@rossigee/clarity-ui 18.2.1-fixed
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 +29 -0
- package/STYLES.md +1796 -0
- package/accordion/_accordion.clarity.scss +81 -0
- package/accordion/_properties.accordion.scss +45 -0
- package/accordion/_variables.accordion.scss +91 -0
- package/button/_buttons.clarity.scss +374 -0
- package/button/_mixins.buttons.scss +232 -0
- package/button/_properties.buttons.scss +325 -0
- package/button/_properties.toggles.scss +35 -0
- package/button/_variables.buttons.scss +843 -0
- package/button/_variables.toggles.scss +41 -0
- package/button/button-group/_button-group.clarity.scss +193 -0
- package/clr-ui.css +31728 -0
- package/clr-ui.css.map +1 -0
- package/clr-ui.min.css +52 -0
- package/clr-ui.min.css.map +1 -0
- package/collapsible-panel/_mixins.collapsible-panel.scss +189 -0
- package/collapsible-panel/_properties.collapsible-panel.scss +42 -0
- package/collapsible-panel/_variables.collapsible-panel.scss +40 -0
- package/data/_mixins.tables.scss +111 -0
- package/data/_properties.tables.scss +62 -0
- package/data/_tables.clarity.scss +120 -0
- package/data/_variables.tables.scss +42 -0
- package/data/datagrid/_datagrid.clarity.scss +1753 -0
- package/data/datagrid/_mixins.datagrid.scss +102 -0
- package/data/datagrid/_properties.datagrid.scss +90 -0
- package/data/datagrid/_variables.datagrid.scss +96 -0
- package/data/stack-view/_properties.stack-view.scss +50 -0
- package/data/stack-view/_stack-view.clarity.scss +267 -0
- package/data/stack-view/_variables.stack-view.scss +32 -0
- package/data/tree-view/_properties.tree-view.scss +41 -0
- package/data/tree-view/_tree-view.clarity.scss +281 -0
- package/data/tree-view/_variables.tree-view.scss +51 -0
- package/emphasis/alert/_alert.clarity.scss +467 -0
- package/emphasis/alert/_mixins.alert.scss +96 -0
- package/emphasis/alert/_properties.alert.scss +183 -0
- package/emphasis/alert/_variables.alert.scss +502 -0
- package/emphasis/badge/_badges.clarity.scss +61 -0
- package/emphasis/badge/_mixins.bades.scss +34 -0
- package/emphasis/badge/_properties.badges.scss +82 -0
- package/emphasis/badge/_variables.badges.scss +160 -0
- package/emphasis/label/_labels.clarity.scss +175 -0
- package/emphasis/label/_mixins.label.scss +76 -0
- package/emphasis/label/_properties.label.scss +105 -0
- package/emphasis/label/_variables.label.scss +181 -0
- package/forms/combobox/_combobox.clarity.scss +322 -0
- package/forms/combobox/_properties.combobox.scss +45 -0
- package/forms/combobox/_variables.combobox.scss +32 -0
- package/forms/datepicker/_datepicker.clarity.scss +259 -0
- package/forms/datepicker/_mixins.datepicker.scss +90 -0
- package/forms/datepicker/_properties.datepicker.scss +46 -0
- package/forms/datepicker/_variables.datepicker.scss +74 -0
- package/forms/styles/_checkbox.clarity.scss +193 -0
- package/forms/styles/_containers.clarity.scss +228 -0
- package/forms/styles/_datalist.clarity.scss +47 -0
- package/forms/styles/_file-input.clarity.scss +134 -0
- package/forms/styles/_file.clarity.scss +52 -0
- package/forms/styles/_form.clarity.scss +87 -0
- package/forms/styles/_input-group.clarity.scss +118 -0
- package/forms/styles/_input.clarity.scss +78 -0
- package/forms/styles/_mixins.forms.scss +173 -0
- package/forms/styles/_number-input.clarity.scss +58 -0
- package/forms/styles/_password.clarity.scss +26 -0
- package/forms/styles/_properties.forms.scss +121 -0
- package/forms/styles/_radio.clarity.scss +120 -0
- package/forms/styles/_range.clarity.scss +124 -0
- package/forms/styles/_select.clarity.scss +178 -0
- package/forms/styles/_textarea.clarity.scss +77 -0
- package/forms/styles/_toggles.clarity.scss +209 -0
- package/forms/styles/_variables.forms.scss +128 -0
- package/icon/icon.component.scss +242 -0
- package/image/_icons.clarity.scss +101 -0
- package/image/_images.clarity.scss +42 -0
- package/image/_mixins.images.scss +11 -0
- package/layout/_card.clarity.scss +311 -0
- package/layout/_login.clarity.scss +240 -0
- package/layout/_properties.card.scss +36 -0
- package/layout/_properties.login.scss +32 -0
- package/layout/_variables.card.scss +23 -0
- package/layout/_variables.login.scss +22 -0
- package/layout/breadcrumbs/_breadcrumbs.clarity.scss +60 -0
- package/layout/breadcrumbs/_properties.breadcrumbs.scss +18 -0
- package/layout/breadcrumbs/_variables.breadcrumbs.scss +11 -0
- package/layout/grid/_grid.scss +23 -0
- package/layout/grid/grid/_grid.scss +39 -0
- package/layout/grid/mixins/_breakpoint.scss +83 -0
- package/layout/grid/mixins/_clearfix.scss +13 -0
- package/layout/grid/mixins/_grid-framework.scss +91 -0
- package/layout/grid/mixins/_grid.scss +39 -0
- package/layout/grid/utilities/_align.scss +30 -0
- package/layout/grid/utilities/_clearfix.scss +12 -0
- package/layout/grid/utilities/_display.scss +18 -0
- package/layout/grid/utilities/_flex.scss +222 -0
- package/layout/grid/utilities/_float.scss +26 -0
- package/layout/grid/utilities/_visibility.scss +60 -0
- package/layout/main-container/_layout.clarity.scss +87 -0
- package/layout/main-container/_properties.header.scss +39 -0
- package/layout/main-container/_variables.header.scss +32 -0
- package/layout/nav/_header.clarity.scss +40 -0
- package/layout/nav/_links.clarity.scss +84 -0
- package/layout/nav/_mixins.header.scss +332 -0
- package/layout/nav/_mixins.responsive-nav.scss +75 -0
- package/layout/nav/_nav.clarity.scss +100 -0
- package/layout/nav/_properties.nav.scss +27 -0
- package/layout/nav/_properties.responsive-nav.scss +23 -0
- package/layout/nav/_properties.subnav.scss +19 -0
- package/layout/nav/_responsive-nav.clarity.scss +488 -0
- package/layout/nav/_subnav.clarity.scss +48 -0
- package/layout/nav/_variables.nav.scss +13 -0
- package/layout/nav/_variables.responsive-nav.scss +28 -0
- package/layout/nav/_variables.subnav.scss +21 -0
- package/layout/tabs/_mixins.tabs.scss +41 -0
- package/layout/tabs/_properties.tabs.scss +25 -0
- package/layout/tabs/_tabs.clarity.scss +110 -0
- package/layout/tabs/_variables.tabs.scss +17 -0
- package/layout/vertical-nav/_mixins.vertical-nav.scss +52 -0
- package/layout/vertical-nav/_properties.vertical-nav.scss +73 -0
- package/layout/vertical-nav/_variables.vertical-nav.scss +52 -0
- package/layout/vertical-nav/_vertical-nav.clarity.scss +469 -0
- package/main.scss +14 -0
- package/modal/_modal.clarity.scss +362 -0
- package/modal/_properties.modal.scss +45 -0
- package/modal/_variables.modal.scss +38 -0
- package/package.json +15 -0
- package/popover/common/_popover.clarity.scss +28 -0
- package/popover/dropdown/_dropdown.clarity.scss +326 -0
- package/popover/dropdown/_menu-mixins.clarity.scss +132 -0
- package/popover/dropdown/_properties.dropdown.scss +50 -0
- package/popover/dropdown/_variables.dropdown.scss +36 -0
- package/popover/signpost/_properties.signpost.scss +34 -0
- package/popover/signpost/_signposts.clarity.scss +414 -0
- package/popover/signpost/_variables.signpost.scss +21 -0
- package/popover/tooltip/_mixins.tooltip.scss +186 -0
- package/popover/tooltip/_properties.tooltip.scss +28 -0
- package/popover/tooltip/_tooltips.clarity.scss +122 -0
- package/popover/tooltip/_variables.tooltip.scss +20 -0
- package/progress/progress-bars/_progress-bars.clarity.scss +616 -0
- package/progress/progress-bars/_properties.progress-bars.scss +24 -0
- package/progress/progress-bars/_variables.progress-bars.scss +15 -0
- package/progress/progress-bars/utils/_mixins.clarity.scss +18 -0
- package/progress/spinner/_mixins.spinner.scss +30 -0
- package/progress/spinner/_properties.spinner.scss +37 -0
- package/progress/spinner/_spinner.clarity.scss +148 -0
- package/progress/spinner/_variables.spinner.scss +25 -0
- package/stepper/_properties.stepper.scss +29 -0
- package/stepper/_stepper.clarity.scss +184 -0
- package/stepper/_variables.stepper.scss +13 -0
- package/styles/_a11y.scss +14 -0
- package/styles/_close.clarity.scss +60 -0
- package/styles/_components.clarity.scss +183 -0
- package/styles/_mixins.scss +478 -0
- package/styles/_normalize.scss +292 -0
- package/styles/_reboot.clarity.scss +374 -0
- package/styles/_variables.clarity.scss +139 -0
- package/styles/core/base/base.element.scss +97 -0
- package/styles/core/global.scss +12 -0
- package/styles/core/layout/_alignments.scss +18 -0
- package/styles/core/layout/_container.scss +29 -0
- package/styles/core/layout/_display.scss +58 -0
- package/styles/core/layout/_optimize.scss +60 -0
- package/styles/core/layout/_shadow-dom.scss +47 -0
- package/styles/core/layout/_spacing.scss +31 -0
- package/styles/core/layout/_type-grid.scss +66 -0
- package/styles/core/layout/_type-horizontal.scss +33 -0
- package/styles/core/layout/_type-vertical.scss +26 -0
- package/styles/core/layout/mixins/_mixins.alignment.scss +35 -0
- package/styles/core/layout/mixins/_mixins.display.scss +23 -0
- package/styles/core/layout/mixins/_mixins.grid.scss +105 -0
- package/styles/core/layout/mixins/_mixins.scss +106 -0
- package/styles/core/layout/mixins/_mixins.shadow-dom.scss +106 -0
- package/styles/core/layout/mixins/_mixins.type-horizontal.scss +113 -0
- package/styles/core/layout/mixins/_mixins.type-vertical.scss +108 -0
- package/styles/core/module.layout.scss +22 -0
- package/styles/core/module.reset.scss +48 -0
- package/styles/core/module.typography.scss +9 -0
- package/styles/core/theme.dark.scss +266 -0
- package/styles/core/theme.high-contrast.scss +42 -0
- package/styles/core/theme.low-motion.scss +20 -0
- package/styles/core/tokens/_alias-interaction.scss +59 -0
- package/styles/core/tokens/_alias-object-background.scss +14 -0
- package/styles/core/tokens/_alias-object-border.scss +21 -0
- package/styles/core/tokens/_alias-object-container.scss +20 -0
- package/styles/core/tokens/_alias-object-opacity.scss +15 -0
- package/styles/core/tokens/_alias-object-shadow.scss +17 -0
- package/styles/core/tokens/_alias-status.scss +34 -0
- package/styles/core/tokens/_alias-typography.scss +101 -0
- package/styles/core/tokens/_alias-utility.scss +38 -0
- package/styles/core/tokens/_alias-viz-colors.scss +170 -0
- package/styles/core/tokens/_global-animation.scss +32 -0
- package/styles/core/tokens/_global-colors.scss +249 -0
- package/styles/core/tokens/_global-space.scss +52 -0
- package/styles/core/tokens/_internal-scale.scss +14 -0
- package/styles/core/tokens/_properties.tokens.scss +21 -0
- package/styles/core/tokens/_variables.tokens.scss +770 -0
- package/styles/core/typography/_legacy-typography.scss +328 -0
- package/styles/core/typography/_mixins.typography.scss +18 -0
- package/styles/core/typography/_typography.scss +321 -0
- package/styles/variables/_properties.density.scss +223 -0
- package/styles/variables/_properties.global.scss +51 -0
- package/styles/variables/_properties.layout.scss +21 -0
- package/styles/variables/_properties.scss +11 -0
- package/styles/variables/_properties.typography.scss +164 -0
- package/styles/variables/_variables.density.scss +114 -0
- package/styles/variables/_variables.global.scss +82 -0
- package/styles/variables/_variables.layout.scss +37 -0
- package/styles/variables/_variables.scss +11 -0
- package/styles/variables/_variables.typography.scss +156 -0
- package/timeline/_properties.timeline.scss +38 -0
- package/timeline/_timeline.clarity.scss +172 -0
- package/timeline/_variables.timeline.scss +29 -0
- package/typography/_code.scss +36 -0
- package/typography/_font-metropolis.scss +45 -0
- package/typography/_lists.scss +81 -0
- package/typography/_typography.scss +322 -0
- package/utils/animations/_animations.clarity.scss +44 -0
- package/utils/animations/_mixins.animations.scss +33 -0
- package/wizard/_properties.wizard.scss +53 -0
- package/wizard/_variables.wizard.scss +58 -0
- package/wizard/_wizard.clarity.scss +688 -0
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2016-2026 Broadcom. All Rights Reserved.
|
|
3
|
+
* The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries.
|
|
4
|
+
* This software is released under MIT license.
|
|
5
|
+
* The full license information can be found in LICENSE in the root directory of this project.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
// Clarity Internal Dependencies
|
|
9
|
+
|
|
10
|
+
@forward '../styles/normalize'; // TODO: upgrade to latest normalize, once updated clr-ui can import core as is.
|
|
11
|
+
@forward '../styles/mixins';
|
|
12
|
+
@forward '../styles/variables/variables';
|
|
13
|
+
@forward '../styles/variables/properties';
|
|
14
|
+
@forward '../styles/core/global.scss';
|
|
15
|
+
|
|
16
|
+
// Layout/Grid
|
|
17
|
+
|
|
18
|
+
@forward '../layout/grid/grid';
|
|
19
|
+
@forward '../typography/typography';
|
|
20
|
+
|
|
21
|
+
// Component variables
|
|
22
|
+
|
|
23
|
+
@forward '../styles/variables.clarity';
|
|
24
|
+
|
|
25
|
+
//Reboot
|
|
26
|
+
|
|
27
|
+
@forward '../styles/reboot.clarity'; // depends on variables.clarity, mixins.clarity, color.clarity, helpers.clarity
|
|
28
|
+
@forward '../styles/a11y';
|
|
29
|
+
|
|
30
|
+
//Icons & Images
|
|
31
|
+
|
|
32
|
+
@forward '../image/icons.clarity'; // depends on variables.clarity
|
|
33
|
+
@forward '../image/images.clarity'; // depends on variables.clarity, mixins.clarity, icons.clarity
|
|
34
|
+
|
|
35
|
+
//Popover
|
|
36
|
+
|
|
37
|
+
@forward '../popover/common/popover.clarity';
|
|
38
|
+
|
|
39
|
+
//Buttons
|
|
40
|
+
|
|
41
|
+
@forward '../button/buttons.clarity'; // depends on variables.clarity, mixins.clarity, color.clarity
|
|
42
|
+
@forward '../button/button-group/button-group.clarity'; // depends on variables.clarity, mixins.clarity
|
|
43
|
+
@forward '../styles/close.clarity'; //depends on variables.clarity, mixins.clarity
|
|
44
|
+
|
|
45
|
+
//Alerts
|
|
46
|
+
//depends on variables.clarity, mixins.clarity, color.clarity, icons.clarity, buttons.clarity
|
|
47
|
+
|
|
48
|
+
@forward '../emphasis/alert/alert.clarity';
|
|
49
|
+
|
|
50
|
+
//Cards
|
|
51
|
+
//depends on variables.clarity, mixins.clarity, color.clarity, helpers.clarity, list-group.clarity, buttons.clarity
|
|
52
|
+
|
|
53
|
+
@forward '../layout/card.clarity';
|
|
54
|
+
|
|
55
|
+
//Dropdowns
|
|
56
|
+
//depends on variables.clarity, mixins.clarity, color.clarity, helpers.clarity, layers.clarity
|
|
57
|
+
|
|
58
|
+
@forward '../popover/dropdown/dropdown.clarity';
|
|
59
|
+
|
|
60
|
+
//Login
|
|
61
|
+
//depends on variables.clarity, mixins.clarity, helpers.clarity, color.clarity, icons.clarity
|
|
62
|
+
|
|
63
|
+
@forward '../layout/login.clarity';
|
|
64
|
+
|
|
65
|
+
//Layout
|
|
66
|
+
//depends on variables.clarity, mixins.clarity, helpers.clarity, color.clarity, layers.clarity
|
|
67
|
+
|
|
68
|
+
@forward '../layout/main-container/layout.clarity';
|
|
69
|
+
|
|
70
|
+
//Modal
|
|
71
|
+
//depends on variables.clarity, mixins.clarity, helpers.clarity, color.clarity, layers.clarity
|
|
72
|
+
|
|
73
|
+
@forward '../modal/modal.clarity';
|
|
74
|
+
|
|
75
|
+
//Nav
|
|
76
|
+
|
|
77
|
+
@forward '../layout/nav/header.clarity'; // depends on variables.clarity, mixins.clarity, helpers.clarity, color.clarity, layers.clarity
|
|
78
|
+
@forward '../layout/nav/links.clarity'; // depends on variables.clarity, mixins.clarity, helpers.clarity, color.clarity
|
|
79
|
+
@forward '../layout/nav/nav.clarity'; // depends on variables.clarity, mixins.clarity, helpers.clarity, color.clarity, layers.clarity
|
|
80
|
+
@forward '../layout/nav/subnav.clarity'; // depends on variables.clarity, mixins.clarity, helpers.clarity, color.clarity, layers.clarity
|
|
81
|
+
@forward '../layout/vertical-nav/vertical-nav.clarity'; // depends on variables.clarity, mixins.clarity, helpers.clarity, color.clarity
|
|
82
|
+
@forward '../layout/nav/responsive-nav.clarity'; // depends on variables.clarity, mixins.clarity, helpers.clarity, color.clarity, layers.clarity
|
|
83
|
+
|
|
84
|
+
//Badges
|
|
85
|
+
// depends on variables.clarity, mixins.clarity, color.clarity, helpers.clarity, typography.clarity
|
|
86
|
+
|
|
87
|
+
@forward '../emphasis/badge/badges.clarity';
|
|
88
|
+
|
|
89
|
+
//Labels
|
|
90
|
+
// depends on variables.clarity, mixins.clarity, color.clarity, helpers.clarity, typography.clarity, badges.clarity
|
|
91
|
+
|
|
92
|
+
@forward '../emphasis/label/labels.clarity';
|
|
93
|
+
|
|
94
|
+
//Progress Bars
|
|
95
|
+
//depends on variables.clarity, helpers.clarity, color.clarity, cards.clarity
|
|
96
|
+
|
|
97
|
+
@forward '../progress/progress-bars/progress-bars.clarity';
|
|
98
|
+
|
|
99
|
+
//Spinners
|
|
100
|
+
//depends on variables.clarity, mixins.clarity, color.clarity, helpers.clarity, icons.clarity
|
|
101
|
+
|
|
102
|
+
@forward '../progress/spinner/spinner.clarity';
|
|
103
|
+
|
|
104
|
+
//Tables
|
|
105
|
+
//depends on variables.clarity, mixins.clarity, helpers.clarity, typography.clarity
|
|
106
|
+
|
|
107
|
+
@forward '../data/tables.clarity';
|
|
108
|
+
|
|
109
|
+
//Tooltips
|
|
110
|
+
// depends on variables.clarity, mixins.clarity, color.clarity, helpers.clarity, layers.clarity
|
|
111
|
+
|
|
112
|
+
@forward '../popover/tooltip/tooltips.clarity';
|
|
113
|
+
|
|
114
|
+
//Forms
|
|
115
|
+
|
|
116
|
+
@forward '../forms/styles/mixins.forms';
|
|
117
|
+
@forward '../forms/styles/properties.forms';
|
|
118
|
+
@forward '../forms/styles/containers.clarity';
|
|
119
|
+
@forward '../forms/styles/form.clarity';
|
|
120
|
+
@forward '../forms/styles/checkbox.clarity';
|
|
121
|
+
@forward '../forms/styles/file.clarity';
|
|
122
|
+
@forward '../forms/styles/file-input.clarity';
|
|
123
|
+
@forward '../forms/styles/input.clarity';
|
|
124
|
+
@forward '../forms/styles/input-group.clarity';
|
|
125
|
+
@forward '../forms/styles/radio.clarity';
|
|
126
|
+
@forward '../forms/styles/select.clarity';
|
|
127
|
+
@forward '../forms/styles/textarea.clarity';
|
|
128
|
+
@forward '../forms/styles/toggles.clarity'; // depends on variables.clarity, mixins.clarity, color.clarity, helpers.clarity
|
|
129
|
+
@forward '../forms/styles/range.clarity';
|
|
130
|
+
@forward '../forms/styles/datalist.clarity';
|
|
131
|
+
@forward '../forms/styles/password.clarity';
|
|
132
|
+
@forward '../forms/styles/number-input.clarity';
|
|
133
|
+
@forward '../forms/datepicker/datepicker.clarity';
|
|
134
|
+
@forward '../forms/combobox/combobox.clarity';
|
|
135
|
+
|
|
136
|
+
//Stack View
|
|
137
|
+
//depends on variables.clarity, mixins.clarity, color.clarity, helpers.clarity, forms.clarity
|
|
138
|
+
|
|
139
|
+
@forward '../data/stack-view/stack-view.clarity';
|
|
140
|
+
|
|
141
|
+
//Tree View
|
|
142
|
+
//depends on variables.clarity, mixins.clarity, helpers.clarity, forms.clarity
|
|
143
|
+
|
|
144
|
+
@forward '../data/tree-view/tree-view.clarity';
|
|
145
|
+
|
|
146
|
+
//Datagrid
|
|
147
|
+
//depends on variables.clarity, mixins.clarity, helpers.clarity, layers, icons.clarity, tables.clarity, forms.clarity
|
|
148
|
+
|
|
149
|
+
@forward '../data/datagrid/datagrid.clarity';
|
|
150
|
+
|
|
151
|
+
//Animations
|
|
152
|
+
// no dependencies on other clarity scss
|
|
153
|
+
|
|
154
|
+
@forward '../utils/animations/animations.clarity';
|
|
155
|
+
|
|
156
|
+
//Tabs
|
|
157
|
+
|
|
158
|
+
@forward '../layout/tabs/tabs.clarity'; // no dependencies on other clarity scss
|
|
159
|
+
|
|
160
|
+
//Wizards
|
|
161
|
+
// depends on variables.clarity, mixins.clarity, helpers.clarity, color.clarity, layers.clarity
|
|
162
|
+
|
|
163
|
+
@forward '../wizard/wizard.clarity';
|
|
164
|
+
|
|
165
|
+
// Signposts
|
|
166
|
+
|
|
167
|
+
@forward '../popover/signpost/signposts.clarity';
|
|
168
|
+
|
|
169
|
+
// Accordion
|
|
170
|
+
|
|
171
|
+
@forward '../accordion/accordion.clarity';
|
|
172
|
+
|
|
173
|
+
// Stepper
|
|
174
|
+
|
|
175
|
+
@forward '../stepper/stepper.clarity';
|
|
176
|
+
|
|
177
|
+
// Timeline
|
|
178
|
+
|
|
179
|
+
@forward '../timeline/timeline.clarity';
|
|
180
|
+
|
|
181
|
+
// Breadcrumbs
|
|
182
|
+
|
|
183
|
+
@forward '../layout/breadcrumbs/breadcrumbs.clarity';
|
|
@@ -0,0 +1,478 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2016-2026 Broadcom. All Rights Reserved.
|
|
3
|
+
* The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries.
|
|
4
|
+
* This software is released under MIT license.
|
|
5
|
+
* The full license information can be found in LICENSE in the root directory of this project.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
@use 'sass:list';
|
|
9
|
+
@use 'sass:map';
|
|
10
|
+
@use 'sass:selector';
|
|
11
|
+
@use 'variables/variables';
|
|
12
|
+
|
|
13
|
+
//Credit: Zurb Foundation for Apps https://github.com/zurb/foundation-apps/blob/master/scss/helpers/_functions.scss
|
|
14
|
+
//Keep track of modules that have been imported, so we don't import more than once
|
|
15
|
+
$imported-modules: () !default;
|
|
16
|
+
|
|
17
|
+
@mixin exports($name) {
|
|
18
|
+
//check if they have been imported
|
|
19
|
+
|
|
20
|
+
@if (not list.index($imported-modules, $name)) {
|
|
21
|
+
$imported-modules: list.append($imported-modules, $name) !global;
|
|
22
|
+
@content;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
@mixin include-outline-style-form-fields($offset: var(--cds-alias-object-interaction-outline-offset)) {
|
|
26
|
+
outline: var(--cds-alias-object-interaction-outline);
|
|
27
|
+
outline-color: -webkit-focus-ring-color;
|
|
28
|
+
outline-offset: $offset;
|
|
29
|
+
}
|
|
30
|
+
@mixin include-slim-outline-style-form-fields($width: var(--cds-global-space-2)) {
|
|
31
|
+
outline-color: Highlight;
|
|
32
|
+
outline-color: -webkit-focus-ring-color;
|
|
33
|
+
outline-style: auto;
|
|
34
|
+
outline-width: $width;
|
|
35
|
+
}
|
|
36
|
+
@mixin overflow-ellipsis($leftAlignment: false) {
|
|
37
|
+
white-space: nowrap;
|
|
38
|
+
overflow: hidden;
|
|
39
|
+
text-overflow: ellipsis;
|
|
40
|
+
|
|
41
|
+
@if $leftAlignment == true {
|
|
42
|
+
text-align: left;
|
|
43
|
+
justify-content: start;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
@mixin off-screen-styles() {
|
|
47
|
+
position: fixed !important;
|
|
48
|
+
border: none !important;
|
|
49
|
+
height: 1px !important;
|
|
50
|
+
width: 1px !important;
|
|
51
|
+
left: 0 !important;
|
|
52
|
+
top: calc(-1 * var(--cds-global-space-1)) !important;
|
|
53
|
+
overflow: hidden !important;
|
|
54
|
+
visibility: hidden !important;
|
|
55
|
+
padding: 0 !important;
|
|
56
|
+
margin: 0 0 calc(-1 * var(--cds-global-space-1)) !important;
|
|
57
|
+
}
|
|
58
|
+
@mixin focus-within() {
|
|
59
|
+
&:focus-within,
|
|
60
|
+
&.focus-within {
|
|
61
|
+
outline: var(--cds-global-space-2) solid Highlight;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
@media (-min-device-pixel-ratio: 0) {
|
|
65
|
+
&:focus-within,
|
|
66
|
+
&.focus-within {
|
|
67
|
+
outline: baselinePx(5) auto -webkit-focus-ring-color;
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
@mixin equilateral($size: 1.2rem) {
|
|
72
|
+
height: $size;
|
|
73
|
+
width: $size;
|
|
74
|
+
}
|
|
75
|
+
@mixin min-equilateral($size: 1.2rem) {
|
|
76
|
+
@include equilateral($size);
|
|
77
|
+
|
|
78
|
+
min-height: $size;
|
|
79
|
+
min-width: $size;
|
|
80
|
+
}
|
|
81
|
+
@mixin max-equilateral($size: 1.2rem) {
|
|
82
|
+
@include equilateral($size);
|
|
83
|
+
|
|
84
|
+
max-height: $size;
|
|
85
|
+
max-width: $size;
|
|
86
|
+
}
|
|
87
|
+
@mixin clr-appearance-normal() {
|
|
88
|
+
appearance: none;
|
|
89
|
+
background: none;
|
|
90
|
+
}
|
|
91
|
+
@mixin clr-no-styles-button {
|
|
92
|
+
@include clr-appearance-normal();
|
|
93
|
+
|
|
94
|
+
margin: 0;
|
|
95
|
+
padding: 0;
|
|
96
|
+
border: none;
|
|
97
|
+
border-radius: 0;
|
|
98
|
+
box-shadow: none;
|
|
99
|
+
background: none;
|
|
100
|
+
|
|
101
|
+
@at-root button#{&} {
|
|
102
|
+
cursor: pointer;
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
//Dropdowns & Tooltips
|
|
107
|
+
$opp-directions: (
|
|
108
|
+
top: bottom,
|
|
109
|
+
bottom: top,
|
|
110
|
+
left: right,
|
|
111
|
+
right: left,
|
|
112
|
+
);
|
|
113
|
+
|
|
114
|
+
@mixin clr-container() {
|
|
115
|
+
& > :first-child {
|
|
116
|
+
margin-top: 0;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
& > :last-child {
|
|
120
|
+
margin-bottom: 0;
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
// Moves styles outside of any parent selector conditionally,
|
|
124
|
+
// while allowing an additional selector to be appended.
|
|
125
|
+
|
|
126
|
+
@mixin optional-at-root($selector) {
|
|
127
|
+
// Check if parent selector exists
|
|
128
|
+
|
|
129
|
+
@if & {
|
|
130
|
+
// Append the additional selector to the parent selector
|
|
131
|
+
|
|
132
|
+
@at-root #{selector.append(&, $selector)} {
|
|
133
|
+
@content;
|
|
134
|
+
}
|
|
135
|
+
} @else {
|
|
136
|
+
// Use the parent selector with the additional selector
|
|
137
|
+
|
|
138
|
+
@at-root #{$selector} {
|
|
139
|
+
@content;
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
// Declaring CSS in :root or :host depending which is available
|
|
145
|
+
// Enabling tokens to work under Global DOM or Shadow DOM
|
|
146
|
+
@mixin root-or-host() {
|
|
147
|
+
:where(:root, :host) {
|
|
148
|
+
@content;
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
@mixin input-placeholder-wrapper() {
|
|
152
|
+
@include optional-at-root('::-webkit-input-placeholder') {
|
|
153
|
+
@content;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
@include optional-at-root('::placeholder') {
|
|
157
|
+
@content;
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
@function baselinePx($pixels: 0) {
|
|
162
|
+
@return calc($pixels * (1rem / var(--cds-global-base)));
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
$typography-tokens: (
|
|
166
|
+
'DISPLAY-40': (
|
|
167
|
+
// H1, Login Header
|
|
168
|
+
font-size: #{variables.$clr-base-typography-font-size-display},
|
|
169
|
+
font-weight: var(--cds-alias-typography-display-font-weight),
|
|
170
|
+
line-height: #{variables.$clr-base-typography-line-height-44},
|
|
171
|
+
letter-spacing: #{baselinePx(-0.5)},
|
|
172
|
+
),
|
|
173
|
+
'HEADLINE-32': (
|
|
174
|
+
// H2, Page Header
|
|
175
|
+
font-size: #{variables.$clr-base-typography-font-size-headline},
|
|
176
|
+
font-weight: var(--cds-alias-typography-headline-font-weight),
|
|
177
|
+
line-height: #{variables.$clr-base-typography-line-height-36},
|
|
178
|
+
letter-spacing: #{baselinePx(-0.4)},
|
|
179
|
+
),
|
|
180
|
+
'TITLE-24-EXP': (
|
|
181
|
+
// H3, Modal, Wizard Heading
|
|
182
|
+
font-size: #{variables.$clr-base-typography-font-size-heading},
|
|
183
|
+
font-weight: var(--cds-alias-typography-title-font-weight),
|
|
184
|
+
line-height: #{variables.$clr-base-typography-line-height-32},
|
|
185
|
+
letter-spacing: #{baselinePx(-0.2)},
|
|
186
|
+
),
|
|
187
|
+
'SECTION-20-STD': (
|
|
188
|
+
// H4, Card, Signpost Heading, Wizard Sidenav Title
|
|
189
|
+
font-size: #{variables.$clr-base-typography-font-size-section},
|
|
190
|
+
font-weight: var(--cds-alias-typography-section-font-weight),
|
|
191
|
+
line-height: #{variables.$clr-base-typography-line-height-24},
|
|
192
|
+
letter-spacing: #{baselinePx(-0.2)},
|
|
193
|
+
),
|
|
194
|
+
'SECTION-12-SB-CPT': (
|
|
195
|
+
font-size: #{variables.$clr-base-typography-font-size-button},
|
|
196
|
+
font-weight: var(--cds-alias-typography-font-weight-semibold),
|
|
197
|
+
line-height: #{variables.$clr-base-typography-line-height-16},
|
|
198
|
+
letter-spacing: #{baselinePx(-0.2)},
|
|
199
|
+
),
|
|
200
|
+
'SUBSECTION-16-EXP': (
|
|
201
|
+
// H5, Stack View Heading
|
|
202
|
+
font-size: #{variables.$clr-base-typography-font-size-sub-section},
|
|
203
|
+
font-weight: var(--cds-alias-typography-subsection-font-weight),
|
|
204
|
+
line-height: #{variables.$clr-base-typography-line-height-24},
|
|
205
|
+
letter-spacing: #{baselinePx(-0.2)},
|
|
206
|
+
),
|
|
207
|
+
'SUBSECTION-16-SB': (
|
|
208
|
+
font-size: #{variables.$clr-base-typography-font-size-sub-section},
|
|
209
|
+
font-weight: var(--cds-alias-typography-font-weight-semibold),
|
|
210
|
+
line-height: #{variables.$clr-base-typography-line-height-24},
|
|
211
|
+
letter-spacing: #{baselinePx(-0.2)},
|
|
212
|
+
),
|
|
213
|
+
'MESSAGE-16-EXP': (
|
|
214
|
+
// H6, Heading
|
|
215
|
+
font-size: #{variables.$clr-base-typography-font-size-sub-section},
|
|
216
|
+
font-weight: var(--cds-alias-typography-message-font-weight),
|
|
217
|
+
line-height: #{variables.$clr-base-typography-line-height-24},
|
|
218
|
+
letter-spacing: #{baselinePx(-0.2)},
|
|
219
|
+
),
|
|
220
|
+
'BODY-14-SB-STD': (
|
|
221
|
+
// Not used yet
|
|
222
|
+
font-size: #{variables.$clr-base-typography-font-size-default},
|
|
223
|
+
font-weight: var(--cds-alias-typography-font-weight-semibold),
|
|
224
|
+
line-height: #{variables.$clr-base-typography-line-height-20},
|
|
225
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
226
|
+
),
|
|
227
|
+
'BODY-14-MD-STD': (
|
|
228
|
+
// Wizard sidenav link
|
|
229
|
+
font-size: #{variables.$clr-base-typography-font-size-default},
|
|
230
|
+
font-weight: var(--cds-alias-typography-font-weight-medium),
|
|
231
|
+
line-height: #{variables.$clr-base-typography-line-height-20},
|
|
232
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
233
|
+
),
|
|
234
|
+
'BODY-14-RG-STD': (
|
|
235
|
+
// P0, P1, Body text
|
|
236
|
+
font-size: #{variables.$clr-base-typography-font-size-default},
|
|
237
|
+
font-weight: var(--cds-alias-typography-body-font-weight),
|
|
238
|
+
line-height: #{variables.$clr-base-typography-line-height-20},
|
|
239
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
240
|
+
),
|
|
241
|
+
'BODY-14-RG-CPT': (
|
|
242
|
+
font-size: #{variables.$clr-base-typography-font-size-default},
|
|
243
|
+
font-weight: var(--cds-alias-typography-body-font-weight),
|
|
244
|
+
line-height: #{variables.$clr-base-typography-line-height-16},
|
|
245
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
246
|
+
),
|
|
247
|
+
'BODY-14-RG-EXP': (
|
|
248
|
+
font-size: #{variables.$clr-base-typography-font-size-default},
|
|
249
|
+
font-weight: var(--cds-alias-typography-body-font-weight),
|
|
250
|
+
line-height: #{variables.$clr-base-typography-line-height-24},
|
|
251
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
252
|
+
),
|
|
253
|
+
'BODY-14-SB-EXP': (
|
|
254
|
+
font-size: #{variables.$clr-base-typography-font-size-default},
|
|
255
|
+
font-weight: var(--cds-alias-typography-font-weight-semibold),
|
|
256
|
+
line-height: #{variables.$clr-base-typography-line-height-24},
|
|
257
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
258
|
+
),
|
|
259
|
+
'SECONDARY-14-RG-CPT': (
|
|
260
|
+
font-size: #{variables.$clr-base-typography-font-size-default},
|
|
261
|
+
font-weight: var(--cds-alias-typography-secondary-font-weight),
|
|
262
|
+
line-height: #{variables.$clr-base-typography-line-height-16},
|
|
263
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
264
|
+
),
|
|
265
|
+
'SECONDARY-13-MD-EXP': (
|
|
266
|
+
// P2, Section Header
|
|
267
|
+
font-size: #{variables.$clr-base-typography-font-size-inline},
|
|
268
|
+
font-weight: var(--cds-alias-typography-font-weight-medium),
|
|
269
|
+
line-height: #{variables.$clr-base-typography-line-height-24},
|
|
270
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
271
|
+
),
|
|
272
|
+
'SECONDARY-13-RG-CPT': (
|
|
273
|
+
// Checkbox and radio labels, Spinner
|
|
274
|
+
font-size: #{variables.$clr-base-typography-font-size-inline},
|
|
275
|
+
font-weight: var(--cds-alias-typography-secondary-font-weight),
|
|
276
|
+
line-height: #{variables.$clr-base-typography-line-height-16},
|
|
277
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
278
|
+
),
|
|
279
|
+
'SECONDARY-13-RG-EXP': (
|
|
280
|
+
// P3, Form Labels and Column Headers
|
|
281
|
+
// P5, Table footer and chart data
|
|
282
|
+
font-size: #{variables.$clr-base-typography-font-size-inline},
|
|
283
|
+
font-weight: var(--cds-alias-typography-secondary-font-weight),
|
|
284
|
+
line-height: #{variables.$clr-base-typography-line-height-24},
|
|
285
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
286
|
+
),
|
|
287
|
+
'SECONDARY-13-RG-STD': (
|
|
288
|
+
font-size: #{variables.$clr-base-typography-font-size-inline},
|
|
289
|
+
font-weight: var(--cds-alias-typography-secondary-font-weight),
|
|
290
|
+
line-height: #{variables.$clr-base-typography-line-height-20},
|
|
291
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
292
|
+
),
|
|
293
|
+
'SECONDARY-13-SB-STD': (
|
|
294
|
+
// P4, Form Labels and Column Headers
|
|
295
|
+
font-size: #{variables.$clr-base-typography-font-size-inline},
|
|
296
|
+
font-weight: var(--cds-alias-typography-font-weight-semibold),
|
|
297
|
+
line-height: #{variables.$clr-base-typography-line-height-20},
|
|
298
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
299
|
+
),
|
|
300
|
+
'SECONDARY-13-MD-CPT': (
|
|
301
|
+
font-size: #{variables.$clr-base-typography-font-size-inline},
|
|
302
|
+
font-weight: var(--cds-alias-typography-font-weight-medium),
|
|
303
|
+
line-height: #{variables.$clr-base-typography-line-height-16},
|
|
304
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
305
|
+
),
|
|
306
|
+
'SECONDARY-13-SB-CPT': (
|
|
307
|
+
font-size: #{variables.$clr-base-typography-font-size-inline},
|
|
308
|
+
font-weight: var(--cds-alias-typography-font-weight-semibold),
|
|
309
|
+
line-height: #{variables.$clr-base-typography-line-height-16},
|
|
310
|
+
letter-spacing: #{baselinePx(-0.1)},
|
|
311
|
+
),
|
|
312
|
+
'CAPTION-LG-11-STD': (
|
|
313
|
+
// P6, Small Headers
|
|
314
|
+
font-size: #{variables.$clr-base-typography-font-size-caption},
|
|
315
|
+
font-weight: var(--cds-alias-typography-caption-font-weight),
|
|
316
|
+
line-height: #{variables.$clr-base-typography-line-height-16},
|
|
317
|
+
letter-spacing: #{baselinePx(0.2)},
|
|
318
|
+
),
|
|
319
|
+
'CAPTION-LG-11-CPT': (
|
|
320
|
+
// Badges, Tag and Labels
|
|
321
|
+
font-size: #{variables.$clr-base-typography-font-size-caption},
|
|
322
|
+
font-weight: var(--cds-alias-typography-caption-font-weight),
|
|
323
|
+
line-height: #{variables.$clr-base-typography-line-height-12},
|
|
324
|
+
letter-spacing: #{baselinePx(0.2)},
|
|
325
|
+
),
|
|
326
|
+
'ColumnHeader-11-SB-CPT': (
|
|
327
|
+
font-size: #{variables.$clr-base-typography-font-size-caption},
|
|
328
|
+
font-weight: var(--cds-alias-typography-font-weight-semibold),
|
|
329
|
+
line-height: #{variables.$clr-base-typography-line-height-16},
|
|
330
|
+
letter-spacing: #{baselinePx(0.2)},
|
|
331
|
+
),
|
|
332
|
+
'CAPTION-SM-10': (
|
|
333
|
+
// P7, P8
|
|
334
|
+
font-size: #{variables.$clr-base-typography-font-size-caption-small},
|
|
335
|
+
font-weight: var(--cds-alias-typography-smallcaption-font-weight),
|
|
336
|
+
line-height: #{variables.$clr-base-typography-line-height-12},
|
|
337
|
+
letter-spacing: #{baselinePx(0.5)},
|
|
338
|
+
),
|
|
339
|
+
'BUTTON-12': (
|
|
340
|
+
// Buttons
|
|
341
|
+
font-size: #{variables.$clr-base-typography-font-size-button},
|
|
342
|
+
font-weight: var(--cds-alias-typography-font-weight-semibold),
|
|
343
|
+
line-height: #{variables.$clr-base-typography-line-height-16},
|
|
344
|
+
letter-spacing: var(--cds-global-space-1),
|
|
345
|
+
text-transform: uppercase,
|
|
346
|
+
),
|
|
347
|
+
'BUTTON-11-SMALL': (
|
|
348
|
+
// Small Buttons
|
|
349
|
+
font-size: #{variables.$clr-base-typography-font-size-caption},
|
|
350
|
+
font-weight: var(--cds-alias-typography-font-weight-semibold),
|
|
351
|
+
line-height: #{variables.$clr-base-typography-line-height-16},
|
|
352
|
+
letter-spacing: #{baselinePx(0.2)},
|
|
353
|
+
text-transform: uppercase,
|
|
354
|
+
),
|
|
355
|
+
);
|
|
356
|
+
|
|
357
|
+
@mixin setValue($key, $map: (), $value) {
|
|
358
|
+
@if (map.has-key($map, $key)) {
|
|
359
|
+
#{$key}: map.get($map, $key);
|
|
360
|
+
} @else {
|
|
361
|
+
#{$key}: $value;
|
|
362
|
+
}
|
|
363
|
+
}
|
|
364
|
+
@mixin generate-typography-header-token($name, $fallbacks: (), $addFontFamily: true, $addColor: true) {
|
|
365
|
+
@if ($addFontFamily) {
|
|
366
|
+
@include setValue(
|
|
367
|
+
font-family,
|
|
368
|
+
$fallbacks,
|
|
369
|
+
variables.$clr-font
|
|
370
|
+
); // tokens.$cds-alias-typography-header-font-family);
|
|
371
|
+
}
|
|
372
|
+
@if ($addColor) {
|
|
373
|
+
@include setValue(color, $fallbacks, var(--cds-alias-typography-color-300));
|
|
374
|
+
}
|
|
375
|
+
|
|
376
|
+
@include generate-typography-token($name, $fallbacks);
|
|
377
|
+
}
|
|
378
|
+
@mixin generate-typography-body-token($name, $fallbacks: (), $addFontFamily: true, $addColor: true) {
|
|
379
|
+
@if ($addFontFamily) {
|
|
380
|
+
@include setValue(font-family, $fallbacks, variables.$clr-font); // tokens.$cds-alias-typography-font-family);
|
|
381
|
+
}
|
|
382
|
+
@if ($addColor) {
|
|
383
|
+
@include setValue(color, $fallbacks, var(--cds-alias-typography-color-450));
|
|
384
|
+
}
|
|
385
|
+
|
|
386
|
+
@include generate-typography-token($name, $fallbacks);
|
|
387
|
+
}
|
|
388
|
+
@mixin generate-typography-token($name, $fallbacks: ()) {
|
|
389
|
+
@each $key, $value in map.get($typography-tokens, $name) {
|
|
390
|
+
@include setValue($key, $fallbacks, $value);
|
|
391
|
+
}
|
|
392
|
+
}
|
|
393
|
+
@mixin cell-children-aligment() {
|
|
394
|
+
cds-icon,
|
|
395
|
+
clr-icon {
|
|
396
|
+
margin-top: calc((-1 * var(--cds-global-space-3)) - var(--cds-global-space-1));
|
|
397
|
+
margin-bottom: calc(-1 * var(--cds-global-space-3));
|
|
398
|
+
}
|
|
399
|
+
|
|
400
|
+
.badge {
|
|
401
|
+
margin-top: calc(-1 * var(--cds-global-space-3));
|
|
402
|
+
margin-bottom: calc(-1 * var(--cds-global-space-1));
|
|
403
|
+
}
|
|
404
|
+
}
|
|
405
|
+
|
|
406
|
+
// a11y
|
|
407
|
+
@mixin screen-reader-only() {
|
|
408
|
+
position: absolute;
|
|
409
|
+
clip-path: inset(50%);
|
|
410
|
+
padding: 0;
|
|
411
|
+
border: 0;
|
|
412
|
+
height: 1px;
|
|
413
|
+
width: 1px;
|
|
414
|
+
overflow: hidden;
|
|
415
|
+
white-space: nowrap;
|
|
416
|
+
top: 0;
|
|
417
|
+
left: 0;
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
// default are for metropolis/clarity-city
|
|
421
|
+
@mixin line-height-eraser(
|
|
422
|
+
$line-height-gap-em: 0.6em,
|
|
423
|
+
$font-top-gap-em: 0.1475em,
|
|
424
|
+
$font-ascender-height-em: 0.1703em,
|
|
425
|
+
$font-x-height-em: 0.517em,
|
|
426
|
+
$pull-nudge: 0.037em,
|
|
427
|
+
$push-nudge: 0.044em
|
|
428
|
+
) {
|
|
429
|
+
&::before {
|
|
430
|
+
content: '';
|
|
431
|
+
display: block;
|
|
432
|
+
height: 0;
|
|
433
|
+
width: 0;
|
|
434
|
+
margin-bottom: pullUp($line-height-gap-em, $font-top-gap-em, $pull-nudge);
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
&::after {
|
|
438
|
+
content: '';
|
|
439
|
+
display: block;
|
|
440
|
+
height: 0;
|
|
441
|
+
width: 0;
|
|
442
|
+
margin-top: pushDown(
|
|
443
|
+
$line-height-gap-em,
|
|
444
|
+
$font-top-gap-em,
|
|
445
|
+
$font-ascender-height-em,
|
|
446
|
+
$font-x-height-em,
|
|
447
|
+
$push-nudge
|
|
448
|
+
);
|
|
449
|
+
}
|
|
450
|
+
}
|
|
451
|
+
@mixin remove-line-height-erasers() {
|
|
452
|
+
&::before,
|
|
453
|
+
&::after {
|
|
454
|
+
content: none;
|
|
455
|
+
}
|
|
456
|
+
}
|
|
457
|
+
|
|
458
|
+
@function getLineHeightGap($line-height-value: 1.2, $line-height-token: null) {
|
|
459
|
+
@if (not $line-height-token) or ($line-height-value < 1) {
|
|
460
|
+
@return 0;
|
|
461
|
+
}
|
|
462
|
+
@return calc((#{$line-height-token} - 1em) / 2);
|
|
463
|
+
}
|
|
464
|
+
@function pullUp($line-height-gap: 1.2em, $font-top-gap: 0.1475em, $pull-nudge: 0.037em) {
|
|
465
|
+
@return calc(((#{$font-top-gap} + #{$line-height-gap}) * -1) + #{$pull-nudge});
|
|
466
|
+
}
|
|
467
|
+
@function pushDown(
|
|
468
|
+
$line-height-gap: 0.6em,
|
|
469
|
+
$font-top-gap: 0.1475em,
|
|
470
|
+
$font-ascender-height: 0.1703,
|
|
471
|
+
$font-x-height: 0.517,
|
|
472
|
+
$push-nudge: 0.044em
|
|
473
|
+
) {
|
|
474
|
+
@return calc(
|
|
475
|
+
(((1em - #{$font-top-gap} - #{$font-ascender-height} - #{$font-x-height}) + #{$line-height-gap}) * -1) -
|
|
476
|
+
#{$push-nudge}
|
|
477
|
+
);
|
|
478
|
+
}
|