dap-design-system 0.54.7 → 0.54.8

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.
@@ -47,6 +47,7 @@ export default class DapDSCodePuncher extends GenericFormElement {
47
47
  private _activeIndex;
48
48
  private _chars;
49
49
  private _hasFocus;
50
+ private _rawValue;
50
51
  static readonly styles: import('lit').CSSResult;
51
52
  private _patternRegex;
52
53
  private _provider;
@@ -6157,7 +6157,7 @@ var qh = Object.defineProperty, Kh = Object.getOwnPropertyDescriptor, li = (t, e
6157
6157
  };
6158
6158
  let De = class extends pe {
6159
6159
  constructor() {
6160
- super(...arguments), this.mask = !1, this.pattern = "[0-9]", this.placeholder = "", this.autocomplete = "one-time-code", this._slots = [], this._activeIndex = -1, this._chars = [], this._hasFocus = !1, this._patternRegex = /^[0-9]$/;
6160
+ super(...arguments), this.mask = !1, this.pattern = "[0-9]", this.placeholder = "", this.autocomplete = "one-time-code", this._slots = [], this._activeIndex = -1, this._chars = [], this._hasFocus = !1, this._rawValue = "", this._patternRegex = /^[0-9]$/;
6161
6161
  }
6162
6162
  _getContextValue() {
6163
6163
  return {
@@ -6193,17 +6193,23 @@ let De = class extends pe {
6193
6193
  return this._chars.join("");
6194
6194
  }
6195
6195
  set value(t) {
6196
+ if (this._rawValue = t, this._slots.length === 0) return;
6196
6197
  const e = t.split("");
6197
- for (this._chars = e.slice(0, this._slots.length); this._chars.length < this._slots.length; )
6198
- this._chars.push("");
6199
- this.internals.setFormValue(this.value), this.requestUpdate();
6198
+ this._chars = Array.from(
6199
+ { length: this._slots.length },
6200
+ (i, o) => {
6201
+ var r;
6202
+ return (r = e[o]) != null ? r : "";
6203
+ }
6204
+ ), this.internals.setFormValue(this.value), this.requestUpdate();
6200
6205
  }
6201
6206
  willUpdate(t) {
6202
6207
  super.willUpdate(t), t.has("pattern") && (this._patternRegex = new RegExp(`^${this.pattern}$`)), this._updateContext();
6203
6208
  }
6204
6209
  _registerSlot(t) {
6210
+ var i;
6205
6211
  const e = this._slots.length;
6206
- return this._slots = [...this._slots, t], this._chars = [...this._chars, ""], this.requestUpdate(), e;
6212
+ return this._slots = [...this._slots, t], this._chars = [...this._chars, (i = this._rawValue[e]) != null ? i : ""], this.internals.setFormValue(this.value), this.requestUpdate(), e;
6207
6213
  }
6208
6214
  _unregisterSlot(t) {
6209
6215
  const e = this._slots.indexOf(t);
@@ -21463,7 +21469,7 @@ export {
21463
21469
  Ei as A,
21464
21470
  To as B,
21465
21471
  Ea as C,
21466
- Po as D,
21472
+ Us as D,
21467
21473
  Ir as E,
21468
21474
  W as F,
21469
21475
  et as G,
@@ -21487,7 +21493,7 @@ export {
21487
21493
  ja as Y,
21488
21494
  Ro as Z,
21489
21495
  ie as _,
21490
- Us as a,
21496
+ Be as a,
21491
21497
  Lr as a0,
21492
21498
  zt as a1,
21493
21499
  Ar as a2,
@@ -21533,24 +21539,24 @@ export {
21533
21539
  co as ax,
21534
21540
  me as ay,
21535
21541
  Er as az,
21536
- Be as b,
21537
- to as c,
21538
- Qi as d,
21539
- Ut as e,
21540
- fi as f,
21541
- He as g,
21542
+ to as b,
21543
+ Ut as c,
21544
+ He as d,
21545
+ fi as e,
21546
+ Qi as f,
21547
+ Po as g,
21542
21548
  ii as h,
21543
21549
  Ot as i,
21544
21550
  qt as j,
21545
21551
  Et as k,
21546
21552
  Xt as l,
21547
- jt as m,
21548
- Ia as n,
21549
- $r as o,
21550
- Li as p,
21551
- Sr as q,
21552
- Eo as r,
21553
- ve as s,
21553
+ Ia as m,
21554
+ $r as n,
21555
+ Li as o,
21556
+ Sr as p,
21557
+ Eo as q,
21558
+ ve as r,
21559
+ jt as s,
21554
21560
  Ce as t,
21555
21561
  Ai as u,
21556
21562
  De as v,
@@ -21559,4 +21565,4 @@ export {
21559
21565
  Qt as y,
21560
21566
  xi as z
21561
21567
  };
21562
- //# sourceMappingURL=components-CxteXcvo.js.map
21568
+ //# sourceMappingURL=components-B4VmOYHn.js.map