@nylas/react 1.0.0-prealpha1
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.
- package/LICENSE.md +22 -0
- package/README.md +3 -0
- package/dist/_commonjsHelpers-57e89916-4a3ae7d8.cjs +1 -0
- package/dist/_commonjsHelpers-57e89916-af061c86.js +19 -0
- package/dist/archive-icon_7.entry-53aede1b.js +75 -0
- package/dist/archive-icon_7.entry-8c90815a.cjs +1 -0
- package/dist/arrow-icon.entry-2867f4fb.js +15 -0
- package/dist/arrow-icon.entry-a2f53919.cjs +1 -0
- package/dist/bold-icon_3.entry-ad806730.js +35 -0
- package/dist/bold-icon_3.entry-e0bc6774.cjs +1 -0
- package/dist/calendar-cancel-icon.entry-546b7bd4.cjs +1 -0
- package/dist/calendar-cancel-icon.entry-74051835.js +15 -0
- package/dist/calendar-check-icon_3.entry-42bab0b4.js +35 -0
- package/dist/calendar-check-icon_3.entry-f5846fee.cjs +1 -0
- package/dist/calendar-icon.entry-25474b1e.cjs +1 -0
- package/dist/calendar-icon.entry-c751873f.js +15 -0
- package/dist/chevron-icon.entry-60842fb6.js +15 -0
- package/dist/chevron-icon.entry-97e4621e.cjs +1 -0
- package/dist/close-icon_2.entry-aa015993.cjs +1 -0
- package/dist/close-icon_2.entry-ef03bd27.js +25 -0
- package/dist/core-js-38e53e34.cjs +4 -0
- package/dist/core-js-a9d3b6e1.js +3297 -0
- package/dist/document-refresh-icon.entry-b27207eb.js +15 -0
- package/dist/document-refresh-icon.entry-ca2ef29e.cjs +1 -0
- package/dist/dom-68f08be9.cjs +15 -0
- package/dist/dom-86e17616.js +664 -0
- package/dist/duration-bddc4a13-05d3e3e2.cjs +1 -0
- package/dist/duration-bddc4a13-179ce826.js +41 -0
- package/dist/elements/index.d.ts +56 -0
- package/dist/elements/react-component-lib/createComponent.d.ts +10 -0
- package/dist/elements/react-component-lib/createOverlayComponent.d.ts +21 -0
- package/dist/elements/react-component-lib/index.d.ts +2 -0
- package/dist/elements/react-component-lib/interfaces.d.ts +29 -0
- package/dist/elements/react-component-lib/utils/attachProps.d.ts +9 -0
- package/dist/elements/react-component-lib/utils/case.d.ts +2 -0
- package/dist/elements/react-component-lib/utils/dev.d.ts +2 -0
- package/dist/elements/react-component-lib/utils/index.d.ts +10 -0
- package/dist/elements-60ebdb01-24595598.cjs +16494 -0
- package/dist/elements-60ebdb01-5d144002.js +27455 -0
- package/dist/flow-40ff9cea-6f8c30e2.cjs +9 -0
- package/dist/flow-40ff9cea-ee70fdf5.js +505 -0
- package/dist/focus-visible-e8093c16-28fc08a0.js +82 -0
- package/dist/focus-visible-e8093c16-f380b705.cjs +1 -0
- package/dist/forward-icon_6.entry-725d1be4.cjs +3 -0
- package/dist/forward-icon_6.entry-dc8f7235.js +955 -0
- package/dist/globe-icon.entry-796d3f48.js +15 -0
- package/dist/globe-icon.entry-918cfd35.cjs +1 -0
- package/dist/index-29d0e781.cjs +30 -0
- package/dist/index-2b85580a-bfc3ceac.cjs +7 -0
- package/dist/index-2b85580a-f9211f23.js +3238 -0
- package/dist/index-4f65b6f9.js +1489 -0
- package/dist/index.d.ts +4 -0
- package/dist/loading-icon.entry-8e49fab0.js +15 -0
- package/dist/loading-icon.entry-b2534e3e.cjs +1 -0
- package/dist/mailbox-store-0019772c-06d31a90.js +380 -0
- package/dist/mailbox-store-0019772c-d1254c5c.cjs +1 -0
- package/dist/nylas-booked-event-card_9.entry-d995d7cb.js +4567 -0
- package/dist/nylas-booked-event-card_9.entry-ea02f083.cjs +148 -0
- package/dist/nylas-if-state_3.entry-ce816adb.js +291 -0
- package/dist/nylas-if-state_3.entry-e8c831b7.cjs +1 -0
- package/dist/nylas-list-folders.entry-8134344b.js +121 -0
- package/dist/nylas-list-folders.entry-de8cca60.cjs +1 -0
- package/dist/nylas-list-threads.entry-1367fe30.js +71 -0
- package/dist/nylas-list-threads.entry-93b70a1a.cjs +1 -0
- package/dist/nylas-mailbox-pagination.entry-568ac217.js +102 -0
- package/dist/nylas-mailbox-pagination.entry-6bb0ee37.cjs +1 -0
- package/dist/nylas-mailbox-toolbar-button.entry-9214b283.js +83 -0
- package/dist/nylas-mailbox-toolbar-button.entry-d4ad5c15.cjs +1 -0
- package/dist/nylas-open-hours-picker.entry-109f13f5.js +186 -0
- package/dist/nylas-open-hours-picker.entry-2c19643f.cjs +1 -0
- package/dist/nylas-provider.entry-2cfe5f0e.js +134 -0
- package/dist/nylas-provider.entry-87fa9276.cjs +1 -0
- package/dist/nylas-scheduler.entry-6ec8e574.js +195 -0
- package/dist/nylas-scheduler.entry-b41cbf99.cjs +1 -0
- package/dist/nylas-threads-refresh.entry-6d61a689.cjs +1 -0
- package/dist/nylas-threads-refresh.entry-9111a403.js +75 -0
- package/dist/nylas-threads-search.entry-03073490.cjs +1 -0
- package/dist/nylas-threads-search.entry-2124f663.js +70 -0
- package/dist/nylas-view-thread.entry-4ecbcd78.cjs +1 -0
- package/dist/nylas-view-thread.entry-fe51c1f6.js +204 -0
- package/dist/play-icon_2.entry-8e156535.js +25 -0
- package/dist/play-icon_2.entry-cf1cbc8d.cjs +1 -0
- package/dist/property-0065dde7-83dc9cc4.cjs +23 -0
- package/dist/property-0065dde7-c57b8fa3.js +589 -0
- package/dist/react.cjs +1 -0
- package/dist/react.js +62 -0
- package/dist/refresh-icon.entry-4ddd53b0.js +15 -0
- package/dist/refresh-icon.entry-9f24e833.cjs +1 -0
- package/dist/register-component-55376f31-5eaf8954.js +105 -0
- package/dist/register-component-55376f31-8d6ddee4.cjs +1 -0
- package/dist/scheduler-store-5a39585a-117668e3.js +173 -0
- package/dist/scheduler-store-5a39585a-2c848bec.cjs +1 -0
- package/dist/translate-icon.entry-0cd24de4.cjs +1 -0
- package/dist/translate-icon.entry-db2cdf1d.js +15 -0
- package/dist/utils-5074a070-ce33ee6b.js +119 -0
- package/dist/utils-5074a070-d5ba6add.cjs +2 -0
- package/package.json +47 -0
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
import { r as y, c as p, h as n, H as d, g as v, F as _ } from "./index-4f65b6f9.js";
|
|
2
|
+
import { n as m, N as k } from "./index-2b85580a-f9211f23.js";
|
|
3
|
+
import { d as g } from "./utils-5074a070-ce33ee6b.js";
|
|
4
|
+
import { C as w, N as S } from "./scheduler-store-5a39585a-117668e3.js";
|
|
5
|
+
import "react";
|
|
6
|
+
import "react-dom";
|
|
7
|
+
class x {
|
|
8
|
+
constructor({ schedulerAPIURL: e, nylasSchedulerStore: s, sessionId: i }) {
|
|
9
|
+
if (!e)
|
|
10
|
+
throw new Error("schedulerAPIURL is required");
|
|
11
|
+
if (!s)
|
|
12
|
+
throw new Error("nylasSchedulerStore is required");
|
|
13
|
+
if (!i)
|
|
14
|
+
throw new Error("sessionId is required");
|
|
15
|
+
e === "/" && (e = new URL(window.location.href).origin), this.sessionId = i, this.schedulerAPIURL = e, this.nylasSchedulerStore = s;
|
|
16
|
+
}
|
|
17
|
+
init() {
|
|
18
|
+
g("NylasConnector init");
|
|
19
|
+
}
|
|
20
|
+
get schedulerStore() {
|
|
21
|
+
return this.nylasSchedulerStore;
|
|
22
|
+
}
|
|
23
|
+
get scheduler() {
|
|
24
|
+
return this._schedulerAPIConnector ? this._schedulerAPIConnector : (this._schedulerAPIConnector = new S({
|
|
25
|
+
schedulerAPIURL: this.schedulerAPIURL,
|
|
26
|
+
schedulerStore: this.schedulerStore,
|
|
27
|
+
sessionId: this.sessionId
|
|
28
|
+
}), this._schedulerAPIConnector);
|
|
29
|
+
}
|
|
30
|
+
resetStores() {
|
|
31
|
+
this.nylasSchedulerStore.reset();
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
const c = (t, e) => {
|
|
35
|
+
const s = t.loadingState && !!t.loadingState.api;
|
|
36
|
+
return n(
|
|
37
|
+
_,
|
|
38
|
+
null,
|
|
39
|
+
s && n(
|
|
40
|
+
"div",
|
|
41
|
+
{ class: "loading" },
|
|
42
|
+
n(
|
|
43
|
+
"div",
|
|
44
|
+
{ class: "left" },
|
|
45
|
+
n("div", { class: "skeleton" })
|
|
46
|
+
),
|
|
47
|
+
n(
|
|
48
|
+
"div",
|
|
49
|
+
{ class: "right" },
|
|
50
|
+
n("div", { class: "skeleton" }),
|
|
51
|
+
n("div", { class: "skeleton" }),
|
|
52
|
+
n("div", { class: "skeleton" }),
|
|
53
|
+
n("div", { class: "skeleton" }),
|
|
54
|
+
n("div", { class: "skeleton" })
|
|
55
|
+
)
|
|
56
|
+
),
|
|
57
|
+
!s && e,
|
|
58
|
+
n("nylas-notification", null),
|
|
59
|
+
n(
|
|
60
|
+
"div",
|
|
61
|
+
{ class: "footer" },
|
|
62
|
+
"Powered by ",
|
|
63
|
+
n("nylas-logo", null)
|
|
64
|
+
)
|
|
65
|
+
);
|
|
66
|
+
}, C = ":host{display:flex;flex-direction:column;overflow:visible;border-radius:var(--nylas-border-radius-2x);box-shadow:0px 4px 6px -2px rgba(0, 0, 0, 0.05), 0px 10px 15px -3px rgba(0, 0, 0, 0.1);--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;background:var(--nylas-base-0);position:relative}.error{padding:8rem 12rem;color:var(--nylas-base-0);background-color:var(--nylas-error);margin:1.5rem;border-radius:var(--nylas-border-radius-2x)}.loading{margin:1.5rem;display:flex;gap:1rem}.loading .skeleton{border-radius:var(--nylas-border-radius-2x);animation:pulsate 1.5s infinite}.loading .skeleton:nth-child(2){animation-delay:-100ms}.loading .skeleton:nth-child(3){animation-delay:-200ms}.loading .skeleton:nth-child(4){animation-delay:-300ms}.loading .skeleton:nth-child(5){animation-delay:-400ms}.loading .left .skeleton{height:100%;width:400px}.loading .right .skeleton{height:5rem;width:300px;margin-bottom:1rem}.loading .right .skeleton:last-child{margin-bottom:0}@keyframes pulsate{0%{background-color:var(--nylas-base-50)}50%{background-color:var(--nylas-base-100)}100%{background-color:var(--nylas-base-50)}}.select-date-page,.additional-data-page{display:flex}.additional-data-page{background-color:var(--nylas-base-50)}.booked-event-page{background-color:var(--nylas-base-50)}.cancelled-event-page{padding:1rem;height:496px;display:flex;justify-content:center;align-items:center}.booked-event-page,.cancelled-event-page{min-width:784px}.left-panel{padding-left:1.5rem;padding-right:1.5rem;padding-top:1rem;gap:1rem;border-right-width:1px;height:500px;min-width:384px}.border{margin-left:-1.5rem;margin-right:-1.5rem;border-top-width:1px;height:1px;background-color:var(--nylas-base-200)}.right-panel{display:flex;overflow:hidden;flex-direction:column;justify-content:flex-start;align-items:center;min-width:360px;background-color:var(--nylas-base-50)}.right-panel .wrapper{width:100%}.right-panel .wrapper h2{display:flex;margin-bottom:1rem;margin-top:1.5rem;gap:0.25rem;justify-content:center;align-items:center;width:100%;font-size:1.125rem;line-height:1.75rem;font-weight:600;text-align:center;width:100%}nylas-selected-event-card,nylas-booking-form{height:496px}.footer{display:flex;justify-content:flex-end;align-items:center;padding:16px;font-size:14px;font-weight:300;color:var(--nylas-base-500);border-top:1px solid var(--nylas-base-100)}.footer svg{fill:var(--nylas-base-500)}.footer svg{margin-top:1px}nylas-selected-event-card::part(nsec__timezone){position:absolute;bottom:0}", I = C, b = { title: "Something went wrong...", type: m.Error, category: "internal" }, D = class {
|
|
67
|
+
constructor(t) {
|
|
68
|
+
y(this, t), this.init = p(this, "init", 7), this.nylasSchedulerError = p(this, "nylasSchedulerError", 7), this.mode = "app", this.defaultSchedulerStoreState = void 0, this.sessionId = void 0, this.schedulerApiUrl = "https://elements-staging.us.nylas.com", this.bookingInfo = void 0, this.rescheduleId = void 0, this.eventOverrides = {}, this.loadingState = void 0, this.themeConfig = void 0, this.automaticComponentRegistration = !0, this.selectedDateLabel = (/* @__PURE__ */ new Date()).toLocaleDateString(void 0, { dateStyle: "full" }) || "No date selected";
|
|
69
|
+
}
|
|
70
|
+
connectedCallback() {
|
|
71
|
+
g("[nylas-scheduler] connectedCallback");
|
|
72
|
+
}
|
|
73
|
+
async componentWillLoad() {
|
|
74
|
+
var e, s;
|
|
75
|
+
if (g("[nylas-scheduler] Component will load", { eventOverrides: this.eventOverrides }), !this.sessionId)
|
|
76
|
+
throw new Error("The page slug or session Id is required");
|
|
77
|
+
this.stores = {
|
|
78
|
+
scheduler: w({
|
|
79
|
+
bookingInfo: this.bookingInfo,
|
|
80
|
+
...this.defaultSchedulerStoreState
|
|
81
|
+
})
|
|
82
|
+
}, this.baseProvider = new k(this.host, this.stores, this.automaticComponentRegistration, this.eventOverrides);
|
|
83
|
+
const t = (e = this.baseProvider) == null ? void 0 : e.getStore("scheduler");
|
|
84
|
+
if (this.nylasSchedulerConnector = new x({
|
|
85
|
+
schedulerAPIURL: this.schedulerApiUrl,
|
|
86
|
+
sessionId: this.sessionId,
|
|
87
|
+
nylasSchedulerStore: t
|
|
88
|
+
}), this.init.emit(this.host), (s = this.baseProvider) == null || s.componentWillLoad(this.nylasSchedulerConnector), this.themeConfig)
|
|
89
|
+
for (const [i, a] of Object.entries(this.themeConfig))
|
|
90
|
+
this.host.style.setProperty(`${i}`, a);
|
|
91
|
+
}
|
|
92
|
+
async componentDidLoad() {
|
|
93
|
+
var o, r, l, u;
|
|
94
|
+
(o = this.baseProvider) == null || o.componentDidLoad();
|
|
95
|
+
let t;
|
|
96
|
+
const e = (r = this.baseProvider) == null ? void 0 : r.getStore("scheduler"), s = e == null ? void 0 : e.get("selectedDate");
|
|
97
|
+
if (!s)
|
|
98
|
+
t = await ((l = this.nylasSchedulerConnector) == null ? void 0 : l.scheduler.getAvailability());
|
|
99
|
+
else {
|
|
100
|
+
const h = new Date(s.getFullYear(), s.getMonth(), 1).getTime() / 1e3, f = new Date(s.getFullYear(), s.getMonth() + 1, 1).getTime() / 1e3;
|
|
101
|
+
t = await ((u = this.nylasSchedulerConnector) == null ? void 0 : u.scheduler.getAvailability(h, f));
|
|
102
|
+
}
|
|
103
|
+
(!t || "error" in t) && this.nylasSchedulerError.emit({ ...this.getErrorObject(t == null ? void 0 : t.error) });
|
|
104
|
+
const i = e == null ? void 0 : e.get("availability").find((h) => new Date(h.start_time) > /* @__PURE__ */ new Date());
|
|
105
|
+
let a = /* @__PURE__ */ new Date();
|
|
106
|
+
i && (a = i.start_time), e == null || e.set("selectedDate", a), this.selectedDateLabel = a.toLocaleDateString(void 0, { dateStyle: "full" }) || "No date selected";
|
|
107
|
+
}
|
|
108
|
+
componentDisconnected() {
|
|
109
|
+
var t;
|
|
110
|
+
(t = this.baseProvider) == null || t.componentDisconnected();
|
|
111
|
+
}
|
|
112
|
+
bookingInfoChanged(t) {
|
|
113
|
+
var e;
|
|
114
|
+
(e = this.stores) == null || e.scheduler.set("bookingInfo", t);
|
|
115
|
+
}
|
|
116
|
+
async registerComponentHandler(t) {
|
|
117
|
+
var e;
|
|
118
|
+
(e = this.baseProvider) == null || e.registerComponent(t.detail);
|
|
119
|
+
}
|
|
120
|
+
async unregisterComponentHandler(t) {
|
|
121
|
+
var e;
|
|
122
|
+
(e = this.baseProvider) == null || e.unregisterComponent(t.detail);
|
|
123
|
+
}
|
|
124
|
+
async monthChangedHandler(t) {
|
|
125
|
+
var o;
|
|
126
|
+
const e = t.detail, s = new Date(e.getFullYear(), e.getMonth(), 1).getTime() / 1e3, i = new Date(e.getFullYear(), e.getMonth() + 1, 1).getTime() / 1e3, a = await ((o = this.nylasSchedulerConnector) == null ? void 0 : o.scheduler.getAvailability(s, i));
|
|
127
|
+
(!a || "error" in a) && this.nylasSchedulerError.emit({ ...this.getErrorObject(a == null ? void 0 : a.error) });
|
|
128
|
+
}
|
|
129
|
+
async bookButtonClickedHandler(t) {
|
|
130
|
+
var s, i, a, o;
|
|
131
|
+
if (this.rescheduleId) {
|
|
132
|
+
const r = await ((s = this.nylasSchedulerConnector) == null ? void 0 : s.scheduler.rescheduleBooking(this.rescheduleId, t.detail));
|
|
133
|
+
!r || "error" in r ? this.nylasSchedulerError.emit({ ...this.getErrorObject(r == null ? void 0 : r.error) }) : (i = this.baseProvider) == null || i.getStore("scheduler").set("showThankYouMessage", !0);
|
|
134
|
+
return;
|
|
135
|
+
}
|
|
136
|
+
const e = await ((a = this.nylasSchedulerConnector) == null ? void 0 : a.scheduler.bookTimeslot(t.detail));
|
|
137
|
+
!e || "error" in e ? this.nylasSchedulerError.emit({ ...this.getErrorObject(e == null ? void 0 : e.error) }) : (o = this.baseProvider) == null || o.getStore("scheduler").set("showThankYouMessage", !0);
|
|
138
|
+
}
|
|
139
|
+
async cancelButtonClickedHandler() {
|
|
140
|
+
var t, e;
|
|
141
|
+
(t = this.baseProvider) == null || t.getStore("scheduler").set("bookedEventLoading", !1), (e = this.baseProvider) == null || e.getStore("scheduler").set("bookedEventError", null);
|
|
142
|
+
}
|
|
143
|
+
selectedDateChanged(t) {
|
|
144
|
+
const e = t.detail;
|
|
145
|
+
this.selectedDateLabel = e ? e.toLocaleDateString(void 0, { dateStyle: "full" }) : "No date selected";
|
|
146
|
+
}
|
|
147
|
+
async getNylasSchedulerStore() {
|
|
148
|
+
var t;
|
|
149
|
+
return (t = this.baseProvider) == null ? void 0 : t.getStore("scheduler");
|
|
150
|
+
}
|
|
151
|
+
async getNylasSchedulerConnector() {
|
|
152
|
+
return this.nylasSchedulerConnector;
|
|
153
|
+
}
|
|
154
|
+
async getRef() {
|
|
155
|
+
return this.host;
|
|
156
|
+
}
|
|
157
|
+
getErrorObject(t) {
|
|
158
|
+
return {
|
|
159
|
+
title: (t == null ? void 0 : t.title) || b.title,
|
|
160
|
+
category: (t == null ? void 0 : t.type) || b.category,
|
|
161
|
+
type: m.Error,
|
|
162
|
+
description: (t == null ? void 0 : t.message) || "",
|
|
163
|
+
id: (/* @__PURE__ */ new Date()).getTime().toString()
|
|
164
|
+
};
|
|
165
|
+
}
|
|
166
|
+
render() {
|
|
167
|
+
var r;
|
|
168
|
+
const t = this.mode === "app", e = (r = this.baseProvider) == null ? void 0 : r.getStore("scheduler"), s = e == null ? void 0 : e.get("eventInfo"), i = e == null ? void 0 : e.get("showThankYouMessage"), a = e == null ? void 0 : e.get("showBookingForm"), o = e == null ? void 0 : e.get("cancelledEvent");
|
|
169
|
+
if (t && o)
|
|
170
|
+
return n(d, null, n(c, { loadingState: this.loadingState }, n("div", { class: "cancelled-event-page", part: "cancelled-event-page" }, n("nylas-cancelled-event-card", { cancelledEvent: o, exportparts: "ncec, ncec__icon, ncec__title, ncec__description, ncec__button-outline, ncec__card" }))));
|
|
171
|
+
if (t && i && s)
|
|
172
|
+
return n(d, null, n(c, { loadingState: this.loadingState }, n("div", { class: "booked-event-page", part: "booked-event-page" }, n("nylas-booked-event-card", { eventInfo: s, exportparts: "nbec, nbec__title, nbec__card, nbec__description, nbec__button-outline, nbec__cancel-cta, nbec__reschedule-cta" }))));
|
|
173
|
+
if (t && !i && !a) {
|
|
174
|
+
const l = this.host.querySelector('[slot="timeslot-picker-cta-label"]');
|
|
175
|
+
return n(d, null, n(c, { loadingState: this.loadingState }, n("div", { class: "select-date-page", part: "select-date-page" }, n("div", { class: "left-panel" }, n("nylas-date-picker", { exportparts: "ndp, ndp__month-header, ndp__month-button, ndp__day, ndp__date, ndp__date--selected, ndp__date--current-day, ndp__date--current-month" }), n("div", { class: "border" }), n("nylas-locale-switch", null)), n("div", { class: "right-panel" }, n("div", { class: "wrapper" }, n("h2", null, n("calendar-icon", null), n("span", { id: "selectedDate" }, this.selectedDateLabel)), n("nylas-timeslot-picker", { exportparts: "ntp, ntp__timeslot, ntp__timeslot--selected, ntp__button-primary" }, l && n("span", { slot: "timeslot-picker-cta-label" }, n("slot", { name: "timeslot-picker-cta-label" }))))))));
|
|
176
|
+
}
|
|
177
|
+
if (t && !i && a) {
|
|
178
|
+
const l = this.host.querySelector('[slot="custom-booking-form"]');
|
|
179
|
+
return n(d, null, n(c, { loadingState: this.loadingState }, n("div", { class: "additional-data-page", part: "additional-data-page" }, n("div", { class: "left-panel" }, n("div", { class: "wrapper" }, n("nylas-selected-event-card", { exportparts: "nsec, nsec__card, nsec__icon, nsec__date, nsec__time" }))), n("div", { class: "right-panel" }, n("div", { class: "wrapper" }, n("nylas-booking-form", { exportparts: "nbf, nbf__input-label, nbf__input-textfield, nbf__button-ghost, nbf__button-primary, nbf__button-outline" }, l && n("div", { slot: "custom-booking-form" }, n("slot", { name: "custom-booking-form" }))))))));
|
|
180
|
+
}
|
|
181
|
+
return n(d, null, n("slot", null));
|
|
182
|
+
}
|
|
183
|
+
get host() {
|
|
184
|
+
return v(this);
|
|
185
|
+
}
|
|
186
|
+
static get watchers() {
|
|
187
|
+
return {
|
|
188
|
+
bookingInfo: ["bookingInfoChanged"]
|
|
189
|
+
};
|
|
190
|
+
}
|
|
191
|
+
};
|
|
192
|
+
D.style = I;
|
|
193
|
+
export {
|
|
194
|
+
D as nylas_scheduler
|
|
195
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-29d0e781.cjs"),h=require("./index-2b85580a-bfc3ceac.cjs"),g=require("./utils-5074a070-d5ba6add.cjs"),b=require("./scheduler-store-5a39585a-2c848bec.cjs");require("react");require("react-dom");class f{constructor({schedulerAPIURL:t,nylasSchedulerStore:s,sessionId:i}){if(!t)throw new Error("schedulerAPIURL is required");if(!s)throw new Error("nylasSchedulerStore is required");if(!i)throw new Error("sessionId is required");t==="/"&&(t=new URL(window.location.href).origin),this.sessionId=i,this.schedulerAPIURL=t,this.nylasSchedulerStore=s}init(){g.debug("NylasConnector init")}get schedulerStore(){return this.nylasSchedulerStore}get scheduler(){return this._schedulerAPIConnector?this._schedulerAPIConnector:(this._schedulerAPIConnector=new b.NylaSchedulerAPIConnector({schedulerAPIURL:this.schedulerAPIURL,schedulerStore:this.schedulerStore,sessionId:this.sessionId}),this._schedulerAPIConnector)}resetStores(){this.nylasSchedulerStore.reset()}}const d=(n,t)=>{const s=n.loadingState&&!!n.loadingState.api;return e.h(e.Fragment,null,s&&e.h("div",{class:"loading"},e.h("div",{class:"left"},e.h("div",{class:"skeleton"})),e.h("div",{class:"right"},e.h("div",{class:"skeleton"}),e.h("div",{class:"skeleton"}),e.h("div",{class:"skeleton"}),e.h("div",{class:"skeleton"}),e.h("div",{class:"skeleton"}))),!s&&t,e.h("nylas-notification",null),e.h("div",{class:"footer"},"Powered by ",e.h("nylas-logo",null)))},v=":host{display:flex;flex-direction:column;overflow:visible;border-radius:var(--nylas-border-radius-2x);box-shadow:0px 4px 6px -2px rgba(0, 0, 0, 0.05), 0px 10px 15px -3px rgba(0, 0, 0, 0.1);--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;background:var(--nylas-base-0);position:relative}.error{padding:8rem 12rem;color:var(--nylas-base-0);background-color:var(--nylas-error);margin:1.5rem;border-radius:var(--nylas-border-radius-2x)}.loading{margin:1.5rem;display:flex;gap:1rem}.loading .skeleton{border-radius:var(--nylas-border-radius-2x);animation:pulsate 1.5s infinite}.loading .skeleton:nth-child(2){animation-delay:-100ms}.loading .skeleton:nth-child(3){animation-delay:-200ms}.loading .skeleton:nth-child(4){animation-delay:-300ms}.loading .skeleton:nth-child(5){animation-delay:-400ms}.loading .left .skeleton{height:100%;width:400px}.loading .right .skeleton{height:5rem;width:300px;margin-bottom:1rem}.loading .right .skeleton:last-child{margin-bottom:0}@keyframes pulsate{0%{background-color:var(--nylas-base-50)}50%{background-color:var(--nylas-base-100)}100%{background-color:var(--nylas-base-50)}}.select-date-page,.additional-data-page{display:flex}.additional-data-page{background-color:var(--nylas-base-50)}.booked-event-page{background-color:var(--nylas-base-50)}.cancelled-event-page{padding:1rem;height:496px;display:flex;justify-content:center;align-items:center}.booked-event-page,.cancelled-event-page{min-width:784px}.left-panel{padding-left:1.5rem;padding-right:1.5rem;padding-top:1rem;gap:1rem;border-right-width:1px;height:500px;min-width:384px}.border{margin-left:-1.5rem;margin-right:-1.5rem;border-top-width:1px;height:1px;background-color:var(--nylas-base-200)}.right-panel{display:flex;overflow:hidden;flex-direction:column;justify-content:flex-start;align-items:center;min-width:360px;background-color:var(--nylas-base-50)}.right-panel .wrapper{width:100%}.right-panel .wrapper h2{display:flex;margin-bottom:1rem;margin-top:1.5rem;gap:0.25rem;justify-content:center;align-items:center;width:100%;font-size:1.125rem;line-height:1.75rem;font-weight:600;text-align:center;width:100%}nylas-selected-event-card,nylas-booking-form{height:496px}.footer{display:flex;justify-content:flex-end;align-items:center;padding:16px;font-size:14px;font-weight:300;color:var(--nylas-base-500);border-top:1px solid var(--nylas-base-100)}.footer svg{fill:var(--nylas-base-500)}.footer svg{margin-top:1px}nylas-selected-event-card::part(nsec__timezone){position:absolute;bottom:0}",_=v,p={title:"Something went wrong...",type:h.nr.Error,category:"internal"},m=class{constructor(n){e.registerInstance(this,n),this.init=e.createEvent(this,"init",7),this.nylasSchedulerError=e.createEvent(this,"nylasSchedulerError",7),this.mode="app",this.defaultSchedulerStoreState=void 0,this.sessionId=void 0,this.schedulerApiUrl="https://elements-staging.us.nylas.com",this.bookingInfo=void 0,this.rescheduleId=void 0,this.eventOverrides={},this.loadingState=void 0,this.themeConfig=void 0,this.automaticComponentRegistration=!0,this.selectedDateLabel=new Date().toLocaleDateString(void 0,{dateStyle:"full"})||"No date selected"}connectedCallback(){g.debug("[nylas-scheduler] connectedCallback")}async componentWillLoad(){var t,s;if(g.debug("[nylas-scheduler] Component will load",{eventOverrides:this.eventOverrides}),!this.sessionId)throw new Error("The page slug or session Id is required");this.stores={scheduler:b.CreateNylasSchedulerStore({bookingInfo:this.bookingInfo,...this.defaultSchedulerStoreState})},this.baseProvider=new h.NylasBaseProvider(this.host,this.stores,this.automaticComponentRegistration,this.eventOverrides);const n=(t=this.baseProvider)==null?void 0:t.getStore("scheduler");if(this.nylasSchedulerConnector=new f({schedulerAPIURL:this.schedulerApiUrl,sessionId:this.sessionId,nylasSchedulerStore:n}),this.init.emit(this.host),(s=this.baseProvider)==null||s.componentWillLoad(this.nylasSchedulerConnector),this.themeConfig)for(const[i,a]of Object.entries(this.themeConfig))this.host.style.setProperty(`${i}`,a)}async componentDidLoad(){var r,o,l,u;(r=this.baseProvider)==null||r.componentDidLoad();let n;const t=(o=this.baseProvider)==null?void 0:o.getStore("scheduler"),s=t==null?void 0:t.get("selectedDate");if(!s)n=await((l=this.nylasSchedulerConnector)==null?void 0:l.scheduler.getAvailability());else{const c=new Date(s.getFullYear(),s.getMonth(),1).getTime()/1e3,y=new Date(s.getFullYear(),s.getMonth()+1,1).getTime()/1e3;n=await((u=this.nylasSchedulerConnector)==null?void 0:u.scheduler.getAvailability(c,y))}(!n||"error"in n)&&this.nylasSchedulerError.emit({...this.getErrorObject(n==null?void 0:n.error)});const i=t==null?void 0:t.get("availability").find(c=>new Date(c.start_time)>new Date);let a=new Date;i&&(a=i.start_time),t==null||t.set("selectedDate",a),this.selectedDateLabel=a.toLocaleDateString(void 0,{dateStyle:"full"})||"No date selected"}componentDisconnected(){var n;(n=this.baseProvider)==null||n.componentDisconnected()}bookingInfoChanged(n){var t;(t=this.stores)==null||t.scheduler.set("bookingInfo",n)}async registerComponentHandler(n){var t;(t=this.baseProvider)==null||t.registerComponent(n.detail)}async unregisterComponentHandler(n){var t;(t=this.baseProvider)==null||t.unregisterComponent(n.detail)}async monthChangedHandler(n){var r;const t=n.detail,s=new Date(t.getFullYear(),t.getMonth(),1).getTime()/1e3,i=new Date(t.getFullYear(),t.getMonth()+1,1).getTime()/1e3,a=await((r=this.nylasSchedulerConnector)==null?void 0:r.scheduler.getAvailability(s,i));(!a||"error"in a)&&this.nylasSchedulerError.emit({...this.getErrorObject(a==null?void 0:a.error)})}async bookButtonClickedHandler(n){var s,i,a,r;if(this.rescheduleId){const o=await((s=this.nylasSchedulerConnector)==null?void 0:s.scheduler.rescheduleBooking(this.rescheduleId,n.detail));!o||"error"in o?this.nylasSchedulerError.emit({...this.getErrorObject(o==null?void 0:o.error)}):(i=this.baseProvider)==null||i.getStore("scheduler").set("showThankYouMessage",!0);return}const t=await((a=this.nylasSchedulerConnector)==null?void 0:a.scheduler.bookTimeslot(n.detail));!t||"error"in t?this.nylasSchedulerError.emit({...this.getErrorObject(t==null?void 0:t.error)}):(r=this.baseProvider)==null||r.getStore("scheduler").set("showThankYouMessage",!0)}async cancelButtonClickedHandler(){var n,t;(n=this.baseProvider)==null||n.getStore("scheduler").set("bookedEventLoading",!1),(t=this.baseProvider)==null||t.getStore("scheduler").set("bookedEventError",null)}selectedDateChanged(n){const t=n.detail;this.selectedDateLabel=t?t.toLocaleDateString(void 0,{dateStyle:"full"}):"No date selected"}async getNylasSchedulerStore(){var n;return(n=this.baseProvider)==null?void 0:n.getStore("scheduler")}async getNylasSchedulerConnector(){return this.nylasSchedulerConnector}async getRef(){return this.host}getErrorObject(n){return{title:(n==null?void 0:n.title)||p.title,category:(n==null?void 0:n.type)||p.category,type:h.nr.Error,description:(n==null?void 0:n.message)||"",id:new Date().getTime().toString()}}render(){var o;const n=this.mode==="app",t=(o=this.baseProvider)==null?void 0:o.getStore("scheduler"),s=t==null?void 0:t.get("eventInfo"),i=t==null?void 0:t.get("showThankYouMessage"),a=t==null?void 0:t.get("showBookingForm"),r=t==null?void 0:t.get("cancelledEvent");if(n&&r)return e.h(e.Host,null,e.h(d,{loadingState:this.loadingState},e.h("div",{class:"cancelled-event-page",part:"cancelled-event-page"},e.h("nylas-cancelled-event-card",{cancelledEvent:r,exportparts:"ncec, ncec__icon, ncec__title, ncec__description, ncec__button-outline, ncec__card"}))));if(n&&i&&s)return e.h(e.Host,null,e.h(d,{loadingState:this.loadingState},e.h("div",{class:"booked-event-page",part:"booked-event-page"},e.h("nylas-booked-event-card",{eventInfo:s,exportparts:"nbec, nbec__title, nbec__card, nbec__description, nbec__button-outline, nbec__cancel-cta, nbec__reschedule-cta"}))));if(n&&!i&&!a){const l=this.host.querySelector('[slot="timeslot-picker-cta-label"]');return e.h(e.Host,null,e.h(d,{loadingState:this.loadingState},e.h("div",{class:"select-date-page",part:"select-date-page"},e.h("div",{class:"left-panel"},e.h("nylas-date-picker",{exportparts:"ndp, ndp__month-header, ndp__month-button, ndp__day, ndp__date, ndp__date--selected, ndp__date--current-day, ndp__date--current-month"}),e.h("div",{class:"border"}),e.h("nylas-locale-switch",null)),e.h("div",{class:"right-panel"},e.h("div",{class:"wrapper"},e.h("h2",null,e.h("calendar-icon",null),e.h("span",{id:"selectedDate"},this.selectedDateLabel)),e.h("nylas-timeslot-picker",{exportparts:"ntp, ntp__timeslot, ntp__timeslot--selected, ntp__button-primary"},l&&e.h("span",{slot:"timeslot-picker-cta-label"},e.h("slot",{name:"timeslot-picker-cta-label"}))))))))}if(n&&!i&&a){const l=this.host.querySelector('[slot="custom-booking-form"]');return e.h(e.Host,null,e.h(d,{loadingState:this.loadingState},e.h("div",{class:"additional-data-page",part:"additional-data-page"},e.h("div",{class:"left-panel"},e.h("div",{class:"wrapper"},e.h("nylas-selected-event-card",{exportparts:"nsec, nsec__card, nsec__icon, nsec__date, nsec__time"}))),e.h("div",{class:"right-panel"},e.h("div",{class:"wrapper"},e.h("nylas-booking-form",{exportparts:"nbf, nbf__input-label, nbf__input-textfield, nbf__button-ghost, nbf__button-primary, nbf__button-outline"},l&&e.h("div",{slot:"custom-booking-form"},e.h("slot",{name:"custom-booking-form"}))))))))}return e.h(e.Host,null,e.h("slot",null))}get host(){return e.getElement(this)}static get watchers(){return{bookingInfo:["bookingInfoChanged"]}}};m.style=_;exports.nylas_scheduler=m;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index-29d0e781.cjs"),f=require("./register-component-55376f31-8d6ddee4.cjs"),o=require("./utils-5074a070-d5ba6add.cjs");require("react");require("react-dom");const u=":host{display:contents}.container{width:100%;overflow:auto;-webkit-overflow-scrolling:touch}.pull-to-refresh{display:none;border:0;background-color:transparent;text-align:center;width:100%;justify-content:center}.pulling{position:relative;display:flex;margin:0 auto;padding:1rem}.pulling svg{width:24px;height:24px;color:var(--nylas-color-primary-500);transform:rotate(90deg)}.refreshing{position:relative;display:flex;margin:0 auto;padding:1rem}.refreshing svg{width:24px;height:24px;fill:var(--nylas-color-primary-500);animation:rotate 1s linear infinite}@keyframes rotate{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}",p=u;var g=function(t,e,n,a){var i=arguments.length,s=i<3?e:a===null?a=Object.getOwnPropertyDescriptor(e,n):a,h;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")s=Reflect.decorate(t,e,n,a);else for(var l=t.length-1;l>=0;l--)(h=t[l])&&(s=(i<3?h(s):i>3?h(e,n,s):h(e,n))||s);return i>3&&s&&Object.defineProperty(e,n,s),s},d=function(t,e){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(t,e)};const c=class{constructor(t){r.registerInstance(this,t),this.refresh=r.createEvent(this,"refresh",7),this.threshold=100,this.onTouchStart=e=>{var n,a,i,s;o.debug("[nylas-threads-refresh] Touch start",e.touches[0].pageY,(n=this.containerElement)==null?void 0:n.scrollTop,(a=this.containerElement)==null?void 0:a.offsetHeight,(i=this.contentElement)==null?void 0:i.scrollTop),((s=this.containerElement)==null?void 0:s.scrollTop)===0?this.start=e.touches[0].pageY:this.start=0},this.onTouchMove=e=>{this.start&&(e.touches[0].pageY-this.start>this.threshold?this.pulling=!0:this.pulling=!1)},this.onTouchEnd=e=>{this.start&&(e.changedTouches[0].pageY-this.start>this.threshold&&(this.pulling=!1,this.refresh.emit({updateState:this.updateState})),this.start=0)},this.start=0,this.state="ready",this.pulling=!1,o.debug("[nylas-threads-refresh] Constructor"),this.updateState=this.updateState.bind(this)}connectedCallback(){}async componentWillLoad(){o.debug("[nylas-threads-refresh] Component will load")}componentDidLoad(){var t,e,n;o.debug("[nylas-threads-refresh] Component did load"),(t=this.containerElement)==null||t.addEventListener("touchstart",this.onTouchStart),(e=this.containerElement)==null||e.addEventListener("touchmove",this.onTouchMove),(n=this.containerElement)==null||n.addEventListener("touchend",this.onTouchEnd)}disconnectedCallback(){var t,e,n;o.debug("[nylas-threads-refresh] Component disconnected"),(t=this.containerElement)==null||t.removeEventListener("touchstart",this.onTouchStart),(e=this.containerElement)==null||e.removeEventListener("touchmove",this.onTouchMove),(n=this.containerElement)==null||n.removeEventListener("touchend",this.onTouchEnd)}async updateState(t){this.state=t}render(){return r.h(r.Host,{key:"978dd26b52dbef9d43245a2a0e9c57695ee0d0b3"},r.h("div",{key:"0062815cd33f0575ef5ced1bed59bc34863cd5a3",class:"container",ref:t=>this.containerElement=t},r.h("button",{key:"33cb5977a2d535631030a2e27a74f8fcea5a3977",class:{"pull-to-refresh":!0,pulling:this.pulling,refreshing:this.state==="loading"},"aria-label":"Refreshing..."},this.state==="loading"&&r.h("refresh-icon",{slot:"icon"}),this.state!=="loading"&&r.h("arrow-icon",{slot:"icon"})),r.h("div",{key:"83a120b8da04de8ccdc98821d1f046b7d87fd3d0",class:"content",ref:t=>this.contentElement=t},r.h("slot",{key:"47612e8d4765a94f9564d2e5bcd6c764dc03d887"}))))}};g([f.RegisterComponent({name:"nylas-threads-refresh",eventToProps:{refresh:async(t,e)=>{o.debug("[nylas-threads-refresh] Refreshing threads");const{updateState:n}=t.detail;await n("loading"),await e.threads.getThreads(void 0,"overwrite",!1),await n("ready")}},fireRegisterEvent:!0}),d("design:type",Function),d("design:paramtypes",[]),d("design:returntype",void 0)],c.prototype,"render",null);c.style=p;exports.nylas_threads_refresh=c;
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { r as f, c as p, h as o, H as u } from "./index-4f65b6f9.js";
|
|
2
|
+
import { R as m } from "./register-component-55376f31-5eaf8954.js";
|
|
3
|
+
import { d as i } from "./utils-5074a070-ce33ee6b.js";
|
|
4
|
+
import "react";
|
|
5
|
+
import "react-dom";
|
|
6
|
+
const g = ":host{display:contents}.container{width:100%;overflow:auto;-webkit-overflow-scrolling:touch}.pull-to-refresh{display:none;border:0;background-color:transparent;text-align:center;width:100%;justify-content:center}.pulling{position:relative;display:flex;margin:0 auto;padding:1rem}.pulling svg{width:24px;height:24px;color:var(--nylas-color-primary-500);transform:rotate(90deg)}.refreshing{position:relative;display:flex;margin:0 auto;padding:1rem}.refreshing svg{width:24px;height:24px;fill:var(--nylas-color-primary-500);animation:rotate 1s linear infinite}@keyframes rotate{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}", y = g;
|
|
7
|
+
var v = function(t, e, s, r) {
|
|
8
|
+
var a = arguments.length, n = a < 3 ? e : r === null ? r = Object.getOwnPropertyDescriptor(e, s) : r, h;
|
|
9
|
+
if (typeof Reflect == "object" && typeof Reflect.decorate == "function")
|
|
10
|
+
n = Reflect.decorate(t, e, s, r);
|
|
11
|
+
else
|
|
12
|
+
for (var l = t.length - 1; l >= 0; l--)
|
|
13
|
+
(h = t[l]) && (n = (a < 3 ? h(n) : a > 3 ? h(e, s, n) : h(e, s)) || n);
|
|
14
|
+
return a > 3 && n && Object.defineProperty(e, s, n), n;
|
|
15
|
+
}, c = function(t, e) {
|
|
16
|
+
if (typeof Reflect == "object" && typeof Reflect.metadata == "function")
|
|
17
|
+
return Reflect.metadata(t, e);
|
|
18
|
+
};
|
|
19
|
+
const d = class {
|
|
20
|
+
constructor(t) {
|
|
21
|
+
f(this, t), this.refresh = p(this, "refresh", 7), this.threshold = 100, this.onTouchStart = (e) => {
|
|
22
|
+
var s, r, a, n;
|
|
23
|
+
i("[nylas-threads-refresh] Touch start", e.touches[0].pageY, (s = this.containerElement) == null ? void 0 : s.scrollTop, (r = this.containerElement) == null ? void 0 : r.offsetHeight, (a = this.contentElement) == null ? void 0 : a.scrollTop), ((n = this.containerElement) == null ? void 0 : n.scrollTop) === 0 ? this.start = e.touches[0].pageY : this.start = 0;
|
|
24
|
+
}, this.onTouchMove = (e) => {
|
|
25
|
+
this.start && (e.touches[0].pageY - this.start > this.threshold ? this.pulling = !0 : this.pulling = !1);
|
|
26
|
+
}, this.onTouchEnd = (e) => {
|
|
27
|
+
this.start && (e.changedTouches[0].pageY - this.start > this.threshold && (this.pulling = !1, this.refresh.emit({
|
|
28
|
+
updateState: this.updateState
|
|
29
|
+
})), this.start = 0);
|
|
30
|
+
}, this.start = 0, this.state = "ready", this.pulling = !1, i("[nylas-threads-refresh] Constructor"), this.updateState = this.updateState.bind(this);
|
|
31
|
+
}
|
|
32
|
+
connectedCallback() {
|
|
33
|
+
}
|
|
34
|
+
async componentWillLoad() {
|
|
35
|
+
i("[nylas-threads-refresh] Component will load");
|
|
36
|
+
}
|
|
37
|
+
componentDidLoad() {
|
|
38
|
+
var t, e, s;
|
|
39
|
+
i("[nylas-threads-refresh] Component did load"), (t = this.containerElement) == null || t.addEventListener("touchstart", this.onTouchStart), (e = this.containerElement) == null || e.addEventListener("touchmove", this.onTouchMove), (s = this.containerElement) == null || s.addEventListener("touchend", this.onTouchEnd);
|
|
40
|
+
}
|
|
41
|
+
disconnectedCallback() {
|
|
42
|
+
var t, e, s;
|
|
43
|
+
i("[nylas-threads-refresh] Component disconnected"), (t = this.containerElement) == null || t.removeEventListener("touchstart", this.onTouchStart), (e = this.containerElement) == null || e.removeEventListener("touchmove", this.onTouchMove), (s = this.containerElement) == null || s.removeEventListener("touchend", this.onTouchEnd);
|
|
44
|
+
}
|
|
45
|
+
async updateState(t) {
|
|
46
|
+
this.state = t;
|
|
47
|
+
}
|
|
48
|
+
render() {
|
|
49
|
+
return o(u, { key: "978dd26b52dbef9d43245a2a0e9c57695ee0d0b3" }, o("div", { key: "0062815cd33f0575ef5ced1bed59bc34863cd5a3", class: "container", ref: (t) => this.containerElement = t }, o("button", { key: "33cb5977a2d535631030a2e27a74f8fcea5a3977", class: {
|
|
50
|
+
"pull-to-refresh": !0,
|
|
51
|
+
pulling: this.pulling,
|
|
52
|
+
refreshing: this.state === "loading"
|
|
53
|
+
}, "aria-label": "Refreshing..." }, this.state === "loading" && o("refresh-icon", { slot: "icon" }), this.state !== "loading" && o("arrow-icon", { slot: "icon" })), o("div", { key: "83a120b8da04de8ccdc98821d1f046b7d87fd3d0", class: "content", ref: (t) => this.contentElement = t }, o("slot", { key: "47612e8d4765a94f9564d2e5bcd6c764dc03d887" }))));
|
|
54
|
+
}
|
|
55
|
+
};
|
|
56
|
+
v([
|
|
57
|
+
m({
|
|
58
|
+
name: "nylas-threads-refresh",
|
|
59
|
+
eventToProps: {
|
|
60
|
+
refresh: async (t, e) => {
|
|
61
|
+
i("[nylas-threads-refresh] Refreshing threads");
|
|
62
|
+
const { updateState: s } = t.detail;
|
|
63
|
+
await s("loading"), await e.threads.getThreads(void 0, "overwrite", !1), await s("ready");
|
|
64
|
+
}
|
|
65
|
+
},
|
|
66
|
+
fireRegisterEvent: !0
|
|
67
|
+
}),
|
|
68
|
+
c("design:type", Function),
|
|
69
|
+
c("design:paramtypes", []),
|
|
70
|
+
c("design:returntype", void 0)
|
|
71
|
+
], d.prototype, "render", null);
|
|
72
|
+
d.style = y;
|
|
73
|
+
export {
|
|
74
|
+
d as nylas_threads_refresh
|
|
75
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./index-29d0e781.cjs"),d=require("./register-component-55376f31-8d6ddee4.cjs"),h=require("./utils-5074a070-d5ba6add.cjs");require("react");require("react-dom");const y=":host{display:block}sp-search{width:100%;border:0}",f=y;var p=function(t,e,n,a){var c=arguments.length,r=c<3?e:a===null?a=Object.getOwnPropertyDescriptor(e,n):a,o;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(t,e,n,a);else for(var i=t.length-1;i>=0;i--)(o=t[i])&&(r=(c<3?o(r):c>3?o(e,n,r):o(e,n))||r);return c>3&&r&&Object.defineProperty(e,n,r),r},l=function(t,e){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(t,e)};const u=class{constructor(t){s.registerInstance(this,t),this.search=s.createEvent(this,"search",7),this.onSearch=async e=>{e.preventDefault(),e.stopPropagation();const a=e.target.value;a!==this.internalQuery&&(this.internalQuery=a,this.search.emit(this.internalQuery))},this.query="",this.internalQuery=""}connectedCallback(){}disconnectedCallback(){}async componentWillLoad(){h.debug("[nylas-threads-search] Component will load")}async componentDidLoad(){h.debug("[nylas-threads-search] Component did load")}onQueryChange(){this.internalQuery=this.query}render(){return s.h(s.Host,{key:"8cec946ccaeb5fe2bf8f1282eaf5bb1e471fdc1d"},s.h("sp-theme",{key:"5795406abf802029c3722835aced9fd8bc562ef1",scale:"medium",color:"dark"},s.h("sp-search",{key:"e8c140f3a65a05106156af09a7bdf1c35f709ed1",quiet:!0,onSubmit:this.onSearch,onBlur:this.onSearch,value:this.internalQuery})))}static get watchers(){return{query:["onQueryChange"]}}};p([d.RegisterComponent({name:"nylas-pagination",stateToProps:new Map([["mailbox.searchQuery","query"]]),eventToProps:{search:async(t,e)=>{await e.threads.getThreads({search_query_native:t.detail||void 0,page_token:void 0})}},fireRegisterEvent:!0}),l("design:type",Function),l("design:paramtypes",[]),l("design:returntype",void 0)],u.prototype,"render",null);u.style=f;exports.nylas_threads_search=u;
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { r as u, c as f, h as i, H as y } from "./index-4f65b6f9.js";
|
|
2
|
+
import { R as p } from "./register-component-55376f31-5eaf8954.js";
|
|
3
|
+
import { d as h } from "./utils-5074a070-ce33ee6b.js";
|
|
4
|
+
import "react";
|
|
5
|
+
import "react-dom";
|
|
6
|
+
const m = ":host{display:block}sp-search{width:100%;border:0}", b = m;
|
|
7
|
+
var g = function(t, e, n, r) {
|
|
8
|
+
var s = arguments.length, a = s < 3 ? e : r === null ? r = Object.getOwnPropertyDescriptor(e, n) : r, o;
|
|
9
|
+
if (typeof Reflect == "object" && typeof Reflect.decorate == "function")
|
|
10
|
+
a = Reflect.decorate(t, e, n, r);
|
|
11
|
+
else
|
|
12
|
+
for (var c = t.length - 1; c >= 0; c--)
|
|
13
|
+
(o = t[c]) && (a = (s < 3 ? o(a) : s > 3 ? o(e, n, a) : o(e, n)) || a);
|
|
14
|
+
return s > 3 && a && Object.defineProperty(e, n, a), a;
|
|
15
|
+
}, l = function(t, e) {
|
|
16
|
+
if (typeof Reflect == "object" && typeof Reflect.metadata == "function")
|
|
17
|
+
return Reflect.metadata(t, e);
|
|
18
|
+
};
|
|
19
|
+
const d = class {
|
|
20
|
+
constructor(t) {
|
|
21
|
+
u(this, t), this.search = f(this, "search", 7), this.onSearch = async (e) => {
|
|
22
|
+
e.preventDefault(), e.stopPropagation();
|
|
23
|
+
const r = e.target.value;
|
|
24
|
+
r !== this.internalQuery && (this.internalQuery = r, this.search.emit(this.internalQuery));
|
|
25
|
+
}, this.query = "", this.internalQuery = "";
|
|
26
|
+
}
|
|
27
|
+
connectedCallback() {
|
|
28
|
+
}
|
|
29
|
+
disconnectedCallback() {
|
|
30
|
+
}
|
|
31
|
+
async componentWillLoad() {
|
|
32
|
+
h("[nylas-threads-search] Component will load");
|
|
33
|
+
}
|
|
34
|
+
async componentDidLoad() {
|
|
35
|
+
h("[nylas-threads-search] Component did load");
|
|
36
|
+
}
|
|
37
|
+
onQueryChange() {
|
|
38
|
+
this.internalQuery = this.query;
|
|
39
|
+
}
|
|
40
|
+
render() {
|
|
41
|
+
return i(y, { key: "8cec946ccaeb5fe2bf8f1282eaf5bb1e471fdc1d" }, i("sp-theme", { key: "5795406abf802029c3722835aced9fd8bc562ef1", scale: "medium", color: "dark" }, i("sp-search", { key: "e8c140f3a65a05106156af09a7bdf1c35f709ed1", quiet: !0, onSubmit: this.onSearch, onBlur: this.onSearch, value: this.internalQuery })));
|
|
42
|
+
}
|
|
43
|
+
static get watchers() {
|
|
44
|
+
return {
|
|
45
|
+
query: ["onQueryChange"]
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
g([
|
|
50
|
+
p({
|
|
51
|
+
name: "nylas-pagination",
|
|
52
|
+
stateToProps: /* @__PURE__ */ new Map([["mailbox.searchQuery", "query"]]),
|
|
53
|
+
eventToProps: {
|
|
54
|
+
search: async (t, e) => {
|
|
55
|
+
await e.threads.getThreads({
|
|
56
|
+
search_query_native: t.detail || void 0,
|
|
57
|
+
page_token: void 0
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
fireRegisterEvent: !0
|
|
62
|
+
}),
|
|
63
|
+
l("design:type", Function),
|
|
64
|
+
l("design:paramtypes", []),
|
|
65
|
+
l("design:returntype", void 0)
|
|
66
|
+
], d.prototype, "render", null);
|
|
67
|
+
d.style = b;
|
|
68
|
+
export {
|
|
69
|
+
d as nylas_threads_search
|
|
70
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-29d0e781.cjs"),f=require("./register-component-55376f31-8d6ddee4.cjs"),i=require("./utils-5074a070-d5ba6add.cjs");require("react");require("react-dom");function b(t,a,s,o,r){if(!o||!s||s.children.length>0)return;i.debug("[nylas-view-thread] Rendering email",{message:t,attachments:a,viewEmailElement:o});const n=o.cloneNode(!0);n.message=t.data,n.parent=r,s.appendChild(n)}const m=({viewEmailElement:t,message:a,attachments:s,onMessageClick:o,onShowContactDataClick:r,parent:n})=>{var d,l,h,u,v,y,w;return e.h(e.Fragment,null,e.h("div",{key:a.id,class:"message"},e.h("div",{class:"sub-header","data-id":a.data.id,onClick:o},e.h("div",{class:"avatar"},a.data.from&&((d=a.data.from[0])==null?void 0:d.name)&&((h=(l=a.data.from[0])==null?void 0:l.name[0])==null?void 0:h.toUpperCase())),e.h("div",{class:"from"},e.h("span",{class:"name"},a.data.from&&((u=a.data.from[0])==null?void 0:u.name))," ",e.h("span",{class:"email"},a.data.from&&((v=a.data.from[0])==null?void 0:v.email))),e.h("div",{class:"date"},new Date(a.data.date*1e3).toLocaleTimeString(void 0,{timeStyle:"short"})," ","(",i.formatTimeAgo(new Date(a.data.date*1e3)),")"),e.h("sp-button-group",{class:"buttons"},e.h("nylas-summarize-message-button",{message:a.data})),a.collapse&&e.h("div",{class:"snippet"},a.data.snippet),!a.collapse&&a.data.to&&e.h("div",{class:"to"},e.h("span",null,"to")," ",i.formatParticipants(a.data.to)," ",e.h("button",{type:"button",value:a.data.id,onClick:r,class:{expand:!0,"expand--showContactData":a.showContactData}},e.h("chevron-icon",null)))),a.showContactData&&e.h("div",{class:"address-info"},e.h("div",{class:"label"},"From"),e.h("div",{class:"value"},i.formatRecipient((y=a.data)!=null&&y.from?(w=a==null?void 0:a.data)==null?void 0:w.from[0]:{name:"",email:""})),a.data.to&&e.h(e.Fragment,null,e.h("div",{class:"label"},"To"),e.h("div",{class:"value"},a.data.to.map(c=>e.h("div",null,i.formatRecipient(c))))),typeof a.data.cc<"u"&&a.data.cc.length>0&&e.h(e.Fragment,null,e.h("div",{class:"label"},"CC"),e.h("div",{class:"value"},a.data.cc.map(c=>e.h("div",null,i.formatRecipient(c)))))),!a.collapse&&t&&e.h("div",{key:a.id,ref:c=>b(a,s,c,t,n)}),!a.collapse&&!t&&e.h("nylas-view-email",{key:a.id,message:a.data,parent:n})),e.h("hr",null))},C=':host{display:block;font-size:inherit}.avatar{z-index:1;border-radius:100%;background-color:var(--nylas-color-primary-200);height:40px;width:40px;align-items:center;display:flex;justify-content:center;border:1px solid var(--nylas-color-primary-200)}.view-thread{display:grid;grid-auto-flow:row;width:100%}.view-thread .header{display:grid;grid-gap:1rem;align-items:center;margin-bottom:1rem}.view-thread .header .subject{font-size:1.25rem;font-weight:600;line-height:1.5rem}.view-thread .header .folders{display:grid;grid-auto-flow:column;grid-auto-columns:min-content;overflow-x:auto;gap:1rem}.view-thread .header .folders .folder{padding:0 0.5rem;font-size:0.9rem;color:var(--nylas-color-primary-900);background-color:var(--nylas-color-primary-300)}.view-thread .messages{display:grid;gap:1rem}.view-thread .messages hr{margin:0;width:100%;border:1px solid var(--nylas-color-primary-200)}.view-thread .messages hr:last-of-type{display:none}.view-thread .messages .message{display:grid;grid-auto-flow:row;gap:1rem}.view-thread .messages .message:last-of-type .sub-header{cursor:default}.view-thread .messages .message .sub-header{display:grid;grid-template:"avatar from date buttons" "avatar to to buttons";grid-column-gap:1rem;grid-template-columns:auto 1fr auto auto;cursor:pointer}.view-thread .messages .message .sub-header>*{pointer-events:none}.view-thread .messages .message .sub-header .avatar{grid-area:avatar}.view-thread .messages .message .sub-header .from{grid-area:from}.view-thread .messages .message .sub-header .from span.email{display:none;color:var(--nylas-color-primary-400);font-weight:600}.view-thread .messages .message .sub-header .buttons{grid-area:buttons;align-self:center}.view-thread .messages .message .sub-header .buttons *{pointer-events:all}.view-thread .messages .message .sub-header .date{grid-area:date;align-self:center;color:var(--nylas-color-primary-400)}.view-thread .messages .message .sub-header .snippet{width:90%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:var(--nylas-color-primary-600)}.view-thread .messages .message .sub-header .to{grid-area:to;color:var(--nylas-color-primary-400)}.view-thread .messages .message .sub-header .to>span{color:var(--nylas-color-primary-400)}.view-thread .messages .message .sub-header .to button{border:0;background-color:transparent;cursor:pointer;pointer-events:all;padding:0;margin:0}.view-thread .messages .message .sub-header .to button>*{pointer-events:none}.view-thread .messages .message .sub-header .to button chevron-icon{display:inline-table;fill:var(--nylas-color-primary-400);width:15px;height:15px;vertical-align:middle}.view-thread .messages .message .sub-header .to button chevron-icon svg{width:15px;height:15px;transform:rotate(90deg)}.view-thread .messages .message .sub-header .to button.expand--showContactData chevron-icon svg{transform:rotate(270deg)}.view-thread .messages .message .address-info{display:grid;column-gap:1rem;row-gap:0.5rem;grid-template-columns:auto 1fr;grid-template-rows:1fr;padding:1rem 2rem;border-radius:var(--nylas-border-radius-2x);border:1px solid var(--nylas-color-primary-200);align-items:flex-start;color:var(--nylas-color-primary-600)}.view-thread .messages .message .address-info .label{color:var(--nylas-color-primary-400);font-weight:600}.show-more{position:relative;display:flex;width:100%}.show-more .sr-only{display:none}.show-more button{position:relative;display:inline-flex;width:100%;padding:0;border:0;background-color:transparent;cursor:pointer;text-align:left;overflow:hidden}.show-more button span{border:1px solid var(--nylas-color-primary-400)}.show-more button:hover span{background-color:var(--nylas-color-primary-700)}.show-more button::after{border-top:1px solid rgba(100, 121, 143, 0.122);border-bottom:1px solid rgba(100, 121, 143, 0.122);content:"";height:4px;width:100%;position:absolute;top:50%}.loading{position:absolute;width:100%;height:100%;background-color:var(--loading__background-color);top:0;bottom:0;left:0;z-index:1;display:grid;justify-content:center;align-items:center;font-weight:600;overflow:hidden}.reply-buttons{display:grid;grid-auto-flow:column;grid-auto-columns:min-content;gap:1rem;margin-top:1rem}.reply-buttons sp-button{border-radius:var(--nylas-border-radius);background-color:var(--nylas-color-primary-400);color:var(--nylas-color-primary-900);fill:var(--nylas-color-primary-900)}.reply-buttons sp-button:hover{background-color:var(--nylas-color-primary-500)}.reply-buttons sp-button:disabled{background-color:var(--nylas-color-primary-200);color:var(--nylas-color-primary-600);cursor:not-allowed}.reply-buttons sp-button chevron-icon{display:inline-block}@media only screen and (min-width: 768px){.view-thread .messages .message .sub-header .from span.email{display:inline}}',k=C;var M=function(t,a,s,o){var r=arguments.length,n=r<3?a:o===null?o=Object.getOwnPropertyDescriptor(a,s):o,d;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")n=Reflect.decorate(t,a,s,o);else for(var l=t.length-1;l>=0;l--)(d=t[l])&&(n=(r<3?d(n):r>3?d(a,s,n):d(a,s))||n);return r>3&&n&&Object.defineProperty(a,s,n),n},p=function(t,a){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(t,a)};const g=class{constructor(t){e.registerInstance(this,t),this.threadSelected=e.createEvent(this,"threadSelected",7),this.showContactDataClicked=e.createEvent(this,"showContactDataClicked",7),this.messageClicked=e.createEvent(this,"messageClicked",7),this.nylasViewEmailElement=null,this.nylasComposerElement=null,this.onShowContactDataClick=a=>{a.stopPropagation();const o=a.target.value,r=this.internalMessages.find(d=>d.data.id===o);if(!r){i.debug(`[nylas-view-thread] Could not find message ${o}`);return}this.showContactDataClicked.emit(r.data).defaultPrevented||(r.showContactData=!r.showContactData,this.internalMessages=[...this.internalMessages]),i.debug(`[nylas-view-thread] show contact data clicked ${o} ${r.showContactData?"collapsed":"expanded"}`)},this.onMessageClick=a=>{var d;const o=a.target.dataset.id,r=this.internalMessages.find(l=>l.data.id===o);if(!r){i.debug(`[nylas-view-thread] Could not find message ${o}`);return}this.messageClicked.emit(r.data).defaultPrevented||(r.id!==((d=this.internalMessages[this.internalMessages.length-1])==null?void 0:d.id)&&(r.collapse=!r.collapse,r.collapse&&(r.showContactData=!1)),this.internalMessages=[...this.internalMessages]),i.debug(`[nylas-view-thread] message clicked ${o} ${r.collapse?"collapsed":"expanded"}`)},this.onShowAllEmailsClick=()=>{this.showAllEmails=!this.showAllEmails},this.showComposerClick=()=>{this.showComposer=!this.showComposer},this.draft=void 0,this.thread=void 0,this.messages=[],this.attachments=[],this.state="loading",this.internalMessages=[],this.showAllEmails=!1,this.showComposer=!1}connectedCallback(){}disconnectedCallback(){}async componentWillLoad(){i.debug("[nylas-view-thread] Component will load"),this.updateInternalMessages(this.messages);const t=this.host.querySelector("template.nylas-view-email");if(!t){i.debug("[nylas-view-thread] Could not find template");return}const a=document.importNode(t.content,!0);this.nylasViewEmailElement=a.querySelector("nylas-view-email");const s=this.host.querySelector("template.nylas-composer");if(!s){i.debug("[nylas-view-thread] Could not find composer template");return}const o=document.importNode(s.content,!0);this.nylasComposerElement=o.querySelector("nylas-composer")}async componentDidLoad(){i.debug("[nylas-view-thread] Component did load")}async threadChanged(t){i.debug("[nylas-view-thread] Thread changed",{thread:t}),this.internalMessages=[],this.threadSelected.emit(t).defaultPrevented||i.debug("[nylas-view-thread] Default event not prevented, initializing")}updateInternalMessages(t){i.debug("[nylas-view-thread] Updating internal messages",{messages:t});const a=t.sort((s,o)=>s.date>o.date?1:-1).map((s,o)=>({id:s.id,data:s,collapse:o!==t.length-1,showContactData:!1}));this.internalMessages=a}render(){var r,n,d;const t=this.internalMessages.length>2?this.internalMessages[0]:null,a=this.internalMessages.slice(this.internalMessages.length-2,this.internalMessages.length),s=this.internalMessages.slice(1,this.internalMessages.length-2),o=this.internalMessages[this.internalMessages.length-1];return e.h(e.Host,{key:"99b11b1bd476708c89e6284a7d8fda1da9d886ff"},e.h("sp-theme",{key:"23bc8c7387f08654aa38a187ee0da13e860ad207",scale:"medium",color:"dark"},e.h("div",{key:"fd78702832a02c3469dfea1b91aea94282cc566d",class:"view-thread"},e.h("div",{key:"2405c194d2a7f80802cc25794129496453781445",class:"header"},e.h("div",{key:"f69ceef2127c53c38acb2be2033fd1e5b5502aad",class:"subject"},(r=this.thread)==null?void 0:r.subject),e.h("div",{key:"2aceb0fa163a30aaa3e6a8f95b52b6ba0583d904",class:"folders"},(d=(n=this.thread)==null?void 0:n.folders)==null?void 0:d.map(l=>e.h("sp-tag",{size:"s"},i.toTitleCase(l.replace("CATEGORY_","").replace("_"," ")))))),e.h("div",{key:"33a0f1c33dfd2072681c356a5144eaba7ef9522b",class:"messages"},t&&e.h(m,{message:t,attachments:this.attachments.filter(l=>l.messageId===t.id),onMessageClick:this.onMessageClick,onShowContactDataClick:this.onShowContactDataClick,parent:this.host,viewEmailElement:this.nylasViewEmailElement,composerElement:this.nylasComposerElement}),s.length>0&&this.messages.length>1&&!this.showAllEmails&&a.length>0&&e.h(e.Fragment,null,e.h("div",{class:"show-more"},e.h("button",{type:"button",onClick:this.onShowAllEmailsClick},e.h("span",{class:"avatar"},s.length)," ",e.h("span",{class:"sr-only"},"Show ",s.length," more emails"))),e.h("hr",null)),s.length>0&&this.showAllEmails&&this.messages.length>2&&s.map(l=>e.h(m,{message:l,attachments:this.attachments.filter(h=>h.messageId===(t==null?void 0:t.id)),onMessageClick:this.onMessageClick,onShowContactDataClick:this.onShowContactDataClick,parent:this.host,viewEmailElement:this.nylasViewEmailElement,composerElement:this.nylasComposerElement})),a.length>0&&a.map(l=>e.h(m,{message:l,attachments:this.attachments.filter(h=>h.messageId===(t==null?void 0:t.id)),onMessageClick:this.onMessageClick,onShowContactDataClick:this.onShowContactDataClick,parent:this.host,viewEmailElement:this.nylasViewEmailElement,composerElement:this.nylasComposerElement}))),!(this.showComposer&&o)&&e.h("div",{class:"reply-buttons"},e.h("sp-button",{variant:"cta",type:"button",onClick:this.showComposerClick},e.h("span",{slot:"icon"},e.h("reply-icon",null)),e.h("span",null,"Reply")),e.h("sp-button",{variant:"cta",type:"button"},e.h("span",{slot:"icon"},e.h("reply-all-icon",null)),e.h("span",null,"Reply All")),e.h("sp-button",{variant:"cta",type:"button"},e.h("span",{slot:"icon"},e.h("forward-icon",null)),e.h("span",null,"Forward"))),this.showComposer&&o&&e.h("div",{class:"composer"},e.h("nylas-composer",{message:o.data,onClose:this.showComposerClick,onSend:l=>{i.debug("[nylas-view-thread] Send event",{message:l.detail.message,replyBody:l.detail.replyBody})}})))))}get host(){return e.getElement(this)}static get watchers(){return{thread:["threadChanged"],messages:["updateInternalMessages"]}}};M([f.RegisterComponent({name:"nylas-view-thread",stateToProps:new Map([["mailbox.selectedThread","thread"],["mailbox.messages","messages"],["mailbox.state","state"]]),eventToProps:{threadSelected:async(t,a)=>{i.debug("[nylas-view-thread] Nylas init event. Fetching thread messages.",{event:t});const s=t.detail;s&&s.id&&await a.messages.getThreadMessages(s.id)}},fireRegisterEvent:!0}),p("design:type",Function),p("design:paramtypes",[]),p("design:returntype",void 0)],g.prototype,"render",null);g.style=k;exports.nylas_view_thread=g;
|