style_block.inc.php
12.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
<?php defined('ABSPATH') or die('Access denied.'); ?>
<style>
<?php if(!empty($wdtFontColorSettings['wdtTableFontColor'])){ ?>
/* table font color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead th,
.wpdt-c .wpDataTablesWrapper table.wpDataTable tbody td,
.wpdt-c .wpDataTablesWrapper table.wpDataTabletable tfoot td {
color: <?php echo $wdtFontColorSettings['wdtTableFontColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtHeaderBaseColor'])){ ?>
/* th background color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead th,
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead th.sorting {
background-color: <?php echo $wdtFontColorSettings['wdtHeaderBaseColor'] ?> !important;
background-image: none !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtHeaderBorderColor'])){ ?>
/* th border color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead th,
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead th.sorting {
border-color: <?php echo $wdtFontColorSettings['wdtHeaderBorderColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtHeaderFontColor'])){ ?>
/* th font color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead th {
color: <?php echo $wdtFontColorSettings['wdtHeaderFontColor'] ?> !important;
}
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead th.sorting:after,
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead th.sorting_asc:after {
border-bottom-color: <?php echo $wdtFontColorSettings['wdtHeaderFontColor'] ?> !important;
}
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead th.sorting_desc:after {
border-top-color: <?php echo $wdtFontColorSettings['wdtHeaderFontColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtHeaderActiveColor'])){ ?>
/* th active/hover background color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead th.sorting_asc,
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead th.sorting_desc,
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead th.sorting:hover {
background-color: <?php echo $wdtFontColorSettings['wdtHeaderActiveColor'] ?> !important;
background-image: none !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtTableInnerBorderColor'])){ ?>
/* td inner border color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable td {
border-color: <?php echo $wdtFontColorSettings['wdtTableInnerBorderColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtTableOuterBorderColor'])){ ?>
/* table outer border color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr:last-child td {
border-bottom-color: <?php echo $wdtFontColorSettings['wdtTableOuterBorderColor'] ?> !important;
}
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr td:first-child {
border-left-color: <?php echo $wdtFontColorSettings['wdtTableOuterBorderColor'] ?> !important;
}
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr td:last-child {
border-right-color: <?php echo $wdtFontColorSettings['wdtTableOuterBorderColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtOddRowColor'])){ ?>
/* odd rows background color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr.odd td {
background-color: <?php echo $wdtFontColorSettings['wdtOddRowColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtEvenRowColor'])){ ?>
/* even rows background color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr.even td,
.wpdt-c .wpDataTablesWrapper table.has-columns-hidden tr.row-detail > td {
background-color: <?php echo $wdtFontColorSettings['wdtEvenRowColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtActiveOddCellColor'])){ ?>
/* odd rows active background color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr.odd td.sorting_1 {
background-color: <?php echo $wdtFontColorSettings['wdtActiveOddCellColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtActiveEvenCellColor'])){ ?>
/* even rows active background color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr.even td.sorting_1 {
background-color: <?php echo $wdtFontColorSettings['wdtActiveEvenCellColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtHoverRowColor'])){ ?>
/* rows hover background color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr.odd:hover > td,
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr.odd:hover > td.sorting_1,
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr.even:hover > td,
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr.even:hover > td.sorting_1 {
background-color: <?php echo $wdtFontColorSettings['wdtHoverRowColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtSelectedRowColor'])){ ?>
/* selected rows background color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr.odd.selected > td,
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr.odd.selected > td.sorting_1,
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr.even.selected > td,
.wpdt-c .wpDataTablesWrapper table.wpDataTable tr.even.selected > td.sorting_1 {
background-color: <?php echo $wdtFontColorSettings['wdtSelectedRowColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtButtonColor'])){ ?>
/* buttons background color */
.wpDataTables .wdt-checkbox-filter.btn,
.wdt-frontend-modal .btn,
div.dt-button-collection a.dt-button.active:not(.disabled) {
background-color: <?php echo $wdtFontColorSettings['wdtButtonColor'] ?> !important;
background-image: none !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtButtonBorderColor'])){ ?>
/* buttons border color */
.wpDataTables .wdt-checkbox-filter.btn,
.wdt-frontend-modal .btn:not(.dropdown-toggle),
div.dt-button-collection a.dt-button.active:not(.disabled) {
<?php if ($wdtFontColorSettings['wdtButtonBorderColor']) { ?>
border: 1px solid;
border-color: <?php echo $wdtFontColorSettings['wdtButtonBorderColor'] ?> !important;
<?php } ?>
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtButtonFontColor'])){ ?>
/* buttons font color */
.wpDataTables .wdt-checkbox-filter.btn,
.wpDataTables .selecter .selecter-selected,
.wdt-frontend-modal .btn:not(.dropdown-toggle),
div.dt-button-collection a.dt-button.active:not(.disabled) {
color: <?php echo $wdtFontColorSettings['wdtButtonFontColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtBorderRadius'])){ ?>
<?php $wdtBorderRadius = (int)$wdtFontColorSettings['wdtBorderRadius']; ?>
/* buttons and inputs border radius */
.wpDataTables .wdt-checkbox-filter.btn,
.wdt-frontend-modal .btn:not(.dropdown-toggle),
div.dt-button-collection a.dt-button.active:not(.disabled) {
border-radius: <?php echo $wdtBorderRadius ?>px !important;
}
.wpDataTables input {
border-radius: <?php echo $wdtBorderRadius ?>px !important;
}
<?php echo $wdtSelecterRadius = $wdtBorderRadius-1 > 0 ? $wdtBorderRadius-1 : 0; ?>
.wpDataTables .selecter .selecter-item:last-child {
border-radius: 0px 0px <?php echo $wdtSelecterRadius ?>px <?php echo $wdtSelecterRadius ?>px !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtButtonBackgroundHoverColor'])){ ?>
/** buttons background hover color */
.wpDataTables .wdt-checkbox-filter.btn:hover,
.wdt-frontend-modal .btn:not(.dropdown-toggle).btn:hover,
div.dt-button-collection a.dt-button.active:not(.disabled):hover {
background-color: <?php echo $wdtFontColorSettings['wdtButtonBackgroundHoverColor'] ?> !important;
background-image: none !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtButtonBorderHoverColor'])){ ?>
/** buttons hover border color */
.wpDataTables .wdt-checkbox-filter.btn:hover,
.wdt-frontend-modal .btn:not(.dropdown-toggle).btn:hover,
div.dt-button-collection a.dt-button.active:not(.disabled):hover {
border-color: <?php echo $wdtFontColorSettings['wdtButtonBorderHoverColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtButtonFontHoverColor'])){ ?>
/** buttons hover font color */
.wpDataTables .wdt-checkbox-filter.btn:hover,
.wdt-frontend-modal .btn:not(.dropdown-toggle).btn:hover,
div.dt-button-collection a.dt-button.active:not(.disabled):hover {
color: <?php echo $wdtFontColorSettings['wdtButtonFontHoverColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtButtonFontHoverColor'])){ ?>
/** buttons hover font color */
.wpDataTables .wdt-checkbox-filter.btn:hover,
.wdt-frontend-modal .btn:not(.dropdown-toggle).btn:hover,
div.dt-button-collection a.dt-button.active:not(.disabled):hover {
color: <?php echo $wdtFontColorSettings['wdtButtonFontHoverColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtModalFontColor'])){ ?>
/** modals font color */
.wpDataTables .picker .picker-handle,
.wpDataTables .picker.focus .picker-handle {
border-color: <?php echo $wdtFontColorSettings['wdtModalFontColor'] ?> !important;
}
.wpDataTables .picker.picker-checkbox .picker-flag,
.wpDataTables .picker .picker-label,
.wdt-frontend-modal .modal-dialog .modal-content,
.wpDataTables .picker__box,
.wpDataTables .picker__weekday {
color: <?php echo $wdtFontColorSettings['wdtModalFontColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtModalBackgroundColor'])){ ?>
/** modals background color */
.wdt-frontend-modal .modal-dialog .modal-content,
.wpDataTables .picker__box,
.picker__list-item {
background-color: <?php echo $wdtFontColorSettings['wdtModalBackgroundColor'] ?> !important;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtOverlayColor'])){ ?>
/** overlays background color */
<?php
list($overlayR,$overlayG,$overlayB) = array_map('hexdec',str_split(ltrim($wdtFontColorSettings['wdtOverlayColor'],'#'),2));
?>
.modal-backdrop.in,
.wpdt-c .wpDataTablesWrapper .picker--opened .picker__holder {
background-color: rgba(<?php echo (int)$overlayR ?>,<?php echo (int)$overlayG ?>,<?php echo (int)$overlayB ?>,0.8) !important;
}
<?php } ?>
<?php if( get_option('wdtRenderFilter') == 'header') { ?>
.wpdt-c .wpDataTablesWrapper table.wpDataTable thead tr:nth-child(2) th {
overflow: visible;
}
<?php } ?>
<?php if(!empty($wdtFontColorSettings['wdtTableFont'])){ ?>
/* table font color */
.wpdt-c .wpDataTablesWrapper table.wpDataTable {
font-family: <?php echo $wdtFontColorSettings['wdtTableFont'] ?> !important;
}
<?php } ?>
<?php if( !empty($wdtFontColorSettings['wdtFontSize'] ) ) { ?>
/* table font size */
.wpdt-c .wpDataTablesWrapper table.wpDataTable {
font-size:<?php echo $wdtFontColorSettings['wdtFontSize'] ?>px;
}
<?php } ?>
<?php if( !empty($wdtFontColorSettings['wdtPaginationCurrentBackgroundColor'] ) ) { ?>
/* pagination current page background color */
.wpDataTablesWrapper .dataTables_paginate .paginate_button.current,
.wpDataTablesWrapper .dataTables_paginate .paginate_button.current:hover{
background-color:<?php echo $wdtFontColorSettings['wdtPaginationCurrentBackgroundColor'] ?> !important;
}
<?php } ?>
<?php if( !empty($wdtFontColorSettings['wdtPaginationCurrentColor'] ) ) { ?>
/*pagination current page color */
.wpDataTablesWrapper .dataTables_paginate .paginate_button.current,
.wpDataTablesWrapper .dataTables_paginate .paginate_button.current:hover{
color:<?php echo $wdtFontColorSettings['wdtPaginationCurrentColor'] ?> !important;
}
<?php } ?>
<?php if( !empty($wdtFontColorSettings['wdtPaginationHoverBackgroundColor'] ) ) { ?>
/* pagination other pages hover background color */
.wpDataTablesWrapper .dataTables_paginate .paginate_button:hover:not(.disabled):not(.current){
background-color:<?php echo $wdtFontColorSettings['wdtPaginationHoverBackgroundColor'] ?> !important;
}
<?php } ?>
<?php if( !empty($wdtFontColorSettings['wdtPaginationHoverColor'] ) ) { ?>
/* pagination other pages hover color */
.wpDataTablesWrapper .dataTables_paginate .paginate_button:hover:not(.disabled):not(.current),
.wpDataTablesWrapper .paginate_button.previous:hover:before,
.wpDataTablesWrapper .paginate_button.first:hover:before,
.wpDataTablesWrapper .paginate_button.next:hover:before,
.wpDataTablesWrapper .paginate_button.last:hover:before{
color:<?php echo $wdtFontColorSettings['wdtPaginationHoverColor'] ?> !important;
}
<?php } ?>
<?php if( !empty($wdtFontColorSettings['wdtPaginationBackgroundColor'] ) ) { ?>
/* pagination background color */
.wpDataTablesWrapper .dataTables_paginate {
background-color:<?php echo $wdtFontColorSettings['wdtPaginationBackgroundColor'] ?> !important;
}
<?php } ?>
<?php if( !empty($wdtFontColorSettings['wdtPaginationColor'] ) ) { ?>
/* pagination color */
.wpDataTablesWrapper .dataTables_paginate .paginate_button,
.wpDataTablesWrapper .dataTables_paginate .paginate_button.disabled:before,
.wpDataTablesWrapper .dataTables_paginate .paginate_button.disabled:hover:before,
.wpDataTablesWrapper .dataTables_paginate .ellipsis,
.wpDataTablesWrapper .paginate_button.previous:before,
.wpDataTablesWrapper .paginate_button.first:before,
.wpDataTablesWrapper .paginate_button.next:before,
.wpDataTablesWrapper .paginate_button.last:before{
color:<?php echo $wdtFontColorSettings['wdtPaginationColor'] ?> !important;
}
<?php } ?>
</style>