@carbon/type 10.26.0 → 10.28.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/es/index.js +63 -36
- package/lib/index.js +65 -35
- package/package.json +4 -4
- package/scss/_inlined/_reset.scss +2 -2
- package/scss/_inlined/_styles.scss +33 -0
- package/scss/_inlined/font-face/_mono.scss +72 -72
- package/scss/_inlined/font-face/_sans-condensed.scss +42 -42
- package/scss/_inlined/font-face/_sans.scss +84 -84
- package/scss/_inlined/font-face/_serif.scss +72 -72
- package/scss/_reset.scss +2 -2
- package/scss/_styles.scss +33 -0
- package/scss/font-face/_mono.scss +72 -72
- package/scss/font-face/_sans-condensed.scss +42 -42
- package/scss/font-face/_sans.scss +84 -84
- package/scss/font-face/_serif.scss +72 -72
- package/scss/modules/_reset.scss +3 -3
- package/src/__tests__/__snapshots__/styles-test.js.snap +20 -0
- package/src/__tests__/exports-test.js +3 -0
- package/src/styles.js +20 -0
- package/src/tokens.js +6 -0
- package/umd/index.js +65 -35
package/umd/index.js
CHANGED
|
@@ -146,45 +146,18 @@
|
|
|
146
146
|
|
|
147
147
|
var scale = [12, 14, 16, 18, 20, 24, 28, 32, 36, 42, 48, 54, 60, 68, 76, 84, 92, 102, 112, 122, 132, 144, 156];
|
|
148
148
|
|
|
149
|
-
function _typeof(obj) {
|
|
150
|
-
"@babel/helpers - typeof";
|
|
151
|
-
|
|
152
|
-
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
|
|
153
|
-
_typeof = function (obj) {
|
|
154
|
-
return typeof obj;
|
|
155
|
-
};
|
|
156
|
-
} else {
|
|
157
|
-
_typeof = function (obj) {
|
|
158
|
-
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
159
|
-
};
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
return _typeof(obj);
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
function _defineProperty(obj, key, value) {
|
|
166
|
-
if (key in obj) {
|
|
167
|
-
Object.defineProperty(obj, key, {
|
|
168
|
-
value: value,
|
|
169
|
-
enumerable: true,
|
|
170
|
-
configurable: true,
|
|
171
|
-
writable: true
|
|
172
|
-
});
|
|
173
|
-
} else {
|
|
174
|
-
obj[key] = value;
|
|
175
|
-
}
|
|
176
|
-
|
|
177
|
-
return obj;
|
|
178
|
-
}
|
|
179
|
-
|
|
180
149
|
function ownKeys(object, enumerableOnly) {
|
|
181
150
|
var keys = Object.keys(object);
|
|
182
151
|
|
|
183
152
|
if (Object.getOwnPropertySymbols) {
|
|
184
153
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
154
|
+
|
|
155
|
+
if (enumerableOnly) {
|
|
156
|
+
symbols = symbols.filter(function (sym) {
|
|
157
|
+
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
158
|
+
});
|
|
159
|
+
}
|
|
160
|
+
|
|
188
161
|
keys.push.apply(keys, symbols);
|
|
189
162
|
}
|
|
190
163
|
|
|
@@ -211,6 +184,37 @@
|
|
|
211
184
|
return target;
|
|
212
185
|
}
|
|
213
186
|
|
|
187
|
+
function _typeof(obj) {
|
|
188
|
+
"@babel/helpers - typeof";
|
|
189
|
+
|
|
190
|
+
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
|
|
191
|
+
_typeof = function (obj) {
|
|
192
|
+
return typeof obj;
|
|
193
|
+
};
|
|
194
|
+
} else {
|
|
195
|
+
_typeof = function (obj) {
|
|
196
|
+
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
197
|
+
};
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
return _typeof(obj);
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
function _defineProperty(obj, key, value) {
|
|
204
|
+
if (key in obj) {
|
|
205
|
+
Object.defineProperty(obj, key, {
|
|
206
|
+
value: value,
|
|
207
|
+
enumerable: true,
|
|
208
|
+
configurable: true,
|
|
209
|
+
writable: true
|
|
210
|
+
});
|
|
211
|
+
} else {
|
|
212
|
+
obj[key] = value;
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
return obj;
|
|
216
|
+
}
|
|
217
|
+
|
|
214
218
|
function _objectWithoutPropertiesLoose(source, excluded) {
|
|
215
219
|
if (source == null) return {};
|
|
216
220
|
var target = {};
|
|
@@ -253,17 +257,34 @@
|
|
|
253
257
|
lineHeight: 1.34,
|
|
254
258
|
letterSpacing: layout.px(0.32)
|
|
255
259
|
};
|
|
260
|
+
var caption02$1 = {
|
|
261
|
+
fontSize: layout.rem(scale[1]),
|
|
262
|
+
fontWeight: fontWeights.regular,
|
|
263
|
+
lineHeight: 1.29,
|
|
264
|
+
letterSpacing: layout.px(0.32)
|
|
265
|
+
};
|
|
256
266
|
var label01$1 = {
|
|
257
267
|
fontSize: layout.rem(scale[0]),
|
|
258
268
|
fontWeight: fontWeights.regular,
|
|
259
269
|
lineHeight: 1.34,
|
|
260
270
|
letterSpacing: layout.px(0.32)
|
|
261
271
|
};
|
|
272
|
+
var label02$1 = {
|
|
273
|
+
fontSize: layout.rem(scale[1]),
|
|
274
|
+
fontWeight: fontWeights.regular,
|
|
275
|
+
lineHeight: 1.29,
|
|
276
|
+
letterSpacing: layout.px(0.32)
|
|
277
|
+
};
|
|
262
278
|
var helperText01$1 = {
|
|
263
279
|
fontSize: layout.rem(scale[0]),
|
|
264
280
|
lineHeight: 1.34,
|
|
265
281
|
letterSpacing: layout.px(0.32)
|
|
266
282
|
};
|
|
283
|
+
var helperText02$1 = {
|
|
284
|
+
fontSize: layout.rem(scale[1]),
|
|
285
|
+
lineHeight: 1.29,
|
|
286
|
+
letterSpacing: layout.px(0.32)
|
|
287
|
+
};
|
|
267
288
|
var bodyShort01$1 = {
|
|
268
289
|
fontSize: layout.rem(scale[1]),
|
|
269
290
|
fontWeight: fontWeights.regular,
|
|
@@ -616,8 +637,11 @@
|
|
|
616
637
|
var styles = /*#__PURE__*/Object.freeze({
|
|
617
638
|
__proto__: null,
|
|
618
639
|
caption01: caption01$1,
|
|
640
|
+
caption02: caption02$1,
|
|
619
641
|
label01: label01$1,
|
|
642
|
+
label02: label02$1,
|
|
620
643
|
helperText01: helperText01$1,
|
|
644
|
+
helperText02: helperText02$1,
|
|
621
645
|
bodyShort01: bodyShort01$1,
|
|
622
646
|
bodyLong01: bodyLong01$1,
|
|
623
647
|
bodyShort02: bodyShort02$1,
|
|
@@ -723,8 +747,11 @@
|
|
|
723
747
|
*/
|
|
724
748
|
// Unstable tokens
|
|
725
749
|
var caption01 = 'caption01';
|
|
750
|
+
var caption02 = 'caption02';
|
|
726
751
|
var label01 = 'label01';
|
|
752
|
+
var label02 = 'label02';
|
|
727
753
|
var helperText01 = 'helperText01';
|
|
754
|
+
var helperText02 = 'helperText02';
|
|
728
755
|
var bodyShort01 = 'bodyShort01';
|
|
729
756
|
var bodyLong01 = 'bodyLong01';
|
|
730
757
|
var bodyShort02 = 'bodyShort02';
|
|
@@ -753,13 +780,14 @@
|
|
|
753
780
|
var display02 = 'display02';
|
|
754
781
|
var display03 = 'display03';
|
|
755
782
|
var display04 = 'display04';
|
|
756
|
-
var unstable_tokens = [caption01, label01, helperText01, bodyShort01, bodyLong01, bodyShort02, bodyLong02, code01, code02, heading01, productiveHeading01, heading02, productiveHeading02, productiveHeading03, productiveHeading04, productiveHeading05, productiveHeading06, productiveHeading07, expressiveHeading01, expressiveHeading02, expressiveHeading03, expressiveHeading04, expressiveHeading05, expressiveHeading06, expressiveParagraph01, quotation01, quotation02, display01, display02, display03, display04];
|
|
783
|
+
var unstable_tokens = [caption01, caption02, label01, label02, helperText01, helperText02, bodyShort01, bodyLong01, bodyShort02, bodyLong02, code01, code02, heading01, productiveHeading01, heading02, productiveHeading02, productiveHeading03, productiveHeading04, productiveHeading05, productiveHeading06, productiveHeading07, expressiveHeading01, expressiveHeading02, expressiveHeading03, expressiveHeading04, expressiveHeading05, expressiveHeading06, expressiveParagraph01, quotation01, quotation02, display01, display02, display03, display04];
|
|
757
784
|
|
|
758
785
|
exports.bodyLong01 = bodyLong01$1;
|
|
759
786
|
exports.bodyLong02 = bodyLong02$1;
|
|
760
787
|
exports.bodyShort01 = bodyShort01$1;
|
|
761
788
|
exports.bodyShort02 = bodyShort02$1;
|
|
762
789
|
exports.caption01 = caption01$1;
|
|
790
|
+
exports.caption02 = caption02$1;
|
|
763
791
|
exports.code01 = code01$1;
|
|
764
792
|
exports.code02 = code02$1;
|
|
765
793
|
exports.display01 = display01$1;
|
|
@@ -782,7 +810,9 @@
|
|
|
782
810
|
exports.heading01 = heading01$1;
|
|
783
811
|
exports.heading02 = heading02$1;
|
|
784
812
|
exports.helperText01 = helperText01$1;
|
|
813
|
+
exports.helperText02 = helperText02$1;
|
|
785
814
|
exports.label01 = label01$1;
|
|
815
|
+
exports.label02 = label02$1;
|
|
786
816
|
exports.print = print;
|
|
787
817
|
exports.productiveHeading01 = productiveHeading01$1;
|
|
788
818
|
exports.productiveHeading02 = productiveHeading02$1;
|