@riverty/web-components 6.3.0 → 6.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/cjs/app-globals-V2Kpy_OQ.js +5 -0
- package/dist/cjs/focusable-Oll_rmtP.js +28 -0
- package/dist/cjs/formData-B2DZyLxP.js +44 -0
- package/dist/cjs/index-BnETQtSf.js +1834 -0
- package/dist/cjs/index.cjs.js +37 -0
- package/dist/cjs/loader.cjs.js +13 -0
- package/dist/cjs/r-accordion-panel.cjs.entry.js +24 -0
- package/dist/cjs/r-accordion-section.cjs.entry.js +125 -0
- package/dist/cjs/r-accordion-trigger.cjs.entry.js +93 -0
- package/dist/cjs/r-accordion.cjs.entry.js +20 -0
- package/dist/cjs/r-alert.cjs.entry.js +146 -0
- package/dist/cjs/r-badge.cjs.entry.js +41 -0
- package/dist/cjs/r-button.cjs.entry.js +149 -0
- package/dist/cjs/r-checkbox-group.cjs.entry.js +237 -0
- package/dist/cjs/r-checkbox.cjs.entry.js +274 -0
- package/dist/cjs/r-design-system-devtools.cjs.entry.js +31 -0
- package/dist/cjs/r-dialog.cjs.entry.js +107 -0
- package/dist/cjs/r-hint_2.cjs.entry.js +50 -0
- package/dist/cjs/r-icon-button_2.cjs.entry.js +492 -0
- package/dist/cjs/r-icon.cjs.entry.js +284 -0
- package/dist/cjs/r-illustration.cjs.entry.js +396 -0
- package/dist/cjs/r-input-code.cjs.entry.js +437 -0
- package/dist/cjs/r-input-date.cjs.entry.js +524 -0
- package/dist/cjs/r-input-password.cjs.entry.js +270 -0
- package/dist/cjs/r-input-phone-number.cjs.entry.js +2525 -0
- package/dist/cjs/r-input.cjs.entry.js +618 -0
- package/dist/cjs/r-list-item.cjs.entry.js +109 -0
- package/dist/cjs/r-pagination.cjs.entry.js +320 -0
- package/dist/cjs/r-panel.cjs.entry.js +184 -0
- package/dist/cjs/r-popover-action.cjs.entry.js +80 -0
- package/dist/cjs/r-popover-content.cjs.entry.js +62 -0
- package/dist/cjs/r-popover-headline.cjs.entry.js +28 -0
- package/dist/cjs/r-popover-trigger.cjs.entry.js +70 -0
- package/dist/cjs/r-popover.cjs.entry.js +347 -0
- package/dist/cjs/r-progress-bar.cjs.entry.js +25 -0
- package/dist/cjs/r-radio-button-description.cjs.entry.js +18 -0
- package/dist/cjs/r-radio-button-leading.cjs.entry.js +18 -0
- package/dist/cjs/r-radio-button-title.cjs.entry.js +18 -0
- package/dist/cjs/r-radio-button-trailing.cjs.entry.js +18 -0
- package/dist/cjs/r-radio-button.cjs.entry.js +139 -0
- package/dist/cjs/r-radio-group.cjs.entry.js +428 -0
- package/dist/cjs/r-select-option.cjs.entry.js +130 -0
- package/dist/cjs/r-select.cjs.entry.js +1107 -0
- package/dist/cjs/r-skip-link.cjs.entry.js +19 -0
- package/dist/cjs/r-stepper-item.cjs.entry.js +42 -0
- package/dist/cjs/r-stepper.cjs.entry.js +99 -0
- package/dist/cjs/r-tab-panel.cjs.entry.js +26 -0
- package/dist/cjs/r-tab.cjs.entry.js +62 -0
- package/dist/cjs/r-tabs-list.cjs.entry.js +175 -0
- package/dist/cjs/r-tabs.cjs.entry.js +277 -0
- package/dist/cjs/r-textarea.cjs.entry.js +270 -0
- package/dist/cjs/r-toast-group.cjs.entry.js +46 -0
- package/dist/cjs/r-toast.cjs.entry.js +314 -0
- package/dist/cjs/style-observer-D9zSP9wP.js +1118 -0
- package/dist/cjs/theming-NqxjhVJS.js +109 -0
- package/dist/cjs/web-components.cjs.js +25 -0
- package/dist/collection/collection-manifest.json +60 -0
- package/dist/collection/components/accordion/accordion.css +24 -0
- package/dist/collection/components/accordion/accordion.js +90 -0
- package/dist/collection/components/accordion/exports.js +1 -0
- package/dist/collection/components/accordion-panel/accordion-panel.css +50 -0
- package/dist/collection/components/accordion-panel/accordion-panel.js +86 -0
- package/dist/collection/components/accordion-section/accordion-section.css +27 -0
- package/dist/collection/components/accordion-section/accordion-section.js +235 -0
- package/dist/collection/components/accordion-trigger/accordion-trigger.css +93 -0
- package/dist/collection/components/accordion-trigger/accordion-trigger.js +220 -0
- package/dist/collection/components/alert/alert.css +120 -0
- package/dist/collection/components/alert/alert.js +526 -0
- package/dist/collection/components/alert/exports.js +2 -0
- package/dist/collection/components/badge/badge.css +62 -0
- package/dist/collection/components/badge/badge.js +124 -0
- package/dist/collection/components/badge/exports.js +1 -0
- package/dist/collection/components/button/button.css +180 -0
- package/dist/collection/components/button/button.js +510 -0
- package/dist/collection/components/button/exports.js +5 -0
- package/dist/collection/components/checkbox/checkbox.css +116 -0
- package/dist/collection/components/checkbox/checkbox.js +803 -0
- package/dist/collection/components/checkbox-group/checkbox-group.css +48 -0
- package/dist/collection/components/checkbox-group/checkbox-group.js +744 -0
- package/dist/collection/components/design-system-devtools/design-system-devtools.js +59 -0
- package/dist/collection/components/dialog/dialog.css +125 -0
- package/dist/collection/components/dialog/dialog.js +345 -0
- package/dist/collection/components/dialog/exports.js +9 -0
- package/dist/collection/components/hint/exports.js +1 -0
- package/dist/collection/components/hint/hint.css +63 -0
- package/dist/collection/components/hint/hint.js +114 -0
- package/dist/collection/components/icon/all-kit.js +2 -0
- package/dist/collection/components/icon/data.js +90 -0
- package/dist/collection/components/icon/exports.js +7 -0
- package/dist/collection/components/icon/icon.css +105 -0
- package/dist/collection/components/icon/icon.js +379 -0
- package/dist/collection/components/icon/riverty-kit.js +2 -0
- package/dist/collection/components/icon-button/icon-button.css +105 -0
- package/dist/collection/components/icon-button/icon-button.js +343 -0
- package/dist/collection/components/illustration/data.js +112 -0
- package/dist/collection/components/illustration/exports.js +3 -0
- package/dist/collection/components/illustration/illustration.css +52 -0
- package/dist/collection/components/illustration/illustration.js +540 -0
- package/dist/collection/components/illustration/illustrations-ui-kit.js +2 -0
- package/dist/collection/components/input/exports.js +62 -0
- package/dist/collection/components/input/input.css +186 -0
- package/dist/collection/components/input/input.js +1861 -0
- package/dist/collection/components/input-code/exports.js +2 -0
- package/dist/collection/components/input-code/input-code.css +127 -0
- package/dist/collection/components/input-code/input-code.js +1165 -0
- package/dist/collection/components/input-date/exports.js +1 -0
- package/dist/collection/components/input-date/input-date.css +148 -0
- package/dist/collection/components/input-date/input-date.js +1254 -0
- package/dist/collection/components/input-password/exports.js +1 -0
- package/dist/collection/components/input-password/input-password.css +25 -0
- package/dist/collection/components/input-password/input-password.js +1077 -0
- package/dist/collection/components/input-phone-number/input-phone-number.css +61 -0
- package/dist/collection/components/input-phone-number/input-phone-number.js +893 -0
- package/dist/collection/components/label/label.css +38 -0
- package/dist/collection/components/label/label.js +47 -0
- package/dist/collection/components/list-item/list-item/exports.js +2 -0
- package/dist/collection/components/list-item/list-item/list-item.css +199 -0
- package/dist/collection/components/list-item/list-item/list-item.js +467 -0
- package/dist/collection/components/pagination/exports.js +3 -0
- package/dist/collection/components/pagination/pagination.css +118 -0
- package/dist/collection/components/pagination/pagination.js +814 -0
- package/dist/collection/components/panel/exports.js +1 -0
- package/dist/collection/components/panel/panel.css +192 -0
- package/dist/collection/components/panel/panel.js +473 -0
- package/dist/collection/components/popover/exports.js +3 -0
- package/dist/collection/components/popover/popover.css +251 -0
- package/dist/collection/components/popover/popover.js +741 -0
- package/dist/collection/components/popover-action/popover-action.css +21 -0
- package/dist/collection/components/popover-action/popover-action.js +150 -0
- package/dist/collection/components/popover-content/popover-content.css +9 -0
- package/dist/collection/components/popover-content/popover-content.js +130 -0
- package/dist/collection/components/popover-headline/popover-headline.css +7 -0
- package/dist/collection/components/popover-headline/popover-headline.js +28 -0
- package/dist/collection/components/popover-trigger/exports.js +1 -0
- package/dist/collection/components/popover-trigger/popover-trigger.css +4 -0
- package/dist/collection/components/popover-trigger/popover-trigger.js +163 -0
- package/dist/collection/components/progress-bar/progress-bar.css +41 -0
- package/dist/collection/components/progress-bar/progress-bar.js +71 -0
- package/dist/collection/components/radio-button/radio-button.css +126 -0
- package/dist/collection/components/radio-button/radio-button.js +559 -0
- package/dist/collection/components/radio-button-description/radio-button-description.css +5 -0
- package/dist/collection/components/radio-button-description/radio-button-description.js +22 -0
- package/dist/collection/components/radio-button-leading/radio-button-leading.css +3 -0
- package/dist/collection/components/radio-button-leading/radio-button-leading.js +22 -0
- package/dist/collection/components/radio-button-title/radio-button-title.css +8 -0
- package/dist/collection/components/radio-button-title/radio-button-title.js +22 -0
- package/dist/collection/components/radio-button-trailing/radio-button-trailing.css +6 -0
- package/dist/collection/components/radio-button-trailing/radio-button-trailing.js +22 -0
- package/dist/collection/components/radio-group/exports.js +1 -0
- package/dist/collection/components/radio-group/radio-group.css +65 -0
- package/dist/collection/components/radio-group/radio-group.js +1023 -0
- package/dist/collection/components/select/exports.js +1 -0
- package/dist/collection/components/select/select.css +247 -0
- package/dist/collection/components/select/select.js +2038 -0
- package/dist/collection/components/select-option/select-option.css +93 -0
- package/dist/collection/components/select-option/select-option.js +459 -0
- package/dist/collection/components/skip-link/exports.js +1 -0
- package/dist/collection/components/skip-link/skip-link.css +37 -0
- package/dist/collection/components/skip-link/skip-link.js +52 -0
- package/dist/collection/components/stepper/stepper.css +25 -0
- package/dist/collection/components/stepper/stepper.js +216 -0
- package/dist/collection/components/stepper-item/stepper-item.css +62 -0
- package/dist/collection/components/stepper-item/stepper-item.js +171 -0
- package/dist/collection/components/tab/tab.css +81 -0
- package/dist/collection/components/tab/tab.js +169 -0
- package/dist/collection/components/tab-panel/tab-panel.css +19 -0
- package/dist/collection/components/tab-panel/tab-panel.js +72 -0
- package/dist/collection/components/tabs/tabs.css +4 -0
- package/dist/collection/components/tabs/tabs.js +345 -0
- package/dist/collection/components/tabs-list/exports.js +2 -0
- package/dist/collection/components/tabs-list/tabs-list.css +58 -0
- package/dist/collection/components/tabs-list/tabs-list.js +294 -0
- package/dist/collection/components/textarea/exports.js +8 -0
- package/dist/collection/components/textarea/textarea.css +148 -0
- package/dist/collection/components/textarea/textarea.js +1055 -0
- package/dist/collection/components/toast/exports.js +3 -0
- package/dist/collection/components/toast/toast.css +179 -0
- package/dist/collection/components/toast/toast.js +820 -0
- package/dist/collection/components/toast-group/exports.js +1 -0
- package/dist/collection/components/toast-group/toast-group.css +37 -0
- package/dist/collection/components/toast-group/toast-group.js +49 -0
- package/dist/collection/components/tooltip/exports.js +3 -0
- package/dist/collection/components/tooltip/tooltip.css +77 -0
- package/dist/collection/components/tooltip/tooltip.js +525 -0
- package/dist/collection/index.js +2 -0
- package/dist/collection/utils/focusable.js +24 -0
- package/dist/collection/utils/formData.js +40 -0
- package/dist/collection/utils/theming.js +103 -0
- package/dist/collection/utils/version-checker.js +33 -0
- package/dist/esm/app-globals-DQuL1Twl.js +3 -0
- package/dist/esm/focusable-ky1yonnS.js +26 -0
- package/dist/esm/formData-DvLT8-y3.js +42 -0
- package/dist/esm/index-CTxpqopm.js +1806 -0
- package/dist/esm/index.js +35 -0
- package/dist/esm/loader.js +11 -0
- package/dist/esm/r-accordion-panel.entry.js +22 -0
- package/dist/esm/r-accordion-section.entry.js +123 -0
- package/dist/esm/r-accordion-trigger.entry.js +91 -0
- package/dist/esm/r-accordion.entry.js +18 -0
- package/dist/esm/r-alert.entry.js +144 -0
- package/dist/esm/r-badge.entry.js +39 -0
- package/dist/esm/r-button.entry.js +147 -0
- package/dist/esm/r-checkbox-group.entry.js +235 -0
- package/dist/esm/r-checkbox.entry.js +272 -0
- package/dist/esm/r-design-system-devtools.entry.js +29 -0
- package/dist/esm/r-dialog.entry.js +105 -0
- package/dist/esm/r-hint_2.entry.js +47 -0
- package/dist/esm/r-icon-button_2.entry.js +489 -0
- package/dist/esm/r-icon.entry.js +282 -0
- package/dist/esm/r-illustration.entry.js +394 -0
- package/dist/esm/r-input-code.entry.js +435 -0
- package/dist/esm/r-input-date.entry.js +522 -0
- package/dist/esm/r-input-password.entry.js +268 -0
- package/dist/esm/r-input-phone-number.entry.js +2523 -0
- package/dist/esm/r-input.entry.js +616 -0
- package/dist/esm/r-list-item.entry.js +107 -0
- package/dist/esm/r-pagination.entry.js +318 -0
- package/dist/esm/r-panel.entry.js +182 -0
- package/dist/esm/r-popover-action.entry.js +78 -0
- package/dist/esm/r-popover-content.entry.js +60 -0
- package/dist/esm/r-popover-headline.entry.js +26 -0
- package/dist/esm/r-popover-trigger.entry.js +68 -0
- package/dist/esm/r-popover.entry.js +345 -0
- package/dist/esm/r-progress-bar.entry.js +23 -0
- package/dist/esm/r-radio-button-description.entry.js +16 -0
- package/dist/esm/r-radio-button-leading.entry.js +16 -0
- package/dist/esm/r-radio-button-title.entry.js +16 -0
- package/dist/esm/r-radio-button-trailing.entry.js +16 -0
- package/dist/esm/r-radio-button.entry.js +137 -0
- package/dist/esm/r-radio-group.entry.js +426 -0
- package/dist/esm/r-select-option.entry.js +128 -0
- package/dist/esm/r-select.entry.js +1105 -0
- package/dist/esm/r-skip-link.entry.js +17 -0
- package/dist/esm/r-stepper-item.entry.js +40 -0
- package/dist/esm/r-stepper.entry.js +97 -0
- package/dist/esm/r-tab-panel.entry.js +24 -0
- package/dist/esm/r-tab.entry.js +60 -0
- package/dist/esm/r-tabs-list.entry.js +173 -0
- package/dist/esm/r-tabs.entry.js +275 -0
- package/dist/esm/r-textarea.entry.js +268 -0
- package/dist/esm/r-toast-group.entry.js +44 -0
- package/dist/esm/r-toast.entry.js +312 -0
- package/dist/esm/style-observer-4Uv3PpKT.js +1116 -0
- package/dist/esm/theming-DD2IrjpG.js +106 -0
- package/dist/esm/web-components.js +21 -0
- package/dist/index.cjs.js +1 -0
- package/dist/index.js +1 -0
- package/dist/types/components/accordion/accordion.d.ts +27 -0
- package/dist/types/components/accordion/exports.d.ts +2 -0
- package/dist/types/components/accordion-panel/accordion-panel.d.ts +10 -0
- package/dist/types/components/accordion-section/accordion-section.d.ts +36 -0
- package/dist/types/components/accordion-trigger/accordion-trigger.d.ts +33 -0
- package/dist/types/components/alert/alert.d.ts +67 -0
- package/dist/types/components/alert/exports.d.ts +4 -0
- package/dist/types/components/badge/badge.d.ts +26 -0
- package/dist/types/components/badge/exports.d.ts +2 -0
- package/dist/types/components/button/button.d.ts +89 -0
- package/dist/types/components/button/exports.d.ts +10 -0
- package/dist/types/components/checkbox/checkbox.d.ts +138 -0
- package/dist/types/components/checkbox-group/checkbox-group.d.ts +124 -0
- package/dist/types/components/design-system-devtools/design-system-devtools.d.ts +15 -0
- package/dist/types/components/dialog/dialog.d.ts +69 -0
- package/dist/types/components/dialog/exports.d.ts +10 -0
- package/dist/types/components/hint/exports.d.ts +2 -0
- package/dist/types/components/hint/hint.d.ts +20 -0
- package/dist/types/components/icon/all-kit.d.ts +2890 -0
- package/dist/types/components/icon/data.d.ts +145 -0
- package/dist/types/components/icon/exports.d.ts +152 -0
- package/dist/types/components/icon/icon.d.ts +37 -0
- package/dist/types/components/icon/riverty-kit.d.ts +139 -0
- package/dist/types/components/icon-button/icon-button.d.ts +69 -0
- package/dist/types/components/illustration/data.d.ts +52 -0
- package/dist/types/components/illustration/exports.d.ts +23 -0
- package/dist/types/components/illustration/illustration.d.ts +51 -0
- package/dist/types/components/illustration/illustrations-ui-kit.d.ts +21 -0
- package/dist/types/components/input/exports.d.ts +55 -0
- package/dist/types/components/input/input.d.ts +365 -0
- package/dist/types/components/input-code/exports.d.ts +4 -0
- package/dist/types/components/input-code/input-code.d.ts +177 -0
- package/dist/types/components/input-date/exports.d.ts +5 -0
- package/dist/types/components/input-date/input-date.d.ts +174 -0
- package/dist/types/components/input-password/exports.d.ts +1 -0
- package/dist/types/components/input-password/input-password.d.ts +186 -0
- package/dist/types/components/input-phone-number/input-phone-number.d.ts +130 -0
- package/dist/types/components/label/label.d.ts +9 -0
- package/dist/types/components/list-item/list-item/exports.d.ts +4 -0
- package/dist/types/components/list-item/list-item/list-item.d.ts +61 -0
- package/dist/types/components/pagination/exports.d.ts +6 -0
- package/dist/types/components/pagination/pagination.d.ts +140 -0
- package/dist/types/components/panel/exports.d.ts +2 -0
- package/dist/types/components/panel/panel.d.ts +56 -0
- package/dist/types/components/popover/exports.d.ts +6 -0
- package/dist/types/components/popover/popover.d.ts +131 -0
- package/dist/types/components/popover-action/popover-action.d.ts +24 -0
- package/dist/types/components/popover-content/popover-content.d.ts +22 -0
- package/dist/types/components/popover-headline/popover-headline.d.ts +6 -0
- package/dist/types/components/popover-trigger/exports.d.ts +2 -0
- package/dist/types/components/popover-trigger/popover-trigger.d.ts +31 -0
- package/dist/types/components/progress-bar/progress-bar.d.ts +10 -0
- package/dist/types/components/radio-button/radio-button.d.ts +92 -0
- package/dist/types/components/radio-button-description/radio-button-description.d.ts +8 -0
- package/dist/types/components/radio-button-leading/radio-button-leading.d.ts +8 -0
- package/dist/types/components/radio-button-title/radio-button-title.d.ts +8 -0
- package/dist/types/components/radio-button-trailing/radio-button-trailing.d.ts +8 -0
- package/dist/types/components/radio-group/exports.d.ts +2 -0
- package/dist/types/components/radio-group/radio-group.d.ts +179 -0
- package/dist/types/components/select/exports.d.ts +2 -0
- package/dist/types/components/select/select.d.ts +319 -0
- package/dist/types/components/select-option/select-option.d.ts +113 -0
- package/dist/types/components/skip-link/exports.d.ts +2 -0
- package/dist/types/components/skip-link/skip-link.d.ts +6 -0
- package/dist/types/components/stepper/stepper.d.ts +22 -0
- package/dist/types/components/stepper-item/stepper-item.d.ts +23 -0
- package/dist/types/components/tab/tab.d.ts +23 -0
- package/dist/types/components/tab-panel/tab-panel.d.ts +7 -0
- package/dist/types/components/tabs/tabs.d.ts +49 -0
- package/dist/types/components/tabs-list/exports.d.ts +4 -0
- package/dist/types/components/tabs-list/tabs-list.d.ts +41 -0
- package/dist/types/components/textarea/exports.d.ts +2 -0
- package/dist/types/components/textarea/textarea.d.ts +158 -0
- package/dist/types/components/toast/exports.d.ts +6 -0
- package/dist/types/components/toast/toast.d.ts +146 -0
- package/dist/types/components/toast-group/exports.d.ts +2 -0
- package/dist/types/components/toast-group/toast-group.d.ts +9 -0
- package/dist/types/components/tooltip/exports.d.ts +6 -0
- package/dist/types/components/tooltip/tooltip.d.ts +132 -0
- package/dist/types/components.d.ts +6347 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/stencil-public-runtime.d.ts +1732 -0
- package/dist/types/types/jsx-shim.d.ts +13 -0
- package/dist/types/types/style-observer.d.ts +20 -0
- package/dist/types/utils/focusable.d.ts +1 -0
- package/dist/types/utils/formData.d.ts +1 -0
- package/dist/types/utils/theming.d.ts +15 -0
- package/dist/types/utils/version-checker.d.ts +1 -0
- package/dist/web-components/index.esm.js +1 -0
- package/dist/web-components/p-01aefcf0.entry.js +1 -0
- package/dist/web-components/p-05cb55db.entry.js +1 -0
- package/dist/web-components/p-0a34d33b.entry.js +1 -0
- package/dist/web-components/p-11b22309.entry.js +1 -0
- package/dist/web-components/p-2d878934.entry.js +1 -0
- package/dist/web-components/p-325dbedf.entry.js +1 -0
- package/dist/web-components/p-34b9457b.entry.js +1 -0
- package/dist/web-components/p-36abd05a.entry.js +1 -0
- package/dist/web-components/p-386d1ef9.entry.js +1 -0
- package/dist/web-components/p-3d67b77b.entry.js +1 -0
- package/dist/web-components/p-4Uv3PpKT.js +1 -0
- package/dist/web-components/p-4b12fbc0.entry.js +1 -0
- package/dist/web-components/p-52f7b505.entry.js +1 -0
- package/dist/web-components/p-55600d47.entry.js +1 -0
- package/dist/web-components/p-57ebc474.entry.js +1 -0
- package/dist/web-components/p-57edf7f4.entry.js +1 -0
- package/dist/web-components/p-69a24fe2.entry.js +1 -0
- package/dist/web-components/p-6d92648c.entry.js +1 -0
- package/dist/web-components/p-75052597.entry.js +1 -0
- package/dist/web-components/p-7b2c5b63.entry.js +1 -0
- package/dist/web-components/p-7bf463ff.entry.js +1 -0
- package/dist/web-components/p-838e43d4.entry.js +1 -0
- package/dist/web-components/p-8c16d038.entry.js +1 -0
- package/dist/web-components/p-8f8313de.entry.js +1 -0
- package/dist/web-components/p-9026d5a2.entry.js +1 -0
- package/dist/web-components/p-95396b5c.entry.js +1 -0
- package/dist/web-components/p-9c31c7c4.entry.js +1 -0
- package/dist/web-components/p-9c415b9c.entry.js +1 -0
- package/dist/web-components/p-9f583ed1.entry.js +1 -0
- package/dist/web-components/p-B9rsR6cQ.js +1 -0
- package/dist/web-components/p-CTxpqopm.js +2 -0
- package/dist/web-components/p-DQuL1Twl.js +1 -0
- package/dist/web-components/p-DvLT8-y3.js +1 -0
- package/dist/web-components/p-b303b2cc.entry.js +1 -0
- package/dist/web-components/p-b8df041d.entry.js +1 -0
- package/dist/web-components/p-bc30844f.entry.js +1 -0
- package/dist/web-components/p-c4a77a65.entry.js +1 -0
- package/dist/web-components/p-c549addf.entry.js +1 -0
- package/dist/web-components/p-c65df19f.entry.js +1 -0
- package/dist/web-components/p-c80a5541.entry.js +1 -0
- package/dist/web-components/p-c96ee61a.entry.js +1 -0
- package/dist/web-components/p-cf3f044d.entry.js +1 -0
- package/dist/web-components/p-d1412932.entry.js +1 -0
- package/dist/web-components/p-d9778cfa.entry.js +1 -0
- package/dist/web-components/p-dbe4ccb8.entry.js +1 -0
- package/dist/web-components/p-ded50850.entry.js +1 -0
- package/dist/web-components/p-e5be895b.entry.js +1 -0
- package/dist/web-components/p-e6b34c1e.entry.js +1 -0
- package/dist/web-components/p-ec3c4800.entry.js +1 -0
- package/dist/web-components/p-f670fd87.entry.js +1 -0
- package/dist/web-components/p-f867e4c3.entry.js +1 -0
- package/dist/web-components/p-ff6b1b8f.entry.js +1 -0
- package/dist/web-components/p-ky1yonnS.js +1 -0
- package/dist/web-components/web-components.esm.js +1 -0
- package/loader/cdn.js +1 -0
- package/loader/index.cjs.js +1 -0
- package/loader/index.d.ts +24 -0
- package/loader/index.es2017.js +1 -0
- package/loader/index.js +2 -0
- package/package.json +1 -1
|
@@ -0,0 +1,1861 @@
|
|
|
1
|
+
import { Host, h } from "@stencil/core";
|
|
2
|
+
import { nativeInputAttributesSet, excludedAttributesSet, frameworkAttributesSet, managedAriaAttributesSet, attributeCamelCaseMap } from "./exports";
|
|
3
|
+
import { appendControlToFormData } from "../../utils/formData";
|
|
4
|
+
export class RInput {
|
|
5
|
+
constructor() {
|
|
6
|
+
/**
|
|
7
|
+
* Input type (e.g. `text`, `email`, `number`, `password`).
|
|
8
|
+
* See HTMLInputElement `type` for supported values.
|
|
9
|
+
*/
|
|
10
|
+
this.type = 'text';
|
|
11
|
+
/**
|
|
12
|
+
* Current value. Mutable: can be changed programmatically or through user input.
|
|
13
|
+
*/
|
|
14
|
+
this.value = '';
|
|
15
|
+
/** Internal state for options extracted from slotted datalist */
|
|
16
|
+
this.slottedOptions = [];
|
|
17
|
+
/**
|
|
18
|
+
* When `true` field renders valid/invalid marker within.
|
|
19
|
+
*/
|
|
20
|
+
this.validityMarker = true;
|
|
21
|
+
/** Validity state passed from validateFormElement function after validation */
|
|
22
|
+
this.validityState = '';
|
|
23
|
+
/** Validity message passed from validateFormElement function after validation */
|
|
24
|
+
this.validityMessage = '';
|
|
25
|
+
/** Defines if the component has been touched by user */
|
|
26
|
+
this.touched = false;
|
|
27
|
+
/** Defines if the value has been changed by user interaction */
|
|
28
|
+
this.dirty = false;
|
|
29
|
+
/** Private flag to prevent validation during reset */
|
|
30
|
+
this.isResetting = false;
|
|
31
|
+
this.nativeElement = null;
|
|
32
|
+
/**
|
|
33
|
+
* Helper to set the native input element ref and apply boolean properties
|
|
34
|
+
* that don't get properly set through JSX attribute spreading.
|
|
35
|
+
*/
|
|
36
|
+
this.setNativeInputRef = (el) => {
|
|
37
|
+
this.nativeElement = el;
|
|
38
|
+
if (el) {
|
|
39
|
+
el.addEventListener('beforeinput', this.onBeforeInput);
|
|
40
|
+
// Manually apply boolean native attributes as properties
|
|
41
|
+
// This is necessary because Stencil's JSX doesn't always properly
|
|
42
|
+
// set boolean DOM properties when spreading attributes
|
|
43
|
+
const passthroughAttrs = this.collectNativeAttributes();
|
|
44
|
+
// List of boolean native input properties that need manual application
|
|
45
|
+
const booleanProps = ['multiple'];
|
|
46
|
+
for (const prop of booleanProps) {
|
|
47
|
+
if (prop in passthroughAttrs && passthroughAttrs[prop] === true) {
|
|
48
|
+
el[prop] = true;
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
};
|
|
53
|
+
this.uniqueId = `r-input-${Date.now().toString(32)}${Math.random().toString(32)}`.replace(/\./g, '');
|
|
54
|
+
/**
|
|
55
|
+
* Initial attributes state
|
|
56
|
+
* */
|
|
57
|
+
this.initial = {};
|
|
58
|
+
/**
|
|
59
|
+
* Cache for passthrough attributes to avoid recomputing on every render.
|
|
60
|
+
* Cleared when attributes might have changed.
|
|
61
|
+
*/
|
|
62
|
+
this.passthroughAttrsCache = null;
|
|
63
|
+
this.getValidityStateData = (element) => {
|
|
64
|
+
let validityState = '';
|
|
65
|
+
let validityMessage = '';
|
|
66
|
+
if (this.type === 'email' && this.pattern) {
|
|
67
|
+
element.setCustomValidity('');
|
|
68
|
+
validityState = this.validEmailPattern ? 'valid' : 'patternMismatch';
|
|
69
|
+
validityMessage = this.validEmailPattern ? '' : this.patternMismatchMessage;
|
|
70
|
+
return { validityState, validityMessage };
|
|
71
|
+
}
|
|
72
|
+
for (const state in element.validity) {
|
|
73
|
+
if (element.validity[state]) {
|
|
74
|
+
validityState = state;
|
|
75
|
+
const customMessage = this[state + 'Message'];
|
|
76
|
+
if (customMessage) {
|
|
77
|
+
validityMessage = customMessage;
|
|
78
|
+
return { validityState, validityMessage };
|
|
79
|
+
}
|
|
80
|
+
validityMessage = element.validationMessage;
|
|
81
|
+
// Found an error, use it even if no custom message
|
|
82
|
+
return { validityState, validityMessage };
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
// No errors found, field is valid
|
|
86
|
+
return { validityState: 'valid', validityMessage: '' };
|
|
87
|
+
};
|
|
88
|
+
this.validateFormElement = (element) => {
|
|
89
|
+
if (element === null)
|
|
90
|
+
return;
|
|
91
|
+
if (this.isNoValidate)
|
|
92
|
+
return;
|
|
93
|
+
if (this.error)
|
|
94
|
+
return;
|
|
95
|
+
// Trigger browser validation to populate validity states
|
|
96
|
+
if (element.checkValidity) {
|
|
97
|
+
element.checkValidity();
|
|
98
|
+
}
|
|
99
|
+
const { validityState, validityMessage } = this.getValidityStateData(element);
|
|
100
|
+
this.validityState = validityState;
|
|
101
|
+
this.validityMessage = validityMessage;
|
|
102
|
+
const isValid = this.validityState === 'valid';
|
|
103
|
+
this.valid = isValid;
|
|
104
|
+
this.invalid = !isValid;
|
|
105
|
+
this.rValidate.emit({
|
|
106
|
+
state: this.validityState,
|
|
107
|
+
message: this.validityMessage
|
|
108
|
+
});
|
|
109
|
+
};
|
|
110
|
+
this.onInput = (event) => {
|
|
111
|
+
if (this.readonly)
|
|
112
|
+
return;
|
|
113
|
+
this.value = event.target.value;
|
|
114
|
+
this.touched = true;
|
|
115
|
+
this.dirty = true;
|
|
116
|
+
const { host, value } = this;
|
|
117
|
+
this.rInput.emit({ element: host, value });
|
|
118
|
+
};
|
|
119
|
+
this.onChange = event => {
|
|
120
|
+
if (this.readonly)
|
|
121
|
+
return;
|
|
122
|
+
this.value = event.target.value;
|
|
123
|
+
this.touched = true;
|
|
124
|
+
this.dirty = true;
|
|
125
|
+
const { host, value } = this;
|
|
126
|
+
this.rChange.emit({ element: host, value });
|
|
127
|
+
};
|
|
128
|
+
this.onBlur = () => {
|
|
129
|
+
this.host.classList.remove('focused');
|
|
130
|
+
this.touched = true;
|
|
131
|
+
this.validateFormElement(this.nativeElement);
|
|
132
|
+
this.rBlur.emit();
|
|
133
|
+
};
|
|
134
|
+
this.onFocus = () => {
|
|
135
|
+
this.host.classList.add('focused');
|
|
136
|
+
this.rFocus.emit();
|
|
137
|
+
};
|
|
138
|
+
this.onBeforeInput = (event) => {
|
|
139
|
+
this.rBeforeInput.emit(event);
|
|
140
|
+
};
|
|
141
|
+
this.onInvalid = (event) => {
|
|
142
|
+
this.rInvalid.emit(event);
|
|
143
|
+
};
|
|
144
|
+
this.onKeyDown = (event) => {
|
|
145
|
+
this.rKeyDown.emit(event);
|
|
146
|
+
};
|
|
147
|
+
this.onKeyUp = (event) => {
|
|
148
|
+
this.rKeyUp.emit(event);
|
|
149
|
+
};
|
|
150
|
+
this.onSelect = (event) => {
|
|
151
|
+
this.rSelect.emit(event);
|
|
152
|
+
};
|
|
153
|
+
this.contributeToFormData = (event) => {
|
|
154
|
+
appendControlToFormData(this.nativeElement || this.host, event.formData);
|
|
155
|
+
};
|
|
156
|
+
this.datalistObserver = null;
|
|
157
|
+
this.onResetForm = () => {
|
|
158
|
+
if (this.readonly)
|
|
159
|
+
return;
|
|
160
|
+
this.isResetting = true;
|
|
161
|
+
this.markAsPristine();
|
|
162
|
+
this.validityState = null;
|
|
163
|
+
this.validityMessage = null;
|
|
164
|
+
// Restore initial value without triggering validation
|
|
165
|
+
if (this.nativeElement) {
|
|
166
|
+
this.nativeElement.value = this.initial['value'] || '';
|
|
167
|
+
}
|
|
168
|
+
this.value = this.initial['value'];
|
|
169
|
+
this.invalid = this.initial['invalid'];
|
|
170
|
+
this.valid = !this.invalid;
|
|
171
|
+
this.isResetting = false;
|
|
172
|
+
const { host, value } = this;
|
|
173
|
+
this.rReset.emit({ element: host, value });
|
|
174
|
+
};
|
|
175
|
+
this.onSubmitForm = (event) => {
|
|
176
|
+
if (this.isNoValidate)
|
|
177
|
+
return;
|
|
178
|
+
this.touched = true;
|
|
179
|
+
this.validateFormElement(this.nativeElement);
|
|
180
|
+
if (this.invalid) {
|
|
181
|
+
event.preventDefault();
|
|
182
|
+
event.stopPropagation();
|
|
183
|
+
}
|
|
184
|
+
};
|
|
185
|
+
this.handleKeyup = (event) => {
|
|
186
|
+
var _a, _b;
|
|
187
|
+
this.validateFormElement(this.nativeElement);
|
|
188
|
+
if (this.invalid && !this.isNoValidate)
|
|
189
|
+
return;
|
|
190
|
+
if (event.code === 'Enter') {
|
|
191
|
+
const submitEl = this.host.querySelector('[type="submit"]') ||
|
|
192
|
+
((_a = this.parentFormEl) === null || _a === void 0 ? void 0 : _a.querySelector('[type="submit"]'));
|
|
193
|
+
if (submitEl && 'triggerClick' in submitEl) {
|
|
194
|
+
submitEl === null || submitEl === void 0 ? void 0 : submitEl.triggerClick();
|
|
195
|
+
}
|
|
196
|
+
else {
|
|
197
|
+
(_b = this.parentFormEl) === null || _b === void 0 ? void 0 : _b.requestSubmit();
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
};
|
|
201
|
+
this.handleClick = () => {
|
|
202
|
+
this.host.shadowRoot.querySelector('input').focus();
|
|
203
|
+
};
|
|
204
|
+
}
|
|
205
|
+
/**
|
|
206
|
+
* Programmatically focus the native input element.
|
|
207
|
+
*/
|
|
208
|
+
async setFocus() {
|
|
209
|
+
var _a;
|
|
210
|
+
(_a = this.nativeElement) === null || _a === void 0 ? void 0 : _a.focus();
|
|
211
|
+
}
|
|
212
|
+
/**
|
|
213
|
+
* Programmatically remove focus from the native input.
|
|
214
|
+
*/
|
|
215
|
+
async setBlur() {
|
|
216
|
+
var _a;
|
|
217
|
+
(_a = this.nativeElement) === null || _a === void 0 ? void 0 : _a.blur();
|
|
218
|
+
}
|
|
219
|
+
/**
|
|
220
|
+
* Select (highlight) the entire current input value.
|
|
221
|
+
*/
|
|
222
|
+
async select() {
|
|
223
|
+
var _a;
|
|
224
|
+
(_a = this.nativeElement) === null || _a === void 0 ? void 0 : _a.select();
|
|
225
|
+
}
|
|
226
|
+
/**
|
|
227
|
+
* Get the start index of the current text selection (or null if unavailable).
|
|
228
|
+
*/
|
|
229
|
+
async getSelectionStart() {
|
|
230
|
+
var _a, _b;
|
|
231
|
+
return (_b = (_a = this.nativeElement) === null || _a === void 0 ? void 0 : _a.selectionStart) !== null && _b !== void 0 ? _b : null;
|
|
232
|
+
}
|
|
233
|
+
/**
|
|
234
|
+
* Get the end index of the current text selection (or null if unavailable).
|
|
235
|
+
*/
|
|
236
|
+
async getSelectionEnd() {
|
|
237
|
+
var _a, _b;
|
|
238
|
+
return (_b = (_a = this.nativeElement) === null || _a === void 0 ? void 0 : _a.selectionEnd) !== null && _b !== void 0 ? _b : null;
|
|
239
|
+
}
|
|
240
|
+
/**
|
|
241
|
+
* Set a selection (or caret) range within the value.
|
|
242
|
+
* @param start Start index (inclusive)
|
|
243
|
+
* @param end End index (exclusive)
|
|
244
|
+
* @param direction Selection direction (browser hint)
|
|
245
|
+
*/
|
|
246
|
+
async setSelectionRange(start, end, direction = 'none') {
|
|
247
|
+
if (this.nativeElement) {
|
|
248
|
+
this.nativeElement.setSelectionRange(start, end, direction);
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
/**
|
|
252
|
+
* Retrieve the current value (returns empty string if unset).
|
|
253
|
+
*/
|
|
254
|
+
async getValue() {
|
|
255
|
+
var _a;
|
|
256
|
+
return ((_a = this.nativeElement) === null || _a === void 0 ? void 0 : _a.value) || '';
|
|
257
|
+
}
|
|
258
|
+
/**
|
|
259
|
+
* Set the current value programmatically (does not fire native input/change automatically).
|
|
260
|
+
*/
|
|
261
|
+
async setValue(value) {
|
|
262
|
+
if (this.nativeElement) {
|
|
263
|
+
this.nativeElement.value = value;
|
|
264
|
+
}
|
|
265
|
+
this.value = value;
|
|
266
|
+
this.validateFormElement(this.nativeElement);
|
|
267
|
+
}
|
|
268
|
+
/** Validates an element, displays provided message in case value is invalid. */
|
|
269
|
+
async setCustomValidity(message) {
|
|
270
|
+
this.customErrorMessage = message;
|
|
271
|
+
this.validateFormElement(this.nativeElement);
|
|
272
|
+
}
|
|
273
|
+
/**
|
|
274
|
+
* Validates the input without triggering UI and returns a boolean indicating its validity.
|
|
275
|
+
* @returns A boolean indicating whether the input is valid.
|
|
276
|
+
*/
|
|
277
|
+
async checkValidity() {
|
|
278
|
+
const { validityState } = this.getValidityStateData(this.nativeElement);
|
|
279
|
+
return validityState === 'valid';
|
|
280
|
+
}
|
|
281
|
+
/**
|
|
282
|
+
* Gets the touched state (whether user has interacted with the input)
|
|
283
|
+
*/
|
|
284
|
+
async isTouched() {
|
|
285
|
+
return this.touched;
|
|
286
|
+
}
|
|
287
|
+
/**
|
|
288
|
+
* Gets the dirty state (whether value has been changed by user)
|
|
289
|
+
*/
|
|
290
|
+
async isDirty() {
|
|
291
|
+
return this.dirty;
|
|
292
|
+
}
|
|
293
|
+
/**
|
|
294
|
+
* Resets touched and dirty states to pristine (untouched/clean)
|
|
295
|
+
*/
|
|
296
|
+
async markAsPristine() {
|
|
297
|
+
this.touched = false;
|
|
298
|
+
this.dirty = false;
|
|
299
|
+
}
|
|
300
|
+
get datalistId() {
|
|
301
|
+
return `${this.uniqueId}-list`;
|
|
302
|
+
}
|
|
303
|
+
/**
|
|
304
|
+
* Checks if an attribute should be excluded from passthrough.
|
|
305
|
+
*/
|
|
306
|
+
shouldExcludeAttribute(attrName) {
|
|
307
|
+
return (frameworkAttributesSet.has(attrName) ||
|
|
308
|
+
excludedAttributesSet.has(attrName) ||
|
|
309
|
+
managedAriaAttributesSet.has(attrName));
|
|
310
|
+
}
|
|
311
|
+
/**
|
|
312
|
+
* Collects native HTML input attributes from the host element that aren't
|
|
313
|
+
* already handled by explicit props. This allows passing through attributes
|
|
314
|
+
* like 'list', 'multiple', 'size', etc. without creating explicit props.
|
|
315
|
+
* Optimized with Set lookups (O(1)) and caching.
|
|
316
|
+
*/
|
|
317
|
+
collectNativeAttributes() {
|
|
318
|
+
// Return cached result if available
|
|
319
|
+
if (this.passthroughAttrsCache !== null) {
|
|
320
|
+
return this.passthroughAttrsCache;
|
|
321
|
+
}
|
|
322
|
+
const collected = {};
|
|
323
|
+
const hostAttrs = this.host.attributes;
|
|
324
|
+
// Early return if no attributes to process
|
|
325
|
+
if (!hostAttrs || hostAttrs.length === 0) {
|
|
326
|
+
this.passthroughAttrsCache = collected;
|
|
327
|
+
return collected;
|
|
328
|
+
}
|
|
329
|
+
for (const attr of Array.from(hostAttrs)) {
|
|
330
|
+
const attrName = attr.name.toLowerCase();
|
|
331
|
+
// Skip framework/component-specific attributes using helper method
|
|
332
|
+
if (this.shouldExcludeAttribute(attrName)) {
|
|
333
|
+
continue;
|
|
334
|
+
}
|
|
335
|
+
// Include data-* or native input attributes (exclude aria- - component manages ARIA via inputAttrs)
|
|
336
|
+
if (attrName.startsWith('data-') || nativeInputAttributesSet.has(attrName)) {
|
|
337
|
+
// Use special camelCase mapping for certain attributes that need it for JSX properties
|
|
338
|
+
// Otherwise keep the attribute name as-is for native HTML attributes
|
|
339
|
+
const jsxAttrName = attributeCamelCaseMap[attrName] || attrName;
|
|
340
|
+
// Handle boolean attributes: if value is empty or matches attribute name, set to true
|
|
341
|
+
// This ensures proper JSX rendering for attributes like 'multiple'
|
|
342
|
+
const attrValue = attr.value;
|
|
343
|
+
collected[jsxAttrName] = (attrValue === '' || attrValue === attrName) ? true : attrValue;
|
|
344
|
+
}
|
|
345
|
+
}
|
|
346
|
+
// Cache the result
|
|
347
|
+
this.passthroughAttrsCache = collected;
|
|
348
|
+
return collected;
|
|
349
|
+
}
|
|
350
|
+
/** Identify wrapping form element */
|
|
351
|
+
get parentFormEl() {
|
|
352
|
+
return this.host.closest('form') || document.querySelector(`#${this.form}`) || null;
|
|
353
|
+
}
|
|
354
|
+
get ariaDescribedBy() {
|
|
355
|
+
const describedBy = `${this.uniqueId}-message`;
|
|
356
|
+
return this.hint ? `${this.uniqueId}-hint ${describedBy}` : describedBy;
|
|
357
|
+
}
|
|
358
|
+
get hasError() {
|
|
359
|
+
var _a;
|
|
360
|
+
return this.invalid && !!((_a = this.error) === null || _a === void 0 ? void 0 : _a.length);
|
|
361
|
+
}
|
|
362
|
+
get hasValidationError() {
|
|
363
|
+
return (this.validityState && this.validityState !== 'valid' || this.invalid) && !!(this.validityMessage || this.customErrorMessage);
|
|
364
|
+
}
|
|
365
|
+
get hasMessage() {
|
|
366
|
+
return this.hasError || this.hasValidationError;
|
|
367
|
+
}
|
|
368
|
+
/**
|
|
369
|
+
* Determine whether this element should be ignored
|
|
370
|
+
* during Constraint Validation API validation.
|
|
371
|
+
* */
|
|
372
|
+
get isNoValidate() {
|
|
373
|
+
var _a;
|
|
374
|
+
return (((_a = this.parentFormEl) === null || _a === void 0 ? void 0 : _a.hasAttribute('novalidate')) ||
|
|
375
|
+
this.novalidate ||
|
|
376
|
+
false);
|
|
377
|
+
}
|
|
378
|
+
get hasTrailingSlot() {
|
|
379
|
+
return !!this.host.querySelector('[slot="trailing"]');
|
|
380
|
+
}
|
|
381
|
+
get validEmailPattern() {
|
|
382
|
+
if (!this.value)
|
|
383
|
+
return false;
|
|
384
|
+
const regex = new RegExp(this.pattern, 'u');
|
|
385
|
+
return regex.test(this.value);
|
|
386
|
+
}
|
|
387
|
+
componentWillLoad() {
|
|
388
|
+
this.initial['value'] = this.value;
|
|
389
|
+
this.initial['invalid'] = this.invalid;
|
|
390
|
+
// Clear passthrough attributes cache to ensure fresh collection on load
|
|
391
|
+
this.passthroughAttrsCache = null;
|
|
392
|
+
// Extract options from slotted datalist
|
|
393
|
+
this.extractSlottedDatalistOptions();
|
|
394
|
+
}
|
|
395
|
+
/**
|
|
396
|
+
* Extracts options from a slotted <datalist> element.
|
|
397
|
+
* Supports both default slot and slot="datalist" usage.
|
|
398
|
+
*/
|
|
399
|
+
extractSlottedDatalistOptions() {
|
|
400
|
+
// First check for slot="datalist"
|
|
401
|
+
const slottedDatalist = this.host.querySelector('datalist[slot="datalist"]');
|
|
402
|
+
if (!slottedDatalist) {
|
|
403
|
+
// Check for datalist in default slot
|
|
404
|
+
const defaultSlotDatalist = Array.from(this.host.querySelectorAll('datalist'))
|
|
405
|
+
.find(el => !el.hasAttribute('slot'));
|
|
406
|
+
if (!defaultSlotDatalist) {
|
|
407
|
+
return;
|
|
408
|
+
}
|
|
409
|
+
this.slottedOptions = this.parseDatalistOptions(defaultSlotDatalist);
|
|
410
|
+
}
|
|
411
|
+
else {
|
|
412
|
+
this.slottedOptions = this.parseDatalistOptions(slottedDatalist);
|
|
413
|
+
}
|
|
414
|
+
}
|
|
415
|
+
/**
|
|
416
|
+
* Parses options from a HTMLDataListElement into InputOption array.
|
|
417
|
+
*/
|
|
418
|
+
parseDatalistOptions(datalist) {
|
|
419
|
+
const options = [];
|
|
420
|
+
const optionElements = datalist.querySelectorAll('option');
|
|
421
|
+
optionElements.forEach(opt => {
|
|
422
|
+
options.push({
|
|
423
|
+
value: opt.value,
|
|
424
|
+
label: opt.label || opt.textContent || opt.value
|
|
425
|
+
});
|
|
426
|
+
});
|
|
427
|
+
return options;
|
|
428
|
+
}
|
|
429
|
+
connectFormEventListeners() {
|
|
430
|
+
var _a, _b, _c;
|
|
431
|
+
(_a = this.parentFormEl) === null || _a === void 0 ? void 0 : _a.addEventListener('formdata', this.contributeToFormData);
|
|
432
|
+
(_b = this.parentFormEl) === null || _b === void 0 ? void 0 : _b.addEventListener('submit', this.onSubmitForm, { capture: true });
|
|
433
|
+
(_c = this.parentFormEl) === null || _c === void 0 ? void 0 : _c.addEventListener('reset', this.onResetForm);
|
|
434
|
+
}
|
|
435
|
+
connectedCallback() {
|
|
436
|
+
this.connectFormEventListeners();
|
|
437
|
+
this.setupDatalistObserver();
|
|
438
|
+
if (this.autofocus && !RInput.autofocusHandled) {
|
|
439
|
+
RInput.autofocusHandled = true;
|
|
440
|
+
queueMicrotask(() => { var _a; return (_a = this.host.querySelector('input[autofocus]')) === null || _a === void 0 ? void 0 : _a.focus({ preventScroll: true }); });
|
|
441
|
+
}
|
|
442
|
+
}
|
|
443
|
+
disconnectedCallback() {
|
|
444
|
+
var _a;
|
|
445
|
+
this.disconnectFormEventListeners();
|
|
446
|
+
this.disconnectDatalistObserver();
|
|
447
|
+
(_a = this.nativeElement) === null || _a === void 0 ? void 0 : _a.removeEventListener('beforeinput', this.onBeforeInput);
|
|
448
|
+
}
|
|
449
|
+
setupDatalistObserver() {
|
|
450
|
+
this.extractSlottedDatalistOptions();
|
|
451
|
+
if (typeof MutationObserver === 'undefined') {
|
|
452
|
+
return;
|
|
453
|
+
}
|
|
454
|
+
this.datalistObserver = new MutationObserver((mutations) => {
|
|
455
|
+
for (const mutation of mutations) {
|
|
456
|
+
if (mutation.type === 'childList') {
|
|
457
|
+
this.extractSlottedDatalistOptions();
|
|
458
|
+
break;
|
|
459
|
+
}
|
|
460
|
+
}
|
|
461
|
+
});
|
|
462
|
+
this.datalistObserver.observe(this.host, {
|
|
463
|
+
childList: true,
|
|
464
|
+
subtree: false
|
|
465
|
+
});
|
|
466
|
+
}
|
|
467
|
+
disconnectDatalistObserver() {
|
|
468
|
+
if (this.datalistObserver) {
|
|
469
|
+
this.datalistObserver.disconnect();
|
|
470
|
+
this.datalistObserver = null;
|
|
471
|
+
}
|
|
472
|
+
}
|
|
473
|
+
disconnectFormEventListeners() {
|
|
474
|
+
var _a, _b, _c;
|
|
475
|
+
(_a = this.parentFormEl) === null || _a === void 0 ? void 0 : _a.removeEventListener('formdata', this.contributeToFormData);
|
|
476
|
+
(_b = this.parentFormEl) === null || _b === void 0 ? void 0 : _b.removeEventListener('submit', this.onSubmitForm);
|
|
477
|
+
(_c = this.parentFormEl) === null || _c === void 0 ? void 0 : _c.removeEventListener('reset', this.onResetForm);
|
|
478
|
+
}
|
|
479
|
+
handleValueChange() {
|
|
480
|
+
if (!this.isResetting) {
|
|
481
|
+
this.validateFormElement(this.nativeElement);
|
|
482
|
+
}
|
|
483
|
+
}
|
|
484
|
+
handleTypeChange() {
|
|
485
|
+
if (this.nativeElement) {
|
|
486
|
+
this.setValue(this.nativeElement.value);
|
|
487
|
+
}
|
|
488
|
+
}
|
|
489
|
+
render() {
|
|
490
|
+
const { name, placeholder, required, fieldIndicator, maxlength, minlength, min, max, value, disabled, form, pattern, invalid, valid, hint, label, internal, uniqueId, autocomplete, readonly, autofocus, passwordrules, enterkeyhint, spellcheck, autocapitalize, validityMarker } = this;
|
|
491
|
+
// Collect any native input attributes that were set on the host element
|
|
492
|
+
const passthroughAttrs = this.collectNativeAttributes();
|
|
493
|
+
// Combine options from prop and slotted datalist (prop takes precedence)
|
|
494
|
+
const options = [...(this.slottedOptions || [])];
|
|
495
|
+
const hasDatalist = options.length > 0;
|
|
496
|
+
const inputAttrs = Object.assign(Object.assign({ disabled,
|
|
497
|
+
readonly,
|
|
498
|
+
required,
|
|
499
|
+
label,
|
|
500
|
+
name,
|
|
501
|
+
placeholder,
|
|
502
|
+
maxlength,
|
|
503
|
+
minlength,
|
|
504
|
+
min,
|
|
505
|
+
max,
|
|
506
|
+
form,
|
|
507
|
+
pattern,
|
|
508
|
+
autocomplete, autofocus: autofocus || null, passwordrules,
|
|
509
|
+
enterkeyhint,
|
|
510
|
+
autocapitalize,
|
|
511
|
+
spellcheck, inputmode: this.inputmode || null, id: uniqueId }, passthroughAttrs), {
|
|
512
|
+
// Component-controlled values always win
|
|
513
|
+
'data-value': value, 'aria-invalid': `${invalid || false}`, 'aria-required': `${required || false}`, 'aria-describedby': this.ariaDescribedBy,
|
|
514
|
+
// list attribute: use internal datalist when options provided, otherwise use passthrough value (explicit takes precedence)
|
|
515
|
+
list: hasDatalist ? this.datalistId : (passthroughAttrs.list || null)
|
|
516
|
+
});
|
|
517
|
+
const labelAttr = label ? {
|
|
518
|
+
id: `${uniqueId}-label`,
|
|
519
|
+
fieldIndicator
|
|
520
|
+
} : {};
|
|
521
|
+
const renderValidationMarker = () => {
|
|
522
|
+
const icons = {
|
|
523
|
+
valid: 'circled-check',
|
|
524
|
+
invalid: 'circled-exclamation-mark'
|
|
525
|
+
};
|
|
526
|
+
const colors = {
|
|
527
|
+
valid: '--r-status-success-regular',
|
|
528
|
+
invalid: '--r-status-error-regular'
|
|
529
|
+
};
|
|
530
|
+
const shouldShowValidMarker = !!validityMarker && !!valid && !!value;
|
|
531
|
+
const shouldShowInvalidMarker = !!validityMarker && !!invalid;
|
|
532
|
+
if (!shouldShowValidMarker && !shouldShowInvalidMarker)
|
|
533
|
+
return null;
|
|
534
|
+
const iconName = shouldShowInvalidMarker ? icons.invalid : icons.valid;
|
|
535
|
+
const iconColor = shouldShowInvalidMarker ? colors.invalid : colors.valid;
|
|
536
|
+
return h("r-icon", { class: "r-input--validation-icon", "aria-hidden": "true", size: "s", name: iconName, color: iconColor });
|
|
537
|
+
};
|
|
538
|
+
return (h(Host, { onClick: this.handleClick, onKeyup: this.handleKeyup, "data-touched": `${this.touched}`, "data-dirty": `${this.dirty}` }, h("div", { class: internal ? 'visually-hidden' : 'r-input--label-container' }, h("label", { htmlFor: uniqueId }, label ?
|
|
539
|
+
h("r-label", Object.assign({ class: "r-input--label" }, labelAttr), label)
|
|
540
|
+
:
|
|
541
|
+
h("slot", { name: "label" })), h("slot", { name: "popover" })), hint &&
|
|
542
|
+
h("r-hint", { id: `${uniqueId}-hint`, role: "note" }, hint), h("div", { class: "r-input--container" }, h("slot", { name: "leading" }), h("input", Object.assign({ class: "r-input--input", type: this.type }, inputAttrs, { ref: this.setNativeInputRef, value: this.value, onInput: this.onInput, onChange: this.onChange, onBlur: this.onBlur, onFocus: this.onFocus, onInvalid: this.onInvalid, onKeyDown: this.onKeyDown, onKeyUp: this.onKeyUp, onSelect: this.onSelect })), hasDatalist && (h("datalist", { ref: (el) => el && (el.id = this.datalistId) }, options.map((option) => (h("option", { value: option.value }, option.label || option.value))))), h("div", { class: "r-input--trailing" }, this.readonly &&
|
|
543
|
+
h("r-icon", { class: "r-input--readonly-icon", name: "pen-disabled", size: "s" }), renderValidationMarker(), this.hasTrailingSlot &&
|
|
544
|
+
h("slot", { name: "trailing" }))), h("div", { id: `${uniqueId}-message`, "aria-live": !internal ? 'polite' : null, class: !internal ? 'r-input--message' : 'visually-hidden' }, h("slot", { name: "message" }, this.hasMessage && h("r-hint", { variant: valid ? 'success' : 'error' }, this.hasError && this.error, this.hasValidationError && (this.customErrorMessage || this.validityMessage))))));
|
|
545
|
+
}
|
|
546
|
+
static get is() { return "r-input"; }
|
|
547
|
+
static get encapsulation() { return "shadow"; }
|
|
548
|
+
static get originalStyleUrls() {
|
|
549
|
+
return {
|
|
550
|
+
"$": ["input.css"]
|
|
551
|
+
};
|
|
552
|
+
}
|
|
553
|
+
static get styleUrls() {
|
|
554
|
+
return {
|
|
555
|
+
"$": ["input.css"]
|
|
556
|
+
};
|
|
557
|
+
}
|
|
558
|
+
static get properties() {
|
|
559
|
+
return {
|
|
560
|
+
"form": {
|
|
561
|
+
"type": "string",
|
|
562
|
+
"attribute": "form",
|
|
563
|
+
"mutable": false,
|
|
564
|
+
"complexType": {
|
|
565
|
+
"original": "string",
|
|
566
|
+
"resolved": "string",
|
|
567
|
+
"references": {}
|
|
568
|
+
},
|
|
569
|
+
"required": false,
|
|
570
|
+
"optional": true,
|
|
571
|
+
"docs": {
|
|
572
|
+
"tags": [],
|
|
573
|
+
"text": "ID of the form this input is associated with (mirrors native `form` attribute).\nUse when the input is not a direct descendant of the target form element."
|
|
574
|
+
},
|
|
575
|
+
"getter": false,
|
|
576
|
+
"setter": false,
|
|
577
|
+
"reflect": false
|
|
578
|
+
},
|
|
579
|
+
"novalidate": {
|
|
580
|
+
"type": "boolean",
|
|
581
|
+
"attribute": "novalidate",
|
|
582
|
+
"mutable": false,
|
|
583
|
+
"complexType": {
|
|
584
|
+
"original": "boolean",
|
|
585
|
+
"resolved": "boolean",
|
|
586
|
+
"references": {}
|
|
587
|
+
},
|
|
588
|
+
"required": false,
|
|
589
|
+
"optional": true,
|
|
590
|
+
"docs": {
|
|
591
|
+
"tags": [],
|
|
592
|
+
"text": "If set, the field is skipped by built\u2011in (Constraint Validation API) validation logic.\nDoes not prevent custom validation you may trigger manually."
|
|
593
|
+
},
|
|
594
|
+
"getter": false,
|
|
595
|
+
"setter": false,
|
|
596
|
+
"reflect": false
|
|
597
|
+
},
|
|
598
|
+
"type": {
|
|
599
|
+
"type": "string",
|
|
600
|
+
"attribute": "type",
|
|
601
|
+
"mutable": false,
|
|
602
|
+
"complexType": {
|
|
603
|
+
"original": "InputType",
|
|
604
|
+
"resolved": "\"email\" | \"number\" | \"password\" | \"search\" | \"tel\" | \"text\" | \"url\"",
|
|
605
|
+
"references": {
|
|
606
|
+
"InputType": {
|
|
607
|
+
"location": "import",
|
|
608
|
+
"path": "./exports",
|
|
609
|
+
"id": "src/components/input/exports.ts::InputType"
|
|
610
|
+
}
|
|
611
|
+
}
|
|
612
|
+
},
|
|
613
|
+
"required": false,
|
|
614
|
+
"optional": false,
|
|
615
|
+
"docs": {
|
|
616
|
+
"tags": [],
|
|
617
|
+
"text": "Input type (e.g. `text`, `email`, `number`, `password`).\nSee HTMLInputElement `type` for supported values."
|
|
618
|
+
},
|
|
619
|
+
"getter": false,
|
|
620
|
+
"setter": false,
|
|
621
|
+
"reflect": true,
|
|
622
|
+
"defaultValue": "'text'"
|
|
623
|
+
},
|
|
624
|
+
"name": {
|
|
625
|
+
"type": "string",
|
|
626
|
+
"attribute": "name",
|
|
627
|
+
"mutable": false,
|
|
628
|
+
"complexType": {
|
|
629
|
+
"original": "string",
|
|
630
|
+
"resolved": "string",
|
|
631
|
+
"references": {}
|
|
632
|
+
},
|
|
633
|
+
"required": false,
|
|
634
|
+
"optional": false,
|
|
635
|
+
"docs": {
|
|
636
|
+
"tags": [],
|
|
637
|
+
"text": "Name used when contributing the value to form submission (`FormData` / POST body)."
|
|
638
|
+
},
|
|
639
|
+
"getter": false,
|
|
640
|
+
"setter": false,
|
|
641
|
+
"reflect": true
|
|
642
|
+
},
|
|
643
|
+
"value": {
|
|
644
|
+
"type": "string",
|
|
645
|
+
"attribute": "value",
|
|
646
|
+
"mutable": true,
|
|
647
|
+
"complexType": {
|
|
648
|
+
"original": "string | null",
|
|
649
|
+
"resolved": "string",
|
|
650
|
+
"references": {}
|
|
651
|
+
},
|
|
652
|
+
"required": false,
|
|
653
|
+
"optional": true,
|
|
654
|
+
"docs": {
|
|
655
|
+
"tags": [],
|
|
656
|
+
"text": "Current value. Mutable: can be changed programmatically or through user input."
|
|
657
|
+
},
|
|
658
|
+
"getter": false,
|
|
659
|
+
"setter": false,
|
|
660
|
+
"reflect": true,
|
|
661
|
+
"defaultValue": "''"
|
|
662
|
+
},
|
|
663
|
+
"placeholder": {
|
|
664
|
+
"type": "string",
|
|
665
|
+
"attribute": "placeholder",
|
|
666
|
+
"mutable": false,
|
|
667
|
+
"complexType": {
|
|
668
|
+
"original": "string",
|
|
669
|
+
"resolved": "string",
|
|
670
|
+
"references": {}
|
|
671
|
+
},
|
|
672
|
+
"required": false,
|
|
673
|
+
"optional": true,
|
|
674
|
+
"docs": {
|
|
675
|
+
"tags": [],
|
|
676
|
+
"text": "Placeholder hint text shown when the field is empty and unfocused."
|
|
677
|
+
},
|
|
678
|
+
"getter": false,
|
|
679
|
+
"setter": false,
|
|
680
|
+
"reflect": false
|
|
681
|
+
},
|
|
682
|
+
"label": {
|
|
683
|
+
"type": "string",
|
|
684
|
+
"attribute": "label",
|
|
685
|
+
"mutable": false,
|
|
686
|
+
"complexType": {
|
|
687
|
+
"original": "string",
|
|
688
|
+
"resolved": "string",
|
|
689
|
+
"references": {}
|
|
690
|
+
},
|
|
691
|
+
"required": true,
|
|
692
|
+
"optional": false,
|
|
693
|
+
"docs": {
|
|
694
|
+
"tags": [],
|
|
695
|
+
"text": "Label text describing the field. Provide for accessibility (or use the `label` slot)."
|
|
696
|
+
},
|
|
697
|
+
"getter": false,
|
|
698
|
+
"setter": false,
|
|
699
|
+
"reflect": true
|
|
700
|
+
},
|
|
701
|
+
"fieldIndicator": {
|
|
702
|
+
"type": "string",
|
|
703
|
+
"attribute": "field-indicator",
|
|
704
|
+
"mutable": false,
|
|
705
|
+
"complexType": {
|
|
706
|
+
"original": "string",
|
|
707
|
+
"resolved": "string",
|
|
708
|
+
"references": {}
|
|
709
|
+
},
|
|
710
|
+
"required": false,
|
|
711
|
+
"optional": true,
|
|
712
|
+
"docs": {
|
|
713
|
+
"tags": [],
|
|
714
|
+
"text": "Small marker string appended to the label (e.g. \u201COptional\u201D, localized markers, etc.)."
|
|
715
|
+
},
|
|
716
|
+
"getter": false,
|
|
717
|
+
"setter": false,
|
|
718
|
+
"reflect": false
|
|
719
|
+
},
|
|
720
|
+
"internal": {
|
|
721
|
+
"type": "boolean",
|
|
722
|
+
"attribute": "internal",
|
|
723
|
+
"mutable": false,
|
|
724
|
+
"complexType": {
|
|
725
|
+
"original": "boolean",
|
|
726
|
+
"resolved": "boolean",
|
|
727
|
+
"references": {}
|
|
728
|
+
},
|
|
729
|
+
"required": false,
|
|
730
|
+
"optional": true,
|
|
731
|
+
"docs": {
|
|
732
|
+
"tags": [],
|
|
733
|
+
"text": "When true, hides visual label & messages (for internal layout use; accessibility still preserved)."
|
|
734
|
+
},
|
|
735
|
+
"getter": false,
|
|
736
|
+
"setter": false,
|
|
737
|
+
"reflect": true
|
|
738
|
+
},
|
|
739
|
+
"hint": {
|
|
740
|
+
"type": "string",
|
|
741
|
+
"attribute": "hint",
|
|
742
|
+
"mutable": false,
|
|
743
|
+
"complexType": {
|
|
744
|
+
"original": "string",
|
|
745
|
+
"resolved": "string",
|
|
746
|
+
"references": {}
|
|
747
|
+
},
|
|
748
|
+
"required": false,
|
|
749
|
+
"optional": true,
|
|
750
|
+
"docs": {
|
|
751
|
+
"tags": [],
|
|
752
|
+
"text": "Optional contextual help text displayed beneath the field."
|
|
753
|
+
},
|
|
754
|
+
"getter": false,
|
|
755
|
+
"setter": false,
|
|
756
|
+
"reflect": false
|
|
757
|
+
},
|
|
758
|
+
"fullWidth": {
|
|
759
|
+
"type": "boolean",
|
|
760
|
+
"attribute": "full-width",
|
|
761
|
+
"mutable": false,
|
|
762
|
+
"complexType": {
|
|
763
|
+
"original": "boolean",
|
|
764
|
+
"resolved": "boolean",
|
|
765
|
+
"references": {}
|
|
766
|
+
},
|
|
767
|
+
"required": false,
|
|
768
|
+
"optional": true,
|
|
769
|
+
"docs": {
|
|
770
|
+
"tags": [],
|
|
771
|
+
"text": "When true, stretches the component horizontally to fill its container."
|
|
772
|
+
},
|
|
773
|
+
"getter": false,
|
|
774
|
+
"setter": false,
|
|
775
|
+
"reflect": true
|
|
776
|
+
},
|
|
777
|
+
"valid": {
|
|
778
|
+
"type": "boolean",
|
|
779
|
+
"attribute": "valid",
|
|
780
|
+
"mutable": true,
|
|
781
|
+
"complexType": {
|
|
782
|
+
"original": "boolean",
|
|
783
|
+
"resolved": "boolean",
|
|
784
|
+
"references": {}
|
|
785
|
+
},
|
|
786
|
+
"required": false,
|
|
787
|
+
"optional": true,
|
|
788
|
+
"docs": {
|
|
789
|
+
"tags": [],
|
|
790
|
+
"text": "Explicit valid state override (when set manually)."
|
|
791
|
+
},
|
|
792
|
+
"getter": false,
|
|
793
|
+
"setter": false,
|
|
794
|
+
"reflect": true
|
|
795
|
+
},
|
|
796
|
+
"invalid": {
|
|
797
|
+
"type": "boolean",
|
|
798
|
+
"attribute": "invalid",
|
|
799
|
+
"mutable": true,
|
|
800
|
+
"complexType": {
|
|
801
|
+
"original": "boolean",
|
|
802
|
+
"resolved": "boolean",
|
|
803
|
+
"references": {}
|
|
804
|
+
},
|
|
805
|
+
"required": false,
|
|
806
|
+
"optional": true,
|
|
807
|
+
"docs": {
|
|
808
|
+
"tags": [],
|
|
809
|
+
"text": "Explicit invalid state override (when set manually)."
|
|
810
|
+
},
|
|
811
|
+
"getter": false,
|
|
812
|
+
"setter": false,
|
|
813
|
+
"reflect": true
|
|
814
|
+
},
|
|
815
|
+
"error": {
|
|
816
|
+
"type": "string",
|
|
817
|
+
"attribute": "error",
|
|
818
|
+
"mutable": false,
|
|
819
|
+
"complexType": {
|
|
820
|
+
"original": "string",
|
|
821
|
+
"resolved": "string",
|
|
822
|
+
"references": {}
|
|
823
|
+
},
|
|
824
|
+
"required": false,
|
|
825
|
+
"optional": true,
|
|
826
|
+
"docs": {
|
|
827
|
+
"tags": [],
|
|
828
|
+
"text": "Manual error message independent of native validation messages.\nWhen set, native validation messages are suppressed."
|
|
829
|
+
},
|
|
830
|
+
"getter": false,
|
|
831
|
+
"setter": false,
|
|
832
|
+
"reflect": false
|
|
833
|
+
},
|
|
834
|
+
"disabled": {
|
|
835
|
+
"type": "boolean",
|
|
836
|
+
"attribute": "disabled",
|
|
837
|
+
"mutable": false,
|
|
838
|
+
"complexType": {
|
|
839
|
+
"original": "boolean",
|
|
840
|
+
"resolved": "boolean",
|
|
841
|
+
"references": {}
|
|
842
|
+
},
|
|
843
|
+
"required": false,
|
|
844
|
+
"optional": true,
|
|
845
|
+
"docs": {
|
|
846
|
+
"tags": [],
|
|
847
|
+
"text": "Disables the field (non-interactive, excluded from form submission)."
|
|
848
|
+
},
|
|
849
|
+
"getter": false,
|
|
850
|
+
"setter": false,
|
|
851
|
+
"reflect": true
|
|
852
|
+
},
|
|
853
|
+
"required": {
|
|
854
|
+
"type": "boolean",
|
|
855
|
+
"attribute": "required",
|
|
856
|
+
"mutable": false,
|
|
857
|
+
"complexType": {
|
|
858
|
+
"original": "boolean",
|
|
859
|
+
"resolved": "boolean",
|
|
860
|
+
"references": {}
|
|
861
|
+
},
|
|
862
|
+
"required": false,
|
|
863
|
+
"optional": true,
|
|
864
|
+
"docs": {
|
|
865
|
+
"tags": [],
|
|
866
|
+
"text": "Marks the field as required; failing to provide a value triggers `valueMissing`."
|
|
867
|
+
},
|
|
868
|
+
"getter": false,
|
|
869
|
+
"setter": false,
|
|
870
|
+
"reflect": true
|
|
871
|
+
},
|
|
872
|
+
"maxlength": {
|
|
873
|
+
"type": "number",
|
|
874
|
+
"attribute": "maxlength",
|
|
875
|
+
"mutable": false,
|
|
876
|
+
"complexType": {
|
|
877
|
+
"original": "number",
|
|
878
|
+
"resolved": "number",
|
|
879
|
+
"references": {}
|
|
880
|
+
},
|
|
881
|
+
"required": false,
|
|
882
|
+
"optional": true,
|
|
883
|
+
"docs": {
|
|
884
|
+
"tags": [],
|
|
885
|
+
"text": "Maximum character length (enforced by native input)."
|
|
886
|
+
},
|
|
887
|
+
"getter": false,
|
|
888
|
+
"setter": false,
|
|
889
|
+
"reflect": false
|
|
890
|
+
},
|
|
891
|
+
"minlength": {
|
|
892
|
+
"type": "number",
|
|
893
|
+
"attribute": "minlength",
|
|
894
|
+
"mutable": false,
|
|
895
|
+
"complexType": {
|
|
896
|
+
"original": "number",
|
|
897
|
+
"resolved": "number",
|
|
898
|
+
"references": {}
|
|
899
|
+
},
|
|
900
|
+
"required": false,
|
|
901
|
+
"optional": true,
|
|
902
|
+
"docs": {
|
|
903
|
+
"tags": [],
|
|
904
|
+
"text": "Minimum character length (validation only)."
|
|
905
|
+
},
|
|
906
|
+
"getter": false,
|
|
907
|
+
"setter": false,
|
|
908
|
+
"reflect": false
|
|
909
|
+
},
|
|
910
|
+
"min": {
|
|
911
|
+
"type": "number",
|
|
912
|
+
"attribute": "min",
|
|
913
|
+
"mutable": false,
|
|
914
|
+
"complexType": {
|
|
915
|
+
"original": "number",
|
|
916
|
+
"resolved": "number",
|
|
917
|
+
"references": {}
|
|
918
|
+
},
|
|
919
|
+
"required": false,
|
|
920
|
+
"optional": true,
|
|
921
|
+
"docs": {
|
|
922
|
+
"tags": [],
|
|
923
|
+
"text": "Minimum numeric/date value (for supported types)."
|
|
924
|
+
},
|
|
925
|
+
"getter": false,
|
|
926
|
+
"setter": false,
|
|
927
|
+
"reflect": false
|
|
928
|
+
},
|
|
929
|
+
"max": {
|
|
930
|
+
"type": "number",
|
|
931
|
+
"attribute": "max",
|
|
932
|
+
"mutable": false,
|
|
933
|
+
"complexType": {
|
|
934
|
+
"original": "number",
|
|
935
|
+
"resolved": "number",
|
|
936
|
+
"references": {}
|
|
937
|
+
},
|
|
938
|
+
"required": false,
|
|
939
|
+
"optional": true,
|
|
940
|
+
"docs": {
|
|
941
|
+
"tags": [],
|
|
942
|
+
"text": "Maximum numeric/date value (for supported types)."
|
|
943
|
+
},
|
|
944
|
+
"getter": false,
|
|
945
|
+
"setter": false,
|
|
946
|
+
"reflect": false
|
|
947
|
+
},
|
|
948
|
+
"pattern": {
|
|
949
|
+
"type": "any",
|
|
950
|
+
"attribute": "pattern",
|
|
951
|
+
"mutable": false,
|
|
952
|
+
"complexType": {
|
|
953
|
+
"original": "any",
|
|
954
|
+
"resolved": "any",
|
|
955
|
+
"references": {}
|
|
956
|
+
},
|
|
957
|
+
"required": false,
|
|
958
|
+
"optional": true,
|
|
959
|
+
"docs": {
|
|
960
|
+
"tags": [],
|
|
961
|
+
"text": "Regex pattern the value must match (string form)."
|
|
962
|
+
},
|
|
963
|
+
"getter": false,
|
|
964
|
+
"setter": false,
|
|
965
|
+
"reflect": false
|
|
966
|
+
},
|
|
967
|
+
"step": {
|
|
968
|
+
"type": "number",
|
|
969
|
+
"attribute": "step",
|
|
970
|
+
"mutable": false,
|
|
971
|
+
"complexType": {
|
|
972
|
+
"original": "number",
|
|
973
|
+
"resolved": "number",
|
|
974
|
+
"references": {}
|
|
975
|
+
},
|
|
976
|
+
"required": false,
|
|
977
|
+
"optional": true,
|
|
978
|
+
"docs": {
|
|
979
|
+
"tags": [],
|
|
980
|
+
"text": "Step interval for numeric/date input types."
|
|
981
|
+
},
|
|
982
|
+
"getter": false,
|
|
983
|
+
"setter": false,
|
|
984
|
+
"reflect": false
|
|
985
|
+
},
|
|
986
|
+
"valueMissingMessage": {
|
|
987
|
+
"type": "string",
|
|
988
|
+
"attribute": "value-missing-message",
|
|
989
|
+
"mutable": false,
|
|
990
|
+
"complexType": {
|
|
991
|
+
"original": "string",
|
|
992
|
+
"resolved": "string",
|
|
993
|
+
"references": {}
|
|
994
|
+
},
|
|
995
|
+
"required": false,
|
|
996
|
+
"optional": true,
|
|
997
|
+
"docs": {
|
|
998
|
+
"tags": [],
|
|
999
|
+
"text": "Custom message for `valueMissing`."
|
|
1000
|
+
},
|
|
1001
|
+
"getter": false,
|
|
1002
|
+
"setter": false,
|
|
1003
|
+
"reflect": false
|
|
1004
|
+
},
|
|
1005
|
+
"typeMismatchMessage": {
|
|
1006
|
+
"type": "string",
|
|
1007
|
+
"attribute": "type-mismatch-message",
|
|
1008
|
+
"mutable": false,
|
|
1009
|
+
"complexType": {
|
|
1010
|
+
"original": "string",
|
|
1011
|
+
"resolved": "string",
|
|
1012
|
+
"references": {}
|
|
1013
|
+
},
|
|
1014
|
+
"required": false,
|
|
1015
|
+
"optional": true,
|
|
1016
|
+
"docs": {
|
|
1017
|
+
"tags": [],
|
|
1018
|
+
"text": "Custom message for `typeMismatch`."
|
|
1019
|
+
},
|
|
1020
|
+
"getter": false,
|
|
1021
|
+
"setter": false,
|
|
1022
|
+
"reflect": false
|
|
1023
|
+
},
|
|
1024
|
+
"patternMismatchMessage": {
|
|
1025
|
+
"type": "string",
|
|
1026
|
+
"attribute": "pattern-mismatch-message",
|
|
1027
|
+
"mutable": false,
|
|
1028
|
+
"complexType": {
|
|
1029
|
+
"original": "string",
|
|
1030
|
+
"resolved": "string",
|
|
1031
|
+
"references": {}
|
|
1032
|
+
},
|
|
1033
|
+
"required": false,
|
|
1034
|
+
"optional": true,
|
|
1035
|
+
"docs": {
|
|
1036
|
+
"tags": [],
|
|
1037
|
+
"text": "Custom message for `patternMismatch`."
|
|
1038
|
+
},
|
|
1039
|
+
"getter": false,
|
|
1040
|
+
"setter": false,
|
|
1041
|
+
"reflect": false
|
|
1042
|
+
},
|
|
1043
|
+
"tooLongMessage": {
|
|
1044
|
+
"type": "string",
|
|
1045
|
+
"attribute": "too-long-message",
|
|
1046
|
+
"mutable": false,
|
|
1047
|
+
"complexType": {
|
|
1048
|
+
"original": "string",
|
|
1049
|
+
"resolved": "string",
|
|
1050
|
+
"references": {}
|
|
1051
|
+
},
|
|
1052
|
+
"required": false,
|
|
1053
|
+
"optional": true,
|
|
1054
|
+
"docs": {
|
|
1055
|
+
"tags": [],
|
|
1056
|
+
"text": "Custom message for `tooLong`."
|
|
1057
|
+
},
|
|
1058
|
+
"getter": false,
|
|
1059
|
+
"setter": false,
|
|
1060
|
+
"reflect": false
|
|
1061
|
+
},
|
|
1062
|
+
"tooShortMessage": {
|
|
1063
|
+
"type": "string",
|
|
1064
|
+
"attribute": "too-short-message",
|
|
1065
|
+
"mutable": false,
|
|
1066
|
+
"complexType": {
|
|
1067
|
+
"original": "string",
|
|
1068
|
+
"resolved": "string",
|
|
1069
|
+
"references": {}
|
|
1070
|
+
},
|
|
1071
|
+
"required": false,
|
|
1072
|
+
"optional": true,
|
|
1073
|
+
"docs": {
|
|
1074
|
+
"tags": [],
|
|
1075
|
+
"text": "Custom message for `tooShort`."
|
|
1076
|
+
},
|
|
1077
|
+
"getter": false,
|
|
1078
|
+
"setter": false,
|
|
1079
|
+
"reflect": false
|
|
1080
|
+
},
|
|
1081
|
+
"rangeOverflowMessage": {
|
|
1082
|
+
"type": "string",
|
|
1083
|
+
"attribute": "range-overflow-message",
|
|
1084
|
+
"mutable": false,
|
|
1085
|
+
"complexType": {
|
|
1086
|
+
"original": "string",
|
|
1087
|
+
"resolved": "string",
|
|
1088
|
+
"references": {}
|
|
1089
|
+
},
|
|
1090
|
+
"required": false,
|
|
1091
|
+
"optional": true,
|
|
1092
|
+
"docs": {
|
|
1093
|
+
"tags": [],
|
|
1094
|
+
"text": "Custom message for `rangeOverflow`."
|
|
1095
|
+
},
|
|
1096
|
+
"getter": false,
|
|
1097
|
+
"setter": false,
|
|
1098
|
+
"reflect": false
|
|
1099
|
+
},
|
|
1100
|
+
"rangeUnderflowMessage": {
|
|
1101
|
+
"type": "string",
|
|
1102
|
+
"attribute": "range-underflow-message",
|
|
1103
|
+
"mutable": false,
|
|
1104
|
+
"complexType": {
|
|
1105
|
+
"original": "string",
|
|
1106
|
+
"resolved": "string",
|
|
1107
|
+
"references": {}
|
|
1108
|
+
},
|
|
1109
|
+
"required": false,
|
|
1110
|
+
"optional": true,
|
|
1111
|
+
"docs": {
|
|
1112
|
+
"tags": [],
|
|
1113
|
+
"text": "Custom message for `rangeUnderflow`."
|
|
1114
|
+
},
|
|
1115
|
+
"getter": false,
|
|
1116
|
+
"setter": false,
|
|
1117
|
+
"reflect": false
|
|
1118
|
+
},
|
|
1119
|
+
"stepMismatchMessage": {
|
|
1120
|
+
"type": "string",
|
|
1121
|
+
"attribute": "step-mismatch-message",
|
|
1122
|
+
"mutable": false,
|
|
1123
|
+
"complexType": {
|
|
1124
|
+
"original": "string",
|
|
1125
|
+
"resolved": "string",
|
|
1126
|
+
"references": {}
|
|
1127
|
+
},
|
|
1128
|
+
"required": false,
|
|
1129
|
+
"optional": true,
|
|
1130
|
+
"docs": {
|
|
1131
|
+
"tags": [],
|
|
1132
|
+
"text": "Custom message for `stepMismatch`."
|
|
1133
|
+
},
|
|
1134
|
+
"getter": false,
|
|
1135
|
+
"setter": false,
|
|
1136
|
+
"reflect": false
|
|
1137
|
+
},
|
|
1138
|
+
"badInputMessage": {
|
|
1139
|
+
"type": "string",
|
|
1140
|
+
"attribute": "bad-input-message",
|
|
1141
|
+
"mutable": false,
|
|
1142
|
+
"complexType": {
|
|
1143
|
+
"original": "string",
|
|
1144
|
+
"resolved": "string",
|
|
1145
|
+
"references": {}
|
|
1146
|
+
},
|
|
1147
|
+
"required": false,
|
|
1148
|
+
"optional": true,
|
|
1149
|
+
"docs": {
|
|
1150
|
+
"tags": [],
|
|
1151
|
+
"text": "Custom message for `badInput` (conversion / parsing failure)."
|
|
1152
|
+
},
|
|
1153
|
+
"getter": false,
|
|
1154
|
+
"setter": false,
|
|
1155
|
+
"reflect": false
|
|
1156
|
+
},
|
|
1157
|
+
"customErrorMessage": {
|
|
1158
|
+
"type": "string",
|
|
1159
|
+
"attribute": "custom-error-message",
|
|
1160
|
+
"mutable": false,
|
|
1161
|
+
"complexType": {
|
|
1162
|
+
"original": "string",
|
|
1163
|
+
"resolved": "string",
|
|
1164
|
+
"references": {}
|
|
1165
|
+
},
|
|
1166
|
+
"required": false,
|
|
1167
|
+
"optional": true,
|
|
1168
|
+
"docs": {
|
|
1169
|
+
"tags": [],
|
|
1170
|
+
"text": "Custom message for `customError` (applies when set via `setCustomValidity()` logic internally)."
|
|
1171
|
+
},
|
|
1172
|
+
"getter": false,
|
|
1173
|
+
"setter": false,
|
|
1174
|
+
"reflect": false
|
|
1175
|
+
},
|
|
1176
|
+
"autocomplete": {
|
|
1177
|
+
"type": "string",
|
|
1178
|
+
"attribute": "autocomplete",
|
|
1179
|
+
"mutable": false,
|
|
1180
|
+
"complexType": {
|
|
1181
|
+
"original": "InputAutocomplete",
|
|
1182
|
+
"resolved": "\"url\" | AutoFill | \"bday\" | \"sex\" | \"photo\" | \"language\"",
|
|
1183
|
+
"references": {
|
|
1184
|
+
"InputAutocomplete": {
|
|
1185
|
+
"location": "import",
|
|
1186
|
+
"path": "./exports",
|
|
1187
|
+
"id": "src/components/input/exports.ts::InputAutocomplete"
|
|
1188
|
+
}
|
|
1189
|
+
}
|
|
1190
|
+
},
|
|
1191
|
+
"required": false,
|
|
1192
|
+
"optional": true,
|
|
1193
|
+
"docs": {
|
|
1194
|
+
"tags": [],
|
|
1195
|
+
"text": "Native `autocomplete` hint for browsers / password managers."
|
|
1196
|
+
},
|
|
1197
|
+
"getter": false,
|
|
1198
|
+
"setter": false,
|
|
1199
|
+
"reflect": false
|
|
1200
|
+
},
|
|
1201
|
+
"enterkeyhint": {
|
|
1202
|
+
"type": "string",
|
|
1203
|
+
"attribute": "enterkeyhint",
|
|
1204
|
+
"mutable": false,
|
|
1205
|
+
"complexType": {
|
|
1206
|
+
"original": "EnterKeyHint",
|
|
1207
|
+
"resolved": "\"done\" | \"enter\" | \"go\" | \"next\" | \"previous\" | \"search\" | \"send\"",
|
|
1208
|
+
"references": {
|
|
1209
|
+
"EnterKeyHint": {
|
|
1210
|
+
"location": "import",
|
|
1211
|
+
"path": "./exports",
|
|
1212
|
+
"id": "src/components/input/exports.ts::EnterKeyHint"
|
|
1213
|
+
}
|
|
1214
|
+
}
|
|
1215
|
+
},
|
|
1216
|
+
"required": false,
|
|
1217
|
+
"optional": true,
|
|
1218
|
+
"docs": {
|
|
1219
|
+
"tags": [],
|
|
1220
|
+
"text": "Hint for the action label/icon on the virtual keyboard's enter key.\nUse cases:\n- `enter`: Default, generic newline/submit action\n- `done`: Finishes current input session (e.g., last field in a form)\n- `go`: Navigates to URL input target (e.g., URL bar)\n- `next`: Advances to next input field in a sequence\n- `previous`: Goes back to previous input field\n- `search`: Submits a search query\n- `send`: Sends a message (e.g., chat, email)"
|
|
1221
|
+
},
|
|
1222
|
+
"getter": false,
|
|
1223
|
+
"setter": false,
|
|
1224
|
+
"reflect": false
|
|
1225
|
+
},
|
|
1226
|
+
"spellcheck": {
|
|
1227
|
+
"type": "boolean",
|
|
1228
|
+
"attribute": "spellcheck",
|
|
1229
|
+
"mutable": true,
|
|
1230
|
+
"complexType": {
|
|
1231
|
+
"original": "boolean",
|
|
1232
|
+
"resolved": "boolean",
|
|
1233
|
+
"references": {}
|
|
1234
|
+
},
|
|
1235
|
+
"required": false,
|
|
1236
|
+
"optional": true,
|
|
1237
|
+
"docs": {
|
|
1238
|
+
"tags": [],
|
|
1239
|
+
"text": "Controls browser spell-checking for text input.\nWhen true, enables spell-checking; when false, disables it.\nBrowser default behavior applies when not specified."
|
|
1240
|
+
},
|
|
1241
|
+
"getter": false,
|
|
1242
|
+
"setter": false,
|
|
1243
|
+
"reflect": true
|
|
1244
|
+
},
|
|
1245
|
+
"autocapitalize": {
|
|
1246
|
+
"type": "string",
|
|
1247
|
+
"attribute": "autocapitalize",
|
|
1248
|
+
"mutable": false,
|
|
1249
|
+
"complexType": {
|
|
1250
|
+
"original": "AutocapitalizeType",
|
|
1251
|
+
"resolved": "\"characters\" | \"none\" | \"off\" | \"on\" | \"sentences\" | \"words\"",
|
|
1252
|
+
"references": {
|
|
1253
|
+
"AutocapitalizeType": {
|
|
1254
|
+
"location": "import",
|
|
1255
|
+
"path": "./exports",
|
|
1256
|
+
"id": "src/components/input/exports.ts::AutocapitalizeType"
|
|
1257
|
+
}
|
|
1258
|
+
}
|
|
1259
|
+
},
|
|
1260
|
+
"required": false,
|
|
1261
|
+
"optional": true,
|
|
1262
|
+
"docs": {
|
|
1263
|
+
"tags": [],
|
|
1264
|
+
"text": "Controls automatic capitalization of text input on mobile devices.\n- `off` or `none`: No automatic capitalization\n- `on` or `sentences`: Capitalize first letter of each sentence (default for most text inputs)\n- `words`: Capitalize first letter of each word\n- `characters`: Capitalize all characters"
|
|
1265
|
+
},
|
|
1266
|
+
"getter": false,
|
|
1267
|
+
"setter": false,
|
|
1268
|
+
"reflect": false
|
|
1269
|
+
},
|
|
1270
|
+
"passwordrules": {
|
|
1271
|
+
"type": "string",
|
|
1272
|
+
"attribute": "passwordrules",
|
|
1273
|
+
"mutable": false,
|
|
1274
|
+
"complexType": {
|
|
1275
|
+
"original": "string",
|
|
1276
|
+
"resolved": "string",
|
|
1277
|
+
"references": {}
|
|
1278
|
+
},
|
|
1279
|
+
"required": false,
|
|
1280
|
+
"optional": true,
|
|
1281
|
+
"docs": {
|
|
1282
|
+
"tags": [],
|
|
1283
|
+
"text": "Safari-specific password rules for strong password generation (password inputs only).\nFormat: \"minlength: X; required: lower; required: upper; required: digit; required: special;\"\nThis attribute is Safari-specific and will be ignored by other browsers.\nSee: https://developer.apple.com/documentation/security/password_autofill/customizing_password_autofill_rules"
|
|
1284
|
+
},
|
|
1285
|
+
"getter": false,
|
|
1286
|
+
"setter": false,
|
|
1287
|
+
"reflect": false
|
|
1288
|
+
},
|
|
1289
|
+
"autofocus": {
|
|
1290
|
+
"type": "boolean",
|
|
1291
|
+
"attribute": "autofocus",
|
|
1292
|
+
"mutable": false,
|
|
1293
|
+
"complexType": {
|
|
1294
|
+
"original": "boolean",
|
|
1295
|
+
"resolved": "boolean",
|
|
1296
|
+
"references": {}
|
|
1297
|
+
},
|
|
1298
|
+
"required": false,
|
|
1299
|
+
"optional": true,
|
|
1300
|
+
"docs": {
|
|
1301
|
+
"tags": [],
|
|
1302
|
+
"text": "Automatically focus the input when it is first rendered.\nMirrors native `autofocus` attribute behavior. Avoid using multiple times per page."
|
|
1303
|
+
},
|
|
1304
|
+
"getter": false,
|
|
1305
|
+
"setter": false,
|
|
1306
|
+
"reflect": true
|
|
1307
|
+
},
|
|
1308
|
+
"readonly": {
|
|
1309
|
+
"type": "boolean",
|
|
1310
|
+
"attribute": "readonly",
|
|
1311
|
+
"mutable": false,
|
|
1312
|
+
"complexType": {
|
|
1313
|
+
"original": "boolean",
|
|
1314
|
+
"resolved": "boolean",
|
|
1315
|
+
"references": {}
|
|
1316
|
+
},
|
|
1317
|
+
"required": false,
|
|
1318
|
+
"optional": true,
|
|
1319
|
+
"docs": {
|
|
1320
|
+
"tags": [],
|
|
1321
|
+
"text": "Read-only mode (mirrors native `readonly`): value cannot be changed by the user,\nbut the field can still receive focus, be selected, and be submitted with a form."
|
|
1322
|
+
},
|
|
1323
|
+
"getter": false,
|
|
1324
|
+
"setter": false,
|
|
1325
|
+
"reflect": true
|
|
1326
|
+
},
|
|
1327
|
+
"inputmode": {
|
|
1328
|
+
"type": "string",
|
|
1329
|
+
"attribute": "inputmode",
|
|
1330
|
+
"mutable": false,
|
|
1331
|
+
"complexType": {
|
|
1332
|
+
"original": "InputMode",
|
|
1333
|
+
"resolved": "\"decimal\" | \"email\" | \"none\" | \"numeric\" | \"search\" | \"tel\" | \"text\" | \"url\"",
|
|
1334
|
+
"references": {
|
|
1335
|
+
"InputMode": {
|
|
1336
|
+
"location": "import",
|
|
1337
|
+
"path": "./exports",
|
|
1338
|
+
"id": "src/components/input/exports.ts::InputMode"
|
|
1339
|
+
}
|
|
1340
|
+
}
|
|
1341
|
+
},
|
|
1342
|
+
"required": false,
|
|
1343
|
+
"optional": true,
|
|
1344
|
+
"docs": {
|
|
1345
|
+
"tags": [],
|
|
1346
|
+
"text": "Hint to the browser about which keyboard to display on mobile devices."
|
|
1347
|
+
},
|
|
1348
|
+
"getter": false,
|
|
1349
|
+
"setter": false,
|
|
1350
|
+
"reflect": false
|
|
1351
|
+
},
|
|
1352
|
+
"validityMarker": {
|
|
1353
|
+
"type": "boolean",
|
|
1354
|
+
"attribute": "validity-marker",
|
|
1355
|
+
"mutable": false,
|
|
1356
|
+
"complexType": {
|
|
1357
|
+
"original": "boolean",
|
|
1358
|
+
"resolved": "boolean",
|
|
1359
|
+
"references": {}
|
|
1360
|
+
},
|
|
1361
|
+
"required": false,
|
|
1362
|
+
"optional": false,
|
|
1363
|
+
"docs": {
|
|
1364
|
+
"tags": [],
|
|
1365
|
+
"text": "When `true` field renders valid/invalid marker within."
|
|
1366
|
+
},
|
|
1367
|
+
"getter": false,
|
|
1368
|
+
"setter": false,
|
|
1369
|
+
"reflect": true,
|
|
1370
|
+
"defaultValue": "true"
|
|
1371
|
+
}
|
|
1372
|
+
};
|
|
1373
|
+
}
|
|
1374
|
+
static get states() {
|
|
1375
|
+
return {
|
|
1376
|
+
"slottedOptions": {},
|
|
1377
|
+
"validityState": {},
|
|
1378
|
+
"validityMessage": {},
|
|
1379
|
+
"touched": {},
|
|
1380
|
+
"dirty": {}
|
|
1381
|
+
};
|
|
1382
|
+
}
|
|
1383
|
+
static get events() {
|
|
1384
|
+
return [{
|
|
1385
|
+
"method": "rValidate",
|
|
1386
|
+
"name": "rValidate",
|
|
1387
|
+
"bubbles": true,
|
|
1388
|
+
"cancelable": true,
|
|
1389
|
+
"composed": true,
|
|
1390
|
+
"docs": {
|
|
1391
|
+
"tags": [],
|
|
1392
|
+
"text": "Emitted after each validation attempt (native or triggered logic)."
|
|
1393
|
+
},
|
|
1394
|
+
"complexType": {
|
|
1395
|
+
"original": "{\n state: string,\n message: string\n }",
|
|
1396
|
+
"resolved": "{ state: string; message: string; }",
|
|
1397
|
+
"references": {}
|
|
1398
|
+
}
|
|
1399
|
+
}, {
|
|
1400
|
+
"method": "rInput",
|
|
1401
|
+
"name": "rInput",
|
|
1402
|
+
"bubbles": true,
|
|
1403
|
+
"cancelable": true,
|
|
1404
|
+
"composed": true,
|
|
1405
|
+
"docs": {
|
|
1406
|
+
"tags": [],
|
|
1407
|
+
"text": "Emitted on each user input (mirrors native `input` semantics)."
|
|
1408
|
+
},
|
|
1409
|
+
"complexType": {
|
|
1410
|
+
"original": "{\n element: HTMLRInputElement,\n value: any\n }",
|
|
1411
|
+
"resolved": "{ element: HTMLRInputElement; value: any; }",
|
|
1412
|
+
"references": {
|
|
1413
|
+
"HTMLRInputElement": {
|
|
1414
|
+
"location": "global",
|
|
1415
|
+
"id": "global::HTMLRInputElement"
|
|
1416
|
+
}
|
|
1417
|
+
}
|
|
1418
|
+
}
|
|
1419
|
+
}, {
|
|
1420
|
+
"method": "rBlur",
|
|
1421
|
+
"name": "rBlur",
|
|
1422
|
+
"bubbles": true,
|
|
1423
|
+
"cancelable": true,
|
|
1424
|
+
"composed": true,
|
|
1425
|
+
"docs": {
|
|
1426
|
+
"tags": [],
|
|
1427
|
+
"text": "Emitted when the input loses focus."
|
|
1428
|
+
},
|
|
1429
|
+
"complexType": {
|
|
1430
|
+
"original": "any",
|
|
1431
|
+
"resolved": "any",
|
|
1432
|
+
"references": {}
|
|
1433
|
+
}
|
|
1434
|
+
}, {
|
|
1435
|
+
"method": "rFocus",
|
|
1436
|
+
"name": "rFocus",
|
|
1437
|
+
"bubbles": true,
|
|
1438
|
+
"cancelable": true,
|
|
1439
|
+
"composed": true,
|
|
1440
|
+
"docs": {
|
|
1441
|
+
"tags": [],
|
|
1442
|
+
"text": "Emitted when the input receives focus."
|
|
1443
|
+
},
|
|
1444
|
+
"complexType": {
|
|
1445
|
+
"original": "any",
|
|
1446
|
+
"resolved": "any",
|
|
1447
|
+
"references": {}
|
|
1448
|
+
}
|
|
1449
|
+
}, {
|
|
1450
|
+
"method": "rChange",
|
|
1451
|
+
"name": "rChange",
|
|
1452
|
+
"bubbles": true,
|
|
1453
|
+
"cancelable": true,
|
|
1454
|
+
"composed": true,
|
|
1455
|
+
"docs": {
|
|
1456
|
+
"tags": [],
|
|
1457
|
+
"text": "Emitted when the committed value changes (mirrors native `change` semantics)."
|
|
1458
|
+
},
|
|
1459
|
+
"complexType": {
|
|
1460
|
+
"original": "{\n element: HTMLRInputElement,\n value: any\n }",
|
|
1461
|
+
"resolved": "{ element: HTMLRInputElement; value: any; }",
|
|
1462
|
+
"references": {
|
|
1463
|
+
"HTMLRInputElement": {
|
|
1464
|
+
"location": "global",
|
|
1465
|
+
"id": "global::HTMLRInputElement"
|
|
1466
|
+
}
|
|
1467
|
+
}
|
|
1468
|
+
}
|
|
1469
|
+
}, {
|
|
1470
|
+
"method": "rReset",
|
|
1471
|
+
"name": "rReset",
|
|
1472
|
+
"bubbles": true,
|
|
1473
|
+
"cancelable": true,
|
|
1474
|
+
"composed": true,
|
|
1475
|
+
"docs": {
|
|
1476
|
+
"tags": [],
|
|
1477
|
+
"text": "Emitted when a parent form is reset and the field restores its initial value."
|
|
1478
|
+
},
|
|
1479
|
+
"complexType": {
|
|
1480
|
+
"original": "{\n element: HTMLRInputElement,\n value: any\n }",
|
|
1481
|
+
"resolved": "{ element: HTMLRInputElement; value: any; }",
|
|
1482
|
+
"references": {
|
|
1483
|
+
"HTMLRInputElement": {
|
|
1484
|
+
"location": "global",
|
|
1485
|
+
"id": "global::HTMLRInputElement"
|
|
1486
|
+
}
|
|
1487
|
+
}
|
|
1488
|
+
}
|
|
1489
|
+
}, {
|
|
1490
|
+
"method": "rBeforeInput",
|
|
1491
|
+
"name": "rBeforeInput",
|
|
1492
|
+
"bubbles": true,
|
|
1493
|
+
"cancelable": true,
|
|
1494
|
+
"composed": true,
|
|
1495
|
+
"docs": {
|
|
1496
|
+
"tags": [],
|
|
1497
|
+
"text": "Emitted when the input is about to be modified (mirrors native `beforeinput` semantics).\nUse for intercepting and preventing input before it occurs."
|
|
1498
|
+
},
|
|
1499
|
+
"complexType": {
|
|
1500
|
+
"original": "InputEvent",
|
|
1501
|
+
"resolved": "InputEvent",
|
|
1502
|
+
"references": {
|
|
1503
|
+
"InputEvent": {
|
|
1504
|
+
"location": "global",
|
|
1505
|
+
"id": "global::InputEvent"
|
|
1506
|
+
}
|
|
1507
|
+
}
|
|
1508
|
+
}
|
|
1509
|
+
}, {
|
|
1510
|
+
"method": "rInvalid",
|
|
1511
|
+
"name": "rInvalid",
|
|
1512
|
+
"bubbles": true,
|
|
1513
|
+
"cancelable": true,
|
|
1514
|
+
"composed": true,
|
|
1515
|
+
"docs": {
|
|
1516
|
+
"tags": [],
|
|
1517
|
+
"text": "Emitted when the input fails validation (mirrors native `invalid` semantics)."
|
|
1518
|
+
},
|
|
1519
|
+
"complexType": {
|
|
1520
|
+
"original": "Event",
|
|
1521
|
+
"resolved": "Event",
|
|
1522
|
+
"references": {
|
|
1523
|
+
"Event": {
|
|
1524
|
+
"location": "import",
|
|
1525
|
+
"path": "@stencil/core",
|
|
1526
|
+
"id": "../../node_modules/@stencil/core/internal/stencil-core/index.d.ts::Event"
|
|
1527
|
+
}
|
|
1528
|
+
}
|
|
1529
|
+
}
|
|
1530
|
+
}, {
|
|
1531
|
+
"method": "rKeyDown",
|
|
1532
|
+
"name": "rKeyDown",
|
|
1533
|
+
"bubbles": true,
|
|
1534
|
+
"cancelable": true,
|
|
1535
|
+
"composed": true,
|
|
1536
|
+
"docs": {
|
|
1537
|
+
"tags": [],
|
|
1538
|
+
"text": "Emitted when a key is pressed down (mirrors native `keydown` semantics)."
|
|
1539
|
+
},
|
|
1540
|
+
"complexType": {
|
|
1541
|
+
"original": "KeyboardEvent",
|
|
1542
|
+
"resolved": "KeyboardEvent",
|
|
1543
|
+
"references": {
|
|
1544
|
+
"KeyboardEvent": {
|
|
1545
|
+
"location": "global",
|
|
1546
|
+
"id": "global::KeyboardEvent"
|
|
1547
|
+
}
|
|
1548
|
+
}
|
|
1549
|
+
}
|
|
1550
|
+
}, {
|
|
1551
|
+
"method": "rKeyUp",
|
|
1552
|
+
"name": "rKeyUp",
|
|
1553
|
+
"bubbles": true,
|
|
1554
|
+
"cancelable": true,
|
|
1555
|
+
"composed": true,
|
|
1556
|
+
"docs": {
|
|
1557
|
+
"tags": [],
|
|
1558
|
+
"text": "Emitted when a key is released (mirrors native `keyup` semantics)."
|
|
1559
|
+
},
|
|
1560
|
+
"complexType": {
|
|
1561
|
+
"original": "KeyboardEvent",
|
|
1562
|
+
"resolved": "KeyboardEvent",
|
|
1563
|
+
"references": {
|
|
1564
|
+
"KeyboardEvent": {
|
|
1565
|
+
"location": "global",
|
|
1566
|
+
"id": "global::KeyboardEvent"
|
|
1567
|
+
}
|
|
1568
|
+
}
|
|
1569
|
+
}
|
|
1570
|
+
}, {
|
|
1571
|
+
"method": "rSelect",
|
|
1572
|
+
"name": "rSelect",
|
|
1573
|
+
"bubbles": true,
|
|
1574
|
+
"cancelable": true,
|
|
1575
|
+
"composed": true,
|
|
1576
|
+
"docs": {
|
|
1577
|
+
"tags": [],
|
|
1578
|
+
"text": "Emitted when text is selected (mirrors native `select` semantics)."
|
|
1579
|
+
},
|
|
1580
|
+
"complexType": {
|
|
1581
|
+
"original": "Event",
|
|
1582
|
+
"resolved": "Event",
|
|
1583
|
+
"references": {
|
|
1584
|
+
"Event": {
|
|
1585
|
+
"location": "import",
|
|
1586
|
+
"path": "@stencil/core",
|
|
1587
|
+
"id": "../../node_modules/@stencil/core/internal/stencil-core/index.d.ts::Event"
|
|
1588
|
+
}
|
|
1589
|
+
}
|
|
1590
|
+
}
|
|
1591
|
+
}];
|
|
1592
|
+
}
|
|
1593
|
+
static get methods() {
|
|
1594
|
+
return {
|
|
1595
|
+
"setFocus": {
|
|
1596
|
+
"complexType": {
|
|
1597
|
+
"signature": "() => Promise<void>",
|
|
1598
|
+
"parameters": [],
|
|
1599
|
+
"references": {
|
|
1600
|
+
"Promise": {
|
|
1601
|
+
"location": "global",
|
|
1602
|
+
"id": "global::Promise"
|
|
1603
|
+
}
|
|
1604
|
+
},
|
|
1605
|
+
"return": "Promise<void>"
|
|
1606
|
+
},
|
|
1607
|
+
"docs": {
|
|
1608
|
+
"text": "Programmatically focus the native input element.",
|
|
1609
|
+
"tags": []
|
|
1610
|
+
}
|
|
1611
|
+
},
|
|
1612
|
+
"setBlur": {
|
|
1613
|
+
"complexType": {
|
|
1614
|
+
"signature": "() => Promise<void>",
|
|
1615
|
+
"parameters": [],
|
|
1616
|
+
"references": {
|
|
1617
|
+
"Promise": {
|
|
1618
|
+
"location": "global",
|
|
1619
|
+
"id": "global::Promise"
|
|
1620
|
+
}
|
|
1621
|
+
},
|
|
1622
|
+
"return": "Promise<void>"
|
|
1623
|
+
},
|
|
1624
|
+
"docs": {
|
|
1625
|
+
"text": "Programmatically remove focus from the native input.",
|
|
1626
|
+
"tags": []
|
|
1627
|
+
}
|
|
1628
|
+
},
|
|
1629
|
+
"select": {
|
|
1630
|
+
"complexType": {
|
|
1631
|
+
"signature": "() => Promise<void>",
|
|
1632
|
+
"parameters": [],
|
|
1633
|
+
"references": {
|
|
1634
|
+
"Promise": {
|
|
1635
|
+
"location": "global",
|
|
1636
|
+
"id": "global::Promise"
|
|
1637
|
+
}
|
|
1638
|
+
},
|
|
1639
|
+
"return": "Promise<void>"
|
|
1640
|
+
},
|
|
1641
|
+
"docs": {
|
|
1642
|
+
"text": "Select (highlight) the entire current input value.",
|
|
1643
|
+
"tags": []
|
|
1644
|
+
}
|
|
1645
|
+
},
|
|
1646
|
+
"getSelectionStart": {
|
|
1647
|
+
"complexType": {
|
|
1648
|
+
"signature": "() => Promise<number | null>",
|
|
1649
|
+
"parameters": [],
|
|
1650
|
+
"references": {
|
|
1651
|
+
"Promise": {
|
|
1652
|
+
"location": "global",
|
|
1653
|
+
"id": "global::Promise"
|
|
1654
|
+
}
|
|
1655
|
+
},
|
|
1656
|
+
"return": "Promise<number>"
|
|
1657
|
+
},
|
|
1658
|
+
"docs": {
|
|
1659
|
+
"text": "Get the start index of the current text selection (or null if unavailable).",
|
|
1660
|
+
"tags": []
|
|
1661
|
+
}
|
|
1662
|
+
},
|
|
1663
|
+
"getSelectionEnd": {
|
|
1664
|
+
"complexType": {
|
|
1665
|
+
"signature": "() => Promise<number | null>",
|
|
1666
|
+
"parameters": [],
|
|
1667
|
+
"references": {
|
|
1668
|
+
"Promise": {
|
|
1669
|
+
"location": "global",
|
|
1670
|
+
"id": "global::Promise"
|
|
1671
|
+
}
|
|
1672
|
+
},
|
|
1673
|
+
"return": "Promise<number>"
|
|
1674
|
+
},
|
|
1675
|
+
"docs": {
|
|
1676
|
+
"text": "Get the end index of the current text selection (or null if unavailable).",
|
|
1677
|
+
"tags": []
|
|
1678
|
+
}
|
|
1679
|
+
},
|
|
1680
|
+
"setSelectionRange": {
|
|
1681
|
+
"complexType": {
|
|
1682
|
+
"signature": "(start: number, end: number, direction?: \"forward\" | \"backward\" | \"none\") => Promise<void>",
|
|
1683
|
+
"parameters": [{
|
|
1684
|
+
"name": "start",
|
|
1685
|
+
"type": "number",
|
|
1686
|
+
"docs": "Start index (inclusive)"
|
|
1687
|
+
}, {
|
|
1688
|
+
"name": "end",
|
|
1689
|
+
"type": "number",
|
|
1690
|
+
"docs": "End index (exclusive)"
|
|
1691
|
+
}, {
|
|
1692
|
+
"name": "direction",
|
|
1693
|
+
"type": "\"none\" | \"forward\" | \"backward\"",
|
|
1694
|
+
"docs": "Selection direction (browser hint)"
|
|
1695
|
+
}],
|
|
1696
|
+
"references": {
|
|
1697
|
+
"Promise": {
|
|
1698
|
+
"location": "global",
|
|
1699
|
+
"id": "global::Promise"
|
|
1700
|
+
}
|
|
1701
|
+
},
|
|
1702
|
+
"return": "Promise<void>"
|
|
1703
|
+
},
|
|
1704
|
+
"docs": {
|
|
1705
|
+
"text": "Set a selection (or caret) range within the value.",
|
|
1706
|
+
"tags": [{
|
|
1707
|
+
"name": "param",
|
|
1708
|
+
"text": "start Start index (inclusive)"
|
|
1709
|
+
}, {
|
|
1710
|
+
"name": "param",
|
|
1711
|
+
"text": "end End index (exclusive)"
|
|
1712
|
+
}, {
|
|
1713
|
+
"name": "param",
|
|
1714
|
+
"text": "direction Selection direction (browser hint)"
|
|
1715
|
+
}]
|
|
1716
|
+
}
|
|
1717
|
+
},
|
|
1718
|
+
"getValue": {
|
|
1719
|
+
"complexType": {
|
|
1720
|
+
"signature": "() => Promise<string>",
|
|
1721
|
+
"parameters": [],
|
|
1722
|
+
"references": {
|
|
1723
|
+
"Promise": {
|
|
1724
|
+
"location": "global",
|
|
1725
|
+
"id": "global::Promise"
|
|
1726
|
+
}
|
|
1727
|
+
},
|
|
1728
|
+
"return": "Promise<string>"
|
|
1729
|
+
},
|
|
1730
|
+
"docs": {
|
|
1731
|
+
"text": "Retrieve the current value (returns empty string if unset).",
|
|
1732
|
+
"tags": []
|
|
1733
|
+
}
|
|
1734
|
+
},
|
|
1735
|
+
"setValue": {
|
|
1736
|
+
"complexType": {
|
|
1737
|
+
"signature": "(value: string) => Promise<void>",
|
|
1738
|
+
"parameters": [{
|
|
1739
|
+
"name": "value",
|
|
1740
|
+
"type": "string",
|
|
1741
|
+
"docs": ""
|
|
1742
|
+
}],
|
|
1743
|
+
"references": {
|
|
1744
|
+
"Promise": {
|
|
1745
|
+
"location": "global",
|
|
1746
|
+
"id": "global::Promise"
|
|
1747
|
+
}
|
|
1748
|
+
},
|
|
1749
|
+
"return": "Promise<void>"
|
|
1750
|
+
},
|
|
1751
|
+
"docs": {
|
|
1752
|
+
"text": "Set the current value programmatically (does not fire native input/change automatically).",
|
|
1753
|
+
"tags": []
|
|
1754
|
+
}
|
|
1755
|
+
},
|
|
1756
|
+
"setCustomValidity": {
|
|
1757
|
+
"complexType": {
|
|
1758
|
+
"signature": "(message: string) => Promise<void>",
|
|
1759
|
+
"parameters": [{
|
|
1760
|
+
"name": "message",
|
|
1761
|
+
"type": "string",
|
|
1762
|
+
"docs": ""
|
|
1763
|
+
}],
|
|
1764
|
+
"references": {
|
|
1765
|
+
"Promise": {
|
|
1766
|
+
"location": "global",
|
|
1767
|
+
"id": "global::Promise"
|
|
1768
|
+
}
|
|
1769
|
+
},
|
|
1770
|
+
"return": "Promise<void>"
|
|
1771
|
+
},
|
|
1772
|
+
"docs": {
|
|
1773
|
+
"text": "Validates an element, displays provided message in case value is invalid.",
|
|
1774
|
+
"tags": []
|
|
1775
|
+
}
|
|
1776
|
+
},
|
|
1777
|
+
"checkValidity": {
|
|
1778
|
+
"complexType": {
|
|
1779
|
+
"signature": "() => Promise<boolean>",
|
|
1780
|
+
"parameters": [],
|
|
1781
|
+
"references": {
|
|
1782
|
+
"Promise": {
|
|
1783
|
+
"location": "global",
|
|
1784
|
+
"id": "global::Promise"
|
|
1785
|
+
}
|
|
1786
|
+
},
|
|
1787
|
+
"return": "Promise<boolean>"
|
|
1788
|
+
},
|
|
1789
|
+
"docs": {
|
|
1790
|
+
"text": "Validates the input without triggering UI and returns a boolean indicating its validity.",
|
|
1791
|
+
"tags": [{
|
|
1792
|
+
"name": "returns",
|
|
1793
|
+
"text": "A boolean indicating whether the input is valid."
|
|
1794
|
+
}]
|
|
1795
|
+
}
|
|
1796
|
+
},
|
|
1797
|
+
"isTouched": {
|
|
1798
|
+
"complexType": {
|
|
1799
|
+
"signature": "() => Promise<boolean>",
|
|
1800
|
+
"parameters": [],
|
|
1801
|
+
"references": {
|
|
1802
|
+
"Promise": {
|
|
1803
|
+
"location": "global",
|
|
1804
|
+
"id": "global::Promise"
|
|
1805
|
+
}
|
|
1806
|
+
},
|
|
1807
|
+
"return": "Promise<boolean>"
|
|
1808
|
+
},
|
|
1809
|
+
"docs": {
|
|
1810
|
+
"text": "Gets the touched state (whether user has interacted with the input)",
|
|
1811
|
+
"tags": []
|
|
1812
|
+
}
|
|
1813
|
+
},
|
|
1814
|
+
"isDirty": {
|
|
1815
|
+
"complexType": {
|
|
1816
|
+
"signature": "() => Promise<boolean>",
|
|
1817
|
+
"parameters": [],
|
|
1818
|
+
"references": {
|
|
1819
|
+
"Promise": {
|
|
1820
|
+
"location": "global",
|
|
1821
|
+
"id": "global::Promise"
|
|
1822
|
+
}
|
|
1823
|
+
},
|
|
1824
|
+
"return": "Promise<boolean>"
|
|
1825
|
+
},
|
|
1826
|
+
"docs": {
|
|
1827
|
+
"text": "Gets the dirty state (whether value has been changed by user)",
|
|
1828
|
+
"tags": []
|
|
1829
|
+
}
|
|
1830
|
+
},
|
|
1831
|
+
"markAsPristine": {
|
|
1832
|
+
"complexType": {
|
|
1833
|
+
"signature": "() => Promise<void>",
|
|
1834
|
+
"parameters": [],
|
|
1835
|
+
"references": {
|
|
1836
|
+
"Promise": {
|
|
1837
|
+
"location": "global",
|
|
1838
|
+
"id": "global::Promise"
|
|
1839
|
+
}
|
|
1840
|
+
},
|
|
1841
|
+
"return": "Promise<void>"
|
|
1842
|
+
},
|
|
1843
|
+
"docs": {
|
|
1844
|
+
"text": "Resets touched and dirty states to pristine (untouched/clean)",
|
|
1845
|
+
"tags": []
|
|
1846
|
+
}
|
|
1847
|
+
}
|
|
1848
|
+
};
|
|
1849
|
+
}
|
|
1850
|
+
static get elementRef() { return "host"; }
|
|
1851
|
+
static get watchers() {
|
|
1852
|
+
return [{
|
|
1853
|
+
"propName": "value",
|
|
1854
|
+
"methodName": "handleValueChange"
|
|
1855
|
+
}, {
|
|
1856
|
+
"propName": "type",
|
|
1857
|
+
"methodName": "handleTypeChange"
|
|
1858
|
+
}];
|
|
1859
|
+
}
|
|
1860
|
+
}
|
|
1861
|
+
RInput.autofocusHandled = false;
|