@duetds/components 5.2.0 → 5.2.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/hydrate/index.js +186 -100
- package/lib/cjs/{dom-66424ef2.js → dom-96576bce.js} +1 -1
- package/lib/cjs/duet-action-button.cjs.entry.js +1 -1
- package/lib/cjs/duet-alert.cjs.entry.js +1 -1
- package/lib/cjs/duet-badge.cjs.entry.js +1 -1
- package/lib/cjs/duet-breadcrumb.cjs.entry.js +1 -1
- package/lib/cjs/duet-breadcrumbs.cjs.entry.js +1 -1
- package/lib/cjs/duet-button_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-caption_4.cjs.entry.js +1 -1
- package/lib/cjs/duet-card.cjs.entry.js +1 -1
- package/lib/cjs/duet-checkbox.cjs.entry.js +1 -1
- package/lib/cjs/duet-choice_2.cjs.entry.js +2 -2
- package/lib/cjs/duet-collapsible.cjs.entry.js +1 -1
- package/lib/cjs/duet-combobox.cjs.entry.js +1 -1
- package/lib/cjs/duet-cookie-consent.cjs.entry.js +1 -1
- package/lib/cjs/duet-date-picker.cjs.entry.js +2 -2
- package/lib/cjs/duet-divider_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-editable-table_3.cjs.entry.js +4 -3
- package/lib/cjs/duet-empty-state.cjs.entry.js +1 -1
- package/lib/cjs/duet-fieldset.cjs.entry.js +1 -1
- package/lib/cjs/duet-footer.cjs.entry.js +1 -1
- package/lib/cjs/duet-grid_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-header_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-hero.cjs.entry.js +1 -1
- package/lib/cjs/duet-icon.cjs.entry.js +1 -1
- package/lib/cjs/duet-input_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-layout.cjs.entry.js +1 -1
- package/lib/cjs/duet-list_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-modal.cjs.entry.js +2 -2
- package/lib/cjs/duet-notification_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-number-input.cjs.entry.js +92 -47
- package/lib/cjs/duet-pagination_2.cjs.entry.js +39 -17
- package/lib/cjs/duet-progress.cjs.entry.js +1 -1
- package/lib/cjs/duet-radio_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-range-slider.cjs.entry.js +1 -1
- package/lib/cjs/duet-scrollable_3.cjs.entry.js +1 -1
- package/lib/cjs/duet-select.cjs.entry.js +1 -1
- package/lib/cjs/duet-step_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-textarea.cjs.entry.js +1 -1
- package/lib/cjs/duet-toggle.cjs.entry.js +1 -1
- package/lib/cjs/duet-tooltip.cjs.entry.js +1 -1
- package/lib/cjs/duet-tray.cjs.entry.js +1 -1
- package/lib/cjs/duet-upload-aria-status.cjs.entry.js +1 -1
- package/lib/cjs/duet-visually-hidden.cjs.entry.js +1 -1
- package/lib/cjs/duet.cjs.js +4 -4
- package/lib/cjs/{focus-utils-bfb10d32.js → focus-utils-12f0a2cb.js} +1 -1
- package/lib/cjs/{index-a4844346.js → index-ba78fa3c.js} +11 -9
- package/lib/cjs/loader.cjs.js +3 -3
- package/lib/cjs/{shadow-css-1ff2f74f.js → shadow-css-38b9e725.js} +2 -3
- package/lib/collection/collection-manifest.json +1 -1
- package/lib/collection/components/duet-editable-table/duet-editable-table.js +2 -1
- package/lib/collection/components/duet-number-input/duet-number-input.js +22 -27
- package/lib/collection/components/duet-pagination/duet-pagination.js +18 -13
- package/lib/collection/components/duet-range-stepper/duet-range-stepper.js +28 -11
- package/lib/collection/components/duet-table/duet-table.css +30 -18
- package/lib/collection/utils/math.utils.js +76 -0
- package/lib/custom-elements-bundle/index.js +145 -78
- package/lib/duet/duet.esm.js +1 -1
- package/lib/duet/duet.js +1 -1
- package/lib/duet/{p-285714dd.entry.js → p-0146f86f.entry.js} +1 -1
- package/lib/duet/{p-b0a4dc6d.entry.js → p-02fdca38.entry.js} +1 -1
- package/lib/duet/{p-99fe93c6.system.entry.js → p-034aa5af.system.entry.js} +1 -1
- package/lib/duet/{p-f5613315.system.entry.js → p-072a20bb.system.entry.js} +1 -1
- package/lib/duet/{p-b35d6368.system.entry.js → p-07970e02.system.entry.js} +1 -1
- package/lib/duet/{p-fbec1a47.entry.js → p-119b3a75.entry.js} +1 -1
- package/lib/duet/{p-423d4211.system.entry.js → p-12eb57c0.system.entry.js} +1 -1
- package/lib/duet/{p-78de93b3.entry.js → p-17d0567c.entry.js} +1 -1
- package/lib/duet/p-1919ea71.system.entry.js +4 -0
- package/lib/duet/{p-97f1e254.entry.js → p-1b03c0b0.entry.js} +1 -1
- package/lib/duet/p-1d3fe5c7.js +5 -0
- package/lib/duet/{p-b4ca3864.system.entry.js → p-1d557ffa.system.entry.js} +1 -1
- package/lib/duet/{p-6a843f9e.entry.js → p-1e124cda.entry.js} +1 -1
- package/lib/duet/p-28ed49f6.entry.js +4 -0
- package/lib/duet/{p-e8f8374b.system.entry.js → p-2b1098f7.system.entry.js} +1 -1
- package/lib/duet/{p-271107d8.entry.js → p-30c2a422.entry.js} +1 -1
- package/lib/duet/{p-b16befbc.system.entry.js → p-36ad89c8.system.entry.js} +1 -1
- package/lib/duet/{p-fef3a403.system.entry.js → p-38d81ea7.system.entry.js} +1 -1
- package/lib/duet/{p-e7b761c5.system.js → p-392d3906.system.js} +1 -1
- package/lib/duet/{p-00bf0bb9.system.entry.js → p-3a1bcb33.system.entry.js} +1 -1
- package/lib/duet/{p-fa59ebf4.js → p-3b31184e.js} +0 -0
- package/lib/duet/{p-360f8fff.system.entry.js → p-3dcf6143.system.entry.js} +1 -1
- package/lib/duet/{p-ec6d63fc.entry.js → p-45fce3bd.entry.js} +1 -1
- package/lib/duet/{p-bf87d801.entry.js → p-4d661df0.entry.js} +1 -1
- package/lib/duet/{p-41cc3490.entry.js → p-4d6b63bd.entry.js} +1 -1
- package/lib/duet/{p-c0aca70c.entry.js → p-4dfd691c.entry.js} +1 -1
- package/lib/duet/{p-7a4764db.system.entry.js → p-4e1342e8.system.entry.js} +1 -1
- package/lib/duet/{p-d4dba079.system.entry.js → p-506d7234.system.entry.js} +1 -1
- package/lib/duet/{p-bb4d8e7b.entry.js → p-518d507a.entry.js} +1 -1
- package/lib/duet/{p-437fe50b.system.entry.js → p-532a7563.system.entry.js} +1 -1
- package/lib/duet/{p-790ee851.entry.js → p-5de61303.entry.js} +1 -1
- package/lib/duet/{p-a2fa0049.entry.js → p-62635fbd.entry.js} +1 -1
- package/lib/duet/p-63536b2d.entry.js +4 -0
- package/lib/duet/{p-01478a01.system.entry.js → p-64469525.system.entry.js} +1 -1
- package/lib/duet/{p-53ad61ed.entry.js → p-65527b10.entry.js} +1 -1
- package/lib/duet/{p-98039227.system.entry.js → p-68b86cf3.system.entry.js} +1 -1
- package/lib/duet/{p-c1d55269.system.entry.js → p-6a4e52a8.system.entry.js} +1 -1
- package/lib/duet/{p-fd0a3ab7.entry.js → p-6b7706d1.entry.js} +1 -1
- package/lib/duet/{p-1ff51ad8.system.entry.js → p-6e7f309d.system.entry.js} +1 -1
- package/lib/duet/p-6e853c11.system.entry.js +4 -0
- package/lib/duet/{p-9920ad3b.entry.js → p-70a3b04a.entry.js} +1 -1
- package/lib/duet/{p-cb8ebdd7.entry.js → p-72975917.entry.js} +1 -1
- package/lib/duet/{p-ee97a406.system.entry.js → p-73c4e3a3.system.entry.js} +1 -1
- package/lib/duet/{p-f91e88e3.system.entry.js → p-78627725.system.entry.js} +1 -1
- package/lib/duet/{p-641edb93.system.entry.js → p-7adfeba7.system.entry.js} +1 -1
- package/lib/duet/{p-88ffd1cc.entry.js → p-82492a56.entry.js} +1 -1
- package/lib/duet/p-835fbc11.js +4 -0
- package/lib/duet/{p-10585f06.system.entry.js → p-84a7b980.system.entry.js} +1 -1
- package/lib/duet/{p-9406ee60.entry.js → p-856b4648.entry.js} +1 -1
- package/lib/duet/{p-04061cef.entry.js → p-89fa490e.entry.js} +1 -1
- package/lib/duet/{p-72739cec.entry.js → p-8bc46a6e.entry.js} +1 -1
- package/lib/duet/{p-24721182.system.entry.js → p-8bd8f3b9.system.entry.js} +1 -1
- package/lib/duet/{p-05e069d8.entry.js → p-8e2ec8a1.entry.js} +1 -1
- package/lib/duet/{p-56d3e64f.entry.js → p-8eeccac4.entry.js} +1 -1
- package/lib/duet/{p-95a0db46.entry.js → p-92ab9288.entry.js} +1 -1
- package/lib/duet/{p-030e20d7.entry.js → p-96d1c0b2.entry.js} +1 -1
- package/lib/duet/{p-7021d0c6.system.entry.js → p-97a5f165.system.entry.js} +1 -1
- package/lib/duet/{p-071ebe1d.system.entry.js → p-9c850ee8.system.entry.js} +1 -1
- package/lib/duet/{p-0bee3151.system.entry.js → p-9fb0854f.system.entry.js} +1 -1
- package/lib/duet/{p-afd34b6b.system.entry.js → p-a2f3f08d.system.entry.js} +1 -1
- package/lib/duet/p-a81531cf.system.js +4 -0
- package/lib/duet/{p-08eb2200.entry.js → p-a9f17642.entry.js} +1 -1
- package/lib/duet/{p-d33b5ac5.system.entry.js → p-ab1cda11.system.entry.js} +1 -1
- package/lib/duet/{p-64685397.entry.js → p-ae7e7fbf.entry.js} +1 -1
- package/lib/duet/{p-76e38bb2.system.entry.js → p-b3dba7d7.system.entry.js} +1 -1
- package/lib/duet/{p-542af014.system.js → p-b668b67c.system.js} +0 -0
- package/lib/duet/{p-c7657242.entry.js → p-baf2428d.entry.js} +1 -1
- package/lib/duet/p-bb65d334.system.entry.js +4 -0
- package/lib/duet/{p-03b6ce80.entry.js → p-bbf4391c.entry.js} +1 -1
- package/lib/duet/{p-a509cc2b.system.entry.js → p-c54d7981.system.entry.js} +1 -1
- package/lib/duet/p-c6791e18.system.js +5 -0
- package/lib/duet/{p-e75c7aa8.system.entry.js → p-c6d4025f.system.entry.js} +1 -1
- package/lib/duet/{p-73cd4f03.system.entry.js → p-c6d99598.system.entry.js} +1 -1
- package/lib/duet/{p-19100783.system.entry.js → p-c75db094.system.entry.js} +1 -1
- package/lib/duet/{p-b08bb1fd.entry.js → p-c9c6d840.entry.js} +1 -1
- package/lib/duet/{p-495a1326.system.entry.js → p-cfcb5990.system.entry.js} +1 -1
- package/lib/duet/{p-95e1a336.entry.js → p-d16b2352.entry.js} +1 -1
- package/lib/duet/{p-5f009925.system.entry.js → p-d1f678be.system.entry.js} +1 -1
- package/lib/duet/{p-27d238c5.js → p-d4c234ed.js} +1 -1
- package/lib/duet/{p-7fe67436.system.entry.js → p-d506da98.system.entry.js} +1 -1
- package/lib/duet/{p-b8623ab8.entry.js → p-d96432a0.entry.js} +1 -1
- package/lib/duet/{p-5b1cbe5b.entry.js → p-dc5971bf.entry.js} +1 -1
- package/lib/duet/{p-3260eef0.entry.js → p-de6e8bfb.entry.js} +1 -1
- package/lib/duet/{p-30e901f2.system.entry.js → p-dfff5f16.system.entry.js} +1 -1
- package/lib/duet/{p-0ae816ee.entry.js → p-e27f1382.entry.js} +1 -1
- package/lib/duet/{p-68cbc3b7.entry.js → p-e2cc3eb4.entry.js} +1 -1
- package/lib/duet/{p-9496d6d4.entry.js → p-e575b990.entry.js} +1 -1
- package/lib/duet/{p-a843e579.system.entry.js → p-ee6352cf.system.entry.js} +1 -1
- package/lib/duet/{p-4a7f290f.entry.js → p-f66e69a0.entry.js} +1 -1
- package/lib/duet/p-f80195fa.entry.js +4 -0
- package/lib/duet/{p-b51928dc.system.entry.js → p-fd8ac2e7.system.entry.js} +1 -1
- package/lib/duet/{p-33388bf3.system.entry.js → p-febd0192.system.entry.js} +1 -1
- package/lib/duet/p-ff46ec81.system.js +16 -0
- package/lib/esm/{dom-3c479050.js → dom-3dbcb0d8.js} +1 -1
- package/lib/esm/duet-action-button.entry.js +1 -1
- package/lib/esm/duet-alert.entry.js +1 -1
- package/lib/esm/duet-badge.entry.js +1 -1
- package/lib/esm/duet-breadcrumb.entry.js +1 -1
- package/lib/esm/duet-breadcrumbs.entry.js +1 -1
- package/lib/esm/duet-button_2.entry.js +1 -1
- package/lib/esm/duet-caption_4.entry.js +1 -1
- package/lib/esm/duet-card.entry.js +1 -1
- package/lib/esm/duet-checkbox.entry.js +1 -1
- package/lib/esm/duet-choice_2.entry.js +2 -2
- package/lib/esm/duet-collapsible.entry.js +1 -1
- package/lib/esm/duet-combobox.entry.js +1 -1
- package/lib/esm/duet-cookie-consent.entry.js +1 -1
- package/lib/esm/duet-date-picker.entry.js +2 -2
- package/lib/esm/duet-divider_2.entry.js +1 -1
- package/lib/esm/duet-editable-table_3.entry.js +4 -3
- package/lib/esm/duet-empty-state.entry.js +1 -1
- package/lib/esm/duet-fieldset.entry.js +1 -1
- package/lib/esm/duet-footer.entry.js +1 -1
- package/lib/esm/duet-grid_2.entry.js +1 -1
- package/lib/esm/duet-header_2.entry.js +1 -1
- package/lib/esm/duet-hero.entry.js +1 -1
- package/lib/esm/duet-icon.entry.js +1 -1
- package/lib/esm/duet-input_2.entry.js +1 -1
- package/lib/esm/duet-layout.entry.js +1 -1
- package/lib/esm/duet-list_2.entry.js +1 -1
- package/lib/esm/duet-modal.entry.js +2 -2
- package/lib/esm/duet-notification_2.entry.js +1 -1
- package/lib/esm/duet-number-input.entry.js +92 -47
- package/lib/esm/duet-pagination_2.entry.js +39 -17
- package/lib/esm/duet-progress.entry.js +1 -1
- package/lib/esm/duet-radio_2.entry.js +1 -1
- package/lib/esm/duet-range-slider.entry.js +1 -1
- package/lib/esm/duet-scrollable_3.entry.js +1 -1
- package/lib/esm/duet-select.entry.js +1 -1
- package/lib/esm/duet-step_2.entry.js +1 -1
- package/lib/esm/duet-textarea.entry.js +1 -1
- package/lib/esm/duet-toggle.entry.js +1 -1
- package/lib/esm/duet-tooltip.entry.js +1 -1
- package/lib/esm/duet-tray.entry.js +1 -1
- package/lib/esm/duet-upload-aria-status.entry.js +1 -1
- package/lib/esm/duet-visually-hidden.entry.js +1 -1
- package/lib/esm/duet.js +4 -4
- package/lib/esm/{focus-utils-3af074ea.js → focus-utils-3769afc3.js} +1 -1
- package/lib/esm/{index-ab2bfa68.js → index-374256c8.js} +11 -9
- package/lib/esm/loader.js +3 -3
- package/lib/esm/polyfills/css-shim.js +1 -1
- package/lib/esm/{shadow-css-fbe49d20.js → shadow-css-501eda9a.js} +2 -3
- package/lib/esm-es5/{dom-3c479050.js → dom-3dbcb0d8.js} +0 -0
- package/lib/esm-es5/duet-action-button.entry.js +1 -1
- package/lib/esm-es5/duet-alert.entry.js +1 -1
- package/lib/esm-es5/duet-badge.entry.js +1 -1
- package/lib/esm-es5/duet-breadcrumb.entry.js +1 -1
- package/lib/esm-es5/duet-breadcrumbs.entry.js +1 -1
- package/lib/esm-es5/duet-button_2.entry.js +1 -1
- package/lib/esm-es5/duet-caption_4.entry.js +1 -1
- package/lib/esm-es5/duet-card.entry.js +1 -1
- package/lib/esm-es5/duet-checkbox.entry.js +1 -1
- package/lib/esm-es5/duet-choice_2.entry.js +2 -2
- package/lib/esm-es5/duet-collapsible.entry.js +1 -1
- package/lib/esm-es5/duet-combobox.entry.js +1 -1
- package/lib/esm-es5/duet-cookie-consent.entry.js +1 -1
- package/lib/esm-es5/duet-date-picker.entry.js +1 -1
- package/lib/esm-es5/duet-divider_2.entry.js +1 -1
- package/lib/esm-es5/duet-editable-table_3.entry.js +2 -2
- package/lib/esm-es5/duet-empty-state.entry.js +1 -1
- package/lib/esm-es5/duet-fieldset.entry.js +1 -1
- package/lib/esm-es5/duet-footer.entry.js +1 -1
- package/lib/esm-es5/duet-grid_2.entry.js +1 -1
- package/lib/esm-es5/duet-header_2.entry.js +1 -1
- package/lib/esm-es5/duet-hero.entry.js +1 -1
- package/lib/esm-es5/duet-icon.entry.js +1 -1
- package/lib/esm-es5/duet-input_2.entry.js +1 -1
- package/lib/esm-es5/duet-layout.entry.js +1 -1
- package/lib/esm-es5/duet-list_2.entry.js +1 -1
- package/lib/esm-es5/duet-modal.entry.js +1 -1
- package/lib/esm-es5/duet-notification_2.entry.js +1 -1
- package/lib/esm-es5/duet-number-input.entry.js +2 -2
- package/lib/esm-es5/duet-pagination_2.entry.js +1 -1
- package/lib/esm-es5/duet-progress.entry.js +1 -1
- package/lib/esm-es5/duet-radio_2.entry.js +1 -1
- package/lib/esm-es5/duet-range-slider.entry.js +1 -1
- package/lib/esm-es5/duet-scrollable_3.entry.js +1 -1
- package/lib/esm-es5/duet-select.entry.js +1 -1
- package/lib/esm-es5/duet-step_2.entry.js +1 -1
- package/lib/esm-es5/duet-textarea.entry.js +1 -1
- package/lib/esm-es5/duet-toggle.entry.js +1 -1
- package/lib/esm-es5/duet-tooltip.entry.js +1 -1
- package/lib/esm-es5/duet-tray.entry.js +1 -1
- package/lib/esm-es5/duet-upload-aria-status.entry.js +1 -1
- package/lib/esm-es5/duet-visually-hidden.entry.js +1 -1
- package/lib/esm-es5/duet.js +1 -1
- package/lib/esm-es5/{focus-utils-3af074ea.js → focus-utils-3769afc3.js} +1 -1
- package/lib/esm-es5/index-374256c8.js +5 -0
- package/lib/esm-es5/loader.js +1 -1
- package/lib/esm-es5/shadow-css-501eda9a.js +15 -0
- package/lib/types/components/duet-number-input/duet-number-input.d.ts +0 -1
- package/lib/types/components/duet-pagination/duet-pagination.d.ts +1 -1
- package/lib/types/components/duet-range-stepper/duet-range-stepper.d.ts +3 -1
- package/lib/types/components.d.ts +192 -80
- package/lib/types/utils/math.utils.d.ts +11 -0
- package/package.json +6 -6
- package/lib/collection/components/duet-number-input/number-input-utils.js +0 -26
- package/lib/duet/p-12c89686.system.js +0 -4
- package/lib/duet/p-37dc064c.js +0 -4
- package/lib/duet/p-4972c76e.system.js +0 -4
- package/lib/duet/p-5a5d8fb1.entry.js +0 -4
- package/lib/duet/p-66536958.system.entry.js +0 -4
- package/lib/duet/p-92a25fb5.system.js +0 -16
- package/lib/duet/p-971f42d6.system.entry.js +0 -4
- package/lib/duet/p-98a9556f.js +0 -4
- package/lib/duet/p-a76bf729.entry.js +0 -4
- package/lib/duet/p-b7462f8c.system.entry.js +0 -4
- package/lib/duet/p-fe99b9cb.entry.js +0 -4
- package/lib/esm-es5/index-ab2bfa68.js +0 -4
- package/lib/esm-es5/shadow-css-fbe49d20.js +0 -15
- package/lib/types/components/duet-number-input/number-input-utils.d.ts +0 -4
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, h, H as Host } from './index-
|
|
4
|
+
import { r as registerInstance, h, H as Host } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
|
|
7
7
|
const duetBadgeCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-right:4px !important;margin-bottom:2px !important;display:inline-block;width:auto;vertical-align:middle}:host:last-child,:host:last-of-type{margin-right:0 !important}:host(.duet-m-0){margin:0 !important}.duet-badge{width:100%;padding:4.4444444444px 12px 5.4444444444px;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:0.75rem;font-style:normal;font-weight:600;line-height:1.25;color:#00294d;text-align:center;word-break:break-word;vertical-align:middle;background:#e6f1f7;border-radius:20rem}.duet-badge.duet-p-0{padding:0 !important}.duet-badge.duet-m-0{margin:0 !important}.duet-badge.duet-theme-turva{padding:5.4444444444px 12px 4.4444444444px;font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-weight:700;color:#171c3a;background:#e8e8eb}.duet-badge.warning{background:#fef3df}.duet-badge.warning.duet-theme-turva{background:#fef1db}.duet-badge.danger{background:#fce9ef}.duet-badge.danger.duet-theme-turva{background:#fceae7}.duet-badge.success{background:#e6f3ef}.duet-badge.success.duet-theme-turva{background:#e6f3ed}";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, h, H as Host } from './index-
|
|
4
|
+
import { r as registerInstance, h, H as Host } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
|
|
7
7
|
const duetBreadcrumbCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:block;width:100%}.duet-breadcrumb{display:flex;flex-direction:row;align-items:center;justify-content:flex-start;height:100%;font-size:0.875rem;color:#00294d;text-decoration:none}.duet-breadcrumb:hover{color:#004d80}.duet-breadcrumb.duet-theme-turva{color:#171c3a}.duet-breadcrumb.duet-theme-turva:hover{color:#940925}.duet-breadcrumb:focus{outline:0}.duet-breadcrumb:active{opacity:0.75}:host(.user-is-tabbing) .duet-breadcrumb:focus{box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}:host(.user-is-tabbing) .duet-breadcrumb.duet-theme-turva:focus{box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, h, F as Fragment, H as Host, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, h, F as Fragment, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { a as actionArrowRightSmall } from './action-arrow-right-small-f9d2ba83.js';
|
|
6
6
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
7
7
|
import { g as getLocaleString } from './language-utils-bf701d37.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { D as DuetStringsExternalDefaults } from './common-strings-97e04e4b.js';
|
|
7
7
|
import { a as getLanguage, g as getLocaleString } from './language-utils-bf701d37.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, h, H as Host, g as getElement, F as Fragment } from './index-
|
|
4
|
+
import { r as registerInstance, h, H as Host, g as getElement, F as Fragment } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { s as sanitizeString } from './string-utils-5954f458.js';
|
|
7
7
|
import { g as getColorByName } from './token-utils-1f9435bc.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, c as createEvent, h, F as Fragment, H as Host, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, c as createEvent, h, F as Fragment, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { c as createID } from './create-id-981107da.js';
|
|
7
7
|
import { i as isKeyboardClick } from './keyboard-utils-88ea1007.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { c as createID } from './create-id-981107da.js';
|
|
7
7
|
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { D as DuetStringsExternalDefaults } from './common-strings-97e04e4b.js';
|
|
7
7
|
import { c as createID } from './create-id-981107da.js';
|
|
8
|
-
import { F as FocusGuard } from './focus-utils-
|
|
8
|
+
import { F as FocusGuard } from './focus-utils-3769afc3.js';
|
|
9
9
|
import { i as isKeyboardClick, h as isQuestionKey, f as isEscapeKey } from './keyboard-utils-88ea1007.js';
|
|
10
10
|
import { g as getLocaleString, a as getLanguage } from './language-utils-bf701d37.js';
|
|
11
11
|
import { f as findCheckedOption, w as watchForOptions } from './watch-options-dd55bce8.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { a as actionArrowDownSmall } from './action-arrow-down-small-82273dc8.js';
|
|
6
6
|
import { f as font_size_medium, t as tokens } from './tokens-8ff8c570.js';
|
|
7
7
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { h, F as Fragment, r as registerInstance, c as createEvent, H as Host, g as getElement } from './index-
|
|
4
|
+
import { h, F as Fragment, r as registerInstance, c as createEvent, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { d as debounce } from './js-utils-52e0944c.js';
|
|
7
7
|
import { n as isEnterKey, f as isEscapeKey, o as isTabKey, b as isArrowUpKey, c as isArrowDownKey } from './keyboard-utils-88ea1007.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
|
|
7
7
|
const duetCookieConsentCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;position:fixed;right:0;bottom:0;left:0;z-index:950;display:block;width:100%;box-shadow:0 2px 20px 0 rgba(0, 0, 0, 0.2)}@media (min-width: 48em){:host{right:28px;bottom:28px;left:auto;width:25rem}}:host(:focus){outline:0}:host(.user-is-tabbing:focus){border-radius:4px;box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}:host(.user-is-tabbing.duet-theme-turva:focus){box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}.duet-cookie-consent{padding:20px;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:0.875rem;color:white !important;background-color:rgba(0, 21, 39, 0.9)}@supports (-webkit-backdrop-filter: none) or (backdrop-filter: none){.duet-cookie-consent{background:rgba(0, 21, 39, 0.8);-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}}.duet-cookie-consent.duet-theme-turva{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";background-color:rgba(12, 14, 29, 0.9)}@supports (-webkit-backdrop-filter: none) or (backdrop-filter: none){.duet-cookie-consent.duet-theme-turva{background:rgba(12, 14, 29, 0.8)}}@media (min-width: 48em){.duet-cookie-consent{padding:20px;border-radius:4px}}.duet-cookie-consent-content{display:flex;align-items:center;max-width:1110px;margin:0 auto}.duet-cookie-consent-content .expand{flex:1}::slotted(a){font-weight:600;color:white !important;text-decoration:underline;white-space:nowrap}::slotted(a[target=_blank]){padding-right:16px;background:url(\"data:image/svg+xml;base64,PHN2ZyBmaWxsPSIjZmZmIiB2aWV3Qm94PSIwIDAgMjQgMjQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEwLjUgMmExLjUgMS41IDAgMDEuMTQgM0gzLjc1Yy0uMzggMC0uNy4yOC0uNzQuNjVsLS4wMS4xdjE0LjVjMCAuMzguMjguNy42NS43NGwuMS4wMWgxNC41Yy4zOCAwIC43LS4yOC43NC0uNjVsLjAxLS4xdi02Ljg5YTEuNSAxLjUgMCAwMTMgMHY2Ljg5QTMuNzUgMy43NSAwIDAxMTguMjUgMjRIMy43NUEzLjc1IDMuNzUgMCAwMTAgMjAuMjVWNS43NUEzLjc1IDMuNzUgMCAwMTMuNzUgMnptMTItMmMuNzggMCAxLjQyLjYgMS41IDEuMzZWNy41YTEuNSAxLjUgMCAwMS0zIC4xNFY1LjEybC01LjQ0IDUuNDRhMS41IDEuNSAwIDAxLTIuMjItMmwuMS0uMTJMMTguODggM0gxNi41QTEuNSAxLjUgMCAwMTE1IDEuNjRWMS41YzAtLjc4LjYtMS40MiAxLjM2LTEuNWguMTR6Ii8+PC9zdmc+\") no-repeat right 50%;background-size:12px 10px}::slotted(a:focus){outline:0;box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}.duet-theme-turva ::slotted(a:focus){outline:0;box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { h, r as registerInstance, c as createEvent, H as Host, g as getElement } from './index-
|
|
4
|
+
import { h, r as registerInstance, c as createEvent, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { c as createID } from './create-id-981107da.js';
|
|
7
|
-
import { F as FocusGuard } from './focus-utils-
|
|
7
|
+
import { F as FocusGuard } from './focus-utils-3769afc3.js';
|
|
8
8
|
import { a as getLanguage, g as getLocaleString } from './language-utils-bf701d37.js';
|
|
9
9
|
import './string-utils-5954f458.js';
|
|
10
10
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, h, g as getElement, H as Host } from './index-
|
|
4
|
+
import { r as registerInstance, h, g as getElement, H as Host } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
|
|
7
7
|
const duetDividerCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:block;width:100%}.duet-divider{-webkit-user-select:none;user-select:none;display:block;width:100%;height:1px;margin-top:36px !important;margin-bottom:28px;background:#e1e3e6}.duet-divider.duet-p-0{padding:0 !important}.duet-divider.duet-m-0{margin:0 !important}.duet-divider.duet-m-s{margin-bottom:16px !important;margin-top:0 !important}.duet-divider.duet-theme-turva{background:#e4e4e6}";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { h, r as registerInstance, c as createEvent, H as Host, g as getElement } from './index-
|
|
4
|
+
import { h, r as registerInstance, c as createEvent, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { f as fieldSorter, d as debounce } from './js-utils-52e0944c.js';
|
|
7
7
|
import { i as isKeyboardClick } from './keyboard-utils-88ea1007.js';
|
|
@@ -209,6 +209,7 @@ const DuetEditableTable = class {
|
|
|
209
209
|
render() {
|
|
210
210
|
return (h(Host, { class: {
|
|
211
211
|
[`duet-editable-table-${this.variation}`]: true,
|
|
212
|
+
"duet-editable-table": true,
|
|
212
213
|
[`duet-editable-table-${this.theme}`]: true,
|
|
213
214
|
// sticky only valid when in regular table layout
|
|
214
215
|
"duet-editable-table-scrollable": this.breakpoint === "none-scrollable",
|
|
@@ -216,13 +217,13 @@ const DuetEditableTable = class {
|
|
|
216
217
|
"duet-editable-table-actions": !!this.actions,
|
|
217
218
|
"duet-m-0": this.margin === "none",
|
|
218
219
|
"duet-theme-turva": this.theme === "turva",
|
|
219
|
-
} }, h("duet-table", { sticky: this.sticky, stickyDistance: this.stickyDistance, margin: this.margin, theme: this.theme, variation: this.variation, breakpoint: this.breakpoint }, h("table", { role: this.accessibleRole }, h("caption", null, h("slot", { name: "tcaption" })), h("thead", null, h("tr", null, h("td", { class: "duet-editable-table-actions-menu", colSpan: 99 }, h("slot", { name: "thead-first" }))), this.renderTableHeader(), h("tr", null, h("td", { class: "duet-editable-table-actions-menu", colSpan: 99 }, h("slot", { name: "thead-last" })))), h("tbody", null, this.renderTableBody()), h("tfoot", null, h("tr", null, h("th", { class: "duet-editable-table-footer-menu", colSpan: 99 }, h("slot", { name: "tfoot" }))))))));
|
|
220
|
+
} }, h("duet-table", { class: "duet-editable-table-table", sticky: this.sticky, stickyDistance: this.stickyDistance, margin: this.margin, theme: this.theme, variation: this.variation, breakpoint: this.breakpoint }, h("table", { role: this.accessibleRole }, h("caption", null, h("slot", { name: "tcaption" })), h("thead", null, h("tr", null, h("td", { class: "duet-editable-table-actions-menu", colSpan: 99 }, h("slot", { name: "thead-first" }))), this.renderTableHeader(), h("tr", null, h("td", { class: "duet-editable-table-actions-menu", colSpan: 99 }, h("slot", { name: "thead-last" })))), h("tbody", null, this.renderTableBody()), h("tfoot", null, h("tr", null, h("th", { class: "duet-editable-table-footer-menu", colSpan: 99 }, h("slot", { name: "tfoot" }))))))));
|
|
220
221
|
}
|
|
221
222
|
get element() { return getElement(this); }
|
|
222
223
|
};
|
|
223
224
|
DuetEditableTable.style = duetEditableTableCss;
|
|
224
225
|
|
|
225
|
-
const duetTableCss = "duet-table{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-bottom:20px !important;display:block;font-variant-numeric:tabular-nums}duet-table table,duet-table thead,duet-table tbody,duet-table tfoot,duet-table th,duet-table td,duet-table tr{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}duet-table.duet-m-0{margin:0 !important}duet-table table{width:100%;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;text-align:left;border-spacing:0;border-collapse:separate}duet-table.duet-theme-turva table{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"}duet-table td{-webkit-hyphens:auto;hyphens:auto;color:#00294d}duet-table.duet-theme-turva td{color:#171c3a}duet-table th{font-weight:600;line-height:1.25;color:#657787;text-align:left}duet-table.duet-theme-turva th{color:#747475}duet-table tbody th{font-weight:600;color:#00294d}duet-table.duet-theme-turva tbody th{color:#171c3a}duet-table .duet-table-action-row td:last-child{justify-self:end;padding-right:20px !important;white-space:nowrap}.duet-table-flattened
|
|
226
|
+
const duetTableCss = "duet-table{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-bottom:20px !important;display:block;font-variant-numeric:tabular-nums}duet-table table,duet-table thead,duet-table tbody,duet-table tfoot,duet-table th,duet-table td,duet-table tr{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}duet-table.duet-m-0{margin:0 !important}duet-table table{width:100%;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;text-align:left;border-spacing:0;border-collapse:separate}duet-table.duet-theme-turva table{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"}duet-table td{-webkit-hyphens:auto;hyphens:auto;color:#00294d}duet-table.duet-theme-turva td{color:#171c3a}duet-table th{font-weight:600;line-height:1.25;color:#657787;text-align:left}duet-table.duet-theme-turva th{color:#747475}duet-table tbody th{font-weight:600;color:#00294d}duet-table.duet-theme-turva tbody th{color:#171c3a}duet-table .duet-table-action-row td:last-child{justify-self:end;padding-right:20px !important;white-space:nowrap}.duet-table-flattened table,.duet-table-flattened thead,.duet-table-flattened tbody,.duet-table-flattened tfoot,.duet-table-flattened th,.duet-table-flattened td,.duet-table-flattened tr{display:block}.duet-table-flattened thead tr{position:absolute !important;top:0;width:1px !important;height:1px !important;padding:0 !important;overflow:hidden !important;clip:rect(1px, 1px, 1px, 1px) !important;border:0 !important}.duet-table-flattened td{line-height:1.25}.duet-table-flattened td:not(:last-child){margin-bottom:16px !important}.duet-table-flattened tbody td,.duet-table-flattened tbody th,.duet-table-flattened tfoot td{padding:0 !important;text-align:left !important}.duet-table-flattened tbody th{font-weight:600;line-height:1.25;color:#657787;text-align:left}.duet-table-flattened td[data-heading]::before{margin-bottom:4px !important;display:block;font-size:1rem;font-weight:600;color:#00294d;content:attr(data-heading)}.duet-table-flattened.duet-theme-turva td[data-heading]::before{color:#171c3a}.duet-table-sticky thead th{position:sticky;top:0;background:white}.duet-table-striped td,.duet-table-striped th{padding:20px !important}@media (max-width: 35.9375em){.duet-table-striped td,.duet-table-striped th{padding:20px 12px !important}}.duet-table-striped tbody th{background:white}.duet-table-striped.duet-table-sticky thead th{border-bottom:1px solid #e1e3e6}.duet-table-striped.duet-table-sticky.duet-theme-turva thead th{border-bottom-color:#e4e4e6}.duet-table-striped tbody:not(:first-of-type) th{padding-top:40px !important}.duet-table-striped tbody:only-of-type tr:nth-of-type(odd){background:rgba(0, 80, 128, 0.04)}.duet-table-striped.duet-theme-turva tbody:only-of-type tr:nth-of-type(odd){background:rgba(23, 28, 58, 0.04)}.duet-table-striped tbody:not(:only-of-type) tr:nth-of-type(even){background:rgba(0, 80, 128, 0.04)}.duet-table-striped.duet-theme-turva tbody:not(:only-of-type) tr:nth-of-type(even){background:rgba(23, 28, 58, 0.04)}.duet-table-striped tfoot td{border-top:1px solid #e1e3e6}.duet-table-striped.duet-theme-turva tfoot td{border-top-color:#e4e4e6}.duet-table-striped.duet-table-flattened tbody:not(:first-of-type) th{padding-top:20px !important}.duet-table-striped.duet-table-flattened tr{padding:20px !important}.duet-table-striped.duet-table-flattened tfoot td{border-top:0}.duet-table-striped.duet-table-flattened tfoot tr{border-top:1px solid #e1e3e6}.duet-table-striped.duet-table-flattened.duet-theme-turva tfoot tr{border-top-color:#e4e4e6}.duet-table-fixed th,.duet-table-minimal th,.duet-table-plain th{padding:16px !important;border-bottom:1px solid #657787}.duet-table-fixed th:first-child,.duet-table-minimal th:first-child,.duet-table-plain th:first-child{padding-left:0 !important}.duet-table-fixed th:last-child,.duet-table-minimal th:last-child,.duet-table-plain th:last-child{padding-right:0 !important}.duet-theme-turva.duet-table-fixed th,.duet-theme-turva.duet-table-minimal th,.duet-theme-turva.duet-table-plain th{border-bottom-color:#444445}.duet-table-fixed tbody th,.duet-table-minimal tbody th,.duet-table-plain tbody th{padding-top:40px !important;border-bottom-color:#e1e3e6}.duet-theme-turva.duet-table-fixed tbody th,.duet-theme-turva.duet-table-minimal tbody th,.duet-theme-turva.duet-table-plain tbody th{border-bottom-color:#e4e4e6}.duet-table-fixed td,.duet-table-minimal td,.duet-table-plain td{padding:16px !important}.duet-table-fixed td:first-child,.duet-table-minimal td:first-child,.duet-table-plain td:first-child{padding-left:0 !important}.duet-table-fixed td:last-child,.duet-table-minimal td:last-child,.duet-table-plain td:last-child{padding-right:0 !important}.duet-table-fixed tbody td,.duet-table-minimal tbody td,.duet-table-plain tbody td{border-bottom:1px solid #e1e3e6}.duet-theme-turva.duet-table-fixed tbody td,.duet-theme-turva.duet-table-minimal tbody td,.duet-theme-turva.duet-table-plain tbody td{border-bottom-color:#e4e4e6}.duet-table-flattened.duet-table-fixed tbody:first-of-type th,.duet-table-flattened.duet-table-minimal tbody:first-of-type th,.duet-table-flattened.duet-table-plain tbody:first-of-type th{padding-top:0 !important}.duet-table-flattened.duet-table-fixed td,.duet-table-flattened.duet-table-minimal td,.duet-table-flattened.duet-table-plain td,.duet-table-flattened.duet-table-fixed tbody th,.duet-table-flattened.duet-table-minimal tbody th,.duet-table-flattened.duet-table-plain tbody th{border-bottom:0}.duet-table-flattened.duet-table-fixed tr,.duet-table-flattened.duet-table-minimal tr,.duet-table-flattened.duet-table-plain tr{padding:20px 0 !important}.duet-table-flattened.duet-table-fixed tbody th,.duet-table-flattened.duet-table-minimal tbody th,.duet-table-flattened.duet-table-plain tbody th{padding-top:20px !important}.duet-table-flattened.duet-table-fixed tfoot td,.duet-table-flattened.duet-table-minimal tfoot td,.duet-table-flattened.duet-table-plain tfoot td{margin-bottom:4px !important}.duet-table-flattened.duet-table-fixed tbody:not(:only-of-type) tr:first-child,.duet-table-flattened.duet-table-minimal tbody:not(:only-of-type) tr:first-child,.duet-table-flattened.duet-table-plain tbody:not(:only-of-type) tr:first-child{border-bottom:0}.duet-table-plain.duet-table-flattened tbody tr{border-bottom:1px solid #e1e3e6}.duet-table-plain.duet-table-flattened.duet-theme-turva tbody tr{border-bottom-color:#e4e4e6}.duet-table-minimal tbody tr,.duet-table-minimal tbody tr td{vertical-align:top;border-bottom:0 none}.duet-table-minimal tbody tr:last-of-type,.duet-table-minimal tbody tr:last-of-type td{border-bottom:1px solid #e1e3e6}.duet-table-minimal.duet-table-flattened tbody tr,.duet-table-minimal.duet-table-flattened tbody tr td{border-bottom:0 none}.duet-table-minimal.duet-table-flattened tbody tr td[data-heading]::before{display:none}.duet-table-minimal.duet-table-flattened tfoot{border-top:1px solid #e1e3e6}.duet-table-minimal.duet-table-flattened.duet-theme-turva tfoot{border-top-color:#e4e4e6}.duet-table-fixed table{table-layout:fixed}.duet-table-fixed tbody tr,.duet-table-fixed tbody tr td,.duet-table-fixed tbody tr td:first-child{padding:4px !important;vertical-align:text-bottom;border-bottom:0 none}.duet-table-fixed thead{display:none}.duet-table-fixed tbody tr,.duet-table-fixed tbody tr td{border-bottom:0 none}.duet-table-fixed:not(.duet-table-flattened) tfoot{border-top:1px solid #e1e3e6}.duet-table-fixed:not(.duet-table-flattened).duet-theme-turva tfoot{border-top-color:#e4e4e6}.duet-table-scrollable{position:relative;width:100%;overflow-x:auto;background:linear-gradient(90deg, #fff 0%, rgba(255, 255, 255, 0)), linear-gradient(-90deg, #fff 0%, rgba(255, 255, 255, 0)) 100% 0, radial-gradient(farthest-side at 0% 50%, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0)), radial-gradient(farthest-side at 100% 50%, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0)) 100% 0%;background-repeat:no-repeat;background-attachment:local, local, scroll, scroll;background-size:100px 100%, 100px 100%, 12px 100%, 12px 100%}.duet-table-selected-column{background:rgba(0, 119, 179, 0.08)}.duet-theme-turva .duet-table-selected-column{background:rgba(68, 68, 69, 0.08)}.duet-table-sortable tbody tr td:first-child,.duet-table-sortable thead tr th:first-child{padding:20px}.duet-table-sortable:not(.duet-table-flattened) tfoot{border-top:1px solid #e1e3e6}.duet-table-sortable:not(.duet-table-flattened).duet-theme-turva tfoot{border-top-color:#e4e4e6}.duet-table-actions table{table-layout:auto}.duet-table-actions thead th:last-child{width:1px;white-space:nowrap}.duet-editable-table-table.duet-table-flattened tr{display:grid;grid-template-columns:repeat(2, 1fr);grid-auto-rows:auto;gap:10px}.duet-editable-table-table.duet-table-flattened tr.duet-table-action-row td:last-child::before{padding:0;content:\"\"}.duet-editable-table-table.duet-table-flattened td{grid-column:1/2}.duet-editable-table-table.duet-table-flattened td:first-child{grid-row:1;grid-column:1}.duet-editable-table-table.duet-table-flattened td:last-child{grid-row:1;grid-column:2}";
|
|
226
227
|
|
|
227
228
|
// remove wrapping speech marks.
|
|
228
229
|
// media query tokens are wrapped in speech marks,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, h, H as Host } from './index-
|
|
4
|
+
import { r as registerInstance, h, H as Host } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
|
|
7
7
|
const duetEmptyStateCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:block;width:100%;height:100%}.duet-empty-state{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;width:100%;height:100%;padding:48px;color:#00294d;text-align:center;background:#f5f8fa;border-radius:4px}.duet-empty-state.duet-theme-turva{color:#171c3a;background:#f5f5f7}";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, h, H as Host, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, h, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { c as createID } from './create-id-981107da.js';
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, c as createEvent$1, h, F as Fragment, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, c as createEvent$1, h, F as Fragment, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { a as actionArrowDownSmall } from './action-arrow-down-small-82273dc8.js';
|
|
6
6
|
import { a as actionArrowRightSmall } from './action-arrow-right-small-f9d2ba83.js';
|
|
7
7
|
import { a as actionNewWindowSmall } from './action-new-window-small-1945be91.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, h, g as getElement, H as Host } from './index-
|
|
4
|
+
import { r as registerInstance, h, g as getElement, H as Host } from './index-374256c8.js';
|
|
5
5
|
import { m as media_query_large, a as media_query_medium, b as media_query_small } from './tokens-8ff8c570.js';
|
|
6
6
|
import { w as watchForOptions, a as watchForElement } from './watch-options-dd55bce8.js';
|
|
7
7
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { h, r as registerInstance, c as createEvent$1, F as Fragment, H as Host, g as getElement } from './index-
|
|
4
|
+
import { h, r as registerInstance, c as createEvent$1, F as Fragment, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { f as formSearch } from './form-search-ea8e19ae.js';
|
|
6
6
|
import { m as media_query_large } from './tokens-8ff8c570.js';
|
|
7
7
|
import { d as disableBodyScroll, e as enableBodyScroll } from './bodyScrollLock.es6-61b5e9a4.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, c as createEvent, h, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, c as createEvent, h, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { a as actionNewWindowSmall } from './action-new-window-small-1945be91.js';
|
|
6
6
|
import { D as DuetStringsExternalDefaults } from './common-strings-97e04e4b.js';
|
|
7
7
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { E as Env, r as registerInstance, h, H as Host, g as getElement } from './index-
|
|
4
|
+
import { E as Env, r as registerInstance, h, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { g as getColorByName } from './token-utils-1f9435bc.js';
|
|
7
7
|
import './tokens.module-f4572ed7.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { f as formSearch } from './form-search-ea8e19ae.js';
|
|
6
6
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
7
7
|
import { c as createID } from './create-id-981107da.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, h, H as Host, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, h, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as isInternetExplorer } from './is-internet-explorer-62b3bdbd.js';
|
|
6
6
|
|
|
7
7
|
const duetLayoutCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:block;flex:1 0 auto;width:100%}:host(.duet-middle){display:flex}:host(.duet-middle) .duet-layout{padding:36px 28px !important}@media (min-width: 36em){:host(.duet-middle) .duet-layout{padding:48px 36px !important}}@media (min-width: 62em){:host(.duet-middle) .duet-layout{padding:56px !important}}:host(.duet-ie){height:100%}:host(.duet-middle.duet-ie){height:auto}.duet-layout{position:relative;padding:0 16px;margin:48px auto 36px}@media (min-width: 36em){.duet-layout{margin-top:72px}}.duet-layout.duet-layout-has-top{margin-top:0}.duet-layout.duet-m-0{margin-top:0 !important;margin-bottom:0 !important}.duet-layout.duet-center{display:flex;align-items:center;justify-content:center;width:100%;max-width:888px}@media (min-width: 36em){.duet-layout.duet-center{padding:0 48px}}@media (min-width: 48em){.duet-layout.duet-center{padding:0 72px}}@media (min-width: 62em){.duet-layout.duet-center{width:100%}}@media (min-width: 36em){.duet-layout{padding:0 28px}}@media (min-width: 62em){.duet-layout{display:flex;flex-direction:row;padding:0 56px;margin-bottom:48px}}@media (min-width: 76.25em){.duet-layout{max-width:1110px;padding:0}}.duet-main,.duet-sidebar,.duet-layout-top,.duet-layout-bottom{display:block;width:100%}.duet-layout-top{position:relative;display:block;width:100%;margin:72px auto 0}.duet-layout-top.duet-m-0{margin-top:0 !important;margin-bottom:0 !important}.duet-layout-top .duet-layout-top-wrapper{padding:0 20px;margin:0 auto}@media (min-width: 36em){.duet-layout-top .duet-layout-top-wrapper{padding:0 28px}}@media (min-width: 62em){.duet-layout-top .duet-layout-top-wrapper{padding:0 56px}}@media (min-width: 76.25em){.duet-layout-top .duet-layout-top-wrapper{max-width:1110px;padding:0}}.duet-center .duet-layout-top-wrapper{max-width:888px}@media (min-width: 36em){.duet-center .duet-layout-top-wrapper{padding:0 48px}}@media (min-width: 48em){.duet-center .duet-layout-top-wrapper{padding:0 72px}}@media (min-width: 62em){.duet-main{min-width:600px;margin:0 auto}.has-sidebar .duet-main{max-width:734px;margin-right:20px}}@media (min-width: 62em){.duet-sidebar{min-width:256px;max-width:356px}}@media (min-width: 62em){.duet-sidebar-container{width:auto;max-width:356px}}@media (min-width: 62em){.duet-sidebar-container.has-tabs{margin-top:89px}}@media (min-width: 62em){.duet-sidebar-container.sticky{position:sticky}.duet-sidebar-container.sticky.with-links{top:calc(3rem + 20px)}.duet-sidebar-container.sticky.without-links{top:calc(4rem + 20px)}}";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, h, g as getElement, H as Host } from './index-
|
|
4
|
+
import { r as registerInstance, h, g as getElement, H as Host } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { w as watchForOptions } from './watch-options-dd55bce8.js';
|
|
7
7
|
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, c as createEvent, h, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, c as createEvent, h, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { d as disableBodyScroll, e as enableBodyScroll } from './bodyScrollLock.es6-61b5e9a4.js';
|
|
6
6
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
7
7
|
import { c as createID } from './create-id-981107da.js';
|
|
8
|
-
import { f as focusElement, F as FocusGuard } from './focus-utils-
|
|
8
|
+
import { f as focusElement, F as FocusGuard } from './focus-utils-3769afc3.js';
|
|
9
9
|
import { f as isEscapeKey } from './keyboard-utils-88ea1007.js';
|
|
10
10
|
import { a as getLanguage, g as getLocaleString } from './language-utils-bf701d37.js';
|
|
11
11
|
import './string-utils-5954f458.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, h, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, h, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { a as getLanguage, g as getLocaleString } from './language-utils-bf701d37.js';
|
|
7
7
|
import { a as actionArrowDownSmall } from './action-arrow-down-small-82273dc8.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Built with Duet Design System
|
|
3
3
|
*/
|
|
4
|
-
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-
|
|
4
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-374256c8.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-cb76be7c.js';
|
|
6
6
|
import { c as createID } from './create-id-981107da.js';
|
|
7
7
|
import { a as isArrowRightKey, b as isArrowUpKey, c as isArrowDownKey, d as isArrowLeftKey, e as isBackspaceKey } from './keyboard-utils-88ea1007.js';
|
|
@@ -12,27 +12,77 @@ var actionAdd={"title":"action-add","tags":"action add plus","svg":"<svg fill=\"
|
|
|
12
12
|
|
|
13
13
|
var actionSubtract={"title":"action-subtract","tags":"action subtract minus remove delete cancel","svg":"<svg fill=\"currentColor\" viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\" role=\"img\"><path d=\"M.75 12.788a.75.75 0 0 1 0-1.5h22.5a.75.75 0 0 1 0 1.5z\"/></svg>"};
|
|
14
14
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
15
|
+
/**
|
|
16
|
+
* function that takes a string value or number and looks for any character resembling a minus,
|
|
17
|
+
* it will then replace it with a hypen-minus and return the parseFloat value of that string
|
|
18
|
+
* it will string / number cast the value to a number and return that number
|
|
19
|
+
* known issues: if a negative number is indicated with other characters than a "minus like" character, it will throw
|
|
20
|
+
* - an example is that some locales use (number) as an indicator for negative values instead of -number
|
|
21
|
+
*/
|
|
22
|
+
function SafeParseFloat(value, locale) {
|
|
23
|
+
let results;
|
|
24
|
+
if (typeof value === "string") {
|
|
25
|
+
//the minuses are NOT the same characters, they differ in unicode for some languages
|
|
26
|
+
// "‐", "−", "–", and "—"
|
|
27
|
+
let convertedMinus = value.replace("−", "-").replace("‐", "-").replace("−", "-").replace("–", "-").replace("—", "-");
|
|
28
|
+
if (locale) {
|
|
29
|
+
convertedMinus = ConvertToEnUS(convertedMinus, locale, false);
|
|
30
|
+
}
|
|
31
|
+
// replace all possible spaces from the string
|
|
32
|
+
convertedMinus = convertedMinus.replace(/\s+/g, "");
|
|
33
|
+
convertedMinus = convertedMinus.replace(/(?!^-?\d*\.{0,1}\d+$)/g, "");
|
|
34
|
+
/*
|
|
35
|
+
example: https://regex101.com/r/np7FqS/1
|
|
36
|
+
/(?!^-?\d*\.{0,1}\d+$)/g
|
|
37
|
+
Negative Lookahead (?!^-?\d*\.{0,1}\d+$)
|
|
38
|
+
Assert that the Regex below does not match
|
|
39
|
+
^ asserts position at start of a line
|
|
40
|
+
- matches the character - with index 4510 (2D16 or 558) literally (case sensitive)
|
|
41
|
+
? matches the previous token between zero and one times, as many times as possible, giving back as needed (greedy)
|
|
42
|
+
\d matches a digit (equivalent to [0-9])
|
|
43
|
+
* matches the previous token between zero and unlimited times, as many times as possible, giving back as needed (greedy)
|
|
44
|
+
\. matches the character . with index 4610 (2E16 or 568) literally (case sensitive)
|
|
45
|
+
{0,1} matches the previous token between zero and one times, as many times as possible, giving back as needed (greedy)
|
|
46
|
+
\d matches a digit (equivalent to [0-9])
|
|
47
|
+
+ matches the previous token between one and unlimited times, as many times as possible, giving back as needed (greedy)
|
|
48
|
+
$ asserts position at the end of a line
|
|
49
|
+
Global pattern flags
|
|
50
|
+
g modifier: global. All matches (don't return after first match)
|
|
51
|
+
m modifier: multi line. Causes ^ and $ to match the begin/end of each line (not only begin/end of string)
|
|
52
|
+
*/
|
|
53
|
+
results = parseFloat(convertedMinus);
|
|
33
54
|
}
|
|
34
|
-
|
|
35
|
-
|
|
55
|
+
if (typeof value === "number") {
|
|
56
|
+
results = parseFloat(String(value));
|
|
57
|
+
}
|
|
58
|
+
if (!isNaN(Number(results))) {
|
|
59
|
+
return Number(results);
|
|
60
|
+
}
|
|
61
|
+
if (value === null || value === undefined) {
|
|
62
|
+
return null;
|
|
63
|
+
}
|
|
64
|
+
throw new Error("Invalid value passed to SafeParseFloat");
|
|
65
|
+
}
|
|
66
|
+
// string conversion function that takes a locale and coverts decimal indicator to en-US indicator
|
|
67
|
+
// and takes the thousand separator for the given locale and transforms that to the en-US separator
|
|
68
|
+
function ConvertToEnUS(value, locale, replaceThousands = false) {
|
|
69
|
+
let replacedValue;
|
|
70
|
+
const localeSeparator = new Intl.NumberFormat(locale).format(1 / 2).replace(/[0-9]/g, "");
|
|
71
|
+
const enUSSeparator = new Intl.NumberFormat("en-US").format(1 / 2).replace(/[0-9]/g, "");
|
|
72
|
+
const thousandSeparator = new Intl.NumberFormat(locale).format(1000).replace(/[0-9]/g, "");
|
|
73
|
+
const enUSThousandSeparator = new Intl.NumberFormat("en-US").format(1000).replace(/[0-9]/g, "");
|
|
74
|
+
// double conversions to avoid ,->. and .->, at the same time resulting in a double conversion
|
|
75
|
+
replacedValue = value.replace(localeSeparator, "DECIMALSEPARATOR");
|
|
76
|
+
if (replaceThousands) {
|
|
77
|
+
replacedValue = replacedValue.replace(thousandSeparator, "THOUSANDSEPARATOR");
|
|
78
|
+
}
|
|
79
|
+
else {
|
|
80
|
+
replacedValue = replacedValue.replace(thousandSeparator, "");
|
|
81
|
+
}
|
|
82
|
+
replacedValue = replacedValue.replace("DECIMALSEPARATOR", enUSSeparator);
|
|
83
|
+
replacedValue = replacedValue.replace("THOUSANDSEPARATOR", enUSThousandSeparator);
|
|
84
|
+
return replacedValue;
|
|
85
|
+
}
|
|
36
86
|
const roundTo = (val, multiple) => Math.round(val / multiple) * multiple;
|
|
37
87
|
const clamp = (val, min, max) => Math.min(Math.max(val, min), max);
|
|
38
88
|
|
|
@@ -208,7 +258,7 @@ const DuetNumberInput = class {
|
|
|
208
258
|
this.handleChange = (ev) => {
|
|
209
259
|
const input = ev.target;
|
|
210
260
|
if (input && input.value) {
|
|
211
|
-
let value =
|
|
261
|
+
let value = SafeParseFloat(input.value, this.locale);
|
|
212
262
|
// Make sure that everything works if the user clears the input and
|
|
213
263
|
// starts typing non-numeric characters.
|
|
214
264
|
if (isNaN(value) || value == null) {
|
|
@@ -218,7 +268,7 @@ const DuetNumberInput = class {
|
|
|
218
268
|
this.duetInput.emit({
|
|
219
269
|
component: "duet-number-input",
|
|
220
270
|
originalEvent: ev,
|
|
221
|
-
value: this.
|
|
271
|
+
value: SafeParseFloat(this.value, this.locale).toString(),
|
|
222
272
|
valueAsNumber: value,
|
|
223
273
|
});
|
|
224
274
|
}
|
|
@@ -239,30 +289,29 @@ const DuetNumberInput = class {
|
|
|
239
289
|
if (input.value) {
|
|
240
290
|
// On blur we want to make sure that the user input is between the min and max values,
|
|
241
291
|
// and also round it up or down to the nearest step.
|
|
242
|
-
let value =
|
|
292
|
+
let value = SafeParseFloat(input.value, this.locale);
|
|
243
293
|
if (this.rounding) {
|
|
244
294
|
value = roundTo(value, this.step);
|
|
245
295
|
}
|
|
246
296
|
value = clamp(value, this.min, this.max);
|
|
247
|
-
if (value !==
|
|
297
|
+
if (value !== SafeParseFloat(this.value, this.locale) ||
|
|
298
|
+
value !== SafeParseFloat(this.focusedValue, this.locale)) {
|
|
248
299
|
this.setValue(value);
|
|
249
300
|
this.emitChange(ev);
|
|
250
301
|
}
|
|
251
302
|
}
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
});
|
|
259
|
-
}
|
|
303
|
+
this.duetChange.emit({
|
|
304
|
+
originalEvent: ev,
|
|
305
|
+
value: null,
|
|
306
|
+
valueAsNumber: null,
|
|
307
|
+
component: "duet-number-input",
|
|
308
|
+
});
|
|
260
309
|
};
|
|
261
310
|
/**
|
|
262
311
|
* Local methods.
|
|
263
312
|
*/
|
|
264
313
|
this.emitChange = (ev) => {
|
|
265
|
-
const currentValue = this.
|
|
314
|
+
const currentValue = SafeParseFloat(this.value, this.locale);
|
|
266
315
|
this.duetChange.emit({
|
|
267
316
|
originalEvent: ev,
|
|
268
317
|
value: currentValue.toString(),
|
|
@@ -270,10 +319,6 @@ const DuetNumberInput = class {
|
|
|
270
319
|
component: "duet-number-input",
|
|
271
320
|
});
|
|
272
321
|
};
|
|
273
|
-
this.cleanValue = (value) => {
|
|
274
|
-
// Returns a number that can be used in calculations.
|
|
275
|
-
return value ? parseLocaleFloat(value, this.locale) : null;
|
|
276
|
-
};
|
|
277
322
|
this.localizeValue = (value) => {
|
|
278
323
|
// Returns a localized string that can be used as input value.
|
|
279
324
|
return value.toLocaleString(this.locale);
|
|
@@ -290,13 +335,13 @@ const DuetNumberInput = class {
|
|
|
290
335
|
if (ev) {
|
|
291
336
|
ev.preventDefault();
|
|
292
337
|
}
|
|
293
|
-
const
|
|
338
|
+
const cleanedValue = SafeParseFloat(this.value, this.locale);
|
|
294
339
|
// Only fire change event when necessary
|
|
295
|
-
if (
|
|
340
|
+
if (cleanedValue === this.max) {
|
|
296
341
|
return;
|
|
297
342
|
}
|
|
298
343
|
// in cases where no value set, incrementing should go to min
|
|
299
|
-
let newValue =
|
|
344
|
+
let newValue = cleanedValue == null ? this.min : cleanedValue + this.step;
|
|
300
345
|
// handle cases where value is not multiple of step
|
|
301
346
|
// e.g. if someone enters 199, with a step of 100, add should go to 200
|
|
302
347
|
// and if someone enters 101, add should also go to 200
|
|
@@ -304,8 +349,8 @@ const DuetNumberInput = class {
|
|
|
304
349
|
const adjustment = newValue % this.step;
|
|
305
350
|
newValue -= adjustment;
|
|
306
351
|
}
|
|
307
|
-
|
|
308
|
-
this.value = this.localizeValue(
|
|
352
|
+
const clampedValue = clamp(newValue, this.min, this.max);
|
|
353
|
+
this.value = this.localizeValue(clampedValue);
|
|
309
354
|
this.emitChange(ev);
|
|
310
355
|
};
|
|
311
356
|
this.subtract = (ev) => {
|
|
@@ -314,7 +359,7 @@ const DuetNumberInput = class {
|
|
|
314
359
|
if (ev) {
|
|
315
360
|
ev.preventDefault();
|
|
316
361
|
}
|
|
317
|
-
const currentValue = this.
|
|
362
|
+
const currentValue = SafeParseFloat(this.value, this.locale);
|
|
318
363
|
// Only fire change event when necessary.
|
|
319
364
|
if (currentValue === this.min) {
|
|
320
365
|
return;
|
|
@@ -339,7 +384,7 @@ const DuetNumberInput = class {
|
|
|
339
384
|
inheritGlobalTheme(this);
|
|
340
385
|
// Format the number value to a localeString initially.
|
|
341
386
|
if (this.value) {
|
|
342
|
-
this.value = this.localizeValue(
|
|
387
|
+
this.value = this.localizeValue(SafeParseFloat(this.value, this.locale));
|
|
343
388
|
}
|
|
344
389
|
}
|
|
345
390
|
/**
|
|
@@ -354,7 +399,7 @@ const DuetNumberInput = class {
|
|
|
354
399
|
this.duetInputElement.value = "";
|
|
355
400
|
}
|
|
356
401
|
formatAnnouncement() {
|
|
357
|
-
const current = this.
|
|
402
|
+
const current = SafeParseFloat(this.value, this.locale);
|
|
358
403
|
if (current == null) {
|
|
359
404
|
return "";
|
|
360
405
|
}
|
|
@@ -367,7 +412,7 @@ const DuetNumberInput = class {
|
|
|
367
412
|
render() {
|
|
368
413
|
const identifier = this.identifier || this.inputId;
|
|
369
414
|
const maxlength = `${this.localizeValue(this.max)} ${this.unit}`.length;
|
|
370
|
-
const cleanedValue = this.
|
|
415
|
+
const cleanedValue = SafeParseFloat(this.value, this.locale);
|
|
371
416
|
return (h(Host, { class: {
|
|
372
417
|
"duet-theme-turva": this.theme === "turva",
|
|
373
418
|
"duet-expand": this.expand,
|