@nylas/react 1.1.0-canary.15 → 1.1.0-canary.17

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 (129) hide show
  1. package/dist/add-circle-icon_2.entry-936fd73b.cjs +1 -0
  2. package/dist/add-circle-icon_2.entry-ce6aaa1d.js +25 -0
  3. package/dist/{archive-icon_7.entry-ca8262ff.js → archive-icon_7.entry-60e900b6.js} +18 -18
  4. package/dist/{archive-icon_7.entry-25d8b2f0.cjs → archive-icon_7.entry-8c8317e9.cjs} +1 -1
  5. package/dist/{arrow-icon.entry-991ba7cd.js → arrow-icon.entry-057db95a.js} +2 -2
  6. package/dist/{arrow-icon.entry-01192ecf.cjs → arrow-icon.entry-2d4e9572.cjs} +1 -1
  7. package/dist/bold-icon_3.entry-557c6007.js +35 -0
  8. package/dist/{bold-icon_3.entry-e94dcf5b.cjs → bold-icon_3.entry-ba732761.cjs} +1 -1
  9. package/dist/{add-circle-icon_2.entry-3f834b47.js → button-component.entry-22d0ac2e.js} +5 -15
  10. package/dist/button-component.entry-385f9581.cjs +1 -0
  11. package/dist/{calendar-cancel-icon.entry-f646c147.js → calendar-cancel-icon.entry-820cf967.js} +5 -5
  12. package/dist/{calendar-cancel-icon.entry-9088fa8b.cjs → calendar-cancel-icon.entry-b2657caf.cjs} +1 -1
  13. package/dist/{calendar-check-icon_2.entry-a7e4d0e6.js → calendar-check-icon_2.entry-128a5d67.js} +9 -9
  14. package/dist/{calendar-check-icon_2.entry-4dc1391a.cjs → calendar-check-icon_2.entry-b13e7cbb.cjs} +1 -1
  15. package/dist/{calendar-icon.entry-1658930c.js → calendar-icon.entry-a43e6011.js} +5 -5
  16. package/dist/{calendar-icon.entry-1e2acd5c.cjs → calendar-icon.entry-d17d7cfb.cjs} +1 -1
  17. package/dist/calendar-info-icon_28.entry-b4f09bfe.cjs +1 -0
  18. package/dist/{calendar-info-icon_25.entry-493c5547.js → calendar-info-icon_28.entry-b71c23c5.js} +754 -828
  19. package/dist/{chevron-icon_3.entry-52b97043.cjs → chevron-icon_3.entry-4807a0b1.cjs} +1 -1
  20. package/dist/{chevron-icon_3.entry-b3c7eb44.js → chevron-icon_3.entry-e0796c69.js} +5 -5
  21. package/dist/{clock-icon_2.entry-882249ee.cjs → clock-icon_2.entry-267614c2.cjs} +1 -1
  22. package/dist/{clock-icon_2.entry-58f07042.js → clock-icon_2.entry-e959ae50.js} +7 -7
  23. package/dist/{constants-f34b9c6e-1da5094b.cjs → constants-f34b9c6e-ebc2e19c.cjs} +1 -1
  24. package/dist/{constants-f34b9c6e-628beaa8.js → constants-f34b9c6e-efe2836b.js} +1 -1
  25. package/dist/{document-refresh-icon.entry-b53316b4.js → document-refresh-icon.entry-b4c217df.js} +2 -2
  26. package/dist/{document-refresh-icon.entry-4f581bf4.cjs → document-refresh-icon.entry-b8850675.cjs} +1 -1
  27. package/dist/elements/index.d.ts +1 -0
  28. package/dist/{elements-dc5b338e-3284591d.cjs → elements-dc5b338e-a33785e3.cjs} +1 -1
  29. package/dist/{elements-dc5b338e-7abe37c6.js → elements-dc5b338e-b0a290ae.js} +1 -1
  30. package/dist/{focus-visible-e8093c16-d6612604.js → focus-visible-e8093c16-5f1ae916.js} +1 -1
  31. package/dist/{focus-visible-e8093c16-cb6c97b1.cjs → focus-visible-e8093c16-d2afb13d.cjs} +1 -1
  32. package/dist/{forward-icon_6.entry-e402ad1e.cjs → forward-icon_6.entry-0009e4f0.cjs} +3 -3
  33. package/dist/{forward-icon_6.entry-d54244f7.js → forward-icon_6.entry-53683e82.js} +9 -9
  34. package/dist/{globe-icon.entry-e83c79c2.js → globe-icon.entry-dbb47687.js} +4 -4
  35. package/dist/{globe-icon.entry-db7377d9.cjs → globe-icon.entry-df67eab8.cjs} +1 -1
  36. package/dist/google-logo-icon_4.entry-77f3b86e.js +454 -0
  37. package/dist/google-logo-icon_4.entry-c5db1be3.cjs +1 -0
  38. package/dist/index-53420959-16700a42.cjs +1 -0
  39. package/dist/index-53420959-f0c4f9af.js +5 -0
  40. package/dist/{index-2d032bec.js → index-5851f0a2.js} +816 -825
  41. package/dist/{index-6d9eeb53-91d36348.js → index-6d9eeb53-2f37342f.js} +2 -2
  42. package/dist/{index-6d9eeb53-f478270c.cjs → index-6d9eeb53-ded66877.cjs} +1 -1
  43. package/dist/{index-9c04361d.cjs → index-769f0fdd.cjs} +3 -3
  44. package/dist/{index.es-9cc0eb3c-ee2ebbe1.js → index.es-9cc0eb3c-2cf4632f.js} +1 -1
  45. package/dist/{index.es-9cc0eb3c-2242baf6.cjs → index.es-9cc0eb3c-e8de46e6.cjs} +1 -1
  46. package/dist/{info-icon_2.entry-74eb7415.js → info-icon_2.entry-c27ac645.js} +3 -3
  47. package/dist/{info-icon_2.entry-4b257e73.cjs → info-icon_2.entry-e355fb7d.cjs} +1 -1
  48. package/dist/{input-component.entry-6bb4a5e8.js → input-component.entry-a38a65da.js} +4 -4
  49. package/dist/{input-component.entry-3ef7ce2c.cjs → input-component.entry-ef2b397d.cjs} +1 -1
  50. package/dist/input-dropdown_2.entry-9e50060e.cjs +1 -0
  51. package/dist/{input-dropdown_2.entry-f71e4c01.js → input-dropdown_2.entry-ce1da1b3.js} +37 -26
  52. package/dist/loading-icon.entry-175aca19.cjs +1 -0
  53. package/dist/loading-icon.entry-4ab88ed8.js +15 -0
  54. package/dist/{mailbox-store-64b4ef7c-202f1afd.js → mailbox-store-64b4ef7c-47dac9aa.js} +2 -2
  55. package/dist/{mailbox-store-64b4ef7c-74f959be.cjs → mailbox-store-64b4ef7c-ebe84c96.cjs} +1 -1
  56. package/dist/nylas-booked-event-card_10.entry-6de99d57.cjs +1 -0
  57. package/dist/{nylas-booked-event-card_10.entry-ddfcff5e.js → nylas-booked-event-card_10.entry-ef9c2d62.js} +11 -11
  58. package/dist/{nylas-custom-booking-flow.entry-63ed387e.cjs → nylas-custom-booking-flow.entry-c59c1306.cjs} +1 -1
  59. package/dist/{nylas-custom-booking-flow.entry-a1f66d05.js → nylas-custom-booking-flow.entry-f31400e2.js} +2 -2
  60. package/dist/{nylas-form-card.entry-ea1153b9.js → nylas-form-card.entry-b189e066.js} +2 -2
  61. package/dist/{nylas-form-card.entry-6fece0ff.cjs → nylas-form-card.entry-bc048703.cjs} +1 -1
  62. package/dist/{nylas-if-state.entry-05f8f66f.js → nylas-if-state.entry-5bdf8669.js} +3 -3
  63. package/dist/{nylas-if-state.entry-b75320f0.cjs → nylas-if-state.entry-933c79e0.cjs} +1 -1
  64. package/dist/{nylas-list-folders.entry-edc61b97.cjs → nylas-list-folders.entry-5d1bef7f.cjs} +1 -1
  65. package/dist/{nylas-list-folders.entry-bd5a1b1d.js → nylas-list-folders.entry-f0e7ae4e.js} +3 -3
  66. package/dist/{nylas-list-threads.entry-79ad0944.cjs → nylas-list-threads.entry-3e300e7e.cjs} +1 -1
  67. package/dist/{nylas-list-threads.entry-f3cd80de.js → nylas-list-threads.entry-3f7451ad.js} +3 -3
  68. package/dist/{nylas-login.entry-68873357.cjs → nylas-login.entry-dbf9e11f.cjs} +1 -1
  69. package/dist/{nylas-login.entry-b3207e82.js → nylas-login.entry-e3b757a0.js} +7 -7
  70. package/dist/{nylas-mailbox-pagination.entry-2ef5b88a.cjs → nylas-mailbox-pagination.entry-0db12a01.cjs} +1 -1
  71. package/dist/{nylas-mailbox-pagination.entry-22c5b9ca.js → nylas-mailbox-pagination.entry-6c845a2a.js} +2 -2
  72. package/dist/{nylas-mailbox-toolbar-button.entry-f2fa3a8e.cjs → nylas-mailbox-toolbar-button.entry-553f041a.cjs} +1 -1
  73. package/dist/{nylas-mailbox-toolbar-button.entry-95bb58b5.js → nylas-mailbox-toolbar-button.entry-ec196947.js} +4 -4
  74. package/dist/{nylas-mailbox.entry-4ef7d18d.js → nylas-mailbox.entry-1552ad11.js} +7 -7
  75. package/dist/{nylas-mailbox.entry-4b1d320f.cjs → nylas-mailbox.entry-c0bbca56.cjs} +1 -1
  76. package/dist/{nylas-provider.entry-7f7e098a.js → nylas-provider.entry-6d286e92.js} +37 -37
  77. package/dist/{nylas-provider.entry-b629340a.cjs → nylas-provider.entry-d4bf23c2.cjs} +1 -1
  78. package/dist/{nylas-scheduler-editor.entry-19a29c4c.cjs → nylas-scheduler-editor.entry-00a71304.cjs} +2 -2
  79. package/dist/{nylas-scheduler-editor.entry-2d19593f.js → nylas-scheduler-editor.entry-caa1026b.js} +8 -7
  80. package/dist/{nylas-scheduling.entry-753cb746.js → nylas-scheduling.entry-19ff3d50.js} +9 -9
  81. package/dist/nylas-scheduling.entry-f1fb67d2.cjs +1 -0
  82. package/dist/{nylas-threads-refresh.entry-5a774ad7.js → nylas-threads-refresh.entry-6acf3c2b.js} +4 -4
  83. package/dist/{nylas-threads-refresh.entry-0a832631.cjs → nylas-threads-refresh.entry-bc4c10ea.cjs} +1 -1
  84. package/dist/{nylas-threads-search.entry-451c6d5c.js → nylas-threads-search.entry-82fa1504.js} +5 -5
  85. package/dist/{nylas-threads-search.entry-5b57688b.cjs → nylas-threads-search.entry-ee28712c.cjs} +1 -1
  86. package/dist/nylas-time-window-picker.entry-131f84b4.cjs +1 -0
  87. package/dist/nylas-time-window-picker.entry-3c45d82e.js +316 -0
  88. package/dist/{nylas-view-thread.entry-7b273955.cjs → nylas-view-thread.entry-0d9a4aa9.cjs} +1 -1
  89. package/dist/{nylas-view-thread.entry-e0af8998.js → nylas-view-thread.entry-695a7b0b.js} +6 -6
  90. package/dist/{play-icon_2.entry-58592b64.js → play-icon_2.entry-ab47588e.js} +3 -3
  91. package/dist/{play-icon_2.entry-5b22a7ca.cjs → play-icon_2.entry-b1167d3a.cjs} +1 -1
  92. package/dist/react.cjs +1 -1
  93. package/dist/react.js +41 -40
  94. package/dist/{refresh-icon.entry-876b8aea.cjs → refresh-icon.entry-28e3ade7.cjs} +1 -1
  95. package/dist/{refresh-icon.entry-90756bc6.js → refresh-icon.entry-43267155.js} +5 -5
  96. package/dist/{register-component-a5a9ca5d-8bede801.js → register-component-a5a9ca5d-538c35c3.js} +1 -1
  97. package/dist/{register-component-a5a9ca5d-1fbb27d2.cjs → register-component-a5a9ca5d-8b06415c.cjs} +1 -1
  98. package/dist/scheduler-config-store-4a50a03d-40e87f35.cjs +1 -0
  99. package/dist/{scheduler-config-store-ec3b6190-cbc40d60.js → scheduler-config-store-4a50a03d-4a2e2abf.js} +4 -3
  100. package/dist/{scheduler-store-f02ce045-1d93c571.js → scheduler-store-f02ce045-121c1e09.js} +1 -1
  101. package/dist/{scheduler-store-f02ce045-712c600c.cjs → scheduler-store-f02ce045-f11cfad9.cjs} +1 -1
  102. package/dist/{textarea-component.entry-3ea161d6.js → textarea-component.entry-1ec19adb.js} +4 -4
  103. package/dist/{textarea-component.entry-9d6b5cdc.cjs → textarea-component.entry-402a369b.cjs} +1 -1
  104. package/dist/{translate-icon.entry-04dde6b1.cjs → translate-icon.entry-59f4e190.cjs} +1 -1
  105. package/dist/{translate-icon.entry-be9c3401.js → translate-icon.entry-d412697e.js} +6 -6
  106. package/dist/{warning-icon.entry-347d77af.js → warning-icon.entry-3ee1f451.js} +5 -5
  107. package/dist/{warning-icon.entry-84121a43.cjs → warning-icon.entry-aa6b2c2c.cjs} +1 -1
  108. package/package.json +3 -3
  109. package/dist/add-circle-icon_2.entry-00dc2c13.cjs +0 -1
  110. package/dist/bold-icon_3.entry-81a3ff1e.js +0 -35
  111. package/dist/calendar-info-icon_25.entry-7513d798.cjs +0 -1
  112. package/dist/close-icon.entry-4a39816a.js +0 -15
  113. package/dist/close-icon.entry-f1166251.cjs +0 -1
  114. package/dist/google-logo-icon_4.entry-8818686b.js +0 -429
  115. package/dist/google-logo-icon_4.entry-fa65ae29.cjs +0 -1
  116. package/dist/index-53420959-41ed02ae.js +0 -5
  117. package/dist/index-53420959-a76f0327.cjs +0 -1
  118. package/dist/input-dropdown_2.entry-a87714fc.cjs +0 -1
  119. package/dist/loading-icon.entry-30724cb0.js +0 -15
  120. package/dist/loading-icon.entry-bb250f1c.cjs +0 -1
  121. package/dist/nylas-additional-participants.entry-567c7c2a.cjs +0 -1
  122. package/dist/nylas-additional-participants.entry-7961be04.js +0 -81
  123. package/dist/nylas-booked-event-card_10.entry-c2f889ba.cjs +0 -1
  124. package/dist/nylas-scheduling.entry-70454242.cjs +0 -1
  125. package/dist/people-icon.entry-c7fb7f6c.cjs +0 -1
  126. package/dist/people-icon.entry-de3fada0.js +0 -15
  127. package/dist/scheduler-config-store-ec3b6190-104df545.cjs +0 -1
  128. package/dist/toggle-switch.entry-10aa0c1a.cjs +0 -1
  129. package/dist/toggle-switch.entry-a08c1027.js +0 -25
@@ -1,5 +1,5 @@
1
- import { r as ne, h as g, c as We, d as T, H as $e, g as Rt, i as yn, q as bn, s as En, v as Tn, F as An, w as _n } from "./index-2d032bec.js";
2
- import { R as wn } from "./register-component-a5a9ca5d-8bede801.js";
1
+ import { r as ne, h as g, c as We, d as T, H as $e, g as Rt, i as yn, q as bn, s as En, v as Tn, F as An, w as _n } from "./index-5851f0a2.js";
2
+ import { R as wn } from "./register-component-a5a9ca5d-538c35c3.js";
3
3
  import "react";
4
4
  import "react-dom";
5
5
  const vn = ".sc-forward-icon-h{display:flex}", Sn = vn, Cn = class {
@@ -7,7 +7,7 @@ const vn = ".sc-forward-icon-h{display:flex}", Sn = vn, Cn = class {
7
7
  ne(this, t), this.width = "15", this.height = "15";
8
8
  }
9
9
  render() {
10
- return g("svg", { key: "4459922a9da41ee6755a6374ed801c99e78cc872", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "44eebaf7f76223a343560213b7aff4bae70a6387", d: "m1246.246 64-90.496 90.496 477.952 477.952h-590.848C467.878 632.448.038 1100.416.038 1675.392v109.056h128v-109.056c0-504.576 410.368-914.944 914.816-914.944h590.848l-477.952 478.08 90.496 90.496 632.448-632.576L1246.246 64Z", "fill-rule": "evenodd" }));
10
+ return g("svg", { key: "c4820cbfde5bdb6591754bb0d0448cf2176f30e4", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "511b0734c288d9057ccfaa357baed4b0622d3c47", d: "m1246.246 64-90.496 90.496 477.952 477.952h-590.848C467.878 632.448.038 1100.416.038 1675.392v109.056h128v-109.056c0-504.576 410.368-914.944 914.816-914.944h590.848l-477.952 478.08 90.496 90.496 632.448-632.576L1246.246 64Z", "fill-rule": "evenodd" }));
11
11
  }
12
12
  };
13
13
  Cn.style = Sn;
@@ -106,7 +106,7 @@ const Ln = ':host{display:grid;color:var(--nylas-color-primary-900)}.editor{posi
106
106
  }), this.editorEl.focus();
107
107
  }
108
108
  render() {
109
- return g($e, { key: "c8ab18162320c10834660c655141a985c36958ac" }, g("sp-theme", { key: "01a86b0ddef68c16b139cdb95bf3f9df102ead60", scale: "medium", color: "dark" }, g("div", { key: "280d8dfbee592023d7461e6691805a6e44e8837b", class: "editor", contentEditable: !0, ref: (t) => this.editorEl = t }, g("div", { key: "35437f24077f1e5a9b629bfca6437ec6740c8780", class: "toolbar", ref: (t) => this.toolbarEl = t, contentEditable: !1 }, g("sp-button", { key: "378551180f48beb175216d045acd4d65355f3234", quiet: !0, onClick: () => document.execCommand("bold") }, g("div", { key: "a7a6872cfc4d34939aaeba4e45e67d8ca1ac52ab", slot: "icon" }, g("bold-icon", { key: "198210356c76239162c2d44251845529b5765e04" })), g("div", { key: "6ecdf762f2a29a39bce8c49da6cc366594218c52", slot: "label" }, "Bold")), g("sp-button", { key: "6ee0821abd7462a9105f13228a4441ed302d0df9", quiet: !0, onClick: () => document.execCommand("underline") }, g("div", { key: "37745f4ee7e5bac2d4bba65d3682338590b49c88", slot: "icon" }, g("underline-icon", { key: "9b7a46dbf44378c001c16afca0e8c30e0b1ea12f" })), g("div", { key: "54e6ce111dcc82421b475040a0a85d26c648c1d4", slot: "label" }, "Underline")), g("sp-button", { key: "ae292c9f8f55a7ae82ddfaaa75ba9a045c80c02d", quiet: !0, onClick: () => document.execCommand("italic") }, g("div", { key: "fdfdf0265a51eeca44c72ec7de634f9c23a5a846", slot: "icon" }, g("italic-icon", { key: "6308247060d42eb21284e6687a0abc18cf63e32c" })), g("div", { key: "49487a1f0677fc394dd617abfdb645c56e441f55", slot: "label" }, "Italic")))), g("div", { key: "08b56206aef08fbc262ec615c1c593949ef05c82", class: "buttons" }, g("sp-button", { key: "f099e2091f8070adaf80cd9fd4299e53e25ef39b", onClick: this.sendComposer, class: "send" }, "Send"), g("sp-button", { key: "78c73f9aec9dd29a7b1360192ef190d20f0bb092", onClick: this.closeComposer, class: "close" }, "Close"))));
109
+ return g($e, { key: "272229753ac9d990a72c4e1d743b34d01d57d3e3" }, g("sp-theme", { key: "a43065734dff3bbda8163f9d39f381619020e603", scale: "medium", color: "dark" }, g("div", { key: "11d5f1e8d8c3e7debda04af54a2c6ef5c63b3260", class: "editor", contentEditable: !0, ref: (t) => this.editorEl = t }, g("div", { key: "6c936b9bfb1fdce1d8f073405bd80a582849e175", class: "toolbar", ref: (t) => this.toolbarEl = t, contentEditable: !1 }, g("sp-button", { key: "b6c5c51c52d707165367990fa76b5a80fc837936", quiet: !0, onClick: () => document.execCommand("bold") }, g("div", { key: "e8d07f19efe1bcbb1eb0efd69fe0566df8a656d3", slot: "icon" }, g("bold-icon", { key: "cd5c2e7b5883e1ff5c6d34106a0b4086ffb9b1d2" })), g("div", { key: "8efca1559b463fc356fe69d0bf7fc327f90ab846", slot: "label" }, "Bold")), g("sp-button", { key: "1d7703909feab13241fd75052946f198ad01d1b6", quiet: !0, onClick: () => document.execCommand("underline") }, g("div", { key: "ab1d89e8d5ebca33447274cffbcda5574f41bdde", slot: "icon" }, g("underline-icon", { key: "0598b423ac6724aef96ca5343ce1449fb56f8766" })), g("div", { key: "c091c8f3d08798fa7d49b86508b29047e5e4ea44", slot: "label" }, "Underline")), g("sp-button", { key: "60ea18e3f3ff95760910fef22119255477375a8f", quiet: !0, onClick: () => document.execCommand("italic") }, g("div", { key: "ed6f703adc15b721e0e3cfc72ab438a620b34dbd", slot: "icon" }, g("italic-icon", { key: "adb995c72136305499b149eb706841b4ca8291c8" })), g("div", { key: "481da563cadf1885efe1f466c5299913f78442a7", slot: "label" }, "Italic")))), g("div", { key: "5c2185ee0ba3c99bde46c13094c696fba33bfe6a", class: "buttons" }, g("sp-button", { key: "f73a9a795a24e59d2c835b5a9a1cb7e2d16532c6", onClick: this.sendComposer, class: "send" }, "Send"), g("sp-button", { key: "2a2ef56256878c45da84f03933e292a98069c44d", onClick: this.closeComposer, class: "close" }, "Close"))));
110
110
  }
111
111
  get host() {
112
112
  return Rt(this);
@@ -213,12 +213,12 @@ const kt = class {
213
213
  return t.read().then(({ done: u, value: s }) => u ? o : (o.push(s), this.readChunk(t, o)));
214
214
  }
215
215
  render() {
216
- return g($e, { key: "62f141a0a4bdba909ee313c05be61dfa5000bcaf" }, g("sp-theme", { key: "3839bf561000187ab456ae201cb539df420ec653", scale: "medium", color: "dark" }, g("sp-button", { key: "5bc73336c7afc299ac213c9b2903424a014a3f13", label: "Summarize email", "icon-only": !0, onClickCapture: this.onClick, class: {
216
+ return g($e, { key: "ab54db8a781cad602a1bd07093c407a8073934be" }, g("sp-theme", { key: "bf0cbbed7ca686cfc5cc94d0209d61237359776a", scale: "medium", color: "dark" }, g("sp-button", { key: "51f6a0e1db8ae2fd8be3175886a522ca519170bf", label: "Summarize email", "icon-only": !0, onClickCapture: this.onClick, class: {
217
217
  "summarize-button": !0,
218
218
  stopped: this.state === "stopped",
219
219
  loading: this.state === "loading",
220
220
  playing: this.state === "playing"
221
- } }, this.state === "stopped" && g("play-icon", null), this.state === "loading" && g("loading-icon", null), this.state === "playing" && g("stop-icon", null)), g("audio", { key: "acf15db8df8104a59f452f29b797f4967f8243b3", ref: (t) => this.audioRef = t, autoPlay: !0, onPlaying: () => this.state = "playing", onPause: () => this.state = "stopped", onEnded: () => {
221
+ } }, this.state === "stopped" && g("play-icon", null), this.state === "loading" && g("loading-icon", null), this.state === "playing" && g("stop-icon", null)), g("audio", { key: "c8e6e048f53002956ea54465b1e7ebc4cbec1282", ref: (t) => this.audioRef = t, autoPlay: !0, onPlaying: () => this.state = "playing", onPause: () => this.state = "stopped", onEnded: () => {
222
222
  this.state = "stopped", T("[nylas-summarize-message-button] Audio ended");
223
223
  } })));
224
224
  }
@@ -912,7 +912,7 @@ const Bn = class {
912
912
  });
913
913
  }
914
914
  render() {
915
- return console.debug("[nylas-view-email] render", { hoistedFontURLs: this.hoistedFontURLs }), g($e, { key: "2b8f2ef90fc96788d4925a70b1cdb692b7e7d183" }, this.state === "loading" && g("div", null, "Loading..."), this.state === "ready" && g(An, null, this.styles.map((t) => g("style", null, Ge.sanitize(t.innerHTML))), g("div", { class: "view-email", part: "view-email", innerHTML: this.sanitizedBody, ref: (t) => this.viewEmailElement = t })));
915
+ return console.debug("[nylas-view-email] render", { hoistedFontURLs: this.hoistedFontURLs }), g($e, { key: "1a82db1175c9bffed825dc2941b277ab699ff457" }, this.state === "loading" && g("div", null, "Loading..."), this.state === "ready" && g(An, null, this.styles.map((t) => g("style", null, Ge.sanitize(t.innerHTML))), g("div", { class: "view-email", part: "view-email", innerHTML: this.sanitizedBody, ref: (t) => this.viewEmailElement = t })));
916
916
  }
917
917
  get host() {
918
918
  return Rt(this);
@@ -930,7 +930,7 @@ const Wn = ".sc-reply-all-icon-h{display:flex}", Gn = Wn, $n = class {
930
930
  ne(this, t), this.width = "15", this.height = "15";
931
931
  }
932
932
  render() {
933
- return g("svg", { key: "cf3a910b7232018b6579cfe31a868e3ba54f30b0", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "1db5bb9aa170d0a00c5939cdd7bfe7b878124c2c", d: "m1030.975 188 81.249 81.249-429.228 429.228h300.747c516.223 0 936.257 420.034 936.257 936.257v98.028h-114.92v-98.028c0-452.901-368.436-821.337-821.337-821.337H682.996l429.228 429.229-81.25 81.248-567.936-567.937L1030.975 188Zm-463.038.011 81.249 81.25-486.688 486.688 486.688 486.688-81.249 81.249L0 755.949 567.937 188.01Z", "fill-rule": "evenodd" }));
933
+ return g("svg", { key: "e0178c328ba6b6cee56a080b757c3c6778a8d5bf", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "8b579e2760f2d3a65be0d505f413c2277d1f9c28", d: "m1030.975 188 81.249 81.249-429.228 429.228h300.747c516.223 0 936.257 420.034 936.257 936.257v98.028h-114.92v-98.028c0-452.901-368.436-821.337-821.337-821.337H682.996l429.228 429.229-81.25 81.248-567.936-567.937L1030.975 188Zm-463.038.011 81.249 81.25-486.688 486.688 486.688 486.688-81.249 81.249L0 755.949 567.937 188.01Z", "fill-rule": "evenodd" }));
934
934
  }
935
935
  };
936
936
  $n.style = Gn;
@@ -939,7 +939,7 @@ const qn = ".sc-reply-icon-h{display:flex}", Yn = qn, jn = class {
939
939
  ne(this, t), this.width = "15", this.height = "15";
940
940
  }
941
941
  render() {
942
- return g("svg", { key: "a353055eb9122f1dae36fbf49a557c431fd8580a", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "97ac62efd50d229e10b45fc2a47f3c8c5a9b6e5d", d: "M835.942 632.563H244.966l478.08-478.08-90.496-90.496L-.026 696.563 632.55 1329.14l90.496-90.496-478.08-478.08h590.976c504.448 0 914.816 410.368 914.816 914.816v109.184h128V1675.38c0-574.976-467.84-1042.816-1042.816-1042.816", "fill-rule": "evenodd" }));
942
+ return g("svg", { key: "6c04aaf9406e45710a19af8b19a26174d337a120", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "1995d8a661f6e23bd4f9d225fd84f0de45a3b0a5", d: "M835.942 632.563H244.966l478.08-478.08-90.496-90.496L-.026 696.563 632.55 1329.14l90.496-90.496-478.08-478.08h590.976c504.448 0 914.816 410.368 914.816 914.816v109.184h128V1675.38c0-574.976-467.84-1042.816-1042.816-1042.816", "fill-rule": "evenodd" }));
943
943
  }
944
944
  };
945
945
  jn.style = Yn;
@@ -1,12 +1,12 @@
1
- import { r as t, h as C } from "./index-2d032bec.js";
1
+ import { r as e, h as C } from "./index-5851f0a2.js";
2
2
  import "react";
3
3
  import "react-dom";
4
4
  const o = ".sc-globe-icon-h{display:flex}", s = o, i = class {
5
- constructor(e) {
6
- t(this, e), this.width = "16", this.height = "16";
5
+ constructor(t) {
6
+ e(this, t), this.width = "16", this.height = "16";
7
7
  }
8
8
  render() {
9
- return C("svg", { key: "f491775c5d5c635be9dcfec23fff61ec0093844e", xmlns: "http://www.w3.org/2000/svg", width: this.width, height: this.height, viewBox: "0 0 16 16", fill: "none" }, C("path", { key: "ed8e2b4295a1db6ded29520c94b1ac3d6d81efba", d: "M8 14C11.3137 14 14 11.3137 14 8C14 4.68629 11.3137 2 8 2C4.68629 2 2 4.68629 2 8C2 11.3137 4.68629 14 8 14ZM8 3C8.37372 3 8.87543 3.35608 9.31258 4.31781C9.4073 4.52619 9.49448 4.75446 9.57265 5H6.42735C6.50552 4.75446 6.5927 4.52619 6.68742 4.31781C7.12457 3.35608 7.62628 3 8 3ZM5.77705 3.90401C5.62614 4.23601 5.49428 4.6038 5.38411 5H3.99963C4.52341 4.30269 5.22525 3.74677 6.03766 3.39978C5.94287 3.56117 5.85596 3.7304 5.77705 3.90401ZM5.16299 6C5.05694 6.6275 5 7.30146 5 8C5 8.69854 5.05694 9.3725 5.16299 10H3.41604C3.14845 9.38754 3 8.7111 3 8C3 7.2889 3.14845 6.61246 3.41604 6H5.16299ZM5.38411 11C5.49428 11.3962 5.62614 11.764 5.77705 12.096C5.85596 12.2696 5.94287 12.4388 6.03766 12.6002C5.22525 12.2532 4.52341 11.6973 3.99963 11H5.38411ZM6.42735 11H9.57265C9.49448 11.2455 9.4073 11.4738 9.31258 11.6822C8.87543 12.6439 8.37372 13 8 13C7.62628 13 7.12457 12.6439 6.68742 11.6822C6.5927 11.4738 6.50552 11.2455 6.42735 11ZM9.82134 10H6.17866C6.06438 9.3892 6 8.71396 6 8C6 7.28604 6.06438 6.6108 6.17866 6H9.82134C9.93562 6.6108 10 7.28604 10 8C10 8.71396 9.93562 9.3892 9.82134 10ZM10.6159 11H12.0004C11.4766 11.6973 10.7747 12.2532 9.96234 12.6002C10.0571 12.4388 10.144 12.2696 10.2229 12.096C10.3739 11.764 10.5057 11.3962 10.6159 11ZM12.584 10H10.837C10.9431 9.3725 11 8.69854 11 8C11 7.30146 10.9431 6.6275 10.837 6H12.584C12.8516 6.61246 13 7.2889 13 8C13 8.7111 12.8516 9.38754 12.584 10ZM9.96234 3.39978C10.7747 3.74677 11.4766 4.30269 12.0004 5H10.6159C10.5057 4.6038 10.3739 4.23601 10.2229 3.90401C10.144 3.7304 10.0571 3.56117 9.96234 3.39978Z", fill: "currentColor" }));
9
+ return C("svg", { key: "f66b8a8a33e8b391325655db55556a4183cc8456", xmlns: "http://www.w3.org/2000/svg", width: this.width, height: this.height, viewBox: "0 0 16 16", fill: "none" }, C("path", { key: "1b65d25d5d037c6e6447dc8e154819ddc20e9a0b", d: "M8 14C11.3137 14 14 11.3137 14 8C14 4.68629 11.3137 2 8 2C4.68629 2 2 4.68629 2 8C2 11.3137 4.68629 14 8 14ZM8 3C8.37372 3 8.87543 3.35608 9.31258 4.31781C9.4073 4.52619 9.49448 4.75446 9.57265 5H6.42735C6.50552 4.75446 6.5927 4.52619 6.68742 4.31781C7.12457 3.35608 7.62628 3 8 3ZM5.77705 3.90401C5.62614 4.23601 5.49428 4.6038 5.38411 5H3.99963C4.52341 4.30269 5.22525 3.74677 6.03766 3.39978C5.94287 3.56117 5.85596 3.7304 5.77705 3.90401ZM5.16299 6C5.05694 6.6275 5 7.30146 5 8C5 8.69854 5.05694 9.3725 5.16299 10H3.41604C3.14845 9.38754 3 8.7111 3 8C3 7.2889 3.14845 6.61246 3.41604 6H5.16299ZM5.38411 11C5.49428 11.3962 5.62614 11.764 5.77705 12.096C5.85596 12.2696 5.94287 12.4388 6.03766 12.6002C5.22525 12.2532 4.52341 11.6973 3.99963 11H5.38411ZM6.42735 11H9.57265C9.49448 11.2455 9.4073 11.4738 9.31258 11.6822C8.87543 12.6439 8.37372 13 8 13C7.62628 13 7.12457 12.6439 6.68742 11.6822C6.5927 11.4738 6.50552 11.2455 6.42735 11ZM9.82134 10H6.17866C6.06438 9.3892 6 8.71396 6 8C6 7.28604 6.06438 6.6108 6.17866 6H9.82134C9.93562 6.6108 10 7.28604 10 8C10 8.71396 9.93562 9.3892 9.82134 10ZM10.6159 11H12.0004C11.4766 11.6973 10.7747 12.2532 9.96234 12.6002C10.0571 12.4388 10.144 12.2696 10.2229 12.096C10.3739 11.764 10.5057 11.3962 10.6159 11ZM12.584 10H10.837C10.9431 9.3725 11 8.69854 11 8C11 7.30146 10.9431 6.6275 10.837 6H12.584C12.8516 6.61246 13 7.2889 13 8C13 8.7111 12.8516 9.38754 12.584 10ZM9.96234 3.39978C10.7747 3.74677 11.4766 4.30269 12.0004 5H10.6159C10.5057 4.6038 10.3739 4.23601 10.2229 3.90401C10.144 3.7304 10.0571 3.56117 9.96234 3.39978Z", fill: "currentColor" }));
10
10
  }
11
11
  };
12
12
  i.style = s;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-9c04361d.cjs");require("react");require("react-dom");const i=".sc-globe-icon-h{display:flex}",c=i,C=class{constructor(t){e.registerInstance(this,t),this.width="16",this.height="16"}render(){return e.h("svg",{key:"f491775c5d5c635be9dcfec23fff61ec0093844e",xmlns:"http://www.w3.org/2000/svg",width:this.width,height:this.height,viewBox:"0 0 16 16",fill:"none"},e.h("path",{key:"ed8e2b4295a1db6ded29520c94b1ac3d6d81efba",d:"M8 14C11.3137 14 14 11.3137 14 8C14 4.68629 11.3137 2 8 2C4.68629 2 2 4.68629 2 8C2 11.3137 4.68629 14 8 14ZM8 3C8.37372 3 8.87543 3.35608 9.31258 4.31781C9.4073 4.52619 9.49448 4.75446 9.57265 5H6.42735C6.50552 4.75446 6.5927 4.52619 6.68742 4.31781C7.12457 3.35608 7.62628 3 8 3ZM5.77705 3.90401C5.62614 4.23601 5.49428 4.6038 5.38411 5H3.99963C4.52341 4.30269 5.22525 3.74677 6.03766 3.39978C5.94287 3.56117 5.85596 3.7304 5.77705 3.90401ZM5.16299 6C5.05694 6.6275 5 7.30146 5 8C5 8.69854 5.05694 9.3725 5.16299 10H3.41604C3.14845 9.38754 3 8.7111 3 8C3 7.2889 3.14845 6.61246 3.41604 6H5.16299ZM5.38411 11C5.49428 11.3962 5.62614 11.764 5.77705 12.096C5.85596 12.2696 5.94287 12.4388 6.03766 12.6002C5.22525 12.2532 4.52341 11.6973 3.99963 11H5.38411ZM6.42735 11H9.57265C9.49448 11.2455 9.4073 11.4738 9.31258 11.6822C8.87543 12.6439 8.37372 13 8 13C7.62628 13 7.12457 12.6439 6.68742 11.6822C6.5927 11.4738 6.50552 11.2455 6.42735 11ZM9.82134 10H6.17866C6.06438 9.3892 6 8.71396 6 8C6 7.28604 6.06438 6.6108 6.17866 6H9.82134C9.93562 6.6108 10 7.28604 10 8C10 8.71396 9.93562 9.3892 9.82134 10ZM10.6159 11H12.0004C11.4766 11.6973 10.7747 12.2532 9.96234 12.6002C10.0571 12.4388 10.144 12.2696 10.2229 12.096C10.3739 11.764 10.5057 11.3962 10.6159 11ZM12.584 10H10.837C10.9431 9.3725 11 8.69854 11 8C11 7.30146 10.9431 6.6275 10.837 6H12.584C12.8516 6.61246 13 7.2889 13 8C13 8.7111 12.8516 9.38754 12.584 10ZM9.96234 3.39978C10.7747 3.74677 11.4766 4.30269 12.0004 5H10.6159C10.5057 4.6038 10.3739 4.23601 10.2229 3.90401C10.144 3.7304 10.0571 3.56117 9.96234 3.39978Z",fill:"currentColor"}))}};C.style=c;exports.globe_icon=C;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-769f0fdd.cjs");require("react");require("react-dom");const i=".sc-globe-icon-h{display:flex}",o=i,C=class{constructor(t){e.registerInstance(this,t),this.width="16",this.height="16"}render(){return e.h("svg",{key:"f66b8a8a33e8b391325655db55556a4183cc8456",xmlns:"http://www.w3.org/2000/svg",width:this.width,height:this.height,viewBox:"0 0 16 16",fill:"none"},e.h("path",{key:"1b65d25d5d037c6e6447dc8e154819ddc20e9a0b",d:"M8 14C11.3137 14 14 11.3137 14 8C14 4.68629 11.3137 2 8 2C4.68629 2 2 4.68629 2 8C2 11.3137 4.68629 14 8 14ZM8 3C8.37372 3 8.87543 3.35608 9.31258 4.31781C9.4073 4.52619 9.49448 4.75446 9.57265 5H6.42735C6.50552 4.75446 6.5927 4.52619 6.68742 4.31781C7.12457 3.35608 7.62628 3 8 3ZM5.77705 3.90401C5.62614 4.23601 5.49428 4.6038 5.38411 5H3.99963C4.52341 4.30269 5.22525 3.74677 6.03766 3.39978C5.94287 3.56117 5.85596 3.7304 5.77705 3.90401ZM5.16299 6C5.05694 6.6275 5 7.30146 5 8C5 8.69854 5.05694 9.3725 5.16299 10H3.41604C3.14845 9.38754 3 8.7111 3 8C3 7.2889 3.14845 6.61246 3.41604 6H5.16299ZM5.38411 11C5.49428 11.3962 5.62614 11.764 5.77705 12.096C5.85596 12.2696 5.94287 12.4388 6.03766 12.6002C5.22525 12.2532 4.52341 11.6973 3.99963 11H5.38411ZM6.42735 11H9.57265C9.49448 11.2455 9.4073 11.4738 9.31258 11.6822C8.87543 12.6439 8.37372 13 8 13C7.62628 13 7.12457 12.6439 6.68742 11.6822C6.5927 11.4738 6.50552 11.2455 6.42735 11ZM9.82134 10H6.17866C6.06438 9.3892 6 8.71396 6 8C6 7.28604 6.06438 6.6108 6.17866 6H9.82134C9.93562 6.6108 10 7.28604 10 8C10 8.71396 9.93562 9.3892 9.82134 10ZM10.6159 11H12.0004C11.4766 11.6973 10.7747 12.2532 9.96234 12.6002C10.0571 12.4388 10.144 12.2696 10.2229 12.096C10.3739 11.764 10.5057 11.3962 10.6159 11ZM12.584 10H10.837C10.9431 9.3725 11 8.69854 11 8C11 7.30146 10.9431 6.6275 10.837 6H12.584C12.8516 6.61246 13 7.2889 13 8C13 8.7111 12.8516 9.38754 12.584 10ZM9.96234 3.39978C10.7747 3.74677 11.4766 4.30269 12.0004 5H10.6159C10.5057 4.6038 10.3739 4.23601 10.2229 3.90401C10.144 3.7304 10.0571 3.56117 9.96234 3.39978Z",fill:"currentColor"}))}};C.style=o;exports.globe_icon=C;
@@ -0,0 +1,454 @@
1
+ import { r as H, h as e, c as m, x as at, d, y as q, H as K, g as Q } from "./index-5851f0a2.js";
2
+ import { R as X } from "./register-component-a5a9ca5d-538c35c3.js";
3
+ import { D as W } from "./constants-f34b9c6e-efe2836b.js";
4
+ import "react";
5
+ import "react-dom";
6
+ const nt = ".sc-google-logo-icon-h{display:flex}", it = nt, st = class {
7
+ constructor(t) {
8
+ H(this, t), this.width = "24", this.height = "24";
9
+ }
10
+ render() {
11
+ return e("svg", { key: "2b6d66fd099e97716cdb808f575b5aadf1503a06", width: this.width, height: this.height, viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, e("g", { key: "2d02d3ca40389d13f189bddba578ae683c487d3e", "clip-path": "url(#clip0_959_12452)" }, e("path", { key: "41eeee9cdd77323ffee094ce688e222c2ae95461", d: "M23.745 12.27C23.745 11.48 23.675 10.73 23.555 10H12.255V14.51H18.725C18.435 15.99 17.585 17.24 16.325 18.09V21.09H20.185C22.445 19 23.745 15.92 23.745 12.27Z", fill: "#4285F4" }), e("path", { key: "7a8f1123dc6b8b29324eb255637f7b536982e112", d: "M12.255 24C15.495 24 18.205 22.92 20.185 21.09L16.325 18.09C15.245 18.81 13.875 19.25 12.255 19.25C9.12504 19.25 6.47505 17.14 5.52505 14.29H1.54504V17.38C3.51504 21.3 7.56504 24 12.255 24Z", fill: "#34A853" }), e("path", { key: "e71780d270c31b20d6617deb912a0b74b3dc8004", d: "M5.52501 14.2901C5.27501 13.5701 5.145 12.8001 5.145 12.0001C5.145 11.2001 5.28501 10.4301 5.52501 9.71012V6.62012H1.545C0.725004 8.24012 0.255005 10.0601 0.255005 12.0001C0.255005 13.9401 0.725004 15.7601 1.545 17.3801L5.52501 14.2901Z", fill: "#FBBC05" }), e("path", { key: "4e8795414ed616287f7e315d9d4ae7882832c56c", d: "M12.255 4.75C14.025 4.75 15.605 5.36 16.855 6.55L20.275 3.13C18.205 1.19 15.495 0 12.255 0C7.56504 0 3.51504 2.7 1.54504 6.62L5.52505 9.71C6.47505 6.86 9.12504 4.75 12.255 4.75Z", fill: "#EA4335" })), e("defs", { key: "9ad522ed57a9d8c75d8515e0e0a1e64d1dcde3a0" }, e("clipPath", { key: "da8c3ef1116cd32e06a73e30c5c4bc335f209d5b", id: "clip0_959_12452" }, e("rect", { key: "8936b3346ec26a6c0901073adca44b8021661be6", width: 24, height: 24, fill: "white" }))));
12
+ }
13
+ };
14
+ st.style = it;
15
+ const ot = ".sc-microsoft-logo-icon-h{display:flex}", rt = ot, lt = class {
16
+ constructor(t) {
17
+ H(this, t), this.width = "22", this.height = "22";
18
+ }
19
+ render() {
20
+ return e("svg", { key: "deae127512c4d2b6ef876ab1311fb6ab4d5cd368", width: this.width, height: this.height, viewBox: "0 0 22 22", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, e("path", { key: "ea58fbe3dac4c5a6455acec95fe9677068999d53", d: "M0.043457 0.043457H10.4782V10.4782H0.043457V0.043457Z", fill: "#F35325" }), e("path", { key: "e8a2faf14e8a7cdf15808a1fac1b16fba79f6051", d: "M11.5217 0.043457H21.9565V10.4782H11.5217V0.043457Z", fill: "#81BC06" }), e("path", { key: "56644908156e19d4ba9eedfec54a9ffa9b9744bd", d: "M0.043457 11.5217H10.4782V21.9565H0.043457V11.5217Z", fill: "#05A6F0" }), e("path", { key: "24c76e1b54ed1cdbc97ec6e56888db403169d74f", d: "M11.5217 11.5217H21.9565V21.9565H11.5217V11.5217Z", fill: "#FFBA08" }));
21
+ }
22
+ };
23
+ lt.style = rt;
24
+ function dt({ id: t, formState: a, activeTab: n, calendars: s }) {
25
+ var o;
26
+ switch (n) {
27
+ case "eventInfo":
28
+ const i = a.title, l = a.description, r = parseInt(a.duration), c = a.location;
29
+ return e(
30
+ "div",
31
+ { key: t },
32
+ e(
33
+ "nylas-event-info",
34
+ null,
35
+ e(
36
+ "div",
37
+ { slot: "inputs" },
38
+ e("nylas-event-title", { name: "title", eventTitle: i, exportparts: "net, net__title, net__dropdown-content" }),
39
+ e("nylas-event-duration", { name: "duration", eventDurationMinutes: r, exportparts: "ned, ned__dropdown, ned__dropdown-button, ned__dropdown-content, ned__input_dropdown, ned__input_dropdown-input, ned__input_dropdown-content" }),
40
+ e("nylas-event-location", { name: "location", eventLocation: c, exportparts: "nel, nel__location, nel__dropdown, nel__dropdown-button, nel__dropdown-content" }),
41
+ e("nylas-event-description", { name: "description", eventDescription: l, exportparts: "nedesc, nedesc__textarea" })
42
+ )
43
+ )
44
+ );
45
+ case "availability":
46
+ const b = a.availability.openHours, f = a.availability.timezone ? a.availability.timezone : Intl.DateTimeFormat().resolvedOptions().timeZone, p = (o = a.participants) == null ? void 0 : o.find((w) => w.is_organizer), g = (p == null ? void 0 : p.email) ?? "primary", _ = a.calendarIds.length > 0 ? a.calendarIds : [g], v = a.bookingCalendar == "primary" ? g : a.bookingCalendar;
47
+ return e(
48
+ "div",
49
+ { key: t },
50
+ e("nylas-booking-calendar-picker", { name: "booking-calendar", calendars: s ?? [], defaultBookingCalendar: v, exportparts: "nbcp, nbcp__header, nbcp__input-label, nbcp__dropdown, nbcp__dropdown-button, nbcp__dropdown-content" }),
51
+ e("nylas-calendar-picker", { name: "calendars", calendars: s ?? [], defaultSelectedCalendars: _, exportparts: "ncp ncp__header, ncp__dropdown, ncp__dropdown-button, ncp__dropdown-content" }),
52
+ e("nylas-availability-picker", { name: "availability", openHours: b, defaultTimezone: f, exportparts: "nap__header, nap__select-timezone, nap__select-timezone-button, nap__select-timezone-dropdown-content, nap__availability, nap__day, nap__time-ranges, nap__time-range, nap__add-time-range, nap__time-picker-container, nap__time-picker-input, nap__time-picker-times" })
53
+ );
54
+ case "bookingOptions":
55
+ return e(
56
+ "div",
57
+ { key: t },
58
+ e("nylas-buffer-time", { name: "buffer-time", buffer: a.buffer, exportparts: "nbt, nbt__header, nbt__body, nbt__dropdown-before, nbt__dropdown-button-before, nbt__dropdown-content-before, nbt__dropdown-after, nbt__dropdown-button-after, nbt__dropdown-content-after, nbt__preview" }),
59
+ e(
60
+ "nylas-event-limits",
61
+ null,
62
+ e(
63
+ "div",
64
+ { slot: "inputs" },
65
+ e("nylas-min-booking-notice", { name: "min-booking-notice", minBookingNotice: a.minBookingNotice, exportparts: "nmbn, nmbn__number-dropdown, nmbn__number-dropdown-button, nmbn__number-dropdown-content, nmbn__period-dropdown, nmbn__period-dropdown-button, nmbn__period-dropdown-content" }),
66
+ e("nylas-limit-future-bookings", { name: "limit-future-bookings", availableDaysInFuture: a.availableDaysInFuture, exportparts: "nlfb, nlfb__number-dropdown, nlfb__number-dropdown-button, nlfb__number-dropdown-content, nlfb__period-dropdown, nlfb__period-dropdown-button, nlfb__period-dropdown-content" }),
67
+ e("nylas-min-cancellation-notice", { name: "min-cancellation-notice", minCancellationNotice: a.minCancellationNotice, exportparts: "nmcn, nmcn__number-dropdown, nmcn__number-dropdown-button, nmcn__number-dropdown-content, nmcn__period-dropdown, nmcn__period-dropdown-button, nmcn__period-dropdown-content" }),
68
+ e("nylas-cancellation-policy", { name: "cancellation-policy", cancellationPolicy: a.cancellationPolicy, exportparts: "ncpolicy, ncpolicy__textarea" })
69
+ )
70
+ ),
71
+ e("nylas-timeslot-interval", { name: "timeslot-interval", eventDurationMinutes: parseInt(a.duration), exportparts: "nti, nti__header, nti__input-label, nti__dropdown, nti__dropdown-button, nti__dropdown-content" }),
72
+ e("nylas-customize-booking-settings", { name: "customize-booking-settings", exportparts: "ncbs, ncbs__header, ncbs__settings, ncbs__settings-div, ncbs__additional_guests, ncbs__cancellation_options, ncbs__rescheduling_options" })
73
+ );
74
+ case "participants":
75
+ return e(
76
+ "div",
77
+ { key: t },
78
+ e("nylas-additional-participants", { name: "participants", eventParticipants: a.participants, exportparts: "nap__title, nap__subtitle, nap__content, nap__input_group, nap__input_wrapper, nap__input, nap__remove-participant" }),
79
+ e("nylas-participants-custom-availability", { name: "participant-custom-availability", participants: a.participants, exportparts: "npca, npca__header, npca__content, npca__participant-container, npca__participant-title, npca__participant-toggle--container, npca__toggle-label, npca__toggle-input, npca__toggle-slider" })
80
+ );
81
+ }
82
+ }
83
+ const ct = '.sc-nylas-editor-tabs-h{display:block;--nylas-primary:#2563eb;--nylas-error:#cc4841;--nylas-error-pressed:#992222;--nylas-wraning:#f06c00;--nylas-success:#16a392;--nylas-info:#2b8fc2;--nylas-base-0:#ffffff;--nylas-base-25:#fcfcfd;--nylas-base-50:#f8f9fc;--nylas-base-100:#eaecf5;--nylas-base-200:#d5d9eb;--nylas-base-300:#b3b8d8;--nylas-base-400:#717bbc;--nylas-base-500:#4e5ba6;--nylas-base-600:#3e4784;--nylas-base-700:#263f72;--nylas-base-800:#293056;--nylas-base-900:#101323;--nylas-base-950:#0e101b;--nylas-border-radius:0.25rem;--nylas-border-radius-2x:0.5rem;--nylas-border-radius-3x:0.75rem;--nylas-font-family:"Inter", sans-serif}.scheduler-editor.sc-nylas-editor-tabs{display:flex;flex-direction:column}.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs{height:554px;display:grid;grid-template-columns:minmax(224px, 25%) 1fr}@media screen and (max-width: 768px){.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs{display:table-column-group;height:auto}}.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs .tabs.sc-nylas-editor-tabs{display:flex;flex-direction:column;border-right:1px solid var(--nylas-base-200);background-color:var(--nylas-base-25)}.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs .tabs.sc-nylas-editor-tabs .tab.sc-nylas-editor-tabs{display:flex;align-items:center;gap:0.5rem;padding:0.5rem 1rem;color:var(--nylas-base-900);background:var(--nylas-base-0);border:none;height:56px;font-family:var(--nylas-font-family);font-size:16px;font-weight:500;line-height:24px;cursor:pointer}.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs .tabs.sc-nylas-editor-tabs .tab.sc-nylas-editor-tabs:not(:first-of-type){margin-top:0.25rem}.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs .tabs.sc-nylas-editor-tabs .tab.active.sc-nylas-editor-tabs{font-weight:600;background:var(--nylas-base-0);color:var(--nylas-primary);border-left:4px solid var(--nylas-primary);box-shadow:0px 1px 2px 0px rgba(0, 0, 0, 0.0588235294);box-shadow:0px 1px 3px 0px rgba(0, 0, 0, 0.1019607843)}.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs .tab-content.sc-nylas-editor-tabs{max-width:692px;overflow-y:auto}.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs .tab-content.sc-nylas-editor-tabs nylas-event-info.sc-nylas-editor-tabs,.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs .tab-content.sc-nylas-editor-tabs nylas-event-limits.sc-nylas-editor-tabs{width:inherit}.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs .tab-content.sc-nylas-editor-tabs nylas-event-info.sc-nylas-editor-tabs div[slot=inputs].sc-nylas-editor-tabs,.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs .tab-content.sc-nylas-editor-tabs nylas-event-limits.sc-nylas-editor-tabs div[slot=inputs].sc-nylas-editor-tabs{display:flex;flex-direction:column;gap:1rem}.footer.sc-nylas-editor-tabs{display:flex;justify-content:space-between;align-items:center;gap:1rem;min-height:80px;padding:0 1rem;border-top:1px solid var(--nylas-base-200)}@media screen and (max-width: 768px){.footer.sc-nylas-editor-tabs{flex-direction:column;height:auto}}@media screen and (max-width: 768px){.footer.sc-nylas-editor-tabs .preview.sc-nylas-editor-tabs{margin-top:1rem;width:100%}}.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs{display:flex;justify-content:flex-end;align-items:center;justify-self:flex-end;gap:1rem}@media screen and (max-width: 768px){.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs{flex-direction:column-reverse;width:100%}}.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs p.sc-nylas-editor-tabs{max-width:524px}.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs p.unsaved-changes.sc-nylas-editor-tabs{color:var(--nylas-base-600)}.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs p.saved-changes.sc-nylas-editor-tabs{color:var(--nylas-success)}.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs p.error.sc-nylas-editor-tabs{color:var(--nylas-error)}.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs p.error-full-width.sc-nylas-editor-tabs{max-width:660px}@media screen and (max-width: 768px){.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs button-component.sc-nylas-editor-tabs{width:100%}}.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs button.sc-nylas-editor-tabs{background:var(--nylas-primary);color:var(--nylas-base-0);height:48px;border:none;border-radius:var(--nylas-border-radius-2x);font-size:1rem;line-height:24px;padding:0 1rem;cursor:pointer;width:148px}.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs button.sc-nylas-editor-tabs:hover{background:var(--nylas-base-600)}.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs button.sc-nylas-editor-tabs:active{background:var(--nylas-base-800)}.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs button.sc-nylas-editor-tabs:disabled{background:var(--nylas-base-300);cursor:not-allowed}.footer.sc-nylas-editor-tabs .buttons.sc-nylas-editor-tabs button.sc-nylas-editor-tabs span.sc-nylas-editor-tabs{display:flex;align-items:center;justify-content:center;gap:0.5rem}', bt = ct;
84
+ var ut = function(t, a, n, s) {
85
+ var o = arguments.length, i = o < 3 ? a : s === null ? s = Object.getOwnPropertyDescriptor(a, n) : s, l;
86
+ if (typeof Reflect == "object" && typeof Reflect.decorate == "function")
87
+ i = Reflect.decorate(t, a, n, s);
88
+ else
89
+ for (var r = t.length - 1; r >= 0; r--)
90
+ (l = t[r]) && (i = (o < 3 ? l(i) : o > 3 ? l(a, n, i) : l(a, n)) || i);
91
+ return o > 3 && i && Object.defineProperty(a, n, i), i;
92
+ }, F = function(t, a) {
93
+ if (typeof Reflect == "object" && typeof Reflect.metadata == "function")
94
+ return Reflect.metadata(t, a);
95
+ };
96
+ const Y = class {
97
+ constructor(t) {
98
+ H(this, t), this.schedulerConfigChanged = m(this, "schedulerConfigChanged", 7), this.cancelButtonClick = m(this, "cancelButtonClick", 7), this.formSubmitted = m(this, "formSubmitted", 7), this.previewButtonClicked = m(this, "previewButtonClicked", 7), this.setError = (a) => {
99
+ this.error = a.message;
100
+ }, this.formSubmissionHandler = async (a) => {
101
+ var P, E, R, N, z, j, M, V, A, $, U;
102
+ if (a.preventDefault(), this.formSubmitted.emit(), !this.formRef.checkValidity())
103
+ return;
104
+ this.isLoading = !0, this.hasUnsavedChanges = !1;
105
+ const s = this.updateFormState(), { title: o, description: i, duration: l, availability: r, calendarIds: c, bookingCalendar: b, location: f, bookingType: p, buffer: g, availableDaysInFuture: _, minCancellationNotice: v, minBookingNotice: w, cancellationPolicy: S, timeslotInterval: h, additionalGuestsHidden: L, hideCancellationOptions: B, hideReschedulingOptions: D, participants: k, participantOpenHours: y } = s, C = l ? parseInt(l) : 30, x = {
106
+ ...((P = this.selectedConfiguration) == null ? void 0 : P.id) && { id: this.selectedConfiguration.id },
107
+ version: ((E = this.selectedConfiguration) == null ? void 0 : E.version) ?? "1.0.0",
108
+ availability: {
109
+ duration_minutes: C,
110
+ interval_minutes: (h == null ? void 0 : h.interval) ?? C,
111
+ round_to: h == null ? void 0 : h.roundTo,
112
+ availability_rules: {
113
+ availability_method: ((z = (N = (R = this.selectedConfiguration) == null ? void 0 : R.availability) == null ? void 0 : N.availability_rules) == null ? void 0 : z.availability_method) ?? "collective",
114
+ buffer: g || { before: 0, after: 0 },
115
+ default_open_hours: (r == null ? void 0 : r.openHours) ?? ((V = (M = (j = this.selectedConfiguration) == null ? void 0 : j.availability) == null ? void 0 : M.availability_rules) == null ? void 0 : V.default_open_hours) ?? W,
116
+ round_robin_group_id: ((U = ($ = (A = this.selectedConfiguration) == null ? void 0 : A.availability) == null ? void 0 : $.availability_rules) == null ? void 0 : U.round_robin_group_id) ?? ""
117
+ }
118
+ },
119
+ participants: [
120
+ ...(k == null ? void 0 : k.map((u) => {
121
+ var Z, G, J;
122
+ return u.is_organizer ? {
123
+ name: u.name ?? u.email,
124
+ email: u.email,
125
+ is_organizer: !0,
126
+ availability: {
127
+ calendar_ids: c != null && c.length ? c : ["primary"],
128
+ open_hours: (y == null ? void 0 : y[u.email]) ?? ((Z = u.availability) == null ? void 0 : Z.open_hours) ?? []
129
+ },
130
+ booking: {
131
+ calendar_id: b && b !== "" ? b : "primary"
132
+ }
133
+ } : {
134
+ ...u,
135
+ availability: {
136
+ calendar_ids: ((G = u.availability) == null ? void 0 : G.calendar_ids) ?? ["primary"],
137
+ open_hours: (y == null ? void 0 : y[u.email]) ?? ((J = u.availability) == null ? void 0 : J.open_hours) ?? []
138
+ }
139
+ };
140
+ })) ?? []
141
+ ],
142
+ event_booking: {
143
+ title: (o == null ? void 0 : o.toString()) ?? "",
144
+ description: (i == null ? void 0 : i.toString()) ?? "",
145
+ location: (f == null ? void 0 : f.toString()) ?? "",
146
+ booking_type: (p == null ? void 0 : p.toString()) ?? "booking",
147
+ timezone: (r == null ? void 0 : r.timezone) ?? Intl.DateTimeFormat().resolvedOptions().timeZone
148
+ },
149
+ scheduler: {
150
+ cancellation_policy: S ?? "",
151
+ available_days_in_future: _ ?? 30,
152
+ min_cancellation_notice: v ?? 0,
153
+ min_booking_notice: w ?? 60,
154
+ hide_additional_guests: L ?? !1,
155
+ hide_cancellation_options: B ?? !1,
156
+ hide_rescheduling_options: D ?? !1
157
+ }
158
+ }, T = at(x, this.selectedConfiguration), I = this.action === "create" ? T : x, et = (u) => {
159
+ this.isLoading = !1, this.changesSaved = !0, setTimeout(() => {
160
+ this.changesSaved = !1;
161
+ }, 5e3);
162
+ };
163
+ this.schedulerConfigChanged.emit({ config: I, resetLoadingState: et, setError: this.setError, action: this.action });
164
+ }, this.calendars = void 0, this.selectedConfiguration = void 0, this.currentUser = void 0, this.schedulerPreviewLink = "", this.mode = "app", this.action = "create", this.activeTab = "eventInfo", this.isLoading = !1, this.hasUnsavedChanges = !1, this.changesSaved = !1, this.formState = {}, this.error = "";
165
+ }
166
+ configChangedHandler(t) {
167
+ d("[nylas-editor-tabs]", "configChangedHandler", t, this.selectedConfiguration), this.formState = {
168
+ ...this.getFormStateFromConfig(t)
169
+ }, t.id ? this.action = "edit" : this.action = "create";
170
+ }
171
+ connectedCallback() {
172
+ d("[nylas-editor-tabs]", "connectedCallback");
173
+ }
174
+ componentWillLoad() {
175
+ d("[nylas-editor-tabs]", "componentWillLoad"), this.formState = this.getFormStateFromConfig(this.selectedConfiguration);
176
+ }
177
+ componentDidLoad() {
178
+ d("[nylas-editor-tabs]", "componentDidLoad");
179
+ }
180
+ disconnectedCallback() {
181
+ d("[nylas-editor-tabs]", "disconnectedCallback");
182
+ }
183
+ handleValueChanged(t) {
184
+ d("[nylas-editor-tabs]", "handleValueChanged", t);
185
+ const { name: a, value: n } = t.detail;
186
+ this.setFormState(n, a), this.formState = { ...this.formState }, this.hasUnsavedChanges = !0, this.error = "";
187
+ }
188
+ getFormStateFromConfig(t) {
189
+ var n, s, o, i, l, r, c, b, f, p, g, _, v, w, S, h, L, B, D, k, y, C, x, T;
190
+ const a = (n = t == null ? void 0 : t.participants) == null ? void 0 : n.find((I) => I.is_organizer);
191
+ return {
192
+ title: ((s = t == null ? void 0 : t.event_booking) == null ? void 0 : s.title) ?? "",
193
+ description: ((o = t == null ? void 0 : t.event_booking) == null ? void 0 : o.description) ?? "",
194
+ duration: ((l = (i = t == null ? void 0 : t.availability) == null ? void 0 : i.duration_minutes) == null ? void 0 : l.toString()) ?? "30",
195
+ availability: {
196
+ timezone: ((r = t == null ? void 0 : t.event_booking) == null ? void 0 : r.timezone) ?? Intl.DateTimeFormat().resolvedOptions().timeZone,
197
+ openHours: ((b = (c = t == null ? void 0 : t.availability) == null ? void 0 : c.availability_rules) == null ? void 0 : b.default_open_hours) ?? W
198
+ },
199
+ calendarIds: ((f = a == null ? void 0 : a.availability) == null ? void 0 : f.calendar_ids) ?? [],
200
+ participants: (t == null ? void 0 : t.participants) ?? [],
201
+ bookingCalendar: ((p = a == null ? void 0 : a.booking) == null ? void 0 : p.calendar_id) ?? (a == null ? void 0 : a.email) ?? "",
202
+ location: ((g = t == null ? void 0 : t.event_booking) == null ? void 0 : g.location) ?? "",
203
+ bookingType: ((_ = t == null ? void 0 : t.event_booking) == null ? void 0 : _.booking_type) ?? "booking",
204
+ buffer: ((w = (v = t == null ? void 0 : t.availability) == null ? void 0 : v.availability_rules) == null ? void 0 : w.buffer) ?? { before: 0, after: 0 },
205
+ cancellationPolicy: ((S = t == null ? void 0 : t.scheduler) == null ? void 0 : S.cancellation_policy) ?? "",
206
+ availableDaysInFuture: ((h = t == null ? void 0 : t.scheduler) == null ? void 0 : h.available_days_in_future) ?? 30,
207
+ minCancellationNotice: ((L = t == null ? void 0 : t.scheduler) == null ? void 0 : L.min_cancellation_notice) ?? 0,
208
+ minBookingNotice: ((B = t == null ? void 0 : t.scheduler) == null ? void 0 : B.min_booking_notice) ?? 60,
209
+ timeslotInterval: {
210
+ interval: ((D = t == null ? void 0 : t.availability) == null ? void 0 : D.interval_minutes) ?? ((k = t == null ? void 0 : t.availability) == null ? void 0 : k.duration_minutes) ?? 10,
211
+ roundTo: (y = t == null ? void 0 : t.availability) == null ? void 0 : y.round_to
212
+ },
213
+ additionalGuestsHidden: ((C = t == null ? void 0 : t.scheduler) == null ? void 0 : C.hide_additional_guests) ?? !1,
214
+ hideCancellationOptions: ((x = t == null ? void 0 : t.scheduler) == null ? void 0 : x.hide_cancellation_options) ?? !1,
215
+ hideReschedulingOptions: ((T = t == null ? void 0 : t.scheduler) == null ? void 0 : T.hide_rescheduling_options) ?? !1
216
+ };
217
+ }
218
+ setFormState(t, a) {
219
+ switch (a) {
220
+ case "title":
221
+ this.formState.title = t.toString();
222
+ break;
223
+ case "description":
224
+ this.formState.description = t.toString();
225
+ break;
226
+ case "duration":
227
+ this.formState.duration = t.toString();
228
+ break;
229
+ case "availability":
230
+ this.formState.availability = JSON.parse(t.toString());
231
+ break;
232
+ case "participants":
233
+ this.formState.participants = JSON.parse(t.toString());
234
+ break;
235
+ case "calendars":
236
+ this.formState.calendarIds = t.toString().split(",");
237
+ break;
238
+ case "booking-calendar":
239
+ this.formState.bookingCalendar = t.toString();
240
+ break;
241
+ case "location":
242
+ this.formState.location = t.toString();
243
+ break;
244
+ case "booking-type":
245
+ this.formState.bookingType = t.toString();
246
+ break;
247
+ case "buffer-time":
248
+ this.formState.buffer = JSON.parse(t.toString());
249
+ break;
250
+ case "limit-future-bookings":
251
+ this.formState.availableDaysInFuture = parseInt(t.toString());
252
+ break;
253
+ case "min-cancellation-notice":
254
+ this.formState.minCancellationNotice = parseInt(t.toString());
255
+ break;
256
+ case "min-booking-notice":
257
+ this.formState.minBookingNotice = parseInt(t.toString());
258
+ break;
259
+ case "cancellation-policy":
260
+ this.formState.cancellationPolicy = t.toString();
261
+ break;
262
+ case "timeslot-interval":
263
+ this.formState.timeslotInterval = JSON.parse(t.toString());
264
+ break;
265
+ case "customize-booking-settings":
266
+ const n = JSON.parse(t.toString());
267
+ this.formState.additionalGuestsHidden = n.additionalGuestsHidden, this.formState.hideCancellationOptions = n.hideCancellationOptions, this.formState.hideReschedulingOptions = n.hideReschedulingOptions;
268
+ break;
269
+ case "participant-custom-availability":
270
+ const s = JSON.parse(t.toString());
271
+ this.formState.participantOpenHours = s;
272
+ break;
273
+ }
274
+ }
275
+ updateFormState() {
276
+ return new FormData(this.formRef).forEach((a, n) => {
277
+ this.setFormState(a, n);
278
+ }), this.formState = { ...this.formState }, this.formState;
279
+ }
280
+ setActiveTab(t, a) {
281
+ t.preventDefault(), this.updateFormState(), this.activeTab = a;
282
+ }
283
+ render() {
284
+ var a;
285
+ d("[nylas-editor-tabs]", "render", this.formState);
286
+ const t = localStorage.getItem("nylas") === "Nylas Developer";
287
+ return e(K, { key: "ccfd780da5c6ce1688f60384796bbaa98fe6094d" }, e("form", { key: "2e5d1c16a5373a5b623869925a7cab71f52f98ce", onSubmit: this.formSubmissionHandler, class: "scheduler-editor", ref: (n) => this.formRef = n, noValidate: !0 }, this.mode === "app" ? e("div", { class: "form-contents" }, e("div", { class: "tabs" }, e("button", { class: { tab: !0, active: this.activeTab == "eventInfo" }, onClick: (n) => this.setActiveTab(n, "eventInfo") }, e("calendar-info-icon", { width: "16", height: "16" }), "Event Info"), e("button", { class: { tab: !0, active: this.activeTab == "availability" }, onClick: (n) => this.setActiveTab(n, "availability") }, e("calendar-patterns-icon", { width: "16", height: "16" }), "Availability"), e("button", { class: { tab: !0, active: this.activeTab == "bookingOptions" }, onClick: (n) => this.setActiveTab(n, "bookingOptions") }, e("flow-icon", { width: "16", height: "16" }), "Booking Options"), t && e("button", { class: { tab: !0, active: this.activeTab == "participants" }, onClick: (n) => this.setActiveTab(n, "participants") }, e("people-icon", { width: "16", height: "16" }), "Participants")), e("div", { class: "tab-content" }, e(dt, { formState: this.formState, activeTab: this.activeTab, calendars: this.calendars, id: ((a = this.selectedConfiguration) == null ? void 0 : a.id) ?? "new" }))) : e("slot", null), e("div", { key: "f11d2767c5fc65ad7a72f346e9b3940b8151d7a3", class: "footer" }, e("div", { key: "858c5dac4d006f28b05347be3feba2d6dd336b15", class: "preview" }, this.schedulerPreviewLink !== "" && this.action === "edit" && e("button-component", { type: "button", disabled: this.isLoading, clickHandler: (n) => {
288
+ n.preventDefault(), this.previewButtonClicked.emit(this.host).defaultPrevented || window.open(q(this.schedulerPreviewLink, this.selectedConfiguration), "_blank");
289
+ }, variant: "basic" }, "Preview")), e("div", { key: "c5225165887e64b467570a3f90222479fb259494", class: "buttons" }, e("p", { key: "50b2861f9c99e3dc91e58f77097fa753ba02cd1b", class: {
290
+ "unsaved-changes": this.hasUnsavedChanges && !this.changesSaved,
291
+ "saved-changes": this.changesSaved,
292
+ error: this.error !== "",
293
+ "error-full-width": this.error !== "" && this.action === "create"
294
+ } }, this.error !== "" ? this.error : "", this.error == "" && this.hasUnsavedChanges && !this.changesSaved ? "Unsaved changes" : this.error == "" && this.changesSaved ? "Changes saved!" : ""), e("button-component", { key: "9934c2cf6faf7e74b135add1728e3524bc29e13f", type: "button", disabled: this.isLoading, clickHandler: (n) => {
295
+ n.preventDefault(), this.cancelButtonClick.emit(), this.error = "";
296
+ }, variant: "basic" }, "Cancel"), e("button-component", { key: "872f1a24204c38948d484b2bf99aa72d78ba7a37", type: "submit", disabled: this.isLoading }, this.isLoading ? e("span", null, "Saving", e("loading-icon", null), " ") : this.action == "create" ? "Create" : "Save changes")))));
297
+ }
298
+ get host() {
299
+ return Q(this);
300
+ }
301
+ static get watchers() {
302
+ return {
303
+ selectedConfiguration: ["configChangedHandler"]
304
+ };
305
+ }
306
+ };
307
+ ut([
308
+ X({
309
+ name: "nylas-editor-tabs",
310
+ stateToProps: /* @__PURE__ */ new Map([
311
+ ["schedulerConfig.calendars", "calendars"],
312
+ ["schedulerConfig.selectedConfiguration", "selectedConfiguration"],
313
+ ["schedulerConfig.currentUser", "currentUser"]
314
+ ]),
315
+ eventToProps: {
316
+ schedulerConfigChanged: async (t, a) => {
317
+ const { resetLoadingState: n, setError: s, action: o, config: i } = t.detail, l = (r) => {
318
+ const [c, b] = r;
319
+ !c && b && s && s(b), n && n(t);
320
+ };
321
+ if (o === "edit") {
322
+ const r = await a.schedulerConfig.updateConfiguration(i);
323
+ l(r);
324
+ } else {
325
+ const r = await a.schedulerConfig.createConfiguration(i);
326
+ l(r);
327
+ }
328
+ },
329
+ cancelButtonClick: async (t, a) => {
330
+ a.schedulerConfigStore.state.action = null;
331
+ },
332
+ previewButtonClicked: async (t, a) => {
333
+ d("[nylas-editor-tabs]", "previewButtonClicked", a);
334
+ },
335
+ formSubmitted: async (t, a) => {
336
+ d("[nylas-editor-tabs]", "formSubmitted", a);
337
+ }
338
+ },
339
+ localPropsToProp: /* @__PURE__ */ new Map([["schedulerPreviewLink", "schedulerPreviewLink"]]),
340
+ fireRegisterEvent: !0
341
+ }),
342
+ F("design:type", Function),
343
+ F("design:paramtypes", []),
344
+ F("design:returntype", void 0)
345
+ ], Y.prototype, "render", null);
346
+ Y.style = bt;
347
+ const pt = ':host{display:grid;grid-auto-flow:row;width:100%;font-family:inherit;font-optical-sizing:auto;--nylas-primary:#2563eb;--nylas-error:#cc4841;--nylas-error-pressed:#992222;--nylas-wraning:#f06c00;--nylas-success:#16a392;--nylas-info:#2b8fc2;--nylas-base-0:#ffffff;--nylas-base-25:#fcfcfd;--nylas-base-50:#f8f9fc;--nylas-base-100:#eaecf5;--nylas-base-200:#d5d9eb;--nylas-base-300:#b3b8d8;--nylas-base-400:#717bbc;--nylas-base-500:#4e5ba6;--nylas-base-600:#3e4784;--nylas-base-700:#263f72;--nylas-base-800:#293056;--nylas-base-900:#101323;--nylas-base-950:#0e101b;--nylas-border-radius:0.25rem;--nylas-border-radius-2x:0.5rem;--nylas-border-radius-3x:0.75rem;--nylas-font-family:"Inter", sans-serif}.header{display:flex;align-items:center;justify-content:space-between;margin-bottom:1rem;gap:1rem}@media screen and (max-width: 768px){.header{flex-direction:column;gap:0.5rem;align-items:unset}}.header h2{margin:0;font-size:1.25rem;color:var(--nylas-base-900);font-weight:600}.header p{margin:0;font-size:1rem;color:var(--nylas-base-700)}.header .actions{justify-self:end}@media screen and (max-width: 768px){.header .actions{width:100%}}.configurations{border:1px solid var(--nylas-base-200);border-radius:var(--nylas-border-radius-2x);background:var(--nylas-base-0);height:100%;display:flex;overflow-y:auto}.configurations table{width:100%;border-spacing:0;border-collapse:collapse;font-family:inherit;height:max-content}.configurations table.no-configurations{height:100%}.configurations table tr{color:var(--nylas-base-800);border-bottom:1px solid var(--nylas-base-200);font-family:inherit}.configurations table tr:last-of-type{border-bottom:0}.configurations table tr.hide{display:none}.configurations table th{font-weight:600;text-transform:uppercase;font-size:14px;line-height:20px}.configurations table th.actions-header{text-align:right}.configurations table tr.no-configurations td>div{display:flex;height:100%;justify-content:center;align-items:center;flex-direction:column;padding:var(--nylas-border-radius-3x)}.configurations table tr.no-configurations td>div h3{margin:0 0 1rem 0;color:var(--nylas-base-700)}.configurations table tr.no-configurations td>div p{margin:0 0 1rem 0;color:var(--nylas-base-600)}.configurations table tr.no-configurations td>div calendar-icon{margin-bottom:1rem;color:var(--nylas-base-200)}.configurations table th,.configurations table td{text-align:left;padding:1rem;font-family:inherit}.configurations table .actions{text-align:right}.configurations table .actions{display:flex;justify-content:flex-end;gap:1rem}@media screen and (max-width: 768px){.configurations table .actions{flex-direction:column;gap:0.5rem}}.configurations table .title{display:flex;flex-direction:column}.configurations table .title .config-event-title{font-weight:600}.configurations table .title .config-event-description{font-size:0.75rem}.error-container{margin-top:1.5rem}.error-container .error{color:var(--nylas-error);padding:0.5rem 0;margin:1rem 0 0}button-component#copy button{width:108px}', ht = pt;
348
+ var yt = function(t, a, n, s) {
349
+ var o = arguments.length, i = o < 3 ? a : s === null ? s = Object.getOwnPropertyDescriptor(a, n) : s, l;
350
+ if (typeof Reflect == "object" && typeof Reflect.decorate == "function")
351
+ i = Reflect.decorate(t, a, n, s);
352
+ else
353
+ for (var r = t.length - 1; r >= 0; r--)
354
+ (l = t[r]) && (i = (o < 3 ? l(i) : o > 3 ? l(a, n, i) : l(a, n)) || i);
355
+ return o > 3 && i && Object.defineProperty(a, n, i), i;
356
+ }, O = function(t, a) {
357
+ if (typeof Reflect == "object" && typeof Reflect.metadata == "function")
358
+ return Reflect.metadata(t, a);
359
+ };
360
+ const tt = class {
361
+ constructor(t) {
362
+ H(this, t), this.initListConfigurations = m(this, "initListConfigurations", 7), this.createButtonClick = m(this, "createButtonClick", 7), this.editButtonClick = m(this, "editButtonClick", 7), this.deleteButtonClick = m(this, "deleteButtonClick", 7), this.configurations = [], this.schedulerPreviewLink = "", this.state = "loading", this.error = "", this.copiedButtonIndex = -1;
363
+ }
364
+ connectedCallback() {
365
+ d("[nylas-list-configurations]", "connectedCallback");
366
+ }
367
+ componentWillLoad() {
368
+ d("[nylas-list-configurations]", "componentWillLoad"), this.configurations && this.configurations.length > 0 && (this.state = "loaded");
369
+ }
370
+ componentDidLoad() {
371
+ d("[nylas-list-configurations]", "componentDidLoad"), this.initListConfigurations.emit(this.host);
372
+ }
373
+ disconnectedCallback() {
374
+ d("[nylas-list-configurations]", "disconnectedCallback");
375
+ }
376
+ async getState() {
377
+ return this.state;
378
+ }
379
+ async setState(t) {
380
+ this.state = t;
381
+ }
382
+ async setError(t) {
383
+ this.error = t;
384
+ }
385
+ getDurationString(t) {
386
+ const a = Math.floor(t / 60), n = t % 60;
387
+ return `${a || ""} ${a ? `${a > 1 ? "hours" : "hour"}` : ""} ${n || ""} ${n ? `${n > 1 ? "mins" : "min"}` : ""}`;
388
+ }
389
+ render() {
390
+ return e(K, null, e("div", { class: "header" }, e("div", { class: "description" }, e("h2", null, "All scheduling pages"), e("p", null, "Create, edit and manage all your scheduling pages.")), this.configurations && this.configurations.length > 0 && e("div", { class: "actions" }, e("button-component", { clickHandler: () => {
391
+ this.createButtonClick.emit(this.host);
392
+ } }, "Create new"))), e("div", { class: "configurations" }, e("table", { class: {
393
+ "no-configurations": this.state !== "loading" && (!this.configurations || this.configurations.length === 0)
394
+ } }, e("tr", { class: {
395
+ hide: this.state === "loading" || this.configurations && this.configurations.length === 0
396
+ } }, e("th", null, "Scheduling page title"), e("th", null, "Duration"), e("th", { class: "actions-header" }, "Actions")), this.state === "loading" && e("tr", { class: "no-configurations" }, e("td", { colSpan: 3 }, e("div", null, e("h3", null, "Loading..."), e("p", null, "Please wait while we fetch the scheduling pages")))), this.state !== "loading" && (!this.configurations || this.configurations.length === 0) && e("tr", { class: "no-configurations" }, e("td", { colSpan: 3 }, e("div", null, e("calendar-icon", { width: "48", height: "48" }), e("h3", null, "No scheduling pages found"), e("p", null, "Get started with creating your first scheduling page"), e("button-component", { clickHandler: () => {
397
+ this.createButtonClick.emit(this.host);
398
+ } }, "Create new")))), this.state !== "loading" && this.configurations.map((t, a) => e("tr", { key: t.id }, e("td", null, e("div", { class: "title" }, e("span", { class: "config-event-title" }, t.event_booking.title), e("span", { class: "config-event-description" }, t.event_booking.description))), e("td", null, e("div", null, this.getDurationString(t.availability.duration_minutes))), e("td", null, e("div", { class: "actions" }, e("button-component", { variant: "basic", id: "copy", key: `copy-${a}`, clickHandler: async (n) => {
399
+ n.preventDefault();
400
+ const s = q(this.schedulerPreviewLink, t);
401
+ await navigator.clipboard.writeText(s), this.copiedButtonIndex = a, setTimeout(() => {
402
+ this.copiedButtonIndex = -1;
403
+ }, 3e3);
404
+ } }, this.copiedButtonIndex === a ? "Copied!" : "Copy link"), e("button-component", { variant: "basic", key: `edit-${a}`, clickHandler: (n) => {
405
+ n.preventDefault(), this.editButtonClick.emit({ host: this.host, configuration: t });
406
+ } }, "Edit"), e("button-component", { variant: "basic", key: `delete-${a}`, clickHandler: (n) => {
407
+ n.preventDefault(), this.deleteButtonClick.emit({ host: this.host, configuration: t });
408
+ } }, "Delete"))))))), this.state === "error" && e("div", { class: "error-container" }, e("p", { class: "error" }, this.error)));
409
+ }
410
+ get host() {
411
+ return Q(this);
412
+ }
413
+ };
414
+ yt([
415
+ X({
416
+ name: "nylas-list-configurations",
417
+ stateToProps: /* @__PURE__ */ new Map([["schedulerConfig.configurations", "configurations"]]),
418
+ localPropsToProp: /* @__PURE__ */ new Map([["schedulerPreviewLink", "schedulerPreviewLink"]]),
419
+ eventToProps: {
420
+ initListConfigurations: async (t, a) => {
421
+ const n = t.detail;
422
+ await n.setState("loading");
423
+ const [s, o] = await a.schedulerConfig.getConfigurations();
424
+ if (!s && o && o.message) {
425
+ await n.setState("error"), await n.setError(o.message);
426
+ return;
427
+ }
428
+ await n.setState("loaded");
429
+ },
430
+ createButtonClick: async (t, a) => {
431
+ a.schedulerConfigStore.resetSelectedConfiguration(), a.schedulerConfigStore.state.action = "create";
432
+ },
433
+ deleteButtonClick: async (t, a) => {
434
+ const { host: n, configuration: s } = t.detail, [o, i] = await a.schedulerConfig.deleteConfiguration(s.id);
435
+ !o && i && i.message && (await n.setState("error"), await n.setError(i.message));
436
+ },
437
+ editButtonClick: async (t, a) => {
438
+ const { configuration: n } = t.detail;
439
+ a.schedulerConfigStore.state.selectedConfiguration = n, a.schedulerConfigStore.state.action = "edit";
440
+ }
441
+ },
442
+ fireRegisterEvent: !0
443
+ }),
444
+ O("design:type", Function),
445
+ O("design:paramtypes", []),
446
+ O("design:returntype", void 0)
447
+ ], tt.prototype, "render", null);
448
+ tt.style = ht;
449
+ export {
450
+ st as google_logo_icon,
451
+ lt as microsoft_logo_icon,
452
+ Y as nylas_editor_tabs,
453
+ tt as nylas_list_configurations
454
+ };