diff --git a/internals/cli/src/commands/build/build-entry-app.ts b/internals/cli/src/commands/build/build-entry-app.ts index b9c98df4f8..ffe3f0faad 100644 --- a/internals/cli/src/commands/build/build-entry-app.ts +++ b/internals/cli/src/commands/build/build-entry-app.ts @@ -151,7 +151,7 @@ const buildFullRuntime = (mode: RunTimeModeType) => { .map((component) => { if (component.includes('Hui')) { return `${component}${joinStr}${component} as ${component - .replace('Huicharts', 'Charts') + .replace('Huicharts', 'Chart') .trim()}${joinStr}${component} as Tiny${component.trim()}` } return `${component}${joinStr}${component} as Tiny${component.trim()}` @@ -161,7 +161,7 @@ const buildFullRuntime = (mode: RunTimeModeType) => { .map((component) => { if (component.includes('Hui')) { return `${component}${joinStr}${component - .replace('Huicharts', 'Charts') + .replace('Huicharts', 'Chart') .trim()}: ${component}${joinStr}Tiny${component.trim()}: ${component}` } return `${component}${joinStr}Tiny${component.trim()}: ${component}` diff --git a/packages/vue/src/huicharts/huicharts-amap/src/AMapModel.ts b/packages/vue/src/huicharts/huicharts-amap/src/AMapModel.ts index 5dd316c5da..5b16611811 100644 --- a/packages/vue/src/huicharts/huicharts-amap/src/AMapModel.ts +++ b/packages/vue/src/huicharts/huicharts-amap/src/AMapModel.ts @@ -19,12 +19,12 @@ export default function extendComponentModel() { }, setCenterAndZoom(center, zoom) { - this.option.center = center - this.option.zoom = zoom + this.huiChartOption.center = center + this.huiChartOption.zoom = zoom }, centerOrZoomChanged(center, zoom) { - let option = this.option + let option = this.huiChartOption return !(equal(center, option.center) && zoom === option.zoom) }, diff --git a/packages/vue/src/huicharts/huicharts-amap/src/autonavi-map.vue b/packages/vue/src/huicharts/huicharts-amap/src/autonavi-map.vue index e526a562b2..848906a98e 100644 --- a/packages/vue/src/huicharts/huicharts-amap/src/autonavi-map.vue +++ b/packages/vue/src/huicharts/huicharts-amap/src/autonavi-map.vue @@ -25,13 +25,13 @@ export default { methods: { updateChart() { if (this.options && Object.keys(this.options).length) { - this.option = { ...this.options, ...this.settings } + this.huiChartOption = { ...this.options, ...this.settings } if (!this.tooltipVisible) { - this.option.tooltip = { show: false } + this.huiChartOption.tooltip = { show: false } } if (!this.legendVisible) { - this.option.legend = { show: false } + this.huiChartOption.legend = { show: false } } return @@ -55,7 +55,7 @@ export default { 'backgroundColor', 'textStyle' ] - this.option = { + this.huiChartOption = { ...this.settings, tooltip: this.tooltipVisible ? this.tooltip : { show: false }, series: this.series @@ -63,12 +63,12 @@ export default { echartsSettings.forEach((prop) => { if (this[prop]) { - this.option[prop] = this[prop] + this.huiChartOption[prop] = this[prop] } }) if (!this.legendVisible) { - this.option.legend = { show: false } + this.huiChartOption.legend = { show: false } } } } diff --git a/packages/vue/src/huicharts/huicharts-bar/src/chart-bar.vue b/packages/vue/src/huicharts/huicharts-bar/src/chart-bar.vue index 2a06d1d222..829287733c 100644 --- a/packages/vue/src/huicharts/huicharts-bar/src/chart-bar.vue +++ b/packages/vue/src/huicharts/huicharts-bar/src/chart-bar.vue @@ -31,7 +31,7 @@ export default { const option = histogram(columns, rows, this.settings, extra, false) - this.option = { + this.huiChartOption = { smooth: true, ...option, direction: 'horizontal' diff --git a/packages/vue/src/huicharts/huicharts-bmap/src/baidu-map.vue b/packages/vue/src/huicharts/huicharts-bmap/src/baidu-map.vue index 1882d4082d..8529ec8320 100644 --- a/packages/vue/src/huicharts/huicharts-bmap/src/baidu-map.vue +++ b/packages/vue/src/huicharts/huicharts-bmap/src/baidu-map.vue @@ -22,13 +22,13 @@ export default { methods: { updateChart() { if (this.options && Object.keys(this.options).length) { - this.option = { ...this.options, ...this.settings } + this.huiChartOption = { ...this.options, ...this.settings } if (!this.tooltipVisible) { - this.option.tooltip = { show: false } + this.huiChartOption.tooltip = { show: false } } if (!this.legendVisible) { - this.option.legend = { show: false } + this.huiChartOption.legend = { show: false } } return @@ -52,7 +52,7 @@ export default { 'backgroundColor', 'textStyle' ] - this.option = { + this.huiChartOption = { ...this.settings, tooltip: this.tooltipVisible ? this.tooltip : { show: false }, series: this.series @@ -60,12 +60,12 @@ export default { echartsSettings.forEach((prop) => { if (this[prop]) { - this.option[prop] = this[prop] + this.huiChartOption[prop] = this[prop] } }) if (!this.legendVisible) { - this.option.legend = { show: false } + this.huiChartOption.legend = { show: false } } } } diff --git a/packages/vue/src/huicharts/huicharts-boxplot/src/chart-boxplot.vue b/packages/vue/src/huicharts/huicharts-boxplot/src/chart-boxplot.vue index 8be1afbae0..c40f917e0a 100644 --- a/packages/vue/src/huicharts/huicharts-boxplot/src/chart-boxplot.vue +++ b/packages/vue/src/huicharts/huicharts-boxplot/src/chart-boxplot.vue @@ -28,7 +28,7 @@ export default { data: prepareBoxplotData && Array.isArray(data) ? data : null } const option = boxplot(columns, rows, this.settings, extra) - this.option = { ...option } + this.huiChartOption = { ...option } }, prepareBoxplotData(data) { return prepareBoxplotData(data) diff --git a/packages/vue/src/huicharts/huicharts-candle/src/chart-candle.vue b/packages/vue/src/huicharts/huicharts-candle/src/chart-candle.vue index 13fb4ff100..fdb34b30ad 100644 --- a/packages/vue/src/huicharts/huicharts-candle/src/chart-candle.vue +++ b/packages/vue/src/huicharts/huicharts-candle/src/chart-candle.vue @@ -27,7 +27,7 @@ export default { legendVisible: this.legendVisible, t } - this.option = candle(columns, rows, this.settings, extra) + this.huiChartOption = candle(columns, rows, this.settings, extra) } } } diff --git a/packages/vue/src/huicharts/huicharts-core/common/extend.ts b/packages/vue/src/huicharts/huicharts-core/common/extend.ts index 814b1293cc..7df0448cfc 100644 --- a/packages/vue/src/huicharts/huicharts-core/common/extend.ts +++ b/packages/vue/src/huicharts/huicharts-core/common/extend.ts @@ -19,8 +19,8 @@ function removeNullKeys(obj) { return obj } -export default ({ option, extend }) => { - const cloneOption = cloneDeep(option) +export default ({ huiChartOption, extend }) => { + const cloneOption = cloneDeep(huiChartOption) const mergeOption = removeNullKeys(cloneOption) if (!extend) { return @@ -53,13 +53,17 @@ export default ({ option, extend }) => { ] if (~attrList.indexOf(key)) { // attrList,指定的key才能合并处理 - mergeOption[key] = merge(mergeOption[key], value) + if (key === 'dataZoom') { + mergeOption[key] = value + } else { + mergeOption[key] = merge(mergeOption[key], value) + } } } else { // 属性为对象(eg: tooltip)或包含对象的数组(eg: series) if (isArr(mergeOption[key]) && isObject(mergeOption[key][0])) { // 属性值是包含对象数组 - mergeOption[key].forEach((option, i) => (mergeOption[key][i] = { ...option, ...value })) + mergeOption[key].forEach((huiChartOption, i) => (mergeOption[key][i] = { ...huiChartOption, ...value })) } else if (isObject(mergeOption[key])) { // 被替换属性值是对象 let optionBase = mergeOption[key] diff --git a/packages/vue/src/huicharts/huicharts-core/src/chart-core.ts b/packages/vue/src/huicharts/huicharts-core/src/chart-core.ts index bfe1550a2c..b0cadb5754 100644 --- a/packages/vue/src/huicharts/huicharts-core/src/chart-core.ts +++ b/packages/vue/src/huicharts/huicharts-core/src/chart-core.ts @@ -26,7 +26,7 @@ export default { }, width: { type: String, default: 'auto' }, height: { type: String, default: '400px' }, - events: { type: Object, default() { } }, + events: { type: Object, default() {} }, initOptions: { type: Object, default() { @@ -72,7 +72,7 @@ export default { }, extend: { type: Object, - default() { } + default() {} }, tooltipFormatter: { type: Function }, @@ -120,7 +120,7 @@ export default { }, setOptionOpts: { type: Object, - default() { } + default() {} }, colorMode: { type: String, @@ -194,27 +194,27 @@ export default { ...this.initOpts, ...val } - this.renderChart(this.option) + this.renderChart(this.huiChartOption) }, deep: true }, judgeWidth: { handler(val) { this.initOpts.domResize = val - this.renderChart(this.option) + this.renderChart(this.huiChartOption) } }, delay: { handler(val) { this.initOpts.resizeThrottle = val - this.renderChart(this.option) + this.renderChart(this.huiChartOption) }, deep: true }, resizeable: { handler(val) { this.initOpts.windowResize = val - this.renderChart(this.option) + this.renderChart(this.huiChartOption) } }, setOptionOpts: { @@ -334,10 +334,10 @@ export default { } } }, - applyExtend(option) { + applyExtend(huiChartOption) { if (this.extend) { return setExtend({ - option, + huiChartOption, extend: this.extend }) } @@ -345,56 +345,56 @@ export default { // 更新图表 refreshChart() { - if (!this.option.theme) { - this.option.theme = 'cloud-light' - } - if (Array.isArray(this.colors) && this.colors.length > 0) { - option.color = cloneDeep(this.colors) - } const { data } = this if (Object.keys(this.options).length === 0) { this.updateChart(data) } else { - this.option = cloneDeep(this.options) + this.huiChartOption = cloneDeep(this.options) + } + let huiChartOption = cloneDeep(this.huiChartOption) + if (!huiChartOption.theme) { + huiChartOption.theme = 'cloud-light' + } + if (Array.isArray(this.colors) && this.colors.length > 0) { + huiChartOption.color = cloneDeep(this.colors) } - let { option } = this clearTimeout(this.timer) this.timer = null this.timer = setTimeout(() => { if (this.afterConfig) { - option = this.afterConfig(option) + huiChartOption = this.afterConfig(optichartOptionon) } - this.selfSetting(option) - this.setAnimation(option) + this.selfSetting(huiChartOption) + this.setAnimation(huiChartOption) this.applyMarks(this.integrateChart.eChartOption) - this.integrateChart.refresh(option) + this.integrateChart.refresh(cloneDeep(huiChartOption)) if (this.colorMode !== 'default') { - option.color = this.computedChartColor() + huiChartOption.color = this.computedChartColor() } if (this.extend && Object.keys(this.extend).length !== 0) { - option.extend = this.applyExtend(this.integrateChart.eChartOption) - this.integrateChart.refresh(option) + huiChartOption.extend = this.applyExtend(this.integrateChart.eChartOption) + this.integrateChart.refresh(cloneDeep(huiChartOption)) } - this.$emit('handle-color', option.color) + this.$emit('handle-color', huiChartOption.color) if (this.afterSetOption) { this.afterSetOption(this.integrateChart.echartsIns) } - this.$emit('ready', this.integrateChart.echartsIns, option) + this.$emit('ready', this.integrateChart.echartsIns, huiChartOption) }, this.changeDelay) this.eChartOption = this.integrateChart.eChartOption }, // 初始渲染图表 - renderChart(option) { + renderChart(huiChartOption) { // 设置默认theme为'cloud-light' - if (!option.theme) { - option.theme = 'cloud-light' + if (!huiChartOption.theme) { + huiChartOption.theme = 'cloud-light' } // 将外部colors放入配置项中 if (Array.isArray(this.colors) && this.colors.length > 0) { - option.color = cloneDeep(this.colors) + huiChartOption.color = cloneDeep(this.colors) } const plugins = this.plugins || {} @@ -402,13 +402,13 @@ export default { if (this.isSelfChart) { this.integrateChart.init(this.$refs.chartRef) if (this.colorMode !== 'default') { - option.color = this.computedChartColor() + huiChartOption.color = this.computedChartColor() } - this.integrateChart.setSimpleOption(this.chartList[this.iChartName], option, plugins) - this.$emit('handle-color', option.color) + this.integrateChart.setSimpleOption(this.chartList[this.iChartName], huiChartOption, plugins) + this.$emit('handle-color', huiChartOption.color) } else { - this.selfSetting(option) - this.setAnimation(option) + this.selfSetting(huiChartOption) + this.setAnimation(huiChartOption) // theme为ecahrts主题参数 const theme = this.themeName || this.theme || DEFAULT_THEME @@ -416,27 +416,27 @@ export default { // 通过colorMode参数控制颜色 if (this.colorMode !== 'default') { - option.color = this.computedChartColor() + huiChartOption.color = this.computedChartColor() } - this.integrateChart.setSimpleOption(this.iChartName, option, plugins) - this.$emit('handle-color', option.color) + this.integrateChart.setSimpleOption(this.iChartName, cloneDeep(huiChartOption), plugins) + this.$emit('handle-color', huiChartOption.color) this.applyMarks(this.integrateChart.eChartOption) } // 判断extend,将extend放入配置项中 if (this.extend && Object.keys(this.extend).length !== 0) { - option.extend = this.applyExtend(this.integrateChart.eChartOption) - this.integrateChart.setSimpleOption(this.iChartName, option, plugins) + huiChartOption.extend = this.applyExtend(this.integrateChart.eChartOption) + this.integrateChart.setSimpleOption(this.iChartName, cloneDeep(huiChartOption), plugins) } this.integrateChart.render(this.renderOption) // 返回图表实例 - this.$emit('ready', this.integrateChart.echartsIns, option) + this.$emit('ready', this.integrateChart.echartsIns, huiChartOption) // 返回图表实例(仅一次) if (!this.once['ready-once']) { this.once['ready-once'] = true - this.$emit('ready-once', this.integrateChart.echartsIns, option) + this.$emit('ready-once', this.integrateChart.echartsIns, huiChartOption) } // 赋值echartOption,方便用户获取 @@ -467,12 +467,12 @@ export default { this.integrateChart.echartsIns.resize() } }, - afterConfigFn(option) { + afterConfigFn(huiChartOption) { if (this.afterConfig) { - option = this.afterConfig(option) - this.option = option + huiChartOption = this.afterConfig(huiChartOption) + this.huiChartOption = huiChartOption } - return option + return huiChartOption }, beforeConfigFn(data) { if (this.beforeConfig) { @@ -537,7 +537,7 @@ export default { } }, created() { - this.option = {} + this.huiChartOption = {} if (!this.selfChart.includes(this.iChartName)) { this.isSelfChart = false this.integrateChart = new IntegrateChart() @@ -567,12 +567,12 @@ export default { if (Object.keys(this.options).length === 0) { this.updateChart(data) } else { - this.option = cloneDeep(this.options) + this.huiChartOption = cloneDeep(this.options) } - let { option } = this - option = this.afterConfigFn(option) + let { huiChartOption } = this + huiChartOption = this.afterConfigFn(huiChartOption) - this.renderChart(option) + this.renderChart(huiChartOption) this.afterSetOption && this.afterSetOption(this.integrateChart.echartsIns) diff --git a/packages/vue/src/huicharts/huicharts-funnel/src/chart-funnel.vue b/packages/vue/src/huicharts/huicharts-funnel/src/chart-funnel.vue index c10058638d..cc221475ac 100644 --- a/packages/vue/src/huicharts/huicharts-funnel/src/chart-funnel.vue +++ b/packages/vue/src/huicharts/huicharts-funnel/src/chart-funnel.vue @@ -24,7 +24,7 @@ export default { legendVisible: this.legendVisible, tooltipVisible: this.tooltipVisible } - this.option = getIChartOption(columns, rows, this.settings, extra) + this.huiChartOption = getIChartOption(columns, rows, this.settings, extra) } } } diff --git a/packages/vue/src/huicharts/huicharts-gauge/src/chart-gauge.vue b/packages/vue/src/huicharts/huicharts-gauge/src/chart-gauge.vue index c8b6f33058..27bdf26ea5 100644 --- a/packages/vue/src/huicharts/huicharts-gauge/src/chart-gauge.vue +++ b/packages/vue/src/huicharts/huicharts-gauge/src/chart-gauge.vue @@ -27,7 +27,7 @@ export default { legendVisible: this.legendVisible, tooltipVisible: this.tooltipVisible } - this.option = getIChartOption(columns, rows, this.settings, extra) + this.huiChartOption = getIChartOption(columns, rows, this.settings, extra) } } } diff --git a/packages/vue/src/huicharts/huicharts-graph/src/chart-graph.vue b/packages/vue/src/huicharts/huicharts-graph/src/chart-graph.vue index cf62371bf2..b3d56cf402 100644 --- a/packages/vue/src/huicharts/huicharts-graph/src/chart-graph.vue +++ b/packages/vue/src/huicharts/huicharts-graph/src/chart-graph.vue @@ -27,7 +27,7 @@ export default { } const option = graph(columns, rows, this.settings, extra) - this.option = { + this.huiChartOption = { ...option } } diff --git a/packages/vue/src/huicharts/huicharts-heatmap/src/chart-heatmap.vue b/packages/vue/src/huicharts/huicharts-heatmap/src/chart-heatmap.vue index 5d1b63a595..f231f07e77 100644 --- a/packages/vue/src/huicharts/huicharts-heatmap/src/chart-heatmap.vue +++ b/packages/vue/src/huicharts/huicharts-heatmap/src/chart-heatmap.vue @@ -40,7 +40,7 @@ export default { echartsLib: this.integrateChart.echartIns } const option = heatmap(columns, rows, this.settings, extra, true) - this.option = { + this.huiChartOption = { ...option } }, diff --git a/packages/vue/src/huicharts/huicharts-histogram/src/chart-histogram.vue b/packages/vue/src/huicharts/huicharts-histogram/src/chart-histogram.vue index 296c7a20db..f9b6e83dd4 100644 --- a/packages/vue/src/huicharts/huicharts-histogram/src/chart-histogram.vue +++ b/packages/vue/src/huicharts/huicharts-histogram/src/chart-histogram.vue @@ -31,7 +31,7 @@ export default { const option = histogram(columns, rows, this.settings, extra, true) - this.option = { + this.huiChartOption = { smooth: true, ...option } diff --git a/packages/vue/src/huicharts/huicharts-line/src/chart-line.vue b/packages/vue/src/huicharts/huicharts-line/src/chart-line.vue index a82bbc50ac..411e3f0eb9 100644 --- a/packages/vue/src/huicharts/huicharts-line/src/chart-line.vue +++ b/packages/vue/src/huicharts/huicharts-line/src/chart-line.vue @@ -28,7 +28,7 @@ export default { } const option = line(columns, rows, this.settings, extra) - this.option = { + this.huiChartOption = { smooth: true, ...option } diff --git a/packages/vue/src/huicharts/huicharts-liquidfill/src/chart-liquidfill.vue b/packages/vue/src/huicharts/huicharts-liquidfill/src/chart-liquidfill.vue index 462db33b6c..e4c9218a15 100644 --- a/packages/vue/src/huicharts/huicharts-liquidfill/src/chart-liquidfill.vue +++ b/packages/vue/src/huicharts/huicharts-liquidfill/src/chart-liquidfill.vue @@ -28,7 +28,7 @@ export default { legendVisible: this.legendVisible, tooltipVisible: this.tooltipVisible } - this.option = getIChartOption(columns, rows, this.settings, extra) + this.huiChartOption = getIChartOption(columns, rows, this.settings, extra) } } } diff --git a/packages/vue/src/huicharts/huicharts-map/src/chart-map.vue b/packages/vue/src/huicharts/huicharts-map/src/chart-map.vue index 75e792e7e6..7096200e45 100644 --- a/packages/vue/src/huicharts/huicharts-map/src/chart-map.vue +++ b/packages/vue/src/huicharts/huicharts-map/src/chart-map.vue @@ -38,7 +38,7 @@ export default { const option = map(columns, rows, this.settings, extra) - this.option = { + this.huiChartOption = { ...option } } diff --git a/packages/vue/src/huicharts/huicharts-pie/src/chart-pie.vue b/packages/vue/src/huicharts/huicharts-pie/src/chart-pie.vue index ea873778ae..9e494b4dfe 100644 --- a/packages/vue/src/huicharts/huicharts-pie/src/chart-pie.vue +++ b/packages/vue/src/huicharts/huicharts-pie/src/chart-pie.vue @@ -29,7 +29,7 @@ export default { tooltipVisible: this.tooltipVisible, t } - this.option = pie(columns, rows, this.settings, extra) + this.huiChartOption = pie(columns, rows, this.settings, extra) } } } diff --git a/packages/vue/src/huicharts/huicharts-process/src/chart-process.vue b/packages/vue/src/huicharts/huicharts-process/src/chart-process.vue index a6df47fcc7..3b273f0505 100644 --- a/packages/vue/src/huicharts/huicharts-process/src/chart-process.vue +++ b/packages/vue/src/huicharts/huicharts-process/src/chart-process.vue @@ -20,7 +20,7 @@ export default { }, methods: { updateChart() { - this.option = { ...this.options } + this.huiChartOption = { ...this.options } } } } diff --git a/packages/vue/src/huicharts/huicharts-radar/src/chart-radar.vue b/packages/vue/src/huicharts/huicharts-radar/src/chart-radar.vue index a6933e076b..3850a1e346 100644 --- a/packages/vue/src/huicharts/huicharts-radar/src/chart-radar.vue +++ b/packages/vue/src/huicharts/huicharts-radar/src/chart-radar.vue @@ -40,7 +40,7 @@ export default { extend: this.extend } const option = radar(columns, rows, this.settings, extra) - this.option = { + this.huiChartOption = { ...option } } diff --git a/packages/vue/src/huicharts/huicharts-ring/src/chart-ring.vue b/packages/vue/src/huicharts/huicharts-ring/src/chart-ring.vue index 2829a5750d..fbf73a3574 100644 --- a/packages/vue/src/huicharts/huicharts-ring/src/chart-ring.vue +++ b/packages/vue/src/huicharts/huicharts-ring/src/chart-ring.vue @@ -28,7 +28,7 @@ export default { tooltipVisible: this.tooltipVisible, t } - this.option = pie(columns, rows, this.settings, extra, true) + this.huiChartOption = pie(columns, rows, this.settings, extra, true) } } } diff --git a/packages/vue/src/huicharts/huicharts-sankey/src/chart-sankey.vue b/packages/vue/src/huicharts/huicharts-sankey/src/chart-sankey.vue index ebbd6e110e..bcecc32535 100644 --- a/packages/vue/src/huicharts/huicharts-sankey/src/chart-sankey.vue +++ b/packages/vue/src/huicharts/huicharts-sankey/src/chart-sankey.vue @@ -28,7 +28,7 @@ export default { tooltipVisible: this.tooltipVisible } const option = sankey(columns, rows, this.settings, extra) - this.option = { + this.huiChartOption = { ...option } } diff --git a/packages/vue/src/huicharts/huicharts-scatter/src/chart-scatter.vue b/packages/vue/src/huicharts/huicharts-scatter/src/chart-scatter.vue index 71dfbd1158..d3cd2ccdf2 100644 --- a/packages/vue/src/huicharts/huicharts-scatter/src/chart-scatter.vue +++ b/packages/vue/src/huicharts/huicharts-scatter/src/chart-scatter.vue @@ -28,7 +28,7 @@ export default { tooltipVisible: this.tooltipVisible } const option = scatter(columns, rows, this.settings, extra) - this.option = { ...option } + this.huiChartOption = { ...option } } } } diff --git a/packages/vue/src/huicharts/huicharts-sunburst/src/chart-sunburst.vue b/packages/vue/src/huicharts/huicharts-sunburst/src/chart-sunburst.vue index 9f2c2f1c59..9aa22839fa 100644 --- a/packages/vue/src/huicharts/huicharts-sunburst/src/chart-sunburst.vue +++ b/packages/vue/src/huicharts/huicharts-sunburst/src/chart-sunburst.vue @@ -28,7 +28,7 @@ export default { } const option = sunburst(columns, rows, this.settings, extra) - this.option = { + this.huiChartOption = { ...option } } diff --git a/packages/vue/src/huicharts/huicharts-tree/src/chart-tree.vue b/packages/vue/src/huicharts/huicharts-tree/src/chart-tree.vue index dedf81f2ce..4eff763e58 100644 --- a/packages/vue/src/huicharts/huicharts-tree/src/chart-tree.vue +++ b/packages/vue/src/huicharts/huicharts-tree/src/chart-tree.vue @@ -30,7 +30,7 @@ export default { } const option = tree(columns, rows, this.settings, extra) - this.option = { ...option } + this.huiChartOption = { ...option } } } } diff --git a/packages/vue/src/huicharts/huicharts-waterfall/src/chart-waterfall.vue b/packages/vue/src/huicharts/huicharts-waterfall/src/chart-waterfall.vue index 434c46691d..c3ab03129e 100644 --- a/packages/vue/src/huicharts/huicharts-waterfall/src/chart-waterfall.vue +++ b/packages/vue/src/huicharts/huicharts-waterfall/src/chart-waterfall.vue @@ -29,7 +29,7 @@ export default { } const option = waterfall(columns, rows, this.settings, extra) - this.option = { + this.huiChartOption = { ...option } } diff --git a/packages/vue/src/huicharts/huicharts-wordcloud/src/chart-wordcloud.vue b/packages/vue/src/huicharts/huicharts-wordcloud/src/chart-wordcloud.vue index bd94c205b3..b64584deea 100644 --- a/packages/vue/src/huicharts/huicharts-wordcloud/src/chart-wordcloud.vue +++ b/packages/vue/src/huicharts/huicharts-wordcloud/src/chart-wordcloud.vue @@ -28,7 +28,7 @@ export default { tooltipVisible: this.tooltipVisible } const option = wordcloud(columns, rows, this.settings, extra) - this.option = { + this.huiChartOption = { ...option } }