This is an automated email from the ASF dual-hosted git repository. shenyi pushed a commit to branch enhance-morph in repository https://gitbox.apache.org/repos/asf/echarts.git
The following commit(s) were added to refs/heads/enhance-morph by this push: new eee35f8 feat(ut): divideShape default to be clone in series with symbol. eee35f8 is described below commit eee35f885beab3285eff5ac32ff2af69c618d733 Author: pissang <bm2736...@gmail.com> AuthorDate: Sat Jun 19 00:13:32 2021 +0800 feat(ut): divideShape default to be clone in series with symbol. symbol usually are too small and complex to divide --- src/chart/effectScatter/EffectScatterSeries.ts | 3 +++ src/chart/line/LineSeries.ts | 6 +++++- src/chart/scatter/ScatterSeries.ts | 4 ++++ src/util/types.ts | 6 +++--- test/universalTransition2.html | 2 +- 5 files changed, 16 insertions(+), 5 deletions(-) diff --git a/src/chart/effectScatter/EffectScatterSeries.ts b/src/chart/effectScatter/EffectScatterSeries.ts index e6f8830..5d16446 100644 --- a/src/chart/effectScatter/EffectScatterSeries.ts +++ b/src/chart/effectScatter/EffectScatterSeries.ts @@ -119,6 +119,9 @@ class EffectScatterSeriesModel extends SeriesModel<EffectScatterSeriesOption> { brushType: 'fill' }, + universalTransition: { + divideShape: 'clone' + }, // Cartesian coordinate system // xAxisIndex: 0, // yAxisIndex: 0, diff --git a/src/chart/line/LineSeries.ts b/src/chart/line/LineSeries.ts index 7dfe71d..0b685eb 100644 --- a/src/chart/line/LineSeries.ts +++ b/src/chart/line/LineSeries.ts @@ -208,7 +208,11 @@ class LineSeriesModel extends SeriesModel<LineSeriesOption> { // Disable progressive progressive: 0, - hoverLayerThreshold: Infinity + hoverLayerThreshold: Infinity, + + universalTransition: { + divideShape: 'clone' + } }; getLegendIcon(opt: LegendIconParams): ECSymbol | Group { diff --git a/src/chart/scatter/ScatterSeries.ts b/src/chart/scatter/ScatterSeries.ts index 92efb41..a217c5a 100644 --- a/src/chart/scatter/ScatterSeries.ts +++ b/src/chart/scatter/ScatterSeries.ts @@ -144,6 +144,10 @@ class ScatterSeriesModel extends SeriesModel<ScatterSeriesOption> { itemStyle: { borderColor: '#212121' } + }, + + universalTransition: { + divideShape: 'clone' } // progressive: null }; diff --git a/src/util/types.ts b/src/util/types.ts index 05edf06..fe9a0c7 100644 --- a/src/util/types.ts +++ b/src/util/types.ts @@ -1611,11 +1611,11 @@ export interface SeriesOption< * If enabled universal transition cross series. */ universalTransition?: { - enabled: boolean + enabled?: boolean /** * How to divide the shape in combine and split animation. */ - divideShape: 'clone' | 'split' + divideShape?: 'clone' | 'split' /** * Series will have transition between if they have same seriesKey. * Usually it is a string. It can also be an array, @@ -1627,7 +1627,7 @@ export interface SeriesOption< * * Default to use series id. */ - seriesKey: string | string[] + seriesKey?: string | string[] } /** diff --git a/test/universalTransition2.html b/test/universalTransition2.html index fb8aa7a..78a1ac3 100644 --- a/test/universalTransition2.html +++ b/test/universalTransition2.html @@ -260,7 +260,7 @@ under the License. }, universalTransition: { enabled: true, - divideShape: 'clone' + // divideShape: 'clone' } } } --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@echarts.apache.org For additional commands, e-mail: commits-h...@echarts.apache.org