@riverty/web-components 5.3.0 → 5.4.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/CHANGELOG.md +27 -1
- package/custom-elements.json +32 -4
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/r-badge.cjs.entry.js +1 -1
- package/dist/cjs/r-dialog.cjs.entry.js +9 -10
- package/dist/cjs/r-hint_3.cjs.entry.js +4 -4
- package/dist/cjs/r-icon-button.cjs.entry.js +3 -3
- package/dist/cjs/r-input-code.cjs.entry.js +23 -7
- package/dist/cjs/r-input-date.cjs.entry.js +28 -7
- package/dist/cjs/r-input-password.cjs.entry.js +15 -4
- package/dist/cjs/r-input-phone-number.cjs.entry.js +57 -19
- package/dist/cjs/r-input.cjs.entry.js +15 -3
- package/dist/cjs/r-list-item.cjs.entry.js +13 -9
- package/dist/cjs/r-panel.cjs.entry.js +2 -2
- package/dist/cjs/r-popover-action.cjs.entry.js +1 -1
- package/dist/cjs/r-popover-content.cjs.entry.js +1 -1
- package/dist/cjs/r-popover-headline.cjs.entry.js +1 -1
- package/dist/cjs/r-popover-trigger.cjs.entry.js +1 -1
- package/dist/cjs/r-popover.cjs.entry.js +2 -2
- package/dist/cjs/r-progress-bar.cjs.entry.js +1 -1
- package/dist/cjs/r-radio-button-description.cjs.entry.js +1 -1
- package/dist/cjs/r-radio-button-leading.cjs.entry.js +1 -1
- package/dist/cjs/r-radio-button-title.cjs.entry.js +1 -1
- package/dist/cjs/r-radio-button-trailing.cjs.entry.js +1 -1
- package/dist/cjs/r-radio-button.cjs.entry.js +5 -5
- package/dist/cjs/r-radio-group.cjs.entry.js +6 -6
- package/dist/cjs/r-select-option.cjs.entry.js +1 -1
- package/dist/cjs/r-select.cjs.entry.js +5 -4
- package/dist/cjs/r-skip-link.cjs.entry.js +1 -1
- package/dist/cjs/r-stepper-item.cjs.entry.js +2 -2
- package/dist/cjs/r-stepper.cjs.entry.js +1 -1
- package/dist/cjs/r-tab-panel.cjs.entry.js +1 -1
- package/dist/cjs/r-tab.cjs.entry.js +1 -1
- package/dist/cjs/r-tabs-list.cjs.entry.js +1 -1
- package/dist/cjs/r-tabs.cjs.entry.js +3 -3
- package/dist/cjs/r-textarea.cjs.entry.js +17 -3
- package/dist/cjs/r-toast-group.cjs.entry.js +1 -1
- package/dist/cjs/r-toast.cjs.entry.js +15 -9
- package/dist/cjs/web-components.cjs.js +1 -1
- package/dist/collection/components/badge/badge.css +7 -7
- package/dist/collection/components/dialog/dialog.css +13 -13
- package/dist/collection/components/dialog/dialog.js +8 -9
- package/dist/collection/components/icon-button/icon-button.js +3 -3
- package/dist/collection/components/input/input.css +17 -2
- package/dist/collection/components/input/input.js +33 -2
- package/dist/collection/components/input-code/input-code.css +17 -2
- package/dist/collection/components/input-code/input-code.js +41 -6
- package/dist/collection/components/input-date/input-date.css +13 -2
- package/dist/collection/components/input-date/input-date.js +46 -6
- package/dist/collection/components/input-password/input-password.js +34 -4
- package/dist/collection/components/input-phone-number/input-phone-number.js +79 -18
- package/dist/collection/components/label/label.js +3 -3
- package/dist/collection/components/list-item/list-item/list-item.css +21 -22
- package/dist/collection/components/list-item/list-item/list-item.js +36 -10
- package/dist/collection/components/panel/panel.js +2 -2
- package/dist/collection/components/popover/popover.js +2 -2
- package/dist/collection/components/popover-action/popover-action.js +1 -1
- package/dist/collection/components/popover-content/popover-content.js +1 -1
- package/dist/collection/components/popover-headline/popover-headline.js +1 -1
- package/dist/collection/components/popover-trigger/popover-trigger.js +1 -1
- package/dist/collection/components/progress-bar/progress-bar.js +1 -1
- package/dist/collection/components/radio-button/radio-button.js +5 -5
- package/dist/collection/components/radio-button-description/radio-button-description.js +1 -1
- package/dist/collection/components/radio-button-leading/radio-button-leading.js +1 -1
- package/dist/collection/components/radio-button-title/radio-button-title.js +1 -1
- package/dist/collection/components/radio-button-trailing/radio-button-trailing.js +1 -1
- package/dist/collection/components/radio-group/radio-group.js +6 -6
- package/dist/collection/components/select/select.js +5 -4
- package/dist/collection/components/select-option/select-option.js +1 -1
- package/dist/collection/components/skip-link/skip-link.js +1 -1
- package/dist/collection/components/stepper/stepper.js +1 -1
- package/dist/collection/components/stepper-item/stepper-item.js +2 -2
- package/dist/collection/components/tab/tab.js +1 -1
- package/dist/collection/components/tab-panel/tab-panel.js +1 -1
- package/dist/collection/components/tabs/tabs.js +3 -3
- package/dist/collection/components/tabs-list/tabs-list.js +1 -1
- package/dist/collection/components/textarea/textarea.css +52 -21
- package/dist/collection/components/textarea/textarea.js +36 -3
- package/dist/collection/components/toast/toast.css +2 -1
- package/dist/collection/components/toast/toast.js +19 -10
- package/dist/collection/components/toast-group/toast-group.js +1 -1
- package/dist/collection/components/tooltip/tooltip.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/r-badge.entry.js +1 -1
- package/dist/esm/r-dialog.entry.js +9 -10
- package/dist/esm/r-hint_3.entry.js +4 -4
- package/dist/esm/r-icon-button.entry.js +3 -3
- package/dist/esm/r-input-code.entry.js +23 -7
- package/dist/esm/r-input-date.entry.js +28 -7
- package/dist/esm/r-input-password.entry.js +15 -4
- package/dist/esm/r-input-phone-number.entry.js +57 -19
- package/dist/esm/r-input.entry.js +15 -3
- package/dist/esm/r-list-item.entry.js +13 -9
- package/dist/esm/r-panel.entry.js +2 -2
- package/dist/esm/r-popover-action.entry.js +1 -1
- package/dist/esm/r-popover-content.entry.js +1 -1
- package/dist/esm/r-popover-headline.entry.js +1 -1
- package/dist/esm/r-popover-trigger.entry.js +1 -1
- package/dist/esm/r-popover.entry.js +2 -2
- package/dist/esm/r-progress-bar.entry.js +1 -1
- package/dist/esm/r-radio-button-description.entry.js +1 -1
- package/dist/esm/r-radio-button-leading.entry.js +1 -1
- package/dist/esm/r-radio-button-title.entry.js +1 -1
- package/dist/esm/r-radio-button-trailing.entry.js +1 -1
- package/dist/esm/r-radio-button.entry.js +5 -5
- package/dist/esm/r-radio-group.entry.js +6 -6
- package/dist/esm/r-select-option.entry.js +1 -1
- package/dist/esm/r-select.entry.js +5 -4
- package/dist/esm/r-skip-link.entry.js +1 -1
- package/dist/esm/r-stepper-item.entry.js +2 -2
- package/dist/esm/r-stepper.entry.js +1 -1
- package/dist/esm/r-tab-panel.entry.js +1 -1
- package/dist/esm/r-tab.entry.js +1 -1
- package/dist/esm/r-tabs-list.entry.js +1 -1
- package/dist/esm/r-tabs.entry.js +3 -3
- package/dist/esm/r-textarea.entry.js +17 -3
- package/dist/esm/r-toast-group.entry.js +1 -1
- package/dist/esm/r-toast.entry.js +15 -9
- package/dist/esm/web-components.js +1 -1
- package/dist/types/components/dialog/dialog.d.ts +1 -0
- package/dist/types/components/input/input.d.ts +6 -0
- package/dist/types/components/input-code/input-code.d.ts +6 -0
- package/dist/types/components/input-date/input-date.d.ts +6 -0
- package/dist/types/components/input-password/input-password.d.ts +5 -0
- package/dist/types/components/input-phone-number/input-phone-number.d.ts +7 -0
- package/dist/types/components/list-item/list-item/list-item.d.ts +11 -3
- package/dist/types/components/textarea/textarea.d.ts +8 -1
- package/dist/types/components/toast/toast.d.ts +6 -0
- package/dist/types/components.d.ts +66 -8
- package/dist/web-components/p-05ba30ba.entry.js +1 -0
- package/dist/web-components/p-0a424361.entry.js +1 -0
- package/dist/web-components/p-0ac858b8.entry.js +1 -0
- package/dist/web-components/p-0bb0de18.entry.js +1 -0
- package/dist/web-components/{p-5dd43433.entry.js → p-10724c18.entry.js} +1 -1
- package/dist/web-components/{p-59aa588e.entry.js → p-1157b7f4.entry.js} +1 -1
- package/dist/web-components/{p-5bc9fe5e.entry.js → p-135be1d5.entry.js} +1 -1
- package/dist/web-components/{p-5cd1ad6a.entry.js → p-1ed3efd7.entry.js} +1 -1
- package/dist/web-components/p-20f979ff.entry.js +1 -0
- package/dist/web-components/p-2394508f.entry.js +1 -0
- package/dist/web-components/{p-a45fd808.entry.js → p-2d85c0f3.entry.js} +1 -1
- package/dist/web-components/p-31c8388d.entry.js +1 -0
- package/dist/web-components/p-333707b2.entry.js +1 -0
- package/dist/web-components/p-3ea6a1be.entry.js +1 -0
- package/dist/web-components/p-3fc2b23b.entry.js +1 -0
- package/dist/web-components/{p-77335ae7.entry.js → p-48dfb286.entry.js} +1 -1
- package/dist/web-components/p-61f78bf6.entry.js +1 -0
- package/dist/web-components/{p-806b173d.entry.js → p-66c454ce.entry.js} +1 -1
- package/dist/web-components/{p-26e4816a.entry.js → p-71d6c4d7.entry.js} +1 -1
- package/dist/web-components/{p-4dae8c19.entry.js → p-735da2bb.entry.js} +1 -1
- package/dist/web-components/p-77dc268e.entry.js +1 -0
- package/dist/web-components/{p-512d3a60.entry.js → p-89ff32dc.entry.js} +1 -1
- package/dist/web-components/{p-0930ee1d.entry.js → p-8d6a35e3.entry.js} +1 -1
- package/dist/web-components/{p-90d390f4.entry.js → p-8f719321.entry.js} +1 -1
- package/dist/web-components/{p-d35303a6.entry.js → p-900923ab.entry.js} +1 -1
- package/dist/web-components/{p-651522b6.entry.js → p-988a7731.entry.js} +1 -1
- package/dist/web-components/{p-7545038f.entry.js → p-9c40f9cd.entry.js} +1 -1
- package/dist/web-components/p-aecd025b.entry.js +1 -0
- package/dist/web-components/{p-87bb4b91.entry.js → p-c7a9da98.entry.js} +1 -1
- package/dist/web-components/p-caca2855.entry.js +1 -0
- package/dist/web-components/{p-8968ddf6.entry.js → p-dc93ed55.entry.js} +1 -1
- package/dist/web-components/p-df81177e.entry.js +1 -0
- package/dist/web-components/{p-a81a67da.entry.js → p-e273950c.entry.js} +1 -1
- package/dist/web-components/{p-832dca22.entry.js → p-e50503d0.entry.js} +1 -1
- package/dist/web-components/p-fdf70aed.entry.js +1 -0
- package/dist/web-components/web-components.esm.js +1 -1
- package/package.json +1 -1
- package/dist/web-components/p-0bd10e93.entry.js +0 -1
- package/dist/web-components/p-15d10c68.entry.js +0 -1
- package/dist/web-components/p-1cfa9a0e.entry.js +0 -1
- package/dist/web-components/p-23ff25a1.entry.js +0 -1
- package/dist/web-components/p-50f01d6b.entry.js +0 -1
- package/dist/web-components/p-547fc56c.entry.js +0 -1
- package/dist/web-components/p-73adec9b.entry.js +0 -1
- package/dist/web-components/p-8388221b.entry.js +0 -1
- package/dist/web-components/p-8cc4be0c.entry.js +0 -1
- package/dist/web-components/p-98628a15.entry.js +0 -1
- package/dist/web-components/p-aff51d37.entry.js +0 -1
- package/dist/web-components/p-b07be088.entry.js +0 -1
- package/dist/web-components/p-b5c8e978.entry.js +0 -1
- package/dist/web-components/p-d6ef5fff.entry.js +0 -1
- package/dist/web-components/p-dfd8bed6.entry.js +0 -1
- package/dist/web-components/p-e138c70a.entry.js +0 -1
|
@@ -290,8 +290,8 @@ const Popover = class {
|
|
|
290
290
|
this.open ? this.show() : this.hide();
|
|
291
291
|
}
|
|
292
292
|
render() {
|
|
293
|
-
return (index.h(index.Host, { key: '
|
|
294
|
-
index.h("r-icon-button", { key: '
|
|
293
|
+
return (index.h(index.Host, { key: 'da45eae6a21cc01596344d33afc5def4da57967f', id: this.uniqueId, "data-position": this.positionState, "data-open": `${this.isOpen}`, open: this.isOpen }, index.h("div", { key: 'ad832de894e0af250cc93bdf3158032bc252740f', class: "r-popover" }, index.h("button", { key: '28c4938bb02cb7c4eaed074178dda00c2c39a0b7', class: "r-popover--trigger", "aria-label": this.triggerAriaLabel, ref: el => this.triggerElement = el, popoverTarget: `${this.uniqueId}-board`, popoverTargetAction: this.triggerAction }, index.h("slot", { key: '0a74ac9d6a7ecdba54771e733f8db5af1709e7fb', name: "trigger" })), index.h("div", { key: 'dbdb43df6a9823f5d8c954146347f40438bbf053', class: "r-popover--board", id: `${this.uniqueId}-board`, popover: this.dismissMode, ref: el => this.boardElement = el, onToggle: this.onToggle, onKeyDown: this.onKeyDown }, this.hasDismiss &&
|
|
294
|
+
index.h("r-icon-button", { key: '99cb4c1c050cdf197346ef84f7c610f5f6ed0b4c', ref: el => this.dismissElement = el, class: "r-popover--dismiss", name: "cross", onClick: this.onClickDismiss, label: this.dismissAriaLabel }), index.h("div", { key: 'fe7e18bd38a4f3879aada14169bfa50f84cd2eac', class: "r-popover--board-content" }, index.h("slot", { key: 'b5674f8f2f72340cf5af712f513a20bda9e04b47', name: "headline" }), index.h("slot", { key: '024ce9cc17f041df172d853176d09f4ec493df20', name: "content" }), index.h("slot", { key: '437ca7707856b7c6db59240d7b4378c74dc8fda8', name: "action" })), index.h("div", { key: '93184bd493520dbea03c7c63bbfe8c4ae788cde3', class: "r-popover--board-pointer", "aria-hidden": "true" }, index.h("svg", { key: '779d8b7df8f92ea14517ce9ce5099a73a4fdeac8', width: "16", height: "8", viewBox: "0 0 16 8", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, index.h("path", { key: '53b9fee3e6a34cf184d8818ac272122f04193ff6', d: "M8 8L0 0L16 0L8 8Z", fill: "currentColor" })))))));
|
|
295
295
|
}
|
|
296
296
|
get host() { return index.getElement(this); }
|
|
297
297
|
static get watchers() { return {
|
|
@@ -17,7 +17,7 @@ const ProgressBar = class {
|
|
|
17
17
|
max: '100',
|
|
18
18
|
'aria-label': rAriaLabel
|
|
19
19
|
};
|
|
20
|
-
return (index.h(index.Host, { key: '
|
|
20
|
+
return (index.h(index.Host, { key: '81203123d2df8fb029855f39dc359b98991630ee' }, index.h("progress", Object.assign({ key: 'f766b44c2c4088ab67d69b57de074fee15be166c' }, progressBarAttrs, { class: "r-progress-bar" }))));
|
|
21
21
|
}
|
|
22
22
|
};
|
|
23
23
|
ProgressBar.style = progressBarCss;
|
|
@@ -9,7 +9,7 @@ const RadioButtonDescription = class {
|
|
|
9
9
|
index.registerInstance(this, hostRef);
|
|
10
10
|
}
|
|
11
11
|
render() {
|
|
12
|
-
return (index.h(index.Host, { key: '
|
|
12
|
+
return (index.h(index.Host, { key: '83668642a70a083a0db012ad4e80aa31eeb08b85', slot: "description" }, index.h("div", { key: '12530fbda5f2789443e7d78237ba633922d97683', class: "r-radio-button-description", style: { display: 'contents' } }, index.h("slot", { key: 'a62b23dc0e9ea5f80660e9e97a45a4f1aef50c24' }))));
|
|
13
13
|
}
|
|
14
14
|
get host() { return index.getElement(this); }
|
|
15
15
|
};
|
|
@@ -9,7 +9,7 @@ const RadioButtonLeading = class {
|
|
|
9
9
|
index.registerInstance(this, hostRef);
|
|
10
10
|
}
|
|
11
11
|
render() {
|
|
12
|
-
return (index.h(index.Host, { key: '
|
|
12
|
+
return (index.h(index.Host, { key: '802f0d0c98c87abb566dd2ef0388d6d6237dba68', slot: "leading" }, index.h("div", { key: '4c0296adc5dd6839dd150450f0be62e92a810d7c', class: "r-radio-button-leading", style: { display: 'contents' } }, index.h("slot", { key: '16b6131307cbaa02e1182b204ded280fa903da0a' }))));
|
|
13
13
|
}
|
|
14
14
|
get host() { return index.getElement(this); }
|
|
15
15
|
};
|
|
@@ -9,7 +9,7 @@ const RadioButtonTitle = class {
|
|
|
9
9
|
index.registerInstance(this, hostRef);
|
|
10
10
|
}
|
|
11
11
|
render() {
|
|
12
|
-
return (index.h(index.Host, { key: '
|
|
12
|
+
return (index.h(index.Host, { key: '623feed7834a4702b83257202de4505b6c08145d', slot: "title" }, index.h("div", { key: 'ca7b90c670583ba4a874df1da73dad9db67d0bf7', class: "r-radio-button-title", style: { display: 'contents' } }, index.h("slot", { key: 'fd7ac8a7ee5e2cd05dab3d061328eecb5ee14800' }))));
|
|
13
13
|
}
|
|
14
14
|
get host() { return index.getElement(this); }
|
|
15
15
|
};
|
|
@@ -9,7 +9,7 @@ const RadioButtonTrailing = class {
|
|
|
9
9
|
index.registerInstance(this, hostRef);
|
|
10
10
|
}
|
|
11
11
|
render() {
|
|
12
|
-
return (index.h(index.Host, { key: '
|
|
12
|
+
return (index.h(index.Host, { key: 'a1c1c9d525cd2fb7b6223677f216b8398c3dac9f', slot: "trailing" }, index.h("div", { key: '554e798bcd117d7a56024097041609dc532ad2c1', class: "r-radio-button-trailing", style: { display: 'contents' } }, index.h("slot", { key: 'f48cef26f06bedf6e37439dd1f406d5c789b06a0' }))));
|
|
13
13
|
}
|
|
14
14
|
get host() { return index.getElement(this); }
|
|
15
15
|
};
|
|
@@ -108,11 +108,11 @@ const RadioButton = class {
|
|
|
108
108
|
checked,
|
|
109
109
|
required
|
|
110
110
|
};
|
|
111
|
-
return (index.h(index.Host, { key: '
|
|
112
|
-
index.h("div", { key: '
|
|
113
|
-
index.h("div", { key: '
|
|
114
|
-
index.h("r-hint", { key: '
|
|
115
|
-
index.h("r-hint", { key: '
|
|
111
|
+
return (index.h(index.Host, { key: '862574a20e04e55e3e7e0b8cb48131652f029030' }, index.h("label", { key: 'b916e9d5740605bad9a1f88c6bb07d0564b63f16', class: "r-radio-button", onClick: this.onClick, onKeyDown: this.onKeydown }, index.h("input", Object.assign({ key: 'd0ca90e85e619d8c5b9a8c71ae1582db65562036' }, inputAttrs, { id: `${uniqueId}-input`, class: "r-radio-button--input", ref: el => this.nativeEl = el, onFocus: this.onFocus, onBlur: this.onBlur })), index.h("span", { key: 'f77f3e56e88c5e3ad1f3e36e5f96715edb7e91cc', class: "r-radio-button--box" }), this.isLeading &&
|
|
112
|
+
index.h("div", { key: '60d6a15880fafd8007d20a80137b30f19d4f641e', class: "r-radio-button--leading" }, index.h("slot", { key: '9329c56d97e5e357ea70d165ee11ac171c605519', name: "leading" }, this.icon && index.h("r-icon", { key: 'ace86d3b61cd39f05ca3146e54d3ae4820d7b66d', name: this.icon, size: "m" }))), index.h("div", { key: '7773e0c5b2348245e4b4dafc06a6b10a6dc245c3', class: "r-radio-button--text" }, index.h("slot", { key: 'f060b0853a7a6ed0108d0182669807fd0236da33', name: "title" }, index.h("div", { key: '1ca5059e718a0bda9a53e2e0f630a617d0252638', style: { display: 'contents' } }, index.h("slot", { key: 'cb9128b915d2a71cff7e8960d5bd86973c615232' }))), index.h("slot", { key: 'f07a62e2caa36ceb27bc547cf86c7dfcdce1c5b4', name: "description" }, this.description)), this.isTrailing &&
|
|
113
|
+
index.h("div", { key: 'cc5e6dff1c324fdce239f8d4e553e154bdb73eac', class: "r-radio-button--trailing" }, index.h("slot", { key: '3d5e862c5830adb7a480fbb71ff92fef054bf1f7', name: "trailing" }))), invalid && error &&
|
|
114
|
+
index.h("r-hint", { key: '997b440b69a23cb432b8376b0351a947ec3b162e', role: "alert", variant: "error", id: `${uniqueId}-hint` }, this.error), hint &&
|
|
115
|
+
index.h("r-hint", { key: 'd3c41065b4924f42a2971d1cb91154e8e3041238', role: "note", variant: "information", id: `${uniqueId}-hint` }, hint)));
|
|
116
116
|
}
|
|
117
117
|
get host() { return index.getElement(this); }
|
|
118
118
|
};
|
|
@@ -338,12 +338,12 @@ const RadioGroup = class {
|
|
|
338
338
|
'tooltip-icon': tooltipIcon,
|
|
339
339
|
'tooltip-icon-color': tooltipIconColor
|
|
340
340
|
};
|
|
341
|
-
return (index.h(index.Host, { key: '
|
|
342
|
-
index.h("div", { key: '
|
|
343
|
-
index.h("r-hint", { key: '
|
|
344
|
-
index.h("r-hint", { key: '
|
|
345
|
-
index.h("r-hint", { key: '
|
|
346
|
-
index.h("r-hint", { key: '
|
|
341
|
+
return (index.h(index.Host, { key: '899b3d8d509fa3d6f37a81279e6fc58b98e1314c' }, index.h("div", { key: 'dc1c47c966aac6ebaab2b8ec9061342b6c1e81e3', class: "r-radio-group", onClick: this.onLabelClick }, label &&
|
|
342
|
+
index.h("div", { key: '5b39dcc6952d971f8c03e2dab554b25bb1be3ccf', class: "r-radio-group--label-container" }, index.h("r-label", Object.assign({ key: '7f13b1571bccb986a0e36903399c8f15536de539', id: `${uniqueId}-label`, class: "r-radio-group--label", "field-indicator": fieldIndicator }, labelAttr), label), index.h("slot", { key: 'bfd151ce64e670722a6a1f3254763b6f514c99ab', name: "popover" })), hint &&
|
|
343
|
+
index.h("r-hint", { key: 'edb8bbe44470579a5638e5dbee0b7b843cc998b4', id: `${uniqueId}-hint`, class: "r-radio-group--hint", role: "note" }, hint), index.h("div", { key: '1727429f1c36de0fd13567af448aed7c84f7c7b1', class: "r-radio-group--content" }, index.h("slot", { key: 'f7d712be6351c44e5f072f85a407b5e73837b48b' }))), invalid && error &&
|
|
344
|
+
index.h("r-hint", { key: '71feb492e87164e485bb10a0e856d86ef3c57a7d', "aria-live": "polite", id: `${uniqueId}-message`, role: "alert", variant: "error" }, error), this.validityState !== 'valid' && this.validityMessage &&
|
|
345
|
+
index.h("r-hint", { key: '0ddc4636948329a97e8140c9efc267a4a054ff3b', "aria-live": "polite", id: `${uniqueId}-message`, role: "alert", variant: "error" }, this.customErrorMessage || this.validityMessage), this.valid && this.validMessage && this.showValid &&
|
|
346
|
+
index.h("r-hint", { key: 'e7cfa4eccf754e90ad30b22b24dd9f2ce1fcadc8', role: "alert", variant: "success" }, this.validMessage)));
|
|
347
347
|
}
|
|
348
348
|
get host() { return index.getElement(this); }
|
|
349
349
|
};
|
|
@@ -121,7 +121,7 @@ const SelectOption = class {
|
|
|
121
121
|
size: iconSize,
|
|
122
122
|
color: iconColor
|
|
123
123
|
};
|
|
124
|
-
return (index.h(index.Host, { key: '
|
|
124
|
+
return (index.h(index.Host, { key: '1f3440961f3c606f5b2b1eef77ae3c53fc1ea4a0', id: uniqueId, role: "option", onClick: this.handleClick, onKeydown: this.handleKeydown, "aria-disabled": `${disabled}`, "aria-selected": `${this.isSelected}`, "data-value": this.definedValue, "data-focused": `${this.isFocused}` }, index.h("div", { key: '9a29dd16478d39c905f8cb54ca603e6982c3a24e', class: "r-select-option" }, icon && index.h("span", { key: 'fdcecb70781424749e0527f06eff5140a8a79ccc', class: "r-select-option--icon" }, index.h("r-icon", Object.assign({ key: '5a1906d39a27bc70729d26e93fd8f0d77e80e972' }, iconAttributes))), !icon && hasIconSlot && index.h("span", { key: '572b0e90b5695e0233505f28fb7c9b3dbc90a73f', class: "r-select-option--icon" }, index.h("slot", { key: 'bc04c317491e690281b0f4442aaff3f86a5ddb12', name: "icon" })), index.h("span", { key: '77bf634b415a36d8463212918cf200fda8647f85', class: "r-select-option--label" }, index.h("slot", { key: '83dd97fa580d18f4a9e27beca4835adf6c746240' })))));
|
|
125
125
|
}
|
|
126
126
|
get host() { return index.getElement(this); }
|
|
127
127
|
};
|
|
@@ -867,8 +867,9 @@ const Select = class {
|
|
|
867
867
|
const isTopSpace = ((_b = this.listboxElement) === null || _b === void 0 ? void 0 : _b.offsetHeight) < this.top;
|
|
868
868
|
const isTop = this.listboxPosition === 'top';
|
|
869
869
|
const isBottom = this.listboxPosition === 'bottom';
|
|
870
|
-
|
|
871
|
-
|
|
870
|
+
/** Don't change the position if there is sufficient space for the listbox
|
|
871
|
+
* or insufficient space for another position.
|
|
872
|
+
* */
|
|
872
873
|
if ((isTop && (isTopSpace || !isBottomSpace)) || (isBottom && (isBottomSpace || !isTopSpace))) {
|
|
873
874
|
this.listboxPositionState = this.listboxPosition;
|
|
874
875
|
return;
|
|
@@ -1006,8 +1007,8 @@ const Select = class {
|
|
|
1006
1007
|
disabled,
|
|
1007
1008
|
required: isRequired
|
|
1008
1009
|
};
|
|
1009
|
-
return (index.h(index.Host, { key: '
|
|
1010
|
-
index.h("r-hint", { key: '
|
|
1010
|
+
return (index.h(index.Host, { key: 'aca9ddac308a41221f08de7fde92f45fcd89162f', "data-value": this.currentValue, expanded: !this.disabled && this.isExpanded, "data-listbox-position": this.listboxPositionState, "data-initial-value": this.initial['value'], "data-is-placeholder": `${!!this.isPlaceholder}`, "data-value-focused": `${!!this.isValueFocused}`, "data-option-focused": `${!!this.focusedOption}`, "data-validity-state": `${this.validityState || ''}`, "data-validity-message": `${this.validityMessage || ''}`, "data-readonly": `${!!this.isReadonly}` }, index.h("div", { key: '34c00c70c0b73cdd7afdcd65f175a94e82c900d2', class: `r-select--label ${!internal ? 'r-select--label__margin-bottom' : ''}` }, index.h("div", { key: '5a2b30341687b152eb17c2fc5ca2f65b1fda886f', class: internal ? 'visually-hidden' : 'r-select--label-container' }, index.h("label", { key: '10021c02cfe8a697ee3a0e452e0052044f2b80a7', id: `${uniqueId}-label`, onClick: this.isInteractive ? this.onValueClick : null }, index.h("r-label", Object.assign({ key: 'cc7173f5b427c9fca7e08a12552227d3f20ad64c' }, labelAttr), label)), index.h("slot", { key: '625e1bd9f1fa11950ff75e1875e03510f55022c0', name: "popover" })), hint &&
|
|
1011
|
+
index.h("r-hint", { key: '6d22db79a4375ddd901f5ea6b25d9c456e8f1ab2', id: `${uniqueId}-hint`, class: "r-select--hint" }, hint)), index.h("div", { key: 'a243a731bdd150386ea47ad0897831b37eed6621', class: "r-select" }, index.h("select", Object.assign({ key: 'e1878ed06636fad3768d8b4b1f4a944d30730346', class: "r-select--native", ref: el => this.nativeElement = el }, nativeAttrs)), index.h("div", { key: 'b47cd423033129e827a99f8fcff39173f4c74ed9', class: "r-select--container" }, this.combobox ? this.renderCombobox(comboboxAttrs) : this.renderSelect(comboboxAttrs), index.h("div", Object.assign({ key: '04db58929d97226614d344f7f419c3e8aa7e250d', role: "listbox", tabindex: "-1", id: `${uniqueId}-list`, class: "r-select--options", ref: el => this.listboxElement = el }, listboxAttrs), (this.isNoResultsFound || !((_a = this.optionElements) === null || _a === void 0 ? void 0 : _a.length)) && index.h("r-select-option", { key: 'b23380c2c75c33e6a8a99737189c43400e29940b', "data-no-results": "true", value: "no_results" }, this.noResultsFound), index.h("slot", { key: '83e215daafbd8909f9788e8918691b08417a5f2d', onSlotchange: this.handleSlotChange })))), index.h("div", { key: '57acdd7994fa67813e60641493e99f29afafcaf4', id: `${uniqueId}-message`, "aria-live": "polite", "aria-atomic": "true", ref: (el) => this.messageContainer = el, class: this.hasMessage && !internal ? 'r-select--message' : 'visually-hidden' }, this.hasMessage && index.h("r-hint", { key: 'f14bc3026b6bee74b1192f37af64381958c0c87b', variant: this.invalid ? 'error' : 'success' }, this.hasError && this.error, this.hasValidationError && this.validityMessage, this.hasValidationSuccess && this.validMessage))));
|
|
1011
1012
|
}
|
|
1012
1013
|
get host() { return index.getElement(this); }
|
|
1013
1014
|
static get watchers() { return {
|
|
@@ -11,7 +11,7 @@ const SkipLink = class {
|
|
|
11
11
|
this.position = 'center';
|
|
12
12
|
}
|
|
13
13
|
render() {
|
|
14
|
-
return (index.h(index.Host, { key: '
|
|
14
|
+
return (index.h(index.Host, { key: '7ca2f29a347197be2951841e6b59807360e76f9d' }, index.h("slot", { key: '6d26f29f7dbec9d60e302de3cbbf0d8d2afd3009' })));
|
|
15
15
|
}
|
|
16
16
|
};
|
|
17
17
|
SkipLink.style = skipLinkCss;
|
|
@@ -17,8 +17,8 @@ const StepperItem = class {
|
|
|
17
17
|
}
|
|
18
18
|
render() {
|
|
19
19
|
const number = this.number || this.stepNumber;
|
|
20
|
-
return (index.h(index.Host, { key: '
|
|
21
|
-
index.h("div", { key: '
|
|
20
|
+
return (index.h(index.Host, { key: 'a5004ade661b4abfacb920a256f6a12bbd32a6ea' }, index.h("div", { key: '1358044cc918c2988a2f32198b0a8260cf439ec0', class: "r-stepper-item" }, index.h("div", { key: 'ec2afea7c0b6d603ebce7dda25e93246fafb248a', class: "r-stepper-item--indicator" }, this.complete ? (index.h("r-icon", { name: "check", size: "s" })) : this.icon ? (index.h("r-icon", { name: this.icon, size: "s" })) : number !== undefined ? (index.h("span", { class: "r-stepper-item--indicator--step-number" }, number)) : null), this.hasText &&
|
|
21
|
+
index.h("div", { key: '6cf7607d13bdd0bd58885e5cc4c74c0068448dfc', class: "r-stepper-item--text" }, index.h("slot", { key: '8c47f057e435924f8c004be5f3112743127bf885' })))));
|
|
22
22
|
}
|
|
23
23
|
get host() { return index.getElement(this); }
|
|
24
24
|
};
|
|
@@ -17,7 +17,7 @@ const Stepper = class {
|
|
|
17
17
|
}
|
|
18
18
|
render() {
|
|
19
19
|
const completed = this.completed || this.completeSteps;
|
|
20
|
-
return (index.h(index.Host, { key: '
|
|
20
|
+
return (index.h(index.Host, { key: 'd501495c36f83cfc14c706f46936d5acc925d6d2' }, index.h("div", { key: 'a2952de15ea74093ea41663438bc8fec866d428b', class: "r-stepper" }, !this.hasSteps && Array.from({ length: this.total }, (_, index$1) => (index.h("r-stepper-item", { number: index$1 + 1, complete: completed > index$1, active: completed === index$1, key: index$1 }))), index.h("slot", { key: '4834a5947ae40241607131dcbb3dfa56354fdc13' }))));
|
|
21
21
|
}
|
|
22
22
|
get host() { return index.getElement(this); }
|
|
23
23
|
};
|
|
@@ -18,7 +18,7 @@ const RTabPanel = class {
|
|
|
18
18
|
active,
|
|
19
19
|
'aria-labelledby': tabId
|
|
20
20
|
};
|
|
21
|
-
return (index.h(index.Host, Object.assign({ key: '
|
|
21
|
+
return (index.h(index.Host, Object.assign({ key: '042aba1f5eebeafdff7035d8ad5afc9ec204eb8a', class: "r-typography" }, hostAttrs), index.h("div", { key: '0e9c72a859b07c1e4c2cb4a5d936fbadc07f23ca', class: "r-tab-panel" }, index.h("slot", { key: '2d588c5c67cfd26d7762a2be0c8400faa12a96c8' }))));
|
|
22
22
|
}
|
|
23
23
|
};
|
|
24
24
|
RTabPanel.style = tabPanelCss;
|
|
@@ -49,7 +49,7 @@ const RTab = class {
|
|
|
49
49
|
'aria-selected': `${active}`,
|
|
50
50
|
'aria-disabled': `${disabled}`
|
|
51
51
|
};
|
|
52
|
-
return (index.h(index.Host, Object.assign({ key: '
|
|
52
|
+
return (index.h(index.Host, Object.assign({ key: '2e2b2d84376e097c80a84a1e7224c0f026c16277', onClick: this.handleClick, onKeyUp: this.handleKeyup, onKeyDown: this.handleKeydown }, hostAttrs), index.h("span", { key: 'c38098d413b17ba8b8ddd3436687879d1b37114f', class: "r-tab" }, index.h("span", { key: '3f7bfedd8a933da7ec52f34dd64f3a4e862cb836', class: "r-tab--slot" }, index.h("slot", { key: 'bc056a0d06188ddd1b47c3c062a4d51367e48393' })))));
|
|
53
53
|
}
|
|
54
54
|
get host() { return index.getElement(this); }
|
|
55
55
|
};
|
|
@@ -9,7 +9,7 @@ const RTabsList = class {
|
|
|
9
9
|
index.registerInstance(this, hostRef);
|
|
10
10
|
}
|
|
11
11
|
render() {
|
|
12
|
-
return (index.h(index.Host, { key: '
|
|
12
|
+
return (index.h(index.Host, { key: '323b36e7d276c42c72764c34f2564153d80b64d2', role: "tablist" }, index.h("div", { key: 'bab777186d6d538c6f541e08bda090ab228f38d3', class: "r-tabs-list" }, index.h("slot", { key: '60a0d80ba3ada9d218ca8058cdcdf720277e19d0' }))));
|
|
13
13
|
}
|
|
14
14
|
};
|
|
15
15
|
RTabsList.style = tabsListCss;
|
|
@@ -70,8 +70,8 @@ const RTabs = class {
|
|
|
70
70
|
var _a, _b;
|
|
71
71
|
const label = this.transliterateToKebabCase(tab.textContent);
|
|
72
72
|
// Unique id per each tab-panel pair
|
|
73
|
-
const tabId =
|
|
74
|
-
const panelId =
|
|
73
|
+
const tabId = `r-tab-${label}`;
|
|
74
|
+
const panelId = `r-tab-panel-${label}`;
|
|
75
75
|
// Assign `id` and `panel-id` to each tab
|
|
76
76
|
tab.setAttribute('id', tabId);
|
|
77
77
|
tab.setAttribute('panel-id', panelId);
|
|
@@ -240,7 +240,7 @@ const RTabs = class {
|
|
|
240
240
|
this._changeFocusTab(e.target, e.detail.keycode);
|
|
241
241
|
}
|
|
242
242
|
render() {
|
|
243
|
-
return (index.h(index.Host, { key: '
|
|
243
|
+
return (index.h(index.Host, { key: 'ddb0847ae3eb4a03c446b2dd193f2fa9603081df', class: "r-tabs" }, index.h("slot", { key: 'd60346bd45b58534e6ac922ac66c09c1bb04c532' })));
|
|
244
244
|
}
|
|
245
245
|
get host() { return index.getElement(this); }
|
|
246
246
|
};
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
var index = require('./index-BnETQtSf.js');
|
|
4
4
|
var formData = require('./formData-B2DZyLxP.js');
|
|
5
5
|
|
|
6
|
-
const textareaCss = ":host{opacity:1;display:block;outline:none;--r-label--margin-bottom:0}:host(:focus-visible){outline:none}:host([resize=none]){--r-textarea--input--resize:none}:host([resize=both]){--r-textarea--input--resize:both}:host([resize=horizontal]){--r-textarea--input--resize:horizontal}:host([resize=vertical]){--r-textarea--input--resize:vertical}:host([resize=initial]){--r-textarea--input--resize:initial}:host([resize=inherit]){--r-textarea--input--resize:inherit}:host([invalid]:not([invalid=false])){--r-textarea--
|
|
6
|
+
const textareaCss = ":host{opacity:1;display:block;outline:none;--r-label--margin-bottom:0}:host(:focus-visible){outline:none}:host([resize=none]){--r-textarea--input--resize:none}:host([resize=both]){--r-textarea--input--resize:both}:host([resize=horizontal]){--r-textarea--input--resize:horizontal}:host([resize=vertical]){--r-textarea--input--resize:vertical}:host([resize=initial]){--r-textarea--input--resize:initial}:host([resize=inherit]){--r-textarea--input--resize:inherit}:host([invalid]:not([invalid=false])){--r-textarea--container--background-color:var(--r-status-error-soft, #fef6f6);--r-textarea--container--border-color:var(--r-status-error-regular, #da1e28)}.r-textarea--label-container{display:var(--r-textarea--label-container--display, flex);gap:var(--r-textarea--label-container--gap, var(--r-spacing-100, 1rem));align-items:var(--r-textarea--label-container--align-items, center);justify-content:var(--r-textarea--label-container--align-items, space-between)}.r-textarea--label-container ::slotted([slot=popover]){display:var(--r-textarea--popover--display, inline-flex);height:var(--r-textarea--popover--height, var(--r-spacing-150, 1.5));align-items:var(--r-textarea--popover--align-items, center);justify-content:var(--r-textarea--popover--justify-content, center);margin-right:var(--r-textarea--popover--margin-right, -0.25rem);--r-popover--trigger--min-width:var(--r-textarea--popover-trigger--min-width, var(--r-spacing-150, 1.5))}.r-textarea--input::placeholder{color:var(--r-textarea--input--placeholder--color, var(--r-text-soft, #686868))}.r-textarea--input{vertical-align:top;width:var(--r-textarea--input--width, 100%);max-width:var(--r-textarea--input--max-width, 100%);min-height:var(--r-textarea--input--min-height, 8.875em);font-family:var(--r-textarea--input--font-family, var(--r-font-family-text, system-ui));font-weight:var(--r-textarea--input--font-weight, var(--r-font-weight-regular, 400));font-size:var(--r-textarea--input--font-size, var(--r-font-size-400, 1rem));line-height:var(--r-textarea--input--line-height, var(--r-line-height-m, 1.5));color:var(--r-textarea--input--color, var(--r-text-regular, #282828));background-color:var(--r-textarea--input--background-color, transparent);opacity:var(--r-textarea--input--opacity, 1);border-width:var(--r-textarea--input--border-width, 0px);border-style:var(--r-textarea--input--border-style, solid);border-color:var(--r-textarea--input--border-color, var(--r-border-soft, #686868));border-radius:var(--r-textarea--input--border-radius, 0);box-sizing:var(--r-textarea--input--box-sizing, border-box);box-shadow:var(--r-textarea--input--box-shadow, none);padding:var(--r-textarea--input--padding, var(--r-textarea--input--padding-top, 0.688em) var(--r-textarea--input--padding-right, 0.625em) var(--r-textarea--input--padding-bottom, 0.688em) var(--r-textarea--input--padding-left, 0.625em));margin-top:var(--r-textarea--input--margin-top, 0);resize:var(--r-textarea--input--resize, both);z-index:var(--r-textarea--input--z-index, 1);outline:var(--r-textarea--input--outline, none);outline-offset:var(--r-textarea--input--outline-offset, 0);pointer-events:var(--r-textarea--input--pointer-events, auto);cursor:var(--r-textarea--input--cursor, inherit)}.r-textarea--container{display:flex;align-items:start;overflow:visible;background-color:var(--r-textarea--container--background-color, var(--r-background-interactive-softest, #f7f7f7));border-width:var(--r-textarea--container--border-width, 1px);border-style:var(--r-textarea--container--border-style, solid);border-color:var(--r-textarea--container--border-color, var(--r-border-soft, #686868));padding:var(--r-textarea--container--padding, 0);margin-top:var(--r-textarea--container--margin-top, var(--r-spacing-025, 0.25rem));box-shadow:var(--r-textarea--container--box-shadow, none);outline:var(--r-textarea--container--outline, none);outline-offset:var(--r-textarea--container--outline-offset, none)}.r-textarea--container[data-readonly=true]{--r-textarea--container--background-color:var(--r-background-soft, #f3f1f0);--r-textarea--container--border-color:transparent transparent var(--r-border-soft, #686868) transparent;--r-textarea--container--cursor:text}.r-textarea--container:hover:not([data-disabled=true]):not([data-readonly=true]){--r-textarea--container--background-color:var(--r-background-interactive-hovered)}.r-textarea--container:active:not([data-disabled=true]):not([data-readonly=true]){--r-textarea--container--background-color:var(--r-background-interactive-pressed)}.r-textarea--container:focus-within{--r-textarea--container--box-shadow:0 0 0 6px var(--r-border-focused-outlined, #fff);--r-textarea--container--outline:2px solid var(--r-border-focused, #0071e3);--r-textarea--container--outline-offset:2px}.r-textarea--trailing{display:var(--r-textarea--trailing--display, flex);margin-top:var(--r-textarea--trailing--margin-top, 0.688em);margin-right:var(--r-textarea--trailing--margin-right, 0.625em);margin-left:var(--r-textarea--trailing--margin-left, auto);gap:var(--r-textarea--trailing--gap, 0.625rem)}.r-textarea--trailing:empty{display:none}.r-textarea--readonly-icon{color:var(--r-textarea--readonly-icon--color, var(--r-icon-soft, #686868))}.r-textarea--messages{display:flex;gap:var(--r-textarea--messages--gap, var(--r-spacing-025, 0.25rem))}.r-textarea--messages--counter{margin-left:auto}.r-textarea--messages:has(r-hint){margin-top:var(--r-spacing-025, 0.25rem)}.visually-hidden{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);border:0}";
|
|
7
7
|
|
|
8
8
|
const RTextarea = class {
|
|
9
9
|
constructor(hostRef) {
|
|
@@ -39,6 +39,8 @@ const RTextarea = class {
|
|
|
39
39
|
/** Unique id */
|
|
40
40
|
this.uniqueId = `r-textarea-${Date.now().toString(32)}${Math.random().toString(32)}`.replace(/\./g, '');
|
|
41
41
|
this.onInput = event => {
|
|
42
|
+
if (this.readonly)
|
|
43
|
+
return;
|
|
42
44
|
this.value = event.target.value;
|
|
43
45
|
this.validateFormElement(this.nativeElement);
|
|
44
46
|
const { host, value } = this;
|
|
@@ -51,6 +53,8 @@ const RTextarea = class {
|
|
|
51
53
|
}
|
|
52
54
|
};
|
|
53
55
|
this.onChange = event => {
|
|
56
|
+
if (this.readonly)
|
|
57
|
+
return;
|
|
54
58
|
this.value = event.target.value;
|
|
55
59
|
this.validateFormElement(this.nativeElement);
|
|
56
60
|
const { host, value } = this;
|
|
@@ -66,6 +70,8 @@ const RTextarea = class {
|
|
|
66
70
|
}
|
|
67
71
|
};
|
|
68
72
|
this.onResetForm = () => {
|
|
73
|
+
if (this.readonly)
|
|
74
|
+
return;
|
|
69
75
|
// Return to initial state
|
|
70
76
|
this.validityState = null;
|
|
71
77
|
this.validityMessage = null;
|
|
@@ -109,6 +115,8 @@ const RTextarea = class {
|
|
|
109
115
|
}
|
|
110
116
|
/** Sets the value of the element. */
|
|
111
117
|
async setValue(value) {
|
|
118
|
+
if (this.readonly)
|
|
119
|
+
return;
|
|
112
120
|
this.value = value;
|
|
113
121
|
}
|
|
114
122
|
/** Gets the value of the element. */
|
|
@@ -117,6 +125,8 @@ const RTextarea = class {
|
|
|
117
125
|
}
|
|
118
126
|
/** Resets value and validity state to initial. */
|
|
119
127
|
async reset() {
|
|
128
|
+
if (this.readonly)
|
|
129
|
+
return;
|
|
120
130
|
this.validityState = null;
|
|
121
131
|
this.validityMessage = null;
|
|
122
132
|
this.value = this.initial['value'];
|
|
@@ -183,6 +193,9 @@ const RTextarea = class {
|
|
|
183
193
|
this.novalidate ||
|
|
184
194
|
false);
|
|
185
195
|
}
|
|
196
|
+
get hasTrailingSlot() {
|
|
197
|
+
return !!this.host.querySelector('[slot="trailing"]');
|
|
198
|
+
}
|
|
186
199
|
get textareaSlotValue() {
|
|
187
200
|
return this.host.textContent;
|
|
188
201
|
}
|
|
@@ -209,7 +222,7 @@ const RTextarea = class {
|
|
|
209
222
|
this.disconnectFormEventListeners();
|
|
210
223
|
}
|
|
211
224
|
render() {
|
|
212
|
-
const { name, rows, cols, placeholder, required, showCounter, maxlength, minlength, form, value, disabled, resize, hint, invalid, label, uniqueId, fieldIndicator, tooltip, tooltipIcon, tooltipIconColor } = this;
|
|
225
|
+
const { name, rows, cols, placeholder, required, showCounter, maxlength, minlength, form, value, disabled, resize, hint, invalid, label, uniqueId, fieldIndicator, tooltip, tooltipIcon, tooltipIconColor, readonly } = this;
|
|
213
226
|
const textareaAttrs = {
|
|
214
227
|
name,
|
|
215
228
|
rows,
|
|
@@ -222,6 +235,7 @@ const RTextarea = class {
|
|
|
222
235
|
value,
|
|
223
236
|
disabled,
|
|
224
237
|
resize,
|
|
238
|
+
readonly,
|
|
225
239
|
id: uniqueId,
|
|
226
240
|
'aria-describedby': this.ariaDescribedBy,
|
|
227
241
|
'aria-invalid': `${!!invalid}`,
|
|
@@ -245,7 +259,7 @@ const RTextarea = class {
|
|
|
245
259
|
}, {});
|
|
246
260
|
return (index.h(index.Host, null, index.h("div", { class: "r-textarea--label-container" }, index.h("label", { htmlFor: uniqueId }, label &&
|
|
247
261
|
index.h("r-label", Object.assign({ id: `${uniqueId}-label` }, labelAttr), label)), index.h("slot", { name: "popover" })), hint &&
|
|
248
|
-
index.h("r-hint", { id: `${uniqueId}-hint`, role: "note" }, hint), index.h("textarea", Object.assign({ class: "r-textarea--input" }, textareaAttrs, eventListeners, { ref: el => this.nativeElement = el, onChange: this.onChange, onInput: this.onInput })), index.h("div", { class: "r-textarea--messages" }, index.h("r-hint", { "aria-live": "polite", "aria-atomic": "true", id: `${uniqueId}-message`, class: !this.hasMessage && 'visually-hidden', variant: invalid ? 'error' : 'success' }, this.hasError && this.error, this.hasValidationError && (this.customErrorMessage || this.validityMessage), this.hasValidationSuccess && this.validMessage), showCounter && index.h("r-hint", { "aria-hidden": true, class: "r-textarea--messages--counter" }, value.length
|
|
262
|
+
index.h("r-hint", { id: `${uniqueId}-hint`, role: "note" }, hint), index.h("div", { class: "r-textarea--container", "data-disabled": `${!!disabled}`, "data-readonly": `${!!readonly}` }, index.h("textarea", Object.assign({ class: "r-textarea--input" }, textareaAttrs, eventListeners, { ref: el => this.nativeElement = el, onChange: this.onChange, onInput: this.onInput })), index.h("div", { class: "r-textarea--trailing" }, this.readonly && index.h("r-icon", { class: "r-textarea--readonly-icon", name: "pen-disabled", size: "s" }), this.hasTrailingSlot && index.h("slot", { name: "trailing" }))), index.h("div", { class: "r-textarea--messages" }, index.h("r-hint", { "aria-live": "polite", "aria-atomic": "true", id: `${uniqueId}-message`, class: !this.hasMessage && 'visually-hidden', variant: invalid ? 'error' : 'success' }, this.hasError && this.error, this.hasValidationError && (this.customErrorMessage || this.validityMessage), this.hasValidationSuccess && this.validMessage), showCounter && index.h("r-hint", { "aria-hidden": true, class: "r-textarea--messages--counter" }, `${value.length}${maxlength ? '/' : ''}${maxlength}`), maxlength &&
|
|
249
263
|
index.h("div", { class: "visually-hidden", ref: el => this.characterLimitReachedAlert = el, "aria-live": "assertive" }))));
|
|
250
264
|
}
|
|
251
265
|
get host() { return index.getElement(this); }
|
|
@@ -18,7 +18,7 @@ const ToastGroup = class {
|
|
|
18
18
|
this.updateHiddenState();
|
|
19
19
|
}
|
|
20
20
|
render() {
|
|
21
|
-
return (index.h(index.Host, { key: '
|
|
21
|
+
return (index.h(index.Host, { key: 'cd72702e1eee0d746e85c2022038972dea391dba' }, index.h("div", { key: '86bce60683eab444715fa266d39cada11bf19ce4', class: "r-toast-group" }, index.h("slot", { key: '594c29dc3b2ba4762d8a5b7876a47923d11f6f86', onSlotchange: this.updateHiddenState }))));
|
|
22
22
|
}
|
|
23
23
|
get host() { return index.getElement(this); }
|
|
24
24
|
};
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var index = require('./index-BnETQtSf.js');
|
|
4
4
|
|
|
5
|
-
const toastCss = ":host([status=info]){--r-toast--border-color:var(--r-status-info-regular, #466882);--r-toast--background-color:var(--r-status-info-soft, #f8fafb);--r-toast--leading-icon--color:var(--r-status-info-regular, #466882)}:host([status=warning]){--r-toast--border-color:var(--r-status-warning-regular, #f26a20);--r-toast--background-color:var(--r-status-warning-soft, #fef9f5);--r-toast--leading-icon--color:var(--r-status-warning-strong, #89411A)}:host([status=error]){--r-toast--border-color:var(--r-status-error-regular, #da1e28);--r-toast--background-color:var(--r-status-error-soft, #fef6f6);--r-toast--leading-icon--color:var(--r-status-error-regular, #da1e28)}:host([status=success]){--r-toast--border-color:var(--r-status-success-regular, #298535);--r-toast--background-color:var(--r-status-success-soft, #f7fdf8);--r-toast--leading-icon--color:var(--r-status-success-regular, #298535)}:host([is-content=false]){--r-toast--content--display:none}:host([headline]){--r-toast--content--margin-top:var(--r-spacing-050, 0.5rem)}:host([aria-hidden=true]){--r-toast--host--transition:all 0.15s;--r-toast--host--transition-delay:0.15s;--r-toast--host--opacity:0;--r-toast--host--height-expanded:0}:host{animation-duration:var(--r-toast--host--animation-duration, 0.3s);animation-fill-mode:var(--r-toast--host--animation-fill-mode, forwards);animation-name:var(--r-toast--host--animation-name, none);box-sizing:var(--r-toast--host--box-sizing, border-box);display:var(--r-toast--host--display, block);height:var(--r-toast--host--height, var(--r-toast--host--height-expanded, auto));opacity:var(--r-toast--host--opacity, 1);overflow:var(--r-toast--host--overflow, hidden);position:var(--r-toast--host--position, relative);transition:var(--r-toast--host--transition, all 0.3s);transition-delay:var(--r-toast--host--transition-delay, 0s)}:host ::slotted(p){margin:0}:host ::slotted(p+p),:host ::slotted(p+ul),:host ::slotted(p+ol){margin-top:1rem}:host .r-toast--action-link:hover{--r-toast--action--color:var(--r-text-strong, #000000)}:host .r-toast--action-link:focus{outline:var(--r-toast--action-link--outline, 2px solid var(--r-border-focused, #0071e3));box-shadow:var(--r-toast--action-link--box-shadow, 0 0 0 1px var(--r-border-focused-outlined, #fff), 0 0 0 3px var(--r-border-focused, #0071e3), 0 0 0 4px var(--r-border-focused-outlined, #fff))}:host .r-toast--trailing-button{--r-button--width:2.75rem;--r-button--height:2.75rem;--r-button--color:var(--r-text-regular, #282828);--r-button--border-color:transparent;--r-button--background-color:transparent;position:relative;top:-8px;right:-8px}:host .r-toast--trailing-button:hover{--r-button--color:var(--r-text-strong, #000000);--r-button--background-color:var(--r-background-interactive-hovered, #000000)}:host .r-toast--trailing-button:active{--r-button--transform:scale(0.94)}.r-toast{font-family:var(--r-toast--font-family, var(--r-font-family-text, system-ui));font-size:var(--r-toast--font-size, var(--r-font-size-400, 1rem));display:var(--r-toast--display, flex);flex-direction:var(--r-toast--flex-direction, row);align-items:var(--r-toast--align-items, stretch);gap:var(--r-toast--gap, var(--r-spacing-075, 0.75rem));padding:var(--r-toast--padding, var(--r-spacing-100, 1rem));border-width:var(--r-toast--border-width, 1px);border-style:var(--r-toast--border-style, solid);border-color:var(--r-toast--border-color, var(--r-status-info-regular, #466882));background-color:var(--r-toast--background-color, var(--r-status-info-soft, #f8fafb));box-sizing:var(--r-toast--box-sizing, border-box);transition:var(--r-toast--transition, all 0.3s)}.r-toast--main{flex:var(--r-toast--content--flex, 1)}.r-toast--leading-icon{color:var(--r-toast--leading-icon--color, var(--r-status-info-regular, #466882));margin-top:var(--r-toast--leading-icon--margin-top, 0
|
|
5
|
+
const toastCss = ":host([status=info]){--r-toast--border-color:var(--r-status-info-regular, #466882);--r-toast--background-color:var(--r-status-info-soft, #f8fafb);--r-toast--leading-icon--color:var(--r-status-info-regular, #466882)}:host([status=warning]){--r-toast--border-color:var(--r-status-warning-regular, #f26a20);--r-toast--background-color:var(--r-status-warning-soft, #fef9f5);--r-toast--leading-icon--color:var(--r-status-warning-strong, #89411A)}:host([status=error]){--r-toast--border-color:var(--r-status-error-regular, #da1e28);--r-toast--background-color:var(--r-status-error-soft, #fef6f6);--r-toast--leading-icon--color:var(--r-status-error-regular, #da1e28)}:host([status=success]){--r-toast--border-color:var(--r-status-success-regular, #298535);--r-toast--background-color:var(--r-status-success-soft, #f7fdf8);--r-toast--leading-icon--color:var(--r-status-success-regular, #298535)}:host([is-content=false]){--r-toast--content--display:none}:host([headline]){--r-toast--content--margin-top:var(--r-spacing-050, 0.5rem)}:host([aria-hidden=true]){--r-toast--host--transition:all 0.15s;--r-toast--host--transition-delay:0.15s;--r-toast--host--opacity:0;--r-toast--host--height-expanded:0}:host{animation-duration:var(--r-toast--host--animation-duration, 0.3s);animation-fill-mode:var(--r-toast--host--animation-fill-mode, forwards);animation-name:var(--r-toast--host--animation-name, none);box-sizing:var(--r-toast--host--box-sizing, border-box);display:var(--r-toast--host--display, block);height:var(--r-toast--host--height, var(--r-toast--host--height-expanded, auto));opacity:var(--r-toast--host--opacity, 1);overflow:var(--r-toast--host--overflow, hidden);position:var(--r-toast--host--position, relative);transition:var(--r-toast--host--transition, all 0.3s);transition-delay:var(--r-toast--host--transition-delay, 0s)}:host ::slotted(p){margin:0}:host ::slotted(p+p),:host ::slotted(p+ul),:host ::slotted(p+ol){margin-top:1rem}:host .r-toast--action-link:hover{--r-toast--action--color:var(--r-text-strong, #000000)}:host .r-toast--action-link:focus{outline:var(--r-toast--action-link--outline, 2px solid var(--r-border-focused, #0071e3));box-shadow:var(--r-toast--action-link--box-shadow, 0 0 0 1px var(--r-border-focused-outlined, #fff), 0 0 0 3px var(--r-border-focused, #0071e3), 0 0 0 4px var(--r-border-focused-outlined, #fff))}:host .r-toast--trailing-button{--r-button--width:2.75rem;--r-button--height:2.75rem;--r-button--color:var(--r-text-regular, #282828);--r-button--border-color:transparent;--r-button--background-color:transparent;position:relative;top:-8px;right:-8px}:host .r-toast--trailing-button:hover{--r-button--color:var(--r-text-strong, #000000);--r-button--background-color:var(--r-background-interactive-hovered, #000000)}:host .r-toast--trailing-button:active{--r-button--transform:scale(0.94)}.r-toast{font-family:var(--r-toast--font-family, var(--r-font-family-text, system-ui));font-size:var(--r-toast--font-size, var(--r-font-size-400, 1rem));display:var(--r-toast--display, flex);flex-direction:var(--r-toast--flex-direction, row);align-items:var(--r-toast--align-items, stretch);gap:var(--r-toast--gap, var(--r-spacing-075, 0.75rem));padding:var(--r-toast--padding, var(--r-spacing-100, 1rem));border-width:var(--r-toast--border-width, 1px);border-style:var(--r-toast--border-style, solid);border-color:var(--r-toast--border-color, var(--r-status-info-regular, #466882));background-color:var(--r-toast--background-color, var(--r-status-info-soft, #f8fafb));box-sizing:var(--r-toast--box-sizing, border-box);transition:var(--r-toast--transition, all 0.3s)}.r-toast--main{flex:var(--r-toast--content--flex, 1)}.r-toast--leading-icon{color:var(--r-toast--leading-icon--color, var(--r-status-info-regular, #466882));margin-top:var(--r-toast--leading-icon--margin-top, 0)}.r-toast--headline{color:var(--r-toast--headline--color, var(--r-text-regular, #282828));font-size:var(--r-toast--headline--font-size, var(--r-font-size-400, 1rem));font-weight:var(--r-toast--headline--font-weight, var(--r-font-weight-semibold, 600));line-height:var(--r-toast--headline--line-height, 1);margin:var(--r-toast--headline--margin, 0)}.r-toast--content{display:var(--r-toast--content--display, block);color:var(--r-toast--content--color, var(--r-text-regular, #282828));line-height:var(--r-toast--content--line-height, var(--r-line-height-m, 1.5));font-size:var(--r-toast--content--font-size, var(--r-font-size-300, 0.875rem));font-weight:var(--r-toast--content--font-weight, var(--r-font-weight-light, 300));margin-top:var(--r-toast--content--margin-top, 0)}.r-toast--action{display:var(--r-toast--action--display, flex);margin-top:var(--r-toast--action--margin-top, var(--r-spacing-050, 0.5rem));color:var(--r-toast--action--color, var(--r-text-regular, #282828));font-size:var(--r-toast--action--font-size, var(--r-font-size-300, 0.875rem));font-weight:var(--r-toast--action--font-weight, var(--r-font-weight-light, 300))}.r-toast--action-link{color:var(--r-toast--action--color, var(--r-text-regular, #282828))}.r-toast--action ::slotted(*){font-size:inherit;color:inherit}.r-toast--action ::slotted(a){color:var(--r-toast--action--color, var(--r-text-regular, #282828))}";
|
|
6
6
|
|
|
7
7
|
const Toast = class {
|
|
8
8
|
constructor(hostRef) {
|
|
@@ -32,6 +32,12 @@ const Toast = class {
|
|
|
32
32
|
* @default 3000
|
|
33
33
|
*/
|
|
34
34
|
this.delay = 3000;
|
|
35
|
+
/**
|
|
36
|
+
* Defines the behavior of the component's dismissing.
|
|
37
|
+
* - `auto`: The component will be dismissed automatically after number of ms set by `delay` property.
|
|
38
|
+
* - `manual`: The component requires explicit user action to close.
|
|
39
|
+
* @default "auto"
|
|
40
|
+
*/
|
|
35
41
|
this.dismissMode = 'auto';
|
|
36
42
|
/** Provides content for `aria-label` attribute of the dismiss button. */
|
|
37
43
|
this.dismissLabel = 'Dismiss the toast';
|
|
@@ -162,14 +168,14 @@ const Toast = class {
|
|
|
162
168
|
name: trailingIcon,
|
|
163
169
|
size: 'm'
|
|
164
170
|
};
|
|
165
|
-
return (index.h(index.Host, { key: '
|
|
166
|
-
index.h("div", { key: '
|
|
167
|
-
index.h("h2", { key: '
|
|
168
|
-
index.h("div", { key: '
|
|
169
|
-
index.h("div", { key: '
|
|
170
|
-
index.h("a", Object.assign({ key: '
|
|
171
|
-
index.h("div", { key: '
|
|
172
|
-
index.h("r-icon-button", Object.assign({ key: '
|
|
171
|
+
return (index.h(index.Host, { key: 'f5413c4a9e1335b4a4e2f37cef036acbc7c05770', id: this.uniqueId, role: `${this.isError ? 'alert' : 'status'}`, "aria-live": "polite", "aria-label": `${headline}`, "aria-hidden": `${this.isOpen ? 'false' : 'true'}` }, index.h("div", { key: '3a222a7eaac62655c1cc7361865321c6a130f1fc', class: "r-toast" }, this.hasLeading &&
|
|
172
|
+
index.h("div", { key: '91d8dd470641658118be1e7c99c4e2cf648fce5f', class: "r-toast--leading" }, this.hasLeadingSlot && index.h("slot", { key: '2c877ff1c79839e66c5f7ec79926a4f5eb807d02', name: "leading" }), this.hasLeadingIcon && index.h("r-icon", Object.assign({ key: 'f238d9fc8eb6f0360bc97587e0b3ab9b2d077314', class: "r-toast--leading-icon" }, leadingIconAttrs))), index.h("div", { key: '568bb66c165a3f3d9e52c74fc51673283e3789f8', class: "r-toast--main" }, this.hasHeadline &&
|
|
173
|
+
index.h("h2", { key: '2267cbc787dfe1d9de4b35bc81981c3fe0df8deb', class: "r-toast--headline" }, index.h("slot", { key: '0a64068708db344d785db7d94fdb7edfcdf4fb7e', name: "headline" }, headline)), this.hasContent &&
|
|
174
|
+
index.h("div", { key: 'e4b198949b659f7724ca2191145da9e577546bdf', class: "r-toast--content r-typography" }, index.h("slot", { key: 'bd063b802fd04ee1606e4934511a2f48ec2c9304', onSlotchange: this.handleSlotChange })), this.hasAction &&
|
|
175
|
+
index.h("div", { key: '38c9af908aa62379cf9c914426bfb7d7ba707608', class: "r-toast--action" }, index.h("slot", { key: 'e25437e3a9298f21a9e6c7fd1b86cccaa096b44d', name: "action" }, this.hasActionLink &&
|
|
176
|
+
index.h("a", Object.assign({ key: '9cae694c50dd9aab6acde4924dce66ec7823c5b9', class: "r-toast--action-link" }, actionAttrs), action)))), this.hasTrailing &&
|
|
177
|
+
index.h("div", { key: 'fd7207cb911423a81a3ac80a26cbc025e5689e16', class: "r-toast--trailing" }, this.hasTrailingSlot && index.h("slot", { key: '5bcd5167e2299f62c20ed80be93dd06a8303dcab', name: "trailing" }), this.isDismissManual &&
|
|
178
|
+
index.h("r-icon-button", Object.assign({ key: 'c33a87247c3ff02dc3ed4d4205f20fcdf2259f2e' }, trailingIconAttrs, { class: "r-toast--trailing-button", onClick: this.handleTrailingButtonClick, "aria-label": this.dismissLabel }), index.h("slot", { key: '05ddb2629df06aaa350c88b442df7894a2f4bcd7', name: "dismiss" }))))));
|
|
173
179
|
}
|
|
174
180
|
get host() { return index.getElement(this); }
|
|
175
181
|
static get watchers() { return {
|