PluginProbe
Darkify – Dark Mode & Night Mode for Website & Admin (Dark Theme Included) / 2.0.3
Darkify – Dark Mode & Night Mode for Website & Admin (Dark Theme Included) v2.0.3
2.1.3 2.1.2 2.1.1 2.1.0 2.0.4 2.0.3 2.0.2 2.0.1 2.0.0 1.5.5 1.5.4 1.5.3 1.5.2 1.5.1 1.5.0 trunk 1.0.1 1.1.0 1.2.0 1.2.1 1.2.2 1.2.3 1.2.4 1.2.5 1.3.0 All 57 releases
darkify / src / Admin / Views / ColorControl.php

ColorControl.php in Darkify – Dark Mode & Night Mode for Website & Admin (Dark Theme Included) 2.0.3, at src/Admin/Views/ColorControl.php

957 lines 60.8 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 /**
4 * ColorControl class for Color options.
5 *
6 * @link https://themeatelier.net
7 * @since 1.0.0
8 *
9 * @package darkify
10 * @subpackage darkify/src/Admin/Views/ColorControl
11 * @author ThemeAtelier<themeatelierbd@gmail.com>
12 */
13
14 namespace ThemeAtelier\Darkify\Admin\Views;
15
16 use ThemeAtelier\Darkify\Admin\Schema\SchemaRegistry as Darkify;
17
18 class ColorControl
19 {
20 /**
21 * Create Option fields for the setting options.
22 *
23 * @param string $prefix Option setting key prefix.
24 * @return void
25 */
26 public static function options($prefix)
27 {
28 Darkify::createSection(
29 $prefix,
30 array(
31 'id' => 'colors',
32 'title' => esc_html__('Colors', 'darkify'),
33 'icon' => 'icofont-paint',
34 'fields' => array(
35
36 array(
37 'type' => 'section_tab',
38 'tabs' => array(
39 array(
40 'id' => 'preset',
41 'title' => esc_html__('Preset', 'darkify'),
42 'icon' => 'icofont-color-bucket',
43 'fields' => array(
44 // Intro line, rendered plain above the section card.
45 array(
46 'type' => 'page_hint',
47 'content' => esc_html__('Pick a dark-mode color preset, then fine-tune any individual color for your site.', 'darkify'),
48 ),
49 // ===== CHOOSE A PRESET =====
50 array(
51 'type' => 'heading',
52 'title' => esc_html__('Choose A Preset', 'darkify'),
53 'section_start' => true,
54 ),
55 array(
56 'id' => 'color_pallets',
57 'type' => 'palette',
58 'class' => 'darkify_preset',
59 // Title lifted to the section heading above; the field keeps only its
60 // short description (rendered above the swatch grid by PaletteField).
61 'title_help' =>
62 esc_html__('Choose from pre-made dark-mode color presets.', 'darkify'),
63
64 'options' => array(
65 'set1' => array(
66 'colors' => array('#0F0F0F', '#4A4A4A', '#BEBEBE', '#171717', '#2D2D2D'),
67 'name' => esc_html__('Carbon Mist', 'darkify'),
68 ),
69 'set3' => array(
70 'colors' => array('#211e3c', '#B1BBD8', '#302C57', '#4E478D', '#2A264D'),
71 'name' => esc_html__('Midnight Reverie', 'darkify'),
72 ),
73 'set9' => array(
74 'colors' => array('#04261d', '#C1D2BB', '#021e16', '#073d2f', '#095541'),
75 'name' => esc_html__('Verdant Depths', 'darkify'),
76 ),
77 'set6' => array(
78 'colors' => array('#082032', '#B5D9F3', '#061825', '#144E78', '#0E3755'),
79 'name' => esc_html__('Celestial Tide', 'darkify'),
80 ),
81 'set10' => array(
82 'colors' => array('#171004', '#E0D2BD', '#211706', '#372911', '#5D4010'),
83 'name' => esc_html__('Emberwood', 'darkify'),
84 ),
85 'set2' => array(
86 'colors' => array('#092635', '#BEE0F1', '#081E29', '#123d52', '#195979'),
87 'name' => esc_html__('Glacier Drift', 'darkify'),
88 'pro_only' => true,
89 ),
90 'set4' => array(
91 'colors' => array('#1d253a', '#B1BBD8', '#2B3655', '#46598C', '#242F4C'),
92 'name' => esc_html__('Indigo Veil', 'darkify'),
93 'pro_only' => true,
94 ),
95 'set5' => array(
96 'colors' => array('#1b1823', '#C6C1D5', '#352f44', '#403953', '#54496f'),
97 'name' => esc_html__('Duskmire', 'darkify'),
98 'pro_only' => true,
99 ),
100 'set7' => array(
101 'colors' => array('#07161b', '#C5E6F0', '#0d242e', '#286F8D', '#19495A'),
102 'name' => esc_html__('Tidal Frost', 'darkify'),
103 'pro_only' => true,
104 ),
105 'set8' => array(
106 'colors' => array('#15274C', '#ACC1EA', '#112244', '#244892', '#1a2f5c'),
107 'name' => esc_html__('Blue Bastion', 'darkify'),
108 'pro_only' => true,
109 ),
110 'set11' => array(
111 'colors' => array('#19081b', '#c09dc2', '#210a24', '#440649', '#2c082f'),
112 'name' => esc_html__('Crimson Veil', 'darkify'),
113 'pro_only' => true,
114 ),
115 ),
116 'default' => 'set1',
117 ),
118 array(
119 'type' => 'heading',
120 'title' => esc_html__('Customize Selected Preset', 'darkify'),
121 'section_start' => true,
122 ),
123
124 // color pallate set 1
125 array(
126 'id' => 'dark_mode_color_set1',
127 'type' => 'color_group',
128 'title' => esc_html__('Background', 'darkify'),
129 'title_help' =>
130 '<div class="darkify-info-label">' .
131 __('Set the background colors used when dark mode is enabled on your website.', 'darkify') .
132 '</div>',
133 'options' => array(
134 'background' => esc_html__('Primary', 'darkify'),
135 'secondary_background' => esc_html__('Secondary', 'darkify'),
136 ),
137
138 'dependency' => array('color_pallets', '==', 'set1', 'all'),
139 'default' => array(
140 'background' => '#0F0F0F',
141 'secondary_background' => '#171717',
142 ),
143 ),
144 array(
145 'id' => 'dark_mode_link_color_set1',
146 'type' => 'color_group',
147 'title' => esc_html__('Text', 'darkify'),
148 'title_help' =>
149 '<div class="darkify-info-label">' .
150 __('Set the text color of your website when dark mode is enabled.', 'darkify') .
151 '</div>',
152
153 'dependency' => array('color_pallets', '==', 'set1', 'all'),
154 'class' => 'only_pro',
155 'options' => array(
156 'text' => esc_html__('Text Color', 'darkify'),
157 'color' => esc_html__('Link Color', 'darkify'),
158 'hover' => esc_html__('Link Hover Color', 'darkify'),
159 ),
160 'default' => array(
161 'text' => '#BEBEBE',
162 'color' => '#E7E7E7',
163 'hover' => '#BEBEBE',
164 ),
165 ),
166 array(
167 'id' => 'dark_mode_input_color_set1',
168 'type' => 'color_group',
169 'title' => esc_html__('Input', 'darkify'),
170 'title_help' =>
171 '<div class="darkify-info-label">' .
172 __('Set the input field colors of your website when dark mode is enabled.', 'darkify') .
173 '</div>',
174
175 'dependency' => array('color_pallets', '==', 'set1', 'all'),
176 'class' => 'only_pro',
177 'options' => array(
178 'color' => esc_html__('Input Text', 'darkify'),
179 'placeholder' => esc_html__('Input Placeholder', 'darkify'),
180 'background' => esc_html__('Input Background', 'darkify'),
181 ),
182
183 'default' => array(
184 'color' => '#BEBEBE',
185 'placeholder' => '#BEBEBE',
186 'background' => '#2D2D2D',
187 ),
188 ),
189 array(
190 'id' => 'dark_mode_border_color_set1',
191 'type' => 'color',
192 'title' => esc_html__('Border', 'darkify'),
193 'title_help' =>
194 '<div class="darkify-info-label">' .
195 __('Set the border color of your website when dark mode is enabled.', 'darkify') .
196 '</div>',
197
198 'class' => 'only_pro',
199 'dependency' => array('color_pallets', '==', 'set1', 'all'),
200 'default' => '#4A4A4A',
201 ),
202 array(
203 'id' => 'dark_mode_btn_color_set1',
204 'type' => 'color_group',
205 'title' => esc_html__('Button', 'darkify'),
206 'title_help' =>
207 '<div class="darkify-info-label">' .
208 __('Set the button colors of your website when dark mode is enabled.', 'darkify') .
209 '</div>',
210
211 'options' => array(
212 'color' => esc_html__('Text Color', 'darkify'),
213 'background' => esc_html__('Background', 'darkify'),
214 'hover_color' => esc_html__('Hover Text Color', 'darkify'),
215 'hover_background' => esc_html__('Hover Background', 'darkify'),
216 ),
217
218 'class' => 'only_pro',
219 'dependency' => array('color_pallets', '==', 'set1', 'all'),
220 'default' => array(
221 'color' => '#BEBEBE',
222 'background' => '#4A4A4A',
223 'hover_color' => '#BEBEBE',
224 'hover_background' => '#2D2D2D',
225 ),
226 ),
227 // color pallate set 3
228 array(
229 'id' => 'dark_mode_color_set3',
230 'type' => 'color_group',
231 'title' => esc_html__('Background', 'darkify'),
232 'title_help' =>
233 '<div class="darkify-info-label">' .
234 __('Set the background color of your website when dark mode is enabled.', 'darkify') .
235 '</div>',
236
237 'options' => array(
238 'background' => esc_html__('Primary', 'darkify'),
239 'secondary_background' => esc_html__('Secondary', 'darkify'),
240 ),
241 'dependency' => array('color_pallets', '==', 'set3', 'all'),
242
243 'default' => array(
244 'background' => '#211e3c',
245 'secondary_background' => '#302C57',
246 ),
247 ),
248 array(
249 'id' => 'dark_mode_link_color_set3',
250 'type' => 'color_group',
251 'title' => esc_html__('Text', 'darkify'),
252 'title_help' =>
253 '<div class="darkify-info-label">' .
254 __('Set the text and link colors of your website when dark mode is enabled.', 'darkify') .
255 '</div>',
256
257 'options' => array(
258 'text' => esc_html__('Text Color', 'darkify'),
259 'color' => esc_html__('Link Color', 'darkify'),
260 'hover' => esc_html__('Link Hover Color', 'darkify'),
261 ),
262
263 'class' => 'only_pro',
264 'dependency' => array('color_pallets', '==', 'set3', 'all'),
265 'default' => array(
266 'text' => '#B1BBD8',
267 'color' => '#8071fb',
268 'hover' => '#B1BBD8',
269 ),
270 ),
271 array(
272 'id' => 'dark_mode_input_color_set3',
273 'type' => 'color_group',
274 'title' => esc_html__('Input', 'darkify'),
275 'title_help' =>
276 '<div class="darkify-info-label">' .
277 __('Set the input field color of your website when dark mode is enabled.', 'darkify') .
278 '</div>',
279
280 'options' => array(
281 'color' => esc_html__('Input Text', 'darkify'),
282 'placeholder' => esc_html__('Input Placeholder', 'darkify'),
283 'background' => esc_html__('Input Background', 'darkify'),
284 ),
285
286 'class' => 'only_pro',
287 'dependency' => array('color_pallets', '==', 'set3', 'all'),
288 'default' => array(
289 'color' => '#B1BBD8',
290 'placeholder' => '#B1BBD8',
291 'background' => '#2A264D',
292 ),
293 ),
294 array(
295 'id' => 'dark_mode_border_color_set3',
296 'type' => 'color',
297 'title' => esc_html__('Border', 'darkify'),
298 'title_help' =>
299 '<div class="darkify-info-label">' .
300 __('Set the border color of your website when dark mode is enabled.', 'darkify') .
301 '</div>',
302
303 'class' => 'only_pro',
304 'dependency' => array('color_pallets', '==', 'set3', 'all'),
305 'default' => '#4E478D',
306 ),
307 array(
308 'id' => 'dark_mode_btn_color_set3',
309 'type' => 'color_group',
310 'title' => esc_html__('Button', 'darkify'),
311 'title_help' =>
312 '<div class="darkify-info-label">' .
313 __('Set the button colors of your website when dark mode is enabled.', 'darkify') .
314 '</div>',
315 'options' => array(
316 'color' => esc_html__('Text Color', 'darkify'),
317 'background' => esc_html__('Background', 'darkify'),
318 'hover_color' => esc_html__('Hover Text Color', 'darkify'),
319 'hover_background' => esc_html__('Hover Background', 'darkify'),
320 ),
321
322 'class' => 'only_pro',
323 'dependency' => array('color_pallets', '==', 'set3', 'all'),
324 'default' => array(
325 'color' => '#4E478D',
326 'background' => '#B1BBD8',
327 'hover_color' => '#B1BBD8',
328 'hover_background' => '#2A264D',
329 ),
330 ),
331 // color pallate set 6
332 array(
333 'id' => 'dark_mode_color_set6',
334 'type' => 'color_group',
335 'title' => esc_html__('Background', 'darkify'),
336 'title_help' =>
337 '<div class="darkify-info-label">' .
338 __('Set the background color of your website when dark mode is enabled.', 'darkify') .
339 '</div>',
340 'options' => array(
341 'background' => esc_html__('Primary', 'darkify'),
342 'secondary_background' => esc_html__('Secondary', 'darkify'),
343 ),
344
345 'dependency' => array('color_pallets', '==', 'set6', 'all'),
346 'default' => array(
347 'background' => '#082032',
348 'secondary_background' => '#2C394B',
349 ),
350 ),
351 array(
352 'id' => 'dark_mode_link_color_set6',
353 'type' => 'color_group',
354 'title' => esc_html__('Text', 'darkify'),
355 'title_help' =>
356 '<div class="darkify-info-label">' .
357 __('Set the text color of your website when dark mode is enabled.', 'darkify') .
358 '</div>',
359 'options' => array(
360 'text' => esc_html__('Text Color', 'darkify'),
361 'color' => esc_html__('Link Color', 'darkify'),
362 'hover' => esc_html__('Link Hover Color', 'darkify'),
363 ),
364
365 'class' => 'only_pro',
366 'dependency' => array('color_pallets', '==', 'set6', 'all'),
367 'default' => array(
368 'text' => '#B5D9F3',
369 'color' => '#61bbff',
370 'hover' => '#B5D9F3',
371 ),
372 ),
373
374 array(
375 'id' => 'dark_mode_input_color_set6',
376 'type' => 'color_group',
377 'title' => esc_html__('Input', 'darkify'),
378 'title_help' =>
379 '<div class="darkify-info-label">' .
380 __('Set the input field color of your website when dark mode is enabled.', 'darkify') .
381 '</div>',
382
383 'options' => array(
384 'color' => esc_html__('Input Text', 'darkify'),
385 'placeholder' => esc_html__('Input Placeholder', 'darkify'),
386 'background' => esc_html__('Input Background', 'darkify'),
387 ),
388
389 'class' => 'only_pro',
390 'dependency' => array('color_pallets', '==', 'set6', 'all'),
391 'default' => array(
392 'color' => '#B5D9F3',
393 'placeholder' => '#B5D9F3',
394 'background' => '#0E3755',
395 ),
396 ),
397
398 array(
399 'id' => 'dark_mode_border_color_set6',
400 'type' => 'color',
401 'title' => esc_html__('Border', 'darkify'),
402 'title_help' =>
403 '<div class="darkify-info-label">' .
404 __('Set the border color of your website when dark mode is enabled.', 'darkify') .
405 '</div>',
406
407 'class' => 'only_pro',
408 'dependency' => array('color_pallets', '==', 'set6', 'all'),
409 'default' => '#3B4D65',
410 ),
411 array(
412 'id' => 'dark_mode_btn_color_set6',
413 'type' => 'color_group',
414 'title' => esc_html__('Button', 'darkify'),
415 'title_help' =>
416 '<div class="darkify-info-label">' .
417 __('Set the button colors of your website when dark mode is enabled.', 'darkify') .
418 '</div>',
419 'options' => array(
420 'color' => esc_html__('Text Color', 'darkify'),
421 'background' => esc_html__('Background', 'darkify'),
422 'hover_color' => esc_html__('Hover Text Color', 'darkify'),
423 'hover_background' => esc_html__('Hover Background', 'darkify'),
424 ),
425
426 'class' => 'only_pro',
427 'dependency' => array('color_pallets', '==', 'set6', 'all'),
428
429 'default' => array(
430 'color' => '#B5D9F3',
431 'background' => '#3B4D65',
432 'hover_color' => '#B5D9F3',
433 'hover_background' => '#144E78',
434 ),
435 ),
436 // color pallate set 9
437 array(
438 'id' => 'dark_mode_color_set9',
439 'type' => 'color_group',
440 'title' => esc_html__('Background', 'darkify'),
441 'title_help' =>
442 '<div class="darkify-info-label">' .
443 __('Set the background color of your website when dark mode is enabled.', 'darkify') .
444 '</div>',
445
446 'dependency' => array('color_pallets', '==', 'set9', 'all'),
447
448 'options' => array(
449 'background' => esc_html__('Primary', 'darkify'),
450 'secondary_background' => esc_html__('Secondary', 'darkify'),
451 ),
452
453 'default' => array(
454 'background' => '#04261d',
455 'secondary_background' => '#021e16',
456 ),
457 ),
458 array(
459 'id' => 'dark_mode_link_color_set9',
460 'type' => 'color_group',
461 'title' => esc_html__('Text', 'darkify'),
462 'title_help' =>
463 '<div class="darkify-info-label">' .
464 __('Set the text and link colors of your website when dark mode is enabled.', 'darkify') .
465 '</div>',
466 'options' => array(
467 'text' => esc_html__('Text Color', 'darkify'),
468 'color' => esc_html__('Link Color', 'darkify'),
469 'hover' => esc_html__('Link Hover Color', 'darkify'),
470 ),
471
472 'class' => 'only_pro',
473 'dependency' => array('color_pallets', '==', 'set9', 'all'),
474 'default' => array(
475 'text' => '#C1D2BB',
476 'color' => '#00d29a',
477 'hover' => '#C1D2BB',
478 ),
479 ),
480
481 array(
482 'id' => 'dark_mode_input_color_set9',
483 'type' => 'color_group',
484 'title' => esc_html__('Input', 'darkify'),
485 'title_help' =>
486 '<div class="darkify-info-label">' .
487 __('Set the input field colors of your website when dark mode is enabled.', 'darkify') .
488 '</div>',
489
490 'options' => array(
491 'color' => esc_html__('Input Text', 'darkify'),
492 'placeholder' => esc_html__('Input Placeholder', 'darkify'),
493 'background' => esc_html__('Input Background', 'darkify'),
494 ),
495
496 'class' => 'only_pro',
497 'dependency' => array('color_pallets', '==', 'set9', 'all'),
498 'default' => array(
499 'color' => '#C1D2BB',
500 'placeholder' => '#C1D2BB',
501 'background' => '#073d2f',
502 ),
503 ),
504
505 array(
506 'id' => 'dark_mode_border_color_set9',
507 'type' => 'color',
508 'title' => esc_html__('Border', 'darkify'),
509 'title_help' =>
510 '<div class="darkify-info-label">' .
511 __('Set the border color of your website when dark mode is enabled.', 'darkify') .
512 '</div>',
513
514 'class' => 'only_pro',
515 'dependency' => array('color_pallets', '==', 'set9', 'all'),
516 'default' => '#095541',
517 ),
518 array(
519 'id' => 'dark_mode_btn_color_set9',
520 'type' => 'color_group',
521 'title' => esc_html__('Button', 'darkify'),
522 'title_help' => '<div class="darkify-info-label">' .
523 __('Set the button colors of your website when dark mode is enabled.', 'darkify') .
524 '</div>',
525 'options' => array(
526 'color' => esc_html__('Text Color', 'darkify'),
527 'background' => esc_html__('Background', 'darkify'),
528 'hover_color' => esc_html__('Hover Text Color', 'darkify'),
529 'hover_background' => esc_html__('Hover Background', 'darkify'),
530 ),
531 'class' => 'only_pro',
532 'dependency' => array('color_pallets', '==', 'set9', 'all'),
533 'default' => array(
534 'color' => '#C1D2BB',
535 'background' => '#095541',
536 'hover_color' => '#C1D2BB',
537 'hover_background' => '#073d2f',
538 ),
539 ),
540 // color pallate set 10
541 array(
542 'id' => 'dark_mode_color_set10',
543 'type' => 'color_group',
544 'title' => esc_html__('Background', 'darkify'),
545 'title_help' =>
546 '<div class="darkify-info-label">' .
547 __('Set the background color of your website when dark mode is enabled.', 'darkify') .
548 '</div>',
549 'options' => array(
550 'background' => esc_html__('Primary', 'darkify'),
551 'secondary_background' => esc_html__('Secondary', 'darkify'),
552 ),
553
554 'dependency' => array('color_pallets', '==', 'set10', 'all'),
555 'default' => array(
556 'background' => '#171004',
557 'secondary_background' => '#211706',
558 ),
559 ),
560 array(
561 'id' => 'dark_mode_link_color_set10',
562 'type' => 'color_group',
563 'title' => esc_html__('Text', 'darkify'),
564 'title_help' =>
565 '<div class="darkify-info-label">' .
566 __('Set the text color of your website when dark mode is enabled.', 'darkify') .
567 '</div>',
568 'options' => array(
569 'text' => esc_html__('Text Color', 'darkify'),
570 'color' => esc_html__('Link Color', 'darkify'),
571 'hover' => esc_html__('Link Hover Color', 'darkify'),
572 ),
573
574 'class' => 'only_pro',
575 'dependency' => array('color_pallets', '==', 'set10', 'all'),
576 'default' => array(
577 'text' => '#E0D2BD',
578 'color' => '#e09525',
579 'hover' => '#E0D2BD',
580 ),
581 ),
582
583 array(
584 'id' => 'dark_mode_input_color_set10',
585 'type' => 'color_group',
586 'title' => esc_html__('Input', 'darkify'),
587 'title_help' =>
588 '<div class="darkify-info-label">' .
589 __('Set the input field colors of your website when dark mode is enabled.', 'darkify') .
590 '</div>',
591
592 'options' => array(
593 'color' => esc_html__('Input Text', 'darkify'),
594 'placeholder' => esc_html__('Input Placeholder', 'darkify'),
595 'background' => esc_html__('Input Background', 'darkify'),
596 ),
597
598 'class' => 'only_pro',
599 'dependency' => array('color_pallets', '==', 'set10', 'all'),
600
601 'default' => array(
602 'color' => '#E0D2BD',
603 'placeholder' => '#E0D2BD',
604 'background' => '#372911',
605 ),
606 ),
607
608 array(
609 'id' => 'dark_mode_border_color_set10',
610 'type' => 'color',
611 'title' => esc_html__('Border', 'darkify'),
612 'title_help' =>
613 '<div class="darkify-info-label">' .
614 __('Set the border color of your website when dark mode is enabled.', 'darkify') .
615 '</div>',
616
617 'class' => 'only_pro',
618 'dependency' => array('color_pallets', '==', 'set10', 'all'),
619 'default' => '#5D4010',
620 ),
621 array(
622 'id' => 'dark_mode_btn_color_set10',
623 'type' => 'color_group',
624 'title' => esc_html__('Button', 'darkify'),
625 'title' => esc_html__('Button', 'darkify'),
626 'title_help' =>
627 '<div class="darkify-info-label">' .
628 __('Set the color of buttons on your website when dark mode is enabled.', 'darkify') .
629 '</div>',
630 'options' => array(
631 'color' => esc_html__('Button Text', 'darkify'),
632 'background' => esc_html__('Button Background', 'darkify'),
633 'hover_color' => esc_html__('Hover Text', 'darkify'),
634 'hover_background' => esc_html__('Hover Background', 'darkify'),
635 ),
636
637 'class' => 'only_pro',
638 'dependency' => array('color_pallets', '==', 'set10', 'all'),
639 'default' => array(
640 'color' => '#E0D2BD',
641 'background' => '#5D4010',
642 'hover_color' => '#E0D2BD',
643 'hover_background' => '#372911',
644 ),
645 ),
646 // color pallate set 11
647 array(
648 'id' => 'dark_mode_color_set11',
649 'type' => 'color_group',
650 'title' => esc_html__('Background', 'darkify'),
651 'title_help' =>
652 '<div class="darkify-info-label">' .
653 __('Set the background color of your website when dark mode is enabled.', 'darkify') .
654 '</div>',
655 'options' => array(
656 'background' => esc_html__('Primary BG', 'darkify'),
657 'secondary_background' => esc_html__('Secondary BG', 'darkify'),
658 ),
659
660 'dependency' => array('color_pallets', '==', 'set11', 'all'),
661
662 'default' => array(
663 'background' => '#19081b',
664 'secondary_background' => '#210a24',
665 ),
666 ),
667 array(
668 'id' => 'dark_mode_link_color_set11',
669 'type' => 'color_group',
670 'title' => esc_html__('Text', 'darkify'),
671 'title_help' =>
672 '<div class="darkify-info-label">' .
673 __('Set the text color of your website when dark mode is enabled.', 'darkify') .
674 '</div>',
675 'options' => array(
676 'text' => esc_html__('Text Color', 'darkify'),
677 'color' => esc_html__('Link Color', 'darkify'),
678 'hover' => esc_html__('Link Hover Color', 'darkify'),
679 ),
680
681 'class' => 'only_pro',
682 'dependency' => array('color_pallets', '==', 'set11', 'all'),
683
684 'default' => array(
685 'text' => '#c09dc2',
686 'color' => '#c832d4',
687 'hover' => '#c09dc2',
688 ),
689 ),
690
691 array(
692 'id' => 'dark_mode_input_color_set11',
693 'type' => 'color_group',
694 'title' => esc_html__('Input', 'darkify'),
695 'title_help' =>
696 '<div class="darkify-info-label">' .
697 __('Set the input field colors of your website when dark mode is enabled.', 'darkify') .
698 '</div>',
699 'options' => array(
700 'color' => esc_html__('Input Text', 'darkify'),
701 'placeholder' => esc_html__('Input Placeholder', 'darkify'),
702 'background' => esc_html__('Input Background', 'darkify'),
703 ),
704
705 'class' => 'only_pro',
706 'dependency' => array('color_pallets', '==', 'set11', 'all'),
707
708 'default' => array(
709 'color' => '#c09dc2',
710 'placeholder' => '#c09dc2',
711 'background' => '#2c082f',
712 ),
713 ),
714
715 array(
716 'id' => 'dark_mode_border_color_set11',
717 'type' => 'color',
718 'title' => esc_html__('Border', 'darkify'),
719 'title_help' =>
720 '<div class="darkify-info-label">' .
721 __('Set the border color of your website when dark mode is enabled.', 'darkify') .
722 '</div>',
723
724 'class' => 'only_pro',
725 'dependency' => array('color_pallets', '==', 'set11', 'all'),
726 'default' => '#440649',
727 ),
728 array(
729 'id' => 'dark_mode_btn_color_set11',
730 'type' => 'color_group',
731 'title' => esc_html__('Button', 'darkify'),
732 'title_help' =>
733 '<div class="darkify-info-label">' .
734 __('Set the button colors of your website when dark mode is enabled.', 'darkify') .
735 '</div>',
736
737 'options' => array(
738 'color' => esc_html__('Text Color', 'darkify'),
739 'background' => esc_html__('Background', 'darkify'),
740 'hover_color' => esc_html__('Hover Text Color', 'darkify'),
741 'hover_background' => esc_html__('Hover Background', 'darkify'),
742 ),
743
744 'class' => 'only_pro',
745 'dependency' => array('color_pallets', '==', 'set11', 'all'),
746
747 'default' => array(
748 'color' => '#c09dc2',
749 'background' => '#440649',
750 'hover_color' => '#c09dc2',
751 'hover_background' => '#2c082f',
752 ),
753 ),
754 )
755 ),
756
757 array(
758 'id' => 'fine-tuning',
759 'title' => esc_html__('Fine-Tuning', 'darkify'),
760 'icon' => 'icofont-options',
761 'fields' => array(
762 // Intro line, rendered plain above the section card.
763 array(
764 'type' => 'page_hint',
765 'content' => esc_html__('Control how gradients, brand colors and shadows are treated in dark mode, and pin individual colors to a dark-mode replacement.', 'darkify'),
766 ),
767
768 // ===== GRADIENTS =====
769 array(
770 'type' => 'heading',
771 'title' => esc_html__('Gradients', 'darkify'),
772 'section_start' => true,
773 ),
774 array(
775 'id' => 'gradient_handling',
776 'type' => 'select',
777 'title' => esc_html__('Gradient Backgrounds', 'darkify'),
778 'title_help' =>
779 '<div class="darkify-info-label">' .
780 __('A gradient lives in a different CSS property than a solid color, so it is not covered by the dark-mode color set. Recoloring runs every color stop through the same dark ramp a solid background gets, which is what keeps a gradient section and a solid section next to it looking like one design.', 'darkify') .
781 '</div>',
782
783 'options' => array(
784 'recolor' => esc_html__('Recolor gradient stops (recommended)', 'darkify'),
785 'flatten' => esc_html__('Replace gradient with a flat dark background', 'darkify'),
786 'keep' => esc_html__('Leave gradients untouched', 'darkify'),
787 ),
788 'default' => 'recolor',
789 ),
790
791 // ===== SHADOWS =====
792 array(
793 'type' => 'heading',
794 'title' => esc_html__('Shadows', 'darkify'),
795 'section_start' => true,
796 ),
797 array(
798 'id' => 'shadow_handling',
799 'type' => 'select',
800 'title' => esc_html__('Box & Text Shadows', 'darkify'),
801 'title_help' =>
802 '<div class="darkify-info-label">' .
803 __('A colored shadow designed for a light page stays lit on a dark one and cancels out the dimming. Neutralizing keeps the shadow geometry — so cards keep their depth — but drops the color.', 'darkify') .
804 '</div>',
805
806 'options' => array(
807 'neutralize' => esc_html__('Neutralize color, keep depth (recommended)', 'darkify'),
808 'map' => esc_html__('Use the color overrides below, then neutralize', 'darkify'),
809 'remove' => esc_html__('Remove shadows entirely', 'darkify'),
810 'keep' => esc_html__('Leave shadows untouched', 'darkify'),
811 ),
812 'default' => 'neutralize',
813 ),
814
815 // ===== BRAND COLORS =====
816 array(
817 'type' => 'heading',
818 'title' => esc_html__('Brand Colors', 'darkify'),
819 'section_start' => true,
820 ),
821 array(
822 'id' => 'brand_color_handling',
823 'type' => 'select',
824 'title' => esc_html__('Accent & Icon Colors', 'darkify'),
825 'title_help' =>
826 '<div class="darkify-info-label">' .
827 __('Controls brand colors only — accents, icons, buttons, colored panels. Adaptive keeps each color\'s hue while matching its depth to the preset above, so an intense accent stays on-brand without glowing. This is not an inversion: a blue icon stays blue. Plain light and grey backgrounds always follow your preset either way.', 'darkify') .
828 '</div>',
829
830 'options' => array(
831 'adaptive' => esc_html__('Keep brand hues, matched to your preset (recommended)', 'darkify'),
832 'flatten' => esc_html__('Replace brand colors with the preset colors', 'darkify'),
833 ),
834 'default' => 'adaptive',
835 ),
836
837 // ===== MANUAL COLOR OVERRIDES =====
838 array(
839 'type' => 'heading',
840 'title' => esc_html__('Color Overrides', 'darkify'),
841 'section_start' => true,
842 ),
843 array(
844 'id' => 'color_overrides',
845 'type' => 'repeater',
846 'class' => 'replacement_repeater repeater_pro_only',
847 'title' => esc_html__('Replace Individual Colors', 'darkify'),
848 'title_help' =>
849 '<div class="darkify-info-label">' .
850 __('Pin one light-mode color to an exact dark-mode color. Overrides are matched against the color the element actually renders with, and they apply whatever the settings above are set to — so a handful of colors can be pinned without switching the whole site to adaptive.', 'darkify') .
851 '</div>',
852
853 'fields' => array(
854 array(
855 'id' => 'light_color',
856 'type' => 'color',
857 'title' => esc_html__('Light Mode Color', 'darkify'),
858 ),
859 array(
860 'id' => 'dark_color',
861 'type' => 'color',
862 'title' => esc_html__('Dark Mode Color', 'darkify'),
863 ),
864 array(
865 'id' => 'override_scope',
866 'type' => 'select',
867 'title' => esc_html__('Apply To', 'darkify'),
868 'options' => array(
869 'all' => esc_html__('Everywhere', 'darkify'),
870 'text' => esc_html__('Text only', 'darkify'),
871 'icon' => esc_html__('Icons only', 'darkify'),
872 'background' => esc_html__('Backgrounds only', 'darkify'),
873 'border' => esc_html__('Borders only', 'darkify'),
874 'shadow' => esc_html__('Shadows only', 'darkify'),
875 ),
876 'default' => 'all',
877 ),
878 ),
879
880 'default' => array(
881 array(
882 'light_color' => '',
883 'dark_color' => '',
884 'override_scope' => 'all',
885 ),
886 ),
887 ),
888 )
889 ),
890
891 array(
892 'id' => 'scroll-bar',
893 'title' => esc_html__('Scroll Bar', 'darkify'),
894 'icon' => 'icofont-scroll-double-down',
895 'fields' => array(
896 // Intro line, rendered plain above the section card.
897 array(
898 'type' => 'page_hint',
899 'content' => esc_html__('Style the browser scrollbar to match dark mode.', 'darkify'),
900 ),
901 // ===== SCROLLBAR =====
902 array(
903 'type' => 'heading',
904 'title' => esc_html__('Scrollbar', 'darkify'),
905 'section_start' => true,
906 ),
907 array(
908 'id' => 'enable_scrollbar_dark',
909 'type' => 'switcher',
910 'title' => esc_html__('Enable Dark Mode on Scrollbar', 'darkify'),
911 'title_help' =>
912 '<div class="darkify-info-label">' .
913 __('Enable dark mode styling for the website scrollbar.', 'darkify') .
914 '</div>',
915
916 'text_on' => esc_html__('Enabled', 'darkify'),
917 'text_off' => esc_html__('Disabled', 'darkify'),
918 'text_width' => 100,
919 'default' => true,
920 ),
921
922 array(
923 'id' => 'scrollbar_color',
924 'type' => 'color_group',
925 'title' => esc_html__('Scrollbar Color', 'darkify'),
926 'title_help' =>
927 '<div class="darkify-info-label">' .
928 __('Set the track and thumb background colors of the scrollbar when dark mode is enabled.', 'darkify') .
929 '</div>',
930
931 'options' => array(
932 'dark_mode_scrollbar_track_bg' => esc_html__('Track Background', 'darkify'),
933 'dark_mode_scrollbar_thumb_bg' => esc_html__('Thumb Background', 'darkify'),
934 ),
935
936 'class' => 'only_pro',
937
938 'default' => array(
939 'dark_mode_scrollbar_track_bg' => '#29292a',
940 'dark_mode_scrollbar_thumb_bg' => '#52565a',
941 ),
942 'dependency' => array('enable_scrollbar_dark', '==', 'true'),
943 ),
944
945
946 )
947 ),
948
949
950 )
951 ),
952 ),
953 )
954 );
955 }
956 }
957