@duetds/components 5.1.3 → 5.1.6
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 +225 -36
- package/lib/cjs/action-arrow-right-small-a25eb475.js +8 -0
- package/lib/cjs/duet-action-button.cjs.entry.js +17 -6
- 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 +3 -4
- package/lib/cjs/duet-button_2.cjs.entry.js +5 -4
- package/lib/cjs/duet-caption_4.cjs.entry.js +3 -3
- package/lib/cjs/duet-card.cjs.entry.js +3 -3
- 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 +2 -2
- 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 +105 -27
- 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 +23 -4
- package/lib/cjs/duet-grid_2.cjs.entry.js +2 -2
- package/lib/cjs/duet-header_2.cjs.entry.js +3 -3
- package/lib/cjs/duet-hero.cjs.entry.js +1 -1
- package/lib/cjs/duet-icon.cjs.entry.js +3 -3
- package/lib/cjs/duet-input_2.cjs.entry.js +56 -4
- 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 +1 -1
- package/lib/cjs/duet-pagination_2.cjs.entry.js +1 -1
- 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 +2 -2
- 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 +2 -2
- 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 +2 -2
- 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 +2 -2
- package/lib/cjs/{focus-utils-85b1fb81.js → focus-utils-9ccade35.js} +1 -1
- package/lib/cjs/{index-a29ba279.js → index-014f74e2.js} +1 -1
- package/lib/cjs/loader.cjs.js +2 -2
- package/lib/cjs/{token-utils-f402e205.js → token-utils-50a1f7e2.js} +16 -1
- package/lib/cjs/{tokens-8596cece.js → tokens-29450bcb.js} +3 -0
- package/lib/cjs/{tokens.module-6b2df1c2.js → tokens.module-ef598645.js} +2 -0
- package/lib/collection/components/duet-action-button/duet-action-button.css +2 -2
- package/lib/collection/components/duet-action-button/duet-action-button.js +14 -2
- package/lib/collection/components/duet-button/duet-button.css +48 -16
- package/lib/collection/components/duet-button/duet-button.js +2 -1
- package/lib/collection/components/duet-footer/duet-footer.css +154 -0
- package/lib/collection/components/duet-footer/duet-footer.js +135 -5
- package/lib/collection/components/duet-input/duet-input.css +49 -0
- package/lib/collection/components/duet-input/duet-input.js +132 -3
- package/lib/collection/components/duet-step/duet-step.js +1 -1
- package/lib/collection/components/duet-stepper/duet-stepper.js +1 -1
- package/lib/collection/components/duet-table/duet-table.js +1 -1
- package/lib/collection/components/duet-upload/duet-upload.js +136 -27
- package/lib/collection/components/duet-upload/upload-editable-item-pending.js +7 -0
- package/lib/collection/utils/token-utils.js +14 -0
- package/lib/custom-elements-bundle/index.js +216 -41
- package/lib/duet/duet.esm.js +1 -1
- package/lib/duet/duet.js +1 -1
- package/lib/duet/{p-632e25d1.system.entry.js → p-00e6a13d.system.entry.js} +1 -1
- package/lib/duet/{p-ac1e6f4b.system.js → p-0447601c.system.js} +1 -1
- package/lib/duet/{p-bc8c3ace.system.js → p-04b00c25.system.js} +1 -1
- package/lib/duet/{p-c435f7e8.entry.js → p-06fde0d1.entry.js} +1 -1
- package/lib/duet/{p-94dc3e07.system.entry.js → p-13d2c818.system.entry.js} +1 -1
- package/lib/duet/p-13df0560.system.entry.js +4 -0
- package/lib/duet/{p-62cc6d2a.entry.js → p-17c7514e.entry.js} +1 -1
- package/lib/duet/p-18cc5627.system.js +4 -0
- package/lib/duet/{p-ebd9782a.system.entry.js → p-19073b04.system.entry.js} +1 -1
- package/lib/duet/{p-497750f2.entry.js → p-1953f729.entry.js} +1 -1
- package/lib/duet/{p-b9120f45.system.entry.js → p-1faf5cfe.system.entry.js} +1 -1
- package/lib/duet/{p-bd322f8f.js → p-206285a6.js} +1 -1
- package/lib/duet/{p-28b24806.system.entry.js → p-21f33ec5.system.entry.js} +1 -1
- package/lib/duet/{p-c2ad83a9.entry.js → p-23779e01.entry.js} +1 -1
- package/lib/duet/{p-f2ad1371.entry.js → p-23b467cc.entry.js} +1 -1
- package/lib/duet/{p-3bf4c99a.entry.js → p-2999ea4f.entry.js} +1 -1
- package/lib/duet/p-2a9db427.system.entry.js +4 -0
- package/lib/duet/{p-e4d54f1e.system.entry.js → p-2daca660.system.entry.js} +1 -1
- package/lib/duet/{p-18e17e10.entry.js → p-2ed50edc.entry.js} +1 -1
- package/lib/duet/{p-8d4c33ed.system.entry.js → p-322ab135.system.entry.js} +1 -1
- package/lib/duet/{p-e530ae17.entry.js → p-35957177.entry.js} +1 -1
- package/lib/duet/p-377f68c5.system.entry.js +4 -0
- package/lib/duet/{p-ad07f399.js → p-398a79a0.js} +1 -1
- package/lib/duet/p-3cc51ea1.entry.js +4 -0
- package/lib/duet/{p-7dec1cfd.entry.js → p-412a2ce3.entry.js} +1 -1
- package/lib/duet/{p-6910ace8.system.entry.js → p-458c1110.system.entry.js} +1 -1
- package/lib/duet/p-47058313.entry.js +4 -0
- package/lib/duet/{p-aaed5ea2.entry.js → p-4727c5c5.entry.js} +1 -1
- package/lib/duet/{p-3e1145b2.entry.js → p-5104272f.entry.js} +1 -1
- package/lib/duet/{p-7e17fd75.system.entry.js → p-513d8f06.system.entry.js} +1 -1
- package/lib/duet/{p-0e6dd740.entry.js → p-5186bfcf.entry.js} +1 -1
- package/lib/duet/{p-acdd49f6.entry.js → p-520d1c93.entry.js} +1 -1
- package/lib/duet/p-54e3d301.system.entry.js +4 -0
- package/lib/duet/{p-28feed35.system.entry.js → p-56ed6884.system.entry.js} +1 -1
- package/lib/duet/p-5752ff1c.entry.js +4 -0
- package/lib/duet/p-583c5a60.entry.js +4 -0
- package/lib/duet/{p-995ecd9d.system.entry.js → p-5c085a4a.system.entry.js} +1 -1
- package/lib/duet/p-6190e2d6.system.js +4 -0
- package/lib/duet/{p-ca79fa1a.js → p-6194272d.js} +1 -1
- package/lib/duet/{p-f0f60ea3.entry.js → p-62915653.entry.js} +1 -1
- package/lib/duet/{p-c06452b7.system.entry.js → p-7020d5a8.system.entry.js} +1 -1
- package/lib/duet/{p-9318e1c2.system.entry.js → p-71c7fa31.system.entry.js} +1 -1
- package/lib/duet/{p-ffbe9ffc.entry.js → p-7a5bf551.entry.js} +1 -1
- package/lib/duet/p-7cbb6eba.js +4 -0
- package/lib/duet/{p-57f58be7.entry.js → p-7de2b748.entry.js} +1 -1
- package/lib/duet/{p-a6b6a918.system.entry.js → p-7fcbf42e.system.entry.js} +1 -1
- package/lib/duet/{p-5a434b4e.system.entry.js → p-84237fd2.system.entry.js} +1 -1
- package/lib/duet/{p-dea3d7f9.system.entry.js → p-8c8f15ed.system.entry.js} +1 -1
- package/lib/duet/{p-d460ac7d.entry.js → p-8fed1e36.entry.js} +1 -1
- package/lib/duet/{p-a3857cd4.system.entry.js → p-90870281.system.entry.js} +1 -1
- package/lib/duet/{p-b683fec1.system.entry.js → p-914a5315.system.entry.js} +1 -1
- package/lib/duet/{p-8ee6f874.system.entry.js → p-96e42603.system.entry.js} +1 -1
- package/lib/duet/p-97900023.entry.js +4 -0
- package/lib/duet/{p-20814483.entry.js → p-99bbbecd.entry.js} +1 -1
- package/lib/duet/p-9cca0bb4.js +4 -0
- package/lib/duet/p-9e759a4a.system.entry.js +4 -0
- package/lib/duet/{p-bd122a6e.system.entry.js → p-9e8afa21.system.entry.js} +1 -1
- package/lib/duet/{p-f8dd1339.entry.js → p-9ff69b54.entry.js} +1 -1
- package/lib/duet/{p-955b90c3.system.entry.js → p-a2eafa77.system.entry.js} +1 -1
- package/lib/duet/{p-2b250ac6.system.entry.js → p-a53ca782.system.entry.js} +1 -1
- package/lib/duet/{p-3f65158e.entry.js → p-a74ed7f0.entry.js} +1 -1
- package/lib/duet/p-a83aa6f3.entry.js +4 -0
- package/lib/duet/p-a93a04b9.system.js +4 -0
- package/lib/duet/p-a9bd0a4b.entry.js +4 -0
- package/lib/duet/{p-f42c4e0f.system.entry.js → p-abdf47c8.system.entry.js} +1 -1
- package/lib/duet/p-ad196791.system.js +4 -0
- package/lib/duet/{p-5e591b97.entry.js → p-ae7580c4.entry.js} +1 -1
- package/lib/duet/{p-cd07c340.entry.js → p-b04e51be.entry.js} +1 -1
- package/lib/duet/{p-456f44e9.system.entry.js → p-b1f08a11.system.entry.js} +1 -1
- package/lib/duet/{p-7df54c59.entry.js → p-b477f0b1.entry.js} +1 -1
- package/lib/duet/{p-2c31428e.system.entry.js → p-b504bfcc.system.entry.js} +1 -1
- package/lib/duet/{p-3e4a5b9c.entry.js → p-b8a6c198.entry.js} +1 -1
- package/lib/duet/{p-4268681b.entry.js → p-ba2d5d3b.entry.js} +1 -1
- package/lib/duet/p-bb05bcf9.entry.js +4 -0
- package/lib/duet/{p-ff5ddd90.system.entry.js → p-bbdbff69.system.entry.js} +1 -1
- package/lib/duet/{p-b7420414.entry.js → p-c1ec46db.entry.js} +1 -1
- package/lib/duet/{p-28e309f1.entry.js → p-c63e58e3.entry.js} +1 -1
- package/lib/duet/{p-adb092e7.entry.js → p-ce936701.entry.js} +1 -1
- package/lib/duet/{p-48307b31.entry.js → p-ced1983f.entry.js} +1 -1
- package/lib/duet/p-cf67a60b.entry.js +4 -0
- package/lib/duet/{p-28e6da82.system.entry.js → p-d132dde7.system.entry.js} +1 -1
- package/lib/duet/p-d1746325.js +4 -0
- package/lib/duet/p-d312b69e.system.entry.js +4 -0
- package/lib/duet/{p-b6cbe383.entry.js → p-d64b4b43.entry.js} +1 -1
- package/lib/duet/{p-5969399b.system.entry.js → p-dccd1711.system.entry.js} +1 -1
- package/lib/duet/{p-a056cc14.system.entry.js → p-dd58a713.system.entry.js} +1 -1
- package/lib/duet/{p-712c9016.system.entry.js → p-df8c5af0.system.entry.js} +1 -1
- package/lib/duet/{p-83be3810.entry.js → p-e21029cc.entry.js} +1 -1
- package/lib/duet/{p-cfe414d2.system.entry.js → p-e7d9d84b.system.entry.js} +1 -1
- package/lib/duet/{p-1c67e70d.system.entry.js → p-ed5c2f24.system.entry.js} +1 -1
- package/lib/duet/{p-53849160.entry.js → p-ef888954.entry.js} +1 -1
- package/lib/duet/{p-0304408d.system.entry.js → p-f3d0d952.system.entry.js} +1 -1
- package/lib/duet/p-f476cb84.system.js +4 -0
- package/lib/duet/{p-b9d3eeb1.system.entry.js → p-f8927797.system.entry.js} +1 -1
- package/lib/duet/{p-8e0bad03.entry.js → p-fb70b22b.entry.js} +1 -1
- package/lib/duet/{p-f4664942.system.entry.js → p-fb81d343.system.entry.js} +2 -2
- package/lib/duet/{p-21d7cb5d.system.entry.js → p-fece90db.system.entry.js} +1 -1
- package/lib/esm/action-arrow-right-small-f9d2ba83.js +6 -0
- package/lib/esm/duet-action-button.entry.js +17 -6
- 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 +2 -3
- package/lib/esm/duet-button_2.entry.js +5 -4
- package/lib/esm/duet-caption_4.entry.js +3 -3
- package/lib/esm/duet-card.entry.js +3 -3
- 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 +2 -2
- 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 +105 -27
- 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 +23 -4
- package/lib/esm/duet-grid_2.entry.js +2 -2
- package/lib/esm/duet-header_2.entry.js +3 -3
- package/lib/esm/duet-hero.entry.js +1 -1
- package/lib/esm/duet-icon.entry.js +3 -3
- package/lib/esm/duet-input_2.entry.js +56 -4
- 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 +1 -1
- package/lib/esm/duet-pagination_2.entry.js +1 -1
- 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 +2 -2
- 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 +2 -2
- 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 +2 -2
- 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 +2 -2
- package/lib/esm/{focus-utils-429ccac4.js → focus-utils-fe498b6c.js} +1 -1
- package/lib/esm/{index-089c3eed.js → index-715101b6.js} +1 -1
- package/lib/esm/loader.js +2 -2
- package/lib/esm/{token-utils-e9a69acf.js → token-utils-1f9435bc.js} +16 -2
- package/lib/esm/{tokens-e110dc89.js → tokens-8ff8c570.js} +3 -0
- package/lib/esm/{tokens.module-49cbf963.js → tokens.module-f4572ed7.js} +2 -0
- package/lib/esm-es5/action-arrow-right-small-f9d2ba83.js +4 -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 +2 -2
- package/lib/esm-es5/duet-button_2.entry.js +2 -2
- 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 +1 -1
- 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 +1 -1
- 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 +2 -2
- 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 +2 -2
- 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 +1 -1
- 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 +2 -2
- 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-fe498b6c.js +4 -0
- package/lib/esm-es5/{index-089c3eed.js → index-715101b6.js} +1 -1
- package/lib/esm-es5/loader.js +1 -1
- package/lib/esm-es5/token-utils-1f9435bc.js +4 -0
- package/lib/esm-es5/tokens-8ff8c570.js +4 -0
- package/lib/esm-es5/{tokens.module-49cbf963.js → tokens.module-f4572ed7.js} +1 -1
- package/lib/types/components/duet-button/duet-button.d.ts +1 -1
- package/lib/types/components/duet-footer/duet-footer.d.ts +30 -1
- package/lib/types/components/duet-input/duet-input.d.ts +23 -0
- package/lib/types/components/duet-upload/duet-upload.d.ts +18 -1
- package/lib/types/components/duet-upload/upload-editable-item-pending.d.ts +6 -0
- package/lib/types/components.d.ts +71 -3
- package/lib/types/utils/token-utils.d.ts +1 -0
- package/package.json +5 -5
- package/lib/duet/p-021f4ce6.entry.js +0 -4
- package/lib/duet/p-165aeec8.system.entry.js +0 -4
- package/lib/duet/p-27189fa0.entry.js +0 -4
- package/lib/duet/p-4cb2c888.entry.js +0 -4
- package/lib/duet/p-4e2532c7.system.js +0 -4
- package/lib/duet/p-52b6d127.entry.js +0 -4
- package/lib/duet/p-694ebf05.entry.js +0 -4
- package/lib/duet/p-7888e2d8.entry.js +0 -4
- package/lib/duet/p-7ce6ba93.system.entry.js +0 -4
- package/lib/duet/p-80e16593.entry.js +0 -4
- package/lib/duet/p-8143f3de.js +0 -4
- package/lib/duet/p-86777eb7.system.js +0 -4
- package/lib/duet/p-93f9ccbc.system.entry.js +0 -4
- package/lib/duet/p-94def463.entry.js +0 -4
- package/lib/duet/p-ad4570bf.system.entry.js +0 -4
- package/lib/duet/p-b2d00c4b.system.entry.js +0 -4
- package/lib/duet/p-b48323e2.system.entry.js +0 -4
- package/lib/duet/p-c5c212fd.entry.js +0 -4
- package/lib/duet/p-cb445018.js +0 -4
- package/lib/duet/p-ddb6344c.system.js +0 -4
- package/lib/duet/p-fa99eaa4.system.js +0 -4
- package/lib/esm-es5/focus-utils-429ccac4.js +0 -4
- package/lib/esm-es5/token-utils-e9a69acf.js +0 -4
- package/lib/esm-es5/tokens-e110dc89.js +0 -4
- package/lib/html.html-data.json +0 -5325
|
@@ -1,15 +1,15 @@
|
|
|
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-715101b6.js';
|
|
5
5
|
import { D as DuetStringsExternalDefaults } from './common-strings-97e04e4b.js';
|
|
6
6
|
import { a as getLanguage, g as getLocaleString } from './language-utils-bf701d37.js';
|
|
7
7
|
import { i as inheritGlobalTheme } from './themeable-component-e8fc98bf.js';
|
|
8
|
-
import { g as getColorByName } from './token-utils-
|
|
8
|
+
import { g as getColorByName } from './token-utils-1f9435bc.js';
|
|
9
9
|
import './string-utils-5954f458.js';
|
|
10
|
-
import './tokens.module-
|
|
10
|
+
import './tokens.module-f4572ed7.js';
|
|
11
11
|
|
|
12
|
-
const duetButtonCss = "*,*::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:8px !important;margin-bottom:12px !important;position:relative;z-index:1;display:inline-flex;width:auto;max-width:100%;vertical-align:bottom;-webkit-tap-highlight-color:transparent}:host:last-child,:host:last-of-type{margin-right:0 !important}@media (max-width: 35.9375em){:host{width:100%}}:host(.duet-small){margin-right:2px !important;margin-bottom:8px !important}:host(.duet-small):last-child,:host(.duet-small):last-of-type{margin-right:0 !important}@media (max-width: 35.9375em){:host(.duet-small){width:auto}}:host(.duet-expand){width:100% !important}:host(.duet-m-0){margin:0 !important}:host(.duet-fixed){width:auto !important}:host(:last-child){margin-right:0 !important}.duet-button-container{position:relative;width:100%}.duet-button{padding:14px 27px 15px !important;-webkit-user-select:none;user-select:none;position:relative;z-index:100;display:block;width:100%;min-width:8rem;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;font-weight:600;font-variant-numeric:tabular-nums;-webkit-hyphens:auto;hyphens:auto;line-height:1.1;color:#0077b3 !important;text-align:center;text-decoration:none;cursor:pointer;background:transparent;border-style:solid;border-width:2px;border-radius:20rem;transition:background-color 300ms ease, color 300ms ease, border 300ms ease, box-shadow 300ms ease}.duet-button.duet-p-0{padding:0 !important}.duet-button.duet-m-0{margin:0 !important}.duet-button.duet-button-text-center{text-align:center !important}.duet-button.duet-button-is-small:not(.duet-button-icon-only){padding:9px 19px 10px !important;min-width:5.3333333333rem;font-size:0.875rem}.duet-button.duet-button-is-small:not(.duet-button-icon-only).icon{padding-left:48px !important}.duet-button.duet-button-is-small:not(.duet-button-icon-only).icon-right{padding-right:48px !important;padding-left:20px !important}.duet-theme-turva .duet-button{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#c60c30 !important}.duet-button .duet-button-contents{position:relative;display:inline-block;margin:0 auto;pointer-events:none}.duet-button.duet-no-wrap{white-space:nowrap}.duet-button.icon{padding-left:52px !important}.duet-button.icon-right{padding-right:52px !important;padding-left:28px !important}.duet-button svg{width:100%;min-width:100%;fill:currentColor}.duet-button .duet-button-icon{position:absolute;top:50%;left:-28px;display:flex;align-items:center;justify-content:center;width:16px;height:16px;margin:0 !important;transform:translateY(-50%)}.duet-button .duet-button-icon duet-icon{width:16px;height:16px}.duet-button .duet-button-icon.right{right:-28px;left:auto}.duet-button .duet-button-icon.large{left:-32px;width:20px;height:20px}.duet-button .duet-button-icon.large duet-icon{width:20px;height:20px}.duet-button .duet-button-icon.large.right{right:-32px;left:auto}.duet-button .duet-button-icon.medium-small{left:-16px;width:10px;height:10px;padding-top:1px}.duet-button .duet-button-icon.medium-small duet-icon{width:10px;height:10px}.duet-button .duet-button-icon.medium-small.right{right:-16px;left:auto}.duet-button .duet-button-icon.small{left:-16px;width:7px;height:7px}.duet-button .duet-button-icon.small duet-icon{width:7px;height:7px}.duet-button .duet-button-icon.small.right{right:-16px;left:auto}.duet-button:focus{outline:0;box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}.duet-theme-turva .duet-button:focus{box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}.duet-button:active{opacity:0.75;transition:none}.duet-button.default{border-color:#e1e3e6}.duet-theme-turva .duet-button.default{color:#c60c30 !important;border-color:#e4e4e6}.duet-button.default:hover{border-color:#0077b3}.duet-theme-turva .duet-button.default:hover{border-color:#c60c30}.duet-button.default.duet-button-negative{background-color:white}.duet-theme-turva .duet-button.default.duet-button-negative{background-color:#e4e4e6 !important}.duet-button.default.duet-button-negative:hover{color:#0077b3 !important;border-color:#0077b3}.duet-theme-turva .duet-button.default.duet-button-negative:hover{color:#c60c30 !important;border-color:#c60c30}.duet-button.primary{color:white !important;background:#0077b3;border-color:#0077b3}.duet-theme-turva .duet-button.primary{color:white !important;background:#c60c30;border-color:#c60c30}.duet-button.primary:hover{background:#005f8f;border-color:#005f8f;box-shadow:0 4px 20px rgba(34, 34, 34, 0.1)}.duet-theme-turva .duet-button.primary:hover{background:#940925;border-color:#940925}.duet-button.primary:focus{outline:0;box-shadow:0 0 0 1px white, 0 0 0 4px rgba(0, 119, 179, 0.75)}.duet-theme-turva .duet-button.primary:focus{box-shadow:0 0 0 1px white, 0 0 0 4px rgba(23, 28, 58, 0.7)}.duet-button.secondary{color:#00294d !important;background:transparent;border-color:#00294d}.duet-theme-turva .duet-button.secondary{color:#171c3a !important;border-color:#171c3a}.duet-button.secondary:hover{color:#0077b3 !important;border-color:#0077b3}.duet-theme-turva .duet-button.secondary:hover{color:#c60c30 !important;border-color:#c60c30}.duet-button.secondary.duet-button-negative{color:#e1e3e6 !important;border-color:white}.duet-theme-turva .duet-button.secondary.duet-button-negative{color:#e4e4e6 !important}.duet-button.secondary.duet-button-negative:hover{color:#0077b3 !important;border-color:#0077b3}.duet-theme-turva .duet-button.secondary.duet-button-negative:hover{color:#c60c30 !important;border-color:#c60c30}.duet-button.negative{color:#00294d !important;background:white;border-color:white}.duet-theme-turva .duet-button.negative{color:#171c3a !important}.duet-button.negative:hover{color:white !important;background:transparent;border-color:white}.duet-button.negative:focus{outline:0;box-shadow:0 0 0 1px #00294d, 0 0 0 4px rgba(255, 255, 255, 0.7)}.duet-theme-turva .duet-button.negative:focus{box-shadow:0 0 0 1px #171c3a, 0 0 0 4px rgba(255, 255, 255, 0.7)}.duet-button.destructive-primary{color:white !important;background:#de2362;border-color:#de2362}.duet-theme-turva .duet-button.destructive-primary{color:white !important;background:#e02a0d;border-color:#e02a0d}.duet-button.destructive-primary:hover{background:#b21c4e;border-color:#b21c4e;box-shadow:0 4px 20px rgba(34, 34, 34, 0.1)}.duet-theme-turva .duet-button.destructive-primary:hover{background:#b3220a}.duet-button.destructive,.duet-button.destructive-secondary{color:#de2362 !important;background:white;border-color:#de2362}.duet-theme-turva .duet-button.destructive,.duet-theme-turva .duet-button.destructive-secondary{color:#e02a0d !important;background:white;border-color:#e02a0d}.duet-button.destructive:hover,.duet-button.destructive-secondary:hover{color:white !important;background:#b21c4e;border-color:#b21c4e}.duet-theme-turva .duet-button.destructive:hover,.duet-theme-turva .duet-button.destructive-secondary:hover{color:white !important;background:#b3220a;border-color:#b3220a}.duet-button.plain{min-width:48px;padding-right:0 !important;padding-left:0 !important;line-height:1.5;text-align:left;background:transparent;border:0;border-color:transparent;border-radius:4px}.duet-theme-turva .duet-button.plain{color:#c60c30 !important;background:transparent;border-color:transparent}.duet-button.plain.icon{padding-left:20px !important}.duet-button.plain.icon.icon-right{padding-right:20px !important;padding-left:0 !important}.duet-button.plain.icon.medium{padding-left:24px !important}.duet-button.plain.icon.medium.icon-right{padding-right:24px !important;padding-left:0 !important}.duet-button.plain.icon.large{padding-left:30px !important}.duet-button.plain.icon.large.icon-right{padding-right:30px !important;padding-left:0 !important}.duet-button.plain .duet-button-icon.left{left:-16.6666666667px !important}.duet-button.plain .duet-button-icon.left.medium{left:-24px !important}.duet-button.plain .duet-button-icon.left.large{left:-30px !important}.duet-button.plain .duet-button-icon.right{right:-16.6666666667px !important}.duet-button.plain .duet-button-icon.right.medium{right:-24px !important}.duet-button.plain .duet-button-icon.right.large{right:-30px !important}.duet-button.plain[disabled]{color:#657787 !important;background:transparent !important;border-color:transparent !important}.duet-theme-turva .duet-button.plain[disabled]{color:transparent !important;background:transparent !important;border-color:#e4e4e6 !important}.duet-button.plain:hover{color:#004d80 !important;background:transparent !important}.duet-theme-turva .duet-button.plain:hover{color:#940925 !important}.duet-button.plain.duet-button-negative{color:white !important}.duet-theme-turva .duet-button.plain.duet-button-negative{color:#e4e4e6 !important}.duet-button.plain.duet-button-negative:hover{color:#0077b3 !important}.duet-theme-turva .duet-button.plain.duet-button-negative:hover{color:#c60c30 !important}.duet-button.duet-button-icon-only{min-width:48px;min-height:48px;padding:0 !important}.duet-button.duet-button-icon-only .duet-button-contents{position:static}.duet-button.duet-button-icon-only .duet-button-icon.left.large,.duet-button.duet-button-icon-only .duet-button-icon.left.medium,.duet-button.duet-button-icon-only .duet-button-icon.left.small{position:absolute;top:50% !important;left:50% !important;padding:0;margin:0;transform:translateX(-50%) translateY(-50%)}.duet-button[disabled],.duet-button[disabled]:hover,.duet-button.duet-button-negative[disabled],.duet-button.duet-button-negative[disabled]:hover{color:#657787 !important;background:#e1e3e6 !important;border-color:#e1e3e6 !important;box-shadow:none !important}.duet-theme-turva .duet-button[disabled],.duet-theme-turva .duet-button[disabled]:hover,.duet-theme-turva .duet-button.duet-button-negative [disabled],.duet-theme-turva .duet-button.duet-button-negative [disabled]:hover{color:#747475 !important;background:#e4e4e6 !important;border-color:#e4e4e6 !important}.duet-button-is-loading.primary{color:white}.duet-button-is-loading.default{color:#0077b3}.duet-button-is-loading.default.duet-theme-turva{color:#c60c30}.duet-button-is-loading .duet-button-contents{visibility:hidden;opacity:0}";
|
|
12
|
+
const duetButtonCss = "*,*::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:8px !important;margin-bottom:12px !important;position:relative;z-index:1;display:inline-flex;width:auto;max-width:100%;vertical-align:bottom;-webkit-tap-highlight-color:transparent}:host:last-child,:host:last-of-type{margin-right:0 !important}@media (max-width: 35.9375em){:host{width:100%}}:host(.input-button){z-index:250}:host(.duet-small){margin-right:2px !important;margin-bottom:8px !important}:host(.duet-small):last-child,:host(.duet-small):last-of-type{margin-right:0 !important}@media (max-width: 35.9375em){:host(.duet-small){width:auto}}:host(.duet-expand){width:100% !important}:host(.duet-m-0){margin:0 !important}:host(.duet-fixed){width:auto !important}:host(:last-child){margin-right:0 !important}.duet-button-container{position:relative;width:100%}.duet-button{padding:14px 27px 15px !important;-webkit-user-select:none;user-select:none;position:relative;z-index:100;display:block;width:100%;min-width:8rem;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;font-weight:600;-webkit-hyphens:auto;hyphens:auto;line-height:1.1;color:#0077b3 !important;text-align:center;text-decoration:none;cursor:pointer;background:transparent;border-style:solid;border-width:2px;border-radius:20rem;transition:background-color 300ms ease, color 300ms ease, border 300ms ease, box-shadow 300ms ease}.duet-button.duet-p-0{padding:0 !important}.duet-button.duet-m-0{margin:0 !important}.duet-button:not(.input-button-primary,.input-button-secondary){font-variant-numeric:tabular-nums}.duet-button.duet-button-text-center{text-align:center !important}.duet-button.duet-button-is-small:not(.duet-button-icon-only){padding:9px 19px 10px !important;min-width:5.3333333333rem;font-size:0.875rem}.duet-button.duet-button-is-small:not(.duet-button-icon-only).icon{padding-left:48px !important}.duet-button.duet-button-is-small:not(.duet-button-icon-only).icon-right{padding-right:48px !important;padding-left:20px !important}.duet-theme-turva .duet-button{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#c60c30 !important}.duet-button .duet-button-contents{position:relative;display:inline-block;margin:0 auto;pointer-events:none}.duet-button.duet-no-wrap{white-space:nowrap}.duet-button.icon{padding-left:52px !important}.duet-button.icon-right{padding-right:52px !important;padding-left:28px !important}.duet-button svg{width:100%;min-width:100%;fill:currentColor}.duet-button .duet-button-icon{position:absolute;top:50%;left:-28px;display:flex;align-items:center;justify-content:center;width:16px;height:16px;margin:0 !important;transform:translateY(-50%)}.duet-button .duet-button-icon duet-icon{width:16px;height:16px}.duet-button .duet-button-icon.right{right:-28px;left:auto}.duet-button .duet-button-icon.large{left:-32px;width:20px;height:20px}.duet-button .duet-button-icon.large duet-icon{width:20px;height:20px}.duet-button .duet-button-icon.large.right{right:-32px;left:auto}.duet-button .duet-button-icon.medium-small{left:-16px;width:10px;height:10px;padding-top:1px}.duet-button .duet-button-icon.medium-small duet-icon{width:10px;height:10px}.duet-button .duet-button-icon.medium-small.right{right:-16px;left:auto}.duet-button .duet-button-icon.small{left:-16px;width:7px;height:7px}.duet-button .duet-button-icon.small duet-icon{width:7px;height:7px}.duet-button .duet-button-icon.small.right{right:-16px;left:auto}.duet-button:focus{outline:0;box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}.duet-theme-turva .duet-button:focus{box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}.duet-button:active{opacity:0.75;transition:none}.duet-button.default{border-color:#e1e3e6}.duet-theme-turva .duet-button.default{color:#c60c30 !important;border-color:#e4e4e6}.duet-button.default:hover{border-color:#0077b3}.duet-theme-turva .duet-button.default:hover{border-color:#c60c30}.duet-button.default.duet-button-negative{background-color:white}.duet-theme-turva .duet-button.default.duet-button-negative{background-color:#e4e4e6 !important}.duet-button.default.duet-button-negative:hover{color:#0077b3 !important;border-color:#0077b3}.duet-theme-turva .duet-button.default.duet-button-negative:hover{color:#c60c30 !important;border-color:#c60c30}.duet-button.primary,.duet-button.input-button-primary{color:white !important;background:#0077b3;border-color:#0077b3}.duet-theme-turva .duet-button.primary,.duet-theme-turva .duet-button.input-button-primary{color:white !important;background:#c60c30;border-color:#c60c30}.duet-button.primary:hover,.duet-button.input-button-primary:hover{background:#005f8f;border-color:#005f8f;box-shadow:0 4px 20px rgba(34, 34, 34, 0.1)}.duet-theme-turva .duet-button.primary:hover,.duet-theme-turva .duet-button.input-button-primary:hover{background:#940925;border-color:#940925}.duet-button.primary:focus,.duet-button.input-button-primary:focus{outline:0;box-shadow:0 0 0 1px white, 0 0 0 4px rgba(0, 119, 179, 0.75)}.duet-theme-turva .duet-button.primary:focus,.duet-theme-turva .duet-button.input-button-primary:focus{box-shadow:0 0 0 1px white, 0 0 0 4px rgba(23, 28, 58, 0.7)}.duet-button.secondary,.duet-button.input-button-secondary{color:#00294d !important;background:transparent;border-color:#00294d}.duet-theme-turva .duet-button.secondary,.duet-theme-turva .duet-button.input-button-secondary{color:#171c3a !important;border-color:#171c3a}.duet-button.secondary:hover,.duet-button.input-button-secondary:hover{color:#0077b3 !important;border-color:#0077b3}.duet-theme-turva .duet-button.secondary:hover,.duet-theme-turva .duet-button.input-button-secondary:hover{color:#c60c30 !important;border-color:#c60c30}.duet-button.secondary.duet-button-negative,.duet-button.input-button-secondary.duet-button-negative{color:#e1e3e6 !important;border-color:white}.duet-theme-turva .duet-button.secondary.duet-button-negative,.duet-theme-turva .duet-button.input-button-secondary.duet-button-negative{color:#e4e4e6 !important}.duet-button.secondary.duet-button-negative:hover,.duet-button.input-button-secondary.duet-button-negative:hover{color:#0077b3 !important;border-color:#0077b3}.duet-theme-turva .duet-button.secondary.duet-button-negative:hover,.duet-theme-turva .duet-button.input-button-secondary.duet-button-negative:hover{color:#c60c30 !important;border-color:#c60c30}.duet-button.negative{color:#00294d !important;background:white;border-color:white}.duet-theme-turva .duet-button.negative{color:#171c3a !important}.duet-button.negative:hover{color:white !important;background:transparent;border-color:white}.duet-button.negative:focus{outline:0;box-shadow:0 0 0 1px #00294d, 0 0 0 4px rgba(255, 255, 255, 0.7)}.duet-theme-turva .duet-button.negative:focus{box-shadow:0 0 0 1px #171c3a, 0 0 0 4px rgba(255, 255, 255, 0.7)}.duet-button.destructive-primary{color:white !important;background:#de2362;border-color:#de2362}.duet-theme-turva .duet-button.destructive-primary{color:white !important;background:#e02a0d;border-color:#e02a0d}.duet-button.destructive-primary:hover{background:#b21c4e;border-color:#b21c4e;box-shadow:0 4px 20px rgba(34, 34, 34, 0.1)}.duet-theme-turva .duet-button.destructive-primary:hover{background:#b3220a}.duet-button.destructive,.duet-button.destructive-secondary{color:#de2362 !important;background:white;border-color:#de2362}.duet-theme-turva .duet-button.destructive,.duet-theme-turva .duet-button.destructive-secondary{color:#e02a0d !important;background:white;border-color:#e02a0d}.duet-button.destructive:hover,.duet-button.destructive-secondary:hover{color:white !important;background:#b21c4e;border-color:#b21c4e}.duet-theme-turva .duet-button.destructive:hover,.duet-theme-turva .duet-button.destructive-secondary:hover{color:white !important;background:#b3220a;border-color:#b3220a}.duet-button.plain{min-width:48px;padding-right:0 !important;padding-left:0 !important;line-height:1.5;text-align:left;background:transparent;border:0;border-color:transparent;border-radius:4px}.duet-theme-turva .duet-button.plain{color:#c60c30 !important;background:transparent;border-color:transparent}.duet-button.plain.icon{padding-left:20px !important}.duet-button.plain.icon.icon-right{padding-right:20px !important;padding-left:0 !important}.duet-button.plain.icon.medium{padding-left:24px !important}.duet-button.plain.icon.medium.icon-right{padding-right:24px !important;padding-left:0 !important}.duet-button.plain.icon.large{padding-left:30px !important}.duet-button.plain.icon.large.icon-right{padding-right:30px !important;padding-left:0 !important}.duet-button.plain .duet-button-icon.left{left:-16.6666666667px !important}.duet-button.plain .duet-button-icon.left.medium{left:-24px !important}.duet-button.plain .duet-button-icon.left.large{left:-30px !important}.duet-button.plain .duet-button-icon.right{right:-16.6666666667px !important}.duet-button.plain .duet-button-icon.right.medium{right:-24px !important}.duet-button.plain .duet-button-icon.right.large{right:-30px !important}.duet-button.plain[disabled]{color:#657787 !important;background:transparent !important;border-color:transparent !important}.duet-theme-turva .duet-button.plain[disabled]{color:transparent !important;background:transparent !important;border-color:#e4e4e6 !important}.duet-button.plain:hover{color:#004d80 !important;background:transparent !important}.duet-theme-turva .duet-button.plain:hover{color:#940925 !important}.duet-button.plain.duet-button-negative{color:white !important}.duet-theme-turva .duet-button.plain.duet-button-negative{color:#e4e4e6 !important}.duet-button.plain.duet-button-negative:hover{color:#0077b3 !important}.duet-theme-turva .duet-button.plain.duet-button-negative:hover{color:#c60c30 !important}.duet-button.duet-button-icon-only{min-width:48px;min-height:48px;padding:0 !important}.duet-button.duet-button-icon-only .duet-button-contents{position:static}.duet-button.duet-button-icon-only .duet-button-icon.left.large,.duet-button.duet-button-icon-only .duet-button-icon.left.medium,.duet-button.duet-button-icon-only .duet-button-icon.left.small{position:absolute;top:50% !important;left:50% !important;padding:0;margin:0;transform:translateX(-50%) translateY(-50%)}.duet-button.duet-button.input-button-primary,.duet-button.duet-button.input-button-secondary{box-sizing:content-box;min-width:48px;min-height:48px;padding:0 !important;border-width:1px;border-top-left-radius:0;border-top-right-radius:4px;border-bottom-right-radius:4px;border-bottom-left-radius:0}.duet-button.duet-button.input-button-primary .duet-button-contents,.duet-button.duet-button.input-button-secondary .duet-button-contents{position:static}.duet-button.duet-button.input-button-primary .duet-button-icon.left.large,.duet-button.duet-button.input-button-primary .duet-button-icon.left.medium,.duet-button.duet-button.input-button-primary .duet-button-icon.left.small,.duet-button.duet-button.input-button-secondary .duet-button-icon.left.large,.duet-button.duet-button.input-button-secondary .duet-button-icon.left.medium,.duet-button.duet-button.input-button-secondary .duet-button-icon.left.small{position:absolute;top:50% !important;left:50% !important;padding:0;margin:0;transform:translateX(-50%) translateY(-50%)}.duet-button[disabled],.duet-button[disabled]:hover,.duet-button.duet-button-negative[disabled],.duet-button.duet-button-negative[disabled]:hover{color:#657787 !important;background:#e1e3e6 !important;border-color:#e1e3e6 !important;box-shadow:none !important}.duet-theme-turva .duet-button[disabled],.duet-theme-turva .duet-button[disabled]:hover,.duet-theme-turva .duet-button.duet-button-negative [disabled],.duet-theme-turva .duet-button.duet-button-negative [disabled]:hover{color:#747475 !important;background:#e4e4e6 !important;border-color:#e4e4e6 !important}.duet-button-is-loading.primary,.duet-button-is-loading.input-button-primary{color:white}.duet-button-is-loading.default{color:#0077b3}.duet-button-is-loading.default.duet-theme-turva{color:#c60c30}.duet-button-is-loading .duet-button-contents{visibility:hidden;opacity:0}";
|
|
13
13
|
|
|
14
14
|
const DuetButton = class {
|
|
15
15
|
constructor(hostRef) {
|
|
@@ -234,6 +234,7 @@ const DuetButton = class {
|
|
|
234
234
|
"duet-small": this.size === "small",
|
|
235
235
|
"duet-fixed": this.fixed,
|
|
236
236
|
"duet-expand": this.expand,
|
|
237
|
+
"input-button": this.variation === "input-button-primary" || this.variation === "input-button-secondary",
|
|
237
238
|
} }, h("div", { class: {
|
|
238
239
|
"duet-button-container": true,
|
|
239
240
|
"duet-button-is-loading": this.loading,
|
|
@@ -1,14 +1,14 @@
|
|
|
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-715101b6.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-e8fc98bf.js';
|
|
6
6
|
import { s as sanitizeString } from './string-utils-5954f458.js';
|
|
7
|
-
import { g as getColorByName } from './token-utils-
|
|
7
|
+
import { g as getColorByName } from './token-utils-1f9435bc.js';
|
|
8
8
|
import { a as actionNewWindowSmall } from './action-new-window-small-1945be91.js';
|
|
9
9
|
import { D as DuetStringsExternalDefaults } from './common-strings-97e04e4b.js';
|
|
10
10
|
import { a as getLanguage, g as getLocaleString } from './language-utils-bf701d37.js';
|
|
11
|
-
import './tokens.module-
|
|
11
|
+
import './tokens.module-f4572ed7.js';
|
|
12
12
|
|
|
13
13
|
const duetCaptionCss = ":host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-bottom:16px !important;display:flex;flex:0 0 100%;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;font-weight:400;line-height:1.5;color:#657787;vertical-align:top}:host.duet-p-0{padding:0 !important}:host.duet-m-0{margin:0 !important}:host(.duet-caption-small){font-size:0.875rem;line-height:1.25}:host(.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\";color:#747475}:host(.duet-caption-selected){color:#0077b3}:host(.duet-caption-selected.duet-theme-turva){color:#171c3a}:host(.duet-m-0){margin:0 !important}";
|
|
14
14
|
|
|
@@ -1,13 +1,13 @@
|
|
|
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-715101b6.js';
|
|
5
5
|
import { c as createID } from './create-id-981107da.js';
|
|
6
6
|
import { i as isKeyboardClick } from './keyboard-utils-88ea1007.js';
|
|
7
7
|
import { s as sanitizeString } from './string-utils-5954f458.js';
|
|
8
8
|
import { i as inheritGlobalTheme } from './themeable-component-e8fc98bf.js';
|
|
9
|
-
import { g as getColorByName } from './token-utils-
|
|
10
|
-
import './tokens.module-
|
|
9
|
+
import { g as getColorByName } from './token-utils-1f9435bc.js';
|
|
10
|
+
import './tokens.module-f4572ed7.js';
|
|
11
11
|
|
|
12
12
|
var actionArrowUp={"title":"action-arrow-up","tags":"action arrow up caret","svg":"<svg fill=\"currentColor\" viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\" role=\"img\"><path d=\"M.75 17.939a.752.752 0 0 1-.53-1.281L10.94 5.94c.283-.284.659-.44 1.059-.44.401 0 .777.156 1.06.438l10.721 10.72a.752.752 0 0 1-.53 1.281.743.743 0 0 1-.53-.22L12 7 1.28 17.719a.743.743 0 0 1-.53.22z\"/></svg>"};
|
|
13
13
|
|
|
@@ -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-715101b6.js';
|
|
5
5
|
import { c as createID } from './create-id-981107da.js';
|
|
6
6
|
import { i as inheritGlobalTheme } from './themeable-component-e8fc98bf.js';
|
|
7
7
|
|
|
@@ -1,10 +1,10 @@
|
|
|
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-715101b6.js';
|
|
5
5
|
import { D as DuetStringsExternalDefaults } from './common-strings-97e04e4b.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-fe498b6c.js';
|
|
8
8
|
import { i as isKeyboardClick, h as isQuestionKey, f as isEscapeKey } from './keyboard-utils-88ea1007.js';
|
|
9
9
|
import { g as getLocaleString, a as getLanguage } from './language-utils-bf701d37.js';
|
|
10
10
|
import { i as inheritGlobalTheme } from './themeable-component-e8fc98bf.js';
|
|
@@ -1,9 +1,9 @@
|
|
|
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-715101b6.js';
|
|
5
5
|
import { a as actionArrowDownSmall } from './action-arrow-down-small-82273dc8.js';
|
|
6
|
-
import { f as font_size_medium, t as tokens } from './tokens-
|
|
6
|
+
import { f as font_size_medium, t as tokens } from './tokens-8ff8c570.js';
|
|
7
7
|
import { c as createID } from './create-id-981107da.js';
|
|
8
8
|
import { i as isKeyboardClick } from './keyboard-utils-88ea1007.js';
|
|
9
9
|
import { s as sanitizeString } from './string-utils-5954f458.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-715101b6.js';
|
|
5
5
|
import { d as debounce } from './js-utils-52e0944c.js';
|
|
6
6
|
import { n as isEnterKey, f as isEscapeKey, o as isTabKey, b as isArrowUpKey, c as isArrowDownKey } from './keyboard-utils-88ea1007.js';
|
|
7
7
|
import { g as getLocaleString, a as getLanguage } 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-715101b6.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-e8fc98bf.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,9 +1,9 @@
|
|
|
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-715101b6.js';
|
|
5
5
|
import { c as createID } from './create-id-981107da.js';
|
|
6
|
-
import { F as FocusGuard } from './focus-utils-
|
|
6
|
+
import { F as FocusGuard } from './focus-utils-fe498b6c.js';
|
|
7
7
|
import { a as getLanguage, g as getLocaleString } from './language-utils-bf701d37.js';
|
|
8
8
|
import { i as inheritGlobalTheme } from './themeable-component-e8fc98bf.js';
|
|
9
9
|
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, H as Host } from './index-
|
|
4
|
+
import { r as registerInstance, h, g as getElement, H as Host } from './index-715101b6.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-e8fc98bf.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,12 +1,12 @@
|
|
|
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-715101b6.js';
|
|
5
5
|
import { f as fieldSorter, d as debounce } from './js-utils-52e0944c.js';
|
|
6
6
|
import { i as isKeyboardClick } from './keyboard-utils-88ea1007.js';
|
|
7
7
|
import { g as getLocaleString, s as sanitizeString } from './language-utils-bf701d37.js';
|
|
8
8
|
import { i as inheritGlobalTheme } from './themeable-component-e8fc98bf.js';
|
|
9
|
-
import { m as mediaQueryMedium, h as mediaQueryLarge, i as mediaQueryXLarge, j as mediaQueryXxLarge, k as mediaQueryXxxLarge, l as mediaQuerySmall, n as sizeNavigation, s as sizeHeader } from './tokens.module-
|
|
9
|
+
import { m as mediaQueryMedium, h as mediaQueryLarge, i as mediaQueryXLarge, j as mediaQueryXxLarge, k as mediaQueryXxxLarge, l as mediaQuerySmall, n as sizeNavigation, s as sizeHeader } from './tokens.module-f4572ed7.js';
|
|
10
10
|
import { c as createID } from './create-id-981107da.js';
|
|
11
11
|
import './string-utils-5954f458.js';
|
|
12
12
|
|
|
@@ -306,7 +306,7 @@ const DuetTable = class {
|
|
|
306
306
|
// this clears all pending mutations,
|
|
307
307
|
// that way we avoid dealing with any initial changes
|
|
308
308
|
// and only get genuine mutations as rows are added/removed
|
|
309
|
-
this.observer.takeRecords();
|
|
309
|
+
this.observer ? this.observer.takeRecords() : null;
|
|
310
310
|
}
|
|
311
311
|
disconnectedCallback() {
|
|
312
312
|
this.observer.disconnect();
|
|
@@ -519,6 +519,10 @@ const ProgressItem = ({ progress, name }) => (h("span", null,
|
|
|
519
519
|
h("duet-spacer", { size: "xx-small" }),
|
|
520
520
|
h("duet-progress", { progress: Math.ceil(progress), "aria-hidden": true })));
|
|
521
521
|
|
|
522
|
+
const PendingItem = ({ name }) => (h("span", null,
|
|
523
|
+
h("duet-paragraph", { color: "secondary", margin: "none", size: "small" }, name),
|
|
524
|
+
h("duet-spacer", { size: "xx-small" })));
|
|
525
|
+
|
|
522
526
|
const formatBytes = (bytes, decimals = 2) => {
|
|
523
527
|
if (bytes === 0) {
|
|
524
528
|
return "0 Bytes";
|
|
@@ -696,9 +700,13 @@ const DuetUpload = class {
|
|
|
696
700
|
* it will be up to you to handle the upload and return progress information to the upload-component
|
|
697
701
|
*/
|
|
698
702
|
this.external = false;
|
|
703
|
+
/**
|
|
704
|
+
* If defer-upload is true, duet-upload will not (as recommended) instantly upload files but await a call to uploadPending()
|
|
705
|
+
*/
|
|
706
|
+
this.deferUpload = false;
|
|
699
707
|
/**
|
|
700
708
|
* If set the upload component will not display an upload button, you will have to create one yourself
|
|
701
|
-
* and call the exposed method startUpload
|
|
709
|
+
* and call the exposed method startUpload to open the upload dialog
|
|
702
710
|
*/
|
|
703
711
|
this.hideButton = false;
|
|
704
712
|
/**
|
|
@@ -711,7 +719,7 @@ const DuetUpload = class {
|
|
|
711
719
|
size: "x-small",
|
|
712
720
|
background: "gray-lightest",
|
|
713
721
|
name: "delete",
|
|
714
|
-
map: ["success", "failure"],
|
|
722
|
+
map: ["success", "failure", "pending"],
|
|
715
723
|
label: {
|
|
716
724
|
fi: "Poista tiedosto",
|
|
717
725
|
en: "Poista tiedosto",
|
|
@@ -965,6 +973,7 @@ const DuetUpload = class {
|
|
|
965
973
|
this.DefaultGroups = {
|
|
966
974
|
inprogress: "inprogress",
|
|
967
975
|
success: "success",
|
|
976
|
+
pending: "pending",
|
|
968
977
|
failure: "failure",
|
|
969
978
|
};
|
|
970
979
|
/**
|
|
@@ -981,6 +990,14 @@ const DuetUpload = class {
|
|
|
981
990
|
en: "Files inprogress",
|
|
982
991
|
},
|
|
983
992
|
},
|
|
993
|
+
{
|
|
994
|
+
id: this.DefaultGroups.pending,
|
|
995
|
+
label: {
|
|
996
|
+
en: "Files to upload",
|
|
997
|
+
sv: "Filer att ladda",
|
|
998
|
+
fi: "Tiedostot ladattavat",
|
|
999
|
+
},
|
|
1000
|
+
},
|
|
984
1001
|
{
|
|
985
1002
|
id: this.DefaultGroups.success,
|
|
986
1003
|
label: {
|
|
@@ -1008,7 +1025,6 @@ const DuetUpload = class {
|
|
|
1008
1025
|
this.element.addEventListener("duetActionEvent", (e) => {
|
|
1009
1026
|
const detail = e.detail;
|
|
1010
1027
|
const { action, id, originalEvent } = detail;
|
|
1011
|
-
console.log(e);
|
|
1012
1028
|
switch (action) {
|
|
1013
1029
|
case "delete":
|
|
1014
1030
|
this.onDelete(id, originalEvent);
|
|
@@ -1036,9 +1052,6 @@ const DuetUpload = class {
|
|
|
1036
1052
|
if (item.valid && item.progress === 100) {
|
|
1037
1053
|
// if the item has a group, move the file to that group instead
|
|
1038
1054
|
// of into the standard success group
|
|
1039
|
-
if (item.group) {
|
|
1040
|
-
return item.group;
|
|
1041
|
-
}
|
|
1042
1055
|
return this.DefaultGroups.success;
|
|
1043
1056
|
}
|
|
1044
1057
|
else if (item.progress > 0 && item.progress !== 100) {
|
|
@@ -1047,6 +1060,9 @@ const DuetUpload = class {
|
|
|
1047
1060
|
else if (!item.valid) {
|
|
1048
1061
|
return this.DefaultGroups.failure;
|
|
1049
1062
|
}
|
|
1063
|
+
else if (item.pending) {
|
|
1064
|
+
return this.DefaultGroups.pending;
|
|
1065
|
+
}
|
|
1050
1066
|
else if (item.group) {
|
|
1051
1067
|
return item.group;
|
|
1052
1068
|
}
|
|
@@ -1061,6 +1077,9 @@ const DuetUpload = class {
|
|
|
1061
1077
|
else if (group === this.DefaultGroups.inprogress) {
|
|
1062
1078
|
return h(ProgressItem, { progress: data.progress, name: data.item.name });
|
|
1063
1079
|
}
|
|
1080
|
+
else if (group === this.DefaultGroups.pending) {
|
|
1081
|
+
return h(PendingItem, { name: data.item.name });
|
|
1082
|
+
}
|
|
1064
1083
|
else if (group === this.DefaultGroups.failure) {
|
|
1065
1084
|
return h(ErrorItem, { data: data });
|
|
1066
1085
|
}
|
|
@@ -1073,9 +1092,16 @@ const DuetUpload = class {
|
|
|
1073
1092
|
};
|
|
1074
1093
|
this.genHashName = () => Date.now().toString(36) + Math.random();
|
|
1075
1094
|
this.updateValueInMap = (item, key, value, kick = true) => {
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1095
|
+
try {
|
|
1096
|
+
const fileItem = this.files.get(item);
|
|
1097
|
+
fileItem[key] = value;
|
|
1098
|
+
this.files.set(item, fileItem);
|
|
1099
|
+
}
|
|
1100
|
+
catch (e) {
|
|
1101
|
+
// if a users tries to update entries on a file that doesn't exist,
|
|
1102
|
+
// this will blow up - so we're swallowing the errors here on purpose
|
|
1103
|
+
// console.warn("operation on missing items")
|
|
1104
|
+
}
|
|
1079
1105
|
if (kick) {
|
|
1080
1106
|
this.kick();
|
|
1081
1107
|
}
|
|
@@ -1193,6 +1219,46 @@ const DuetUpload = class {
|
|
|
1193
1219
|
fileMaxReached: isTotalFileAmountAboveMax,
|
|
1194
1220
|
};
|
|
1195
1221
|
};
|
|
1222
|
+
this.uploadFile = async (fileListItem, force = false, key) => {
|
|
1223
|
+
if (!force && this.deferUpload) {
|
|
1224
|
+
this.updateValueInMap(fileListItem.item.name, "pending", true, false);
|
|
1225
|
+
this.updateValueInMap(fileListItem.item.name, "group", "pending", true);
|
|
1226
|
+
}
|
|
1227
|
+
else if (force) {
|
|
1228
|
+
this.updateValueInMap(fileListItem.item.name, "pending", false, false);
|
|
1229
|
+
this.updateValueInMap(fileListItem.item.name, "group", undefined, true);
|
|
1230
|
+
}
|
|
1231
|
+
try {
|
|
1232
|
+
if (!this.deferUpload || force) {
|
|
1233
|
+
// if all is well AND external file upload handling has not been set, start upload
|
|
1234
|
+
const data = new FormData();
|
|
1235
|
+
data.append("file", fileListItem.item);
|
|
1236
|
+
if (key) {
|
|
1237
|
+
data.append("key", key);
|
|
1238
|
+
}
|
|
1239
|
+
data.append("uid", fileListItem.uid);
|
|
1240
|
+
data.append("name", fileListItem.item.name);
|
|
1241
|
+
data.append("metadata", JSON.stringify({
|
|
1242
|
+
uid: fileListItem.uid,
|
|
1243
|
+
url: this.uri,
|
|
1244
|
+
size: fileListItem.item.size,
|
|
1245
|
+
meta: fileListItem.meta,
|
|
1246
|
+
}));
|
|
1247
|
+
fileListItem.xhr = await this.makeXHRPostRequest(data);
|
|
1248
|
+
}
|
|
1249
|
+
}
|
|
1250
|
+
catch (e) {
|
|
1251
|
+
// in case one of the global maxes have been reached, invalidate the file
|
|
1252
|
+
this.updateValueInMap(fileListItem.item.name, "valid", false, false);
|
|
1253
|
+
}
|
|
1254
|
+
};
|
|
1255
|
+
this.uploadPendingFiles = () => {
|
|
1256
|
+
for (const [key, value] of this.files.entries()) {
|
|
1257
|
+
if (value.group === "pending" && value.pending === true) {
|
|
1258
|
+
this.uploadFile(value, true, key);
|
|
1259
|
+
}
|
|
1260
|
+
}
|
|
1261
|
+
};
|
|
1196
1262
|
this.getItemFromUID = (uid) => {
|
|
1197
1263
|
for (const [key, value] of this.files.entries()) {
|
|
1198
1264
|
if (value.uid === uid) {
|
|
@@ -1202,7 +1268,8 @@ const DuetUpload = class {
|
|
|
1202
1268
|
return null;
|
|
1203
1269
|
};
|
|
1204
1270
|
this.onDelete = (key, ev) => {
|
|
1205
|
-
const
|
|
1271
|
+
const item = this.getItemFromUID(key);
|
|
1272
|
+
const retrievedKey = item.key;
|
|
1206
1273
|
const deletedItem = this.files.get(retrievedKey);
|
|
1207
1274
|
this.files.delete(retrievedKey);
|
|
1208
1275
|
this.validateTotals();
|
|
@@ -1212,7 +1279,8 @@ const DuetUpload = class {
|
|
|
1212
1279
|
data: { deletion: deletedItem },
|
|
1213
1280
|
component: "duet-upload",
|
|
1214
1281
|
});
|
|
1215
|
-
if
|
|
1282
|
+
// don't send a xhr request if the item was pending, just remove it from the list
|
|
1283
|
+
if (!this.external && !deletedItem.pending) {
|
|
1216
1284
|
this.makeXHRDeleteRequest(deletedItem);
|
|
1217
1285
|
}
|
|
1218
1286
|
this.resetFormFields();
|
|
@@ -1277,6 +1345,7 @@ const DuetUpload = class {
|
|
|
1277
1345
|
const all = [...this.files.values()];
|
|
1278
1346
|
const inprogress = [];
|
|
1279
1347
|
const failure = [];
|
|
1348
|
+
const pending = [];
|
|
1280
1349
|
const success = [];
|
|
1281
1350
|
all.forEach(data => {
|
|
1282
1351
|
const group = this.getGroupFromItemData(data);
|
|
@@ -1295,6 +1364,13 @@ const DuetUpload = class {
|
|
|
1295
1364
|
group,
|
|
1296
1365
|
});
|
|
1297
1366
|
}
|
|
1367
|
+
else if (group === this.DefaultGroups.pending) {
|
|
1368
|
+
pending.push({
|
|
1369
|
+
uid: data.uid,
|
|
1370
|
+
item,
|
|
1371
|
+
group,
|
|
1372
|
+
});
|
|
1373
|
+
}
|
|
1298
1374
|
else if (group === this.DefaultGroups.failure) {
|
|
1299
1375
|
failure.push({
|
|
1300
1376
|
uid: data.uid,
|
|
@@ -1312,6 +1388,7 @@ const DuetUpload = class {
|
|
|
1312
1388
|
});
|
|
1313
1389
|
return {
|
|
1314
1390
|
inprogress,
|
|
1391
|
+
pending,
|
|
1315
1392
|
failure,
|
|
1316
1393
|
success,
|
|
1317
1394
|
};
|
|
@@ -1385,6 +1462,12 @@ const DuetUpload = class {
|
|
|
1385
1462
|
this.nativeInput.click();
|
|
1386
1463
|
return;
|
|
1387
1464
|
}
|
|
1465
|
+
/**
|
|
1466
|
+
* Method for uploading pending files
|
|
1467
|
+
*/
|
|
1468
|
+
async uploadPending() {
|
|
1469
|
+
this.uploadPendingFiles();
|
|
1470
|
+
}
|
|
1388
1471
|
/**
|
|
1389
1472
|
* Method for forcing a render of the upload list, element.files can be changed externally
|
|
1390
1473
|
* But it will only rerender on a new Map or a top Level change - this can be used to update
|
|
@@ -1523,19 +1606,14 @@ const DuetUpload = class {
|
|
|
1523
1606
|
this.updateValueInMap(item.name, "valid", false, false);
|
|
1524
1607
|
}
|
|
1525
1608
|
else if (valid && !this.external) {
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
}
|
|
1535
|
-
catch (e) {
|
|
1536
|
-
// in case one of the global maxes have been reached, invalidate the file
|
|
1537
|
-
this.updateValueInMap(item.name, "valid", false, false);
|
|
1538
|
-
}
|
|
1609
|
+
await this.uploadFile(fileListItem);
|
|
1610
|
+
}
|
|
1611
|
+
else if (valid && this.external) {
|
|
1612
|
+
this.updateValueInMap(fileListItem.item.name, "pending", true, false);
|
|
1613
|
+
this.updateValueInMap(fileListItem.item.name, "group", "pending", true);
|
|
1614
|
+
}
|
|
1615
|
+
else if (!valid) {
|
|
1616
|
+
this.updateValueInMap(item.name, "valid", false, true);
|
|
1539
1617
|
}
|
|
1540
1618
|
// kick the stat to force update
|
|
1541
1619
|
this.kick();
|
|
@@ -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-715101b6.js';
|
|
5
5
|
import { i as inheritGlobalTheme } from './themeable-component-e8fc98bf.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-715101b6.js';
|
|
5
5
|
import { c as createID } from './create-id-981107da.js';
|
|
6
6
|
import { i as inheritGlobalTheme } from './themeable-component-e8fc98bf.js';
|
|
7
7
|
|
|
@@ -1,7 +1,9 @@
|
|
|
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-715101b6.js';
|
|
5
|
+
import { a as actionArrowDownSmall } from './action-arrow-down-small-82273dc8.js';
|
|
6
|
+
import { a as actionArrowRightSmall } from './action-arrow-right-small-f9d2ba83.js';
|
|
5
7
|
import { a as actionNewWindowSmall } from './action-new-window-small-1945be91.js';
|
|
6
8
|
import { D as DuetStringsExternalDefaults } from './common-strings-97e04e4b.js';
|
|
7
9
|
import { a as getLanguage, g as getLocaleString } from './language-utils-bf701d37.js';
|
|
@@ -12,13 +14,18 @@ var actionArrowRight={"title":"action-arrow-right","tags":"action arrow right ca
|
|
|
12
14
|
|
|
13
15
|
var actionNewWindow={"title":"action-new-window","tags":"arrow open new window tab external link square box rectangle action","svg":"<svg fill=\"currentColor\" viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\" role=\"img\"><path d=\"M10.25 2a.75.75 0 1 1 0 1.5h-6.5A2.252 2.252 0 0 0 1.5 5.75v14.5a2.252 2.252 0 0 0 2.25 2.25h14.5a2.252 2.252 0 0 0 2.25-2.25v-6.5a.75.75 0 0 1 1.5 0v6.5A3.754 3.754 0 0 1 18.25 24H3.75A3.754 3.754 0 0 1 0 20.25V5.75A3.754 3.754 0 0 1 3.75 2zm12.985-2c.1 0 .198.02.29.058l.025.011a.726.726 0 0 1 .15.091l.066.059a.755.755 0 0 1 .109.138l.051.1c.04.092.06.192.06.293l-.001 6.363c0 .2-.078.389-.22.53a.743.743 0 0 1-.53.22.743.743 0 0 1-.53-.22.743.743 0 0 1-.22-.53V2.559L15.28 9.764a.75.75 0 0 1-1.06-1.06l7.204-7.205h-4.553a.744.744 0 0 1-.75-.75c0-.2.078-.388.22-.53A.743.743 0 0 1 16.87 0z\"/></svg>"};
|
|
14
16
|
|
|
15
|
-
const duetFooterCss = "*,*::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-shrink:0;width:100%}.duet-footer{display:block;width:100%;padding-top:20px;padding-bottom:16px;margin-top:48px;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;font-weight:400;line-height:1.5;color:white;text-align:left;background:#00294d}.duet-footer.duet-p-0{padding:0 !important}.duet-footer.duet-m-0{margin:0 !important}@media (min-width: 36em){.duet-footer{padding-top:36px}}@media (min-width: 62em){.duet-footer{padding-top:48px;padding-bottom:36px}}.duet-footer.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:#c60c30}.duet-footer a{color:white;text-decoration:none}@media (min-width: 62em){.duet-footer a{border-radius:4px}}.duet-footer a:focus{outline:0}:host(.user-is-tabbing) .duet-footer a:focus{box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}:host(.user-is-tabbing) .duet-theme-turva a:focus{box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}.duet-footer-wrapper{position:relative;margin:0 auto}@media (min-width: 62em){.duet-footer-wrapper{padding:0 72px 0 48px}}@media (min-width: 76.25em){.duet-footer-wrapper{max-width:1110px;padding:0 20px 0 0}}.duet-footer-top{width:100%}@media (min-width: 62em){.duet-footer-top{display:flex;flex-direction:row;align-items:center;justify-content:space-between}}duet-logo{margin-left:16px !important}@media (min-width: 36em){duet-logo{margin-left:28px !important}}@media (min-width: 62em){duet-logo{margin-left:0 !important}}.duet-footer-link{padding:16px !important;display:flex;flex-direction:row;align-items:center;width:100%;font-weight:600;border-bottom:1px solid rgba(255, 255, 255, 0.2);transition:background-color 300ms ease}@media (min-width: 36em){.duet-footer-link{padding-right:20px !important;padding-left:28px !important}}@media (min-width: 62em){.duet-footer-link{width:auto;min-width:0;padding-right:0 !important;padding-left:0 !important;border:0}}.duet-footer-link:first-of-type{margin-top:20px;border-top:1px solid rgba(255, 255, 255, 0.2)}@media (min-width: 62em){.duet-footer-link:first-of-type{margin:0;border:0}}.duet-footer-link span{display:inline-block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.duet-footer-link:hover{background:rgba(0, 0, 0, 0.1)}@media (min-width: 62em){.duet-footer-link:hover{background:transparent}}.duet-footer-icon{display:flex;align-items:center;justify-content:center;padding:12px;margin-right:16px;background:#0077b3;border-radius:50%;transition:300ms ease}.duet-theme-turva .duet-footer-icon{background:transparent;box-shadow:0 0 0 1px white}a:hover .duet-footer-icon{background:#006ba1}.duet-theme-turva a:hover .duet-footer-icon{background:transparent}.duet-footer-arrow{display:flex;align-items:center;justify-content:center;width:20px;min-width:20px;max-width:20px;height:20px;max-height:20px;margin-left:auto;color:white;transition:transform 300ms ease}@media (min-width: 62em){.duet-footer-arrow{width:10px;min-width:10px;margin-top:3px;margin-left:8px}}@media (min-width: 62em){.duet-footer-arrow{margin-right:0}}a:hover .duet-footer-arrow{transform:translateX(4px)}.duet-footer-arrow duet-icon{width:20px;height:20px}@media (min-width: 62em){.duet-footer-arrow duet-icon{width:10px;height:10px}}.duet-footer-menu{padding:20px !important;font-size:0.875rem}@media (min-width: 36em){.duet-footer-menu{padding:28px !important}}@media (min-width: 62em){.duet-footer-menu{padding-left:8px !important}}.duet-footer-menu a{display:inline-block;text-decoration:none;word-break:break-all}.duet-footer-menu a:hover,.duet-footer-menu a:focus{text-decoration:underline}.duet-footer-menu a:hover .duet-footer-divider,.duet-footer-menu a:focus .duet-footer-divider{text-decoration:none}.duet-footer-menu .duet-footer-divider{display:inline-block;margin:0 8px}.duet-footer-menu a:last-of-type .duet-footer-divider{display:none}.duet-footer-copyright{color:white}.duet-footer-simple{padding:0;margin:0;margin-top:16px;color:#00294d;background:transparent !important;border-top:1px solid #e1e3e6}.duet-footer-simple .duet-footer-wrapper{max-width:100%;padding:0 20px;margin:0}@media (min-width: 62em){.duet-footer-simple .duet-footer-wrapper{padding:0 36px}}@media (min-width: 106.25em){.duet-footer-simple .duet-footer-wrapper{padding:0 48px}}.duet-footer-simple .duet-footer-copyright,.duet-footer-simple .duet-footer-menu a{color:#00294d}.duet-footer-simple .duet-footer-menu{padding:20px 0 !important}.duet-footer-simple.duet-theme-turva{color:#171c3a;border-color:#e4e4e6}.duet-footer-simple.duet-theme-turva .duet-footer-copyright,.duet-footer-simple.duet-theme-turva .duet-footer-menu a{color:#171c3a}.duet-footer-external{display:inline-block;margin-left:4px;color:#0077b3}.duet-theme-turva .duet-footer-external{color:white}.duet-footer-simple.duet-theme-turva .duet-footer-external{color:#c60c30}";
|
|
17
|
+
const duetFooterCss = "*,*::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-shrink:0;width:100%}.duet-footer{display:block;width:100%;padding-top:20px;padding-bottom:16px;margin-top:48px;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;font-weight:400;line-height:1.5;color:white;text-align:left;background:#00294d}.duet-footer.duet-p-0{padding:0 !important}.duet-footer.duet-m-0{margin:0 !important}@media (min-width: 36em){.duet-footer{padding-top:36px}}@media (min-width: 62em){.duet-footer{padding-top:48px;padding-bottom:36px}}.duet-footer.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:#c60c30}.duet-footer a{color:white;text-decoration:none}@media (min-width: 62em){.duet-footer a{border-radius:4px}}.duet-footer a:focus{outline:0}:host(.user-is-tabbing) .duet-footer a:focus{box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}:host(.user-is-tabbing) .duet-theme-turva a:focus{box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}.duet-footer-wrapper{position:relative;margin:0 auto}@media (min-width: 62em){.duet-footer-wrapper{padding:0 72px 0 48px}}@media (min-width: 76.25em){.duet-footer-wrapper{max-width:1110px;padding:0 20px 0 0}}.duet-footer-top{width:100%}@media (min-width: 62em){.duet-footer-top{display:flex;flex-direction:row;align-items:center;justify-content:space-between}}duet-logo{margin-left:16px !important}@media (min-width: 36em){duet-logo{margin-left:28px !important}}@media (min-width: 62em){duet-logo{margin-left:0 !important}}.duet-footer-link{padding:16px !important;display:flex;flex-direction:row;align-items:center;width:100%;font-weight:600;border-bottom:1px solid rgba(255, 255, 255, 0.2);transition:background-color 300ms ease}@media (min-width: 36em){.duet-footer-link{padding-right:20px !important;padding-left:28px !important}}@media (min-width: 62em){.duet-footer-link{width:auto;min-width:0;padding-right:0 !important;padding-left:0 !important;border:0}}.duet-footer-link:first-of-type{margin-top:20px;border-top:1px solid rgba(255, 255, 255, 0.2)}@media (min-width: 62em){.duet-footer-link:first-of-type{margin:0;border:0}}.duet-footer-link span{display:inline-block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.duet-footer-link:hover{background:rgba(0, 0, 0, 0.1)}@media (min-width: 62em){.duet-footer-link:hover{background:transparent}}.duet-footer-icon{display:flex;align-items:center;justify-content:center;padding:12px;margin-right:16px;background:#0077b3;border-radius:50%;transition:300ms ease}.duet-theme-turva .duet-footer-icon{background:transparent;box-shadow:0 0 0 1px white}a:hover .duet-footer-icon{background:#006ba1}.duet-theme-turva a:hover .duet-footer-icon{background:transparent}.duet-footer-arrow{display:flex;align-items:center;justify-content:center;width:20px;min-width:20px;max-width:20px;height:20px;max-height:20px;margin-left:auto;color:white;transition:transform 300ms ease}@media (min-width: 62em){.duet-footer-arrow{width:10px;min-width:10px;margin-top:3px;margin-left:8px}}@media (min-width: 62em){.duet-footer-arrow{margin-right:0}}a:hover .duet-footer-arrow{transform:translateX(4px)}.duet-footer-arrow duet-icon{width:20px;height:20px}@media (min-width: 62em){.duet-footer-arrow duet-icon{width:10px;height:10px}}.duet-footer-menu{padding:20px !important;font-size:0.875rem}@media (min-width: 36em){.duet-footer-menu{padding:28px !important}}@media (min-width: 62em){.duet-footer-menu{padding-left:8px !important}}.duet-footer-menu a{display:inline-block;text-decoration:none;word-break:break-all}.duet-footer-menu a:hover,.duet-footer-menu a:focus{text-decoration:underline}.duet-footer-menu a:hover .duet-footer-divider,.duet-footer-menu a:focus .duet-footer-divider{text-decoration:none}.duet-footer-menu .duet-footer-divider{display:inline-block;margin:0 8px}.duet-footer-menu a:last-of-type .duet-footer-divider{display:none}.duet-footer-copyright{color:white}.duet-footer-simple{padding:0;margin:0;margin-top:16px;color:#00294d;background:transparent !important;border-top:1px solid #e1e3e6}.duet-footer-simple .duet-footer-wrapper{max-width:100%;padding:0 20px;margin:0}@media (min-width: 62em){.duet-footer-simple .duet-footer-wrapper{padding:0 36px}}@media (min-width: 106.25em){.duet-footer-simple .duet-footer-wrapper{padding:0 48px}}.duet-footer-simple .duet-footer-copyright,.duet-footer-simple .duet-footer-menu a{color:#00294d}.duet-footer-simple .duet-footer-menu{padding:20px 0 !important}.duet-footer-simple.duet-theme-turva{color:#171c3a;border-color:#e4e4e6}.duet-footer-simple.duet-theme-turva .duet-footer-copyright,.duet-footer-simple.duet-theme-turva .duet-footer-menu a{color:#171c3a}.duet-footer-multilevel duet-logo{margin-left:0.5rem !important}@media (min-width: 62em){.duet-footer-multilevel duet-logo{margin-left:-0.5rem !important}}.duet-footer-multilevel .duet-footer-link{padding:0.5rem 1.25rem !important;border:0}.duet-footer-multilevel .duet-footer-link:first-of-type{margin:0}.duet-footer-multilevel .duet-footer-link .duet-footer-arrow{margin-left:0.5rem}.duet-footer-multilevel .duet-footer-link .duet-footer-arrow duet-icon{width:0.75rem;height:0.75rem}@media (min-width: 62em){.duet-footer-multilevel .duet-footer-link{padding:0.75rem 0 !important}}.duet-footer-multilevel .duet-footer-top{flex-direction:column;gap:1rem 0;align-items:flex-start}@media (min-width: 62em){.duet-footer-multilevel .multilevel{display:flex;justify-content:space-between;width:100%}}.duet-footer-multilevel .multilevel-main-item{margin-top:1.25rem}@media (min-width: 62em){.duet-footer-multilevel .multilevel-main-item{margin-top:0}}.duet-footer-multilevel .multilevel-main-item .duet-footer-link{padding:0 0.5 1.25rem !important;font-weight:700}@media (min-width: 62em){.duet-footer-multilevel .multilevel-main-item .duet-footer-link{padding:0 0 0.5rem !important}}@media (min-width: 62em){.duet-footer-multilevel .multilevel-primary-items{column-gap:0;width:100%;columns:3}.duet-footer-multilevel .multilevel-primary-items .duet-footer-link{display:inline-flex}}.duet-footer-multilevel .multilevel-secondary-items .duet-footer-link{padding:0.875rem 1.25rem !important;font-weight:700}.duet-footer-multilevel .multilevel-secondary-items .duet-footer-link:first-child{padding:1.25rem 1.25rem 0.875rem !important}@media (min-width: 62em){.duet-footer-multilevel .multilevel-secondary-items{display:grid;grid-template-columns:repeat(3, 1fr);width:100%}.duet-footer-multilevel .multilevel-secondary-items .duet-footer-link,.duet-footer-multilevel .multilevel-secondary-items .duet-footer-link:first-child{display:inline-flex;padding:1rem 0 !important}}.duet-footer-multilevel .multilevel-right .duet-footer-link:first-child{padding-top:0.875rem !important;font-weight:700}@media (min-width: 62em){.duet-footer-multilevel .multilevel-right .duet-footer-link{padding:0.375rem 0 !important;font-size:0.875rem;font-weight:400}.duet-footer-multilevel .multilevel-right .duet-footer-link:first-child{padding-top:0 !important;font-size:1rem;font-weight:600}.duet-footer-multilevel .multilevel-right .tertiary-main-item .duet-footer-arrow{display:none}}.duet-footer-multilevel .duet-footer-menu{padding:1.25rem !important;line-height:2.5}@media (min-width: 62em){.duet-footer-multilevel .duet-footer-menu{padding-right:0 !important;padding-left:0 !important;text-align:right}}.duet-footer-multilevel .duet-footer-copyright{display:none;font-size:0.875rem}@media (min-width: 62em){.duet-footer-multilevel .duet-footer-copyright{position:absolute;left:48px;display:inline}}@media (min-width: 76.25em){.duet-footer-multilevel .duet-footer-copyright{left:0}}.duet-footer-multilevel .duet-footer-copyright.duet-footer-copyright-mobile{display:block;padding-top:0.5rem;padding-bottom:1.25rem;text-align:center}@media (min-width: 62em){.duet-footer-multilevel .duet-footer-copyright.duet-footer-copyright-mobile{display:none}}.duet-footer-multilevel.duet-theme-turva .duet-footer-copyright-mobile{padding-left:1.25rem;text-align:left}.duet-footer-multilevel.duet-theme-turva .duet-footer-icon{color:#171c3a;background:white}.duet-footer-multilevel.duet-theme-turva a:hover .duet-footer-icon{background:#e6e6e6}.duet-footer-external{display:inline-block;margin-left:4px;color:#0077b3}.duet-theme-turva .duet-footer-external{color:white}.duet-footer-simple.duet-theme-turva .duet-footer-external{color:#c60c30}";
|
|
16
18
|
|
|
17
19
|
const i18n = {
|
|
18
20
|
fi: { lahi: "© LähiTapiola", turva: "© Turva" },
|
|
19
21
|
sv: { lahi: "© LokalTapiola", turva: "© Turva" },
|
|
20
22
|
en: { lahi: "© LocalTapiola", turva: "© Turva" },
|
|
21
23
|
};
|
|
24
|
+
const i18nMultilevel = {
|
|
25
|
+
fi: { lahi: "© LähiTapiola", turva: "© Keskinäinen Vakuutusyhtiö Turva" },
|
|
26
|
+
sv: { lahi: "© LokalTapiola", turva: "© Keskinäinen Vakuutusyhtiö Turva" },
|
|
27
|
+
en: { lahi: "© LocalTapiola", turva: "© Keskinäinen Vakuutusyhtiö Turva" },
|
|
28
|
+
};
|
|
22
29
|
const createEvent = (ev, data) => ({
|
|
23
30
|
component: "duet-footer",
|
|
24
31
|
data,
|
|
@@ -36,7 +43,11 @@ const DuetFooter = class {
|
|
|
36
43
|
* State() variables
|
|
37
44
|
* Inlined decorator, alphabetical order.
|
|
38
45
|
*/
|
|
46
|
+
this.processedMainItem = null;
|
|
39
47
|
this.processedItems = null;
|
|
48
|
+
this.processedSecondaryItems = null;
|
|
49
|
+
this.processedTertiaryMainItem = null;
|
|
50
|
+
this.processedTertiaryItems = null;
|
|
40
51
|
this.processedMenu = null;
|
|
41
52
|
/**
|
|
42
53
|
* Theme of the navigation.
|
|
@@ -111,7 +122,11 @@ const DuetFooter = class {
|
|
|
111
122
|
* Local methods
|
|
112
123
|
*/
|
|
113
124
|
async refresh() {
|
|
125
|
+
this.processedMainItem = parsePossibleJSON(this.mainItem);
|
|
114
126
|
this.processedItems = parsePossibleJSON(this.items);
|
|
127
|
+
this.processedSecondaryItems = parsePossibleJSON(this.secondaryItems);
|
|
128
|
+
this.processedTertiaryMainItem = parsePossibleJSON(this.tertiaryMainItem);
|
|
129
|
+
this.processedTertiaryItems = parsePossibleJSON(this.tertiaryItems);
|
|
115
130
|
this.processedMenu = parsePossibleJSON(this.menu);
|
|
116
131
|
}
|
|
117
132
|
/**
|
|
@@ -119,16 +134,20 @@ const DuetFooter = class {
|
|
|
119
134
|
* Always the last one in the class.
|
|
120
135
|
*/
|
|
121
136
|
render() {
|
|
122
|
-
const text = getLocaleString(i18n);
|
|
137
|
+
const text = this.variation === "multilevel" ? getLocaleString(i18nMultilevel) : getLocaleString(i18n);
|
|
123
138
|
const copyrightLabel = this.theme === "turva" ? text.turva : text.lahi;
|
|
124
139
|
return (h("footer", { class: {
|
|
125
140
|
"duet-footer": true,
|
|
126
141
|
"duet-m-0": this.margin === "none",
|
|
127
142
|
"duet-theme-turva": this.theme === "turva",
|
|
128
143
|
"duet-footer-simple": this.variation === "simple",
|
|
144
|
+
"duet-footer-multilevel": this.variation === "multilevel",
|
|
129
145
|
} }, h("div", { class: "duet-footer-wrapper" }, h("div", { class: "duet-footer-top", part: "top" }, this.variation !== "simple" && (h("duet-logo", { href: this.logoHref, onClick: this.handleLogoClick, size: "large", inverse: true, language: this.language, theme: this.theme })), this.processedItems &&
|
|
130
146
|
this.variation !== "simple" &&
|
|
131
|
-
this.
|
|
147
|
+
this.variation !== "multilevel" &&
|
|
148
|
+
this.processedItems.map(item => (h("a", { class: "duet-footer-link", href: item.href, id: item.id, target: item.external ? "_blank" : "_self", onClick: event => this.handleItemClick(event, item) }, h("div", { class: "duet-footer-icon" }, h("duet-icon", { size: "medium", margin: "none", name: item.icon, color: "currentColor" })), h("span", null, item.label), item.external && h("duet-visually-hidden", null, ", ", this.accessibleLabelExternal), h("div", { class: "duet-footer-arrow" }, item.external ? (h("duet-icon", { icon: actionNewWindow.svg, size: "xx-small", margin: "none", color: "currentColor" })) : (h("duet-icon", { icon: actionArrowRight.svg, size: "auto", margin: "none", color: "currentColor" })))))), this.processedItems && this.variation === "multilevel" && (h("div", { class: "multilevel" }, h("div", { class: "multilevel-left" }, h("div", { class: "multilevel-main-item" }, this.processedMainItem && (h("a", { class: "duet-footer-link", href: this.processedMainItem.href, id: this.processedMainItem.id, target: this.processedMainItem.external ? "_blank" : "_self", onClick: event => this.handleItemClick(event, this.processedMainItem) }, h("span", null, this.processedMainItem.label), this.processedMainItem.external && (h("duet-visually-hidden", null, ", ", this.accessibleLabelExternal)), h("div", { class: "duet-footer-arrow" }, this.processedMainItem.external && (h("duet-icon", { icon: actionNewWindow.svg, size: "xx-small", margin: "none", color: "currentColor" })))))), h("div", { class: "multilevel-primary-items" }, this.processedItems.map(item => (h("a", { class: "duet-footer-link", href: item.href, id: item.id, target: item.external ? "_blank" : "_self", onClick: event => this.handleItemClick(event, item) }, h("div", { class: "duet-footer-icon" }, h("duet-icon", { size: "small", margin: "none", name: item.icon, color: "currentColor" })), h("span", null, item.label), item.external && h("duet-visually-hidden", null, ", ", this.accessibleLabelExternal), h("div", { class: "duet-footer-arrow" }, item.external && (h("duet-icon", { icon: actionNewWindow.svg, size: "xx-small", margin: "none", color: "currentColor" }))))))), h("div", { class: "multilevel-secondary-items" }, this.processedSecondaryItems &&
|
|
149
|
+
this.processedSecondaryItems.map(item => (h("a", { class: "duet-footer-link", href: item.href, id: item.id, target: item.external ? "_blank" : "_self", onClick: event => this.handleItemClick(event, item) }, h("span", null, item.label), item.external && (h("duet-visually-hidden", null, ", ", this.accessibleLabelExternal)), h("div", { class: "duet-footer-arrow" }, item.external ? (h("duet-icon", { icon: actionNewWindow.svg, size: "xx-small", margin: "none", color: "currentColor" })) : (h("duet-icon", { icon: actionArrowRightSmall.svg, size: "auto", margin: "none", color: "currentColor" })))))))), h("div", { class: "multilevel-right" }, this.processedTertiaryMainItem && (h("span", { class: "duet-footer-link tertiary-main-item", id: this.processedTertiaryMainItem.id }, h("span", null, this.processedTertiaryMainItem.label), this.processedTertiaryMainItem.external && (h("duet-visually-hidden", null, ", ", this.accessibleLabelExternal)), h("div", { class: "duet-footer-arrow" }, h("duet-icon", { icon: actionArrowDownSmall.svg, size: "xx-small", margin: "none", color: "currentColor" })))), this.processedTertiaryItems &&
|
|
150
|
+
this.processedTertiaryItems.map(item => (h("a", { class: "duet-footer-link", href: item.href, id: item.id, target: item.external ? "_blank" : "_self", onClick: event => this.handleItemClick(event, item) }, h("span", null, item.label), item.external && h("duet-visually-hidden", null, ", ", this.accessibleLabelExternal), h("div", { class: "duet-footer-arrow" }, item.external && (h("duet-icon", { icon: actionNewWindow.svg, size: "xx-small", margin: "none", color: "currentColor" })))))))))), h("slot", { name: "extra" }), h("p", { class: "duet-footer-menu", part: "menu" }, h("span", { class: "duet-footer-copyright" }, `${copyrightLabel} ${new Date().getFullYear()}`), this.processedMenu && (h(Fragment, null, this.variation !== "multilevel" && (h("span", { class: "duet-footer-divider", role: "presentation", "aria-hidden": "true" }, "/")), this.processedMenu.map(item => (h("a", { href: item.href, id: item.id, target: item.external ? "_blank" : "_self", onClick: event => this.handleMenuClick(event, item) }, item.label, item.external && (h(Fragment, null, h("duet-visually-hidden", null, ", ", this.accessibleLabelExternal), h("div", { class: "duet-footer-external" }, h("duet-icon", { icon: actionNewWindowSmall.svg, size: "xx-small", margin: "none", color: "currentColor" })))), h("span", { class: "duet-footer-divider", role: "presentation", "aria-hidden": "true" }, "/"))))))), this.variation === "multilevel" && (h("p", { class: "duet-footer-copyright duet-footer-copyright-mobile" }, `${copyrightLabel} ${new Date().getFullYear()}`)))));
|
|
132
151
|
}
|
|
133
152
|
get element() { return getElement(this); }
|
|
134
153
|
static get watchers() { return {
|