@calcom/atoms 2.0.0 → 2.2.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.
Files changed (260) hide show
  1. package/dist/{AddressInput-BpSJca3r.js → AddressInput-6bVKck2M.js} +1 -1
  2. package/dist/{AlbyPriceComponent-0EzHrAW1.js → AlbyPriceComponent-GfOmDB_O.js} +1 -1
  3. package/dist/{AppCard-8e-kpo72.js → AppCard-XVjVUT2T.js} +1 -1
  4. package/dist/{AppListCardPlatformWrapper-ixynsgLl.js → AppListCardPlatformWrapper-i7akxulv.js} +1 -1
  5. package/dist/{AppListCardWebWrapper-fZ9Ne6_r.js → AppListCardWebWrapper-dPeS1ok1.js} +1 -1
  6. package/dist/{AppSettingsInterface-vtpma4Ty.js → AppSettingsInterface-ETQ3qMkX.js} +1 -1
  7. package/dist/{AppSettingsInterface-jrZ0xNex.js → AppSettingsInterface-TrLEI6ni.js} +1 -1
  8. package/dist/{AppSettingsInterface-vmWnGjAP.js → AppSettingsInterface-ZA_4mY8_.js} +1 -1
  9. package/dist/{DateRangePicker-YEvczWqa.js → DateRangePicker-DQqNk0Jz.js} +1 -1
  10. package/dist/{EventTypeAppCardInterface-J2GpH83m.js → EventTypeAppCardInterface-1Wyihj4E.js} +3 -3
  11. package/dist/{EventTypeAppCardInterface-rOrmbyNN.js → EventTypeAppCardInterface-6sq_fBN1.js} +4 -4
  12. package/dist/{EventTypeAppCardInterface-aH_uqNUP.js → EventTypeAppCardInterface-CP8Elysz.js} +4 -4
  13. package/dist/{EventTypeAppCardInterface-ILCE1dyV.js → EventTypeAppCardInterface-FLCpeKqZ.js} +4 -4
  14. package/dist/{EventTypeAppCardInterface-YsABP7F5.js → EventTypeAppCardInterface-M1n4NXFA.js} +3 -3
  15. package/dist/{EventTypeAppCardInterface-cJTTVbQp.js → EventTypeAppCardInterface-MdK8qkg-.js} +4 -4
  16. package/dist/EventTypeAppCardInterface-N8wGa45M.js +69 -0
  17. package/dist/{EventTypeAppCardInterface-XYdXwsp1.js → EventTypeAppCardInterface-Qplt4YLq.js} +2 -2
  18. package/dist/{EventTypeAppCardInterface-64u7JDmK.js → EventTypeAppCardInterface-RHtdwd9a.js} +3 -3
  19. package/dist/{EventTypeAppCardInterface-zruB2FzC.js → EventTypeAppCardInterface-Uga0cNx6.js} +4 -4
  20. package/dist/{EventTypeAppCardInterface-SThwQJqI.js → EventTypeAppCardInterface-XSG4xPHW.js} +3 -3
  21. package/dist/{EventTypeAppCardInterface-KfTLSDMB.js → EventTypeAppCardInterface-ZHgUOsc7.js} +3 -3
  22. package/dist/{EventTypeAppCardInterface-r9B6g_vb.js → EventTypeAppCardInterface-b1u3_3R0.js} +4 -4
  23. package/dist/{EventTypeAppCardInterface-xdH4tRYC.js → EventTypeAppCardInterface-cc81lVyN.js} +4 -4
  24. package/dist/{EventTypeAppCardInterface-i5sePaPw.js → EventTypeAppCardInterface-eycetC2V.js} +3 -3
  25. package/dist/{EventTypeAppCardInterface-Ms-ryW85.js → EventTypeAppCardInterface-nL-zlXJQ.js} +4 -4
  26. package/dist/{EventTypeAppCardInterface-MQTWgkIo.js → EventTypeAppCardInterface-oLxuW8Vd.js} +4 -4
  27. package/dist/{EventTypeAppCardInterface-tFi51kOu.js → EventTypeAppCardInterface-oZda5T7g.js} +3 -3
  28. package/dist/{EventTypeAppCardInterface-bmQeZj3C.js → EventTypeAppCardInterface-pIt_xj9c.js} +3 -3
  29. package/dist/{EventTypeAppCardInterface-yg1X_xul.js → EventTypeAppCardInterface-qcozX-yQ.js} +4 -4
  30. package/dist/{EventTypeAppCardInterface-AxmjB7N4.js → EventTypeAppCardInterface-tgHZw_9s.js} +3 -3
  31. package/dist/{EventTypeAppCardInterface-XQAC7Sns.js → EventTypeAppCardInterface-toMtOVtA.js} +3 -3
  32. package/dist/{EventTypeAppCardInterface-GgzM8H2q.js → EventTypeAppCardInterface-ty37Eet2.js} +3 -3
  33. package/dist/{EventTypeAppCardInterface-RR8Pdcmk.js → EventTypeAppCardInterface-wOZWukpM.js} +2 -2
  34. package/dist/{EventTypeAppCardInterface-T51D3u6j.js → EventTypeAppCardInterface-xdESsRSy.js} +3 -3
  35. package/dist/{EventTypeAppCardInterface-x_wvzB0v.js → EventTypeAppCardInterface-xhl5HR0c.js} +4 -4
  36. package/dist/{EventTypeAppCardInterface-Wd5IxHUp.js → EventTypeAppCardInterface-y79vOxtJ.js} +3 -3
  37. package/dist/{EventTypeAppCardInterface-lBKaAtVo.js → EventTypeAppCardInterface-ygx1fj1H.js} +3 -3
  38. package/dist/{EventTypeAppSettingsInterface-O49EtYq9.js → EventTypeAppSettingsInterface-4A-o9k6K.js} +1 -1
  39. package/dist/{EventTypeAppSettingsInterface-_mhcQh98.js → EventTypeAppSettingsInterface-8Ydf4Kkr.js} +1 -1
  40. package/dist/{EventTypeAppSettingsInterface-gQwMLmra.js → EventTypeAppSettingsInterface-99ISmKkW.js} +1 -1
  41. package/dist/{EventTypeAppSettingsInterface-lUUXnR-g.js → EventTypeAppSettingsInterface-EtvOWW0T.js} +1 -1
  42. package/dist/{EventTypeAppSettingsInterface-UM5TZ94u.js → EventTypeAppSettingsInterface-LzkaglR0.js} +1 -1
  43. package/dist/{EventTypeAppSettingsInterface-kSolFl0q.js → EventTypeAppSettingsInterface-Ocx3MqcJ.js} +1 -1
  44. package/dist/{EventTypeAppSettingsInterface-WtvV4-VQ.js → EventTypeAppSettingsInterface-VXarBLQW.js} +1 -1
  45. package/dist/{EventTypeAppSettingsInterface-NcU2fhCq.js → EventTypeAppSettingsInterface-_L8Wkfpq.js} +1 -1
  46. package/dist/{EventTypeAppSettingsInterface-wQb-fMuk.js → EventTypeAppSettingsInterface-iF25p2gL.js} +1 -1
  47. package/dist/{EventTypeAppSettingsInterface-JPQ1yyiJ.js → EventTypeAppSettingsInterface-k25b3S_w.js} +1 -1
  48. package/dist/{EventTypeAppSettingsInterface-A9lNB6of.js → EventTypeAppSettingsInterface-mxDLmxhf.js} +1 -1
  49. package/dist/{EventTypeAppSettingsInterface-jYxTenwf.js → EventTypeAppSettingsInterface-oyqECCFB.js} +1 -1
  50. package/dist/{EventTypeAppSettingsInterface-NwadKkE9.js → EventTypeAppSettingsInterface-qExeDjlG.js} +1 -1
  51. package/dist/{EventTypeAppSettingsInterface-je_rg4FH.js → EventTypeAppSettingsInterface-xRSZJnRg.js} +1 -1
  52. package/dist/{InstallAppButton-IvfhWvux.js → InstallAppButton-RTdjVmy9.js} +1 -1
  53. package/dist/{InstallAppButton-9HlFrOHB.js → InstallAppButton-ZoK0cieH.js} +1 -1
  54. package/dist/{InstallAppButton-o3I02uwv.js → InstallAppButton-jnDe70lC.js} +1 -1
  55. package/dist/{PhoneInput-GWE7KXiz.js → PhoneInput-KPIrpgU-.js} +7 -7
  56. package/dist/StripePaymentForm-R4ocdPBz.js +493 -0
  57. package/dist/cal-atoms.js +1 -1
  58. package/dist/{index-n0I0RFcR.js → index-A4odhI08.js} +1 -1
  59. package/dist/{index-c1AU6gV4.js → index-dVustuDq.js} +99416 -75974
  60. package/dist/index-jM5C1qEC.js +579 -0
  61. package/dist/{index-FKnC-Bdq.js → index-lr8mon7V.js} +1 -1
  62. package/dist/packages/features/bookings/Booker/components/AvailableTimeSlots.d.ts.map +1 -1
  63. package/dist/packages/features/bookings/Booker/components/EventMeta.d.ts.map +1 -1
  64. package/dist/packages/features/bookings/Booker/components/OutOfOfficeInSlots.d.ts +2 -0
  65. package/dist/packages/features/bookings/Booker/components/OutOfOfficeInSlots.d.ts.map +1 -1
  66. package/dist/packages/features/bookings/Booker/components/ScrollableWithGradients.d.ts +9 -0
  67. package/dist/packages/features/bookings/Booker/components/ScrollableWithGradients.d.ts.map +1 -0
  68. package/dist/packages/features/bookings/Booker/components/hooks/useBookings.d.ts.map +1 -1
  69. package/dist/packages/features/bookings/Booker/utils/event.d.ts +21 -3
  70. package/dist/packages/features/bookings/Booker/utils/event.d.ts.map +1 -1
  71. package/dist/packages/features/bookings/lib/bookingCreateBodySchema.d.ts +12 -3
  72. package/dist/packages/features/bookings/lib/bookingCreateBodySchema.d.ts.map +1 -1
  73. package/dist/packages/features/bookings/lib/client/decoyBookingStore.d.ts +4 -3
  74. package/dist/packages/features/bookings/lib/client/decoyBookingStore.d.ts.map +1 -1
  75. package/dist/packages/features/bookings/lib/get-booking.d.ts +6 -0
  76. package/dist/packages/features/bookings/lib/get-booking.d.ts.map +1 -1
  77. package/dist/packages/features/bookings/lib/getAllUserBookings.d.ts +73 -2
  78. package/dist/packages/features/bookings/lib/getAllUserBookings.d.ts.map +1 -1
  79. package/dist/packages/features/bookings/lib/getBookingDataSchema.d.ts +4 -1
  80. package/dist/packages/features/bookings/lib/getBookingDataSchema.d.ts.map +1 -1
  81. package/dist/packages/features/bookings/lib/getBookingDataSchemaForApi.d.ts +6 -1
  82. package/dist/packages/features/bookings/lib/getBookingDataSchemaForApi.d.ts.map +1 -1
  83. package/dist/packages/features/bookings/lib/getLuckyUser.d.ts +2 -2
  84. package/dist/packages/features/bookings/lib/getLuckyUser.d.ts.map +1 -1
  85. package/dist/packages/features/bookings/lib/handleConfirmation.d.ts +2 -0
  86. package/dist/packages/features/bookings/lib/handleConfirmation.d.ts.map +1 -1
  87. package/dist/packages/features/bookings/lib/handleNewBooking/ensureAvailableUsers.d.ts +4 -0
  88. package/dist/packages/features/bookings/lib/handleNewBooking/ensureAvailableUsers.d.ts.map +1 -1
  89. package/dist/packages/features/bookings/lib/handleNewBooking/getBookingData.d.ts +4 -0
  90. package/dist/packages/features/bookings/lib/handleNewBooking/getBookingData.d.ts.map +1 -1
  91. package/dist/packages/features/bookings/lib/handleNewBooking/getEventType.d.ts +9 -0
  92. package/dist/packages/features/bookings/lib/handleNewBooking/getEventType.d.ts.map +1 -1
  93. package/dist/packages/features/bookings/lib/handleNewBooking/getEventTypesFromDB.d.ts +4 -0
  94. package/dist/packages/features/bookings/lib/handleNewBooking/getEventTypesFromDB.d.ts.map +1 -1
  95. package/dist/packages/features/bookings/lib/handleNewBooking/loadAndValidateUsers.d.ts +2 -1
  96. package/dist/packages/features/bookings/lib/handleNewBooking/loadAndValidateUsers.d.ts.map +1 -1
  97. package/dist/packages/features/bookings/lib/handleNewBooking/loadUsers.d.ts.map +1 -1
  98. package/dist/packages/features/bookings/lib/handleNewBooking/originalRescheduledBookingUtils.d.ts +6 -0
  99. package/dist/packages/features/bookings/lib/handleNewBooking/originalRescheduledBookingUtils.d.ts.map +1 -1
  100. package/dist/packages/features/bookings/lib/handleSeats/handleSeats.d.ts.map +1 -1
  101. package/dist/packages/features/bookings/lib/handleWebhookTrigger.d.ts +2 -0
  102. package/dist/packages/features/bookings/lib/handleWebhookTrigger.d.ts.map +1 -1
  103. package/dist/packages/features/bookings/lib/host-filtering/findQualifiedHostsWithDelegationCredentials.d.ts +6 -2
  104. package/dist/packages/features/bookings/lib/host-filtering/findQualifiedHostsWithDelegationCredentials.d.ts.map +1 -1
  105. package/dist/packages/features/bookings/lib/payment/getBooking.d.ts +2 -0
  106. package/dist/packages/features/bookings/lib/payment/getBooking.d.ts.map +1 -1
  107. package/dist/packages/features/bookings/lib/reschedule/determineReschedulePreventionRedirect.d.ts +4 -0
  108. package/dist/packages/features/bookings/lib/reschedule/determineReschedulePreventionRedirect.d.ts.map +1 -1
  109. package/dist/packages/features/bookings/lib/reschedule/isWithinMinimumRescheduleNotice.d.ts +2 -0
  110. package/dist/packages/features/bookings/lib/reschedule/isWithinMinimumRescheduleNotice.d.ts.map +1 -0
  111. package/dist/packages/features/bookings/lib/service/RegularBookingService.d.ts.map +1 -1
  112. package/dist/packages/features/bookings/lib/types/actor.d.ts +15 -0
  113. package/dist/packages/features/bookings/lib/types/actor.d.ts.map +1 -1
  114. package/dist/packages/features/data-table/components/filters/AddFilterButton.d.ts +1 -1
  115. package/dist/packages/features/data-table/components/filters/AddFilterButton.d.ts.map +1 -1
  116. package/dist/packages/features/data-table/components/filters/FilterBar.d.ts.map +1 -1
  117. package/dist/packages/features/data-table/components/filters/index.d.ts.map +1 -1
  118. package/dist/packages/features/data-table/components/segment/FilterSegmentSelect.d.ts +5 -1
  119. package/dist/packages/features/data-table/components/segment/FilterSegmentSelect.d.ts.map +1 -1
  120. package/dist/packages/features/data-table/hooks/index.d.ts +1 -0
  121. package/dist/packages/features/data-table/hooks/index.d.ts.map +1 -1
  122. package/dist/packages/features/data-table/hooks/useDisplayedFilterCount.d.ts +6 -0
  123. package/dist/packages/features/data-table/hooks/useDisplayedFilterCount.d.ts.map +1 -0
  124. package/dist/packages/features/data-table/lib/parsers.d.ts +18 -18
  125. package/dist/packages/features/data-table/lib/serializers.d.ts +12 -12
  126. package/dist/packages/features/data-table/lib/types.d.ts +36 -36
  127. package/dist/packages/features/data-table/repositories/filterSegment.type.d.ts +96 -96
  128. package/dist/packages/features/ee/billing/api/webhook/_checkout.session.completed.d.ts +3 -0
  129. package/dist/packages/features/ee/billing/api/webhook/_checkout.session.completed.d.ts.map +1 -1
  130. package/dist/packages/features/ee/billing/constants.d.ts +1 -0
  131. package/dist/packages/features/ee/billing/constants.d.ts.map +1 -1
  132. package/dist/packages/features/ee/billing/di/modules/StripeClient.d.ts.map +1 -1
  133. package/dist/packages/features/ee/payments/api/webhook.d.ts +2 -1
  134. package/dist/packages/features/ee/payments/api/webhook.d.ts.map +1 -1
  135. package/dist/packages/features/ee/payments/pages/payment.d.ts +2 -0
  136. package/dist/packages/features/ee/payments/pages/payment.d.ts.map +1 -1
  137. package/dist/packages/features/ee/workflows/api/scheduleEmailReminders.d.ts.map +1 -1
  138. package/dist/packages/features/ee/workflows/lib/reminders/scheduleMandatoryReminder.d.ts +2 -0
  139. package/dist/packages/features/ee/workflows/lib/reminders/scheduleMandatoryReminder.d.ts.map +1 -1
  140. package/dist/packages/features/ee/workflows/lib/repository/workflowReminder.d.ts +9 -0
  141. package/dist/packages/features/ee/workflows/lib/repository/workflowReminder.d.ts.map +1 -1
  142. package/dist/packages/features/ee/workflows/repositories/WorkflowRepository.d.ts +4 -0
  143. package/dist/packages/features/ee/workflows/repositories/WorkflowRepository.d.ts.map +1 -1
  144. package/dist/packages/features/eventtypes/components/locations/CalVideoSettings.d.ts.map +1 -1
  145. package/dist/packages/features/eventtypes/components/tabs/advanced/DisableReschedulingController.d.ts +18 -0
  146. package/dist/packages/features/eventtypes/components/tabs/advanced/DisableReschedulingController.d.ts.map +1 -0
  147. package/dist/packages/features/eventtypes/components/tabs/advanced/EventAdvancedTab.d.ts +2 -0
  148. package/dist/packages/features/eventtypes/components/tabs/advanced/EventAdvancedTab.d.ts.map +1 -1
  149. package/dist/packages/features/eventtypes/hooks/useCreateEventType.d.ts +8 -0
  150. package/dist/packages/features/eventtypes/hooks/useCreateEventType.d.ts.map +1 -1
  151. package/dist/packages/features/eventtypes/lib/defaultEvents.d.ts +15 -0
  152. package/dist/packages/features/eventtypes/lib/defaultEvents.d.ts.map +1 -1
  153. package/dist/packages/features/eventtypes/lib/getEventTypeById.d.ts +5 -0
  154. package/dist/packages/features/eventtypes/lib/getEventTypeById.d.ts.map +1 -1
  155. package/dist/packages/features/eventtypes/lib/getEventTypesByViewer.d.ts +5 -0
  156. package/dist/packages/features/eventtypes/lib/getEventTypesByViewer.d.ts.map +1 -1
  157. package/dist/packages/features/eventtypes/lib/getEventTypesPublic.d.ts +2 -0
  158. package/dist/packages/features/eventtypes/lib/getEventTypesPublic.d.ts.map +1 -1
  159. package/dist/packages/features/eventtypes/lib/getPublicEvent.d.ts +15 -0
  160. package/dist/packages/features/eventtypes/lib/getPublicEvent.d.ts.map +1 -1
  161. package/dist/packages/features/eventtypes/lib/getTeamEventType.d.ts +1 -0
  162. package/dist/packages/features/eventtypes/lib/getTeamEventType.d.ts.map +1 -1
  163. package/dist/packages/features/eventtypes/lib/types.d.ts +21 -0
  164. package/dist/packages/features/eventtypes/lib/types.d.ts.map +1 -1
  165. package/dist/packages/features/eventtypes/repositories/EventRepository.d.ts +9 -0
  166. package/dist/packages/features/eventtypes/repositories/EventRepository.d.ts.map +1 -1
  167. package/dist/packages/features/eventtypes/repositories/__tests__/EventTypeRepository.test.d.ts +2 -0
  168. package/dist/packages/features/eventtypes/repositories/__tests__/EventTypeRepository.test.d.ts.map +1 -0
  169. package/dist/packages/features/eventtypes/repositories/eventTypeRepository.d.ts +50 -3
  170. package/dist/packages/features/eventtypes/repositories/eventTypeRepository.d.ts.map +1 -1
  171. package/dist/packages/features/schedules/lib/slots.d.ts.map +1 -1
  172. package/dist/packages/features/schedules/lib/use-schedule/useSchedule.d.ts +11 -3
  173. package/dist/packages/features/schedules/lib/use-schedule/useSchedule.d.ts.map +1 -1
  174. package/dist/packages/features/schedules/lib/use-schedule/useTimesForSchedule.d.ts +2 -2
  175. package/dist/packages/features/schedules/lib/use-schedule/useTimesForSchedule.d.ts.map +1 -1
  176. package/dist/packages/features/schedules/lib/use-schedule/useTimesForSchedule.timezone.test.d.ts +2 -0
  177. package/dist/packages/features/schedules/lib/use-schedule/useTimesForSchedule.timezone.test.d.ts.map +1 -0
  178. package/dist/packages/features/schedules/repositories/ScheduleRepository.d.ts +58 -5
  179. package/dist/packages/features/schedules/repositories/ScheduleRepository.d.ts.map +1 -1
  180. package/dist/packages/features/schedules/repositories/ScheduleRepository.test.d.ts +2 -0
  181. package/dist/packages/features/schedules/repositories/ScheduleRepository.test.d.ts.map +1 -0
  182. package/dist/packages/features/schedules/services/ScheduleService.d.ts.map +1 -1
  183. package/dist/packages/features/shell/DynamicModals.d.ts.map +1 -1
  184. package/dist/packages/features/shell/components/GatedFeaturesModal.d.ts +2 -0
  185. package/dist/packages/features/shell/components/GatedFeaturesModal.d.ts.map +1 -0
  186. package/dist/packages/features/shell/navigation/Navigation.d.ts.map +1 -1
  187. package/dist/packages/features/shell/navigation/NavigationItem.d.ts +0 -4
  188. package/dist/packages/features/shell/navigation/NavigationItem.d.ts.map +1 -1
  189. package/dist/packages/features/shell/stores/gatedFeaturesStore.d.ts +12 -0
  190. package/dist/packages/features/shell/stores/gatedFeaturesStore.d.ts.map +1 -0
  191. package/dist/packages/kysely/types.d.ts +6 -0
  192. package/dist/packages/kysely/types.d.ts.map +1 -1
  193. package/dist/packages/platform/atoms/booker/BookerPlatformWrapper.d.ts.map +1 -1
  194. package/dist/packages/platform/atoms/booker/types.d.ts +1 -0
  195. package/dist/packages/platform/atoms/booker/types.d.ts.map +1 -1
  196. package/dist/packages/platform/atoms/calendar-view/EventTypeCalendarViewComponent.d.ts.map +1 -1
  197. package/dist/packages/platform/atoms/connect/conferencing-apps/hooks/useAtomBulkUpdateEventTypesToDefaultLocation.d.ts +2 -0
  198. package/dist/packages/platform/atoms/connect/conferencing-apps/hooks/useAtomBulkUpdateEventTypesToDefaultLocation.d.ts.map +1 -1
  199. package/dist/packages/platform/atoms/event-types/hooks/useAtomEventTypeById.d.ts +4 -0
  200. package/dist/packages/platform/atoms/event-types/hooks/useAtomEventTypeById.d.ts.map +1 -1
  201. package/dist/packages/platform/atoms/event-types/hooks/useAtomEventTypePaymentInfo.d.ts +2 -0
  202. package/dist/packages/platform/atoms/event-types/hooks/useAtomEventTypePaymentInfo.d.ts.map +1 -1
  203. package/dist/packages/platform/atoms/event-types/hooks/useAtomUpdateEventType.d.ts +6 -0
  204. package/dist/packages/platform/atoms/event-types/hooks/useAtomUpdateEventType.d.ts.map +1 -1
  205. package/dist/packages/platform/atoms/event-types/hooks/useEventTypeForm.d.ts.map +1 -1
  206. package/dist/packages/platform/atoms/hooks/bookings/useCreateInstantBooking.d.ts +1 -0
  207. package/dist/packages/platform/atoms/hooks/bookings/useCreateInstantBooking.d.ts.map +1 -1
  208. package/dist/packages/platform/atoms/hooks/bookings/useGetBookingForReschedule.d.ts +2 -0
  209. package/dist/packages/platform/atoms/hooks/bookings/useGetBookingForReschedule.d.ts.map +1 -1
  210. package/dist/packages/platform/atoms/hooks/bookings/useHandleBookEvent.d.ts +2 -1
  211. package/dist/packages/platform/atoms/hooks/bookings/useHandleBookEvent.d.ts.map +1 -1
  212. package/dist/packages/platform/atoms/hooks/event-types/private/useCreateEventType.d.ts +2 -0
  213. package/dist/packages/platform/atoms/hooks/event-types/private/useCreateEventType.d.ts.map +1 -1
  214. package/dist/packages/platform/atoms/hooks/event-types/private/useCreateTeamEventType.d.ts +2 -0
  215. package/dist/packages/platform/atoms/hooks/event-types/private/useCreateTeamEventType.d.ts.map +1 -1
  216. package/dist/packages/platform/atoms/hooks/event-types/private/useDeleteEventTypeById.d.ts +2 -0
  217. package/dist/packages/platform/atoms/hooks/event-types/private/useDeleteEventTypeById.d.ts.map +1 -1
  218. package/dist/packages/platform/atoms/hooks/event-types/public/useAtomGetPublicEvent.d.ts +9 -0
  219. package/dist/packages/platform/atoms/hooks/event-types/public/useAtomGetPublicEvent.d.ts.map +1 -1
  220. package/dist/packages/platform/atoms/hooks/useAvailableSlots.d.ts.map +1 -1
  221. package/dist/packages/platform/atoms/vite.config.d.ts +1 -1
  222. package/dist/packages/platform/atoms/vite.config.d.ts.map +1 -1
  223. package/dist/packages/platform/libraries/repositories.d.ts +2 -2
  224. package/dist/packages/platform/libraries/repositories.d.ts.map +1 -1
  225. package/dist/packages/platform/types/bookings/2024-08-13/inputs/create-booking.input.d.ts +1 -0
  226. package/dist/packages/platform/types/bookings/2024-08-13/inputs/create-booking.input.d.ts.map +1 -1
  227. package/dist/packages/platform/types/event-types/event-types_2024_06_14/inputs/create-event-type.input.d.ts +1 -0
  228. package/dist/packages/platform/types/event-types/event-types_2024_06_14/inputs/create-event-type.input.d.ts.map +1 -1
  229. package/dist/packages/platform/types/event-types/event-types_2024_06_14/inputs/update-event-type.input.d.ts +1 -0
  230. package/dist/packages/platform/types/event-types/event-types_2024_06_14/inputs/update-event-type.input.d.ts.map +1 -1
  231. package/dist/packages/platform/types/event-types/event-types_2024_06_14/outputs/event-type.output.d.ts +1 -0
  232. package/dist/packages/platform/types/event-types/event-types_2024_06_14/outputs/event-type.output.d.ts.map +1 -1
  233. package/dist/packages/platform/types/slots/slots-2024-04-15/inputs/index.d.ts +1 -0
  234. package/dist/packages/platform/types/slots/slots-2024-04-15/inputs/index.d.ts.map +1 -1
  235. package/dist/packages/platform/types/slots/slots-2024-09-04/inputs/get-slots.input.d.ts +1 -0
  236. package/dist/packages/platform/types/slots/slots-2024-09-04/inputs/get-slots.input.d.ts.map +1 -1
  237. package/dist/packages/prisma/zod/inputTypeSchemas/EventTypeScalarFieldEnumSchema.d.ts +1 -1
  238. package/dist/packages/prisma/zod/inputTypeSchemas/EventTypeScalarFieldEnumSchema.d.ts.map +1 -1
  239. package/dist/packages/prisma/zod/inputTypeSchemas/OutOfOfficeEntryScalarFieldEnumSchema.d.ts +1 -1
  240. package/dist/packages/prisma/zod/inputTypeSchemas/OutOfOfficeEntryScalarFieldEnumSchema.d.ts.map +1 -1
  241. package/dist/packages/prisma/zod/modelSchema/EventTypeSchema.d.ts +22 -0
  242. package/dist/packages/prisma/zod/modelSchema/EventTypeSchema.d.ts.map +1 -1
  243. package/dist/packages/prisma/zod/modelSchema/OutOfOfficeEntrySchema.d.ts +3 -0
  244. package/dist/packages/prisma/zod/modelSchema/OutOfOfficeEntrySchema.d.ts.map +1 -1
  245. package/dist/packages/prisma/zod-utils.d.ts +36 -0
  246. package/dist/packages/prisma/zod-utils.d.ts.map +1 -1
  247. package/dist/packages/trpc/server/routers/viewer/slots/_router.d.ts +1 -0
  248. package/dist/packages/trpc/server/routers/viewer/slots/_router.d.ts.map +1 -1
  249. package/dist/packages/trpc/server/routers/viewer/slots/types.d.ts +24 -3
  250. package/dist/packages/trpc/server/routers/viewer/slots/types.d.ts.map +1 -1
  251. package/dist/packages/trpc/server/routers/viewer/slots/util.d.ts +10 -2
  252. package/dist/packages/trpc/server/routers/viewer/slots/util.d.ts.map +1 -1
  253. package/dist/{useIsAppEnabled-LmZ5_dpZ.js → useIsAppEnabled-OQG85VSh.js} +1 -1
  254. package/package.json +1 -1
  255. package/dist/EventTypeAppCardInterface-i6nf7Wge.js +0 -48
  256. package/dist/StripePaymentForm-QbBVD2ns.js +0 -540
  257. package/dist/cal-atoms.umd.cjs +0 -656
  258. package/dist/index-SoDSIlE9.js +0 -664
  259. package/dist/packages/features/bookings/Booker/components/hooks/usePrefetch.d.ts +0 -19
  260. package/dist/packages/features/bookings/Booker/components/hooks/usePrefetch.d.ts.map +0 -1
@@ -0,0 +1,493 @@
1
+ import { jsxs as H, jsx as g } from "react/jsx-runtime";
2
+ import f, { useState as R, useEffect as Z } from "react";
3
+ import { aw as S, q as ee, b as Ce, B as G, W as Oe } from "./index-dVustuDq.js";
4
+ function Y(n, e) {
5
+ var t = Object.keys(n);
6
+ if (Object.getOwnPropertySymbols) {
7
+ var r = Object.getOwnPropertySymbols(n);
8
+ e && (r = r.filter(function(i) {
9
+ return Object.getOwnPropertyDescriptor(n, i).enumerable;
10
+ })), t.push.apply(t, r);
11
+ }
12
+ return t;
13
+ }
14
+ function V(n) {
15
+ for (var e = 1; e < arguments.length; e++) {
16
+ var t = arguments[e] != null ? arguments[e] : {};
17
+ e % 2 ? Y(Object(t), !0).forEach(function(r) {
18
+ te(n, r, t[r]);
19
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(t)) : Y(Object(t)).forEach(function(r) {
20
+ Object.defineProperty(n, r, Object.getOwnPropertyDescriptor(t, r));
21
+ });
22
+ }
23
+ return n;
24
+ }
25
+ function A(n) {
26
+ "@babel/helpers - typeof";
27
+ return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? A = function(e) {
28
+ return typeof e;
29
+ } : A = function(e) {
30
+ return e && typeof Symbol == "function" && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
31
+ }, A(n);
32
+ }
33
+ function te(n, e, t) {
34
+ return e in n ? Object.defineProperty(n, e, {
35
+ value: t,
36
+ enumerable: !0,
37
+ configurable: !0,
38
+ writable: !0
39
+ }) : n[e] = t, n;
40
+ }
41
+ function Pe(n, e) {
42
+ return we(n) || je(n, e) || xe(n, e) || Ae();
43
+ }
44
+ function we(n) {
45
+ if (Array.isArray(n))
46
+ return n;
47
+ }
48
+ function je(n, e) {
49
+ var t = n && (typeof Symbol < "u" && n[Symbol.iterator] || n["@@iterator"]);
50
+ if (t != null) {
51
+ var r = [], i = !0, a = !1, d, l;
52
+ try {
53
+ for (t = t.call(n); !(i = (d = t.next()).done) && (r.push(d.value), !(e && r.length === e)); i = !0)
54
+ ;
55
+ } catch (o) {
56
+ a = !0, l = o;
57
+ } finally {
58
+ try {
59
+ !i && t.return != null && t.return();
60
+ } finally {
61
+ if (a)
62
+ throw l;
63
+ }
64
+ }
65
+ return r;
66
+ }
67
+ }
68
+ function xe(n, e) {
69
+ if (n) {
70
+ if (typeof n == "string")
71
+ return X(n, e);
72
+ var t = Object.prototype.toString.call(n).slice(8, -1);
73
+ if (t === "Object" && n.constructor && (t = n.constructor.name), t === "Map" || t === "Set")
74
+ return Array.from(n);
75
+ if (t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))
76
+ return X(n, e);
77
+ }
78
+ }
79
+ function X(n, e) {
80
+ (e == null || e > n.length) && (e = n.length);
81
+ for (var t = 0, r = new Array(e); t < e; t++)
82
+ r[t] = n[t];
83
+ return r;
84
+ }
85
+ function Ae() {
86
+ throw new TypeError(`Invalid attempt to destructure non-iterable instance.
87
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
88
+ }
89
+ var B = function(e) {
90
+ var t = f.useRef(e);
91
+ return f.useEffect(function() {
92
+ t.current = e;
93
+ }, [e]), t.current;
94
+ }, P = function(e) {
95
+ return e !== null && A(e) === "object";
96
+ }, Le = function(e) {
97
+ return P(e) && typeof e.then == "function";
98
+ }, Re = function(e) {
99
+ return P(e) && typeof e.elements == "function" && typeof e.createToken == "function" && typeof e.createPaymentMethod == "function" && typeof e.confirmCardPayment == "function";
100
+ }, z = "[object Object]", Ie = function n(e, t) {
101
+ if (!P(e) || !P(t))
102
+ return e === t;
103
+ var r = Array.isArray(e), i = Array.isArray(t);
104
+ if (r !== i)
105
+ return !1;
106
+ var a = Object.prototype.toString.call(e) === z, d = Object.prototype.toString.call(t) === z;
107
+ if (a !== d)
108
+ return !1;
109
+ if (!a && !r)
110
+ return e === t;
111
+ var l = Object.keys(e), o = Object.keys(t);
112
+ if (l.length !== o.length)
113
+ return !1;
114
+ for (var s = {}, c = 0; c < l.length; c += 1)
115
+ s[l[c]] = !0;
116
+ for (var y = 0; y < o.length; y += 1)
117
+ s[o[y]] = !0;
118
+ var u = Object.keys(s);
119
+ if (u.length !== l.length)
120
+ return !1;
121
+ var b = e, _ = t, C = function(j) {
122
+ return n(b[j], _[j]);
123
+ };
124
+ return u.every(C);
125
+ }, ne = function(e, t, r) {
126
+ return P(e) ? Object.keys(e).reduce(function(i, a) {
127
+ var d = !P(t) || !Ie(e[a], t[a]);
128
+ return r.includes(a) ? (d && console.warn("Unsupported prop change: options.".concat(a, " is not a mutable property.")), i) : d ? V(V({}, i || {}), {}, te({}, a, e[a])) : i;
129
+ }, null) : null;
130
+ }, ke = "Invalid prop `stripe` supplied to `Elements`. We recommend using the `loadStripe` utility from `@stripe/stripe-js`. See https://stripe.com/docs/stripe-js/react#elements-props-stripe for details.", J = function(e) {
131
+ if (e === null || Re(e))
132
+ return e;
133
+ throw new Error(ke);
134
+ }, Ne = function(e) {
135
+ if (Le(e))
136
+ return {
137
+ tag: "async",
138
+ stripePromise: Promise.resolve(e).then(J)
139
+ };
140
+ var t = J(e);
141
+ return t === null ? {
142
+ tag: "empty"
143
+ } : {
144
+ tag: "sync",
145
+ stripe: t
146
+ };
147
+ }, T = /* @__PURE__ */ f.createContext(null);
148
+ T.displayName = "ElementsContext";
149
+ var Be = function(e, t) {
150
+ if (!e)
151
+ throw new Error("Could not find Elements context; You need to wrap the part of your app that ".concat(t, " in an <Elements> provider."));
152
+ return e;
153
+ }, re = function(e) {
154
+ var t = e.stripe, r = e.options, i = e.children, a = f.useMemo(function() {
155
+ return Ne(t);
156
+ }, [t]), d = f.useState(function() {
157
+ return {
158
+ stripe: a.tag === "sync" ? a.stripe : null,
159
+ elements: a.tag === "sync" ? a.stripe.elements(r) : null
160
+ };
161
+ }), l = Pe(d, 2), o = l[0], s = l[1];
162
+ f.useEffect(function() {
163
+ var u = !0, b = function(C) {
164
+ s(function(w) {
165
+ return w.stripe ? w : {
166
+ stripe: C,
167
+ elements: C.elements(r)
168
+ };
169
+ });
170
+ };
171
+ return a.tag === "async" && !o.stripe ? a.stripePromise.then(function(_) {
172
+ _ && u && b(_);
173
+ }) : a.tag === "sync" && !o.stripe && b(a.stripe), function() {
174
+ u = !1;
175
+ };
176
+ }, [a, o, r]);
177
+ var c = B(t);
178
+ f.useEffect(function() {
179
+ c !== null && c !== t && console.warn("Unsupported prop change on Elements: You cannot change the `stripe` prop after setting it.");
180
+ }, [c, t]);
181
+ var y = B(r);
182
+ return f.useEffect(function() {
183
+ if (o.elements) {
184
+ var u = ne(r, y, ["clientSecret", "fonts"]);
185
+ u && o.elements.update(u);
186
+ }
187
+ }, [r, y, o.elements]), f.useEffect(function() {
188
+ var u = o.stripe;
189
+ !u || !u._registerWrapper || !u.registerAppInfo || (u._registerWrapper({
190
+ name: "react-stripe-js",
191
+ version: "1.10.0"
192
+ }), u.registerAppInfo({
193
+ name: "react-stripe-js",
194
+ version: "1.10.0",
195
+ url: "https://stripe.com/docs/stripe-js/react"
196
+ }));
197
+ }, [o.stripe]), /* @__PURE__ */ f.createElement(T.Provider, {
198
+ value: o
199
+ }, i);
200
+ };
201
+ re.propTypes = {
202
+ stripe: S.any,
203
+ options: S.object
204
+ };
205
+ var I = function(e) {
206
+ var t = f.useContext(T);
207
+ return Be(t, e);
208
+ }, Te = function() {
209
+ var e = I("calls useElements()"), t = e.elements;
210
+ return t;
211
+ }, $e = function() {
212
+ var e = I("calls useStripe()"), t = e.stripe;
213
+ return t;
214
+ };
215
+ S.func.isRequired;
216
+ var h = function(e) {
217
+ var t = f.useRef(e);
218
+ return f.useEffect(function() {
219
+ t.current = e;
220
+ }, [e]), function() {
221
+ t.current && t.current.apply(t, arguments);
222
+ };
223
+ }, E = function() {
224
+ }, Ue = function(e) {
225
+ return e.charAt(0).toUpperCase() + e.slice(1);
226
+ }, p = function(e, t) {
227
+ var r = "".concat(Ue(e), "Element"), i = function(o) {
228
+ var s = o.id, c = o.className, y = o.options, u = y === void 0 ? {} : y, b = o.onBlur, _ = b === void 0 ? E : b, C = o.onFocus, w = C === void 0 ? E : C, j = o.onReady, ce = j === void 0 ? E : j, U = o.onChange, ue = U === void 0 ? E : U, W = o.onEscape, le = W === void 0 ? E : W, F = o.onClick, fe = F === void 0 ? E : F, q = o.onLoadError, de = q === void 0 ? E : q, D = o.onLoaderStart, pe = D === void 0 ? E : D, me = I("mounts <".concat(r, ">")), M = me.elements, O = f.useRef(null), k = f.useRef(null), ye = h(ce), ve = h(_), ge = h(w), Se = h(fe), be = h(ue), he = h(le), Ee = h(de), _e = h(pe);
229
+ f.useLayoutEffect(function() {
230
+ if (O.current == null && M && k.current != null) {
231
+ var v = M.create(e, u);
232
+ O.current = v, v.mount(k.current), v.on("ready", function() {
233
+ return ye(v);
234
+ }), v.on("change", be), v.on("blur", ve), v.on("focus", ge), v.on("escape", he), v.on("loaderror", Ee), v.on("loaderstart", _e), v.on("click", Se);
235
+ }
236
+ });
237
+ var K = B(u);
238
+ return f.useEffect(function() {
239
+ if (O.current) {
240
+ var v = ne(u, K, ["paymentRequest"]);
241
+ v && O.current.update(v);
242
+ }
243
+ }, [u, K]), f.useLayoutEffect(function() {
244
+ return function() {
245
+ O.current && (O.current.destroy(), O.current = null);
246
+ };
247
+ }, []), /* @__PURE__ */ f.createElement("div", {
248
+ id: s,
249
+ className: c,
250
+ ref: k
251
+ });
252
+ }, a = function(o) {
253
+ I("mounts <".concat(r, ">"));
254
+ var s = o.id, c = o.className;
255
+ return /* @__PURE__ */ f.createElement("div", {
256
+ id: s,
257
+ className: c
258
+ });
259
+ }, d = t ? a : i;
260
+ return d.propTypes = {
261
+ id: S.string,
262
+ className: S.string,
263
+ onChange: S.func,
264
+ onBlur: S.func,
265
+ onFocus: S.func,
266
+ onReady: S.func,
267
+ onClick: S.func,
268
+ onLoadError: S.func,
269
+ onLoaderStart: S.func,
270
+ options: S.object
271
+ }, d.displayName = r, d.__elementType = e, d;
272
+ }, m = typeof window > "u";
273
+ p("auBankAccount", m);
274
+ p("card", m);
275
+ p("cardNumber", m);
276
+ p("cardExpiry", m);
277
+ p("cardCvc", m);
278
+ p("fpxBank", m);
279
+ p("iban", m);
280
+ p("idealBank", m);
281
+ p("p24Bank", m);
282
+ p("epsBank", m);
283
+ var We = p("payment", m);
284
+ p("paymentRequestButton", m);
285
+ p("linkAuthentication", m);
286
+ p("shippingAddress", m);
287
+ p("affirmMessage", m);
288
+ p("afterpayClearpayMessage", m);
289
+ var $ = {};
290
+ Object.defineProperty($, "__esModule", { value: !0 });
291
+ function L(n) {
292
+ "@babel/helpers - typeof";
293
+ return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? L = function(e) {
294
+ return typeof e;
295
+ } : L = function(e) {
296
+ return e && typeof Symbol == "function" && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
297
+ }, L(n);
298
+ }
299
+ var ae = "https://js.stripe.com/v3", Fe = /^https:\/\/js\.stripe\.com\/v3\/?(\?.*)?$/, Q = "loadStripe.setLoadParameters was called but an existing Stripe.js script already exists in the document; existing script parameters will be used", qe = function() {
300
+ for (var e = document.querySelectorAll('script[src^="'.concat(ae, '"]')), t = 0; t < e.length; t++) {
301
+ var r = e[t];
302
+ if (Fe.test(r.src))
303
+ return r;
304
+ }
305
+ return null;
306
+ }, De = function(e) {
307
+ var t = e && !e.advancedFraudSignals ? "?advancedFraudSignals=false" : "", r = document.createElement("script");
308
+ r.src = "".concat(ae).concat(t);
309
+ var i = document.head || document.body;
310
+ if (!i)
311
+ throw new Error("Expected document.body not to be null. Stripe.js requires a <body> element.");
312
+ return i.appendChild(r), r;
313
+ }, Me = function(e, t) {
314
+ !e || !e._registerWrapper || e._registerWrapper({
315
+ name: "stripe-js",
316
+ version: "1.35.0",
317
+ startTime: t
318
+ });
319
+ }, x = null, Ke = function(e) {
320
+ return x !== null || (x = new Promise(function(t, r) {
321
+ if (typeof window > "u") {
322
+ t(null);
323
+ return;
324
+ }
325
+ if (window.Stripe && e && console.warn(Q), window.Stripe) {
326
+ t(window.Stripe);
327
+ return;
328
+ }
329
+ try {
330
+ var i = qe();
331
+ i && e ? console.warn(Q) : i || (i = De(e)), i.addEventListener("load", function() {
332
+ window.Stripe ? t(window.Stripe) : r(new Error("Stripe.js not available"));
333
+ }), i.addEventListener("error", function() {
334
+ r(new Error("Failed to load Stripe.js"));
335
+ });
336
+ } catch (a) {
337
+ r(a);
338
+ return;
339
+ }
340
+ })), x;
341
+ }, He = function(e, t, r) {
342
+ if (e === null)
343
+ return null;
344
+ var i = e.apply(void 0, t);
345
+ return Me(i, r), i;
346
+ }, Ge = function(e) {
347
+ var t = `invalid load parameters; expected object of shape
348
+
349
+ {advancedFraudSignals: boolean}
350
+
351
+ but received
352
+
353
+ `.concat(JSON.stringify(e), `
354
+ `);
355
+ if (e === null || L(e) !== "object")
356
+ throw new Error(t);
357
+ if (Object.keys(e).length === 1 && typeof e.advancedFraudSignals == "boolean")
358
+ return e;
359
+ throw new Error(t);
360
+ }, oe, ie = !1, se = function() {
361
+ for (var e = arguments.length, t = new Array(e), r = 0; r < e; r++)
362
+ t[r] = arguments[r];
363
+ ie = !0;
364
+ var i = Date.now();
365
+ return Ke(oe).then(function(a) {
366
+ return He(a, t, i);
367
+ });
368
+ };
369
+ se.setLoadParameters = function(n) {
370
+ if (ie)
371
+ throw new Error("You cannot change load parameters after calling loadStripe");
372
+ oe = Ge(n);
373
+ };
374
+ $.loadStripe = se;
375
+ var Ye = $, Ve = {};
376
+ const Xe = Ve.NEXT_PUBLIC_STRIPE_PUBLIC_KEY || "";
377
+ let N;
378
+ const ze = (n) => (N || (N = Ye.loadStripe(
379
+ n || Xe
380
+ /* , {
381
+ locale: "es-419" TODO: Handle multiple locales,
382
+ } */
383
+ )), N), Je = ze, Qe = (n) => {
384
+ const { t: e, i18n: t } = ee(), { paymentOption: r, elements: i, state: a, onPaymentElementChange: d } = n, [l, o] = R(!1), [s, c] = R(r !== "HOLD"), y = l || !s || ["processing", "error"].includes(a.status), u = {
385
+ layout: "accordion"
386
+ };
387
+ return Z(() => {
388
+ i == null || i.update({ locale: t.language });
389
+ }, [i, t.language]), /* @__PURE__ */ H("form", { id: "payment-form", className: "bg-subtle mt-4 rounded-md p-6", onSubmit: n.onSubmit, children: [
390
+ /* @__PURE__ */ g("div", { children: /* @__PURE__ */ g(We, { options: u, onChange: (b) => d() }) }),
391
+ r === "HOLD" && /* @__PURE__ */ g("div", { className: "bg-cal-info mb-5 mt-2 rounded-md p-3", children: /* @__PURE__ */ g(
392
+ Ce,
393
+ {
394
+ description: e("acknowledge_booking_no_show_fee", {
395
+ amount: n.payment.amount / 100,
396
+ formatParams: { amount: { currency: n.payment.currency } }
397
+ }),
398
+ onChange: (b) => c(b.target.checked),
399
+ descriptionClassName: "text-info font-semibold"
400
+ }
401
+ ) }),
402
+ /* @__PURE__ */ H("div", { className: "mt-2 flex justify-end space-x-2", children: [
403
+ /* @__PURE__ */ g(
404
+ G,
405
+ {
406
+ color: "minimal",
407
+ disabled: y,
408
+ id: "cancel",
409
+ type: "button",
410
+ loading: l,
411
+ onClick: () => {
412
+ o(!0), n.onCancel();
413
+ },
414
+ children: /* @__PURE__ */ g("span", { id: "button-text", children: e("cancel") })
415
+ }
416
+ ),
417
+ /* @__PURE__ */ g(
418
+ G,
419
+ {
420
+ type: "submit",
421
+ disabled: y,
422
+ loading: a.status === "processing",
423
+ id: "submit",
424
+ color: "secondary",
425
+ children: /* @__PURE__ */ g("span", { id: "button-text", children: a.status === "processing" ? /* @__PURE__ */ g("div", { className: "spinner", id: "spinner" }) : e(r === "HOLD" ? "submit_card" : "pay_now") })
426
+ }
427
+ )
428
+ ] }),
429
+ a.status === "error" && /* @__PURE__ */ g("div", { className: "mt-4 text-center text-red-900 dark:text-gray-300", role: "alert", children: a.error.message })
430
+ ] });
431
+ }, Ze = (n) => {
432
+ const { t: e } = ee(), t = Te(), r = n.payment.paymentOption, i = n.booking.attendees[0].email, a = $e(), [d, l] = R({ status: "idle" });
433
+ return /* @__PURE__ */ g(
434
+ Qe,
435
+ {
436
+ ...n,
437
+ elements: t,
438
+ paymentOption: r,
439
+ state: d,
440
+ onSubmit: async (o) => {
441
+ var y;
442
+ if (o.preventDefault(), !a || !t)
443
+ return;
444
+ l({ status: "processing" });
445
+ let s;
446
+ const c = {
447
+ uid: n.booking.uid,
448
+ email: i
449
+ };
450
+ r === "HOLD" && "setupIntent" in n.payment.data ? (s = await a.confirmSetup({
451
+ elements: t,
452
+ redirect: "if_required"
453
+ }), s.setupIntent && (c.payment_intent = s.setupIntent.id, c.payment_intent_client_secret = s.setupIntent.client_secret || void 0, c.redirect_status = s.setupIntent.status)) : r === "ON_BOOKING" && (s = await a.confirmPayment({
454
+ elements: t,
455
+ redirect: "if_required",
456
+ confirmParams: {
457
+ return_url: `${Oe}/booking/${c.uid}`
458
+ }
459
+ }), s.paymentIntent && (c.payment_intent = s.paymentIntent.id, c.payment_intent_client_secret = s.paymentIntent.client_secret || void 0, c.redirect_status = s.paymentIntent.status)), s != null && s.error ? l({
460
+ status: "error",
461
+ error: new Error(`Payment failed: ${s.error.message}`)
462
+ }) : (l({ status: "idle" }), (y = n.onPaymentSuccess) == null || y.call(n, n), n.location && (n.location.includes("integration") ? c.location = e("web_conferencing_details_to_follow") : c.location = n.location));
463
+ },
464
+ onCancel: () => {
465
+ var o;
466
+ (o = n.onPaymentCancellation) == null || o.call(n, n);
467
+ },
468
+ onPaymentElementChange: () => {
469
+ l({ status: "idle" });
470
+ }
471
+ }
472
+ );
473
+ }, rt = (n) => {
474
+ const e = Je(n.payment.data.stripe_publishable_key), [t, r] = R("stripe");
475
+ return Z(() => {
476
+ document.documentElement.classList.contains("dark") && r("night");
477
+ }, []), /* @__PURE__ */ g(
478
+ re,
479
+ {
480
+ stripe: e,
481
+ options: {
482
+ clientSecret: n.clientSecret,
483
+ appearance: {
484
+ theme: t
485
+ }
486
+ },
487
+ children: /* @__PURE__ */ g(Ze, { ...n })
488
+ }
489
+ );
490
+ };
491
+ export {
492
+ rt as default
493
+ };
package/dist/cal-atoms.js CHANGED
@@ -1,4 +1,4 @@
1
- import { aJ as s, aK as t, aX as n, aH as o, b3 as r, bd as i, b5 as l, aW as u, b7 as C, be as b, bf as d, b2 as c, b4 as g, aI as S, bg as p, aV as v, b8 as m, aY as T, b1 as y, b6 as E, a_ as k, aL as B, bh as A, aS as f, aT as h, aR as O, aM as P, b9 as I, ba as R, aZ as x, aP as z, aQ as D, aN as F, ap as L, aU as M, bb as U, bc as V, a$ as w, aO as G, b0 as H } from "./index-c1AU6gV4.js";
1
+ import { aJ as s, aK as t, aX as n, aH as o, b3 as r, bd as i, b5 as l, aW as u, b7 as C, be as b, bf as d, b2 as c, b4 as g, aI as S, bg as p, aV as v, b8 as m, aY as T, b1 as y, b6 as E, a_ as k, aL as B, bh as A, aS as f, aT as h, aR as O, aM as P, b9 as I, ba as R, aZ as x, aP as z, aQ as D, aN as F, ap as L, aU as M, bb as U, bc as V, a$ as w, aO as G, b0 as H } from "./index-dVustuDq.js";
2
2
  export {
3
3
  s as AvailabilitySettings,
4
4
  t as Booker,
@@ -1,4 +1,4 @@
1
- import { T as m, a as n } from "./index-c1AU6gV4.js";
1
+ import { T as m, a as n } from "./index-dVustuDq.js";
2
2
  export {
3
3
  m as TimezoneSelect,
4
4
  n as TimezoneSelectComponent