@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
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { M as Me } from './index.es.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* List of all possibles sizes
|
|
@@ -461,7 +461,7 @@ const MgIcon = /*@__PURE__*/ proxyCustomElement(class MgIcon extends HTMLElement
|
|
|
461
461
|
this.variant = undefined;
|
|
462
462
|
this.variantStyle = undefined;
|
|
463
463
|
this.spin = false;
|
|
464
|
-
this.classCollection = new
|
|
464
|
+
this.classCollection = new Me(['mg-c-icon']);
|
|
465
465
|
}
|
|
466
466
|
validateIcon(newValue, oldValue) {
|
|
467
467
|
if (!iconList.includes(newValue))
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { F as Fe } from './index.es.js';
|
|
3
3
|
|
|
4
4
|
const mgIllustratedMessageCss = ".mg-c-illustrated-message{display:flex;max-width:47.5rem;box-sizing:border-box;flex-direction:column;justify-content:center;padding:var(--mg-illustrated-message-padding-vertical) 1.5rem;margin:auto;gap:3em 7rem;text-align:center}.mg-c-illustrated-message__illustration{max-height:18.4rem}.mg-c-illustrated-message__illustration ::slotted([slot=illustration]){width:auto;max-width:100%;height:auto;max-height:18.4rem}.mg-c-illustrated-message__illustration.mg-c-illustrated-message__illustration--small{max-height:6rem}.mg-c-illustrated-message__illustration.mg-c-illustrated-message__illustration--small ::slotted([slot=illustration]){max-height:6rem}.mg-c-illustrated-message.mg-c-illustrated-message--horizontal{max-width:unset;flex-flow:row wrap;align-items:center}.mg-c-illustrated-message.mg-c-illustrated-message--horizontal .mg-c-illustrated-message__slots,.mg-c-illustrated-message.mg-c-illustrated-message--horizontal .mg-c-illustrated-message__illustration{max-width:47.5rem}.mg-c-illustrated-message__title ::slotted([slot=title]){margin:0;font-family:var(--font-family) !important;font-size:2rem !important;font-weight:400 !important}.mg-c-illustrated-message__details ::slotted([slot=details]){margin:2rem 0 0}";
|
|
5
5
|
const MgIllustratedMessageStyle0 = mgIllustratedMessageCss;
|
|
@@ -21,7 +21,7 @@ const MgIllustratedMessage$1 = /*@__PURE__*/ proxyCustomElement(class MgIllustra
|
|
|
21
21
|
componentDidLoad() {
|
|
22
22
|
const headingTags = ['h1', 'h2', 'h3', 'h4', 'h5', 'h6'];
|
|
23
23
|
const slottedIllustrations = this.element.querySelectorAll('[slot="illustration"]');
|
|
24
|
-
if (!
|
|
24
|
+
if (!Fe(this.element.querySelector('[slot="title"]'), headingTags)) {
|
|
25
25
|
throw new Error(`<mg-illustrated-message> Slotted title must be a heading: ${headingTags.join(', ')}`);
|
|
26
26
|
}
|
|
27
27
|
else if (slottedIllustrations.length !== 1) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
2
2
|
import { H as Handler, M as MgInput } from './MgInput.js';
|
|
3
|
-
import {
|
|
3
|
+
import { N as Ne, M as Me, B as Be } from './index.es.js';
|
|
4
4
|
import { i as initLocales } from './index2.js';
|
|
5
5
|
import { d as defineCustomElement$a, S as SelectValuesButtonKey, c as checkboxTypes, a as SectionKind, M as MgInputCheckboxList } from './mg-input-checkbox-paginated2.js';
|
|
6
6
|
import { d as defineCustomElement$e } from './mg-button2.js';
|
|
@@ -156,7 +156,7 @@ const MgInputCheckbox$1 = /*@__PURE__*/ proxyCustomElement(class MgInputCheckbox
|
|
|
156
156
|
* Method to update searchResults
|
|
157
157
|
*/
|
|
158
158
|
this.updateSearchResults = () => {
|
|
159
|
-
this.searchResults = this.checkboxItems.filter(item =>
|
|
159
|
+
this.searchResults = this.checkboxItems.filter(item => Ne(item.title).includes(Ne(this.searchValue)));
|
|
160
160
|
};
|
|
161
161
|
/**
|
|
162
162
|
* Methode to validate if one of inputs value is checked id required
|
|
@@ -230,7 +230,7 @@ const MgInputCheckbox$1 = /*@__PURE__*/ proxyCustomElement(class MgInputCheckbox
|
|
|
230
230
|
this.helpText = undefined;
|
|
231
231
|
this.valid = undefined;
|
|
232
232
|
this.invalid = undefined;
|
|
233
|
-
this.classCollection = new
|
|
233
|
+
this.classCollection = new Me([this.baseClassName]);
|
|
234
234
|
this.errorMessage = undefined;
|
|
235
235
|
this.checkboxItems = [];
|
|
236
236
|
this.displaySearchInput = undefined;
|
|
@@ -317,7 +317,7 @@ const MgInputCheckbox$1 = /*@__PURE__*/ proxyCustomElement(class MgInputCheckbox
|
|
|
317
317
|
if (typeof valid !== 'boolean') {
|
|
318
318
|
throw new Error('<mg-input-checkbox> method "setError()" param "valid" must be a boolean');
|
|
319
319
|
}
|
|
320
|
-
else if (!
|
|
320
|
+
else if (!Be(errorMessage)) {
|
|
321
321
|
throw new Error('<mg-input-checkbox> method "setError()" param "errorMessage" must be a string');
|
|
322
322
|
}
|
|
323
323
|
else {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
2
2
|
import { H as Handler, M as MgInput } from './MgInput.js';
|
|
3
|
-
import {
|
|
3
|
+
import { B as Be, g as ge, W as We, P as Pe, M as Me, d as de } from './index.es.js';
|
|
4
4
|
import { i as initLocales } from './index2.js';
|
|
5
5
|
import { d as defineCustomElement$5 } from './mg-icon2.js';
|
|
6
6
|
import { d as defineCustomElement$4 } from './mg-input-title2.js';
|
|
@@ -34,10 +34,10 @@ const MgInputDate$1 = /*@__PURE__*/ proxyCustomElement(class MgInputDate extends
|
|
|
34
34
|
*/
|
|
35
35
|
this.formatHelpText = (helpText) => {
|
|
36
36
|
const defaultHelpTextVariable = '{defaultHelpText}';
|
|
37
|
-
let text =
|
|
37
|
+
let text = Be(helpText) ? helpText : this.messages.input.date.helpText;
|
|
38
38
|
if (text.includes(defaultHelpTextVariable))
|
|
39
39
|
text = text.replace(defaultHelpTextVariable, this.formatHelpText(this.messages.input.date.helpText));
|
|
40
|
-
return text.replace('{pattern}', this.renderPattern()).replace('{date}',
|
|
40
|
+
return text.replace('{pattern}', this.renderPattern()).replace('{date}', ge(We(new Date('2023-12-24')), this.systemLocale));
|
|
41
41
|
};
|
|
42
42
|
/**
|
|
43
43
|
* Handle input event
|
|
@@ -110,8 +110,8 @@ const MgInputDate$1 = /*@__PURE__*/ proxyCustomElement(class MgInputDate extends
|
|
|
110
110
|
// min, max & minMax
|
|
111
111
|
else if ([InputError.MIN, InputError.MAX, InputError.MINMAX].includes(inputError)) {
|
|
112
112
|
this.errorMessage = this.messages.errors.date[inputError]
|
|
113
|
-
.replace('{min}',
|
|
114
|
-
.replace('{max}',
|
|
113
|
+
.replace('{min}', ge(this.min, this.systemLocale))
|
|
114
|
+
.replace('{max}', ge(this.max, this.systemLocale));
|
|
115
115
|
}
|
|
116
116
|
// wrong date format
|
|
117
117
|
// element.validity.badInput is default error message
|
|
@@ -125,7 +125,7 @@ const MgInputDate$1 = /*@__PURE__*/ proxyCustomElement(class MgInputDate extends
|
|
|
125
125
|
* @returns translated html pattern
|
|
126
126
|
*/
|
|
127
127
|
this.renderPattern = () => {
|
|
128
|
-
let patternLocal =
|
|
128
|
+
let patternLocal = Pe(this.systemLocale);
|
|
129
129
|
for (const key in this.messages.input.date.pattern) {
|
|
130
130
|
patternLocal = patternLocal.replace(key, this.messages.input.date.pattern[key]);
|
|
131
131
|
}
|
|
@@ -147,14 +147,14 @@ const MgInputDate$1 = /*@__PURE__*/ proxyCustomElement(class MgInputDate extends
|
|
|
147
147
|
this.helpText = undefined;
|
|
148
148
|
this.valid = undefined;
|
|
149
149
|
this.invalid = undefined;
|
|
150
|
-
this.classCollection = new
|
|
150
|
+
this.classCollection = new Me(['mg-c-input--date']);
|
|
151
151
|
this.errorMessage = undefined;
|
|
152
152
|
}
|
|
153
153
|
validateValue(newValue) {
|
|
154
154
|
// When the input is not fully completed or has been cleared, the value becomes an empty string.
|
|
155
155
|
if (newValue === '')
|
|
156
156
|
newValue = null;
|
|
157
|
-
if (newValue !== undefined && newValue !== null && (typeof newValue !== 'string' || !
|
|
157
|
+
if (newValue !== undefined && newValue !== null && (typeof newValue !== 'string' || !de.test(newValue))) {
|
|
158
158
|
throw new Error("<mg-input-date> props 'value' doesn't match pattern: yyyy-mm-dd");
|
|
159
159
|
}
|
|
160
160
|
else {
|
|
@@ -162,7 +162,7 @@ const MgInputDate$1 = /*@__PURE__*/ proxyCustomElement(class MgInputDate extends
|
|
|
162
162
|
}
|
|
163
163
|
}
|
|
164
164
|
validateMinMax(newValue) {
|
|
165
|
-
if ((newValue === null || newValue === void 0 ? void 0 : newValue.length) === 0 || ((newValue === null || newValue === void 0 ? void 0 : newValue.length) > 0 && !(typeof newValue === 'string' &&
|
|
165
|
+
if ((newValue === null || newValue === void 0 ? void 0 : newValue.length) === 0 || ((newValue === null || newValue === void 0 ? void 0 : newValue.length) > 0 && !(typeof newValue === 'string' && de.test(newValue)))) {
|
|
166
166
|
throw new Error("<mg-input-date> props 'min/max' doesn't match pattern: yyyy-mm-dd");
|
|
167
167
|
}
|
|
168
168
|
}
|
|
@@ -196,7 +196,7 @@ const MgInputDate$1 = /*@__PURE__*/ proxyCustomElement(class MgInputDate extends
|
|
|
196
196
|
if (typeof valid !== 'boolean') {
|
|
197
197
|
throw new Error('<mg-input-date> method "setError()" param "valid" must be a boolean');
|
|
198
198
|
}
|
|
199
|
-
else if (!
|
|
199
|
+
else if (!Be(errorMessage)) {
|
|
200
200
|
throw new Error('<mg-input-date> method "setError()" param "errorMessage" must be a string');
|
|
201
201
|
}
|
|
202
202
|
else {
|
|
@@ -248,7 +248,7 @@ const MgInputDate$1 = /*@__PURE__*/ proxyCustomElement(class MgInputDate extends
|
|
|
248
248
|
* @returns HTML Element
|
|
249
249
|
*/
|
|
250
250
|
render() {
|
|
251
|
-
return (h(MgInput, { key: 'd6e63d2f60d8c1b977181b35ad1c5393ebbf9f2d', identifier: this.identifier, classCollection: this.classCollection, ariaDescribedbyIDs: [], label: this.label, labelOnTop: this.labelOnTop, labelHide: this.labelHide, required: this.required, readonly: this.readonly, mgWidth: undefined, disabled: this.disabled, value: this.value, readonlyValue:
|
|
251
|
+
return (h(MgInput, { key: 'd6e63d2f60d8c1b977181b35ad1c5393ebbf9f2d', identifier: this.identifier, classCollection: this.classCollection, ariaDescribedbyIDs: [], label: this.label, labelOnTop: this.labelOnTop, labelHide: this.labelHide, required: this.required, readonly: this.readonly, mgWidth: undefined, disabled: this.disabled, value: this.value, readonlyValue: ge(this.value, this.locale), tooltip: this.tooltip, tooltipPosition: this.tooltipPosition, helpText: this.formatHelpText(this.helpText), errorMessage: this.errorMessage, isFieldset: false }, h("input", { key: 'd94cfb21684af81db4dc3fc3ba1cc1fdfdaa2793', type: "date", class: "mg-c-input__box", min: this.min, max: this.max, value: this.value, id: this.identifier, name: this.name, disabled: this.disabled, required: this.required, "aria-invalid": (this.invalid === true).toString(), onInput: this.handleInput, onBlur: this.handleBlur, ref: (el) => {
|
|
252
252
|
if (el !== null)
|
|
253
253
|
this.input = el;
|
|
254
254
|
} })));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
2
2
|
import { H as Handler, M as MgInput } from './MgInput.js';
|
|
3
|
-
import {
|
|
3
|
+
import { z as ze, q as qe, M as Me, B as Be } from './index.es.js';
|
|
4
4
|
import { i as initLocales } from './index2.js';
|
|
5
5
|
import { d as defineCustomElement$5 } from './mg-icon2.js';
|
|
6
6
|
import { d as defineCustomElement$4 } from './mg-input-title2.js';
|
|
@@ -125,9 +125,9 @@ const MgInputNumeric$1 = /*@__PURE__*/ proxyCustomElement(class MgInputNumeric e
|
|
|
125
125
|
this.formatValue = (value) => {
|
|
126
126
|
switch (this.format) {
|
|
127
127
|
case 'number':
|
|
128
|
-
return
|
|
128
|
+
return qe(value, this.locale);
|
|
129
129
|
case 'currency':
|
|
130
|
-
return
|
|
130
|
+
return ze(value, this.locale, this.currency);
|
|
131
131
|
case 'none':
|
|
132
132
|
return value.toString();
|
|
133
133
|
}
|
|
@@ -164,7 +164,7 @@ const MgInputNumeric$1 = /*@__PURE__*/ proxyCustomElement(class MgInputNumeric e
|
|
|
164
164
|
this.decimalLength = 2;
|
|
165
165
|
this.valid = undefined;
|
|
166
166
|
this.invalid = undefined;
|
|
167
|
-
this.classCollection = new
|
|
167
|
+
this.classCollection = new Me(['mg-c-input--numeric']);
|
|
168
168
|
this.errorMessage = undefined;
|
|
169
169
|
this.hasFocus = undefined;
|
|
170
170
|
}
|
|
@@ -239,7 +239,7 @@ const MgInputNumeric$1 = /*@__PURE__*/ proxyCustomElement(class MgInputNumeric e
|
|
|
239
239
|
if (typeof valid !== 'boolean') {
|
|
240
240
|
throw new Error('<mg-input-numeric> method "setError()" param "valid" must be a boolean');
|
|
241
241
|
}
|
|
242
|
-
else if (!
|
|
242
|
+
else if (!Be(errorMessage)) {
|
|
243
243
|
throw new Error('<mg-input-numeric> method "setError()" param "errorMessage" must be a string');
|
|
244
244
|
}
|
|
245
245
|
else {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
2
2
|
import { H as Handler, M as MgInput } from './MgInput.js';
|
|
3
|
-
import {
|
|
3
|
+
import { M as Me, B as Be } from './index.es.js';
|
|
4
4
|
import { i as initLocales } from './index2.js';
|
|
5
5
|
import { d as defineCustomElement$5 } from './mg-icon2.js';
|
|
6
6
|
import { d as defineCustomElement$4 } from './mg-input-title2.js';
|
|
@@ -79,7 +79,7 @@ const MgInputPassword$1 = /*@__PURE__*/ proxyCustomElement(class MgInputPassword
|
|
|
79
79
|
this.helpText = undefined;
|
|
80
80
|
this.valid = undefined;
|
|
81
81
|
this.invalid = undefined;
|
|
82
|
-
this.classCollection = new
|
|
82
|
+
this.classCollection = new Me(['mg-c-input--password']);
|
|
83
83
|
this.errorMessage = undefined;
|
|
84
84
|
}
|
|
85
85
|
handleValue(newValue) {
|
|
@@ -115,7 +115,7 @@ const MgInputPassword$1 = /*@__PURE__*/ proxyCustomElement(class MgInputPassword
|
|
|
115
115
|
if (typeof valid !== 'boolean') {
|
|
116
116
|
throw new Error('<mg-input-password> method "setError()" param "valid" must be a boolean');
|
|
117
117
|
}
|
|
118
|
-
else if (!
|
|
118
|
+
else if (!Be(errorMessage)) {
|
|
119
119
|
throw new Error('<mg-input-password> method "setError()" param "errorMessage" must be a string');
|
|
120
120
|
}
|
|
121
121
|
else {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
2
2
|
import { H as Handler, M as MgInput } from './MgInput.js';
|
|
3
|
-
import {
|
|
3
|
+
import { M as Me, O as Oe, B as Be } from './index.es.js';
|
|
4
4
|
import { i as initLocales } from './index2.js';
|
|
5
5
|
import { d as defineCustomElement$5 } from './mg-icon2.js';
|
|
6
6
|
import { d as defineCustomElement$4 } from './mg-input-title2.js';
|
|
@@ -92,7 +92,7 @@ const MgInputRadio$1 = /*@__PURE__*/ proxyCustomElement(class MgInputRadio exten
|
|
|
92
92
|
this.helpText = undefined;
|
|
93
93
|
this.valid = undefined;
|
|
94
94
|
this.invalid = undefined;
|
|
95
|
-
this.classCollection = new
|
|
95
|
+
this.classCollection = new Me(['mg-c-input--radio']);
|
|
96
96
|
this.errorMessage = undefined;
|
|
97
97
|
this.options = undefined;
|
|
98
98
|
}
|
|
@@ -105,7 +105,7 @@ const MgInputRadio$1 = /*@__PURE__*/ proxyCustomElement(class MgInputRadio exten
|
|
|
105
105
|
throw new Error('<mg-input-radio> prop "items" require at least 2 items.');
|
|
106
106
|
}
|
|
107
107
|
// String array
|
|
108
|
-
else if (
|
|
108
|
+
else if (Oe(newValue)) {
|
|
109
109
|
this.options = newValue.map(item => ({ title: item, value: item, disabled: this.disabled }));
|
|
110
110
|
}
|
|
111
111
|
// Object array
|
|
@@ -146,7 +146,7 @@ const MgInputRadio$1 = /*@__PURE__*/ proxyCustomElement(class MgInputRadio exten
|
|
|
146
146
|
if (typeof valid !== 'boolean') {
|
|
147
147
|
throw new Error('<mg-input-radio> method "setError()" param "valid" must be a boolean');
|
|
148
148
|
}
|
|
149
|
-
else if (!
|
|
149
|
+
else if (!Be(errorMessage)) {
|
|
150
150
|
throw new Error('<mg-input-radio> method "setError()" param "errorMessage" must be a string');
|
|
151
151
|
}
|
|
152
152
|
else {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
2
2
|
import { H as Handler, M as MgInput } from './MgInput.js';
|
|
3
|
-
import {
|
|
3
|
+
import { O as Oe, M as Me, B as Be } from './index.es.js';
|
|
4
4
|
import { i as initLocales } from './index2.js';
|
|
5
5
|
import { d as defineCustomElement$4 } from './mg-icon2.js';
|
|
6
6
|
import { d as defineCustomElement$3 } from './mg-input-title2.js';
|
|
@@ -90,7 +90,7 @@ const MgInputSelect = /*@__PURE__*/ proxyCustomElement(class MgInputSelect exten
|
|
|
90
90
|
if (this.input.value === '') {
|
|
91
91
|
this.setValue(null);
|
|
92
92
|
}
|
|
93
|
-
else if (
|
|
93
|
+
else if (Oe(this.items) && this.items.includes(this.input.value)) {
|
|
94
94
|
this.setValue(this.input.value);
|
|
95
95
|
}
|
|
96
96
|
else if (allItemsAreOptions(this.items) && typeof this.input.value === 'string' && this.items.some(this.isInputValue)) {
|
|
@@ -165,7 +165,7 @@ const MgInputSelect = /*@__PURE__*/ proxyCustomElement(class MgInputSelect exten
|
|
|
165
165
|
this.helpText = undefined;
|
|
166
166
|
this.valid = undefined;
|
|
167
167
|
this.invalid = undefined;
|
|
168
|
-
this.classCollection = new
|
|
168
|
+
this.classCollection = new Me(['mg-c-input--select']);
|
|
169
169
|
this.errorMessage = undefined;
|
|
170
170
|
this.options = undefined;
|
|
171
171
|
this.valueExist = undefined;
|
|
@@ -173,7 +173,7 @@ const MgInputSelect = /*@__PURE__*/ proxyCustomElement(class MgInputSelect exten
|
|
|
173
173
|
}
|
|
174
174
|
validateValue(newValue) {
|
|
175
175
|
var _a, _b;
|
|
176
|
-
if (
|
|
176
|
+
if (Oe(this.items) && typeof newValue === 'string') {
|
|
177
177
|
this.readonlyValue = ((_a = this.input) === null || _a === void 0 ? void 0 : _a.value) ? this.input.value : newValue;
|
|
178
178
|
}
|
|
179
179
|
else if (allItemsAreOptions(this.items)) {
|
|
@@ -190,7 +190,7 @@ const MgInputSelect = /*@__PURE__*/ proxyCustomElement(class MgInputSelect exten
|
|
|
190
190
|
this.options = [];
|
|
191
191
|
}
|
|
192
192
|
// String array
|
|
193
|
-
else if (
|
|
193
|
+
else if (Oe(newValue)) {
|
|
194
194
|
if (typeof this.value === 'string')
|
|
195
195
|
this.valueExist = newValue.includes(this.value);
|
|
196
196
|
this.options = newValue.map(item => ({ title: item, value: item }));
|
|
@@ -241,7 +241,7 @@ const MgInputSelect = /*@__PURE__*/ proxyCustomElement(class MgInputSelect exten
|
|
|
241
241
|
if (typeof valid !== 'boolean') {
|
|
242
242
|
throw new Error('<mg-input-select> method "setError()" param "valid" must be a boolean');
|
|
243
243
|
}
|
|
244
|
-
else if (!
|
|
244
|
+
else if (!Be(errorMessage)) {
|
|
245
245
|
throw new Error('<mg-input-select> method "setError()" param "errorMessage" must be a string');
|
|
246
246
|
}
|
|
247
247
|
else {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
2
2
|
import { H as Handler, M as MgInput } from './MgInput.js';
|
|
3
|
-
import {
|
|
3
|
+
import { M as Me, B as Be } from './index.es.js';
|
|
4
4
|
import { i as initLocales } from './index2.js';
|
|
5
5
|
import { d as defineCustomElement$5 } from './mg-character-left2.js';
|
|
6
6
|
import { d as defineCustomElement$4 } from './mg-icon2.js';
|
|
@@ -43,7 +43,7 @@ const MgInputText = /*@__PURE__*/ proxyCustomElement(class MgInputText extends H
|
|
|
43
43
|
*/
|
|
44
44
|
this.handleFocus = () => {
|
|
45
45
|
this.classCollection.add(this.classFocus);
|
|
46
|
-
this.classCollection = new
|
|
46
|
+
this.classCollection = new Me(this.classCollection.classes);
|
|
47
47
|
};
|
|
48
48
|
/**
|
|
49
49
|
* Handle blur event
|
|
@@ -51,7 +51,7 @@ const MgInputText = /*@__PURE__*/ proxyCustomElement(class MgInputText extends H
|
|
|
51
51
|
this.handleBlur = () => {
|
|
52
52
|
// Manage focus
|
|
53
53
|
this.classCollection.delete(this.classFocus);
|
|
54
|
-
this.classCollection = new
|
|
54
|
+
this.classCollection = new Me(this.classCollection.classes);
|
|
55
55
|
// Display Error
|
|
56
56
|
this.handlerInProgress = Handler.BLUR;
|
|
57
57
|
this.displayError().finally(() => {
|
|
@@ -127,7 +127,7 @@ const MgInputText = /*@__PURE__*/ proxyCustomElement(class MgInputText extends H
|
|
|
127
127
|
this.helpText = undefined;
|
|
128
128
|
this.valid = undefined;
|
|
129
129
|
this.invalid = undefined;
|
|
130
|
-
this.classCollection = new
|
|
130
|
+
this.classCollection = new Me(['mg-c-input--text']);
|
|
131
131
|
this.errorMessage = undefined;
|
|
132
132
|
}
|
|
133
133
|
handleValue(newValue) {
|
|
@@ -157,7 +157,7 @@ const MgInputText = /*@__PURE__*/ proxyCustomElement(class MgInputText extends H
|
|
|
157
157
|
}
|
|
158
158
|
}
|
|
159
159
|
validatePattern(newValue) {
|
|
160
|
-
if (newValue !== undefined && !(
|
|
160
|
+
if (newValue !== undefined && !(Be(this.pattern) && Be(this.patternErrorMessage))) {
|
|
161
161
|
throw new Error('<mg-input-text> props "pattern" and "patternErrorMessage" must be non-empty string and paired.');
|
|
162
162
|
}
|
|
163
163
|
}
|
|
@@ -187,7 +187,7 @@ const MgInputText = /*@__PURE__*/ proxyCustomElement(class MgInputText extends H
|
|
|
187
187
|
if (typeof valid !== 'boolean') {
|
|
188
188
|
throw new Error('<mg-input-text> method "setError()" param "valid" must be a boolean');
|
|
189
189
|
}
|
|
190
|
-
else if (!
|
|
190
|
+
else if (!Be(errorMessage)) {
|
|
191
191
|
throw new Error('<mg-input-text> method "setError()" param "errorMessage" must be a string');
|
|
192
192
|
}
|
|
193
193
|
else {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
2
2
|
import { H as Handler, M as MgInput } from './MgInput.js';
|
|
3
|
-
import {
|
|
3
|
+
import { M as Me, B as Be } from './index.es.js';
|
|
4
4
|
import { i as initLocales } from './index2.js';
|
|
5
5
|
import { d as defineCustomElement$6 } from './mg-character-left2.js';
|
|
6
6
|
import { d as defineCustomElement$5 } from './mg-icon2.js';
|
|
@@ -41,7 +41,7 @@ const MgInputTextarea$1 = /*@__PURE__*/ proxyCustomElement(class MgInputTextarea
|
|
|
41
41
|
*/
|
|
42
42
|
this.handleFocus = () => {
|
|
43
43
|
this.classCollection.add(this.classFocus);
|
|
44
|
-
this.classCollection = new
|
|
44
|
+
this.classCollection = new Me(this.classCollection.classes);
|
|
45
45
|
};
|
|
46
46
|
/**
|
|
47
47
|
* Handle blur event
|
|
@@ -49,7 +49,7 @@ const MgInputTextarea$1 = /*@__PURE__*/ proxyCustomElement(class MgInputTextarea
|
|
|
49
49
|
this.handleBlur = () => {
|
|
50
50
|
// Manage focus
|
|
51
51
|
this.classCollection.delete(this.classFocus);
|
|
52
|
-
this.classCollection = new
|
|
52
|
+
this.classCollection = new Me(this.classCollection.classes);
|
|
53
53
|
// Display Error
|
|
54
54
|
this.handlerInProgress = Handler.BLUR;
|
|
55
55
|
this.displayError().finally(() => {
|
|
@@ -113,7 +113,7 @@ const MgInputTextarea$1 = /*@__PURE__*/ proxyCustomElement(class MgInputTextarea
|
|
|
113
113
|
this.valid = undefined;
|
|
114
114
|
this.invalid = undefined;
|
|
115
115
|
this.resizable = 'none';
|
|
116
|
-
this.classCollection = new
|
|
116
|
+
this.classCollection = new Me(['mg-c-input--textarea']);
|
|
117
117
|
this.errorMessage = undefined;
|
|
118
118
|
}
|
|
119
119
|
handleValue(newValue) {
|
|
@@ -131,7 +131,7 @@ const MgInputTextarea$1 = /*@__PURE__*/ proxyCustomElement(class MgInputTextarea
|
|
|
131
131
|
}
|
|
132
132
|
}
|
|
133
133
|
validatePattern(newValue) {
|
|
134
|
-
if (newValue !== undefined && !(
|
|
134
|
+
if (newValue !== undefined && !(Be(this.pattern) && Be(this.patternErrorMessage))) {
|
|
135
135
|
throw new Error('<mg-input-textarea> props "pattern" and "patternErrorMessage" must be non-empty string and paired.');
|
|
136
136
|
}
|
|
137
137
|
}
|
|
@@ -163,7 +163,7 @@ const MgInputTextarea$1 = /*@__PURE__*/ proxyCustomElement(class MgInputTextarea
|
|
|
163
163
|
if (typeof valid !== 'boolean') {
|
|
164
164
|
throw new Error('<mg-input-textarea> method "setError()" param "valid" must be a boolean');
|
|
165
165
|
}
|
|
166
|
-
else if (!
|
|
166
|
+
else if (!Be(errorMessage)) {
|
|
167
167
|
throw new Error('<mg-input-textarea> method "setError()" param "errorMessage" must be a string');
|
|
168
168
|
}
|
|
169
169
|
else {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { B as Be } from './index.es.js';
|
|
3
3
|
|
|
4
4
|
const mgInputTitleCss = ".mg-u-form-legacy.sc-mg-input-title{--mg-form-inputs-title-width:calc(100% / 3 - 20px)}.mg-u-is-asterisk.sc-mg-input-title{color:hsl(var(--color-danger))}legend.mg-c-input-title.sc-mg-input-title{padding-right:0;padding-left:0}.mg-c-input-title__required.sc-mg-input-title{display:var(--mg-input-title-display, unset)}";
|
|
5
5
|
const MgInputTitleStyle0 = mgInputTitleCss;
|
|
@@ -15,7 +15,7 @@ const MgInputTitle = /*@__PURE__*/ proxyCustomElement(class MgInputTitle extends
|
|
|
15
15
|
this.tagName = 'label';
|
|
16
16
|
}
|
|
17
17
|
validateIdentifier(newValue) {
|
|
18
|
-
if (!
|
|
18
|
+
if (!Be(newValue)) {
|
|
19
19
|
throw new Error('<mg-input-title> prop "identifier" is required.');
|
|
20
20
|
}
|
|
21
21
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
2
2
|
import { M as MgInput } from './MgInput.js';
|
|
3
|
-
import {
|
|
3
|
+
import { M as Me, O as Oe, B as Be } from './index.es.js';
|
|
4
4
|
import { d as defineCustomElement$5 } from './mg-icon2.js';
|
|
5
5
|
import { d as defineCustomElement$4 } from './mg-input-title2.js';
|
|
6
6
|
import { d as defineCustomElement$3 } from './mg-tooltip2.js';
|
|
@@ -90,7 +90,7 @@ const MgInputToggle$1 = /*@__PURE__*/ proxyCustomElement(class MgInputToggle ext
|
|
|
90
90
|
this.tooltip = undefined;
|
|
91
91
|
this.tooltipPosition = 'input';
|
|
92
92
|
this.helpText = undefined;
|
|
93
|
-
this.classCollection = new
|
|
93
|
+
this.classCollection = new Me(['mg-c-input--toggle']);
|
|
94
94
|
this.options = undefined;
|
|
95
95
|
this.errorMessage = undefined;
|
|
96
96
|
this.valid = undefined;
|
|
@@ -107,7 +107,7 @@ const MgInputToggle$1 = /*@__PURE__*/ proxyCustomElement(class MgInputToggle ext
|
|
|
107
107
|
throw new Error('<mg-input-toggle> prop "items" require 2 items.');
|
|
108
108
|
}
|
|
109
109
|
// String array
|
|
110
|
-
else if (
|
|
110
|
+
else if (Oe(newValue)) {
|
|
111
111
|
this.options = newValue.map(item => ({ title: item, value: item }));
|
|
112
112
|
}
|
|
113
113
|
// Object array
|
|
@@ -157,7 +157,7 @@ const MgInputToggle$1 = /*@__PURE__*/ proxyCustomElement(class MgInputToggle ext
|
|
|
157
157
|
if (typeof valid !== 'boolean') {
|
|
158
158
|
throw new Error('<mg-input-toggle> method "setError()" param "valid" must be a boolean');
|
|
159
159
|
}
|
|
160
|
-
else if (!
|
|
160
|
+
else if (!Be(errorMessage)) {
|
|
161
161
|
throw new Error('<mg-input-toggle> method "setError()" param "errorMessage" must be a string');
|
|
162
162
|
}
|
|
163
163
|
else {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
import { i as initLocales } from './index2.js';
|
|
3
3
|
import { D as Direction } from './mg-menu.conf.js';
|
|
4
|
-
import {
|
|
4
|
+
import { B as Be } from './index.es.js';
|
|
5
5
|
import { d as defineCustomElement$9 } from './mg-badge2.js';
|
|
6
6
|
import { d as defineCustomElement$8 } from './mg-button2.js';
|
|
7
7
|
import { d as defineCustomElement$7 } from './mg-card2.js';
|
|
@@ -187,7 +187,7 @@ const MgItemMore$1 = /*@__PURE__*/ proxyCustomElement(class MgItemMore extends H
|
|
|
187
187
|
navElement.click();
|
|
188
188
|
});
|
|
189
189
|
// add id suffix to prevent duplicate key. default html id is: '';
|
|
190
|
-
if (
|
|
190
|
+
if (Be(proxy.id))
|
|
191
191
|
proxy.id = `${proxy.id}-proxy`;
|
|
192
192
|
// manage status change miror in proxy
|
|
193
193
|
allMenuItem[index].addEventListener('status-change', (event) => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
|
|
2
2
|
import { i as initLocales } from './index2.js';
|
|
3
|
-
import {
|
|
3
|
+
import { B as Be } from './index.es.js';
|
|
4
4
|
import { d as defineCustomElement$2 } from './mg-icon2.js';
|
|
5
5
|
|
|
6
6
|
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}";
|
|
@@ -15,7 +15,7 @@ const MgLoader$1 = /*@__PURE__*/ proxyCustomElement(class MgLoader extends HTMLE
|
|
|
15
15
|
this.messageHide = undefined;
|
|
16
16
|
}
|
|
17
17
|
watchMessage(newValue) {
|
|
18
|
-
if (newValue && !
|
|
18
|
+
if (newValue && !Be(newValue))
|
|
19
19
|
throw new Error('<mg-loader> prop "message" must be a valid string.');
|
|
20
20
|
}
|
|
21
21
|
/*************
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { B as Be, R as Re, M as Me } from './index.es.js';
|
|
3
3
|
import { i as initLocales } from './index2.js';
|
|
4
4
|
import { D as Direction } from './mg-menu.conf.js';
|
|
5
5
|
import { d as defineCustomElement$6 } from './mg-badge2.js';
|
|
@@ -95,7 +95,7 @@ const MgMenuItem = /*@__PURE__*/ proxyCustomElement(class MgMenuItem extends HTM
|
|
|
95
95
|
throw new Error(`<${this.name}> slot "label" is required.`);
|
|
96
96
|
['label', 'metadata'].forEach(slot => {
|
|
97
97
|
Array.from(this.element.querySelectorAll(`[slot="${slot}"]`)).forEach(element => {
|
|
98
|
-
if (!
|
|
98
|
+
if (!Be(element.textContent))
|
|
99
99
|
throw new Error(`<${this.name}> slot "${slot}" must have text content.`);
|
|
100
100
|
if ((guard && element.getAttribute('title') === null) || !guard)
|
|
101
101
|
element.setAttribute('title', element.textContent);
|
|
@@ -164,12 +164,12 @@ const MgMenuItem = /*@__PURE__*/ proxyCustomElement(class MgMenuItem extends HTM
|
|
|
164
164
|
* @returns HTML Element
|
|
165
165
|
*/
|
|
166
166
|
this.renderSlot = () => h("slot", null);
|
|
167
|
-
this.identifier =
|
|
167
|
+
this.identifier = Re('mg-menu-item');
|
|
168
168
|
this.href = undefined;
|
|
169
169
|
this.status = Status.VISIBLE;
|
|
170
170
|
this.expanded = false;
|
|
171
171
|
this.size = 'regular';
|
|
172
|
-
this.navigationButtonClassList = new
|
|
172
|
+
this.navigationButtonClassList = new Me([this.navigationButton]);
|
|
173
173
|
this.direction = undefined;
|
|
174
174
|
this.isInMainMenu = undefined;
|
|
175
175
|
this.isItemMore = undefined;
|
|
@@ -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
|
import { d as defineCustomElement$4 } from './mg-button2.js';
|
|
5
5
|
import { d as defineCustomElement$3 } from './mg-card2.js';
|
|
@@ -83,13 +83,13 @@ const MgMessage$1 = /*@__PURE__*/ proxyCustomElement(class MgMessage extends HTM
|
|
|
83
83
|
return 'exclamation-circle';
|
|
84
84
|
}
|
|
85
85
|
};
|
|
86
|
-
this.identifier =
|
|
86
|
+
this.identifier = Re('mg-message');
|
|
87
87
|
this.delay = undefined;
|
|
88
88
|
this.variant = variants[0];
|
|
89
89
|
this.closeButton = false;
|
|
90
90
|
this.hide = false;
|
|
91
91
|
this.noAriaRole = undefined;
|
|
92
|
-
this.classCollection = new
|
|
92
|
+
this.classCollection = new Me(['mg-c-message']);
|
|
93
93
|
this.hasActions = false;
|
|
94
94
|
}
|
|
95
95
|
validateDelay(newValue) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { D as De, R as Re, M as Me, B as Be } from './index.es.js';
|
|
3
3
|
import { i as initLocales } from './index2.js';
|
|
4
4
|
import { d as defineCustomElement$4 } from './mg-button2.js';
|
|
5
5
|
import { d as defineCustomElement$3 } from './mg-card2.js';
|
|
@@ -59,12 +59,12 @@ const MgModal$1 = /*@__PURE__*/ proxyCustomElement(class MgModal extends HTMLEle
|
|
|
59
59
|
*/
|
|
60
60
|
this.setFocus = () => {
|
|
61
61
|
// Get all focusable elements
|
|
62
|
-
const slottedFocusableElements = Array.from(this.element.querySelectorAll(
|
|
62
|
+
const slottedFocusableElements = Array.from(this.element.querySelectorAll(De));
|
|
63
63
|
// If close button is enabled or at least one of the slotted element is focusable
|
|
64
64
|
if (this.closeButton || slottedFocusableElements.length > 0) {
|
|
65
65
|
// Check if slotted focusable elements have shadowDom with focusable elements
|
|
66
66
|
this.modalFocusableElements = slottedFocusableElements.reduce((acc, focusableElement) => {
|
|
67
|
-
acc.push(focusableElement.shadowRoot !== null ? focusableElement.shadowRoot.querySelector(
|
|
67
|
+
acc.push(focusableElement.shadowRoot !== null ? focusableElement.shadowRoot.querySelector(De) || focusableElement : focusableElement);
|
|
68
68
|
return acc;
|
|
69
69
|
}, []);
|
|
70
70
|
// When close button is enabled it's the first focusable element.
|
|
@@ -86,21 +86,21 @@ const MgModal$1 = /*@__PURE__*/ proxyCustomElement(class MgModal extends HTMLEle
|
|
|
86
86
|
this.handleClose = () => {
|
|
87
87
|
this.hide = true;
|
|
88
88
|
};
|
|
89
|
-
this.identifier =
|
|
89
|
+
this.identifier = Re('mg-modal');
|
|
90
90
|
this.dialogRole = dialogRoles[0];
|
|
91
91
|
this.modalTitle = undefined;
|
|
92
92
|
this.closeButton = false;
|
|
93
93
|
this.hide = undefined;
|
|
94
94
|
this.hasActions = false;
|
|
95
95
|
this.hasContent = false;
|
|
96
|
-
this.classCollection = new
|
|
96
|
+
this.classCollection = new Me(['mg-c-modal']);
|
|
97
97
|
}
|
|
98
98
|
validateDialogRole(newValue) {
|
|
99
99
|
if (!dialogRoles.includes(newValue))
|
|
100
100
|
throw new Error(`<mg-modal> prop "dialogRole" must be one of: ${dialogRoles.join(', ')}.`);
|
|
101
101
|
}
|
|
102
102
|
validateModalTitle(newValue) {
|
|
103
|
-
if (!
|
|
103
|
+
if (!Be(newValue)) {
|
|
104
104
|
throw new Error('<mg-modal> prop "modalTitle" is required.');
|
|
105
105
|
}
|
|
106
106
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
|
2
|
-
import {
|
|
2
|
+
import { R as Re } from './index.es.js';
|
|
3
3
|
import { i as initLocales } from './index2.js';
|
|
4
4
|
import { d as defineCustomElement$6 } from './mg-button2.js';
|
|
5
5
|
import { d as defineCustomElement$5 } from './mg-icon2.js';
|
|
@@ -71,7 +71,7 @@ const MgPagination = /*@__PURE__*/ proxyCustomElement(class MgPagination extends
|
|
|
71
71
|
this.handleGoToPage = (action, disabled) => {
|
|
72
72
|
!disabled && this.goToPage(action === NavigationAction.NEXT ? this.currentPage + 1 : this.currentPage - 1);
|
|
73
73
|
};
|
|
74
|
-
this.identifier =
|
|
74
|
+
this.identifier = Re('mg-pagination');
|
|
75
75
|
this.label = undefined;
|
|
76
76
|
this.hideNavigationLabels = undefined;
|
|
77
77
|
this.hidePageCount = undefined;
|