@microsoft/atlas-css 3.43.0 → 3.44.0
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 +42 -42
- package/dist/class-names.json +1 -1
- package/dist/index.css +1 -1
- package/dist/index.css.map +1 -1
- package/package.json +91 -91
- package/src/atomics/README.md +56 -56
- package/src/atomics/aspect-ratio.scss +13 -13
- package/src/atomics/background.scss +11 -11
- package/src/atomics/border.scss +113 -113
- package/src/atomics/colors.scss +204 -204
- package/src/atomics/display.scss +33 -33
- package/src/atomics/flex.scss +74 -71
- package/src/atomics/gap.scss +60 -60
- package/src/atomics/image.scss +15 -15
- package/src/atomics/index.scss +18 -18
- package/src/atomics/line-clamp.scss +15 -15
- package/src/atomics/list.scss +3 -3
- package/src/atomics/overflow.scss +9 -9
- package/src/atomics/position.scss +19 -19
- package/src/atomics/shadow.scss +19 -19
- package/src/atomics/spacing-auto.scss +52 -52
- package/src/atomics/spacing.scss +98 -98
- package/src/atomics/typography.scss +203 -203
- package/src/atomics/visually-hidden.scss +4 -4
- package/src/atomics/width.scss +44 -44
- package/src/components/README.md +69 -69
- package/src/components/banner.scss +69 -69
- package/src/components/breadcrumbs.scss +37 -37
- package/src/components/button-reset.scss +8 -8
- package/src/components/button.scss +241 -241
- package/src/components/buttons.scss +93 -93
- package/src/components/card.scss +252 -252
- package/src/components/form/checkbox.scss +141 -141
- package/src/components/form/form.scss +67 -67
- package/src/components/form/help.scss +18 -18
- package/src/components/form/index.scss +8 -8
- package/src/components/form/input.scss +143 -143
- package/src/components/form/label.scss +14 -14
- package/src/components/form/radio.scss +121 -121
- package/src/components/form/select.scss +116 -116
- package/src/components/form/textarea.scss +82 -82
- package/src/components/gradient-card.scss +14 -14
- package/src/components/gradient.scss +85 -85
- package/src/components/hero.scss +197 -197
- package/src/components/icon.scss +20 -20
- package/src/components/image.scss +44 -44
- package/src/components/index.scss +27 -27
- package/src/components/layout.scss +189 -189
- package/src/components/link-button.scss +34 -34
- package/src/components/markdown.scss +158 -158
- package/src/components/media.scss +22 -22
- package/src/components/message.scss +74 -74
- package/src/components/notification.scss +101 -101
- package/src/components/pagination.scss +183 -183
- package/src/components/persona.scss +60 -60
- package/src/components/popover.scss +42 -42
- package/src/components/scroll.scss +26 -26
- package/src/components/segmented-control.scss +128 -128
- package/src/components/site-header.scss +255 -255
- package/src/components/stretched-link.scss +8 -8
- package/src/components/table.scss +114 -114
- package/src/components/toggle.scss +86 -86
- package/src/core/animations.scss +55 -55
- package/src/core/bare-elements.scss +38 -38
- package/src/core/focus.scss +45 -45
- package/src/core/font-stack.scss +28 -28
- package/src/core/index.scss +7 -7
- package/src/core/minireset.scss +79 -79
- package/src/core/normalize.scss +353 -353
- package/src/core/themes.scss +91 -91
- package/src/index.scss +5 -5
- package/src/mixins/center.scss +11 -11
- package/src/mixins/code-block.scss +43 -43
- package/src/mixins/colors.scss +6 -6
- package/src/mixins/control.scss +43 -43
- package/src/mixins/dismiss.scss +22 -22
- package/src/mixins/focus.scss +23 -23
- package/src/mixins/font-size.scss +35 -35
- package/src/mixins/force-colors.scss +5 -5
- package/src/mixins/gradient.scss +11 -11
- package/src/mixins/index.scss +17 -17
- package/src/mixins/layout-gap.scss +7 -7
- package/src/mixins/line-clamp.scss +15 -15
- package/src/mixins/loader.scss +16 -16
- package/src/mixins/media-queries.scss +61 -61
- package/src/mixins/overlay.scss +12 -12
- package/src/mixins/transparency.scss +15 -15
- package/src/mixins/unselectable.scss +13 -13
- package/src/mixins/visually-hidden.scss +12 -12
- package/src/tokens/animation.scss +8 -8
- package/src/tokens/border.scss +12 -12
- package/src/tokens/breakpoints.scss +11 -11
- package/src/tokens/colors.scss +239 -239
- package/src/tokens/direction.scss +25 -25
- package/src/tokens/display.scss +5 -5
- package/src/tokens/focus.scss +9 -9
- package/src/tokens/font-stack.scss +10 -10
- package/src/tokens/index.scss +17 -17
- package/src/tokens/layout.scss +17 -17
- package/src/tokens/palette.scss +200 -200
- package/src/tokens/position.scss +5 -5
- package/src/tokens/schemes.scss +14 -14
- package/src/tokens/shadow.scss +11 -11
- package/src/tokens/spacing.scss +25 -25
- package/src/tokens/themes.scss +318 -318
- package/src/tokens/typography.scss +33 -33
- package/src/tokens/z-index.scss +20 -20
- package/tokens/README.md +34 -34
- package/tokens/index.js +246 -246
- package/tokens/types.d.ts +35 -35
package/src/atomics/gap.scss
CHANGED
|
@@ -1,60 +1,60 @@
|
|
|
1
|
-
$separator: '-' !default;
|
|
2
|
-
|
|
3
|
-
$gap-sizes: (
|
|
4
|
-
('xxs', $layout-1),
|
|
5
|
-
('xs', $layout-2),
|
|
6
|
-
('sm', $layout-3),
|
|
7
|
-
('md', $layout-4),
|
|
8
|
-
('lg', $layout-5),
|
|
9
|
-
// ('xl', $layout-6),
|
|
10
|
-
// ('xxl', $layout-7),
|
|
11
|
-
// ('xxxl', $layout-8),
|
|
12
|
-
('none', $layout-0)
|
|
13
|
-
);
|
|
14
|
-
|
|
15
|
-
@function sizeValue($key, $value) {
|
|
16
|
-
@return if($key == 'none', 0, $value);
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
@each $size in $gap-sizes {
|
|
20
|
-
$sizeKey: nth($size, 1);
|
|
21
|
-
$sizeValue: nth($size, 2);
|
|
22
|
-
|
|
23
|
-
// .<property>-<value>
|
|
24
|
-
.gap#{$separator}#{$sizeKey} {
|
|
25
|
-
gap: sizeValue($sizeKey, $sizeValue) !important;
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
@include tablet {
|
|
30
|
-
@each $size in $gap-sizes {
|
|
31
|
-
$sizeKey: nth($size, 1);
|
|
32
|
-
$sizeValue: nth($size, 2);
|
|
33
|
-
|
|
34
|
-
.gap#{$separator}#{$sizeKey}#{$separator}tablet {
|
|
35
|
-
gap: $sizeValue !important;
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
@include desktop {
|
|
41
|
-
@each $size in $gap-sizes {
|
|
42
|
-
$sizeKey: nth($size, 1);
|
|
43
|
-
$sizeValue: nth($size, 2);
|
|
44
|
-
|
|
45
|
-
.gap#{$separator}#{$sizeKey}#{$separator}desktop {
|
|
46
|
-
gap: $sizeValue !important;
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
@include widescreen {
|
|
52
|
-
@each $size in $gap-sizes {
|
|
53
|
-
$sizeKey: nth($size, 1);
|
|
54
|
-
$sizeValue: nth($size, 2);
|
|
55
|
-
|
|
56
|
-
.gap#{$separator}#{$sizeKey}#{$separator}widescreen {
|
|
57
|
-
gap: $sizeValue !important;
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
}
|
|
1
|
+
$separator: '-' !default;
|
|
2
|
+
|
|
3
|
+
$gap-sizes: (
|
|
4
|
+
('xxs', $layout-1),
|
|
5
|
+
('xs', $layout-2),
|
|
6
|
+
('sm', $layout-3),
|
|
7
|
+
('md', $layout-4),
|
|
8
|
+
('lg', $layout-5),
|
|
9
|
+
// ('xl', $layout-6),
|
|
10
|
+
// ('xxl', $layout-7),
|
|
11
|
+
// ('xxxl', $layout-8),
|
|
12
|
+
('none', $layout-0)
|
|
13
|
+
);
|
|
14
|
+
|
|
15
|
+
@function sizeValue($key, $value) {
|
|
16
|
+
@return if($key == 'none', 0, $value);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
@each $size in $gap-sizes {
|
|
20
|
+
$sizeKey: nth($size, 1);
|
|
21
|
+
$sizeValue: nth($size, 2);
|
|
22
|
+
|
|
23
|
+
// .<property>-<value>
|
|
24
|
+
.gap#{$separator}#{$sizeKey} {
|
|
25
|
+
gap: sizeValue($sizeKey, $sizeValue) !important;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
@include tablet {
|
|
30
|
+
@each $size in $gap-sizes {
|
|
31
|
+
$sizeKey: nth($size, 1);
|
|
32
|
+
$sizeValue: nth($size, 2);
|
|
33
|
+
|
|
34
|
+
.gap#{$separator}#{$sizeKey}#{$separator}tablet {
|
|
35
|
+
gap: $sizeValue !important;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
@include desktop {
|
|
41
|
+
@each $size in $gap-sizes {
|
|
42
|
+
$sizeKey: nth($size, 1);
|
|
43
|
+
$sizeValue: nth($size, 2);
|
|
44
|
+
|
|
45
|
+
.gap#{$separator}#{$sizeKey}#{$separator}desktop {
|
|
46
|
+
gap: $sizeValue !important;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
@include widescreen {
|
|
52
|
+
@each $size in $gap-sizes {
|
|
53
|
+
$sizeKey: nth($size, 1);
|
|
54
|
+
$sizeValue: nth($size, 2);
|
|
55
|
+
|
|
56
|
+
.gap#{$separator}#{$sizeKey}#{$separator}widescreen {
|
|
57
|
+
gap: $sizeValue !important;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
package/src/atomics/image.scss
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
.object-fit-contain {
|
|
2
|
-
object-fit: contain !important;
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
.object-fit-cover {
|
|
6
|
-
object-fit: cover !important;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.object-fit-fill {
|
|
10
|
-
object-fit: fill !important;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
.object-position-top {
|
|
14
|
-
object-position: top !important;
|
|
15
|
-
}
|
|
1
|
+
.object-fit-contain {
|
|
2
|
+
object-fit: contain !important;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.object-fit-cover {
|
|
6
|
+
object-fit: cover !important;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.object-fit-fill {
|
|
10
|
+
object-fit: fill !important;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.object-position-top {
|
|
14
|
+
object-position: top !important;
|
|
15
|
+
}
|
package/src/atomics/index.scss
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
@import './aspect-ratio.scss';
|
|
2
|
-
@import './typography.scss';
|
|
3
|
-
@import './border.scss';
|
|
4
|
-
@import './background.scss';
|
|
5
|
-
@import './colors.scss';
|
|
6
|
-
@import './display.scss';
|
|
7
|
-
@import './gap.scss';
|
|
8
|
-
@import './overflow.scss';
|
|
9
|
-
@import './shadow.scss';
|
|
10
|
-
@import './spacing-auto.scss';
|
|
11
|
-
@import './spacing.scss';
|
|
12
|
-
@import './flex.scss';
|
|
13
|
-
@import './position.scss';
|
|
14
|
-
@import './line-clamp.scss';
|
|
15
|
-
@import './image.scss';
|
|
16
|
-
@import './list.scss';
|
|
17
|
-
@import './width.scss';
|
|
18
|
-
@import './visually-hidden.scss';
|
|
1
|
+
@import './aspect-ratio.scss';
|
|
2
|
+
@import './typography.scss';
|
|
3
|
+
@import './border.scss';
|
|
4
|
+
@import './background.scss';
|
|
5
|
+
@import './colors.scss';
|
|
6
|
+
@import './display.scss';
|
|
7
|
+
@import './gap.scss';
|
|
8
|
+
@import './overflow.scss';
|
|
9
|
+
@import './shadow.scss';
|
|
10
|
+
@import './spacing-auto.scss';
|
|
11
|
+
@import './spacing.scss';
|
|
12
|
+
@import './flex.scss';
|
|
13
|
+
@import './position.scss';
|
|
14
|
+
@import './line-clamp.scss';
|
|
15
|
+
@import './image.scss';
|
|
16
|
+
@import './list.scss';
|
|
17
|
+
@import './width.scss';
|
|
18
|
+
@import './visually-hidden.scss';
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
.line-clamp-1 {
|
|
2
|
-
@include line-clamp(1, true);
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
.line-clamp-2 {
|
|
6
|
-
@include line-clamp(2, true);
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.line-clamp-3 {
|
|
10
|
-
@include line-clamp(3, true);
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
.line-clamp-4 {
|
|
14
|
-
@include line-clamp(4, true);
|
|
15
|
-
}
|
|
1
|
+
.line-clamp-1 {
|
|
2
|
+
@include line-clamp(1, true);
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.line-clamp-2 {
|
|
6
|
+
@include line-clamp(2, true);
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.line-clamp-3 {
|
|
10
|
+
@include line-clamp(3, true);
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.line-clamp-4 {
|
|
14
|
+
@include line-clamp(4, true);
|
|
15
|
+
}
|
package/src/atomics/list.scss
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
.list-style-none {
|
|
2
|
-
list-style: none !important;
|
|
3
|
-
}
|
|
1
|
+
.list-style-none {
|
|
2
|
+
list-style: none !important;
|
|
3
|
+
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
.overflow-hidden {
|
|
2
|
-
overflow: hidden;
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
@include tablet {
|
|
6
|
-
.overflow-hidden-tablet {
|
|
7
|
-
overflow: hidden;
|
|
8
|
-
}
|
|
9
|
-
}
|
|
1
|
+
.overflow-hidden {
|
|
2
|
+
overflow: hidden;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
@include tablet {
|
|
6
|
+
.overflow-hidden-tablet {
|
|
7
|
+
overflow: hidden;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
@each $item in $positions {
|
|
2
|
-
.position-#{$item} {
|
|
3
|
-
position: #{$item} !important;
|
|
4
|
-
}
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
@include tablet {
|
|
8
|
-
@each $item in $positions {
|
|
9
|
-
.position-#{$item}-tablet {
|
|
10
|
-
position: #{$item} !important;
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
@each $side, $direction in $logical-directions {
|
|
16
|
-
.#{$side}-0 {
|
|
17
|
-
inset-#{$direction}: 0 !important;
|
|
18
|
-
}
|
|
19
|
-
}
|
|
1
|
+
@each $item in $positions {
|
|
2
|
+
.position-#{$item} {
|
|
3
|
+
position: #{$item} !important;
|
|
4
|
+
}
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
@include tablet {
|
|
8
|
+
@each $item in $positions {
|
|
9
|
+
.position-#{$item}-tablet {
|
|
10
|
+
position: #{$item} !important;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
@each $side, $direction in $logical-directions {
|
|
16
|
+
.#{$side}-0 {
|
|
17
|
+
inset-#{$direction}: 0 !important;
|
|
18
|
+
}
|
|
19
|
+
}
|
package/src/atomics/shadow.scss
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
.box-shadow-none {
|
|
2
|
-
box-shadow: none !important;
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
.box-shadow-light {
|
|
6
|
-
box-shadow: $box-shadow-light !important;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.box-shadow-medium {
|
|
10
|
-
box-shadow: $box-shadow-medium !important;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
.box-shadow-heavy {
|
|
14
|
-
box-shadow: $box-shadow-heavy !important;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
.box-shadow-extra-heavy {
|
|
18
|
-
box-shadow: $box-shadow-extra-heavy !important;
|
|
19
|
-
}
|
|
1
|
+
.box-shadow-none {
|
|
2
|
+
box-shadow: none !important;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.box-shadow-light {
|
|
6
|
+
box-shadow: $box-shadow-light !important;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.box-shadow-medium {
|
|
10
|
+
box-shadow: $box-shadow-medium !important;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.box-shadow-heavy {
|
|
14
|
+
box-shadow: $box-shadow-heavy !important;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.box-shadow-extra-heavy {
|
|
18
|
+
box-shadow: $box-shadow-extra-heavy !important;
|
|
19
|
+
}
|
|
@@ -1,52 +1,52 @@
|
|
|
1
|
-
$auto-spacing-properties: (
|
|
2
|
-
('margin-inline', 'margin-inline'),
|
|
3
|
-
('margin-left', 'margin-inline-start'),
|
|
4
|
-
('margin-right', 'margin-inline-end'),
|
|
5
|
-
('margin-top', 'margin-block-start')
|
|
6
|
-
) !default;
|
|
7
|
-
|
|
8
|
-
$separator: '-';
|
|
9
|
-
|
|
10
|
-
@each $property in $auto-spacing-properties {
|
|
11
|
-
$classicProp: nth($property, 1);
|
|
12
|
-
$logicalProp: nth($property, 2);
|
|
13
|
-
|
|
14
|
-
// .<property>-auto
|
|
15
|
-
.#{$classicProp}#{$separator}auto {
|
|
16
|
-
#{$logicalProp}: auto !important;
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
// .<property>-auto-<screensize>
|
|
21
|
-
@each $property in $auto-spacing-properties {
|
|
22
|
-
$classicProp: nth($property, 1);
|
|
23
|
-
$logicalProp: nth($property, 2);
|
|
24
|
-
|
|
25
|
-
@include tablet {
|
|
26
|
-
.#{$classicProp}#{$separator}auto#{$separator}tablet {
|
|
27
|
-
#{$logicalProp}: auto !important;
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
@each $property in $auto-spacing-properties {
|
|
33
|
-
$classicProp: nth($property, 1);
|
|
34
|
-
$logicalProp: nth($property, 2);
|
|
35
|
-
|
|
36
|
-
@include desktop {
|
|
37
|
-
.#{$classicProp}#{$separator}auto#{$separator}desktop {
|
|
38
|
-
#{$logicalProp}: auto !important;
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
@each $property in $auto-spacing-properties {
|
|
44
|
-
$classicProp: nth($property, 1);
|
|
45
|
-
$logicalProp: nth($property, 2);
|
|
46
|
-
|
|
47
|
-
@include widescreen {
|
|
48
|
-
.#{$classicProp}#{$separator}auto#{$separator}widescreen {
|
|
49
|
-
#{$logicalProp}: auto !important;
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
}
|
|
1
|
+
$auto-spacing-properties: (
|
|
2
|
+
('margin-inline', 'margin-inline'),
|
|
3
|
+
('margin-left', 'margin-inline-start'),
|
|
4
|
+
('margin-right', 'margin-inline-end'),
|
|
5
|
+
('margin-top', 'margin-block-start')
|
|
6
|
+
) !default;
|
|
7
|
+
|
|
8
|
+
$separator: '-';
|
|
9
|
+
|
|
10
|
+
@each $property in $auto-spacing-properties {
|
|
11
|
+
$classicProp: nth($property, 1);
|
|
12
|
+
$logicalProp: nth($property, 2);
|
|
13
|
+
|
|
14
|
+
// .<property>-auto
|
|
15
|
+
.#{$classicProp}#{$separator}auto {
|
|
16
|
+
#{$logicalProp}: auto !important;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
// .<property>-auto-<screensize>
|
|
21
|
+
@each $property in $auto-spacing-properties {
|
|
22
|
+
$classicProp: nth($property, 1);
|
|
23
|
+
$logicalProp: nth($property, 2);
|
|
24
|
+
|
|
25
|
+
@include tablet {
|
|
26
|
+
.#{$classicProp}#{$separator}auto#{$separator}tablet {
|
|
27
|
+
#{$logicalProp}: auto !important;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
@each $property in $auto-spacing-properties {
|
|
33
|
+
$classicProp: nth($property, 1);
|
|
34
|
+
$logicalProp: nth($property, 2);
|
|
35
|
+
|
|
36
|
+
@include desktop {
|
|
37
|
+
.#{$classicProp}#{$separator}auto#{$separator}desktop {
|
|
38
|
+
#{$logicalProp}: auto !important;
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
@each $property in $auto-spacing-properties {
|
|
44
|
+
$classicProp: nth($property, 1);
|
|
45
|
+
$logicalProp: nth($property, 2);
|
|
46
|
+
|
|
47
|
+
@include widescreen {
|
|
48
|
+
.#{$classicProp}#{$separator}auto#{$separator}widescreen {
|
|
49
|
+
#{$logicalProp}: auto !important;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
}
|
package/src/atomics/spacing.scss
CHANGED
|
@@ -1,98 +1,98 @@
|
|
|
1
|
-
$separator: '-' !default;
|
|
2
|
-
$logical-spacing-properties: (
|
|
3
|
-
('margin', 'margin'),
|
|
4
|
-
('margin-inline', 'margin-inline'),
|
|
5
|
-
('margin-block', 'margin-block'),
|
|
6
|
-
('margin-top', 'margin-block-start'),
|
|
7
|
-
('margin-bottom', 'margin-block-end'),
|
|
8
|
-
('margin-left', 'margin-inline-start'),
|
|
9
|
-
('margin-right', 'margin-inline-end'),
|
|
10
|
-
('padding', 'padding'),
|
|
11
|
-
('padding-inline', 'padding-inline'),
|
|
12
|
-
('padding-block', 'padding-block'),
|
|
13
|
-
('padding-top', 'padding-block-start'),
|
|
14
|
-
('padding-bottom', 'padding-block-end'),
|
|
15
|
-
('padding-left', 'padding-inline-start'),
|
|
16
|
-
('padding-right', 'padding-inline-end')
|
|
17
|
-
) !default;
|
|
18
|
-
|
|
19
|
-
$layout-sizes: (
|
|
20
|
-
('xxs', $layout-1),
|
|
21
|
-
('xs', $layout-2),
|
|
22
|
-
('sm', $layout-3),
|
|
23
|
-
('md', $layout-4),
|
|
24
|
-
('lg', $layout-5),
|
|
25
|
-
('xl', $layout-6),
|
|
26
|
-
('xxl', $layout-7),
|
|
27
|
-
('xxxl', $layout-8),
|
|
28
|
-
('none', $layout-0)
|
|
29
|
-
);
|
|
30
|
-
|
|
31
|
-
@function sizeValue($key, $value) {
|
|
32
|
-
@return if($key == 'none', 0, $value);
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
// Pattern: <cssproperty>-<value>-<screen>
|
|
36
|
-
|
|
37
|
-
@each $property in $logical-spacing-properties {
|
|
38
|
-
$classicProp: nth($property, 1);
|
|
39
|
-
$logicalProp: nth($property, 2);
|
|
40
|
-
|
|
41
|
-
@each $size in $layout-sizes {
|
|
42
|
-
$sizeKey: nth($size, 1);
|
|
43
|
-
$sizeValue: nth($size, 2);
|
|
44
|
-
|
|
45
|
-
// .<property>-<value>
|
|
46
|
-
.#{$classicProp}#{$separator}#{$sizeKey} {
|
|
47
|
-
#{$logicalProp}: sizeValue($sizeKey, $sizeValue) !important;
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
@include tablet {
|
|
53
|
-
@each $property in $logical-spacing-properties {
|
|
54
|
-
$classicProp: nth($property, 1);
|
|
55
|
-
$logicalProp: nth($property, 2);
|
|
56
|
-
|
|
57
|
-
@each $size in $layout-sizes {
|
|
58
|
-
$sizeKey: nth($size, 1);
|
|
59
|
-
$sizeValue: nth($size, 2);
|
|
60
|
-
|
|
61
|
-
.#{$classicProp}#{$separator}#{$sizeKey}#{$separator}tablet {
|
|
62
|
-
#{$logicalProp}: $sizeValue !important;
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
@include desktop {
|
|
69
|
-
@each $property in $logical-spacing-properties {
|
|
70
|
-
$classicProp: nth($property, 1);
|
|
71
|
-
$logicalProp: nth($property, 2);
|
|
72
|
-
|
|
73
|
-
@each $size in $layout-sizes {
|
|
74
|
-
$sizeKey: nth($size, 1);
|
|
75
|
-
$sizeValue: nth($size, 2);
|
|
76
|
-
|
|
77
|
-
.#{$classicProp}#{$separator}#{$sizeKey}#{$separator}desktop {
|
|
78
|
-
#{$logicalProp}: $sizeValue !important;
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
@include widescreen {
|
|
85
|
-
@each $property in $logical-spacing-properties {
|
|
86
|
-
$classicProp: nth($property, 1);
|
|
87
|
-
$logicalProp: nth($property, 2);
|
|
88
|
-
|
|
89
|
-
@each $size in $layout-sizes {
|
|
90
|
-
$sizeKey: nth($size, 1);
|
|
91
|
-
$sizeValue: nth($size, 2);
|
|
92
|
-
|
|
93
|
-
.#{$classicProp}#{$separator}#{$sizeKey}#{$separator}widescreen {
|
|
94
|
-
#{$logicalProp}: $sizeValue !important;
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
}
|
|
1
|
+
$separator: '-' !default;
|
|
2
|
+
$logical-spacing-properties: (
|
|
3
|
+
('margin', 'margin'),
|
|
4
|
+
('margin-inline', 'margin-inline'),
|
|
5
|
+
('margin-block', 'margin-block'),
|
|
6
|
+
('margin-top', 'margin-block-start'),
|
|
7
|
+
('margin-bottom', 'margin-block-end'),
|
|
8
|
+
('margin-left', 'margin-inline-start'),
|
|
9
|
+
('margin-right', 'margin-inline-end'),
|
|
10
|
+
('padding', 'padding'),
|
|
11
|
+
('padding-inline', 'padding-inline'),
|
|
12
|
+
('padding-block', 'padding-block'),
|
|
13
|
+
('padding-top', 'padding-block-start'),
|
|
14
|
+
('padding-bottom', 'padding-block-end'),
|
|
15
|
+
('padding-left', 'padding-inline-start'),
|
|
16
|
+
('padding-right', 'padding-inline-end')
|
|
17
|
+
) !default;
|
|
18
|
+
|
|
19
|
+
$layout-sizes: (
|
|
20
|
+
('xxs', $layout-1),
|
|
21
|
+
('xs', $layout-2),
|
|
22
|
+
('sm', $layout-3),
|
|
23
|
+
('md', $layout-4),
|
|
24
|
+
('lg', $layout-5),
|
|
25
|
+
('xl', $layout-6),
|
|
26
|
+
('xxl', $layout-7),
|
|
27
|
+
('xxxl', $layout-8),
|
|
28
|
+
('none', $layout-0)
|
|
29
|
+
);
|
|
30
|
+
|
|
31
|
+
@function sizeValue($key, $value) {
|
|
32
|
+
@return if($key == 'none', 0, $value);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
// Pattern: <cssproperty>-<value>-<screen>
|
|
36
|
+
|
|
37
|
+
@each $property in $logical-spacing-properties {
|
|
38
|
+
$classicProp: nth($property, 1);
|
|
39
|
+
$logicalProp: nth($property, 2);
|
|
40
|
+
|
|
41
|
+
@each $size in $layout-sizes {
|
|
42
|
+
$sizeKey: nth($size, 1);
|
|
43
|
+
$sizeValue: nth($size, 2);
|
|
44
|
+
|
|
45
|
+
// .<property>-<value>
|
|
46
|
+
.#{$classicProp}#{$separator}#{$sizeKey} {
|
|
47
|
+
#{$logicalProp}: sizeValue($sizeKey, $sizeValue) !important;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
@include tablet {
|
|
53
|
+
@each $property in $logical-spacing-properties {
|
|
54
|
+
$classicProp: nth($property, 1);
|
|
55
|
+
$logicalProp: nth($property, 2);
|
|
56
|
+
|
|
57
|
+
@each $size in $layout-sizes {
|
|
58
|
+
$sizeKey: nth($size, 1);
|
|
59
|
+
$sizeValue: nth($size, 2);
|
|
60
|
+
|
|
61
|
+
.#{$classicProp}#{$separator}#{$sizeKey}#{$separator}tablet {
|
|
62
|
+
#{$logicalProp}: $sizeValue !important;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
@include desktop {
|
|
69
|
+
@each $property in $logical-spacing-properties {
|
|
70
|
+
$classicProp: nth($property, 1);
|
|
71
|
+
$logicalProp: nth($property, 2);
|
|
72
|
+
|
|
73
|
+
@each $size in $layout-sizes {
|
|
74
|
+
$sizeKey: nth($size, 1);
|
|
75
|
+
$sizeValue: nth($size, 2);
|
|
76
|
+
|
|
77
|
+
.#{$classicProp}#{$separator}#{$sizeKey}#{$separator}desktop {
|
|
78
|
+
#{$logicalProp}: $sizeValue !important;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
@include widescreen {
|
|
85
|
+
@each $property in $logical-spacing-properties {
|
|
86
|
+
$classicProp: nth($property, 1);
|
|
87
|
+
$logicalProp: nth($property, 2);
|
|
88
|
+
|
|
89
|
+
@each $size in $layout-sizes {
|
|
90
|
+
$sizeKey: nth($size, 1);
|
|
91
|
+
$sizeValue: nth($size, 2);
|
|
92
|
+
|
|
93
|
+
.#{$classicProp}#{$separator}#{$sizeKey}#{$separator}widescreen {
|
|
94
|
+
#{$logicalProp}: $sizeValue !important;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
}
|