Merge "Soft deprecate Title::getUserCaseDBKey()"
[lhc/web/wiklou.git] / resources / src / mediawiki.widgets.datetime / CalendarWidget.less
1 /* stylelint-disable no-duplicate-selectors */
2 @import 'mediawiki.widgets.datetime.definitions';
3
4 .mw-widgets-datetime-calendarWidget {
5 background-color: @background-color-base;
6 display: inline-block;
7 position: relative;
8 border: @border-base;
9 border-radius: @border-radius-base;
10 padding: 0.5em;
11 box-shadow: @box-shadow-dialog;
12 vertical-align: middle;
13
14 &:focus {
15 border-color: @color-progressive;
16 outline: 0;
17 box-shadow: @box-shadow-base--focus, @box-shadow-dialog;
18 }
19
20 &.mw-widgets-datetime-calendarWidget-dependent {
21 display: block;
22 position: absolute;
23 z-index: 4;
24 }
25
26 &-grid {
27 table-layout: fixed;
28
29 .mw-widgets-datetime-calendarWidget-cell {
30 display: table-cell;
31 white-space: nowrap;
32 }
33 }
34
35 &.mw-widgets-datetime-calendarWidget-dependent {
36 margin-top: -1px;
37 }
38
39 &-heading {
40 font-weight: bold;
41 text-align: center;
42 vertical-align: middle;
43 white-space: nowrap;
44
45 .mw-widgets-datetime-calendarWidget-previous {
46 float: left;
47
48 // Overwrite OOUI's `.oo-ui-buttonElement-frameless.oo-ui-iconElement:first-child`
49 &:first-child {
50 margin-left: 0;
51 }
52 }
53
54 .mw-widgets-datetime-calendarWidget-next {
55 float: right;
56 }
57 }
58
59 &-grid {
60 margin: 0 auto;
61
62 .mw-widgets-datetime-calendarWidget-cell {
63 text-align: center;
64
65 .oo-ui-buttonElement-button {
66 width: 100%;
67 border: 1px solid rgba( 255, 255, 255, 0 );
68 .oo-ui-transition(
69 background-color @transition-base,
70 color @transition-base,
71 border-color @transition-base
72 );
73 }
74
75 &.mw-widgets-datetime-calendarWidget-extra .oo-ui-buttonElement-button {
76 .oo-ui-labelElement-label {
77 color: @color-base--subtle;
78 }
79
80 &:hover .oo-ui-labelElement-label {
81 color: @color-base--inverted;
82 }
83 }
84
85 &.mw-widgets-datetime-calendarWidget-selected .oo-ui-buttonElement-button {
86 background-color: #2a4b8d;
87
88 .oo-ui-labelElement-label {
89 color: @color-base--inverted;
90 }
91 }
92
93 &.oo-ui-widget-enabled .oo-ui-buttonElement-button:hover {
94 background-color: @color-progressive;
95 color: @color-base--inverted;
96 border-color: @color-progressive;
97 }
98 }
99 }
100
101 &:focus &-grid &-cell&-focused .oo-ui-buttonElement-button {
102 border-color: rgba( 0, 0, 0, 0.3 );
103 }
104 }