@carbon/type 10.41.0 → 10.43.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 +73 -2
- package/lib/index.js +169 -98
- package/package.json +5 -5
- package/scss/_inlined/_reset.scss +1 -1
- package/scss/_inlined/_scale.scss +1 -1
- package/scss/_inlined/_styles.import.scss +3 -3
- package/scss/_inlined/_styles.scss +1 -1
- package/scss/_styles.import.scss +3 -3
- package/scss/modules/_font-family.scss +13 -11
- package/scss/modules/_scale.scss +2 -1
- package/scss/modules/_styles.scss +7 -11
- package/scss/vendor/@carbon/grid/12.scss +41 -0
- package/scss/vendor/@carbon/grid/_inlined/12.scss +41 -0
- package/scss/vendor/@carbon/grid/_inlined/_mixins.import.scss +431 -0
- package/scss/vendor/@carbon/grid/_inlined/_mixins.scss +415 -0
- package/scss/vendor/@carbon/grid/_inlined/_prefix.scss +12 -0
- package/scss/vendor/@carbon/grid/_mixins.import.scss +431 -0
- package/scss/vendor/@carbon/grid/_mixins.scss +415 -0
- package/scss/vendor/@carbon/grid/_prefix.scss +12 -0
- package/scss/vendor/@carbon/grid/grid.scss +10 -0
- package/scss/vendor/@carbon/grid/index.scss +10 -0
- package/scss/vendor/@carbon/{layout → grid}/modules/_breakpoint.scss +11 -45
- package/scss/vendor/@carbon/grid/modules/_config.scss +94 -0
- package/scss/vendor/@carbon/grid/modules/_css-grid.scss +470 -0
- package/scss/vendor/@carbon/grid/modules/_flex-grid.scss +363 -0
- package/scss/vendor/@carbon/grid/modules/_mixins.scss +336 -0
- package/scss/vendor/@carbon/grid/vendor/@carbon/import-once/import-once.scss +27 -0
- package/scss/vendor/@carbon/grid/vendor/@carbon/import-once/index.scss +8 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/_breakpoint.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/_convert.import.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/_convert.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/_key-height.import.scss +2 -2
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/_key-height.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/_mini-unit.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/_spacing.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/_utilities.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/generated/_container.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/generated/_fluid-spacing.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/generated/_icon-size.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/generated/_layout.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/generated/_size.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/generated/_spacing.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/index.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/layout.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/modules/_convert.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/modules/_spacing.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/modules/_utilities.scss +3 -3
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/modules/generated/_fluid-spacing.scss +0 -0
- package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/modules/generated/_spacing.scss +0 -0
- package/scss/vendor/@carbon/import-once/import-once.scss +1 -1
- package/umd/index.js +173 -100
|
@@ -0,0 +1,27 @@
|
|
|
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
|
+
/// Used by `exports` mixin to track which modules have been imported
|
|
9
|
+
/// @type Map
|
|
10
|
+
/// @access public
|
|
11
|
+
/// @group @carbon/import-once
|
|
12
|
+
$imported-modules: () !default;
|
|
13
|
+
|
|
14
|
+
/// Module export mixin that helps making sure a module is imported once and only once
|
|
15
|
+
/// @access public
|
|
16
|
+
/// @param {String} $name - Name of exported module
|
|
17
|
+
/// @param {Bool} $warn [false] - Warn when a module has been already imported
|
|
18
|
+
/// @content Declaration blocks to be imported
|
|
19
|
+
/// @group @carbon/import-once
|
|
20
|
+
@mixin exports($name, $warn: false) {
|
|
21
|
+
@if not(index($imported-modules, $name)) {
|
|
22
|
+
$imported-modules: append($imported-modules, $name) !global;
|
|
23
|
+
@content;
|
|
24
|
+
} @else if $warn == true {
|
|
25
|
+
@warn 'Module `#{$name}` has already been imported.';
|
|
26
|
+
}
|
|
27
|
+
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
|
|
22
22
|
@use 'sass:meta';
|
|
23
23
|
@use "sass:math";
|
|
24
|
-
@import 'breakpoint';
|
|
25
|
-
@import 'utilities';
|
|
24
|
+
@import 'breakpoint';
|
|
25
|
+
@import 'utilities';
|
|
26
26
|
|
|
27
27
|
/// Get the column width for a given breakpoint
|
|
28
28
|
/// @param {String} $breakpoint
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/generated/_fluid-spacing.scss
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
/// @group @carbon/layout
|
|
15
15
|
@function map-deep-get($map, $keys...) {
|
|
16
16
|
@each $key in $keys {
|
|
17
|
-
$map: map
|
|
17
|
+
$map: map.get($map, $key);
|
|
18
18
|
}
|
|
19
19
|
@return $map;
|
|
20
20
|
}
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
/// @return {String} Desired value
|
|
27
27
|
/// @group @carbon/layout
|
|
28
28
|
@function key-by-index($map, $index) {
|
|
29
|
-
$keys: map
|
|
29
|
+
$keys: map.keys($map);
|
|
30
30
|
@return nth($keys, $index);
|
|
31
31
|
}
|
|
32
32
|
|
|
@@ -36,6 +36,6 @@
|
|
|
36
36
|
/// @return {*} Desired value
|
|
37
37
|
/// @group @carbon/layout
|
|
38
38
|
@function last-map-item($map) {
|
|
39
|
-
$total-length: length($map);
|
|
39
|
+
$total-length: list.length($map);
|
|
40
40
|
@return map-get($map, carbon--key-by-index($map, $total-length));
|
|
41
41
|
}
|
|
File without changes
|
package/scss/vendor/@carbon/{layout → grid/vendor/@carbon/layout}/modules/generated/_spacing.scss
RENAMED
|
File without changes
|
|
@@ -18,7 +18,7 @@ $imported-modules: () !default;
|
|
|
18
18
|
/// @content Declaration blocks to be imported
|
|
19
19
|
/// @group @carbon/import-once
|
|
20
20
|
@mixin exports($name, $warn: false) {
|
|
21
|
-
@if (index($imported-modules, $name)
|
|
21
|
+
@if not(index($imported-modules, $name)) {
|
|
22
22
|
$imported-modules: append($imported-modules, $name) !global;
|
|
23
23
|
@content;
|
|
24
24
|
} @else if $warn == true {
|