From 4f1b0daf34422bd93a39c8b37c818ba4b4cae60e Mon Sep 17 00:00:00 2001 From: ulleo Date: Thu, 16 Nov 2023 14:45:53 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E8=B0=83=E6=95=B4AntV=E8=A1=A8?= =?UTF-8?q?=E6=A0=BC=E6=96=91=E9=A9=AC=E7=BA=B9=E9=A2=9C=E8=89=B2=E9=85=8D?= =?UTF-8?q?=E7=BD=AE=E4=B8=8EEcharts=E7=BB=9F=E4=B8=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- core/frontend/src/lang/en.js | 2 +- core/frontend/src/lang/tw.js | 2 +- core/frontend/src/lang/zh.js | 2 +- .../src/views/chart/chart/common/common_table.js | 11 ++++++++--- 4 files changed, 11 insertions(+), 6 deletions(-) diff --git a/core/frontend/src/lang/en.js b/core/frontend/src/lang/en.js index 3343a4e8f3..1bee90b490 100644 --- a/core/frontend/src/lang/en.js +++ b/core/frontend/src/lang/en.js @@ -1147,7 +1147,7 @@ export default { table_header_bg: 'Header Background', table_item_bg: 'Table Background', table_item_sub_enable: 'Enable CrossBackgroundColor', - table_item_sub_bg: 'Table CrossBackgroundColor', + table_item_sub_bg: 'CrossBackgroundColor', table_header_font_color: 'Header Font', table_item_font_color: 'Table Font', table_show_index: 'Show Index', diff --git a/core/frontend/src/lang/tw.js b/core/frontend/src/lang/tw.js index c694425e1c..3f3b9f5975 100644 --- a/core/frontend/src/lang/tw.js +++ b/core/frontend/src/lang/tw.js @@ -1146,7 +1146,7 @@ export default { table_header_bg: '表頭背景', table_item_bg: '表格背景', table_item_sub_enable: '斑馬紋', - table_item_sub_bg: '奇數行表格背景', + table_item_sub_bg: '斑馬紋顏色', table_header_font_color: '表頭字體', table_item_font_color: '表格字體', table_show_index: '顯示序號', diff --git a/core/frontend/src/lang/zh.js b/core/frontend/src/lang/zh.js index 6eaeab9ce6..9843040a55 100644 --- a/core/frontend/src/lang/zh.js +++ b/core/frontend/src/lang/zh.js @@ -1145,7 +1145,7 @@ export default { table_header_bg: '表头背景', table_item_bg: '表格背景', table_item_sub_enable: '斑马纹', - table_item_sub_bg: '奇数行表格背景', + table_item_sub_bg: '斑马纹颜色', table_header_font_color: '表头字体', table_item_font_color: '表格字体', table_show_index: '显示序号', diff --git a/core/frontend/src/views/chart/chart/common/common_table.js b/core/frontend/src/views/chart/chart/common/common_table.js index 4c16f0dfd5..2ac834cc2b 100644 --- a/core/frontend/src/views/chart/chart/common/common_table.js +++ b/core/frontend/src/views/chart/chart/common/common_table.js @@ -165,9 +165,14 @@ export function getCustomTheme(chart) { theme.colCell.text.fill = c.tableHeaderFontColor ? c.tableHeaderFontColor : c.tableFontColor theme.colCell.measureText.fill = c.tableHeaderFontColor ? c.tableHeaderFontColor : c.tableFontColor - // 奇数行单元格背景色 - theme.dataCell.cell.crossBackgroundColor = enableTableCrossBG ? i_s_c : i_c - theme.dataCell.cell.backgroundColor = i_c + // 为了与Echarts统一,奇数行是原来颜色 + if (enableTableCrossBG) { + theme.dataCell.cell.crossBackgroundColor = i_c + theme.dataCell.cell.backgroundColor = i_s_c + } else { + theme.dataCell.cell.crossBackgroundColor = i_c + theme.dataCell.cell.backgroundColor = i_c + } theme.dataCell.cell.horizontalBorderColor = b_c theme.dataCell.cell.verticalBorderColor = b_c theme.dataCell.bolderText.fill = c.tableFontColor