@maggioli-design-system/mds-input-range 2.0.1 → 2.1.1

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 (91) hide show
  1. package/dist/cjs/{index-f984e289.js → index-27635fed.js} +171 -73
  2. package/dist/cjs/loader.cjs.js +2 -2
  3. package/dist/cjs/mds-input-range.cjs.entry.js +30 -8
  4. package/dist/cjs/mds-input-range.cjs.js +3 -3
  5. package/dist/collection/collection-manifest.json +1 -1
  6. package/dist/collection/common/floating-controller.js +180 -0
  7. package/dist/collection/common/slot.js +19 -0
  8. package/dist/collection/components/mds-input-range/mds-input-range.css +22 -2
  9. package/dist/collection/components/mds-input-range/mds-input-range.js +57 -6
  10. package/dist/collection/components/mds-input-range/test/mds-input-range.stories.js +8 -0
  11. package/dist/collection/dictionary/animation.js +5 -0
  12. package/dist/collection/dictionary/file-extensions.js +6 -59
  13. package/dist/collection/dictionary/tree.js +13 -0
  14. package/dist/collection/fixtures/filenames.js +62 -1
  15. package/dist/collection/type/animation.js +1 -0
  16. package/dist/collection/type/tree.js +1 -0
  17. package/dist/collection/type/variant-file-format.js +5 -0
  18. package/dist/components/mds-input-range.js +31 -7
  19. package/dist/documentation.d.ts +8 -0
  20. package/dist/documentation.json +40 -6
  21. package/dist/esm/{index-e0ac0a55.js → index-c0c11860.js} +171 -73
  22. package/dist/esm/loader.js +3 -3
  23. package/dist/esm/mds-input-range.entry.js +30 -8
  24. package/dist/esm/mds-input-range.js +4 -4
  25. package/dist/esm-es5/index-c0c11860.js +1 -0
  26. package/dist/esm-es5/loader.js +1 -1
  27. package/dist/esm-es5/mds-input-range.entry.js +1 -1
  28. package/dist/esm-es5/mds-input-range.js +1 -1
  29. package/dist/mds-input-range/mds-input-range.esm.js +1 -1
  30. package/dist/mds-input-range/mds-input-range.js +1 -1
  31. package/dist/mds-input-range/p-16118dde.system.entry.js +1 -0
  32. package/dist/mds-input-range/p-71d27af5.system.js +2 -0
  33. package/dist/mds-input-range/p-7a612415.system.js +1 -0
  34. package/dist/mds-input-range/p-8951c4d3.entry.js +1 -0
  35. package/dist/mds-input-range/p-dd7b28fc.js +2 -0
  36. package/dist/stats.json +120 -41
  37. package/dist/types/common/floating-controller.d.ts +46 -0
  38. package/dist/types/common/slot.d.ts +3 -0
  39. package/dist/types/components/mds-input-range/mds-input-range.d.ts +6 -0
  40. package/dist/types/components/mds-input-range/test/mds-input-range.stories.d.ts +7 -0
  41. package/dist/types/components.d.ts +8 -0
  42. package/dist/types/dictionary/animation.d.ts +2 -0
  43. package/dist/types/dictionary/tree.d.ts +4 -0
  44. package/dist/types/fixtures/filenames.d.ts +62 -1
  45. package/dist/types/type/animation.d.ts +1 -0
  46. package/dist/types/type/file-types.d.ts +1 -1
  47. package/dist/types/type/tree.d.ts +3 -0
  48. package/dist/types/type/variant-file-format.d.ts +1 -1
  49. package/documentation.json +81 -17
  50. package/package.json +4 -4
  51. package/readme.md +7 -6
  52. package/src/common/floating-controller.ts +263 -0
  53. package/src/common/slot.ts +24 -0
  54. package/src/components/mds-input-range/css/mds-input-range-disabled.css +9 -0
  55. package/src/components/mds-input-range/mds-input-range.css +12 -2
  56. package/src/components/mds-input-range/mds-input-range.tsx +23 -0
  57. package/src/components/mds-input-range/readme.md +7 -6
  58. package/src/components/mds-input-range/test/mds-input-range.stories.tsx +9 -0
  59. package/src/components.d.ts +8 -0
  60. package/src/dictionary/animation.ts +8 -0
  61. package/src/dictionary/file-extensions.ts +6 -60
  62. package/src/dictionary/tree.ts +21 -0
  63. package/src/fixtures/filenames.ts +63 -0
  64. package/src/fixtures/icons.json +21 -0
  65. package/src/fixtures/iconsauce.json +6 -0
  66. package/src/meta/file-format/locale.el.json +26 -21
  67. package/src/meta/file-format/locale.en.json +26 -21
  68. package/src/meta/file-format/locale.es.json +26 -21
  69. package/src/meta/file-format/locale.it.json +26 -21
  70. package/src/type/animation.ts +3 -0
  71. package/src/type/file-types.ts +6 -0
  72. package/src/type/tree.ts +12 -0
  73. package/src/type/variant-file-format.ts +6 -0
  74. package/www/build/mds-input-range.esm.js +1 -1
  75. package/www/build/mds-input-range.js +1 -1
  76. package/www/build/p-16118dde.system.entry.js +1 -0
  77. package/www/build/p-71d27af5.system.js +2 -0
  78. package/www/build/p-7a612415.system.js +1 -0
  79. package/www/build/p-8951c4d3.entry.js +1 -0
  80. package/www/build/p-dd7b28fc.js +2 -0
  81. package/dist/esm-es5/index-e0ac0a55.js +0 -1
  82. package/dist/mds-input-range/p-48fdc5db.system.entry.js +0 -1
  83. package/dist/mds-input-range/p-4e0b934e.system.js +0 -2
  84. package/dist/mds-input-range/p-76412b19.system.js +0 -1
  85. package/dist/mds-input-range/p-d697edb0.entry.js +0 -1
  86. package/dist/mds-input-range/p-f6cc8c2e.js +0 -2
  87. package/www/build/p-48fdc5db.system.entry.js +0 -1
  88. package/www/build/p-4e0b934e.system.js +0 -2
  89. package/www/build/p-76412b19.system.js +0 -1
  90. package/www/build/p-d697edb0.entry.js +0 -1
  91. package/www/build/p-f6cc8c2e.js +0 -2
@@ -21,19 +21,23 @@ function _interopNamespace(e) {
21
21
  }
22
22
 
23
23
  const NAMESPACE = 'mds-input-range';
24
- const BUILD = /* mds-input-range */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: false, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: false, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: false, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: false, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: true, hasRenderFn: true, hostListener: false, hostListenerTarget: false, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: false, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: true, hydratedClass: false, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, observeAttribute: true, profile: false, prop: true, propBoolean: false, propMutable: true, propNumber: true, propString: false, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: false, state: true, style: true, svg: false, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: false, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: false, watchCallback: true };
24
+ const BUILD = /* mds-input-range */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: false, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: false, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: false, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: false, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: true, hasRenderFn: true, hostListener: false, hostListenerTarget: false, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: false, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: true, hydratedClass: false, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, modernPropertyDecls: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: true, propNumber: true, propString: false, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: false, state: true, style: true, svg: false, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: false, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: false, watchCallback: true };
25
25
 
26
26
  /*
27
- Stencil Client Platform v4.22.2 | MIT Licensed | https://stenciljs.com
27
+ Stencil Client Platform v4.25.1 | MIT Licensed | https://stenciljs.com
28
28
  */
29
29
  var __defProp = Object.defineProperty;
30
30
  var __export = (target, all) => {
31
31
  for (var name in all)
32
32
  __defProp(target, name, { get: all[name], enumerable: true });
33
33
  };
34
+
35
+ // src/client/client-host-ref.ts
34
36
  var hostRefs = /* @__PURE__ */ new WeakMap();
35
37
  var getHostRef = (ref) => hostRefs.get(ref);
36
- var registerInstance = (lazyInstance, hostRef) => hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
38
+ var registerInstance = (lazyInstance, hostRef) => {
39
+ hostRefs.set(hostRef.$lazyInstance$ = lazyInstance, hostRef);
40
+ };
37
41
  var registerHost = (hostElement, cmpMeta) => {
38
42
  const hostRef = {
39
43
  $flags$: 0,
@@ -46,7 +50,8 @@ var registerHost = (hostElement, cmpMeta) => {
46
50
  hostElement["s-p"] = [];
47
51
  hostElement["s-rc"] = [];
48
52
  }
49
- return hostRefs.set(hostElement, hostRef);
53
+ const ref = hostRefs.set(hostElement, hostRef);
54
+ return ref;
50
55
  };
51
56
  var isMemberInElement = (elm, memberName) => memberName in elm;
52
57
  var consoleError = (e, el) => (0, console.error)(e, el);
@@ -83,16 +88,22 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
83
88
  /* webpackExclude: /\.system\.entry\.js$/ */
84
89
  /* webpackMode: "lazy" */
85
90
  `./${bundleId}.entry.js${""}`
86
- )); }).then((importedModule) => {
87
- {
88
- cmpModules.set(bundleId, importedModule);
91
+ )); }).then(
92
+ (importedModule) => {
93
+ {
94
+ cmpModules.set(bundleId, importedModule);
95
+ }
96
+ return importedModule[exportName];
97
+ },
98
+ (e) => {
99
+ consoleError(e, hostRef.$hostElement$);
89
100
  }
90
- return importedModule[exportName];
91
- }, consoleError);
101
+ );
92
102
  };
93
103
 
94
104
  // src/client/client-style.ts
95
105
  var styles = /* @__PURE__ */ new Map();
106
+ var HYDRATED_STYLE_ID = "sty-id";
96
107
  var HYDRATED_CSS = "{visibility:hidden}[hydrated]{visibility:inherit}";
97
108
  var SLOT_FB_CSS = "slot-fb{display:contents}slot-fb[hidden]{display:none}";
98
109
  var FORM_ASSOCIATED_CUSTOM_ELEMENT_CALLBACKS = [
@@ -156,12 +167,6 @@ var flush = () => {
156
167
  };
157
168
  var nextTick = (cb) => promiseResolve().then(cb);
158
169
  var writeTask = /* @__PURE__ */ queueTask(queueDomWrites, true);
159
-
160
- // src/utils/constants.ts
161
- var EMPTY_OBJ = {};
162
-
163
- // src/utils/helpers.ts
164
- var isDef = (v) => v != null;
165
170
  var isComplexType = (o) => {
166
171
  o = typeof o;
167
172
  return o === "object" || o === "function";
@@ -301,6 +306,9 @@ var Host = {};
301
306
  var isHost = (node) => node && node.$tag$ === Host;
302
307
  var parsePropertyValue = (propValue, propType) => {
303
308
  if (propValue != null && !isComplexType(propValue)) {
309
+ if (propType & 4 /* Boolean */) {
310
+ return propValue === "false" ? false : propValue === "" || !!propValue;
311
+ }
304
312
  if (propType & 2 /* Number */) {
305
313
  return parseFloat(propValue);
306
314
  }
@@ -359,7 +367,7 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
359
367
  }
360
368
  if (!appliedStyles.has(scopeId2)) {
361
369
  {
362
- styleElm = doc.createElement("style");
370
+ styleElm = document.querySelector(`[${HYDRATED_STYLE_ID}="${scopeId2}"]`) || doc.createElement("style");
363
371
  styleElm.innerHTML = style;
364
372
  const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(doc);
365
373
  if (nonce != null) {
@@ -369,7 +377,10 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
369
377
  if (styleContainerNode.nodeName === "HEAD") {
370
378
  const preconnectLinks = styleContainerNode.querySelectorAll("link[rel=preconnect]");
371
379
  const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector("style");
372
- styleContainerNode.insertBefore(styleElm, referenceNode2);
380
+ styleContainerNode.insertBefore(
381
+ styleElm,
382
+ (referenceNode2 == null ? void 0 : referenceNode2.parentNode) === styleContainerNode ? referenceNode2 : null
383
+ );
373
384
  } else if ("host" in styleContainerNode) {
374
385
  if (supportsConstructableStylesheets) {
375
386
  const stylesheet = new CSSStyleSheet();
@@ -419,16 +430,18 @@ var attachStyles = (hostRef) => {
419
430
  endAttachStyles();
420
431
  };
421
432
  var getScopeId = (cmp, mode) => "sc-" + (cmp.$tagName$);
422
- var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
433
+ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRender) => {
423
434
  if (oldValue !== newValue) {
424
435
  let isProp = isMemberInElement(elm, memberName);
425
436
  let ln = memberName.toLowerCase();
426
437
  if (memberName === "class") {
427
438
  const classList = elm.classList;
428
439
  const oldClasses = parseClassList(oldValue);
429
- const newClasses = parseClassList(newValue);
430
- classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
431
- classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
440
+ let newClasses = parseClassList(newValue);
441
+ {
442
+ classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
443
+ classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
444
+ }
432
445
  } else if (memberName === "style") {
433
446
  {
434
447
  for (const prop in oldValue) {
@@ -483,7 +496,7 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
483
496
  elm.setAttribute(memberName, n);
484
497
  }
485
498
  }
486
- } else {
499
+ } else if (elm[memberName] !== newValue) {
487
500
  elm[memberName] = newValue;
488
501
  }
489
502
  } catch (e) {
@@ -505,24 +518,44 @@ var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
505
518
  }
506
519
  };
507
520
  var parseClassListRegex = /\s/;
508
- var parseClassList = (value) => !value ? [] : value.split(parseClassListRegex);
521
+ var parseClassList = (value) => {
522
+ if (typeof value === "object" && value && "baseVal" in value) {
523
+ value = value.baseVal;
524
+ }
525
+ if (!value || typeof value !== "string") {
526
+ return [];
527
+ }
528
+ return value.split(parseClassListRegex);
529
+ };
509
530
  var CAPTURE_EVENT_SUFFIX = "Capture";
510
531
  var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
511
532
 
512
533
  // src/runtime/vdom/update-element.ts
513
- var updateElement = (oldVnode, newVnode, isSvgMode2) => {
534
+ var updateElement = (oldVnode, newVnode, isSvgMode2, isInitialRender) => {
514
535
  const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;
515
- const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || EMPTY_OBJ;
516
- const newVnodeAttrs = newVnode.$attrs$ || EMPTY_OBJ;
536
+ const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || {};
537
+ const newVnodeAttrs = newVnode.$attrs$ || {};
517
538
  {
518
539
  for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {
519
540
  if (!(memberName in newVnodeAttrs)) {
520
- setAccessor(elm, memberName, oldVnodeAttrs[memberName], void 0, isSvgMode2, newVnode.$flags$);
541
+ setAccessor(
542
+ elm,
543
+ memberName,
544
+ oldVnodeAttrs[memberName],
545
+ void 0,
546
+ isSvgMode2,
547
+ newVnode.$flags$);
521
548
  }
522
549
  }
523
550
  }
524
551
  for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {
525
- setAccessor(elm, memberName, oldVnodeAttrs[memberName], newVnodeAttrs[memberName], isSvgMode2, newVnode.$flags$);
552
+ setAccessor(
553
+ elm,
554
+ memberName,
555
+ oldVnodeAttrs[memberName],
556
+ newVnodeAttrs[memberName],
557
+ isSvgMode2,
558
+ newVnode.$flags$);
526
559
  }
527
560
  };
528
561
  function sortedAttrNames(attrNames) {
@@ -534,13 +567,10 @@ function sortedAttrNames(attrNames) {
534
567
  attrNames
535
568
  );
536
569
  }
537
-
538
- // src/runtime/vdom/vdom-render.ts
539
- var scopeId;
540
570
  var hostTagName;
541
571
  var useNativeShadowDom = false;
542
572
  var isSvgMode = false;
543
- var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
573
+ var createElm = (oldParentVNode, newParentVNode, childIndex) => {
544
574
  const newVNode2 = newParentVNode.$children$[childIndex];
545
575
  let i2 = 0;
546
576
  let elm;
@@ -554,11 +584,6 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
554
584
  {
555
585
  updateElement(null, newVNode2, isSvgMode);
556
586
  }
557
- const rootNode = elm.getRootNode();
558
- const isElementWithinShadowRoot = !rootNode.querySelector("body");
559
- if (!isElementWithinShadowRoot && BUILD.scoped && isDef(scopeId) && elm["s-si"] !== scopeId) {
560
- elm.classList.add(elm["s-si"] = scopeId);
561
- }
562
587
  if (newVNode2.$children$) {
563
588
  for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {
564
589
  childNode = createElm(oldParentVNode, newVNode2, i2);
@@ -687,6 +712,9 @@ var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
687
712
  if (!isInitialRender) {
688
713
  return leftVNode.$key$ === rightVNode.$key$;
689
714
  }
715
+ if (isInitialRender && !leftVNode.$key$ && rightVNode.$key$) {
716
+ leftVNode.$key$ = rightVNode.$key$;
717
+ }
690
718
  return true;
691
719
  }
692
720
  return false;
@@ -721,8 +749,9 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
721
749
  }
722
750
  };
723
751
  var insertBefore = (parent, newNode, reference) => {
724
- const inserted = parent == null ? void 0 : parent.insertBefore(newNode, reference);
725
- return inserted;
752
+ {
753
+ return parent == null ? void 0 : parent.insertBefore(newNode, reference);
754
+ }
726
755
  };
727
756
  var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
728
757
  const hostElm = hostRef.$hostElement$;
@@ -747,9 +776,6 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
747
776
  rootVnode.$flags$ |= 4 /* isHost */;
748
777
  hostRef.$vnode$ = rootVnode;
749
778
  rootVnode.$elm$ = oldVNode.$elm$ = hostElm.shadowRoot || hostElm ;
750
- {
751
- scopeId = hostElm["s-sc"];
752
- }
753
779
  useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) !== 0;
754
780
  patch(oldVNode, rootVnode, isInitialLoad);
755
781
  };
@@ -757,7 +783,14 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
757
783
  // src/runtime/update-component.ts
758
784
  var attachToAncestor = (hostRef, ancestorComponent) => {
759
785
  if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent["s-p"]) {
760
- ancestorComponent["s-p"].push(new Promise((r) => hostRef.$onRenderResolve$ = r));
786
+ const index = ancestorComponent["s-p"].push(
787
+ new Promise(
788
+ (r) => hostRef.$onRenderResolve$ = () => {
789
+ ancestorComponent["s-p"].splice(index - 1, 1);
790
+ r();
791
+ }
792
+ )
793
+ );
761
794
  }
762
795
  };
763
796
  var scheduleUpdate = (hostRef, isInitialLoad) => {
@@ -853,7 +886,7 @@ var postUpdateComponent = (hostRef) => {
853
886
  addHydratedFlag(elm);
854
887
  }
855
888
  {
856
- safeCall(instance, "componentDidLoad");
889
+ safeCall(instance, "componentDidLoad", void 0, elm);
857
890
  }
858
891
  endPostUpdate();
859
892
  {
@@ -882,12 +915,12 @@ var appDidLoad = (who) => {
882
915
  }
883
916
  nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
884
917
  };
885
- var safeCall = (instance, method, arg) => {
918
+ var safeCall = (instance, method, arg, elm) => {
886
919
  if (instance && instance[method]) {
887
920
  try {
888
921
  return instance[method](arg);
889
922
  } catch (e) {
890
- consoleError(e);
923
+ consoleError(e, elm);
891
924
  }
892
925
  }
893
926
  return void 0;
@@ -940,23 +973,23 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
940
973
  var _a, _b;
941
974
  const prototype = Cstr.prototype;
942
975
  if (cmpMeta.$flags$ & 64 /* formAssociated */ && flags & 1 /* isElementConstructor */) {
943
- FORM_ASSOCIATED_CUSTOM_ELEMENT_CALLBACKS.forEach(
944
- (cbName) => Object.defineProperty(prototype, cbName, {
976
+ FORM_ASSOCIATED_CUSTOM_ELEMENT_CALLBACKS.forEach((cbName) => {
977
+ Object.defineProperty(prototype, cbName, {
945
978
  value(...args) {
946
979
  const hostRef = getHostRef(this);
947
980
  const instance = hostRef.$lazyInstance$ ;
948
981
  if (!instance) {
949
- hostRef.$onReadyPromise$.then((instance2) => {
950
- const cb = instance2[cbName];
951
- typeof cb === "function" && cb.call(instance2, ...args);
982
+ hostRef.$onReadyPromise$.then((asyncInstance) => {
983
+ const cb = asyncInstance[cbName];
984
+ typeof cb === "function" && cb.call(asyncInstance, ...args);
952
985
  });
953
986
  } else {
954
- const cb = instance[cbName];
987
+ const cb = instance[cbName] ;
955
988
  typeof cb === "function" && cb.call(instance, ...args);
956
989
  }
957
990
  }
958
- })
959
- );
991
+ });
992
+ });
960
993
  }
961
994
  if (cmpMeta.$members$ || (cmpMeta.$watchers$ || Cstr.watchers)) {
962
995
  if (Cstr.watchers && !cmpMeta.$watchers$) {
@@ -965,15 +998,68 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
965
998
  const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
966
999
  members.map(([memberName, [memberFlags]]) => {
967
1000
  if ((memberFlags & 31 /* Prop */ || (flags & 2 /* proxyState */) && memberFlags & 32 /* State */)) {
1001
+ const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(prototype, memberName) || {};
1002
+ if (origGetter) cmpMeta.$members$[memberName][0] |= 2048 /* Getter */;
1003
+ if (origSetter) cmpMeta.$members$[memberName][0] |= 4096 /* Setter */;
1004
+ if (flags & 1 /* isElementConstructor */ || !origGetter) {
1005
+ Object.defineProperty(prototype, memberName, {
1006
+ get() {
1007
+ {
1008
+ if ((cmpMeta.$members$[memberName][0] & 2048 /* Getter */) === 0) {
1009
+ return getValue(this, memberName);
1010
+ }
1011
+ const ref = getHostRef(this);
1012
+ const instance = ref ? ref.$lazyInstance$ : prototype;
1013
+ if (!instance) return;
1014
+ return instance[memberName];
1015
+ }
1016
+ },
1017
+ configurable: true,
1018
+ enumerable: true
1019
+ });
1020
+ }
968
1021
  Object.defineProperty(prototype, memberName, {
969
- get() {
970
- return getValue(this, memberName);
971
- },
972
1022
  set(newValue) {
973
- setValue(this, memberName, newValue, cmpMeta);
974
- },
975
- configurable: true,
976
- enumerable: true
1023
+ const ref = getHostRef(this);
1024
+ if (origSetter) {
1025
+ const currentValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
1026
+ if (typeof currentValue === "undefined" && ref.$instanceValues$.get(memberName)) {
1027
+ newValue = ref.$instanceValues$.get(memberName);
1028
+ } else if (!ref.$instanceValues$.get(memberName) && currentValue) {
1029
+ ref.$instanceValues$.set(memberName, currentValue);
1030
+ }
1031
+ origSetter.apply(this, [parsePropertyValue(newValue, memberFlags)]);
1032
+ newValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
1033
+ setValue(this, memberName, newValue, cmpMeta);
1034
+ return;
1035
+ }
1036
+ {
1037
+ if ((flags & 1 /* isElementConstructor */) === 0 || (cmpMeta.$members$[memberName][0] & 4096 /* Setter */) === 0) {
1038
+ setValue(this, memberName, newValue, cmpMeta);
1039
+ if (flags & 1 /* isElementConstructor */ && !ref.$lazyInstance$) {
1040
+ ref.$onReadyPromise$.then(() => {
1041
+ if (cmpMeta.$members$[memberName][0] & 4096 /* Setter */ && ref.$lazyInstance$[memberName] !== ref.$instanceValues$.get(memberName)) {
1042
+ ref.$lazyInstance$[memberName] = newValue;
1043
+ }
1044
+ });
1045
+ }
1046
+ return;
1047
+ }
1048
+ const setterSetVal = () => {
1049
+ const currentValue = ref.$lazyInstance$[memberName];
1050
+ if (!ref.$instanceValues$.get(memberName) && currentValue) {
1051
+ ref.$instanceValues$.set(memberName, currentValue);
1052
+ }
1053
+ ref.$lazyInstance$[memberName] = parsePropertyValue(newValue, memberFlags);
1054
+ setValue(this, memberName, ref.$lazyInstance$[memberName], cmpMeta);
1055
+ };
1056
+ if (ref.$lazyInstance$) {
1057
+ setterSetVal();
1058
+ } else {
1059
+ ref.$onReadyPromise$.then(() => setterSetVal());
1060
+ }
1061
+ }
1062
+ }
977
1063
  });
978
1064
  }
979
1065
  });
@@ -983,7 +1069,7 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
983
1069
  plt.jmp(() => {
984
1070
  var _a2;
985
1071
  const propName = attrNameToPropName.get(attrName);
986
- if (this.hasOwnProperty(propName)) {
1072
+ if (this.hasOwnProperty(propName) && BUILD.lazyLoad) {
987
1073
  newValue = this[propName];
988
1074
  delete this[propName];
989
1075
  } else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" && // cast type to number to avoid TS compiler issues
@@ -1003,7 +1089,11 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
1003
1089
  }
1004
1090
  return;
1005
1091
  }
1006
- this[propName] = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
1092
+ const propDesc = Object.getOwnPropertyDescriptor(prototype, propName);
1093
+ newValue = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
1094
+ if (newValue !== this[propName] && (!propDesc.get || !!propDesc.set)) {
1095
+ this[propName] = newValue;
1096
+ }
1007
1097
  });
1008
1098
  };
1009
1099
  Cstr.observedAttributes = Array.from(
@@ -1030,9 +1120,8 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
1030
1120
  let Cstr;
1031
1121
  if ((hostRef.$flags$ & 32 /* hasInitializedComponent */) === 0) {
1032
1122
  hostRef.$flags$ |= 32 /* hasInitializedComponent */;
1033
- const bundleId = cmpMeta.$lazyBundleId$;
1034
- if (bundleId) {
1035
- const CstrImport = loadModule(cmpMeta);
1123
+ {
1124
+ const CstrImport = loadModule(cmpMeta, hostRef);
1036
1125
  if (CstrImport && "then" in CstrImport) {
1037
1126
  const endLoad = uniqueTime();
1038
1127
  Cstr = await CstrImport;
@@ -1057,7 +1146,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
1057
1146
  try {
1058
1147
  new Cstr(hostRef);
1059
1148
  } catch (e) {
1060
- consoleError(e);
1149
+ consoleError(e, elm);
1061
1150
  }
1062
1151
  {
1063
1152
  hostRef.$flags$ &= ~8 /* isConstructingInstance */;
@@ -1066,10 +1155,6 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
1066
1155
  hostRef.$flags$ |= 128 /* isWatchReady */;
1067
1156
  }
1068
1157
  endNewInstance();
1069
- } else {
1070
- Cstr = elm.constructor;
1071
- const cmpTag = elm.localName;
1072
- customElements.whenDefined(cmpTag).then(() => hostRef.$flags$ |= 128 /* isWatchReady */);
1073
1158
  }
1074
1159
  if (Cstr && Cstr.style) {
1075
1160
  let style;
@@ -1092,7 +1177,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
1092
1177
  schedule();
1093
1178
  }
1094
1179
  };
1095
- var fireConnectedCallback = (instance) => {
1180
+ var fireConnectedCallback = (instance, elm) => {
1096
1181
  };
1097
1182
 
1098
1183
  // src/runtime/connected-callback.ts
@@ -1132,7 +1217,7 @@ var connectedCallback = (elm) => {
1132
1217
  endConnected();
1133
1218
  }
1134
1219
  };
1135
- var disconnectInstance = (instance) => {
1220
+ var disconnectInstance = (instance, elm) => {
1136
1221
  };
1137
1222
  var disconnectedCallback = async (elm) => {
1138
1223
  if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
@@ -1141,6 +1226,12 @@ var disconnectedCallback = async (elm) => {
1141
1226
  hostRef.$onReadyPromise$.then(() => disconnectInstance());
1142
1227
  }
1143
1228
  }
1229
+ if (rootAppliedStyles.has(elm)) {
1230
+ rootAppliedStyles.delete(elm);
1231
+ }
1232
+ if (elm.shadowRoot && rootAppliedStyles.has(elm.shadowRoot)) {
1233
+ rootAppliedStyles.delete(elm.shadowRoot);
1234
+ }
1144
1235
  };
1145
1236
 
1146
1237
  // src/runtime/bootstrap-lazy.ts
@@ -1221,6 +1312,13 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
1221
1312
  }
1222
1313
  disconnectedCallback() {
1223
1314
  plt.jmp(() => disconnectedCallback(this));
1315
+ plt.raf(() => {
1316
+ var _a3;
1317
+ const hostRef = getHostRef(this);
1318
+ if (((_a3 = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a3.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {
1319
+ delete hostRef.$vnode$.$elm$;
1320
+ }
1321
+ });
1224
1322
  }
1225
1323
  componentOnReady() {
1226
1324
  return getHostRef(this).$onReadyPromise$;
@@ -2,13 +2,13 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const index = require('./index-f984e289.js');
5
+ const index = require('./index-27635fed.js');
6
6
  const appGlobals = require('./app-globals-3a1e7e63.js');
7
7
 
8
8
  const defineCustomElements = async (win, options) => {
9
9
  if (typeof window === 'undefined') return undefined;
10
10
  await appGlobals.globalScripts();
11
- return index.bootstrapLazy([["mds-input-range.cjs",[[65,"mds-input-range",{"max":[2],"min":[2],"step":[2],"value":[1538],"progress":[32]},null,{"value":["valueChanged"],"min":["minChanged"],"max":["maxChanged"],"step":["stepChanged"]}]]]], options);
11
+ return index.bootstrapLazy([["mds-input-range.cjs",[[65,"mds-input-range",{"max":[2],"min":[2],"step":[2],"disabled":[1540],"value":[1538],"progress":[32]},null,{"disabled":["disabledChanged"],"value":["valueChanged"],"min":["minChanged"],"max":["maxChanged"],"step":["stepChanged"]}]]]], options);
12
12
  };
13
13
 
14
14
  exports.setNonce = index.setNonce;
@@ -2,9 +2,9 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const index = require('./index-f984e289.js');
5
+ const index = require('./index-27635fed.js');
6
6
 
7
- const mdsInputRangeCss = "@-webkit-keyframes focus-bounce {\n 0%, 75%, 100% {\n outline-offset: var(--magma-outline-focus-offset, 6px);\n }\n\n 50% {\n outline-offset: var(--magma-outline-blur-offset, 2px);\n }\n}\n\n@keyframes focus-bounce {\n 0%, 75%, 100% {\n outline-offset: var(--magma-outline-focus-offset, 6px);\n }\n\n 50% {\n outline-offset: var(--magma-outline-blur-offset, 2px);\n }\n}\n\n@tailwind components;\n@tailwind utilities;\n\n/**\n * @prop --mds-input-range-thumb-size: Sets the thumb width and height of the component\n * @prop --mds-input-range-thumb-background:\n * @prop --mds-input-range-track-background:\n * @prop --mds-input-range-track-size:\n * @prop --mds-input-range-track-progress-background:\n */\n\n:host {\n\n --mds-input-range-thumb-size: 1rem;\n --mds-input-range-thumb-background: rgb(var(--variant-primary-04));\n --mds-input-range-thumb-shadow: 0 0 0 2px rgb(var(--tone-neutral));\n --mds-input-range-track-background: rgb(var(--tone-neutral-09));\n --mds-input-range-track-size: 0.5rem;\n --mds-input-range-track-progress-background: rgb(var(--variant-primary-03));\n gap: 0.25rem;\n -webkit-transition-duration: 200ms;\n transition-duration: 200ms;\n\n display: grid;\n -webkit-transition-property: color;\n transition-property: color;\n}\n\n.header {\n gap: 0.5rem;\n\n display: -ms-flexbox;\n\n display: flex;\n}\n\n.label {\n min-width: 0rem;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.value {\n margin-left: auto;\n}\n\n.range {\n -ms-flex-align: center;\n align-items: center;\n display: -ms-flexbox;\n display: flex;\n height: var(--mds-input-range-thumb-size);\n position: relative;\n}\n\n.track {\n width: 100%;\n\n --margin: calc(var(--mds-input-range-track-size) / 2);\n\n -webkit-box-sizing: border-box;\n\n box-sizing: border-box;\n padding: 0 var(--margin);\n position: absolute;\n}\n\n.field {\n -webkit-animation-duration: var(--magma-outline-animation-duration, 1s);\n animation-duration: var(--magma-outline-animation-duration, 1s);\n -webkit-animation-fill-mode: forwards;\n animation-fill-mode: forwards;\n -webkit-animation-iteration-count: infinite;\n animation-iteration-count: infinite;\n -webkit-animation-name: focus-bounce;\n animation-name: focus-bounce;\n -webkit-animation-play-state: paused;\n animation-play-state: paused;\n -webkit-animation-timing-function: cubic-bezier(0, 0, 0.2, 1);\n animation-timing-function: cubic-bezier(0, 0, 0.2, 1);\n outline: var(--magma-outline-blur);\n -webkit-transition-duration: 200ms;\n transition-duration: 200ms;\n -webkit-transition-property: background-color, border-color, color, fill, outline, outline-offset, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, outline, outline-offset, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, outline, outline-offset, transform;\n transition-property: background-color, border-color, box-shadow, color, fill, outline, outline-offset, transform, -webkit-box-shadow, -webkit-transform;\n -webkit-transition-timing-function: ease-in-out;\n transition-timing-function: ease-in-out;\n }\n\n.field:focus-visible {\n\n --magma-outline-blur: var(--magma-outline-focus);\n\n -webkit-animation-play-state: running;\n\n animation-play-state: running;\n }\n\n.field {\n z-index: 20;\n height: 1rem;\n\n -webkit-appearance: none;\n\n -moz-appearance: none;\n\n appearance: none;\n background-color: transparent;\n border-radius: 1000px;\n -ms-flex-positive: 1;\n flex-grow: 1;\n margin: 0;\n}\n\n.field:focus-visible {\n\n --magma-outline-blur: var(--magma-outline-focus);\n\n -webkit-animation-play-state: running;\n\n animation-play-state: running;\n }\n\n.field::-webkit-slider-thumb {\n -webkit-appearance: none;\n appearance: none;\n background-color: var(--mds-input-range-thumb-background);\n border: 0;\n border-radius: var(--mds-input-range-thumb-size);\n -webkit-box-shadow: var(--mds-input-range-thumb-shadow);\n box-shadow: var(--mds-input-range-thumb-shadow);\n cursor: -webkit-grab;\n cursor: grab;\n height: var(--mds-input-range-thumb-size);\n line-height: 0;\n -webkit-transform: translate(0, -50%);\n transform: translate(0, -50%);\n width: var(--mds-input-range-thumb-size);\n}\n\n.field::-webkit-slider-runnable-track {\n -webkit-appearance: none;\n appearance: none;\n border: 0;\n height: 0;\n width: 100%;\n}\n\n.track-progress {\n -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n\n background-color: var(--mds-input-range-track-progress-background);\n display: -ms-flexbox;\n display: flex;\n height: var(--mds-input-range-track-size);\n -webkit-transition-property: background-color;\n transition-property: background-color;\n}\n\n.track-total {\n -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n\n background-color: var(--mds-input-range-track-background);\n border-radius: var(--mds-input-range-track-size);\n display: -ms-flexbox;\n display: flex;\n height: var(--mds-input-range-track-size);\n overflow: hidden;\n -webkit-transition-property: background-color;\n transition-property: background-color;\n width: 100%;\n}\n\n.contrast-area {\n margin-left: 0.25rem;\n margin-right: 0.25rem;\n\n border-radius: var(--mds-input-range-track-size);\n}\n\n@tailwind utilities;\n\n@container style(--magma-pref-animation: reduce) {\n :host,\n .field::-webkit-slider-thumb,\n .field::-webkit-slider-runnable-track,\n .track-progress,\n .track-total {\n -webkit-transition-duration: 0s;\n transition-duration: 0s;\n }\n}\n\n@container style(--magma-pref-animation: system) {\n\n @media (prefers-reduced-motion) {\n :host,\n .field::-webkit-slider-thumb,\n .field::-webkit-slider-runnable-track,\n .track-progress,\n .track-total {\n -webkit-transition-duration: 0s;\n transition-duration: 0s;\n }\n }\n}\n\n@tailwind utilities;\n\n@container style(--magma-pref-theme: dark) {\n :host {\n\n --mds-input-range-thumb-background: rgb(var(--variant-primary-04));\n --mds-input-range-track-background: rgb(var(--tone-neutral-07));\n --mds-input-range-track-progress-background: rgb(var(--variant-primary-05));\n }\n}\n\n@container style(--magma-pref-theme: system) {\n\n @media (prefers-color-scheme: dark) {\n :host {\n\n --mds-input-range-thumb-background: rgb(var(--variant-primary-04));\n --mds-input-range-track-background: rgb(var(--tone-neutral-07));\n --mds-input-range-track-progress-background: rgb(var(--variant-primary-05));\n }\n }\n}\n\n@container style(--magma-pref-contrast: more) {\n :host {\n color: rgb(var(--tone-neutral-01));\n }\n}\n\n@container style(--magma-pref-contrast: system) {\n\n @media (prefers-contrast: more) {\n :host {\n color: rgb(var(--tone-neutral-01));\n }\n }\n}\n\n\n";
7
+ const mdsInputRangeCss = "@-webkit-keyframes focus-bounce {\n 0%, 75%, 100% {\n outline-offset: var(--magma-outline-focus-offset, 6px);\n }\n\n 50% {\n outline-offset: var(--magma-outline-blur-offset, 2px);\n }\n}\n\n@keyframes focus-bounce {\n 0%, 75%, 100% {\n outline-offset: var(--magma-outline-focus-offset, 6px);\n }\n\n 50% {\n outline-offset: var(--magma-outline-blur-offset, 2px);\n }\n}\n\n@tailwind components;\n@tailwind utilities;\n\n/**\n * @prop --mds-input-range-thumb-size: Sets the thumb width and height of the component\n * @prop --mds-input-range-thumb-background:\n * @prop --mds-input-range-track-background:\n * @prop --mds-input-range-track-size:\n * @prop --mds-input-range-track-progress-background:\n */\n\n:host {\n\n --mds-input-range-thumb-size: 1rem;\n --mds-input-range-thumb-background: rgb(var(--variant-primary-04));\n --mds-input-range-thumb-shadow: 0 0 0 2px rgb(var(--tone-neutral));\n --mds-input-range-track-background: rgb(var(--tone-neutral-08));\n --mds-input-range-track-size: 0.5rem;\n --mds-input-range-track-progress-background: rgb(var(--variant-primary-03));\n --mds-input-range-thumb-background-disabled: rgb(var(--tone-neutral-06));\n --mds-input-range-track-background-disabled: rgb(var(--tone-neutral-08));\n --mds-input-range-track-progress-background-disabled: rgb(var(--tone-neutral-06));\n gap: 0.25rem;\n -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n\n display: grid;\n -webkit-transition-property: color;\n transition-property: color;\n}\n\n.header {\n gap: 0.5rem;\n\n display: -ms-flexbox;\n\n display: flex;\n}\n\n.label {\n min-width: 0rem;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.value {\n margin-left: auto;\n}\n\n.range {\n -ms-flex-align: center;\n align-items: center;\n display: -ms-flexbox;\n display: flex;\n height: var(--mds-input-range-thumb-size);\n position: relative;\n}\n\n.track {\n width: 100%;\n\n --margin: calc(var(--mds-input-range-track-size) / 2);\n\n -webkit-box-sizing: border-box;\n\n box-sizing: border-box;\n padding: 0 var(--margin);\n position: absolute;\n}\n\n.field {\n -webkit-animation-duration: var(--magma-outline-animation-duration, 1s);\n animation-duration: var(--magma-outline-animation-duration, 1s);\n -webkit-animation-fill-mode: forwards;\n animation-fill-mode: forwards;\n -webkit-animation-iteration-count: infinite;\n animation-iteration-count: infinite;\n -webkit-animation-name: focus-bounce;\n animation-name: focus-bounce;\n -webkit-animation-play-state: paused;\n animation-play-state: paused;\n -webkit-animation-timing-function: cubic-bezier(0, 0, 0.2, 1);\n animation-timing-function: cubic-bezier(0, 0, 0.2, 1);\n outline: var(--magma-outline-blur);\n -webkit-transition-duration: 200ms;\n transition-duration: 200ms;\n -webkit-transition-property: background-color, border-color, color, fill, outline, outline-offset, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, outline, outline-offset, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, outline, outline-offset, transform;\n transition-property: background-color, border-color, box-shadow, color, fill, outline, outline-offset, transform, -webkit-box-shadow, -webkit-transform;\n -webkit-transition-timing-function: ease-in-out;\n transition-timing-function: ease-in-out;\n }\n\n.field:focus-visible {\n\n --magma-outline-blur: var(--magma-outline-focus);\n\n -webkit-animation-play-state: running;\n\n animation-play-state: running;\n }\n\n.field {\n z-index: 20;\n height: 1rem;\n\n -webkit-appearance: none;\n\n -moz-appearance: none;\n\n appearance: none;\n background-color: transparent;\n border-radius: 1000px;\n -ms-flex-positive: 1;\n flex-grow: 1;\n margin: 0;\n}\n\n.field:focus-visible {\n\n --magma-outline-blur: var(--magma-outline-focus);\n\n -webkit-animation-play-state: running;\n\n animation-play-state: running;\n }\n\n.field::-webkit-slider-thumb {\n -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n\n -webkit-appearance: none;\n\n appearance: none;\n background-color: var(--mds-input-range-thumb-background);\n border: 0;\n border-radius: var(--mds-input-range-thumb-size);\n -webkit-box-shadow: var(--mds-input-range-thumb-shadow);\n box-shadow: var(--mds-input-range-thumb-shadow);\n cursor: -webkit-grab;\n cursor: grab;\n height: var(--mds-input-range-thumb-size);\n line-height: 0;\n -webkit-transform: translate(0, -50%);\n transform: translate(0, -50%);\n -webkit-transition-property: background-color, box-shadow;\n -webkit-transition-property: background-color, -webkit-box-shadow;\n transition-property: background-color, -webkit-box-shadow;\n transition-property: background-color, box-shadow;\n transition-property: background-color, box-shadow, -webkit-box-shadow;\n width: var(--mds-input-range-thumb-size);\n}\n\n.field::-webkit-slider-runnable-track {\n -webkit-appearance: none;\n appearance: none;\n border: 0;\n height: 0;\n width: 100%;\n}\n\n.track-progress {\n -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n\n background-color: var(--mds-input-range-track-progress-background);\n display: -ms-flexbox;\n display: flex;\n height: var(--mds-input-range-track-size);\n -webkit-transition-property: background-color;\n transition-property: background-color;\n}\n\n.track-total {\n -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n\n background-color: var(--mds-input-range-track-background);\n border-radius: var(--mds-input-range-track-size);\n display: -ms-flexbox;\n display: flex;\n height: var(--mds-input-range-track-size);\n overflow: hidden;\n -webkit-transition-property: background-color;\n transition-property: background-color;\n width: 100%;\n}\n\n.contrast-area {\n margin-left: 0.25rem;\n margin-right: 0.25rem;\n\n border-radius: var(--mds-input-range-track-size);\n}\n\n:host([disabled]:not([disabled=\"false\"])) {\n --mds-input-range-thumb-background: var(--mds-input-range-thumb-background-disabled);\n --mds-input-range-track-background: var(--mds-input-range-track-background-disabled);\n --mds-input-range-track-progress-background: var(--mds-input-range-track-progress-background-disabled);\n}\n\n:host([disabled]:not([disabled=\"false\"])) .field::-webkit-slider-thumb {\n cursor: not-allowed;\n}\n\n@tailwind utilities;\n\n@container style(--magma-pref-animation: reduce) {\n :host,\n .field::-webkit-slider-thumb,\n .field::-webkit-slider-runnable-track,\n .track-progress,\n .track-total {\n -webkit-transition-duration: 0s;\n transition-duration: 0s;\n }\n}\n\n@container style(--magma-pref-animation: system) {\n\n @media (prefers-reduced-motion) {\n :host,\n .field::-webkit-slider-thumb,\n .field::-webkit-slider-runnable-track,\n .track-progress,\n .track-total {\n -webkit-transition-duration: 0s;\n transition-duration: 0s;\n }\n }\n}\n\n@tailwind utilities;\n\n@container style(--magma-pref-theme: dark) {\n :host {\n\n --mds-input-range-thumb-background: rgb(var(--variant-primary-04));\n --mds-input-range-track-background: rgb(var(--tone-neutral-07));\n --mds-input-range-track-progress-background: rgb(var(--variant-primary-05));\n }\n}\n\n@container style(--magma-pref-theme: system) {\n\n @media (prefers-color-scheme: dark) {\n :host {\n\n --mds-input-range-thumb-background: rgb(var(--variant-primary-04));\n --mds-input-range-track-background: rgb(var(--tone-neutral-07));\n --mds-input-range-track-progress-background: rgb(var(--variant-primary-05));\n }\n }\n}\n\n@container style(--magma-pref-contrast: more) {\n :host {\n color: rgb(var(--tone-neutral-01));\n }\n}\n\n@container style(--magma-pref-contrast: system) {\n\n @media (prefers-contrast: more) {\n :host {\n color: rgb(var(--tone-neutral-01));\n }\n }\n}\n\n\n";
8
8
  const MdsInputRangeStyle0 = mdsInputRangeCss;
9
9
 
10
10
  const MdsInputRange = class {
@@ -18,15 +18,23 @@ const MdsInputRange = class {
18
18
  this.internals = hostRef.$hostElement$.attachInternals();
19
19
  hostRef.$hostElement$["s-ei"] = this.internals;
20
20
  }
21
+ /**
22
+ * The greatest value in the range of permitted values
23
+ */
24
+ this.max = 100;
25
+ /**
26
+ * The lowest value in the range of permitted values
27
+ */
28
+ this.min = 0;
29
+ /**
30
+ * The step attribute is a number that specifies the granularity that
31
+ * the value must adhere to, or the special value any, which is described below.
32
+ */
33
+ this.step = 1;
21
34
  this.onInput = () => {
22
35
  // trigger valueChanged that update progress and emit event
23
36
  this.value = parseInt(this.inputElement.value);
24
37
  };
25
- this.progress = undefined;
26
- this.max = 100;
27
- this.min = 0;
28
- this.step = 1;
29
- this.value = undefined;
30
38
  }
31
39
  calculateProgress() {
32
40
  // validate value
@@ -43,6 +51,16 @@ const MdsInputRange = class {
43
51
  const current = this.value - this.min;
44
52
  this.progress = current * 100 / total;
45
53
  }
54
+ disabledChanged(newValue) {
55
+ /**
56
+ * This is related to ALL disabled attributes set on Magma input components
57
+ * if solved, please check mds-button, mds-input, mds-input-*
58
+ * https://github.com/ionic-team/stencil/issues/5461
59
+ */
60
+ if (newValue) {
61
+ this.internals.setFormValue(null);
62
+ }
63
+ }
46
64
  valueChanged() {
47
65
  this.inputElement.value = this.value.toString();
48
66
  this.calculateProgress();
@@ -59,6 +77,9 @@ const MdsInputRange = class {
59
77
  throw Error('step cant be negative or zero');
60
78
  this.calculateProgress();
61
79
  }
80
+ formResetCallback() {
81
+ this.internals.setFormValue('');
82
+ }
62
83
  componentDidLoad() {
63
84
  var _a, _b;
64
85
  this.label = (_a = this.element.textContent) !== null && _a !== void 0 ? _a : '';
@@ -67,11 +88,12 @@ const MdsInputRange = class {
67
88
  this.calculateProgress();
68
89
  }
69
90
  render() {
70
- return (index.h(index.Host, { key: '4f58f56b2bf1af905741bbcab323e583dd907a35' }, index.h("header", { key: '69a2e6c483558f0ce70eca8e1ec45f4ce7f63b10', class: "header", part: "header" }, index.h("mds-text", { key: '1d5f89b89f5bdf1ca6746567eb23d2b96444c2d9', class: "label", typography: "label" }, index.h("slot", { key: '534eb663ff412980069c4308a2a15a784e2bf1cf' })), index.h("mds-text", { key: 'e187c33fb9124f1d20032c822b535d0ddc839fe3', class: "value", typography: "label" }, this.value)), index.h("div", { key: 'fb3245af7eefbab656b68810577d77a328e312c5', class: "range" }, index.h("div", { key: 'f146b8b59fbd5bbb3db2350d94686fad986b4dfc', class: "track" }, index.h("div", { key: '04aaec03384f51e3ad2ad8cc695274c36062d6bf', class: "contrast-area" }), index.h("div", { key: '2de981fb668e8056a24ca82163dca106fcc5878e', class: "track-total" }, index.h("div", { key: '2044a5ce25454e56d950c2c7f68ce11369babd87', class: "track-progress", style: { width: `${this.progress}%` } }))), index.h("input", { key: '423eb3d5b176748d0376374888c7ef3298dc54d9', class: "field", "aria-label": this.label, max: this.max, min: this.min, onInput: this.onInput, step: this.step, type: "range", value: this.value }))));
91
+ return (index.h(index.Host, { key: 'e1cf60063d451ad99e6e4943412119634a261dc6' }, index.h("header", { key: '786ee56712c0d48fce3b0107bf44e1a4e39a5cb2', class: "header", part: "header" }, index.h("mds-text", { key: 'b51d53ca91e1a39431b851dcefdbda983ae59a60', class: "label", typography: "label" }, index.h("slot", { key: '1e8a604c35454992794958088051f5074504a3cf' })), index.h("mds-text", { key: '64cdd428f13f52a6964ab55527707a74ef98d560', class: "value", typography: "label" }, this.value)), index.h("div", { key: '00f8ad9cd7bdaff91a766d7c8e50a5ad65b4983a', class: "range" }, index.h("div", { key: '64e70fc8df3951015535b0e0bee0177089c9c399', class: "track" }, index.h("div", { key: '255824ff26075a8da7e176f03e8a2e99d8e754e5', class: "contrast-area" }), index.h("div", { key: 'a5d3f15b29af3c95dcdaffe05ba3d9481bfafce2', class: "track-total" }, index.h("div", { key: 'f50dff46578030bc9ecd83d56dec99b4a099f0b5', class: "track-progress", style: { width: `${this.progress}%` } }))), index.h("input", { key: '34ba926affc23fb845c421c7813ec05f7ce03f5f', class: "field", "aria-label": this.label, disabled: this.disabled, max: this.max, min: this.min, onInput: this.onInput, step: this.step, type: "range", value: this.value }))));
71
92
  }
72
93
  static get formAssociated() { return true; }
73
94
  get element() { return index.getElement(this); }
74
95
  static get watchers() { return {
96
+ "disabled": ["disabledChanged"],
75
97
  "value": ["valueChanged"],
76
98
  "min": ["minChanged"],
77
99
  "max": ["maxChanged"],
@@ -2,11 +2,11 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const index = require('./index-f984e289.js');
5
+ const index = require('./index-27635fed.js');
6
6
  const appGlobals = require('./app-globals-3a1e7e63.js');
7
7
 
8
8
  /*
9
- Stencil Client Patch Browser v4.22.2 | MIT Licensed | https://stenciljs.com
9
+ Stencil Client Patch Browser v4.25.1 | MIT Licensed | https://stenciljs.com
10
10
  */
11
11
  var patchBrowser = () => {
12
12
  const importMeta = (typeof document === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : (document.currentScript && document.currentScript.src || new URL('mds-input-range.cjs.js', document.baseURI).href));
@@ -19,7 +19,7 @@ var patchBrowser = () => {
19
19
 
20
20
  patchBrowser().then(async (options) => {
21
21
  await appGlobals.globalScripts();
22
- return index.bootstrapLazy([["mds-input-range.cjs",[[65,"mds-input-range",{"max":[2],"min":[2],"step":[2],"value":[1538],"progress":[32]},null,{"value":["valueChanged"],"min":["minChanged"],"max":["maxChanged"],"step":["stepChanged"]}]]]], options);
22
+ return index.bootstrapLazy([["mds-input-range.cjs",[[65,"mds-input-range",{"max":[2],"min":[2],"step":[2],"disabled":[1540],"value":[1538],"progress":[32]},null,{"disabled":["disabledChanged"],"value":["valueChanged"],"min":["minChanged"],"max":["maxChanged"],"step":["stepChanged"]}]]]], options);
23
23
  });
24
24
 
25
25
  exports.setNonce = index.setNonce;
@@ -4,7 +4,7 @@
4
4
  ],
5
5
  "compiler": {
6
6
  "name": "@stencil/core",
7
- "version": "4.22.2",
7
+ "version": "4.25.1",
8
8
  "typescriptVersion": "5.5.4"
9
9
  },
10
10
  "collections": [],