@nylas/web-elements 1.1.0-canary.19.c → 1.1.0-canary.19.d
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/dist/cjs/add-circle-icon_2.cjs.entry.js +1 -1
- package/dist/cjs/archive-icon_7.cjs.entry.js +7 -7
- package/dist/cjs/arrow-icon.cjs.entry.js +1 -1
- package/dist/cjs/bold-icon_3.cjs.entry.js +3 -3
- package/dist/cjs/button-component_4.cjs.entry.js +203 -0
- package/dist/cjs/button-component_4.cjs.entry.js.map +1 -0
- package/dist/cjs/calendar-agenda-fill-icon_35.cjs.entry.js +6943 -0
- package/dist/cjs/calendar-agenda-fill-icon_35.cjs.entry.js.map +1 -0
- package/dist/cjs/chevron-icon_3.cjs.entry.js +11 -3
- package/dist/cjs/chevron-icon_3.cjs.entry.js.map +1 -1
- package/dist/cjs/clock-icon_2.cjs.entry.js +1 -1
- package/dist/cjs/{constants-3e962931.js → constants-7cc75333.js} +106 -1
- package/dist/cjs/{constants-3e962931.js.map → constants-7cc75333.js.map} +1 -1
- package/dist/cjs/copy-icon_4.cjs.entry.js +72 -0
- package/dist/cjs/copy-icon_4.cjs.entry.js.map +1 -0
- package/dist/cjs/document-refresh-icon.cjs.entry.js +1 -1
- package/dist/cjs/forward-icon_6.cjs.entry.js +7 -7
- package/dist/cjs/globe-icon.cjs.entry.js +1 -1
- package/dist/cjs/google-logo-icon_4.cjs.entry.js +192 -51
- package/dist/cjs/google-logo-icon_4.cjs.entry.js.map +1 -1
- package/dist/cjs/index-7af03e3f.js +20 -16
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/info-icon_2.cjs.entry.js +2 -2
- package/dist/cjs/input-dropdown_2.cjs.entry.js +2 -2
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/loading-icon.cjs.entry.js +1 -1
- package/dist/cjs/multi-select-dropdown.cjs.entry.js +144 -0
- package/dist/cjs/multi-select-dropdown.cjs.entry.js.map +1 -0
- package/dist/cjs/{nylas-api-request-a1751a40.js → nylas-api-request-393b08a0.js} +2 -1
- package/dist/cjs/nylas-api-request-393b08a0.js.map +1 -0
- package/dist/cjs/nylas-booked-event-card_10.cjs.entry.js +66 -35
- package/dist/cjs/nylas-booked-event-card_10.cjs.entry.js.map +1 -1
- package/dist/cjs/nylas-custom-booking-flow.cjs.entry.js +1 -1
- package/dist/cjs/nylas-form-card.cjs.entry.js +1 -1
- package/dist/cjs/nylas-if-state.cjs.entry.js +1 -1
- package/dist/cjs/nylas-list-folders.cjs.entry.js +1 -1
- package/dist/cjs/nylas-list-threads.cjs.entry.js +1 -1
- package/dist/cjs/nylas-login.cjs.entry.js +1 -1
- package/dist/cjs/nylas-mailbox-toolbar-button.cjs.entry.js +1 -1
- package/dist/cjs/nylas-mailbox.cjs.entry.js +1 -1
- package/dist/cjs/nylas-provider.cjs.entry.js +3 -3
- package/dist/cjs/nylas-scheduler-editor.cjs.entry.js +26 -9
- package/dist/cjs/nylas-scheduler-editor.cjs.entry.js.map +1 -1
- package/dist/cjs/nylas-scheduling.cjs.entry.js +3 -3
- package/dist/cjs/nylas-scheduling.cjs.entry.js.map +1 -1
- package/dist/cjs/nylas-threads-refresh.cjs.entry.js +2 -2
- package/dist/cjs/nylas-threads-search.cjs.entry.js +1 -1
- package/dist/cjs/nylas-time-window-picker.cjs.entry.js +1 -1
- package/dist/cjs/nylas-view-thread.cjs.entry.js +1 -1
- package/dist/cjs/nylas-web-elements.cjs.js +1 -1
- package/dist/cjs/play-icon_2.cjs.entry.js +2 -2
- package/dist/cjs/refresh-icon.cjs.entry.js +1 -1
- package/dist/cjs/{scheduler-config-store-9f19c7a9.js → scheduler-config-store-5bfc8cb8.js} +3 -1
- package/dist/cjs/scheduler-config-store-5bfc8cb8.js.map +1 -0
- package/dist/cjs/{scheduler-store-0f7328f1.js → scheduler-store-b5cf2e82.js} +43 -7
- package/dist/cjs/scheduler-store-b5cf2e82.js.map +1 -0
- package/dist/cjs/textarea-component.cjs.entry.js +3 -1
- package/dist/cjs/textarea-component.cjs.entry.js.map +1 -1
- package/dist/cjs/translate-icon.cjs.entry.js +1 -1
- package/dist/cjs/warning-icon.cjs.entry.js +1 -1
- package/dist/collection/collection-manifest.json +14 -0
- package/dist/collection/common/constants.js +102 -0
- package/dist/collection/common/constants.js.map +1 -1
- package/dist/collection/common/icons/add-circle.js +1 -1
- package/dist/collection/common/icons/archive.js +1 -1
- package/dist/collection/common/icons/arrow.js +1 -1
- package/dist/collection/common/icons/bold.js +1 -1
- package/dist/collection/common/icons/calendar-agenda-fill.js +63 -0
- package/dist/collection/common/icons/calendar-agenda-fill.js.map +1 -0
- package/dist/collection/common/icons/calendar-agenda.js +63 -0
- package/dist/collection/common/icons/calendar-agenda.js.map +1 -0
- package/dist/collection/common/icons/copy.js +63 -0
- package/dist/collection/common/icons/copy.js.map +1 -0
- package/dist/collection/common/icons/delete.js +63 -0
- package/dist/collection/common/icons/delete.js.map +1 -0
- package/dist/collection/common/icons/document-refresh.js +1 -1
- package/dist/collection/common/icons/dragable.js +63 -0
- package/dist/collection/common/icons/dragable.js.map +1 -0
- package/dist/collection/common/icons/edit.js +63 -0
- package/dist/collection/common/icons/edit.js.map +1 -0
- package/dist/collection/common/icons/eye.js +63 -0
- package/dist/collection/common/icons/eye.js.map +1 -0
- package/dist/collection/common/icons/flow.js +1 -1
- package/dist/collection/common/icons/folder.js +1 -1
- package/dist/collection/common/icons/forward.js +1 -1
- package/dist/collection/common/icons/globe.js +1 -1
- package/dist/collection/common/icons/google-logo.js +1 -1
- package/dist/collection/common/icons/google-meet.js +63 -0
- package/dist/collection/common/icons/google-meet.js.map +1 -0
- package/dist/collection/common/icons/inbox.js +1 -1
- package/dist/collection/common/icons/info.js +1 -1
- package/dist/collection/common/icons/italic.js +1 -1
- package/dist/collection/common/icons/loading.js +1 -1
- package/dist/collection/common/icons/location-off.js +1 -1
- package/dist/collection/common/icons/location.js +1 -1
- package/dist/collection/common/icons/microsof-teams.js +63 -0
- package/dist/collection/common/icons/microsof-teams.js.map +1 -0
- package/dist/collection/common/icons/microsoft-logo.js +1 -1
- package/dist/collection/common/icons/nylas-logo.js +1 -1
- package/dist/collection/common/icons/people.js +1 -1
- package/dist/collection/common/icons/person.js +1 -1
- package/dist/collection/common/icons/play.js +1 -1
- package/dist/collection/common/icons/plus.js +63 -0
- package/dist/collection/common/icons/plus.js.map +1 -0
- package/dist/collection/common/icons/refresh.js +1 -1
- package/dist/collection/common/icons/reply-all.js +1 -1
- package/dist/collection/common/icons/reply.js +1 -1
- package/dist/collection/common/icons/search.js +1 -1
- package/dist/collection/common/icons/sent.js +1 -1
- package/dist/collection/common/icons/spam.js +1 -1
- package/dist/collection/common/icons/star.js +1 -1
- package/dist/collection/common/icons/stop.js +1 -1
- package/dist/collection/common/icons/translate.js +1 -1
- package/dist/collection/common/icons/trash.js +1 -1
- package/dist/collection/common/icons/underline.js +1 -1
- package/dist/collection/common/icons/warning.js +1 -1
- package/dist/collection/common/icons/zoom.js +63 -0
- package/dist/collection/common/icons/zoom.js.map +1 -0
- package/dist/collection/common/nylas-api-request.js +1 -0
- package/dist/collection/common/nylas-api-request.js.map +1 -1
- package/dist/collection/common/types.js.map +1 -1
- package/dist/collection/components/design-system/button-component/button-component.css +4 -0
- package/dist/collection/components/design-system/button-component/button-component.js +1 -1
- package/dist/collection/components/design-system/checkbox-component/checkbox-component.css +15 -1
- package/dist/collection/components/design-system/checkbox-component/checkbox-component.js +46 -6
- package/dist/collection/components/design-system/checkbox-component/checkbox-component.js.map +1 -1
- package/dist/collection/components/design-system/input-component/input-component.css +9 -1
- package/dist/collection/components/design-system/input-component/input-component.js +20 -8
- package/dist/collection/components/design-system/input-component/input-component.js.map +1 -1
- package/dist/collection/components/design-system/input-dropdown/input-dropdown.js +1 -1
- package/dist/collection/components/design-system/multi-select-dropdown/multi-select-dropdown.css +8 -1
- package/dist/collection/components/design-system/multi-select-dropdown/multi-select-dropdown.js +21 -2
- package/dist/collection/components/design-system/multi-select-dropdown/multi-select-dropdown.js.map +1 -1
- package/dist/collection/components/design-system/radio-button-group/radio-button-group.css +57 -1
- package/dist/collection/components/design-system/radio-button-group/radio-button-group.js +69 -10
- package/dist/collection/components/design-system/radio-button-group/radio-button-group.js.map +1 -1
- package/dist/collection/components/design-system/select-dropdown/select-dropdown.js +45 -2
- package/dist/collection/components/design-system/select-dropdown/select-dropdown.js.map +1 -1
- package/dist/collection/components/design-system/textarea-component/textarea-component.js +23 -3
- package/dist/collection/components/design-system/textarea-component/textarea-component.js.map +1 -1
- package/dist/collection/components/design-system/time-period-selector/time-period-selector.js +1 -1
- package/dist/collection/components/design-system/toggle-switch/toggle-switch.css +1 -1
- package/dist/collection/components/design-system/toggle-switch/toggle-switch.js +5 -5
- package/dist/collection/components/design-system/toggle-switch/toggle-switch.js.map +1 -1
- package/dist/collection/components/design-system/tooltip-component/toolitp-component.js +1 -1
- package/dist/collection/components/mailbox/nylas-composer/nylas-composer.js +1 -1
- package/dist/collection/components/mailbox/nylas-list-folders/nylas-list-folders.js +1 -1
- package/dist/collection/components/mailbox/nylas-list-threads/nylas-list-threads.js +1 -1
- package/dist/collection/components/mailbox/nylas-mailbox/nylas-mailbox.js +1 -1
- package/dist/collection/components/mailbox/nylas-mailbox-toolbar-button/nylas-mailbox-toolbar-button.js +1 -1
- package/dist/collection/components/mailbox/nylas-summarize-message-button/nylas-summarize-message-button.js +2 -2
- package/dist/collection/components/mailbox/nylas-threads-refresh/nylas-threads-refresh.js +2 -2
- package/dist/collection/components/mailbox/nylas-threads-search/nylas-threads-search.js +1 -1
- package/dist/collection/components/mailbox/nylas-view-email/nylas-view-email.js +1 -1
- package/dist/collection/components/mailbox/nylas-view-thread/nylas-view-thread.js +1 -1
- package/dist/collection/components/nylas-if-state/nylas-if-state.js +1 -1
- package/dist/collection/components/nylas-login/nylas-login.js +1 -1
- package/dist/collection/components/nylas-provider/nylas-provider.js +1 -1
- package/dist/collection/components/scheduler/nylas-booked-event-card/nylas-booked-event-card.js +23 -4
- package/dist/collection/components/scheduler/nylas-booked-event-card/nylas-booked-event-card.js.map +1 -1
- package/dist/collection/components/scheduler/nylas-booked-event-card/test/nylas-booked-event-card.spec.js +1 -0
- package/dist/collection/components/scheduler/nylas-booked-event-card/test/nylas-booked-event-card.spec.js.map +1 -1
- package/dist/collection/components/scheduler/nylas-booking-form/nylas-booking-form.js +37 -21
- package/dist/collection/components/scheduler/nylas-booking-form/nylas-booking-form.js.map +1 -1
- package/dist/collection/components/scheduler/nylas-cancel-booking-form/nylas-cancel-booking-form.js +42 -3
- package/dist/collection/components/scheduler/nylas-cancel-booking-form/nylas-cancel-booking-form.js.map +1 -1
- package/dist/collection/components/scheduler/nylas-cancel-booking-form/test/nylas-cancel-booking-form.spec.js +11 -0
- package/dist/collection/components/scheduler/nylas-cancel-booking-form/test/nylas-cancel-booking-form.spec.js.map +1 -1
- package/dist/collection/components/scheduler/nylas-cancelled-event-card/nylas-cancelled-event-card.js +2 -2
- package/dist/collection/components/scheduler/nylas-date-picker/nylas-date-picker.js +1 -1
- package/dist/collection/components/scheduler/nylas-notification/nylas-notification.js +1 -1
- package/dist/collection/components/scheduler/nylas-scheduling/nylas-scheduling.css +4 -1
- package/dist/collection/components/scheduler/nylas-scheduling/nylas-scheduling.js +3 -3
- package/dist/collection/components/scheduler/nylas-scheduling/nylas-scheduling.js.map +1 -1
- package/dist/collection/components/scheduler/nylas-selected-event-card/nylas-selected-event-card.js +1 -1
- package/dist/collection/components/scheduler/nylas-timeslot-picker/nylas-timeslot-picker.css +2 -2
- package/dist/collection/components/scheduler/nylas-timeslot-picker/nylas-timeslot-picker.js +8 -7
- package/dist/collection/components/scheduler/nylas-timeslot-picker/nylas-timeslot-picker.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-additional-participants/nylas-additional-participants.css +16 -2
- package/dist/collection/components/scheduler-editor/nylas-additional-participants/nylas-additional-participants.js +31 -12
- package/dist/collection/components/scheduler-editor/nylas-additional-participants/nylas-additional-participants.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-availability-picker/nylas-availability-picker.css +3 -0
- package/dist/collection/components/scheduler-editor/nylas-availability-picker/nylas-availability-picker.js +2 -2
- package/dist/collection/components/scheduler-editor/nylas-availability-picker/nylas-availability-picker.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-booking-calendar-picker/nylas-booking-calendar-picker.css +3 -0
- package/dist/collection/components/scheduler-editor/nylas-booking-calendar-picker/nylas-booking-calendar-picker.js +22 -6
- package/dist/collection/components/scheduler-editor/nylas-booking-calendar-picker/nylas-booking-calendar-picker.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-booking-form-config/nylas-booking-form-config.css +233 -0
- package/dist/collection/components/scheduler-editor/nylas-booking-form-config/nylas-booking-form-config.js +388 -0
- package/dist/collection/components/scheduler-editor/nylas-booking-form-config/nylas-booking-form-config.js.map +1 -0
- package/dist/collection/components/scheduler-editor/nylas-calendar-picker/nylas-calendar-picker.css +3 -20
- package/dist/collection/components/scheduler-editor/nylas-calendar-picker/nylas-calendar-picker.js +19 -9
- package/dist/collection/components/scheduler-editor/nylas-calendar-picker/nylas-calendar-picker.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-cancellation-policy/nylas-cancellation-policy.js +1 -1
- package/dist/collection/components/scheduler-editor/nylas-connected-calendars/nylas-connected-calendars.css +105 -0
- package/dist/collection/components/scheduler-editor/nylas-connected-calendars/nylas-connected-calendars.js +298 -0
- package/dist/collection/components/scheduler-editor/nylas-connected-calendars/nylas-connected-calendars.js.map +1 -0
- package/dist/collection/components/scheduler-editor/nylas-custom-booking-flow/nylas-custom-booking-flow.js +1 -1
- package/dist/collection/components/scheduler-editor/nylas-customize-booking-settings/nylas-customize-booking-settings.js +5 -5
- package/dist/collection/components/scheduler-editor/nylas-customize-booking-settings/nylas-customize-booking-settings.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-editor-tabs/nylas-editor-tabs.css +3 -0
- package/dist/collection/components/scheduler-editor/nylas-editor-tabs/nylas-editor-tabs.js +106 -20
- package/dist/collection/components/scheduler-editor/nylas-editor-tabs/nylas-editor-tabs.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-editor-tabs/tab-contents.js +7 -7
- package/dist/collection/components/scheduler-editor/nylas-editor-tabs/tab-contents.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-event-info/nylas-event-info.js +1 -1
- package/dist/collection/components/scheduler-editor/nylas-event-limits/nylas-event-limits.js +1 -1
- package/dist/collection/components/scheduler-editor/nylas-event-limits/nylas-event-limits.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-event-location/nylas-event-location.js +161 -11
- package/dist/collection/components/scheduler-editor/nylas-event-location/nylas-event-location.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-event-title/nylas-event-title.js +1 -1
- package/dist/collection/components/scheduler-editor/nylas-event-title/nylas-event-title.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-form-card/nylas-form-card.js +1 -1
- package/dist/collection/components/scheduler-editor/nylas-limit-future-bookings/nylas-limit-future-bookings.js +1 -1
- package/dist/collection/components/scheduler-editor/nylas-limit-future-bookings/nylas-limit-future-bookings.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-list-configurations/nylas-list-configurations.css +79 -3
- package/dist/collection/components/scheduler-editor/nylas-list-configurations/nylas-list-configurations.js +125 -22
- package/dist/collection/components/scheduler-editor/nylas-list-configurations/nylas-list-configurations.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-min-booking-notice/nylas-min-booking-notice.js +1 -1
- package/dist/collection/components/scheduler-editor/nylas-min-booking-notice/nylas-min-booking-notice.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-min-cancellation-notice/nylas-min-cancellation-notice.js +1 -1
- package/dist/collection/components/scheduler-editor/nylas-min-cancellation-notice/nylas-min-cancellation-notice.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-participant-booking-calendars/nylas-participant-booking-calendars.css +105 -0
- package/dist/collection/components/scheduler-editor/nylas-participant-booking-calendars/nylas-participant-booking-calendars.js +324 -0
- package/dist/collection/components/scheduler-editor/nylas-participant-booking-calendars/nylas-participant-booking-calendars.js.map +1 -0
- package/dist/collection/components/scheduler-editor/nylas-participants-custom-availability/nylas-participants-custom-availability.js +39 -5
- package/dist/collection/components/scheduler-editor/nylas-participants-custom-availability/nylas-participants-custom-availability.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-scheduler-editor/ExpressFlow.js +4 -3
- package/dist/collection/components/scheduler-editor/nylas-scheduler-editor/ExpressFlow.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-scheduler-editor/nylas-scheduler-editor.js +59 -9
- package/dist/collection/components/scheduler-editor/nylas-scheduler-editor/nylas-scheduler-editor.js.map +1 -1
- package/dist/collection/components/scheduler-editor/nylas-time-window-picker/nylas-time-window-picker.js +1 -1
- package/dist/collection/components/scheduler-editor/nylas-timeslot-interval/nylas-timeslot-interval.js +16 -16
- package/dist/collection/components/scheduler-editor/nylas-timeslot-interval/nylas-timeslot-interval.js.map +1 -1
- package/dist/collection/connector/shared/api/scheduler-config.js +4 -2
- package/dist/collection/connector/shared/api/scheduler-config.js.map +1 -1
- package/dist/collection/connector/shared/api/scheduler.js +41 -6
- package/dist/collection/connector/shared/api/scheduler.js.map +1 -1
- package/dist/collection/stores/scheduler-config-store.js +2 -0
- package/dist/collection/stores/scheduler-config-store.js.map +1 -1
- package/dist/collection/stores/scheduler-store.js +1 -0
- package/dist/collection/stores/scheduler-store.js.map +1 -1
- package/dist/collection/types/index.js.map +1 -1
- package/dist/components/add-circle.js +1 -1
- package/dist/components/archive.js +1 -1
- package/dist/components/arrow.js +1 -1
- package/dist/components/bold.js +1 -1
- package/dist/components/button-component2.js +2 -2
- package/dist/components/button-component2.js.map +1 -1
- package/dist/components/calendar-agenda-fill-icon.d.ts +11 -0
- package/dist/components/calendar-agenda-fill-icon.js +8 -0
- package/dist/components/calendar-agenda-fill-icon.js.map +1 -0
- package/dist/components/calendar-agenda-fill.js +37 -0
- package/dist/components/calendar-agenda-fill.js.map +1 -0
- package/dist/components/calendar-agenda-icon.d.ts +11 -0
- package/dist/components/calendar-agenda-icon.js +8 -0
- package/dist/components/calendar-agenda-icon.js.map +1 -0
- package/dist/components/calendar-agenda.js +37 -0
- package/dist/components/calendar-agenda.js.map +1 -0
- package/dist/components/checkbox-component2.js +18 -4
- package/dist/components/checkbox-component2.js.map +1 -1
- package/dist/components/constants.js +102 -1
- package/dist/components/constants.js.map +1 -1
- package/dist/components/copy-icon.d.ts +11 -0
- package/dist/components/copy-icon.js +8 -0
- package/dist/components/copy-icon.js.map +1 -0
- package/dist/components/copy.js +37 -0
- package/dist/components/copy.js.map +1 -0
- package/dist/components/delete-icon.d.ts +11 -0
- package/dist/components/delete-icon.js +8 -0
- package/dist/components/delete-icon.js.map +1 -0
- package/dist/components/delete.js +37 -0
- package/dist/components/delete.js.map +1 -0
- package/dist/components/document-refresh-icon.js +1 -1
- package/dist/components/dragable-icon.d.ts +11 -0
- package/dist/components/dragable-icon.js +8 -0
- package/dist/components/dragable-icon.js.map +1 -0
- package/dist/components/dragable.js +37 -0
- package/dist/components/dragable.js.map +1 -0
- package/dist/components/edit-icon.d.ts +11 -0
- package/dist/components/edit-icon.js +8 -0
- package/dist/components/edit-icon.js.map +1 -0
- package/dist/components/edit.js +37 -0
- package/dist/components/edit.js.map +1 -0
- package/dist/components/eye-icon.d.ts +11 -0
- package/dist/components/eye-icon.js +8 -0
- package/dist/components/eye-icon.js.map +1 -0
- package/dist/components/eye.js +37 -0
- package/dist/components/eye.js.map +1 -0
- package/dist/components/flow.js +1 -1
- package/dist/components/folder.js +1 -1
- package/dist/components/forward.js +1 -1
- package/dist/components/globe.js +1 -1
- package/dist/components/google-logo.js +1 -1
- package/dist/components/google-meet-icon.d.ts +11 -0
- package/dist/components/google-meet-icon.js +8 -0
- package/dist/components/google-meet-icon.js.map +1 -0
- package/dist/components/google-meet.js +37 -0
- package/dist/components/google-meet.js.map +1 -0
- package/dist/components/inbox.js +1 -1
- package/dist/components/info.js +1 -1
- package/dist/components/input-component2.js +17 -6
- package/dist/components/input-component2.js.map +1 -1
- package/dist/components/input-dropdown2.js +1 -1
- package/dist/components/italic.js +1 -1
- package/dist/components/loading.js +1 -1
- package/dist/components/location-off.js +1 -1
- package/dist/components/location.js +1 -1
- package/dist/components/microsof-teams.js +37 -0
- package/dist/components/microsof-teams.js.map +1 -0
- package/dist/components/microsoft-logo.js +1 -1
- package/dist/components/microsoft-teams-icon.d.ts +11 -0
- package/dist/components/microsoft-teams-icon.js +8 -0
- package/dist/components/microsoft-teams-icon.js.map +1 -0
- package/dist/components/multi-select-dropdown2.js +5 -3
- package/dist/components/multi-select-dropdown2.js.map +1 -1
- package/dist/components/nylas-additional-participants2.js +26 -8
- package/dist/components/nylas-additional-participants2.js.map +1 -1
- package/dist/components/nylas-api-request.js +1 -0
- package/dist/components/nylas-api-request.js.map +1 -1
- package/dist/components/nylas-availability-picker2.js +2 -2
- package/dist/components/nylas-availability-picker2.js.map +1 -1
- package/dist/components/nylas-booked-event-card2.js +7 -4
- package/dist/components/nylas-booked-event-card2.js.map +1 -1
- package/dist/components/nylas-booking-calendar-picker2.js +5 -6
- package/dist/components/nylas-booking-calendar-picker2.js.map +1 -1
- package/dist/components/nylas-booking-form-config.d.ts +11 -0
- package/dist/components/nylas-booking-form-config.js +8 -0
- package/dist/components/nylas-booking-form-config.js.map +1 -0
- package/dist/components/nylas-booking-form-config2.js +3691 -0
- package/dist/components/nylas-booking-form-config2.js.map +1 -0
- package/dist/components/nylas-booking-form2.js +78 -32
- package/dist/components/nylas-booking-form2.js.map +1 -1
- package/dist/components/nylas-calendar-picker2.js +27 -23
- package/dist/components/nylas-calendar-picker2.js.map +1 -1
- package/dist/components/nylas-cancel-booking-form2.js +21 -2
- package/dist/components/nylas-cancel-booking-form2.js.map +1 -1
- package/dist/components/nylas-cancellation-policy2.js +1 -1
- package/dist/components/nylas-cancelled-event-card2.js +1 -1
- package/dist/components/nylas-composer2.js +1 -1
- package/dist/components/nylas-connected-calendars.d.ts +11 -0
- package/dist/components/nylas-connected-calendars.js +8 -0
- package/dist/components/nylas-connected-calendars.js.map +1 -0
- package/dist/components/nylas-connected-calendars2.js +232 -0
- package/dist/components/nylas-connected-calendars2.js.map +1 -0
- package/dist/components/nylas-custom-booking-flow.js +1 -1
- package/dist/components/nylas-customize-booking-settings2.js +4 -4
- package/dist/components/nylas-customize-booking-settings2.js.map +1 -1
- package/dist/components/nylas-editor-tabs2.js +251 -113
- package/dist/components/nylas-editor-tabs2.js.map +1 -1
- package/dist/components/nylas-event-info2.js +1 -1
- package/dist/components/nylas-event-limits2.js +1 -1
- package/dist/components/nylas-event-limits2.js.map +1 -1
- package/dist/components/nylas-event-location2.js +138 -25
- package/dist/components/nylas-event-location2.js.map +1 -1
- package/dist/components/nylas-event-title2.js +1 -1
- package/dist/components/nylas-event-title2.js.map +1 -1
- package/dist/components/nylas-form-card2.js +1 -1
- package/dist/components/nylas-if-state.js +1 -1
- package/dist/components/nylas-limit-future-bookings2.js +1 -1
- package/dist/components/nylas-limit-future-bookings2.js.map +1 -1
- package/dist/components/nylas-list-configurations2.js +142 -25
- package/dist/components/nylas-list-configurations2.js.map +1 -1
- package/dist/components/nylas-list-folders.js +1 -1
- package/dist/components/nylas-list-threads.js +1 -1
- package/dist/components/nylas-login.js +1 -1
- package/dist/components/nylas-logo2.js +1 -1
- package/dist/components/nylas-mailbox-toolbar-button.js +1 -1
- package/dist/components/nylas-mailbox.js +1 -1
- package/dist/components/nylas-min-booking-notice2.js +1 -1
- package/dist/components/nylas-min-booking-notice2.js.map +1 -1
- package/dist/components/nylas-min-cancellation-notice2.js +1 -1
- package/dist/components/nylas-min-cancellation-notice2.js.map +1 -1
- package/dist/components/nylas-notification2.js +1 -1
- package/dist/components/nylas-participant-booking-calendars.d.ts +11 -0
- package/dist/components/nylas-participant-booking-calendars.js +8 -0
- package/dist/components/nylas-participant-booking-calendars.js.map +1 -0
- package/dist/components/nylas-participant-booking-calendars2.js +237 -0
- package/dist/components/nylas-participant-booking-calendars2.js.map +1 -0
- package/dist/components/nylas-participants-custom-availability2.js +18 -5
- package/dist/components/nylas-participants-custom-availability2.js.map +1 -1
- package/dist/components/nylas-provider.js +1 -1
- package/dist/components/nylas-scheduler-editor.js +210 -101
- package/dist/components/nylas-scheduler-editor.js.map +1 -1
- package/dist/components/nylas-scheduling.js +70 -52
- package/dist/components/nylas-scheduling.js.map +1 -1
- package/dist/components/nylas-summarize-message-button2.js +2 -2
- package/dist/components/nylas-threads-refresh.js +2 -2
- package/dist/components/nylas-threads-search.js +1 -1
- package/dist/components/nylas-time-window-picker2.js +1 -1
- package/dist/components/nylas-timeslot-interval2.js +11 -11
- package/dist/components/nylas-timeslot-interval2.js.map +1 -1
- package/dist/components/nylas-timeslot-picker2.js +6 -5
- package/dist/components/nylas-timeslot-picker2.js.map +1 -1
- package/dist/components/nylas-view-email2.js +1 -1
- package/dist/components/nylas-view-thread.js +1 -1
- package/dist/components/people.js +1 -1
- package/dist/components/person.js +1 -1
- package/dist/components/play.js +1 -1
- package/dist/components/plus-icon.d.ts +11 -0
- package/dist/components/plus-icon.js +8 -0
- package/dist/components/plus-icon.js.map +1 -0
- package/dist/components/plus.js +37 -0
- package/dist/components/plus.js.map +1 -0
- package/dist/components/radio-button-group2.js +23 -6
- package/dist/components/radio-button-group2.js.map +1 -1
- package/dist/components/refresh.js +1 -1
- package/dist/components/reply-all.js +1 -1
- package/dist/components/reply.js +1 -1
- package/dist/components/scheduler-config-store.js +2 -0
- package/dist/components/scheduler-config-store.js.map +1 -1
- package/dist/components/scheduler-store.js +42 -6
- package/dist/components/scheduler-store.js.map +1 -1
- package/dist/components/search.js +1 -1
- package/dist/components/select-dropdown2.js +12 -2
- package/dist/components/select-dropdown2.js.map +1 -1
- package/dist/components/sent.js +1 -1
- package/dist/components/spam.js +1 -1
- package/dist/components/star.js +1 -1
- package/dist/components/stop.js +1 -1
- package/dist/components/textarea-component.js +1 -82
- package/dist/components/textarea-component.js.map +1 -1
- package/dist/components/textarea-component2.js +89 -0
- package/dist/components/textarea-component2.js.map +1 -0
- package/dist/components/time-period-selector2.js +1 -1
- package/dist/components/toggle-switch2.js +2 -2
- package/dist/components/toggle-switch2.js.map +1 -1
- package/dist/components/toolitp-component.js +1 -1
- package/dist/components/translate.js +1 -1
- package/dist/components/trash.js +1 -1
- package/dist/components/underline.js +1 -1
- package/dist/components/warning.js +1 -1
- package/dist/components/zoom-icon.d.ts +11 -0
- package/dist/components/zoom-icon.js +8 -0
- package/dist/components/zoom-icon.js.map +1 -0
- package/dist/components/zoom.js +37 -0
- package/dist/components/zoom.js.map +1 -0
- package/dist/esm/add-circle-icon_2.entry.js +1 -1
- package/dist/esm/archive-icon_7.entry.js +7 -7
- package/dist/esm/arrow-icon.entry.js +1 -1
- package/dist/esm/bold-icon_3.entry.js +3 -3
- package/dist/esm/button-component_4.entry.js +196 -0
- package/dist/esm/button-component_4.entry.js.map +1 -0
- package/dist/esm/calendar-agenda-fill-icon_35.entry.js +6905 -0
- package/dist/esm/calendar-agenda-fill-icon_35.entry.js.map +1 -0
- package/dist/esm/chevron-icon_3.entry.js +11 -3
- package/dist/esm/chevron-icon_3.entry.js.map +1 -1
- package/dist/esm/clock-icon_2.entry.js +1 -1
- package/dist/esm/{constants-f34b9c6e.js → constants-7ce66b44.js} +103 -2
- package/dist/esm/{constants-f34b9c6e.js.map → constants-7ce66b44.js.map} +1 -1
- package/dist/esm/copy-icon_4.entry.js +65 -0
- package/dist/esm/copy-icon_4.entry.js.map +1 -0
- package/dist/esm/document-refresh-icon.entry.js +1 -1
- package/dist/esm/forward-icon_6.entry.js +7 -7
- package/dist/esm/globe-icon.entry.js +1 -1
- package/dist/esm/google-logo-icon_4.entry.js +192 -51
- package/dist/esm/google-logo-icon_4.entry.js.map +1 -1
- package/dist/esm/index-7cb0dd3d.js +20 -16
- package/dist/esm/index.js +1 -1
- package/dist/esm/info-icon_2.entry.js +2 -2
- package/dist/esm/input-dropdown_2.entry.js +2 -2
- package/dist/esm/loader.js +1 -1
- package/dist/esm/loading-icon.entry.js +1 -1
- package/dist/esm/multi-select-dropdown.entry.js +140 -0
- package/dist/esm/multi-select-dropdown.entry.js.map +1 -0
- package/dist/esm/{nylas-api-request-a67d2997.js → nylas-api-request-4f8edff2.js} +2 -1
- package/dist/esm/nylas-api-request-4f8edff2.js.map +1 -0
- package/dist/esm/nylas-booked-event-card_10.entry.js +66 -35
- package/dist/esm/nylas-booked-event-card_10.entry.js.map +1 -1
- package/dist/esm/nylas-custom-booking-flow.entry.js +1 -1
- package/dist/esm/nylas-form-card.entry.js +1 -1
- package/dist/esm/nylas-if-state.entry.js +1 -1
- package/dist/esm/nylas-list-folders.entry.js +1 -1
- package/dist/esm/nylas-list-threads.entry.js +1 -1
- package/dist/esm/nylas-login.entry.js +1 -1
- package/dist/esm/nylas-mailbox-toolbar-button.entry.js +1 -1
- package/dist/esm/nylas-mailbox.entry.js +1 -1
- package/dist/esm/nylas-provider.entry.js +3 -3
- package/dist/esm/nylas-scheduler-editor.entry.js +26 -9
- package/dist/esm/nylas-scheduler-editor.entry.js.map +1 -1
- package/dist/esm/nylas-scheduling.entry.js +3 -3
- package/dist/esm/nylas-scheduling.entry.js.map +1 -1
- package/dist/esm/nylas-threads-refresh.entry.js +2 -2
- package/dist/esm/nylas-threads-search.entry.js +1 -1
- package/dist/esm/nylas-time-window-picker.entry.js +1 -1
- package/dist/esm/nylas-view-thread.entry.js +1 -1
- package/dist/esm/nylas-web-elements.js +1 -1
- package/dist/esm/play-icon_2.entry.js +2 -2
- package/dist/esm/refresh-icon.entry.js +1 -1
- package/dist/esm/{scheduler-config-store-4a50a03d.js → scheduler-config-store-9ccfba4d.js} +3 -1
- package/dist/esm/scheduler-config-store-9ccfba4d.js.map +1 -0
- package/dist/esm/{scheduler-store-f02ce045.js → scheduler-store-8a400448.js} +43 -7
- package/dist/esm/scheduler-store-8a400448.js.map +1 -0
- package/dist/esm/textarea-component.entry.js +3 -1
- package/dist/esm/textarea-component.entry.js.map +1 -1
- package/dist/esm/translate-icon.entry.js +1 -1
- package/dist/esm/warning-icon.entry.js +1 -1
- package/dist/nylas-web-elements/index.esm.js +1 -1
- package/dist/nylas-web-elements/nylas-web-elements.esm.js +1 -1
- package/dist/nylas-web-elements/nylas-web-elements.esm.js.map +1 -1
- package/dist/nylas-web-elements/p-0161429f.entry.js +2 -0
- package/dist/nylas-web-elements/{p-33a6a75b.entry.js.map → p-0161429f.entry.js.map} +1 -1
- package/dist/nylas-web-elements/p-064c2ae5.entry.js +2 -0
- package/dist/nylas-web-elements/{p-de7b0878.entry.js → p-0aa1e433.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-3f122804.entry.js → p-0bf6f818.entry.js} +2 -2
- package/dist/nylas-web-elements/p-1102df14.entry.js +2 -0
- package/dist/nylas-web-elements/{p-f1a54acf.entry.js → p-155e5ce8.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-a85408e0.entry.js → p-18d100c8.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-5231fc13.entry.js → p-1a7edf86.entry.js} +3 -3
- package/dist/nylas-web-elements/p-1d8c468f.entry.js +2 -0
- package/dist/nylas-web-elements/p-1d8c468f.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-be38a8eb.entry.js → p-1e1ae8d0.entry.js} +2 -2
- package/dist/nylas-web-elements/p-1f290858.entry.js +2 -0
- package/dist/nylas-web-elements/p-1f290858.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-eb7e8455.entry.js → p-1fbe50b1.entry.js} +2 -2
- package/dist/nylas-web-elements/p-20bbc663.js +2 -0
- package/dist/nylas-web-elements/p-20bbc663.js.map +1 -0
- package/dist/nylas-web-elements/{p-49f716ed.js → p-2270e6cf.js} +4 -4
- package/dist/nylas-web-elements/p-2270e6cf.js.map +1 -0
- package/dist/nylas-web-elements/{p-70e5cfb0.entry.js → p-22e05c7d.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-554891cd.entry.js → p-26302ad0.entry.js} +2 -2
- package/dist/nylas-web-elements/p-27df8f01.entry.js +2 -0
- package/dist/nylas-web-elements/p-27df8f01.entry.js.map +1 -0
- package/dist/nylas-web-elements/p-2b1d53fa.entry.js +8 -0
- package/dist/nylas-web-elements/p-2b1d53fa.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-6ce66add.entry.js → p-2f47205d.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-28512ab6.entry.js → p-3277023d.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-1a27960b.entry.js → p-3423de64.entry.js} +2 -2
- package/dist/nylas-web-elements/p-3423de64.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-b0c8021f.entry.js → p-34c747f9.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-d9a91bc9.entry.js → p-359af1e3.entry.js} +2 -2
- package/dist/nylas-web-elements/p-359af1e3.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-613c070f.js → p-371b20b2.js} +2 -2
- package/dist/nylas-web-elements/p-371b20b2.js.map +1 -0
- package/dist/nylas-web-elements/{p-e9ba368f.entry.js → p-3ae38e51.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-6ef1024f.entry.js → p-3bc1289e.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-7fcecf3f.entry.js → p-3d1e8e4d.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-45c37986.entry.js → p-3dae0c71.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-acadfabf.entry.js → p-3db7ab8d.entry.js} +3 -3
- package/dist/nylas-web-elements/{p-66493463.entry.js → p-3e09b0fb.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-5c3c1888.entry.js → p-3eac9f45.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-dcc27b67.entry.js → p-4000107d.entry.js} +2 -2
- package/dist/nylas-web-elements/p-40cad9a8.entry.js +11 -0
- package/dist/nylas-web-elements/p-40cad9a8.entry.js.map +1 -0
- package/dist/nylas-web-elements/p-445d8bb4.entry.js +11 -0
- package/dist/nylas-web-elements/p-445d8bb4.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-08d75d35.entry.js → p-47392968.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-16a3bfb2.entry.js → p-4a594ebe.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-d633e735.entry.js → p-4b6995fe.entry.js} +2 -2
- package/dist/nylas-web-elements/p-4cdd4107.entry.js +2 -0
- package/dist/nylas-web-elements/{p-39fd9c90.entry.js → p-4e8c8939.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-9b68568e.entry.js → p-4e9ba325.entry.js} +2 -2
- package/dist/nylas-web-elements/p-4f55d0e5.entry.js +2 -0
- package/dist/nylas-web-elements/{p-12b83ea9.entry.js.map → p-4f55d0e5.entry.js.map} +1 -1
- package/dist/nylas-web-elements/{p-9794f735.entry.js → p-524a6acc.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-6bd9c9c3.entry.js → p-533d39ce.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-e928898a.entry.js → p-5a379fb5.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-c90755ba.entry.js → p-5a68368a.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-37f41a90.entry.js → p-5b965d0d.entry.js} +2 -2
- package/dist/nylas-web-elements/p-5e1cd3c1.entry.js +2 -0
- package/dist/nylas-web-elements/p-5e1cd3c1.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-34f0d1fe.entry.js → p-5ff4e63b.entry.js} +2 -2
- package/dist/nylas-web-elements/p-62aeac5f.entry.js +2 -0
- package/dist/nylas-web-elements/p-62aeac5f.entry.js.map +1 -0
- package/dist/nylas-web-elements/p-64d43339.entry.js +2 -0
- package/dist/nylas-web-elements/p-64d43339.entry.js.map +1 -0
- package/dist/nylas-web-elements/p-656cf33f.entry.js +2 -0
- package/dist/nylas-web-elements/{p-cf589eab.entry.js → p-65b7a2a7.entry.js} +2 -2
- package/dist/nylas-web-elements/p-68471dbd.entry.js +8 -0
- package/dist/nylas-web-elements/p-68471dbd.entry.js.map +1 -0
- package/dist/nylas-web-elements/p-692852d2.entry.js +2 -0
- package/dist/nylas-web-elements/p-692852d2.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-60b03f86.entry.js → p-6c8af4fb.entry.js} +2 -2
- package/dist/nylas-web-elements/p-6d410f0a.entry.js +2 -0
- package/dist/nylas-web-elements/{p-daac96cb.entry.js → p-6e50d2fd.entry.js} +3 -3
- package/dist/nylas-web-elements/p-6e8b7ce8.entry.js +2 -0
- package/dist/nylas-web-elements/p-7042eb03.entry.js +2 -0
- package/dist/nylas-web-elements/{p-958746a1.entry.js.map → p-7042eb03.entry.js.map} +1 -1
- package/dist/nylas-web-elements/{p-b9fa6848.entry.js → p-7355937b.entry.js} +2 -2
- package/dist/nylas-web-elements/p-749238c6.entry.js +2 -0
- package/dist/nylas-web-elements/p-749238c6.entry.js.map +1 -0
- package/dist/nylas-web-elements/p-76156a82.entry.js +2 -0
- package/dist/nylas-web-elements/p-79c1475e.entry.js +11 -0
- package/dist/nylas-web-elements/p-79c1475e.entry.js.map +1 -0
- package/dist/nylas-web-elements/p-79c33cf9.entry.js +2 -0
- package/dist/nylas-web-elements/p-79c33cf9.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-052bc3b1.entry.js → p-7e08f131.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-a12f3223.entry.js → p-7e10aa6d.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-a7b19349.entry.js → p-7e53588e.entry.js} +2 -2
- package/dist/nylas-web-elements/p-83de54ae.entry.js +2 -0
- package/dist/nylas-web-elements/{p-b2d95965.entry.js → p-884b66bd.entry.js} +2 -2
- package/dist/nylas-web-elements/p-8aac762b.entry.js +2 -0
- package/dist/nylas-web-elements/p-8aac762b.entry.js.map +1 -0
- package/dist/nylas-web-elements/p-8d74c874.js +2 -0
- package/dist/nylas-web-elements/p-8d74c874.js.map +1 -0
- package/dist/nylas-web-elements/{p-a800e7af.entry.js → p-8ddf6518.entry.js} +2 -2
- package/dist/nylas-web-elements/p-8ddf6518.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-7a95bc3f.entry.js → p-90294a76.entry.js} +2 -2
- package/dist/nylas-web-elements/p-90817d1f.entry.js +2 -0
- package/dist/nylas-web-elements/{p-f1b0120b.entry.js → p-90d32fc3.entry.js} +2 -2
- package/dist/nylas-web-elements/p-94a93ca9.entry.js +2 -0
- package/dist/nylas-web-elements/p-94a93ca9.entry.js.map +1 -0
- package/dist/nylas-web-elements/p-95a9d2f1.entry.js +2 -0
- package/dist/nylas-web-elements/p-96746b87.entry.js +2 -0
- package/dist/nylas-web-elements/p-97026709.entry.js +2 -0
- package/dist/nylas-web-elements/{p-65097f45.entry.js → p-987042a1.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-7ce048c0.entry.js → p-9f903292.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-bd34f97d.entry.js → p-9fdbeba5.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-2a92691a.entry.js → p-a22908ba.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-091a8f00.entry.js → p-a3c76c06.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-520ffe94.entry.js → p-a63d6241.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-cf0d5ab9.entry.js → p-aa4e6e5e.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-ba5a625c.entry.js → p-ab050d5b.entry.js} +2 -2
- package/dist/nylas-web-elements/p-b2b2d351.entry.js +2 -0
- package/dist/nylas-web-elements/p-b2b2d351.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-161c9325.entry.js → p-b348aad4.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-bfe8e06b.entry.js → p-b547209f.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-e8cde784.entry.js → p-b5b051e0.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-aae7febd.entry.js → p-b7a53268.entry.js} +2 -2
- package/dist/nylas-web-elements/p-b8a9e8f4.entry.js +2 -0
- package/dist/nylas-web-elements/p-b8a9e8f4.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-385070ba.entry.js → p-bc6c9256.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-cb03e4d4.entry.js → p-be26ce19.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-8a4ac2a4.entry.js → p-bed6d217.entry.js} +2 -2
- package/dist/nylas-web-elements/p-bf4e0d2a.entry.js +2 -0
- package/dist/nylas-web-elements/p-bf4e0d2a.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-8e63b66c.entry.js → p-cb9fd100.entry.js} +2 -2
- package/dist/nylas-web-elements/p-ce14a1d5.entry.js +2 -0
- package/dist/nylas-web-elements/{p-1fa7b832.entry.js.map → p-ce14a1d5.entry.js.map} +1 -1
- package/dist/nylas-web-elements/{p-44507695.entry.js → p-cee0929a.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-b334d63b.entry.js → p-cffb3636.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-b2aca6c4.entry.js → p-d1ab9d75.entry.js} +2 -2
- package/dist/nylas-web-elements/p-d6a19e25.entry.js +2 -0
- package/dist/nylas-web-elements/p-d6a19e25.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-f96b12de.entry.js → p-d830e428.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-8075a758.entry.js → p-d9b08dd2.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-8f843faf.entry.js → p-db73506b.entry.js} +2 -2
- package/dist/nylas-web-elements/p-dcf99ddf.entry.js +2 -0
- package/dist/nylas-web-elements/p-dcf99ddf.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-d513d2ee.entry.js → p-de2f4643.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-f2d1b1a6.entry.js.map → p-de2f4643.entry.js.map} +1 -1
- package/dist/nylas-web-elements/{p-25c97a60.entry.js → p-de84d999.entry.js} +2 -2
- package/dist/nylas-web-elements/p-debf614f.entry.js +8 -0
- package/dist/nylas-web-elements/p-debf614f.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-158fe1e9.entry.js → p-dfe9b5d0.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-085950eb.entry.js → p-e5452799.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-f8653b9b.entry.js → p-e6e79d76.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-b813eb5d.entry.js → p-e944aa75.entry.js} +2 -2
- package/dist/nylas-web-elements/p-ec844414.entry.js +2 -0
- package/dist/nylas-web-elements/{p-34f0d1fe.entry.js.map → p-ec844414.entry.js.map} +1 -1
- package/dist/nylas-web-elements/p-ed64716c.entry.js +2 -0
- package/dist/nylas-web-elements/p-ed64716c.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-ecaf3ae1.entry.js → p-eff175d3.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-246983ed.entry.js → p-eff774e6.entry.js} +2 -2
- package/dist/nylas-web-elements/p-f03b9d40.entry.js +2 -0
- package/dist/nylas-web-elements/p-f03b9d40.entry.js.map +1 -0
- package/dist/nylas-web-elements/{p-2f148064.entry.js → p-f13b8bd3.entry.js} +2 -2
- package/dist/nylas-web-elements/{p-8f3b02cd.entry.js → p-f7465959.entry.js} +2 -2
- package/dist/nylas-web-elements/p-f8e8270d.entry.js +2 -0
- package/dist/nylas-web-elements/p-f8e8270d.entry.js.map +1 -0
- package/dist/types/common/constants.d.ts +17 -0
- package/dist/types/common/icons/calendar-agenda-fill.d.ts +5 -0
- package/dist/types/common/icons/calendar-agenda.d.ts +5 -0
- package/dist/types/common/icons/copy.d.ts +5 -0
- package/dist/types/common/icons/delete.d.ts +5 -0
- package/dist/types/common/icons/dragable.d.ts +5 -0
- package/dist/types/common/icons/edit.d.ts +5 -0
- package/dist/types/common/icons/eye.d.ts +5 -0
- package/dist/types/common/icons/google-meet.d.ts +5 -0
- package/dist/types/common/icons/microsof-teams.d.ts +5 -0
- package/dist/types/common/icons/plus.d.ts +5 -0
- package/dist/types/common/icons/zoom.d.ts +5 -0
- package/dist/types/common/nylas-api-request.d.ts +1 -0
- package/dist/types/common/types.d.ts +1 -0
- package/dist/types/components/design-system/checkbox-component/checkbox-component.d.ts +3 -0
- package/dist/types/components/design-system/input-component/input-component.d.ts +2 -1
- package/dist/types/components/design-system/multi-select-dropdown/multi-select-dropdown.d.ts +1 -0
- package/dist/types/components/design-system/radio-button-group/radio-button-group.d.ts +6 -1
- package/dist/types/components/design-system/select-dropdown/select-dropdown.d.ts +3 -0
- package/dist/types/components/design-system/textarea-component/textarea-component.d.ts +2 -0
- package/dist/types/components/scheduler/nylas-booked-event-card/nylas-booked-event-card.d.ts +1 -0
- package/dist/types/components/scheduler/nylas-booking-form/nylas-booking-form.d.ts +8 -6
- package/dist/types/components/scheduler/nylas-cancel-booking-form/nylas-cancel-booking-form.d.ts +3 -2
- package/dist/types/components/scheduler-editor/nylas-additional-participants/nylas-additional-participants.d.ts +7 -4
- package/dist/types/components/scheduler-editor/nylas-booking-calendar-picker/nylas-booking-calendar-picker.d.ts +1 -0
- package/dist/types/components/scheduler-editor/nylas-booking-form-config/nylas-booking-form-config.d.ts +51 -0
- package/dist/types/components/scheduler-editor/nylas-calendar-picker/nylas-calendar-picker.d.ts +1 -0
- package/dist/types/components/scheduler-editor/nylas-connected-calendars/nylas-connected-calendars.d.ts +41 -0
- package/dist/types/components/scheduler-editor/nylas-customize-booking-settings/nylas-customize-booking-settings.d.ts +1 -1
- package/dist/types/components/scheduler-editor/nylas-editor-tabs/nylas-editor-tabs.d.ts +27 -4
- package/dist/types/components/scheduler-editor/nylas-editor-tabs/tab-contents.d.ts +2 -1
- package/dist/types/components/scheduler-editor/nylas-event-location/nylas-event-location.d.ts +7 -1
- package/dist/types/components/scheduler-editor/nylas-list-configurations/nylas-list-configurations.d.ts +13 -2
- package/dist/types/components/scheduler-editor/nylas-participant-booking-calendars/nylas-participant-booking-calendars.d.ts +43 -0
- package/dist/types/components/scheduler-editor/nylas-participants-custom-availability/nylas-participants-custom-availability.d.ts +4 -2
- package/dist/types/components/scheduler-editor/nylas-scheduler-editor/ExpressFlow.d.ts +11 -2
- package/dist/types/components/scheduler-editor/nylas-scheduler-editor/nylas-scheduler-editor.d.ts +4 -2
- package/dist/types/components/scheduler-editor/nylas-timeslot-interval/nylas-timeslot-interval.d.ts +2 -2
- package/dist/types/components.d.ts +723 -30
- package/dist/types/connector/shared/api/scheduler-config.d.ts +1 -1
- package/dist/types/stores/scheduler-config-store.d.ts +5 -2
- package/dist/types/stores/scheduler-store.d.ts +3 -1
- package/dist/types/types/index.d.ts +8 -0
- package/package.json +3 -2
- package/dist/cjs/button-component.cjs.entry.js +0 -31
- package/dist/cjs/button-component.cjs.entry.js.map +0 -1
- package/dist/cjs/calendar-info-icon_28.cjs.entry.js +0 -2935
- package/dist/cjs/calendar-info-icon_28.cjs.entry.js.map +0 -1
- package/dist/cjs/input-component.cjs.entry.js +0 -89
- package/dist/cjs/input-component.cjs.entry.js.map +0 -1
- package/dist/cjs/nylas-api-request-a1751a40.js.map +0 -1
- package/dist/cjs/scheduler-config-store-9f19c7a9.js.map +0 -1
- package/dist/cjs/scheduler-store-0f7328f1.js.map +0 -1
- package/dist/esm/button-component.entry.js +0 -27
- package/dist/esm/button-component.entry.js.map +0 -1
- package/dist/esm/calendar-info-icon_28.entry.js +0 -2904
- package/dist/esm/calendar-info-icon_28.entry.js.map +0 -1
- package/dist/esm/input-component.entry.js +0 -85
- package/dist/esm/input-component.entry.js.map +0 -1
- package/dist/esm/nylas-api-request-a67d2997.js.map +0 -1
- package/dist/esm/scheduler-config-store-4a50a03d.js.map +0 -1
- package/dist/esm/scheduler-store-f02ce045.js.map +0 -1
- package/dist/nylas-web-elements/p-019be093.entry.js +0 -11
- package/dist/nylas-web-elements/p-019be093.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-05833164.entry.js +0 -2
- package/dist/nylas-web-elements/p-05833164.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-061d0ae2.entry.js +0 -2
- package/dist/nylas-web-elements/p-061d0ae2.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-0c31f7ca.entry.js +0 -2
- package/dist/nylas-web-elements/p-0d98c728.entry.js +0 -2
- package/dist/nylas-web-elements/p-0d98c728.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-12b83ea9.entry.js +0 -2
- package/dist/nylas-web-elements/p-16fb6243.entry.js +0 -2
- package/dist/nylas-web-elements/p-1970b6ee.entry.js +0 -2
- package/dist/nylas-web-elements/p-1a27960b.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-1fa7b832.entry.js +0 -2
- package/dist/nylas-web-elements/p-26976360.entry.js +0 -2
- package/dist/nylas-web-elements/p-26976360.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-29938263.js +0 -2
- package/dist/nylas-web-elements/p-29938263.js.map +0 -1
- package/dist/nylas-web-elements/p-33a6a75b.entry.js +0 -2
- package/dist/nylas-web-elements/p-36f4b804.entry.js +0 -2
- package/dist/nylas-web-elements/p-36f4b804.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-39160c0d.entry.js +0 -11
- package/dist/nylas-web-elements/p-39160c0d.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-3b6bd448.entry.js +0 -2
- package/dist/nylas-web-elements/p-3eeab083.entry.js +0 -2
- package/dist/nylas-web-elements/p-49f716ed.js.map +0 -1
- package/dist/nylas-web-elements/p-53a1bb82.entry.js +0 -2
- package/dist/nylas-web-elements/p-53a1bb82.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-5bed86c2.entry.js +0 -2
- package/dist/nylas-web-elements/p-5ddd0c37.entry.js +0 -2
- package/dist/nylas-web-elements/p-613c070f.js.map +0 -1
- package/dist/nylas-web-elements/p-644ff4ee.entry.js +0 -2
- package/dist/nylas-web-elements/p-644ff4ee.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-64d73008.entry.js +0 -2
- package/dist/nylas-web-elements/p-6ddb4b95.entry.js +0 -2
- package/dist/nylas-web-elements/p-6ddb4b95.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-823c8aa2.js +0 -2
- package/dist/nylas-web-elements/p-823c8aa2.js.map +0 -1
- package/dist/nylas-web-elements/p-83444c0a.entry.js +0 -2
- package/dist/nylas-web-elements/p-83444c0a.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-8506a8d4.entry.js +0 -11
- package/dist/nylas-web-elements/p-8506a8d4.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-926dd201.entry.js +0 -2
- package/dist/nylas-web-elements/p-9283504a.entry.js +0 -2
- package/dist/nylas-web-elements/p-9283504a.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-958746a1.entry.js +0 -2
- package/dist/nylas-web-elements/p-9bb41364.entry.js +0 -2
- package/dist/nylas-web-elements/p-9bb41364.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-a800e7af.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-a8678862.entry.js +0 -2
- package/dist/nylas-web-elements/p-aac962c7.entry.js +0 -2
- package/dist/nylas-web-elements/p-aac962c7.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-b4d09fcf.entry.js +0 -2
- package/dist/nylas-web-elements/p-b4d09fcf.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-b9559f06.entry.js +0 -2
- package/dist/nylas-web-elements/p-b9559f06.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-bab1d562.entry.js +0 -2
- package/dist/nylas-web-elements/p-bab1d562.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-c18c15d0.entry.js +0 -2
- package/dist/nylas-web-elements/p-c1ff6499.entry.js +0 -2
- package/dist/nylas-web-elements/p-c1ff6499.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-d5d67115.entry.js +0 -2
- package/dist/nylas-web-elements/p-d5d67115.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-d9a91bc9.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-ea12997b.entry.js +0 -2
- package/dist/nylas-web-elements/p-f2d1b1a6.entry.js +0 -2
- package/dist/nylas-web-elements/p-f6fafe86.entry.js +0 -2
- package/dist/nylas-web-elements/p-f6fafe86.entry.js.map +0 -1
- package/dist/nylas-web-elements/p-ffce3a49.entry.js +0 -2
- package/dist/nylas-web-elements/p-ffce3a49.entry.js.map +0 -1
- /package/dist/nylas-web-elements/{p-08d75d35.entry.js.map → p-064c2ae5.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-5bed86c2.entry.js.map → p-0aa1e433.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-3f122804.entry.js.map → p-0bf6f818.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-926dd201.entry.js.map → p-1102df14.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-a7b19349.entry.js.map → p-155e5ce8.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-a85408e0.entry.js.map → p-18d100c8.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-5231fc13.entry.js.map → p-1a7edf86.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-554891cd.entry.js.map → p-1e1ae8d0.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-65097f45.entry.js.map → p-1fbe50b1.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-70e5cfb0.entry.js.map → p-22e05c7d.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-be38a8eb.entry.js.map → p-26302ad0.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-2a92691a.entry.js.map → p-2f47205d.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-085950eb.entry.js.map → p-3277023d.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-64d73008.entry.js.map → p-34c747f9.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-45c37986.entry.js.map → p-3ae38e51.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-0c31f7ca.entry.js.map → p-3bc1289e.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-5ddd0c37.entry.js.map → p-3d1e8e4d.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-e9ba368f.entry.js.map → p-3dae0c71.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-acadfabf.entry.js.map → p-3db7ab8d.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-28512ab6.entry.js.map → p-3e09b0fb.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-158fe1e9.entry.js.map → p-3eac9f45.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-d513d2ee.entry.js.map → p-4000107d.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-3b6bd448.entry.js.map → p-47392968.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-16a3bfb2.entry.js.map → p-4a594ebe.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-c90755ba.entry.js.map → p-4b6995fe.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-b2d95965.entry.js.map → p-4cdd4107.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-25c97a60.entry.js.map → p-4e8c8939.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-6bd9c9c3.entry.js.map → p-4e9ba325.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-6ce66add.entry.js.map → p-524a6acc.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-9b68568e.entry.js.map → p-533d39ce.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-7a95bc3f.entry.js.map → p-5a379fb5.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-cb03e4d4.entry.js.map → p-5a68368a.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-1970b6ee.entry.js.map → p-5b965d0d.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-091a8f00.entry.js.map → p-5ff4e63b.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-37f41a90.entry.js.map → p-656cf33f.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-246983ed.entry.js.map → p-65b7a2a7.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-60b03f86.entry.js.map → p-6c8af4fb.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-8e63b66c.entry.js.map → p-6d410f0a.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-daac96cb.entry.js.map → p-6e50d2fd.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-c18c15d0.entry.js.map → p-6e8b7ce8.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-b9fa6848.entry.js.map → p-7355937b.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-a8678862.entry.js.map → p-76156a82.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-052bc3b1.entry.js.map → p-7e08f131.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-2f148064.entry.js.map → p-7e10aa6d.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-b2aca6c4.entry.js.map → p-7e53588e.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-aae7febd.entry.js.map → p-83de54ae.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-de7b0878.entry.js.map → p-884b66bd.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-e928898a.entry.js.map → p-90294a76.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-3eeab083.entry.js.map → p-90817d1f.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-f1b0120b.entry.js.map → p-90d32fc3.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-dcc27b67.entry.js.map → p-95a9d2f1.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-6ef1024f.entry.js.map → p-96746b87.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-7fcecf3f.entry.js.map → p-97026709.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-eb7e8455.entry.js.map → p-987042a1.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-44507695.entry.js.map → p-9f903292.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-7ce048c0.entry.js.map → p-9fdbeba5.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-9794f735.entry.js.map → p-a22908ba.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-16fb6243.entry.js.map → p-a3c76c06.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-520ffe94.entry.js.map → p-a63d6241.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-cf0d5ab9.entry.js.map → p-aa4e6e5e.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-ba5a625c.entry.js.map → p-ab050d5b.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-161c9325.entry.js.map → p-b348aad4.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-5c3c1888.entry.js.map → p-b547209f.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-e8cde784.entry.js.map → p-b5b051e0.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-b0c8021f.entry.js.map → p-b7a53268.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-385070ba.entry.js.map → p-bc6c9256.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-d633e735.entry.js.map → p-be26ce19.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-8a4ac2a4.entry.js.map → p-bed6d217.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-8f3b02cd.entry.js.map → p-cb9fd100.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-bd34f97d.entry.js.map → p-cee0929a.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-b334d63b.entry.js.map → p-cffb3636.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-f1a54acf.entry.js.map → p-d1ab9d75.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-f96b12de.entry.js.map → p-d830e428.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-8075a758.entry.js.map → p-d9b08dd2.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-39fd9c90.entry.js.map → p-db73506b.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-8f843faf.entry.js.map → p-de84d999.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-bfe8e06b.entry.js.map → p-dfe9b5d0.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-66493463.entry.js.map → p-e5452799.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-f8653b9b.entry.js.map → p-e6e79d76.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-b813eb5d.entry.js.map → p-e944aa75.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-a12f3223.entry.js.map → p-eff175d3.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-cf589eab.entry.js.map → p-eff774e6.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-ecaf3ae1.entry.js.map → p-f13b8bd3.entry.js.map} +0 -0
- /package/dist/nylas-web-elements/{p-ea12997b.entry.js.map → p-f7465959.entry.js.map} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nylas-participants-custom-availability.js","sourceRoot":"","sources":["../../../../src/components/scheduler-editor/nylas-participants-custom-availability/nylas-participants-custom-availability.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAEhE,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtC,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AAuB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GAAG,EAAE,KAAK,EACV,IAAI,EAAE,eAAe,KAAK,IAAI,GAAG,EAAE,EACnC,SAAS,EAAE,WAAW,CAAC,SAAS,EAChC,eAAe,EAAE,WAAW,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,EAAE,QAAQ,EACrD,UAAU,EAAE,IAAI,GAChB,CACH,CACG,CACP,CAAC;oBACJ,CAAC,CAAC,CACG,CACH,CACF,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF;AArDC;IALC,iBAAiB,CAAyH;QACzI,IAAI,EAAE,wCAAwC;QAC9C,YAAY,EAAE,EAAE;QAChB,iBAAiB,EAAE,IAAI;KACxB,CAAC;;;;iEAqDD","sourcesContent":["import { RegisterComponent } from '@/common/register-component';\nimport { NylasSchedulerConfigConnector } from '@/connector/nylas-scheduler-config-connector';\nimport { debug } from '@/utils/utils';\nimport { AttachInternals, Component, Element, Event, EventEmitter, Host, Listen, Prop, State, Watch, h } from '@stencil/core';\nimport { NylasSchedulerEditor } from '../nylas-scheduler-editor/nylas-scheduler-editor';\nimport { Availability, OpenHours, Participant } from '@nylas/core';\n\n/**\n * The `nylas-participants-custom-availability` component is a form input for setting custom availability for participants.\n *\n * @part npca - The participants custom availability container\n * @part npca__header - The header of the participants custom availability\n * @part npca__content - The content of the participants custom availability\n * @part npca__participant-container - The participant container\n * @part npca__participant-title - The title of the participant\n * @part npca__participant-toggle--container - The toggle container for the participant\n * @part npca__toggle-label - The label of the toggle\n * @part npca_toggle-input - The input of the toggle\n * @part npca_toggle-slider - The slider of the toggle\n */\n@Component({\n tag: 'nylas-participants-custom-availability',\n styleUrl: 'nylas-participants-custom-availability.scss',\n shadow: true,\n formAssociated: true,\n})\nexport class NylasParticipantsCustomAvailability {\n @Element() host!: HTMLNylasParticipantsCustomAvailabilityElement;\n private participantFormRef!: HTMLFormElement;\n\n /**\n * The name of the participants custom availability.\n */\n @Prop() name: string = 'participant-custom-availability';\n\n /**\n * The participants selected in the add participants section.\n */\n @Prop() participants!: Participant[];\n\n /**\n * This event is fired when the participants custom availability changes.\n */\n @Event() valueChanged!: EventEmitter<{\n value: string;\n name: string;\n }>;\n\n /**\n * The element internals.\n */\n @AttachInternals() internals!: ElementInternals;\n\n /**\n * The state to store the custom availability setting for participants.\n */\n @State() selectedParticipants: {\n [key: string]: {\n setCustom: boolean;\n isOpen: boolean;\n openHours: OpenHours[];\n name: string;\n availability?: Availability;\n };\n } = this.setParticipants(this.participants);\n\n // Watchers\n @Watch('name')\n elementNameChangedHandler(newValue: string) {\n debug('nylas-participants-custom-availability', 'elementNameChangedHandler', newValue);\n this.host.setAttribute('name', newValue);\n }\n\n @Watch('participants')\n participantsChangedHandler(newValue: Participant[]) {\n debug('nylas-participants-custom-availability', 'participantsChangedHandler', newValue);\n this.selectedParticipants = this.setParticipants(newValue);\n }\n\n // Lifecycle Methods\n connectedCallback() {\n debug('nylas-participants-custom-availability', 'connectedCallback');\n }\n\n disconnectedCallback() {\n debug('nylas-participants-custom-availability', 'disconnectedCallback');\n }\n\n componentWillLoad() {\n debug('nylas-participants-custom-availability', 'componentWillLoad');\n }\n\n componentDidLoad() {\n debug('nylas-participants-custom-availability', 'componentDidLoad');\n }\n\n // Event Handlers\n @Listen('nylasFormSwitchToggled')\n nylasFormSwitchToggledHandler(event: CustomEvent<{ checked: boolean; name: string; label: boolean }>) {\n debug('nylas-participants-custom-availability', 'nylasFormSwitchToggledHandler', event.detail);\n this.selectedParticipants[event.detail.name]['isOpen'] = event.detail.checked;\n this.selectedParticipants[event.detail.name]['setCustom'] = event.detail.checked;\n this.selectedParticipants = { ...this.selectedParticipants };\n }\n\n @Listen('valueChanged')\n handleValueChanged(event: CustomEvent) {\n debug('[nylas-editor-tabs]', 'handleValueChanged', event);\n const { name, value } = event.detail;\n if (!name.startsWith('participant-')) {\n return;\n }\n // Validate the form\n if (!this.participantFormRef.checkValidity()) {\n this.internals.setValidity({ customError: true }, 'Please fix the overlapping time ranges.');\n return;\n } else {\n this.internals.setValidity({});\n }\n\n const jsonValue = JSON.parse(value);\n\n const key = name.split('-')[2];\n if (!this.selectedParticipants[key]) return;\n this.selectedParticipants[key]['openHours'] = jsonValue.openHours;\n this.selectedParticipants = { ...this.selectedParticipants };\n\n const participantOpenHours = {};\n this.participants.forEach(participant => {\n participantOpenHours[participant.email] = this.selectedParticipants[participant.email].openHours;\n });\n this.internals.setFormValue(JSON.stringify(participantOpenHours), this.name);\n this.valueChanged.emit({ value: JSON.stringify(participantOpenHours), name: this.name });\n }\n\n setParticipants(participants: Participant[]) {\n const selectedParticipants = {};\n participants.forEach(participant => {\n const isOpen = participant.is_organizer ? true : false;\n selectedParticipants[participant.email] = {\n isOpen: isOpen,\n setCustom: !!participant.availability?.open_hours ? true : false,\n openHours: participant.availability?.open_hours || [],\n name: participant.name || participant.email,\n availability: participant.availability,\n };\n });\n return selectedParticipants;\n }\n @RegisterComponent<NylasParticipantsCustomAvailability, NylasSchedulerConfigConnector, Exclude<NylasSchedulerEditor['stores'], undefined>>({\n name: 'nylas-participants-custom-availability',\n eventToProps: {},\n fireRegisterEvent: true,\n })\n render() {\n return (\n <Host>\n <div class=\"nylas-participants-custom-availability\" part=\"npca\">\n <div class=\"header\" part=\"npca__header\">\n <h3>Set Custom Availability for Participants</h3>\n <p>Set custom availability for scheduling meetings, or default to general availability.</p>\n </div>\n <div class=\"content\" part=\"npca__content\">\n <form ref={el => (this.participantFormRef = el as HTMLFormElement)}>\n {Object.keys(this.selectedParticipants).map((key, index) => {\n const participant = this.selectedParticipants[key];\n if (!participant || !participant.name || !participant.availability) return;\n return (\n <div class=\"participant-container\" part=\"npca__participant-container\" key={`participant-conatiner-${index}`}>\n <div class=\"participant-title\" part=\"npca__participant-title\">\n <p>Set {participant.name}'s custom availability</p>\n <div class=\"participant-toggle\" part=\"npca__participant-toggle--container\">\n <toggle-switch\n exportparts=\"ts_label: npca__toggle-label, ts_input: npca_toggle-input, ts_slider: npca_toggle-slider\"\n name={key}\n checked={!!participant.openHours && participant.openHours.length > 0}\n />\n <span\n class={`chevron ${participant.isOpen ? 'open' : 'closed'} ${participant.setCustom ? '' : 'disabled'}`}\n onClick={() => {\n if (!participant.setCustom) return;\n this.selectedParticipants[key].isOpen = !participant.isOpen;\n this.selectedParticipants = { ...this.selectedParticipants };\n }}\n >\n <chevron-icon width=\"24\" height=\"24\" />\n </span>\n </div>\n </div>\n {participant.isOpen && (\n <nylas-availability-picker\n key={index}\n name={`participant-${index}-${key}`}\n openHours={participant.openHours}\n defaultTimezone={participant.openHours?.[0]?.timezone}\n hideHeader={true}\n />\n )}\n </div>\n );\n })}\n </form>\n </div>\n </div>\n </Host>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"nylas-participants-custom-availability.js","sourceRoot":"","sources":["../../../../src/components/scheduler-editor/nylas-participants-custom-availability/nylas-participants-custom-availability.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAEhE,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtC,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AAuB9H,MAAM,OAAO,mCAAmC;;;oBAWvB,iCAAiC;;oCA+BpD,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,YAAY,CAAC;;IAI3C,yBAAyB,CAAC,QAAgB;QACxC,KAAK,CAAC,wCAAwC,EAAE,2BAA2B,EAAE,QAAQ,CAAC,CAAC;QACvF,IAAI,CAAC,IAAI,CAAC,YAAY,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;IAC3C,CAAC;IAGD,mCAAmC,CAAC,QAAuB,EAAE,QAA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G,EAAE,KAAK,EACV,IAAI,EAAE,eAAe,KAAK,IAAI,GAAG,EAAE,EACnC,SAAS,EAAE,WAAW,CAAC,SAAS,EAChC,eAAe,EAAE,WAAW,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,EAAE,QAAQ,EACrD,UAAU,EAAE,IAAI,GAChB,CACH,CACG,CACP,CAAC;oBACJ,CAAC,CAAC,CACG,CACH,CACF,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF;AArDC;IANC,iBAAiB,CAAyH;QACzI,IAAI,EAAE,wCAAwC;QAC9C,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,CAAC,uCAAuC,EAAE,uBAAuB,CAAC,CAAC,CAAC;QAC3F,YAAY,EAAE,EAAE;QAChB,iBAAiB,EAAE,IAAI;KACxB,CAAC;;;;iEAqDD","sourcesContent":["import { RegisterComponent } from '@/common/register-component';\nimport { NylasSchedulerConfigConnector } from '@/connector/nylas-scheduler-config-connector';\nimport { debug } from '@/utils/utils';\nimport { AttachInternals, Component, Element, Event, EventEmitter, Host, Listen, Prop, State, Watch, h } from '@stencil/core';\nimport { NylasSchedulerEditor } from '../nylas-scheduler-editor/nylas-scheduler-editor';\nimport { Availability, Configuration, OpenHours, Participant } from '@nylas/core';\n\n/**\n * The `nylas-participants-custom-availability` component is a form input for setting custom availability for participants.\n *\n * @part npca - The participants custom availability container\n * @part npca__header - The header of the participants custom availability\n * @part npca__content - The content of the participants custom availability\n * @part npca__participant-container - The participant container\n * @part npca__participant-title - The title of the participant\n * @part npca__participant-toggle--container - The toggle container for the participant\n * @part npca__toggle-label - The label of the toggle\n * @part npca_toggle-input - The input of the toggle\n * @part npca_toggle-slider - The slider of the toggle\n */\n@Component({\n tag: 'nylas-participants-custom-availability',\n styleUrl: 'nylas-participants-custom-availability.scss',\n shadow: true,\n formAssociated: true,\n})\nexport class NylasParticipantsCustomAvailability {\n @Element() host!: HTMLNylasParticipantsCustomAvailabilityElement;\n private participantFormRef!: HTMLFormElement;\n /**\n * The selected config\n */\n @Prop() selectedConfiguration?: Configuration;\n\n /**\n * The name of the participants custom availability.\n */\n @Prop() name: string = 'participant-custom-availability';\n\n /**\n * The participants selected in the add participants section.\n */\n @Prop() participants!: Participant[];\n\n /**\n * This event is fired when the participants custom availability changes.\n */\n @Event() valueChanged!: EventEmitter<{\n value: string;\n name: string;\n }>;\n\n /**\n * The element internals.\n */\n @AttachInternals() internals!: ElementInternals;\n\n /**\n * The state to store the custom availability setting for participants.\n */\n @State() selectedParticipants: {\n [key: string]: {\n setCustom: boolean;\n isOpen: boolean;\n openHours: OpenHours[];\n name: string;\n availability?: Availability;\n };\n } = this.setParticipants(this.participants);\n\n // Watchers\n @Watch('name')\n elementNameChangedHandler(newValue: string) {\n debug('nylas-participants-custom-availability', 'elementNameChangedHandler', newValue);\n this.host.setAttribute('name', newValue);\n }\n\n @Watch('selectedConfiguration')\n selectedConfigurationChangedHandler(newValue: Configuration, oldValue: Configuration) {\n debug('nylas-participants-custom-availability', 'selectedConfigurationChangedHandler', newValue, oldValue);\n if (newValue?.participants) {\n this.selectedParticipants = this.setParticipants(newValue?.participants);\n } else {\n this.selectedParticipants = this.setParticipants(this.participants);\n }\n }\n\n @Watch('participants')\n participantsChangedHandler(newValue: Participant[], oldValue: Participant[]) {\n debug('nylas-participants-custom-availability', 'participantsChangedHandler', newValue, oldValue);\n this.selectedParticipants = this.setParticipants(newValue);\n }\n\n // Lifecycle Methods\n connectedCallback() {\n debug('nylas-participants-custom-availability', 'connectedCallback');\n }\n\n disconnectedCallback() {\n debug('nylas-participants-custom-availability', 'disconnectedCallback');\n }\n\n componentWillLoad() {\n debug('nylas-participants-custom-availability', 'componentWillLoad');\n }\n\n componentDidLoad() {\n debug('nylas-participants-custom-availability', 'componentDidLoad');\n }\n\n // Event Handlers\n @Listen('nylasFormSwitchToggled')\n nylasFormSwitchToggledHandler(event: CustomEvent<{ checked: boolean; name: string; label: boolean }>) {\n debug('nylas-participants-custom-availability', 'nylasFormSwitchToggledHandler', event.detail);\n this.selectedParticipants[event.detail.name]['isOpen'] = event.detail.checked;\n this.selectedParticipants[event.detail.name]['setCustom'] = event.detail.checked;\n this.selectedParticipants = { ...this.selectedParticipants };\n }\n\n @Listen('valueChanged')\n handleValueChanged(event: CustomEvent) {\n debug('[nylas-editor-tabs]', 'handleValueChanged', event);\n const { name, value } = event.detail;\n if (!name.startsWith('participant-')) {\n return;\n }\n // Validate the form\n if (!this.participantFormRef.checkValidity()) {\n this.internals.setValidity({ customError: true }, 'Please fix the overlapping time ranges.');\n return;\n } else {\n this.internals.setValidity({});\n }\n\n const jsonValue = JSON.parse(value);\n\n const key = name.split('-')[2];\n if (!this.selectedParticipants[key]) return;\n this.selectedParticipants[key]['openHours'] = jsonValue.openHours;\n this.selectedParticipants = { ...this.selectedParticipants };\n\n const participantOpenHours = {};\n this.participants.forEach(participant => {\n participantOpenHours[participant.email] = this.selectedParticipants[participant.email].openHours;\n });\n this.internals.setFormValue(JSON.stringify(participantOpenHours), this.name);\n this.valueChanged.emit({ value: JSON.stringify(participantOpenHours), name: this.name });\n }\n\n setParticipants(participants: Participant[]) {\n const selectedParticipants = {};\n participants.forEach(participant => {\n selectedParticipants[participant.email] = {\n isOpen: false,\n setCustom: !!participant.availability?.open_hours ? true : false,\n openHours: participant.availability?.open_hours || [],\n name: participant.name || participant.email,\n availability: participant.availability,\n };\n });\n return selectedParticipants;\n }\n @RegisterComponent<NylasParticipantsCustomAvailability, NylasSchedulerConfigConnector, Exclude<NylasSchedulerEditor['stores'], undefined>>({\n name: 'nylas-participants-custom-availability',\n stateToProps: new Map([['schedulerConfig.selectedConfiguration', 'selectedConfiguration']]),\n eventToProps: {},\n fireRegisterEvent: true,\n })\n render() {\n return (\n <Host>\n <div class=\"nylas-participants-custom-availability\" part=\"npca\">\n <div class=\"header\" part=\"npca__header\">\n <h3>Availability for participants</h3>\n <p>If not set, the general availability on the Availability tab is used.</p>\n </div>\n <div class=\"content\" part=\"npca__content\">\n <form ref={el => (this.participantFormRef = el as HTMLFormElement)}>\n {Object.keys(this.selectedParticipants).map((key, index) => {\n const participant = this.selectedParticipants[key];\n if (!participant || !participant.name || !participant.availability) return;\n return (\n <div class=\"participant-container\" part=\"npca__participant-container\" key={`participant-conatiner-${index}`}>\n <div class=\"participant-title\" part=\"npca__participant-title\">\n <p>Set {participant.name}'s custom availability</p>\n <div class=\"participant-toggle\" part=\"npca__participant-toggle--container\">\n <toggle-switch\n exportparts=\"ts_label: npca__toggle-label, ts_input: npca_toggle-input, ts_slider: npca_toggle-slider\"\n name={key}\n checked={!!participant.openHours && participant.openHours.length > 0}\n />\n <span\n class={`chevron ${participant.isOpen ? 'open' : 'closed'} ${participant.setCustom ? '' : 'disabled'}`}\n onClick={() => {\n if (!participant.setCustom) return;\n this.selectedParticipants[key].isOpen = !participant.isOpen;\n this.selectedParticipants = { ...this.selectedParticipants };\n }}\n >\n <chevron-icon width=\"24\" height=\"24\" />\n </span>\n </div>\n </div>\n {participant.isOpen && (\n <nylas-availability-picker\n key={index}\n name={`participant-${index}-${key}`}\n openHours={participant.openHours}\n defaultTimezone={participant.openHours?.[0]?.timezone}\n hideHeader={true}\n />\n )}\n </div>\n );\n })}\n </form>\n </div>\n </div>\n </Host>\n );\n }\n}\n"]}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Fragment, h } from "@stencil/core";
|
|
2
|
-
export
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
export default function ExpressFlow({ selectedConfiguration, currentUser, calendars }) {
|
|
3
|
+
const organizer = selectedConfiguration.participants?.find(p => p.is_organizer) ?? currentUser;
|
|
4
|
+
return (h(Fragment, null, h("nylas-event-info", null, h("div", { slot: "inputs" }, h("nylas-event-title", null), h("nylas-event-duration", null), h("nylas-event-location", null))), h("nylas-booking-calendar-picker", { calendars: calendars, currentUser: currentUser, defaultBookingCalendar: organizer?.email })));
|
|
5
|
+
}
|
|
5
6
|
//# sourceMappingURL=ExpressFlow.js.map
|
package/dist/collection/components/scheduler-editor/nylas-scheduler-editor/ExpressFlow.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ExpressFlow.js","sourceRoot":"","sources":["../../../../src/components/scheduler-editor/nylas-scheduler-editor/ExpressFlow.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,
|
|
1
|
+
{"version":3,"file":"ExpressFlow.js","sourceRoot":"","sources":["../../../../src/components/scheduler-editor/nylas-scheduler-editor/ExpressFlow.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AAmB5C,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,EAAE,qBAAqB,EAAE,WAAW,EAAE,SAAS,EAAoB;IACrG,MAAM,SAAS,GAAG,qBAAqB,CAAC,YAAY,EAAE,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,YAAY,CAAC,IAAI,WAAW,CAAC;IAC/F,OAAO,CACL,EAAC,QAAQ;QACP;YACE,WAAK,IAAI,EAAC,QAAQ;gBAChB,4BAAqB;gBACrB,+BAAwB;gBACxB,+BAAwB,CACpB,CACW;QACnB,qCAA+B,SAAS,EAAE,SAAS,EAAE,WAAW,EAAE,WAAW,EAAE,sBAAsB,EAAE,SAAS,EAAE,KAAK,GAAI,CAClH,CACZ,CAAC;AACJ,CAAC","sourcesContent":["import { Fragment, h } from '@stencil/core';\nimport { Configuration } from '@nylas/core';\n\ntype RecursivePartial<T> = {\n [P in keyof T]?: T[P] extends (infer U)[] ? RecursivePartial<U>[] : T[P] extends object | undefined ? RecursivePartial<T[P]> : T[P];\n};\n\n/**\n * The props for the Express Flow component.\n */\nexport type ExpressFlowProps = {\n currentUser: any;\n calendars: any[];\n selectedConfiguration: RecursivePartial<Configuration>;\n};\n\n/**\n * The Express Flow component.\n */\nexport default function ExpressFlow({ selectedConfiguration, currentUser, calendars }: ExpressFlowProps) {\n const organizer = selectedConfiguration.participants?.find(p => p.is_organizer) ?? currentUser;\n return (\n <Fragment>\n <nylas-event-info>\n <div slot=\"inputs\">\n <nylas-event-title />\n <nylas-event-duration />\n <nylas-event-location />\n </div>\n </nylas-event-info>\n <nylas-booking-calendar-picker calendars={calendars} currentUser={currentUser} defaultBookingCalendar={organizer?.email} />\n </Fragment>\n );\n}\n"]}
|
package/dist/collection/components/scheduler-editor/nylas-scheduler-editor/nylas-scheduler-editor.js
CHANGED
|
@@ -6,7 +6,7 @@ import { debug } from "../../../utils/utils";
|
|
|
6
6
|
import { NylasSessions } from "@nylas/identity";
|
|
7
7
|
import { Host, h } from "@stencil/core";
|
|
8
8
|
import { LoginRequired } from "./LoginRequired";
|
|
9
|
-
import
|
|
9
|
+
import ExpressFlow from "./ExpressFlow";
|
|
10
10
|
export class NylasSchedulerEditor {
|
|
11
11
|
constructor() {
|
|
12
12
|
this.handleSchedulerConfigCloseClicked = (_event) => {
|
|
@@ -34,6 +34,8 @@ export class NylasSchedulerEditor {
|
|
|
34
34
|
this.defaultSchedulerConfigState = undefined;
|
|
35
35
|
this.mode = 'app';
|
|
36
36
|
this.additionalParticipants = undefined;
|
|
37
|
+
this.hideEditorTabs = [];
|
|
38
|
+
this.conferenceProviders = undefined;
|
|
37
39
|
this.automaticComponentRegistration = true;
|
|
38
40
|
}
|
|
39
41
|
connectedCallback() {
|
|
@@ -41,10 +43,22 @@ export class NylasSchedulerEditor {
|
|
|
41
43
|
}
|
|
42
44
|
async componentWillLoad() {
|
|
43
45
|
debug(`[nylas-scheduler-editor] componentWillLoad`);
|
|
46
|
+
const filteredAdditionalParticipants = this.additionalParticipants?.filter(participant => {
|
|
47
|
+
const filteredCalendars = participant.calendars?.length > 0 ? participant.calendars.filter(calendar => calendar.id && calendar.name) : [];
|
|
48
|
+
if (participant.name && participant.email && filteredCalendars.length > 0) {
|
|
49
|
+
return {
|
|
50
|
+
name: participant.name,
|
|
51
|
+
email: participant.email,
|
|
52
|
+
calendars: filteredCalendars,
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
});
|
|
44
56
|
this.stores = {
|
|
45
57
|
schedulerConfig: CreateNylasSchedulerConfigStore({
|
|
46
58
|
...this.defaultSchedulerConfigState,
|
|
47
|
-
additionalParticipants:
|
|
59
|
+
additionalParticipants: filteredAdditionalParticipants,
|
|
60
|
+
conferenceProviders: this.conferenceProviders,
|
|
61
|
+
hideEditorTabs: this.hideEditorTabs,
|
|
48
62
|
}),
|
|
49
63
|
};
|
|
50
64
|
if (!this.nylasApiRequest && this.nylasSessionsConfig) {
|
|
@@ -134,7 +148,7 @@ export class NylasSchedulerEditor {
|
|
|
134
148
|
await this.nylasSchedulerConfigConnector.schedulerConfig?.getCalendars();
|
|
135
149
|
}
|
|
136
150
|
render() {
|
|
137
|
-
return (h(Host, { key: '
|
|
151
|
+
return (h(Host, { key: '843aa39842caf2c85154b6b70120bf7f66d6e13b' }, h("div", { key: 'bb75d22d48ac322be916635dbbb6229b1077db36', class: "scheduler-editor-header", part: "nse__header" }, h("h1", { key: 'ae180ddc9c742c58e91cfeae59c76129f2b8d4b1', class: "scheduler-editor-title", part: "nse__title" }, h("calendar-icon", { key: '6f96e2158cccdddbad611fb64fa5d37795a60ee7', width: "18", height: "18" }), "Scheduler editor"), h("button", { key: 'f24abc88ac228e1b0c05689cbe9b33560d87a7a5', class: "scheduler-editor-close", title: "logout", onClick: e => this.handleSchedulerConfigCloseClicked(e), part: "nse__close-button" }, h("close-icon", { key: '916d5d1c0506995603598e6a56d16586690a509b', width: "18", height: "18" }))), this.stores?.schedulerConfig?.state.currentUser && this.stores.schedulerConfig.state.action === null && (h("div", { class: "list-configurations" }, h("nylas-list-configurations", null))), this.stores?.schedulerConfig?.state.currentUser && this.stores.schedulerConfig.state.action === 'create' && (h("nylas-editor-tabs", { mode: "composable" }, h(ExpressFlow, { currentUser: this.stores?.schedulerConfig?.state.currentUser, calendars: this.stores?.schedulerConfig?.state?.calendars, selectedConfiguration: this.stores?.schedulerConfig?.state?.selectedConfiguration }))), this.stores?.schedulerConfig?.state.currentUser && this.stores.schedulerConfig.state.action === 'edit' && (h("nylas-editor-tabs", { mode: this.mode }, this.mode === 'composable' && h("slot", null))), !this.stores?.schedulerConfig?.state.currentUser && (h("slot", { name: "login-required" }, h(LoginRequired, { authenticationUrl: this.authenticationUrl })))));
|
|
138
152
|
}
|
|
139
153
|
static get is() { return "nylas-scheduler-editor"; }
|
|
140
154
|
static get encapsulation() { return "shadow"; }
|
|
@@ -235,7 +249,7 @@ export class NylasSchedulerEditor {
|
|
|
235
249
|
"mutable": false,
|
|
236
250
|
"complexType": {
|
|
237
251
|
"original": "SchedulerEditorEventOverride",
|
|
238
|
-
"resolved": "Partial<{ valueChanged: (event: CustomEvent<{ value: string[]; name: string; valueChangedHandler?: ((event: CustomEvent<{ value: string[]; name: string; }>) => void) | undefined; } | { value: string; name: string; valueChanged?: ((event: CustomEvent<{ value: string; name: string; }>) => void) | undefined; } | { value: string; name: string; } | { value: string; name: string; } | { value: string; name: string; } | { value: string; name: string; }>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; formSubmitted: (event: CustomEvent<void>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; schedulerConfigChanged: (event: CustomEvent<SchedulerEventDetail>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; cancelButtonClick: (event: CustomEvent<void>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; previewButtonClicked: (event: CustomEvent<HTMLNylasEditorTabsElement>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; initListConfigurations: (event: CustomEvent<HTMLNylasListConfigurationsElement>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; createButtonClick: (event: CustomEvent<HTMLNylasListConfigurationsElement>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; editButtonClick: (event: CustomEvent<{ host: HTMLNylasListConfigurationsElement; configuration: Configuration; }>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; deleteButtonClick: (event: CustomEvent<{ host: HTMLNylasListConfigurationsElement; configuration: Configuration; }>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; }> & EventOverride<NylasSchedulerConfigConnectorInterface>",
|
|
252
|
+
"resolved": "Partial<{ valueChanged: (event: CustomEvent<{ value: string[]; name: string; valueChangedHandler?: ((event: CustomEvent<{ value: string[]; name: string; }>) => void) | undefined; } | { value: string; name: string; valueChanged?: ((event: CustomEvent<{ value: string; name: string; }>) => void) | undefined; } | { value: string; name: string; } | { value: string; name: string; } | { value: string; name: string; } | { value: string; name: string; }>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; formSubmitted: (event: CustomEvent<void>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; schedulerConfigChanged: (event: CustomEvent<SchedulerEventDetail>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; cancelButtonClick: (event: CustomEvent<void>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; previewButtonClicked: (event: CustomEvent<HTMLNylasEditorTabsElement>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; initListConfigurations: (event: CustomEvent<{ host: HTMLNylasListConfigurationsElement; cursor?: string | undefined; }>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; createButtonClick: (event: CustomEvent<HTMLNylasListConfigurationsElement>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; editButtonClick: (event: CustomEvent<{ host: HTMLNylasListConfigurationsElement; configuration: Configuration; }>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; deleteButtonClick: (event: CustomEvent<{ host: HTMLNylasListConfigurationsElement; configuration: Configuration; }>, connector?: NylasSchedulerConnectorInterface | undefined) => Promise<void>; }> & EventOverride<NylasSchedulerConfigConnectorInterface>",
|
|
239
253
|
"references": {
|
|
240
254
|
"SchedulerEditorEventOverride": {
|
|
241
255
|
"location": "import",
|
|
@@ -275,7 +289,7 @@ export class NylasSchedulerEditor {
|
|
|
275
289
|
"mutable": false,
|
|
276
290
|
"complexType": {
|
|
277
291
|
"original": "Partial<NylasSchedulerConfigStoreState>",
|
|
278
|
-
"resolved": "undefined | { selectedConfiguration?: RecursivePartial<Configuration> | undefined; configurations?: Configuration[] | undefined; calendars?: Calendar[] | undefined; currentUser?: User | null | undefined; action?: \"create\" | \"edit\" | null | undefined; additionalParticipants?:
|
|
292
|
+
"resolved": "undefined | { selectedConfiguration?: RecursivePartial<Configuration> | undefined; configurations?: Configuration[] | undefined; calendars?: Calendar[] | undefined; currentUser?: User | null | undefined; action?: \"create\" | \"edit\" | null | undefined; additionalParticipants?: AdditionalParticipant[] | undefined; listConfigurationsNextCursor?: string | null | undefined; hideEditorTabs?: string[] | undefined; conferenceProviders?: Record<\"google\" | \"microsoft\" | \"zoom\", string> | undefined; }",
|
|
279
293
|
"references": {
|
|
280
294
|
"Partial": {
|
|
281
295
|
"location": "global",
|
|
@@ -317,13 +331,13 @@ export class NylasSchedulerEditor {
|
|
|
317
331
|
"type": "unknown",
|
|
318
332
|
"mutable": false,
|
|
319
333
|
"complexType": {
|
|
320
|
-
"original": "
|
|
321
|
-
"resolved": "
|
|
334
|
+
"original": "AdditionalParticipant[]",
|
|
335
|
+
"resolved": "AdditionalParticipant[] | undefined",
|
|
322
336
|
"references": {
|
|
323
|
-
"
|
|
337
|
+
"AdditionalParticipant": {
|
|
324
338
|
"location": "import",
|
|
325
339
|
"path": "@nylas/core",
|
|
326
|
-
"id": "../nylas-js-core/dist/index.d.ts::
|
|
340
|
+
"id": "../nylas-js-core/dist/index.d.ts::AdditionalParticipant"
|
|
327
341
|
}
|
|
328
342
|
}
|
|
329
343
|
},
|
|
@@ -333,6 +347,42 @@ export class NylasSchedulerEditor {
|
|
|
333
347
|
"tags": [],
|
|
334
348
|
"text": "This prop is used to populate the additional participants and\ntheir availability in the scheduler editor."
|
|
335
349
|
}
|
|
350
|
+
},
|
|
351
|
+
"hideEditorTabs": {
|
|
352
|
+
"type": "unknown",
|
|
353
|
+
"mutable": false,
|
|
354
|
+
"complexType": {
|
|
355
|
+
"original": "string[]",
|
|
356
|
+
"resolved": "string[] | undefined",
|
|
357
|
+
"references": {}
|
|
358
|
+
},
|
|
359
|
+
"required": false,
|
|
360
|
+
"optional": true,
|
|
361
|
+
"docs": {
|
|
362
|
+
"tags": [],
|
|
363
|
+
"text": "This optional prop is used to hide tabs in the editor. Available tabs are:\neventInfo, availability, participants, bookingOptions, bookingForm"
|
|
364
|
+
},
|
|
365
|
+
"defaultValue": "[]"
|
|
366
|
+
},
|
|
367
|
+
"conferenceProviders": {
|
|
368
|
+
"type": "unknown",
|
|
369
|
+
"mutable": false,
|
|
370
|
+
"complexType": {
|
|
371
|
+
"original": "Record<string, string>",
|
|
372
|
+
"resolved": "undefined | { [x: string]: string; }",
|
|
373
|
+
"references": {
|
|
374
|
+
"Record": {
|
|
375
|
+
"location": "global",
|
|
376
|
+
"id": "global::Record"
|
|
377
|
+
}
|
|
378
|
+
}
|
|
379
|
+
},
|
|
380
|
+
"required": false,
|
|
381
|
+
"optional": true,
|
|
382
|
+
"docs": {
|
|
383
|
+
"tags": [],
|
|
384
|
+
"text": "This prop will be used to populate the conference provider options in the editor.\nThe key is the provider name ('zoom') and the value is the grant id.\nWe currently support same provider ('google', 'microsoft') for all participants and 'zoom' for cross-provider conferencing."
|
|
385
|
+
}
|
|
336
386
|
}
|
|
337
387
|
};
|
|
338
388
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nylas-scheduler-editor.js","sourceRoot":"","sources":["../../../../src/components/scheduler-editor/nylas-scheduler-editor/nylas-scheduler-editor.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAE/D,OAAO,EAAY,2BAA2B,EAA8B,MAA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@/common/component-types';\nimport { AuthArgs, NylasIdentityRequestWrapper, User, type NylasApiRequest } from '@/common/nylas-api-request';\nimport { RegisteredComponent } from '@/common/register-component';\nimport { NylasSchedulerConfigConnector } from '@/connector/nylas-scheduler-config-connector';\nimport { CreateNylasSchedulerConfigStore, NylasSchedulerConfigStoreState, NylasSchedulerConfigStoreType } from '@/stores/scheduler-config-store';\nimport { debug } from '@/utils/utils';\nimport { Config, NylasSessions } from '@nylas/identity';\nimport { Component, Element, Event, EventEmitter, Host, Listen, Method, Prop, State, Watch, h } from '@stencil/core';\nimport { LoginRequired } from './LoginRequired';\nimport { ExpressFlow } from './ExpressFlow';\nimport { Participant } from '@nylas/core';\n\n/**\n * The `nylas-scheduler-editor` component is a form that allows users to configure the settings for the Nylas Scheduler.\n *\n * @slot login-required - This slot is used to display a message when the user is not logged in.\n */\n@Component({\n tag: 'nylas-scheduler-editor',\n styleUrl: 'nylas-scheduler-editor.scss',\n shadow: true,\n})\nexport class NylasSchedulerEditor {\n /**\n * Stores to be used by the provider.\n */\n private stores?: {\n schedulerConfig: NylasSchedulerConfigStoreType;\n };\n\n /**\n * This is a base provide that defines the common methods and properties\n * that all providers should have.\n *\n * Because stencil does not support abstract classes, we have to use a\n * property to store the base provider instance.\n */\n private baseProvider?: NylasBaseProvider<Exclude<typeof this.stores, undefined>>;\n\n /**\n * The Nylas Scheduler Config Connector instance.\n * The brains of the provider. It manages data fetching and state synchronization.\n */\n private nylasSchedulerConfigConnector?: NylasSchedulerConfigConnector;\n\n /**\n * The host element.\n * Used to manage the host element of the provider.\n */\n @Element() private host!: HTMLNylasSchedulerEditorElement;\n\n /***\n * The configuration id to use for the scheduler editor.\n * If provided, then the scheduler editor will try and fetch the configuration\n * with the provided id. If found, it will automatically load the editor\n * with the configuration settings for editing.\n */\n @Prop({ mutable: true }) configurationId?: string;\n\n /**\n * The Nylas Api Request instance.\n * Used to make requests to the Nylas API.\n */\n @Prop({ mutable: true }) nylasApiRequest?: NylasApiRequest;\n\n /**\n * The Nylas Sessions configuration.\n * Used to configure the Nylas Sessions instance.\n */\n @Prop() nylasSessionsConfig?: Config;\n\n /**\n * The default authentication arguments to use when authenticating a user.\n */\n @Prop() defaultAuthArgs?: AuthArgs[];\n\n /**\n * This provides a way to override the default event handlers.\n */\n @Prop() eventOverrides: SchedulerEditorEventOverride = {};\n\n /**\n * The scheduler preview link to use when the user clicks on the preview button.\n * You can use the placeholder `{config.id}` to replace the configuration id anywhere in the link.\n */\n @Prop({ attribute: 'scheduler-preview-link' }) schedulerPreviewLink: string = '';\n\n /**\n * The default scheduler config store state.\n * Used to set the initial state of the scheduler config store.\n * This state can be used to pass defaults to newly created configurations.\n */\n @Prop({ attribute: 'default-scheduler-config-store-state' }) readonly defaultSchedulerConfigState?: Partial<NylasSchedulerConfigStoreState>;\n\n /**\n * This is used to set the mode for the scheduler config.\n * The mode can be 'app' or 'composable'.\n * The default mode is 'app'.\n */\n @Prop({ attribute: 'mode' }) readonly mode: 'app' | 'composable' = 'app';\n\n /**\n * This prop is used to populate the additional participants and\n * their availability in the scheduler editor.\n */\n @Prop({ attribute: 'additional-participants' }) additionalParticipants?: Participant[];\n\n /**\n * This event is fired when the provider is initialized.\n * By default, this event handles determining if the user is logged in or not.\n * In addition, it fetches the provided configuration if a valid configuration id is provided.\n */\n @Event({ cancelable: true }) readonly init!: EventEmitter<HTMLNylasSchedulerEditorElement>;\n\n /**\n * This event is fired when the the NylasAuth isAuthenticated state changes\n * to true.\n */\n @Event({ cancelable: true }) readonly loggedIn!: EventEmitter<HTMLNylasSchedulerEditorElement>;\n\n /**\n * This event is fired when the the NylasAuth isAuthenticated state changes\n * to false.\n */\n @Event({ cancelable: true }) readonly loggedOut!: EventEmitter<HTMLNylasSchedulerEditorElement>;\n\n /**\n * This event is fired when the close button on scheduler config is clicked.\n */\n @Event({ cancelable: true }) readonly schedulerConfigCloseClicked!: EventEmitter<HTMLNylasSchedulerEditorElement>;\n\n /**\n * Automatically register components that have the `@RegisterComponent` decorator.\n * If this is set to false, you will need to manually register components using the\n * `registerComponent` method.\n * @default true\n */\n @State() automaticComponentRegistration: boolean = true;\n\n connectedCallback() {\n debug(`[nylas-scheduler-editor] connectedCallback`);\n }\n\n async componentWillLoad() {\n debug(`[nylas-scheduler-editor] componentWillLoad`);\n this.stores = {\n schedulerConfig: CreateNylasSchedulerConfigStore({\n ...this.defaultSchedulerConfigState,\n additionalParticipants: this.additionalParticipants,\n }),\n };\n\n if (!this.nylasApiRequest && this.nylasSessionsConfig) {\n const nylasSession = new NylasSessions(this.nylasSessionsConfig);\n\n // We must check if the user is logged in before continuing\n // otherwise, a PCKE code will not be generated and the user\n // will not be able to log in.\n await nylasSession.isLoggedIn();\n\n // Watch for login events so that we can automatically update the state\n nylasSession.onLoginSuccess(async () => {\n const currentUser = await this.nylasSchedulerConfigConnector?.schedulerConfig?.currentUser();\n if (currentUser) {\n this.loggedIn.emit(this.host);\n this.loggedInHandler(currentUser);\n }\n });\n\n // Watch for logout events so that we can automatically update the state\n nylasSession.onLoginFail(async () => {\n this.stores?.schedulerConfig?.set('currentUser', null);\n this.loggedOut.emit(this.host);\n });\n\n this.nylasApiRequest = new NylasIdentityRequestWrapper(nylasSession);\n }\n\n if (this.nylasApiRequest && this.defaultAuthArgs) {\n this.nylasApiRequest.setDefaultAuthArgs(this.defaultAuthArgs);\n }\n\n this.baseProvider = new NylasBaseProvider(this.host, this.stores, this.automaticComponentRegistration, this.eventOverrides);\n\n const nylasSchedulerConfigStore = this.baseProvider.getStore('schedulerConfig');\n this.nylasSchedulerConfigConnector = new NylasSchedulerConfigConnector({\n nylasApiRequest: this.nylasApiRequest,\n nylasSchedulerConfigStore: nylasSchedulerConfigStore,\n });\n\n const initEvent = this.init.emit(this.host);\n if (!initEvent.defaultPrevented) {\n const currentUser = await this.nylasSchedulerConfigConnector?.schedulerConfig?.currentUser();\n if (currentUser) {\n this.loggedIn.emit(this.host);\n await this.loggedInHandler(currentUser);\n } else {\n this.stores?.schedulerConfig?.set('currentUser', null);\n this.loggedOut.emit(this.host);\n }\n }\n\n // Watch for store changes\n this.stores?.schedulerConfig?.onChange('selectedConfiguration', async config => {\n if (config && config.id) {\n this.configurationId = config.id;\n }\n });\n\n this.baseProvider?.componentWillLoad(this.nylasSchedulerConfigConnector);\n }\n\n async componentDidLoad() {\n debug(`[nylas-scheduler-editor] componentDidLoad`);\n this.baseProvider?.componentDidLoad();\n }\n\n componentDisconnected() {\n this.baseProvider?.componentDisconnected();\n }\n\n /**\n * Watch for changes to the configuration id and automatically fetch the configuration\n * when the configuration id changes. If the configuration id is cleared, then the\n * configuration is cleared as well.\n * @param newConfigurationId The new configuration id\n */\n @Watch('configurationId')\n async configurationIdChanged(newConfigurationId: string) {\n if (newConfigurationId) {\n await this.nylasSchedulerConfigConnector?.schedulerConfig?.getConfigurationById(newConfigurationId);\n this.stores?.schedulerConfig?.set('action', 'edit');\n } else {\n // Clear the configuration\n this.stores?.schedulerConfig?.set('selectedConfiguration', {});\n this.stores?.schedulerConfig?.set('action', null);\n }\n }\n\n /**\n * This method is used to get the NylasSchedulerConfigStore instance.\n * You can use this instance to update or get the state of the store.\n * @returns Promise<NylasSchedulerConfigStoreType | undefined>\n */\n @Method()\n async store(): Promise<NylasSchedulerConfigStoreType | undefined> {\n return this.stores?.schedulerConfig;\n }\n\n /**\n * This method is used to get the NylasSchedulerConfigConnector instance.\n * You can use this instance to make requests to the Nylas API.\n * @returns Promise<NylasSchedulerConfigConnector | undefined>\n */\n @Method()\n async schedulerConnector(): Promise<NylasSchedulerConfigConnector | undefined> {\n return this.nylasSchedulerConfigConnector;\n }\n\n /**\n * This is a custom event handler that is used to register a component with the provider.\n * It is used by components that have the `@RegisterComponent` decorator.\n * @param event A custom event that contains the component to register\n * @returns Promise<void>\n */\n @Listen('registerComponent')\n async registerComponentHandler(event: CustomEvent<RegisteredComponent<any, any>>): Promise<void> {\n this.baseProvider?.registerComponent(event.detail);\n }\n\n /**\n * This is a custom event handler that is used to unregister a component with the provider.\n * It is used by components that have the `@RegisterComponent` decorator.\n * @param event A custom event that contains the component to unregister\n * @returns Promise<void>\n */\n @Listen('unregisterComponent')\n async unregisterComponentHandler(event: CustomEvent<RegisteredComponent<any, any>>): Promise<void> {\n this.baseProvider?.unregisterComponent(event.detail);\n }\n\n /**\n * Upon login, set the current user and fetch the configuration and calendars.\n * @param currentUser The current user that is logged in\n */\n private async loggedInHandler(currentUser: User) {\n this.stores?.schedulerConfig?.set('currentUser', currentUser);\n\n if (!this.nylasSchedulerConfigConnector) {\n return;\n }\n\n if (this.configurationId) {\n const data = await this.nylasSchedulerConfigConnector.schedulerConfig?.getConfigurationById(this.configurationId);\n if (data && data[0]?.id) {\n this.stores?.schedulerConfig?.set('action', 'edit');\n }\n }\n\n await this.nylasSchedulerConfigConnector.schedulerConfig?.getCalendars();\n }\n\n /**\n * This is a custom event handler that is used to update the state of the provider.\n */\n private handleSchedulerConfigCloseClicked = (_event: Event) => {\n const event = this.schedulerConfigCloseClicked.emit(this.host);\n if (!event.defaultPrevented) {\n localStorage.removeItem('grant');\n localStorage.removeItem('user');\n window.location.reload();\n }\n };\n\n /**\n * This method is used to get the authentication URL for a provider.\n * @param provider The provider to get the authentication URL for (e.g. google, microsoft, etc.)\n * @returns Promise<string> The authentication URL to redirect the user for the provider\n */\n private authenticationUrl = async (provider?: string) => {\n if (!this.nylasApiRequest) {\n console.error(`[nylas-scheduler-editor] Nylas API Request is not initialized.`);\n return '';\n }\n const url = await this.nylasApiRequest.authenticationUrl({ provider });\n\n return url || '';\n };\n\n render() {\n return (\n <Host>\n <div class=\"scheduler-editor-header\" part=\"nse__header\">\n <h1 class=\"scheduler-editor-title\" part=\"nse__title\">\n <calendar-icon width=\"18\" height=\"18\" />\n Scheduler editor\n </h1>\n <button class=\"scheduler-editor-close\" title=\"logout\" onClick={e => this.handleSchedulerConfigCloseClicked(e)} part=\"nse__close-button\">\n <close-icon width=\"18\" height=\"18\" />\n </button>\n </div>\n {this.stores?.schedulerConfig?.state.currentUser && this.stores.schedulerConfig.state.action === null && (\n <div class=\"list-configurations\">\n <nylas-list-configurations></nylas-list-configurations>\n </div>\n )}\n {this.stores?.schedulerConfig?.state.currentUser && this.stores.schedulerConfig.state.action === 'create' && (\n // If the mode is 'app', then render the editor tabs in a composable mode with children for creating a new configuration (Express flow).\n <nylas-editor-tabs mode=\"composable\">\n <ExpressFlow />\n </nylas-editor-tabs>\n )}\n {this.stores?.schedulerConfig?.state.currentUser && this.stores.schedulerConfig.state.action === 'edit' && (\n <nylas-editor-tabs mode={this.mode}>{this.mode === 'composable' && <slot />}</nylas-editor-tabs>\n )}\n {!this.stores?.schedulerConfig?.state.currentUser && (\n <slot name=\"login-required\">\n <LoginRequired authenticationUrl={this.authenticationUrl} />\n </slot>\n )}\n </Host>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"nylas-scheduler-editor.js","sourceRoot":"","sources":["../../../../src/components/scheduler-editor/nylas-scheduler-editor/nylas-scheduler-editor.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAE/D,OAAO,EAAY,2BAA2B,EAA8B,MAAM,4BAA4B,CAAC;AAE/G,OAAO,EAAE,6BAA6B,EAAE,MAAM,8CAA8C,CAAC;AAC7F,OAAO,EAAE,+BAA+B,EAAiE,MAAM,iCAAiC,CAAC;AACjJ,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtC,OAAO,EAAU,aAAa,EAAE,MAAM,iBAAiB,CAAC;AACxD,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AACrH,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,WAAW,MAAM,eAAe,CAAC;AAaxC,MAAM,OAAO,oBAAoB;;QAoTvB,sCAAiC,G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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { NylasBaseProvider } from '@/common/abstract-provider';\nimport type { SchedulerEditorEventOverride } from '@/common/component-types';\nimport { AuthArgs, NylasIdentityRequestWrapper, User, type NylasApiRequest } from '@/common/nylas-api-request';\nimport { RegisteredComponent } from '@/common/register-component';\nimport { NylasSchedulerConfigConnector } from '@/connector/nylas-scheduler-config-connector';\nimport { CreateNylasSchedulerConfigStore, NylasSchedulerConfigStoreState, NylasSchedulerConfigStoreType } from '@/stores/scheduler-config-store';\nimport { debug } from '@/utils/utils';\nimport { Config, NylasSessions } from '@nylas/identity';\nimport { Component, Element, Event, EventEmitter, Host, Listen, Method, Prop, State, Watch, h } from '@stencil/core';\nimport { LoginRequired } from './LoginRequired';\nimport ExpressFlow from './ExpressFlow';\nimport { AdditionalParticipant } from '@nylas/core';\n\n/**\n * The `nylas-scheduler-editor` component is a form that allows users to configure the settings for the Nylas Scheduler.\n *\n * @slot login-required - This slot is used to display a message when the user is not logged in.\n */\n@Component({\n tag: 'nylas-scheduler-editor',\n styleUrl: 'nylas-scheduler-editor.scss',\n shadow: true,\n})\nexport class NylasSchedulerEditor {\n /**\n * Stores to be used by the provider.\n */\n private stores?: {\n schedulerConfig: NylasSchedulerConfigStoreType;\n };\n\n /**\n * This is a base provide that defines the common methods and properties\n * that all providers should have.\n *\n * Because stencil does not support abstract classes, we have to use a\n * property to store the base provider instance.\n */\n private baseProvider?: NylasBaseProvider<Exclude<typeof this.stores, undefined>>;\n\n /**\n * The Nylas Scheduler Config Connector instance.\n * The brains of the provider. It manages data fetching and state synchronization.\n */\n private nylasSchedulerConfigConnector?: NylasSchedulerConfigConnector;\n\n /**\n * The host element.\n * Used to manage the host element of the provider.\n */\n @Element() private host!: HTMLNylasSchedulerEditorElement;\n\n /***\n * The configuration id to use for the scheduler editor.\n * If provided, then the scheduler editor will try and fetch the configuration\n * with the provided id. If found, it will automatically load the editor\n * with the configuration settings for editing.\n */\n @Prop({ mutable: true }) configurationId?: string;\n\n /**\n * The Nylas Api Request instance.\n * Used to make requests to the Nylas API.\n */\n @Prop({ mutable: true }) nylasApiRequest?: NylasApiRequest;\n\n /**\n * The Nylas Sessions configuration.\n * Used to configure the Nylas Sessions instance.\n */\n @Prop() nylasSessionsConfig?: Config;\n\n /**\n * The default authentication arguments to use when authenticating a user.\n */\n @Prop() defaultAuthArgs?: AuthArgs[];\n\n /**\n * This provides a way to override the default event handlers.\n */\n @Prop() eventOverrides: SchedulerEditorEventOverride = {};\n\n /**\n * The scheduler preview link to use when the user clicks on the preview button.\n * You can use the placeholder `{config.id}` to replace the configuration id anywhere in the link.\n */\n @Prop({ attribute: 'scheduler-preview-link' }) schedulerPreviewLink: string = '';\n\n /**\n * The default scheduler config store state.\n * Used to set the initial state of the scheduler config store.\n * This state can be used to pass defaults to newly created configurations.\n */\n @Prop({ attribute: 'default-scheduler-config-store-state' }) readonly defaultSchedulerConfigState?: Partial<NylasSchedulerConfigStoreState>;\n\n /**\n * This is used to set the mode for the scheduler config.\n * The mode can be 'app' or 'composable'.\n * The default mode is 'app'.\n */\n @Prop({ attribute: 'mode' }) readonly mode: 'app' | 'composable' = 'app';\n\n /**\n * This prop is used to populate the additional participants and\n * their availability in the scheduler editor.\n */\n @Prop({ attribute: 'additional-participants' }) additionalParticipants?: AdditionalParticipant[];\n\n /**\n * This optional prop is used to hide tabs in the editor. Available tabs are:\n * eventInfo, availability, participants, bookingOptions, bookingForm\n */\n @Prop({ attribute: 'hide-editor-tabs' }) hideEditorTabs?: string[] = [];\n\n /**\n * This prop will be used to populate the conference provider options in the editor.\n * The key is the provider name ('zoom') and the value is the grant id.\n * We currently support same provider ('google', 'microsoft') for all participants and 'zoom' for cross-provider conferencing.\n */\n @Prop({ attribute: 'conference-providers' }) conferenceProviders?: Record<string, string>;\n\n /**\n * This event is fired when the provider is initialized.\n * By default, this event handles determining if the user is logged in or not.\n * In addition, it fetches the provided configuration if a valid configuration id is provided.\n */\n @Event({ cancelable: true }) readonly init!: EventEmitter<HTMLNylasSchedulerEditorElement>;\n\n /**\n * This event is fired when the the NylasAuth isAuthenticated state changes\n * to true.\n */\n @Event({ cancelable: true }) readonly loggedIn!: EventEmitter<HTMLNylasSchedulerEditorElement>;\n\n /**\n * This event is fired when the the NylasAuth isAuthenticated state changes\n * to false.\n */\n @Event({ cancelable: true }) readonly loggedOut!: EventEmitter<HTMLNylasSchedulerEditorElement>;\n\n /**\n * This event is fired when the close button on scheduler config is clicked.\n */\n @Event({ cancelable: true }) readonly schedulerConfigCloseClicked!: EventEmitter<HTMLNylasSchedulerEditorElement>;\n\n /**\n * Automatically register components that have the `@RegisterComponent` decorator.\n * If this is set to false, you will need to manually register components using the\n * `registerComponent` method.\n * @default true\n */\n @State() automaticComponentRegistration: boolean = true;\n\n connectedCallback() {\n debug(`[nylas-scheduler-editor] connectedCallback`);\n }\n\n async componentWillLoad() {\n debug(`[nylas-scheduler-editor] componentWillLoad`);\n const filteredAdditionalParticipants = this.additionalParticipants?.filter(participant => {\n const filteredCalendars = participant.calendars?.length > 0 ? participant.calendars.filter(calendar => calendar.id && calendar.name) : [];\n if (participant.name && participant.email && filteredCalendars.length > 0) {\n return {\n name: participant.name,\n email: participant.email,\n calendars: filteredCalendars,\n };\n }\n });\n this.stores = {\n schedulerConfig: CreateNylasSchedulerConfigStore({\n ...this.defaultSchedulerConfigState,\n additionalParticipants: filteredAdditionalParticipants,\n conferenceProviders: this.conferenceProviders,\n hideEditorTabs: this.hideEditorTabs,\n }),\n };\n\n if (!this.nylasApiRequest && this.nylasSessionsConfig) {\n const nylasSession = new NylasSessions(this.nylasSessionsConfig);\n\n // We must check if the user is logged in before continuing\n // otherwise, a PCKE code will not be generated and the user\n // will not be able to log in.\n await nylasSession.isLoggedIn();\n\n // Watch for login events so that we can automatically update the state\n nylasSession.onLoginSuccess(async () => {\n const currentUser = await this.nylasSchedulerConfigConnector?.schedulerConfig?.currentUser();\n if (currentUser) {\n this.loggedIn.emit(this.host);\n this.loggedInHandler(currentUser);\n }\n });\n\n // Watch for logout events so that we can automatically update the state\n nylasSession.onLoginFail(async () => {\n this.stores?.schedulerConfig?.set('currentUser', null);\n this.loggedOut.emit(this.host);\n });\n\n this.nylasApiRequest = new NylasIdentityRequestWrapper(nylasSession);\n }\n\n if (this.nylasApiRequest && this.defaultAuthArgs) {\n this.nylasApiRequest.setDefaultAuthArgs(this.defaultAuthArgs);\n }\n\n this.baseProvider = new NylasBaseProvider(this.host, this.stores, this.automaticComponentRegistration, this.eventOverrides);\n\n const nylasSchedulerConfigStore = this.baseProvider.getStore('schedulerConfig');\n this.nylasSchedulerConfigConnector = new NylasSchedulerConfigConnector({\n nylasApiRequest: this.nylasApiRequest,\n nylasSchedulerConfigStore: nylasSchedulerConfigStore,\n });\n\n const initEvent = this.init.emit(this.host);\n if (!initEvent.defaultPrevented) {\n const currentUser = await this.nylasSchedulerConfigConnector?.schedulerConfig?.currentUser();\n if (currentUser) {\n this.loggedIn.emit(this.host);\n await this.loggedInHandler(currentUser);\n } else {\n this.stores?.schedulerConfig?.set('currentUser', null);\n this.loggedOut.emit(this.host);\n }\n }\n\n // Watch for store changes\n this.stores?.schedulerConfig?.onChange('selectedConfiguration', async config => {\n if (config && config.id) {\n this.configurationId = config.id;\n }\n });\n\n this.baseProvider?.componentWillLoad(this.nylasSchedulerConfigConnector);\n }\n\n async componentDidLoad() {\n debug(`[nylas-scheduler-editor] componentDidLoad`);\n this.baseProvider?.componentDidLoad();\n }\n\n componentDisconnected() {\n this.baseProvider?.componentDisconnected();\n }\n\n /**\n * Watch for changes to the configuration id and automatically fetch the configuration\n * when the configuration id changes. If the configuration id is cleared, then the\n * configuration is cleared as well.\n * @param newConfigurationId The new configuration id\n */\n @Watch('configurationId')\n async configurationIdChanged(newConfigurationId: string) {\n if (newConfigurationId) {\n await this.nylasSchedulerConfigConnector?.schedulerConfig?.getConfigurationById(newConfigurationId);\n this.stores?.schedulerConfig?.set('action', 'edit');\n } else {\n // Clear the configuration\n this.stores?.schedulerConfig?.set('selectedConfiguration', {});\n this.stores?.schedulerConfig?.set('action', null);\n }\n }\n\n /**\n * This method is used to get the NylasSchedulerConfigStore instance.\n * You can use this instance to update or get the state of the store.\n * @returns Promise<NylasSchedulerConfigStoreType | undefined>\n */\n @Method()\n async store(): Promise<NylasSchedulerConfigStoreType | undefined> {\n return this.stores?.schedulerConfig;\n }\n\n /**\n * This method is used to get the NylasSchedulerConfigConnector instance.\n * You can use this instance to make requests to the Nylas API.\n * @returns Promise<NylasSchedulerConfigConnector | undefined>\n */\n @Method()\n async schedulerConnector(): Promise<NylasSchedulerConfigConnector | undefined> {\n return this.nylasSchedulerConfigConnector;\n }\n\n /**\n * This is a custom event handler that is used to register a component with the provider.\n * It is used by components that have the `@RegisterComponent` decorator.\n * @param event A custom event that contains the component to register\n * @returns Promise<void>\n */\n @Listen('registerComponent')\n async registerComponentHandler(event: CustomEvent<RegisteredComponent<any, any>>): Promise<void> {\n this.baseProvider?.registerComponent(event.detail);\n }\n\n /**\n * This is a custom event handler that is used to unregister a component with the provider.\n * It is used by components that have the `@RegisterComponent` decorator.\n * @param event A custom event that contains the component to unregister\n * @returns Promise<void>\n */\n @Listen('unregisterComponent')\n async unregisterComponentHandler(event: CustomEvent<RegisteredComponent<any, any>>): Promise<void> {\n this.baseProvider?.unregisterComponent(event.detail);\n }\n\n /**\n * Upon login, set the current user and fetch the configuration and calendars.\n * @param currentUser The current user that is logged in\n */\n private async loggedInHandler(currentUser: User) {\n this.stores?.schedulerConfig?.set('currentUser', currentUser);\n\n if (!this.nylasSchedulerConfigConnector) {\n return;\n }\n\n if (this.configurationId) {\n const data = await this.nylasSchedulerConfigConnector.schedulerConfig?.getConfigurationById(this.configurationId);\n if (data && data[0]?.id) {\n this.stores?.schedulerConfig?.set('action', 'edit');\n }\n }\n\n await this.nylasSchedulerConfigConnector.schedulerConfig?.getCalendars();\n }\n\n /**\n * This is a custom event handler that is used to update the state of the provider.\n */\n private handleSchedulerConfigCloseClicked = (_event: Event) => {\n const event = this.schedulerConfigCloseClicked.emit(this.host);\n if (!event.defaultPrevented) {\n localStorage.removeItem('grant');\n localStorage.removeItem('user');\n window.location.reload();\n }\n };\n\n /**\n * This method is used to get the authentication URL for a provider.\n * @param provider The provider to get the authentication URL for (e.g. google, microsoft, etc.)\n * @returns Promise<string> The authentication URL to redirect the user for the provider\n */\n private authenticationUrl = async (provider?: string) => {\n if (!this.nylasApiRequest) {\n console.error(`[nylas-scheduler-editor] Nylas API Request is not initialized.`);\n return '';\n }\n const url = await this.nylasApiRequest.authenticationUrl({ provider });\n\n return url || '';\n };\n\n render() {\n return (\n <Host>\n <div class=\"scheduler-editor-header\" part=\"nse__header\">\n <h1 class=\"scheduler-editor-title\" part=\"nse__title\">\n <calendar-icon width=\"18\" height=\"18\" />\n Scheduler editor\n </h1>\n <button class=\"scheduler-editor-close\" title=\"logout\" onClick={e => this.handleSchedulerConfigCloseClicked(e)} part=\"nse__close-button\">\n <close-icon width=\"18\" height=\"18\" />\n </button>\n </div>\n {this.stores?.schedulerConfig?.state.currentUser && this.stores.schedulerConfig.state.action === null && (\n <div class=\"list-configurations\">\n <nylas-list-configurations></nylas-list-configurations>\n </div>\n )}\n {this.stores?.schedulerConfig?.state.currentUser && this.stores.schedulerConfig.state.action === 'create' && (\n // If the mode is 'app', then render the editor tabs in a composable mode with children for creating a new configuration (Express flow).\n <nylas-editor-tabs mode=\"composable\">\n <ExpressFlow\n currentUser={this.stores?.schedulerConfig?.state.currentUser}\n calendars={this.stores?.schedulerConfig?.state?.calendars}\n selectedConfiguration={this.stores?.schedulerConfig?.state?.selectedConfiguration}\n />\n </nylas-editor-tabs>\n )}\n {this.stores?.schedulerConfig?.state.currentUser && this.stores.schedulerConfig.state.action === 'edit' && (\n <nylas-editor-tabs mode={this.mode}>{this.mode === 'composable' && <slot />}</nylas-editor-tabs>\n )}\n {!this.stores?.schedulerConfig?.state.currentUser && (\n <slot name=\"login-required\">\n <LoginRequired authenticationUrl={this.authenticationUrl} />\n </slot>\n )}\n </Host>\n );\n }\n}\n"]}
|
|
@@ -254,7 +254,7 @@ export class TimeInput {
|
|
|
254
254
|
}
|
|
255
255
|
}
|
|
256
256
|
render() {
|
|
257
|
-
return (h(Host, { key: '
|
|
257
|
+
return (h(Host, { key: '0ffd2bd4930bcb5fd19e0e9f4aa930206cd445ef' }, h("div", { key: '94a265377b520768cfe2d755193bd88b6fd76b27', class: "time-picker", part: "time-picker" }, h("input", { key: '957b8e3736cede01bdac8fc4c6050a058b45a717', type: "text", name: this.name, id: this.name, part: "time-input", class: {
|
|
258
258
|
'time-input': true,
|
|
259
259
|
'error': !!this.err || this.hasError,
|
|
260
260
|
}, ref: el => (this.timeInput = el), value: this.time, onClick: () => {
|
|
@@ -20,8 +20,8 @@ export class NylasTimeslotInterval {
|
|
|
20
20
|
constructor() {
|
|
21
21
|
this.selectedConfiguration = undefined;
|
|
22
22
|
this.name = 'timeslot-picker';
|
|
23
|
-
this.eventDurationMinutes = this.selectedConfiguration?.availability?.duration_minutes
|
|
24
|
-
this.defaultIntervalMinutes = this.selectedConfiguration?.availability?.interval_minutes ?? this.eventDurationMinutes;
|
|
23
|
+
this.eventDurationMinutes = this.selectedConfiguration?.availability?.duration_minutes;
|
|
24
|
+
this.defaultIntervalMinutes = this.selectedConfiguration?.availability?.interval_minutes ?? this.eventDurationMinutes ?? 10;
|
|
25
25
|
this.defaultRoundTo = this.selectedConfiguration?.availability?.round_to ?? undefined;
|
|
26
26
|
this.selectedInterval = this.defaultIntervalMinutes;
|
|
27
27
|
this.selectedRoundTo = this.defaultRoundTo && this.defaultRoundTo === this.defaultIntervalMinutes ? true : false;
|
|
@@ -32,7 +32,7 @@ export class NylasTimeslotInterval {
|
|
|
32
32
|
}
|
|
33
33
|
selectedConfigurationChangedHandler(newValue) {
|
|
34
34
|
debug('nylas-timeslot-interval', 'selectedConfigurationChangedHandler', newValue);
|
|
35
|
-
this.defaultIntervalMinutes = newValue.availability?.interval_minutes ?? this.eventDurationMinutes;
|
|
35
|
+
this.defaultIntervalMinutes = newValue.availability?.interval_minutes ?? this.eventDurationMinutes ?? 10;
|
|
36
36
|
this.defaultRoundTo = newValue.availability?.round_to ?? undefined;
|
|
37
37
|
this.selectedInterval = this.defaultIntervalMinutes;
|
|
38
38
|
this.selectedRoundTo = this.defaultRoundTo && this.defaultRoundTo === this.defaultIntervalMinutes ? true : false;
|
|
@@ -66,7 +66,7 @@ export class NylasTimeslotInterval {
|
|
|
66
66
|
debug('nylas-timeslot-interval', 'nylasFormDropdownChangedHandler', event.detail);
|
|
67
67
|
const value = event.detail.value;
|
|
68
68
|
if (value === 'duration') {
|
|
69
|
-
this.selectedInterval = this.eventDurationMinutes;
|
|
69
|
+
this.selectedInterval = this.eventDurationMinutes ?? 10;
|
|
70
70
|
}
|
|
71
71
|
else {
|
|
72
72
|
this.selectedInterval = parseInt(event.detail.value);
|
|
@@ -83,8 +83,8 @@ export class NylasTimeslotInterval {
|
|
|
83
83
|
this.internals.setFormValue(JSON.stringify({ interval: this.selectedInterval, roundTo: this.selectedRoundTo ? this.selectedInterval : defaultRoundToMinustes }), this.name);
|
|
84
84
|
}
|
|
85
85
|
}
|
|
86
|
-
|
|
87
|
-
debug('nylas-timeslot-interval', '
|
|
86
|
+
nylasFormRadioChangedHandler(event) {
|
|
87
|
+
debug('nylas-timeslot-interval', 'nylasFormRadioChangedHandler', event.detail);
|
|
88
88
|
const value = event.detail.value;
|
|
89
89
|
if (value === 'no-rounding') {
|
|
90
90
|
this.selectedRoundTo = false;
|
|
@@ -115,14 +115,14 @@ export class NylasTimeslotInterval {
|
|
|
115
115
|
{ value: '45', label: '45 mins' },
|
|
116
116
|
{ value: '60', label: '60 mins' },
|
|
117
117
|
];
|
|
118
|
-
return (h(Host, { key: '
|
|
118
|
+
return (h(Host, { key: '74ed43cccb282e8de5cff14d7966b79deee55daf' }, h("div", { key: '5b3bbf89048551b553aabf468ca475cdefdad341', class: "nylas-timeslot-interval", part: "nti" }, h("div", { key: '04aec403481c8870063b8704a9ac880c11e3071e', class: "header", part: "nti__header" }, h("h3", { key: '35a9bd6d07a4a89a8dde8be1f252e5210fc21f2e' }, "Time slot settings"), h("p", { key: 'b889b033a82475a832abb0b480a3c648a2f99172' }, "Manage time slot settings.")), h("div", { key: 'c37caaec6d8fd3326bef84024ab32e6e4ac5464f', class: "nylas-timeslot-interval__dropdown" }, h("span", { key: '723a6719aee58e8ed767c541fd45929024e348bf', class: "label", part: "nti__input-label" }, "Select a time slot interval."), h("select-dropdown", { key: 'b621f8df10b400e944c65da1dc7d18c63886edcc', name: "booking-calendar", options: intervalPreferenceOptions, withSearch: false, exportparts: "sd_dropdown: nti__dropdown, sd_dropdown-button: nti__dropdown-button, sd_dropdown-content: nti__dropdown-content", defaultSelectedOption: this.defaultIntervalMinutes == this.eventDurationMinutes
|
|
119
119
|
? intervalPreferenceOptions[0]
|
|
120
|
-
: intervalPreferenceOptions.find(op => op.value == this.defaultIntervalMinutes.toString()) ?? intervalPreferenceOptions[0] }), h("span", { key: '
|
|
121
|
-
{ value: 'no-rounding', label: 'Default', description: 'Time
|
|
120
|
+
: intervalPreferenceOptions.find(op => op.value == this.defaultIntervalMinutes.toString()) ?? intervalPreferenceOptions[0] }), h("span", { key: 'c98907d3660086deb3bb66aede6d3834190f9a69', slot: "label", class: "label", part: "nti__input-label" }, "Select the time slot rounding type", h("tooltip-component", { key: 'e4f6f0f75ab80a99612c622b111f4500d12cb05d' }, h("info-icon", { key: 'aa3e8de015f4c63511694f4cad1513615a87d738', slot: "tooltip-icon" }), h("span", { key: '9e0653df752fad754c51aa79438f75deab9bedb1', slot: "tooltip-content" }, "Select if you want to round the time slots to the nearest interval."))), h("radio-button-group", { key: 'b534ab334dd45491b7bfd287675fb67e24f82c99', name: "interval-preference", defaultSelectedValue: this.defaultRoundTo && this.defaultRoundTo === this.defaultIntervalMinutes ? 'rounding' : 'no-rounding', options: [
|
|
121
|
+
{ value: 'no-rounding', label: 'Default', description: 'Time slots will be rounded to the nearest quarter-hour.' },
|
|
122
122
|
{
|
|
123
123
|
value: 'rounding',
|
|
124
124
|
label: 'Interval rounding',
|
|
125
|
-
description: 'Time
|
|
125
|
+
description: 'Time slots will begin at times rounded to the interval value.',
|
|
126
126
|
},
|
|
127
127
|
] })))));
|
|
128
128
|
}
|
|
@@ -185,18 +185,18 @@ export class NylasTimeslotInterval {
|
|
|
185
185
|
"mutable": false,
|
|
186
186
|
"complexType": {
|
|
187
187
|
"original": "number",
|
|
188
|
-
"resolved": "number",
|
|
188
|
+
"resolved": "number | undefined",
|
|
189
189
|
"references": {}
|
|
190
190
|
},
|
|
191
191
|
"required": false,
|
|
192
|
-
"optional":
|
|
192
|
+
"optional": true,
|
|
193
193
|
"docs": {
|
|
194
194
|
"tags": [],
|
|
195
195
|
"text": "The event duration in minutes."
|
|
196
196
|
},
|
|
197
197
|
"attribute": "event-duration-minutes",
|
|
198
198
|
"reflect": false,
|
|
199
|
-
"defaultValue": "this.selectedConfiguration?.availability?.duration_minutes
|
|
199
|
+
"defaultValue": "this.selectedConfiguration?.availability?.duration_minutes"
|
|
200
200
|
},
|
|
201
201
|
"defaultIntervalMinutes": {
|
|
202
202
|
"type": "number",
|
|
@@ -214,7 +214,7 @@ export class NylasTimeslotInterval {
|
|
|
214
214
|
},
|
|
215
215
|
"attribute": "default-interval-minutes",
|
|
216
216
|
"reflect": false,
|
|
217
|
-
"defaultValue": "this.selectedConfiguration?.availability?.interval_minutes ?? this.eventDurationMinutes"
|
|
217
|
+
"defaultValue": "this.selectedConfiguration?.availability?.interval_minutes ?? this.eventDurationMinutes ?? 10"
|
|
218
218
|
},
|
|
219
219
|
"defaultRoundTo": {
|
|
220
220
|
"type": "number",
|
|
@@ -278,8 +278,8 @@ export class NylasTimeslotInterval {
|
|
|
278
278
|
"capture": false,
|
|
279
279
|
"passive": false
|
|
280
280
|
}, {
|
|
281
|
-
"name": "
|
|
282
|
-
"method": "
|
|
281
|
+
"name": "nylasFormRadioChanged",
|
|
282
|
+
"method": "nylasFormRadioChangedHandler",
|
|
283
283
|
"target": undefined,
|
|
284
284
|
"capture": false,
|
|
285
285
|
"passive": false
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nylas-timeslot-interval.js","sourceRoot":"","sources":["../../../../src/components/scheduler-editor/nylas-timeslot-interval/nylas-timeslot-interval.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAEhE,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtC,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AAI9H,MAAM,sBAAsB,GAAG,EAAE,CAAC;AAkBlC,MAAM,OAAO,qBAAqB;;;oBAST,iBAAiB;oCAKD,IAAI,CAAC,qBAAqB,EAAE,YAAY,EAAE,gBAAgB,IAAI,CAAC;sCAG7D,IAAI,CAAC,qBAAqB,EAAE,YAAY,EAAE,gBAAgB,IAAI,IAAI,CAAC,oBAAoB;8BAI9F,IAAI,CAAC,qBAAqB,EAAE,YAAY,EAAE,QAAQ,IAAI,SAAS;gCAU7D,IAAI,CAAC,sBAAsB;+BAK3B,IAAI,CAAC,cAAc,IAAI,IAAI,CAAC,cAAc,KAAK,IAAI,CAAC,sBAAsB,CAAC,CAAC,CAAC,IAAI,CAA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,IAAI,EAAC,kBAAkB;;wBAEzC;4BACE,kEAAW,IAAI,EAAC,cAAc,GAAG;4BACjC,6DAAM,IAAI,EAAC,iBAAiB,0EAA2E,CACrF,CACf;oBACP,2EACE,IAAI,EAAC,qBAAqB,EAC1B,oBAAoB,EAAE,IAAI,CAAC,cAAc,IAAI,IAAI,CAAC,cAAc,KAAK,IAAI,CAAC,sBAAsB,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,aAAa,EAC7H,OAAO,EAAE;4BACP,EAAE,KAAK,EAAE,aAAa,EAAE,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,yDAAyD,EAAE;4BAClH;gCACE,KAAK,EAAE,UAAU;gCACjB,KAAK,EAAE,mBAAmB;gCAC1B,WAAW,EAAE,+DAA+D;6BAC7E;yBACF,GACD,CACE,CACF,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF;AA/DC;IALC,iBAAiB,CAA2G;QAC3H,IAAI,EAAE,yBAAyB;QAC/B,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,CAAC,uCAAuC,EAAE,uBAAuB,CAAC,CAAC,CAAC;QAC3F,iBAAiB,EAAE,IAAI;KACxB,CAAC;;;;mDA+DD","sourcesContent":["import { RegisterComponent } from '@/common/register-component';\nimport { NylasSchedulerConfigConnector } from '@/connector/nylas-scheduler-config-connector';\nimport { debug } from '@/utils/utils';\nimport { AttachInternals, Component, Element, Event, EventEmitter, Host, Listen, Prop, State, Watch, h } from '@stencil/core';\nimport { NylasSchedulerEditor } from '../nylas-scheduler-editor/nylas-scheduler-editor';\nimport { Configuration } from '@nylas/core';\n\nconst defaultRoundToMinustes = 15;\n/**\n * The `nylas-timeslot-interval` component is a UI component that allows users to set their time-slot interval preferences.\n * This component provides an option to set both `interval_minutes` and `round_to` in the configuration.\n *\n * @part nti - The timeslot interval container\n * @part nti__header - The header of the timeslot interval picker\n * @part nti__input-label - The input label of the timeslot interval picker\n * @part nti__dropdown - The dropdown container\n * @part nti__dropdown-button - The dropdown button\n * @part nti__dropdown-content - The dropdown content\n */\n@Component({\n tag: 'nylas-timeslot-interval',\n styleUrl: 'nylas-timeslot-interval.scss',\n shadow: true,\n formAssociated: true,\n})\nexport class NylasTimeslotInterval {\n @Element() host!: HTMLNylasTimeslotIntervalElement;\n /**\n * The selected config\n */\n @Prop() selectedConfiguration?: Configuration;\n /**\n * The name of the calendar picker.\n */\n @Prop() name: string = 'timeslot-picker';\n\n /**\n * The event duration in minutes.\n */\n @Prop() eventDurationMinutes: number = this.selectedConfiguration?.availability?.duration_minutes ?? 5; /**\n * The default interval minutes.\n */\n @Prop() defaultIntervalMinutes: number = this.selectedConfiguration?.availability?.interval_minutes ?? this.eventDurationMinutes;\n /**\n * The round to option in minutes as set in the configuration.\n */\n @Prop() defaultRoundTo?: number = this.selectedConfiguration?.availability?.round_to ?? undefined;\n\n /**\n * The element internals.\n */\n @AttachInternals() internals!: ElementInternals;\n\n /**\n * The selected interval minutes.\n */\n @State() selectedInterval: number = this.defaultIntervalMinutes;\n\n /**\n * The selected round to minutes.\n */\n @State() selectedRoundTo: boolean = this.defaultRoundTo && this.defaultRoundTo === this.defaultIntervalMinutes ? true : false;\n\n /**\n * This event is fired when the selected booking calendar changes.\n */\n @Event() valueChanged!: EventEmitter<{\n value: string;\n name: string;\n }>;\n\n /**\n * When a name prop is passed, stencil does not automatically set the name attribute on the host element.\n * Since this component is form-associated, the name attribute is required for form submission.\n * This is a workaround to ensure that the name attribute is set on the host element.\n */\n @Watch('name')\n elementNameChangedHandler(newValue: string) {\n debug('nylas-timeslot-interval', 'elementNameChangedHandler', newValue);\n this.host.setAttribute('name', newValue);\n }\n\n @Watch('selectedConfiguration')\n selectedConfigurationChangedHandler(newValue: Configuration) {\n debug('nylas-timeslot-interval', 'selectedConfigurationChangedHandler', newValue);\n this.defaultIntervalMinutes = newValue.availability?.interval_minutes ?? this.eventDurationMinutes;\n this.defaultRoundTo = newValue.availability?.round_to ?? undefined;\n this.selectedInterval = this.defaultIntervalMinutes;\n this.selectedRoundTo = this.defaultRoundTo && this.defaultRoundTo === this.defaultIntervalMinutes ? true : false;\n }\n\n // Lifecycle methods\n connectedCallback() {\n debug('nylas-timeslot-interval', 'connectedCallback');\n }\n\n disconnectedCallback() {\n debug('nylas-timeslot-interval', 'disconnectedCallback');\n }\n\n componentWillLoad() {\n debug('nylas-timeslot-interval', 'componentWillLoad');\n // See comment in the @Watch('name') decorator for more information.\n this.host.setAttribute('name', this.name);\n }\n\n componentDidLoad() {\n debug('nylas-timeslot-interval', 'componentDidLoad');\n }\n\n componentWillUpdate() {\n debug('nylas-timeslot-interval', 'componentWillUpdate');\n }\n\n componentDidUpdate() {\n debug('nylas-timeslot-interval', 'componentDidUpdate');\n }\n\n componentWillRender() {\n debug('nylas-timeslot-interval', 'componentWillRender');\n }\n\n componentDidRender() {\n debug('nylas-timeslot-interval', 'componentDidRender');\n }\n\n @Listen('nylasFormDropdownChanged')\n nylasFormDropdownChangedHandler(event: CustomEvent<{ value: string; name: string }>) {\n debug('nylas-timeslot-interval', 'nylasFormDropdownChangedHandler', event.detail);\n const value = event.detail.value;\n if (value === 'duration') {\n this.selectedInterval = this.eventDurationMinutes;\n } else {\n this.selectedInterval = parseInt(event.detail.value);\n }\n console.log('nylasFormDropdownChanged selectedRoundTo', this.selectedRoundTo);\n\n this.valueChanged.emit({\n value: JSON.stringify({\n interval: this.selectedInterval,\n roundTo: this.selectedRoundTo ? this.selectedInterval : defaultRoundToMinustes,\n }),\n name: this.name,\n });\n if (typeof this.internals.setFormValue === 'function') {\n this.internals.setFormValue(JSON.stringify({ interval: this.selectedInterval, roundTo: this.selectedRoundTo ? this.selectedInterval : defaultRoundToMinustes }), this.name);\n }\n }\n\n @Listen('radioSelectionChanged')\n radioSelectionChangedHandler(event: CustomEvent<{ value: string; name: string }>) {\n debug('nylas-timeslot-interval', 'radioSelectionChangedHandler', event.detail);\n const value = event.detail.value;\n if (value === 'no-rounding') {\n this.selectedRoundTo = false;\n } else {\n this.selectedRoundTo = true;\n }\n console.log('selectedRoundTo', this.selectedRoundTo);\n\n this.valueChanged.emit({\n value: JSON.stringify({\n interval: this.selectedInterval,\n roundTo: this.selectedRoundTo ? this.selectedInterval : defaultRoundToMinustes,\n }),\n name: this.name,\n });\n if (typeof this.internals.setFormValue === 'function') {\n this.internals.setFormValue(JSON.stringify({ interval: this.selectedInterval, roundTo: this.selectedRoundTo ? this.selectedInterval : defaultRoundToMinustes }), this.name);\n }\n }\n\n @RegisterComponent<NylasTimeslotInterval, NylasSchedulerConfigConnector, Exclude<NylasSchedulerEditor['stores'], undefined>>({\n name: 'nylas-timeslot-interval',\n stateToProps: new Map([['schedulerConfig.selectedConfiguration', 'selectedConfiguration']]),\n fireRegisterEvent: true,\n })\n render() {\n const intervalPreferenceOptions = [\n { value: 'duration', label: 'Length of the booking' },\n { value: '5', label: '5 mins' },\n { value: '10', label: '10 mins' },\n { value: '15', label: '15 mins' },\n { value: '20', label: '20 mins' },\n { value: '30', label: '30 mins' },\n { value: '45', label: '45 mins' },\n { value: '60', label: '60 mins' },\n ];\n\n return (\n <Host>\n <div class=\"nylas-timeslot-interval\" part=\"nti\">\n <div class=\"header\" part=\"nti__header\">\n <h3>Time-slot interval preferences</h3>\n <p>Choose your interval preference for time-slots.</p>\n </div>\n\n <div class=\"nylas-timeslot-interval__dropdown\">\n <span class=\"label\" part=\"nti__input-label\">\n Select interval preference\n <tooltip-component>\n <info-icon slot=\"tooltip-icon\" />\n <span slot=\"tooltip-content\">Set the interval preference for the time-slots.</span>\n </tooltip-component>\n </span>\n <select-dropdown\n name=\"booking-calendar\"\n options={intervalPreferenceOptions}\n withSearch={false}\n exportparts=\"sd_dropdown: nti__dropdown, sd_dropdown-button: nti__dropdown-button, sd_dropdown-content: nti__dropdown-content\"\n defaultSelectedOption={\n this.defaultIntervalMinutes == this.eventDurationMinutes\n ? intervalPreferenceOptions[0]\n : intervalPreferenceOptions.find(op => op.value == this.defaultIntervalMinutes.toString()) ?? intervalPreferenceOptions[0]\n }\n />\n <span class=\"label\" part=\"nti__input-label\">\n Select the type of time-slot rounding\n <tooltip-component>\n <info-icon slot=\"tooltip-icon\" />\n <span slot=\"tooltip-content\">Select if you want to round the time slots to the nearest interval.</span>\n </tooltip-component>\n </span>\n <radio-button-group\n name=\"interval-preference\"\n defaultSelectedValue={this.defaultRoundTo && this.defaultRoundTo === this.defaultIntervalMinutes ? 'rounding' : 'no-rounding'}\n options={[\n { value: 'no-rounding', label: 'Default', description: 'Time-slots will be rounded to the nearest quarter-hour.' },\n {\n value: 'rounding',\n label: 'Interval rounding',\n description: 'Time-slots will begin at times rounded to the interval value.',\n },\n ]}\n />\n </div>\n </div>\n </Host>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"nylas-timeslot-interval.js","sourceRoot":"","sources":["../../../../src/components/scheduler-editor/nylas-timeslot-interval/nylas-timeslot-interval.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAEhE,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtC,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AAI9H,MAAM,sBAAsB,GAAG,EAAE,CAAC;AAkBlC,MAAM,OAAO,qBAAqB;;;oBAST,iBAAiB;oCAKA,IAAI,CAAC,qBAAqB,EAAE,YAAY,EAAE,gBAAgB;sCAGzD,IAAI,CAAC,qBAAqB,EAAE,YAAY,EAAE,gBAAgB,IAAI,IAAI,CAAC,oBAAoB,I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EAAE,CAAC,KAAK,IAAI,IAAI,CAAC,sBAAsB,CAAC,QAAQ,EAAE,CAAC,IAAI,yBAAyB,CAAC,CAAC,CAAC,GAE9H;oBACF,6DAAM,IAAI,EAAC,OAAO,EAAC,KAAK,EAAC,OAAO,EAAC,IAAI,EAAC,kBAAkB;;wBAEtD;4BACE,kEAAW,IAAI,EAAC,cAAc,GAAG;4BACjC,6DAAM,IAAI,EAAC,iBAAiB,0EAA2E,CACrF,CACf;oBACP,2EACE,IAAI,EAAC,qBAAqB,EAC1B,oBAAoB,EAAE,IAAI,CAAC,cAAc,IAAI,IAAI,CAAC,cAAc,KAAK,IAAI,CAAC,sBAAsB,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,aAAa,EAC7H,OAAO,EAAE;4BACP,EAAE,KAAK,EAAE,aAAa,EAAE,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,yDAAyD,EAAE;4BAClH;gCACE,KAAK,EAAE,UAAU;gCACjB,KAAK,EAAE,mBAAmB;gCAC1B,WAAW,EAAE,+DAA+D;6BAC7E;yBACF,GACD,CACE,CACF,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF;AA3DC;IALC,iBAAiB,CAA2G;QAC3H,IAAI,EAAE,yBAAyB;QAC/B,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,CAAC,uCAAuC,EAAE,uBAAuB,CAAC,CAAC,CAAC;QAC3F,iBAAiB,EAAE,IAAI;KACxB,CAAC;;;;mDA2DD","sourcesContent":["import { RegisterComponent } from '@/common/register-component';\nimport { NylasSchedulerConfigConnector } from '@/connector/nylas-scheduler-config-connector';\nimport { debug } from '@/utils/utils';\nimport { AttachInternals, Component, Element, Event, EventEmitter, Host, Listen, Prop, State, Watch, h } from '@stencil/core';\nimport { NylasSchedulerEditor } from '../nylas-scheduler-editor/nylas-scheduler-editor';\nimport { Configuration } from '@nylas/core';\n\nconst defaultRoundToMinustes = 15;\n/**\n * The `nylas-timeslot-interval` component allows users to set their time slot interval preferences.\n * This component provides an option to set both `interval_minutes` and `round_to` in the configuration.\n *\n * @part nti - The timeslot interval container\n * @part nti__header - The header of the timeslot interval picker\n * @part nti__input-label - The input label of the timeslot interval picker\n * @part nti__dropdown - The dropdown container\n * @part nti__dropdown-button - The dropdown button\n * @part nti__dropdown-content - The dropdown content\n */\n@Component({\n tag: 'nylas-timeslot-interval',\n styleUrl: 'nylas-timeslot-interval.scss',\n shadow: true,\n formAssociated: true,\n})\nexport class NylasTimeslotInterval {\n @Element() host!: HTMLNylasTimeslotIntervalElement;\n /**\n * The selected config\n */\n @Prop() selectedConfiguration?: Configuration;\n /**\n * The name of the calendar picker.\n */\n @Prop() name: string = 'timeslot-picker';\n\n /**\n * The event duration in minutes.\n */\n @Prop() eventDurationMinutes?: number = this.selectedConfiguration?.availability?.duration_minutes; /**\n * The default interval minutes.\n */\n @Prop() defaultIntervalMinutes: number = this.selectedConfiguration?.availability?.interval_minutes ?? this.eventDurationMinutes ?? 10;\n /**\n * The round to option in minutes as set in the configuration.\n */\n @Prop() defaultRoundTo?: number = this.selectedConfiguration?.availability?.round_to ?? undefined;\n\n /**\n * The element internals.\n */\n @AttachInternals() internals!: ElementInternals;\n\n /**\n * The selected interval minutes.\n */\n @State() selectedInterval: number = this.defaultIntervalMinutes;\n\n /**\n * The selected round to minutes.\n */\n @State() selectedRoundTo: boolean = this.defaultRoundTo && this.defaultRoundTo === this.defaultIntervalMinutes ? true : false;\n\n /**\n * This event is fired when the selected booking calendar changes.\n */\n @Event() valueChanged!: EventEmitter<{\n value: string;\n name: string;\n }>;\n\n /**\n * When a name prop is passed, stencil does not automatically set the name attribute on the host element.\n * Since this component is form-associated, the name attribute is required for form submission.\n * This is a workaround to ensure that the name attribute is set on the host element.\n */\n @Watch('name')\n elementNameChangedHandler(newValue: string) {\n debug('nylas-timeslot-interval', 'elementNameChangedHandler', newValue);\n this.host.setAttribute('name', newValue);\n }\n\n @Watch('selectedConfiguration')\n selectedConfigurationChangedHandler(newValue: Configuration) {\n debug('nylas-timeslot-interval', 'selectedConfigurationChangedHandler', newValue);\n this.defaultIntervalMinutes = newValue.availability?.interval_minutes ?? this.eventDurationMinutes ?? 10;\n this.defaultRoundTo = newValue.availability?.round_to ?? undefined;\n this.selectedInterval = this.defaultIntervalMinutes;\n this.selectedRoundTo = this.defaultRoundTo && this.defaultRoundTo === this.defaultIntervalMinutes ? true : false;\n }\n\n // Lifecycle methods\n connectedCallback() {\n debug('nylas-timeslot-interval', 'connectedCallback');\n }\n\n disconnectedCallback() {\n debug('nylas-timeslot-interval', 'disconnectedCallback');\n }\n\n componentWillLoad() {\n debug('nylas-timeslot-interval', 'componentWillLoad');\n // See comment in the @Watch('name') decorator for more information.\n this.host.setAttribute('name', this.name);\n }\n\n componentDidLoad() {\n debug('nylas-timeslot-interval', 'componentDidLoad');\n }\n\n componentWillUpdate() {\n debug('nylas-timeslot-interval', 'componentWillUpdate');\n }\n\n componentDidUpdate() {\n debug('nylas-timeslot-interval', 'componentDidUpdate');\n }\n\n componentWillRender() {\n debug('nylas-timeslot-interval', 'componentWillRender');\n }\n\n componentDidRender() {\n debug('nylas-timeslot-interval', 'componentDidRender');\n }\n\n @Listen('nylasFormDropdownChanged')\n nylasFormDropdownChangedHandler(event: CustomEvent<{ value: string; name: string }>) {\n debug('nylas-timeslot-interval', 'nylasFormDropdownChangedHandler', event.detail);\n const value = event.detail.value;\n if (value === 'duration') {\n this.selectedInterval = this.eventDurationMinutes ?? 10;\n } else {\n this.selectedInterval = parseInt(event.detail.value);\n }\n console.log('nylasFormDropdownChanged selectedRoundTo', this.selectedRoundTo);\n\n this.valueChanged.emit({\n value: JSON.stringify({\n interval: this.selectedInterval,\n roundTo: this.selectedRoundTo ? this.selectedInterval : defaultRoundToMinustes,\n }),\n name: this.name,\n });\n if (typeof this.internals.setFormValue === 'function') {\n this.internals.setFormValue(JSON.stringify({ interval: this.selectedInterval, roundTo: this.selectedRoundTo ? this.selectedInterval : defaultRoundToMinustes }), this.name);\n }\n }\n\n @Listen('nylasFormRadioChanged')\n nylasFormRadioChangedHandler(event: CustomEvent<{ value: string; name: string }>) {\n debug('nylas-timeslot-interval', 'nylasFormRadioChangedHandler', event.detail);\n const value = event.detail.value;\n if (value === 'no-rounding') {\n this.selectedRoundTo = false;\n } else {\n this.selectedRoundTo = true;\n }\n console.log('selectedRoundTo', this.selectedRoundTo);\n\n this.valueChanged.emit({\n value: JSON.stringify({\n interval: this.selectedInterval,\n roundTo: this.selectedRoundTo ? this.selectedInterval : defaultRoundToMinustes,\n }),\n name: this.name,\n });\n if (typeof this.internals.setFormValue === 'function') {\n this.internals.setFormValue(JSON.stringify({ interval: this.selectedInterval, roundTo: this.selectedRoundTo ? this.selectedInterval : defaultRoundToMinustes }), this.name);\n }\n }\n\n @RegisterComponent<NylasTimeslotInterval, NylasSchedulerConfigConnector, Exclude<NylasSchedulerEditor['stores'], undefined>>({\n name: 'nylas-timeslot-interval',\n stateToProps: new Map([['schedulerConfig.selectedConfiguration', 'selectedConfiguration']]),\n fireRegisterEvent: true,\n })\n render() {\n const intervalPreferenceOptions = [\n { value: 'duration', label: 'Length of the booking' },\n { value: '5', label: '5 mins' },\n { value: '10', label: '10 mins' },\n { value: '15', label: '15 mins' },\n { value: '20', label: '20 mins' },\n { value: '30', label: '30 mins' },\n { value: '45', label: '45 mins' },\n { value: '60', label: '60 mins' },\n ];\n\n return (\n <Host>\n <div class=\"nylas-timeslot-interval\" part=\"nti\">\n <div class=\"header\" part=\"nti__header\">\n <h3>Time slot settings</h3>\n <p>Manage time slot settings.</p>\n </div>\n\n <div class=\"nylas-timeslot-interval__dropdown\">\n <span class=\"label\" part=\"nti__input-label\">\n Select a time slot interval.\n </span>\n <select-dropdown\n name=\"booking-calendar\"\n options={intervalPreferenceOptions}\n withSearch={false}\n exportparts=\"sd_dropdown: nti__dropdown, sd_dropdown-button: nti__dropdown-button, sd_dropdown-content: nti__dropdown-content\"\n defaultSelectedOption={\n this.defaultIntervalMinutes == this.eventDurationMinutes\n ? intervalPreferenceOptions[0]\n : intervalPreferenceOptions.find(op => op.value == this.defaultIntervalMinutes.toString()) ?? intervalPreferenceOptions[0]\n }\n />\n <span slot=\"label\" class=\"label\" part=\"nti__input-label\">\n Select the time slot rounding type\n <tooltip-component>\n <info-icon slot=\"tooltip-icon\" />\n <span slot=\"tooltip-content\">Select if you want to round the time slots to the nearest interval.</span>\n </tooltip-component>\n </span>\n <radio-button-group\n name=\"interval-preference\"\n defaultSelectedValue={this.defaultRoundTo && this.defaultRoundTo === this.defaultIntervalMinutes ? 'rounding' : 'no-rounding'}\n options={[\n { value: 'no-rounding', label: 'Default', description: 'Time slots will be rounded to the nearest quarter-hour.' },\n {\n value: 'rounding',\n label: 'Interval rounding',\n description: 'Time slots will begin at times rounded to the interval value.',\n },\n ]}\n />\n </div>\n </div>\n </Host>\n );\n }\n}\n"]}
|
|
@@ -73,16 +73,17 @@ export class NylasSchedulerConfigAPIConnector {
|
|
|
73
73
|
}
|
|
74
74
|
return dataResponse(response.data);
|
|
75
75
|
}
|
|
76
|
-
async getConfigurations() {
|
|
76
|
+
async getConfigurations(cursor) {
|
|
77
77
|
if (!this.nylasApiRequest) {
|
|
78
78
|
console.warn('Nylas API Request is not initialized');
|
|
79
79
|
return dataResponse(null, {
|
|
80
80
|
message: 'Error fetching configurations: Nylas API Request is not initialized',
|
|
81
81
|
});
|
|
82
82
|
}
|
|
83
|
+
const limit = 50;
|
|
83
84
|
const [response, error] = await this.nylasApiRequest.request({
|
|
84
85
|
method: 'GET',
|
|
85
|
-
path: `scheduling/configurations`,
|
|
86
|
+
path: `scheduling/configurations?limit=${limit}${cursor ? `&page_token=${cursor}` : ''}`,
|
|
86
87
|
});
|
|
87
88
|
if (error) {
|
|
88
89
|
return dataResponse(null, {
|
|
@@ -95,6 +96,7 @@ export class NylasSchedulerConfigAPIConnector {
|
|
|
95
96
|
});
|
|
96
97
|
}
|
|
97
98
|
this.nylasSchedulerConfigStore.state.configurations = response.data;
|
|
99
|
+
this.nylasSchedulerConfigStore.state.listConfigurationsNextCursor = response.next_cursor || null;
|
|
98
100
|
return dataResponse(response.data);
|
|
99
101
|
}
|
|
100
102
|
async createConfiguration(configuration) {
|