@nylas/react 1.1.0-canary.16 → 1.1.0-canary.18

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 (124) hide show
  1. package/dist/add-circle-icon_2.entry-3091976b.cjs +1 -0
  2. package/dist/add-circle-icon_2.entry-3b13ee64.js +25 -0
  3. package/dist/{archive-icon_7.entry-54dc5cc2.js → archive-icon_7.entry-8932618a.js} +19 -19
  4. package/dist/{archive-icon_7.entry-073d9915.cjs → archive-icon_7.entry-c2b6d860.cjs} +1 -1
  5. package/dist/{arrow-icon.entry-869a1db9.js → arrow-icon.entry-1f54c377.js} +4 -4
  6. package/dist/{arrow-icon.entry-bada78b8.cjs → arrow-icon.entry-a159bee8.cjs} +1 -1
  7. package/dist/{bold-icon_3.entry-5695177e.js → bold-icon_3.entry-447d0537.js} +10 -10
  8. package/dist/{bold-icon_3.entry-cc6150c9.cjs → bold-icon_3.entry-c51e1af3.cjs} +1 -1
  9. package/dist/{button-component.entry-a0533c8b.js → button-component.entry-52ccb6d9.js} +2 -2
  10. package/dist/{button-component.entry-3703ecff.cjs → button-component.entry-e79b2d08.cjs} +1 -1
  11. package/dist/{calendar-cancel-icon.entry-0f1d98b3.cjs → calendar-cancel-icon.entry-805febcc.cjs} +1 -1
  12. package/dist/{calendar-cancel-icon.entry-a9ab0b09.js → calendar-cancel-icon.entry-a78f27bc.js} +2 -2
  13. package/dist/{calendar-check-icon_2.entry-6b83717e.cjs → calendar-check-icon_2.entry-4a0fd7bd.cjs} +1 -1
  14. package/dist/{calendar-check-icon_2.entry-a62b5d2c.js → calendar-check-icon_2.entry-7c8b6c92.js} +3 -3
  15. package/dist/{calendar-icon.entry-08f83da9.cjs → calendar-icon.entry-1fc018b4.cjs} +1 -1
  16. package/dist/{calendar-icon.entry-ddc22561.js → calendar-icon.entry-96f9727f.js} +5 -5
  17. package/dist/calendar-info-icon_28.entry-2054703c.cjs +1 -0
  18. package/dist/{calendar-info-icon_27.entry-f02f44b7.js → calendar-info-icon_28.entry-e7bebd13.js} +527 -701
  19. package/dist/{chevron-icon_3.entry-f27202a2.js → chevron-icon_3.entry-25d90239.js} +6 -6
  20. package/dist/chevron-icon_3.entry-7bd4a4b5.cjs +1 -0
  21. package/dist/{clock-icon_2.entry-b7b8ef46.cjs → clock-icon_2.entry-2406c3d0.cjs} +1 -1
  22. package/dist/{clock-icon_2.entry-2277fd45.js → clock-icon_2.entry-c1b22ed4.js} +5 -5
  23. package/dist/{constants-f34b9c6e-ccdbc4ac.cjs → constants-f34b9c6e-b774916c.cjs} +1 -1
  24. package/dist/{constants-f34b9c6e-bbca6b6e.js → constants-f34b9c6e-f1c4dd0d.js} +1 -1
  25. package/dist/document-refresh-icon.entry-570f9c9d.js +15 -0
  26. package/dist/document-refresh-icon.entry-a0293858.cjs +1 -0
  27. package/dist/elements/index.d.ts +1 -0
  28. package/dist/{elements-dc5b338e-d48368b1.cjs → elements-dc5b338e-550a6cb1.cjs} +1 -1
  29. package/dist/{elements-dc5b338e-c4a07acc.js → elements-dc5b338e-cafa7a55.js} +1 -1
  30. package/dist/{focus-visible-e8093c16-10c0fa06.js → focus-visible-e8093c16-022799ce.js} +1 -1
  31. package/dist/{focus-visible-e8093c16-c86f3687.cjs → focus-visible-e8093c16-c14162e8.cjs} +1 -1
  32. package/dist/{forward-icon_6.entry-07cd4b52.cjs → forward-icon_6.entry-55752b23.cjs} +2 -2
  33. package/dist/{forward-icon_6.entry-39d788af.js → forward-icon_6.entry-9b832146.js} +9 -9
  34. package/dist/{globe-icon.entry-60a53e89.js → globe-icon.entry-2b61820e.js} +4 -4
  35. package/dist/{globe-icon.entry-76c90d97.cjs → globe-icon.entry-dabe7b8b.cjs} +1 -1
  36. package/dist/google-logo-icon_4.entry-60c0d39a.cjs +1 -0
  37. package/dist/google-logo-icon_4.entry-a0dc33da.js +467 -0
  38. package/dist/index-53420959-67beefed.js +5 -0
  39. package/dist/index-53420959-d3254a34.cjs +1 -0
  40. package/dist/{index-6d9eeb53-66c114b2.cjs → index-6d9eeb53-3049fc04.cjs} +1 -1
  41. package/dist/{index-6d9eeb53-38c9f47c.js → index-6d9eeb53-3edef246.js} +2 -2
  42. package/dist/{index-f383e3c4.js → index-812162da.js} +902 -901
  43. package/dist/{index-f435e814.cjs → index-e3e9b594.cjs} +3 -3
  44. package/dist/{index.es-9cc0eb3c-09dc620b.cjs → index.es-9cc0eb3c-0c99c055.cjs} +1 -1
  45. package/dist/{index.es-9cc0eb3c-510db795.js → index.es-9cc0eb3c-52226859.js} +1 -1
  46. package/dist/{info-icon_2.entry-a61859ac.js → info-icon_2.entry-2fe6c16c.js} +8 -8
  47. package/dist/{info-icon_2.entry-7fe8bcd9.cjs → info-icon_2.entry-5f6b9af8.cjs} +1 -1
  48. package/dist/{input-component.entry-12f60175.js → input-component.entry-1195d579.js} +6 -6
  49. package/dist/{input-component.entry-04dcc655.cjs → input-component.entry-2b6e44c4.cjs} +1 -1
  50. package/dist/{input-dropdown_2.entry-0e5925a7.js → input-dropdown_2.entry-dbd0d6f4.js} +35 -28
  51. package/dist/input-dropdown_2.entry-dbdb5aa3.cjs +1 -0
  52. package/dist/loading-icon.entry-027a2ad1.js +15 -0
  53. package/dist/{loading-icon.entry-f82786b4.cjs → loading-icon.entry-e179f122.cjs} +1 -1
  54. package/dist/{mailbox-store-64b4ef7c-1e6c96cc.cjs → mailbox-store-64b4ef7c-0eac526c.cjs} +1 -1
  55. package/dist/{mailbox-store-64b4ef7c-017196a6.js → mailbox-store-64b4ef7c-22a6c565.js} +2 -2
  56. package/dist/nylas-booked-event-card_10.entry-84f64ba5.cjs +1 -0
  57. package/dist/{nylas-booked-event-card_10.entry-2dff7f16.js → nylas-booked-event-card_10.entry-e0990f5b.js} +170 -170
  58. package/dist/{nylas-custom-booking-flow.entry-36f7a943.cjs → nylas-custom-booking-flow.entry-898c8cc9.cjs} +1 -1
  59. package/dist/{nylas-custom-booking-flow.entry-feed589b.js → nylas-custom-booking-flow.entry-bc64af5f.js} +7 -7
  60. package/dist/{nylas-form-card.entry-e9f09602.cjs → nylas-form-card.entry-0c71f4fc.cjs} +1 -1
  61. package/dist/{nylas-form-card.entry-49f519dd.js → nylas-form-card.entry-c564b52e.js} +9 -9
  62. package/dist/{nylas-if-state.entry-127694a9.js → nylas-if-state.entry-e9486e12.js} +3 -3
  63. package/dist/{nylas-if-state.entry-81916723.cjs → nylas-if-state.entry-ff6a2046.cjs} +1 -1
  64. package/dist/{nylas-list-folders.entry-e3e9ec1f.js → nylas-list-folders.entry-0258af1e.js} +7 -7
  65. package/dist/{nylas-list-folders.entry-f4c68fb9.cjs → nylas-list-folders.entry-90716d2b.cjs} +1 -1
  66. package/dist/{nylas-list-threads.entry-fa4b5318.js → nylas-list-threads.entry-1abcdd30.js} +3 -3
  67. package/dist/{nylas-list-threads.entry-f0a1b9d1.cjs → nylas-list-threads.entry-21edf012.cjs} +1 -1
  68. package/dist/{nylas-login.entry-aeac716e.cjs → nylas-login.entry-2e0ce95e.cjs} +1 -1
  69. package/dist/{nylas-login.entry-6d17e994.js → nylas-login.entry-ba7383ac.js} +3 -3
  70. package/dist/{nylas-mailbox-pagination.entry-50fba238.cjs → nylas-mailbox-pagination.entry-ba6beb08.cjs} +1 -1
  71. package/dist/{nylas-mailbox-pagination.entry-c440f56a.js → nylas-mailbox-pagination.entry-f6186560.js} +2 -2
  72. package/dist/{nylas-mailbox-toolbar-button.entry-d3d0c870.cjs → nylas-mailbox-toolbar-button.entry-0875aadb.cjs} +1 -1
  73. package/dist/{nylas-mailbox-toolbar-button.entry-14e30d36.js → nylas-mailbox-toolbar-button.entry-e18059b0.js} +10 -10
  74. package/dist/{nylas-mailbox.entry-a59159c7.js → nylas-mailbox.entry-2e3815ed.js} +4 -4
  75. package/dist/{nylas-mailbox.entry-2fdb3d4c.cjs → nylas-mailbox.entry-bb2905bf.cjs} +1 -1
  76. package/dist/{nylas-provider.entry-dfa8c7c1.cjs → nylas-provider.entry-51c5cdbf.cjs} +1 -1
  77. package/dist/{nylas-provider.entry-d7dbb5fc.js → nylas-provider.entry-69ee5061.js} +13 -13
  78. package/dist/{nylas-scheduler-editor.entry-67e71234.cjs → nylas-scheduler-editor.entry-923b8566.cjs} +2 -2
  79. package/dist/{nylas-scheduler-editor.entry-3b44b807.js → nylas-scheduler-editor.entry-d4a9afb1.js} +5 -5
  80. package/dist/{nylas-scheduling.entry-0ce0dab9.cjs → nylas-scheduling.entry-54f1a5e9.cjs} +1 -1
  81. package/dist/{nylas-scheduling.entry-68f72bf7.js → nylas-scheduling.entry-f82a2822.js} +3 -3
  82. package/dist/{nylas-threads-refresh.entry-23a83bd4.js → nylas-threads-refresh.entry-72482d2f.js} +10 -10
  83. package/dist/{nylas-threads-refresh.entry-955e92c7.cjs → nylas-threads-refresh.entry-99001756.cjs} +1 -1
  84. package/dist/{nylas-threads-search.entry-2fb6db63.cjs → nylas-threads-search.entry-462527fd.cjs} +1 -1
  85. package/dist/{nylas-threads-search.entry-8f01ee4a.js → nylas-threads-search.entry-c5fe50e5.js} +14 -14
  86. package/dist/nylas-time-window-picker.entry-0d93e7cc.js +316 -0
  87. package/dist/nylas-time-window-picker.entry-ccffcf2b.cjs +1 -0
  88. package/dist/{nylas-view-thread.entry-b957f88b.js → nylas-view-thread.entry-2d34b41c.js} +6 -6
  89. package/dist/{nylas-view-thread.entry-3cf0c1ac.cjs → nylas-view-thread.entry-58432a52.cjs} +1 -1
  90. package/dist/play-icon_2.entry-1ea3fd6b.cjs +1 -0
  91. package/dist/{play-icon_2.entry-ecdf8ea4.js → play-icon_2.entry-d08adf17.js} +7 -7
  92. package/dist/react.cjs +1 -1
  93. package/dist/react.js +41 -40
  94. package/dist/{refresh-icon.entry-76e58ccb.cjs → refresh-icon.entry-1e670732.cjs} +1 -1
  95. package/dist/{refresh-icon.entry-480d28aa.js → refresh-icon.entry-a041136d.js} +4 -4
  96. package/dist/{register-component-a5a9ca5d-438c8a96.js → register-component-a5a9ca5d-a5c01c35.js} +1 -1
  97. package/dist/{register-component-a5a9ca5d-ebf633cf.cjs → register-component-a5a9ca5d-b68b6039.cjs} +1 -1
  98. package/dist/{scheduler-config-store-4a50a03d-d5a5899e.cjs → scheduler-config-store-4a50a03d-884e6df8.cjs} +1 -1
  99. package/dist/{scheduler-config-store-4a50a03d-defa6368.js → scheduler-config-store-4a50a03d-ee42ff96.js} +1 -1
  100. package/dist/{scheduler-store-f02ce045-de4cb1f5.js → scheduler-store-f02ce045-23a14e3f.js} +1 -1
  101. package/dist/{scheduler-store-f02ce045-00faab09.cjs → scheduler-store-f02ce045-42e3647c.cjs} +1 -1
  102. package/dist/{textarea-component.entry-1c8d11af.js → textarea-component.entry-1b4c771b.js} +4 -4
  103. package/dist/{textarea-component.entry-5ff249a8.cjs → textarea-component.entry-24a830c1.cjs} +1 -1
  104. package/dist/{translate-icon.entry-a55c013b.cjs → translate-icon.entry-0c0add25.cjs} +1 -1
  105. package/dist/{translate-icon.entry-3741cac0.js → translate-icon.entry-44bde57b.js} +2 -2
  106. package/dist/{warning-icon.entry-445352b5.js → warning-icon.entry-8956cba2.js} +5 -5
  107. package/dist/{warning-icon.entry-1a104c52.cjs → warning-icon.entry-9a77ab01.cjs} +1 -1
  108. package/package.json +2 -2
  109. package/dist/add-circle-icon_2.entry-035ffd48.cjs +0 -1
  110. package/dist/add-circle-icon_2.entry-5cadaf97.js +0 -25
  111. package/dist/calendar-info-icon_27.entry-a8390790.cjs +0 -1
  112. package/dist/chevron-icon_3.entry-978b52d5.cjs +0 -1
  113. package/dist/document-refresh-icon.entry-5795e2a9.cjs +0 -1
  114. package/dist/document-refresh-icon.entry-656a5e02.js +0 -15
  115. package/dist/google-logo-icon_4.entry-5402eae2.cjs +0 -1
  116. package/dist/google-logo-icon_4.entry-d327d68f.js +0 -438
  117. package/dist/index-53420959-791b4e73.js +0 -5
  118. package/dist/index-53420959-9f979766.cjs +0 -1
  119. package/dist/input-dropdown_2.entry-d9bff099.cjs +0 -1
  120. package/dist/loading-icon.entry-51ddd748.js +0 -15
  121. package/dist/nylas-booked-event-card_10.entry-5a9a4cc6.cjs +0 -1
  122. package/dist/play-icon_2.entry-c92d5237.cjs +0 -1
  123. package/dist/toggle-switch.entry-26d3d1c9.cjs +0 -1
  124. package/dist/toggle-switch.entry-339ab48b.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-f383e3c4.js";
2
- import { R as wn } from "./register-component-a5a9ca5d-438c8a96.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-812162da.js";
2
+ import { R as wn } from "./register-component-a5a9ca5d-a5c01c35.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: "56e947b67fe88f2a095cca9a0dd4c3ca9e570e7f", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "6d6da4d1c35613bdedc7fac5d2d8f0e6f2c3042c", 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: "7537b7c56a1e609f88189c2c4deed986827eb193" }, g("sp-theme", { key: "efa28f8ed5585ec21b44ae5ec174aa10a9c92aba", scale: "medium", color: "dark" }, g("div", { key: "c7932bcedcb2b3cfa4e0900578cf2b749000125d", class: "editor", contentEditable: !0, ref: (t) => this.editorEl = t }, g("div", { key: "89c06c0e76d29ea6713dd44b2452e261d0d7d43b", class: "toolbar", ref: (t) => this.toolbarEl = t, contentEditable: !1 }, g("sp-button", { key: "beeb60448f03c8818925aeb13ab5231aa72f7526", quiet: !0, onClick: () => document.execCommand("bold") }, g("div", { key: "4e37be81a28ac4355f9d0d6d6c71b7b78cf41456", slot: "icon" }, g("bold-icon", { key: "56cf047799a6a5713310d5b095ca91e6004d6107" })), g("div", { key: "2fe47f8f364f7fb1016990f2aecec655e2e6eb30", slot: "label" }, "Bold")), g("sp-button", { key: "0416d13b88ccefd5005f4b97f7dded2118d37f43", quiet: !0, onClick: () => document.execCommand("underline") }, g("div", { key: "6d20e215eafbb91a17ce452a6b64295ab4ef2bb9", slot: "icon" }, g("underline-icon", { key: "b8d988fa168047ed213fbcceb53b24bf3f766d7a" })), g("div", { key: "bd05639007b3ea849501b995137ceda70aed20da", slot: "label" }, "Underline")), g("sp-button", { key: "9775c4787363cd4d21778f4c848c7f5a7564b507", quiet: !0, onClick: () => document.execCommand("italic") }, g("div", { key: "ca9d557028981c0fe209045e5d1748b19bbb5069", slot: "icon" }, g("italic-icon", { key: "1be5debba3572e83ab132a3e44d8fc1e799f6619" })), g("div", { key: "cccb70309840e20f558158e6ef9edf8fe0e52eed", slot: "label" }, "Italic")))), g("div", { key: "502854e008886de49ec435c1ebd73b48f2cc4c70", class: "buttons" }, g("sp-button", { key: "9663a709ca8794dc76dec379a39c52a6a754cb6e", onClick: this.sendComposer, class: "send" }, "Send"), g("sp-button", { key: "b0c7637932f2659c9115e74f1244db04992a69aa", 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: "977e97a8d9e6f0d5c3f56a8cedcdb18c65a18007" }, g("sp-theme", { key: "3e3e9a385317466347c5e4bac4cac584dc603063", scale: "medium", color: "dark" }, g("sp-button", { key: "4e47a9b38e47991c64236d567df1341df0a7a2b3", 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: "0a0a952634d68aeab930d9a0c9feb07a1dea2828", 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: "4f0a1e688ae465d65943adc7dabac9cad6c62fe8" }, 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: "27304a19b7ec5d4fb64051ba1edbd99699adc3c5", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "185831a5360ae2e5b3559e22839c38fe8667e027", 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: "8f2d5daffb8ab92a42abacce15e2abd868f979a7", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "fcad20369efbf76e019c7b433e380419c696e481", 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-f383e3c4.js";
1
+ import { r as e, h as C } from "./index-812162da.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: "e118f6587042dbd2405c644943d89e7711e9a384", xmlns: "http://www.w3.org/2000/svg", width: this.width, height: this.height, viewBox: "0 0 16 16", fill: "none" }, C("path", { key: "05682560c53869ae2fd5a8531736f511386a0db2", 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-f435e814.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-e3e9b594.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:"e118f6587042dbd2405c644943d89e7711e9a384",xmlns:"http://www.w3.org/2000/svg",width:this.width,height:this.height,viewBox:"0 0 16 16",fill:"none"},e.h("path",{key:"05682560c53869ae2fd5a8531736f511386a0db2",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 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-e3e9b594.cjs"),Y=require("./register-component-a5a9ca5d-b68b6039.cjs"),X=require("./constants-f34b9c6e-b774916c.cjs");require("react");require("react-dom");const st=".sc-google-logo-icon-h{display:flex}",ot=st,tt=class{constructor(t){e.registerInstance(this,t),this.width="24",this.height="24"}render(){return e.h("svg",{key:"0e9d7d49a7c9b6cd2087805b88f0e5a2067dfaed",width:this.width,height:this.height,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.h("g",{key:"e97ac24bfe96bdba16a9709dde3ebc675e942d56","clip-path":"url(#clip0_959_12452)"},e.h("path",{key:"231167532157853cb95fddc85fa8cffcf1134ef4",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.h("path",{key:"4f964a28a6b0894940c9d762a91db0c099f6c2c7",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.h("path",{key:"9ada4b2f2625f18538ff4455b1160efcfccbd646",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.h("path",{key:"6a260b3024a69fa930820a80a917152dc7ef52a7",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.h("defs",{key:"56bc051b67a1bfa29ecaf64bac03ee1017836365"},e.h("clipPath",{key:"8057800f9035048497e8198789e1e0b4dba1c64a",id:"clip0_959_12452"},e.h("rect",{key:"6c0299822390d3433158d87c607fe9546e878eb0",width:24,height:24,fill:"white"}))))}};tt.style=ot;const rt=".sc-microsoft-logo-icon-h{display:flex}",lt=rt,et=class{constructor(t){e.registerInstance(this,t),this.width="22",this.height="22"}render(){return e.h("svg",{key:"3dd5e1a94ca5889c14f7695c9077f9be0cbc4d00",width:this.width,height:this.height,viewBox:"0 0 22 22",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.h("path",{key:"381068331f74d7f1a06c0ca0cd9dfc2b58f72a10",d:"M0.043457 0.043457H10.4782V10.4782H0.043457V0.043457Z",fill:"#F35325"}),e.h("path",{key:"62c7be7371433602169a19fe2657e0a1635f516e",d:"M11.5217 0.043457H21.9565V10.4782H11.5217V0.043457Z",fill:"#81BC06"}),e.h("path",{key:"72464e489d4cfd78f016282a743a1000fb732368",d:"M0.043457 11.5217H10.4782V21.9565H0.043457V11.5217Z",fill:"#05A6F0"}),e.h("path",{key:"d766c4d950ee3122cf4916b53ce5f630b52a30bb",d:"M11.5217 11.5217H21.9565V21.9565H11.5217V11.5217Z",fill:"#FFBA08"}))}};et.style=lt;function ct({id:t,formState:n,activeTab:a,calendars:s}){var o;switch(a){case"eventInfo":const i=n.title,l=n.description,r=parseInt(n.duration),c=n.location;return e.h("div",{key:t},e.h("nylas-event-info",null,e.h("div",{slot:"inputs"},e.h("nylas-event-title",{name:"title",eventTitle:i,exportparts:"net, net__title, net__dropdown-content"}),e.h("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"}),e.h("nylas-event-location",{name:"location",eventLocation:c,exportparts:"nel, nel__location, nel__dropdown, nel__dropdown-button, nel__dropdown-content"}),e.h("nylas-event-description",{name:"description",eventDescription:l,exportparts:"nedesc, nedesc__textarea"}))));case"availability":const d=n.availability.openHours,f=n.availability.timezone?n.availability.timezone:Intl.DateTimeFormat().resolvedOptions().timeZone,u=(o=n.participants)==null?void 0:o.find(w=>w.is_organizer),g=(u==null?void 0:u.email)??"primary",_=n.calendarIds.length>0?n.calendarIds:[g],v=n.bookingCalendar=="primary"?g:n.bookingCalendar;return e.h("div",{key:t},e.h("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"}),e.h("nylas-calendar-picker",{name:"calendars",calendars:s??[],defaultSelectedCalendars:_,exportparts:"ncp ncp__header, ncp__dropdown, ncp__dropdown-button, ncp__dropdown-content"}),e.h("nylas-availability-picker",{name:"availability",openHours:d,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"}));case"bookingOptions":return e.h("div",{key:t},e.h("nylas-buffer-time",{name:"buffer-time",buffer:n.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"}),e.h("nylas-event-limits",null,e.h("div",{slot:"inputs"},e.h("nylas-min-booking-notice",{name:"min-booking-notice",minBookingNotice:n.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"}),e.h("nylas-limit-future-bookings",{name:"limit-future-bookings",availableDaysInFuture:n.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"}),e.h("nylas-min-cancellation-notice",{name:"min-cancellation-notice",minCancellationNotice:n.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"}),e.h("nylas-cancellation-policy",{name:"cancellation-policy",cancellationPolicy:n.cancellationPolicy,exportparts:"ncpolicy, ncpolicy__textarea"}))),e.h("nylas-timeslot-interval",{name:"timeslot-interval",eventDurationMinutes:parseInt(n.duration),exportparts:"nti, nti__header, nti__input-label, nti__dropdown, nti__dropdown-button, nti__dropdown-content"}),e.h("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"}));case"participants":return e.h("div",{key:t},e.h("nylas-additional-participants",{name:"participants",eventParticipants:n.participants,exportparts:"nap__title, nap__subtitle, nap__content, nap__input_group, nap__input_wrapper, nap__input, nap__remove-participant"}),e.h("nylas-participants-custom-availability",{name:"participant-custom-availability",participants:n.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"}))}}const dt='.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}',ht=dt;var bt=function(t,n,a,s){var o=arguments.length,i=o<3?n:s===null?s=Object.getOwnPropertyDescriptor(n,a):s,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,n,a,s);else for(var r=t.length-1;r>=0;r--)(l=t[r])&&(i=(o<3?l(i):o>3?l(n,a,i):l(n,a))||i);return o>3&&i&&Object.defineProperty(n,a,i),i},D=function(t,n){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(t,n)};const E=class{constructor(t){e.registerInstance(this,t),this.schedulerConfigChanged=e.createEvent(this,"schedulerConfigChanged",7),this.cancelButtonClick=e.createEvent(this,"cancelButtonClick",7),this.formSubmitted=e.createEvent(this,"formSubmitted",7),this.previewButtonClicked=e.createEvent(this,"previewButtonClicked",7),this.setError=n=>{this.error=n.message},this.formSubmissionHandler=async n=>{var F,O,P,R,N,j,M,z,U,V,A,$,Z,G,J,q;if(n.preventDefault(),this.formSubmitted.emit(),!this.formRef.checkValidity())return;this.isLoading=!0,this.hasUnsavedChanges=!1;const s=this.updateFormState(),{title:o,description:i,duration:l,availability:r,calendarIds:c,bookingCalendar:d,location:f,bookingType:u,buffer:g,availableDaysInFuture:_,minCancellationNotice:v,minBookingNotice:w,cancellationPolicy:x,timeslotInterval:p,additionalGuestsHidden:S,hideCancellationOptions:L,hideReschedulingOptions:B,participants:m,participantOpenHours:y}=s,b=(O=(F=this.selectedConfiguration)==null?void 0:F.participants)==null?void 0:O.find(h=>h.is_organizer),C=l?parseInt(l):30,k=m&&(m==null?void 0:m.length)>0?m:[{name:(b==null?void 0:b.name)??((P=this.currentUser)==null?void 0:P.name)??(b==null?void 0:b.email)??((R=this.currentUser)==null?void 0:R.email)??"",email:(b==null?void 0:b.email)??((N=this.currentUser)==null?void 0:N.email)??"",is_organizer:!0,availability:{calendar_ids:c!=null&&c.length?c:["primary"],open_hours:[]},booking:{calendar_id:d&&d!==""?d:"primary"}}],T={...((j=this.selectedConfiguration)==null?void 0:j.id)&&{id:this.selectedConfiguration.id},version:((M=this.selectedConfiguration)==null?void 0:M.version)??"1.0.0",availability:{duration_minutes:C,interval_minutes:(p==null?void 0:p.interval)??C,round_to:p==null?void 0:p.roundTo,availability_rules:{availability_method:((V=(U=(z=this.selectedConfiguration)==null?void 0:z.availability)==null?void 0:U.availability_rules)==null?void 0:V.availability_method)??"collective",buffer:g||{before:0,after:0},default_open_hours:(r==null?void 0:r.openHours)??((Z=($=(A=this.selectedConfiguration)==null?void 0:A.availability)==null?void 0:$.availability_rules)==null?void 0:Z.default_open_hours)??X.DEFAULT_OPEN_HOURS,round_robin_group_id:((q=(J=(G=this.selectedConfiguration)==null?void 0:G.availability)==null?void 0:J.availability_rules)==null?void 0:q.round_robin_group_id)??""}},participants:[...k==null?void 0:k.map(h=>{var W,K,Q;return h.is_organizer?{name:h.name??h.email,email:h.email,is_organizer:!0,availability:{calendar_ids:c!=null&&c.length?c:["primary"],open_hours:(y==null?void 0:y[h.email])??((W=h.availability)==null?void 0:W.open_hours)??[]},booking:{calendar_id:d&&d!==""?d:"primary"}}:{...h,availability:{calendar_ids:((K=h.availability)==null?void 0:K.calendar_ids)??["primary"],open_hours:(y==null?void 0:y[h.email])??((Q=h.availability)==null?void 0:Q.open_hours)??[]}}})],event_booking:{title:(o==null?void 0:o.toString())??"",description:(i==null?void 0:i.toString())??"",location:(f==null?void 0:f.toString())??"",booking_type:(u==null?void 0:u.toString())??"booking",timezone:(r==null?void 0:r.timezone)??Intl.DateTimeFormat().resolvedOptions().timeZone},scheduler:{cancellation_policy:x??"",available_days_in_future:_??30,min_cancellation_notice:v??0,min_booking_notice:w??60,hide_additional_guests:S??!1,hide_cancellation_options:L??!1,hide_rescheduling_options:B??!1}},nt=e.mergeDeep(T,this.selectedConfiguration),at=this.action==="create"?nt:T,it=h=>{this.isLoading=!1,this.changesSaved=!0,setTimeout(()=>{this.changesSaved=!1},5e3)};this.schedulerConfigChanged.emit({config:at,resetLoadingState:it,setError:this.setError,action:this.action})},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=""}configChangedHandler(t){e.debug("[nylas-editor-tabs]","configChangedHandler",t,this.selectedConfiguration),this.formState={...this.getFormStateFromConfig(t)},t.id?this.action="edit":this.action="create"}connectedCallback(){e.debug("[nylas-editor-tabs]","connectedCallback")}componentWillLoad(){e.debug("[nylas-editor-tabs]","componentWillLoad"),this.formState=this.getFormStateFromConfig(this.selectedConfiguration)}componentDidLoad(){e.debug("[nylas-editor-tabs]","componentDidLoad")}disconnectedCallback(){e.debug("[nylas-editor-tabs]","disconnectedCallback")}handleValueChanged(t){e.debug("[nylas-editor-tabs]","handleValueChanged",t);const{name:n,value:a}=t.detail;this.setFormState(a,n),this.formState={...this.formState},this.hasUnsavedChanges=!0,this.error=""}getFormStateFromConfig(t){var a,s,o,i,l,r,c,d,f,u,g,_,v,w,x,p,S,L,B,m,y,b,C,k;const n=(a=t==null?void 0:t.participants)==null?void 0:a.find(T=>T.is_organizer);return{title:((s=t==null?void 0:t.event_booking)==null?void 0:s.title)??"",description:((o=t==null?void 0:t.event_booking)==null?void 0:o.description)??"",duration:((l=(i=t==null?void 0:t.availability)==null?void 0:i.duration_minutes)==null?void 0:l.toString())??"30",availability:{timezone:((r=t==null?void 0:t.event_booking)==null?void 0:r.timezone)??Intl.DateTimeFormat().resolvedOptions().timeZone,openHours:((d=(c=t==null?void 0:t.availability)==null?void 0:c.availability_rules)==null?void 0:d.default_open_hours)??X.DEFAULT_OPEN_HOURS},calendarIds:((f=n==null?void 0:n.availability)==null?void 0:f.calendar_ids)??[],participants:(t==null?void 0:t.participants)??[],bookingCalendar:((u=n==null?void 0:n.booking)==null?void 0:u.calendar_id)??(n==null?void 0:n.email)??"",location:((g=t==null?void 0:t.event_booking)==null?void 0:g.location)??"",bookingType:((_=t==null?void 0:t.event_booking)==null?void 0:_.booking_type)??"booking",buffer:((w=(v=t==null?void 0:t.availability)==null?void 0:v.availability_rules)==null?void 0:w.buffer)??{before:0,after:0},cancellationPolicy:((x=t==null?void 0:t.scheduler)==null?void 0:x.cancellation_policy)??"",availableDaysInFuture:((p=t==null?void 0:t.scheduler)==null?void 0:p.available_days_in_future)??30,minCancellationNotice:((S=t==null?void 0:t.scheduler)==null?void 0:S.min_cancellation_notice)??0,minBookingNotice:((L=t==null?void 0:t.scheduler)==null?void 0:L.min_booking_notice)??60,timeslotInterval:{interval:((B=t==null?void 0:t.availability)==null?void 0:B.interval_minutes)??((m=t==null?void 0:t.availability)==null?void 0:m.duration_minutes)??10,roundTo:(y=t==null?void 0:t.availability)==null?void 0:y.round_to},additionalGuestsHidden:((b=t==null?void 0:t.scheduler)==null?void 0:b.hide_additional_guests)??!1,hideCancellationOptions:((C=t==null?void 0:t.scheduler)==null?void 0:C.hide_cancellation_options)??!1,hideReschedulingOptions:((k=t==null?void 0:t.scheduler)==null?void 0:k.hide_rescheduling_options)??!1}}setFormState(t,n){switch(n){case"title":this.formState.title=t.toString();break;case"description":this.formState.description=t.toString();break;case"duration":this.formState.duration=t.toString();break;case"availability":this.formState.availability=JSON.parse(t.toString());break;case"participants":this.formState.participants=JSON.parse(t.toString());break;case"calendars":this.formState.calendarIds=t.toString().split(",");break;case"booking-calendar":this.formState.bookingCalendar=t.toString();break;case"location":this.formState.location=t.toString();break;case"booking-type":this.formState.bookingType=t.toString();break;case"buffer-time":this.formState.buffer=JSON.parse(t.toString());break;case"limit-future-bookings":this.formState.availableDaysInFuture=parseInt(t.toString());break;case"min-cancellation-notice":this.formState.minCancellationNotice=parseInt(t.toString());break;case"min-booking-notice":this.formState.minBookingNotice=parseInt(t.toString());break;case"cancellation-policy":this.formState.cancellationPolicy=t.toString();break;case"timeslot-interval":this.formState.timeslotInterval=JSON.parse(t.toString());break;case"customize-booking-settings":const a=JSON.parse(t.toString());this.formState.additionalGuestsHidden=a.additionalGuestsHidden,this.formState.hideCancellationOptions=a.hideCancellationOptions,this.formState.hideReschedulingOptions=a.hideReschedulingOptions;break;case"participant-custom-availability":const s=JSON.parse(t.toString());this.formState.participantOpenHours=s;break}}updateFormState(){return new FormData(this.formRef).forEach((n,a)=>{this.setFormState(n,a)}),this.formState={...this.formState},this.formState}setActiveTab(t,n){t.preventDefault(),this.updateFormState(),this.activeTab=n}render(){var n;e.debug("[nylas-editor-tabs]","render",this.formState);const t=localStorage.getItem("nylas")==="Nylas Developer";return e.h(e.Host,{key:"13aad28cba8de3b30e60d7a26849d30ef2578bb5"},e.h("form",{key:"31e835f74ca7728d597148a18c840e0791c34c89",onSubmit:this.formSubmissionHandler,class:"scheduler-editor",ref:a=>this.formRef=a,noValidate:!0},this.mode==="app"?e.h("div",{class:"form-contents"},e.h("div",{class:"tabs"},e.h("button",{class:{tab:!0,active:this.activeTab=="eventInfo"},onClick:a=>this.setActiveTab(a,"eventInfo")},e.h("calendar-info-icon",{width:"16",height:"16"}),"Event Info"),e.h("button",{class:{tab:!0,active:this.activeTab=="availability"},onClick:a=>this.setActiveTab(a,"availability")},e.h("calendar-patterns-icon",{width:"16",height:"16"}),"Availability"),e.h("button",{class:{tab:!0,active:this.activeTab=="bookingOptions"},onClick:a=>this.setActiveTab(a,"bookingOptions")},e.h("flow-icon",{width:"16",height:"16"}),"Booking Options"),t&&e.h("button",{class:{tab:!0,active:this.activeTab=="participants"},onClick:a=>this.setActiveTab(a,"participants")},e.h("people-icon",{width:"16",height:"16"}),"Participants")),e.h("div",{class:"tab-content"},e.h(ct,{formState:this.formState,activeTab:this.activeTab,calendars:this.calendars,id:((n=this.selectedConfiguration)==null?void 0:n.id)??"new"}))):e.h("slot",null),e.h("div",{key:"e83274ed2d92f179c90564a21f80ba869d1033a2",class:"footer"},e.h("div",{key:"c661b7a0c024f7b8f1c916b55bc5784a10ee9958",class:"preview"},this.schedulerPreviewLink!==""&&this.action==="edit"&&e.h("button-component",{type:"button",disabled:this.isLoading,clickHandler:a=>{a.preventDefault(),this.previewButtonClicked.emit(this.host).defaultPrevented||window.open(e.parsePreviewLink(this.schedulerPreviewLink,this.selectedConfiguration),"_blank")},variant:"basic"},"Preview")),e.h("div",{key:"78cb89dbbb6e124aaddf9b486834e81ab10ea70a",class:"buttons"},e.h("p",{key:"e07f651a081607471d067aa05a3858446725a6db",class:{"unsaved-changes":this.hasUnsavedChanges&&!this.changesSaved,"saved-changes":this.changesSaved,error:this.error!=="","error-full-width":this.error!==""&&this.action==="create"}},this.error!==""?this.error:"",this.error==""&&this.hasUnsavedChanges&&!this.changesSaved?"Unsaved changes":this.error==""&&this.changesSaved?"Changes saved!":""),e.h("button-component",{key:"66500ec7f10c2a5ecb6d98647766e2f31f030fe4",type:"button",disabled:this.isLoading,clickHandler:a=>{a.preventDefault(),this.cancelButtonClick.emit(),this.error=""},variant:"basic"},"Cancel"),e.h("button-component",{key:"a816e4c9d7d1f53e09edf635f06c9a177bdcb15a",type:"submit",disabled:this.isLoading},this.isLoading?e.h("span",null,"Saving",e.h("loading-icon",null)," "):this.action=="create"?"Create":"Save changes")))))}get host(){return e.getElement(this)}static get watchers(){return{selectedConfiguration:["configChangedHandler"]}}};bt([Y.RegisterComponent({name:"nylas-editor-tabs",stateToProps:new Map([["schedulerConfig.calendars","calendars"],["schedulerConfig.selectedConfiguration","selectedConfiguration"],["schedulerConfig.currentUser","currentUser"]]),eventToProps:{schedulerConfigChanged:async(t,n)=>{const{resetLoadingState:a,setError:s,action:o,config:i}=t.detail,l=r=>{const[c,d]=r;!c&&d&&s&&s(d),a&&a(t)};if(o==="edit"){const r=await n.schedulerConfig.updateConfiguration(i);l(r)}else{const r=await n.schedulerConfig.createConfiguration(i);l(r)}},cancelButtonClick:async(t,n)=>{n.schedulerConfigStore.state.action=null},previewButtonClicked:async(t,n)=>{e.debug("[nylas-editor-tabs]","previewButtonClicked",n)},formSubmitted:async(t,n)=>{e.debug("[nylas-editor-tabs]","formSubmitted",n)}},localPropsToProp:new Map([["schedulerPreviewLink","schedulerPreviewLink"]]),fireRegisterEvent:!0}),D("design:type",Function),D("design:paramtypes",[]),D("design:returntype",void 0)],E.prototype,"render",null);E.style=ht;const ut=':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}',pt=ut;var yt=function(t,n,a,s){var o=arguments.length,i=o<3?n:s===null?s=Object.getOwnPropertyDescriptor(n,a):s,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,n,a,s);else for(var r=t.length-1;r>=0;r--)(l=t[r])&&(i=(o<3?l(i):o>3?l(n,a,i):l(n,a))||i);return o>3&&i&&Object.defineProperty(n,a,i),i},H=function(t,n){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(t,n)};const I=class{constructor(t){e.registerInstance(this,t),this.initListConfigurations=e.createEvent(this,"initListConfigurations",7),this.createButtonClick=e.createEvent(this,"createButtonClick",7),this.editButtonClick=e.createEvent(this,"editButtonClick",7),this.deleteButtonClick=e.createEvent(this,"deleteButtonClick",7),this.configurations=[],this.schedulerPreviewLink="",this.state="loading",this.error="",this.copiedButtonIndex=-1}connectedCallback(){e.debug("[nylas-list-configurations]","connectedCallback")}componentWillLoad(){e.debug("[nylas-list-configurations]","componentWillLoad"),this.configurations&&this.configurations.length>0&&(this.state="loaded")}componentDidLoad(){e.debug("[nylas-list-configurations]","componentDidLoad"),this.initListConfigurations.emit(this.host)}disconnectedCallback(){e.debug("[nylas-list-configurations]","disconnectedCallback")}async getState(){return this.state}async setState(t){this.state=t}async setError(t){this.error=t}getDurationString(t){const n=Math.floor(t/60),a=t%60;return`${n||""} ${n?`${n>1?"hours":"hour"}`:""} ${a||""} ${a?`${a>1?"mins":"min"}`:""}`}render(){return e.h(e.Host,null,e.h("div",{class:"header"},e.h("div",{class:"description"},e.h("h2",null,"All scheduling pages"),e.h("p",null,"Create, edit and manage all your scheduling pages.")),this.configurations&&this.configurations.length>0&&e.h("div",{class:"actions"},e.h("button-component",{clickHandler:()=>{this.createButtonClick.emit(this.host)}},"Create new"))),e.h("div",{class:"configurations"},e.h("table",{class:{"no-configurations":this.state!=="loading"&&(!this.configurations||this.configurations.length===0)}},e.h("tr",{class:{hide:this.state==="loading"||this.configurations&&this.configurations.length===0}},e.h("th",null,"Scheduling page title"),e.h("th",null,"Duration"),e.h("th",{class:"actions-header"},"Actions")),this.state==="loading"&&e.h("tr",{class:"no-configurations"},e.h("td",{colSpan:3},e.h("div",null,e.h("h3",null,"Loading..."),e.h("p",null,"Please wait while we fetch the scheduling pages")))),this.state!=="loading"&&(!this.configurations||this.configurations.length===0)&&e.h("tr",{class:"no-configurations"},e.h("td",{colSpan:3},e.h("div",null,e.h("calendar-icon",{width:"48",height:"48"}),e.h("h3",null,"No scheduling pages found"),e.h("p",null,"Get started with creating your first scheduling page"),e.h("button-component",{clickHandler:()=>{this.createButtonClick.emit(this.host)}},"Create new")))),this.state!=="loading"&&this.configurations.map((t,n)=>e.h("tr",{key:t.id},e.h("td",null,e.h("div",{class:"title"},e.h("span",{class:"config-event-title"},t.event_booking.title),e.h("span",{class:"config-event-description"},t.event_booking.description))),e.h("td",null,e.h("div",null,this.getDurationString(t.availability.duration_minutes))),e.h("td",null,e.h("div",{class:"actions"},e.h("button-component",{variant:"basic",id:"copy",key:`copy-${n}`,clickHandler:async a=>{a.preventDefault();const s=e.parsePreviewLink(this.schedulerPreviewLink,t);await navigator.clipboard.writeText(s),this.copiedButtonIndex=n,setTimeout(()=>{this.copiedButtonIndex=-1},3e3)}},this.copiedButtonIndex===n?"Copied!":"Copy link"),e.h("button-component",{variant:"basic",key:`edit-${n}`,clickHandler:a=>{a.preventDefault(),this.editButtonClick.emit({host:this.host,configuration:t})}},"Edit"),e.h("button-component",{variant:"basic",key:`delete-${n}`,clickHandler:a=>{a.preventDefault(),this.deleteButtonClick.emit({host:this.host,configuration:t})}},"Delete"))))))),this.state==="error"&&e.h("div",{class:"error-container"},e.h("p",{class:"error"},this.error)))}get host(){return e.getElement(this)}};yt([Y.RegisterComponent({name:"nylas-list-configurations",stateToProps:new Map([["schedulerConfig.configurations","configurations"]]),localPropsToProp:new Map([["schedulerPreviewLink","schedulerPreviewLink"]]),eventToProps:{initListConfigurations:async(t,n)=>{const a=t.detail;await a.setState("loading");const[s,o]=await n.schedulerConfig.getConfigurations();if(!s&&o&&o.message){await a.setState("error"),await a.setError(o.message);return}await a.setState("loaded")},createButtonClick:async(t,n)=>{n.schedulerConfigStore.resetSelectedConfiguration(),n.schedulerConfigStore.state.action="create"},deleteButtonClick:async(t,n)=>{const{host:a,configuration:s}=t.detail,[o,i]=await n.schedulerConfig.deleteConfiguration(s.id);!o&&i&&i.message&&(await a.setState("error"),await a.setError(i.message))},editButtonClick:async(t,n)=>{const{configuration:a}=t.detail;n.schedulerConfigStore.state.selectedConfiguration=a,n.schedulerConfigStore.state.action="edit"}},fireRegisterEvent:!0}),H("design:type",Function),H("design:paramtypes",[]),H("design:returntype",void 0)],I.prototype,"render",null);I.style=pt;exports.google_logo_icon=tt;exports.microsoft_logo_icon=et;exports.nylas_editor_tabs=E;exports.nylas_list_configurations=I;