@stackoverflow/stacks 3.0.0-beta.3 → 3.0.0-beta.30
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.
- package/dist/controllers.d.ts +0 -2
- package/dist/css/stacks.css +14245 -15086
- package/dist/css/stacks.min.css +1 -1
- package/dist/js/stacks.js +0 -364
- package/dist/js/stacks.min.js +1 -1
- package/lib/atomic/backgrounds.less +67 -0
- package/lib/atomic/border-radius.less +38 -0
- package/lib/atomic/borders.less +73 -0
- package/lib/atomic/box-shadow.less +29 -0
- package/lib/atomic/box-sizing.less +3 -0
- package/lib/atomic/current-color.less +2 -0
- package/lib/atomic/cursors.less +8 -0
- package/lib/atomic/display.less +15 -0
- package/lib/atomic/flex.less +6 -34
- package/lib/atomic/floats.less +20 -0
- package/lib/atomic/gap.less +2 -0
- package/lib/atomic/grid.less +2 -0
- package/lib/atomic/height.less +22 -0
- package/lib/atomic/interactivity.less +45 -0
- package/lib/atomic/lists.less +29 -0
- package/lib/atomic/margin.less +48 -0
- package/lib/atomic/object-fit.less +9 -0
- package/lib/atomic/opacity.less +54 -0
- package/lib/atomic/outline.less +11 -0
- package/lib/atomic/overflow.less +17 -0
- package/lib/atomic/padding.less +12 -0
- package/lib/atomic/positioning.less +41 -0
- package/lib/atomic/sizing.less +51 -0
- package/lib/atomic/transitions.less +20 -0
- package/lib/atomic/truncation.less +58 -0
- package/lib/atomic/typography.less +71 -137
- package/lib/atomic/vertical-alignment.less +9 -0
- package/lib/atomic/visibility.less +18 -0
- package/lib/atomic/width.less +27 -0
- package/lib/atomic/z-index.less +12 -0
- package/lib/base/body.less +2 -4
- package/lib/base/configuration-static.less +3 -3
- package/lib/base/internal.less +3 -5
- package/lib/base/reset-normalize.less +3 -3
- package/lib/components/activity-indicator/activity-indicator.less +4 -20
- package/lib/components/anchor/anchor.less +28 -39
- package/lib/components/avatar/avatar.less +20 -19
- package/lib/components/badge/badge.less +227 -167
- package/lib/components/banner/banner.less +12 -11
- package/lib/components/bling/bling.less +47 -10
- package/lib/components/button/button.less +300 -380
- package/lib/components/checkbox_radio/checkbox_radio.less +195 -113
- package/lib/components/code-block/code-block.fixtures.ts +2 -2
- package/lib/components/code-block/code-block.less +2 -3
- package/lib/components/description/description.less +17 -2
- package/lib/components/empty-state/empty-state.less +17 -6
- package/lib/components/form-group/form-group.less +38 -0
- package/lib/components/input-fill/input-fill.less +3 -3
- package/lib/components/input-icon/input-icon.less +3 -3
- package/lib/components/input-message/input-message.less +1 -0
- package/lib/components/input_textarea/input_textarea.less +71 -58
- package/lib/components/label/label.less +12 -56
- package/lib/components/link/link.less +44 -98
- package/lib/components/loader/loader.less +88 -0
- package/lib/components/menu/menu.less +89 -19
- package/lib/components/modal/modal.less +10 -10
- package/lib/components/navigation/navigation.less +77 -42
- package/lib/components/notice/notice.less +90 -75
- package/lib/components/pagination/pagination.less +50 -42
- package/lib/components/popover/popover.less +9 -11
- package/lib/components/post-summary/post-summary.less +225 -385
- package/lib/components/prose/prose.less +49 -35
- package/lib/components/select/select.less +46 -41
- package/lib/components/sidebar-widget/sidebar-widget.less +26 -196
- package/lib/components/table/table.less +48 -22
- package/lib/components/tag/tag.less +25 -6
- package/lib/components/toast/toast.less +4 -2
- package/lib/components/toggle-switch/toggle-switch.less +15 -19
- package/lib/components/user-card/user-card.less +129 -92
- package/lib/components/vote/vote.less +134 -0
- package/lib/controllers.ts +0 -2
- package/lib/exports/color-sets.less +108 -81
- package/lib/exports/constants-helpers.less +9 -13
- package/lib/exports/constants-type.less +18 -36
- package/lib/exports/mixins.less +92 -272
- package/lib/index.ts +0 -4
- package/lib/stacks-static.less +44 -30
- package/lib/test/visual-test-utils.ts +42 -10
- package/lib/tsconfig.json +1 -1
- package/package.json +1 -1
- package/dist/components/expandable/expandable.d.ts +0 -17
- package/dist/components/uploader/uploader.d.ts +0 -48
- package/lib/atomic/border.less +0 -121
- package/lib/atomic/misc.less +0 -374
- package/lib/atomic/spacing.less +0 -98
- package/lib/atomic/width-height.less +0 -194
- package/lib/components/block-link/block-link.less +0 -82
- package/lib/components/breadcrumbs/breadcrumbs.less +0 -41
- package/lib/components/button-group/button-group.less +0 -81
- package/lib/components/card/card.less +0 -37
- package/lib/components/check-control/check-control.less +0 -17
- package/lib/components/check-group/check-group.less +0 -19
- package/lib/components/expandable/expandable.less +0 -119
- package/lib/components/expandable/expandable.ts +0 -238
- package/lib/components/link-preview/link-preview.less +0 -148
- package/lib/components/page-title/page-title.less +0 -51
- package/lib/components/progress-bar/progress-bar.less +0 -292
- package/lib/components/skeleton/skeleton.less +0 -73
- package/lib/components/spinner/spinner.less +0 -103
- package/lib/components/topbar/topbar.less +0 -553
- package/lib/components/uploader/uploader.less +0 -205
- package/lib/components/uploader/uploader.ts +0 -207
- package/lib/exports/spacing-mixins.less +0 -67
|
@@ -1,292 +0,0 @@
|
|
|
1
|
-
.s-progress {
|
|
2
|
-
// COMPONENT-SPECIFIC CONSTANTS
|
|
3
|
-
@pr-circle-circumference: (2 * pi() * 14); // 2πr, r = 14.
|
|
4
|
-
// COMPONENT-SPECIFIC CUSTOM PROPERTIES
|
|
5
|
-
--_pr-bar: var(--br-md);
|
|
6
|
-
--_pr-bg: var(--black-300);
|
|
7
|
-
--_pr-h: unset;
|
|
8
|
-
--_pr-size: unset;
|
|
9
|
-
--_pr-w: 100%;
|
|
10
|
-
--_pr-hmn: var(--su-static4);
|
|
11
|
-
--_pr-bar-bar: var(--br-md);
|
|
12
|
-
--_pr-bar-bg: var(--green-400);
|
|
13
|
-
--_pr-bar-hmn: var(--su-static4);
|
|
14
|
-
--_pr-label-ai: unset;
|
|
15
|
-
--_pr-label-bc: transparent;
|
|
16
|
-
--_pr-label-d: unset;
|
|
17
|
-
--_pr-label-g: unset;
|
|
18
|
-
--_pr-label-jc: unset;
|
|
19
|
-
--_pr-label-px: unset;
|
|
20
|
-
|
|
21
|
-
// MODIFIERS
|
|
22
|
-
&&__brand {
|
|
23
|
-
--_pr-bar-bg: var(--orange-400);
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
// TODO SPARK I've changed metallic colors here to use their new non-metallic equivalents
|
|
27
|
-
&&__bronze {
|
|
28
|
-
--_pr-bar-bg: var(--orange-100);
|
|
29
|
-
--_pr-label-bc: var(--orange-400);
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
&&__gold {
|
|
33
|
-
--_pr-bar-bg: var(--yellow-100);
|
|
34
|
-
--_pr-label-bc: var(--yellow-400);
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
&&__info {
|
|
38
|
-
--_pr-bar-bg: var(--blue-400);
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
&&__silver {
|
|
42
|
-
--_pr-bar-bg: var(--blue-100);
|
|
43
|
-
--_pr-label-bc: var(--blue-400);
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
// VARIANTS
|
|
47
|
-
&&__badge,
|
|
48
|
-
&&__privilege {
|
|
49
|
-
--_pr-bar: var(--br-md);
|
|
50
|
-
--_pr-bg: transparent;
|
|
51
|
-
--_pr-hmn: 2em;
|
|
52
|
-
--_pr-bar-bar: var(--br-md);
|
|
53
|
-
--_pr-bar-hmn: 2em;
|
|
54
|
-
--_pr-label-d: flex;
|
|
55
|
-
--_pr-label-g: var(--su4);
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
&&__badge {
|
|
59
|
-
--_pr-label-ai: center;
|
|
60
|
-
--_pr-label-px: 1em;
|
|
61
|
-
|
|
62
|
-
.s-progress--label {
|
|
63
|
-
.s-badge--label {
|
|
64
|
-
flex-grow: 1;
|
|
65
|
-
text-align: center;
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
&&__circular {
|
|
71
|
-
--_pr-bg: transparent;
|
|
72
|
-
--_pr-size: var(--su-static32);
|
|
73
|
-
--s-progress-value: 0;
|
|
74
|
-
|
|
75
|
-
&.s-progress {
|
|
76
|
-
&__sm {
|
|
77
|
-
--_pr-size: var(--su-static24);
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
&__md {
|
|
81
|
-
--_pr-size: var(--su-static48);
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
&__lg {
|
|
85
|
-
--_pr-size: var(--su-static64);
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
// TODO: consider renaming to `.s-progress--bar`
|
|
90
|
-
.s-progress-bar { // It may necessitate wrapping element in a `&:not(&__circular)`
|
|
91
|
-
circle {
|
|
92
|
-
&:nth-of-type(1) {
|
|
93
|
-
opacity: 0.4;
|
|
94
|
-
stroke: currentColor;
|
|
95
|
-
}
|
|
96
|
-
&:nth-of-type(2) {
|
|
97
|
-
stroke: currentColor;
|
|
98
|
-
stroke-dasharray: @pr-circle-circumference; // [1]
|
|
99
|
-
stroke-dashoffset: calc(((1 - var(--s-progress-value)) * @pr-circle-circumference) * 1px); // Multiply everything by 1px since Safari and Firefox require these to be in pixels
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
fill: none;
|
|
103
|
-
stroke-linecap: round;
|
|
104
|
-
stroke-width: var(--su-static4);
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
transform: rotate(270deg); // Make everything originate from the top of the circle
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
&&__privilege {
|
|
112
|
-
--_pr-bar-bg: var(--green-200);
|
|
113
|
-
--_pr-label-ai: center;
|
|
114
|
-
--_pr-label-bc: var(--green-400);
|
|
115
|
-
--_pr-label-jc: center;
|
|
116
|
-
|
|
117
|
-
.highcontrast-mode({ --_pr-bar-bg: var(--green-300); });
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
// TODO move `.s-progress__stepped` to entirely separate component (or consider deprecating)
|
|
121
|
-
&&__stepped { // There's so little overlap with the base .s-progress that it doesn't make sense as a variant
|
|
122
|
-
background: transparent;
|
|
123
|
-
display: flex;
|
|
124
|
-
|
|
125
|
-
.s-progress {
|
|
126
|
-
&--bar {
|
|
127
|
-
&.s-progress--bar {
|
|
128
|
-
&__left {
|
|
129
|
-
left: 0;
|
|
130
|
-
right: 50%;
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
&__right {
|
|
134
|
-
left: 50%;
|
|
135
|
-
right: 0;
|
|
136
|
-
}
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
background: var(--black-250);
|
|
140
|
-
border-radius: 0;
|
|
141
|
-
height: var(--su-static6);
|
|
142
|
-
position: absolute;
|
|
143
|
-
top: calc(var(--su-static8) + var(--su-static1));
|
|
144
|
-
z-index: var(--zi-base);
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
&--label { // Override a ton of properties
|
|
148
|
-
border: 0;
|
|
149
|
-
border-radius: 0;
|
|
150
|
-
color: var(--black-400);
|
|
151
|
-
display: block;
|
|
152
|
-
font-size: var(--fs-body1);
|
|
153
|
-
height: auto;
|
|
154
|
-
padding: var(--su12) var(--su6) 0 var(--su6);
|
|
155
|
-
position: static;
|
|
156
|
-
text-align: center;
|
|
157
|
-
width: auto;
|
|
158
|
-
z-index: var(--zi-base);
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
&--step {
|
|
162
|
-
&.is-active {
|
|
163
|
-
.s-progress {
|
|
164
|
-
&--bar.s-progress--bar__left {
|
|
165
|
-
background: var(--theme-secondary);
|
|
166
|
-
}
|
|
167
|
-
|
|
168
|
-
&--label {
|
|
169
|
-
color: var(--fc-dark);
|
|
170
|
-
}
|
|
171
|
-
|
|
172
|
-
&--stop {
|
|
173
|
-
background: var(--theme-secondary);
|
|
174
|
-
box-shadow: 0 0 0 var(--su-static6) var(--translucent-secondary);// TODO SHINE revisit this value once theme colors are finalized
|
|
175
|
-
}
|
|
176
|
-
}
|
|
177
|
-
}
|
|
178
|
-
|
|
179
|
-
&.is-complete {
|
|
180
|
-
.s-progress {
|
|
181
|
-
&--bar,
|
|
182
|
-
&--stop {
|
|
183
|
-
background: var(--theme-secondary);
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
&--label {
|
|
187
|
-
color: var(--fc-dark);
|
|
188
|
-
}
|
|
189
|
-
}
|
|
190
|
-
}
|
|
191
|
-
|
|
192
|
-
align-items: center;
|
|
193
|
-
display: flex;
|
|
194
|
-
flex-basis: 0;
|
|
195
|
-
flex-direction: column;
|
|
196
|
-
flex-grow: 1;
|
|
197
|
-
flex-shrink: 1;
|
|
198
|
-
position: relative;
|
|
199
|
-
}
|
|
200
|
-
|
|
201
|
-
&--stop {
|
|
202
|
-
.highcontrast-mode({
|
|
203
|
-
color: var(--white);
|
|
204
|
-
});
|
|
205
|
-
|
|
206
|
-
align-items: center;
|
|
207
|
-
background: var(--black-250);
|
|
208
|
-
border-radius: 100%;
|
|
209
|
-
color: var(--_white-static);
|
|
210
|
-
display: flex;
|
|
211
|
-
height: var(--su-static24);
|
|
212
|
-
justify-content: center;
|
|
213
|
-
position: relative;
|
|
214
|
-
width: var(--su-static24);
|
|
215
|
-
z-index: var(--zi-selected);
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
}
|
|
219
|
-
|
|
220
|
-
// CHILD ELEMENTS
|
|
221
|
-
& &--bar {
|
|
222
|
-
background-color: var(--_pr-bar-bg);
|
|
223
|
-
border-radius: var(--_pr-bar);
|
|
224
|
-
min-height: var(--_pr-hmn);
|
|
225
|
-
|
|
226
|
-
height: 100%;
|
|
227
|
-
min-width: var(--su-static6);
|
|
228
|
-
position: relative;
|
|
229
|
-
}
|
|
230
|
-
|
|
231
|
-
& &--label {
|
|
232
|
-
align-items: var(--_pr-label-ai);
|
|
233
|
-
border: var(--su-static1) solid var(--_pr-label-bc);
|
|
234
|
-
display: var(--_pr-label-d);
|
|
235
|
-
gap: var(--_pr-label-g);
|
|
236
|
-
justify-content: var(--_pr-label-jc);
|
|
237
|
-
padding-left: var(--_pr-label-px);
|
|
238
|
-
padding-right: var(--_pr-label-px);
|
|
239
|
-
|
|
240
|
-
border-radius: var(--br-md);
|
|
241
|
-
color: var(--fc-dark);
|
|
242
|
-
font-size: var(--fs-caption);
|
|
243
|
-
height: 100%;
|
|
244
|
-
line-height: var(--lh-xs);
|
|
245
|
-
position: absolute;
|
|
246
|
-
width: 100%;
|
|
247
|
-
z-index: calc(var(--zi-base) + 2);
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
& &--segments { // DEPRECATED: AFAICT, this is unused in core (as well as it's intended parent variant class `.s-progress__segmented`)
|
|
251
|
-
li {
|
|
252
|
-
&:not(:first-child):not(:last-child):before {
|
|
253
|
-
background-color: var(--white);
|
|
254
|
-
content: "";
|
|
255
|
-
display: block;
|
|
256
|
-
height: 100%;
|
|
257
|
-
left: calc(var(--su-static1) * -1); // -1px
|
|
258
|
-
position: absolute;
|
|
259
|
-
top: 0;
|
|
260
|
-
width: var(--su-static4);
|
|
261
|
-
}
|
|
262
|
-
|
|
263
|
-
display: block;
|
|
264
|
-
padding-top: var(--su-static4);
|
|
265
|
-
position: relative;
|
|
266
|
-
text-align: center;
|
|
267
|
-
}
|
|
268
|
-
|
|
269
|
-
display: flex;
|
|
270
|
-
height: 100%;
|
|
271
|
-
justify-content: space-between;
|
|
272
|
-
list-style: none;
|
|
273
|
-
margin: 0;
|
|
274
|
-
padding: 0;
|
|
275
|
-
position: absolute;
|
|
276
|
-
top: 0;
|
|
277
|
-
width: 100%;
|
|
278
|
-
}
|
|
279
|
-
|
|
280
|
-
background-color: var(--_pr-bg);
|
|
281
|
-
border-radius: var(--_pr-bar);
|
|
282
|
-
height: var(--_pr-size, var(--_pr-h));
|
|
283
|
-
min-height: var(--_pr-hmn);
|
|
284
|
-
|
|
285
|
-
min-width: var(--su-static6);
|
|
286
|
-
position: relative;
|
|
287
|
-
width: var(--_pr-size, var(--_pr-w));
|
|
288
|
-
}
|
|
289
|
-
|
|
290
|
-
// [1] Multiply the circle circumference by an the opposite percentage of what we want to display
|
|
291
|
-
// For example 70%, represented as a decimal is 0.7
|
|
292
|
-
// The opposite of that is 0.3 so ( 1 - 0.7 )
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
.s-skeleton {
|
|
2
|
-
// BASE COMPONENT-SPECIFIC CUSTOM PROPERTIES
|
|
3
|
-
// TODO verify colors with design
|
|
4
|
-
--_sk-bg-1: var(--black-400);
|
|
5
|
-
--_sk-bg-2: var(--black-350);
|
|
6
|
-
--_sk-bg-3: var(--black-300);
|
|
7
|
-
--_sk-o: 0.25;
|
|
8
|
-
|
|
9
|
-
// CONTEXTUAL STYLES
|
|
10
|
-
.highcontrast-mode({
|
|
11
|
-
--_sk-o: 0.4;
|
|
12
|
-
});
|
|
13
|
-
|
|
14
|
-
@keyframes flow {
|
|
15
|
-
0% {
|
|
16
|
-
background-position: 400% 50%;
|
|
17
|
-
}
|
|
18
|
-
100% {
|
|
19
|
-
background-position: 0% 50%;
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
// VARIANTS
|
|
24
|
-
&&__ai {
|
|
25
|
-
--_sk-bg-1: #ac76f0;
|
|
26
|
-
--_sk-bg-2: #297fff;
|
|
27
|
-
--_sk-bg-3: #6abcf8;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
&,
|
|
31
|
-
&:after,
|
|
32
|
-
&:before {
|
|
33
|
-
@media (prefers-reduced-motion: no-preference) {
|
|
34
|
-
animation: flow 8s linear infinite;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
background-image: linear-gradient(
|
|
38
|
-
to right,
|
|
39
|
-
var(--_sk-bg-1) 8%,
|
|
40
|
-
var(--_sk-bg-2) 16%,
|
|
41
|
-
var(--_sk-bg-3) 25%,
|
|
42
|
-
var(--_sk-bg-1) 42%,
|
|
43
|
-
var(--_sk-bg-2) 58%,
|
|
44
|
-
var(--_sk-bg-3) 75%,
|
|
45
|
-
var(--_sk-bg-1) 83%
|
|
46
|
-
);
|
|
47
|
-
background-size: 400% 100%;
|
|
48
|
-
border-radius: var(--br-md);
|
|
49
|
-
display: block;
|
|
50
|
-
height: var(--su16);
|
|
51
|
-
position: relative;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
&:after,
|
|
55
|
-
&:before {
|
|
56
|
-
content: '';
|
|
57
|
-
position: relative;
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
&:after {
|
|
61
|
-
top: calc(var(--su4));
|
|
62
|
-
width: calc(2/3 * 100%);
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
&:before {
|
|
66
|
-
top: calc(var(--su32) + var(--su8));
|
|
67
|
-
width: calc(1/3 * 100%);
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
margin-bottom: var(--su48);
|
|
71
|
-
opacity: var(--_sk-o);
|
|
72
|
-
width: 100%;
|
|
73
|
-
}
|
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
.s-spinner {
|
|
2
|
-
--_sp-baw: calc(var(--su-static1) * 3); // 3px
|
|
3
|
-
--_sp-size: var(--su-static24);
|
|
4
|
-
|
|
5
|
-
// MODIFIERS
|
|
6
|
-
&&__xs {
|
|
7
|
-
--_sp-baw: var(--su-static1);
|
|
8
|
-
--_sp-size: var(--su-static12);
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
&&__sm {
|
|
12
|
-
--_sp-baw: var(--su-static2);
|
|
13
|
-
--_sp-size: var(--su-static16);
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
&&__md {
|
|
17
|
-
--_sp-baw: var(--su-static4);
|
|
18
|
-
--_sp-size: var(--su-static32);
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
&&__lg {
|
|
22
|
-
--_sp-baw: var(--su-static6);
|
|
23
|
-
--_sp-size: var(--su-static48);
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
// CHILD ELEMENTS
|
|
27
|
-
&:after,
|
|
28
|
-
&:before {
|
|
29
|
-
border: var(--_sp-baw) solid currentColor;
|
|
30
|
-
|
|
31
|
-
border-radius: var(--br-circle);
|
|
32
|
-
content: '';
|
|
33
|
-
height: 100%;
|
|
34
|
-
position: absolute;
|
|
35
|
-
width: 100%;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
&:after {
|
|
39
|
-
border-top-color: transparent;
|
|
40
|
-
border-right-color: transparent;
|
|
41
|
-
border-bottom-color: transparent;
|
|
42
|
-
animation: s-spinner-rotate 0.9s infinite cubic-bezier(0.5, 0.1, 0.5, 0.9);
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
&:before {
|
|
46
|
-
opacity: 0.25;
|
|
47
|
-
transform: rotate(90deg); // [1]
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
height: var(--_sp-size);
|
|
51
|
-
width: var(--_sp-size);
|
|
52
|
-
|
|
53
|
-
position: relative;
|
|
54
|
-
text-align: left; // [2]
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
.is-loading {
|
|
58
|
-
--_li-offset: 0.6em;
|
|
59
|
-
--_il-size: 1.23076923em;
|
|
60
|
-
|
|
61
|
-
&:after,
|
|
62
|
-
&:before {
|
|
63
|
-
border-radius: var(--br-circle);
|
|
64
|
-
border-style: solid;
|
|
65
|
-
border-width: var(--su-static2);
|
|
66
|
-
content: "";
|
|
67
|
-
height: var(--_il-size);
|
|
68
|
-
left: var(--_li-offset);
|
|
69
|
-
position: absolute;
|
|
70
|
-
top: calc(50% - var(--_li-offset));
|
|
71
|
-
width: var(--_il-size);
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
&:after {
|
|
75
|
-
animation: s-spinner-rotate 0.9s infinite cubic-bezier(0.5, 0.1, 0.5, 0.9);
|
|
76
|
-
border-color: transparent;
|
|
77
|
-
border-left-color: currentColor;
|
|
78
|
-
filter: invert(0); // [1]
|
|
79
|
-
transform-origin: 50% 50% var(--su-static1); // [1]
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
&:before {
|
|
83
|
-
border-color: currentColor;
|
|
84
|
-
opacity: 0.3;
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
padding-left: 2.2em;
|
|
88
|
-
position: relative;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
// Keyframes
|
|
92
|
-
@keyframes s-spinner-rotate {
|
|
93
|
-
from {
|
|
94
|
-
transform: rotate(0deg);
|
|
95
|
-
}
|
|
96
|
-
to {
|
|
97
|
-
transform: rotate(360deg);
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
// [1] no-op to reduce wobble in Edge. More info: https://github.com/StackExchange/Stacks/blob/d2af26aca06c47e3f1f7a638e49b221a9e28e450/lib/css/components/_stacks-spinner.less#L16-L26
|
|
102
|
-
|
|
103
|
-
// [2] When within a parent that has text-align: center, the spinner's entire container spins, not just the spinner. Let's force text-align left so things spin internally.
|