@opencxh/domain 1.277.0 → 1.278.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/index.js CHANGED
@@ -1,4 +1,4 @@
1
- const aa = 10, ca = 10, la = 10, ua = 5, Cn = /* @__PURE__ */ new Set([
1
+ const la = 10, ua = 10, da = 10, fa = 5, Cn = /* @__PURE__ */ new Set([
2
2
  "header",
3
3
  "section",
4
4
  "context",
@@ -14,7 +14,7 @@ function ae(e) {
14
14
  const t = e;
15
15
  return typeof t.key == "string" || typeof t.value == "string";
16
16
  }
17
- function da(e, t = () => {
17
+ function pa(e, t = () => {
18
18
  }) {
19
19
  if (!Array.isArray(e)) return [];
20
20
  const n = [];
@@ -70,7 +70,7 @@ function da(e, t = () => {
70
70
  return n;
71
71
  }
72
72
  const Nn = /(\*\*|__)(?=\S)([\s\S]*?\S)\1/g, xn = /(\*|_)(?=\S)([^*_\n]*?\S)\1/g;
73
- function $n(e) {
73
+ function Dn(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(`
@@ -79,7 +79,7 @@ function $n(e) {
79
79
  ).join(`
80
80
  `), t = t.replace(Nn, "$2"), t = t.replace(xn, "$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 Dn(e) {
82
+ function Rn(e) {
83
83
  return e.replace(/<style[\s\S]*?<\/style>/gi, " ").replace(/<script[\s\S]*?<\/script>/gi, " ").replace(/<[^>]+>/g, " ").replace(/&nbsp;/g, " ").replace(/&amp;/g, "&").replace(/&lt;/g, "<").replace(/&gt;/g, ">").replace(/&quot;/g, '"').replace(/&#39;/g, "'").replace(/\s+/g, " ").trim();
84
84
  }
85
85
  function Q(e) {
@@ -99,7 +99,7 @@ function J(e) {
99
99
  function Qe(e) {
100
100
  return e === "meeting" ? "Meeting" : e === "video" ? "Video call" : "Audio call";
101
101
  }
102
- const D = {
102
+ const R = {
103
103
  /* ---- voice ---- */
104
104
  VOICE_CALL_STARTED: {
105
105
  shape: "event",
@@ -478,46 +478,46 @@ const D = {
478
478
  }
479
479
  };
480
480
  function Je(e) {
481
- const t = e.payload, n = $n(t.bodyText).trim() || t.bodySnippet?.trim() || Dn(t.body ?? "");
481
+ const t = e.payload, n = Dn(t.bodyText).trim() || t.bodySnippet?.trim() || Rn(t.body ?? "");
482
482
  return t.subject ? `${t.subject} — ${n}` : n;
483
483
  }
484
484
  function v(e) {
485
- return D[e];
485
+ return R[e];
486
486
  }
487
- function fa(e) {
487
+ function ma(e) {
488
488
  return v(e)?.icon ?? "circle";
489
489
  }
490
- function pa(e) {
490
+ function ha(e) {
491
491
  return v(e)?.channelKind;
492
492
  }
493
493
  function Ht(e) {
494
494
  return e === "message" || e === "note";
495
495
  }
496
- function ma(e) {
496
+ function ga(e) {
497
497
  return Ht(v(e)?.shape);
498
498
  }
499
499
  function Gt(e) {
500
500
  return e === "note";
501
501
  }
502
- function ha(e) {
502
+ function ya(e) {
503
503
  return Gt(v(e)?.shape);
504
504
  }
505
- function ga(e) {
505
+ function ba(e) {
506
506
  return v(e)?.replyable === !0;
507
507
  }
508
- function ya(e) {
508
+ function _a(e) {
509
509
  return v(e)?.carriesText === !0;
510
510
  }
511
- function Rn(e) {
511
+ function $n(e) {
512
512
  return v(e)?.countsAs;
513
513
  }
514
- function ba(e) {
514
+ function Aa(e) {
515
515
  return v(e)?.playbookAuthored === !0;
516
516
  }
517
- function Aa(e) {
517
+ function Ea(e) {
518
518
  return v(e)?.connected === !0;
519
519
  }
520
- function _a(e) {
520
+ function Sa(e) {
521
521
  const t = v(e);
522
522
  return t?.shape === "artifact" && t?.carriesText === !0;
523
523
  }
@@ -525,15 +525,15 @@ function Ln(e) {
525
525
  const t = v(e.type)?.snippet;
526
526
  return t ? t(e) : "";
527
527
  }
528
- function Ea(e, t) {
528
+ function Ta(e, t) {
529
529
  const n = v(e.type)?.timeline;
530
530
  return n ? n(e, t) : e.type.replace(/_/g, " ").toLowerCase();
531
531
  }
532
- function Sa(e) {
532
+ function Ia(e) {
533
533
  const t = v(e.type)?.joinUrl;
534
534
  return t ? t(e) : void 0;
535
535
  }
536
- function _e(e, t) {
536
+ function Ae(e, t) {
537
537
  let n = e;
538
538
  for (const r of t.split(".")) {
539
539
  if (n == null || typeof n != "object") return "";
@@ -545,10 +545,10 @@ function Ee(e, t, n) {
545
545
  if (e === void 0) return null;
546
546
  if (typeof e == "string") return e || null;
547
547
  if ("value" in e)
548
- return _e(t, e.value) || null;
548
+ return Ae(t, e.value) || null;
549
549
  const r = {};
550
550
  for (const [i, s] of Object.entries(e.params ?? {}))
551
- r[i] = _e(t, s);
551
+ r[i] = Ae(t, s);
552
552
  const o = n(e.key, r);
553
553
  return o === e.key ? null : o;
554
554
  }
@@ -556,7 +556,7 @@ function Pn(e, t) {
556
556
  if (!e || typeof e == "string" || "value" in e) return null;
557
557
  const n = {};
558
558
  for (const [r, o] of Object.entries(e.params ?? {}))
559
- n[r] = _e(t, o);
559
+ n[r] = Ae(t, o);
560
560
  return { key: e.key, params: n };
561
561
  }
562
562
  const Ze = 140;
@@ -564,7 +564,7 @@ function Kn(e) {
564
564
  const t = e.trim();
565
565
  return t.length <= Ze ? t : `${t.slice(0, Ze - 1).trimEnd()}…`;
566
566
  }
567
- function Ta(e, t) {
567
+ function va(e, t) {
568
568
  const n = Pn(t?.text, e), r = t ? Ee(t.text, e, (o) => o) : null;
569
569
  return {
570
570
  activityId: e.id,
@@ -578,7 +578,7 @@ function Ta(e, t) {
578
578
  }
579
579
  const Un = (e) => e;
580
580
  function et(e) {
581
- const t = D[e];
581
+ const t = R[e];
582
582
  return {
583
583
  type: e,
584
584
  shape: t.shape,
@@ -612,17 +612,17 @@ class Fn {
612
612
  constructor(t = [], n = Un) {
613
613
  this.translate = n;
614
614
  for (const r of t)
615
- r?.type && (r.type in D || this.declared.has(r.type) || this.declared.set(r.type, r));
615
+ r?.type && (r.type in R || this.declared.has(r.type) || this.declared.set(r.type, r));
616
616
  }
617
617
  declared = /* @__PURE__ */ new Map();
618
618
  get(t) {
619
- if (t in D) return et(t);
619
+ if (t in R) return et(t);
620
620
  const n = this.declared.get(t);
621
621
  return n ? tt(n) : void 0;
622
622
  }
623
623
  /** Everything that may be offered as a trigger, built-in and declared. */
624
624
  triggerable() {
625
- const t = Object.keys(D).filter((r) => D[r].triggerable).map(et), n = [...this.declared.values()].map(tt).filter((r) => r.triggerable);
625
+ const t = Object.keys(R).filter((r) => R[r].triggerable).map(et), n = [...this.declared.values()].map(tt).filter((r) => r.triggerable);
626
626
  return [...t, ...n];
627
627
  }
628
628
  /**
@@ -631,14 +631,14 @@ class Fn {
631
631
  * the feed always showed for unknown types.
632
632
  */
633
633
  timelineText(t, n) {
634
- const r = D[t.type];
634
+ const r = R[t.type];
635
635
  if (r?.timeline) return r.timeline(t, n);
636
636
  const o = this.declared.get(t.type);
637
637
  return Ee(o?.text, t, this.translate) ?? t.type.replace(/_/g, " ").toLowerCase();
638
638
  }
639
639
  /** The line for the inbox list. Empty when the type has nothing to show. */
640
640
  snippet(t) {
641
- const n = D[t.type];
641
+ const n = R[t.type];
642
642
  if (n?.snippet) return n.snippet(t);
643
643
  const r = this.declared.get(t.type);
644
644
  return Ee(r?.text, t, this.translate) ?? "";
@@ -698,8 +698,8 @@ class Fn {
698
698
  return this.translate;
699
699
  }
700
700
  }
701
- const Ia = new Fn();
702
- function va(e, t, n = []) {
701
+ const ka = new Fn();
702
+ function wa(e, t, n = []) {
703
703
  const r = e.createdAt;
704
704
  if (!r) return [];
705
705
  const o = new Set(n);
@@ -708,10 +708,10 @@ function va(e, t, n = []) {
708
708
  function jn(e) {
709
709
  return e.createdAt ?? 0;
710
710
  }
711
- function ka(e) {
711
+ function Ma(e) {
712
712
  return e.type === "EMAIL_RECEIVED" || e.type === "EMAIL_SENT";
713
713
  }
714
- function wa(e) {
714
+ function Oa(e) {
715
715
  return e.type === "CHAT_MESSAGE_SENT" || e.type === "CHAT_MESSAGE_RECEIVED";
716
716
  }
717
717
  const Ue = [
@@ -732,16 +732,16 @@ const Ue = [
732
732
  */
733
733
  { id: "decision", defaultFlag: "isDefaultDecision", label: "Beslissingen" }
734
734
  ];
735
- function Ma(e) {
735
+ function Ca(e) {
736
736
  return Ue.find((t) => t.id === e)?.defaultFlag;
737
737
  }
738
- function Oa(e) {
738
+ function Na(e) {
739
739
  const t = {};
740
740
  for (const n of Ue)
741
741
  t[n.defaultFlag] = e?.[n.defaultFlag] === !0;
742
742
  return t;
743
743
  }
744
- function Ca(e, t) {
744
+ function xa(e, t) {
745
745
  const n = {};
746
746
  for (const r of Ue) {
747
747
  const o = r.defaultFlag;
@@ -756,7 +756,7 @@ const Bn = {
756
756
  audio: "audio",
757
757
  video: "video"
758
758
  };
759
- function Na(e, t) {
759
+ function Da(e, t) {
760
760
  if (t === "text") return !0;
761
761
  if (!e?.in?.length) return;
762
762
  const n = Bn[t];
@@ -771,7 +771,7 @@ function Hn(e) {
771
771
  let n;
772
772
  return e.expectsSchema ? (n = "fast", t.push("schema-antwoord")) : (e.mode ?? "agent") === "ask" && !e.toolCount ? (n = "fast", t.push("vraag zonder tools")) : e.toolCount || e.hasAttachments ? (n = "standard", t.push(e.hasAttachments ? "bijlagen" : "tools beschikbaar")) : (n = "standard", t.push("standaard")), e.repair && (n = nt(n, 1), t.push("herstelbeurt: een tier omhoog")), e.budgetPressure === "soft" && n !== "fast" && (n = nt(n, -1), t.push("budget bijna op: een tier omlaag in plaats van weigeren")), e.maxTier && Se(n) > Se(e.maxTier) && (n = e.maxTier, t.push(`plafond van de rol: ${e.maxTier}`)), { tier: n, reasons: t };
773
773
  }
774
- function xa(e, t, n) {
774
+ function Ra(e, t, n) {
775
775
  const r = Hn(t);
776
776
  if (!e) return { ...r, ...n, routed: !1 };
777
777
  for (let o = Se(r.tier); o >= 0; o--) {
@@ -808,10 +808,10 @@ function $a(e) {
808
808
  }
809
809
  return null;
810
810
  }
811
- function Da(e, t = 0.9, n = 0.6) {
811
+ function La(e, t = 0.9, n = 0.6) {
812
812
  return Number.isFinite(e) ? e >= t ? "act" : e >= n ? "check" : "refuse" : "refuse";
813
813
  }
814
- const Ra = [
814
+ const Pa = [
815
815
  "counting or arithmetic",
816
816
  "comparing dates or durations",
817
817
  "judging whether two numbers are close",
@@ -923,23 +923,23 @@ const Ra = [
923
923
  function oe(e) {
924
924
  return Wt.find((t) => t.id === e);
925
925
  }
926
- function La(e) {
926
+ function Ka(e) {
927
927
  return oe(e)?.label ?? e;
928
928
  }
929
- function Pa(e, t = "gpt-5-mini") {
929
+ function Ua(e, t = "gpt-5-mini") {
930
930
  return oe(e)?.defaultModel ?? t;
931
931
  }
932
- function Ka(e) {
932
+ function Fa(e) {
933
933
  return Wt.filter((t) => t.capabilities.includes(e));
934
934
  }
935
- function Ua(e) {
935
+ function ja(e) {
936
936
  const t = oe(e);
937
937
  return !!t && !t.baseUrl;
938
938
  }
939
- function Fa(e, t) {
939
+ function Ba(e, t) {
940
940
  return t === "text" ? !0 : oe(e)?.attachmentKinds?.includes(t) === !0;
941
941
  }
942
- function ja(e, t) {
942
+ function Ha(e, t) {
943
943
  if (!e.enabled) return "ok";
944
944
  const n = st(e.hardLimitNanos), r = st(e.softLimitNanos);
945
945
  return n !== void 0 && t >= n ? "hard" : r !== void 0 && t >= r ? "soft" : "ok";
@@ -951,17 +951,17 @@ function Gn(e, t = "month") {
951
951
  const n = new Date(e);
952
952
  return Date.UTC(n.getUTCFullYear(), n.getUTCMonth(), 1);
953
953
  }
954
- function Ba(e, t = "month") {
954
+ function Ga(e, t = "month") {
955
955
  const n = new Date(Gn(e, t));
956
956
  return `${n.getUTCFullYear()}-${String(n.getUTCMonth() + 1).padStart(2, "0")}`;
957
957
  }
958
- function Ha(e) {
958
+ function Wa(e) {
959
959
  return e === "ask" || e === "draft" || e === "agent";
960
960
  }
961
- function Ga(e) {
961
+ function Va(e) {
962
962
  return e?.listeningEnabled !== !1;
963
963
  }
964
- const Wa = [
964
+ const za = [
965
965
  { id: "agent", label: "Agent", labelSource: "user" },
966
966
  { id: "team", label: "Team", labelSource: "team" },
967
967
  { id: "inbox", label: "Inbox", labelSource: "inbox" },
@@ -983,14 +983,14 @@ function V(e, t) {
983
983
  return n.setUTCMinutes(0, 0, 0), t === "day" && n.setUTCHours(0), n.getTime();
984
984
  }
985
985
  const Wn = 36e5, Vn = 864e5;
986
- function Va(e, t, n) {
986
+ function Ya(e, t, n) {
987
987
  const r = n === "hour" ? Wn : Vn, o = [];
988
988
  for (let i = V(e, n); i <= t; i += r)
989
989
  o.push(W(i, n));
990
990
  return o;
991
991
  }
992
992
  const zn = /* @__PURE__ */ new Set(["time"]);
993
- function za(e, t, n) {
993
+ function Xa(e, t, n) {
994
994
  if (!e) return [];
995
995
  const r = new Set(e.supportedDimensions ?? []);
996
996
  return t.filter((o) => r.has(o.id) && !zn.has(o.id)).map((o) => ({
@@ -999,21 +999,21 @@ function za(e, t, n) {
999
999
  options: o.options?.length ? o.options : n[o.id] ?? []
1000
1000
  })).filter((o) => o.options.length > 0);
1001
1001
  }
1002
- function Xa(e, t) {
1002
+ function qa(e, t) {
1003
1003
  const n = t.find((o) => o.id === e.dimensionId), r = n?.options.find((o) => o.value === e.value);
1004
1004
  return `${n?.label ?? e.dimensionId} · ${r?.label ?? e.value}`;
1005
1005
  }
1006
- function Ya(e) {
1006
+ function Qa(e) {
1007
1007
  return { value: e.id, label: `${e.category} · ${e.label}` };
1008
1008
  }
1009
- const Xn = [
1009
+ const Yn = [
1010
1010
  { id: "resource", label: "Resource", labelSource: "raw" },
1011
1011
  { id: "origin", label: "Herkomst", labelSource: "raw" }
1012
- ], Yn = Xn.map((e) => e.id);
1012
+ ], Xn = Yn.map((e) => e.id);
1013
1013
  function qn(e, t) {
1014
1014
  return `${e}.usage.${t}`;
1015
1015
  }
1016
- function qa(e, t) {
1016
+ function Ja(e, t) {
1017
1017
  return t.map((n) => ({
1018
1018
  id: qn(e, n.unit),
1019
1019
  label: n.label,
@@ -1022,13 +1022,13 @@ function qa(e, t) {
1022
1022
  aggregation: "sum",
1023
1023
  supportedDimensions: [
1024
1024
  "provider",
1025
- ...Yn,
1025
+ ...Xn,
1026
1026
  ...n.extraDimensions ?? [],
1027
1027
  "time"
1028
1028
  ]
1029
1029
  }));
1030
1030
  }
1031
- async function Qa(e, t) {
1031
+ async function Za(e, t) {
1032
1032
  let n = 0, r = 0;
1033
1033
  for (const o of e)
1034
1034
  try {
@@ -1040,22 +1040,22 @@ async function Qa(e, t) {
1040
1040
  }
1041
1041
  return { decided: n, waiting: r };
1042
1042
  }
1043
- function Ja(e) {
1043
+ function ec(e) {
1044
1044
  return e.approvalRequestIds?.length ? [...e.approvalRequestIds] : e.approvalRequestId ? [e.approvalRequestId] : [];
1045
1045
  }
1046
- function Za(e, t) {
1046
+ function tc(e, t) {
1047
1047
  return e.filter((r) => !r.enabled || r.scopeKind !== t.scopeKind || r.act !== t.act ? !1 : r.minAmountCents == null ? !0 : t.amountCents != null && t.amountCents >= r.minAmountCents).sort((r, o) => {
1048
1048
  const i = r.minAmountCents ?? -1;
1049
1049
  return (o.minAmountCents ?? -1) - i || r.id.localeCompare(o.id);
1050
1050
  })[0];
1051
1051
  }
1052
- function ec(e, t, n, r) {
1052
+ function nc(e, t, n, r) {
1053
1053
  const o = new Set(e.userIds);
1054
1054
  for (const i of e.teamIds)
1055
1055
  for (const s of t[i] ?? []) o.add(s);
1056
1056
  return r || o.delete(n), [...o];
1057
1057
  }
1058
- function tc(e, t) {
1058
+ function rc(e, t) {
1059
1059
  if (e.status !== "pending" || e.decisions.some((i) => i.userId === t.userId)) return e;
1060
1060
  const n = [...e.decisions, t], r = e.pendingUserIds.filter((i) => i !== t.userId);
1061
1061
  if (t.decision === "rejected")
@@ -1069,7 +1069,7 @@ function tc(e, t) {
1069
1069
  settledAt: o ? t.at : void 0
1070
1070
  };
1071
1071
  }
1072
- const Vt = /* @__PURE__ */ new Set(["info", "success", "warning", "destructive"]), at = 200, ct = 100, lt = 200, ut = 12, dt = 4, ft = 10, Qn = 8, pt = 12, zt = 4e3, Z = 500, nc = 1024 * 1024, Jn = /* @__PURE__ */ new Set([
1072
+ const Vt = /* @__PURE__ */ new Set(["info", "success", "warning", "destructive"]), at = 200, ct = 100, lt = 200, ut = 12, dt = 4, ft = 10, Qn = 8, pt = 12, zt = 4e3, Z = 500, oc = 1024 * 1024, Jn = /* @__PURE__ */ new Set([
1073
1073
  "heading",
1074
1074
  "paragraph",
1075
1075
  "list",
@@ -1145,7 +1145,7 @@ function j(e, t = 200) {
1145
1145
  function ir(e, t = "info") {
1146
1146
  return typeof e == "string" && Vt.has(e) ? e : t;
1147
1147
  }
1148
- function rc(e, t = () => {
1148
+ function ic(e, t = () => {
1149
1149
  }) {
1150
1150
  if (!Array.isArray(e)) return [];
1151
1151
  const n = [];
@@ -1364,10 +1364,10 @@ function rc(e, t = () => {
1364
1364
  }
1365
1365
  return n;
1366
1366
  }
1367
- function oc(e) {
1367
+ function sc(e) {
1368
1368
  return JSON.stringify(e).length;
1369
1369
  }
1370
- function ic(e) {
1370
+ function ac(e) {
1371
1371
  return {
1372
1372
  blocks: e.length,
1373
1373
  types: e.map((t) => t.type),
@@ -1454,45 +1454,45 @@ function ar(e, t) {
1454
1454
  `)}
1455
1455
  `;
1456
1456
  }
1457
- const Xt = (e) => `user:${e}`, Yt = (e) => `team:${e}`;
1458
- function sc(e) {
1457
+ const Yt = (e) => `user:${e}`, Xt = (e) => `team:${e}`;
1458
+ function cc(e) {
1459
1459
  const t = /* @__PURE__ */ new Set();
1460
1460
  for (const n of e ?? [])
1461
- n?.id && (n.kind === "user" && t.add(Xt(n.id)), n.kind === "team" && t.add(Yt(n.id)));
1461
+ n?.id && (n.kind === "user" && t.add(Yt(n.id)), n.kind === "team" && t.add(Xt(n.id)));
1462
1462
  return [...t].sort();
1463
1463
  }
1464
- function ac(e, t) {
1465
- return [Xt(e), ...t.map(Yt)];
1464
+ function lc(e, t) {
1465
+ return [Yt(e), ...t.map(Xt)];
1466
1466
  }
1467
- function cc(e) {
1467
+ function uc(e) {
1468
1468
  const t = /* @__PURE__ */ new Set();
1469
1469
  for (const n of e ?? [])
1470
1470
  n?.kind && t.add(n.kind);
1471
1471
  return [...t];
1472
1472
  }
1473
- const cr = ["done", "escalated"], lc = ["open", "waiting"];
1474
- function uc(e) {
1473
+ const cr = ["done", "escalated"], dc = ["open", "waiting"];
1474
+ function fc(e) {
1475
1475
  return cr.includes(e);
1476
1476
  }
1477
1477
  const lr = "assignment";
1478
- function dc(e) {
1478
+ function pc(e) {
1479
1479
  return `${lr}:${e}`;
1480
1480
  }
1481
- function fc(e, t, n, r) {
1481
+ function mc(e, t, n, r) {
1482
1482
  if (e.direction === "inbound") return !0;
1483
1483
  if (e.author?.type === "user" && e.author.id === t) return !1;
1484
1484
  const o = e.payload?.mentions;
1485
1485
  return Array.isArray(o) && o.includes(t) || r && r === t ? !0 : n === "reply";
1486
1486
  }
1487
- function pc(e) {
1487
+ function hc(e) {
1488
1488
  const { targetAuthorId: t, reactorId: n, agentId: r, on: o } = e;
1489
1489
  return !o || !t || t !== r ? !1 : n !== r;
1490
1490
  }
1491
- function mc(e) {
1491
+ function gc(e) {
1492
1492
  return e.subjectKind && e.subjectId ? { type: e.subjectKind, id: e.subjectId } : void 0;
1493
1493
  }
1494
1494
  const ur = 12;
1495
- function hc(e, t, n = ur) {
1495
+ function yc(e, t, n = ur) {
1496
1496
  const r = t + 1;
1497
1497
  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 ? {
1498
1498
  status: "escalated",
@@ -1507,7 +1507,7 @@ function hc(e, t, n = ur) {
1507
1507
  };
1508
1508
  }
1509
1509
  const dr = 2;
1510
- function gc(e, t, n, r) {
1510
+ function bc(e, t, n, r) {
1511
1511
  if (t === n)
1512
1512
  return "een agent schakelt zichzelf niet in";
1513
1513
  if (!r?.includes(t))
@@ -1518,14 +1518,14 @@ function gc(e, t, n, r) {
1518
1518
  const i = Math.max(0, o.length - 1);
1519
1519
  return i >= dr ? `er zijn al ${i} agents ingeschakeld voor deze vraag; dieper delegeren mag niet` : null;
1520
1520
  }
1521
- const yc = "organization.business-entities.list";
1522
- function bc(e, t, n) {
1521
+ const _c = "organization.business-entities.list";
1522
+ function Ac(e, t, n) {
1523
1523
  return e ? e === t : n;
1524
1524
  }
1525
- function Ac(e) {
1525
+ function Ec(e) {
1526
1526
  return e.isDefault === !0 ? [e.id, ""] : [e.id];
1527
1527
  }
1528
- function _c(e, t, n) {
1528
+ function Sc(e, t, n) {
1529
1529
  const r = /* @__PURE__ */ new Map();
1530
1530
  for (const o of e) o.businessEntityId || r.set(o[t], o);
1531
1531
  if (n)
@@ -1544,7 +1544,7 @@ function pr(e) {
1544
1544
  t += Number(e[n]) * (n % 2 === 0 ? 3 : 1);
1545
1545
  return (10 - t % 10) % 10;
1546
1546
  }
1547
- function Ec(e, t) {
1547
+ function Tc(e, t) {
1548
1548
  const n = t.trim(), r = fr(n), o = [{ sku: n }, { barcodes: { $in: [n] } }];
1549
1549
  return r && o.push({ gtin: r }), { organizationId: e, $or: o };
1550
1550
  }
@@ -1562,14 +1562,14 @@ function mr(e, t) {
1562
1562
  o[s[l].index] += a, i -= a;
1563
1563
  return o;
1564
1564
  }
1565
- function R(e, t = {}) {
1565
+ function $(e, t = {}) {
1566
1566
  const n = t.decimal ?? ",", r = t.group ?? ".", o = e < 0, i = Math.abs(Math.trunc(e)).toString().padStart(3, "0"), s = i.slice(0, -2), a = i.slice(-2);
1567
1567
  let l = "";
1568
1568
  for (let c = 0; c < s.length; c++)
1569
1569
  c > 0 && (s.length - c) % 3 === 0 && (l += r), l += s[c];
1570
1570
  return `${o ? "-" : ""}${l}${n}${a}`;
1571
1571
  }
1572
- function Sc(e) {
1572
+ function Ic(e) {
1573
1573
  const t = e.trim().replace(/[\s ]/g, "");
1574
1574
  if (!t) return;
1575
1575
  const n = t.replace(/^[-+]?[^\d.,-]*/, "").replace(/[^\d.,-]+$/, ""), r = /^-/.test(t) || /-$/.test(t), o = n.replace(/-/g, "");
@@ -1584,7 +1584,7 @@ function Sc(e) {
1584
1584
  function hr(e) {
1585
1585
  return /^\d+$/.test(e) ? !0 : e.includes(".") && e.includes(",") ? !1 : /^\d{1,3}([.,]\d{3})*$/.test(e);
1586
1586
  }
1587
- function Tc(e) {
1587
+ function vc(e) {
1588
1588
  return e.costPriceCents == null ? e.netCents : e.netCents - z(e.costPriceCents * e.quantity);
1589
1589
  }
1590
1590
  const gr = [
@@ -1639,47 +1639,65 @@ function yr(e, t, n) {
1639
1639
  function br(e, t) {
1640
1640
  return e.unitPriceCents != null ? e.unitPriceCents : e.discountPercent != null ? z(t * (1 - e.discountPercent / 100)) : t;
1641
1641
  }
1642
- const Ar = "manual";
1643
- function Ic(e, t, n, r) {
1642
+ const _r = "manual";
1643
+ function kc(e, t, n, r) {
1644
1644
  return e.map((o) => {
1645
- if (o.kind !== "product" || o.priceSourceKey === Ar) return o;
1645
+ if (o.kind !== "product" || o.priceSourceKey === _r) return o;
1646
1646
  const i = t.find((a) => a.id === o.productId);
1647
1647
  if (!i) return o;
1648
1648
  const s = yr(i, { ...r, quantity: o.quantity }, n);
1649
1649
  return s.unitPriceCents === o.unitPriceCents && s.sourceKey === o.priceSourceKey ? o : { ...o, unitPriceCents: s.unitPriceCents, priceSourceKey: s.sourceKey };
1650
1650
  });
1651
1651
  }
1652
- const vc = ["piece", "hour", "day", "month", "km", "license"], kc = /* @__PURE__ */ new Set(["mail", "message"]);
1653
- function _r(e, t) {
1652
+ const wc = ["piece", "hour", "day", "month", "km", "license"], Mc = /* @__PURE__ */ new Set(["mail", "message"]);
1653
+ function Ar(e, t) {
1654
1654
  const n = e.settings?.signatures?.[t];
1655
1655
  return !n?.enabled || !n.body || n.body.trim() === "" ? null : n;
1656
1656
  }
1657
- function wc(e, t, n, r = "html") {
1657
+ function Oc(e, t, n, r = "html") {
1658
1658
  if (!e) return n;
1659
- const o = _r(e, t);
1659
+ const o = Ar(e, t);
1660
1660
  return o ? `${n}${r === "text" ? `
1661
1661
 
1662
1662
  ` : t === "mail" ? "<br><br>-- <br>" : "<br><br>"}${o.body}` : n;
1663
1663
  }
1664
- function Mc(e) {
1664
+ function Cc(e) {
1665
1665
  return e.endpoints ?? [];
1666
1666
  }
1667
+ const Nc = ["lead", "opportunity", "customer", "former"], xc = ["new", "working", "unqualified"];
1668
+ function Dc(e) {
1669
+ return [e.firstName, e.lastName].filter(Boolean).join(" ").trim();
1670
+ }
1671
+ const Er = [
1672
+ "stages",
1673
+ "leadStatuses",
1674
+ "sources",
1675
+ "scopes",
1676
+ "cities",
1677
+ "parentCompanyIds"
1678
+ ], Sr = ["openDeal", "hasContacts"], Rc = {
1679
+ contact: ["stages", "leadStatuses", "sources", "scopes", "cities", "openDeal"],
1680
+ company: ["sources", "scopes", "cities", "parentCompanyIds", "hasContacts"]
1681
+ }, $c = ["updatedAt", "createdAt", "name"], Lc = ["list"];
1682
+ function Pc(e) {
1683
+ return e.search?.trim() || e.createdWithinDays || Sr.some((t) => e[t]) || Er.some((t) => e[t]?.length) ? !1 : !Object.values(e.fields ?? {}).some((t) => t.length);
1684
+ }
1667
1685
  function L(e) {
1668
1686
  const t = (e ?? "").trim().toLowerCase();
1669
1687
  if (t)
1670
1688
  return t.split(/[-_]/)[0] || void 0;
1671
1689
  }
1672
- function Oc(e) {
1690
+ function Kc(e) {
1673
1691
  return L(e.contactLocale) ?? L(e.companyLocale) ?? L(e.organizationLocale);
1674
1692
  }
1675
- function Cc(e, t, n, r) {
1693
+ function Uc(e, t, n, r) {
1676
1694
  const o = e.filter((a) => a.key === t && !a.archived);
1677
1695
  if (o.length === 0) return;
1678
1696
  const i = L(n), s = L(r);
1679
1697
  return o.find((a) => L(a.locale) === i) ?? o.find((a) => L(a.locale) === s) ?? // A row with no language at all is the single-language case: it is for everybody.
1680
1698
  o.find((a) => !a.locale) ?? o[0];
1681
1699
  }
1682
- const Er = /\{([a-zA-Z0-9_.]+)\}/g;
1700
+ const Tr = /\{([a-zA-Z0-9_.]+)\}/g;
1683
1701
  function qt(e, t) {
1684
1702
  let n = e;
1685
1703
  for (const r of t.split(".")) {
@@ -1688,17 +1706,17 @@ function qt(e, t) {
1688
1706
  }
1689
1707
  return n;
1690
1708
  }
1691
- function Sr(e) {
1709
+ function Ir(e) {
1692
1710
  return typeof e == "string" ? e : typeof e == "number" || typeof e == "boolean" ? String(e) : "";
1693
1711
  }
1694
- function Tr(e, t, n) {
1712
+ function vr(e, t, n) {
1695
1713
  const r = [];
1696
- return { text: e.replace(Er, (i, s) => {
1714
+ return { text: e.replace(Tr, (i, s) => {
1697
1715
  const a = qt(t, s);
1698
- return a == null || a === "" ? (r.includes(s) || r.push(s), n ?? `{${s}}`) : Sr(a);
1716
+ return a == null || a === "" ? (r.includes(s) || r.push(s), n ?? `{${s}}`) : Ir(a);
1699
1717
  }), unresolved: r };
1700
1718
  }
1701
- function Ir(e, t) {
1719
+ function kr(e, t) {
1702
1720
  if (!e) return !0;
1703
1721
  const n = qt(t, e.key);
1704
1722
  if (e.exists !== void 0) {
@@ -1707,14 +1725,14 @@ function Ir(e, t) {
1707
1725
  }
1708
1726
  return e.equals !== void 0 ? n === e.equals : !0;
1709
1727
  }
1710
- function Nc(e, t, n, r, o) {
1728
+ function Fc(e, t, n, r, o) {
1711
1729
  const i = [], s = [], a = /* @__PURE__ */ new Set(), l = (c) => {
1712
- const d = Tr(c, t, o);
1730
+ const d = vr(c, t, o);
1713
1731
  for (const u of d.unresolved) i.includes(u) || i.push(u);
1714
1732
  return d.text;
1715
1733
  };
1716
1734
  for (const c of e) {
1717
- if (c.block_id && !Ir(n?.[c.block_id], t)) continue;
1735
+ if (c.block_id && !kr(n?.[c.block_id], t)) continue;
1718
1736
  const d = c.block_id ? r?.[c.block_id] : void 0;
1719
1737
  if (d && c.block_id) {
1720
1738
  a.add(c.block_id), s.push(...d);
@@ -1804,7 +1822,7 @@ function Nc(e, t, n, r, o) {
1804
1822
  unusedSlots: Object.keys(r ?? {}).filter((c) => !a.has(c))
1805
1823
  };
1806
1824
  }
1807
- function vr(e) {
1825
+ function wr(e) {
1808
1826
  const t = e?.address, n = [t?.street, t?.houseNumber].filter(Boolean).join(" "), r = [t?.postalCode, t?.city].filter(Boolean).join(" ");
1809
1827
  return {
1810
1828
  name: e?.name ?? "",
@@ -1818,8 +1836,8 @@ function vr(e) {
1818
1836
  ...e?.logo ? { logo: e.logo } : {}
1819
1837
  };
1820
1838
  }
1821
- function xc(e) {
1822
- return vr({
1839
+ function jc(e) {
1840
+ return wr({
1823
1841
  name: e?.billing?.companyName || e?.name || e?.displayName || "",
1824
1842
  address: e?.address,
1825
1843
  kvkNumber: e?.billing?.kvkNumber,
@@ -1829,7 +1847,7 @@ function xc(e) {
1829
1847
  logo: e?.logo
1830
1848
  });
1831
1849
  }
1832
- function kr(e, t, n, r = Date.now()) {
1850
+ function Mr(e, t, n, r = Date.now()) {
1833
1851
  const o = n.filter((i) => i.ok).length;
1834
1852
  return {
1835
1853
  suite: e,
@@ -1839,10 +1857,10 @@ function kr(e, t, n, r = Date.now()) {
1839
1857
  perCase: [...n]
1840
1858
  };
1841
1859
  }
1842
- function $c(e) {
1860
+ function Bc(e) {
1843
1861
  return e.perCase.filter((t) => !t.ok).map((t) => `${t.caseId}: ${t.note ?? "onverwacht resultaat"}`);
1844
1862
  }
1845
- async function Dc(e, t, n, r, o = Date.now()) {
1863
+ async function Hc(e, t, n, r, o = Date.now()) {
1846
1864
  const i = [];
1847
1865
  for (const s of n)
1848
1866
  try {
@@ -1854,24 +1872,24 @@ async function Dc(e, t, n, r, o = Date.now()) {
1854
1872
  note: `beoordeling mislukt: ${a?.message ?? String(a)}`
1855
1873
  });
1856
1874
  }
1857
- return kr(e, t, i, o);
1875
+ return Mr(e, t, i, o);
1858
1876
  }
1859
- const wr = 36e5, Mr = 864e5, P = -1 / 0, Rc = (e) => e.score > P, ne = {
1877
+ const Or = 36e5, Cr = 864e5, P = -1 / 0, Gc = (e) => e.score > P, ne = {
1860
1878
  urgent: 40,
1861
1879
  high: 25,
1862
1880
  normal: 10,
1863
1881
  low: 0
1864
1882
  };
1865
- function Lc(e) {
1883
+ function Wc(e) {
1866
1884
  return Object.fromEntries(e.map((t) => [t.resourceId, t]));
1867
1885
  }
1868
- const Or = /(^|[._+-])(no-?reply|noreply|donotreply|do-not-reply|newsletter|nieuwsbrief|mailer|mailing|notifications?|bounce|postmaster|marketing)@/i, Qt = /\b(unsubscribe|afmelden|uitschrijven|opt[\s-]?out|manage (your )?preferences|geen (e-?mails?|nieuwsbrief|berichten) meer)\b/i;
1869
- function Cr(e, t) {
1870
- return !!(e && Or.test(e) || t && Qt.test(t));
1886
+ const Nr = /(^|[._+-])(no-?reply|noreply|donotreply|do-not-reply|newsletter|nieuwsbrief|mailer|mailing|notifications?|bounce|postmaster|marketing)@/i, Qt = /\b(unsubscribe|afmelden|uitschrijven|opt[\s-]?out|manage (your )?preferences|geen (e-?mails?|nieuwsbrief|berichten) meer)\b/i;
1887
+ function xr(e, t) {
1888
+ return !!(e && Nr.test(e) || t && Qt.test(t));
1871
1889
  }
1872
- const Nr = 3, xr = 600;
1873
- function Pc(e, t) {
1874
- return e >= Nr || t >= xr;
1890
+ const Dr = 3, Rr = 600;
1891
+ function Vc(e, t) {
1892
+ return e >= Dr || t >= Rr;
1875
1893
  }
1876
1894
  const $r = [
1877
1895
  "list-unsubscribe",
@@ -1883,7 +1901,7 @@ const $r = [
1883
1901
  "feedback-id",
1884
1902
  "x-mailer"
1885
1903
  ];
1886
- function Kc(e) {
1904
+ function zc(e) {
1887
1905
  const t = {};
1888
1906
  for (const n of e) {
1889
1907
  const r = n.name?.toLowerCase();
@@ -1891,82 +1909,82 @@ function Kc(e) {
1891
1909
  }
1892
1910
  return t;
1893
1911
  }
1894
- const Dr = /(^|[._+-])(no-?reply|noreply|donotreply|do-not-reply|notifications?|bounce|postmaster|mailer)@/i, Rr = /(^|[._+-])(newsletter|nieuwsbrief|marketing|mailing)@/i;
1895
- function Uc(e) {
1912
+ const Lr = /(^|[._+-])(no-?reply|noreply|donotreply|do-not-reply|notifications?|bounce|postmaster|mailer)@/i, Pr = /(^|[._+-])(newsletter|nieuwsbrief|marketing|mailing)@/i;
1913
+ function Yc(e) {
1896
1914
  const t = e.headers ?? {}, n = e.from?.email, r = t["auto-submitted"]?.toLowerCase();
1897
- if (r && r !== "no" || t["x-auto-response-suppress"] || n && Dr.test(n))
1915
+ if (r && r !== "no" || t["x-auto-response-suppress"] || n && Lr.test(n))
1898
1916
  return "automated";
1899
1917
  const o = t.precedence?.toLowerCase();
1900
- if (t["list-unsubscribe"] || t["list-unsubscribe-post"] || t["list-id"] || o === "bulk" || o === "list" || e.body && Qt.test(e.body) || n && Rr.test(n))
1918
+ if (t["list-unsubscribe"] || t["list-unsubscribe-post"] || t["list-id"] || o === "bulk" || o === "list" || e.body && Qt.test(e.body) || n && Pr.test(n))
1901
1919
  return "marketing";
1902
1920
  }
1903
- function Lr(e, t) {
1921
+ function Kr(e, t) {
1904
1922
  return e.lastActivityAt ? !(e.seenBy ?? []).includes(t) : !1;
1905
1923
  }
1906
- const Pr = ["open"], Kr = 1e3, Ur = 72;
1907
- function Fr(e) {
1924
+ const Ur = ["open"], Fr = 1e3, jr = 72;
1925
+ function Br(e) {
1908
1926
  return e.lastActivityAt ?? (e.createdAt ? new Date(jn(e)).getTime() : 0);
1909
1927
  }
1910
- function jr(e, t) {
1911
- return Br(t.remindersById?.[e.id], e, t.now);
1928
+ function Hr(e, t) {
1929
+ return Gr(t.remindersById?.[e.id], e, t.now);
1912
1930
  }
1913
- function Br(e, t, n) {
1931
+ function Gr(e, t, n) {
1914
1932
  return !e || e.remindAt <= n ? !1 : !((t.lastActivityAt ?? 0) > e.parkedAt && t.lastActivityPreview?.direction === "inbound");
1915
1933
  }
1916
- const Jt = (e) => Rn(e) === "outbound_message", Zt = (e) => Pr.includes(e);
1934
+ const Jt = (e) => $n(e) === "outbound_message", Zt = (e) => Ur.includes(e);
1917
1935
  function je(e, t) {
1918
- return Math.max(0, (t - Fr(e)) / wr);
1936
+ return Math.max(0, (t - Br(e)) / Or);
1919
1937
  }
1920
- function Hr(e, t) {
1938
+ function Wr(e, t) {
1921
1939
  const n = e.assignedInboxId ? t?.[e.assignedInboxId] : void 0;
1922
1940
  return typeof n == "number" && n > 0 ? n : void 0;
1923
1941
  }
1924
- function Fc(e) {
1942
+ function Xc(e) {
1925
1943
  const t = {};
1926
1944
  for (const n of e)
1927
1945
  typeof n.slaHours == "number" && n.slaHours > 0 && (t[n.id] = n.slaHours);
1928
1946
  return t;
1929
1947
  }
1930
- function jc(e, t, n) {
1948
+ function qc(e, t, n) {
1931
1949
  if (!Zt(e.status) || e.firstResponseAt) return !1;
1932
- const r = Hr(e, n);
1950
+ const r = Wr(e, n);
1933
1951
  return r !== void 0 && je(e, t) > r;
1934
1952
  }
1935
- function Gr(e, t) {
1953
+ function Vr(e, t) {
1936
1954
  const n = e.lastActivityPreview;
1937
- return n?.direction !== "outbound" || !Jt(n.type) ? !1 : je(e, t) < Ur;
1955
+ return n?.direction !== "outbound" || !Jt(n.type) ? !1 : je(e, t) < jr;
1938
1956
  }
1939
- function Bc(e, t) {
1957
+ function Qc(e, t) {
1940
1958
  if (!Zt(e.status)) return { score: P, reasons: [] };
1941
1959
  if (e.snoozedTill && e.snoozedTill > t.now) return { score: P, reasons: [] };
1942
- if (Gr(e, t.now)) return { score: P, reasons: [] };
1943
- if (jr(e, t)) return { score: P, reasons: [] };
1960
+ if (Vr(e, t.now)) return { score: P, reasons: [] };
1961
+ if (Hr(e, t)) return { score: P, reasons: [] };
1944
1962
  let n = 0;
1945
1963
  const r = [], o = e.priority ?? "normal";
1946
- ne[o] > 0 && (n += ne[o], r.push(`priority:${o}`)), Lr(e, t.userId) && (n += 20, r.push("unseen")), e.assignedUserId && e.assignedUserId === t.userId && (n += 15, r.push("assigned-to-you"));
1964
+ ne[o] > 0 && (n += ne[o], r.push(`priority:${o}`)), Kr(e, t.userId) && (n += 20, r.push("unseen")), e.assignedUserId && e.assignedUserId === t.userId && (n += 15, r.push("assigned-to-you"));
1947
1965
  const i = je(e, t.now);
1948
1966
  if (i > 0) {
1949
1967
  const l = Math.min(i * 2, 30);
1950
1968
  n += l, i >= 1 && r.push(`waiting:${Math.round(i)}h`);
1951
1969
  }
1952
1970
  const s = e.lastActivityPreview;
1953
- return s?.type === "AI_ACTION_PROPOSED" && (n += 30, r.push("awaiting-approval")), s?.direction === "outbound" && Jt(s.type) && (n += 10, r.push("no-reply")), !e.firstResponseAt && e.lastActivityPreview?.direction === "inbound" && (n += 10, r.push("awaiting-reply")), (e.tags?.some((l) => l === "marketing" || l === "automated") || Cr(e.remoteParty?.resource, e.lastActivityPreview?.snippet)) && (n -= Kr, r.push("bulk")), { score: n, reasons: r };
1971
+ return s?.type === "AI_ACTION_PROPOSED" && (n += 30, r.push("awaiting-approval")), s?.direction === "outbound" && Jt(s.type) && (n += 10, r.push("no-reply")), !e.firstResponseAt && e.lastActivityPreview?.direction === "inbound" && (n += 10, r.push("awaiting-reply")), (e.tags?.some((l) => l === "marketing" || l === "automated") || xr(e.remoteParty?.resource, e.lastActivityPreview?.snippet)) && (n -= Fr, r.push("bulk")), { score: n, reasons: r };
1954
1972
  }
1955
- const Hc = (e) => !!e.assignedUserId || !!e.assignedInboxId, Gc = (e) => e.status === "closed", Wc = (e) => ({
1973
+ const Jc = (e) => !!e.assignedUserId || !!e.assignedInboxId, Zc = (e) => e.status === "closed", el = (e) => ({
1956
1974
  urgent: 10,
1957
1975
  high: 5,
1958
1976
  normal: 2,
1959
1977
  low: 1
1960
- })[e.priority] || 0, Vc = (e, t = 30) => e.title?.length <= t ? e.title : `${e.title.substring(0, t)}...`;
1961
- function zc(e, t) {
1978
+ })[e.priority] || 0, tl = (e, t = 30) => e.title?.length <= t ? e.title : `${e.title.substring(0, t)}...`;
1979
+ function nl(e, t) {
1962
1980
  const n = e.labels ?? [];
1963
1981
  return n.find((r) => r.locale === t)?.label ?? n[0]?.label ?? e.url;
1964
1982
  }
1965
- function Xc(e, t, n) {
1983
+ function rl(e, t, n) {
1966
1984
  const r = e.translations ?? [];
1967
1985
  return r.find((o) => o.locale === t) ?? (n ? r.find((o) => o.locale === n) : void 0) ?? { locale: t };
1968
1986
  }
1969
- const Yc = "article", gt = [
1987
+ const ol = "article", gt = [
1970
1988
  { code: "nl", label: "Nederlands", english: "Dutch" },
1971
1989
  { code: "en", label: "English", english: "English" },
1972
1990
  { code: "de", label: "Deutsch", english: "German" },
@@ -1985,15 +2003,15 @@ function en(e) {
1985
2003
  const t = (e ?? "").toLowerCase();
1986
2004
  return gt.find((n) => n.code === t) ?? gt.find((n) => n.code === t.split("-")[0]);
1987
2005
  }
1988
- function qc(e) {
2006
+ function il(e) {
1989
2007
  return en(e)?.label ?? e;
1990
2008
  }
1991
- function Qc(e) {
2009
+ function sl(e) {
1992
2010
  const t = en(e);
1993
2011
  return t ? t.english === t.label ? `${t.english} (${t.code})` : `${t.english} — ${t.label} (${t.code})` : e;
1994
2012
  }
1995
2013
  const tn = 3;
1996
- function Wr(e, t) {
2014
+ function zr(e, t) {
1997
2015
  const n = /* @__PURE__ */ new Set();
1998
2016
  let r = 1, o = t.get(e)?.parentId;
1999
2017
  for (; o; ) {
@@ -2002,15 +2020,15 @@ function Wr(e, t) {
2002
2020
  }
2003
2021
  return r;
2004
2022
  }
2005
- function Jc(e, t, n) {
2023
+ function al(e, t, n) {
2006
2024
  if (!e) return !0;
2007
2025
  if (e === t) return !1;
2008
2026
  const r = new Map(n.map((s) => [s.id, s]));
2009
- if (!r.has(e) || t && Vr(e, t, r)) return !1;
2010
- const o = Wr(e, r), i = t ? nn(t, n) : 1;
2027
+ if (!r.has(e) || t && Yr(e, t, r)) return !1;
2028
+ const o = zr(e, r), i = t ? nn(t, n) : 1;
2011
2029
  return o + i <= tn;
2012
2030
  }
2013
- function Vr(e, t, n) {
2031
+ function Yr(e, t, n) {
2014
2032
  const r = /* @__PURE__ */ new Set();
2015
2033
  let o = n.get(e)?.parentId;
2016
2034
  for (; o; ) {
@@ -2026,17 +2044,17 @@ function nn(e, t, n = /* @__PURE__ */ new Set()) {
2026
2044
  const r = t.filter((o) => o.parentId === e);
2027
2045
  return r.length ? 1 + Math.max(...r.map((o) => nn(o.id, t, n))) : 1;
2028
2046
  }
2029
- const zr = "en";
2030
- function Xr(e) {
2031
- return e.defaultLocale || e.locale || zr;
2047
+ const Xr = "en";
2048
+ function qr(e) {
2049
+ return e.defaultLocale || e.locale || Xr;
2032
2050
  }
2033
- function Zc(e) {
2051
+ function cl(e) {
2034
2052
  const t = /* @__PURE__ */ new Set(), n = [];
2035
- for (const r of [Xr(e), ...e.locales ?? []])
2053
+ for (const r of [qr(e), ...e.locales ?? []])
2036
2054
  !r || t.has(r) || (t.add(r), n.push(r));
2037
2055
  return n;
2038
2056
  }
2039
- function el(e, t, n) {
2057
+ function ll(e, t, n) {
2040
2058
  const r = e.translations ?? [];
2041
2059
  return r.find((o) => o.locale === t)?.name ?? (n ? r.find((o) => o.locale === n)?.name : void 0) ?? e.name;
2042
2060
  }
@@ -2061,7 +2079,7 @@ function de(e) {
2061
2079
  }
2062
2080
  return null;
2063
2081
  }
2064
- function Yr(e, t) {
2082
+ function Qr(e, t) {
2065
2083
  switch (e.kind) {
2066
2084
  case "org":
2067
2085
  return !0;
@@ -2071,29 +2089,29 @@ function Yr(e, t) {
2071
2089
  return e.userId === t.userId;
2072
2090
  }
2073
2091
  }
2074
- function tl(e, t) {
2075
- return e.filter((n) => n.enabled && Yr(n.ownerScope, t));
2092
+ function ul(e, t) {
2093
+ return e.filter((n) => n.enabled && Qr(n.ownerScope, t));
2076
2094
  }
2077
- function nl(e) {
2095
+ function dl(e) {
2078
2096
  return e.credentialScope ? e.credentialScope : (e.authMode ?? "header") === "header" || e.oauth?.scope === "org" ? "shared" : "per-user";
2079
2097
  }
2080
- function rl(e) {
2098
+ function fl(e) {
2081
2099
  return `mcp__${e}__`;
2082
2100
  }
2083
- const ol = 1e3, il = 2e3, sl = 500, al = 12e3, cl = 4e3, qr = ["contact", "company", "work_item"];
2084
- function ll(e) {
2101
+ const pl = 1e3, ml = 2e3, hl = 500, gl = 12e3, yl = 4e3, Jr = ["contact", "company", "work_item"];
2102
+ function bl(e) {
2085
2103
  if (!e) return !1;
2086
2104
  const t = e.slice(0, e.indexOf(":"));
2087
- return qr.includes(t);
2105
+ return Jr.includes(t);
2088
2106
  }
2089
- const ul = [
2107
+ const _l = [
2090
2108
  { key: "high", label: "tax_high", percent: 21, kind: "standard" },
2091
2109
  { key: "low", label: "tax_low", percent: 9, kind: "reduced" },
2092
2110
  { key: "zero", label: "tax_zero", percent: 0, kind: "zero" },
2093
2111
  { key: "reverse_charge", label: "tax_reverse_charge", percent: 0, kind: "reverse_charge" },
2094
2112
  { key: "exempt", label: "tax_exempt", percent: 0, kind: "exempt" }
2095
2113
  ];
2096
- function Qr(e, t) {
2114
+ function Zr(e, t) {
2097
2115
  return t.find((n) => n.key === e) ?? {
2098
2116
  key: e,
2099
2117
  label: e,
@@ -2101,13 +2119,13 @@ function Qr(e, t) {
2101
2119
  kind: "zero"
2102
2120
  };
2103
2121
  }
2104
- function Jr(e) {
2122
+ function eo(e) {
2105
2123
  if (e.kind !== "product") return 0;
2106
2124
  const t = 1 - (e.discountPercent ?? 0) / 100;
2107
2125
  return z(e.quantity * e.unitPriceCents * t);
2108
2126
  }
2109
- function dl(e, t, n) {
2110
- const r = e.map((c) => ({ ...c, netCents: Jr(c), taxCents: 0 })), o = /* @__PURE__ */ new Map();
2127
+ function Al(e, t, n) {
2128
+ const r = e.map((c) => ({ ...c, netCents: eo(c), taxCents: 0 })), o = /* @__PURE__ */ new Map();
2111
2129
  for (let c = 0; c < r.length; c++) {
2112
2130
  if (r[c].kind !== "product" || r[c].optional) continue;
2113
2131
  const d = n ?? r[c].taxRateKey, u = o.get(d);
@@ -2116,7 +2134,7 @@ function dl(e, t, n) {
2116
2134
  const i = [];
2117
2135
  let s = 0, a = 0;
2118
2136
  for (const [c, d] of o) {
2119
- const u = Qr(c, t), f = d.reduce((m, S) => m + r[S].netCents, 0), p = z(f * u.percent / 100), y = mr(
2137
+ const u = Zr(c, t), f = d.reduce((m, S) => m + r[S].netCents, 0), p = z(f * u.percent / 100), y = mr(
2120
2138
  p,
2121
2139
  d.map((m) => r[m].netCents)
2122
2140
  );
@@ -2144,7 +2162,7 @@ function dl(e, t, n) {
2144
2162
  }
2145
2163
  };
2146
2164
  }
2147
- const fl = "onboarding-source", pl = ["support", "billing", "availability", "sales", "onboarding"], ml = ["keep", "replace"], Be = [
2165
+ const El = "onboarding-source", Sl = ["support", "billing", "availability", "sales", "onboarding"], Tl = ["keep", "replace"], Be = [
2148
2166
  {
2149
2167
  key: "shift",
2150
2168
  label: "kind_shift",
@@ -2218,36 +2236,36 @@ const fl = "onboarding-source", pl = ["support", "billing", "availability", "sal
2218
2236
  absent: !0,
2219
2237
  icon: "party-popper"
2220
2238
  }
2221
- ], Zr = {
2239
+ ], to = {
2222
2240
  key: "unknown",
2223
2241
  label: "kind_unknown",
2224
2242
  capacity: !1,
2225
2243
  productive: !1,
2226
2244
  absent: !1
2227
2245
  };
2228
- function $(e, t = Be) {
2229
- return t.find((n) => n.key === e) ?? { ...Zr, key: e };
2246
+ function D(e, t = Be) {
2247
+ return t.find((n) => n.key === e) ?? { ...to, key: e };
2230
2248
  }
2231
- function X(e) {
2249
+ function Y(e) {
2232
2250
  return e === "published" || e === "approved";
2233
2251
  }
2234
2252
  function rn(e, t, n = Be) {
2235
2253
  if (e.workstreamId !== t) return !1;
2236
- const r = $(e.kindKey, n);
2254
+ const r = D(e.kindKey, n);
2237
2255
  return r.absent ? !1 : r.productive || r.capacity;
2238
2256
  }
2239
- function hl(e, t = Be) {
2240
- if (!e.userId || !X(e.status)) return !1;
2241
- const n = $(e.kindKey, t);
2257
+ function Il(e, t = Be) {
2258
+ if (!e.userId || !Y(e.status)) return !1;
2259
+ const n = D(e.kindKey, t);
2242
2260
  return n.capacity || n.productive || n.absent;
2243
2261
  }
2244
- const eo = 864e5;
2245
- function to(e, t) {
2246
- return Math.round((t - e) / eo);
2262
+ const no = 864e5;
2263
+ function ro(e, t) {
2264
+ return Math.round((t - e) / no);
2247
2265
  }
2248
2266
  function on(e, t) {
2249
2267
  const n = e.cycleMinutes.length;
2250
- return n === 0 ? 0 : (to(e.anchor, t) % n + n) % n;
2268
+ return n === 0 ? 0 : (ro(e.anchor, t) % n + n) % n;
2251
2269
  }
2252
2270
  function sn(e, t) {
2253
2271
  return e.effectiveFrom !== void 0 && t < e.effectiveFrom ? 0 : e.cycleMinutes[on(e, t)] ?? 0;
@@ -2263,13 +2281,13 @@ function cn(e, t, n, r) {
2263
2281
  o.filter((a) => !a.userId && a.teamId && n.includes(a.teamId))
2264
2282
  );
2265
2283
  }
2266
- function no(e, t, n) {
2284
+ function oo(e, t, n) {
2267
2285
  return e.filter(
2268
2286
  (r) => r.userId === t && (r.effectiveFrom === void 0 || r.effectiveFrom <= n)
2269
2287
  ).sort((r, o) => (o.effectiveFrom ?? 0) - (r.effectiveFrom ?? 0))[0];
2270
2288
  }
2271
2289
  const Te = 864e5;
2272
- function ro(e) {
2290
+ function io(e) {
2273
2291
  const t = Math.max(1, Math.round((e.to - e.from) / Te));
2274
2292
  return Array.from({ length: t }, (n, r) => e.from + r * Te);
2275
2293
  }
@@ -2278,11 +2296,11 @@ function Ie(e, t, n, r) {
2278
2296
  return o > 0 ? o / 1e3 : 0;
2279
2297
  }
2280
2298
  const bt = { interval: 0, day: 1, week: 2 };
2281
- function gl(e, t) {
2299
+ function vl(e, t) {
2282
2300
  const { entries: n, patterns: r = [], terms: o = [] } = t, i = n.filter(
2283
- (u) => u.userId && X(u.status) && $(u.kindKey).capacity
2301
+ (u) => u.userId && Y(u.status) && D(u.kindKey).capacity
2284
2302
  ), s = n.filter(
2285
- (u) => u.userId && X(u.status) && $(u.kindKey).absent
2303
+ (u) => u.userId && Y(u.status) && D(u.kindKey).absent
2286
2304
  ), a = t.userIds ?? [
2287
2305
  .../* @__PURE__ */ new Set([
2288
2306
  ...i.map((u) => u.userId),
@@ -2297,10 +2315,10 @@ function gl(e, t) {
2297
2315
  for (const u of a) {
2298
2316
  const f = t.teamIdsOf?.(u) ?? [];
2299
2317
  let p = 0, y = 0, m = 0;
2300
- for (const h of ro(e)) {
2318
+ for (const h of io(e)) {
2301
2319
  const E = Math.max(h, e.from), x = Math.min(h + Te, e.to);
2302
2320
  m++;
2303
- const C = i.filter((k) => k.userId === u).reduce((k, Ye) => k + Ie(Ye.start, Ye.end, E, x), 0);
2321
+ const C = i.filter((k) => k.userId === u).reduce((k, Xe) => k + Ie(Xe.start, Xe.end, E, x), 0);
2304
2322
  if (C > 0) {
2305
2323
  p += C;
2306
2324
  continue;
@@ -2313,7 +2331,7 @@ function gl(e, t) {
2313
2331
  w || y++;
2314
2332
  }
2315
2333
  if (y > 0) {
2316
- const h = no(o, u, e.from);
2334
+ const h = oo(o, u, e.from);
2317
2335
  h && (p += h.weeklyMinutes * 60 * (y / 7), d("week"));
2318
2336
  }
2319
2337
  const S = s.filter((h) => h.userId === u).reduce(
@@ -2328,7 +2346,7 @@ function gl(e, t) {
2328
2346
  byUser: l
2329
2347
  };
2330
2348
  }
2331
- function yl(e, t) {
2349
+ function kl(e, t) {
2332
2350
  if (!e.some((a) => a.userId)) return [];
2333
2351
  const n = "", r = /* @__PURE__ */ new Map();
2334
2352
  for (const a of e) {
@@ -2351,14 +2369,14 @@ function yl(e, t) {
2351
2369
  const s = r.get(n) ?? 0;
2352
2370
  return s > 0 && i.push({ requiredSeconds: s, capacitySeconds: 0, netSeconds: -s }), i;
2353
2371
  }
2354
- function bl(e, t, n, r) {
2372
+ function wl(e, t, n, r) {
2355
2373
  const o = e.filter(
2356
- (s) => s.userId && X(s.status) && !$(s.kindKey).absent
2374
+ (s) => s.userId && Y(s.status) && !D(s.kindKey).absent
2357
2375
  ), i = Object.entries(r.byUser).map(
2358
2376
  ([s, a]) => {
2359
2377
  let l = 0, c = 0;
2360
2378
  for (const d of o) {
2361
- if (d.userId !== s || $(d.kindKey).capacity && !d.workstreamId) continue;
2379
+ if (d.userId !== s || D(d.kindKey).capacity && !d.workstreamId) continue;
2362
2380
  const u = Ie(d.start, d.end, n.from, n.to);
2363
2381
  u <= 0 || (rn(d, t) ? l += u : c += u);
2364
2382
  }
@@ -2373,59 +2391,59 @@ function bl(e, t, n, r) {
2373
2391
  );
2374
2392
  return i.sort((s, a) => a.freeSeconds - s.freeSeconds), i;
2375
2393
  }
2376
- const Al = "demand-source", At = 1e3;
2377
- function oo(e, t) {
2394
+ const Ml = "demand-source", _t = 1e3;
2395
+ function so(e, t) {
2378
2396
  let n = 1;
2379
2397
  for (let r = 1; r <= e; r++)
2380
2398
  n = t * n / (r + t * n);
2381
2399
  return n;
2382
2400
  }
2383
- function io(e, t) {
2401
+ function ao(e, t) {
2384
2402
  if (e <= 0) return 1;
2385
2403
  if (t <= 0) return 0;
2386
2404
  if (e <= t) return 1;
2387
- const n = oo(e, t), r = t / e;
2405
+ const n = so(e, t), r = t / e;
2388
2406
  return n / (1 - r * (1 - n));
2389
2407
  }
2390
- function so(e, t, n, r) {
2391
- return r <= 0 ? 1 : e <= t ? 0 : 1 - io(e, t) * Math.exp(-(e - t) * n / r);
2408
+ function co(e, t, n, r) {
2409
+ return r <= 0 ? 1 : e <= t ? 0 : 1 - ao(e, t) * Math.exp(-(e - t) * n / r);
2392
2410
  }
2393
- function ao(e, t, n) {
2411
+ function lo(e, t, n) {
2394
2412
  return n <= 0 ? 0 : e * t / n;
2395
2413
  }
2396
- function co(e, t, n, r) {
2414
+ function uo(e, t, n, r) {
2397
2415
  if (e <= 0 || t <= 0) return 0;
2398
- const o = ao(e, t, n);
2416
+ const o = lo(e, t, n);
2399
2417
  if (o <= 0) return 0;
2400
2418
  const i = r.serviceLevelPercent / 100, s = r.maxOccupancyPercent ? r.maxOccupancyPercent / 100 : void 0;
2401
- for (let a = Math.max(1, Math.ceil(o)); a <= At; a++)
2402
- if (!(a <= o) && !(so(a, o, r.targetSeconds, t) < i) && !(s && o / a > s))
2419
+ for (let a = Math.max(1, Math.ceil(o)); a <= _t; a++)
2420
+ if (!(a <= o) && !(co(a, o, r.targetSeconds, t) < i) && !(s && o / a > s))
2403
2421
  return a;
2404
- return At;
2422
+ return _t;
2405
2423
  }
2406
- const lo = 36e5, uo = 864e5;
2407
- function fo(e) {
2408
- return e === "day" ? uo : lo;
2424
+ const fo = 36e5, po = 864e5;
2425
+ function mo(e) {
2426
+ return e === "day" ? po : fo;
2409
2427
  }
2410
- function _l(e, t) {
2428
+ function Ol(e, t) {
2411
2429
  return e.start < t.end && t.start < e.end;
2412
2430
  }
2413
2431
  function fe(e, t, n) {
2414
2432
  const r = Math.min(e.end, n) - Math.max(e.start, t);
2415
2433
  return r > 0 ? r / 1e3 : 0;
2416
2434
  }
2417
- function po(e, t, n) {
2435
+ function ho(e, t, n) {
2418
2436
  const r = e.handleSeconds ?? 0, o = e.seconds ?? (e.volume !== void 0 ? e.volume * r : 0);
2419
2437
  if (o <= 0 && !e.volume) return { seconds: 0, headcount: 0 };
2420
2438
  const i = (t.unplannedLossPercent ?? 0) / 100, s = i > 0 && i < 1 ? 1 / (1 - i) : 1;
2421
2439
  if (t.model === "queue" && e.volume !== void 0 && r > 0) {
2422
- const a = co(e.volume, r, n, t);
2440
+ const a = uo(e.volume, r, n, t);
2423
2441
  return { seconds: o, headcount: a * s };
2424
2442
  }
2425
2443
  return { seconds: o, headcount: o / n * s };
2426
2444
  }
2427
- function El(e) {
2428
- const { entries: t, workstreamId: n, staffing: r, demand: o, range: i } = e, s = e.grain ?? "hour", a = fo(s), l = a / 1e3, c = e.kinds, d = t.filter((m) => X(m.status)), u = d.filter((m) => rn(m, n, c)), f = d.filter((m) => $(m.kindKey, c).capacity), p = d.filter((m) => $(m.kindKey, c).absent), y = [];
2445
+ function Cl(e) {
2446
+ const { entries: t, workstreamId: n, staffing: r, demand: o, range: i } = e, s = e.grain ?? "hour", a = mo(s), l = a / 1e3, c = e.kinds, d = t.filter((m) => Y(m.status)), u = d.filter((m) => rn(m, n, c)), f = d.filter((m) => D(m.kindKey, c).capacity), p = d.filter((m) => D(m.kindKey, c).absent), y = [];
2429
2447
  for (let m = V(i.from, s); m < i.to; m += a) {
2430
2448
  const S = m + a, g = W(m, s);
2431
2449
  let h = 0;
@@ -2434,7 +2452,7 @@ function El(e) {
2434
2452
  for (const k of f) E += fe(k, m, S);
2435
2453
  let x = 0;
2436
2454
  for (const k of p) x += fe(k, m, S);
2437
- const C = o?.[g] ?? {}, w = po(C, r, l), N = h / l;
2455
+ const C = o?.[g] ?? {}, w = ho(C, r, l), N = h / l;
2438
2456
  y.push({
2439
2457
  period: g,
2440
2458
  forecastVolume: C.volume,
@@ -2449,24 +2467,24 @@ function El(e) {
2449
2467
  }
2450
2468
  return y;
2451
2469
  }
2452
- function mo(e, t) {
2470
+ function go(e, t) {
2453
2471
  return e.workTypeKey ?? t?.defaultWorkTypeKey;
2454
2472
  }
2455
- function Sl(e, t, n) {
2456
- const r = mo(e, t);
2473
+ function Nl(e, t, n) {
2474
+ const r = go(e, t);
2457
2475
  return r ? n.find((o) => o.key === r)?.defaultBillable ?? !1 : !1;
2458
2476
  }
2459
- function Tl(e) {
2477
+ function xl(e) {
2460
2478
  return e.filter(
2461
2479
  (t) => t.netHeadcount < 0 && t.requiredHeadcount > 0
2462
2480
  );
2463
2481
  }
2464
- const ho = 36e5, ve = 6048e5, go = 8, yo = 0.5, bo = 2;
2465
- function Ao(e) {
2482
+ const yo = 36e5, ve = 6048e5, bo = 8, _o = 0.5, Ao = 2;
2483
+ function Eo(e) {
2466
2484
  const t = Number(e.slice(0, 4)), n = Number(e.slice(5, 7)), r = Number(e.slice(8, 10)), o = e.length > 10 ? Number(e.slice(11, 13)) : 0;
2467
2485
  return Date.UTC(t, n - 1, r, o);
2468
2486
  }
2469
- function _o(e, t, n) {
2487
+ function So(e, t, n) {
2470
2488
  const r = [];
2471
2489
  for (let i = 0; i < n; i++) {
2472
2490
  const s = t - i * ve, a = s - ve;
@@ -2477,21 +2495,21 @@ function _o(e, t, n) {
2477
2495
  }
2478
2496
  if (r.length < 2) return 1;
2479
2497
  const o = r.reduce((i, s) => i + s, 0) / r.length;
2480
- return o <= 0 ? 1 : Math.min(bo, Math.max(yo, r[0] / o));
2498
+ return o <= 0 ? 1 : Math.min(Ao, Math.max(_o, r[0] / o));
2481
2499
  }
2482
- function Eo(e, t) {
2500
+ function To(e, t) {
2483
2501
  if (!e?.length) return;
2484
2502
  let n;
2485
2503
  for (const r of e)
2486
2504
  t >= r.from && t < r.to && (n = r);
2487
2505
  return n;
2488
2506
  }
2489
- function Il(e, t, n) {
2490
- const r = Math.max(1, n?.weeks ?? go), o = /* @__PURE__ */ new Map(), i = /* @__PURE__ */ new Set();
2507
+ function Dl(e, t, n) {
2508
+ const r = Math.max(1, n?.weeks ?? bo), o = /* @__PURE__ */ new Map(), i = /* @__PURE__ */ new Set();
2491
2509
  for (const l of e)
2492
- o.set(Ao(l.period), l.value), i.add(l.period.slice(0, 10));
2493
- const s = _o(o, V(t.from, "hour"), r), a = [];
2494
- for (let l = V(t.from, "hour"); l < t.to; l += ho) {
2510
+ o.set(Eo(l.period), l.value), i.add(l.period.slice(0, 10));
2511
+ const s = So(o, V(t.from, "hour"), r), a = [];
2512
+ for (let l = V(t.from, "hour"); l < t.to; l += yo) {
2495
2513
  let c = 0, d = 0;
2496
2514
  for (let p = 1; p <= r; p++) {
2497
2515
  const y = l - p * ve, S = o.get(y) ?? (i.has(W(y, "day")) ? 0 : void 0);
@@ -2500,25 +2518,25 @@ function Il(e, t, n) {
2500
2518
  c += S * g, d += g;
2501
2519
  }
2502
2520
  let u = d > 0 ? c / d * s : 0;
2503
- const f = Eo(n?.adjustments, l);
2521
+ const f = To(n?.adjustments, l);
2504
2522
  f?.absoluteVolume !== void 0 ? u = f.absoluteVolume : f?.factor !== void 0 && (u *= f.factor), a.push({ period: W(l, "hour"), volume: u });
2505
2523
  }
2506
2524
  return a;
2507
2525
  }
2508
- const So = "schedule_entry", To = "workstream";
2509
- function vl(e) {
2510
- return `${So}:${e}`;
2526
+ const Io = "schedule_entry", vo = "workstream";
2527
+ function Rl(e) {
2528
+ return `${Io}:${e}`;
2511
2529
  }
2512
- function kl(e) {
2513
- return `${To}:${e}`;
2530
+ function $l(e) {
2531
+ return `${vo}:${e}`;
2514
2532
  }
2515
2533
  const ke = 36e5, F = 864e5;
2516
- function Io(e, t) {
2534
+ function ko(e, t) {
2517
2535
  const n = t === "day" ? F : ke, r = [];
2518
2536
  for (let o = V(e.from, t); o < e.to; o += n) r.push(o);
2519
2537
  return r;
2520
2538
  }
2521
- function _t(e) {
2539
+ function At(e) {
2522
2540
  const t = Math.max(1, Math.round((e.to - e.from) / F));
2523
2541
  return Array.from({ length: t }, (n, r) => e.from + r * F);
2524
2542
  }
@@ -2526,15 +2544,15 @@ function pe(e, t, n, r) {
2526
2544
  const o = Math.min(t, r) - Math.max(e, n);
2527
2545
  return o > 0 ? o / 1e3 : 0;
2528
2546
  }
2529
- function wl(e, t, n = {}) {
2530
- const r = n.grain ?? "hour", o = Io(t, r), i = r === "day" ? F : ke, s = new Map(o.map((u) => [u, 0])), a = e.filter((u) => u.userId && $(u.kindKey).capacity), l = n.userIds?.length ? new Set(n.userIds) : null, c = /* @__PURE__ */ new Set();
2547
+ function Ll(e, t, n = {}) {
2548
+ const r = n.grain ?? "hour", o = ko(t, r), i = r === "day" ? F : ke, s = new Map(o.map((u) => [u, 0])), a = e.filter((u) => u.userId && D(u.kindKey).capacity), l = n.userIds?.length ? new Set(n.userIds) : null, c = /* @__PURE__ */ new Set();
2531
2549
  for (const u of a)
2532
2550
  if (!(l && u.userId && !l.has(u.userId))) {
2533
2551
  for (const f of o) {
2534
2552
  const p = pe(u.start, u.end, f, f + i);
2535
2553
  p > 0 && s.set(f, (s.get(f) ?? 0) + p);
2536
2554
  }
2537
- for (const f of _t(t))
2555
+ for (const f of At(t))
2538
2556
  pe(u.start, u.end, f, f + F) > 0 && c.add(`${u.userId}:${f}`);
2539
2557
  }
2540
2558
  const d = n.userIds ?? [
@@ -2546,7 +2564,7 @@ function wl(e, t, n = {}) {
2546
2564
  if (n.patterns?.length)
2547
2565
  for (const u of d) {
2548
2566
  const f = n.teamIdsOf?.(u) ?? [];
2549
- for (const p of _t(t)) {
2567
+ for (const p of At(t)) {
2550
2568
  if (c.has(`${u}:${p}`)) continue;
2551
2569
  const y = cn(n.patterns, u, f, p);
2552
2570
  if (!y) continue;
@@ -2569,7 +2587,7 @@ function wl(e, t, n = {}) {
2569
2587
  }
2570
2588
  return o.map((u) => ({ period: W(u, r), weight: s.get(u) ?? 0 }));
2571
2589
  }
2572
- function vo(e, t) {
2590
+ function wo(e, t) {
2573
2591
  if (e <= 0 || !t.length) return [];
2574
2592
  const n = t.reduce((r, o) => r + Math.max(0, o.weight), 0);
2575
2593
  if (n <= 0) {
@@ -2578,11 +2596,11 @@ function vo(e, t) {
2578
2596
  }
2579
2597
  return t.filter((r) => r.weight > 0).map((r) => ({ period: r.period, seconds: e * r.weight / n }));
2580
2598
  }
2581
- function Ml(e, t, n) {
2599
+ function Pl(e, t, n) {
2582
2600
  const r = /* @__PURE__ */ new Map();
2583
2601
  for (const o of e) {
2584
2602
  const i = o.by ? t.filter((a) => n(a.period) < o.by) : t, s = i.length ? i : t;
2585
- for (const a of vo(o.seconds, s)) {
2603
+ for (const a of wo(o.seconds, s)) {
2586
2604
  const l = `${a.period}|${o.userId ?? ""}`, c = r.get(l);
2587
2605
  c ? c.seconds += a.seconds : r.set(l, { ...a, userId: o.userId });
2588
2606
  }
@@ -2591,7 +2609,7 @@ function Ml(e, t, n) {
2591
2609
  (o, i) => o.period.localeCompare(i.period) || (o.userId ?? "").localeCompare(i.userId ?? "")
2592
2610
  );
2593
2611
  }
2594
- function ko(e) {
2612
+ function Mo(e) {
2595
2613
  switch (e.kind) {
2596
2614
  case "user":
2597
2615
  return `user:${e.userId}`;
@@ -2601,7 +2619,7 @@ function ko(e) {
2601
2619
  return "org";
2602
2620
  }
2603
2621
  }
2604
- function Ol(e) {
2622
+ function Kl(e) {
2605
2623
  if (typeof e != "string") return;
2606
2624
  const t = e.trim();
2607
2625
  if (t === "org") return { kind: "org" };
@@ -2613,10 +2631,10 @@ function Ol(e) {
2613
2631
  if (r === "team") return { kind: "team", teamId: o };
2614
2632
  }
2615
2633
  }
2616
- function wo(e) {
2617
- return ko(e);
2634
+ function Oo(e) {
2635
+ return Mo(e);
2618
2636
  }
2619
- function Mo(e) {
2637
+ function Co(e) {
2620
2638
  switch (e.kind) {
2621
2639
  case "personal":
2622
2640
  return { kind: "user", userId: e.userId };
@@ -2626,21 +2644,21 @@ function Mo(e) {
2626
2644
  return { kind: "org" };
2627
2645
  }
2628
2646
  }
2629
- function Cl(e) {
2630
- return e.agentId ? { kind: "user", userId: e.agentId } : Mo(e.ownerScope);
2647
+ function Ul(e) {
2648
+ return e.agentId ? { kind: "user", userId: e.agentId } : Co(e.ownerScope);
2631
2649
  }
2632
- function Nl(e) {
2633
- return wo(e);
2650
+ function Fl(e) {
2651
+ return Oo(e);
2634
2652
  }
2635
- const Oo = "playbook-run", xl = "run";
2636
- function $l(e, t = 0) {
2637
- return `${Oo}:${e}~${t}`;
2653
+ const No = "playbook-run", jl = "run";
2654
+ function Bl(e, t = 0) {
2655
+ return `${No}:${e}~${t}`;
2638
2656
  }
2639
- function Dl(e) {
2657
+ function Hl(e) {
2640
2658
  const t = e.indexOf("~");
2641
2659
  return t < 0 ? e : e.slice(0, t);
2642
2660
  }
2643
- function Co(e, t) {
2661
+ function xo(e, t) {
2644
2662
  if (!t) return;
2645
2663
  let n = e;
2646
2664
  for (const r of t.split(".")) {
@@ -2649,44 +2667,44 @@ function Co(e, t) {
2649
2667
  }
2650
2668
  return n;
2651
2669
  }
2652
- function Rl(e, t) {
2670
+ function Gl(e, t) {
2653
2671
  return e.targets.find((n) => n.activityTypes.includes(t));
2654
2672
  }
2655
- function Ll(e, t) {
2673
+ function Wl(e, t) {
2656
2674
  if (t)
2657
2675
  return e.targets.find((n) => n.id === t);
2658
2676
  }
2659
- function No(e) {
2677
+ function Do(e) {
2660
2678
  return e?.kind === "assignment";
2661
2679
  }
2662
- function Pl(e) {
2680
+ function Vl(e) {
2663
2681
  const { trigger: t, agentId: n, target: r, activityType: o, assigneeUserId: i, authorUserId: s } = e;
2664
- return No(t) ? n ? r ? r.activityTypes.includes(o) ? i ? i !== n ? "assigned to someone else" : s && s === n ? "the agent assigned this to itself, which would restart its own run" : null : `no assignee found at ${r.assigneePath}` : `activity type ${o} 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";
2682
+ return Do(t) ? n ? r ? r.activityTypes.includes(o) ? i ? i !== n ? "assigned to someone else" : s && s === n ? "the agent assigned this to itself, which would restart its own run" : null : `no assignee found at ${r.assigneePath}` : `activity type ${o} 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";
2665
2683
  }
2666
2684
  const we = ["suggest", "outward", "auto"];
2667
- function Kl(e) {
2685
+ function zl(e) {
2668
2686
  return typeof e == "string" && we.includes(e);
2669
2687
  }
2670
- function Ul(e) {
2688
+ function Yl(e) {
2671
2689
  const t = e.playbook?.autonomy ?? e.agent?.autonomy ?? "suggest";
2672
2690
  return e.demoted && t === "auto" ? "outward" : t;
2673
2691
  }
2674
- function Fl(e, t) {
2692
+ function Xl(e, t) {
2675
2693
  const n = e ?? "suggest";
2676
2694
  return t && we.indexOf(t) < we.indexOf(n) ? t : n;
2677
2695
  }
2678
- function jl(e) {
2696
+ function ql(e) {
2679
2697
  return e.replace(/__/g, " · ").replace(/\./g, " · ").replace(/_/g, " ");
2680
2698
  }
2681
- function xo(e) {
2699
+ function Ro(e) {
2682
2700
  const t = e.split("__");
2683
2701
  return t[t.length - 1] || e;
2684
2702
  }
2685
- function Bl(e) {
2686
- const t = xo(e).replace(/[_.]+/g, " ").trim();
2703
+ function Ql(e) {
2704
+ const t = Ro(e).replace(/[_.]+/g, " ").trim();
2687
2705
  return t ? t.charAt(0).toUpperCase() + t.slice(1) : e;
2688
2706
  }
2689
- const Hl = [
2707
+ const Jl = [
2690
2708
  { name: "text", type: "string" },
2691
2709
  { name: "subject", type: "string" },
2692
2710
  { name: "from", type: "string" },
@@ -2727,10 +2745,10 @@ const Hl = [
2727
2745
  // the trigger filter runs — like contactId/companyId above.
2728
2746
  { name: "assigneeUserId", type: "string" }
2729
2747
  ];
2730
- function Gl(e, t) {
2748
+ function Zl(e, t) {
2731
2749
  return !e.onlyFor || !t?.length ? !0 : t.some((n) => e.onlyFor?.includes(n));
2732
2750
  }
2733
- const Wl = {
2751
+ const eu = {
2734
2752
  topics: [
2735
2753
  { name: "topicId", type: "string" },
2736
2754
  { name: "topic", type: "string" },
@@ -2747,17 +2765,17 @@ const Wl = {
2747
2765
  function $o(e) {
2748
2766
  return `${e.type}:${e.id}`;
2749
2767
  }
2750
- const Do = "interaction";
2751
- function Ro(e) {
2752
- return e?.type === Do ? e.id : void 0;
2768
+ const Lo = "interaction";
2769
+ function Po(e) {
2770
+ return e?.type === Lo ? e.id : void 0;
2753
2771
  }
2754
- const Lo = 64, Po = 8e3;
2755
- function Vl(e) {
2772
+ const Ko = 64, Uo = 8e3;
2773
+ function tu(e) {
2756
2774
  const t = typeof e == "number" ? e : Number(String(e ?? "").trim());
2757
2775
  if (!(!Number.isFinite(t) || t <= 0))
2758
- return Math.min(Math.max(Math.round(t), Lo), Po);
2776
+ return Math.min(Math.max(Math.round(t), Ko), Uo);
2759
2777
  }
2760
- const zl = [
2778
+ const nu = [
2761
2779
  "condition",
2762
2780
  "for-each",
2763
2781
  "parallel",
@@ -2768,48 +2786,48 @@ const zl = [
2768
2786
  "agent",
2769
2787
  "wait-for-reply",
2770
2788
  "wait-for-task"
2771
- ], Xl = { kind: "workflow", steps: [] };
2772
- function Yl(e) {
2789
+ ], ru = { kind: "workflow", steps: [] };
2790
+ function ou(e) {
2773
2791
  return e?.kind === "workflow" ? e.steps : [];
2774
2792
  }
2775
- function ql(e) {
2793
+ function iu(e) {
2776
2794
  return e?.kind === "procedure" ? e.procedure : void 0;
2777
2795
  }
2778
- function Ql(e) {
2796
+ function su(e) {
2779
2797
  return e.assignmentId ? "assignment" : e.decider?.kind === "procedure" ? "procedure" : "workflow";
2780
2798
  }
2781
- function Ko(e) {
2799
+ function Fo(e) {
2782
2800
  const t = e?.approved ?? 0, n = t + (e?.rejected ?? 0);
2783
2801
  return { total: n, rate: n ? t / n : 0 };
2784
2802
  }
2785
- const Uo = 10, Fo = 0.9;
2786
- function Jl(e) {
2787
- const { total: t, rate: n } = Ko(e);
2788
- return t >= Uo && n >= Fo;
2803
+ const jo = 10, Bo = 0.9;
2804
+ function au(e) {
2805
+ const { total: t, rate: n } = Fo(e);
2806
+ return t >= jo && n >= Bo;
2789
2807
  }
2790
- const jo = ["done", "escalated", "failed", "stopped"];
2791
- function Zl(e) {
2792
- return jo.includes(e);
2808
+ const Ho = ["done", "escalated", "failed", "stopped"];
2809
+ function cu(e) {
2810
+ return Ho.includes(e);
2793
2811
  }
2794
- function Bo(e) {
2812
+ function Go(e) {
2795
2813
  return e === "waiting";
2796
2814
  }
2797
- function eu(e) {
2798
- return e === "running" || Bo(e);
2815
+ function lu(e) {
2816
+ return e === "running" || Go(e);
2799
2817
  }
2800
2818
  function ln(e) {
2801
2819
  return e.subjectKind && e.subjectId ? { type: e.subjectKind, id: e.subjectId } : void 0;
2802
2820
  }
2803
- function tu(e) {
2821
+ function uu(e) {
2804
2822
  const t = ln(e);
2805
2823
  return t ? $o(t) : void 0;
2806
2824
  }
2807
- function nu(e) {
2808
- return Ro(ln(e));
2825
+ function du(e) {
2826
+ return Po(ln(e));
2809
2827
  }
2810
- function ru(e) {
2828
+ function fu(e) {
2811
2829
  const t = [], n = /* @__PURE__ */ new Map();
2812
- for (const r of [...e].sort(Ho)) {
2830
+ for (const r of [...e].sort(Wo)) {
2813
2831
  const o = n.get(r.emoji);
2814
2832
  if (o) {
2815
2833
  o.push(r.actor);
@@ -2822,8 +2840,8 @@ function ru(e) {
2822
2840
  return { emoji: r, count: o.length, actors: o };
2823
2841
  }).sort((r, o) => o.count - r.count || t.indexOf(r.emoji) - t.indexOf(o.emoji));
2824
2842
  }
2825
- const Ho = (e, t) => (e.createdAt ?? 0) - (t.createdAt ?? 0);
2826
- function ou(e, t) {
2843
+ const Wo = (e, t) => (e.createdAt ?? 0) - (t.createdAt ?? 0);
2844
+ function pu(e, t) {
2827
2845
  return t ? e.actors.some((n) => n.type === "user" && n.id === t) : !1;
2828
2846
  }
2829
2847
  class un extends Error {
@@ -2831,12 +2849,12 @@ class un extends Error {
2831
2849
  super(t), this.name = "UnresolvedRefError";
2832
2850
  }
2833
2851
  }
2834
- const Go = /^\{\{\s*([\w.]+)\s*\}\}$/, Wo = /\{\{\s*([\w.]+)\s*\}\}/g, Vo = /\$[A-Za-z_][\w]*\.[\w.]+/;
2835
- function iu(e, t, n = {}) {
2852
+ const Vo = /^\{\{\s*([\w.]+)\s*\}\}$/, zo = /\{\{\s*([\w.]+)\s*\}\}/g, Yo = /\$[A-Za-z_][\w]*\.[\w.]+/;
2853
+ function mu(e, t, n = {}) {
2836
2854
  return Me(e, t, n);
2837
2855
  }
2838
2856
  function Me(e, t, n = {}) {
2839
- return typeof e == "string" ? zo(e, t, n) : Array.isArray(e) ? e.map((r) => Me(r, t, n)) : e && typeof e == "object" ? Object.fromEntries(
2857
+ return typeof e == "string" ? Xo(e, t, n) : Array.isArray(e) ? e.map((r) => Me(r, t, n)) : e && typeof e == "object" ? Object.fromEntries(
2840
2858
  Object.entries(e).map(([r, o]) => [
2841
2859
  r,
2842
2860
  Me(o, t, {
@@ -2846,21 +2864,21 @@ function Me(e, t, n = {}) {
2846
2864
  ])
2847
2865
  ) : e;
2848
2866
  }
2849
- function zo(e, t, n) {
2867
+ function Xo(e, t, n) {
2850
2868
  const r = n.onMissing === "throw";
2851
2869
  if (r) {
2852
- const i = e.match(Vo);
2870
+ const i = e.match(Yo);
2853
2871
  if (i)
2854
2872
  throw new un(
2855
2873
  `"${i[0]}" in ${n.where ?? "een waarde"} is de oude schrijfwijze; gebruik {{ ${i[0].slice(1)} }}.`
2856
2874
  );
2857
2875
  }
2858
- const o = e.match(Go);
2876
+ const o = e.match(Vo);
2859
2877
  if (o) {
2860
2878
  const i = Et(t, o[1], e, n);
2861
2879
  return i === void 0 && !r ? "" : i;
2862
2880
  }
2863
- return e.replace(Wo, (i, s) => {
2881
+ return e.replace(zo, (i, s) => {
2864
2882
  const a = Et(t, s, i, n);
2865
2883
  return a == null ? "" : typeof a == "object" ? JSON.stringify(a) : String(a);
2866
2884
  });
@@ -2873,9 +2891,9 @@ function Et(e, t, n, r) {
2873
2891
  `onbekende verwijzing ${n} in ${r.where ?? "een waarde"}: "${o}" bestaat niet. Beschikbaar: ${i.length ? i.join(", ") : "(nog niets)"}`
2874
2892
  );
2875
2893
  }
2876
- return Xo(e, t);
2894
+ return qo(e, t);
2877
2895
  }
2878
- function Xo(e, t) {
2896
+ function qo(e, t) {
2879
2897
  let n = e;
2880
2898
  for (const r of t.split(".")) {
2881
2899
  if (n == null || typeof n != "object") return;
@@ -2883,11 +2901,11 @@ function Xo(e, t) {
2883
2901
  }
2884
2902
  return n;
2885
2903
  }
2886
- const su = /* @__PURE__ */ new Set(["filled", "empty"]);
2887
- function au() {
2904
+ const hu = /* @__PURE__ */ new Set(["filled", "empty"]);
2905
+ function gu() {
2888
2906
  return { kind: "rule", op: "==", varPath: "", value: "" };
2889
2907
  }
2890
- const Yo = /* @__PURE__ */ new Set(["==", "!=", ">", "<", ">=", "<="]);
2908
+ const Qo = /* @__PURE__ */ new Set(["==", "!=", ">", "<", ">=", "<="]);
2891
2909
  function me(e) {
2892
2910
  return !!e && typeof e == "object" && "var" in e && typeof e.var == "string";
2893
2911
  }
@@ -2895,7 +2913,7 @@ function St(e) {
2895
2913
  const t = typeof e;
2896
2914
  return t === "string" || t === "number" || t === "boolean";
2897
2915
  }
2898
- function qo(e) {
2916
+ function Jo(e) {
2899
2917
  if (e === !0 || e == null) return { kind: "group", op: "and", children: [] };
2900
2918
  if (e === !1) return null;
2901
2919
  const t = Oe(e);
@@ -2929,7 +2947,7 @@ function Oe(e) {
2929
2947
  const [o, i] = r;
2930
2948
  return !me(i) || !St(o) ? null : { kind: "rule", op: "in", varPath: i.var, value: o };
2931
2949
  }
2932
- if (Yo.has(n)) {
2950
+ if (Qo.has(n)) {
2933
2951
  if (!Array.isArray(r) || r.length !== 2) return null;
2934
2952
  const [o, i] = r;
2935
2953
  return !me(o) || !St(i) ? null : { kind: "rule", op: n, varPath: o.var, value: i };
@@ -2939,8 +2957,8 @@ function Oe(e) {
2939
2957
  function he(e) {
2940
2958
  return e.kind === "group" ? e.children.length === 0 ? !0 : e.children.length === 1 ? he(e.children[0]) : { [e.op]: e.children.map(he) } : e.kind === "not" ? { "!": he(e.child) } : e.op === "filled" ? { "!!": [{ var: e.varPath }] } : e.op === "empty" ? { "!": [{ var: e.varPath }] } : e.op === "in" ? { in: [e.value, { var: e.varPath }] } : { [e.op]: [{ var: e.varPath }, e.value] };
2941
2959
  }
2942
- function cu(e) {
2943
- const t = qo(e);
2960
+ function yu(e) {
2961
+ const t = Jo(e);
2944
2962
  return t && Ce(t) || null;
2945
2963
  }
2946
2964
  function Ce(e) {
@@ -2962,7 +2980,7 @@ const ge = [
2962
2980
  { min: 0, max: 7 }
2963
2981
  // day of week
2964
2982
  ];
2965
- function Qo(e, t, n) {
2983
+ function Zo(e, t, n) {
2966
2984
  const r = /* @__PURE__ */ new Set();
2967
2985
  for (const o of e.split(",")) {
2968
2986
  const [i, s] = o.split("/"), a = s === void 0 ? 1 : Number(s);
@@ -2983,7 +3001,7 @@ function dn(e) {
2983
3001
  for (let l = 0; l < ge.length; l++) {
2984
3002
  const c = ge[l], d = t[l];
2985
3003
  if (!c || d === void 0) return null;
2986
- const u = Qo(d, c.min, c.max);
3004
+ const u = Zo(d, c.min, c.max);
2987
3005
  if (!u) return null;
2988
3006
  n.push(u);
2989
3007
  }
@@ -2998,17 +3016,17 @@ function dn(e) {
2998
3016
  anyDayOfWeek: t[4] === "*"
2999
3017
  };
3000
3018
  }
3001
- function lu(e) {
3019
+ function bu(e) {
3002
3020
  return dn(e) !== null;
3003
3021
  }
3004
- function Jo(e, t) {
3022
+ function ei(e, t) {
3005
3023
  const n = dn(e);
3006
3024
  if (!n || !n.minute.has(t.getUTCMinutes()) || !n.hour.has(t.getUTCHours()) || !n.month.has(t.getUTCMonth() + 1)) return !1;
3007
3025
  const r = n.dayOfMonth.has(t.getUTCDate()), o = n.dayOfWeek.has(t.getUTCDay());
3008
3026
  return n.anyDayOfMonth && n.anyDayOfWeek ? !0 : n.anyDayOfMonth ? o : n.anyDayOfWeek ? r : r || o;
3009
3027
  }
3010
- const Zo = "@schedule", Tt = 3;
3011
- function ei(e, t, n) {
3028
+ const ti = "@schedule", Tt = 3;
3029
+ function ni(e, t, n) {
3012
3030
  const r = [], o = e.depth ?? 0;
3013
3031
  if (o >= Tt)
3014
3032
  return {
@@ -3025,7 +3043,7 @@ function ei(e, t, n) {
3025
3043
  continue;
3026
3044
  }
3027
3045
  if (a.trigger.kind === "schedule") {
3028
- if (e.name !== Zo) {
3046
+ if (e.name !== ti) {
3029
3047
  r.push({ ruleId: a.id, reason: "luistert op de klok" });
3030
3048
  continue;
3031
3049
  }
@@ -3034,7 +3052,7 @@ function ei(e, t, n) {
3034
3052
  r.push({ ruleId: a.id, reason: "tik zonder tijdstip" });
3035
3053
  continue;
3036
3054
  }
3037
- if (!Jo(a.trigger.cron, new Date(l))) {
3055
+ if (!ei(a.trigger.cron, new Date(l))) {
3038
3056
  r.push({ ruleId: a.id, reason: `niet aan de beurt (${a.trigger.cron})` });
3039
3057
  continue;
3040
3058
  }
@@ -3057,11 +3075,11 @@ function ei(e, t, n) {
3057
3075
  }
3058
3076
  return { matched: s, skipped: r };
3059
3077
  }
3060
- function uu(e, t) {
3078
+ function _u(e, t) {
3061
3079
  return { causedByRule: t, depth: (e.depth ?? 0) + 1 };
3062
3080
  }
3063
- function du(e, t) {
3064
- const { event: n, rules: r } = e.input, { matched: o, skipped: i } = ei(n, r, t), s = o.flatMap((c) => c.rule.then.map((d) => d.action)), a = e.expected?.actions ?? [];
3081
+ function Au(e, t) {
3082
+ const { event: n, rules: r } = e.input, { matched: o, skipped: i } = ni(n, r, t), s = o.flatMap((c) => c.rule.then.map((d) => d.action)), a = e.expected?.actions ?? [];
3065
3083
  if (s.length === a.length && s.every((c, d) => c === a[d]))
3066
3084
  return { caseId: e.id, ok: !0 };
3067
3085
  const l = i.map((c) => `${c.ruleId}: ${c.reason}`).join(" · ");
@@ -3072,49 +3090,49 @@ function du(e, t) {
3072
3090
  note: a.length ? `verwacht [${a.join(", ")}], kreeg [${s.join(", ")}]${l ? ` — ${l}` : ""}` : `mocht niet vuren, maar deed [${s.join(", ")}]`
3073
3091
  };
3074
3092
  }
3075
- function ti(e, t) {
3093
+ function ri(e, t) {
3076
3094
  return e.wrote && t in e.wrote ? e.wrote[t] : t in e.params ? e.params[t] : "";
3077
3095
  }
3078
- function ni(e, t) {
3096
+ function oi(e, t) {
3079
3097
  return e.fields.filter(
3080
- (n) => t?.[n] !== void 0 && t[n] !== ti(e, n)
3098
+ (n) => t?.[n] !== void 0 && t[n] !== ri(e, n)
3081
3099
  );
3082
3100
  }
3083
- function fu(e, t, n) {
3084
- return n ? "undone" : !t || !e.length ? "unknown" : e.some((r) => ni(r, t).length) ? "corrected" : "kept";
3101
+ function Eu(e, t, n) {
3102
+ return n ? "undone" : !t || !e.length ? "unknown" : e.some((r) => oi(r, t).length) ? "corrected" : "kept";
3085
3103
  }
3086
- function pu(e) {
3104
+ function Su(e) {
3087
3105
  return e === "string[]" ? ["in"] : e === "boolean" ? ["==", "!="] : e === "number" || e === "date" ? ["==", "!=", ">", "<", ">=", "<="] : ["==", "!=", "in", "filled", "empty"];
3088
3106
  }
3089
- function mu(e) {
3107
+ function Tu(e) {
3090
3108
  return `subject.${e.path}`;
3091
3109
  }
3092
- function hu(e, t) {
3110
+ function Iu(e, t) {
3093
3111
  return e.events.find((n) => n.name === t);
3094
3112
  }
3095
- function gu(e, t) {
3096
- return e.filter((n) => Co(t, n.path) === void 0).map((n) => n.path);
3113
+ function vu(e, t) {
3114
+ return e.filter((n) => xo(t, n.path) === void 0).map((n) => n.path);
3097
3115
  }
3098
- const Ne = 6e4, ri = 36e5, Y = 864e5, fn = 800;
3116
+ const Ne = 6e4, ii = 36e5, X = 864e5, fn = 800;
3099
3117
  function It(e, t) {
3100
3118
  const n = Date.UTC(e, t + 1, 0);
3101
- return n - new Date(n).getUTCDay() * Y + ri;
3119
+ return n - new Date(n).getUTCDay() * X + ii;
3102
3120
  }
3103
- function oi(e) {
3121
+ function si(e) {
3104
3122
  const t = new Date(e).getUTCFullYear();
3105
3123
  return e >= It(t, 2) && e < It(t, 9);
3106
3124
  }
3107
3125
  function pn(e, t) {
3108
- const n = t.dst === "eu" && oi(e) ? 60 : 0;
3126
+ const n = t.dst === "eu" && si(e) ? 60 : 0;
3109
3127
  return (t.utcOffsetMinutes + n) * Ne;
3110
3128
  }
3111
- function ii(e) {
3129
+ function ai(e) {
3112
3130
  return (e + 3) % 7 + 1;
3113
3131
  }
3114
3132
  function mn(e, t) {
3115
- const n = pn(e, t), r = e + n, o = Math.floor(r / Y);
3116
- if (!t.days.includes(ii(o))) return null;
3117
- const i = o * Y;
3133
+ const n = pn(e, t), r = e + n, o = Math.floor(r / X);
3134
+ if (!t.days.includes(ai(o))) return null;
3135
+ const i = o * X;
3118
3136
  return {
3119
3137
  open: i + t.fromMinutes * Ne - n,
3120
3138
  close: i + t.toMinutes * Ne - n
@@ -3122,7 +3140,7 @@ function mn(e, t) {
3122
3140
  }
3123
3141
  function hn(e, t) {
3124
3142
  const n = pn(e, t), r = e + n;
3125
- return (Math.floor(r / Y) + 1) * Y - n;
3143
+ return (Math.floor(r / X) + 1) * X - n;
3126
3144
  }
3127
3145
  function xe(e, t, n) {
3128
3146
  if (t <= e) return 0;
@@ -3155,61 +3173,61 @@ function He(e, t, n) {
3155
3173
  }
3156
3174
  return e + t;
3157
3175
  }
3158
- function yu(e) {
3176
+ function ku(e) {
3159
3177
  const t = /^([01]\d|2[0-3]):([0-5]\d)$/.exec(e);
3160
3178
  return t ? Number(t[1]) * 60 + Number(t[2]) : null;
3161
3179
  }
3162
- const $e = 1, De = 2, Re = 4;
3163
- function bu(e) {
3164
- return e === "snoozed" ? $e : De;
3180
+ const De = 1, Re = 2, $e = 4;
3181
+ function wu(e) {
3182
+ return e === "snoozed" ? De : Re;
3165
3183
  }
3166
3184
  function Ge(e) {
3167
3185
  const t = e.calendar;
3168
3186
  return t && Array.isArray(t.days) ? t : null;
3169
3187
  }
3170
- const Au = [
3188
+ const Mu = [
3171
3189
  "speed_of_answer",
3172
3190
  "first_response",
3173
3191
  "next_response",
3174
3192
  "resolution",
3175
3193
  "close"
3176
- ], _u = ["snoozed", "waiting_for_customer"], si = 6e4, gn = ["speed_of_answer", "first_response", "next_response"], ai = [...gn, "resolution", "close"];
3194
+ ], Ou = ["snoozed", "waiting_for_customer"], ci = 6e4, gn = ["speed_of_answer", "first_response", "next_response"], li = [...gn, "resolution", "close"];
3177
3195
  function q(e) {
3178
3196
  return e.state === "running" || e.state === "paused";
3179
3197
  }
3180
- function ci(e, t) {
3198
+ function ui(e, t) {
3181
3199
  return q(e) ? { state: (e.state === "paused" ? e.remainingMs > 0 : t <= e.dueAt) ? "hit" : "missed", settledAt: Math.max(t, e.startedAt) } : null;
3182
3200
  }
3183
3201
  function vt(e) {
3184
3202
  return q(e) ? { state: "void" } : null;
3185
3203
  }
3186
- function li(e, t, n, r) {
3204
+ function di(e, t, n, r) {
3187
3205
  if (!q(e) || (e.pauseBits & t) !== 0) return null;
3188
3206
  const o = e.pauseBits | t;
3189
3207
  return e.state === "paused" ? { pauseBits: o } : { pauseBits: o, state: "paused", remainingMs: xe(n, e.dueAt, r) };
3190
3208
  }
3191
- function ui(e, t, n, r) {
3209
+ function fi(e, t, n, r) {
3192
3210
  if (!q(e) || (e.pauseBits & t) === 0) return null;
3193
3211
  const o = e.pauseBits & ~t;
3194
3212
  return o !== 0 ? { pauseBits: o } : { pauseBits: o, state: "running", dueAt: He(n, e.remainingMs, r) };
3195
3213
  }
3196
- function Eu({ event: e, at: t, now: n, clocks: r, profile: o }) {
3214
+ function Cu({ event: e, at: t, now: n, clocks: r, profile: o }) {
3197
3215
  const i = Ge(o), s = Math.min(t, n), a = r.map((g) => ({ ...g })), l = [], c = (g, h) => {
3198
3216
  h && (l.push({ op: "patch", clockId: g.id, patch: h }), Object.assign(g, h));
3199
3217
  }, d = (g) => {
3200
3218
  for (const h of a)
3201
- h.metric === g && c(h, ci(h, s));
3219
+ h.metric === g && c(h, ui(h, s));
3202
3220
  }, u = (g) => {
3203
3221
  for (const h of a)
3204
3222
  g.includes(h.metric) && c(h, vt(h));
3205
3223
  }, f = (g) => {
3206
- for (const h of a) c(h, li(h, g, s, i));
3224
+ for (const h of a) c(h, di(h, g, s, i));
3207
3225
  }, p = (g) => {
3208
- for (const h of a) c(h, ui(h, g, s, i));
3226
+ for (const h of a) c(h, fi(h, g, s, i));
3209
3227
  }, y = (g) => a.reduce((h, E) => E.metric === g ? Math.max(h, E.attempt) : h, 0) + 1, m = (g) => a.some((h) => h.metric === g && q(h)), S = (g, h) => {
3210
3228
  const E = o.targets.find((C) => C.metric === g);
3211
3229
  if (!E) return;
3212
- const x = E.minutes * si;
3230
+ const x = E.minutes * ci;
3213
3231
  l.push({
3214
3232
  op: "start",
3215
3233
  metric: g,
@@ -3235,11 +3253,11 @@ function Eu({ event: e, at: t, now: n, clocks: r, profile: o }) {
3235
3253
  d("speed_of_answer");
3236
3254
  break;
3237
3255
  case "outbound": {
3238
- d("first_response"), d("next_response"), o.pauseOn.includes("waiting_for_customer") && f(De);
3256
+ d("first_response"), d("next_response"), o.pauseOn.includes("waiting_for_customer") && f(Re);
3239
3257
  break;
3240
3258
  }
3241
3259
  case "inbound": {
3242
- p(De), !m("first_response") && !m("next_response") && S("next_response", s);
3260
+ p(Re), !m("first_response") && !m("next_response") && S("next_response", s);
3243
3261
  break;
3244
3262
  }
3245
3263
  case "resolved":
@@ -3252,48 +3270,48 @@ function Eu({ event: e, at: t, now: n, clocks: r, profile: o }) {
3252
3270
  m("resolution") || S("resolution", s), m("close") || S("close", s);
3253
3271
  break;
3254
3272
  case "snoozed":
3255
- o.pauseOn.includes("snoozed") && f($e);
3273
+ o.pauseOn.includes("snoozed") && f(De);
3256
3274
  break;
3257
3275
  case "unsnoozed":
3258
- p($e);
3276
+ p(De);
3259
3277
  break;
3260
3278
  // Not gated on `profile.pauseOn`, unlike the two above: this is a person deciding about
3261
3279
  // one conversation, not a profile setting. `resumeAll` only lifts the bit it is given, so
3262
3280
  // an `inbound` arriving meanwhile clears `waiting_for_customer` and the clock stays held.
3263
3281
  case "hold":
3264
- f(Re);
3282
+ f($e);
3265
3283
  break;
3266
3284
  case "unhold":
3267
- p(Re);
3285
+ p($e);
3268
3286
  break;
3269
3287
  case "discarded":
3270
- u(ai);
3288
+ u(li);
3271
3289
  break;
3272
3290
  }
3273
3291
  return l;
3274
3292
  }
3275
- function di(e) {
3293
+ function pi(e) {
3276
3294
  return e.state === "running" || e.state === "paused";
3277
3295
  }
3278
- function Su(e) {
3279
- return (e.pauseBits & Re) !== 0;
3296
+ function Nu(e) {
3297
+ return (e.pauseBits & $e) !== 0;
3280
3298
  }
3281
3299
  function Le(e, t) {
3282
3300
  const n = Ge(e);
3283
3301
  return e.state === "paused" ? e.remainingMs : t >= e.dueAt ? -xe(e.dueAt, t, n) : xe(t, e.dueAt, n);
3284
3302
  }
3285
- function Tu(e, t) {
3303
+ function xu(e, t) {
3286
3304
  return e.state === "paused" ? He(t, e.remainingMs, Ge(e)) : e.dueAt;
3287
3305
  }
3288
- function Iu(e, t) {
3289
- const n = e.filter(di);
3306
+ function Du(e, t) {
3307
+ const n = e.filter(pi);
3290
3308
  if (!n.length) return;
3291
3309
  const r = n.filter((i) => i.state === "running");
3292
3310
  return (r.length ? r : n).reduce(
3293
3311
  (i, s) => Le(s, t) < Le(i, t) ? s : i
3294
3312
  );
3295
3313
  }
3296
- function vu(e, t) {
3314
+ function Ru(e, t) {
3297
3315
  if (e.state === "missed") return "breached";
3298
3316
  if (e.state === "hit") return "met";
3299
3317
  if (e.state === "paused") return "paused";
@@ -3301,41 +3319,41 @@ function vu(e, t) {
3301
3319
  const n = Le(e, t);
3302
3320
  return n <= 0 ? "breached" : n <= e.targetMs / 5 ? "urgent" : "running";
3303
3321
  }
3304
- function ku(e) {
3322
+ function $u(e) {
3305
3323
  const t = Math.floor(Math.abs(e) / 1e3), n = Math.floor(t / 86400), r = Math.floor(t % 86400 / 3600), o = Math.floor(t % 3600 / 60);
3306
3324
  return n ? r ? `${n}d ${r}u` : `${n}d` : r ? o ? `${r}u ${o}m` : `${r}u` : o ? `${o}m` : `${t % 60}s`;
3307
3325
  }
3308
- const fi = "strategy_item";
3326
+ const mi = "strategy_item";
3309
3327
  function yn(e) {
3310
- return `${fi}:${e}`;
3328
+ return `${mi}:${e}`;
3311
3329
  }
3312
- function wu(e, t = 25) {
3330
+ function Lu(e, t = 25) {
3313
3331
  const n = /* @__PURE__ */ new Set([yn(e.id)]);
3314
3332
  for (const r of e.ancestorKeys ?? []) n.add(r);
3315
3333
  return Array.from(n).slice(0, t);
3316
3334
  }
3317
- function Mu(e) {
3335
+ function Pu(e) {
3318
3336
  return e ? [...e.ancestorKeys ?? [], yn(e.id)] : [];
3319
3337
  }
3320
3338
  const ie = [
3321
3339
  { key: "area", label: "level_area", order: 10, measurable: !1, icon: "compass" },
3322
3340
  { key: "objective", label: "level_objective", order: 20, measurable: !0, icon: "target" },
3323
3341
  { key: "key_result", label: "level_key_result", order: 30, measurable: !0, icon: "gauge" }
3324
- ], pi = 999, mi = 7;
3325
- function hi(e, t = ie) {
3342
+ ], hi = 999, gi = 7;
3343
+ function yi(e, t = ie) {
3326
3344
  return t.find((n) => n.key === e);
3327
3345
  }
3328
3346
  function Pe(e, t = ie) {
3329
- return hi(e, t)?.order ?? pi;
3347
+ return yi(e, t)?.order ?? hi;
3330
3348
  }
3331
- function Ou(e, t, n = ie) {
3349
+ function Ku(e, t, n = ie) {
3332
3350
  return Pe(t, n) <= Pe(e, n);
3333
3351
  }
3334
- function Cu(e, t = ie) {
3352
+ function Uu(e, t = ie) {
3335
3353
  const n = Pe(e, t);
3336
3354
  return t.filter((o) => o.order > n).sort((o, i) => o.order - i.order)[0]?.key ?? e;
3337
3355
  }
3338
- function Nu(e) {
3356
+ function Fu(e) {
3339
3357
  const t = e.trim().toLowerCase();
3340
3358
  return t ? t.includes("key result") || t.includes("keyresult") || t === "kr" ? "key_result" : t.includes("objective") || t.includes("goal") || t.includes("doel") ? "objective" : t.includes("focus") || t.includes("area") || t.includes("theme") ? "area" : null : null;
3341
3359
  }
@@ -3348,74 +3366,74 @@ const Ke = {
3348
3366
  achieved: "closed",
3349
3367
  missed: "closed"
3350
3368
  };
3351
- function xu(e) {
3369
+ function ju(e) {
3352
3370
  return Ke[e] ?? "open";
3353
3371
  }
3354
- function $u(e) {
3372
+ function Bu(e) {
3355
3373
  return Object.keys(Ke).filter(
3356
3374
  (t) => e.includes(Ke[t])
3357
3375
  );
3358
3376
  }
3359
- const gi = 864e5, se = (e) => e <= 0 ? 0 : e > 1 ? 1 : e;
3360
- function Du(e, t) {
3377
+ const bi = 864e5, se = (e) => e <= 0 ? 0 : e > 1 ? 1 : e;
3378
+ function Hu(e, t) {
3361
3379
  const { direction: n } = e, r = e.startValue ?? 0, o = e.targetValue ?? 0;
3362
3380
  if (!Number.isFinite(t)) return 0;
3363
3381
  const i = n === "down" ? t <= o : t >= o, s = o - r;
3364
3382
  return (n === "down" ? s < 0 : s > 0) ? se((t - r) / s) : i ? 1 : 0;
3365
3383
  }
3366
- function Ru(e, t) {
3384
+ function Gu(e, t) {
3367
3385
  const { startDate: n, targetDate: r } = e;
3368
3386
  if (!(typeof n != "number" || typeof r != "number") && !(r <= n))
3369
3387
  return se((t - n) / (r - n));
3370
3388
  }
3371
- const yi = 0.1, bi = 0.25;
3372
- function Lu(e, t) {
3389
+ const _i = 0.1, Ai = 0.25;
3390
+ function Wu(e, t) {
3373
3391
  if (typeof e != "number" || typeof t != "number") return;
3374
3392
  if (e >= 1) return "achieved";
3375
3393
  const n = t - e;
3376
- return n >= bi ? "off_track" : n >= yi ? "at_risk" : "on_track";
3394
+ return n >= Ai ? "off_track" : n >= _i ? "at_risk" : "on_track";
3377
3395
  }
3378
- function Pu(e, t) {
3396
+ function Vu(e, t) {
3379
3397
  if (t)
3380
3398
  return se(e / t);
3381
3399
  }
3382
- function Ku(e) {
3400
+ function zu(e) {
3383
3401
  const t = e.map((n) => n.progress?.ratio).filter((n) => typeof n == "number" && Number.isFinite(n));
3384
3402
  if (t.length)
3385
3403
  return se(t.reduce((n, r) => n + r, 0) / t.length);
3386
3404
  }
3387
- function Uu(e, t) {
3405
+ function Yu(e, t) {
3388
3406
  const n = e.lastCheckInAt ?? e.createdAt;
3389
3407
  if (typeof n != "number") return 0;
3390
- const r = (e.checkInEveryDays ?? mi) * gi, o = t - n - r;
3408
+ const r = (e.checkInEveryDays ?? gi) * bi, o = t - n - r;
3391
3409
  return o > 0 ? o : 0;
3392
3410
  }
3393
- function Fu(e) {
3411
+ function Xu(e) {
3394
3412
  return e.targetDate ?? Number.MAX_SAFE_INTEGER;
3395
3413
  }
3396
- function ju(e, t) {
3414
+ function qu(e, t) {
3397
3415
  const n = e.accumulatedSeconds || 0;
3398
3416
  return e.runningSince ? n + Math.max(0, Math.floor((t - e.runningSince) / 1e3)) : n;
3399
3417
  }
3400
- function Bu(e, t) {
3418
+ function Qu(e, t) {
3401
3419
  const n = Math.max(1, Math.ceil(Math.max(0, e) / 60));
3402
3420
  if (!t || t === "exact") return n * 60;
3403
3421
  const r = Number(t);
3404
3422
  return !Number.isFinite(r) || r <= 0 ? n * 60 : Math.ceil(n / r) * r * 60;
3405
3423
  }
3406
- function Hu(e) {
3424
+ function Ju(e) {
3407
3425
  const t = Math.max(0, Math.round(e / 60));
3408
3426
  return `${Math.floor(t / 60)}:${String(t % 60).padStart(2, "0")}`;
3409
3427
  }
3410
- function Gu(e) {
3428
+ function Zu(e) {
3411
3429
  const t = Math.max(0, Math.floor(e)), n = (i) => String(i).padStart(2, "0"), r = Math.floor(t / 60) % 60, o = Math.floor(t / 3600);
3412
3430
  return o > 0 ? `${o}:${n(r)}:${n(t % 60)}` : `${n(r)}:${n(t % 60)}`;
3413
3431
  }
3414
- function Ai(e) {
3432
+ function Ei(e) {
3415
3433
  return (e || "").normalize("NFD").replace(/[\u0300-\u036f]/g, "").toLowerCase().replace(/[^a-z0-9]+/g, "-").slice(0, 48).replace(/^-+|-+$/g, "");
3416
3434
  }
3417
- function Wu(e, t) {
3418
- const n = Ai(e) || "werksoort", r = new Set(t);
3435
+ function ed(e, t) {
3436
+ const n = Ei(e) || "werksoort", r = new Set(t);
3419
3437
  if (!r.has(n)) return n;
3420
3438
  for (let o = 2; o < 500; o++) {
3421
3439
  const i = `${n}-${o}`;
@@ -3423,29 +3441,29 @@ function Wu(e, t) {
3423
3441
  }
3424
3442
  return `${n}-${r.size + 1}`;
3425
3443
  }
3426
- function Vu(e, t) {
3444
+ function td(e, t) {
3427
3445
  const n = e.ownerScope;
3428
3446
  return !n || n.kind === "org" ? !0 : t.includes(n.teamId);
3429
3447
  }
3430
- function zu(e) {
3431
- return e.filter((t) => !t.archived).sort(_i);
3448
+ function nd(e) {
3449
+ return e.filter((t) => !t.archived).sort(Si);
3432
3450
  }
3433
- function _i(e, t) {
3451
+ function Si(e, t) {
3434
3452
  const n = (e.order ?? 0) - (t.order ?? 0);
3435
3453
  return n !== 0 ? n : (e.label || "").localeCompare(t.label || "");
3436
3454
  }
3437
- const Ei = 20, Si = 20, ye = 300;
3455
+ const Ti = 20, Ii = 20, ye = 300;
3438
3456
  function K(e) {
3439
3457
  return e.toLowerCase().replace(/[^\p{L}\p{N}\s]/gu, " ").replace(/\s+/g, " ").trim();
3440
3458
  }
3441
- function Ti(e) {
3459
+ function vi(e) {
3442
3460
  const t = e.replace(/\s+/g, " ").trim();
3443
3461
  if (t.length <= ye) return t;
3444
3462
  const n = t.slice(0, ye), r = Math.max(n.lastIndexOf(". "), n.lastIndexOf("! "), n.lastIndexOf("? "));
3445
3463
  return r > ye * 0.6 ? n.slice(0, r + 1) : `${n.trimEnd()}…`;
3446
3464
  }
3447
- function Xu(e, t) {
3448
- const n = Ti(t.text), r = K(n);
3465
+ function rd(e, t) {
3466
+ const n = vi(t.text), r = K(n);
3449
3467
  if (!r || (e.examples ?? []).some((s) => K(s) === r)) return null;
3450
3468
  const o = e.exampleCandidates ?? [], i = o.findIndex((s) => K(s.text) === r);
3451
3469
  if (i >= 0) {
@@ -3453,27 +3471,27 @@ function Xu(e, t) {
3453
3471
  const s = [...o];
3454
3472
  return s[i] = { ...s[i], corrected: !0, addedAt: t.addedAt }, kt(s);
3455
3473
  }
3456
- return kt([{ ...t, text: n }, ...o]).slice(0, Si);
3474
+ return kt([{ ...t, text: n }, ...o]).slice(0, Ii);
3457
3475
  }
3458
3476
  function kt(e) {
3459
3477
  return [...e].sort(
3460
3478
  (t, n) => Number(n.corrected) - Number(t.corrected) || n.addedAt - t.addedAt
3461
3479
  );
3462
3480
  }
3463
- function Yu(e, t) {
3481
+ function od(e, t) {
3464
3482
  const n = K(t), r = (e.examples ?? []).filter((i) => i.trim());
3465
- return { examples: r.some((i) => K(i) === n) ? r : [...r, t].slice(-Ei), exampleCandidates: Ii(e, t) };
3483
+ return { examples: r.some((i) => K(i) === n) ? r : [...r, t].slice(-Ti), exampleCandidates: ki(e, t) };
3466
3484
  }
3467
- function Ii(e, t) {
3485
+ function ki(e, t) {
3468
3486
  const n = K(t);
3469
3487
  return (e.exampleCandidates ?? []).filter((r) => K(r.text) !== n);
3470
3488
  }
3471
- function vi(e, t) {
3489
+ function wi(e, t) {
3472
3490
  const n = e.ownerScope;
3473
3491
  return n ? n.kind === "org" ? !0 : n.kind === "team" ? !!t && n.teamId === t : !1 : !1;
3474
3492
  }
3475
- function qu(e, t) {
3476
- return e.filter((n) => vi(n, t));
3493
+ function id(e, t) {
3494
+ return e.filter((n) => wi(n, t));
3477
3495
  }
3478
3496
  const We = [
3479
3497
  {
@@ -3553,7 +3571,7 @@ const We = [
3553
3571
  "invoice",
3554
3572
  "credit_note"
3555
3573
  ];
3556
- function Qu() {
3574
+ function sd() {
3557
3575
  const e = /* @__PURE__ */ new Map();
3558
3576
  for (const t of We)
3559
3577
  bn.includes(t.key) && (e.has(t.path) || e.set(t.path, t));
@@ -3573,7 +3591,7 @@ function O(e) {
3573
3591
  convertsTo: []
3574
3592
  };
3575
3593
  }
3576
- const Ju = {
3594
+ const ad = {
3577
3595
  draft: "Concept",
3578
3596
  sent: "Verstuurd",
3579
3597
  accepted: "Geaccepteerd",
@@ -3588,16 +3606,16 @@ const Ju = {
3588
3606
  cancelled: "Geannuleerd",
3589
3607
  superseded: "Vervangen"
3590
3608
  };
3591
- function ki(e, t) {
3609
+ function Mi(e, t) {
3592
3610
  return O(e).transitions[t] ?? [];
3593
3611
  }
3594
- function Zu(e, t, n) {
3595
- return ki(e, t).includes(n);
3612
+ function cd(e, t, n) {
3613
+ return Mi(e, t).includes(n);
3596
3614
  }
3597
- function wi(e) {
3615
+ function Oi(e) {
3598
3616
  return e.issuedAt != null;
3599
3617
  }
3600
- const ed = [
3618
+ const ld = [
3601
3619
  "status",
3602
3620
  "fileRef",
3603
3621
  "number",
@@ -3605,7 +3623,7 @@ const ed = [
3605
3623
  "postedAt",
3606
3624
  "dunning",
3607
3625
  "updatedAt"
3608
- ], td = [
3626
+ ], ud = [
3609
3627
  "companyId",
3610
3628
  "contactId",
3611
3629
  "dealItemId",
@@ -3621,7 +3639,7 @@ const ed = [
3621
3639
  "periodTo",
3622
3640
  "paymentTerm",
3623
3641
  "lines"
3624
- ], nd = [
3642
+ ], dd = [
3625
3643
  "contactId",
3626
3644
  "dealItemId",
3627
3645
  "title",
@@ -3634,12 +3652,12 @@ const ed = [
3634
3652
  "periodFrom",
3635
3653
  "periodTo"
3636
3654
  ];
3637
- function rd(e, t) {
3655
+ function fd(e, t) {
3638
3656
  if (!bn.includes(t) || !O(e.kindKey).convertsTo.includes(t)) return !1;
3639
3657
  const n = O(t);
3640
- return !n.credits || n.credits === e.kindKey && wi(e);
3658
+ return !n.credits || n.credits === e.kindKey && Oi(e);
3641
3659
  }
3642
- function Mi(e, t) {
3660
+ function Ci(e, t) {
3643
3661
  const n = O(t).signFlip !== O(e.kindKey).signFlip, r = e.lines.map((o) => ({
3644
3662
  ...o,
3645
3663
  quantity: n ? -o.quantity : o.quantity,
@@ -3678,9 +3696,9 @@ function Mi(e, t) {
3678
3696
  source: e.source
3679
3697
  };
3680
3698
  }
3681
- function od(e) {
3699
+ function pd(e) {
3682
3700
  return {
3683
- ...Mi(e, e.kindKey),
3701
+ ...Ci(e, e.kindKey),
3684
3702
  sourceTransactionId: e.sourceTransactionId,
3685
3703
  previousVersionId: e.id,
3686
3704
  version: e.version + 1,
@@ -3688,7 +3706,7 @@ function od(e) {
3688
3706
  totals: e.totals
3689
3707
  };
3690
3708
  }
3691
- function id(e, t = {}) {
3709
+ function md(e, t = {}) {
3692
3710
  const n = O(e.kindKey), r = e.totals ?? { netCents: 0, taxCents: 0, grossCents: 0 };
3693
3711
  return {
3694
3712
  customer: {
@@ -3697,7 +3715,7 @@ function id(e, t = {}) {
3697
3715
  // One token per line of the address, plus `street` on its own for a template that wants
3698
3716
  // the house number elsewhere. Empty stays empty: `fillText` reports it as a hole, and a
3699
3717
  // recipient block missing its street is exactly what the issue gate has to refuse.
3700
- address: Ni(t.companyAddress),
3718
+ address: Di(t.companyAddress),
3701
3719
  street: t.companyAddress?.street ?? "",
3702
3720
  house_number: t.companyAddress?.houseNumber ?? "",
3703
3721
  postal_code: t.companyAddress?.postalCode ?? "",
@@ -3729,13 +3747,13 @@ function id(e, t = {}) {
3729
3747
  terms: e.termsText ?? ""
3730
3748
  },
3731
3749
  totals: {
3732
- net: R(r.netCents),
3733
- tax: R(r.taxCents),
3734
- gross: R(r.grossCents)
3750
+ net: $(r.netCents),
3751
+ tax: $(r.taxCents),
3752
+ gross: $(r.grossCents)
3735
3753
  }
3736
3754
  };
3737
3755
  }
3738
- function sd(e, t = [], n = Oi) {
3756
+ function hd(e, t = [], n = Ni) {
3739
3757
  const r = e.totals ?? { netCents: 0, grossCents: 0, byRate: [] }, o = (a) => t.find((l) => l.key === a)?.percent ?? 0, i = {
3740
3758
  block_id: "lines",
3741
3759
  type: "table",
@@ -3750,27 +3768,27 @@ function sd(e, t = [], n = Oi) {
3750
3768
  // A text line spans as a heading: empty money cells would read as "free".
3751
3769
  [a.name, "", "", ""]
3752
3770
  ) : [
3753
- Ci(a.name, a.description, a.optional, n.optional),
3754
- xi(a.quantity),
3755
- R(a.unitPriceCents),
3756
- R(a.netCents)
3771
+ xi(a.name, a.description, a.optional, n.optional),
3772
+ Ri(a.quantity),
3773
+ $(a.unitPriceCents),
3774
+ $(a.netCents)
3757
3775
  ]
3758
3776
  )
3759
3777
  }, s = {
3760
3778
  block_id: "totals",
3761
3779
  type: "totals",
3762
3780
  rows: [
3763
- { label: n.net, amount: R(r.netCents) },
3764
- { label: n.gross, amount: R(r.grossCents), emphasis: !0 }
3781
+ { label: n.net, amount: $(r.netCents) },
3782
+ { label: n.gross, amount: $(r.grossCents), emphasis: !0 }
3765
3783
  ],
3766
3784
  taxRows: r.byRate.map((a) => ({
3767
3785
  label: `${n.tax} ${a.percent ?? o(a.taxRateKey)}%`,
3768
- amount: R(a.taxCents)
3786
+ amount: $(a.taxCents)
3769
3787
  }))
3770
3788
  };
3771
3789
  return { lines: [i], totals: [s] };
3772
3790
  }
3773
- const Oi = {
3791
+ const Ni = {
3774
3792
  description: "Omschrijving",
3775
3793
  optional: "optioneel",
3776
3794
  quantity: "Aantal",
@@ -3779,14 +3797,14 @@ const Oi = {
3779
3797
  tax: "Btw",
3780
3798
  gross: "Totaal"
3781
3799
  };
3782
- function Ci(e, t, n, r) {
3800
+ function xi(e, t, n, r) {
3783
3801
  const o = t ? `${e} — ${t}` : e;
3784
3802
  return n ? `${o} (${r})` : o;
3785
3803
  }
3786
- function Ni(e) {
3804
+ function Di(e) {
3787
3805
  return e?.street ? [e.street, e.houseNumber].filter(Boolean).join(" ") : "";
3788
3806
  }
3789
- function xi(e) {
3807
+ function Ri(e) {
3790
3808
  return Number.isInteger(e) ? String(e) : String(e).replace(".", ",");
3791
3809
  }
3792
3810
  function U(e) {
@@ -3801,7 +3819,7 @@ function $i(e) {
3801
3819
  block_id: "head",
3802
3820
  type: "letterhead",
3803
3821
  fields: [
3804
- ...r ? [{ key: "number", label: Di[n]?.number ?? "Nummer", value: `{${n}.number}` }] : [],
3822
+ ...r ? [{ key: "number", label: Li[n]?.number ?? "Nummer", value: `{${n}.number}` }] : [],
3805
3823
  { key: "date", label: "Datum", value: `{${n}.date}` },
3806
3824
  ...r ? [{ key: "due_date", label: "Vervaldatum", value: `{${n}.due_date}` }] : [{ key: "valid_until", label: "Geldig tot", value: `{${n}.valid_until}` }],
3807
3825
  // Required on a credit note: an open token is a hole, and the issue gate refuses holes.
@@ -3850,11 +3868,11 @@ function $i(e) {
3850
3868
  { block_id: "terms", type: "paragraph", text: Mt[n] ?? Mt.quote }
3851
3869
  ];
3852
3870
  }
3853
- const ad = (e) => ({
3871
+ const gd = (e) => ({
3854
3872
  note: { key: `${O(e).key}.note`, exists: !0 },
3855
3873
  // Keyed on the start: a range without one is not a range, and `period_to` alone says nothing.
3856
3874
  period: { key: `${O(e).key}.period_from`, exists: !0 }
3857
- }), Di = {
3875
+ }), Li = {
3858
3876
  invoice: { number: "Factuurnummer" },
3859
3877
  credit_note: { number: "Creditnotanummer" }
3860
3878
  }, wt = {
@@ -3875,54 +3893,54 @@ Hierbij onze creditnota. De onderstaande bedragen worden met u verrekend.`
3875
3893
  order: "Genoemde bedragen zijn exclusief btw tenzij anders vermeld.",
3876
3894
  invoice: "Genoemde bedragen zijn exclusief btw tenzij anders vermeld.",
3877
3895
  credit_note: "Genoemde bedragen zijn exclusief btw tenzij anders vermeld."
3878
- }, cd = $i("quote"), Ri = We.map((e) => e.key), Li = "product";
3879
- function Pi(e, t) {
3896
+ }, yd = $i("quote"), Pi = We.map((e) => e.key), Ki = "product";
3897
+ function Ui(e, t) {
3880
3898
  return `${e}:${t}`;
3881
3899
  }
3882
- function ld(e) {
3883
- return `${Li}:${e}`;
3900
+ function bd(e) {
3901
+ return `${Ki}:${e}`;
3884
3902
  }
3885
- function ud(e, t) {
3903
+ function _d(e, t) {
3886
3904
  const n = e.businessEntityId || t;
3887
3905
  if (n)
3888
3906
  return `/apps/sales/${n}/${O(e.kindKey).path}/${e.id}`;
3889
3907
  }
3890
- function dd(e, t) {
3908
+ function Ad(e, t) {
3891
3909
  const n = e.businessEntityId || t;
3892
3910
  return n ? `/apps/sales/${n}/product/${e.id}` : void 0;
3893
3911
  }
3894
- function fd(e) {
3912
+ function Ed(e) {
3895
3913
  const t = e.indexOf(":");
3896
3914
  if (t < 0) return;
3897
3915
  const n = e.slice(0, t);
3898
- return Ri.includes(n) ? e.slice(t + 1) : void 0;
3916
+ return Pi.includes(n) ? e.slice(t + 1) : void 0;
3899
3917
  }
3900
- function pd(e) {
3901
- const t = /* @__PURE__ */ new Set([Pi(e.kindKey, e.id)]);
3918
+ function Sd(e) {
3919
+ const t = /* @__PURE__ */ new Set([Ui(e.kindKey, e.id)]);
3902
3920
  return e.companyId && t.add(`company:${e.companyId}`), e.contactId && t.add(`contact:${e.contactId}`), e.dealItemId && t.add(`work_item:${e.dealItemId}`), Array.from(t);
3903
3921
  }
3904
- const md = 4;
3905
- function hd(e, t) {
3922
+ const Td = 4;
3923
+ function Id(e, t) {
3906
3924
  const n = String(t).padStart(Math.max(1, e.padding), "0");
3907
3925
  return `${e.prefix}${e.period ? `${e.period}-` : ""}${n}`;
3908
3926
  }
3909
- function gd(e, t = Date.now()) {
3927
+ function vd(e, t = Date.now()) {
3910
3928
  return e === "year" ? String(new Date(t).getFullYear()) : "";
3911
3929
  }
3912
- const yd = [
3930
+ const kd = [
3913
3931
  "cash",
3914
3932
  "credit",
3915
3933
  "direct_debit",
3916
3934
  "card",
3917
3935
  "other"
3918
3936
  ];
3919
- function bd(e, t) {
3937
+ function wd(e, t) {
3920
3938
  return e + Math.max(0, Math.round(t)) * 24 * 60 * 60 * 1e3;
3921
3939
  }
3922
- function Ad(e) {
3940
+ function Md(e) {
3923
3941
  return { code: e.code, label: e.label, method: e.method, dueDays: e.dueDays };
3924
3942
  }
3925
- const _d = [
3943
+ const Od = [
3926
3944
  {
3927
3945
  code: "14D",
3928
3946
  label: "Binnen 14 dagen",
@@ -3934,34 +3952,34 @@ const _d = [
3934
3952
  { code: "30D", label: "Binnen 30 dagen", method: "credit", dueDays: 30, order: 1 },
3935
3953
  { code: "CONTANT", label: "Contant", method: "cash", dueDays: 0, order: 2 }
3936
3954
  ];
3937
- function Ed(e) {
3955
+ function Cd(e) {
3938
3956
  return e.type === "agent";
3939
3957
  }
3940
- const Ki = [
3958
+ const Fi = [
3941
3959
  "communication:interactions:created",
3942
3960
  "communication:interactions:updated",
3943
3961
  "communication:activities:created",
3944
3962
  "communication:activities:updated"
3945
3963
  ];
3946
- function Sd(e) {
3947
- return Ki.includes(e);
3964
+ function Nd(e) {
3965
+ return Fi.includes(e);
3948
3966
  }
3949
- const Td = "WORK_COMMENT_ADDED", Id = "WORK_ITEM_ASSIGNED", vd = "WORK_ITEM_STATUS_CHANGED";
3950
- function Ui(e, t) {
3967
+ const xd = "WORK_COMMENT_ADDED", Dd = "WORK_ITEM_ASSIGNED", Rd = "WORK_ITEM_STATUS_CHANGED";
3968
+ function ji(e, t) {
3951
3969
  const n = (r) => {
3952
3970
  const o = new Date(r);
3953
3971
  return o.setHours(0, 0, 0, 0), o.getTime();
3954
3972
  };
3955
- return Math.round((n(e) - n(t)) / Mr);
3973
+ return Math.round((n(e) - n(t)) / Cr);
3956
3974
  }
3957
- function kd(e, t) {
3975
+ function $d(e, t) {
3958
3976
  if (e.closedAt != null) return { score: P, reasons: [] };
3959
3977
  const n = t.remindersById?.[e.id];
3960
3978
  if (n && n.remindAt > t.now) return { score: P, reasons: [] };
3961
3979
  let r = 0;
3962
3980
  const o = [], i = e.priority ?? "normal";
3963
3981
  if (ne[i] > 0 && (r += ne[i], o.push(`priority:${i}`)), typeof e.dueDate == "number") {
3964
- const s = Ui(e.dueDate, t.now);
3982
+ const s = ji(e.dueDate, t.now);
3965
3983
  s < 0 ? (r += 35, o.push("overdue")) : s === 0 && (r += 20, o.push("due-today"));
3966
3984
  }
3967
3985
  return e.source?.initiator === "system" && e.source.systemReason && (r += 15, o.push(`auto:${e.source.systemReason}`)), { score: r, reasons: o };
@@ -3976,35 +3994,35 @@ const Ve = [
3976
3994
  { key: "deal", label: "type_deal" },
3977
3995
  /** A date others lead up to: what blocks it, or sits under it, is its progress. No duration. */
3978
3996
  { key: "milestone", label: "type_milestone" }
3979
- ], wd = Ve.map((e) => e.key);
3980
- function Md(e) {
3997
+ ], Ld = Ve.map((e) => e.key);
3998
+ function Pd(e) {
3981
3999
  return e?.types?.length ? e.types : Ve;
3982
4000
  }
3983
- function Od(e, t) {
4001
+ function Kd(e, t) {
3984
4002
  return t.find((n) => n.key === e);
3985
4003
  }
3986
- function Cd(e) {
4004
+ function Ud(e) {
3987
4005
  const t = e.trim().toLowerCase();
3988
4006
  return t ? t.includes("sub-task") || t.includes("subtask") || t.includes("sub task") ? "subtask" : t.includes("bug") || t.includes("defect") ? "bug" : t.includes("epic") ? "epic" : t.includes("story") ? "story" : t.includes("incident") || t.includes("problem") || t.includes("service request") || t.includes("change") ? "case" : t.includes("milestone") || t.includes("mijlpaal") ? "milestone" : t.includes("task") ? "task" : null : null;
3989
4007
  }
3990
- function Nd(...e) {
4008
+ function Fd(...e) {
3991
4009
  return e.map((t) => Ve.find((n) => n.key === t)).filter((t) => !!t);
3992
4010
  }
3993
- const Fi = "work_item", ji = "work_project", Bi = "work_activity", xd = "work_cycle";
3994
- function Hi(e) {
3995
- return `${Fi}:${e}`;
4011
+ const Bi = "work_item", Hi = "work_project", Gi = "work_activity", jd = "work_cycle";
4012
+ function Wi(e) {
4013
+ return `${Bi}:${e}`;
3996
4014
  }
3997
- function An(e) {
3998
- return `${ji}:${e}`;
4015
+ function _n(e) {
4016
+ return `${Hi}:${e}`;
3999
4017
  }
4000
- function $d(e) {
4001
- return `${Bi}:${e}`;
4018
+ function Bd(e) {
4019
+ return `${Gi}:${e}`;
4002
4020
  }
4003
- function Dd(e, t, n) {
4021
+ function Hd(e, t, n) {
4004
4022
  const r = `${e}-${t}`;
4005
4023
  return n ? `${r}-${n}` : r;
4006
4024
  }
4007
- function Rd(e) {
4025
+ function Gd(e) {
4008
4026
  const t = /^([A-Za-z0-9]{2,8})-(\d+)(?:-(\d+))?$/.exec((e || "").trim());
4009
4027
  return t ? {
4010
4028
  projectKey: t[1].toUpperCase(),
@@ -4012,52 +4030,52 @@ function Rd(e) {
4012
4030
  ...t[3] ? { subSequence: Number(t[3]) } : {}
4013
4031
  } : null;
4014
4032
  }
4015
- function Ld(e) {
4033
+ function Wd(e) {
4016
4034
  return (e || "").normalize("NFD").replace(/[\u0300-\u036f]/g, "").toUpperCase().replace(/[^A-Z0-9]/g, "").slice(0, 3) || "PRJ";
4017
4035
  }
4018
- function Pd(e, t = 25) {
4019
- const n = /* @__PURE__ */ new Set([Hi(e.id)]);
4020
- e.projectId && n.add(An(e.projectId));
4036
+ function Vd(e, t = 25) {
4037
+ const n = /* @__PURE__ */ new Set([Wi(e.id)]);
4038
+ e.projectId && n.add(_n(e.projectId));
4021
4039
  for (const r of e.ancestorKeys ?? []) n.add(r);
4022
4040
  for (const r of e.partyKeys ?? []) n.add(r);
4023
4041
  return Array.from(n).slice(0, t);
4024
4042
  }
4025
- function Kd(e) {
4026
- return [An(e.id)];
4043
+ function zd(e) {
4044
+ return [_n(e.id)];
4027
4045
  }
4028
4046
  const ze = [
4029
4047
  { key: "open", label: "status_open", category: "todo", order: 0 },
4030
4048
  { key: "in_progress", label: "status_in_progress", category: "in_progress", order: 1 },
4031
4049
  { key: "done", label: "status_done", category: "done", order: 2 },
4032
4050
  { key: "cancelled", label: "status_cancelled", category: "done", order: 3 }
4033
- ], _n = ze.map((e) => e.key);
4034
- function Gi(e) {
4051
+ ], An = ze.map((e) => e.key);
4052
+ function Vi(e) {
4035
4053
  return e?.statuses?.length ? e.statuses : ze;
4036
4054
  }
4037
- function Wi(e, t) {
4055
+ function zi(e, t) {
4038
4056
  return t.find((n) => n.key === e)?.category ?? "todo";
4039
4057
  }
4040
- function Ud(e, t) {
4058
+ function Yd(e, t) {
4041
4059
  return t.find((n) => n.key === e);
4042
4060
  }
4043
- function Fd(e) {
4044
- const t = Gi(e), n = e?.defaultStatusKey;
4045
- return n && t.some((r) => r.key === n) ? n : Vi(t)[0]?.key ?? ze[0].key;
4061
+ function Xd(e) {
4062
+ const t = Vi(e), n = e?.defaultStatusKey;
4063
+ return n && t.some((r) => r.key === n) ? n : Yi(t)[0]?.key ?? ze[0].key;
4046
4064
  }
4047
- function Vi(e) {
4065
+ function Yi(e) {
4048
4066
  return [...e].sort((t, n) => {
4049
4067
  const r = (t.order ?? 0) - (n.order ?? 0);
4050
4068
  return r !== 0 ? r : (t.label || "").localeCompare(n.label || "");
4051
4069
  });
4052
4070
  }
4053
- function jd(e, t) {
4054
- return Wi(e, t) === "done";
4071
+ function qd(e, t) {
4072
+ return zi(e, t) === "done";
4055
4073
  }
4056
- function zi(e) {
4074
+ function Xi(e) {
4057
4075
  return (e || "").normalize("NFD").replace(/[\u0300-\u036f]/g, "").toLowerCase().replace(/[^a-z0-9]+/g, "-").slice(0, 48).replace(/^-+|-+$/g, "");
4058
4076
  }
4059
- function Bd(e, t) {
4060
- const n = zi(e) || "status", r = /* @__PURE__ */ new Set([...t, ..._n]);
4077
+ function Qd(e, t) {
4078
+ const n = Xi(e) || "status", r = /* @__PURE__ */ new Set([...t, ...An]);
4061
4079
  if (!r.has(n)) return n;
4062
4080
  for (let o = 2; o < 500; o++) {
4063
4081
  const i = `${n}-${o}`;
@@ -4065,7 +4083,7 @@ function Bd(e, t) {
4065
4083
  }
4066
4084
  return `${n}-${r.size + 1}`;
4067
4085
  }
4068
- function Hd(e) {
4086
+ function Jd(e) {
4069
4087
  const t = [];
4070
4088
  if (!e.length) return [{ index: -1, reason: "empty" }];
4071
4089
  const n = /* @__PURE__ */ new Set();
@@ -4074,45 +4092,45 @@ function Hd(e) {
4074
4092
  t.push({ index: o, reason: "missing_key" });
4075
4093
  return;
4076
4094
  }
4077
- _n.includes(r.key) && t.push({ index: o, reason: "reserved_key", key: r.key }), n.has(r.key) && t.push({ index: o, reason: "duplicate_key", key: r.key }), n.add(r.key);
4095
+ An.includes(r.key) && t.push({ index: o, reason: "reserved_key", key: r.key }), n.has(r.key) && t.push({ index: o, reason: "duplicate_key", key: r.key }), n.add(r.key);
4078
4096
  }), 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;
4079
4097
  }
4080
- function Gd(e, t) {
4098
+ function Zd(e, t) {
4081
4099
  return t.find((n) => n.key === e)?.requiresApproval === !0;
4082
4100
  }
4083
- function Wd(e, t) {
4101
+ function ef(e, t) {
4084
4102
  if (!e) return;
4085
4103
  const n = t?.resolutions?.find((r) => r.key === e)?.positive;
4086
4104
  return n === void 0 ? void 0 : n ? "won" : "lost";
4087
4105
  }
4088
- function Vd(e) {
4106
+ function tf(e) {
4089
4107
  return e.startDate ?? Number.MAX_SAFE_INTEGER;
4090
4108
  }
4091
- function zd(e) {
4109
+ function nf(e) {
4092
4110
  return e.completedAt ? "completed" : e.startedAt ? "active" : "planned";
4093
4111
  }
4094
- const Xd = [
4112
+ const rf = [
4095
4113
  "statusKeys",
4096
4114
  "typeKeys",
4097
4115
  "labels",
4098
4116
  "priority",
4099
4117
  "assignees"
4100
- ], Yd = ["blockedOnly", "watchingOnly", "reportedByMe"], qd = [
4118
+ ], of = ["blockedOnly", "watchingOnly", "reportedByMe"], sf = [
4101
4119
  "priority",
4102
4120
  "dueDate",
4103
4121
  "updatedAt",
4104
4122
  "createdAt",
4105
4123
  "title",
4106
4124
  "estimateSeconds"
4107
- ], Qd = ["list", "board", "calendar", "workload"], Xi = ["day", "week", "month"];
4108
- function Jd(e) {
4125
+ ], af = ["list", "board", "calendar", "workload"], qi = ["day", "week", "month"];
4126
+ function cf(e) {
4109
4127
  const t = e;
4110
- if (!t || !Xi.includes(t.every)) return;
4128
+ if (!t || !qi.includes(t.every)) return;
4111
4129
  const n = Math.floor(Number(t.interval ?? 1));
4112
4130
  if (!(!Number.isFinite(n) || n < 1 || n > 365))
4113
4131
  return { every: t.every, interval: n };
4114
4132
  }
4115
- function Yi(e, t) {
4133
+ function Qi(e, t) {
4116
4134
  const n = new Date(e);
4117
4135
  if (t.every === "day") n.setDate(n.getDate() + t.interval);
4118
4136
  else if (t.every === "week") n.setDate(n.getDate() + 7 * t.interval);
@@ -4122,11 +4140,11 @@ function Yi(e, t) {
4122
4140
  }
4123
4141
  return n.getTime();
4124
4142
  }
4125
- function Zd(e, t, n) {
4126
- const r = Yi(e.dueDate ?? n, t);
4143
+ function lf(e, t, n) {
4144
+ const r = Qi(e.dueDate ?? n, t);
4127
4145
  return e.startDate === void 0 || e.dueDate === void 0 ? { dueDate: r } : { dueDate: r, startDate: r - (e.dueDate - e.startDate) };
4128
4146
  }
4129
- const qi = /* @__PURE__ */ new Set(["image/png", "image/jpeg", "image/jpg", "image/gif", "image/webp"]), Qi = /* @__PURE__ */ new Set([
4147
+ const Ji = /* @__PURE__ */ new Set(["image/png", "image/jpeg", "image/jpg", "image/gif", "image/webp"]), Zi = /* @__PURE__ */ new Set([
4130
4148
  "text/plain",
4131
4149
  "text/markdown",
4132
4150
  "text/csv",
@@ -4135,71 +4153,71 @@ const qi = /* @__PURE__ */ new Set(["image/png", "image/jpeg", "image/jpg", "ima
4135
4153
  "application/xml",
4136
4154
  "text/xml"
4137
4155
  ]);
4138
- function Ji(e) {
4156
+ function es(e) {
4139
4157
  const t = (e ?? "").trim().toLowerCase().split(";")[0];
4140
- return t ? qi.has(t) ? "image" : t === "application/pdf" ? "pdf" : Qi.has(t) ? "text" : t.startsWith("audio/") ? "audio" : "unsupported" : "unsupported";
4158
+ return t ? Ji.has(t) ? "image" : t === "application/pdf" ? "pdf" : Zi.has(t) ? "text" : t.startsWith("audio/") ? "audio" : "unsupported" : "unsupported";
4141
4159
  }
4142
- const B = 1024 * 1024, Zi = {
4160
+ const B = 1024 * 1024, ts = {
4143
4161
  image: 5 * B,
4144
4162
  pdf: 20 * B,
4145
4163
  text: 1 * B,
4146
4164
  audio: 20 * B
4147
- }, ef = 25 * B, tf = 5;
4148
- function nf(e, t) {
4149
- const n = Ji(e);
4150
- return n === "unsupported" ? "unsupported" : t > Zi[n] ? "too-large" : null;
4165
+ }, uf = 25 * B, df = 5;
4166
+ function ff(e, t) {
4167
+ const n = es(e);
4168
+ return n === "unsupported" ? "unsupported" : t > ts[n] ? "too-large" : null;
4151
4169
  }
4152
- const rf = "ai-tool";
4153
- function of(e) {
4170
+ const pf = "ai-tool";
4171
+ function mf(e) {
4154
4172
  return e.access === "read" ? "idempotent" : e.reversible ?? "none";
4155
4173
  }
4156
4174
  function En(e) {
4157
4175
  return e.access !== "read" && e.effect !== "internal";
4158
4176
  }
4159
- function es(e) {
4177
+ function ns(e) {
4160
4178
  return `${e.kind}:${e.id || e.url || e.title}`;
4161
4179
  }
4162
- function sf(e, t = []) {
4180
+ function hf(e, t = []) {
4163
4181
  const n = new Set(t), r = [], o = [];
4164
4182
  for (const i of e) {
4165
- const s = es(i);
4183
+ const s = ns(i);
4166
4184
  n.has(s) || (n.add(s), r.push(i), o.push(s));
4167
4185
  }
4168
4186
  return { sources: r, keys: o };
4169
4187
  }
4170
- const af = "assist-source", cf = ["blocking", "due", "open"];
4171
- function lf(e, t) {
4188
+ const gf = "assist-source", yf = ["blocking", "due", "open"];
4189
+ function bf(e, t) {
4172
4190
  const [n, r] = (e.subjectKey ?? "").split(":");
4173
4191
  return n === t && r ? r : void 0;
4174
4192
  }
4175
4193
  const Ot = { blocking: 0, due: 1, open: 2 };
4176
- function uf(e, t) {
4194
+ function _f(e, t) {
4177
4195
  return Ot[e.band ?? "open"] - Ot[t.band ?? "open"] || (t.priority ?? 0) - (e.priority ?? 0) || e.id.localeCompare(t.id);
4178
4196
  }
4179
- function df(e) {
4197
+ function Af(e) {
4180
4198
  return e.sessions.filter(
4181
4199
  (t) => t.id !== e.exceptSessionId && t.state === "connected" && e.canHold(t.providerId)
4182
4200
  );
4183
4201
  }
4184
- function ff(e) {
4202
+ function Ef(e) {
4185
4203
  return e.sessions.filter(
4186
4204
  (t) => t.id !== e.exceptSessionId && t.state === "connected" && !e.canHold(t.providerId)
4187
4205
  );
4188
4206
  }
4189
- function pf(e) {
4207
+ function Sf(e) {
4190
4208
  return e.sessions.some(
4191
4209
  (n) => n.id !== e.exceptSessionId && (n.state === "connected" || n.state === "on_hold")
4192
4210
  ) ? { admit: !1, reason: "busy" } : { admit: !0 };
4193
4211
  }
4194
- function ts(e, t) {
4195
- const n = new Set(e.disabledIntents ?? []), r = e.intentOverrides ?? {}, o = t.intents.filter((s) => !n.has(s.intent)).map((s) => rs(s, r[s.intent]));
4212
+ function rs(e, t) {
4213
+ const n = new Set(e.disabledIntents ?? []), r = e.intentOverrides ?? {}, o = t.intents.filter((s) => !n.has(s.intent)).map((s) => is(s, r[s.intent]));
4196
4214
  if (!e.extraIntents || e.extraIntents.length === 0) return o;
4197
4215
  const i = new Set(o.map((s) => s.intent));
4198
4216
  for (const s of e.extraIntents)
4199
4217
  i.has(s.intent) || (o.push(s), i.add(s.intent));
4200
4218
  return o;
4201
4219
  }
4202
- function ns(e, t) {
4220
+ function os(e, t) {
4203
4221
  const n = {};
4204
4222
  for (const r of e.intents) {
4205
4223
  if (!r.togglable) continue;
@@ -4208,46 +4226,46 @@ function ns(e, t) {
4208
4226
  }
4209
4227
  return n;
4210
4228
  }
4211
- function mf(e, t) {
4212
- const n = ns(e, t);
4229
+ function Tf(e, t) {
4230
+ const n = os(e, t);
4213
4231
  return Object.entries(n).filter(([, r]) => !r).map(([r]) => r);
4214
4232
  }
4215
- function rs(e, t) {
4233
+ function is(e, t) {
4216
4234
  return t ? {
4217
4235
  intent: t.intent ?? e.intent,
4218
4236
  targetSchemes: t.targetSchemes ?? e.targetSchemes,
4219
4237
  transport: t.transport ?? e.transport
4220
4238
  } : e;
4221
4239
  }
4222
- function hf(e, t) {
4240
+ function If(e, t) {
4223
4241
  const n = [];
4224
4242
  for (const r of e) {
4225
4243
  if (!r.enabled) continue;
4226
4244
  const o = t[r.providerId];
4227
4245
  if (o)
4228
- for (const i of ts(r, o))
4246
+ for (const i of rs(r, o))
4229
4247
  n.push({ channel: r, description: o, capability: i });
4230
4248
  }
4231
4249
  return n;
4232
4250
  }
4233
- function gf(e, t) {
4251
+ function vf(e, t) {
4234
4252
  return t.filter((n) => n.capability.intent === e);
4235
4253
  }
4236
- function os(e, t) {
4254
+ function ss(e, t) {
4237
4255
  return t.filter((n) => n.capability.targetSchemes.includes(e));
4238
4256
  }
4239
- function yf(e, t) {
4240
- return os(e.scheme, t);
4257
+ function kf(e, t) {
4258
+ return ss(e.scheme, t);
4241
4259
  }
4242
- function bf(e, t, n) {
4260
+ function wf(e, t, n) {
4243
4261
  const r = [];
4244
4262
  for (const o of e)
4245
4263
  for (const i of n)
4246
4264
  i.capability.intent === t && i.capability.targetSchemes.includes(o.scheme) && r.push({ channelIntent: i, endpoint: o });
4247
4265
  return r;
4248
4266
  }
4249
- var is = /* @__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))(is || {});
4250
- const ss = {
4267
+ var as = /* @__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))(as || {});
4268
+ const cs = {
4251
4269
  mailto: "mail",
4252
4270
  sip: "tel",
4253
4271
  tel: "tel",
@@ -4268,10 +4286,10 @@ const ss = {
4268
4286
  id: "note",
4269
4287
  custom: "note"
4270
4288
  };
4271
- function Af(e) {
4272
- return e ? ss[e] ?? "note" : "note";
4289
+ function Mf(e) {
4290
+ return e ? cs[e] ?? "note" : "note";
4273
4291
  }
4274
- const _f = "message_window", Ef = "message_templates", Sf = {
4292
+ const Of = "message_window", Cf = "message_templates", Nf = {
4275
4293
  // E-mail
4276
4294
  FROM: "from",
4277
4295
  TO: "to",
@@ -4288,11 +4306,11 @@ const _f = "message_window", Ef = "message_templates", Sf = {
4288
4306
  // Voice/conference
4289
4307
  HOST: "host",
4290
4308
  PARTICIPANT: "participant"
4291
- }, Tf = (e, t) => ({ intent: e, ...t }), If = "folder_management", vf = "remote_search", kf = "message_reactions", wf = {
4309
+ }, xf = (e, t) => ({ intent: e, ...t }), Df = "folder_management", Rf = "remote_search", $f = "message_reactions", Lf = {
4292
4310
  ok: !1,
4293
4311
  code: "UNSUPPORTED",
4294
4312
  message: "Provider does not support this op"
4295
- }, Mf = "connector", Of = "context.collect", _ = (e) => ({ type: "string", description: e }), A = (e) => ({ type: "number", description: e }), ee = (e) => ({ type: "boolean", description: e }), M = _("Sheet name. Omit for the sheet the user is looking at."), Ct = _("Slide id, as `inspect` reports it.");
4313
+ }, Pf = "connector", Kf = "context.collect", A = (e) => ({ type: "string", description: e }), _ = (e) => ({ type: "number", description: e }), ee = (e) => ({ type: "boolean", description: e }), M = A("Sheet name. Omit for the sheet the user is looking at."), Ct = A("Slide id, as `inspect` reports it.");
4296
4314
  function b(e, t, n, r, o, i) {
4297
4315
  return {
4298
4316
  op: e,
@@ -4303,12 +4321,12 @@ function b(e, t, n, r, o, i) {
4303
4321
  visible: i.visible
4304
4322
  };
4305
4323
  }
4306
- const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt = { undoable: !1, visible: !0 }, re = { undoable: !1, visible: !1 }, as = [
4324
+ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt = { undoable: !1, visible: !0 }, re = { undoable: !1, visible: !1 }, ls = [
4307
4325
  b(
4308
4326
  "pdf.goToPage",
4309
4327
  ["pdf"],
4310
4328
  "Scroll the viewer to a page.",
4311
- { page: A("1-based page number.") },
4329
+ { page: _("1-based page number.") },
4312
4330
  ["page"],
4313
4331
  G
4314
4332
  ),
@@ -4316,7 +4334,7 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4316
4334
  "pdf.search",
4317
4335
  ["pdf"],
4318
4336
  "Search the document and highlight the matches, as the find bar does.",
4319
- { query: _("Text to find."), next: ee("Jump to the next match instead of the first.") },
4337
+ { query: A("Text to find."), next: ee("Jump to the next match instead of the first.") },
4320
4338
  ["query"],
4321
4339
  G
4322
4340
  ),
@@ -4339,7 +4357,7 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4339
4357
  ["pdf"],
4340
4358
  "Fill one form field of a fillable PDF.",
4341
4359
  {
4342
- field: _("Field name, exactly as `inspect` reports it under `fields`."),
4360
+ field: A("Field name, exactly as `inspect` reports it under `fields`."),
4343
4361
  value: {
4344
4362
  type: ["string", "boolean"],
4345
4363
  description: "Text for a text field, true/false for a checkbox or radio."
@@ -4375,13 +4393,13 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4375
4393
  ["pdf"],
4376
4394
  "Place a text note on a page. Written on save; not visible before that.",
4377
4395
  {
4378
- page: A("1-based page number."),
4379
- text: _("The note's text."),
4380
- left: A("Distance from the left edge, in PDF points (72 per inch)."),
4381
- top: A("Distance from the top edge, in PDF points."),
4382
- width: A("Box width in points. Omit for a sensible default."),
4383
- height: A("Box height in points. Omit for a sensible default."),
4384
- fontSize: A("Font size in points. Omit for 12.")
4396
+ page: _("1-based page number."),
4397
+ text: A("The note's text."),
4398
+ left: _("Distance from the left edge, in PDF points (72 per inch)."),
4399
+ top: _("Distance from the top edge, in PDF points."),
4400
+ width: _("Box width in points. Omit for a sensible default."),
4401
+ height: _("Box height in points. Omit for a sensible default."),
4402
+ fontSize: _("Font size in points. Omit for 12.")
4385
4403
  },
4386
4404
  ["page", "text", "left", "top"],
4387
4405
  re
@@ -4391,21 +4409,21 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4391
4409
  ["pdf"],
4392
4410
  "Highlight a phrase on a page. Written on save; not visible before that.",
4393
4411
  {
4394
- page: A("1-based page number."),
4395
- text: _("The exact phrase to highlight, as it appears in the page's text."),
4396
- occurrence: A("Which occurrence on that page, 1-based. Omit for the first.")
4412
+ page: _("1-based page number."),
4413
+ text: A("The exact phrase to highlight, as it appears in the page's text."),
4414
+ occurrence: _("Which occurrence on that page, 1-based. Omit for the first.")
4397
4415
  },
4398
4416
  ["page", "text"],
4399
4417
  re
4400
4418
  )
4401
- ], cs = [
4419
+ ], us = [
4402
4420
  b(
4403
4421
  "sheet.setValues",
4404
4422
  ["sheet"],
4405
4423
  "Write a block of values. The block's shape must match the range.",
4406
4424
  {
4407
4425
  sheet: M,
4408
- range: _("A1 notation, e.g. `B2:D5` or a single `A1`."),
4426
+ range: A("A1 notation, e.g. `B2:D5` or a single `A1`."),
4409
4427
  values: {
4410
4428
  type: "array",
4411
4429
  items: { type: "array", items: { type: ["string", "number", "boolean", "null"] } },
@@ -4419,7 +4437,7 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4419
4437
  "sheet.setFormula",
4420
4438
  ["sheet"],
4421
4439
  "Put a formula in every cell of a range.",
4422
- { sheet: M, range: _("A1 notation."), formula: _("Including the leading `=`.") },
4440
+ { sheet: M, range: A("A1 notation."), formula: A("Including the leading `=`.") },
4423
4441
  ["range", "formula"],
4424
4442
  T
4425
4443
  ),
@@ -4429,18 +4447,18 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4429
4447
  "Change the look of a range. Only the properties you pass are touched.",
4430
4448
  {
4431
4449
  sheet: M,
4432
- range: _("A1 notation."),
4450
+ range: A("A1 notation."),
4433
4451
  bold: ee("Bold on or off."),
4434
4452
  italic: ee("Italic on or off."),
4435
- fontSize: A("Point size."),
4436
- fontColor: _("CSS colour, e.g. `#b91c1c`."),
4437
- background: _("CSS colour for the cell fill."),
4453
+ fontSize: _("Point size."),
4454
+ fontColor: A("CSS colour, e.g. `#b91c1c`."),
4455
+ background: A("CSS colour for the cell fill."),
4438
4456
  horizontalAlignment: {
4439
4457
  type: "string",
4440
4458
  enum: ["left", "center", "right"],
4441
4459
  description: "Horizontal alignment."
4442
4460
  },
4443
- numberFormat: _("Number format pattern, e.g. `#,##0.00` or `0%`.")
4461
+ numberFormat: A("Number format pattern, e.g. `#,##0.00` or `0%`.")
4444
4462
  },
4445
4463
  ["range"],
4446
4464
  T
@@ -4451,8 +4469,8 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4451
4469
  "Insert empty rows, pushing the rest down.",
4452
4470
  {
4453
4471
  sheet: M,
4454
- at: A("1-based row number to insert before."),
4455
- count: A("How many. Omit for 1.")
4472
+ at: _("1-based row number to insert before."),
4473
+ count: _("How many. Omit for 1.")
4456
4474
  },
4457
4475
  ["at"],
4458
4476
  T
@@ -4461,7 +4479,7 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4461
4479
  "sheet.deleteRows",
4462
4480
  ["sheet"],
4463
4481
  "Delete rows, pulling the rest up.",
4464
- { sheet: M, at: A("1-based first row to delete."), count: A("How many. Omit for 1.") },
4482
+ { sheet: M, at: _("1-based first row to delete."), count: _("How many. Omit for 1.") },
4465
4483
  ["at"],
4466
4484
  T
4467
4485
  ),
@@ -4471,8 +4489,8 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4471
4489
  "Insert empty columns, pushing the rest right.",
4472
4490
  {
4473
4491
  sheet: M,
4474
- at: A("1-based column number to insert before."),
4475
- count: A("How many. Omit for 1.")
4492
+ at: _("1-based column number to insert before."),
4493
+ count: _("How many. Omit for 1.")
4476
4494
  },
4477
4495
  ["at"],
4478
4496
  T
@@ -4483,8 +4501,8 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4483
4501
  "Delete columns, pulling the rest left.",
4484
4502
  {
4485
4503
  sheet: M,
4486
- at: A("1-based first column to delete."),
4487
- count: A("How many. Omit for 1.")
4504
+ at: _("1-based first column to delete."),
4505
+ count: _("How many. Omit for 1.")
4488
4506
  },
4489
4507
  ["at"],
4490
4508
  T
@@ -4493,7 +4511,7 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4493
4511
  "sheet.merge",
4494
4512
  ["sheet"],
4495
4513
  "Merge a range into one cell.",
4496
- { sheet: M, range: _("A1 notation.") },
4514
+ { sheet: M, range: A("A1 notation.") },
4497
4515
  ["range"],
4498
4516
  T
4499
4517
  ),
@@ -4501,7 +4519,7 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4501
4519
  "sheet.unmerge",
4502
4520
  ["sheet"],
4503
4521
  "Break merged cells in a range apart.",
4504
- { sheet: M, range: _("A1 notation.") },
4522
+ { sheet: M, range: A("A1 notation.") },
4505
4523
  ["range"],
4506
4524
  T
4507
4525
  ),
@@ -4511,8 +4529,8 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4511
4529
  "Sort a range on one of its columns.",
4512
4530
  {
4513
4531
  sheet: M,
4514
- range: _("A1 notation covering the rows to sort, header excluded."),
4515
- column: A("1-based column *within the range*, not within the sheet."),
4532
+ range: A("A1 notation covering the rows to sort, header excluded."),
4533
+ column: _("1-based column *within the range*, not within the sheet."),
4516
4534
  ascending: ee("Ascending. Omit for ascending.")
4517
4535
  },
4518
4536
  ["range", "column"],
@@ -4522,7 +4540,7 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4522
4540
  "sheet.insertSheet",
4523
4541
  ["sheet"],
4524
4542
  "Add a new sheet.",
4525
- { name: _("Name for the new sheet.") },
4543
+ { name: A("Name for the new sheet.") },
4526
4544
  ["name"],
4527
4545
  T
4528
4546
  ),
@@ -4530,7 +4548,7 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4530
4548
  "sheet.renameSheet",
4531
4549
  ["sheet"],
4532
4550
  "Rename a sheet.",
4533
- { sheet: _("Current name."), name: _("New name.") },
4551
+ { sheet: A("Current name."), name: A("New name.") },
4534
4552
  ["sheet", "name"],
4535
4553
  T
4536
4554
  ),
@@ -4538,7 +4556,7 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4538
4556
  "sheet.deleteSheet",
4539
4557
  ["sheet"],
4540
4558
  "Remove a sheet and everything on it.",
4541
- { sheet: _("Name of the sheet to delete.") },
4559
+ { sheet: A("Name of the sheet to delete.") },
4542
4560
  ["sheet"],
4543
4561
  T
4544
4562
  ),
@@ -4546,18 +4564,18 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4546
4564
  "sheet.activate",
4547
4565
  ["sheet"],
4548
4566
  "Show the user a sheet and select a range on it.",
4549
- { sheet: M, range: _("A1 notation to select. Omit to only switch sheets.") },
4567
+ { sheet: M, range: A("A1 notation to select. Omit to only switch sheets.") },
4550
4568
  [],
4551
4569
  G
4552
4570
  )
4553
- ], ls = [
4571
+ ], ds = [
4554
4572
  b(
4555
4573
  "word.replaceParagraph",
4556
4574
  ["word"],
4557
4575
  "Rewrite one whole paragraph, keeping its style. This is the verb for shortening or rephrasing something; call it once per paragraph.",
4558
4576
  {
4559
- at: A("The offset the paragraph starts at, exactly as `inspect` prints it."),
4560
- text: _("The new text for that paragraph. A newline starts a further paragraph.")
4577
+ at: _("The offset the paragraph starts at, exactly as `inspect` prints it."),
4578
+ text: A("The new text for that paragraph. A newline starts a further paragraph.")
4561
4579
  },
4562
4580
  ["at", "text"],
4563
4581
  T
@@ -4567,9 +4585,9 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4567
4585
  ["word"],
4568
4586
  "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.",
4569
4587
  {
4570
- start: A("Character offset where the replaced text starts, as `inspect` reports offsets."),
4571
- end: A("Character offset just past the last character to replace."),
4572
- text: _("The replacement text. A newline starts a new paragraph.")
4588
+ start: _("Character offset where the replaced text starts, as `inspect` reports offsets."),
4589
+ end: _("Character offset just past the last character to replace."),
4590
+ text: A("The replacement text. A newline starts a new paragraph.")
4573
4591
  },
4574
4592
  ["start", "end", "text"],
4575
4593
  T
@@ -4579,8 +4597,8 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4579
4597
  ["word"],
4580
4598
  "Insert text at a character offset, without removing anything.",
4581
4599
  {
4582
- index: A("Character offset, as `inspect` reports offsets."),
4583
- text: _("The text to insert.")
4600
+ index: _("Character offset, as `inspect` reports offsets."),
4601
+ text: A("The text to insert.")
4584
4602
  },
4585
4603
  ["index", "text"],
4586
4604
  T
@@ -4589,7 +4607,7 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4589
4607
  "word.appendText",
4590
4608
  ["word"],
4591
4609
  "Add text at the end of the document.",
4592
- { text: _("The text to append.") },
4610
+ { text: A("The text to append.") },
4593
4611
  ["text"],
4594
4612
  T
4595
4613
  ),
@@ -4598,8 +4616,8 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4598
4616
  ["word"],
4599
4617
  "Start a new paragraph, optionally with text in it.",
4600
4618
  {
4601
- text: _("Paragraph text. Newlines start further paragraphs."),
4602
- index: A("Character offset to insert at. Omit for the end of the document.")
4619
+ text: A("Paragraph text. Newlines start further paragraphs."),
4620
+ index: _("Character offset to insert at. Omit for the end of the document.")
4603
4621
  },
4604
4622
  [],
4605
4623
  T
@@ -4608,19 +4626,19 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4608
4626
  "word.setSelection",
4609
4627
  ["word"],
4610
4628
  "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.",
4611
- { start: A("Start character offset."), end: A("End character offset. Omit for a caret.") },
4629
+ { start: _("Start character offset."), end: _("End character offset. Omit for a caret.") },
4612
4630
  ["start"],
4613
4631
  G
4614
4632
  )
4615
- ], us = [
4633
+ ], fs = [
4616
4634
  b(
4617
4635
  "slides.setText",
4618
4636
  ["slides"],
4619
4637
  "Replace the text of one shape. Written on save; not visible before that, and not undoable.",
4620
4638
  {
4621
4639
  slide: Ct,
4622
- element: _("Element id, as `inspect` reports it."),
4623
- text: _("The new text.")
4640
+ element: A("Element id, as `inspect` reports it."),
4641
+ text: A("The new text.")
4624
4642
  },
4625
4643
  ["slide", "element", "text"],
4626
4644
  re
@@ -4631,33 +4649,33 @@ const G = { undoable: !1, visible: !0 }, T = { undoable: !0, visible: !0 }, Nt =
4631
4649
  "Move or resize one shape. Only the values you pass change. Written on save; not visible before that, and not undoable.",
4632
4650
  {
4633
4651
  slide: Ct,
4634
- element: _("Element id."),
4635
- left: A("Distance from the left edge, in pixels."),
4636
- top: A("Distance from the top edge, in pixels."),
4637
- width: A("Width in pixels."),
4638
- height: A("Height in pixels.")
4652
+ element: A("Element id."),
4653
+ left: _("Distance from the left edge, in pixels."),
4654
+ top: _("Distance from the top edge, in pixels."),
4655
+ width: _("Width in pixels."),
4656
+ height: _("Height in pixels.")
4639
4657
  },
4640
4658
  ["slide", "element"],
4641
4659
  re
4642
4660
  )
4643
4661
  ], Sn = [
4644
- ...as,
4645
- ...cs,
4646
4662
  ...ls,
4647
- ...us
4663
+ ...us,
4664
+ ...ds,
4665
+ ...fs
4648
4666
  ];
4649
- function Cf(e) {
4667
+ function Uf(e) {
4650
4668
  return Sn.filter((t) => t.kinds.includes(e));
4651
4669
  }
4652
- function Nf(e) {
4670
+ function Ff(e) {
4653
4671
  return Sn.find((t) => t.op === e);
4654
4672
  }
4655
- const xt = /(?: {2,}|\\)$/, ds = /^\*\*([^*]+)\*\*\s+(.*)$/;
4656
- function $t(e) {
4657
- const t = ds.exec(e);
4673
+ const xt = /(?: {2,}|\\)$/, ps = /^\*\*([^*]+)\*\*\s+(.*)$/;
4674
+ function Dt(e) {
4675
+ const t = ps.exec(e);
4658
4676
  return t ? { lead: t[1], text: t[2] } : { text: e };
4659
4677
  }
4660
- function xf(e) {
4678
+ function jf(e) {
4661
4679
  const t = (e ?? "").replace(/\r\n/g, `
4662
4680
  `).split(`
4663
4681
  `), n = [];
@@ -4665,7 +4683,7 @@ function xf(e) {
4665
4683
  const o = () => {
4666
4684
  r && n.push({ type: "list", style: r.style, items: r.items }), r = null;
4667
4685
  }, i = (f, p) => {
4668
- r && r.style !== f && o(), r ? r.items.push($t(p)) : r = { style: f, items: [$t(p)] };
4686
+ r && r.style !== f && o(), r ? r.items.push(Dt(p)) : r = { style: f, items: [Dt(p)] };
4669
4687
  };
4670
4688
  let s = [], a = [];
4671
4689
  const l = () => {
@@ -4736,27 +4754,27 @@ function xf(e) {
4736
4754
  }
4737
4755
  return d(), n;
4738
4756
  }
4739
- function $f(e, t) {
4757
+ function Bf(e, t) {
4740
4758
  return ar(e, t).replace(/^```.*$/gm, "").replace(/^\|[\s:|-]*\|$/gm, "").replace(/[ \t]*\|[ \t]*/g, " ").replace(/^[ \t]*(#{1,6}|>|[-*+]|\d+\.)[ \t]+/gm, "").replace(/!\[([^\]]*)\]\([^)]*\)/g, "$1").replace(/\[([^\]]+)\]\([^)]*\)/g, "$1").replace(/(\*\*|__|\*|_|`|~~)/g, "").replace(/[ \t]+$/gm, "").replace(/\n{3,}/g, `
4741
4759
 
4742
4760
  `).trim();
4743
4761
  }
4744
- const Df = "documents.describe", Rf = "documents.inspect", Lf = "documents.apply";
4745
- function Pf(e) {
4762
+ const Hf = "documents.describe", Gf = "documents.inspect", Wf = "documents.apply";
4763
+ function Vf(e) {
4746
4764
  const t = e.indexOf(":");
4747
4765
  if (t !== -1) return e.slice(0, t);
4748
4766
  const n = e.indexOf(".");
4749
4767
  return n === -1 ? e : e.slice(0, n);
4750
4768
  }
4751
- const Kf = "installation-id";
4752
- function Uf(e) {
4769
+ const zf = "installation-id";
4770
+ function Yf(e) {
4753
4771
  const t = [];
4754
4772
  for (const n of Object.keys(e))
4755
4773
  for (const r of Object.keys(e[n]))
4756
4774
  t.push({ lang: n, key: r, value: e[n][r] });
4757
4775
  return t;
4758
4776
  }
4759
- const Ff = "notification-source", jf = (e, t) => `${e}.pref.${t}`, Bf = {
4777
+ const Xf = "notification-source", qf = (e, t) => `${e}.pref.${t}`, Qf = {
4760
4778
  ai: [
4761
4779
  "account.read",
4762
4780
  "account.write",
@@ -4896,48 +4914,48 @@ const Ff = "notification-source", jf = (e, t) => `${e}.pref.${t}`, Bf = {
4896
4914
  time: ["entry.read", "entry.write", "work-type.read", "work-type.write"],
4897
4915
  user: ["user.read", "user.write"],
4898
4916
  work: ["item.read", "item.write", "project.read", "project.write"]
4899
- }, Tn = 9e4, fs = ["out_of_office"], In = (e) => fs.includes(e);
4900
- function Hf(e, t, n) {
4917
+ }, Tn = 9e4, ms = ["out_of_office"], In = (e) => ms.includes(e);
4918
+ function Jf(e, t, n) {
4901
4919
  const r = n - e < Tn, o = t?.status && (!t.expiresAt || t.expiresAt > n) ? t : void 0;
4902
4920
  if (!o?.status) return { online: r, status: r ? "available" : "offline" };
4903
4921
  const i = o.status;
4904
4922
  return !r && !In(i) ? { online: !1, status: "offline" } : { online: r, status: i, message: o.message };
4905
4923
  }
4906
- function Gf(e, t) {
4924
+ function Zf(e, t) {
4907
4925
  const n = t - e.lastSeenAt < Tn, r = n || In(e.status) ? e.status : "offline";
4908
4926
  return n === e.online && r === e.status ? e : { ...e, online: n, status: r };
4909
4927
  }
4910
- function Wf(e, t) {
4928
+ function ep(e, t) {
4911
4929
  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 };
4912
4930
  }
4913
- function Vf(e) {
4931
+ function tp(e) {
4914
4932
  return e.providerAvailable && e.allowed;
4915
4933
  }
4916
- const zf = "resources.describe", Xf = "resources.search", Yf = "resources.resolve", qf = "resources.attached";
4917
- function Qf(e) {
4934
+ const np = "resources.describe", rp = "resources.search", op = "resources.resolve", ip = "resources.attached";
4935
+ function sp(e) {
4918
4936
  const t = e.indexOf(":");
4919
4937
  return t === -1 ? e : e.slice(0, t);
4920
4938
  }
4921
- const Jf = "/provider/scope/related", Zf = "/provider/scope/read", ep = "/provider/scope/acts", vn = "auth";
4939
+ const ap = "/provider/scope/related", cp = "/provider/scope/read", lp = "/provider/scope/acts", vn = "auth";
4922
4940
  function kn(e) {
4923
4941
  const t = typeof e == "string" ? e.match(/apps\/([^/?#]+)/) : null;
4924
4942
  return t ? t[1] : null;
4925
4943
  }
4926
- function tp(e) {
4944
+ function up(e) {
4927
4945
  const t = kn(e);
4928
4946
  return t ? t !== vn : typeof e == "string" && e.startsWith("/wake");
4929
4947
  }
4930
- function np(e) {
4948
+ function dp(e) {
4931
4949
  return typeof e != "string" || e === "" || e === "/" ? !0 : kn(e) === vn;
4932
4950
  }
4933
- function ps(e) {
4951
+ function hs(e) {
4934
4952
  return e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
4935
4953
  }
4936
- function ms(e) {
4937
- const n = e.split("/").filter(Boolean).map((r) => r.startsWith(":") ? r.endsWith("?") ? "(?:/[^/]+)?" : "/[^/]+" : `/${ps(r)}`).join("");
4954
+ function gs(e) {
4955
+ const n = e.split("/").filter(Boolean).map((r) => r.startsWith(":") ? r.endsWith("?") ? "(?:/[^/]+)?" : "/[^/]+" : `/${hs(r)}`).join("");
4938
4956
  return new RegExp(`^${n}\\/?$`);
4939
4957
  }
4940
- function hs(e, t) {
4958
+ function ys(e, t) {
4941
4959
  const n = e.split("/").filter(Boolean), r = t.split("/").filter(Boolean), o = {};
4942
4960
  return n.forEach((i, s) => {
4943
4961
  if (i.startsWith(":")) {
@@ -4946,14 +4964,14 @@ function hs(e, t) {
4946
4964
  }
4947
4965
  }), o;
4948
4966
  }
4949
- function gs(e) {
4967
+ function bs(e) {
4950
4968
  return e.publicBasePath ?? `/apps/${e.name}`;
4951
4969
  }
4952
- function rp(e) {
4970
+ function fp(e) {
4953
4971
  const t = [];
4954
4972
  for (const n of e) {
4955
4973
  if (!n?.name) continue;
4956
- const r = gs(n);
4974
+ const r = bs(n);
4957
4975
  for (const o of n.routes ?? []) {
4958
4976
  if (!o.public) continue;
4959
4977
  const i = o.path === "/" ? "" : o.path;
@@ -4967,7 +4985,7 @@ function rp(e) {
4967
4985
  }
4968
4986
  return t;
4969
4987
  }
4970
- function ys(e, t) {
4988
+ function _s(e, t) {
4971
4989
  const n = e.split("/").filter(Boolean), r = t.split("/").filter(Boolean);
4972
4990
  for (let o = 0; o < Math.min(n.length, r.length); o++) {
4973
4991
  const i = n[o].startsWith(":"), s = r[o].startsWith(":");
@@ -4975,35 +4993,35 @@ function ys(e, t) {
4975
4993
  }
4976
4994
  return n.length > r.length;
4977
4995
  }
4978
- function bs(e, t) {
4996
+ function As(e, t) {
4979
4997
  if (typeof e != "string") return null;
4980
4998
  let n = null;
4981
4999
  for (const r of t)
4982
- ms(r.pattern).test(e) && (!n || ys(r.pattern, n.pattern)) && (n = r);
4983
- return n ? { ...n, params: { ...n.props, ...hs(n.pattern, e) } } : null;
5000
+ gs(r.pattern).test(e) && (!n || _s(r.pattern, n.pattern)) && (n = r);
5001
+ return n ? { ...n, params: { ...n.props, ...ys(n.pattern, e) } } : null;
4984
5002
  }
4985
- function op(e, t) {
4986
- return bs(e, t) !== null;
5003
+ function pp(e, t) {
5004
+ return As(e, t) !== null;
4987
5005
  }
4988
- const ip = 10 * 1024 * 1024, sp = 25 * 1024 * 1024, ap = "sync-target", cp = 20;
5006
+ const mp = 10 * 1024 * 1024, hp = 25 * 1024 * 1024, gp = "sync-target", yp = 20;
4989
5007
  function wn(e, t) {
4990
5008
  const n = Array.isArray(t) ? t.find((r) => r.name === e.name)?.policy : void 0;
4991
5009
  return n ? n !== "read" : e.access ? e.access !== "read" : !0;
4992
5010
  }
4993
- function As(e, t, n) {
5011
+ function Es(e, t, n) {
4994
5012
  return wn(e, n) ? t.guarded === "all" || t.guarded?.has(e.name) ? !0 : t.autonomy === "auto" ? !1 : t.autonomy === "outward" ? En(e) : !0 : !1;
4995
5013
  }
4996
- function _s(e) {
5014
+ function Ss(e) {
4997
5015
  return e.produces === "draft";
4998
5016
  }
4999
- function lp(e, t) {
5017
+ function bp(e, t) {
5000
5018
  if (t.allowed) {
5001
5019
  const n = t.personalTools === "allow" && e.personal === !0;
5002
5020
  if (!t.allowed.has(e.name) && !n) return "hidden";
5003
5021
  }
5004
- return t.narrow && !t.narrow.has(e.name) || !t.attended && (e.personal === !0 || e.surface === "interactive") || t.readOnly && e.access !== "read" || t.mode === "ask" && wn(e) || t.mode === "draft" && (En(e) || e.access !== "read" && !_s(e)) ? "hidden" : t.gate && As(e, t.gate, t.policy) ? "held" : "free";
5022
+ return t.narrow && !t.narrow.has(e.name) || !t.attended && (e.personal === !0 || e.surface === "interactive") || t.readOnly && e.access !== "read" || t.mode === "ask" && wn(e) || t.mode === "draft" && (En(e) || e.access !== "read" && !Ss(e)) ? "hidden" : t.gate && Es(e, t.gate, t.policy) ? "held" : "free";
5005
5023
  }
5006
- const Es = {
5024
+ const Ts = {
5007
5025
  afrikaans: [
5008
5026
  "[Muziek]",
5009
5027
  "(C) TV GELDERLAND 2021",
@@ -5153,14 +5171,14 @@ const Es = {
5153
5171
  "[MÚSICA]",
5154
5172
  "[Music cuts in British]"
5155
5173
  ]
5156
- }, Ss = (e) => {
5174
+ }, Is = (e) => {
5157
5175
  let t = e;
5158
- return Object.values(Es).forEach((n) => {
5176
+ return Object.values(Ts).forEach((n) => {
5159
5177
  n.forEach((r) => {
5160
5178
  t = t.replaceAll(r, "");
5161
5179
  });
5162
5180
  }), t = t.replace(/\(.*?\)/g, ""), t = t.replace(/\[.*?\]/g, ""), t;
5163
- }, Ts = 6e4, Is = 8e3, vs = 2, ks = 0.4, ws = 3, Ms = /* @__PURE__ */ new Set([
5181
+ }, vs = 6e4, ks = 8e3, ws = 2, Ms = 0.4, Os = 3, Cs = /* @__PURE__ */ new Set([
5164
5182
  "aan",
5165
5183
  "als",
5166
5184
  "ben",
@@ -5273,13 +5291,13 @@ const Es = {
5273
5291
  "you",
5274
5292
  "your"
5275
5293
  ]);
5276
- function Os(e) {
5294
+ function Ns(e) {
5277
5295
  const t = /* @__PURE__ */ new Set();
5278
5296
  for (const n of e.toLowerCase().split(/[^a-z0-9À-ɏ]+/))
5279
- n.length < ws || Ms.has(n) || t.add(n);
5297
+ n.length < Os || Cs.has(n) || t.add(n);
5280
5298
  return [...t];
5281
5299
  }
5282
- function Cs(e, t) {
5300
+ function xs(e, t) {
5283
5301
  if (!e.length) return 0;
5284
5302
  if (!t.length) return 1;
5285
5303
  const n = new Set(t), r = new Set(e);
@@ -5287,32 +5305,32 @@ function Cs(e, t) {
5287
5305
  for (const i of r) n.has(i) || (o += 1);
5288
5306
  return o / r.size;
5289
5307
  }
5290
- function Ns(e, t = Ts) {
5308
+ function Ds(e, t = vs) {
5291
5309
  const n = e.filter((s) => !s.partial && typeof s.text == "string");
5292
5310
  if (!n.length) return { text: "", segmentCount: 0 };
5293
5311
  const o = n.reduce((s, a) => Math.max(s, a.endedAt ?? 0), 0) - t;
5294
- return { text: n.filter((s) => (s.endedAt ?? 0) >= o).map((s) => Ss(s.text).trim()).filter(Boolean).join(" ").replace(/\s+/g, " ").trim(), segmentCount: n.length };
5312
+ return { text: n.filter((s) => (s.endedAt ?? 0) >= o).map((s) => Is(s.text).trim()).filter(Boolean).join(" ").replace(/\s+/g, " ").trim(), segmentCount: n.length };
5295
5313
  }
5296
- const xs = 60;
5297
- function up(e, t, n = xs) {
5314
+ const Rs = 60;
5315
+ function _p(e, t, n = Rs) {
5298
5316
  const r = new Set(e), o = [...e];
5299
5317
  for (const i of t)
5300
5318
  !i || r.has(i) || (r.add(i), o.push(i));
5301
5319
  return o.slice(-n);
5302
5320
  }
5303
- function dp(e) {
5321
+ function Ap(e) {
5304
5322
  const { segments: t, now: n, state: r } = e;
5305
- if (r.lastTriggerAt && n - r.lastTriggerAt < Is)
5323
+ if (r.lastTriggerAt && n - r.lastTriggerAt < ks)
5306
5324
  return { trigger: !1, reason: "too_soon" };
5307
- const o = Ns(t, e.windowMs);
5325
+ const o = Ds(t, e.windowMs);
5308
5326
  if (!o.text) return { trigger: !1, reason: "no_speech" };
5309
5327
  const i = o.segmentCount - (r.lastSegmentCount ?? 0);
5310
- if (r.lastQueryTerms && i < vs)
5328
+ if (r.lastQueryTerms && i < ws)
5311
5329
  return { trigger: !1, reason: "too_few_new" };
5312
- const s = Os(o.text);
5313
- return s.length ? r.lastQueryTerms?.length && Cs(s, r.lastQueryTerms) < ks ? { trigger: !1, reason: "same_topic" } : { trigger: !0, text: o.text, terms: s, segmentCount: o.segmentCount } : { trigger: !1, reason: "no_speech" };
5330
+ const s = Ns(o.text);
5331
+ return s.length ? r.lastQueryTerms?.length && xs(s, r.lastQueryTerms) < Ms ? { trigger: !1, reason: "same_topic" } : { trigger: !0, text: o.text, terms: s, segmentCount: o.segmentCount } : { trigger: !1, reason: "no_speech" };
5314
5332
  }
5315
- const fp = [
5333
+ const Ep = [
5316
5334
  "personal",
5317
5335
  "organization",
5318
5336
  "connections",
@@ -5320,7 +5338,7 @@ const fp = [
5320
5338
  "work",
5321
5339
  "administration",
5322
5340
  "ai"
5323
- ], pp = "navNotice", Xe = {
5341
+ ], Sp = "navNotice", Ye = {
5324
5342
  // The lower bounds are deliberately generous: service ranges (0800/0900) are
5325
5343
  // shorter than geographic numbers, and a too-strict minimum silently drops them.
5326
5344
  // An over-permissive key is harmless — it simply matches nothing.
@@ -5343,38 +5361,38 @@ const fp = [
5343
5361
  PL: { callingCode: "48", nsnMin: 9, nsnMax: 9 },
5344
5362
  US: { callingCode: "1", nsnMin: 10, nsnMax: 10 },
5345
5363
  CA: { callingCode: "1", nsnMin: 10, nsnMax: 10 }
5346
- }, $s = "NL", Ds = 15, Rs = 8, Ls = Array.from(
5347
- new Set(Object.values(Xe).map((e) => e.callingCode))
5364
+ }, $s = "NL", Ls = 15, Ps = 8, Ks = Array.from(
5365
+ new Set(Object.values(Ye).map((e) => e.callingCode))
5348
5366
  ).sort((e, t) => t.length - e.length);
5349
- function Dt(e) {
5367
+ function Rt(e) {
5350
5368
  if (e)
5351
- return Xe[e.trim().toUpperCase()];
5369
+ return Ye[e.trim().toUpperCase()];
5352
5370
  }
5353
5371
  function te(e, t) {
5354
5372
  return e.length >= t.nsnMin && e.length <= t.nsnMax;
5355
5373
  }
5356
- function Rt(e) {
5357
- if (e.length > Ds) return null;
5358
- for (const t of Ls) {
5374
+ function $t(e) {
5375
+ if (e.length > Ls) return null;
5376
+ for (const t of Ks) {
5359
5377
  if (!e.startsWith(t)) continue;
5360
5378
  const n = e.slice(t.length);
5361
- for (const r of Object.values(Xe)) {
5379
+ for (const r of Object.values(Ye)) {
5362
5380
  if (r.callingCode !== t) continue;
5363
5381
  const o = r.trunkPrefix, i = o && n.startsWith(o) ? n.slice(o.length) : n;
5364
5382
  if (te(i, r)) return `+${t}${i}`;
5365
5383
  }
5366
5384
  return null;
5367
5385
  }
5368
- return e.length < Rs ? null : `+${e}`;
5386
+ return e.length < Ps ? null : `+${e}`;
5369
5387
  }
5370
- function Ps(e) {
5388
+ function Us(e) {
5371
5389
  let t = e.trim();
5372
5390
  const n = t.match(/^(sips?|tel|whatsapp):/i);
5373
5391
  n && (t = t.slice(n[0].length));
5374
5392
  const r = t.indexOf("@");
5375
5393
  return r >= 0 && (t = t.slice(0, r)), t.trim();
5376
5394
  }
5377
- function mp(e) {
5395
+ function Tp(e) {
5378
5396
  if (!e) return !1;
5379
5397
  const t = e.indexOf("@");
5380
5398
  if (t <= 0) return !1;
@@ -5383,13 +5401,13 @@ function mp(e) {
5383
5401
  }
5384
5402
  function Lt(e, t) {
5385
5403
  if (!e) return null;
5386
- const n = Ps(e);
5404
+ const n = Us(e);
5387
5405
  if (!n) return null;
5388
5406
  const r = n.startsWith("+"), o = n.replace(/\D/g, "");
5389
5407
  if (!o) return null;
5390
- if (r) return Rt(o);
5391
- if (o.startsWith("00")) return Rt(o.slice(2));
5392
- const i = Dt(t) ?? Dt($s);
5408
+ if (r) return $t(o);
5409
+ if (o.startsWith("00")) return $t(o.slice(2));
5410
+ const i = Rt(t) ?? Rt($s);
5393
5411
  if (!i) return null;
5394
5412
  const s = i.trunkPrefix;
5395
5413
  if (s && o.startsWith(s)) {
@@ -5402,7 +5420,7 @@ function Lt(e, t) {
5402
5420
  }
5403
5421
  return !s && te(o, i) ? `+${i.callingCode}${o}` : null;
5404
5422
  }
5405
- function hp(e, t = 9) {
5423
+ function Ip(e, t = 9) {
5406
5424
  const n = (e ?? "").replace(/\D/g, "");
5407
5425
  return n.length < t ? null : n.slice(-t);
5408
5426
  }
@@ -5413,11 +5431,11 @@ function Mn(e) {
5413
5431
  const r = t.slice(0, n).split("+")[0], o = t.slice(n + 1);
5414
5432
  return !r || !o.includes(".") ? null : `${r}@${o}`;
5415
5433
  }
5416
- function gp(e) {
5434
+ function vp(e) {
5417
5435
  const t = Mn(e);
5418
5436
  return t ? t.slice(t.lastIndexOf("@") + 1) : null;
5419
5437
  }
5420
- const Ks = /* @__PURE__ */ new Set([
5438
+ const Fs = /* @__PURE__ */ new Set([
5421
5439
  "co.uk",
5422
5440
  "org.uk",
5423
5441
  "gov.uk",
@@ -5427,14 +5445,14 @@ const Ks = /* @__PURE__ */ new Set([
5427
5445
  "com.br",
5428
5446
  "co.za"
5429
5447
  ]);
5430
- function Us(e) {
5448
+ function js(e) {
5431
5449
  if (!e) return null;
5432
5450
  const t = e.trim().toLowerCase().replace(/\.$/, "").split(".").filter(Boolean);
5433
5451
  if (t.length < 2) return null;
5434
5452
  const n = t.slice(-2).join(".");
5435
- return Ks.has(n) && t.length >= 3 ? t.slice(-3).join(".") : n;
5453
+ return Fs.has(n) && t.length >= 3 ? t.slice(-3).join(".") : n;
5436
5454
  }
5437
- const Fs = /* @__PURE__ */ new Set([
5455
+ const Bs = /* @__PURE__ */ new Set([
5438
5456
  "gmail.com",
5439
5457
  "googlemail.com",
5440
5458
  "outlook.com",
@@ -5479,16 +5497,16 @@ const Fs = /* @__PURE__ */ new Set([
5479
5497
  "proximus.be",
5480
5498
  "scarlet.be"
5481
5499
  ]);
5482
- function yp(e) {
5483
- const t = Us(e);
5484
- return t ? Fs.has(t) : !1;
5500
+ function kp(e) {
5501
+ const t = js(e);
5502
+ return t ? Bs.has(t) : !1;
5485
5503
  }
5486
- function bp(e) {
5504
+ function wp(e) {
5487
5505
  if (!e) return !1;
5488
5506
  const t = e.trim().toLowerCase();
5489
5507
  return t === "tel" || t === "sms" || t === "whatsapp" || t === "fax";
5490
5508
  }
5491
- function Ap(e, t, n) {
5509
+ function Mp(e, t, n) {
5492
5510
  if (!e || !t) return null;
5493
5511
  const r = e.trim().toLowerCase();
5494
5512
  if (r === "tel" || r === "sms" || r === "whatsapp") {
@@ -5506,7 +5524,7 @@ function Ap(e, t, n) {
5506
5524
  const o = t.trim().toLowerCase();
5507
5525
  return o ? `${r}:${o}` : null;
5508
5526
  }
5509
- const js = [
5527
+ const Hs = [
5510
5528
  /<blockquote/i,
5511
5529
  /class="?gmail_quote/i,
5512
5530
  // Gmail quote container
@@ -5519,72 +5537,72 @@ const js = [
5519
5537
  // Outlook underscore separator before "From:"
5520
5538
  /\bOn\b[\s\S]{0,200}?\bwrote:/i
5521
5539
  // Gmail "On <date> <name> wrote:"
5522
- ], Pt = /^\s*(?:>+\s*)?(?:from|van|sent|verzonden|to|aan|cc|subject|onderwerp|date|datum)\s*:/i, Bs = /^\s*(?:on|op)\b.{0,200}?\b(?:wrote|schreef|geschreven)\s*:?\s*$/i;
5523
- function Hs(e) {
5540
+ ], Pt = /^\s*(?:>+\s*)?(?:from|van|sent|verzonden|to|aan|cc|subject|onderwerp|date|datum)\s*:/i, Gs = /^\s*(?:on|op)\b.{0,200}?\b(?:wrote|schreef|geschreven)\s*:?\s*$/i;
5541
+ function Ws(e) {
5524
5542
  const t = e.split(`
5525
5543
  `);
5526
5544
  for (let n = 0; n < t.length; n++)
5527
- if (Bs.test(t[n]) || Pt.test(t[n]) && t.slice(n + 1, n + 4).some((r) => Pt.test(r)))
5545
+ if (Gs.test(t[n]) || Pt.test(t[n]) && t.slice(n + 1, n + 4).some((r) => Pt.test(r)))
5528
5546
  return t.slice(0, n).join(`
5529
5547
  `).trim();
5530
5548
  return e;
5531
5549
  }
5532
- const Gs = /^(?:https?:|mailto:|tel:)/i, Ws = /^(?:https?:|cid:|data:image\/)/i;
5550
+ const Vs = /^(?:https?:|mailto:|tel:)/i, zs = /^(?:https?:|cid:|data:image\/)/i;
5533
5551
  function be(e, t) {
5534
5552
  const n = e.match(new RegExp(`\\b${t}\\s*=\\s*(?:"([^"]*)"|'([^']*)'|([^\\s">]+))`, "i"));
5535
5553
  return (n?.[1] ?? n?.[2] ?? n?.[3] ?? "").trim();
5536
5554
  }
5537
- const Vs = /(!\[[^\]]*\]\([^)]*\))/;
5555
+ const Ys = /(!\[[^\]]*\]\([^)]*\))/;
5538
5556
  function Kt(e) {
5539
- return e.replace(/\s+/g, " ").trim().split(Vs).map((t, n) => n % 2 === 1 ? t : t.replace(/[[\]]/g, "\\$&")).join("");
5557
+ return e.replace(/\s+/g, " ").trim().split(Ys).map((t, n) => n % 2 === 1 ? t : t.replace(/[[\]]/g, "\\$&")).join("");
5540
5558
  }
5541
- function Ae(e) {
5559
+ function _e(e) {
5542
5560
  return e.replace(
5543
5561
  /[()\s<>"]/g,
5544
5562
  (t) => `%${t.charCodeAt(0).toString(16).toUpperCase().padStart(2, "0")}`
5545
5563
  );
5546
5564
  }
5547
- function zs(e) {
5565
+ function Xs(e) {
5548
5566
  return e.replace(/<img\b([^>]*?)\/?>/gi, (n, r) => {
5549
5567
  const o = be(r, "src");
5550
- return Ws.test(o) ? `![${Kt(be(r, "alt"))}](${Ae(o)})` : "";
5568
+ return zs.test(o) ? `![${Kt(be(r, "alt"))}](${_e(o)})` : "";
5551
5569
  }).replace(
5552
5570
  /<a\b([^>]*)>([\s\S]*?)<\/a\s*>/gi,
5553
5571
  (n, r, o) => {
5554
5572
  const i = Kt(o.replace(/<[^>]*>/g, "")), s = be(r, "href");
5555
- return Gs.test(s) ? `[${i || Ae(s)}](${Ae(s)})` : i;
5573
+ return Vs.test(s) ? `[${i || _e(s)}](${_e(s)})` : i;
5556
5574
  }
5557
5575
  );
5558
5576
  }
5559
- const Xs = /<table\b[^>]*>((?:(?!<table\b)[\s\S])*?)<\/table\s*>/i, Ys = /<tr\b[^>]*>([\s\S]*?)<\/tr\s*>/gi, qs = /<(t[dh])\b([^>]*)>([\s\S]*?)<\/\1\s*>/gi;
5560
- function Qs(e, t) {
5577
+ const qs = /<table\b[^>]*>((?:(?!<table\b)[\s\S])*?)<\/table\s*>/i, Qs = /<tr\b[^>]*>([\s\S]*?)<\/tr\s*>/gi, Js = /<(t[dh])\b([^>]*)>([\s\S]*?)<\/\1\s*>/gi;
5578
+ function Zs(e, t) {
5561
5579
  return /<table\b/i.test(e) || e.includes(`
5562
5580
 
5563
5581
  |`) || t.includes("![") || t.length > 200;
5564
5582
  }
5565
- const Js = 40, Zs = { left: "---", center: ":---:", right: "---:" };
5566
- function ea(e) {
5583
+ const ea = 40, ta = { left: "---", center: ":---:", right: "---:" };
5584
+ function na(e) {
5567
5585
  const t = e.match(/align\s*[=:]\s*["']?\s*(right|center)/i);
5568
5586
  return t ? t[1].toLowerCase() : "left";
5569
5587
  }
5570
- function ta(e) {
5588
+ function ra(e) {
5571
5589
  return e.replace(/<[^>]*>/g, "").replace(/\s+/g, " ").trim().replace(/\|/g, "\\|");
5572
5590
  }
5573
- function na(e) {
5591
+ function oa(e) {
5574
5592
  const t = [];
5575
- for (const s of e.matchAll(Ys)) {
5593
+ for (const s of e.matchAll(Qs)) {
5576
5594
  const a = [];
5577
- for (const l of s[1].matchAll(qs)) {
5578
- const c = ta(l[3]);
5579
- if (Qs(l[3], c)) return null;
5580
- a.push({ text: c, align: ea(l[2]) });
5595
+ for (const l of s[1].matchAll(Js)) {
5596
+ const c = ra(l[3]);
5597
+ if (Zs(l[3], c)) return null;
5598
+ a.push({ text: c, align: na(l[2]) });
5581
5599
  }
5582
5600
  if (a.length === 0) return null;
5583
5601
  a.some((l) => l.text !== "") && t.push(a);
5584
5602
  }
5585
5603
  const n = t[0]?.length ?? 0;
5586
5604
  if (t.length < 2 || n < 2 || t.some((s) => s.length !== n)) return null;
5587
- const r = (s) => `| ${s.map((a) => a.text).join(" | ")} |`, o = t[1].map((s) => Zs[s.align]).join(" | "), i = t.slice(1).map(r).join(`
5605
+ const r = (s) => `| ${s.map((a) => a.text).join(" | ")} |`, o = t[1].map((s) => ta[s.align]).join(" | "), i = t.slice(1).map(r).join(`
5588
5606
  `);
5589
5607
  return `
5590
5608
 
@@ -5594,18 +5612,18 @@ ${i}
5594
5612
 
5595
5613
  `;
5596
5614
  }
5597
- function ra(e) {
5615
+ function ia(e) {
5598
5616
  return e.replace(/<\/(t[dh])\s*>/gi, " ").replace(/<\/tr\s*>/gi, `
5599
5617
  `).replace(/<(?:tbody|thead|tfoot|caption|colgroup|col|tr|t[dh])\b[^>]*>/gi, "").replace(/<\/(?:tbody|thead|tfoot|caption|colgroup)\s*>/gi, "");
5600
5618
  }
5601
- function oa(e) {
5619
+ function sa(e) {
5602
5620
  let t = e;
5603
- for (let n = 0; n < Js; n++) {
5604
- const r = Xs.exec(t);
5621
+ for (let n = 0; n < ea; n++) {
5622
+ const r = qs.exec(t);
5605
5623
  if (!r || r.index === void 0) break;
5606
- const i = na(r[1]) ?? `
5624
+ const i = oa(r[1]) ?? `
5607
5625
 
5608
- ${ra(r[1])}
5626
+ ${ia(r[1])}
5609
5627
 
5610
5628
  `;
5611
5629
  t = t.slice(0, r.index) + i + t.slice(r.index + r[0].length);
@@ -5615,7 +5633,7 @@ ${ra(r[1])}
5615
5633
  function Ut(e, t) {
5616
5634
  let n = e;
5617
5635
  return n = n.replace(/<(script|style)[\s\S]*?<\/\1>/gi, ""), n = n.replace(/<!--[\s\S]*?-->/g, ""), n = n.replace(/<br\s*\/?>/gi, `
5618
- `), t && (n = oa(zs(n))), n = n.replace(/<\/(p|h[1-6]|ul|ol|table|blockquote)>/gi, `
5636
+ `), t && (n = sa(Xs(n))), n = n.replace(/<\/(p|h[1-6]|ul|ol|table|blockquote)>/gi, `
5619
5637
 
5620
5638
  `), n = n.replace(/<\/(div|li|tr)>/gi, `
5621
5639
  `), n = n.replace(/<\/(td|th)>/gi, " "), n = n.replace(/<[^>]+>/g, ""), n = n.replace(/<[^>]*$/, ""), n;
@@ -5623,7 +5641,7 @@ function Ut(e, t) {
5623
5641
  function Ft(e) {
5624
5642
  return !Number.isInteger(e) || e < 0 || e > 1114111 ? null : String.fromCodePoint(e);
5625
5643
  }
5626
- const ia = {
5644
+ const aa = {
5627
5645
  euro: "€",
5628
5646
  pound: "£",
5629
5647
  yen: "¥",
@@ -5646,7 +5664,7 @@ const ia = {
5646
5664
  apos: "'"
5647
5665
  };
5648
5666
  function jt(e) {
5649
- return e.replace(/&nbsp;/gi, " ").replace(/&([a-z]+);/gi, (t, n) => ia[n.toLowerCase()] ?? t).replace(/&lt;/gi, "<").replace(/&gt;/gi, ">").replace(/&quot;/gi, '"').replace(/&#(\d+);/g, (t, n) => Ft(Number(n)) ?? t).replace(/&#x([0-9a-f]+);/gi, (t, n) => Ft(parseInt(n, 16)) ?? t).replace(/&amp;/gi, "&");
5667
+ return e.replace(/&nbsp;/gi, " ").replace(/&([a-z]+);/gi, (t, n) => aa[n.toLowerCase()] ?? t).replace(/&lt;/gi, "<").replace(/&gt;/gi, ">").replace(/&quot;/gi, '"').replace(/&#(\d+);/g, (t, n) => Ft(Number(n)) ?? t).replace(/&#x([0-9a-f]+);/gi, (t, n) => Ft(parseInt(n, 16)) ?? t).replace(/&amp;/gi, "&");
5650
5668
  }
5651
5669
  function Bt(e) {
5652
5670
  return e.replace(/\r/g, "").replace(/[ \t]+/g, " ").replace(/ *\n */g, `
@@ -5654,41 +5672,41 @@ function Bt(e) {
5654
5672
 
5655
5673
  `).trim();
5656
5674
  }
5657
- const sa = /<\s*(html|body|div|p|table|br|span)\b/i;
5658
- function _p(e) {
5659
- return sa.test(e);
5675
+ const ca = /<\s*(html|body|div|p|table|br|span)\b/i;
5676
+ function Op(e) {
5677
+ return ca.test(e);
5660
5678
  }
5661
- function Ep(e) {
5679
+ function Cp(e) {
5662
5680
  return On(e, !1);
5663
5681
  }
5664
- function Sp(e) {
5682
+ function Np(e) {
5665
5683
  return On(e, !0);
5666
5684
  }
5667
5685
  function On(e, t) {
5668
5686
  if (typeof e != "string" || !e) return "";
5669
5687
  let n = e.length;
5670
- for (const s of js) {
5688
+ for (const s of Hs) {
5671
5689
  const a = e.search(s);
5672
5690
  a >= 0 && a < n && (n = a);
5673
5691
  }
5674
5692
  const r = e.slice(0, n);
5675
5693
  let o = Bt(jt(Ut(r, t)));
5676
- return o || (o = Bt(jt(Ut(e, t)))), Hs(o) || o;
5694
+ return o || (o = Bt(jt(Ut(e, t)))), Ws(o) || o;
5677
5695
  }
5678
5696
  export {
5679
- lc as ACTIVE_ASSIGNMENT_STATUSES,
5680
- D as ACTIVITY_CATALOG,
5681
- Zi as AI_ATTACHMENT_LIMITS,
5682
- tf as AI_ATTACHMENT_MAX_PER_TURN,
5683
- ef as AI_ATTACHMENT_TURN_BUDGET,
5697
+ dc as ACTIVE_ASSIGNMENT_STATUSES,
5698
+ R as ACTIVITY_CATALOG,
5699
+ ts as AI_ATTACHMENT_LIMITS,
5700
+ df as AI_ATTACHMENT_MAX_PER_TURN,
5701
+ uf as AI_ATTACHMENT_TURN_BUDGET,
5684
5702
  Ue as AI_CAPABILITIES,
5685
- rf as AI_TOOL_PROVIDER_GROUP,
5703
+ pf as AI_TOOL_PROVIDER_GROUP,
5686
5704
  Wt as AI_VENDORS,
5687
5705
  Zn as ALLOWED_LINK_SCHEMES,
5688
- Bf as APP_PERMISSIONS,
5689
- Yc as ARTICLE_SCOPE_KIND,
5706
+ Qf as APP_PERMISSIONS,
5707
+ ol as ARTICLE_SCOPE_KIND,
5690
5708
  at as ARTIFACT_MAX_BLOCKS,
5691
- nc as ARTIFACT_MAX_BODY_BYTES,
5709
+ oc as ARTIFACT_MAX_BODY_BYTES,
5692
5710
  Z as ARTIFACT_MAX_CELL_LEN,
5693
5711
  dt as ARTIFACT_MAX_KPI_ITEMS,
5694
5712
  ct as ARTIFACT_MAX_LIST_ITEMS,
@@ -5696,41 +5714,41 @@ export {
5696
5714
  lt as ARTIFACT_MAX_TABLE_ROWS,
5697
5715
  zt as ARTIFACT_MAX_TEXT_LEN,
5698
5716
  lr as ASSIGNMENT_SCOPE_KIND,
5699
- cf as ASSIST_BANDS,
5700
- af as ASSIST_SOURCE_PROVIDER_GROUP,
5701
- Pr as ATTENTION_STATUSES,
5702
- yi as AT_RISK_GAP,
5717
+ yf as ASSIST_BANDS,
5718
+ gf as ASSIST_SOURCE_PROVIDER_GROUP,
5719
+ Ur as ATTENTION_STATUSES,
5720
+ _i as AT_RISK_GAP,
5703
5721
  vn as AUTH_APP_NAME,
5704
- Uo as AUTO_READY_MIN_PROPOSALS,
5705
- Fo as AUTO_READY_RATE,
5722
+ jo as AUTO_READY_MIN_PROPOSALS,
5723
+ Bo as AUTO_READY_RATE,
5706
5724
  Fn as ActivityTypeRegistry,
5707
- Ia as BUILT_IN_ONLY,
5708
- Kr as BULK_PENALTY,
5709
- yc as BUSINESS_ENTITY_LIST_SERVICE,
5710
- Is as CADENCE_FLOOR_MS,
5711
- vs as CADENCE_MIN_NEW_SEGMENTS,
5712
- ks as CADENCE_MIN_NOVELTY,
5713
- Ts as CADENCE_WINDOW_MS,
5714
- Wl as CLASSIFY_VARS,
5715
- nd as CLEARABLE_FIELDS,
5716
- Mf as CONNECTOR_PROVIDER_GROUP,
5717
- Of as CONTEXT_COLLECT_SERVICE,
5718
- Wa as CORE_DIMENSIONS,
5719
- is as CommunicationScheme,
5720
- Mr as DAY_MS,
5721
- mi as DEFAULT_CHECK_IN_DAYS,
5722
- go as DEFAULT_FORECAST_WEEKS,
5723
- cl as DEFAULT_MEMORY_BUDGET,
5724
- md as DEFAULT_NUMBER_PADDING,
5725
+ ka as BUILT_IN_ONLY,
5726
+ Fr as BULK_PENALTY,
5727
+ _c as BUSINESS_ENTITY_LIST_SERVICE,
5728
+ ks as CADENCE_FLOOR_MS,
5729
+ ws as CADENCE_MIN_NEW_SEGMENTS,
5730
+ Ms as CADENCE_MIN_NOVELTY,
5731
+ vs as CADENCE_WINDOW_MS,
5732
+ eu as CLASSIFY_VARS,
5733
+ dd as CLEARABLE_FIELDS,
5734
+ Pf as CONNECTOR_PROVIDER_GROUP,
5735
+ Kf as CONTEXT_COLLECT_SERVICE,
5736
+ za as CORE_DIMENSIONS,
5737
+ as as CommunicationScheme,
5738
+ Cr as DAY_MS,
5739
+ gi as DEFAULT_CHECK_IN_DAYS,
5740
+ bo as DEFAULT_FORECAST_WEEKS,
5741
+ yl as DEFAULT_MEMORY_BUDGET,
5742
+ Td as DEFAULT_NUMBER_PADDING,
5725
5743
  $s as DEFAULT_PHONE_REGION,
5726
- cd as DEFAULT_QUOTE_TEMPLATE_BLOCKS,
5727
- ad as DEFAULT_TEMPLATE_CONDITIONS,
5728
- Al as DEMAND_SOURCE_PROVIDER_GROUP,
5729
- Lf as DOCUMENT_APPLY_SERVICE,
5730
- Df as DOCUMENT_DESCRIBE_SERVICE,
5731
- Rf as DOCUMENT_INSPECT_SERVICE,
5744
+ yd as DEFAULT_QUOTE_TEMPLATE_BLOCKS,
5745
+ gd as DEFAULT_TEMPLATE_CONDITIONS,
5746
+ Ml as DEMAND_SOURCE_PROVIDER_GROUP,
5747
+ Wf as DOCUMENT_APPLY_SERVICE,
5748
+ Hf as DOCUMENT_DESCRIBE_SERVICE,
5749
+ Gf as DOCUMENT_INSPECT_SERVICE,
5732
5750
  at as DOCUMENT_MAX_BLOCKS,
5733
- nc as DOCUMENT_MAX_BODY_BYTES,
5751
+ oc as DOCUMENT_MAX_BODY_BYTES,
5734
5752
  Z as DOCUMENT_MAX_CELL_LEN,
5735
5753
  dt as DOCUMENT_MAX_KPI_ITEMS,
5736
5754
  ft as DOCUMENT_MAX_LETTERHEAD_FIELDS,
@@ -5741,517 +5759,526 @@ export {
5741
5759
  zt as DOCUMENT_MAX_TEXT_LEN,
5742
5760
  pt as DOCUMENT_MAX_TOTALS_ROWS,
5743
5761
  Sn as DOCUMENT_OPERATIONS,
5744
- td as DRAFT_FIELDS,
5745
- Oi as DUTCH_SLOT_LABELS,
5746
- Xl as EMPTY_WORKFLOW,
5762
+ ud as DRAFT_FIELDS,
5763
+ Ni as DUTCH_SLOT_LABELS,
5764
+ ru as EMPTY_WORKFLOW,
5747
5765
  bn as ENABLED_TRANSACTION_KINDS,
5748
- If as FEATURE_FOLDER_MANAGEMENT,
5749
- kf as FEATURE_MESSAGE_REACTIONS,
5750
- vf as FEATURE_REMOTE_SEARCH,
5766
+ Df as FEATURE_FOLDER_MANAGEMENT,
5767
+ $f as FEATURE_MESSAGE_REACTIONS,
5768
+ Rf as FEATURE_REMOTE_SEARCH,
5751
5769
  Be as FIXED_KINDS,
5752
5770
  ie as FIXED_LEVELS,
5753
5771
  Ve as FIXED_TYPES,
5754
- vc as FIXED_UNITS,
5755
- Ur as FOLLOW_UP_HOURS,
5756
- ed as FROZEN_WRITABLE_FIELDS,
5757
- wr as HOUR_MS,
5758
- sa as HTML_BODY_RE,
5772
+ wc as FIXED_UNITS,
5773
+ jr as FOLLOW_UP_HOURS,
5774
+ ld as FROZEN_WRITABLE_FIELDS,
5775
+ Or as HOUR_MS,
5776
+ ca as HTML_BODY_RE,
5759
5777
  P as INELIGIBLE,
5760
- Kf as INSTALLATION_HEADER,
5761
- Do as INTERACTION_KIND,
5762
- Sf as InteractionParticipantRole,
5763
- zr as KB_FALLBACK_LOCALE,
5778
+ zf as INSTALLATION_HEADER,
5779
+ Lo as INTERACTION_KIND,
5780
+ Nf as InteractionParticipantRole,
5781
+ Xr as KB_FALLBACK_LOCALE,
5764
5782
  gt as KB_LOCALES,
5783
+ xc as LEAD_STATUSES,
5784
+ Nc as LIFECYCLE_STAGES,
5765
5785
  gt as LOCALES,
5766
5786
  ze as LOOSE_STATUSES,
5767
5787
  $r as MAIL_HINT_HEADERS,
5768
- Ar as MANUAL_PRICE_SOURCE,
5769
- ua as MAX_ACTIONS,
5788
+ _r as MANUAL_PRICE_SOURCE,
5789
+ fa as MAX_ACTIONS,
5770
5790
  ur as MAX_ASSIGNMENT_TURNS,
5771
- aa as MAX_BLOCKS,
5791
+ la as MAX_BLOCKS,
5772
5792
  rt as MAX_CHOICE_OPTIONS,
5773
5793
  tn as MAX_COLLECTION_DEPTH,
5774
5794
  dr as MAX_DELEGATION_DEPTH,
5775
- ip as MAX_EDITABLE_FILE_BYTES,
5776
- ca as MAX_FIELDS,
5777
- la as MAX_LIST_ITEMS,
5778
- ol as MAX_MEMORY_BROWSE,
5779
- al as MAX_MEMORY_BUDGET,
5780
- il as MAX_MEMORY_CHARS,
5795
+ mp as MAX_EDITABLE_FILE_BYTES,
5796
+ ua as MAX_FIELDS,
5797
+ da as MAX_LIST_ITEMS,
5798
+ pl as MAX_MEMORY_BROWSE,
5799
+ gl as MAX_MEMORY_BUDGET,
5800
+ ml as MAX_MEMORY_CHARS,
5781
5801
  Tt as MAX_RULE_DEPTH,
5782
5802
  it as MAX_SCORE_LEVELS,
5783
- xs as MAX_SHOWN_KEYS,
5784
- Si as MAX_TOPIC_CANDIDATES,
5785
- Ei as MAX_TOPIC_EXAMPLES,
5803
+ Rs as MAX_SHOWN_KEYS,
5804
+ Ii as MAX_TOPIC_CANDIDATES,
5805
+ Ti as MAX_TOPIC_EXAMPLES,
5786
5806
  ye as MAX_TOPIC_EXAMPLE_CHARS,
5787
- sp as MAX_VIEWABLE_FILE_BYTES,
5788
- sl as MIN_MEMORY_BUDGET,
5807
+ hp as MAX_VIEWABLE_FILE_BYTES,
5808
+ hl as MIN_MEMORY_BUDGET,
5789
5809
  ot as MIN_SCORE_LEVELS,
5790
5810
  H as MODEL_TIERS,
5791
- pp as NAV_NOTICE_SLOT,
5792
- _d as NL_PAYMENT_TERMS,
5793
- ul as NL_TAX_RATES,
5794
- Ff as NOTIFICATION_SOURCE_PROVIDER_GROUP,
5795
- bi as OFF_TRACK_GAP,
5796
- fl as ONBOARDING_SOURCE_PROVIDER_GROUP,
5797
- Re as PAUSE_HOLD,
5798
- $e as PAUSE_SNOOZED,
5799
- De as PAUSE_WAITING_FOR_CUSTOMER,
5800
- yd as PAYMENT_TERM_METHODS,
5801
- Xe as PHONE_REGIONS,
5802
- xl as PLAYBOOK_RUN_APPROVAL_ACT,
5803
- Oo as PLAYBOOK_RUN_SCOPE_KIND,
5811
+ Sp as NAV_NOTICE_SLOT,
5812
+ Od as NL_PAYMENT_TERMS,
5813
+ _l as NL_TAX_RATES,
5814
+ Xf as NOTIFICATION_SOURCE_PROVIDER_GROUP,
5815
+ Ai as OFF_TRACK_GAP,
5816
+ El as ONBOARDING_SOURCE_PROVIDER_GROUP,
5817
+ $e as PAUSE_HOLD,
5818
+ De as PAUSE_SNOOZED,
5819
+ Re as PAUSE_WAITING_FOR_CUSTOMER,
5820
+ kd as PAYMENT_TERM_METHODS,
5821
+ Ye as PHONE_REGIONS,
5822
+ jl as PLAYBOOK_RUN_APPROVAL_ACT,
5823
+ No as PLAYBOOK_RUN_SCOPE_KIND,
5804
5824
  Tn as PRESENCE_ONLINE_WINDOW_MS,
5805
- fs as PRESENCE_SURVIVES_OFFLINE,
5806
- Li as PRODUCT_SCOPE_KIND,
5807
- ml as PROFILE_TOOL_DISPOSITIONS,
5808
- Ef as PROVIDER_FEATURE_MESSAGE_TEMPLATES,
5809
- _f as PROVIDER_FEATURE_MESSAGE_WINDOW,
5810
- Fs as PUBLIC_EMAIL_DOMAINS,
5825
+ ms as PRESENCE_SURVIVES_OFFLINE,
5826
+ Ki as PRODUCT_SCOPE_KIND,
5827
+ Tl as PROFILE_TOOL_DISPOSITIONS,
5828
+ Cf as PROVIDER_FEATURE_MESSAGE_TEMPLATES,
5829
+ Of as PROVIDER_FEATURE_MESSAGE_WINDOW,
5830
+ Bs as PUBLIC_EMAIL_DOMAINS,
5811
5831
  yt as READ_STEP_TYPES,
5812
- qr as RELATED_SUBJECT_KINDS,
5813
- _n as RESERVED_STATUS_KEYS,
5814
- wd as RESERVED_TYPE_KEYS,
5815
- qf as RESOURCE_ATTACHED_SERVICE,
5816
- zf as RESOURCE_DESCRIBE_SERVICE,
5817
- Yf as RESOURCE_RESOLVE_SERVICE,
5818
- Xf as RESOURCE_SEARCH_SERVICE,
5819
- So as SCHEDULE_ENTRY_SCOPE_KIND,
5820
- Zo as SCHEDULE_EVENT,
5821
- ep as SCOPE_ACTS_ROUTE,
5822
- Zf as SCOPE_READ_ROUTE,
5823
- Jf as SCOPE_RELATED_ROUTE,
5824
- fp as SETTINGS_CATEGORIES,
5825
- kc as SIGNATURE_INTENTS,
5826
- Au as SLA_METRICS,
5827
- _u as SLA_PAUSE_REASONS,
5828
- Ju as STATUS_NAMES,
5829
- Po as STEP_MAX_TOKENS_MAX,
5830
- Lo as STEP_MAX_TOKENS_MIN,
5831
- zl as STEP_TYPES,
5832
- fi as STRATEGY_ITEM_SCOPE_KIND,
5833
- xr as SUMMARY_MIN_LAST_CHARS,
5834
- Nr as SUMMARY_MIN_MESSAGES,
5835
- cp as SYNC_RUN_MAX_ERRORS,
5836
- ap as SYNC_TARGET_PROVIDER_GROUP,
5837
- Ra as SYSTEM_ONE_NON_GOALS,
5832
+ Jr as RELATED_SUBJECT_KINDS,
5833
+ An as RESERVED_STATUS_KEYS,
5834
+ Ld as RESERVED_TYPE_KEYS,
5835
+ ip as RESOURCE_ATTACHED_SERVICE,
5836
+ np as RESOURCE_DESCRIBE_SERVICE,
5837
+ op as RESOURCE_RESOLVE_SERVICE,
5838
+ rp as RESOURCE_SEARCH_SERVICE,
5839
+ Io as SCHEDULE_ENTRY_SCOPE_KIND,
5840
+ ti as SCHEDULE_EVENT,
5841
+ lp as SCOPE_ACTS_ROUTE,
5842
+ cp as SCOPE_READ_ROUTE,
5843
+ ap as SCOPE_RELATED_ROUTE,
5844
+ Rc as SEGMENT_FILTER_KEYS,
5845
+ Lc as SEGMENT_LAYOUTS,
5846
+ Er as SEGMENT_LIST_FILTERS,
5847
+ Sr as SEGMENT_PRESENCE_FILTERS,
5848
+ $c as SEGMENT_SORT_FIELDS,
5849
+ Ep as SETTINGS_CATEGORIES,
5850
+ Mc as SIGNATURE_INTENTS,
5851
+ Mu as SLA_METRICS,
5852
+ Ou as SLA_PAUSE_REASONS,
5853
+ ad as STATUS_NAMES,
5854
+ Uo as STEP_MAX_TOKENS_MAX,
5855
+ Ko as STEP_MAX_TOKENS_MIN,
5856
+ nu as STEP_TYPES,
5857
+ mi as STRATEGY_ITEM_SCOPE_KIND,
5858
+ Rr as SUMMARY_MIN_LAST_CHARS,
5859
+ Dr as SUMMARY_MIN_MESSAGES,
5860
+ yp as SYNC_RUN_MAX_ERRORS,
5861
+ gp as SYNC_TARGET_PROVIDER_GROUP,
5862
+ Pa as SYSTEM_ONE_NON_GOALS,
5838
5863
  cr as TERMINAL_ASSIGNMENT_STATUSES,
5839
- jo as TERMINAL_RUN_STATUSES,
5864
+ Ho as TERMINAL_RUN_STATUSES,
5840
5865
  We as TRANSACTION_KINDS,
5841
- Ri as TRANSACTION_SCOPE_KINDS,
5842
- Hl as TRIGGER_VARS,
5843
- su as UNARY_OPS,
5844
- Zr as UNKNOWN_KIND,
5845
- pi as UNKNOWN_LEVEL_ORDER,
5846
- wf as UNSUPPORTED,
5847
- Xn as USAGE_DIMENSIONS,
5848
- Yn as USAGE_DIMENSION_IDS,
5866
+ Pi as TRANSACTION_SCOPE_KINDS,
5867
+ Jl as TRIGGER_VARS,
5868
+ hu as UNARY_OPS,
5869
+ to as UNKNOWN_KIND,
5870
+ hi as UNKNOWN_LEVEL_ORDER,
5871
+ Lf as UNSUPPORTED,
5872
+ Yn as USAGE_DIMENSIONS,
5873
+ Xn as USAGE_DIMENSION_IDS,
5849
5874
  un as UnresolvedRefError,
5850
- Ki as WEBHOOK_EVENTS,
5851
- To as WORKSTREAM_SCOPE_KIND,
5852
- Bi as WORK_ACTIVITY_SCOPE_KIND,
5853
- pl as WORK_AREAS,
5854
- Td as WORK_COMMENT_ADDED,
5855
- xd as WORK_CYCLE_SYNC_KIND,
5856
- Id as WORK_ITEM_ASSIGNED,
5857
- Fi as WORK_ITEM_SCOPE_KIND,
5858
- vd as WORK_ITEM_STATUS_CHANGED,
5859
- ji as WORK_PROJECT_SCOPE_KIND,
5860
- qd as WORK_SORT_FIELDS,
5861
- Yd as WORK_VIEW_FLAGS,
5862
- Qd as WORK_VIEW_LAYOUTS,
5863
- Xd as WORK_VIEW_LIST_FILTERS,
5875
+ Fi as WEBHOOK_EVENTS,
5876
+ vo as WORKSTREAM_SCOPE_KIND,
5877
+ Gi as WORK_ACTIVITY_SCOPE_KIND,
5878
+ Sl as WORK_AREAS,
5879
+ xd as WORK_COMMENT_ADDED,
5880
+ jd as WORK_CYCLE_SYNC_KIND,
5881
+ Dd as WORK_ITEM_ASSIGNED,
5882
+ Bi as WORK_ITEM_SCOPE_KIND,
5883
+ Rd as WORK_ITEM_STATUS_CHANGED,
5884
+ Hi as WORK_PROJECT_SCOPE_KIND,
5885
+ sf as WORK_SORT_FIELDS,
5886
+ of as WORK_VIEW_FLAGS,
5887
+ af as WORK_VIEW_LAYOUTS,
5888
+ rf as WORK_VIEW_LIST_FILTERS,
5864
5889
  ne as W_PRIORITY,
5865
- Yu as acceptExampleCandidate,
5866
- wo as actingIdentityKey,
5867
- zu as activeWorkTypes,
5868
- fa as activityIconOf,
5869
- Sa as activityJoinUrl,
5890
+ od as acceptExampleCandidate,
5891
+ Oo as actingIdentityKey,
5892
+ nd as activeWorkTypes,
5893
+ ma as activityIconOf,
5894
+ Ia as activityJoinUrl,
5870
5895
  Ln as activitySnippet,
5871
5896
  Pn as activityTextParams,
5872
- Ea as activityTimelineText,
5897
+ Ta as activityTimelineText,
5873
5898
  jn as activityTimestamp,
5874
5899
  v as activityTypeInfo,
5875
- Nl as actorKey,
5876
- Xu as addExampleCandidate,
5900
+ Fl as actorKey,
5901
+ rd as addExampleCandidate,
5877
5902
  He as addWorkingMs,
5878
- Gf as agePresenceEntry,
5879
- Ji as aiAttachmentKind,
5880
- nf as aiAttachmentRejection,
5903
+ Zf as agePresenceEntry,
5904
+ es as aiAttachmentKind,
5905
+ ff as aiAttachmentRejection,
5881
5906
  st as aiBudgetLimit,
5882
- Ba as aiBudgetPeriodKey,
5907
+ Ga as aiBudgetPeriodKey,
5883
5908
  Gn as aiBudgetPeriodStart,
5884
- ja as aiBudgetState,
5885
- Fa as aiVendorAcceptsAttachment,
5886
- Pa as aiVendorDefaultModel,
5887
- La as aiVendorLabel,
5888
- Ua as aiVendorNeedsBaseUrl,
5889
- Ka as aiVendorsWith,
5909
+ Ha as aiBudgetState,
5910
+ Ba as aiVendorAcceptsAttachment,
5911
+ Ua as aiVendorDefaultModel,
5912
+ Ka as aiVendorLabel,
5913
+ ja as aiVendorNeedsBaseUrl,
5914
+ Fa as aiVendorsWith,
5890
5915
  mr as allocate,
5891
5916
  kn as appNameFromPath,
5892
- tc as applyApprovalDecision,
5893
- Bu as applyRounding,
5894
- wc as applySignature,
5895
- Ko as approvalRate,
5896
- oc as artifactBodyBytes,
5897
- ic as artifactOutline,
5917
+ rc as applyApprovalDecision,
5918
+ Qu as applyRounding,
5919
+ Oc as applySignature,
5920
+ Fo as approvalRate,
5921
+ sc as artifactBodyBytes,
5922
+ ac as artifactOutline,
5898
5923
  ar as artifactToMarkdown,
5899
- Pl as assignmentMismatch,
5900
- dc as assignmentScopeKey,
5901
- mc as assignmentSubject,
5902
- bl as availabilityByPerson,
5903
- hl as belongsOnCalendar,
5904
- bc as belongsToEntity,
5905
- iu as bindParams,
5924
+ Vl as assignmentMismatch,
5925
+ pc as assignmentScopeKey,
5926
+ gc as assignmentSubject,
5927
+ wl as availabilityByPerson,
5928
+ Il as belongsOnCalendar,
5929
+ Ac as belongsToEntity,
5930
+ mu as bindParams,
5906
5931
  Me as bindValue,
5907
- Ta as buildActivityPreview,
5908
- hf as buildChannelIntents,
5909
- sc as buildShareKeys,
5910
- Ns as buildWindow,
5911
- vr as businessEntitySender,
5912
- to as calendarDaysBetween,
5932
+ va as buildActivityPreview,
5933
+ If as buildChannelIntents,
5934
+ cc as buildShareKeys,
5935
+ Ds as buildWindow,
5936
+ wr as businessEntitySender,
5937
+ ro as calendarDaysBetween,
5913
5938
  Ge as calendarOf,
5914
- rd as canConvert,
5915
- Jc as canNestUnder,
5916
- Ou as canParent,
5917
- Zu as canTransition,
5918
- Ma as capabilityDefaultFlag,
5919
- gl as capacityTotal,
5920
- wl as capacityWeights,
5921
- ya as carriesText,
5922
- el as categoryLabel,
5923
- Wi as categoryOf,
5924
- uu as causedBy,
5925
- Af as channelKindForScheme,
5926
- pa as channelKindOf,
5927
- Uu as checkInOverdueMs,
5928
- Vl as clampStepMaxTokens,
5929
- Uc as classifyMail,
5930
- Sp as cleanMessageMarkdown,
5931
- Ep as cleanMessageText,
5932
- Ec as codeQuery,
5933
- uf as compareAssistRank,
5934
- _i as compareWorkTypes,
5935
- Ir as conditionHolds,
5936
- Mi as copyFrom,
5937
- X as countsAsPlanned,
5938
- yl as coverageByPerson,
5939
- El as coverageFor,
5939
+ fd as canConvert,
5940
+ al as canNestUnder,
5941
+ Ku as canParent,
5942
+ cd as canTransition,
5943
+ Ca as capabilityDefaultFlag,
5944
+ vl as capacityTotal,
5945
+ Ll as capacityWeights,
5946
+ _a as carriesText,
5947
+ ll as categoryLabel,
5948
+ zi as categoryOf,
5949
+ _u as causedBy,
5950
+ Mf as channelKindForScheme,
5951
+ ha as channelKindOf,
5952
+ Yu as checkInOverdueMs,
5953
+ tu as clampStepMaxTokens,
5954
+ Yc as classifyMail,
5955
+ Np as cleanMessageMarkdown,
5956
+ Cp as cleanMessageText,
5957
+ Tc as codeQuery,
5958
+ _f as compareAssistRank,
5959
+ Si as compareWorkTypes,
5960
+ kr as conditionHolds,
5961
+ Dc as contactName,
5962
+ Ci as copyFrom,
5963
+ Y as countsAsPlanned,
5964
+ kl as coverageByPerson,
5965
+ Cl as coverageFor,
5940
5966
  rn as coversWorkstream,
5941
- Jo as cronMatches,
5942
- gd as currentPeriod,
5967
+ ei as cronMatches,
5968
+ vd as currentPeriod,
5943
5969
  on as cycleDayIndex,
5944
- Vd as cycleOrder,
5945
- zd as cycleState,
5946
- hc as decideAssignmentState,
5947
- dp as decideCadence,
5948
- Qa as decideEach,
5949
- pf as decideIncomingCall,
5950
- Da as decisionBand,
5951
- Xr as defaultLocaleOf,
5952
- Fd as defaultStatusKey,
5970
+ tf as cycleOrder,
5971
+ nf as cycleState,
5972
+ yc as decideAssignmentState,
5973
+ Ap as decideCadence,
5974
+ Za as decideEach,
5975
+ Sf as decideIncomingCall,
5976
+ La as decisionBand,
5977
+ qr as defaultLocaleOf,
5978
+ Xd as defaultStatusKey,
5953
5979
  $i as defaultTemplateBlocks,
5954
- Tf as defineIntent,
5955
- gc as delegationRefusal,
5956
- Wr as depthOf,
5957
- Hf as derivePresence,
5958
- Xa as describeClause,
5959
- cu as describeExpression,
5960
- mf as disabledIntentsFromCapabilities,
5961
- oc as documentBodyBytes,
5962
- Pf as documentKindOf,
5963
- ic as documentOutline,
5980
+ xf as defineIntent,
5981
+ bc as delegationRefusal,
5982
+ zr as depthOf,
5983
+ Jf as derivePresence,
5984
+ qa as describeClause,
5985
+ yu as describeExpression,
5986
+ Tf as disabledIntentsFromCapabilities,
5987
+ sc as documentBodyBytes,
5988
+ Vf as documentKindOf,
5989
+ ac as documentOutline,
5964
5990
  ar as documentToMarkdown,
5965
- $f as documentToText,
5966
- ni as driftedFields,
5967
- Tu as dueAtOf,
5968
- bd as dueDateFrom,
5969
- ju as elapsedSeconds,
5970
- gp as emailDomain,
5971
- au as emptyConditionLeaf,
5972
- Ap as endpointKey,
5973
- Ac as entityOwnerIds,
5974
- io as erlangC,
5975
- hs as extractParams,
5976
- Os as extractTerms,
5977
- $c as failureLines,
5978
- mu as fieldVarPath,
5979
- Nc as fillDocument,
5980
- Tr as fillText,
5981
- yf as filterByEndpoint,
5982
- gf as filterByIntent,
5983
- os as filterByTargetScheme,
5984
- za as filterableDimensions,
5991
+ Bf as documentToText,
5992
+ oi as driftedFields,
5993
+ xu as dueAtOf,
5994
+ wd as dueDateFrom,
5995
+ qu as elapsedSeconds,
5996
+ vp as emailDomain,
5997
+ gu as emptyConditionLeaf,
5998
+ Mp as endpointKey,
5999
+ Ec as entityOwnerIds,
6000
+ ao as erlangC,
6001
+ ys as extractParams,
6002
+ Ns as extractTerms,
6003
+ Bc as failureLines,
6004
+ Tu as fieldVarPath,
6005
+ Fc as fillDocument,
6006
+ vr as fillText,
6007
+ kf as filterByEndpoint,
6008
+ vf as filterByIntent,
6009
+ ss as filterByTargetScheme,
6010
+ Xa as filterableDimensions,
5985
6011
  oe as findAiVendor,
5986
- hu as findEvent,
5987
- Nu as fixedLevelForName,
5988
- Cd as fixedTypeForName,
5989
- Nd as fixedTypes,
5990
- Uf as flattenLocales,
6012
+ Iu as findEvent,
6013
+ Fu as fixedLevelForName,
6014
+ Ud as fixedTypeForName,
6015
+ Fd as fixedTypes,
6016
+ Yf as flattenLocales,
5991
6017
  V as floorToPeriod,
5992
- Il as forecastIntervals,
5993
- ko as formatActingIdentity,
5994
- R as formatCents,
5995
- Gu as formatClock,
5996
- Hu as formatHm,
5997
- Dd as formatItemKey,
6018
+ Dl as forecastIntervals,
6019
+ Mo as formatActingIdentity,
6020
+ $ as formatCents,
6021
+ Zu as formatClock,
6022
+ Ju as formatHm,
6023
+ Hd as formatItemKey,
5998
6024
  W as formatPeriod,
5999
- hd as formatSeriesNumber,
6000
- ku as formatSlaDuration,
6001
- sf as freshSources,
6002
- va as getActivitySeenUserIds,
6003
- Mc as getContactEndpoints,
6004
- Vc as getShortTitle,
6005
- Wc as getUrgencyScore,
6006
- ou as hasReacted,
6007
- xu as healthCategory,
6008
- $u as healthsInCategory,
6025
+ Id as formatSeriesNumber,
6026
+ $u as formatSlaDuration,
6027
+ hf as freshSources,
6028
+ wa as getActivitySeenUserIds,
6029
+ Cc as getContactEndpoints,
6030
+ tl as getShortTitle,
6031
+ el as getUrgencyScore,
6032
+ pu as hasReacted,
6033
+ ju as healthCategory,
6034
+ Bu as healthsInCategory,
6009
6035
  nn as heightOf,
6010
- Xc as helpCenterText,
6011
- jl as humanizeAction,
6012
- Ro as interactionIdOf,
6013
- Ed as isAgentUser,
6014
- Hc as isAssigned,
6015
- uc as isAssignmentTerminal,
6016
- No as isAssignmentTrigger,
6017
- Ha as isAssistantMode,
6018
- Jl as isAutoReady,
6019
- Kl as isAutonomy,
6020
- Gr as isAwaitingThem,
6021
- wa as isChatMessageActivity,
6022
- Gc as isClosed,
6023
- Aa as isConnectedType,
6024
- tp as isDeepLink,
6025
- Vr as isDescendant,
6026
- Rc as isEligible,
6027
- ka as isEmailActivity,
6028
- wi as isFrozen,
6029
- Su as isHeldClock,
6030
- _p as isHtmlBody,
6031
- eu as isInFlight,
6032
- Lr as isInteractionUnseen,
6033
- np as isLandingPath,
6034
- Cr as isLikelyBulk,
6036
+ rl as helpCenterText,
6037
+ ql as humanizeAction,
6038
+ Po as interactionIdOf,
6039
+ Cd as isAgentUser,
6040
+ Jc as isAssigned,
6041
+ fc as isAssignmentTerminal,
6042
+ Do as isAssignmentTrigger,
6043
+ Wa as isAssistantMode,
6044
+ au as isAutoReady,
6045
+ zl as isAutonomy,
6046
+ Vr as isAwaitingThem,
6047
+ Oa as isChatMessageActivity,
6048
+ Zc as isClosed,
6049
+ Ea as isConnectedType,
6050
+ up as isDeepLink,
6051
+ Yr as isDescendant,
6052
+ Gc as isEligible,
6053
+ Ma as isEmailActivity,
6054
+ Oi as isFrozen,
6055
+ Nu as isHeldClock,
6056
+ Op as isHtmlBody,
6057
+ lu as isInFlight,
6058
+ Kr as isInteractionUnseen,
6059
+ dp as isLandingPath,
6060
+ xr as isLikelyBulk,
6035
6061
  Ht as isMessageShape,
6036
- ma as isMessageType,
6037
- ys as isMoreSpecificPattern,
6062
+ ga as isMessageType,
6063
+ _s as isMoreSpecificPattern,
6038
6064
  Gt as isNoteShape,
6039
- di as isOpenClock,
6065
+ pi as isOpenClock,
6040
6066
  En as isOutwardTool,
6041
- jr as isParked,
6042
- Bo as isPaused,
6043
- ba as isPlaybookAuthoredType,
6044
- yp as isPublicEmailDomain,
6045
- op as isPublicPath,
6046
- Br as isReminderActive,
6047
- ga as isReplyableType,
6048
- jc as isSlaAtRisk,
6049
- lu as isSupportedCron,
6050
- Zl as isTerminal,
6051
- Pc as isThreadLongEnough,
6052
- _a as isTranscriptType,
6053
- Sd as isWebhookEvent,
6054
- jd as isWorkClosed,
6055
- Vu as isWorkTypeVisible,
6067
+ Hr as isParked,
6068
+ Go as isPaused,
6069
+ Aa as isPlaybookAuthoredType,
6070
+ kp as isPublicEmailDomain,
6071
+ pp as isPublicPath,
6072
+ Gr as isReminderActive,
6073
+ ba as isReplyableType,
6074
+ qc as isSlaAtRisk,
6075
+ bu as isSupportedCron,
6076
+ cu as isTerminal,
6077
+ Vc as isThreadLongEnough,
6078
+ Sa as isTranscriptType,
6079
+ Nd as isWebhookEvent,
6080
+ qd as isWorkClosed,
6081
+ td as isWorkTypeVisible,
6056
6082
  wn as isWriteTool,
6057
- Pd as itemDossierKeys,
6058
- du as judgeRuleCase,
6059
- $ as kindFor,
6060
- Gi as ladderFor,
6061
- hi as levelIn,
6083
+ Vd as itemDossierKeys,
6084
+ Au as judgeRuleCase,
6085
+ D as kindFor,
6086
+ Vi as ladderFor,
6087
+ yi as levelIn,
6062
6088
  Pe as levelOrder,
6063
- Jr as lineNet,
6064
- zc as linkLabel,
6065
- Qu as listedTransactionKinds,
6066
- Ga as listeningAllowed,
6067
- Qc as localeInstruction,
6068
- qc as localeName,
6069
- Zc as localesOf,
6070
- mp as looksLikeEmail,
6089
+ eo as lineNet,
6090
+ nl as linkLabel,
6091
+ sd as listedTransactionKinds,
6092
+ Va as listeningAllowed,
6093
+ sl as localeInstruction,
6094
+ il as localeName,
6095
+ cl as localesOf,
6096
+ Tp as looksLikeEmail,
6071
6097
  qt as lookup,
6072
- Tc as marginCents,
6073
- xf as markdownToDocument,
6074
- Za as matchApprovalPolicy,
6075
- bf as matchContactToIntents,
6076
- bs as matchPublicRoute,
6077
- ei as matchRules,
6078
- nl as mcpCredentialScope,
6079
- rl as mcpToolPrefix,
6080
- Du as measureRatio,
6081
- Ca as mergeDefaultFlags,
6082
- up as mergeShownKeys,
6083
- Rn as messageCountsAs,
6084
- Ya as metricOption,
6098
+ vc as marginCents,
6099
+ jf as markdownToDocument,
6100
+ tc as matchApprovalPolicy,
6101
+ wf as matchContactToIntents,
6102
+ As as matchPublicRoute,
6103
+ ni as matchRules,
6104
+ dl as mcpCredentialScope,
6105
+ fl as mcpToolPrefix,
6106
+ Hu as measureRatio,
6107
+ xa as mergeDefaultFlags,
6108
+ _p as mergeShownKeys,
6109
+ $n as messageCountsAs,
6110
+ Qa as metricOption,
6085
6111
  sn as minutesOn,
6086
- gu as missingFieldPaths,
6087
- Na as modelAcceptsAttachment,
6088
- As as mustAsk,
6089
- Fl as narrowAutonomy,
6090
- bp as needsPhoneRegion,
6091
- ha as nestsUnderParent,
6092
- Cu as nextLevelBelow,
6093
- Zd as nextOccurrenceDates,
6094
- Iu as nextSlaClock,
6095
- ki as nextStatuses,
6096
- od as nextVersion,
6097
- rc as normalizeArtifactBlocks,
6098
- da as normalizeBlocks,
6099
- rc as normalizeDocumentBlocks,
6112
+ vu as missingFieldPaths,
6113
+ Da as modelAcceptsAttachment,
6114
+ Es as mustAsk,
6115
+ Xl as narrowAutonomy,
6116
+ wp as needsPhoneRegion,
6117
+ ya as nestsUnderParent,
6118
+ Uu as nextLevelBelow,
6119
+ lf as nextOccurrenceDates,
6120
+ Du as nextSlaClock,
6121
+ Mi as nextStatuses,
6122
+ pd as nextVersion,
6123
+ ic as normalizeArtifactBlocks,
6124
+ pa as normalizeBlocks,
6125
+ ic as normalizeDocumentBlocks,
6100
6126
  Mn as normalizeEmail,
6101
6127
  K as normalizeExample,
6102
6128
  fr as normalizeGtin,
6103
- jf as notificationPrefKey,
6104
- Cs as novelty,
6105
- Nf as operationDescriptor,
6106
- Cf as operationsForKind,
6107
- pu as opsForFieldType,
6108
- xc as organizationSender,
6109
- Wd as outcomeOf,
6129
+ qf as notificationPrefKey,
6130
+ xs as novelty,
6131
+ Ff as operationDescriptor,
6132
+ Uf as operationsForKind,
6133
+ Su as opsForFieldType,
6134
+ jc as organizationSender,
6135
+ ef as outcomeOf,
6110
6136
  fe as overlapSeconds,
6111
- _l as overlaps,
6112
- Ru as paceRatio,
6113
- Lc as parkMarksById,
6114
- qo as parse,
6115
- Ol as parseActingIdentity,
6116
- Sc as parseAmount,
6117
- yu as parseClockMinutes,
6137
+ Ol as overlaps,
6138
+ Gu as paceRatio,
6139
+ Wc as parkMarksById,
6140
+ Jo as parse,
6141
+ Kl as parseActingIdentity,
6142
+ Ic as parseAmount,
6143
+ ku as parseClockMinutes,
6118
6144
  dn as parseCron,
6119
- Rd as parseItemKey,
6120
- Jd as parseRecurrence,
6121
- ms as pathToRegex,
6145
+ Gd as parseItemKey,
6146
+ cf as parseRecurrence,
6147
+ gs as pathToRegex,
6122
6148
  cn as patternFor,
6123
6149
  an as patternStartTime,
6124
- bu as pauseBitFor,
6125
- ec as pendingApprovers,
6126
- Va as periodsInRange,
6127
- hp as phoneSuffix,
6128
- Kc as pickMailHeaders,
6129
- Cc as pickTemplate,
6130
- Ml as placeLumps,
6131
- $n as plainTextFromMarkdown,
6132
- Eu as planSlaEvent,
6133
- Sl as plannedBillable,
6134
- mo as plannedWorkTypeKey,
6135
- ql as procedureOf,
6136
- dd as productHref,
6137
- ld as productScopeKey,
6138
- Kd as projectDossierKeys,
6139
- Ja as proposalRequestIds,
6140
- gs as publicBasePathFor,
6141
- rp as publicRoutePatterns,
6142
- pc as reactionWakesAssignment,
6143
- Oa as readDefaultFlags,
6144
- _e as readPath,
6150
+ wu as pauseBitFor,
6151
+ nc as pendingApprovers,
6152
+ Ya as periodsInRange,
6153
+ Ip as phoneSuffix,
6154
+ zc as pickMailHeaders,
6155
+ Uc as pickTemplate,
6156
+ Pl as placeLumps,
6157
+ Dn as plainTextFromMarkdown,
6158
+ Cu as planSlaEvent,
6159
+ Nl as plannedBillable,
6160
+ go as plannedWorkTypeKey,
6161
+ iu as procedureOf,
6162
+ Ad as productHref,
6163
+ bd as productScopeKey,
6164
+ zd as projectDossierKeys,
6165
+ ec as proposalRequestIds,
6166
+ bs as publicBasePathFor,
6167
+ fp as publicRoutePatterns,
6168
+ hc as reactionWakesAssignment,
6169
+ Na as readDefaultFlags,
6170
+ Ae as readPath,
6145
6171
  de as readStepError,
6146
- Fr as recencyOf,
6147
- Oc as recipientLocale,
6172
+ Br as recencyOf,
6173
+ Kc as recipientLocale,
6148
6174
  $o as refKey,
6149
- Us as registrableDomain,
6150
- Ii as rejectExampleCandidate,
6151
- ll as relatedByDefault,
6175
+ js as registrableDomain,
6176
+ ki as rejectExampleCandidate,
6177
+ bl as relatedByDefault,
6152
6178
  Le as remainingMsOf,
6153
- Ic as repriceLines,
6154
- co as requiredAgents,
6155
- po as requirementFor,
6156
- ns as resolveAccountCapabilities,
6179
+ kc as repriceLines,
6180
+ uo as requiredAgents,
6181
+ ho as requirementFor,
6182
+ os as resolveAccountCapabilities,
6157
6183
  Ee as resolveActivityText,
6158
- Ul as resolveAutonomy,
6159
- ts as resolveChannelIntents,
6184
+ Yl as resolveAutonomy,
6185
+ rs as resolveChannelIntents,
6160
6186
  yr as resolvePrice,
6161
- xa as resolveRoute,
6162
- _r as resolveSignature,
6187
+ Ra as resolveRoute,
6188
+ Ar as resolveSignature,
6163
6189
  Hn as resolveTier,
6164
- Wf as resolveWorkMode,
6165
- Qf as resourceKindOf,
6166
- Ku as rollupChildren,
6190
+ ep as resolveWorkMode,
6191
+ sp as resourceKindOf,
6192
+ zu as rollupChildren,
6167
6193
  z as roundHalfUp,
6168
- Cl as runActor,
6169
- $l as runApprovalKey,
6170
- Dc as runEvalSuite,
6171
- Dl as runIdOfApprovalRef,
6172
- nu as runInteractionId,
6173
- Ql as runKind,
6174
- fu as runOutcome,
6194
+ Ul as runActor,
6195
+ Bl as runApprovalKey,
6196
+ Hc as runEvalSuite,
6197
+ Hl as runIdOfApprovalRef,
6198
+ du as runInteractionId,
6199
+ su as runKind,
6200
+ Eu as runOutcome,
6175
6201
  rr as sanitizeInline,
6176
- Ss as sanitizeTranscript,
6177
- vl as scheduleEntryScopeKey,
6178
- Bc as scoreInteraction,
6179
- kd as scoreWorkItem,
6180
- tl as selectLenses,
6202
+ Is as sanitizeTranscript,
6203
+ Rl as scheduleEntryScopeKey,
6204
+ Qc as scoreInteraction,
6205
+ $d as scoreWorkItem,
6206
+ Pc as segmentIsEmpty,
6207
+ ul as selectLenses,
6181
6208
  he as serialize,
6182
- so as serviceLevel,
6183
- ff as sessionsHoldCannotReach,
6184
- df as sessionsToHold,
6185
- _c as shadowByKey,
6186
- Yt as shareKeyForTeam,
6187
- Xt as shareKeyForUser,
6188
- ac as shareKeysForViewer,
6189
- Tl as shortfalls,
6190
- Vf as shouldRunAudioPipeline,
6191
- vu as slaBadgeTone,
6192
- Fc as slaHoursByInbox,
6193
- Hr as slaHoursFor,
6194
- Vi as sortStatuses,
6195
- es as sourceKey,
6196
- vo as spreadOverWeights,
6197
- Ud as statusIn,
6198
- Gd as statusRequiresApproval,
6199
- Yi as stepDate,
6200
- Yl as stepsOf,
6201
- Mu as strategyAncestorKeysFor,
6202
- wu as strategyDossierKeys,
6209
+ co as serviceLevel,
6210
+ Ef as sessionsHoldCannotReach,
6211
+ Af as sessionsToHold,
6212
+ Sc as shadowByKey,
6213
+ Xt as shareKeyForTeam,
6214
+ Yt as shareKeyForUser,
6215
+ lc as shareKeysForViewer,
6216
+ xl as shortfalls,
6217
+ tp as shouldRunAudioPipeline,
6218
+ Ru as slaBadgeTone,
6219
+ Xc as slaHoursByInbox,
6220
+ Wr as slaHoursFor,
6221
+ Yi as sortStatuses,
6222
+ ns as sourceKey,
6223
+ wo as spreadOverWeights,
6224
+ Yd as statusIn,
6225
+ Zd as statusRequiresApproval,
6226
+ Qi as stepDate,
6227
+ ou as stepsOf,
6228
+ Pu as strategyAncestorKeysFor,
6229
+ Lu as strategyDossierKeys,
6203
6230
  yn as strategyItemScopeKey,
6204
- Dn as stripHtml,
6205
- tu as subjectKeyOf,
6231
+ Rn as stripHtml,
6232
+ uu as subjectKeyOf,
6206
6233
  ln as subjectOf,
6207
- lf as subjectRef,
6208
- Ld as suggestProjectKey,
6209
- Lu as suggestedHealth,
6210
- kr as summariseEval,
6211
- ru as summarizeReactions,
6212
- Ll as targetById,
6213
- Rl as targetForActivityType,
6214
- Fu as targetOrder,
6215
- Qr as taxRateFor,
6216
- no as termsFor,
6217
- Mo as toActingIdentity,
6234
+ bf as subjectRef,
6235
+ Wd as suggestProjectKey,
6236
+ Wu as suggestedHealth,
6237
+ Mr as summariseEval,
6238
+ fu as summarizeReactions,
6239
+ Wl as targetById,
6240
+ Gl as targetForActivityType,
6241
+ Xu as targetOrder,
6242
+ Zr as taxRateFor,
6243
+ oo as termsFor,
6244
+ Co as toActingIdentity,
6218
6245
  Lt as toE164,
6219
- Ad as toTransactionTerm,
6220
- xo as toolBareName,
6221
- Bl as toolDisplayName,
6222
- of as toolReversible,
6223
- cc as toolSourceKinds,
6224
- lp as toolVerdict,
6225
- vi as topicOfferedForTeam,
6226
- qu as topicsForTeam,
6227
- ao as trafficIntensity,
6228
- id as transactionContext,
6229
- pd as transactionDossierKeys,
6230
- ud as transactionHref,
6231
- fd as transactionIdFromScope,
6246
+ Md as toTransactionTerm,
6247
+ Ro as toolBareName,
6248
+ Ql as toolDisplayName,
6249
+ mf as toolReversible,
6250
+ uc as toolSourceKinds,
6251
+ bp as toolVerdict,
6252
+ wi as topicOfferedForTeam,
6253
+ id as topicsForTeam,
6254
+ lo as trafficIntensity,
6255
+ md as transactionContext,
6256
+ Sd as transactionDossierKeys,
6257
+ _d as transactionHref,
6258
+ Ed as transactionIdFromScope,
6232
6259
  O as transactionKind,
6233
- Pi as transactionScopeKey,
6234
- sd as transactionSlots,
6235
- dl as transactionTotals,
6236
- Gl as triggerFillsVar,
6237
- Ti as truncateExample,
6238
- Od as typeIn,
6239
- Md as typesFor,
6240
- Bd as uniqueWorkStatusKey,
6241
- Wu as uniqueWorkTypeKey,
6260
+ Ui as transactionScopeKey,
6261
+ hd as transactionSlots,
6262
+ Al as transactionTotals,
6263
+ Zl as triggerFillsVar,
6264
+ vi as truncateExample,
6265
+ Kd as typeIn,
6266
+ Pd as typesFor,
6267
+ Qd as uniqueWorkStatusKey,
6268
+ ed as uniqueWorkTypeKey,
6242
6269
  qn as usageMetricId,
6243
- qa as usageMetrics,
6270
+ Ja as usageMetrics,
6244
6271
  $a as validateQuestions,
6245
- Hd as validateStatuses,
6246
- Co as valueAtPath,
6272
+ Jd as validateStatuses,
6273
+ xo as valueAtPath,
6247
6274
  je as waitHoursOf,
6248
- fc as wakesAssignment,
6249
- $d as workActivityScopeKey,
6250
- Hi as workItemScopeKey,
6251
- An as workProjectScopeKey,
6252
- Pu as workRatio,
6253
- zi as workStatusKey,
6254
- Ai as workTypeKey,
6275
+ mc as wakesAssignment,
6276
+ Bd as workActivityScopeKey,
6277
+ Wi as workItemScopeKey,
6278
+ _n as workProjectScopeKey,
6279
+ Vu as workRatio,
6280
+ Xi as workStatusKey,
6281
+ Ei as workTypeKey,
6255
6282
  xe as workingMsBetween,
6256
- kl as workstreamScopeKey
6283
+ $l as workstreamScopeKey
6257
6284
  };