Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/nightly-next.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
registry-url: https://registry.npmjs.org/
registry-url: https://npm.pkg.github.com/
- name: Setup and publish nightly
run: |
node build/nightly/prepare.js --next
Expand All @@ -38,4 +38,4 @@ jobs:
npm run test:dts
npm publish --tag next
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
6 changes: 3 additions & 3 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:
jobs:
build:
runs-on: ubuntu-latest
if: ${{ github.repository_owner == 'apache' }}
if: ${{ github.repository_owner == 'appflow-ai' }}

strategy:
matrix:
Expand All @@ -22,7 +22,7 @@ jobs:
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
registry-url: https://registry.npmjs.org/
registry-url: https://npm.pkg.github.com/
- name: Setup and publish nightly
run: |
node build/nightly/prepare.js
Expand All @@ -35,4 +35,4 @@ jobs:
npm run test:dts
npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
2 changes: 1 addition & 1 deletion .github/workflows/source-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
jobs:
materials:
runs-on: ubuntu-latest
if: ${{ github.repository_owner == 'apache' }}
if: ${{ github.repository_owner == 'appflow-ai' }}

strategy:
matrix:
Expand Down
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@appflow-ai:registry=https://npm.pkg.github.com
7 changes: 3 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "echarts",
"name": "@appflow-ai/echarts",
"version": "5.4.1",
"description": "Apache ECharts is a powerful, interactive charting and data visualization library for browser",
"license": "Apache-2.0",
Expand All @@ -20,12 +20,11 @@
"types": "index.d.ts",
"homepage": "https://echarts.apache.org",
"bugs": {
"url": "https://github.com/apache/echarts/issues",
"email": "dev@echarts.apache.org"
"url": "https://github.com/appflow-ai/echarts/issues"
},
"repository": {
"type": "git",
"url": "git+https://github.com/apache/echarts.git"
"url": "git+https://github.com/appflow-ai/echarts.git"
},
"sideEffects": [
"index.js",
Expand Down
22 changes: 21 additions & 1 deletion src/chart/funnel/FunnelSeries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,10 @@ type FunnelLabelOption = Omit<SeriesLabelOption, 'position'> & {
| 'outer' | 'inner' | 'center' | 'rightTop' | 'rightBottom' | 'leftTop' | 'leftBottom'
};

type FunnelRateLabelOption = Omit<SeriesLabelOption, 'position'> & {
precision: number
};

interface FunnelStatesMixin {
emphasis?: DefaultStatesMixinEmphasis
}
Expand All @@ -59,6 +63,8 @@ export interface FunnelStateOption<TCbParams = never> {
itemStyle?: ItemStyleOption<TCbParams>
label?: FunnelLabelOption
labelLine?: LabelLineOption
rateLabel?: FunnelRateLabelOption
overallRateLabel?: FunnelRateLabelOption
}

export interface FunnelDataItemOption
Expand Down Expand Up @@ -95,6 +101,12 @@ export interface FunnelSeriesOption
funnelAlign?: HorizontalAlign | VerticalAlign

data?: (OptionDataValueNumeric | OptionDataValueNumeric[] | FunnelDataItemOption)[]

exitWidth?: string

showRate?: boolean

dynamicHeight?: boolean
}

class FunnelSeriesModel extends SeriesModel<FunnelSeriesOption> {
Expand Down Expand Up @@ -172,6 +184,14 @@ class FunnelSeriesModel extends SeriesModel<FunnelSeriesOption> {
position: 'outer'
// formatter: 标签文本格式器,同Tooltip.formatter,不支持异步回调
},
rateLabel: {
show: true,
precision: 2
},
overallRateLabel: {
show: true,
precision: 2
},
labelLine: {
show: true,
length: 20,
Expand Down Expand Up @@ -199,4 +219,4 @@ class FunnelSeriesModel extends SeriesModel<FunnelSeriesOption> {

}

export default FunnelSeriesModel;
export default FunnelSeriesModel;
Loading