pico-rails 1.4.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/README.md +53 -0
- data/app/assets/stylesheets/pico.classless.scss +13 -0
- data/app/assets/stylesheets/pico.fluid.classless.scss +16 -0
- data/app/assets/stylesheets/pico.scss +42 -0
- data/app/assets/stylesheets/pico.slim.scss +47 -0
- data/app/assets/stylesheets/scss/_variables.scss +66 -0
- data/app/assets/stylesheets/scss/components/_accordion.scss +90 -0
- data/app/assets/stylesheets/scss/components/_card.scss +33 -0
- data/app/assets/stylesheets/scss/components/_modal.scss +175 -0
- data/app/assets/stylesheets/scss/components/_nav.scss +73 -0
- data/app/assets/stylesheets/scss/components/_progress.scss +81 -0
- data/app/assets/stylesheets/scss/content/_button.scss +227 -0
- data/app/assets/stylesheets/scss/content/_code.scss +91 -0
- data/app/assets/stylesheets/scss/content/_embedded.scss +53 -0
- data/app/assets/stylesheets/scss/content/_form-alt-input-types.scss +258 -0
- data/app/assets/stylesheets/scss/content/_form-checkbox-radio.scss +138 -0
- data/app/assets/stylesheets/scss/content/_form.scss +361 -0
- data/app/assets/stylesheets/scss/content/_miscs.scss +33 -0
- data/app/assets/stylesheets/scss/content/_table.scss +52 -0
- data/app/assets/stylesheets/scss/content/_typography.scss +292 -0
- data/app/assets/stylesheets/scss/layout/_container.scss +42 -0
- data/app/assets/stylesheets/scss/layout/_document.scss +45 -0
- data/app/assets/stylesheets/scss/layout/_grid.scss +24 -0
- data/app/assets/stylesheets/scss/layout/_scroller.scss +16 -0
- data/app/assets/stylesheets/scss/layout/_section.scss +8 -0
- data/app/assets/stylesheets/scss/layout/_sectioning.scss +69 -0
- data/app/assets/stylesheets/scss/themes/default/_colors.scss +65 -0
- data/app/assets/stylesheets/scss/themes/default/_dark.scss +139 -0
- data/app/assets/stylesheets/scss/themes/default/_light.scss +139 -0
- data/app/assets/stylesheets/scss/themes/default/_styles.scss +238 -0
- data/app/assets/stylesheets/scss/themes/default.scss +29 -0
- data/app/assets/stylesheets/scss/utilities/_accessibility.scss +54 -0
- data/app/assets/stylesheets/scss/utilities/_loading.scss +58 -0
- data/app/assets/stylesheets/scss/utilities/_reduce-motion.scss +29 -0
- data/app/assets/stylesheets/scss/utilities/_tooltip.scss +105 -0
- data/lib/pico/engine.rb +4 -0
- data/lib/pico/version.rb +3 -0
- data/lib/pico-rails.rb +5 -0
- data/pico-rails.gemspec +16 -0
- metadata +97 -0
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Form elements
|
|
3
|
+
* Checkboxes & Radios
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
[type="checkbox"],
|
|
7
|
+
[type="radio"] {
|
|
8
|
+
-webkit-appearance: none;
|
|
9
|
+
-moz-appearance: none;
|
|
10
|
+
appearance: none;
|
|
11
|
+
width: 1.25em;
|
|
12
|
+
height: 1.25em;
|
|
13
|
+
margin-top: -0.125em;
|
|
14
|
+
margin-right: 0.375em;
|
|
15
|
+
margin-left: 0;
|
|
16
|
+
margin-inline-start: 0;
|
|
17
|
+
margin-inline-end: 0.375em;
|
|
18
|
+
border-width: var(--border-width);
|
|
19
|
+
font-size: inherit;
|
|
20
|
+
vertical-align: middle;
|
|
21
|
+
cursor: pointer;
|
|
22
|
+
|
|
23
|
+
&::-ms-check {
|
|
24
|
+
display: none; // unstyle IE checkboxes
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
&:checked,
|
|
28
|
+
&:checked:active,
|
|
29
|
+
&:checked:focus {
|
|
30
|
+
--background-color: var(--primary);
|
|
31
|
+
--border-color: var(--primary);
|
|
32
|
+
background-image: var(--icon-checkbox);
|
|
33
|
+
background-position: center;
|
|
34
|
+
background-size: 0.75em auto;
|
|
35
|
+
background-repeat: no-repeat;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
& ~ label {
|
|
39
|
+
display: inline-block;
|
|
40
|
+
margin-right: 0.375em;
|
|
41
|
+
margin-bottom: 0;
|
|
42
|
+
cursor: pointer;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
// Checkboxes
|
|
47
|
+
[type="checkbox"] {
|
|
48
|
+
&:indeterminate {
|
|
49
|
+
--background-color: var(--primary);
|
|
50
|
+
--border-color: var(--primary);
|
|
51
|
+
background-image: var(--icon-minus);
|
|
52
|
+
background-position: center;
|
|
53
|
+
background-size: 0.75em auto;
|
|
54
|
+
background-repeat: no-repeat;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
// Radios
|
|
59
|
+
[type="radio"] {
|
|
60
|
+
border-radius: 50%;
|
|
61
|
+
|
|
62
|
+
&:checked,
|
|
63
|
+
&:checked:active,
|
|
64
|
+
&:checked:focus {
|
|
65
|
+
--background-color: var(--primary-inverse);
|
|
66
|
+
border-width: 0.35em;
|
|
67
|
+
background-image: none;
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
// Switchs
|
|
72
|
+
[type="checkbox"][role="switch"] {
|
|
73
|
+
--background-color: var(--switch-background-color);
|
|
74
|
+
--border-color: var(--switch-background-color);
|
|
75
|
+
--color: var(--switch-color);
|
|
76
|
+
|
|
77
|
+
// Config
|
|
78
|
+
$switch-height: 1.25em;
|
|
79
|
+
$switch-width: 2.25em;
|
|
80
|
+
$switch-transition: 0.1s ease-in-out;
|
|
81
|
+
|
|
82
|
+
// Styles
|
|
83
|
+
width: $switch-width;
|
|
84
|
+
height: $switch-height;
|
|
85
|
+
border: var(--border-width) solid var(--border-color);
|
|
86
|
+
border-radius: $switch-height;
|
|
87
|
+
background-color: var(--background-color);
|
|
88
|
+
line-height: $switch-height;
|
|
89
|
+
|
|
90
|
+
&:focus {
|
|
91
|
+
--background-color: var(--switch-background-color);
|
|
92
|
+
--border-color: var(--switch-background-color);
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
&:checked {
|
|
96
|
+
--background-color: var(--switch-checked-background-color);
|
|
97
|
+
--border-color: var(--switch-checked-background-color);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
&:before {
|
|
101
|
+
display: block;
|
|
102
|
+
width: calc(#{$switch-height} - (var(--border-width) * 2));
|
|
103
|
+
height: 100%;
|
|
104
|
+
border-radius: 50%;
|
|
105
|
+
background-color: var(--color);
|
|
106
|
+
content: "";
|
|
107
|
+
|
|
108
|
+
@if $enable-transitions {
|
|
109
|
+
transition: margin $switch-transition;
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
&:checked {
|
|
114
|
+
background-image: none;
|
|
115
|
+
|
|
116
|
+
&::before {
|
|
117
|
+
margin-left: calc(#{$switch-width * 0.5} - var(--border-width));
|
|
118
|
+
margin-inline-start: calc(#{$switch-width * 0.5} - var(--border-width));
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
// Aria-invalid
|
|
124
|
+
[type="checkbox"],
|
|
125
|
+
[type="checkbox"]:checked,
|
|
126
|
+
[type="radio"],
|
|
127
|
+
[type="radio"]:checked,
|
|
128
|
+
[type="checkbox"][role="switch"],
|
|
129
|
+
[type="checkbox"][role="switch"]:checked {
|
|
130
|
+
|
|
131
|
+
&[aria-invalid="false"] {
|
|
132
|
+
--border-color: var(--form-element-valid-border-color);
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
&[aria-invalid="true"] {
|
|
136
|
+
--border-color: var(--form-element-invalid-border-color);
|
|
137
|
+
}
|
|
138
|
+
}
|
|
@@ -0,0 +1,361 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Form elements
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
// Reboot based on :
|
|
6
|
+
// - normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css
|
|
7
|
+
// - sanitize.css v12.0.1 | CC0 1.0 Universal | github.com/csstools/sanitize.css
|
|
8
|
+
// ––––––––––––––––––––
|
|
9
|
+
|
|
10
|
+
// 1. Change the font styles in all browsers
|
|
11
|
+
// 2. Remove the margin in Firefox and Safari
|
|
12
|
+
input,
|
|
13
|
+
optgroup,
|
|
14
|
+
select,
|
|
15
|
+
textarea {
|
|
16
|
+
margin: 0; // 2
|
|
17
|
+
font-size: 1rem; // 1
|
|
18
|
+
line-height: var(--line-height); // 1
|
|
19
|
+
font-family: inherit; // 1
|
|
20
|
+
letter-spacing: inherit; // 2
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
// Show the overflow in IE.
|
|
24
|
+
input {
|
|
25
|
+
overflow: visible;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
// Remove the inheritance of text transform in Edge, Firefox, and IE
|
|
29
|
+
select {
|
|
30
|
+
text-transform: none;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
// 1. Correct the text wrapping in Edge and IE
|
|
34
|
+
// 2. Correct the color inheritance from `fieldset` elements in IE
|
|
35
|
+
// 3. Remove the padding so developers are not caught out when they zero out
|
|
36
|
+
// `fieldset` elements in all browsers
|
|
37
|
+
legend {
|
|
38
|
+
max-width: 100%; // 1
|
|
39
|
+
padding: 0; // 3
|
|
40
|
+
color: inherit; // 2
|
|
41
|
+
white-space: normal; // 1
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
// 1. Remove the default vertical scrollbar in IE
|
|
45
|
+
textarea {
|
|
46
|
+
overflow: auto; // 1
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
// Remove the padding in IE 10
|
|
50
|
+
[type="checkbox"],
|
|
51
|
+
[type="radio"] {
|
|
52
|
+
padding: 0;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
// Correct the cursor style of increment and decrement buttons in Safari
|
|
56
|
+
::-webkit-inner-spin-button,
|
|
57
|
+
::-webkit-outer-spin-button {
|
|
58
|
+
height: auto;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
// 1. Correct the odd appearance in Chrome and Safari
|
|
62
|
+
// 2. Correct the outline style in Safari
|
|
63
|
+
[type="search"] {
|
|
64
|
+
-webkit-appearance: textfield; // 1
|
|
65
|
+
outline-offset: -2px; // 2
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
// Remove the inner padding in Chrome and Safari on macOS
|
|
69
|
+
[type="search"]::-webkit-search-decoration {
|
|
70
|
+
-webkit-appearance: none;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
// 1. Correct the inability to style clickable types in iOS and Safari
|
|
74
|
+
// 2. Change font properties to `inherit` in Safari
|
|
75
|
+
::-webkit-file-upload-button {
|
|
76
|
+
-webkit-appearance: button; // 1
|
|
77
|
+
font: inherit; // 2
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
// Remove the inner border and padding of focus outlines in Firefox
|
|
81
|
+
::-moz-focus-inner {
|
|
82
|
+
padding: 0;
|
|
83
|
+
border-style: none;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
// Remove the focus outline in Firefox
|
|
87
|
+
:-moz-focusring {
|
|
88
|
+
outline: none;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
// Remove the additional :invalid styles in Firefox
|
|
92
|
+
:-moz-ui-invalid {
|
|
93
|
+
box-shadow: none;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
// Change the inconsistent appearance in IE (opinionated)
|
|
97
|
+
::-ms-expand {
|
|
98
|
+
display: none;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
// Remove the border and padding in all browsers (opinionated)
|
|
102
|
+
[type="file"],
|
|
103
|
+
[type="range"] {
|
|
104
|
+
padding: 0;
|
|
105
|
+
border-width: 0;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
// Pico
|
|
109
|
+
// ––––––––––––––––––––
|
|
110
|
+
|
|
111
|
+
// Force height for alternatives input types
|
|
112
|
+
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]) {
|
|
113
|
+
height: calc(
|
|
114
|
+
(1rem * var(--line-height)) + (var(--form-element-spacing-vertical) * 2) +
|
|
115
|
+
(var(--border-width) * 2)
|
|
116
|
+
);
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
// Fieldset
|
|
120
|
+
fieldset {
|
|
121
|
+
margin: 0;
|
|
122
|
+
margin-bottom: var(--spacing);
|
|
123
|
+
padding: 0;
|
|
124
|
+
border: 0;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
// Label & legend
|
|
128
|
+
label,
|
|
129
|
+
fieldset legend {
|
|
130
|
+
display: block;
|
|
131
|
+
margin-bottom: calc(var(--spacing) * 0.25);
|
|
132
|
+
font-weight: var(--form-label-font-weight, var(--font-weight));
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
// Blocks, 100%
|
|
136
|
+
input:not([type="checkbox"]):not([type="radio"]),
|
|
137
|
+
select,
|
|
138
|
+
textarea {
|
|
139
|
+
width: 100%;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
// Reset appearance (Not Checkboxes, Radios, Range and File)
|
|
143
|
+
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="file"]),
|
|
144
|
+
select,
|
|
145
|
+
textarea {
|
|
146
|
+
appearance: none;
|
|
147
|
+
padding: var(--form-element-spacing-vertical)
|
|
148
|
+
var(--form-element-spacing-horizontal);
|
|
149
|
+
vertical-align: middle;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
// Commons styles
|
|
153
|
+
input,
|
|
154
|
+
select,
|
|
155
|
+
textarea {
|
|
156
|
+
--background-color: var(--form-element-background-color);
|
|
157
|
+
--border-color: var(--form-element-border-color);
|
|
158
|
+
--color: var(--form-element-color);
|
|
159
|
+
--box-shadow: none;
|
|
160
|
+
border: var(--border-width) solid var(--border-color);
|
|
161
|
+
border-radius: var(--border-radius);
|
|
162
|
+
outline: none;
|
|
163
|
+
background-color: var(--background-color);
|
|
164
|
+
box-shadow: var(--box-shadow);
|
|
165
|
+
color: var(--color);
|
|
166
|
+
font-weight: var(--font-weight);
|
|
167
|
+
|
|
168
|
+
@if $enable-transitions {
|
|
169
|
+
transition: background-color var(--transition),
|
|
170
|
+
border-color var(--transition), color var(--transition),
|
|
171
|
+
box-shadow var(--transition);
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
// Active & Focus
|
|
176
|
+
input:not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="checkbox"]):not([type="radio"]):not([readonly]),
|
|
177
|
+
select,
|
|
178
|
+
textarea {
|
|
179
|
+
&:active,
|
|
180
|
+
&:focus {
|
|
181
|
+
--background-color: var(--form-element-active-background-color);
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
// Active & Focus
|
|
186
|
+
input:not([type="submit"]):not([type="button"]):not([type="reset"]):not([role="switch"]):not([readonly]),
|
|
187
|
+
select,
|
|
188
|
+
textarea {
|
|
189
|
+
&:active,
|
|
190
|
+
&:focus {
|
|
191
|
+
--border-color: var(--form-element-active-border-color);
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
// Focus
|
|
196
|
+
input:not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="range"]):not([type="file"]):not([readonly]),
|
|
197
|
+
select,
|
|
198
|
+
textarea {
|
|
199
|
+
&:focus {
|
|
200
|
+
--box-shadow: 0 0 0 var(--outline-width) var(--form-element-focus-color);
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
// Disabled
|
|
205
|
+
input:not([type="submit"]):not([type="button"]):not([type="reset"]),
|
|
206
|
+
select,
|
|
207
|
+
textarea {
|
|
208
|
+
&[disabled] {
|
|
209
|
+
--background-color: var(--form-element-disabled-background-color);
|
|
210
|
+
--border-color: var(--form-element-disabled-border-color);
|
|
211
|
+
opacity: var(--form-element-disabled-opacity);
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
// Aria-invalid
|
|
216
|
+
input,
|
|
217
|
+
select,
|
|
218
|
+
textarea {
|
|
219
|
+
|
|
220
|
+
&:not([type="checkbox"]):not([type="radio"]) {
|
|
221
|
+
&[aria-invalid] {
|
|
222
|
+
@if $enable-important {
|
|
223
|
+
padding-right: calc(
|
|
224
|
+
var(--form-element-spacing-horizontal) + 1.5rem
|
|
225
|
+
) !important;
|
|
226
|
+
padding-left: var(--form-element-spacing-horizontal);
|
|
227
|
+
padding-inline-start: var(--form-element-spacing-horizontal) !important;
|
|
228
|
+
padding-inline-end: calc(
|
|
229
|
+
var(--form-element-spacing-horizontal) + 1.5rem
|
|
230
|
+
) !important;
|
|
231
|
+
} @else {
|
|
232
|
+
padding-right: calc(var(--form-element-spacing-horizontal) + 1.5rem);
|
|
233
|
+
padding-left: var(--form-element-spacing-horizontal);
|
|
234
|
+
padding-inline-start: var(--form-element-spacing-horizontal);
|
|
235
|
+
padding-inline-end: calc(var(--form-element-spacing-horizontal) + 1.5rem);
|
|
236
|
+
}
|
|
237
|
+
background-position: center right 0.75rem;
|
|
238
|
+
background-size: 1rem auto;
|
|
239
|
+
background-repeat: no-repeat;
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
&[aria-invalid="false"] {
|
|
243
|
+
background-image: var(--icon-valid);
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
&[aria-invalid="true"] {
|
|
247
|
+
background-image: var(--icon-invalid);
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
&[aria-invalid="false"] {
|
|
252
|
+
--border-color: var(--form-element-valid-border-color);
|
|
253
|
+
|
|
254
|
+
&:active,
|
|
255
|
+
&:focus {
|
|
256
|
+
@if $enable-important {
|
|
257
|
+
--border-color: var(--form-element-valid-active-border-color) !important;
|
|
258
|
+
--box-shadow: 0 0 0 var(--outline-width) var(--form-element-valid-focus-color) !important;
|
|
259
|
+
} @else {
|
|
260
|
+
--border-color: var(--form-element-valid-active-border-color);
|
|
261
|
+
--box-shadow: 0 0 0 var(--outline-width) var(--form-element-valid-focus-color);
|
|
262
|
+
}
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
&[aria-invalid="true"] {
|
|
267
|
+
--border-color: var(--form-element-invalid-border-color);
|
|
268
|
+
|
|
269
|
+
&:active,
|
|
270
|
+
&:focus {
|
|
271
|
+
@if $enable-important {
|
|
272
|
+
--border-color: var(--form-element-invalid-active-border-color) !important;
|
|
273
|
+
--box-shadow: 0 0 0 var(--outline-width) var(--form-element-invalid-focus-color) !important;
|
|
274
|
+
} @else {
|
|
275
|
+
--border-color: var(--form-element-invalid-active-border-color);
|
|
276
|
+
--box-shadow: 0 0 0 var(--outline-width) var(--form-element-invalid-focus-color);
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
[dir="rtl"] {
|
|
283
|
+
input,
|
|
284
|
+
select,
|
|
285
|
+
textarea {
|
|
286
|
+
&:not([type="checkbox"]):not([type="radio"]) {
|
|
287
|
+
&[aria-invalid],
|
|
288
|
+
&[aria-invalid="true"],
|
|
289
|
+
&[aria-invalid="false"] {
|
|
290
|
+
background-position: center left 0.75rem;
|
|
291
|
+
}
|
|
292
|
+
}
|
|
293
|
+
}
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
// Placeholder
|
|
297
|
+
input::placeholder,
|
|
298
|
+
input::-webkit-input-placeholder,
|
|
299
|
+
textarea::placeholder,
|
|
300
|
+
textarea::-webkit-input-placeholder,
|
|
301
|
+
select:invalid {
|
|
302
|
+
color: var(--form-element-placeholder-color);
|
|
303
|
+
opacity: 1;
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
// Margin bottom (Not Checkboxes and Radios)
|
|
307
|
+
input:not([type="checkbox"]):not([type="radio"]),
|
|
308
|
+
select,
|
|
309
|
+
textarea {
|
|
310
|
+
margin-bottom: var(--spacing);
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
// Select
|
|
314
|
+
select {
|
|
315
|
+
// Unstyle the caret on `<select>`s in IE10+.
|
|
316
|
+
&::-ms-expand {
|
|
317
|
+
border: 0;
|
|
318
|
+
background-color: transparent;
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
&:not([multiple]):not([size]) {
|
|
322
|
+
padding-right: calc(var(--form-element-spacing-horizontal) + 1.5rem);
|
|
323
|
+
padding-left: var(--form-element-spacing-horizontal);
|
|
324
|
+
padding-inline-start: var(--form-element-spacing-horizontal);
|
|
325
|
+
padding-inline-end: calc(var(--form-element-spacing-horizontal) + 1.5rem);
|
|
326
|
+
background-image: var(--icon-chevron);
|
|
327
|
+
background-position: center right 0.75rem;
|
|
328
|
+
background-size: 1rem auto;
|
|
329
|
+
background-repeat: no-repeat;
|
|
330
|
+
}
|
|
331
|
+
}
|
|
332
|
+
|
|
333
|
+
[dir="rtl"] {
|
|
334
|
+
select {
|
|
335
|
+
&:not([multiple]):not([size]) {
|
|
336
|
+
background-position: center left 0.75rem;
|
|
337
|
+
}
|
|
338
|
+
}
|
|
339
|
+
}
|
|
340
|
+
|
|
341
|
+
// Helper
|
|
342
|
+
input,
|
|
343
|
+
select,
|
|
344
|
+
textarea {
|
|
345
|
+
+ small {
|
|
346
|
+
display: block;
|
|
347
|
+
width: 100%;
|
|
348
|
+
margin-top: calc(var(--spacing) * -0.75);
|
|
349
|
+
margin-bottom: var(--spacing);
|
|
350
|
+
color: var(--muted-color);
|
|
351
|
+
}
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
// Styles for Input inside a label
|
|
355
|
+
label {
|
|
356
|
+
& > input,
|
|
357
|
+
& > select,
|
|
358
|
+
& > textarea {
|
|
359
|
+
margin-top: calc(var(--spacing) * 0.25);
|
|
360
|
+
}
|
|
361
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Miscs
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
// Reboot based on :
|
|
6
|
+
// - normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css
|
|
7
|
+
// - sanitize.css v12.0.1 | CC0 1.0 Universal | github.com/csstools/sanitize.css
|
|
8
|
+
// ––––––––––––––––––––
|
|
9
|
+
|
|
10
|
+
// 1. Add the correct box sizing in Firefox
|
|
11
|
+
// 2. Show the overflow in Edge and IE
|
|
12
|
+
hr {
|
|
13
|
+
box-sizing: content-box; // 1
|
|
14
|
+
height: 0; // 1
|
|
15
|
+
overflow: visible; // 2
|
|
16
|
+
border: none;
|
|
17
|
+
border-top: 1px solid var(--muted-border-color);
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
// Add the correct display in IE 10+
|
|
21
|
+
[hidden],
|
|
22
|
+
template {
|
|
23
|
+
@if $enable-important {
|
|
24
|
+
display: none !important;
|
|
25
|
+
} @else {
|
|
26
|
+
display: none;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
// Add the correct display in IE 9-
|
|
31
|
+
canvas {
|
|
32
|
+
display: inline-block;
|
|
33
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Table
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
// Reboot based on :
|
|
6
|
+
// - normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css
|
|
7
|
+
// - sanitize.css v12.0.1 | CC0 1.0 Universal | github.com/csstools/sanitize.css
|
|
8
|
+
// ––––––––––––––––––––
|
|
9
|
+
|
|
10
|
+
// 1. Collapse border spacing in all browsers (opinionated).
|
|
11
|
+
// 2. Correct table border color inheritance in all Chrome, Edge, and Safari.
|
|
12
|
+
// 3. Remove text indentation from table contents in Chrome, Edge, and Safari.
|
|
13
|
+
table {
|
|
14
|
+
width: 100%;
|
|
15
|
+
border-color: inherit; // 2
|
|
16
|
+
border-collapse: collapse; // 1
|
|
17
|
+
border-spacing: 0;
|
|
18
|
+
text-indent: 0; // 3
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
// Pico
|
|
22
|
+
// ––––––––––––––––––––
|
|
23
|
+
|
|
24
|
+
// Cells
|
|
25
|
+
th,
|
|
26
|
+
td {
|
|
27
|
+
padding: calc(var(--spacing) / 2) var(--spacing);
|
|
28
|
+
border-bottom: var(--border-width) solid var(--table-border-color);
|
|
29
|
+
color: var(--color);
|
|
30
|
+
font-weight: var(--font-weight);
|
|
31
|
+
font-size: var(--font-size);
|
|
32
|
+
text-align: left;
|
|
33
|
+
text-align: start;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
// Footer
|
|
37
|
+
tfoot {
|
|
38
|
+
th,
|
|
39
|
+
td {
|
|
40
|
+
border-top: var(--border-width) solid var(--table-border-color);
|
|
41
|
+
border-bottom: 0;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
// Striped
|
|
46
|
+
table {
|
|
47
|
+
&[role="grid"] {
|
|
48
|
+
tbody tr:nth-child(odd) {
|
|
49
|
+
background-color: var(--table-row-stripped-background-color);
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
}
|