表格图表在开启排序选项后在表头显示排序图标

This commit is contained in:
datagear 2021-01-25 18:57:32 +08:00
parent 7e66a03424
commit 542a339fc8
3 changed files with 52 additions and 6 deletions

View File

@ -42,7 +42,7 @@
.dg-chart-table .dg-chart-table-content table.dataTable thead td,
.dg-chart-table .dg-chart-table-content table.dataTable tbody th,
.dg-chart-table .dg-chart-table-content table.dataTable tbody td{
padding: 0.5em 0.8em;
padding: 0.5em 18px;
text-align: left;
white-space: nowrap;
}
@ -74,6 +74,38 @@
.dg-chart-table .dg-chart-table-content .DTFC_RightBodyLiner{
overflow-x: hidden;
}
/*排序图标*/
.dg-chart-table table.dataTable thead th.sorting div.DataTables_sort_wrapper span{
position: absolute;
top: 50%;
margin-top: -2px;
right: -14px;
width: 6px;
height: 6px;
background: #333;
opacity: 0.3;
filter: Alpha(Opacity=30);
}
.dg-chart-table table.dataTable thead th.sorting_asc div.DataTables_sort_wrapper span{
width: 0;
height: 0;
border-left: 3px solid transparent;
border-right: 3px solid transparent;
border-bottom: 6px solid #333;
background: none;
opacity: 1;
filter: Alpha(Opacity=100);
}
.dg-chart-table table.dataTable thead th.sorting_desc div.DataTables_sort_wrapper span{
width: 0;
height: 0;
border-left: 3px solid transparent;
border-right: 3px solid transparent;
border-top: 6px solid #333;
background: none;
opacity: 1;
filter: Alpha(Opacity=100);
}
/*标签图表*/
.dg-chart-label{

View File

@ -1262,27 +1262,30 @@
+" color: "+color+";"
+" background: "+bgColor+";"
+" border-color: "+borderColor+";"
+"} "
+"} \n"
+qualifier + ".dg-chart-setting-box .dg-chart-setting-button:hover{"
+" background: "+chartFactory.getGradualColor(chartTheme, 0.2)+";"
+"} \n"
+qualifier + ".dg-chart-setting-box .dg-chart-setting-panel{"
+" color: "+color+";"
+" background: "+bgColor+";"
+" border-color: "+borderColor+";"
+" box-shadow: 0px 0px 6px "+shadowColor+";"
+" -webkit-box-shadow: 0px 0px 6px "+shadowColor+";"
+"} "
+"} \n"
+qualifier + ".dg-chart-setting-box .dg-chart-setting-panel .dg-chartdataset-section{"
+" color: "+color+";"
+" background: "+bgColor+";"
+" border-color: "+borderColor+";"
+"} "
+"} \n"
+qualifier + ".dg-chart-setting-box .dg-chart-setting-panel .dg-chart-setting-panel-foot button{"
+" color: "+color+";"
+" background: "+chartFactory.getGradualColor(chartTheme, 0.1)+";"
+" border-color: "+borderColor+";"
+"} "
+"} \n"
+qualifier + ".dg-chart-setting-box .dg-chart-setting-panel .dg-chart-setting-panel-foot button:hover{"
+" background: "+chartFactory.getGradualColor(chartTheme, 0.3)+";"
+"} "
+"} \n"
;
global.chartFactory.createStyleSheet(styleId, cssText);

View File

@ -4652,6 +4652,17 @@
+qualifier + " table.dataTable.stripe tbody > tr.odd > .selected, table.dataTable.display tbody > tr.odd.selected,"
+qualifier + " table.dataTable.display tbody > tr.odd > .selected {"
+ global.chartFactory.stylesObjToCssText(chartOptions.table.row.selected)
+"} \n"
+qualifier + " table.dataTable thead th.sorting div.DataTables_sort_wrapper span {"
+ " background:" + chartOptions.table.header.color+";"
+"} \n"
+qualifier + " table.dataTable thead th.sorting_asc div.DataTables_sort_wrapper span {"
+ " border-bottom-color:" + chartOptions.table.header.color+";"
+ " background: none;"
+"} \n"
+qualifier + " table.dataTable thead th.sorting_desc div.DataTables_sort_wrapper span {"
+ " border-top-color:" + chartOptions.table.header.color+";"
+ " background: none;"
+"} \n";
global.chartFactory.createStyleSheet(styleSheetId, cssText);