@lets-events/react 12.2.10 → 12.2.12

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 +12 -0
  4. package/dist/index.css +171 -0
  5. package/dist/index.d.mts +377 -3
  6. package/dist/index.d.ts +377 -3
  7. package/dist/index.js +73 -27
  8. package/dist/index.mjs +72 -27
  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 +107 -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
package/dist/index.mjs CHANGED
@@ -3620,16 +3620,44 @@ var ModalTitleStyled = styled(ModalRadix.Title, {
3620
3620
  textTransform: "uppercase"
3621
3621
  });
3622
3622
  function Modal(_a) {
3623
- var _b = _a, { children, title, trigger } = _b, props = __objRest(_b, ["children", "title", "trigger"]);
3623
+ var _b = _a, {
3624
+ children,
3625
+ title,
3626
+ trigger,
3627
+ zIndex,
3628
+ maxWidth
3629
+ } = _b, props = __objRest(_b, [
3630
+ "children",
3631
+ "title",
3632
+ "trigger",
3633
+ "zIndex",
3634
+ "maxWidth"
3635
+ ]);
3624
3636
  return /* @__PURE__ */ jsxs4(ModalRadix.Root, __spreadProps(__spreadValues({}, props), { children: [
3625
3637
  trigger && /* @__PURE__ */ jsx13(ModalRadix.Trigger, { asChild: true, children: trigger }),
3626
- /* @__PURE__ */ jsx13(ModalRadix.Portal, { children: /* @__PURE__ */ jsx13(ModalOverlay, { children: /* @__PURE__ */ jsxs4(ModalContentStyled, { children: [
3627
- title && /* @__PURE__ */ jsxs4(ModalHeaderStyled, { children: [
3628
- /* @__PURE__ */ jsx13(ModalTitleStyled, { asChild: true, children: /* @__PURE__ */ jsx13(Text, { typography: "headline6", fontWeight: "medium", children: title }) }),
3629
- /* @__PURE__ */ jsx13(ModalRadix.Close, { asChild: true, children: /* @__PURE__ */ jsx13(ModalIconClose, { name: "close", size: "xl" }) })
3630
- ] }),
3631
- /* @__PURE__ */ jsx13(Box, { children })
3632
- ] }) }) })
3638
+ /* @__PURE__ */ jsx13(ModalRadix.Portal, { children: /* @__PURE__ */ jsx13(
3639
+ ModalOverlay,
3640
+ {
3641
+ css: {
3642
+ zIndex
3643
+ },
3644
+ children: /* @__PURE__ */ jsxs4(
3645
+ ModalContentStyled,
3646
+ {
3647
+ css: {
3648
+ maxWidth
3649
+ },
3650
+ children: [
3651
+ title && /* @__PURE__ */ jsxs4(ModalHeaderStyled, { children: [
3652
+ /* @__PURE__ */ jsx13(ModalTitleStyled, { asChild: true, children: /* @__PURE__ */ jsx13(Text, { typography: "headline6", fontWeight: "medium", children: title }) }),
3653
+ /* @__PURE__ */ jsx13(ModalRadix.Close, { asChild: true, children: /* @__PURE__ */ jsx13(ModalIconClose, { name: "close", size: "xl" }) })
3654
+ ] }),
3655
+ /* @__PURE__ */ jsx13(Box, { children })
3656
+ ]
3657
+ }
3658
+ )
3659
+ }
3660
+ ) })
3633
3661
  ] }));
3634
3662
  }
3635
3663
 
@@ -8031,7 +8059,8 @@ function Drawer({
8031
8059
  title,
8032
8060
  children,
8033
8061
  goBackIcon,
8034
- goBackAction
8062
+ goBackAction,
8063
+ zIndex
8035
8064
  }) {
8036
8065
  if (!isOpen) return null;
8037
8066
  const drawerContainerRef = useRef4(null);
@@ -8072,29 +8101,37 @@ function Drawer({
8072
8101
  const isDropdownOpen = target.closest("[data-radix-popper-content-wrapper]") || target.closest('[role="dialog"]') || target.closest('[data-state="open"]') || target.closest("[data-radix-dropdown-menu-content]") || target.closest("[data-radix-dropdown-menu-root]") || target.closest("[data-radix-dropdown-menu-trigger]") || target.closest("[data-radix-dropdown-menu-portal]") || target.closest("[data-radix-dropdown-menu-item]") || target.closest("[data-radix-dropdown-menu-checkbox-item]") || target.closest("[data-radix-dropdown-menu-radio-item]") || target.closest("[data-radix-dropdown-menu-separator]") || target.closest("[data-radix-dropdown-menu-label]") || target.closest("[data-radix-dropdown-menu-group]") || target.closest("[data-radix-dropdown-menu-sub]") || target.closest("[data-radix-dropdown-menu-sub-trigger]") || target.closest("[data-radix-dropdown-menu-sub-content]") || target.closest("[data-radix-dropdown-menu-radio-group]");
8073
8102
  const shouldPreventClose = isDropdownOpen || target.closest("[data-radix-dropdown-menu-root]") || target.closest("[data-radix-dropdown-menu-trigger]") || target.closest("[data-radix-dropdown-menu-content]") || target.closest("[data-radix-dropdown-menu-portal]") || target.closest("[data-radix-dropdown-menu-item]") || target.closest("[data-radix-dropdown-menu-checkbox-item]") || target.closest("[data-radix-dropdown-menu-radio-item]") || target.closest("[data-radix-dropdown-menu-separator]") || target.closest("[data-radix-dropdown-menu-label]") || target.closest("[data-radix-dropdown-menu-group]") || target.closest("[data-radix-dropdown-menu-sub]") || target.closest("[data-radix-dropdown-menu-sub-trigger]") || target.closest("[data-radix-dropdown-menu-sub-content]") || target.closest("[data-radix-dropdown-menu-radio-group]");
8074
8103
  if (!shouldPreventClose) {
8075
- onClose();
8104
+ onClose == null ? void 0 : onClose();
8076
8105
  }
8077
8106
  });
8078
- return /* @__PURE__ */ jsx16(DrawerOverlayStyled, { children: /* @__PURE__ */ jsxs7(
8079
- DrawerContainerStyled,
8107
+ return /* @__PURE__ */ jsx16(
8108
+ DrawerOverlayStyled,
8080
8109
  {
8081
- ref: drawerContainerRef,
8082
- style: {
8083
- width: width != null ? width : "34.25rem",
8084
- backgroundColor: colors[backgroundColor != null ? backgroundColor : "neutral50"]
8110
+ css: {
8111
+ zIndex
8085
8112
  },
8086
- children: [
8087
- /* @__PURE__ */ jsxs7(DrawerHeaderDiv, { children: [
8088
- /* @__PURE__ */ jsxs7(Flex2, { gap: 8, align: "center", children: [
8089
- goBackIcon && goBackIcon && /* @__PURE__ */ jsx16(GoBackButtonStyled, { type: "button", onClick: goBackAction, children: goBackIcon }),
8090
- /* @__PURE__ */ jsx16(DrawerHeaderTitle, { children: title })
8091
- ] }),
8092
- /* @__PURE__ */ jsx16(DrawerHeaderCloseButton, { onClick: onClose, children: /* @__PURE__ */ jsx16(Icon_default, { size: "xl", color: "$dark600", name: "xmark" }) })
8093
- ] }),
8094
- children
8095
- ]
8113
+ children: /* @__PURE__ */ jsxs7(
8114
+ DrawerContainerStyled,
8115
+ {
8116
+ ref: drawerContainerRef,
8117
+ style: {
8118
+ width: width != null ? width : "34.25rem",
8119
+ backgroundColor: colors[backgroundColor != null ? backgroundColor : "neutral50"]
8120
+ },
8121
+ children: [
8122
+ /* @__PURE__ */ jsxs7(DrawerHeaderDiv, { children: [
8123
+ /* @__PURE__ */ jsxs7(Flex2, { gap: 8, align: "center", children: [
8124
+ goBackIcon && goBackIcon && /* @__PURE__ */ jsx16(GoBackButtonStyled, { type: "button", onClick: goBackAction, children: goBackIcon }),
8125
+ /* @__PURE__ */ jsx16(DrawerHeaderTitle, { children: title })
8126
+ ] }),
8127
+ /* @__PURE__ */ jsx16(DrawerHeaderCloseButton, { onClick: onClose, children: /* @__PURE__ */ jsx16(Icon_default, { size: "xl", color: "$dark600", name: "xmark" }) })
8128
+ ] }),
8129
+ children
8130
+ ]
8131
+ }
8132
+ )
8096
8133
  }
8097
- ) });
8134
+ );
8098
8135
  }
8099
8136
 
8100
8137
  // src/components/TimePicker.tsx
@@ -9673,6 +9710,13 @@ var MultiSelect = React9.forwardRef(
9673
9710
  }
9674
9711
  );
9675
9712
 
9713
+ // src/components/Divider.tsx
9714
+ var Divider = styled("div", {
9715
+ backgroundColor: "$dark300",
9716
+ width: "100%",
9717
+ height: "1px"
9718
+ });
9719
+
9676
9720
  // src/components/Grid.tsx
9677
9721
  import { Grid as GridRadix } from "@radix-ui/themes";
9678
9722
  import { jsx as jsx27 } from "react/jsx-runtime";
@@ -12850,6 +12894,7 @@ export {
12850
12894
  Container,
12851
12895
  ContainerStyled,
12852
12896
  CountryFormField,
12897
+ Divider,
12853
12898
  Drawer,
12854
12899
  DropdownMenu2 as DropdownMenu,
12855
12900
  DropdownMenuItem,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lets-events/react",
3
- "version": "12.2.10",
3
+ "version": "12.2.12",
4
4
  "description": "",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",