diff --git a/frontend/src/views/chart/components/ChartComponent.vue b/frontend/src/views/chart/components/ChartComponent.vue index 4c60e80017..e538d3abd0 100644 --- a/frontend/src/views/chart/components/ChartComponent.vue +++ b/frontend/src/views/chart/components/ChartComponent.vue @@ -10,15 +10,15 @@
- +
- +
- +
@@ -81,7 +81,7 @@ import { geoJson } from '@/api/map/map' import ViewTrackBar from '@/components/canvas/components/Editor/ViewTrackBar' - +import { reverseColor } from '../chart/common/common' export default { name: 'ChartComponent', components: { @@ -140,7 +140,8 @@ export default { dynamicAreaCode: null, borderRadius: '0px', mapCenter: null, - linkageActiveParam: null + linkageActiveParam: null, + buttonTextColor: null } }, @@ -291,6 +292,13 @@ export default { let themeStyle = null if (this.themeStyle) { themeStyle = JSON.parse(JSON.stringify(this.themeStyle)) + if (themeStyle && themeStyle.backgroundColorSelect) { + const panelColor = themeStyle.color + if (panelColor !== '#FFFFFF') { + const reverseValue = reverseColor(panelColor) + this.buttonTextColor = reverseValue + } + } } const chart_option = baseMapOption(base_json, chart, themeStyle, curAreaCode) this.myEcharts(chart_option)