@opencxh/domain 1.222.0 → 1.225.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.
- package/dist/entities/activity/types.d.ts +21 -1
- package/dist/entities/assignment/types.d.ts +42 -4
- package/dist/entities/mcp/types.d.ts +14 -0
- package/dist/entities/playbook/trigger-vars.d.ts +9 -0
- package/dist/entities/reaction/types.d.ts +25 -0
- package/dist/entities/sla/hours.d.ts +7 -0
- package/dist/entities/sla/hours.test.d.ts +1 -0
- package/dist/entities/sla/index.d.ts +4 -0
- package/dist/entities/sla/machine.d.ts +47 -0
- package/dist/entities/sla/machine.test.d.ts +1 -0
- package/dist/entities/sla/types.d.ts +107 -0
- package/dist/entities/sla/view.d.ts +36 -0
- package/dist/entities/sla/view.test.d.ts +1 -0
- package/dist/entities/work/types.d.ts +5 -0
- package/dist/index.cjs +14 -14
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1340 -1102
- package/dist/platform/provider.d.ts +11 -0
- package/dist/platform/resource-source.d.ts +24 -0
- package/dist/platform/storage.d.ts +281 -4
- package/dist/platform/sync-source.d.ts +72 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const
|
|
1
|
+
const hi = 10, yi = 10, bi = 10, Ai = 5, ht = /* @__PURE__ */ new Set([
|
|
2
2
|
"header",
|
|
3
3
|
"section",
|
|
4
4
|
"context",
|
|
@@ -8,13 +8,13 @@ const Ur = 10, Kr = 10, jr = 10, Br = 5, ze = /* @__PURE__ */ new Set([
|
|
|
8
8
|
"actions",
|
|
9
9
|
"attachments"
|
|
10
10
|
]);
|
|
11
|
-
function
|
|
11
|
+
function j(e) {
|
|
12
12
|
if (typeof e == "string") return e.length > 0;
|
|
13
13
|
if (!e || typeof e != "object") return !1;
|
|
14
14
|
const t = e;
|
|
15
15
|
return typeof t.key == "string" || typeof t.value == "string";
|
|
16
16
|
}
|
|
17
|
-
function
|
|
17
|
+
function Ei(e, t = () => {
|
|
18
18
|
}) {
|
|
19
19
|
if (!Array.isArray(e)) return [];
|
|
20
20
|
const n = [];
|
|
@@ -25,19 +25,19 @@ function Hr(e, t = () => {
|
|
|
25
25
|
}
|
|
26
26
|
if (!r || typeof r != "object") continue;
|
|
27
27
|
const i = r;
|
|
28
|
-
if (!
|
|
28
|
+
if (!ht.has(i.type)) {
|
|
29
29
|
t(`unknown block type ${String(i.type)}`);
|
|
30
30
|
continue;
|
|
31
31
|
}
|
|
32
32
|
switch (i.type) {
|
|
33
33
|
case "header":
|
|
34
|
-
if (!
|
|
34
|
+
if (!j(i.text)) {
|
|
35
35
|
t("a header without text");
|
|
36
36
|
continue;
|
|
37
37
|
}
|
|
38
38
|
break;
|
|
39
39
|
case "context":
|
|
40
|
-
if (!
|
|
40
|
+
if (!j(i.text)) {
|
|
41
41
|
t("a context block without text");
|
|
42
42
|
continue;
|
|
43
43
|
}
|
|
@@ -59,7 +59,7 @@ function Hr(e, t = () => {
|
|
|
59
59
|
i.items.length > 10 && (t("more than 10 list items"), i.items = i.items.slice(0, 10));
|
|
60
60
|
break;
|
|
61
61
|
case "actions": {
|
|
62
|
-
const o = Array.isArray(i.elements) ? i.elements : [], a = o.filter((s) => s?.action_id && s.invoke &&
|
|
62
|
+
const o = Array.isArray(i.elements) ? i.elements : [], a = o.filter((s) => s?.action_id && s.invoke && j(s.text));
|
|
63
63
|
if (a.length !== o.length && t("an action without action_id, invoke or text"), a.length === 0) continue;
|
|
64
64
|
a.length > 5 && t("more than 5 actions"), i.elements = a.slice(0, 5);
|
|
65
65
|
break;
|
|
@@ -69,44 +69,44 @@ function Hr(e, t = () => {
|
|
|
69
69
|
}
|
|
70
70
|
return n;
|
|
71
71
|
}
|
|
72
|
-
const
|
|
73
|
-
function
|
|
72
|
+
const yt = /(\*\*|__)(?=\S)([\s\S]*?\S)\1/g, bt = /(\*|_)(?=\S)([^*_\n]*?\S)\1/g;
|
|
73
|
+
function At(e) {
|
|
74
74
|
if (typeof e != "string" || !e) return "";
|
|
75
75
|
let t = e;
|
|
76
76
|
return t = t.replace(/```[a-z]*\n?/gi, "").replace(/~~~[a-z]*\n?/gi, ""), t = t.replace(/!\[([^\]]*)\]\([^)]*\)/g, "$1"), t = t.replace(/\[([^\]]*)\]\([^)]*\)/g, "$1"), t = t.replace(/\[([^\]]*)\]\[[^\]]*\]/g, "$1"), t = t.replace(/<((?:https?|mailto):[^>\s]+)>/gi, "$1"), t = t.split(`
|
|
77
77
|
`).map(
|
|
78
78
|
(n) => n.replace(/^\s{0,3}#{1,6}\s+/, "").replace(/^\s{0,3}>\s?/, "").replace(/^\s*[-*+]\s+/, "").replace(/^\s*\d+[.)]\s+/, "").replace(/^\s*(?:[-*_]\s*){3,}$/, "")
|
|
79
79
|
).join(`
|
|
80
|
-
`), t = t.replace(
|
|
80
|
+
`), t = t.replace(yt, "$2"), t = t.replace(bt, "$2"), t = t.replace(/~~(?=\S)([\s\S]*?\S)~~/g, "$1"), t = t.replace(/`([^`\n]+)`/g, "$1"), t.replace(/\s+/g, " ").trim();
|
|
81
81
|
}
|
|
82
|
-
function
|
|
82
|
+
function Et(e) {
|
|
83
83
|
return e.replace(/<style[\s\S]*?<\/style>/gi, " ").replace(/<script[\s\S]*?<\/script>/gi, " ").replace(/<[^>]+>/g, " ").replace(/ /g, " ").replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, '"').replace(/'/g, "'").replace(/\s+/g, " ").trim();
|
|
84
84
|
}
|
|
85
|
-
function
|
|
85
|
+
function R(e) {
|
|
86
86
|
if (!e || e < 0) return "";
|
|
87
87
|
const t = Math.floor(e / 60), n = Math.floor(e % 60);
|
|
88
88
|
return `${t}:${n.toString().padStart(2, "0")}`;
|
|
89
89
|
}
|
|
90
|
-
function
|
|
90
|
+
function se(e) {
|
|
91
91
|
return e ? ` — ${Math.floor(e / 60)}m ${e % 60}s` : "";
|
|
92
92
|
}
|
|
93
|
-
function
|
|
93
|
+
function H(e) {
|
|
94
94
|
return e?.split("@")?.[0] || e || "";
|
|
95
95
|
}
|
|
96
|
-
function
|
|
96
|
+
function D(e) {
|
|
97
97
|
return e.map((t) => t.name).join(", ");
|
|
98
98
|
}
|
|
99
|
-
function
|
|
99
|
+
function ce(e) {
|
|
100
100
|
return e === "meeting" ? "Meeting" : e === "video" ? "Video call" : "Audio call";
|
|
101
101
|
}
|
|
102
|
-
const
|
|
102
|
+
const _ = {
|
|
103
103
|
/* ---- voice ---- */
|
|
104
104
|
VOICE_CALL_STARTED: {
|
|
105
105
|
shape: "event",
|
|
106
106
|
channelKind: "voice",
|
|
107
107
|
icon: "phone",
|
|
108
108
|
snippet: () => "Gesprek gestart",
|
|
109
|
-
timeline: (e) => e.direction === "inbound" ? `Inbound call started — ${
|
|
109
|
+
timeline: (e) => e.direction === "inbound" ? `Inbound call started — ${H(e.payload.from)}` : `Outbound call started — ${H(e.payload.to)}`
|
|
110
110
|
},
|
|
111
111
|
VOICE_CALL_ANSWERED: {
|
|
112
112
|
shape: "event",
|
|
@@ -133,15 +133,15 @@ const A = {
|
|
|
133
133
|
shape: "event",
|
|
134
134
|
channelKind: "voice",
|
|
135
135
|
icon: "phone",
|
|
136
|
-
snippet: (e) => `Gesprek beëindigd${e.payload.duration ? ` (${
|
|
137
|
-
timeline: (e) => `Call ended${
|
|
136
|
+
snippet: (e) => `Gesprek beëindigd${e.payload.duration ? ` (${R(e.payload.duration)})` : ""}`,
|
|
137
|
+
timeline: (e) => `Call ended${se(e.payload.duration)}`
|
|
138
138
|
},
|
|
139
139
|
VOICE_CALL_MISSED: {
|
|
140
140
|
shape: "event",
|
|
141
141
|
channelKind: "voice",
|
|
142
142
|
icon: "phone",
|
|
143
143
|
snippet: () => "Gemiste oproep",
|
|
144
|
-
timeline: (e) => `Missed call — ${
|
|
144
|
+
timeline: (e) => `Missed call — ${H(e.payload.from)}`
|
|
145
145
|
},
|
|
146
146
|
VOICE_CALL_FAILED: {
|
|
147
147
|
shape: "event",
|
|
@@ -188,7 +188,7 @@ const A = {
|
|
|
188
188
|
shape: "event",
|
|
189
189
|
channelKind: "video",
|
|
190
190
|
icon: "video",
|
|
191
|
-
snippet: (e) => `Gesprek beëindigd${e.payload.duration ? ` (${
|
|
191
|
+
snippet: (e) => `Gesprek beëindigd${e.payload.duration ? ` (${R(e.payload.duration)})` : ""}`,
|
|
192
192
|
timeline: () => "Video call ended"
|
|
193
193
|
},
|
|
194
194
|
VIDEO_CALL_MISSED: {
|
|
@@ -216,7 +216,7 @@ const A = {
|
|
|
216
216
|
replyable: !0,
|
|
217
217
|
carriesText: !0,
|
|
218
218
|
countsAs: "inbound_message",
|
|
219
|
-
snippet:
|
|
219
|
+
snippet: le
|
|
220
220
|
},
|
|
221
221
|
EMAIL_SENT: {
|
|
222
222
|
shape: "message",
|
|
@@ -226,7 +226,7 @@ const A = {
|
|
|
226
226
|
replyable: !0,
|
|
227
227
|
carriesText: !0,
|
|
228
228
|
countsAs: "outbound_message",
|
|
229
|
-
snippet:
|
|
229
|
+
snippet: le
|
|
230
230
|
},
|
|
231
231
|
/* ---- chat ---- */
|
|
232
232
|
CHAT_MESSAGE_SENT: {
|
|
@@ -255,9 +255,9 @@ const A = {
|
|
|
255
255
|
shape: "event",
|
|
256
256
|
channelKind: "chat",
|
|
257
257
|
icon: "message-circle",
|
|
258
|
-
snippet: (e) => `${
|
|
258
|
+
snippet: (e) => `${D(e.payload.members)} toegevoegd`,
|
|
259
259
|
timeline: (e) => {
|
|
260
|
-
const t =
|
|
260
|
+
const t = D(e.payload.members) || "Someone", n = e.payload.initiator?.name ? ` · added by ${e.payload.initiator.name}` : "";
|
|
261
261
|
return `${t} joined the chat${n}`;
|
|
262
262
|
}
|
|
263
263
|
},
|
|
@@ -265,9 +265,9 @@ const A = {
|
|
|
265
265
|
shape: "event",
|
|
266
266
|
channelKind: "chat",
|
|
267
267
|
icon: "message-circle",
|
|
268
|
-
snippet: (e) => `${
|
|
268
|
+
snippet: (e) => `${D(e.payload.members)} verlaten`,
|
|
269
269
|
timeline: (e) => {
|
|
270
|
-
const t =
|
|
270
|
+
const t = D(e.payload.members) || "Someone", n = e.payload.initiator?.name ? ` · removed by ${e.payload.initiator.name}` : "";
|
|
271
271
|
return `${t} left the chat${n}`;
|
|
272
272
|
}
|
|
273
273
|
},
|
|
@@ -283,15 +283,15 @@ const A = {
|
|
|
283
283
|
channelKind: "chat",
|
|
284
284
|
icon: "message-circle",
|
|
285
285
|
snippet: () => "Gesprek gestart",
|
|
286
|
-
timeline: (e) => `${
|
|
286
|
+
timeline: (e) => `${ce(e.payload.callType)} started${e.payload.initiator ? ` by ${e.payload.initiator.name}` : ""}`,
|
|
287
287
|
joinUrl: (e) => e.payload.joinUrl
|
|
288
288
|
},
|
|
289
289
|
CHAT_CALL_ENDED: {
|
|
290
290
|
shape: "event",
|
|
291
291
|
channelKind: "chat",
|
|
292
292
|
icon: "message-circle",
|
|
293
|
-
snippet: (e) => `Gesprek beëindigd${e.payload.duration ? ` (${
|
|
294
|
-
timeline: (e) => `${
|
|
293
|
+
snippet: (e) => `Gesprek beëindigd${e.payload.duration ? ` (${R(e.payload.duration)})` : ""}`,
|
|
294
|
+
timeline: (e) => `${ce(e.payload.callType)} ended${se(e.payload.duration)}`,
|
|
295
295
|
joinUrl: (e) => e.payload.joinUrl
|
|
296
296
|
},
|
|
297
297
|
CHAT_EVENT: {
|
|
@@ -380,7 +380,7 @@ const A = {
|
|
|
380
380
|
MEETING_ENDED: {
|
|
381
381
|
shape: "event",
|
|
382
382
|
icon: "calendar",
|
|
383
|
-
snippet: (e) => `Vergadering beëindigd${e.payload.duration ? ` (${
|
|
383
|
+
snippet: (e) => `Vergadering beëindigd${e.payload.duration ? ` (${R(e.payload.duration)})` : ""}`,
|
|
384
384
|
timeline: () => "Meeting ended"
|
|
385
385
|
},
|
|
386
386
|
MEETING_PARTICIPANT_JOINED: {
|
|
@@ -416,6 +416,18 @@ const A = {
|
|
|
416
416
|
snippet: () => "Interactie toegewezen",
|
|
417
417
|
timeline: (e, t) => `Assigned by ${t}`
|
|
418
418
|
},
|
|
419
|
+
/**
|
|
420
|
+
* `triggerable`, and that is the point: escalation on a breach is an ordinary playbook rule
|
|
421
|
+
* on an ordinary activity trigger, so the engine needed no new trigger kind.
|
|
422
|
+
*/
|
|
423
|
+
SLA_BREACHED: {
|
|
424
|
+
shape: "event",
|
|
425
|
+
triggerable: !0,
|
|
426
|
+
displayNameKey: "communication:activity.SLA_BREACHED",
|
|
427
|
+
icon: "alarm-clock",
|
|
428
|
+
snippet: (e) => `SLA verlopen: ${e.payload.metric}`,
|
|
429
|
+
timeline: (e) => `SLA target ${e.payload.metric} passed its deadline`
|
|
430
|
+
},
|
|
419
431
|
/* ---- work items ---- */
|
|
420
432
|
/**
|
|
421
433
|
* `shape: "note"` is load-bearing: it makes `isMessageShape` → `isMessageType` →
|
|
@@ -448,63 +460,63 @@ const A = {
|
|
|
448
460
|
timeline: (e, t) => `Status changed by ${t}`
|
|
449
461
|
}
|
|
450
462
|
};
|
|
451
|
-
function
|
|
452
|
-
const t = e.payload, n =
|
|
463
|
+
function le(e) {
|
|
464
|
+
const t = e.payload, n = At(t.bodyText).trim() || t.bodySnippet?.trim() || Et(t.body ?? "");
|
|
453
465
|
return t.subject ? `${t.subject} — ${n}` : n;
|
|
454
466
|
}
|
|
455
|
-
function
|
|
456
|
-
return
|
|
467
|
+
function b(e) {
|
|
468
|
+
return _[e];
|
|
457
469
|
}
|
|
458
|
-
function
|
|
459
|
-
return
|
|
470
|
+
function Si(e) {
|
|
471
|
+
return b(e)?.icon ?? "circle";
|
|
460
472
|
}
|
|
461
|
-
function
|
|
462
|
-
return
|
|
473
|
+
function _i(e) {
|
|
474
|
+
return b(e)?.channelKind;
|
|
463
475
|
}
|
|
464
|
-
function
|
|
476
|
+
function Be(e) {
|
|
465
477
|
return e === "message" || e === "note";
|
|
466
478
|
}
|
|
467
|
-
function
|
|
468
|
-
return
|
|
479
|
+
function Ti(e) {
|
|
480
|
+
return Be(b(e)?.shape);
|
|
469
481
|
}
|
|
470
|
-
function
|
|
482
|
+
function je(e) {
|
|
471
483
|
return e === "note";
|
|
472
484
|
}
|
|
473
|
-
function
|
|
474
|
-
return
|
|
485
|
+
function wi(e) {
|
|
486
|
+
return je(b(e)?.shape);
|
|
475
487
|
}
|
|
476
|
-
function
|
|
477
|
-
return
|
|
488
|
+
function Ii(e) {
|
|
489
|
+
return b(e)?.replyable === !0;
|
|
478
490
|
}
|
|
479
|
-
function
|
|
480
|
-
return
|
|
491
|
+
function Mi(e) {
|
|
492
|
+
return b(e)?.carriesText === !0;
|
|
481
493
|
}
|
|
482
|
-
function
|
|
483
|
-
return
|
|
494
|
+
function St(e) {
|
|
495
|
+
return b(e)?.countsAs;
|
|
484
496
|
}
|
|
485
|
-
function
|
|
486
|
-
return
|
|
497
|
+
function Oi(e) {
|
|
498
|
+
return b(e)?.playbookAuthored === !0;
|
|
487
499
|
}
|
|
488
|
-
function
|
|
489
|
-
return
|
|
500
|
+
function Ci(e) {
|
|
501
|
+
return b(e)?.connected === !0;
|
|
490
502
|
}
|
|
491
|
-
function
|
|
492
|
-
const t =
|
|
503
|
+
function ki(e) {
|
|
504
|
+
const t = b(e);
|
|
493
505
|
return t?.shape === "artifact" && t?.carriesText === !0;
|
|
494
506
|
}
|
|
495
|
-
function
|
|
496
|
-
const t =
|
|
507
|
+
function _t(e) {
|
|
508
|
+
const t = b(e.type)?.snippet;
|
|
497
509
|
return t ? t(e) : "";
|
|
498
510
|
}
|
|
499
|
-
function
|
|
500
|
-
const n =
|
|
511
|
+
function vi(e, t) {
|
|
512
|
+
const n = b(e.type)?.timeline;
|
|
501
513
|
return n ? n(e, t) : e.type.replace(/_/g, " ").toLowerCase();
|
|
502
514
|
}
|
|
503
|
-
function
|
|
504
|
-
const t =
|
|
515
|
+
function xi(e) {
|
|
516
|
+
const t = b(e.type)?.joinUrl;
|
|
505
517
|
return t ? t(e) : void 0;
|
|
506
518
|
}
|
|
507
|
-
function
|
|
519
|
+
function X(e, t) {
|
|
508
520
|
let n = e;
|
|
509
521
|
for (const r of t.split(".")) {
|
|
510
522
|
if (n == null || typeof n != "object") return "";
|
|
@@ -512,44 +524,44 @@ function j(e, t) {
|
|
|
512
524
|
}
|
|
513
525
|
return n == null ? "" : typeof n == "string" ? n : typeof n == "number" || typeof n == "boolean" ? String(n) : "";
|
|
514
526
|
}
|
|
515
|
-
function
|
|
527
|
+
function Y(e, t, n) {
|
|
516
528
|
if (e === void 0) return null;
|
|
517
529
|
if (typeof e == "string") return e || null;
|
|
518
530
|
if ("value" in e)
|
|
519
|
-
return
|
|
531
|
+
return X(t, e.value) || null;
|
|
520
532
|
const r = {};
|
|
521
533
|
for (const [o, a] of Object.entries(e.params ?? {}))
|
|
522
|
-
r[o] =
|
|
534
|
+
r[o] = X(t, a);
|
|
523
535
|
const i = n(e.key, r);
|
|
524
536
|
return i === e.key ? null : i;
|
|
525
537
|
}
|
|
526
|
-
function
|
|
538
|
+
function Tt(e, t) {
|
|
527
539
|
if (!e || typeof e == "string" || "value" in e) return null;
|
|
528
540
|
const n = {};
|
|
529
541
|
for (const [r, i] of Object.entries(e.params ?? {}))
|
|
530
|
-
n[r] =
|
|
542
|
+
n[r] = X(t, i);
|
|
531
543
|
return { key: e.key, params: n };
|
|
532
544
|
}
|
|
533
|
-
const
|
|
534
|
-
function
|
|
545
|
+
const ue = 140;
|
|
546
|
+
function wt(e) {
|
|
535
547
|
const t = e.trim();
|
|
536
|
-
return t.length <=
|
|
548
|
+
return t.length <= ue ? t : `${t.slice(0, ue - 1).trimEnd()}…`;
|
|
537
549
|
}
|
|
538
|
-
function
|
|
539
|
-
const n =
|
|
550
|
+
function Ni(e, t) {
|
|
551
|
+
const n = Tt(t?.text, e), r = t ? Y(t.text, e, (i) => i) : null;
|
|
540
552
|
return {
|
|
541
553
|
activityId: e.id,
|
|
542
554
|
type: e.type,
|
|
543
|
-
snippet:
|
|
555
|
+
snippet: wt(r ?? _t(e)),
|
|
544
556
|
authorName: e.author?.name ?? "",
|
|
545
557
|
direction: e.direction,
|
|
546
558
|
createdAt: e.createdAt ?? Date.now(),
|
|
547
559
|
...n ? { snippetKey: n.key, snippetParams: n.params } : {}
|
|
548
560
|
};
|
|
549
561
|
}
|
|
550
|
-
const
|
|
551
|
-
function
|
|
552
|
-
const t =
|
|
562
|
+
const It = (e) => e;
|
|
563
|
+
function de(e) {
|
|
564
|
+
const t = _[e];
|
|
553
565
|
return {
|
|
554
566
|
type: e,
|
|
555
567
|
shape: t.shape,
|
|
@@ -564,7 +576,7 @@ function Y(e) {
|
|
|
564
576
|
displayNameKey: t.displayNameKey
|
|
565
577
|
};
|
|
566
578
|
}
|
|
567
|
-
function
|
|
579
|
+
function pe(e) {
|
|
568
580
|
return {
|
|
569
581
|
type: e.type,
|
|
570
582
|
shape: e.shape,
|
|
@@ -579,21 +591,21 @@ function q(e) {
|
|
|
579
591
|
displayNameKey: e.displayNameKey
|
|
580
592
|
};
|
|
581
593
|
}
|
|
582
|
-
class
|
|
583
|
-
constructor(t = [], n =
|
|
594
|
+
class Mt {
|
|
595
|
+
constructor(t = [], n = It) {
|
|
584
596
|
this.translate = n;
|
|
585
597
|
for (const r of t)
|
|
586
|
-
r?.type && (r.type in
|
|
598
|
+
r?.type && (r.type in _ || this.declared.has(r.type) || this.declared.set(r.type, r));
|
|
587
599
|
}
|
|
588
600
|
declared = /* @__PURE__ */ new Map();
|
|
589
601
|
get(t) {
|
|
590
|
-
if (t in
|
|
602
|
+
if (t in _) return de(t);
|
|
591
603
|
const n = this.declared.get(t);
|
|
592
|
-
return n ?
|
|
604
|
+
return n ? pe(n) : void 0;
|
|
593
605
|
}
|
|
594
606
|
/** Everything that may be offered as a trigger, built-in and declared. */
|
|
595
607
|
triggerable() {
|
|
596
|
-
const t = Object.keys(
|
|
608
|
+
const t = Object.keys(_).filter((r) => _[r].triggerable).map(de), n = [...this.declared.values()].map(pe).filter((r) => r.triggerable);
|
|
597
609
|
return [...t, ...n];
|
|
598
610
|
}
|
|
599
611
|
/**
|
|
@@ -602,17 +614,17 @@ class rt {
|
|
|
602
614
|
* the feed always showed for unknown types.
|
|
603
615
|
*/
|
|
604
616
|
timelineText(t, n) {
|
|
605
|
-
const r =
|
|
617
|
+
const r = _[t.type];
|
|
606
618
|
if (r?.timeline) return r.timeline(t, n);
|
|
607
619
|
const i = this.declared.get(t.type);
|
|
608
|
-
return
|
|
620
|
+
return Y(i?.text, t, this.translate) ?? t.type.replace(/_/g, " ").toLowerCase();
|
|
609
621
|
}
|
|
610
622
|
/** The line for the inbox list. Empty when the type has nothing to show. */
|
|
611
623
|
snippet(t) {
|
|
612
|
-
const n =
|
|
624
|
+
const n = _[t.type];
|
|
613
625
|
if (n?.snippet) return n.snippet(t);
|
|
614
626
|
const r = this.declared.get(t.type);
|
|
615
|
-
return
|
|
627
|
+
return Y(r?.text, t, this.translate) ?? "";
|
|
616
628
|
}
|
|
617
629
|
/** The descriptor as it arrived; needed to store `text` as a key. */
|
|
618
630
|
descriptor(t) {
|
|
@@ -637,11 +649,11 @@ class rt {
|
|
|
637
649
|
* {@link ResolvedActivityType}.
|
|
638
650
|
*/
|
|
639
651
|
isMessage(t) {
|
|
640
|
-
return
|
|
652
|
+
return Be(this.get(t)?.shape);
|
|
641
653
|
}
|
|
642
654
|
/** Folds into the list under the message it answers. See {@link isNoteShape}. */
|
|
643
655
|
nestsUnderParent(t) {
|
|
644
|
-
return
|
|
656
|
+
return je(this.get(t)?.shape);
|
|
645
657
|
}
|
|
646
658
|
/** Can a person reply to this? Notes cannot — those go nowhere. */
|
|
647
659
|
isReplyable(t) {
|
|
@@ -669,23 +681,23 @@ class rt {
|
|
|
669
681
|
return this.translate;
|
|
670
682
|
}
|
|
671
683
|
}
|
|
672
|
-
const
|
|
673
|
-
function
|
|
684
|
+
const Ri = new Mt();
|
|
685
|
+
function Di(e, t, n = []) {
|
|
674
686
|
const r = e.createdAt;
|
|
675
687
|
if (!r) return [];
|
|
676
688
|
const i = new Set(n);
|
|
677
689
|
return e.author.type === "user" && e.author.id && i.add(e.author.id), Object.entries(t).filter(([o, a]) => a >= r && !i.has(o)).map(([o]) => o);
|
|
678
690
|
}
|
|
679
|
-
function
|
|
691
|
+
function Ot(e) {
|
|
680
692
|
return e.createdAt ?? 0;
|
|
681
693
|
}
|
|
682
|
-
function
|
|
694
|
+
function $i(e) {
|
|
683
695
|
return e.type === "EMAIL_RECEIVED" || e.type === "EMAIL_SENT";
|
|
684
696
|
}
|
|
685
|
-
function
|
|
697
|
+
function Li(e) {
|
|
686
698
|
return e.type === "CHAT_MESSAGE_SENT" || e.type === "CHAT_MESSAGE_RECEIVED";
|
|
687
699
|
}
|
|
688
|
-
const
|
|
700
|
+
const He = [
|
|
689
701
|
{
|
|
690
702
|
id: "openai",
|
|
691
703
|
attachmentKinds: ["image", "pdf"],
|
|
@@ -775,45 +787,45 @@ const we = [
|
|
|
775
787
|
defaultModel: "default"
|
|
776
788
|
}
|
|
777
789
|
];
|
|
778
|
-
function
|
|
779
|
-
return
|
|
790
|
+
function K(e) {
|
|
791
|
+
return He.find((t) => t.id === e);
|
|
780
792
|
}
|
|
781
|
-
function
|
|
782
|
-
return
|
|
793
|
+
function Pi(e) {
|
|
794
|
+
return K(e)?.label ?? e;
|
|
783
795
|
}
|
|
784
|
-
function
|
|
785
|
-
return
|
|
796
|
+
function Ui(e, t = "gpt-5-mini") {
|
|
797
|
+
return K(e)?.defaultModel ?? t;
|
|
786
798
|
}
|
|
787
|
-
function
|
|
788
|
-
return
|
|
799
|
+
function Ki(e) {
|
|
800
|
+
return He.filter((t) => t.capabilities.includes(e));
|
|
789
801
|
}
|
|
790
|
-
function
|
|
791
|
-
const t =
|
|
802
|
+
function Bi(e) {
|
|
803
|
+
const t = K(e);
|
|
792
804
|
return !!t && !t.baseUrl;
|
|
793
805
|
}
|
|
794
|
-
function
|
|
795
|
-
return t === "text" ? !0 :
|
|
806
|
+
function ji(e, t) {
|
|
807
|
+
return t === "text" ? !0 : K(e)?.attachmentKinds?.includes(t) === !0;
|
|
796
808
|
}
|
|
797
|
-
function
|
|
809
|
+
function Hi(e, t) {
|
|
798
810
|
if (!e.enabled) return "ok";
|
|
799
|
-
const n =
|
|
811
|
+
const n = fe(e.hardLimitNanos), r = fe(e.softLimitNanos);
|
|
800
812
|
return n !== void 0 && t >= n ? "hard" : r !== void 0 && t >= r ? "soft" : "ok";
|
|
801
813
|
}
|
|
802
|
-
function
|
|
814
|
+
function fe(e) {
|
|
803
815
|
return typeof e == "number" ? e : void 0;
|
|
804
816
|
}
|
|
805
|
-
function
|
|
817
|
+
function Ct(e, t = "month") {
|
|
806
818
|
const n = new Date(e);
|
|
807
819
|
return Date.UTC(n.getUTCFullYear(), n.getUTCMonth(), 1);
|
|
808
820
|
}
|
|
809
|
-
function
|
|
810
|
-
const n = new Date(
|
|
821
|
+
function Gi(e, t = "month") {
|
|
822
|
+
const n = new Date(Ct(e, t));
|
|
811
823
|
return `${n.getUTCFullYear()}-${String(n.getUTCMonth() + 1).padStart(2, "0")}`;
|
|
812
824
|
}
|
|
813
|
-
function
|
|
825
|
+
function Fi(e) {
|
|
814
826
|
return e?.listeningEnabled !== !1;
|
|
815
827
|
}
|
|
816
|
-
const
|
|
828
|
+
const Wi = [
|
|
817
829
|
{ id: "agent", label: "Agent", labelSource: "user" },
|
|
818
830
|
{ id: "team", label: "Team", labelSource: "team" },
|
|
819
831
|
{ id: "inbox", label: "Inbox", labelSource: "inbox" },
|
|
@@ -823,47 +835,47 @@ const fi = [
|
|
|
823
835
|
{ id: "handledBy", label: "Afhandelaar", labelSource: "raw" },
|
|
824
836
|
{ id: "time", label: "Tijd", labelSource: "raw" }
|
|
825
837
|
];
|
|
826
|
-
function
|
|
838
|
+
function G(e) {
|
|
827
839
|
return e < 10 ? `0${e}` : `${e}`;
|
|
828
840
|
}
|
|
829
|
-
function
|
|
830
|
-
const n = new Date(e), r = `${n.getUTCFullYear()}-${
|
|
831
|
-
return t === "day" ? r : `${r}T${
|
|
841
|
+
function kt(e, t) {
|
|
842
|
+
const n = new Date(e), r = `${n.getUTCFullYear()}-${G(n.getUTCMonth() + 1)}-${G(n.getUTCDate())}`;
|
|
843
|
+
return t === "day" ? r : `${r}T${G(n.getUTCHours())}`;
|
|
832
844
|
}
|
|
833
|
-
function
|
|
845
|
+
function vt(e, t) {
|
|
834
846
|
const n = new Date(e);
|
|
835
847
|
return n.setUTCMinutes(0, 0, 0), t === "day" && n.setUTCHours(0), n.getTime();
|
|
836
848
|
}
|
|
837
|
-
const
|
|
838
|
-
function
|
|
839
|
-
const r = n === "hour" ?
|
|
840
|
-
for (let o =
|
|
841
|
-
i.push(
|
|
849
|
+
const xt = 36e5, Nt = 864e5;
|
|
850
|
+
function Vi(e, t, n) {
|
|
851
|
+
const r = n === "hour" ? xt : Nt, i = [];
|
|
852
|
+
for (let o = vt(e, n); o <= t; o += r)
|
|
853
|
+
i.push(kt(o, n));
|
|
842
854
|
return i;
|
|
843
855
|
}
|
|
844
|
-
const
|
|
856
|
+
const Rt = [
|
|
845
857
|
{ id: "resource", label: "Resource", labelSource: "raw" },
|
|
846
858
|
{ id: "origin", label: "Herkomst", labelSource: "raw" }
|
|
847
|
-
],
|
|
848
|
-
function
|
|
859
|
+
], Dt = Rt.map((e) => e.id);
|
|
860
|
+
function $t(e, t) {
|
|
849
861
|
return `${e}.usage.${t}`;
|
|
850
862
|
}
|
|
851
|
-
function
|
|
863
|
+
function zi(e, t) {
|
|
852
864
|
return t.map((n) => ({
|
|
853
|
-
id:
|
|
865
|
+
id: $t(e, n.unit),
|
|
854
866
|
label: n.label,
|
|
855
867
|
category: "Verbruik",
|
|
856
868
|
valueType: n.valueType ?? "count",
|
|
857
869
|
aggregation: "sum",
|
|
858
870
|
supportedDimensions: [
|
|
859
871
|
"provider",
|
|
860
|
-
...
|
|
872
|
+
...Dt,
|
|
861
873
|
...n.extraDimensions ?? [],
|
|
862
874
|
"time"
|
|
863
875
|
]
|
|
864
876
|
}));
|
|
865
877
|
}
|
|
866
|
-
const
|
|
878
|
+
const Ge = /* @__PURE__ */ new Set(["info", "success", "warning", "destructive"]), me = 200, ge = 100, he = 200, ye = 12, be = 4, Fe = 4e3, F = 500, Xi = 256 * 1024, Lt = /* @__PURE__ */ new Set([
|
|
867
879
|
"heading",
|
|
868
880
|
"paragraph",
|
|
869
881
|
"list",
|
|
@@ -873,15 +885,15 @@ const Ie = /* @__PURE__ */ new Set(["info", "success", "warning", "destructive"]
|
|
|
873
885
|
"table",
|
|
874
886
|
"kpi",
|
|
875
887
|
"callout"
|
|
876
|
-
]),
|
|
877
|
-
function
|
|
888
|
+
]), Pt = ["http:", "https:", "mailto:", "tel:"], Ut = /^[a-z][a-z0-9+.-]*:/i;
|
|
889
|
+
function We(e) {
|
|
878
890
|
const t = e.trim().replace(/^<|>$/g, "");
|
|
879
891
|
if (!t) return !1;
|
|
880
|
-
const n =
|
|
881
|
-
return n ?
|
|
892
|
+
const n = Ut.exec(t)?.[0];
|
|
893
|
+
return n ? Pt.includes(n.toLowerCase()) : !t.startsWith("//");
|
|
882
894
|
}
|
|
883
|
-
const
|
|
884
|
-
function
|
|
895
|
+
const Kt = /^[ \t]{0,3}\[([^\]]+)\]:[ \t]*(\S+).*$/gm;
|
|
896
|
+
function Bt(e) {
|
|
885
897
|
let t = "", n = 0;
|
|
886
898
|
for (; n < e.length; ) {
|
|
887
899
|
const r = e[n] === "!" && e[n + 1] === "[";
|
|
@@ -889,22 +901,22 @@ function yt(e) {
|
|
|
889
901
|
t += e[n], n += 1;
|
|
890
902
|
continue;
|
|
891
903
|
}
|
|
892
|
-
const i = n + (r ? 2 : 1), o =
|
|
904
|
+
const i = n + (r ? 2 : 1), o = Ae(e, i, "[", "]");
|
|
893
905
|
if (o < 0 || e[o + 1] !== "(") {
|
|
894
906
|
t += e[n], n += 1;
|
|
895
907
|
continue;
|
|
896
908
|
}
|
|
897
|
-
const a =
|
|
909
|
+
const a = Ae(e, o + 2, "(", ")");
|
|
898
910
|
if (a < 0) {
|
|
899
911
|
t += e[n], n += 1;
|
|
900
912
|
continue;
|
|
901
913
|
}
|
|
902
|
-
const s = e.slice(i, o),
|
|
903
|
-
t += r || !
|
|
914
|
+
const s = e.slice(i, o), c = e.slice(o + 2, a).trim().split(/\s+/)[0] ?? "";
|
|
915
|
+
t += r || !We(c) ? s : e.slice(n, a + 1), n = a + 1;
|
|
904
916
|
}
|
|
905
917
|
return t;
|
|
906
918
|
}
|
|
907
|
-
function
|
|
919
|
+
function Ae(e, t, n, r) {
|
|
908
920
|
let i = 1;
|
|
909
921
|
for (let o = t; o < e.length; o += 1) {
|
|
910
922
|
if (e[o] === "\\") {
|
|
@@ -917,40 +929,40 @@ function re(e, t, n, r) {
|
|
|
917
929
|
}
|
|
918
930
|
return -1;
|
|
919
931
|
}
|
|
920
|
-
function
|
|
921
|
-
return
|
|
922
|
-
|
|
923
|
-
(t, n, r) =>
|
|
932
|
+
function jt(e) {
|
|
933
|
+
return Bt(e).replace(
|
|
934
|
+
Kt,
|
|
935
|
+
(t, n, r) => We(r) ? t : ""
|
|
924
936
|
);
|
|
925
937
|
}
|
|
926
|
-
function
|
|
927
|
-
return typeof e == "string" ?
|
|
938
|
+
function A(e, t = Fe) {
|
|
939
|
+
return typeof e == "string" ? jt(e).slice(0, t) : "";
|
|
928
940
|
}
|
|
929
|
-
function
|
|
941
|
+
function Ht(e, t = Fe) {
|
|
930
942
|
return typeof e == "string" ? e.slice(0, t) : "";
|
|
931
943
|
}
|
|
932
|
-
function
|
|
933
|
-
return typeof e == "string" &&
|
|
944
|
+
function Gt(e, t = "info") {
|
|
945
|
+
return typeof e == "string" && Ge.has(e) ? e : t;
|
|
934
946
|
}
|
|
935
|
-
function
|
|
947
|
+
function Yi(e, t = () => {
|
|
936
948
|
}) {
|
|
937
949
|
if (!Array.isArray(e)) return [];
|
|
938
950
|
const n = [];
|
|
939
951
|
for (const r of e) {
|
|
940
|
-
if (n.length >=
|
|
941
|
-
t(`more than ${
|
|
952
|
+
if (n.length >= me) {
|
|
953
|
+
t(`more than ${me} blocks; the rest was dropped`);
|
|
942
954
|
break;
|
|
943
955
|
}
|
|
944
956
|
if (!r || typeof r != "object") continue;
|
|
945
957
|
const i = r;
|
|
946
|
-
if (!
|
|
958
|
+
if (!Lt.has(i.type)) {
|
|
947
959
|
t(`unknown block type ${String(i.type)}`);
|
|
948
960
|
continue;
|
|
949
961
|
}
|
|
950
962
|
const o = typeof i.block_id == "string" ? { block_id: i.block_id } : {};
|
|
951
963
|
switch (i.type) {
|
|
952
964
|
case "heading": {
|
|
953
|
-
const a =
|
|
965
|
+
const a = A(i.text);
|
|
954
966
|
if (!a) {
|
|
955
967
|
t("a heading without text");
|
|
956
968
|
continue;
|
|
@@ -960,7 +972,7 @@ function yi(e, t = () => {
|
|
|
960
972
|
break;
|
|
961
973
|
}
|
|
962
974
|
case "paragraph": {
|
|
963
|
-
const a =
|
|
975
|
+
const a = A(i.text);
|
|
964
976
|
if (!a) {
|
|
965
977
|
t("a paragraph without text");
|
|
966
978
|
continue;
|
|
@@ -969,7 +981,7 @@ function yi(e, t = () => {
|
|
|
969
981
|
break;
|
|
970
982
|
}
|
|
971
983
|
case "quote": {
|
|
972
|
-
const a =
|
|
984
|
+
const a = A(i.text);
|
|
973
985
|
if (!a) {
|
|
974
986
|
t("a quote without text");
|
|
975
987
|
continue;
|
|
@@ -978,7 +990,7 @@ function yi(e, t = () => {
|
|
|
978
990
|
break;
|
|
979
991
|
}
|
|
980
992
|
case "code": {
|
|
981
|
-
const a =
|
|
993
|
+
const a = Ht(i.text);
|
|
982
994
|
if (!a) {
|
|
983
995
|
t("a code block without text");
|
|
984
996
|
continue;
|
|
@@ -992,69 +1004,69 @@ function yi(e, t = () => {
|
|
|
992
1004
|
break;
|
|
993
1005
|
case "list": {
|
|
994
1006
|
const a = Array.isArray(i.items) ? i.items : [], s = [];
|
|
995
|
-
for (const
|
|
996
|
-
if (s.length >=
|
|
997
|
-
t(`more than ${
|
|
1007
|
+
for (const m of a) {
|
|
1008
|
+
if (s.length >= ge) {
|
|
1009
|
+
t(`more than ${ge} list items`);
|
|
998
1010
|
break;
|
|
999
1011
|
}
|
|
1000
|
-
const
|
|
1001
|
-
if (!
|
|
1002
|
-
const
|
|
1003
|
-
s.push(
|
|
1012
|
+
const h = A(m?.text);
|
|
1013
|
+
if (!h) continue;
|
|
1014
|
+
const y = A(m?.lead, 200);
|
|
1015
|
+
s.push(y ? { lead: y, text: h } : { text: h });
|
|
1004
1016
|
}
|
|
1005
1017
|
if (s.length === 0) {
|
|
1006
1018
|
t("a list without usable items");
|
|
1007
1019
|
continue;
|
|
1008
1020
|
}
|
|
1009
|
-
const
|
|
1010
|
-
n.push({ ...o, type: "list", style:
|
|
1021
|
+
const c = i.style === "numbered" ? "numbered" : "bulleted";
|
|
1022
|
+
n.push({ ...o, type: "list", style: c, items: s });
|
|
1011
1023
|
break;
|
|
1012
1024
|
}
|
|
1013
1025
|
case "table": {
|
|
1014
1026
|
const a = Array.isArray(i.columns) ? i.columns : [], s = [];
|
|
1015
|
-
for (const
|
|
1016
|
-
if (s.length >=
|
|
1017
|
-
t(`more than ${
|
|
1027
|
+
for (const y of a) {
|
|
1028
|
+
if (s.length >= ye) {
|
|
1029
|
+
t(`more than ${ye} table columns`);
|
|
1018
1030
|
break;
|
|
1019
1031
|
}
|
|
1020
|
-
const
|
|
1021
|
-
s.push(
|
|
1032
|
+
const T = A(y?.label, F), M = y?.align === "right" ? "right" : void 0;
|
|
1033
|
+
s.push(M ? { label: T, align: M } : { label: T });
|
|
1022
1034
|
}
|
|
1023
1035
|
if (s.length === 0) {
|
|
1024
1036
|
t("a table without columns");
|
|
1025
1037
|
continue;
|
|
1026
1038
|
}
|
|
1027
|
-
const
|
|
1028
|
-
for (const
|
|
1029
|
-
if (
|
|
1030
|
-
t(`more than ${
|
|
1039
|
+
const c = Array.isArray(i.rows) ? i.rows : [], m = [];
|
|
1040
|
+
for (const y of c) {
|
|
1041
|
+
if (m.length >= he) {
|
|
1042
|
+
t(`more than ${he} table rows`);
|
|
1031
1043
|
break;
|
|
1032
1044
|
}
|
|
1033
|
-
const
|
|
1034
|
-
|
|
1045
|
+
const T = Array.isArray(y) ? y : [];
|
|
1046
|
+
m.push(s.map((M, B) => A(T[B], F)));
|
|
1035
1047
|
}
|
|
1036
|
-
const
|
|
1048
|
+
const h = A(i.caption, F);
|
|
1037
1049
|
n.push({
|
|
1038
1050
|
...o,
|
|
1039
1051
|
type: "table",
|
|
1040
1052
|
columns: s,
|
|
1041
|
-
rows:
|
|
1042
|
-
...
|
|
1053
|
+
rows: m,
|
|
1054
|
+
...h ? { caption: h } : {}
|
|
1043
1055
|
});
|
|
1044
1056
|
break;
|
|
1045
1057
|
}
|
|
1046
1058
|
case "kpi": {
|
|
1047
1059
|
const a = Array.isArray(i.items) ? i.items : [], s = [];
|
|
1048
|
-
for (const
|
|
1049
|
-
if (s.length >=
|
|
1050
|
-
t(`more than ${
|
|
1060
|
+
for (const c of a) {
|
|
1061
|
+
if (s.length >= be) {
|
|
1062
|
+
t(`more than ${be} kpi items`);
|
|
1051
1063
|
break;
|
|
1052
1064
|
}
|
|
1053
|
-
const
|
|
1054
|
-
if (!
|
|
1055
|
-
const
|
|
1065
|
+
const m = A(c?.value, 40), h = A(c?.label, 80);
|
|
1066
|
+
if (!m || !h) continue;
|
|
1067
|
+
const y = c?.tone;
|
|
1056
1068
|
s.push(
|
|
1057
|
-
typeof
|
|
1069
|
+
typeof y == "string" && Ge.has(y) ? { value: m, label: h, tone: y } : { value: m, label: h }
|
|
1058
1070
|
);
|
|
1059
1071
|
}
|
|
1060
1072
|
if (s.length === 0) {
|
|
@@ -1065,16 +1077,16 @@ function yi(e, t = () => {
|
|
|
1065
1077
|
break;
|
|
1066
1078
|
}
|
|
1067
1079
|
case "callout": {
|
|
1068
|
-
const a =
|
|
1080
|
+
const a = A(i.text);
|
|
1069
1081
|
if (!a) {
|
|
1070
1082
|
t("a callout without text");
|
|
1071
1083
|
continue;
|
|
1072
1084
|
}
|
|
1073
|
-
const s =
|
|
1085
|
+
const s = A(i.title, 200);
|
|
1074
1086
|
n.push({
|
|
1075
1087
|
...o,
|
|
1076
1088
|
type: "callout",
|
|
1077
|
-
tone:
|
|
1089
|
+
tone: Gt(i.tone),
|
|
1078
1090
|
...s ? { title: s } : {},
|
|
1079
1091
|
text: a
|
|
1080
1092
|
});
|
|
@@ -1084,28 +1096,28 @@ function yi(e, t = () => {
|
|
|
1084
1096
|
}
|
|
1085
1097
|
return n;
|
|
1086
1098
|
}
|
|
1087
|
-
function
|
|
1099
|
+
function qi(e) {
|
|
1088
1100
|
return JSON.stringify(e).length;
|
|
1089
1101
|
}
|
|
1090
|
-
function
|
|
1102
|
+
function Ji(e) {
|
|
1091
1103
|
return {
|
|
1092
1104
|
blocks: e.length,
|
|
1093
1105
|
types: e.map((t) => t.type),
|
|
1094
1106
|
headings: e.flatMap((t) => t.type === "heading" ? [t.text] : [])
|
|
1095
1107
|
};
|
|
1096
1108
|
}
|
|
1097
|
-
function
|
|
1109
|
+
function Ee(e) {
|
|
1098
1110
|
return e.replace(/\|/g, "\\|").replace(/\r?\n/g, " ").trim();
|
|
1099
1111
|
}
|
|
1100
|
-
function
|
|
1112
|
+
function Se(e, t, n) {
|
|
1101
1113
|
const r = e.map((i, o) => n?.[o] === "right" ? "---:" : "---");
|
|
1102
1114
|
return [
|
|
1103
|
-
`| ${e.map(
|
|
1115
|
+
`| ${e.map(Ee).join(" | ")} |`,
|
|
1104
1116
|
`| ${r.join(" | ")} |`,
|
|
1105
|
-
...t.map((i) => `| ${i.map(
|
|
1117
|
+
...t.map((i) => `| ${i.map(Ee).join(" | ")} |`)
|
|
1106
1118
|
];
|
|
1107
1119
|
}
|
|
1108
|
-
function
|
|
1120
|
+
function Ft(e) {
|
|
1109
1121
|
switch (e.type) {
|
|
1110
1122
|
case "heading":
|
|
1111
1123
|
return [`${"#".repeat(e.level)} ${e.text}`];
|
|
@@ -1123,7 +1135,7 @@ function St(e) {
|
|
|
1123
1135
|
return t.lead ? `${r} **${t.lead}** ${t.text}` : `${r} ${t.text}`;
|
|
1124
1136
|
});
|
|
1125
1137
|
case "table": {
|
|
1126
|
-
const t =
|
|
1138
|
+
const t = Se(
|
|
1127
1139
|
e.columns.map((n) => n.label),
|
|
1128
1140
|
e.rows,
|
|
1129
1141
|
e.columns.map((n) => n.align ?? "left")
|
|
@@ -1131,7 +1143,7 @@ function St(e) {
|
|
|
1131
1143
|
return e.caption ? [...t, "", `*${e.caption}*`] : t;
|
|
1132
1144
|
}
|
|
1133
1145
|
case "kpi":
|
|
1134
|
-
return
|
|
1146
|
+
return Se(
|
|
1135
1147
|
e.items.map((t) => t.value),
|
|
1136
1148
|
[e.items.map((t) => t.label)]
|
|
1137
1149
|
);
|
|
@@ -1139,11 +1151,11 @@ function St(e) {
|
|
|
1139
1151
|
return (e.title ? `**${e.title}** ${e.text}` : e.text).split(/\r?\n/).map((n) => `> ${n}`);
|
|
1140
1152
|
}
|
|
1141
1153
|
}
|
|
1142
|
-
function
|
|
1154
|
+
function Zi(e, t) {
|
|
1143
1155
|
const n = [], r = e.some((i) => i.type === "heading" && i.level === 1);
|
|
1144
1156
|
t && !r && n.push(`# ${t}`);
|
|
1145
1157
|
for (const i of e) {
|
|
1146
|
-
const o =
|
|
1158
|
+
const o = Ft(i);
|
|
1147
1159
|
o.length > 0 && n.push(o.join(`
|
|
1148
1160
|
`));
|
|
1149
1161
|
}
|
|
@@ -1152,41 +1164,45 @@ function Ei(e, t) {
|
|
|
1152
1164
|
`)}
|
|
1153
1165
|
`;
|
|
1154
1166
|
}
|
|
1155
|
-
const
|
|
1156
|
-
function
|
|
1167
|
+
const Ve = (e) => `user:${e}`, ze = (e) => `team:${e}`;
|
|
1168
|
+
function Qi(e) {
|
|
1157
1169
|
const t = /* @__PURE__ */ new Set();
|
|
1158
1170
|
for (const n of e ?? [])
|
|
1159
|
-
n?.id && (n.kind === "user" && t.add(
|
|
1171
|
+
n?.id && (n.kind === "user" && t.add(Ve(n.id)), n.kind === "team" && t.add(ze(n.id)));
|
|
1160
1172
|
return [...t].sort();
|
|
1161
1173
|
}
|
|
1162
|
-
function
|
|
1163
|
-
return [
|
|
1174
|
+
function eo(e, t) {
|
|
1175
|
+
return [Ve(e), ...t.map(ze)];
|
|
1164
1176
|
}
|
|
1165
|
-
function
|
|
1177
|
+
function to(e) {
|
|
1166
1178
|
const t = /* @__PURE__ */ new Set();
|
|
1167
1179
|
for (const n of e ?? [])
|
|
1168
1180
|
n?.kind && t.add(n.kind);
|
|
1169
1181
|
return [...t];
|
|
1170
1182
|
}
|
|
1171
|
-
const
|
|
1172
|
-
function
|
|
1173
|
-
return
|
|
1183
|
+
const Wt = ["done", "escalated"], no = ["open", "waiting"];
|
|
1184
|
+
function ro(e) {
|
|
1185
|
+
return Wt.includes(e);
|
|
1174
1186
|
}
|
|
1175
|
-
const
|
|
1176
|
-
function
|
|
1177
|
-
return `${
|
|
1187
|
+
const Vt = "assignment";
|
|
1188
|
+
function io(e) {
|
|
1189
|
+
return `${Vt}:${e}`;
|
|
1178
1190
|
}
|
|
1179
|
-
function
|
|
1191
|
+
function oo(e, t, n, r) {
|
|
1180
1192
|
if (e.direction === "inbound") return !0;
|
|
1181
1193
|
if (e.author?.type === "user" && e.author.id === t) return !1;
|
|
1182
|
-
const
|
|
1183
|
-
return Array.isArray(
|
|
1194
|
+
const i = e.payload?.mentions;
|
|
1195
|
+
return Array.isArray(i) && i.includes(t) || r && r === t ? !0 : n === "reply";
|
|
1184
1196
|
}
|
|
1185
|
-
function
|
|
1197
|
+
function ao(e) {
|
|
1198
|
+
const { targetAuthorId: t, reactorId: n, agentId: r, on: i } = e;
|
|
1199
|
+
return !i || !t || t !== r ? !1 : n !== r;
|
|
1200
|
+
}
|
|
1201
|
+
function so(e) {
|
|
1186
1202
|
return e.subjectKind && e.subjectId ? { type: e.subjectKind, id: e.subjectId } : void 0;
|
|
1187
1203
|
}
|
|
1188
|
-
const
|
|
1189
|
-
function
|
|
1204
|
+
const zt = 12;
|
|
1205
|
+
function co(e, t, n = zt) {
|
|
1190
1206
|
const r = t + 1;
|
|
1191
1207
|
return e ? e.kind === "done" ? { status: "done", waitingOn: null, turns: r, reason: e.note } : e.kind === "escalate" ? { status: "escalated", waitingOn: null, turns: r, reason: e.reason } : r >= n ? {
|
|
1192
1208
|
status: "escalated",
|
|
@@ -1200,39 +1216,39 @@ function Oi(e, t, n = wt) {
|
|
|
1200
1216
|
reason: "de agent rondde zijn beurt af zonder te zeggen wat er moet gebeuren (wachten, afronden of overdragen)"
|
|
1201
1217
|
};
|
|
1202
1218
|
}
|
|
1203
|
-
const
|
|
1204
|
-
function
|
|
1219
|
+
const lo = /* @__PURE__ */ new Set(["mail", "message"]);
|
|
1220
|
+
function Xt(e, t) {
|
|
1205
1221
|
const n = e.settings?.signatures?.[t];
|
|
1206
1222
|
return !n?.enabled || !n.body || n.body.trim() === "" ? null : n;
|
|
1207
1223
|
}
|
|
1208
|
-
function
|
|
1224
|
+
function uo(e, t, n, r = "html") {
|
|
1209
1225
|
if (!e) return n;
|
|
1210
|
-
const i =
|
|
1226
|
+
const i = Xt(e, t);
|
|
1211
1227
|
return i ? `${n}${r === "text" ? `
|
|
1212
1228
|
|
|
1213
1229
|
` : t === "mail" ? "<br><br>-- <br>" : "<br><br>"}${i.body}` : n;
|
|
1214
1230
|
}
|
|
1215
|
-
function
|
|
1231
|
+
function po(e) {
|
|
1216
1232
|
return e.endpoints ?? [];
|
|
1217
1233
|
}
|
|
1218
|
-
const
|
|
1234
|
+
const Yt = 36e5, qt = 864e5, w = -1 / 0, fo = (e) => e.score > w, P = {
|
|
1219
1235
|
urgent: 40,
|
|
1220
1236
|
high: 25,
|
|
1221
1237
|
normal: 10,
|
|
1222
1238
|
low: 0
|
|
1223
1239
|
};
|
|
1224
|
-
function
|
|
1240
|
+
function mo(e) {
|
|
1225
1241
|
return Object.fromEntries(e.map((t) => [t.resourceId, t]));
|
|
1226
1242
|
}
|
|
1227
|
-
const
|
|
1228
|
-
function
|
|
1229
|
-
return !!(e &&
|
|
1243
|
+
const Jt = /(^|[._+-])(no-?reply|noreply|donotreply|do-not-reply|newsletter|nieuwsbrief|mailer|mailing|notifications?|bounce|postmaster|marketing)@/i, Xe = /\b(unsubscribe|afmelden|uitschrijven|opt[\s-]?out|manage (your )?preferences|geen (e-?mails?|nieuwsbrief|berichten) meer)\b/i;
|
|
1244
|
+
function Zt(e, t) {
|
|
1245
|
+
return !!(e && Jt.test(e) || t && Xe.test(t));
|
|
1230
1246
|
}
|
|
1231
|
-
const
|
|
1232
|
-
function
|
|
1233
|
-
return e >=
|
|
1247
|
+
const Qt = 3, en = 600;
|
|
1248
|
+
function go(e, t) {
|
|
1249
|
+
return e >= Qt || t >= en;
|
|
1234
1250
|
}
|
|
1235
|
-
const
|
|
1251
|
+
const tn = [
|
|
1236
1252
|
"list-unsubscribe",
|
|
1237
1253
|
"list-unsubscribe-post",
|
|
1238
1254
|
"list-id",
|
|
@@ -1242,93 +1258,93 @@ const Nt = [
|
|
|
1242
1258
|
"feedback-id",
|
|
1243
1259
|
"x-mailer"
|
|
1244
1260
|
];
|
|
1245
|
-
function
|
|
1261
|
+
function ho(e) {
|
|
1246
1262
|
const t = {};
|
|
1247
1263
|
for (const n of e) {
|
|
1248
1264
|
const r = n.name?.toLowerCase();
|
|
1249
|
-
r && n.value !== void 0 &&
|
|
1265
|
+
r && n.value !== void 0 && tn.includes(r) && (t[r] = n.value);
|
|
1250
1266
|
}
|
|
1251
1267
|
return t;
|
|
1252
1268
|
}
|
|
1253
|
-
const
|
|
1254
|
-
function
|
|
1269
|
+
const nn = /(^|[._+-])(no-?reply|noreply|donotreply|do-not-reply|notifications?|bounce|postmaster|mailer)@/i, rn = /(^|[._+-])(newsletter|nieuwsbrief|marketing|mailing)@/i;
|
|
1270
|
+
function yo(e) {
|
|
1255
1271
|
const t = e.headers ?? {}, n = e.from?.email, r = t["auto-submitted"]?.toLowerCase();
|
|
1256
|
-
if (r && r !== "no" || t["x-auto-response-suppress"] || n &&
|
|
1272
|
+
if (r && r !== "no" || t["x-auto-response-suppress"] || n && nn.test(n))
|
|
1257
1273
|
return "automated";
|
|
1258
1274
|
const i = t.precedence?.toLowerCase();
|
|
1259
|
-
if (t["list-unsubscribe"] || t["list-unsubscribe-post"] || t["list-id"] || i === "bulk" || i === "list" || e.body &&
|
|
1275
|
+
if (t["list-unsubscribe"] || t["list-unsubscribe-post"] || t["list-id"] || i === "bulk" || i === "list" || e.body && Xe.test(e.body) || n && rn.test(n))
|
|
1260
1276
|
return "marketing";
|
|
1261
1277
|
}
|
|
1262
|
-
function
|
|
1278
|
+
function on(e, t) {
|
|
1263
1279
|
return e.lastActivityAt ? !(e.seenBy ?? []).includes(t) : !1;
|
|
1264
1280
|
}
|
|
1265
|
-
const
|
|
1281
|
+
const an = ["open"], sn = 1e3, cn = {
|
|
1266
1282
|
urgent: 1,
|
|
1267
1283
|
high: 4,
|
|
1268
1284
|
normal: 8,
|
|
1269
1285
|
low: 24
|
|
1270
|
-
},
|
|
1271
|
-
function
|
|
1272
|
-
return e.lastActivityAt ?? (e.createdAt ? new Date(
|
|
1286
|
+
}, ln = 72;
|
|
1287
|
+
function un(e) {
|
|
1288
|
+
return e.lastActivityAt ?? (e.createdAt ? new Date(Ot(e)).getTime() : 0);
|
|
1273
1289
|
}
|
|
1274
|
-
function
|
|
1275
|
-
return
|
|
1290
|
+
function dn(e, t) {
|
|
1291
|
+
return pn(t.remindersById?.[e.id], e, t.now);
|
|
1276
1292
|
}
|
|
1277
|
-
function
|
|
1293
|
+
function pn(e, t, n) {
|
|
1278
1294
|
return !e || e.remindAt <= n ? !1 : !((t.lastActivityAt ?? 0) > e.parkedAt && t.lastActivityPreview?.direction === "inbound");
|
|
1279
1295
|
}
|
|
1280
|
-
const
|
|
1281
|
-
function
|
|
1282
|
-
return Math.max(0, (t -
|
|
1296
|
+
const Ye = (e) => St(e) === "outbound_message", qe = (e) => an.includes(e);
|
|
1297
|
+
function te(e, t) {
|
|
1298
|
+
return Math.max(0, (t - un(e)) / Yt);
|
|
1283
1299
|
}
|
|
1284
|
-
function
|
|
1300
|
+
function fn(e, t) {
|
|
1285
1301
|
const n = e.assignedInboxId ? t?.[e.assignedInboxId] : void 0;
|
|
1286
|
-
return typeof n == "number" && n > 0 ? n :
|
|
1302
|
+
return typeof n == "number" && n > 0 ? n : cn[e.priority ?? "normal"];
|
|
1287
1303
|
}
|
|
1288
|
-
function
|
|
1304
|
+
function bo(e) {
|
|
1289
1305
|
const t = {};
|
|
1290
1306
|
for (const n of e)
|
|
1291
1307
|
typeof n.slaHours == "number" && n.slaHours > 0 && (t[n.id] = n.slaHours);
|
|
1292
1308
|
return t;
|
|
1293
1309
|
}
|
|
1294
|
-
function
|
|
1295
|
-
return !
|
|
1310
|
+
function Ao(e, t, n) {
|
|
1311
|
+
return !qe(e.status) || e.firstResponseAt ? !1 : te(e, t) > fn(e, n);
|
|
1296
1312
|
}
|
|
1297
|
-
function
|
|
1313
|
+
function mn(e, t) {
|
|
1298
1314
|
const n = e.lastActivityPreview;
|
|
1299
|
-
return n?.direction !== "outbound" || !
|
|
1315
|
+
return n?.direction !== "outbound" || !Ye(n.type) ? !1 : te(e, t) < ln;
|
|
1300
1316
|
}
|
|
1301
|
-
function
|
|
1302
|
-
if (!
|
|
1303
|
-
if (e.snoozedTill && e.snoozedTill > t.now) return { score:
|
|
1304
|
-
if (
|
|
1305
|
-
if (
|
|
1317
|
+
function Eo(e, t) {
|
|
1318
|
+
if (!qe(e.status)) return { score: w, reasons: [] };
|
|
1319
|
+
if (e.snoozedTill && e.snoozedTill > t.now) return { score: w, reasons: [] };
|
|
1320
|
+
if (mn(e, t.now)) return { score: w, reasons: [] };
|
|
1321
|
+
if (dn(e, t)) return { score: w, reasons: [] };
|
|
1306
1322
|
let n = 0;
|
|
1307
1323
|
const r = [], i = e.priority ?? "normal";
|
|
1308
|
-
|
|
1309
|
-
const o =
|
|
1324
|
+
P[i] > 0 && (n += P[i], r.push(`priority:${i}`)), on(e, t.userId) && (n += 20, r.push("unseen")), e.assignedUserId && e.assignedUserId === t.userId && (n += 15, r.push("assigned-to-you"));
|
|
1325
|
+
const o = te(e, t.now);
|
|
1310
1326
|
if (o > 0) {
|
|
1311
|
-
const
|
|
1312
|
-
n +=
|
|
1327
|
+
const c = Math.min(o * 2, 30);
|
|
1328
|
+
n += c, o >= 1 && r.push(`waiting:${Math.round(o)}h`);
|
|
1313
1329
|
}
|
|
1314
1330
|
const a = e.lastActivityPreview;
|
|
1315
|
-
return a?.type === "AI_ACTION_PROPOSED" && (n += 30, r.push("awaiting-approval")), a?.direction === "outbound" &&
|
|
1331
|
+
return a?.type === "AI_ACTION_PROPOSED" && (n += 30, r.push("awaiting-approval")), a?.direction === "outbound" && Ye(a.type) && (n += 10, r.push("no-reply")), !e.firstResponseAt && e.lastActivityPreview?.direction === "inbound" && (n += 10, r.push("awaiting-reply")), (e.tags?.some((c) => c === "marketing" || c === "automated") || Zt(e.remoteParty?.resource, e.lastActivityPreview?.snippet)) && (n -= sn, r.push("bulk")), { score: n, reasons: r };
|
|
1316
1332
|
}
|
|
1317
|
-
const
|
|
1333
|
+
const So = (e) => !!e.assignedUserId || !!e.assignedInboxId, _o = (e) => e.status === "closed", To = (e) => ({
|
|
1318
1334
|
urgent: 10,
|
|
1319
1335
|
high: 5,
|
|
1320
1336
|
normal: 2,
|
|
1321
1337
|
low: 1
|
|
1322
|
-
})[e.priority] || 0,
|
|
1323
|
-
function
|
|
1338
|
+
})[e.priority] || 0, wo = (e, t = 30) => e.title?.length <= t ? e.title : `${e.title.substring(0, t)}...`;
|
|
1339
|
+
function Io(e, t) {
|
|
1324
1340
|
const n = e.labels ?? [];
|
|
1325
1341
|
return n.find((r) => r.locale === t)?.label ?? n[0]?.label ?? e.url;
|
|
1326
1342
|
}
|
|
1327
|
-
function
|
|
1343
|
+
function Mo(e, t, n) {
|
|
1328
1344
|
const r = e.translations ?? [];
|
|
1329
1345
|
return r.find((i) => i.locale === t) ?? (n ? r.find((i) => i.locale === n) : void 0) ?? { locale: t };
|
|
1330
1346
|
}
|
|
1331
|
-
const
|
|
1347
|
+
const _e = [
|
|
1332
1348
|
{ code: "nl", label: "Nederlands", english: "Dutch" },
|
|
1333
1349
|
{ code: "en", label: "English", english: "English" },
|
|
1334
1350
|
{ code: "de", label: "Deutsch", english: "German" },
|
|
@@ -1343,36 +1359,36 @@ const ae = [
|
|
|
1343
1359
|
{ code: "fi", label: "Suomi", english: "Finnish" },
|
|
1344
1360
|
{ code: "tr", label: "Türkçe", english: "Turkish" }
|
|
1345
1361
|
];
|
|
1346
|
-
function
|
|
1362
|
+
function Je(e) {
|
|
1347
1363
|
const t = (e ?? "").toLowerCase();
|
|
1348
|
-
return
|
|
1364
|
+
return _e.find((n) => n.code === t) ?? _e.find((n) => n.code === t.split("-")[0]);
|
|
1349
1365
|
}
|
|
1350
|
-
function
|
|
1351
|
-
return
|
|
1366
|
+
function Oo(e) {
|
|
1367
|
+
return Je(e)?.label ?? e;
|
|
1352
1368
|
}
|
|
1353
|
-
function
|
|
1354
|
-
const t =
|
|
1369
|
+
function Co(e) {
|
|
1370
|
+
const t = Je(e);
|
|
1355
1371
|
return t ? t.english === t.label ? `${t.english} (${t.code})` : `${t.english} — ${t.label} (${t.code})` : e;
|
|
1356
1372
|
}
|
|
1357
|
-
const
|
|
1358
|
-
function
|
|
1373
|
+
const Ze = 3;
|
|
1374
|
+
function gn(e, t) {
|
|
1359
1375
|
const n = /* @__PURE__ */ new Set();
|
|
1360
1376
|
let r = 1, i = t.get(e)?.parentId;
|
|
1361
1377
|
for (; i; ) {
|
|
1362
|
-
if (n.has(i) || (n.add(i), r++, r >
|
|
1378
|
+
if (n.has(i) || (n.add(i), r++, r > Ze + 1)) return 1 / 0;
|
|
1363
1379
|
i = t.get(i)?.parentId;
|
|
1364
1380
|
}
|
|
1365
1381
|
return r;
|
|
1366
1382
|
}
|
|
1367
|
-
function
|
|
1383
|
+
function ko(e, t, n) {
|
|
1368
1384
|
if (!e) return !0;
|
|
1369
1385
|
if (e === t) return !1;
|
|
1370
1386
|
const r = new Map(n.map((a) => [a.id, a]));
|
|
1371
|
-
if (!r.has(e) || t &&
|
|
1372
|
-
const i =
|
|
1373
|
-
return i + o <=
|
|
1387
|
+
if (!r.has(e) || t && hn(e, t, r)) return !1;
|
|
1388
|
+
const i = gn(e, r), o = t ? Qe(t, n) : 1;
|
|
1389
|
+
return i + o <= Ze;
|
|
1374
1390
|
}
|
|
1375
|
-
function
|
|
1391
|
+
function hn(e, t, n) {
|
|
1376
1392
|
const r = /* @__PURE__ */ new Set();
|
|
1377
1393
|
let i = n.get(e)?.parentId;
|
|
1378
1394
|
for (; i; ) {
|
|
@@ -1382,44 +1398,44 @@ function Vt(e, t, n) {
|
|
|
1382
1398
|
}
|
|
1383
1399
|
return !1;
|
|
1384
1400
|
}
|
|
1385
|
-
function
|
|
1401
|
+
function Qe(e, t, n = /* @__PURE__ */ new Set()) {
|
|
1386
1402
|
if (n.has(e)) return 1;
|
|
1387
1403
|
n.add(e);
|
|
1388
1404
|
const r = t.filter((i) => i.parentId === e);
|
|
1389
|
-
return r.length ? 1 + Math.max(...r.map((i) =>
|
|
1405
|
+
return r.length ? 1 + Math.max(...r.map((i) => Qe(i.id, t, n))) : 1;
|
|
1390
1406
|
}
|
|
1391
|
-
const
|
|
1392
|
-
function
|
|
1393
|
-
return e.defaultLocale || e.locale ||
|
|
1407
|
+
const yn = "en";
|
|
1408
|
+
function bn(e) {
|
|
1409
|
+
return e.defaultLocale || e.locale || yn;
|
|
1394
1410
|
}
|
|
1395
|
-
function
|
|
1411
|
+
function vo(e) {
|
|
1396
1412
|
const t = /* @__PURE__ */ new Set(), n = [];
|
|
1397
|
-
for (const r of [
|
|
1413
|
+
for (const r of [bn(e), ...e.locales ?? []])
|
|
1398
1414
|
!r || t.has(r) || (t.add(r), n.push(r));
|
|
1399
1415
|
return n;
|
|
1400
1416
|
}
|
|
1401
|
-
function
|
|
1417
|
+
function xo(e, t, n) {
|
|
1402
1418
|
const r = e.translations ?? [];
|
|
1403
1419
|
return r.find((i) => i.locale === t)?.name ?? (n ? r.find((i) => i.locale === n)?.name : void 0) ?? e.name;
|
|
1404
1420
|
}
|
|
1405
|
-
const
|
|
1406
|
-
function
|
|
1421
|
+
const Te = ["lookup", "condition", "parallel", "for-each"];
|
|
1422
|
+
function we(e) {
|
|
1407
1423
|
for (const t of e) {
|
|
1408
|
-
if (!
|
|
1409
|
-
return `staptype "${t.type}" mag niet meelezen (alleen ${
|
|
1424
|
+
if (!Te.includes(t.type))
|
|
1425
|
+
return `staptype "${t.type}" mag niet meelezen (alleen ${Te.join(", ")})`;
|
|
1410
1426
|
if (t.type === "parallel")
|
|
1411
1427
|
for (const n of t.branches ?? []) {
|
|
1412
|
-
const r =
|
|
1428
|
+
const r = we(n);
|
|
1413
1429
|
if (r) return r;
|
|
1414
1430
|
}
|
|
1415
1431
|
if (t.type === "for-each") {
|
|
1416
|
-
const n =
|
|
1432
|
+
const n = we(t.body ?? []);
|
|
1417
1433
|
if (n) return n;
|
|
1418
1434
|
}
|
|
1419
1435
|
}
|
|
1420
1436
|
return null;
|
|
1421
1437
|
}
|
|
1422
|
-
function
|
|
1438
|
+
function An(e, t) {
|
|
1423
1439
|
switch (e.kind) {
|
|
1424
1440
|
case "org":
|
|
1425
1441
|
return !0;
|
|
@@ -1429,23 +1445,23 @@ function Yt(e, t) {
|
|
|
1429
1445
|
return e.userId === t.userId;
|
|
1430
1446
|
}
|
|
1431
1447
|
}
|
|
1432
|
-
function
|
|
1433
|
-
return e.filter((n) => n.enabled &&
|
|
1448
|
+
function No(e, t) {
|
|
1449
|
+
return e.filter((n) => n.enabled && An(n.ownerScope, t));
|
|
1434
1450
|
}
|
|
1435
|
-
function
|
|
1451
|
+
function Ro(e) {
|
|
1436
1452
|
return e.credentialScope ? e.credentialScope : (e.authMode ?? "header") === "header" || e.oauth?.scope === "org" ? "shared" : "per-user";
|
|
1437
1453
|
}
|
|
1438
|
-
function
|
|
1454
|
+
function Do(e) {
|
|
1439
1455
|
return `mcp__${e}__`;
|
|
1440
1456
|
}
|
|
1441
|
-
const
|
|
1442
|
-
function
|
|
1457
|
+
const $o = 1e3, Lo = 2e3, Po = 500, Uo = 12e3, Ko = 4e3, En = ["contact", "company", "work_item"];
|
|
1458
|
+
function Bo(e) {
|
|
1443
1459
|
if (!e) return !1;
|
|
1444
1460
|
const t = e.slice(0, e.indexOf(":"));
|
|
1445
|
-
return
|
|
1461
|
+
return En.includes(t);
|
|
1446
1462
|
}
|
|
1447
|
-
const
|
|
1448
|
-
function
|
|
1463
|
+
const jo = "onboarding-source", Ho = ["support", "billing", "availability", "sales", "onboarding"], Go = ["keep", "replace"];
|
|
1464
|
+
function Sn(e) {
|
|
1449
1465
|
switch (e.kind) {
|
|
1450
1466
|
case "user":
|
|
1451
1467
|
return `user:${e.userId}`;
|
|
@@ -1455,7 +1471,7 @@ function Jt(e) {
|
|
|
1455
1471
|
return "org";
|
|
1456
1472
|
}
|
|
1457
1473
|
}
|
|
1458
|
-
function
|
|
1474
|
+
function Fo(e) {
|
|
1459
1475
|
if (typeof e != "string") return;
|
|
1460
1476
|
const t = e.trim();
|
|
1461
1477
|
if (t === "org") return { kind: "org" };
|
|
@@ -1467,10 +1483,10 @@ function uo(e) {
|
|
|
1467
1483
|
if (r === "team") return { kind: "team", teamId: i };
|
|
1468
1484
|
}
|
|
1469
1485
|
}
|
|
1470
|
-
function
|
|
1471
|
-
return
|
|
1486
|
+
function _n(e) {
|
|
1487
|
+
return Sn(e);
|
|
1472
1488
|
}
|
|
1473
|
-
function
|
|
1489
|
+
function Tn(e) {
|
|
1474
1490
|
switch (e.kind) {
|
|
1475
1491
|
case "personal":
|
|
1476
1492
|
return { kind: "user", userId: e.userId };
|
|
@@ -1480,14 +1496,14 @@ function Qt(e) {
|
|
|
1480
1496
|
return { kind: "org" };
|
|
1481
1497
|
}
|
|
1482
1498
|
}
|
|
1483
|
-
const
|
|
1484
|
-
function
|
|
1485
|
-
return e.agentId ? { kind: "user", userId: e.agentId } :
|
|
1499
|
+
const wn = Tn;
|
|
1500
|
+
function Wo(e) {
|
|
1501
|
+
return e.agentId ? { kind: "user", userId: e.agentId } : wn(e.ownerScope);
|
|
1486
1502
|
}
|
|
1487
|
-
function
|
|
1488
|
-
return
|
|
1503
|
+
function Vo(e) {
|
|
1504
|
+
return _n(e);
|
|
1489
1505
|
}
|
|
1490
|
-
function
|
|
1506
|
+
function zo(e, t) {
|
|
1491
1507
|
if (!t) return;
|
|
1492
1508
|
let n = e;
|
|
1493
1509
|
for (const r of t.split(".")) {
|
|
@@ -1496,24 +1512,24 @@ function mo(e, t) {
|
|
|
1496
1512
|
}
|
|
1497
1513
|
return n;
|
|
1498
1514
|
}
|
|
1499
|
-
function
|
|
1515
|
+
function Xo(e, t) {
|
|
1500
1516
|
return e.targets.find((n) => n.activityTypes.includes(t));
|
|
1501
1517
|
}
|
|
1502
|
-
function
|
|
1518
|
+
function Yo(e, t) {
|
|
1503
1519
|
if (t)
|
|
1504
1520
|
return e.targets.find((n) => n.id === t);
|
|
1505
1521
|
}
|
|
1506
|
-
function
|
|
1522
|
+
function In(e) {
|
|
1507
1523
|
return e?.kind === "assignment";
|
|
1508
1524
|
}
|
|
1509
|
-
function
|
|
1525
|
+
function qo(e) {
|
|
1510
1526
|
const { trigger: t, agentId: n, target: r, activityType: i, assigneeUserId: o, authorUserId: a } = e;
|
|
1511
|
-
return
|
|
1527
|
+
return In(t) ? n ? r ? r.activityTypes.includes(i) ? o ? o !== n ? "assigned to someone else" : a && a === n ? "the agent assigned this to itself, which would restart its own run" : null : `no assignee found at ${r.assigneePath}` : `activity type ${i} does not announce an assignment for ${r.id}` : `assignment target kind "${t.targetKind}" is not declared by any installed app` : "this playbook has no agent, so an assignment can never be for it" : "trigger is not an assignment trigger";
|
|
1512
1528
|
}
|
|
1513
|
-
function
|
|
1529
|
+
function Jo(e) {
|
|
1514
1530
|
return (e.startsWith("tool:") ? e.slice(5) : e).replace(/__/g, " · ").replace(/\./g, " · ").replace(/_/g, " ");
|
|
1515
1531
|
}
|
|
1516
|
-
const
|
|
1532
|
+
const Zo = [
|
|
1517
1533
|
{ name: "text", type: "string" },
|
|
1518
1534
|
{ name: "subject", type: "string" },
|
|
1519
1535
|
{ name: "from", type: "string" },
|
|
@@ -1542,12 +1558,18 @@ const Ao = [
|
|
|
1542
1558
|
// message from a new address) — so a step leaning on this should carry a `condition`.
|
|
1543
1559
|
{ name: "contactId", type: "string" },
|
|
1544
1560
|
{ name: "companyId", type: "string" },
|
|
1561
|
+
// Properties of the conversation itself rather than of the activity, and filled from the same
|
|
1562
|
+
// read as contactId/companyId. Without these a rule like "inbox = Support and priority = high"
|
|
1563
|
+
// compares silently against `undefined` — it never fires and says nothing about why.
|
|
1564
|
+
{ name: "priority", type: "string" },
|
|
1565
|
+
{ name: "inboxId", type: "string" },
|
|
1566
|
+
{ name: "topicId", type: "string" },
|
|
1545
1567
|
// Who this work is assigned to, on an activity announcing an assignment. Where that sits on
|
|
1546
1568
|
// the activity is **declared** per source (`AssignmentTargetKind.assigneePath`), so
|
|
1547
1569
|
// `buildTriggerVars` cannot fill it itself: the job does that with the catalog in hand, before
|
|
1548
1570
|
// the trigger filter runs — like contactId/companyId above.
|
|
1549
1571
|
{ name: "assigneeUserId", type: "string" }
|
|
1550
|
-
],
|
|
1572
|
+
], Qo = {
|
|
1551
1573
|
topics: [
|
|
1552
1574
|
{ name: "topicId", type: "string" },
|
|
1553
1575
|
{ name: "topic", type: "string" },
|
|
@@ -1561,58 +1583,58 @@ const Ao = [
|
|
|
1561
1583
|
// Deliberately empty: the fields come from `ClassifyStep.fields` and so differ per step.
|
|
1562
1584
|
extract: []
|
|
1563
1585
|
};
|
|
1564
|
-
function
|
|
1586
|
+
function Mn(e) {
|
|
1565
1587
|
return `${e.type}:${e.id}`;
|
|
1566
1588
|
}
|
|
1567
|
-
const
|
|
1568
|
-
function
|
|
1569
|
-
return e?.type ===
|
|
1589
|
+
const On = "interaction";
|
|
1590
|
+
function Cn(e) {
|
|
1591
|
+
return e?.type === On ? e.id : void 0;
|
|
1570
1592
|
}
|
|
1571
|
-
const
|
|
1572
|
-
function
|
|
1593
|
+
const kn = 64, vn = 8e3;
|
|
1594
|
+
function ea(e) {
|
|
1573
1595
|
const t = typeof e == "number" ? e : Number(String(e ?? "").trim());
|
|
1574
1596
|
if (!(!Number.isFinite(t) || t <= 0))
|
|
1575
|
-
return Math.min(Math.max(Math.round(t),
|
|
1597
|
+
return Math.min(Math.max(Math.round(t), kn), vn);
|
|
1576
1598
|
}
|
|
1577
|
-
const
|
|
1578
|
-
function
|
|
1599
|
+
const ta = { kind: "workflow", steps: [] };
|
|
1600
|
+
function na(e) {
|
|
1579
1601
|
return e?.kind === "workflow" ? e.steps : [];
|
|
1580
1602
|
}
|
|
1581
|
-
function
|
|
1603
|
+
function ra(e) {
|
|
1582
1604
|
return e?.kind === "procedure" ? e.procedure : void 0;
|
|
1583
1605
|
}
|
|
1584
|
-
function
|
|
1606
|
+
function xn(e) {
|
|
1585
1607
|
const t = e?.approved ?? 0, n = t + (e?.rejected ?? 0);
|
|
1586
1608
|
return { total: n, rate: n ? t / n : 0 };
|
|
1587
1609
|
}
|
|
1588
|
-
const
|
|
1589
|
-
function
|
|
1590
|
-
const { total: t, rate: n } =
|
|
1591
|
-
return t >=
|
|
1610
|
+
const Nn = 10, Rn = 0.9;
|
|
1611
|
+
function ia(e) {
|
|
1612
|
+
const { total: t, rate: n } = xn(e);
|
|
1613
|
+
return t >= Nn && n >= Rn;
|
|
1592
1614
|
}
|
|
1593
|
-
const
|
|
1594
|
-
function
|
|
1595
|
-
return
|
|
1615
|
+
const Dn = ["done", "escalated", "failed", "stopped"];
|
|
1616
|
+
function oa(e) {
|
|
1617
|
+
return Dn.includes(e);
|
|
1596
1618
|
}
|
|
1597
|
-
function
|
|
1619
|
+
function $n(e) {
|
|
1598
1620
|
return e === "waiting";
|
|
1599
1621
|
}
|
|
1600
|
-
function
|
|
1601
|
-
return e === "running" ||
|
|
1622
|
+
function aa(e) {
|
|
1623
|
+
return e === "running" || $n(e);
|
|
1602
1624
|
}
|
|
1603
|
-
function
|
|
1625
|
+
function et(e) {
|
|
1604
1626
|
return e.subjectKind && e.subjectId ? { type: e.subjectKind, id: e.subjectId } : void 0;
|
|
1605
1627
|
}
|
|
1606
|
-
function
|
|
1607
|
-
const t =
|
|
1608
|
-
return t ?
|
|
1628
|
+
function sa(e) {
|
|
1629
|
+
const t = et(e);
|
|
1630
|
+
return t ? Mn(t) : void 0;
|
|
1609
1631
|
}
|
|
1610
|
-
function
|
|
1611
|
-
return
|
|
1632
|
+
function ca(e) {
|
|
1633
|
+
return Cn(et(e));
|
|
1612
1634
|
}
|
|
1613
|
-
function
|
|
1635
|
+
function la(e) {
|
|
1614
1636
|
const t = [], n = /* @__PURE__ */ new Map();
|
|
1615
|
-
for (const r of [...e].sort(
|
|
1637
|
+
for (const r of [...e].sort(Ln)) {
|
|
1616
1638
|
const i = n.get(r.emoji);
|
|
1617
1639
|
if (i) {
|
|
1618
1640
|
i.push(r.actor);
|
|
@@ -1625,33 +1647,231 @@ function vo(e) {
|
|
|
1625
1647
|
return { emoji: r, count: i.length, actors: i };
|
|
1626
1648
|
}).sort((r, i) => i.count - r.count || t.indexOf(r.emoji) - t.indexOf(i.emoji));
|
|
1627
1649
|
}
|
|
1628
|
-
const
|
|
1629
|
-
function
|
|
1650
|
+
const Ln = (e, t) => (e.createdAt ?? 0) - (t.createdAt ?? 0);
|
|
1651
|
+
function ua(e, t) {
|
|
1630
1652
|
return t ? e.actors.some((n) => n.type === "user" && n.id === t) : !1;
|
|
1631
1653
|
}
|
|
1632
|
-
|
|
1654
|
+
const q = 6e4, Pn = 36e5, k = 864e5, tt = 800;
|
|
1655
|
+
function Ie(e, t) {
|
|
1656
|
+
const n = Date.UTC(e, t + 1, 0);
|
|
1657
|
+
return n - new Date(n).getUTCDay() * k + Pn;
|
|
1658
|
+
}
|
|
1659
|
+
function Un(e) {
|
|
1660
|
+
const t = new Date(e).getUTCFullYear();
|
|
1661
|
+
return e >= Ie(t, 2) && e < Ie(t, 9);
|
|
1662
|
+
}
|
|
1663
|
+
function nt(e, t) {
|
|
1664
|
+
const n = t.dst === "eu" && Un(e) ? 60 : 0;
|
|
1665
|
+
return (t.utcOffsetMinutes + n) * q;
|
|
1666
|
+
}
|
|
1667
|
+
function Kn(e) {
|
|
1668
|
+
return (e + 3) % 7 + 1;
|
|
1669
|
+
}
|
|
1670
|
+
function rt(e, t) {
|
|
1671
|
+
const n = nt(e, t), r = e + n, i = Math.floor(r / k);
|
|
1672
|
+
if (!t.days.includes(Kn(i))) return null;
|
|
1673
|
+
const o = i * k;
|
|
1674
|
+
return {
|
|
1675
|
+
open: o + t.fromMinutes * q - n,
|
|
1676
|
+
close: o + t.toMinutes * q - n
|
|
1677
|
+
};
|
|
1678
|
+
}
|
|
1679
|
+
function it(e, t) {
|
|
1680
|
+
const n = nt(e, t), r = e + n;
|
|
1681
|
+
return (Math.floor(r / k) + 1) * k - n;
|
|
1682
|
+
}
|
|
1683
|
+
function J(e, t, n) {
|
|
1684
|
+
if (t <= e) return 0;
|
|
1685
|
+
if (!n) return t - e;
|
|
1686
|
+
let r = 0, i = e;
|
|
1687
|
+
for (let o = 0; o < tt && i < t; o++) {
|
|
1688
|
+
const a = rt(i, n);
|
|
1689
|
+
if (a) {
|
|
1690
|
+
const s = Math.max(i, a.open), c = Math.min(t, a.close);
|
|
1691
|
+
c > s && (r += c - s);
|
|
1692
|
+
}
|
|
1693
|
+
i = it(i, n);
|
|
1694
|
+
}
|
|
1695
|
+
return r;
|
|
1696
|
+
}
|
|
1697
|
+
function ne(e, t, n) {
|
|
1698
|
+
if (!n) return e + t;
|
|
1699
|
+
let r = t, i = e;
|
|
1700
|
+
for (let o = 0; o < tt; o++) {
|
|
1701
|
+
const a = rt(i, n);
|
|
1702
|
+
if (a) {
|
|
1703
|
+
const s = Math.max(i, a.open);
|
|
1704
|
+
if (a.close > s) {
|
|
1705
|
+
const c = a.close - s;
|
|
1706
|
+
if (r <= c) return s + r;
|
|
1707
|
+
r -= c;
|
|
1708
|
+
}
|
|
1709
|
+
}
|
|
1710
|
+
i = it(i, n);
|
|
1711
|
+
}
|
|
1712
|
+
return e + t;
|
|
1713
|
+
}
|
|
1714
|
+
function da(e) {
|
|
1715
|
+
const t = /^([01]\d|2[0-3]):([0-5]\d)$/.exec(e);
|
|
1716
|
+
return t ? Number(t[1]) * 60 + Number(t[2]) : null;
|
|
1717
|
+
}
|
|
1718
|
+
const Z = 1, Q = 2;
|
|
1719
|
+
function pa(e) {
|
|
1720
|
+
return e === "snoozed" ? Z : Q;
|
|
1721
|
+
}
|
|
1722
|
+
function re(e) {
|
|
1723
|
+
const t = e.calendar;
|
|
1724
|
+
return t && Array.isArray(t.days) ? t : null;
|
|
1725
|
+
}
|
|
1726
|
+
const fa = [
|
|
1727
|
+
"speed_of_answer",
|
|
1728
|
+
"first_response",
|
|
1729
|
+
"next_response",
|
|
1730
|
+
"resolution",
|
|
1731
|
+
"close"
|
|
1732
|
+
], ma = ["snoozed", "waiting_for_customer"], Bn = 6e4, ot = ["speed_of_answer", "first_response", "next_response"], jn = [...ot, "resolution", "close"];
|
|
1733
|
+
function v(e) {
|
|
1734
|
+
return e.state === "running" || e.state === "paused";
|
|
1735
|
+
}
|
|
1736
|
+
function Hn(e, t) {
|
|
1737
|
+
return v(e) ? { state: (e.state === "paused" ? e.remainingMs > 0 : t <= e.dueAt) ? "hit" : "missed", settledAt: Math.max(t, e.startedAt) } : null;
|
|
1738
|
+
}
|
|
1739
|
+
function Me(e) {
|
|
1740
|
+
return v(e) ? { state: "void" } : null;
|
|
1741
|
+
}
|
|
1742
|
+
function Gn(e, t, n, r) {
|
|
1743
|
+
if (!v(e) || (e.pauseBits & t) !== 0) return null;
|
|
1744
|
+
const i = e.pauseBits | t;
|
|
1745
|
+
return e.state === "paused" ? { pauseBits: i } : { pauseBits: i, state: "paused", remainingMs: J(n, e.dueAt, r) };
|
|
1746
|
+
}
|
|
1747
|
+
function Fn(e, t, n, r) {
|
|
1748
|
+
if (!v(e) || (e.pauseBits & t) === 0) return null;
|
|
1749
|
+
const i = e.pauseBits & ~t;
|
|
1750
|
+
return i !== 0 ? { pauseBits: i } : { pauseBits: i, state: "running", dueAt: ne(n, e.remainingMs, r) };
|
|
1751
|
+
}
|
|
1752
|
+
function ga({ event: e, at: t, now: n, clocks: r, profile: i }) {
|
|
1753
|
+
const o = re(i), a = Math.min(t, n), s = r.map((p) => ({ ...p })), c = [], m = (p, f) => {
|
|
1754
|
+
f && (c.push({ op: "patch", clockId: p.id, patch: f }), Object.assign(p, f));
|
|
1755
|
+
}, h = (p) => {
|
|
1756
|
+
for (const f of s)
|
|
1757
|
+
f.metric === p && m(f, Hn(f, a));
|
|
1758
|
+
}, y = (p) => {
|
|
1759
|
+
for (const f of s)
|
|
1760
|
+
p.includes(f.metric) && m(f, Me(f));
|
|
1761
|
+
}, T = (p) => {
|
|
1762
|
+
for (const f of s) m(f, Gn(f, p, a, o));
|
|
1763
|
+
}, M = (p) => {
|
|
1764
|
+
for (const f of s) m(f, Fn(f, p, a, o));
|
|
1765
|
+
}, B = (p) => s.reduce((f, S) => S.metric === p ? Math.max(f, S.attempt) : f, 0) + 1, x = (p) => s.some((f) => f.metric === p && v(f)), N = (p, f) => {
|
|
1766
|
+
const S = i.targets.find((gt) => gt.metric === p);
|
|
1767
|
+
if (!S) return;
|
|
1768
|
+
const ae = S.minutes * Bn;
|
|
1769
|
+
c.push({
|
|
1770
|
+
op: "start",
|
|
1771
|
+
metric: p,
|
|
1772
|
+
attempt: B(p),
|
|
1773
|
+
startedAt: f,
|
|
1774
|
+
targetMs: ae,
|
|
1775
|
+
dueAt: ne(f, ae, o)
|
|
1776
|
+
});
|
|
1777
|
+
};
|
|
1778
|
+
switch (e) {
|
|
1779
|
+
case "apply": {
|
|
1780
|
+
for (const p of s)
|
|
1781
|
+
p.profileId !== i.id && m(p, Me(p));
|
|
1782
|
+
for (const p of i.targets) {
|
|
1783
|
+
if (p.metric === "next_response") continue;
|
|
1784
|
+
s.some(
|
|
1785
|
+
(S) => S.metric === p.metric && S.profileId === i.id
|
|
1786
|
+
) || N(p.metric, a);
|
|
1787
|
+
}
|
|
1788
|
+
break;
|
|
1789
|
+
}
|
|
1790
|
+
case "answered":
|
|
1791
|
+
h("speed_of_answer");
|
|
1792
|
+
break;
|
|
1793
|
+
case "outbound": {
|
|
1794
|
+
h("first_response"), h("next_response"), i.pauseOn.includes("waiting_for_customer") && T(Q);
|
|
1795
|
+
break;
|
|
1796
|
+
}
|
|
1797
|
+
case "inbound": {
|
|
1798
|
+
M(Q), !x("first_response") && !x("next_response") && N("next_response", a);
|
|
1799
|
+
break;
|
|
1800
|
+
}
|
|
1801
|
+
case "resolved":
|
|
1802
|
+
h("resolution");
|
|
1803
|
+
break;
|
|
1804
|
+
case "closed":
|
|
1805
|
+
h("close"), h("resolution"), y(ot);
|
|
1806
|
+
break;
|
|
1807
|
+
case "reopened":
|
|
1808
|
+
x("resolution") || N("resolution", a), x("close") || N("close", a);
|
|
1809
|
+
break;
|
|
1810
|
+
case "snoozed":
|
|
1811
|
+
i.pauseOn.includes("snoozed") && T(Z);
|
|
1812
|
+
break;
|
|
1813
|
+
case "unsnoozed":
|
|
1814
|
+
M(Z);
|
|
1815
|
+
break;
|
|
1816
|
+
case "discarded":
|
|
1817
|
+
y(jn);
|
|
1818
|
+
break;
|
|
1819
|
+
}
|
|
1820
|
+
return c;
|
|
1821
|
+
}
|
|
1822
|
+
function Wn(e) {
|
|
1823
|
+
return e.state === "running" || e.state === "paused";
|
|
1824
|
+
}
|
|
1825
|
+
function ee(e, t) {
|
|
1826
|
+
const n = re(e);
|
|
1827
|
+
return e.state === "paused" ? e.remainingMs : t >= e.dueAt ? -J(e.dueAt, t, n) : J(t, e.dueAt, n);
|
|
1828
|
+
}
|
|
1829
|
+
function ha(e, t) {
|
|
1830
|
+
return e.state === "paused" ? ne(t, e.remainingMs, re(e)) : e.dueAt;
|
|
1831
|
+
}
|
|
1832
|
+
function ya(e, t) {
|
|
1833
|
+
const n = e.filter(Wn);
|
|
1834
|
+
if (!n.length) return;
|
|
1835
|
+
const r = n.filter((o) => o.state === "running");
|
|
1836
|
+
return (r.length ? r : n).reduce(
|
|
1837
|
+
(o, a) => ee(a, t) < ee(o, t) ? a : o
|
|
1838
|
+
);
|
|
1839
|
+
}
|
|
1840
|
+
function ba(e, t) {
|
|
1841
|
+
if (e.state === "missed") return "breached";
|
|
1842
|
+
if (e.state === "hit") return "met";
|
|
1843
|
+
if (e.state === "paused") return "paused";
|
|
1844
|
+
if (e.state === "void") return "met";
|
|
1845
|
+
const n = ee(e, t);
|
|
1846
|
+
return n <= 0 ? "breached" : n <= e.targetMs / 5 ? "urgent" : "running";
|
|
1847
|
+
}
|
|
1848
|
+
function Aa(e) {
|
|
1849
|
+
const t = Math.floor(Math.abs(e) / 1e3), n = Math.floor(t / 86400), r = Math.floor(t % 86400 / 3600), i = Math.floor(t % 3600 / 60);
|
|
1850
|
+
return n ? r ? `${n}d ${r}u` : `${n}d` : r ? i ? `${r}u ${i}m` : `${r}u` : i ? `${i}m` : `${t % 60}s`;
|
|
1851
|
+
}
|
|
1852
|
+
function Ea(e, t) {
|
|
1633
1853
|
const n = e.accumulatedSeconds || 0;
|
|
1634
1854
|
return e.runningSince ? n + Math.max(0, Math.floor((t - e.runningSince) / 1e3)) : n;
|
|
1635
1855
|
}
|
|
1636
|
-
function
|
|
1856
|
+
function Sa(e, t) {
|
|
1637
1857
|
const n = Math.max(1, Math.ceil(Math.max(0, e) / 60));
|
|
1638
1858
|
if (!t || t === "exact") return n * 60;
|
|
1639
1859
|
const r = Number(t);
|
|
1640
1860
|
return !Number.isFinite(r) || r <= 0 ? n * 60 : Math.ceil(n / r) * r * 60;
|
|
1641
1861
|
}
|
|
1642
|
-
function
|
|
1862
|
+
function _a(e) {
|
|
1643
1863
|
const t = Math.max(0, Math.round(e / 60));
|
|
1644
1864
|
return `${Math.floor(t / 60)}:${String(t % 60).padStart(2, "0")}`;
|
|
1645
1865
|
}
|
|
1646
|
-
function
|
|
1866
|
+
function Ta(e) {
|
|
1647
1867
|
const t = Math.max(0, Math.floor(e)), n = (o) => String(o).padStart(2, "0"), r = Math.floor(t / 60) % 60, i = Math.floor(t / 3600);
|
|
1648
1868
|
return i > 0 ? `${i}:${n(r)}:${n(t % 60)}` : `${n(r)}:${n(t % 60)}`;
|
|
1649
1869
|
}
|
|
1650
|
-
function
|
|
1870
|
+
function Vn(e) {
|
|
1651
1871
|
return (e || "").normalize("NFD").replace(/[\u0300-\u036f]/g, "").toLowerCase().replace(/[^a-z0-9]+/g, "-").slice(0, 48).replace(/^-+|-+$/g, "");
|
|
1652
1872
|
}
|
|
1653
|
-
function
|
|
1654
|
-
const n =
|
|
1873
|
+
function wa(e, t) {
|
|
1874
|
+
const n = Vn(e) || "werksoort", r = new Set(t);
|
|
1655
1875
|
if (!r.has(n)) return n;
|
|
1656
1876
|
for (let i = 2; i < 500; i++) {
|
|
1657
1877
|
const o = `${n}-${i}`;
|
|
@@ -1659,96 +1879,96 @@ function Lo(e, t) {
|
|
|
1659
1879
|
}
|
|
1660
1880
|
return `${n}-${r.size + 1}`;
|
|
1661
1881
|
}
|
|
1662
|
-
function
|
|
1882
|
+
function Ia(e, t) {
|
|
1663
1883
|
const n = e.ownerScope;
|
|
1664
1884
|
return !n || n.kind === "org" ? !0 : t.includes(n.teamId);
|
|
1665
1885
|
}
|
|
1666
|
-
function
|
|
1667
|
-
return e.filter((t) => !t.archived).sort(
|
|
1886
|
+
function Ma(e) {
|
|
1887
|
+
return e.filter((t) => !t.archived).sort(zn);
|
|
1668
1888
|
}
|
|
1669
|
-
function
|
|
1889
|
+
function zn(e, t) {
|
|
1670
1890
|
const n = (e.order ?? 0) - (t.order ?? 0);
|
|
1671
1891
|
return n !== 0 ? n : (e.label || "").localeCompare(t.label || "");
|
|
1672
1892
|
}
|
|
1673
|
-
const
|
|
1674
|
-
function
|
|
1893
|
+
const Xn = 20, Yn = 20, W = 300;
|
|
1894
|
+
function I(e) {
|
|
1675
1895
|
return e.toLowerCase().replace(/[^\p{L}\p{N}\s]/gu, " ").replace(/\s+/g, " ").trim();
|
|
1676
1896
|
}
|
|
1677
|
-
function
|
|
1897
|
+
function qn(e) {
|
|
1678
1898
|
const t = e.replace(/\s+/g, " ").trim();
|
|
1679
|
-
if (t.length <=
|
|
1680
|
-
const n = t.slice(0,
|
|
1681
|
-
return r >
|
|
1682
|
-
}
|
|
1683
|
-
function
|
|
1684
|
-
const n =
|
|
1685
|
-
if (!r || (e.examples ?? []).some((a) =>
|
|
1686
|
-
const i = e.exampleCandidates ?? [], o = i.findIndex((a) =>
|
|
1899
|
+
if (t.length <= W) return t;
|
|
1900
|
+
const n = t.slice(0, W), r = Math.max(n.lastIndexOf(". "), n.lastIndexOf("! "), n.lastIndexOf("? "));
|
|
1901
|
+
return r > W * 0.6 ? n.slice(0, r + 1) : `${n.trimEnd()}…`;
|
|
1902
|
+
}
|
|
1903
|
+
function Oa(e, t) {
|
|
1904
|
+
const n = qn(t.text), r = I(n);
|
|
1905
|
+
if (!r || (e.examples ?? []).some((a) => I(a) === r)) return null;
|
|
1906
|
+
const i = e.exampleCandidates ?? [], o = i.findIndex((a) => I(a.text) === r);
|
|
1687
1907
|
if (o >= 0) {
|
|
1688
1908
|
if (i[o].corrected || !t.corrected) return null;
|
|
1689
1909
|
const a = [...i];
|
|
1690
|
-
return a[o] = { ...a[o], corrected: !0, addedAt: t.addedAt },
|
|
1910
|
+
return a[o] = { ...a[o], corrected: !0, addedAt: t.addedAt }, Oe(a);
|
|
1691
1911
|
}
|
|
1692
|
-
return
|
|
1912
|
+
return Oe([{ ...t, text: n }, ...i]).slice(0, Yn);
|
|
1693
1913
|
}
|
|
1694
|
-
function
|
|
1914
|
+
function Oe(e) {
|
|
1695
1915
|
return [...e].sort(
|
|
1696
1916
|
(t, n) => Number(n.corrected) - Number(t.corrected) || n.addedAt - t.addedAt
|
|
1697
1917
|
);
|
|
1698
1918
|
}
|
|
1699
|
-
function
|
|
1700
|
-
const n =
|
|
1701
|
-
return { examples: r.some((o) =>
|
|
1919
|
+
function Ca(e, t) {
|
|
1920
|
+
const n = I(t), r = (e.examples ?? []).filter((o) => o.trim());
|
|
1921
|
+
return { examples: r.some((o) => I(o) === n) ? r : [...r, t].slice(-Xn), exampleCandidates: Jn(e, t) };
|
|
1702
1922
|
}
|
|
1703
|
-
function
|
|
1704
|
-
const n =
|
|
1705
|
-
return (e.exampleCandidates ?? []).filter((r) =>
|
|
1923
|
+
function Jn(e, t) {
|
|
1924
|
+
const n = I(t);
|
|
1925
|
+
return (e.exampleCandidates ?? []).filter((r) => I(r.text) !== n);
|
|
1706
1926
|
}
|
|
1707
|
-
function
|
|
1927
|
+
function Zn(e, t) {
|
|
1708
1928
|
const n = e.ownerScope;
|
|
1709
1929
|
return n ? n.kind === "org" ? !0 : n.kind === "team" ? !!t && n.teamId === t : !1 : !1;
|
|
1710
1930
|
}
|
|
1711
|
-
function
|
|
1712
|
-
return e.filter((n) =>
|
|
1931
|
+
function ka(e, t) {
|
|
1932
|
+
return e.filter((n) => Zn(n, t));
|
|
1713
1933
|
}
|
|
1714
|
-
function
|
|
1934
|
+
function va(e) {
|
|
1715
1935
|
return e.type === "agent";
|
|
1716
1936
|
}
|
|
1717
|
-
const
|
|
1718
|
-
function
|
|
1937
|
+
const xa = "WORK_COMMENT_ADDED", Na = "WORK_ITEM_ASSIGNED", Ra = "WORK_ITEM_STATUS_CHANGED";
|
|
1938
|
+
function Qn(e, t) {
|
|
1719
1939
|
const n = (r) => {
|
|
1720
1940
|
const i = new Date(r);
|
|
1721
1941
|
return i.setHours(0, 0, 0, 0), i.getTime();
|
|
1722
1942
|
};
|
|
1723
|
-
return Math.round((n(e) - n(t)) /
|
|
1943
|
+
return Math.round((n(e) - n(t)) / qt);
|
|
1724
1944
|
}
|
|
1725
|
-
function
|
|
1726
|
-
if (e.closedAt != null) return { score:
|
|
1945
|
+
function Da(e, t) {
|
|
1946
|
+
if (e.closedAt != null) return { score: w, reasons: [] };
|
|
1727
1947
|
const n = t.remindersById?.[e.id];
|
|
1728
|
-
if (n && n.remindAt > t.now) return { score:
|
|
1948
|
+
if (n && n.remindAt > t.now) return { score: w, reasons: [] };
|
|
1729
1949
|
let r = 0;
|
|
1730
1950
|
const i = [], o = e.priority ?? "normal";
|
|
1731
|
-
if (
|
|
1732
|
-
const a =
|
|
1951
|
+
if (P[o] > 0 && (r += P[o], i.push(`priority:${o}`)), typeof e.dueDate == "number") {
|
|
1952
|
+
const a = Qn(e.dueDate, t.now);
|
|
1733
1953
|
a < 0 ? (r += 35, i.push("overdue")) : a === 0 && (r += 20, i.push("due-today"));
|
|
1734
1954
|
}
|
|
1735
1955
|
return e.source?.initiator === "system" && e.source.systemReason && (r += 15, i.push(`auto:${e.source.systemReason}`)), { score: r, reasons: i };
|
|
1736
1956
|
}
|
|
1737
|
-
const
|
|
1738
|
-
function
|
|
1739
|
-
return `${
|
|
1957
|
+
const er = "work_item", tr = "work_project", nr = "work_activity";
|
|
1958
|
+
function rr(e) {
|
|
1959
|
+
return `${er}:${e}`;
|
|
1740
1960
|
}
|
|
1741
|
-
function
|
|
1742
|
-
return `${
|
|
1961
|
+
function at(e) {
|
|
1962
|
+
return `${tr}:${e}`;
|
|
1743
1963
|
}
|
|
1744
|
-
function
|
|
1745
|
-
return `${
|
|
1964
|
+
function $a(e) {
|
|
1965
|
+
return `${nr}:${e}`;
|
|
1746
1966
|
}
|
|
1747
|
-
function
|
|
1967
|
+
function La(e, t, n) {
|
|
1748
1968
|
const r = `${e}-${t}`;
|
|
1749
1969
|
return n ? `${r}-${n}` : r;
|
|
1750
1970
|
}
|
|
1751
|
-
function
|
|
1971
|
+
function Pa(e) {
|
|
1752
1972
|
const t = /^([A-Za-z0-9]{2,8})-(\d+)(?:-(\d+))?$/.exec((e || "").trim());
|
|
1753
1973
|
return t ? {
|
|
1754
1974
|
projectKey: t[1].toUpperCase(),
|
|
@@ -1756,52 +1976,52 @@ function Yo(e) {
|
|
|
1756
1976
|
...t[3] ? { subSequence: Number(t[3]) } : {}
|
|
1757
1977
|
} : null;
|
|
1758
1978
|
}
|
|
1759
|
-
function
|
|
1979
|
+
function Ua(e) {
|
|
1760
1980
|
return (e || "").normalize("NFD").replace(/[\u0300-\u036f]/g, "").toUpperCase().replace(/[^A-Z0-9]/g, "").slice(0, 3) || "PRJ";
|
|
1761
1981
|
}
|
|
1762
|
-
function
|
|
1763
|
-
const n = /* @__PURE__ */ new Set([
|
|
1764
|
-
e.projectId && n.add(
|
|
1982
|
+
function Ka(e, t = 25) {
|
|
1983
|
+
const n = /* @__PURE__ */ new Set([rr(e.id)]);
|
|
1984
|
+
e.projectId && n.add(at(e.projectId));
|
|
1765
1985
|
for (const r of e.ancestorKeys ?? []) n.add(r);
|
|
1766
1986
|
for (const r of e.partyKeys ?? []) n.add(r);
|
|
1767
1987
|
return Array.from(n).slice(0, t);
|
|
1768
1988
|
}
|
|
1769
|
-
function
|
|
1770
|
-
return [
|
|
1989
|
+
function Ba(e) {
|
|
1990
|
+
return [at(e.id)];
|
|
1771
1991
|
}
|
|
1772
|
-
const
|
|
1992
|
+
const ie = [
|
|
1773
1993
|
{ key: "open", label: "status_open", category: "todo", order: 0 },
|
|
1774
1994
|
{ key: "in_progress", label: "status_in_progress", category: "in_progress", order: 1 },
|
|
1775
1995
|
{ key: "done", label: "status_done", category: "done", order: 2 },
|
|
1776
1996
|
{ key: "cancelled", label: "status_cancelled", category: "done", order: 3 }
|
|
1777
|
-
],
|
|
1778
|
-
function
|
|
1779
|
-
return e?.statuses?.length ? e.statuses :
|
|
1997
|
+
], st = ie.map((e) => e.key);
|
|
1998
|
+
function ir(e) {
|
|
1999
|
+
return e?.statuses?.length ? e.statuses : ie;
|
|
1780
2000
|
}
|
|
1781
|
-
function
|
|
2001
|
+
function or(e, t) {
|
|
1782
2002
|
return t.find((n) => n.key === e)?.category ?? "todo";
|
|
1783
2003
|
}
|
|
1784
|
-
function
|
|
2004
|
+
function ja(e, t) {
|
|
1785
2005
|
return t.find((n) => n.key === e);
|
|
1786
2006
|
}
|
|
1787
|
-
function
|
|
1788
|
-
const t =
|
|
1789
|
-
return n && t.some((r) => r.key === n) ? n :
|
|
2007
|
+
function Ha(e) {
|
|
2008
|
+
const t = ir(e), n = e?.defaultStatusKey;
|
|
2009
|
+
return n && t.some((r) => r.key === n) ? n : ar(t)[0]?.key ?? ie[0].key;
|
|
1790
2010
|
}
|
|
1791
|
-
function
|
|
2011
|
+
function ar(e) {
|
|
1792
2012
|
return [...e].sort((t, n) => {
|
|
1793
2013
|
const r = (t.order ?? 0) - (n.order ?? 0);
|
|
1794
2014
|
return r !== 0 ? r : (t.label || "").localeCompare(n.label || "");
|
|
1795
2015
|
});
|
|
1796
2016
|
}
|
|
1797
|
-
function
|
|
1798
|
-
return
|
|
2017
|
+
function Ga(e, t) {
|
|
2018
|
+
return or(e, t) === "done";
|
|
1799
2019
|
}
|
|
1800
|
-
function
|
|
2020
|
+
function sr(e) {
|
|
1801
2021
|
return (e || "").normalize("NFD").replace(/[\u0300-\u036f]/g, "").toLowerCase().replace(/[^a-z0-9]+/g, "-").slice(0, 48).replace(/^-+|-+$/g, "");
|
|
1802
2022
|
}
|
|
1803
|
-
function
|
|
1804
|
-
const n =
|
|
2023
|
+
function Fa(e, t) {
|
|
2024
|
+
const n = sr(e) || "status", r = /* @__PURE__ */ new Set([...t, ...st]);
|
|
1805
2025
|
if (!r.has(n)) return n;
|
|
1806
2026
|
for (let i = 2; i < 500; i++) {
|
|
1807
2027
|
const o = `${n}-${i}`;
|
|
@@ -1809,7 +2029,7 @@ function na(e, t) {
|
|
|
1809
2029
|
}
|
|
1810
2030
|
return `${n}-${r.size + 1}`;
|
|
1811
2031
|
}
|
|
1812
|
-
function
|
|
2032
|
+
function Wa(e) {
|
|
1813
2033
|
const t = [];
|
|
1814
2034
|
if (!e.length) return [{ index: -1, reason: "empty" }];
|
|
1815
2035
|
const n = /* @__PURE__ */ new Set();
|
|
@@ -1818,10 +2038,10 @@ function ra(e) {
|
|
|
1818
2038
|
t.push({ index: i, reason: "missing_key" });
|
|
1819
2039
|
return;
|
|
1820
2040
|
}
|
|
1821
|
-
|
|
2041
|
+
st.includes(r.key) && t.push({ index: i, reason: "reserved_key", key: r.key }), n.has(r.key) && t.push({ index: i, reason: "duplicate_key", key: r.key }), n.add(r.key);
|
|
1822
2042
|
}), e.some((r) => r.category === "todo" || r.category === "in_progress") || t.push({ index: -1, reason: "no_open" }), e.some((r) => r.category === "done") || t.push({ index: -1, reason: "no_done" }), t;
|
|
1823
2043
|
}
|
|
1824
|
-
const
|
|
2044
|
+
const cr = /* @__PURE__ */ new Set(["image/png", "image/jpeg", "image/jpg", "image/gif", "image/webp"]), lr = /* @__PURE__ */ new Set([
|
|
1825
2045
|
"text/plain",
|
|
1826
2046
|
"text/markdown",
|
|
1827
2047
|
"text/csv",
|
|
@@ -1830,67 +2050,67 @@ const vn = /* @__PURE__ */ new Set(["image/png", "image/jpeg", "image/jpg", "ima
|
|
|
1830
2050
|
"application/xml",
|
|
1831
2051
|
"text/xml"
|
|
1832
2052
|
]);
|
|
1833
|
-
function
|
|
2053
|
+
function ur(e) {
|
|
1834
2054
|
const t = (e ?? "").trim().toLowerCase().split(";")[0];
|
|
1835
|
-
return t ?
|
|
1836
|
-
}
|
|
1837
|
-
const
|
|
1838
|
-
image: 5 *
|
|
1839
|
-
pdf: 20 *
|
|
1840
|
-
text: 1 *
|
|
1841
|
-
audio: 20 *
|
|
1842
|
-
},
|
|
1843
|
-
function
|
|
1844
|
-
const n =
|
|
1845
|
-
return n === "unsupported" ? "unsupported" : t >
|
|
1846
|
-
}
|
|
1847
|
-
function
|
|
2055
|
+
return t ? cr.has(t) ? "image" : t === "application/pdf" ? "pdf" : lr.has(t) ? "text" : t.startsWith("audio/") ? "audio" : "unsupported" : "unsupported";
|
|
2056
|
+
}
|
|
2057
|
+
const O = 1024 * 1024, dr = {
|
|
2058
|
+
image: 5 * O,
|
|
2059
|
+
pdf: 20 * O,
|
|
2060
|
+
text: 1 * O,
|
|
2061
|
+
audio: 20 * O
|
|
2062
|
+
}, Va = 25 * O, za = 5;
|
|
2063
|
+
function Xa(e, t) {
|
|
2064
|
+
const n = ur(e);
|
|
2065
|
+
return n === "unsupported" ? "unsupported" : t > dr[n] ? "too-large" : null;
|
|
2066
|
+
}
|
|
2067
|
+
function Ya(e) {
|
|
1848
2068
|
return e.access !== "read" && e.effect !== "internal";
|
|
1849
2069
|
}
|
|
1850
|
-
function
|
|
2070
|
+
function pr(e) {
|
|
1851
2071
|
return `${e.kind}:${e.id || e.url || e.title}`;
|
|
1852
2072
|
}
|
|
1853
|
-
function
|
|
2073
|
+
function qa(e, t = []) {
|
|
1854
2074
|
const n = new Set(t), r = [], i = [];
|
|
1855
2075
|
for (const o of e) {
|
|
1856
|
-
const a =
|
|
2076
|
+
const a = pr(o);
|
|
1857
2077
|
n.has(a) || (n.add(a), r.push(o), i.push(a));
|
|
1858
2078
|
}
|
|
1859
2079
|
return { sources: r, keys: i };
|
|
1860
2080
|
}
|
|
1861
|
-
const
|
|
1862
|
-
function
|
|
2081
|
+
const Ja = "assist-source", Za = ["blocking", "due", "open"];
|
|
2082
|
+
function Qa(e, t) {
|
|
1863
2083
|
const [n, r] = (e.subjectKey ?? "").split(":");
|
|
1864
2084
|
return n === t && r ? r : void 0;
|
|
1865
2085
|
}
|
|
1866
|
-
const
|
|
1867
|
-
function
|
|
1868
|
-
return
|
|
2086
|
+
const Ce = { blocking: 0, due: 1, open: 2 };
|
|
2087
|
+
function es(e, t) {
|
|
2088
|
+
return Ce[e.band ?? "open"] - Ce[t.band ?? "open"] || (t.priority ?? 0) - (e.priority ?? 0) || e.id.localeCompare(t.id);
|
|
1869
2089
|
}
|
|
1870
|
-
function
|
|
2090
|
+
function ts(e) {
|
|
1871
2091
|
return e.sessions.filter(
|
|
1872
2092
|
(t) => t.id !== e.exceptSessionId && t.state === "connected" && e.canHold(t.providerId)
|
|
1873
2093
|
);
|
|
1874
2094
|
}
|
|
1875
|
-
function
|
|
2095
|
+
function ns(e) {
|
|
1876
2096
|
return e.sessions.filter(
|
|
1877
2097
|
(t) => t.id !== e.exceptSessionId && t.state === "connected" && !e.canHold(t.providerId)
|
|
1878
2098
|
);
|
|
1879
2099
|
}
|
|
1880
|
-
function
|
|
2100
|
+
function rs(e) {
|
|
1881
2101
|
return e.sessions.some(
|
|
1882
2102
|
(n) => n.id !== e.exceptSessionId && (n.state === "connected" || n.state === "on_hold")
|
|
1883
2103
|
) ? { admit: !1, reason: "busy" } : { admit: !0 };
|
|
1884
2104
|
}
|
|
1885
|
-
function
|
|
1886
|
-
const n = new Set(e.disabledIntents ?? []), r = e.intentOverrides ?? {}, i = t.intents.filter((a) => !n.has(a.intent)).map((a) =>
|
|
2105
|
+
function fr(e, t) {
|
|
2106
|
+
const n = new Set(e.disabledIntents ?? []), r = e.intentOverrides ?? {}, i = t.intents.filter((a) => !n.has(a.intent)).map((a) => gr(a, r[a.intent]));
|
|
1887
2107
|
if (!e.extraIntents || e.extraIntents.length === 0) return i;
|
|
1888
2108
|
const o = new Set(i.map((a) => a.intent));
|
|
1889
2109
|
for (const a of e.extraIntents)
|
|
1890
2110
|
o.has(a.intent) || (i.push(a), o.add(a.intent));
|
|
1891
2111
|
return i;
|
|
1892
2112
|
}
|
|
1893
|
-
function
|
|
2113
|
+
function mr(e, t) {
|
|
1894
2114
|
const n = {};
|
|
1895
2115
|
for (const r of e.intents) {
|
|
1896
2116
|
if (!r.togglable) continue;
|
|
@@ -1899,46 +2119,46 @@ function Ln(e, t) {
|
|
|
1899
2119
|
}
|
|
1900
2120
|
return n;
|
|
1901
2121
|
}
|
|
1902
|
-
function
|
|
1903
|
-
const n =
|
|
2122
|
+
function is(e, t) {
|
|
2123
|
+
const n = mr(e, t);
|
|
1904
2124
|
return Object.entries(n).filter(([, r]) => !r).map(([r]) => r);
|
|
1905
2125
|
}
|
|
1906
|
-
function
|
|
2126
|
+
function gr(e, t) {
|
|
1907
2127
|
return t ? {
|
|
1908
2128
|
intent: t.intent ?? e.intent,
|
|
1909
2129
|
targetSchemes: t.targetSchemes ?? e.targetSchemes,
|
|
1910
2130
|
transport: t.transport ?? e.transport
|
|
1911
2131
|
} : e;
|
|
1912
2132
|
}
|
|
1913
|
-
function
|
|
2133
|
+
function os(e, t) {
|
|
1914
2134
|
const n = [];
|
|
1915
2135
|
for (const r of e) {
|
|
1916
2136
|
if (!r.enabled) continue;
|
|
1917
2137
|
const i = t[r.providerId];
|
|
1918
2138
|
if (i)
|
|
1919
|
-
for (const o of
|
|
2139
|
+
for (const o of fr(r, i))
|
|
1920
2140
|
n.push({ channel: r, description: i, capability: o });
|
|
1921
2141
|
}
|
|
1922
2142
|
return n;
|
|
1923
2143
|
}
|
|
1924
|
-
function
|
|
2144
|
+
function as(e, t) {
|
|
1925
2145
|
return t.filter((n) => n.capability.intent === e);
|
|
1926
2146
|
}
|
|
1927
|
-
function
|
|
2147
|
+
function hr(e, t) {
|
|
1928
2148
|
return t.filter((n) => n.capability.targetSchemes.includes(e));
|
|
1929
2149
|
}
|
|
1930
|
-
function
|
|
1931
|
-
return
|
|
2150
|
+
function ss(e, t) {
|
|
2151
|
+
return hr(e.scheme, t);
|
|
1932
2152
|
}
|
|
1933
|
-
function
|
|
2153
|
+
function cs(e, t, n) {
|
|
1934
2154
|
const r = [];
|
|
1935
2155
|
for (const i of e)
|
|
1936
2156
|
for (const o of n)
|
|
1937
2157
|
o.capability.intent === t && o.capability.targetSchemes.includes(i.scheme) && r.push({ channelIntent: o, endpoint: i });
|
|
1938
2158
|
return r;
|
|
1939
2159
|
}
|
|
1940
|
-
var
|
|
1941
|
-
const
|
|
2160
|
+
var yr = /* @__PURE__ */ ((e) => (e.MAILTO = "mailto", e.SIP = "sip", e.TEL = "tel", e.WEBHOOK = "webhook", e.USERNAME = "username", e.ID = "id", e.CUSTOM = "custom", e.URL = "url", e.TELEGRAM = "telegram", e.WHATSAPP = "whatsapp", e.MESSENGER = "messenger", e.INSTAGRAM = "instagram", e.VIBER = "viber", e.SMS = "sms", e.FAX = "fax", e.TEAMS = "teams", e.CALENDAR = "calendar", e))(yr || {});
|
|
2161
|
+
const br = {
|
|
1942
2162
|
mailto: "mail",
|
|
1943
2163
|
sip: "tel",
|
|
1944
2164
|
tel: "tel",
|
|
@@ -1959,10 +2179,10 @@ const jn = {
|
|
|
1959
2179
|
id: "note",
|
|
1960
2180
|
custom: "note"
|
|
1961
2181
|
};
|
|
1962
|
-
function
|
|
1963
|
-
return e ?
|
|
2182
|
+
function ls(e) {
|
|
2183
|
+
return e ? br[e] ?? "note" : "note";
|
|
1964
2184
|
}
|
|
1965
|
-
const
|
|
2185
|
+
const us = "message_window", ds = "message_templates", ps = {
|
|
1966
2186
|
// E-mail
|
|
1967
2187
|
FROM: "from",
|
|
1968
2188
|
TO: "to",
|
|
@@ -1979,12 +2199,12 @@ const _a = "message_window", Ta = "message_templates", wa = {
|
|
|
1979
2199
|
// Voice/conference
|
|
1980
2200
|
HOST: "host",
|
|
1981
2201
|
PARTICIPANT: "participant"
|
|
1982
|
-
},
|
|
2202
|
+
}, fs = (e, t) => ({ intent: e, ...t }), ms = "folder_management", gs = "remote_search", hs = "message_reactions", ys = {
|
|
1983
2203
|
ok: !1,
|
|
1984
2204
|
code: "UNSUPPORTED",
|
|
1985
2205
|
message: "Provider does not support this op"
|
|
1986
|
-
},
|
|
1987
|
-
function
|
|
2206
|
+
}, bs = "context.collect", d = (e) => ({ type: "string", description: e }), u = (e) => ({ type: "number", description: e }), $ = (e) => ({ type: "boolean", description: e }), E = d("Sheet name. Omit for the sheet the user is looking at."), ke = d("Slide id, as `inspect` reports it.");
|
|
2207
|
+
function l(e, t, n, r, i, o) {
|
|
1988
2208
|
return {
|
|
1989
2209
|
op: e,
|
|
1990
2210
|
kinds: t,
|
|
@@ -1994,24 +2214,24 @@ function c(e, t, n, r, i, o) {
|
|
|
1994
2214
|
visible: o.visible
|
|
1995
2215
|
};
|
|
1996
2216
|
}
|
|
1997
|
-
const
|
|
1998
|
-
|
|
2217
|
+
const C = { undoable: !1, visible: !0 }, g = { undoable: !0, visible: !0 }, ve = { undoable: !1, visible: !0 }, U = { undoable: !1, visible: !1 }, Ar = [
|
|
2218
|
+
l(
|
|
1999
2219
|
"pdf.goToPage",
|
|
2000
2220
|
["pdf"],
|
|
2001
2221
|
"Scroll the viewer to a page.",
|
|
2002
|
-
{ page:
|
|
2222
|
+
{ page: u("1-based page number.") },
|
|
2003
2223
|
["page"],
|
|
2004
|
-
|
|
2224
|
+
C
|
|
2005
2225
|
),
|
|
2006
|
-
|
|
2226
|
+
l(
|
|
2007
2227
|
"pdf.search",
|
|
2008
2228
|
["pdf"],
|
|
2009
2229
|
"Search the document and highlight the matches, as the find bar does.",
|
|
2010
|
-
{ query:
|
|
2230
|
+
{ query: d("Text to find."), next: $("Jump to the next match instead of the first.") },
|
|
2011
2231
|
["query"],
|
|
2012
|
-
|
|
2232
|
+
C
|
|
2013
2233
|
),
|
|
2014
|
-
|
|
2234
|
+
l(
|
|
2015
2235
|
"pdf.setTool",
|
|
2016
2236
|
["pdf"],
|
|
2017
2237
|
"Select a markup tool for the user, so their next click draws it.",
|
|
@@ -2023,23 +2243,23 @@ const T = { undoable: !1, visible: !0 }, p = { undoable: !0, visible: !0 }, pe =
|
|
|
2023
2243
|
}
|
|
2024
2244
|
},
|
|
2025
2245
|
["tool"],
|
|
2026
|
-
|
|
2246
|
+
C
|
|
2027
2247
|
),
|
|
2028
|
-
|
|
2248
|
+
l(
|
|
2029
2249
|
"pdf.fillField",
|
|
2030
2250
|
["pdf"],
|
|
2031
2251
|
"Fill one form field of a fillable PDF.",
|
|
2032
2252
|
{
|
|
2033
|
-
field:
|
|
2253
|
+
field: d("Field name, exactly as `inspect` reports it under `fields`."),
|
|
2034
2254
|
value: {
|
|
2035
2255
|
type: ["string", "boolean"],
|
|
2036
2256
|
description: "Text for a text field, true/false for a checkbox or radio."
|
|
2037
2257
|
}
|
|
2038
2258
|
},
|
|
2039
2259
|
["field", "value"],
|
|
2040
|
-
|
|
2260
|
+
g
|
|
2041
2261
|
),
|
|
2042
|
-
|
|
2262
|
+
l(
|
|
2043
2263
|
"pdf.reorderPages",
|
|
2044
2264
|
["pdf"],
|
|
2045
2265
|
"Put the pages in a different order. Pages left out are deleted.",
|
|
@@ -2051,52 +2271,52 @@ const T = { undoable: !1, visible: !0 }, p = { undoable: !0, visible: !0 }, pe =
|
|
|
2051
2271
|
}
|
|
2052
2272
|
},
|
|
2053
2273
|
["order"],
|
|
2054
|
-
|
|
2274
|
+
ve
|
|
2055
2275
|
),
|
|
2056
|
-
|
|
2276
|
+
l(
|
|
2057
2277
|
"pdf.deletePages",
|
|
2058
2278
|
["pdf"],
|
|
2059
2279
|
"Remove pages, keeping the rest in order.",
|
|
2060
2280
|
{ pages: { type: "array", items: { type: "number" }, description: "1-based page numbers." } },
|
|
2061
2281
|
["pages"],
|
|
2062
|
-
|
|
2282
|
+
ve
|
|
2063
2283
|
),
|
|
2064
|
-
|
|
2284
|
+
l(
|
|
2065
2285
|
"pdf.addNote",
|
|
2066
2286
|
["pdf"],
|
|
2067
2287
|
"Place a text note on a page. Written on save; not visible before that.",
|
|
2068
2288
|
{
|
|
2069
|
-
page:
|
|
2070
|
-
text:
|
|
2071
|
-
left:
|
|
2072
|
-
top:
|
|
2073
|
-
width:
|
|
2074
|
-
height:
|
|
2075
|
-
fontSize:
|
|
2289
|
+
page: u("1-based page number."),
|
|
2290
|
+
text: d("The note's text."),
|
|
2291
|
+
left: u("Distance from the left edge, in PDF points (72 per inch)."),
|
|
2292
|
+
top: u("Distance from the top edge, in PDF points."),
|
|
2293
|
+
width: u("Box width in points. Omit for a sensible default."),
|
|
2294
|
+
height: u("Box height in points. Omit for a sensible default."),
|
|
2295
|
+
fontSize: u("Font size in points. Omit for 12.")
|
|
2076
2296
|
},
|
|
2077
2297
|
["page", "text", "left", "top"],
|
|
2078
|
-
|
|
2298
|
+
U
|
|
2079
2299
|
),
|
|
2080
|
-
|
|
2300
|
+
l(
|
|
2081
2301
|
"pdf.highlightText",
|
|
2082
2302
|
["pdf"],
|
|
2083
2303
|
"Highlight a phrase on a page. Written on save; not visible before that.",
|
|
2084
2304
|
{
|
|
2085
|
-
page:
|
|
2086
|
-
text:
|
|
2087
|
-
occurrence:
|
|
2305
|
+
page: u("1-based page number."),
|
|
2306
|
+
text: d("The exact phrase to highlight, as it appears in the page's text."),
|
|
2307
|
+
occurrence: u("Which occurrence on that page, 1-based. Omit for the first.")
|
|
2088
2308
|
},
|
|
2089
2309
|
["page", "text"],
|
|
2090
|
-
|
|
2310
|
+
U
|
|
2091
2311
|
)
|
|
2092
|
-
],
|
|
2093
|
-
|
|
2312
|
+
], Er = [
|
|
2313
|
+
l(
|
|
2094
2314
|
"sheet.setValues",
|
|
2095
2315
|
["sheet"],
|
|
2096
2316
|
"Write a block of values. The block's shape must match the range.",
|
|
2097
2317
|
{
|
|
2098
|
-
sheet:
|
|
2099
|
-
range:
|
|
2318
|
+
sheet: E,
|
|
2319
|
+
range: d("A1 notation, e.g. `B2:D5` or a single `A1`."),
|
|
2100
2320
|
values: {
|
|
2101
2321
|
type: "array",
|
|
2102
2322
|
items: { type: "array", items: { type: ["string", "number", "boolean", "null"] } },
|
|
@@ -2104,261 +2324,261 @@ const T = { undoable: !1, visible: !0 }, p = { undoable: !0, visible: !0 }, pe =
|
|
|
2104
2324
|
}
|
|
2105
2325
|
},
|
|
2106
2326
|
["range", "values"],
|
|
2107
|
-
|
|
2327
|
+
g
|
|
2108
2328
|
),
|
|
2109
|
-
|
|
2329
|
+
l(
|
|
2110
2330
|
"sheet.setFormula",
|
|
2111
2331
|
["sheet"],
|
|
2112
2332
|
"Put a formula in every cell of a range.",
|
|
2113
|
-
{ sheet:
|
|
2333
|
+
{ sheet: E, range: d("A1 notation."), formula: d("Including the leading `=`.") },
|
|
2114
2334
|
["range", "formula"],
|
|
2115
|
-
|
|
2335
|
+
g
|
|
2116
2336
|
),
|
|
2117
|
-
|
|
2337
|
+
l(
|
|
2118
2338
|
"sheet.setStyle",
|
|
2119
2339
|
["sheet"],
|
|
2120
2340
|
"Change the look of a range. Only the properties you pass are touched.",
|
|
2121
2341
|
{
|
|
2122
|
-
sheet:
|
|
2123
|
-
range:
|
|
2124
|
-
bold:
|
|
2125
|
-
italic:
|
|
2126
|
-
fontSize:
|
|
2127
|
-
fontColor:
|
|
2128
|
-
background:
|
|
2342
|
+
sheet: E,
|
|
2343
|
+
range: d("A1 notation."),
|
|
2344
|
+
bold: $("Bold on or off."),
|
|
2345
|
+
italic: $("Italic on or off."),
|
|
2346
|
+
fontSize: u("Point size."),
|
|
2347
|
+
fontColor: d("CSS colour, e.g. `#b91c1c`."),
|
|
2348
|
+
background: d("CSS colour for the cell fill."),
|
|
2129
2349
|
horizontalAlignment: {
|
|
2130
2350
|
type: "string",
|
|
2131
2351
|
enum: ["left", "center", "right"],
|
|
2132
2352
|
description: "Horizontal alignment."
|
|
2133
2353
|
},
|
|
2134
|
-
numberFormat:
|
|
2354
|
+
numberFormat: d("Number format pattern, e.g. `#,##0.00` or `0%`.")
|
|
2135
2355
|
},
|
|
2136
2356
|
["range"],
|
|
2137
|
-
|
|
2357
|
+
g
|
|
2138
2358
|
),
|
|
2139
|
-
|
|
2359
|
+
l(
|
|
2140
2360
|
"sheet.insertRows",
|
|
2141
2361
|
["sheet"],
|
|
2142
2362
|
"Insert empty rows, pushing the rest down.",
|
|
2143
2363
|
{
|
|
2144
|
-
sheet:
|
|
2145
|
-
at:
|
|
2146
|
-
count:
|
|
2364
|
+
sheet: E,
|
|
2365
|
+
at: u("1-based row number to insert before."),
|
|
2366
|
+
count: u("How many. Omit for 1.")
|
|
2147
2367
|
},
|
|
2148
2368
|
["at"],
|
|
2149
|
-
|
|
2369
|
+
g
|
|
2150
2370
|
),
|
|
2151
|
-
|
|
2371
|
+
l(
|
|
2152
2372
|
"sheet.deleteRows",
|
|
2153
2373
|
["sheet"],
|
|
2154
2374
|
"Delete rows, pulling the rest up.",
|
|
2155
|
-
{ sheet:
|
|
2375
|
+
{ sheet: E, at: u("1-based first row to delete."), count: u("How many. Omit for 1.") },
|
|
2156
2376
|
["at"],
|
|
2157
|
-
|
|
2377
|
+
g
|
|
2158
2378
|
),
|
|
2159
|
-
|
|
2379
|
+
l(
|
|
2160
2380
|
"sheet.insertColumns",
|
|
2161
2381
|
["sheet"],
|
|
2162
2382
|
"Insert empty columns, pushing the rest right.",
|
|
2163
2383
|
{
|
|
2164
|
-
sheet:
|
|
2165
|
-
at:
|
|
2166
|
-
count:
|
|
2384
|
+
sheet: E,
|
|
2385
|
+
at: u("1-based column number to insert before."),
|
|
2386
|
+
count: u("How many. Omit for 1.")
|
|
2167
2387
|
},
|
|
2168
2388
|
["at"],
|
|
2169
|
-
|
|
2389
|
+
g
|
|
2170
2390
|
),
|
|
2171
|
-
|
|
2391
|
+
l(
|
|
2172
2392
|
"sheet.deleteColumns",
|
|
2173
2393
|
["sheet"],
|
|
2174
2394
|
"Delete columns, pulling the rest left.",
|
|
2175
2395
|
{
|
|
2176
|
-
sheet:
|
|
2177
|
-
at:
|
|
2178
|
-
count:
|
|
2396
|
+
sheet: E,
|
|
2397
|
+
at: u("1-based first column to delete."),
|
|
2398
|
+
count: u("How many. Omit for 1.")
|
|
2179
2399
|
},
|
|
2180
2400
|
["at"],
|
|
2181
|
-
|
|
2401
|
+
g
|
|
2182
2402
|
),
|
|
2183
|
-
|
|
2403
|
+
l(
|
|
2184
2404
|
"sheet.merge",
|
|
2185
2405
|
["sheet"],
|
|
2186
2406
|
"Merge a range into one cell.",
|
|
2187
|
-
{ sheet:
|
|
2407
|
+
{ sheet: E, range: d("A1 notation.") },
|
|
2188
2408
|
["range"],
|
|
2189
|
-
|
|
2409
|
+
g
|
|
2190
2410
|
),
|
|
2191
|
-
|
|
2411
|
+
l(
|
|
2192
2412
|
"sheet.unmerge",
|
|
2193
2413
|
["sheet"],
|
|
2194
2414
|
"Break merged cells in a range apart.",
|
|
2195
|
-
{ sheet:
|
|
2415
|
+
{ sheet: E, range: d("A1 notation.") },
|
|
2196
2416
|
["range"],
|
|
2197
|
-
|
|
2417
|
+
g
|
|
2198
2418
|
),
|
|
2199
|
-
|
|
2419
|
+
l(
|
|
2200
2420
|
"sheet.sort",
|
|
2201
2421
|
["sheet"],
|
|
2202
2422
|
"Sort a range on one of its columns.",
|
|
2203
2423
|
{
|
|
2204
|
-
sheet:
|
|
2205
|
-
range:
|
|
2206
|
-
column:
|
|
2207
|
-
ascending:
|
|
2424
|
+
sheet: E,
|
|
2425
|
+
range: d("A1 notation covering the rows to sort, header excluded."),
|
|
2426
|
+
column: u("1-based column *within the range*, not within the sheet."),
|
|
2427
|
+
ascending: $("Ascending. Omit for ascending.")
|
|
2208
2428
|
},
|
|
2209
2429
|
["range", "column"],
|
|
2210
|
-
|
|
2430
|
+
g
|
|
2211
2431
|
),
|
|
2212
|
-
|
|
2432
|
+
l(
|
|
2213
2433
|
"sheet.insertSheet",
|
|
2214
2434
|
["sheet"],
|
|
2215
2435
|
"Add a new sheet.",
|
|
2216
|
-
{ name:
|
|
2436
|
+
{ name: d("Name for the new sheet.") },
|
|
2217
2437
|
["name"],
|
|
2218
|
-
|
|
2438
|
+
g
|
|
2219
2439
|
),
|
|
2220
|
-
|
|
2440
|
+
l(
|
|
2221
2441
|
"sheet.renameSheet",
|
|
2222
2442
|
["sheet"],
|
|
2223
2443
|
"Rename a sheet.",
|
|
2224
|
-
{ sheet:
|
|
2444
|
+
{ sheet: d("Current name."), name: d("New name.") },
|
|
2225
2445
|
["sheet", "name"],
|
|
2226
|
-
|
|
2446
|
+
g
|
|
2227
2447
|
),
|
|
2228
|
-
|
|
2448
|
+
l(
|
|
2229
2449
|
"sheet.deleteSheet",
|
|
2230
2450
|
["sheet"],
|
|
2231
2451
|
"Remove a sheet and everything on it.",
|
|
2232
|
-
{ sheet:
|
|
2452
|
+
{ sheet: d("Name of the sheet to delete.") },
|
|
2233
2453
|
["sheet"],
|
|
2234
|
-
|
|
2454
|
+
g
|
|
2235
2455
|
),
|
|
2236
|
-
|
|
2456
|
+
l(
|
|
2237
2457
|
"sheet.activate",
|
|
2238
2458
|
["sheet"],
|
|
2239
2459
|
"Show the user a sheet and select a range on it.",
|
|
2240
|
-
{ sheet:
|
|
2460
|
+
{ sheet: E, range: d("A1 notation to select. Omit to only switch sheets.") },
|
|
2241
2461
|
[],
|
|
2242
|
-
|
|
2462
|
+
C
|
|
2243
2463
|
)
|
|
2244
|
-
],
|
|
2245
|
-
|
|
2464
|
+
], Sr = [
|
|
2465
|
+
l(
|
|
2246
2466
|
"word.replaceParagraph",
|
|
2247
2467
|
["word"],
|
|
2248
2468
|
"Rewrite one whole paragraph, keeping its style. This is the verb for shortening or rephrasing something; call it once per paragraph.",
|
|
2249
2469
|
{
|
|
2250
|
-
at:
|
|
2251
|
-
text:
|
|
2470
|
+
at: u("The offset the paragraph starts at, exactly as `inspect` prints it."),
|
|
2471
|
+
text: d("The new text for that paragraph. A newline starts a further paragraph.")
|
|
2252
2472
|
},
|
|
2253
2473
|
["at", "text"],
|
|
2254
|
-
|
|
2474
|
+
g
|
|
2255
2475
|
),
|
|
2256
|
-
|
|
2476
|
+
l(
|
|
2257
2477
|
"word.replaceRange",
|
|
2258
2478
|
["word"],
|
|
2259
2479
|
"Replace a stretch of text inside a paragraph - a sentence, a phrase. To rewrite whole paragraphs use word.replaceParagraph: a range covering several paragraph styles is refused, because a replacement carries one style and would set the whole span in the first.",
|
|
2260
2480
|
{
|
|
2261
|
-
start:
|
|
2262
|
-
end:
|
|
2263
|
-
text:
|
|
2481
|
+
start: u("Character offset where the replaced text starts, as `inspect` reports offsets."),
|
|
2482
|
+
end: u("Character offset just past the last character to replace."),
|
|
2483
|
+
text: d("The replacement text. A newline starts a new paragraph.")
|
|
2264
2484
|
},
|
|
2265
2485
|
["start", "end", "text"],
|
|
2266
|
-
|
|
2486
|
+
g
|
|
2267
2487
|
),
|
|
2268
|
-
|
|
2488
|
+
l(
|
|
2269
2489
|
"word.insertText",
|
|
2270
2490
|
["word"],
|
|
2271
2491
|
"Insert text at a character offset, without removing anything.",
|
|
2272
2492
|
{
|
|
2273
|
-
index:
|
|
2274
|
-
text:
|
|
2493
|
+
index: u("Character offset, as `inspect` reports offsets."),
|
|
2494
|
+
text: d("The text to insert.")
|
|
2275
2495
|
},
|
|
2276
2496
|
["index", "text"],
|
|
2277
|
-
|
|
2497
|
+
g
|
|
2278
2498
|
),
|
|
2279
|
-
|
|
2499
|
+
l(
|
|
2280
2500
|
"word.appendText",
|
|
2281
2501
|
["word"],
|
|
2282
2502
|
"Add text at the end of the document.",
|
|
2283
|
-
{ text:
|
|
2503
|
+
{ text: d("The text to append.") },
|
|
2284
2504
|
["text"],
|
|
2285
|
-
|
|
2505
|
+
g
|
|
2286
2506
|
),
|
|
2287
|
-
|
|
2507
|
+
l(
|
|
2288
2508
|
"word.insertParagraph",
|
|
2289
2509
|
["word"],
|
|
2290
2510
|
"Start a new paragraph, optionally with text in it.",
|
|
2291
2511
|
{
|
|
2292
|
-
text:
|
|
2293
|
-
index:
|
|
2512
|
+
text: d("Paragraph text. Newlines start further paragraphs."),
|
|
2513
|
+
index: u("Character offset to insert at. Omit for the end of the document.")
|
|
2294
2514
|
},
|
|
2295
2515
|
[],
|
|
2296
|
-
|
|
2516
|
+
g
|
|
2297
2517
|
),
|
|
2298
|
-
|
|
2518
|
+
l(
|
|
2299
2519
|
"word.setSelection",
|
|
2300
2520
|
["word"],
|
|
2301
2521
|
"Put the user's cursor on a stretch of text, and move the reading window there: the page context carries one window of a long document, and the text around this offset arrives in the next turn.",
|
|
2302
|
-
{ start:
|
|
2522
|
+
{ start: u("Start character offset."), end: u("End character offset. Omit for a caret.") },
|
|
2303
2523
|
["start"],
|
|
2304
|
-
|
|
2524
|
+
C
|
|
2305
2525
|
)
|
|
2306
|
-
],
|
|
2307
|
-
|
|
2526
|
+
], _r = [
|
|
2527
|
+
l(
|
|
2308
2528
|
"slides.setText",
|
|
2309
2529
|
["slides"],
|
|
2310
2530
|
"Replace the text of one shape. Written on save; not visible before that, and not undoable.",
|
|
2311
2531
|
{
|
|
2312
|
-
slide:
|
|
2313
|
-
element:
|
|
2314
|
-
text:
|
|
2532
|
+
slide: ke,
|
|
2533
|
+
element: d("Element id, as `inspect` reports it."),
|
|
2534
|
+
text: d("The new text.")
|
|
2315
2535
|
},
|
|
2316
2536
|
["slide", "element", "text"],
|
|
2317
|
-
|
|
2537
|
+
U
|
|
2318
2538
|
),
|
|
2319
|
-
|
|
2539
|
+
l(
|
|
2320
2540
|
"slides.setTransform",
|
|
2321
2541
|
["slides"],
|
|
2322
2542
|
"Move or resize one shape. Only the values you pass change. Written on save; not visible before that, and not undoable.",
|
|
2323
2543
|
{
|
|
2324
|
-
slide:
|
|
2325
|
-
element:
|
|
2326
|
-
left:
|
|
2327
|
-
top:
|
|
2328
|
-
width:
|
|
2329
|
-
height:
|
|
2544
|
+
slide: ke,
|
|
2545
|
+
element: d("Element id."),
|
|
2546
|
+
left: u("Distance from the left edge, in pixels."),
|
|
2547
|
+
top: u("Distance from the top edge, in pixels."),
|
|
2548
|
+
width: u("Width in pixels."),
|
|
2549
|
+
height: u("Height in pixels.")
|
|
2330
2550
|
},
|
|
2331
2551
|
["slide", "element"],
|
|
2332
|
-
|
|
2552
|
+
U
|
|
2333
2553
|
)
|
|
2334
|
-
],
|
|
2335
|
-
...
|
|
2336
|
-
...
|
|
2337
|
-
...
|
|
2338
|
-
...
|
|
2554
|
+
], ct = [
|
|
2555
|
+
...Ar,
|
|
2556
|
+
...Er,
|
|
2557
|
+
...Sr,
|
|
2558
|
+
..._r
|
|
2339
2559
|
];
|
|
2340
|
-
function
|
|
2341
|
-
return
|
|
2560
|
+
function As(e) {
|
|
2561
|
+
return ct.filter((t) => t.kinds.includes(e));
|
|
2342
2562
|
}
|
|
2343
|
-
function
|
|
2344
|
-
return
|
|
2563
|
+
function Es(e) {
|
|
2564
|
+
return ct.find((t) => t.op === e);
|
|
2345
2565
|
}
|
|
2346
|
-
const
|
|
2347
|
-
function
|
|
2566
|
+
const Ss = "documents.describe", _s = "documents.inspect", Ts = "documents.apply";
|
|
2567
|
+
function ws(e) {
|
|
2348
2568
|
const t = e.indexOf(":");
|
|
2349
2569
|
if (t !== -1) return e.slice(0, t);
|
|
2350
2570
|
const n = e.indexOf(".");
|
|
2351
2571
|
return n === -1 ? e : e.slice(0, n);
|
|
2352
2572
|
}
|
|
2353
|
-
const
|
|
2354
|
-
function
|
|
2573
|
+
const Is = "installation-id";
|
|
2574
|
+
function Ms(e) {
|
|
2355
2575
|
const t = [];
|
|
2356
2576
|
for (const n of Object.keys(e))
|
|
2357
2577
|
for (const r of Object.keys(e[n]))
|
|
2358
2578
|
t.push({ lang: n, key: r, value: e[n][r] });
|
|
2359
2579
|
return t;
|
|
2360
2580
|
}
|
|
2361
|
-
const
|
|
2581
|
+
const Os = "notification-source", Cs = (e, t) => `${e}.pref.${t}`, ks = {
|
|
2362
2582
|
ai: [
|
|
2363
2583
|
"account.read",
|
|
2364
2584
|
"account.write",
|
|
@@ -2493,64 +2713,64 @@ const Ka = "notification-source", ja = (e, t) => `${e}.pref.${t}`, Ba = {
|
|
|
2493
2713
|
time: ["entry.read", "entry.write", "work-type.read", "work-type.write"],
|
|
2494
2714
|
user: ["user.read", "user.write"],
|
|
2495
2715
|
work: ["item.read", "item.write", "project.read", "project.write"]
|
|
2496
|
-
},
|
|
2497
|
-
function
|
|
2498
|
-
const r = n - e <
|
|
2716
|
+
}, lt = 9e4, Tr = ["out_of_office"], ut = (e) => Tr.includes(e);
|
|
2717
|
+
function vs(e, t, n) {
|
|
2718
|
+
const r = n - e < lt, i = t?.status && (!t.expiresAt || t.expiresAt > n) ? t : void 0;
|
|
2499
2719
|
if (!i?.status) return { online: r, status: r ? "available" : "offline" };
|
|
2500
2720
|
const o = i.status;
|
|
2501
|
-
return !r && !
|
|
2721
|
+
return !r && !ut(o) ? { online: !1, status: "offline" } : { online: r, status: o, message: i.message };
|
|
2502
2722
|
}
|
|
2503
|
-
function
|
|
2504
|
-
const n = t - e.lastSeenAt <
|
|
2723
|
+
function xs(e, t) {
|
|
2724
|
+
const n = t - e.lastSeenAt < lt, r = n || ut(e.status) ? e.status : "offline";
|
|
2505
2725
|
return n === e.online && r === e.status ? e : { ...e, online: n, status: r };
|
|
2506
2726
|
}
|
|
2507
|
-
function
|
|
2727
|
+
function Ns(e, t) {
|
|
2508
2728
|
return e?.teamId && t.includes(e.teamId) ? { teamId: e.teamId, mustChoose: !1 } : t.length === 1 ? { teamId: t[0], mustChoose: !1 } : { teamId: void 0, mustChoose: t.length > 1 };
|
|
2509
2729
|
}
|
|
2510
|
-
function
|
|
2730
|
+
function Rs(e) {
|
|
2511
2731
|
return e.providerAvailable && e.allowed;
|
|
2512
2732
|
}
|
|
2513
|
-
const
|
|
2514
|
-
function
|
|
2733
|
+
const Ds = "resources.describe", $s = "resources.search", Ls = "resources.resolve", Ps = "resources.attached";
|
|
2734
|
+
function Us(e) {
|
|
2515
2735
|
const t = e.indexOf(":");
|
|
2516
2736
|
return t === -1 ? e : e.slice(0, t);
|
|
2517
2737
|
}
|
|
2518
|
-
const
|
|
2519
|
-
function
|
|
2738
|
+
const Ks = "/provider/scope/related", Bs = "/provider/scope/read", dt = "auth";
|
|
2739
|
+
function pt(e) {
|
|
2520
2740
|
const t = typeof e == "string" ? e.match(/apps\/([^/?#]+)/) : null;
|
|
2521
2741
|
return t ? t[1] : null;
|
|
2522
2742
|
}
|
|
2523
|
-
function
|
|
2524
|
-
const t =
|
|
2525
|
-
return t ? t !==
|
|
2743
|
+
function js(e) {
|
|
2744
|
+
const t = pt(e);
|
|
2745
|
+
return t ? t !== dt : typeof e == "string" && e.startsWith("/wake");
|
|
2526
2746
|
}
|
|
2527
|
-
function
|
|
2528
|
-
return typeof e != "string" || e === "" || e === "/" ? !0 :
|
|
2747
|
+
function Hs(e) {
|
|
2748
|
+
return typeof e != "string" || e === "" || e === "/" ? !0 : pt(e) === dt;
|
|
2529
2749
|
}
|
|
2530
|
-
function
|
|
2750
|
+
function wr(e) {
|
|
2531
2751
|
return e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
2532
2752
|
}
|
|
2533
|
-
function
|
|
2534
|
-
const n = e.split("/").filter(Boolean).map((r) => r.startsWith(":") ? r.endsWith("?") ? "(?:/[^/]+)?" : "/[^/]+" : `/${
|
|
2753
|
+
function Ir(e) {
|
|
2754
|
+
const n = e.split("/").filter(Boolean).map((r) => r.startsWith(":") ? r.endsWith("?") ? "(?:/[^/]+)?" : "/[^/]+" : `/${wr(r)}`).join("");
|
|
2535
2755
|
return new RegExp(`^${n}\\/?$`);
|
|
2536
2756
|
}
|
|
2537
|
-
function
|
|
2757
|
+
function Mr(e, t) {
|
|
2538
2758
|
const n = e.split("/").filter(Boolean), r = t.split("/").filter(Boolean), i = {};
|
|
2539
2759
|
return n.forEach((o, a) => {
|
|
2540
2760
|
if (o.startsWith(":")) {
|
|
2541
|
-
const s = o.endsWith("?") ? o.slice(1, -1) : o.slice(1),
|
|
2542
|
-
|
|
2761
|
+
const s = o.endsWith("?") ? o.slice(1, -1) : o.slice(1), c = r[a];
|
|
2762
|
+
c && (i[s] = c);
|
|
2543
2763
|
}
|
|
2544
2764
|
}), i;
|
|
2545
2765
|
}
|
|
2546
|
-
function
|
|
2766
|
+
function Or(e) {
|
|
2547
2767
|
return e.publicBasePath ?? `/apps/${e.name}`;
|
|
2548
2768
|
}
|
|
2549
|
-
function
|
|
2769
|
+
function Gs(e) {
|
|
2550
2770
|
const t = [];
|
|
2551
2771
|
for (const n of e) {
|
|
2552
2772
|
if (!n?.name) continue;
|
|
2553
|
-
const r =
|
|
2773
|
+
const r = Or(n);
|
|
2554
2774
|
for (const i of n.routes ?? []) {
|
|
2555
2775
|
if (!i.public) continue;
|
|
2556
2776
|
const o = i.path === "/" ? "" : i.path;
|
|
@@ -2564,7 +2784,7 @@ function ts(e) {
|
|
|
2564
2784
|
}
|
|
2565
2785
|
return t;
|
|
2566
2786
|
}
|
|
2567
|
-
function
|
|
2787
|
+
function Cr(e, t) {
|
|
2568
2788
|
const n = e.split("/").filter(Boolean), r = t.split("/").filter(Boolean);
|
|
2569
2789
|
for (let i = 0; i < Math.min(n.length, r.length); i++) {
|
|
2570
2790
|
const o = n[i].startsWith(":"), a = r[i].startsWith(":");
|
|
@@ -2572,17 +2792,17 @@ function qn(e, t) {
|
|
|
2572
2792
|
}
|
|
2573
2793
|
return n.length > r.length;
|
|
2574
2794
|
}
|
|
2575
|
-
function
|
|
2795
|
+
function kr(e, t) {
|
|
2576
2796
|
if (typeof e != "string") return null;
|
|
2577
2797
|
let n = null;
|
|
2578
2798
|
for (const r of t)
|
|
2579
|
-
|
|
2580
|
-
return n ? { ...n, params: { ...n.props, ...
|
|
2799
|
+
Ir(r.pattern).test(e) && (!n || Cr(r.pattern, n.pattern)) && (n = r);
|
|
2800
|
+
return n ? { ...n, params: { ...n.props, ...Mr(n.pattern, e) } } : null;
|
|
2581
2801
|
}
|
|
2582
|
-
function
|
|
2583
|
-
return
|
|
2802
|
+
function Fs(e, t) {
|
|
2803
|
+
return kr(e, t) !== null;
|
|
2584
2804
|
}
|
|
2585
|
-
const
|
|
2805
|
+
const Ws = 10 * 1024 * 1024, Vs = 25 * 1024 * 1024, zs = "sync-source", Xs = "sync-target", Ys = "externalId", qs = 20, vr = {
|
|
2586
2806
|
afrikaans: [
|
|
2587
2807
|
"[Muziek]",
|
|
2588
2808
|
"(C) TV GELDERLAND 2021",
|
|
@@ -2732,14 +2952,14 @@ const rs = 10 * 1024 * 1024, is = 25 * 1024 * 1024, os = "sync-source", as = "sy
|
|
|
2732
2952
|
"[MÚSICA]",
|
|
2733
2953
|
"[Music cuts in British]"
|
|
2734
2954
|
]
|
|
2735
|
-
},
|
|
2955
|
+
}, xr = (e) => {
|
|
2736
2956
|
let t = e;
|
|
2737
|
-
return Object.values(
|
|
2957
|
+
return Object.values(vr).forEach((n) => {
|
|
2738
2958
|
n.forEach((r) => {
|
|
2739
2959
|
t = t.replaceAll(r, "");
|
|
2740
2960
|
});
|
|
2741
2961
|
}), t = t.replace(/\(.*?\)/g, ""), t = t.replace(/\[.*?\]/g, ""), t;
|
|
2742
|
-
},
|
|
2962
|
+
}, Nr = 6e4, Rr = 8e3, Dr = 2, $r = 0.4, Lr = 3, Pr = /* @__PURE__ */ new Set([
|
|
2743
2963
|
"aan",
|
|
2744
2964
|
"als",
|
|
2745
2965
|
"ben",
|
|
@@ -2852,13 +3072,13 @@ const rs = 10 * 1024 * 1024, is = 25 * 1024 * 1024, os = "sync-source", as = "sy
|
|
|
2852
3072
|
"you",
|
|
2853
3073
|
"your"
|
|
2854
3074
|
]);
|
|
2855
|
-
function
|
|
3075
|
+
function Ur(e) {
|
|
2856
3076
|
const t = /* @__PURE__ */ new Set();
|
|
2857
3077
|
for (const n of e.toLowerCase().split(/[^a-z0-9À-ɏ]+/))
|
|
2858
|
-
n.length <
|
|
3078
|
+
n.length < Lr || Pr.has(n) || t.add(n);
|
|
2859
3079
|
return [...t];
|
|
2860
3080
|
}
|
|
2861
|
-
function
|
|
3081
|
+
function Kr(e, t) {
|
|
2862
3082
|
if (!e.length) return 0;
|
|
2863
3083
|
if (!t.length) return 1;
|
|
2864
3084
|
const n = new Set(t), r = new Set(e);
|
|
@@ -2866,38 +3086,38 @@ function sr(e, t) {
|
|
|
2866
3086
|
for (const o of r) n.has(o) || (i += 1);
|
|
2867
3087
|
return i / r.size;
|
|
2868
3088
|
}
|
|
2869
|
-
function
|
|
3089
|
+
function Br(e, t = Nr) {
|
|
2870
3090
|
const n = e.filter((a) => !a.partial && typeof a.text == "string");
|
|
2871
3091
|
if (!n.length) return { text: "", segmentCount: 0 };
|
|
2872
3092
|
const i = n.reduce((a, s) => Math.max(a, s.endedAt ?? 0), 0) - t;
|
|
2873
|
-
return { text: n.filter((a) => (a.endedAt ?? 0) >= i).map((a) =>
|
|
3093
|
+
return { text: n.filter((a) => (a.endedAt ?? 0) >= i).map((a) => xr(a.text).trim()).filter(Boolean).join(" ").replace(/\s+/g, " ").trim(), segmentCount: n.length };
|
|
2874
3094
|
}
|
|
2875
|
-
const
|
|
2876
|
-
function
|
|
3095
|
+
const jr = 60;
|
|
3096
|
+
function Js(e, t, n = jr) {
|
|
2877
3097
|
const r = new Set(e), i = [...e];
|
|
2878
3098
|
for (const o of t)
|
|
2879
3099
|
!o || r.has(o) || (r.add(o), i.push(o));
|
|
2880
3100
|
return i.slice(-n);
|
|
2881
3101
|
}
|
|
2882
|
-
function
|
|
3102
|
+
function Zs(e) {
|
|
2883
3103
|
const { segments: t, now: n, state: r } = e;
|
|
2884
|
-
if (r.lastTriggerAt && n - r.lastTriggerAt <
|
|
3104
|
+
if (r.lastTriggerAt && n - r.lastTriggerAt < Rr)
|
|
2885
3105
|
return { trigger: !1, reason: "too_soon" };
|
|
2886
|
-
const i =
|
|
3106
|
+
const i = Br(t, e.windowMs);
|
|
2887
3107
|
if (!i.text) return { trigger: !1, reason: "no_speech" };
|
|
2888
3108
|
const o = i.segmentCount - (r.lastSegmentCount ?? 0);
|
|
2889
|
-
if (r.lastQueryTerms && o <
|
|
3109
|
+
if (r.lastQueryTerms && o < Dr)
|
|
2890
3110
|
return { trigger: !1, reason: "too_few_new" };
|
|
2891
|
-
const a =
|
|
2892
|
-
return a.length ? r.lastQueryTerms?.length &&
|
|
3111
|
+
const a = Ur(i.text);
|
|
3112
|
+
return a.length ? r.lastQueryTerms?.length && Kr(a, r.lastQueryTerms) < $r ? { trigger: !1, reason: "same_topic" } : { trigger: !0, text: i.text, terms: a, segmentCount: i.segmentCount } : { trigger: !1, reason: "no_speech" };
|
|
2893
3113
|
}
|
|
2894
|
-
const
|
|
3114
|
+
const Qs = [
|
|
2895
3115
|
"personal",
|
|
2896
3116
|
"workspace",
|
|
2897
3117
|
"connections",
|
|
2898
3118
|
"work",
|
|
2899
3119
|
"ai"
|
|
2900
|
-
],
|
|
3120
|
+
], ec = "navNotice", oe = {
|
|
2901
3121
|
// The lower bounds are deliberately generous: service ranges (0800/0900) are
|
|
2902
3122
|
// shorter than geographic numbers, and a too-strict minimum silently drops them.
|
|
2903
3123
|
// An over-permissive key is harmless — it simply matches nothing.
|
|
@@ -2920,81 +3140,81 @@ const us = [
|
|
|
2920
3140
|
PL: { callingCode: "48", nsnMin: 9, nsnMax: 9 },
|
|
2921
3141
|
US: { callingCode: "1", nsnMin: 10, nsnMax: 10 },
|
|
2922
3142
|
CA: { callingCode: "1", nsnMin: 10, nsnMax: 10 }
|
|
2923
|
-
},
|
|
2924
|
-
new Set(Object.values(
|
|
3143
|
+
}, Hr = "NL", Gr = 15, Fr = 8, Wr = Array.from(
|
|
3144
|
+
new Set(Object.values(oe).map((e) => e.callingCode))
|
|
2925
3145
|
).sort((e, t) => t.length - e.length);
|
|
2926
|
-
function
|
|
3146
|
+
function xe(e) {
|
|
2927
3147
|
if (e)
|
|
2928
|
-
return
|
|
3148
|
+
return oe[e.trim().toUpperCase()];
|
|
2929
3149
|
}
|
|
2930
|
-
function
|
|
3150
|
+
function L(e, t) {
|
|
2931
3151
|
return e.length >= t.nsnMin && e.length <= t.nsnMax;
|
|
2932
3152
|
}
|
|
2933
|
-
function
|
|
2934
|
-
if (e.length >
|
|
2935
|
-
for (const t of
|
|
3153
|
+
function Ne(e) {
|
|
3154
|
+
if (e.length > Gr) return null;
|
|
3155
|
+
for (const t of Wr) {
|
|
2936
3156
|
if (!e.startsWith(t)) continue;
|
|
2937
3157
|
const n = e.slice(t.length);
|
|
2938
|
-
for (const r of Object.values(
|
|
3158
|
+
for (const r of Object.values(oe)) {
|
|
2939
3159
|
if (r.callingCode !== t) continue;
|
|
2940
3160
|
const i = r.trunkPrefix, o = i && n.startsWith(i) ? n.slice(i.length) : n;
|
|
2941
|
-
if (
|
|
3161
|
+
if (L(o, r)) return `+${t}${o}`;
|
|
2942
3162
|
}
|
|
2943
3163
|
return null;
|
|
2944
3164
|
}
|
|
2945
|
-
return e.length <
|
|
3165
|
+
return e.length < Fr ? null : `+${e}`;
|
|
2946
3166
|
}
|
|
2947
|
-
function
|
|
3167
|
+
function Vr(e) {
|
|
2948
3168
|
let t = e.trim();
|
|
2949
3169
|
const n = t.match(/^(sips?|tel|whatsapp):/i);
|
|
2950
3170
|
n && (t = t.slice(n[0].length));
|
|
2951
3171
|
const r = t.indexOf("@");
|
|
2952
3172
|
return r >= 0 && (t = t.slice(0, r)), t.trim();
|
|
2953
3173
|
}
|
|
2954
|
-
function
|
|
3174
|
+
function tc(e) {
|
|
2955
3175
|
if (!e) return !1;
|
|
2956
3176
|
const t = e.indexOf("@");
|
|
2957
3177
|
if (t <= 0) return !1;
|
|
2958
3178
|
const n = e.slice(0, t).trim();
|
|
2959
3179
|
return !/^[+\d\s().-]+$/.test(n);
|
|
2960
3180
|
}
|
|
2961
|
-
function
|
|
3181
|
+
function Re(e, t) {
|
|
2962
3182
|
if (!e) return null;
|
|
2963
|
-
const n =
|
|
3183
|
+
const n = Vr(e);
|
|
2964
3184
|
if (!n) return null;
|
|
2965
3185
|
const r = n.startsWith("+"), i = n.replace(/\D/g, "");
|
|
2966
3186
|
if (!i) return null;
|
|
2967
|
-
if (r) return
|
|
2968
|
-
if (i.startsWith("00")) return
|
|
2969
|
-
const o =
|
|
3187
|
+
if (r) return Ne(i);
|
|
3188
|
+
if (i.startsWith("00")) return Ne(i.slice(2));
|
|
3189
|
+
const o = xe(t) ?? xe(Hr);
|
|
2970
3190
|
if (!o) return null;
|
|
2971
3191
|
const a = o.trunkPrefix;
|
|
2972
3192
|
if (a && i.startsWith(a)) {
|
|
2973
3193
|
const s = i.slice(a.length);
|
|
2974
|
-
return
|
|
3194
|
+
return L(s, o) ? `+${o.callingCode}${s}` : null;
|
|
2975
3195
|
}
|
|
2976
3196
|
if (i.startsWith(o.callingCode)) {
|
|
2977
3197
|
const s = i.slice(o.callingCode.length);
|
|
2978
|
-
if (
|
|
3198
|
+
if (L(s, o)) return `+${o.callingCode}${s}`;
|
|
2979
3199
|
}
|
|
2980
|
-
return !a &&
|
|
3200
|
+
return !a && L(i, o) ? `+${o.callingCode}${i}` : null;
|
|
2981
3201
|
}
|
|
2982
|
-
function
|
|
3202
|
+
function nc(e, t = 9) {
|
|
2983
3203
|
const n = (e ?? "").replace(/\D/g, "");
|
|
2984
3204
|
return n.length < t ? null : n.slice(-t);
|
|
2985
3205
|
}
|
|
2986
|
-
function
|
|
3206
|
+
function ft(e) {
|
|
2987
3207
|
if (!e) return null;
|
|
2988
3208
|
const t = e.trim().toLowerCase(), n = t.lastIndexOf("@");
|
|
2989
3209
|
if (n <= 0 || n === t.length - 1) return null;
|
|
2990
3210
|
const r = t.slice(0, n).split("+")[0], i = t.slice(n + 1);
|
|
2991
3211
|
return !r || !i.includes(".") ? null : `${r}@${i}`;
|
|
2992
3212
|
}
|
|
2993
|
-
function
|
|
2994
|
-
const t =
|
|
3213
|
+
function rc(e) {
|
|
3214
|
+
const t = ft(e);
|
|
2995
3215
|
return t ? t.slice(t.lastIndexOf("@") + 1) : null;
|
|
2996
3216
|
}
|
|
2997
|
-
const
|
|
3217
|
+
const zr = /* @__PURE__ */ new Set([
|
|
2998
3218
|
"co.uk",
|
|
2999
3219
|
"org.uk",
|
|
3000
3220
|
"gov.uk",
|
|
@@ -3004,14 +3224,14 @@ const gr = /* @__PURE__ */ new Set([
|
|
|
3004
3224
|
"com.br",
|
|
3005
3225
|
"co.za"
|
|
3006
3226
|
]);
|
|
3007
|
-
function
|
|
3227
|
+
function Xr(e) {
|
|
3008
3228
|
if (!e) return null;
|
|
3009
3229
|
const t = e.trim().toLowerCase().replace(/\.$/, "").split(".").filter(Boolean);
|
|
3010
3230
|
if (t.length < 2) return null;
|
|
3011
3231
|
const n = t.slice(-2).join(".");
|
|
3012
|
-
return
|
|
3232
|
+
return zr.has(n) && t.length >= 3 ? t.slice(-3).join(".") : n;
|
|
3013
3233
|
}
|
|
3014
|
-
const
|
|
3234
|
+
const Yr = /* @__PURE__ */ new Set([
|
|
3015
3235
|
"gmail.com",
|
|
3016
3236
|
"googlemail.com",
|
|
3017
3237
|
"outlook.com",
|
|
@@ -3056,34 +3276,34 @@ const yr = /* @__PURE__ */ new Set([
|
|
|
3056
3276
|
"proximus.be",
|
|
3057
3277
|
"scarlet.be"
|
|
3058
3278
|
]);
|
|
3059
|
-
function
|
|
3060
|
-
const t =
|
|
3061
|
-
return t ?
|
|
3279
|
+
function ic(e) {
|
|
3280
|
+
const t = Xr(e);
|
|
3281
|
+
return t ? Yr.has(t) : !1;
|
|
3062
3282
|
}
|
|
3063
|
-
function
|
|
3283
|
+
function oc(e) {
|
|
3064
3284
|
if (!e) return !1;
|
|
3065
3285
|
const t = e.trim().toLowerCase();
|
|
3066
3286
|
return t === "tel" || t === "sms" || t === "whatsapp" || t === "fax";
|
|
3067
3287
|
}
|
|
3068
|
-
function
|
|
3288
|
+
function ac(e, t, n) {
|
|
3069
3289
|
if (!e || !t) return null;
|
|
3070
3290
|
const r = e.trim().toLowerCase();
|
|
3071
3291
|
if (r === "tel" || r === "sms" || r === "whatsapp") {
|
|
3072
|
-
const o =
|
|
3292
|
+
const o = Re(t, n);
|
|
3073
3293
|
return o ? `tel:${o}` : null;
|
|
3074
3294
|
}
|
|
3075
3295
|
if (r === "fax") {
|
|
3076
|
-
const o =
|
|
3296
|
+
const o = Re(t, n);
|
|
3077
3297
|
return o ? `fax:${o}` : null;
|
|
3078
3298
|
}
|
|
3079
3299
|
if (r === "mailto" || r === "email") {
|
|
3080
|
-
const o =
|
|
3300
|
+
const o = ft(t);
|
|
3081
3301
|
return o ? `mailto:${o}` : null;
|
|
3082
3302
|
}
|
|
3083
3303
|
const i = t.trim().toLowerCase();
|
|
3084
3304
|
return i ? `${r}:${i}` : null;
|
|
3085
3305
|
}
|
|
3086
|
-
const
|
|
3306
|
+
const qr = [
|
|
3087
3307
|
/<blockquote/i,
|
|
3088
3308
|
/class="?gmail_quote/i,
|
|
3089
3309
|
// Gmail quote container
|
|
@@ -3096,72 +3316,72 @@ const br = [
|
|
|
3096
3316
|
// Outlook underscore separator before "From:"
|
|
3097
3317
|
/\bOn\b[\s\S]{0,200}?\bwrote:/i
|
|
3098
3318
|
// Gmail "On <date> <name> wrote:"
|
|
3099
|
-
],
|
|
3100
|
-
function
|
|
3319
|
+
], De = /^\s*(?:>+\s*)?(?:from|van|sent|verzonden|to|aan|cc|subject|onderwerp|date|datum)\s*:/i, Jr = /^\s*(?:on|op)\b.{0,200}?\b(?:wrote|schreef|geschreven)\s*:?\s*$/i;
|
|
3320
|
+
function Zr(e) {
|
|
3101
3321
|
const t = e.split(`
|
|
3102
3322
|
`);
|
|
3103
3323
|
for (let n = 0; n < t.length; n++)
|
|
3104
|
-
if (
|
|
3324
|
+
if (Jr.test(t[n]) || De.test(t[n]) && t.slice(n + 1, n + 4).some((r) => De.test(r)))
|
|
3105
3325
|
return t.slice(0, n).join(`
|
|
3106
3326
|
`).trim();
|
|
3107
3327
|
return e;
|
|
3108
3328
|
}
|
|
3109
|
-
const
|
|
3110
|
-
function
|
|
3329
|
+
const Qr = /^(?:https?:|mailto:|tel:)/i, ei = /^(?:https?:|cid:|data:image\/)/i;
|
|
3330
|
+
function V(e, t) {
|
|
3111
3331
|
const n = e.match(new RegExp(`\\b${t}\\s*=\\s*(?:"([^"]*)"|'([^']*)'|([^\\s">]+))`, "i"));
|
|
3112
3332
|
return (n?.[1] ?? n?.[2] ?? n?.[3] ?? "").trim();
|
|
3113
3333
|
}
|
|
3114
|
-
const
|
|
3115
|
-
function
|
|
3116
|
-
return e.replace(/\s+/g, " ").trim().split(
|
|
3334
|
+
const ti = /(!\[[^\]]*\]\([^)]*\))/;
|
|
3335
|
+
function $e(e) {
|
|
3336
|
+
return e.replace(/\s+/g, " ").trim().split(ti).map((t, n) => n % 2 === 1 ? t : t.replace(/[[\]]/g, "\\$&")).join("");
|
|
3117
3337
|
}
|
|
3118
|
-
function
|
|
3338
|
+
function z(e) {
|
|
3119
3339
|
return e.replace(
|
|
3120
3340
|
/[()\s<>"]/g,
|
|
3121
3341
|
(t) => `%${t.charCodeAt(0).toString(16).toUpperCase().padStart(2, "0")}`
|
|
3122
3342
|
);
|
|
3123
3343
|
}
|
|
3124
|
-
function
|
|
3344
|
+
function ni(e) {
|
|
3125
3345
|
return e.replace(/<img\b([^>]*?)\/?>/gi, (n, r) => {
|
|
3126
|
-
const i =
|
|
3127
|
-
return
|
|
3346
|
+
const i = V(r, "src");
|
|
3347
|
+
return ei.test(i) ? `})` : "";
|
|
3128
3348
|
}).replace(
|
|
3129
3349
|
/<a\b([^>]*)>([\s\S]*?)<\/a\s*>/gi,
|
|
3130
3350
|
(n, r, i) => {
|
|
3131
|
-
const o =
|
|
3132
|
-
return
|
|
3351
|
+
const o = $e(i.replace(/<[^>]*>/g, "")), a = V(r, "href");
|
|
3352
|
+
return Qr.test(a) ? `[${o || z(a)}](${z(a)})` : o;
|
|
3133
3353
|
}
|
|
3134
3354
|
);
|
|
3135
3355
|
}
|
|
3136
|
-
const
|
|
3137
|
-
function
|
|
3356
|
+
const ri = /<table\b[^>]*>((?:(?!<table\b)[\s\S])*?)<\/table\s*>/i, ii = /<tr\b[^>]*>([\s\S]*?)<\/tr\s*>/gi, oi = /<(t[dh])\b([^>]*)>([\s\S]*?)<\/\1\s*>/gi;
|
|
3357
|
+
function ai(e, t) {
|
|
3138
3358
|
return /<table\b/i.test(e) || e.includes(`
|
|
3139
3359
|
|
|
3140
3360
|
|`) || t.includes("![") || t.length > 200;
|
|
3141
3361
|
}
|
|
3142
|
-
const
|
|
3143
|
-
function
|
|
3362
|
+
const si = 40, ci = { left: "---", center: ":---:", right: "---:" };
|
|
3363
|
+
function li(e) {
|
|
3144
3364
|
const t = e.match(/align\s*[=:]\s*["']?\s*(right|center)/i);
|
|
3145
3365
|
return t ? t[1].toLowerCase() : "left";
|
|
3146
3366
|
}
|
|
3147
|
-
function
|
|
3367
|
+
function ui(e) {
|
|
3148
3368
|
return e.replace(/<[^>]*>/g, "").replace(/\s+/g, " ").trim().replace(/\|/g, "\\|");
|
|
3149
3369
|
}
|
|
3150
|
-
function
|
|
3370
|
+
function di(e) {
|
|
3151
3371
|
const t = [];
|
|
3152
|
-
for (const a of e.matchAll(
|
|
3372
|
+
for (const a of e.matchAll(ii)) {
|
|
3153
3373
|
const s = [];
|
|
3154
|
-
for (const
|
|
3155
|
-
const
|
|
3156
|
-
if (
|
|
3157
|
-
s.push({ text:
|
|
3374
|
+
for (const c of a[1].matchAll(oi)) {
|
|
3375
|
+
const m = ui(c[3]);
|
|
3376
|
+
if (ai(c[3], m)) return null;
|
|
3377
|
+
s.push({ text: m, align: li(c[2]) });
|
|
3158
3378
|
}
|
|
3159
3379
|
if (s.length === 0) return null;
|
|
3160
|
-
s.some((
|
|
3380
|
+
s.some((c) => c.text !== "") && t.push(s);
|
|
3161
3381
|
}
|
|
3162
3382
|
const n = t[0]?.length ?? 0;
|
|
3163
3383
|
if (t.length < 2 || n < 2 || t.some((a) => a.length !== n)) return null;
|
|
3164
|
-
const r = (a) => `| ${a.map((s) => s.text).join(" | ")} |`, i = t[1].map((a) =>
|
|
3384
|
+
const r = (a) => `| ${a.map((s) => s.text).join(" | ")} |`, i = t[1].map((a) => ci[a.align]).join(" | "), o = t.slice(1).map(r).join(`
|
|
3165
3385
|
`);
|
|
3166
3386
|
return `
|
|
3167
3387
|
|
|
@@ -3171,36 +3391,36 @@ ${o}
|
|
|
3171
3391
|
|
|
3172
3392
|
`;
|
|
3173
3393
|
}
|
|
3174
|
-
function
|
|
3394
|
+
function pi(e) {
|
|
3175
3395
|
return e.replace(/<\/(t[dh])\s*>/gi, " ").replace(/<\/tr\s*>/gi, `
|
|
3176
3396
|
`).replace(/<(?:tbody|thead|tfoot|caption|colgroup|col|tr|t[dh])\b[^>]*>/gi, "").replace(/<\/(?:tbody|thead|tfoot|caption|colgroup)\s*>/gi, "");
|
|
3177
3397
|
}
|
|
3178
|
-
function
|
|
3398
|
+
function fi(e) {
|
|
3179
3399
|
let t = e;
|
|
3180
|
-
for (let n = 0; n <
|
|
3181
|
-
const r =
|
|
3400
|
+
for (let n = 0; n < si; n++) {
|
|
3401
|
+
const r = ri.exec(t);
|
|
3182
3402
|
if (!r || r.index === void 0) break;
|
|
3183
|
-
const o =
|
|
3403
|
+
const o = di(r[1]) ?? `
|
|
3184
3404
|
|
|
3185
|
-
${
|
|
3405
|
+
${pi(r[1])}
|
|
3186
3406
|
|
|
3187
3407
|
`;
|
|
3188
3408
|
t = t.slice(0, r.index) + o + t.slice(r.index + r[0].length);
|
|
3189
3409
|
}
|
|
3190
3410
|
return t;
|
|
3191
3411
|
}
|
|
3192
|
-
function
|
|
3412
|
+
function Le(e, t) {
|
|
3193
3413
|
let n = e;
|
|
3194
3414
|
return n = n.replace(/<(script|style)[\s\S]*?<\/\1>/gi, ""), n = n.replace(/<!--[\s\S]*?-->/g, ""), n = n.replace(/<br\s*\/?>/gi, `
|
|
3195
|
-
`), t && (n =
|
|
3415
|
+
`), t && (n = fi(ni(n))), n = n.replace(/<\/(p|h[1-6]|ul|ol|table|blockquote)>/gi, `
|
|
3196
3416
|
|
|
3197
3417
|
`), n = n.replace(/<\/(div|li|tr)>/gi, `
|
|
3198
3418
|
`), n = n.replace(/<\/(td|th)>/gi, " "), n = n.replace(/<[^>]+>/g, ""), n = n.replace(/<[^>]*$/, ""), n;
|
|
3199
3419
|
}
|
|
3200
|
-
function
|
|
3420
|
+
function Pe(e) {
|
|
3201
3421
|
return !Number.isInteger(e) || e < 0 || e > 1114111 ? null : String.fromCodePoint(e);
|
|
3202
3422
|
}
|
|
3203
|
-
const
|
|
3423
|
+
const mi = {
|
|
3204
3424
|
euro: "€",
|
|
3205
3425
|
pound: "£",
|
|
3206
3426
|
yen: "¥",
|
|
@@ -3222,368 +3442,386 @@ const Lr = {
|
|
|
3222
3442
|
rdquo: "”",
|
|
3223
3443
|
apos: "'"
|
|
3224
3444
|
};
|
|
3225
|
-
function
|
|
3226
|
-
return e.replace(/ /gi, " ").replace(/&([a-z]+);/gi, (t, n) =>
|
|
3445
|
+
function Ue(e) {
|
|
3446
|
+
return e.replace(/ /gi, " ").replace(/&([a-z]+);/gi, (t, n) => mi[n.toLowerCase()] ?? t).replace(/</gi, "<").replace(/>/gi, ">").replace(/"/gi, '"').replace(/&#(\d+);/g, (t, n) => Pe(Number(n)) ?? t).replace(/&#x([0-9a-f]+);/gi, (t, n) => Pe(parseInt(n, 16)) ?? t).replace(/&/gi, "&");
|
|
3227
3447
|
}
|
|
3228
|
-
function
|
|
3448
|
+
function Ke(e) {
|
|
3229
3449
|
return e.replace(/\r/g, "").replace(/[ \t]+/g, " ").replace(/ *\n */g, `
|
|
3230
3450
|
`).replace(/\n{3,}/g, `
|
|
3231
3451
|
|
|
3232
3452
|
`).trim();
|
|
3233
3453
|
}
|
|
3234
|
-
const
|
|
3235
|
-
function
|
|
3236
|
-
return
|
|
3454
|
+
const gi = /<\s*(html|body|div|p|table|br|span)\b/i;
|
|
3455
|
+
function sc(e) {
|
|
3456
|
+
return gi.test(e);
|
|
3237
3457
|
}
|
|
3238
|
-
function
|
|
3239
|
-
return
|
|
3458
|
+
function cc(e) {
|
|
3459
|
+
return mt(e, !1);
|
|
3240
3460
|
}
|
|
3241
|
-
function
|
|
3242
|
-
return
|
|
3461
|
+
function lc(e) {
|
|
3462
|
+
return mt(e, !0);
|
|
3243
3463
|
}
|
|
3244
|
-
function
|
|
3464
|
+
function mt(e, t) {
|
|
3245
3465
|
if (typeof e != "string" || !e) return "";
|
|
3246
3466
|
let n = e.length;
|
|
3247
|
-
for (const a of
|
|
3467
|
+
for (const a of qr) {
|
|
3248
3468
|
const s = e.search(a);
|
|
3249
3469
|
s >= 0 && s < n && (n = s);
|
|
3250
3470
|
}
|
|
3251
3471
|
const r = e.slice(0, n);
|
|
3252
|
-
let i =
|
|
3253
|
-
return i || (i =
|
|
3472
|
+
let i = Ke(Ue(Le(r, t)));
|
|
3473
|
+
return i || (i = Ke(Ue(Le(e, t)))), Zr(i) || i;
|
|
3254
3474
|
}
|
|
3255
3475
|
export {
|
|
3256
|
-
|
|
3257
|
-
|
|
3258
|
-
|
|
3259
|
-
|
|
3260
|
-
|
|
3261
|
-
|
|
3262
|
-
|
|
3263
|
-
|
|
3264
|
-
|
|
3265
|
-
|
|
3266
|
-
|
|
3267
|
-
|
|
3268
|
-
|
|
3269
|
-
|
|
3270
|
-
|
|
3271
|
-
|
|
3272
|
-
|
|
3273
|
-
|
|
3274
|
-
|
|
3275
|
-
|
|
3276
|
-
|
|
3277
|
-
|
|
3278
|
-
|
|
3279
|
-
|
|
3280
|
-
|
|
3281
|
-
|
|
3282
|
-
|
|
3283
|
-
|
|
3284
|
-
|
|
3285
|
-
|
|
3286
|
-
|
|
3287
|
-
|
|
3288
|
-
|
|
3289
|
-
|
|
3290
|
-
|
|
3291
|
-
|
|
3292
|
-
|
|
3293
|
-
|
|
3294
|
-
|
|
3295
|
-
|
|
3296
|
-
|
|
3297
|
-
|
|
3298
|
-
|
|
3299
|
-
|
|
3300
|
-
|
|
3301
|
-
|
|
3302
|
-
|
|
3303
|
-
|
|
3304
|
-
|
|
3305
|
-
|
|
3306
|
-
|
|
3307
|
-
|
|
3308
|
-
|
|
3309
|
-
|
|
3310
|
-
|
|
3311
|
-
|
|
3312
|
-
|
|
3313
|
-
|
|
3314
|
-
|
|
3315
|
-
|
|
3316
|
-
|
|
3317
|
-
|
|
3318
|
-
|
|
3319
|
-
|
|
3320
|
-
|
|
3321
|
-
|
|
3322
|
-
|
|
3323
|
-
|
|
3324
|
-
|
|
3325
|
-
|
|
3326
|
-
|
|
3327
|
-
|
|
3328
|
-
|
|
3329
|
-
|
|
3330
|
-
|
|
3331
|
-
|
|
3332
|
-
|
|
3333
|
-
|
|
3334
|
-
|
|
3335
|
-
|
|
3336
|
-
|
|
3337
|
-
|
|
3338
|
-
|
|
3339
|
-
|
|
3340
|
-
|
|
3341
|
-
|
|
3342
|
-
|
|
3343
|
-
|
|
3344
|
-
|
|
3345
|
-
|
|
3346
|
-
|
|
3347
|
-
|
|
3348
|
-
|
|
3349
|
-
|
|
3350
|
-
|
|
3351
|
-
|
|
3352
|
-
|
|
3353
|
-
|
|
3354
|
-
|
|
3355
|
-
|
|
3356
|
-
|
|
3357
|
-
|
|
3358
|
-
|
|
3359
|
-
|
|
3360
|
-
|
|
3361
|
-
|
|
3362
|
-
|
|
3363
|
-
|
|
3364
|
-
|
|
3365
|
-
|
|
3366
|
-
|
|
3367
|
-
|
|
3368
|
-
|
|
3369
|
-
|
|
3370
|
-
|
|
3371
|
-
|
|
3372
|
-
|
|
3373
|
-
|
|
3374
|
-
|
|
3375
|
-
|
|
3376
|
-
|
|
3377
|
-
|
|
3378
|
-
|
|
3379
|
-
|
|
3380
|
-
|
|
3381
|
-
|
|
3382
|
-
|
|
3383
|
-
|
|
3384
|
-
|
|
3385
|
-
|
|
3386
|
-
|
|
3387
|
-
|
|
3388
|
-
|
|
3389
|
-
|
|
3390
|
-
|
|
3391
|
-
|
|
3392
|
-
|
|
3393
|
-
|
|
3394
|
-
|
|
3395
|
-
|
|
3396
|
-
|
|
3397
|
-
|
|
3398
|
-
|
|
3399
|
-
|
|
3400
|
-
|
|
3401
|
-
|
|
3402
|
-
|
|
3403
|
-
|
|
3404
|
-
|
|
3405
|
-
|
|
3406
|
-
|
|
3407
|
-
|
|
3408
|
-
|
|
3409
|
-
|
|
3410
|
-
|
|
3411
|
-
|
|
3412
|
-
|
|
3413
|
-
|
|
3414
|
-
|
|
3415
|
-
|
|
3416
|
-
|
|
3417
|
-
|
|
3418
|
-
|
|
3419
|
-
|
|
3420
|
-
|
|
3421
|
-
|
|
3422
|
-
|
|
3423
|
-
|
|
3424
|
-
|
|
3425
|
-
|
|
3426
|
-
|
|
3427
|
-
|
|
3428
|
-
|
|
3429
|
-
|
|
3430
|
-
|
|
3431
|
-
|
|
3432
|
-
|
|
3433
|
-
|
|
3434
|
-
|
|
3435
|
-
|
|
3436
|
-
|
|
3437
|
-
|
|
3438
|
-
|
|
3439
|
-
|
|
3440
|
-
|
|
3441
|
-
|
|
3442
|
-
|
|
3443
|
-
|
|
3444
|
-
|
|
3445
|
-
|
|
3446
|
-
|
|
3447
|
-
|
|
3448
|
-
|
|
3449
|
-
|
|
3450
|
-
|
|
3451
|
-
|
|
3452
|
-
|
|
3453
|
-
|
|
3454
|
-
|
|
3455
|
-
|
|
3456
|
-
|
|
3457
|
-
|
|
3458
|
-
|
|
3459
|
-
|
|
3460
|
-
|
|
3461
|
-
|
|
3462
|
-
|
|
3463
|
-
|
|
3464
|
-
|
|
3465
|
-
|
|
3466
|
-
|
|
3467
|
-
|
|
3468
|
-
|
|
3469
|
-
|
|
3470
|
-
|
|
3471
|
-
|
|
3472
|
-
|
|
3473
|
-
|
|
3474
|
-
|
|
3475
|
-
|
|
3476
|
-
|
|
3477
|
-
|
|
3478
|
-
|
|
3479
|
-
|
|
3480
|
-
|
|
3481
|
-
|
|
3482
|
-
|
|
3483
|
-
|
|
3484
|
-
|
|
3485
|
-
|
|
3486
|
-
|
|
3487
|
-
|
|
3488
|
-
|
|
3489
|
-
|
|
3490
|
-
|
|
3491
|
-
|
|
3492
|
-
|
|
3493
|
-
|
|
3494
|
-
|
|
3495
|
-
|
|
3496
|
-
|
|
3497
|
-
|
|
3498
|
-
|
|
3499
|
-
|
|
3500
|
-
|
|
3501
|
-
|
|
3502
|
-
|
|
3503
|
-
|
|
3504
|
-
|
|
3505
|
-
|
|
3506
|
-
|
|
3507
|
-
|
|
3508
|
-
|
|
3509
|
-
|
|
3510
|
-
|
|
3511
|
-
|
|
3512
|
-
|
|
3513
|
-
|
|
3514
|
-
|
|
3515
|
-
|
|
3516
|
-
|
|
3517
|
-
|
|
3518
|
-
|
|
3519
|
-
|
|
3520
|
-
|
|
3521
|
-
|
|
3522
|
-
|
|
3523
|
-
|
|
3524
|
-
|
|
3525
|
-
|
|
3526
|
-
|
|
3527
|
-
|
|
3528
|
-
|
|
3529
|
-
|
|
3530
|
-
|
|
3531
|
-
|
|
3532
|
-
|
|
3533
|
-
|
|
3534
|
-
|
|
3535
|
-
|
|
3536
|
-
|
|
3537
|
-
|
|
3538
|
-
|
|
3539
|
-
|
|
3540
|
-
|
|
3541
|
-
|
|
3542
|
-
|
|
3543
|
-
|
|
3544
|
-
|
|
3545
|
-
|
|
3546
|
-
|
|
3547
|
-
|
|
3548
|
-
|
|
3549
|
-
|
|
3550
|
-
|
|
3551
|
-
|
|
3552
|
-
|
|
3553
|
-
|
|
3554
|
-
|
|
3555
|
-
|
|
3556
|
-
|
|
3557
|
-
|
|
3558
|
-
|
|
3559
|
-
|
|
3560
|
-
|
|
3561
|
-
|
|
3562
|
-
|
|
3563
|
-
|
|
3564
|
-
|
|
3565
|
-
|
|
3566
|
-
|
|
3567
|
-
|
|
3568
|
-
|
|
3569
|
-
|
|
3570
|
-
|
|
3571
|
-
|
|
3572
|
-
|
|
3573
|
-
|
|
3574
|
-
|
|
3575
|
-
|
|
3576
|
-
|
|
3577
|
-
|
|
3578
|
-
|
|
3579
|
-
|
|
3580
|
-
|
|
3581
|
-
|
|
3582
|
-
|
|
3583
|
-
|
|
3584
|
-
|
|
3585
|
-
|
|
3586
|
-
|
|
3587
|
-
|
|
3588
|
-
|
|
3476
|
+
no as ACTIVE_ASSIGNMENT_STATUSES,
|
|
3477
|
+
_ as ACTIVITY_CATALOG,
|
|
3478
|
+
dr as AI_ATTACHMENT_LIMITS,
|
|
3479
|
+
za as AI_ATTACHMENT_MAX_PER_TURN,
|
|
3480
|
+
Va as AI_ATTACHMENT_TURN_BUDGET,
|
|
3481
|
+
He as AI_VENDORS,
|
|
3482
|
+
Pt as ALLOWED_LINK_SCHEMES,
|
|
3483
|
+
ks as APP_PERMISSIONS,
|
|
3484
|
+
me as ARTIFACT_MAX_BLOCKS,
|
|
3485
|
+
Xi as ARTIFACT_MAX_BODY_BYTES,
|
|
3486
|
+
F as ARTIFACT_MAX_CELL_LEN,
|
|
3487
|
+
be as ARTIFACT_MAX_KPI_ITEMS,
|
|
3488
|
+
ge as ARTIFACT_MAX_LIST_ITEMS,
|
|
3489
|
+
ye as ARTIFACT_MAX_TABLE_COLUMNS,
|
|
3490
|
+
he as ARTIFACT_MAX_TABLE_ROWS,
|
|
3491
|
+
Fe as ARTIFACT_MAX_TEXT_LEN,
|
|
3492
|
+
Vt as ASSIGNMENT_SCOPE_KIND,
|
|
3493
|
+
Za as ASSIST_BANDS,
|
|
3494
|
+
Ja as ASSIST_SOURCE_PROVIDER_GROUP,
|
|
3495
|
+
an as ATTENTION_STATUSES,
|
|
3496
|
+
dt as AUTH_APP_NAME,
|
|
3497
|
+
Nn as AUTO_READY_MIN_PROPOSALS,
|
|
3498
|
+
Rn as AUTO_READY_RATE,
|
|
3499
|
+
Mt as ActivityTypeRegistry,
|
|
3500
|
+
Ri as BUILT_IN_ONLY,
|
|
3501
|
+
sn as BULK_PENALTY,
|
|
3502
|
+
Rr as CADENCE_FLOOR_MS,
|
|
3503
|
+
Dr as CADENCE_MIN_NEW_SEGMENTS,
|
|
3504
|
+
$r as CADENCE_MIN_NOVELTY,
|
|
3505
|
+
Nr as CADENCE_WINDOW_MS,
|
|
3506
|
+
Qo as CLASSIFY_VARS,
|
|
3507
|
+
bs as CONTEXT_COLLECT_SERVICE,
|
|
3508
|
+
Wi as CORE_DIMENSIONS,
|
|
3509
|
+
yr as CommunicationScheme,
|
|
3510
|
+
qt as DAY_MS,
|
|
3511
|
+
Ko as DEFAULT_MEMORY_BUDGET,
|
|
3512
|
+
Hr as DEFAULT_PHONE_REGION,
|
|
3513
|
+
Ts as DOCUMENT_APPLY_SERVICE,
|
|
3514
|
+
Ss as DOCUMENT_DESCRIBE_SERVICE,
|
|
3515
|
+
_s as DOCUMENT_INSPECT_SERVICE,
|
|
3516
|
+
ct as DOCUMENT_OPERATIONS,
|
|
3517
|
+
ta as EMPTY_WORKFLOW,
|
|
3518
|
+
ms as FEATURE_FOLDER_MANAGEMENT,
|
|
3519
|
+
hs as FEATURE_MESSAGE_REACTIONS,
|
|
3520
|
+
gs as FEATURE_REMOTE_SEARCH,
|
|
3521
|
+
ln as FOLLOW_UP_HOURS,
|
|
3522
|
+
Yt as HOUR_MS,
|
|
3523
|
+
gi as HTML_BODY_RE,
|
|
3524
|
+
w as INELIGIBLE,
|
|
3525
|
+
Is as INSTALLATION_HEADER,
|
|
3526
|
+
On as INTERACTION_KIND,
|
|
3527
|
+
ps as InteractionParticipantRole,
|
|
3528
|
+
yn as KB_FALLBACK_LOCALE,
|
|
3529
|
+
_e as KB_LOCALES,
|
|
3530
|
+
ie as LOOSE_STATUSES,
|
|
3531
|
+
tn as MAIL_HINT_HEADERS,
|
|
3532
|
+
Ai as MAX_ACTIONS,
|
|
3533
|
+
zt as MAX_ASSIGNMENT_TURNS,
|
|
3534
|
+
hi as MAX_BLOCKS,
|
|
3535
|
+
Ze as MAX_COLLECTION_DEPTH,
|
|
3536
|
+
Ws as MAX_EDITABLE_FILE_BYTES,
|
|
3537
|
+
yi as MAX_FIELDS,
|
|
3538
|
+
bi as MAX_LIST_ITEMS,
|
|
3539
|
+
$o as MAX_MEMORY_BROWSE,
|
|
3540
|
+
Uo as MAX_MEMORY_BUDGET,
|
|
3541
|
+
Lo as MAX_MEMORY_CHARS,
|
|
3542
|
+
jr as MAX_SHOWN_KEYS,
|
|
3543
|
+
Yn as MAX_TOPIC_CANDIDATES,
|
|
3544
|
+
Xn as MAX_TOPIC_EXAMPLES,
|
|
3545
|
+
W as MAX_TOPIC_EXAMPLE_CHARS,
|
|
3546
|
+
Vs as MAX_VIEWABLE_FILE_BYTES,
|
|
3547
|
+
Po as MIN_MEMORY_BUDGET,
|
|
3548
|
+
ec as NAV_NOTICE_SLOT,
|
|
3549
|
+
Os as NOTIFICATION_SOURCE_PROVIDER_GROUP,
|
|
3550
|
+
jo as ONBOARDING_SOURCE_PROVIDER_GROUP,
|
|
3551
|
+
Z as PAUSE_SNOOZED,
|
|
3552
|
+
Q as PAUSE_WAITING_FOR_CUSTOMER,
|
|
3553
|
+
oe as PHONE_REGIONS,
|
|
3554
|
+
lt as PRESENCE_ONLINE_WINDOW_MS,
|
|
3555
|
+
Tr as PRESENCE_SURVIVES_OFFLINE,
|
|
3556
|
+
Go as PROFILE_TOOL_DISPOSITIONS,
|
|
3557
|
+
ds as PROVIDER_FEATURE_MESSAGE_TEMPLATES,
|
|
3558
|
+
us as PROVIDER_FEATURE_MESSAGE_WINDOW,
|
|
3559
|
+
Yr as PUBLIC_EMAIL_DOMAINS,
|
|
3560
|
+
Te as READ_STEP_TYPES,
|
|
3561
|
+
En as RELATED_SUBJECT_KINDS,
|
|
3562
|
+
st as RESERVED_STATUS_KEYS,
|
|
3563
|
+
Ps as RESOURCE_ATTACHED_SERVICE,
|
|
3564
|
+
Ds as RESOURCE_DESCRIBE_SERVICE,
|
|
3565
|
+
Ls as RESOURCE_RESOLVE_SERVICE,
|
|
3566
|
+
$s as RESOURCE_SEARCH_SERVICE,
|
|
3567
|
+
Bs as SCOPE_READ_ROUTE,
|
|
3568
|
+
Ks as SCOPE_RELATED_ROUTE,
|
|
3569
|
+
Qs as SETTINGS_CATEGORIES,
|
|
3570
|
+
lo as SIGNATURE_INTENTS,
|
|
3571
|
+
cn as SLA_HOURS_BY_PRIORITY,
|
|
3572
|
+
fa as SLA_METRICS,
|
|
3573
|
+
ma as SLA_PAUSE_REASONS,
|
|
3574
|
+
vn as STEP_MAX_TOKENS_MAX,
|
|
3575
|
+
kn as STEP_MAX_TOKENS_MIN,
|
|
3576
|
+
en as SUMMARY_MIN_LAST_CHARS,
|
|
3577
|
+
Qt as SUMMARY_MIN_MESSAGES,
|
|
3578
|
+
Ys as SYNC_MAPPING_EXTERNAL_ID,
|
|
3579
|
+
qs as SYNC_RUN_MAX_ERRORS,
|
|
3580
|
+
zs as SYNC_SOURCE_PROVIDER_GROUP,
|
|
3581
|
+
Xs as SYNC_TARGET_PROVIDER_GROUP,
|
|
3582
|
+
Wt as TERMINAL_ASSIGNMENT_STATUSES,
|
|
3583
|
+
Dn as TERMINAL_RUN_STATUSES,
|
|
3584
|
+
Zo as TRIGGER_VARS,
|
|
3585
|
+
ys as UNSUPPORTED,
|
|
3586
|
+
Rt as USAGE_DIMENSIONS,
|
|
3587
|
+
Dt as USAGE_DIMENSION_IDS,
|
|
3588
|
+
nr as WORK_ACTIVITY_SCOPE_KIND,
|
|
3589
|
+
Ho as WORK_AREAS,
|
|
3590
|
+
xa as WORK_COMMENT_ADDED,
|
|
3591
|
+
Na as WORK_ITEM_ASSIGNED,
|
|
3592
|
+
er as WORK_ITEM_SCOPE_KIND,
|
|
3593
|
+
Ra as WORK_ITEM_STATUS_CHANGED,
|
|
3594
|
+
tr as WORK_PROJECT_SCOPE_KIND,
|
|
3595
|
+
P as W_PRIORITY,
|
|
3596
|
+
Ca as acceptExampleCandidate,
|
|
3597
|
+
_n as actingIdentityKey,
|
|
3598
|
+
Ma as activeWorkTypes,
|
|
3599
|
+
Si as activityIconOf,
|
|
3600
|
+
xi as activityJoinUrl,
|
|
3601
|
+
_t as activitySnippet,
|
|
3602
|
+
Tt as activityTextParams,
|
|
3603
|
+
vi as activityTimelineText,
|
|
3604
|
+
Ot as activityTimestamp,
|
|
3605
|
+
b as activityTypeInfo,
|
|
3606
|
+
Vo as actorKey,
|
|
3607
|
+
Oa as addExampleCandidate,
|
|
3608
|
+
ne as addWorkingMs,
|
|
3609
|
+
xs as agePresenceEntry,
|
|
3610
|
+
ur as aiAttachmentKind,
|
|
3611
|
+
Xa as aiAttachmentRejection,
|
|
3612
|
+
fe as aiBudgetLimit,
|
|
3613
|
+
Gi as aiBudgetPeriodKey,
|
|
3614
|
+
Ct as aiBudgetPeriodStart,
|
|
3615
|
+
Hi as aiBudgetState,
|
|
3616
|
+
ji as aiVendorAcceptsAttachment,
|
|
3617
|
+
Ui as aiVendorDefaultModel,
|
|
3618
|
+
Pi as aiVendorLabel,
|
|
3619
|
+
Bi as aiVendorNeedsBaseUrl,
|
|
3620
|
+
Ki as aiVendorsWith,
|
|
3621
|
+
pt as appNameFromPath,
|
|
3622
|
+
Sa as applyRounding,
|
|
3623
|
+
uo as applySignature,
|
|
3624
|
+
xn as approvalRate,
|
|
3625
|
+
qi as artifactBodyBytes,
|
|
3626
|
+
Ji as artifactOutline,
|
|
3627
|
+
Zi as artifactToMarkdown,
|
|
3628
|
+
qo as assignmentMismatch,
|
|
3629
|
+
io as assignmentScopeKey,
|
|
3630
|
+
so as assignmentSubject,
|
|
3631
|
+
Ni as buildActivityPreview,
|
|
3632
|
+
os as buildChannelIntents,
|
|
3633
|
+
Qi as buildShareKeys,
|
|
3634
|
+
Br as buildWindow,
|
|
3635
|
+
re as calendarOf,
|
|
3636
|
+
ko as canNestUnder,
|
|
3637
|
+
Mi as carriesText,
|
|
3638
|
+
xo as categoryLabel,
|
|
3639
|
+
or as categoryOf,
|
|
3640
|
+
ls as channelKindForScheme,
|
|
3641
|
+
_i as channelKindOf,
|
|
3642
|
+
ea as clampStepMaxTokens,
|
|
3643
|
+
yo as classifyMail,
|
|
3644
|
+
lc as cleanMessageMarkdown,
|
|
3645
|
+
cc as cleanMessageText,
|
|
3646
|
+
es as compareAssistRank,
|
|
3647
|
+
zn as compareWorkTypes,
|
|
3648
|
+
co as decideAssignmentState,
|
|
3649
|
+
Zs as decideCadence,
|
|
3650
|
+
rs as decideIncomingCall,
|
|
3651
|
+
bn as defaultLocaleOf,
|
|
3652
|
+
Ha as defaultStatusKey,
|
|
3653
|
+
fs as defineIntent,
|
|
3654
|
+
gn as depthOf,
|
|
3655
|
+
vs as derivePresence,
|
|
3656
|
+
is as disabledIntentsFromCapabilities,
|
|
3657
|
+
ws as documentKindOf,
|
|
3658
|
+
ha as dueAtOf,
|
|
3659
|
+
Ea as elapsedSeconds,
|
|
3660
|
+
rc as emailDomain,
|
|
3661
|
+
ac as endpointKey,
|
|
3662
|
+
Mr as extractParams,
|
|
3663
|
+
Ur as extractTerms,
|
|
3664
|
+
ss as filterByEndpoint,
|
|
3665
|
+
as as filterByIntent,
|
|
3666
|
+
hr as filterByTargetScheme,
|
|
3667
|
+
K as findAiVendor,
|
|
3668
|
+
Ms as flattenLocales,
|
|
3669
|
+
vt as floorToPeriod,
|
|
3670
|
+
Sn as formatActingIdentity,
|
|
3671
|
+
Ta as formatClock,
|
|
3672
|
+
_a as formatHm,
|
|
3673
|
+
La as formatItemKey,
|
|
3674
|
+
kt as formatPeriod,
|
|
3675
|
+
Aa as formatSlaDuration,
|
|
3676
|
+
qa as freshSources,
|
|
3677
|
+
Di as getActivitySeenUserIds,
|
|
3678
|
+
po as getContactEndpoints,
|
|
3679
|
+
wo as getShortTitle,
|
|
3680
|
+
To as getUrgencyScore,
|
|
3681
|
+
ua as hasReacted,
|
|
3682
|
+
Qe as heightOf,
|
|
3683
|
+
Mo as helpCenterText,
|
|
3684
|
+
Jo as humanizeAction,
|
|
3685
|
+
Cn as interactionIdOf,
|
|
3686
|
+
va as isAgentUser,
|
|
3687
|
+
So as isAssigned,
|
|
3688
|
+
ro as isAssignmentTerminal,
|
|
3689
|
+
In as isAssignmentTrigger,
|
|
3690
|
+
ia as isAutoReady,
|
|
3691
|
+
mn as isAwaitingThem,
|
|
3692
|
+
Li as isChatMessageActivity,
|
|
3693
|
+
_o as isClosed,
|
|
3694
|
+
Ci as isConnectedType,
|
|
3695
|
+
js as isDeepLink,
|
|
3696
|
+
hn as isDescendant,
|
|
3697
|
+
fo as isEligible,
|
|
3698
|
+
$i as isEmailActivity,
|
|
3699
|
+
sc as isHtmlBody,
|
|
3700
|
+
aa as isInFlight,
|
|
3701
|
+
on as isInteractionUnseen,
|
|
3702
|
+
Hs as isLandingPath,
|
|
3703
|
+
Zt as isLikelyBulk,
|
|
3704
|
+
Be as isMessageShape,
|
|
3705
|
+
Ti as isMessageType,
|
|
3706
|
+
Cr as isMoreSpecificPattern,
|
|
3707
|
+
je as isNoteShape,
|
|
3708
|
+
Wn as isOpenClock,
|
|
3709
|
+
Ya as isOutwardTool,
|
|
3710
|
+
dn as isParked,
|
|
3711
|
+
$n as isPaused,
|
|
3712
|
+
Oi as isPlaybookAuthoredType,
|
|
3713
|
+
ic as isPublicEmailDomain,
|
|
3714
|
+
Fs as isPublicPath,
|
|
3715
|
+
pn as isReminderActive,
|
|
3716
|
+
Ii as isReplyableType,
|
|
3717
|
+
Ao as isSlaAtRisk,
|
|
3718
|
+
oa as isTerminal,
|
|
3719
|
+
go as isThreadLongEnough,
|
|
3720
|
+
ki as isTranscriptType,
|
|
3721
|
+
Ga as isWorkClosed,
|
|
3722
|
+
Ia as isWorkTypeVisible,
|
|
3723
|
+
Ka as itemDossierKeys,
|
|
3724
|
+
ir as ladderFor,
|
|
3725
|
+
Io as linkLabel,
|
|
3726
|
+
Fi as listeningAllowed,
|
|
3727
|
+
Co as localeInstruction,
|
|
3728
|
+
Oo as localeName,
|
|
3729
|
+
vo as localesOf,
|
|
3730
|
+
tc as looksLikeEmail,
|
|
3731
|
+
cs as matchContactToIntents,
|
|
3732
|
+
kr as matchPublicRoute,
|
|
3733
|
+
Ro as mcpCredentialScope,
|
|
3734
|
+
Do as mcpToolPrefix,
|
|
3735
|
+
Js as mergeShownKeys,
|
|
3736
|
+
St as messageCountsAs,
|
|
3737
|
+
oc as needsPhoneRegion,
|
|
3738
|
+
wi as nestsUnderParent,
|
|
3739
|
+
ya as nextSlaClock,
|
|
3740
|
+
Yi as normalizeArtifactBlocks,
|
|
3741
|
+
Ei as normalizeBlocks,
|
|
3742
|
+
ft as normalizeEmail,
|
|
3743
|
+
I as normalizeExample,
|
|
3744
|
+
Cs as notificationPrefKey,
|
|
3745
|
+
Kr as novelty,
|
|
3746
|
+
Es as operationDescriptor,
|
|
3747
|
+
As as operationsForKind,
|
|
3748
|
+
mo as parkMarksById,
|
|
3749
|
+
Fo as parseActingIdentity,
|
|
3750
|
+
da as parseClockMinutes,
|
|
3751
|
+
Pa as parseItemKey,
|
|
3752
|
+
Ir as pathToRegex,
|
|
3753
|
+
pa as pauseBitFor,
|
|
3754
|
+
Vi as periodsInRange,
|
|
3755
|
+
nc as phoneSuffix,
|
|
3756
|
+
ho as pickMailHeaders,
|
|
3757
|
+
At as plainTextFromMarkdown,
|
|
3758
|
+
ga as planSlaEvent,
|
|
3759
|
+
wn as playbookActor,
|
|
3760
|
+
ra as procedureOf,
|
|
3761
|
+
Ba as projectDossierKeys,
|
|
3762
|
+
Or as publicBasePathFor,
|
|
3763
|
+
Gs as publicRoutePatterns,
|
|
3764
|
+
ao as reactionWakesAssignment,
|
|
3765
|
+
X as readPath,
|
|
3766
|
+
we as readStepError,
|
|
3767
|
+
un as recencyOf,
|
|
3768
|
+
Mn as refKey,
|
|
3769
|
+
Xr as registrableDomain,
|
|
3770
|
+
Jn as rejectExampleCandidate,
|
|
3771
|
+
Bo as relatedByDefault,
|
|
3772
|
+
ee as remainingMsOf,
|
|
3773
|
+
mr as resolveAccountCapabilities,
|
|
3774
|
+
Y as resolveActivityText,
|
|
3775
|
+
fr as resolveChannelIntents,
|
|
3776
|
+
Xt as resolveSignature,
|
|
3777
|
+
Ns as resolveWorkMode,
|
|
3778
|
+
Us as resourceKindOf,
|
|
3779
|
+
Wo as runActor,
|
|
3780
|
+
ca as runInteractionId,
|
|
3781
|
+
jt as sanitizeInline,
|
|
3782
|
+
xr as sanitizeTranscript,
|
|
3783
|
+
Eo as scoreInteraction,
|
|
3784
|
+
Da as scoreWorkItem,
|
|
3785
|
+
No as selectLenses,
|
|
3786
|
+
ns as sessionsHoldCannotReach,
|
|
3787
|
+
ts as sessionsToHold,
|
|
3788
|
+
ze as shareKeyForTeam,
|
|
3789
|
+
Ve as shareKeyForUser,
|
|
3790
|
+
eo as shareKeysForViewer,
|
|
3791
|
+
Rs as shouldRunAudioPipeline,
|
|
3792
|
+
ba as slaBadgeTone,
|
|
3793
|
+
bo as slaHoursByInbox,
|
|
3794
|
+
fn as slaHoursFor,
|
|
3795
|
+
ar as sortStatuses,
|
|
3796
|
+
pr as sourceKey,
|
|
3797
|
+
ja as statusIn,
|
|
3798
|
+
na as stepsOf,
|
|
3799
|
+
Et as stripHtml,
|
|
3800
|
+
sa as subjectKeyOf,
|
|
3801
|
+
et as subjectOf,
|
|
3802
|
+
Qa as subjectRef,
|
|
3803
|
+
Ua as suggestProjectKey,
|
|
3804
|
+
la as summarizeReactions,
|
|
3805
|
+
Yo as targetById,
|
|
3806
|
+
Xo as targetForActivityType,
|
|
3807
|
+
Tn as toActingIdentity,
|
|
3808
|
+
Re as toE164,
|
|
3809
|
+
to as toolSourceKinds,
|
|
3810
|
+
Zn as topicOfferedForTeam,
|
|
3811
|
+
ka as topicsForTeam,
|
|
3812
|
+
qn as truncateExample,
|
|
3813
|
+
Fa as uniqueWorkStatusKey,
|
|
3814
|
+
wa as uniqueWorkTypeKey,
|
|
3815
|
+
$t as usageMetricId,
|
|
3816
|
+
zi as usageMetrics,
|
|
3817
|
+
Wa as validateStatuses,
|
|
3818
|
+
zo as valueAtPath,
|
|
3819
|
+
te as waitHoursOf,
|
|
3820
|
+
oo as wakesAssignment,
|
|
3821
|
+
$a as workActivityScopeKey,
|
|
3822
|
+
rr as workItemScopeKey,
|
|
3823
|
+
at as workProjectScopeKey,
|
|
3824
|
+
sr as workStatusKey,
|
|
3825
|
+
Vn as workTypeKey,
|
|
3826
|
+
J as workingMsBetween
|
|
3589
3827
|
};
|