udp-stencil-component-library 1.0.2 → 1.0.3
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/add-map-feature-popup_4.cjs.entry.js +11 -11
- package/dist/cjs/advanced-search_50.cjs.entry.js +109 -41
- package/dist/cjs/advanced-search_50.cjs.entry.js.map +1 -1
- package/dist/cjs/ag-grid-base_2.cjs.entry.js +2 -2
- package/dist/cjs/api-method-grid.cjs.entry.js +1 -1
- package/dist/cjs/check-box.cjs.entry.js +2 -2
- package/dist/cjs/chip-section.cjs.entry.js +2 -2
- package/dist/cjs/client-side-grid.cjs.entry.js +1 -1
- package/dist/cjs/color-preview.cjs.entry.js +1 -1
- package/dist/cjs/date-time-renderer.file-upload-renderer.list-options-renderer.question-specific-configs-renderer.text-input-renderer.entry.cjs.js.map +1 -1
- package/dist/cjs/date-time-renderer_5.cjs.entry.js +17 -16
- package/dist/cjs/date-time-renderer_5.cjs.entry.js.map +1 -1
- package/dist/cjs/enums-CA1UjPVU.js +25 -0
- package/dist/cjs/enums-CA1UjPVU.js.map +1 -0
- package/dist/cjs/feature-details-card_2.cjs.entry.js +5 -5
- package/dist/cjs/file-upload.selectable-list.stencil-field.entry.cjs.js.map +1 -1
- package/dist/cjs/file-upload_3.cjs.entry.js +73 -29
- package/dist/cjs/file-upload_3.cjs.entry.js.map +1 -1
- package/dist/cjs/index-Bu1pSYrV.js +8 -8
- package/dist/cjs/inputs-example.cjs.entry.js +2 -2
- package/dist/cjs/inputs-example.cjs.entry.js.map +1 -1
- package/dist/cjs/inputs-example.entry.cjs.js.map +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/map-component_2.cjs.entry.js +2 -2
- package/dist/cjs/numeric-field.text-area.udp-date-selector.udp-datetime-selector.udp-time-selector.entry.cjs.js.map +1 -1
- package/dist/cjs/numeric-field_5.cjs.entry.js +194 -19
- package/dist/cjs/numeric-field_5.cjs.entry.js.map +1 -1
- package/dist/cjs/page-renderer.cjs.entry.js +1 -1
- package/dist/cjs/question-configs-renderer.section-configs-renderer.udp-forms-builder-menu.udp-forms-builder-question-item.udp-forms-builder-style-override.entry.cjs.js.map +1 -1
- package/dist/cjs/question-configs-renderer_5.cjs.entry.js +17 -4
- package/dist/cjs/question-configs-renderer_5.cjs.entry.js.map +1 -1
- package/dist/cjs/resource-timeline-calendar.cjs.entry.js +1 -1
- package/dist/cjs/resource-timeline-primary-bar.cjs.entry.js +1 -1
- package/dist/cjs/server-side-grid.cjs.entry.js +1 -1
- package/dist/cjs/signature-input.stencil-form.tally-display.udp-icon-button.udp-question.udp-save-draft-button.entry.cjs.js.map +1 -0
- package/dist/cjs/{signature-input_4.cjs.entry.js → signature-input_6.cjs.entry.js} +359 -157
- package/dist/cjs/signature-input_6.cjs.entry.js.map +1 -0
- package/dist/cjs/stencil-library.cjs.js +1 -1
- package/dist/cjs/udp-container-query-grid-item.cjs.entry.js +1 -1
- package/dist/cjs/udp-container-query-grid.cjs.entry.js +1 -1
- package/dist/cjs/udp-container-query.cjs.entry.js +2 -2
- package/dist/cjs/udp-container.cjs.entry.js +2 -2
- package/dist/cjs/udp-drive-utils-BOyI3h7K.js +180 -0
- package/dist/cjs/udp-drive-utils-BOyI3h7K.js.map +1 -0
- package/dist/cjs/udp-forms-builder.cjs.entry.js +133 -152
- package/dist/cjs/udp-forms-builder.cjs.entry.js.map +1 -1
- package/dist/cjs/udp-forms-builder.entry.cjs.js.map +1 -1
- package/dist/cjs/udp-forms-list-card_2.cjs.entry.js +5 -5
- package/dist/cjs/udp-forms-list.cjs.entry.js +1 -1
- package/dist/cjs/udp-forms-renderer.cjs.entry.js +185 -175
- package/dist/cjs/udp-forms-renderer.cjs.entry.js.map +1 -1
- package/dist/cjs/udp-forms-renderer.entry.cjs.js.map +1 -1
- package/dist/cjs/udp-forms-ui.cjs.entry.js +113 -82
- package/dist/cjs/udp-forms-ui.cjs.entry.js.map +1 -1
- package/dist/cjs/udp-forms-ui.entry.cjs.js.map +1 -1
- package/dist/cjs/udp-map.cjs.entry.js +3 -3
- package/dist/cjs/udp-page.cjs.entry.js +1 -1
- package/dist/cjs/udp-split-screen.cjs.entry.js +1 -1
- package/dist/cjs/udp-stepper-demo.cjs.entry.js +1 -1
- package/dist/cjs/udp-vertical-spacer.cjs.entry.js +1 -1
- package/dist/cjs/utils-CdiEmuDf.js +34 -0
- package/dist/cjs/utils-CdiEmuDf.js.map +1 -0
- package/dist/collection/collection-manifest.json +2 -0
- package/dist/collection/components/my-component/UI/buttons/icon-button/stencil-icon-button.js +22 -0
- package/dist/collection/components/my-component/UI/buttons/icon-button/stencil-icon-button.js.map +1 -1
- package/dist/collection/components/my-component/UI/buttons/udp-icon-button/udp-icon-button.css +269 -0
- package/dist/collection/components/my-component/UI/buttons/udp-icon-button/udp-icon-button.js +392 -0
- package/dist/collection/components/my-component/UI/buttons/udp-icon-button/udp-icon-button.js.map +1 -0
- package/dist/collection/components/my-component/UI/forms/form/stencil-field.js +38 -14
- package/dist/collection/components/my-component/UI/forms/form/stencil-field.js.map +1 -1
- package/dist/collection/components/my-component/UI/forms/form/stencil-form.js +81 -28
- package/dist/collection/components/my-component/UI/forms/form/stencil-form.js.map +1 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/mockData.js +1 -0
- package/dist/collection/components/my-component/UI/forms/udp-forms/mockData.js.map +1 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/types.js.map +1 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-builder/udp-forms-builder-item/question-specific-configs-renderer.js +13 -17
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-builder/udp-forms-builder-item/question-specific-configs-renderer.js.map +1 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-builder/udp-forms-builder-item/question_type_renderers/date-time-renderer.js +4 -3
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-builder/udp-forms-builder-item/question_type_renderers/date-time-renderer.js.map +1 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-builder/udp-forms-builder-item/question_type_renderers/section-configs-renderer.css +0 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-builder/udp-forms-builder-item/question_type_renderers/section-configs-renderer.js +16 -3
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-builder/udp-forms-builder-item/question_type_renderers/section-configs-renderer.js.map +1 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-builder/udp-forms-builder-item/question_type_renderers/text-input-renderer.js +2 -2
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-builder/udp-forms-builder.js +135 -159
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-builder/udp-forms-builder.js.map +1 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-list/udp-forms-list-card.js +5 -5
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-list/udp-forms-list.js +1 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/form-handler/PrivateFormHandler.js +1 -5
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/form-handler/PrivateFormHandler.js.map +1 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/form-handler/PublicFormHandler.js +1 -0
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/form-handler/PublicFormHandler.js.map +1 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/udp-forms-renderer.js +188 -172
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/udp-forms-renderer.js.map +1 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/udp-forms-ui.css +175 -0
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/udp-forms-ui.js +211 -88
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/udp-forms-ui.js.map +1 -1
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/udp-save-draft-button/udp-save-draft-button.css +166 -0
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/udp-save-draft-button/udp-save-draft-button.js +215 -0
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/udp-save-draft-button/udp-save-draft-button.js.map +1 -0
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-question/udp-question.js +5 -5
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-question/udp-question.js.map +1 -1
- package/dist/collection/components/my-component/UI/grid/ag-table/ag-table.js +1 -1
- package/dist/collection/components/my-component/UI/grid/ambient-template-grid/ambient-template-grid.js +15 -15
- package/dist/collection/components/my-component/UI/grid/grid-primary-bar/grid-primary-bar.js +2 -2
- package/dist/collection/components/my-component/UI/grid/hotlists/udp-hotlist-form/udp-hotlist-form.js +1 -1
- package/dist/collection/components/my-component/UI/grid/new-grid/ag-grid-base.js +1 -1
- package/dist/collection/components/my-component/UI/grid/new-grid/api-method-grid.js +1 -1
- package/dist/collection/components/my-component/UI/grid/new-grid/client-side-grid.js +1 -1
- package/dist/collection/components/my-component/UI/grid/new-grid/grid-header.js +1 -1
- package/dist/collection/components/my-component/UI/grid/new-grid/server-side-grid.js +1 -1
- package/dist/collection/components/my-component/UI/grid/resource-timeline-calendar/resource-timeline-calendar.js +1 -1
- package/dist/collection/components/my-component/UI/grid/resource-timeline-calendar/resource-timeline-primary-bar.js +1 -1
- package/dist/collection/components/my-component/UI/inputs/checkbox/check-box.js +2 -2
- package/dist/collection/components/my-component/UI/inputs/date-selector/udp-date-selector.js +3 -3
- package/dist/collection/components/my-component/UI/inputs/date-time-selector/udp-datetime-selector.js +3 -3
- package/dist/collection/components/my-component/UI/inputs/file-upload/file-upload.js +35 -22
- package/dist/collection/components/my-component/UI/inputs/file-upload/file-upload.js.map +1 -1
- package/dist/collection/components/my-component/UI/inputs/file-upload/udp-drive-utils.js +202 -10
- package/dist/collection/components/my-component/UI/inputs/file-upload/udp-drive-utils.js.map +1 -1
- package/dist/collection/components/my-component/UI/inputs/numeric-field/numeric-field.js +6 -6
- package/dist/collection/components/my-component/UI/inputs/numeric-field/numeric-field.js.map +1 -1
- package/dist/collection/components/my-component/UI/inputs/signature-input/signature-input.js +52 -22
- package/dist/collection/components/my-component/UI/inputs/signature-input/signature-input.js.map +1 -1
- package/dist/collection/components/my-component/UI/inputs/tally/tally.js +2 -2
- package/dist/collection/components/my-component/UI/inputs/text-area/text-area.js +99 -3
- package/dist/collection/components/my-component/UI/inputs/text-area/text-area.js.map +1 -1
- package/dist/collection/components/my-component/UI/inputs/text-field/text-field.js +99 -3
- package/dist/collection/components/my-component/UI/inputs/text-field/text-field.js.map +1 -1
- package/dist/collection/components/my-component/UI/inputs/time-selector/udp-time-selector.js +132 -6
- package/dist/collection/components/my-component/UI/inputs/time-selector/udp-time-selector.js.map +1 -1
- package/dist/collection/components/my-component/UI/inputs/toggle/stencil-toggle.js +4 -4
- package/dist/collection/components/my-component/UI/inputs/udp-selector/udp-selector.js +4 -4
- package/dist/collection/components/my-component/UI/layout/udp-container/udp-container.js +2 -2
- package/dist/collection/components/my-component/UI/layout/udp-container-query/udp-container-query.js +2 -2
- package/dist/collection/components/my-component/UI/layout/udp-container-query-grid/udp-container-query-grid.js +1 -1
- package/dist/collection/components/my-component/UI/layout/udp-container-query-grid-item/udp-container-query-grid-item.js +1 -1
- package/dist/collection/components/my-component/UI/layout/udp-page/udp-page.js +1 -1
- package/dist/collection/components/my-component/UI/layout/udp-split-screen/udp-split-screen.js +1 -1
- package/dist/collection/components/my-component/UI/layout/udp-vertical-spacer.js +1 -1
- package/dist/collection/components/my-component/UI/loaders/udp-grid-loader/udp-grid-loader.js +2 -2
- package/dist/collection/components/my-component/UI/loaders/udp-linear-loader/udp-linear-loader.js +1 -1
- package/dist/collection/components/my-component/UI/loaders/udp-skeleton-loading.js +1 -1
- package/dist/collection/components/my-component/UI/map/udp-map/map-component.js +1 -1
- package/dist/collection/components/my-component/UI/map/udp-map/popups/add-map-feature-popup.js +3 -3
- package/dist/collection/components/my-component/UI/map/udp-map/popups/feature-details-card/feature-details-card.js +4 -4
- package/dist/collection/components/my-component/UI/map/udp-map/popups/feature-details-popup.js +1 -1
- package/dist/collection/components/my-component/UI/map/udp-map/popups/select-layer-popup.js +1 -1
- package/dist/collection/components/my-component/UI/map/udp-map/popups/split-line-popup.js +1 -1
- package/dist/collection/components/my-component/UI/map/udp-map/toolbar/map-toolbar.js +6 -6
- package/dist/collection/components/my-component/UI/map/udp-map/udp-map-toolbar.js +1 -1
- package/dist/collection/components/my-component/UI/map/udp-map/udp-map.js +3 -3
- package/dist/collection/components/my-component/UI/menu/menu-item/udp-menu-item.js +2 -2
- package/dist/collection/components/my-component/UI/stepper/udp-stepper-demo.js +1 -1
- package/dist/collection/components/my-component/UI/tabs/tab/tabs/udp-tabs.js +1 -1
- package/dist/collection/components/my-component/UI/tabs/tab/udp-tab.js +1 -1
- package/dist/collection/components/my-component/UI/toolbars/app-bar/app-bar.js +1 -1
- package/dist/collection/components/my-component/demo/ambient-demo-container.js +1 -1
- package/dist/collection/components/test-component/inputs-example/inputs-example.js +2 -2
- package/dist/collection/components/test-component/inputs-example/inputs-example.js.map +1 -1
- package/dist/collection/page-renderer/page-renderer.js +1 -1
- package/dist/collection/theme/color-preview/color-preview.js +1 -1
- package/dist/collection/udp-utilities/layout/udp-dynamic-container-with-menu/chip-section/chip-section.js +2 -2
- package/dist/collection/udp-utilities/layout/udp-dynamic-container-with-menu/udp-dynamic-container-with-menu.js +1 -1
- package/dist/components/add-map-feature-popup.js +1 -1
- package/dist/components/advanced-search-grouped.js +1 -1
- package/dist/components/advanced-search.js +1 -1
- package/dist/components/ag-grid-base.js +1 -1
- package/dist/components/ag-table.js +1 -1
- package/dist/components/ambient-demo-container.js +1 -1
- package/dist/components/ambient-template-grid.js +1 -1
- package/dist/components/api-method-grid.js +4 -4
- package/dist/components/app-bar.js +1 -1
- package/dist/components/chart-container.js +1 -1
- package/dist/components/check-box-group.js +1 -1
- package/dist/components/check-box.js +1 -1
- package/dist/components/chip-section.js +3 -3
- package/dist/components/client-side-grid.js +3 -3
- package/dist/components/color-preview.js +1 -1
- package/dist/components/date-time-renderer.js +1 -1
- package/dist/components/edit-view-form-dialog.js +1 -1
- package/dist/components/feature-details-card.js +1 -1
- package/dist/components/feature-details-popup.js +1 -1
- package/dist/components/file-upload-renderer.js +1 -1
- package/dist/components/file-upload.js +1 -1
- package/dist/components/grid-header.js +1 -1
- package/dist/components/grid-primary-bar.js +1 -1
- package/dist/components/inputs-example.js +15 -15
- package/dist/components/inputs-example.js.map +1 -1
- package/dist/components/list-options-renderer.js +1 -1
- package/dist/components/map-component.js +1 -1
- package/dist/components/map-toolbar.js +1 -1
- package/dist/components/my-component.js +26 -26
- package/dist/components/numeric-field.js +1 -1
- package/dist/components/{p-CfZR5rek.js → p-0F2I6Qvn.js} +3 -3
- package/dist/components/{p-CfZR5rek.js.map → p-0F2I6Qvn.js.map} +1 -1
- package/dist/components/{p-BbC2Itep.js → p-1CPON0Xx.js} +5 -5
- package/dist/components/{p-BbC2Itep.js.map → p-1CPON0Xx.js.map} +1 -1
- package/dist/components/{p-IlXn87Ki.js → p-1Cv4cku0.js} +4 -14
- package/dist/components/p-1Cv4cku0.js.map +1 -0
- package/dist/components/{p-CTn3c76I.js → p-1uly65Sv.js} +3 -3
- package/dist/components/{p-CTn3c76I.js.map → p-1uly65Sv.js.map} +1 -1
- package/dist/components/{p-C8cWVxBF.js → p-26jyxB7s.js} +66 -27
- package/dist/components/p-26jyxB7s.js.map +1 -0
- package/dist/components/{p-GQEOUb0c.js → p-4hWvEEZf.js} +5 -5
- package/dist/components/{p-GQEOUb0c.js.map → p-4hWvEEZf.js.map} +1 -1
- package/dist/components/{p-HrsHnWeG.js → p-6EzLtNtq.js} +6 -6
- package/dist/components/{p-HrsHnWeG.js.map → p-6EzLtNtq.js.map} +1 -1
- package/dist/components/{p-syf9yo9-.js → p-8avkq8Fj.js} +4 -4
- package/dist/components/{p-syf9yo9-.js.map → p-8avkq8Fj.js.map} +1 -1
- package/dist/components/{p-B8k9GGZB.js → p-8paOuPay.js} +4 -4
- package/dist/components/{p-B8k9GGZB.js.map → p-8paOuPay.js.map} +1 -1
- package/dist/components/{p-DntePo7I.js → p-B2mj8zmp.js} +3 -3
- package/dist/components/{p-DntePo7I.js.map → p-B2mj8zmp.js.map} +1 -1
- package/dist/components/{p-Bv1MGbhE.js → p-B3gbGwCE.js} +50 -83
- package/dist/components/p-B3gbGwCE.js.map +1 -0
- package/dist/components/{p-ves_LtSN.js → p-B6A-djr0.js} +4 -4
- package/dist/components/{p-ves_LtSN.js.map → p-B6A-djr0.js.map} +1 -1
- package/dist/components/{p-D0T6NTw2.js → p-BANMRVyZ.js} +3 -3
- package/dist/components/{p-D0T6NTw2.js.map → p-BANMRVyZ.js.map} +1 -1
- package/dist/components/{p-D-JeGky8.js → p-BB2sALAW.js} +3 -3
- package/dist/components/{p-D-JeGky8.js.map → p-BB2sALAW.js.map} +1 -1
- package/dist/components/{p-DehJN46u.js → p-BLWvjl_b.js} +6 -6
- package/dist/components/{p-DehJN46u.js.map → p-BLWvjl_b.js.map} +1 -1
- package/dist/components/{p-y6ddPVSK.js → p-BO3Kzy6x.js} +6 -6
- package/dist/components/{p-y6ddPVSK.js.map → p-BO3Kzy6x.js.map} +1 -1
- package/dist/components/p-BY5RQ-T1.js +16 -0
- package/dist/components/p-BY5RQ-T1.js.map +1 -0
- package/dist/components/{p-ClToknIK.js → p-BbOHuqrJ.js} +5 -5
- package/dist/components/{p-ClToknIK.js.map → p-BbOHuqrJ.js.map} +1 -1
- package/dist/components/{p-CJsnV8uM.js → p-BfT3KUJC.js} +4 -4
- package/dist/components/{p-CJsnV8uM.js.map → p-BfT3KUJC.js.map} +1 -1
- package/dist/components/{p-BdWgc1UD.js → p-Bi8lqIP-.js} +8 -7
- package/dist/components/p-Bi8lqIP-.js.map +1 -0
- package/dist/components/{p-DNxY-i6k.js → p-BpD1NQKC.js} +5 -5
- package/dist/components/{p-DNxY-i6k.js.map → p-BpD1NQKC.js.map} +1 -1
- package/dist/components/p-BtOBW9_N.js +142 -0
- package/dist/components/p-BtOBW9_N.js.map +1 -0
- package/dist/components/{p-Akx0UDMW.js → p-BwPAbBUr.js} +4 -4
- package/dist/components/{p-Akx0UDMW.js.map → p-BwPAbBUr.js.map} +1 -1
- package/dist/components/p-BzH4NpB-.js +301 -0
- package/dist/components/p-BzH4NpB-.js.map +1 -0
- package/dist/components/{p-CSunqYw8.js → p-C-E6e6mL.js} +17 -17
- package/dist/components/{p-CSunqYw8.js.map → p-C-E6e6mL.js.map} +1 -1
- package/dist/components/{p-DWJbhjYR.js → p-C1K2NBql.js} +5 -5
- package/dist/components/{p-DWJbhjYR.js.map → p-C1K2NBql.js.map} +1 -1
- package/dist/components/{p-CNC3rtXm.js → p-C2j9tPIU.js} +4 -4
- package/dist/components/{p-CNC3rtXm.js.map → p-C2j9tPIU.js.map} +1 -1
- package/dist/components/p-C5aOw4Ij.js +168 -0
- package/dist/components/p-C5aOw4Ij.js.map +1 -0
- package/dist/components/{p-CJINZgmD.js → p-C6bm8Rs4.js} +17 -17
- package/dist/components/{p-CJINZgmD.js.map → p-C6bm8Rs4.js.map} +1 -1
- package/dist/components/{p-PqypuW_Q.js → p-CL4gkS6u.js} +22 -84
- package/dist/components/p-CL4gkS6u.js.map +1 -0
- package/dist/components/{p-DeS7YSzc.js → p-CMTLAuz8.js} +3 -3
- package/dist/components/{p-DeS7YSzc.js.map → p-CMTLAuz8.js.map} +1 -1
- package/dist/components/p-CWAWWTnd.js +47 -0
- package/dist/components/p-CWAWWTnd.js.map +1 -0
- package/dist/components/{p-B3-pcvgV.js → p-Cdz5sX_v.js} +38 -25
- package/dist/components/p-Cdz5sX_v.js.map +1 -0
- package/dist/components/{p-byKLubNE.js → p-Coa3kO6W.js} +3 -3
- package/dist/components/{p-byKLubNE.js.map → p-Coa3kO6W.js.map} +1 -1
- package/dist/components/{p-DzaN4l_Y.js → p-Cp1kbBGM.js} +5 -5
- package/dist/components/{p-DzaN4l_Y.js.map → p-Cp1kbBGM.js.map} +1 -1
- package/dist/components/{p-BYsLvu6g.js → p-CpMdhv3j.js} +69 -5
- package/dist/components/p-CpMdhv3j.js.map +1 -0
- package/dist/components/{p-BWI0GtPn.js → p-CpQin4NC.js} +7 -7
- package/dist/components/{p-BWI0GtPn.js.map → p-CpQin4NC.js.map} +1 -1
- package/dist/components/{p-DIPIddaO.js → p-CqiZ9SAU.js} +3 -3
- package/dist/components/{p-DIPIddaO.js.map → p-CqiZ9SAU.js.map} +1 -1
- package/dist/components/{p-DxJCXXmE.js → p-Cr_ifuX-.js} +27 -26
- package/dist/components/p-Cr_ifuX-.js.map +1 -0
- package/dist/components/{p-bLKTEsIH.js → p-CsMmUkoQ.js} +8 -8
- package/dist/components/{p-bLKTEsIH.js.map → p-CsMmUkoQ.js.map} +1 -1
- package/dist/components/{p-Cf-3pInV.js → p-Ct7EvUCI.js} +3 -3
- package/dist/components/{p-Cf-3pInV.js.map → p-Ct7EvUCI.js.map} +1 -1
- package/dist/components/{p-BbHv2Hzb.js → p-CvQ8X76F.js} +8 -8
- package/dist/components/{p-BbHv2Hzb.js.map → p-CvQ8X76F.js.map} +1 -1
- package/dist/components/{p-BEwTqpWE.js → p-CxOYMG-r.js} +4 -4
- package/dist/components/{p-BEwTqpWE.js.map → p-CxOYMG-r.js.map} +1 -1
- package/dist/components/{p-DOKGpXin.js → p-Cyigv-iT.js} +27 -8
- package/dist/components/p-Cyigv-iT.js.map +1 -0
- package/dist/components/{p-hRee3qYx.js → p-D6Wo7quX.js} +7 -2
- package/dist/components/p-D6Wo7quX.js.map +1 -0
- package/dist/components/{p-BUw3R0Ql.js → p-D9A5l8BE.js} +7 -7
- package/dist/components/{p-BUw3R0Ql.js.map → p-D9A5l8BE.js.map} +1 -1
- package/dist/components/{p-CDnOrzs3.js → p-DBtdo56U.js} +4 -4
- package/dist/components/{p-CDnOrzs3.js.map → p-DBtdo56U.js.map} +1 -1
- package/dist/components/{p-BIc3R4fE.js → p-DFKz-3Nr.js} +5 -5
- package/dist/components/{p-BIc3R4fE.js.map → p-DFKz-3Nr.js.map} +1 -1
- package/dist/components/{p-BJerffMg.js → p-DL9uHt-7.js} +5 -5
- package/dist/components/{p-BJerffMg.js.map → p-DL9uHt-7.js.map} +1 -1
- package/dist/components/{p-DIcPqQkn.js → p-DSIcWNUB.js} +5 -4
- package/dist/components/p-DSIcWNUB.js.map +1 -0
- package/dist/components/{p-CRiQA7Cy.js → p-DZaCCOXB.js} +69 -5
- package/dist/components/p-DZaCCOXB.js.map +1 -0
- package/dist/components/{p-BwHEv1Kb.js → p-DaMmzX_J.js} +13 -13
- package/dist/components/{p-BwHEv1Kb.js.map → p-DaMmzX_J.js.map} +1 -1
- package/dist/components/{p-CY0PAhIT.js → p-Dmmz74K2.js} +4 -4
- package/dist/components/{p-CY0PAhIT.js.map → p-Dmmz74K2.js.map} +1 -1
- package/dist/components/{p-DMcaGgHq.js → p-DnMRLbBX.js} +5 -5
- package/dist/components/{p-DMcaGgHq.js.map → p-DnMRLbBX.js.map} +1 -1
- package/dist/components/{p-ChdtzL8Z.js → p-Dpvhge5H.js} +10 -9
- package/dist/components/p-Dpvhge5H.js.map +1 -0
- package/dist/components/p-DtiAfg0X.js +25 -0
- package/dist/components/p-DtiAfg0X.js.map +1 -0
- package/dist/components/{p-XoXMxeuq.js → p-Dwnxv7WO.js} +3 -3
- package/dist/components/{p-XoXMxeuq.js.map → p-Dwnxv7WO.js.map} +1 -1
- package/dist/components/{p-BvSuY3tY.js → p-Dx5ehH3t.js} +7 -7
- package/dist/components/{p-BvSuY3tY.js.map → p-Dx5ehH3t.js.map} +1 -1
- package/dist/components/{p-DueJnVH4.js → p-DyC6jVV8.js} +10 -9
- package/dist/components/p-DyC6jVV8.js.map +1 -0
- package/dist/components/{p-Bdt-oOnd.js → p-Oil5iqFm.js} +120 -8
- package/dist/components/p-Oil5iqFm.js.map +1 -0
- package/dist/components/{p-C6aDnKNm.js → p-P3YTnOWe.js} +5 -5
- package/dist/components/{p-C6aDnKNm.js.map → p-P3YTnOWe.js.map} +1 -1
- package/dist/components/{p-CLvAjrtw.js → p-Qxi-zxd0.js} +8 -8
- package/dist/components/{p-CLvAjrtw.js.map → p-Qxi-zxd0.js.map} +1 -1
- package/dist/components/{p-DRO3I7Mm.js → p-Qxw1cxga.js} +8 -8
- package/dist/components/{p-DRO3I7Mm.js.map → p-Qxw1cxga.js.map} +1 -1
- package/dist/components/{p-DLWUrvpt.js → p-Tu9UB-v3.js} +5 -5
- package/dist/components/{p-DLWUrvpt.js.map → p-Tu9UB-v3.js.map} +1 -1
- package/dist/components/{p-DQIj9UI7.js → p-Ut5zP7nE.js} +5 -5
- package/dist/components/{p-DQIj9UI7.js.map → p-Ut5zP7nE.js.map} +1 -1
- package/dist/components/{p-Thx6k3Xp.js → p-WLd9SWLl.js} +4 -4
- package/dist/components/{p-Thx6k3Xp.js.map → p-WLd9SWLl.js.map} +1 -1
- package/dist/components/{p-BTIWOttf.js → p-W_kxEzVl.js} +6 -6
- package/dist/components/{p-BTIWOttf.js.map → p-W_kxEzVl.js.map} +1 -1
- package/dist/components/{p-BOW03S7b.js → p-XP8tp0pm.js} +5 -5
- package/dist/components/{p-BOW03S7b.js.map → p-XP8tp0pm.js.map} +1 -1
- package/dist/components/{p-w2FTnlQG.js → p-_HuUfybA.js} +3 -3
- package/dist/components/{p-w2FTnlQG.js.map → p-_HuUfybA.js.map} +1 -1
- package/dist/components/{p-BU706xtx.js → p-hWgAmNsF.js} +3 -3
- package/dist/components/{p-BU706xtx.js.map → p-hWgAmNsF.js.map} +1 -1
- package/dist/components/{p-Bykep8mm.js → p-ibwbE8nI.js} +4 -4
- package/dist/components/{p-Bykep8mm.js.map → p-ibwbE8nI.js.map} +1 -1
- package/dist/components/{p-CA-v1fbV.js → p-ill5r6eV.js} +40 -9
- package/dist/components/p-ill5r6eV.js.map +1 -0
- package/dist/components/{p-DqYsDDHy.js → p-jdqTpLxN.js} +4 -4
- package/dist/components/{p-DqYsDDHy.js.map → p-jdqTpLxN.js.map} +1 -1
- package/dist/components/{p-ByM88ZWk.js → p-jpt3zFdi.js} +3 -3
- package/dist/components/{p-ByM88ZWk.js.map → p-jpt3zFdi.js.map} +1 -1
- package/dist/components/{p-BEtm34A3.js → p-ncemY4Wx.js} +37 -36
- package/dist/components/p-ncemY4Wx.js.map +1 -0
- package/dist/components/{p-DqPGCQm2.js → p-s8qXxEgi.js} +3 -3
- package/dist/components/{p-DqPGCQm2.js.map → p-s8qXxEgi.js.map} +1 -1
- package/dist/components/p-vrP9HZiW.js +156 -0
- package/dist/components/p-vrP9HZiW.js.map +1 -0
- package/dist/components/{p-D32jPxWa.js → p-ycrk0Lr4.js} +5 -5
- package/dist/components/{p-D32jPxWa.js.map → p-ycrk0Lr4.js.map} +1 -1
- package/dist/components/page-renderer.js +21 -21
- package/dist/components/primary-action-header.js +1 -1
- package/dist/components/question-configs-renderer.js +1 -1
- package/dist/components/question-specific-configs-renderer.js +1 -1
- package/dist/components/resource-timeline-calendar.js +5 -5
- package/dist/components/resource-timeline-primary-bar.js +1 -1
- package/dist/components/save-view-form-dialog.js +1 -1
- package/dist/components/search-list-item.js +1 -1
- package/dist/components/section-configs-renderer.js +1 -1
- package/dist/components/select-layer-popup.js +1 -1
- package/dist/components/server-side-grid.js +1 -1
- package/dist/components/side-sheet.js +1 -1
- package/dist/components/signature-input.js +1 -1
- package/dist/components/split-line-popup.js +1 -1
- package/dist/components/stencil-field.js +1 -1
- package/dist/components/stencil-form.js +1 -1
- package/dist/components/stencil-icon-button.js +1 -1
- package/dist/components/stencil-toggle.js +1 -1
- package/dist/components/tally-display.js +1 -1
- package/dist/components/text-area.js +1 -1
- package/dist/components/text-field.js +1 -1
- package/dist/components/text-input-renderer.js +1 -1
- package/dist/components/udp-ambient-card.js +1 -1
- package/dist/components/udp-avatar.js +1 -1
- package/dist/components/udp-bar-chart.js +1 -1
- package/dist/components/udp-charts-example.js +7 -7
- package/dist/components/udp-container-query-grid-item.js +1 -1
- package/dist/components/udp-container-query-grid.js +2 -2
- package/dist/components/udp-container-query.js +1 -1
- package/dist/components/udp-container.js +1 -1
- package/dist/components/udp-date-selector.js +1 -1
- package/dist/components/udp-datetime-selector.js +1 -1
- package/dist/components/udp-distribution-chart.js +1 -1
- package/dist/components/udp-donut-chart.js +1 -1
- package/dist/components/udp-dynamic-container-with-menu.js +1 -1
- package/dist/components/udp-dynamic-form.js +4 -4
- package/dist/components/udp-forms-builder-menu.js +1 -1
- package/dist/components/udp-forms-builder-question-item.js +1 -1
- package/dist/components/udp-forms-builder-style-override.js +1 -1
- package/dist/components/udp-forms-builder.js +162 -183
- package/dist/components/udp-forms-builder.js.map +1 -1
- package/dist/components/udp-forms-list-card.js +1 -1
- package/dist/components/udp-forms-list.js +10 -10
- package/dist/components/udp-forms-renderer.js +244 -219
- package/dist/components/udp-forms-renderer.js.map +1 -1
- package/dist/components/udp-forms-ui.js +1 -1
- package/dist/components/udp-grid-loader.js +1 -1
- package/dist/components/udp-hotlist-form.js +1 -1
- package/dist/components/udp-icon-button.d.ts +11 -0
- package/dist/components/udp-icon-button.js +9 -0
- package/dist/components/udp-icon-button.js.map +1 -0
- package/dist/components/udp-icon.js +1 -1
- package/dist/components/udp-line-chart.js +1 -1
- package/dist/components/udp-linear-loader.js +1 -1
- package/dist/components/udp-list-item.js +2 -2
- package/dist/components/udp-map-toolbar.js +1 -1
- package/dist/components/udp-map.js +17 -17
- package/dist/components/udp-menu-item.js +1 -1
- package/dist/components/udp-page.js +1 -1
- package/dist/components/udp-question.js +1 -1
- package/dist/components/udp-save-draft-button.d.ts +11 -0
- package/dist/components/udp-save-draft-button.js +9 -0
- package/dist/components/udp-save-draft-button.js.map +1 -0
- package/dist/components/udp-selector.js +1 -1
- package/dist/components/udp-side-sheet.js +1 -1
- package/dist/components/udp-skeleton-loading.js +1 -1
- package/dist/components/udp-split-screen.js +1 -1
- package/dist/components/udp-stepper-demo.js +1 -1
- package/dist/components/udp-tab.js +1 -1
- package/dist/components/udp-tabs.js +1 -1
- package/dist/components/udp-time-selector.js +1 -1
- package/dist/components/udp-vertical-spacer.js +1 -1
- package/dist/esm/add-map-feature-popup_4.entry.js +11 -11
- package/dist/esm/advanced-search_50.entry.js +109 -41
- package/dist/esm/advanced-search_50.entry.js.map +1 -1
- package/dist/esm/ag-grid-base_2.entry.js +2 -2
- package/dist/esm/api-method-grid.entry.js +1 -1
- package/dist/esm/check-box.entry.js +2 -2
- package/dist/esm/chip-section.entry.js +2 -2
- package/dist/esm/client-side-grid.entry.js +1 -1
- package/dist/esm/color-preview.entry.js +1 -1
- package/dist/esm/date-time-renderer.file-upload-renderer.list-options-renderer.question-specific-configs-renderer.text-input-renderer.entry.js.map +1 -1
- package/dist/esm/date-time-renderer_5.entry.js +17 -16
- package/dist/esm/date-time-renderer_5.entry.js.map +1 -1
- package/dist/esm/enums-DtiAfg0X.js +25 -0
- package/dist/esm/enums-DtiAfg0X.js.map +1 -0
- package/dist/esm/feature-details-card_2.entry.js +5 -5
- package/dist/esm/file-upload.selectable-list.stencil-field.entry.js.map +1 -1
- package/dist/esm/file-upload_3.entry.js +73 -29
- package/dist/esm/file-upload_3.entry.js.map +1 -1
- package/dist/esm/index-CaIWDYyq.js +8 -8
- package/dist/esm/inputs-example.entry.js +2 -2
- package/dist/esm/inputs-example.entry.js.map +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/map-component_2.entry.js +2 -2
- package/dist/esm/numeric-field.text-area.udp-date-selector.udp-datetime-selector.udp-time-selector.entry.js.map +1 -1
- package/dist/esm/numeric-field_5.entry.js +195 -20
- package/dist/esm/numeric-field_5.entry.js.map +1 -1
- package/dist/esm/page-renderer.entry.js +1 -1
- package/dist/esm/question-configs-renderer.section-configs-renderer.udp-forms-builder-menu.udp-forms-builder-question-item.udp-forms-builder-style-override.entry.js.map +1 -1
- package/dist/esm/question-configs-renderer_5.entry.js +17 -4
- package/dist/esm/question-configs-renderer_5.entry.js.map +1 -1
- package/dist/esm/resource-timeline-calendar.entry.js +1 -1
- package/dist/esm/resource-timeline-primary-bar.entry.js +1 -1
- package/dist/esm/server-side-grid.entry.js +1 -1
- package/dist/esm/signature-input.stencil-form.tally-display.udp-icon-button.udp-question.udp-save-draft-button.entry.js.map +1 -0
- package/dist/esm/{signature-input_4.entry.js → signature-input_6.entry.js} +315 -115
- package/dist/esm/signature-input_6.entry.js.map +1 -0
- package/dist/esm/stencil-library.js +1 -1
- package/dist/esm/udp-container-query-grid-item.entry.js +1 -1
- package/dist/esm/udp-container-query-grid.entry.js +1 -1
- package/dist/esm/udp-container-query.entry.js +2 -2
- package/dist/esm/udp-container.entry.js +2 -2
- package/dist/esm/udp-drive-utils-Cm3Sms8t.js +168 -0
- package/dist/esm/udp-drive-utils-Cm3Sms8t.js.map +1 -0
- package/dist/esm/udp-forms-builder.entry.js +133 -152
- package/dist/esm/udp-forms-builder.entry.js.map +1 -1
- package/dist/esm/udp-forms-list-card_2.entry.js +5 -5
- package/dist/esm/udp-forms-list.entry.js +1 -1
- package/dist/esm/udp-forms-renderer.entry.js +186 -176
- package/dist/esm/udp-forms-renderer.entry.js.map +1 -1
- package/dist/esm/udp-forms-ui.entry.js +113 -82
- package/dist/esm/udp-forms-ui.entry.js.map +1 -1
- package/dist/esm/udp-map.entry.js +3 -3
- package/dist/esm/udp-page.entry.js +1 -1
- package/dist/esm/udp-split-screen.entry.js +1 -1
- package/dist/esm/udp-stepper-demo.entry.js +1 -1
- package/dist/esm/udp-vertical-spacer.entry.js +1 -1
- package/dist/esm/utils-DZv4MqyU.js +31 -0
- package/dist/esm/utils-DZv4MqyU.js.map +1 -0
- package/dist/stencil-library/date-time-renderer.file-upload-renderer.list-options-renderer.question-specific-configs-renderer.text-input-renderer.entry.esm.js.map +1 -1
- package/dist/stencil-library/file-upload.selectable-list.stencil-field.entry.esm.js.map +1 -1
- package/dist/stencil-library/inputs-example.entry.esm.js.map +1 -1
- package/dist/stencil-library/numeric-field.text-area.udp-date-selector.udp-datetime-selector.udp-time-selector.entry.esm.js.map +1 -1
- package/dist/stencil-library/p-09319660.entry.js +2 -0
- package/dist/stencil-library/p-09319660.entry.js.map +1 -0
- package/dist/stencil-library/p-146bc917.entry.js +2 -0
- package/dist/stencil-library/{p-b3b6310e.entry.js → p-147c4595.entry.js} +2 -2
- package/dist/stencil-library/{p-06ca29e0.entry.js → p-1b001f78.entry.js} +2 -2
- package/dist/stencil-library/{p-762591f6.entry.js → p-2635a6cc.entry.js} +2 -2
- package/dist/stencil-library/p-2f2fd111.entry.js +2 -0
- package/dist/stencil-library/{p-368be454.entry.js → p-2fc495ce.entry.js} +2 -2
- package/dist/stencil-library/{p-fdfa7087.entry.js → p-476c08df.entry.js} +2 -2
- package/dist/stencil-library/{p-ee1610d3.entry.js → p-4ab893a0.entry.js} +2 -2
- package/dist/stencil-library/p-4dac2b6d.entry.js +2 -0
- package/dist/stencil-library/p-4dac2b6d.entry.js.map +1 -0
- package/dist/stencil-library/p-556a182f.entry.js +2 -0
- package/dist/stencil-library/p-556a182f.entry.js.map +1 -0
- package/dist/stencil-library/p-5ac16f81.entry.js +2 -0
- package/dist/stencil-library/p-5ac16f81.entry.js.map +1 -0
- package/dist/stencil-library/p-609236fc.entry.js +2 -0
- package/dist/stencil-library/p-609236fc.entry.js.map +1 -0
- package/dist/stencil-library/{p-9b0b311b.entry.js → p-64330dbb.entry.js} +2 -2
- package/dist/stencil-library/p-65a5cce3.entry.js +2 -0
- package/dist/stencil-library/{p-5a946191.entry.js → p-70d8a0d8.entry.js} +2 -2
- package/dist/stencil-library/{p-79065768.entry.js → p-8119eb18.entry.js} +2 -2
- package/dist/stencil-library/{p-2f99476a.entry.js → p-86cd0134.entry.js} +2 -2
- package/dist/stencil-library/p-89aa56f1.entry.js +2 -0
- package/dist/stencil-library/p-89aa56f1.entry.js.map +1 -0
- package/dist/stencil-library/{p-767b7be7.entry.js → p-8a0b6bd4.entry.js} +2 -2
- package/dist/stencil-library/{p-40127f9f.entry.js → p-90fbca0f.entry.js} +2 -2
- package/dist/stencil-library/p-C5aOw4Ij.js +2 -0
- package/dist/stencil-library/p-C5aOw4Ij.js.map +1 -0
- package/dist/stencil-library/p-DZv4MqyU.js +2 -0
- package/dist/stencil-library/p-DZv4MqyU.js.map +1 -0
- package/dist/stencil-library/p-DtiAfg0X.js +2 -0
- package/dist/stencil-library/p-DtiAfg0X.js.map +1 -0
- package/dist/stencil-library/{p-f4f4ba61.entry.js → p-a98b033e.entry.js} +2 -2
- package/dist/stencil-library/p-a98b033e.entry.js.map +1 -0
- package/dist/stencil-library/{p-2a11c543.entry.js → p-ae167d4b.entry.js} +2 -2
- package/dist/stencil-library/{p-55459135.entry.js → p-b53e1b9a.entry.js} +2 -2
- package/dist/stencil-library/p-c1966f2c.entry.js +2 -0
- package/dist/stencil-library/p-c1966f2c.entry.js.map +1 -0
- package/dist/stencil-library/{p-0de6045a.entry.js → p-c9046d64.entry.js} +2 -2
- package/dist/stencil-library/{p-c1809ef3.entry.js → p-ca53be83.entry.js} +2 -2
- package/dist/stencil-library/p-d46dd16c.entry.js +2 -0
- package/dist/stencil-library/{p-09186dea.entry.js → p-d48b5599.entry.js} +2 -2
- package/dist/stencil-library/p-d4f31146.entry.js +2 -0
- package/dist/stencil-library/p-d4f31146.entry.js.map +1 -0
- package/dist/stencil-library/{p-b0b70c0b.entry.js → p-e7e8a8a3.entry.js} +2 -2
- package/dist/stencil-library/p-ea6e9a24.entry.js +2 -0
- package/dist/stencil-library/p-ea6e9a24.entry.js.map +1 -0
- package/dist/stencil-library/{p-79587009.entry.js → p-f4b5879d.entry.js} +2 -2
- package/dist/stencil-library/p-fbfbbcf1.entry.js +2 -0
- package/dist/stencil-library/question-configs-renderer.section-configs-renderer.udp-forms-builder-menu.udp-forms-builder-question-item.udp-forms-builder-style-override.entry.esm.js.map +1 -1
- package/dist/stencil-library/signature-input.stencil-form.tally-display.udp-icon-button.udp-question.udp-save-draft-button.entry.esm.js.map +1 -0
- package/dist/stencil-library/stencil-library.esm.js +1 -1
- package/dist/stencil-library/udp-forms-builder.entry.esm.js.map +1 -1
- package/dist/stencil-library/udp-forms-renderer.entry.esm.js.map +1 -1
- package/dist/stencil-library/udp-forms-ui.entry.esm.js.map +1 -1
- package/dist/types/components/my-component/UI/buttons/icon-button/stencil-icon-button.d.ts +14 -0
- package/dist/types/components/my-component/UI/buttons/udp-icon-button/udp-icon-button.d.ts +91 -0
- package/dist/types/components/my-component/UI/forms/form/stencil-field.d.ts +2 -1
- package/dist/types/components/my-component/UI/forms/form/stencil-form.d.ts +7 -5
- package/dist/types/components/my-component/UI/forms/udp-forms/types.d.ts +16 -0
- package/dist/types/components/my-component/UI/forms/udp-forms/udp-forms-builder/udp-forms-builder-item/question_type_renderers/section-configs-renderer.d.ts +1 -0
- package/dist/types/components/my-component/UI/forms/udp-forms/udp-forms-builder/udp-forms-builder.d.ts +16 -19
- package/dist/types/components/my-component/UI/forms/udp-forms/udp-forms-renderer/udp-forms-renderer.d.ts +14 -26
- package/dist/types/components/my-component/UI/forms/udp-forms/udp-forms-renderer/udp-forms-ui.d.ts +21 -7
- package/dist/types/components/my-component/UI/forms/udp-forms/udp-forms-renderer/udp-save-draft-button/udp-save-draft-button.d.ts +20 -0
- package/dist/types/components/my-component/UI/inputs/file-upload/file-upload.d.ts +1 -1
- package/dist/types/components/my-component/UI/inputs/file-upload/udp-drive-utils.d.ts +68 -1
- package/dist/types/components/my-component/UI/inputs/numeric-field/numeric-field.d.ts +1 -1
- package/dist/types/components/my-component/UI/inputs/signature-input/signature-input.d.ts +1 -1
- package/dist/types/components/my-component/UI/inputs/text-area/text-area.d.ts +21 -0
- package/dist/types/components/my-component/UI/inputs/text-field/text-field.d.ts +21 -0
- package/dist/types/components/my-component/UI/inputs/time-selector/udp-time-selector.d.ts +33 -1
- package/dist/types/components.d.ts +384 -14
- package/package.json +1 -1
- package/dist/cjs/signature-input.stencil-form.tally-display.udp-question.entry.cjs.js.map +0 -1
- package/dist/cjs/signature-input_4.cjs.entry.js.map +0 -1
- package/dist/cjs/utils-DMhqs00g.js +0 -55
- package/dist/cjs/utils-DMhqs00g.js.map +0 -1
- package/dist/collection/components/my-component/UI/forms/form/stencil-field.css +0 -70
- package/dist/collection/components/my-component/UI/forms/udp-forms/udp-forms-renderer/udp-forms-renderer.css +0 -89
- package/dist/components/p-B3-pcvgV.js.map +0 -1
- package/dist/components/p-BEtm34A3.js.map +0 -1
- package/dist/components/p-BYsLvu6g.js.map +0 -1
- package/dist/components/p-BdWgc1UD.js.map +0 -1
- package/dist/components/p-Bdt-oOnd.js.map +0 -1
- package/dist/components/p-Bv1MGbhE.js.map +0 -1
- package/dist/components/p-C8cWVxBF.js.map +0 -1
- package/dist/components/p-C9cEH65u.js +0 -307
- package/dist/components/p-C9cEH65u.js.map +0 -1
- package/dist/components/p-CA-v1fbV.js.map +0 -1
- package/dist/components/p-CRiQA7Cy.js.map +0 -1
- package/dist/components/p-ChdtzL8Z.js.map +0 -1
- package/dist/components/p-DIcPqQkn.js.map +0 -1
- package/dist/components/p-DOKGpXin.js.map +0 -1
- package/dist/components/p-DueJnVH4.js.map +0 -1
- package/dist/components/p-DxJCXXmE.js.map +0 -1
- package/dist/components/p-IlXn87Ki.js.map +0 -1
- package/dist/components/p-PqypuW_Q.js.map +0 -1
- package/dist/components/p-hRee3qYx.js.map +0 -1
- package/dist/esm/signature-input.stencil-form.tally-display.udp-question.entry.js.map +0 -1
- package/dist/esm/signature-input_4.entry.js.map +0 -1
- package/dist/esm/utils-vXSpJxEK.js +0 -52
- package/dist/esm/utils-vXSpJxEK.js.map +0 -1
- package/dist/stencil-library/p-00c1ce44.entry.js +0 -2
- package/dist/stencil-library/p-00c1ce44.entry.js.map +0 -1
- package/dist/stencil-library/p-250a8400.entry.js +0 -2
- package/dist/stencil-library/p-2fda98ee.entry.js +0 -2
- package/dist/stencil-library/p-2fda98ee.entry.js.map +0 -1
- package/dist/stencil-library/p-50f67815.entry.js +0 -2
- package/dist/stencil-library/p-50f67815.entry.js.map +0 -1
- package/dist/stencil-library/p-584552e6.entry.js +0 -2
- package/dist/stencil-library/p-5e96c57a.entry.js +0 -2
- package/dist/stencil-library/p-5e96c57a.entry.js.map +0 -1
- package/dist/stencil-library/p-6a1febc9.entry.js +0 -2
- package/dist/stencil-library/p-6ed5258c.entry.js +0 -2
- package/dist/stencil-library/p-6ed5258c.entry.js.map +0 -1
- package/dist/stencil-library/p-77739d4b.entry.js +0 -2
- package/dist/stencil-library/p-77739d4b.entry.js.map +0 -1
- package/dist/stencil-library/p-7a2202b9.entry.js +0 -2
- package/dist/stencil-library/p-7a2202b9.entry.js.map +0 -1
- package/dist/stencil-library/p-84109194.entry.js +0 -2
- package/dist/stencil-library/p-b1d412a7.entry.js +0 -2
- package/dist/stencil-library/p-b1d412a7.entry.js.map +0 -1
- package/dist/stencil-library/p-f4f4ba61.entry.js.map +0 -1
- package/dist/stencil-library/p-f7c855d0.entry.js +0 -2
- package/dist/stencil-library/p-f889438a.entry.js +0 -2
- package/dist/stencil-library/p-f889438a.entry.js.map +0 -1
- package/dist/stencil-library/p-vXSpJxEK.js +0 -2
- package/dist/stencil-library/p-vXSpJxEK.js.map +0 -1
- package/dist/stencil-library/signature-input.stencil-form.tally-display.udp-question.entry.esm.js.map +0 -1
- /package/dist/stencil-library/{p-84109194.entry.js.map → p-146bc917.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-b3b6310e.entry.js.map → p-147c4595.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-06ca29e0.entry.js.map → p-1b001f78.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-762591f6.entry.js.map → p-2635a6cc.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-6a1febc9.entry.js.map → p-2f2fd111.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-368be454.entry.js.map → p-2fc495ce.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-fdfa7087.entry.js.map → p-476c08df.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-ee1610d3.entry.js.map → p-4ab893a0.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-9b0b311b.entry.js.map → p-64330dbb.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-584552e6.entry.js.map → p-65a5cce3.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-5a946191.entry.js.map → p-70d8a0d8.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-79065768.entry.js.map → p-8119eb18.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-2f99476a.entry.js.map → p-86cd0134.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-767b7be7.entry.js.map → p-8a0b6bd4.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-40127f9f.entry.js.map → p-90fbca0f.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-2a11c543.entry.js.map → p-ae167d4b.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-55459135.entry.js.map → p-b53e1b9a.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-0de6045a.entry.js.map → p-c9046d64.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-c1809ef3.entry.js.map → p-ca53be83.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-f7c855d0.entry.js.map → p-d46dd16c.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-09186dea.entry.js.map → p-d48b5599.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-b0b70c0b.entry.js.map → p-e7e8a8a3.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-79587009.entry.js.map → p-f4b5879d.entry.js.map} +0 -0
- /package/dist/stencil-library/{p-250a8400.entry.js.map → p-fbfbbcf1.entry.js.map} +0 -0
|
@@ -70,6 +70,15 @@ export class TextField {
|
|
|
70
70
|
if (this.value !== undefined) {
|
|
71
71
|
this.value = newValue;
|
|
72
72
|
}
|
|
73
|
+
// Re-evaluate validation on input if there's currently an error
|
|
74
|
+
// This provides immediate feedback when user corrects the error
|
|
75
|
+
if (this.errorMessage) {
|
|
76
|
+
const validationError = this.validateCharacterLength(newValue);
|
|
77
|
+
if (validationError !== this.errorMessage) {
|
|
78
|
+
// Error state has changed, update it
|
|
79
|
+
this.setAndDispatchError(validationError);
|
|
80
|
+
}
|
|
81
|
+
}
|
|
73
82
|
};
|
|
74
83
|
/**
|
|
75
84
|
* Handles change events (committed changes on blur/enter). Emits change event.
|
|
@@ -81,6 +90,16 @@ export class TextField {
|
|
|
81
90
|
return;
|
|
82
91
|
}
|
|
83
92
|
const newValue = event.target.value;
|
|
93
|
+
// Validate the new value for character length constraints
|
|
94
|
+
const validationError = this.validateCharacterLength(newValue);
|
|
95
|
+
if (validationError) {
|
|
96
|
+
// Character length validation failed
|
|
97
|
+
this.setAndDispatchError(validationError);
|
|
98
|
+
}
|
|
99
|
+
else {
|
|
100
|
+
// Character length validation passed, clear any existing error
|
|
101
|
+
this.setAndDispatchError('');
|
|
102
|
+
}
|
|
84
103
|
// Emit change event when user finishes editing (blur, enter, etc.)
|
|
85
104
|
this.change.emit(newValue);
|
|
86
105
|
};
|
|
@@ -114,6 +133,41 @@ export class TextField {
|
|
|
114
133
|
this.internalValue = this.value;
|
|
115
134
|
}
|
|
116
135
|
}
|
|
136
|
+
/**
|
|
137
|
+
* Validates the text value against min/max character constraints
|
|
138
|
+
* @param value - The text value to validate
|
|
139
|
+
* @returns Error message if invalid, empty string if valid
|
|
140
|
+
*/
|
|
141
|
+
validateCharacterLength(value) {
|
|
142
|
+
if (!value)
|
|
143
|
+
return '';
|
|
144
|
+
const length = value.length;
|
|
145
|
+
if (this.minCharacter && length < this.minCharacter) {
|
|
146
|
+
return `Must be at least ${this.minCharacter} characters`;
|
|
147
|
+
}
|
|
148
|
+
if (this.maxCharacter && length > this.maxCharacter) {
|
|
149
|
+
return `Must be no more than ${this.maxCharacter} characters`;
|
|
150
|
+
}
|
|
151
|
+
return '';
|
|
152
|
+
}
|
|
153
|
+
/**
|
|
154
|
+
* Sets error state and dispatches error event that bubbles to stencil-field
|
|
155
|
+
* @param errorMessage - The error message to set and dispatch
|
|
156
|
+
*/
|
|
157
|
+
setAndDispatchError(errorMessage) {
|
|
158
|
+
console.log('Setting text field error:', errorMessage);
|
|
159
|
+
// Update internal error state
|
|
160
|
+
this.errorMessage = errorMessage;
|
|
161
|
+
// Emit Stencil error event
|
|
162
|
+
this.errorEvent.emit(errorMessage);
|
|
163
|
+
// Dispatch custom error event that bubbles up to stencil-field
|
|
164
|
+
const errorEvent = new CustomEvent('error', {
|
|
165
|
+
detail: errorMessage,
|
|
166
|
+
bubbles: true,
|
|
167
|
+
composed: true
|
|
168
|
+
});
|
|
169
|
+
this.el.dispatchEvent(errorEvent);
|
|
170
|
+
}
|
|
117
171
|
/**
|
|
118
172
|
* Component lifecycle method. Initializes error message and internal value.
|
|
119
173
|
* @internal
|
|
@@ -125,6 +179,13 @@ export class TextField {
|
|
|
125
179
|
}
|
|
126
180
|
// Initialize value: use value prop if provided (controlled), otherwise use initialValue (uncontrolled)
|
|
127
181
|
this.internalValue = this.value !== undefined ? this.value : (this.initialValue || '');
|
|
182
|
+
// Validate the initial value
|
|
183
|
+
if (this.internalValue) {
|
|
184
|
+
const validationError = this.validateCharacterLength(this.internalValue);
|
|
185
|
+
if (validationError) {
|
|
186
|
+
this.setAndDispatchError(validationError);
|
|
187
|
+
}
|
|
188
|
+
}
|
|
128
189
|
}
|
|
129
190
|
render() {
|
|
130
191
|
const isError = !!this.errorMessage;
|
|
@@ -134,7 +195,7 @@ export class TextField {
|
|
|
134
195
|
'bx--text-input:user-invalid': isError,
|
|
135
196
|
'text-field--disabled': this.disabled,
|
|
136
197
|
};
|
|
137
|
-
return (h(Host, { key: '
|
|
198
|
+
return (h(Host, { key: '4c97f1b312bfacd447bc14bf3c28542a64829d57', class: {
|
|
138
199
|
'udp-input': true,
|
|
139
200
|
'udp-input--error': isError,
|
|
140
201
|
'udp-input--disabled': this.disabled,
|
|
@@ -142,9 +203,9 @@ export class TextField {
|
|
|
142
203
|
'udp-input--required': this.required,
|
|
143
204
|
[`udp-input--size-${this.size}`]: true,
|
|
144
205
|
[`udp-input--margin-${this.margin}`]: true,
|
|
145
|
-
}, "aria-invalid": isError ? 'true' : 'false', "aria-required": this.required ? 'true' : 'false' }, h("div", { key: '
|
|
206
|
+
}, "aria-invalid": isError ? 'true' : 'false', "aria-required": this.required ? 'true' : 'false' }, h("div", { key: '71ce2d0d6564b5bb0689839616bd7197361ffeb6', class: "bx--form-item" }, h("unity-typography", { key: '7f1a7a034239aa9c69cd970d959f35e74f7111e8', variant: "caption-text" }, h("label", { key: 'c62a431b8e86c6803cc574f196c785a67ee853af', htmlFor: this.id, class: "bx--label" }, this.label, this.required ? '*' : '')), this.hidden ? (h("input", { id: this.id, type: "hidden", value: this.internalValue })) : (h("input", { id: this.id, type: "text", class: Object.assign({}, inputClass), placeholder: this.placeholder, value: this.internalValue, required: this.required, disabled: this.disabled, readonly: this.readonly, maxLength: this.maxCharacter, inputMode: this.inputMode, onInput: this.onInput, onChange: this.onChange,
|
|
146
207
|
//@ts-ignore
|
|
147
|
-
udprecordid: 'udpRecord-text-field-' + this.id })), isError && (h("div", { key: '
|
|
208
|
+
udprecordid: 'udpRecord-text-field-' + this.id })), isError && (h("div", { key: '7f5c9cac452884047569840e6620044c4d544c65', class: "error-message" }, h("unity-typography", { key: '61c3877f867c8a6751483c402f45132a289b84c2', variant: "caption-text", color: "error" }, this.errorMessage))))));
|
|
148
209
|
}
|
|
149
210
|
static get is() { return "text-field"; }
|
|
150
211
|
static get encapsulation() { return "shadow"; }
|
|
@@ -274,6 +335,25 @@ export class TextField {
|
|
|
274
335
|
"setter": false,
|
|
275
336
|
"reflect": false
|
|
276
337
|
},
|
|
338
|
+
"minCharacter": {
|
|
339
|
+
"type": "number",
|
|
340
|
+
"attribute": "min-character",
|
|
341
|
+
"mutable": false,
|
|
342
|
+
"complexType": {
|
|
343
|
+
"original": "number",
|
|
344
|
+
"resolved": "number",
|
|
345
|
+
"references": {}
|
|
346
|
+
},
|
|
347
|
+
"required": false,
|
|
348
|
+
"optional": false,
|
|
349
|
+
"docs": {
|
|
350
|
+
"tags": [],
|
|
351
|
+
"text": "Minimum number of characters required in the input. Enforces minimum character limits."
|
|
352
|
+
},
|
|
353
|
+
"getter": false,
|
|
354
|
+
"setter": false,
|
|
355
|
+
"reflect": false
|
|
356
|
+
},
|
|
277
357
|
"maxCharacter": {
|
|
278
358
|
"type": "number",
|
|
279
359
|
"attribute": "max-character",
|
|
@@ -474,8 +554,24 @@ export class TextField {
|
|
|
474
554
|
"resolved": "string",
|
|
475
555
|
"references": {}
|
|
476
556
|
}
|
|
557
|
+
}, {
|
|
558
|
+
"method": "errorEvent",
|
|
559
|
+
"name": "error",
|
|
560
|
+
"bubbles": true,
|
|
561
|
+
"cancelable": true,
|
|
562
|
+
"composed": true,
|
|
563
|
+
"docs": {
|
|
564
|
+
"tags": [],
|
|
565
|
+
"text": "Emitted when validation errors occur (e.g., character length outside min/max constraints).\nContains the error message string. Empty string indicates no error."
|
|
566
|
+
},
|
|
567
|
+
"complexType": {
|
|
568
|
+
"original": "string",
|
|
569
|
+
"resolved": "string",
|
|
570
|
+
"references": {}
|
|
571
|
+
}
|
|
477
572
|
}];
|
|
478
573
|
}
|
|
574
|
+
static get elementRef() { return "el"; }
|
|
479
575
|
static get watchers() {
|
|
480
576
|
return [{
|
|
481
577
|
"propName": "error",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-field.js","sourceRoot":"","sources":["../../../../../../src/components/my-component/UI/inputs/text-field/text-field.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,IAAI,EACJ,KAAK,EACL,KAAK,EACL,KAAK,GAEN,MAAM,eAAe,CAAC;AAGvB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAMH,MAAM,OAAO,SAAS;IALtB;QA0DE;;WAEG;QACK,UAAK,GAAW,EAAE,CAAC;QAQ3B;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {\n Component,\n Prop,\n h,\n Host,\n State,\n Watch,\n Event,\n EventEmitter,\n} from '@stencil/core';\nimport { InputSize, InputMargin } from '../input-types';\n\n/**\n * A standardized text input field component with error handling, validation, and custom styling.\n * Supports both controlled and uncontrolled modes with proper event emission for integration\n * with form libraries and custom event handlers.\n *\n * @example\n * ```tsx\n * // Uncontrolled component with initial value\n * <text-field\n * placeholder=\"Enter your name\"\n * initialValue=\"John Doe\"\n * onChange={(e) => console.log('Final value:', e.detail)}\n * />\n *\n * // Controlled component\n * <text-field\n * placeholder=\"Enter your name\"\n * value={nameValue}\n * onChange={(e) => setNameValue(e.detail)}\n * />\n *\n * // With validation and error handling\n * <text-field\n * label=\"Email Address\"\n * placeholder=\"user@example.com\"\n * required={true}\n * error={emailError}\n * value={email}\n * onChange={handleEmailChange}\n * />\n * ```\n */\n@Component({\n tag: 'text-field',\n styleUrl: 'text-field.css',\n shadow: true,\n})\nexport class TextField {\n /**\n * Unique identifier for the input element. Used for form association and accessibility.\n */\n @Prop() id: string;\n\n /**\n * Label text displayed above the input field. Used for accessibility and user guidance.\n */\n @Prop() label: string;\n\n /**\n * Placeholder text shown when the input is empty. Provides hints about expected input format.\n */\n @Prop() placeholder: string;\n\n /**\n * Whether the field is required for form submission. Adds visual indicator (*) and validation.\n */\n @Prop() required: boolean;\n\n /**\n * Whether the field is read-only. Users can see the value but cannot modify it.\n */\n @Prop() readonly: boolean;\n\n /**\n * Whether the field is disabled. Users cannot interact with the field.\n */\n @Prop() disabled: boolean;\n\n /**\n * Maximum number of characters allowed in the input. Enforces character limits.\n */\n @Prop() maxCharacter: number;\n\n /**\n * Current value of the input field. When provided, makes this a controlled component.\n * The component will use this value and update it through events.\n */\n @Prop({ mutable: true }) value: string;\n\n /**\n * Initial value for the input field. Used for uncontrolled components to set the default value.\n * Only used when `value` prop is not provided.\n */\n @Prop() initialValue: string;\n\n /**\n * Whether the field should be hidden from display while maintaining form functionality.\n */\n @Prop() hidden: boolean;\n\n /**\n * Error message to display below the input field. Shows validation errors or other issues.\n */\n @Prop() error: string = '';\n\n /**\n * Input mode hint for mobile keyboards. Optimizes keyboard layout for specific input types.\n * Common values: 'text', 'email', 'tel', 'url', 'numeric', 'decimal', 'search'\n */\n @Prop() inputMode: string;\n\n /**\n * Size variant controlling the padding and spacing of the input.\n * - 'small': Compact spacing for data-heavy interfaces\n * - 'normal': Standard spacing (default)\n * - 'large': Generous spacing for accessibility\n */\n @Prop() size: InputSize = 'normal';\n\n /**\n * Margin variant for the input spacing.\n * - 'none': No margin\n * - 'dense': Minimal margin spacing\n * - 'normal': Standard margin spacing (default)\n */\n @Prop() margin: InputMargin = 'normal';\n\n /**\n * Internal error message state. Manages display of validation errors.\n * @internal\n */\n @State() errorMessage: string;\n\n /**\n * Internal value state. Manages the current input value independently of props.\n * @internal\n */\n @State() internalValue: string;\n\n /**\n * Emitted when the text field value changes (on blur, enter, etc.).\n * Provides the final committed value when user finishes editing.\n *\n * @event change\n * @param {string} value - The current value of the text field\n *\n * @example\n * ```tsx\n * <text-field onChange={(e) => handleValueChange(e.detail)} />\n * ```\n */\n @Event() change: EventEmitter<string>;\n\n /**\n * Updates the error message when the error prop changes.\n * @internal\n */\n @Watch('error')\n updateError() {\n this.errorMessage = this.error;\n }\n\n /**\n * Updates the internal value when initialValue prop changes.\n * Only updates if current value is empty to avoid overriding user input.\n * @internal\n */\n @Watch('initialValue')\n updateInitialValue() {\n // Only update if we don't have a value yet or if explicitly resetting\n if (this.internalValue === '' || this.internalValue === undefined) {\n this.internalValue = this.initialValue || '';\n }\n }\n\n /**\n * Updates the internal value when value prop changes.\n * For controlled components, the value prop takes precedence.\n * @internal\n */\n @Watch('value')\n updateValue() {\n // If value prop is provided, this is a controlled component\n if (this.value !== undefined) {\n this.internalValue = this.value;\n }\n }\n\n /**\n * Component lifecycle method. Initializes error message and internal value.\n * @internal\n */\n componentWillLoad() {\n // Initialize error message\n if (this.error) {\n this.errorMessage = this.error;\n }\n // Initialize value: use value prop if provided (controlled), otherwise use initialValue (uncontrolled)\n this.internalValue = this.value !== undefined ? this.value : (this.initialValue || '');\n }\n\n /**\n * Handles input events (real-time typing). Updates internal state and emits input event.\n * For controlled components, also updates the value prop.\n * @param event - The native input event\n * @internal\n */\n private onInput = (event: InputEvent) => {\n if (this.readonly) {\n // Prevent typing if the field is read-only\n const input = event.target as HTMLInputElement;\n input.value = this.internalValue;\n return;\n }\n const newValue = (event.target as HTMLInputElement).value;\n this.internalValue = newValue; // Update internal state\n\n // If this is a controlled component (value prop provided), update the value prop\n if (this.value !== undefined) {\n this.value = newValue;\n }\n }\n\n /**\n * Handles change events (committed changes on blur/enter). Emits change event.\n * @param event - The native change event\n * @internal\n */\n private onChange = (event: Event) => {\n if (this.readonly) {\n return;\n }\n const newValue = (event.target as HTMLInputElement).value;\n // Emit change event when user finishes editing (blur, enter, etc.)\n this.change.emit(newValue);\n }\n\n render() {\n const isError = !!this.errorMessage;\n\n const inputClass = {\n 'bx--text-input': true,\n 'bx--text-input--error': isError,\n 'bx--text-input:user-invalid': isError,\n 'text-field--disabled': this.disabled,\n };\n return (\n <Host\n class={{\n 'udp-input': true,\n 'udp-input--error': isError,\n 'udp-input--disabled': this.disabled,\n 'udp-input--readonly': this.readonly,\n 'udp-input--required': this.required,\n [`udp-input--size-${this.size}`]: true,\n [`udp-input--margin-${this.margin}`]: true,\n }}\n aria-invalid={isError ? 'true' : 'false'}\n aria-required={this.required ? 'true' : 'false'}\n >\n <div class=\"bx--form-item\">\n <unity-typography variant=\"caption-text\">\n <label htmlFor={this.id} class=\"bx--label\">\n {this.label}\n {this.required ? '*' : ''}\n </label>\n </unity-typography>\n {this.hidden ? (\n <input id={this.id} type=\"hidden\" value={this.internalValue} />\n ) : (\n <input\n id={this.id}\n type=\"text\"\n class={{ ...inputClass }}\n placeholder={this.placeholder}\n value={this.internalValue}\n required={this.required}\n disabled={this.disabled}\n readonly={this.readonly}\n maxLength={this.maxCharacter}\n inputMode={this.inputMode}\n onInput={this.onInput}\n onChange={this.onChange}\n //@ts-ignore\n udprecordid={'udpRecord-text-field-' + this.id}\n />\n )}\n {isError && (\n <div class=\"error-message\">\n <unity-typography variant=\"caption-text\" color=\"error\">{this.errorMessage}</unity-typography>\n </div>\n )}\n </div>\n </Host>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"text-field.js","sourceRoot":"","sources":["../../../../../../src/components/my-component/UI/inputs/text-field/text-field.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,IAAI,EACJ,KAAK,EACL,KAAK,EACL,KAAK,EAEL,OAAO,GACR,MAAM,eAAe,CAAC;AAGvB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAMH,MAAM,OAAO,SAAS;IALtB;QAiEE;;WAEG;QACK,UAAK,GAAW,EAAE,CAAC;QAQ3B;;;;;WAKG;QACK,SAAI,GAAc,QAAQ,CAAC;QAEnC;;;;;WAKG;QACK,WAAM,GAAgB,QAAQ,CAAC;QA0IvC;;;;;WAKG;QACK,YAAO,GAAG,CAAC,KAAiB,EAAE,EAAE;YACtC,IAAI,IAAI,CAAC,QAAQ,EAAE,CAAC;gBAClB,2CAA2C;gBAC3C,MAAM,KAAK,GAAG,KAAK,CAAC,MAA0B,CAAC;gBAC/C,KAAK,CAAC,KAAK,GAAG,IAAI,CAAC,aAAa,CAAC;gBACjC,OAAO;YACT,CAAC;YACD,MAAM,QAAQ,GAAI,KAAK,CAAC,MAA2B,CAAC,KAAK,CAAC;YAC1D,IAAI,CAAC,aAAa,GAAG,Q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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {\n Component,\n Prop,\n h,\n Host,\n State,\n Watch,\n Event,\n EventEmitter,\n Element,\n} from '@stencil/core';\nimport { InputSize, InputMargin } from '../input-types';\n\n/**\n * A standardized text input field component with error handling, validation, and custom styling.\n * Supports both controlled and uncontrolled modes with proper event emission for integration\n * with form libraries and custom event handlers.\n *\n * @example\n * ```tsx\n * // Uncontrolled component with initial value\n * <text-field\n * placeholder=\"Enter your name\"\n * initialValue=\"John Doe\"\n * onChange={(e) => console.log('Final value:', e.detail)}\n * />\n *\n * // Controlled component\n * <text-field\n * placeholder=\"Enter your name\"\n * value={nameValue}\n * onChange={(e) => setNameValue(e.detail)}\n * />\n *\n * // With validation and error handling\n * <text-field\n * label=\"Email Address\"\n * placeholder=\"user@example.com\"\n * required={true}\n * error={emailError}\n * value={email}\n * onChange={handleEmailChange}\n * />\n * ```\n */\n@Component({\n tag: 'text-field',\n styleUrl: 'text-field.css',\n shadow: true,\n})\nexport class TextField {\n @Element() el: HTMLElement;\n\n /**\n * Unique identifier for the input element. Used for form association and accessibility.\n */\n @Prop() id: string;\n\n /**\n * Label text displayed above the input field. Used for accessibility and user guidance.\n */\n @Prop() label: string;\n\n /**\n * Placeholder text shown when the input is empty. Provides hints about expected input format.\n */\n @Prop() placeholder: string;\n\n /**\n * Whether the field is required for form submission. Adds visual indicator (*) and validation.\n */\n @Prop() required: boolean;\n\n /**\n * Whether the field is read-only. Users can see the value but cannot modify it.\n */\n @Prop() readonly: boolean;\n\n /**\n * Whether the field is disabled. Users cannot interact with the field.\n */\n @Prop() disabled: boolean;\n\n /**\n * Minimum number of characters required in the input. Enforces minimum character limits.\n */\n @Prop() minCharacter: number;\n\n /**\n * Maximum number of characters allowed in the input. Enforces character limits.\n */\n @Prop() maxCharacter: number;\n\n /**\n * Current value of the input field. When provided, makes this a controlled component.\n * The component will use this value and update it through events.\n */\n @Prop({ mutable: true }) value: string;\n\n /**\n * Initial value for the input field. Used for uncontrolled components to set the default value.\n * Only used when `value` prop is not provided.\n */\n @Prop() initialValue: string;\n\n /**\n * Whether the field should be hidden from display while maintaining form functionality.\n */\n @Prop() hidden: boolean;\n\n /**\n * Error message to display below the input field. Shows validation errors or other issues.\n */\n @Prop() error: string = '';\n\n /**\n * Input mode hint for mobile keyboards. Optimizes keyboard layout for specific input types.\n * Common values: 'text', 'email', 'tel', 'url', 'numeric', 'decimal', 'search'\n */\n @Prop() inputMode: string;\n\n /**\n * Size variant controlling the padding and spacing of the input.\n * - 'small': Compact spacing for data-heavy interfaces\n * - 'normal': Standard spacing (default)\n * - 'large': Generous spacing for accessibility\n */\n @Prop() size: InputSize = 'normal';\n\n /**\n * Margin variant for the input spacing.\n * - 'none': No margin\n * - 'dense': Minimal margin spacing\n * - 'normal': Standard margin spacing (default)\n */\n @Prop() margin: InputMargin = 'normal';\n\n /**\n * Internal error message state. Manages display of validation errors.\n * @internal\n */\n @State() errorMessage: string;\n\n /**\n * Internal value state. Manages the current input value independently of props.\n * @internal\n */\n @State() internalValue: string;\n\n /**\n * Emitted when the text field value changes (on blur, enter, etc.).\n * Provides the final committed value when user finishes editing.\n *\n * @event change\n * @param {string} value - The current value of the text field\n *\n * @example\n * ```tsx\n * <text-field onChange={(e) => handleValueChange(e.detail)} />\n * ```\n */\n @Event() change: EventEmitter<string>;\n\n /**\n * Emitted when validation errors occur (e.g., character length outside min/max constraints).\n * Contains the error message string. Empty string indicates no error.\n */\n @Event({\n eventName: 'error',\n bubbles: true,\n composed: true,\n cancelable: true\n }) errorEvent: EventEmitter<string>;\n\n /**\n * Updates the error message when the error prop changes.\n * @internal\n */\n @Watch('error')\n updateError() {\n this.errorMessage = this.error;\n }\n\n /**\n * Updates the internal value when initialValue prop changes.\n * Only updates if current value is empty to avoid overriding user input.\n * @internal\n */\n @Watch('initialValue')\n updateInitialValue() {\n // Only update if we don't have a value yet or if explicitly resetting\n if (this.internalValue === '' || this.internalValue === undefined) {\n this.internalValue = this.initialValue || '';\n }\n }\n\n /**\n * Updates the internal value when value prop changes.\n * For controlled components, the value prop takes precedence.\n * @internal\n */\n @Watch('value')\n updateValue() {\n // If value prop is provided, this is a controlled component\n if (this.value !== undefined) {\n this.internalValue = this.value;\n }\n }\n\n /**\n * Validates the text value against min/max character constraints\n * @param value - The text value to validate\n * @returns Error message if invalid, empty string if valid\n */\n private validateCharacterLength(value: string): string {\n if (!value) return '';\n\n const length = value.length;\n\n if (this.minCharacter && length < this.minCharacter) {\n return `Must be at least ${this.minCharacter} characters`;\n }\n\n if (this.maxCharacter && length > this.maxCharacter) {\n return `Must be no more than ${this.maxCharacter} characters`;\n }\n\n return '';\n }\n\n /**\n * Sets error state and dispatches error event that bubbles to stencil-field\n * @param errorMessage - The error message to set and dispatch\n */\n private setAndDispatchError(errorMessage: string) {\n console.log('Setting text field error:', errorMessage);\n\n // Update internal error state\n this.errorMessage = errorMessage;\n\n // Emit Stencil error event\n this.errorEvent.emit(errorMessage);\n\n // Dispatch custom error event that bubbles up to stencil-field\n const errorEvent = new CustomEvent('error', {\n detail: errorMessage,\n bubbles: true,\n composed: true\n });\n this.el.dispatchEvent(errorEvent);\n }\n\n /**\n * Component lifecycle method. Initializes error message and internal value.\n * @internal\n */\n componentWillLoad() {\n // Initialize error message\n if (this.error) {\n this.errorMessage = this.error;\n }\n // Initialize value: use value prop if provided (controlled), otherwise use initialValue (uncontrolled)\n this.internalValue = this.value !== undefined ? this.value : (this.initialValue || '');\n\n // Validate the initial value\n if (this.internalValue) {\n const validationError = this.validateCharacterLength(this.internalValue);\n if (validationError) {\n this.setAndDispatchError(validationError);\n }\n }\n }\n\n /**\n * Handles input events (real-time typing). Updates internal state and emits input event.\n * For controlled components, also updates the value prop.\n * @param event - The native input event\n * @internal\n */\n private onInput = (event: InputEvent) => {\n if (this.readonly) {\n // Prevent typing if the field is read-only\n const input = event.target as HTMLInputElement;\n input.value = this.internalValue;\n return;\n }\n const newValue = (event.target as HTMLInputElement).value;\n this.internalValue = newValue; // Update internal state\n\n // If this is a controlled component (value prop provided), update the value prop\n if (this.value !== undefined) {\n this.value = newValue;\n }\n\n // Re-evaluate validation on input if there's currently an error\n // This provides immediate feedback when user corrects the error\n if (this.errorMessage) {\n const validationError = this.validateCharacterLength(newValue);\n\n if (validationError !== this.errorMessage) {\n // Error state has changed, update it\n this.setAndDispatchError(validationError);\n }\n }\n }\n\n /**\n * Handles change events (committed changes on blur/enter). Emits change event.\n * @param event - The native change event\n * @internal\n */\n private onChange = (event: Event) => {\n if (this.readonly) {\n return;\n }\n const newValue = (event.target as HTMLInputElement).value;\n\n // Validate the new value for character length constraints\n const validationError = this.validateCharacterLength(newValue);\n\n if (validationError) {\n // Character length validation failed\n this.setAndDispatchError(validationError);\n } else {\n // Character length validation passed, clear any existing error\n this.setAndDispatchError('');\n }\n\n // Emit change event when user finishes editing (blur, enter, etc.)\n this.change.emit(newValue);\n }\n\n render() {\n const isError = !!this.errorMessage;\n\n const inputClass = {\n 'bx--text-input': true,\n 'bx--text-input--error': isError,\n 'bx--text-input:user-invalid': isError,\n 'text-field--disabled': this.disabled,\n };\n return (\n <Host\n class={{\n 'udp-input': true,\n 'udp-input--error': isError,\n 'udp-input--disabled': this.disabled,\n 'udp-input--readonly': this.readonly,\n 'udp-input--required': this.required,\n [`udp-input--size-${this.size}`]: true,\n [`udp-input--margin-${this.margin}`]: true,\n }}\n aria-invalid={isError ? 'true' : 'false'}\n aria-required={this.required ? 'true' : 'false'}\n >\n <div class=\"bx--form-item\">\n <unity-typography variant=\"caption-text\">\n <label htmlFor={this.id} class=\"bx--label\">\n {this.label}\n {this.required ? '*' : ''}\n </label>\n </unity-typography>\n {this.hidden ? (\n <input id={this.id} type=\"hidden\" value={this.internalValue} />\n ) : (\n <input\n id={this.id}\n type=\"text\"\n class={{ ...inputClass }}\n placeholder={this.placeholder}\n value={this.internalValue}\n required={this.required}\n disabled={this.disabled}\n readonly={this.readonly}\n maxLength={this.maxCharacter}\n inputMode={this.inputMode}\n onInput={this.onInput}\n onChange={this.onChange}\n //@ts-ignore\n udprecordid={'udpRecord-text-field-' + this.id}\n />\n )}\n {isError && (\n <div class=\"error-message\">\n <unity-typography variant=\"caption-text\" color=\"error\">{this.errorMessage}</unity-typography>\n </div>\n )}\n </div>\n </Host>\n );\n }\n}\n"]}
|
package/dist/collection/components/my-component/UI/inputs/time-selector/udp-time-selector.js
CHANGED
|
@@ -68,9 +68,60 @@ export class UdpTimeSelector {
|
|
|
68
68
|
this.margin = 'normal';
|
|
69
69
|
this.internalValue = ''; // Internal state for value management
|
|
70
70
|
/**
|
|
71
|
-
* Handles
|
|
71
|
+
* Handles the invalid event from the native input element
|
|
72
|
+
* @param event - The invalid event from the time input
|
|
73
|
+
*/
|
|
74
|
+
this.handleInvalid = (event) => {
|
|
75
|
+
const target = event.target;
|
|
76
|
+
const validationMessage = target.validationMessage;
|
|
77
|
+
this.setAndDispatchError(validationMessage);
|
|
78
|
+
};
|
|
79
|
+
/**
|
|
80
|
+
* Handles when the input becomes valid (clears errors)
|
|
81
|
+
* @param event - The input event
|
|
82
|
+
*/
|
|
83
|
+
this.handleValid = (event) => {
|
|
84
|
+
const target = event.target;
|
|
85
|
+
// Always validate with our custom logic first
|
|
86
|
+
const customError = this.validateTime(target.value);
|
|
87
|
+
if (customError) {
|
|
88
|
+
// Custom validation failed
|
|
89
|
+
this.setAndDispatchError(customError);
|
|
90
|
+
}
|
|
91
|
+
else if (target.validity.valid) {
|
|
92
|
+
// Both custom and native validation passed
|
|
93
|
+
this.setAndDispatchError('');
|
|
94
|
+
}
|
|
95
|
+
};
|
|
96
|
+
/**
|
|
97
|
+
* Handles input events (real-time typing). Updates internal state and provides immediate validation feedback.
|
|
72
98
|
* @param event - The input event from the time input
|
|
73
99
|
*/
|
|
100
|
+
this.handleTimeInput = (event) => {
|
|
101
|
+
const target = event.target;
|
|
102
|
+
const newValue = target.value;
|
|
103
|
+
// Update internal value
|
|
104
|
+
this.internalValue = newValue;
|
|
105
|
+
// Update controlled value if this is a controlled component
|
|
106
|
+
if (this.value !== undefined) {
|
|
107
|
+
this.value = newValue;
|
|
108
|
+
}
|
|
109
|
+
// Re-evaluate validation on input if there's currently an error
|
|
110
|
+
// This provides immediate feedback when user corrects the error
|
|
111
|
+
if (this.errorMessage) {
|
|
112
|
+
const validationError = this.validateTime(newValue);
|
|
113
|
+
if (validationError !== this.errorMessage) {
|
|
114
|
+
// Error state has changed, update it
|
|
115
|
+
this.setAndDispatchError(validationError);
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
// Emit input event for real-time updates
|
|
119
|
+
this.input.emit(newValue);
|
|
120
|
+
};
|
|
121
|
+
/**
|
|
122
|
+
* Handles changes to the time input value. Updates internal state and emits standard events.
|
|
123
|
+
* @param event - The change event from the time input
|
|
124
|
+
*/
|
|
74
125
|
this.handleTimeChange = (event) => {
|
|
75
126
|
const target = event.target;
|
|
76
127
|
const newValue = target.value;
|
|
@@ -80,9 +131,18 @@ export class UdpTimeSelector {
|
|
|
80
131
|
if (this.value !== undefined) {
|
|
81
132
|
this.value = newValue;
|
|
82
133
|
}
|
|
83
|
-
//
|
|
134
|
+
// Validate the new value
|
|
135
|
+
const customError = this.validateTime(newValue);
|
|
136
|
+
if (customError) {
|
|
137
|
+
// Custom validation failed
|
|
138
|
+
this.setAndDispatchError(customError);
|
|
139
|
+
}
|
|
140
|
+
else {
|
|
141
|
+
// Custom validation passed, clear any existing error
|
|
142
|
+
this.setAndDispatchError('');
|
|
143
|
+
}
|
|
144
|
+
// Emit change event for committed changes
|
|
84
145
|
this.change.emit(newValue);
|
|
85
|
-
this.input.emit(newValue);
|
|
86
146
|
};
|
|
87
147
|
}
|
|
88
148
|
/**
|
|
@@ -98,6 +158,7 @@ export class UdpTimeSelector {
|
|
|
98
158
|
* Watcher for the error prop. Updates the internal error message when the error prop changes.
|
|
99
159
|
*/
|
|
100
160
|
updateError() {
|
|
161
|
+
console.log('Error prop changed:', this.error);
|
|
101
162
|
this.errorMessage = this.error;
|
|
102
163
|
}
|
|
103
164
|
/**
|
|
@@ -108,6 +169,9 @@ export class UdpTimeSelector {
|
|
|
108
169
|
initialValueChanged(newValue) {
|
|
109
170
|
if (newValue !== undefined) {
|
|
110
171
|
this.internalValue = newValue;
|
|
172
|
+
const newError = this.validateTime(newValue);
|
|
173
|
+
if (newError)
|
|
174
|
+
this.setAndDispatchError(newError);
|
|
111
175
|
}
|
|
112
176
|
}
|
|
113
177
|
/**
|
|
@@ -132,6 +196,52 @@ export class UdpTimeSelector {
|
|
|
132
196
|
handleFocus() {
|
|
133
197
|
// Standard focus events bubble naturally - no custom emission needed
|
|
134
198
|
}
|
|
199
|
+
/**
|
|
200
|
+
* Validates the time value against min/max constraints
|
|
201
|
+
* @param value - The time value to validate
|
|
202
|
+
* @returns Error message if invalid, empty string if valid
|
|
203
|
+
*/
|
|
204
|
+
validateTime(value) {
|
|
205
|
+
if (!value)
|
|
206
|
+
return '';
|
|
207
|
+
// Convert time strings to minutes for comparison
|
|
208
|
+
const timeToMinutes = (time) => {
|
|
209
|
+
const [hours, minutes] = time.split(':').map(Number);
|
|
210
|
+
return hours * 60 + minutes;
|
|
211
|
+
};
|
|
212
|
+
const valueMinutes = timeToMinutes(value);
|
|
213
|
+
if (this.min) {
|
|
214
|
+
const minMinutes = timeToMinutes(this.min);
|
|
215
|
+
if (valueMinutes < minMinutes) {
|
|
216
|
+
return `Time must be after ${this.min}`;
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
if (this.max) {
|
|
220
|
+
const maxMinutes = timeToMinutes(this.max);
|
|
221
|
+
if (valueMinutes > maxMinutes) {
|
|
222
|
+
return `Time must be before ${this.max}`;
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
return '';
|
|
226
|
+
}
|
|
227
|
+
/**
|
|
228
|
+
* Sets error state and dispatches error event that bubbles to stencil-field
|
|
229
|
+
* @param errorMessage - The error message to set and dispatch
|
|
230
|
+
*/
|
|
231
|
+
setAndDispatchError(errorMessage) {
|
|
232
|
+
console.log('Setting error:', errorMessage);
|
|
233
|
+
// Update internal error state
|
|
234
|
+
this.errorMessage = errorMessage;
|
|
235
|
+
// Emit Stencil error event
|
|
236
|
+
this.errorEvent.emit(errorMessage);
|
|
237
|
+
// Dispatch custom error event that bubbles up to stencil-field
|
|
238
|
+
const errorEvent = new CustomEvent('error', {
|
|
239
|
+
detail: errorMessage,
|
|
240
|
+
bubbles: true,
|
|
241
|
+
composed: true
|
|
242
|
+
});
|
|
243
|
+
this.el.dispatchEvent(errorEvent);
|
|
244
|
+
}
|
|
135
245
|
render() {
|
|
136
246
|
const isError = !!this.errorMessage;
|
|
137
247
|
const classNames = ['bx--text-input'];
|
|
@@ -145,7 +255,7 @@ export class UdpTimeSelector {
|
|
|
145
255
|
classNames.push('bx--text-input--full-width');
|
|
146
256
|
}
|
|
147
257
|
const inputClass = classNames.join(' ');
|
|
148
|
-
return (h(Host, { key: '
|
|
258
|
+
return (h(Host, { key: '1205a25d9e0373114297d342b9ab0cbd285c51e2', class: {
|
|
149
259
|
'udp-input': true,
|
|
150
260
|
'udp-input--error': isError,
|
|
151
261
|
'udp-input--disabled': this.disabled,
|
|
@@ -154,9 +264,9 @@ export class UdpTimeSelector {
|
|
|
154
264
|
'udp-input--required': this.required,
|
|
155
265
|
[`udp-input--size-${this.size}`]: true,
|
|
156
266
|
[`udp-input--margin-${this.margin}`]: true,
|
|
157
|
-
}, "aria-invalid": isError ? 'true' : 'false', "aria-required": this.required ? 'true' : 'false' }, h("div", { key: '
|
|
267
|
+
}, "aria-invalid": isError ? 'true' : 'false', "aria-required": this.required ? 'true' : 'false' }, h("div", { key: 'b88a1cf0cccdf135fb40e86e0fbc4cf10847dec2', class: "bx--form-item" }, h("unity-typography", { key: '77c013fb01660898ad898db14ca04b51f6e07de0', variant: "caption-text" }, h("label", { key: '26721af45bf881a3daa594dd8ae018b8a98b39bc', htmlFor: this.id, class: "bx--label" }, this.label, this.required ? '*' : '')), h("input", { key: 'a51e49451c55e4ece0668078959a141d521d7773', type: "time", id: this.id, name: this.name, class: inputClass, value: this.internalValue, min: this.min, max: this.max, onInput: this.handleTimeInput, onChange: this.handleTimeChange, onBlur: this.handleBlur, onFocus: this.handleFocus, onInvalid: this.handleInvalid, disabled: this.disabled, readonly: this.readonly, required: this.required,
|
|
158
268
|
//@ts-ignore
|
|
159
|
-
udprecordid: 'udpRecord-udp-time-selector-' + this.id }), h("unity-typography", { key: '
|
|
269
|
+
udprecordid: 'udpRecord-udp-time-selector-' + this.id }), h("unity-typography", { key: '5171d4ca07938113cc781e605da2d60492e64008', class: "error-message", variant: "caption-text", color: "error" }, this.errorMessage))));
|
|
160
270
|
}
|
|
161
271
|
static get is() { return "udp-time-selector"; }
|
|
162
272
|
static get encapsulation() { return "shadow"; }
|
|
@@ -494,8 +604,24 @@ export class UdpTimeSelector {
|
|
|
494
604
|
"resolved": "string",
|
|
495
605
|
"references": {}
|
|
496
606
|
}
|
|
607
|
+
}, {
|
|
608
|
+
"method": "errorEvent",
|
|
609
|
+
"name": "error",
|
|
610
|
+
"bubbles": true,
|
|
611
|
+
"cancelable": true,
|
|
612
|
+
"composed": true,
|
|
613
|
+
"docs": {
|
|
614
|
+
"tags": [],
|
|
615
|
+
"text": "Emitted when validation errors occur (e.g., time outside min/max constraints).\nContains the error message string. Empty string indicates no error."
|
|
616
|
+
},
|
|
617
|
+
"complexType": {
|
|
618
|
+
"original": "string",
|
|
619
|
+
"resolved": "string",
|
|
620
|
+
"references": {}
|
|
621
|
+
}
|
|
497
622
|
}];
|
|
498
623
|
}
|
|
624
|
+
static get elementRef() { return "el"; }
|
|
499
625
|
static get watchers() {
|
|
500
626
|
return [{
|
|
501
627
|
"propName": "error",
|
package/dist/collection/components/my-component/UI/inputs/time-selector/udp-time-selector.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"udp-time-selector.js","sourceRoot":"","sources":["../../../../../../src/components/my-component/UI/inputs/time-selector/udp-time-selector.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAgB,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAG5F;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqCG;AAMH,MAAM,OAAO,eAAe;IAL5B;QAiDE;;;WAGG;QACsB,UAAK,GAAW,EAAE,CAAC;QAO5C;;WAEG;QACK,aAAQ,GAAY,KAAK,CAAC;QAElC;;WAEG;QACK,cAAS,GAAY,KAAK,CAAC;QAEnC;;;;;WAKG;QACK,SAAI,GAAc,QAAQ,CAAC;QAEnC;;;;;WAKG;QACK,WAAM,GAAgB,QAAQ,CAAC;QAE9B,kBAAa,GAAW,EAAE,CAAC,CAAC,sCAAsC;QAuE3E;;;WAGG;QACH,qBAAgB,GAAG,CAAC,KAAY,EAAE,EAAE;YAClC,MAAM,MAAM,GAAG,KAAK,CAAC,MAA0B,CAAC;YAChD,MAAM,QAAQ,GAAG,MAAM,CAAC,KAAK,CAAC;YAE9B,wBAAwB;YACxB,IAAI,CAAC,aAAa,GAAG,QAAQ,CAAC;YAE9B,4DAA4D;YAC5D,IAAI,IAAI,CAAC,KAAK,KAAK,SAAS,EAAE,CAAC;gBAC7B,IAAI,CAAC,KAAK,GAAG,QAAQ,CAAC;YACxB,CAAC;YAED,+EAA+E;YAC/E,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,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AAE,IAAI,CAAC,QAAQ,EACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ;oBACvB,YAAY;oBACZ,WAAW,EAAE,8BAA8B,GAAG,IAAI,CAAC,EAAE,GACrD;gBACF,yEAAkB,KAAK,EAAC,eAAe,EAAC,OAAO,EAAC,cAAc,EAAC,KAAK,EAAC,OAAO,IACzE,IAAI,CAAC,YAAY,CACD,CACf,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Host, State, Event, EventEmitter, Prop, Watch } from '@stencil/core';\nimport { InputSize, InputMargin } from '../input-types';\n\n/**\n * A standardized time input component with validation, min/max constraints, and precise time selection.\n * Supports both controlled and uncontrolled modes with proper event emission for integration\n * with form libraries and custom event handlers.\n *\n * **Time Handling:**\n * - Uses HTML5 `time` input for consistent browser behavior and native time picker\n * - Supports HH:mm format (24-hour time) as per HTML5 specification\n * - Provides min/max time constraints for validation\n *\n * @example\n * ```tsx\n * // Uncontrolled component with initial value\n * <udp-time-selector\n * label=\"Meeting Time\"\n * initialValue=\"14:30\"\n * onChange={(e) => console.log('Selected:', e.detail)}\n * />\n *\n * // Controlled component\n * <udp-time-selector\n * label=\"Appointment Time\"\n * value={appointmentTime}\n * onChange={(e) => setAppointmentTime(e.detail)}\n * />\n *\n * // With validation and constraints\n * <udp-time-selector\n * label=\"Business Hours\"\n * value={businessTime}\n * min=\"09:00\"\n * max=\"17:00\"\n * required={true}\n * error={timeError}\n * onChange={handleTimeChange}\n * />\n * ```\n */\n@Component({\n tag: 'udp-time-selector',\n styleUrl: 'udp-time-selector.css',\n shadow: true,\n})\nexport class UdpTimeSelector {\n /**\n * Unique identifier for the input element. Used for form association and accessibility.\n */\n @Prop() id: string;\n\n /**\n * Name attribute for the input element. Used for form submission.\n */\n @Prop() name: string;\n\n /**\n * Label text displayed above the input field. Used for accessibility and user guidance.\n */\n @Prop() label: string;\n\n /**\n * Minimum time value allowed. Uses HH:mm format (e.g., \"09:00\").\n * Enforces lower bounds validation for time selection.\n */\n @Prop() min: string;\n\n /**\n * Maximum time value allowed. Uses HH:mm format (e.g., \"17:00\").\n * Enforces upper bounds validation for time selection.\n */\n @Prop() max: string;\n\n /**\n * Whether the field is required for form submission. Adds visual indicator (*) and validation.\n */\n @Prop() required: boolean;\n\n /**\n * Error message to display below the input field. Shows validation errors or other issues.\n */\n @Prop() error: string;\n\n /**\n * Initial value for the time selector. Used for uncontrolled components to set the default value.\n * Uses HH:mm format (e.g., \"14:30\"). Only used when `value` prop is not provided.\n */\n @Prop() initialValue: string;\n\n /**\n * Current value of the time selector. When provided, makes this a controlled component.\n * Uses HH:mm format (e.g., \"14:30\"). The component will use this value and update it through events.\n */\n @Prop({ mutable: true }) value: string = '';\n\n /**\n * Whether the field is disabled. Users cannot interact with the field when disabled.\n */\n @Prop() disabled: boolean;\n\n /**\n * Whether the input is readonly.\n */\n @Prop() readonly: boolean = false;\n\n /**\n * Whether the input should take the full width of its container.\n */\n @Prop() fullWidth: boolean = false;\n\n /**\n * Size variant controlling the padding and spacing of the input.\n * - 'small': Compact spacing for data-heavy interfaces\n * - 'normal': Standard spacing (default)\n * - 'large': Generous spacing for accessibility\n */\n @Prop() size: InputSize = 'normal';\n\n /**\n * Margin variant for the input spacing.\n * - 'none': No margin\n * - 'dense': Minimal margin spacing\n * - 'normal': Standard margin spacing (default)\n */\n @Prop() margin: InputMargin = 'normal';\n\n @State() internalValue: string = ''; // Internal state for value management\n @State() errorMessage: string;\n\n /**\n * Emitted when the time value changes through user interaction or programmatic update.\n * Contains the new time value in HH:mm format.\n */\n @Event() change: EventEmitter<string>;\n\n /**\n * Emitted when the user types in the time input field.\n * Contains the current input value (may be incomplete during typing).\n */\n @Event() input: EventEmitter<string>;\n\n /**\n * Component lifecycle method called when the component is about to load.\n * Initializes the internal value from either the value prop or initialValue prop.\n */\n componentWillLoad() {\n // Initialize from controlled value or initial value\n this.internalValue = this.value || this.initialValue || '';\n this.errorMessage = this.error;\n }\n\n /**\n * Watcher for the error prop. Updates the internal error message when the error prop changes.\n */\n @Watch('error')\n updateError() {\n this.errorMessage = this.error;\n }\n\n /**\n * Watcher for the initialValue prop. Updates the internal value when initialValue changes\n * (useful for form resets, dynamic initial values, etc.).\n * @param newValue - The new initial value\n */\n @Watch('initialValue')\n initialValueChanged(newValue: string) {\n if (newValue !== undefined) {\n this.internalValue = newValue;\n }\n }\n\n /**\n * Watcher for the value prop. Updates the internal value when the value prop changes\n * (controlled component behavior).\n * @param newValue - The new controlled value\n */\n @Watch('value')\n valueChanged(newValue: string) {\n if (newValue !== undefined) {\n this.internalValue = newValue;\n }\n }\n\n /**\n * Handles the blur event on the time input. Standard focus events bubble naturally.\n */\n handleBlur() {\n // Standard focus events bubble naturally - no custom emission needed\n }\n\n /**\n * Handles the focus event on the time input. Standard focus events bubble naturally.\n */\n handleFocus() {\n // Standard focus events bubble naturally - no custom emission needed\n }\n\n /**\n * Handles changes to the time input value. Updates internal state and emits standard events.\n * @param event - The input event from the time input\n */\n handleTimeChange = (event: Event) => {\n const target = event.target as HTMLInputElement;\n const newValue = target.value;\n\n // Update internal value\n this.internalValue = newValue;\n\n // Update controlled value if this is a controlled component\n if (this.value !== undefined) {\n this.value = newValue;\n }\n\n // Emit standard events for integration with form libraries and custom handlers\n this.change.emit(newValue);\n this.input.emit(newValue);\n }\n\n render() {\n const isError: boolean = !!this.errorMessage;\n const classNames = ['bx--text-input'];\n if (isError) {\n classNames.push('bx--text-input--error');\n }\n if (this.disabled) {\n classNames.push('time-selector--disabled');\n }\n if (this.fullWidth) {\n classNames.push('bx--text-input--full-width');\n }\n const inputClass = classNames.join(' ');\n\n return (\n <Host\n class={{\n 'udp-input': true,\n 'udp-input--error': isError,\n 'udp-input--disabled': this.disabled,\n 'udp-input--readonly': this.readonly,\n 'udp-input--full-width': this.fullWidth,\n 'udp-input--required': this.required,\n [`udp-input--size-${this.size}`]: true,\n [`udp-input--margin-${this.margin}`]: true,\n }}\n aria-invalid={isError ? 'true' : 'false'}\n aria-required={this.required ? 'true' : 'false'}\n >\n <div class=\"bx--form-item\">\n <unity-typography variant=\"caption-text\">\n <label htmlFor={this.id} class=\"bx--label\">\n {this.label}\n {this.required ? '*' : ''}\n </label>\n </unity-typography>\n <input\n type=\"time\"\n id={this.id}\n name={this.name}\n class={inputClass}\n value={this.internalValue}\n min={this.min}\n max={this.max}\n onInput={this.handleTimeChange}\n onChange={this.handleTimeChange}\n onBlur={this.handleBlur}\n onFocus={this.handleFocus}\n disabled={this.disabled}\n readonly={this.readonly}\n required={this.required}\n //@ts-ignore\n udprecordid={'udpRecord-udp-time-selector-' + this.id}\n />\n <unity-typography class=\"error-message\" variant=\"caption-text\" color=\"error\">\n {this.errorMessage}\n </unity-typography>\n </div>\n </Host>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"udp-time-selector.js","sourceRoot":"","sources":["../../../../../../src/components/my-component/UI/inputs/time-selector/udp-time-selector.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAgB,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAGrG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqCG;AAMH,MAAM,OA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IAAI,CAAC,GAAG,EACb,GAAG,EAAE,IAAI,CAAC,GAAG,EACb,OAAO,EAAE,IAAI,CAAC,eAAe,EAC7B,QAAQ,EAAE,IAAI,CAAC,gBAAgB,EAC/B,MAAM,EAAE,IAAI,CAAC,UAAU,EACvB,OAAO,EAAE,IAAI,CAAC,WAAW,EACzB,SAAS,EAAE,IAAI,CAAC,aAAa,EAC7B,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ;oBACvB,YAAY;oBACZ,WAAW,EAAE,8BAA8B,GAAG,IAAI,CAAC,EAAE,GACrD;gBACF,yEAAkB,KAAK,EAAC,eAAe,EAAC,OAAO,EAAC,cAAc,EAAC,KAAK,EAAC,OAAO,IACzE,IAAI,CAAC,YAAY,CACD,CACf,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Host, State, Event, EventEmitter, Prop, Watch, Element } from '@stencil/core';\nimport { InputSize, InputMargin } from '../input-types';\n\n/**\n * A standardized time input component with validation, min/max constraints, and precise time selection.\n * Supports both controlled and uncontrolled modes with proper event emission for integration\n * with form libraries and custom event handlers.\n *\n * **Time Handling:**\n * - Uses HTML5 `time` input for consistent browser behavior and native time picker\n * - Supports HH:mm format (24-hour time) as per HTML5 specification\n * - Provides min/max time constraints for validation\n *\n * @example\n * ```tsx\n * // Uncontrolled component with initial value\n * <udp-time-selector\n * label=\"Meeting Time\"\n * initialValue=\"14:30\"\n * onChange={(e) => console.log('Selected:', e.detail)}\n * />\n *\n * // Controlled component\n * <udp-time-selector\n * label=\"Appointment Time\"\n * value={appointmentTime}\n * onChange={(e) => setAppointmentTime(e.detail)}\n * />\n *\n * // With validation and constraints\n * <udp-time-selector\n * label=\"Business Hours\"\n * value={businessTime}\n * min=\"09:00\"\n * max=\"17:00\"\n * required={true}\n * error={timeError}\n * onChange={handleTimeChange}\n * />\n * ```\n */\n@Component({\n tag: 'udp-time-selector',\n styleUrl: 'udp-time-selector.css',\n shadow: true,\n})\nexport class UdpTimeSelector {\n /**\n * Unique identifier for the input element. Used for form association and accessibility.\n */\n @Prop() id: string;\n\n /**\n * Name attribute for the input element. Used for form submission.\n */\n @Prop() name: string;\n\n /**\n * Label text displayed above the input field. Used for accessibility and user guidance.\n */\n @Prop() label: string;\n\n /**\n * Minimum time value allowed. Uses HH:mm format (e.g., \"09:00\").\n * Enforces lower bounds validation for time selection.\n */\n @Prop() min: string;\n\n /**\n * Maximum time value allowed. Uses HH:mm format (e.g., \"17:00\").\n * Enforces upper bounds validation for time selection.\n */\n @Prop() max: string;\n\n /**\n * Whether the field is required for form submission. Adds visual indicator (*) and validation.\n */\n @Prop() required: boolean;\n\n /**\n * Error message to display below the input field. Shows validation errors or other issues.\n */\n @Prop() error: string;\n\n /**\n * Initial value for the time selector. Used for uncontrolled components to set the default value.\n * Uses HH:mm format (e.g., \"14:30\"). Only used when `value` prop is not provided.\n */\n @Prop() initialValue: string;\n\n /**\n * Current value of the time selector. When provided, makes this a controlled component.\n * Uses HH:mm format (e.g., \"14:30\"). The component will use this value and update it through events.\n */\n @Prop({ mutable: true }) value: string = '';\n\n /**\n * Whether the field is disabled. Users cannot interact with the field when disabled.\n */\n @Prop() disabled: boolean;\n\n /**\n * Whether the input is readonly.\n */\n @Prop() readonly: boolean = false;\n\n /**\n * Whether the input should take the full width of its container.\n */\n @Prop() fullWidth: boolean = false;\n\n /**\n * Size variant controlling the padding and spacing of the input.\n * - 'small': Compact spacing for data-heavy interfaces\n * - 'normal': Standard spacing (default)\n * - 'large': Generous spacing for accessibility\n */\n @Prop() size: InputSize = 'normal';\n\n /**\n * Margin variant for the input spacing.\n * - 'none': No margin\n * - 'dense': Minimal margin spacing\n * - 'normal': Standard margin spacing (default)\n */\n @Prop() margin: InputMargin = 'normal';\n\n @Element() el: HTMLElement;\n\n @State() internalValue: string = ''; // Internal state for value management\n @State() errorMessage: string;\n\n /**\n * Emitted when the time value changes through user interaction or programmatic update.\n * Contains the new time value in HH:mm format.\n */\n @Event() change: EventEmitter<string>;\n\n /**\n * Emitted when the user types in the time input field.\n * Contains the current input value (may be incomplete during typing).\n */\n @Event() input: EventEmitter<string>;\n\n /**\n * Emitted when validation errors occur (e.g., time outside min/max constraints).\n * Contains the error message string. Empty string indicates no error.\n */\n @Event({\n eventName: 'error',\n bubbles: true,\n composed: true,\n cancelable: true\n }) errorEvent: EventEmitter<string>;\n\n /**\n * Component lifecycle method called when the component is about to load.\n * Initializes the internal value from either the value prop or initialValue prop.\n */\n componentWillLoad() {\n // Initialize from controlled value or initial value\n this.internalValue = this.value || this.initialValue || '';\n this.errorMessage = this.error;\n }\n\n /**\n * Watcher for the error prop. Updates the internal error message when the error prop changes.\n */\n @Watch('error')\n updateError() {\n console.log('Error prop changed:', this.error);\n this.errorMessage = this.error;\n }\n\n /**\n * Watcher for the initialValue prop. Updates the internal value when initialValue changes\n * (useful for form resets, dynamic initial values, etc.).\n * @param newValue - The new initial value\n */\n @Watch('initialValue')\n initialValueChanged(newValue: string) {\n if (newValue !== undefined) {\n this.internalValue = newValue;\n const newError = this.validateTime(newValue);\n if(newError) this.setAndDispatchError(newError);\n }\n }\n\n /**\n * Watcher for the value prop. Updates the internal value when the value prop changes\n * (controlled component behavior).\n * @param newValue - The new controlled value\n */\n @Watch('value')\n valueChanged(newValue: string) {\n if (newValue !== undefined) {\n this.internalValue = newValue;\n }\n }\n\n /**\n * Handles the blur event on the time input. Standard focus events bubble naturally.\n */\n handleBlur() {\n // Standard focus events bubble naturally - no custom emission needed\n }\n\n /**\n * Handles the focus event on the time input. Standard focus events bubble naturally.\n */\n handleFocus() {\n // Standard focus events bubble naturally - no custom emission needed\n }\n\n /**\n * Validates the time value against min/max constraints\n * @param value - The time value to validate\n * @returns Error message if invalid, empty string if valid\n */\n private validateTime(value: string): string {\n if (!value) return '';\n\n // Convert time strings to minutes for comparison\n const timeToMinutes = (time: string): number => {\n const [hours, minutes] = time.split(':').map(Number);\n return hours * 60 + minutes;\n };\n\n const valueMinutes = timeToMinutes(value);\n\n if (this.min) {\n const minMinutes = timeToMinutes(this.min);\n if (valueMinutes < minMinutes) {\n return `Time must be after ${this.min}`;\n }\n }\n\n if (this.max) {\n const maxMinutes = timeToMinutes(this.max);\n if (valueMinutes > maxMinutes) {\n return `Time must be before ${this.max}`;\n }\n }\n\n return '';\n }\n\n /**\n * Sets error state and dispatches error event that bubbles to stencil-field\n * @param errorMessage - The error message to set and dispatch\n */\n private setAndDispatchError(errorMessage: string) {\n console.log('Setting error:', errorMessage);\n\n // Update internal error state\n this.errorMessage = errorMessage;\n\n // Emit Stencil error event\n this.errorEvent.emit(errorMessage);\n\n // Dispatch custom error event that bubbles up to stencil-field\n const errorEvent = new CustomEvent('error', {\n detail: errorMessage,\n bubbles: true,\n composed: true\n });\n this.el.dispatchEvent(errorEvent);\n }\n\n /**\n * Handles the invalid event from the native input element\n * @param event - The invalid event from the time input\n */\n handleInvalid = (event: Event) => {\n const target = event.target as HTMLInputElement;\n const validationMessage = target.validationMessage;\n this.setAndDispatchError(validationMessage);\n }\n\n /**\n * Handles when the input becomes valid (clears errors)\n * @param event - The input event\n */\n handleValid = (event: Event) => {\n const target = event.target as HTMLInputElement;\n\n // Always validate with our custom logic first\n const customError = this.validateTime(target.value);\n\n if (customError) {\n // Custom validation failed\n this.setAndDispatchError(customError);\n } else if (target.validity.valid) {\n // Both custom and native validation passed\n this.setAndDispatchError('');\n }\n }\n\n /**\n * Handles input events (real-time typing). Updates internal state and provides immediate validation feedback.\n * @param event - The input event from the time input\n */\n handleTimeInput = (event: Event) => {\n const target = event.target as HTMLInputElement;\n const newValue = target.value;\n\n // Update internal value\n this.internalValue = newValue;\n\n // Update controlled value if this is a controlled component\n if (this.value !== undefined) {\n this.value = newValue;\n }\n\n // Re-evaluate validation on input if there's currently an error\n // This provides immediate feedback when user corrects the error\n if (this.errorMessage) {\n const validationError = this.validateTime(newValue);\n\n if (validationError !== this.errorMessage) {\n // Error state has changed, update it\n this.setAndDispatchError(validationError);\n }\n }\n\n // Emit input event for real-time updates\n this.input.emit(newValue);\n }\n\n /**\n * Handles changes to the time input value. Updates internal state and emits standard events.\n * @param event - The change event from the time input\n */\n handleTimeChange = (event: Event) => {\n const target = event.target as HTMLInputElement;\n const newValue = target.value;\n\n // Update internal value\n this.internalValue = newValue;\n\n // Update controlled value if this is a controlled component\n if (this.value !== undefined) {\n this.value = newValue;\n }\n\n // Validate the new value\n const customError = this.validateTime(newValue);\n\n if (customError) {\n // Custom validation failed\n this.setAndDispatchError(customError);\n } else {\n // Custom validation passed, clear any existing error\n this.setAndDispatchError('');\n }\n\n // Emit change event for committed changes\n this.change.emit(newValue);\n }\n\n render() {\n const isError: boolean = !!this.errorMessage;\n const classNames = ['bx--text-input'];\n if (isError) {\n classNames.push('bx--text-input--error');\n }\n if (this.disabled) {\n classNames.push('time-selector--disabled');\n }\n if (this.fullWidth) {\n classNames.push('bx--text-input--full-width');\n }\n const inputClass = classNames.join(' ');\n return (\n <Host\n class={{\n 'udp-input': true,\n 'udp-input--error': isError,\n 'udp-input--disabled': this.disabled,\n 'udp-input--readonly': this.readonly,\n 'udp-input--full-width': this.fullWidth,\n 'udp-input--required': this.required,\n [`udp-input--size-${this.size}`]: true,\n [`udp-input--margin-${this.margin}`]: true,\n }}\n aria-invalid={isError ? 'true' : 'false'}\n aria-required={this.required ? 'true' : 'false'}\n >\n <div class=\"bx--form-item\">\n <unity-typography variant=\"caption-text\">\n <label htmlFor={this.id} class=\"bx--label\">\n {this.label}\n {this.required ? '*' : ''}\n </label>\n </unity-typography>\n <input\n type=\"time\"\n id={this.id}\n name={this.name}\n class={inputClass}\n value={this.internalValue}\n min={this.min}\n max={this.max}\n onInput={this.handleTimeInput}\n onChange={this.handleTimeChange}\n onBlur={this.handleBlur}\n onFocus={this.handleFocus}\n onInvalid={this.handleInvalid}\n disabled={this.disabled}\n readonly={this.readonly}\n required={this.required}\n //@ts-ignore\n udprecordid={'udpRecord-udp-time-selector-' + this.id}\n />\n <unity-typography class=\"error-message\" variant=\"caption-text\" color=\"error\">\n {this.errorMessage}\n </unity-typography>\n </div>\n </Host>\n );\n }\n}\n"]}
|
|
@@ -158,16 +158,16 @@ export class StencilToggle {
|
|
|
158
158
|
const buttonId = `${baseId}-button`;
|
|
159
159
|
const labelId = `${baseId}-label`;
|
|
160
160
|
const isError = !!this.errorMessage;
|
|
161
|
-
const labelElement = this.label && (h("label", { key: '
|
|
162
|
-
const toggleElement = (h("div", { key: '
|
|
163
|
-
return (h(Host, { key: '
|
|
161
|
+
const labelElement = this.label && (h("label", { key: '5bab829756552a4ca27ad67089dbcb764bda2de1', id: labelId, class: `toggle-label label-${this.labelPosition}`, htmlFor: !this.disabled ? buttonId : undefined }, h("unity-typography", { key: '1f1f400380c31913441255264eb6d0af35e1c421', variant: "caption-text" }, this.label)));
|
|
162
|
+
const toggleElement = (h("div", { key: '6c54df6caf5b3f294cae26d2ca3615c7e1bb05cd', class: `toggle-container ${this.toggled ? 'toggled' : ''}` }, h("button", { key: 'e060117671835f2e6a47597a926a2f9512d4f8d7', id: buttonId, onClick: () => this.toggleButton(), disabled: this.disabled, "aria-checked": this.toggled.toString(), "aria-labelledby": labelId, role: "switch" }, h("span", { key: 'fcab0a5fd5bcf15e02a13fc160ceca872034eb69', class: "toggle-knob" }))));
|
|
163
|
+
return (h(Host, { key: '3f90cb01c6032b87310837aead982a41b0078bad', class: {
|
|
164
164
|
'udp-input': true,
|
|
165
165
|
'udp-input--error': isError,
|
|
166
166
|
'udp-input--disabled': this.disabled,
|
|
167
167
|
'udp-input--checked': this.toggled,
|
|
168
168
|
[`udp-input--margin-${this.margin}`]: true,
|
|
169
169
|
[`udp-input--size-${this.size}`]: true,
|
|
170
|
-
}, "aria-invalid": isError ? 'true' : 'false' }, h("div", { key: '
|
|
170
|
+
}, "aria-invalid": isError ? 'true' : 'false' }, h("div", { key: '14fbbb34b5dee8da92375cabd8ddb050772318a3', class: `toggle-wrapper position-${this.labelPosition}` }, this.labelPosition === 'left' && labelElement, toggleElement, this.labelPosition === 'right' && labelElement, this.labelPosition === 'bottom' && labelElement, this.errorMessage && h("div", { key: 'bdee0f654adb087590d9bcf45daf35d0ffe12bb6', class: "error-message" }, this.errorMessage))));
|
|
171
171
|
}
|
|
172
172
|
static get is() { return "stencil-toggle"; }
|
|
173
173
|
static get encapsulation() { return "shadow"; }
|
|
@@ -357,7 +357,7 @@ export class UdpSelector {
|
|
|
357
357
|
'focused': this.isOpen,
|
|
358
358
|
};
|
|
359
359
|
const hasSelection = this.multiSelect ? this.selectedOptions.length > 0 : !!this.selectedOption;
|
|
360
|
-
return (h(Host, { key: '
|
|
360
|
+
return (h(Host, { key: '29251dd9cf9059a19c3ee9cc2c2b03f57ad3e431', class: {
|
|
361
361
|
'udp-input': true,
|
|
362
362
|
'udp-selector': true,
|
|
363
363
|
'udp-input--error': isError,
|
|
@@ -367,9 +367,9 @@ export class UdpSelector {
|
|
|
367
367
|
'udp-input--large': this.large,
|
|
368
368
|
[`udp-input--size-${this.size}`]: true,
|
|
369
369
|
[`udp-input--margin-${this.margin}`]: true,
|
|
370
|
-
}, "aria-invalid": isError ? 'true' : 'false', "aria-required": this.required ? 'true' : 'false' }, h("div", { key: '
|
|
370
|
+
}, "aria-invalid": isError ? 'true' : 'false', "aria-required": this.required ? 'true' : 'false' }, h("div", { key: '308273e697814be1edf27d05022fbda9bb9287e7', class: "bx--form-item" }, this.label && (h("unity-typography", { key: '646f781c41b4ebb60eb8d6b08da033b70ce2e48c', variant: "caption-text" }, h("label", { key: 'a0bd9c00fda4e8048a7fe41cc510a5cf6a8ae8ff', htmlFor: this.id, class: "bx--label" }, this.label, this.required ? '*' : ''))), h("div", { key: '81ea44d8eed860aa6efa95e544e9a5ba6d929c14', class: "udp-selector__container" }, h("div", { key: 'b896d5d9c6235d95de68f743da2e923b70e619ce', class: selectedOptionClasses, onClick: () => this.toggleDropdown(), onBlur: this.handleBlur, tabindex: this.disabled || this.readonly ? '-1' : '0', role: "combobox", "aria-haspopup": "listbox", "aria-expanded": this.isOpen.toString(), id: 'udpRecord-udp-selector-' + this.id,
|
|
371
371
|
// @ts-ignore
|
|
372
|
-
udprecordid: 'udpRecord-udp-selector-' + this.id }, h("div", { key: '
|
|
372
|
+
udprecordid: 'udpRecord-udp-selector-' + this.id }, h("div", { key: '8818ec5d3b96b12f5eee6081b04c5664a4944274', class: {
|
|
373
373
|
'selected-option-label': true,
|
|
374
374
|
'placeholder': !hasSelection,
|
|
375
375
|
} }, this.multiSelect
|
|
@@ -378,7 +378,7 @@ export class UdpSelector {
|
|
|
378
378
|
: 'Select option(s)'
|
|
379
379
|
: this.selectedOption
|
|
380
380
|
? this.selectedOption.label
|
|
381
|
-
: 'Select an option'), this.multiSelect && this.selectedOptions.length > 0 && h("span", { key: '
|
|
381
|
+
: 'Select an option'), this.multiSelect && this.selectedOptions.length > 0 && h("span", { key: 'aebc9ac1f638b9f5222d051c2e29e2c2c78175d3', class: "checkmark" }), h("div", { key: '241aeeeb1cbf93e82ba882b94acbac0cdc6cb738', class: "arrow" })), this.isOpen && (h("ul", { key: 'b9152b16546b6533c389ba648bf6a3bceaf4daad', class: "options-list" }, this.options.map(option => (h("unity-typography", { variant: "button" }, h("li", { class: this.isOptionSelected(option) ? 'selected' : '', onClick: () => this.selectOption(option), onMouseDown: this.handleOptionMouseDown }, option.label, this.isOptionSelected(option) && h("span", { class: "checkmark" })))))))), this.errorMessage && (h("div", { key: '735fd74f02b851563948987b1b73fbe0b4ef7d00', class: "error-message" }, h("unity-typography", { key: 'cfb1289b857dc0acbcab2ade46f383c93995da5e', variant: "caption-text", color: "error" }, this.errorMessage))))));
|
|
382
382
|
}
|
|
383
383
|
/**
|
|
384
384
|
* Checks if a given option is currently selected.
|
|
@@ -15,12 +15,12 @@ export class UdpContainer {
|
|
|
15
15
|
this.padding = true;
|
|
16
16
|
}
|
|
17
17
|
render() {
|
|
18
|
-
return (h("div", { key: '
|
|
18
|
+
return (h("div", { key: '585b9bb995cb7e179c328d07748c66459269c1a0', class: {
|
|
19
19
|
'udp-container': true,
|
|
20
20
|
'udp-container--fluid': this.fluid,
|
|
21
21
|
'udp-container--padded': this.padding,
|
|
22
22
|
[`udp-container--${this.maxWidth}`]: true,
|
|
23
|
-
} }, h("slot", { key: '
|
|
23
|
+
} }, h("slot", { key: '5851c51e280c4322cc404bbea3bb3979ac14681e' })));
|
|
24
24
|
}
|
|
25
25
|
static get is() { return "udp-container"; }
|
|
26
26
|
static get encapsulation() { return "shadow"; }
|
package/dist/collection/components/my-component/UI/layout/udp-container-query/udp-container-query.js
CHANGED
|
@@ -21,9 +21,9 @@ export class UdpContainerQuery {
|
|
|
21
21
|
return styleRules;
|
|
22
22
|
}
|
|
23
23
|
render() {
|
|
24
|
-
return (h(Host, { key: '
|
|
24
|
+
return (h(Host, { key: '0a3f0cd285329482e518b84661fd5337a3354546', class: {
|
|
25
25
|
[this.customClass]: !!this.customClass,
|
|
26
|
-
} }, h("style", { key: '
|
|
26
|
+
} }, h("style", { key: '3011ae8940a91e75ba8491c7b770f7ff9e4d09b5' }, this.getContainerQueryStyle()), h("slot", { key: 'd67a5d70dcc304668e5b26d3f19e11a6c0a20454' })));
|
|
27
27
|
}
|
|
28
28
|
static get is() { return "udp-container-query"; }
|
|
29
29
|
static get encapsulation() { return "shadow"; }
|
|
@@ -29,7 +29,7 @@ export class UdpContainerQueryGrid {
|
|
|
29
29
|
gap: `${this.gaps[breakpoint]}rem`,
|
|
30
30
|
}));
|
|
31
31
|
});
|
|
32
|
-
return (h(Host, { key: '
|
|
32
|
+
return (h(Host, { key: '2c106d3026ddc0aa842fb7098e329f9e550bc4f4' }, h("udp-container-query", { key: '636957df833e8c94d3cc35e4055718530c5afe07', queries: queries }, h("div", { key: '344083115b010236374b5ab29a66e7d2bc8046ba', class: "grid-container" }, h("slot", { key: '0e710ee548f3505d588627087256d918a1e14462' }))), h("style", { key: 'f2843d85b7037305124570f6581a76542107e8d9' }, `
|
|
33
33
|
.grid-container {
|
|
34
34
|
display: grid;
|
|
35
35
|
grid-template-columns: repeat(${this.columns[0]}, 1fr);
|