@123usmanhaider321/ui 0.1.6 → 1.0.0
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.
- package/README.md +416 -31
- package/dist/images/icon/1LINK.svg +50 -0
- package/dist/images/icon/CreditCard.svg +83 -0
- package/dist/images/icon/Easypaisa.png +0 -0
- package/dist/images/icon/MobileWallet.png +0 -0
- package/dist/images/icon/Raast-Logo.png +0 -0
- package/dist/images/icon/VISA.png +0 -0
- package/dist/images/icon/add-circle-1.svg +5 -0
- package/dist/images/icon/check-circle-broken.svg +3 -0
- package/dist/images/icon/close-circle.svg +5 -0
- package/dist/images/icon/jazzcash.png +0 -0
- package/dist/images/icon/loading_icon.json +3347 -0
- package/dist/images/icon/mastercard-logo.webp +0 -0
- package/dist/images/icon/paymo.jpeg +0 -0
- package/dist/images/icon/preview-svgrepo-com.svg +36 -0
- package/dist/images/icon/trash.svg +7 -0
- package/dist/images/icon/unionpay-logo.svg +9 -0
- package/dist/index-87FQZHOs.js +11119 -0
- package/dist/index-87FQZHOs.js.map +1 -0
- package/dist/index-Tl9g213f.js +60475 -0
- package/dist/index-Tl9g213f.js.map +1 -0
- package/dist/index.d.ts +1 -10
- package/dist/index.es-CpgTaa1Y.js +16734 -0
- package/dist/index.es-CpgTaa1Y.js.map +1 -0
- package/dist/index.js +40 -12
- package/dist/index.js.map +1 -1
- package/dist/loading_icon-n5H5dQBl.js +3375 -0
- package/dist/loading_icon-n5H5dQBl.js.map +1 -0
- package/dist/src/components/Alert/ErrorAlert.d.ts +6 -0
- package/dist/src/components/Alert/SuccessAlert.d.ts +6 -0
- package/dist/{components → src/components}/FormBuilder/DiscountInput.d.ts +3 -6
- package/dist/{components → src/components}/FormBuilder/FormBuilder.d.ts +2 -11
- package/dist/{components → src/components}/FormBuilder/QuestionCard.d.ts +0 -5
- package/dist/{components → src/components}/FormBuilder/QuestionEditor.d.ts +0 -5
- package/dist/{components → src/components}/FormBuilder/SortableQuestionList.d.ts +0 -5
- package/dist/src/components/FormBuilder/questionIcons.d.ts +5 -0
- package/dist/{components/EventAddForm → src/components/NewAddEvent}/AddEventLayout.d.ts +2 -1
- package/dist/{components/EventAddForm → src/components/NewAddEvent}/AddEventStepper.d.ts +2 -2
- package/dist/{components/EventAddForm → src/components/NewAddEvent}/common/ConfirmationModal.d.ts +1 -1
- package/dist/src/components/NewAddEvent/components/EventSubmissionConfirmationModal.d.ts +14 -0
- package/dist/{components/EventAddForm → src/components/NewAddEvent}/components/StepTwo/TicketTierSection.d.ts +1 -1
- package/dist/{components/EventAddForm → src/components/NewAddEvent}/components/TicketTierForm.d.ts +1 -1
- package/dist/{components/EventAddForm → src/components/NewAddEvent}/hooks/useStepperForm.d.ts +22 -22
- package/dist/{components/EventAddForm → src/components/NewAddEvent}/hooks/useTicketTierForm.d.ts +63 -15
- package/dist/src/components/NewAddEvent/schemas/step1.d.ts +211 -0
- package/dist/src/components/NewAddEvent/schemas/step2.d.ts +411 -0
- package/dist/{components/EventAddForm → src/components/NewAddEvent}/schemas/utils.d.ts +8 -2
- package/dist/{components/EventAddForm → src/components/NewAddEvent}/steps/IndividualFormStep.d.ts +1 -1
- package/dist/{components/EventAddForm → src/components/NewAddEvent}/steps/SocialProfilesStep.d.ts +1 -1
- package/dist/{components/EventAddForm → src/components/NewAddEvent}/steps/TeamFormStep.d.ts +1 -1
- package/dist/src/components/Spinner/spinner.d.ts +4 -0
- package/dist/src/components/TicketlyUIProvider.d.ts +35 -0
- package/dist/src/components/common/Loader/index.d.ts +8 -0
- package/dist/src/components/common/Modals/ConfirmationModal.d.ts +7 -0
- package/dist/{components/FormInput → src/components/ui}/FormInput.d.ts +1 -1
- package/dist/src/components/ui/Loader.d.ts +4 -0
- package/dist/{components/Button/Button.d.ts → src/components/ui/button.d.ts} +1 -1
- package/dist/src/index.d.ts +10 -0
- package/dist/{lib → src/lib}/actions.d.ts +0 -126
- package/dist/src/lib/dom-utils.d.ts +2 -0
- package/dist/src/lib/storage-utils.d.ts +5 -0
- package/dist/src/lib/types.d.ts +258 -0
- package/dist/src/redux/baseQuery.d.ts +16 -0
- package/dist/{services → src/redux/features}/eventApi.d.ts +1053 -1745
- package/dist/src/redux/features/globalSlice.d.ts +17 -0
- package/dist/{services → src/redux/features/single-event}/single-event-api.d.ts +856 -1190
- package/dist/src/redux/types.d.ts +2 -0
- package/dist/src/services/library-services.d.ts +15 -0
- package/dist/src/services/remote-config.d.ts +27 -0
- package/dist/{services → src/services}/utils.d.ts +1 -1
- package/dist/src/theme/colors.d.ts +127 -0
- package/dist/src/theme/typography.d.ts +13 -0
- package/dist/src/types/api.d.ts +18 -0
- package/dist/style.css +2984 -0
- package/dist/styles.css +3758 -3636
- package/package.json +78 -68
- package/dist/_virtual/_commonjsHelpers.js +0 -9
- package/dist/_virtual/_commonjsHelpers.js.map +0 -1
- package/dist/_virtual/customParseFormat.js +0 -5
- package/dist/_virtual/customParseFormat.js.map +0 -1
- package/dist/_virtual/dayjs.min.js +0 -5
- package/dist/_virtual/dayjs.min.js.map +0 -1
- package/dist/_virtual/duration.js +0 -5
- package/dist/_virtual/duration.js.map +0 -1
- package/dist/_virtual/index.js +0 -5
- package/dist/_virtual/index.js.map +0 -1
- package/dist/_virtual/isBetween.js +0 -5
- package/dist/_virtual/isBetween.js.map +0 -1
- package/dist/_virtual/relativeTime.js +0 -5
- package/dist/_virtual/relativeTime.js.map +0 -1
- package/dist/_virtual/use-sync-external-store-shim.development.js +0 -5
- package/dist/_virtual/use-sync-external-store-shim.development.js.map +0 -1
- package/dist/_virtual/use-sync-external-store-shim.production.js +0 -5
- package/dist/_virtual/use-sync-external-store-shim.production.js.map +0 -1
- package/dist/_virtual/with-selector.development.js +0 -5
- package/dist/_virtual/with-selector.development.js.map +0 -1
- package/dist/_virtual/with-selector.js +0 -5
- package/dist/_virtual/with-selector.js.map +0 -1
- package/dist/_virtual/with-selector.production.js +0 -5
- package/dist/_virtual/with-selector.production.js.map +0 -1
- package/dist/components/Alert/Alert.js +0 -51
- package/dist/components/Alert/Alert.js.map +0 -1
- package/dist/components/Button/Button.js +0 -52
- package/dist/components/Button/Button.js.map +0 -1
- package/dist/components/Button/Button.test.d.ts +0 -1
- package/dist/components/Button/index.d.ts +0 -1
- package/dist/components/Checkbox/Checkbox.js +0 -50
- package/dist/components/Checkbox/Checkbox.js.map +0 -1
- package/dist/components/Checkbox/Checkbox.test.d.ts +0 -1
- package/dist/components/Checkbox/index.d.ts +0 -1
- package/dist/components/CheckboxGroup/CheckboxGroup.d.ts +0 -25
- package/dist/components/CheckboxGroup/CheckboxGroup.js +0 -99
- package/dist/components/CheckboxGroup/CheckboxGroup.js.map +0 -1
- package/dist/components/ConfirmationModal/ConfirmationModal.d.ts +0 -15
- package/dist/components/ConfirmationModal/ConfirmationModal.js +0 -136
- package/dist/components/ConfirmationModal/ConfirmationModal.js.map +0 -1
- package/dist/components/ConfirmationModal/index.d.ts +0 -2
- package/dist/components/CustomSelect/CustomSelect.js +0 -259
- package/dist/components/CustomSelect/CustomSelect.js.map +0 -1
- package/dist/components/EventAddForm/AddEventLayout.js +0 -227
- package/dist/components/EventAddForm/AddEventLayout.js.map +0 -1
- package/dist/components/EventAddForm/AddEventStepper.js +0 -719
- package/dist/components/EventAddForm/AddEventStepper.js.map +0 -1
- package/dist/components/EventAddForm/common/ConfirmationModal.js +0 -136
- package/dist/components/EventAddForm/common/ConfirmationModal.js.map +0 -1
- package/dist/components/EventAddForm/common/DescriptionModal.js +0 -70
- package/dist/components/EventAddForm/common/DescriptionModal.js.map +0 -1
- package/dist/components/EventAddForm/components/AnimatedBackground.d.ts +0 -8
- package/dist/components/EventAddForm/components/ApprovalConfirmationModal.d.ts +0 -7
- package/dist/components/EventAddForm/components/CheckboxGroup.js +0 -92
- package/dist/components/EventAddForm/components/CheckboxGroup.js.map +0 -1
- package/dist/components/EventAddForm/components/CustomMeetingForm.js +0 -237
- package/dist/components/EventAddForm/components/CustomMeetingForm.js.map +0 -1
- package/dist/components/EventAddForm/components/DateTimeField.js +0 -173
- package/dist/components/EventAddForm/components/DateTimeField.js.map +0 -1
- package/dist/components/EventAddForm/components/EventSubmissionConfirmationModal.d.ts +0 -33
- package/dist/components/EventAddForm/components/EventSubmissionConfirmationModal.js +0 -366
- package/dist/components/EventAddForm/components/EventSubmissionConfirmationModal.js.map +0 -1
- package/dist/components/EventAddForm/components/FileUpload.js +0 -412
- package/dist/components/EventAddForm/components/FileUpload.js.map +0 -1
- package/dist/components/EventAddForm/components/FormBuilderProceedModal.js +0 -197
- package/dist/components/EventAddForm/components/FormBuilderProceedModal.js.map +0 -1
- package/dist/components/EventAddForm/components/GoogleMapsAutocompleteInput.js +0 -1179
- package/dist/components/EventAddForm/components/GoogleMapsAutocompleteInput.js.map +0 -1
- package/dist/components/EventAddForm/components/InputField.d.ts +0 -15
- package/dist/components/EventAddForm/components/RadioGroupButton.d.ts +0 -14
- package/dist/components/EventAddForm/components/SelectField.d.ts +0 -19
- package/dist/components/EventAddForm/components/SingleDateTimeInput.js +0 -102
- package/dist/components/EventAddForm/components/SingleDateTimeInput.js.map +0 -1
- package/dist/components/EventAddForm/components/StepTwo/CustomFormSection.js +0 -277
- package/dist/components/EventAddForm/components/StepTwo/CustomFormSection.js.map +0 -1
- package/dist/components/EventAddForm/components/StepTwo/TicketTierSection.js +0 -148
- package/dist/components/EventAddForm/components/StepTwo/TicketTierSection.js.map +0 -1
- package/dist/components/EventAddForm/components/TicketTierForm.js +0 -418
- package/dist/components/EventAddForm/components/TicketTierForm.js.map +0 -1
- package/dist/components/EventAddForm/components/TicketTypeSelection.js +0 -93
- package/dist/components/EventAddForm/components/TicketTypeSelection.js.map +0 -1
- package/dist/components/EventAddForm/hooks/useStepperForm.js +0 -371
- package/dist/components/EventAddForm/hooks/useStepperForm.js.map +0 -1
- package/dist/components/EventAddForm/hooks/useTicketTierForm.js +0 -237
- package/dist/components/EventAddForm/hooks/useTicketTierForm.js.map +0 -1
- package/dist/components/EventAddForm/index.d.ts +0 -3
- package/dist/components/EventAddForm/index.js +0 -41
- package/dist/components/EventAddForm/index.js.map +0 -1
- package/dist/components/EventAddForm/schemas/index.d.ts +0 -2
- package/dist/components/EventAddForm/schemas/step1.d.ts +0 -47
- package/dist/components/EventAddForm/schemas/step1.js +0 -135
- package/dist/components/EventAddForm/schemas/step1.js.map +0 -1
- package/dist/components/EventAddForm/schemas/step2.d.ts +0 -138
- package/dist/components/EventAddForm/schemas/step2.js +0 -94
- package/dist/components/EventAddForm/schemas/step2.js.map +0 -1
- package/dist/components/EventAddForm/schemas/utils.js +0 -28
- package/dist/components/EventAddForm/schemas/utils.js.map +0 -1
- package/dist/components/EventAddForm/steps/IndividualFormStep.js +0 -85
- package/dist/components/EventAddForm/steps/IndividualFormStep.js.map +0 -1
- package/dist/components/EventAddForm/steps/SocialProfilesStep.js +0 -123
- package/dist/components/EventAddForm/steps/SocialProfilesStep.js.map +0 -1
- package/dist/components/EventAddForm/steps/StepOne.js +0 -462
- package/dist/components/EventAddForm/steps/StepOne.js.map +0 -1
- package/dist/components/EventAddForm/steps/StepTwo.js +0 -173
- package/dist/components/EventAddForm/steps/StepTwo.js.map +0 -1
- package/dist/components/EventAddForm/steps/TeamFormStep.js +0 -13
- package/dist/components/EventAddForm/steps/TeamFormStep.js.map +0 -1
- package/dist/components/FormBuilder/CategoryList.js +0 -242
- package/dist/components/FormBuilder/CategoryList.js.map +0 -1
- package/dist/components/FormBuilder/DiscountInput.js +0 -366
- package/dist/components/FormBuilder/DiscountInput.js.map +0 -1
- package/dist/components/FormBuilder/FormBuilder.js +0 -918
- package/dist/components/FormBuilder/FormBuilder.js.map +0 -1
- package/dist/components/FormBuilder/OptionList.js +0 -120
- package/dist/components/FormBuilder/OptionList.js.map +0 -1
- package/dist/components/FormBuilder/PaymentPreview.d.ts +0 -12
- package/dist/components/FormBuilder/PaymentPreview.js +0 -70
- package/dist/components/FormBuilder/PaymentPreview.js.map +0 -1
- package/dist/components/FormBuilder/PreviewInput.d.ts +0 -10
- package/dist/components/FormBuilder/PreviewInput.js +0 -143
- package/dist/components/FormBuilder/PreviewInput.js.map +0 -1
- package/dist/components/FormBuilder/QuestionCard.js +0 -252
- package/dist/components/FormBuilder/QuestionCard.js.map +0 -1
- package/dist/components/FormBuilder/QuestionEditor.js +0 -166
- package/dist/components/FormBuilder/QuestionEditor.js.map +0 -1
- package/dist/components/FormBuilder/RequiredToggle.js +0 -43
- package/dist/components/FormBuilder/RequiredToggle.js.map +0 -1
- package/dist/components/FormBuilder/SortableQuestionList.js +0 -137
- package/dist/components/FormBuilder/SortableQuestionList.js.map +0 -1
- package/dist/components/FormBuilder/index.d.ts +0 -4
- package/dist/components/FormBuilder/utils.js +0 -229
- package/dist/components/FormBuilder/utils.js.map +0 -1
- package/dist/components/FormInput/FormInput.js +0 -126
- package/dist/components/FormInput/FormInput.js.map +0 -1
- package/dist/components/FormInput/FormInput.test.d.ts +0 -1
- package/dist/components/FormInput/index.d.ts +0 -2
- package/dist/components/ImageCropModal/index.js +0 -464
- package/dist/components/ImageCropModal/index.js.map +0 -1
- package/dist/components/InformationPopover/InformationPopover.d.ts +0 -7
- package/dist/components/InformationPopover/InformationPopover.js +0 -19
- package/dist/components/InformationPopover/InformationPopover.js.map +0 -1
- package/dist/components/InformationPopover.js +0 -19
- package/dist/components/InformationPopover.js.map +0 -1
- package/dist/components/InputErrorMessage/InputErrorMessage.js +0 -21
- package/dist/components/InputErrorMessage/InputErrorMessage.js.map +0 -1
- package/dist/components/Modal/Modal.d.ts +0 -15
- package/dist/components/Modal/Modal.js +0 -73
- package/dist/components/Modal/Modal.js.map +0 -1
- package/dist/components/Radio/Radio.js +0 -35
- package/dist/components/Radio/Radio.js.map +0 -1
- package/dist/components/Spinner/spinner.d.ts +0 -2
- package/dist/components/Spinner/spinner.js +0 -22
- package/dist/components/Spinner/spinner.js.map +0 -1
- package/dist/components/Toggle/Toggle.d.ts +0 -16
- package/dist/components/Toggle/index.d.ts +0 -2
- package/dist/components/Tooltip/Tooltip.d.ts +0 -12
- package/dist/components/Tooltip/Tooltip.js +0 -134
- package/dist/components/Tooltip/Tooltip.js.map +0 -1
- package/dist/components/common/FallbackImage.js +0 -47
- package/dist/components/common/FallbackImage.js.map +0 -1
- package/dist/components/ui/Calendar/calendar-utils.js +0 -51
- package/dist/components/ui/Calendar/calendar-utils.js.map +0 -1
- package/dist/components/ui/Calendar/index.js +0 -142
- package/dist/components/ui/Calendar/index.js.map +0 -1
- package/dist/components/ui/Checkbox.d.ts +0 -9
- package/dist/components/ui/Checkbox.js +0 -50
- package/dist/components/ui/Checkbox.js.map +0 -1
- package/dist/components/ui/DatePicker/index.js +0 -188
- package/dist/components/ui/DatePicker/index.js.map +0 -1
- package/dist/components/ui/FormInput.js +0 -129
- package/dist/components/ui/FormInput.js.map +0 -1
- package/dist/components/ui/InputErrorMessage.d.ts +0 -7
- package/dist/components/ui/InputErrorMessage.js +0 -21
- package/dist/components/ui/InputErrorMessage.js.map +0 -1
- package/dist/components/ui/Modal/index.js +0 -73
- package/dist/components/ui/Modal/index.js.map +0 -1
- package/dist/components/ui/Radio.d.ts +0 -6
- package/dist/components/ui/Radio.js +0 -35
- package/dist/components/ui/Radio.js.map +0 -1
- package/dist/components/ui/RichTextEditor.js +0 -242
- package/dist/components/ui/RichTextEditor.js.map +0 -1
- package/dist/components/ui/TimePicker/index.js +0 -215
- package/dist/components/ui/TimePicker/index.js.map +0 -1
- package/dist/components/ui/TimeSelector/index.js +0 -138
- package/dist/components/ui/TimeSelector/index.js.map +0 -1
- package/dist/components/ui/Tooltip.d.ts +0 -12
- package/dist/components/ui/Tooltip.js +0 -136
- package/dist/components/ui/Tooltip.js.map +0 -1
- package/dist/hooks/useDropdownPosition.d.ts +0 -11
- package/dist/hooks/useFirebaseAuthState.d.ts +0 -6
- package/dist/hooks/useFirebaseAuthState.js +0 -23
- package/dist/hooks/useFirebaseAuthState.js.map +0 -1
- package/dist/hooks/useTicketTierForm.d.ts +0 -61
- package/dist/lib/actions.js +0 -32
- package/dist/lib/actions.js.map +0 -1
- package/dist/lib/cropImage.js +0 -113
- package/dist/lib/cropImage.js.map +0 -1
- package/dist/lib/imageAnalysis.js +0 -58
- package/dist/lib/imageAnalysis.js.map +0 -1
- package/dist/lib/utils.js +0 -9
- package/dist/lib/utils.js.map +0 -1
- package/dist/node_modules/@dnd-kit/accessibility/dist/accessibility.esm.js +0 -60
- package/dist/node_modules/@dnd-kit/accessibility/dist/accessibility.esm.js.map +0 -1
- package/dist/node_modules/@dnd-kit/core/dist/core.esm.js +0 -3458
- package/dist/node_modules/@dnd-kit/core/dist/core.esm.js.map +0 -1
- package/dist/node_modules/@dnd-kit/sortable/dist/sortable.esm.js +0 -593
- package/dist/node_modules/@dnd-kit/sortable/dist/sortable.esm.js.map +0 -1
- package/dist/node_modules/@dnd-kit/utilities/dist/utilities.esm.js +0 -302
- package/dist/node_modules/@dnd-kit/utilities/dist/utilities.esm.js.map +0 -1
- package/dist/node_modules/@firebase/app/dist/esm/index.esm.js +0 -768
- package/dist/node_modules/@firebase/app/dist/esm/index.esm.js.map +0 -1
- package/dist/node_modules/@firebase/component/dist/esm/index.esm.js +0 -340
- package/dist/node_modules/@firebase/component/dist/esm/index.esm.js.map +0 -1
- package/dist/node_modules/@firebase/logger/dist/esm/index.esm.js +0 -123
- package/dist/node_modules/@firebase/logger/dist/esm/index.esm.js.map +0 -1
- package/dist/node_modules/@firebase/storage/dist/index.esm.js +0 -2623
- package/dist/node_modules/@firebase/storage/dist/index.esm.js.map +0 -1
- package/dist/node_modules/@firebase/util/dist/index.esm.js +0 -658
- package/dist/node_modules/@firebase/util/dist/index.esm.js.map +0 -1
- package/dist/node_modules/@firebase/util/dist/postinstall.js +0 -5
- package/dist/node_modules/@firebase/util/dist/postinstall.js.map +0 -1
- package/dist/node_modules/@fortawesome/fontawesome-svg-core/index.js +0 -3179
- package/dist/node_modules/@fortawesome/fontawesome-svg-core/index.js.map +0 -1
- package/dist/node_modules/@fortawesome/free-solid-svg-icons/index.js +0 -60
- package/dist/node_modules/@fortawesome/free-solid-svg-icons/index.js.map +0 -1
- package/dist/node_modules/@fortawesome/react-fontawesome/dist/index.js +0 -400
- package/dist/node_modules/@fortawesome/react-fontawesome/dist/index.js.map +0 -1
- package/dist/node_modules/@heroicons/react/20/solid/esm/CheckIcon.js +0 -27
- package/dist/node_modules/@heroicons/react/20/solid/esm/CheckIcon.js.map +0 -1
- package/dist/node_modules/@heroicons/react/20/solid/esm/ChevronDownIcon.js +0 -27
- package/dist/node_modules/@heroicons/react/20/solid/esm/ChevronDownIcon.js.map +0 -1
- package/dist/node_modules/@heroicons/react/24/outline/esm/ArrowRightIcon.js +0 -29
- package/dist/node_modules/@heroicons/react/24/outline/esm/ArrowRightIcon.js.map +0 -1
- package/dist/node_modules/@heroicons/react/24/outline/esm/ClockIcon.js +0 -29
- package/dist/node_modules/@heroicons/react/24/outline/esm/ClockIcon.js.map +0 -1
- package/dist/node_modules/@heroicons/react/24/outline/esm/DocumentDuplicateIcon.js +0 -29
- package/dist/node_modules/@heroicons/react/24/outline/esm/DocumentDuplicateIcon.js.map +0 -1
- package/dist/node_modules/@heroicons/react/24/outline/esm/InformationCircleIcon.js +0 -29
- package/dist/node_modules/@heroicons/react/24/outline/esm/InformationCircleIcon.js.map +0 -1
- package/dist/node_modules/@heroicons/react/24/outline/esm/LinkIcon.js +0 -29
- package/dist/node_modules/@heroicons/react/24/outline/esm/LinkIcon.js.map +0 -1
- package/dist/node_modules/@heroicons/react/24/outline/esm/MagnifyingGlassIcon.js +0 -29
- package/dist/node_modules/@heroicons/react/24/outline/esm/MagnifyingGlassIcon.js.map +0 -1
- package/dist/node_modules/@heroicons/react/24/outline/esm/MapPinIcon.js +0 -33
- package/dist/node_modules/@heroicons/react/24/outline/esm/MapPinIcon.js.map +0 -1
- package/dist/node_modules/@heroicons/react/24/outline/esm/VideoCameraIcon.js +0 -29
- package/dist/node_modules/@heroicons/react/24/outline/esm/VideoCameraIcon.js.map +0 -1
- package/dist/node_modules/@heroicons/react/24/outline/esm/XMarkIcon.js +0 -29
- package/dist/node_modules/@heroicons/react/24/outline/esm/XMarkIcon.js.map +0 -1
- package/dist/node_modules/@tiptap/core/dist/index.js +0 -5446
- package/dist/node_modules/@tiptap/core/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/core/dist/jsx-runtime/jsx-runtime.js +0 -21
- package/dist/node_modules/@tiptap/core/dist/jsx-runtime/jsx-runtime.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-blockquote/dist/index.js +0 -78
- package/dist/node_modules/@tiptap/extension-blockquote/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-bold/dist/index.js +0 -100
- package/dist/node_modules/@tiptap/extension-bold/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-code/dist/index.js +0 -70
- package/dist/node_modules/@tiptap/extension-code/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-code-block/dist/index.js +0 -317
- package/dist/node_modules/@tiptap/extension-code-block/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-document/dist/index.js +0 -16
- package/dist/node_modules/@tiptap/extension-document/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-hard-break/dist/index.js +0 -66
- package/dist/node_modules/@tiptap/extension-hard-break/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-heading/dist/index.js +0 -86
- package/dist/node_modules/@tiptap/extension-heading/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-horizontal-rule/dist/index.js +0 -80
- package/dist/node_modules/@tiptap/extension-horizontal-rule/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-italic/dist/index.js +0 -98
- package/dist/node_modules/@tiptap/extension-italic/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-link/dist/index.js +0 -423
- package/dist/node_modules/@tiptap/extension-link/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-list/dist/index.js +0 -1039
- package/dist/node_modules/@tiptap/extension-list/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-paragraph/dist/index.js +0 -61
- package/dist/node_modules/@tiptap/extension-paragraph/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-placeholder/dist/index.js +0 -7
- package/dist/node_modules/@tiptap/extension-placeholder/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-strike/dist/index.js +0 -79
- package/dist/node_modules/@tiptap/extension-strike/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-text/dist/index.js +0 -16
- package/dist/node_modules/@tiptap/extension-text/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extension-underline/dist/index.js +0 -76
- package/dist/node_modules/@tiptap/extension-underline/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/extensions/dist/index.js +0 -376
- package/dist/node_modules/@tiptap/extensions/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/react/dist/index.js +0 -650
- package/dist/node_modules/@tiptap/react/dist/index.js.map +0 -1
- package/dist/node_modules/@tiptap/starter-kit/dist/index.js +0 -97
- package/dist/node_modules/@tiptap/starter-kit/dist/index.js.map +0 -1
- package/dist/node_modules/dayjs/dayjs.min.js +0 -283
- package/dist/node_modules/dayjs/dayjs.min.js.map +0 -1
- package/dist/node_modules/dayjs/plugin/customParseFormat.js +0 -130
- package/dist/node_modules/dayjs/plugin/customParseFormat.js.map +0 -1
- package/dist/node_modules/dayjs/plugin/duration.js +0 -137
- package/dist/node_modules/dayjs/plugin/duration.js.map +0 -1
- package/dist/node_modules/dayjs/plugin/isBetween.js +0 -20
- package/dist/node_modules/dayjs/plugin/isBetween.js.map +0 -1
- package/dist/node_modules/dayjs/plugin/relativeTime.js +0 -49
- package/dist/node_modules/dayjs/plugin/relativeTime.js.map +0 -1
- package/dist/node_modules/fast-equals/dist/es/index.js +0 -442
- package/dist/node_modules/fast-equals/dist/es/index.js.map +0 -1
- package/dist/node_modules/idb/build/index.js +0 -70
- package/dist/node_modules/idb/build/index.js.map +0 -1
- package/dist/node_modules/idb/build/wrap-idb-value.js +0 -149
- package/dist/node_modules/idb/build/wrap-idb-value.js.map +0 -1
- package/dist/node_modules/linkifyjs/dist/linkify.js +0 -1159
- package/dist/node_modules/linkifyjs/dist/linkify.js.map +0 -1
- package/dist/node_modules/orderedmap/dist/index.js +0 -120
- package/dist/node_modules/orderedmap/dist/index.js.map +0 -1
- package/dist/node_modules/prosemirror-commands/dist/index.js +0 -527
- package/dist/node_modules/prosemirror-commands/dist/index.js.map +0 -1
- package/dist/node_modules/prosemirror-dropcursor/dist/index.js +0 -137
- package/dist/node_modules/prosemirror-dropcursor/dist/index.js.map +0 -1
- package/dist/node_modules/prosemirror-gapcursor/dist/index.js +0 -221
- package/dist/node_modules/prosemirror-gapcursor/dist/index.js.map +0 -1
- package/dist/node_modules/prosemirror-history/dist/index.js +0 -357
- package/dist/node_modules/prosemirror-history/dist/index.js.map +0 -1
- package/dist/node_modules/prosemirror-keymap/dist/index.js +0 -84
- package/dist/node_modules/prosemirror-keymap/dist/index.js.map +0 -1
- package/dist/node_modules/prosemirror-model/dist/index.js +0 -3209
- package/dist/node_modules/prosemirror-model/dist/index.js.map +0 -1
- package/dist/node_modules/prosemirror-schema-list/dist/index.js +0 -131
- package/dist/node_modules/prosemirror-schema-list/dist/index.js.map +0 -1
- package/dist/node_modules/prosemirror-state/dist/index.js +0 -936
- package/dist/node_modules/prosemirror-state/dist/index.js.map +0 -1
- package/dist/node_modules/prosemirror-transform/dist/index.js +0 -1881
- package/dist/node_modules/prosemirror-transform/dist/index.js.map +0 -1
- package/dist/node_modules/prosemirror-view/dist/index.js +0 -5232
- package/dist/node_modules/prosemirror-view/dist/index.js.map +0 -1
- package/dist/node_modules/rope-sequence/dist/index.js +0 -184
- package/dist/node_modules/rope-sequence/dist/index.js.map +0 -1
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js +0 -82
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js.map +0 -1
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js +0 -78
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js.map +0 -1
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js +0 -78
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js.map +0 -1
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js +0 -63
- package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js.map +0 -1
- package/dist/node_modules/use-sync-external-store/shim/index.js +0 -13
- package/dist/node_modules/use-sync-external-store/shim/index.js.map +0 -1
- package/dist/node_modules/use-sync-external-store/shim/with-selector.js +0 -13
- package/dist/node_modules/use-sync-external-store/shim/with-selector.js.map +0 -1
- package/dist/node_modules/w3c-keyname/index.js +0 -106
- package/dist/node_modules/w3c-keyname/index.js.map +0 -1
- package/dist/node_modules/zod/v4/classic/coerce.js +0 -10
- package/dist/node_modules/zod/v4/classic/coerce.js.map +0 -1
- package/dist/node_modules/zod/v4/classic/compat.js +0 -8
- package/dist/node_modules/zod/v4/classic/compat.js.map +0 -1
- package/dist/node_modules/zod/v4/classic/errors.js +0 -45
- package/dist/node_modules/zod/v4/classic/errors.js.map +0 -1
- package/dist/node_modules/zod/v4/classic/iso.js +0 -44
- package/dist/node_modules/zod/v4/classic/iso.js.map +0 -1
- package/dist/node_modules/zod/v4/classic/parse.js +0 -30
- package/dist/node_modules/zod/v4/classic/parse.js.map +0 -1
- package/dist/node_modules/zod/v4/classic/schemas.js +0 -711
- package/dist/node_modules/zod/v4/classic/schemas.js.map +0 -1
- package/dist/node_modules/zod/v4/core/api.js +0 -588
- package/dist/node_modules/zod/v4/core/api.js.map +0 -1
- package/dist/node_modules/zod/v4/core/checks.js +0 -411
- package/dist/node_modules/zod/v4/core/checks.js.map +0 -1
- package/dist/node_modules/zod/v4/core/core.js +0 -75
- package/dist/node_modules/zod/v4/core/core.js.map +0 -1
- package/dist/node_modules/zod/v4/core/doc.js +0 -38
- package/dist/node_modules/zod/v4/core/doc.js.map +0 -1
- package/dist/node_modules/zod/v4/core/errors.js +0 -73
- package/dist/node_modules/zod/v4/core/errors.js.map +0 -1
- package/dist/node_modules/zod/v4/core/json-schema-processors.js +0 -359
- package/dist/node_modules/zod/v4/core/json-schema-processors.js.map +0 -1
- package/dist/node_modules/zod/v4/core/parse.js +0 -96
- package/dist/node_modules/zod/v4/core/parse.js.map +0 -1
- package/dist/node_modules/zod/v4/core/regexes.js +0 -84
- package/dist/node_modules/zod/v4/core/regexes.js.map +0 -1
- package/dist/node_modules/zod/v4/core/registries.js +0 -52
- package/dist/node_modules/zod/v4/core/registries.js.map +0 -1
- package/dist/node_modules/zod/v4/core/schemas.js +0 -1391
- package/dist/node_modules/zod/v4/core/schemas.js.map +0 -1
- package/dist/node_modules/zod/v4/core/to-json-schema.js +0 -363
- package/dist/node_modules/zod/v4/core/to-json-schema.js.map +0 -1
- package/dist/node_modules/zod/v4/core/util.js +0 -431
- package/dist/node_modules/zod/v4/core/util.js.map +0 -1
- package/dist/node_modules/zod/v4/core/versions.js +0 -9
- package/dist/node_modules/zod/v4/core/versions.js.map +0 -1
- package/dist/redux/baseQuery.d.ts +0 -1
- package/dist/redux/baseQuery.js +0 -24
- package/dist/redux/baseQuery.js.map +0 -1
- package/dist/services/eventApi.js +0 -411
- package/dist/services/eventApi.js.map +0 -1
- package/dist/services/helpers.js +0 -115
- package/dist/services/helpers.js.map +0 -1
- package/dist/services/initialize-firebase.d.ts +0 -2
- package/dist/services/initialize-firebase.js +0 -20
- package/dist/services/initialize-firebase.js.map +0 -1
- package/dist/services/process-image-on-server.js +0 -30
- package/dist/services/process-image-on-server.js.map +0 -1
- package/dist/services/remote-config.d.ts +0 -5
- package/dist/services/remote-config.js +0 -9
- package/dist/services/remote-config.js.map +0 -1
- package/dist/services/single-event-api.js +0 -301
- package/dist/services/single-event-api.js.map +0 -1
- package/dist/services/utils.js +0 -107
- package/dist/services/utils.js.map +0 -1
- package/dist/setupTests.d.ts +0 -1
- package/dist/stories/Alert.stories.d.ts +0 -10
- package/dist/stories/Button.stories.d.ts +0 -13
- package/dist/types/redux-types.d.ts +0 -15
- package/dist/types/types.d.ts +0 -60
- package/dist/types/types.js +0 -10
- package/dist/types/types.js.map +0 -1
- package/dist/utils/cn.d.ts +0 -6
- package/dist/utils/cn.js +0 -9
- package/dist/utils/cn.js.map +0 -1
- package/dist/utils/date-range.d.ts +0 -4
- package/dist/utils/date-range.js +0 -13
- package/dist/utils/date-range.js.map +0 -1
- package/dist/utils/single-event-helpers.d.ts +0 -50
- package/dist/utils/single-event-helpers.js +0 -18
- package/dist/utils/single-event-helpers.js.map +0 -1
- package/dist/utils/social-validation.js +0 -42
- package/dist/utils/social-validation.js.map +0 -1
- package/dist/utils/utils.js +0 -20
- package/dist/utils/utils.js.map +0 -1
- /package/dist/{components/Alert/Alert.d.ts → src/components/Alert/index.d.ts} +0 -0
- /package/dist/{components → src/components}/FormBuilder/CategoryList.d.ts +0 -0
- /package/dist/{components → src/components}/FormBuilder/OptionList.d.ts +0 -0
- /package/dist/{components → src/components}/FormBuilder/RequiredToggle.d.ts +0 -0
- /package/dist/{components → src/components}/FormBuilder/types.d.ts +0 -0
- /package/dist/{components → src/components}/FormBuilder/utils.d.ts +0 -0
- /package/dist/{components → src/components}/ImageCropModal/index.d.ts +0 -0
- /package/dist/{components → src/components}/InformationPopover.d.ts +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/common/DescriptionModal.d.ts +0 -0
- /package/dist/{components/ui/FormInput.d.ts → src/components/NewAddEvent/components/AddEventFormInput.d.ts} +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/components/CheckboxGroup.d.ts +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/components/CustomMeetingForm.d.ts +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/components/DateTimeField.d.ts +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/components/FileUpload.d.ts +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/components/FormBuilderProceedModal.d.ts +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/components/GoogleMapsAutocompleteInput.d.ts +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/components/SingleDateTimeInput.d.ts +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/components/StepTwo/CustomFormSection.d.ts +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/components/TicketTypeSelection.d.ts +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/steps/StepOne.d.ts +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/steps/StepTwo.d.ts +0 -0
- /package/dist/{components/EventAddForm → src/components/NewAddEvent}/types.d.ts +0 -0
- /package/dist/{components → src/components}/common/FallbackImage.d.ts +0 -0
- /package/dist/{components → src/components}/ui/Calendar/calendar-utils.d.ts +0 -0
- /package/dist/{components → src/components}/ui/Calendar/index.d.ts +0 -0
- /package/dist/{components/Checkbox → src/components/ui}/Checkbox.d.ts +0 -0
- /package/dist/{components/CustomSelect → src/components/ui}/CustomSelect.d.ts +0 -0
- /package/dist/{components → src/components}/ui/DatePicker/index.d.ts +0 -0
- /package/dist/{components/InputErrorMessage → src/components/ui}/InputErrorMessage.d.ts +0 -0
- /package/dist/{components → src/components}/ui/Modal/index.d.ts +0 -0
- /package/dist/{components/Radio → src/components/ui}/Radio.d.ts +0 -0
- /package/dist/{components → src/components}/ui/RichTextEditor.d.ts +0 -0
- /package/dist/{components → src/components}/ui/TimePicker/index.d.ts +0 -0
- /package/dist/{components → src/components}/ui/TimeSelector/index.d.ts +0 -0
- /package/dist/{components → src/components}/ui/Tooltip/index.d.ts +0 -0
- /package/dist/{lib → src/lib}/constants.d.ts +0 -0
- /package/dist/{lib → src/lib}/cropImage.d.ts +0 -0
- /package/dist/{lib → src/lib}/imageAnalysis.d.ts +0 -0
- /package/dist/{utils → src/lib}/social-validation.d.ts +0 -0
- /package/dist/{lib/utils.d.ts → src/lib/tailwind-merge.d.ts} +0 -0
- /package/dist/{utils → src/lib}/utils.d.ts +0 -0
- /package/dist/{services → src/redux/features/single-event}/helpers.d.ts +0 -0
- /package/dist/{services → src/services}/process-image-on-server.d.ts +0 -0
- /package/dist/{types → src/types}/events.d.ts +0 -0
- /package/dist/{types → src/types}/question.d.ts +0 -0
|
@@ -1,711 +0,0 @@
|
|
|
1
|
-
import { $constructor, $ZodEncodeError } from "../core/core.js";
|
|
2
|
-
import { normalizeParams, issue, mergeDefs, clone, shallowClone, defineLazy, extend, safeExtend, merge, pick, omit, partial, required } from "../core/util.js";
|
|
3
|
-
import { $ZodPipe, $ZodTransform, $ZodType, $ZodOptional, $ZodExactOptional, $ZodNullable, $ZodNonOptional, $ZodIntersection, $ZodDefault, $ZodPrefault, $ZodCatch, $ZodReadonly, $ZodObjectJIT, $ZodUnion, $ZodRecord, $ZodEnum, $ZodLiteral, $ZodString, $ZodNumber, $ZodBoolean, $ZodArray, $ZodCustom, $ZodStringFormat, $ZodEmail, $ZodGUID, $ZodUUID, $ZodURL, $ZodEmoji, $ZodNanoID, $ZodCUID, $ZodCUID2, $ZodULID, $ZodXID, $ZodKSUID, $ZodIPv4, $ZodIPv6, $ZodCIDRv4, $ZodCIDRv6, $ZodBase64, $ZodBase64URL, $ZodE164, $ZodJWT, $ZodNumberFormat, $ZodAny, $ZodUnknown, $ZodNever } from "../core/schemas.js";
|
|
4
|
-
import { globalRegistry } from "../core/registries.js";
|
|
5
|
-
import { _string, _array, _number, _boolean, _overwrite, _refine, _superRefine, _email, _url, _jwt, _emoji, _guid, _uuid, _uuidv4, _uuidv6, _uuidv7, _nanoid, _cuid, _cuid2, _ulid, _base64, _base64url, _xid, _ksuid, _ipv4, _ipv6, _cidrv4, _cidrv6, _e164, _gt, _gte, _lt, _lte, _multipleOf, _minLength, _maxLength, _length, _unknown, _never, _regex, _includes, _startsWith, _endsWith, _lowercase, _uppercase, _trim, _normalize, _toLowerCase, _toUpperCase, _slugify, _int, _any } from "../core/api.js";
|
|
6
|
-
import { createStandardJSONSchemaMethod, createToJSONSchemaMethod } from "../core/to-json-schema.js";
|
|
7
|
-
import { pipeProcessor, transformProcessor, optionalProcessor, nullableProcessor, nonoptionalProcessor, intersectionProcessor, defaultProcessor, prefaultProcessor, catchProcessor, readonlyProcessor, objectProcessor, unionProcessor, recordProcessor, enumProcessor, literalProcessor, numberProcessor, booleanProcessor, arrayProcessor, customProcessor, stringProcessor, anyProcessor, unknownProcessor, neverProcessor } from "../core/json-schema-processors.js";
|
|
8
|
-
import { datetime, date, time, duration } from "./iso.js";
|
|
9
|
-
import { parse, safeParse, parseAsync, safeParseAsync, encode, decode, encodeAsync, decodeAsync, safeEncode, safeDecode, safeEncodeAsync, safeDecodeAsync } from "./parse.js";
|
|
10
|
-
const ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
|
|
11
|
-
$ZodType.init(inst, def);
|
|
12
|
-
Object.assign(inst["~standard"], {
|
|
13
|
-
jsonSchema: {
|
|
14
|
-
input: createStandardJSONSchemaMethod(inst, "input"),
|
|
15
|
-
output: createStandardJSONSchemaMethod(inst, "output")
|
|
16
|
-
}
|
|
17
|
-
});
|
|
18
|
-
inst.toJSONSchema = createToJSONSchemaMethod(inst, {});
|
|
19
|
-
inst.def = def;
|
|
20
|
-
inst.type = def.type;
|
|
21
|
-
Object.defineProperty(inst, "_def", { value: def });
|
|
22
|
-
inst.check = (...checks) => {
|
|
23
|
-
return inst.clone(mergeDefs(def, {
|
|
24
|
-
checks: [
|
|
25
|
-
...def.checks ?? [],
|
|
26
|
-
...checks.map((ch) => typeof ch === "function" ? { _zod: { check: ch, def: { check: "custom" }, onattach: [] } } : ch)
|
|
27
|
-
]
|
|
28
|
-
}), {
|
|
29
|
-
parent: true
|
|
30
|
-
});
|
|
31
|
-
};
|
|
32
|
-
inst.with = inst.check;
|
|
33
|
-
inst.clone = (def2, params) => clone(inst, def2, params);
|
|
34
|
-
inst.brand = () => inst;
|
|
35
|
-
inst.register = (reg, meta) => {
|
|
36
|
-
reg.add(inst, meta);
|
|
37
|
-
return inst;
|
|
38
|
-
};
|
|
39
|
-
inst.parse = (data, params) => parse(inst, data, params, { callee: inst.parse });
|
|
40
|
-
inst.safeParse = (data, params) => safeParse(inst, data, params);
|
|
41
|
-
inst.parseAsync = async (data, params) => parseAsync(inst, data, params, { callee: inst.parseAsync });
|
|
42
|
-
inst.safeParseAsync = async (data, params) => safeParseAsync(inst, data, params);
|
|
43
|
-
inst.spa = inst.safeParseAsync;
|
|
44
|
-
inst.encode = (data, params) => encode(inst, data, params);
|
|
45
|
-
inst.decode = (data, params) => decode(inst, data, params);
|
|
46
|
-
inst.encodeAsync = async (data, params) => encodeAsync(inst, data, params);
|
|
47
|
-
inst.decodeAsync = async (data, params) => decodeAsync(inst, data, params);
|
|
48
|
-
inst.safeEncode = (data, params) => safeEncode(inst, data, params);
|
|
49
|
-
inst.safeDecode = (data, params) => safeDecode(inst, data, params);
|
|
50
|
-
inst.safeEncodeAsync = async (data, params) => safeEncodeAsync(inst, data, params);
|
|
51
|
-
inst.safeDecodeAsync = async (data, params) => safeDecodeAsync(inst, data, params);
|
|
52
|
-
inst.refine = (check, params) => inst.check(refine(check, params));
|
|
53
|
-
inst.superRefine = (refinement) => inst.check(superRefine(refinement));
|
|
54
|
-
inst.overwrite = (fn) => inst.check(_overwrite(fn));
|
|
55
|
-
inst.optional = () => optional(inst);
|
|
56
|
-
inst.exactOptional = () => exactOptional(inst);
|
|
57
|
-
inst.nullable = () => nullable(inst);
|
|
58
|
-
inst.nullish = () => optional(nullable(inst));
|
|
59
|
-
inst.nonoptional = (params) => nonoptional(inst, params);
|
|
60
|
-
inst.array = () => array(inst);
|
|
61
|
-
inst.or = (arg) => union([inst, arg]);
|
|
62
|
-
inst.and = (arg) => intersection(inst, arg);
|
|
63
|
-
inst.transform = (tx) => pipe(inst, transform(tx));
|
|
64
|
-
inst.default = (def2) => _default(inst, def2);
|
|
65
|
-
inst.prefault = (def2) => prefault(inst, def2);
|
|
66
|
-
inst.catch = (params) => _catch(inst, params);
|
|
67
|
-
inst.pipe = (target) => pipe(inst, target);
|
|
68
|
-
inst.readonly = () => readonly(inst);
|
|
69
|
-
inst.describe = (description) => {
|
|
70
|
-
const cl = inst.clone();
|
|
71
|
-
globalRegistry.add(cl, { description });
|
|
72
|
-
return cl;
|
|
73
|
-
};
|
|
74
|
-
Object.defineProperty(inst, "description", {
|
|
75
|
-
get() {
|
|
76
|
-
var _a;
|
|
77
|
-
return (_a = globalRegistry.get(inst)) == null ? void 0 : _a.description;
|
|
78
|
-
},
|
|
79
|
-
configurable: true
|
|
80
|
-
});
|
|
81
|
-
inst.meta = (...args) => {
|
|
82
|
-
if (args.length === 0) {
|
|
83
|
-
return globalRegistry.get(inst);
|
|
84
|
-
}
|
|
85
|
-
const cl = inst.clone();
|
|
86
|
-
globalRegistry.add(cl, args[0]);
|
|
87
|
-
return cl;
|
|
88
|
-
};
|
|
89
|
-
inst.isOptional = () => inst.safeParse(void 0).success;
|
|
90
|
-
inst.isNullable = () => inst.safeParse(null).success;
|
|
91
|
-
inst.apply = (fn) => fn(inst);
|
|
92
|
-
return inst;
|
|
93
|
-
});
|
|
94
|
-
const _ZodString = /* @__PURE__ */ $constructor("_ZodString", (inst, def) => {
|
|
95
|
-
$ZodString.init(inst, def);
|
|
96
|
-
ZodType.init(inst, def);
|
|
97
|
-
inst._zod.processJSONSchema = (ctx, json, params) => stringProcessor(inst, ctx, json);
|
|
98
|
-
const bag = inst._zod.bag;
|
|
99
|
-
inst.format = bag.format ?? null;
|
|
100
|
-
inst.minLength = bag.minimum ?? null;
|
|
101
|
-
inst.maxLength = bag.maximum ?? null;
|
|
102
|
-
inst.regex = (...args) => inst.check(_regex(...args));
|
|
103
|
-
inst.includes = (...args) => inst.check(_includes(...args));
|
|
104
|
-
inst.startsWith = (...args) => inst.check(_startsWith(...args));
|
|
105
|
-
inst.endsWith = (...args) => inst.check(_endsWith(...args));
|
|
106
|
-
inst.min = (...args) => inst.check(_minLength(...args));
|
|
107
|
-
inst.max = (...args) => inst.check(_maxLength(...args));
|
|
108
|
-
inst.length = (...args) => inst.check(_length(...args));
|
|
109
|
-
inst.nonempty = (...args) => inst.check(_minLength(1, ...args));
|
|
110
|
-
inst.lowercase = (params) => inst.check(_lowercase(params));
|
|
111
|
-
inst.uppercase = (params) => inst.check(_uppercase(params));
|
|
112
|
-
inst.trim = () => inst.check(_trim());
|
|
113
|
-
inst.normalize = (...args) => inst.check(_normalize(...args));
|
|
114
|
-
inst.toLowerCase = () => inst.check(_toLowerCase());
|
|
115
|
-
inst.toUpperCase = () => inst.check(_toUpperCase());
|
|
116
|
-
inst.slugify = () => inst.check(_slugify());
|
|
117
|
-
});
|
|
118
|
-
const ZodString = /* @__PURE__ */ $constructor("ZodString", (inst, def) => {
|
|
119
|
-
$ZodString.init(inst, def);
|
|
120
|
-
_ZodString.init(inst, def);
|
|
121
|
-
inst.email = (params) => inst.check(_email(ZodEmail, params));
|
|
122
|
-
inst.url = (params) => inst.check(_url(ZodURL, params));
|
|
123
|
-
inst.jwt = (params) => inst.check(_jwt(ZodJWT, params));
|
|
124
|
-
inst.emoji = (params) => inst.check(_emoji(ZodEmoji, params));
|
|
125
|
-
inst.guid = (params) => inst.check(_guid(ZodGUID, params));
|
|
126
|
-
inst.uuid = (params) => inst.check(_uuid(ZodUUID, params));
|
|
127
|
-
inst.uuidv4 = (params) => inst.check(_uuidv4(ZodUUID, params));
|
|
128
|
-
inst.uuidv6 = (params) => inst.check(_uuidv6(ZodUUID, params));
|
|
129
|
-
inst.uuidv7 = (params) => inst.check(_uuidv7(ZodUUID, params));
|
|
130
|
-
inst.nanoid = (params) => inst.check(_nanoid(ZodNanoID, params));
|
|
131
|
-
inst.guid = (params) => inst.check(_guid(ZodGUID, params));
|
|
132
|
-
inst.cuid = (params) => inst.check(_cuid(ZodCUID, params));
|
|
133
|
-
inst.cuid2 = (params) => inst.check(_cuid2(ZodCUID2, params));
|
|
134
|
-
inst.ulid = (params) => inst.check(_ulid(ZodULID, params));
|
|
135
|
-
inst.base64 = (params) => inst.check(_base64(ZodBase64, params));
|
|
136
|
-
inst.base64url = (params) => inst.check(_base64url(ZodBase64URL, params));
|
|
137
|
-
inst.xid = (params) => inst.check(_xid(ZodXID, params));
|
|
138
|
-
inst.ksuid = (params) => inst.check(_ksuid(ZodKSUID, params));
|
|
139
|
-
inst.ipv4 = (params) => inst.check(_ipv4(ZodIPv4, params));
|
|
140
|
-
inst.ipv6 = (params) => inst.check(_ipv6(ZodIPv6, params));
|
|
141
|
-
inst.cidrv4 = (params) => inst.check(_cidrv4(ZodCIDRv4, params));
|
|
142
|
-
inst.cidrv6 = (params) => inst.check(_cidrv6(ZodCIDRv6, params));
|
|
143
|
-
inst.e164 = (params) => inst.check(_e164(ZodE164, params));
|
|
144
|
-
inst.datetime = (params) => inst.check(datetime(params));
|
|
145
|
-
inst.date = (params) => inst.check(date(params));
|
|
146
|
-
inst.time = (params) => inst.check(time(params));
|
|
147
|
-
inst.duration = (params) => inst.check(duration(params));
|
|
148
|
-
});
|
|
149
|
-
function string(params) {
|
|
150
|
-
return _string(ZodString, params);
|
|
151
|
-
}
|
|
152
|
-
const ZodStringFormat = /* @__PURE__ */ $constructor("ZodStringFormat", (inst, def) => {
|
|
153
|
-
$ZodStringFormat.init(inst, def);
|
|
154
|
-
_ZodString.init(inst, def);
|
|
155
|
-
});
|
|
156
|
-
const ZodEmail = /* @__PURE__ */ $constructor("ZodEmail", (inst, def) => {
|
|
157
|
-
$ZodEmail.init(inst, def);
|
|
158
|
-
ZodStringFormat.init(inst, def);
|
|
159
|
-
});
|
|
160
|
-
const ZodGUID = /* @__PURE__ */ $constructor("ZodGUID", (inst, def) => {
|
|
161
|
-
$ZodGUID.init(inst, def);
|
|
162
|
-
ZodStringFormat.init(inst, def);
|
|
163
|
-
});
|
|
164
|
-
const ZodUUID = /* @__PURE__ */ $constructor("ZodUUID", (inst, def) => {
|
|
165
|
-
$ZodUUID.init(inst, def);
|
|
166
|
-
ZodStringFormat.init(inst, def);
|
|
167
|
-
});
|
|
168
|
-
const ZodURL = /* @__PURE__ */ $constructor("ZodURL", (inst, def) => {
|
|
169
|
-
$ZodURL.init(inst, def);
|
|
170
|
-
ZodStringFormat.init(inst, def);
|
|
171
|
-
});
|
|
172
|
-
const ZodEmoji = /* @__PURE__ */ $constructor("ZodEmoji", (inst, def) => {
|
|
173
|
-
$ZodEmoji.init(inst, def);
|
|
174
|
-
ZodStringFormat.init(inst, def);
|
|
175
|
-
});
|
|
176
|
-
const ZodNanoID = /* @__PURE__ */ $constructor("ZodNanoID", (inst, def) => {
|
|
177
|
-
$ZodNanoID.init(inst, def);
|
|
178
|
-
ZodStringFormat.init(inst, def);
|
|
179
|
-
});
|
|
180
|
-
const ZodCUID = /* @__PURE__ */ $constructor("ZodCUID", (inst, def) => {
|
|
181
|
-
$ZodCUID.init(inst, def);
|
|
182
|
-
ZodStringFormat.init(inst, def);
|
|
183
|
-
});
|
|
184
|
-
const ZodCUID2 = /* @__PURE__ */ $constructor("ZodCUID2", (inst, def) => {
|
|
185
|
-
$ZodCUID2.init(inst, def);
|
|
186
|
-
ZodStringFormat.init(inst, def);
|
|
187
|
-
});
|
|
188
|
-
const ZodULID = /* @__PURE__ */ $constructor("ZodULID", (inst, def) => {
|
|
189
|
-
$ZodULID.init(inst, def);
|
|
190
|
-
ZodStringFormat.init(inst, def);
|
|
191
|
-
});
|
|
192
|
-
const ZodXID = /* @__PURE__ */ $constructor("ZodXID", (inst, def) => {
|
|
193
|
-
$ZodXID.init(inst, def);
|
|
194
|
-
ZodStringFormat.init(inst, def);
|
|
195
|
-
});
|
|
196
|
-
const ZodKSUID = /* @__PURE__ */ $constructor("ZodKSUID", (inst, def) => {
|
|
197
|
-
$ZodKSUID.init(inst, def);
|
|
198
|
-
ZodStringFormat.init(inst, def);
|
|
199
|
-
});
|
|
200
|
-
const ZodIPv4 = /* @__PURE__ */ $constructor("ZodIPv4", (inst, def) => {
|
|
201
|
-
$ZodIPv4.init(inst, def);
|
|
202
|
-
ZodStringFormat.init(inst, def);
|
|
203
|
-
});
|
|
204
|
-
const ZodIPv6 = /* @__PURE__ */ $constructor("ZodIPv6", (inst, def) => {
|
|
205
|
-
$ZodIPv6.init(inst, def);
|
|
206
|
-
ZodStringFormat.init(inst, def);
|
|
207
|
-
});
|
|
208
|
-
const ZodCIDRv4 = /* @__PURE__ */ $constructor("ZodCIDRv4", (inst, def) => {
|
|
209
|
-
$ZodCIDRv4.init(inst, def);
|
|
210
|
-
ZodStringFormat.init(inst, def);
|
|
211
|
-
});
|
|
212
|
-
const ZodCIDRv6 = /* @__PURE__ */ $constructor("ZodCIDRv6", (inst, def) => {
|
|
213
|
-
$ZodCIDRv6.init(inst, def);
|
|
214
|
-
ZodStringFormat.init(inst, def);
|
|
215
|
-
});
|
|
216
|
-
const ZodBase64 = /* @__PURE__ */ $constructor("ZodBase64", (inst, def) => {
|
|
217
|
-
$ZodBase64.init(inst, def);
|
|
218
|
-
ZodStringFormat.init(inst, def);
|
|
219
|
-
});
|
|
220
|
-
const ZodBase64URL = /* @__PURE__ */ $constructor("ZodBase64URL", (inst, def) => {
|
|
221
|
-
$ZodBase64URL.init(inst, def);
|
|
222
|
-
ZodStringFormat.init(inst, def);
|
|
223
|
-
});
|
|
224
|
-
const ZodE164 = /* @__PURE__ */ $constructor("ZodE164", (inst, def) => {
|
|
225
|
-
$ZodE164.init(inst, def);
|
|
226
|
-
ZodStringFormat.init(inst, def);
|
|
227
|
-
});
|
|
228
|
-
const ZodJWT = /* @__PURE__ */ $constructor("ZodJWT", (inst, def) => {
|
|
229
|
-
$ZodJWT.init(inst, def);
|
|
230
|
-
ZodStringFormat.init(inst, def);
|
|
231
|
-
});
|
|
232
|
-
const ZodNumber = /* @__PURE__ */ $constructor("ZodNumber", (inst, def) => {
|
|
233
|
-
$ZodNumber.init(inst, def);
|
|
234
|
-
ZodType.init(inst, def);
|
|
235
|
-
inst._zod.processJSONSchema = (ctx, json, params) => numberProcessor(inst, ctx, json);
|
|
236
|
-
inst.gt = (value, params) => inst.check(_gt(value, params));
|
|
237
|
-
inst.gte = (value, params) => inst.check(_gte(value, params));
|
|
238
|
-
inst.min = (value, params) => inst.check(_gte(value, params));
|
|
239
|
-
inst.lt = (value, params) => inst.check(_lt(value, params));
|
|
240
|
-
inst.lte = (value, params) => inst.check(_lte(value, params));
|
|
241
|
-
inst.max = (value, params) => inst.check(_lte(value, params));
|
|
242
|
-
inst.int = (params) => inst.check(int(params));
|
|
243
|
-
inst.safe = (params) => inst.check(int(params));
|
|
244
|
-
inst.positive = (params) => inst.check(_gt(0, params));
|
|
245
|
-
inst.nonnegative = (params) => inst.check(_gte(0, params));
|
|
246
|
-
inst.negative = (params) => inst.check(_lt(0, params));
|
|
247
|
-
inst.nonpositive = (params) => inst.check(_lte(0, params));
|
|
248
|
-
inst.multipleOf = (value, params) => inst.check(_multipleOf(value, params));
|
|
249
|
-
inst.step = (value, params) => inst.check(_multipleOf(value, params));
|
|
250
|
-
inst.finite = () => inst;
|
|
251
|
-
const bag = inst._zod.bag;
|
|
252
|
-
inst.minValue = Math.max(bag.minimum ?? Number.NEGATIVE_INFINITY, bag.exclusiveMinimum ?? Number.NEGATIVE_INFINITY) ?? null;
|
|
253
|
-
inst.maxValue = Math.min(bag.maximum ?? Number.POSITIVE_INFINITY, bag.exclusiveMaximum ?? Number.POSITIVE_INFINITY) ?? null;
|
|
254
|
-
inst.isInt = (bag.format ?? "").includes("int") || Number.isSafeInteger(bag.multipleOf ?? 0.5);
|
|
255
|
-
inst.isFinite = true;
|
|
256
|
-
inst.format = bag.format ?? null;
|
|
257
|
-
});
|
|
258
|
-
function number(params) {
|
|
259
|
-
return _number(ZodNumber, params);
|
|
260
|
-
}
|
|
261
|
-
const ZodNumberFormat = /* @__PURE__ */ $constructor("ZodNumberFormat", (inst, def) => {
|
|
262
|
-
$ZodNumberFormat.init(inst, def);
|
|
263
|
-
ZodNumber.init(inst, def);
|
|
264
|
-
});
|
|
265
|
-
function int(params) {
|
|
266
|
-
return _int(ZodNumberFormat, params);
|
|
267
|
-
}
|
|
268
|
-
const ZodBoolean = /* @__PURE__ */ $constructor("ZodBoolean", (inst, def) => {
|
|
269
|
-
$ZodBoolean.init(inst, def);
|
|
270
|
-
ZodType.init(inst, def);
|
|
271
|
-
inst._zod.processJSONSchema = (ctx, json, params) => booleanProcessor(inst, ctx, json);
|
|
272
|
-
});
|
|
273
|
-
function boolean(params) {
|
|
274
|
-
return _boolean(ZodBoolean, params);
|
|
275
|
-
}
|
|
276
|
-
const ZodAny = /* @__PURE__ */ $constructor("ZodAny", (inst, def) => {
|
|
277
|
-
$ZodAny.init(inst, def);
|
|
278
|
-
ZodType.init(inst, def);
|
|
279
|
-
inst._zod.processJSONSchema = (ctx, json, params) => anyProcessor();
|
|
280
|
-
});
|
|
281
|
-
function any() {
|
|
282
|
-
return _any(ZodAny);
|
|
283
|
-
}
|
|
284
|
-
const ZodUnknown = /* @__PURE__ */ $constructor("ZodUnknown", (inst, def) => {
|
|
285
|
-
$ZodUnknown.init(inst, def);
|
|
286
|
-
ZodType.init(inst, def);
|
|
287
|
-
inst._zod.processJSONSchema = (ctx, json, params) => unknownProcessor();
|
|
288
|
-
});
|
|
289
|
-
function unknown() {
|
|
290
|
-
return _unknown(ZodUnknown);
|
|
291
|
-
}
|
|
292
|
-
const ZodNever = /* @__PURE__ */ $constructor("ZodNever", (inst, def) => {
|
|
293
|
-
$ZodNever.init(inst, def);
|
|
294
|
-
ZodType.init(inst, def);
|
|
295
|
-
inst._zod.processJSONSchema = (ctx, json, params) => neverProcessor(inst, ctx, json);
|
|
296
|
-
});
|
|
297
|
-
function never(params) {
|
|
298
|
-
return _never(ZodNever, params);
|
|
299
|
-
}
|
|
300
|
-
const ZodArray = /* @__PURE__ */ $constructor("ZodArray", (inst, def) => {
|
|
301
|
-
$ZodArray.init(inst, def);
|
|
302
|
-
ZodType.init(inst, def);
|
|
303
|
-
inst._zod.processJSONSchema = (ctx, json, params) => arrayProcessor(inst, ctx, json, params);
|
|
304
|
-
inst.element = def.element;
|
|
305
|
-
inst.min = (minLength, params) => inst.check(_minLength(minLength, params));
|
|
306
|
-
inst.nonempty = (params) => inst.check(_minLength(1, params));
|
|
307
|
-
inst.max = (maxLength, params) => inst.check(_maxLength(maxLength, params));
|
|
308
|
-
inst.length = (len, params) => inst.check(_length(len, params));
|
|
309
|
-
inst.unwrap = () => inst.element;
|
|
310
|
-
});
|
|
311
|
-
function array(element, params) {
|
|
312
|
-
return _array(ZodArray, element, params);
|
|
313
|
-
}
|
|
314
|
-
const ZodObject = /* @__PURE__ */ $constructor("ZodObject", (inst, def) => {
|
|
315
|
-
$ZodObjectJIT.init(inst, def);
|
|
316
|
-
ZodType.init(inst, def);
|
|
317
|
-
inst._zod.processJSONSchema = (ctx, json, params) => objectProcessor(inst, ctx, json, params);
|
|
318
|
-
defineLazy(inst, "shape", () => {
|
|
319
|
-
return def.shape;
|
|
320
|
-
});
|
|
321
|
-
inst.keyof = () => _enum(Object.keys(inst._zod.def.shape));
|
|
322
|
-
inst.catchall = (catchall) => inst.clone({ ...inst._zod.def, catchall });
|
|
323
|
-
inst.passthrough = () => inst.clone({ ...inst._zod.def, catchall: unknown() });
|
|
324
|
-
inst.loose = () => inst.clone({ ...inst._zod.def, catchall: unknown() });
|
|
325
|
-
inst.strict = () => inst.clone({ ...inst._zod.def, catchall: never() });
|
|
326
|
-
inst.strip = () => inst.clone({ ...inst._zod.def, catchall: void 0 });
|
|
327
|
-
inst.extend = (incoming) => {
|
|
328
|
-
return extend(inst, incoming);
|
|
329
|
-
};
|
|
330
|
-
inst.safeExtend = (incoming) => {
|
|
331
|
-
return safeExtend(inst, incoming);
|
|
332
|
-
};
|
|
333
|
-
inst.merge = (other) => merge(inst, other);
|
|
334
|
-
inst.pick = (mask) => pick(inst, mask);
|
|
335
|
-
inst.omit = (mask) => omit(inst, mask);
|
|
336
|
-
inst.partial = (...args) => partial(ZodOptional, inst, args[0]);
|
|
337
|
-
inst.required = (...args) => required(ZodNonOptional, inst, args[0]);
|
|
338
|
-
});
|
|
339
|
-
function object(shape, params) {
|
|
340
|
-
const def = {
|
|
341
|
-
type: "object",
|
|
342
|
-
shape: shape ?? {},
|
|
343
|
-
...normalizeParams(params)
|
|
344
|
-
};
|
|
345
|
-
return new ZodObject(def);
|
|
346
|
-
}
|
|
347
|
-
const ZodUnion = /* @__PURE__ */ $constructor("ZodUnion", (inst, def) => {
|
|
348
|
-
$ZodUnion.init(inst, def);
|
|
349
|
-
ZodType.init(inst, def);
|
|
350
|
-
inst._zod.processJSONSchema = (ctx, json, params) => unionProcessor(inst, ctx, json, params);
|
|
351
|
-
inst.options = def.options;
|
|
352
|
-
});
|
|
353
|
-
function union(options, params) {
|
|
354
|
-
return new ZodUnion({
|
|
355
|
-
type: "union",
|
|
356
|
-
options,
|
|
357
|
-
...normalizeParams(params)
|
|
358
|
-
});
|
|
359
|
-
}
|
|
360
|
-
const ZodIntersection = /* @__PURE__ */ $constructor("ZodIntersection", (inst, def) => {
|
|
361
|
-
$ZodIntersection.init(inst, def);
|
|
362
|
-
ZodType.init(inst, def);
|
|
363
|
-
inst._zod.processJSONSchema = (ctx, json, params) => intersectionProcessor(inst, ctx, json, params);
|
|
364
|
-
});
|
|
365
|
-
function intersection(left, right) {
|
|
366
|
-
return new ZodIntersection({
|
|
367
|
-
type: "intersection",
|
|
368
|
-
left,
|
|
369
|
-
right
|
|
370
|
-
});
|
|
371
|
-
}
|
|
372
|
-
const ZodRecord = /* @__PURE__ */ $constructor("ZodRecord", (inst, def) => {
|
|
373
|
-
$ZodRecord.init(inst, def);
|
|
374
|
-
ZodType.init(inst, def);
|
|
375
|
-
inst._zod.processJSONSchema = (ctx, json, params) => recordProcessor(inst, ctx, json, params);
|
|
376
|
-
inst.keyType = def.keyType;
|
|
377
|
-
inst.valueType = def.valueType;
|
|
378
|
-
});
|
|
379
|
-
function record(keyType, valueType, params) {
|
|
380
|
-
return new ZodRecord({
|
|
381
|
-
type: "record",
|
|
382
|
-
keyType,
|
|
383
|
-
valueType,
|
|
384
|
-
...normalizeParams(params)
|
|
385
|
-
});
|
|
386
|
-
}
|
|
387
|
-
const ZodEnum = /* @__PURE__ */ $constructor("ZodEnum", (inst, def) => {
|
|
388
|
-
$ZodEnum.init(inst, def);
|
|
389
|
-
ZodType.init(inst, def);
|
|
390
|
-
inst._zod.processJSONSchema = (ctx, json, params) => enumProcessor(inst, ctx, json);
|
|
391
|
-
inst.enum = def.entries;
|
|
392
|
-
inst.options = Object.values(def.entries);
|
|
393
|
-
const keys = new Set(Object.keys(def.entries));
|
|
394
|
-
inst.extract = (values, params) => {
|
|
395
|
-
const newEntries = {};
|
|
396
|
-
for (const value of values) {
|
|
397
|
-
if (keys.has(value)) {
|
|
398
|
-
newEntries[value] = def.entries[value];
|
|
399
|
-
} else
|
|
400
|
-
throw new Error(`Key ${value} not found in enum`);
|
|
401
|
-
}
|
|
402
|
-
return new ZodEnum({
|
|
403
|
-
...def,
|
|
404
|
-
checks: [],
|
|
405
|
-
...normalizeParams(params),
|
|
406
|
-
entries: newEntries
|
|
407
|
-
});
|
|
408
|
-
};
|
|
409
|
-
inst.exclude = (values, params) => {
|
|
410
|
-
const newEntries = { ...def.entries };
|
|
411
|
-
for (const value of values) {
|
|
412
|
-
if (keys.has(value)) {
|
|
413
|
-
delete newEntries[value];
|
|
414
|
-
} else
|
|
415
|
-
throw new Error(`Key ${value} not found in enum`);
|
|
416
|
-
}
|
|
417
|
-
return new ZodEnum({
|
|
418
|
-
...def,
|
|
419
|
-
checks: [],
|
|
420
|
-
...normalizeParams(params),
|
|
421
|
-
entries: newEntries
|
|
422
|
-
});
|
|
423
|
-
};
|
|
424
|
-
});
|
|
425
|
-
function _enum(values, params) {
|
|
426
|
-
const entries = Array.isArray(values) ? Object.fromEntries(values.map((v) => [v, v])) : values;
|
|
427
|
-
return new ZodEnum({
|
|
428
|
-
type: "enum",
|
|
429
|
-
entries,
|
|
430
|
-
...normalizeParams(params)
|
|
431
|
-
});
|
|
432
|
-
}
|
|
433
|
-
function nativeEnum(entries, params) {
|
|
434
|
-
return new ZodEnum({
|
|
435
|
-
type: "enum",
|
|
436
|
-
entries,
|
|
437
|
-
...normalizeParams(params)
|
|
438
|
-
});
|
|
439
|
-
}
|
|
440
|
-
const ZodLiteral = /* @__PURE__ */ $constructor("ZodLiteral", (inst, def) => {
|
|
441
|
-
$ZodLiteral.init(inst, def);
|
|
442
|
-
ZodType.init(inst, def);
|
|
443
|
-
inst._zod.processJSONSchema = (ctx, json, params) => literalProcessor(inst, ctx, json);
|
|
444
|
-
inst.values = new Set(def.values);
|
|
445
|
-
Object.defineProperty(inst, "value", {
|
|
446
|
-
get() {
|
|
447
|
-
if (def.values.length > 1) {
|
|
448
|
-
throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");
|
|
449
|
-
}
|
|
450
|
-
return def.values[0];
|
|
451
|
-
}
|
|
452
|
-
});
|
|
453
|
-
});
|
|
454
|
-
function literal(value, params) {
|
|
455
|
-
return new ZodLiteral({
|
|
456
|
-
type: "literal",
|
|
457
|
-
values: Array.isArray(value) ? value : [value],
|
|
458
|
-
...normalizeParams(params)
|
|
459
|
-
});
|
|
460
|
-
}
|
|
461
|
-
const ZodTransform = /* @__PURE__ */ $constructor("ZodTransform", (inst, def) => {
|
|
462
|
-
$ZodTransform.init(inst, def);
|
|
463
|
-
ZodType.init(inst, def);
|
|
464
|
-
inst._zod.processJSONSchema = (ctx, json, params) => transformProcessor(inst, ctx);
|
|
465
|
-
inst._zod.parse = (payload, _ctx) => {
|
|
466
|
-
if (_ctx.direction === "backward") {
|
|
467
|
-
throw new $ZodEncodeError(inst.constructor.name);
|
|
468
|
-
}
|
|
469
|
-
payload.addIssue = (issue$1) => {
|
|
470
|
-
if (typeof issue$1 === "string") {
|
|
471
|
-
payload.issues.push(issue(issue$1, payload.value, def));
|
|
472
|
-
} else {
|
|
473
|
-
const _issue = issue$1;
|
|
474
|
-
if (_issue.fatal)
|
|
475
|
-
_issue.continue = false;
|
|
476
|
-
_issue.code ?? (_issue.code = "custom");
|
|
477
|
-
_issue.input ?? (_issue.input = payload.value);
|
|
478
|
-
_issue.inst ?? (_issue.inst = inst);
|
|
479
|
-
payload.issues.push(issue(_issue));
|
|
480
|
-
}
|
|
481
|
-
};
|
|
482
|
-
const output = def.transform(payload.value, payload);
|
|
483
|
-
if (output instanceof Promise) {
|
|
484
|
-
return output.then((output2) => {
|
|
485
|
-
payload.value = output2;
|
|
486
|
-
return payload;
|
|
487
|
-
});
|
|
488
|
-
}
|
|
489
|
-
payload.value = output;
|
|
490
|
-
return payload;
|
|
491
|
-
};
|
|
492
|
-
});
|
|
493
|
-
function transform(fn) {
|
|
494
|
-
return new ZodTransform({
|
|
495
|
-
type: "transform",
|
|
496
|
-
transform: fn
|
|
497
|
-
});
|
|
498
|
-
}
|
|
499
|
-
const ZodOptional = /* @__PURE__ */ $constructor("ZodOptional", (inst, def) => {
|
|
500
|
-
$ZodOptional.init(inst, def);
|
|
501
|
-
ZodType.init(inst, def);
|
|
502
|
-
inst._zod.processJSONSchema = (ctx, json, params) => optionalProcessor(inst, ctx, json, params);
|
|
503
|
-
inst.unwrap = () => inst._zod.def.innerType;
|
|
504
|
-
});
|
|
505
|
-
function optional(innerType) {
|
|
506
|
-
return new ZodOptional({
|
|
507
|
-
type: "optional",
|
|
508
|
-
innerType
|
|
509
|
-
});
|
|
510
|
-
}
|
|
511
|
-
const ZodExactOptional = /* @__PURE__ */ $constructor("ZodExactOptional", (inst, def) => {
|
|
512
|
-
$ZodExactOptional.init(inst, def);
|
|
513
|
-
ZodType.init(inst, def);
|
|
514
|
-
inst._zod.processJSONSchema = (ctx, json, params) => optionalProcessor(inst, ctx, json, params);
|
|
515
|
-
inst.unwrap = () => inst._zod.def.innerType;
|
|
516
|
-
});
|
|
517
|
-
function exactOptional(innerType) {
|
|
518
|
-
return new ZodExactOptional({
|
|
519
|
-
type: "optional",
|
|
520
|
-
innerType
|
|
521
|
-
});
|
|
522
|
-
}
|
|
523
|
-
const ZodNullable = /* @__PURE__ */ $constructor("ZodNullable", (inst, def) => {
|
|
524
|
-
$ZodNullable.init(inst, def);
|
|
525
|
-
ZodType.init(inst, def);
|
|
526
|
-
inst._zod.processJSONSchema = (ctx, json, params) => nullableProcessor(inst, ctx, json, params);
|
|
527
|
-
inst.unwrap = () => inst._zod.def.innerType;
|
|
528
|
-
});
|
|
529
|
-
function nullable(innerType) {
|
|
530
|
-
return new ZodNullable({
|
|
531
|
-
type: "nullable",
|
|
532
|
-
innerType
|
|
533
|
-
});
|
|
534
|
-
}
|
|
535
|
-
const ZodDefault = /* @__PURE__ */ $constructor("ZodDefault", (inst, def) => {
|
|
536
|
-
$ZodDefault.init(inst, def);
|
|
537
|
-
ZodType.init(inst, def);
|
|
538
|
-
inst._zod.processJSONSchema = (ctx, json, params) => defaultProcessor(inst, ctx, json, params);
|
|
539
|
-
inst.unwrap = () => inst._zod.def.innerType;
|
|
540
|
-
inst.removeDefault = inst.unwrap;
|
|
541
|
-
});
|
|
542
|
-
function _default(innerType, defaultValue) {
|
|
543
|
-
return new ZodDefault({
|
|
544
|
-
type: "default",
|
|
545
|
-
innerType,
|
|
546
|
-
get defaultValue() {
|
|
547
|
-
return typeof defaultValue === "function" ? defaultValue() : shallowClone(defaultValue);
|
|
548
|
-
}
|
|
549
|
-
});
|
|
550
|
-
}
|
|
551
|
-
const ZodPrefault = /* @__PURE__ */ $constructor("ZodPrefault", (inst, def) => {
|
|
552
|
-
$ZodPrefault.init(inst, def);
|
|
553
|
-
ZodType.init(inst, def);
|
|
554
|
-
inst._zod.processJSONSchema = (ctx, json, params) => prefaultProcessor(inst, ctx, json, params);
|
|
555
|
-
inst.unwrap = () => inst._zod.def.innerType;
|
|
556
|
-
});
|
|
557
|
-
function prefault(innerType, defaultValue) {
|
|
558
|
-
return new ZodPrefault({
|
|
559
|
-
type: "prefault",
|
|
560
|
-
innerType,
|
|
561
|
-
get defaultValue() {
|
|
562
|
-
return typeof defaultValue === "function" ? defaultValue() : shallowClone(defaultValue);
|
|
563
|
-
}
|
|
564
|
-
});
|
|
565
|
-
}
|
|
566
|
-
const ZodNonOptional = /* @__PURE__ */ $constructor("ZodNonOptional", (inst, def) => {
|
|
567
|
-
$ZodNonOptional.init(inst, def);
|
|
568
|
-
ZodType.init(inst, def);
|
|
569
|
-
inst._zod.processJSONSchema = (ctx, json, params) => nonoptionalProcessor(inst, ctx, json, params);
|
|
570
|
-
inst.unwrap = () => inst._zod.def.innerType;
|
|
571
|
-
});
|
|
572
|
-
function nonoptional(innerType, params) {
|
|
573
|
-
return new ZodNonOptional({
|
|
574
|
-
type: "nonoptional",
|
|
575
|
-
innerType,
|
|
576
|
-
...normalizeParams(params)
|
|
577
|
-
});
|
|
578
|
-
}
|
|
579
|
-
const ZodCatch = /* @__PURE__ */ $constructor("ZodCatch", (inst, def) => {
|
|
580
|
-
$ZodCatch.init(inst, def);
|
|
581
|
-
ZodType.init(inst, def);
|
|
582
|
-
inst._zod.processJSONSchema = (ctx, json, params) => catchProcessor(inst, ctx, json, params);
|
|
583
|
-
inst.unwrap = () => inst._zod.def.innerType;
|
|
584
|
-
inst.removeCatch = inst.unwrap;
|
|
585
|
-
});
|
|
586
|
-
function _catch(innerType, catchValue) {
|
|
587
|
-
return new ZodCatch({
|
|
588
|
-
type: "catch",
|
|
589
|
-
innerType,
|
|
590
|
-
catchValue: typeof catchValue === "function" ? catchValue : () => catchValue
|
|
591
|
-
});
|
|
592
|
-
}
|
|
593
|
-
const ZodPipe = /* @__PURE__ */ $constructor("ZodPipe", (inst, def) => {
|
|
594
|
-
$ZodPipe.init(inst, def);
|
|
595
|
-
ZodType.init(inst, def);
|
|
596
|
-
inst._zod.processJSONSchema = (ctx, json, params) => pipeProcessor(inst, ctx, json, params);
|
|
597
|
-
inst.in = def.in;
|
|
598
|
-
inst.out = def.out;
|
|
599
|
-
});
|
|
600
|
-
function pipe(in_, out) {
|
|
601
|
-
return new ZodPipe({
|
|
602
|
-
type: "pipe",
|
|
603
|
-
in: in_,
|
|
604
|
-
out
|
|
605
|
-
// ...util.normalizeParams(params),
|
|
606
|
-
});
|
|
607
|
-
}
|
|
608
|
-
const ZodReadonly = /* @__PURE__ */ $constructor("ZodReadonly", (inst, def) => {
|
|
609
|
-
$ZodReadonly.init(inst, def);
|
|
610
|
-
ZodType.init(inst, def);
|
|
611
|
-
inst._zod.processJSONSchema = (ctx, json, params) => readonlyProcessor(inst, ctx, json, params);
|
|
612
|
-
inst.unwrap = () => inst._zod.def.innerType;
|
|
613
|
-
});
|
|
614
|
-
function readonly(innerType) {
|
|
615
|
-
return new ZodReadonly({
|
|
616
|
-
type: "readonly",
|
|
617
|
-
innerType
|
|
618
|
-
});
|
|
619
|
-
}
|
|
620
|
-
const ZodCustom = /* @__PURE__ */ $constructor("ZodCustom", (inst, def) => {
|
|
621
|
-
$ZodCustom.init(inst, def);
|
|
622
|
-
ZodType.init(inst, def);
|
|
623
|
-
inst._zod.processJSONSchema = (ctx, json, params) => customProcessor(inst, ctx);
|
|
624
|
-
});
|
|
625
|
-
function refine(fn, _params = {}) {
|
|
626
|
-
return _refine(ZodCustom, fn, _params);
|
|
627
|
-
}
|
|
628
|
-
function superRefine(fn) {
|
|
629
|
-
return _superRefine(fn);
|
|
630
|
-
}
|
|
631
|
-
function preprocess(fn, schema) {
|
|
632
|
-
return pipe(transform(fn), schema);
|
|
633
|
-
}
|
|
634
|
-
export {
|
|
635
|
-
ZodAny,
|
|
636
|
-
ZodArray,
|
|
637
|
-
ZodBase64,
|
|
638
|
-
ZodBase64URL,
|
|
639
|
-
ZodBoolean,
|
|
640
|
-
ZodCIDRv4,
|
|
641
|
-
ZodCIDRv6,
|
|
642
|
-
ZodCUID,
|
|
643
|
-
ZodCUID2,
|
|
644
|
-
ZodCatch,
|
|
645
|
-
ZodCustom,
|
|
646
|
-
ZodDefault,
|
|
647
|
-
ZodE164,
|
|
648
|
-
ZodEmail,
|
|
649
|
-
ZodEmoji,
|
|
650
|
-
ZodEnum,
|
|
651
|
-
ZodExactOptional,
|
|
652
|
-
ZodGUID,
|
|
653
|
-
ZodIPv4,
|
|
654
|
-
ZodIPv6,
|
|
655
|
-
ZodIntersection,
|
|
656
|
-
ZodJWT,
|
|
657
|
-
ZodKSUID,
|
|
658
|
-
ZodLiteral,
|
|
659
|
-
ZodNanoID,
|
|
660
|
-
ZodNever,
|
|
661
|
-
ZodNonOptional,
|
|
662
|
-
ZodNullable,
|
|
663
|
-
ZodNumber,
|
|
664
|
-
ZodNumberFormat,
|
|
665
|
-
ZodObject,
|
|
666
|
-
ZodOptional,
|
|
667
|
-
ZodPipe,
|
|
668
|
-
ZodPrefault,
|
|
669
|
-
ZodReadonly,
|
|
670
|
-
ZodRecord,
|
|
671
|
-
ZodString,
|
|
672
|
-
ZodStringFormat,
|
|
673
|
-
ZodTransform,
|
|
674
|
-
ZodType,
|
|
675
|
-
ZodULID,
|
|
676
|
-
ZodURL,
|
|
677
|
-
ZodUUID,
|
|
678
|
-
ZodUnion,
|
|
679
|
-
ZodUnknown,
|
|
680
|
-
ZodXID,
|
|
681
|
-
_ZodString,
|
|
682
|
-
_default,
|
|
683
|
-
any,
|
|
684
|
-
array,
|
|
685
|
-
boolean,
|
|
686
|
-
_catch as catch,
|
|
687
|
-
_enum as enum,
|
|
688
|
-
exactOptional,
|
|
689
|
-
int,
|
|
690
|
-
intersection,
|
|
691
|
-
literal,
|
|
692
|
-
nativeEnum,
|
|
693
|
-
never,
|
|
694
|
-
nonoptional,
|
|
695
|
-
nullable,
|
|
696
|
-
number,
|
|
697
|
-
object,
|
|
698
|
-
optional,
|
|
699
|
-
pipe,
|
|
700
|
-
prefault,
|
|
701
|
-
preprocess,
|
|
702
|
-
readonly,
|
|
703
|
-
record,
|
|
704
|
-
refine,
|
|
705
|
-
string,
|
|
706
|
-
superRefine,
|
|
707
|
-
transform,
|
|
708
|
-
union,
|
|
709
|
-
unknown
|
|
710
|
-
};
|
|
711
|
-
//# sourceMappingURL=schemas.js.map
|