@zendeskgarden/react-theming 9.0.0-next.8 → 9.0.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/dist/esm/elements/ThemeProvider.js +1 -4
- package/dist/esm/elements/palette/index.js +183 -207
- package/dist/esm/elements/theme/index.js +40 -11
- package/dist/esm/index.js +2 -1
- package/dist/esm/utils/StyledBaseIcon.js +22 -0
- package/dist/esm/utils/arrowStyles.js +29 -40
- package/dist/esm/utils/getCheckeredBackground.js +40 -0
- package/dist/esm/utils/getColor.js +125 -24
- package/dist/esm/utils/menuStyles.js +23 -16
- package/dist/index.cjs.js +593 -448
- package/dist/typings/elements/ThemeProvider.d.ts +1 -6
- package/dist/typings/elements/palette/index.d.ts +0 -24
- package/dist/typings/index.d.ts +3 -2
- package/dist/typings/types/index.d.ts +10 -0
- package/dist/typings/utils/StyledBaseIcon.d.ts +8 -0
- package/dist/typings/utils/arrowStyles.d.ts +3 -16
- package/dist/typings/utils/getCheckeredBackground.d.ts +20 -0
- package/dist/typings/utils/getColor.d.ts +2 -3
- package/dist/typings/utils/getColorV8.d.ts +0 -1
- package/dist/typings/utils/menuStyles.d.ts +1 -1
- package/dist/typings/utils/useText.d.ts +1 -1
- package/package.json +6 -8
- package/LICENSE.md +0 -176
|
@@ -10,15 +10,12 @@ import DEFAULT_THEME from './theme/index.js';
|
|
|
10
10
|
|
|
11
11
|
const ThemeProvider = _ref => {
|
|
12
12
|
let {
|
|
13
|
-
theme,
|
|
13
|
+
theme = DEFAULT_THEME,
|
|
14
14
|
...other
|
|
15
15
|
} = _ref;
|
|
16
16
|
return React.createElement(ThemeProvider$1, Object.assign({
|
|
17
17
|
theme: theme
|
|
18
18
|
}, other));
|
|
19
19
|
};
|
|
20
|
-
ThemeProvider.defaultProps = {
|
|
21
|
-
theme: DEFAULT_THEME
|
|
22
|
-
};
|
|
23
20
|
|
|
24
21
|
export { ThemeProvider };
|
|
@@ -9,274 +9,250 @@ const PALETTE = {
|
|
|
9
9
|
white: '#fff',
|
|
10
10
|
product: {
|
|
11
11
|
support: '#00a656',
|
|
12
|
-
message: '#37b8af',
|
|
13
12
|
explore: '#30aabc',
|
|
14
13
|
gather: '#f6c8be',
|
|
15
14
|
guide: '#eb4962',
|
|
16
|
-
connect: '#ff6224',
|
|
17
15
|
chat: '#f79a3e',
|
|
18
16
|
talk: '#efc93d',
|
|
19
17
|
sell: '#c38f00'
|
|
20
18
|
},
|
|
21
19
|
grey: {
|
|
22
|
-
100: '#
|
|
23
|
-
200: '#
|
|
24
|
-
300: '#
|
|
25
|
-
400: '#
|
|
26
|
-
500: '#
|
|
27
|
-
600: '#
|
|
28
|
-
700: '#
|
|
29
|
-
800: '#
|
|
30
|
-
900: '#
|
|
31
|
-
1000: '#
|
|
32
|
-
1100: '#
|
|
33
|
-
1200: '#
|
|
20
|
+
100: '#f8f9f9',
|
|
21
|
+
200: '#e8eaec',
|
|
22
|
+
300: '#d8dcde',
|
|
23
|
+
400: '#b0b8be',
|
|
24
|
+
500: '#919ca5',
|
|
25
|
+
600: '#848f99',
|
|
26
|
+
700: '#5c6970',
|
|
27
|
+
800: '#39434b',
|
|
28
|
+
900: '#293239',
|
|
29
|
+
1000: '#1c2227',
|
|
30
|
+
1100: '#151a1e',
|
|
31
|
+
1200: '#0a0d0e'
|
|
34
32
|
},
|
|
35
33
|
blue: {
|
|
36
34
|
100: '#edf7ff',
|
|
37
|
-
200: '#
|
|
38
|
-
300: '#
|
|
39
|
-
400: '#
|
|
40
|
-
500: '#
|
|
41
|
-
600: '#
|
|
35
|
+
200: '#ddecf8',
|
|
36
|
+
300: '#cce0f1',
|
|
37
|
+
400: '#93bcdc',
|
|
38
|
+
500: '#66a0cd',
|
|
39
|
+
600: '#2694d6',
|
|
42
40
|
700: '#1f73b7',
|
|
43
|
-
800: '#
|
|
44
|
-
900: '#
|
|
45
|
-
1000: '#
|
|
46
|
-
1100: '#
|
|
47
|
-
1200: '#
|
|
41
|
+
800: '#13456d',
|
|
42
|
+
900: '#0f3655',
|
|
43
|
+
1000: '#0a2338',
|
|
44
|
+
1100: '#061420',
|
|
45
|
+
1200: '#040d15'
|
|
48
46
|
},
|
|
49
47
|
red: {
|
|
50
48
|
100: '#fff2f3',
|
|
51
|
-
200: '#
|
|
52
|
-
300: '#
|
|
53
|
-
400: '#
|
|
54
|
-
500: '#
|
|
55
|
-
600: '#
|
|
49
|
+
200: '#fee3e5',
|
|
50
|
+
300: '#f5d5d8',
|
|
51
|
+
400: '#f2a1a8',
|
|
52
|
+
500: '#ea7881',
|
|
53
|
+
600: '#eb5c69',
|
|
56
54
|
700: '#cd3642',
|
|
57
|
-
800: '#
|
|
58
|
-
900: '#
|
|
59
|
-
1000: '#
|
|
60
|
-
1100: '#
|
|
61
|
-
1200: '#
|
|
55
|
+
800: '#7e1d25',
|
|
56
|
+
900: '#671219',
|
|
57
|
+
1000: '#3d1418',
|
|
58
|
+
1100: '#1d1011',
|
|
59
|
+
1200: '#100b0c'
|
|
62
60
|
},
|
|
63
61
|
yellow: {
|
|
64
62
|
100: '#fff3e4',
|
|
65
|
-
200: '#
|
|
66
|
-
300: '#
|
|
67
|
-
400: '#
|
|
68
|
-
500: '#
|
|
69
|
-
600: '#
|
|
63
|
+
200: '#ffe6cb',
|
|
64
|
+
300: '#fed6a9',
|
|
65
|
+
400: '#fca347',
|
|
66
|
+
500: '#e38215',
|
|
67
|
+
600: '#d67305',
|
|
70
68
|
700: '#ac5918',
|
|
71
|
-
800: '#
|
|
72
|
-
900: '#
|
|
73
|
-
1000: '#
|
|
74
|
-
1100: '#
|
|
75
|
-
1200: '#
|
|
69
|
+
800: '#673515',
|
|
70
|
+
900: '#4c2c17',
|
|
71
|
+
1000: '#2d1e15',
|
|
72
|
+
1100: '#18120f',
|
|
73
|
+
1200: '#0e0c0b'
|
|
76
74
|
},
|
|
77
75
|
green: {
|
|
78
76
|
100: '#eef8f4',
|
|
79
|
-
200: '#
|
|
80
|
-
300: '#
|
|
81
|
-
400: '#
|
|
82
|
-
500: '#
|
|
83
|
-
600: '#
|
|
77
|
+
200: '#daeee6',
|
|
78
|
+
300: '#cae3d9',
|
|
79
|
+
400: '#94c1b0',
|
|
80
|
+
500: '#4eab89',
|
|
81
|
+
600: '#26a178',
|
|
84
82
|
700: '#037f52',
|
|
85
|
-
800: '#
|
|
86
|
-
900: '#
|
|
87
|
-
1000: '#
|
|
88
|
-
1100: '#
|
|
89
|
-
1200: '#
|
|
83
|
+
800: '#104b35',
|
|
84
|
+
900: '#0b3b29',
|
|
85
|
+
1000: '#0c261c',
|
|
86
|
+
1100: '#0a1511',
|
|
87
|
+
1200: '#080d0c'
|
|
90
88
|
},
|
|
91
89
|
kale: {
|
|
92
90
|
100: '#ecf9f9',
|
|
93
|
-
200: '#
|
|
94
|
-
300: '#
|
|
95
|
-
400: '#
|
|
96
|
-
500: '#
|
|
97
|
-
600: '#
|
|
91
|
+
200: '#daeded',
|
|
92
|
+
300: '#cbe2e1',
|
|
93
|
+
400: '#97bfbf',
|
|
94
|
+
500: '#6ba4a5',
|
|
95
|
+
600: '#4a9999',
|
|
98
96
|
700: '#40787a',
|
|
99
|
-
800: '#
|
|
100
|
-
900: '#
|
|
101
|
-
1000: '#
|
|
102
|
-
1100: '#
|
|
103
|
-
1200: '#
|
|
97
|
+
800: '#16494f',
|
|
98
|
+
900: '#063940',
|
|
99
|
+
1000: '#03252a',
|
|
100
|
+
1100: '#061517',
|
|
101
|
+
1200: '#060e0e'
|
|
104
102
|
},
|
|
105
103
|
fuschia: {
|
|
106
104
|
100: '#fbf3f8',
|
|
107
|
-
200: '#
|
|
108
|
-
300: '#
|
|
109
|
-
400: '#
|
|
110
|
-
500: '#
|
|
111
|
-
600: '#
|
|
105
|
+
200: '#f7e6f1',
|
|
106
|
+
300: '#f2d5e7',
|
|
107
|
+
400: '#e3a4cc',
|
|
108
|
+
500: '#d77db7',
|
|
109
|
+
600: '#d16aac',
|
|
112
110
|
700: '#b34496',
|
|
113
|
-
800: '#
|
|
114
|
-
900: '#
|
|
115
|
-
1000: '#
|
|
116
|
-
1100: '#
|
|
117
|
-
1200: '#
|
|
118
|
-
M400: '#cf62a8',
|
|
119
|
-
M600: '#a8458c'
|
|
111
|
+
800: '#78116c',
|
|
112
|
+
900: '#5a0d51',
|
|
113
|
+
1000: '#3f0939',
|
|
114
|
+
1100: '#31072c',
|
|
115
|
+
1200: '#1b0418'
|
|
120
116
|
},
|
|
121
117
|
pink: {
|
|
122
|
-
100: '#
|
|
123
|
-
200: '#
|
|
124
|
-
300: '#
|
|
125
|
-
400: '#
|
|
126
|
-
500: '#
|
|
127
|
-
600: '#
|
|
118
|
+
100: '#fcf3f4',
|
|
119
|
+
200: '#f7e5e8',
|
|
120
|
+
300: '#f3d6dc',
|
|
121
|
+
400: '#e5a6b4',
|
|
122
|
+
500: '#d98193',
|
|
123
|
+
600: '#d96b81',
|
|
128
124
|
700: '#d62054',
|
|
129
|
-
800: '#
|
|
130
|
-
900: '#
|
|
131
|
-
1000: '#
|
|
132
|
-
1100: '#
|
|
133
|
-
1200: '#
|
|
134
|
-
M400: '#d57287',
|
|
135
|
-
M600: '#b23a5d'
|
|
125
|
+
800: '#75263d',
|
|
126
|
+
900: '#561d2e',
|
|
127
|
+
1000: '#3c141f',
|
|
128
|
+
1100: '#2e0f18',
|
|
129
|
+
1200: '#17080c'
|
|
136
130
|
},
|
|
137
131
|
crimson: {
|
|
138
|
-
100: '#
|
|
139
|
-
200: '#
|
|
140
|
-
300: '#
|
|
141
|
-
400: '#
|
|
142
|
-
500: '#
|
|
143
|
-
600: '#
|
|
132
|
+
100: '#fbf3f2',
|
|
133
|
+
200: '#f7e7e4',
|
|
134
|
+
300: '#f1d7d2',
|
|
135
|
+
400: '#e2aaa0',
|
|
136
|
+
500: '#d58678',
|
|
137
|
+
600: '#cf7464',
|
|
144
138
|
700: '#be4938',
|
|
145
|
-
800: '#
|
|
146
|
-
900: '#
|
|
147
|
-
1000: '#
|
|
148
|
-
1100: '#
|
|
149
|
-
1200: '#
|
|
150
|
-
M400: '#cc6c5b',
|
|
151
|
-
M600: '#b24a3c'
|
|
139
|
+
800: '#811b12',
|
|
140
|
+
900: '#61140d',
|
|
141
|
+
1000: '#440e09',
|
|
142
|
+
1100: '#340b07',
|
|
143
|
+
1200: '#1c0604'
|
|
152
144
|
},
|
|
153
145
|
orange: {
|
|
154
146
|
100: '#fdf3ed',
|
|
155
|
-
200: '#
|
|
156
|
-
300: '#
|
|
157
|
-
400: '#
|
|
158
|
-
500: '#
|
|
159
|
-
600: '#
|
|
147
|
+
200: '#fae7d8',
|
|
148
|
+
300: '#f7d7be',
|
|
149
|
+
400: '#eda875',
|
|
150
|
+
500: '#e58035',
|
|
151
|
+
600: '#d57428',
|
|
160
152
|
700: '#af5626',
|
|
161
|
-
800: '#
|
|
162
|
-
900: '#
|
|
163
|
-
1000: '#
|
|
164
|
-
1100: '#
|
|
165
|
-
1200: '#
|
|
166
|
-
M400: '#d4772c',
|
|
167
|
-
M600: '#b35827'
|
|
153
|
+
800: '#693317',
|
|
154
|
+
900: '#4d2711',
|
|
155
|
+
1000: '#361a0c',
|
|
156
|
+
1100: '#291409',
|
|
157
|
+
1200: '#150a04'
|
|
168
158
|
},
|
|
169
159
|
lemon: {
|
|
170
|
-
100: '#
|
|
171
|
-
200: '#
|
|
172
|
-
300: '#
|
|
173
|
-
400: '#
|
|
174
|
-
500: '#
|
|
175
|
-
600: '#
|
|
160
|
+
100: '#fff7d4',
|
|
161
|
+
200: '#ffea97',
|
|
162
|
+
300: '#ffdc4f',
|
|
163
|
+
400: '#efab00',
|
|
164
|
+
500: '#c79100',
|
|
165
|
+
600: '#b68500',
|
|
176
166
|
700: '#8f6900',
|
|
177
|
-
800: '#
|
|
178
|
-
900: '#
|
|
179
|
-
1000: '#
|
|
180
|
-
1100: '#
|
|
181
|
-
1200: '#
|
|
182
|
-
M400: '#e7a500',
|
|
183
|
-
M600: '#c38f00'
|
|
167
|
+
800: '#563e00',
|
|
168
|
+
900: '#3f2e00',
|
|
169
|
+
1000: '#2b2000',
|
|
170
|
+
1100: '#221800',
|
|
171
|
+
1200: '#110c00'
|
|
184
172
|
},
|
|
185
173
|
lime: {
|
|
186
|
-
100: '#
|
|
187
|
-
200: '#
|
|
188
|
-
300: '#
|
|
189
|
-
400: '#
|
|
190
|
-
500: '#
|
|
191
|
-
600: '#
|
|
174
|
+
100: '#ecfae7',
|
|
175
|
+
200: '#d1f3c7',
|
|
176
|
+
300: '#b3eda3',
|
|
177
|
+
400: '#4fd12b',
|
|
178
|
+
500: '#45b025',
|
|
179
|
+
600: '#509f2d',
|
|
192
180
|
700: '#3d7e19',
|
|
193
|
-
800: '#
|
|
194
|
-
900: '#
|
|
195
|
-
1000: '#
|
|
196
|
-
1100: '#
|
|
197
|
-
1200: '#
|
|
198
|
-
M400: '#519e2d',
|
|
199
|
-
M600: '#47782c'
|
|
181
|
+
800: '#2c491b',
|
|
182
|
+
900: '#203614',
|
|
183
|
+
1000: '#16250e',
|
|
184
|
+
1100: '#111d0a',
|
|
185
|
+
1200: '#090e05'
|
|
200
186
|
},
|
|
201
187
|
mint: {
|
|
202
188
|
100: '#d6ffeb',
|
|
203
|
-
200: '#
|
|
204
|
-
300: '#
|
|
205
|
-
400: '#
|
|
206
|
-
500: '#
|
|
207
|
-
600: '#
|
|
208
|
-
700: '#
|
|
209
|
-
800: '#
|
|
210
|
-
900: '#
|
|
211
|
-
1000: '#
|
|
212
|
-
1100: '#
|
|
213
|
-
1200: '#
|
|
214
|
-
M400: '#299c66',
|
|
215
|
-
M600: '#2e8057'
|
|
189
|
+
200: '#9affce',
|
|
190
|
+
300: '#0afe89',
|
|
191
|
+
400: '#00d26d',
|
|
192
|
+
500: '#01b15c',
|
|
193
|
+
600: '#16a260',
|
|
194
|
+
700: '#2d7e55',
|
|
195
|
+
800: '#1b4b33',
|
|
196
|
+
900: '#143726',
|
|
197
|
+
1000: '#0e261a',
|
|
198
|
+
1100: '#0b1d14',
|
|
199
|
+
1200: '#050e0a'
|
|
216
200
|
},
|
|
217
201
|
teal: {
|
|
218
|
-
100: '#
|
|
219
|
-
200: '#
|
|
220
|
-
300: '#
|
|
221
|
-
400: '#
|
|
222
|
-
500: '#
|
|
223
|
-
600: '#
|
|
202
|
+
100: '#d4fefa',
|
|
203
|
+
200: '#88fdf1',
|
|
204
|
+
300: '#0bf8e1',
|
|
205
|
+
400: '#03cdb8',
|
|
206
|
+
500: '#02ad9c',
|
|
207
|
+
600: '#2a9d8f',
|
|
224
208
|
700: '#367a74',
|
|
225
|
-
800: '#
|
|
226
|
-
900: '#
|
|
227
|
-
1000: '#
|
|
228
|
-
1100: '#
|
|
229
|
-
1200: '#
|
|
230
|
-
M400: '#2d9e8f',
|
|
231
|
-
M600: '#3c7873'
|
|
209
|
+
800: '#254846',
|
|
210
|
+
900: '#1b3534',
|
|
211
|
+
1000: '#122423',
|
|
212
|
+
1100: '#0e1c1a',
|
|
213
|
+
1200: '#070d0d'
|
|
232
214
|
},
|
|
233
215
|
azure: {
|
|
234
|
-
100: '#
|
|
235
|
-
200: '#
|
|
236
|
-
300: '#
|
|
237
|
-
400: '#
|
|
238
|
-
500: '#
|
|
239
|
-
600: '#
|
|
240
|
-
700: '#
|
|
241
|
-
800: '#
|
|
242
|
-
900: '#
|
|
243
|
-
1000: '#
|
|
244
|
-
1100: '#
|
|
245
|
-
1200: '#
|
|
246
|
-
M400: '#5f8dcf',
|
|
247
|
-
M600: '#3a70b2'
|
|
216
|
+
100: '#eff7fe',
|
|
217
|
+
200: '#d9ecfc',
|
|
218
|
+
300: '#c4e0fa',
|
|
219
|
+
400: '#82bcf4',
|
|
220
|
+
500: '#4b9fee',
|
|
221
|
+
600: '#3191ea',
|
|
222
|
+
700: '#2770c3',
|
|
223
|
+
800: '#23446b',
|
|
224
|
+
900: '#1a3250',
|
|
225
|
+
1000: '#122238',
|
|
226
|
+
1100: '#0e1a2a',
|
|
227
|
+
1200: '#070d14'
|
|
248
228
|
},
|
|
249
229
|
royal: {
|
|
250
|
-
100: '#
|
|
251
|
-
200: '#
|
|
252
|
-
300: '#
|
|
253
|
-
400: '#
|
|
254
|
-
500: '#
|
|
255
|
-
600: '#
|
|
256
|
-
700: '#
|
|
257
|
-
800: '#
|
|
258
|
-
900: '#
|
|
259
|
-
1000: '#
|
|
260
|
-
1100: '#
|
|
261
|
-
1200: '#
|
|
262
|
-
M400: '#7986d8',
|
|
263
|
-
M600: '#4b61c3'
|
|
230
|
+
100: '#f4f5fc',
|
|
231
|
+
200: '#e7e9f8',
|
|
232
|
+
300: '#d8dcf4',
|
|
233
|
+
400: '#acb4e7',
|
|
234
|
+
500: '#8a96dd',
|
|
235
|
+
600: '#7a88d9',
|
|
236
|
+
700: '#4c67d3',
|
|
237
|
+
800: '#1833ab',
|
|
238
|
+
900: '#122680',
|
|
239
|
+
1000: '#0d1a5a',
|
|
240
|
+
1100: '#0a1445',
|
|
241
|
+
1200: '#050a25'
|
|
264
242
|
},
|
|
265
243
|
purple: {
|
|
266
|
-
100: '#
|
|
267
|
-
200: '#
|
|
268
|
-
300: '#
|
|
269
|
-
400: '#
|
|
270
|
-
500: '#
|
|
271
|
-
600: '#
|
|
244
|
+
100: '#f9f3fb',
|
|
245
|
+
200: '#f2e7f6',
|
|
246
|
+
300: '#e9d8f1',
|
|
247
|
+
400: '#d0a9e0',
|
|
248
|
+
500: '#bb86d3',
|
|
249
|
+
600: '#b276cd',
|
|
272
250
|
700: '#9256b1',
|
|
273
|
-
800: '#
|
|
274
|
-
900: '#
|
|
275
|
-
1000: '#
|
|
276
|
-
1100: '#
|
|
277
|
-
1200: '#
|
|
278
|
-
M400: '#b072cc',
|
|
279
|
-
M600: '#9358b0'
|
|
251
|
+
800: '#58209a',
|
|
252
|
+
900: '#411973',
|
|
253
|
+
1000: '#2e1150',
|
|
254
|
+
1100: '#230d3f',
|
|
255
|
+
1200: '#120720'
|
|
280
256
|
}
|
|
281
257
|
};
|
|
282
258
|
|
|
@@ -44,26 +44,27 @@ const colors = {
|
|
|
44
44
|
recessed: 'neutralHue.1200',
|
|
45
45
|
subtle: 'neutralHue.1000',
|
|
46
46
|
emphasis: 'neutralHue.600',
|
|
47
|
-
primary: 'primaryHue.900',
|
|
48
47
|
success: 'successHue.1000',
|
|
49
48
|
warning: 'warningHue.1000',
|
|
50
49
|
danger: 'dangerHue.1000',
|
|
51
50
|
primaryEmphasis: 'primaryHue.600',
|
|
52
51
|
successEmphasis: 'successHue.600',
|
|
53
52
|
warningEmphasis: 'warningHue.600',
|
|
54
|
-
dangerEmphasis: 'dangerHue.600'
|
|
53
|
+
dangerEmphasis: 'dangerHue.600',
|
|
54
|
+
disabled: 'rgba(neutralHue.500, 100)'
|
|
55
55
|
},
|
|
56
56
|
border: {
|
|
57
57
|
default: 'neutralHue.800',
|
|
58
58
|
emphasis: 'neutralHue.600',
|
|
59
59
|
subtle: 'neutralHue.900',
|
|
60
|
-
success: 'successHue.
|
|
61
|
-
warning: 'warningHue.
|
|
62
|
-
danger: 'dangerHue.
|
|
60
|
+
success: 'successHue.900',
|
|
61
|
+
warning: 'warningHue.900',
|
|
62
|
+
danger: 'dangerHue.900',
|
|
63
63
|
primaryEmphasis: 'primaryHue.600',
|
|
64
64
|
successEmphasis: 'successHue.600',
|
|
65
65
|
warningEmphasis: 'warningHue.600',
|
|
66
|
-
dangerEmphasis: 'dangerHue.600'
|
|
66
|
+
dangerEmphasis: 'dangerHue.600',
|
|
67
|
+
disabled: 'neutralHue.800'
|
|
67
68
|
},
|
|
68
69
|
foreground: {
|
|
69
70
|
default: 'neutralHue.300',
|
|
@@ -75,7 +76,13 @@ const colors = {
|
|
|
75
76
|
danger: 'dangerHue.400',
|
|
76
77
|
successEmphasis: 'successHue.300',
|
|
77
78
|
warningEmphasis: 'warningHue.300',
|
|
78
|
-
dangerEmphasis: 'dangerHue.300'
|
|
79
|
+
dangerEmphasis: 'dangerHue.300',
|
|
80
|
+
disabled: 'neutralHue.700'
|
|
81
|
+
},
|
|
82
|
+
shadow: {
|
|
83
|
+
small: 'rgba(neutralHue.1200, 1100)',
|
|
84
|
+
medium: 'rgba(neutralHue.1200, 800)',
|
|
85
|
+
large: 'rgba(neutralHue.1200, 1000)'
|
|
79
86
|
}
|
|
80
87
|
},
|
|
81
88
|
light: {
|
|
@@ -85,14 +92,14 @@ const colors = {
|
|
|
85
92
|
recessed: 'neutralHue.100',
|
|
86
93
|
subtle: 'neutralHue.100',
|
|
87
94
|
emphasis: 'neutralHue.700',
|
|
88
|
-
primary: 'primaryHue.100',
|
|
89
95
|
success: 'successHue.100',
|
|
90
96
|
warning: 'warningHue.100',
|
|
91
97
|
danger: 'dangerHue.100',
|
|
92
98
|
primaryEmphasis: 'primaryHue.700',
|
|
93
99
|
successEmphasis: 'successHue.700',
|
|
94
100
|
warningEmphasis: 'warningHue.700',
|
|
95
|
-
dangerEmphasis: 'dangerHue.700'
|
|
101
|
+
dangerEmphasis: 'dangerHue.700',
|
|
102
|
+
disabled: 'rgba(neutralHue.700, 100)'
|
|
96
103
|
},
|
|
97
104
|
border: {
|
|
98
105
|
default: 'neutralHue.300',
|
|
@@ -104,7 +111,8 @@ const colors = {
|
|
|
104
111
|
primaryEmphasis: 'primaryHue.700',
|
|
105
112
|
successEmphasis: 'successHue.700',
|
|
106
113
|
warningEmphasis: 'warningHue.700',
|
|
107
|
-
dangerEmphasis: 'dangerHue.700'
|
|
114
|
+
dangerEmphasis: 'dangerHue.700',
|
|
115
|
+
disabled: 'neutralHue.300'
|
|
108
116
|
},
|
|
109
117
|
foreground: {
|
|
110
118
|
default: 'neutralHue.900',
|
|
@@ -116,7 +124,13 @@ const colors = {
|
|
|
116
124
|
danger: 'dangerHue.700',
|
|
117
125
|
successEmphasis: 'successHue.900',
|
|
118
126
|
warningEmphasis: 'warningHue.900',
|
|
119
|
-
dangerEmphasis: 'dangerHue.900'
|
|
127
|
+
dangerEmphasis: 'dangerHue.900',
|
|
128
|
+
disabled: 'neutralHue.600'
|
|
129
|
+
},
|
|
130
|
+
shadow: {
|
|
131
|
+
small: 'rgba(neutralHue.1200, 200)',
|
|
132
|
+
medium: 'rgba(neutralHue.1200, 200)',
|
|
133
|
+
large: 'rgba(neutralHue.1200, 200)'
|
|
120
134
|
}
|
|
121
135
|
}
|
|
122
136
|
}
|
|
@@ -158,6 +172,20 @@ const lineHeights = {
|
|
|
158
172
|
xxl: `${BASE * 8}px`,
|
|
159
173
|
xxxl: `${BASE * 11}px`
|
|
160
174
|
};
|
|
175
|
+
const opacity = {
|
|
176
|
+
100: 0.08,
|
|
177
|
+
200: 0.16,
|
|
178
|
+
300: 0.24,
|
|
179
|
+
400: 0.32,
|
|
180
|
+
500: 0.4,
|
|
181
|
+
600: 0.48,
|
|
182
|
+
700: 0.56,
|
|
183
|
+
800: 0.64,
|
|
184
|
+
900: 0.72,
|
|
185
|
+
1000: 0.8,
|
|
186
|
+
1100: 0.88,
|
|
187
|
+
1200: 0.96
|
|
188
|
+
};
|
|
161
189
|
const palette = {
|
|
162
190
|
...PALETTE
|
|
163
191
|
};
|
|
@@ -199,6 +227,7 @@ const DEFAULT_THEME = {
|
|
|
199
227
|
fontWeights,
|
|
200
228
|
iconSizes,
|
|
201
229
|
lineHeights,
|
|
230
|
+
opacity,
|
|
202
231
|
palette,
|
|
203
232
|
rtl: false,
|
|
204
233
|
shadowWidths,
|
package/dist/esm/index.js
CHANGED
|
@@ -7,9 +7,9 @@
|
|
|
7
7
|
export { ThemeProvider } from './elements/ThemeProvider.js';
|
|
8
8
|
export { default as DEFAULT_THEME } from './elements/theme/index.js';
|
|
9
9
|
export { default as PALETTE } from './elements/palette/index.js';
|
|
10
|
-
export { default as PALETTE_V8 } from './elements/palette/v8.js';
|
|
11
10
|
export { default as retrieveComponentStyles } from './utils/retrieveComponentStyles.js';
|
|
12
11
|
export { getArrowPosition } from './utils/getArrowPosition.js';
|
|
12
|
+
export { getCheckeredBackground } from './utils/getCheckeredBackground.js';
|
|
13
13
|
export { getColor } from './utils/getColor.js';
|
|
14
14
|
export { getColorV8 } from './utils/getColorV8.js';
|
|
15
15
|
export { getFloatingPlacements } from './utils/getFloatingPlacements.js';
|
|
@@ -23,4 +23,5 @@ export { useWindow } from './utils/useWindow.js';
|
|
|
23
23
|
export { useText } from './utils/useText.js';
|
|
24
24
|
export { default as menuStyles } from './utils/menuStyles.js';
|
|
25
25
|
export { SELECTOR_FOCUS_VISIBLE, focusStyles } from './utils/focusStyles.js';
|
|
26
|
+
export { StyledBaseIcon } from './utils/StyledBaseIcon.js';
|
|
26
27
|
export { ARROW_POSITION, MENU_POSITION, PLACEMENT } from './types/index.js';
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright Zendesk, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Use of this source code is governed under the Apache License, Version 2.0
|
|
5
|
+
* found at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
|
+
*/
|
|
7
|
+
import styled from 'styled-components';
|
|
8
|
+
import React, { Children } from 'react';
|
|
9
|
+
|
|
10
|
+
const StyledBaseIcon = styled(_ref => {
|
|
11
|
+
let {
|
|
12
|
+
children,
|
|
13
|
+
theme,
|
|
14
|
+
...props
|
|
15
|
+
} = _ref;
|
|
16
|
+
return React.cloneElement(Children.only(children), props);
|
|
17
|
+
}).withConfig({
|
|
18
|
+
displayName: "StyledBaseIcon",
|
|
19
|
+
componentId: "sc-1moykgb-0"
|
|
20
|
+
})([""]);
|
|
21
|
+
|
|
22
|
+
export { StyledBaseIcon };
|