forked from bendavis78/paper-time-picker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
paper-time-picker.css
144 lines (136 loc) · 2.64 KB
/
paper-time-picker.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
:host /deep/ * {
--webkit-tap-highlight-color: rgba(0,0,0,0);
}
:host {
display: block;
@apply(--paper-font-body1);
background: var(--default-background-color);
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
overflow: hidden;
font-size: 14px;
}
#timePicker {
height: 100%;
@apply(--layout-horizontal);
}
:host([narrow]) #timePicker {
@apply(--layout-vertical);
}
/** Horizontal ******************/
:host {
width: 520px;
height: 240px;
}
#heading {
width: 270px;
height: 240px;
@apply(--layout-horizontal);
@apply(--layout-center);
@apply(--layout-center-justified);
}
#clockArea {
margin: 12px 22px;
@apply(--layout-vertical);
@apply(--layout-flex);
}
/** Narrow *********************/
:host([narrow]) {
width: 270px;
height: 366px;
}
:host([narrow]) #heading {
height: 96px;
}
:host([narrow]) #clock {
margin: 10px 18px;
}
/** Heading ********************/
#heading {
color: var(--light-primary-color);
background: var(--default-primary-color);
}
#heading .time {
font-size: 0;
width: 200px;
text-align: right;
}
#heading .time .iron-selected {
color: var(--text-primary-color);
}
#heading .time .period {
@apply(--paper-font-title);
padding-left: 4px;
line-height: 33px !important;
}
#heading .time div {
@apply(--paper-font-display3);
display: inline-block;
padding: 2px;
}
#heading .time div:hover {
cursor: pointer;
}
/** Clock *********************/
#clockArea {
position: relative;
}
#selectors {
pointer-events: none;
}
#selectors,
#selectors > section,
#selectors > section > * {
@apply(--layout-fit);
}
#selectors section.iron-selected {
z-index: 1000;
}
#selectors section {
z-index: 0;
}
/** Period selector *************/
#periodSelector {
position: absolute;
bottom: 0;
left: 0;
right: 0;
height: 38px;
@apply(--layout-horizontal);
@apply(--layout-justified);
}
#periodSelector .period {
cursor: pointer;
width: 36px;
height: 36px;
line-height: 38px;
border-radius: 100%;
text-align: center;
vertical-align: middle;
}
#periodSelector .period.iron-selected {
background: var(--default-primary-color);
color: var(--text-primary-color);
}
/** Clock transition ***********/
#selectors .iron-selected /deep/ #clock .face {
opacity: 1;
}
#selectors .iron-selected /deep/ #clock .numbers {
transform: scale(1);
opacity: 1;
}
#selectors /deep/ #clock .face {
transition: opacity 500ms;
opacity: 0;
}
#selectors /deep/ #clock .numbers {
transition: transform 500ms, opacity 500ms;
transform: scale(1.2);
transform-origin: 50% 50%;
opacity: 0;
}