@carbon/layout 12.0.0-alpha.0 → 12.0.0-alpha.2
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/es/index.js +205 -0
- package/lib/__tests__/tokens-test.d.ts +1 -0
- package/package.json +11 -2
- package/umd/index.js +277 -0
- package/docs/sass.md +0 -65
- package/src/dtcg/README.md +0 -266
- package/src/dtcg/layout.json +0 -432
- package/src/index.ts +0 -221
- package/src/tokens.ts +0 -56
- package/style-dictionary/formats/js-layout.js +0 -104
- package/style-dictionary/formats/scss-layout.js +0 -188
- package/style-dictionary/sd.config.js +0 -104
- package/tsconfig.json +0 -8
- package/tsconfig.types.json +0 -10
package/es/index.js
ADDED
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
//#region js/generated/layout-tokens.js
|
|
2
|
+
const spacing01 = "0.125rem";
|
|
3
|
+
const spacing02 = "0.25rem";
|
|
4
|
+
const spacing03 = "0.5rem";
|
|
5
|
+
const spacing04 = "0.75rem";
|
|
6
|
+
const spacing05 = "1rem";
|
|
7
|
+
const spacing06 = "1.5rem";
|
|
8
|
+
const spacing07 = "2rem";
|
|
9
|
+
const spacing08 = "2.5rem";
|
|
10
|
+
const spacing09 = "3rem";
|
|
11
|
+
const spacing10 = "4rem";
|
|
12
|
+
const spacing11 = "5rem";
|
|
13
|
+
const spacing12 = "6rem";
|
|
14
|
+
const spacing13 = "10rem";
|
|
15
|
+
const fluidSpacing01 = 0;
|
|
16
|
+
const fluidSpacing02 = "2vw";
|
|
17
|
+
const fluidSpacing03 = "5vw";
|
|
18
|
+
const fluidSpacing04 = "10vw";
|
|
19
|
+
const container01 = "1.5rem";
|
|
20
|
+
const container02 = "2rem";
|
|
21
|
+
const container03 = "2.5rem";
|
|
22
|
+
const container04 = "3rem";
|
|
23
|
+
const container05 = "4rem";
|
|
24
|
+
const sizeXs = "1.5rem";
|
|
25
|
+
const sizeSm = "2rem";
|
|
26
|
+
const sizeMd = "2.5rem";
|
|
27
|
+
const sizeLg = "3rem";
|
|
28
|
+
const sizeXl = "4rem";
|
|
29
|
+
const size2xl = "5rem";
|
|
30
|
+
const iconSize01 = "1rem";
|
|
31
|
+
const iconSize02 = "1.25rem";
|
|
32
|
+
const borderRadius00 = "0px";
|
|
33
|
+
const borderRadius02 = "0.125rem";
|
|
34
|
+
const borderRadius04 = "0.25rem";
|
|
35
|
+
const borderRadius08 = "0.5rem";
|
|
36
|
+
const borderRadius16 = "1rem";
|
|
37
|
+
const borderRadius24 = "1.5rem";
|
|
38
|
+
const borderRadiusMax = "999999px";
|
|
39
|
+
const layout01 = "1rem";
|
|
40
|
+
const layout02 = "1.5rem";
|
|
41
|
+
const layout03 = "2rem";
|
|
42
|
+
const layout04 = "3rem";
|
|
43
|
+
const layout05 = "4rem";
|
|
44
|
+
const layout06 = "6rem";
|
|
45
|
+
const layout07 = "10rem";
|
|
46
|
+
//#endregion
|
|
47
|
+
//#region src/tokens.ts
|
|
48
|
+
/**
|
|
49
|
+
* Copyright IBM Corp. 2018, 2026
|
|
50
|
+
*
|
|
51
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
52
|
+
* LICENSE file in the root directory of this source tree.
|
|
53
|
+
*/
|
|
54
|
+
const unstable_tokens = [
|
|
55
|
+
"spacing01",
|
|
56
|
+
"spacing02",
|
|
57
|
+
"spacing03",
|
|
58
|
+
"spacing04",
|
|
59
|
+
"spacing05",
|
|
60
|
+
"spacing06",
|
|
61
|
+
"spacing07",
|
|
62
|
+
"spacing08",
|
|
63
|
+
"spacing09",
|
|
64
|
+
"spacing10",
|
|
65
|
+
"spacing11",
|
|
66
|
+
"spacing12",
|
|
67
|
+
"spacing13",
|
|
68
|
+
"fluidSpacing01",
|
|
69
|
+
"fluidSpacing02",
|
|
70
|
+
"fluidSpacing03",
|
|
71
|
+
"fluidSpacing04",
|
|
72
|
+
"container01",
|
|
73
|
+
"container02",
|
|
74
|
+
"container03",
|
|
75
|
+
"container04",
|
|
76
|
+
"container05",
|
|
77
|
+
"sizeXSmall",
|
|
78
|
+
"sizeSmall",
|
|
79
|
+
"sizeMedium",
|
|
80
|
+
"sizeLarge",
|
|
81
|
+
"sizeXLarge",
|
|
82
|
+
"size2XLarge",
|
|
83
|
+
"iconSize01",
|
|
84
|
+
"iconSize02",
|
|
85
|
+
"layout01",
|
|
86
|
+
"layout02",
|
|
87
|
+
"layout03",
|
|
88
|
+
"layout04",
|
|
89
|
+
"layout05",
|
|
90
|
+
"layout06",
|
|
91
|
+
"layout07"
|
|
92
|
+
];
|
|
93
|
+
//#endregion
|
|
94
|
+
//#region src/index.ts
|
|
95
|
+
const baseFontSize = 16;
|
|
96
|
+
const rem = (px) => {
|
|
97
|
+
return `${px / 16}rem`;
|
|
98
|
+
};
|
|
99
|
+
const em = (px) => {
|
|
100
|
+
return `${px / 16}em`;
|
|
101
|
+
};
|
|
102
|
+
const px = (value) => {
|
|
103
|
+
return `${value}px`;
|
|
104
|
+
};
|
|
105
|
+
const breakpoints = {
|
|
106
|
+
sm: {
|
|
107
|
+
width: rem(320),
|
|
108
|
+
columns: 4,
|
|
109
|
+
margin: "0"
|
|
110
|
+
},
|
|
111
|
+
md: {
|
|
112
|
+
width: rem(672),
|
|
113
|
+
columns: 8,
|
|
114
|
+
margin: rem(16)
|
|
115
|
+
},
|
|
116
|
+
lg: {
|
|
117
|
+
width: rem(1056),
|
|
118
|
+
columns: 16,
|
|
119
|
+
margin: rem(16)
|
|
120
|
+
},
|
|
121
|
+
xlg: {
|
|
122
|
+
width: rem(1312),
|
|
123
|
+
columns: 16,
|
|
124
|
+
margin: rem(16)
|
|
125
|
+
},
|
|
126
|
+
max: {
|
|
127
|
+
width: rem(1584),
|
|
128
|
+
columns: 16,
|
|
129
|
+
margin: rem(24)
|
|
130
|
+
}
|
|
131
|
+
};
|
|
132
|
+
const breakpointUp = (name) => {
|
|
133
|
+
return `@media (min-width: ${breakpoints[name].width})`;
|
|
134
|
+
};
|
|
135
|
+
const breakpointDown = (name) => {
|
|
136
|
+
return `@media (max-width: ${breakpoints[name].width})`;
|
|
137
|
+
};
|
|
138
|
+
const breakpoint = breakpointUp;
|
|
139
|
+
const miniUnit = 8;
|
|
140
|
+
const miniUnits = (count) => {
|
|
141
|
+
return rem(8 * count);
|
|
142
|
+
};
|
|
143
|
+
const spacing = [
|
|
144
|
+
spacing01,
|
|
145
|
+
spacing02,
|
|
146
|
+
spacing03,
|
|
147
|
+
spacing04,
|
|
148
|
+
spacing05,
|
|
149
|
+
spacing06,
|
|
150
|
+
spacing07,
|
|
151
|
+
spacing08,
|
|
152
|
+
spacing09,
|
|
153
|
+
spacing10,
|
|
154
|
+
spacing11,
|
|
155
|
+
spacing12,
|
|
156
|
+
spacing13
|
|
157
|
+
];
|
|
158
|
+
const fluidSpacing = [
|
|
159
|
+
0,
|
|
160
|
+
"2vw",
|
|
161
|
+
"5vw",
|
|
162
|
+
fluidSpacing04
|
|
163
|
+
];
|
|
164
|
+
const layout = [
|
|
165
|
+
layout01,
|
|
166
|
+
layout02,
|
|
167
|
+
layout03,
|
|
168
|
+
layout04,
|
|
169
|
+
layout05,
|
|
170
|
+
layout06,
|
|
171
|
+
layout07
|
|
172
|
+
];
|
|
173
|
+
const container = [
|
|
174
|
+
container01,
|
|
175
|
+
container02,
|
|
176
|
+
container03,
|
|
177
|
+
container04,
|
|
178
|
+
container05
|
|
179
|
+
];
|
|
180
|
+
const sizeXSmall = sizeXs;
|
|
181
|
+
const sizeSmall = sizeSm;
|
|
182
|
+
const sizeMedium = sizeMd;
|
|
183
|
+
const sizeLarge = sizeLg;
|
|
184
|
+
const sizeXLarge = sizeXl;
|
|
185
|
+
const size2XLarge = size2xl;
|
|
186
|
+
const sizes = {
|
|
187
|
+
XSmall: sizeXSmall,
|
|
188
|
+
Small: sizeSmall,
|
|
189
|
+
Medium: sizeMedium,
|
|
190
|
+
Large: sizeLarge,
|
|
191
|
+
XLarge: sizeXLarge,
|
|
192
|
+
"2XLarge": size2XLarge
|
|
193
|
+
};
|
|
194
|
+
const iconSize = [iconSize01, iconSize02];
|
|
195
|
+
const borderRadius = {
|
|
196
|
+
"border-radius-00": "0px",
|
|
197
|
+
"border-radius-02": borderRadius02,
|
|
198
|
+
"border-radius-04": borderRadius04,
|
|
199
|
+
"border-radius-08": borderRadius08,
|
|
200
|
+
"border-radius-16": borderRadius16,
|
|
201
|
+
"border-radius-24": borderRadius24,
|
|
202
|
+
"border-radius-max": borderRadiusMax
|
|
203
|
+
};
|
|
204
|
+
//#endregion
|
|
205
|
+
export { baseFontSize, borderRadius, borderRadius00, borderRadius02, borderRadius04, borderRadius08, borderRadius16, borderRadius24, borderRadiusMax, breakpoint, breakpointDown, breakpointUp, breakpoints, container, container01, container02, container03, container04, container05, em, fluidSpacing, fluidSpacing01, fluidSpacing02, fluidSpacing03, fluidSpacing04, iconSize, iconSize01, iconSize02, layout, layout01, layout02, layout03, layout04, layout05, layout06, layout07, miniUnit, miniUnits, px, rem, size2XLarge, size2xl, sizeLarge, sizeLg, sizeMd, sizeMedium, sizeSm, sizeSmall, sizeXLarge, sizeXSmall, sizeXl, sizeXs, sizes, spacing, spacing01, spacing02, spacing03, spacing04, spacing05, spacing06, spacing07, spacing08, spacing09, spacing10, spacing11, spacing12, spacing13, unstable_tokens };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@carbon/layout",
|
|
3
3
|
"description": "Layout helpers for digital and software products using the Carbon Design System",
|
|
4
|
-
"version": "12.0.0-alpha.
|
|
4
|
+
"version": "12.0.0-alpha.2",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"sideEffects": [
|
|
7
7
|
"index.scss",
|
|
@@ -17,6 +17,15 @@
|
|
|
17
17
|
"directory": "packages/layout"
|
|
18
18
|
},
|
|
19
19
|
"bugs": "https://github.com/carbon-design-system/carbon/issues",
|
|
20
|
+
"files": [
|
|
21
|
+
"es",
|
|
22
|
+
"js/generated",
|
|
23
|
+
"lib",
|
|
24
|
+
"scss",
|
|
25
|
+
"umd",
|
|
26
|
+
"index.scss",
|
|
27
|
+
"telemetry.yml"
|
|
28
|
+
],
|
|
20
29
|
"keywords": [
|
|
21
30
|
"ibm",
|
|
22
31
|
"elements",
|
|
@@ -37,7 +46,7 @@
|
|
|
37
46
|
"postinstall": "ibmtelemetry --config=telemetry.yml"
|
|
38
47
|
},
|
|
39
48
|
"devDependencies": {
|
|
40
|
-
"@carbon/cli": "^12.0.0-alpha.
|
|
49
|
+
"@carbon/cli": "^12.0.0-alpha.1",
|
|
41
50
|
"@carbon/cli-reporter": "^10.9.0",
|
|
42
51
|
"@carbon/scss-generator": "^10.20.0",
|
|
43
52
|
"@carbon/test-utils": "^10.41.0",
|
package/umd/index.js
ADDED
|
@@ -0,0 +1,277 @@
|
|
|
1
|
+
(function(global, factory) {
|
|
2
|
+
typeof exports === "object" && typeof module !== "undefined" ? factory(exports) : typeof define === "function" && define.amd ? define(["exports"], factory) : (global = typeof globalThis !== "undefined" ? globalThis : global || self, factory(global.CarbonLayout = {}));
|
|
3
|
+
})(this, function(exports) {
|
|
4
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
5
|
+
//#region js/generated/layout-tokens.js
|
|
6
|
+
const spacing01 = "0.125rem";
|
|
7
|
+
const spacing02 = "0.25rem";
|
|
8
|
+
const spacing03 = "0.5rem";
|
|
9
|
+
const spacing04 = "0.75rem";
|
|
10
|
+
const spacing05 = "1rem";
|
|
11
|
+
const spacing06 = "1.5rem";
|
|
12
|
+
const spacing07 = "2rem";
|
|
13
|
+
const spacing08 = "2.5rem";
|
|
14
|
+
const spacing09 = "3rem";
|
|
15
|
+
const spacing10 = "4rem";
|
|
16
|
+
const spacing11 = "5rem";
|
|
17
|
+
const spacing12 = "6rem";
|
|
18
|
+
const spacing13 = "10rem";
|
|
19
|
+
const fluidSpacing01 = 0;
|
|
20
|
+
const fluidSpacing02 = "2vw";
|
|
21
|
+
const fluidSpacing03 = "5vw";
|
|
22
|
+
const fluidSpacing04 = "10vw";
|
|
23
|
+
const container01 = "1.5rem";
|
|
24
|
+
const container02 = "2rem";
|
|
25
|
+
const container03 = "2.5rem";
|
|
26
|
+
const container04 = "3rem";
|
|
27
|
+
const container05 = "4rem";
|
|
28
|
+
const sizeXs = "1.5rem";
|
|
29
|
+
const sizeSm = "2rem";
|
|
30
|
+
const sizeMd = "2.5rem";
|
|
31
|
+
const sizeLg = "3rem";
|
|
32
|
+
const sizeXl = "4rem";
|
|
33
|
+
const size2xl = "5rem";
|
|
34
|
+
const iconSize01 = "1rem";
|
|
35
|
+
const iconSize02 = "1.25rem";
|
|
36
|
+
const borderRadius00 = "0px";
|
|
37
|
+
const borderRadius02 = "0.125rem";
|
|
38
|
+
const borderRadius04 = "0.25rem";
|
|
39
|
+
const borderRadius08 = "0.5rem";
|
|
40
|
+
const borderRadius16 = "1rem";
|
|
41
|
+
const borderRadius24 = "1.5rem";
|
|
42
|
+
const borderRadiusMax = "999999px";
|
|
43
|
+
const layout01 = "1rem";
|
|
44
|
+
const layout02 = "1.5rem";
|
|
45
|
+
const layout03 = "2rem";
|
|
46
|
+
const layout04 = "3rem";
|
|
47
|
+
const layout05 = "4rem";
|
|
48
|
+
const layout06 = "6rem";
|
|
49
|
+
const layout07 = "10rem";
|
|
50
|
+
//#endregion
|
|
51
|
+
//#region src/tokens.ts
|
|
52
|
+
/**
|
|
53
|
+
* Copyright IBM Corp. 2018, 2026
|
|
54
|
+
*
|
|
55
|
+
* This source code is licensed under the Apache-2.0 license found in the
|
|
56
|
+
* LICENSE file in the root directory of this source tree.
|
|
57
|
+
*/
|
|
58
|
+
const unstable_tokens = [
|
|
59
|
+
"spacing01",
|
|
60
|
+
"spacing02",
|
|
61
|
+
"spacing03",
|
|
62
|
+
"spacing04",
|
|
63
|
+
"spacing05",
|
|
64
|
+
"spacing06",
|
|
65
|
+
"spacing07",
|
|
66
|
+
"spacing08",
|
|
67
|
+
"spacing09",
|
|
68
|
+
"spacing10",
|
|
69
|
+
"spacing11",
|
|
70
|
+
"spacing12",
|
|
71
|
+
"spacing13",
|
|
72
|
+
"fluidSpacing01",
|
|
73
|
+
"fluidSpacing02",
|
|
74
|
+
"fluidSpacing03",
|
|
75
|
+
"fluidSpacing04",
|
|
76
|
+
"container01",
|
|
77
|
+
"container02",
|
|
78
|
+
"container03",
|
|
79
|
+
"container04",
|
|
80
|
+
"container05",
|
|
81
|
+
"sizeXSmall",
|
|
82
|
+
"sizeSmall",
|
|
83
|
+
"sizeMedium",
|
|
84
|
+
"sizeLarge",
|
|
85
|
+
"sizeXLarge",
|
|
86
|
+
"size2XLarge",
|
|
87
|
+
"iconSize01",
|
|
88
|
+
"iconSize02",
|
|
89
|
+
"layout01",
|
|
90
|
+
"layout02",
|
|
91
|
+
"layout03",
|
|
92
|
+
"layout04",
|
|
93
|
+
"layout05",
|
|
94
|
+
"layout06",
|
|
95
|
+
"layout07"
|
|
96
|
+
];
|
|
97
|
+
//#endregion
|
|
98
|
+
//#region src/index.ts
|
|
99
|
+
const baseFontSize = 16;
|
|
100
|
+
const rem = (px) => {
|
|
101
|
+
return `${px / 16}rem`;
|
|
102
|
+
};
|
|
103
|
+
const em = (px) => {
|
|
104
|
+
return `${px / 16}em`;
|
|
105
|
+
};
|
|
106
|
+
const px = (value) => {
|
|
107
|
+
return `${value}px`;
|
|
108
|
+
};
|
|
109
|
+
const breakpoints = {
|
|
110
|
+
sm: {
|
|
111
|
+
width: rem(320),
|
|
112
|
+
columns: 4,
|
|
113
|
+
margin: "0"
|
|
114
|
+
},
|
|
115
|
+
md: {
|
|
116
|
+
width: rem(672),
|
|
117
|
+
columns: 8,
|
|
118
|
+
margin: rem(16)
|
|
119
|
+
},
|
|
120
|
+
lg: {
|
|
121
|
+
width: rem(1056),
|
|
122
|
+
columns: 16,
|
|
123
|
+
margin: rem(16)
|
|
124
|
+
},
|
|
125
|
+
xlg: {
|
|
126
|
+
width: rem(1312),
|
|
127
|
+
columns: 16,
|
|
128
|
+
margin: rem(16)
|
|
129
|
+
},
|
|
130
|
+
max: {
|
|
131
|
+
width: rem(1584),
|
|
132
|
+
columns: 16,
|
|
133
|
+
margin: rem(24)
|
|
134
|
+
}
|
|
135
|
+
};
|
|
136
|
+
const breakpointUp = (name) => {
|
|
137
|
+
return `@media (min-width: ${breakpoints[name].width})`;
|
|
138
|
+
};
|
|
139
|
+
const breakpointDown = (name) => {
|
|
140
|
+
return `@media (max-width: ${breakpoints[name].width})`;
|
|
141
|
+
};
|
|
142
|
+
const breakpoint = breakpointUp;
|
|
143
|
+
const miniUnit = 8;
|
|
144
|
+
const miniUnits = (count) => {
|
|
145
|
+
return rem(8 * count);
|
|
146
|
+
};
|
|
147
|
+
const spacing = [
|
|
148
|
+
spacing01,
|
|
149
|
+
spacing02,
|
|
150
|
+
spacing03,
|
|
151
|
+
spacing04,
|
|
152
|
+
spacing05,
|
|
153
|
+
spacing06,
|
|
154
|
+
spacing07,
|
|
155
|
+
spacing08,
|
|
156
|
+
spacing09,
|
|
157
|
+
spacing10,
|
|
158
|
+
spacing11,
|
|
159
|
+
spacing12,
|
|
160
|
+
spacing13
|
|
161
|
+
];
|
|
162
|
+
const fluidSpacing = [
|
|
163
|
+
0,
|
|
164
|
+
"2vw",
|
|
165
|
+
"5vw",
|
|
166
|
+
fluidSpacing04
|
|
167
|
+
];
|
|
168
|
+
const layout = [
|
|
169
|
+
layout01,
|
|
170
|
+
layout02,
|
|
171
|
+
layout03,
|
|
172
|
+
layout04,
|
|
173
|
+
layout05,
|
|
174
|
+
layout06,
|
|
175
|
+
layout07
|
|
176
|
+
];
|
|
177
|
+
const container = [
|
|
178
|
+
container01,
|
|
179
|
+
container02,
|
|
180
|
+
container03,
|
|
181
|
+
container04,
|
|
182
|
+
container05
|
|
183
|
+
];
|
|
184
|
+
const sizeXSmall = sizeXs;
|
|
185
|
+
const sizeSmall = sizeSm;
|
|
186
|
+
const sizeMedium = sizeMd;
|
|
187
|
+
const sizeLarge = sizeLg;
|
|
188
|
+
const sizeXLarge = sizeXl;
|
|
189
|
+
const size2XLarge = size2xl;
|
|
190
|
+
const sizes = {
|
|
191
|
+
XSmall: sizeXSmall,
|
|
192
|
+
Small: sizeSmall,
|
|
193
|
+
Medium: sizeMedium,
|
|
194
|
+
Large: sizeLarge,
|
|
195
|
+
XLarge: sizeXLarge,
|
|
196
|
+
"2XLarge": size2XLarge
|
|
197
|
+
};
|
|
198
|
+
const iconSize = [iconSize01, iconSize02];
|
|
199
|
+
const borderRadius = {
|
|
200
|
+
"border-radius-00": "0px",
|
|
201
|
+
"border-radius-02": borderRadius02,
|
|
202
|
+
"border-radius-04": borderRadius04,
|
|
203
|
+
"border-radius-08": borderRadius08,
|
|
204
|
+
"border-radius-16": borderRadius16,
|
|
205
|
+
"border-radius-24": borderRadius24,
|
|
206
|
+
"border-radius-max": borderRadiusMax
|
|
207
|
+
};
|
|
208
|
+
//#endregion
|
|
209
|
+
exports.baseFontSize = baseFontSize;
|
|
210
|
+
exports.borderRadius = borderRadius;
|
|
211
|
+
exports.borderRadius00 = borderRadius00;
|
|
212
|
+
exports.borderRadius02 = borderRadius02;
|
|
213
|
+
exports.borderRadius04 = borderRadius04;
|
|
214
|
+
exports.borderRadius08 = borderRadius08;
|
|
215
|
+
exports.borderRadius16 = borderRadius16;
|
|
216
|
+
exports.borderRadius24 = borderRadius24;
|
|
217
|
+
exports.borderRadiusMax = borderRadiusMax;
|
|
218
|
+
exports.breakpoint = breakpoint;
|
|
219
|
+
exports.breakpointDown = breakpointDown;
|
|
220
|
+
exports.breakpointUp = breakpointUp;
|
|
221
|
+
exports.breakpoints = breakpoints;
|
|
222
|
+
exports.container = container;
|
|
223
|
+
exports.container01 = container01;
|
|
224
|
+
exports.container02 = container02;
|
|
225
|
+
exports.container03 = container03;
|
|
226
|
+
exports.container04 = container04;
|
|
227
|
+
exports.container05 = container05;
|
|
228
|
+
exports.em = em;
|
|
229
|
+
exports.fluidSpacing = fluidSpacing;
|
|
230
|
+
exports.fluidSpacing01 = fluidSpacing01;
|
|
231
|
+
exports.fluidSpacing02 = fluidSpacing02;
|
|
232
|
+
exports.fluidSpacing03 = fluidSpacing03;
|
|
233
|
+
exports.fluidSpacing04 = fluidSpacing04;
|
|
234
|
+
exports.iconSize = iconSize;
|
|
235
|
+
exports.iconSize01 = iconSize01;
|
|
236
|
+
exports.iconSize02 = iconSize02;
|
|
237
|
+
exports.layout = layout;
|
|
238
|
+
exports.layout01 = layout01;
|
|
239
|
+
exports.layout02 = layout02;
|
|
240
|
+
exports.layout03 = layout03;
|
|
241
|
+
exports.layout04 = layout04;
|
|
242
|
+
exports.layout05 = layout05;
|
|
243
|
+
exports.layout06 = layout06;
|
|
244
|
+
exports.layout07 = layout07;
|
|
245
|
+
exports.miniUnit = miniUnit;
|
|
246
|
+
exports.miniUnits = miniUnits;
|
|
247
|
+
exports.px = px;
|
|
248
|
+
exports.rem = rem;
|
|
249
|
+
exports.size2XLarge = size2XLarge;
|
|
250
|
+
exports.size2xl = size2xl;
|
|
251
|
+
exports.sizeLarge = sizeLarge;
|
|
252
|
+
exports.sizeLg = sizeLg;
|
|
253
|
+
exports.sizeMd = sizeMd;
|
|
254
|
+
exports.sizeMedium = sizeMedium;
|
|
255
|
+
exports.sizeSm = sizeSm;
|
|
256
|
+
exports.sizeSmall = sizeSmall;
|
|
257
|
+
exports.sizeXLarge = sizeXLarge;
|
|
258
|
+
exports.sizeXSmall = sizeXSmall;
|
|
259
|
+
exports.sizeXl = sizeXl;
|
|
260
|
+
exports.sizeXs = sizeXs;
|
|
261
|
+
exports.sizes = sizes;
|
|
262
|
+
exports.spacing = spacing;
|
|
263
|
+
exports.spacing01 = spacing01;
|
|
264
|
+
exports.spacing02 = spacing02;
|
|
265
|
+
exports.spacing03 = spacing03;
|
|
266
|
+
exports.spacing04 = spacing04;
|
|
267
|
+
exports.spacing05 = spacing05;
|
|
268
|
+
exports.spacing06 = spacing06;
|
|
269
|
+
exports.spacing07 = spacing07;
|
|
270
|
+
exports.spacing08 = spacing08;
|
|
271
|
+
exports.spacing09 = spacing09;
|
|
272
|
+
exports.spacing10 = spacing10;
|
|
273
|
+
exports.spacing11 = spacing11;
|
|
274
|
+
exports.spacing12 = spacing12;
|
|
275
|
+
exports.spacing13 = spacing13;
|
|
276
|
+
exports.unstable_tokens = unstable_tokens;
|
|
277
|
+
});
|
package/docs/sass.md
DELETED
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
# Sass
|
|
2
|
-
|
|
3
|
-
> Sass documentation for `@carbon/layout`
|
|
4
|
-
|
|
5
|
-
## Usage
|
|
6
|
-
|
|
7
|
-
The `@carbon/layout` package provides spacing tokens and conversion utilities
|
|
8
|
-
for the Carbon Design System. You can access these tokens and helpers by writing
|
|
9
|
-
the following:
|
|
10
|
-
|
|
11
|
-
```scss
|
|
12
|
-
@use '@carbon/layout';
|
|
13
|
-
|
|
14
|
-
.selector {
|
|
15
|
-
margin-bottom: layout.$spacing-05;
|
|
16
|
-
width: layout.rem(24px);
|
|
17
|
-
height: layout.rem(24px);
|
|
18
|
-
}
|
|
19
|
-
```
|
|
20
|
-
|
|
21
|
-
## API
|
|
22
|
-
|
|
23
|
-
| Export | Description | !default |
|
|
24
|
-
| :------------------- | :---------- | :------- |
|
|
25
|
-
| `$spacing-01` | | ✅ |
|
|
26
|
-
| `$spacing-02` | | ✅ |
|
|
27
|
-
| `$spacing-03` | | ✅ |
|
|
28
|
-
| `$spacing-04` | | ✅ |
|
|
29
|
-
| `$spacing-05` | | ✅ |
|
|
30
|
-
| `$spacing-06` | | ✅ |
|
|
31
|
-
| `$spacing-07` | | ✅ |
|
|
32
|
-
| `$spacing-08` | | ✅ |
|
|
33
|
-
| `$spacing-09` | | ✅ |
|
|
34
|
-
| `$spacing-10` | | ✅ |
|
|
35
|
-
| `$spacing-11` | | ✅ |
|
|
36
|
-
| `$spacing-12` | | ✅ |
|
|
37
|
-
| `$spacing-13` | | ✅ |
|
|
38
|
-
| `$spacing ` | | |
|
|
39
|
-
| `$fluid-spacing-01` | | ✅ |
|
|
40
|
-
| `$fluid-spacing-02` | | ✅ |
|
|
41
|
-
| `$fluid-spacing-03` | | ✅ |
|
|
42
|
-
| `$fluid-spacing-04` | | ✅ |
|
|
43
|
-
| `$fluid-spacing ` | | |
|
|
44
|
-
| `$border-radius-00` | | ✅ |
|
|
45
|
-
| `$border-radius-02` | | ✅ |
|
|
46
|
-
| `$border-radius-04` | | ✅ |
|
|
47
|
-
| `$border-radius-08` | | ✅ |
|
|
48
|
-
| `$border-radius-16` | | ✅ |
|
|
49
|
-
| `$border-radius-24` | | ✅ |
|
|
50
|
-
| `$border-radius-max` | | ✅ |
|
|
51
|
-
| `@function em` | | |
|
|
52
|
-
| `@function rem` | | |
|
|
53
|
-
| `$base-font-size` | | ✅ |
|
|
54
|
-
|
|
55
|
-
### Configuration
|
|
56
|
-
|
|
57
|
-
You can configure parts of the `@carbon/layout` package that are `!default` with
|
|
58
|
-
Sass Modules. For example, you can change the `$base-font-size` by writing the
|
|
59
|
-
following:
|
|
60
|
-
|
|
61
|
-
```scss
|
|
62
|
-
@use '@carbon/layout' with (
|
|
63
|
-
$base-font-size: 18px
|
|
64
|
-
);
|
|
65
|
-
```
|