@mgdis/mg-components 5.25.2 → 5.26.0
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-0256ee6d.js → index-0a2783ee.js} +1 -1
- package/dist/cjs/{index-0256ee6d.js.map → index-0a2783ee.js.map} +1 -1
- package/dist/cjs/{index-f699ee11.js → index-c585c382.js} +37 -37
- package/dist/cjs/index-c585c382.js.map +1 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/mg-action-more_34.cjs.entry.js +89 -89
- package/dist/cjs/mg-action-more_34.cjs.entry.js.map +1 -1
- package/dist/cjs/mg-components.cjs.js +2 -2
- package/dist/cjs/mg-components.cjs.js.map +1 -1
- package/dist/cjs/mg-item-more.cjs.entry.js +3 -3
- package/dist/cjs/mg-loader.cjs.entry.js +3 -3
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/atoms/mg-badge/mg-badge.js +2 -2
- package/dist/collection/components/atoms/mg-badge/mg-badge.js.map +1 -1
- package/dist/components/MgInput.js +3 -3
- package/dist/components/index.es.js +29 -29
- package/dist/components/index.es.js.map +1 -1
- package/dist/components/index2.js +2 -2
- package/dist/components/mg-action-more.js +2 -2
- package/dist/components/mg-badge2.js +4 -4
- package/dist/components/mg-badge2.js.map +1 -1
- package/dist/components/mg-button2.js +4 -4
- package/dist/components/mg-card2.js +2 -2
- package/dist/components/mg-details.js +2 -2
- package/dist/components/mg-form.js +3 -3
- package/dist/components/mg-icon2.js +2 -2
- package/dist/components/mg-illustrated-message.js +2 -2
- package/dist/components/mg-input-checkbox.js +4 -4
- package/dist/components/mg-input-date.js +11 -11
- package/dist/components/mg-input-numeric.js +5 -5
- package/dist/components/mg-input-password.js +3 -3
- package/dist/components/mg-input-radio.js +4 -4
- package/dist/components/mg-input-select2.js +6 -6
- package/dist/components/mg-input-text2.js +6 -6
- package/dist/components/mg-input-textarea.js +6 -6
- package/dist/components/mg-input-title2.js +2 -2
- package/dist/components/mg-input-toggle.js +4 -4
- package/dist/components/mg-item-more.js +2 -2
- package/dist/components/mg-loader.js +2 -2
- package/dist/components/mg-menu-item2.js +4 -4
- package/dist/components/mg-message.js +3 -3
- package/dist/components/mg-modal.js +6 -6
- package/dist/components/mg-pagination2.js +2 -2
- package/dist/components/mg-panel.js +4 -4
- package/dist/components/mg-popover-content2.js +3 -3
- package/dist/components/mg-popover2.js +3 -3
- package/dist/components/mg-skip-links.js +2 -2
- package/dist/components/mg-tabs.js +6 -6
- package/dist/components/mg-tag.js +3 -3
- package/dist/components/mg-tooltip2.js +6 -6
- package/dist/esm/{index-4ad17402.js → index-ad78ece7.js} +1 -1
- package/dist/esm/{index-4ad17402.js.map → index-ad78ece7.js.map} +1 -1
- package/dist/esm/{index-d2fc6ec0.js → index-bb17de92.js} +31 -31
- package/dist/esm/index-bb17de92.js.map +1 -0
- package/dist/esm/loader.js +2 -2
- package/dist/esm/mg-action-more_34.entry.js +89 -89
- package/dist/esm/mg-action-more_34.entry.js.map +1 -1
- package/dist/esm/mg-components.js +3 -3
- package/dist/esm/mg-components.js.map +1 -1
- package/dist/esm/mg-item-more.entry.js +3 -3
- package/dist/esm/mg-loader.entry.js +3 -3
- package/dist/mg-components/mg-components.esm.js +1 -1
- package/dist/mg-components/mg-components.esm.js.map +1 -1
- package/dist/mg-components/{p-568c9ea9.entry.js → p-2db8355d.entry.js} +2 -2
- package/dist/mg-components/p-95653110.entry.js +2 -0
- package/dist/mg-components/p-95653110.entry.js.map +1 -0
- package/dist/mg-components/{p-f761ebcd.js → p-bc62d75e.js} +1 -1
- package/dist/mg-components/{p-f761ebcd.js.map → p-bc62d75e.js.map} +1 -1
- package/dist/mg-components/{p-29b5a514.js → p-d41aa78b.js} +2 -2
- package/dist/mg-components/p-d41aa78b.js.map +1 -0
- package/dist/mg-components/{p-22f575c5.entry.js → p-d80b844d.entry.js} +2 -2
- package/dist/types/components/atoms/mg-badge/mg-badge.d.ts +1 -1
- package/dist/types/components.d.ts +2 -2
- package/ide/intellij/web-types.json +5810 -0
- package/ide/vscode/html-custom-data.json +5083 -0
- package/package.json +21 -14
- package/dist/cjs/index-f699ee11.js.map +0 -1
- package/dist/esm/index-d2fc6ec0.js.map +0 -1
- package/dist/mg-components/p-29b5a514.js.map +0 -1
- package/dist/mg-components/p-57614d95.entry.js +0 -2
- package/dist/mg-components/p-57614d95.entry.js.map +0 -1
- /package/dist/mg-components/{p-568c9ea9.entry.js.map → p-2db8355d.entry.js.map} +0 -0
- /package/dist/mg-components/{p-22f575c5.entry.js.map → p-d80b844d.entry.js.map} +0 -0
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-0a2783ee.js');
|
|
6
6
|
const appGlobals = require('./app-globals-3a1e7e63.js');
|
|
7
7
|
|
|
8
8
|
/*
|
|
9
|
-
Stencil Client Patch Browser v4.12.
|
|
9
|
+
Stencil Client Patch Browser v4.12.6 | MIT Licensed | https://stenciljs.com
|
|
10
10
|
*/
|
|
11
11
|
const patchBrowser = () => {
|
|
12
12
|
const importMeta = (typeof document === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : (document.currentScript && document.currentScript.src || new URL('mg-components.cjs.js', document.baseURI).href));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"mg-components.cjs.js","mappings":";;;;;;;AAAA;AACA;AACA;AAGA,MAAM,YAAY,GAAG,MAAM;AAa3B,IAAI,MAAM,UAAU,GAAG,+MAAe,CAAC;AACvC,IAAI,MAAM,IAAI,GAAiE,EAAE,CAAC;AAClF,IAAI,IAAI,UAAU,KAAK,EAAE,EAAE;AAC3B,QAAQ,IAAI,CAAC,YAAY,GAAG,IAAI,GAAG,CAAC,GAAG,EAAE,UAAU,CAAC,CAAC,IAAI,CAAC;AAC1D,KAAK;AACL,IAAI,OAAOA,oBAAc,CAAC,IAAI,CAAC,CAAC;AAChC,CAAC;;ACpBD,YAAY,EAAE,CAAC,IAAI,CAAC,OAAO,OAAO,KAAK;AACvC,EAAE,MAAMC,wBAAa,EAAE,CAAC;AACxB,EAAE,OAAOC,mBAAa,CAAC,4BAA4B,EAAE,OAAO,CAAC,CAAC;AAC9D,CAAC,CAAC;;;;","names":["promiseResolve","globalScripts","bootstrapLazy"],"sources":["../../node_modules/.pnpm/@stencil+core@4.12.
|
|
1
|
+
{"file":"mg-components.cjs.js","mappings":";;;;;;;AAAA;AACA;AACA;AAGA,MAAM,YAAY,GAAG,MAAM;AAa3B,IAAI,MAAM,UAAU,GAAG,+MAAe,CAAC;AACvC,IAAI,MAAM,IAAI,GAAiE,EAAE,CAAC;AAClF,IAAI,IAAI,UAAU,KAAK,EAAE,EAAE;AAC3B,QAAQ,IAAI,CAAC,YAAY,GAAG,IAAI,GAAG,CAAC,GAAG,EAAE,UAAU,CAAC,CAAC,IAAI,CAAC;AAC1D,KAAK;AACL,IAAI,OAAOA,oBAAc,CAAC,IAAI,CAAC,CAAC;AAChC,CAAC;;ACpBD,YAAY,EAAE,CAAC,IAAI,CAAC,OAAO,OAAO,KAAK;AACvC,EAAE,MAAMC,wBAAa,EAAE,CAAC;AACxB,EAAE,OAAOC,mBAAa,CAAC,4BAA4B,EAAE,OAAO,CAAC,CAAC;AAC9D,CAAC,CAAC;;;;","names":["promiseResolve","globalScripts","bootstrapLazy"],"sources":["../../node_modules/.pnpm/@stencil+core@4.12.6/node_modules/@stencil/core/internal/client/patch-browser.js","@lazy-browser-entrypoint?app-data=conditional"],"sourcesContent":["/*\n Stencil Client Patch Browser v4.12.6 | MIT Licensed | https://stenciljs.com\n */\nimport { BUILD, NAMESPACE } from '@stencil/core/internal/app-data';\nimport { consoleDevInfo, doc, promiseResolve, H } from '@stencil/core';\nconst patchBrowser = () => {\n // NOTE!! This fn cannot use async/await!\n if (BUILD.isDev && !BUILD.isTesting) {\n consoleDevInfo('Running in development mode.');\n }\n if (BUILD.cloneNodeFix) {\n // opted-in to polyfill cloneNode() for slot polyfilled components\n patchCloneNodeFix(H.prototype);\n }\n const scriptElm = BUILD.scriptDataOpts\n ? Array.from(doc.querySelectorAll('script')).find((s) => new RegExp(`\\/${NAMESPACE}(\\\\.esm)?\\\\.js($|\\\\?|#)`).test(s.src) ||\n s.getAttribute('data-stencil-namespace') === NAMESPACE)\n : null;\n const importMeta = import.meta.url;\n const opts = BUILD.scriptDataOpts ? (scriptElm || {})['data-opts'] || {} : {};\n if (importMeta !== '') {\n opts.resourcesUrl = new URL('.', importMeta).href;\n }\n return promiseResolve(opts);\n};\nconst patchCloneNodeFix = (HTMLElementPrototype) => {\n const nativeCloneNodeFn = HTMLElementPrototype.cloneNode;\n HTMLElementPrototype.cloneNode = function (deep) {\n if (this.nodeName === 'TEMPLATE') {\n return nativeCloneNodeFn.call(this, deep);\n }\n const clonedNode = nativeCloneNodeFn.call(this, false);\n const srcChildNodes = this.childNodes;\n if (deep) {\n for (let i = 0; i < srcChildNodes.length; i++) {\n // Node.ATTRIBUTE_NODE === 2, and checking because IE11\n if (srcChildNodes[i].nodeType !== 2) {\n clonedNode.appendChild(srcChildNodes[i].cloneNode(true));\n }\n }\n }\n return clonedNode;\n };\n};\nexport { patchBrowser };\n","export { setNonce } from '@stencil/core';\nimport { bootstrapLazy } from '@stencil/core';\nimport { patchBrowser } from '@stencil/core/internal/client/patch-browser';\nimport { globalScripts } from '@stencil/core/internal/app-globals';\npatchBrowser().then(async (options) => {\n await globalScripts();\n return bootstrapLazy([/*!__STENCIL_LAZY_DATA__*/], options);\n});\n"],"version":3}
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const index$1 = require('./index-
|
|
5
|
+
const index = require('./index-0a2783ee.js');
|
|
6
|
+
const index$1 = require('./index-c585c382.js');
|
|
7
7
|
const mgMenu_conf = require('./mg-menu.conf-c291eee6.js');
|
|
8
8
|
|
|
9
9
|
/**
|
|
@@ -180,7 +180,7 @@ const MgItemMore = class {
|
|
|
180
180
|
navElement.click();
|
|
181
181
|
});
|
|
182
182
|
// add id suffix to prevent duplicate key. default html id is: '';
|
|
183
|
-
if (index$1.
|
|
183
|
+
if (index$1.Be(proxy.id))
|
|
184
184
|
proxy.id = `${proxy.id}-proxy`;
|
|
185
185
|
// manage status change miror in proxy
|
|
186
186
|
allMenuItem[index].addEventListener('status-change', (event) => {
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const index$1 = require('./index-
|
|
5
|
+
const index = require('./index-0a2783ee.js');
|
|
6
|
+
const index$1 = require('./index-c585c382.js');
|
|
7
7
|
|
|
8
8
|
const mgLoaderCss = ".mg-u-visually-hidden{position:absolute !important;overflow:hidden !important;width:.1rem !important;height:.1rem !important;padding:0 !important;border:0 !important;margin:-0.1rem !important;clip:rect(0.1rem, 0.1rem, 0.1rem, 0.1rem) !important;clip-path:inset(50%) !important;white-space:nowrap !important}*:focus:not(:focus-visible){outline:none}@media (prefers-reduced-motion){*{animation:none !important;transition:none !important}}:host{display:block}.mg-c-loader{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:.4rem;text-align:center}";
|
|
9
9
|
const MgLoaderStyle0 = mgLoaderCss;
|
|
@@ -15,7 +15,7 @@ const MgLoader = class {
|
|
|
15
15
|
this.messageHide = undefined;
|
|
16
16
|
}
|
|
17
17
|
watchMessage(newValue) {
|
|
18
|
-
if (newValue && !index$1.
|
|
18
|
+
if (newValue && !index$1.Be(newValue))
|
|
19
19
|
throw new Error('<mg-loader> prop "message" must be a valid string.');
|
|
20
20
|
}
|
|
21
21
|
/*************
|
|
@@ -55,7 +55,7 @@ export class MgBadge {
|
|
|
55
55
|
* @returns HTML Element
|
|
56
56
|
*/
|
|
57
57
|
render() {
|
|
58
|
-
return (h("span", { key: '
|
|
58
|
+
return (h("span", { key: 'f6f1baa91f4a9e55af711f0a84eaca74b97962b3', class: this.classCollection.join() }, h("span", { key: '9c61217b74129839f600617d5e6e6bc7a2863667', class: "mg-c-badge__value" }, this.value), h("span", { key: '2fd7529d5d9a9b32da2c4a80a70a09396ffb9100', class: "mg-u-visually-hidden" }, this.label)));
|
|
59
59
|
}
|
|
60
60
|
static get is() { return "mg-badge"; }
|
|
61
61
|
static get encapsulation() { return "shadow"; }
|
|
@@ -123,7 +123,7 @@ export class MgBadge {
|
|
|
123
123
|
"optional": true,
|
|
124
124
|
"docs": {
|
|
125
125
|
"tags": [],
|
|
126
|
-
"text": "Define
|
|
126
|
+
"text": "Define badge variant"
|
|
127
127
|
},
|
|
128
128
|
"attribute": "variant",
|
|
129
129
|
"reflect": false,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mg-badge.js","sourceRoot":"","sources":["../../../../src/components/atoms/mg-badge/mg-badge.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACjE,OAAO,EAAE,QAAQ,EAAoB,MAAM,iBAAiB,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAMlE,MAAM,OAAO,OAAO;;QAClB;;sBAEc;QAEd,UAAU;QACO,iBAAY,GAAG,qBAAqB,CAAC;;;uBAgCjB,QAAQ,CAAC,CAAC,CAAC;;+BA0BV,IAAI,SAAS,CAAC,CAAC,YAAY,CAAC,CAAC;;IA/CnE,aAAa,CAAC,QAA0B;QACtC,IAAI,sBAAsB,CAAC,IAAI,CAAC,GAAG,QAAQ,EAAE,CAAC,KAAK,IAAI,EAAE,CAAC;YACxD,MAAM,IAAI,KAAK,CAAC,mEAAmE,CAAC,CAAC;QACvF,CAAC;IACH,CAAC;IAQD,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,KAAK,CAAQ;YACnD,6DAAM,KAAK,EAAC,sBAAsB,IAAE,IAAI,CAAC,KAAK,CAAQ,CACjD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Prop, State, Watch } from '@stencil/core';\nimport { variants, BadgeVariantType } from './mg-badge.conf';\nimport { ClassList, isValidString } from '@mgdis/stencil-helpers';\n@Component({\n tag: 'mg-badge',\n styleUrl: '../../../../node_modules/@mgdis/styles/dist/components/mg-badge.css',\n shadow: true,\n})\nexport class MgBadge {\n /************\n * Internal *\n ************/\n\n // Classes\n private readonly classOutline = `mg-c-badge--outline`;\n\n /**************\n * Decorators *\n **************/\n\n /**\n * Badge value\n */\n @Prop() value!: string | number;\n @Watch('value')\n validateValue(newValue: MgBadge['value']): void {\n if (/^(\\d+\\+*|[?*!a-z])$/i.exec(`${newValue}`) === null) {\n throw new Error('<mg-badge> prop \"value\" must be integer or ponctuation character.');\n }\n }\n\n /**\n * Badge label. Include short description.\n * Required for accessibility\n */\n @Prop() label!: string;\n @Watch('label')\n validateLabel(newValue: MgBadge['label']): void {\n if (!isValidString(newValue)) {\n throw new Error('<mg-badge> prop \"label\" is required.');\n }\n }\n\n /**\n * Define
|
|
1
|
+
{"version":3,"file":"mg-badge.js","sourceRoot":"","sources":["../../../../src/components/atoms/mg-badge/mg-badge.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACjE,OAAO,EAAE,QAAQ,EAAoB,MAAM,iBAAiB,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAMlE,MAAM,OAAO,OAAO;;QAClB;;sBAEc;QAEd,UAAU;QACO,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C,IAAI,CAAC,KAAK,CAAC,CAAC;QAC/B,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACnC,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IACrC,CAAC;IAED;;;OAGG;IACH,MAAM;QACJ,OAAO,CACL,6DAAM,KAAK,EAAE,IAAI,CAAC,eAAe,CAAC,IAAI,EAAE;YACtC,6DAAM,KAAK,EAAC,mBAAmB,IAAE,IAAI,CAAC,KAAK,CAAQ;YACnD,6DAAM,KAAK,EAAC,sBAAsB,IAAE,IAAI,CAAC,KAAK,CAAQ,CACjD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Prop, State, Watch } from '@stencil/core';\nimport { variants, BadgeVariantType } from './mg-badge.conf';\nimport { ClassList, isValidString } from '@mgdis/stencil-helpers';\n@Component({\n tag: 'mg-badge',\n styleUrl: '../../../../node_modules/@mgdis/styles/dist/components/mg-badge.css',\n shadow: true,\n})\nexport class MgBadge {\n /************\n * Internal *\n ************/\n\n // Classes\n private readonly classOutline = `mg-c-badge--outline`;\n\n /**************\n * Decorators *\n **************/\n\n /**\n * Badge value\n */\n @Prop() value!: string | number;\n @Watch('value')\n validateValue(newValue: MgBadge['value']): void {\n if (/^(\\d+\\+*|[?*!a-z])$/i.exec(`${newValue}`) === null) {\n throw new Error('<mg-badge> prop \"value\" must be integer or ponctuation character.');\n }\n }\n\n /**\n * Badge label. Include short description.\n * Required for accessibility\n */\n @Prop() label!: string;\n @Watch('label')\n validateLabel(newValue: MgBadge['label']): void {\n if (!isValidString(newValue)) {\n throw new Error('<mg-badge> prop \"label\" is required.');\n }\n }\n\n /**\n * Define badge variant\n */\n @Prop() variant?: BadgeVariantType = variants[0]; // info\n @Watch('variant')\n validateVariant(newValue: MgBadge['variant'], oldValue?: MgBadge['variant']): void {\n if (!variants.includes(newValue)) {\n throw new Error(`<mg-badge> prop \"variant\" must be one of: ${variants.join(', ')}.`);\n } else {\n if (oldValue !== undefined) {\n this.classCollection.delete(`mg-c-badge--${oldValue}`);\n }\n this.classCollection.add(`mg-c-badge--${newValue}`);\n }\n }\n\n /**\n * Define if button is using outline style\n */\n @Prop() outline: boolean;\n @Watch('outline')\n validateOutline(newValue: MgBadge['outline']): void {\n if (newValue) this.classCollection.add(this.classOutline);\n else this.classCollection.delete(this.classOutline);\n }\n\n /**\n * Component classes\n */\n @State() classCollection: ClassList = new ClassList(['mg-c-badge']);\n\n /**\n * Check if props are well configured on init\n */\n componentWillLoad(): void {\n this.validateValue(this.value);\n this.validateLabel(this.label);\n this.validateVariant(this.variant);\n this.validateOutline(this.outline);\n }\n\n /**\n * Render\n * @returns HTML Element\n */\n render(): HTMLElement {\n return (\n <span class={this.classCollection.join()}>\n <span class=\"mg-c-badge__value\">{this.value}</span>\n <span class=\"mg-u-visually-hidden\">{this.label}</span>\n </span>\n );\n }\n}\n"]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { B as Be } from './index.es.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Possible input width
|
|
@@ -56,10 +56,10 @@ const manageClasses = (props) => {
|
|
|
56
56
|
* @param props - MgInput Interface Props
|
|
57
57
|
*/
|
|
58
58
|
const checkPropsConfig = (props) => {
|
|
59
|
-
if (!
|
|
59
|
+
if (!Be(props.identifier)) {
|
|
60
60
|
throw new Error('<mg-input> prop "identifier" is required.');
|
|
61
61
|
}
|
|
62
|
-
if (!
|
|
62
|
+
if (!Be(props.label)) {
|
|
63
63
|
throw new Error('<mg-input> prop "label" is required.');
|
|
64
64
|
}
|
|
65
65
|
if (props.labelOnTop && props.labelHide) {
|
|
@@ -1,39 +1,30 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
const
|
|
5
|
-
const e = { value: "2023", pattern: "yyyy" }, n = { value: "12", pattern: "mm" }, s = { value: "24", pattern: "dd" };
|
|
6
|
-
return be([e.value, n.value, s.value].join("-"), t).replace(e.value, e.pattern).replace(n.value, n.pattern).replace(s.value, s.pattern);
|
|
7
|
-
}, Ae = (t) => t.toISOString().split("T")[0], ve = (t, e, n) => {
|
|
8
|
-
const s = t.closest("[lang]"), l = Intl.NumberFormat.supportedLocalesOf(s == null ? void 0 : s.lang), r = l.length > 0 && typeof l[0] == "string" ? l[0] : navigator.language || n, o = r.split("-").shift();
|
|
9
|
-
return {
|
|
10
|
-
locale: r,
|
|
11
|
-
messages: e[o] || e[n]
|
|
12
|
-
};
|
|
13
|
-
}, Re = (t, e, n) => new Intl.NumberFormat(e, { style: "currency", currency: n }).format(t), Me = (t, e) => new Intl.NumberFormat(e).format(t), Se = /^\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\d|3[01])$/, be = (t, e) => typeof t != "string" || t === "" || !Se.test(t) ? "" : new Intl.DateTimeFormat(e).format(new Date(t)), Oe = (t, e) => (n) => ve(n, t, e), je = (t = "", e = 10) => {
|
|
1
|
+
var ie = Object.defineProperty;
|
|
2
|
+
var ce = (t, e, n) => e in t ? ie(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
|
|
3
|
+
var p = (t, e, n) => (ce(t, typeof e != "symbol" ? e + "" : e, n), n);
|
|
4
|
+
const Re = (t = "", e = 10) => {
|
|
14
5
|
const n = new Uint8Array(e);
|
|
15
6
|
crypto.getRandomValues(n);
|
|
16
|
-
const
|
|
17
|
-
return t !== "" ? `${t}-${
|
|
7
|
+
const r = Array.from(n).map((s) => s.toString(16).padStart(2, "0")).join("").slice(0, e);
|
|
8
|
+
return t !== "" ? `${t}-${r}` : r;
|
|
18
9
|
};
|
|
19
|
-
class
|
|
10
|
+
class Me {
|
|
20
11
|
constructor(e = []) {
|
|
21
12
|
/**
|
|
22
13
|
* Available classes
|
|
23
14
|
*/
|
|
24
|
-
|
|
15
|
+
p(this, "classes");
|
|
25
16
|
/**
|
|
26
17
|
* Add class
|
|
27
18
|
* @param className - class name to add
|
|
28
19
|
*/
|
|
29
|
-
|
|
20
|
+
p(this, "add", (e) => {
|
|
30
21
|
this.has(e) || this.classes.push(e);
|
|
31
22
|
});
|
|
32
23
|
/**
|
|
33
24
|
* Delete class
|
|
34
25
|
* @param className - class name to delete
|
|
35
26
|
*/
|
|
36
|
-
|
|
27
|
+
p(this, "delete", (e) => {
|
|
37
28
|
const n = this.classes.indexOf(e);
|
|
38
29
|
n > -1 && this.classes.splice(n, 1);
|
|
39
30
|
});
|
|
@@ -42,34 +33,43 @@ class Fe {
|
|
|
42
33
|
* @param className - class name to check
|
|
43
34
|
* @returns class name is in the list
|
|
44
35
|
*/
|
|
45
|
-
|
|
36
|
+
p(this, "has", (e) => this.classes.includes(e));
|
|
46
37
|
/**
|
|
47
38
|
* Join classes seperated by spaces
|
|
48
39
|
* @returns joined values
|
|
49
40
|
*/
|
|
50
|
-
|
|
41
|
+
p(this, "join", () => this.classes.join(" "));
|
|
51
42
|
this.classes = e;
|
|
52
43
|
}
|
|
53
44
|
}
|
|
54
|
-
const
|
|
55
|
-
const e =
|
|
45
|
+
const Oe = (t) => Array.isArray(t) && t.every((e) => typeof e == "string"), Fe = (t, e) => e.includes(t == null ? void 0 : t.tagName.toLowerCase()), De = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]), [identifier], mg-button', _e = (t) => {
|
|
46
|
+
const e = G(t), n = I(t);
|
|
56
47
|
return [t, ...e, ...n];
|
|
57
|
-
},
|
|
48
|
+
}, G = (t, e = []) => {
|
|
58
49
|
if (t.self !== t.top)
|
|
59
50
|
try {
|
|
60
51
|
const n = t.parent;
|
|
61
|
-
return n ? (e.push(n),
|
|
52
|
+
return n ? (e.push(n), G(n, e)) : e;
|
|
62
53
|
} catch (n) {
|
|
63
54
|
return console.error("Different hosts between iframes:", n), e;
|
|
64
55
|
}
|
|
65
56
|
return e;
|
|
66
|
-
},
|
|
57
|
+
}, I = (t, e = []) => {
|
|
67
58
|
if (t.frames.length > 0)
|
|
68
59
|
for (const n of Array.from(t.frames))
|
|
69
|
-
e.push(n),
|
|
60
|
+
e.push(n), I(n, e);
|
|
70
61
|
return e;
|
|
71
|
-
},
|
|
62
|
+
}, Be = (t) => typeof t == "string" && t.trim() !== "", Ne = (t) => typeof t == "string" ? t.toLocaleLowerCase().normalize("NFD").replaceAll(/[\u0300-\u036f]/g, "") : t, Ue = async (t) => t(), Pe = (t) => {
|
|
63
|
+
const e = { value: "2023", pattern: "yyyy" }, n = { value: "12", pattern: "mm" }, r = { value: "24", pattern: "dd" };
|
|
64
|
+
return ge([e.value, n.value, r.value].join("-"), t).replace(e.value, e.pattern).replace(n.value, n.pattern).replace(r.value, r.pattern);
|
|
65
|
+
}, We = (t) => t.toISOString().split("T")[0], ue = (t, e, n) => {
|
|
66
|
+
const r = t.closest("[lang]"), s = Intl.NumberFormat.supportedLocalesOf(r == null ? void 0 : r.lang), o = s.length > 0 && typeof s[0] == "string" ? s[0] : navigator.language || n, l = o.split("-").shift();
|
|
67
|
+
return {
|
|
68
|
+
locale: o,
|
|
69
|
+
messages: e[l] || e[n]
|
|
70
|
+
};
|
|
71
|
+
}, ze = (t, e, n) => new Intl.NumberFormat(e, { style: "currency", currency: n }).format(t), qe = (t, e) => new Intl.NumberFormat(e).format(t), de = /^\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\d|3[01])$/, ge = (t, e) => typeof t != "string" || t === "" || !de.test(t) ? "" : new Intl.DateTimeFormat(e).format(new Date(t)), we = (t, e) => (n) => ue(n, t, e);
|
|
72
72
|
|
|
73
|
-
export {
|
|
73
|
+
export { Be as B, De as D, Fe as F, Me as M, Ne as N, Oe as O, Pe as P, Re as R, Ue as U, We as W, _e as _, de as d, ge as g, qe as q, we as w, ze as z };
|
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AC,CAAC,EAAE,GAAG,OAAO,CAAC,KAAK,CAAC,EAAE;;;;","names":[],"sources":["../stencil-helpers/dist/index.es.js"],"sourcesContent":["var le = Object.defineProperty;\nvar oe = (t, e, n) => e in t ? le(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;\nvar g = (t, e, n) => (oe(t, typeof e != \"symbol\" ? e + \"\" : e, n), n);\nconst X = {\n allRenderFn: !1,\n cmpDidLoad: !0,\n cmpDidUnload: !1,\n cmpDidUpdate: !0,\n cmpDidRender: !0,\n cmpWillLoad: !0,\n cmpWillUpdate: !0,\n cmpWillRender: !0,\n connectedCallback: !0,\n disconnectedCallback: !0,\n element: !0,\n event: !0,\n hasRenderFn: !0,\n lifecycle: !0,\n hostListener: !0,\n hostListenerTargetWindow: !0,\n hostListenerTargetDocument: !0,\n hostListenerTargetBody: !0,\n hostListenerTargetParent: !1,\n hostListenerTarget: !0,\n member: !0,\n method: !0,\n mode: !0,\n observeAttribute: !0,\n prop: !0,\n propMutable: !0,\n reflect: !0,\n scoped: !0,\n shadowDom: !0,\n slot: !0,\n cssAnnotations: !0,\n state: !0,\n style: !0,\n formAssociated: !1,\n svg: !0,\n updatable: !0,\n vdomAttribute: !0,\n vdomXlink: !0,\n vdomClass: !0,\n vdomFunctional: !0,\n vdomKey: !0,\n vdomListener: !0,\n vdomRef: !0,\n vdomPropOrAttr: !0,\n vdomRender: !0,\n vdomStyle: !0,\n vdomText: !0,\n watchCallback: !0,\n taskQueue: !0,\n hotModuleReplacement: !1,\n isDebug: !1,\n isDev: !1,\n isTesting: !1,\n hydrateServerSide: !1,\n hydrateClientSide: !1,\n lifecycleDOMEvents: !1,\n lazyLoad: !1,\n profile: !1,\n slotRelocation: !0,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n appendChildSlotFix: !1,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n cloneNodeFix: !1,\n hydratedAttribute: !1,\n hydratedClass: !0,\n scriptDataOpts: !1,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n scopedSlotTextContentFix: !1,\n // TODO(STENCIL-854): Remove code related to legacy shadowDomShim field\n shadowDomShim: !1,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n slotChildNodesFix: !1,\n invisiblePrehydration: !0,\n propBoolean: !0,\n propNumber: !0,\n propString: !0,\n constructableCSS: !0,\n cmpShouldUpdate: !0,\n devTools: !1,\n shadowDelegatesFocus: !0,\n initializeNextTick: !1,\n asyncLoading: !1,\n asyncQueue: !1,\n transformTagName: !1,\n attachStyles: !0,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n experimentalSlotFixes: !1\n};\nlet T, F, m, D = !1, M = !1, _ = !1, h = !1;\nconst H = \"http://www.w3.org/1999/xlink\", C = {}, re = \"http://www.w3.org/2000/svg\", ie = \"http://www.w3.org/1999/xhtml\", ce = (t) => t != null, q = (t) => (t = typeof t, t === \"object\" || t === \"function\"), G = (t, e, ...n) => {\n let s = null, l = null, r = null, o = !1, c = !1;\n const i = [], d = (f) => {\n for (let $ = 0; $ < f.length; $++)\n s = f[$], Array.isArray(s) ? d(s) : s != null && typeof s != \"boolean\" && ((o = typeof t != \"function\" && !q(s)) && (s = String(s)), o && c ? i[i.length - 1].$text$ += s : i.push(o ? O(null, s) : s), c = o);\n };\n if (d(n), e) {\n e.key && (l = e.key), e.name && (r = e.name);\n {\n const f = e.className || e.class;\n f && (e.class = typeof f != \"object\" ? f : Object.keys(f).filter(($) => f[$]).join(\" \"));\n }\n }\n if (typeof t == \"function\")\n return t(e === null ? {} : e, i, $e);\n const u = O(t, null);\n return u.$attrs$ = e, i.length > 0 && (u.$children$ = i), u.$key$ = l, u.$name$ = r, u;\n}, O = (t, e) => {\n const n = {\n $flags$: 0,\n $tag$: t,\n $text$: e,\n $elm$: null,\n $children$: null\n };\n return n.$attrs$ = null, n.$key$ = null, n.$name$ = null, n;\n}, fe = {}, ae = (t) => t && t.$tag$ === fe, $e = {\n forEach: (t, e) => t.map(P).forEach(e),\n map: (t, e) => t.map(P).map(e).map(ue)\n}, P = (t) => ({\n vattrs: t.$attrs$,\n vchildren: t.$children$,\n vkey: t.$key$,\n vname: t.$name$,\n vtag: t.$tag$,\n vtext: t.$text$\n}), ue = (t) => {\n if (typeof t.vtag == \"function\") {\n const n = Object.assign({}, t.vattrs);\n return t.vkey && (n.key = t.vkey), t.vname && (n.name = t.vname), G(t.vtag, n, ...t.vchildren || []);\n }\n const e = O(t.vtag, t.vtext);\n return e.$attrs$ = t.vattrs, e.$children$ = t.vchildren, e.$key$ = t.vkey, e.$name$ = t.vname, e;\n}, U = (t, e, n, s, l, r) => {\n if (n !== s) {\n let o = I(t, e), c = e.toLowerCase();\n if (e === \"class\") {\n const i = t.classList, d = W(n), u = W(s);\n i.remove(...d.filter((f) => f && !u.includes(f))), i.add(...u.filter((f) => f && !d.includes(f)));\n } else if (e === \"style\") {\n for (const i in n)\n (!s || s[i] == null) && (i.includes(\"-\") ? t.style.removeProperty(i) : t.style[i] = \"\");\n for (const i in s)\n (!n || s[i] !== n[i]) && (i.includes(\"-\") ? t.style.setProperty(i, s[i]) : t.style[i] = s[i]);\n } else if (e !== \"key\")\n if (e === \"ref\")\n s && s(t);\n else if (!t.__lookupSetter__(e) && e[0] === \"o\" && e[1] === \"n\") {\n if (e[2] === \"-\" ? e = e.slice(3) : I(N, c) ? e = c.slice(2) : e = c[2] + e.slice(3), n || s) {\n const i = e.endsWith(K);\n e = e.replace(pe, \"\"), n && x.rel(t, e, n, i), s && x.ael(t, e, s, i);\n }\n } else {\n const i = q(s);\n if ((o || i && s !== null) && !l)\n try {\n if (t.tagName.includes(\"-\"))\n t[e] = s;\n else {\n const u = s ?? \"\";\n e === \"list\" ? o = !1 : (n == null || t[e] != u) && (t[e] = u);\n }\n } catch {\n }\n let d = !1;\n c !== (c = c.replace(/^xlink\\:?/, \"\")) && (e = c, d = !0), s == null || s === !1 ? (s !== !1 || t.getAttribute(e) === \"\") && (d ? t.removeAttributeNS(H, e) : t.removeAttribute(e)) : (!o || r & 4 || l) && !i && (s = s === !0 ? \"\" : s, d ? t.setAttributeNS(H, e, s) : t.setAttribute(e, s));\n }\n }\n}, de = /\\s/, W = (t) => t ? t.split(de) : [], K = \"Capture\", pe = new RegExp(K + \"$\"), Q = (t, e, n, s) => {\n const l = e.$elm$.nodeType === 11 && e.$elm$.host ? e.$elm$.host : e.$elm$, r = t && t.$attrs$ || C, o = e.$attrs$ || C;\n for (s in r)\n s in o || U(l, s, r[s], void 0, n, e.$flags$);\n for (s in o)\n U(l, s, r[s], o[s], n, e.$flags$);\n}, j = (t, e, n, s) => {\n const l = e.$children$[n];\n let r = 0, o, c, i;\n if (D || (_ = !0, l.$tag$ === \"slot\" && (T && s.classList.add(T + \"-s\"), l.$flags$ |= l.$children$ ? (\n // slot element has fallback content\n 2\n ) : (\n // slot element does not have fallback content\n 1\n ))), l.$text$ !== null)\n o = l.$elm$ = R.createTextNode(l.$text$);\n else if (l.$flags$ & 1)\n o = l.$elm$ = R.createTextNode(\"\");\n else {\n if (h || (h = l.$tag$ === \"svg\"), o = l.$elm$ = R.createElementNS(h ? re : ie, l.$flags$ & 2 ? \"slot-fb\" : l.$tag$), h && l.$tag$ === \"foreignObject\" && (h = !1), Q(null, l, h), ce(T) && o[\"s-si\"] !== T && o.classList.add(o[\"s-si\"] = T), l.$children$)\n for (r = 0; r < l.$children$.length; ++r)\n c = j(t, l, r, o), c && o.appendChild(c);\n l.$tag$ === \"svg\" ? h = !1 : o.tagName === \"foreignObject\" && (h = !0);\n }\n return o[\"s-hn\"] = m, l.$flags$ & 3 && (o[\"s-sr\"] = !0, o[\"s-cr\"] = F, o[\"s-sn\"] = l.$name$ || \"\", i = t && t.$children$ && t.$children$[n], i && i.$tag$ === l.$tag$ && t.$elm$ && L(t.$elm$, !1)), o;\n}, L = (t, e) => {\n x.$flags$ |= 1;\n const n = t.childNodes;\n for (let s = n.length - 1; s >= 0; s--) {\n const l = n[s];\n l[\"s-hn\"] !== m && l[\"s-ol\"] && (Z(l).insertBefore(l, B(l)), l[\"s-ol\"].remove(), l[\"s-ol\"] = void 0, l[\"s-sh\"] = void 0, _ = !0), e && L(l, e);\n }\n x.$flags$ &= -2;\n}, J = (t, e, n, s, l, r) => {\n let o = t[\"s-cr\"] && t[\"s-cr\"].parentNode || t, c;\n for (o.shadowRoot && o.tagName === m && (o = o.shadowRoot); l <= r; ++l)\n s[l] && (c = j(null, n, l, t), c && (s[l].$elm$ = c, o.insertBefore(c, B(e))));\n}, Y = (t, e, n) => {\n for (let s = e; s <= n; ++s) {\n const l = t[s];\n if (l) {\n const r = l.$elm$;\n ee(l), r && (M = !0, r[\"s-ol\"] ? r[\"s-ol\"].remove() : L(r, !0), r.remove());\n }\n }\n}, ge = (t, e, n, s, l = !1) => {\n let r = 0, o = 0, c = 0, i = 0, d = e.length - 1, u = e[0], f = e[d], $ = s.length - 1, a = s[0], p = s[$], v, y;\n for (; r <= d && o <= $; )\n if (u == null)\n u = e[++r];\n else if (f == null)\n f = e[--d];\n else if (a == null)\n a = s[++o];\n else if (p == null)\n p = s[--$];\n else if (A(u, a, l))\n k(u, a, l), u = e[++r], a = s[++o];\n else if (A(f, p, l))\n k(f, p, l), f = e[--d], p = s[--$];\n else if (A(u, p, l))\n (u.$tag$ === \"slot\" || p.$tag$ === \"slot\") && L(u.$elm$.parentNode, !1), k(u, p, l), t.insertBefore(u.$elm$, f.$elm$.nextSibling), u = e[++r], p = s[--$];\n else if (A(f, a, l))\n (u.$tag$ === \"slot\" || p.$tag$ === \"slot\") && L(f.$elm$.parentNode, !1), k(f, a, l), t.insertBefore(f.$elm$, u.$elm$), f = e[--d], a = s[++o];\n else {\n for (c = -1, i = r; i <= d; ++i)\n if (e[i] && e[i].$key$ !== null && e[i].$key$ === a.$key$) {\n c = i;\n break;\n }\n c >= 0 ? (y = e[c], y.$tag$ !== a.$tag$ ? v = j(e && e[o], n, c, t) : (k(y, a, l), e[c] = void 0, v = y.$elm$), a = s[++o]) : (v = j(e && e[o], n, o, t), a = s[++o]), v && Z(u.$elm$).insertBefore(v, B(u.$elm$));\n }\n r > d ? J(t, s[$ + 1] == null ? null : s[$ + 1].$elm$, n, s, o, $) : o > $ && Y(e, r, d);\n}, A = (t, e, n = !1) => t.$tag$ === e.$tag$ ? t.$tag$ === \"slot\" ? t.$name$ === e.$name$ : n ? !0 : t.$key$ === e.$key$ : !1, B = (t) => t && t[\"s-ol\"] || t, Z = (t) => (t[\"s-ol\"] ? t[\"s-ol\"] : t).parentNode, k = (t, e, n = !1) => {\n const s = e.$elm$ = t.$elm$, l = t.$children$, r = e.$children$, o = e.$tag$, c = e.$text$;\n let i;\n c === null ? (h = o === \"svg\" ? !0 : o === \"foreignObject\" ? !1 : h, o === \"slot\" && !D || Q(t, e, h), l !== null && r !== null ? ge(s, l, e, r, n) : r !== null ? (t.$text$ !== null && (s.textContent = \"\"), J(s, null, e, r, 0, r.length - 1)) : l !== null && Y(l, 0, l.length - 1), h && o === \"svg\" && (h = !1)) : (i = s[\"s-cr\"]) ? i.parentNode.textContent = c : t.$text$ !== c && (s.data = c);\n}, w = (t) => {\n const e = t.childNodes;\n for (const n of e)\n if (n.nodeType === 1) {\n if (n[\"s-sr\"]) {\n const s = n[\"s-sn\"];\n n.hidden = !1;\n for (const l of e)\n if (l !== n) {\n if (l[\"s-hn\"] !== n[\"s-hn\"] || s !== \"\") {\n if (l.nodeType === 1 && (s === l.getAttribute(\"slot\") || s === l[\"s-sn\"])) {\n n.hidden = !0;\n break;\n }\n } else if (l.nodeType === 1 || l.nodeType === 3 && l.textContent.trim() !== \"\") {\n n.hidden = !0;\n break;\n }\n }\n }\n w(n);\n }\n}, S = [], V = (t) => {\n let e, n, s;\n for (const l of t.childNodes) {\n if (l[\"s-sr\"] && (e = l[\"s-cr\"]) && e.parentNode) {\n n = e.parentNode.childNodes;\n const r = l[\"s-sn\"];\n for (s = n.length - 1; s >= 0; s--)\n if (e = n[s], !e[\"s-cn\"] && !e[\"s-nr\"] && e[\"s-hn\"] !== l[\"s-hn\"] && !X.experimentalSlotFixes)\n if (z(e, r)) {\n let o = S.find((c) => c.$nodeToRelocate$ === e);\n M = !0, e[\"s-sn\"] = e[\"s-sn\"] || r, o ? (o.$nodeToRelocate$[\"s-sh\"] = l[\"s-hn\"], o.$slotRefNode$ = l) : (e[\"s-sh\"] = l[\"s-hn\"], S.push({\n $slotRefNode$: l,\n $nodeToRelocate$: e\n })), e[\"s-sr\"] && S.map((c) => {\n z(c.$nodeToRelocate$, e[\"s-sn\"]) && (o = S.find((i) => i.$nodeToRelocate$ === e), o && !c.$slotRefNode$ && (c.$slotRefNode$ = o.$slotRefNode$));\n });\n } else\n S.some((o) => o.$nodeToRelocate$ === e) || S.push({\n $nodeToRelocate$: e\n });\n }\n l.nodeType === 1 && V(l);\n }\n}, z = (t, e) => t.nodeType === 1 ? t.getAttribute(\"slot\") === null && e === \"\" || t.getAttribute(\"slot\") === e : t[\"s-sn\"] === e ? !0 : e === \"\", ee = (t) => {\n t.$attrs$ && t.$attrs$.ref && t.$attrs$.ref(null), t.$children$ && t.$children$.map(ee);\n}, he = (t, e, n = !1) => {\n var s, l, r, o, c;\n const i = t.$hostElement$, d = t.$cmpMeta$, u = t.$vnode$ || O(null, null), f = ae(e) ? e : G(null, null, e);\n if (m = i.tagName, d.$attrsToReflect$ && (f.$attrs$ = f.$attrs$ || {}, d.$attrsToReflect$.map(([$, a]) => f.$attrs$[a] = i[$])), n && f.$attrs$)\n for (const $ of Object.keys(f.$attrs$))\n i.hasAttribute($) && ![\"key\", \"ref\", \"style\", \"class\"].includes($) && (f.$attrs$[$] = i[$]);\n f.$tag$ = null, f.$flags$ |= 4, t.$vnode$ = f, f.$elm$ = u.$elm$ = i.shadowRoot || i, T = i[\"s-sc\"], D = (d.$flags$ & 1) !== 0, F = i[\"s-cr\"], M = !1, k(u, f, n);\n {\n if (x.$flags$ |= 1, _) {\n V(f.$elm$);\n for (const $ of S) {\n const a = $.$nodeToRelocate$;\n if (!a[\"s-ol\"]) {\n const p = R.createTextNode(\"\");\n p[\"s-nr\"] = a, a.parentNode.insertBefore(a[\"s-ol\"] = p, a);\n }\n }\n for (const $ of S) {\n const a = $.$nodeToRelocate$, p = $.$slotRefNode$;\n if (p) {\n const v = p.parentNode;\n let y = p.nextSibling;\n {\n let E = (s = a[\"s-ol\"]) === null || s === void 0 ? void 0 : s.previousSibling;\n for (; E; ) {\n let b = (l = E[\"s-nr\"]) !== null && l !== void 0 ? l : null;\n if (b && b[\"s-sn\"] === a[\"s-sn\"] && v === b.parentNode && (b = b.nextSibling, !b || !b[\"s-nr\"])) {\n y = b;\n break;\n }\n E = E.previousSibling;\n }\n }\n (!y && v !== a.parentNode || a.nextSibling !== y) && a !== y && (!a[\"s-hn\"] && a[\"s-ol\"] && (a[\"s-hn\"] = a[\"s-ol\"].parentNode.nodeName), v.insertBefore(a, y), a.nodeType === 1 && (a.hidden = (r = a[\"s-ih\"]) !== null && r !== void 0 ? r : !1));\n } else\n a.nodeType === 1 && (n && (a[\"s-ih\"] = (o = a.hidden) !== null && o !== void 0 ? o : !1), a.hidden = !0);\n }\n }\n M && w(f.$elm$), x.$flags$ &= -2, S.length = 0;\n }\n if (X.experimentalScopedSlotChanges && d.$flags$ & 2)\n for (const $ of f.$elm$.childNodes)\n $[\"s-hn\"] !== m && !$[\"s-sh\"] && (n && $[\"s-ih\"] == null && ($[\"s-ih\"] = (c = $.hidden) !== null && c !== void 0 ? c : !1), $.hidden = !0);\n F = void 0;\n}, I = (t, e) => e in t, N = typeof window < \"u\" ? window : {}, R = N.document || { head: {} };\nN.HTMLElement;\nconst x = {\n $flags$: 0,\n $resourcesUrl$: \"\",\n jmp: (t) => t(),\n raf: (t) => requestAnimationFrame(t),\n ael: (t, e, n, s) => t.addEventListener(e, n, s),\n rel: (t, e, n, s) => t.removeEventListener(e, n, s),\n ce: (t, e) => new CustomEvent(t, e)\n}, ye = (t, e, n) => {\n [null, void 0, \"\", !1].includes(n) || [\"innerHTML\", \"style\"].includes(e) || t.setAttribute(e, [\"object\", \"function\"].includes(typeof n) ? \"/!\\\\ Object props are not rendered in the code example\" : n);\n}, te = (t, e, n, s, l) => {\n if (e && typeof e == \"string\") {\n const r = document.createElement(e);\n Object.keys(n || {}).forEach((o) => {\n ye(r, o, n[o]);\n }), s == null || s.forEach((o) => {\n te(r, o.$tag$, o.$attrs$, o.$children$, o.$text$);\n }), n != null && n.innerHTML && (r.innerHTML = n.innerHTML), t.appendChild(r);\n }\n l && (t.innerHTML = l);\n}, xe = (t, e) => {\n const n = {};\n if (typeof t != \"object\")\n throw new Error(\"filterArgs - args isn't an object.\");\n for (const s in t)\n if (!s.startsWith(\"slot\")) {\n const l = t[s], r = s.replace(/([a-z])([A-Z])/g, \"$1-$2\").toLowerCase();\n (!e || !Object.keys(e).includes(s) || e[s] !== l) && (n[r] = l);\n }\n return n;\n}, me = (t, e) => {\n var s, l;\n const n = document.getElementById(\"storybook-root\");\n if (n)\n return (l = document.querySelector(\"[lang]\")) == null || l.setAttribute(\"lang\", ((s = e.globals) == null ? void 0 : s.locale) || \"en\"), he(\n {\n $ancestorComponent$: void 0,\n $flags$: 0,\n $modeName$: void 0,\n $cmpMeta$: {\n $flags$: 0,\n $tagName$: n.tagName\n },\n $hostElement$: n\n },\n t(e)\n ), n.children[n.children.length - 1];\n}, Le = ({ $tag$: t, $attrs$: e, $children$: n, $text$: s }) => {\n const l = document.createElement(\"div\");\n return te(l, t, e, n, s), l.innerHTML;\n}, Ee = (t) => {\n const e = { value: \"2023\", pattern: \"yyyy\" }, n = { value: \"12\", pattern: \"mm\" }, s = { value: \"24\", pattern: \"dd\" };\n return be([e.value, n.value, s.value].join(\"-\"), t).replace(e.value, e.pattern).replace(n.value, n.pattern).replace(s.value, s.pattern);\n}, Ae = (t) => t.toISOString().split(\"T\")[0], ve = (t, e, n) => {\n const s = t.closest(\"[lang]\"), l = Intl.NumberFormat.supportedLocalesOf(s == null ? void 0 : s.lang), r = l.length > 0 && typeof l[0] == \"string\" ? l[0] : navigator.language || n, o = r.split(\"-\").shift();\n return {\n locale: r,\n messages: e[o] || e[n]\n };\n}, Re = (t, e, n) => new Intl.NumberFormat(e, { style: \"currency\", currency: n }).format(t), Me = (t, e) => new Intl.NumberFormat(e).format(t), Se = /^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\\d|3[01])$/, be = (t, e) => typeof t != \"string\" || t === \"\" || !Se.test(t) ? \"\" : new Intl.DateTimeFormat(e).format(new Date(t)), Oe = (t, e) => (n) => ve(n, t, e), je = (t = \"\", e = 10) => {\n const n = new Uint8Array(e);\n crypto.getRandomValues(n);\n const s = Array.from(n).map((l) => l.toString(16).padStart(2, \"0\")).join(\"\").slice(0, e);\n return t !== \"\" ? `${t}-${s}` : s;\n};\nclass Fe {\n constructor(e = []) {\n /**\n * Available classes\n */\n g(this, \"classes\");\n /**\n * Add class\n * @param className - class name to add\n */\n g(this, \"add\", (e) => {\n this.has(e) || this.classes.push(e);\n });\n /**\n * Delete class\n * @param className - class name to delete\n */\n g(this, \"delete\", (e) => {\n const n = this.classes.indexOf(e);\n n > -1 && this.classes.splice(n, 1);\n });\n /**\n * Check if class exist in list\n * @param className - class name to check\n * @returns class name is in the list\n */\n g(this, \"has\", (e) => this.classes.includes(e));\n /**\n * Join classes seperated by spaces\n * @returns joined values\n */\n g(this, \"join\", () => this.classes.join(\" \"));\n this.classes = e;\n }\n}\nconst De = (t) => Array.isArray(t) && t.every((e) => typeof e == \"string\"), _e = (t, e) => e.includes(t == null ? void 0 : t.tagName.toLowerCase()), Be = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]), [identifier], mg-button', Ne = (t) => {\n const e = se(t), n = ne(t);\n return [t, ...e, ...n];\n}, se = (t, e = []) => {\n if (t.self !== t.top)\n try {\n const n = t.parent;\n return n ? (e.push(n), se(n, e)) : e;\n } catch (n) {\n return console.error(\"Different hosts between iframes:\", n), e;\n }\n return e;\n}, ne = (t, e = []) => {\n if (t.frames.length > 0)\n for (const n of Array.from(t.frames))\n e.push(n), ne(n, e);\n return e;\n}, He = (t) => typeof t == \"string\" && t.trim() !== \"\", Ce = (t) => typeof t == \"string\" ? t.toLocaleLowerCase().normalize(\"NFD\").replaceAll(/[\\u0300-\\u036f]/g, \"\") : t, Pe = async (t) => t(), Ue = ({ disconnect: t, observe: e, takeRecords: n }) => {\n class s {\n constructor(r) {\n /**\n *\n */\n g(this, \"disconnect\", t);\n /**\n *\n */\n g(this, \"observe\", e);\n /**\n *\n */\n g(this, \"takeRecords\", n);\n /**\n *\n */\n g(this, \"cb\");\n this.cb = r;\n }\n }\n return [window, global].forEach((l) => {\n Object.defineProperty(l, \"MutationObserver\", {\n writable: !0,\n configurable: !0,\n value: s\n });\n }), s;\n}, We = ({ disconnect: t, observe: e }) => {\n class n {\n constructor(l) {\n /**\n *\n */\n g(this, \"disconnect\", t);\n /**\n *\n */\n g(this, \"observe\", e);\n /**\n *\n */\n g(this, \"unobserve\");\n /**\n *\n */\n g(this, \"cb\");\n this.cb = l;\n }\n }\n return [window, global].forEach((s) => {\n Object.defineProperty(s, \"ResizeObserver\", {\n writable: !0,\n configurable: !0,\n value: n\n });\n }), n;\n};\nclass Te extends Event {\n constructor() {\n super(...arguments);\n /**\n *\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n g(this, \"detail\");\n }\n}\nconst ze = () => {\n class t extends Te {\n }\n return [window, global].forEach((e) => {\n Object.defineProperty(e, \"SubmitEvent\", {\n writable: !0,\n configurable: !0,\n value: t\n });\n }), t;\n};\nexport {\n Fe as ClassList,\n De as allItemsAreString,\n Ce as cleanString,\n je as createID,\n Se as dateRegExp,\n Ae as dateToString,\n Oe as defineLocales,\n xe as filterArgs,\n Be as focusableElements,\n Ee as getLocaleDatePattern,\n se as getParentWindows,\n Le as getStoryHTML,\n Ne as getWindows,\n _e as isTagName,\n He as isValidString,\n Re as localeCurrency,\n be as localeDate,\n Me as localeNumber,\n Pe as nextTick,\n Ue as setupMutationObserverMock,\n We as setupResizeObserverMock,\n ze as setupSubmitEventMock,\n me as stencilWrapper\n};\n//# sourceMappingURL=index.es.js.map\n"],"version":3}
|
|
1
|
+
{"file":"index.es.js","mappings":"AAAA,IAAI,EAAE,GAAG,MAAM,CAAC,cAAc,CAAC;AAC/B,IAAI,EAAE,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,UAAU,EAAE,CAAC,CAAC,EAAE,YAAY,EAAE,CAAC,CAAC,EAAE,QAAQ,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;AACjH,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,MAAM,EAAE,CAAC,CAAC,EAAE,OAAO,CAAC,IAAI,QAAQ,GAAG,CAAC,GAAG,EAAE,GAAG,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AACjE,MAAC,EAAE,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,EAAE,KAAK;AAC/B,EAAE,MAAM,CAAC,GAAG,IAAI,UAAU,CAAC,CAAC,CAAC,CAAC;AAC9B,EAAE,MAAM,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC;AAC5B,EAAE,MAAM,CAAC,GAAG,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AAC3F,EAAE,OAAO,CAAC,KAAK,EAAE,GAAG,CAA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AAC,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC;;;;","names":[],"sources":["../stencil-helpers/dist/index.es.js"],"sourcesContent":["var ie = Object.defineProperty;\nvar ce = (t, e, n) => e in t ? ie(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;\nvar p = (t, e, n) => (ce(t, typeof e != \"symbol\" ? e + \"\" : e, n), n);\nconst Re = (t = \"\", e = 10) => {\n const n = new Uint8Array(e);\n crypto.getRandomValues(n);\n const r = Array.from(n).map((s) => s.toString(16).padStart(2, \"0\")).join(\"\").slice(0, e);\n return t !== \"\" ? `${t}-${r}` : r;\n};\nclass Me {\n constructor(e = []) {\n /**\n * Available classes\n */\n p(this, \"classes\");\n /**\n * Add class\n * @param className - class name to add\n */\n p(this, \"add\", (e) => {\n this.has(e) || this.classes.push(e);\n });\n /**\n * Delete class\n * @param className - class name to delete\n */\n p(this, \"delete\", (e) => {\n const n = this.classes.indexOf(e);\n n > -1 && this.classes.splice(n, 1);\n });\n /**\n * Check if class exist in list\n * @param className - class name to check\n * @returns class name is in the list\n */\n p(this, \"has\", (e) => this.classes.includes(e));\n /**\n * Join classes seperated by spaces\n * @returns joined values\n */\n p(this, \"join\", () => this.classes.join(\" \"));\n this.classes = e;\n }\n}\nconst Oe = (t) => Array.isArray(t) && t.every((e) => typeof e == \"string\"), Fe = (t, e) => e.includes(t == null ? void 0 : t.tagName.toLowerCase()), De = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]), [identifier], mg-button', _e = (t) => {\n const e = G(t), n = I(t);\n return [t, ...e, ...n];\n}, G = (t, e = []) => {\n if (t.self !== t.top)\n try {\n const n = t.parent;\n return n ? (e.push(n), G(n, e)) : e;\n } catch (n) {\n return console.error(\"Different hosts between iframes:\", n), e;\n }\n return e;\n}, I = (t, e = []) => {\n if (t.frames.length > 0)\n for (const n of Array.from(t.frames))\n e.push(n), I(n, e);\n return e;\n}, Be = (t) => typeof t == \"string\" && t.trim() !== \"\", Ne = (t) => typeof t == \"string\" ? t.toLocaleLowerCase().normalize(\"NFD\").replaceAll(/[\\u0300-\\u036f]/g, \"\") : t, Ue = async (t) => t(), X = (t, e) => {\n if (!e)\n return;\n const n = e.split(\"/\");\n return `${t}${n.slice(2, n.length - 1).join(\"-\")}--docs`;\n}, ae = (t, e) => {\n if (e)\n return `${t}${e}`;\n}, K = (t) => {\n let e = t.overview ? `${t.overview}\n\n` : \"\";\n const n = t.props.filter(({ attr: s }) => s !== void 0);\n n.length && (e += `Attributes:\n`, e += n.map(({ attr: s, docs: o }) => `- \\`${s}\\`: ${o}\n`).join(\"\"), e += `\n`);\n const r = t.props.filter(({ attr: s }) => s === void 0);\n return r.length && (e += `Properties:\n`, e += r.map(({ name: s, docs: o }) => `- \\`${s}\\`: ${o}\n`).join(\"\"), e += `\n`), t.methods.length && (e += `Methods:\n`, e += t.methods.map(({ name: s, docs: o }) => `- \\`${s}\\`: ${o}\n`).join(\"\"), e += `\n`), t.events.length && (e += `Events:\n`, e += t.events.map(({ event: s, docs: o }) => `- \\`${s}\\`: ${o}\n`).join(\"\"), e += `\n`), t.listeners.length && (e += `Listeners:\n`, e += t.listeners.map(({ event: s }) => `- \\`${s}\\`\n`).join(\"\"), e += `\n`), t.slots.length && (e += `Slots:\n`, e += t.slots.map(({ name: s, docs: o }) => `- \\`${s}\\`: ${o}\n`).join(\"\"), e += `\n`), e;\n}, F = (t) => `${t.docs}\n\nType: \\`${t.type}\\``, Ce = (t, e, n, r) => ({\n $schema: \"https://json.schemastore.org/web-types\",\n name: t,\n version: e,\n \"description-markup\": \"markdown\",\n contributions: {\n html: {\n elements: n.components.map((s) => {\n const o = X(r, s.filePath);\n return {\n name: s.tag,\n description: K(s),\n \"doc-url\": o,\n attributes: s.props.filter((l) => l.attr).map((l) => ({\n name: l.attr,\n description: F(l),\n \"doc-url\": o,\n value: {\n type: l.type,\n default: l.default,\n required: l.required\n }\n })),\n js: {\n properties: s.props.map((l) => ({\n name: l.name,\n description: F(l),\n \"doc-url\": o,\n value: {\n type: l.type,\n default: l.default,\n required: l.required\n }\n })),\n events: s.events.map((l) => ({\n name: l.event,\n description: l.docs\n }))\n }\n };\n })\n }\n }\n}), fe = (t, e, n) => {\n if (n)\n return [\n { name: \"Storybook\", url: X(t, n) },\n { name: \"Sources\", url: ae(e, n) }\n ];\n}, $e = (t) => {\n if (!t.values.some(({ value: e }) => e === void 0))\n return t.values.map(({ value: e }) => ({ name: e }));\n}, He = (t, e, n, r) => ({\n version: t,\n tags: e.components.map((s) => {\n const o = fe(n, r, s.filePath);\n return {\n name: s.tag,\n description: K(s),\n attributes: s.props.map((l) => ({\n name: l.attr || l.name,\n description: F(l),\n values: $e(l),\n references: o\n })),\n references: o\n };\n }),\n globalAttributes: [],\n valueSets: []\n}), Pe = (t) => {\n const e = { value: \"2023\", pattern: \"yyyy\" }, n = { value: \"12\", pattern: \"mm\" }, r = { value: \"24\", pattern: \"dd\" };\n return ge([e.value, n.value, r.value].join(\"-\"), t).replace(e.value, e.pattern).replace(n.value, n.pattern).replace(r.value, r.pattern);\n}, We = (t) => t.toISOString().split(\"T\")[0], ue = (t, e, n) => {\n const r = t.closest(\"[lang]\"), s = Intl.NumberFormat.supportedLocalesOf(r == null ? void 0 : r.lang), o = s.length > 0 && typeof s[0] == \"string\" ? s[0] : navigator.language || n, l = o.split(\"-\").shift();\n return {\n locale: o,\n messages: e[l] || e[n]\n };\n}, ze = (t, e, n) => new Intl.NumberFormat(e, { style: \"currency\", currency: n }).format(t), qe = (t, e) => new Intl.NumberFormat(e).format(t), de = /^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\\d|3[01])$/, ge = (t, e) => typeof t != \"string\" || t === \"\" || !de.test(t) ? \"\" : new Intl.DateTimeFormat(e).format(new Date(t)), we = (t, e) => (n) => ue(n, t, e), Q = {\n allRenderFn: !1,\n cmpDidLoad: !0,\n cmpDidUnload: !1,\n cmpDidUpdate: !0,\n cmpDidRender: !0,\n cmpWillLoad: !0,\n cmpWillUpdate: !0,\n cmpWillRender: !0,\n connectedCallback: !0,\n disconnectedCallback: !0,\n element: !0,\n event: !0,\n hasRenderFn: !0,\n lifecycle: !0,\n hostListener: !0,\n hostListenerTargetWindow: !0,\n hostListenerTargetDocument: !0,\n hostListenerTargetBody: !0,\n hostListenerTargetParent: !1,\n hostListenerTarget: !0,\n member: !0,\n method: !0,\n mode: !0,\n observeAttribute: !0,\n prop: !0,\n propMutable: !0,\n reflect: !0,\n scoped: !0,\n shadowDom: !0,\n slot: !0,\n cssAnnotations: !0,\n state: !0,\n style: !0,\n formAssociated: !1,\n svg: !0,\n updatable: !0,\n vdomAttribute: !0,\n vdomXlink: !0,\n vdomClass: !0,\n vdomFunctional: !0,\n vdomKey: !0,\n vdomListener: !0,\n vdomRef: !0,\n vdomPropOrAttr: !0,\n vdomRender: !0,\n vdomStyle: !0,\n vdomText: !0,\n watchCallback: !0,\n taskQueue: !0,\n hotModuleReplacement: !1,\n isDebug: !1,\n isDev: !1,\n isTesting: !1,\n hydrateServerSide: !1,\n hydrateClientSide: !1,\n lifecycleDOMEvents: !1,\n lazyLoad: !1,\n profile: !1,\n slotRelocation: !0,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n appendChildSlotFix: !1,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n cloneNodeFix: !1,\n hydratedAttribute: !1,\n hydratedClass: !0,\n scriptDataOpts: !1,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n scopedSlotTextContentFix: !1,\n // TODO(STENCIL-854): Remove code related to legacy shadowDomShim field\n shadowDomShim: !1,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n slotChildNodesFix: !1,\n invisiblePrehydration: !0,\n propBoolean: !0,\n propNumber: !0,\n propString: !0,\n constructableCSS: !0,\n cmpShouldUpdate: !0,\n devTools: !1,\n shadowDelegatesFocus: !0,\n initializeNextTick: !1,\n asyncLoading: !1,\n asyncQueue: !1,\n transformTagName: !1,\n attachStyles: !0,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n experimentalSlotFixes: !1\n};\nlet k, D, x, _ = !1, R = !1, B = !1, h = !1;\nconst C = \"http://www.w3.org/1999/xlink\", H = {}, pe = \"http://www.w3.org/2000/svg\", he = \"http://www.w3.org/1999/xhtml\", ye = (t) => t != null, J = (t) => (t = typeof t, t === \"object\" || t === \"function\"), Y = (t, e, ...n) => {\n let r = null, s = null, o = null, l = !1, c = !1;\n const i = [], d = (a) => {\n for (let $ = 0; $ < a.length; $++)\n r = a[$], Array.isArray(r) ? d(r) : r != null && typeof r != \"boolean\" && ((l = typeof t != \"function\" && !J(r)) && (r = String(r)), l && c ? i[i.length - 1].$text$ += r : i.push(l ? M(null, r) : r), c = l);\n };\n if (d(n), e) {\n e.key && (s = e.key), e.name && (o = e.name);\n {\n const a = e.className || e.class;\n a && (e.class = typeof a != \"object\" ? a : Object.keys(a).filter(($) => a[$]).join(\" \"));\n }\n }\n if (typeof t == \"function\")\n return t(e === null ? {} : e, i, Se);\n const u = M(t, null);\n return u.$attrs$ = e, i.length > 0 && (u.$children$ = i), u.$key$ = s, u.$name$ = o, u;\n}, M = (t, e) => {\n const n = {\n $flags$: 0,\n $tag$: t,\n $text$: e,\n $elm$: null,\n $children$: null\n };\n return n.$attrs$ = null, n.$key$ = null, n.$name$ = null, n;\n}, ve = {}, be = (t) => t && t.$tag$ === ve, Se = {\n forEach: (t, e) => t.map(P).forEach(e),\n map: (t, e) => t.map(P).map(e).map(ke)\n}, P = (t) => ({\n vattrs: t.$attrs$,\n vchildren: t.$children$,\n vkey: t.$key$,\n vname: t.$name$,\n vtag: t.$tag$,\n vtext: t.$text$\n}), ke = (t) => {\n if (typeof t.vtag == \"function\") {\n const n = Object.assign({}, t.vattrs);\n return t.vkey && (n.key = t.vkey), t.vname && (n.name = t.vname), Y(t.vtag, n, ...t.vchildren || []);\n }\n const e = M(t.vtag, t.vtext);\n return e.$attrs$ = t.vattrs, e.$children$ = t.vchildren, e.$key$ = t.vkey, e.$name$ = t.vname, e;\n}, W = (t, e, n, r, s, o) => {\n if (n !== r) {\n let l = w(t, e), c = e.toLowerCase();\n if (e === \"class\") {\n const i = t.classList, d = z(n), u = z(r);\n i.remove(...d.filter((a) => a && !u.includes(a))), i.add(...u.filter((a) => a && !d.includes(a)));\n } else if (e === \"style\") {\n for (const i in n)\n (!r || r[i] == null) && (i.includes(\"-\") ? t.style.removeProperty(i) : t.style[i] = \"\");\n for (const i in r)\n (!n || r[i] !== n[i]) && (i.includes(\"-\") ? t.style.setProperty(i, r[i]) : t.style[i] = r[i]);\n } else if (e !== \"key\")\n if (e === \"ref\")\n r && r(t);\n else if (!t.__lookupSetter__(e) && e[0] === \"o\" && e[1] === \"n\") {\n if (e[2] === \"-\" ? e = e.slice(3) : w(U, c) ? e = c.slice(2) : e = c[2] + e.slice(3), n || r) {\n const i = e.endsWith(Z);\n e = e.replace(Te, \"\"), n && T.rel(t, e, n, i), r && T.ael(t, e, r, i);\n }\n } else {\n const i = J(r);\n if ((l || i && r !== null) && !s)\n try {\n if (t.tagName.includes(\"-\"))\n t[e] = r;\n else {\n const u = r ?? \"\";\n e === \"list\" ? l = !1 : (n == null || t[e] != u) && (t[e] = u);\n }\n } catch {\n }\n let d = !1;\n c !== (c = c.replace(/^xlink\\:?/, \"\")) && (e = c, d = !0), r == null || r === !1 ? (r !== !1 || t.getAttribute(e) === \"\") && (d ? t.removeAttributeNS(C, e) : t.removeAttribute(e)) : (!l || o & 4 || s) && !i && (r = r === !0 ? \"\" : r, d ? t.setAttributeNS(C, e, r) : t.setAttribute(e, r));\n }\n }\n}, me = /\\s/, z = (t) => t ? t.split(me) : [], Z = \"Capture\", Te = new RegExp(Z + \"$\"), V = (t, e, n, r) => {\n const s = e.$elm$.nodeType === 11 && e.$elm$.host ? e.$elm$.host : e.$elm$, o = t && t.$attrs$ || H, l = e.$attrs$ || H;\n for (r in o)\n r in l || W(s, r, o[r], void 0, n, e.$flags$);\n for (r in l)\n W(s, r, o[r], l[r], n, e.$flags$);\n}, O = (t, e, n, r) => {\n const s = e.$children$[n];\n let o = 0, l, c, i;\n if (_ || (B = !0, s.$tag$ === \"slot\" && (k && r.classList.add(k + \"-s\"), s.$flags$ |= s.$children$ ? (\n // slot element has fallback content\n 2\n ) : (\n // slot element does not have fallback content\n 1\n ))), s.$text$ !== null)\n l = s.$elm$ = j.createTextNode(s.$text$);\n else if (s.$flags$ & 1)\n l = s.$elm$ = j.createTextNode(\"\");\n else {\n if (h || (h = s.$tag$ === \"svg\"), l = s.$elm$ = j.createElementNS(h ? pe : he, s.$flags$ & 2 ? \"slot-fb\" : s.$tag$), h && s.$tag$ === \"foreignObject\" && (h = !1), V(null, s, h), ye(k) && l[\"s-si\"] !== k && l.classList.add(l[\"s-si\"] = k), s.$children$)\n for (o = 0; o < s.$children$.length; ++o)\n c = O(t, s, o, l), c && l.appendChild(c);\n s.$tag$ === \"svg\" ? h = !1 : l.tagName === \"foreignObject\" && (h = !0);\n }\n return l[\"s-hn\"] = x, s.$flags$ & 3 && (l[\"s-sr\"] = !0, l[\"s-cr\"] = D, l[\"s-sn\"] = s.$name$ || \"\", i = t && t.$children$ && t.$children$[n], i && i.$tag$ === s.$tag$ && t.$elm$ && E(t.$elm$, !1)), l;\n}, E = (t, e) => {\n T.$flags$ |= 1;\n const n = t.childNodes;\n for (let r = n.length - 1; r >= 0; r--) {\n const s = n[r];\n s[\"s-hn\"] !== x && s[\"s-ol\"] && (se(s).insertBefore(s, N(s)), s[\"s-ol\"].remove(), s[\"s-ol\"] = void 0, s[\"s-sh\"] = void 0, B = !0), e && E(s, e);\n }\n T.$flags$ &= -2;\n}, ee = (t, e, n, r, s, o) => {\n let l = t[\"s-cr\"] && t[\"s-cr\"].parentNode || t, c;\n for (l.shadowRoot && l.tagName === x && (l = l.shadowRoot); s <= o; ++s)\n r[s] && (c = O(null, n, s, t), c && (r[s].$elm$ = c, l.insertBefore(c, N(e))));\n}, te = (t, e, n) => {\n for (let r = e; r <= n; ++r) {\n const s = t[r];\n if (s) {\n const o = s.$elm$;\n le(s), o && (R = !0, o[\"s-ol\"] ? o[\"s-ol\"].remove() : E(o, !0), o.remove());\n }\n }\n}, xe = (t, e, n, r, s = !1) => {\n let o = 0, l = 0, c = 0, i = 0, d = e.length - 1, u = e[0], a = e[d], $ = r.length - 1, f = r[0], g = r[$], v, y;\n for (; o <= d && l <= $; )\n if (u == null)\n u = e[++o];\n else if (a == null)\n a = e[--d];\n else if (f == null)\n f = r[++l];\n else if (g == null)\n g = r[--$];\n else if (A(u, f, s))\n m(u, f, s), u = e[++o], f = r[++l];\n else if (A(a, g, s))\n m(a, g, s), a = e[--d], g = r[--$];\n else if (A(u, g, s))\n (u.$tag$ === \"slot\" || g.$tag$ === \"slot\") && E(u.$elm$.parentNode, !1), m(u, g, s), t.insertBefore(u.$elm$, a.$elm$.nextSibling), u = e[++o], g = r[--$];\n else if (A(a, f, s))\n (u.$tag$ === \"slot\" || g.$tag$ === \"slot\") && E(a.$elm$.parentNode, !1), m(a, f, s), t.insertBefore(a.$elm$, u.$elm$), a = e[--d], f = r[++l];\n else {\n for (c = -1, i = o; i <= d; ++i)\n if (e[i] && e[i].$key$ !== null && e[i].$key$ === f.$key$) {\n c = i;\n break;\n }\n c >= 0 ? (y = e[c], y.$tag$ !== f.$tag$ ? v = O(e && e[l], n, c, t) : (m(y, f, s), e[c] = void 0, v = y.$elm$), f = r[++l]) : (v = O(e && e[l], n, l, t), f = r[++l]), v && se(u.$elm$).insertBefore(v, N(u.$elm$));\n }\n o > d ? ee(t, r[$ + 1] == null ? null : r[$ + 1].$elm$, n, r, l, $) : l > $ && te(e, o, d);\n}, A = (t, e, n = !1) => t.$tag$ === e.$tag$ ? t.$tag$ === \"slot\" ? t.$name$ === e.$name$ : n ? !0 : t.$key$ === e.$key$ : !1, N = (t) => t && t[\"s-ol\"] || t, se = (t) => (t[\"s-ol\"] ? t[\"s-ol\"] : t).parentNode, m = (t, e, n = !1) => {\n const r = e.$elm$ = t.$elm$, s = t.$children$, o = e.$children$, l = e.$tag$, c = e.$text$;\n let i;\n c === null ? (h = l === \"svg\" ? !0 : l === \"foreignObject\" ? !1 : h, l === \"slot\" && !_ || V(t, e, h), s !== null && o !== null ? xe(r, s, e, o, n) : o !== null ? (t.$text$ !== null && (r.textContent = \"\"), ee(r, null, e, o, 0, o.length - 1)) : s !== null && te(s, 0, s.length - 1), h && l === \"svg\" && (h = !1)) : (i = r[\"s-cr\"]) ? i.parentNode.textContent = c : t.$text$ !== c && (r.data = c);\n}, ne = (t) => {\n const e = t.childNodes;\n for (const n of e)\n if (n.nodeType === 1) {\n if (n[\"s-sr\"]) {\n const r = n[\"s-sn\"];\n n.hidden = !1;\n for (const s of e)\n if (s !== n) {\n if (s[\"s-hn\"] !== n[\"s-hn\"] || r !== \"\") {\n if (s.nodeType === 1 && (r === s.getAttribute(\"slot\") || r === s[\"s-sn\"])) {\n n.hidden = !0;\n break;\n }\n } else if (s.nodeType === 1 || s.nodeType === 3 && s.textContent.trim() !== \"\") {\n n.hidden = !0;\n break;\n }\n }\n }\n ne(n);\n }\n}, b = [], re = (t) => {\n let e, n, r;\n for (const s of t.childNodes) {\n if (s[\"s-sr\"] && (e = s[\"s-cr\"]) && e.parentNode) {\n n = e.parentNode.childNodes;\n const o = s[\"s-sn\"];\n for (r = n.length - 1; r >= 0; r--)\n if (e = n[r], !e[\"s-cn\"] && !e[\"s-nr\"] && e[\"s-hn\"] !== s[\"s-hn\"] && !Q.experimentalSlotFixes)\n if (q(e, o)) {\n let l = b.find((c) => c.$nodeToRelocate$ === e);\n R = !0, e[\"s-sn\"] = e[\"s-sn\"] || o, l ? (l.$nodeToRelocate$[\"s-sh\"] = s[\"s-hn\"], l.$slotRefNode$ = s) : (e[\"s-sh\"] = s[\"s-hn\"], b.push({\n $slotRefNode$: s,\n $nodeToRelocate$: e\n })), e[\"s-sr\"] && b.map((c) => {\n q(c.$nodeToRelocate$, e[\"s-sn\"]) && (l = b.find((i) => i.$nodeToRelocate$ === e), l && !c.$slotRefNode$ && (c.$slotRefNode$ = l.$slotRefNode$));\n });\n } else\n b.some((l) => l.$nodeToRelocate$ === e) || b.push({\n $nodeToRelocate$: e\n });\n }\n s.nodeType === 1 && re(s);\n }\n}, q = (t, e) => t.nodeType === 1 ? t.getAttribute(\"slot\") === null && e === \"\" || t.getAttribute(\"slot\") === e : t[\"s-sn\"] === e ? !0 : e === \"\", le = (t) => {\n t.$attrs$ && t.$attrs$.ref && t.$attrs$.ref(null), t.$children$ && t.$children$.map(le);\n}, Ee = (t, e, n = !1) => {\n var r, s, o, l, c;\n const i = t.$hostElement$, d = t.$cmpMeta$, u = t.$vnode$ || M(null, null), a = be(e) ? e : Y(null, null, e);\n if (x = i.tagName, d.$attrsToReflect$ && (a.$attrs$ = a.$attrs$ || {}, d.$attrsToReflect$.map(([$, f]) => a.$attrs$[f] = i[$])), n && a.$attrs$)\n for (const $ of Object.keys(a.$attrs$))\n i.hasAttribute($) && ![\"key\", \"ref\", \"style\", \"class\"].includes($) && (a.$attrs$[$] = i[$]);\n a.$tag$ = null, a.$flags$ |= 4, t.$vnode$ = a, a.$elm$ = u.$elm$ = i.shadowRoot || i, k = i[\"s-sc\"], _ = (d.$flags$ & 1) !== 0, D = i[\"s-cr\"], R = !1, m(u, a, n);\n {\n if (T.$flags$ |= 1, B) {\n re(a.$elm$);\n for (const $ of b) {\n const f = $.$nodeToRelocate$;\n if (!f[\"s-ol\"]) {\n const g = j.createTextNode(\"\");\n g[\"s-nr\"] = f, f.parentNode.insertBefore(f[\"s-ol\"] = g, f);\n }\n }\n for (const $ of b) {\n const f = $.$nodeToRelocate$, g = $.$slotRefNode$;\n if (g) {\n const v = g.parentNode;\n let y = g.nextSibling;\n {\n let L = (r = f[\"s-ol\"]) === null || r === void 0 ? void 0 : r.previousSibling;\n for (; L; ) {\n let S = (s = L[\"s-nr\"]) !== null && s !== void 0 ? s : null;\n if (S && S[\"s-sn\"] === f[\"s-sn\"] && v === S.parentNode && (S = S.nextSibling, !S || !S[\"s-nr\"])) {\n y = S;\n break;\n }\n L = L.previousSibling;\n }\n }\n (!y && v !== f.parentNode || f.nextSibling !== y) && f !== y && (!f[\"s-hn\"] && f[\"s-ol\"] && (f[\"s-hn\"] = f[\"s-ol\"].parentNode.nodeName), v.insertBefore(f, y), f.nodeType === 1 && (f.hidden = (o = f[\"s-ih\"]) !== null && o !== void 0 ? o : !1));\n } else\n f.nodeType === 1 && (n && (f[\"s-ih\"] = (l = f.hidden) !== null && l !== void 0 ? l : !1), f.hidden = !0);\n }\n }\n R && ne(a.$elm$), T.$flags$ &= -2, b.length = 0;\n }\n if (Q.experimentalScopedSlotChanges && d.$flags$ & 2)\n for (const $ of a.$elm$.childNodes)\n $[\"s-hn\"] !== x && !$[\"s-sh\"] && (n && $[\"s-ih\"] == null && ($[\"s-ih\"] = (c = $.hidden) !== null && c !== void 0 ? c : !1), $.hidden = !0);\n D = void 0;\n}, w = (t, e) => e in t, U = typeof window < \"u\" ? window : {}, j = U.document || { head: {} };\nU.HTMLElement;\nconst T = {\n $flags$: 0,\n $resourcesUrl$: \"\",\n jmp: (t) => t(),\n raf: (t) => requestAnimationFrame(t),\n ael: (t, e, n, r) => t.addEventListener(e, n, r),\n rel: (t, e, n, r) => t.removeEventListener(e, n, r),\n ce: (t, e) => new CustomEvent(t, e)\n}, Le = (t, e, n) => {\n [null, void 0, \"\", !1].includes(n) || [\"innerHTML\", \"style\"].includes(e) || t.setAttribute(e, [\"object\", \"function\"].includes(typeof n) ? \"/!\\\\ Object props are not rendered in the code example\" : n);\n}, oe = (t, e, n, r, s) => {\n if (e && typeof e == \"string\") {\n const o = document.createElement(e);\n Object.keys(n || {}).forEach((l) => {\n Le(o, l, n[l]);\n }), r == null || r.forEach((l) => {\n oe(o, l.$tag$, l.$attrs$, l.$children$, l.$text$);\n }), n != null && n.innerHTML && (o.innerHTML = n.innerHTML), t.appendChild(o);\n }\n s && (t.innerHTML = s);\n}, Ge = (t, e) => {\n const n = {};\n if (typeof t != \"object\")\n throw new Error(\"filterArgs - args isn't an object.\");\n for (const r in t)\n if (!r.startsWith(\"slot\")) {\n const s = t[r], o = r.replace(/([a-z])([A-Z])/g, \"$1-$2\").toLowerCase();\n (!e || !Object.keys(e).includes(r) || e[r] !== s) && (n[o] = s);\n }\n return n;\n}, Ie = (t, e) => {\n var r, s;\n const n = document.getElementById(\"storybook-root\");\n if (n)\n return (s = document.querySelector(\"[lang]\")) == null || s.setAttribute(\"lang\", ((r = e.globals) == null ? void 0 : r.locale) || \"en\"), Ee(\n {\n $ancestorComponent$: void 0,\n $flags$: 0,\n $modeName$: void 0,\n $cmpMeta$: {\n $flags$: 0,\n $tagName$: n.tagName\n },\n $hostElement$: n\n },\n t(e)\n ), n.children[n.children.length - 1];\n}, Xe = ({ $tag$: t, $attrs$: e, $children$: n, $text$: r }) => {\n const s = document.createElement(\"div\");\n return oe(s, t, e, n, r), s.innerHTML;\n}, Ke = ({ disconnect: t, observe: e, takeRecords: n }) => {\n class r {\n constructor(o) {\n /**\n *\n */\n p(this, \"disconnect\", t);\n /**\n *\n */\n p(this, \"observe\", e);\n /**\n *\n */\n p(this, \"takeRecords\", n);\n /**\n *\n */\n p(this, \"cb\");\n this.cb = o;\n }\n }\n return [window, global].forEach((s) => {\n Object.defineProperty(s, \"MutationObserver\", {\n writable: !0,\n configurable: !0,\n value: r\n });\n }), r;\n}, Qe = ({ disconnect: t, observe: e }) => {\n class n {\n constructor(s) {\n /**\n *\n */\n p(this, \"disconnect\", t);\n /**\n *\n */\n p(this, \"observe\", e);\n /**\n *\n */\n p(this, \"unobserve\");\n /**\n *\n */\n p(this, \"cb\");\n this.cb = s;\n }\n }\n return [window, global].forEach((r) => {\n Object.defineProperty(r, \"ResizeObserver\", {\n writable: !0,\n configurable: !0,\n value: n\n });\n }), n;\n};\nclass Ae extends Event {\n constructor() {\n super(...arguments);\n /**\n *\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n p(this, \"detail\");\n }\n}\nconst Je = () => {\n class t extends Ae {\n }\n return [window, global].forEach((e) => {\n Object.defineProperty(e, \"SubmitEvent\", {\n writable: !0,\n configurable: !0,\n value: t\n });\n }), t;\n};\nexport {\n Me as ClassList,\n Oe as allItemsAreString,\n Ne as cleanString,\n Re as createID,\n de as dateRegExp,\n We as dateToString,\n we as defineLocales,\n Ge as filterArgs,\n De as focusableElements,\n Pe as getLocaleDatePattern,\n G as getParentWindows,\n Xe as getStoryHTML,\n _e as getWindows,\n Fe as isTagName,\n Be as isValidString,\n ze as localeCurrency,\n ge as localeDate,\n qe as localeNumber,\n Ue as nextTick,\n Ke as setupMutationObserverMock,\n Qe as setupResizeObserverMock,\n Je as setupSubmitEventMock,\n Ie as stencilWrapper,\n He as vsCodeGenerator,\n Ce as webTypesGenerator\n};\n//# sourceMappingURL=index.es.js.map\n"],"version":3}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { w as we } from './index.es.js';
|
|
2
2
|
|
|
3
3
|
const errors$1 = {
|
|
4
4
|
required: "This field is required.",
|
|
@@ -233,7 +233,7 @@ const messages = { en, fr };
|
|
|
233
233
|
* @param element - element we need to get the language
|
|
234
234
|
* @returns messages object
|
|
235
235
|
*/
|
|
236
|
-
const initLocales =
|
|
236
|
+
const initLocales = we(messages, defaultLocale);
|
|
237
237
|
|
|
238
238
|
export { initLocales as i };
|
|
239
239
|
|
|
@@ -2,7 +2,7 @@ import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal
|
|
|
2
2
|
import { i as initLocales } from './index2.js';
|
|
3
3
|
import { d as defineCustomElement$4, S as Status } from './mg-menu-item2.js';
|
|
4
4
|
import { D as Direction } from './mg-menu.conf.js';
|
|
5
|
-
import {
|
|
5
|
+
import { R as Re } from './index.es.js';
|
|
6
6
|
import { d as defineCustomElement$9 } from './mg-badge2.js';
|
|
7
7
|
import { d as defineCustomElement$8 } from './mg-button2.js';
|
|
8
8
|
import { d as defineCustomElement$7 } from './mg-card2.js';
|
|
@@ -51,7 +51,7 @@ const MgActionMore$1 = /*@__PURE__*/ proxyCustomElement(class MgActionMore exten
|
|
|
51
51
|
************/
|
|
52
52
|
this.name = 'mg-action-more';
|
|
53
53
|
this.classBase = 'mg-c-action-more';
|
|
54
|
-
this.mgPopoverIdentifier =
|
|
54
|
+
this.mgPopoverIdentifier = Re(this.name);
|
|
55
55
|
/************
|
|
56
56
|
* Methods *
|
|
57
57
|
***********/
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { M as Me, B as Be } from './index.es.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* List of all possibles variants
|
|
@@ -23,7 +23,7 @@ const MgBadge = /*@__PURE__*/ proxyCustomElement(class MgBadge extends HTMLEleme
|
|
|
23
23
|
this.label = undefined;
|
|
24
24
|
this.variant = variants[0];
|
|
25
25
|
this.outline = undefined;
|
|
26
|
-
this.classCollection = new
|
|
26
|
+
this.classCollection = new Me(['mg-c-badge']);
|
|
27
27
|
}
|
|
28
28
|
validateValue(newValue) {
|
|
29
29
|
if (/^(\d+\+*|[?*!a-z])$/i.exec(`${newValue}`) === null) {
|
|
@@ -31,7 +31,7 @@ const MgBadge = /*@__PURE__*/ proxyCustomElement(class MgBadge extends HTMLEleme
|
|
|
31
31
|
}
|
|
32
32
|
}
|
|
33
33
|
validateLabel(newValue) {
|
|
34
|
-
if (!
|
|
34
|
+
if (!Be(newValue)) {
|
|
35
35
|
throw new Error('<mg-badge> prop "label" is required.');
|
|
36
36
|
}
|
|
37
37
|
}
|
|
@@ -66,7 +66,7 @@ const MgBadge = /*@__PURE__*/ proxyCustomElement(class MgBadge extends HTMLEleme
|
|
|
66
66
|
* @returns HTML Element
|
|
67
67
|
*/
|
|
68
68
|
render() {
|
|
69
|
-
return (h("span", { key: '
|
|
69
|
+
return (h("span", { key: 'f6f1baa91f4a9e55af711f0a84eaca74b97962b3', class: this.classCollection.join() }, h("span", { key: '9c61217b74129839f600617d5e6e6bc7a2863667', class: "mg-c-badge__value" }, this.value), h("span", { key: '2fd7529d5d9a9b32da2c4a80a70a09396ffb9100', class: "mg-u-visually-hidden" }, this.label)));
|
|
70
70
|
}
|
|
71
71
|
static get watchers() { return {
|
|
72
72
|
"value": ["validateValue"],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"mg-badge2.js","mappings":";;;AAAA;;;AAGO,MAAM,QAAQ,GAAG,CAAC,MAAM,EAAE,SAAS,EAAE,WAAW,EAAE,SAAS,EAAE,SAAS,EAAE,QAAQ,EAAE,YAAY,CAAU;;ACH/G,MAAM,UAAU,GAAG,yoFAAyoF,CAAC;AAC7pF,sBAAe,UAAU;;MCOZ,OAAO;;;;;;;;;QAMD,iBAAY,GAAG,qBAAqB,CAAC;;;uBAgCjB,QAAQ,CAAC,CAAC,CAAC;;+BA0BV,IAAIA,EAAS,CAAC,CAAC,YAAY,CAAC,CAAC;;IA/CnE,aAAa,CAAC,QAA0B;QACtC,IAAI,sBAAsB,CAAC,IAAI,CAAC,GAAG,QAAQ,EAAE,CAAC,KAAK,IAAI,EAAE;YACvD,MAAM,IAAI,KAAK,CAAC,mEAAmE,CAAC,CAAC;SACtF;KACF;IAQD,aAAa,CAAC,QAA0B;QACtC,IAAI,CAACC,EAAa,CAAC,QAAQ,CAAC,EAAE;YAC5B,MAAM,IAAI,KAAK,CAAC,sCAAsC,CAAC,CAAC;SACzD;KACF;IAOD,eAAe,CAAC,QAA4B,EAAE,QAA6B;QACzE,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE;YAChC,MAAM,IAAI,KAAK,CAAC,6CAA6C,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;SACtF;aAAM;YACL,IAAI,QAAQ,KAAK,SAAS,EAAE;gBAC1B,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,eAAe,QAAQ,EAAE,CAAC,CAAC;aACxD;YACD,IAAI,CAAC,eAAe,CAAC,GAAG,CAAC,eAAe,QAAQ,EAAE,CAAC,CAAC;SACrD;KACF;IAOD,eAAe,CAAC,QAA4B;QAC1C,IAAI,QAAQ;YAAE,IAAI,CAAC,eAAe,CAAC,GAAG,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;;YACrD,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;KACrD;;;;IAUD,iBAAiB;QACf,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QAC/B,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QAC/B,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACnC,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;KACpC;;;;;IAMD,MAAM;QACJ,QACE,6DAAM,KAAK,EAAE,IAAI,CAAC,eAAe,CAAC,IAAI,EAAE,IACtC,6DAAM,KAAK,EAAC,mBAAmB,IAAE,IAAI,CAAC,KAAK,CAAQ,EACnD,6DAAM,KAAK,EAAC,sBAAsB,IAAE,IAAI,CAAC,KAAK,CAAQ,CACjD,EACP;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["ClassList","isValidString"],"sources":["src/components/atoms/mg-badge/mg-badge.conf.ts","../styles/dist/components/mg-badge.css?tag=mg-badge&encapsulation=shadow","src/components/atoms/mg-badge/mg-badge.tsx"],"sourcesContent":["/**\n * List of all possibles variants\n */\nexport const variants = ['info', 'primary', 'secondary', 'success', 'warning', 'danger', 'text-color'] as const;\n\n/**\n * Variant type from variants\n */\nexport type BadgeVariantType = (typeof variants)[number];\n",".mg-u-visually-hidden{position:absolute !important;overflow:hidden !important;width:.1rem !important;height:.1rem !important;padding:0 !important;border:0 !important;margin:-0.1rem !important;clip:rect(0.1rem, 0.1rem, 0.1rem, 0.1rem) !important;clip-path:inset(50%) !important;white-space:nowrap !important}*:focus:not(:focus-visible){outline:none}@media(prefers-reduced-motion){*{animation:none !important;transition:none !important}}.mg-c-badge{min-width:var(--mg-badge-size);height:var(--mg-badge-size);box-sizing:border-box;padding:0 .4rem;border:.1rem solid;border-radius:calc(var(--mg-badge-size)/2);font-size:var(--mg-badge-font-size);font-weight:600;line-height:var(--mg-badge-size);text-align:center}.mg-c-badge.mg-c-badge--primary{border-color:hsl(var(--color-dark));background-color:hsl(var(--color-dark));color:hsl(var(--color-light))}.mg-c-badge.mg-c-badge--primary.mg-c-badge--outline{background-color:rgba(0,0,0,0);color:hsl(var(--color-dark))}.mg-c-badge.mg-c-badge--secondary{border-color:hsl(var(--color-light));background-color:hsl(var(--color-light));color:hsl(var(--color-dark))}.mg-c-badge.mg-c-badge--secondary.mg-c-badge--outline{background-color:rgba(0,0,0,0);color:hsl(var(--color-light))}.mg-c-badge.mg-c-badge--success{border-color:hsl(var(--color-success));background-color:hsl(var(--color-success));color:hsl(var(--color-dark))}.mg-c-badge.mg-c-badge--success.mg-c-badge--outline{background-color:rgba(0,0,0,0);color:hsl(var(--color-success))}.mg-c-badge.mg-c-badge--warning{border-color:hsl(var(--color-warning));background-color:hsl(var(--color-warning));color:hsl(var(--color-dark))}.mg-c-badge.mg-c-badge--warning.mg-c-badge--outline{background-color:rgba(0,0,0,0);color:hsl(var(--color-warning))}.mg-c-badge.mg-c-badge--danger{border-color:hsl(var(--color-danger));background-color:hsl(var(--color-danger));color:hsl(var(--color-light))}.mg-c-badge.mg-c-badge--danger.mg-c-badge--outline{background-color:rgba(0,0,0,0);color:hsl(var(--color-danger))}.mg-c-badge.mg-c-badge--info{border-color:hsl(var(--color-info));background-color:hsl(var(--color-info));color:hsl(var(--color-light))}.mg-c-badge.mg-c-badge--info.mg-c-badge--outline{background-color:rgba(0,0,0,0);color:hsl(var(--color-info))}.mg-c-badge.mg-c-badge--text-color{border-color:currentcolor;background-color:currentcolor}.mg-c-badge.mg-c-badge--text-color .mg-c-badge__value{color:hsl(var(--mg-badge-text-color, var(--color-light)))}.mg-c-badge.mg-c-badge--text-color.mg-c-badge--outline{background-color:rgba(0,0,0,0)}.mg-c-badge.mg-c-badge--text-color.mg-c-badge--outline .mg-c-badge__value{color:currentcolor}.mg-c-badge,mg-badge{display:inline-flex;align-items:center;justify-content:center}/*# sourceMappingURL=mg-badge.css.map */\n","import { Component, h, Prop, State, Watch } from '@stencil/core';\nimport { variants, BadgeVariantType } from './mg-badge.conf';\nimport { ClassList, isValidString } from '@mgdis/stencil-helpers';\n@Component({\n tag: 'mg-badge',\n styleUrl: '../../../../node_modules/@mgdis/styles/dist/components/mg-badge.css',\n shadow: true,\n})\nexport class MgBadge {\n /************\n * Internal *\n ************/\n\n // Classes\n private readonly classOutline = `mg-c-badge--outline`;\n\n /**************\n * Decorators *\n **************/\n\n /**\n * Badge value\n */\n @Prop() value!: string | number;\n @Watch('value')\n validateValue(newValue: MgBadge['value']): void {\n if (/^(\\d+\\+*|[?*!a-z])$/i.exec(`${newValue}`) === null) {\n throw new Error('<mg-badge> prop \"value\" must be integer or ponctuation character.');\n }\n }\n\n /**\n * Badge label. Include short description.\n * Required for accessibility\n */\n @Prop() label!: string;\n @Watch('label')\n validateLabel(newValue: MgBadge['label']): void {\n if (!isValidString(newValue)) {\n throw new Error('<mg-badge> prop \"label\" is required.');\n }\n }\n\n /**\n * Define
|
|
1
|
+
{"file":"mg-badge2.js","mappings":";;;AAAA;;;AAGO,MAAM,QAAQ,GAAG,CAAC,MAAM,EAAE,SAAS,EAAE,WAAW,EAAE,SAAS,EAAE,SAAS,EAAE,QAAQ,EAAE,YAAY,CAAU;;ACH/G,MAAM,UAAU,GAAG,yoFAAyoF,CAAC;AAC7pF,sBAAe,UA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AAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACnC,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;KACpC;;;;;IAMD,MAAM;QACJ,QACE,6DAAM,KAAK,EAAE,IAAI,CAAC,eAAe,CAAC,IAAI,EAAE,IACtC,6DAAM,KAAK,EAAC,mBAAmB,IAAE,IAAI,CAAC,KAAK,CAAQ,EACnD,6DAAM,KAAK,EAAC,sBAAsB,IAAE,IAAI,CAAC,KAAK,CAAQ,CACjD,EACP;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["ClassList","isValidString"],"sources":["src/components/atoms/mg-badge/mg-badge.conf.ts","../styles/dist/components/mg-badge.css?tag=mg-badge&encapsulation=shadow","src/components/atoms/mg-badge/mg-badge.tsx"],"sourcesContent":["/**\n * List of all possibles variants\n */\nexport const variants = ['info', 'primary', 'secondary', 'success', 'warning', 'danger', 'text-color'] as const;\n\n/**\n * Variant type from variants\n */\nexport type BadgeVariantType = (typeof variants)[number];\n",".mg-u-visually-hidden{position:absolute !important;overflow:hidden !important;width:.1rem !important;height:.1rem !important;padding:0 !important;border:0 !important;margin:-0.1rem !important;clip:rect(0.1rem, 0.1rem, 0.1rem, 0.1rem) !important;clip-path:inset(50%) !important;white-space:nowrap !important}*:focus:not(:focus-visible){outline:none}@media(prefers-reduced-motion){*{animation:none !important;transition:none !important}}.mg-c-badge{min-width:var(--mg-badge-size);height:var(--mg-badge-size);box-sizing:border-box;padding:0 .4rem;border:.1rem solid;border-radius:calc(var(--mg-badge-size)/2);font-size:var(--mg-badge-font-size);font-weight:600;line-height:var(--mg-badge-size);text-align:center}.mg-c-badge.mg-c-badge--primary{border-color:hsl(var(--color-dark));background-color:hsl(var(--color-dark));color:hsl(var(--color-light))}.mg-c-badge.mg-c-badge--primary.mg-c-badge--outline{background-color:rgba(0,0,0,0);color:hsl(var(--color-dark))}.mg-c-badge.mg-c-badge--secondary{border-color:hsl(var(--color-light));background-color:hsl(var(--color-light));color:hsl(var(--color-dark))}.mg-c-badge.mg-c-badge--secondary.mg-c-badge--outline{background-color:rgba(0,0,0,0);color:hsl(var(--color-light))}.mg-c-badge.mg-c-badge--success{border-color:hsl(var(--color-success));background-color:hsl(var(--color-success));color:hsl(var(--color-dark))}.mg-c-badge.mg-c-badge--success.mg-c-badge--outline{background-color:rgba(0,0,0,0);color:hsl(var(--color-success))}.mg-c-badge.mg-c-badge--warning{border-color:hsl(var(--color-warning));background-color:hsl(var(--color-warning));color:hsl(var(--color-dark))}.mg-c-badge.mg-c-badge--warning.mg-c-badge--outline{background-color:rgba(0,0,0,0);color:hsl(var(--color-warning))}.mg-c-badge.mg-c-badge--danger{border-color:hsl(var(--color-danger));background-color:hsl(var(--color-danger));color:hsl(var(--color-light))}.mg-c-badge.mg-c-badge--danger.mg-c-badge--outline{background-color:rgba(0,0,0,0);color:hsl(var(--color-danger))}.mg-c-badge.mg-c-badge--info{border-color:hsl(var(--color-info));background-color:hsl(var(--color-info));color:hsl(var(--color-light))}.mg-c-badge.mg-c-badge--info.mg-c-badge--outline{background-color:rgba(0,0,0,0);color:hsl(var(--color-info))}.mg-c-badge.mg-c-badge--text-color{border-color:currentcolor;background-color:currentcolor}.mg-c-badge.mg-c-badge--text-color .mg-c-badge__value{color:hsl(var(--mg-badge-text-color, var(--color-light)))}.mg-c-badge.mg-c-badge--text-color.mg-c-badge--outline{background-color:rgba(0,0,0,0)}.mg-c-badge.mg-c-badge--text-color.mg-c-badge--outline .mg-c-badge__value{color:currentcolor}.mg-c-badge,mg-badge{display:inline-flex;align-items:center;justify-content:center}/*# sourceMappingURL=mg-badge.css.map */\n","import { Component, h, Prop, State, Watch } from '@stencil/core';\nimport { variants, BadgeVariantType } from './mg-badge.conf';\nimport { ClassList, isValidString } from '@mgdis/stencil-helpers';\n@Component({\n tag: 'mg-badge',\n styleUrl: '../../../../node_modules/@mgdis/styles/dist/components/mg-badge.css',\n shadow: true,\n})\nexport class MgBadge {\n /************\n * Internal *\n ************/\n\n // Classes\n private readonly classOutline = `mg-c-badge--outline`;\n\n /**************\n * Decorators *\n **************/\n\n /**\n * Badge value\n */\n @Prop() value!: string | number;\n @Watch('value')\n validateValue(newValue: MgBadge['value']): void {\n if (/^(\\d+\\+*|[?*!a-z])$/i.exec(`${newValue}`) === null) {\n throw new Error('<mg-badge> prop \"value\" must be integer or ponctuation character.');\n }\n }\n\n /**\n * Badge label. Include short description.\n * Required for accessibility\n */\n @Prop() label!: string;\n @Watch('label')\n validateLabel(newValue: MgBadge['label']): void {\n if (!isValidString(newValue)) {\n throw new Error('<mg-badge> prop \"label\" is required.');\n }\n }\n\n /**\n * Define badge variant\n */\n @Prop() variant?: BadgeVariantType = variants[0]; // info\n @Watch('variant')\n validateVariant(newValue: MgBadge['variant'], oldValue?: MgBadge['variant']): void {\n if (!variants.includes(newValue)) {\n throw new Error(`<mg-badge> prop \"variant\" must be one of: ${variants.join(', ')}.`);\n } else {\n if (oldValue !== undefined) {\n this.classCollection.delete(`mg-c-badge--${oldValue}`);\n }\n this.classCollection.add(`mg-c-badge--${newValue}`);\n }\n }\n\n /**\n * Define if button is using outline style\n */\n @Prop() outline: boolean;\n @Watch('outline')\n validateOutline(newValue: MgBadge['outline']): void {\n if (newValue) this.classCollection.add(this.classOutline);\n else this.classCollection.delete(this.classOutline);\n }\n\n /**\n * Component classes\n */\n @State() classCollection: ClassList = new ClassList(['mg-c-badge']);\n\n /**\n * Check if props are well configured on init\n */\n componentWillLoad(): void {\n this.validateValue(this.value);\n this.validateLabel(this.label);\n this.validateVariant(this.variant);\n this.validateOutline(this.outline);\n }\n\n /**\n * Render\n * @returns HTML Element\n */\n render(): HTMLElement {\n return (\n <span class={this.classCollection.join()}>\n <span class=\"mg-c-badge__value\">{this.value}</span>\n <span class=\"mg-u-visually-hidden\">{this.label}</span>\n </span>\n );\n }\n}\n"],"version":3}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { M as Me, B as Be, U as Ue } from './index.es.js';
|
|
3
3
|
import { d as defineCustomElement$1 } from './mg-icon2.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
@@ -69,7 +69,7 @@ const MgButton = /*@__PURE__*/ proxyCustomElement(class MgButton extends HTMLEle
|
|
|
69
69
|
this.isIcon = false;
|
|
70
70
|
this.disableOnClick = false;
|
|
71
71
|
this.loading = false;
|
|
72
|
-
this.classCollection = new
|
|
72
|
+
this.classCollection = new Me(['mg-c-button']);
|
|
73
73
|
}
|
|
74
74
|
validateVariant(newValue, oldValue) {
|
|
75
75
|
if (!variants.includes(newValue)) {
|
|
@@ -128,7 +128,7 @@ const MgButton = /*@__PURE__*/ proxyCustomElement(class MgButton extends HTMLEle
|
|
|
128
128
|
this.validateFullWidth(this.fullWidth);
|
|
129
129
|
if (this.isIcon) {
|
|
130
130
|
this.classCollection.add(`mg-c-button--icon`);
|
|
131
|
-
if (!
|
|
131
|
+
if (!Be(this.label)) {
|
|
132
132
|
throw new Error(`<mg-button> prop "label" is mandatory when prop "isIcon" is set to true.`);
|
|
133
133
|
}
|
|
134
134
|
}
|
|
@@ -140,7 +140,7 @@ const MgButton = /*@__PURE__*/ proxyCustomElement(class MgButton extends HTMLEle
|
|
|
140
140
|
* Add listners
|
|
141
141
|
*/
|
|
142
142
|
componentDidLoad() {
|
|
143
|
-
|
|
143
|
+
Ue(() => {
|
|
144
144
|
var _a;
|
|
145
145
|
const closestForm = this.element.closest('form') || ((_a = this.element.closest('mg-form')) === null || _a === void 0 ? void 0 : _a.shadowRoot.querySelector('form'));
|
|
146
146
|
// submit buttons should trigger form submition;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { M as Me } from './index.es.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* List available variants
|
|
@@ -33,7 +33,7 @@ const MgCard = /*@__PURE__*/ proxyCustomElement(class MgCard extends HTMLElement
|
|
|
33
33
|
};
|
|
34
34
|
this.variant = undefined;
|
|
35
35
|
this.variantStyle = undefined;
|
|
36
|
-
this.classCollection = new
|
|
36
|
+
this.classCollection = new Me([this.classBase]);
|
|
37
37
|
}
|
|
38
38
|
validateVariant(newValue, oldValue) {
|
|
39
39
|
if (newValue && !variants.includes(newValue))
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { B as Be } from './index.es.js';
|
|
3
3
|
import { d as defineCustomElement$2 } from './mg-icon2.js';
|
|
4
4
|
|
|
5
5
|
const mgDetailsCss = ".mg-u-visually-hidden{position:absolute !important;overflow:hidden !important;width:.1rem !important;height:.1rem !important;padding:0 !important;border:0 !important;margin:-0.1rem !important;clip:rect(0.1rem, 0.1rem, 0.1rem, 0.1rem) !important;clip-path:inset(50%) !important;white-space:nowrap !important}*:focus:not(:focus-visible){outline:none}@media (prefers-reduced-motion){*{animation:none !important;transition:none !important}}.mg-c-details summary{display:flex;align-items:baseline;cursor:pointer}.mg-c-details__toggle{display:flex;min-height:calc(var(--font-size)*var(--line-height));flex-shrink:0;align-items:center;align-self:flex-start;margin-left:1.5rem;gap:.6rem}.mg-c-details__toggle-icon.mg-c-details__toggle-icon--reverse{transform:rotate(180deg)}.mg-c-details__details{margin-top:var(--mg-details-spacing)}@media (width < 43.75rem){.mg-c-details__toggle>span{position:absolute !important;overflow:hidden !important;width:.1rem !important;height:.1rem !important;padding:0 !important;border:0 !important;margin:-0.1rem !important;clip:rect(0.1rem, 0.1rem, 0.1rem, 0.1rem) !important;clip-path:inset(50%) !important;white-space:nowrap !important}}";
|
|
@@ -23,7 +23,7 @@ const MgDetails$1 = /*@__PURE__*/ proxyCustomElement(class MgDetails extends HTM
|
|
|
23
23
|
this.expanded = false;
|
|
24
24
|
}
|
|
25
25
|
validateTitles(newValue) {
|
|
26
|
-
if (!
|
|
26
|
+
if (!Be(newValue)) {
|
|
27
27
|
throw new Error('<mg-details> prop "toggleClosed" and "toggleOpened" must be defined.');
|
|
28
28
|
}
|
|
29
29
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { R as Re, M as Me } from './index.es.js';
|
|
3
3
|
import { i as initLocales } from './index2.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
@@ -109,7 +109,7 @@ const MgForm$1 = /*@__PURE__*/ proxyCustomElement(class MgForm extends HTMLEleme
|
|
|
109
109
|
}
|
|
110
110
|
});
|
|
111
111
|
};
|
|
112
|
-
this.identifier =
|
|
112
|
+
this.identifier = Re('mg-form');
|
|
113
113
|
this.name = this.identifier;
|
|
114
114
|
this.readonly = false;
|
|
115
115
|
this.requiredMessage = undefined;
|
|
@@ -118,7 +118,7 @@ const MgForm$1 = /*@__PURE__*/ proxyCustomElement(class MgForm extends HTMLEleme
|
|
|
118
118
|
this.disabled = false;
|
|
119
119
|
this.valid = undefined;
|
|
120
120
|
this.invalid = undefined;
|
|
121
|
-
this.classCollection = new
|
|
121
|
+
this.classCollection = new Me(['mg-c-form']);
|
|
122
122
|
this.requiredMessageText = undefined;
|
|
123
123
|
}
|
|
124
124
|
validateRequiredMessage(newValue) {
|