@magmonium/one 0.2.64 → 0.2.65

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.
@@ -6992,7 +6992,7 @@ class SectionFormItemComponent extends ConfigComponent {
6992
6992
  break;
6993
6993
  }
6994
6994
  case InputType.TOGGLE: {
6995
- const { ToggleInputComponent } = await import('./magmonium-one-toggle-ClMCzNyX.mjs');
6995
+ const { ToggleInputComponent } = await import('./magmonium-one-toggle-Bt7PKdJF.mjs');
6996
6996
  this.createDynamicComponent(seq, ToggleInputComponent, [], true);
6997
6997
  break;
6998
6998
  }
@@ -7004,12 +7004,12 @@ class SectionFormItemComponent extends ConfigComponent {
7004
7004
  break;
7005
7005
  }
7006
7006
  case InputType.PASSWORD: {
7007
- const { PasswordInputComponent } = await import('./magmonium-one-password-9dcVrCh6.mjs');
7007
+ const { PasswordInputComponent } = await import('./magmonium-one-password-DFK2Wr3Q.mjs');
7008
7008
  this.createDynamicComponent(seq, PasswordInputComponent);
7009
7009
  break;
7010
7010
  }
7011
7011
  case InputType.OTP: {
7012
- const { OtpInputComponent } = await import('./magmonium-one-otp-BRc_lVXW.mjs');
7012
+ const { OtpInputComponent } = await import('./magmonium-one-otp-DAjGRkND.mjs');
7013
7013
  this.createDynamicComponent(seq, OtpInputComponent);
7014
7014
  break;
7015
7015
  }
@@ -7356,8 +7356,9 @@ const findFirstFocusable = (root) => {
7356
7356
  *
7357
7357
  * Arrays, objects and booleans keep their shape — a boolean stringified to ''
7358
7358
  * reads as "unset" to every consumer that filters empty values, so `false`
7359
- * could never survive a round trip (ADR 0010). Everything else becomes a
7360
- * string, an absent key becoming ''.
7359
+ * could never survive a round trip (ADR 0010). A number stays one too: a
7360
+ * rating's key is typed `number`, and `'3'` handed back through `dataChange`
7361
+ * would lie to it. Everything else becomes a string, an absent key becoming ''.
7361
7362
  *
7362
7363
  * `data` is typed `object` rather than `Record<string, unknown>`: a caller's
7363
7364
  * shape is often an `interface`, which has no implicit index signature and so
@@ -7375,7 +7376,7 @@ const toModelValues = (data, keys) => {
7375
7376
  else if (raw !== null && typeof raw === 'object') {
7376
7377
  values[key] = raw;
7377
7378
  }
7378
- else if (typeof raw === 'boolean') {
7379
+ else if (typeof raw === 'boolean' || typeof raw === 'number') {
7379
7380
  values[key] = raw;
7380
7381
  }
7381
7382
  else {
@@ -10689,6 +10690,13 @@ class AutosizeDirective {
10689
10690
  // resizing and flickered. On the canvas the field keeps its intrinsic
10690
10691
  // `rows` height and is never resized.
10691
10692
  #isDesignMode = !!inject(IS_DESIGN_MODE, { optional: true });
10693
+ // What the height was last measured against. Outside the canvas, change
10694
+ // detection still runs on every hover, select and drag; re-measuring on each
10695
+ // pass collapsed the field to `0px` for a moment, which clamps the scrollTop
10696
+ // of any scrolling ancestor — the panel jumped and the field flickered. Only
10697
+ // a new value or a new width can change the height, so nothing else measures.
10698
+ #measuredValue = null;
10699
+ #measuredWidth = -1;
10692
10700
  onInput() {
10693
10701
  if (!this.#isDesignMode)
10694
10702
  this.#adjust();
@@ -10710,6 +10718,12 @@ class AutosizeDirective {
10710
10718
  // stretches it and `scrollHeight` is the content alone.
10711
10719
  #adjust = () => {
10712
10720
  const el = this._el.nativeElement;
10721
+ const width = el.clientWidth;
10722
+ if (el.value === this.#measuredValue && width === this.#measuredWidth) {
10723
+ return;
10724
+ }
10725
+ this.#measuredValue = el.value;
10726
+ this.#measuredWidth = width;
10713
10727
  el.style.overflow = 'hidden';
10714
10728
  el.style.height = '0px';
10715
10729
  el.style.height = `${el.scrollHeight}px`;
@@ -20788,7 +20802,7 @@ class WrapperInputComponent extends ConfigComponent {
20788
20802
  break;
20789
20803
  }
20790
20804
  case InputType.TOGGLE: {
20791
- const { ToggleInputComponent } = await import('./magmonium-one-toggle-ClMCzNyX.mjs');
20805
+ const { ToggleInputComponent } = await import('./magmonium-one-toggle-Bt7PKdJF.mjs');
20792
20806
  this.createDynamicComponent(seq, ToggleInputComponent, [], true);
20793
20807
  break;
20794
20808
  }
@@ -20800,12 +20814,12 @@ class WrapperInputComponent extends ConfigComponent {
20800
20814
  break;
20801
20815
  }
20802
20816
  case InputType.PASSWORD: {
20803
- const { PasswordInputComponent } = await import('./magmonium-one-password-9dcVrCh6.mjs');
20817
+ const { PasswordInputComponent } = await import('./magmonium-one-password-DFK2Wr3Q.mjs');
20804
20818
  this.createDynamicComponent(seq, PasswordInputComponent);
20805
20819
  break;
20806
20820
  }
20807
20821
  case InputType.OTP: {
20808
- const { OtpInputComponent } = await import('./magmonium-one-otp-BRc_lVXW.mjs');
20822
+ const { OtpInputComponent } = await import('./magmonium-one-otp-DAjGRkND.mjs');
20809
20823
  this.createDynamicComponent(seq, OtpInputComponent);
20810
20824
  break;
20811
20825
  }
@@ -21711,7 +21725,23 @@ var selectableCard = /*#__PURE__*/Object.freeze({
21711
21725
  SelectableCardInputComponent: SelectableCardInputComponent
21712
21726
  });
21713
21727
 
21714
- const STARS = [1, 2, 3, 4, 5];
21728
+ /** Star indexes; the index IS the emitted value (0 = first star, 4 = fifth). */
21729
+ const STARS = [0, 1, 2, 3, 4];
21730
+ const MAX_RATING = STARS.length - 1;
21731
+ /**
21732
+ * Reads a bound value as a rating: a form model hands it over as text ('' or
21733
+ * '3'), so strings are parsed; blank or non-numeric reads as unrated.
21734
+ */
21735
+ const toRating = (raw) => {
21736
+ if (raw === null || raw === undefined)
21737
+ return null;
21738
+ if (typeof raw === 'string' && !raw.trim())
21739
+ return null;
21740
+ const parsed = Number(raw);
21741
+ if (!Number.isFinite(parsed))
21742
+ return null;
21743
+ return Math.min(Math.max(parsed, 0), MAX_RATING);
21744
+ };
21715
21745
  class RatingInputComponent extends BaseInputComponent {
21716
21746
  value = model(null, ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
21717
21747
  config = input(...(ngDevMode ? [undefined, { debugName: "config" }] : /* istanbul ignore next */ []));
@@ -21731,32 +21761,38 @@ class RatingInputComponent extends BaseInputComponent {
21731
21761
  }, ...(ngDevMode ? [{ debugName: "filledColor" }] : /* istanbul ignore next */ []));
21732
21762
  enlarged = computed(() => this.config()?.enlarge === true || `${this.config()?.enlarge}` === 'true', ...(ngDevMode ? [{ debugName: "enlarged" }] : /* istanbul ignore next */ []));
21733
21763
  hoverValue = signal(null, ...(ngDevMode ? [{ debugName: "hoverValue" }] : /* istanbul ignore next */ []));
21764
+ /** Committed value as a number 0–4, or null when unrated. */
21765
+ ratingValue = computed(() => toRating(this.value()), ...(ngDevMode ? [{ debugName: "ratingValue" }] : /* istanbul ignore next */ []));
21734
21766
  interactive = computed(() => !this.disabled() && !this.readonly(), ...(ngDevMode ? [{ debugName: "interactive" }] : /* istanbul ignore next */ []));
21735
- /** Effective display value: hover preview (interactive) or committed value */
21736
- displayValue = computed(() => {
21767
+ /**
21768
+ * Filled star count (0–5): hover preview (interactive) or committed value.
21769
+ * Value is a zero-based index, so value 0 fills one star.
21770
+ */
21771
+ filledCount = computed(() => {
21737
21772
  const hover = this.hoverValue();
21738
21773
  if (this.interactive() && hover !== null)
21739
- return hover;
21740
- return this.value() ?? 0;
21741
- }, ...(ngDevMode ? [{ debugName: "displayValue" }] : /* istanbul ignore next */ []));
21774
+ return hover + 1;
21775
+ const rating = this.ratingValue();
21776
+ return rating === null ? 0 : rating + 1;
21777
+ }, ...(ngDevMode ? [{ debugName: "filledCount" }] : /* istanbul ignore next */ []));
21742
21778
  /**
21743
21779
  * Per-star fill percentage (0–100).
21744
21780
  * Interactive: always full (0 or 100) because hover snaps to whole stars.
21745
21781
  * Read-only: fractional fill for the partial star.
21746
21782
  */
21747
21783
  starFill = (star) => {
21748
- const display = this.displayValue();
21749
- if (display >= star)
21784
+ const filled = this.filledCount();
21785
+ if (filled >= star + 1)
21750
21786
  return 100;
21751
- if (display < star - 1)
21787
+ if (filled <= star)
21752
21788
  return 0;
21753
- // Partial: e.g. value=4.7, star=5 → 70%
21754
- return Math.round((display - (star - 1)) * 100);
21789
+ // Partial: e.g. value=3.7 → 4.7 filled, star=4 → 70%
21790
+ return Math.round((filled - star) * 100);
21755
21791
  };
21756
- rate = (value) => {
21792
+ rate = (star) => {
21757
21793
  if (!this.interactive())
21758
21794
  return;
21759
- this.value.set(value);
21795
+ this.value.set(star);
21760
21796
  this.touched.set(true);
21761
21797
  this.hoverValue.set(null);
21762
21798
  };
@@ -21768,11 +21804,11 @@ class RatingInputComponent extends BaseInputComponent {
21768
21804
  this.hoverValue.set(null);
21769
21805
  };
21770
21806
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RatingInputComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
21771
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.9", type: RatingInputComponent, isStandalone: true, selector: "m-rating-input", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null }, touched: { classPropertyName: "touched", publicName: "touched", isSignal: true, isRequired: false, transformFunction: null }, focused: { classPropertyName: "focused", publicName: "focused", isSignal: true, isRequired: false, transformFunction: null }, errors: { classPropertyName: "errors", publicName: "errors", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange", touched: "touchedChange" }, usesInheritance: true, ngImport: i0, template: "@if (config(); as rating) {\n @if (rating.label) {\n <m-label\n [for]=\"rating.name ?? ''\"\n [placeholder]=\"rating.label\"\n [params]=\"rating.params\"\n [required]=\"required()\"\n [disabled]=\"disabled()\"\n />\n }\n\n <div\n class=\"rating\"\n [class.rating--error]=\"showErrors()\"\n [class.rating--enlarge]=\"enlarged()\"\n [style.--rating-color-filled]=\"filledColor()\"\n >\n <div\n class=\"rating__stars\"\n [class.rating__stars--interactive]=\"interactive()\"\n [class.rating__stars--disabled]=\"disabled()\"\n (mouseleave)=\"onLeave()\"\n >\n <!-- Hidden SVG for per-star gradient defs -->\n <svg width=\"0\" height=\"0\" aria-hidden=\"true\" class=\"rating__defs\">\n <defs>\n @for (star of stars; track star) {\n <linearGradient [id]=\"'star-grad-' + star\" x1=\"0%\" y1=\"0%\" x2=\"100%\" y2=\"0%\">\n <stop [attr.offset]=\"starFill(star) + '%'\" class=\"rating__stop--filled\" />\n <stop [attr.offset]=\"starFill(star) + '%'\" class=\"rating__stop--empty\" />\n </linearGradient>\n }\n </defs>\n </svg>\n\n @for (star of stars; track star) {\n <button\n class=\"rating__star\"\n type=\"button\"\n [attr.aria-label]=\"'rate-star-out-of-5' | translate: { star: star.toString() }\"\n [attr.aria-pressed]=\"(value() ?? 0) >= star\"\n [attr.disabled]=\"(!interactive()) ? true : null\"\n (click)=\"rate(star)\"\n (mouseenter)=\"onHover(star)\"\n >\n <svg\n class=\"rating__star-svg\"\n viewBox=\"0 0 24 24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n aria-hidden=\"true\"\n >\n <polygon\n class=\"rating__star-shape\"\n [attr.fill]=\"'url(#star-grad-' + star + ')'\"\n points=\"12,2.5 15.27,9.14 22.6,10.13 17.3,15.26 18.54,22.56 12,19.13 5.46,22.56 6.7,15.26 1.4,10.13 8.73,9.14\"\n />\n </svg>\n </button>\n }\n </div>\n </div>\n\n @if (showErrors()) {\n @for (error of errors(); track $index) {\n <m-text-output\n variant=\"footer\"\n color=\"error\"\n [label]=\"error.message\"\n />\n }\n }\n}\n", styles: ["@keyframes toggle-pulse{0%,to{transform:scale(1)}50%{transform:scale(1.02)}}@keyframes thumb-slide{0%{transform:translate(0) scale(1)}50%{transform:translate(.3em) scale(.9)}to{transform:translate(.6em) scale(1)}}.rating{display:inline-flex;flex-direction:column;gap:6px}.rating__defs{display:block;width:0;height:0;overflow:hidden;pointer-events:none;flex-shrink:0}.rating__stop--filled{stop-color:var(--rating-color-filled, #FFB800);stop-opacity:1}.rating__stop--empty{stop-color:#e0e0e0;stop-opacity:1}.rating__stars{position:relative;display:inline-flex;align-items:center;gap:4px}.rating__star{display:inline-flex;align-items:center;justify-content:center;width:28px;height:28px;padding:0;background:none;border:none;cursor:default;outline:none;flex-shrink:0}.rating__star-svg{width:28px;height:28px;display:block;filter:drop-shadow(0 1px 1px rgba(0,0,0,.08));transition:opacity .15s ease,transform .12s ease}.rating__star-shape{stroke:#0000000f;stroke-width:.5px}.rating__stars--interactive .rating__star{cursor:pointer;border-radius:4px}.rating__stars--interactive .rating__star:focus-visible{outline:2px solid var(--m-mm);outline-offset:2px;border-radius:4px}.rating__stars--interactive .rating__star:hover .rating__star-svg,.rating__stars--interactive .rating__star:focus-visible .rating__star-svg{transform:scale(1.15);filter:drop-shadow(0 2px 4px rgba(0,0,0,.18))}.rating__stars--disabled{opacity:.5;pointer-events:none}.rating__stars--disabled .rating__stop--filled{stop-color:#bdbdbd}.rating--enlarge .rating__star,.rating--enlarge .rating__star-svg{width:56px;height:56px}.rating--error .rating__stop--filled{stop-color:var(--m-error)}\n"], dependencies: [{ kind: "component", type: LabelComponent, selector: "m-label", inputs: ["for", "placeholder", "params", "required", "disabled", "color"] }, { kind: "component", type: TextOutputComponent, selector: "m-text-output", inputs: ["config", "align", "variant", "color", "label", "noTranslate", "params"], outputs: ["configChange", "clicked"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
21807
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.9", type: RatingInputComponent, isStandalone: true, selector: "m-rating-input", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, invalid: { classPropertyName: "invalid", publicName: "invalid", isSignal: true, isRequired: false, transformFunction: null }, touched: { classPropertyName: "touched", publicName: "touched", isSignal: true, isRequired: false, transformFunction: null }, focused: { classPropertyName: "focused", publicName: "focused", isSignal: true, isRequired: false, transformFunction: null }, errors: { classPropertyName: "errors", publicName: "errors", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange", touched: "touchedChange" }, usesInheritance: true, ngImport: i0, template: "@if (config(); as rating) {\n @if (rating.label) {\n <m-label\n [for]=\"rating.name ?? ''\"\n [placeholder]=\"rating.label\"\n [params]=\"rating.params\"\n [required]=\"required()\"\n [disabled]=\"disabled()\"\n />\n }\n\n <div\n class=\"rating\"\n [class.rating--error]=\"showErrors()\"\n [class.rating--enlarge]=\"enlarged()\"\n [style.--rating-color-filled]=\"filledColor()\"\n >\n <div\n class=\"rating__stars\"\n [class.rating__stars--interactive]=\"interactive()\"\n [class.rating__stars--disabled]=\"disabled()\"\n (mouseleave)=\"onLeave()\"\n >\n <!-- Hidden SVG for per-star gradient defs -->\n <svg width=\"0\" height=\"0\" aria-hidden=\"true\" class=\"rating__defs\">\n <defs>\n @for (star of stars; track star) {\n <linearGradient [id]=\"'star-grad-' + star\" x1=\"0%\" y1=\"0%\" x2=\"100%\" y2=\"0%\">\n <stop [attr.offset]=\"starFill(star) + '%'\" class=\"rating__stop--filled\" />\n <stop [attr.offset]=\"starFill(star) + '%'\" class=\"rating__stop--empty\" />\n </linearGradient>\n }\n </defs>\n </svg>\n\n @for (star of stars; track star) {\n <button\n class=\"rating__star\"\n type=\"button\"\n [attr.aria-label]=\"'rate-star-out-of-5' | translate: { star: (star + 1).toString() }\"\n [attr.aria-pressed]=\"(ratingValue() ?? -1) >= star\"\n [attr.disabled]=\"(!interactive()) ? true : null\"\n (click)=\"rate(star)\"\n (mouseenter)=\"onHover(star)\"\n >\n <svg\n class=\"rating__star-svg\"\n viewBox=\"0 0 24 24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n aria-hidden=\"true\"\n >\n <polygon\n class=\"rating__star-shape\"\n [attr.fill]=\"'url(#star-grad-' + star + ')'\"\n points=\"12,2.5 15.27,9.14 22.6,10.13 17.3,15.26 18.54,22.56 12,19.13 5.46,22.56 6.7,15.26 1.4,10.13 8.73,9.14\"\n />\n </svg>\n </button>\n }\n </div>\n </div>\n\n @if (showErrors()) {\n @for (error of errors(); track $index) {\n <m-text-output\n variant=\"footer\"\n color=\"error\"\n [label]=\"error.message\"\n />\n }\n }\n}\n", styles: ["@keyframes toggle-pulse{0%,to{transform:scale(1)}50%{transform:scale(1.02)}}@keyframes thumb-slide{0%{transform:translate(0) scale(1)}50%{transform:translate(.3em) scale(.9)}to{transform:translate(.6em) scale(1)}}.rating{display:inline-flex;flex-direction:column;gap:6px}.rating__defs{display:block;width:0;height:0;overflow:hidden;pointer-events:none;flex-shrink:0}.rating__stop--filled{stop-color:var(--rating-color-filled, #FFB800);stop-opacity:1}.rating__stop--empty{stop-color:#e0e0e0;stop-opacity:1}.rating__stars{position:relative;display:inline-flex;align-items:center;gap:4px}.rating__star{display:inline-flex;align-items:center;justify-content:center;width:28px;height:28px;padding:0;background:none;border:none;cursor:default;outline:none;flex-shrink:0}.rating__star-svg{width:28px;height:28px;display:block;filter:drop-shadow(0 1px 1px rgba(0,0,0,.08));transition:opacity .15s ease,transform .12s ease}.rating__star-shape{stroke:#0000000f;stroke-width:.5px}.rating__stars--interactive .rating__star{cursor:pointer;border-radius:4px}.rating__stars--interactive .rating__star:focus-visible{outline:2px solid var(--m-mm);outline-offset:2px;border-radius:4px}.rating__stars--interactive .rating__star:hover .rating__star-svg,.rating__stars--interactive .rating__star:focus-visible .rating__star-svg{transform:scale(1.15);filter:drop-shadow(0 2px 4px rgba(0,0,0,.18))}.rating__stars--disabled{opacity:.5;pointer-events:none}.rating__stars--disabled .rating__stop--filled{stop-color:#bdbdbd}.rating--enlarge .rating__star,.rating--enlarge .rating__star-svg{width:56px;height:56px}.rating--error .rating__stop--filled{stop-color:var(--m-error)}\n"], dependencies: [{ kind: "component", type: LabelComponent, selector: "m-label", inputs: ["for", "placeholder", "params", "required", "disabled", "color"] }, { kind: "component", type: TextOutputComponent, selector: "m-text-output", inputs: ["config", "align", "variant", "color", "label", "noTranslate", "params"], outputs: ["configChange", "clicked"] }, { kind: "pipe", type: TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
21772
21808
  }
21773
21809
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: RatingInputComponent, decorators: [{
21774
21810
  type: Component,
21775
- args: [{ selector: 'm-rating-input', imports: [LabelComponent, TextOutputComponent, TranslatePipe], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (config(); as rating) {\n @if (rating.label) {\n <m-label\n [for]=\"rating.name ?? ''\"\n [placeholder]=\"rating.label\"\n [params]=\"rating.params\"\n [required]=\"required()\"\n [disabled]=\"disabled()\"\n />\n }\n\n <div\n class=\"rating\"\n [class.rating--error]=\"showErrors()\"\n [class.rating--enlarge]=\"enlarged()\"\n [style.--rating-color-filled]=\"filledColor()\"\n >\n <div\n class=\"rating__stars\"\n [class.rating__stars--interactive]=\"interactive()\"\n [class.rating__stars--disabled]=\"disabled()\"\n (mouseleave)=\"onLeave()\"\n >\n <!-- Hidden SVG for per-star gradient defs -->\n <svg width=\"0\" height=\"0\" aria-hidden=\"true\" class=\"rating__defs\">\n <defs>\n @for (star of stars; track star) {\n <linearGradient [id]=\"'star-grad-' + star\" x1=\"0%\" y1=\"0%\" x2=\"100%\" y2=\"0%\">\n <stop [attr.offset]=\"starFill(star) + '%'\" class=\"rating__stop--filled\" />\n <stop [attr.offset]=\"starFill(star) + '%'\" class=\"rating__stop--empty\" />\n </linearGradient>\n }\n </defs>\n </svg>\n\n @for (star of stars; track star) {\n <button\n class=\"rating__star\"\n type=\"button\"\n [attr.aria-label]=\"'rate-star-out-of-5' | translate: { star: star.toString() }\"\n [attr.aria-pressed]=\"(value() ?? 0) >= star\"\n [attr.disabled]=\"(!interactive()) ? true : null\"\n (click)=\"rate(star)\"\n (mouseenter)=\"onHover(star)\"\n >\n <svg\n class=\"rating__star-svg\"\n viewBox=\"0 0 24 24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n aria-hidden=\"true\"\n >\n <polygon\n class=\"rating__star-shape\"\n [attr.fill]=\"'url(#star-grad-' + star + ')'\"\n points=\"12,2.5 15.27,9.14 22.6,10.13 17.3,15.26 18.54,22.56 12,19.13 5.46,22.56 6.7,15.26 1.4,10.13 8.73,9.14\"\n />\n </svg>\n </button>\n }\n </div>\n </div>\n\n @if (showErrors()) {\n @for (error of errors(); track $index) {\n <m-text-output\n variant=\"footer\"\n color=\"error\"\n [label]=\"error.message\"\n />\n }\n }\n}\n", styles: ["@keyframes toggle-pulse{0%,to{transform:scale(1)}50%{transform:scale(1.02)}}@keyframes thumb-slide{0%{transform:translate(0) scale(1)}50%{transform:translate(.3em) scale(.9)}to{transform:translate(.6em) scale(1)}}.rating{display:inline-flex;flex-direction:column;gap:6px}.rating__defs{display:block;width:0;height:0;overflow:hidden;pointer-events:none;flex-shrink:0}.rating__stop--filled{stop-color:var(--rating-color-filled, #FFB800);stop-opacity:1}.rating__stop--empty{stop-color:#e0e0e0;stop-opacity:1}.rating__stars{position:relative;display:inline-flex;align-items:center;gap:4px}.rating__star{display:inline-flex;align-items:center;justify-content:center;width:28px;height:28px;padding:0;background:none;border:none;cursor:default;outline:none;flex-shrink:0}.rating__star-svg{width:28px;height:28px;display:block;filter:drop-shadow(0 1px 1px rgba(0,0,0,.08));transition:opacity .15s ease,transform .12s ease}.rating__star-shape{stroke:#0000000f;stroke-width:.5px}.rating__stars--interactive .rating__star{cursor:pointer;border-radius:4px}.rating__stars--interactive .rating__star:focus-visible{outline:2px solid var(--m-mm);outline-offset:2px;border-radius:4px}.rating__stars--interactive .rating__star:hover .rating__star-svg,.rating__stars--interactive .rating__star:focus-visible .rating__star-svg{transform:scale(1.15);filter:drop-shadow(0 2px 4px rgba(0,0,0,.18))}.rating__stars--disabled{opacity:.5;pointer-events:none}.rating__stars--disabled .rating__stop--filled{stop-color:#bdbdbd}.rating--enlarge .rating__star,.rating--enlarge .rating__star-svg{width:56px;height:56px}.rating--error .rating__stop--filled{stop-color:var(--m-error)}\n"] }]
21811
+ args: [{ selector: 'm-rating-input', imports: [LabelComponent, TextOutputComponent, TranslatePipe], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (config(); as rating) {\n @if (rating.label) {\n <m-label\n [for]=\"rating.name ?? ''\"\n [placeholder]=\"rating.label\"\n [params]=\"rating.params\"\n [required]=\"required()\"\n [disabled]=\"disabled()\"\n />\n }\n\n <div\n class=\"rating\"\n [class.rating--error]=\"showErrors()\"\n [class.rating--enlarge]=\"enlarged()\"\n [style.--rating-color-filled]=\"filledColor()\"\n >\n <div\n class=\"rating__stars\"\n [class.rating__stars--interactive]=\"interactive()\"\n [class.rating__stars--disabled]=\"disabled()\"\n (mouseleave)=\"onLeave()\"\n >\n <!-- Hidden SVG for per-star gradient defs -->\n <svg width=\"0\" height=\"0\" aria-hidden=\"true\" class=\"rating__defs\">\n <defs>\n @for (star of stars; track star) {\n <linearGradient [id]=\"'star-grad-' + star\" x1=\"0%\" y1=\"0%\" x2=\"100%\" y2=\"0%\">\n <stop [attr.offset]=\"starFill(star) + '%'\" class=\"rating__stop--filled\" />\n <stop [attr.offset]=\"starFill(star) + '%'\" class=\"rating__stop--empty\" />\n </linearGradient>\n }\n </defs>\n </svg>\n\n @for (star of stars; track star) {\n <button\n class=\"rating__star\"\n type=\"button\"\n [attr.aria-label]=\"'rate-star-out-of-5' | translate: { star: (star + 1).toString() }\"\n [attr.aria-pressed]=\"(ratingValue() ?? -1) >= star\"\n [attr.disabled]=\"(!interactive()) ? true : null\"\n (click)=\"rate(star)\"\n (mouseenter)=\"onHover(star)\"\n >\n <svg\n class=\"rating__star-svg\"\n viewBox=\"0 0 24 24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n aria-hidden=\"true\"\n >\n <polygon\n class=\"rating__star-shape\"\n [attr.fill]=\"'url(#star-grad-' + star + ')'\"\n points=\"12,2.5 15.27,9.14 22.6,10.13 17.3,15.26 18.54,22.56 12,19.13 5.46,22.56 6.7,15.26 1.4,10.13 8.73,9.14\"\n />\n </svg>\n </button>\n }\n </div>\n </div>\n\n @if (showErrors()) {\n @for (error of errors(); track $index) {\n <m-text-output\n variant=\"footer\"\n color=\"error\"\n [label]=\"error.message\"\n />\n }\n }\n}\n", styles: ["@keyframes toggle-pulse{0%,to{transform:scale(1)}50%{transform:scale(1.02)}}@keyframes thumb-slide{0%{transform:translate(0) scale(1)}50%{transform:translate(.3em) scale(.9)}to{transform:translate(.6em) scale(1)}}.rating{display:inline-flex;flex-direction:column;gap:6px}.rating__defs{display:block;width:0;height:0;overflow:hidden;pointer-events:none;flex-shrink:0}.rating__stop--filled{stop-color:var(--rating-color-filled, #FFB800);stop-opacity:1}.rating__stop--empty{stop-color:#e0e0e0;stop-opacity:1}.rating__stars{position:relative;display:inline-flex;align-items:center;gap:4px}.rating__star{display:inline-flex;align-items:center;justify-content:center;width:28px;height:28px;padding:0;background:none;border:none;cursor:default;outline:none;flex-shrink:0}.rating__star-svg{width:28px;height:28px;display:block;filter:drop-shadow(0 1px 1px rgba(0,0,0,.08));transition:opacity .15s ease,transform .12s ease}.rating__star-shape{stroke:#0000000f;stroke-width:.5px}.rating__stars--interactive .rating__star{cursor:pointer;border-radius:4px}.rating__stars--interactive .rating__star:focus-visible{outline:2px solid var(--m-mm);outline-offset:2px;border-radius:4px}.rating__stars--interactive .rating__star:hover .rating__star-svg,.rating__stars--interactive .rating__star:focus-visible .rating__star-svg{transform:scale(1.15);filter:drop-shadow(0 2px 4px rgba(0,0,0,.18))}.rating__stars--disabled{opacity:.5;pointer-events:none}.rating__stars--disabled .rating__stop--filled{stop-color:#bdbdbd}.rating--enlarge .rating__star,.rating--enlarge .rating__star-svg{width:56px;height:56px}.rating--error .rating__stop--filled{stop-color:var(--m-error)}\n"] }]
21776
21812
  }], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], config: [{ type: i0.Input, args: [{ isSignal: true, alias: "config", required: false }] }], required: [{ type: i0.Input, args: [{ isSignal: true, alias: "required", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], invalid: [{ type: i0.Input, args: [{ isSignal: true, alias: "invalid", required: false }] }], touched: [{ type: i0.Input, args: [{ isSignal: true, alias: "touched", required: false }] }, { type: i0.Output, args: ["touchedChange"] }], focused: [{ type: i0.Input, args: [{ isSignal: true, alias: "focused", required: false }] }], errors: [{ type: i0.Input, args: [{ isSignal: true, alias: "errors", required: false }] }] } });
21777
21813
 
21778
21814
  var ratingInput = /*#__PURE__*/Object.freeze({
@@ -35374,4 +35410,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
35374
35410
  */
35375
35411
 
35376
35412
  export { DEFAULT_FILTER_VARIANT as $, ACCESS_DOMAINS as A, BaseInputComponent as B, COMPONENT_INPUT_REGISTRY as C, CardComponent as D, CardWrapperComponent as E, CarouselComponent as F, ChartComponent as G, ChatBubbleComponent as H, IS_DESIGN_MODE as I, CheckboxInputComponent as J, ClearableInputComponent as K, LabelComponent as L, ColComponent as M, ColorPickerInputComponent as N, CommentItemComponent as O, CommentsApiService as P, CommentsComponent as Q, CommentsStore as R, ComponentInputComponent as S, TranslatePipe as T, ComponentStepperComponent as U, ConfigComponent as V, ConfirmComponent as W, ContextMenuComponent as X, CustomIconClass as Y, CustomIconEditComponent as Z, DEFAULT_FILTER_RANGE_MODE as _, BaseTextInputComponent as a, MultiRangeInputComponent as a$, DEFAULT_NAV_PARAM as a0, DEFAULT_NAV_SEGMENT as a1, DEFAULT_SIZE as a2, DashboardCardComponent as a3, DateInputComponent as a4, DatePickerComponent as a5, DeviceService as a6, DomService as a7, Domain as a8, DotGridComponent as a9, ImgComponent as aA, InputType as aB, InstrumentScoreComponent as aC, InterceptorObservables as aD, JumbotronComponent as aE, KeyValueComponent as aF, LAYOUT_ASSET_FOLDER as aG, LOGIN_COMPONENT as aH, LOGIN_STORE as aI, LanguageComponent as aJ, ListComponent as aK, LogoComponent as aL, MAG_SOCKET_EVENT as aM, MHeroColorDirective as aN, MHeroComponent as aO, MODAL_REF as aP, MODAL_STORE_REF as aQ, MRefDirective as aR, MStepComponent as aS, MURL_PARAM as aT, MURL_SEP as aU, ManifestEnrichmentService as aV, MenuComponent as aW, ModalDirective as aX, ModalRef as aY, ModalStore as aZ, MoneyPipe as a_, DragListDirective as aa, DragListItemDirective as ab, DraggableDirective as ac, DropdownInputComponent as ad, FILTER_GROUP_CONTEXT as ae, FILTER_RANGE_MODES as af, FILTER_VARIANTS as ag, FLEX_VARIANTS as ah, FOLDER_PICK_LISTENER as ai, FORM_ASSET_FOLDER as aj, FileService as ak, FileUploadDirective as al, FileUploadInputComponent as am, FlexComponent as an, FlexItemComponent as ao, FormGroupComponent as ap, FrameComponent as aq, FreezeService as ar, GRID_BREAKPOINTS as as, GetNavService as at, HeaderComponent$1 as au, HighlightDirective as av, HttpService as aw, ICON_SOURCE as ax, IS_SIDE_PANEL as ay, IconComponent as az, TextOutputComponent as b, SectionAccordionDirective as b$, MurlUrlSerializer as b0, NAV_DEFAULT_MURL as b1, NAV_ID_SEP as b2, NAV_MAIN_BUTTONS as b3, NAV_SEGMENT_RE as b4, NAV_STORE_REF as b5, NAV_WC_COMPONENTS as b6, NAV_WIDGET_MAP as b7, NavComponent as b8, NavDetailsComponent as b9, PercentagePipe as bA, PlaygroundComponent as bB, PositionDirective as bC, PwaInstallComponent as bD, ROOT_NAV$1 as bE, RadioGroupComponent as bF, RadioInputComponent as bG, RangeInputComponent as bH, RatingInputComponent as bI, ReactiveElementComponent as bJ, RemoteComponent as bK, RemoteLoaderService as bL, ResizeElementComponent as bM, RouteContainer as bN, RowComponent as bO, SEARCH_QUERY as bP, SEARCH_RESULTS_EVENT as bQ, SECTION_ACCORDION_GROUP as bR, SECTION_FORM_CONTEXT as bS, SHARED_ICONS as bT, SIZE_CONTEXT as bU, ScoreComponent as bV, ScrollComponent as bW, ScrollService as bX, SearchPanelComponent as bY, SearchStore as bZ, SearchUserPanelComponent as b_, NavHeaderComponent as ba, NavMenuComponent as bb, NavStore as bc, NavTrailComponent as bd, NothingComponent as be, NotificationElementComponent as bf, NotificationGroupComponent as bg, NotificationPopupComponent as bh, NotificationService as bi, NotificationStore as bj, NotificationType as bk, NotificationWidgetComponent as bl, ONE_ASSET_BASE_URL as bm, OPTIONS_SOURCE as bn, OVERLAY_WIDGETS as bo, OneApp as bp, OptionsSourceDirective as bq, OverlayBodyComponent as br, OverlayRef as bs, OverlayService as bt, PLATFORM_BUTTON_NAV_IDS as bu, PLATFORM_EXTENSIBLE_NAV_IDS as bv, PLATFORM_NAV_MAP as bw, PLATFORM_ROOT_CHILDREN as bx, PaginationComponent as by, PanelComponent as bz, ButtonComponent as c, URL_SEP as c$, SectionAccordionGroupDirective as c0, SectionBackComponent as c1, SectionBadgesComponent as c2, SectionButtonGroupComponent as c3, SectionCardComponent as c4, SectionCarouselComponent as c5, SectionComponent as c6, SectionFilterComponent as c7, SectionFilterGroupComponent as c8, SectionFilterMenuComponent as c9, StepsComponent as cA, StorageService as cB, StrokeLinecap as cC, StrokeLinejoin as cD, SummaryComponent as cE, SvgGeneratorComponent as cF, SvgGeneratorService as cG, SvgService as cH, TOTAL_COLUMNS as cI, TRANSLATION_SOURCE as cJ, TableComponent as cK, TechnicalMeterComponent as cL, TextInputComponent as cM, TextareaInputComponent as cN, ThemeComponent as cO, ThemeDataService as cP, ThemeService as cQ, ThemeStore as cR, TimeAgoPipe as cS, TimelineComponent as cT, ToggleButtonComponent as cU, ToggleInputComponent as cV, ToggleRadioInputComponent as cW, ToolTipDirective as cX, TooltipComponent as cY, TranslateService as cZ, TreeGridComponent as c_, SectionFilterPanelComponent as ca, SectionFilterRangePanelComponent as cb, SectionFooterComponent as cc, SectionFormComponent as cd, SectionFormItemComponent as ce, SectionHeaderComponent as cf, SectionHeroComponent as cg, SectionPaginationComponent as ch, SectionSearchComponent as ci, SectionStepperComponent as cj, SectionTabsComponent as ck, SectionToggleComponent as cl, SectionToggleItemDirective as cm, SelectableCardInputComponent as cn, SelectorDirective as co, SettingsSearchBarComponent as cp, SettingsSearchService as cq, ShapeComponent as cr, SharedStoreRegistry as cs, SidePanelDirective as ct, Size as cu, SocketStore as cv, SortComponent as cw, StatComponent as cx, StepComponent as cy, StepperComponent as cz, APP_CONTEXT_REF as d, getTierFromPreviewPath as d$, USER_STORE_REF as d0, USER_TAB_MAP as d1, UniverseComponent as d2, UserApiService as d3, UserAvatarComponent as d4, UserComponent as d5, UserNavComponent as d6, UserSettingsComponent as d7, UserStore as d8, WC_ROUTE_CHANGED_EVENT as d9, deriveOppositeColor as dA, derivePropertyName as dB, emailValidation as dC, evaluate as dD, evaluateBool as dE, filterHoldsList as dF, filterHoldsOneBound as dG, filterHoldsOptions as dH, filterHoldsRange as dI, filterList as dJ, filterNumber as dK, filterNumberList as dL, filterOne as dM, filterPanelOf as dN, filterPanelWidth as dO, filterRange as dP, filterTreeGridRows as dQ, filterValueList as dR, filterValues as dS, flattenTreeGridRows as dT, formatBadgeCount as dU, fullName as dV, generateClipPath as dW, generateTransform as dX, getClassList as dY, getProperty as dZ, getScrollParent as d_, WC_SEARCH_GROUPS as da, WIN_USER_TAB_HOOK as db, WIN_USER_TAB_KEY as dc, WatermarkComponent as dd, WcRouterStore as de, WrapperInputComponent as df, anchorNavId as dg, applyColorsToElement as dh, assetOptions as di, bootstrapMagApp as dj, bootstrapPwaInstall as dk, buildWcBaseUrl as dl, calculateLuminance as dm, calculateRanks as dn, cellText as dp, checkFilterCondition as dq, childNavId as dr, classListSignal as ds, coerceSize as dt, cornerEdge as du, cornerSide as dv, createMap as dw, createPlatformNavMap as dx, deriveAvatarGradient as dy, deriveContrastColor as dz, ASSET_BASE_URL as e, provideAppContext as e$, getTreeGridRow as e0, getUniqueId as e1, getValue as e2, hasErrorComputed as e3, hexToRgb as e4, hslToRgb$1 as e5, initMagmoniumApp as e6, initialNotificationState as e7, initialState$2 as e8, initials as e9, maxLengthValidation as eA, maxValidation as eB, mergePlatformNav as eC, mergeUnique as eD, mergeUniqueBy as eE, mergeUniqueWith as eF, minAgeValidation as eG, minLengthValidation as eH, minValidation as eI, miniMarkToHtml as eJ, navIdChain as eK, navIdFor as eL, navIdSegment as eM, navIdToRoutePath as eN, navIdToSegments as eO, navParamOf as eP, navToId as eQ, normalizeAssetOptions as eR, parentNavId as eS, parseAddress as eT, parseColor as eU, parsePatternNames as eV, patternValidation as eW, patternsValidation as eX, platformNavWidgets as eY, privateGuard as eZ, processImageToSvg as e_, injectAuthenticate as ea, injectInstallApp as eb, injectParentSize as ec, injectScrollSticky as ed, isButtonName as ee, isCancelledComputed as ef, isExtensiblePlatformNavId as eg, isJson as eh, isLoadingComputed as ei, isLocalhost as ej, isNavInstanceConfig as ek, isNavMenuConfig as el, isNavRowsConfig as em, isPlatformNavId as en, isSize as eo, isTierPreview as ep, isUrlLocalhost as eq, isValidNavId as er, isValidNavSegment as es, isWebComponent as et, linkToId as eu, linkToNav as ev, loadingActions as ew, mInterceptor as ex, manualValidation as ey, matchFieldValidation as ez, AccordionBodyDirective as f, provideMagAppConfig as f0, provideMagWcConfig as f1, provideMagWcRoutes as f2, provideModalComponents as f3, provideMurlUrlSerializer as f4, provideNavWidgets as f5, provideOverlayWidgets as f6, providePlatformNavWidgets as f7, provideSearch as f8, provideSizeContext as f9, toLength$1 as fA, toLocalNavId as fB, toggleTreeGridRow as fC, unfetchedPlatformNav as fD, urlValidation as fE, provideUserTabs as fa, publicGuard as fb, readFieldPatterns as fc, renderAddress as fd, requiredValidation as fe, resolveConfigAsset as ff, resolveIconSize as fg, resolvePallet as fh, resolvePatternRules as fi, resolveSize as fj, rgbToHex as fk, rgbToHsl as fl, rowHasChildren as fm, samePatterns as fn, segmentsToNavId as fo, setProperty as fp, setTreeGridChildren as fq, settingsWidgets as fr, shouldShowBadge as fs, splitNavId as ft, splitOnMatch as fu, stringToColor as fv, toAttrBool as fw, toAttrNumber as fx, toCssLength as fy, toHostNavId as fz, AccordionComponent as g, AccordionGroupComponent as h, ActionComponent as i, AnimatedGraphsComponent as j, AppCardComponent as k, AppRelationType as l, AppTileComponent as m, AssetStore as n, AssetUrlPipe as o, Assets as p, AuthActivityPageComponent as q, AuthApiService as r, AuthStore as s, AutosizeDirective as t, BadgeComponent as u, BandingComponent as v, BaseArrayInputComponent as w, BaseRootWebComponent as x, BaseWebComponent as y, ButtonGroupComponent as z };
35377
- //# sourceMappingURL=magmonium-one-magmonium-one-CUE3qDYz.mjs.map
35413
+ //# sourceMappingURL=magmonium-one-magmonium-one-C2uyw8As.mjs.map