@watermarkinsights/ripple 5.20.0 → 5.21.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{app-globals-c9940f6b.js → app-globals-84a1a262.js} +1 -1
- package/dist/cjs/{chartFunctions-ce91b2c9.js → chartFunctions-369d5c6e.js} +1 -1
- package/dist/cjs/{functions-ea3eae05.js → functions-505d6601.js} +106 -24
- package/dist/cjs/{intl-ea56dd40.js → intl-e7d7e719.js} +1 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/priv-calendar.cjs.entry.js +105 -84
- package/dist/cjs/priv-chart-popover.cjs.entry.js +1 -1
- package/dist/cjs/priv-navigator-button.cjs.entry.js +1 -1
- package/dist/cjs/priv-navigator-item.cjs.entry.js +1 -1
- package/dist/cjs/priv-option-list.cjs.entry.js +3 -3
- package/dist/cjs/ripple.cjs.js +2 -2
- package/dist/cjs/wm-action-menu_2.cjs.entry.js +3 -3
- package/dist/cjs/wm-button.cjs.entry.js +2 -2
- package/dist/cjs/wm-chart.cjs.entry.js +3 -3
- package/dist/cjs/wm-date-range.cjs.entry.js +1 -1
- package/dist/cjs/wm-datepicker.cjs.entry.js +1 -1
- package/dist/cjs/wm-file-list.cjs.entry.js +1 -1
- package/dist/cjs/wm-file.cjs.entry.js +2 -2
- package/dist/cjs/wm-flyout.cjs.entry.js +5 -4
- package/dist/cjs/wm-input.cjs.entry.js +3 -3
- package/dist/cjs/wm-line-chart.cjs.entry.js +3 -3
- package/dist/cjs/wm-modal-pss_3.cjs.entry.js +11 -8
- package/dist/cjs/wm-modal_3.cjs.entry.js +8 -7
- package/dist/cjs/wm-navigation_3.cjs.entry.js +8 -8
- package/dist/cjs/wm-navigator.cjs.entry.js +1 -1
- package/dist/cjs/wm-nested-select.cjs.entry.js +5 -5
- package/dist/cjs/wm-optgroup.cjs.entry.js +2 -2
- package/dist/cjs/wm-option_2.cjs.entry.js +7 -7
- package/dist/cjs/wm-pagination.cjs.entry.js +3 -3
- package/dist/cjs/wm-progress-indicator_3.cjs.entry.js +2 -2
- package/dist/cjs/wm-search.cjs.entry.js +4 -4
- package/dist/cjs/wm-snackbar.cjs.entry.js +4 -4
- package/dist/cjs/wm-tab-item_3.cjs.entry.js +7 -7
- package/dist/cjs/wm-tag-input.cjs.entry.js +4 -4
- package/dist/cjs/wm-tag-option.cjs.entry.js +1 -1
- package/dist/cjs/wm-textarea.cjs.entry.js +3 -3
- package/dist/cjs/wm-timepicker.cjs.entry.js +4 -4
- package/dist/cjs/wm-toggletip.cjs.entry.js +4 -4
- package/dist/cjs/wm-uploader.cjs.entry.js +32 -29
- package/dist/collection/components/datepickers/priv-calendar/priv-calendar.css +61 -35
- package/dist/collection/components/datepickers/priv-calendar/priv-calendar.js +106 -83
- package/dist/collection/components/selects/priv-option-list/priv-option-list.js +1 -1
- package/dist/collection/components/selects/wm-nested-select/wm-nested-select.js +3 -3
- package/dist/collection/components/selects/wm-optgroup/wm-optgroup.js +1 -1
- package/dist/collection/components/selects/wm-option/wm-option.js +1 -1
- package/dist/collection/components/selects/wm-select/wm-select.js +4 -4
- package/dist/collection/components/wm-action-menu/wm-action-menu.js +1 -1
- package/dist/collection/components/wm-button/wm-button.js +1 -1
- package/dist/collection/components/wm-file/wm-file.js +1 -1
- package/dist/collection/components/wm-file-list/wm-file-list.js +1 -1
- package/dist/collection/components/wm-flyout/wm-flyout.js +3 -2
- package/dist/collection/components/wm-input/wm-input.js +1 -1
- package/dist/collection/components/wm-menuitem/wm-menuitem.js +1 -1
- package/dist/collection/components/wm-modal/wm-modal-footer.js +1 -1
- package/dist/collection/components/wm-modal/wm-modal-header.js +1 -1
- package/dist/collection/components/wm-modal/wm-modal.js +4 -3
- package/dist/collection/components/wm-modal-pss/wm-modal-pss-footer.js +1 -1
- package/dist/collection/components/wm-modal-pss/wm-modal-pss-header.js +1 -1
- package/dist/collection/components/wm-modal-pss/wm-modal-pss.js +7 -4
- package/dist/collection/components/wm-navigation/wm-navigation-hamburger.js +1 -1
- package/dist/collection/components/wm-navigation/wm-navigation-item.js +1 -1
- package/dist/collection/components/wm-navigation/wm-navigation.js +4 -4
- package/dist/collection/components/wm-navigator/priv-navigator-button/priv-navigator-button.js +1 -1
- package/dist/collection/components/wm-navigator/priv-navigator-item/priv-navigator-item.js +1 -1
- package/dist/collection/components/wm-pagination/wm-pagination.js +1 -1
- package/dist/collection/components/wm-search/wm-search.js +2 -2
- package/dist/collection/components/wm-snackbar/wm-snackbar.js +2 -2
- package/dist/collection/components/wm-tabs/wm-tab-item/wm-tab-item.js +2 -2
- package/dist/collection/components/wm-tabs/wm-tab-list/wm-tab-list.js +3 -3
- package/dist/collection/components/wm-tabs/wm-tab-panel/wm-tab-panel.js +1 -1
- package/dist/collection/components/wm-tag-input/wm-tag-input.js +2 -2
- package/dist/collection/components/wm-textarea/wm-textarea.js +1 -1
- package/dist/collection/components/wm-timepicker/wm-timepicker.css +14 -29
- package/dist/collection/components/wm-timepicker/wm-timepicker.js +2 -2
- package/dist/collection/components/wm-toggletip/wm-toggletip.js +3 -3
- package/dist/collection/components/wm-uploader/wm-uploader.js +31 -28
- package/dist/collection/global/functions.js +9 -0
- package/dist/esm/{app-globals-8cefcc2e.js → app-globals-1505b33c.js} +1 -1
- package/dist/esm/{chartFunctions-613e9c87.js → chartFunctions-02a60556.js} +1 -1
- package/dist/esm/{functions-38e392cb.js → functions-14aaf49d.js} +106 -25
- package/dist/esm/{intl-0b8f342e.js → intl-7b5f8017.js} +1 -1
- package/dist/esm/loader.js +2 -2
- package/dist/esm/priv-calendar.entry.js +105 -84
- package/dist/esm/priv-chart-popover.entry.js +1 -1
- package/dist/esm/priv-navigator-button.entry.js +1 -1
- package/dist/esm/priv-navigator-item.entry.js +1 -1
- package/dist/esm/priv-option-list.entry.js +3 -3
- package/dist/esm/ripple.js +2 -2
- package/dist/esm/wm-action-menu_2.entry.js +3 -3
- package/dist/esm/wm-button.entry.js +2 -2
- package/dist/esm/wm-chart.entry.js +3 -3
- package/dist/esm/wm-date-range.entry.js +1 -1
- package/dist/esm/wm-datepicker.entry.js +1 -1
- package/dist/esm/wm-file-list.entry.js +1 -1
- package/dist/esm/wm-file.entry.js +2 -2
- package/dist/esm/wm-flyout.entry.js +5 -4
- package/dist/esm/wm-input.entry.js +3 -3
- package/dist/esm/wm-line-chart.entry.js +3 -3
- package/dist/esm/wm-modal-pss_3.entry.js +11 -8
- package/dist/esm/wm-modal_3.entry.js +8 -7
- package/dist/esm/wm-navigation_3.entry.js +8 -8
- package/dist/esm/wm-navigator.entry.js +1 -1
- package/dist/esm/wm-nested-select.entry.js +5 -5
- package/dist/esm/wm-optgroup.entry.js +2 -2
- package/dist/esm/wm-option_2.entry.js +7 -7
- package/dist/esm/wm-pagination.entry.js +3 -3
- package/dist/esm/wm-progress-indicator_3.entry.js +2 -2
- package/dist/esm/wm-search.entry.js +4 -4
- package/dist/esm/wm-snackbar.entry.js +4 -4
- package/dist/esm/wm-tab-item_3.entry.js +7 -7
- package/dist/esm/wm-tag-input.entry.js +4 -4
- package/dist/esm/wm-tag-option.entry.js +1 -1
- package/dist/esm/wm-textarea.entry.js +3 -3
- package/dist/esm/wm-timepicker.entry.js +4 -4
- package/dist/esm/wm-toggletip.entry.js +4 -4
- package/dist/esm/wm-uploader.entry.js +32 -29
- package/dist/esm-es5/app-globals-1505b33c.js +1 -0
- package/dist/esm-es5/{chartFunctions-613e9c87.js → chartFunctions-02a60556.js} +1 -1
- package/dist/esm-es5/functions-14aaf49d.js +1 -0
- package/dist/esm-es5/{intl-0b8f342e.js → intl-7b5f8017.js} +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/priv-calendar.entry.js +1 -1
- package/dist/esm-es5/priv-chart-popover.entry.js +1 -1
- package/dist/esm-es5/priv-navigator-button.entry.js +1 -1
- package/dist/esm-es5/priv-navigator-item.entry.js +1 -1
- package/dist/esm-es5/priv-option-list.entry.js +1 -1
- package/dist/esm-es5/ripple.js +1 -1
- package/dist/esm-es5/wm-action-menu_2.entry.js +1 -1
- package/dist/esm-es5/wm-button.entry.js +1 -1
- package/dist/esm-es5/wm-chart.entry.js +1 -1
- package/dist/esm-es5/wm-date-range.entry.js +1 -1
- package/dist/esm-es5/wm-datepicker.entry.js +1 -1
- package/dist/esm-es5/wm-file-list.entry.js +1 -1
- package/dist/esm-es5/wm-file.entry.js +1 -1
- package/dist/esm-es5/wm-flyout.entry.js +1 -1
- package/dist/esm-es5/wm-input.entry.js +1 -1
- package/dist/esm-es5/wm-line-chart.entry.js +1 -1
- package/dist/esm-es5/wm-modal-pss_3.entry.js +1 -1
- package/dist/esm-es5/wm-modal_3.entry.js +1 -1
- package/dist/esm-es5/wm-navigation_3.entry.js +1 -1
- package/dist/esm-es5/wm-navigator.entry.js +1 -1
- package/dist/esm-es5/wm-nested-select.entry.js +1 -1
- package/dist/esm-es5/wm-optgroup.entry.js +1 -1
- package/dist/esm-es5/wm-option_2.entry.js +1 -1
- package/dist/esm-es5/wm-pagination.entry.js +1 -1
- package/dist/esm-es5/wm-progress-indicator_3.entry.js +1 -1
- package/dist/esm-es5/wm-search.entry.js +1 -1
- package/dist/esm-es5/wm-snackbar.entry.js +1 -1
- package/dist/esm-es5/wm-tab-item_3.entry.js +1 -1
- package/dist/esm-es5/wm-tag-input.entry.js +1 -1
- package/dist/esm-es5/wm-tag-option.entry.js +1 -1
- package/dist/esm-es5/wm-textarea.entry.js +1 -1
- package/dist/esm-es5/wm-timepicker.entry.js +1 -1
- package/dist/esm-es5/wm-toggletip.entry.js +1 -1
- package/dist/esm-es5/wm-uploader.entry.js +1 -1
- package/dist/ripple/{p-8d1e0f23.system.entry.js → p-020e58d2.system.entry.js} +1 -1
- package/dist/ripple/{p-4df8346a.entry.js → p-0460b298.entry.js} +1 -1
- package/dist/ripple/{p-41664372.entry.js → p-07dd157d.entry.js} +1 -1
- package/dist/ripple/{p-47e87534.entry.js → p-0a47f460.entry.js} +1 -1
- package/dist/ripple/{p-667fdcbb.system.entry.js → p-0c737405.system.entry.js} +1 -1
- package/dist/ripple/{p-908057b2.entry.js → p-0eb56759.entry.js} +1 -1
- package/dist/ripple/{p-44cc05f6.system.entry.js → p-0ed21cab.system.entry.js} +1 -1
- package/dist/ripple/{p-9609d8e7.entry.js → p-12f39b2f.entry.js} +1 -1
- package/dist/ripple/{p-2b7259cb.system.entry.js → p-135ecb41.system.entry.js} +1 -1
- package/dist/ripple/{p-b0da7ad4.system.entry.js → p-140d1765.system.entry.js} +1 -1
- package/dist/ripple/{p-118093e1.entry.js → p-1ea4427b.entry.js} +1 -1
- package/dist/ripple/p-21361a84.entry.js +1 -0
- package/dist/ripple/{p-92c8361f.js → p-220fa36a.js} +1 -1
- package/dist/ripple/{p-96f86eb4.system.entry.js → p-223efa2f.system.entry.js} +1 -1
- package/dist/ripple/{p-7134a305.system.entry.js → p-22b8d0a4.system.entry.js} +1 -1
- package/dist/ripple/{p-c7f3ef7f.system.entry.js → p-241e4847.system.entry.js} +1 -1
- package/dist/ripple/{p-7edd25f7.system.js → p-2ecde7a9.system.js} +1 -1
- package/dist/ripple/{p-17964357.system.entry.js → p-321d4148.system.entry.js} +1 -1
- package/dist/ripple/{p-8e2f3a45.entry.js → p-365ab12b.entry.js} +1 -1
- package/dist/ripple/{p-65abcbb4.system.js → p-3967eef9.system.js} +1 -1
- package/dist/ripple/{p-6a70dc0b.system.entry.js → p-3b9ddb71.system.entry.js} +1 -1
- package/dist/ripple/{p-960d2cf0.system.entry.js → p-3ef56754.system.entry.js} +1 -1
- package/dist/ripple/{p-2f8bad10.entry.js → p-3ef6eadd.entry.js} +1 -1
- package/dist/ripple/{p-00eaa361.system.entry.js → p-4086d2f2.system.entry.js} +1 -1
- package/dist/ripple/{p-4d0abf7a.entry.js → p-4cc3a15f.entry.js} +1 -1
- package/dist/ripple/{p-91c5b14e.system.entry.js → p-4e9f0f73.system.entry.js} +1 -1
- package/dist/ripple/{p-b1fb99e4.system.entry.js → p-4edc18b1.system.entry.js} +1 -1
- package/dist/ripple/{p-5405df80.system.entry.js → p-533290cd.system.entry.js} +1 -1
- package/dist/ripple/{p-3133ce3c.system.entry.js → p-579e1c9d.system.entry.js} +1 -1
- package/dist/ripple/p-5a38e30d.system.entry.js +1 -0
- package/dist/ripple/{p-1a89139d.system.entry.js → p-5e15c72a.system.entry.js} +1 -1
- package/dist/ripple/{p-3612ee73.entry.js → p-61f780ab.entry.js} +1 -1
- package/dist/ripple/p-65b87f9b.entry.js +1 -0
- package/dist/ripple/p-65ba88b7.system.js +1 -0
- package/dist/ripple/{p-23e1112c.system.entry.js → p-6d0f7f1d.system.entry.js} +1 -1
- package/dist/ripple/{p-ecd1c2ba.entry.js → p-71a3be1c.entry.js} +1 -1
- package/dist/ripple/{p-56e376b2.system.entry.js → p-736dc15d.system.entry.js} +1 -1
- package/dist/ripple/p-73d1ec58.js +1 -0
- package/dist/ripple/{p-39a4934f.entry.js → p-742451fa.entry.js} +1 -1
- package/dist/ripple/{p-2db6573e.system.entry.js → p-78339dc5.system.entry.js} +1 -1
- package/dist/ripple/p-7a68fd88.system.entry.js +1 -0
- package/dist/ripple/p-80554ae6.entry.js +1 -0
- package/dist/ripple/{p-f9bbb123.system.entry.js → p-86113458.system.entry.js} +1 -1
- package/dist/ripple/{p-a9ddfa2c.entry.js → p-886b50fb.entry.js} +1 -1
- package/dist/ripple/p-8e59cec0.entry.js +1 -0
- package/dist/ripple/{p-4602304a.system.entry.js → p-8eba876d.system.entry.js} +1 -1
- package/dist/ripple/p-99a2a45c.entry.js +1 -0
- package/dist/ripple/{p-d815809f.js → p-9f10c71b.js} +1 -1
- package/dist/ripple/{p-86a61a2a.entry.js → p-9f27c966.entry.js} +1 -1
- package/dist/ripple/{p-507ea41f.system.entry.js → p-a0acef05.system.entry.js} +1 -1
- package/dist/ripple/p-a0b38e60.system.js +1 -0
- package/dist/ripple/{p-fe697924.system.entry.js → p-ad409bbe.system.entry.js} +1 -1
- package/dist/ripple/{p-abcdd7be.system.entry.js → p-b3682bbf.system.entry.js} +1 -1
- package/dist/ripple/{p-e5c34af5.system.entry.js → p-b5bfb1a3.system.entry.js} +1 -1
- package/dist/ripple/{p-72e1fdb5.entry.js → p-be8f0d4c.entry.js} +1 -1
- package/dist/ripple/{p-f91fc18d.entry.js → p-c68699f5.entry.js} +1 -1
- package/dist/ripple/{p-0bce3f83.entry.js → p-c9c76589.entry.js} +1 -1
- package/dist/ripple/{p-a5c5c64c.entry.js → p-cc85cd9b.entry.js} +1 -1
- package/dist/ripple/p-d05bd699.entry.js +1 -0
- package/dist/ripple/{p-9e89655f.entry.js → p-d3aa80bc.entry.js} +1 -1
- package/dist/ripple/{p-a14dee02.system.entry.js → p-d66d99cd.system.entry.js} +1 -1
- package/dist/ripple/{p-bde7e77b.system.entry.js → p-d8e7f0ab.system.entry.js} +1 -1
- package/dist/ripple/{p-2f7e25a2.system.entry.js → p-dab72fca.system.entry.js} +1 -1
- package/dist/ripple/{p-4b8f7d1e.entry.js → p-de03a626.entry.js} +1 -1
- package/dist/ripple/p-e72235c6.js +1 -0
- package/dist/ripple/{p-60e16c79.entry.js → p-e73d5896.entry.js} +1 -1
- package/dist/ripple/{p-5e7893f0.entry.js → p-e9038796.entry.js} +1 -1
- package/dist/ripple/{p-1259cb49.system.js → p-e9d745e1.system.js} +1 -1
- package/dist/ripple/{p-2508b801.entry.js → p-eb68ec38.entry.js} +1 -1
- package/dist/ripple/{p-957f13fb.entry.js → p-ecafbfba.entry.js} +1 -1
- package/dist/ripple/{p-31bac55d.entry.js → p-ef3a4568.entry.js} +1 -1
- package/dist/ripple/{p-d9c7206b.system.entry.js → p-f1dea7a8.system.entry.js} +1 -1
- package/dist/ripple/{p-9202d9e9.entry.js → p-f3216137.entry.js} +1 -1
- package/dist/ripple/{p-f4390a0a.system.entry.js → p-f496570f.system.entry.js} +1 -1
- package/dist/ripple/{p-ee96cea8.entry.js → p-f5c59ec1.entry.js} +1 -1
- package/dist/ripple/ripple.esm.js +1 -1
- package/dist/ripple/ripple.js +1 -1
- package/dist/types/components/datepickers/priv-calendar/priv-calendar.d.ts +8 -0
- package/dist/types/components/wm-flyout/wm-flyout.d.ts +1 -0
- package/dist/types/components/wm-modal/wm-modal.d.ts +1 -0
- package/dist/types/components/wm-modal-pss/wm-modal-pss.d.ts +2 -0
- package/dist/types/components/wm-navigation/wm-navigation.d.ts +1 -0
- package/dist/types/components/wm-uploader/wm-uploader.d.ts +3 -3
- package/dist/types/global/functions.d.ts +1 -0
- package/package.json +2 -2
- package/dist/esm-es5/app-globals-8cefcc2e.js +0 -1
- package/dist/esm-es5/functions-38e392cb.js +0 -1
- package/dist/ripple/p-0652e156.js +0 -1
- package/dist/ripple/p-0825151e.entry.js +0 -1
- package/dist/ripple/p-26ffcd83.entry.js +0 -1
- package/dist/ripple/p-56b6d9f6.entry.js +0 -1
- package/dist/ripple/p-608971f2.system.js +0 -1
- package/dist/ripple/p-7c3bf608.entry.js +0 -1
- package/dist/ripple/p-8ec6ec53.entry.js +0 -1
- package/dist/ripple/p-a7cde3fc.entry.js +0 -1
- package/dist/ripple/p-b511ebfd.js +0 -1
- package/dist/ripple/p-e660d0b8.system.entry.js +0 -1
- package/dist/ripple/p-f1939079.system.js +0 -1
- package/dist/ripple/p-fbad04d7.system.entry.js +0 -1
|
@@ -46,8 +46,10 @@ export class ModalPss {
|
|
|
46
46
|
showModal() {
|
|
47
47
|
this.setAriaDescribedbyOnModal();
|
|
48
48
|
this.setElToFocusOnClose(); //Record where the user was before the modal opened so that focus can return to it when the modal closes
|
|
49
|
+
this.initialBodyOverflow = document.body.style.overflow;
|
|
49
50
|
document.body.style.overflow = "hidden"; //Keeps the page below the modal from scrolling
|
|
50
51
|
//Focus listeners as a general catch for keeping focus in case of errors in finding element with id passed in by dev (element is removed from DOM, etc.) or other scenarios
|
|
52
|
+
this.initialBodyTabIndex = document.body.tabIndex;
|
|
51
53
|
document.body.tabIndex = 0;
|
|
52
54
|
document.body.removeEventListener("focus", this.bodyFocusListener, true);
|
|
53
55
|
document.body.addEventListener("focus", this.bodyFocusListener, true);
|
|
@@ -58,8 +60,9 @@ export class ModalPss {
|
|
|
58
60
|
}
|
|
59
61
|
//Close the modal and focus the triggering element when the modal buttons emit their events
|
|
60
62
|
hideModal() {
|
|
61
|
-
|
|
62
|
-
document.body.
|
|
63
|
+
// TypeScript doesn't like the idea of assigning undefined but that's what we want
|
|
64
|
+
document.body.style.overflow = this.initialBodyOverflow;
|
|
65
|
+
document.body.tabIndex = this.initialBodyTabIndex;
|
|
63
66
|
document.body.removeEventListener("focus", this.bodyFocusListener, true);
|
|
64
67
|
window.requestAnimationFrame(() => this.focusOnCloseEl.focus()); //Return focus
|
|
65
68
|
}
|
|
@@ -112,9 +115,9 @@ export class ModalPss {
|
|
|
112
115
|
}
|
|
113
116
|
}
|
|
114
117
|
render() {
|
|
115
|
-
return (h(Host, { key: '
|
|
118
|
+
return (h(Host, { key: 'ddf77d980c1751926c10fe86afebb9eef85dc9ac', class: `${this.open ? "" : "hide "}${"wm-" + this.modalType}`, role: "dialog", "aria-describedby": `wm-modal-heading-text-${this.uid}`, "aria-modal": "true", tabindex: this.open ? 0 : null, onFocus: () => {
|
|
116
119
|
this.focusLastElement.emit();
|
|
117
|
-
} }, h("div", { key: '
|
|
120
|
+
} }, h("div", { key: '0f422c764810c173e093a0c1c92a5248446b3a75', class: "overlay", ref: (el) => (this.overlayEl = el) }), h("div", { key: 'b15e362f110ca21ca9ba554b9b884c9db4af9138', class: "sr-only", tabIndex: 0, onFocus: () => {
|
|
118
121
|
this.focusFirstElement.emit();
|
|
119
122
|
} })));
|
|
120
123
|
}
|
|
@@ -34,7 +34,7 @@ export class NavigationHamburger {
|
|
|
34
34
|
this.wmNavigationHamburgerClicked.emit();
|
|
35
35
|
}
|
|
36
36
|
render() {
|
|
37
|
-
return (h(Host, { key: '
|
|
37
|
+
return (h(Host, { key: 'a43f96c6c9277bcbc28db3f54c1e6dac5a12c711', class: `hamburger ${this.open ? "nav-open" : "nav-closed"}` }, h("button", { key: 'e8d172739a625abdd185201609f43660a43d92b4', "aria-expanded": this.open, "aria-label": this.showNavMessage, onMouseEnter: () => showTooltip("right", this.el, this.showNavMessage), onMouseLeave: () => hideTooltip(), onFocus: () => this.isTabbing && showTooltip("right", this.el, this.showNavMessage), onBlur: () => hideTooltip(), onClick: () => this.handleClick() }, h("span", { key: '1e6cf4f1d121a4e5b04dcece6a00ac5cffbaecbb', class: "svg-icon svg-menu" }))));
|
|
38
38
|
}
|
|
39
39
|
static get is() { return "wm-navigation-hamburger"; }
|
|
40
40
|
static get encapsulation() { return "shadow"; }
|
|
@@ -6,7 +6,7 @@ export class NavigationItem {
|
|
|
6
6
|
this.active = undefined;
|
|
7
7
|
}
|
|
8
8
|
render() {
|
|
9
|
-
return (h(Host, { key: '
|
|
9
|
+
return (h(Host, { key: 'bf087268732555bdbe50c267f97c9f0858bba980', role: "listitem" }, h("a", { key: '2b6086ffd77e24e73ea262a9c730825cd9050e94', class: `link ${this.active ? "active" : ""}`, href: this.href, onClick: () => this.wmNavigationItemClicked.emit() }, h("div", { key: '3e2e6f675ad123a095e2ca41f575e988c7949395', class: "icon", "aria-hidden": "true" }, h("slot", { key: '7733614fd071798abf4f8b254293d34cacfd6c5c' })), h("div", { key: 'a5312a7a50264dbfa191ed1136e6433609c337a6', class: "text" }, this.text))));
|
|
10
10
|
}
|
|
11
11
|
static get is() { return "wm-navigation-item"; }
|
|
12
12
|
static get encapsulation() { return "shadow"; }
|
|
@@ -69,6 +69,7 @@ export class Navigation {
|
|
|
69
69
|
// listen to focus on body and redirect to the component
|
|
70
70
|
// this is to handle trap focus when user has left the page (e.g. went to the address bar)
|
|
71
71
|
// and is tabbing back in
|
|
72
|
+
this.initialBodyTabIndex = document.body.tabIndex; // Typescript complains that this might be undefined but if it were, we would want to assign it.
|
|
72
73
|
document.body.tabIndex = 0;
|
|
73
74
|
document.body.addEventListener("focus", this.redirectFocusFromBody.bind(this), true);
|
|
74
75
|
// wait for nav to be expanded otherwise tooltip will be misplaced.
|
|
@@ -76,8 +77,7 @@ export class Navigation {
|
|
|
76
77
|
//document.querySelector("wm-navigation")!.shadowRoot!.querySelector(".toggle")!.focus()
|
|
77
78
|
}
|
|
78
79
|
collapse() {
|
|
79
|
-
//
|
|
80
|
-
document.body.tabIndex = -1;
|
|
80
|
+
document.body.tabIndex = this.initialBodyTabIndex; // TypeScript doesn't like that this can be undefined, but we do want to assign undefined if that's the value.
|
|
81
81
|
document.body.removeEventListener("focus", this.redirectFocusFromBody.bind(this));
|
|
82
82
|
const hamburgerBtn = document.querySelector("wm-navigation-hamburger");
|
|
83
83
|
// should fail silently if el doesn't exist
|
|
@@ -96,9 +96,9 @@ export class Navigation {
|
|
|
96
96
|
} }));
|
|
97
97
|
}
|
|
98
98
|
render() {
|
|
99
|
-
return (h(Host, { key: '
|
|
99
|
+
return (h(Host, { key: '2d7f11924052f4438243237f1d38141f6652b944', role: "navigation", "aria-expanded": this.ariaExpanded, "aria-label": this.mainNavigationMessage }, this.open ? this.renderOverlay() : "", this.isCollapsible && (h("div", { key: 'f92b7cab8cd7e1c63e59cac31afd9efcfda4234f', class: "trapfocus", tabindex: this.open ? 0 : undefined, onFocus: () => this.focusLastItem() })), h("div", { key: '7fec0055e808b49676b8b589e59244b884545ea1', class: "tray" }, h("div", { key: '8ac1ae8da1054a6dceda08f751768de718080bde', class: "toggle-wrapper" }, h("wm-button", { key: 'e36fcb93366baef360df96298cb35c4576a9a916', ref: (el) => (this.toggleEl = el), class: "toggle", "button-type": "navigational", icon: this.open ? "#close" : "#menu", "icon-size": "2rem", tooltip: this.open ? globalMessages.close : globalMessages.open, "tooltip-position": "right", tabIndex: this.open ? undefined : -1, onClick: () => {
|
|
100
100
|
this.open = !this.open;
|
|
101
|
-
} })), h("ul", { key: '
|
|
101
|
+
} })), h("ul", { key: '22ba6ec5ce572f1c04ccb45301659dde791f3115', class: "navlist" }, h("slot", { key: '3fa52b5bbe4e1346d90e5a556eeeabfeb9a7f4a0' }))), this.isCollapsible && (h("div", { key: 'e7738e6001e65f8e4fecdd775ea40d93b84cd4b4', class: "trapfocus", tabindex: this.open ? 0 : undefined, onFocus: () => this.toggleEl.focus() }))));
|
|
102
102
|
}
|
|
103
103
|
static get is() { return "wm-navigation"; }
|
|
104
104
|
static get encapsulation() { return "shadow"; }
|
package/dist/collection/components/wm-navigator/priv-navigator-button/priv-navigator-button.js
CHANGED
|
@@ -9,7 +9,7 @@ export class PrivNavigatorButton {
|
|
|
9
9
|
}
|
|
10
10
|
render() {
|
|
11
11
|
const { handleClick, altText } = this;
|
|
12
|
-
return (h("button", { key: '
|
|
12
|
+
return (h("button", { key: '37826c509d1b35d0e5ef9915749d521941251722', "aria-expanded": this.expanded.toString(), class: "navigator", onClick: handleClick.bind(this), "aria-label": altText }));
|
|
13
13
|
}
|
|
14
14
|
static get is() { return "priv-navigator-button"; }
|
|
15
15
|
static get encapsulation() { return "shadow"; }
|
|
@@ -16,7 +16,7 @@ export class PrivNavigatorItem {
|
|
|
16
16
|
render() {
|
|
17
17
|
const selectedClass = this.selected ? "selected" : "";
|
|
18
18
|
const focusedClass = this.focused ? "focused" : "";
|
|
19
|
-
return (h("div", { key: '
|
|
19
|
+
return (h("div", { key: '7dba57536d9412d9f8865433056a2bcbde2f95aa', class: `navoption ${selectedClass} ${focusedClass}` }, h("slot", { key: 'fcfc79489b88184203d8e4163f256e531de9bc67' })));
|
|
20
20
|
}
|
|
21
21
|
static get is() { return "priv-navigator-item"; }
|
|
22
22
|
static get encapsulation() { return "shadow"; }
|
|
@@ -203,7 +203,7 @@ export class Pagination {
|
|
|
203
203
|
render() {
|
|
204
204
|
return (
|
|
205
205
|
// do not render the component if there's only one page
|
|
206
|
-
this.totalItems > this.itemsPerPage && (h("nav", { key: '
|
|
206
|
+
this.totalItems > this.itemsPerPage && (h("nav", { key: '6be7673743d44ea45076ea3a7a6bcd4e48d4837d', "aria-label": `${this.navigationLabel} ${this.getCurrentPagesInView()}. ${this.currentPageAnnouncement(this.currentPage)}` }, this.isLargeSize ? this.renderLarge() : this.renderSmall(), h("div", { key: 'd67e8a638a0aad67828a625ac07e5559876b15e8', id: "status", class: "sr-only", "aria-live": "polite", "aria-relevant": "text", "aria-atomic": "true" }, this.srAnnouncement))));
|
|
207
207
|
}
|
|
208
208
|
static get is() { return "wm-pagination"; }
|
|
209
209
|
static get encapsulation() { return "shadow"; }
|
|
@@ -168,10 +168,10 @@ export class Search {
|
|
|
168
168
|
* End search and find render helpers
|
|
169
169
|
*/
|
|
170
170
|
render() {
|
|
171
|
-
return (h(Host, { key: '
|
|
171
|
+
return (h(Host, { key: '54839cc6b1e6c142e3f60d01572f4645816ccf08' }, h("div", { key: '19d72e8d5c578328ca64819a289e974a279ee352', id: "wm-search-wrapper", class: `wm-search-wrapper ${this.searchType}` }, h("input", { key: '1cf69b8f9d3ec4e7fdb0fa6a391fd71c920c7c74', disabled: this.isDisabled, id: "wm-search-input", placeholder: this.placeholder, "aria-label": `${this.label ? this.label + ". " : ""}${intl.formatMessage({
|
|
172
172
|
id: "search.typeToFilterResults",
|
|
173
173
|
defaultMessage: "Type to filter the results",
|
|
174
|
-
})}`, onInput: (ev) => this.updateValue(ev.target.value), onBlur: () => this.handleBlur(), "aria-autocomplete": "none", autocomplete: "off", value: this.value }), h("span", { key: '
|
|
174
|
+
})}`, onInput: (ev) => this.updateValue(ev.target.value), onBlur: () => this.handleBlur(), "aria-autocomplete": "none", autocomplete: "off", value: this.value }), h("span", { key: '3495eb2351e9e51a114cb8680206196752623135', class: "svg-icon svg-search" }), this.searchType === "find" && this.renderResultsAndBrowseButtons(), h("div", { key: '837a9c6a9c68d19c9bf4cb09158b22867036c128', id: "wm-search-live", class: "sr-only", "aria-live": "polite", "aria-atomic": "true", ref: (el) => (this.resultsLiveRegion = el) }, this.announcement)), this.searchType === "find" && this.renderJumpToLink()));
|
|
175
175
|
}
|
|
176
176
|
static get is() { return "wm-search"; }
|
|
177
177
|
static get encapsulation() { return "shadow"; }
|
|
@@ -145,11 +145,11 @@ export class Snackbar {
|
|
|
145
145
|
}, onKeyDown: (ev) => ev.key === "Enter" && this.snackLinkClicked(notification) }, h("span", { "aria-hidden": "true" }, notification.link), notification.newWindow && h("div", { class: "svg-icon svg-open-in-new" })))), h("button", { id: `close-button-${notification.id}`, "aria-label": this.closeSnackMessage, class: "closesnack", tabindex: notification.link ? 0 : -1, onClick: () => this.snackDismissed(notification), onMouseEnter: (ev) => showTooltip("bottom", ev.target, globalMessages.close), onMouseLeave: () => hideTooltip(), onFocus: (ev) => this.isTabbing && showTooltip("bottom", ev.target, globalMessages.close), onBlur: () => hideTooltip() }, h("div", { class: "svg-icon svg-close" }))), h("div", { class: "sr-only", tabindex: notification.link ? 0 : -1, onFocus: () => notification.link && this.snackDismissed(notification) })))));
|
|
146
146
|
}
|
|
147
147
|
render() {
|
|
148
|
-
return (h(Host, { key: '
|
|
148
|
+
return (h(Host, { key: 'd3e6bea353d66664559f6dce9fa1d3301f99e3db' }, h("div", { key: 'be5bf8d2ebbab807af66cc479929c3b696537fd8', ref: (el) => (this.snackAreaEl = el), class: {
|
|
149
149
|
"list-wrapper": true,
|
|
150
150
|
"user-is-tabbing": this.isTabbing,
|
|
151
151
|
empty: this.parsedNotifications.length == 0,
|
|
152
|
-
} }, this.renderSnackbars()), h("div", { key: '
|
|
152
|
+
} }, this.renderSnackbars()), h("div", { key: 'defc7a78c6a890a4a9566f57ec55352ecc91dfa0', class: "sr-only", "aria-live": "polite", "aria-atomic": "false", id: `wm-live-region-${this.uid}`, ref: (el) => (this.liveRegionEl = el) }, this.announcement)));
|
|
153
153
|
}
|
|
154
154
|
static get is() { return "wm-snackbar"; }
|
|
155
155
|
static get encapsulation() { return "shadow"; }
|
|
@@ -27,9 +27,9 @@ export class TabItem {
|
|
|
27
27
|
}
|
|
28
28
|
render() {
|
|
29
29
|
const isDark = this.parentTabList && this.parentTabList.customBackground == "dark";
|
|
30
|
-
return (h(Host, { key: '
|
|
30
|
+
return (h(Host, { key: '32c6aac6411c25d4b82107b6334b1732a0ef2ffa', role: "presentation" }, h("li", { key: 'f6fc4ae969e7a767389b9addf613fb83f8185bae', class: `tab-item ${isDark ? "dark" : ""}`, role: "presentation" }, h("a", { key: '250ad48a22872b09adbf5bac7de1779ecc3a8a9b', class: `tab`, role: "tab", ref: (el) => (this.linkEl = el), id: `tab-link-${this.tabId}`, onKeyDown: (ev) => this.tabPressed(ev), "aria-selected": this.selected ? "true" : "false", tabindex: this.selected ? 0 : -1, onClick: this.tabClicked, onFocus: () => {
|
|
31
31
|
this.wmIntTabFocused.emit({ tabItem: this.el });
|
|
32
|
-
} }, h("slot", { key: '
|
|
32
|
+
} }, h("slot", { key: 'ab90abb21cb8617a158aa3dff4d77c7ac4d49b96' })))));
|
|
33
33
|
}
|
|
34
34
|
static get is() { return "wm-tab-item"; }
|
|
35
35
|
static get encapsulation() { return "shadow"; }
|
|
@@ -257,15 +257,15 @@ export class TabList {
|
|
|
257
257
|
this.announcement = message;
|
|
258
258
|
}
|
|
259
259
|
render() {
|
|
260
|
-
return (h(Host, { key: '
|
|
260
|
+
return (h(Host, { key: 'fb6f216a7c2b9008565d2084751daf40267aa43e' }, h("div", { key: '6d8ade20d79c1d3e152cdf01bad10c3b7494a8a6', class: "component-wrapper" }, h("wm-button", { key: '70be40893bb3ececa751eaccf86e33c9035e01b5', class: `left-arrow ${this.scrollArrowsVisible ? "visible" : ""}`, "aria-controls": "tablist", customBackground: this.customBackground, buttonType: "navigational", icon: "#previous", tooltip: intl.formatMessage({
|
|
261
261
|
id: "tabs.showPreviousTabs",
|
|
262
262
|
defaultMessage: "Show previous tabs",
|
|
263
263
|
description: "Tooltip for button scrolling tab group.",
|
|
264
|
-
}), onClick: (ev) => this.handleLeftArrowClick(ev) }), h("ul", { key: '
|
|
264
|
+
}), onClick: (ev) => this.handleLeftArrowClick(ev) }), h("ul", { key: '30a4176c4ba68f4a30c269d0998f7634b66ebc0c', id: "tablist", ref: (el) => (this.tabContainerEl = el), class: `tabcontainer ${this.customBackground || ""} ${this.containerFadeLeft ? "fade-left" : ""} ${this.containerFadeRight ? "fade-right" : ""}`, role: "tablist", tabIndex: -1 }, h("slot", { key: 'd3225fe95f7c09287d79886a8a22cf80aab18bb7' })), h("wm-button", { key: 'ef52e8c658dbe0a968bb89c8b3ff15a981d83d23', class: `right-arrow ${this.scrollArrowsVisible ? "visible" : ""}`, "aria-controls": "tablist", customBackground: this.customBackground, buttonType: "navigational", icon: "#next", tooltip: intl.formatMessage({
|
|
265
265
|
id: "tabs.showNextTabs",
|
|
266
266
|
defaultMessage: "Show next tabs",
|
|
267
267
|
description: "Tooltip for button scrolling tab group.",
|
|
268
|
-
}), onClick: (ev) => this.handleRightArrowClick(ev) }), h("span", { key: '
|
|
268
|
+
}), onClick: (ev) => this.handleRightArrowClick(ev) }), h("span", { key: 'cc2cf63d5f82dbf25b93888e13cde3fdab9453dc', "aria-live": "assertive", class: "sr-only", ref: (el) => (this.liveRegionEl = el) }, this.announcement))));
|
|
269
269
|
}
|
|
270
270
|
static get is() { return "wm-tab-list"; }
|
|
271
271
|
static get encapsulation() { return "shadow"; }
|
|
@@ -12,7 +12,7 @@ export class TabPanel {
|
|
|
12
12
|
this.tabPanelLoaded.emit({ tabId: this.tabId });
|
|
13
13
|
}
|
|
14
14
|
render() {
|
|
15
|
-
return h(Host, { key: '
|
|
15
|
+
return h(Host, { key: 'a7969f5c022d18fc579947c557b8177fdee413b4', role: "tabpanel", class: { "tab-hidden": !this.active } });
|
|
16
16
|
}
|
|
17
17
|
static get is() { return "wm-tab-panel"; }
|
|
18
18
|
static get originalStyleUrls() {
|
|
@@ -927,10 +927,10 @@ export class TagInput {
|
|
|
927
927
|
}
|
|
928
928
|
}
|
|
929
929
|
render() {
|
|
930
|
-
return (h("div", { key: '
|
|
930
|
+
return (h("div", { key: '1ea7a4e18d1edcd6c3e66f7b1a7426058b03e1a1', class: `wrapper label-${this.labelPosition} ${this.errorMessage ? "invalid" : ""}` }, h("div", { key: 'd0779f651e99b8f5bdbb6986daf70e7701f83d81', class: "label-wrapper" }, h("label", { key: '80465bcd2dcedd108c353fd95b57163e84ad266d', class: "label", htmlFor: "input", onMouseEnter: (ev) => this.handleLabelMouseEnter(ev), onMouseLeave: () => hideTooltip() }, this.label), this.requiredField && (h("div", { key: '2758d90e08028cac91b7b5894a9bdb919cfa9fe7', class: "required", "aria-hidden": "true" }, "*"))), h("div", { key: '5d6454cab0ae655c9ad9e5155a2737807552641d', class: `field-wrapper ${this.el.shadowRoot.activeElement === this.inputEl ? "focused" : ""} ${this.errorMessage ? "invalid" : ""}`, ref: (el) => (this.fieldWrapperEl = el) }, h("div", { key: '66e23fb5d85d8133e1907f12f354caff5b4f8b09', class: "upper-row" }, h("div", { key: '6b27e970920af73e50e1e6ae04c721f8899bb53b', class: "svg-icon svg-search" }), h("div", { key: 'c67fe9b9a364cb09224abcec3caca9979bcd66a1', class: `tags-and-input-wrapper` }, h("ul", { key: '26e53e16f3498add3b64461b9ad0cc414e7b9cd0', ref: (el) => (this.tagAreaEl = el), class: `tag-area ${this.taggedOptions.length === 0 && "empty"} ${this.isKeying ? "user-is-keying" : ""}`, role: "listbox", "aria-activedescendant": this.focusedTag ? this.focusedTag.id : null, "aria-orientation": "horizontal", "aria-label": `${this.label} ${this.tagAreaInstructions}`, tabindex: this._tagEls.length > 0 ? 0 : -1, "aria-describedby": `info max-tags`, onFocus: (ev) => this.handleTagAreaFocus(ev), onBlur: (ev) => {
|
|
931
931
|
this.focusedTagIndex = undefined;
|
|
932
932
|
this.handleBlur(ev);
|
|
933
|
-
}, onKeyDown: (ev) => this.handleTagAreaKeyDown(ev) }, this.renderTags()), this.isDropdown && this.renderDropdownInput(), this.isTable && this.renderTableInput()), this.isDropdown && (h("div", { key: '
|
|
933
|
+
}, onKeyDown: (ev) => this.handleTagAreaKeyDown(ev) }, this.renderTags()), this.isDropdown && this.renderDropdownInput(), this.isTable && this.renderTableInput()), this.isDropdown && (h("div", { key: 'bcb6e30890a2198f54b955a54226f25e1e7e887e', class: "character-count" }, this.charCount, "/", this.characterLimit))), this.renderTagCounter(), this.isDropdown && this.renderDropdown()), this.info && (h("div", { key: 'a00c7fe46e44c232ead4f1ab80f507850dec3185', id: "info", class: "info-text" }, this.info)), h("div", { key: 'de82e4d355b12f88db7b4054f1f318a2452cd4d7', id: "error" }, this.errorMessage), h("div", { key: '318a2efc15622295f94236615d1f6b3e369e77ea', class: "sr-only", "aria-live": "polite", ref: (el) => (this.liveRegionEl = el), "aria-atomic": "true" }, this.liveRegionMessage), this.isTable && this.renderTable()));
|
|
934
934
|
}
|
|
935
935
|
static get is() { return "wm-tag-input"; }
|
|
936
936
|
static get encapsulation() { return "shadow"; }
|
|
@@ -71,7 +71,7 @@ export class Textarea {
|
|
|
71
71
|
this.announcement = message;
|
|
72
72
|
}
|
|
73
73
|
render() {
|
|
74
|
-
return (h("div", { key: '
|
|
74
|
+
return (h("div", { key: '4d66731ba9bd4ba435090f31acc86b7eae07ea25', class: `wrapper label-${this.labelPosition} ${this.errorMessage ? "invalid" : ""}` }, h("div", { key: '642ce791dc16814534694b36dab601777dc655de', class: "label-wrapper" }, h("label", { key: '2a60aa3829eed6a377f5daecaa9d264dc715b38d', htmlFor: "inputfield", class: "label", onMouseEnter: (ev) => this.handleLabelMouseEnter(ev), onMouseLeave: () => hideTooltip() }, this.label, this.characterLimit && (h("span", { key: '76b6ad6c0a639f6fae230a7c1bd13f102fe747c7', class: "sr-only" }, " ", globalMessages.getCharacterLimit(this.characterLimit)))), this.requiredField && (h("span", { key: '0d47f3ef8ff15e2c4110cc279f29434f1c1c55ee', class: "required", "aria-hidden": "true" }, "*"))), h("div", { key: '060b640fcdb2b4a6fc0b310fb152b4a5736a8797', class: "inner-wrapper" }, h("div", { key: '26ec20786b6b6cf22a3b5b042478e8057fcaa471', class: `inputfield-wrapper ${this.errorMessage ? "invalid" : ""}`, style: this.inputWidth ? { width: this.inputWidth } : {} }, h("textarea", { key: '15cc0321f901bd8db6aa9fb8f26ee3906b72d7c7', id: "inputfield", disabled: this.isDisabled, "aria-describedby": "info error", onInput: (ev) => this.handleInput(ev), onBlur: () => this.handleBlur(), placeholder: this.placeholder, autocomplete: "off", "aria-required": this.requiredField ? "true" : null, value: this.value, rows: 3, style: { height: this.inputHeight } }), this.characterLimit && typeof this.characterLimit === "number" ? (h("div", { class: `character-count ${this.value.length > this.characterLimit ? "exceeded" : ""}` }, this.charCount, "/", this.characterLimit)) : ("")), this.info && (h("div", { key: '13f454a13e63f3f583011ab43c7b22409f934a2e', id: "info", class: "info" }, this.info)), h("div", { key: '281885a5098b169ba5f192f5056c7ab14c8d944c', id: "error", class: "error-message" }, this.errorMessage), h("div", { key: '32a259bfdda78dc540e71140a4d8fbd1b7e46143', id: "live-polite", class: "sr-only", "aria-live": "polite", "aria-atomic": "true", ref: (el) => (this.liveRegionEl = el) }, this.announcement))));
|
|
75
75
|
}
|
|
76
76
|
static get is() { return "wm-textarea"; }
|
|
77
77
|
static get encapsulation() { return "shadow"; }
|
|
@@ -865,22 +865,6 @@
|
|
|
865
865
|
}
|
|
866
866
|
|
|
867
867
|
:host {
|
|
868
|
-
--wmcolor-timepicker-background: var(--wmcolor-background);
|
|
869
|
-
--wmcolor-timepicker-input-background-disabled: var(--wmcolor-interactive-background-disabled);
|
|
870
|
-
--wmcolor-timepicker-input-background: var(--wmcolor-background);
|
|
871
|
-
--wmcolor-timepicker-input-border: var(--wmcolor-border-dark);
|
|
872
|
-
--wmcolor-timepicker-input-text-disabled: var(--wmcolor-interactive-disabled);
|
|
873
|
-
--wmcolor-timepicker-input-text: var(--wmcolor-text);
|
|
874
|
-
--wmcolor-timepicker-option-background-focus: var(--wmcolor-interactive-background-hover);
|
|
875
|
-
--wmcolor-timepicker-option-background-hover: var(--wmcolor-option-background-hover);
|
|
876
|
-
--wmcolor-timepicker-option-background: var(--wmcolor-option-background);
|
|
877
|
-
--wmcolor-timepicker-option-border: var(--wmcolor-option-border);
|
|
878
|
-
--wmcolor-timepicker-option-text: var(--wmcolor-option-text);
|
|
879
|
-
--wmcolor-timepicker-toggle-background-disabled: var(--wmcolor-interactive-background-disabled);
|
|
880
|
-
--wmcolor-timepicker-toggle-background-hover: var(--wmcolor-interactive-background-hover);
|
|
881
|
-
--wmcolor-timepicker-toggle-background: var(--wmcolor-background);
|
|
882
|
-
--wmcolor-timepicker-toggle-icon-disabled: var(--wmcolor-interactive-disabled);
|
|
883
|
-
--wmcolor-timepicker-toggle-icon: var(--wmcolor-interactive);
|
|
884
868
|
font-family: inherit;
|
|
885
869
|
}
|
|
886
870
|
:host .sr-only {
|
|
@@ -981,7 +965,7 @@
|
|
|
981
965
|
align-items: center;
|
|
982
966
|
height: 2.5rem;
|
|
983
967
|
border: 1px solid;
|
|
984
|
-
border-color: var(--wmcolor-
|
|
968
|
+
border-color: var(--wmcolor-border-dark);
|
|
985
969
|
-webkit-border-radius: 3px;
|
|
986
970
|
-moz-border-radius: 3px;
|
|
987
971
|
-ms-border-radius: 3px;
|
|
@@ -1007,8 +991,8 @@
|
|
|
1007
991
|
font-family: inherit;
|
|
1008
992
|
}
|
|
1009
993
|
:host .wrapper .inner-wrapper input:disabled {
|
|
1010
|
-
background-color: var(--wmcolor-
|
|
1011
|
-
color: var(--wmcolor-
|
|
994
|
+
background-color: var(--wmcolor-interactive-background-disabled);
|
|
995
|
+
color: var(--wmcolor-interactive-disabled);
|
|
1012
996
|
}
|
|
1013
997
|
:host .wrapper .inner-wrapper input:focus {
|
|
1014
998
|
outline: none;
|
|
@@ -1018,7 +1002,7 @@
|
|
|
1018
1002
|
cursor: pointer;
|
|
1019
1003
|
padding: 0 0.375rem;
|
|
1020
1004
|
height: 2.375rem;
|
|
1021
|
-
background-color: var(--wmcolor-
|
|
1005
|
+
background-color: var(--wmcolor-background);
|
|
1022
1006
|
border: none;
|
|
1023
1007
|
-moz-border-top-right-radius: 3px;
|
|
1024
1008
|
-webkit-border-top-right-radius: 3px;
|
|
@@ -1029,19 +1013,19 @@
|
|
|
1029
1013
|
}
|
|
1030
1014
|
:host .wrapper .inner-wrapper button .svg-time {
|
|
1031
1015
|
--icon-size: 1.5rem;
|
|
1032
|
-
color: var(--wmcolor-
|
|
1016
|
+
color: var(--wmcolor-interactive);
|
|
1033
1017
|
}
|
|
1034
1018
|
:host .wrapper .inner-wrapper button:hover {
|
|
1035
|
-
background: var(--wmcolor-
|
|
1019
|
+
background: var(--wmcolor-interactive-background-hover);
|
|
1036
1020
|
box-shadow: none;
|
|
1037
1021
|
}
|
|
1038
1022
|
:host .wrapper .inner-wrapper button:disabled {
|
|
1039
1023
|
pointer-events: none;
|
|
1040
1024
|
box-shadow: none;
|
|
1041
|
-
background-color: var(--wmcolor-
|
|
1025
|
+
background-color: var(--wmcolor-interactive-background-disabled);
|
|
1042
1026
|
}
|
|
1043
1027
|
:host .wrapper .inner-wrapper button:disabled .clock::after {
|
|
1044
|
-
color: var(--wmcolor-
|
|
1028
|
+
color: var(--wmcolor-interactive-disabled);
|
|
1045
1029
|
}
|
|
1046
1030
|
[dir=RTL] :host .wrapper .inner-wrapper button {
|
|
1047
1031
|
right: auto;
|
|
@@ -1105,22 +1089,23 @@
|
|
|
1105
1089
|
cursor: pointer;
|
|
1106
1090
|
position: relative;
|
|
1107
1091
|
padding: 1.25rem;
|
|
1108
|
-
background: var(--wmcolor-
|
|
1092
|
+
background: var(--wmcolor-option-background);
|
|
1109
1093
|
font-family: inherit;
|
|
1110
1094
|
list-style: none;
|
|
1111
|
-
color: var(--wmcolor-
|
|
1095
|
+
color: var(--wmcolor-option-text);
|
|
1112
1096
|
}
|
|
1113
1097
|
:host .wrapper .inner-wrapper .options [role=option]:hover {
|
|
1114
|
-
background: var(--wmcolor-
|
|
1098
|
+
background: var(--wmcolor-option-background-hover);
|
|
1115
1099
|
outline: none;
|
|
1116
1100
|
}
|
|
1117
1101
|
:host .wrapper .inner-wrapper .options [role=option]:focus {
|
|
1118
1102
|
outline: none;
|
|
1119
|
-
|
|
1103
|
+
color: var(--wmcolor-text-ondark);
|
|
1104
|
+
background: var(--wmcolor-interactive-background-focus);
|
|
1120
1105
|
}
|
|
1121
1106
|
:host .wrapper .inner-wrapper .options [role=option]:not(:last-child) {
|
|
1122
1107
|
border-bottom: 2px solid;
|
|
1123
|
-
border-color: var(--wmcolor-
|
|
1108
|
+
border-color: var(--wmcolor-option-border);
|
|
1124
1109
|
}
|
|
1125
1110
|
:host .wrapper .inner-wrapper .options.open {
|
|
1126
1111
|
-ms-transform: scale(1, 1);
|
|
@@ -281,13 +281,13 @@ export class Timepicker {
|
|
|
281
281
|
return this.times.map((time, index) => (h("li", { id: `option${index + 1}`, "data-time": time, role: "option", onClick: () => this.handleOptionClick(time) }, this.reformatTimeInternal("12", time))));
|
|
282
282
|
}
|
|
283
283
|
render() {
|
|
284
|
-
return (h(Host, { key: '
|
|
284
|
+
return (h(Host, { key: '8d1fed516e7969fa0e9684d455ed3bd01e9cd040', onBlur: () => this.close(false) }, h("div", { key: '4cb010201d91dec397fd717848e68c98ebd14106', class: `wrapper label-${this.labelPosition} ${!!this.errorMessage ? "invalid" : ""}`, ref: (t) => (this.tpWrapper = t) }, h("div", { key: 'da58fa1acc6136025158d957e59b45455b5ebeca', class: "label-wrapper" }, this.labelPosition !== "none" && (h("label", { key: '0dcfe28b0917725ed47c3dfb5da1303f137b0ada', id: "label", class: "label", htmlFor: "time-input", onMouseEnter: (ev) => this.handleLabelMouseEnter(ev), onMouseLeave: () => hideTooltip() }, this.label)), this.labelPosition !== "none" && this.requiredField && (h("div", { key: '9ad3ded1b7adc2d3427bfb7170ad8de29675aebd', "aria-hidden": "true", class: "required" }, "*"))), h("div", { key: '6ab239767fbe02e97602ad7b758bc5cc83bdced9' }, h("div", { key: '8d194e417f8af4d3c3af3973fac98cfe44fb10f4', class: "inner-wrapper" }, h("input", { key: '13b6ba2e040cfc5857bcd93381873b75422cad92', id: "time-input", "aria-label": this.label, "aria-describedby": "error", ref: (el) => (this.inputEl = el), onBlur: () => this.handleInputBlur(), onInput: () => (this.value = this.inputEl.value), disabled: this.isDisabled, "aria-required": this.requiredField ? "true" : null, placeholder: this.timeFormat, autocomplete: "off", value: this.value, onFocus: () => this.tpWrapper.classList.add("focus") }), h("button", { key: '01af343694382e726544e6c15fec61ffe8f94a52', id: "btn", ref: (el) => (this.buttonEl = el), disabled: this.isDisabled, "aria-controls": "list", "aria-expanded": this.isExpanded ? "true" : "false", "aria-label": this.buttonAriaLabel, "aria-describedby": "time-input", onClick: () => (this.isExpanded ? this.close() : this.open()),
|
|
285
285
|
// This addresses an issue in Safari, where clicking buttons does not focus them
|
|
286
286
|
// if the button does not receive focus when clicked, Timepicker incorrectly emits a blur event
|
|
287
287
|
onMouseDown: (ev) => {
|
|
288
288
|
ev.preventDefault();
|
|
289
289
|
this.buttonEl.focus();
|
|
290
|
-
} }, h("span", { key: '
|
|
290
|
+
} }, h("span", { key: '9021fa1d31cc4601e36705e23c81bd64a7079de3', class: "svg-icon svg-time" })), h("ul", { key: '070568110a252cfcbeed0db9a650c5aa33f3d6fa', class: `options ${this.isExpanded ? "open" : ""} ${this.openUp ? "upwards" : ""}`, id: "list", role: "listbox", "aria-labelledby": "label", "aria-describedby": this.isExpanded ? "collapsed" : null, tabindex: -1, ref: (el) => (this.optionsEl = el) }, this.renderOptions())), h("div", { key: '219fedbed0146e2dedb2e2bfb2ac8df4d1fa75bf', id: "error", class: "error" }, this.errorMessage)), h("div", { key: 'dd3b6ebb4f17f49ecb18f361500073ab11cbdeac', id: "live-polite", class: "sr-only", "aria-live": "polite", "aria-atomic": "true", ref: (el) => (this.liveRegionEl = el) }))));
|
|
291
291
|
}
|
|
292
292
|
static get is() { return "wm-timepicker"; }
|
|
293
293
|
static get encapsulation() { return "shadow"; }
|
|
@@ -229,11 +229,11 @@ export class Toggletip {
|
|
|
229
229
|
}
|
|
230
230
|
}
|
|
231
231
|
render() {
|
|
232
|
-
return (h(Host, { key: '
|
|
232
|
+
return (h(Host, { key: 'c11bb0162cedb31f4acf39a61319c6827f5ebe75', class: `size-${this.targetSize}` }, h("button", { key: '9560429d4dec4e97069adf77f36ac98cf385087e', ref: (el) => (this.buttonEl = el), class: "button", type: "button", "aria-label": this.label, popoverTarget: "toggletip", popoverTargetAction: "toggle", onClick: () => this.open(),
|
|
233
233
|
// In order to position the tooltip identically to the toggletip, its presence is determined by these four events
|
|
234
|
-
onMouseEnter: () => !this.isOpen && showTooltip(this.toggletipPosition, this.el, this.tooltipMessage), onMouseLeave: () => hideTooltip(), onFocus: () => !this.isOpen && showTooltip(this.toggletipPosition, this.el, this.tooltipMessage), onBlur: () => this.handleBlur() }, this.renderIcon()), h("div", { key: '
|
|
234
|
+
onMouseEnter: () => !this.isOpen && showTooltip(this.toggletipPosition, this.el, this.tooltipMessage), onMouseLeave: () => hideTooltip(), onFocus: () => !this.isOpen && showTooltip(this.toggletipPosition, this.el, this.tooltipMessage), onBlur: () => this.handleBlur() }, this.renderIcon()), h("div", { key: 'f76ca5ac9fc02c2c7de7365a699b73f543ec1efd', popover: "", ref: (el) => (this.toggletipEl = el), class: `toggletip ${this.targetSize} ${this.isHidden ? "hidden" : ""}`, id: "toggletip",
|
|
235
235
|
// @ts-ignore - despite what Typescript says, this is a valid event for popover elements
|
|
236
|
-
onToggle: (ev) => this.handlePopoverToggle(ev) }, this.tooltip), h("div", { key: '
|
|
236
|
+
onToggle: (ev) => this.handlePopoverToggle(ev) }, this.tooltip), h("div", { key: '37c35790aafadbee0ee979ac5b1dcf28a4f29de5', ref: (el) => (this.liveRegionEl = el), class: "live-region sr-only", role: "status", "aria-live": "polite", "aria-atomic": "true" })));
|
|
237
237
|
}
|
|
238
238
|
static get is() { return "wm-toggletip"; }
|
|
239
239
|
static get encapsulation() { return "shadow"; }
|
|
@@ -5,7 +5,6 @@ export class Uploader {
|
|
|
5
5
|
constructor() {
|
|
6
6
|
this.batchCount = 0; // used to calculate the aggregate upload progress
|
|
7
7
|
this.prevUploadCount = 0; // comparison to determine whether or not to announce updated count
|
|
8
|
-
this.fileIdToDelete = "";
|
|
9
8
|
this.label = undefined;
|
|
10
9
|
this.uploaderType = "select";
|
|
11
10
|
this.dropArea = "component";
|
|
@@ -49,8 +48,27 @@ export class Uploader {
|
|
|
49
48
|
handleFileErrorCleared() {
|
|
50
49
|
this.uploadButtonEl.focus();
|
|
51
50
|
}
|
|
52
|
-
|
|
53
|
-
this.
|
|
51
|
+
handleFileDelete(ev) {
|
|
52
|
+
const focusableFileEls = this.fileEls.filter((file) => !!file.fileActions);
|
|
53
|
+
this.deletedEl = ev.target;
|
|
54
|
+
const index = focusableFileEls.indexOf(this.deletedEl);
|
|
55
|
+
// actual focus will called only after el is removed from DOM
|
|
56
|
+
if (focusableFileEls.length === 1) {
|
|
57
|
+
// it was the only item, focus the upload button
|
|
58
|
+
this.elToFocusOnDelete = this.uploadButtonEl;
|
|
59
|
+
}
|
|
60
|
+
else if (index === focusableFileEls.length - 1) {
|
|
61
|
+
// it's the last item, focus the previous file
|
|
62
|
+
const fileToFocus = focusableFileEls[index - 1];
|
|
63
|
+
const fileActionButtons = fileToFocus.shadowRoot.querySelectorAll("wm-button");
|
|
64
|
+
this.elToFocusOnDelete = fileActionButtons[fileActionButtons.length - 1];
|
|
65
|
+
}
|
|
66
|
+
else {
|
|
67
|
+
// otherwise focus the next file
|
|
68
|
+
const fileToFocus = focusableFileEls[index + 1];
|
|
69
|
+
const fileActionButtons = fileToFocus.shadowRoot.querySelectorAll("wm-button");
|
|
70
|
+
this.elToFocusOnDelete = fileActionButtons[fileActionButtons.length - 1];
|
|
71
|
+
}
|
|
54
72
|
}
|
|
55
73
|
announceError() {
|
|
56
74
|
if (this.errorMessage) {
|
|
@@ -145,11 +163,13 @@ export class Uploader {
|
|
|
145
163
|
}
|
|
146
164
|
else if (mutationRecord.type === "childList") {
|
|
147
165
|
// if user prompted the removal of a single file (they hit the delete button)
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
this.
|
|
166
|
+
// re-assigning focus handled here because component shouldn't assume the node removal based on the event firing
|
|
167
|
+
const removedEls = mutationRecord.removedNodes;
|
|
168
|
+
const removedEl = removedEls[0];
|
|
169
|
+
if (removedEls.length === 1 && removedEl === this.deletedEl && this.elToFocusOnDelete) {
|
|
170
|
+
this.elToFocusOnDelete.focus();
|
|
171
|
+
this.deletedEl = null;
|
|
172
|
+
this.elToFocusOnDelete = null;
|
|
153
173
|
}
|
|
154
174
|
// on added wm-files, if wm-file has an error, announce
|
|
155
175
|
if (mutationRecord.addedNodes.length > 0) {
|
|
@@ -193,23 +213,6 @@ export class Uploader {
|
|
|
193
213
|
}, 20 * 1000);
|
|
194
214
|
}
|
|
195
215
|
}
|
|
196
|
-
focusAfterFileRemoval(mutationRecord) {
|
|
197
|
-
let previousSibling = mutationRecord.previousSibling;
|
|
198
|
-
// .previousSibling can sometimes grab #text nodes but unfortunately mutationRecord does not hold .previousElementSibling
|
|
199
|
-
// so we need to loop upwards until we find a wm-file with a button to focus, or null
|
|
200
|
-
while (previousSibling &&
|
|
201
|
-
!(previousSibling.nodeName === "WM-FILE" &&
|
|
202
|
-
previousSibling.shadowRoot.querySelector("wm-button"))) {
|
|
203
|
-
previousSibling = previousSibling.previousSibling;
|
|
204
|
-
}
|
|
205
|
-
if (previousSibling) {
|
|
206
|
-
const fileActionButtons = previousSibling.shadowRoot.querySelectorAll("wm-button");
|
|
207
|
-
fileActionButtons[fileActionButtons.length - 1].focus();
|
|
208
|
-
}
|
|
209
|
-
else {
|
|
210
|
-
this.uploadButtonEl.focus();
|
|
211
|
-
}
|
|
212
|
-
}
|
|
213
216
|
handleUploadButtonClick(ev) {
|
|
214
217
|
if (this.isDisabled) {
|
|
215
218
|
// this is a temporary fix.
|
|
@@ -313,9 +316,9 @@ export class Uploader {
|
|
|
313
316
|
return (h("div", { class: `drop-area -${this.dropArea}`, ref: (el) => (this.dropAreaEl = el), onDragEnter: (ev) => this.handleDragEnter(ev), onDragOver: (ev) => this.handleDragOver(ev), onDragLeave: (ev) => this.handleDragLeave(ev), onDrop: (ev) => this.handleDrop(ev) }, this.dropArea == "page" && (h("div", { ref: (el) => (this.dropOverlayEl = el), class: "drop-overlay", popover: "manual" }, h("span", { class: "upload-arrow" }), h("span", null, "Drop to Upload")))));
|
|
314
317
|
}
|
|
315
318
|
render() {
|
|
316
|
-
return (h(Host, { key: '
|
|
319
|
+
return (h(Host, { key: 'd00c00331919db5cfc64993ff9994af5412d5de7', class: `-${this.dropArea}` }, this.uploaderType == "drop" && this.renderDropArea(), this.label && this.renderLabel(), this.renderHeader(), this.renderListContainer(), h("div", { key: 'f7013a127e18f9de001ca3b47d4c320e2718accf', ref: (el) => (this.assertiveLiveRegionEl = el), class: "live-region sr-only", "aria-live": "assertive" // since it's directly linked to the action the user took, it should be read in priority. With polite, some messages get dismissed in favor of the page title
|
|
317
320
|
,
|
|
318
|
-
"aria-atomic": "true" }), h("div", { key: '
|
|
321
|
+
"aria-atomic": "true" }), h("div", { key: '535047222b8d454c5fdbd0183b2259714f21a5ad', ref: (el) => (this.politeLiveRegionEl = el), class: "live-region sr-only", "aria-live": "polite", "aria-atomic": "true" })));
|
|
319
322
|
}
|
|
320
323
|
static get is() { return "wm-uploader"; }
|
|
321
324
|
static get encapsulation() { return "shadow"; }
|
|
@@ -583,7 +586,7 @@ export class Uploader {
|
|
|
583
586
|
"passive": false
|
|
584
587
|
}, {
|
|
585
588
|
"name": "wmFileDelete",
|
|
586
|
-
"method": "
|
|
589
|
+
"method": "handleFileDelete",
|
|
587
590
|
"target": undefined,
|
|
588
591
|
"capture": false,
|
|
589
592
|
"passive": false
|
|
@@ -750,6 +750,15 @@ export function dateToISO(date) {
|
|
|
750
750
|
.toString()
|
|
751
751
|
.padStart(2, "0")}`;
|
|
752
752
|
}
|
|
753
|
+
export function clampDate(isoDate) {
|
|
754
|
+
// clamp the day to the maximum number of days in the month
|
|
755
|
+
const y = dateFind.year.asInt(isoDate);
|
|
756
|
+
const m = dateFind.month.asInt(isoDate);
|
|
757
|
+
const d = dateFind.day.asInt(isoDate);
|
|
758
|
+
const maxDays = getMonthLength(m, y);
|
|
759
|
+
const clampedDay = Math.min(d, maxDays);
|
|
760
|
+
return makeISO(y, m, clampedDay);
|
|
761
|
+
}
|
|
753
762
|
function splitISO(isoDate) {
|
|
754
763
|
const [year, month, day] = isoDate.split("-");
|
|
755
764
|
return {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h } from './index-130e07bb.js';
|
|
2
|
-
import { i as intl, c as checkForActiveElInShadow, e as safeMultiplyFloat, f as getPosition } from './functions-
|
|
2
|
+
import { i as intl, c as checkForActiveElInShadow, e as safeMultiplyFloat, f as getPosition } from './functions-14aaf49d.js';
|
|
3
3
|
|
|
4
4
|
const colors = {
|
|
5
5
|
salmon: "#ff5f4e",
|