Debian Codegraph @

gtk/theme/Default/_common.scss

raw
1 @function gtkalpha($c,$a) {
2 @return unquote("rgb(from #{$c} r g b / calc(alpha * #{$a}))");
3 }
4
5 $ease-out-quad: cubic-bezier(0.25, 0.46, 0.45, 0.94);
6 $asset_suffix: if($variant=='dark', '-dark', '');
7 $asset_prefix: if($contrast=='normal', '', 'hc-');
8 $assets: 'assets';
9 $backdrop_transition: 200ms ease-out;
10 $button_transition: all 200ms $ease-out-quad;
11 $focus_transition: outline-width 200ms $ease-out-quad, outline-offset 200ms $ease-out-quad;
12 $button_radius: 5px;
13 $menu_radius: 5px;
14 $menu_margin: $menu_radius; //margin around menuitems & sidebar items
15 $window_radius: $button_radius + 3;
16 $popover_radius: $button_radius + 4;
17
18 /***************
19 * Base States *
20 ***************/
21 .background {
22 color: $fg_color;
23 background-color: $bg_color;
24
25 &:backdrop {
26 text-shadow: none;
27 -gtk-icon-shadow: none;
28 }
29 }
30
31 dnd {
32 color: $fg-color;
33 }
34
35 .normal-icons {
36 -gtk-icon-size: 16px;
37 }
38
39 .large-icons {
40 -gtk-icon-size: 32px;
41 }
42
43 image:disabled {
44 -gtk-icon-filter: opacity(0.5);
45 }
46
47 picture:disabled {
48 opacity: 0.5;
49 }
50
51 .view,
52 %view {
53 color: $text_color;
54 background-color: $base_color;
55
56 &:disabled {
57 color: $insensitive_fg_color;
58 background-color: $insensitive_bg_color;
59 }
60
61 &:selected {
62 &:focus, & {
63 @extend %selected_items;
64
65 border-radius: 3px;
66 }
67 }
68 }
69
70 textview {
71 > text {
72 @extend %view;
73
74 background-color: transparent;
75
76 > selection {
77 background-color: $backdrop_selected_bg_color;
78
79 &:focus-within {
80 background-color: $selected_text_bg_color;
81 }
82 }
83 }
84
85 &:drop(active) {
86 caret-color: $drop_target_color;
87 }
88 }
89
90 textview > border { background-color: mix($bg_color, $base_color, 50%); }
91
92 iconview {
93 @extend .view;
94
95 @include focus-ring();
96
97 @if $contrast == 'high' {
98 &:selected {
99 box-shadow: inset 0 0 0 1px $borders_color;
100 }
101 }
102
103
104 &:drop(active) {
105 box-shadow: none;
106 }
107
108 > dndtarget:drop(active) {
109 border-style: solid;
110 border-width: 1px;
111 border-color: $selected_borders_color;
112 }
113 }
114
115 rubberband {
116 border: 1px solid darken($selected_bg_color, 10%);
117 background-color: transparentize(darken($selected_bg_color, 10%), 0.8);
118 }
119
120 flowbox {
121 > rubberband { @extend rubberband; }
122
123 > flowboxchild {
124 padding: 3px;
125 transition: $focus_transition;
126
127 @include focus-ring();
128
129 &:selected {
130 outline-color: $alt_focus_border_color;
131
132 @extend %selected_items;
133 }
134 }
135 }
136
137 gridview {
138 > rubberband { @extend rubberband; }
139
140 > child {
141 padding: 3px;
142 transition: $focus_transition;
143
144 @include focus-ring();
145
146 &:selected {
147 outline-color: $alt_focus_border_color;
148
149 @extend %selected_items;
150
151 @if $contrast == 'high' {
152 box-shadow: inset 0 0 0 1px $borders_color;
153 }
154
155 }
156
157 box { //cells
158 border-spacing: 8px; //label separation
159 margin: 12px;
160 }
161 }
162 }
163
164 coverflow cover {
165 color: $text_color;
166 background-color: $base_color;
167 border: 1px solid black;
168 }
169
170 label {
171 @include focus-ring();
172
173 &.separator {
174 @extend .dim-label;
175 }
176
177 &:selected { @extend %nobg_selected_items; }
178
179 > selection {
180 background-color: $backdrop_selected_bg_color;
181 color: transparent;
182 &:focus-within {
183 background-color: $selected_text_bg_color;
184 }
185 }
186
187 &:disabled {
188 color: $insensitive_fg_color;
189
190 button & { color: inherit; }
191
192 > selection { @extend %selected_items_disabled; }
193 }
194
195 &.error {
196 color: $error_color;
197 &:disabled { color: transparentize($error_color,0.5); }
198 }
199 }
200
201 .dim-label {
202 opacity: $dim_label_opacity;
203 text-shadow: none;
204 }
205
206 window.assistant {
207 .sidebar {
208 padding: $menu-margin;
209 border-top: 1px solid $borders_color;
210 }
211
212 &.csd .sidebar { border-top-style: none; }
213
214 .sidebar > label { padding: 6px 12px; }
215
216 .sidebar > label.highlight {
217 background-color: $menu_selected_color;
218 border-radius: $menu-margin;
219 }
220 }
221
222 window.aboutdialog image.large-icons {
223 -gtk-icon-size: 128px;
224 }
225
226 %osd,
227 .osd {
228 color: $osd_fg_color;
229 border: none;
230 background-color: $osd_bg_color;
231 background-clip: padding-box;
232 -gtk-icon-shadow: 0 1px black;
233
234 }
235
236
237 /*********************
238 * Spinner Animation *
239 *********************/
240 @keyframes spin {
241 to { transform: rotate(1turn); }
242 }
243
244 spinner {
245 background: none;
246 opacity: 0; // non spinning spinner makes no sense
247 -gtk-icon-source: -gtk-icontheme('process-working-symbolic');
248
249 &:checked {
250 opacity: 1;
251 animation: spin 1s linear infinite;
252
253 &:disabled { opacity: 0.5; }
254 }
255 }
256
257 /**********************
258 * General Typography *
259 **********************/
260
261 .large-title {
262 font-weight: 300;
263 font-size: 240%;
264 }
265 .title-1 {
266 font-weight: 800;
267 font-size: 200%;
268 }
269 .title-2 {
270 font-weight: 800;
271 font-size: 150%;
272 }
273 .title-3 {
274 font-weight: 700;
275 font-size: 150%;
276 }
277 .title-4 {
278 font-weight: 700;
279 font-size: 130%;
280 }
281 .heading {
282 font-weight: 700;
283 font-size: 110%;
284 }
285 .body {
286 font-weight: 400;
287 font-size: 110%;
288 }
289 .caption-heading {
290 font-weight: 700;
291 font-size: 90%;
292 }
293 .caption {
294 font-weight: 400;
295 font-size: 90%;
296 }
297
298 /****************
299 * Text Entries *
300 ****************/
301
302 %entry,
303 entry {
304 %entry_basic, & {
305 min-height: 32px;
306 padding-left: 8px;
307 padding-right: 8px;
308 border: 1px solid;
309 border-radius: $button_radius;
310 border-spacing: 6px;
311 transition: all 200ms $ease-out-quad;
312
313 @include entry(normal);
314
315 @include focus-ring($focus-state: 'focus-within');
316
317 > image { // icons inside the entry
318 &.left { margin-right: 6px; }
319 &.right { margin-left: 6px; }
320 }
321
322 > text > placeholder {
323 @extend .dim-label;
324 @if $contrast == 'high' { font-style: italic; }
325 }
326
327 > text > block-cursor {
328 @include entry(block_cursor);
329 }
330
331 &.flat {
332 &:focus-within, &:backdrop, &:disabled, &:backdrop:disabled, & {
333 min-height: 0;
334 padding: 2px;
335 background-color: transparent;
336 border-color: transparent;
337 border-radius: 0;
338 }
339 }
340
341 &:focus-within {
342 @include entry(focus);
343 > placeholder {
344 opacity: 0; /* We hide placeholders on focus */
345 }
346 }
347
348 &:disabled { @include entry(insensitive); }
349
350 > text > selection {
351 background-color: $backdrop_selected_bg_color;
352 color: transparent;
353 &:focus-within {
354 background-color: $selected_text_bg_color;
355 color: $fg_color;
356 }
357 }
358
359 // entry error and warning style
360 @each $e_type, $e_color in (error, $error_color),
361 (warning, $warning_color) {
362 &.#{$e_type} {
363 color: $e_color;
364
365 @include focus-ring($focus-state: 'focus-within', $fc: transparentize($e_color, 0.5));
366
367 &:focus-within { @include entry(focus, $e_color); }
368
369 > selection { background-color: $e_color; }
370 }
371 }
372
373 > image { // entry icons colors
374 color: mix($fg_color, $base_color, 80%);
375
376 &:hover { color: $fg_color; }
377
378 &:active { color: $selected_bg_color; }
379
380 }
381
382 &.password image.caps-lock-indicator {
383 color: mix($backdrop_fg_color, $backdrop_base_color, 80%);
384 }
385
386 &:drop(active) {
387 &:focus-within, & {
388 border-color: $drop_target_color;
389 box-shadow: inset 0 0 0 1px $drop_target_color;
390 }
391 }
392
393 .osd & {
394 @include entry(osd);
395
396 &:focus-within { @include entry(osd-focus); }
397
398 &:disabled { @include entry(osd-insensitive); }
399 }
400 }
401
402 > progress {
403 margin-bottom: 2px;
404 }
405
406 > progress > trough {
407 min-height: 2px;
408 }
409
410 > progress > trough > progress {
411 background-color: transparent;
412 background-image: none;
413 border-radius: 0;
414 border-width: 0 0 2px;
415 border-color: $selected_bg_color;
416 border-style: solid;
417 box-shadow: none;
418 }
419
420 // linked entries
421 .linked:not(.vertical) > & { @extend %linked; }
422
423 .linked:not(.vertical) > &:drop(active) + &,
424 .linked:not(.vertical) > &:drop(active) + button,
425 .linked:not(.vertical) > &:drop(active) + menubutton > button,
426 .linked:not(.vertical) > &:drop(active) + dropdown > button,
427 .linked:not(.vertical) > &:drop(active) + colorbutton > button,
428 .linked:not(.vertical) > &:drop(active) + fontbutton > button,
429 .linked:not(.vertical) > &:drop(active) + filechooserbutton > button,
430 .linked:not(.vertical) > &:drop(active) + filechooserbutton > combobox > box > button.combo,
431 .linked:not(.vertical) > &:drop(active) + appchooserbutton > combobox > box > button.combo,
432 .linked:not(.vertical) > &:drop(active) + combobox > box > button.combo { border-left-color: $drop_target_color; }
433
434 // Vertically linked entries
435 // FIXME: take care of "colored" entries
436 .linked.vertical > & {
437 @extend %linked_vertical;
438
439 // brighter border between linked entries
440 &:not(:disabled) + entry:not(:disabled),
441 &:not(:disabled) + %entry:not(:disabled) {
442 border-top-color: mix($borders_color, $base_color, 30%);
443 }
444
445 // brighter border between linked insensitive entries
446 &:disabled + %entry:disabled,
447 &:disabled + entry:disabled { border-top-color: mix($borders_color, $base_color, 30%); }
448
449 + %entry:drop(active):not(:only-child),
450 + entry:drop(active):not(:only-child) { border-top-color: $drop_target_color; }
451
452 &:drop(active):not(:only-child) {
453 + %entry,
454 + entry,
455 + button,
456 + menubutton > button,
457 + dropdown > button,
458 + colorbutton > button,
459 + fontbutton > button,
460 + filechooserbutton > button,
461 + filechooserbutton > combobox > box > button.combo,
462 + appchooserbutton > combobox > box > button.combo,
463 + combobox > box > button.combo { border-top-color: $drop_target_color; }
464 }
465 }
466
467 &.error { color: $error_color; }
468 }
469
470 treeview entry {
471 &:focus-within {
472 &:dir(rtl), &:dir(ltr) { // specificity bump hack
473 background-color: $base_color;
474 transition-property: color, background;
475 }
476 }
477
478 &.flat, & {
479 border-radius: 0;
480 background-image: none;
481 background-color: $base_color;
482
483 &:focus-within { border-color: $selected_bg_color; }
484 }
485 }
486
487 /*******************
488 * Editable Labels *
489 *******************/
490 editablelabel > stack > text {
491 @include entry(normal);
492
493 > selection {
494 background-color: $backdrop_selected_bg_color;
495 color: transparent;
496 &:focus-within {
497 background-color: $selected_text_bg_color;
498 color: $fg_color;
499 }
500 }
501 }
502
503 /***********
504 * Buttons *
505 ***********/
506 // stuff for .needs-attention
507 $_dot_color: if($variant=='light', $selected_bg_color,
508 lighten($selected_bg_color,15%));
509 @keyframes needs_attention {
510 from { background-image: radial-gradient(farthest-side, $_dot_color 0%, transparentize($_dot_color, 1) 0%); }
511 to { background-image: radial-gradient(farthest-side, $_dot_color 95%, transparentize($_dot_color, 1)); }
512 }
513
514 %button,
515 button {
516 @at-root %button_basic, & {
517
518 min-height: 24px;
519 min-width: 16px;
520 padding: 4px 9px;
521 border: 1px solid;
522 border-radius: $button_radius;
523 transition: $button_transition;
524
525 @include button(normal);
526
527 @include focus-ring();
528
529 &:hover {
530 @include button(hover);
531 -gtk-icon-filter: brightness(1.2);
532 }
533
534 &.keyboard-activating,
535 &:active,
536 &:checked {
537 @include button(active);
538
539 transition-duration: 50ms;
540 }
541
542 &:checked:hover { @include button(checked-hover); }
543 &:checked:active { @include button(checked-active); }
544
545 &:backdrop {
546 &.flat, & {
547 @include button(backdrop);
548
549 transition: $backdrop_transition;
550
551 &:not(:disabled) { -gtk-icon-filter: none; }
552
553 &:active,
554 &:checked { @include button(backdrop-active); }
555
556 &:disabled {
557 @include button(backdrop-insensitive);
558
559 &:active,
560 &:checked { @include button(backdrop-insensitive-active); }
561 }
562 }
563 }
564
565 &:disabled {
566 @include button(insensitive);
567 -gtk-icon-filter: opacity(0.5);
568
569 &:active,
570 &:checked { @include button(insensitive-active); }
571 }
572
573 @at-root %button_basic_flat,
574 &.flat {
575 @include button(undecorated);
576 // to avoid adjacent buttons borders clashing when transitioning, the transition on the normal state is set
577 // to none, while it's added back in the hover state, so the button decoration will fade in on hover, but
578 // it won't fade out when the pointer leave the button allocation area. To make the transition more evident
579 // in this case the duration is increased.
580 transition: none;
581
582 &:hover {
583 @include button(undecorated-hover);
584 transition: $button_transition;
585 transition-duration: 500ms;
586 }
587 &.keyboard-activating,
588 &:active,
589 &:checked {
590 @include button(undecorated-active);
591 transition: $button_transition;
592 }
593 &:backdrop, &:disabled, &:backdrop:disabled { @include button(undecorated); }
594 }
595
596 &.image-button {
597 min-width: 24px;
598 padding-left: 5px;
599 padding-right: 5px;
600 }
601
602 &.text-button {
603 padding-left: 16px;
604 padding-right: 16px;
605 }
606
607 &.text-button.image-button {
608 padding-left: 8px;
609 padding-right: 8px;
610
611 label {
612 padding-left: 8px;
613 padding-right: 8px;
614 }
615 }
616
617 &.arrow-button {
618 padding-left: 10px;
619 padding-right: 10px;
620
621 > box {
622 border-spacing: 4px;
623 }
624 }
625
626 @at-root %button_basic_drop_active,
627 &:drop(active) {
628 color: $drop_target_color;
629 border-color: $drop_target_color;
630 box-shadow: inset 0 0 0 1px $drop_target_color;
631 }
632 }
633
634 @at-root %button_selected, & {
635 row:selected & {
636 @if $variant == 'light' { border-color: $selected_borders_color; }
637 }
638
639 @at-root %button_selected_flat, &.flat {
640 row:selected & {
641 &:not(:active):not(:checked):not(:hover):not(disabled) {
642 color: $selected_fg_color;
643 border-color: transparent;
644
645 &:backdrop { color: if($variant=='light', $backdrop_base_color, $backdrop_fg_color); }
646 }
647 }
648 }
649 }
650
651
652 // big standalone buttons like in Documents pager
653 &.osd {
654 min-width: 26px;
655 min-height: 32px;
656
657 &.image-button {
658 min-width: 30px;
659 &:only-child {
660 margin: 4px;
661 border-radius: 50%; // completely round when it is a single button
662 box-shadow: 0 1px 2px transparentize(black, 0.8); // drop shadow for the only child
663 };
664 }
665
666 color: $osd_fg_color;
667 border-radius: 5px;
668
669 @include button(osd);
670
671 border: none;
672 box-shadow: none;
673
674 &:hover {
675 @include button(osd-hover);
676
677 border: none;
678 box-shadow: none;
679 }
680
681 &:active,
682 &:checked {
683 @include button(osd-active);
684
685 border: none;
686 box-shadow: none;
687 }
688 }
689
690 //overlay / OSD style
691 @at-root %osd_button,
692 .osd & {
693 @include button(osd);
694
695 &:hover { @include button(osd-hover); }
696
697 &:active,
698 &:checked { &:backdrop, & { @include button(osd-active); }}
699
700 &:disabled { &:backdrop, & { @include button(osd-insensitive); }}
701
702 &.flat {
703 @include button(undecorated);
704
705 box-shadow: none;
706 -gtk-icon-shadow: 0 1px black;
707
708 &:hover { @include button(osd-hover); }
709
710 &:disabled {
711 @include button(osd-insensitive);
712 background-image: none;
713 border-color: transparent;
714 box-shadow: none;
715 }
716
717 &:active,
718 &:checked { @include button(osd-active); }
719 }
720 }
721
722 // Suggested and Destructive Action buttons
723 @each $b_type, $b_color in (suggested-action, $selected_bg_color),
724 (destructive-action, $destructive_color) {
725 &.#{$b_type} {
726 @include button(normal, $b_color, white);
727 @include focus-ring($fc: $alt_focus_border_color);
728
729 &.flat {
730 @include button(undecorated);
731
732 color: $b_color; //FIXME: does it work on the dark variant?
733 }
734
735 &:hover { @include button(hover, $b_color, white); }
736
737 &:active,
738 &:checked { @include button(active, $b_color, white); }
739
740 &.flat {
741 &:disabled {
742 @include button(undecorated);
743
744 color: transparentize($b_color, 0.2);
745 }
746 }
747
748 &:disabled {
749 @include button(insensitive);
750
751 &:active,
752 &:checked { @include button(insensitive-active, $b_color, white); }
753 }
754
755 .osd & {
756 @include button(osd, $b_color);
757
758 &:hover { @include button(osd-hover, $b_color); }
759
760 &:active,
761 &:checked { &:backdrop, & { @include button(osd-active, $b_color); }}
762
763 &:disabled { &:backdrop, & { @include button(osd-insensitive, $b_color); }}
764
765 }
766 }
767 }
768
769 stackswitcher > & {
770 // to position the needs attention dot, padding is added to the button
771 // child, a label needs just lateral padding while an icon needs vertical
772 // padding added too.
773
774 > label {
775 padding: 0 6px;
776 margin: 0 -6px;
777 }
778
779 > image {
780 padding: 3px 6px;
781 margin: -3px -6px;
782 }
783
784 &.needs-attention {
785 > label,
786 > image { @extend %needs_attention; }
787 }
788 }
789
790 // hide separators
791 &.font{
792 separator { background-color: transparent; }
793 > box { border-spacing: 6px; }
794 > box > box > label { font-weight: bold; }
795 }
796
797 .linked:not(.vertical) > & { @extend %linked; }
798
799 .linked.vertical > & { @extend %linked_vertical; }
800
801 menubutton.circular &,
802 &.circular { // force circular button shape
803 min-width: 32px;
804 min-height: 32px;
805 padding: 0;
806 border-radius: 9999px;
807
808 label { padding: 0; }
809 }
810 }
811
812 %needs_attention {
813 // the dot is drawn by using two radial gradient, the first one is the actual dot, the other
814 // simulates the shadow labels and icons normally have in buttons.
815 animation: needs_attention 150ms ease-in;
816
817 background-image: radial-gradient(farthest-side, $_dot_color 96%, transparentize($_dot_color,1 ));
818 background-size: 6px 6px, 6px 6px;
819 background-repeat: no-repeat;
820
821 @if $variant == 'light' { background-position: right 3px, right 4px; }
822
823 @else { background-position: right 3px, right 2px; }
824
825 &:backdrop { background-size: 6px 6px, 0 0;}
826
827 &:dir(rtl) {
828 @if $variant == 'light' { background-position: left 3px, left 4px; }
829
830 @else { background-position: left 3px, left 2px; }
831 }
832 }
833
834
835 %linked_not_left {
836 border-top-left-radius: 0;
837 border-bottom-left-radius: 0;
838 }
839
840 %linked_not_right {
841 border-right-style: none;
842 border-top-right-radius: 0;
843 border-bottom-right-radius: 0;
844 }
845
846 // 1st/last child are at text start/end
847 %linked {
848 &:dir(ltr) {
849 &:not(:first-child) { @extend %linked_not_left; }
850 &:not(:last-child) { @extend %linked_not_right; }
851 }
852
853 &:dir(rtl) {
854 &:not(:first-child) { @extend %linked_not_right; }
855 &:not(:last-child) { @extend %linked_not_left; }
856 }
857 }
858
859 %linked_not_top {
860 border-top-left-radius: 0;
861 border-top-right-radius: 0;
862 }
863
864 %linked_not_bottom {
865 border-bottom-style: none;
866 border-bottom-left-radius: 0;
867 border-bottom-right-radius: 0;
868 }
869
870 %linked_vertical {
871 &:not(:first-child) { @extend %linked_not_top; }
872
873 &:not(:last-child) { @extend %linked_not_bottom; }
874 }
875
876 %undecorated_button {
877 background-color: transparent;
878 background-image: none;
879 border-color: transparent;
880 box-shadow: inset 0 1px transparentize(white, 1),
881 0 1px transparentize(white, 1);
882 text-shadow: none;
883 -gtk-icon-shadow: none;
884 }
885
886 .linked:not(.vertical) > menubutton,
887 .linked:not(.vertical) > dropdown,
888 .linked:not(.vertical) > colorbutton,
889 .linked:not(.vertical) > fontbutton,
890 .linked:not(.vertical) > filechooserbutton {
891 &:dir(ltr) {
892 &:not(:first-child) > button { @extend %linked_not_left; }
893 &:not(:last-child) > button { @extend %linked_not_right; }
894 }
895
896 &:dir(rtl) {
897 &:not(:first-child) > button { @extend %linked_not_right; }
898 &:not(:last-child) > button { @extend %linked_not_left; }
899 }
900 }
901
902 .linked.vertical > menubutton,
903 .linked.vertical > dropdown,
904 .linked.vertical > colorbutton,
905 .linked.vertical > fontbutton,
906 .linked.vertical > filechooserbutton {
907 &:not(:first-child) > button { @extend %linked_not_top; }
908 &:not(:last-child) > button { @extend %linked_not_bottom; }
909 }
910
911 /* menu buttons */
912 modelbutton.flat {
913 min-height: 26px;
914 padding-left: 5px;
915 padding-right: 5px;
916 border-radius: $button_radius;
917
918 @extend %undecorated_button;
919
920 &:hover { background-color: $menu_selected_color; }
921
922 &:disabled {
923 color: $insensitive_fg_color;
924
925
926 }
927
928 &:selected { @extend %selected_items; }
929 }
930
931 modelbutton.flat arrow {
932 background: none;
933 min-width: 16px;
934 min-height: 16px;
935 opacity: 0.3; //dim icon
936
937 &:hover { background: none; }
938
939 &.left { -gtk-icon-source: -gtk-icontheme("go-previous-symbolic"); }
940
941 &.right { -gtk-icon-source: -gtk-icontheme("go-next-symbolic"); }
942 }
943
944 /* oldstyle toolbar buttons */
945
946 .toolbar > button,
947 .toolbar > :not(.linked) > button,
948 .toolbar :not(.linked) > menubutton > button,
949 .toolbar :not(.linked) > scalebutton > button,
950 .toolbar :not(.linked) > dropdown > button,
951 .toolbar :not(.linked) > colorbutton > button,
952 .toolbar :not(.linked) > fontbutton > button,
953 .toolbar :not(.linked) > appchooserbutton > button,
954 .toolbar :not(.linked) > combobox > box > button {
955 margin: 1px;
956
957 @extend %button_basic_flat;
958
959 &:hover { @include button(undecorated-hover, $c:darken($bg_color, 4%)); }
960 &:active,
961 &:checked { @include button(undecorated-active, $c:darken($bg_color, 4%)); }
962 }
963
964 button.color {
965 padding: 4px;
966
967 > colorswatch:only-child {
968 &, > overlay { border-radius: 0; }
969
970 @if $variant == 'light' {
971 box-shadow: 0 1px $shadow_color;
972
973 .osd & { box-shadow: none; }
974 }
975 }
976
977 @if $variant == 'light' {
978 .osd &, & {
979 &:disabled,
980 &:active,
981 &:checked { colorswatch:only-child { box-shadow: none; }}
982 }
983 }
984 }
985
986 /* list buttons */
987 /* tone down as per new designs, see issue #1473 */
988 %list_button,
989 list > row button.image-button:not(.flat) {
990 @extend %undecorated_button;
991 border: 1px solid transparentize($borders_color, .5);
992 &:hover { @include button(hover); }
993 &:active,
994 &:checked { @include button(active); }
995
996 @each $b_type, $b_color in (suggested-action, $selected_bg_color),
997 (destructive-action, $destructive_color) {
998 &.#{$b_type} { // allow colored buttons in lists #3643
999 @include button(normal, $b_color, white);
1000 @include focus-ring($fc: $alt_focus_border_color);
1001 }
1002 }
1003 }
1004
1005 /*********
1006 * Links *
1007 *********/
1008
1009 %link,
1010 link {
1011 color: $link_color;
1012 text-decoration: underline;
1013
1014 &:visited {
1015 color: $link_visited_color;
1016
1017 *:selected & { color: mix($selected_fg_color, $link_visited_color, 60%); }
1018 }
1019
1020 &:hover {
1021 $_fg: lighten($link_color, 10%);
1022 color: $_fg;
1023
1024 *:selected & { color: mix($selected_fg_color, $_fg, 90%); }
1025 }
1026
1027 &:active {
1028 color: $link_color;
1029
1030 *:selected & { color: mix($selected_fg_color, $link_color, 80%); }
1031 }
1032
1033 &:disabled { color: transparentize(desaturate($link_color, 100%), 0.2); }
1034
1035 @at-root %link_selected,
1036 &:selected,
1037 *:selected & { color: mix($selected_fg_color, $link_color, 80%); }
1038 }
1039
1040 link {
1041 @include focus-ring();
1042 }
1043
1044 button.link {
1045 @extend %link;
1046
1047 &,
1048 &:hover,
1049 &:active,
1050 &:checked {
1051 @extend %undecorated_button;
1052
1053 text-shadow: none;
1054 }
1055
1056 > label {
1057 text-decoration: underline;
1058 }
1059 }
1060
1061
1062 /*****************
1063 * GtkSpinButton *
1064 *****************/
1065 spinbutton {
1066 &:not(.vertical) {
1067 // in this horizontal configuration, the whole spinbutton
1068 // behaves as the entry, so we extend the entry styling
1069 // and nuke the style on the internal entry
1070 @extend %entry;
1071
1072 padding: 0;
1073 border-spacing: 0;
1074
1075 %spinbutton_horz_entry {
1076 min-width: 28px;
1077 // reset all the other props since the spinbutton node is styled here
1078 margin: 0;
1079 background: none;
1080 background-color: transparent;
1081 border: none;
1082 border-radius: 0;
1083 box-shadow: none;
1084 padding: 6px;
1085
1086 &:backdrop:disabled { background-color: transparent; }
1087 }
1088
1089 > text {
1090 @extend %spinbutton_horz_entry;
1091 }
1092
1093 /* :not here just to bump specificity above that of the list button styling */
1094 > button.image-button.up:not(.flat),
1095 > button.image-button.down:not(.flat) {
1096 min-height: 16px;
1097 margin: 0;
1098 padding-bottom: 0;
1099 padding-top: 0;
1100 color: mix($fg_color, $base_color, 90%);
1101 background-image: none;
1102 border-style: none none none solid;
1103 border-color: transparentize($borders_color, 0.7);
1104 border-radius: 0;
1105 box-shadow: none;
1106
1107 &:dir(rtl) { border-style: none solid none none; }
1108
1109 &:hover {
1110 color: $fg_color;
1111 background-color: darken($bg_color,5%);
1112 }
1113
1114 &:disabled {
1115 color: transparentize($insensitive_fg_color, 0.7);
1116 background-color: transparent;
1117 }
1118
1119 &:active {
1120 background-color: transparentize(black, 0.9);
1121 box-shadow: inset 0 2px 3px -1px transparentize(black, 0.8);
1122 }
1123
1124 &:dir(ltr):last-child { border-radius: 0 $button_radius $button_radius 0; }
1125
1126 &:dir(rtl):first-child { border-radius: $button_radius 0 0 $button_radius; }
1127 }
1128 }
1129
1130 // OSD horizontal
1131 .osd &:not(.vertical) {
1132 > text {
1133 @extend %spinbutton_horz_entry;
1134 }
1135
1136 > button.image-button.up:not(.flat),
1137 > button.image-button.down:not(.flat) {
1138 @include button(undecorated);
1139
1140 color: $osd_fg_color;
1141 border-style: none none none solid;
1142 border-color: transparentize($osd_borders_color, 0.3);
1143 border-radius: 0;
1144 box-shadow: none;
1145 -gtk-icon-shadow: 0 1px black;
1146
1147 &:dir(rtl) { border-style: none solid none none; }
1148
1149 &:hover {
1150 @include button(undecorated);
1151
1152 color: $osd_fg_color;
1153 border-color: transparentize(opacify($osd_borders_color, 1), 0.5);
1154 background-color: darken($osd_bg_color,10%);
1155 -gtk-icon-shadow: 0 1px black;
1156 box-shadow: none;
1157 }
1158
1159 &:disabled {
1160 @include button(undecorated);
1161
1162 color: $osd_insensitive_fg_color;
1163 border-color: transparentize(opacify($osd_borders_color, 1), 0.5);
1164 -gtk-icon-shadow: none;
1165 box-shadow: none;
1166 }
1167
1168 &:dir(ltr):last-child { border-radius: 0 $button_radius $button_radius 0; }
1169
1170 &:dir(rtl):first-child { border-radius: $button_radius 0 0 $button_radius; }
1171 }
1172 }
1173
1174 // Vertical
1175 &.vertical {
1176 // in the vertical configuration, we treat the spinbutton
1177 // as a box, and tweak the style of the entry in the middle
1178 // so that it's linked
1179
1180 // FIXME: this should not be set at all, but otherwise it gets the wrong
1181 // color
1182 &:disabled { color: $insensitive_fg_color; }
1183
1184 &:drop(active) {
1185 border-color: transparent;
1186 box-shadow: none;
1187 }
1188
1189 > text {
1190 @extend %entry;
1191
1192 min-height: 32px;
1193 min-width: 32px;
1194 padding: 0;
1195 border-radius: 0;
1196
1197 > selection {
1198 background-color: $backdrop_selected_bg_color;
1199 color: transparent;
1200 &:focus-within {
1201 background-color: $selected_text_bg_color;
1202 color: $fg_color;
1203 }
1204 }
1205 > block-cursor { @include entry(block_cursor); }
1206 }
1207
1208 > button {
1209 min-height: 32px;
1210 min-width: 32px;
1211 padding: 0;
1212
1213 &.up { @extend %top_button; }
1214
1215 &.down { @extend %bottom_button; }
1216 }
1217
1218 %top_button {
1219 border-bottom-style: none;
1220 border-bottom-left-radius: 0;
1221 border-bottom-right-radius: 0;
1222 }
1223
1224 %bottom_button {
1225 border-top-style: none;
1226 border-top-left-radius: 0;
1227 border-top-right-radius: 0;
1228 }
1229 }
1230
1231 // OSD vertical
1232 .osd &.vertical > button:first-child {
1233 @include button(osd);
1234
1235 &:hover { @include button(osd-hover);}
1236
1237 &:active { @include button(osd-active); }
1238
1239 &:disabled { @include button(osd-insensitive); }
1240 }
1241
1242 // Misc
1243 treeview &:not(.vertical) {
1244 min-height: 0;
1245 border-style: none;
1246 border-radius: 0;
1247
1248 > text {
1249 min-height: 0;
1250 padding: 1px 2px;
1251 }
1252 }
1253
1254 font-feature-settings: "tnum";
1255 }
1256
1257
1258 /**************
1259 * ComboBoxes *
1260 **************/
1261 dropdown > popover.menu.background > contents { padding: 0; } //allow search entries with no margin
1262
1263 dropdown > button > box {
1264 border-spacing: 6px;
1265
1266 > stack > row.activatable:hover {
1267 background: none;
1268 box-shadow: none;
1269 }
1270 }
1271
1272 dropdown,
1273 combobox {
1274 arrow {
1275 -gtk-icon-source: -gtk-icontheme('pan-down-symbolic');
1276 min-height: 16px;
1277 min-width: 16px;
1278 }
1279
1280 // align menu labels with the button label
1281 > popover.menu > contents modelbutton {
1282 padding-left: 9px;
1283 padding-right: 9px;
1284 }
1285
1286 &.linked {
1287 button:nth-child(2) {
1288 &:dir(ltr) { @extend %linked_not_left; }
1289 &:dir(rtl) { @extend %linked_not_right; }
1290 }
1291 }
1292
1293 &:drop(active) { // FIXME: untested
1294 box-shadow: none;
1295
1296 button.combo { @extend %button_basic_drop_active; }
1297 }
1298
1299 // newstyle
1300 popover {
1301 margin-top: 6px;
1302 padding: 0;
1303
1304 listview {
1305 margin: 8px;
1306
1307 > row.activatable {
1308 padding: 8px;
1309
1310 &:selected {
1311 &, &:hover {
1312 outline-color: $alt_focus_border_color;
1313 color: $text-color;
1314 background-color: $menu_selected_color;
1315 box-shadow: none;
1316 border-radius: $button_radius;
1317 }
1318 }
1319 }
1320 }
1321
1322 // drodowns with searchboxes on top
1323 .dropdown-searchbar {
1324 padding: 6px;
1325 border-bottom: 1px solid $borders_color;
1326 }
1327 }
1328 }
1329
1330
1331 // the combo is a composite widget so the way we do button linking doesn't
1332 // work, special case needed. See
1333 // https://bugzilla.gnome.org/show_bug.cgi?id=733979
1334
1335 .linked:not(.vertical) > filechooserbutton > combobox,
1336 .linked:not(.vertical) > appchooserbutton > combobox,
1337 .linked:not(.vertical) > combobox {
1338 &:dir(ltr) {
1339 &:not(:first-child) > box > button.combo { @extend %linked_not_left; }
1340 &:not(:last-child) > box > button.combo { @extend %linked_not_right; }
1341 }
1342
1343 &:dir(rtl) {
1344 &:not(:first-child) > box > button.combo { @extend %linked_not_right; }
1345 &:not(:last-child) > box > button.combo { @extend %linked_not_left; }
1346 }
1347 }
1348
1349 .linked.vertical > filechooserbutton > combobox,
1350 .linked.vertical > appchooserbutton > combobox,
1351 .linked.vertical > combobox {
1352 &:not(:first-child) > box > button.combo { @extend %linked_not_top; }
1353 &:not(:last-child) > box > button.combo { @extend %linked_not_bottom; }
1354 }
1355
1356
1357 /************
1358 * Toolbars *
1359 ************/
1360 %toolbar {
1361 padding: 4px;
1362 border-spacing: 4px;
1363 background-color: $bg_color;
1364 }
1365
1366 .toolbar {
1367 @extend %toolbar;
1368
1369 // on OSD
1370 .osd & { background-color: transparent; }
1371
1372 // stand-alone OSD toolbars
1373 &.osd {
1374 padding: 13px;
1375 border: none;
1376 border-radius: 5px;
1377 background-color: $osd_bg_color;
1378
1379 &.left,
1380 &.right,
1381 &.top,
1382 &.bottom { border-radius: 0; } // positional classes for `attached` osd toolbars
1383 }
1384
1385 // toolbar separators
1386 &.horizontal > separator { margin: 4px 0; }
1387 &.vertical > separator { margin: 0 4px; }
1388 }
1389
1390 //searchbar & location-bar
1391 searchbar > revealer > box {
1392 padding: 6px;
1393 border-spacing: 6px;
1394 @extend %toolbar;
1395
1396 @extend %darkbar;
1397
1398 border-width: 0 0 1px;
1399 }
1400
1401 %darkbar {
1402 border-style: solid;
1403 border-color: $borders_color;
1404 $_bg: mix($bg_color, $borders_color, 70%);
1405 background-color: $_bg;
1406
1407 &:backdrop {
1408 border-color: $backdrop_borders_color;
1409 background-color: $backdrop_dark_fill;
1410 box-shadow: none;
1411 transition: $backdrop_transition;
1412 }
1413 }
1414
1415 /**************
1416 * GtkInfoBar *
1417 **************/
1418 infobar {
1419 > revealer > box {
1420 padding: 8px;
1421 border-spacing: 12px;
1422 }
1423
1424 &.action:hover > revealer > box {
1425 background-color: if($variant == 'light', desaturate(lighten(invert($selected_bg_color), 47%), 30%),
1426 desaturate(darken(invert($selected_bg_color), 42%), 70%));
1427 }
1428
1429 &.info,
1430 &.question,
1431 &.warning,
1432 &.error {
1433 > revealer > box {
1434 border-bottom: 1px solid lighten($borders_color, 5%);
1435 background-color: if($variant == 'light', desaturate(lighten(invert($selected_bg_color), 45%), 30%),
1436 desaturate(darken(invert($selected_bg_color), 40%), 70%));
1437 }
1438 }
1439 }
1440
1441 //close button for info and searchbar (#3215)
1442
1443 infobar .close,
1444 searchbar .close {
1445 @include button(undecorated);
1446 min-width: 16px;
1447 min-height: 16px;
1448 padding: 4px;
1449 border-radius: 50%;
1450
1451 &:hover { @include button(hover); }
1452 }
1453
1454
1455 /*****************
1456 * Title buttons *
1457 *****************/
1458
1459 windowcontrols {
1460 border-spacing: 6px;
1461
1462 &:not(.empty) {
1463 &.start:dir(ltr),
1464 &.end:dir(rtl) {
1465 margin-right: 7px;
1466 }
1467
1468 &.start:dir(rtl),
1469 &.end:dir(ltr) {
1470 margin-left: 7px;
1471 }
1472 }
1473
1474 button {
1475 @extend %button_basic_flat;
1476
1477 box-shadow: none;
1478 border: none;
1479 min-width: 34px;
1480 padding: 0;
1481
1482 > image {
1483 border-radius: 9999px;
1484 min-height: 30px;
1485 min-width: 30px;
1486 }
1487 &:hover > image {
1488 //special case hover colors inside a headerbar
1489 @include button(undecorated-hover,$c:darken($headerbar_bg_color,6%));
1490 }
1491 &:active > image,
1492 &:checked > image { @include button(undecorated-active,$c:darken($headerbar_bg_color,10%)); }
1493
1494 &:hover,
1495 &:active,
1496 &:checked {
1497 background: none;
1498 }
1499 }
1500 }
1501
1502
1503 /***************
1504 * Header bars *
1505 ***************/
1506 %titlebar,
1507 headerbar {
1508 padding: 0 6px;
1509 min-height: 46px;
1510 border-width: 0 0 1px;
1511 border-style: solid;
1512 border-color: $alt_borders_color;
1513 border-radius: 0;
1514
1515 @include headerbar_fill(darken($bg_color, 10%));
1516
1517 &:backdrop {
1518 border-color: $backdrop_borders_color;
1519 background-color: $bg_color;
1520 background-image: none;
1521
1522 transition: $backdrop_transition;
1523
1524 .title { filter: opacity(.5); }
1525 }
1526
1527 .title {
1528 padding-left: 12px;
1529 padding-right: 12px;
1530 font-weight: bold;
1531 }
1532
1533 .subtitle {
1534 font-size: smaller;
1535 padding-left: 12px;
1536 padding-right: 12px;
1537
1538 @extend .dim-label;
1539 }
1540
1541 /* Darken switchbuttons for headerbars. issue #1588 */
1542 stackswitcher > button:checked,
1543 button.toggle:checked {
1544
1545 background: if($variant == 'light', image(darken($bg_color, 17%)), image(darken($bg_color, 9%)));
1546 border-color: darken($borders_color, 3%);
1547 border-top-color: darken($borders_color, 8%);
1548 &:backdrop {
1549 @include button(backdrop-active);
1550 }
1551 }
1552
1553 // squared corners when the window is maximized, tiled, or fullscreen
1554 .tiled &,
1555 .tiled-top &,
1556 .tiled-left &,
1557 .tiled-right &,
1558 .tiled-bottom &,
1559 .maximized &,
1560 .fullscreen & {
1561 &:backdrop, & {
1562 border-radius: 0;
1563 }
1564 }
1565
1566 &.default-decoration {
1567 min-height: 28px;
1568 padding: 4px;
1569
1570 windowcontrols {
1571 button,
1572 menubutton {
1573 min-height: 26px;
1574 min-width: 26px;
1575 margin: 0;
1576 padding: 0;
1577 }
1578
1579 menubutton button {
1580 min-height: 20px;
1581 min-width: 20px;
1582 margin: 0;
1583 padding: 4px;
1584 }
1585 }
1586 }
1587
1588 .solid-csd & {
1589 &:backdrop, & {
1590 &:dir(rtl), &:dir(ltr) { // specificity bump
1591 margin-left: -1px;
1592 margin-right: -1px;
1593 margin-top: -1px;
1594 border-radius: 0;
1595 box-shadow: none;
1596 }
1597 }
1598 }
1599 }
1600
1601 headerbar {
1602 > windowhandle > box {
1603 &,
1604 > box.start,
1605 > box.end {
1606 border-spacing: 6px;
1607 }
1608 }
1609
1610 // add vertical margins to common widget on the headerbar to avoid them spanning the whole height
1611 entry,
1612 spinbutton,
1613 separator:not(.sidebar),
1614 button,
1615 menubutton {
1616 margin-top: 6px;
1617 margin-bottom: 6px;
1618 }
1619
1620 windowcontrols {
1621 > button {
1622 margin: 0;
1623 }
1624
1625 &.start > image.icon {
1626 -gtk-icon-size: 20px;
1627 }
1628
1629 &.end {
1630 margin-right: -6px;
1631
1632 > button:last-child {
1633 padding-right: 6px;
1634 }
1635 }
1636 }
1637
1638 // Reset margins for buttons inside menubutton
1639 menubutton > button {
1640 margin-top: 0px;
1641 margin-bottom: 0px;
1642 }
1643
1644 switch {
1645 margin-top: 10px;
1646 margin-bottom: 10px;
1647 }
1648 }
1649
1650
1651 .titlebar:not(headerbar) {
1652 window.csd > & {
1653 // in csd we assume every titlebar is a headerbar so reset anything, this is needed for split toolbars cases
1654 padding: 0;
1655 background-color: transparent;
1656 background-image: none;
1657 border-style: none;
1658 border-color: transparent;
1659 }
1660
1661 separator { background-color: $borders_color; } // FIXME: use darker border?
1662
1663 @extend %titlebar;
1664 }
1665
1666 // Development versions of apps to use a differently styled headerbar
1667
1668 window.devel {
1669 headerbar.titlebar {
1670 $c: darken($bg_color, 10%);
1671 $gradient: cross-fade(10% -gtk-icontheme("system-run-symbolic"), image(transparent)) 90% 0/256px 256px no-repeat,
1672 linear-gradient(to right, transparent 65%, transparentize($selected_bg_color, 0.8)),
1673 linear-gradient(to top, darken($c, 3%), $c 3px, lighten($c, 6%));
1674 @if $variant == 'dark' {
1675 $gradient: cross-fade(10% -gtk-icontheme("system-run-symbolic"), image(transparent)) 90% 0/256px 256px no-repeat,
1676 linear-gradient(to right, transparent 65%, transparentize($selected_bg_color, 0.9)),
1677 linear-gradient(to top, lighten($c, 3%) 3px, lighten($c, 5%));
1678 }
1679
1680 background: $bg_color $gradient;
1681
1682 &:backdrop {
1683 background: $bg_color cross-fade(10% -gtk-icontheme("system-run-symbolic"), image(transparent)) 90% 0/256px 256px no-repeat,
1684 image($bg_color); /* background-color would flash */
1685 }
1686 }
1687 }
1688
1689 /************
1690 * Pathbars *
1691 ************/
1692
1693 pathbar scrolledwindow undershoot.left {
1694 border-left: solid 1px $borders_color;
1695 }
1696
1697 pathbar scrolledwindow undershoot.right {
1698 border-right: solid 1px $borders_color;
1699 }
1700
1701 pathbar button {
1702 &.text-button, &.image-button, & {
1703 padding-left: 4px;
1704 padding-right: 4px;
1705 }
1706
1707 &.text-button.image-button label {
1708 padding-left: 0;
1709 padding-right: 0;
1710 }
1711
1712 &.text-button.image-button, & {
1713 label:last-child { padding-right: 8px; }
1714 label:first-child { padding-left: 8px; }
1715 }
1716
1717 image {
1718 padding-left: 4px;
1719 padding-right: 4px;
1720 }
1721
1722 &.slider-button {
1723 padding-left: 0;
1724 padding-right: 0;
1725 }
1726 }
1727
1728
1729 /**************
1730 * Tree Views *
1731 **************/
1732
1733 $_treeview_borders_color: if($variant=='light',mix($borders_color, $base_color,80%),mix($fg_color, $base_color, 20%));
1734 $_treeview_backdrop_borders_color: if($variant=='light',mix($backdrop_borders_color, $base_color, 80%),mix($backdrop_fg_color, $base_color, 20%));
1735 columnview.view,
1736 treeview.view {
1737 border-left-color: $_treeview_borders_color; // this is actually the tree lines color,
1738 border-top-color: $_treeview_borders_color; // while this is the grid lines color, better then nothing
1739
1740 @include focus-ring();
1741
1742 > rubberband { @extend rubberband; } // to avoid borders being overridden by the previously set props
1743
1744 &:selected {
1745 &:focus, & {
1746 border-radius: 0;
1747 outline-color: $alt_focus_border_color;
1748
1749 @extend %selected_items;
1750 }
1751 }
1752
1753 &:disabled {
1754 color: $insensitive_fg_color;
1755
1756 &:selected {
1757 color: mix($selected_fg_color, $selected_bg_color, 40%);
1758 &:backdrop { color: mix($backdrop_selected_fg_color, $selected_bg_color, 30%); }
1759 }
1760 }
1761
1762 &.separator {
1763 min-height: 2px;
1764 color: $_treeview_borders_color;
1765 }
1766
1767 &:backdrop {
1768 border-left-color: $_treeview_backdrop_borders_color;
1769 border-top: $_treeview_backdrop_borders_color;
1770 }
1771
1772 &:drop(active) {
1773 box-shadow: none;
1774 }
1775
1776 > dndtarget:drop(active) {
1777 border-style: solid none;
1778 border-width: 1px;
1779 border-color: $selected_borders_color;
1780
1781 &.after { border-top-style: none; }
1782
1783 &.before { border-bottom-style: none; }
1784 }
1785
1786 &.expander {
1787 // GtkTreeView uses the larger of the expander’s min-width and min-height
1788 min-width: 16px;
1789 min-height: 16px;
1790 -gtk-icon-source: -gtk-icontheme('pan-end-symbolic');
1791
1792 &:dir(rtl) { -gtk-icon-source: -gtk-icontheme('pan-end-symbolic-rtl'); }
1793
1794 color: mix($text_color, $base_color, 70%);
1795
1796 &:hover { color: $text_color; }
1797
1798 &:selected {
1799 color: mix($selected_fg_color, $selected_bg_color, 70%);
1800
1801 &:hover { color: $selected_fg_color; }
1802 }
1803
1804 &:checked { -gtk-icon-source: -gtk-icontheme('pan-down-symbolic'); }
1805 }
1806
1807 &.progressbar { // progress bar in treeviews
1808 @if $variant == light { color: $base_color; }
1809
1810 background-color: $selected_bg_color;
1811 background-image: image($selected_bg_color);
1812 box-shadow: none;
1813
1814 &:selected {
1815 &:focus, & {
1816
1817 @if $variant == 'light' {
1818 color: $selected_bg_color;
1819
1820 }
1821
1822 @else { box-shadow: inset 0 1px transparentize(white, 0.95); }
1823
1824 background-image: image($base_color);
1825
1826 &:backdrop {
1827 @if $variant == 'light' {
1828 color: $selected_bg_color;
1829 }
1830 background-color: $backdrop_base_color;
1831 }
1832 }
1833 }
1834 }
1835
1836 &.trough { // progress bar trough in treeviews
1837 background-color: transparentize($fg_color,0.9);
1838
1839 &:selected {
1840 &:focus, & {
1841 background-color: if($variant == 'light',
1842 transparentize($selected_fg_color, 0.7),
1843 darken($selected_bg_color, 10%));
1844
1845 }
1846 }
1847 }
1848
1849 > header {
1850 > button {
1851 $_column_header_color: mix($fg_color, $base_color, 50%);
1852
1853 @extend %column_header_button;
1854
1855 color: $_column_header_color;
1856 background-color: $base_color;
1857 font-weight: bold;
1858 text-shadow: none;
1859 box-shadow: none;
1860
1861 &:hover {
1862 @extend %column_header_button;
1863
1864 color: mix($_column_header_color, $fg_color, 50%);
1865 box-shadow: none;
1866 transition: none; //I shouldn't need this
1867 }
1868
1869 &:active {
1870 @extend %column_header_button;
1871
1872 color: $fg_color;
1873 transition: none; //I shouldn't need this
1874 }
1875 sort-indicator {
1876 &.ascending {
1877 -gtk-icon-source: -gtk-icontheme('pan-up-symbolic');
1878 }
1879 &.descending {
1880 -gtk-icon-source: -gtk-icontheme('pan-down-symbolic');
1881 }
1882
1883 min-height: 16px;
1884 min-width: 16px;
1885 }
1886 }
1887 }
1888
1889 button.dnd,
1890 header.button.dnd { // for treeview-like derive widgets
1891 &:active, &:selected, &:hover, & {
1892 padding: 0 6px;
1893 color: $base_color;
1894 background-image: none;
1895 background-color: $selected_bg_color;
1896 border-style: none;
1897 border-radius: 0;
1898 box-shadow: inset 0 0 0 1px $base_color;
1899 text-shadow: none;
1900 transition: none;
1901 }
1902 }
1903
1904 acceleditor > label { background-color: $selected_bg_color; } // see tests/testaccel to test
1905 }
1906
1907 %column_header_button {
1908 padding: 0 6px;
1909 background-image: none;
1910 border-style: none none solid solid;
1911 border-color: $_treeview_borders_color;
1912 border-radius: 0;
1913 text-shadow: none;
1914
1915 &:disabled {
1916 border-color: $bg_color;
1917 background-image: none;
1918 }
1919
1920 &:last-child { &:backdrop, & { border-right-style: none; }}
1921 }
1922
1923 /***************
1924 * Popovers *
1925 ***************/
1926
1927 popover.background {
1928 background-color: transparent;
1929 font: initial; // Decouple the font of popovers from their entry/textview
1930
1931 > arrow,
1932 > contents {
1933 $_popover_border: if($variant=='light', transparentize(black, 0.77), transparentize(black, 0.25));
1934
1935 background-color: $menu_color;
1936 background-clip: padding-box;
1937 border: 1px solid $_popover_border;
1938 box-shadow: 0 1px 2px transparentize(black, 0.7);
1939 }
1940
1941 &:backdrop {
1942 background-color: transparent;
1943 }
1944
1945 > contents {
1946 padding: 8px;
1947 border-radius: $popover_radius;
1948
1949 > list,
1950 > .view,
1951 > .toolbar {
1952 border-style: none;
1953 background-color: transparent;
1954 }
1955
1956 separator {
1957 background-color: mix($bg_color, $borders_color, 30%);
1958 margin: 3px;
1959 }
1960
1961 list separator { margin: 0; }
1962 }
1963
1964 .osd &,
1965 &.touch-selection,
1966 &.magnifier {
1967 background-color: transparent;
1968
1969 > arrow,
1970 > contents {
1971 @extend %osd;
1972
1973 border: 1px solid transparentize(white, 0.9);
1974 box-shadow: none;
1975 }
1976 }
1977
1978 &.touch-selection,
1979 &.magnifier {
1980 button { @extend %osd_button; }
1981 }
1982 }
1983
1984 magnifier {
1985 background-color: $base_color;
1986 }
1987
1988 /**********************
1989 * Popover Base Menus *
1990 **********************/
1991
1992 $_menu-padding: 12px; //inner menuitem padding
1993 //global $menu-margin for outside menuitems
1994
1995 popover.menu {
1996 padding: 0;
1997
1998 box.inline-buttons {
1999 padding: 0 $_menu-padding;
2000
2001 button.image-button.model {
2002 @include button(undecorated);
2003
2004 min-height: 30px;
2005 min-width: 30px;
2006 padding: 0;
2007 border: none;
2008 outline: none;
2009 transition: none;
2010
2011 &:selected {
2012 background: image($menu_selected_color);
2013
2014 @if $contrast == 'high' {
2015 box-shadow: inset 0 0 0 1px $borders_color;
2016 }
2017 }
2018 }
2019 }
2020
2021 box.circular-buttons {
2022 padding: $_menu-padding $_menu-padding 6px;
2023
2024 button.circular.image-button.model {
2025 @extend %list_button;
2026
2027 padding: 11px;
2028 &:focus {
2029 background-color: $menu_selected_color;
2030 border-color: $menu_selected_color;
2031 }
2032 }
2033 }
2034
2035 & > arrow,
2036 &.background > contents {
2037 background-color: $menu_color;
2038 padding: $menu-margin;
2039 }
2040
2041 &.background separator {
2042 margin: 6px 0;
2043 }
2044
2045 accelerator {
2046 color: gtkalpha(currentColor,0.55);
2047
2048 &:dir(ltr) { margin-left: $_menu-padding; }
2049 &:dir(rtl) { margin-right: $_menu-padding; }
2050 }
2051
2052 check,
2053 radio {
2054 @include check('menu', 'transparent', $text_color);
2055
2056 &:hover { @include check('menu-active', 'transparent', $text_color); }
2057 &:active { @include check('menu-active', 'transparent', $text_color); }
2058 }
2059
2060 //only menu radios have a border
2061 radio { border-color: $borders_color;
2062 &:active { border-color: transparentize($borders_color,0.5); }
2063 }
2064
2065 arrow.left,
2066 radio.left,
2067 check.left {
2068 margin-left: -2px;
2069 margin-right: 6px;
2070 }
2071
2072 arrow.right,
2073 radio.right,
2074 check.right {
2075 margin-left: 6px;
2076 margin-right: -2px;
2077 }
2078
2079 modelbutton {
2080 min-height: 30px;
2081 min-width: 40px;
2082 padding: 0 $_menu-padding;
2083 border-radius: $menu-margin;
2084
2085 &:selected {
2086 color: $text-color;
2087 background-color: $menu_selected_color;
2088 }
2089 &:selected:active {
2090 //@extend %selected_items;
2091 //color: $selected_fg_color;
2092 background-color: darken($bg_color,14%); // matching buttons
2093 }
2094 }
2095
2096 label.title {
2097 font-weight: bold;
2098 padding: 4px ($_menu-padding + 20px); //this will fall apart with font sizing
2099 }
2100 }
2101
2102 // initial styling for popover menu and bar
2103 menubar {
2104 padding: 0px;
2105 box-shadow: inset 0 -1px transparentize(black, 0.9);
2106
2107 > item {
2108 min-height: 16px;
2109 padding: 4px 8px;
2110
2111 &:selected { //Seems like it :hover even with keyboard focus
2112 box-shadow: inset 0 -3px $selected_bg_color;
2113 color: $link_color;
2114 }
2115
2116 &:disabled {
2117 color: $insensitive_fg_color;
2118 box-shadow: none;
2119 }
2120 }
2121
2122 & > item popover.menu.background > contents {
2123 padding: $menu-margin;
2124 }
2125 //nested submenus
2126 & > item popover.menu popover.menu {
2127 padding: 0 0 4px 0;
2128 }
2129 & > item popover.menu.background popover.menu.background > contents {
2130 margin: 0;
2131 border-radius: $popover_radius; //including top
2132 }
2133 }
2134
2135
2136 /*************
2137 * Notebooks *
2138 *************/
2139 notebook {
2140 @include focus-ring("> header > tabs > tab:checked", $offset: -2px, $focus-state: 'focus:focus-visible');
2141
2142 > header {
2143 padding: 1px;
2144 border-color: $borders_color;
2145 border-width: 1px;
2146 background-color: $dark_fill;
2147
2148 > tabs { margin: -1px; }
2149
2150 &.top {
2151 border-bottom-style: solid;
2152 > tabs {
2153 margin-bottom: -2px;
2154 > tab {
2155 &:hover { box-shadow: inset 0 -4px $borders_color; }
2156
2157
2158 &:checked { box-shadow: inset 0 -4px $selected_bg_color; }
2159 }
2160 }
2161 }
2162
2163 &.bottom {
2164 border-top-style: solid;
2165 > tabs {
2166 margin-top: -2px;
2167 > tab {
2168 &:hover { box-shadow: inset 0 4px $borders_color; }
2169
2170 &:checked { box-shadow: inset 0 4px $selected_bg_color; }
2171 }
2172 }
2173 }
2174
2175 &.left {
2176 border-right-style: solid;
2177 > tabs {
2178 margin-right: -2px;
2179 > tab {
2180 &:hover { box-shadow: inset -4px 0 $borders_color; }
2181
2182 &:checked { box-shadow: inset -4px 0 $selected_bg_color; }
2183 }
2184 }
2185 }
2186
2187 &.right {
2188 border-left-style: solid;
2189 > tabs {
2190 margin-left: -2px;
2191 > tab {
2192 &:hover { box-shadow: inset 4px 0 $borders_color; }
2193
2194 &:checked { box-shadow: inset 4px 0 $selected_bg_color; }
2195 }
2196 }
2197 }
2198
2199 &.top > tabs > arrow {
2200 @extend %notebook_vert_arrows;
2201
2202 border-top-style: none;
2203 }
2204
2205 &.bottom > tabs > arrow {
2206 @extend %notebook_vert_arrows;
2207
2208 border-bottom-style: none;
2209 }
2210
2211 @at-root %notebook_vert_arrows {
2212 margin-left: -5px;
2213 margin-right: -5px;
2214 padding-left: 4px;
2215 padding-right: 4px;
2216
2217 &.down { -gtk-icon-source: -gtk-icontheme('pan-start-symbolic'); }
2218
2219 &.up { -gtk-icon-source: -gtk-icontheme('pan-end-symbolic'); }
2220 }
2221
2222 &.left > tabs > arrow {
2223 @extend %notebook_horz_arrows;
2224
2225 border-left-style: none;
2226 }
2227
2228 &.right > tabs > arrow {
2229 @extend %notebook_horz_arrows;
2230
2231 border-right-style: none;
2232 }
2233
2234 @at-root %notebook_horz_arrows {
2235 margin-top: -5px;
2236 margin-bottom: -5px;
2237 padding-top: 4px;
2238 padding-bottom: 4px;
2239
2240 &.down { -gtk-icon-source: -gtk-icontheme('pan-up-symbolic'); }
2241
2242 &.up { -gtk-icon-source: -gtk-icontheme('pan-down-symbolic'); }
2243 }
2244
2245 > tabs > arrow {
2246 @extend %button_basic;
2247
2248 @extend %button_basic_flat;
2249
2250 min-height: 16px;
2251 min-width: 16px;
2252 border-radius: 0;
2253
2254 &:hover:not(:active):not(:backdrop) {
2255 background-clip: padding-box;
2256 background-image: none;
2257 background-color: transparentize(white, 0.7);
2258 border-color: transparent;
2259 box-shadow: none;
2260 }
2261
2262 &:disabled { @include button(undecorated); }
2263 }
2264
2265 > tabs > tab {
2266 transition: $focus_transition;
2267 min-height: 30px;
2268 min-width: 30px;
2269 padding: 3px 12px;
2270
2271 color: $fg_color;
2272 font-weight: normal;
2273
2274 border-width: 1px; // for reorderable tabs
2275 border-color: transparent; //
2276
2277 &:hover {
2278 color: $fg_color;
2279 background-color: darken($dark_fill,4%);
2280
2281 &.reorderable-page {
2282 border-color: transparentize($borders_color, 0.7);
2283 background-color: transparentize($bg_color, 0.8);
2284 }
2285 }
2286
2287 &:not(:checked) {
2288 outline-color: transparent;
2289 }
2290
2291 &:checked {
2292 color: $fg_color;
2293 &.reorderable-page {
2294 border-color: transparentize($borders_color, 0.5);
2295 background-color: transparentize($bg_color, 0.5);
2296
2297 &:hover { background-color: transparentize($bg_color, 0.3); }
2298 }
2299 }
2300
2301 // colors the button like the label, overridden otherwise
2302 button.flat {
2303 color: gtkalpha(currentColor, 0.3);
2304 &:hover { color: currentColor; }
2305
2306 padding: 0;
2307 margin-top: 4px;
2308 margin-bottom: 4px;
2309 // FIXME: generalize .small-button?
2310 min-width: 20px;
2311 min-height: 20px;
2312
2313 &:last-child {
2314 margin-left: 4px;
2315 margin-right: -4px;
2316 }
2317
2318 &:first-child {
2319 margin-left: -4px;
2320 margin-right: 4px;
2321 }
2322 }
2323 }
2324
2325 &.top,
2326 &.bottom {
2327 > tabs {
2328 padding-left: 4px;
2329 padding-right: 4px;
2330
2331 &:not(:only-child) {
2332 margin-left: 3px;
2333 margin-right: 3px;
2334
2335 &:first-child { margin-left: -1px; }
2336 &:last-child { margin-right: -1px; }
2337 }
2338
2339 > tab {
2340 margin-left: 4px;
2341 margin-right: 4px;
2342
2343 &.reorderable-page { border-style: none solid; }
2344 }
2345 }
2346 }
2347
2348 &.left,
2349 &.right {
2350 > tabs {
2351 padding-top: 4px;
2352 padding-bottom: 4px;
2353
2354 &:not(:only-child) {
2355 margin-top: 3px;
2356 margin-bottom: 3px;
2357
2358 &:first-child { margin-top: -1px; }
2359 &:last-child { margin-bottom: -1px; }
2360 }
2361
2362 > tab {
2363 margin-top: 4px;
2364 margin-bottom: 4px;
2365
2366 &.reorderable-page { border-style: solid none; }
2367 }
2368 }
2369 }
2370
2371 &.top > tabs > tab { padding-bottom: 4px; }
2372 &.bottom > tabs > tab { padding-top: 4px; }
2373 }
2374
2375 > stack:not(:only-child) { // the :not(:only-child) is for "hidden" notebooks
2376 background-color: $base_color;
2377 }
2378 }
2379
2380
2381 /**************
2382 * Scrollbars *
2383 **************/
2384
2385 scrollbar {
2386 $_slider_min_length: 40px;
2387 $_slider_width: 8px;
2388 $_scrollbar_transition: all 300ms $ease-out-quad;
2389 $_fine-tune_slider_border: $_slider_width - 3; //#3672
2390
2391 background-color: $scrollbar_bg_color;
2392 transition: $_scrollbar_transition;
2393
2394 // scrollbar border
2395 &.top { border-bottom: 1px solid $borders_color; }
2396 &.bottom { border-top: 1px solid $borders_color; }
2397 &.left { border-right: 1px solid $borders_color; }
2398 &.right { border-left: 1px solid $borders_color; }
2399
2400 > range > trough > slider {
2401 min-width: $_slider_width;
2402 min-height: $_slider_width;
2403 margin: -1px;
2404 border: 4px solid transparent;
2405 border-radius: 10px;
2406 background-clip: padding-box;
2407 background-color: $scrollbar_slider_color;
2408 transition: $_scrollbar_transition;
2409
2410 &:hover { background-color: $scrollbar_slider_hover_color; }
2411
2412 &:hover:active { background-color: $scrollbar_slider_active_color; }
2413
2414 &:disabled { background-color: transparent; }
2415 }
2416
2417 > range.fine-tune {
2418 > trough > slider {
2419 transition: none;
2420 min-width: $_fine-tune_slider_border+1;
2421 min-height: $_fine-tune_slider_border+1;
2422 }
2423
2424 &.horizontal > trough > slider { border-width: $_fine-tune_slider_border 4px; }
2425 &.vertical > trough > slider { border-width: 4px $_fine-tune_slider_border; }
2426 }
2427
2428 &.overlay-indicator {
2429 &:not(.dragging):not(.hovering) {
2430 border-color: transparent;
2431 background-color: transparent;
2432
2433 > range > trough > slider {
2434 margin: 0;
2435 min-width: 3px;
2436 min-height: 3px;
2437 background-color: gtkalpha($fg_color, 0.4);
2438 border: 1px solid gtkalpha(if($variant == 'light', white, black), 0.4);
2439 }
2440
2441 &.horizontal {
2442 > range > trough > slider {
2443 margin: 0 2px;
2444 min-width: $_slider_min_length;
2445 }
2446 }
2447
2448 &.vertical {
2449 > range > trough > slider {
2450 margin: 2px 0;
2451 min-height: $_slider_min_length;
2452 }
2453 }
2454 }
2455
2456 &.dragging,
2457 &.hovering {
2458 background-color: gtkalpha($scrollbar_bg_color, 0.8);
2459 border: 1px solid gtkalpha(if($variant == 'light', white, black), 0.8);
2460 }
2461 }
2462
2463 &.horizontal > range > trough > slider { min-width: $_slider_min_length; }
2464 &.vertical > range > trough > slider { min-height: $_slider_min_length; }
2465 }
2466
2467 treeview ~ scrollbar.vertical {
2468 border-top: 1px solid $borders_color;
2469 margin-top: -1px;
2470 }
2471
2472 /**********
2473 * Switch *
2474 **********/
2475 switch {
2476 font-weight: bold;
2477 font-size: smaller;
2478
2479 // similar to the .scale
2480 border: 1px solid $borders_color;
2481 border-radius: 14px;
2482 color: $fg_color;
2483 background-color: $dark_fill;
2484 transition: $focus_transition;
2485
2486 @include focus-ring($offset: 0, $outer: true);
2487
2488 headerbar & { background-color: darken($dark_fill,8%); } //3504
2489
2490 &:checked {
2491 color: $selected_fg_color;
2492 border-color: $switch_borders_color;
2493 background-color: $switch_bg_color;
2494 }
2495
2496 &:disabled {
2497 color: $insensitive_fg_color;
2498 border-color: $borders_color;
2499 background-color: $insensitive_bg_color;
2500 text-shadow: none;
2501 }
2502
2503 > slider {
2504 @include button(normal);
2505
2506 margin: -1px;
2507 min-width: 24px;
2508 min-height: 24px;
2509 border: 1px solid;
2510 border-color: $borders_color;
2511 border-radius: 50%;
2512 transition: $button_transition;
2513 }
2514
2515 &:hover > slider {
2516 @include button(hover);
2517 }
2518
2519 &:checked > slider { border: 1px solid $switch_borders_color; }
2520
2521 &:disabled > slider { @include button(insensitive); }
2522
2523
2524 row:selected & {
2525 outline-color: $alt_focus_border_color;
2526
2527 @if $variant == 'light' {
2528 box-shadow: none;
2529 border-color: $switch_borders_color;
2530
2531 > slider { &:checked, & { border-color: $switch_borders_color; } }
2532 }
2533 }
2534 }
2535
2536
2537 /*************************
2538 * Check and Radio items *
2539 *************************/
2540 // draw regular check and radio items using our PNG assets
2541 // all assets are rendered from assets.svg. never add pngs directly
2542
2543
2544 //selection-mode
2545 @each $check_state, $check_icon, $check_color, $check_background in
2546 ('', 'none', 'transparent', $checkradio_bg_color),
2547 (':hover', 'none', 'transparent', $checkradio_bg_color),
2548 (':active', 'none', 'transparent', $checkradio_bg_color),
2549 (':backdrop', 'none', 'transparent', '#{desaturate($checkradio_bg_color, 100%)}'),
2550 (':checked', '-gtk-icontheme(\'object-select-symbolic\')', $osd_fg_color, $checkradio_bg_color),
2551 (':checked:hover', '-gtk-icontheme(\'object-select-symbolic\')', $osd_fg_color, $checkradio_bg_color),
2552 (':checked:active', '-gtk-icontheme(\'object-select-symbolic\')', $osd_fg_color, $checkradio_bg_color),
2553 (':backdrop:checked', '-gtk-icontheme(\'object-select-symbolic\')', '#{transparentize($osd_fg_color, 0.2)}', '#{desaturate($checkradio_bg_color, 100%)}'), {
2554
2555 .view.content-view.check#{$check_state}:not(list),
2556 .content-view .tile check#{$check_state}:not(list) {
2557 margin: 4px;
2558 min-width: 32px;
2559 min-height: 32px;
2560 color: #{$check_color};
2561 background-color: #{$check_background};
2562 border-radius: 5px;
2563 background-image: none;
2564 transition: 200ms;
2565 box-shadow: none;
2566 border-width: 0;
2567 -gtk-icon-source: #{$check_icon};
2568 -gtk-icon-shadow: none;
2569 }
2570 }
2571
2572 checkbutton {
2573 border-spacing: 4px;
2574 border-radius: $button_radius;
2575 transition: $focus_transition;
2576
2577 @include focus-ring();
2578
2579 &.text-button {
2580 // this is for a nice focus on check and radios text
2581 padding: 4px;
2582 }
2583 }
2584
2585 check,
2586 radio {
2587 min-height: 14px;
2588 min-width: 14px;
2589 border: 1px solid;
2590 -gtk-icon-source: none;
2591
2592 & {
2593 // for unchecked
2594 $_c: if($variant=='light', white, $bg_color);
2595
2596 @each $state, $t in ("", "normal"),
2597 (":hover", "hover"),
2598 (":active", "active"),
2599 (":disabled", "insensitive") {
2600 &#{$state} {
2601 @include check($t, $_c);
2602 }
2603 }
2604 }
2605
2606 & {
2607 // for checked
2608 @each $t in (':checked'), (':indeterminate') {
2609 &#{$t} {
2610 @each $state, $t in ("", "normal"),
2611 (":hover", "hover"),
2612 (":active", "active"),
2613 (":disabled", "insensitive") {
2614 &#{$state} {
2615 @include check($t, $checkradio_bg_color, $checkradio_fg_color, $checked: true);
2616 }
2617 }
2618 }
2619 }
2620 }
2621
2622 @if $variant == 'light' {
2623 // the borders of the light variant versions of checks and radios are too similar in luminosity to the selected background
2624 // color, hence we need special casing.
2625 row:selected & { border-color: $checkradio_borders_color; }
2626 }
2627
2628 .osd & {
2629 @include button(osd);
2630
2631 &:hover { @include button(osd); }
2632 &:active { @include button(osd-active); }
2633 &:disabled { @include button(osd-insensitive); }
2634 }
2635 }
2636
2637 %check,
2638 check {
2639 border-radius: 3px;
2640 -gtk-icon-size: 14px;
2641
2642 &:checked { -gtk-icon-source: -gtk-recolor(url("#{$assets}/#{$asset_prefix}check-symbolic.svg")); }
2643
2644 &:indeterminate { -gtk-icon-source: -gtk-recolor(url("#{$assets}/#{$asset_prefix}dash-symbolic.svg")); }
2645 }
2646
2647 %radio,
2648 radio {
2649 border-radius: 100%;
2650 -gtk-icon-size: 14px;
2651
2652 &:checked { -gtk-icon-source: -gtk-recolor(url("#{$assets}/#{$asset_prefix}bullet-symbolic.svg")); }
2653
2654 &:indeterminate { -gtk-icon-source: -gtk-recolor(url("#{$assets}/#{$asset_prefix}dash-symbolic.svg")); }
2655 }
2656
2657 treeview.view check,
2658 treeview.view radio {
2659 &:selected {
2660 &:focus, & {
2661 color: $checkradio_fg_color;
2662
2663 @if $variant == 'light' { border-color: $selected_borders_color; }
2664 }
2665 }
2666 }
2667
2668 treeview.view radio:selected { &:focus, & { @extend %radio; }} // This is a workaround
2669
2670
2671 /************
2672 * GtkScale *
2673 ************/
2674 %scale_trough {
2675 border: 1px solid $dark_fill;
2676 border-radius: 3px;
2677 background-color: $dark_fill;
2678
2679 headerbar & { background-color: darken($dark_fill,8%); } //3504
2680
2681 &:disabled {
2682 background-color: $insensitive_bg_color;
2683 border-color: $insensitive_borders_color;
2684 }
2685
2686 // ...on selected list rows
2687 row:selected & {
2688 &:disabled, & {
2689 outline-color: $alt_focus_border_color;
2690 border-color: $selected_borders_color;
2691 }
2692 }
2693
2694 // OSD
2695 .osd & {
2696 border-color: $osd_borders_color;
2697 background-color: transparentize($osd_borders_color, 0.2);
2698
2699 &:disabled { background-color: $osd_insensitive_bg_color; }
2700 }
2701 }
2702
2703 %scale_highlight {
2704 border: 1px solid $selected_bg_color;
2705 border-radius: 3px;
2706 background-color: $selected_bg_color;
2707
2708 &:disabled {
2709 background-color: transparent;
2710 border-color: transparent;
2711 }
2712
2713 // ...on selected list rows
2714 row:selected & { &:disabled, & { border-color: $selected_borders_color; }}
2715
2716 // OSD
2717 .osd & {
2718 border-color: $osd_borders_color;
2719
2720 &:disabled { border-color: transparent; }
2721 }
2722 }
2723
2724 scale {
2725 // sizing
2726 $_marks_length: 6px;
2727 $_marks_distance: 6px;
2728 $_marks_size: $_marks_length + $_marks_distance;
2729
2730 min-height: 10px;
2731 min-width: 10px;
2732 padding: 12px;
2733
2734 @include focus-ring("> trough", $offset: 10px);
2735
2736 // those are inside the trough node, I need them to show their own border over the trough one, so negative margin
2737 > trough {
2738 transition: $focus_transition;
2739
2740 > fill,
2741 > highlight { margin: -1px; }
2742
2743 // the slider is inside the trough, so to have make it bigger there's a negative margin
2744
2745 > slider {
2746 min-height: 18px;
2747 min-width: 18px;
2748 margin: -9px;
2749 }
2750 }
2751
2752 // click-and-hold the slider to activate
2753 &.fine-tune {
2754 // to make the trough grow in fine-tune mode
2755 > trough { margin: -3px; }
2756 > trough > slider { margin: -6px; }
2757
2758 > trough > fill,
2759 > trough > highlight,
2760 > trough {
2761 border-radius: 5px;
2762 }
2763 }
2764
2765 // the backing bit
2766 > trough {
2767 @extend %scale_trough;
2768 }
2769
2770 // the colored part of the backing bit
2771 > trough > highlight { @extend %scale_highlight; }
2772
2773 // this is another differently styled part of the backing bit, the most relevant use case is for example
2774 // in media player to indicate how much video stream as been cached
2775 > trough > fill {
2776 @extend %scale_trough;
2777
2778
2779 &:disabled {
2780 border-color: transparent;
2781 background-color: transparent;
2782 }
2783
2784 // OSD
2785 .osd & {
2786 background-color: mix($osd_fg_color, $osd_borders_color, 25%);
2787
2788 &:disabled {
2789 border-color: transparent;
2790 background-color: transparent;
2791 }
2792 }
2793 }
2794
2795 > trough > slider {
2796 @include button(normal);
2797 border-width: 1px;
2798 border-style: solid;
2799 border-radius: 100%;
2800 transition: $button_transition;
2801 transition-property: background, border, box-shadow;
2802
2803 &:hover { @include button(hover); }
2804
2805 &:active { border-color: $selected_borders_color; }
2806
2807 &:disabled { @include button(insensitive); }
2808
2809 // ...on selected list rows
2810 row:selected & { &:disabled, & { border-color: $selected_borders_color; } }
2811
2812 // OSD
2813 .osd & {
2814 @include button(osd);
2815 border-color: darken($osd_borders_color, 3%);
2816 background-color: opacify($osd_bg_color, 1); // solid background needed here
2817
2818 &:hover {
2819 @include button(osd-hover);
2820 background-color: opacify($osd_bg_color, 1); // solid background needed here
2821 }
2822
2823 &:active {
2824 @include button(osd-active);
2825 background-color: opacify($osd_bg_color, 1); // solid background needed here
2826 }
2827
2828 &:disabled {
2829 @include button(osd-insensitive);
2830 background-color: opacify($osd_bg_color, 1); // solid background needed here
2831 }
2832 }
2833 }
2834
2835 > value {
2836 color: gtkalpha(currentColor, 0.55);
2837 font-feature-settings: "tnum";
2838 }
2839
2840 &.horizontal {
2841 > marks {
2842 color: gtkalpha(currentColor, 0.55);
2843 &.top { margin-bottom: $_marks_distance; }
2844 &.bottom { margin-top: $_marks_distance; }
2845
2846 indicator {
2847 background-color: currentColor;
2848 min-height: $_marks_length;
2849 min-width: 1px;
2850 }
2851 }
2852
2853 &:not(.marks-before) {
2854 > value.top { margin-bottom: $_marks_size; }
2855 }
2856
2857 &:not(.marks-after) {
2858 > value.bottom { margin-top: $_marks_size; }
2859 }
2860
2861 > value.left { margin-right: 9px; }
2862 > value.right { margin-left: 9px; }
2863
2864 &.fine-tune >marks {
2865 &.top { margin-top: 3px; }
2866 &.bottom { margin-bottom: 3px; }
2867
2868 indicator { min-height: ($_marks_length - 3px); }
2869 }
2870 }
2871
2872 &.vertical {
2873 > marks {
2874 color: gtkalpha(currentColor, 0.55);
2875 &.top { margin-right: $_marks_distance; }
2876 &.bottom { margin-left: $_marks_distance; }
2877
2878 indicator {
2879 background-color: currentColor;
2880 min-height: 1px;
2881 min-width: $_marks_length;
2882 }
2883 }
2884
2885 &:not(.marks-before) {
2886 > value.left { margin-right: $_marks_size; }
2887 }
2888
2889 &:not(.marks-after) {
2890 > value.right { margin-left: $_marks_size; }
2891 }
2892
2893 > value.top { margin-bottom: 9px; }
2894 > value.bottom { margin-top: 9px; }
2895
2896 &.fine-tune >marks {
2897 &.top { margin-left: 3px; }
2898 &.bottom { margin-right: 3px; }
2899
2900 indicator { min-width: ($_marks_length - 3px); }
2901 }
2902 }
2903
2904 // *WARNING* scale with marks madness following
2905
2906 // FIXME: OSD and selected list rows missing, I don't feel like adding the other 144 assets needed for those...
2907
2908 @each $dir_class, $dir_infix in ('horizontal', 'horz'),
2909 ('vertical', 'vert') {
2910 @each $marks_infix, $marks_class in ('scale-has-marks-above', 'marks-before:not(.marks-after)'),
2911 ('scale-has-marks-below', 'marks-after:not(.marks-before)') {
2912 @each $state, $state_infix in ('', ''),
2913 (':hover', '-hover'),
2914 (':active', '-active'),
2915 (':disabled', '-insensitive') {
2916 &.#{$dir_class}.#{$marks_class} {
2917
2918 > trough > slider {
2919 &#{$state} {
2920 // an asymmetric slider asset is used here, so the margins are uneven, the smaller
2921 // margin is set on the point side.
2922 margin: -10px;
2923 $_scale_asset: '#{$assets}/#{$asset_prefix}slider-#{$dir_infix}-#{$marks_infix}#{$state_infix}#{$asset_suffix}';
2924 border-style: none;
2925 border-radius: 0;
2926
2927 background-color: transparent;
2928 background-image: -gtk-scaled(url('#{$_scale_asset}.png'), url('#{$_scale_asset}@2.png'));
2929
2930 $_scale_slider_bg_pos: bottom;
2931
2932 @if $dir_class == 'horizontal' {
2933 min-height: 26px;
2934 min-width: 22px;
2935
2936 @if $marks_infix == 'scale-has-marks-above' {
2937 margin-top: -14px;
2938
2939 $_scale_slider_bg_pos: top;
2940 }
2941
2942 @else { margin-bottom: -14px; }
2943 }
2944
2945 @else {
2946 min-height: 22px;
2947 min-width: 26px;
2948
2949 @if $marks_infix == 'scale-has-marks-above' {
2950 margin-left: -14px;
2951
2952 $_scale_slider_bg_pos: left bottom;
2953 }
2954
2955 @else {
2956 margin-right: -14px;
2957
2958 $_scale_slider_bg_pos: right bottom;
2959 }
2960 }
2961
2962 background-position: $_scale_slider_bg_pos;
2963 background-repeat: no-repeat;
2964 box-shadow: none;
2965 }
2966 }
2967
2968 &.fine-tune > trough > slider {
2969 @if $dir_class == 'horizontal' {
2970 // bigger negative margins to make the trough grow here as well
2971 margin: -7px;
2972
2973 @if $marks_infix == 'scale-has-marks-above' { margin-top: -11px; }
2974
2975 @else { margin-bottom: -11px; }
2976 }
2977
2978 @else {
2979 margin: -7px;
2980
2981 @if $marks_infix == 'scale-has-marks-above' { margin-left: -11px; }
2982
2983 @else { margin-right: -11px; }
2984 }
2985 }
2986 }
2987 }
2988 }
2989 }
2990
2991 &.color {
2992 padding: 0;
2993
2994 > trough {
2995 border: none;
2996 background: none;
2997 border-radius: 10px;
2998 outline-offset: 1px;
2999
3000 > slider {
3001 margin: 0;
3002 opacity: .8;
3003 }
3004 }
3005
3006 &.fine-tune {
3007 &.vertical {
3008 padding-left: 2px;
3009 padding-right: 2px;
3010
3011 > trough > slider {
3012 margin-left: -2px;
3013 margin-right: -2px;
3014 }
3015 }
3016
3017 &.horizontal {
3018 padding-top: 2px;
3019 padding-bottom: 2px;
3020
3021 > trough > slider {
3022 margin-top: -2px;
3023 margin-bottom: -2px;
3024 }
3025 }
3026 }
3027 }
3028 }
3029
3030
3031 /*****************
3032 * Progress bars *
3033 *****************/
3034 progressbar {
3035 // sizing
3036 &.horizontal {
3037 > trough {
3038 min-width: 150px;
3039 &, > progress { min-height: 2px; }
3040 }
3041 }
3042
3043 &.vertical {
3044 > trough {
3045 min-height: 80px;
3046 &, > progress { min-width: 2px; }
3047 }
3048 }
3049
3050 &.horizontal > trough > progress { margin: 0 -1px; } // the progress node is positioned after the trough border
3051 &.vertical > trough > progress { margin: -1px 0; } // this moves it over it.
3052
3053
3054 // FIXME: insensitive state missing and some other state should be set probably
3055 font-size: smaller;
3056 color: transparentize($fg_color, 0.6);
3057 font-feature-settings: "tnum";
3058
3059 > trough { @extend %scale_trough; }
3060
3061 > trough > progress {
3062 @extend %scale_highlight; /* share most of scales' */
3063 /* override insensitive that is specific to progress */
3064 &:disabled {
3065 background-color: $insensitive_fg_color;
3066 border-color: $insensitive_fg_color;
3067 }
3068
3069 border-radius: 1.5px;
3070 $_progress-radius: 5px;
3071 &.left {
3072 border-top-left-radius: $_progress-radius;
3073 border-bottom-left-radius: $_progress-radius;
3074 }
3075
3076 &.right {
3077 border-top-right-radius: $_progress-radius;
3078 border-bottom-right-radius: $_progress-radius;
3079 }
3080
3081 &.top {
3082 border-top-right-radius: $_progress-radius;
3083 border-top-left-radius: $_progress-radius;
3084 }
3085
3086 &.bottom {
3087 border-bottom-right-radius: $_progress-radius;
3088 border-bottom-left-radius: $_progress-radius;
3089 }
3090 }
3091
3092 &.osd { // progressbar.osd used for epiphany page loading progress
3093 min-width: 3px;
3094 min-height: 3px;
3095 background-color: transparent;
3096
3097 > trough {
3098 border-style: none;
3099 border-radius: 0;
3100 background-color: transparent;
3101 box-shadow: none;
3102
3103 > progress {
3104 border-style: none;
3105 border-radius: 0;
3106 }
3107 }
3108 }
3109
3110 > trough.empty > progress { all: unset; } // makes the progress indicator disappear, when the fraction is 0
3111 }
3112
3113 /*************
3114 * Level Bar *
3115 *************/
3116
3117 $_levelbar_size: 9px;
3118 $_levelbar_border_radius: 5px;
3119
3120 levelbar {
3121 &.horizontal {
3122 trough > block {
3123 min-height: $_levelbar_size;
3124 border-radius: $_levelbar_border_radius;
3125
3126 &:dir(rtl) {
3127 border-radius: 0 $_levelbar_border_radius $_levelbar_border_radius 0;
3128 }
3129
3130 &:dir(ltr) {
3131 border-radius: $_levelbar_border_radius 0 0 $_levelbar_border_radius;
3132 }
3133
3134 &.empty,&.full {
3135 border-radius: $_levelbar_border_radius;
3136 }
3137 }
3138
3139 // segmented level bar
3140 &.discrete {
3141 trough > block {
3142 min-height: 2px;
3143 margin: 1px;
3144 min-width: 24px;
3145 border-radius:0;
3146 &:first-child {border-radius: 2px 0 0 2px;}
3147 &:last-child {
3148 border-radius: 0 2px 2px 0;
3149 }
3150 }
3151 }
3152 }
3153
3154 &.vertical {
3155 trough > block {
3156 min-width: $_levelbar_size;
3157 border-radius: $_levelbar_border_radius;
3158 }
3159
3160 &.discrete > trough > block {
3161 min-width: $_levelbar_size - 7px;
3162 margin: 1px 0;
3163 min-height: 32px;
3164 }
3165 }
3166
3167 > trough {
3168 padding: 0;
3169 }
3170
3171 // level bar colours
3172 > trough > block {
3173 border: 1px solid;
3174
3175 &.low {
3176 border-color: $warning_color;
3177 background-color: $warning_color;
3178 }
3179
3180 &.high,
3181 &:not(.empty) {
3182 border-color: $selected_bg_color;
3183 background-color: $selected_bg_color;
3184 }
3185
3186 &.full {
3187 border-color: $success_color;
3188 background-color: $success_color;
3189 }
3190
3191 &.empty {
3192 background-color: darken($bg_color, 5%);
3193 border-color: darken($bg_color, 5%);
3194 }
3195 }
3196 }
3197
3198
3199 /****************
3200 * Print dialog *
3201 *****************/
3202 window.dialog.print {
3203 page-thumbnail {
3204 background: white;
3205 color: #2e3436;
3206 border: 1px solid $borders_color;
3207
3208 label {
3209 color: #2e3436;
3210 }
3211 }
3212
3213 .drawing {
3214 color: $fg_color;
3215 background: none;
3216 border: none;
3217 padding: 0;
3218 }
3219
3220 .dialog-action-box { margin: 12px; }
3221 }
3222
3223
3224 /**********
3225 * Frames *
3226 **********/
3227 frame,
3228 .frame {
3229 border: 1px solid $borders_color;
3230 }
3231
3232 frame {
3233 border-radius: $window_radius;
3234
3235 > label {
3236 margin: 4px;
3237 }
3238 }
3239
3240 actionbar > revealer > box {
3241 padding: 6px;
3242 border-top: 1px solid $borders_color;
3243
3244 &, > box.start, > box.end {
3245 border-spacing: 6px;
3246 }
3247 }
3248
3249 scrolledwindow {
3250 // This is used when content is touch-dragged past boundaries.
3251 // draws a box on top of the content, the size changes programmatically.
3252 > overshoot {
3253 &.top {
3254 @include overshoot(top);
3255 }
3256
3257 &.bottom {
3258 @include overshoot(bottom);
3259 }
3260
3261 &.left {
3262 @include overshoot(left);
3263 }
3264
3265 &.right {
3266 @include overshoot(right);
3267 }
3268 }
3269
3270 > junction { // the small square between two scrollbars
3271 // Only color the top-left (or top right in RTL) pixel, to visually connect
3272 // the borders of the two scrollbars.
3273
3274 background: $borders_color,
3275 linear-gradient(to bottom, transparent 1px, $scrollbar_bg_color 1px),
3276 linear-gradient(to right, transparent 1px, $scrollbar_bg_color 1px);
3277
3278 &:dir(rtl) {
3279 background: $borders_color,
3280 linear-gradient(to bottom, transparent 1px, $scrollbar_bg_color 1px),
3281 linear-gradient(to left, transparent 1px, $scrollbar_bg_color 1px);
3282 }
3283 }
3284 }
3285
3286 //vbox and hbox separators
3287 separator {
3288 background: lighten($borders_color, 5%);
3289 min-width: 1px;
3290 min-height: 1px;
3291 }
3292
3293
3294 /*********
3295 * Lists *
3296 *********/
3297 listview,
3298 list {
3299 color: $text_color;
3300 background-color: $base_color;
3301 border-color: $borders_color;
3302
3303 &:backdrop {
3304 background-color: $backdrop_base_color;
3305 border-color: $backdrop_borders_color;
3306 }
3307
3308 > row { padding: 2px; }
3309 > row.expander { padding: 0px; }
3310 > row.expander .row-header { padding: 2px; }
3311
3312 &.horizontal row.separator,
3313 &.separators.horizontal > row:not(.separator) {
3314 border-left: 1px solid $_treeview_borders_color;
3315 }
3316 &:not(.horizontal) row.separator,
3317 &.separators:not(.horizontal) > row:not(.separator) {
3318 border-bottom: 1px solid $_treeview_borders_color;
3319 }
3320 }
3321
3322 row {
3323 @include focus-ring();
3324
3325 &.activatable {
3326 &.has-open-popup, // this is for indicathing which row generated a popover see https://bugzilla.gnome.org/show_bug.cgi?id=754411
3327
3328 &:hover { background-color: if(variant == light, transparentize($fg_color, 0.9), transparentize($fg_color, 0.95)); }
3329
3330 &:active { box-shadow: inset 0 2px 2px -2px transparentize(black, 0.8); }
3331
3332 &:selected {
3333 &:active { box-shadow: inset 0 2px 3px -1px transparentize(black, 0.5); }
3334
3335 &.has-open-popup,
3336 &:hover { background-color: mix($fg_color, $selected_bg_color, 10%); }
3337 }
3338 }
3339
3340 &:selected {
3341 outline-color: $alt_focus_border_color;
3342
3343 @extend %selected_items;
3344 }
3345 }
3346
3347 listview:not(:focus-within) > row:selected {
3348 background-color: $backdrop_selected_bg_color;
3349 }
3350
3351 columnview {
3352 // move padding to child cells
3353 > listview > row {
3354 padding: 0;
3355
3356 // align horizontal sizing with header buttons
3357 > cell {
3358 padding: 8px 6px;
3359
3360 &:not(:first-child) {
3361 border-left: 1px solid transparent;
3362 }
3363 }
3364 }
3365
3366 // make column separators visible when :show-column-separators is true
3367 &.column-separators > listview > row > cell {
3368 border-left-color: $_treeview_borders_color;
3369 }
3370
3371 // shrink vertically for .data-table
3372 &.data-table > listview > row > cell {
3373 padding-top: 2px;
3374 padding-bottom: 2px;
3375 }
3376 }
3377
3378 treeexpander {
3379 border-spacing: 4px;
3380 indent {
3381 -gtk-icon-size: 8px;
3382 }
3383 }
3384
3385 /********************************************************
3386 * Data Tables *
3387 * treeview like tables with individual focusable cells *
3388 * https://gitlab.gnome.org/GNOME/gtk/-/issues/2929 *
3389 ********************************************************/
3390
3391 columnview row:not(:selected) cell editablelabel:not(.editing):focus-within {
3392 outline: 2px solid $focus_border_color;
3393 }
3394
3395 columnview row:not(:selected) cell editablelabel.editing:focus-within {
3396 outline: 2px solid $selected_bg_color;
3397 }
3398
3399 columnview row:not(:selected) cell editablelabel.editing text selection {
3400 background-color: $backdrop_selected_bg_color;
3401 color: transparent;
3402 &:focus-within {
3403 background-color: $selected_text_bg_color;
3404 color: $fg_color;
3405 }
3406 }
3407
3408 /*******************************************************
3409 * Rich Lists *
3410 * Large list usually containing lots of widgets *
3411 * https://gitlab.gnome.org/GNOME/gtk/-/issues/3073 *
3412 *******************************************************/
3413
3414
3415 .rich-list { /* rich lists usually containing other widgets than just labels/text */
3416 & > row, & > header {
3417 padding: 8px 12px;
3418 min-height: 32px; /* should be tall even when only containing a label */
3419
3420 & > box {
3421 border-spacing: 12px;
3422 }
3423 }
3424 & > header {
3425 @extend %osd;
3426 background-color: $osd_bg_color;
3427
3428 border-bottom: 1px solid $borders-color;
3429 border-top: 1px solid $borders-color;
3430 font-weight: bold;
3431 }
3432 }
3433
3434 /********************************************************
3435 * Complex Lists *
3436 * Put padding on the cell content so event controllers *
3437 * can cover the whole area. *
3438 ********************************************************/
3439
3440 columnview.complex {
3441 > listview > row > cell {
3442 padding: 0;
3443 > * {
3444 padding: 8px 6px;
3445 }
3446 }
3447
3448 // shrink vertically for .data-table
3449 &.data-table > listview > row > cell {
3450 padding: 0;
3451 > * {
3452 padding-top: 2px;
3453 padding-bottom: 2px;
3454 }
3455 }
3456 }
3457
3458
3459 /**********************************************************************
3460 * Boxed Lists *
3461 * Lists inside a rounded frame. Can be used together with .rich-list * *
3462 **********************************************************************/
3463
3464 .boxed-list {
3465 border-radius: $window_radius;
3466 border: 1px solid $borders_color;
3467
3468 > row {
3469 @include focus-ring($offset: -1px);
3470
3471 border-bottom: 1px solid transparentize($borders_color, 0.5);
3472
3473 &:backdrop {
3474 border-bottom-color: transparentize($backdrop_borders_color, 0.5);
3475 }
3476
3477 &:first-child {
3478 border-top-left-radius: $window_radius;
3479 border-top-right-radius: $window_radius;
3480 }
3481
3482 &:last-child {
3483 border-bottom-left-radius: $window_radius;
3484 border-bottom-right-radius: $window_radius;
3485 border-bottom: none;
3486 }
3487 }
3488 }
3489
3490 /*********************
3491 * App Notifications *
3492 *********************/
3493 .app-notification {
3494 @extend %osd;
3495
3496 padding: 10px;
3497 border-spacing: 10px;
3498 border-radius: 0 0 5px 5px;
3499 background-color: $osd_bg_color;
3500 background-image: linear-gradient(to bottom, transparentize(black, 0.8),
3501 transparent 2px);
3502 background-clip: padding-box;
3503
3504 button { @extend %osd_button; }
3505
3506 border { border: none; }
3507 }
3508
3509
3510 /*************
3511 * Expanders *
3512 *************/
3513 expander {
3514 min-width: 16px;
3515 min-height: 16px;
3516 -gtk-icon-source: -gtk-icontheme('pan-end-symbolic');
3517 &:dir(rtl) { -gtk-icon-source: -gtk-icontheme('pan-end-symbolic-rtl'); }
3518
3519 &:disabled { color: $insensitive_fg_color; }
3520
3521 &:checked { -gtk-icon-source: -gtk-icontheme('pan-down-symbolic'); }
3522 }
3523
3524 expander-widget {
3525 @include focus-ring("> box > title");
3526
3527 > box > title {
3528 transition: $focus_transition;
3529 border-radius: $button_radius;
3530
3531 &:hover > expander {
3532 color: lighten($fg_color,30%); //only lightens the icon
3533 }
3534 }
3535 }
3536
3537 .navigation-sidebar,
3538 placessidebar,
3539 stackswitcher,
3540 expander-widget {
3541 &:not(decoration):not(window):drop(active):focus,
3542 &:not(decoration):not(window):drop(active) {
3543 box-shadow: none;
3544 }
3545 }
3546
3547
3548 /************
3549 * Calendar *
3550 ***********/
3551 calendar {
3552 color: $text_color;
3553 border: 1px solid $borders_color;
3554 font-feature-settings: "tnum";
3555
3556 > header {
3557 border-bottom: 1px solid $borders_color;
3558
3559 > button {
3560 border: none;
3561 box-shadow: none;
3562 background: none;
3563 border-radius: 0;
3564 }
3565 > button:backdrop {
3566 background: none;
3567 }
3568 }
3569
3570 > grid {
3571 > label.day-name {
3572 }
3573
3574 > label.week-number {
3575 }
3576
3577 > label.today {
3578 box-shadow: inset 0px -2px $borders_color;
3579
3580 &:selected {
3581 box-shadow: none;
3582 }
3583 }
3584
3585 > label:focus {
3586 outline-color: $focus_border_color;
3587 outline-offset: -2px;
3588 outline-width: 2px;
3589 outline-style: solid;
3590 }
3591
3592 > label.day-number {
3593 padding: 4px;
3594
3595 &:selected{
3596 @extend %selected_items;
3597 border-radius: 3px;
3598 }
3599
3600 &:checked {
3601 background-color: gtkalpha($selected_bg_color, 0.3);
3602 }
3603 }
3604
3605 > label.day-number.other-month {
3606 color: gtkalpha(currentColor, 0.3);
3607 }
3608 }
3609
3610 }
3611
3612
3613 /***********
3614 * Dialogs *
3615 ***********/
3616 window.dialog.message { // Message Dialog styling
3617 .titlebar {
3618 min-height: 20px;
3619 background-image: none;
3620 background-color: $bg_color;
3621 border-style: none;
3622 border-top-left-radius: 7px;
3623 border-top-right-radius: 7px;
3624 }
3625
3626 box.dialog-vbox.vertical {
3627 border-spacing: 10px;
3628 }
3629
3630 & label.title {
3631 font-weight: 800;
3632 font-size: 150%;
3633 }
3634
3635 &.csd { // rounded bottom border styling for csd version
3636 &.background {
3637 // bigger radius for better antialiasing
3638 border-bottom-left-radius: $window_radius+1;
3639 border-bottom-right-radius: $window_radius+1;
3640 }
3641
3642 .dialog-action-area button {
3643 padding: 10px 14px; // labels are not vertically centered on message dialog, this is a workaround
3644 border-radius: 0;
3645 border-left-style: solid;
3646 border-right-style: none;
3647 border-bottom-style: none;
3648
3649 &:first-child{
3650 border-left-style: none;
3651 border-bottom-left-radius: 7px;
3652 }
3653
3654 &:last-child {
3655 border-bottom-right-radius: 7px;
3656 }
3657 }
3658 }
3659 }
3660
3661 filechooser {
3662 .dialog-action-box {
3663 border-top: 1px solid $borders_color;
3664 }
3665
3666 #pathbarbox { border-bottom: 1px solid $bg_color; }
3667
3668 gridview child {
3669 border-radius: 12px;
3670 margin: 12px;
3671
3672 &:hover {
3673 background-color: gtkalpha(currentColor, .04);
3674 }
3675
3676 &:active {
3677 background-color: gtkalpha(currentColor, .08);
3678 }
3679
3680 &:selected {
3681 background-color: gtkalpha($selected_bg_color, .15);
3682 color: inherit;
3683 }
3684
3685 &:selected:hover {
3686 background-color: gtkalpha($selected_bg_color, .20);
3687 }
3688
3689 &:selected:active {
3690 background-color: gtkalpha($selected_bg_color, .25);
3691 }
3692
3693 & filethumbnail image {
3694 filter: drop-shadow(0px 1px 1px rgba(0,0,0,0.3));
3695 }
3696 }
3697 }
3698
3699
3700 filechooserbutton>button>box {
3701 border-spacing: 6px;
3702 }
3703 filechooserbutton:drop(active) {
3704 box-shadow: none;
3705 border-color: transparent;
3706 }
3707
3708
3709 /***********
3710 * Sidebar *
3711 ***********/
3712 .sidebar {
3713 background-color: mix($bg_color, $base_color, 50%);
3714
3715 &:not(separator) {
3716 @at-root %sidebar_left,
3717 &:dir(ltr),
3718 &.left,
3719 &.left:dir(rtl) {
3720 border-right: 1px solid $borders_color;
3721 border-left-style: none;
3722 }
3723
3724 @at-root %sidebar_right,
3725 &:dir(rtl),
3726 &.right {
3727 border-left: 1px solid $borders_color;
3728 border-right-style: none;
3729 }
3730 }
3731
3732 listview.view,
3733 list { background-color: transparent; }
3734
3735 paned & { &.left, &.right, &.left:dir(rtl), &:dir(rtl), &:dir(ltr), & { border-style: none; }}
3736 }
3737
3738 stacksidebar {
3739 //not a regular list
3740 list.separators:not(.horizontal) > row:not(.separator) {
3741 border-bottom: none;
3742 }
3743 row {
3744 padding: 10px 4px;
3745 @include focus-ring();
3746
3747 > label {
3748 padding-left: 6px;
3749 padding-right: 6px;
3750 }
3751
3752 &.needs-attention > label {
3753 @extend %needs_attention;
3754 background-size: 6px 6px, 0 0;
3755 }
3756 &:selected {
3757 background-color: $menu_selected_color;
3758 border-radius: $menu_radius;
3759 color: $fg_color;
3760 }
3761 &:selected:hover:dir(ltr), &:selected:hover:dir(rtl) {
3762 background-color: darken($menu_selected_color,5%);
3763 }
3764 &.activatable:active, &.activatable:selected:active {
3765 box-shadow: none; // #3413
3766 }
3767 }
3768 }
3769
3770 separator.sidebar {
3771 background-color: $borders_color;
3772 }
3773
3774
3775 /**********************
3776 * Navigation Sidebar *
3777 **********************/
3778
3779 .navigation-sidebar {
3780 padding: $menu-margin 0; //only vertical padding. horizontal row size would clip
3781
3782 > separator {
3783 margin: $menu-margin;
3784 }
3785
3786 > row {
3787 min-height: 36px;
3788 padding: 0 8px;
3789 border-radius: $menu-margin;
3790 margin: 0 $menu-margin 2px;
3791 @include focus-ring($focus-state: 'focus-visible:focus-within');
3792 &:hover {
3793 background-color: darken($menu_selected_color, 5%);
3794 }
3795
3796 &:selected {
3797 background-color: $menu_selected_color;
3798 color: inherit;
3799
3800 @if $contrast == 'high' {
3801 box-shadow: inset 0 0 0 1px $borders_color;
3802 }
3803
3804
3805 &:hover {
3806 background-color: darken($menu_selected_color,5%);
3807 }
3808
3809 }
3810
3811 &:disabled { color: $insensitive_fg_color; }
3812 }
3813 }
3814
3815
3816 /****************
3817 * File chooser *
3818 ****************/
3819
3820 $_placesidebar_icons_opacity: 0.7;
3821
3822 row image.sidebar-icon { opacity: $_placesidebar_icons_opacity; } // dim the sidebar icons
3823 // see bug #786613 for details
3824 // on this oddity
3825
3826 /* this should be more generic, only using .navigation-sidebar
3827 https://gitlab.gnome.org/GNOME/gtk/-/issues/2929
3828 */
3829
3830 placessidebar {
3831 .navigation-sidebar > row {
3832 // Needs overriding of the `.navigation-sidebar > row` padding
3833 padding: 0;
3834
3835 // Using margins/padding directly in the SidebarRow
3836 // will make the animation of the new bookmark row jump
3837 > revealer { padding: 0 14px; }
3838
3839 image.sidebar-icon {
3840 &:dir(ltr) { padding-right: 8px; }
3841 &:dir(rtl) { padding-left: 8px; }
3842 }
3843
3844 label.sidebar-label {
3845 &:dir(ltr) { padding-right: 2px; }
3846 &:dir(rtl) { padding-left: 2px; }
3847 }
3848
3849 @at-root button.sidebar-button {
3850 @extend %button_basic_flat;
3851
3852 @extend %button_selected_flat;
3853 min-height: 26px;
3854 min-width: 26px;
3855 margin-top: 3px;
3856 margin-bottom: 3px;
3857 padding: 0;
3858 border-radius: 100%;
3859 }
3860
3861 // in the sidebar case it makes no sense to click the selected row
3862 &:selected:active { box-shadow: none; }
3863
3864 &.sidebar-placeholder-row {
3865 padding: 0 8px;
3866 min-height: 2px;
3867 background-image: image($drop_target_color);
3868 background-clip: content-box;
3869 }
3870
3871 &.sidebar-new-bookmark-row { color: $selected_bg_color; }
3872
3873 &:drop(active):not(:disabled) {
3874 color: $drop_target_color;
3875 box-shadow: inset 0 1px $drop_target_color,
3876 inset 0 -1px $drop_target_color;
3877
3878 &:selected {
3879 color: $selected_fg_color;
3880 background-color: $drop_target_color;
3881 }
3882 }
3883 }
3884 }
3885
3886 placesview {
3887 .server-list-button > image {
3888 transition: 200ms $ease-out-quad;
3889 -gtk-icon-transform: rotate(0turn);
3890 }
3891
3892 .server-list-button:checked > image {
3893 transition: 200ms $ease-out-quad;
3894 -gtk-icon-transform: rotate(-0.5turn);
3895 }
3896
3897 row.activatable:hover { }
3898
3899 > actionbar > revealer > box > box{
3900 border-spacing: 6px;
3901 }
3902 }
3903
3904
3905 /*********
3906 * Paned *
3907 *********/
3908 paned {
3909 > separator {
3910 min-width: 1px;
3911 min-height: 1px;
3912 -gtk-icon-source: none; // defeats the ugly default handle decoration
3913 border-style: none; // just to be sure
3914 background-color: transparent;
3915 // workaround, using background instead of a border since the border will get rendered twice (?)
3916 background-image: image($borders_color);
3917 background-size: 1px 1px;
3918
3919 &:selected { background-image: image($selected_bg_color); } // FIXME is this needed?
3920
3921 &.wide {
3922 min-width: 5px;
3923 min-height: 5px;
3924 background-color: $bg_color;
3925 background-image: image($borders_color), image($borders_color);
3926 background-size: 1px 1px, 1px 1px;
3927 }
3928 }
3929
3930 &.horizontal > separator {
3931 background-repeat: repeat-y;
3932
3933 &:dir(ltr) {
3934 margin: 0 -8px 0 0;
3935 padding: 0 8px 0 0;
3936 background-position: left;
3937 }
3938 &:dir(rtl) {
3939 margin: 0 0 0 -8px;
3940 padding: 0 0 0 8px;
3941 background-position: right;
3942 }
3943
3944 &.wide {
3945 margin: 0;
3946 padding: 0;
3947 background-repeat: repeat-y, repeat-y;
3948 background-position: left, right;
3949 }
3950 }
3951
3952 &.vertical > separator {
3953 margin: 0 0 -8px 0;
3954 padding: 0 0 8px 0;
3955 background-repeat: repeat-x;
3956 background-position: top;
3957
3958 &.wide {
3959 margin: 0;
3960 padding: 0;
3961 background-repeat: repeat-x, repeat-x;
3962 background-position: bottom, top;
3963 }
3964 }
3965 }
3966
3967
3968 /**************
3969 * GtkVideo *
3970 **************/
3971
3972 video {
3973 & image.osd {
3974 min-width: 64px;
3975 min-height: 64px;
3976 border-radius: 32px;
3977 }
3978 }
3979
3980 /************
3981 * Tooltips *
3982 ************/
3983 tooltip {
3984 &.background {
3985 // background-color needs to be set this way otherwise it gets drawn twice
3986 // see https://bugzilla.gnome.org/show_bug.cgi?id=736155 for details.
3987 background-color: transparentize(black, 0.2);
3988 background-clip: padding-box;
3989 border: 1px solid $tooltip_borders_color; // this subtle border is meant to
3990 // not make the tooltip melt with
3991 // very dark backgrounds
3992 color: white;
3993 }
3994
3995 padding: 6px 10px;
3996 border-radius: $window_radius;
3997 box-shadow: none; // otherwise it gets inherited by windowframe.csd
3998
3999 > box {
4000 border-spacing: 6px;
4001 }
4002 }
4003
4004
4005 /*****************
4006 * Color Chooser *
4007 *****************/
4008 colorswatch {
4009 // This widget is made of two boxes one on top of the other, the lower box is colorswatch {} the other one
4010 // is colorswatch overlay {}, colorswatch has the programmatically set background, so most of the style is
4011 // applied to the overlay box.
4012
4013 transition: $focus_transition;
4014
4015 @include focus-ring($width: 4px, $offset: -2px);
4016
4017 &:drop(active), & { border-style: none; } // FIXME: implement a proper drop(active) state
4018
4019 $_colorswatch_radius: 5px;
4020
4021 // base color corners rounding
4022 // to avoid the artifacts caused by rounded corner anti-aliasing the base color
4023 // sports a bigger radius.
4024 // nth-child is needed by the custom color strip.
4025
4026 &.top {
4027 border-top-left-radius: $_colorswatch_radius + 0.5px;
4028 border-top-right-radius: $_colorswatch_radius + 0.5px;
4029
4030 > overlay {
4031 border-top-left-radius: $_colorswatch_radius;
4032 border-top-right-radius: $_colorswatch_radius;
4033 }
4034 }
4035
4036 &.bottom {
4037 border-bottom-left-radius: $_colorswatch_radius + 0.5px;
4038 border-bottom-right-radius: $_colorswatch_radius + 0.5px;
4039
4040 > overlay {
4041 border-bottom-left-radius: $_colorswatch_radius;
4042 border-bottom-right-radius: $_colorswatch_radius;
4043 }
4044 }
4045
4046 &.left,
4047 &:first-child:not(.top) {
4048 border-top-left-radius: $_colorswatch_radius + 0.5px;
4049 border-bottom-left-radius: $_colorswatch_radius + 0.5px;
4050
4051 > overlay {
4052 border-top-left-radius: $_colorswatch_radius;
4053 border-bottom-left-radius: $_colorswatch_radius;
4054 }
4055 }
4056
4057 &.right,
4058 &:last-child:not(.bottom) {
4059 border-top-right-radius: $_colorswatch_radius + 0.5px;
4060 border-bottom-right-radius: $_colorswatch_radius + 0.5px;
4061
4062 > overlay {
4063 border-top-right-radius: $_colorswatch_radius;
4064 border-bottom-right-radius: $_colorswatch_radius;
4065 }
4066 }
4067
4068 &.dark {
4069 > overlay {
4070 color: white;
4071 }
4072
4073 &.activatable:hover > overlay {
4074 border-color: if($variant == 'light', transparentize(black, 0.2), $borders_color);
4075 }
4076 }
4077
4078 &.light {
4079 > overlay {
4080 color: black;
4081 }
4082
4083 &.activatable:hover > overlay {
4084 border-color: if($variant == 'light', transparentize(black, 0.5), $borders_color);
4085 }
4086 }
4087
4088 &:drop(active) {
4089 box-shadow: none;
4090
4091 &.light > overlay {
4092 border-color: $drop_target_color;
4093 box-shadow: inset 0 0 0 2px if($variant == 'light', darken($drop_target_color, 7%), $borders_color),
4094 inset 0 0 0 1px $drop_target_color;
4095 }
4096
4097 &.dark > overlay {
4098 border-color: $drop_target_color;
4099 box-shadow: inset 0 0 0 2px if($variant == 'light', transparentize(black, 0.7), $borders_color),
4100 inset 0 0 0 1px $drop_target_color;
4101 }
4102 }
4103
4104 > overlay {
4105 border: 1px solid if($variant == 'light', transparentize(black, 0.7), $borders_color);
4106 }
4107
4108 &.activatable:hover > overlay {
4109 box-shadow: inset 0 1px transparentize(white, 0.6),
4110 inset 0 -1px transparentize(black, 0.8);
4111 }
4112
4113 &#add-color-button {
4114 border-radius: $_colorswatch_radius 0 0 $_colorswatch_radius;
4115
4116 &:only-child { border-radius: $_colorswatch_radius; }
4117
4118 > overlay {
4119 @include button(normal);
4120 }
4121
4122 &.activatable:hover > overlay {
4123 @include button(hover);
4124 }
4125 }
4126
4127 &:disabled {
4128 opacity: 0.5;
4129
4130 > overlay {
4131 border-color: transparentize(black, 0.4);
4132 box-shadow: none;
4133 }
4134 }
4135
4136 row:selected & { box-shadow: 0 0 0 2px $selected_fg_color; }
4137
4138 &#editor-color-sample {
4139 border-radius: 4px;
4140
4141 > overlay { border-radius: 4.5px; }
4142 }
4143 }
4144
4145 plane {
4146 transition: $focus_transition;
4147
4148 @include focus-ring($offset: 2px, $outer: true);
4149 }
4150
4151 // colorscale popup
4152 colorchooser .popover.osd { border-radius: 5px; }
4153
4154 /********
4155 * Misc *
4156 ********/
4157 .content-view {
4158 background-color: darken($bg_color,7%);
4159
4160 &:hover { -gtk-icon-filter: brightness(1.2); }
4161
4162 .tile {
4163 margin: 2px;
4164 background-color: if($variant=='light', transparent, black);
4165 border-radius: 0;
4166 padding: 0;
4167
4168 &:active, &:selected { background-color: if($variant=='light', transparent, $selected_bg_color); }
4169 &:disabled { background-color: if($variant=='light', transparent, $insensitive_bg_color); }
4170 }
4171
4172 > rubberband { @extend rubberband; }
4173
4174 }
4175
4176 .scale-popup {
4177 .osd & { @extend %osd; }
4178
4179 .osd & button.flat { //FIXME: quick hack, redo properly
4180 border-style: none;
4181 border-radius: 5px;
4182 }
4183
4184 button { // +/- buttons on GtkVolumeButton popup
4185 &:hover {
4186 @extend %undecorated_button;
4187 background-color: transparentize($fg_color,0.9);
4188 border-radius: 5px;
4189 }
4190 }
4191 }
4192
4193
4194 /**********************
4195 * Window Decorations *
4196 *********************/
4197 window {
4198 // lamefun trick to get rounded borders regardless of CSD use
4199 border-width: 0px;
4200
4201 // this needs to be transparent
4202 // see bug #722563
4203 $_wm_border: if($variant=='light', transparentize(black, 0.77), transparentize(black, 0.25));
4204 $_wm_border_backdrop: if($variant=='light', transparentize(black, 0.82), transparentize(black, 0.25));
4205
4206 &.csd {
4207 box-shadow: 0 3px 9px 1px transparentize(black, 0.5),
4208 0 0 0 1px $_wm_border; //doing borders with box-shadow
4209 margin: 0px;
4210 border-radius: $window_radius $window_radius 0 0;
4211 &:backdrop {
4212 // the transparent shadow here is to enforce that the shadow extents don't
4213 // change when we go to backdrop, to prevent jumping windows.
4214 // The biggest shadow should be in the same order then in the active state
4215 // or the jumping will happen during the transition.
4216 box-shadow: 0 3px 9px 1px transparent,
4217 0 2px 6px 2px transparentize(black, 0.8),
4218 0 0 0 1px $_wm_border_backdrop;
4219 transition: $backdrop_transition;
4220 }
4221
4222 &.popup {
4223 border-radius: $menu_radius;
4224 box-shadow: 0 1px 2px transparentize(black, 0.8),
4225 0 0 0 1px transparentize($_wm_border, 0.1);
4226 }
4227
4228 &.dialog.message {
4229 border-radius: $window_radius;
4230 box-shadow: 0 1px 2px transparentize(black, 0.8),
4231 0 0 0 1px transparentize($_wm_border, 0.1);
4232 }
4233 }
4234
4235 &.solid-csd {
4236 margin: 0;
4237 padding: 4px;
4238 border: solid 1px $borders_color;
4239 border-radius: 0;
4240 box-shadow: inset 0 0 0 4px $borders_color, inset 0 0 0 3px $headerbar_bg_color, inset 0 1px $top_hilight;
4241
4242 &:backdrop { box-shadow: inset 0 0 0 4px $borders_color, inset 0 0 0 3px $backdrop_bg_color, inset 0 1px $top_hilight; }
4243 }
4244
4245 &.maximized,
4246 &.fullscreen { border-radius: 0; box-shadow: none; }
4247
4248 &.tiled,
4249 &.tiled-top,
4250 &.tiled-left,
4251 &.tiled-right,
4252 &.tiled-bottom {
4253 border-radius: 0;
4254 box-shadow: 0 0 0 1px $_wm_border,
4255 0 0 0 20px transparent; //transparent control workaround -- #3670
4256
4257 &:backdrop { box-shadow: 0 0 0 1px $_wm_border_backdrop,
4258 0 0 0 20px transparent; // #3670
4259 }
4260 }
4261
4262 &.popup { box-shadow: none; }
4263
4264 // server-side decorations as used by mutter
4265 &.ssd { box-shadow: 0 0 0 1px $_wm_border; } //just doing borders, wm draws actual shadows
4266
4267 }
4268
4269 tooltip.csd {
4270 border-radius: 5px;
4271 box-shadow: none;
4272 }
4273
4274 // catch all extend :)
4275
4276 %selected_items {
4277 background-color: $selected_bg_color;
4278
4279 @at-root %nobg_selected_items, & {
4280 color: $selected_fg_color;
4281
4282 @at-root %selected_items_disabled,
4283 &:disabled { color: mix($selected_fg_color, $selected_bg_color, 50%); }
4284
4285 }
4286 }
4287
4288 .monospace { font-family: monospace; }
4289
4290
4291 /**********************
4292 * Touch Copy & Paste *
4293 *********************/
4294 //touch selection handlebars for the Popover.osd above
4295 cursor-handle {
4296 background-color: transparent;
4297 background-image: none;
4298 box-shadow: none;
4299 border-style: none;
4300 min-width: 20px;
4301 min-height: 24px;
4302 padding-left: 20px;
4303 padding-right: 20px;
4304 padding-top: 24px;
4305 padding-bottom: 24px;
4306
4307 @each $s,$as in ('',''),
4308 (':hover','-hover'),
4309 (':active','-active') { //no need for insensitive and backdrop
4310 &.top#{$s}:dir(ltr), &.bottom#{$s}:dir(rtl) {
4311 $_url: '#{$assets}/#{$asset_prefix}text-select-start#{$as}#{$asset_suffix}';
4312 -gtk-icon-source: -gtk-scaled(url('#{$_url}.png'),
4313 url('#{$_url}@2.png'));
4314 }
4315
4316 &.bottom#{$s}:dir(ltr), &.top#{$s}:dir(rtl) {
4317 $_url: '#{$assets}/#{$asset_prefix}text-select-end#{$as}#{$asset_suffix}';
4318 -gtk-icon-source: -gtk-scaled(url('#{$_url}.png'),
4319 url('#{$_url}@2.png'));
4320 }
4321
4322 &.insertion-cursor#{$s}:dir(ltr), &.insertion-cursor#{$s}:dir(rtl) {
4323 $_url: '#{$assets}/#{$asset_prefix}slider-horz-scale-has-marks-above#{$as}#{$asset_suffix}';
4324 -gtk-icon-source: -gtk-scaled(url('#{$_url}.png'),
4325 url('#{$_url}@2.png'));
4326 }
4327 }
4328 }
4329
4330 shortcuts-section {
4331 margin: 20px;
4332 }
4333
4334 .shortcuts-search-results {
4335 margin: 20px;
4336 border-spacing: 24px;
4337 }
4338
4339 // shortcut window keys
4340 shortcut {
4341 border-spacing: 6px;
4342 border-radius: 5px;
4343 @include focus-ring();
4344 }
4345
4346 shortcut > .keycap {
4347 min-width: 20px;
4348 min-height: 25px;
4349 margin-top: 2px;
4350 padding-bottom: 3px;
4351 padding-left: 6px;
4352 padding-right: 6px;
4353
4354 color: $fg_color;
4355 background-color: $base_color;
4356 border: 1px solid;
4357 border-color: if($variant == 'light', mix($borders_color, $bg_color, 50%), $borders_color);
4358 border-radius: 5px;
4359 box-shadow: if($variant == 'light', inset 0 -3px mix($base_color, $bg_color, 20%), inset 0 -3px mix($borders_color, $base_color, 60%));
4360 font-size: smaller;
4361
4362 }
4363
4364 :not(decoration):not(window):drop(active):focus,
4365 :not(decoration):not(window):drop(active) { // FIXME needs to be done widget by widget, this wildcard should really die
4366 border-color: $drop_target_color;
4367 box-shadow: inset 0 0 0 1px $drop_target_color;
4368 caret-color: $drop_target_color;
4369 }
4370
4371 stackswitcher > button.text-button { min-width: 100px; } // FIXME aggregate with buttons
4372
4373 stackswitcher.circular {
4374 border-spacing: 12px;
4375
4376 // FIXME aggregate with buttons
4377 > button.circular,
4378 > button.text-button.circular {
4379 min-width: 32px;
4380 min-height: 32px;
4381 padding: 0;
4382 }
4383 }
4384 /*************
4385 * App Icons *
4386 *************/
4387 /* Outline for low res icons */
4388 .lowres-icon {
4389 -gtk-icon-shadow: 0 -1px rgba(0,0,0,0.05),
4390 1px 0 rgba(0,0,0,0.1),
4391 0 1px rgba(0,0,0,0.3),
4392 -1px 0 rgba(0,0,0,0.1);
4393 }
4394
4395 /* Drapshadow for large icons */
4396 .icon-dropshadow {
4397 -gtk-icon-shadow: 0 1px 12px rgba(0,0,0,0.05),
4398 0 -1px rgba(0,0,0,0.05),
4399 1px 0 rgba(0,0,0,0.1),
4400 0 1px rgba(0,0,0,0.3),
4401 -1px 0 rgba(0,0,0,0.1);
4402 }
4403
4404 /*********
4405 * Emoji *
4406 ********/
4407
4408 popover.emoji-picker > contents {
4409 padding: 0;
4410 }
4411
4412 .emoji-searchbar {
4413 padding: 6px;
4414 border-spacing: 6px;
4415 border-bottom: 1px solid $borders_color;
4416 }
4417
4418 .emoji-toolbar {
4419 padding: 6px;
4420 border-spacing: 6px;
4421 border-top: 1px solid $borders_color;
4422 }
4423
4424 button.emoji-section {
4425 border-color: transparent;
4426 border-width: 3px;
4427 border-style: none none solid;
4428 border-radius: 0;
4429
4430 padding: 3px 0 0;
4431 min-width: 32px;
4432 min-height: 28px;
4433
4434 /* reset props inherited from the button style */
4435 background: none;
4436 box-shadow: none;
4437 text-shadow: none;
4438
4439 &:hover { border-color: if($variant == 'light', $borders_color, transparentize($fg_color, .9)); }
4440 &:checked { border-color: $selected_bg_color; }
4441 }
4442
4443 popover.emoji-picker emoji {
4444 font-size: x-large;
4445 padding: 6px;
4446 border-radius: 6px;
4447
4448 &:focus,
4449 &:hover {
4450 background: $selected_bg_color;
4451
4452 @if $contrast == 'high' {
4453 box-shadow: inset 0 0 0 1px $borders_color;
4454 }
4455 }
4456 }
4457
4458 emoji-completion-row > box {
4459 border-spacing: 10px;
4460 padding: 2px 10px;
4461 }
4462
4463 emoji-completion-row:focus,
4464 emoji-completion-row:hover {
4465 background-color: $selected_bg_color;
4466 color: $selected_fg_color;
4467 }
4468
4469 emoji-completion-row emoji:focus,
4470 emoji-completion-row emoji:hover {
4471 background-color: $menu_selected_color;
4472 }
4473
4474 popover.entry-completion > contents {
4475 padding: 0;
4476 }
4477
4478 statusbar {
4479 padding: 6px 10px 6px 10px;
4480 }
4481
4482 menubutton {
4483 > button > box {
4484 border-spacing: 6px;
4485 }
4486
4487 arrow {
4488 min-height: 16px;
4489 min-width: 16px;
4490 &.none {
4491 -gtk-icon-source: -gtk-icontheme('open-menu-symbolic');
4492 }
4493 &.down {
4494 -gtk-icon-source: -gtk-icontheme('pan-down-symbolic');
4495 }
4496 &.up {
4497 -gtk-icon-source: -gtk-icontheme('pan-up-symbolic');
4498 }
4499 &.left {
4500 -gtk-icon-source: -gtk-icontheme('pan-start-symbolic');
4501 }
4502 &.right {
4503 -gtk-icon-source: -gtk-icontheme('pan-end-symbolic');
4504 }
4505 }
4506 }