@melodicdev/components 1.6.6 → 1.6.7

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.
@@ -197,7 +197,7 @@ async function Ks(e = {}) {
197
197
  function Ke(e, t) {
198
198
  e.renderInto(t);
199
199
  }
200
- const Pr = Symbol("melodic.signal"), na = (e) => typeof e == "function" && Pr in e;
200
+ const Mr = Symbol("melodic.signal"), na = (e) => typeof e == "function" && Mr in e;
201
201
  var Ue = "melodic-styles", da = `style[${Ue}], link[rel="stylesheet"][${Ue}]`, Ne = [], xe = null;
202
202
  const ca = (e) => {
203
203
  if (pa()) {
@@ -281,7 +281,7 @@ function O(e) {
281
281
  a.delete(s);
282
282
  }, o.destroy = () => {
283
283
  r || (r = !0, a.clear());
284
- }, Object.defineProperty(o, Pr, {
284
+ }, Object.defineProperty(o, Mr, {
285
285
  value: !0,
286
286
  enumerable: !1,
287
287
  configurable: !1
@@ -2619,7 +2619,7 @@ function dt(e, t, r, a) {
2619
2619
  isNew: !1
2620
2620
  });
2621
2621
  } else {
2622
- const w = Ma(b, u, x, r, a);
2622
+ const w = Pa(b, u, x, r, a);
2623
2623
  s.push({
2624
2624
  item: w,
2625
2625
  oldIndex: -1,
@@ -2636,11 +2636,11 @@ function dt(e, t, r, a) {
2636
2636
  let p = a.endMarker;
2637
2637
  for (let u = s.length - 1; u >= 0; u--) {
2638
2638
  const b = s[u];
2639
- b.isNew ? Pa(b.item, h, p) : m.has(u) || Oa(b.item, p), p = b.item.start;
2639
+ b.isNew ? Ma(b.item, h, p) : m.has(u) || Oa(b.item, p), p = b.item.start;
2640
2640
  }
2641
2641
  a.keyToIndex = o, a.items = s.map((u) => u.item);
2642
2642
  }
2643
- function Ma(e, t, r, a, l) {
2643
+ function Pa(e, t, r, a, l) {
2644
2644
  const o = a(e, t);
2645
2645
  let s, n;
2646
2646
  if (l.useCompiledPath && l.compiledTemplate) {
@@ -2657,7 +2657,7 @@ function Ma(e, t, r, a, l) {
2657
2657
  end: document.createComment("repeat-item-end")
2658
2658
  };
2659
2659
  }
2660
- function Pa(e, t, r) {
2660
+ function Ma(e, t, r) {
2661
2661
  const a = document.createDocumentFragment();
2662
2662
  a.appendChild(e.start);
2663
2663
  for (const l of e.nodes) a.appendChild(l);
@@ -3791,7 +3791,7 @@ const ml = {
3791
3791
  /* Default to light color scheme */
3792
3792
  color-scheme: light;
3793
3793
  }`;
3794
- var ve = "system", Me = /* @__PURE__ */ new Set(), ge = null;
3794
+ var ve = "system", Pe = /* @__PURE__ */ new Set(), ge = null;
3795
3795
  function Tn() {
3796
3796
  return ve;
3797
3797
  }
@@ -3811,10 +3811,10 @@ function hl(e) {
3811
3811
  document.documentElement.setAttribute("data-theme", e), $e(e, e);
3812
3812
  }
3813
3813
  function An(e) {
3814
- return Me.add(e), () => Me.delete(e);
3814
+ return Pe.add(e), () => Pe.delete(e);
3815
3815
  }
3816
3816
  function $e(e, t) {
3817
- Me.forEach((r) => r(e, t));
3817
+ Pe.forEach((r) => r(e, t));
3818
3818
  }
3819
3819
  function Dn() {
3820
3820
  hl(pl() === "light" ? "dark" : "light");
@@ -3831,7 +3831,7 @@ function In(e, t) {
3831
3831
  const l = document.getElementById(a.id);
3832
3832
  return l && l.remove(), document.head.appendChild(a), a;
3833
3833
  }
3834
- function Mn(e, t) {
3834
+ function Pn(e, t) {
3835
3835
  const r = {};
3836
3836
  return t.primary && (r["--ml-color-primary"] = t.primary), t.secondary && (r["--ml-color-secondary"] = t.secondary), t.success && (r["--ml-color-success"] = t.success), t.warning && (r["--ml-color-warning"] = t.warning), t.danger && (r["--ml-color-danger"] = t.danger), Xr(e, r);
3837
3837
  }
@@ -4156,7 +4156,7 @@ function _l(e) {
4156
4156
  const t = He(e);
4157
4157
  return t[t.length - 1] ?? null;
4158
4158
  }
4159
- function Pn(e) {
4159
+ function Mn(e) {
4160
4160
  const t = Qr(e);
4161
4161
  return t ? (t.focus(), !0) : !1;
4162
4162
  }
@@ -4227,9 +4227,9 @@ function Vn(e, t = "focus-visible") {
4227
4227
  e.removeEventListener("focus", r), e.removeEventListener("blur", a), e.classList.remove(t);
4228
4228
  };
4229
4229
  }
4230
- var M = null;
4230
+ var P = null;
4231
4231
  function yl() {
4232
- return M && document.body.contains(M) || (M = document.createElement("div"), M.id = "ml-live-region", M.setAttribute("aria-live", "polite"), M.setAttribute("aria-atomic", "true"), M.setAttribute("role", "status"), Object.assign(M.style, {
4232
+ return P && document.body.contains(P) || (P = document.createElement("div"), P.id = "ml-live-region", P.setAttribute("aria-live", "polite"), P.setAttribute("aria-atomic", "true"), P.setAttribute("role", "status"), Object.assign(P.style, {
4233
4233
  position: "absolute",
4234
4234
  width: "1px",
4235
4235
  height: "1px",
@@ -4239,7 +4239,7 @@ function yl() {
4239
4239
  clip: "rect(0, 0, 0, 0)",
4240
4240
  whiteSpace: "nowrap",
4241
4241
  border: "0"
4242
- }), document.body.appendChild(M)), M;
4242
+ }), document.body.appendChild(P)), P;
4243
4243
  }
4244
4244
  function qn(e, t = "polite") {
4245
4245
  const r = yl();
@@ -5173,7 +5173,7 @@ function Il(e) {
5173
5173
  </div>
5174
5174
  `;
5175
5175
  }
5176
- const Ml = () => _`
5176
+ const Pl = () => _`
5177
5177
  :host {
5178
5178
  display: block;
5179
5179
  width: 100%;
@@ -5400,7 +5400,7 @@ var wt = class {
5400
5400
  wt = v([f({
5401
5401
  selector: "ml-input",
5402
5402
  template: Il,
5403
- styles: Ml,
5403
+ styles: Pl,
5404
5404
  attributes: [
5405
5405
  "type",
5406
5406
  "value",
@@ -5415,7 +5415,7 @@ wt = v([f({
5415
5415
  "autocomplete"
5416
5416
  ]
5417
5417
  })], wt);
5418
- function Pl(e) {
5418
+ function Ml(e) {
5419
5419
  return i`
5420
5420
  <div
5421
5421
  class=${g({
@@ -5667,7 +5667,7 @@ var yt = class {
5667
5667
  };
5668
5668
  yt = v([f({
5669
5669
  selector: "ml-textarea",
5670
- template: Pl,
5670
+ template: Ml,
5671
5671
  styles: Ol,
5672
5672
  attributes: [
5673
5673
  "value",
@@ -9409,7 +9409,7 @@ I((e) => e.tagName === "ML-DATE-PICKER", {
9409
9409
  e.disabled = t;
9410
9410
  }
9411
9411
  });
9412
- var Mt = class {
9412
+ var Pt = class {
9413
9413
  constructor() {
9414
9414
  this.value = "", this.placeholder = "Select date", this.label = "", this.hint = "", this.error = "", this.size = "md", this.disabled = !1, this.required = !1, this.min = "", this.max = "", this.minYear = "", this.maxYear = "", this.isOpen = !1, this._cleanupAutoUpdate = null, this.toggleCalendar = () => {
9415
9415
  if (this.disabled) return;
@@ -9481,7 +9481,7 @@ var Mt = class {
9481
9481
  return this.elementRef.shadowRoot?.querySelector(".ml-date-picker__popover");
9482
9482
  }
9483
9483
  };
9484
- Mt = v([f({
9484
+ Pt = v([f({
9485
9485
  selector: "ml-date-picker",
9486
9486
  template: go,
9487
9487
  styles: vo,
@@ -9499,7 +9499,7 @@ Mt = v([f({
9499
9499
  "min-year",
9500
9500
  "max-year"
9501
9501
  ]
9502
- })], Mt);
9502
+ })], Pt);
9503
9503
  function bo(e) {
9504
9504
  return i`
9505
9505
  <div
@@ -9667,7 +9667,7 @@ const fo = () => _`
9667
9667
  opacity: var(--ml-alert-dismiss-hover-opacity);
9668
9668
  }
9669
9669
  `;
9670
- var Pt = class {
9670
+ var Mt = class {
9671
9671
  constructor() {
9672
9672
  this.variant = "info", this.title = "", this.dismissible = !1, this.handleDismiss = () => {
9673
9673
  this.elementRef.dispatchEvent(new CustomEvent("ml:dismiss", {
@@ -9682,7 +9682,7 @@ var Pt = class {
9682
9682
  }[this.variant]}"></ml-icon>`;
9683
9683
  }
9684
9684
  };
9685
- Pt = v([f({
9685
+ Mt = v([f({
9686
9686
  selector: "ml-alert",
9687
9687
  template: bo,
9688
9688
  styles: fo,
@@ -9691,7 +9691,7 @@ Pt = v([f({
9691
9691
  "title",
9692
9692
  "dismissible"
9693
9693
  ]
9694
- })], Pt);
9694
+ })], Mt);
9695
9695
  var Ot = class {
9696
9696
  constructor() {
9697
9697
  this._containerEl = null, this._position = "top-right";
@@ -10886,14 +10886,14 @@ Bt = v([f({
10886
10886
  "wrap"
10887
10887
  ]
10888
10888
  })], Bt);
10889
- function Mo(e) {
10889
+ function Po(e) {
10890
10890
  return i`
10891
10891
  <div class="ml-container" style=${J(e.getStyles())}>
10892
10892
  <slot></slot>
10893
10893
  </div>
10894
10894
  `;
10895
10895
  }
10896
- const Po = () => _`
10896
+ const Mo = () => _`
10897
10897
  :host {
10898
10898
  display: block;
10899
10899
  width: 100%;
@@ -10925,8 +10925,8 @@ var jt = class {
10925
10925
  };
10926
10926
  jt = v([f({
10927
10927
  selector: "ml-container",
10928
- template: Mo,
10929
- styles: Po,
10928
+ template: Po,
10929
+ styles: Mo,
10930
10930
  attributes: [
10931
10931
  "size",
10932
10932
  "padding",
@@ -13789,7 +13789,7 @@ var ii = [
13789
13789
  "October",
13790
13790
  "November",
13791
13791
  "December"
13792
- ], Pe = [
13792
+ ], Me = [
13793
13793
  "Jan",
13794
13794
  "Feb",
13795
13795
  "Mar",
@@ -13858,7 +13858,7 @@ function rr(e) {
13858
13858
  return `${ii[e.getMonth()]} ${e.getFullYear()}`;
13859
13859
  }
13860
13860
  function di(e, t) {
13861
- const r = Pe[e.getMonth()], a = Pe[t.getMonth()];
13861
+ const r = Me[e.getMonth()], a = Me[t.getMonth()];
13862
13862
  return e.getMonth() === t.getMonth() && e.getFullYear() === t.getFullYear() ? `${r} ${e.getDate()} – ${t.getDate()}, ${e.getFullYear()}` : e.getFullYear() === t.getFullYear() ? `${r} ${e.getDate()} – ${a} ${t.getDate()}, ${e.getFullYear()}` : `${r} ${e.getDate()}, ${e.getFullYear()} – ${a} ${t.getDate()}, ${t.getFullYear()}`;
13863
13863
  }
13864
13864
  function ar(e, t, r = 0) {
@@ -13919,12 +13919,12 @@ function fe(e, t) {
13919
13919
  return e.filter((r) => r.start.split("T")[0] === t);
13920
13920
  }
13921
13921
  function mi(e) {
13922
- return Pe[e.getMonth()];
13922
+ return Me[e.getMonth()];
13923
13923
  }
13924
13924
  function pi(e) {
13925
13925
  return ra[e.getDay()];
13926
13926
  }
13927
- function P(e) {
13927
+ function M(e) {
13928
13928
  const t = new Date(e);
13929
13929
  return t.getHours() * 60 + t.getMinutes();
13930
13930
  }
@@ -13934,13 +13934,13 @@ function or(e) {
13934
13934
  function oa(e) {
13935
13935
  if (e.length === 0) return [];
13936
13936
  const t = [...e].sort((n, c) => {
13937
- const m = P(n.start), h = P(c.start);
13937
+ const m = M(n.start), h = M(c.start);
13938
13938
  if (m !== h) return m - h;
13939
- const p = P(n.end) - m;
13940
- return P(c.end) - h - p;
13939
+ const p = M(n.end) - m;
13940
+ return M(c.end) - h - p;
13941
13941
  }), r = [], a = /* @__PURE__ */ new Map();
13942
13942
  for (const n of t) {
13943
- const c = P(n.start), m = P(n.end);
13943
+ const c = M(n.start), m = M(n.end);
13944
13944
  let h = !1;
13945
13945
  for (let p = 0; p < r.length; p++) if (r[p][r[p].length - 1].end <= c) {
13946
13946
  r[p].push({ end: m }), a.set(n.id, p), h = !0;
@@ -13953,9 +13953,9 @@ function oa(e) {
13953
13953
  if (o.has(n.id)) continue;
13954
13954
  const c = [n];
13955
13955
  o.add(n.id);
13956
- let m = P(n.end), h = a.get(n.id) + 1;
13956
+ let m = M(n.end), h = a.get(n.id) + 1;
13957
13957
  for (const p of t)
13958
- o.has(p.id) || P(p.start) < m && (c.push(p), o.add(p.id), m = Math.max(m, P(p.end)), h = Math.max(h, a.get(p.id) + 1));
13958
+ o.has(p.id) || M(p.start) < m && (c.push(p), o.add(p.id), m = Math.max(m, M(p.end)), h = Math.max(h, a.get(p.id) + 1));
13959
13959
  l.push({
13960
13960
  events: c,
13961
13961
  totalColumns: h
@@ -13963,7 +13963,7 @@ function oa(e) {
13963
13963
  }
13964
13964
  const s = [];
13965
13965
  for (const n of l) for (const c of n.events) {
13966
- const m = P(c.start), h = P(c.end), p = a.get(c.id), u = n.totalColumns;
13966
+ const m = M(c.start), h = M(c.end), p = a.get(c.id), u = n.totalColumns;
13967
13967
  s.push({
13968
13968
  event: c,
13969
13969
  gridRowStart: or(m),
@@ -17017,7 +17017,7 @@ sr = v([f({
17017
17017
  "size"
17018
17018
  ]
17019
17019
  })], sr);
17020
- function Mi(e) {
17020
+ function Pi(e) {
17021
17021
  const t = e.tabs.length > 0;
17022
17022
  return i`
17023
17023
  <div
@@ -17034,7 +17034,7 @@ function Mi(e) {
17034
17034
  aria-orientation=${e.orientation}
17035
17035
  @keydown=${e.handleKeyDown}
17036
17036
  >
17037
- ${t ? k(e.tabs, (r) => `${r.value}-${e.value === r.value}`, (r) => Pi(e, r)) : i`<slot name="tab" @slotchange=${e.handleTabSlotChange}></slot>`}
17037
+ ${t ? k(e.tabs, (r) => `${r.value}-${e.value === r.value}`, (r) => Mi(e, r)) : i`<slot name="tab" @slotchange=${e.handleTabSlotChange}></slot>`}
17038
17038
  </div>
17039
17039
 
17040
17040
  <div class="ml-tabs__panels">
@@ -17043,7 +17043,7 @@ function Mi(e) {
17043
17043
  </div>
17044
17044
  `;
17045
17045
  }
17046
- function Pi(e, t) {
17046
+ function Mi(e, t) {
17047
17047
  const r = e.value === t.value;
17048
17048
  return i`
17049
17049
  <button
@@ -17477,7 +17477,7 @@ var nr = class {
17477
17477
  };
17478
17478
  nr = v([f({
17479
17479
  selector: "ml-tabs",
17480
- template: Mi,
17480
+ template: Pi,
17481
17481
  styles: Oi,
17482
17482
  attributes: [
17483
17483
  "value",
@@ -20896,7 +20896,7 @@ var _s = class {
20896
20896
  this._dialogEl.showModal(), this._afterOpenedCallback?.();
20897
20897
  }
20898
20898
  close(e) {
20899
- this._dialogEl.close(), this._afterClosedCallback?.(e);
20899
+ this._dismissDescendantPopovers(this._dialogEl), this._dialogEl.close(), this._afterClosedCallback?.(e);
20900
20900
  }
20901
20901
  afterOpened(e) {
20902
20902
  this._afterOpenedCallback = e;
@@ -20910,6 +20910,15 @@ var _s = class {
20910
20910
  onBackdropClick(e) {
20911
20911
  e.target === this._dialogEl && !this._disableClose && this.close();
20912
20912
  }
20913
+ _dismissDescendantPopovers(e) {
20914
+ e.querySelectorAll("*").forEach((t) => {
20915
+ if (t.hasAttribute("popover")) try {
20916
+ t.hidePopover();
20917
+ } catch {
20918
+ }
20919
+ t.shadowRoot && this._dismissDescendantPopovers(t.shadowRoot);
20920
+ });
20921
+ }
20913
20922
  }, le = class {
20914
20923
  constructor() {
20915
20924
  this._dialogs = /* @__PURE__ */ new Map();
@@ -22115,7 +22124,7 @@ Er = v([f({
22115
22124
  "arrow"
22116
22125
  ]
22117
22126
  })], Er);
22118
- function Ms(e) {
22127
+ function Ps(e) {
22119
22128
  const t = e["sidebar-position"] === "right", r = e["sidebar-collapsed"], a = e["header-fixed"], l = e.mobileOpen, o = e.mobile;
22120
22129
  return i`
22121
22130
  <div
@@ -22170,7 +22179,7 @@ function Ms(e) {
22170
22179
  </div>
22171
22180
  `;
22172
22181
  }
22173
- const Ps = () => _`
22182
+ const Ms = () => _`
22174
22183
  :host {
22175
22184
  display: block;
22176
22185
  height: 100%;
@@ -22409,8 +22418,8 @@ var Rr = class {
22409
22418
  };
22410
22419
  Rr = v([f({
22411
22420
  selector: "ml-app-shell",
22412
- template: Ms,
22413
- styles: Ps,
22421
+ template: Ps,
22422
+ styles: Ms,
22414
22423
  attributes: [
22415
22424
  "sidebar-position",
22416
22425
  "sidebar-collapsed",
@@ -23652,7 +23661,7 @@ const Ys = () => _`
23652
23661
  }
23653
23662
  }
23654
23663
  `;
23655
- var Mr = class {
23664
+ var Pr = class {
23656
23665
  constructor() {
23657
23666
  this.title = "", this.description = "", this.layout = "default";
23658
23667
  }
@@ -23669,7 +23678,7 @@ var Mr = class {
23669
23678
  return this.elementRef?.querySelector('[slot="header-actions"]') !== null;
23670
23679
  }
23671
23680
  };
23672
- Mr = v([f({
23681
+ Pr = v([f({
23673
23682
  selector: "ml-dashboard-page",
23674
23683
  template: Hs,
23675
23684
  styles: Ys,
@@ -23678,14 +23687,14 @@ Mr = v([f({
23678
23687
  "description",
23679
23688
  "layout"
23680
23689
  ]
23681
- })], Mr);
23690
+ })], Pr);
23682
23691
  export {
23683
23692
  fa as APP_CONFIG,
23684
23693
  wa as AbortError,
23685
23694
  se as AbstractControl,
23686
23695
  Xt as ActivityFeedComponent,
23687
23696
  Jt as ActivityFeedItemComponent,
23688
- Pt as AlertComponent,
23697
+ Mt as AlertComponent,
23689
23698
  Rr as AppShellComponent,
23690
23699
  Ht as AvatarComponent,
23691
23700
  Yt as BadgeComponent,
@@ -23703,8 +23712,8 @@ export {
23703
23712
  ga as ComponentBase,
23704
23713
  un as ComponentStateBaseService,
23705
23714
  jt as ContainerComponent,
23706
- Mr as DashboardPageComponent,
23707
- Mt as DatePickerComponent,
23715
+ Pr as DashboardPageComponent,
23716
+ Pt as DatePickerComponent,
23708
23717
  Oe as DialogComponent,
23709
23718
  _s as DialogRef,
23710
23719
  le as DialogService,
@@ -23754,7 +23763,7 @@ export {
23754
23763
  Re as RouterLinkComponent,
23755
23764
  Ee as RouterOutletComponent,
23756
23765
  q as RouterService,
23757
- Pr as SIGNAL_MARKER,
23766
+ Mr as SIGNAL_MARKER,
23758
23767
  Et as SelectComponent,
23759
23768
  G as Service,
23760
23769
  ur as SidebarComponent,
@@ -23789,8 +23798,8 @@ export {
23789
23798
  Uo as activityFeedTemplate,
23790
23799
  dl as allTokens,
23791
23800
  qn as announce,
23792
- Ps as appShellStyles,
23793
- Ms as appShellTemplate,
23801
+ Ms as appShellStyles,
23802
+ Ps as appShellTemplate,
23794
23803
  ca as applyGlobalStyles,
23795
23804
  hl as applyTheme,
23796
23805
  Jr as arrow,
@@ -23814,11 +23823,11 @@ export {
23814
23823
  Hn as componentBaseStyles,
23815
23824
  ne as computePosition,
23816
23825
  D as computed,
23817
- Po as containerStyles,
23818
- Mo as containerTemplate,
23826
+ Mo as containerStyles,
23827
+ Po as containerTemplate,
23819
23828
  cn as createAction,
23820
23829
  Cn as createAsyncValidator,
23821
- Mn as createBrandTheme,
23830
+ Pn as createBrandTheme,
23822
23831
  Qs as createDeactivateGuard,
23823
23832
  wl as createFocusTrap,
23824
23833
  xn as createFormArray,
@@ -23852,7 +23861,7 @@ export {
23852
23861
  ba as environment,
23853
23862
  ka as findRouteByName,
23854
23863
  ce as flip,
23855
- Pn as focusFirst,
23864
+ Mn as focusFirst,
23856
23865
  On as focusLast,
23857
23866
  Nn as focusTrap,
23858
23867
  Vn as focusVisible,
@@ -23948,7 +23957,7 @@ export {
23948
23957
  ti as tableStyles,
23949
23958
  ei as tableTemplate,
23950
23959
  Oi as tabsStyles,
23951
- Mi as tabsTemplate,
23960
+ Pi as tabsTemplate,
23952
23961
  Xa as textAdapter,
23953
23962
  xo as toastContainerStyles,
23954
23963
  yo as toastContainerTemplate,
@@ -20,5 +20,6 @@ export declare class DialogRef<TResult = unknown, TData = unknown> {
20
20
  afterClosed(callback: (result: TResult | undefined) => void): void;
21
21
  private onCancel;
22
22
  private onBackdropClick;
23
+ private _dismissDescendantPopovers;
23
24
  }
24
25
  //# sourceMappingURL=dialog-ref.class.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"dialog-ref.class.d.ts","sourceRoot":"","sources":["../../../../src/components/overlays/dialog/dialog-ref.class.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE/D,qBAAa,SAAS,CAAC,OAAO,GAAG,OAAO,EAAE,KAAK,GAAG,OAAO;IASvD,OAAO,CAAC,QAAQ,CAAC,SAAS;IAC1B,OAAO,CAAC,QAAQ,CAAC,SAAS;IAT3B,OAAO,CAAC,oBAAoB,CAA6B;IACzD,OAAO,CAAC,oBAAoB,CAAwD;IACpF,OAAO,CAAC,KAAK,CAAoB;IACjC,OAAO,CAAC,aAAa,CAAS;IAC9B,OAAO,CAAC,QAAQ,CAAC,aAAa,CAA4B;IAC1D,OAAO,CAAC,QAAQ,CAAC,oBAAoB,CAAmC;gBAGtD,SAAS,EAAE,QAAQ,EACnB,SAAS,EAAE,iBAAiB;IAM9C,IAAW,QAAQ,IAAI,QAAQ,CAE9B;IAED,IAAW,IAAI,IAAI,KAAK,GAAG,SAAS,CAEnC;IAED,IAAW,YAAY,IAAI,OAAO,CAEjC;IAEM,WAAW,CAAC,MAAM,EAAE,aAAa,CAAC,KAAK,CAAC,GAAG,IAAI;IAyB/C,IAAI,IAAI,IAAI;IAKZ,KAAK,CAAC,MAAM,CAAC,EAAE,OAAO,GAAG,IAAI;IAK7B,WAAW,CAAC,QAAQ,EAAE,MAAM,IAAI,GAAG,IAAI;IAIvC,WAAW,CAAC,QAAQ,EAAE,CAAC,MAAM,EAAE,OAAO,GAAG,SAAS,KAAK,IAAI,GAAG,IAAI;IAIzE,OAAO,CAAC,QAAQ;IAMhB,OAAO,CAAC,eAAe;CAKvB"}
1
+ {"version":3,"file":"dialog-ref.class.d.ts","sourceRoot":"","sources":["../../../../src/components/overlays/dialog/dialog-ref.class.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE/D,qBAAa,SAAS,CAAC,OAAO,GAAG,OAAO,EAAE,KAAK,GAAG,OAAO;IASvD,OAAO,CAAC,QAAQ,CAAC,SAAS;IAC1B,OAAO,CAAC,QAAQ,CAAC,SAAS;IAT3B,OAAO,CAAC,oBAAoB,CAA6B;IACzD,OAAO,CAAC,oBAAoB,CAAwD;IACpF,OAAO,CAAC,KAAK,CAAoB;IACjC,OAAO,CAAC,aAAa,CAAS;IAC9B,OAAO,CAAC,QAAQ,CAAC,aAAa,CAA4B;IAC1D,OAAO,CAAC,QAAQ,CAAC,oBAAoB,CAAmC;gBAGtD,SAAS,EAAE,QAAQ,EACnB,SAAS,EAAE,iBAAiB;IAM9C,IAAW,QAAQ,IAAI,QAAQ,CAE9B;IAED,IAAW,IAAI,IAAI,KAAK,GAAG,SAAS,CAEnC;IAED,IAAW,YAAY,IAAI,OAAO,CAEjC;IAEM,WAAW,CAAC,MAAM,EAAE,aAAa,CAAC,KAAK,CAAC,GAAG,IAAI;IAyB/C,IAAI,IAAI,IAAI;IAKZ,KAAK,CAAC,MAAM,CAAC,EAAE,OAAO,GAAG,IAAI;IAM7B,WAAW,CAAC,QAAQ,EAAE,MAAM,IAAI,GAAG,IAAI;IAIvC,WAAW,CAAC,QAAQ,EAAE,CAAC,MAAM,EAAE,OAAO,GAAG,SAAS,KAAK,IAAI,GAAG,IAAI;IAIzE,OAAO,CAAC,QAAQ;IAMhB,OAAO,CAAC,eAAe;IAMvB,OAAO,CAAC,0BAA0B;CAelC"}
@@ -43,6 +43,7 @@ export class DialogRef {
43
43
  this._afterOpenedCallback?.();
44
44
  }
45
45
  close(result) {
46
+ this._dismissDescendantPopovers(this._dialogEl);
46
47
  this._dialogEl.close();
47
48
  this._afterClosedCallback?.(result);
48
49
  }
@@ -62,4 +63,20 @@ export class DialogRef {
62
63
  this.close();
63
64
  }
64
65
  }
66
+ _dismissDescendantPopovers(root) {
67
+ const children = root.querySelectorAll('*');
68
+ children.forEach((el) => {
69
+ if (el.hasAttribute('popover')) {
70
+ try {
71
+ el.hidePopover();
72
+ }
73
+ catch {
74
+ // Not currently in the top layer — safe to ignore
75
+ }
76
+ }
77
+ if (el.shadowRoot) {
78
+ this._dismissDescendantPopovers(el.shadowRoot);
79
+ }
80
+ });
81
+ }
65
82
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@melodicdev/components",
3
- "version": "1.6.6",
3
+ "version": "1.6.7",
4
4
  "description": "Themeable UI component library built on the Melodic Framework",
5
5
  "license": "MIT",
6
6
  "author": "Melodic Development",