@duetds/components 5.1.4 → 5.1.7
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 +132 -27
- package/lib/cjs/duet-action-button.cjs.entry.js +16 -5
- package/lib/cjs/duet-alert.cjs.entry.js +1 -1
- package/lib/cjs/duet-badge.cjs.entry.js +1 -1
- package/lib/cjs/duet-breadcrumb.cjs.entry.js +1 -1
- package/lib/cjs/duet-breadcrumbs.cjs.entry.js +1 -1
- package/lib/cjs/duet-button_2.cjs.entry.js +2 -2
- package/lib/cjs/duet-caption_4.cjs.entry.js +2 -2
- package/lib/cjs/duet-card.cjs.entry.js +2 -2
- package/lib/cjs/duet-checkbox.cjs.entry.js +1 -1
- package/lib/cjs/duet-choice_2.cjs.entry.js +2 -2
- package/lib/cjs/duet-collapsible.cjs.entry.js +1 -1
- package/lib/cjs/duet-combobox.cjs.entry.js +1 -1
- package/lib/cjs/duet-cookie-consent.cjs.entry.js +1 -1
- package/lib/cjs/duet-date-picker.cjs.entry.js +2 -2
- package/lib/cjs/duet-divider_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-editable-table_3.cjs.entry.js +104 -26
- package/lib/cjs/duet-empty-state.cjs.entry.js +1 -1
- package/lib/cjs/duet-fieldset.cjs.entry.js +1 -1
- package/lib/cjs/duet-footer.cjs.entry.js +1 -1
- package/lib/cjs/duet-grid_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-header_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-hero.cjs.entry.js +1 -1
- package/lib/cjs/duet-icon.cjs.entry.js +2 -2
- package/lib/cjs/duet-input_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-layout.cjs.entry.js +1 -1
- package/lib/cjs/duet-list_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-modal.cjs.entry.js +2 -2
- package/lib/cjs/duet-notification_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-number-input.cjs.entry.js +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 +1 -1
- package/lib/cjs/duet-scrollable_3.cjs.entry.js +1 -1
- package/lib/cjs/duet-select.cjs.entry.js +1 -1
- package/lib/cjs/duet-step_2.cjs.entry.js +1 -1
- package/lib/cjs/duet-textarea.cjs.entry.js +1 -1
- package/lib/cjs/duet-toggle.cjs.entry.js +1 -1
- package/lib/cjs/duet-tooltip.cjs.entry.js +1 -1
- package/lib/cjs/duet-tray.cjs.entry.js +1 -1
- package/lib/cjs/duet-upload-aria-status.cjs.entry.js +1 -1
- package/lib/cjs/duet-visually-hidden.cjs.entry.js +1 -1
- package/lib/cjs/duet.cjs.js +2 -2
- package/lib/cjs/{focus-utils-9ac6d246.js → focus-utils-dacb5c04.js} +1 -1
- package/lib/cjs/{index-c417c983.js → index-3c28214c.js} +1 -1
- package/lib/cjs/loader.cjs.js +2 -2
- package/lib/cjs/{token-utils-d1f8069b.js → token-utils-50a1f7e2.js} +15 -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-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 +133 -30
- package/lib/duet/duet.esm.js +1 -1
- package/lib/duet/duet.js +1 -1
- package/lib/duet/{p-29b73b1b.system.entry.js → p-007e7fd1.system.entry.js} +1 -1
- package/lib/duet/{p-e2074848.system.js → p-017e5a08.system.js} +1 -1
- package/lib/duet/{p-f8b1afeb.system.entry.js → p-019b0bda.system.entry.js} +1 -1
- package/lib/duet/{p-1e5f2840.entry.js → p-030290f4.entry.js} +1 -1
- package/lib/duet/{p-9c9947a8.entry.js → p-038eebd9.entry.js} +1 -1
- package/lib/duet/{p-f597ccbb.system.entry.js → p-0e0d40ae.system.entry.js} +1 -1
- package/lib/duet/{p-3474c348.entry.js → p-0e22e052.entry.js} +1 -1
- package/lib/duet/{p-a980e270.system.entry.js → p-0f2a1f01.system.entry.js} +1 -1
- package/lib/duet/{p-e6aa9737.entry.js → p-1ab0849a.entry.js} +1 -1
- package/lib/duet/{p-460e6137.system.entry.js → p-1b6e8581.system.entry.js} +1 -1
- package/lib/duet/{p-ec1797d8.entry.js → p-20220d27.entry.js} +1 -1
- package/lib/duet/{p-b8e8a024.entry.js → p-25f6c176.entry.js} +1 -1
- package/lib/duet/{p-f2f17151.system.entry.js → p-26798bd0.system.entry.js} +1 -1
- package/lib/duet/{p-b1039960.system.entry.js → p-2c6cd4a3.system.entry.js} +1 -1
- package/lib/duet/{p-99187a3a.system.js → p-31313016.system.js} +1 -1
- package/lib/duet/p-35820b00.entry.js +4 -0
- package/lib/duet/{p-be6e164e.system.entry.js → p-35c9a248.system.entry.js} +1 -1
- package/lib/duet/{p-553366aa.entry.js → p-3638aa71.entry.js} +1 -1
- package/lib/duet/{p-20c86cc5.system.entry.js → p-377ab392.system.entry.js} +1 -1
- package/lib/duet/{p-2fd66459.entry.js → p-39d463ef.entry.js} +1 -1
- package/lib/duet/{p-37217e63.entry.js → p-3bfe748f.entry.js} +1 -1
- package/lib/duet/{p-0356ed8e.entry.js → p-3c51c1b0.entry.js} +1 -1
- package/lib/duet/{p-47053a5e.entry.js → p-3df27412.entry.js} +1 -1
- package/lib/duet/{p-4d95a973.entry.js → p-3f319ed0.entry.js} +1 -1
- package/lib/duet/{p-18d04f2e.system.entry.js → p-3f3fa7a0.system.entry.js} +1 -1
- package/lib/duet/{p-b78ab2f5.system.js → p-485ace7b.system.js} +1 -1
- package/lib/duet/p-4d2dbe9e.js +4 -0
- package/lib/duet/{p-2e959285.system.entry.js → p-5670d324.system.entry.js} +1 -1
- package/lib/duet/{p-e0e35d41.js → p-5cf3316c.js} +1 -1
- package/lib/duet/{p-0e2e056f.system.entry.js → p-5f0ed156.system.entry.js} +1 -1
- package/lib/duet/p-5fcd9397.system.entry.js +4 -0
- package/lib/duet/{p-4c74be13.system.entry.js → p-60d00e2c.system.entry.js} +1 -1
- package/lib/duet/p-6190e2d6.system.js +4 -0
- package/lib/duet/{p-3956c0b8.system.entry.js → p-63a69534.system.entry.js} +1 -1
- package/lib/duet/{p-78ccd8fa.entry.js → p-6429b742.entry.js} +1 -1
- package/lib/duet/{p-e7f60c95.system.entry.js → p-67f357aa.system.entry.js} +1 -1
- package/lib/duet/{p-71d151e6.entry.js → p-6dcbf41c.entry.js} +1 -1
- package/lib/duet/{p-9bf95a5d.entry.js → p-70ac68bd.entry.js} +1 -1
- package/lib/duet/{p-d4d7c619.entry.js → p-72f1bbf5.entry.js} +1 -1
- package/lib/duet/{p-ec06dc8c.system.entry.js → p-75c4b4b0.system.entry.js} +1 -1
- package/lib/duet/{p-b1375931.entry.js → p-765605cb.entry.js} +1 -1
- package/lib/duet/p-79460e68.system.entry.js +4 -0
- package/lib/duet/{p-78d2dfc8.system.entry.js → p-79626865.system.entry.js} +1 -1
- package/lib/duet/{p-4dace9be.system.entry.js → p-7b11807c.system.entry.js} +1 -1
- package/lib/duet/{p-bd8c5946.entry.js → p-7f39ca93.entry.js} +1 -1
- package/lib/duet/{p-30371492.entry.js → p-7fb73896.entry.js} +1 -1
- package/lib/duet/{p-9ce054f9.system.entry.js → p-7fbd5a6f.system.entry.js} +1 -1
- package/lib/duet/p-861046b1.entry.js +4 -0
- package/lib/duet/{p-445d538d.entry.js → p-8a7d3c68.entry.js} +1 -1
- package/lib/duet/{p-3f4ea241.entry.js → p-8cc88eaf.entry.js} +1 -1
- package/lib/duet/{p-4a1a4d2d.system.entry.js → p-8dcd021f.system.entry.js} +1 -1
- package/lib/duet/{p-f650fa99.entry.js → p-8e520b00.entry.js} +1 -1
- package/lib/duet/{p-2aeb9bd2.system.entry.js → p-8f436ae6.system.entry.js} +1 -1
- package/lib/duet/{p-212f7cf5.entry.js → p-9187e214.entry.js} +1 -1
- package/lib/duet/{p-37a36786.entry.js → p-93bcf12a.entry.js} +1 -1
- package/lib/duet/{p-4df9144d.system.entry.js → p-988f0b81.system.entry.js} +1 -1
- package/lib/duet/{p-8a684ac7.system.entry.js → p-99796362.system.entry.js} +1 -1
- package/lib/duet/p-9cca0bb4.js +4 -0
- package/lib/duet/{p-e6eb55cf.system.entry.js → p-9cd00e15.system.entry.js} +1 -1
- package/lib/duet/{p-4bbd7a9c.entry.js → p-9d275136.entry.js} +1 -1
- package/lib/duet/{p-24f41cb3.system.entry.js → p-9ee12daa.system.entry.js} +1 -1
- package/lib/duet/{p-e8340671.entry.js → p-a2a63b2b.entry.js} +1 -1
- package/lib/duet/{p-9f3c3af5.system.entry.js → p-a37dcf98.system.entry.js} +1 -1
- package/lib/duet/{p-6144a827.system.entry.js → p-a447685e.system.entry.js} +1 -1
- package/lib/duet/{p-b49f89cf.system.entry.js → p-a7ba18b5.system.entry.js} +1 -1
- package/lib/duet/{p-f4943cc5.system.entry.js → p-b10db43a.system.entry.js} +1 -1
- package/lib/duet/{p-b6e0ea1d.entry.js → p-b48329a9.entry.js} +1 -1
- package/lib/duet/{p-ab84084f.entry.js → p-ba583a54.entry.js} +1 -1
- package/lib/duet/{p-472da63a.system.entry.js → p-ba66186c.system.entry.js} +1 -1
- package/lib/duet/{p-89042509.system.entry.js → p-baab37cb.system.entry.js} +1 -1
- package/lib/duet/{p-efeac1a1.entry.js → p-bb544c8e.entry.js} +1 -1
- package/lib/duet/{p-2000ef23.entry.js → p-c54340fd.entry.js} +1 -1
- package/lib/duet/{p-078fcf7c.system.entry.js → p-c6c7b718.system.entry.js} +1 -1
- package/lib/duet/{p-b2dfc5bd.system.entry.js → p-c8e5372d.system.entry.js} +1 -1
- package/lib/duet/{p-7af28ef6.entry.js → p-ce511dc5.entry.js} +1 -1
- package/lib/duet/{p-1862208a.system.entry.js → p-cee7aad6.system.entry.js} +1 -1
- package/lib/duet/p-d44434a8.entry.js +4 -0
- package/lib/duet/{p-87900286.entry.js → p-d9cf279a.entry.js} +1 -1
- package/lib/duet/{p-e15afaf5.system.entry.js → p-dff4f263.system.entry.js} +1 -1
- package/lib/duet/{p-8fa8bdab.system.entry.js → p-e4be787a.system.entry.js} +1 -1
- package/lib/duet/{p-64611b86.entry.js → p-e53e48a8.entry.js} +1 -1
- package/lib/duet/{p-24c8d0df.entry.js → p-e934f859.entry.js} +1 -1
- package/lib/duet/{p-85e8d34e.system.entry.js → p-ebc74446.system.entry.js} +1 -1
- package/lib/duet/{p-ecf2860f.entry.js → p-f230db10.entry.js} +1 -1
- package/lib/duet/{p-9903055f.system.entry.js → p-f4526da3.system.entry.js} +1 -1
- package/lib/duet/{p-bf95adc2.entry.js → p-f4e58e80.entry.js} +1 -1
- package/lib/duet/{p-9d681426.system.entry.js → p-fa551382.system.entry.js} +1 -1
- package/lib/duet/{p-4ae75bd5.entry.js → p-fa7e8f3a.entry.js} +1 -1
- package/lib/duet/{p-b7e592bf.entry.js → p-fe1ea738.entry.js} +1 -1
- package/lib/duet/{p-4cab1ba4.system.entry.js → p-ff8b4019.system.entry.js} +1 -1
- package/lib/duet/{p-6440fa65.entry.js → p-ffd8fc7d.entry.js} +1 -1
- package/lib/esm/duet-action-button.entry.js +16 -5
- package/lib/esm/duet-alert.entry.js +1 -1
- package/lib/esm/duet-badge.entry.js +1 -1
- package/lib/esm/duet-breadcrumb.entry.js +1 -1
- package/lib/esm/duet-breadcrumbs.entry.js +1 -1
- package/lib/esm/duet-button_2.entry.js +2 -2
- package/lib/esm/duet-caption_4.entry.js +2 -2
- package/lib/esm/duet-card.entry.js +2 -2
- package/lib/esm/duet-checkbox.entry.js +1 -1
- package/lib/esm/duet-choice_2.entry.js +2 -2
- package/lib/esm/duet-collapsible.entry.js +1 -1
- package/lib/esm/duet-combobox.entry.js +1 -1
- package/lib/esm/duet-cookie-consent.entry.js +1 -1
- package/lib/esm/duet-date-picker.entry.js +2 -2
- package/lib/esm/duet-divider_2.entry.js +1 -1
- package/lib/esm/duet-editable-table_3.entry.js +104 -26
- package/lib/esm/duet-empty-state.entry.js +1 -1
- package/lib/esm/duet-fieldset.entry.js +1 -1
- package/lib/esm/duet-footer.entry.js +1 -1
- package/lib/esm/duet-grid_2.entry.js +1 -1
- package/lib/esm/duet-header_2.entry.js +1 -1
- package/lib/esm/duet-hero.entry.js +1 -1
- package/lib/esm/duet-icon.entry.js +2 -2
- package/lib/esm/duet-input_2.entry.js +1 -1
- package/lib/esm/duet-layout.entry.js +1 -1
- package/lib/esm/duet-list_2.entry.js +1 -1
- package/lib/esm/duet-modal.entry.js +2 -2
- package/lib/esm/duet-notification_2.entry.js +1 -1
- package/lib/esm/duet-number-input.entry.js +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 +1 -1
- package/lib/esm/duet-scrollable_3.entry.js +1 -1
- package/lib/esm/duet-select.entry.js +1 -1
- package/lib/esm/duet-step_2.entry.js +1 -1
- package/lib/esm/duet-textarea.entry.js +1 -1
- package/lib/esm/duet-toggle.entry.js +1 -1
- package/lib/esm/duet-tooltip.entry.js +1 -1
- package/lib/esm/duet-tray.entry.js +1 -1
- package/lib/esm/duet-upload-aria-status.entry.js +1 -1
- package/lib/esm/duet-visually-hidden.entry.js +1 -1
- package/lib/esm/duet.js +2 -2
- package/lib/esm/{focus-utils-bcb5b759.js → focus-utils-00743137.js} +1 -1
- package/lib/esm/{index-7dc1fa94.js → index-ef96b4ca.js} +1 -1
- package/lib/esm/loader.js +2 -2
- package/lib/esm/{token-utils-f3b5f7a8.js → token-utils-1f9435bc.js} +15 -1
- package/lib/esm-es5/duet-action-button.entry.js +1 -1
- package/lib/esm-es5/duet-alert.entry.js +1 -1
- package/lib/esm-es5/duet-badge.entry.js +1 -1
- package/lib/esm-es5/duet-breadcrumb.entry.js +1 -1
- package/lib/esm-es5/duet-breadcrumbs.entry.js +1 -1
- package/lib/esm-es5/duet-button_2.entry.js +1 -1
- package/lib/esm-es5/duet-caption_4.entry.js +1 -1
- package/lib/esm-es5/duet-card.entry.js +1 -1
- package/lib/esm-es5/duet-checkbox.entry.js +1 -1
- package/lib/esm-es5/duet-choice_2.entry.js +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 +1 -1
- package/lib/esm-es5/duet-grid_2.entry.js +1 -1
- package/lib/esm-es5/duet-header_2.entry.js +1 -1
- package/lib/esm-es5/duet-hero.entry.js +1 -1
- package/lib/esm-es5/duet-icon.entry.js +1 -1
- package/lib/esm-es5/duet-input_2.entry.js +1 -1
- package/lib/esm-es5/duet-layout.entry.js +1 -1
- package/lib/esm-es5/duet-list_2.entry.js +1 -1
- package/lib/esm-es5/duet-modal.entry.js +1 -1
- package/lib/esm-es5/duet-notification_2.entry.js +1 -1
- package/lib/esm-es5/duet-number-input.entry.js +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 +1 -1
- package/lib/esm-es5/duet-textarea.entry.js +1 -1
- package/lib/esm-es5/duet-toggle.entry.js +1 -1
- package/lib/esm-es5/duet-tooltip.entry.js +1 -1
- package/lib/esm-es5/duet-tray.entry.js +1 -1
- package/lib/esm-es5/duet-upload-aria-status.entry.js +1 -1
- package/lib/esm-es5/duet-visually-hidden.entry.js +1 -1
- package/lib/esm-es5/duet.js +1 -1
- package/lib/esm-es5/focus-utils-00743137.js +4 -0
- package/lib/esm-es5/{index-7dc1fa94.js → index-ef96b4ca.js} +1 -1
- package/lib/esm-es5/loader.js +1 -1
- package/lib/esm-es5/token-utils-1f9435bc.js +4 -0
- package/lib/html.html-data.json +7 -3
- 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 +14 -2
- package/lib/types/utils/token-utils.d.ts +1 -0
- package/package.json +5 -5
- package/lib/duet/p-32774c23.system.entry.js +0 -4
- package/lib/duet/p-41e4f10e.entry.js +0 -4
- package/lib/duet/p-50363944.js +0 -4
- package/lib/duet/p-5ff75ab0.entry.js +0 -4
- package/lib/duet/p-7212c87c.entry.js +0 -4
- package/lib/duet/p-81ccf6d6.system.entry.js +0 -4
- package/lib/duet/p-9eaccbf3.system.js +0 -4
- package/lib/duet/p-e918a990.js +0 -4
- package/lib/esm-es5/focus-utils-bcb5b759.js +0 -4
- package/lib/esm-es5/token-utils-f3b5f7a8.js +0 -4
package/hydrate/index.js
CHANGED
|
@@ -6145,8 +6145,22 @@ function convertToColorName(name = "", theme = "") {
|
|
|
6145
6145
|
colorResolution = lowerCaseFirst(colorResolution);
|
|
6146
6146
|
return colorResolution;
|
|
6147
6147
|
}
|
|
6148
|
+
function shadeRGBColor(color, percent) {
|
|
6149
|
+
const f = color.split(","), t = percent < 0 ? 0 : 255, p = percent < 0 ? percent * -1 : percent;
|
|
6150
|
+
let R = parseInt(f[0].slice(4)), G = parseInt(f[1]), B = parseInt(f[2]);
|
|
6151
|
+
R = Math.round((t - R) * p) + R;
|
|
6152
|
+
G = Math.round((t - G) * p) + G;
|
|
6153
|
+
B = Math.round((t - B) * p) + B;
|
|
6154
|
+
R = R < 0 ? 0 : R;
|
|
6155
|
+
R = R > 255 ? 255 : R;
|
|
6156
|
+
G = G < 0 ? 0 : G;
|
|
6157
|
+
G = G > 255 ? 255 : G;
|
|
6158
|
+
B = B < 0 ? 0 : B;
|
|
6159
|
+
B = B > 255 ? 255 : B;
|
|
6160
|
+
return `rgb(${R},${G},${B})`;
|
|
6161
|
+
}
|
|
6148
6162
|
|
|
6149
|
-
const duetActionButtonCss = "/*!@*,\n*::after,\n*::before*/*.sc-duet-action-button,*.sc-duet-action-button::after,*.sc-duet-action-button::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}/*!@:host*/.sc-duet-action-button-h{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:inline-block;margin:0 auto}/*!@button.duet-action-button*/button.duet-action-button.sc-duet-action-button{white-space:nowrap}/*!@button.duet-action-button*/button.duet-action-button.sc-duet-action-button{display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;min-height:auto !important;padding:0 !important;margin:0 0 0 8px !important;color:#00294d;cursor:pointer;background:#f5f8fa;border-radius:50%;transition:background-color 300ms ease !important}/*!@.duet-theme-turva button.duet-action-button*/.duet-theme-turva.sc-duet-action-button button.duet-action-button.sc-duet-action-button{color:#171c3a;background:#f5f5f7}/*!@button.duet-action-button duet-icon*/button.duet-action-button.sc-duet-action-button duet-icon.sc-duet-action-button{display:block}@media (max-width: 35.9375em){/*!@button.duet-action-button*/button.duet-action-button.sc-duet-action-button{width:32px;height:32px}}/*!@button.duet-action-button:not(:disabled):hover*/button.duet-action-button.sc-duet-action-button:not(:disabled):hover{background:#e9ecee
|
|
6163
|
+
const duetActionButtonCss = "/*!@*,\n*::after,\n*::before*/*.sc-duet-action-button,*.sc-duet-action-button::after,*.sc-duet-action-button::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}/*!@:host*/.sc-duet-action-button-h{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:inline-block;margin:0 auto}/*!@button.duet-action-button*/button.duet-action-button.sc-duet-action-button{white-space:nowrap}/*!@button.duet-action-button*/button.duet-action-button.sc-duet-action-button{display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;min-height:auto !important;padding:0 !important;margin:0 0 0 8px !important;color:#00294d;cursor:pointer;background:#f5f8fa;border-radius:50%;transition:background-color 300ms ease !important}/*!@.duet-theme-turva button.duet-action-button*/.duet-theme-turva.sc-duet-action-button button.duet-action-button.sc-duet-action-button{color:#171c3a;background:#f5f5f7}/*!@button.duet-action-button duet-icon*/button.duet-action-button.sc-duet-action-button duet-icon.sc-duet-action-button{display:block}@media (max-width: 35.9375em){/*!@button.duet-action-button*/button.duet-action-button.sc-duet-action-button{width:32px;height:32px}}/*!@button.duet-action-button:not(:disabled):hover*/button.duet-action-button.sc-duet-action-button:not(:disabled):hover{background:#e9ecee}/*!@.duet-theme-turva button.duet-action-button:not(:disabled):hover*/.duet-theme-turva.sc-duet-action-button button.duet-action-button.sc-duet-action-button:not(:disabled):hover{background:#e9e9eb}/*!@button.duet-action-button:focus*/button.duet-action-button.sc-duet-action-button:focus{outline:0;box-shadow:0 0 0 2px #0077b3 !important}/*!@.duet-theme-turva button.duet-action-button:focus*/.duet-theme-turva.sc-duet-action-button button.duet-action-button.sc-duet-action-button:focus{box-shadow:0 0 0 2px #171c3a !important}/*!@button.duet-action-button:active:focus*/button.duet-action-button.sc-duet-action-button:active:focus{background:#dddfe1 !important;box-shadow:none}/*!@.duet-theme-turva button.duet-action-button:active:focus*/.duet-theme-turva.sc-duet-action-button button.duet-action-button.sc-duet-action-button:active:focus{background:#ddddde !important}/*!@button.duet-action-button:disabled*/button.duet-action-button.sc-duet-action-button:disabled{color:#909599;cursor:default;background:#f5f8fa;opacity:0.75}/*!@.duet-theme-turva button.duet-action-button:disabled*/.duet-theme-turva.sc-duet-action-button button.duet-action-button.sc-duet-action-button:disabled{color:#747475;background:#f5f5f7}";
|
|
6150
6164
|
|
|
6151
6165
|
/**
|
|
6152
6166
|
* Slot: default slot inside an invisible element, this can be used to enhance accessibility
|
|
@@ -6279,14 +6293,25 @@ class DuetActionButton {
|
|
|
6279
6293
|
*/
|
|
6280
6294
|
render() {
|
|
6281
6295
|
const color = this.color === "currentColor" ? "currentColor" : getColorByName(this.color, this.theme);
|
|
6296
|
+
const backgroundColor = getColorByName(this.background, this.theme);
|
|
6297
|
+
const backgroundHoverColor = backgroundColor ? shadeRGBColor(backgroundColor, -0.1) : backgroundColor;
|
|
6298
|
+
const backgroundStyles = backgroundColor
|
|
6299
|
+
? `
|
|
6300
|
+
button.duet-action-button {
|
|
6301
|
+
background: ${backgroundColor} !important;
|
|
6302
|
+
}
|
|
6303
|
+
button.duet-action-button:not(:disabled):hover {
|
|
6304
|
+
background: ${backgroundHoverColor} !important;
|
|
6305
|
+
}
|
|
6306
|
+
`
|
|
6307
|
+
: "";
|
|
6282
6308
|
const styles = {
|
|
6283
6309
|
color,
|
|
6284
|
-
background: getColorByName(this.background, this.theme),
|
|
6285
6310
|
"border-color": getColorByName(this.iconColor, this.theme),
|
|
6286
6311
|
"border-width": "1px",
|
|
6287
6312
|
"border-style": "solid",
|
|
6288
6313
|
};
|
|
6289
|
-
return (hAsync(Host, { onKeyDown: e => this.onKeyboardDown(e) }, hAsync("button", { part: "button", style: styles, disabled: this.disabled, id: this.listId, class: {
|
|
6314
|
+
return (hAsync(Host, { onKeyDown: e => this.onKeyboardDown(e) }, hAsync("style", { innerHTML: backgroundStyles }), hAsync("button", { part: "button", style: styles, disabled: this.disabled, id: this.listId, class: {
|
|
6290
6315
|
"duet-action-button": true,
|
|
6291
6316
|
"duet-action-button--disabled": this.disabled,
|
|
6292
6317
|
[`duet-action-button--${this.theme}`]: this.theme !== "",
|
|
@@ -16863,6 +16888,10 @@ const ProgressItem = ({ progress, name }) => (hAsync("span", null,
|
|
|
16863
16888
|
hAsync("duet-spacer", { size: "xx-small" }),
|
|
16864
16889
|
hAsync("duet-progress", { progress: Math.ceil(progress), "aria-hidden": true })));
|
|
16865
16890
|
|
|
16891
|
+
const PendingItem = ({ name }) => (hAsync("span", null,
|
|
16892
|
+
hAsync("duet-paragraph", { color: "secondary", margin: "none", size: "small" }, name),
|
|
16893
|
+
hAsync("duet-spacer", { size: "xx-small" })));
|
|
16894
|
+
|
|
16866
16895
|
const formatBytes = (bytes, decimals = 2) => {
|
|
16867
16896
|
if (bytes === 0) {
|
|
16868
16897
|
return "0 Bytes";
|
|
@@ -17048,9 +17077,13 @@ class DuetUpload {
|
|
|
17048
17077
|
* it will be up to you to handle the upload and return progress information to the upload-component
|
|
17049
17078
|
*/
|
|
17050
17079
|
this.external = false;
|
|
17080
|
+
/**
|
|
17081
|
+
* If defer-upload is true, duet-upload will not (as recommended) instantly upload files but await a call to uploadPending()
|
|
17082
|
+
*/
|
|
17083
|
+
this.deferUpload = false;
|
|
17051
17084
|
/**
|
|
17052
17085
|
* If set the upload component will not display an upload button, you will have to create one yourself
|
|
17053
|
-
* and call the exposed method startUpload
|
|
17086
|
+
* and call the exposed method startUpload to open the upload dialog
|
|
17054
17087
|
*/
|
|
17055
17088
|
this.hideButton = false;
|
|
17056
17089
|
/**
|
|
@@ -17063,7 +17096,7 @@ class DuetUpload {
|
|
|
17063
17096
|
size: "x-small",
|
|
17064
17097
|
background: "gray-lightest",
|
|
17065
17098
|
name: "delete",
|
|
17066
|
-
map: ["success", "failure"],
|
|
17099
|
+
map: ["success", "failure", "pending"],
|
|
17067
17100
|
label: {
|
|
17068
17101
|
fi: "Poista tiedosto",
|
|
17069
17102
|
en: "Poista tiedosto",
|
|
@@ -17317,6 +17350,7 @@ class DuetUpload {
|
|
|
17317
17350
|
this.DefaultGroups = {
|
|
17318
17351
|
inprogress: "inprogress",
|
|
17319
17352
|
success: "success",
|
|
17353
|
+
pending: "pending",
|
|
17320
17354
|
failure: "failure",
|
|
17321
17355
|
};
|
|
17322
17356
|
/**
|
|
@@ -17333,6 +17367,14 @@ class DuetUpload {
|
|
|
17333
17367
|
en: "Files inprogress",
|
|
17334
17368
|
},
|
|
17335
17369
|
},
|
|
17370
|
+
{
|
|
17371
|
+
id: this.DefaultGroups.pending,
|
|
17372
|
+
label: {
|
|
17373
|
+
en: "Files to upload",
|
|
17374
|
+
sv: "Filer att ladda",
|
|
17375
|
+
fi: "Tiedostot ladattavat",
|
|
17376
|
+
},
|
|
17377
|
+
},
|
|
17336
17378
|
{
|
|
17337
17379
|
id: this.DefaultGroups.success,
|
|
17338
17380
|
label: {
|
|
@@ -17360,7 +17402,6 @@ class DuetUpload {
|
|
|
17360
17402
|
this.element.addEventListener("duetActionEvent", (e) => {
|
|
17361
17403
|
const detail = e.detail;
|
|
17362
17404
|
const { action, id, originalEvent } = detail;
|
|
17363
|
-
console.log(e);
|
|
17364
17405
|
switch (action) {
|
|
17365
17406
|
case "delete":
|
|
17366
17407
|
this.onDelete(id, originalEvent);
|
|
@@ -17388,9 +17429,6 @@ class DuetUpload {
|
|
|
17388
17429
|
if (item.valid && item.progress === 100) {
|
|
17389
17430
|
// if the item has a group, move the file to that group instead
|
|
17390
17431
|
// of into the standard success group
|
|
17391
|
-
if (item.group) {
|
|
17392
|
-
return item.group;
|
|
17393
|
-
}
|
|
17394
17432
|
return this.DefaultGroups.success;
|
|
17395
17433
|
}
|
|
17396
17434
|
else if (item.progress > 0 && item.progress !== 100) {
|
|
@@ -17399,6 +17437,9 @@ class DuetUpload {
|
|
|
17399
17437
|
else if (!item.valid) {
|
|
17400
17438
|
return this.DefaultGroups.failure;
|
|
17401
17439
|
}
|
|
17440
|
+
else if (item.pending) {
|
|
17441
|
+
return this.DefaultGroups.pending;
|
|
17442
|
+
}
|
|
17402
17443
|
else if (item.group) {
|
|
17403
17444
|
return item.group;
|
|
17404
17445
|
}
|
|
@@ -17413,6 +17454,9 @@ class DuetUpload {
|
|
|
17413
17454
|
else if (group === this.DefaultGroups.inprogress) {
|
|
17414
17455
|
return hAsync(ProgressItem, { progress: data.progress, name: data.item.name });
|
|
17415
17456
|
}
|
|
17457
|
+
else if (group === this.DefaultGroups.pending) {
|
|
17458
|
+
return hAsync(PendingItem, { name: data.item.name });
|
|
17459
|
+
}
|
|
17416
17460
|
else if (group === this.DefaultGroups.failure) {
|
|
17417
17461
|
return hAsync(ErrorItem, { data: data });
|
|
17418
17462
|
}
|
|
@@ -17425,9 +17469,16 @@ class DuetUpload {
|
|
|
17425
17469
|
};
|
|
17426
17470
|
this.genHashName = () => Date.now().toString(36) + Math.random();
|
|
17427
17471
|
this.updateValueInMap = (item, key, value, kick = true) => {
|
|
17428
|
-
|
|
17429
|
-
|
|
17430
|
-
|
|
17472
|
+
try {
|
|
17473
|
+
const fileItem = this.files.get(item);
|
|
17474
|
+
fileItem[key] = value;
|
|
17475
|
+
this.files.set(item, fileItem);
|
|
17476
|
+
}
|
|
17477
|
+
catch (e) {
|
|
17478
|
+
// if a users tries to update entries on a file that doesn't exist,
|
|
17479
|
+
// this will blow up - so we're swallowing the errors here on purpose
|
|
17480
|
+
// console.warn("operation on missing items")
|
|
17481
|
+
}
|
|
17431
17482
|
if (kick) {
|
|
17432
17483
|
this.kick();
|
|
17433
17484
|
}
|
|
@@ -17545,6 +17596,46 @@ class DuetUpload {
|
|
|
17545
17596
|
fileMaxReached: isTotalFileAmountAboveMax,
|
|
17546
17597
|
};
|
|
17547
17598
|
};
|
|
17599
|
+
this.uploadFile = async (fileListItem, force = false, key) => {
|
|
17600
|
+
if (!force && this.deferUpload) {
|
|
17601
|
+
this.updateValueInMap(fileListItem.item.name, "pending", true, false);
|
|
17602
|
+
this.updateValueInMap(fileListItem.item.name, "group", "pending", true);
|
|
17603
|
+
}
|
|
17604
|
+
else if (force) {
|
|
17605
|
+
this.updateValueInMap(fileListItem.item.name, "pending", false, false);
|
|
17606
|
+
this.updateValueInMap(fileListItem.item.name, "group", undefined, true);
|
|
17607
|
+
}
|
|
17608
|
+
try {
|
|
17609
|
+
if (!this.deferUpload || force) {
|
|
17610
|
+
// if all is well AND external file upload handling has not been set, start upload
|
|
17611
|
+
const data = new FormData();
|
|
17612
|
+
data.append("file", fileListItem.item);
|
|
17613
|
+
if (key) {
|
|
17614
|
+
data.append("key", key);
|
|
17615
|
+
}
|
|
17616
|
+
data.append("uid", fileListItem.uid);
|
|
17617
|
+
data.append("name", fileListItem.item.name);
|
|
17618
|
+
data.append("metadata", JSON.stringify({
|
|
17619
|
+
uid: fileListItem.uid,
|
|
17620
|
+
url: this.uri,
|
|
17621
|
+
size: fileListItem.item.size,
|
|
17622
|
+
meta: fileListItem.meta,
|
|
17623
|
+
}));
|
|
17624
|
+
fileListItem.xhr = await this.makeXHRPostRequest(data);
|
|
17625
|
+
}
|
|
17626
|
+
}
|
|
17627
|
+
catch (e) {
|
|
17628
|
+
// in case one of the global maxes have been reached, invalidate the file
|
|
17629
|
+
this.updateValueInMap(fileListItem.item.name, "valid", false, false);
|
|
17630
|
+
}
|
|
17631
|
+
};
|
|
17632
|
+
this.uploadPendingFiles = () => {
|
|
17633
|
+
for (const [key, value] of this.files.entries()) {
|
|
17634
|
+
if (value.group === "pending" && value.pending === true) {
|
|
17635
|
+
this.uploadFile(value, true, key);
|
|
17636
|
+
}
|
|
17637
|
+
}
|
|
17638
|
+
};
|
|
17548
17639
|
this.getItemFromUID = (uid) => {
|
|
17549
17640
|
for (const [key, value] of this.files.entries()) {
|
|
17550
17641
|
if (value.uid === uid) {
|
|
@@ -17554,7 +17645,8 @@ class DuetUpload {
|
|
|
17554
17645
|
return null;
|
|
17555
17646
|
};
|
|
17556
17647
|
this.onDelete = (key, ev) => {
|
|
17557
|
-
const
|
|
17648
|
+
const item = this.getItemFromUID(key);
|
|
17649
|
+
const retrievedKey = item.key;
|
|
17558
17650
|
const deletedItem = this.files.get(retrievedKey);
|
|
17559
17651
|
this.files.delete(retrievedKey);
|
|
17560
17652
|
this.validateTotals();
|
|
@@ -17564,7 +17656,8 @@ class DuetUpload {
|
|
|
17564
17656
|
data: { deletion: deletedItem },
|
|
17565
17657
|
component: "duet-upload",
|
|
17566
17658
|
});
|
|
17567
|
-
if
|
|
17659
|
+
// don't send a xhr request if the item was pending, just remove it from the list
|
|
17660
|
+
if (!this.external && !deletedItem.pending) {
|
|
17568
17661
|
this.makeXHRDeleteRequest(deletedItem);
|
|
17569
17662
|
}
|
|
17570
17663
|
this.resetFormFields();
|
|
@@ -17629,6 +17722,7 @@ class DuetUpload {
|
|
|
17629
17722
|
const all = [...this.files.values()];
|
|
17630
17723
|
const inprogress = [];
|
|
17631
17724
|
const failure = [];
|
|
17725
|
+
const pending = [];
|
|
17632
17726
|
const success = [];
|
|
17633
17727
|
all.forEach(data => {
|
|
17634
17728
|
const group = this.getGroupFromItemData(data);
|
|
@@ -17647,6 +17741,13 @@ class DuetUpload {
|
|
|
17647
17741
|
group,
|
|
17648
17742
|
});
|
|
17649
17743
|
}
|
|
17744
|
+
else if (group === this.DefaultGroups.pending) {
|
|
17745
|
+
pending.push({
|
|
17746
|
+
uid: data.uid,
|
|
17747
|
+
item,
|
|
17748
|
+
group,
|
|
17749
|
+
});
|
|
17750
|
+
}
|
|
17650
17751
|
else if (group === this.DefaultGroups.failure) {
|
|
17651
17752
|
failure.push({
|
|
17652
17753
|
uid: data.uid,
|
|
@@ -17664,6 +17765,7 @@ class DuetUpload {
|
|
|
17664
17765
|
});
|
|
17665
17766
|
return {
|
|
17666
17767
|
inprogress,
|
|
17768
|
+
pending,
|
|
17667
17769
|
failure,
|
|
17668
17770
|
success,
|
|
17669
17771
|
};
|
|
@@ -17737,6 +17839,12 @@ class DuetUpload {
|
|
|
17737
17839
|
this.nativeInput.click();
|
|
17738
17840
|
return;
|
|
17739
17841
|
}
|
|
17842
|
+
/**
|
|
17843
|
+
* Method for uploading pending files
|
|
17844
|
+
*/
|
|
17845
|
+
async uploadPending() {
|
|
17846
|
+
this.uploadPendingFiles();
|
|
17847
|
+
}
|
|
17740
17848
|
/**
|
|
17741
17849
|
* Method for forcing a render of the upload list, element.files can be changed externally
|
|
17742
17850
|
* But it will only rerender on a new Map or a top Level change - this can be used to update
|
|
@@ -17875,19 +17983,14 @@ class DuetUpload {
|
|
|
17875
17983
|
this.updateValueInMap(item.name, "valid", false, false);
|
|
17876
17984
|
}
|
|
17877
17985
|
else if (valid && !this.external) {
|
|
17878
|
-
|
|
17879
|
-
|
|
17880
|
-
|
|
17881
|
-
|
|
17882
|
-
|
|
17883
|
-
|
|
17884
|
-
|
|
17885
|
-
|
|
17886
|
-
}
|
|
17887
|
-
catch (e) {
|
|
17888
|
-
// in case one of the global maxes have been reached, invalidate the file
|
|
17889
|
-
this.updateValueInMap(item.name, "valid", false, false);
|
|
17890
|
-
}
|
|
17986
|
+
await this.uploadFile(fileListItem);
|
|
17987
|
+
}
|
|
17988
|
+
else if (valid && this.external) {
|
|
17989
|
+
this.updateValueInMap(fileListItem.item.name, "pending", true, false);
|
|
17990
|
+
this.updateValueInMap(fileListItem.item.name, "group", "pending", true);
|
|
17991
|
+
}
|
|
17992
|
+
else if (!valid) {
|
|
17993
|
+
this.updateValueInMap(item.name, "valid", false, true);
|
|
17891
17994
|
}
|
|
17892
17995
|
// kick the stat to force update
|
|
17893
17996
|
this.kick();
|
|
@@ -17917,6 +18020,7 @@ class DuetUpload {
|
|
|
17917
18020
|
"accessibleControls": [1, "accessible-controls"],
|
|
17918
18021
|
"accessibleOwns": [1, "accessible-owns"],
|
|
17919
18022
|
"external": [4],
|
|
18023
|
+
"deferUpload": [4, "defer-upload"],
|
|
17920
18024
|
"hideButton": [4, "hide-upload-button"],
|
|
17921
18025
|
"actions": [16],
|
|
17922
18026
|
"uri": [1],
|
|
@@ -17956,6 +18060,7 @@ class DuetUpload {
|
|
|
17956
18060
|
"tick": [32],
|
|
17957
18061
|
"setFocus": [64],
|
|
17958
18062
|
"upload": [64],
|
|
18063
|
+
"uploadPending": [64],
|
|
17959
18064
|
"refresh": [64],
|
|
17960
18065
|
"getFiles": [64],
|
|
17961
18066
|
"updateValue": [64]
|
|
@@ -5,17 +5,17 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const createId = require('./create-id-c3b984b1.js');
|
|
10
10
|
const jsUtils = require('./js-utils-be1d29ae.js');
|
|
11
11
|
const keyboardUtils = require('./keyboard-utils-bb32119b.js');
|
|
12
12
|
const languageUtils = require('./language-utils-4f62a7db.js');
|
|
13
13
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
14
|
-
const tokenUtils = require('./token-utils-
|
|
14
|
+
const tokenUtils = require('./token-utils-50a1f7e2.js');
|
|
15
15
|
require('./string-utils-5cadd058.js');
|
|
16
16
|
require('./tokens.module-ef598645.js');
|
|
17
17
|
|
|
18
|
-
const duetActionButtonCss = "*,*::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:inline-block;margin:0 auto}button.duet-action-button{white-space:nowrap}button.duet-action-button{display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;min-height:auto !important;padding:0 !important;margin:0 0 0 8px !important;color:#00294d;cursor:pointer;background:#f5f8fa;border-radius:50%;transition:background-color 300ms ease !important}.duet-theme-turva button.duet-action-button{color:#171c3a;background:#f5f5f7}button.duet-action-button duet-icon{display:block}@media (max-width: 35.9375em){button.duet-action-button{width:32px;height:32px}}button.duet-action-button:not(:disabled):hover{background:#e9ecee
|
|
18
|
+
const duetActionButtonCss = "*,*::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:inline-block;margin:0 auto}button.duet-action-button{white-space:nowrap}button.duet-action-button{display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;min-height:auto !important;padding:0 !important;margin:0 0 0 8px !important;color:#00294d;cursor:pointer;background:#f5f8fa;border-radius:50%;transition:background-color 300ms ease !important}.duet-theme-turva button.duet-action-button{color:#171c3a;background:#f5f5f7}button.duet-action-button duet-icon{display:block}@media (max-width: 35.9375em){button.duet-action-button{width:32px;height:32px}}button.duet-action-button:not(:disabled):hover{background:#e9ecee}.duet-theme-turva button.duet-action-button:not(:disabled):hover{background:#e9e9eb}button.duet-action-button:focus{outline:0;box-shadow:0 0 0 2px #0077b3 !important}.duet-theme-turva button.duet-action-button:focus{box-shadow:0 0 0 2px #171c3a !important}button.duet-action-button:active:focus{background:#dddfe1 !important;box-shadow:none}.duet-theme-turva button.duet-action-button:active:focus{background:#ddddde !important}button.duet-action-button:disabled{color:#909599;cursor:default;background:#f5f8fa;opacity:0.75}.duet-theme-turva button.duet-action-button:disabled{color:#747475;background:#f5f5f7}";
|
|
19
19
|
|
|
20
20
|
const DuetActionButton = class {
|
|
21
21
|
constructor(hostRef) {
|
|
@@ -143,14 +143,25 @@ const DuetActionButton = class {
|
|
|
143
143
|
*/
|
|
144
144
|
render() {
|
|
145
145
|
const color = this.color === "currentColor" ? "currentColor" : tokenUtils.getColorByName(this.color, this.theme);
|
|
146
|
+
const backgroundColor = tokenUtils.getColorByName(this.background, this.theme);
|
|
147
|
+
const backgroundHoverColor = backgroundColor ? tokenUtils.shadeRGBColor(backgroundColor, -0.1) : backgroundColor;
|
|
148
|
+
const backgroundStyles = backgroundColor
|
|
149
|
+
? `
|
|
150
|
+
button.duet-action-button {
|
|
151
|
+
background: ${backgroundColor} !important;
|
|
152
|
+
}
|
|
153
|
+
button.duet-action-button:not(:disabled):hover {
|
|
154
|
+
background: ${backgroundHoverColor} !important;
|
|
155
|
+
}
|
|
156
|
+
`
|
|
157
|
+
: "";
|
|
146
158
|
const styles = {
|
|
147
159
|
color,
|
|
148
|
-
background: tokenUtils.getColorByName(this.background, this.theme),
|
|
149
160
|
"border-color": tokenUtils.getColorByName(this.iconColor, this.theme),
|
|
150
161
|
"border-width": "1px",
|
|
151
162
|
"border-style": "solid",
|
|
152
163
|
};
|
|
153
|
-
return (index.h(index.Host, { onKeyDown: e => this.onKeyboardDown(e) }, index.h("button", { part: "button", style: styles, disabled: this.disabled, id: this.listId, class: {
|
|
164
|
+
return (index.h(index.Host, { onKeyDown: e => this.onKeyboardDown(e) }, index.h("style", { innerHTML: backgroundStyles }), index.h("button", { part: "button", style: styles, disabled: this.disabled, id: this.listId, class: {
|
|
154
165
|
"duet-action-button": true,
|
|
155
166
|
"duet-action-button--disabled": this.disabled,
|
|
156
167
|
[`duet-action-button--${this.theme}`]: this.theme !== "",
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const languageUtils = require('./language-utils-4f62a7db.js');
|
|
10
10
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
11
11
|
require('./string-utils-5cadd058.js');
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
10
10
|
|
|
11
11
|
const duetBadgeCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-right:4px !important;margin-bottom:2px !important;display:inline-block;width:auto;vertical-align:middle}:host:last-child,:host:last-of-type{margin-right:0 !important}:host(.duet-m-0){margin:0 !important}.duet-badge{width:100%;padding:4.4444444444px 12px 5.4444444444px;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:0.75rem;font-style:normal;font-weight:600;line-height:1.25;color:#00294d;text-align:center;word-break:break-word;vertical-align:middle;background:#e6f1f7;border-radius:20rem}.duet-badge.duet-p-0{padding:0 !important}.duet-badge.duet-m-0{margin:0 !important}.duet-badge.duet-theme-turva{padding:5.4444444444px 12px 4.4444444444px;font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-weight:700;color:#171c3a;background:#e8e8eb}.duet-badge.warning{background:#fef3df}.duet-badge.warning.duet-theme-turva{background:#fef1db}.duet-badge.danger{background:#fce9ef}.duet-badge.danger.duet-theme-turva{background:#fceae7}.duet-badge.success{background:#e6f3ef}.duet-badge.success.duet-theme-turva{background:#e6f3ed}";
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
10
10
|
|
|
11
11
|
const duetBreadcrumbCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:block;width:100%}.duet-breadcrumb{display:flex;flex-direction:row;align-items:center;justify-content:flex-start;height:100%;font-size:0.875rem;color:#00294d;text-decoration:none}.duet-breadcrumb:hover{color:#004d80}.duet-breadcrumb.duet-theme-turva{color:#171c3a}.duet-breadcrumb.duet-theme-turva:hover{color:#940925}.duet-breadcrumb:focus{outline:0}.duet-breadcrumb:active{opacity:0.75}:host(.user-is-tabbing) .duet-breadcrumb:focus{box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}:host(.user-is-tabbing) .duet-breadcrumb.duet-theme-turva:focus{box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}";
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const actionArrowRightSmall = require('./action-arrow-right-small-a25eb475.js');
|
|
10
10
|
const languageUtils = require('./language-utils-4f62a7db.js');
|
|
11
11
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
@@ -5,11 +5,11 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const commonStrings = require('./common-strings-de17f887.js');
|
|
10
10
|
const languageUtils = require('./language-utils-4f62a7db.js');
|
|
11
11
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
12
|
-
const tokenUtils = require('./token-utils-
|
|
12
|
+
const tokenUtils = require('./token-utils-50a1f7e2.js');
|
|
13
13
|
require('./string-utils-5cadd058.js');
|
|
14
14
|
require('./tokens.module-ef598645.js');
|
|
15
15
|
|
|
@@ -5,10 +5,10 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
10
10
|
const stringUtils = require('./string-utils-5cadd058.js');
|
|
11
|
-
const tokenUtils = require('./token-utils-
|
|
11
|
+
const tokenUtils = require('./token-utils-50a1f7e2.js');
|
|
12
12
|
const actionNewWindowSmall = require('./action-new-window-small-fa51dfb9.js');
|
|
13
13
|
const commonStrings = require('./common-strings-de17f887.js');
|
|
14
14
|
const languageUtils = require('./language-utils-4f62a7db.js');
|
|
@@ -5,12 +5,12 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const createId = require('./create-id-c3b984b1.js');
|
|
10
10
|
const keyboardUtils = require('./keyboard-utils-bb32119b.js');
|
|
11
11
|
const stringUtils = require('./string-utils-5cadd058.js');
|
|
12
12
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
13
|
-
const tokenUtils = require('./token-utils-
|
|
13
|
+
const tokenUtils = require('./token-utils-50a1f7e2.js');
|
|
14
14
|
require('./tokens.module-ef598645.js');
|
|
15
15
|
|
|
16
16
|
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>"};
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const createId = require('./create-id-c3b984b1.js');
|
|
10
10
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
11
11
|
|
|
@@ -5,10 +5,10 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const commonStrings = require('./common-strings-de17f887.js');
|
|
10
10
|
const createId = require('./create-id-c3b984b1.js');
|
|
11
|
-
const focusUtils = require('./focus-utils-
|
|
11
|
+
const focusUtils = require('./focus-utils-dacb5c04.js');
|
|
12
12
|
const keyboardUtils = require('./keyboard-utils-bb32119b.js');
|
|
13
13
|
const languageUtils = require('./language-utils-4f62a7db.js');
|
|
14
14
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const actionArrowDownSmall = require('./action-arrow-down-small-ef77a2d1.js');
|
|
10
10
|
const tokens = require('./tokens-29450bcb.js');
|
|
11
11
|
const createId = require('./create-id-c3b984b1.js');
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const jsUtils = require('./js-utils-be1d29ae.js');
|
|
10
10
|
const keyboardUtils = require('./keyboard-utils-bb32119b.js');
|
|
11
11
|
const languageUtils = require('./language-utils-4f62a7db.js');
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
10
10
|
|
|
11
11
|
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}";
|
|
@@ -5,9 +5,9 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const createId = require('./create-id-c3b984b1.js');
|
|
10
|
-
const focusUtils = require('./focus-utils-
|
|
10
|
+
const focusUtils = require('./focus-utils-dacb5c04.js');
|
|
11
11
|
const languageUtils = require('./language-utils-4f62a7db.js');
|
|
12
12
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
13
13
|
require('./string-utils-5cadd058.js');
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
7
7
|
|
|
8
|
-
const index = require('./index-
|
|
8
|
+
const index = require('./index-3c28214c.js');
|
|
9
9
|
const themeableComponent = require('./themeable-component-940d3b50.js');
|
|
10
10
|
|
|
11
11
|
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}";
|