@orangelogic/design-system 2.113.0 → 2.115.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 (146) hide show
  1. package/library/chunks/asset.CtPQLZOf.js +607 -0
  2. package/library/chunks/{button.DIvU_uFU.js → button.DwJEeW2t.js} +1 -1
  3. package/library/chunks/{color-swatch-group.DV5uB8OC.js → color-swatch-group.DjjSIHSV.js} +7 -7
  4. package/library/chunks/{color-swatch.BoUZGGs4.js → color-swatch.DVzEaNeL.js} +1 -1
  5. package/library/chunks/{confirm-popover.DS9HIy3c.js → confirm-popover.BifwpSuf.js} +3 -3
  6. package/library/chunks/{dialog.DyT-Nai2.js → dialog.BYCWepBc.js} +2 -2
  7. package/library/chunks/{document-viewer.AiKX3RO6.js → document-viewer.BIC9iYpZ.js} +1237 -1233
  8. package/library/chunks/{dot-pagination.CKbL6eN_.js → dot-pagination.C4l5vKor.js} +1 -1
  9. package/library/chunks/{endpoints.DBlquU2-.js → endpoints.CDX5PgQz.js} +251 -251
  10. package/library/chunks/{file-on-demand.h8tCgq51.js → file-on-demand.AwMj4AfO.js} +246 -227
  11. package/library/chunks/{folder-select.eoufobYO.js → folder-select.8xNjeJfp.js} +5 -5
  12. package/library/chunks/{header.BUp3_oeJ.js → header.Cf9ujCpg.js} +3 -3
  13. package/library/chunks/{i18n.C21qyGi6.js → i18n.CH-wak_P.js} +3 -1
  14. package/library/chunks/{icon-button.DxkJ-cp-.js → icon-button.CQiBjznj.js} +1 -1
  15. package/library/chunks/{iframe.CwxozWMt.js → iframe.BQPVygBJ.js} +1 -1
  16. package/library/chunks/{image.B-YcKRop.js → image.cT-FziNS.js} +1 -1
  17. package/library/chunks/{input.DdeXWD_F.js → input.CH4lKxPM.js} +1 -1
  18. package/library/chunks/{list-editor.Qx2ecTcL.js → list-editor.7zNWfBuW.js} +13 -13
  19. package/library/chunks/{option.CcGRV3jj.js → option.Bvh35v8S.js} +10 -10
  20. package/library/chunks/{pagination.CgAt4Keg.js → pagination.zQ2FFtxB.js} +5 -5
  21. package/library/chunks/{tab-group.hfUY7YE7.js → tab-group.DvMX02hY.js} +3 -3
  22. package/library/chunks/{table.CP3oGDY1.js → table.BvbReIZh.js} +46 -45
  23. package/library/chunks/{time.BiQnh9wt.js → time.BSmpFe2G.js} +2 -2
  24. package/library/chunks/{tree.YxFs3Tke.js → tree.Btf2Q4YZ.js} +10 -7
  25. package/library/chunks/waveform.1U9U_0rd.js +60 -0
  26. package/library/components/alert.js +2 -2
  27. package/library/components/asset-link-format.js +6 -6
  28. package/library/components/atoms.js +129 -131
  29. package/library/components/audio.js +132 -183
  30. package/library/components/border-input-group.js +2 -2
  31. package/library/components/breadcrumb.js +1 -1
  32. package/library/components/button.js +2 -2
  33. package/library/components/color-picker.js +3 -3
  34. package/library/components/color-swatch-group.js +4 -4
  35. package/library/components/color-swatch.js +2 -2
  36. package/library/components/confirm-popover.js +4 -4
  37. package/library/components/copy-button.js +1 -1
  38. package/library/components/corner-position-input-group.js +3 -3
  39. package/library/components/date-calendar.js +1 -1
  40. package/library/components/details.js +1 -1
  41. package/library/components/dialog.js +3 -3
  42. package/library/components/divider.js +15 -15
  43. package/library/components/document-viewer.js +3 -3
  44. package/library/components/dot-pagination.js +2 -2
  45. package/library/components/drawer.js +2 -2
  46. package/library/components/dropdown.js +2 -2
  47. package/library/components/dynamic-select.js +4 -4
  48. package/library/components/e-chart.js +1 -1
  49. package/library/components/element-clamp.js +2 -2
  50. package/library/components/file-on-demand.js +10 -10
  51. package/library/components/folder-select.js +5 -5
  52. package/library/components/format-bytes.js +1 -1
  53. package/library/components/format-date.js +1 -1
  54. package/library/components/format-number.js +1 -1
  55. package/library/components/format-time.js +2 -2
  56. package/library/components/header.js +2 -2
  57. package/library/components/icon-button.js +2 -2
  58. package/library/components/iframe.js +2 -2
  59. package/library/components/image-comparer.js +1 -1
  60. package/library/components/image.js +2 -2
  61. package/library/components/input.js +2 -2
  62. package/library/components/line-clamp.js +1 -1
  63. package/library/components/list-editor.js +7 -7
  64. package/library/components/masonry.js +2 -2
  65. package/library/components/menu-item.js +1 -1
  66. package/library/components/menu.js +3 -3
  67. package/library/components/molecules.js +4 -4
  68. package/library/components/option.js +2 -2
  69. package/library/components/organisms.js +2 -2
  70. package/library/components/padding-input-group.js +1 -1
  71. package/library/components/pagination.js +6 -6
  72. package/library/components/popup.js +1 -1
  73. package/library/components/position-picker.js +1 -1
  74. package/library/components/progress-bar.js +1 -1
  75. package/library/components/progress-ring.js +1 -1
  76. package/library/components/radio-button.js +10 -10
  77. package/library/components/radio-card.js +6 -6
  78. package/library/components/radio.js +2 -2
  79. package/library/components/range.js +1 -1
  80. package/library/components/rating.js +1 -1
  81. package/library/components/relative-time.js +1 -1
  82. package/library/components/resize-observer.js +3 -3
  83. package/library/components/select.js +7 -7
  84. package/library/components/shadow-input-group.js +1 -1
  85. package/library/components/share-option-list.js +10 -10
  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 +10 -10
  93. package/library/components/tag.js +2 -2
  94. package/library/components/tooltip.js +1 -1
  95. package/library/components/tree-item.js +2 -2
  96. package/library/components/tree.js +2 -2
  97. package/library/components/typeface.js +2 -2
  98. package/library/components/types.js +33324 -32768
  99. package/library/components/video.js +2 -2
  100. package/library/package.json +1 -1
  101. package/library/packages/atoms/src/components/audio/audio.d.ts +36 -28
  102. package/library/packages/atoms/src/components/divider/divider.d.ts +1 -1
  103. package/library/packages/atoms/src/components/option/option.d.ts +1 -1
  104. package/library/packages/atoms/src/components/radio/radio.d.ts +1 -1
  105. package/library/packages/atoms/src/components/radio-button/radio-button.d.ts +1 -1
  106. package/library/packages/atoms/src/components/radio-card/radio-card.d.ts +1 -1
  107. package/library/packages/atoms/src/components/tree/tree.d.ts +1 -0
  108. package/library/packages/atoms/src/index.d.ts +0 -1
  109. package/library/packages/events/src/cx-facet-change.d.ts +16 -0
  110. package/library/packages/events/src/cx-faceted-filter-change.d.ts +6 -1
  111. package/library/packages/events/src/events.d.ts +1 -0
  112. package/library/packages/{atoms/src/components → molecules/src}/faceted-filter/components/facet/facet.d.ts +9 -9
  113. package/library/packages/molecules/src/faceted-filter/components/facet/facet.styles.d.ts +2 -0
  114. package/library/packages/molecules/src/faceted-filter/components/facet-date-picker/facet-date-picker.d.ts +43 -0
  115. package/library/packages/molecules/src/faceted-filter/components/facet-date-range/facet-date-range.d.ts +51 -0
  116. package/library/packages/molecules/src/faceted-filter/facet-adapters.d.ts +12 -0
  117. package/library/packages/{atoms/src/components → molecules/src}/faceted-filter/faceted-filter.d.ts +25 -14
  118. package/library/packages/molecules/src/faceted-filter/faceted-filter.styles.d.ts +2 -0
  119. package/library/packages/molecules/src/icon-picker/icon-picker.d.ts +1 -1
  120. package/library/packages/molecules/src/index.d.ts +4 -0
  121. package/library/packages/molecules/src/share-option-list/share-option-list.d.ts +1 -1
  122. package/library/packages/organisms/src/asset-transformation-dialog/asset-transformation-dialog.d.ts +1 -1
  123. package/library/packages/organisms/src/carousel/carousel.d.ts +1 -0
  124. package/library/packages/organisms/src/content-builder/components/gallery-config/gallery-config.d.ts +1 -0
  125. package/library/packages/organisms/src/content-builder/components/page-picker/page-picker.d.ts +1 -0
  126. package/library/packages/organisms/src/content-builder/configs/audio.d.ts +1 -1
  127. package/library/packages/organisms/src/content-builder/configs-controller.d.ts +2 -2
  128. package/library/packages/organisms/src/file-on-demand/components/file-on-demand-pinned-status.ts/file-on-demand-pinned-status.d.ts +2 -0
  129. package/library/packages/organisms/src/file-on-demand/file-on-demand.d.ts +1 -0
  130. package/library/packages/services/src/api/asset/asset.d.ts +3 -1
  131. package/library/packages/services/src/api/endpoints.d.ts +2 -0
  132. package/library/packages/tools/src/fetch-asset/fetch-asset.d.ts +6 -0
  133. package/library/packages/tools/src/fetch-image/fetch-image.d.ts +11 -4
  134. package/library/packages/types/src/faceted-filter.d.ts +71 -2
  135. package/library/packages/utils/src/custom-element/i18n.d.ts +3 -1
  136. package/library/packages/utils/src/image/index.d.ts +1 -0
  137. package/library/packages/utils/src/image/waveform.d.ts +29 -0
  138. package/library/react-web-component.d.ts +440 -317
  139. package/library/utils.js +174 -171
  140. package/package.json +1 -1
  141. package/library/chunks/asset.HL1qMnhg.js +0 -458
  142. package/library/chunks/wavesurfer.esm.Cwi1pz64.js +0 -1276
  143. package/library/components/faceted-filter.d.ts +0 -3
  144. package/library/components/faceted-filter.js +0 -295
  145. /package/library/packages/{atoms/src/components/faceted-filter/components/facet/facet.styles.d.ts → molecules/src/faceted-filter/components/facet-date-picker/facet-date-picker.styles.d.ts} +0 -0
  146. /package/library/packages/{atoms/src/components/faceted-filter/faceted-filter.styles.d.ts → molecules/src/faceted-filter/components/facet-date-range/facet-date-range.styles.d.ts} +0 -0
@@ -1,45 +1,27 @@
1
- import { r as m, R as y } from "../chunks/resizable-component.styles.DpK0TTP5.js";
1
+ import { r as f, R as y } from "../chunks/resizable-component.styles.DpK0TTP5.js";
2
2
  import { c as v } from "../chunks/component.styles.CRO4Odto.js";
3
- import { c as g } from "../chunks/custom-element.L4WJXn1j.js";
4
- import { L as S } from "../chunks/i18n.C21qyGi6.js";
5
- import { w as f } from "../chunks/watch.CThbualB.js";
6
- import { i as w, x as p } from "../chunks/lit-element.jLBm65_O.js";
7
- import { n as c } from "../chunks/lib-cortex-element.CVMmyPMC.js";
8
- import { r as u } from "../chunks/state.CSDxrqLd.js";
9
- import { r as x } from "../chunks/query-async.CTgXGyQ5.js";
3
+ import { U as u, g, f as x, D as w } from "../chunks/time.BSmpFe2G.js";
4
+ import { c as _ } from "../chunks/custom-element.L4WJXn1j.js";
5
+ import { L as S } from "../chunks/i18n.CH-wak_P.js";
6
+ import { w as m } from "../chunks/watch.CThbualB.js";
7
+ import { e as b, b as P } from "../chunks/waveform.1U9U_0rd.js";
8
+ import { i as $, b as z, x as h } from "../chunks/lit-element.jLBm65_O.js";
9
+ import { n } from "../chunks/lib-cortex-element.CVMmyPMC.js";
10
+ import { r as s } from "../chunks/state.CSDxrqLd.js";
11
+ import { e as E } from "../chunks/query.BBf1UFkC.js";
10
12
  import { e as C } from "../chunks/class-map.BiVq-cVR.js";
11
13
  import { n as d } from "../chunks/when.Dr1es41R.js";
12
- import { C as b } from "../chunks/icon-button.DxkJ-cp-.js";
13
- import { C as W } from "../chunks/typography.DJC_UXgs.js";
14
- const _ = w`:host{background-color:var(--background-color,var(--cx-color-neutral-0));border-radius:var(--border-radius,0px);border:var(--border,0px);box-sizing:border-box;color:var(--text-color,var(--cx-color-neutral));height:var(--height,auto);width:var(--width,100%);border-style:solid;display:block;position:relative}.audio{border-radius:inherit;gap:var(--cx-spacing-x-small,4px);height:100%;padding:var(--cx-spacing-small,8px);flex-direction:column;justify-content:center;display:flex;overflow:hidden}.audio--empty{height:var(--height,200px);min-height:var(--min-height,100%);padding:0}.audio--empty:before{background-color:var(--cx-color-neutral-1000);color:var(--cx-color-neutral-0);content:attr(data-empty-label);font-family:var(--cx-font-sans);font-size:clamp(var(--cx-font-size-x-small), 4cqw, var(--cx-font-size-large));font-weight:var(--cx-font-weight-semibold);text-align:center;height:100%;text-shadow:.05em .05em .1em var(--cx-color-neutral-1000);justify-content:center;align-items:center;width:100%;line-height:1;display:flex}.audio__play-button{--cx-input-border-width:2px;--cx-input-border-color:var(--text-color,var(--cx-color-neutral))}.audio__play-button::part(base){width:50px;height:50px;color:var(--text-color,var(--cx-color-neutral))!important}.audio__player{align-items:center;gap:var(--cx-spacing-small,8px);display:flex}.audio__waveform{flex:1;min-width:0;overflow:hidden}.audio__footer{font-size:var(--cx-font-size-x-small,11px);color:var(--text-color,var(--cx-color-neutral));flex-direction:column;gap:0;padding-left:2px;display:flex}.audio__time{color:var(--text-color,var(--cx-color-neutral));font-variant-numeric:tabular-nums}.audio__filename{opacity:.75;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}`;
15
- var P = Object.defineProperty, z = Object.getOwnPropertyDescriptor, n = (e, t, r, o) => {
16
- for (var i = o > 1 ? void 0 : o ? z(t, r) : t, s = e.length - 1, l; s >= 0; s--)
17
- (l = e[s]) && (i = (o ? l(t, r, i) : l(i)) || i);
18
- return o && i && P(t, r, i), i;
14
+ import { C as k } from "../chunks/icon-button.CQiBjznj.js";
15
+ import { C as T } from "../chunks/typography.DJC_UXgs.js";
16
+ const A = $`audio{display:none}:host{background-color:var(--background-color,var(--cx-color-neutral-0));border-radius:var(--border-radius,0px);border:var(--border,0px);box-sizing:border-box;color:var(--text-color,var(--cx-color-neutral));height:var(--height,auto);width:var(--width,100%);border-style:solid;display:block;position:relative}.audio{border-radius:inherit;gap:var(--cx-spacing-x-small,4px);height:100%;padding:var(--cx-spacing-small,8px);flex-direction:column;justify-content:center;display:flex;overflow:hidden}.audio--empty{height:var(--height,200px);min-height:var(--min-height,100%);padding:0}.audio--empty:before{background-color:var(--cx-color-neutral-1000);color:var(--cx-color-neutral-0);content:attr(data-empty-label);font-family:var(--cx-font-sans);font-size:clamp(var(--cx-font-size-x-small), 4cqw, var(--cx-font-size-large));font-weight:var(--cx-font-weight-semibold);text-align:center;height:100%;text-shadow:.05em .05em .1em var(--cx-color-neutral-1000);justify-content:center;align-items:center;width:100%;line-height:1;display:flex}.audio__play-button{--cx-input-border-width:2px;--cx-input-border-color:var(--text-color,var(--cx-color-neutral))}.audio__play-button::part(base){width:50px;height:50px;color:var(--text-color,var(--cx-color-neutral))!important}.audio__player{align-items:center;gap:var(--cx-spacing-small,8px);height:148px;display:flex}.audio__waveform{flex:1;min-width:0;overflow:hidden}.audio__waveform-svg{cursor:pointer;flex:1;width:100%;min-width:0;height:100%;display:block;overflow:hidden}.audio__waveform-wave{fill:var(--waves-color,var(--cx-color-primary))}.audio__waveform-played{fill:var(--played-color,var(--cx-color-primary-700,var(--cx-color-primary)))}.audio__waveform-playhead{fill:var(--playhead-color,var(--cx-color-neutral-0));opacity:.9}.audio__footer{font-size:var(--cx-font-size-x-small,11px);color:var(--text-color,var(--cx-color-neutral));flex-direction:column;gap:0;padding-left:2px;display:flex}.audio__time{color:var(--text-color,var(--cx-color-neutral));font-variant-numeric:tabular-nums}.audio__filename{opacity:.75;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}`;
17
+ var B = Object.defineProperty, W = Object.getOwnPropertyDescriptor, i = (t, a, o, r) => {
18
+ for (var l = r > 1 ? void 0 : r ? W(a, o) : a, c = t.length - 1, p; c >= 0; c--)
19
+ (p = t[c]) && (l = (r ? p(a, o, l) : p(l)) || l);
20
+ return r && l && B(a, o, l), l;
19
21
  };
20
- function $(e) {
21
- const t = "light-dark(";
22
- if (!e.startsWith(t) || !e.endsWith(")"))
23
- return null;
24
- const r = e.slice(t.length, -1);
25
- let o = 0, i = -1;
26
- for (let h = 0; h < r.length; h++)
27
- if (r[h] === "(")
28
- o++;
29
- else if (r[h] === ")")
30
- o--;
31
- else if (r[h] === "," && o === 0) {
32
- i = h;
33
- break;
34
- }
35
- if (i === -1)
36
- return null;
37
- const s = r.slice(0, i).trim(), l = r.slice(i + 1).trim();
38
- return !CSS.supports("color", s) || !CSS.supports("color", l) ? null : [s, l];
39
- }
40
- let a = class extends y {
22
+ let e = class extends y {
41
23
  constructor() {
42
- super(), this.localize = new S(this), this.waveSurfer = null, this.srcLoadVersion = 0, this.src = "", this.name = "", this.autoplay = !1, this.loop = !1, this.waveColor = ["", ""], this.isPlaying = !1, this.isLoaded = !1, this.isError = !1, this.currentTimeSeconds = 0, this.durationSeconds = 0, this.onWaveSurferReady = this.onWaveSurferReady.bind(this), this.onWaveSurferPlay = this.onWaveSurferPlay.bind(this), this.onWaveSurferPause = this.onWaveSurferPause.bind(this), this.onWaveSurferTimeUpdate = this.onWaveSurferTimeUpdate.bind(this), this.onWaveSurferFinish = this.onWaveSurferFinish.bind(this), this.onWaveSurferError = this.onWaveSurferError.bind(this);
24
+ super(...arguments), this.localize = new S(this), this.srcLoadVersion = 0, this.extractWaveformPeaks = b, this.src = "", this.name = "", this.autoplay = !1, this.loop = !1, this.waveformSrc = "", this.isPlaying = !1, this.isLoaded = !1, this.isError = !1, this.currentTimeSeconds = 0, this.durationSeconds = 0, this.waveformPath = "", this.waveformViewBoxWidth = 1e3, this.playedFraction = 0, this.audioSrc = "";
43
25
  }
44
26
  runConnectedCallback() {
45
27
  this.hasUpdated && this.requestUpdate("src");
@@ -50,188 +32,155 @@ let a = class extends y {
50
32
  async handleSrcChange() {
51
33
  await this.applySrc(this.src);
52
34
  }
53
- async applySrc(e) {
54
- const t = ++this.srcLoadVersion;
55
- if (this.isLoaded = !1, this.isPlaying = !1, !e) {
35
+ async applySrc(t) {
36
+ const a = ++this.srcLoadVersion;
37
+ if (this.isLoaded = !1, this.isPlaying = !1, !this.waveformSrc) {
56
38
  this.cleanUp();
57
39
  return;
58
40
  }
59
- await this.waveformContainerAsync, !(t !== this.srcLoadVersion || !this.isConnected) && await this.setupWaveSurfer(e, t);
41
+ await this.setupPngWaveform(t, a);
60
42
  }
61
- async handleWaveColorThemeChange() {
62
- this.src && this.waveSurfer && (await this.updateComplete, this.waveSurfer.setOptions(this.setupColors()));
43
+ updated(t) {
44
+ super.updated(t), (t.has("width") || t.has("height") || t.has("resizeSize")) && this.handleSizeChange();
63
45
  }
64
- updated(e) {
65
- super.updated(e), (e.has("width") || e.has("height") || e.has("resizeSize")) && this.handleSizeChange();
46
+ cleanUp() {
47
+ this.audioEl?.pause(), this.audioSrc = "", this.waveformPath = "", this.waveformViewBoxWidth = 1e3, this.playedFraction = 0, this.isLoaded = !1, this.isPlaying = !1, this.currentTimeSeconds = 0, this.durationSeconds = 0;
66
48
  }
67
- onWaveSurferReady() {
68
- this.isLoaded = !0, this.durationSeconds = this.waveSurfer.getDuration();
49
+ async setupPngWaveform(t, a) {
50
+ this.cleanUp();
51
+ const o = await this.extractWaveformPeaks(this.waveformSrc);
52
+ if (a !== this.srcLoadVersion || !this.isConnected)
53
+ return;
54
+ if (!o) {
55
+ this.isError = !0, this.emit("cx-error");
56
+ return;
57
+ }
58
+ const r = o.peaks.length;
59
+ this.waveformViewBoxWidth = r, this.waveformPath = P(o.peaks, r, 200), t && (this.audioSrc = t), this.isLoaded = !0, this.autoplay && t && (await this.updateComplete, this.audioEl?.play());
69
60
  }
70
- onWaveSurferPlay() {
61
+ handleAudioPlay() {
71
62
  this.isPlaying = !0, this.emit("cx-play");
72
63
  }
73
- onWaveSurferPause() {
64
+ handleAudioPause() {
74
65
  this.isPlaying = !1, this.emit("cx-pause");
75
66
  }
76
- onWaveSurferTimeUpdate(e) {
77
- this.currentTimeSeconds = e, this.emit("cx-time-update", {
78
- detail: {
79
- time: e
80
- }
81
- });
67
+ handleAudioTimeUpdate() {
68
+ if (!this.audioEl)
69
+ return;
70
+ const t = this.audioEl.duration ? this.audioEl.currentTime / this.audioEl.duration : 0;
71
+ this.playedFraction = t, this.style.setProperty("--played-fraction", String(t)), this.currentTimeSeconds = this.audioEl.currentTime, this.emit("cx-time-update", { detail: { time: this.audioEl.currentTime } });
72
+ }
73
+ handleAudioDurationChange() {
74
+ this.durationSeconds = this.audioEl?.duration || 0;
82
75
  }
83
- onWaveSurferFinish() {
76
+ handleAudioEnded() {
84
77
  this.isPlaying = !1, this.emit("cx-ended");
85
78
  }
86
- onWaveSurferError() {
87
- this.isError = !0, this.emit("cx-error");
88
- }
89
- resolveColorValue(e) {
90
- if (!e.startsWith("var("))
91
- return e;
92
- const t = e.match(/var\(\s*(--[\w-]+)/)?.[1];
93
- return t && getComputedStyle(this).getPropertyValue(t).trim() || e;
94
- }
95
- computeCursorColor(e) {
96
- const t = document.createElement("canvas");
97
- t.width = 1, t.height = 1;
98
- const r = t.getContext("2d");
99
- if (!r)
100
- return e;
101
- r.fillStyle = e, r.fillRect(0, 0, 1, 1);
102
- const [o, i, s] = r.getImageData(0, 0, 1, 1).data;
103
- return (0.299 * o + 0.587 * i + 0.114 * s) / 255 > 0.5 ? `rgb(${Math.round(o * 0.5)}, ${Math.round(i * 0.5)}, ${Math.round(s * 0.5)})` : `rgb(${Math.round(o + (255 - o) * 0.5)}, ${Math.round(i + (255 - i) * 0.5)}, ${Math.round(s + (255 - s) * 0.5)})`;
104
- }
105
- setupColors() {
106
- const t = getComputedStyle(this).getPropertyValue("--cx-color-primary").trim(), r = (this.theme === "dark" ? this.waveColor[1] : this.waveColor[0]) || t, o = this.resolveColorValue(r), i = this.resolveColorValue(
107
- this.theme === "dark" ? this.waveColor[1] : this.waveColor[0]
108
- ), s = this.computeCursorColor(o);
109
- return {
110
- cursorColor: s,
111
- progressColor: s,
112
- waveColor: i
113
- };
114
- }
115
- async setupWaveSurfer(e, t = this.srcLoadVersion) {
116
- this.cleanUp();
117
- const r = await this.waveformContainerAsync;
118
- if (t !== this.srcLoadVersion || !r || !e || !this.isConnected)
119
- return;
120
- const { default: o } = await import("../chunks/wavesurfer.esm.Cwi1pz64.js");
121
- t !== this.srcLoadVersion || !this.isConnected || (this.waveSurfer = o.create({
122
- barGap: 1,
123
- barRadius: 2,
124
- barWidth: 2,
125
- container: r,
126
- height: "auto",
127
- normalize: !0,
128
- url: e,
129
- ...this.setupColors()
130
- }), this.attachWaveSurferEvents(), this.autoplay && this.waveSurfer.play());
131
- }
132
- attachWaveSurferEvents() {
133
- this.waveSurfer && (this.waveSurfer.on("ready", this.onWaveSurferReady), this.waveSurfer.on("play", this.onWaveSurferPlay), this.waveSurfer.on("pause", this.onWaveSurferPause), this.waveSurfer.on("timeupdate", this.onWaveSurferTimeUpdate), this.waveSurfer.on("finish", this.onWaveSurferFinish), this.waveSurfer.on("error", this.onWaveSurferError));
134
- }
135
- cleanUp() {
136
- this.waveSurfer && (this.waveSurfer.destroy(), this.waveSurfer = null), this.isLoaded = !1, this.isPlaying = !1, this.currentTimeSeconds = 0, this.durationSeconds = 0;
79
+ handleAudioError() {
80
+ this.audioSrc && (this.isError = !0, this.emit("cx-error"));
137
81
  }
138
82
  handleSizeChange() {
139
- const e = this.isResizing ? `${this.resizeSize.width}px` : this.width, t = this.isResizing ? `${this.resizeSize.height}px` : this.height;
140
- this.width || this.isResizing ? this.style.setProperty("--width", e) : this.style.removeProperty("--width"), this.height || this.isResizing ? this.style.setProperty("--height", t) : this.style.removeProperty("--height");
83
+ const t = this.isResizing ? `${this.resizeSize.width}px` : this.width, a = this.isResizing ? `${this.resizeSize.height}px` : this.height;
84
+ this.width || this.isResizing ? this.style.setProperty("--width", t) : this.style.removeProperty("--width"), this.height || this.isResizing ? this.style.setProperty("--height", a) : this.style.removeProperty("--height");
141
85
  }
142
86
  /** Starts audio playback. */
143
87
  play() {
144
- this.waveSurfer?.play();
88
+ this.audioEl?.play();
145
89
  }
146
90
  /** Pauses audio playback. */
147
91
  pause() {
148
- this.waveSurfer?.pause();
92
+ this.audioEl?.pause();
149
93
  }
150
94
  /** Toggles between play and pause. */
151
95
  togglePlay() {
152
96
  this.isPlaying ? this.pause() : this.play();
153
97
  }
154
- formatTime(e) {
155
- const t = Math.floor(e / 60), r = Math.floor(e % 60);
156
- return `${t}:${r.toString().padStart(2, "0")}`;
98
+ formatTime(t) {
99
+ const o = this.durationSeconds >= 3600 ? u.HourMinuteSecond : u.MinuteSecond, r = g(t * 1e3, o);
100
+ return x(r, w.Digital);
101
+ }
102
+ handleWaveformClick(t) {
103
+ if (t.stopPropagation(), !this.audioEl || !this.durationSeconds)
104
+ return;
105
+ const o = t.currentTarget.getBoundingClientRect(), r = Math.max(0, Math.min(1, (t.clientX - o.left) / o.width));
106
+ this.audioEl.currentTime = r * this.durationSeconds;
157
107
  }
158
- handlePlayButtonKeyDown(e) {
159
- (e.key === "Enter" || e.key === " ") && (e.preventDefault(), this.togglePlay());
108
+ handlePlayButtonKeyDown(t) {
109
+ (t.key === "Enter" || t.key === " ") && (t.preventDefault(), this.togglePlay());
160
110
  }
161
111
  render() {
162
- const e = !this.src, t = this.formatTime(this.currentTimeSeconds), r = this.formatTime(this.durationSeconds);
163
- return p`<div part="base" class=${C({ audio: !0, "audio--empty": e })} data-empty-label=${this.localize.term("emptyAudio")} @click=${this.startResizing}>${d(
164
- !e,
165
- () => p`<div part="player" class="audio__player"><cx-icon-button part="play-button" class="audio__play-button" aria-pressed=${String(this.isPlaying)} circle label=${this.localize.term(this.isPlaying ? "pause" : "play")} name=${this.isPlaying ? "pause" : "play_arrow"} variant="filled" outline @click=${this.togglePlay} @keydown=${this.handlePlayButtonKeyDown}></cx-icon-button><div part="waveform" class="audio__waveform"></div></div><div part="footer" class="audio__footer"><cx-typography part="time" variant="small" class="audio__time">${t} / ${r}</cx-typography>${d(
112
+ const t = !this.src && !this.waveformSrc, a = this.formatTime(this.currentTimeSeconds), o = this.formatTime(this.durationSeconds);
113
+ return h`<audio src=${this.audioSrc} ?loop=${this.loop} @play=${this.handleAudioPlay} @pause=${this.handleAudioPause} @timeupdate=${this.handleAudioTimeUpdate} @durationchange=${this.handleAudioDurationChange} @ended=${this.handleAudioEnded} @error=${this.handleAudioError}></audio><div part="base" class=${C({ audio: !0, "audio--empty": t })} data-empty-label=${this.localize.term("emptyAudio")} @click=${this.startResizing}>${d(
114
+ !t,
115
+ () => h`<div part="player" class="audio__player"><cx-icon-button part="play-button" class="audio__play-button" aria-pressed=${String(this.isPlaying)} circle label=${this.localize.term(this.isPlaying ? "pause" : "play")} name=${this.isPlaying ? "pause" : "play_arrow"} variant="filled" outline @click=${this.togglePlay} @keydown=${this.handlePlayButtonKeyDown}></cx-icon-button>${d(
116
+ this.waveformPath,
117
+ () => z`<svg class="audio__waveform-svg" part="waveform-svg" viewBox="0 0 ${this.waveformViewBoxWidth} 200" preserveAspectRatio="none" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" @click=${this.handleWaveformClick}><path class="audio__waveform-wave" d=${this.waveformPath} /><svg x="0" y="0" width=${String(Math.round(this.playedFraction * this.waveformViewBoxWidth))} height="200" overflow="hidden"><path class="audio__waveform-played" d=${this.waveformPath} /></svg><rect class="audio__waveform-playhead" x=${String(Math.max(0, Math.round(this.playedFraction * this.waveformViewBoxWidth) - 1))} y="0" width="2" height="200"/></svg>`,
118
+ () => h`<div part="waveform" class="audio__waveform"></div>`
119
+ )}</div><div part="footer" class="audio__footer"><cx-typography part="time" variant="small" class="audio__time">${a} / ${o}</cx-typography>${d(
166
120
  this.name,
167
- () => p`<cx-typography part="filename" class="audio__filename">${this.name}</cx-typography>`
121
+ () => h`<cx-typography part="filename" class="audio__filename">${this.name}</cx-typography>`
168
122
  )}</div>`
169
123
  )}</div>${d(this.resizable && this.isResizeActive, () => this.renderResizer())}
170
124
  `;
171
125
  }
172
126
  };
173
- a.styles = [v, m, _];
174
- a.dependencies = {
175
- "cx-icon-button": b,
176
- "cx-typography": W
127
+ e.styles = [v, f, A];
128
+ e.dependencies = {
129
+ "cx-icon-button": k,
130
+ "cx-typography": T
177
131
  };
178
- n([
179
- x(".audio__waveform")
180
- ], a.prototype, "waveformContainerAsync", 2);
181
- n([
182
- c({ reflect: !0, type: String })
183
- ], a.prototype, "src", 2);
184
- n([
185
- c({ reflect: !0, type: String })
186
- ], a.prototype, "name", 2);
187
- n([
188
- c({ reflect: !0, type: Boolean })
189
- ], a.prototype, "autoplay", 2);
190
- n([
191
- c({ reflect: !0, type: Boolean })
192
- ], a.prototype, "loop", 2);
193
- n([
194
- c({
195
- attribute: "wave-color",
196
- converter: {
197
- fromAttribute(e) {
198
- if (!e)
199
- return ["", ""];
200
- const t = $(e);
201
- return t || (CSS.supports("color", e) ? [e, e] : ["", ""]);
202
- },
203
- toAttribute([e, t]) {
204
- return e === t ? e : `light-dark(${e}, ${t})`;
205
- }
206
- },
207
- reflect: !0
208
- })
209
- ], a.prototype, "waveColor", 2);
210
- n([
211
- u()
212
- ], a.prototype, "isPlaying", 2);
213
- n([
214
- u()
215
- ], a.prototype, "isLoaded", 2);
216
- n([
217
- u()
218
- ], a.prototype, "isError", 2);
219
- n([
220
- u()
221
- ], a.prototype, "currentTimeSeconds", 2);
222
- n([
223
- u()
224
- ], a.prototype, "durationSeconds", 2);
225
- n([
226
- f("src")
227
- ], a.prototype, "handleSrcChange", 1);
228
- n([
229
- f("theme", { waitUntilFirstUpdate: !0 }),
230
- f("waveColor", { waitUntilFirstUpdate: !0 })
231
- ], a.prototype, "handleWaveColorThemeChange", 1);
232
- a = n([
233
- g("cx-audio")
234
- ], a);
132
+ i([
133
+ E("audio")
134
+ ], e.prototype, "audioEl", 2);
135
+ i([
136
+ n({ reflect: !0, type: String })
137
+ ], e.prototype, "src", 2);
138
+ i([
139
+ n({ reflect: !0, type: String })
140
+ ], e.prototype, "name", 2);
141
+ i([
142
+ n({ reflect: !0, type: Boolean })
143
+ ], e.prototype, "autoplay", 2);
144
+ i([
145
+ n({ reflect: !0, type: Boolean })
146
+ ], e.prototype, "loop", 2);
147
+ i([
148
+ n({ attribute: "waveform-src", reflect: !0, type: String })
149
+ ], e.prototype, "waveformSrc", 2);
150
+ i([
151
+ s()
152
+ ], e.prototype, "isPlaying", 2);
153
+ i([
154
+ s()
155
+ ], e.prototype, "isLoaded", 2);
156
+ i([
157
+ s()
158
+ ], e.prototype, "isError", 2);
159
+ i([
160
+ s()
161
+ ], e.prototype, "currentTimeSeconds", 2);
162
+ i([
163
+ s()
164
+ ], e.prototype, "durationSeconds", 2);
165
+ i([
166
+ s()
167
+ ], e.prototype, "waveformPath", 2);
168
+ i([
169
+ s()
170
+ ], e.prototype, "waveformViewBoxWidth", 2);
171
+ i([
172
+ s()
173
+ ], e.prototype, "playedFraction", 2);
174
+ i([
175
+ s()
176
+ ], e.prototype, "audioSrc", 2);
177
+ i([
178
+ m("waveformSrc", { waitUntilFirstUpdate: !0 }),
179
+ m("src")
180
+ ], e.prototype, "handleSrcChange", 1);
181
+ e = i([
182
+ _("cx-audio")
183
+ ], e);
235
184
  export {
236
- a as default
185
+ e as default
237
186
  };
@@ -1,9 +1,9 @@
1
- import { C as n } from "../chunks/input.DdeXWD_F.js";
1
+ import { C as n } from "../chunks/input.CH4lKxPM.js";
2
2
  import p from "./space.js";
3
3
  import { n as u, C as m } from "../chunks/lib-cortex-element.CVMmyPMC.js";
4
4
  import { c as h } from "../chunks/component.styles.CRO4Odto.js";
5
5
  import { c as d } from "../chunks/custom-element.L4WJXn1j.js";
6
- import { L as x } from "../chunks/i18n.C21qyGi6.js";
6
+ import { L as x } from "../chunks/i18n.CH-wak_P.js";
7
7
  import { i as v, x as b } from "../chunks/lit-element.jLBm65_O.js";
8
8
  import f from "./bicolor-picker.js";
9
9
  const g = v`.border-width{width:72px}`;
@@ -1,7 +1,7 @@
1
1
  import { n as p, C as h } from "../chunks/lib-cortex-element.CVMmyPMC.js";
2
2
  import { c as d } from "../chunks/component.styles.CRO4Odto.js";
3
3
  import { c as m } from "../chunks/custom-element.L4WJXn1j.js";
4
- import { L as u } from "../chunks/i18n.C21qyGi6.js";
4
+ import { L as u } from "../chunks/i18n.CH-wak_P.js";
5
5
  import { i as f, x as b } from "../chunks/lit-element.jLBm65_O.js";
6
6
  import { e as c } from "../chunks/query.BBf1UFkC.js";
7
7
  import { C as g } from "../chunks/icon.DnBh6-56.js";
@@ -1,9 +1,9 @@
1
1
  import "../chunks/lib-cortex-element.CVMmyPMC.js";
2
2
  import "../chunks/component.styles.CRO4Odto.js";
3
- import { C as h } from "../chunks/button.DIvU_uFU.js";
3
+ import { C as h } from "../chunks/button.DwJEeW2t.js";
4
4
  import "../chunks/custom-element.L4WJXn1j.js";
5
5
  import "../chunks/form.B-5nQJva.js";
6
- import "../chunks/i18n.C21qyGi6.js";
6
+ import "../chunks/i18n.CH-wak_P.js";
7
7
  import "../chunks/slot.j5oheLJC.js";
8
8
  import "../chunks/watch.CThbualB.js";
9
9
  import "../chunks/state.CSDxrqLd.js";
@@ -5,7 +5,7 @@ import { d as C } from "../chunks/debounce.CIEhztrj.js";
5
5
  import { d as z } from "../chunks/default-value.COZopaet.js";
6
6
  import { d as y } from "../chunks/drag.DXEXVXPv.js";
7
7
  import { F as D } from "../chunks/form.B-5nQJva.js";
8
- import { L as I } from "../chunks/i18n.C21qyGi6.js";
8
+ import { L as I } from "../chunks/i18n.CH-wak_P.js";
9
9
  import { c as u } from "../chunks/math.DqTA6ya4.js";
10
10
  import { w as k } from "../chunks/watch.CThbualB.js";
11
11
  import { i as E, x as h } from "../chunks/lit-element.jLBm65_O.js";
@@ -16,11 +16,11 @@ import { e as b } from "../chunks/class-map.BiVq-cVR.js";
16
16
  import { o as x } from "../chunks/if-defined.BRoBj_Rp.js";
17
17
  import { o as f } from "../chunks/style-map.llVFPd__.js";
18
18
  import { n as d } from "../chunks/when.Dr1es41R.js";
19
- import { C as M } from "../chunks/button.DIvU_uFU.js";
19
+ import { C as M } from "../chunks/button.DwJEeW2t.js";
20
20
  import O from "./button-group.js";
21
21
  import A from "./dropdown.js";
22
22
  import { C as B } from "../chunks/icon.DnBh6-56.js";
23
- import { C as P } from "../chunks/input.DdeXWD_F.js";
23
+ import { C as P } from "../chunks/input.CH4lKxPM.js";
24
24
  import L from "./spinner.js";
25
25
  import N from "./visually-hidden.js";
26
26
  import { T as w } from "../chunks/index.C1chwzNp.js";
@@ -1,14 +1,14 @@
1
1
  import "./space.js";
2
- import "../chunks/table.CP3oGDY1.js";
2
+ import "../chunks/table.BvbReIZh.js";
3
3
  import "../chunks/typography.DJC_UXgs.js";
4
4
  import "../chunks/lib-cortex-element.CVMmyPMC.js";
5
- import "../chunks/color-swatch.BoUZGGs4.js";
5
+ import "../chunks/color-swatch.DVzEaNeL.js";
6
6
  import "../chunks/component.styles.CRO4Odto.js";
7
- import { C as w } from "../chunks/color-swatch-group.DV5uB8OC.js";
7
+ import { C as w } from "../chunks/color-swatch-group.DjjSIHSV.js";
8
8
  import "../chunks/content-builder.OsUmm8Wu.js";
9
9
  import "../chunks/custom-element.L4WJXn1j.js";
10
10
  import "../chunks/debounce.CIEhztrj.js";
11
- import "../chunks/i18n.C21qyGi6.js";
11
+ import "../chunks/i18n.CH-wak_P.js";
12
12
  import "../chunks/watch.CThbualB.js";
13
13
  import "../chunks/responsive.C8NCkfCG.js";
14
14
  import "../chunks/lit-element.jLBm65_O.js";
@@ -5,11 +5,11 @@ import "./space.js";
5
5
  import "../chunks/typography.DJC_UXgs.js";
6
6
  import "../chunks/lib-cortex-element.CVMmyPMC.js";
7
7
  import "../chunks/component.styles.CRO4Odto.js";
8
- import { C as q } from "../chunks/color-swatch.BoUZGGs4.js";
8
+ import { C as q } from "../chunks/color-swatch.DVzEaNeL.js";
9
9
  import "../chunks/color.LzSGBy7o.js";
10
10
  import "../chunks/custom-element.L4WJXn1j.js";
11
11
  import "../chunks/debounce.CIEhztrj.js";
12
- import "../chunks/i18n.C21qyGi6.js";
12
+ import "../chunks/i18n.CH-wak_P.js";
13
13
  import "../chunks/watch.CThbualB.js";
14
14
  import "../chunks/lit-element.jLBm65_O.js";
15
15
  import "../chunks/state.CSDxrqLd.js";
@@ -1,12 +1,12 @@
1
- import "../chunks/button.DIvU_uFU.js";
2
- import "../chunks/dialog.DyT-Nai2.js";
1
+ import "../chunks/button.DwJEeW2t.js";
2
+ import "../chunks/dialog.BYCWepBc.js";
3
3
  import "./dropdown.js";
4
4
  import "../chunks/typography.DJC_UXgs.js";
5
5
  import "../chunks/lib-cortex-element.CVMmyPMC.js";
6
6
  import "../chunks/component.styles.CRO4Odto.js";
7
- import { C as x } from "../chunks/confirm-popover.DS9HIy3c.js";
7
+ import { C as x } from "../chunks/confirm-popover.BifwpSuf.js";
8
8
  import "../chunks/custom-element.L4WJXn1j.js";
9
- import "../chunks/i18n.C21qyGi6.js";
9
+ import "../chunks/i18n.CH-wak_P.js";
10
10
  import "../chunks/lit-element.jLBm65_O.js";
11
11
  import "../chunks/query.BBf1UFkC.js";
12
12
  import "../chunks/class-map.BiVq-cVR.js";
@@ -1,7 +1,7 @@
1
1
  import { n as r, C as y } from "../chunks/lib-cortex-element.CVMmyPMC.js";
2
2
  import { c as m } from "../chunks/component.styles.CRO4Odto.js";
3
3
  import { c as f } from "../chunks/custom-element.L4WJXn1j.js";
4
- import { L as g } from "../chunks/i18n.C21qyGi6.js";
4
+ import { L as g } from "../chunks/i18n.CH-wak_P.js";
5
5
  import { H as x } from "../chunks/slot.j5oheLJC.js";
6
6
  import { w as v } from "../chunks/watch.CThbualB.js";
7
7
  import { i as _, x as b } from "../chunks/lit-element.jLBm65_O.js";
@@ -1,12 +1,12 @@
1
- import { C as u } from "../chunks/input.DdeXWD_F.js";
2
- import { C as h } from "../chunks/option.CcGRV3jj.js";
1
+ import { C as u } from "../chunks/input.CH4lKxPM.js";
2
+ import { C as h } from "../chunks/option.Bvh35v8S.js";
3
3
  import m from "./select.js";
4
4
  import x from "./space.js";
5
5
  import { n as l, C as g } from "../chunks/lib-cortex-element.CVMmyPMC.js";
6
6
  import { c as C } from "../chunks/component.styles.CRO4Odto.js";
7
7
  import { C as o } from "../chunks/index.Cpamj0jB.js";
8
8
  import { c as d } from "../chunks/custom-element.L4WJXn1j.js";
9
- import { L as _ } from "../chunks/i18n.C21qyGi6.js";
9
+ import { L as _ } from "../chunks/i18n.CH-wak_P.js";
10
10
  import { i as v, x as y } from "../chunks/lit-element.jLBm65_O.js";
11
11
  const $ = v`:host{width:100%;display:block}.corner-position-input-group__inputs{width:100%}.corner-position-input-group__input{flex:1}`;
12
12
  var X = Object.defineProperty, Y = Object.getOwnPropertyDescriptor, r = (e, t, f, n) => {
@@ -7,7 +7,7 @@ import { i as f, x as n } from "../chunks/lit-element.jLBm65_O.js";
7
7
  import { r as h } from "../chunks/state.CSDxrqLd.js";
8
8
  import { e as w } from "../chunks/class-map.BiVq-cVR.js";
9
9
  import { c as k } from "../chunks/repeat.DbF2p5ae.js";
10
- import { C as D } from "../chunks/icon-button.DxkJ-cp-.js";
10
+ import { C as D } from "../chunks/icon-button.CQiBjznj.js";
11
11
  const M = f`:host{display:inline-block}.calendar{background:var(--cx-color-neutral-0);border:1px solid var(--cx-color-neutral-200);border-radius:var(--cx-border-radius-medium);user-select:none;width:fit-content;overflow:hidden}.calendar__header{padding:var(--cx-spacing-3x-small);background:var(--header-background,var(--cx-color-neutral-100));border-bottom:1px solid var(--cx-color-neutral-200);justify-content:space-between;align-items:center;display:flex}.calendar__title{font-size:var(--cx-font-size-small);font-weight:var(--cx-font-weight-semibold);color:var(--cx-color-neutral-900)}.calendar__weekdays{grid-template-columns:repeat(7, var(--cell-size,30px));border-bottom:1px solid var(--cx-color-neutral-200);display:grid}.calendar__weekday{text-align:center;font-size:var(--cx-font-size-2x-small);font-weight:var(--cx-font-weight-regular);color:var(--cx-color-neutral-500);padding-block:var(--cx-spacing-2x-small)}.calendar__grid{grid-template-columns:repeat(7, var(--cell-size,30px));border-top:1px solid var(--cx-color-neutral-200);border-left:1px solid var(--cx-color-neutral-200);display:grid}.calendar__cell{height:var(--cell-size,30px);border:none;border-right:1px solid var(--cx-color-neutral-200);border-bottom:1px solid var(--cx-color-neutral-200);border-radius:var(--cell-border-radius,0);color:var(--cx-color-neutral-900);font-size:var(--cx-font-size-x-small);cursor:pointer;transition:background var(--cx-transition-x-fast) ease;background:0 0;justify-content:center;align-items:center;padding:0;display:flex}.calendar__cell:hover:not(.calendar__cell--selected){background:var(--cell-hover-background,var(--cx-color-primary-50))}.calendar__cell--disabled{background:var(--cx-color-neutral-50);color:var(--cx-color-neutral-300);cursor:not-allowed}.calendar__cell--disabled:hover{background:var(--cx-color-neutral-50)}.calendar__cell--outside{background:var(--cx-color-neutral-100);color:var(--cx-color-neutral-400)}.calendar__cell--today:not(.calendar__cell--selected){background:var(--cell-today-background,var(--cx-color-primary-200))}.calendar__cell--selected{background:var(--cell-selected-background,var(--cx-color-neutral-300));color:var(--cell-selected-color,var(--cx-color-neutral-0));font-weight:var(--cx-font-weight-bold)}.calendar__cell--selected:hover{background:var(--cell-selected-background,var(--cx-color-neutral-300));opacity:.85}`;
12
12
  var $ = Object.defineProperty, C = Object.getOwnPropertyDescriptor, c = (e, a, o, r) => {
13
13
  for (var l = r > 1 ? void 0 : r ? C(a, o) : a, i = e.length - 1, s; i >= 0; i--)
@@ -2,7 +2,7 @@ import { n as l, C as b } from "../chunks/lib-cortex-element.CVMmyPMC.js";
2
2
  import { c as v } from "../chunks/component.styles.CRO4Odto.js";
3
3
  import { s as h, a as p, b as m, w as u } from "../chunks/event.BeKOsirN.js";
4
4
  import { c as x } from "../chunks/custom-element.L4WJXn1j.js";
5
- import { L as _ } from "../chunks/i18n.C21qyGi6.js";
5
+ import { L as _ } from "../chunks/i18n.CH-wak_P.js";
6
6
  import { w as g } from "../chunks/watch.CThbualB.js";
7
7
  import { i as w, x as k } from "../chunks/lit-element.jLBm65_O.js";
8
8
  import { e as n } from "../chunks/query.BBf1UFkC.js";
@@ -1,10 +1,10 @@
1
1
  import "../chunks/lib-cortex-element.CVMmyPMC.js";
2
2
  import "../chunks/component.styles.CRO4Odto.js";
3
3
  import "../chunks/overlayscrollbars.BMav4RQ4.js";
4
- import { C as v } from "../chunks/dialog.DyT-Nai2.js";
4
+ import { C as v } from "../chunks/dialog.BYCWepBc.js";
5
5
  import "../chunks/event.BeKOsirN.js";
6
6
  import "../chunks/custom-element.L4WJXn1j.js";
7
- import "../chunks/i18n.C21qyGi6.js";
7
+ import "../chunks/i18n.CH-wak_P.js";
8
8
  import "../chunks/modal.U1QltQKe.js";
9
9
  import "../chunks/scroll.xtO5yojm.js";
10
10
  import "../chunks/slot.j5oheLJC.js";
@@ -18,7 +18,7 @@ import "../chunks/style-map.llVFPd__.js";
18
18
  import "../chunks/when.Dr1es41R.js";
19
19
  import "../chunks/animation-registry.HmpwNuGH.js";
20
20
  import "./divider.js";
21
- import "../chunks/icon-button.DxkJ-cp-.js";
21
+ import "../chunks/icon-button.CQiBjznj.js";
22
22
  import "./popup.js";
23
23
  export {
24
24
  v as default
@@ -5,17 +5,17 @@ import { w as h } from "../chunks/watch.CThbualB.js";
5
5
  import { i as b, x as g } from "../chunks/lit-element.jLBm65_O.js";
6
6
  import { n as f } from "../chunks/when.Dr1es41R.js";
7
7
  const m = b`:host{--color:var(--cx-panel-border-color);--label-color:var(--cx-color-neutral-600);--label-font-size:var(--cx-font-size-small);--width:var(--cx-panel-border-width);--spacing:var(--cx-spacing-medium);--border-style:solid;--padding:var(--spacing)}:host(:not([vertical])){width:100%;display:block}:host(:not([vertical]):not([use-padding])){padding:var(--spacing) 0}.divider__label{text-align:center;margin-bottom:var(--cx-spacing-2x-small);color:var(--label-color);font-size:var(--label-font-size);display:block}:host(:not([vertical])):after{content:" ";border-top:var(--border-style) var(--width) var(--color);display:block}:host([vertical]){height:100%;display:inline-block}:host([vertical]:not([use-padding])){padding:0 var(--spacing)}:host([vertical]):after{content:" ";border-left:var(--border-style) var(--width) var(--color);height:100%;display:inline-block}:host([use-padding]){padding:var(--padding)}`;
8
- var u = Object.defineProperty, y = Object.getOwnPropertyDescriptor, r = (a, l, i, o) => {
9
- for (var e = o > 1 ? void 0 : o ? y(l, i) : l, s = a.length - 1, n; s >= 0; s--)
10
- (n = a[s]) && (e = (o ? n(l, i, e) : n(e)) || e);
11
- return o && e && u(l, i, e), e;
8
+ var u = Object.defineProperty, y = Object.getOwnPropertyDescriptor, r = (a, o, i, l) => {
9
+ for (var t = l > 1 ? void 0 : l ? y(o, i) : o, s = a.length - 1, n; s >= 0; s--)
10
+ (n = a[s]) && (t = (l ? n(o, i, t) : n(t)) || t);
11
+ return l && t && u(o, i, t), t;
12
12
  };
13
- let t = class extends d {
13
+ let e = class extends d {
14
14
  constructor() {
15
15
  super(...arguments), this.vertical = !1, this.label = "", this.usePadding = !1;
16
16
  }
17
- connectedCallback() {
18
- super.connectedCallback(), this.setAttribute("role", "separator");
17
+ runFirstUpdated() {
18
+ this.setAttribute("role", "separator");
19
19
  }
20
20
  handleVerticalChange() {
21
21
  this.setAttribute(
@@ -31,22 +31,22 @@ let t = class extends d {
31
31
  );
32
32
  }
33
33
  };
34
- t.styles = [p, m];
34
+ e.styles = [p, m];
35
35
  r([
36
36
  c({ reflect: !0, type: Boolean })
37
- ], t.prototype, "vertical", 2);
37
+ ], e.prototype, "vertical", 2);
38
38
  r([
39
39
  c({ reflect: !0, type: String })
40
- ], t.prototype, "label", 2);
40
+ ], e.prototype, "label", 2);
41
41
  r([
42
42
  c({ attribute: "use-padding", reflect: !0, type: Boolean })
43
- ], t.prototype, "usePadding", 2);
43
+ ], e.prototype, "usePadding", 2);
44
44
  r([
45
45
  h("vertical")
46
- ], t.prototype, "handleVerticalChange", 1);
47
- t = r([
46
+ ], e.prototype, "handleVerticalChange", 1);
47
+ e = r([
48
48
  v("cx-divider")
49
- ], t);
49
+ ], e);
50
50
  export {
51
- t as default
51
+ e as default
52
52
  };