@nylas/react 1.1.0-canary.20 → 1.1.0-canary.21

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 (145) hide show
  1. package/dist/add-circle-icon_2.entry-29cc2385.cjs +1 -0
  2. package/dist/add-circle-icon_2.entry-b8d6df60.js +69 -0
  3. package/dist/{archive-icon_7.entry-2f418a3e.js → archive-icon_7.entry-3830776a.js} +18 -18
  4. package/dist/{archive-icon_7.entry-eb90a353.cjs → archive-icon_7.entry-afaef817.cjs} +1 -1
  5. package/dist/{arrow-icon.entry-753eb942.js → arrow-icon.entry-19f00716.js} +1 -1
  6. package/dist/{arrow-icon.entry-ac5e1a47.cjs → arrow-icon.entry-460cdd9f.cjs} +1 -1
  7. package/dist/{bold-icon_3.entry-4fff7400.cjs → bold-icon_3.entry-1893eeec.cjs} +1 -1
  8. package/dist/{bold-icon_3.entry-18507c82.js → bold-icon_3.entry-80abafbb.js} +3 -3
  9. package/dist/button-component.entry-36137536.js +16 -0
  10. package/dist/button-component.entry-b78dc39e.cjs +1 -0
  11. package/dist/calendar-agenda-fill-icon_40.entry-62c66fce.cjs +10 -0
  12. package/dist/{calendar-agenda-fill-icon_35.entry-db989ce0.js → calendar-agenda-fill-icon_40.entry-f19d6ad7.js} +1469 -1076
  13. package/dist/{calendar-cancel-icon.entry-d2e10dfc.cjs → calendar-cancel-icon.entry-0d83ee82.cjs} +1 -1
  14. package/dist/{calendar-cancel-icon.entry-31caeae1.js → calendar-cancel-icon.entry-1fae00c5.js} +1 -1
  15. package/dist/{calendar-check-icon_2.entry-7f67c003.js → calendar-check-icon_2.entry-159c38af.js} +1 -1
  16. package/dist/{calendar-check-icon_2.entry-d32551e9.cjs → calendar-check-icon_2.entry-e01c9028.cjs} +1 -1
  17. package/dist/{calendar-icon.entry-f3f1c623.cjs → calendar-icon.entry-2e701aab.cjs} +1 -1
  18. package/dist/{calendar-icon.entry-6e89816b.js → calendar-icon.entry-3af9cb76.js} +1 -1
  19. package/dist/checkbox-component_2.entry-5eee51f6.js +56 -0
  20. package/dist/checkbox-component_2.entry-9ff2c85b.cjs +1 -0
  21. package/dist/checkmark-icon.entry-0749b942.js +15 -0
  22. package/dist/checkmark-icon.entry-f96f1117.cjs +1 -0
  23. package/dist/{chevron-icon_3.entry-2e20a83e.js → chevron-icon_3.entry-2e9eebbc.js} +10 -10
  24. package/dist/{chevron-icon_3.entry-3be68846.cjs → chevron-icon_3.entry-c3989df2.cjs} +1 -1
  25. package/dist/clock-icon_4.entry-9395d0cb.js +45 -0
  26. package/dist/clock-icon_4.entry-d4563931.cjs +1 -0
  27. package/dist/close-icon.entry-cf9f0a69.js +15 -0
  28. package/dist/close-icon.entry-e24af309.cjs +1 -0
  29. package/dist/{constants-7ce66b44-3952e81c.js → constants-67de2eec-b17f5b96.js} +37 -17
  30. package/dist/{constants-7ce66b44-a6b777d4.cjs → constants-67de2eec-e3b50fc6.cjs} +5 -5
  31. package/dist/{copy-icon_4.entry-187edab9.js → copy-icon_3.entry-7b276fa2.js} +9 -19
  32. package/dist/copy-icon_3.entry-7de3667f.cjs +1 -0
  33. package/dist/document-refresh-icon.entry-582ac233.cjs +1 -0
  34. package/dist/{document-refresh-icon.entry-9d7900d7.js → document-refresh-icon.entry-6dd65cb6.js} +2 -2
  35. package/dist/elements/index.d.ts +8 -0
  36. package/dist/{elements-dc5b338e-edf63aa6.cjs → elements-dc5b338e-158dce67.cjs} +1 -1
  37. package/dist/{elements-dc5b338e-e6271e48.js → elements-dc5b338e-5e8a704b.js} +1 -1
  38. package/dist/{focus-visible-e8093c16-84e41b3b.cjs → focus-visible-e8093c16-5883a317.cjs} +1 -1
  39. package/dist/{focus-visible-e8093c16-4c45967c.js → focus-visible-e8093c16-9d88e8ee.js} +1 -1
  40. package/dist/{forward-icon_6.entry-4cb6eb63.cjs → forward-icon_6.entry-a59dada5.cjs} +3 -3
  41. package/dist/{forward-icon_6.entry-949d0cfb.js → forward-icon_6.entry-acdf04ad.js} +7 -7
  42. package/dist/{globe-icon.entry-04b35395.js → globe-icon.entry-389c0391.js} +2 -2
  43. package/dist/{globe-icon.entry-741f8ad4.cjs → globe-icon.entry-eef27331.cjs} +1 -1
  44. package/dist/google-logo-icon_4.entry-e9be320c.cjs +1 -0
  45. package/dist/google-logo-icon_4.entry-eae19fc8.js +637 -0
  46. package/dist/index-53420959-82a5306f.cjs +1 -0
  47. package/dist/index-53420959-9b1699ec.js +5 -0
  48. package/dist/{index-6d9eeb53-8b16e3b5.cjs → index-6d9eeb53-15c69801.cjs} +1 -1
  49. package/dist/{index-6d9eeb53-b15263de.js → index-6d9eeb53-c70fc8a7.js} +2 -2
  50. package/dist/index-db48e0b6.cjs +42 -0
  51. package/dist/index-f8317a8e.js +7638 -0
  52. package/dist/{index.es-9cc0eb3c-e6c5dd2d.js → index.es-b16d0cf5-386496a9.js} +1 -1
  53. package/dist/{index.es-9cc0eb3c-2e0f7d11.cjs → index.es-b16d0cf5-d7f30c4a.cjs} +1 -1
  54. package/dist/{info-icon_2.entry-c3468951.cjs → info-icon_2.entry-63914227.cjs} +1 -1
  55. package/dist/{info-icon_2.entry-d0270899.js → info-icon_2.entry-97d75550.js} +5 -5
  56. package/dist/input-dropdown.entry-4d29246a.js +132 -0
  57. package/dist/input-dropdown.entry-629d7b54.cjs +1 -0
  58. package/dist/loading-icon.entry-2f15a09f.cjs +1 -0
  59. package/dist/loading-icon.entry-fc9bc740.js +15 -0
  60. package/dist/{mailbox-store-64b4ef7c-c609ac6d.cjs → mailbox-store-f11de360-02a6de93.cjs} +1 -1
  61. package/dist/{mailbox-store-64b4ef7c-7c793d9a.js → mailbox-store-f11de360-d781fd36.js} +2 -2
  62. package/dist/{multi-select-dropdown.entry-f298ca2c.cjs → multi-select-dropdown.entry-68fcca98.cjs} +1 -1
  63. package/dist/{multi-select-dropdown.entry-2ca73c71.js → multi-select-dropdown.entry-8e14e9af.js} +2 -2
  64. package/dist/nylas-booked-event-card_10.entry-4da23b61.cjs +1 -0
  65. package/dist/{nylas-booked-event-card_10.entry-2b01df7e.js → nylas-booked-event-card_10.entry-9487941d.js} +357 -316
  66. package/dist/{nylas-custom-booking-flow.entry-66beff43.js → nylas-custom-booking-flow.entry-0e16973b.js} +32 -32
  67. package/dist/{nylas-custom-booking-flow.entry-05b9522a.cjs → nylas-custom-booking-flow.entry-338b0a8f.cjs} +1 -1
  68. package/dist/nylas-form-card.entry-ca669dea.cjs +1 -0
  69. package/dist/{nylas-form-card.entry-3de9f477.js → nylas-form-card.entry-ccfa5692.js} +10 -10
  70. package/dist/{nylas-if-state.entry-a0689083.js → nylas-if-state.entry-93935670.js} +2 -2
  71. package/dist/{nylas-if-state.entry-a734df46.cjs → nylas-if-state.entry-faa11bb6.cjs} +1 -1
  72. package/dist/{nylas-list-folders.entry-4fb9d4c2.js → nylas-list-folders.entry-14fc1fe8.js} +4 -4
  73. package/dist/{nylas-list-folders.entry-74a56187.cjs → nylas-list-folders.entry-e7e179ea.cjs} +1 -1
  74. package/dist/{nylas-list-threads.entry-9a6d4c33.js → nylas-list-threads.entry-2118b146.js} +3 -3
  75. package/dist/{nylas-list-threads.entry-0addc621.cjs → nylas-list-threads.entry-3f52fc06.cjs} +1 -1
  76. package/dist/{nylas-login.entry-beb6e0d9.js → nylas-login.entry-87a902d6.js} +7 -7
  77. package/dist/{nylas-login.entry-bdac29c0.cjs → nylas-login.entry-915f0284.cjs} +1 -1
  78. package/dist/{nylas-mailbox-pagination.entry-c5d07bbe.cjs → nylas-mailbox-pagination.entry-9aa8a606.cjs} +1 -1
  79. package/dist/{nylas-mailbox-pagination.entry-1d71850a.js → nylas-mailbox-pagination.entry-eedbf796.js} +2 -2
  80. package/dist/{nylas-mailbox-toolbar-button.entry-882c97a0.js → nylas-mailbox-toolbar-button.entry-40b75810.js} +2 -2
  81. package/dist/{nylas-mailbox-toolbar-button.entry-7d9d6293.cjs → nylas-mailbox-toolbar-button.entry-ba5b826e.cjs} +1 -1
  82. package/dist/{nylas-mailbox.entry-d810adba.js → nylas-mailbox.entry-179e5a5c.js} +3 -3
  83. package/dist/{nylas-mailbox.entry-94eb97ec.cjs → nylas-mailbox.entry-31de7f8f.cjs} +1 -1
  84. package/dist/{nylas-provider.entry-5a4bb86e.cjs → nylas-provider.entry-46fe01b6.cjs} +1 -1
  85. package/dist/{nylas-provider.entry-fcaf9e1c.js → nylas-provider.entry-7b70bbdc.js} +36 -36
  86. package/dist/{nylas-scheduler-editor.entry-30597812.cjs → nylas-scheduler-editor.entry-76b68f66.cjs} +2 -2
  87. package/dist/{nylas-scheduler-editor.entry-1ca566d3.js → nylas-scheduler-editor.entry-f1f80de1.js} +7 -10
  88. package/dist/{nylas-scheduling.entry-aefefe3d.js → nylas-scheduling.entry-31d13205.js} +83 -70
  89. package/dist/nylas-scheduling.entry-3ce8c52f.cjs +1 -0
  90. package/dist/{nylas-threads-refresh.entry-a85222e2.js → nylas-threads-refresh.entry-a3ea46aa.js} +2 -2
  91. package/dist/{nylas-threads-refresh.entry-f3b9fdf2.cjs → nylas-threads-refresh.entry-c9f9db8c.cjs} +1 -1
  92. package/dist/{nylas-threads-search.entry-b1bf455b.js → nylas-threads-search.entry-01482ddf.js} +8 -8
  93. package/dist/{nylas-threads-search.entry-2c8ac7dc.cjs → nylas-threads-search.entry-a4ab0d47.cjs} +1 -1
  94. package/dist/{nylas-time-window-picker.entry-3a34b29b.cjs → nylas-time-window-picker.entry-5a3bb0b7.cjs} +1 -1
  95. package/dist/{nylas-time-window-picker.entry-6d664a05.js → nylas-time-window-picker.entry-5f063b2b.js} +18 -18
  96. package/dist/{nylas-view-thread.entry-bf6cab2a.cjs → nylas-view-thread.entry-82e78b82.cjs} +1 -1
  97. package/dist/{nylas-view-thread.entry-ddcb042f.js → nylas-view-thread.entry-cb057b9e.js} +6 -6
  98. package/dist/person-icon.entry-3e30c63c.js +15 -0
  99. package/dist/person-icon.entry-78cdc7f9.cjs +1 -0
  100. package/dist/play-icon_2.entry-4fb1938c.cjs +1 -0
  101. package/dist/play-icon_2.entry-71eaad5c.js +25 -0
  102. package/dist/react.cjs +1 -1
  103. package/dist/react.js +116 -108
  104. package/dist/{refresh-icon.entry-99761cb6.cjs → refresh-icon.entry-3570353d.cjs} +1 -1
  105. package/dist/{refresh-icon.entry-0fdcb7af.js → refresh-icon.entry-db85d14d.js} +4 -4
  106. package/dist/{register-component-a5a9ca5d-ddae10b3.js → register-component-b2a51b20-8a262dcf.js} +1 -1
  107. package/dist/{register-component-a5a9ca5d-4439e573.cjs → register-component-b2a51b20-9a913603.cjs} +1 -1
  108. package/dist/{scheduler-config-store-9ccfba4d-b774bfee.cjs → scheduler-config-store-9ccfba4d-6806e3cb.cjs} +1 -1
  109. package/dist/{scheduler-config-store-9ccfba4d-84025740.js → scheduler-config-store-9ccfba4d-a6745ccc.js} +1 -1
  110. package/dist/{scheduler-store-8a400448-8ab7b63e.js → scheduler-store-db06b30a-1e63b67f.js} +119 -116
  111. package/dist/scheduler-store-db06b30a-d5e6b6c3.cjs +1 -0
  112. package/dist/{textarea-component.entry-359e4665.cjs → textarea-component.entry-be870b8f.cjs} +1 -1
  113. package/dist/{textarea-component.entry-193d29fd.js → textarea-component.entry-f5f402a1.js} +4 -4
  114. package/dist/time-period-selector.entry-d1a8470b.js +93 -0
  115. package/dist/time-period-selector.entry-fc7d61c6.cjs +1 -0
  116. package/dist/{translate-icon.entry-32ec36de.cjs → translate-icon.entry-3ae0ddae.cjs} +1 -1
  117. package/dist/{translate-icon.entry-22a3e72e.js → translate-icon.entry-b91a0449.js} +2 -2
  118. package/dist/{warning-icon.entry-b8d483e1.cjs → warning-icon.entry-54127f45.cjs} +1 -1
  119. package/dist/{warning-icon.entry-8d9b59c0.js → warning-icon.entry-acdc811b.js} +5 -5
  120. package/package.json +3 -3
  121. package/dist/add-circle-icon_2.entry-5cefae99.js +0 -25
  122. package/dist/add-circle-icon_2.entry-85523420.cjs +0 -1
  123. package/dist/button-component_4.entry-3c508e3b.js +0 -115
  124. package/dist/button-component_4.entry-f8ab53dc.cjs +0 -1
  125. package/dist/calendar-agenda-fill-icon_35.entry-b56841a0.cjs +0 -7
  126. package/dist/clock-icon_2.entry-074eb053.cjs +0 -1
  127. package/dist/clock-icon_2.entry-bc938936.js +0 -25
  128. package/dist/copy-icon_4.entry-f704b2f1.cjs +0 -1
  129. package/dist/document-refresh-icon.entry-ea0e1ab9.cjs +0 -1
  130. package/dist/google-logo-icon_4.entry-8e87cf66.cjs +0 -1
  131. package/dist/google-logo-icon_4.entry-f50de25f.js +0 -598
  132. package/dist/index-53420959-507f0a27.js +0 -5
  133. package/dist/index-53420959-e6c2e510.cjs +0 -1
  134. package/dist/index-a4831dfe.cjs +0 -42
  135. package/dist/index-a68236be.js +0 -5011
  136. package/dist/input-dropdown_2.entry-2485dcc3.cjs +0 -1
  137. package/dist/input-dropdown_2.entry-2cd6cfc7.js +0 -220
  138. package/dist/loading-icon.entry-5ed52afe.cjs +0 -1
  139. package/dist/loading-icon.entry-96d9d1be.js +0 -15
  140. package/dist/nylas-booked-event-card_10.entry-97977ac7.cjs +0 -1
  141. package/dist/nylas-form-card.entry-3e1331c9.cjs +0 -1
  142. package/dist/nylas-scheduling.entry-00c418c8.cjs +0 -1
  143. package/dist/play-icon_2.entry-4f316c3d.cjs +0 -1
  144. package/dist/play-icon_2.entry-d55a018a.js +0 -25
  145. package/dist/scheduler-store-8a400448-eaa566fa.cjs +0 -1
@@ -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-a68236be.js";
2
- import { R as wn } from "./register-component-a5a9ca5d-ddae10b3.js";
1
+ import { r as ne, h as g, c as We, d as T, H as $e, g as Rt, i as yn, v as bn, w as En, x as Tn, F as An, y as _n } from "./index-f8317a8e.js";
2
+ import { R as wn } from "./register-component-b2a51b20-8a262dcf.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: "cb5aaea71d642a44a5f53655c7ae98190aaf3745", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "e15b175864ce7c39e04c3885653da3f4d9f35fb1", 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: "ba8b910e873ccb02317d9d8a430d6571cacb45f3", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "390bf0b7bd7ac699af87de2cb8b485f0295fda03", 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: "a8cae87973663ced987b12f8a41385f3311910e5" }, g("sp-theme", { key: "9b732690d1f0c529704c614955c603af602f1805", scale: "medium", color: "dark" }, g("div", { key: "6f9da518afc2027bb938b50dced65383c83281f5", class: "editor", contentEditable: !0, ref: (t) => this.editorEl = t }, g("div", { key: "d665e4adebc7352b5c07137ead22793da96b1a6a", class: "toolbar", ref: (t) => this.toolbarEl = t, contentEditable: !1 }, g("sp-button", { key: "cf4c80151daac614613530c7f3973fa44285b943", quiet: !0, onClick: () => document.execCommand("bold") }, g("div", { key: "406b64ee65391632212f69aab967cce595ef3145", slot: "icon" }, g("bold-icon", { key: "38a82fba1133e28052ae18f59148056213c76e63" })), g("div", { key: "8ab054e1caa8da4d5745a991e0a2ad197124466b", slot: "label" }, "Bold")), g("sp-button", { key: "52d7e1302c0624d4e1e5c337a412a5e0e3752914", quiet: !0, onClick: () => document.execCommand("underline") }, g("div", { key: "c64009e9818a9ccf0385f7cd2c8e3c9df2e08d0d", slot: "icon" }, g("underline-icon", { key: "75de67cc0add37d483d564c1cae6486147ad6669" })), g("div", { key: "d46d90b0959349c237720890afd7b700a6f3cd71", slot: "label" }, "Underline")), g("sp-button", { key: "af87cc784ed3c77e471ba54abbf7e18c3c391e1c", quiet: !0, onClick: () => document.execCommand("italic") }, g("div", { key: "0e1d03379b6f212fe9b0d080577f0633c2ce5c4a", slot: "icon" }, g("italic-icon", { key: "6e127d2755fccaf634d6a261d95dc191bda77bd2" })), g("div", { key: "f2e251b97838ed752af350ed0dae3213a3a14e68", slot: "label" }, "Italic")))), g("div", { key: "70399bf4636e5c061562c478504799b6fdf6e15c", class: "buttons" }, g("sp-button", { key: "90d7d39c6dd284ea399425ea07e205f0562d1423", onClick: this.sendComposer, class: "send" }, "Send"), g("sp-button", { key: "7a1cd27929d585a43b076b8e8131b01f6835aba7", onClick: this.closeComposer, class: "close" }, "Close"))));
109
+ return g($e, { key: "24eb3a7777d0d8d651986e780ccab3ed73f2940e" }, g("sp-theme", { key: "e4f3ab2a32fc79eed17f504e50d9d63db4e58541", scale: "medium", color: "dark" }, g("div", { key: "835738f8e29bae607a2d15e1253721bc2bfbb9f9", class: "editor", contentEditable: !0, ref: (t) => this.editorEl = t }, g("div", { key: "a8eaebb270c1eb0e046cc75ef442d07d7a301ffd", class: "toolbar", ref: (t) => this.toolbarEl = t, contentEditable: !1 }, g("sp-button", { key: "ef149be7a599e823df35a8bb2daf6a6a05e491e6", quiet: !0, onClick: () => document.execCommand("bold") }, g("div", { key: "a016e06e3bd1e1693d602ca143a0db9ebc25f32f", slot: "icon" }, g("bold-icon", { key: "2efa49d13983df8278c71b62765c4663b8f40d49" })), g("div", { key: "50753638d2cebaedfbb1c32e5c7d9fa652ca2182", slot: "label" }, "Bold")), g("sp-button", { key: "9542448b18e7339d90204d6a2133b417e0c6ec76", quiet: !0, onClick: () => document.execCommand("underline") }, g("div", { key: "a89c054aaa20e5a5d75dc0ce0a60ed7d68ee3f52", slot: "icon" }, g("underline-icon", { key: "0251dc3eae7df7229899b17722ecb61f59650be9" })), g("div", { key: "7dbdf879d504975c9f7ac81f5daf6e56618cd0f6", slot: "label" }, "Underline")), g("sp-button", { key: "f1532cb5650c7aef22dbbb8509945ec2c1ee8d30", quiet: !0, onClick: () => document.execCommand("italic") }, g("div", { key: "abe8ada6e4c4cb71cb64313eaa6e580f019f4ad6", slot: "icon" }, g("italic-icon", { key: "38c5bbe4725f72df108b3efbfe819fb84a5b974a" })), g("div", { key: "6ee318ade829600da35b18b917c15a92610d65ce", slot: "label" }, "Italic")))), g("div", { key: "3b7551486b542a077aceaee81b9c59cdaba0f85a", class: "buttons" }, g("sp-button", { key: "350040ee1cf93ad27cfdc467977eeeb3410e6496", onClick: this.sendComposer, class: "send" }, "Send"), g("sp-button", { key: "1324a0e3a401fcee22cfe96dfa43736965ce7256", onClick: this.closeComposer, class: "close" }, "Close"))));
110
110
  }
111
111
  get host() {
112
112
  return Rt(this);
@@ -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: "285c8ae259a5c1de84aa7facdc2165f1f0383e31" }, 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: "43eacf68af3d674b391490436c9b99daabb1eafb" }, 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: "c5eb888da15f3b1cd71273ac5ce16d364dc75c1a", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "2b46aff2e7c0da2f0384485892fe9d3c1998363c", 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: "1828cbf84b5c319ae5f49a26899d07a5887530b0", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "fd9631d0eca90b3ee04beb055b776e1b3643e7d5", 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: "b39732ec7ae51099897b58265e3107537e033038", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "c96f0bfb2877690a272883481c820bc06c8d04ce", 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: "335c0da2d5f172a9775dad2013550ce1ce436bac", fill: "auto", width: this.width, height: this.height, viewBox: "0 0 1920 1920", xmlns: "http://www.w3.org/2000/svg" }, g("path", { key: "44711cc95b1da82767491f45e921a51d8155faf9", 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,4 +1,4 @@
1
- import { r as e, h as C } from "./index-a68236be.js";
1
+ import { r as e, h as C } from "./index-f8317a8e.js";
2
2
  import "react";
3
3
  import "react-dom";
4
4
  const o = ".sc-globe-icon-h{display:flex}", s = o, i = class {
@@ -6,7 +6,7 @@ const o = ".sc-globe-icon-h{display:flex}", s = o, i = class {
6
6
  e(this, t), this.width = "16", this.height = "16";
7
7
  }
8
8
  render() {
9
- return C("svg", { key: "ec642b0d935a6beb65806088a72133496a34a1e4", xmlns: "http://www.w3.org/2000/svg", width: this.width, height: this.height, viewBox: "0 0 16 16", fill: "none" }, C("path", { key: "d2430b66983aaf52ebd0df5a79ac9709c489794b", 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: "bcdb88fa2aa40f8bbf8f59859885380d43ed7789", xmlns: "http://www.w3.org/2000/svg", width: this.width, height: this.height, viewBox: "0 0 16 16", fill: "none" }, C("path", { key: "7735385505203af67841ae105080263c2545919e", 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-a4831dfe.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:"ec642b0d935a6beb65806088a72133496a34a1e4",xmlns:"http://www.w3.org/2000/svg",width:this.width,height:this.height,viewBox:"0 0 16 16",fill:"none"},e.h("path",{key:"d2430b66983aaf52ebd0df5a79ac9709c489794b",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;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-db48e0b6.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:"bcdb88fa2aa40f8bbf8f59859885380d43ed7789",xmlns:"http://www.w3.org/2000/svg",width:this.width,height:this.height,viewBox:"0 0 16 16",fill:"none"},e.h("path",{key:"7735385505203af67841ae105080263c2545919e",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 t=require("./index-db48e0b6.cjs"),ve=require("./register-component-b2a51b20-9a913603.cjs"),_e=require("./constants-67de2eec-e3b50fc6.cjs");require("react");require("react-dom");const Ce=".sc-google-logo-icon-h{display:flex}",xe=Ce,we=class{constructor(e){t.registerInstance(this,e),this.width="24",this.height="24"}render(){return t.h("svg",{key:"3b66b8f8406bb1bb2735eefb8e353f564b148d76",width:this.width,height:this.height,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t.h("g",{key:"e7e6e047f7126a577be5b6e67495e091fe6a4a91","clip-path":"url(#clip0_959_12452)"},t.h("path",{key:"cafb8f5cc31f77a0e964f6809df04080225c0059",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"}),t.h("path",{key:"25d96d59ba32154b37a83bbcfe2114386d462e7f",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"}),t.h("path",{key:"054c72712a95610e75ccefa638bba56cfefb9dc7",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"}),t.h("path",{key:"3450a383589adbdde25a2d7c3f528385746d7116",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"})),t.h("defs",{key:"1c29157546a3b7c420398f2b4fa65a17b02e5010"},t.h("clipPath",{key:"9e1804395e96faa50fb95a9600cee29c415216a2",id:"clip0_959_12452"},t.h("rect",{key:"98fd7d191b71077f96e8b1f2bfe4c3446b01f2fa",width:24,height:24,fill:"white"}))))}};we.style=xe;const Se=".sc-microsoft-logo-icon-h{display:flex}",Te=Se,ke=class{constructor(e){t.registerInstance(this,e),this.width="22",this.height="22"}render(){return t.h("svg",{key:"b136cb884eb1d99d5673ad39651d6370de1acd32",width:this.width,height:this.height,viewBox:"0 0 22 22",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t.h("path",{key:"475d51fa261724499d3abb9be21e4aa256b35d7b",d:"M0.043457 0.043457H10.4782V10.4782H0.043457V0.043457Z",fill:"#F35325"}),t.h("path",{key:"551e2efd56295a498f300a384d8ffc7fd3766188",d:"M11.5217 0.043457H21.9565V10.4782H11.5217V0.043457Z",fill:"#81BC06"}),t.h("path",{key:"d3f07689492b30b3494f5097db79545b5b35d69d",d:"M0.043457 11.5217H10.4782V21.9565H0.043457V11.5217Z",fill:"#05A6F0"}),t.h("path",{key:"ba3c56ed418db7603b969795e0f31e32a066fbb4",d:"M11.5217 11.5217H21.9565V21.9565H11.5217V11.5217Z",fill:"#FFBA08"}))}};ke.style=Te;function Le({id:e,formState:i,activeTab:a,calendars:s,currentUser:r}){var n,d,o;switch(a){case"eventInfo":const u=i.title,p=i.description,g=parseInt(i.duration),k=i.location,C=i.conferencing;return t.h("div",{key:e},t.h("nylas-event-info",null,t.h("div",{slot:"inputs"},t.h("nylas-event-title",{name:"title",eventTitle:u,exportparts:"net, net__title, net__dropdown-content"}),t.h("nylas-event-duration",{name:"duration",eventDurationMinutes:g,exportparts:"ned, ned__dropdown, ned__dropdown-button, ned__dropdown-content, ned__input_dropdown, ned__input_dropdown-input, ned__input_dropdown-content"}),t.h("nylas-event-location",{name:"location",eventLocation:k,eventConferencing:C,userProvider:r.provider,exportparts:"nel, nel__location, nel__dropdown, nel__dropdown-button, nel__dropdown-content"}),t.h("nylas-event-description",{name:"description",eventDescription:p,exportparts:"nedesc, nedesc__textarea"}))));case"availability":const x=i.availability.openHours,S=i.availability.timezone?i.availability.timezone:Intl.DateTimeFormat().resolvedOptions().timeZone;return t.h("div",{key:e},t.h("nylas-participant-booking-calendars",{name:"participant-booking-calendars",participants:i.participants,calendars:s}),t.h("nylas-connected-calendars",{name:"connected-calendars",participants:i.participants}),t.h("nylas-availability-picker",{name:"availability",openHours:x,defaultTimezone:S,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 t.h("div",{key:e},t.h("nylas-buffer-time",{name:"buffer-time",buffer:i.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"}),t.h("nylas-event-limits",null,t.h("div",{slot:"inputs"},t.h("nylas-min-booking-notice",{name:"min-booking-notice",minBookingNotice:i.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"}),t.h("nylas-limit-future-bookings",{name:"limit-future-bookings",availableDaysInFuture:i.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"}),t.h("nylas-min-cancellation-notice",{name:"min-cancellation-notice",minCancellationNotice:i.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"}),t.h("nylas-cancellation-policy",{name:"cancellation-policy",cancellationPolicy:i.cancellationPolicy,exportparts:"ncpolicy, ncpolicy__textarea"}))),t.h("nylas-timeslot-interval",{name:"timeslot-interval",eventDurationMinutes:parseInt(i.duration),exportparts:"nti, nti__header, nti__input-label, nti__dropdown, nti__dropdown-button, nti__dropdown-content"}),t.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"communications":return t.h("div",{key:e},t.h("div",{class:"tab-header"},t.h("h3",null,"Event communications"),t.h("p",null,"Set up automatic communications for your events.")),t.h("nylas-confirmation-email",{name:"confirmation-email-template",confirmationEmailTemplate:i.emailTemplate,isOpen:!((d=(n=i.reminders)==null?void 0:n.overrides)!=null&&d.length),participants:i.participants,exportparts:"nce, nce__tab-heading, nce__header, nce__body, nce__confirmation-email-toggle--container, nce__summary, nce__reminder-input_dropdown, nce__reminder-input_dropdown-input, nce__reminder-input_dropdown-content"}),t.h("nylas-reminder-emails",{name:"reminder-emails",eventReminders:((o=i.reminders)==null?void 0:o.overrides)??[],participants:i.participants,exportparts:"nre, nre__tab-heading, nre__header, nre__body, nre__confirmation-email-toggle--container, nre__summary, nre__reminder-input_dropdown, nre__reminder-input_dropdown-input, nre__reminder-input_dropdown-content"}));case"participants":return t.h("div",{key:e},t.h("nylas-additional-participants",{name:"participants",eventParticipants:i.participants,exportparts:"nap__title, nap__subtitle, nap__content, nap__input_group, nap__input_wrapper, nap__input, nap__remove-participant"}),t.h("nylas-participants-custom-availability",{name:"participant-custom-availability",participants:i.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"}));case"bookingForm":const T=Object.entries(i.additionalFields).map(([m,L])=>({key:m,...L}));return t.h("div",{key:e},t.h("nylas-booking-form-config",{name:"additional-fields",additonalFields:T}))}}const Fe='.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 .tabs.sc-nylas-editor-tabs .tab.hide.sc-nylas-editor-tabs{display:none}.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}.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs .tab-content.sc-nylas-editor-tabs .tab-header.sc-nylas-editor-tabs{display:flex;flex-direction:column;margin:1rem 1rem 0.5rem;row-gap:4px}.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs .tab-content.sc-nylas-editor-tabs .tab-header.sc-nylas-editor-tabs h3.sc-nylas-editor-tabs{margin:0;font-size:1rem;font-weight:600;line-height:20px;color:var(--nylas-base-900);text-align:left}.scheduler-editor.sc-nylas-editor-tabs .form-contents.sc-nylas-editor-tabs .tab-content.sc-nylas-editor-tabs .tab-header.sc-nylas-editor-tabs p.sc-nylas-editor-tabs{margin:0;font-size:0.875rem;font-weight:400;line-height:20px;color:var(--nylas-base-600);text-align:left}.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}',Ee=Fe;var He=function(e,i,a,s){var r=arguments.length,n=r<3?i:s===null?s=Object.getOwnPropertyDescriptor(i,a):s,d;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")n=Reflect.decorate(e,i,a,s);else for(var o=e.length-1;o>=0;o--)(d=e[o])&&(n=(r<3?d(n):r>3?d(i,a,n):d(i,a))||n);return r>3&&n&&Object.defineProperty(i,a,n),n},U=function(e,i){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(e,i)};const $=class{constructor(e){t.registerInstance(this,e),this.schedulerConfigChanged=t.createEvent(this,"schedulerConfigChanged",7),this.cancelButtonClick=t.createEvent(this,"cancelButtonClick",7),this.formSubmitted=t.createEvent(this,"formSubmitted",7),this.previewButtonClicked=t.createEvent(this,"previewButtonClicked",7),this.schedulerEditorFormUpdated=t.createEvent(this,"schedulerEditorFormUpdated",7),this.setError=i=>{this.error=i.message},this.formSubmissionHandler=async i=>{var B,Z,J,q,G,W,K,Q,X,Y,ee,te,ie,ae,ne,se;if(i.preventDefault(),this.formSubmitted.emit(),!this.formRef.checkValidity()){this.error=this.formRef.validationMessage||"Please fix the form errors.";return}this.isLoading=!0,this.hasUnsavedChanges=!1;const s=this.updateFormState(),{title:r,description:n,duration:d,availability:o,bookingCalendar:u,location:p,bookingType:g,buffer:k,availableDaysInFuture:C,minCancellationNotice:x,minBookingNotice:S,cancellationPolicy:T,timeslotInterval:m,additionalGuestsHidden:L,hideCancellationOptions:O,hideReschedulingOptions:N,participants:_,participantOpenHours:h,additionalFields:I,participantCalendars:v,conferencing:R,participantBookingCalendars:y,reminders:M,emailTemplate:z}=s,c=(Z=(B=this.selectedConfiguration)==null?void 0:B.participants)==null?void 0:Z.find(l=>l.is_organizer),w=v&&(c!=null&&c.email)?v[c==null?void 0:c.email]:[],H=((J=c==null?void 0:c.booking)==null?void 0:J.calendar_id)||u,P=d?parseInt(d):30,F=_&&(_==null?void 0:_.length)>0?_:[{name:(c==null?void 0:c.name)??((q=this.currentUser)==null?void 0:q.name)??"",email:(c==null?void 0:c.email)??((G=this.currentUser)==null?void 0:G.email)??"",is_organizer:!0,timezone:(o==null?void 0:o.timezone)??Intl.DateTimeFormat().resolvedOptions().timeZone,availability:{calendar_ids:w.length?w:["primary"],open_hours:[]},booking:{calendar_id:u&&u!==""?u:"primary"}}],D={...((W=this.selectedConfiguration)==null?void 0:W.id)&&{id:this.selectedConfiguration.id},version:((K=this.selectedConfiguration)==null?void 0:K.version)??"1.0.0",availability:{duration_minutes:P,interval_minutes:(m==null?void 0:m.interval)??P,round_to:m==null?void 0:m.roundTo,availability_rules:{availability_method:((Y=(X=(Q=this.selectedConfiguration)==null?void 0:Q.availability)==null?void 0:X.availability_rules)==null?void 0:Y.availability_method)??"collective",buffer:k||{before:0,after:0},default_open_hours:(o==null?void 0:o.openHours)??((ie=(te=(ee=this.selectedConfiguration)==null?void 0:ee.availability)==null?void 0:te.availability_rules)==null?void 0:ie.default_open_hours)??_e.DEFAULT_OPEN_HOURS,round_robin_group_id:((se=(ne=(ae=this.selectedConfiguration)==null?void 0:ae.availability)==null?void 0:ne.availability_rules)==null?void 0:se.round_robin_group_id)??""}},participants:[...F==null?void 0:F.map(l=>{var oe,re,le,de,ce,he,be,ue,pe,me,fe,ye,ge;return l.is_organizer?{name:l.name??"",email:l.email,is_organizer:!0,timezone:((re=(oe=h==null?void 0:h[l.email])==null?void 0:oe[0])==null?void 0:re.timezone)??((ce=(de=(le=l.availability)==null?void 0:le.open_hours)==null?void 0:de[0])==null?void 0:ce.timezone)??Intl.DateTimeFormat().resolvedOptions().timeZone,availability:{calendar_ids:w.length?w:["primary"],open_hours:(h==null?void 0:h[l.email])??((he=l.availability)==null?void 0:he.open_hours)??[]},booking:{calendar_id:H||"primary"}}:{...l,timezone:((ue=(be=h==null?void 0:h[l.email])==null?void 0:be[0])==null?void 0:ue.timezone)??((fe=(me=(pe=l.availability)==null?void 0:pe.open_hours)==null?void 0:me[0])==null?void 0:fe.timezone)??Intl.DateTimeFormat().resolvedOptions().timeZone,availability:l.availability?{calendar_ids:(v==null?void 0:v[l.email])??((ye=l.availability)==null?void 0:ye.calendar_ids)??["primary"],open_hours:(h==null?void 0:h[l.email])??((ge=l.availability)==null?void 0:ge.open_hours)??[]}:void 0,booking:y!=null&&y[l.email]?{calendar_id:y==null?void 0:y[l.email]}:(l==null?void 0:l.booking)??void 0}})],event_booking:{title:(r==null?void 0:r.toString())??"",description:(n==null?void 0:n.toString())??"",location:(p==null?void 0:p.toString())??"",booking_type:(g==null?void 0:g.toString())??"booking",timezone:(o==null?void 0:o.timezone)??Intl.DateTimeFormat().resolvedOptions().timeZone,conferencing:R,reminders:M},scheduler:{cancellation_policy:T??"",available_days_in_future:C??30,min_cancellation_notice:x??0,min_booking_notice:S??60,hide_additional_guests:L??!1,hide_cancellation_options:O??!1,hide_rescheduling_options:N??!1,additional_fields:I,email_template:z}},j=t.mergeDeep(D,this.selectedConfiguration),b=this.action==="create"?j:D;this.isConfigRoundRobin(b)&&(b.participants=b.participants.map(l=>({...l,is_organizer:void 0})));const f=l=>{this.isLoading=!1,this.changesSaved=!0,setTimeout(()=>{this.changesSaved=!1},5e3)};this.checkForClientSideErrors(b)||this.schedulerConfigChanged.emit({config:b,resetLoadingState:f,setError:this.setError,action:this.action})},this.isConfigRoundRobin=i=>{var a,s,r,n;return((s=(a=i.availability)==null?void 0:a.availability_rules)==null?void 0:s.availability_method)==="max-availability"||((n=(r=i.availability)==null?void 0:r.availability_rules)==null?void 0:n.availability_method)==="max-fairness"},this.checkForClientSideErrors=i=>{var n;let a=!1,s="";const r=(n=i.scheduler)==null?void 0:n.additional_fields;return r&&(s="Booking form error: ",Object.entries(r).forEach(d=>{const o=d[1];if(o.label===""){s+=`Label is required for field of type ${o.type}.`,a=!0;return}if(o.options){for(const u of o.options)if(u===""){s+=`Empty option detected inside ${o.label} of type ${o.type}.`,a=!0;break}}})),a&&(this.isLoading=!1,this.setError(new Error(s))),a},this.calendars=void 0,this.selectedConfiguration=void 0,this.currentUser=void 0,this.schedulerPreviewLink="",this.mode="app",this.hideEditorTabs=[],this.action="create",this.activeTab="eventInfo",this.isLoading=!1,this.hasUnsavedChanges=!1,this.changesSaved=!1,this.formState={},this.error=""}configChangedHandler(e){t.debug("[nylas-editor-tabs]","configChangedHandler",e,this.selectedConfiguration),this.formState={...this.getFormStateFromConfig(e)},e.id?this.action="edit":this.action="create"}userChangedHandler(e){t.debug("[nylas-editor-tabs]","userChangedHandler",e),e&&(this.formState={...this.getFormStateFromConfig(this.selectedConfiguration)})}connectedCallback(){t.debug("[nylas-editor-tabs]","connectedCallback")}componentWillLoad(){t.debug("[nylas-editor-tabs]","componentWillLoad"),this.formState=this.getFormStateFromConfig(this.selectedConfiguration)}componentDidLoad(){var i;t.debug("[nylas-editor-tabs]","componentDidLoad");const e=(i=this.host.querySelector("button.tab:not(.hide)"))==null?void 0:i.name;e&&(this.activeTab=e)}disconnectedCallback(){t.debug("[nylas-editor-tabs]","disconnectedCallback")}handleValueChanged(e){t.debug("[nylas-editor-tabs]","handleValueChanged",e);const{name:i,value:a}=e.detail;this.setFormState(a,i),this.formState={...this.formState},this.hasUnsavedChanges=!0,this.error="",this.schedulerEditorFormUpdated.emit({value:e.detail.value,name:e.detail.name})}getFormStateFromConfig(e){var a,s,r,n,d,o,u,p,g,k,C,x,S,T,m,L,O,N,_,h,I,v,R,y,M,z,c,w,H,P,F,D,j;let i=(a=e==null?void 0:e.participants)==null?void 0:a.find(b=>b.is_organizer);return!i&&((r=(s=e==null?void 0:e.availability)==null?void 0:s.availability_rules)==null?void 0:r.availability_method)!=="collective"&&(i=(n=e==null?void 0:e.participants)==null?void 0:n.find(b=>{var f;return b.email===((f=this.currentUser)==null?void 0:f.email)}),i&&(i.is_organizer=!0)),{title:((d=e==null?void 0:e.event_booking)==null?void 0:d.title)??"",description:((o=e==null?void 0:e.event_booking)==null?void 0:o.description)??"",duration:((p=(u=e==null?void 0:e.availability)==null?void 0:u.duration_minutes)==null?void 0:p.toString())??"30",availability:{timezone:((g=e==null?void 0:e.event_booking)==null?void 0:g.timezone)??Intl.DateTimeFormat().resolvedOptions().timeZone,openHours:((C=(k=e==null?void 0:e.availability)==null?void 0:k.availability_rules)==null?void 0:C.default_open_hours)??_e.DEFAULT_OPEN_HOURS},additionalFields:((x=e==null?void 0:e.scheduler)==null?void 0:x.additional_fields)??{},conferencing:((S=e==null?void 0:e.event_booking)==null?void 0:S.conferencing)??{},calendarIds:((T=i==null?void 0:i.availability)==null?void 0:T.calendar_ids)??[],participants:(e==null?void 0:e.participants)??[],bookingCalendar:((m=i==null?void 0:i.booking)==null?void 0:m.calendar_id)??(i==null?void 0:i.email)??"",location:((L=e==null?void 0:e.event_booking)==null?void 0:L.location)??"",bookingType:((O=e==null?void 0:e.event_booking)==null?void 0:O.booking_type)??"booking",buffer:((_=(N=e==null?void 0:e.availability)==null?void 0:N.availability_rules)==null?void 0:_.buffer)??{before:0,after:0},cancellationPolicy:((h=e==null?void 0:e.scheduler)==null?void 0:h.cancellation_policy)??"",availableDaysInFuture:((I=e==null?void 0:e.scheduler)==null?void 0:I.available_days_in_future)??30,minCancellationNotice:((v=e==null?void 0:e.scheduler)==null?void 0:v.min_cancellation_notice)??0,minBookingNotice:((R=e==null?void 0:e.scheduler)==null?void 0:R.min_booking_notice)??60,timeslotInterval:{interval:((y=e==null?void 0:e.availability)==null?void 0:y.interval_minutes)??((M=e==null?void 0:e.availability)==null?void 0:M.duration_minutes),roundTo:(z=e==null?void 0:e.availability)==null?void 0:z.round_to},additionalGuestsHidden:((c=e==null?void 0:e.scheduler)==null?void 0:c.hide_additional_guests)??!1,hideCancellationOptions:((w=e==null?void 0:e.scheduler)==null?void 0:w.hide_cancellation_options)??!1,hideReschedulingOptions:((H=e==null?void 0:e.scheduler)==null?void 0:H.hide_rescheduling_options)??!1,participantBookingCalendars:((P=e==null?void 0:e.participants)==null?void 0:P.reduce((b,f)=>{var E,B;return(E=f.booking)!=null&&E.calendar_id&&(b[f.email]=(B=f.booking)==null?void 0:B.calendar_id),b}))??{},participantCalendars:((F=e==null?void 0:e.participants)==null?void 0:F.reduce((b,f)=>{var E;return b[f.email]=(E=f.availability)==null?void 0:E.calendar_ids,b},{}))??{},reminders:(D=e==null?void 0:e.event_booking)==null?void 0:D.reminders,emailTemplate:(j=e==null?void 0:e.scheduler)==null?void 0:j.email_template}}setFormState(e,i){switch(i){case"title":this.formState.title=e.toString();break;case"description":this.formState.description=e.toString();break;case"duration":this.formState.duration=e.toString();break;case"availability":this.formState.availability=JSON.parse(e.toString());break;case"participants":this.formState.participants=JSON.parse(e.toString());break;case"booking-calendar":this.formState.bookingCalendar=e.toString();break;case"participant-booking-calendars":this.formState.participantBookingCalendars=JSON.parse(e.toString());break;case"location":this.formState.location=e.toString();break;case"conference":this.formState.conferencing=JSON.parse(e.toString());break;case"booking-type":this.formState.bookingType=e.toString();break;case"buffer-time":this.formState.buffer=JSON.parse(e.toString());break;case"limit-future-bookings":this.formState.availableDaysInFuture=parseInt(e.toString());break;case"min-cancellation-notice":this.formState.minCancellationNotice=parseInt(e.toString());break;case"min-booking-notice":this.formState.minBookingNotice=parseInt(e.toString());break;case"cancellation-policy":this.formState.cancellationPolicy=e.toString();break;case"timeslot-interval":this.formState.timeslotInterval=JSON.parse(e.toString());break;case"customize-booking-settings":const a=JSON.parse(e.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(e.toString());this.formState.participantOpenHours=s;break;case"additional-fields":this.formState.additionalFields=e;break;case"connected-calendars":this.formState.participantCalendars=JSON.parse(e.toString());break;case"confirmation-email-template":this.formState.emailTemplate=JSON.parse(e.toString());break;case"reminder-overrides":this.formState.reminders={overrides:JSON.parse(e.toString())};break}this.schedulerEditorFormUpdated.emit({value:e,name:i})}updateFormState(){return new FormData(this.formRef).forEach((i,a)=>{this.setFormState(i,a)}),this.formState={...this.formState},this.formState}setActiveTab(e,i){e.preventDefault(),this.updateFormState(),this.activeTab=i}hideTab(e){var i;return((i=this.hideEditorTabs)==null?void 0:i.includes(e))||!1}render(){var i;t.debug("[nylas-editor-tabs]","render",this.formState);const e=localStorage.getItem("nylas")==="Nylas Developer";return t.h(t.Host,{key:"5e190ea179c30e38c254ad7ec34e3ffa53da6d2f"},t.h("form",{key:"2048843017f86406f676d158f97c42283f44ea9a",onSubmit:this.formSubmissionHandler,class:"scheduler-editor",ref:a=>this.formRef=a,noValidate:!0},this.mode==="app"?t.h("div",{class:"form-contents"},t.h("div",{class:"tabs"},t.h("button",{name:"eventInfo",class:{tab:!0,active:this.activeTab=="eventInfo",hide:this.hideTab("eventInfo")},part:"editortab__event-info",onClick:a=>this.setActiveTab(a,"eventInfo")},t.h("calendar-info-icon",{width:"16",height:"16"}),"Event info"),t.h("button",{name:"availability",class:{tab:!0,active:this.activeTab=="availability",hide:this.hideTab("availability")},part:"editortab__availability",onClick:a=>this.setActiveTab(a,"availability")},t.h("calendar-patterns-icon",{width:"16",height:"16"}),"Availability"),t.h("button",{name:"participants",class:{tab:!0,active:this.activeTab=="participants",hide:this.hideTab("participants")},part:"editortab__participants",onClick:a=>this.setActiveTab(a,"participants")},t.h("people-icon",{width:"16",height:"16"}),"Participants"),t.h("button",{name:"bookingOptions",class:{tab:!0,active:this.activeTab=="bookingOptions",hide:this.hideTab("bookingOptions")},part:"editortab__booking-options",onClick:a=>this.setActiveTab(a,"bookingOptions")},t.h("flow-icon",{width:"16",height:"16"}),"Booking options"),t.h("button",{name:"bookingForm",class:{tab:!0,active:this.activeTab=="bookingForm",hide:this.hideTab("bookingForm")},part:"editortab__booking-form",onClick:a=>this.setActiveTab(a,"bookingForm")},this.activeTab=="bookingForm"?t.h("calendar-agenda-fill-icon",{width:"16",height:"16"}):t.h("calendar-agenda-icon",{width:"16",height:"16"}),"Booking form"),e&&t.h("button",{name:"communications",class:{tab:!0,active:this.activeTab=="communications"},onClick:a=>this.setActiveTab(a,"communications")},this.activeTab=="communications"?t.h("envelope-fill-icon",{width:"16",height:"16"}):t.h("envelope-icon",{width:"16",height:"16"}),"Communications")),t.h("div",{class:"tab-content"},t.h(Le,{formState:this.formState,activeTab:this.activeTab,currentUser:this.currentUser,calendars:this.calendars,id:((i=this.selectedConfiguration)==null?void 0:i.id)??"new"}))):t.h("slot",null),t.h("div",{key:"88a16f2bccf874acaec34b0ad37d42313758cbb9",class:"footer",part:"editor__footer"},t.h("div",{key:"17387917bc660e6e691e5d75501d4a13da2632fc",class:"preview",part:"editor__footer-preview"},this.schedulerPreviewLink!==""&&this.action==="edit"&&t.h("button-component",{type:"button",disabled:this.isLoading,clickHandler:a=>{a.preventDefault(),this.previewButtonClicked.emit(this.host).defaultPrevented||window.open(t.parsePreviewLink(this.schedulerPreviewLink,this.selectedConfiguration),"_blank")},variant:"basic"},"Preview")),t.h("div",{key:"a4e8d02452c2ab524dc0fb010ad88f05cd46d244",class:"buttons",part:"editor__footer-buttons"},t.h("p",{key:"2a04af9dc978964725eeb787b1a3f31d76e26720",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!":""),t.h("button-component",{key:"5997accc74ff1f73b2577923a02f50af0f613429",type:"button",disabled:this.isLoading,clickHandler:a=>{a.preventDefault(),this.cancelButtonClick.emit(),this.error=""},variant:"basic",part:"editor__footer-cancel"},"Back"),t.h("button-component",{key:"9aee416653e7648a62a4d95af171b49b9fd35cba",type:"submit",disabled:this.isLoading,part:"editor__footer-cta"},this.isLoading?t.h("span",null,"Saving",t.h("loading-icon",null)," "):this.action=="create"?"Create":"Save changes")))))}get host(){return t.getElement(this)}static get watchers(){return{selectedConfiguration:["configChangedHandler"],currentUser:["userChangedHandler"]}}};He([ve.RegisterComponent({name:"nylas-editor-tabs",stateToProps:new Map([["schedulerConfig.calendars","calendars"],["schedulerConfig.selectedConfiguration","selectedConfiguration"],["schedulerConfig.currentUser","currentUser"],["schedulerConfig.hideEditorTabs","hideEditorTabs"]]),eventToProps:{schedulerConfigChanged:async(e,i)=>{const{resetLoadingState:a,setError:s,action:r,config:n}=e.detail,d=o=>{const[u,p]=o;!u&&p&&s&&s(p),a&&a(e)};if(r==="edit"){const o=await i.schedulerConfig.updateConfiguration(n);d(o)}else{const o=await i.schedulerConfig.createConfiguration(n);d(o)}},cancelButtonClick:async(e,i)=>{i.schedulerConfigStore.state.action=null},previewButtonClicked:async(e,i)=>{t.debug("[nylas-editor-tabs]","previewButtonClicked",i)},formSubmitted:async(e,i)=>{t.debug("[nylas-editor-tabs]","formSubmitted",i)},schedulerEditorFormUpdated:async(e,i)=>{t.debug("[nylas-editor-tabs]","schedulerEditorFormUpdated",e)}},localPropsToProp:new Map([["schedulerPreviewLink","schedulerPreviewLink"]]),fireRegisterEvent:!0}),U("design:type",Function),U("design:paramtypes",[]),U("design:returntype",void 0)],$.prototype,"render",null);$.style=Ee;const Pe=':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;flex-direction:column;position:relative;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.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{width:100%;max-width:300px}@media screen and (max-width: 768px){.configurations table .title{max-width:96px}}.configurations table .title div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.configurations table .title div.config-event-title{font-weight:600}.configurations table .title div.config-event-description{font-size:0.75rem}.configurations .pagination{padding:1rem;position:sticky;top:100%;display:flex;justify-content:flex-end;gap:0.5rem;background:white;width:calc(100% - 2rem);z-index:2}.configurations .pagination td.arrows{display:flex;justify-content:flex-end;gap:0.5rem}.configurations .pagination button{display:flex;flex-direction:row;justify-content:center;align-items:center;height:3vh;width:3vh;min-width:3em;min-height:3em;cursor:pointer;border-radius:var(--nylas-border-radius-2x);border:1px solid var(--nylas-base-300);background-color:transparent;color:var(--nylas-base-800);cursor:pointer}.configurations .pagination button:hover:not(:disabled){border:1px solid var(--nylas-primary)}.configurations .pagination button:active{border:1px solid var(--nylas-base-800)}.configurations .pagination button:disabled{border:1px solid var(--nylas-base-100);background-color:transparent;color:var(--nylas-base-300);cursor:not-allowed}.configurations .pagination button.right{transform:rotate(180deg)}.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}select-dropdown{width:auto}select-dropdown::part(sd_dropdown-button){display:block;height:48px;padding:0px 16px 8px}@media screen and (max-width: 768px){select-dropdown::part(sd_dropdown-button){width:92px}}select-dropdown::part(sd_dropdown-content){width:120px;right:0}select-dropdown::part(sd_dropdown-labelhtml){display:flex;gap:0.5rem;align-items:center;color:var(--nylas-base-900)}select-dropdown::part(sd_dropdown-labelhtml):hover{color:var(--nylas-primary)}',De=Pe;var Be=function(e,i,a,s){var r=arguments.length,n=r<3?i:s===null?s=Object.getOwnPropertyDescriptor(i,a):s,d;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")n=Reflect.decorate(e,i,a,s);else for(var o=e.length-1;o>=0;o--)(d=e[o])&&(n=(r<3?d(n):r>3?d(i,a,n):d(i,a))||n);return r>3&&n&&Object.defineProperty(i,a,n),n},A=function(e,i){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(e,i)};const V=class{constructor(e){t.registerInstance(this,e),this.initListConfigurations=t.createEvent(this,"initListConfigurations",7),this.createButtonClick=t.createEvent(this,"createButtonClick",7),this.editButtonClick=t.createEvent(this,"editButtonClick",7),this.deleteButtonClick=t.createEvent(this,"deleteButtonClick",7),this.configurations=[],this.schedulerPreviewLink="",this.listConfigurationsNextCursor=void 0,this.state="loading",this.error="",this.currentCursor=null,this.previousCursors=[],this.disableNextPageButton=!1}listConfigurationsNextCursorChangedHandler(e,i){if(!e||e===i){e===null&&(this.disableNextPageButton=!0);return}this.disableNextPageButton=!1,this.currentCursor=e}connectedCallback(){t.debug("[nylas-list-configurations]","connectedCallback")}componentWillLoad(){t.debug("[nylas-list-configurations]","componentWillLoad"),this.configurations&&this.configurations.length>0&&(this.state="loaded")}componentDidLoad(){t.debug("[nylas-list-configurations]","componentDidLoad"),this.initListConfigurations.emit({host:this.host})}disconnectedCallback(){t.debug("[nylas-list-configurations]","disconnectedCallback")}async handleNylasFormDropdownChanged(e){t.debug("[nylas-list-configurations]","handleNylasFormDropdownChanged",e.detail);const{value:i}=e.detail,[a,s]=i.split("-");switch(e.preventDefault(),a){case"delete":this.deleteButtonClick.emit({host:this.host,configuration:this.configurations[s]});break;case"preview":window.open(t.parsePreviewLink(this.schedulerPreviewLink,this.configurations[s]),"_blank");break;case"copy":await navigator.clipboard.writeText(t.parsePreviewLink(this.schedulerPreviewLink,this.configurations[s]));break}}async getState(){return this.state}async setState(e){this.state=e}async setError(e){this.error=e}getDurationString(e){const i=Math.floor(e/60),a=e%60;return`${i||""} ${i?`${i>1?"hours":"hour"}`:""} ${a||""} ${a?`${a>1?"mins":"min"}`:""}`}getActionLabelHTML(e){const i={display:"inline-flex",alignItems:"center",gap:"0.5rem"},a={color:"var(--nylas-error)"};switch(e){case"preview":return t.h("span",{style:i},t.h("eye-icon",{width:"16",height:"16"}),"Preview");case"copy":return t.h("span",{style:i},t.h("copy-icon",{width:"16",height:"16"}),"Copy");case"delete":return t.h("span",{style:{...i,...a}},t.h("delete-icon",{width:"15",height:"17"}),"Delete");default:return""}}previousPageClickedHandler(){if(this.previousCursors.length===0)return;this.currentCursor=this.previousCursors.pop()||null;const e=this.previousCursors[this.previousCursors.length-1]||void 0;this.initListConfigurations.emit({host:this.host,cursor:e})}nextPageClickedHandler(){this.currentCursor&&(this.previousCursors=[...this.previousCursors,this.currentCursor],this.initListConfigurations.emit({host:this.host,cursor:this.currentCursor}))}render(){return t.h(t.Host,null,t.h("div",{class:"header"},t.h("div",{class:"description"},t.h("h2",null,"All scheduling pages"),t.h("p",null,"Create, edit and manage all your scheduling pages.")),this.configurations&&this.configurations.length>0&&t.h("div",{class:"actions"},t.h("button-component",{clickHandler:()=>{this.createButtonClick.emit(this.host)}},"Create new"))),t.h("div",{class:"configurations"},t.h("table",{class:{"no-configurations":this.state!=="loading"&&(!this.configurations||this.configurations.length===0)}},t.h("tr",{class:{hide:this.state==="loading"||this.configurations&&this.configurations.length===0}},t.h("th",null,"Scheduling page title"),t.h("th",null,"Duration"),t.h("th",{class:"actions-header"},"Actions")),this.state==="loading"&&t.h("tr",{class:"no-configurations"},t.h("td",{colSpan:3},t.h("div",null,t.h("h3",null,"Loading..."),t.h("p",null,"Please wait while we fetch the scheduling pages")))),this.state!=="loading"&&(!this.configurations||this.configurations.length===0)&&t.h("tr",{class:"no-configurations"},t.h("td",{colSpan:3},t.h("div",null,t.h("calendar-icon",{width:"48",height:"48"}),t.h("h3",null,"No scheduling pages found"),t.h("p",null,"Get started with creating your first scheduling page"),t.h("button-component",{clickHandler:()=>{this.createButtonClick.emit(this.host)}},"Create new")))),this.state!=="loading"&&this.configurations.map((e,i)=>t.h("tr",{key:e.id},t.h("td",null,t.h("div",{class:"title"},t.h("div",{class:"config-event-title",title:e.event_booking.title},e.event_booking.title),t.h("div",{class:"config-event-description"},e.event_booking.description))),t.h("td",null,t.h("div",{class:"duration"},this.getDurationString(e.availability.duration_minutes))),t.h("td",null,t.h("div",{class:"actions"},t.h("button-component",{variant:"basic",key:`edit-${i}`,clickHandler:a=>{a.preventDefault(),this.editButtonClick.emit({host:this.host,configuration:e})}},t.h("edit-icon",{width:"16",height:"16"}),"Edit"),t.h("select-dropdown",{name:"actions",options:[{value:`preview-${i}`,label:"Preview",labelHTML:this.getActionLabelHTML("preview")},{value:`copy-${i}`,label:"Copy link",labelHTML:this.getActionLabelHTML("copy")},{value:`delete-${i}`,label:"Delete",labelHTML:this.getActionLabelHTML("delete")}],defaultSelectedOption:{value:"",label:""},dropdownButtonText:"...",withSearch:!1,withChevron:!1,exportparts:"sd_dropdown: actions__dropdown, sd_dropdown-button: actions__dropdown-button, sd_dropdown-content: actions__dropdown-content"})))))),t.h("div",{class:"pagination"},t.h("button",{class:"arrow left",onClick:()=>this.previousPageClickedHandler(),disabled:this.previousCursors.length<=0},t.h("chevron-icon",null)),t.h("button",{class:"arrow right",onClick:()=>this.nextPageClickedHandler(),disabled:this.disableNextPageButton},t.h("chevron-icon",null)))),this.state==="error"&&t.h("div",{class:"error-container"},t.h("p",{class:"error"},this.error)))}get host(){return t.getElement(this)}static get watchers(){return{listConfigurationsNextCursor:["listConfigurationsNextCursorChangedHandler"]}}};Be([ve.RegisterComponent({name:"nylas-list-configurations",stateToProps:new Map([["schedulerConfig.configurations","configurations"],["schedulerConfig.listConfigurationsNextCursor","listConfigurationsNextCursor"]]),localPropsToProp:new Map([["schedulerPreviewLink","schedulerPreviewLink"]]),eventToProps:{initListConfigurations:async(e,i)=>{const{host:a,cursor:s}=e.detail;await a.setState("loading");const[r,n]=await i.schedulerConfig.getConfigurations(s);if(!r&&n&&n.message){await a.setState("error"),await a.setError(n.message);return}await a.setState("loaded")},createButtonClick:async(e,i)=>{i.schedulerConfigStore.resetSelectedConfiguration(),i.schedulerConfigStore.state.action="create"},deleteButtonClick:async(e,i)=>{const{host:a,configuration:s}=e.detail,[r,n]=await i.schedulerConfig.deleteConfiguration(s.id);!r&&n&&n.message&&(await a.setState("error"),await a.setError(n.message))},editButtonClick:async(e,i)=>{const{configuration:a}=e.detail;i.schedulerConfigStore.state.selectedConfiguration=a,i.schedulerConfigStore.state.action="edit"}},fireRegisterEvent:!0}),A("design:type",Function),A("design:paramtypes",[]),A("design:returntype",void 0)],V.prototype,"render",null);V.style=De;exports.google_logo_icon=we;exports.microsoft_logo_icon=ke;exports.nylas_editor_tabs=$;exports.nylas_list_configurations=V;