@orangelogic/design-system 2.131.0 → 2.133.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (138) hide show
  1. package/library/chunks/{asset.D_VITxRH.js → asset.CcxcYY9d.js} +2 -2
  2. package/library/chunks/{button.DcInI7IV.js → button.DYoFn504.js} +1 -1
  3. package/library/chunks/calendar-grid.CvdcwfTo.js +34 -0
  4. package/library/chunks/checkbox.uH0uF0OV.js +198 -0
  5. package/library/chunks/{color-swatch-group.Cy-M_lbx.js → color-swatch-group.DlTVQ3Ul.js} +3 -3
  6. package/library/chunks/{color-swatch.U-wztpLf.js → color-swatch.0zyBEfL_.js} +1 -1
  7. package/library/chunks/{confirm-popover.DfAd2F8S.js → confirm-popover.DpVYvK20.js} +3 -3
  8. package/library/chunks/{date-picker.D0SJADN6.js → date-picker.DTUICGb9.js} +2 -2
  9. package/library/chunks/date.dSYNLBVO.js +77 -0
  10. package/library/chunks/{dialog.BlKHLwFx.js → dialog.BwBD_hJi.js} +2 -2
  11. package/library/chunks/{document-viewer.Dn_vUYCW.js → document-viewer.BM716ovi.js} +6 -6
  12. package/library/chunks/{dot-pagination.CNJWQ4zf.js → dot-pagination.B70lV5Av.js} +1 -1
  13. package/library/chunks/{file-on-demand.Dr05DdkU.js → file-on-demand.D-Ectby2.js} +9 -9
  14. package/library/chunks/{folder-select.DMpO7oQF.js → folder-select.DHV6f6TA.js} +48 -48
  15. package/library/chunks/{header.WRWyUU36.js → header.BMGvKrdP.js} +1 -1
  16. package/library/chunks/{i18n.NAH4U8Lw.js → i18n.DoMIwXr2.js} +61 -45
  17. package/library/chunks/{icon-button.COTH_z-J.js → icon-button.B-Jf9W3v.js} +1 -1
  18. package/library/chunks/{iframe.DvBR4KYU.js → iframe.Cdv6esyS.js} +1 -1
  19. package/library/chunks/image.BzmclWBR.js +150 -0
  20. package/library/chunks/{image.BC_hwk-b.js → image.SLqIVjqc.js} +1 -1
  21. package/library/chunks/{input.BRgVRr2i.js → input.CQNhMu4z.js} +1 -1
  22. package/library/chunks/{list-editor.CdMU7vNF.js → list-editor.BXY4UIAI.js} +9 -9
  23. package/library/chunks/{option.BH13eKSl.js → option.SCVixE2L.js} +1 -1
  24. package/library/chunks/{pagination.tSkuYrqk.js → pagination.BFE6Nk3_.js} +5 -5
  25. package/library/chunks/{tab-group.GA4X3LL2.js → tab-group.C-p2Dljr.js} +3 -3
  26. package/library/chunks/{table.C6YsaNOh.js → table.DuP4v5FN.js} +3581 -2656
  27. package/library/chunks/{tree.CbeHY8pn.js → tree.9PK8ifJd.js} +2 -2
  28. package/library/components/alert.js +2 -2
  29. package/library/components/asset-link-format.js +8 -8
  30. package/library/components/atoms.js +22 -22
  31. package/library/components/audio.js +2 -2
  32. package/library/components/border-input-group.js +2 -2
  33. package/library/components/breadcrumb.js +1 -1
  34. package/library/components/button.js +2 -2
  35. package/library/components/checkbox.js +18 -195
  36. package/library/components/color-picker.js +3 -3
  37. package/library/components/color-swatch-group.js +4 -4
  38. package/library/components/color-swatch.js +2 -2
  39. package/library/components/confirm-popover.js +4 -4
  40. package/library/components/copy-button.js +1 -1
  41. package/library/components/corner-position-input-group.js +3 -3
  42. package/library/components/cropper.js +1 -1
  43. package/library/components/date-calendar.js +10 -9
  44. package/library/components/details.js +1 -1
  45. package/library/components/dialog.js +3 -3
  46. package/library/components/diff.js +77 -51
  47. package/library/components/document-viewer.js +3 -3
  48. package/library/components/dot-pagination.js +2 -2
  49. package/library/components/drawer.js +2 -2
  50. package/library/components/dropdown.js +2 -2
  51. package/library/components/dynamic-select.js +4 -4
  52. package/library/components/e-chart.js +1 -1
  53. package/library/components/element-clamp.js +2 -2
  54. package/library/components/file-on-demand.js +10 -10
  55. package/library/components/folder-select.js +4 -4
  56. package/library/components/format-bytes.js +1 -1
  57. package/library/components/format-date.js +38 -23
  58. package/library/components/format-number.js +1 -1
  59. package/library/components/format-time.js +1 -1
  60. package/library/components/header.js +2 -2
  61. package/library/components/icon-button.js +2 -2
  62. package/library/components/iframe.js +2 -2
  63. package/library/components/image-comparer.js +1 -1
  64. package/library/components/image.js +2 -2
  65. package/library/components/input.js +2 -2
  66. package/library/components/line-clamp.js +1 -1
  67. package/library/components/list-editor.js +7 -7
  68. package/library/components/masonry.js +2 -2
  69. package/library/components/menu-item.js +2 -2
  70. package/library/components/menu.js +1 -1
  71. package/library/components/molecules.js +4 -4
  72. package/library/components/option.js +2 -2
  73. package/library/components/organisms.js +2 -2
  74. package/library/components/padding-input-group.js +1 -1
  75. package/library/components/pagination.js +6 -6
  76. package/library/components/popup.js +1 -1
  77. package/library/components/position-picker.js +1 -1
  78. package/library/components/progress-bar.js +1 -1
  79. package/library/components/progress-ring.js +1 -1
  80. package/library/components/range.js +1 -1
  81. package/library/components/rating.js +1 -1
  82. package/library/components/relative-time.js +1 -1
  83. package/library/components/select.js +2 -2
  84. package/library/components/shadow-input-group.js +1 -1
  85. package/library/components/share-option-list.js +1 -1
  86. package/library/components/sidebar.js +1 -1
  87. package/library/components/size-input-group.js +3 -3
  88. package/library/components/spinner.js +1 -1
  89. package/library/components/split-panel.js +1 -1
  90. package/library/components/tab-group.js +4 -4
  91. package/library/components/tab.js +2 -2
  92. package/library/components/table.js +16 -16
  93. package/library/components/tag.js +2 -2
  94. package/library/components/tooltip.js +1 -1
  95. package/library/components/tree-item.js +3 -3
  96. package/library/components/tree.js +2 -2
  97. package/library/components/typeface.js +2 -2
  98. package/library/components/types.js +38201 -38461
  99. package/library/components/video.js +2 -2
  100. package/library/package.json +1 -1
  101. package/library/packages/atoms/src/components/checkbox/checkbox.d.ts +3 -0
  102. package/library/packages/atoms/src/components/diff/utils/diff-worker-client.d.ts +2 -1
  103. package/library/packages/atoms/src/components/format-date/format-date.d.ts +8 -0
  104. package/library/packages/atoms/src/components/menu-item/menu-item.d.ts +2 -0
  105. package/library/packages/atoms/src/components/table/components/table-toolbar/table-dropdown-filter.d.ts +1 -1
  106. package/library/packages/atoms/src/components/table/components/table-toolbar/table-group-by-dropdown.d.ts +44 -0
  107. package/library/packages/atoms/src/components/table/components/table-toolbar/table-saved-search-dropdown.d.ts +1 -1
  108. package/library/packages/atoms/src/components/table/components/table-toolbar/table-toolbar.d.ts +33 -1
  109. package/library/packages/atoms/src/components/table/controllers/ajax-facets/ajax-facet-data-controller.d.ts +39 -0
  110. package/library/packages/atoms/src/components/table/controllers/ajax-facets/ajax-facet-filter-controller.d.ts +27 -0
  111. package/library/packages/atoms/src/components/table/{filter-controller.d.ts → controllers/filter-controller.d.ts} +24 -3
  112. package/library/packages/atoms/src/components/table/controllers/select-all-controller.d.ts +55 -0
  113. package/library/packages/atoms/src/components/table/table.d.ts +70 -1
  114. package/library/packages/events/src/cx-table-dropdown-filter-change.d.ts +1 -1
  115. package/library/packages/events/src/cx-table-export.d.ts +1 -1
  116. package/library/packages/events/src/cx-table-group-by-change.d.ts +8 -0
  117. package/library/packages/events/src/cx-table-select-all-change.d.ts +8 -0
  118. package/library/packages/events/src/events.d.ts +2 -0
  119. package/library/packages/hybrid/table-core/src/tabulator-tables/core/TabulatorFull.d.ts +1 -1
  120. package/library/packages/hybrid/table-core/src/tabulator-tables/modules/Format/defaults/formatters/avatar.d.ts +5 -0
  121. package/library/packages/hybrid/table-core/src/tabulator-tables/modules/Format/defaults/formatters/date.d.ts +12 -0
  122. package/library/packages/hybrid/table-core/src/tabulator-tables/modules/Format/defaults/formatters/diff.d.ts +2 -1
  123. package/library/packages/hybrid/table-core/src/tabulator-tables/modules/Format/defaults/formatters.d.ts +4 -0
  124. package/library/packages/hybrid/table-core/src/tabulator-tables/modules/GroupRows/Group.d.ts +1 -0
  125. package/library/packages/hybrid/table-core/src/tabulator-tables/modules/GroupRows/GroupRows.d.ts +7 -0
  126. package/library/packages/hybrid/table-core/src/tabulator-tables/modules/SelectRow/extensions/formatters/rowSelection.d.ts +1 -1
  127. package/library/packages/molecules/src/faceted-filter/faceted-filter.d.ts +2 -0
  128. package/library/packages/types/src/faceted-filter.d.ts +11 -0
  129. package/library/packages/types/src/format-date.d.ts +12 -0
  130. package/library/packages/types/src/table.d.ts +40 -21
  131. package/library/packages/utils/src/custom-element/i18n-utils.d.ts +7 -0
  132. package/library/packages/utils/src/custom-element/i18n.d.ts +1 -0
  133. package/library/react-web-component.d.ts +278 -246
  134. package/library/utils.js +86 -85
  135. package/package.json +1 -1
  136. package/library/assets/diff.worker-ClilI1xm.js +0 -1
  137. package/library/chunks/calendar-grid.CXYoS6VA.js +0 -108
  138. package/library/chunks/image.9qwbjGNb.js +0 -150
@@ -1,21 +1,21 @@
1
1
  import { C as Y } from "./icon.DnBh6-56.js";
2
- import { C as de } from "./input.BRgVRr2i.js";
2
+ import { C as de } from "./input.CQNhMu4z.js";
3
3
  import ee from "../components/line-clamp.js";
4
4
  import pe from "../components/select.js";
5
5
  import ue from "../components/tag.js";
6
- import { C as S, a as fe } from "./tree.CbeHY8pn.js";
6
+ import { C as $, a as fe } from "./tree.9PK8ifJd.js";
7
7
  import { n as l, C as B } from "./lib-cortex-element.CVMmyPMC.js";
8
8
  import { h as L, F as me, c as ye } from "./endpoints.6E17hFiK.js";
9
9
  import { M as P } from "./asset-link-format.QzzboHHE.js";
10
10
  import { c as te } from "./component.styles.CRO4Odto.js";
11
11
  import { c as W } from "./custom-element.L4WJXn1j.js";
12
- import { L as q } from "./i18n.NAH4U8Lw.js";
12
+ import { L as q } from "./i18n.DoMIwXr2.js";
13
13
  import { w as f } from "./watch.CThbualB.js";
14
14
  import { x as m, i as xe } from "./lit-element.jLBm65_O.js";
15
15
  import { r as x } from "./state.CSDxrqLd.js";
16
16
  import { e as re } from "./query.BBf1UFkC.js";
17
17
  import { r as ge } from "./choose.BTbF6BAn.js";
18
- import { C as se } from "./button.DcInI7IV.js";
18
+ import { C as se } from "./button.DYoFn504.js";
19
19
  import { d as be } from "./debounce.DaHuiSGU.js";
20
20
  import { g as G, p as Z, e as $e } from "./string.CbnVBzsd.js";
21
21
  import { o as y } from "./if-defined.BRoBj_Rp.js";
@@ -25,7 +25,7 @@ import { n as w } from "./when.Dr1es41R.js";
25
25
  import ve from "../components/space.js";
26
26
  import { g as Fe } from "./template.ClovJacp.js";
27
27
  import { e as Te } from "./class-map.BiVq-cVR.js";
28
- var v = /* @__PURE__ */ ((e) => (e.CortexPath = "Document.CortexPath", e.DocType = "CoreField.DocType", e.HasBrowserChildren = "Document.HasBrowserChildren", e.RepresentativeAssetId = "Document.DocumentDirectRepresentativeRID", e.TitleWithFallback = "CoreField.TitleWithFallback", e.rawDocSubtype = "Document.RawDocSubType", e))(v || {});
28
+ var S = /* @__PURE__ */ ((e) => (e.CortexPath = "Document.CortexPath", e.DocType = "CoreField.DocType", e.HasBrowserChildren = "Document.HasBrowserChildren", e.RepresentativeAssetId = "Document.DocumentDirectRepresentativeRID", e.TitleWithFallback = "CoreField.TitleWithFallback", e.rawDocSubtype = "Document.RawDocSubType", e))(S || {});
29
29
  const Ie = 50;
30
30
  async function H({
31
31
  allowedFolders: e,
@@ -36,12 +36,12 @@ async function H({
36
36
  includeDirectChild: p,
37
37
  limit: u = Ie,
38
38
  searchTerm: g,
39
- self: C,
39
+ self: I,
40
40
  start: N = 0,
41
41
  token: ne
42
42
  }) {
43
43
  let O = [], Q = p ?? !0;
44
- e && e.length > 0 && !s ? (O = e, C = !0, Q = !1) : s && (O = [s]);
44
+ e && e.length > 0 && !s ? (O = e, I = !0, Q = !1) : s && (O = [s]);
45
45
  try {
46
46
  return (await L.request({
47
47
  baseURL: t,
@@ -55,7 +55,7 @@ async function H({
55
55
  Limit: u,
56
56
  ObjectRecordIDs: O,
57
57
  SeeThru: !!g,
58
- Self: C,
58
+ Self: I,
59
59
  Start: N,
60
60
  Text: g || void 0,
61
61
  Token: ne || void 0
@@ -66,32 +66,32 @@ async function H({
66
66
  responseType: "json",
67
67
  transformResponse: [
68
68
  ...Array.isArray(L.defaults.transformResponse) ? L.defaults.transformResponse : [],
69
- (F, Re, R) => {
69
+ (v, Re, R) => {
70
70
  if (R !== void 0 && (R < 200 || R >= 300))
71
71
  return {
72
72
  data: [],
73
73
  hasMore: !1,
74
74
  totalCount: 0
75
75
  };
76
- if (!F || typeof F != "object")
76
+ if (!v || typeof v != "object")
77
77
  throw new Error("Invalid response format");
78
- const he = F.contentItems?.length ?? 0;
78
+ const he = v.contentItems?.length ?? 0;
79
79
  return {
80
- data: F.contentItems?.map((b) => {
81
- const E = b.fields[v.DocType] ?? "", U = b.fields[v.TitleWithFallback] ?? "", k = b.fields[v.CortexPath] ?? "", M = k.endsWith("/") && k.length > 1 ? k.slice(0, -1) : k;
80
+ data: v.contentItems?.map((b) => {
81
+ const E = b.fields[S.DocType] ?? "", U = b.fields[S.TitleWithFallback] ?? "", k = b.fields[S.CortexPath] ?? "", M = k.endsWith("/") && k.length > 1 ? k.slice(0, -1) : k;
82
82
  let j = M;
83
83
  return (E === P.Album || E === P.ProjectDocument) && (j = M ? `${M}/${U}` : U), {
84
84
  docType: E,
85
85
  fullPath: j,
86
- hasChildren: b.fields[v.HasBrowserChildren] === "1",
86
+ hasChildren: b.fields[S.HasBrowserChildren] === "1",
87
87
  id: b.recordID,
88
- isShared: b.fields[v.rawDocSubtype] === "DO_OR1ND000001913488",
89
- representativeAssetId: b.fields[v.RepresentativeAssetId] ?? "",
88
+ isShared: b.fields[S.rawDocSubtype] === "DO_OR1ND000001913488",
89
+ representativeAssetId: b.fields[S.RepresentativeAssetId] ?? "",
90
90
  title: U
91
91
  };
92
92
  }) ?? [],
93
- hasMore: N + he < F.totalCount,
94
- totalCount: F.totalCount
93
+ hasMore: N + he < v.totalCount,
94
+ totalCount: v.totalCount
95
95
  };
96
96
  }
97
97
  ],
@@ -105,7 +105,7 @@ async function H({
105
105
  };
106
106
  }
107
107
  }
108
- var _ = /* @__PURE__ */ ((e) => (e.Input = "input", e.Select = "select", e))(_ || {}), Ce = Object.defineProperty, _e = Object.getOwnPropertyDescriptor, d = (e, t, r, a) => {
108
+ var C = /* @__PURE__ */ ((e) => (e.Input = "input", e.Select = "select", e))(C || {}), Ce = Object.defineProperty, _e = Object.getOwnPropertyDescriptor, d = (e, t, r, a) => {
109
109
  for (var s = a > 1 ? void 0 : a ? _e(t, r) : t, p = e.length - 1, u; p >= 0; p--)
110
110
  (u = e[p]) && (s = (a ? u(t, r, s) : u(s)) || s);
111
111
  return a && s && Ce(t, r, s), s;
@@ -190,8 +190,8 @@ let o = class extends B {
190
190
  const g = $e(u);
191
191
  if (!g.path.trim() || !g.id.trim())
192
192
  continue;
193
- const C = Z(g.path);
194
- if (C.startsWith(r) && C !== r) {
193
+ const I = Z(g.path);
194
+ if (I.startsWith(r) && I !== r) {
195
195
  s = !0;
196
196
  break;
197
197
  }
@@ -222,7 +222,7 @@ o.dependencies = {
222
222
  "cx-icon": Y,
223
223
  "cx-line-clamp": ee,
224
224
  "cx-space": ve,
225
- "cx-tree-item": S
225
+ "cx-tree-item": $
226
226
  };
227
227
  d([
228
228
  re("cx-tree-item")
@@ -316,10 +316,10 @@ var De = Object.defineProperty, ke = Object.getOwnPropertyDescriptor, le = (e) =
316
316
  for (var s = a > 1 ? void 0 : a ? ke(t, r) : t, p = e.length - 1, u; p >= 0; p--)
317
317
  (u = e[p]) && (s = (a ? u(t, r, s) : u(s)) || s);
318
318
  return a && s && De(t, r, s), s;
319
- }, ae = (e, t, r) => t.has(e) || le("Cannot " + r), $ = (e, t, r) => (ae(e, t, "read from private field"), t.get(e)), z = (e, t, r) => t.has(e) ? le("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, r), J = (e, t, r, a) => (ae(e, t, "write to private field"), t.set(e, r), r), T, V, D;
319
+ }, ae = (e, t, r) => t.has(e) || le("Cannot " + r), F = (e, t, r) => (ae(e, t, "read from private field"), t.get(e)), z = (e, t, r) => t.has(e) ? le("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, r), J = (e, t, r, a) => (ae(e, t, "write to private field"), t.set(e, r), r), _, V, D;
320
320
  let n = class extends B {
321
321
  constructor() {
322
- super(...arguments), this.localize = new q(this), this.minQueryLength = 1, this.selection = "single", this.searchTerm = "", this.selectedValue = "", this.token = "", this.bearerToken = "", this.baseUrl = "", this.extraFolderId = "", this.extraFolderTitle = "", this.extraFolderIcon = "", this.seeThru = !1, this.extraFolderData = null, this.api = H, this.excludeVirtualFolders = !1, this.firstFetchCallback = null, this.autoPageSize = !1, this.data = [], this.hasMore = !1, this.loading = !1, this.preloadedFolders = [], this.currentRootIDsSet = /* @__PURE__ */ new Set(), this.removedIDs = [], z(this, T, !1), z(this, V, 10), z(this, D, /* @__PURE__ */ new Set());
322
+ super(...arguments), this.localize = new q(this), this.minQueryLength = 1, this.selection = "single", this.searchTerm = "", this.selectedValue = "", this.token = "", this.bearerToken = "", this.baseUrl = "", this.extraFolderId = "", this.extraFolderTitle = "", this.extraFolderIcon = "", this.seeThru = !1, this.extraFolderData = null, this.api = H, this.excludeVirtualFolders = !1, this.firstFetchCallback = null, this.autoPageSize = !1, this.data = [], this.hasMore = !1, this.loading = !1, this.preloadedFolders = [], this.currentRootIDsSet = /* @__PURE__ */ new Set(), this.removedIDs = [], z(this, _, !1), z(this, V, 10), z(this, D, /* @__PURE__ */ new Set());
323
323
  }
324
324
  get empty() {
325
325
  return !this.loading && this.data.length === 0;
@@ -406,10 +406,10 @@ let n = class extends B {
406
406
  }
407
407
  async handleFetchFolders() {
408
408
  const { data: e, hasMore: t } = await this.fetchFolders();
409
- $(this, T) || (e.length > 0 && this.firstFetchCallback?.(e), J(this, T, !0)), this.data = e, this.hasMore = t, this.loading = !1, this.seedSelectionFromValue(e), this.removePreloadedFolders(e), await this.preloadSelectedFolders();
409
+ F(this, _) || (e.length > 0 && this.firstFetchCallback?.(e), J(this, _, !0)), this.data = e, this.hasMore = t, this.loading = !1, this.seedSelectionFromValue(e), this.removePreloadedFolders(e), await this.preloadSelectedFolders();
410
410
  }
411
411
  async handleSelectedValueChange() {
412
- if (!$(this, T))
412
+ if (!F(this, _))
413
413
  return;
414
414
  const e = new Set(
415
415
  this.selectedValue.split(/[\s,]+/).filter(Boolean)
@@ -433,7 +433,7 @@ let n = class extends B {
433
433
  bearerToken: this.bearerToken,
434
434
  excludeVirtualFolders: this.excludeVirtualFolders,
435
435
  folderId: "",
436
- limit: $(this, T) ? 10 : $(this, V),
436
+ limit: F(this, V),
437
437
  searchTerm: this.searchTerm,
438
438
  seeThru: this.seeThru,
439
439
  start: 0,
@@ -462,7 +462,7 @@ let n = class extends B {
462
462
  ...this.data.map((s) => s.id),
463
463
  ...this.extraFolderData ? [this.extraFolderData.id] : [],
464
464
  ...this.preloadedFolders.map((s) => s.id),
465
- ...$(this, D),
465
+ ...F(this, D),
466
466
  ...[
467
467
  ...this.querySelectorAll(
468
468
  "cx-folder-select-tree-item"
@@ -473,7 +473,7 @@ let n = class extends B {
473
473
  );
474
474
  if (r.length === 0)
475
475
  return;
476
- r.forEach((s) => $(this, D).add(s));
476
+ r.forEach((s) => F(this, D).add(s));
477
477
  const a = [];
478
478
  if (await Promise.all(
479
479
  r.map(async (s) => {
@@ -495,7 +495,7 @@ let n = class extends B {
495
495
  } catch {
496
496
  }
497
497
  })
498
- ), r.forEach((s) => $(this, D).delete(s)), a.length > 0) {
498
+ ), r.forEach((s) => F(this, D).delete(s)), a.length > 0) {
499
499
  const s = new Set(this.preloadedFolders.map((u) => u.id)), p = a.filter((u) => !s.has(u.id));
500
500
  p.length > 0 && (this.preloadedFolders = [...this.preloadedFolders, ...p].sort(
501
501
  (u, g) => u.title.localeCompare(g.title)
@@ -543,7 +543,7 @@ let n = class extends B {
543
543
  )}`;
544
544
  }
545
545
  };
546
- T = /* @__PURE__ */ new WeakMap();
546
+ _ = /* @__PURE__ */ new WeakMap();
547
547
  V = /* @__PURE__ */ new WeakMap();
548
548
  D = /* @__PURE__ */ new WeakMap();
549
549
  n.dependencies = {
@@ -644,17 +644,17 @@ var Ve = Object.defineProperty, Pe = Object.getOwnPropertyDescriptor, ie = (e) =
644
644
  for (var s = a > 1 ? void 0 : a ? Pe(t, r) : t, p = e.length - 1, u; p >= 0; p--)
645
645
  (u = e[p]) && (s = (a ? u(t, r, s) : u(s)) || s);
646
646
  return a && s && Ve(t, r, s), s;
647
- }, oe = (e, t, r) => t.has(e) || ie("Cannot " + r), K = (e, t, r) => (oe(e, t, "read from private field"), r ? r.call(e) : t.get(e)), Oe = (e, t, r) => t.has(e) ? ie("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, r), X = (e, t, r, a) => (oe(e, t, "write to private field"), t.set(e, r), r), I;
647
+ }, oe = (e, t, r) => t.has(e) || ie("Cannot " + r), K = (e, t, r) => (oe(e, t, "read from private field"), r ? r.call(e) : t.get(e)), Oe = (e, t, r) => t.has(e) ? ie("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, r), X = (e, t, r, a) => (oe(e, t, "write to private field"), t.set(e, r), r), T;
648
648
  let i = class extends B {
649
649
  constructor() {
650
- super(), this.localize = new q(this), this.minQueryLength = 1, this.selection = "single", this.variant = _.Input, this.value = "", this.name = "", this.selectedLabel = "", this.baseUrl = "", this.open = !1, this.token = "", this.bearerToken = "", this.seeThru = !1, this.api = H, this.required = !1, this.form = void 0, this.excludeVirtualFolders = !1, this.extraFolderId = "", this.extraFolderTitle = "", this.extraFolderIcon = "", this.autoPageSize = !1, this.firstFetchCallback = null, this.searchTerm = "", Oe(this, I), this.selectGetOptionValue = this.selectGetOptionValue.bind(this), this.selectGetOptionLabel = this.selectGetOptionLabel.bind(this), this.selectGetOptionSelected = this.selectGetOptionSelected.bind(this), this.selectFilterCallback = this.selectFilterCallback.bind(this), this.selectSetOptionSelected = this.selectSetOptionSelected.bind(this), this.selectGetTag = this.selectGetTag.bind(this), this.updateWrappedApi();
650
+ super(), this.localize = new q(this), this.minQueryLength = 1, this.selection = "single", this.variant = C.Input, this.value = "", this.name = "", this.selectedLabel = "", this.baseUrl = "", this.open = !1, this.token = "", this.bearerToken = "", this.seeThru = !1, this.api = H, this.required = !1, this.form = void 0, this.excludeVirtualFolders = !1, this.extraFolderId = "", this.extraFolderTitle = "", this.extraFolderIcon = "", this.autoPageSize = !1, this.firstFetchCallback = null, this.searchTerm = "", Oe(this, T), this.selectGetOptionValue = this.selectGetOptionValue.bind(this), this.selectGetOptionLabel = this.selectGetOptionLabel.bind(this), this.selectGetOptionSelected = this.selectGetOptionSelected.bind(this), this.selectFilterCallback = this.selectFilterCallback.bind(this), this.selectSetOptionSelected = this.selectSetOptionSelected.bind(this), this.selectGetTag = this.selectGetTag.bind(this), this.updateWrappedApi();
651
651
  }
652
652
  updateWrappedApi() {
653
653
  if (!this.api) {
654
- X(this, I, void 0);
654
+ X(this, T, void 0);
655
655
  return;
656
656
  }
657
- X(this, I, async (e) => {
657
+ X(this, T, async (e) => {
658
658
  try {
659
659
  return await this.api(e);
660
660
  } catch (t) {
@@ -696,17 +696,17 @@ let i = class extends B {
696
696
  ), this.selectEl.handleDefaultSlotChange(), await this.selectEl.updateComplete, this.selectEl.displayLabel = this.searchTerm);
697
697
  }
698
698
  selectGetOptionValue(e) {
699
- return !e || !(e instanceof S) ? this.value : e.dataset.id || this.value;
699
+ return !e || !(e instanceof $) ? this.value : e.dataset.id || this.value;
700
700
  }
701
701
  selectGetOptionLabel(e) {
702
- return !e || !(e instanceof S) ? this.selectedLabel : e.dataset.name || this.selectedLabel;
702
+ return !e || !(e instanceof $) ? this.selectedLabel : e.dataset.name || this.selectedLabel;
703
703
  }
704
704
  selectGetOptionSelected(e) {
705
- if (!(!e || !(e instanceof S)))
705
+ if (!(!e || !(e instanceof $)))
706
706
  return e.selected;
707
707
  }
708
708
  selectFilterCallback(e) {
709
- return !(!e || !(e instanceof S));
709
+ return !(!e || !(e instanceof $));
710
710
  }
711
711
  /**
712
712
  * Custom tag renderer for cx-select multi mode. Identical visuals to the
@@ -723,11 +723,11 @@ let i = class extends B {
723
723
  remove-button:tag__remove-button,
724
724
  remove-button__base:tag__remove-button__base
725
725
  " removable @cx-remove=${(r) => {
726
- r.stopPropagation(), e instanceof S && (e.selected = !1);
726
+ r.stopPropagation(), e instanceof $ && (e.selected = !1);
727
727
  }}><cx-line-clamp lines="1">${this.selectGetOptionLabel(e)}</cx-line-clamp></cx-tag>`;
728
728
  }
729
729
  selectSetOptionSelected(e, t) {
730
- if (!(!e || !(e instanceof S)) && this.selection !== "multiple") {
730
+ if (!(!e || !(e instanceof $)) && this.selection !== "multiple") {
731
731
  if (t === void 0) {
732
732
  e.selected = !e.selected;
733
733
  return;
@@ -748,7 +748,7 @@ let i = class extends B {
748
748
  }
749
749
  }
750
750
  async handleVariantChange() {
751
- this.variant === _.Select && (await this.updateComplete, this.updateFunctionProps());
751
+ this.variant === C.Select && (await this.updateComplete, this.updateFunctionProps());
752
752
  }
753
753
  handleValueChange() {
754
754
  this.selectEl && (this.searchTerm = "", this.selectEl.getOptionValue = this.selectGetOptionValue, this.selectEl.getOptionLabel = this.selectGetOptionLabel, this.selectEl.getOptionSelected = this.selectGetOptionSelected, this.selectEl.filterCallback = this.selectFilterCallback, this.selectEl.setOptionSelected = this.selectSetOptionSelected, this.selectEl.getTag = this.selectGetTag, this.selectEl.handleDefaultSlotChange());
@@ -756,17 +756,17 @@ let i = class extends B {
756
756
  render() {
757
757
  return m`<div class="folder-select">${ge(this.variant, [
758
758
  [
759
- _.Input,
760
- () => m`<cx-input class="folder-select__search" aria-label=${this.localize.term("searchFolders")} placeholder=${`${this.localize.term("searchFolders")}...`} value=${this.searchTerm} clearable @cx-input=${this.handleSearchTermInputChange}><cx-icon name="search" slot="prefix"></cx-icon></cx-input><cx-folder-select-tree class="folder-select__tree" base-url=${this.baseUrl} extra-folder-id=${this.extraFolderId} extra-folder-title=${this.extraFolderTitle} extra-folder-icon=${this.extraFolderIcon} min-query-length=${this.minQueryLength} search-term=${this.searchTerm} selected-value=${this.value} selection=${this.selection} token=${this.token} bearer-token=${this.bearerToken} ?exclude-virtual-folders=${this.excludeVirtualFolders} ?see-thru=${this.seeThru} ?auto-page-size=${this.autoPageSize} .api=${K(this, I)} .firstFetchCallback=${this.firstFetchCallback}></cx-folder-select-tree>`
759
+ C.Input,
760
+ () => m`<cx-input class="folder-select__search" aria-label=${this.localize.term("searchFolders")} placeholder=${`${this.localize.term("searchFolders")}...`} value=${this.searchTerm} clearable @cx-input=${this.handleSearchTermInputChange}><cx-icon name="search" slot="prefix"></cx-icon></cx-input><cx-folder-select-tree class="folder-select__tree" base-url=${this.baseUrl} extra-folder-id=${this.extraFolderId} extra-folder-title=${this.extraFolderTitle} extra-folder-icon=${this.extraFolderIcon} min-query-length=${this.minQueryLength} search-term=${this.searchTerm} selected-value=${this.value} selection=${this.selection} token=${this.token} bearer-token=${this.bearerToken} ?exclude-virtual-folders=${this.excludeVirtualFolders} ?see-thru=${this.seeThru} ?auto-page-size=${this.autoPageSize} .api=${K(this, T)} .firstFetchCallback=${this.firstFetchCallback}></cx-folder-select-tree>`
761
761
  ],
762
762
  [
763
- _.Select,
764
- () => m`<cx-select clearable hoist lazy name=${this.name} value=${this.value} .form=${this.form} ?required=${this.required} ?multiple=${this.selection === "multiple"} @input=${this.handleSearchTermSelectChange} @cx-clear=${this.handleSelectClear} @cx-selected-change=${this.handleTreeSelectedChange} allow-freetext><cx-folder-select-tree base-url=${this.baseUrl} extra-folder-id=${this.extraFolderId} extra-folder-title=${this.extraFolderTitle} extra-folder-icon=${this.extraFolderIcon} min-query-length=${this.minQueryLength} search-term=${this.searchTerm} selected-value=${this.value} selection=${this.selection} token=${this.token} bearer-token=${this.bearerToken} ?exclude-virtual-folders=${this.excludeVirtualFolders} ?see-thru=${this.seeThru} ?auto-page-size=${this.autoPageSize} .api=${K(this, I)} .firstFetchCallback=${this.firstFetchCallback}></cx-folder-select-tree></cx-select>`
763
+ C.Select,
764
+ () => m`<cx-select clearable hoist lazy name=${this.name} value=${this.value} .form=${this.form} ?required=${this.required} ?multiple=${this.selection === "multiple"} @input=${this.handleSearchTermSelectChange} @cx-clear=${this.handleSelectClear} @cx-selected-change=${this.handleTreeSelectedChange} allow-freetext><cx-folder-select-tree base-url=${this.baseUrl} extra-folder-id=${this.extraFolderId} extra-folder-title=${this.extraFolderTitle} extra-folder-icon=${this.extraFolderIcon} min-query-length=${this.minQueryLength} search-term=${this.searchTerm} selected-value=${this.value} selection=${this.selection} token=${this.token} bearer-token=${this.bearerToken} ?exclude-virtual-folders=${this.excludeVirtualFolders} ?see-thru=${this.seeThru} ?auto-page-size=${this.autoPageSize} .api=${K(this, T)} .firstFetchCallback=${this.firstFetchCallback}></cx-folder-select-tree></cx-select>`
765
765
  ]
766
766
  ])}</div>`;
767
767
  }
768
768
  };
769
- I = /* @__PURE__ */ new WeakMap();
769
+ T = /* @__PURE__ */ new WeakMap();
770
770
  i.styles = [te, we];
771
771
  i.dependencies = {
772
772
  "cx-folder-select-tree": n,
@@ -879,6 +879,6 @@ i = c([
879
879
  ], i);
880
880
  export {
881
881
  i as C,
882
- _ as F,
882
+ C as F,
883
883
  H as a
884
884
  };
@@ -3,7 +3,7 @@ import { n as c, C as b } from "./lib-cortex-element.CVMmyPMC.js";
3
3
  import { c as k } from "./component.styles.CRO4Odto.js";
4
4
  import { i as p } from "./lit-element.jLBm65_O.js";
5
5
  import { c as v } from "./custom-element.L4WJXn1j.js";
6
- import { L as y } from "./i18n.NAH4U8Lw.js";
6
+ import { L as y } from "./i18n.DoMIwXr2.js";
7
7
  import { w } from "./watch.CThbualB.js";
8
8
  import { e as m } from "./query.BBf1UFkC.js";
9
9
  import { e as u } from "./class-map.BiVq-cVR.js";
@@ -1,119 +1,134 @@
1
- import { p as b } from "./purify.es.BIuh5IAZ.js";
2
- const l = /* @__PURE__ */ new Set(), v = new MutationObserver(f), n = /* @__PURE__ */ new Map(), h = /* @__PURE__ */ new Map();
3
- let d = document.documentElement.dir || "ltr", m = document.documentElement.lang || navigator.language, r;
4
- v.observe(document.documentElement, {
1
+ import { p as v } from "./purify.es.BIuh5IAZ.js";
2
+ const A = /* @__PURE__ */ new Set(["weekday", "era", "year", "month", "day"]), T = /* @__PURE__ */ new Set(["hour", "minute", "second", "dayPeriod", "timeZoneName"]), u = /* @__PURE__ */ new Set(), C = new MutationObserver(y), n = /* @__PURE__ */ new Map(), g = /* @__PURE__ */ new Map();
3
+ let h = document.documentElement.dir || "ltr", f = document.documentElement.lang || navigator.language, r;
4
+ C.observe(document.documentElement, {
5
5
  attributeFilter: ["dir", "lang"],
6
6
  attributes: !0
7
7
  });
8
- function T(e) {
9
- return `${e.dir || d}`.toLowerCase();
8
+ function k(e) {
9
+ return `${e.dir || h}`.toLowerCase();
10
10
  }
11
- function u(...e) {
11
+ function m(...e) {
12
12
  e.map((t) => {
13
13
  const o = t.$code.toLowerCase();
14
14
  n.has(o) ? n.set(o, { ...n.get(o), ...t }) : n.set(o, t), r || (r = t);
15
15
  });
16
16
  }
17
- function g(...e) {
18
- if (u(...e), globalThis.WC_TRANSLATION) {
17
+ function w(...e) {
18
+ if (m(...e), globalThis.WC_TRANSLATION) {
19
19
  const t = { ...globalThis.WC_TRANSLATION };
20
- typeof t.$code == "string" && u(t);
20
+ typeof t.$code == "string" && m(t);
21
21
  }
22
22
  if (globalThis.LANGUAGE_NAMES) {
23
23
  const t = { ...globalThis.LANGUAGE_NAMES };
24
- Object.entries(t).forEach(([o, a]) => {
25
- h.set(o.replace(/_/g, "-").toLowerCase(), a);
24
+ Object.entries(t).forEach(([o, i]) => {
25
+ g.set(o.replace(/_/g, "-").toLowerCase(), i);
26
26
  });
27
27
  }
28
- f();
28
+ y();
29
29
  }
30
- function f() {
31
- d = document.documentElement.dir || "ltr", m = document.documentElement.lang || navigator.language, [...l.keys()].forEach((e) => {
30
+ function y() {
31
+ h = document.documentElement.dir || "ltr", f = document.documentElement.lang || navigator.language, [...u.keys()].forEach((e) => {
32
32
  typeof e.requestUpdate == "function" && e.requestUpdate();
33
33
  });
34
34
  }
35
- let A = class {
35
+ let S = class {
36
36
  constructor(t) {
37
37
  this.host = t, this.host.addController(this);
38
38
  }
39
39
  hostConnected() {
40
- l.add(this.host);
40
+ u.add(this.host);
41
41
  }
42
42
  hostDisconnected() {
43
- l.delete(this.host);
43
+ u.delete(this.host);
44
44
  }
45
45
  /**
46
46
  * Gets the host element's directionality as determined by the `dir` attribute. The return value is transformed to
47
47
  * lowercase.
48
48
  */
49
49
  dir() {
50
- return `${this.host.dir || d}`.toLowerCase();
50
+ return `${this.host.dir || h}`.toLowerCase();
51
51
  }
52
52
  /**
53
53
  * Gets the host element's language as determined by the `lang` attribute. The return value is transformed to
54
54
  * lowercase.
55
55
  */
56
56
  lang() {
57
- return `${this.host.lang || m}`.toLowerCase();
57
+ return `${this.host.lang || f}`.toLowerCase();
58
58
  }
59
59
  getTranslationData(t) {
60
- let o, a = "", i = "";
60
+ let o, i = "", a = "";
61
61
  try {
62
- o = new Intl.Locale(t.replace(/_/g, "-")), a = o?.language?.toLowerCase() ?? "", i = o?.region?.toLowerCase() ?? "";
62
+ o = new Intl.Locale(t.replace(/_/g, "-")), i = o?.language?.toLowerCase() ?? "", a = o?.region?.toLowerCase() ?? "";
63
63
  } catch {
64
- const [c, p] = t.replace(/_/g, "-").split("-");
65
- a = c ? c.toLowerCase() : "", i = p ? p.toLowerCase() : "", o = { language: a, region: i };
64
+ const [l, p] = t.replace(/_/g, "-").split("-");
65
+ i = l ? l.toLowerCase() : "", a = p ? p.toLowerCase() : "", o = { language: i, region: a };
66
66
  }
67
- const s = i && n.get(`${a}-${i}`) ? n.get(`${a}-${i}`) : void 0, y = n.get(a);
68
- return { language: a, locale: o, primary: s, region: i, secondary: y };
67
+ const s = a && n.get(`${i}-${a}`) ? n.get(`${i}-${a}`) : void 0, d = n.get(i);
68
+ return { language: i, locale: o, primary: s, region: a, secondary: d };
69
69
  }
70
70
  /** Determines if the specified term exists, optionally checking the fallback translation. */
71
71
  exists(t, o) {
72
- const { primary: a, secondary: i } = this.getTranslationData(
72
+ const { primary: i, secondary: a } = this.getTranslationData(
73
73
  o.lang ?? this.lang()
74
74
  );
75
75
  return o = {
76
76
  includeFallback: !1,
77
77
  ...o
78
- }, !!(a && a[t] || i && i[t] || o.includeFallback && r && r[t]);
78
+ }, !!(i && i[t] || a && a[t] || o.includeFallback && r && r[t]);
79
79
  }
80
80
  /** Outputs a translated term. */
81
81
  term(t, ...o) {
82
- const { primary: a, secondary: i } = this.getTranslationData(this.lang());
82
+ const { primary: i, secondary: a } = this.getTranslationData(this.lang());
83
83
  let s;
84
- if (a && a[t])
85
- s = a[t];
86
- else if (i && i[t])
84
+ if (i && i[t])
87
85
  s = i[t];
86
+ else if (a && a[t])
87
+ s = a[t];
88
88
  else if (r && r[t])
89
89
  s = r[t];
90
90
  else
91
91
  return String(t);
92
- return typeof s == "function" ? b.sanitize(s(...o)) : s;
92
+ return typeof s == "function" ? v.sanitize(s(...o)) : s;
93
93
  }
94
94
  languageName(t) {
95
- return String(h.get(t) ?? "");
95
+ return String(g.get(t) ?? "");
96
96
  }
97
97
  /** Outputs a localized date in the specified format. */
98
98
  date(t, o) {
99
99
  return t = new Date(t), new Intl.DateTimeFormat(this.lang(), o).format(t);
100
100
  }
101
+ /**
102
+ * Outputs a localized date/time without the locale connector literal
103
+ * (e.g. " at " in en-US) that Intl.DateTimeFormat inserts between date and
104
+ * time parts when both are present. Uses formatToParts() and replaces the
105
+ * connector literal with a plain space.
106
+ */
107
+ dateWithoutConnector(t, o) {
108
+ const i = new Date(t), a = new Intl.DateTimeFormat(this.lang(), o).formatToParts(i);
109
+ return a.map((s, d) => {
110
+ if (s.type !== "literal")
111
+ return s.value;
112
+ const c = a[d - 1], l = a[d + 1];
113
+ return c != null && A.has(c.type) && l != null && T.has(l.type) ? " " : s.value;
114
+ }).join("");
115
+ }
101
116
  /** Outputs a localized number in the specified format. */
102
117
  number(t, o) {
103
118
  return t = Number(t), isNaN(t) ? "" : new Intl.NumberFormat(this.lang(), o).format(t);
104
119
  }
105
120
  /** Outputs a localized time in relative format. */
106
- relativeTime(t, o, a) {
121
+ relativeTime(t, o, i) {
107
122
  if (t === 0 || o === "second" && t < 0 && t > -10)
108
123
  return "Just now";
109
- const i = new Intl.RelativeTimeFormat(this.lang(), a).format(
124
+ const a = new Intl.RelativeTimeFormat(this.lang(), i).format(
110
125
  t,
111
126
  o
112
127
  );
113
- return t > 0 ? i.replace("in ", "").concat(" left") : i;
128
+ return t > 0 ? a.replace("in ", "").concat(" left") : a;
114
129
  }
115
130
  };
116
- const w = {
131
+ const b = {
117
132
  $code: "en-us",
118
133
  $dir: "ltr",
119
134
  $name: "English",
@@ -518,6 +533,7 @@ const w = {
518
533
  expo: "Expo",
519
534
  export: "Export",
520
535
  exportAsCsv: "Export as CSV",
536
+ exportAsPdf: "Export as PDF",
521
537
  exportAsXml: "Export as XML",
522
538
  extension: "Extension",
523
539
  externalLink: "External link",
@@ -557,7 +573,7 @@ const w = {
557
573
  fontColor: "Font color",
558
574
  fontKit: "Font kit",
559
575
  fontKitPreview: "Font kit preview",
560
- fontNthOfTotalFonts: (e, t, o, a, i) => `Font ${t} of ${e}: ${o} ${a} ${i}`,
576
+ fontNthOfTotalFonts: (e, t, o, i, a) => `Font ${t} of ${e}: ${o} ${i} ${a}`,
561
577
  fontShowcase: "Font showcase",
562
578
  fontSize: "Font size",
563
579
  fontSizes: "Font sizes",
@@ -1154,12 +1170,12 @@ const w = {
1154
1170
  zoomOut: "Zoom out",
1155
1171
  zoomToFit: "Zoom to fit"
1156
1172
  };
1157
- g(w);
1158
- class k extends A {
1173
+ w(b);
1174
+ class F extends S {
1159
1175
  }
1160
- g(w);
1176
+ w(b);
1161
1177
  export {
1162
- k as L,
1163
- T as d,
1164
- g as r
1178
+ F as L,
1179
+ k as d,
1180
+ w as r
1165
1181
  };
@@ -1,7 +1,7 @@
1
1
  import { n as r, C as g } from "./lib-cortex-element.CVMmyPMC.js";
2
2
  import { c as p } from "./component.styles.CRO4Odto.js";
3
3
  import { c as h } from "./custom-element.L4WJXn1j.js";
4
- import { L as m } from "./i18n.NAH4U8Lw.js";
4
+ import { L as m } from "./i18n.DoMIwXr2.js";
5
5
  import { r as f } from "./state.CSDxrqLd.js";
6
6
  import { e as v } from "./query.BBf1UFkC.js";
7
7
  import { e as y } from "./class-map.BiVq-cVR.js";
@@ -1,7 +1,7 @@
1
1
  import { n as r, C as d } from "./lib-cortex-element.CVMmyPMC.js";
2
2
  import { c as h } from "./component.styles.CRO4Odto.js";
3
3
  import { c as y } from "./custom-element.L4WJXn1j.js";
4
- import { L as u } from "./i18n.NAH4U8Lw.js";
4
+ import { L as u } from "./i18n.DoMIwXr2.js";
5
5
  import { w as g } from "./watch.CThbualB.js";
6
6
  import { i as v, x as p } from "./lit-element.jLBm65_O.js";
7
7
  import { e as b } from "./query.BBf1UFkC.js";