cherry-styled-components 0.1.13 → 0.1.14

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 (50) hide show
  1. package/dist/box.js +20 -11
  2. package/dist/button.js +80 -150
  3. package/dist/col.js +26 -18
  4. package/dist/container.js +32 -30
  5. package/dist/flex.js +39 -34
  6. package/dist/grid.js +36 -33
  7. package/dist/icon.js +14 -23
  8. package/dist/index.js +9 -76
  9. package/dist/input.js +136 -312
  10. package/dist/max-width.js +41 -26
  11. package/dist/range.js +74 -141
  12. package/dist/select.js +56 -100
  13. package/dist/space.js +38 -24
  14. package/dist/styled-components/registry.js +17 -19
  15. package/dist/styled-components/theme-provider.js +27 -31
  16. package/dist/textarea.js +49 -73
  17. package/dist/toggle.js +66 -121
  18. package/dist/utils/global.js +11 -92
  19. package/dist/utils/icons.js +66 -77
  20. package/dist/utils/mixins.js +41 -83
  21. package/dist/utils/theme.js +265 -142
  22. package/dist/utils/typography.js +31 -49
  23. package/package.json +10 -9
  24. /package/dist/{App.d.ts → src/App.d.ts} +0 -0
  25. /package/dist/{lib → src/lib}/box.d.ts +0 -0
  26. /package/dist/{lib → src/lib}/button.d.ts +0 -0
  27. /package/dist/{lib → src/lib}/col.d.ts +0 -0
  28. /package/dist/{lib → src/lib}/container.d.ts +0 -0
  29. /package/dist/{lib → src/lib}/flex.d.ts +0 -0
  30. /package/dist/{lib → src/lib}/grid.d.ts +0 -0
  31. /package/dist/{lib → src/lib}/icon.d.ts +0 -0
  32. /package/dist/{lib → src/lib}/index.d.ts +0 -0
  33. /package/dist/{lib → src/lib}/input.d.ts +0 -0
  34. /package/dist/{lib → src/lib}/max-width.d.ts +0 -0
  35. /package/dist/{lib → src/lib}/range.d.ts +0 -0
  36. /package/dist/{lib → src/lib}/select.d.ts +0 -0
  37. /package/dist/{lib → src/lib}/space.d.ts +0 -0
  38. /package/dist/{lib → src/lib}/styled-components/index.d.ts +0 -0
  39. /package/dist/{lib → src/lib}/styled-components/registry.d.ts +0 -0
  40. /package/dist/{lib → src/lib}/styled-components/theme-provider.d.ts +0 -0
  41. /package/dist/{lib → src/lib}/textarea.d.ts +0 -0
  42. /package/dist/{lib → src/lib}/toggle.d.ts +0 -0
  43. /package/dist/{lib → src/lib}/utils/global.d.ts +0 -0
  44. /package/dist/{lib → src/lib}/utils/icons.d.ts +0 -0
  45. /package/dist/{lib → src/lib}/utils/index.d.ts +0 -0
  46. /package/dist/{lib → src/lib}/utils/mixins.d.ts +0 -0
  47. /package/dist/{lib → src/lib}/utils/theme.d.ts +0 -0
  48. /package/dist/{lib → src/lib}/utils/typography.d.ts +0 -0
  49. /package/dist/{main.d.ts → src/main.d.ts} +0 -0
  50. /package/dist/{toggle-theme.d.ts → src/toggle-theme.d.ts} +0 -0
@@ -1,88 +1,46 @@
1
1
  "use client";
2
- import { css } from "styled-components";
2
+ "use client";
3
3
  import { mq } from "./theme.js";
4
- const resetButton = css`
5
- box-sizing: border-box;
6
- appearance: none;
7
- border: none;
8
- background: none;
9
- padding: 0;
10
- margin: 0;
11
- cursor: pointer;
12
- outline: none;
13
- `;
14
- const resetInput = css`
15
- cursor: text;
16
- min-width: 100px;
17
- `;
18
- const fullWidthStyles = (fullWidth) => {
19
- if (fullWidth) {
20
- return css`
21
- width: 100%;
22
- `;
23
- }
24
- };
25
- const statusBorderStyles = ($error, $success, theme) => {
26
- if ($error) {
27
- return css`
28
- border-color: ${theme?.colors.error};
29
- `;
30
- }
31
- if ($success) {
32
- return css`
33
- border-color: ${theme?.colors.success};
34
- `;
35
- }
4
+ import { css } from "styled-components";
5
+ //#region src/lib/utils/mixins.tsx
6
+ var resetButton = css([`box-sizing:border-box;appearance:none;border:none;background:none;padding:0;margin:0;cursor:pointer;outline:none;`]);
7
+ var resetInput = css([`cursor:text;min-width:100px;`]);
8
+ var fullWidthStyles = (fullWidth) => {
9
+ if (fullWidth) return css([`width:100%;`]);
36
10
  };
37
- const formElementHeightStyles = ($size) => {
38
- if ($size === "big") {
39
- return css`
40
- height: 60px;
41
- `;
42
- }
43
- if ($size === "small") {
44
- return css`
45
- height: 40px;
46
- `;
47
- }
48
- return css`
49
- height: 50px;
50
- `;
11
+ var statusBorderStyles = ($error, $success, theme) => {
12
+ if ($error) return css([`border-color:`, `;`], theme?.colors.error);
13
+ if ($success) return css([`border-color:`, `;`], theme?.colors.success);
51
14
  };
52
- const generateGapStyles = (size, gap) => css`
53
- ${mq(size)} {
54
- gap: ${gap === "none" ? "0" : `${gap}px`};
55
- }
56
- `;
57
- const generateColsStyles = (size, cols) => css`
58
- ${mq(size)} {
59
- grid-template-columns: repeat(${cols || 3}, minmax(0, 1fr));
60
- }
61
- `;
62
- const generateColSpanStyles = (size, span) => css`
63
- ${mq(size)} {
64
- grid-column: span ${span};
65
- }
66
- `;
67
- const generatePaddingStyles = (size, padding) => css`
68
- ${mq(size)} {
69
- padding: ${padding === "none" ? "0" : `${padding}px`};
70
- }
71
- `;
72
- const generateJustifyContentStyles = (size, justifyContent) => css`
73
- ${mq(size)} {
74
- justify-content: ${justifyContent && `${justifyContent}`};
75
- }
76
- `;
77
- export {
78
- formElementHeightStyles,
79
- fullWidthStyles,
80
- generateColSpanStyles,
81
- generateColsStyles,
82
- generateGapStyles,
83
- generateJustifyContentStyles,
84
- generatePaddingStyles,
85
- resetButton,
86
- resetInput,
87
- statusBorderStyles
15
+ var formElementHeightStyles = ($size) => {
16
+ if ($size === "big") return css([`height:60px;`]);
17
+ if ($size === "small") return css([`height:40px;`]);
18
+ return css([`height:50px;`]);
88
19
  };
20
+ var generateGapStyles = (size, gap) => css([
21
+ ``,
22
+ `{gap:`,
23
+ `;}`
24
+ ], mq(size), gap === "none" ? "0" : `${gap}px`);
25
+ var generateColsStyles = (size, cols) => css([
26
+ ``,
27
+ `{grid-template-columns:repeat(`,
28
+ `,minmax(0,1fr));}`
29
+ ], mq(size), cols || 3);
30
+ var generateColSpanStyles = (size, span) => css([
31
+ ``,
32
+ `{grid-column:span `,
33
+ `;}`
34
+ ], mq(size), span);
35
+ var generatePaddingStyles = (size, padding) => css([
36
+ ``,
37
+ `{padding:`,
38
+ `;}`
39
+ ], mq(size), padding === "none" ? "0" : `${padding}px`);
40
+ var generateJustifyContentStyles = (size, justifyContent) => css([
41
+ ``,
42
+ `{justify-content:`,
43
+ `;}`
44
+ ], mq(size), justifyContent && `${justifyContent}`);
45
+ //#endregion
46
+ export { formElementHeightStyles, fullWidthStyles, generateColSpanStyles, generateColsStyles, generateGapStyles, generateJustifyContentStyles, generatePaddingStyles, resetButton, resetInput, statusBorderStyles };
@@ -1,156 +1,279 @@
1
1
  "use client";
2
- const breakpoints = {
3
- xs: 0,
4
- sm: 576,
5
- md: 768,
6
- lg: 992,
7
- xl: 1200,
8
- xxl: 1440,
9
- xxxl: 1920
2
+ "use client";
3
+ //#region src/lib/utils/theme.ts
4
+ var breakpoints = {
5
+ xs: 0,
6
+ sm: 576,
7
+ md: 768,
8
+ lg: 992,
9
+ xl: 1200,
10
+ xxl: 1440,
11
+ xxxl: 1920
10
12
  };
11
13
  function mq(minWidth) {
12
- return `@media screen and (min-width: ${breakpoints[minWidth]}px)`;
14
+ return `@media screen and (min-width: ${breakpoints[minWidth]}px)`;
13
15
  }
14
- const spacing = {
15
- maxWidth: { xs: "1280px", xxxl: "1440px" },
16
- padding: { xs: "20px", lg: "40px" },
17
- radius: { xs: "6px", lg: "12px", xl: "30px" },
18
- gridGap: { xs: "20px", lg: "40px" }
19
- };
20
- const colors = {
21
- primaryLight: "#91aec4",
22
- primary: "#4d6f8b",
23
- primaryDark: "#194569",
24
- secondaryLight: "#a4b17b",
25
- secondary: "#5c6e46",
26
- secondaryDark: "#354c2b",
27
- tertiaryLight: "#ebccb9",
28
- tertiary: "#816b5a",
29
- tertiaryDark: "#675445",
30
- grayLight: "#e5e7eb",
31
- gray: "#9ca3af",
32
- grayDark: "#4b5563",
33
- success: "#84cc16",
34
- error: "#ef4444",
35
- warning: "#eab308",
36
- info: "#06b6d4",
37
- dark: "#000000",
38
- light: "#ffffff"
16
+ var spacing = {
17
+ maxWidth: {
18
+ xs: "1280px",
19
+ xxxl: "1440px"
20
+ },
21
+ padding: {
22
+ xs: "20px",
23
+ lg: "40px"
24
+ },
25
+ radius: {
26
+ xs: "6px",
27
+ lg: "12px",
28
+ xl: "30px"
29
+ },
30
+ gridGap: {
31
+ xs: "20px",
32
+ lg: "40px"
33
+ }
39
34
  };
40
- const colorsDark = {
41
- primaryLight: "#79C5FF",
42
- primary: "#6198C6",
43
- primaryDark: "#339DF4",
44
- secondaryLight: "#a4b17b",
45
- secondary: "#5c6e46",
46
- secondaryDark: "#354c2b",
47
- tertiaryLight: "#ebccb9",
48
- tertiary: "#816b5a",
49
- tertiaryDark: "#675445",
50
- grayLight: "#1a1a1a",
51
- gray: "#454444",
52
- grayDark: "#808080",
53
- success: "#84cc16",
54
- error: "#ef4444",
55
- warning: "#eab308",
56
- info: "#06b6d4",
57
- dark: "#ffffff",
58
- light: "#000000"
35
+ var colors = {
36
+ primaryLight: "#91aec4",
37
+ primary: "#4d6f8b",
38
+ primaryDark: "#194569",
39
+ secondaryLight: "#a4b17b",
40
+ secondary: "#5c6e46",
41
+ secondaryDark: "#354c2b",
42
+ tertiaryLight: "#ebccb9",
43
+ tertiary: "#816b5a",
44
+ tertiaryDark: "#675445",
45
+ grayLight: "#e5e7eb",
46
+ gray: "#9ca3af",
47
+ grayDark: "#4b5563",
48
+ success: "#84cc16",
49
+ error: "#ef4444",
50
+ warning: "#eab308",
51
+ info: "#06b6d4",
52
+ dark: "#000000",
53
+ light: "#ffffff"
59
54
  };
60
- const shadows = {
61
- xs: "0px 4px 4px 0px rgba(18, 18, 18, 0.04), 0px 1px 3px 0px rgba(39, 41, 45, 0.02)",
62
- sm: "0px 4px 4px 0px rgba(18, 18, 18, 0.08), 0px 1px 3px 0px rgba(39, 41, 45, 0.04)",
63
- md: "0px 8px 8px 0px rgba(18, 18, 18, 0.16), 0px 2px 3px 0px rgba(39, 41, 45, 0.06)",
64
- lg: "0px 16px 24px 0px rgba(18, 18, 18, 0.20), 0px 2px 3px 0px rgba(39, 41, 45, 0.08)",
65
- xl: "0px 24px 32px 0px rgba(18, 18, 18, 0.24), 0px 2px 3px 0px rgba(39, 41, 45, 0.12)"
55
+ var colorsDark = {
56
+ primaryLight: "#79C5FF",
57
+ primary: "#6198C6",
58
+ primaryDark: "#339DF4",
59
+ secondaryLight: "#a4b17b",
60
+ secondary: "#5c6e46",
61
+ secondaryDark: "#354c2b",
62
+ tertiaryLight: "#ebccb9",
63
+ tertiary: "#816b5a",
64
+ tertiaryDark: "#675445",
65
+ grayLight: "#1a1a1a",
66
+ gray: "#454444",
67
+ grayDark: "#808080",
68
+ success: "#84cc16",
69
+ error: "#ef4444",
70
+ warning: "#eab308",
71
+ info: "#06b6d4",
72
+ dark: "#ffffff",
73
+ light: "#000000"
66
74
  };
67
- const shadowsDark = {
68
- xs: "0px 4px 4px 0px rgba(255, 255, 255, 0.04), 0px 1px 3px 0px rgba(255, 255, 255, 0.02)",
69
- sm: "0px 4px 4px 0px rgba(255, 255, 255, 0.08), 0px 1px 3px 0px rgba(255, 255, 255, 0.04)",
70
- md: "0px 8px 8px 0px rgba(255, 255, 255, 0.16), 0px 2px 3px 0px rgba(255, 255, 255, 0.06)",
71
- lg: "0px 16px 24px 0px rgba(255, 255, 255, 0.20), 0px 2px 3px 0px rgba(255, 255, 255, 0.08)",
72
- xl: "0px 24px 32px 0px rgba(255, 255, 255, 0.24), 0px 2px 3px 0px rgba(255, 255, 255, 0.12)"
75
+ var shadows = {
76
+ xs: "0px 4px 4px 0px rgba(18, 18, 18, 0.04), 0px 1px 3px 0px rgba(39, 41, 45, 0.02)",
77
+ sm: "0px 4px 4px 0px rgba(18, 18, 18, 0.08), 0px 1px 3px 0px rgba(39, 41, 45, 0.04)",
78
+ md: "0px 8px 8px 0px rgba(18, 18, 18, 0.16), 0px 2px 3px 0px rgba(39, 41, 45, 0.06)",
79
+ lg: "0px 16px 24px 0px rgba(18, 18, 18, 0.20), 0px 2px 3px 0px rgba(39, 41, 45, 0.08)",
80
+ xl: "0px 24px 32px 0px rgba(18, 18, 18, 0.24), 0px 2px 3px 0px rgba(39, 41, 45, 0.12)"
73
81
  };
74
- const fonts = {
75
- text: "Inter",
76
- head: "Inter",
77
- mono: "monospace"
82
+ var shadowsDark = {
83
+ xs: "0px 4px 4px 0px rgba(255, 255, 255, 0.04), 0px 1px 3px 0px rgba(255, 255, 255, 0.02)",
84
+ sm: "0px 4px 4px 0px rgba(255, 255, 255, 0.08), 0px 1px 3px 0px rgba(255, 255, 255, 0.04)",
85
+ md: "0px 8px 8px 0px rgba(255, 255, 255, 0.16), 0px 2px 3px 0px rgba(255, 255, 255, 0.06)",
86
+ lg: "0px 16px 24px 0px rgba(255, 255, 255, 0.20), 0px 2px 3px 0px rgba(255, 255, 255, 0.08)",
87
+ xl: "0px 24px 32px 0px rgba(255, 255, 255, 0.24), 0px 2px 3px 0px rgba(255, 255, 255, 0.12)"
78
88
  };
79
- const fontSizes = {
80
- hero1: { xs: "72px", lg: "128px" },
81
- hero2: { xs: "60px", lg: "96px" },
82
- hero3: { xs: "36px", lg: "72px" },
83
- h1: { xs: "40px", lg: "60px" },
84
- h2: { xs: "30px", lg: "36px" },
85
- h3: { xs: "28px", lg: "30px" },
86
- h4: { xs: "26px", lg: "24px" },
87
- h5: { xs: "18px", lg: "20px" },
88
- h6: { xs: "16px", lg: "18px" },
89
- text: { xs: "14px", lg: "16px" },
90
- strong: { xs: "14px", lg: "16px" },
91
- small: { xs: "12px", lg: "14px" },
92
- blockquote: { xs: "16px", lg: "18px" },
93
- code: { xs: "14px", lg: "16px" },
94
- button: { xs: "16px", lg: "16px" },
95
- buttonBig: { xs: "18px", lg: "18px" },
96
- buttonSmall: { xs: "14px", lg: "14px" },
97
- input: { xs: "16px", lg: "16px" },
98
- inputBig: { xs: "18px", lg: "18px" },
99
- inputSmall: { xs: "14px", lg: "14px" }
89
+ var fonts = {
90
+ text: "Inter",
91
+ head: "Inter",
92
+ mono: "monospace"
100
93
  };
101
- const lineHeights = {
102
- hero1: { xs: "1.10", lg: "1.10" },
103
- hero2: { xs: "1.10", lg: "1.10" },
104
- hero3: { xs: "1.20", lg: "1.10" },
105
- h1: { xs: "1.50", lg: "1.40" },
106
- h2: { xs: "1.50", lg: "1.50" },
107
- h3: { xs: "1.30", lg: "1.50" },
108
- h4: { xs: "1.30", lg: "1.50" },
109
- h5: { xs: "1.60", lg: "1.50" },
110
- h6: { xs: "1.60", lg: "1.60" },
111
- text: { xs: "1.70", lg: "1.70" },
112
- strong: { xs: "1.70", lg: "1.70" },
113
- small: { xs: "1.70", lg: "1.70" },
114
- blockquote: { xs: "1.70", lg: "1.70" },
115
- code: { xs: "1.70", lg: "1.70" },
116
- button: { xs: "1.00", lg: "1.00" },
117
- buttonBig: { xs: "1.00", lg: "1.00" },
118
- buttonSmall: { xs: "1.00", lg: "1.00" },
119
- input: { xs: "1.00", lg: "1.00" },
120
- inputBig: { xs: "1.00", lg: "1.00" },
121
- inputSmall: { xs: "1.00", lg: "1.00" }
94
+ var fontSizes = {
95
+ hero1: {
96
+ xs: "72px",
97
+ lg: "128px"
98
+ },
99
+ hero2: {
100
+ xs: "60px",
101
+ lg: "96px"
102
+ },
103
+ hero3: {
104
+ xs: "36px",
105
+ lg: "72px"
106
+ },
107
+ h1: {
108
+ xs: "40px",
109
+ lg: "60px"
110
+ },
111
+ h2: {
112
+ xs: "30px",
113
+ lg: "36px"
114
+ },
115
+ h3: {
116
+ xs: "28px",
117
+ lg: "30px"
118
+ },
119
+ h4: {
120
+ xs: "26px",
121
+ lg: "24px"
122
+ },
123
+ h5: {
124
+ xs: "18px",
125
+ lg: "20px"
126
+ },
127
+ h6: {
128
+ xs: "16px",
129
+ lg: "18px"
130
+ },
131
+ text: {
132
+ xs: "14px",
133
+ lg: "16px"
134
+ },
135
+ strong: {
136
+ xs: "14px",
137
+ lg: "16px"
138
+ },
139
+ small: {
140
+ xs: "12px",
141
+ lg: "14px"
142
+ },
143
+ blockquote: {
144
+ xs: "16px",
145
+ lg: "18px"
146
+ },
147
+ code: {
148
+ xs: "14px",
149
+ lg: "16px"
150
+ },
151
+ button: {
152
+ xs: "16px",
153
+ lg: "16px"
154
+ },
155
+ buttonBig: {
156
+ xs: "18px",
157
+ lg: "18px"
158
+ },
159
+ buttonSmall: {
160
+ xs: "14px",
161
+ lg: "14px"
162
+ },
163
+ input: {
164
+ xs: "16px",
165
+ lg: "16px"
166
+ },
167
+ inputBig: {
168
+ xs: "18px",
169
+ lg: "18px"
170
+ },
171
+ inputSmall: {
172
+ xs: "14px",
173
+ lg: "14px"
174
+ }
122
175
  };
123
- const theme = {
124
- breakpoints,
125
- spacing,
126
- colors,
127
- shadows,
128
- fonts,
129
- fontSizes,
130
- lineHeights,
131
- isDark: false
176
+ var lineHeights = {
177
+ hero1: {
178
+ xs: "1.10",
179
+ lg: "1.10"
180
+ },
181
+ hero2: {
182
+ xs: "1.10",
183
+ lg: "1.10"
184
+ },
185
+ hero3: {
186
+ xs: "1.20",
187
+ lg: "1.10"
188
+ },
189
+ h1: {
190
+ xs: "1.50",
191
+ lg: "1.40"
192
+ },
193
+ h2: {
194
+ xs: "1.50",
195
+ lg: "1.50"
196
+ },
197
+ h3: {
198
+ xs: "1.30",
199
+ lg: "1.50"
200
+ },
201
+ h4: {
202
+ xs: "1.30",
203
+ lg: "1.50"
204
+ },
205
+ h5: {
206
+ xs: "1.60",
207
+ lg: "1.50"
208
+ },
209
+ h6: {
210
+ xs: "1.60",
211
+ lg: "1.60"
212
+ },
213
+ text: {
214
+ xs: "1.70",
215
+ lg: "1.70"
216
+ },
217
+ strong: {
218
+ xs: "1.70",
219
+ lg: "1.70"
220
+ },
221
+ small: {
222
+ xs: "1.70",
223
+ lg: "1.70"
224
+ },
225
+ blockquote: {
226
+ xs: "1.70",
227
+ lg: "1.70"
228
+ },
229
+ code: {
230
+ xs: "1.70",
231
+ lg: "1.70"
232
+ },
233
+ button: {
234
+ xs: "1.00",
235
+ lg: "1.00"
236
+ },
237
+ buttonBig: {
238
+ xs: "1.00",
239
+ lg: "1.00"
240
+ },
241
+ buttonSmall: {
242
+ xs: "1.00",
243
+ lg: "1.00"
244
+ },
245
+ input: {
246
+ xs: "1.00",
247
+ lg: "1.00"
248
+ },
249
+ inputBig: {
250
+ xs: "1.00",
251
+ lg: "1.00"
252
+ },
253
+ inputSmall: {
254
+ xs: "1.00",
255
+ lg: "1.00"
256
+ }
132
257
  };
133
- const themeDark = {
134
- breakpoints,
135
- spacing,
136
- colors: colorsDark,
137
- shadows: shadowsDark,
138
- fonts,
139
- fontSizes,
140
- lineHeights,
141
- isDark: true
258
+ var theme = {
259
+ breakpoints,
260
+ spacing,
261
+ colors,
262
+ shadows,
263
+ fonts,
264
+ fontSizes,
265
+ lineHeights,
266
+ isDark: false
142
267
  };
143
- export {
144
- breakpoints,
145
- colors,
146
- colorsDark,
147
- fontSizes,
148
- fonts,
149
- lineHeights,
150
- mq,
151
- shadows,
152
- shadowsDark,
153
- spacing,
154
- theme,
155
- themeDark
268
+ var themeDark = {
269
+ breakpoints,
270
+ spacing,
271
+ colors: colorsDark,
272
+ shadows: shadowsDark,
273
+ fonts,
274
+ fontSizes,
275
+ lineHeights,
276
+ isDark: true
156
277
  };
278
+ //#endregion
279
+ export { breakpoints, colors, colorsDark, fontSizes, fonts, lineHeights, mq, shadows, shadowsDark, spacing, theme, themeDark };
@@ -1,51 +1,33 @@
1
1
  "use client";
2
- import { css } from "styled-components";
2
+ "use client";
3
3
  import { mq } from "./theme.js";
4
- const createTypographyStyle = (key) => (theme) => css`
5
- font-size: ${theme.fontSizes[key].xs};
6
- line-height: ${theme.lineHeights[key].xs};
7
-
8
- ${mq("lg")} {
9
- font-size: ${theme.fontSizes[key].lg};
10
- line-height: ${theme.lineHeights[key].lg};
11
- }
12
- `;
13
- const styledHero1 = createTypographyStyle("hero1");
14
- const styledHero2 = createTypographyStyle("hero2");
15
- const styledHero3 = createTypographyStyle("hero3");
16
- const styledH1 = createTypographyStyle("h1");
17
- const styledH2 = createTypographyStyle("h2");
18
- const styledH3 = createTypographyStyle("h3");
19
- const styledH4 = createTypographyStyle("h4");
20
- const styledH5 = createTypographyStyle("h5");
21
- const styledH6 = createTypographyStyle("h6");
22
- const styledText = createTypographyStyle("text");
23
- const styledStrong = createTypographyStyle("strong");
24
- const styledSmall = createTypographyStyle("small");
25
- const styledBlockquote = createTypographyStyle("blockquote");
26
- const styledCode = createTypographyStyle("code");
27
- const styledButton = createTypographyStyle("button");
28
- const styledButtonBig = createTypographyStyle("buttonBig");
29
- const styledInput = createTypographyStyle("input");
30
- const styledInputBig = createTypographyStyle("inputBig");
31
- export {
32
- createTypographyStyle,
33
- styledBlockquote,
34
- styledButton,
35
- styledButtonBig,
36
- styledCode,
37
- styledH1,
38
- styledH2,
39
- styledH3,
40
- styledH4,
41
- styledH5,
42
- styledH6,
43
- styledHero1,
44
- styledHero2,
45
- styledHero3,
46
- styledInput,
47
- styledInputBig,
48
- styledSmall,
49
- styledStrong,
50
- styledText
51
- };
4
+ import { css } from "styled-components";
5
+ //#region src/lib/utils/typography.tsx
6
+ var createTypographyStyle = (key) => (theme) => css([
7
+ `font-size:`,
8
+ `;line-height:`,
9
+ `;`,
10
+ `{font-size:`,
11
+ `;line-height:`,
12
+ `;}`
13
+ ], theme.fontSizes[key].xs, theme.lineHeights[key].xs, mq("lg"), theme.fontSizes[key].lg, theme.lineHeights[key].lg);
14
+ var styledHero1 = createTypographyStyle("hero1");
15
+ var styledHero2 = createTypographyStyle("hero2");
16
+ var styledHero3 = createTypographyStyle("hero3");
17
+ var styledH1 = createTypographyStyle("h1");
18
+ var styledH2 = createTypographyStyle("h2");
19
+ var styledH3 = createTypographyStyle("h3");
20
+ var styledH4 = createTypographyStyle("h4");
21
+ var styledH5 = createTypographyStyle("h5");
22
+ var styledH6 = createTypographyStyle("h6");
23
+ var styledText = createTypographyStyle("text");
24
+ var styledStrong = createTypographyStyle("strong");
25
+ var styledSmall = createTypographyStyle("small");
26
+ var styledBlockquote = createTypographyStyle("blockquote");
27
+ var styledCode = createTypographyStyle("code");
28
+ var styledButton = createTypographyStyle("button");
29
+ var styledButtonBig = createTypographyStyle("buttonBig");
30
+ var styledInput = createTypographyStyle("input");
31
+ var styledInputBig = createTypographyStyle("inputBig");
32
+ //#endregion
33
+ export { createTypographyStyle, styledBlockquote, styledButton, styledButtonBig, styledCode, styledH1, styledH2, styledH3, styledH4, styledH5, styledH6, styledHero1, styledHero2, styledHero3, styledInput, styledInputBig, styledSmall, styledStrong, styledText };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cherry-styled-components",
3
- "version": "0.1.13",
3
+ "version": "0.1.14",
4
4
  "description": "Cherry is a design system for the modern web. Designed in Figma, built in React using Typescript.",
5
5
  "private": false,
6
6
  "type": "module",
@@ -41,7 +41,7 @@
41
41
  "format": "prettier --write ."
42
42
  },
43
43
  "dependencies": {
44
- "lucide-react": "^0.575.0",
44
+ "lucide-react": "^1.7.0",
45
45
  "polished": "^4.3.1"
46
46
  },
47
47
  "peerDependencies": {
@@ -50,20 +50,21 @@
50
50
  "styled-components": "^6.0.0"
51
51
  },
52
52
  "devDependencies": {
53
- "@types/node": "^25.3.0",
53
+ "@swc/plugin-styled-components": "^12.7.0",
54
+ "@types/node": "^25.5.0",
54
55
  "@types/react": "^19.2.14",
55
56
  "@types/react-dom": "^19.2.3",
56
- "@vitejs/plugin-react": "^5.1.4",
57
+ "@vitejs/plugin-react-swc": "^4.3.0",
57
58
  "eslint-plugin-react-hooks": "^7.0.1",
58
- "eslint-plugin-react-refresh": "^0.5.0",
59
- "next": "^16.1.6",
59
+ "eslint-plugin-react-refresh": "^0.5.2",
60
+ "next": "^16.2.1",
60
61
  "prettier": "^3.8.1",
61
62
  "react": "^19.2.4",
62
63
  "react-dom": "^19.2.4",
63
64
  "rollup-plugin-preserve-directives": "^0.4.0",
64
- "styled-components": "^6.3.11",
65
- "typescript": "^5.9.3",
66
- "vite": "^7.3.1",
65
+ "styled-components": "^6.3.12",
66
+ "typescript": "^6.0.2",
67
+ "vite": "^8.0.3",
67
68
  "vite-plugin-dts": "^4.5.4"
68
69
  }
69
70
  }