@lets-events/react 12.2.10 → 12.2.11

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 (90) hide show
  1. package/.eslintrc.json +2 -2
  2. package/.turbo/turbo-build.log +19 -21
  3. package/CHANGELOG.md +6 -0
  4. package/dist/index.css +171 -0
  5. package/dist/index.d.mts +374 -2
  6. package/dist/index.d.ts +374 -2
  7. package/dist/index.js +37 -19
  8. package/dist/index.mjs +36 -19
  9. package/package.json +1 -1
  10. package/src/components/Alert.tsx +303 -303
  11. package/src/components/Avatar.tsx +55 -55
  12. package/src/components/Badge.tsx +125 -125
  13. package/src/components/Box.tsx +3 -3
  14. package/src/components/Button/index.tsx +16 -16
  15. package/src/components/Button/styledComponents.ts +300 -300
  16. package/src/components/ButtonGroup.tsx +484 -484
  17. package/src/components/Calendar/index.tsx +148 -148
  18. package/src/components/Calendar/styledComponents.ts +250 -250
  19. package/src/components/Card.tsx +48 -48
  20. package/src/components/CheckboxGroup.tsx +176 -176
  21. package/src/components/Container.tsx +39 -39
  22. package/src/components/Divider.tsx +7 -0
  23. package/src/components/Drawer/index.tsx +148 -138
  24. package/src/components/Drawer/styledComponents.ts +52 -52
  25. package/src/components/Dropdown.tsx +302 -302
  26. package/src/components/Filter.tsx +164 -164
  27. package/src/components/Flex.tsx +118 -118
  28. package/src/components/FormFields/AddressFormFields/CityFormField.tsx +111 -111
  29. package/src/components/FormFields/AddressFormFields/CountryFormField.tsx +33 -33
  30. package/src/components/FormFields/AddressFormFields/PostalCodeFormField.tsx +39 -39
  31. package/src/components/FormFields/AddressFormFields/StateFormField.tsx +32 -32
  32. package/src/components/FormFields/AddressFormFields/index.tsx +141 -141
  33. package/src/components/FormFields/BirthDateFormField.tsx +84 -84
  34. package/src/components/FormFields/CNPJFormField.tsx +87 -87
  35. package/src/components/FormFields/CPFFormField.tsx +78 -78
  36. package/src/components/FormFields/CalendarFormField.tsx +95 -95
  37. package/src/components/FormFields/CheckboxGroupFormField.tsx +91 -91
  38. package/src/components/FormFields/EmailFormField.tsx +27 -27
  39. package/src/components/FormFields/Form.tsx +39 -39
  40. package/src/components/FormFields/IdentityDocumentNumberFormField.tsx +32 -32
  41. package/src/components/FormFields/MultiSelectFormField.tsx +64 -64
  42. package/src/components/FormFields/PhoneFormField.tsx +40 -40
  43. package/src/components/FormFields/RadioGroupFormField.tsx +84 -84
  44. package/src/components/FormFields/RichEditorFormField.tsx +103 -103
  45. package/src/components/FormFields/SelectFormField.tsx +93 -93
  46. package/src/components/FormFields/SwitchFormField.tsx +46 -46
  47. package/src/components/FormFields/TextAreaFormField.tsx +57 -57
  48. package/src/components/FormFields/TextFormField.tsx +112 -112
  49. package/src/components/FormFields/TimePickerFormField.tsx +88 -88
  50. package/src/components/FormFields/subComponents/ErrorFormMessage.tsx +36 -36
  51. package/src/components/FormFields/subComponents/FormLabel.tsx +29 -29
  52. package/src/components/FormFields/utils/validation.ts +23 -23
  53. package/src/components/Grid.tsx +137 -137
  54. package/src/components/Icon.tsx +47 -47
  55. package/src/components/MenuDropdown/index.tsx +38 -38
  56. package/src/components/MenuDropdown/styledComponents.ts +31 -31
  57. package/src/components/Modal.tsx +90 -90
  58. package/src/components/MultiSelect/index.tsx +243 -243
  59. package/src/components/MultiSelect/styledComponents.ts +160 -160
  60. package/src/components/RadioGroup.tsx +210 -210
  61. package/src/components/RichEditor/QuillComponent.tsx +457 -457
  62. package/src/components/RichEditor/RichEditor.tsx +49 -49
  63. package/src/components/RichEditor/index.ts +2 -2
  64. package/src/components/RichEditor/styledComponents.ts +1151 -1151
  65. package/src/components/Section.tsx +33 -33
  66. package/src/components/Step.tsx +164 -164
  67. package/src/components/Switch.tsx +108 -108
  68. package/src/components/Text.tsx +38 -38
  69. package/src/components/TextField.tsx +372 -372
  70. package/src/components/TextareaField.tsx +127 -127
  71. package/src/components/TimePicker.tsx +328 -328
  72. package/src/components/Toast/components/ToastItem.tsx +41 -41
  73. package/src/components/Toast/components/ToastProvider.tsx +63 -63
  74. package/src/components/Toast/hooks/useToast.ts +12 -12
  75. package/src/components/Toast/index.tsx +5 -5
  76. package/src/components/Toast/styles/index.ts +135 -135
  77. package/src/components/Toast/types/index.ts +46 -46
  78. package/src/components/Tooltip/index.tsx +66 -66
  79. package/src/components/Tooltip/styles.ts +77 -77
  80. package/src/hooks/useCountries.ts +41 -41
  81. package/src/hooks/useImageUpload.ts +139 -139
  82. package/src/hooks/useOnClickOutside.tsx +42 -42
  83. package/src/index.tsx +69 -68
  84. package/src/styles/index.ts +38 -38
  85. package/src/types/typographyValues.ts +178 -178
  86. package/src/utils/getNestedValue.ts +3 -3
  87. package/src/utils/states.ts +29 -29
  88. package/src/utils/uploadService.ts +180 -180
  89. package/tsconfig.json +3 -3
  90. package/tsup.config.ts +38 -38
@@ -1,250 +1,250 @@
1
- import { styled } from "../../styles";
2
-
3
- export const CalendarStyled = styled("div", {
4
- fontFamily: "$default",
5
- lineHeight: "$base",
6
- fontSize: "$14",
7
- borderRadius: "$sm",
8
- position: "relative",
9
- width: "fit-content",
10
- variants: {
11
- expand: {
12
- true: {
13
- width: "100%",
14
- flex: "1",
15
- display: "flex",
16
- },
17
- },
18
- },
19
- });
20
- export const CalendarButtonStyled = styled("button", {
21
- backgroundColor: "transparent",
22
- border: "none",
23
- maxWidth: "200px",
24
- padding: "0",
25
- cursor: "pointer",
26
- "> div > div": {
27
- paddingLeft: "0",
28
- input: {
29
- textAlign: "right",
30
- },
31
- },
32
- variants: {
33
- expand: {
34
- true: {
35
- flex: "1",
36
- display: "flex",
37
- maxWidth: "100%",
38
- },
39
- },
40
- },
41
- });
42
- export const CalendarContentStyled = styled("div", {
43
- fontFamily: "$default",
44
- lineHeight: "$base",
45
- fontSize: "$14",
46
- maxWidth: "fit-content",
47
- border: "1px solid $neutral300",
48
- borderRadius: "$sm",
49
- boxShadow: "0px 2px 8px 0px $shadow50",
50
- position: "absolute",
51
- backgroundColor: "$neutral50",
52
- zIndex: "999999",
53
- variants: {
54
- position: {
55
- top: {
56
- bottom: "110%",
57
- left: "0",
58
- },
59
- bottom: {
60
- top: "110%",
61
- left: "0",
62
- },
63
- "top-right": {
64
- bottom: "110%",
65
- right: "0",
66
- },
67
- "bottom-right": {
68
- top: "110%",
69
- right: "0",
70
- },
71
- },
72
- },
73
- });
74
-
75
- export const CalendarFooterStyled = styled("div", {
76
- borderTop: "2px solid $neutral100",
77
- padding: "$4 $16",
78
- display: "flex",
79
- justifyContent: "center",
80
- alignItems: "center",
81
- height: "3rem",
82
- });
83
-
84
- export const DayPickerWrapperStyled = styled("div", {
85
- ".rt-TextFieldInput": {
86
- fontFamily: "$default",
87
- fontSize: "$14",
88
- color: "$dark500",
89
- },
90
- ".rdp-root": {
91
- padding: "$8",
92
- },
93
- ".rdp-today .rdp-day_button": {
94
- color: "$brand500",
95
- textDecoration: "underline",
96
- },
97
- ".rdp-day.rdp-disabled .rdp-day_button": {
98
- color: "$dark400",
99
- },
100
- ".rdp-day_button": {
101
- height: "32px",
102
- width: "32px",
103
- borderRadius: "$sm",
104
- fontSize: "$14",
105
- color: "$text",
106
- backgroundColor: "transparent",
107
- border: "1px solid transparent",
108
- transition: "all 0.2s ease-in-out",
109
- cursor: "pointer",
110
- },
111
- ".rdp-day_button:hover": {
112
- backgroundColor: "$dark100",
113
- borderColor: "$brand500",
114
- },
115
- ".rdp-day.rdp-disabled .rdp-day_button:hover": {
116
- backgroundColor: "transparent",
117
- borderColor: "transparent",
118
- },
119
- ".rdp-nav": {
120
- display: "flex",
121
- justifyContent: "space-between",
122
- width: "100%",
123
- },
124
- ".rdp-nav .rdp-chevron": {
125
- display: "none",
126
- },
127
- ".rdp-nav .rdp-button_previous": {
128
- display: "block",
129
- backgroundImage:
130
- "url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%3E%3Cg%20transform='scale(-1,1)%20translate(-32,0)'%3E%3Cpath%20d='M0%208C0%203.58172%203.58172%200%208%200H24C28.4183%200%2032%203.58172%2032%208V24C32%2028.4183%2028.4183%2032%2024%2032H8C3.58172%2032%200%2028.4183%200%2024V8Z'%20fill='white'/%3E%3Cpath%20d='M19.7062%2015.2938C20.0969%2015.6844%2020.0969%2016.3188%2019.7062%2016.7094L14.7062%2021.7094C14.3156%2022.1%2013.6812%2022.1%2013.2906%2021.7094C12.9%2021.3188%2012.9%2020.6844%2013.2906%2020.2938L17.5844%2016L13.2937%2011.7063C12.9031%2011.3156%2012.9031%2010.6813%2013.2937%2010.2906C13.6844%209.90002%2014.3187%209.90002%2014.7094%2010.2906L19.7094%2015.2906L19.7062%2015.2938Z'%20fill='%23808289'/%3E%3C/g%3E%3C/svg%3E\")",
131
- backgroundRepeat: "no-repeat",
132
- backgroundPosition: "center",
133
- backgroundSize: "cover",
134
- width: "32px",
135
- height: "32px",
136
- },
137
- ".rdp-nav .rdp-button_next": {
138
- display: "block",
139
- backgroundImage:
140
- "url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%3E%3Cpath%20d='M0%208C0%203.58172%203.58172%200%208%200H24C28.4183%200%2032%203.58172%2032%208V24C32%2028.4183%2028.4183%2032%2024%2032H8C3.58172%2032%200%2028.4183%200%2024V8Z'%20fill='white'/%3E%3Cpath%20d='M19.7062%2015.2938C20.0969%2015.6844%2020.0969%2016.3188%2019.7062%2016.7094L14.7062%2021.7094C14.3156%2022.1%2013.6812%2022.1%2013.2906%2021.7094C12.9%2021.3188%2012.9%2020.6844%2013.2906%2020.2938L17.5844%2016L13.2937%2011.7063C12.9031%2011.3156%2012.9031%2010.6813%2013.2937%2010.2906C13.6844%209.90002%2014.3187%209.90002%2014.7094%2010.2906L19.7094%2015.2906L19.7062%2015.2938Z'%20fill='%23808289'/%3E%3C/svg%3E\")",
141
- backgroundRepeat: "no-repeat",
142
- backgroundPosition: "center",
143
- backgroundSize: "cover",
144
- width: "32px",
145
- height: "32px",
146
- },
147
- ".rdp-nav .rdp-button_previous:hover": {
148
- backgroundImage:
149
- "url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%3E%3Cpath%20d='M0%208C0%203.58172%203.58172%200%208%200H24C28.4183%200%2032%203.58172%2032%208V24C32%2028.4183%2028.4183%2032%2024%2032H8C3.58172%2032%200%2028.4183%200%2024V8Z'%20fill='%23F4F4F4'/%3E%3Cpath%20d='M12.2937%2015.2938C11.9031%2015.6844%2011.9031%2016.3188%2012.2937%2016.7094L17.2937%2021.7094C17.6844%2022.1%2018.3187%2022.1%2018.7094%2021.7094C19.1%2021.3188%2019.1%2020.6844%2018.7094%2020.2938L14.4156%2016L18.7062%2011.7063C19.0969%2011.3156%2019.0969%2010.6813%2018.7062%2010.2906C18.3156%209.90002%2017.6812%209.90002%2017.2906%2010.2906L12.2906%2015.2906L12.2937%2015.2938Z'%20fill='%23808289'/%3E%3C/svg%3E\")",
150
- transition: "all 0.2s ease-in-out",
151
- },
152
- ".rdp-nav .rdp-button_next:hover": {
153
- backgroundImage:
154
- "url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%3E%3Cpath%20d='M0%208C0%203.58172%203.58172%200%208%200H24C28.4183%200%2032%203.58172%2032%208V24C32%2028.4183%2028.4183%2032%2024%2032H8C3.58172%2032%200%2028.4183%200%2024V8Z'%20fill='%23F4F4F4'/%3E%3Cpath%20d='M19.7062%2015.2938C20.0969%2015.6844%2020.0969%2016.3188%2019.7062%2016.7094L14.7062%2021.7094C14.3156%2022.1%2013.6812%2022.1%2013.2906%2021.7094C12.9%2021.3188%2012.9%2020.6844%2013.2906%2020.2938L17.5844%2016L13.2937%2011.7063C12.9031%2011.3156%2012.9031%2010.6813%2013.2937%2010.2906C13.6844%209.90002%2014.3187%209.90002%2014.7094%2010.2906L19.7094%2015.2906L19.7062%2015.2938Z'%20fill='%23808289'/%3E%3C/svg%3E\")",
155
- transition: "all 0.2s ease-in-out",
156
- },
157
- ".rdp-nav button": {
158
- border: "none",
159
- backgroundColor: "transparent",
160
- cursor: "pointer",
161
- },
162
- ".rdp-month": {
163
- marginTop: "-24px",
164
- },
165
- ".rdp-month_caption": {
166
- display: "flex",
167
- alignItems: "center",
168
- justifyContent: "center",
169
- width: "calc(100% - 64px)",
170
- margin: "0 auto",
171
- columnGap: "12px",
172
- },
173
- ".rdp-dropdowns span, .rdp-caption_label": {
174
- fontSize: "$16",
175
- fontWeight: "$regular",
176
- lineHeight: "$20",
177
- textTransform: "capitalize",
178
- },
179
- ".rdp-day.rdp-selected .rdp-day_button": {
180
- backgroundColor: "$brand500",
181
- color: "$neutral50",
182
- borderColor: "$brand500",
183
- },
184
- ".rdp-dropdowns": {
185
- display: "flex",
186
- alignItems: "center",
187
- justifyContent: "center",
188
- width: "calc(100% - 64px)",
189
- columnGap: "12px",
190
- },
191
- ".rdp-dropdowns .rdp-caption_label": {
192
- display: "none",
193
- },
194
- ".rdp-dropdown.rdp-months_dropdown, .rdp-dropdown.rdp-years_dropdown": {
195
- border: "none",
196
- backgroundColor: "transparent",
197
- textTransform: "capitalize",
198
- height: "1.25rem",
199
- position: "relative",
200
- fontFamily: "$default",
201
- fontSize: "$16",
202
- lineHeight: "1.25rem",
203
- appearance: "none",
204
- WebkitAppearance: "none",
205
- MozAppearance: "none",
206
- paddingRight: "1.25rem",
207
- zIndex: "3",
208
- },
209
- ".rdp-dropdown:focus, .rdp-dropdown:focus-visible, .rdp-dropdown:active": {
210
- border: "none",
211
- outline: "none",
212
- boxShadow: "none",
213
- },
214
- ".rdp-dropdown.rdp-months_dropdown:focus, .rdp-dropdown.rdp-years_dropdown:focus":
215
- {
216
- border: "none",
217
- },
218
- ".rdp-dropdown_root": {
219
- position: "relative",
220
- },
221
- ".rdp-dropdown_root::after": {
222
- content: "",
223
- height: "1.25rem",
224
- width: "1.25rem",
225
- position: "absolute",
226
- top: "0",
227
- right: "0",
228
- display: "block",
229
- backgroundColor: "$neutral50",
230
- backgroundImage:
231
- "url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='11'%20height='20'%20viewBox='0%200%2011%2020'%20fill='none'%3E%3Crect%20width='11'%20height='20'%20fill='white'/%3E%3Cpath%20d='M5.9414%202.68359C5.69726%202.43945%205.30077%202.43945%205.05663%202.68359L2.55663%205.18359C2.37695%205.36328%202.32421%205.63086%202.42187%205.86523C2.51952%206.09961%202.74609%206.25195%202.99999%206.25195H7.99999C8.25195%206.25195%208.48046%206.09961%208.57812%205.86523C8.67578%205.63086%208.62109%205.36328%208.44335%205.18359L5.94335%202.68359H5.9414Z'%20fill='%23808289'/%3E%3Cpath%20d='M5.05858%2017.3164C5.30272%2017.5605%205.69921%2017.5605%205.94335%2017.3164L8.44335%2014.8164C8.62304%2014.6367%208.67577%2014.3691%208.57811%2014.1348C8.48046%2013.9004%208.25389%2013.748%207.99999%2013.748L2.99999%2013.75C2.74804%2013.75%202.51952%2013.9023%202.42186%2014.1367C2.32421%2014.3711%202.37889%2014.6387%202.55663%2014.8184L5.05663%2017.3184L5.05858%2017.3164Z'%20fill='%23808289'/%3E%3C/svg%3E\")",
232
- backgroundRepeat: "no-repeat",
233
- backgroundPosition: "center",
234
- borderRadius: "0.5rem",
235
- zIndex: "2",
236
- },
237
- ".rdp-weekday": {
238
- textTransform: "uppercase",
239
- fontWeight: "$regular",
240
- fontSize: "0px",
241
- },
242
- ".rdp-weekday::first-letter": {
243
- fontSize: "$14",
244
- },
245
- ".rdp-month_grid": {
246
- marginTop: "$16",
247
- paddingTop: "$16",
248
- borderTop: "2px solid $neutral100",
249
- },
250
- });
1
+ import { styled } from "../../styles";
2
+
3
+ export const CalendarStyled = styled("div", {
4
+ fontFamily: "$default",
5
+ lineHeight: "$base",
6
+ fontSize: "$14",
7
+ borderRadius: "$sm",
8
+ position: "relative",
9
+ width: "fit-content",
10
+ variants: {
11
+ expand: {
12
+ true: {
13
+ width: "100%",
14
+ flex: "1",
15
+ display: "flex",
16
+ },
17
+ },
18
+ },
19
+ });
20
+ export const CalendarButtonStyled = styled("button", {
21
+ backgroundColor: "transparent",
22
+ border: "none",
23
+ maxWidth: "200px",
24
+ padding: "0",
25
+ cursor: "pointer",
26
+ "> div > div": {
27
+ paddingLeft: "0",
28
+ input: {
29
+ textAlign: "right",
30
+ },
31
+ },
32
+ variants: {
33
+ expand: {
34
+ true: {
35
+ flex: "1",
36
+ display: "flex",
37
+ maxWidth: "100%",
38
+ },
39
+ },
40
+ },
41
+ });
42
+ export const CalendarContentStyled = styled("div", {
43
+ fontFamily: "$default",
44
+ lineHeight: "$base",
45
+ fontSize: "$14",
46
+ maxWidth: "fit-content",
47
+ border: "1px solid $neutral300",
48
+ borderRadius: "$sm",
49
+ boxShadow: "0px 2px 8px 0px $shadow50",
50
+ position: "absolute",
51
+ backgroundColor: "$neutral50",
52
+ zIndex: "999999",
53
+ variants: {
54
+ position: {
55
+ top: {
56
+ bottom: "110%",
57
+ left: "0",
58
+ },
59
+ bottom: {
60
+ top: "110%",
61
+ left: "0",
62
+ },
63
+ "top-right": {
64
+ bottom: "110%",
65
+ right: "0",
66
+ },
67
+ "bottom-right": {
68
+ top: "110%",
69
+ right: "0",
70
+ },
71
+ },
72
+ },
73
+ });
74
+
75
+ export const CalendarFooterStyled = styled("div", {
76
+ borderTop: "2px solid $neutral100",
77
+ padding: "$4 $16",
78
+ display: "flex",
79
+ justifyContent: "center",
80
+ alignItems: "center",
81
+ height: "3rem",
82
+ });
83
+
84
+ export const DayPickerWrapperStyled = styled("div", {
85
+ ".rt-TextFieldInput": {
86
+ fontFamily: "$default",
87
+ fontSize: "$14",
88
+ color: "$dark500",
89
+ },
90
+ ".rdp-root": {
91
+ padding: "$8",
92
+ },
93
+ ".rdp-today .rdp-day_button": {
94
+ color: "$brand500",
95
+ textDecoration: "underline",
96
+ },
97
+ ".rdp-day.rdp-disabled .rdp-day_button": {
98
+ color: "$dark400",
99
+ },
100
+ ".rdp-day_button": {
101
+ height: "32px",
102
+ width: "32px",
103
+ borderRadius: "$sm",
104
+ fontSize: "$14",
105
+ color: "$text",
106
+ backgroundColor: "transparent",
107
+ border: "1px solid transparent",
108
+ transition: "all 0.2s ease-in-out",
109
+ cursor: "pointer",
110
+ },
111
+ ".rdp-day_button:hover": {
112
+ backgroundColor: "$dark100",
113
+ borderColor: "$brand500",
114
+ },
115
+ ".rdp-day.rdp-disabled .rdp-day_button:hover": {
116
+ backgroundColor: "transparent",
117
+ borderColor: "transparent",
118
+ },
119
+ ".rdp-nav": {
120
+ display: "flex",
121
+ justifyContent: "space-between",
122
+ width: "100%",
123
+ },
124
+ ".rdp-nav .rdp-chevron": {
125
+ display: "none",
126
+ },
127
+ ".rdp-nav .rdp-button_previous": {
128
+ display: "block",
129
+ backgroundImage:
130
+ "url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%3E%3Cg%20transform='scale(-1,1)%20translate(-32,0)'%3E%3Cpath%20d='M0%208C0%203.58172%203.58172%200%208%200H24C28.4183%200%2032%203.58172%2032%208V24C32%2028.4183%2028.4183%2032%2024%2032H8C3.58172%2032%200%2028.4183%200%2024V8Z'%20fill='white'/%3E%3Cpath%20d='M19.7062%2015.2938C20.0969%2015.6844%2020.0969%2016.3188%2019.7062%2016.7094L14.7062%2021.7094C14.3156%2022.1%2013.6812%2022.1%2013.2906%2021.7094C12.9%2021.3188%2012.9%2020.6844%2013.2906%2020.2938L17.5844%2016L13.2937%2011.7063C12.9031%2011.3156%2012.9031%2010.6813%2013.2937%2010.2906C13.6844%209.90002%2014.3187%209.90002%2014.7094%2010.2906L19.7094%2015.2906L19.7062%2015.2938Z'%20fill='%23808289'/%3E%3C/g%3E%3C/svg%3E\")",
131
+ backgroundRepeat: "no-repeat",
132
+ backgroundPosition: "center",
133
+ backgroundSize: "cover",
134
+ width: "32px",
135
+ height: "32px",
136
+ },
137
+ ".rdp-nav .rdp-button_next": {
138
+ display: "block",
139
+ backgroundImage:
140
+ "url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%3E%3Cpath%20d='M0%208C0%203.58172%203.58172%200%208%200H24C28.4183%200%2032%203.58172%2032%208V24C32%2028.4183%2028.4183%2032%2024%2032H8C3.58172%2032%200%2028.4183%200%2024V8Z'%20fill='white'/%3E%3Cpath%20d='M19.7062%2015.2938C20.0969%2015.6844%2020.0969%2016.3188%2019.7062%2016.7094L14.7062%2021.7094C14.3156%2022.1%2013.6812%2022.1%2013.2906%2021.7094C12.9%2021.3188%2012.9%2020.6844%2013.2906%2020.2938L17.5844%2016L13.2937%2011.7063C12.9031%2011.3156%2012.9031%2010.6813%2013.2937%2010.2906C13.6844%209.90002%2014.3187%209.90002%2014.7094%2010.2906L19.7094%2015.2906L19.7062%2015.2938Z'%20fill='%23808289'/%3E%3C/svg%3E\")",
141
+ backgroundRepeat: "no-repeat",
142
+ backgroundPosition: "center",
143
+ backgroundSize: "cover",
144
+ width: "32px",
145
+ height: "32px",
146
+ },
147
+ ".rdp-nav .rdp-button_previous:hover": {
148
+ backgroundImage:
149
+ "url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%3E%3Cpath%20d='M0%208C0%203.58172%203.58172%200%208%200H24C28.4183%200%2032%203.58172%2032%208V24C32%2028.4183%2028.4183%2032%2024%2032H8C3.58172%2032%200%2028.4183%200%2024V8Z'%20fill='%23F4F4F4'/%3E%3Cpath%20d='M12.2937%2015.2938C11.9031%2015.6844%2011.9031%2016.3188%2012.2937%2016.7094L17.2937%2021.7094C17.6844%2022.1%2018.3187%2022.1%2018.7094%2021.7094C19.1%2021.3188%2019.1%2020.6844%2018.7094%2020.2938L14.4156%2016L18.7062%2011.7063C19.0969%2011.3156%2019.0969%2010.6813%2018.7062%2010.2906C18.3156%209.90002%2017.6812%209.90002%2017.2906%2010.2906L12.2906%2015.2906L12.2937%2015.2938Z'%20fill='%23808289'/%3E%3C/svg%3E\")",
150
+ transition: "all 0.2s ease-in-out",
151
+ },
152
+ ".rdp-nav .rdp-button_next:hover": {
153
+ backgroundImage:
154
+ "url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%3E%3Cpath%20d='M0%208C0%203.58172%203.58172%200%208%200H24C28.4183%200%2032%203.58172%2032%208V24C32%2028.4183%2028.4183%2032%2024%2032H8C3.58172%2032%200%2028.4183%200%2024V8Z'%20fill='%23F4F4F4'/%3E%3Cpath%20d='M19.7062%2015.2938C20.0969%2015.6844%2020.0969%2016.3188%2019.7062%2016.7094L14.7062%2021.7094C14.3156%2022.1%2013.6812%2022.1%2013.2906%2021.7094C12.9%2021.3188%2012.9%2020.6844%2013.2906%2020.2938L17.5844%2016L13.2937%2011.7063C12.9031%2011.3156%2012.9031%2010.6813%2013.2937%2010.2906C13.6844%209.90002%2014.3187%209.90002%2014.7094%2010.2906L19.7094%2015.2906L19.7062%2015.2938Z'%20fill='%23808289'/%3E%3C/svg%3E\")",
155
+ transition: "all 0.2s ease-in-out",
156
+ },
157
+ ".rdp-nav button": {
158
+ border: "none",
159
+ backgroundColor: "transparent",
160
+ cursor: "pointer",
161
+ },
162
+ ".rdp-month": {
163
+ marginTop: "-24px",
164
+ },
165
+ ".rdp-month_caption": {
166
+ display: "flex",
167
+ alignItems: "center",
168
+ justifyContent: "center",
169
+ width: "calc(100% - 64px)",
170
+ margin: "0 auto",
171
+ columnGap: "12px",
172
+ },
173
+ ".rdp-dropdowns span, .rdp-caption_label": {
174
+ fontSize: "$16",
175
+ fontWeight: "$regular",
176
+ lineHeight: "$20",
177
+ textTransform: "capitalize",
178
+ },
179
+ ".rdp-day.rdp-selected .rdp-day_button": {
180
+ backgroundColor: "$brand500",
181
+ color: "$neutral50",
182
+ borderColor: "$brand500",
183
+ },
184
+ ".rdp-dropdowns": {
185
+ display: "flex",
186
+ alignItems: "center",
187
+ justifyContent: "center",
188
+ width: "calc(100% - 64px)",
189
+ columnGap: "12px",
190
+ },
191
+ ".rdp-dropdowns .rdp-caption_label": {
192
+ display: "none",
193
+ },
194
+ ".rdp-dropdown.rdp-months_dropdown, .rdp-dropdown.rdp-years_dropdown": {
195
+ border: "none",
196
+ backgroundColor: "transparent",
197
+ textTransform: "capitalize",
198
+ height: "1.25rem",
199
+ position: "relative",
200
+ fontFamily: "$default",
201
+ fontSize: "$16",
202
+ lineHeight: "1.25rem",
203
+ appearance: "none",
204
+ WebkitAppearance: "none",
205
+ MozAppearance: "none",
206
+ paddingRight: "1.25rem",
207
+ zIndex: "3",
208
+ },
209
+ ".rdp-dropdown:focus, .rdp-dropdown:focus-visible, .rdp-dropdown:active": {
210
+ border: "none",
211
+ outline: "none",
212
+ boxShadow: "none",
213
+ },
214
+ ".rdp-dropdown.rdp-months_dropdown:focus, .rdp-dropdown.rdp-years_dropdown:focus":
215
+ {
216
+ border: "none",
217
+ },
218
+ ".rdp-dropdown_root": {
219
+ position: "relative",
220
+ },
221
+ ".rdp-dropdown_root::after": {
222
+ content: "",
223
+ height: "1.25rem",
224
+ width: "1.25rem",
225
+ position: "absolute",
226
+ top: "0",
227
+ right: "0",
228
+ display: "block",
229
+ backgroundColor: "$neutral50",
230
+ backgroundImage:
231
+ "url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='11'%20height='20'%20viewBox='0%200%2011%2020'%20fill='none'%3E%3Crect%20width='11'%20height='20'%20fill='white'/%3E%3Cpath%20d='M5.9414%202.68359C5.69726%202.43945%205.30077%202.43945%205.05663%202.68359L2.55663%205.18359C2.37695%205.36328%202.32421%205.63086%202.42187%205.86523C2.51952%206.09961%202.74609%206.25195%202.99999%206.25195H7.99999C8.25195%206.25195%208.48046%206.09961%208.57812%205.86523C8.67578%205.63086%208.62109%205.36328%208.44335%205.18359L5.94335%202.68359H5.9414Z'%20fill='%23808289'/%3E%3Cpath%20d='M5.05858%2017.3164C5.30272%2017.5605%205.69921%2017.5605%205.94335%2017.3164L8.44335%2014.8164C8.62304%2014.6367%208.67577%2014.3691%208.57811%2014.1348C8.48046%2013.9004%208.25389%2013.748%207.99999%2013.748L2.99999%2013.75C2.74804%2013.75%202.51952%2013.9023%202.42186%2014.1367C2.32421%2014.3711%202.37889%2014.6387%202.55663%2014.8184L5.05663%2017.3184L5.05858%2017.3164Z'%20fill='%23808289'/%3E%3C/svg%3E\")",
232
+ backgroundRepeat: "no-repeat",
233
+ backgroundPosition: "center",
234
+ borderRadius: "0.5rem",
235
+ zIndex: "2",
236
+ },
237
+ ".rdp-weekday": {
238
+ textTransform: "uppercase",
239
+ fontWeight: "$regular",
240
+ fontSize: "0px",
241
+ },
242
+ ".rdp-weekday::first-letter": {
243
+ fontSize: "$14",
244
+ },
245
+ ".rdp-month_grid": {
246
+ marginTop: "$16",
247
+ paddingTop: "$16",
248
+ borderTop: "2px solid $neutral100",
249
+ },
250
+ });
@@ -1,48 +1,48 @@
1
- import React from "react";
2
- import { ComponentProps, ElementType } from "react";
3
- import { styled } from "../styles";
4
- import { Box, Card as CardRadix } from "@radix-ui/themes";
5
-
6
- export const CardStyled = styled(CardRadix, {
7
- borderRadius: "$2xl",
8
- border: "1px solid $dark100",
9
- padding: "16px",
10
- defaultVariants: {
11
- color: "primary",
12
- boxShadow: false,
13
- },
14
- variants: {
15
- color: {
16
- primary: {
17
- backgroundColor: "$dark50",
18
- border: "1px solid $dark200",
19
- },
20
- disable: {
21
- backgroundColor: "$grey50",
22
- border: "1px solid $dark200",
23
- },
24
- error: {
25
- backgroundColor: "$error50",
26
- border: "1px solid $error600",
27
- },
28
- },
29
- boxShadow: {
30
- true: {
31
- boxShadow:
32
- "0 2px 4px rgba(35, 53, 67, 0.16), 0 4px 4px rgba(35, 53, 67, 0.08)",
33
- },
34
- false: {
35
- boxShadow: "none",
36
- },
37
- },
38
- },
39
- });
40
-
41
- export type CardProps = ComponentProps<typeof CardStyled> & {
42
- children: React.ReactNode;
43
- as?: ElementType;
44
- };
45
-
46
- export function Card({ asChild, children, ...props }: CardProps) {
47
- return <CardStyled {...props}>{children}</CardStyled>;
48
- }
1
+ import React from "react";
2
+ import { ComponentProps, ElementType } from "react";
3
+ import { styled } from "../styles";
4
+ import { Box, Card as CardRadix } from "@radix-ui/themes";
5
+
6
+ export const CardStyled = styled(CardRadix, {
7
+ borderRadius: "$2xl",
8
+ border: "1px solid $dark100",
9
+ padding: "16px",
10
+ defaultVariants: {
11
+ color: "primary",
12
+ boxShadow: false,
13
+ },
14
+ variants: {
15
+ color: {
16
+ primary: {
17
+ backgroundColor: "$dark50",
18
+ border: "1px solid $dark200",
19
+ },
20
+ disable: {
21
+ backgroundColor: "$grey50",
22
+ border: "1px solid $dark200",
23
+ },
24
+ error: {
25
+ backgroundColor: "$error50",
26
+ border: "1px solid $error600",
27
+ },
28
+ },
29
+ boxShadow: {
30
+ true: {
31
+ boxShadow:
32
+ "0 2px 4px rgba(35, 53, 67, 0.16), 0 4px 4px rgba(35, 53, 67, 0.08)",
33
+ },
34
+ false: {
35
+ boxShadow: "none",
36
+ },
37
+ },
38
+ },
39
+ });
40
+
41
+ export type CardProps = ComponentProps<typeof CardStyled> & {
42
+ children: React.ReactNode;
43
+ as?: ElementType;
44
+ };
45
+
46
+ export function Card({ asChild, children, ...props }: CardProps) {
47
+ return <CardStyled {...props}>{children}</CardStyled>;
48
+ }