@nylas/web-elements 2.5.8 → 2.5.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/dist/cdn/nylas-scheduler-editor/nylas-scheduler-editor.es.js +1310 -1310
  2. package/dist/cdn/nylas-scheduling/nylas-scheduling.es.js +1 -1
  3. package/dist/cjs/google-logo-icon.microsoft-logo-icon.nylas-editor-tabs.nylas-editor-tabs-group.nylas-list-configurations.nylas-select-event-type.entry.cjs.js.map +1 -1
  4. package/dist/cjs/google-logo-icon_6.cjs.entry.js +8 -7
  5. package/dist/cjs/google-logo-icon_6.cjs.entry.js.map +1 -1
  6. package/dist/cjs/nylas-scheduler-editor.cjs.entry.js +1 -1
  7. package/dist/cjs/nylas-scheduling.cjs.entry.js +1 -1
  8. package/dist/cjs/{version-COZSykqO.js → version-CN5nqWgI.js} +3 -3
  9. package/dist/cjs/{version-COZSykqO.js.map → version-CN5nqWgI.js.map} +1 -1
  10. package/dist/collection/components/scheduler-editor/nylas-editor-tabs/nylas-editor-tabs.js +7 -6
  11. package/dist/collection/components/scheduler-editor/nylas-editor-tabs/nylas-editor-tabs.js.map +1 -1
  12. package/dist/collection/version.js +1 -1
  13. package/dist/collection/version.js.map +1 -1
  14. package/dist/components/nylas-editor-tabs-group.js +1 -1
  15. package/dist/components/nylas-editor-tabs.js +1 -1
  16. package/dist/components/nylas-scheduler-editor.js +3 -3
  17. package/dist/components/nylas-scheduling.js +1 -1
  18. package/dist/components/{p-DC7TgSr7.js → p-2vIl9-lT.js} +10 -9
  19. package/dist/components/p-2vIl9-lT.js.map +1 -0
  20. package/dist/components/{p-Bkt_Yg_U.js → p-BfwqDqHx.js} +3 -3
  21. package/dist/components/{p-Bkt_Yg_U.js.map → p-BfwqDqHx.js.map} +1 -1
  22. package/dist/components/{p-Bx4lojq9.js → p-DwzjmWk7.js} +3 -3
  23. package/dist/components/{p-Bx4lojq9.js.map → p-DwzjmWk7.js.map} +1 -1
  24. package/dist/esm/google-logo-icon.microsoft-logo-icon.nylas-editor-tabs.nylas-editor-tabs-group.nylas-list-configurations.nylas-select-event-type.entry.js.map +1 -1
  25. package/dist/esm/google-logo-icon_6.entry.js +8 -7
  26. package/dist/esm/google-logo-icon_6.entry.js.map +1 -1
  27. package/dist/esm/nylas-scheduler-editor.entry.js +1 -1
  28. package/dist/esm/nylas-scheduling.entry.js +1 -1
  29. package/dist/esm/{version-CwWcFRQ4.js → version-zgIeli_M.js} +3 -3
  30. package/dist/esm/{version-CwWcFRQ4.js.map → version-zgIeli_M.js.map} +1 -1
  31. package/dist/nylas-web-elements/google-logo-icon.microsoft-logo-icon.nylas-editor-tabs.nylas-editor-tabs-group.nylas-list-configurations.nylas-select-event-type.entry.esm.js.map +1 -1
  32. package/dist/nylas-web-elements/nylas-web-elements.esm.js +1 -1
  33. package/dist/nylas-web-elements/{p-ebdd566e.entry.js → p-6aa41c34.entry.js} +2 -2
  34. package/dist/nylas-web-elements/p-acd75a32.entry.js +2 -0
  35. package/dist/nylas-web-elements/p-acd75a32.entry.js.map +1 -0
  36. package/dist/nylas-web-elements/{p-eb7101dd.entry.js → p-ec243a08.entry.js} +2 -2
  37. package/dist/nylas-web-elements/{p-CwWcFRQ4.js → p-zgIeli_M.js} +2 -2
  38. package/dist/nylas-web-elements/{p-CwWcFRQ4.js.map → p-zgIeli_M.js.map} +1 -1
  39. package/dist/types/version.d.ts +1 -1
  40. package/package.json +3 -3
  41. package/dist/components/p-DC7TgSr7.js.map +0 -1
  42. package/dist/nylas-web-elements/p-942c1486.entry.js +0 -2
  43. package/dist/nylas-web-elements/p-942c1486.entry.js.map +0 -1
  44. /package/dist/nylas-web-elements/{p-ebdd566e.entry.js.map → p-6aa41c34.entry.js.map} +0 -0
  45. /package/dist/nylas-web-elements/{p-eb7101dd.entry.js.map → p-ec243a08.entry.js.map} +0 -0
@@ -3,7 +3,7 @@
3
3
  var index = require('./index-9TuL48qE.js');
4
4
  var registerComponent = require('./register-component-DjG8kzjz.js');
5
5
  var utils = require('./utils-BDriE9YY.js');
6
- var version = require('./version-COZSykqO.js');
6
+ var version = require('./version-CN5nqWgI.js');
7
7
  var feedbackSync = require('./feedbackSync-Bcx7mZ9-.js');
8
8
 
9
9
  const iconCss$1 = ".sc-google-logo-icon-h{display:flex}";
@@ -254,11 +254,12 @@ const NylasEditorTabs = class {
254
254
  const partAvailabilityCalendars = participantCalendars?.[p.email] ?? p.availability?.calendar_ids ?? ['primary'];
255
255
  const isPartAvailabilityCalendarsPrimaryOnly = partAvailabilityCalendars.length === 1 && partAvailabilityCalendars[0] === 'primary';
256
256
  const partGrantId = p.grant_id || this.selectedConfiguration?.participants?.find(sp => sp.email === p.email)?.grant_id;
257
+ const partHasCustomOpenHours = Array.isArray(participantOpenHours?.[p.email]) && participantOpenHours[p.email].length > 0;
257
258
  return {
258
259
  ...p,
259
260
  ...(partGrantId ? { grant_id: partGrantId } : {}),
260
261
  timezone,
261
- availability: p.availability
262
+ availability: p.availability || partHasCustomOpenHours
262
263
  ? {
263
264
  calendar_ids: isPartAvailabilityCalendarsPrimaryOnly && typeof partBooking !== 'undefined' ? [partBooking?.calendar_id] : partAvailabilityCalendars,
264
265
  open_hours: participantOpenHours?.[p.email] ?? p.availability?.open_hours ?? [],
@@ -783,10 +784,10 @@ const NylasEditorTabs = class {
783
784
  }
784
785
  render() {
785
786
  utils.debug('[nylas-editor-tabs]', 'render', this.formState);
786
- return (index.h(index.Host, { key: '53e8f207370316a20260e8c9d5a62546efa70c22' }, index.h("nylas-notification", { key: '3dba6d5e4d6549d7c7afc84543a7de36b5e9565a' }), index.h("form", { key: 'b159d7794cdd2b4747df5b1eb971cc949599d56f', onSubmit: this.formSubmissionHandler, class: "scheduler-editor", ref: el => (this.formRef = el), noValidate: true }, this.mode === 'app' ? (index.h("div", { class: "form-contents", part: "editor__form-contents net__form-contents" }, index.h("div", { class: "tabs", part: "editor__tabs net__tabs" }, index.h("button", { name: Tab.EventInfo, class: { tab: true, active: this.activeTab == Tab.EventInfo, hide: this.hideTab(Tab.EventInfo) }, part: "editortab__event-info net__tab-event-info", onClick: e => this.setActiveTab(e, Tab.EventInfo) }, index.h("calendar-info-icon", { width: "16", height: "16" }), utils.instance.t('eventInfoTab')), index.h("button", { name: Tab.Availability, class: { tab: true, active: this.activeTab == Tab.Availability, hide: this.hideTab(Tab.Availability) }, part: "editortab__availability net__tab-availability", onClick: e => this.setActiveTab(e, Tab.Availability) }, index.h("calendar-patterns-icon", { width: "16", height: "16" }), utils.instance.t('availabilityTab')), index.h("button", { name: Tab.Participants, class: { tab: true, active: this.activeTab == Tab.Participants, hide: this.hideTab(Tab.Participants) }, part: "editortab__participants net__tab-participants", onClick: e => this.setActiveTab(e, Tab.Participants) }, index.h("people-icon", { width: "16", height: "16" }), utils.instance.t('participantsTab')), index.h("button", { name: Tab.BookingOptions, class: { tab: true, active: this.activeTab == Tab.BookingOptions, hide: this.hideTab(Tab.BookingOptions) }, part: "editortab__booking-options net__tab-booking-options", onClick: e => this.setActiveTab(e, Tab.BookingOptions) }, index.h("flow-icon", { width: "16", height: "16" }), utils.instance.t('bookingOptionsTab')), index.h("button", { name: Tab.BookingForm, class: { tab: true, active: this.activeTab == 'bookingForm', hide: this.hideTab(Tab.BookingForm) }, part: "editortab__booking-form net__tab-booking-form", onClick: e => this.setActiveTab(e, Tab.BookingForm) }, this.activeTab == Tab.BookingForm ? index.h("calendar-agenda-fill-icon", { width: "16", height: "16" }) : index.h("calendar-agenda-icon", { width: "16", height: "16" }), utils.instance.t('bookingFormTab')), index.h("button", { name: Tab.Communications, class: { tab: true, active: this.activeTab == 'communications', hide: this.hideTab(Tab.Communications) }, onClick: e => this.setActiveTab(e, Tab.Communications), part: "editortab__communications net__tab-communications" }, this.activeTab == Tab.Communications ? index.h("envelope-fill-icon", { width: "16", height: "16" }) : index.h("envelope-icon", { width: "16", height: "16" }), utils.instance.t('communicationsTab')), index.h("button", { name: Tab.PageStyles, class: { tab: true, active: this.activeTab == 'pageStyles', hide: this.hideTab(Tab.PageStyles) }, onClick: e => this.setActiveTab(e, Tab.PageStyles), part: "editortab__page-styles net__tab-page-styles" }, this.activeTab == Tab.PageStyles ? index.h("paintbrush-fill-icon", { width: "16", height: "16" }) : index.h("paintbrush-icon", { width: "16", height: "16" }), utils.instance.t('pageStylesTab'))), index.h("div", { class: {
787
+ return (index.h(index.Host, { key: 'bf708d7ec542c822eb749ffd4e8045ae9ae4d58e' }, index.h("nylas-notification", { key: 'da0ef8835e5a7c3c7a1e3eae096eea2ef7cdc744' }), index.h("form", { key: '7154f6f9f0e9bb735f1217864a985dc440347893', onSubmit: this.formSubmissionHandler, class: "scheduler-editor", ref: el => (this.formRef = el), noValidate: true }, this.mode === 'app' ? (index.h("div", { class: "form-contents", part: "editor__form-contents net__form-contents" }, index.h("div", { class: "tabs", part: "editor__tabs net__tabs" }, index.h("button", { name: Tab.EventInfo, class: { tab: true, active: this.activeTab == Tab.EventInfo, hide: this.hideTab(Tab.EventInfo) }, part: "editortab__event-info net__tab-event-info", onClick: e => this.setActiveTab(e, Tab.EventInfo) }, index.h("calendar-info-icon", { width: "16", height: "16" }), utils.instance.t('eventInfoTab')), index.h("button", { name: Tab.Availability, class: { tab: true, active: this.activeTab == Tab.Availability, hide: this.hideTab(Tab.Availability) }, part: "editortab__availability net__tab-availability", onClick: e => this.setActiveTab(e, Tab.Availability) }, index.h("calendar-patterns-icon", { width: "16", height: "16" }), utils.instance.t('availabilityTab')), index.h("button", { name: Tab.Participants, class: { tab: true, active: this.activeTab == Tab.Participants, hide: this.hideTab(Tab.Participants) }, part: "editortab__participants net__tab-participants", onClick: e => this.setActiveTab(e, Tab.Participants) }, index.h("people-icon", { width: "16", height: "16" }), utils.instance.t('participantsTab')), index.h("button", { name: Tab.BookingOptions, class: { tab: true, active: this.activeTab == Tab.BookingOptions, hide: this.hideTab(Tab.BookingOptions) }, part: "editortab__booking-options net__tab-booking-options", onClick: e => this.setActiveTab(e, Tab.BookingOptions) }, index.h("flow-icon", { width: "16", height: "16" }), utils.instance.t('bookingOptionsTab')), index.h("button", { name: Tab.BookingForm, class: { tab: true, active: this.activeTab == 'bookingForm', hide: this.hideTab(Tab.BookingForm) }, part: "editortab__booking-form net__tab-booking-form", onClick: e => this.setActiveTab(e, Tab.BookingForm) }, this.activeTab == Tab.BookingForm ? index.h("calendar-agenda-fill-icon", { width: "16", height: "16" }) : index.h("calendar-agenda-icon", { width: "16", height: "16" }), utils.instance.t('bookingFormTab')), index.h("button", { name: Tab.Communications, class: { tab: true, active: this.activeTab == 'communications', hide: this.hideTab(Tab.Communications) }, onClick: e => this.setActiveTab(e, Tab.Communications), part: "editortab__communications net__tab-communications" }, this.activeTab == Tab.Communications ? index.h("envelope-fill-icon", { width: "16", height: "16" }) : index.h("envelope-icon", { width: "16", height: "16" }), utils.instance.t('communicationsTab')), index.h("button", { name: Tab.PageStyles, class: { tab: true, active: this.activeTab == 'pageStyles', hide: this.hideTab(Tab.PageStyles) }, onClick: e => this.setActiveTab(e, Tab.PageStyles), part: "editortab__page-styles net__tab-page-styles" }, this.activeTab == Tab.PageStyles ? index.h("paintbrush-fill-icon", { width: "16", height: "16" }) : index.h("paintbrush-icon", { width: "16", height: "16" }), utils.instance.t('pageStylesTab'))), index.h("div", { class: {
787
788
  'tab-content': true,
788
789
  'fadeIn': this.loaded,
789
- }, part: "editor__tab-content net__tab-content" }, index.h(TabContents, { formState: this.formState, activeTab: this.activeTab, currentUser: this.currentUser, calendars: this.calendars, id: this.selectedConfiguration?.id ?? 'new', i18next: utils.instance, enableNotetaker: this.enableNotetaker, themeConfig: this.themeConfig })))) : (index.h("div", { class: "composable", key: this.selectedConfiguration?.id }, index.h("slot", null))), index.h("div", { key: '89c5898f878016e7f948d163abe29ca754009ecd', class: "footer", part: "editor__footer net__footer" }, index.h("div", { key: 'f03899ff4f65cc1d3ca1eccc741721e64b14f5b7', class: "preview", part: "editor__footer-preview net__footer-preview" }, this.enableUserFeedback && (index.h("button-component", { key: 'f16d904cb742a131095fa70c2348bec8c81e1f29', title: "Share your feedback", id: "report-issue", variant: 'basic', onClick: e => this.onFeedbackClick(e) }, index.h("feedback-icon", { key: '06e12b85432d63d275687a69dbd8c507d66408b6' })))), index.h("div", { key: 'd0f09f33a68578be3541cbd71f92f9f710701858', class: "buttons", part: "editor__footer-buttons net__footer-buttons" }, index.h("p", { key: '628ccfdddad773509ac6e73613c8e4879d627553', class: {
790
+ }, part: "editor__tab-content net__tab-content" }, index.h(TabContents, { formState: this.formState, activeTab: this.activeTab, currentUser: this.currentUser, calendars: this.calendars, id: this.selectedConfiguration?.id ?? 'new', i18next: utils.instance, enableNotetaker: this.enableNotetaker, themeConfig: this.themeConfig })))) : (index.h("div", { class: "composable", key: this.selectedConfiguration?.id }, index.h("slot", null))), index.h("div", { key: '9f8518398d98a211078b50c88f1c81315ed30328', class: "footer", part: "editor__footer net__footer" }, index.h("div", { key: 'cbf1648c8c98b4e48e43d21ba7d9031a329a4e10', class: "preview", part: "editor__footer-preview net__footer-preview" }, this.enableUserFeedback && (index.h("button-component", { key: 'a4f2c13221dade5425f1b59aa5274350a809ffc3', title: "Share your feedback", id: "report-issue", variant: 'basic', onClick: e => this.onFeedbackClick(e) }, index.h("feedback-icon", { key: 'f2f1fe27e3de4f09fe7eb00eede7f9abc90102c3' })))), index.h("div", { key: 'a740aaeccc0f929cfa67ef8c0c703513ec9138ec', class: "buttons", part: "editor__footer-buttons net__footer-buttons" }, index.h("p", { key: 'ded5a9bed46eb1063e0062080fbc2f1eb91510fa', class: {
790
791
  'unsaved-changes': this.hasUnsavedChanges && !this.changesSaved,
791
792
  'saved-changes': this.changesSaved,
792
793
  'error': this.error?.message !== '',
@@ -795,17 +796,17 @@ const NylasEditorTabs = class {
795
796
  ? utils.instance.t('unsavedChangesLabel')
796
797
  : this.error?.message == '' && this.changesSaved
797
798
  ? `${utils.instance.t('changesSavedLabel')}!`
798
- : ''), this.schedulerPreviewLink !== '' && this.action === 'edit' && (index.h("button-component", { key: 'cf3a48e6fd19209a8a87e30a7ab5639d439dbbc9', title: "Preview", type: "button", disabled: this.isLoading, clickHandler: event => {
799
+ : ''), this.schedulerPreviewLink !== '' && this.action === 'edit' && (index.h("button-component", { key: '335dcff1c0fa0e2049cf21f36e33427a9f30a8c1', title: "Preview", type: "button", disabled: this.isLoading, clickHandler: event => {
799
800
  event.preventDefault();
800
801
  const previewEvent = this.previewButtonClicked.emit(this.host);
801
802
  if (!previewEvent.defaultPrevented) {
802
803
  window.open(utils.parsePreviewLink(this.schedulerPreviewLink, this.selectedConfiguration), '_blank');
803
804
  }
804
- }, variant: 'basic' }, index.h("eye-icon", { key: '88a8aeafbefc9d21c5e2f10ebe43fd7308b7f2f0' }))), index.h("button-component", { key: '8377521f43f7050fd5b06fbee24e0c434d80bccc', type: "button", disabled: this.isLoading, clickHandler: event => {
805
+ }, variant: 'basic' }, index.h("eye-icon", { key: '2f8ef52ca16d73c357feb572c35d4f56f056a4d1' }))), index.h("button-component", { key: 'f56f62a0b795d5949cef307518b12ca9c7431cb5', type: "button", disabled: this.isLoading, clickHandler: event => {
805
806
  event.preventDefault();
806
807
  this.cancelButtonClick.emit();
807
808
  this.host.resetError();
808
- }, variant: 'basic', part: "editor__footer-cancel net__footer-cancel" }, utils.instance.t('cancelButton')), index.h("button-component", { key: '5f3393800e9a0499cc538fffdee07005aa15bdba', class: { 'save-changes': this.action === 'edit' }, type: "submit", disabled: this.isLoading, part: "editor__footer-cta, net__footer-cta" }, this.isLoading ? (index.h("span", null, utils.instance.t('savingButtonText'), index.h("loading-icon", null), ' ')) : this.action === 'create' ? (`${utils.instance.t('createButtonText')}`) : (`${utils.instance.t('saveChangesButtonText')}`))))), this.showFeedbackModal && index.h("nylas-feedback-form", { key: '4abad08be25f4ff177f564d54d701d53cce8bba3' })));
809
+ }, variant: 'basic', part: "editor__footer-cancel net__footer-cancel" }, utils.instance.t('cancelButton')), index.h("button-component", { key: 'c04d198a70b9214461d92c380089048febe6113a', class: { 'save-changes': this.action === 'edit' }, type: "submit", disabled: this.isLoading, part: "editor__footer-cta, net__footer-cta" }, this.isLoading ? (index.h("span", null, utils.instance.t('savingButtonText'), index.h("loading-icon", null), ' ')) : this.action === 'create' ? (`${utils.instance.t('createButtonText')}`) : (`${utils.instance.t('saveChangesButtonText')}`))))), this.showFeedbackModal && index.h("nylas-feedback-form", { key: '5c62eea9a45a9060762b43c7a328488653590979' })));
809
810
  }
810
811
  get host() { return index.getElement(this); }
811
812
  static get watchers() { return {