forked from carbon-design-system/carbon
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path_stack.scss
34 lines (28 loc) · 769 Bytes
/
_stack.scss
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
//
// Copyright IBM Corp. 2018, 2023
//
// This source code is licensed under the Apache-2.0 license found in the
// LICENSE file in the root directory of this source tree.
//
@use '../../config' as *;
@use '../../spacing';
@use '../../utilities/custom-property';
@mixin stack() {
.#{$prefix}--stack-horizontal {
display: inline-grid;
column-gap: custom-property.get-var('stack-gap', 0);
grid-auto-flow: column;
}
.#{$prefix}--stack-vertical {
display: grid;
grid-auto-flow: row;
row-gap: custom-property.get-var('stack-gap', 0);
}
$index: 1;
@each $step, $value in spacing.$spacing {
.#{$prefix}--stack-scale-#{$index} {
@include custom-property.declaration('stack-gap', $value);
}
$index: $index + 1;
}
}