1
- import {
2
- createSystem ,
3
- defaultConfig ,
4
- defineConfig ,
5
- defineRecipe ,
6
- defineSlotRecipe ,
7
- } from "@chakra-ui/react"
8
- import { dialogAnatomy } from "@chakra-ui/react/anatomy"
1
+ import { createSystem , defaultConfig , defineConfig } from "@chakra-ui/react"
9
2
10
3
export const config = defineConfig ( {
11
- globalCss : {
12
- html : {
13
- // colorPalette: "red",
14
- } ,
15
- button : {
16
- // colorPalette: "teal",
17
- } ,
18
- } ,
19
4
theme : {
20
- slotRecipes : {
21
- dialog : defineSlotRecipe ( {
22
- slots : dialogAnatomy . keys ( ) ,
23
- base : {
24
- content : {
25
- // for some reason chakra use 14px now instead of 16 for dialogs
26
- textStyle : "none" ,
27
- } ,
28
- } ,
29
- } ) ,
30
- } ,
31
- recipes : {
32
- dialog : defineRecipe ( {
33
- base : {
34
- content : {
35
- // textStyle: "lg"
36
- } ,
37
- } ,
38
- } ) ,
39
- } ,
40
- semanticTokens : {
41
- colors : {
42
- bg : {
43
- DEFAULT : {
44
- value : "{colors.gray.800}" ,
45
- } ,
46
- muted : { value : "{colors.gray.700}" } ,
47
- emphasized : { value : "{colors.gray.600}" } ,
48
- // panel: { value: "#2d3748" },
49
- } ,
50
- border : {
51
- DEFAULT : {
52
- value : "{colors.gray.700}" ,
53
- } ,
54
- } ,
55
- gray : {
56
- muted : {
57
- value : "{colors.gray.700}" ,
58
- } ,
59
- } ,
60
- } ,
61
- } ,
62
5
tokens : {
63
- colors : {
64
- red : {
65
- 600 : {
66
- value : "#C53030" ,
67
- } ,
68
- 700 : {
69
- value : "#9B2C2C" ,
70
- } ,
71
- 800 : {
72
- value : "#822727" ,
73
- } ,
74
- 900 : {
75
- value : "#63171B" ,
76
- } ,
77
- } ,
78
- gray : {
79
- // using old chakra colors https://v2.chakra-ui.com/docs/styled-system/theme
80
- 900 : {
81
- value : "#171923" ,
82
- } ,
83
- 800 : {
84
- value : "#1A202C" ,
85
- } ,
86
- 700 : {
87
- value : "#2D3748" ,
88
- } ,
89
- } ,
90
- } ,
91
6
fonts : {
92
7
body : {
93
8
value : "Roboto, Roboto Fallback" ,
@@ -97,10 +12,4 @@ export const config = defineConfig({
97
12
} ,
98
13
} )
99
14
100
- // console.log(
101
- // defaultConfig.theme,
102
- // createSystem(defaultConfig, config)._config.theme,
103
- // )
104
-
105
15
export default createSystem ( defaultConfig , config )
106
- // export default createSystem(defaultConfig)
0 commit comments