@carbon/elements 10.27.0-rc.0 → 10.27.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 CHANGED
@@ -71,12 +71,6 @@ With `@carbon/elements`, you can also import `colors`:
71
71
  import { colors } from '@carbon/elements';
72
72
  ```
73
73
 
74
- ## 📖 API Documentation
75
-
76
- If you're looking for `@carbon/elements` API documentation, check out:
77
-
78
- - [Sass](./docs/sass.md)
79
-
80
74
  ## 🙌 Contributing
81
75
 
82
76
  We're always looking for contributors to help us fix bugs, build new features,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@carbon/elements",
3
3
  "description": "A collection of design elements in code for the IBM Design Language",
4
- "version": "10.27.0-rc.0",
4
+ "version": "10.27.0",
5
5
  "license": "Apache-2.0",
6
6
  "main": "lib/index.js",
7
7
  "module": "es/index.js",
@@ -31,25 +31,25 @@
31
31
  "access": "public"
32
32
  },
33
33
  "scripts": {
34
- "build": "yarn clean && carbon-cli bundle src/index.js --name CarbonElements && node tasks/build.js && carbon-cli check \"scss/*.scss\" && carbon-cli sassdoc \"scss/**/*.scss\" -i \"**/{_inlined,vendor}/**\"",
34
+ "build": "yarn clean && carbon-cli bundle src/index.js --name CarbonElements && node tasks/build.js && carbon-cli check \"scss/*.scss\"",
35
35
  "clean": "rimraf es lib umd && node tasks/clean.js"
36
36
  },
37
37
  "dependencies": {
38
- "@carbon/colors": "^10.20.0-rc.0",
39
- "@carbon/grid": "^10.20.0-rc.0",
40
- "@carbon/icons": "^10.25.0-rc.0",
41
- "@carbon/import-once": "^10.5.0",
42
- "@carbon/layout": "^10.18.0-rc.0",
43
- "@carbon/motion": "^10.13.0-rc.0",
44
- "@carbon/themes": "^10.27.0-rc.0",
45
- "@carbon/type": "^10.21.0-rc.0"
38
+ "@carbon/colors": "^10.20.0",
39
+ "@carbon/grid": "^10.20.0",
40
+ "@carbon/icons": "^10.25.0",
41
+ "@carbon/import-once": "^10.6.0",
42
+ "@carbon/layout": "^10.18.0",
43
+ "@carbon/motion": "^10.13.0",
44
+ "@carbon/themes": "^10.27.0",
45
+ "@carbon/type": "^10.21.0"
46
46
  },
47
47
  "devDependencies": {
48
- "@carbon/cli": "^10.19.0-rc.0",
48
+ "@carbon/cli": "^10.19.0",
49
49
  "fs-extra": "^8.1.0",
50
50
  "klaw-sync": "^6.0.0",
51
51
  "replace-in-file": "^3.4.2",
52
52
  "rimraf": "^3.0.0"
53
53
  },
54
- "gitHead": "f20d953bfdd69fd024f2b202fd7e62f3139d431c"
54
+ "gitHead": "79db5535fee7f58e0fe21bac154b638cd17f659e"
55
55
  }
@@ -26,12 +26,12 @@ $fluid-spacing-03: 5vw !default;
26
26
  /// @group @carbon/layout
27
27
  $fluid-spacing-04: 10vw !default;
28
28
 
29
- /// @type List
29
+ /// @type Map
30
30
  /// @access public
31
31
  /// @group @carbon/layout
32
32
  $fluid-spacing: (
33
- $fluid-spacing-01,
34
- $fluid-spacing-02,
35
- $fluid-spacing-03,
36
- $fluid-spacing-04
33
+ fluid-spacing-01: $fluid-spacing-01,
34
+ fluid-spacing-02: $fluid-spacing-02,
35
+ fluid-spacing-03: $fluid-spacing-03,
36
+ fluid-spacing-04: $fluid-spacing-04,
37
37
  );
@@ -66,20 +66,20 @@ $spacing-11: 5rem !default;
66
66
  /// @group @carbon/layout
67
67
  $spacing-12: 6rem !default;
68
68
 
69
- /// @type List
69
+ /// @type Map
70
70
  /// @access public
71
71
  /// @group @carbon/layout
72
72
  $spacing: (
73
- $spacing-01,
74
- $spacing-02,
75
- $spacing-03,
76
- $spacing-04,
77
- $spacing-05,
78
- $spacing-06,
79
- $spacing-07,
80
- $spacing-08,
81
- $spacing-09,
82
- $spacing-10,
83
- $spacing-11,
84
- $spacing-12
73
+ spacing-01: $spacing-01,
74
+ spacing-02: $spacing-02,
75
+ spacing-03: $spacing-03,
76
+ spacing-04: $spacing-04,
77
+ spacing-05: $spacing-05,
78
+ spacing-06: $spacing-06,
79
+ spacing-07: $spacing-07,
80
+ spacing-08: $spacing-08,
81
+ spacing-09: $spacing-09,
82
+ spacing-10: $spacing-10,
83
+ spacing-11: $spacing-11,
84
+ spacing-12: $spacing-12,
85
85
  );
@@ -26,12 +26,12 @@ $fluid-spacing-03: 5vw !default;
26
26
  /// @group @carbon/layout
27
27
  $fluid-spacing-04: 10vw !default;
28
28
 
29
- /// @type List
29
+ /// @type Map
30
30
  /// @access public
31
31
  /// @group @carbon/layout
32
32
  $fluid-spacing: (
33
- $fluid-spacing-01,
34
- $fluid-spacing-02,
35
- $fluid-spacing-03,
36
- $fluid-spacing-04
33
+ fluid-spacing-01: $fluid-spacing-01,
34
+ fluid-spacing-02: $fluid-spacing-02,
35
+ fluid-spacing-03: $fluid-spacing-03,
36
+ fluid-spacing-04: $fluid-spacing-04,
37
37
  );
@@ -66,20 +66,20 @@ $spacing-11: 5rem !default;
66
66
  /// @group @carbon/layout
67
67
  $spacing-12: 6rem !default;
68
68
 
69
- /// @type List
69
+ /// @type Map
70
70
  /// @access public
71
71
  /// @group @carbon/layout
72
72
  $spacing: (
73
- $spacing-01,
74
- $spacing-02,
75
- $spacing-03,
76
- $spacing-04,
77
- $spacing-05,
78
- $spacing-06,
79
- $spacing-07,
80
- $spacing-08,
81
- $spacing-09,
82
- $spacing-10,
83
- $spacing-11,
84
- $spacing-12
73
+ spacing-01: $spacing-01,
74
+ spacing-02: $spacing-02,
75
+ spacing-03: $spacing-03,
76
+ spacing-04: $spacing-04,
77
+ spacing-05: $spacing-05,
78
+ spacing-06: $spacing-06,
79
+ spacing-07: $spacing-07,
80
+ spacing-08: $spacing-08,
81
+ spacing-09: $spacing-09,
82
+ spacing-10: $spacing-10,
83
+ spacing-11: $spacing-11,
84
+ spacing-12: $spacing-12,
85
85
  );
@@ -0,0 +1,50 @@
1
+ //
2
+ // Copyright IBM Corp. 2018, 2018
3
+ //
4
+ // This source code is licensed under the Apache-2.0 license found in the
5
+ // LICENSE file in the root directory of this source tree.
6
+ //
7
+
8
+ @use 'sass:map';
9
+ @use 'sass:meta';
10
+ @use 'themes';
11
+
12
+ $theme: themes.$white !default;
13
+ $-custom-property-prefix: 'cds';
14
+
15
+ /// @access public
16
+ /// @group @carbon/themes
17
+ @mixin theme($active-theme: $theme) {
18
+ $parent-theme: $theme;
19
+ $theme: $active-theme !global;
20
+
21
+ @each $token, $value in $theme {
22
+ @include -custom-property($token, $value);
23
+ }
24
+
25
+ @content;
26
+
27
+ $theme: $parent-theme !global;
28
+ }
29
+
30
+ /// @access public
31
+ /// @group @carbon/themes
32
+ @mixin set($active-theme) {
33
+ $theme: $active-theme !global;
34
+ }
35
+
36
+ /// @access private
37
+ /// @group @carbon/themes
38
+ @mixin -custom-property($name, $value, $prefix: $-custom-property-prefix) {
39
+ @if meta.type-of($value) == map {
40
+ @each $property, $property-value in $value {
41
+ // Only support one-level of depth for values that are maps. This is to
42
+ // avoid bringing properties like `breakpoints` on type tokens
43
+ @if type-of($property-value) != map {
44
+ @include -custom-property('#{$name}-#{$property}', $property-value);
45
+ }
46
+ }
47
+ } @else {
48
+ --#{$prefix}-#{$name}: #{$value};
49
+ }
50
+ }
@@ -0,0 +1,8 @@
1
+ //
2
+ // Copyright IBM Corp. 2018, 2018
3
+ //
4
+ // This source code is licensed under the Apache-2.0 license found in the
5
+ // LICENSE file in the root directory of this source tree.
6
+ //
7
+
8
+ @forward 'generated/themes';
@@ -0,0 +1,18 @@
1
+ //
2
+ // Copyright IBM Corp. 2018, 2018
3
+ //
4
+ // This source code is licensed under the Apache-2.0 license found in the
5
+ // LICENSE file in the root directory of this source tree.
6
+ //
7
+
8
+ @use 'sass:map';
9
+
10
+ /// @access private
11
+ /// @group @carbon/themes
12
+ @function merge($map, $maps...) {
13
+ $result: $map;
14
+ @each $map in $maps {
15
+ $result: map.merge($result, $map);
16
+ }
17
+ @return $result;
18
+ }
@@ -0,0 +1,244 @@
1
+ // Code generated by @carbon/themes. DO NOT EDIT.
2
+ //
3
+ // Copyright IBM Corp. 2018, 2019
4
+ //
5
+ // This source code is licensed under the Apache-2.0 license found in the
6
+ // LICENSE file in the root directory of this source tree.
7
+ //
8
+
9
+ @use 'sass:map';
10
+ @use '@carbon/layout';
11
+ @use '@carbon/type';
12
+ @use '../utilities';
13
+
14
+ $white: utilities.merge(
15
+ layout.$spacing,
16
+ layout.$fluid-spacing,
17
+ type.$tokens,
18
+ (
19
+ interactive-01: #0f62fe,
20
+ interactive-02: #393939,
21
+ interactive-03: #0f62fe,
22
+ interactive-04: #0f62fe,
23
+ ui-background: #ffffff,
24
+ ui-01: #f4f4f4,
25
+ ui-02: #ffffff,
26
+ ui-03: #e0e0e0,
27
+ ui-04: #8d8d8d,
28
+ ui-05: #161616,
29
+ text-01: #161616,
30
+ text-02: #525252,
31
+ text-03: #a8a8a8,
32
+ text-04: #ffffff,
33
+ text-05: #6f6f6f,
34
+ text-error: #da1e28,
35
+ icon-01: #161616,
36
+ icon-02: #525252,
37
+ icon-03: #ffffff,
38
+ link-01: #0f62fe,
39
+ inverse-link: #78a9ff,
40
+ field-01: #f4f4f4,
41
+ field-02: #ffffff,
42
+ inverse-01: #ffffff,
43
+ inverse-02: #393939,
44
+ support-01: #da1e28,
45
+ support-02: #24a148,
46
+ support-03: #f1c21b,
47
+ support-04: #0043ce,
48
+ inverse-support-01: #fa4d56,
49
+ inverse-support-02: #42be65,
50
+ inverse-support-03: #f1c21b,
51
+ inverse-support-04: #4589ff,
52
+ overlay-01: rgba(22, 22, 22, 0.5),
53
+ danger-01: #da1e28,
54
+ danger-02: #da1e28,
55
+ focus: #0f62fe,
56
+ inverse-focus-ui: #ffffff,
57
+ hover-primary: #0353e9,
58
+ active-primary: #002d9c,
59
+ hover-primary-text: #0043ce,
60
+ hover-secondary: #4c4c4c,
61
+ active-secondary: #6f6f6f,
62
+ hover-tertiary: #0353e9,
63
+ active-tertiary: #002d9c,
64
+ hover-ui: #e5e5e5,
65
+ hover-light-ui: #e5e5e5,
66
+ active-ui: #c6c6c6,
67
+ active-light-ui: #c6c6c6,
68
+ selected-ui: #e0e0e0,
69
+ selected-light-ui: #e0e0e0,
70
+ inverse-hover-ui: #4c4c4c,
71
+ hover-selected-ui: #cacaca,
72
+ hover-danger: #b81921,
73
+ active-danger: #750e13,
74
+ hover-row: #e5e5e5,
75
+ visited-link: #8a3ffc,
76
+ disabled-01: #f4f4f4,
77
+ disabled-02: #c6c6c6,
78
+ disabled-03: #8d8d8d,
79
+ highlight: #d0e2ff,
80
+ decorative-01: #e0e0e0,
81
+ button-separator: #e0e0e0,
82
+ skeleton-01: #e5e5e5,
83
+ skeleton-02: #c6c6c6,
84
+ brand-01: #0f62fe,
85
+ brand-02: #393939,
86
+ brand-03: #0f62fe,
87
+ active-01: #c6c6c6,
88
+ hover-field: #e5e5e5,
89
+ danger: #da1e28,
90
+ )
91
+ ) !default;
92
+
93
+ /// Carbon's g10 color theme
94
+ /// @type Map
95
+ /// @access public
96
+ /// @group @carbon/themes
97
+ $g10: map.merge(
98
+ $white,
99
+ (
100
+ ui-background: #f4f4f4,
101
+ ui-01: #ffffff,
102
+ ui-02: #f4f4f4,
103
+ field-01: #ffffff,
104
+ field-02: #f4f4f4,
105
+ disabled-01: #ffffff,
106
+ highlight: #edf5ff,
107
+ )
108
+ ) !default;
109
+
110
+ /// Carbon's g90 color theme
111
+ /// @type Map
112
+ /// @access public
113
+ /// @group @carbon/themes
114
+ $g90: map.merge(
115
+ $white,
116
+ (
117
+ interactive-02: #6f6f6f,
118
+ interactive-03: #ffffff,
119
+ interactive-04: #4589ff,
120
+ ui-background: #262626,
121
+ ui-01: #393939,
122
+ ui-02: #525252,
123
+ ui-03: #525252,
124
+ ui-05: #f4f4f4,
125
+ text-01: #f4f4f4,
126
+ text-02: #c6c6c6,
127
+ text-03: #6f6f6f,
128
+ text-05: #8d8d8d,
129
+ text-error: #ffb3b8,
130
+ icon-01: #f4f4f4,
131
+ icon-02: #c6c6c6,
132
+ link-01: #78a9ff,
133
+ inverse-link: #0f62fe,
134
+ field-01: #393939,
135
+ field-02: #525252,
136
+ inverse-01: #161616,
137
+ inverse-02: #f4f4f4,
138
+ support-01: #ff8389,
139
+ support-02: #42be65,
140
+ support-04: #4589ff,
141
+ inverse-support-01: #da1e28,
142
+ inverse-support-02: #24a148,
143
+ inverse-support-04: #0f62fe,
144
+ overlay-01: rgba(22, 22, 22, 0.7),
145
+ danger-02: #ff8389,
146
+ focus: #ffffff,
147
+ inverse-focus-ui: #0f62fe,
148
+ hover-primary-text: #a6c8ff,
149
+ hover-secondary: #606060,
150
+ active-secondary: #393939,
151
+ hover-tertiary: #f4f4f4,
152
+ active-tertiary: #c6c6c6,
153
+ hover-ui: #4c4c4c,
154
+ hover-light-ui: #656565,
155
+ active-ui: #6f6f6f,
156
+ active-light-ui: #8d8d8d,
157
+ selected-ui: #525252,
158
+ selected-light-ui: #6f6f6f,
159
+ inverse-hover-ui: #e5e5e5,
160
+ hover-selected-ui: #656565,
161
+ hover-row: #4c4c4c,
162
+ visited-link: #be95ff,
163
+ disabled-01: #393939,
164
+ disabled-02: #6f6f6f,
165
+ disabled-03: #a8a8a8,
166
+ highlight: #0043ce,
167
+ decorative-01: #6f6f6f,
168
+ button-separator: #161616,
169
+ skeleton-01: #353535,
170
+ skeleton-02: #525252,
171
+ brand-02: #6f6f6f,
172
+ brand-03: #ffffff,
173
+ active-01: #6f6f6f,
174
+ hover-field: #4c4c4c,
175
+ )
176
+ ) !default;
177
+
178
+ /// Carbon's g100 color theme
179
+ /// @type Map
180
+ /// @access public
181
+ /// @group @carbon/themes
182
+ $g100: map.merge(
183
+ $white,
184
+ (
185
+ interactive-02: #6f6f6f,
186
+ interactive-03: #ffffff,
187
+ interactive-04: #4589ff,
188
+ ui-background: #161616,
189
+ ui-01: #262626,
190
+ ui-02: #393939,
191
+ ui-03: #393939,
192
+ ui-04: #6f6f6f,
193
+ ui-05: #f4f4f4,
194
+ text-01: #f4f4f4,
195
+ text-02: #c6c6c6,
196
+ text-03: #6f6f6f,
197
+ text-05: #8d8d8d,
198
+ text-error: #ff8389,
199
+ icon-01: #f4f4f4,
200
+ icon-02: #c6c6c6,
201
+ link-01: #78a9ff,
202
+ inverse-link: #0f62fe,
203
+ field-01: #262626,
204
+ field-02: #393939,
205
+ inverse-01: #161616,
206
+ inverse-02: #f4f4f4,
207
+ support-01: #fa4d56,
208
+ support-02: #42be65,
209
+ support-04: #4589ff,
210
+ inverse-support-01: #da1e28,
211
+ inverse-support-02: #24a148,
212
+ inverse-support-04: #0f62fe,
213
+ overlay-01: rgba(22, 22, 22, 0.7),
214
+ danger-02: #fa4d56,
215
+ focus: #ffffff,
216
+ inverse-focus-ui: #0f62fe,
217
+ hover-primary-text: #a6c8ff,
218
+ hover-secondary: #606060,
219
+ active-secondary: #393939,
220
+ hover-tertiary: #f4f4f4,
221
+ active-tertiary: #c6c6c6,
222
+ hover-ui: #353535,
223
+ hover-light-ui: #4c4c4c,
224
+ active-ui: #525252,
225
+ active-light-ui: #6f6f6f,
226
+ selected-ui: #393939,
227
+ selected-light-ui: #525252,
228
+ inverse-hover-ui: #e5e5e5,
229
+ hover-selected-ui: #4c4c4c,
230
+ hover-row: #353535,
231
+ visited-link: #be95ff,
232
+ disabled-01: #262626,
233
+ disabled-02: #525252,
234
+ highlight: #002d9c,
235
+ decorative-01: #525252,
236
+ button-separator: #161616,
237
+ skeleton-01: #353535,
238
+ skeleton-02: #393939,
239
+ brand-02: #6f6f6f,
240
+ brand-03: #ffffff,
241
+ active-01: #525252,
242
+ hover-field: #353535,
243
+ )
244
+ ) !default;
@@ -26,12 +26,12 @@ $fluid-spacing-03: 5vw !default;
26
26
  /// @group @carbon/layout
27
27
  $fluid-spacing-04: 10vw !default;
28
28
 
29
- /// @type List
29
+ /// @type Map
30
30
  /// @access public
31
31
  /// @group @carbon/layout
32
32
  $fluid-spacing: (
33
- $fluid-spacing-01,
34
- $fluid-spacing-02,
35
- $fluid-spacing-03,
36
- $fluid-spacing-04
33
+ fluid-spacing-01: $fluid-spacing-01,
34
+ fluid-spacing-02: $fluid-spacing-02,
35
+ fluid-spacing-03: $fluid-spacing-03,
36
+ fluid-spacing-04: $fluid-spacing-04,
37
37
  );
@@ -66,20 +66,20 @@ $spacing-11: 5rem !default;
66
66
  /// @group @carbon/layout
67
67
  $spacing-12: 6rem !default;
68
68
 
69
- /// @type List
69
+ /// @type Map
70
70
  /// @access public
71
71
  /// @group @carbon/layout
72
72
  $spacing: (
73
- $spacing-01,
74
- $spacing-02,
75
- $spacing-03,
76
- $spacing-04,
77
- $spacing-05,
78
- $spacing-06,
79
- $spacing-07,
80
- $spacing-08,
81
- $spacing-09,
82
- $spacing-10,
83
- $spacing-11,
84
- $spacing-12
73
+ spacing-01: $spacing-01,
74
+ spacing-02: $spacing-02,
75
+ spacing-03: $spacing-03,
76
+ spacing-04: $spacing-04,
77
+ spacing-05: $spacing-05,
78
+ spacing-06: $spacing-06,
79
+ spacing-07: $spacing-07,
80
+ spacing-08: $spacing-08,
81
+ spacing-09: $spacing-09,
82
+ spacing-10: $spacing-10,
83
+ spacing-11: $spacing-11,
84
+ spacing-12: $spacing-12,
85
85
  );