summaryrefslogtreecommitdiff
path: root/www/wiki/resources/src/mediawiki.widgets.datetime/CalendarWidget.less
blob: 093c58b28ac28311e725670e4121ca8635ab6409 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
/* stylelint-disable no-duplicate-selectors */
@import 'mediawiki.widgets.datetime.definitions';

.mw-widgets-datetime-calendarWidget {
	display: inline-block;
	position: relative;
	vertical-align: middle;
	padding: 0.5em;

	&.mw-widgets-datetime-calendarWidget-dependent {
		display: block;
		position: absolute;
		z-index: 4;
	}

	&-grid {
		table-layout: fixed;

		.mw-widgets-datetime-calendarWidget-cell {
			display: table-cell;
			white-space: nowrap;
		}
	}

	background-color: #fff;
	border: 1px solid #ccc;

	&.mw-widgets-datetime-calendarWidget-dependent {
		margin-top: -1px;
		border-top: 1px solid #fff;
	}

	&-heading {
		text-align: center;
		vertical-align: middle;
		font-weight: bold;
		white-space: nowrap;

		.mw-widgets-datetime-calendarWidget-previous {
			float: left;
		}
		.mw-widgets-datetime-calendarWidget-next {
			float: right;
		}
	}

	&-grid {
		margin: 0 auto;

		.mw-widgets-datetime-calendarWidget-cell {
			text-align: center;

			.oo-ui-buttonElement-button {
				width: 100%;
				border: 1px dotted rgba( 255, 255, 255, 0 );
				.oo-ui-box-sizing( border-box );
			}

			&.mw-widgets-datetime-calendarWidget-extra .oo-ui-buttonElement-button .oo-ui-labelElement-label {
				color: #bbb;
			}

			&.mw-widgets-datetime-calendarWidget-selected .oo-ui-buttonElement-button {
				background-color: #def;
				.oo-ui-labelElement-label {
					color: #38f;
				}
			}
		}
	}

	&:focus &-grid &-cell&-focused .oo-ui-buttonElement-button {
		border-color: rgba( 0, 0, 0, 0.3 );
	}
}