@roadtrip/components 3.32.0 → 3.32.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{index-aadb3ac9.js → index-2a80bffb.js} +58 -22
- package/dist/cjs/index-2a80bffb.js.map +1 -0
- package/dist/cjs/index.cjs.js +4 -4
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/road-accordion.cjs.entry.js +1 -1
- package/dist/cjs/road-alert.cjs.entry.js +1 -1
- package/dist/cjs/road-area-code.cjs.entry.js +1 -1
- package/dist/cjs/road-asset.cjs.entry.js +2 -2
- package/dist/cjs/road-autocomplete.cjs.entry.js +1 -1
- package/dist/cjs/road-avatar.cjs.entry.js +1 -1
- package/dist/cjs/road-badge_14.cjs.entry.js +6 -6
- package/dist/cjs/road-badge_14.cjs.entry.js.map +1 -1
- package/dist/cjs/road-banner.cjs.entry.js +1 -1
- package/dist/cjs/road-button-floating.cjs.entry.js +1 -1
- package/dist/cjs/road-card.cjs.entry.js +1 -1
- package/dist/cjs/road-carousel-item.cjs.entry.js +1 -1
- package/dist/cjs/road-carousel.cjs.entry.js +1 -1
- package/dist/cjs/road-checkbox.cjs.entry.js +1 -1
- package/dist/cjs/road-chip.cjs.entry.js +1 -1
- package/dist/cjs/road-collapse.cjs.entry.js +1 -1
- package/dist/cjs/road-content-card.cjs.entry.js +1 -1
- package/dist/cjs/road-dialog.cjs.entry.js +1 -1
- package/dist/cjs/road-dropdown.cjs.entry.js +1 -1
- package/dist/cjs/road-duration.cjs.entry.js +1 -1
- package/dist/cjs/road-flap.cjs.entry.js +1 -1
- package/dist/cjs/road-global-navigation-v2.cjs.entry.js +1 -1
- package/dist/cjs/road-global-navigation.cjs.entry.js +1 -1
- package/dist/cjs/road-illustration.cjs.entry.js +2 -2
- package/dist/cjs/road-img.cjs.entry.js +1 -1
- package/dist/cjs/road-modal.cjs.entry.js +1 -1
- package/dist/cjs/road-navbar-item-v2.cjs.entry.js +1 -1
- package/dist/cjs/road-navbar-item.cjs.entry.js +1 -1
- package/dist/cjs/road-navbar-v2.cjs.entry.js +1 -1
- package/dist/cjs/road-navbar.cjs.entry.js +1 -1
- package/dist/cjs/road-phone-number-input.cjs.entry.js +1 -1
- package/dist/cjs/road-plate-number.cjs.entry.js +1 -1
- package/dist/cjs/road-profil-dropdown.cjs.entry.js +1 -1
- package/dist/cjs/road-progress-indicator-horizontal.cjs.entry.js +1 -1
- package/dist/cjs/road-progress-indicator-vertical-item.cjs.entry.js +1 -1
- package/dist/cjs/road-progress-indicator-vertical.cjs.entry.js +1 -1
- package/dist/cjs/road-progress-tracker-item.cjs.entry.js +1 -1
- package/dist/cjs/road-progress-tracker.cjs.entry.js +1 -1
- package/dist/cjs/road-progress.cjs.entry.js +1 -1
- package/dist/cjs/road-radio-group.cjs.entry.js +1 -1
- package/dist/cjs/road-radio.cjs.entry.js +1 -1
- package/dist/cjs/road-range.cjs.entry.js +1 -1
- package/dist/cjs/road-rating.cjs.entry.js +1 -1
- package/dist/cjs/road-segmented-button-bar.cjs.entry.js +1 -1
- package/dist/cjs/road-segmented-button.cjs.entry.js +1 -1
- package/dist/cjs/road-segmented-buttons.cjs.entry.js +1 -1
- package/dist/cjs/road-select-filter.cjs.entry.js +1 -1
- package/dist/cjs/road-select.cjs.entry.js +1 -1
- package/dist/cjs/road-skeleton.cjs.entry.js +1 -1
- package/dist/cjs/road-spinner.cjs.entry.js +1 -1
- package/dist/cjs/road-switch.cjs.entry.js +1 -1
- package/dist/cjs/road-tab-bar.cjs.entry.js +1 -1
- package/dist/cjs/road-tab-button.cjs.entry.js +1 -1
- package/dist/cjs/road-tab.cjs.entry.js +1 -1
- package/dist/cjs/road-table.cjs.entry.js +1 -1
- package/dist/cjs/road-tabs.cjs.entry.js +1 -1
- package/dist/cjs/road-tag.cjs.entry.js +1 -1
- package/dist/cjs/road-text.cjs.entry.js +1 -1
- package/dist/cjs/road-textarea.cjs.entry.js +1 -1
- package/dist/cjs/road-toast.cjs.entry.js +1 -1
- package/dist/cjs/road-toggle.cjs.entry.js +1 -1
- package/dist/cjs/road-toolbar-title-page.cjs.entry.js +1 -1
- package/dist/cjs/road-toolbar-title.cjs.entry.js +1 -1
- package/dist/cjs/road-toolbar-v2.cjs.entry.js +1 -1
- package/dist/cjs/road-tooltip.cjs.entry.js +1 -1
- package/dist/cjs/roadtrip.cjs.js +3 -3
- package/dist/cjs/roadtrip.cjs.js.map +1 -1
- package/dist/cjs/{utils-25752683.js → utils-1301c43c.js} +2 -2
- package/dist/cjs/{utils-25752683.js.map → utils-1301c43c.js.map} +1 -1
- package/dist/cjs/{utils-11a0a9e6.js → utils-c951aa69.js} +2 -2
- package/dist/cjs/{utils-11a0a9e6.js.map → utils-c951aa69.js.map} +1 -1
- package/dist/cjs/{utils-e0016ab3.js → utils-f0685862.js} +2 -2
- package/dist/cjs/{utils-e0016ab3.js.map → utils-f0685862.js.map} +1 -1
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/accordion/accordion.stories.js +1 -1
- package/dist/collection/components/alert/alert.stories.js +1 -1
- package/dist/collection/components/asset/asset.stories.js +1 -1
- package/dist/collection/components/avatar/avatar.stories.js +1 -1
- package/dist/collection/components/badge/badge.stories.js +1 -1
- package/dist/collection/components/banner/banner.stories.js +1 -1
- package/dist/collection/components/button/button.stories.js +1 -1
- package/dist/collection/components/button-floating/button-floating.stories.js +1 -1
- package/dist/collection/components/card/card.stories.js +1 -1
- package/dist/collection/components/carousel/carousel.stories.js +1 -1
- package/dist/collection/components/checkbox/checkbox.stories.js +1 -1
- package/dist/collection/components/chip/chip.stories.js +1 -1
- package/dist/collection/components/collapse/collapse.stories.js +1 -1
- package/dist/collection/components/content-card/content-card.stories.js +1 -1
- package/dist/collection/components/counter/counter.stories.js +1 -1
- package/dist/collection/components/dialog/dialog.stories.js +1 -1
- package/dist/collection/components/drawer/drawer.stories.js +1 -1
- package/dist/collection/components/dropdown/dropdown.stories.js +1 -1
- package/dist/collection/components/duration/duration.stories.js +1 -1
- package/dist/collection/components/flap/flap.stories.js +1 -1
- package/dist/collection/components/global-navigation/global-navigation.stories.js +1 -1
- package/dist/collection/components/global-navigation-v2/global-navigation-v2.stories.js +1 -1
- package/dist/collection/components/icon/icon.stories.js +1 -1
- package/dist/collection/components/illustration/illustration.stories.js +1 -1
- package/dist/collection/components/input/input.js +6 -6
- package/dist/collection/components/input/input.js.map +1 -1
- package/dist/collection/components/input/input.stories.js +6 -1
- package/dist/collection/components/item/item.stories.js +1 -1
- package/dist/collection/components/list/list.stories.js +1 -1
- package/dist/collection/components/modal/modal.stories.js +1 -1
- package/dist/collection/components/navbar/navbar.stories.js +1 -1
- package/dist/collection/components/navbar-v2/navbar-v2.stories.js +1 -1
- package/dist/collection/components/phone-number-input/phone-number-input.stories.js +1 -1
- package/dist/collection/components/plate-number/plate-number.stories.js +1 -1
- package/dist/collection/components/profil-dropdown/profil-dropdown.stories.js +1 -1
- package/dist/collection/components/progress-indicator-horizontal/progress-indicator-horizontal.stories.js +1 -1
- package/dist/collection/components/progress-indicator-vertical/progress-indicator-vertical.stories.js +1 -1
- package/dist/collection/components/progress-tracker/progress-tracker.stories.js +1 -1
- package/dist/collection/components/radio/radio.stories.js +1 -1
- package/dist/collection/components/range/range.stories.js +1 -1
- package/dist/collection/components/rating/rating.stories.js +1 -1
- package/dist/collection/components/segmented-buttons/segmented-buttons.stories.js +1 -1
- package/dist/collection/components/select/select.stories.js +1 -1
- package/dist/collection/components/select-filter/select-filter.stories.js +1 -1
- package/dist/collection/components/spinner/spinner.stories.js +1 -1
- package/dist/collection/components/tag/tag.stories.js +1 -1
- package/dist/collection/components/textarea/textarea.stories.js +1 -1
- package/dist/collection/components/toast/toast.stories.js +1 -1
- package/dist/collection/components/toggle/toggle.stories.js +1 -1
- package/dist/collection/components/toolbar/toolbar.stories.js +1 -1
- package/dist/collection/components/toolbar-v2/toolbar-v2.stories.js +1 -1
- package/dist/collection/components/tooltip/tooltip.stories.js +1 -1
- package/dist/esm/{index-f3c5b68e.js → index-4c1f5d1f.js} +58 -22
- package/dist/esm/index-4c1f5d1f.js.map +1 -0
- package/dist/esm/index.js +4 -4
- package/dist/esm/loader.js +3 -3
- package/dist/esm/road-accordion.entry.js +1 -1
- package/dist/esm/road-alert.entry.js +1 -1
- package/dist/esm/road-area-code.entry.js +1 -1
- package/dist/esm/road-asset.entry.js +2 -2
- package/dist/esm/road-autocomplete.entry.js +1 -1
- package/dist/esm/road-avatar.entry.js +1 -1
- package/dist/esm/road-badge_14.entry.js +6 -6
- package/dist/esm/road-badge_14.entry.js.map +1 -1
- package/dist/esm/road-banner.entry.js +1 -1
- package/dist/esm/road-button-floating.entry.js +1 -1
- package/dist/esm/road-card.entry.js +1 -1
- package/dist/esm/road-carousel-item.entry.js +1 -1
- package/dist/esm/road-carousel.entry.js +1 -1
- package/dist/esm/road-checkbox.entry.js +1 -1
- package/dist/esm/road-chip.entry.js +1 -1
- package/dist/esm/road-collapse.entry.js +1 -1
- package/dist/esm/road-content-card.entry.js +1 -1
- package/dist/esm/road-dialog.entry.js +1 -1
- package/dist/esm/road-dropdown.entry.js +1 -1
- package/dist/esm/road-duration.entry.js +1 -1
- package/dist/esm/road-flap.entry.js +1 -1
- package/dist/esm/road-global-navigation-v2.entry.js +1 -1
- package/dist/esm/road-global-navigation.entry.js +1 -1
- package/dist/esm/road-illustration.entry.js +2 -2
- package/dist/esm/road-img.entry.js +1 -1
- package/dist/esm/road-modal.entry.js +1 -1
- package/dist/esm/road-navbar-item-v2.entry.js +1 -1
- package/dist/esm/road-navbar-item.entry.js +1 -1
- package/dist/esm/road-navbar-v2.entry.js +1 -1
- package/dist/esm/road-navbar.entry.js +1 -1
- package/dist/esm/road-phone-number-input.entry.js +1 -1
- package/dist/esm/road-plate-number.entry.js +1 -1
- package/dist/esm/road-profil-dropdown.entry.js +1 -1
- package/dist/esm/road-progress-indicator-horizontal.entry.js +1 -1
- package/dist/esm/road-progress-indicator-vertical-item.entry.js +1 -1
- package/dist/esm/road-progress-indicator-vertical.entry.js +1 -1
- package/dist/esm/road-progress-tracker-item.entry.js +1 -1
- package/dist/esm/road-progress-tracker.entry.js +1 -1
- package/dist/esm/road-progress.entry.js +1 -1
- package/dist/esm/road-radio-group.entry.js +1 -1
- package/dist/esm/road-radio.entry.js +1 -1
- package/dist/esm/road-range.entry.js +1 -1
- package/dist/esm/road-rating.entry.js +1 -1
- package/dist/esm/road-segmented-button-bar.entry.js +1 -1
- package/dist/esm/road-segmented-button.entry.js +1 -1
- package/dist/esm/road-segmented-buttons.entry.js +1 -1
- package/dist/esm/road-select-filter.entry.js +1 -1
- package/dist/esm/road-select.entry.js +1 -1
- package/dist/esm/road-skeleton.entry.js +1 -1
- package/dist/esm/road-spinner.entry.js +1 -1
- package/dist/esm/road-switch.entry.js +1 -1
- package/dist/esm/road-tab-bar.entry.js +1 -1
- package/dist/esm/road-tab-button.entry.js +1 -1
- package/dist/esm/road-tab.entry.js +1 -1
- package/dist/esm/road-table.entry.js +1 -1
- package/dist/esm/road-tabs.entry.js +1 -1
- package/dist/esm/road-tag.entry.js +1 -1
- package/dist/esm/road-text.entry.js +1 -1
- package/dist/esm/road-textarea.entry.js +1 -1
- package/dist/esm/road-toast.entry.js +1 -1
- package/dist/esm/road-toggle.entry.js +1 -1
- package/dist/esm/road-toolbar-title-page.entry.js +1 -1
- package/dist/esm/road-toolbar-title.entry.js +1 -1
- package/dist/esm/road-toolbar-v2.entry.js +1 -1
- package/dist/esm/road-tooltip.entry.js +1 -1
- package/dist/esm/roadtrip.js +4 -4
- package/dist/esm/roadtrip.js.map +1 -1
- package/dist/esm/{utils-65e8eef3.js → utils-78ae85c5.js} +2 -2
- package/dist/esm/{utils-65e8eef3.js.map → utils-78ae85c5.js.map} +1 -1
- package/dist/esm/{utils-d3cec86c.js → utils-964ae527.js} +2 -2
- package/dist/esm/{utils-d3cec86c.js.map → utils-964ae527.js.map} +1 -1
- package/dist/esm/{utils-8148deff.js → utils-c6a028c5.js} +2 -2
- package/dist/esm/{utils-8148deff.js.map → utils-c6a028c5.js.map} +1 -1
- package/dist/html.html-data.json +1 -1
- package/dist/roadtrip/index.esm.js +1 -1
- package/dist/roadtrip/{p-dac4736d.entry.js → p-01618daf.entry.js} +2 -2
- package/dist/roadtrip/{p-23142511.entry.js → p-07633780.entry.js} +2 -2
- package/dist/roadtrip/p-0b68e487.entry.js +2 -0
- package/dist/roadtrip/{p-f9c66715.entry.js.map → p-0b68e487.entry.js.map} +1 -1
- package/dist/roadtrip/p-0e2f57a3.js +2 -0
- package/dist/roadtrip/{p-698abbdb.entry.js → p-10927dd4.entry.js} +2 -2
- package/dist/roadtrip/{p-c70a6f75.entry.js → p-111df76e.entry.js} +2 -2
- package/dist/roadtrip/{p-6e822465.entry.js → p-1269f911.entry.js} +2 -2
- package/dist/roadtrip/{p-200d5c89.entry.js → p-1724566a.entry.js} +2 -2
- package/dist/roadtrip/{p-4de6e537.entry.js → p-1aaaf2b1.entry.js} +2 -2
- package/dist/roadtrip/{p-0801cc18.entry.js → p-1bc42c19.entry.js} +2 -2
- package/dist/roadtrip/{p-6709e3f4.entry.js → p-20459c08.entry.js} +2 -2
- package/dist/roadtrip/{p-52f26ae9.entry.js → p-264ec254.entry.js} +2 -2
- package/dist/roadtrip/p-274069da.entry.js +2 -0
- package/dist/roadtrip/{p-37135c95.entry.js → p-2b9ea6a5.entry.js} +2 -2
- package/dist/roadtrip/{p-6fc769fc.entry.js → p-2dd0333d.entry.js} +2 -2
- package/dist/roadtrip/{p-f155064c.entry.js → p-31aa3829.entry.js} +2 -2
- package/dist/roadtrip/{p-3c567881.entry.js → p-340c1fd7.entry.js} +2 -2
- package/dist/roadtrip/{p-9e7807f4.entry.js → p-3471dbc6.entry.js} +2 -2
- package/dist/roadtrip/{p-3823247f.entry.js → p-399a7d0b.entry.js} +2 -2
- package/dist/roadtrip/{p-3750f911.entry.js → p-3ce2e672.entry.js} +2 -2
- package/dist/roadtrip/{p-79acc6ae.entry.js → p-4bf63a98.entry.js} +2 -2
- package/dist/roadtrip/{p-c5b01dda.entry.js → p-4ecf466e.entry.js} +2 -2
- package/dist/roadtrip/{p-63582e9c.entry.js → p-5880437b.entry.js} +2 -2
- package/dist/roadtrip/{p-d6867247.entry.js → p-5d1b98e6.entry.js} +2 -2
- package/dist/roadtrip/{p-30d74a80.entry.js → p-5d41e85f.entry.js} +2 -2
- package/dist/roadtrip/{p-4688d888.entry.js → p-5ed1f4c0.entry.js} +2 -2
- package/dist/roadtrip/{p-44b6f632.entry.js → p-5f1eebe1.entry.js} +2 -2
- package/dist/roadtrip/{p-b85b7e2b.entry.js → p-604d917f.entry.js} +2 -2
- package/dist/roadtrip/p-6f5174da.entry.js +2 -0
- package/dist/roadtrip/{p-c4ffc419.entry.js.map → p-6f5174da.entry.js.map} +1 -1
- package/dist/roadtrip/{p-aa2721e5.entry.js → p-70406e7e.entry.js} +2 -2
- package/dist/roadtrip/{p-1e73c3ce.entry.js → p-7112119b.entry.js} +2 -2
- package/dist/roadtrip/{p-c8438d35.entry.js → p-73d3c4c3.entry.js} +2 -2
- package/dist/roadtrip/{p-00c5b2d9.entry.js → p-7487724c.entry.js} +2 -2
- package/dist/roadtrip/{p-05088511.entry.js → p-7e6aee16.entry.js} +2 -2
- package/dist/roadtrip/{p-668553e9.entry.js → p-80d87dbd.entry.js} +2 -2
- package/dist/roadtrip/{p-71769ef4.entry.js → p-84938814.entry.js} +2 -2
- package/dist/roadtrip/{p-7684978a.entry.js → p-97683034.entry.js} +2 -2
- package/dist/roadtrip/p-99029235.js +2 -0
- package/dist/roadtrip/{p-43335414.entry.js → p-9c432882.entry.js} +2 -2
- package/dist/roadtrip/{p-b18add2d.entry.js → p-9cc75bae.entry.js} +2 -2
- package/dist/roadtrip/{p-bb33c1b5.entry.js → p-a36d5d3c.entry.js} +2 -2
- package/dist/roadtrip/{p-4b2920f6.entry.js → p-ab58de35.entry.js} +2 -2
- package/dist/roadtrip/{p-d8dcd2d2.entry.js → p-ac169742.entry.js} +2 -2
- package/dist/roadtrip/{p-1fd97505.entry.js → p-ac93c5e0.entry.js} +2 -2
- package/dist/roadtrip/{p-b4ba1b47.entry.js → p-b0fc1a99.entry.js} +3 -3
- package/dist/roadtrip/{p-b4ba1b47.entry.js.map → p-b0fc1a99.entry.js.map} +1 -1
- package/dist/roadtrip/{p-0236ce0a.entry.js → p-b6223198.entry.js} +2 -2
- package/dist/roadtrip/{p-c8ea6b4e.entry.js → p-b87a0f45.entry.js} +2 -2
- package/dist/roadtrip/{p-504c0354.entry.js → p-be114fac.entry.js} +2 -2
- package/dist/roadtrip/{p-5dfc9c10.entry.js → p-be57dbfc.entry.js} +2 -2
- package/dist/roadtrip/{p-6dfdd9e2.entry.js → p-bec6c1c6.entry.js} +2 -2
- package/dist/roadtrip/{p-eabdd6ce.entry.js → p-c29b58de.entry.js} +2 -2
- package/dist/roadtrip/p-c6a3fafd.js +3 -0
- package/dist/roadtrip/p-c6a3fafd.js.map +1 -0
- package/dist/roadtrip/{p-eec578a2.entry.js → p-c9496fa4.entry.js} +2 -2
- package/dist/roadtrip/{p-c1fc3902.entry.js → p-cad3a806.entry.js} +2 -2
- package/dist/roadtrip/{p-cff73fff.entry.js → p-cf7dd5b3.entry.js} +2 -2
- package/dist/roadtrip/{p-d8ff2277.entry.js → p-d1c7020d.entry.js} +2 -2
- package/dist/roadtrip/{p-b55e3657.entry.js → p-d3b3f2c3.entry.js} +2 -2
- package/dist/roadtrip/{p-98fdbcfb.entry.js → p-d78990ab.entry.js} +2 -2
- package/dist/roadtrip/{p-2e26072a.entry.js → p-d8be8638.entry.js} +2 -2
- package/dist/roadtrip/{p-848de0f1.entry.js → p-e3ac1271.entry.js} +2 -2
- package/dist/roadtrip/{p-4a14e21e.entry.js → p-e62e919d.entry.js} +2 -2
- package/dist/roadtrip/{p-18db551b.entry.js → p-e71ed819.entry.js} +2 -2
- package/dist/roadtrip/{p-a8b369c3.entry.js → p-ea3df1ce.entry.js} +2 -2
- package/dist/roadtrip/{p-484f7c99.entry.js → p-ec989647.entry.js} +2 -2
- package/dist/roadtrip/{p-ad43e5f0.entry.js → p-f8994de8.entry.js} +2 -2
- package/dist/roadtrip/p-fab30e42.js +2 -0
- package/dist/roadtrip/{p-4dc8a165.entry.js → p-fd611bb9.entry.js} +2 -2
- package/dist/roadtrip/{p-908e3634.entry.js → p-ffd851b4.entry.js} +2 -2
- package/dist/roadtrip/roadtrip.esm.js +1 -1
- package/dist/roadtrip/roadtrip.esm.js.map +1 -1
- package/dist/types/components/input/input.d.ts +1 -1
- package/dist/types/components.d.ts +2 -2
- package/hydrate/index.d.ts +22 -5
- package/hydrate/index.js +480 -42
- package/hydrate/index.mjs +480 -42
- package/package.json +12 -20
- package/dist/cjs/index-aadb3ac9.js.map +0 -1
- package/dist/esm/index-f3c5b68e.js.map +0 -1
- package/dist/roadtrip/p-38ab0443.js +0 -2
- package/dist/roadtrip/p-4ad903fe.js +0 -2
- package/dist/roadtrip/p-763109be.js +0 -3
- package/dist/roadtrip/p-763109be.js.map +0 -1
- package/dist/roadtrip/p-a1ea2f84.entry.js +0 -2
- package/dist/roadtrip/p-c4ffc419.entry.js +0 -2
- package/dist/roadtrip/p-d9195195.js +0 -2
- package/dist/roadtrip/p-f9c66715.entry.js +0 -2
- /package/dist/roadtrip/{p-dac4736d.entry.js.map → p-01618daf.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-23142511.entry.js.map → p-07633780.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-38ab0443.js.map → p-0e2f57a3.js.map} +0 -0
- /package/dist/roadtrip/{p-698abbdb.entry.js.map → p-10927dd4.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-c70a6f75.entry.js.map → p-111df76e.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-6e822465.entry.js.map → p-1269f911.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-200d5c89.entry.js.map → p-1724566a.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-4de6e537.entry.js.map → p-1aaaf2b1.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-0801cc18.entry.js.map → p-1bc42c19.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-6709e3f4.entry.js.map → p-20459c08.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-52f26ae9.entry.js.map → p-264ec254.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-a1ea2f84.entry.js.map → p-274069da.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-37135c95.entry.js.map → p-2b9ea6a5.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-6fc769fc.entry.js.map → p-2dd0333d.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-f155064c.entry.js.map → p-31aa3829.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-3c567881.entry.js.map → p-340c1fd7.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-9e7807f4.entry.js.map → p-3471dbc6.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-3823247f.entry.js.map → p-399a7d0b.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-3750f911.entry.js.map → p-3ce2e672.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-79acc6ae.entry.js.map → p-4bf63a98.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-c5b01dda.entry.js.map → p-4ecf466e.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-63582e9c.entry.js.map → p-5880437b.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-d6867247.entry.js.map → p-5d1b98e6.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-30d74a80.entry.js.map → p-5d41e85f.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-4688d888.entry.js.map → p-5ed1f4c0.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-44b6f632.entry.js.map → p-5f1eebe1.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-b85b7e2b.entry.js.map → p-604d917f.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-aa2721e5.entry.js.map → p-70406e7e.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-1e73c3ce.entry.js.map → p-7112119b.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-c8438d35.entry.js.map → p-73d3c4c3.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-00c5b2d9.entry.js.map → p-7487724c.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-05088511.entry.js.map → p-7e6aee16.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-668553e9.entry.js.map → p-80d87dbd.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-71769ef4.entry.js.map → p-84938814.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-7684978a.entry.js.map → p-97683034.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-4ad903fe.js.map → p-99029235.js.map} +0 -0
- /package/dist/roadtrip/{p-43335414.entry.js.map → p-9c432882.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-b18add2d.entry.js.map → p-9cc75bae.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-bb33c1b5.entry.js.map → p-a36d5d3c.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-4b2920f6.entry.js.map → p-ab58de35.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-d8dcd2d2.entry.js.map → p-ac169742.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-1fd97505.entry.js.map → p-ac93c5e0.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-0236ce0a.entry.js.map → p-b6223198.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-c8ea6b4e.entry.js.map → p-b87a0f45.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-504c0354.entry.js.map → p-be114fac.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-5dfc9c10.entry.js.map → p-be57dbfc.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-6dfdd9e2.entry.js.map → p-bec6c1c6.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-eabdd6ce.entry.js.map → p-c29b58de.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-eec578a2.entry.js.map → p-c9496fa4.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-c1fc3902.entry.js.map → p-cad3a806.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-cff73fff.entry.js.map → p-cf7dd5b3.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-d8ff2277.entry.js.map → p-d1c7020d.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-b55e3657.entry.js.map → p-d3b3f2c3.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-98fdbcfb.entry.js.map → p-d78990ab.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-2e26072a.entry.js.map → p-d8be8638.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-848de0f1.entry.js.map → p-e3ac1271.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-4a14e21e.entry.js.map → p-e62e919d.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-18db551b.entry.js.map → p-e71ed819.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-a8b369c3.entry.js.map → p-ea3df1ce.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-484f7c99.entry.js.map → p-ec989647.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-ad43e5f0.entry.js.map → p-f8994de8.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-d9195195.js.map → p-fab30e42.js.map} +0 -0
- /package/dist/roadtrip/{p-4dc8a165.entry.js.map → p-fd611bb9.entry.js.map} +0 -0
- /package/dist/roadtrip/{p-908e3634.entry.js.map → p-ffd851b4.entry.js.map} +0 -0
|
@@ -30,7 +30,7 @@ export class Input {
|
|
|
30
30
|
/**
|
|
31
31
|
* If `true`, block decimal.
|
|
32
32
|
*/
|
|
33
|
-
this.
|
|
33
|
+
this.blockdecimal = false;
|
|
34
34
|
/**
|
|
35
35
|
* Whether auto correction should be enabled when the user is entering/editing the text value.
|
|
36
36
|
*/
|
|
@@ -83,7 +83,7 @@ export class Input {
|
|
|
83
83
|
this.onInput = (ev) => {
|
|
84
84
|
const input = ev.target;
|
|
85
85
|
let newValue = input.value;
|
|
86
|
-
if (this.type === 'number' && this.
|
|
86
|
+
if (this.type === 'number' && this.blockdecimal) {
|
|
87
87
|
newValue = newValue.replace(/[.,]/g, ''); // Supprime les décimales si blockDecimal est activé
|
|
88
88
|
}
|
|
89
89
|
this.value = newValue;
|
|
@@ -108,7 +108,7 @@ export class Input {
|
|
|
108
108
|
};
|
|
109
109
|
}
|
|
110
110
|
handleKeyDown(event) {
|
|
111
|
-
if (this.type === 'number' && this.
|
|
111
|
+
if (this.type === 'number' && this.blockdecimal) {
|
|
112
112
|
const forbiddenKeys = ['.', ',', 'e', '-', '¨', '^', '`', '+'];
|
|
113
113
|
if (forbiddenKeys.includes(event.key)) {
|
|
114
114
|
event.preventDefault();
|
|
@@ -157,7 +157,7 @@ export class Input {
|
|
|
157
157
|
const hasValueClass = this.value !== '' && this.value !== null ? 'has-value' : '';
|
|
158
158
|
const lessLabelClass = this.label !== '' ? '' : 'less-label';
|
|
159
159
|
const isInvalidClass = this.error !== undefined && this.error !== '' ? 'is-invalid' : '';
|
|
160
|
-
return (h(Host, { key: '
|
|
160
|
+
return (h(Host, { key: '9251985e0b07d2b85f319d30bd6e4cc46cf78147', "aria-disabled": this.disabled ? 'true' : null, class: this.sizes && `input-${this.sizes}`, value: value, blockdecimal: this.blockdecimal }, h("input", { key: 'b0d87d5bde0d232615d200c1b4c611a997931595', class: `form-control ${hasValueClass} ${isInvalidClass} ${lessLabelClass}`, id: this.inputId, "aria-disabled": this.disabled ? 'true' : null, "aria-labelledby": labelId, disabled: this.disabled, autoCapitalize: this.autocapitalize, autoComplete: this.autocomplete, autoCorrect: this.autocorrect, enterKeyHint: this.enterkeyhint, autoFocus: this.autofocus, inputMode: this.inputmode, min: this.min, max: this.max, minLength: this.minlength, maxLength: this.maxlength, name: this.name, pattern: this.pattern, placeholder: this.placeholder, readOnly: this.readonly, required: this.required, spellcheck: this.spellcheck, step: this.step, size: this.size, type: this.type, value: value, onInput: this.onInput, onBlur: this.onBlur, onFocus: this.onFocus, onKeyDown: this.type === 'number' ? (event) => this.handleKeyDown(event) : undefined, onKeyUp: (event) => this.enforceMinMax(event.target), "data-cy": 'road-input' }), h("label", { key: '910506a3f147908dd802d645c9d985862cf4126b', class: "form-label", id: labelId, htmlFor: this.inputId }, this.label), this.error && this.error !== '' && h("p", { key: 'feb2985f978e936bcde5328233a433eda6f2d16c', class: "invalid-feedback" }, h("road-icon", { key: 'f5d8a3c8edc1ccac2d5b9f9d6b2bcc3f3f7bc283', slot: "start", name: "alert-error-solid", "aria-hidden": "true", size: "sm" }), this.error), this.helper && this.helper !== '' && h("p", { key: '3e11fd43dc68951c17d3ab267bc4a25316e1efce', class: "helper" }, this.helper), this.type && this.type == 'password' && h("slot", { key: '0a2df2f8c92a52d18b6d1063765eaf47809a60b3', name: "checklistPassword" })));
|
|
161
161
|
}
|
|
162
162
|
static get is() { return "road-input"; }
|
|
163
163
|
static get encapsulation() { return "scoped"; }
|
|
@@ -239,7 +239,7 @@ export class Input {
|
|
|
239
239
|
"reflect": false,
|
|
240
240
|
"defaultValue": "'off'"
|
|
241
241
|
},
|
|
242
|
-
"
|
|
242
|
+
"blockdecimal": {
|
|
243
243
|
"type": "boolean",
|
|
244
244
|
"mutable": false,
|
|
245
245
|
"complexType": {
|
|
@@ -255,7 +255,7 @@ export class Input {
|
|
|
255
255
|
},
|
|
256
256
|
"getter": false,
|
|
257
257
|
"setter": false,
|
|
258
|
-
"attribute": "
|
|
258
|
+
"attribute": "blockdecimal",
|
|
259
259
|
"reflect": false,
|
|
260
260
|
"defaultValue": "false"
|
|
261
261
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"input.js","sourceRoot":"","sources":["../../../src/components/input/input.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAgB,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;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,IAAI,QAAQ,GAAG,CAAC,CAAC","sourcesContent":["import { Component, Event, EventEmitter, Host, Prop, Watch, h } from '@stencil/core';\nimport { debounce as lodashDebounce } from 'lodash';\nimport { AutocompleteTypes, TextFieldTypes } from '../../interface';\n\n/**\n * @slot checklistPassword - Content the checklist Password exemple.\n * `<div class=\"checklist-password mt-16\" slot=\"checklistPassword\">`\n * `<span class=\"checklist-password-label\"><strong>Low Safety</strong></span>`\n * `<road-progress color=\"danger\" value=\"25\" class=\"mt-8 mb-16\"></road-progress>`\n * `<p class=\"text-medium mb-8\">For optimal safety your password must have at least :</p>`\n * `<ul class=\"m-0 pl-16\">`\n * `<li id=\"letter\" class=\"invalid mb-8\">1 lowercase and 1 uppercase</li>`\n * `<li id=\"number\" class=\"invalid mb-8\">1 digit</li>`\n * `<li id=\"length\" class=\"invalid\">8 characters minimum</li>`\n * `</ul>`\n * `</div>`\n */\n\n@Component({\n tag: 'road-input',\n styleUrl: 'input.css',\n scoped: true,\n})\nexport class Input {\n /**\n * The id of input\n */\n @Prop() inputId: string = `road-input-${inputIds++}`;\n\n /**\n * Indicates whether and how the text value should be automatically capitalized as it is entered/edited by the user.\n */\n @Prop() autocapitalize = 'off';\n\n /**\n * Indicates whether the value of the control can be automatically completed by the browser.\n */\n @Prop() autocomplete: AutocompleteTypes = 'off';\n\n /**\n * If `true`, block decimal.\n */\n @Prop() blockDecimal: boolean = false;\n\n\n /**\n * Whether auto correction should be enabled when the user is entering/editing the text value.\n */\n @Prop() autocorrect: 'on' | 'off' = 'off';\n\n /**\n * This Boolean attribute lets you specify that a form control should have input focus when the page loads.\n */\n @Prop() autofocus = false;\n\n /**\n * If `true`, the user cannot interact with the input.\n */\n @Prop() disabled = false;\n\n /**\n * A hint to the browser for which enter key to display.\n * Possible values: `\"enter\"`, `\"done\"`, `\"go\"`, `\"next\"`,\n * `\"previous\"`, `\"search\"`, and `\"send\"`.\n */\n @Prop() enterkeyhint?: 'enter' | 'done' | 'go' | 'next' | 'previous' | 'search' | 'send';\n\n /**\n * A hint to the browser for which keyboard to display.\n * This attribute applies when the value of the type attribute is `\"text\"`, `\"password\"`, `\"email\"`, or `\"url\"`. Possible values are: `\"verbatim\"`, `\"latin\"`, `\"latin-name\"`, `\"latin-prose\"`, `\"full-width-latin\"`, `\"kana\"`, `\"katakana\"`, `\"numeric\"`, `\"tel\"`, `\"email\"`, `\"url\"`.\n */\n @Prop() inputmode?: 'none' | 'text' | 'tel' | 'url' | 'email' | 'numeric' | 'decimal' | 'search';\n\n /**\n * The maximum value, which must not be less than its minimum (min attribute) value.\n */\n @Prop() max?: string;\n\n /**\n * If the value of the type attribute is `text`, `email`, `search`, `password`, `tel`, or `url`, this attribute specifies the maximum number of characters that the user can enter.\n */\n @Prop() maxlength?: number;\n\n /**\n * The minimum value, which must not be greater than its maximum (max attribute) value.\n */\n @Prop() min?: string;\n\n /**\n * If the value of the type attribute is `text`, `email`, `search`, `password`, `tel`, or `url`, this attribute specifies the minimum number of characters that the user can enter.\n */\n @Prop() minlength?: number;\n\n /**\n * The name of the control, which is submitted with the form data.\n */\n @Prop() name: string = this.inputId;\n\n /**\n * A regular expression that the value is checked against. The pattern must match the entire value, not just some subset. Use the title attribute to describe the pattern to help the user. This attribute applies when the value of the type attribute is `\"text\"`, `\"search\"`, `\"tel\"`, `\"url\"`, `\"email\"`, or `\"password\"`, otherwise it is ignored.\n */\n @Prop() pattern?: string;\n\n /**\n * Instructional text that shows before the input has a value.\n */\n @Prop() placeholder?: string;\n\n /**\n * If `true`, the user cannot modify the value.\n */\n @Prop() readonly = false;\n\n /**\n * If `true`, the user must fill in a value before submitting a form.\n */\n @Prop() required = false;\n\n /**\n * If `true`, the element will have its spelling and grammar checked.\n */\n @Prop() spellcheck = false;\n\n /**\n * Works with the min and max attributes to limit the increments at which a value can be set.\n * Possible values are: `\"any\"` or a positive floating point number.\n */\n @Prop() step?: string;\n\n /**\n * The initial size of the control. This value is in pixels unless the value of the type attribute is `\"text\"` or `\"password\"`, in which case it is an integer number of characters. This attribute applies only when the `type` attribute is set to `\"text\"`, `\"search\"`, `\"tel\"`, `\"url\"`, `\"email\"`, or `\"password\"`, otherwise it is ignored.\n */\n @Prop() size?: number;\n\n /**\n * The sizes of the input.\n */\n @Prop() sizes: 'lg' | 'xl' = 'lg';\n\n /**\n * The type of control to display. The default type is text.\n */\n @Prop() type: TextFieldTypes = 'text';\n\n /**\n * The value of the input.(for dynamic use use v-model for vue instead)\n */\n @Prop({ mutable: true }) value?: string | number | null = '';\n\n /**\n * Label for the field\n */\n @Prop() label?: string = '';\n\n /**\n * Error message for the field\n */\n @Prop() error?: string;\n\n /**\n * Helper message for the field\n */\n @Prop() helper?: string;\n\n /**\n * Set the amount of time, in milliseconds, to wait to trigger the `roadChange` event after each keystroke.\n */\n @Prop() debounce = 0;\n\n private handleKeyDown(event: KeyboardEvent) {\n if (this.type === 'number' && this.blockDecimal) {\n const forbiddenKeys = ['.', ',', 'e', '-', '¨', '^', '`', '+'];\n if (forbiddenKeys.includes(event.key)) {\n event.preventDefault();\n }\n }\n }\n\n\n private debouncedRoadChange = this.createDebouncedRoadChange();\n\n private createDebouncedRoadChange() {\n return lodashDebounce((value: any) => {\n this.roadChange.emit({ value: value == null ? value : value.toString() });\n }, this.debounce);\n }\n\n @Watch('debounce')\n debounceChanged() {\n // Créez une nouvelle fonction debouncedRoadChange avec la nouvelle valeur de debounce\n this.debouncedRoadChange = this.createDebouncedRoadChange();\n }\n\n /**\n * Update the native input element when the value changes\n */\n @Watch('value')\n protected valueChanged() {\n this.debouncedRoadChange(this.value);\n }\n\n /**\n * Emitted when a keyboard input occurred.\n */\n\n /** @internal */\n @Event() roadInput!: EventEmitter<KeyboardEvent>;\n\n /**\n * Emitted when the value has changed.\n */\n\n /** @internal */\n @Event() roadChange!: EventEmitter<{\n value: string | undefined | null;\n }>;\n\n /**\n * Emitted when the input loses focus.\n */\n\n /** @internal */\n @Event() roadBlur!: EventEmitter<string | null>;\n\n /**\n * Emitted when the input has focus.\n */\n\n /** @internal */\n @Event() roadFocus!: EventEmitter<void>;\n\n private getValue(): string {\n return typeof this.value === 'number'\n ? this.value.toString()\n : (this.value || '').toString();\n }\n\n private onInput = (ev: Event) => {\n const input = ev.target as HTMLInputElement;\n let newValue = input.value;\n\n if (this.type === 'number' && this.blockDecimal) {\n newValue = newValue.replace(/[.,]/g, ''); // Supprime les décimales si blockDecimal est activé\n }\n\n this.value = newValue;\n this.roadInput.emit(ev as KeyboardEvent);\n this.roadChange.emit({ value: newValue });\n };\n\n private onBlur = () => {\n let value = this.getValue();\n\n // Vérifier si les contraintes min et max sont définies\n if (this.min !== undefined && value !== '' && parseFloat(value) < parseFloat(this.min)) {\n value = this.min; // Ajuster la valeur à la valeur minimale\n }\n\n if (this.max !== undefined && value !== '' && parseFloat(value) > parseFloat(this.max)) {\n value = this.max; // Ajuster la valeur à la valeur maximale\n }\n\n this.value = value; // Mettre à jour la valeur avec la valeur ajustée\n\n // Émettre l'événement roadblur avec la valeur ajustée\n this.roadBlur.emit(value);\n };\n\n private onFocus = () => {\n this.roadFocus.emit();\n };\n\n private enforceMinMax(el: HTMLInputElement): void {\n if (el.value !== \"\") {\n const value: number = parseInt(el.value);\n const minValue: number = parseInt(el.min);\n const maxValue: number = parseInt(el.max);\n\n if (value < minValue) {\n el.value = el.min;\n }\n\n if (value > maxValue) {\n el.value = el.max;\n }\n }\n }\n\n componentWillLoad() {\n this.debounceChanged(); // Initialize debounce on component load\n }\n\n render() {\n const value = this.getValue();\n const labelId = this.inputId + '-label';\n const hasValueClass = this.value !== '' && this.value !== null ? 'has-value' : '';\n const lessLabelClass = this.label !== '' ? '' : 'less-label';\n const isInvalidClass = this.error !== undefined && this.error !== '' ? 'is-invalid' : '';\n\n return (\n <Host aria-disabled={this.disabled ? 'true' : null} class={this.sizes && `input-${this.sizes}`} value={value}>\n <input\n class={`form-control ${hasValueClass} ${isInvalidClass} ${lessLabelClass}`}\n id={this.inputId}\n aria-disabled={this.disabled ? 'true' : null}\n aria-labelledby={labelId}\n disabled={this.disabled}\n autoCapitalize={this.autocapitalize}\n autoComplete={this.autocomplete}\n autoCorrect={this.autocorrect}\n enterKeyHint={this.enterkeyhint}\n autoFocus={this.autofocus}\n inputMode={this.inputmode}\n min={this.min}\n max={this.max}\n minLength={this.minlength}\n maxLength={this.maxlength}\n name={this.name}\n pattern={this.pattern}\n placeholder={this.placeholder}\n readOnly={this.readonly}\n required={this.required}\n spellcheck={this.spellcheck}\n step={this.step}\n size={this.size}\n type={this.type}\n value={value}\n onInput={this.onInput}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n onKeyDown={this.type === 'number' ? (event: KeyboardEvent) => this.handleKeyDown(event) : undefined}\n onKeyUp={(event: Event) => this.enforceMinMax(event.target as HTMLInputElement)}\n data-cy='road-input'\n />\n <label class=\"form-label\" id={labelId} htmlFor={this.inputId}>{this.label}</label>\n {this.error && this.error !== '' && <p class=\"invalid-feedback\"><road-icon slot=\"start\" name=\"alert-error-solid\" aria-hidden=\"true\" size=\"sm\"></road-icon>{this.error}</p>}\n {this.helper && this.helper !== '' && <p class=\"helper\">{this.helper}</p>}\n {this.type && this.type == 'password' && <slot name=\"checklistPassword\" />}\n </Host>\n );\n }\n}\n\nlet inputIds = 0;\n"]}
|
|
1
|
+
{"version":3,"file":"input.js","sourceRoot":"","sources":["../../../src/components/input/input.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAgB,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AACrF,OAAO,EAAE,QAAQ,IAAI,cAAc,EAAE,MAAM,QAAQ,CAAC;AAGpD;;;;;;;;;;;;GAYG;AAOH,MAAM,OAAO,KAAK;IALlB;QAME;;WAEG;QACK,YAAO,GAAW,cAAc,QAAQ,EAAE,EAAE,CAAC;QAErD;;WAEG;QACK,mBAAc,GAAG,KAAK,CAAC;QAE/B;;WAEG;QACK,iBAAY,GAAsB,KAAK,CAAC;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KAAK,EAAE,IAAI,0DAAG,KAAK,EAAC,QAAQ,IAAE,IAAI,CAAC,MAAM,CAAK;YACxE,IAAI,CAAC,IAAI,IAAI,IAAI,CAAC,IAAI,IAAI,UAAU,IAAI,6DAAM,IAAI,EAAC,mBAAmB,GAAG,CACrE,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF;AAED,IAAI,QAAQ,GAAG,CAAC,CAAC","sourcesContent":["import { Component, Event, EventEmitter, Host, Prop, Watch, h } from '@stencil/core';\nimport { debounce as lodashDebounce } from 'lodash';\nimport { AutocompleteTypes, TextFieldTypes } from '../../interface';\n\n/**\n * @slot checklistPassword - Content the checklist Password exemple.\n * `<div class=\"checklist-password mt-16\" slot=\"checklistPassword\">`\n * `<span class=\"checklist-password-label\"><strong>Low Safety</strong></span>`\n * `<road-progress color=\"danger\" value=\"25\" class=\"mt-8 mb-16\"></road-progress>`\n * `<p class=\"text-medium mb-8\">For optimal safety your password must have at least :</p>`\n * `<ul class=\"m-0 pl-16\">`\n * `<li id=\"letter\" class=\"invalid mb-8\">1 lowercase and 1 uppercase</li>`\n * `<li id=\"number\" class=\"invalid mb-8\">1 digit</li>`\n * `<li id=\"length\" class=\"invalid\">8 characters minimum</li>`\n * `</ul>`\n * `</div>`\n */\n\n@Component({\n tag: 'road-input',\n styleUrl: 'input.css',\n scoped: true,\n})\nexport class Input {\n /**\n * The id of input\n */\n @Prop() inputId: string = `road-input-${inputIds++}`;\n\n /**\n * Indicates whether and how the text value should be automatically capitalized as it is entered/edited by the user.\n */\n @Prop() autocapitalize = 'off';\n\n /**\n * Indicates whether the value of the control can be automatically completed by the browser.\n */\n @Prop() autocomplete: AutocompleteTypes = 'off';\n\n /**\n * If `true`, block decimal.\n */\n @Prop() blockdecimal = false;\n\n\n /**\n * Whether auto correction should be enabled when the user is entering/editing the text value.\n */\n @Prop() autocorrect: 'on' | 'off' = 'off';\n\n /**\n * This Boolean attribute lets you specify that a form control should have input focus when the page loads.\n */\n @Prop() autofocus = false;\n\n /**\n * If `true`, the user cannot interact with the input.\n */\n @Prop() disabled = false;\n\n /**\n * A hint to the browser for which enter key to display.\n * Possible values: `\"enter\"`, `\"done\"`, `\"go\"`, `\"next\"`,\n * `\"previous\"`, `\"search\"`, and `\"send\"`.\n */\n @Prop() enterkeyhint?: 'enter' | 'done' | 'go' | 'next' | 'previous' | 'search' | 'send';\n\n /**\n * A hint to the browser for which keyboard to display.\n * This attribute applies when the value of the type attribute is `\"text\"`, `\"password\"`, `\"email\"`, or `\"url\"`. Possible values are: `\"verbatim\"`, `\"latin\"`, `\"latin-name\"`, `\"latin-prose\"`, `\"full-width-latin\"`, `\"kana\"`, `\"katakana\"`, `\"numeric\"`, `\"tel\"`, `\"email\"`, `\"url\"`.\n */\n @Prop() inputmode?: 'none' | 'text' | 'tel' | 'url' | 'email' | 'numeric' | 'decimal' | 'search';\n\n /**\n * The maximum value, which must not be less than its minimum (min attribute) value.\n */\n @Prop() max?: string;\n\n /**\n * If the value of the type attribute is `text`, `email`, `search`, `password`, `tel`, or `url`, this attribute specifies the maximum number of characters that the user can enter.\n */\n @Prop() maxlength?: number;\n\n /**\n * The minimum value, which must not be greater than its maximum (max attribute) value.\n */\n @Prop() min?: string;\n\n /**\n * If the value of the type attribute is `text`, `email`, `search`, `password`, `tel`, or `url`, this attribute specifies the minimum number of characters that the user can enter.\n */\n @Prop() minlength?: number;\n\n /**\n * The name of the control, which is submitted with the form data.\n */\n @Prop() name: string = this.inputId;\n\n /**\n * A regular expression that the value is checked against. The pattern must match the entire value, not just some subset. Use the title attribute to describe the pattern to help the user. This attribute applies when the value of the type attribute is `\"text\"`, `\"search\"`, `\"tel\"`, `\"url\"`, `\"email\"`, or `\"password\"`, otherwise it is ignored.\n */\n @Prop() pattern?: string;\n\n /**\n * Instructional text that shows before the input has a value.\n */\n @Prop() placeholder?: string;\n\n /**\n * If `true`, the user cannot modify the value.\n */\n @Prop() readonly = false;\n\n /**\n * If `true`, the user must fill in a value before submitting a form.\n */\n @Prop() required = false;\n\n /**\n * If `true`, the element will have its spelling and grammar checked.\n */\n @Prop() spellcheck = false;\n\n /**\n * Works with the min and max attributes to limit the increments at which a value can be set.\n * Possible values are: `\"any\"` or a positive floating point number.\n */\n @Prop() step?: string;\n\n /**\n * The initial size of the control. This value is in pixels unless the value of the type attribute is `\"text\"` or `\"password\"`, in which case it is an integer number of characters. This attribute applies only when the `type` attribute is set to `\"text\"`, `\"search\"`, `\"tel\"`, `\"url\"`, `\"email\"`, or `\"password\"`, otherwise it is ignored.\n */\n @Prop() size?: number;\n\n /**\n * The sizes of the input.\n */\n @Prop() sizes: 'lg' | 'xl' = 'lg';\n\n /**\n * The type of control to display. The default type is text.\n */\n @Prop() type: TextFieldTypes = 'text';\n\n /**\n * The value of the input.(for dynamic use use v-model for vue instead)\n */\n @Prop({ mutable: true }) value?: string | number | null = '';\n\n /**\n * Label for the field\n */\n @Prop() label?: string = '';\n\n /**\n * Error message for the field\n */\n @Prop() error?: string;\n\n /**\n * Helper message for the field\n */\n @Prop() helper?: string;\n\n /**\n * Set the amount of time, in milliseconds, to wait to trigger the `roadChange` event after each keystroke.\n */\n @Prop() debounce = 0;\n\n private handleKeyDown(event: KeyboardEvent) {\n if (this.type === 'number' && this.blockdecimal) {\n const forbiddenKeys = ['.', ',', 'e', '-', '¨', '^', '`', '+'];\n if (forbiddenKeys.includes(event.key)) {\n event.preventDefault();\n }\n }\n }\n\n\n private debouncedRoadChange = this.createDebouncedRoadChange();\n\n private createDebouncedRoadChange() {\n return lodashDebounce((value: any) => {\n this.roadChange.emit({ value: value == null ? value : value.toString() });\n }, this.debounce);\n }\n\n @Watch('debounce')\n debounceChanged() {\n // Créez une nouvelle fonction debouncedRoadChange avec la nouvelle valeur de debounce\n this.debouncedRoadChange = this.createDebouncedRoadChange();\n }\n\n /**\n * Update the native input element when the value changes\n */\n @Watch('value')\n protected valueChanged() {\n this.debouncedRoadChange(this.value);\n }\n\n /**\n * Emitted when a keyboard input occurred.\n */\n\n /** @internal */\n @Event() roadInput!: EventEmitter<KeyboardEvent>;\n\n /**\n * Emitted when the value has changed.\n */\n\n /** @internal */\n @Event() roadChange!: EventEmitter<{\n value: string | undefined | null;\n }>;\n\n /**\n * Emitted when the input loses focus.\n */\n\n /** @internal */\n @Event() roadBlur!: EventEmitter<string | null>;\n\n /**\n * Emitted when the input has focus.\n */\n\n /** @internal */\n @Event() roadFocus!: EventEmitter<void>;\n\n private getValue(): string {\n return typeof this.value === 'number'\n ? this.value.toString()\n : (this.value || '').toString();\n }\n\n private onInput = (ev: Event) => {\n const input = ev.target as HTMLInputElement;\n let newValue = input.value;\n\n if (this.type === 'number' && this.blockdecimal) {\n newValue = newValue.replace(/[.,]/g, ''); // Supprime les décimales si blockDecimal est activé\n }\n\n this.value = newValue;\n this.roadInput.emit(ev as KeyboardEvent);\n this.roadChange.emit({ value: newValue });\n };\n\n private onBlur = () => {\n let value = this.getValue();\n\n // Vérifier si les contraintes min et max sont définies\n if (this.min !== undefined && value !== '' && parseFloat(value) < parseFloat(this.min)) {\n value = this.min; // Ajuster la valeur à la valeur minimale\n }\n\n if (this.max !== undefined && value !== '' && parseFloat(value) > parseFloat(this.max)) {\n value = this.max; // Ajuster la valeur à la valeur maximale\n }\n\n this.value = value; // Mettre à jour la valeur avec la valeur ajustée\n\n // Émettre l'événement roadblur avec la valeur ajustée\n this.roadBlur.emit(value);\n };\n\n private onFocus = () => {\n this.roadFocus.emit();\n };\n\n private enforceMinMax(el: HTMLInputElement): void {\n if (el.value !== \"\") {\n const value: number = parseInt(el.value);\n const minValue: number = parseInt(el.min);\n const maxValue: number = parseInt(el.max);\n\n if (value < minValue) {\n el.value = el.min;\n }\n\n if (value > maxValue) {\n el.value = el.max;\n }\n }\n }\n\n componentWillLoad() {\n this.debounceChanged(); // Initialize debounce on component load\n }\n\n render() {\n const value = this.getValue();\n const labelId = this.inputId + '-label';\n const hasValueClass = this.value !== '' && this.value !== null ? 'has-value' : '';\n const lessLabelClass = this.label !== '' ? '' : 'less-label';\n const isInvalidClass = this.error !== undefined && this.error !== '' ? 'is-invalid' : '';\n\n return (\n <Host aria-disabled={this.disabled ? 'true' : null} class={this.sizes && `input-${this.sizes}`} value={value} blockdecimal={this.blockdecimal}>\n <input\n class={`form-control ${hasValueClass} ${isInvalidClass} ${lessLabelClass}`}\n id={this.inputId}\n aria-disabled={this.disabled ? 'true' : null}\n aria-labelledby={labelId}\n disabled={this.disabled}\n autoCapitalize={this.autocapitalize}\n autoComplete={this.autocomplete}\n autoCorrect={this.autocorrect}\n enterKeyHint={this.enterkeyhint}\n autoFocus={this.autofocus}\n inputMode={this.inputmode}\n min={this.min}\n max={this.max}\n minLength={this.minlength}\n maxLength={this.maxlength}\n name={this.name}\n pattern={this.pattern}\n placeholder={this.placeholder}\n readOnly={this.readonly}\n required={this.required}\n spellcheck={this.spellcheck}\n step={this.step}\n size={this.size}\n type={this.type}\n value={value}\n onInput={this.onInput}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n onKeyDown={this.type === 'number' ? (event: KeyboardEvent) => this.handleKeyDown(event) : undefined}\n onKeyUp={(event: Event) => this.enforceMinMax(event.target as HTMLInputElement)}\n data-cy='road-input'\n />\n <label class=\"form-label\" id={labelId} htmlFor={this.inputId}>{this.label}</label>\n {this.error && this.error !== '' && <p class=\"invalid-feedback\"><road-icon slot=\"start\" name=\"alert-error-solid\" aria-hidden=\"true\" size=\"sm\"></road-icon>{this.error}</p>}\n {this.helper && this.helper !== '' && <p class=\"helper\">{this.helper}</p>}\n {this.type && this.type == 'password' && <slot name=\"checklistPassword\" />}\n </Host>\n );\n }\n}\n\nlet inputIds = 0;\n"]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { html } from 'lit-html';
|
|
2
|
-
import { ifDefined } from 'lit/directives/if-defined
|
|
2
|
+
import { ifDefined } from 'lit-html/directives/if-defined';
|
|
3
3
|
import { unsafeHTML } from 'lit-html/directives/unsafe-html.js';
|
|
4
4
|
|
|
5
5
|
export default {
|
|
@@ -26,6 +26,9 @@ export default {
|
|
|
26
26
|
spellcheck: {
|
|
27
27
|
control: 'boolean',
|
|
28
28
|
},
|
|
29
|
+
blockdecimal: {
|
|
30
|
+
control: 'boolean',
|
|
31
|
+
},
|
|
29
32
|
error: {
|
|
30
33
|
control: 'text',
|
|
31
34
|
},
|
|
@@ -181,6 +184,7 @@ export default {
|
|
|
181
184
|
required: null,
|
|
182
185
|
autofocus: null,
|
|
183
186
|
spellcheck: null,
|
|
187
|
+
blockdecimal: null,
|
|
184
188
|
'checklistPassword': ``,
|
|
185
189
|
},
|
|
186
190
|
};
|
|
@@ -204,6 +208,7 @@ const Template = (args) => html`
|
|
|
204
208
|
value="${ifDefined(args.value)}"
|
|
205
209
|
pattern="${ifDefined(args.pattern)}"
|
|
206
210
|
spellcheck="${ifDefined(args.spellcheck)}"
|
|
211
|
+
blockdecimal="${ifDefined(args.blockdecimal)}"
|
|
207
212
|
placeholder="${ifDefined(args.placeholder)}"
|
|
208
213
|
type="${ifDefined(args.type)}"
|
|
209
214
|
autocapitalize="${ifDefined(args.autocapitalize)}"
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { html } from 'lit-html';
|
|
2
|
-
import { ifDefined } from 'lit/directives/if-defined
|
|
2
|
+
import { ifDefined } from 'lit-html/directives/if-defined';
|
|
3
3
|
import { unsafeHTML } from 'lit-html/directives/unsafe-html.js';
|
|
4
4
|
import { list } from '../../../.storybook/list';
|
|
5
5
|
|
|
@@ -2,7 +2,7 @@ const NAMESPACE = 'roadtrip';
|
|
|
2
2
|
const BUILD = /* roadtrip */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: false, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: true, cmpWillUpdate: false, connectedCallback: true, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: true, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: true, hostListenerTarget: true, hostListenerTargetBody: false, hostListenerTargetDocument: true, hostListenerTargetParent: false, hostListenerTargetWindow: true, hotModuleReplacement: false, hydrateClientSide: true, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, hydratedSelectorName: "hydrated", initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: true, mode: false, modernPropertyDecls: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: true, propNumber: true, propString: true, reflect: true, scoped: true, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: true, state: true, style: true, svg: true, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: true, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: true, vdomRender: true, vdomStyle: true, vdomText: true, vdomXlink: true, watchCallback: true };
|
|
3
3
|
|
|
4
4
|
/*
|
|
5
|
-
Stencil Client Platform v4.
|
|
5
|
+
Stencil Client Platform v4.26.0 | MIT Licensed | https://stenciljs.com
|
|
6
6
|
*/
|
|
7
7
|
var __defProp = Object.defineProperty;
|
|
8
8
|
var __export = (target, all) => {
|
|
@@ -727,7 +727,7 @@ var initializeClientHydrate = (hostElm, tagName, hostId, hostRef) => {
|
|
|
727
727
|
delete hostElm["s-sc"];
|
|
728
728
|
}
|
|
729
729
|
}
|
|
730
|
-
if (!plt.$orgLocNodes$) {
|
|
730
|
+
if (!plt.$orgLocNodes$ || !plt.$orgLocNodes$.size) {
|
|
731
731
|
initializeDocumentHydrate(doc.body, plt.$orgLocNodes$ = /* @__PURE__ */ new Map());
|
|
732
732
|
}
|
|
733
733
|
hostElm[HYDRATE_ID] = hostId;
|
|
@@ -757,6 +757,7 @@ var initializeClientHydrate = (hostElm, tagName, hostId, hostRef) => {
|
|
|
757
757
|
}
|
|
758
758
|
}
|
|
759
759
|
if (childRenderNode.$tag$ === "slot") {
|
|
760
|
+
childRenderNode.$name$ = childRenderNode.$elm$["s-sn"] || childRenderNode.$elm$["name"] || null;
|
|
760
761
|
if (childRenderNode.$children$) {
|
|
761
762
|
childRenderNode.$flags$ |= 2 /* isSlotFallback */;
|
|
762
763
|
if (!childRenderNode.$elm$.childNodes.length) {
|
|
@@ -817,18 +818,25 @@ var initializeClientHydrate = (hostElm, tagName, hostId, hostRef) => {
|
|
|
817
818
|
slot.$elm$.parentElement.classList.add(scopeId2 + "-s");
|
|
818
819
|
});
|
|
819
820
|
}
|
|
820
|
-
if (shadowRoot) {
|
|
821
|
+
if (shadowRoot && !shadowRoot.childNodes.length) {
|
|
821
822
|
let rnIdex = 0;
|
|
822
823
|
const rnLen = shadowRootNodes.length;
|
|
823
|
-
|
|
824
|
-
|
|
824
|
+
if (rnLen) {
|
|
825
|
+
for (rnIdex; rnIdex < rnLen; rnIdex++) {
|
|
826
|
+
shadowRoot.appendChild(shadowRootNodes[rnIdex]);
|
|
827
|
+
}
|
|
828
|
+
Array.from(hostElm.childNodes).forEach((node) => {
|
|
829
|
+
if (typeof node["s-sn"] !== "string") {
|
|
830
|
+
if (node.nodeType === 1 /* ElementNode */ && node.slot && node.hidden) {
|
|
831
|
+
node.removeAttribute("hidden");
|
|
832
|
+
} else if (node.nodeType === 8 /* CommentNode */ || node.nodeType === 3 /* TextNode */ && !node.wholeText.trim()) {
|
|
833
|
+
node.parentNode.removeChild(node);
|
|
834
|
+
}
|
|
835
|
+
}
|
|
836
|
+
});
|
|
825
837
|
}
|
|
826
|
-
Array.from(hostElm.childNodes).forEach((node) => {
|
|
827
|
-
if (node.nodeType === 8 /* CommentNode */ && typeof node["s-sn"] !== "string") {
|
|
828
|
-
node.parentNode.removeChild(node);
|
|
829
|
-
}
|
|
830
|
-
});
|
|
831
838
|
}
|
|
839
|
+
plt.$orgLocNodes$.delete(hostElm["s-id"]);
|
|
832
840
|
hostRef.$hostElement$ = hostElm;
|
|
833
841
|
endHydrate();
|
|
834
842
|
};
|
|
@@ -939,7 +947,7 @@ var clientHydrate = (parentVNode, childRenderNodes, slotNodes, shadowRootNodes,
|
|
|
939
947
|
$text$: null
|
|
940
948
|
});
|
|
941
949
|
if (childNodeType === TEXT_NODE_ID) {
|
|
942
|
-
childVNode.$elm$ = node
|
|
950
|
+
childVNode.$elm$ = findCorrespondingNode(node, 3 /* TextNode */);
|
|
943
951
|
if (childVNode.$elm$ && childVNode.$elm$.nodeType === 3 /* TextNode */) {
|
|
944
952
|
childVNode.$text$ = childVNode.$elm$.textContent;
|
|
945
953
|
childRenderNodes.push(childVNode);
|
|
@@ -955,7 +963,7 @@ var clientHydrate = (parentVNode, childRenderNodes, slotNodes, shadowRootNodes,
|
|
|
955
963
|
}
|
|
956
964
|
}
|
|
957
965
|
} else if (childNodeType === COMMENT_NODE_ID) {
|
|
958
|
-
childVNode.$elm$ = node
|
|
966
|
+
childVNode.$elm$ = findCorrespondingNode(node, 8 /* CommentNode */);
|
|
959
967
|
if (childVNode.$elm$ && childVNode.$elm$.nodeType === 8 /* CommentNode */) {
|
|
960
968
|
childRenderNodes.push(childVNode);
|
|
961
969
|
node.remove();
|
|
@@ -989,6 +997,10 @@ var clientHydrate = (parentVNode, childRenderNodes, slotNodes, shadowRootNodes,
|
|
|
989
997
|
vnode.$elm$ = node;
|
|
990
998
|
vnode.$index$ = "0";
|
|
991
999
|
parentVNode.$children$ = [vnode];
|
|
1000
|
+
} else {
|
|
1001
|
+
if (node.nodeType === 3 /* TextNode */ && !node.wholeText.trim()) {
|
|
1002
|
+
node.remove();
|
|
1003
|
+
}
|
|
992
1004
|
}
|
|
993
1005
|
return parentVNode;
|
|
994
1006
|
};
|
|
@@ -1078,6 +1090,13 @@ var addSlottedNodes = (slottedNodes, slotNodeId, slotName, slotNode, hostId) =>
|
|
|
1078
1090
|
slottedNode = slottedNode.nextSibling;
|
|
1079
1091
|
}
|
|
1080
1092
|
};
|
|
1093
|
+
var findCorrespondingNode = (node, type) => {
|
|
1094
|
+
let sibling = node;
|
|
1095
|
+
do {
|
|
1096
|
+
sibling = sibling.nextSibling;
|
|
1097
|
+
} while (sibling && (sibling.nodeType !== type || !sibling.nodeValue));
|
|
1098
|
+
return sibling;
|
|
1099
|
+
};
|
|
1081
1100
|
var parsePropertyValue = (propValue, propType) => {
|
|
1082
1101
|
if (propValue != null && !isComplexType(propValue)) {
|
|
1083
1102
|
if (propType & 4 /* Boolean */) {
|
|
@@ -1177,7 +1196,7 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
|
|
|
1177
1196
|
styleContainerNode.append(styleElm);
|
|
1178
1197
|
}
|
|
1179
1198
|
}
|
|
1180
|
-
if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */
|
|
1199
|
+
if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) {
|
|
1181
1200
|
styleContainerNode.insertBefore(styleElm, null);
|
|
1182
1201
|
}
|
|
1183
1202
|
}
|
|
@@ -1202,13 +1221,21 @@ var attachStyles = (hostRef) => {
|
|
|
1202
1221
|
const scopeId2 = addStyle(
|
|
1203
1222
|
elm.shadowRoot ? elm.shadowRoot : elm.getRootNode(),
|
|
1204
1223
|
cmpMeta);
|
|
1205
|
-
if (flags & 10 /* needsScopedEncapsulation */ && flags & 2 /* scopedCssEncapsulation */) {
|
|
1224
|
+
if ((flags & 10 /* needsScopedEncapsulation */ && flags & 2 /* scopedCssEncapsulation */ || flags & 128 /* shadowNeedsScopedCss */)) {
|
|
1206
1225
|
elm["s-sc"] = scopeId2;
|
|
1207
1226
|
elm.classList.add(scopeId2 + "-h");
|
|
1208
1227
|
}
|
|
1209
1228
|
endAttachStyles();
|
|
1210
1229
|
};
|
|
1211
1230
|
var getScopeId = (cmp, mode) => "sc-" + (cmp.$tagName$);
|
|
1231
|
+
var convertScopedToShadow = (css) => css.replace(/\/\*!@([^\/]+)\*\/[^\{]+\{/g, "$1{");
|
|
1232
|
+
var hydrateScopedToShadow = () => {
|
|
1233
|
+
const styles2 = doc.querySelectorAll(`[${HYDRATED_STYLE_ID}]`);
|
|
1234
|
+
let i2 = 0;
|
|
1235
|
+
for (; i2 < styles2.length; i2++) {
|
|
1236
|
+
registerStyle(styles2[i2].getAttribute(HYDRATED_STYLE_ID), convertScopedToShadow(styles2[i2].innerHTML), true);
|
|
1237
|
+
}
|
|
1238
|
+
};
|
|
1212
1239
|
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRender) => {
|
|
1213
1240
|
if (oldValue !== newValue) {
|
|
1214
1241
|
let isProp = isMemberInElement(elm, memberName);
|
|
@@ -1735,13 +1762,13 @@ var insertBefore = (parent, newNode, reference) => {
|
|
|
1735
1762
|
}
|
|
1736
1763
|
};
|
|
1737
1764
|
function addRemoveSlotScopedClass(reference, slotNode, newParent, oldParent) {
|
|
1738
|
-
var _a;
|
|
1765
|
+
var _a, _b;
|
|
1739
1766
|
let scopeId2;
|
|
1740
1767
|
if (reference && typeof slotNode["s-sn"] === "string" && !!slotNode["s-sr"] && reference.parentNode && reference.parentNode["s-sc"] && (scopeId2 = slotNode["s-si"] || reference.parentNode["s-sc"])) {
|
|
1741
1768
|
const scopeName = slotNode["s-sn"];
|
|
1742
1769
|
const hostName = slotNode["s-hn"];
|
|
1743
1770
|
(_a = newParent.classList) == null ? void 0 : _a.add(scopeId2 + "-s");
|
|
1744
|
-
if (oldParent && oldParent.classList.contains(scopeId2 + "-s")) {
|
|
1771
|
+
if (oldParent && ((_b = oldParent.classList) == null ? void 0 : _b.contains(scopeId2 + "-s"))) {
|
|
1745
1772
|
let child = (oldParent.__childNodes || oldParent.childNodes)[0];
|
|
1746
1773
|
let found = false;
|
|
1747
1774
|
while (child) {
|
|
@@ -1782,7 +1809,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1782
1809
|
{
|
|
1783
1810
|
scopeId = hostElm["s-sc"];
|
|
1784
1811
|
}
|
|
1785
|
-
useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */)
|
|
1812
|
+
useNativeShadowDom = !!(cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) && !(cmpMeta.$flags$ & 128 /* shadowNeedsScopedCss */);
|
|
1786
1813
|
{
|
|
1787
1814
|
contentRef = hostElm["s-cr"];
|
|
1788
1815
|
checkSlotFallbackVisibility = false;
|
|
@@ -2004,9 +2031,6 @@ var postUpdateComponent = (hostRef) => {
|
|
|
2004
2031
|
}
|
|
2005
2032
|
};
|
|
2006
2033
|
var appDidLoad = (who) => {
|
|
2007
|
-
{
|
|
2008
|
-
addHydratedFlag(doc.documentElement);
|
|
2009
|
-
}
|
|
2010
2034
|
nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
|
|
2011
2035
|
};
|
|
2012
2036
|
var safeCall = (instance, method, arg, elm) => {
|
|
@@ -2206,7 +2230,8 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
2206
2230
|
let Cstr;
|
|
2207
2231
|
if ((hostRef.$flags$ & 32 /* hasInitializedComponent */) === 0) {
|
|
2208
2232
|
hostRef.$flags$ |= 32 /* hasInitializedComponent */;
|
|
2209
|
-
|
|
2233
|
+
const bundleId = cmpMeta.$lazyBundleId$;
|
|
2234
|
+
if (bundleId) {
|
|
2210
2235
|
const CstrImport = loadModule(cmpMeta, hostRef);
|
|
2211
2236
|
if (CstrImport && "then" in CstrImport) {
|
|
2212
2237
|
const endLoad = uniqueTime();
|
|
@@ -2242,6 +2267,10 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
2242
2267
|
}
|
|
2243
2268
|
endNewInstance();
|
|
2244
2269
|
fireConnectedCallback(hostRef.$lazyInstance$, elm);
|
|
2270
|
+
} else {
|
|
2271
|
+
Cstr = elm.constructor;
|
|
2272
|
+
const cmpTag = elm.localName;
|
|
2273
|
+
customElements.whenDefined(cmpTag).then(() => hostRef.$flags$ |= 128 /* isWatchReady */);
|
|
2245
2274
|
}
|
|
2246
2275
|
if (Cstr && Cstr.style) {
|
|
2247
2276
|
let style;
|
|
@@ -2383,6 +2412,9 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
2383
2412
|
{
|
|
2384
2413
|
plt.$flags$ |= 2 /* appLoaded */;
|
|
2385
2414
|
}
|
|
2415
|
+
{
|
|
2416
|
+
hydrateScopedToShadow();
|
|
2417
|
+
}
|
|
2386
2418
|
let hasSlotRelocation = false;
|
|
2387
2419
|
lazyBundles.map((lazyBundle) => {
|
|
2388
2420
|
lazyBundle[1].map((compactMeta) => {
|
|
@@ -2453,6 +2485,10 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
2453
2485
|
plt.raf(() => {
|
|
2454
2486
|
var _a3;
|
|
2455
2487
|
const hostRef = getHostRef(this);
|
|
2488
|
+
const i2 = deferredConnectedCallbacks.findIndex((host) => host === this);
|
|
2489
|
+
if (i2 > -1) {
|
|
2490
|
+
deferredConnectedCallbacks.splice(i2, 1);
|
|
2491
|
+
}
|
|
2456
2492
|
if (((_a3 = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a3.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {
|
|
2457
2493
|
delete hostRef.$vnode$.$elm$;
|
|
2458
2494
|
}
|
|
@@ -2538,4 +2574,4 @@ var setNonce = (nonce) => plt.$nonce$ = nonce;
|
|
|
2538
2574
|
|
|
2539
2575
|
export { Host as H, getElement as a, bootstrapLazy as b, createEvent as c, getAssetPath as g, h, promiseResolve as p, registerInstance as r, setNonce as s };
|
|
2540
2576
|
|
|
2541
|
-
//# sourceMappingURL=index-
|
|
2577
|
+
//# sourceMappingURL=index-4c1f5d1f.js.map
|