@stackoverflow/stacks 1.8.0 → 1.9.1
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/README.md +161 -153
- package/dist/{controllers/s-banner.d.ts → components/banner/banner.d.ts} +1 -1
- package/dist/{controllers/s-expandable-control.d.ts → components/expandable/expandable.d.ts} +1 -1
- package/dist/{controllers/s-modal.d.ts → components/modal/modal.d.ts} +1 -1
- package/dist/{controllers/s-navigation-tablist.d.ts → components/navigation/navigation.d.ts} +1 -1
- package/dist/{controllers/s-popover.d.ts → components/popover/popover.d.ts} +1 -1
- package/dist/{controllers/s-tooltip.d.ts → components/popover/tooltip.d.ts} +1 -1
- package/dist/components/table/table.d.ts +30 -0
- package/dist/{controllers/s-toast.d.ts → components/toast/toast.d.ts} +1 -1
- package/dist/{controllers/s-uploader.d.ts → components/uploader/uploader.d.ts} +1 -1
- package/dist/controllers.d.ts +9 -0
- package/dist/css/stacks.css +2063 -1994
- package/dist/css/stacks.min.css +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/js/stacks.js +1465 -1436
- package/dist/js/stacks.min.js +1 -1
- package/lib/{css/atomic/borders.less → atomic/border.less} +397 -379
- package/lib/{css/atomic/colors.less → atomic/color.less} +210 -210
- package/lib/{css/atomic → atomic}/flex.less +426 -426
- package/lib/{css/atomic → atomic}/gap.less +44 -44
- package/lib/{css/atomic → atomic}/grid.less +139 -139
- package/lib/{css/atomic → atomic}/misc.less +343 -343
- package/lib/{css/atomic → atomic}/spacing.less +342 -342
- package/lib/{css/atomic → atomic}/typography.less +267 -267
- package/lib/{css/atomic → atomic}/width-height.less +194 -194
- package/lib/{css/base → base}/body.less +44 -44
- package/lib/{css/base → base}/configuration-static.less +61 -61
- package/lib/{css/base → base}/fieldset.less +5 -5
- package/lib/{css/base/icons.less → base/icon.less} +11 -20
- package/lib/{css/base/internals.less → base/internal.less} +220 -220
- package/lib/{css/base → base}/reset-meyer.less +64 -64
- package/lib/{css/base → base}/reset-normalize.less +449 -449
- package/lib/{css/base → base}/reset.less +20 -20
- package/lib/components/activity-indicator/activity-indicator.a11y.test.ts +21 -0
- package/lib/{css/components → components/activity-indicator}/activity-indicator.less +40 -40
- package/lib/components/activity-indicator/activity-indicator.visual.test.ts +23 -0
- package/lib/{css/components/anchors.less → components/anchor/anchor.less} +61 -61
- package/lib/components/avatar/avatar.a11y.test.ts +36 -0
- package/lib/{css/components/avatars.less → components/avatar/avatar.less} +108 -108
- package/lib/components/avatar/avatar.visual.test.ts +54 -0
- package/lib/components/award-bling/award-bling.a11y.test.ts +17 -0
- package/lib/{css/components → components/award-bling}/award-bling.less +31 -31
- package/lib/components/award-bling/award-bling.visual.test.ts +26 -0
- package/lib/{css/components/badges.less → components/badge/badge.less} +251 -251
- package/lib/components/banner/banner.a11y.test.ts +37 -0
- package/lib/components/banner/banner.less +51 -0
- package/lib/{test/s-banner.test.ts → components/banner/banner.test.ts} +73 -73
- package/lib/{ts/controllers/s-banner.ts → components/banner/banner.ts} +149 -149
- package/lib/components/banner/banner.visual.test.ts +37 -0
- package/lib/components/block-link/block-link.a11y.test.ts +68 -0
- package/lib/{css/components → components/block-link}/block-link.less +80 -80
- package/lib/components/block-link/block-link.visual.test.ts +61 -0
- package/lib/components/breadcrumbs/breadcrumbs.a11y.test.ts +37 -0
- package/lib/{css/components → components/breadcrumbs}/breadcrumbs.less +41 -41
- package/lib/components/breadcrumbs/breadcrumbs.visual.test.ts +37 -0
- package/lib/components/button/button.a11y.test.ts +32 -0
- package/lib/{css/components/buttons.less → components/button/button.less} +502 -501
- package/lib/components/button/button.visual.test.ts +52 -0
- package/lib/{css/components/button-groups.less → components/button-group/button-group.less} +83 -83
- package/lib/components/card/card.a11y.test.ts +13 -0
- package/lib/{css/components/cards.less → components/card/card.less} +29 -29
- package/lib/components/card/card.visual.test.ts +54 -0
- package/lib/components/check-control/check-control.less +17 -0
- package/lib/components/check-group/check-group.less +19 -0
- package/lib/{css/components/checkboxes-radios.less → components/checkbox_radio/checkbox_radio.less} +158 -158
- package/lib/{css/components/code-blocks.less → components/code-block/code-block.less} +116 -116
- package/lib/{css/components → components/description}/description.less +9 -9
- package/lib/{css/components/empty-states.less → components/empty-state/empty-state.less} +16 -16
- package/lib/{css/components → components/expandable}/expandable.less +118 -115
- package/lib/components/expandable/expandable.test.ts +51 -0
- package/lib/{ts/controllers/s-expandable-control.ts → components/expandable/expandable.ts} +238 -238
- package/lib/components/input-fill/input-fill.less +35 -0
- package/lib/components/input-icon/input-icon.less +45 -0
- package/lib/components/input-message/input-message.less +48 -0
- package/lib/{css/components/inputs.less → components/input_textarea/input_textarea.less} +166 -297
- package/lib/{css/components/labels.less → components/label/label.less} +111 -111
- package/lib/{css/components → components/link}/link.less +119 -119
- package/lib/{css/components/link-previews.less → components/link-preview/link-preview.less} +139 -139
- package/lib/{css/components → components/menu}/menu.less +41 -41
- package/lib/{css/components/modals.less → components/modal/modal.less} +113 -113
- package/lib/{ts/controllers/s-modal.ts → components/modal/modal.ts} +379 -379
- package/lib/{css/components → components/navigation}/navigation.less +134 -134
- package/lib/{ts/controllers/s-navigation-tablist.ts → components/navigation/navigation.ts} +128 -128
- package/lib/{css/components/notices.less → components/notice/notice.less} +203 -292
- package/lib/{css/components/page-titles.less → components/page-title/page-title.less} +51 -51
- package/lib/{css/components → components/pagination}/pagination.less +52 -52
- package/lib/{css/components/popovers.less → components/popover/popover.less} +148 -147
- package/lib/{ts/controllers/s-popover.ts → components/popover/popover.ts} +651 -651
- package/lib/{test/s-tooltip.test.ts → components/popover/tooltip.test.ts} +62 -62
- package/lib/{ts/controllers/s-tooltip.ts → components/popover/tooltip.ts} +343 -343
- package/lib/{test/s-tooltip.visual.test.ts → components/popover/tooltip.visual.test.ts} +31 -31
- package/lib/{css/components → components/post-summary}/post-summary.less +415 -415
- package/lib/{css/components/progress-bars.less → components/progress-bar/progress-bar.less} +291 -291
- package/lib/{css/components → components/prose}/prose.less +452 -452
- package/lib/{css/components → components/select}/select.less +148 -148
- package/lib/{css/components/sidebar-widgets.less → components/sidebar-widget/sidebar-widget.less} +257 -259
- package/lib/{css/components → components/spinner}/spinner.less +103 -103
- package/lib/{css/components → components/table}/table.less +307 -297
- package/lib/components/table/table.test.ts +366 -0
- package/lib/{ts/controllers/s-table.ts → components/table/table.ts} +296 -263
- package/lib/components/table-container/table-container.less +4 -0
- package/lib/{css/components/tags.less → components/tag/tag.less} +213 -213
- package/lib/components/toast/toast.less +35 -0
- package/lib/{test/s-toast.test.ts → components/toast/toast.test.ts} +63 -63
- package/lib/{ts/controllers/s-toast.ts → components/toast/toast.ts} +357 -357
- package/lib/components/toast/toast.visual.test.ts +27 -0
- package/lib/{css/components/toggle-switches.less → components/toggle-switch/toggle-switch.less} +110 -110
- package/lib/{css/components → components/topbar}/topbar.less +436 -435
- package/lib/{css/components → components/uploader}/uploader.less +195 -195
- package/lib/{ts/controllers/s-uploader.ts → components/uploader/uploader.ts} +205 -205
- package/lib/{css/components/user-cards.less → components/user-card/user-card.less} +129 -129
- package/lib/controllers.ts +33 -0
- package/lib/{css/exports → exports}/constants-colors.less +1112 -1111
- package/lib/{css/exports → exports}/constants-helpers.less +108 -108
- package/lib/{css/exports → exports}/constants-type.less +153 -153
- package/lib/{css/exports → exports}/exports.less +15 -15
- package/lib/{css/exports → exports}/mixins.less +299 -299
- package/lib/{ts/index.ts → index.ts} +32 -32
- package/lib/{css/input-utils.less → input-utils.less} +44 -44
- package/lib/{css/stacks-dynamic.less → stacks-dynamic.less} +24 -25
- package/lib/stacks-static.less +93 -0
- package/lib/{css/stacks.less → stacks.less} +13 -13
- package/lib/{ts/stacks.ts → stacks.ts} +113 -113
- package/lib/test/open-wc-testing-patch.d.ts +26 -0
- package/lib/test/test-utils.ts +466 -0
- package/lib/tsconfig.build.json +4 -0
- package/lib/tsconfig.json +16 -13
- package/package.json +106 -105
- package/dist/controllers/index.d.ts +0 -9
- package/dist/controllers/s-table.d.ts +0 -8
- package/lib/css/stacks-static.less +0 -87
- package/lib/test/s-avatar.a11y.test.ts +0 -77
- package/lib/test/s-banner.visual.test.ts +0 -61
- package/lib/test/s-btn.a11y.test.ts +0 -123
- package/lib/test/s-btn.visual.test.ts +0 -16
- package/lib/test/s-toast.visual.test.ts +0 -48
- package/lib/ts/controllers/index.ts +0 -17
|
@@ -1,267 +1,267 @@
|
|
|
1
|
-
//
|
|
2
|
-
// STACK OVERFLOW
|
|
3
|
-
// TYPOGRAPHY
|
|
4
|
-
//
|
|
5
|
-
// This CSS comes from Stacks, our CSS & Pattern library for rapidly building
|
|
6
|
-
// Stack Overflow. For documentation of all these classes and how to contribute,
|
|
7
|
-
// visit https://stackoverflow.design/
|
|
8
|
-
//
|
|
9
|
-
// TABLE OF CONTENTS
|
|
10
|
-
// • ATOMIC CLASSES
|
|
11
|
-
//
|
|
12
|
-
// ============================================================================
|
|
13
|
-
// $ TYPE RESETS
|
|
14
|
-
// ----------------------------------------------------------------------------
|
|
15
|
-
h1,
|
|
16
|
-
h2,
|
|
17
|
-
h3,
|
|
18
|
-
h4,
|
|
19
|
-
h5,
|
|
20
|
-
h6,
|
|
21
|
-
p {
|
|
22
|
-
margin-top: 0;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
// ============================================================================
|
|
26
|
-
// $ TEXT SIZES
|
|
27
|
-
// ----------------------------------------------------------------------------
|
|
28
|
-
// Declare font sizes
|
|
29
|
-
.fs-display4 { font-size: var(--fs-display4) !important; }
|
|
30
|
-
.fs-display3 { font-size: var(--fs-display3) !important; }
|
|
31
|
-
.fs-display2 { font-size: var(--fs-display2) !important; }
|
|
32
|
-
.fs-display1 { font-size: var(--fs-display1) !important; }
|
|
33
|
-
.fs-headline2 { font-size: var(--fs-headline2) !important; }
|
|
34
|
-
.fs-headline1 { font-size: var(--fs-headline1) !important; }
|
|
35
|
-
.fs-title { font-size: var(--fs-title) !important; }
|
|
36
|
-
.fs-subheading { font-size: var(--fs-subheading) !important; }
|
|
37
|
-
.fs-body3 { font-size: var(--fs-body3) !important; }
|
|
38
|
-
.fs-body2 { font-size: var(--fs-body2) !important; }
|
|
39
|
-
.fs-body1 { font-size: var(--fs-body1) !important; }
|
|
40
|
-
|
|
41
|
-
.fs-caption,
|
|
42
|
-
.fs-category { font-size: var(--fs-caption) !important; }
|
|
43
|
-
.fs-fine { font-size: var(--fs-fine) !important; }
|
|
44
|
-
|
|
45
|
-
#stacks-internals #screen-sm({
|
|
46
|
-
.fs-display4 { font-size: 3.8rem !important; }
|
|
47
|
-
.fs-display3 { font-size: 3.3rem !important; }
|
|
48
|
-
.fs-display2 { font-size: 3rem !important; }
|
|
49
|
-
.fs-display1 { font-size: 2.6rem !important; }
|
|
50
|
-
.fs-headline2 { font-size: 2.3rem !important; }
|
|
51
|
-
.fs-headline1 { font-size: 2rem !important; }
|
|
52
|
-
.fs-title { font-size: 1.8rem !important; }
|
|
53
|
-
.fs-subheading { font-size: 1.6rem !important; }
|
|
54
|
-
.fs-body3 { font-size: 1.4rem !important; }
|
|
55
|
-
.fs-body2 { font-size: 1.3rem !important; }
|
|
56
|
-
}, @force-selector: true);
|
|
57
|
-
|
|
58
|
-
.fs-category {
|
|
59
|
-
font-weight: 600;
|
|
60
|
-
text-transform: uppercase;
|
|
61
|
-
|
|
62
|
-
// If a top border is desired
|
|
63
|
-
&.has-border {
|
|
64
|
-
width: 100%;
|
|
65
|
-
padding: var(--su4) 0;
|
|
66
|
-
border-top: 1px solid var(--bc-medium);
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
// ============================================================================
|
|
71
|
-
// $$ TEXT COLORS
|
|
72
|
-
// ----------------------------------------------------------------------------
|
|
73
|
-
.fc-dark { color: var(--fc-dark) !important; }
|
|
74
|
-
.fc-medium { color: var(--fc-medium) !important; }
|
|
75
|
-
.fc-light { color: var(--fc-light) !important; }
|
|
76
|
-
|
|
77
|
-
// ============================================================================
|
|
78
|
-
// $ LINE HEIGHTS
|
|
79
|
-
// ----------------------------------------------------------------------------
|
|
80
|
-
.lh-xs { line-height: var(--lh-xs) !important; }
|
|
81
|
-
.lh-sm { line-height: var(--lh-sm) !important; }
|
|
82
|
-
.lh-md { line-height: var(--lh-md) !important; }
|
|
83
|
-
.lh-lg { line-height: var(--lh-lg) !important; }
|
|
84
|
-
.lh-xl { line-height: var(--lh-xl) !important; }
|
|
85
|
-
.lh-xxl { line-height: var(--lh-xxl) !important; }
|
|
86
|
-
.lh-unset { line-height: initial !important; }
|
|
87
|
-
|
|
88
|
-
// ============================================================================
|
|
89
|
-
// $$ TEXT STYLES & UTILITIES
|
|
90
|
-
// ----------------------------------------------------------------------------
|
|
91
|
-
// -- Font Family
|
|
92
|
-
.ff-sans { font-family: var(--ff-sans) !important; }
|
|
93
|
-
.ff-serif { font-family: var(--ff-serif) !important; }
|
|
94
|
-
.ff-mono { font-family: var(--ff-mono) !important; }
|
|
95
|
-
.ff-inherit { font-family: inherit !important; }
|
|
96
|
-
|
|
97
|
-
// -- Font Weight
|
|
98
|
-
.fw-normal { font-weight: 400 !important; }
|
|
99
|
-
.fw-bold { font-weight: 600 !important; }
|
|
100
|
-
|
|
101
|
-
// -- Font Styles
|
|
102
|
-
.fs-normal { font-style: normal !important; }
|
|
103
|
-
.fs-italic { font-style: italic !important; }
|
|
104
|
-
.fs-unset { font-style: unset !important; }
|
|
105
|
-
|
|
106
|
-
// -- Text Align
|
|
107
|
-
#stacks-internals #responsify('.ta-left', { text-align: left !important; });
|
|
108
|
-
#stacks-internals #responsify('.ta-center', { text-align: center !important; });
|
|
109
|
-
#stacks-internals #responsify('.ta-right', { text-align: right !important; });
|
|
110
|
-
.ta-justify { text-align: justify !important; }
|
|
111
|
-
.ta-unset { text-align: unset !important; }
|
|
112
|
-
|
|
113
|
-
// -- Text Decoration
|
|
114
|
-
.td-none { text-decoration: none !important; }
|
|
115
|
-
.td-underline { text-decoration: underline !important; }
|
|
116
|
-
|
|
117
|
-
// -- Text Transform
|
|
118
|
-
.tt-capitalize { text-transform: capitalize !important; }
|
|
119
|
-
.tt-lowercase { text-transform: lowercase !important; }
|
|
120
|
-
.tt-uppercase { text-transform: uppercase !important; }
|
|
121
|
-
.tt-none { text-transform: none !important; }
|
|
122
|
-
.tt-unset { text-transform: unset !important; }
|
|
123
|
-
|
|
124
|
-
// -- Text Truncate
|
|
125
|
-
.truncate {
|
|
126
|
-
overflow: hidden;
|
|
127
|
-
max-width: 100%;
|
|
128
|
-
text-overflow: ellipsis !important;
|
|
129
|
-
white-space: nowrap;
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
.v-truncate1 {
|
|
133
|
-
.truncation(1);
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
.v-truncate2 {
|
|
137
|
-
.truncation(2);
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
.v-truncate3 {
|
|
141
|
-
.truncation(3);
|
|
142
|
-
}
|
|
143
|
-
|
|
144
|
-
.v-truncate4 {
|
|
145
|
-
.truncation(4);
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
.v-truncate5 {
|
|
149
|
-
.truncation(5);
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
.truncation(@count) {
|
|
153
|
-
// Despite these all being webkit-specific properties, this works across
|
|
154
|
-
// Safari, Chrome, Edge, and Firefox.
|
|
155
|
-
display: -webkit-box;
|
|
156
|
-
-webkit-line-clamp: @count;
|
|
157
|
-
-webkit-box-orient: vertical;
|
|
158
|
-
overflow: hidden;
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
.v-truncate-fade {
|
|
162
|
-
overflow: hidden;
|
|
163
|
-
-webkit-mask-image: linear-gradient(180deg, #000 calc(var(--lh-md) * 9em), transparent);
|
|
164
|
-
mask-image: linear-gradient(180deg, #000 calc(var(--lh-md) * 9em), transparent);
|
|
165
|
-
max-height: calc(var(--lh-md) * 12em);
|
|
166
|
-
|
|
167
|
-
&.v-truncate-fade__sm {
|
|
168
|
-
-webkit-mask-image: linear-gradient(180deg, #000 calc(var(--lh-md) * 3em), transparent);
|
|
169
|
-
mask-image: linear-gradient(180deg, #000 calc(var(--lh-md) * 3em), transparent);
|
|
170
|
-
max-height: calc(var(--lh-md) * 6em);
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
&.v-truncate-fade__lg {
|
|
174
|
-
-webkit-mask-image: linear-gradient(180deg, #000 calc(var(--lh-md) * 21em), transparent);
|
|
175
|
-
mask-image: linear-gradient(180deg, #000 calc(var(--lh-md) * 21em), transparent);
|
|
176
|
-
max-height: calc(var(--lh-md) * 24em);
|
|
177
|
-
}
|
|
178
|
-
}
|
|
179
|
-
|
|
180
|
-
// -- Whitespace
|
|
181
|
-
.ws-normal { white-space: normal !important; }
|
|
182
|
-
.ws-nowrap { white-space: nowrap !important; }
|
|
183
|
-
.ws-pre { white-space: pre !important; }
|
|
184
|
-
.ws-pre-wrap { white-space: pre-wrap !important; }
|
|
185
|
-
.ws-pre-line { white-space: pre-line !important; }
|
|
186
|
-
.ws-unset { white-space: unset !important; }
|
|
187
|
-
|
|
188
|
-
// -- Word Break
|
|
189
|
-
.wb-normal { word-break: normal !important; }
|
|
190
|
-
.wb-break-all { word-break: break-all !important; }
|
|
191
|
-
.wb-keep-all { word-break: keep-all !important; }
|
|
192
|
-
.wb-inherit { word-break: inherit !important; }
|
|
193
|
-
.wb-initial { word-break: initial !important; }
|
|
194
|
-
.wb-unset { word-break: unset !important; }
|
|
195
|
-
|
|
196
|
-
// -- Overflow Wrap
|
|
197
|
-
.ow-normal {
|
|
198
|
-
overflow-wrap: normal !important;
|
|
199
|
-
}
|
|
200
|
-
|
|
201
|
-
.ow-break-word {
|
|
202
|
-
overflow-wrap: break-word !important;
|
|
203
|
-
}
|
|
204
|
-
|
|
205
|
-
.ow-inherit {
|
|
206
|
-
overflow-wrap: inherit !important;
|
|
207
|
-
}
|
|
208
|
-
|
|
209
|
-
.ow-initial {
|
|
210
|
-
overflow-wrap: initial !important;
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
.ow-unset {
|
|
214
|
-
overflow-wrap: unset !important;
|
|
215
|
-
}
|
|
216
|
-
|
|
217
|
-
// -- Hyphenation
|
|
218
|
-
.hyphens-none { hyphens: none !important; }
|
|
219
|
-
.hyphens-auto {
|
|
220
|
-
-ms-hyphens: auto !important;
|
|
221
|
-
-webkit-hyphens: auto !important;
|
|
222
|
-
hyphens: auto !important;
|
|
223
|
-
}
|
|
224
|
-
.hyphens-unset { hyphens: unset !important; }
|
|
225
|
-
|
|
226
|
-
// -- Break word
|
|
227
|
-
.break-word {
|
|
228
|
-
word-break: break-word !important;
|
|
229
|
-
overflow-wrap: break-word !important;
|
|
230
|
-
-webkit-hyphens: auto !important;
|
|
231
|
-
-moz-hyphens: auto !important;
|
|
232
|
-
-ms-hyphens: auto !important;
|
|
233
|
-
hyphens: auto !important;
|
|
234
|
-
}
|
|
235
|
-
|
|
236
|
-
// ============================================================================
|
|
237
|
-
// $ LISTS
|
|
238
|
-
// ----------------------------------------------------------------------------
|
|
239
|
-
ul,
|
|
240
|
-
ol {
|
|
241
|
-
padding: 0;
|
|
242
|
-
margin-left: 2.8em;
|
|
243
|
-
|
|
244
|
-
ul,
|
|
245
|
-
ol {
|
|
246
|
-
margin-bottom: 0;
|
|
247
|
-
}
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
ul { list-style-type: disc; }
|
|
251
|
-
ol { list-style-type: decimal; }
|
|
252
|
-
|
|
253
|
-
.list-reset {
|
|
254
|
-
list-style: none;
|
|
255
|
-
margin: 0;
|
|
256
|
-
padding: 0;
|
|
257
|
-
}
|
|
258
|
-
|
|
259
|
-
// -- List Style Types
|
|
260
|
-
.list-ls-none { list-style: none !important; }
|
|
261
|
-
.list-ls-disc { list-style-type: disc !important; }
|
|
262
|
-
.list-ls-decimal { list-style-type: decimal !important; }
|
|
263
|
-
.list-ls-unset { list-style-type: unset !important; }
|
|
264
|
-
|
|
265
|
-
// -- List Position
|
|
266
|
-
.list-inside { list-style-position: inside !important; }
|
|
267
|
-
.list-outside { list-style-position: outside !important; }
|
|
1
|
+
//
|
|
2
|
+
// STACK OVERFLOW
|
|
3
|
+
// TYPOGRAPHY
|
|
4
|
+
//
|
|
5
|
+
// This CSS comes from Stacks, our CSS & Pattern library for rapidly building
|
|
6
|
+
// Stack Overflow. For documentation of all these classes and how to contribute,
|
|
7
|
+
// visit https://stackoverflow.design/
|
|
8
|
+
//
|
|
9
|
+
// TABLE OF CONTENTS
|
|
10
|
+
// • ATOMIC CLASSES
|
|
11
|
+
//
|
|
12
|
+
// ============================================================================
|
|
13
|
+
// $ TYPE RESETS
|
|
14
|
+
// ----------------------------------------------------------------------------
|
|
15
|
+
h1,
|
|
16
|
+
h2,
|
|
17
|
+
h3,
|
|
18
|
+
h4,
|
|
19
|
+
h5,
|
|
20
|
+
h6,
|
|
21
|
+
p {
|
|
22
|
+
margin-top: 0;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
// ============================================================================
|
|
26
|
+
// $ TEXT SIZES
|
|
27
|
+
// ----------------------------------------------------------------------------
|
|
28
|
+
// Declare font sizes
|
|
29
|
+
.fs-display4 { font-size: var(--fs-display4) !important; }
|
|
30
|
+
.fs-display3 { font-size: var(--fs-display3) !important; }
|
|
31
|
+
.fs-display2 { font-size: var(--fs-display2) !important; }
|
|
32
|
+
.fs-display1 { font-size: var(--fs-display1) !important; }
|
|
33
|
+
.fs-headline2 { font-size: var(--fs-headline2) !important; }
|
|
34
|
+
.fs-headline1 { font-size: var(--fs-headline1) !important; }
|
|
35
|
+
.fs-title { font-size: var(--fs-title) !important; }
|
|
36
|
+
.fs-subheading { font-size: var(--fs-subheading) !important; }
|
|
37
|
+
.fs-body3 { font-size: var(--fs-body3) !important; }
|
|
38
|
+
.fs-body2 { font-size: var(--fs-body2) !important; }
|
|
39
|
+
.fs-body1 { font-size: var(--fs-body1) !important; }
|
|
40
|
+
|
|
41
|
+
.fs-caption,
|
|
42
|
+
.fs-category { font-size: var(--fs-caption) !important; }
|
|
43
|
+
.fs-fine { font-size: var(--fs-fine) !important; }
|
|
44
|
+
|
|
45
|
+
#stacks-internals #screen-sm({
|
|
46
|
+
.fs-display4 { font-size: 3.8rem !important; }
|
|
47
|
+
.fs-display3 { font-size: 3.3rem !important; }
|
|
48
|
+
.fs-display2 { font-size: 3rem !important; }
|
|
49
|
+
.fs-display1 { font-size: 2.6rem !important; }
|
|
50
|
+
.fs-headline2 { font-size: 2.3rem !important; }
|
|
51
|
+
.fs-headline1 { font-size: 2rem !important; }
|
|
52
|
+
.fs-title { font-size: 1.8rem !important; }
|
|
53
|
+
.fs-subheading { font-size: 1.6rem !important; }
|
|
54
|
+
.fs-body3 { font-size: 1.4rem !important; }
|
|
55
|
+
.fs-body2 { font-size: 1.3rem !important; }
|
|
56
|
+
}, @force-selector: true);
|
|
57
|
+
|
|
58
|
+
.fs-category {
|
|
59
|
+
font-weight: 600;
|
|
60
|
+
text-transform: uppercase;
|
|
61
|
+
|
|
62
|
+
// If a top border is desired
|
|
63
|
+
&.has-border {
|
|
64
|
+
width: 100%;
|
|
65
|
+
padding: var(--su4) 0;
|
|
66
|
+
border-top: 1px solid var(--bc-medium);
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
// ============================================================================
|
|
71
|
+
// $$ TEXT COLORS
|
|
72
|
+
// ----------------------------------------------------------------------------
|
|
73
|
+
.fc-dark { color: var(--fc-dark) !important; }
|
|
74
|
+
.fc-medium { color: var(--fc-medium) !important; }
|
|
75
|
+
.fc-light { color: var(--fc-light) !important; }
|
|
76
|
+
|
|
77
|
+
// ============================================================================
|
|
78
|
+
// $ LINE HEIGHTS
|
|
79
|
+
// ----------------------------------------------------------------------------
|
|
80
|
+
.lh-xs { line-height: var(--lh-xs) !important; }
|
|
81
|
+
.lh-sm { line-height: var(--lh-sm) !important; }
|
|
82
|
+
.lh-md { line-height: var(--lh-md) !important; }
|
|
83
|
+
.lh-lg { line-height: var(--lh-lg) !important; }
|
|
84
|
+
.lh-xl { line-height: var(--lh-xl) !important; }
|
|
85
|
+
.lh-xxl { line-height: var(--lh-xxl) !important; }
|
|
86
|
+
.lh-unset { line-height: initial !important; }
|
|
87
|
+
|
|
88
|
+
// ============================================================================
|
|
89
|
+
// $$ TEXT STYLES & UTILITIES
|
|
90
|
+
// ----------------------------------------------------------------------------
|
|
91
|
+
// -- Font Family
|
|
92
|
+
.ff-sans { font-family: var(--ff-sans) !important; }
|
|
93
|
+
.ff-serif { font-family: var(--ff-serif) !important; }
|
|
94
|
+
.ff-mono { font-family: var(--ff-mono) !important; }
|
|
95
|
+
.ff-inherit { font-family: inherit !important; }
|
|
96
|
+
|
|
97
|
+
// -- Font Weight
|
|
98
|
+
.fw-normal { font-weight: 400 !important; }
|
|
99
|
+
.fw-bold { font-weight: 600 !important; }
|
|
100
|
+
|
|
101
|
+
// -- Font Styles
|
|
102
|
+
.fs-normal { font-style: normal !important; }
|
|
103
|
+
.fs-italic { font-style: italic !important; }
|
|
104
|
+
.fs-unset { font-style: unset !important; }
|
|
105
|
+
|
|
106
|
+
// -- Text Align
|
|
107
|
+
#stacks-internals #responsify('.ta-left', { text-align: left !important; });
|
|
108
|
+
#stacks-internals #responsify('.ta-center', { text-align: center !important; });
|
|
109
|
+
#stacks-internals #responsify('.ta-right', { text-align: right !important; });
|
|
110
|
+
.ta-justify { text-align: justify !important; }
|
|
111
|
+
.ta-unset { text-align: unset !important; }
|
|
112
|
+
|
|
113
|
+
// -- Text Decoration
|
|
114
|
+
.td-none { text-decoration: none !important; }
|
|
115
|
+
.td-underline { text-decoration: underline !important; }
|
|
116
|
+
|
|
117
|
+
// -- Text Transform
|
|
118
|
+
.tt-capitalize { text-transform: capitalize !important; }
|
|
119
|
+
.tt-lowercase { text-transform: lowercase !important; }
|
|
120
|
+
.tt-uppercase { text-transform: uppercase !important; }
|
|
121
|
+
.tt-none { text-transform: none !important; }
|
|
122
|
+
.tt-unset { text-transform: unset !important; }
|
|
123
|
+
|
|
124
|
+
// -- Text Truncate
|
|
125
|
+
.truncate {
|
|
126
|
+
overflow: hidden;
|
|
127
|
+
max-width: 100%;
|
|
128
|
+
text-overflow: ellipsis !important;
|
|
129
|
+
white-space: nowrap;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
.v-truncate1 {
|
|
133
|
+
.truncation(1);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
.v-truncate2 {
|
|
137
|
+
.truncation(2);
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.v-truncate3 {
|
|
141
|
+
.truncation(3);
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
.v-truncate4 {
|
|
145
|
+
.truncation(4);
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
.v-truncate5 {
|
|
149
|
+
.truncation(5);
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
.truncation(@count) {
|
|
153
|
+
// Despite these all being webkit-specific properties, this works across
|
|
154
|
+
// Safari, Chrome, Edge, and Firefox.
|
|
155
|
+
display: -webkit-box;
|
|
156
|
+
-webkit-line-clamp: @count;
|
|
157
|
+
-webkit-box-orient: vertical;
|
|
158
|
+
overflow: hidden;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.v-truncate-fade {
|
|
162
|
+
overflow: hidden;
|
|
163
|
+
-webkit-mask-image: linear-gradient(180deg, #000 calc(var(--lh-md) * 9em), transparent);
|
|
164
|
+
mask-image: linear-gradient(180deg, #000 calc(var(--lh-md) * 9em), transparent);
|
|
165
|
+
max-height: calc(var(--lh-md) * 12em);
|
|
166
|
+
|
|
167
|
+
&.v-truncate-fade__sm {
|
|
168
|
+
-webkit-mask-image: linear-gradient(180deg, #000 calc(var(--lh-md) * 3em), transparent);
|
|
169
|
+
mask-image: linear-gradient(180deg, #000 calc(var(--lh-md) * 3em), transparent);
|
|
170
|
+
max-height: calc(var(--lh-md) * 6em);
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
&.v-truncate-fade__lg {
|
|
174
|
+
-webkit-mask-image: linear-gradient(180deg, #000 calc(var(--lh-md) * 21em), transparent);
|
|
175
|
+
mask-image: linear-gradient(180deg, #000 calc(var(--lh-md) * 21em), transparent);
|
|
176
|
+
max-height: calc(var(--lh-md) * 24em);
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
// -- Whitespace
|
|
181
|
+
.ws-normal { white-space: normal !important; }
|
|
182
|
+
.ws-nowrap { white-space: nowrap !important; }
|
|
183
|
+
.ws-pre { white-space: pre !important; }
|
|
184
|
+
.ws-pre-wrap { white-space: pre-wrap !important; }
|
|
185
|
+
.ws-pre-line { white-space: pre-line !important; }
|
|
186
|
+
.ws-unset { white-space: unset !important; }
|
|
187
|
+
|
|
188
|
+
// -- Word Break
|
|
189
|
+
.wb-normal { word-break: normal !important; }
|
|
190
|
+
.wb-break-all { word-break: break-all !important; }
|
|
191
|
+
.wb-keep-all { word-break: keep-all !important; }
|
|
192
|
+
.wb-inherit { word-break: inherit !important; }
|
|
193
|
+
.wb-initial { word-break: initial !important; }
|
|
194
|
+
.wb-unset { word-break: unset !important; }
|
|
195
|
+
|
|
196
|
+
// -- Overflow Wrap
|
|
197
|
+
.ow-normal {
|
|
198
|
+
overflow-wrap: normal !important;
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
.ow-break-word {
|
|
202
|
+
overflow-wrap: break-word !important;
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
.ow-inherit {
|
|
206
|
+
overflow-wrap: inherit !important;
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
.ow-initial {
|
|
210
|
+
overflow-wrap: initial !important;
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
.ow-unset {
|
|
214
|
+
overflow-wrap: unset !important;
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
// -- Hyphenation
|
|
218
|
+
.hyphens-none { hyphens: none !important; }
|
|
219
|
+
.hyphens-auto {
|
|
220
|
+
-ms-hyphens: auto !important;
|
|
221
|
+
-webkit-hyphens: auto !important;
|
|
222
|
+
hyphens: auto !important;
|
|
223
|
+
}
|
|
224
|
+
.hyphens-unset { hyphens: unset !important; }
|
|
225
|
+
|
|
226
|
+
// -- Break word
|
|
227
|
+
.break-word {
|
|
228
|
+
word-break: break-word !important;
|
|
229
|
+
overflow-wrap: break-word !important;
|
|
230
|
+
-webkit-hyphens: auto !important;
|
|
231
|
+
-moz-hyphens: auto !important;
|
|
232
|
+
-ms-hyphens: auto !important;
|
|
233
|
+
hyphens: auto !important;
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
// ============================================================================
|
|
237
|
+
// $ LISTS
|
|
238
|
+
// ----------------------------------------------------------------------------
|
|
239
|
+
ul,
|
|
240
|
+
ol {
|
|
241
|
+
padding: 0;
|
|
242
|
+
margin-left: 2.8em;
|
|
243
|
+
|
|
244
|
+
ul,
|
|
245
|
+
ol {
|
|
246
|
+
margin-bottom: 0;
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
ul { list-style-type: disc; }
|
|
251
|
+
ol { list-style-type: decimal; }
|
|
252
|
+
|
|
253
|
+
.list-reset {
|
|
254
|
+
list-style: none;
|
|
255
|
+
margin: 0;
|
|
256
|
+
padding: 0;
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
// -- List Style Types
|
|
260
|
+
.list-ls-none { list-style: none !important; }
|
|
261
|
+
.list-ls-disc { list-style-type: disc !important; }
|
|
262
|
+
.list-ls-decimal { list-style-type: decimal !important; }
|
|
263
|
+
.list-ls-unset { list-style-type: unset !important; }
|
|
264
|
+
|
|
265
|
+
// -- List Position
|
|
266
|
+
.list-inside { list-style-position: inside !important; }
|
|
267
|
+
.list-outside { list-style-position: outside !important; }
|