mirror of
https://github.com/StarCitizenTools/mediawiki-skins-Citizen.git
synced 2024-11-28 00:01:05 +00:00
feat(SemanticMediaWiki): ✨ add datatable styles
This commit is contained in:
parent
739fa8504c
commit
8cfa260997
|
@ -369,6 +369,7 @@
|
||||||
"+smw.jsonview": "skinStyles/extensions/SemanticMediaWiki/smw.jsonview.less",
|
"+smw.jsonview": "skinStyles/extensions/SemanticMediaWiki/smw.jsonview.less",
|
||||||
"+smw.special.search.styles": "skinStyles/extensions/SemanticMediaWiki/smw.special.search.styles.less",
|
"+smw.special.search.styles": "skinStyles/extensions/SemanticMediaWiki/smw.special.search.styles.less",
|
||||||
"+smw.summarytable": "skinStyles/extensions/SemanticMediaWiki/smw.summarytable.less",
|
"+smw.summarytable": "skinStyles/extensions/SemanticMediaWiki/smw.summarytable.less",
|
||||||
|
"+smw.tableprinter.datatable": "skinStyles/extensions/SemanticMediaWiki/smw.tableprinter.datatable.less",
|
||||||
"+smw.tippy": "skinStyles/extensions/SemanticMediaWiki/smw.tippy.less",
|
"+smw.tippy": "skinStyles/extensions/SemanticMediaWiki/smw.tippy.less",
|
||||||
"+smw.ui.styles": "skinStyles/extensions/SemanticMediaWiki/smw.ui.styles.less",
|
"+smw.ui.styles": "skinStyles/extensions/SemanticMediaWiki/smw.ui.styles.less",
|
||||||
"+ext.srf.d3.chart.bubble": "skinStyles/extensions/SemanticResultFormats/d3/ext.srf.d3.chart.bubble.less",
|
"+ext.srf.d3.chart.bubble": "skinStyles/extensions/SemanticResultFormats/d3/ext.srf.d3.chart.bubble.less",
|
||||||
|
@ -636,6 +637,7 @@
|
||||||
"infobox",
|
"infobox",
|
||||||
"cargoDynamicTable",
|
"cargoDynamicTable",
|
||||||
"dataTable",
|
"dataTable",
|
||||||
|
"smw-datatable",
|
||||||
"mw-capiunto-infobox"
|
"mw-capiunto-infobox"
|
||||||
],
|
],
|
||||||
"description": "Defines table css classes ignored by citizen table wrapper",
|
"description": "Defines table css classes ignored by citizen table wrapper",
|
||||||
|
|
|
@ -8,6 +8,8 @@
|
||||||
* Date: 2023-01-03
|
* Date: 2023-01-03
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/* Sync with smw.tableprinter.datatable */
|
||||||
|
|
||||||
/* jquery.dataTables.css */
|
/* jquery.dataTables.css */
|
||||||
table.dataTable {
|
table.dataTable {
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
|
@ -39,8 +41,6 @@ table.dataTable tfoot td {
|
||||||
table.dataTable thead .sorting,
|
table.dataTable thead .sorting,
|
||||||
table.dataTable thead .sorting_asc,
|
table.dataTable thead .sorting_asc,
|
||||||
table.dataTable thead .sorting_desc {
|
table.dataTable thead .sorting_desc {
|
||||||
border-radius: var( --border-radius--small );
|
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
background-color: var( --background-color-quiet--hover );
|
background-color: var( --background-color-quiet--hover );
|
||||||
}
|
}
|
||||||
|
@ -250,12 +250,6 @@ table.dataTable.no-footer {
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dataTables_wrapper .dataTables_length,
|
|
||||||
.dataTables_wrapper .dataTables_filter {
|
|
||||||
// Add some space
|
|
||||||
margin: var( --space-xs ) 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.dataTables_wrapper .dataTables_length,
|
.dataTables_wrapper .dataTables_length,
|
||||||
.dataTables_wrapper .dataTables_filter,
|
.dataTables_wrapper .dataTables_filter,
|
||||||
.dataTables_wrapper .dataTables_info,
|
.dataTables_wrapper .dataTables_info,
|
||||||
|
|
|
@ -330,6 +330,10 @@ a.smw-ask-action-btn-lblue:active {
|
||||||
font-family: inherit;
|
font-family: inherit;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.smw-dropdown > button {
|
||||||
|
font-weight: var( --font-weight-medium );
|
||||||
|
}
|
||||||
|
|
||||||
.smw-dropdown > a::before,
|
.smw-dropdown > a::before,
|
||||||
.smw-dropdown > button::before {
|
.smw-dropdown > button::before {
|
||||||
border-top-color: var( --color-base--emphasized );
|
border-top-color: var( --color-base--emphasized );
|
||||||
|
|
|
@ -0,0 +1,290 @@
|
||||||
|
/*
|
||||||
|
* Citizen
|
||||||
|
*
|
||||||
|
* SkinStyles for Extension:SemanticMediaWiki
|
||||||
|
* Module: smw.tableprinter.datatable
|
||||||
|
* Version: 4.1.1 (8c09283)
|
||||||
|
*
|
||||||
|
* Date: 2023-07-16
|
||||||
|
*/
|
||||||
|
|
||||||
|
.smw-datatable table.dataTable thead th,
|
||||||
|
.smw-datatable table.dataTable thead td,
|
||||||
|
.smw-datatable table.data.smw-datatable table.compact thead th,
|
||||||
|
.smw-datatable table.data.smw-datatable table.compact thead td {
|
||||||
|
border-top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.smw-datatable .dataTables_wrapper select,
|
||||||
|
.smw-datatable .dataTables_wrapper .dataTables_filter input {
|
||||||
|
border: 1px solid var( --border-color-base );
|
||||||
|
color: var( --color-base--emphasized );
|
||||||
|
}
|
||||||
|
|
||||||
|
.smw-datatable-toolbar .smw-dropdown {
|
||||||
|
button {
|
||||||
|
border-color: var( --border-color-base );
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.smw-datatable .dataTables_wrapper .dataTables_paginate .paginate_button {
|
||||||
|
border-color: var( --border-color-base );
|
||||||
|
transition: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Sync with ext.cargo.datatables */
|
||||||
|
.smw-datatable {
|
||||||
|
table.dataTable {
|
||||||
|
overflow: auto;
|
||||||
|
max-width: 100%;
|
||||||
|
font-size: 0.875rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable thead th,
|
||||||
|
table.dataTable tfoot th {
|
||||||
|
font-weight: var( --font-weight-semibold );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable thead th,
|
||||||
|
table.dataTable thead td {
|
||||||
|
padding: var( --space-xs ) var( --space-sm );
|
||||||
|
border-bottom-color: var( --border-color-base );
|
||||||
|
color: var( --color-base--subtle );
|
||||||
|
font-size: 0.8125rem;
|
||||||
|
font-weight: var( --font-weight-normal );
|
||||||
|
letter-spacing: 0.05em;
|
||||||
|
text-align: start;
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable tfoot th,
|
||||||
|
table.dataTable tfoot td {
|
||||||
|
border-top-color: var( --border-color-base );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable thead .sorting,
|
||||||
|
table.dataTable thead .sorting_asc,
|
||||||
|
table.dataTable thead .sorting_desc {
|
||||||
|
&:hover {
|
||||||
|
background-color: var( --background-color-quiet--hover );
|
||||||
|
}
|
||||||
|
|
||||||
|
&:active {
|
||||||
|
background-color: var( --background-color-quiet--active );
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable thead .sorting,
|
||||||
|
table.dataTable thead .sorting_asc,
|
||||||
|
table.dataTable thead .sorting_desc,
|
||||||
|
table.dataTable thead .sorting_asc_disabled,
|
||||||
|
table.dataTable thead .sorting_desc_disabled {
|
||||||
|
// 19px is the icon size
|
||||||
|
padding-right: ~'calc( 19px + var( --space-sm ) )';
|
||||||
|
background-position-x: ~'calc( 100% - var( --space-xs ) )';
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable tbody tr {
|
||||||
|
background-color: var( --color-surface-0 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable tbody tr.selected {
|
||||||
|
background-color: var( --background-color-quiet--hover );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable tbody th,
|
||||||
|
table.dataTable tbody td {
|
||||||
|
padding: var( --space-xs ) var( --space-sm );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.row-border tbody th,
|
||||||
|
table.dataTable.row-border tbody td,
|
||||||
|
table.dataTable.display tbody th,
|
||||||
|
table.dataTable.display tbody td {
|
||||||
|
border-top-color: var( --border-color-base );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.cell-border tbody th,
|
||||||
|
table.dataTable.cell-border tbody td {
|
||||||
|
border-top-color: var( --border-color-base );
|
||||||
|
border-right-color: var( --border-color-base );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.cell-border tbody tr th:first-child,
|
||||||
|
table.dataTable.cell-border tbody tr td:first-child {
|
||||||
|
border-left-color: var( --border-color-base );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.stripe tbody tr.odd,
|
||||||
|
table.dataTable.display tbody tr.odd {
|
||||||
|
background-color: var( --color-surface-2 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.stripe tbody tr.odd.selected,
|
||||||
|
table.dataTable.display tbody tr.odd.selected {
|
||||||
|
background-color: var( --background-color-quiet--hover );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.hover tbody tr:hover,
|
||||||
|
table.dataTable.display tbody tr:hover,
|
||||||
|
table.dataTable.hover tbody tr:hover.selected,
|
||||||
|
table.dataTable.display tbody tr:hover.selected {
|
||||||
|
background-color: var( --background-color-quiet--hover );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.order-column tbody tr > .sorting_1,
|
||||||
|
table.dataTable.order-column tbody tr > .sorting_2,
|
||||||
|
table.dataTable.order-column tbody tr > .sorting_3,
|
||||||
|
table.dataTable.display tbody tr > .sorting_1,
|
||||||
|
table.dataTable.display tbody tr > .sorting_2,
|
||||||
|
table.dataTable.display tbody tr > .sorting_3 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.order-column tbody tr.selected > .sorting_1,
|
||||||
|
table.dataTable.order-column tbody tr.selected > .sorting_2,
|
||||||
|
table.dataTable.order-column tbody tr.selected > .sorting_3,
|
||||||
|
table.dataTable.display tbody tr.selected > .sorting_1,
|
||||||
|
table.dataTable.display tbody tr.selected > .sorting_2,
|
||||||
|
table.dataTable.display tbody tr.selected > .sorting_3 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr.odd > .sorting_1,
|
||||||
|
table.dataTable.order-column.stripe tbody tr.odd > .sorting_1 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr.odd > .sorting_2,
|
||||||
|
table.dataTable.order-column.stripe tbody tr.odd > .sorting_2 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr.odd > .sorting_3,
|
||||||
|
table.dataTable.order-column.stripe tbody tr.odd > .sorting_3 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr.odd.selected > .sorting_1,
|
||||||
|
table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_1 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr.odd.selected > .sorting_2,
|
||||||
|
table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_2 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr.odd.selected > .sorting_3,
|
||||||
|
table.dataTable.order-column.stripe tbody tr.odd.selected > .sorting_3 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr.even > .sorting_1,
|
||||||
|
table.dataTable.order-column.stripe tbody tr.even > .sorting_1 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr.even > .sorting_2,
|
||||||
|
table.dataTable.order-column.stripe tbody tr.even > .sorting_2 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr.even > .sorting_3,
|
||||||
|
table.dataTable.order-column.stripe tbody tr.even > .sorting_3 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr.even.selected > .sorting_1,
|
||||||
|
table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_1 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr.even.selected > .sorting_2,
|
||||||
|
table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_2 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr.even.selected > .sorting_3,
|
||||||
|
table.dataTable.order-column.stripe tbody tr.even.selected > .sorting_3 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr:hover > .sorting_1,
|
||||||
|
table.dataTable.order-column.hover tbody tr:hover > .sorting_1 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr:hover > .sorting_2,
|
||||||
|
table.dataTable.order-column.hover tbody tr:hover > .sorting_2 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr:hover > .sorting_3,
|
||||||
|
table.dataTable.order-column.hover tbody tr:hover > .sorting_3 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr:hover.selected > .sorting_1,
|
||||||
|
table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_1 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr:hover.selected > .sorting_2,
|
||||||
|
table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_2 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.display tbody tr:hover.selected > .sorting_3,
|
||||||
|
table.dataTable.order-column.hover tbody tr:hover.selected > .sorting_3 {
|
||||||
|
background-color: var( --color-surface-3 );
|
||||||
|
}
|
||||||
|
|
||||||
|
table.dataTable.no-footer {
|
||||||
|
border-bottom-color: var( --border-color-base );
|
||||||
|
}
|
||||||
|
|
||||||
|
/* stylelint-disable-next-line no-duplicate-selectors */
|
||||||
|
.dataTables_wrapper .dataTables_paginate .paginate_button {
|
||||||
|
border-radius: var( --border-radius--small );
|
||||||
|
color: var( --color-base--emphasized ) !important;
|
||||||
|
font-weight: var( --font-weight-medium );
|
||||||
|
}
|
||||||
|
|
||||||
|
.dataTables_wrapper .dataTables_paginate .paginate_button.current,
|
||||||
|
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
|
||||||
|
border-color: transparent;
|
||||||
|
background: var( --background-color-primary--active );
|
||||||
|
color: var( --color-base--emphasized ) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled,
|
||||||
|
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover,
|
||||||
|
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:active {
|
||||||
|
color: var( --color-base--subtle ) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
|
||||||
|
border-color: transparent;
|
||||||
|
background: var( --background-color-quiet--hover );
|
||||||
|
color: var( --color-base--emphasized ) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dataTables_wrapper .dataTables_paginate .paginate_button:active {
|
||||||
|
background: var( --background-color-quiet--active );
|
||||||
|
box-shadow: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dataTables_wrapper .dataTables_length,
|
||||||
|
.dataTables_wrapper .dataTables_filter,
|
||||||
|
.dataTables_wrapper .dataTables_info,
|
||||||
|
.dataTables_wrapper .dataTables_processing,
|
||||||
|
.dataTables_wrapper .dataTables_paginate {
|
||||||
|
color: var( --color-base );
|
||||||
|
font-size: 0.875rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dataTables_wrapper .dataTables_filter + .dataTable {
|
||||||
|
// Add top border as divider if there are filter on top
|
||||||
|
border-top: 1px solid var( --border-color-base );
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue