@blockscout/ui-toolkit 0.0.1-alpha.2 → 0.0.1-alpha.4

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.
Files changed (103) hide show
  1. package/README.md +125 -62
  2. package/dist/chakra/select.d.ts +4 -1
  3. package/dist/components/AdaptiveTabs/index.d.ts +3 -0
  4. package/dist/components/Hint/Hint.d.ts +11 -0
  5. package/dist/components/RoutedTabs/index.d.ts +3 -0
  6. package/dist/components/buttons/BackToButton.d.ts +7 -0
  7. package/dist/components/buttons/ClearButton.d.ts +6 -0
  8. package/dist/components/{Filter → filters}/FilterInput.d.ts +2 -3
  9. package/dist/components/forms/components/FormFieldError.d.ts +7 -0
  10. package/dist/components/forms/components/index.d.ts +1 -0
  11. package/dist/components/forms/fields/FormFieldAddress.d.ts +5 -0
  12. package/dist/components/forms/fields/FormFieldCheckbox.d.ts +9 -0
  13. package/dist/components/forms/fields/FormFieldColor.d.ts +9 -0
  14. package/dist/components/forms/fields/FormFieldEmail.d.ts +5 -0
  15. package/dist/components/forms/fields/FormFieldSelect.d.ts +7 -0
  16. package/dist/components/forms/fields/FormFieldSelectAsync.d.ts +7 -0
  17. package/dist/components/forms/fields/FormFieldText.d.ts +8 -0
  18. package/dist/components/forms/fields/FormFieldUrl.d.ts +4 -0
  19. package/dist/components/forms/fields/image/FormFieldImagePreview.d.ts +13 -0
  20. package/dist/components/forms/fields/image/useImageField.d.ts +25 -0
  21. package/dist/components/forms/fields/index.d.ts +10 -0
  22. package/dist/components/forms/fields/types.d.ts +19 -0
  23. package/dist/components/forms/inputs/file/DragAndDropArea.d.ts +11 -0
  24. package/dist/components/forms/inputs/file/FileInput.d.ts +13 -0
  25. package/dist/components/forms/inputs/file/FileSnippet.d.ts +11 -0
  26. package/dist/components/forms/inputs/file/utils.d.ts +2 -0
  27. package/dist/components/forms/inputs/index.d.ts +3 -0
  28. package/dist/components/forms/utils/getFormFieldErrorText.d.ts +2 -0
  29. package/dist/components/forms/utils/index.d.ts +1 -0
  30. package/dist/components/forms/validators/address.d.ts +3 -0
  31. package/dist/components/forms/validators/color.d.ts +2 -0
  32. package/dist/components/forms/validators/email.d.ts +2 -0
  33. package/dist/components/forms/validators/index.d.ts +7 -0
  34. package/dist/components/forms/validators/signature.d.ts +1 -0
  35. package/dist/components/forms/validators/text.d.ts +1 -0
  36. package/dist/components/forms/validators/transaction.d.ts +2 -0
  37. package/dist/components/forms/validators/url.d.ts +3 -0
  38. package/dist/components/truncation/TruncatedTextTooltip.d.ts +8 -0
  39. package/dist/hooks/useClipboard.d.ts +1 -1
  40. package/dist/hooks/useFirstMountState.d.ts +1 -0
  41. package/dist/hooks/useIsSticky.d.ts +2 -0
  42. package/dist/hooks/useUpdateEffect.d.ts +2 -0
  43. package/dist/hooks/useViewportSize.d.ts +1 -1
  44. package/dist/index.js +4246 -3097
  45. package/dist/package/src/index.d.ts +24 -3
  46. package/dist/theme/theme.d.ts +1 -0
  47. package/dist/utils/consts.d.ts +15 -0
  48. package/dist/utils/guards.d.ts +2 -0
  49. package/dist/utils/htmlEntities.d.ts +26 -0
  50. package/dist/utils/isBrowser.d.ts +1 -0
  51. package/dist/utils/regexp.d.ts +6 -0
  52. package/dist/utils/url.d.ts +6 -0
  53. package/package.json +33 -3
  54. package/dist/components/ButtonBackTo.d.ts +0 -8
  55. package/dist/components/TruncatedTextTooltip.d.ts +0 -9
  56. package/dist/components/index.d.ts +0 -1
  57. package/dist/theme/foundations/animations.ts +0 -12
  58. package/dist/theme/foundations/borders.ts +0 -13
  59. package/dist/theme/foundations/breakpoints.ts +0 -10
  60. package/dist/theme/foundations/colors.ts +0 -162
  61. package/dist/theme/foundations/durations.ts +0 -15
  62. package/dist/theme/foundations/semanticTokens.ts +0 -471
  63. package/dist/theme/foundations/shadows.ts +0 -19
  64. package/dist/theme/foundations/typography.ts +0 -93
  65. package/dist/theme/foundations/zIndex.ts +0 -20
  66. package/dist/theme/globalCss.ts +0 -57
  67. package/dist/theme/globals/address-entity.ts +0 -33
  68. package/dist/theme/globals/recaptcha.ts +0 -20
  69. package/dist/theme/globals/scrollbar.ts +0 -32
  70. package/dist/theme/recipes/accordion.recipe.ts +0 -145
  71. package/dist/theme/recipes/alert.recipe.ts +0 -135
  72. package/dist/theme/recipes/badge.recipe.ts +0 -83
  73. package/dist/theme/recipes/button.recipe.ts +0 -285
  74. package/dist/theme/recipes/checkbox.recipe.ts +0 -56
  75. package/dist/theme/recipes/checkmark.recipe.ts +0 -73
  76. package/dist/theme/recipes/close-button.recipe.ts +0 -34
  77. package/dist/theme/recipes/dialog.recipe.ts +0 -213
  78. package/dist/theme/recipes/drawer.recipe.ts +0 -173
  79. package/dist/theme/recipes/field.recipe.ts +0 -175
  80. package/dist/theme/recipes/index.ts +0 -68
  81. package/dist/theme/recipes/input.recipe.ts +0 -119
  82. package/dist/theme/recipes/link.recipe.ts +0 -78
  83. package/dist/theme/recipes/list.recipe.ts +0 -67
  84. package/dist/theme/recipes/menu.recipe.ts +0 -105
  85. package/dist/theme/recipes/pin-input.recipe.ts +0 -35
  86. package/dist/theme/recipes/popover.recipe.ts +0 -71
  87. package/dist/theme/recipes/progress-circle.recipe.ts +0 -74
  88. package/dist/theme/recipes/radio-group.recipe.ts +0 -73
  89. package/dist/theme/recipes/radiomark.recipe.ts +0 -91
  90. package/dist/theme/recipes/rating-group.recipe.ts +0 -93
  91. package/dist/theme/recipes/select.recipe.ts +0 -277
  92. package/dist/theme/recipes/skeleton.recipe.ts +0 -56
  93. package/dist/theme/recipes/spinner.recipe.ts +0 -31
  94. package/dist/theme/recipes/stat.recipe.ts +0 -101
  95. package/dist/theme/recipes/switch.recipe.ts +0 -130
  96. package/dist/theme/recipes/table.recipe.ts +0 -84
  97. package/dist/theme/recipes/tabs.recipe.ts +0 -219
  98. package/dist/theme/recipes/tag.recipe.ts +0 -145
  99. package/dist/theme/recipes/textarea.recipe.ts +0 -86
  100. package/dist/theme/recipes/toast.recipe.ts +0 -97
  101. package/dist/theme/recipes/tooltip.recipe.ts +0 -85
  102. package/dist/theme/theme.ts +0 -41
  103. package/dist/theme/utils/entries.ts +0 -12
@@ -1,471 +0,0 @@
1
- import type { ThemingConfig } from '@chakra-ui/react';
2
-
3
- import config from 'configs/app';
4
-
5
- const heroBannerButton = config.UI.homepage.heroBanner?.button;
6
-
7
- const semanticTokens: ThemingConfig['semanticTokens'] = {
8
- colors: {
9
- button: {
10
- outline: {
11
- fg: {
12
- DEFAULT: { value: { _light: '{colors.blue.600}', _dark: '{colors.blue.600}' } },
13
- },
14
- },
15
- subtle: {
16
- fg: {
17
- DEFAULT: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
18
- },
19
- bg: {
20
- DEFAULT: { value: { _light: '{colors.blackAlpha.200}', _dark: '{colors.whiteAlpha.200}' } },
21
- },
22
- },
23
- dropdown: {
24
- fg: {
25
- DEFAULT: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
26
- selected: { value: { _light: '{colors.blue.700}', _dark: '{colors.whiteAlpha.800}' } },
27
- },
28
- bg: {
29
- selected: { value: { _light: '{colors.blue.50}', _dark: '{colors.whiteAlpha.100}' } },
30
- },
31
- border: {
32
- DEFAULT: { value: { _light: '{colors.gray.200}', _dark: '{colors.gray.600}' } },
33
- },
34
- },
35
- header: {
36
- fg: {
37
- DEFAULT: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.gray.400}' } },
38
- selected: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
39
- highlighted: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
40
- },
41
- bg: {
42
- selected: { value: { _light: '{colors.blackAlpha.50}', _dark: '{colors.whiteAlpha.100}' } },
43
- highlighted: { value: { _light: '{colors.orange.100}', _dark: '{colors.orange.900}' } },
44
- },
45
- border: {
46
- DEFAULT: { value: { _light: '{colors.gray.300}', _dark: '{colors.gray.600}' } },
47
- },
48
- },
49
- segmented: {
50
- fg: {
51
- DEFAULT: { value: { _light: '{colors.blue.600}', _dark: '{colors.blue.300}' } },
52
- selected: { value: { _light: '{colors.blue.700}', _dark: '{colors.gray.50}' } },
53
- },
54
- border: {
55
- DEFAULT: { value: { _light: '{colors.blue.50}', _dark: '{colors.gray.800}' } },
56
- },
57
- },
58
- icon_secondary: {
59
- fg: {
60
- DEFAULT: { value: { _light: '{colors.gray.400}', _dark: '{colors.gray.500}' } },
61
- selected: { value: { _light: '{colors.blue.700}', _dark: '{colors.whiteAlpha.800}' } },
62
- },
63
- bg: {
64
- selected: { value: { _light: '{colors.blue.50}', _dark: '{colors.whiteAlpha.100}' } },
65
- },
66
- },
67
- hero: {
68
- bg: {
69
- DEFAULT: {
70
- value: {
71
- _light: heroBannerButton?._default?.background?.[0] || '{colors.blue.600}',
72
- _dark: heroBannerButton?._default?.background?.[1] || heroBannerButton?._default?.background?.[0] || '{colors.blue.600}',
73
- },
74
- },
75
- hover: {
76
- value: {
77
- _light: heroBannerButton?._hover?.background?.[0] || '{colors.blue.400}',
78
- _dark: heroBannerButton?._hover?.background?.[1] || heroBannerButton?._hover?.background?.[0] || '{colors.blue.400}',
79
- },
80
- },
81
- selected: {
82
- value: {
83
- _light: heroBannerButton?._selected?.background?.[0] || '{colors.blue.50}',
84
- _dark: heroBannerButton?._selected?.background?.[1] || heroBannerButton?._selected?.background?.[0] || '{colors.blue.50}',
85
- },
86
- },
87
- },
88
- fg: {
89
- DEFAULT: {
90
- value: {
91
- _light: heroBannerButton?._default?.text_color?.[0] || '{colors.white}',
92
- _dark: heroBannerButton?._default?.text_color?.[1] || heroBannerButton?._default?.text_color?.[0] || '{colors.white}',
93
- },
94
- },
95
- hover: {
96
- value: {
97
- _light: heroBannerButton?._hover?.text_color?.[0] || '{colors.white}',
98
- _dark: heroBannerButton?._hover?.text_color?.[1] || heroBannerButton?._hover?.text_color?.[0] || '{colors.white}',
99
- },
100
- },
101
- selected: {
102
- value: {
103
- _light: heroBannerButton?._selected?.text_color?.[0] || '{colors.blackAlpha.800}',
104
- _dark: heroBannerButton?._selected?.text_color?.[1] || heroBannerButton?._selected?.text_color?.[0] || '{colors.blackAlpha.800}',
105
- },
106
- },
107
- },
108
- },
109
- },
110
- closeButton: {
111
- fg: {
112
- DEFAULT: { value: { _light: '{colors.blackAlpha.500}', _dark: '{colors.whiteAlpha.500}' } },
113
- },
114
- },
115
- link: {
116
- primary: {
117
- DEFAULT: { value: { _light: '{colors.blue.600}', _dark: '{colors.blue.300}' } },
118
- hover: { value: { _light: '{colors.blue.400}' } },
119
- },
120
- secondary: {
121
- DEFAULT: { value: { _light: '{colors.gray.500}', _dark: '{colors.gray.400}' } },
122
- },
123
- underlaid: {
124
- bg: { value: { _light: '{colors.gray.100}', _dark: '{colors.gray.800}' } },
125
- },
126
- subtle: {
127
- DEFAULT: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.gray.400}' } },
128
- hover: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.gray.400}' } },
129
- },
130
- navigation: {
131
- fg: {
132
- DEFAULT: { value: { _light: '{colors.gray.600}', _dark: '{colors.gray.400}' } },
133
- selected: { value: { _light: '{colors.blue.700}', _dark: '{colors.gray.50}' } },
134
- hover: { value: { _light: '{colors.link.primary.hover}' } },
135
- active: { value: { _light: '{colors.link.primary.hover}' } },
136
- },
137
- bg: {
138
- selected: { value: { _light: '{colors.blue.50}', _dark: '{colors.gray.800}' } },
139
- group: { value: { _light: '{colors.white}', _dark: '{colors.black}' } },
140
- },
141
- },
142
- menu: {
143
- DEFAULT: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
144
- },
145
- },
146
- tooltip: {
147
- DEFAULT: {
148
- bg: { value: '{colors.gray.900}' },
149
- fg: { value: '{colors.white}' },
150
- },
151
- navigation: {
152
- bg: { value: { _light: '{colors.blue.50}', _dark: '{colors.gray.800}' } },
153
- fg: {
154
- DEFAULT: { value: '{colors.blue.400}' },
155
- selected: { value: { _light: '{colors.blue.700}', _dark: '{colors.gray.50}' } },
156
- },
157
- },
158
- },
159
- popover: {
160
- DEFAULT: {
161
- bg: { value: { _light: '{colors.white}', _dark: '{colors.gray.900}' } },
162
- shadow: { value: { _light: '{colors.blackAlpha.200}', _dark: '{colors.whiteAlpha.300}' } },
163
- },
164
- },
165
- progressCircle: {
166
- trackColor: {
167
- DEFAULT: { value: { _light: '{colors.gray.100}', _dark: '{colors.whiteAlpha.100}' } },
168
- },
169
- },
170
- skeleton: {
171
- bg: {
172
- start: { value: { _light: '{colors.blackAlpha.50}', _dark: '{colors.whiteAlpha.50}' } },
173
- end: { value: { _light: '{colors.blackAlpha.100}', _dark: '{colors.whiteAlpha.100}' } },
174
- },
175
- },
176
- tabs: {
177
- solid: {
178
- fg: {
179
- DEFAULT: { value: { _light: '{colors.blue.700}', _dark: '{colors.blue.100}' } },
180
- selected: { value: { _light: '{colors.blue.700}', _dark: '{colors.gray.50}' } },
181
- },
182
- bg: {
183
- selected: { value: { _light: '{colors.blue.50}', _dark: '{colors.whiteAlpha.100}' } },
184
- },
185
- },
186
- secondary: {
187
- fg: {
188
- DEFAULT: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
189
- },
190
- bg: {
191
- selected: { value: { _light: '{colors.blue.50}', _dark: '{colors.whiteAlpha.100}' } },
192
- },
193
- border: {
194
- DEFAULT: { value: { _light: '{colors.gray.300}', _dark: '{colors.gray.600}' } },
195
- },
196
- },
197
- segmented: {
198
- fg: {
199
- DEFAULT: { value: { _light: '{colors.blue.600}', _dark: '{colors.blue.300}' } },
200
- selected: { value: { _light: '{colors.blue.700}', _dark: '{colors.gray.50}' } },
201
- },
202
- border: {
203
- DEFAULT: { value: { _light: '{colors.blue.50}', _dark: '{colors.gray.800}' } },
204
- },
205
- },
206
- },
207
- 'switch': {
208
- primary: {
209
- bg: {
210
- DEFAULT: { value: { _light: '{colors.gray.300}', _dark: '{colors.whiteAlpha.400}' } },
211
- checked: { value: { _light: '{colors.blue.500}', _dark: '{colors.blue.300}' } },
212
- hover: { value: { _light: '{colors.blue.600}', _dark: '{colors.blue.400}' } },
213
- },
214
- },
215
- },
216
- alert: {
217
- fg: {
218
- DEFAULT: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
219
- },
220
- bg: {
221
- info: { value: { _light: '{colors.blackAlpha.50}', _dark: '{colors.whiteAlpha.100}' } },
222
- warning: { value: { _light: '{colors.orange.100}', _dark: '{colors.orange.800/60}' } },
223
- warning_table: { value: { _light: '{colors.orange.50}', _dark: '{colors.orange.800/60}' } },
224
- success: { value: { _light: '{colors.green.100}', _dark: '{colors.green.900}' } },
225
- error: { value: { _light: '{colors.red.100}', _dark: '{colors.red.900}' } },
226
- },
227
- },
228
- toast: {
229
- fg: {
230
- DEFAULT: { value: '{colors.alert.fg}' },
231
- },
232
- bg: {
233
- DEFAULT: { value: '{colors.alert.bg.info}' },
234
- info: { value: { _light: '{colors.blue.100}', _dark: '{colors.blue.900}' } },
235
- warning: { value: '{colors.alert.bg.warning}' },
236
- success: { value: '{colors.alert.bg.success}' },
237
- error: { value: '{colors.alert.bg.error}' },
238
- loading: { value: { _light: '{colors.blue.100}', _dark: '{colors.blue.900}' } },
239
- },
240
- },
241
- input: {
242
- fg: {
243
- DEFAULT: { value: { _light: '{colors.gray.800}', _dark: '{colors.gray.50}' } },
244
- error: { value: '{colors.text.error}' },
245
- },
246
- bg: {
247
- DEFAULT: { value: { _light: '{colors.white}', _dark: '{colors.black}' } },
248
- readOnly: { value: { _light: '{colors.gray.200}', _dark: '{colors.gray.800}' } },
249
- },
250
- border: {
251
- DEFAULT: { value: { _light: '{colors.gray.100}', _dark: '{colors.gray.700}' } },
252
- hover: { value: { _light: '{colors.gray.200}', _dark: '{colors.gray.500}' } },
253
- focus: { value: '{colors.blue.400}' },
254
- filled: { value: { _light: '{colors.gray.300}', _dark: '{colors.gray.600}' } },
255
- readOnly: { value: { _light: '{colors.gray.200}', _dark: '{colors.gray.800}' } },
256
- error: { value: '{colors.red.500}' },
257
- },
258
- placeholder: {
259
- DEFAULT: { value: '{colors.gray.500}' },
260
- error: { value: '{colors.red.500}' },
261
- },
262
- },
263
- field: {
264
- placeholder: {
265
- DEFAULT: { value: '{colors.gray.500}' },
266
- disabled: { value: '{colors.gray.500/20}' },
267
- error: { value: '{colors.red.500}' },
268
- },
269
- },
270
- dialog: {
271
- bg: {
272
- DEFAULT: { value: { _light: '{colors.white}', _dark: '{colors.gray.900}' } },
273
- },
274
- fg: {
275
- DEFAULT: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
276
- },
277
- },
278
- drawer: {
279
- bg: {
280
- DEFAULT: { value: { _light: '{colors.white}', _dark: '{colors.gray.900}' } },
281
- },
282
- },
283
- select: {
284
- trigger: {
285
- outline: {
286
- fg: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
287
- },
288
- },
289
- item: {
290
- bg: {
291
- highlighted: { value: { _light: '{colors.blue.50}', _dark: '{colors.whiteAlpha.100}' } },
292
- },
293
- },
294
- indicator: {
295
- fg: {
296
- DEFAULT: { value: '{colors.gray.500}' },
297
- },
298
- },
299
- placeholder: {
300
- fg: {
301
- DEFAULT: { value: '{colors.gray.500}' },
302
- error: { value: '{colors.red.500}' },
303
- },
304
- },
305
- },
306
- menu: {
307
- item: {
308
- bg: {
309
- highlighted: { value: { _light: '{colors.blue.50}', _dark: '{colors.whiteAlpha.100}' } },
310
- },
311
- },
312
- },
313
- spinner: {
314
- track: {
315
- DEFAULT: { value: { _light: '{colors.blackAlpha.200}', _dark: '{colors.whiteAlpha.200}' } },
316
- },
317
- },
318
- badge: {
319
- gray: {
320
- bg: { value: { _light: '{colors.blackAlpha.50}', _dark: '{colors.whiteAlpha.100}' } },
321
- fg: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
322
- },
323
- green: {
324
- bg: { value: { _light: '{colors.green.50}', _dark: '{colors.green.800}' } },
325
- fg: { value: { _light: '{colors.green.500}', _dark: '{colors.green.200}' } },
326
- },
327
- red: {
328
- bg: { value: { _light: '{colors.red.50}', _dark: '{colors.red.800}' } },
329
- fg: { value: { _light: '{colors.red.500}', _dark: '{colors.red.200}' } },
330
- },
331
- purple: {
332
- bg: { value: { _light: '{colors.purple.50}', _dark: '{colors.purple.800}' } },
333
- fg: { value: { _light: '{colors.purple.500}', _dark: '{colors.purple.100}' } },
334
- },
335
- purple_alt: {
336
- bg: { value: { _light: '{colors.purple.100}', _dark: '{colors.purple.800}' } },
337
- fg: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
338
- },
339
- orange: {
340
- bg: { value: { _light: '{colors.orange.50}', _dark: '{colors.orange.800}' } },
341
- fg: { value: { _light: '{colors.orange.500}', _dark: '{colors.orange.100}' } },
342
- },
343
- blue: {
344
- bg: { value: { _light: '{colors.blue.50}', _dark: '{colors.blue.800}' } },
345
- fg: { value: { _light: '{colors.blue.500}', _dark: '{colors.blue.100}' } },
346
- },
347
- blue_alt: {
348
- bg: { value: { _light: '{colors.blue.50}', _dark: '{colors.blue.800}' } },
349
- fg: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
350
- },
351
- yellow: {
352
- bg: { value: { _light: '{colors.yellow.50}', _dark: '{colors.yellow.800}' } },
353
- fg: { value: { _light: '{colors.yellow.500}', _dark: '{colors.yellow.100}' } },
354
- },
355
- teal: {
356
- bg: { value: { _light: '{colors.teal.50}', _dark: '{colors.teal.800}' } },
357
- fg: { value: { _light: '{colors.teal.500}', _dark: '{colors.teal.100}' } },
358
- },
359
- cyan: {
360
- bg: { value: { _light: '{colors.cyan.50}', _dark: '{colors.cyan.800}' } },
361
- fg: { value: { _light: '{colors.cyan.500}', _dark: '{colors.cyan.100}' } },
362
- },
363
- },
364
- tag: {
365
- root: {
366
- subtle: {
367
- bg: { value: { _light: '{colors.blackAlpha.50}', _dark: '{colors.whiteAlpha.100}' } },
368
- fg: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
369
- },
370
- clickable: {
371
- bg: { value: { _light: '{colors.gray.100}', _dark: '{colors.gray.800}' } },
372
- fg: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
373
- },
374
- filter: {
375
- bg: { value: { _light: '{colors.blue.50}', _dark: '{colors.blue.800}' } },
376
- },
377
- select: {
378
- bg: {
379
- DEFAULT: { value: { _light: '{colors.gray.100}', _dark: '{colors.gray.800}' } },
380
- selected: { value: { _light: '{colors.blue.500}', _dark: '{colors.blue.900}' } },
381
- },
382
- fg: { value: { _light: '{colors.gray.500}', _dark: '{colors.whiteAlpha.800}' } },
383
- },
384
- },
385
- },
386
- table: {
387
- header: {
388
- bg: { value: { _light: '{colors.blackAlpha.100}', _dark: '{colors.whiteAlpha.200}' } },
389
- fg: { value: { _light: '{colors.blackAlpha.700}', _dark: '{colors.whiteAlpha.700}' } },
390
- },
391
- },
392
- checkbox: {
393
- control: {
394
- border: {
395
- DEFAULT: { value: { _light: '{colors.gray.100}', _dark: '{colors.gray.700}' } },
396
- hover: { value: { _light: '{colors.gray.200}', _dark: '{colors.gray.500}' } },
397
- readOnly: { value: { _light: '{colors.gray.200}', _dark: '{colors.gray.800}' } },
398
- },
399
- },
400
- },
401
- radio: {
402
- control: {
403
- border: {
404
- DEFAULT: { value: { _light: '{colors.gray.100}', _dark: '{colors.gray.700}' } },
405
- hover: { value: { _light: '{colors.gray.200}', _dark: '{colors.gray.500}' } },
406
- readOnly: { value: { _light: '{colors.gray.200}', _dark: '{colors.gray.800}' } },
407
- },
408
- },
409
- },
410
- stat: {
411
- indicator: {
412
- up: { value: { _light: '{colors.green.500}', _dark: '{colors.green.400}' } },
413
- down: { value: { _light: '{colors.red.600}', _dark: '{colors.red.400}' } },
414
- },
415
- },
416
- rating: {
417
- DEFAULT: { value: { _light: '{colors.gray.200}', _dark: '{colors.gray.700}' } },
418
- highlighted: { value: '{colors.yellow.400}' },
419
- },
420
- heading: {
421
- DEFAULT: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
422
- },
423
- text: {
424
- primary: { value: { _light: '{colors.blackAlpha.800}', _dark: '{colors.whiteAlpha.800}' } },
425
- secondary: { value: { _light: '{colors.gray.500}', _dark: '{colors.gray.400}' } },
426
- error: { value: '{colors.red.500}' },
427
- },
428
- border: {
429
- divider: { value: { _light: '{colors.blackAlpha.100}', _dark: '{colors.whiteAlpha.100}' } },
430
- error: { value: '{colors.red.500}' },
431
- },
432
- icon: {
433
- backTo: { value: '{colors.gray.400}' },
434
- externalLink: { value: { _light: '{colors.gray.400}', _dark: '{colors.gray.500}' } },
435
- info: { value: { _light: '{colors.gray.400}', _dark: '{colors.gray.500}' } },
436
- },
437
- address: {
438
- highlighted: {
439
- bg: { value: { _light: '{colors.blue.50}', _dark: '{colors.blue.900}' } },
440
- border: { value: { _light: '{colors.blue.200}', _dark: '{colors.blue.600}' } },
441
- },
442
- },
443
- global: {
444
- body: {
445
- bg: { value: { _light: '{colors.white}', _dark: '{colors.black}' } },
446
- fg: { value: '{colors.text.primary}' },
447
- },
448
- mark: {
449
- bg: { value: { _light: '{colors.green.100}', _dark: '{colors.green.800}' } },
450
- },
451
- scrollbar: {
452
- thumb: { value: { _light: '{colors.blackAlpha.300}', _dark: '{colors.whiteAlpha.300}' } },
453
- },
454
- },
455
- },
456
- shadows: {
457
- popover: {
458
- DEFAULT: { value: { _light: '{shadows.size.2xl}', _dark: '{shadows.dark-lg}' } },
459
- },
460
- drawer: {
461
- DEFAULT: { value: { _light: '{shadows.size.lg}', _dark: '{shadows.dark-lg}' } },
462
- },
463
- },
464
- opacity: {
465
- control: {
466
- disabled: { value: '0.2' },
467
- },
468
- },
469
- };
470
-
471
- export default semanticTokens;
@@ -1,19 +0,0 @@
1
- import type { ThemingConfig } from '@chakra-ui/react';
2
-
3
- import type { ExcludeUndefined } from 'types/utils';
4
-
5
- const shadows: ExcludeUndefined<ThemingConfig['tokens']>['shadows'] = {
6
- action_bar: { value: '0 4px 4px -4px rgb(0 0 0 / 10%), 0 2px 4px -4px rgb(0 0 0 / 6%)' },
7
- size: {
8
- xs: { value: '0px 0px 0px 1px rgba(0, 0, 0, 0.05)' },
9
- sm: { value: '0px 1px 2px 0px rgba(0, 0, 0, 0.05)' },
10
- base: { value: '0px 1px 2px 0px rgba(0, 0, 0, 0.06), 0px 1px 3px 0px rgba(0, 0, 0, 0.1)' },
11
- md: { value: '0px 2px 4px -1px rgba(0, 0, 0, 0.06), 0px 4px 6px -1px rgba(0, 0, 0, 0.1)' },
12
- lg: { value: '0px 4px 6px -2px rgba(0, 0, 0, 0.05), 0px 10px 15px -3px rgba(0, 0, 0, 0.1)' },
13
- xl: { value: '0px 10px 10px -5px rgba(0, 0, 0, 0.04), 0px 20px 25px -5px rgba(0, 0, 0, 0.1)' },
14
- '2xl': { value: '0px 15px 50px -12px rgba(0, 0, 0, 0.25)' },
15
- },
16
- 'dark-lg': { value: '0px 15px 40px 0px rgba(0, 0, 0, 0.4), 0px 5px 10px 0px rgba(0, 0, 0, 0.2), 0px 0px 0px 1px rgba(0, 0, 0, 0.1)' },
17
- };
18
-
19
- export default shadows;
@@ -1,93 +0,0 @@
1
- import type { ThemingConfig } from '@chakra-ui/react';
2
-
3
- import type { ExcludeUndefined } from 'types/utils';
4
-
5
- import config from 'configs/app';
6
-
7
- export const BODY_TYPEFACE = config.UI.fonts.body?.name ?? 'Inter';
8
- export const HEADING_TYPEFACE = config.UI.fonts.heading?.name ?? 'Poppins';
9
-
10
- export const fonts: ExcludeUndefined<ThemingConfig['tokens']>['fonts'] = {
11
- heading: { value: `${ HEADING_TYPEFACE }, sans-serif` },
12
- body: { value: `${ BODY_TYPEFACE }, sans-serif` },
13
- };
14
-
15
- export const textStyles: ThemingConfig['textStyles'] = {
16
- heading: {
17
- xl: {
18
- value: {
19
- fontSize: '32px',
20
- lineHeight: '40px',
21
- fontWeight: '500',
22
- letterSpacing: '-0.5px',
23
- fontFamily: 'heading',
24
- },
25
- },
26
- lg: {
27
- value: {
28
- fontSize: '24px',
29
- lineHeight: '32px',
30
- fontWeight: '500',
31
- fontFamily: 'heading',
32
- },
33
- },
34
- md: {
35
- value: {
36
- fontSize: '18px',
37
- lineHeight: '24px',
38
- fontWeight: '500',
39
- fontFamily: 'heading',
40
- },
41
- },
42
- sm: {
43
- value: {
44
- fontSize: '16px',
45
- lineHeight: '24px',
46
- fontWeight: '500',
47
- fontFamily: 'heading',
48
- },
49
- },
50
- xs: {
51
- value: {
52
- fontSize: '14px',
53
- lineHeight: '20px',
54
- fontWeight: '600',
55
- fontFamily: 'heading',
56
- },
57
- },
58
- },
59
- text: {
60
- xl: {
61
- value: {
62
- fontSize: '20px',
63
- lineHeight: '28px',
64
- fontWeight: '400',
65
- fontFamily: 'body',
66
- },
67
- },
68
- md: {
69
- value: {
70
- fontSize: '16px',
71
- lineHeight: '24px',
72
- fontWeight: '400',
73
- fontFamily: 'body',
74
- },
75
- },
76
- sm: {
77
- value: {
78
- fontSize: '14px',
79
- lineHeight: '20px',
80
- fontWeight: '400',
81
- fontFamily: 'body',
82
- },
83
- },
84
- xs: {
85
- value: {
86
- fontSize: '12px',
87
- lineHeight: '16px',
88
- fontWeight: '400',
89
- fontFamily: 'body',
90
- },
91
- },
92
- },
93
- };
@@ -1,20 +0,0 @@
1
- export const zIndex = {
2
- hide: { value: -1 },
3
- auto: { value: 'auto' },
4
- base: { value: 0 },
5
- docked: { value: 10 },
6
- dropdown: { value: 1000 },
7
- sticky: { value: 1100 },
8
- sticky1: { value: 1101 },
9
- sticky2: { value: 1102 },
10
- banner: { value: 1200 },
11
- overlay: { value: 1300 },
12
- modal: { value: 1400 },
13
- popover: { value: 1500 },
14
- tooltip: { value: 1550 }, // otherwise tooltips will not be visible in modals
15
- tooltip2: { value: 1551 }, // for tooltips in tooltips
16
- skipLink: { value: 1600 },
17
- toast: { value: 1700 },
18
- };
19
-
20
- export default zIndex;
@@ -1,57 +0,0 @@
1
- import type { SystemConfig } from '@chakra-ui/react';
2
-
3
- import addressEntity from './globals/address-entity';
4
- import recaptcha from './globals/recaptcha';
5
- import scrollbar from './globals/scrollbar';
6
-
7
- const webkitAutofillOverrides = {
8
- WebkitTextFillColor: 'var(--chakra-colors-input-fg)',
9
- '-webkit-box-shadow': '0 0 0px 1000px var(--chakra-colors-input-bg) inset',
10
- transition: 'background-color 5000s ease-in-out 0s',
11
- };
12
-
13
- const webkitAutofillRules = {
14
- '&:-webkit-autofill': webkitAutofillOverrides,
15
- '&:-webkit-autofill:hover': webkitAutofillOverrides,
16
- '&:-webkit-autofill:focus': webkitAutofillOverrides,
17
- };
18
-
19
- const globalCss: SystemConfig['globalCss'] = {
20
- body: {
21
- bg: 'global.body.bg',
22
- color: 'global.body.fg',
23
- WebkitTapHighlightColor: 'transparent',
24
- fontVariantLigatures: 'no-contextual',
25
- focusRingStyle: 'hidden',
26
- },
27
- mark: {
28
- bg: 'global.mark.bg',
29
- color: 'inherit',
30
- },
31
- 'svg *::selection': {
32
- color: 'none',
33
- background: 'none',
34
- },
35
- form: {
36
- w: '100%',
37
- },
38
- input: {
39
- // hide number input arrows in Google Chrome
40
- '&::-webkit-outer-spin-button, &::-webkit-inner-spin-button': {
41
- WebkitAppearance: 'none',
42
- margin: 0,
43
- },
44
- ...webkitAutofillRules,
45
- },
46
- textarea: {
47
- ...webkitAutofillRules,
48
- },
49
- select: {
50
- ...webkitAutofillRules,
51
- },
52
- ...recaptcha,
53
- ...scrollbar,
54
- ...addressEntity,
55
- };
56
-
57
- export default globalCss;
@@ -1,33 +0,0 @@
1
- const styles = {
2
- '.address-entity': {
3
- '&.address-entity_highlighted': {
4
- _before: {
5
- content: `" "`,
6
- position: 'absolute',
7
- py: 1,
8
- pl: 1,
9
- pr: 0,
10
- top: '-5px',
11
- left: '-5px',
12
- width: `calc(100% + 6px)`,
13
- height: 'calc(100% + 10px)',
14
- borderRadius: 'base',
15
- borderColor: 'address.highlighted.border',
16
- borderWidth: '1px',
17
- borderStyle: 'dashed',
18
- bgColor: 'address.highlighted.bg',
19
- zIndex: -1,
20
- },
21
- },
22
- },
23
- '.address-entity_no-copy': {
24
- '&.address-entity_highlighted': {
25
- _before: {
26
- pr: 2,
27
- width: `calc(100% + 6px + 8px)`,
28
- },
29
- },
30
- },
31
- };
32
-
33
- export default styles;