@duetds/components 4.30.0 → 4.33.0
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 +1481 -434
- package/lib/cjs/{dom-e89ebf90.js → dom-c850c8d7.js} +1 -1
- package/lib/cjs/duet-alert.cjs.entry.js +4 -2
- package/lib/cjs/duet-badge.cjs.entry.js +2 -2
- package/lib/cjs/duet-button_2.cjs.entry.js +6 -5
- package/lib/cjs/duet-caption_4.cjs.entry.js +21 -15
- package/lib/cjs/duet-card.cjs.entry.js +6 -6
- package/lib/cjs/duet-checkbox.cjs.entry.js +2 -2
- package/lib/cjs/duet-choice_2.cjs.entry.js +56 -25
- package/lib/cjs/duet-collapsible.cjs.entry.js +5 -2
- package/lib/cjs/duet-cookie-consent.cjs.entry.js +1 -1
- package/lib/cjs/duet-date-picker.cjs.entry.js +23 -13
- package/lib/cjs/duet-divider_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-editable-table-button_3.cjs.entry.js +232 -0
- package/lib/cjs/{duet-table.cjs.entry.js → duet-editable-table_3.cjs.entry.js} +206 -2
- package/lib/cjs/duet-empty-state.cjs.entry.js +1 -1
- package/lib/cjs/duet-footer.cjs.entry.js +4 -4
- package/lib/cjs/duet-grid_2.cjs.entry.js +52 -4
- package/lib/cjs/duet-header_2.cjs.entry.js +26 -10
- package/lib/cjs/duet-hero.cjs.entry.js +6 -6
- package/lib/cjs/duet-icon.cjs.entry.js +6 -14
- package/lib/cjs/duet-input_2.cjs.entry.js +7 -7
- package/lib/cjs/duet-layout.cjs.entry.js +1 -1
- package/lib/cjs/duet-list_2.cjs.entry.js +2 -2
- package/lib/cjs/duet-modal.cjs.entry.js +8 -7
- package/lib/cjs/duet-notification_2.cjs.entry.js +6 -5
- package/lib/cjs/duet-number-input.cjs.entry.js +36 -15
- package/lib/cjs/duet-progress.cjs.entry.js +75 -0
- package/lib/cjs/duet-radio_2.cjs.entry.js +2 -2
- package/lib/cjs/duet-range-slider.cjs.entry.js +2 -2
- package/lib/cjs/duet-select.cjs.entry.js +6 -6
- package/lib/cjs/duet-step_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-tab_2.cjs.entry.js +12 -6
- package/lib/cjs/duet-textarea.cjs.entry.js +5 -5
- package/lib/cjs/duet-toggle.cjs.entry.js +1 -1
- package/lib/cjs/duet-tooltip.cjs.entry.js +21 -10
- package/lib/cjs/duet-tray.cjs.entry.js +21 -10
- package/lib/cjs/duet-upload.cjs.entry.js +403 -180
- package/lib/cjs/duet-visually-hidden.cjs.entry.js +1 -1
- package/lib/cjs/duet.cjs.js +4 -4
- package/lib/cjs/{focus-utils-7605778f.js → focus-utils-a7a1fb8b.js} +1 -1
- package/lib/cjs/{index-0c949193.js → index-b724d698.js} +88 -77
- package/lib/cjs/js-utils-33a9dbe3.js +16 -0
- package/lib/cjs/{language-utils-70d6a9a4.js → language-utils-aa282901.js} +28 -9
- package/lib/cjs/loader.cjs.js +3 -3
- package/lib/cjs/{shadow-css-0c8c175b.js → shadow-css-e3edeed1.js} +9 -10
- package/lib/cjs/{string-utils-a6de43d8.js → string-utils-267e3dbb.js} +7 -0
- package/lib/cjs/{token-utils-13e5d13e.js → token-utils-63a9c8dc.js} +1 -1
- package/lib/cjs/{tokens.module-53b3bd92.js → tokens.module-6b2df1c2.js} +2 -0
- package/lib/cjs/{watch-options-3877c082.js → watch-options-d88afac0.js} +29 -6
- package/lib/collection/collection-manifest.json +15 -8
- package/lib/collection/components/duet-alert/duet-alert.js +12 -6
- package/lib/collection/components/duet-badge/duet-badge.css +1 -0
- package/lib/collection/components/duet-button/duet-button.js +17 -15
- package/lib/collection/components/duet-card/duet-card.css +30 -7
- package/lib/collection/components/duet-card/duet-card.js +4 -3
- package/lib/collection/components/duet-checkbox/duet-checkbox.css +1 -1
- package/lib/collection/components/duet-choice/duet-choice.css +16 -3
- package/lib/collection/components/duet-choice/duet-choice.js +123 -36
- package/lib/collection/components/duet-choice-group/duet-choice-group.css +1 -0
- package/lib/collection/components/duet-choice-group/duet-choice-group.js +4 -4
- package/lib/collection/components/duet-date-picker/duet-date-picker.css +1 -1
- package/lib/collection/components/duet-date-picker/duet-date-picker.js +78 -43
- package/lib/collection/components/duet-editable-table/duet-editable-table-button.css +32 -0
- package/lib/collection/components/duet-editable-table/duet-editable-table-button.js +218 -0
- package/lib/collection/components/duet-editable-table/duet-editable-table-item.css +36 -0
- package/lib/collection/components/duet-editable-table/duet-editable-table-item.js +203 -0
- package/lib/collection/components/duet-editable-table/duet-editable-table-tabledata.js +13 -0
- package/lib/collection/components/duet-editable-table/duet-editable-table.css +16 -0
- package/lib/collection/components/duet-editable-table/duet-editable-table.js +348 -0
- package/lib/collection/components/duet-footer/duet-footer.js +17 -15
- package/lib/collection/components/duet-grid/duet-grid.js +57 -6
- package/lib/collection/components/duet-grid-item/duet-grid-item.js +4 -4
- package/lib/collection/components/duet-header/duet-header.js +60 -35
- package/lib/collection/components/duet-heading/duet-heading.css +4 -0
- package/lib/collection/components/duet-heading/duet-heading.js +7 -6
- package/lib/collection/components/duet-hero/duet-hero.js +20 -15
- package/lib/collection/components/duet-icon/duet-icon.js +2 -6
- package/lib/collection/components/duet-icon/icon-utils.js +5 -8
- package/lib/collection/components/duet-input/duet-input.css +15 -0
- package/lib/collection/components/duet-input/duet-input.js +4 -4
- package/lib/collection/components/duet-label/duet-label.css +2 -0
- package/lib/collection/components/duet-link/duet-link.js +18 -19
- package/lib/collection/components/duet-logo/duet-logo.js +4 -4
- package/lib/collection/components/duet-modal/duet-modal.js +22 -17
- package/lib/collection/components/duet-notification/duet-notification.js +8 -8
- package/lib/collection/components/duet-notification-drawer/duet-notification-drawer.js +20 -15
- package/lib/collection/components/duet-number-input/duet-number-input.js +153 -29
- package/lib/collection/components/duet-paragraph/duet-paragraph.css +6 -0
- package/lib/collection/components/duet-paragraph/duet-paragraph.js +34 -3
- package/lib/collection/components/duet-progress/duet-progress.css +103 -0
- package/lib/collection/components/duet-progress/duet-progress.js +240 -0
- package/lib/collection/components/duet-radio/duet-radio.js +6 -6
- package/lib/collection/components/duet-select/duet-select.css +15 -0
- package/lib/collection/components/duet-select/duet-select.js +3 -3
- package/lib/collection/components/duet-step/duet-step.js +8 -8
- package/lib/collection/components/duet-tab-group/duet-tab-group.css +2 -2
- package/lib/collection/components/duet-tab-group/duet-tab-group.js +43 -12
- package/lib/collection/components/duet-textarea/duet-textarea.css +19 -0
- package/lib/collection/components/duet-textarea/duet-textarea.js +5 -4
- package/lib/collection/components/duet-tooltip/duet-tooltip.js +82 -20
- package/lib/collection/components/duet-tray/duet-tray.js +79 -17
- package/lib/collection/components/duet-upload/duet-upload-aria-status.js +217 -0
- package/lib/collection/components/duet-upload/duet-upload-editable-item-error.js +16 -0
- package/lib/collection/components/duet-upload/duet-upload-editable-item-inprogres.js +8 -0
- package/lib/collection/components/duet-upload/duet-upload-editable-item-success.js +30 -0
- package/lib/collection/components/duet-upload/duet-upload.css +17 -86
- package/lib/collection/components/duet-upload/duet-upload.js +551 -153
- package/lib/collection/components/duet-upload/errorcodes.utils.js +16 -4
- package/lib/collection/components/duet-upload/xhr.helpers.js +2 -6
- package/lib/collection/utils/fixture-utils.js +7 -5
- package/lib/collection/utils/js-utils.js +12 -0
- package/lib/collection/utils/language-utils.js +26 -9
- package/lib/collection/utils/string-utils.js +6 -0
- package/lib/collection/utils/watch-options.js +35 -6
- package/lib/custom-elements-bundle/index.d.ts +30 -0
- package/lib/custom-elements-bundle/index.js +1603 -721
- package/lib/duet/duet.esm.js +1 -1
- package/lib/duet/duet.js +1 -1
- package/lib/duet/{p-4a7911fd.entry.js → p-00735436.entry.js} +1 -1
- package/lib/duet/p-060d79be.entry.js +4 -0
- package/lib/duet/p-0d22396e.system.js +16 -0
- package/lib/duet/p-10deead0.system.js +4 -0
- package/lib/duet/p-1208c84f.entry.js +4 -0
- package/lib/duet/p-12721178.js +4 -0
- package/lib/duet/p-155ef581.system.entry.js +4 -0
- package/lib/duet/p-16c48c5d.entry.js +4 -0
- package/lib/duet/p-1797df7b.system.entry.js +4 -0
- package/lib/duet/p-1a08fc22.system.entry.js +4 -0
- package/lib/duet/{p-d1817efe.system.entry.js → p-237e47b4.system.entry.js} +1 -1
- package/lib/duet/p-2443bdca.system.entry.js +4 -0
- package/lib/duet/p-263bc9cd.system.entry.js +4 -0
- package/lib/duet/p-2764f081.js +4 -0
- package/lib/duet/p-27d80cef.system.entry.js +4 -0
- package/lib/duet/p-28e02c08.entry.js +4 -0
- package/lib/duet/{p-f81d8534.entry.js → p-2bb1460c.entry.js} +1 -1
- package/lib/duet/p-33c58756.entry.js +4 -0
- package/lib/duet/{p-bd9a7d8f.js → p-35a3794e.js} +0 -0
- package/lib/duet/{p-bbc229d8.system.entry.js → p-374fb7e6.system.entry.js} +1 -1
- package/lib/duet/p-387823af.system.entry.js +4 -0
- package/lib/duet/p-3af5d66f.entry.js +4 -0
- package/lib/duet/{p-322d1c38.js → p-3c1971d8.js} +1 -1
- package/lib/duet/{p-7e108b7e.entry.js → p-4607af59.entry.js} +1 -1
- package/lib/duet/p-48d1eb1f.system.entry.js +4 -0
- package/lib/duet/p-4a87e9ab.system.entry.js +4 -0
- package/lib/duet/{p-031c2cd8.system.entry.js → p-4b6ebe40.system.entry.js} +1 -1
- package/lib/duet/p-4e28da18.system.entry.js +4 -0
- package/lib/duet/p-548d484e.js +4 -0
- package/lib/duet/p-5826523b.entry.js +4 -0
- package/lib/duet/{p-ce1374a4.system.entry.js → p-58750bae.system.entry.js} +1 -1
- package/lib/duet/p-597d99c7.entry.js +4 -0
- package/lib/duet/p-5ea0cd19.entry.js +4 -0
- package/lib/duet/p-63d5bf73.system.entry.js +4 -0
- package/lib/duet/p-67d9a9a9.system.entry.js +4 -0
- package/lib/duet/p-6a19b5ec.entry.js +4 -0
- package/lib/duet/p-6cc3be76.system.entry.js +4 -0
- package/lib/duet/p-6e363557.system.js +4 -0
- package/lib/duet/p-6e6e76db.system.entry.js +4 -0
- package/lib/duet/p-70fafc98.system.js +4 -0
- package/lib/duet/p-7368b14e.system.entry.js +4 -0
- package/lib/duet/p-751542a0.system.entry.js +4 -0
- package/lib/duet/p-794659ac.entry.js +4 -0
- package/lib/duet/p-7e8d5bb9.system.entry.js +4 -0
- package/lib/duet/p-7fee0d23.system.entry.js +4 -0
- package/lib/duet/p-81867417.system.js +4 -0
- package/lib/duet/p-86daec1c.entry.js +4 -0
- package/lib/duet/{p-4265de16.system.entry.js → p-8b5ca0e7.system.entry.js} +1 -1
- package/lib/duet/{p-66dde4d2.entry.js → p-8cb7416d.entry.js} +1 -1
- package/lib/duet/p-8f826843.system.entry.js +4 -0
- package/lib/duet/p-94169303.entry.js +4 -0
- package/lib/duet/{p-36007600.entry.js → p-9481e312.entry.js} +1 -1
- package/lib/duet/{p-f82709ba.entry.js → p-984576c9.entry.js} +1 -1
- package/lib/duet/p-986779fb.js +4 -0
- package/lib/duet/p-987edcd0.js +15 -0
- package/lib/duet/{p-35e45c19.system.js → p-9a945278.system.js} +1 -1
- package/lib/duet/p-9d73343a.entry.js +4 -0
- package/lib/duet/{p-e26116e0.system.entry.js → p-9dca5c22.system.entry.js} +1 -1
- package/lib/duet/p-a207b008.entry.js +4 -0
- package/lib/duet/p-a5b9c192.system.entry.js +4 -0
- package/lib/duet/p-a6a84ec6.entry.js +4 -0
- package/lib/duet/{p-2d2c45f9.entry.js → p-a890da72.entry.js} +1 -1
- package/lib/duet/p-a9859a82.entry.js +4 -0
- package/lib/duet/p-aba68b7b.entry.js +4 -0
- package/lib/duet/p-acc57c77.entry.js +4 -0
- package/lib/duet/{p-2826f987.js → p-ad07f399.js} +1 -1
- package/lib/duet/p-aee24388.system.entry.js +4 -0
- package/lib/duet/p-aef1b720.system.entry.js +4 -0
- package/lib/duet/{p-62806bb6.system.entry.js → p-af41d894.system.entry.js} +1 -1
- package/lib/duet/p-b25d3769.js +4 -0
- package/lib/duet/{p-dee41056.system.entry.js → p-b32224fe.system.entry.js} +1 -1
- package/lib/duet/p-b3744481.entry.js +4 -0
- package/lib/duet/{p-de2be65b.system.js → p-b42d81c3.system.js} +1 -1
- package/lib/duet/{p-27d538f7.system.entry.js → p-b4e87f02.system.entry.js} +1 -1
- package/lib/duet/{p-f71f12ed.entry.js → p-bf93a991.entry.js} +1 -1
- package/lib/duet/{p-fd98468a.system.js → p-c18a599e.system.js} +0 -0
- package/lib/duet/p-c2e77278.entry.js +4 -0
- package/lib/duet/p-c34329f3.entry.js +4 -0
- package/lib/duet/{p-59a07cf9.entry.js → p-c36b4da0.entry.js} +1 -1
- package/lib/duet/{p-a321a98c.entry.js → p-cdd70b93.entry.js} +1 -1
- package/lib/duet/p-d1c19f04.system.entry.js +4 -0
- package/lib/duet/{p-f71e337e.system.entry.js → p-d3a3c3c7.system.entry.js} +1 -1
- package/lib/duet/{p-345ea4f2.system.entry.js → p-d4118b6e.system.entry.js} +1 -1
- package/lib/duet/{p-3dc9d15d.system.entry.js → p-d744d188.system.entry.js} +1 -1
- package/lib/duet/p-ddb6344c.system.js +4 -0
- package/lib/duet/p-de07c7d7.entry.js +4 -0
- package/lib/duet/p-dfe79666.system.entry.js +4 -0
- package/lib/duet/p-e12f2b8b.system.js +4 -0
- package/lib/duet/p-e2a44156.js +4 -0
- package/lib/duet/p-e76b722f.entry.js +4 -0
- package/lib/duet/p-e964d062.entry.js +4 -0
- package/lib/duet/p-eb55ccd2.system.js +4 -0
- package/lib/duet/p-f0a4b68d.system.entry.js +4 -0
- package/lib/duet/p-f364eb96.entry.js +4 -0
- package/lib/duet/{p-a88df408.entry.js → p-f8ce39fb.entry.js} +1 -1
- package/lib/esm/{dom-21034390.js → dom-58cd15f6.js} +1 -1
- package/lib/esm/duet-alert.entry.js +4 -2
- package/lib/esm/duet-badge.entry.js +2 -2
- package/lib/esm/duet-button_2.entry.js +6 -5
- package/lib/esm/duet-caption_4.entry.js +21 -15
- package/lib/esm/duet-card.entry.js +6 -6
- package/lib/esm/duet-checkbox.entry.js +2 -2
- package/lib/esm/duet-choice_2.entry.js +57 -26
- package/lib/esm/duet-collapsible.entry.js +5 -2
- package/lib/esm/duet-cookie-consent.entry.js +1 -1
- package/lib/esm/duet-date-picker.entry.js +23 -13
- package/lib/esm/duet-divider_2.entry.js +1 -1
- package/lib/esm/duet-editable-table-button_3.entry.js +226 -0
- package/lib/esm/{duet-table.entry.js → duet-editable-table_3.entry.js} +205 -3
- package/lib/esm/duet-empty-state.entry.js +1 -1
- package/lib/esm/duet-footer.entry.js +4 -4
- package/lib/esm/duet-grid_2.entry.js +52 -4
- package/lib/esm/duet-header_2.entry.js +26 -10
- package/lib/esm/duet-hero.entry.js +6 -6
- package/lib/esm/duet-icon.entry.js +6 -14
- package/lib/esm/duet-input_2.entry.js +7 -7
- package/lib/esm/duet-layout.entry.js +1 -1
- package/lib/esm/duet-list_2.entry.js +2 -2
- package/lib/esm/duet-modal.entry.js +8 -7
- package/lib/esm/duet-notification_2.entry.js +6 -5
- package/lib/esm/duet-number-input.entry.js +36 -15
- package/lib/esm/duet-progress.entry.js +71 -0
- package/lib/esm/duet-radio_2.entry.js +2 -2
- package/lib/esm/duet-range-slider.entry.js +2 -2
- package/lib/esm/duet-select.entry.js +6 -6
- package/lib/esm/duet-step_2.entry.js +1 -1
- package/lib/esm/duet-tab_2.entry.js +12 -6
- package/lib/esm/duet-textarea.entry.js +5 -5
- package/lib/esm/duet-toggle.entry.js +1 -1
- package/lib/esm/duet-tooltip.entry.js +21 -10
- package/lib/esm/duet-tray.entry.js +21 -10
- package/lib/esm/duet-upload.entry.js +403 -180
- package/lib/esm/duet-visually-hidden.entry.js +1 -1
- package/lib/esm/duet.js +4 -4
- package/lib/esm/{focus-utils-0b12f0df.js → focus-utils-1fe0dcd0.js} +1 -1
- package/lib/esm/{index-f70ddc7f.js → index-84d97bd1.js} +88 -78
- package/lib/esm/js-utils-b69f17df.js +14 -0
- package/lib/esm/{language-utils-ab9c3afc.js → language-utils-344d894c.js} +28 -10
- package/lib/esm/loader.js +3 -3
- package/lib/esm/{shadow-css-31e2d504.js → shadow-css-7c726abb.js} +9 -10
- package/lib/esm/{string-utils-69cf0d09.js → string-utils-2f1793b8.js} +7 -1
- package/lib/esm/{token-utils-5a35377f.js → token-utils-590d9413.js} +1 -1
- package/lib/esm/{tokens.module-edb66c04.js → tokens.module-49cbf963.js} +3 -1
- package/lib/esm/watch-options-dd55bce8.js +57 -0
- package/lib/esm-es5/{dom-21034390.js → dom-58cd15f6.js} +0 -0
- 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-button_2.entry.js +1 -1
- package/lib/esm-es5/duet-caption_4.entry.js +2 -2
- 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-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-button_3.entry.js +4 -0
- package/lib/esm-es5/duet-editable-table_3.entry.js +4 -0
- package/lib/esm-es5/duet-empty-state.entry.js +1 -1
- package/lib/esm-es5/duet-footer.entry.js +1 -1
- package/lib/esm-es5/duet-grid_2.entry.js +2 -2
- 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 +2 -2
- 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-progress.entry.js +4 -0
- 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-select.entry.js +1 -1
- package/lib/esm-es5/duet-step_2.entry.js +1 -1
- package/lib/esm-es5/duet-tab_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.entry.js +2 -2
- 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-0b12f0df.js → focus-utils-1fe0dcd0.js} +1 -1
- package/lib/esm-es5/index-84d97bd1.js +4 -0
- package/lib/esm-es5/js-utils-b69f17df.js +4 -0
- package/lib/esm-es5/language-utils-344d894c.js +4 -0
- package/lib/esm-es5/loader.js +1 -1
- package/lib/esm-es5/shadow-css-7c726abb.js +15 -0
- package/lib/esm-es5/{string-utils-69cf0d09.js → string-utils-2f1793b8.js} +1 -1
- package/lib/esm-es5/{token-utils-5a35377f.js → token-utils-590d9413.js} +1 -1
- package/lib/esm-es5/tokens.module-49cbf963.js +4 -0
- package/lib/esm-es5/watch-options-dd55bce8.js +4 -0
- package/lib/types/components/duet-alert/duet-alert.d.ts +2 -1
- package/lib/types/components/duet-button/duet-button.d.ts +1 -1
- package/lib/types/components/duet-choice/duet-choice.d.ts +24 -5
- package/lib/types/components/duet-date-picker/duet-date-picker.d.ts +15 -9
- package/lib/types/components/duet-editable-table/duet-editable-table-button.d.ts +72 -0
- package/lib/types/components/duet-editable-table/duet-editable-table-item.d.ts +72 -0
- package/lib/types/components/duet-editable-table/duet-editable-table-tabledata.d.ts +7 -0
- package/lib/types/components/duet-editable-table/duet-editable-table.d.ts +84 -0
- package/lib/types/components/duet-footer/duet-footer.d.ts +1 -1
- package/lib/types/components/duet-grid/duet-grid.d.ts +16 -2
- package/lib/types/components/duet-header/duet-header.d.ts +21 -5
- package/lib/types/components/duet-heading/duet-heading.d.ts +2 -2
- package/lib/types/components/duet-hero/duet-hero.d.ts +3 -3
- package/lib/types/components/duet-icon/duet-icon.d.ts +1 -1
- package/lib/types/components/duet-link/duet-link.d.ts +2 -3
- package/lib/types/components/duet-modal/duet-modal.d.ts +3 -3
- package/lib/types/components/duet-notification-drawer/duet-notification-drawer.d.ts +3 -3
- package/lib/types/components/duet-number-input/duet-number-input.d.ts +21 -0
- package/lib/types/components/duet-paragraph/duet-paragraph.d.ts +9 -1
- package/lib/types/components/duet-progress/duet-progress.d.ts +64 -0
- package/lib/types/components/duet-tab-group/duet-tab-group.d.ts +6 -0
- package/lib/types/components/duet-tooltip/duet-tooltip.d.ts +11 -0
- package/lib/types/components/duet-tray/duet-tray.d.ts +11 -0
- package/lib/types/components/duet-upload/duet-upload-aria-status.d.ts +49 -0
- package/lib/types/components/duet-upload/duet-upload-editable-item-error.d.ts +7 -0
- package/lib/types/components/duet-upload/duet-upload-editable-item-inprogres.d.ts +7 -0
- package/lib/types/components/duet-upload/duet-upload-editable-item-success.d.ts +8 -0
- package/lib/types/components/duet-upload/duet-upload.d.ts +94 -25
- package/lib/types/components/duet-upload/errorcodes.utils.d.ts +1 -0
- package/lib/types/components/duet-upload/xhr.helpers.d.ts +7 -1
- package/lib/types/components.d.ts +611 -79
- package/lib/types/utils/js-utils.d.ts +1 -0
- package/lib/types/utils/language-utils.d.ts +8 -3
- package/lib/types/utils/string-utils.d.ts +1 -0
- package/lib/types/utils/watch-options.d.ts +2 -0
- package/package.json +19 -15
- package/hydrate/package.json +0 -6
- package/lib/cjs/duet-fieldset.cjs.entry.js +0 -62
- package/lib/collection/components/duet-upload/duet-upload-file-list.js +0 -49
- package/lib/duet/p-0733c303.system.entry.js +0 -4
- package/lib/duet/p-095060cc.js +0 -4
- package/lib/duet/p-156864a1.system.entry.js +0 -4
- package/lib/duet/p-15c15c6a.js +0 -15
- package/lib/duet/p-1911dfe7.system.entry.js +0 -4
- package/lib/duet/p-1c41525a.entry.js +0 -4
- package/lib/duet/p-1cfe38b1.system.entry.js +0 -4
- package/lib/duet/p-2834a302.entry.js +0 -4
- package/lib/duet/p-28a3d38f.system.entry.js +0 -4
- package/lib/duet/p-2a1a9f9f.entry.js +0 -4
- package/lib/duet/p-2a4d7c5b.system.entry.js +0 -4
- package/lib/duet/p-3eb36e3d.entry.js +0 -4
- package/lib/duet/p-4095dba5.entry.js +0 -4
- package/lib/duet/p-418b2ce7.system.js +0 -4
- package/lib/duet/p-4289b543.entry.js +0 -4
- package/lib/duet/p-43e39d98.system.js +0 -4
- package/lib/duet/p-46a3ae43.system.js +0 -4
- package/lib/duet/p-4a38cf9d.entry.js +0 -4
- package/lib/duet/p-4be8e814.entry.js +0 -4
- package/lib/duet/p-4dcea8fb.system.entry.js +0 -4
- package/lib/duet/p-591b2137.entry.js +0 -4
- package/lib/duet/p-5c5bdb06.system.entry.js +0 -4
- package/lib/duet/p-5f70e318.entry.js +0 -4
- package/lib/duet/p-62c294d6.system.entry.js +0 -4
- package/lib/duet/p-6a356ab1.system.js +0 -4
- package/lib/duet/p-6c2729da.js +0 -4
- package/lib/duet/p-6f107847.system.entry.js +0 -4
- package/lib/duet/p-77a5fe4c.system.js +0 -4
- package/lib/duet/p-7809e78b.system.entry.js +0 -4
- package/lib/duet/p-7a36d76f.system.entry.js +0 -4
- package/lib/duet/p-7ee52f58.entry.js +0 -4
- package/lib/duet/p-884693f1.entry.js +0 -4
- package/lib/duet/p-89db3b94.entry.js +0 -4
- package/lib/duet/p-8cfce39e.system.entry.js +0 -4
- package/lib/duet/p-8ffe1461.system.entry.js +0 -4
- package/lib/duet/p-9381c2d4.entry.js +0 -4
- package/lib/duet/p-9a450c9a.entry.js +0 -4
- package/lib/duet/p-9a89ec39.js +0 -4
- package/lib/duet/p-9bbfe606.system.entry.js +0 -4
- package/lib/duet/p-a6096b05.system.entry.js +0 -4
- package/lib/duet/p-a89d5d7c.entry.js +0 -4
- package/lib/duet/p-b07055fd.system.entry.js +0 -4
- package/lib/duet/p-b4374f0e.entry.js +0 -4
- package/lib/duet/p-b456d684.system.entry.js +0 -4
- package/lib/duet/p-bd18c93f.js +0 -4
- package/lib/duet/p-bddb1c15.system.entry.js +0 -4
- package/lib/duet/p-c0b95b58.entry.js +0 -4
- package/lib/duet/p-c3688975.entry.js +0 -4
- package/lib/duet/p-c4d183e6.entry.js +0 -4
- package/lib/duet/p-c9303f9a.entry.js +0 -4
- package/lib/duet/p-cd4e8ccf.js +0 -4
- package/lib/duet/p-ceb75b35.system.entry.js +0 -4
- package/lib/duet/p-cf243bcb.system.entry.js +0 -4
- package/lib/duet/p-d37c8a05.system.js +0 -4
- package/lib/duet/p-d989af11.entry.js +0 -4
- package/lib/duet/p-e58ca7af.system.js +0 -16
- package/lib/duet/p-e6128d82.system.entry.js +0 -4
- package/lib/duet/p-e86cdc17.entry.js +0 -4
- package/lib/duet/p-eadb29c7.entry.js +0 -4
- package/lib/duet/p-f30b14d6.system.entry.js +0 -4
- package/lib/duet/p-f79f8da1.entry.js +0 -4
- package/lib/duet/p-fc397e03.system.entry.js +0 -4
- package/lib/esm/duet-fieldset.entry.js +0 -58
- package/lib/esm/watch-options-de55ea78.js +0 -35
- package/lib/esm-es5/duet-fieldset.entry.js +0 -4
- package/lib/esm-es5/duet-table.entry.js +0 -4
- package/lib/esm-es5/index-f70ddc7f.js +0 -4
- package/lib/esm-es5/language-utils-ab9c3afc.js +0 -4
- package/lib/esm-es5/shadow-css-31e2d504.js +0 -15
- package/lib/esm-es5/tokens.module-edb66c04.js +0 -4
- package/lib/esm-es5/watch-options-de55ea78.js +0 -4
- package/lib/html.html-data.json +0 -4556
- package/lib/types/components/duet-upload/duet-upload-file-list.d.ts +0 -9
|
@@ -29,25 +29,35 @@ export class DuetTooltip {
|
|
|
29
29
|
*/
|
|
30
30
|
this.language = getLanguage();
|
|
31
31
|
/**
|
|
32
|
-
*
|
|
33
|
-
* readers. This property is always required to create an accessible interface!
|
|
32
|
+
* Default language strings for the accessibleLabel
|
|
34
33
|
* @default {fi: "Näytä lisätietoja", en: "See more information", sv: "Se mer information"}
|
|
35
34
|
*/
|
|
36
|
-
this.
|
|
35
|
+
this.accessibleLabelDefault = {
|
|
37
36
|
fi: "Näytä lisätietoja",
|
|
38
37
|
en: "Show more information",
|
|
39
38
|
sv: "Visa mer tilläggsuppgifter",
|
|
40
|
-
}
|
|
39
|
+
};
|
|
41
40
|
/**
|
|
42
|
-
* Adds accessible label for the
|
|
43
|
-
* readers. This property is always required to create an
|
|
41
|
+
* Adds accessible label for the info icon that is only shown for screen
|
|
42
|
+
* readers. This property is always required to create an accessible interface!
|
|
43
|
+
* @default {fi: "Näytä lisätietoja", en: "See more information", sv: "Se mer information"}
|
|
44
|
+
*/
|
|
45
|
+
this.accessibleLabel = getLocaleString(this.accessibleLabelDefault, this.language);
|
|
46
|
+
/**
|
|
47
|
+
* Default language strings for the accessibleCloseLabel
|
|
44
48
|
* @default {fi: "Sulje lisätiedot", en: "Close details", sv: "Stäng detaljer"}
|
|
45
49
|
*/
|
|
46
|
-
this.
|
|
50
|
+
this.accessibleCloseLabelDefault = {
|
|
47
51
|
fi: "Sulje lisätiedot",
|
|
48
52
|
en: "Close details",
|
|
49
53
|
sv: "Stäng tilläggsuppgifter",
|
|
50
|
-
}
|
|
54
|
+
};
|
|
55
|
+
/**
|
|
56
|
+
* Adds accessible label for the close icon that is only shown for screen
|
|
57
|
+
* readers. This property is always required to create an accessibly interface!
|
|
58
|
+
* @default {fi: "Sulje lisätiedot", en: "Close details", sv: "Stäng detaljer"}
|
|
59
|
+
*/
|
|
60
|
+
this.accessibleCloseLabel = getLocaleString(this.accessibleCloseLabelDefault, this.language);
|
|
51
61
|
/**
|
|
52
62
|
* Label of the tooltip. If used, replaces the accessibleLabel option.
|
|
53
63
|
*/
|
|
@@ -270,11 +280,11 @@ export class DuetTooltip {
|
|
|
270
280
|
"optional": false,
|
|
271
281
|
"docs": {
|
|
272
282
|
"tags": [{
|
|
273
|
-
"
|
|
274
|
-
"
|
|
283
|
+
"name": "deprecated",
|
|
284
|
+
"text": "this is now handled via the html lang tag, and is no longer used - kept to avoid breaking changes and ease unit testing"
|
|
275
285
|
}, {
|
|
276
|
-
"
|
|
277
|
-
"
|
|
286
|
+
"name": "default",
|
|
287
|
+
"text": "\"fi\""
|
|
278
288
|
}],
|
|
279
289
|
"text": "The currently active language. This setting changes the accessible labels to match the\nchosen language."
|
|
280
290
|
},
|
|
@@ -282,6 +292,32 @@ export class DuetTooltip {
|
|
|
282
292
|
"reflect": false,
|
|
283
293
|
"defaultValue": "getLanguage()"
|
|
284
294
|
},
|
|
295
|
+
"accessibleLabelDefault": {
|
|
296
|
+
"type": "string",
|
|
297
|
+
"mutable": false,
|
|
298
|
+
"complexType": {
|
|
299
|
+
"original": "DuetLangObject | string",
|
|
300
|
+
"resolved": "DuetLangObject | string",
|
|
301
|
+
"references": {
|
|
302
|
+
"DuetLangObject": {
|
|
303
|
+
"location": "import",
|
|
304
|
+
"path": "../../utils/language-utils"
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
},
|
|
308
|
+
"required": false,
|
|
309
|
+
"optional": false,
|
|
310
|
+
"docs": {
|
|
311
|
+
"tags": [{
|
|
312
|
+
"name": "default",
|
|
313
|
+
"text": "{fi: \"N\u00E4yt\u00E4 lis\u00E4tietoja\", en: \"See more information\", sv: \"Se mer information\"}"
|
|
314
|
+
}],
|
|
315
|
+
"text": "Default language strings for the accessibleLabel"
|
|
316
|
+
},
|
|
317
|
+
"attribute": "accessible-label-default",
|
|
318
|
+
"reflect": false,
|
|
319
|
+
"defaultValue": "{\n fi: \"N\u00E4yt\u00E4 lis\u00E4tietoja\",\n en: \"Show more information\",\n sv: \"Visa mer till\u00E4ggsuppgifter\",\n }"
|
|
320
|
+
},
|
|
285
321
|
"accessibleLabel": {
|
|
286
322
|
"type": "string",
|
|
287
323
|
"mutable": false,
|
|
@@ -294,14 +330,14 @@ export class DuetTooltip {
|
|
|
294
330
|
"optional": false,
|
|
295
331
|
"docs": {
|
|
296
332
|
"tags": [{
|
|
297
|
-
"
|
|
298
|
-
"
|
|
333
|
+
"name": "default",
|
|
334
|
+
"text": "{fi: \"N\u00E4yt\u00E4 lis\u00E4tietoja\", en: \"See more information\", sv: \"Se mer information\"}"
|
|
299
335
|
}],
|
|
300
336
|
"text": "Adds accessible label for the info icon that is only shown for screen\nreaders. This property is always required to create an accessible interface!"
|
|
301
337
|
},
|
|
302
338
|
"attribute": "accessible-label",
|
|
303
339
|
"reflect": false,
|
|
304
|
-
"defaultValue": "getLocaleString(
|
|
340
|
+
"defaultValue": "getLocaleString(this.accessibleLabelDefault, this.language)"
|
|
305
341
|
},
|
|
306
342
|
"accessibleInputLabel": {
|
|
307
343
|
"type": "string",
|
|
@@ -315,14 +351,40 @@ export class DuetTooltip {
|
|
|
315
351
|
"optional": false,
|
|
316
352
|
"docs": {
|
|
317
353
|
"tags": [{
|
|
318
|
-
"
|
|
319
|
-
"
|
|
354
|
+
"name": "internal",
|
|
355
|
+
"text": "Adds a prefix to the accessible label.\nUsed internally by input components to add more context to the tooltip."
|
|
320
356
|
}],
|
|
321
357
|
"text": ""
|
|
322
358
|
},
|
|
323
359
|
"attribute": "accessible-input-label",
|
|
324
360
|
"reflect": false
|
|
325
361
|
},
|
|
362
|
+
"accessibleCloseLabelDefault": {
|
|
363
|
+
"type": "string",
|
|
364
|
+
"mutable": false,
|
|
365
|
+
"complexType": {
|
|
366
|
+
"original": "DuetLangObject | string",
|
|
367
|
+
"resolved": "DuetLangObject | string",
|
|
368
|
+
"references": {
|
|
369
|
+
"DuetLangObject": {
|
|
370
|
+
"location": "import",
|
|
371
|
+
"path": "../../utils/language-utils"
|
|
372
|
+
}
|
|
373
|
+
}
|
|
374
|
+
},
|
|
375
|
+
"required": false,
|
|
376
|
+
"optional": false,
|
|
377
|
+
"docs": {
|
|
378
|
+
"tags": [{
|
|
379
|
+
"name": "default",
|
|
380
|
+
"text": "{fi: \"Sulje lis\u00E4tiedot\", en: \"Close details\", sv: \"St\u00E4ng detaljer\"}"
|
|
381
|
+
}],
|
|
382
|
+
"text": "Default language strings for the accessibleCloseLabel"
|
|
383
|
+
},
|
|
384
|
+
"attribute": "accessible-close-label-default",
|
|
385
|
+
"reflect": false,
|
|
386
|
+
"defaultValue": "{\n fi: \"Sulje lis\u00E4tiedot\",\n en: \"Close details\",\n sv: \"St\u00E4ng till\u00E4ggsuppgifter\",\n }"
|
|
387
|
+
},
|
|
326
388
|
"accessibleCloseLabel": {
|
|
327
389
|
"type": "string",
|
|
328
390
|
"mutable": false,
|
|
@@ -335,14 +397,14 @@ export class DuetTooltip {
|
|
|
335
397
|
"optional": false,
|
|
336
398
|
"docs": {
|
|
337
399
|
"tags": [{
|
|
338
|
-
"
|
|
339
|
-
"
|
|
400
|
+
"name": "default",
|
|
401
|
+
"text": "{fi: \"Sulje lis\u00E4tiedot\", en: \"Close details\", sv: \"St\u00E4ng detaljer\"}"
|
|
340
402
|
}],
|
|
341
403
|
"text": "Adds accessible label for the close icon that is only shown for screen\nreaders. This property is always required to create an accessibly interface!"
|
|
342
404
|
},
|
|
343
405
|
"attribute": "accessible-close-label",
|
|
344
406
|
"reflect": false,
|
|
345
|
-
"defaultValue": "getLocaleString(
|
|
407
|
+
"defaultValue": "getLocaleString(this.accessibleCloseLabelDefault, this.language)"
|
|
346
408
|
},
|
|
347
409
|
"label": {
|
|
348
410
|
"type": "string",
|
|
@@ -31,25 +31,35 @@ export class DuetTray {
|
|
|
31
31
|
*/
|
|
32
32
|
this.language = getLanguage();
|
|
33
33
|
/**
|
|
34
|
-
*
|
|
35
|
-
* close toggle. Not visible for normal users.
|
|
34
|
+
* Defaults for accessibleCloseLabel
|
|
36
35
|
* @default {fi: "Sulje", en: "Close", sv: "Stänga"}
|
|
37
36
|
*/
|
|
38
|
-
this.
|
|
37
|
+
this.accessibleCloseLabelDefaults = {
|
|
39
38
|
fi: "Sulje",
|
|
40
39
|
en: "Close",
|
|
41
40
|
sv: "Stäng",
|
|
42
|
-
}
|
|
41
|
+
};
|
|
43
42
|
/**
|
|
44
43
|
* Accessible label that is shown for screen reader users in the expandable
|
|
45
|
-
*
|
|
44
|
+
* close toggle. Not visible for normal users.
|
|
45
|
+
* @default {fi: "Sulje", en: "Close", sv: "Stänga"}
|
|
46
|
+
*/
|
|
47
|
+
this.accessibleCloseLabel = getLocaleString(this.accessibleCloseLabelDefaults, this.language);
|
|
48
|
+
/**
|
|
49
|
+
* Defaults for accessibleOpenLabel
|
|
46
50
|
* @default {fi: "Avaa", en: "Open", sv: "Öppen"}
|
|
47
51
|
*/
|
|
48
|
-
this.
|
|
52
|
+
this.accessibleOpenLabelDefaults = {
|
|
49
53
|
fi: "Avaa",
|
|
50
54
|
en: "Open",
|
|
51
55
|
sv: "Öppna",
|
|
52
|
-
}
|
|
56
|
+
};
|
|
57
|
+
/**
|
|
58
|
+
* Accessible label that is shown for screen reader users in the expandable
|
|
59
|
+
* open toggle. Not visible for normal users.
|
|
60
|
+
* @default {fi: "Avaa", en: "Open", sv: "Öppen"}
|
|
61
|
+
*/
|
|
62
|
+
this.accessibleOpenLabel = getLocaleString(this.accessibleOpenLabelDefaults, this.language);
|
|
53
63
|
/**
|
|
54
64
|
* Theme of the info panel.
|
|
55
65
|
*/
|
|
@@ -151,11 +161,11 @@ export class DuetTray {
|
|
|
151
161
|
"optional": false,
|
|
152
162
|
"docs": {
|
|
153
163
|
"tags": [{
|
|
154
|
-
"
|
|
155
|
-
"
|
|
164
|
+
"name": "deprecated",
|
|
165
|
+
"text": "this is now handled via the html lang tag, and is no longer used - kept to avoid breaking changes and ease unit testing"
|
|
156
166
|
}, {
|
|
157
|
-
"
|
|
158
|
-
"
|
|
167
|
+
"name": "default",
|
|
168
|
+
"text": "\"fi\""
|
|
159
169
|
}],
|
|
160
170
|
"text": "The currently active language. This setting changes the accessible labels to match the\nchosen language."
|
|
161
171
|
},
|
|
@@ -163,6 +173,32 @@ export class DuetTray {
|
|
|
163
173
|
"reflect": false,
|
|
164
174
|
"defaultValue": "getLanguage()"
|
|
165
175
|
},
|
|
176
|
+
"accessibleCloseLabelDefaults": {
|
|
177
|
+
"type": "string",
|
|
178
|
+
"mutable": false,
|
|
179
|
+
"complexType": {
|
|
180
|
+
"original": "DuetLangObject | string",
|
|
181
|
+
"resolved": "DuetLangObject | string",
|
|
182
|
+
"references": {
|
|
183
|
+
"DuetLangObject": {
|
|
184
|
+
"location": "import",
|
|
185
|
+
"path": "../../utils/language-utils"
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
},
|
|
189
|
+
"required": false,
|
|
190
|
+
"optional": false,
|
|
191
|
+
"docs": {
|
|
192
|
+
"tags": [{
|
|
193
|
+
"name": "default",
|
|
194
|
+
"text": "{fi: \"Sulje\", en: \"Close\", sv: \"St\u00E4nga\"}"
|
|
195
|
+
}],
|
|
196
|
+
"text": "Defaults for accessibleCloseLabel"
|
|
197
|
+
},
|
|
198
|
+
"attribute": "accessible-close-label-default",
|
|
199
|
+
"reflect": false,
|
|
200
|
+
"defaultValue": "{\n fi: \"Sulje\",\n en: \"Close\",\n sv: \"St\u00E4ng\",\n }"
|
|
201
|
+
},
|
|
166
202
|
"accessibleCloseLabel": {
|
|
167
203
|
"type": "string",
|
|
168
204
|
"mutable": false,
|
|
@@ -175,14 +211,40 @@ export class DuetTray {
|
|
|
175
211
|
"optional": false,
|
|
176
212
|
"docs": {
|
|
177
213
|
"tags": [{
|
|
178
|
-
"
|
|
179
|
-
"
|
|
214
|
+
"name": "default",
|
|
215
|
+
"text": "{fi: \"Sulje\", en: \"Close\", sv: \"St\u00E4nga\"}"
|
|
180
216
|
}],
|
|
181
217
|
"text": "Accessible label that is shown for screen reader users in the expandable\nclose toggle. Not visible for normal users."
|
|
182
218
|
},
|
|
183
219
|
"attribute": "accessible-close-label",
|
|
184
220
|
"reflect": false,
|
|
185
|
-
"defaultValue": "getLocaleString(
|
|
221
|
+
"defaultValue": "getLocaleString(this.accessibleCloseLabelDefaults, this.language)"
|
|
222
|
+
},
|
|
223
|
+
"accessibleOpenLabelDefaults": {
|
|
224
|
+
"type": "string",
|
|
225
|
+
"mutable": false,
|
|
226
|
+
"complexType": {
|
|
227
|
+
"original": "DuetLangObject | string",
|
|
228
|
+
"resolved": "DuetLangObject | string",
|
|
229
|
+
"references": {
|
|
230
|
+
"DuetLangObject": {
|
|
231
|
+
"location": "import",
|
|
232
|
+
"path": "../../utils/language-utils"
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
},
|
|
236
|
+
"required": false,
|
|
237
|
+
"optional": false,
|
|
238
|
+
"docs": {
|
|
239
|
+
"tags": [{
|
|
240
|
+
"name": "default",
|
|
241
|
+
"text": "{fi: \"Avaa\", en: \"Open\", sv: \"\u00D6ppen\"}"
|
|
242
|
+
}],
|
|
243
|
+
"text": "Defaults for accessibleOpenLabel"
|
|
244
|
+
},
|
|
245
|
+
"attribute": "accessible-open-label-default",
|
|
246
|
+
"reflect": false,
|
|
247
|
+
"defaultValue": "{\n fi: \"Avaa\",\n en: \"Open\",\n sv: \"\u00D6ppna\",\n }"
|
|
186
248
|
},
|
|
187
249
|
"accessibleOpenLabel": {
|
|
188
250
|
"type": "string",
|
|
@@ -196,14 +258,14 @@ export class DuetTray {
|
|
|
196
258
|
"optional": false,
|
|
197
259
|
"docs": {
|
|
198
260
|
"tags": [{
|
|
199
|
-
"
|
|
200
|
-
"
|
|
261
|
+
"name": "default",
|
|
262
|
+
"text": "{fi: \"Avaa\", en: \"Open\", sv: \"\u00D6ppen\"}"
|
|
201
263
|
}],
|
|
202
264
|
"text": "Accessible label that is shown for screen reader users in the expandable\nopen toggle. Not visible for normal users."
|
|
203
265
|
},
|
|
204
266
|
"attribute": "accessible-open-label",
|
|
205
267
|
"reflect": false,
|
|
206
|
-
"defaultValue": "getLocaleString(
|
|
268
|
+
"defaultValue": "getLocaleString(this.accessibleOpenLabelDefaults, this.language)"
|
|
207
269
|
},
|
|
208
270
|
"theme": {
|
|
209
271
|
"type": "string",
|
|
@@ -0,0 +1,217 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Built with Duet Design System
|
|
3
|
+
*/
|
|
4
|
+
import { Component, h, Host, Prop, State, Watch } from "@stencil/core";
|
|
5
|
+
export class DuetUploadAriaStatus {
|
|
6
|
+
constructor() {
|
|
7
|
+
/**
|
|
8
|
+
* State() variables
|
|
9
|
+
*/
|
|
10
|
+
this.statusMessage = null;
|
|
11
|
+
/**
|
|
12
|
+
* State() variables
|
|
13
|
+
*/
|
|
14
|
+
this.statusMessageLabel = null;
|
|
15
|
+
/**
|
|
16
|
+
* Adds accessible label that is read aloud
|
|
17
|
+
*/
|
|
18
|
+
this.accessibleAriaLive = "polite";
|
|
19
|
+
/**
|
|
20
|
+
* valid file amount
|
|
21
|
+
*/
|
|
22
|
+
this.valid = undefined;
|
|
23
|
+
/**
|
|
24
|
+
* total files
|
|
25
|
+
*/
|
|
26
|
+
this.total = undefined;
|
|
27
|
+
/**
|
|
28
|
+
* invalid file amount
|
|
29
|
+
*/
|
|
30
|
+
this.invalid = undefined;
|
|
31
|
+
/**
|
|
32
|
+
* valid file amount
|
|
33
|
+
*/
|
|
34
|
+
this.inprogress = undefined;
|
|
35
|
+
/**
|
|
36
|
+
* Component lifecycle events.
|
|
37
|
+
*/
|
|
38
|
+
this.replacePlaceHolders = (statusString) => {
|
|
39
|
+
const addFiles = (amount) => {
|
|
40
|
+
return amount > 1 ? `${amount} ${this.statusMessageLabel.files}` : `${amount} ${this.statusMessageLabel.file}`;
|
|
41
|
+
};
|
|
42
|
+
return statusString
|
|
43
|
+
.replace("{filesUploaded}", addFiles(this.valid))
|
|
44
|
+
.replace("{filesInProgress}", addFiles(this.inprogress))
|
|
45
|
+
.replace("{filesTotal}", addFiles(this.total))
|
|
46
|
+
.replace("{filesWithErrors}", addFiles(this.invalid));
|
|
47
|
+
};
|
|
48
|
+
this.getStatusMessage = () => {
|
|
49
|
+
const { done, inProgress, doneWithErrors, inProgressWithErrors } = this.statusMessageLabel;
|
|
50
|
+
const hasErrors = this.invalid > 0;
|
|
51
|
+
const isInProgress = this.inprogress > 0;
|
|
52
|
+
const isInProgressWithErrors = this.inprogress > 0 && hasErrors;
|
|
53
|
+
const isDone = this.valid === this.total && !isInProgress && !hasErrors;
|
|
54
|
+
const isDoneWithErrors = this.valid + this.invalid === this.total && !isInProgress;
|
|
55
|
+
if (isDone) {
|
|
56
|
+
this.statusMessage = this.replacePlaceHolders(done);
|
|
57
|
+
return;
|
|
58
|
+
}
|
|
59
|
+
else if (isInProgressWithErrors) {
|
|
60
|
+
this.statusMessage = this.replacePlaceHolders(inProgressWithErrors);
|
|
61
|
+
return;
|
|
62
|
+
}
|
|
63
|
+
else if (isInProgress) {
|
|
64
|
+
this.statusMessage = this.replacePlaceHolders(inProgress);
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
else if (isDoneWithErrors) {
|
|
68
|
+
this.statusMessage = this.replacePlaceHolders(doneWithErrors);
|
|
69
|
+
return;
|
|
70
|
+
}
|
|
71
|
+
return;
|
|
72
|
+
};
|
|
73
|
+
}
|
|
74
|
+
watchHandler(newValue, oldValue) {
|
|
75
|
+
if (newValue !== oldValue) {
|
|
76
|
+
this.getStatusMessage();
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
/**
|
|
80
|
+
* render() function
|
|
81
|
+
* Always the last one in the class.
|
|
82
|
+
*/
|
|
83
|
+
render() {
|
|
84
|
+
return (h(Host, { role: "status", "aria-live": "assertive", "aria-atomic": "true", "aria-relevant": "all" },
|
|
85
|
+
h("duet-visually-hidden", null, this.statusMessage)));
|
|
86
|
+
}
|
|
87
|
+
static get is() { return "duet-upload-aria-status"; }
|
|
88
|
+
static get encapsulation() { return "shadow"; }
|
|
89
|
+
static get properties() { return {
|
|
90
|
+
"statusMessageLabel": {
|
|
91
|
+
"type": "unknown",
|
|
92
|
+
"mutable": false,
|
|
93
|
+
"complexType": {
|
|
94
|
+
"original": "StatusMessage",
|
|
95
|
+
"resolved": "{ inProgress: string; inProgressWithErrors: string; done: string; doneWithErrors: string; file: string; files: string; }",
|
|
96
|
+
"references": {
|
|
97
|
+
"StatusMessage": {
|
|
98
|
+
"location": "local"
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
},
|
|
102
|
+
"required": false,
|
|
103
|
+
"optional": false,
|
|
104
|
+
"docs": {
|
|
105
|
+
"tags": [],
|
|
106
|
+
"text": "State() variables"
|
|
107
|
+
},
|
|
108
|
+
"defaultValue": "null"
|
|
109
|
+
},
|
|
110
|
+
"accessibleAriaLive": {
|
|
111
|
+
"type": "string",
|
|
112
|
+
"mutable": false,
|
|
113
|
+
"complexType": {
|
|
114
|
+
"original": "\"off\" | \"polite\" | \"assertive\"",
|
|
115
|
+
"resolved": "\"assertive\" | \"off\" | \"polite\"",
|
|
116
|
+
"references": {}
|
|
117
|
+
},
|
|
118
|
+
"required": false,
|
|
119
|
+
"optional": false,
|
|
120
|
+
"docs": {
|
|
121
|
+
"tags": [],
|
|
122
|
+
"text": "Adds accessible label that is read aloud"
|
|
123
|
+
},
|
|
124
|
+
"attribute": "accessible-aria-live",
|
|
125
|
+
"reflect": false,
|
|
126
|
+
"defaultValue": "\"polite\""
|
|
127
|
+
},
|
|
128
|
+
"valid": {
|
|
129
|
+
"type": "number",
|
|
130
|
+
"mutable": false,
|
|
131
|
+
"complexType": {
|
|
132
|
+
"original": "number",
|
|
133
|
+
"resolved": "number",
|
|
134
|
+
"references": {}
|
|
135
|
+
},
|
|
136
|
+
"required": false,
|
|
137
|
+
"optional": false,
|
|
138
|
+
"docs": {
|
|
139
|
+
"tags": [],
|
|
140
|
+
"text": "valid file amount"
|
|
141
|
+
},
|
|
142
|
+
"attribute": "valid",
|
|
143
|
+
"reflect": false,
|
|
144
|
+
"defaultValue": "undefined"
|
|
145
|
+
},
|
|
146
|
+
"total": {
|
|
147
|
+
"type": "number",
|
|
148
|
+
"mutable": false,
|
|
149
|
+
"complexType": {
|
|
150
|
+
"original": "number",
|
|
151
|
+
"resolved": "number",
|
|
152
|
+
"references": {}
|
|
153
|
+
},
|
|
154
|
+
"required": false,
|
|
155
|
+
"optional": false,
|
|
156
|
+
"docs": {
|
|
157
|
+
"tags": [],
|
|
158
|
+
"text": "total files"
|
|
159
|
+
},
|
|
160
|
+
"attribute": "total",
|
|
161
|
+
"reflect": false,
|
|
162
|
+
"defaultValue": "undefined"
|
|
163
|
+
},
|
|
164
|
+
"invalid": {
|
|
165
|
+
"type": "number",
|
|
166
|
+
"mutable": false,
|
|
167
|
+
"complexType": {
|
|
168
|
+
"original": "number",
|
|
169
|
+
"resolved": "number",
|
|
170
|
+
"references": {}
|
|
171
|
+
},
|
|
172
|
+
"required": false,
|
|
173
|
+
"optional": false,
|
|
174
|
+
"docs": {
|
|
175
|
+
"tags": [],
|
|
176
|
+
"text": "invalid file amount"
|
|
177
|
+
},
|
|
178
|
+
"attribute": "invalid",
|
|
179
|
+
"reflect": false,
|
|
180
|
+
"defaultValue": "undefined"
|
|
181
|
+
},
|
|
182
|
+
"inprogress": {
|
|
183
|
+
"type": "number",
|
|
184
|
+
"mutable": false,
|
|
185
|
+
"complexType": {
|
|
186
|
+
"original": "number",
|
|
187
|
+
"resolved": "number",
|
|
188
|
+
"references": {}
|
|
189
|
+
},
|
|
190
|
+
"required": false,
|
|
191
|
+
"optional": false,
|
|
192
|
+
"docs": {
|
|
193
|
+
"tags": [],
|
|
194
|
+
"text": "valid file amount"
|
|
195
|
+
},
|
|
196
|
+
"attribute": "inprogress",
|
|
197
|
+
"reflect": false,
|
|
198
|
+
"defaultValue": "undefined"
|
|
199
|
+
}
|
|
200
|
+
}; }
|
|
201
|
+
static get states() { return {
|
|
202
|
+
"statusMessage": {}
|
|
203
|
+
}; }
|
|
204
|
+
static get watchers() { return [{
|
|
205
|
+
"propName": "valid",
|
|
206
|
+
"methodName": "watchHandler"
|
|
207
|
+
}, {
|
|
208
|
+
"propName": "invalid",
|
|
209
|
+
"methodName": "watchHandler"
|
|
210
|
+
}, {
|
|
211
|
+
"propName": "inprogress",
|
|
212
|
+
"methodName": "watchHandler"
|
|
213
|
+
}, {
|
|
214
|
+
"propName": "total",
|
|
215
|
+
"methodName": "watchHandler"
|
|
216
|
+
}]; }
|
|
217
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Built with Duet Design System
|
|
3
|
+
*/
|
|
4
|
+
import { h } from "@stencil/core";
|
|
5
|
+
import { getI18nError } from "./errorcodes.utils";
|
|
6
|
+
export const ErrorItem = ({ data }) => {
|
|
7
|
+
const { item, error } = data;
|
|
8
|
+
const { name } = item;
|
|
9
|
+
const { type } = error;
|
|
10
|
+
return (h("span", { class: "duet-upload-item-error", role: "status" },
|
|
11
|
+
h("duet-paragraph", { class: "duet-upload-item-name", color: "danger", margin: "none", weight: "semi-bold" },
|
|
12
|
+
h("duet-icon", { margin: "none", size: "xx-small", name: "messaging-attachment" }),
|
|
13
|
+
" ",
|
|
14
|
+
name),
|
|
15
|
+
h("duet-paragraph", { class: "duet-upload-item-error-label", size: "small", margin: "none", color: "danger" }, getI18nError(type))));
|
|
16
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Built with Duet Design System
|
|
3
|
+
*/
|
|
4
|
+
import { h } from "@stencil/core";
|
|
5
|
+
export const ProgressItem = ({ progress, name }) => (h("span", null,
|
|
6
|
+
h("duet-paragraph", { color: "secondary", margin: "none", size: "small" }, name),
|
|
7
|
+
h("duet-spacer", { size: "xx-small" }),
|
|
8
|
+
h("duet-progress", { progress: Math.ceil(progress), "aria-hidden": true })));
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Built with Duet Design System
|
|
3
|
+
*/
|
|
4
|
+
import { h } from "@stencil/core";
|
|
5
|
+
import { formatBytes } from "./upload.helpers";
|
|
6
|
+
export const SuccessItem = ({ data, showLinks }) => {
|
|
7
|
+
const { item, size, uploaded, url, meta } = data;
|
|
8
|
+
const { name } = item;
|
|
9
|
+
const ContentName = (h("span", { class: "duet-upload-item-name" },
|
|
10
|
+
h("duet-icon", { margin: "none", size: "xx-small", name: "messaging-attachment" }),
|
|
11
|
+
h("duet-spacer", { size: "xx-small", direction: "horizontal" }),
|
|
12
|
+
name));
|
|
13
|
+
const SizeText = (h("span", { class: "duet-upload-item-size", style: { fontSize: "14px", fontWeight: "400" } },
|
|
14
|
+
"(",
|
|
15
|
+
formatBytes(size),
|
|
16
|
+
")"));
|
|
17
|
+
const FilenameLine = uploaded && url && showLinks ? (h("duet-paragraph", { color: "secondary", margin: "none", weight: "semi-bold" },
|
|
18
|
+
h("duet-link", { url: url, external: true }, ContentName),
|
|
19
|
+
h("duet-spacer", { size: "xx-small", direction: "horizontal" }),
|
|
20
|
+
SizeText)) : (h("duet-paragraph", { color: "secondary", margin: "none", weight: "semi-bold" },
|
|
21
|
+
ContentName,
|
|
22
|
+
h("duet-spacer", { size: "xx-small", direction: "horizontal" }),
|
|
23
|
+
SizeText));
|
|
24
|
+
const Badges = meta && meta.badges ? (h("span", null,
|
|
25
|
+
h("duet-spacer", { size: "xx-small" }),
|
|
26
|
+
meta.badges.map(badgeText => (h("duet-badge", { color: "primary" }, badgeText))))) : undefined;
|
|
27
|
+
return (h("span", { class: "duet-upload-item-success" },
|
|
28
|
+
h("div", null, FilenameLine),
|
|
29
|
+
Badges));
|
|
30
|
+
};
|