@carbon/styles 0.10.0-rc.0 → 0.12.0-rc.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/docs/sass.md +0 -17
- package/index.scss +3 -1
- package/package.json +10 -10
- package/scss/_config.scss +18 -11
- package/scss/_layer.scss +112 -0
- package/scss/_theme.scss +0 -69
- package/scss/_zone.scss +2 -0
- package/scss/components/button/_tokens.scss +2 -2
- package/scss/components/date-picker/_date-picker.scss +1 -1
- package/scss/components/list-box/_list-box.scss +2 -2
- package/scss/components/radio-button/_radio-button.scss +3 -3
- package/scss/components/tabs/_tabs.scss +86 -103
- package/scss/components/tag/_tokens.scss +60 -60
- package/scss/fonts/README.md +148 -0
- package/scss/fonts/_index.scss +75 -0
- package/scss/fonts/_mono.scss +153 -0
- package/scss/fonts/_sans-arabic.scss +151 -0
- package/scss/fonts/_sans-devanagari.scss +151 -0
- package/scss/fonts/_sans-hebrew.scss +151 -0
- package/scss/fonts/_sans-thai-looped.scss +151 -0
- package/scss/fonts/_sans-thai.scss +151 -0
- package/scss/fonts/_sans.scss +153 -0
- package/scss/fonts/_serif.scss +153 -0
- package/scss/fonts/_src.scss +102 -0
- package/scss/fonts/unicode/_index.scss +124 -0
- package/scss/_font-face.scss +0 -13
- package/scss/utilities/_layer-set.scss +0 -38
|
@@ -0,0 +1,124 @@
|
|
|
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
|
+
/// All available unicode ranges where the keys are unicode range names and the
|
|
11
|
+
/// value is the list of unicode ranges that are applicable
|
|
12
|
+
/// @type {List}
|
|
13
|
+
$ranges: (
|
|
14
|
+
Cyrillic: (
|
|
15
|
+
'U+0400-045F',
|
|
16
|
+
'U+0472-0473',
|
|
17
|
+
'U+0490-049D',
|
|
18
|
+
'U+04A0-04A5',
|
|
19
|
+
'U+04AA-04AB',
|
|
20
|
+
'U+04AE-04B3',
|
|
21
|
+
'U+04B6-04BB',
|
|
22
|
+
'U+04C0-04C2',
|
|
23
|
+
'U+04CF-04D9',
|
|
24
|
+
'U+04DC-04DF',
|
|
25
|
+
'U+04E2-04E9',
|
|
26
|
+
'U+04EE-04F5',
|
|
27
|
+
'U+04F8-04F9',
|
|
28
|
+
),
|
|
29
|
+
Greek: (
|
|
30
|
+
'U+0384-038A',
|
|
31
|
+
'U+038C',
|
|
32
|
+
'U+038E-03A1',
|
|
33
|
+
'U+03A3-03CE',
|
|
34
|
+
),
|
|
35
|
+
Latin1: (
|
|
36
|
+
'U+0000',
|
|
37
|
+
'U+000D',
|
|
38
|
+
'U+0020-007E',
|
|
39
|
+
'U+00A0-00A3',
|
|
40
|
+
'U+00A4-00FF',
|
|
41
|
+
'U+0131',
|
|
42
|
+
'U+0152-0153',
|
|
43
|
+
'U+02C6',
|
|
44
|
+
'U+02DA',
|
|
45
|
+
'U+02DC',
|
|
46
|
+
'U+2013-2014',
|
|
47
|
+
'U+2018-201A',
|
|
48
|
+
'U+201C-201E',
|
|
49
|
+
'U+2020-2022',
|
|
50
|
+
'U+2026',
|
|
51
|
+
'U+2030',
|
|
52
|
+
'U+2039-203A',
|
|
53
|
+
'U+2044',
|
|
54
|
+
'U+2074',
|
|
55
|
+
'U+20AC',
|
|
56
|
+
'U+2122',
|
|
57
|
+
'U+2212',
|
|
58
|
+
'U+FB01-FB02',
|
|
59
|
+
),
|
|
60
|
+
Latin2: (
|
|
61
|
+
'U+0100-024F',
|
|
62
|
+
'U+0259',
|
|
63
|
+
'U+1E00-1EFF',
|
|
64
|
+
'U+20A0-20AB',
|
|
65
|
+
'U+20AD-20CF',
|
|
66
|
+
'U+2C60-2C7F',
|
|
67
|
+
'U+A720-A7FF',
|
|
68
|
+
'U+FB01-FB02',
|
|
69
|
+
),
|
|
70
|
+
Latin3: (
|
|
71
|
+
'U+0102-0103',
|
|
72
|
+
'U+1EA0-1EF9',
|
|
73
|
+
'U+20AB',
|
|
74
|
+
),
|
|
75
|
+
Pi: (
|
|
76
|
+
'U+0E3F',
|
|
77
|
+
'U+2032-2033',
|
|
78
|
+
'U+2070',
|
|
79
|
+
'U+2075-2079',
|
|
80
|
+
'U+2080-2081',
|
|
81
|
+
'U+2083',
|
|
82
|
+
'U+2085-2089',
|
|
83
|
+
'U+2113',
|
|
84
|
+
'U+2116',
|
|
85
|
+
'U+2126',
|
|
86
|
+
'U+212E',
|
|
87
|
+
'U+2150-2151',
|
|
88
|
+
'U+2153-215E',
|
|
89
|
+
'U+2190-2199',
|
|
90
|
+
'U+21A9-21AA',
|
|
91
|
+
'U+21B0-21B3',
|
|
92
|
+
'U+21B6-21B7',
|
|
93
|
+
'U+21BA-21BB',
|
|
94
|
+
'U+21C4',
|
|
95
|
+
'U+21C6',
|
|
96
|
+
'U+2202',
|
|
97
|
+
'U+2206',
|
|
98
|
+
'U+220F',
|
|
99
|
+
'U+2211',
|
|
100
|
+
'U+221A',
|
|
101
|
+
'U+221E',
|
|
102
|
+
'U+222B',
|
|
103
|
+
'U+2248',
|
|
104
|
+
'U+2260',
|
|
105
|
+
'U+2264-2265',
|
|
106
|
+
'U+25CA',
|
|
107
|
+
'U+2713',
|
|
108
|
+
'U+274C',
|
|
109
|
+
'U+2B0E-2B11',
|
|
110
|
+
'U+EBE1-EBE7',
|
|
111
|
+
'U+ECE0',
|
|
112
|
+
'U+EFCC',
|
|
113
|
+
),
|
|
114
|
+
);
|
|
115
|
+
|
|
116
|
+
/// Retrieve the unicode range for a given unicode range name
|
|
117
|
+
/// @param {String} $name
|
|
118
|
+
/// @returns {List}
|
|
119
|
+
@function get-range($name) {
|
|
120
|
+
@if map.has-key($ranges, $name) {
|
|
121
|
+
@return map.get($ranges, $name);
|
|
122
|
+
}
|
|
123
|
+
@error 'Unable to find range with the name: #{$name}';
|
|
124
|
+
}
|
package/scss/_font-face.scss
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
@use 'config';
|
|
2
|
-
@use '@ibm/plex/default' as sans;
|
|
3
|
-
@use '@ibm/plex/mono' as mono;
|
|
4
|
-
@use '@ibm/plex/arabic' as arabic;
|
|
5
|
-
|
|
6
|
-
@if config.$css--font-face == true {
|
|
7
|
-
@include sans.all;
|
|
8
|
-
@include mono.all;
|
|
9
|
-
|
|
10
|
-
@if config.$css--plex-arabic == true {
|
|
11
|
-
@include arabic.all;
|
|
12
|
-
}
|
|
13
|
-
} ;
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright IBM Corp. 2021
|
|
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:list';
|
|
9
|
-
@use 'sass:meta';
|
|
10
|
-
@use '../config' as *;
|
|
11
|
-
@use './custom-property';
|
|
12
|
-
|
|
13
|
-
/// Define a map of layer sets, each set should have values for each layer in
|
|
14
|
-
/// the application. The key of this map is used for the CSS Custom Property
|
|
15
|
-
/// name whose value is updated as more layers are added.
|
|
16
|
-
/// @type {Map}
|
|
17
|
-
$layer-sets: () !default;
|
|
18
|
-
|
|
19
|
-
/// Emit the layer tokens defined in $layer-sets for the given $level
|
|
20
|
-
/// @param {Number} $level
|
|
21
|
-
@mixin -emit-layer-tokens($level) {
|
|
22
|
-
@each $key, $layer-set in $layer-sets {
|
|
23
|
-
$value: list.nth($layer-set, $level);
|
|
24
|
-
@include custom-property.declaration($key, $value);
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
:root {
|
|
29
|
-
@include -emit-layer-tokens(1);
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
.#{$prefix}--layer {
|
|
33
|
-
@include -emit-layer-tokens(2);
|
|
34
|
-
|
|
35
|
-
.#{$prefix}--layer {
|
|
36
|
-
@include -emit-layer-tokens(3);
|
|
37
|
-
}
|
|
38
|
-
}
|