@maggioli-design-system/mds-input 5.1.2 → 5.1.4
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.
- package/dist/cjs/{index-0dd8a96b.js → index-d13bd48d.js} +27 -16
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/mds-input.cjs.entry.js +3 -3
- package/dist/cjs/mds-input.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/mds-input/mds-input.css +8 -12
- package/dist/components/mds-input.js +2 -2
- package/dist/documentation.d.ts +1 -21
- package/dist/documentation.json +2 -2
- package/dist/esm/{index-f7903bc7.js → index-0e58948f.js} +27 -16
- package/dist/esm/loader.js +2 -2
- package/dist/esm/mds-input.entry.js +3 -3
- package/dist/esm/mds-input.js +3 -3
- package/dist/esm-es5/index-0e58948f.js +1 -0
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/mds-input.entry.js +1 -1
- package/dist/esm-es5/mds-input.js +1 -1
- package/dist/mds-input/mds-input.esm.js +1 -1
- package/dist/mds-input/mds-input.js +1 -1
- package/dist/mds-input/p-534509b0.js +2 -0
- package/dist/mds-input/p-9923fb56.system.entry.js +1 -0
- package/dist/mds-input/p-b99c7250.system.js +2 -0
- package/dist/mds-input/{p-c3cb102f.system.js → p-e428358e.system.js} +1 -1
- package/dist/mds-input/p-f04a1d99.entry.js +1 -0
- package/dist/stats.json +36 -33
- package/documentation.json +2 -2
- package/package.json +6 -6
- package/www/build/mds-input.esm.js +1 -1
- package/www/build/mds-input.js +1 -1
- package/www/build/p-534509b0.js +2 -0
- package/www/build/p-9923fb56.system.entry.js +1 -0
- package/www/build/p-b99c7250.system.js +2 -0
- package/www/build/{p-c3cb102f.system.js → p-e428358e.system.js} +1 -1
- package/www/build/p-f04a1d99.entry.js +1 -0
- package/dist/esm-es5/index-f7903bc7.js +0 -1
- package/dist/mds-input/p-0af336bb.entry.js +0 -1
- package/dist/mds-input/p-600285d7.js +0 -2
- package/dist/mds-input/p-dfdf0f8c.system.js +0 -2
- package/dist/mds-input/p-fb36d905.system.entry.js +0 -1
- package/www/build/p-0af336bb.entry.js +0 -1
- package/www/build/p-600285d7.js +0 -2
- package/www/build/p-dfdf0f8c.system.js +0 -2
- package/www/build/p-fb36d905.system.entry.js +0 -1
|
@@ -537,6 +537,9 @@ const createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
|
537
537
|
}
|
|
538
538
|
}
|
|
539
539
|
}
|
|
540
|
+
// This needs to always happen so we can hide nodes that are projected
|
|
541
|
+
// to another component but don't end up in a slot
|
|
542
|
+
elm['s-hn'] = hostTagName;
|
|
540
543
|
return elm;
|
|
541
544
|
};
|
|
542
545
|
/**
|
|
@@ -661,8 +664,9 @@ const removeVnodes = (vnodes, startIdx, endIdx) => {
|
|
|
661
664
|
* @param oldCh the old children of the parent node
|
|
662
665
|
* @param newVNode the new VNode which will replace the parent
|
|
663
666
|
* @param newCh the new children of the parent node
|
|
667
|
+
* @param isInitialRender whether or not this is the first render of the vdom
|
|
664
668
|
*/
|
|
665
|
-
const updateChildren = (parentElm, oldCh, newVNode, newCh) => {
|
|
669
|
+
const updateChildren = (parentElm, oldCh, newVNode, newCh, isInitialRender = false) => {
|
|
666
670
|
let oldStartIdx = 0;
|
|
667
671
|
let newStartIdx = 0;
|
|
668
672
|
let oldEndIdx = oldCh.length - 1;
|
|
@@ -686,25 +690,25 @@ const updateChildren = (parentElm, oldCh, newVNode, newCh) => {
|
|
|
686
690
|
else if (newEndVnode == null) {
|
|
687
691
|
newEndVnode = newCh[--newEndIdx];
|
|
688
692
|
}
|
|
689
|
-
else if (isSameVnode(oldStartVnode, newStartVnode)) {
|
|
693
|
+
else if (isSameVnode(oldStartVnode, newStartVnode, isInitialRender)) {
|
|
690
694
|
// if the start nodes are the same then we should patch the new VNode
|
|
691
695
|
// onto the old one, and increment our `newStartIdx` and `oldStartIdx`
|
|
692
696
|
// indices to reflect that. We don't need to move any DOM Nodes around
|
|
693
697
|
// since things are matched up in order.
|
|
694
|
-
patch(oldStartVnode, newStartVnode);
|
|
698
|
+
patch(oldStartVnode, newStartVnode, isInitialRender);
|
|
695
699
|
oldStartVnode = oldCh[++oldStartIdx];
|
|
696
700
|
newStartVnode = newCh[++newStartIdx];
|
|
697
701
|
}
|
|
698
|
-
else if (isSameVnode(oldEndVnode, newEndVnode)) {
|
|
702
|
+
else if (isSameVnode(oldEndVnode, newEndVnode, isInitialRender)) {
|
|
699
703
|
// likewise, if the end nodes are the same we patch new onto old and
|
|
700
704
|
// decrement our end indices, and also likewise in this case we don't
|
|
701
705
|
// need to move any DOM Nodes.
|
|
702
|
-
patch(oldEndVnode, newEndVnode);
|
|
706
|
+
patch(oldEndVnode, newEndVnode, isInitialRender);
|
|
703
707
|
oldEndVnode = oldCh[--oldEndIdx];
|
|
704
708
|
newEndVnode = newCh[--newEndIdx];
|
|
705
709
|
}
|
|
706
|
-
else if (isSameVnode(oldStartVnode, newEndVnode)) {
|
|
707
|
-
patch(oldStartVnode, newEndVnode);
|
|
710
|
+
else if (isSameVnode(oldStartVnode, newEndVnode, isInitialRender)) {
|
|
711
|
+
patch(oldStartVnode, newEndVnode, isInitialRender);
|
|
708
712
|
// We need to move the element for `oldStartVnode` into a position which
|
|
709
713
|
// will be appropriate for `newEndVnode`. For this we can use
|
|
710
714
|
// `.insertBefore` and `oldEndVnode.$elm$.nextSibling`. If there is a
|
|
@@ -726,8 +730,8 @@ const updateChildren = (parentElm, oldCh, newVNode, newCh) => {
|
|
|
726
730
|
oldStartVnode = oldCh[++oldStartIdx];
|
|
727
731
|
newEndVnode = newCh[--newEndIdx];
|
|
728
732
|
}
|
|
729
|
-
else if (isSameVnode(oldEndVnode, newStartVnode)) {
|
|
730
|
-
patch(oldEndVnode, newStartVnode);
|
|
733
|
+
else if (isSameVnode(oldEndVnode, newStartVnode, isInitialRender)) {
|
|
734
|
+
patch(oldEndVnode, newStartVnode, isInitialRender);
|
|
731
735
|
// We've already checked above if `oldStartVnode` and `newStartVnode` are
|
|
732
736
|
// the same node, so since we're here we know that they are not. Thus we
|
|
733
737
|
// can move the element for `oldEndVnode` _before_ the element for
|
|
@@ -781,9 +785,10 @@ const updateChildren = (parentElm, oldCh, newVNode, newCh) => {
|
|
|
781
785
|
*
|
|
782
786
|
* @param leftVNode the first VNode to check
|
|
783
787
|
* @param rightVNode the second VNode to check
|
|
788
|
+
* @param isInitialRender whether or not this is the first render of the vdom
|
|
784
789
|
* @returns whether they're equal or not
|
|
785
790
|
*/
|
|
786
|
-
const isSameVnode = (leftVNode, rightVNode) => {
|
|
791
|
+
const isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
|
|
787
792
|
// compare if two vnode to see if they're "technically" the same
|
|
788
793
|
// need to have the same element tag, and same key to be the same
|
|
789
794
|
if (leftVNode.$tag$ === rightVNode.$tag$) {
|
|
@@ -798,8 +803,9 @@ const isSameVnode = (leftVNode, rightVNode) => {
|
|
|
798
803
|
*
|
|
799
804
|
* @param oldVNode an old VNode whose DOM element and children we want to update
|
|
800
805
|
* @param newVNode a new VNode representing an updated version of the old one
|
|
806
|
+
* @param isInitialRender whether or not this is the first render of the vdom
|
|
801
807
|
*/
|
|
802
|
-
const patch = (oldVNode, newVNode) => {
|
|
808
|
+
const patch = (oldVNode, newVNode, isInitialRender = false) => {
|
|
803
809
|
const elm = (newVNode.$elm$ = oldVNode.$elm$);
|
|
804
810
|
const oldChildren = oldVNode.$children$;
|
|
805
811
|
const newChildren = newVNode.$children$;
|
|
@@ -816,7 +822,7 @@ const patch = (oldVNode, newVNode) => {
|
|
|
816
822
|
if (oldChildren !== null && newChildren !== null) {
|
|
817
823
|
// looks like there's child vnodes for both the old and new vnodes
|
|
818
824
|
// so we need to call `updateChildren` to reconcile them
|
|
819
|
-
updateChildren(elm, oldChildren, newVNode, newChildren);
|
|
825
|
+
updateChildren(elm, oldChildren, newVNode, newChildren, isInitialRender);
|
|
820
826
|
}
|
|
821
827
|
else if (newChildren !== null) {
|
|
822
828
|
// no old child vnodes, but there are new child vnodes to add
|
|
@@ -908,7 +914,7 @@ const renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
908
914
|
scopeId = hostElm['s-sc'];
|
|
909
915
|
}
|
|
910
916
|
// synchronous patch
|
|
911
|
-
patch(oldVNode, rootVnode);
|
|
917
|
+
patch(oldVNode, rootVnode, isInitialLoad);
|
|
912
918
|
};
|
|
913
919
|
const attachToAncestor = (hostRef, ancestorComponent) => {
|
|
914
920
|
if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent['s-p']) {
|
|
@@ -1222,11 +1228,14 @@ const proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1222
1228
|
const hostRef = getHostRef(this);
|
|
1223
1229
|
const instance = hostRef.$lazyInstance$ ;
|
|
1224
1230
|
if (!instance) {
|
|
1225
|
-
hostRef.$onReadyPromise$.then((instance) => {
|
|
1231
|
+
hostRef.$onReadyPromise$.then((instance) => {
|
|
1232
|
+
const cb = instance[cbName];
|
|
1233
|
+
typeof cb === 'function' && cb.call(instance, ...args);
|
|
1234
|
+
});
|
|
1226
1235
|
}
|
|
1227
1236
|
else {
|
|
1228
1237
|
const cb = instance[cbName];
|
|
1229
|
-
typeof cb === 'function' && cb(...args);
|
|
1238
|
+
typeof cb === 'function' && cb.call(instance, ...args);
|
|
1230
1239
|
}
|
|
1231
1240
|
},
|
|
1232
1241
|
}));
|
|
@@ -1618,12 +1627,14 @@ const bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1618
1627
|
// If we have styles, add them to the DOM
|
|
1619
1628
|
if (dataStyles.innerHTML.length) {
|
|
1620
1629
|
dataStyles.setAttribute('data-styles', '');
|
|
1621
|
-
head.insertBefore(dataStyles, metaCharset ? metaCharset.nextSibling : head.firstChild);
|
|
1622
1630
|
// Apply CSP nonce to the style tag if it exists
|
|
1623
1631
|
const nonce = (_a = plt.$nonce$) !== null && _a !== void 0 ? _a : queryNonceMetaTagContent(doc);
|
|
1624
1632
|
if (nonce != null) {
|
|
1625
1633
|
dataStyles.setAttribute('nonce', nonce);
|
|
1626
1634
|
}
|
|
1635
|
+
// Insert the styles into the document head
|
|
1636
|
+
// NOTE: this _needs_ to happen last so we can ensure the nonce (and other attributes) are applied
|
|
1637
|
+
head.insertBefore(dataStyles, metaCharset ? metaCharset.nextSibling : head.firstChild);
|
|
1627
1638
|
}
|
|
1628
1639
|
// Process deferred connectedCallbacks now all components have been registered
|
|
1629
1640
|
isBootstrapping = false;
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-d13bd48d.js');
|
|
6
6
|
|
|
7
7
|
const defineCustomElements = (win, options) => {
|
|
8
8
|
if (typeof window === 'undefined') return undefined;
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-d13bd48d.js');
|
|
6
6
|
|
|
7
|
-
function r(e){var t,f,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e))for(t=0;t<
|
|
7
|
+
function r(e){var t,f,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(f=r(e[t]))&&(n&&(n+=" "),n+=f);}else for(f in e)e[f]&&(n&&(n+=" "),n+=f);return n}function clsx(){for(var e,t,f=0,n="",o=arguments.length;f<o;f++)(e=arguments[f])&&(t=r(e))&&(n&&(n+=" "),n+=t);return n}
|
|
8
8
|
|
|
9
9
|
const miBaselineAdd = `<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path d="M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"/></svg>`;
|
|
10
10
|
|
|
@@ -16,7 +16,7 @@ const miBaselineRemove = `<svg xmlns="http://www.w3.org/2000/svg" width="24" hei
|
|
|
16
16
|
|
|
17
17
|
const miBaselineDone = `<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path d="M9 16.2L4.8 12l-1.4 1.4L9 19L21 7l-1.4-1.4L9 16.2z"/></svg>`;
|
|
18
18
|
|
|
19
|
-
const mdsInputCss = "@-webkit-keyframes focus-bounce {\n 0%, 75%, 100% {\n outline-offset: var(--magma-outline-focus-offset);\n }\n\n 50% {\n outline-offset: var(--magma-outline-blur-offset);\n }\n}\n @keyframes focus-bounce {\n 0%, 75%, 100% {\n outline-offset: var(--magma-outline-focus-offset);\n }\n\n 50% {\n outline-offset: var(--magma-outline-blur-offset);\n }\n}\n /* included for focus effect */\n@tailwind components;\n\n*, ::before, ::after {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n::-webkit-backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n::-ms-backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n::backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n.focus-bounce {\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.focus-bounce--focused,\n .focus-bounce: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.svg {\n display: -ms-flexbox;\n display: flex;\n}\n.svg svg {\n aspect-ratio: 1/1;\n height: 100%;\n width: 100%;\n}\n@tailwind utilities;\n\n/**\n * @prop --mds-input-background: Sets the background-color of the component\n * @prop --mds-input-icon-color: Sets the icon color of the component\n * @prop --mds-input-ring: Sets the box-shadow of the component's input\n * @prop --mds-input-shadow: Sets the box-shadow of the component's input\n * @prop --mds-input-tip-background: Sets the background color of the tip message at the bottom right of the component\n * @prop --mds-input-variant-color: Sets the variant colors of the component\n */\n\n:host {\n\n --mds-input-background: rgb(var(--tone-neutral));\n --mds-input-icon-color: var(--mds-input-variant-color);\n --mds-input-tip-background: 84 84 84;\n --mds-input-ring: 0 0 0 1px rgb(var(--mds-input-variant-color) / 0.1);\n --mds-input-shadow: 0 1px 3px 0 rgb(var(--mds-input-variant-color) / 0.1), 0 1px 2px 0 rgb(var(--mds-input-variant-color) / 0.06);\n --mds-input-variant-color: 0 0 0;\n --mds-input-controls-color: rgb(var(--tone-neutral-04));\n --mds-input-controls-border: 2px solid rgb(var(--tone-neutral-09));\n font-family: Karla, -apple-system, BlinkMacSystemFont, 'San Francisco', 'Segoe UI', 'Helvetica Neue', sans-serif;\n font-size: 16px;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n gap: 0.5rem;\n\n container-type: inline-size;\n display: -ms-flexbox;\n display: flex;\n position: relative;\n}\n\n:host( [typography=\"detail\"] ) .input {\n font-family: Karla, -apple-system, BlinkMacSystemFont, 'San Francisco', 'Segoe UI', 'Helvetica Neue', sans-serif;\n font-size: 16px;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n:host( [typography=\"snippet\"] ) .input {\n font-family: 'Roboto Mono', monospace;\n font-size: 16px;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n.input {\n font-family: Karla, -apple-system, BlinkMacSystemFont, 'San Francisco', 'Segoe UI', 'Helvetica Neue', sans-serif;\n font-size: 16px;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n margin: 0rem;\n border-radius: 0.5rem;\n padding-left: 1rem;\n padding-right: 1rem;\n padding-top: 0.75rem;\n padding-bottom: 0.75rem;\n -webkit-transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width, -webkit-box-shadow, -webkit-transform;\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 -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n background-color: var(--mds-input-background);\n border: 0;\n -webkit-box-shadow: var(--mds-input-ring), var(--mds-input-shadow);\n box-shadow: var(--mds-input-ring), var(--mds-input-shadow);\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: rgb(var(--tone-neutral-02));\n min-height: 3rem;\n overflow: hidden;\n text-overflow: ellipsis;\n width: 100%;\n}\n\n.input::-webkit-outer-spin-button,\n.input::-webkit-inner-spin-button {\n -webkit-appearance: none;\n appearance: none;\n display: none;\n margin: 0;\n}\n\ntextarea.input:active {\n -webkit-transition-property: none;\n transition-property: none;\n}\n\ntextarea.input {\n max-height: 16rem;\n min-height: 6rem;\n border-bottom-right-radius: 0;\n}\n\n.input:focus {\n outline: 2px solid transparent;\n outline-offset: 2px;\n -webkit-transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width, -webkit-box-shadow, -webkit-transform;\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 -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n --mds-input-ring: 0 0 0 3px rgb(var(--mds-input-variant-color) / 1);\n --mds-input-shadow: 0 4px 6px 3px rgb(var(--mds-input-variant-color) / 0.1), 0 2px 4px -1px rgb(var(--mds-input-variant-color) / 0.06);\n}\n\n.input:disabled {\n background-color: rgb(var(--tone-neutral-10));\n}\n\n.input:disabled::-moz-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled::-webkit-input-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled:-ms-input-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled::-ms-input-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled,\n.input:disabled::placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input.has-icon {\n padding-left: 2.75rem;\n}\n\n\n\n.icon {\n left: 0.75rem;\n top: 0.75rem;\n\n fill: rgb(var(--mds-input-icon-color));\n position: absolute;\n}\n\n.counter {\n border-left: var(--mds-input-controls-border);\n display: -ms-flexbox;\n display: flex;\n -ms-flex-direction: column;\n flex-direction: column;\n gap: 0;\n position: absolute;\n right: 0;\n}\n\n.counter-button {\n height: 1.5rem;\n width: 1.75rem;\n border-radius: 0.5rem;\n padding: 0rem;\n\n -ms-flex-align: center;\n\n align-items: center;\n background-color: transparent;\n border: 0;\n display: -ms-flexbox;\n display: flex;\n fill: var(--mds-input-controls-color);\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.counter-button:hover {\n background-color: rgb(var(--tone-neutral-09));\n}\n\n.counter .counter-button:first-child {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.counter .counter-button:last-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n}\n\n.counter-button--horizontal {\n height: 3rem;\n width: 3rem;\n\n bottom: 0;\n position: absolute;\n top: 0;\n}\n\n.counter-button--decrease {\n border-bottom-right-radius: 0;\n border-right: var(--mds-input-controls-border);\n border-top-right-radius: 0;\n left: 0;\n}\n\n.counter-button--increase {\n border-bottom-left-radius: 0;\n border-left: var(--mds-input-controls-border);\n border-top-left-radius: 0;\n right: 0;\n}\n\n:host( [type=\"number\"] ) .input {\n padding-right: 2rem;\n}\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"] ) .input {\n padding-left: 3.5rem;\n padding-right: 3.5rem;\n\n text-align: center;\n}\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"][icon] ) .input {\n padding-left: 6rem;\n\n text-align: left;\n}\n\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"] ) .icon {\n left: 3.75rem;\n}\n\n.fixed {\n position: fixed;\n}\n\n.absolute {\n position: absolute;\n}\n\n.grid {\n display: grid;\n}\n\n.w-min {\n width: -moz-min-content;\n width: -webkit-min-content;\n width: min-content;\n}\n\n.truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.rounded {\n border-radius: 0.25rem;\n}\n\n.border {\n border-width: 1px;\n}\n\n.bg-tone-neutral-08 {\n --tw-bg-opacity: 1;\n background-color: rgb(var(--tone-neutral-08) / var(--tw-bg-opacity));\n}\n\n.text {\n font-size: 1rem;\n}\n\n.text-tone-neutral-04 {\n --tw-text-opacity: 1;\n color: rgb(var(--tone-neutral-04) / var(--tw-text-opacity));\n}\n\n.shadow {\n --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);\n --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);\n -webkit-box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n:host {\n\n --mds-input-icon-color: var(--brand-maggioli-03);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( :focus ) {\n\n --mds-input-variant-color: var(--brand-maggioli-04);\n}\n\n:host( [variant=\"info\"] ) {\n\n --mds-input-icon-color: var(--status-info-05);\n --mds-input-tip-background: var(--status-info-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"info\"]:focus ) {\n\n --mds-input-icon-color: var(--status-info-04);\n --mds-input-variant-color: var(--status-info-05);\n}\n\n:host( [variant=\"success\"] ) {\n\n --mds-input-icon-color: var(--status-success-05);\n --mds-input-tip-background: var(--status-success-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"success\"]:focus ) {\n\n --mds-input-icon-color: var(--status-success-04);\n --mds-input-variant-color: var(--status-success-05);\n}\n\n:host( [variant=\"warning\"] ) {\n\n --mds-input-icon-color: var(--status-warning-05);\n --mds-input-tip-background: var(--status-warning-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"warning\"]:focus ) {\n\n --mds-input-icon-color: var(--status-warning-04);\n --mds-input-variant-color: var(--status-warning-05);\n}\n\n:host( [variant=\"error\"] ) {\n\n --mds-input-icon-color: var(--status-error-05);\n --mds-input-tip-background: var(--status-error-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"error\"]:focus ) {\n\n --mds-input-icon-color: var(--status-error-04);\n --mds-input-variant-color: var(--status-error-05);\n}\n\n.tip-container {\n left: 0.25rem;\n right: 0.25rem;\n gap: 0.25rem;\n -webkit-transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width, -webkit-box-shadow, -webkit-transform;\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 -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n display: -ms-flexbox;\n\n display: flex;\n -ms-flex-pack: end;\n justify-content: flex-end;\n pointer-events: none;\n position: absolute;\n}\n\n.tip-container:empty {\n display: none;\n}\n\n.tip-container--top {\n top: 0.25rem;\n}\n\n.tip-container--bottom {\n bottom: 0.25rem;\n}\n\n.tip {\n height: 0.75rem;\n border-radius: 0.375rem;\n -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n -ms-flex-align: center;\n\n align-items: center;\n background-color: rgb(var(--mds-input-tip-background));\n color: transparent;\n color: rgb(var(--tone-neutral));\n display: -ms-flexbox;\n display: flex;\n fill: rgb(var(--tone-neutral));\n -ms-flex-pack: center;\n justify-content: center;\n min-width: 0.75rem;\n padding: 0;\n pointer-events: none;\n position: static;\n text-align: center;\n -webkit-transform: translate(0, 0);\n transform: translate(0, 0);\n -webkit-transition-property: background-color, border-radius, color, padding-left, padding-right, -webkit-transform;\n transition-property: background-color, border-radius, color, padding-left, padding-right, -webkit-transform;\n transition-property: background-color, border-radius, color, padding-left, padding-right, transform;\n transition-property: background-color, border-radius, color, padding-left, padding-right, transform, -webkit-transform;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n\n.tip__content {\n height: 0.75rem;\n -webkit-transition-duration: 200ms;\n transition-duration: 200ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n display: grid;\n grid-template-columns: 0fr;\n opacity: 0;\n overflow: hidden;\n -webkit-transition-property: grid-template-columns, opacity;\n transition-property: grid-template-columns, opacity;\n transition-property: grid-template-columns, opacity, -ms-grid-columns;\n}\n\n.tip__text {\n -webkit-transform: translate(0, 1px);\n transform: translate(0, 1px);\n}\n\n.tip__icon {\n height: 0.75rem;\n width: 0.75rem;\n\n display: none;\n}\n\n:host(:focus-within) .tip-container--top {\n -webkit-transform: translate(calc(0.25rem * -1), calc(0.25rem * -1));\n transform: translate(calc(0.25rem * -1), calc(0.25rem * -1));\n}\n\n:host(:focus-within) .tip-container--bottom {\n -webkit-transform: translate(calc(0.25rem * -1), 0.25rem);\n transform: translate(calc(0.25rem * -1), 0.25rem);\n}\n\n:host(:focus-within) .tip-container--top .tip {\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n}\n\n:host(:focus-within) .tip-container--bottom .tip {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n}\n\n.tip--expanded,\n:host(:focus-within) .tip--expand {\n padding-left: 0.5rem;\n padding-right: 0.5rem;\n}\n\n.tip--expanded .tip__content,\n:host(:focus-within) .tip--expand .tip__content,\n:host( [value]:not([value=\"\"]) ) .tip--expand .tip__content {\n grid-template-columns: 1fr;\n opacity: 1;\n}\n\n:host( [value]:not([value=\"\"]) ) .tip--expand .tip__text {\n display: none;\n}\n\n:host( [value]:not([value=\"\"]) ) .tip__icon {\n display: -ms-flexbox;\n display: flex;\n}\n\n:host([value]:not([value=\"\"]):focus-within) .tip--expand {\n padding-left: 0;\n padding-right: 0;\n}\n\n:host( [type=\"number\"] ) .tip-container {\n right: 2.25rem;\n}\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"] ) .tip-container {\n left: 3.5rem;\n right: 3.5rem;\n}\n\n:host( [value]:not([value=\"\"]) ) .tip--required {\n\n --mds-input-tip-background: var(--status-success-05);\n}\n\n.tip--required {\n\n --mds-input-tip-background: var(--status-error-05);\n}\n\n.tip--read-only {\n\n --mds-input-tip-background: var(--status-info-05);\n}\n\n.tip--disabled {\n\n --mds-input-tip-background: var(--tone-neutral-05);\n}\n\n\n@container (max-width: 210px) {\n :host .tip__content,\n :host(:focus-within) .tip__content {\n grid-template-columns: 0fr;\n opacity: 0;\n }\n\n :host .tip {\n padding-left: 0;\n padding-right: 0;\n }\n\n :host {\n\n --mds-input-background: rgb(var(--brand-maggioli-07));\n }\n}\n";
|
|
19
|
+
const mdsInputCss = "@-webkit-keyframes focus-bounce {\n 0%, 75%, 100% {\n outline-offset: var(--magma-outline-focus-offset);\n }\n\n 50% {\n outline-offset: var(--magma-outline-blur-offset);\n }\n}\n @keyframes focus-bounce {\n 0%, 75%, 100% {\n outline-offset: var(--magma-outline-focus-offset);\n }\n\n 50% {\n outline-offset: var(--magma-outline-blur-offset);\n }\n}\n /* included for focus effect */\n@tailwind components;\n\n*, ::before, ::after {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n::-webkit-backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n::-ms-backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n::backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n.focus-bounce {\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.focus-bounce--focused,\n .focus-bounce: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.svg {\n display: -ms-flexbox;\n display: flex;\n}\n.svg svg {\n aspect-ratio: 1/1;\n height: 100%;\n width: 100%;\n}\n@tailwind utilities;\n\n/**\n * @prop --mds-input-background: Sets the background-color of the component\n * @prop --mds-input-icon-color: Sets the icon color of the component\n * @prop --mds-input-ring: Sets the box-shadow of the component's input\n * @prop --mds-input-shadow: Sets the box-shadow of the component's input\n * @prop --mds-input-tip-background: Sets the background color of the tip message at the bottom right of the component\n * @prop --mds-input-variant-color: Sets the variant colors of the component\n */\n\n:host {\n\n --mds-input-background: rgb(var(--tone-neutral));\n --mds-input-icon-color: var(--mds-input-variant-color);\n --mds-input-tip-background: 84 84 84;\n --mds-input-ring: 0 0 0 1px rgb(var(--mds-input-variant-color) / 0.1);\n --mds-input-shadow: 0 1px 3px 0 rgb(var(--mds-input-variant-color) / 0.1), 0 1px 2px 0 rgb(var(--mds-input-variant-color) / 0.06);\n --mds-input-variant-color: 0 0 0;\n --mds-input-controls-color: rgb(var(--tone-neutral-04));\n --mds-input-controls-border: 2px solid rgb(var(--tone-neutral-09));\n font-family: Karla, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;\n font-size: 1rem;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n gap: 0.5rem;\n\n container-type: inline-size;\n display: -ms-flexbox;\n display: flex;\n position: relative;\n}\n\n:host( [typography=\"detail\"] ) .input {\n font-family: Karla, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;\n font-size: 1rem;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n:host( [typography=\"snippet\"] ) .input {\n font-family: 'Roboto Mono', 'Courier New', monospace;\n font-size: 1rem;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n.input {\n font-family: Karla, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;\n font-size: 1rem;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n margin: 0rem;\n border-radius: 0.5rem;\n padding-left: 1rem;\n padding-right: 1rem;\n padding-top: 0.75rem;\n padding-bottom: 0.75rem;\n -webkit-transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width, -webkit-box-shadow, -webkit-transform;\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 -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n background-color: var(--mds-input-background);\n border: 0;\n -webkit-box-shadow: var(--mds-input-ring), var(--mds-input-shadow);\n box-shadow: var(--mds-input-ring), var(--mds-input-shadow);\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: rgb(var(--tone-neutral-02));\n min-height: 3rem;\n overflow: hidden;\n text-overflow: ellipsis;\n width: 100%;\n}\n\n.input::-webkit-outer-spin-button,\n.input::-webkit-inner-spin-button {\n -webkit-appearance: none;\n appearance: none;\n display: none;\n margin: 0;\n}\n\ntextarea.input:active {\n -webkit-transition-property: none;\n transition-property: none;\n}\n\ntextarea.input {\n max-height: 16rem;\n min-height: 6rem;\n border-bottom-right-radius: 0;\n}\n\n.input:focus {\n outline: 2px solid transparent;\n outline-offset: 2px;\n -webkit-transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width, -webkit-box-shadow, -webkit-transform;\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 -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n --mds-input-ring: 0 0 0 3px rgb(var(--mds-input-variant-color) / 1);\n --mds-input-shadow: 0 4px 6px 3px rgb(var(--mds-input-variant-color) / 0.1), 0 2px 4px -1px rgb(var(--mds-input-variant-color) / 0.06);\n}\n\n.input:disabled {\n background-color: rgb(var(--tone-neutral-10));\n}\n\n.input:disabled::-moz-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled::-webkit-input-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled:-ms-input-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled::-ms-input-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled,\n.input:disabled::placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input.has-icon {\n padding-left: 2.75rem;\n}\n\n\n\n.icon {\n left: 0.75rem;\n top: 0.75rem;\n\n fill: rgb(var(--mds-input-icon-color));\n position: absolute;\n}\n\n.counter {\n border-left: var(--mds-input-controls-border);\n display: -ms-flexbox;\n display: flex;\n -ms-flex-direction: column;\n flex-direction: column;\n gap: 0;\n position: absolute;\n right: 0;\n}\n\n.counter-button {\n height: 1.5rem;\n width: 1.75rem;\n border-radius: 0.5rem;\n padding: 0rem;\n\n -ms-flex-align: center;\n\n align-items: center;\n background-color: transparent;\n border: 0;\n display: -ms-flexbox;\n display: flex;\n fill: var(--mds-input-controls-color);\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.counter-button:hover {\n background-color: rgb(var(--tone-neutral-09));\n}\n\n.counter .counter-button:first-child {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.counter .counter-button:last-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n}\n\n.counter-button--horizontal {\n height: 3rem;\n width: 3rem;\n\n bottom: 0;\n position: absolute;\n top: 0;\n}\n\n.counter-button--decrease {\n border-bottom-right-radius: 0;\n border-right: var(--mds-input-controls-border);\n border-top-right-radius: 0;\n left: 0;\n}\n\n.counter-button--increase {\n border-bottom-left-radius: 0;\n border-left: var(--mds-input-controls-border);\n border-top-left-radius: 0;\n right: 0;\n}\n\n:host( [type=\"number\"] ) .input {\n padding-right: 2rem;\n}\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"] ) .input {\n padding-left: 3.5rem;\n padding-right: 3.5rem;\n\n text-align: center;\n}\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"][icon] ) .input {\n padding-left: 6rem;\n\n text-align: left;\n}\n\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"] ) .icon {\n left: 3.75rem;\n}\n\n.fixed {\n position: fixed;\n}\n\n.absolute {\n position: absolute;\n}\n\n.grid {\n display: grid;\n}\n\n.w-min {\n width: -moz-min-content;\n width: -webkit-min-content;\n width: min-content;\n}\n\n.truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.rounded {\n border-radius: 0.25rem;\n}\n\n.border {\n border-width: 1px;\n}\n\n.bg-tone-neutral-08 {\n --tw-bg-opacity: 1;\n background-color: rgb(var(--tone-neutral-08) / var(--tw-bg-opacity));\n}\n\n.text-tone-neutral-04 {\n --tw-text-opacity: 1;\n color: rgb(var(--tone-neutral-04) / var(--tw-text-opacity));\n}\n\n.shadow {\n --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);\n --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);\n -webkit-box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n:host {\n\n --mds-input-icon-color: var(--brand-maggioli-03);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( :focus ) {\n\n --mds-input-variant-color: var(--brand-maggioli-04);\n}\n\n:host( [variant=\"info\"] ) {\n\n --mds-input-icon-color: var(--status-info-05);\n --mds-input-tip-background: var(--status-info-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"info\"]:focus ) {\n\n --mds-input-icon-color: var(--status-info-04);\n --mds-input-variant-color: var(--status-info-05);\n}\n\n:host( [variant=\"success\"] ) {\n\n --mds-input-icon-color: var(--status-success-05);\n --mds-input-tip-background: var(--status-success-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"success\"]:focus ) {\n\n --mds-input-icon-color: var(--status-success-04);\n --mds-input-variant-color: var(--status-success-05);\n}\n\n:host( [variant=\"warning\"] ) {\n\n --mds-input-icon-color: var(--status-warning-05);\n --mds-input-tip-background: var(--status-warning-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"warning\"]:focus ) {\n\n --mds-input-icon-color: var(--status-warning-04);\n --mds-input-variant-color: var(--status-warning-05);\n}\n\n:host( [variant=\"error\"] ) {\n\n --mds-input-icon-color: var(--status-error-05);\n --mds-input-tip-background: var(--status-error-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"error\"]:focus ) {\n\n --mds-input-icon-color: var(--status-error-04);\n --mds-input-variant-color: var(--status-error-05);\n}\n\n.tip-container {\n left: 0.25rem;\n right: 0.25rem;\n gap: 0.25rem;\n -webkit-transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width, -webkit-box-shadow, -webkit-transform;\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 -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n display: -ms-flexbox;\n\n display: flex;\n -ms-flex-pack: end;\n justify-content: flex-end;\n pointer-events: none;\n position: absolute;\n}\n\n.tip-container:empty {\n display: none;\n}\n\n.tip-container--top {\n top: 0.25rem;\n}\n\n.tip-container--bottom {\n bottom: 0.25rem;\n}\n\n.tip {\n height: 0.75rem;\n border-radius: 0.375rem;\n -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n -ms-flex-align: center;\n\n align-items: center;\n background-color: rgb(var(--mds-input-tip-background));\n color: transparent;\n color: rgb(var(--tone-neutral));\n display: -ms-flexbox;\n display: flex;\n fill: rgb(var(--tone-neutral));\n -ms-flex-pack: center;\n justify-content: center;\n min-width: 0.75rem;\n padding: 0;\n pointer-events: none;\n position: static;\n text-align: center;\n -webkit-transform: translate(0, 0);\n transform: translate(0, 0);\n -webkit-transition-property: background-color, border-radius, color, padding-left, padding-right, -webkit-transform;\n transition-property: background-color, border-radius, color, padding-left, padding-right, -webkit-transform;\n transition-property: background-color, border-radius, color, padding-left, padding-right, transform;\n transition-property: background-color, border-radius, color, padding-left, padding-right, transform, -webkit-transform;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n\n.tip__content {\n height: 0.75rem;\n -webkit-transition-duration: 200ms;\n transition-duration: 200ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n display: grid;\n grid-template-columns: 0fr;\n opacity: 0;\n overflow: hidden;\n -webkit-transition-property: grid-template-columns, opacity;\n transition-property: grid-template-columns, opacity;\n transition-property: grid-template-columns, opacity, -ms-grid-columns;\n}\n\n.tip__text {\n -webkit-transform: translate(0, 1px);\n transform: translate(0, 1px);\n}\n\n.tip__icon {\n height: 0.75rem;\n width: 0.75rem;\n\n display: none;\n}\n\n:host(:focus-within) .tip-container--top {\n -webkit-transform: translate(calc(0.25rem * -1), calc(0.25rem * -1));\n transform: translate(calc(0.25rem * -1), calc(0.25rem * -1));\n}\n\n:host(:focus-within) .tip-container--bottom {\n -webkit-transform: translate(calc(0.25rem * -1), 0.25rem);\n transform: translate(calc(0.25rem * -1), 0.25rem);\n}\n\n:host(:focus-within) .tip-container--top .tip {\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n}\n\n:host(:focus-within) .tip-container--bottom .tip {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n}\n\n.tip--expanded,\n:host(:focus-within) .tip--expand {\n padding-left: 0.5rem;\n padding-right: 0.5rem;\n}\n\n.tip--expanded .tip__content,\n:host(:focus-within) .tip--expand .tip__content,\n:host( [value]:not([value=\"\"]) ) .tip--expand .tip__content {\n grid-template-columns: 1fr;\n opacity: 1;\n}\n\n:host( [value]:not([value=\"\"]) ) .tip--expand .tip__text {\n display: none;\n}\n\n:host( [value]:not([value=\"\"]) ) .tip__icon {\n display: -ms-flexbox;\n display: flex;\n}\n\n:host([value]:not([value=\"\"]):focus-within) .tip--expand {\n padding-left: 0;\n padding-right: 0;\n}\n\n:host( [type=\"number\"] ) .tip-container {\n right: 2.25rem;\n}\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"] ) .tip-container {\n left: 3.5rem;\n right: 3.5rem;\n}\n\n:host( [value]:not([value=\"\"]) ) .tip--required {\n\n --mds-input-tip-background: var(--status-success-05);\n}\n\n.tip--required {\n\n --mds-input-tip-background: var(--status-error-05);\n}\n\n.tip--read-only {\n\n --mds-input-tip-background: var(--status-info-05);\n}\n\n.tip--disabled {\n\n --mds-input-tip-background: var(--tone-neutral-05);\n}\n\n\n@container (max-width: 210px) {\n :host .tip__content,\n :host(:focus-within) .tip__content {\n grid-template-columns: 0fr;\n opacity: 0;\n }\n\n :host .tip {\n padding-left: 0;\n padding-right: 0;\n }\n\n :host {\n\n --mds-input-background: rgb(var(--brand-maggioli-07));\n }\n}\n";
|
|
20
20
|
|
|
21
21
|
const MdsInput = class {
|
|
22
22
|
constructor(hostRef) {
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-d13bd48d.js');
|
|
6
6
|
|
|
7
7
|
/*
|
|
8
|
-
Stencil Client Patch Browser v4.
|
|
8
|
+
Stencil Client Patch Browser v4.9.1 | MIT Licensed | https://stenciljs.com
|
|
9
9
|
*/
|
|
10
10
|
const patchBrowser = () => {
|
|
11
11
|
const importMeta = (typeof document === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : (document.currentScript && document.currentScript.src || new URL('mds-input.cjs.js', document.baseURI).href));
|
|
@@ -157,8 +157,8 @@
|
|
|
157
157
|
--mds-input-variant-color: 0 0 0;
|
|
158
158
|
--mds-input-controls-color: rgb(var(--tone-neutral-04));
|
|
159
159
|
--mds-input-controls-border: 2px solid rgb(var(--tone-neutral-09));
|
|
160
|
-
font-family: Karla, -apple-system, BlinkMacSystemFont, '
|
|
161
|
-
font-size:
|
|
160
|
+
font-family: Karla, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
|
161
|
+
font-size: 1rem;
|
|
162
162
|
line-height: 1.5rem;
|
|
163
163
|
-webkit-font-smoothing: antialiased;
|
|
164
164
|
-moz-osx-font-smoothing: grayscale;
|
|
@@ -170,24 +170,24 @@
|
|
|
170
170
|
}
|
|
171
171
|
|
|
172
172
|
:host( [typography="detail"] ) .input {
|
|
173
|
-
font-family: Karla, -apple-system, BlinkMacSystemFont, '
|
|
174
|
-
font-size:
|
|
173
|
+
font-family: Karla, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
|
174
|
+
font-size: 1rem;
|
|
175
175
|
line-height: 1.5rem;
|
|
176
176
|
-webkit-font-smoothing: antialiased;
|
|
177
177
|
-moz-osx-font-smoothing: grayscale;
|
|
178
178
|
}
|
|
179
179
|
|
|
180
180
|
:host( [typography="snippet"] ) .input {
|
|
181
|
-
font-family: 'Roboto Mono', monospace;
|
|
182
|
-
font-size:
|
|
181
|
+
font-family: 'Roboto Mono', 'Courier New', monospace;
|
|
182
|
+
font-size: 1rem;
|
|
183
183
|
line-height: 1.5rem;
|
|
184
184
|
-webkit-font-smoothing: antialiased;
|
|
185
185
|
-moz-osx-font-smoothing: grayscale;
|
|
186
186
|
}
|
|
187
187
|
|
|
188
188
|
.input {
|
|
189
|
-
font-family: Karla, -apple-system, BlinkMacSystemFont, '
|
|
190
|
-
font-size:
|
|
189
|
+
font-family: Karla, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
|
190
|
+
font-size: 1rem;
|
|
191
191
|
line-height: 1.5rem;
|
|
192
192
|
-webkit-font-smoothing: antialiased;
|
|
193
193
|
-moz-osx-font-smoothing: grayscale;
|
|
@@ -390,10 +390,6 @@ textarea.input {
|
|
|
390
390
|
background-color: rgb(var(--tone-neutral-08) / var(--tw-bg-opacity));
|
|
391
391
|
}
|
|
392
392
|
|
|
393
|
-
.text {
|
|
394
|
-
font-size: 1rem;
|
|
395
|
-
}
|
|
396
|
-
|
|
397
393
|
.text-tone-neutral-04 {
|
|
398
394
|
--tw-text-opacity: 1;
|
|
399
395
|
color: rgb(var(--tone-neutral-04) / var(--tw-text-opacity));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
|
|
3
|
-
function r(e){var t,f,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e))for(t=0;t<
|
|
3
|
+
function r(e){var t,f,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(f=r(e[t]))&&(n&&(n+=" "),n+=f);}else for(f in e)e[f]&&(n&&(n+=" "),n+=f);return n}function clsx(){for(var e,t,f=0,n="",o=arguments.length;f<o;f++)(e=arguments[f])&&(t=r(e))&&(n&&(n+=" "),n+=t);return n}
|
|
4
4
|
|
|
5
5
|
const miBaselineAdd = `<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path d="M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"/></svg>`;
|
|
6
6
|
|
|
@@ -12,7 +12,7 @@ const miBaselineRemove = `<svg xmlns="http://www.w3.org/2000/svg" width="24" hei
|
|
|
12
12
|
|
|
13
13
|
const miBaselineDone = `<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path d="M9 16.2L4.8 12l-1.4 1.4L9 19L21 7l-1.4-1.4L9 16.2z"/></svg>`;
|
|
14
14
|
|
|
15
|
-
const mdsInputCss = "@-webkit-keyframes focus-bounce {\n 0%, 75%, 100% {\n outline-offset: var(--magma-outline-focus-offset);\n }\n\n 50% {\n outline-offset: var(--magma-outline-blur-offset);\n }\n}\n @keyframes focus-bounce {\n 0%, 75%, 100% {\n outline-offset: var(--magma-outline-focus-offset);\n }\n\n 50% {\n outline-offset: var(--magma-outline-blur-offset);\n }\n}\n /* included for focus effect */\n@tailwind components;\n\n*, ::before, ::after {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n::-webkit-backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n::-ms-backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n::backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n.focus-bounce {\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.focus-bounce--focused,\n .focus-bounce: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.svg {\n display: -ms-flexbox;\n display: flex;\n}\n.svg svg {\n aspect-ratio: 1/1;\n height: 100%;\n width: 100%;\n}\n@tailwind utilities;\n\n/**\n * @prop --mds-input-background: Sets the background-color of the component\n * @prop --mds-input-icon-color: Sets the icon color of the component\n * @prop --mds-input-ring: Sets the box-shadow of the component's input\n * @prop --mds-input-shadow: Sets the box-shadow of the component's input\n * @prop --mds-input-tip-background: Sets the background color of the tip message at the bottom right of the component\n * @prop --mds-input-variant-color: Sets the variant colors of the component\n */\n\n:host {\n\n --mds-input-background: rgb(var(--tone-neutral));\n --mds-input-icon-color: var(--mds-input-variant-color);\n --mds-input-tip-background: 84 84 84;\n --mds-input-ring: 0 0 0 1px rgb(var(--mds-input-variant-color) / 0.1);\n --mds-input-shadow: 0 1px 3px 0 rgb(var(--mds-input-variant-color) / 0.1), 0 1px 2px 0 rgb(var(--mds-input-variant-color) / 0.06);\n --mds-input-variant-color: 0 0 0;\n --mds-input-controls-color: rgb(var(--tone-neutral-04));\n --mds-input-controls-border: 2px solid rgb(var(--tone-neutral-09));\n font-family: Karla, -apple-system, BlinkMacSystemFont, 'San Francisco', 'Segoe UI', 'Helvetica Neue', sans-serif;\n font-size: 16px;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n gap: 0.5rem;\n\n container-type: inline-size;\n display: -ms-flexbox;\n display: flex;\n position: relative;\n}\n\n:host( [typography=\"detail\"] ) .input {\n font-family: Karla, -apple-system, BlinkMacSystemFont, 'San Francisco', 'Segoe UI', 'Helvetica Neue', sans-serif;\n font-size: 16px;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n:host( [typography=\"snippet\"] ) .input {\n font-family: 'Roboto Mono', monospace;\n font-size: 16px;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n.input {\n font-family: Karla, -apple-system, BlinkMacSystemFont, 'San Francisco', 'Segoe UI', 'Helvetica Neue', sans-serif;\n font-size: 16px;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n margin: 0rem;\n border-radius: 0.5rem;\n padding-left: 1rem;\n padding-right: 1rem;\n padding-top: 0.75rem;\n padding-bottom: 0.75rem;\n -webkit-transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width, -webkit-box-shadow, -webkit-transform;\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 -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n background-color: var(--mds-input-background);\n border: 0;\n -webkit-box-shadow: var(--mds-input-ring), var(--mds-input-shadow);\n box-shadow: var(--mds-input-ring), var(--mds-input-shadow);\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: rgb(var(--tone-neutral-02));\n min-height: 3rem;\n overflow: hidden;\n text-overflow: ellipsis;\n width: 100%;\n}\n\n.input::-webkit-outer-spin-button,\n.input::-webkit-inner-spin-button {\n -webkit-appearance: none;\n appearance: none;\n display: none;\n margin: 0;\n}\n\ntextarea.input:active {\n -webkit-transition-property: none;\n transition-property: none;\n}\n\ntextarea.input {\n max-height: 16rem;\n min-height: 6rem;\n border-bottom-right-radius: 0;\n}\n\n.input:focus {\n outline: 2px solid transparent;\n outline-offset: 2px;\n -webkit-transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width, -webkit-box-shadow, -webkit-transform;\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 -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n --mds-input-ring: 0 0 0 3px rgb(var(--mds-input-variant-color) / 1);\n --mds-input-shadow: 0 4px 6px 3px rgb(var(--mds-input-variant-color) / 0.1), 0 2px 4px -1px rgb(var(--mds-input-variant-color) / 0.06);\n}\n\n.input:disabled {\n background-color: rgb(var(--tone-neutral-10));\n}\n\n.input:disabled::-moz-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled::-webkit-input-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled:-ms-input-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled::-ms-input-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled,\n.input:disabled::placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input.has-icon {\n padding-left: 2.75rem;\n}\n\n\n\n.icon {\n left: 0.75rem;\n top: 0.75rem;\n\n fill: rgb(var(--mds-input-icon-color));\n position: absolute;\n}\n\n.counter {\n border-left: var(--mds-input-controls-border);\n display: -ms-flexbox;\n display: flex;\n -ms-flex-direction: column;\n flex-direction: column;\n gap: 0;\n position: absolute;\n right: 0;\n}\n\n.counter-button {\n height: 1.5rem;\n width: 1.75rem;\n border-radius: 0.5rem;\n padding: 0rem;\n\n -ms-flex-align: center;\n\n align-items: center;\n background-color: transparent;\n border: 0;\n display: -ms-flexbox;\n display: flex;\n fill: var(--mds-input-controls-color);\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.counter-button:hover {\n background-color: rgb(var(--tone-neutral-09));\n}\n\n.counter .counter-button:first-child {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.counter .counter-button:last-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n}\n\n.counter-button--horizontal {\n height: 3rem;\n width: 3rem;\n\n bottom: 0;\n position: absolute;\n top: 0;\n}\n\n.counter-button--decrease {\n border-bottom-right-radius: 0;\n border-right: var(--mds-input-controls-border);\n border-top-right-radius: 0;\n left: 0;\n}\n\n.counter-button--increase {\n border-bottom-left-radius: 0;\n border-left: var(--mds-input-controls-border);\n border-top-left-radius: 0;\n right: 0;\n}\n\n:host( [type=\"number\"] ) .input {\n padding-right: 2rem;\n}\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"] ) .input {\n padding-left: 3.5rem;\n padding-right: 3.5rem;\n\n text-align: center;\n}\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"][icon] ) .input {\n padding-left: 6rem;\n\n text-align: left;\n}\n\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"] ) .icon {\n left: 3.75rem;\n}\n\n.fixed {\n position: fixed;\n}\n\n.absolute {\n position: absolute;\n}\n\n.grid {\n display: grid;\n}\n\n.w-min {\n width: -moz-min-content;\n width: -webkit-min-content;\n width: min-content;\n}\n\n.truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.rounded {\n border-radius: 0.25rem;\n}\n\n.border {\n border-width: 1px;\n}\n\n.bg-tone-neutral-08 {\n --tw-bg-opacity: 1;\n background-color: rgb(var(--tone-neutral-08) / var(--tw-bg-opacity));\n}\n\n.text {\n font-size: 1rem;\n}\n\n.text-tone-neutral-04 {\n --tw-text-opacity: 1;\n color: rgb(var(--tone-neutral-04) / var(--tw-text-opacity));\n}\n\n.shadow {\n --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);\n --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);\n -webkit-box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n:host {\n\n --mds-input-icon-color: var(--brand-maggioli-03);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( :focus ) {\n\n --mds-input-variant-color: var(--brand-maggioli-04);\n}\n\n:host( [variant=\"info\"] ) {\n\n --mds-input-icon-color: var(--status-info-05);\n --mds-input-tip-background: var(--status-info-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"info\"]:focus ) {\n\n --mds-input-icon-color: var(--status-info-04);\n --mds-input-variant-color: var(--status-info-05);\n}\n\n:host( [variant=\"success\"] ) {\n\n --mds-input-icon-color: var(--status-success-05);\n --mds-input-tip-background: var(--status-success-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"success\"]:focus ) {\n\n --mds-input-icon-color: var(--status-success-04);\n --mds-input-variant-color: var(--status-success-05);\n}\n\n:host( [variant=\"warning\"] ) {\n\n --mds-input-icon-color: var(--status-warning-05);\n --mds-input-tip-background: var(--status-warning-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"warning\"]:focus ) {\n\n --mds-input-icon-color: var(--status-warning-04);\n --mds-input-variant-color: var(--status-warning-05);\n}\n\n:host( [variant=\"error\"] ) {\n\n --mds-input-icon-color: var(--status-error-05);\n --mds-input-tip-background: var(--status-error-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"error\"]:focus ) {\n\n --mds-input-icon-color: var(--status-error-04);\n --mds-input-variant-color: var(--status-error-05);\n}\n\n.tip-container {\n left: 0.25rem;\n right: 0.25rem;\n gap: 0.25rem;\n -webkit-transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width, -webkit-box-shadow, -webkit-transform;\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 -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n display: -ms-flexbox;\n\n display: flex;\n -ms-flex-pack: end;\n justify-content: flex-end;\n pointer-events: none;\n position: absolute;\n}\n\n.tip-container:empty {\n display: none;\n}\n\n.tip-container--top {\n top: 0.25rem;\n}\n\n.tip-container--bottom {\n bottom: 0.25rem;\n}\n\n.tip {\n height: 0.75rem;\n border-radius: 0.375rem;\n -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n -ms-flex-align: center;\n\n align-items: center;\n background-color: rgb(var(--mds-input-tip-background));\n color: transparent;\n color: rgb(var(--tone-neutral));\n display: -ms-flexbox;\n display: flex;\n fill: rgb(var(--tone-neutral));\n -ms-flex-pack: center;\n justify-content: center;\n min-width: 0.75rem;\n padding: 0;\n pointer-events: none;\n position: static;\n text-align: center;\n -webkit-transform: translate(0, 0);\n transform: translate(0, 0);\n -webkit-transition-property: background-color, border-radius, color, padding-left, padding-right, -webkit-transform;\n transition-property: background-color, border-radius, color, padding-left, padding-right, -webkit-transform;\n transition-property: background-color, border-radius, color, padding-left, padding-right, transform;\n transition-property: background-color, border-radius, color, padding-left, padding-right, transform, -webkit-transform;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n\n.tip__content {\n height: 0.75rem;\n -webkit-transition-duration: 200ms;\n transition-duration: 200ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n display: grid;\n grid-template-columns: 0fr;\n opacity: 0;\n overflow: hidden;\n -webkit-transition-property: grid-template-columns, opacity;\n transition-property: grid-template-columns, opacity;\n transition-property: grid-template-columns, opacity, -ms-grid-columns;\n}\n\n.tip__text {\n -webkit-transform: translate(0, 1px);\n transform: translate(0, 1px);\n}\n\n.tip__icon {\n height: 0.75rem;\n width: 0.75rem;\n\n display: none;\n}\n\n:host(:focus-within) .tip-container--top {\n -webkit-transform: translate(calc(0.25rem * -1), calc(0.25rem * -1));\n transform: translate(calc(0.25rem * -1), calc(0.25rem * -1));\n}\n\n:host(:focus-within) .tip-container--bottom {\n -webkit-transform: translate(calc(0.25rem * -1), 0.25rem);\n transform: translate(calc(0.25rem * -1), 0.25rem);\n}\n\n:host(:focus-within) .tip-container--top .tip {\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n}\n\n:host(:focus-within) .tip-container--bottom .tip {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n}\n\n.tip--expanded,\n:host(:focus-within) .tip--expand {\n padding-left: 0.5rem;\n padding-right: 0.5rem;\n}\n\n.tip--expanded .tip__content,\n:host(:focus-within) .tip--expand .tip__content,\n:host( [value]:not([value=\"\"]) ) .tip--expand .tip__content {\n grid-template-columns: 1fr;\n opacity: 1;\n}\n\n:host( [value]:not([value=\"\"]) ) .tip--expand .tip__text {\n display: none;\n}\n\n:host( [value]:not([value=\"\"]) ) .tip__icon {\n display: -ms-flexbox;\n display: flex;\n}\n\n:host([value]:not([value=\"\"]):focus-within) .tip--expand {\n padding-left: 0;\n padding-right: 0;\n}\n\n:host( [type=\"number\"] ) .tip-container {\n right: 2.25rem;\n}\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"] ) .tip-container {\n left: 3.5rem;\n right: 3.5rem;\n}\n\n:host( [value]:not([value=\"\"]) ) .tip--required {\n\n --mds-input-tip-background: var(--status-success-05);\n}\n\n.tip--required {\n\n --mds-input-tip-background: var(--status-error-05);\n}\n\n.tip--read-only {\n\n --mds-input-tip-background: var(--status-info-05);\n}\n\n.tip--disabled {\n\n --mds-input-tip-background: var(--tone-neutral-05);\n}\n\n\n@container (max-width: 210px) {\n :host .tip__content,\n :host(:focus-within) .tip__content {\n grid-template-columns: 0fr;\n opacity: 0;\n }\n\n :host .tip {\n padding-left: 0;\n padding-right: 0;\n }\n\n :host {\n\n --mds-input-background: rgb(var(--brand-maggioli-07));\n }\n}\n";
|
|
15
|
+
const mdsInputCss = "@-webkit-keyframes focus-bounce {\n 0%, 75%, 100% {\n outline-offset: var(--magma-outline-focus-offset);\n }\n\n 50% {\n outline-offset: var(--magma-outline-blur-offset);\n }\n}\n @keyframes focus-bounce {\n 0%, 75%, 100% {\n outline-offset: var(--magma-outline-focus-offset);\n }\n\n 50% {\n outline-offset: var(--magma-outline-blur-offset);\n }\n}\n /* included for focus effect */\n@tailwind components;\n\n*, ::before, ::after {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n::-webkit-backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n::-ms-backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n\n::backdrop {\n --tw-border-spacing-x: 0;\n --tw-border-spacing-y: 0;\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-rotate: 0;\n --tw-skew-x: 0;\n --tw-skew-y: 0;\n --tw-scale-x: 1;\n --tw-scale-y: 1;\n --tw-pan-x: ;\n --tw-pan-y: ;\n --tw-pinch-zoom: ;\n --tw-scroll-snap-strictness: proximity;\n --tw-gradient-from-position: ;\n --tw-gradient-via-position: ;\n --tw-gradient-to-position: ;\n --tw-ordinal: ;\n --tw-slashed-zero: ;\n --tw-numeric-figure: ;\n --tw-numeric-spacing: ;\n --tw-numeric-fraction: ;\n --tw-ring-inset: ;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-color: rgb(59 130 246 / 0.5);\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-ring-shadow: 0 0 #0000;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-colored: 0 0 #0000;\n --tw-blur: ;\n --tw-brightness: ;\n --tw-contrast: ;\n --tw-grayscale: ;\n --tw-hue-rotate: ;\n --tw-invert: ;\n --tw-saturate: ;\n --tw-sepia: ;\n --tw-drop-shadow: ;\n --tw-backdrop-blur: ;\n --tw-backdrop-brightness: ;\n --tw-backdrop-contrast: ;\n --tw-backdrop-grayscale: ;\n --tw-backdrop-hue-rotate: ;\n --tw-backdrop-invert: ;\n --tw-backdrop-opacity: ;\n --tw-backdrop-saturate: ;\n --tw-backdrop-sepia: ;\n}\n.focus-bounce {\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.focus-bounce--focused,\n .focus-bounce: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.svg {\n display: -ms-flexbox;\n display: flex;\n}\n.svg svg {\n aspect-ratio: 1/1;\n height: 100%;\n width: 100%;\n}\n@tailwind utilities;\n\n/**\n * @prop --mds-input-background: Sets the background-color of the component\n * @prop --mds-input-icon-color: Sets the icon color of the component\n * @prop --mds-input-ring: Sets the box-shadow of the component's input\n * @prop --mds-input-shadow: Sets the box-shadow of the component's input\n * @prop --mds-input-tip-background: Sets the background color of the tip message at the bottom right of the component\n * @prop --mds-input-variant-color: Sets the variant colors of the component\n */\n\n:host {\n\n --mds-input-background: rgb(var(--tone-neutral));\n --mds-input-icon-color: var(--mds-input-variant-color);\n --mds-input-tip-background: 84 84 84;\n --mds-input-ring: 0 0 0 1px rgb(var(--mds-input-variant-color) / 0.1);\n --mds-input-shadow: 0 1px 3px 0 rgb(var(--mds-input-variant-color) / 0.1), 0 1px 2px 0 rgb(var(--mds-input-variant-color) / 0.06);\n --mds-input-variant-color: 0 0 0;\n --mds-input-controls-color: rgb(var(--tone-neutral-04));\n --mds-input-controls-border: 2px solid rgb(var(--tone-neutral-09));\n font-family: Karla, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;\n font-size: 1rem;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n gap: 0.5rem;\n\n container-type: inline-size;\n display: -ms-flexbox;\n display: flex;\n position: relative;\n}\n\n:host( [typography=\"detail\"] ) .input {\n font-family: Karla, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;\n font-size: 1rem;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n:host( [typography=\"snippet\"] ) .input {\n font-family: 'Roboto Mono', 'Courier New', monospace;\n font-size: 1rem;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n.input {\n font-family: Karla, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;\n font-size: 1rem;\n line-height: 1.5rem;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n margin: 0rem;\n border-radius: 0.5rem;\n padding-left: 1rem;\n padding-right: 1rem;\n padding-top: 0.75rem;\n padding-bottom: 0.75rem;\n -webkit-transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width, -webkit-box-shadow, -webkit-transform;\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 -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n background-color: var(--mds-input-background);\n border: 0;\n -webkit-box-shadow: var(--mds-input-ring), var(--mds-input-shadow);\n box-shadow: var(--mds-input-ring), var(--mds-input-shadow);\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: rgb(var(--tone-neutral-02));\n min-height: 3rem;\n overflow: hidden;\n text-overflow: ellipsis;\n width: 100%;\n}\n\n.input::-webkit-outer-spin-button,\n.input::-webkit-inner-spin-button {\n -webkit-appearance: none;\n appearance: none;\n display: none;\n margin: 0;\n}\n\ntextarea.input:active {\n -webkit-transition-property: none;\n transition-property: none;\n}\n\ntextarea.input {\n max-height: 16rem;\n min-height: 6rem;\n border-bottom-right-radius: 0;\n}\n\n.input:focus {\n outline: 2px solid transparent;\n outline-offset: 2px;\n -webkit-transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width, -webkit-box-shadow, -webkit-transform;\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 -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n --mds-input-ring: 0 0 0 3px rgb(var(--mds-input-variant-color) / 1);\n --mds-input-shadow: 0 4px 6px 3px rgb(var(--mds-input-variant-color) / 0.1), 0 2px 4px -1px rgb(var(--mds-input-variant-color) / 0.06);\n}\n\n.input:disabled {\n background-color: rgb(var(--tone-neutral-10));\n}\n\n.input:disabled::-moz-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled::-webkit-input-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled:-ms-input-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled::-ms-input-placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input:disabled,\n.input:disabled::placeholder {\n color: rgb(var(--tone-neutral-05));\n}\n\n.input.has-icon {\n padding-left: 2.75rem;\n}\n\n\n\n.icon {\n left: 0.75rem;\n top: 0.75rem;\n\n fill: rgb(var(--mds-input-icon-color));\n position: absolute;\n}\n\n.counter {\n border-left: var(--mds-input-controls-border);\n display: -ms-flexbox;\n display: flex;\n -ms-flex-direction: column;\n flex-direction: column;\n gap: 0;\n position: absolute;\n right: 0;\n}\n\n.counter-button {\n height: 1.5rem;\n width: 1.75rem;\n border-radius: 0.5rem;\n padding: 0rem;\n\n -ms-flex-align: center;\n\n align-items: center;\n background-color: transparent;\n border: 0;\n display: -ms-flexbox;\n display: flex;\n fill: var(--mds-input-controls-color);\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.counter-button:hover {\n background-color: rgb(var(--tone-neutral-09));\n}\n\n.counter .counter-button:first-child {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n border-top-left-radius: 0;\n}\n\n.counter .counter-button:last-child {\n border-bottom-left-radius: 0;\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n}\n\n.counter-button--horizontal {\n height: 3rem;\n width: 3rem;\n\n bottom: 0;\n position: absolute;\n top: 0;\n}\n\n.counter-button--decrease {\n border-bottom-right-radius: 0;\n border-right: var(--mds-input-controls-border);\n border-top-right-radius: 0;\n left: 0;\n}\n\n.counter-button--increase {\n border-bottom-left-radius: 0;\n border-left: var(--mds-input-controls-border);\n border-top-left-radius: 0;\n right: 0;\n}\n\n:host( [type=\"number\"] ) .input {\n padding-right: 2rem;\n}\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"] ) .input {\n padding-left: 3.5rem;\n padding-right: 3.5rem;\n\n text-align: center;\n}\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"][icon] ) .input {\n padding-left: 6rem;\n\n text-align: left;\n}\n\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"] ) .icon {\n left: 3.75rem;\n}\n\n.fixed {\n position: fixed;\n}\n\n.absolute {\n position: absolute;\n}\n\n.grid {\n display: grid;\n}\n\n.w-min {\n width: -moz-min-content;\n width: -webkit-min-content;\n width: min-content;\n}\n\n.truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.rounded {\n border-radius: 0.25rem;\n}\n\n.border {\n border-width: 1px;\n}\n\n.bg-tone-neutral-08 {\n --tw-bg-opacity: 1;\n background-color: rgb(var(--tone-neutral-08) / var(--tw-bg-opacity));\n}\n\n.text-tone-neutral-04 {\n --tw-text-opacity: 1;\n color: rgb(var(--tone-neutral-04) / var(--tw-text-opacity));\n}\n\n.shadow {\n --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);\n --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);\n -webkit-box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);\n}\n\n:host {\n\n --mds-input-icon-color: var(--brand-maggioli-03);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( :focus ) {\n\n --mds-input-variant-color: var(--brand-maggioli-04);\n}\n\n:host( [variant=\"info\"] ) {\n\n --mds-input-icon-color: var(--status-info-05);\n --mds-input-tip-background: var(--status-info-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"info\"]:focus ) {\n\n --mds-input-icon-color: var(--status-info-04);\n --mds-input-variant-color: var(--status-info-05);\n}\n\n:host( [variant=\"success\"] ) {\n\n --mds-input-icon-color: var(--status-success-05);\n --mds-input-tip-background: var(--status-success-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"success\"]:focus ) {\n\n --mds-input-icon-color: var(--status-success-04);\n --mds-input-variant-color: var(--status-success-05);\n}\n\n:host( [variant=\"warning\"] ) {\n\n --mds-input-icon-color: var(--status-warning-05);\n --mds-input-tip-background: var(--status-warning-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"warning\"]:focus ) {\n\n --mds-input-icon-color: var(--status-warning-04);\n --mds-input-variant-color: var(--status-warning-05);\n}\n\n:host( [variant=\"error\"] ) {\n\n --mds-input-icon-color: var(--status-error-05);\n --mds-input-tip-background: var(--status-error-05);\n --mds-input-variant-color: 0 0 0;\n}\n\n:host( [variant=\"error\"]:focus ) {\n\n --mds-input-icon-color: var(--status-error-04);\n --mds-input-variant-color: var(--status-error-05);\n}\n\n.tip-container {\n left: 0.25rem;\n right: 0.25rem;\n gap: 0.25rem;\n -webkit-transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, color, fill, height, margin, opacity, padding, width, -webkit-box-shadow, -webkit-transform;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width;\n transition-property: background-color, border-color, box-shadow, color, fill, height, margin, opacity, padding, transform, width, -webkit-box-shadow, -webkit-transform;\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 -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n display: -ms-flexbox;\n\n display: flex;\n -ms-flex-pack: end;\n justify-content: flex-end;\n pointer-events: none;\n position: absolute;\n}\n\n.tip-container:empty {\n display: none;\n}\n\n.tip-container--top {\n top: 0.25rem;\n}\n\n.tip-container--bottom {\n bottom: 0.25rem;\n}\n\n.tip {\n height: 0.75rem;\n border-radius: 0.375rem;\n -webkit-transition-duration: 300ms;\n transition-duration: 300ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n -ms-flex-align: center;\n\n align-items: center;\n background-color: rgb(var(--mds-input-tip-background));\n color: transparent;\n color: rgb(var(--tone-neutral));\n display: -ms-flexbox;\n display: flex;\n fill: rgb(var(--tone-neutral));\n -ms-flex-pack: center;\n justify-content: center;\n min-width: 0.75rem;\n padding: 0;\n pointer-events: none;\n position: static;\n text-align: center;\n -webkit-transform: translate(0, 0);\n transform: translate(0, 0);\n -webkit-transition-property: background-color, border-radius, color, padding-left, padding-right, -webkit-transform;\n transition-property: background-color, border-radius, color, padding-left, padding-right, -webkit-transform;\n transition-property: background-color, border-radius, color, padding-left, padding-right, transform;\n transition-property: background-color, border-radius, color, padding-left, padding-right, transform, -webkit-transform;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n\n.tip__content {\n height: 0.75rem;\n -webkit-transition-duration: 200ms;\n transition-duration: 200ms;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n\n display: grid;\n grid-template-columns: 0fr;\n opacity: 0;\n overflow: hidden;\n -webkit-transition-property: grid-template-columns, opacity;\n transition-property: grid-template-columns, opacity;\n transition-property: grid-template-columns, opacity, -ms-grid-columns;\n}\n\n.tip__text {\n -webkit-transform: translate(0, 1px);\n transform: translate(0, 1px);\n}\n\n.tip__icon {\n height: 0.75rem;\n width: 0.75rem;\n\n display: none;\n}\n\n:host(:focus-within) .tip-container--top {\n -webkit-transform: translate(calc(0.25rem * -1), calc(0.25rem * -1));\n transform: translate(calc(0.25rem * -1), calc(0.25rem * -1));\n}\n\n:host(:focus-within) .tip-container--bottom {\n -webkit-transform: translate(calc(0.25rem * -1), 0.25rem);\n transform: translate(calc(0.25rem * -1), 0.25rem);\n}\n\n:host(:focus-within) .tip-container--top .tip {\n border-top-left-radius: 0;\n border-top-right-radius: 0;\n}\n\n:host(:focus-within) .tip-container--bottom .tip {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n}\n\n.tip--expanded,\n:host(:focus-within) .tip--expand {\n padding-left: 0.5rem;\n padding-right: 0.5rem;\n}\n\n.tip--expanded .tip__content,\n:host(:focus-within) .tip--expand .tip__content,\n:host( [value]:not([value=\"\"]) ) .tip--expand .tip__content {\n grid-template-columns: 1fr;\n opacity: 1;\n}\n\n:host( [value]:not([value=\"\"]) ) .tip--expand .tip__text {\n display: none;\n}\n\n:host( [value]:not([value=\"\"]) ) .tip__icon {\n display: -ms-flexbox;\n display: flex;\n}\n\n:host([value]:not([value=\"\"]):focus-within) .tip--expand {\n padding-left: 0;\n padding-right: 0;\n}\n\n:host( [type=\"number\"] ) .tip-container {\n right: 2.25rem;\n}\n\n:host( [type=\"number\"][controls-layout=\"horizontal\"] ) .tip-container {\n left: 3.5rem;\n right: 3.5rem;\n}\n\n:host( [value]:not([value=\"\"]) ) .tip--required {\n\n --mds-input-tip-background: var(--status-success-05);\n}\n\n.tip--required {\n\n --mds-input-tip-background: var(--status-error-05);\n}\n\n.tip--read-only {\n\n --mds-input-tip-background: var(--status-info-05);\n}\n\n.tip--disabled {\n\n --mds-input-tip-background: var(--tone-neutral-05);\n}\n\n\n@container (max-width: 210px) {\n :host .tip__content,\n :host(:focus-within) .tip__content {\n grid-template-columns: 0fr;\n opacity: 0;\n }\n\n :host .tip {\n padding-left: 0;\n padding-right: 0;\n }\n\n :host {\n\n --mds-input-background: rgb(var(--brand-maggioli-07));\n }\n}\n";
|
|
16
16
|
|
|
17
17
|
const MdsInput$1 = /*@__PURE__*/ proxyCustomElement(class MdsInput extends HTMLElement {
|
|
18
18
|
constructor() {
|
package/dist/documentation.d.ts
CHANGED
|
@@ -60,30 +60,10 @@ interface ComponentCompilerEventComplexType {
|
|
|
60
60
|
}
|
|
61
61
|
interface ComponentCompilerMethodComplexType {
|
|
62
62
|
signature: string;
|
|
63
|
-
parameters:
|
|
63
|
+
parameters: JsonDocMethodParameter[];
|
|
64
64
|
references: ComponentCompilerTypeReferences;
|
|
65
65
|
return: string;
|
|
66
66
|
}
|
|
67
|
-
interface CompilerJsDoc {
|
|
68
|
-
/**
|
|
69
|
-
* The text associated with the JSDoc
|
|
70
|
-
*/
|
|
71
|
-
text: string;
|
|
72
|
-
/**
|
|
73
|
-
* Tags included in the JSDoc
|
|
74
|
-
*/
|
|
75
|
-
tags: CompilerJsDocTagInfo[];
|
|
76
|
-
}
|
|
77
|
-
interface CompilerJsDocTagInfo {
|
|
78
|
-
/**
|
|
79
|
-
* The name of the tag - e.g. `@deprecated`
|
|
80
|
-
*/
|
|
81
|
-
name: string;
|
|
82
|
-
/**
|
|
83
|
-
* Additional text that is associated with the tag - e.g. `@deprecated use v2 of this API`
|
|
84
|
-
*/
|
|
85
|
-
text?: string;
|
|
86
|
-
}
|
|
87
67
|
/**
|
|
88
68
|
* The Type Library holds information about the types which are used in a
|
|
89
69
|
* Stencil project. During compilation, Stencil gathers information about the
|