@nylas/react 1.3.5 → 1.4.0

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 (221) hide show
  1. package/dist/add-circle-icon_2.entry-6e8e4e1e.cjs +1 -0
  2. package/dist/add-circle-icon_2.entry-dbad9a3b.js +26 -0
  3. package/dist/archive-icon.entry-21f532af.cjs +1 -0
  4. package/dist/archive-icon.entry-802f7877.js +16 -0
  5. package/dist/{arrow-icon.entry-fa9584cf.js → arrow-icon.entry-e3dec626.js} +3 -2
  6. package/dist/arrow-icon.entry-e9af732a.cjs +1 -0
  7. package/dist/{bold-icon.entry-ac6a4956.js → bold-icon.entry-0492ff02.js} +3 -2
  8. package/dist/bold-icon.entry-1a2be28a.cjs +1 -0
  9. package/dist/button-component_2.entry-f0c7f894.cjs +1 -0
  10. package/dist/{button-component_2.entry-caf33abf.js → button-component_2.entry-fea9bd3d.js} +10 -9
  11. package/dist/calendar-agenda-fill-icon_36.entry-70681da2.cjs +6 -0
  12. package/dist/calendar-agenda-fill-icon_36.entry-c85d6a79.js +4642 -0
  13. package/dist/calendar-cancel-icon.entry-237b8c9e.cjs +1 -0
  14. package/dist/{calendar-cancel-icon.entry-02015d74.js → calendar-cancel-icon.entry-e7dd5b8f.js} +6 -5
  15. package/dist/calendar-check-icon_2.entry-a868e0bc.cjs +1 -0
  16. package/dist/{calendar-check-icon_2.entry-2f7dc236.js → calendar-check-icon_2.entry-c7f47fc8.js} +10 -9
  17. package/dist/calendar-icon.entry-071eb30d.cjs +1 -0
  18. package/dist/{calendar-icon.entry-70ac9bd6.js → calendar-icon.entry-324de624.js} +6 -5
  19. package/dist/checkbox-component.entry-0f9970cc.js +43 -0
  20. package/dist/checkbox-component.entry-5bcf4b08.cjs +1 -0
  21. package/dist/checkmark-icon_15.entry-7776e533.cjs +5 -0
  22. package/dist/checkmark-icon_15.entry-98377585.js +1337 -0
  23. package/dist/chevron-icon_3.entry-526b4b85.cjs +1 -0
  24. package/dist/chevron-icon_3.entry-ec66260c.js +148 -0
  25. package/dist/{clock-icon_4.entry-af5301d7.js → clock-icon_4.entry-4fa47996.js} +19 -18
  26. package/dist/clock-icon_4.entry-66d15f7c.cjs +1 -0
  27. package/dist/{constants-f6e79ab7-24392f9e.js → constants-f5ba52b9-40ab2ded.js} +121 -30
  28. package/dist/constants-f5ba52b9-a0866d2f.cjs +1 -0
  29. package/dist/customParseFormat-39eacb44-45ade322.cjs +1 -0
  30. package/dist/customParseFormat-39eacb44-eeffe2bb.js +135 -0
  31. package/dist/delete-icon.entry-540aa2bb.cjs +1 -0
  32. package/dist/{delete-icon.entry-00cb3ee8.js → delete-icon.entry-95d01eb8.js} +7 -6
  33. package/dist/document-refresh-icon.entry-b82d5da8.js +16 -0
  34. package/dist/document-refresh-icon.entry-c467f082.cjs +1 -0
  35. package/dist/elements/index.d.ts +11 -0
  36. package/dist/{feedbackSync-547e51ee-bcaf691c.js → feedbackSync-47d13bb0-5608d680.js} +1 -1
  37. package/dist/{feedbackSync-547e51ee-9b572309.cjs → feedbackSync-47d13bb0-9f249f33.cjs} +1 -1
  38. package/dist/folder-icon.entry-4d48c2ee.cjs +1 -0
  39. package/dist/{folder-icon.entry-60b3eda5.js → folder-icon.entry-cb0dc63d.js} +5 -4
  40. package/dist/forward-icon.entry-5aa01f53.js +16 -0
  41. package/dist/forward-icon.entry-d04aaf6d.cjs +1 -0
  42. package/dist/globe-icon_2.entry-87e29cdf.cjs +1 -0
  43. package/dist/globe-icon_2.entry-c7ae78cc.js +200 -0
  44. package/dist/google-logo-icon_6.entry-80a6bfa3.js +1457 -0
  45. package/dist/google-logo-icon_6.entry-a8b6efc0.cjs +2 -0
  46. package/dist/google-meet-icon_5.entry-26d667b6.cjs +1 -0
  47. package/dist/google-meet-icon_5.entry-4e71c83b.js +56 -0
  48. package/dist/inbox-icon.entry-60a82bfc.cjs +1 -0
  49. package/dist/inbox-icon.entry-77e4e17b.js +16 -0
  50. package/dist/index-04630615.js +17580 -0
  51. package/dist/index-3d1f13d6.cjs +57 -0
  52. package/dist/index.d.ts +1 -3
  53. package/dist/{index.es-2d849a15-2d84f7a5.cjs → index.es-1fdb1e36-830a422f.cjs} +6 -6
  54. package/dist/{index.es-2d849a15-4eb8e180.js → index.es-1fdb1e36-fbdb04fa.js} +818 -804
  55. package/dist/info-icon_2.entry-34800b66.cjs +1 -0
  56. package/dist/info-icon_2.entry-3c483f61.js +35 -0
  57. package/dist/input-component.entry-ea4016fe.js +84 -0
  58. package/dist/input-component.entry-f7ccf3d6.cjs +1 -0
  59. package/dist/input-dropdown_2.entry-c7730cf8.js +231 -0
  60. package/dist/input-dropdown_2.entry-d4024d2f.cjs +1 -0
  61. package/dist/italic-icon.entry-6e0805ab.js +16 -0
  62. package/dist/italic-icon.entry-8127c2ee.cjs +1 -0
  63. package/dist/multi-select-dropdown_2.entry-49d6f0e7.cjs +1 -0
  64. package/dist/multi-select-dropdown_2.entry-d749999d.js +187 -0
  65. package/dist/notebook-store-b61693cd-7a5576e7.js +14 -0
  66. package/dist/notebook-store-b61693cd-84de36d2.cjs +5 -0
  67. package/dist/nylas-booked-event-card_12.entry-29337b10.cjs +1 -0
  68. package/dist/nylas-booked-event-card_12.entry-3fcfd6f9.js +1418 -0
  69. package/dist/nylas-call-summary.entry-38aed89a.js +16 -0
  70. package/dist/nylas-call-summary.entry-e9adcb93.cjs +1 -0
  71. package/dist/nylas-event-calendar_3.entry-48f656e5.cjs +6 -0
  72. package/dist/nylas-event-calendar_3.entry-62d1f1f5.js +9693 -0
  73. package/dist/nylas-form-card.entry-3828ccb1.js +58 -0
  74. package/dist/nylas-form-card.entry-b900b46e.cjs +1 -0
  75. package/dist/{nylas-if-state.entry-beef8af6.js → nylas-if-state.entry-2810dcf5.js} +4 -3
  76. package/dist/nylas-if-state.entry-92af0a51.cjs +1 -0
  77. package/dist/nylas-key-points.entry-977a6fae.js +29 -0
  78. package/dist/nylas-key-points.entry-de658637.cjs +1 -0
  79. package/dist/nylas-login.entry-4a6c11e6.cjs +1 -0
  80. package/dist/{nylas-login.entry-1661cbd4.js → nylas-login.entry-8101d3d0.js} +4 -3
  81. package/dist/nylas-provider.entry-b7ac25f5.cjs +1 -0
  82. package/dist/{nylas-provider.entry-1f140378.js → nylas-provider.entry-c054d68a.js} +6 -5
  83. package/dist/nylas-scheduler-editor.entry-1538950d.cjs +2 -0
  84. package/dist/{nylas-scheduler-editor.entry-f184f72e.js → nylas-scheduler-editor.entry-e35fad5c.js} +530 -272
  85. package/dist/nylas-scheduling.entry-360b978c.js +439 -0
  86. package/dist/nylas-scheduling.entry-92351cd2.cjs +1 -0
  87. package/dist/nylas-transcript.entry-4d973027.cjs +6 -0
  88. package/dist/nylas-transcript.entry-81e2c821.js +128 -0
  89. package/dist/nylas-video-player.entry-60268c07.js +39 -0
  90. package/dist/nylas-video-player.entry-f3c2b073.cjs +1 -0
  91. package/dist/nylas-video-preview.entry-12e05e4d.cjs +1 -0
  92. package/dist/nylas-video-preview.entry-320421b6.js +16 -0
  93. package/dist/{person-icon.entry-f9ca9147.js → person-icon.entry-8533209c.js} +8 -7
  94. package/dist/person-icon.entry-967ad730.cjs +1 -0
  95. package/dist/play-icon.entry-15ee8568.js +16 -0
  96. package/dist/play-icon.entry-7b1fd79d.cjs +1 -0
  97. package/dist/radio-button-group.entry-24cb342f.cjs +1 -0
  98. package/dist/radio-button-group.entry-53dcf16c.js +47 -0
  99. package/dist/react.cjs +1 -1
  100. package/dist/react.js +133 -123
  101. package/dist/refresh-icon.entry-0486ae54.cjs +1 -0
  102. package/dist/{refresh-icon.entry-7886041f.js → refresh-icon.entry-f3320971.js} +7 -6
  103. package/dist/{register-component-677d8d2b-0113766e.js → register-component-504a1cbb-5f986d7f.js} +1 -1
  104. package/dist/{register-component-677d8d2b-4738af1d.cjs → register-component-504a1cbb-89124fd8.cjs} +1 -1
  105. package/dist/{reply-all-icon.entry-fdd0058e.js → reply-all-icon.entry-006fd1fb.js} +6 -5
  106. package/dist/reply-all-icon.entry-2cea1a40.cjs +1 -0
  107. package/dist/reply-icon.entry-bd252aed.cjs +1 -0
  108. package/dist/reply-icon.entry-d27166a1.js +16 -0
  109. package/dist/scheduler-config-store-d6729d8d-4a2defea.cjs +1 -0
  110. package/dist/{scheduler-config-store-ed4a8dfd-012dcf85.js → scheduler-config-store-d6729d8d-63e34849.js} +4 -1
  111. package/dist/scheduler-store-baf100ed-5c5d3aa5.cjs +1 -0
  112. package/dist/scheduler-store-baf100ed-81b183dc.js +533 -0
  113. package/dist/sent-icon.entry-bf101068.js +16 -0
  114. package/dist/sent-icon.entry-ee434395.cjs +1 -0
  115. package/dist/spam-icon.entry-11016b63.cjs +1 -0
  116. package/dist/spam-icon.entry-5193f9c6.js +16 -0
  117. package/dist/star-icon.entry-0e269252.cjs +1 -0
  118. package/dist/{star-icon.entry-501083c1.js → star-icon.entry-9c7449f3.js} +6 -5
  119. package/dist/stop-icon.entry-2ac11166.js +16 -0
  120. package/dist/stop-icon.entry-86412c9f.cjs +1 -0
  121. package/dist/textarea-component.entry-27717409.cjs +1 -0
  122. package/dist/textarea-component.entry-9df3fa96.js +39 -0
  123. package/dist/toggle-switch.entry-9623e2b2.cjs +1 -0
  124. package/dist/toggle-switch.entry-a5ddfad9.js +34 -0
  125. package/dist/translate-icon.entry-e0617680.cjs +1 -0
  126. package/dist/{translate-icon.entry-676a4150.js → translate-icon.entry-f22293e6.js} +5 -4
  127. package/dist/trash-fill-icon.entry-0275f657.cjs +1 -0
  128. package/dist/trash-fill-icon.entry-2616c5df.js +16 -0
  129. package/dist/{underline-icon.entry-3513c5ef.js → underline-icon.entry-1110dcb1.js} +5 -4
  130. package/dist/underline-icon.entry-d54b06ab.cjs +1 -0
  131. package/dist/warning-icon.entry-6d390ab7.cjs +1 -0
  132. package/dist/{warning-icon.entry-6e723597.js → warning-icon.entry-9a6e7913.js} +8 -7
  133. package/package.json +11 -3
  134. package/dist/add-circle-icon.entry-00c87903.js +0 -15
  135. package/dist/add-circle-icon.entry-640d2b46.cjs +0 -1
  136. package/dist/archive-icon.entry-5b209336.cjs +0 -1
  137. package/dist/archive-icon.entry-e8a39eda.js +0 -15
  138. package/dist/arrow-icon.entry-a25b7b7e.cjs +0 -1
  139. package/dist/bold-icon.entry-d837c73d.cjs +0 -1
  140. package/dist/button-component_2.entry-1471422a.cjs +0 -1
  141. package/dist/calendar-agenda-fill-icon_53.entry-094bd4b9.cjs +0 -6
  142. package/dist/calendar-agenda-fill-icon_53.entry-6d7f9c79.js +0 -5757
  143. package/dist/calendar-cancel-icon.entry-42d3d226.cjs +0 -1
  144. package/dist/calendar-check-icon_2.entry-45aacd91.cjs +0 -1
  145. package/dist/calendar-icon.entry-90d67b03.cjs +0 -1
  146. package/dist/checkbox-component_3.entry-231b2254.cjs +0 -1
  147. package/dist/checkbox-component_3.entry-7270533c.js +0 -153
  148. package/dist/chevron-icon_3.entry-3c95cc88.js +0 -147
  149. package/dist/chevron-icon_3.entry-ead3d4c8.cjs +0 -1
  150. package/dist/clock-icon_4.entry-b50cce70.cjs +0 -1
  151. package/dist/close-icon.entry-04008446.cjs +0 -1
  152. package/dist/close-icon.entry-0a4105c9.js +0 -15
  153. package/dist/constants-f6e79ab7-23d7236b.cjs +0 -1
  154. package/dist/copy-icon.entry-312ff230.js +0 -15
  155. package/dist/copy-icon.entry-74f8ebcd.cjs +0 -1
  156. package/dist/core-js-38e53e34.cjs +0 -4
  157. package/dist/core-js-a9d3b6e1.js +0 -3297
  158. package/dist/delete-icon.entry-b61a6706.cjs +0 -1
  159. package/dist/document-refresh-icon.entry-1c985b1e.js +0 -15
  160. package/dist/document-refresh-icon.entry-27ff5cb2.cjs +0 -1
  161. package/dist/dom-68f08be9.cjs +0 -15
  162. package/dist/dom-86e17616.js +0 -664
  163. package/dist/folder-icon.entry-c32a6e15.cjs +0 -1
  164. package/dist/forward-icon.entry-5f9a7639.js +0 -15
  165. package/dist/forward-icon.entry-8cd805dc.cjs +0 -1
  166. package/dist/globe-icon.entry-21a80591.cjs +0 -1
  167. package/dist/globe-icon.entry-397727e1.js +0 -15
  168. package/dist/google-logo-icon_4.entry-42e87368.cjs +0 -1
  169. package/dist/google-logo-icon_4.entry-6ccf8379.js +0 -778
  170. package/dist/inbox-icon.entry-1e448b4b.js +0 -15
  171. package/dist/inbox-icon.entry-50605b1d.cjs +0 -1
  172. package/dist/index-594c8e7b.js +0 -16763
  173. package/dist/index-cfb93df6.cjs +0 -81
  174. package/dist/info-icon_2.entry-65e0023f.js +0 -34
  175. package/dist/info-icon_2.entry-e7b86847.cjs +0 -1
  176. package/dist/input-color-picker.entry-37d2fb66.js +0 -48
  177. package/dist/input-color-picker.entry-aabfe638.cjs +0 -1
  178. package/dist/input-component.entry-51f6da14.cjs +0 -1
  179. package/dist/input-component.entry-c07d92b1.js +0 -70
  180. package/dist/input-dropdown_2.entry-20fb0552.cjs +0 -1
  181. package/dist/input-dropdown_2.entry-90c08f10.js +0 -228
  182. package/dist/italic-icon.entry-8e5599ff.js +0 -15
  183. package/dist/italic-icon.entry-ee10a040.cjs +0 -1
  184. package/dist/multi-select-dropdown.entry-656d2791.cjs +0 -1
  185. package/dist/multi-select-dropdown.entry-c143becc.js +0 -116
  186. package/dist/nylas-booked-event-card_12.entry-4974ffe6.js +0 -1332
  187. package/dist/nylas-booked-event-card_12.entry-669bb872.cjs +0 -1
  188. package/dist/nylas-form-card.entry-42e718e2.js +0 -57
  189. package/dist/nylas-form-card.entry-55d3909c.cjs +0 -1
  190. package/dist/nylas-if-state.entry-4de782b7.cjs +0 -1
  191. package/dist/nylas-login.entry-d6b80abe.cjs +0 -1
  192. package/dist/nylas-provider.entry-d5495e1a.cjs +0 -1
  193. package/dist/nylas-scheduler-editor.entry-bebe4e7d.cjs +0 -2
  194. package/dist/nylas-scheduling.entry-21c04831.cjs +0 -1
  195. package/dist/nylas-scheduling.entry-c335ad21.js +0 -415
  196. package/dist/nylas-time-window-picker_2.entry-9e0dd470.js +0 -336
  197. package/dist/nylas-time-window-picker_2.entry-a2651ee7.cjs +0 -1
  198. package/dist/person-icon.entry-21946944.cjs +0 -1
  199. package/dist/play-icon.entry-b27fcb18.cjs +0 -1
  200. package/dist/play-icon.entry-dbfed5e8.js +0 -15
  201. package/dist/refresh-icon.entry-9d94a60b.cjs +0 -1
  202. package/dist/reply-all-icon.entry-f0e0a5c4.cjs +0 -1
  203. package/dist/reply-icon.entry-0a42fb2c.cjs +0 -1
  204. package/dist/reply-icon.entry-a8d2b0f8.js +0 -15
  205. package/dist/scheduler-config-store-ed4a8dfd-a16d5c62.cjs +0 -1
  206. package/dist/scheduler-store-92eb8804-bc68a43a.js +0 -487
  207. package/dist/scheduler-store-92eb8804-c3deee73.cjs +0 -1
  208. package/dist/sent-icon.entry-c3f84a59.cjs +0 -1
  209. package/dist/sent-icon.entry-e047f087.js +0 -15
  210. package/dist/spam-icon.entry-55d01416.js +0 -15
  211. package/dist/spam-icon.entry-671eb165.cjs +0 -1
  212. package/dist/star-icon.entry-4dcae472.cjs +0 -1
  213. package/dist/stop-icon.entry-130a28b2.js +0 -15
  214. package/dist/stop-icon.entry-ed949255.cjs +0 -1
  215. package/dist/textarea-component.entry-65dd740a.cjs +0 -1
  216. package/dist/textarea-component.entry-efae9031.js +0 -37
  217. package/dist/translate-icon.entry-2591baf8.cjs +0 -1
  218. package/dist/trash-fill-icon.entry-5b373be7.js +0 -15
  219. package/dist/trash-fill-icon.entry-c411d0e0.cjs +0 -1
  220. package/dist/underline-icon.entry-6bf14476.cjs +0 -1
  221. package/dist/warning-icon.entry-719a094d.cjs +0 -1
@@ -0,0 +1,533 @@
1
+ import { d as A, a as z, i as c, l as F } from "./index-04630615.js";
2
+ var D;
3
+ (function(a) {
4
+ a.Component = "component", a.Api = "api", a.Auth = "auth";
5
+ })(D || (D = {}));
6
+ var M;
7
+ (function(a) {
8
+ a.endtime_not_in_future = "endtime_not_in_future", a.no_booking_info = "no_booking_info", a.no_timeslot_selected = "no_timeslot_selected", a.no_timezone_selected = "no_timezone_selected", a.no_booking_id = "no_booking_id", a.no_salt = "no_salt", a.invalid_start_time = "invalid_start_time", a.invalid_end_time = "invalid_end_time", a.invalid_timezone = "invalid_timezone", a.no_config_id = "no_config_id";
9
+ })(M || (M = {}));
10
+ var $;
11
+ (function(a) {
12
+ a.invalid_session = "invalid_session", a.general_error = "general_error", a.internal_error = "internal_error", a.invalid_request_error = "invalid_request_error", a.timeslot_not_available = "timeslot_not_available", a.provider_error = "provider_error", a.not_found_error = "not_found_error";
13
+ })($ || ($ = {}));
14
+ class C {
15
+ constructor() {
16
+ this.component = (e) => {
17
+ const t = D.Component, s = `${e} Error`;
18
+ return {
19
+ endtime_not_in_future: (i = '"endtime" can not be in the future') => ({
20
+ title: s,
21
+ message: i,
22
+ category: t
23
+ }),
24
+ no_booking_info: (i = "No booking info provided") => ({
25
+ title: s,
26
+ message: i,
27
+ category: t
28
+ }),
29
+ no_timeslot_selected: (i = "No timeslot selected") => ({
30
+ title: s,
31
+ message: i,
32
+ category: t
33
+ }),
34
+ no_timezone_selected: (i = "No timezone selected") => ({
35
+ title: s,
36
+ message: i,
37
+ category: t
38
+ }),
39
+ no_booking_id: (i = "No booking id provided") => ({
40
+ title: s,
41
+ message: i,
42
+ category: t
43
+ }),
44
+ no_salt: (i = "No salt provided") => ({
45
+ title: s,
46
+ message: i,
47
+ category: t
48
+ }),
49
+ invalid_start_time: (i = "Invalid start time") => ({
50
+ title: s,
51
+ message: i,
52
+ category: t
53
+ }),
54
+ invalid_end_time: (i = "Invalid end time") => ({
55
+ title: s,
56
+ message: i,
57
+ category: t
58
+ }),
59
+ invalid_timezone: (i = "Invalid timezone") => ({
60
+ title: s,
61
+ message: i,
62
+ category: t
63
+ }),
64
+ no_config_id: (i = "No configuration id provided") => ({
65
+ title: s,
66
+ message: i,
67
+ category: t
68
+ })
69
+ };
70
+ }, this.api = (e) => {
71
+ const t = D.Api, s = `${e} Error`;
72
+ return {
73
+ invalid_session: (i) => ({
74
+ title: s,
75
+ message: i,
76
+ category: t
77
+ }),
78
+ general_error: (i) => ({
79
+ title: s,
80
+ message: i,
81
+ category: t
82
+ }),
83
+ internal_error: (i) => ({
84
+ title: s,
85
+ message: i,
86
+ category: t
87
+ }),
88
+ invalid_request_error: (i) => ({
89
+ title: s,
90
+ message: i,
91
+ category: t
92
+ }),
93
+ timeslot_not_available: (i) => ({
94
+ title: s,
95
+ message: i,
96
+ category: t
97
+ }),
98
+ provider_error: (i) => ({
99
+ title: s,
100
+ message: i,
101
+ category: t
102
+ }),
103
+ not_found_error: (i) => ({
104
+ title: s,
105
+ message: i,
106
+ category: t
107
+ })
108
+ };
109
+ };
110
+ }
111
+ }
112
+ class O {
113
+ constructor({ schedulerAPIURL: e, schedulerStore: t, sessionId: s, configId: i, slug: n, clientId: r }) {
114
+ this.errors = new C(), this.schedulerStore = t, this.schedulerAPIURL = e, this.sessionId = s, this.configId = i, this.slug = n, this.clientId = r;
115
+ }
116
+ getHeaders() {
117
+ return this.sessionId ? {
118
+ Authorization: `Bearer ${this.sessionId}`
119
+ } : {};
120
+ }
121
+ async makeAPIRequest(e, t, s, i = {}) {
122
+ try {
123
+ const n = new URL(this.schedulerAPIURL), r = "1.4.0";
124
+ return n.pathname = e, await (await fetch(decodeURIComponent(n.toString()), {
125
+ method: t,
126
+ headers: {
127
+ "Content-Type": "application/json",
128
+ Origin: window.location.origin,
129
+ "X-Source": "nylas-scheduling",
130
+ "X-Nylas-Web-Elements-Version": r,
131
+ ...i
132
+ },
133
+ body: s
134
+ })).json();
135
+ } catch (n) {
136
+ return {
137
+ error: {
138
+ message: n.message,
139
+ title: "API request failed",
140
+ type: "api"
141
+ }
142
+ };
143
+ }
144
+ }
145
+ getErrorMessage(e) {
146
+ var s, i, n, r;
147
+ let t = (e == null ? void 0 : e.message) || (e == null ? void 0 : e.title) || "Something went wrong";
148
+ return (e == null ? void 0 : e.type) === "provider_error" && (t = ((i = (s = e == null ? void 0 : e.provider_error) == null ? void 0 : s.error) == null ? void 0 : i.message) || ((r = (n = e == null ? void 0 : e.provider_error) == null ? void 0 : n.error) == null ? void 0 : r.title) || "Something went wrong"), t;
149
+ }
150
+ setConfigId(e) {
151
+ this.configId = e;
152
+ }
153
+ selectDate(e) {
154
+ this.schedulerStore.set("selectedDate", e), this.schedulerStore.set("selectedTimeslot", null);
155
+ }
156
+ selectTime(e) {
157
+ this.schedulerStore.set("selectedTimeslot", e);
158
+ }
159
+ selectTimezone(e) {
160
+ this.schedulerStore.set("selectedTimezone", e);
161
+ }
162
+ selectLanguage(e) {
163
+ this.schedulerStore.set("selectedLanguage", e), c.changeLanguage(e);
164
+ }
165
+ async toggleAdditionalData(e) {
166
+ e || await this.refetchAvailability(), this.schedulerStore.set("showBookingForm", e);
167
+ }
168
+ setParticipantName(e) {
169
+ const { bookingInfo: t } = this.schedulerStore.state;
170
+ this.schedulerStore.set("bookingInfo", {
171
+ ...t,
172
+ primaryParticipant: {
173
+ ...t == null ? void 0 : t.primaryParticipant,
174
+ name: e
175
+ }
176
+ });
177
+ }
178
+ setParticipantEmail(e) {
179
+ const { bookingInfo: t } = this.schedulerStore.state;
180
+ this.schedulerStore.set("bookingInfo", {
181
+ ...t,
182
+ primaryParticipant: {
183
+ ...t == null ? void 0 : t.primaryParticipant,
184
+ email: e
185
+ }
186
+ });
187
+ }
188
+ async refetchAvailability() {
189
+ const e = /* @__PURE__ */ new Date(), t = new Date(e.getFullYear(), e.getMonth(), 1).getTime() / 1e3, s = t < e.getTime() / 1e3 ? Math.floor(e.getTime() / 1e3) : t, i = new Date(e.getFullYear(), e.getMonth() + 1, 1).getTime() / 1e3;
190
+ return await this.getAvailability(s, i);
191
+ }
192
+ async resetStoreStateAndFetchAvailability() {
193
+ const e = /* @__PURE__ */ new Date(), t = await this.refetchAvailability(), s = this.schedulerStore.get("availability").find((n) => new Date(n.start_time) > /* @__PURE__ */ new Date());
194
+ let i = e;
195
+ return s && (i = s.start_time), this.schedulerStore.set("selectedDate", i), this.schedulerStore.set("eventInfo", null), this.schedulerStore.set("showBookingForm", !1), this.schedulerStore.set("selectedTimeslot", null), t;
196
+ }
197
+ async setReschedule(e) {
198
+ this.schedulerStore.set("isLoading", !0);
199
+ const t = this.schedulerStore.state.eventInfo;
200
+ return t && this.schedulerStore.set("reschedulingEventInfo", t), this.schedulerStore.set("rescheduleBookingId", e), await this.getUISettings(), await this.resetStoreStateAndFetchAvailability().finally(() => {
201
+ this.schedulerStore.set("isLoading", !1);
202
+ });
203
+ }
204
+ async setCancel(e) {
205
+ this.schedulerStore.set("cancelBookingId", e);
206
+ }
207
+ async setReject(e) {
208
+ this.schedulerStore.set("rejectBookingId", e);
209
+ }
210
+ async resetCancel() {
211
+ const e = await this.resetStoreStateAndFetchAvailability();
212
+ return this.schedulerStore.set("cancelBookingId", ""), this.schedulerStore.set("rejectBookingId", ""), this.schedulerStore.set("cancelledEventInfo", null), e;
213
+ }
214
+ async goBack() {
215
+ this.schedulerStore.set("cancelBookingId", "");
216
+ }
217
+ async resetConfirm() {
218
+ const e = await this.resetStoreStateAndFetchAvailability();
219
+ return this.schedulerStore.set("organizerConfirmationBookingId", ""), this.schedulerStore.set("confirmedEventInfo", void 0), e;
220
+ }
221
+ async bookTimeslot(e) {
222
+ var L, p, E;
223
+ this.schedulerStore.set("isLoading", !0);
224
+ const { selectedTimeslot: t, selectedTimezone: s, bookingInfo: i, selectedLanguage: n } = this.schedulerStore.state;
225
+ if (!e && !i)
226
+ return { error: this.errors.component(c.t("createBookingErrorTitle")).no_booking_info() };
227
+ const r = (e == null ? void 0 : e.timeslot) || t;
228
+ if (!r)
229
+ return { error: this.errors.component(c.t("createBookingErrorTitle")).no_timeslot_selected() };
230
+ const l = e && (e != null && e.timezone) ? e == null ? void 0 : e.timezone : s, o = n || "en-US";
231
+ if (!l)
232
+ return { error: this.errors.component(c.t("createBookingErrorTitle")).no_timezone_selected() };
233
+ const h = [...this.schedulerStore.get("availabilityOrderEmails")];
234
+ let d = "";
235
+ const m = (r == null ? void 0 : r.emails) || [], f = {};
236
+ Object.entries((i == null ? void 0 : i.additionalFields) || {}).forEach(([u, w]) => {
237
+ f[u] = w.value;
238
+ });
239
+ const _ = e ? e == null ? void 0 : e.primaryParticipant : i == null ? void 0 : i.primaryParticipant, S = e ? (e == null ? void 0 : e.guests) || [] : (i == null ? void 0 : i.guests) || [], y = e ? e == null ? void 0 : e.additionalFields : f, g = this.getHeaders(), b = `/v3/scheduling/bookings${!this.sessionId && this.configId ? `?configuration_id=${this.configId}` : !this.sessionId && this.slug && this.clientId ? `?slug=${this.slug}&client_id=${this.clientId}` : ""}`;
240
+ if (h.length === 0) {
241
+ const u = await this.makeAPIRequest(decodeURIComponent(b), "POST", JSON.stringify({
242
+ additional_fields: y,
243
+ additional_guests: S,
244
+ guest: { ..._ },
245
+ start_time: r.start_time.getTime() / 1e3,
246
+ end_time: r.end_time.getTime() / 1e3,
247
+ timezone: l,
248
+ event_id: (r == null ? void 0 : r.event_id) || void 0,
249
+ master_id: (r == null ? void 0 : r.master_id) || void 0,
250
+ calendar_id: (r == null ? void 0 : r.calendar_id) || void 0,
251
+ email_language: this.getTwoLetterLanguageCode(o)
252
+ }), g);
253
+ return this.schedulerStore.set("isLoading", !1), "data" in u ? (this.schedulerStore.set("eventInfo", u.data), u) : { error: u.error };
254
+ }
255
+ for (; h.length > 0; ) {
256
+ if (d = h.shift(), !m.includes(d))
257
+ continue;
258
+ const u = await this.makeAPIRequest(decodeURIComponent(b), "POST", JSON.stringify({
259
+ participants: d ? [{ email: d }] : void 0,
260
+ additional_fields: y,
261
+ additional_guests: S,
262
+ guest: { ..._ },
263
+ start_time: r.start_time.getTime() / 1e3,
264
+ end_time: r.end_time.getTime() / 1e3,
265
+ timezone: l,
266
+ email_language: this.getTwoLetterLanguageCode(o)
267
+ }), g);
268
+ if ("data" in u)
269
+ return this.schedulerStore.set("isLoading", !1), this.schedulerStore.set("eventInfo", u == null ? void 0 : u.data), u;
270
+ if ((p = (L = u.error) == null ? void 0 : L.message) != null && p.startsWith("The selected timeslot is unavailable"))
271
+ continue;
272
+ {
273
+ this.schedulerStore.set("isLoading", !1);
274
+ const w = (E = u.error) == null ? void 0 : E.type;
275
+ let v = u.error;
276
+ if (w && w in this.errors.api(c.t("createBookingErrorTitle"))) {
277
+ const B = this.getErrorMessage(v);
278
+ v = this.errors.api(c.t("createBookingErrorTitle"))[w](B);
279
+ }
280
+ return { error: v };
281
+ }
282
+ }
283
+ return this.schedulerStore.set("isLoading", !1), {
284
+ error: this.errors.api(c.t("createBookingErrorTitle")).timeslot_not_available("The selected timeslot is unavailable")
285
+ };
286
+ }
287
+ async getUISettings() {
288
+ var r;
289
+ this.schedulerStore.set("isLoading", !0);
290
+ const e = this.schedulerStore.get("rescheduleBookingId"), t = this.getHeaders();
291
+ let s = !this.sessionId && this.configId ? `?configuration_id=${this.configId}` : !this.sessionId && this.slug && this.clientId ? `?slug=${this.slug}&client_id=${this.clientId}` : "";
292
+ e && s ? s += `&booking_id=${e}` : e && (s += `?booking_id=${e}`);
293
+ const i = `/v3/scheduling/ui-settings${s}`, n = await this.makeAPIRequest(i, "GET", void 0, t);
294
+ if ("error" in n) {
295
+ this.schedulerStore.set("isLoading", !1);
296
+ const l = (r = n.error) == null ? void 0 : r.type;
297
+ let o = n.error;
298
+ return l && l in this.errors.api(c.t("getUISettingErrorTitle")) && (o = this.errors.api(c.t("getUISettingErrorTitle"))[l]((o == null ? void 0 : o.message) || (o == null ? void 0 : o.title) || "Something went wrong")), { error: o };
299
+ }
300
+ return "data" in n && this.schedulerStore.set("configSettings", n.data), this.schedulerStore.set("isLoading", !1), n;
301
+ }
302
+ getTwoLetterLanguageCode(e) {
303
+ return e.split("-")[0];
304
+ }
305
+ getStartTimeWithMinBookingNotice(e) {
306
+ var n;
307
+ const t = (n = this.schedulerStore.get("configSettings")) == null ? void 0 : n.scheduler, s = t == null ? void 0 : t.min_booking_notice;
308
+ if (!s)
309
+ return e;
310
+ const i = (/* @__PURE__ */ new Date()).getTime();
311
+ return e < (i + s * 60 * 1e3) / 1e3 ? Math.floor((i + s * 60 * 1e3) / 1e3) : e;
312
+ }
313
+ getEndTimeForAvailableDaysInFuture(e) {
314
+ var r, l;
315
+ const t = /* @__PURE__ */ new Date(), s = (l = (r = this.schedulerStore.get("configSettings")) == null ? void 0 : r.scheduler) == null ? void 0 : l.available_days_in_future, i = Math.floor(F(t, s).getTime() / 1e3);
316
+ return Math.min(i, e);
317
+ }
318
+ async getAvailability(e = 0, t = 0) {
319
+ var f, _, S, y;
320
+ this.schedulerStore.set("isLoading", !0);
321
+ const s = new URLSearchParams(), i = /* @__PURE__ */ new Date(), n = i.getTime();
322
+ if (t && t < n / 1e3)
323
+ return this.schedulerStore.set("isLoading", !1), { error: this.errors.component(c.t("getAvailabilityErrorTitle")).endtime_not_in_future() };
324
+ if (!e) {
325
+ const g = new Date(i.getFullYear(), i.getMonth(), 1);
326
+ e = Math.floor(g.getTime() / 1e3);
327
+ }
328
+ if (!t) {
329
+ const g = new Date(i.getFullYear(), i.getMonth() + 1, 0);
330
+ t = Math.floor(g.getTime() / 1e3);
331
+ }
332
+ t = this.getEndTimeForAvailableDaysInFuture(t);
333
+ const r = this.getStartTimeWithMinBookingNotice(e);
334
+ e = r, t = r > t ? r + 1 : t, s.append("start_time", encodeURIComponent(e.toString())), s.append("end_time", encodeURIComponent(t.toString())), this.configId && !this.sessionId ? s.append("configuration_id", encodeURIComponent(this.configId)) : this.slug && this.clientId && !this.sessionId && (s.append("slug", encodeURIComponent(this.slug)), s.append("client_id", encodeURIComponent(this.clientId)));
335
+ const l = this.schedulerStore.get("rescheduleBookingId");
336
+ l && s.append("booking_id", encodeURIComponent(l));
337
+ const o = s.toString(), h = `/v3/scheduling/availability${o ? `?${o}` : ""}`, d = this.getHeaders(), m = await this.makeAPIRequest(decodeURIComponent(h), "GET", void 0, d);
338
+ if ("error" in m) {
339
+ this.schedulerStore.set("availability", []), this.schedulerStore.set("isLoading", !1);
340
+ const g = (f = m.error) == null ? void 0 : f.type;
341
+ let k = m.error;
342
+ if (g && g in this.errors.api(c.t("getAvailabilityErrorTitle"))) {
343
+ const b = this.getErrorMessage(k);
344
+ k = this.errors.api(c.t("getAvailabilityErrorTitle"))[g](b);
345
+ }
346
+ return { error: k };
347
+ }
348
+ if ("data" in m) {
349
+ const b = (((S = (_ = m.data) == null ? void 0 : _.time_slots) == null ? void 0 : S.map((p) => ({
350
+ ...p,
351
+ start_time: new Date(p.start_time * 1e3),
352
+ end_time: new Date(p.end_time * 1e3)
353
+ }))) || []).filter((p) => p.start_time.getTime() > n).sort((p, E) => p.start_time.getTime() - E.start_time.getTime());
354
+ this.schedulerStore.set("availability", b);
355
+ const L = ((y = m.data) == null ? void 0 : y.order) || [];
356
+ this.schedulerStore.set("availabilityOrderEmails", L);
357
+ }
358
+ return this.schedulerStore.set("isLoading", !1), m;
359
+ }
360
+ async cancelBooking(e, t) {
361
+ var l;
362
+ if (this.schedulerStore.set("isLoading", !0), !e)
363
+ return { error: this.errors.component(c.t("cancelBookingErrorTitle")).no_booking_id() };
364
+ const s = !this.sessionId && this.configId ? `?configuration_id=${this.configId}` : !this.sessionId && this.slug && this.clientId ? `?slug=${this.slug}&client_id=${this.clientId}` : "", i = `/v3/scheduling/bookings/${e}${s}`, n = this.getHeaders(), r = await this.makeAPIRequest(decodeURIComponent(i), "DELETE", JSON.stringify({
365
+ action: "cancel",
366
+ cancellation_reason: t
367
+ }), n);
368
+ if ("error" in r) {
369
+ this.schedulerStore.set("isLoading", !1);
370
+ const o = (l = r.error) == null ? void 0 : l.type;
371
+ let h = r.error;
372
+ if (o && o in this.errors.api(c.t("cancelBookingErrorTitle"))) {
373
+ const d = this.getErrorMessage(h);
374
+ h = this.errors.api(c.t("cancelBookingErrorTitle"))[o](d);
375
+ }
376
+ return { error: h };
377
+ }
378
+ return this.schedulerStore.set("cancelledEventInfo", {
379
+ booking_id: e
380
+ }), this.schedulerStore.set("rescheduleBookingId", ""), this.schedulerStore.set("isLoading", !1), r;
381
+ }
382
+ async rescheduleBooking(e, t) {
383
+ var P;
384
+ if (this.schedulerStore.set("isLoading", !0), !e)
385
+ return { error: this.errors.component(c.t("rescheduleBookingErrorTitle")).no_booking_id() };
386
+ const s = this.errors.api(c.t("rescheduleBookingErrorTitle")), i = this.errors.component(c.t("rescheduleBookingErrorTitle")), { bookingInfo: n, selectedTimeslot: r, selectedTimezone: l, selectedLanguage: o } = this.schedulerStore.state, { startTime: h, endTime: d, timezone: m } = t, f = h || (r == null ? void 0 : r.start_time);
387
+ if (!f)
388
+ return { error: i.invalid_start_time('Please pass "startTime" in data or set "selectedTimeslot" in the defaultSchedulerState.') };
389
+ const _ = d || (r == null ? void 0 : r.end_time);
390
+ if (!_)
391
+ return { error: i.invalid_end_time('Please pass "endTime" in data or set "selectedTimeslot" in the defaultSchedulerState.') };
392
+ const S = this.schedulerStore.get("availabilityOrderEmails");
393
+ let y = "";
394
+ if (S.length > 0) {
395
+ const T = (r == null ? void 0 : r.emails) || [];
396
+ for (let I = 0; I < S.length; I++)
397
+ if (T.includes(S[I])) {
398
+ y = S[I];
399
+ break;
400
+ }
401
+ }
402
+ const g = m || l;
403
+ if (!g)
404
+ return { error: i.invalid_timezone('Please pass "timezone" in data or set "selectedTimezone" in the defaultSchedulerState.') };
405
+ const k = {};
406
+ Object.entries((n == null ? void 0 : n.additionalFields) || {}).forEach(([T, I]) => {
407
+ k[T] = I.value;
408
+ });
409
+ const b = t ? t == null ? void 0 : t.primaryParticipant : n == null ? void 0 : n.primaryParticipant, L = t ? (t == null ? void 0 : t.guests) || [] : (n == null ? void 0 : n.guests) || [], p = t ? t == null ? void 0 : t.additionalFields : k, E = !this.sessionId && this.configId ? `?configuration_id=${this.configId}` : !this.sessionId && this.slug && this.clientId ? `?slug=${this.slug}&client_id=${this.clientId}` : "", u = `/v3/scheduling/bookings/${e}${E}`, w = this.getHeaders(), v = await this.makeAPIRequest(decodeURIComponent(u), "PATCH", JSON.stringify({
410
+ start_time: f.getTime() / 1e3,
411
+ end_time: _.getTime() / 1e3,
412
+ timezone: g,
413
+ additional_fields: p,
414
+ guest: { ...b },
415
+ additional_guests: L,
416
+ participants: y ? [{ email: y }] : void 0,
417
+ email_language: this.getTwoLetterLanguageCode(o)
418
+ }), w);
419
+ if ("error" in v) {
420
+ this.schedulerStore.set("isLoading", !1);
421
+ const T = (P = v.error) == null ? void 0 : P.type;
422
+ let I = v.error;
423
+ if (T && T in s) {
424
+ const R = this.getErrorMessage(I);
425
+ I = s[T](R);
426
+ }
427
+ return { error: I };
428
+ }
429
+ const B = this.schedulerStore.get("reschedulingEventInfo");
430
+ if ("data" in v)
431
+ this.schedulerStore.set("eventInfo", v == null ? void 0 : v.data);
432
+ else if (B)
433
+ this.schedulerStore.set("eventInfo", B);
434
+ else {
435
+ const T = {
436
+ booking_id: e
437
+ };
438
+ this.schedulerStore.set("eventInfo", T);
439
+ }
440
+ return this.schedulerStore.set("isLoading", !1), v;
441
+ }
442
+ async updateBooking(e) {
443
+ var m;
444
+ this.schedulerStore.set("isLoading", !0);
445
+ const { bookingId: t, status: s, reason: i } = e, n = this.schedulerStore.get("organizerConfirmationSalt"), r = s === "confirmed" ? c.t("confirmBookingErrorTitle") : c.t("rejectBookingErrorTitle");
446
+ if (!t)
447
+ return { error: this.errors.component(r).no_booking_id() };
448
+ if (!n)
449
+ return { error: this.errors.component(r).no_salt() };
450
+ const l = !this.sessionId && this.configId ? `?configuration_id=${this.configId}` : !this.sessionId && this.slug && this.clientId ? `?slug=${this.slug}&client_id=${this.clientId}` : "", o = `/v3/scheduling/bookings/${t}${l}`, h = this.getHeaders(), d = await this.makeAPIRequest(decodeURIComponent(o), "PUT", JSON.stringify({
451
+ status: s,
452
+ cancellation_reason: i,
453
+ salt: n
454
+ }), h);
455
+ if ("error" in d) {
456
+ this.schedulerStore.set("isLoading", !1);
457
+ const f = (m = d.error) == null ? void 0 : m.type;
458
+ let _ = d.error;
459
+ if (f && f in this.errors.api(r)) {
460
+ const S = this.getErrorMessage(_);
461
+ _ = this.errors.api(r)[f](S);
462
+ }
463
+ return { error: _ };
464
+ }
465
+ return "data" in d && s === "confirmed" ? this.schedulerStore.set("confirmedEventInfo", d == null ? void 0 : d.data) : "request_id" in d && s === "cancelled" && this.schedulerStore.set("cancelledEventInfo", {
466
+ booking_id: t
467
+ }), this.schedulerStore.set("organizerConfirmationBookingId", ""), this.schedulerStore.set("isLoading", !1), d;
468
+ }
469
+ async validateGroupEventTimeslot(e) {
470
+ var r, l;
471
+ this.schedulerStore.set("isLoading", !0);
472
+ const t = (r = this.schedulerStore.get("configSettings")) == null ? void 0 : r.configuration_id;
473
+ if (!t)
474
+ return { error: this.errors.component(c.t("validateTimeslotErrorTitle")).no_config_id() };
475
+ const s = this.getHeaders(), i = `/v3/scheduling/configurations/${t}/group-events/validate-timeslot`, n = await this.makeAPIRequest(decodeURIComponent(i), "POST", JSON.stringify({
476
+ ...e,
477
+ start_time: e.start_time.getTime() / 1e3,
478
+ end_time: e.end_time.getTime() / 1e3
479
+ }), s);
480
+ if ("error" in n) {
481
+ this.schedulerStore.set("isLoading", !1);
482
+ const o = (l = n.error) == null ? void 0 : l.type;
483
+ let h = n.error;
484
+ if (o && o in this.errors.api(c.t("validateTimeslotErrorTitle"))) {
485
+ const d = this.getErrorMessage(h);
486
+ h = this.errors.api(c.t("validateTimeslotErrorTitle"))[o](d);
487
+ }
488
+ return this.refetchAvailability(), { error: h };
489
+ }
490
+ return this.schedulerStore.set("selectedTimeslot", e), this.schedulerStore.set("showBookingForm", !0), this.schedulerStore.set("isLoading", !1), n;
491
+ }
492
+ }
493
+ function N(a = {}) {
494
+ const e = {
495
+ selectedDate: null,
496
+ selectedLanguage: navigator.language,
497
+ selectedTimezone: Intl.DateTimeFormat().resolvedOptions().timeZone,
498
+ selectedTimeslot: null,
499
+ showBookingForm: !1,
500
+ availabilityOrderEmails: [],
501
+ selectableDates: null,
502
+ availability: [],
503
+ eventDuration: 0,
504
+ state: "ready",
505
+ eventInfo: null,
506
+ cancelledEventInfo: null,
507
+ isLoading: !1,
508
+ nylasBranding: !0,
509
+ ...a
510
+ };
511
+ A("[defaultNylasStoreState]: ", e);
512
+ const t = z(e);
513
+ return t.onChange("availability", (s) => {
514
+ A("[availability]: ", s);
515
+ const i = s.map((l) => l.start_time);
516
+ A("[selectableDates]: ", i), t.set("selectableDates", i);
517
+ const n = s[0];
518
+ if (!n)
519
+ return;
520
+ const r = Math.floor((n.end_time.getTime() - n.start_time.getTime()) / 6e4);
521
+ A("[durationMinutes]: ", r), t.set("eventDuration", r);
522
+ }), t.reset = () => {
523
+ for (const s in e) {
524
+ const i = e[s];
525
+ t.set(s, i);
526
+ }
527
+ }, t;
528
+ }
529
+ export {
530
+ N as C,
531
+ D as E,
532
+ O as N
533
+ };
@@ -0,0 +1,16 @@
1
+ import { r as s, h as t } from "./index-04630615.js";
2
+ import "react";
3
+ import "react/jsx-runtime";
4
+ import "react-dom";
5
+ const o = ".sc-sent-icon-h{display:flex}", c = o, i = class {
6
+ constructor(e) {
7
+ s(this, e), this.width = "15", this.height = "15";
8
+ }
9
+ render() {
10
+ return t("svg", { key: "fe1f3a8dccc7ed5b4b008b3e7ba2b6aa32bf75df", width: this.width, height: this.height, viewBox: "0 0 24 24", fill: "auto", xmlns: "http://www.w3.org/2000/svg" }, t("path", { key: "319aeb3c8bdce5002c624d4926ec3cb0525d396c", d: "M21.5 12L3.5 3.5L3.5 20.5L21.5 12Z", stroke: "auto", "stroke-width": "1.5" }), t("path", { key: "d05924ef434bb7976571e3f9fe2b00ffaac6c770", d: "M3.5 3.5L12 10.5", stroke: "auto", "stroke-width": "1.5" }), t("path", { key: "0268790deda555924f82a772dcd49783aec96c82", d: "M3.5 20.5L12 13.5", stroke: "auto", "stroke-width": "1.5" }));
11
+ }
12
+ };
13
+ i.style = c;
14
+ export {
15
+ i as sent_icon
16
+ };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-3d1f13d6.cjs");require("react");require("react/jsx-runtime");require("react-dom");const c=".sc-sent-icon-h{display:flex}",i=c,t=class{constructor(s){e.registerInstance(this,s),this.width="15",this.height="15"}render(){return e.h("svg",{key:"fe1f3a8dccc7ed5b4b008b3e7ba2b6aa32bf75df",width:this.width,height:this.height,viewBox:"0 0 24 24",fill:"auto",xmlns:"http://www.w3.org/2000/svg"},e.h("path",{key:"319aeb3c8bdce5002c624d4926ec3cb0525d396c",d:"M21.5 12L3.5 3.5L3.5 20.5L21.5 12Z",stroke:"auto","stroke-width":"1.5"}),e.h("path",{key:"d05924ef434bb7976571e3f9fe2b00ffaac6c770",d:"M3.5 3.5L12 10.5",stroke:"auto","stroke-width":"1.5"}),e.h("path",{key:"0268790deda555924f82a772dcd49783aec96c82",d:"M3.5 20.5L12 13.5",stroke:"auto","stroke-width":"1.5"}))}};t.style=i;exports.sent_icon=t;
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-3d1f13d6.cjs");require("react");require("react/jsx-runtime");require("react-dom");const i=".sc-spam-icon-h{display:flex}",c=i,t=class{constructor(s){e.registerInstance(this,s),this.width="15",this.height="15"}render(){return e.h("svg",{key:"84d7e0e5235fe887cc3d239ce69e0986a1d3014d",width:this.width,height:this.height,viewBox:"0 0 24 24",fill:"auto",xmlns:"http://www.w3.org/2000/svg"},e.h("path",{key:"b0b2350a1cf0d3ba1fdc3d099c9882ca095e1369",d:"M20 3H4C2.89543 3 2 3.89543 2 5V19C2 20.1046 2.89543 21 4 21H20C21.1046 21 22 20.1046 22 19V5C22 3.89543 21.1046 3 20 3Z",stroke:"auto","stroke-width":"1.5"}),e.h("path",{key:"a2b5344063a37dc44ff52d46354443f774bc7c86",d:"M2 5L12 12.5L22 5",stroke:"auto","stroke-width":"1.5"}))}};t.style=c;exports.spam_icon=t;
@@ -0,0 +1,16 @@
1
+ import { r as e, h as t } from "./index-04630615.js";
2
+ import "react";
3
+ import "react/jsx-runtime";
4
+ import "react-dom";
5
+ const o = ".sc-spam-icon-h{display:flex}", i = o, c = class {
6
+ constructor(s) {
7
+ e(this, s), this.width = "15", this.height = "15";
8
+ }
9
+ render() {
10
+ return t("svg", { key: "84d7e0e5235fe887cc3d239ce69e0986a1d3014d", width: this.width, height: this.height, viewBox: "0 0 24 24", fill: "auto", xmlns: "http://www.w3.org/2000/svg" }, t("path", { key: "b0b2350a1cf0d3ba1fdc3d099c9882ca095e1369", d: "M20 3H4C2.89543 3 2 3.89543 2 5V19C2 20.1046 2.89543 21 4 21H20C21.1046 21 22 20.1046 22 19V5C22 3.89543 21.1046 3 20 3Z", stroke: "auto", "stroke-width": "1.5" }), t("path", { key: "a2b5344063a37dc44ff52d46354443f774bc7c86", d: "M2 5L12 12.5L22 5", stroke: "auto", "stroke-width": "1.5" }));
11
+ }
12
+ };
13
+ c.style = i;
14
+ export {
15
+ c as spam_icon
16
+ };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./index-3d1f13d6.cjs");require("react");require("react/jsx-runtime");require("react-dom");const i=".sc-star-icon-h{display:flex}",r=i,e=class{constructor(s){t.registerInstance(this,s),this.width="15",this.height="15"}render(){return t.h("svg",{key:"49798910e83f877f8413abb5c4b11cccacab77eb",width:this.width,height:this.height,viewBox:"0 0 24 24",fill:"auto",xmlns:"http://www.w3.org/2000/svg"},t.h("path",{key:"8e0bddce209f480ad0e39574718ccda799f80c70",d:"M9.15316 5.40838C10.4198 3.13613 11.0531 2 12 2C12.9469 2 13.5802 3.13612 14.8468 5.40837L15.1745 5.99623C15.5345 6.64193 15.7144 6.96479 15.9951 7.17781C16.2757 7.39083 16.6251 7.4699 17.3241 7.62805L17.9605 7.77203C20.4201 8.32856 21.65 8.60682 21.9426 9.54773C22.2352 10.4886 21.3968 11.4691 19.7199 13.4299L19.2861 13.9372C18.8096 14.4944 18.5713 14.773 18.4641 15.1177C18.357 15.4624 18.393 15.8341 18.465 16.5776L18.5306 17.2544C18.7841 19.8706 18.9109 21.1787 18.1449 21.7602C17.3788 22.3417 16.2273 21.8115 13.9243 20.7512L13.3285 20.4768C12.6741 20.1755 12.3469 20.0248 12 20.0248C11.6531 20.0248 11.3259 20.1755 10.6715 20.4768L10.0757 20.7512C7.77268 21.8115 6.62118 22.3417 5.85515 21.7602C5.08912 21.1787 5.21588 19.8706 5.4694 17.2544L5.53498 16.5776C5.60703 15.8341 5.64305 15.4624 5.53586 15.1177C5.42868 14.773 5.19043 14.4944 4.71392 13.9372L4.2801 13.4299C2.60325 11.4691 1.76482 10.4886 2.05742 9.54773C2.35002 8.60682 3.57986 8.32856 6.03954 7.77203L6.67589 7.62805C7.37485 7.4699 7.72433 7.39083 8.00494 7.17781C8.28555 6.96479 8.46553 6.64194 8.82547 5.99623L9.15316 5.40838Z",stroke:"auto","stroke-width":"1.5"}))}};e.style=r;exports.star_icon=e;
@@ -1,15 +1,16 @@
1
- import { r as e, h as t } from "./index-594c8e7b.js";
1
+ import { r as e, h as t } from "./index-04630615.js";
2
2
  import "react";
3
+ import "react/jsx-runtime";
3
4
  import "react-dom";
4
- const i = ".sc-star-icon-h{display:flex}", o = i, r = class {
5
+ const i = ".sc-star-icon-h{display:flex}", c = i, o = class {
5
6
  constructor(s) {
6
7
  e(this, s), this.width = "15", this.height = "15";
7
8
  }
8
9
  render() {
9
- return t("svg", { key: "0b63c8921b792299288eededbfbbaa36e9223fc0", width: this.width, height: this.height, viewBox: "0 0 24 24", fill: "auto", xmlns: "http://www.w3.org/2000/svg" }, t("path", { key: "460c1c080ff1127ba78c8962a904cb2456a5667e", d: "M9.15316 5.40838C10.4198 3.13613 11.0531 2 12 2C12.9469 2 13.5802 3.13612 14.8468 5.40837L15.1745 5.99623C15.5345 6.64193 15.7144 6.96479 15.9951 7.17781C16.2757 7.39083 16.6251 7.4699 17.3241 7.62805L17.9605 7.77203C20.4201 8.32856 21.65 8.60682 21.9426 9.54773C22.2352 10.4886 21.3968 11.4691 19.7199 13.4299L19.2861 13.9372C18.8096 14.4944 18.5713 14.773 18.4641 15.1177C18.357 15.4624 18.393 15.8341 18.465 16.5776L18.5306 17.2544C18.7841 19.8706 18.9109 21.1787 18.1449 21.7602C17.3788 22.3417 16.2273 21.8115 13.9243 20.7512L13.3285 20.4768C12.6741 20.1755 12.3469 20.0248 12 20.0248C11.6531 20.0248 11.3259 20.1755 10.6715 20.4768L10.0757 20.7512C7.77268 21.8115 6.62118 22.3417 5.85515 21.7602C5.08912 21.1787 5.21588 19.8706 5.4694 17.2544L5.53498 16.5776C5.60703 15.8341 5.64305 15.4624 5.53586 15.1177C5.42868 14.773 5.19043 14.4944 4.71392 13.9372L4.2801 13.4299C2.60325 11.4691 1.76482 10.4886 2.05742 9.54773C2.35002 8.60682 3.57986 8.32856 6.03954 7.77203L6.67589 7.62805C7.37485 7.4699 7.72433 7.39083 8.00494 7.17781C8.28555 6.96479 8.46553 6.64194 8.82547 5.99623L9.15316 5.40838Z", stroke: "auto", "stroke-width": "1.5" }));
10
+ return t("svg", { key: "49798910e83f877f8413abb5c4b11cccacab77eb", width: this.width, height: this.height, viewBox: "0 0 24 24", fill: "auto", xmlns: "http://www.w3.org/2000/svg" }, t("path", { key: "8e0bddce209f480ad0e39574718ccda799f80c70", d: "M9.15316 5.40838C10.4198 3.13613 11.0531 2 12 2C12.9469 2 13.5802 3.13612 14.8468 5.40837L15.1745 5.99623C15.5345 6.64193 15.7144 6.96479 15.9951 7.17781C16.2757 7.39083 16.6251 7.4699 17.3241 7.62805L17.9605 7.77203C20.4201 8.32856 21.65 8.60682 21.9426 9.54773C22.2352 10.4886 21.3968 11.4691 19.7199 13.4299L19.2861 13.9372C18.8096 14.4944 18.5713 14.773 18.4641 15.1177C18.357 15.4624 18.393 15.8341 18.465 16.5776L18.5306 17.2544C18.7841 19.8706 18.9109 21.1787 18.1449 21.7602C17.3788 22.3417 16.2273 21.8115 13.9243 20.7512L13.3285 20.4768C12.6741 20.1755 12.3469 20.0248 12 20.0248C11.6531 20.0248 11.3259 20.1755 10.6715 20.4768L10.0757 20.7512C7.77268 21.8115 6.62118 22.3417 5.85515 21.7602C5.08912 21.1787 5.21588 19.8706 5.4694 17.2544L5.53498 16.5776C5.60703 15.8341 5.64305 15.4624 5.53586 15.1177C5.42868 14.773 5.19043 14.4944 4.71392 13.9372L4.2801 13.4299C2.60325 11.4691 1.76482 10.4886 2.05742 9.54773C2.35002 8.60682 3.57986 8.32856 6.03954 7.77203L6.67589 7.62805C7.37485 7.4699 7.72433 7.39083 8.00494 7.17781C8.28555 6.96479 8.46553 6.64194 8.82547 5.99623L9.15316 5.40838Z", stroke: "auto", "stroke-width": "1.5" }));
10
11
  }
11
12
  };
12
- r.style = o;
13
+ o.style = c;
13
14
  export {
14
- r as star_icon
15
+ o as star_icon
15
16
  };
@@ -0,0 +1,16 @@
1
+ import { r as s, h as t } from "./index-04630615.js";
2
+ import "react";
3
+ import "react/jsx-runtime";
4
+ import "react-dom";
5
+ const e = ".sc-stop-icon-h{display:flex}", i = e, r = class {
6
+ constructor(o) {
7
+ s(this, o), this.width = "15", this.height = "15";
8
+ }
9
+ render() {
10
+ return t("svg", { key: "6979a1534afefd8f03cac18490c593dc6e95327e", width: this.width, height: this.height, viewBox: "0 0 24 24", fill: "auto", xmlns: "http://www.w3.org/2000/svg" }, t("path", { key: "22c22dbe65bb682d0c0c51ef4b9b23b26b29d729", d: "M4 4H20V20H4V4Z", stroke: "auto", "stroke-width": "1.5", "stroke-linecap": "round", "stroke-linejoin": "round" }));
11
+ }
12
+ };
13
+ r.style = i;
14
+ export {
15
+ r as stop_icon
16
+ };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-3d1f13d6.cjs");require("react");require("react/jsx-runtime");require("react-dom");const o=".sc-stop-icon-h{display:flex}",s=o,t=class{constructor(i){e.registerInstance(this,i),this.width="15",this.height="15"}render(){return e.h("svg",{key:"6979a1534afefd8f03cac18490c593dc6e95327e",width:this.width,height:this.height,viewBox:"0 0 24 24",fill:"auto",xmlns:"http://www.w3.org/2000/svg"},e.h("path",{key:"22c22dbe65bb682d0c0c51ef4b9b23b26b29d729",d:"M4 4H20V20H4V4Z",stroke:"auto","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}))}};t.style=s;exports.stop_icon=t;
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-3d1f13d6.cjs");require("react");require("react/jsx-runtime");require("react-dom");const o=':host{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-color-blue-100:#e0e6f9;--nylas-border-radius:0.25rem;--nylas-border-radius-2x:0.5rem;--nylas-border-radius-3x:0.75rem;--nylas-font-family:"Inter", sans-serif;--nylas-color-black:#000000;--nylas-color-grey-900:#2c2c2c;--nylas-color-grey-800:#4b4b4b;--nylas-color-grey-700:#6e6e6e;--nylas-color-grey-600:#8e8e8e;--nylas-color-grey-500:#b3b3b3;--nylas-color-grey-400:#cacaca;--nylas-color-grey-300:#e1e1e1;--nylas-color-grey-200:#eaeaea;--nylas-color-grey-100:#f5f5f5;--nylas-color-grey-50:#fbfcfe;--nylas-color-white:#ffffff;--nylas-color-red-900:#992222;--nylas-color-red-700:#cc4841;--nylas-color-red-500:#ff786a;--nylas-color-red-300:#ffa79e;--nylas-color-red-100:#ffc5bf;--nylas-color-red-50:#ffeae8;--nylas-color-blue-900:#213571;--nylas-color-blue-700:#314fa9;--nylas-color-blue-500:#4169e1;--nylas-color-blue-300:#bdccf9;--nylas-color-blue-100:#e0e6f9;--nylas-color-blue-50:#f6f8fd;--nylas-color-yellow-900:#7c6506;--nylas-color-yellow-700:#c29f09;--nylas-color-yellow-500:#f7c90b;--nylas-color-yellow-300:#f9de70;--nylas-color-yellow-100:#fceba9;--nylas-color-yellow-50:#fdf4ce;--nylas-color-green-900:#0e6b60;--nylas-color-green-700:#16a392;--nylas-color-green-500:#17c3b2;--nylas-color-green-300:#74dbd1;--nylas-color-green-100:#a2e7e0;--nylas-color-green-50:#d1f3f0;--nylas-color-purple-900:#643554;--nylas-color-purple-700:#954f7d;--nylas-color-purple-500:#c769a7;--nylas-color-purple-300:#dda5ca;--nylas-color-purple-100:#e0bdd6;--nylas-color-purple-50:#e9dde5;--nylas-color-sky-900:#20698f;--nylas-color-sky-700:#2b8fc2;--nylas-color-sky-500:#6dceff;--nylas-color-sky-300:#8fdaff;--nylas-color-sky-100:#b8e7ff;--nylas-color-sky-50:#d9f2ff;width:100%}label{display:flex;color:var(--nylas-base-800, #293056);font-size:14px;font-style:normal;font-weight:400;line-height:150%;flex-direction:column;gap:4px;font-family:var(--nylas-font-family);font-size:16px;color:var(--nylas-base-800)}label.error{color:var(--nylas-error)}label span.required{color:var(--nylas-error);padding:0 0.25rem}label p{margin:0;display:flex;gap:4px;align-items:center}label .error{color:var(--nylas-error)}textarea{display:flex;height:48px;padding-left:16px;align-items:center;gap:8px;align-self:stretch;border-radius:var(--nylas-border-radius-2x);border:1px solid var(--nylas-base-300);background:var(--nylas-base-0);width:-webkit-fill-available;color:var(--nylas-base-900);font-size:16px;font-style:normal;font-weight:400;line-height:150%;padding:12px 16px;border-width:1;resize:vertical;border-radius:8px;font-family:var(--nylas-font-family);font-size:16px;line-height:24px}textarea:focus{outline-color:var(--nylas-primary)}textarea.error{border-radius:var(--nylas-border-radius-2x);font-weight:600;border-color:var(--nylas-error);border-width:2px}textarea.error::placeholder{font-weight:400}textarea::placeholder{color:var(--nylas-base-300)}textarea::-webkit-resizer{display:none}textarea:read-only{background-color:var(--nylas-base-100);cursor:not-allowed}',s=o,l=class{constructor(a){e.registerInstance(this,a),this.nylasFormInputChanged=e.createEvent(this,"nylasFormInputChanged",7),this.name="textarea",this.defaultValue=void 0,this.label="",this.placeholder="",this.required=!1,this.readOnly=!1,this.autoFocus=!1,this.maxLength=255,this.type="multi_line_text",this.tooltip="",this.value="",this.error=""}componentDidLoad(){this.value=e.sanitize(this.defaultValue||"")}handleBookingFormSubmitted(a){this.validate(this.value),this.error&&a.preventDefault()}handletriggerValidation(a){this.validate(this.value),this.error&&a.preventDefault()}handleInput(a){this.error="";const r=a.target;this.value=e.sanitize(r.value),this.nylasFormInputChanged.emit({value:this.value,name:this.name,error:this.error,label:this.label,type:this.type})}validate(a){this.required&&!a?this.error=`${this.label} is required.`:a.length>this.maxLength?this.error=`${this.label} cannot exceed ${this.maxLength} characters.`:this.error=""}render(){return e.h("label",{key:"dfa36b319e151ee064e1dce59391cc1be9cd2284",part:"tc__label",class:{error:!!this.error}},e.h("p",{key:"5dfc3110496c05244225cabc70ccca711b4cbb3b"},e.h("span",{key:"87c2996b6a258d78f829fe57bcab0654216ec3b9",class:"label"},this.label),this.required&&e.h("span",{class:"required"},"*"),this.tooltip&&e.h("tooltip-component",null,e.h("info-icon",{slot:"tooltip-icon"}),e.h("span",{slot:"tooltip-content"},this.tooltip))),e.h("textarea",{key:"ed5c0c9044999404daa9282b70e31698a4571463",name:this.name,title:this.readOnly?"read-only field":void 0,placeholder:this.placeholder,readOnly:this.readOnly,autoFocus:this.autoFocus,value:this.value,maxLength:this.maxLength,onInput:a=>this.handleInput(a),class:{error:!!this.error},part:"tc__textarea"}),this.error&&e.h("span",{class:"error help-text"},this.error))}};l.style=s;exports.textarea_component=l;