@watermarkinsights/ripple 3.27.0 → 3.27.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/README.md +3 -3
- package/dist/cjs/{chartFunctions-b2e0cb4e.js → chartFunctions-42cfb4d3.js} +596 -596
- package/dist/cjs/{functions-9807717e.js → functions-85c3c557.js} +498 -498
- package/dist/cjs/{global-42a24725.js → global-9982752f.js} +72 -72
- package/dist/cjs/{http-service-9e8c4dd5.js → http-service-494d81de.js} +49 -49
- package/dist/cjs/{interfaces-30a74c1f.js → interfaces-a3338581.js} +29 -29
- package/dist/cjs/{intl-526c75ec.js → intl-1c36fe38.js} +131 -131
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/priv-chart-popover.cjs.entry.js +91 -91
- package/dist/cjs/priv-datepicker.cjs.entry.js +657 -657
- package/dist/cjs/priv-navigator-button.cjs.entry.js +19 -19
- package/dist/cjs/priv-navigator-item.cjs.entry.js +23 -23
- package/dist/cjs/ripple.cjs.js +1 -1
- package/dist/cjs/wm-action-menu_2.cjs.entry.js +334 -334
- package/dist/cjs/wm-button.cjs.entry.js +189 -189
- package/dist/cjs/wm-chart-slice.cjs.entry.js +18 -18
- package/dist/cjs/wm-chart.cjs.entry.js +183 -183
- package/dist/cjs/wm-datepicker.cjs.entry.js +263 -263
- package/dist/cjs/wm-file-list.cjs.entry.js +35 -35
- package/dist/cjs/wm-file.cjs.entry.js +181 -181
- package/dist/cjs/wm-input.cjs.entry.js +136 -136
- package/dist/cjs/wm-modal-footer.cjs.entry.js +33 -33
- package/dist/cjs/wm-modal-header.cjs.entry.js +32 -32
- package/dist/cjs/wm-modal.cjs.entry.js +152 -152
- package/dist/cjs/wm-navigation_3.cjs.entry.js +186 -186
- package/dist/cjs/wm-navigator.cjs.entry.js +264 -264
- package/dist/cjs/wm-network-uploader.cjs.entry.js +465 -465
- package/dist/cjs/wm-option_2.cjs.entry.js +768 -768
- package/dist/cjs/wm-pagination.cjs.entry.js +179 -179
- package/dist/cjs/wm-progress-indicator_3.cjs.entry.js +155 -155
- package/dist/cjs/wm-search.cjs.entry.js +184 -184
- package/dist/cjs/wm-snackbar.cjs.entry.js +134 -134
- package/dist/cjs/wm-tab-item_3.cjs.entry.js +264 -264
- package/dist/cjs/wm-tag-input-row.cjs.entry.js +14 -14
- package/dist/cjs/wm-tag-input.cjs.entry.js +948 -941
- package/dist/cjs/wm-timepicker.cjs.entry.js +385 -385
- package/dist/cjs/wm-toggletip.cjs.entry.js +120 -120
- package/dist/cjs/wm-uploader.cjs.entry.js +441 -441
- package/dist/cjs/wm-wrapper.cjs.entry.js +12 -12
- package/dist/collection/components/charts/chartFunctions.js +562 -562
- package/dist/collection/components/charts/priv-chart-popover/priv-chart-popover.js +267 -267
- package/dist/collection/components/charts/wm-chart/wm-chart-slice.js +125 -125
- package/dist/collection/components/charts/wm-chart/wm-chart.js +450 -450
- package/dist/collection/components/charts/wm-progress-monitor/wm-progress-indicator.js +207 -207
- package/dist/collection/components/charts/wm-progress-monitor/wm-progress-monitor.js +143 -143
- package/dist/collection/components/charts/wm-progress-monitor/wm-progress-slice.js +121 -121
- package/dist/collection/components/wm-action-menu/wm-action-menu.js +472 -472
- package/dist/collection/components/wm-button/wm-button.js +486 -486
- package/dist/collection/components/wm-datepicker/priv-datepicker/priv-datepicker.js +983 -983
- package/dist/collection/components/wm-datepicker/wm-datepicker.js +491 -491
- package/dist/collection/components/wm-file/wm-file.js +313 -313
- package/dist/collection/components/wm-file-list/wm-file-list.js +152 -152
- package/dist/collection/components/wm-input/wm-input.js +509 -509
- package/dist/collection/components/wm-menuitem/wm-menuitem.js +454 -454
- package/dist/collection/components/wm-modal/wm-modal-footer.js +138 -138
- package/dist/collection/components/wm-modal/wm-modal-header.js +82 -82
- package/dist/collection/components/wm-modal/wm-modal.js +462 -462
- package/dist/collection/components/wm-navigation/wm-navigation-hamburger.js +119 -119
- package/dist/collection/components/wm-navigation/wm-navigation-item.js +130 -130
- package/dist/collection/components/wm-navigation/wm-navigation.js +217 -217
- package/dist/collection/components/wm-navigator/priv-navigator-button/priv-navigator-button.js +106 -106
- package/dist/collection/components/wm-navigator/priv-navigator-item/priv-navigator-item.js +123 -123
- package/dist/collection/components/wm-navigator/wm-navigator.js +467 -467
- package/dist/collection/components/wm-option/wm-option.js +435 -435
- package/dist/collection/components/wm-pagination/wm-pagination.js +362 -362
- package/dist/collection/components/wm-search/wm-search.js +439 -439
- package/dist/collection/components/wm-select/wm-select.js +1054 -1054
- package/dist/collection/components/wm-snackbar/wm-snackbar.js +267 -267
- package/dist/collection/components/wm-tabs/wm-tab-item/wm-tab-item.js +211 -211
- package/dist/collection/components/wm-tabs/wm-tab-list/wm-tab-list.js +327 -327
- package/dist/collection/components/wm-tabs/wm-tab-panel/wm-tab-panel.js +108 -108
- package/dist/collection/components/wm-tag-input/wm-tag-input-row/wm-tag-input-row.js +122 -122
- package/dist/collection/components/wm-tag-input/wm-tag-input.css +21 -17
- package/dist/collection/components/wm-tag-input/wm-tag-input.js +1302 -1295
- package/dist/collection/components/wm-timepicker/wm-timepicker.js +605 -605
- package/dist/collection/components/wm-toggletip/wm-toggletip.js +243 -243
- package/dist/collection/components/wm-uploader/wm-network-uploader/wm-network-uploader.js +772 -772
- package/dist/collection/components/wm-uploader/wm-uploader.js +964 -964
- package/dist/collection/components/wm-wrapper/wm-wrapper.js +28 -28
- package/dist/collection/dev/scripts.js +20 -20
- package/dist/collection/global/__mocks__/functions.js +6 -6
- package/dist/collection/global/functions.js +541 -541
- package/dist/collection/global/global.js +79 -79
- package/dist/collection/global/interfaces.js +49 -49
- package/dist/collection/global/intl.js +132 -132
- package/dist/collection/global/services/__mocks__/http-service.js +130 -130
- package/dist/collection/global/services/http-service.js +50 -50
- package/dist/collection/lang/lang.js +5 -5
- package/dist/collection/lang/missing.js +43 -43
- package/dist/collection/lang/piglatin.js +93 -93
- package/dist/esm/{chartFunctions-dd9eb9ac.js → chartFunctions-0b53b301.js} +596 -596
- package/dist/esm/{functions-f32b1ca4.js → functions-cbb19d50.js} +498 -498
- package/dist/esm/{global-7ee0d78d.js → global-2c7bbfe6.js} +72 -72
- package/dist/esm/{http-service-5d037e16.js → http-service-3dc3b3e7.js} +49 -49
- package/dist/esm/{interfaces-61c6305b.js → interfaces-2b97fab2.js} +29 -29
- package/dist/esm/{intl-d101e1a9.js → intl-ffbca53d.js} +131 -131
- package/dist/esm/loader.js +1 -1
- package/dist/esm/polyfills/core-js.js +0 -0
- package/dist/esm/polyfills/dom.js +0 -0
- package/dist/esm/polyfills/es5-html-element.js +0 -0
- package/dist/esm/polyfills/index.js +0 -0
- package/dist/esm/polyfills/system.js +0 -0
- package/dist/esm/priv-chart-popover.entry.js +91 -91
- package/dist/esm/priv-datepicker.entry.js +657 -657
- package/dist/esm/priv-navigator-button.entry.js +19 -19
- package/dist/esm/priv-navigator-item.entry.js +23 -23
- package/dist/esm/ripple.js +1 -1
- package/dist/esm/wm-action-menu_2.entry.js +334 -334
- package/dist/esm/wm-button.entry.js +189 -189
- package/dist/esm/wm-chart-slice.entry.js +18 -18
- package/dist/esm/wm-chart.entry.js +183 -183
- package/dist/esm/wm-datepicker.entry.js +263 -263
- package/dist/esm/wm-file-list.entry.js +35 -35
- package/dist/esm/wm-file.entry.js +181 -181
- package/dist/esm/wm-input.entry.js +136 -136
- package/dist/esm/wm-modal-footer.entry.js +33 -33
- package/dist/esm/wm-modal-header.entry.js +32 -32
- package/dist/esm/wm-modal.entry.js +152 -152
- package/dist/esm/wm-navigation_3.entry.js +186 -186
- package/dist/esm/wm-navigator.entry.js +264 -264
- package/dist/esm/wm-network-uploader.entry.js +465 -465
- package/dist/esm/wm-option_2.entry.js +768 -768
- package/dist/esm/wm-pagination.entry.js +179 -179
- package/dist/esm/wm-progress-indicator_3.entry.js +155 -155
- package/dist/esm/wm-search.entry.js +184 -184
- package/dist/esm/wm-snackbar.entry.js +134 -134
- package/dist/esm/wm-tab-item_3.entry.js +264 -264
- package/dist/esm/wm-tag-input-row.entry.js +14 -14
- package/dist/esm/wm-tag-input.entry.js +948 -941
- package/dist/esm/wm-timepicker.entry.js +385 -385
- package/dist/esm/wm-toggletip.entry.js +120 -120
- package/dist/esm/wm-uploader.entry.js +441 -441
- package/dist/esm/wm-wrapper.entry.js +12 -12
- package/dist/esm-es5/{chartFunctions-dd9eb9ac.js → chartFunctions-0b53b301.js} +1 -1
- package/dist/esm-es5/{global-7ee0d78d.js → global-2c7bbfe6.js} +1 -1
- package/dist/esm-es5/{intl-d101e1a9.js → intl-ffbca53d.js} +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/priv-chart-popover.entry.js +1 -1
- package/dist/esm-es5/priv-datepicker.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-datepicker.entry.js +1 -1
- package/dist/esm-es5/wm-file.entry.js +1 -1
- package/dist/esm-es5/wm-input.entry.js +1 -1
- package/dist/esm-es5/wm-modal-header.entry.js +1 -1
- package/dist/esm-es5/wm-modal.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-network-uploader.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-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-725c14b0.system.entry.js → p-00022d17.system.entry.js} +1 -1
- package/dist/ripple/{p-b97de06f.system.entry.js → p-0450cdbe.system.entry.js} +1 -1
- package/dist/ripple/{p-bfe1062d.entry.js → p-05a17658.entry.js} +1 -1
- package/dist/ripple/p-0b6a7b77.system.entry.js +1 -0
- package/dist/ripple/{p-b6bf2866.entry.js → p-0e789be7.entry.js} +1 -1
- package/dist/ripple/{p-b617b64f.system.entry.js → p-15779c22.system.entry.js} +1 -1
- package/dist/ripple/{p-04faca6b.entry.js → p-17487f1b.entry.js} +1 -1
- package/dist/ripple/{p-122da0d1.system.entry.js → p-197c83de.system.entry.js} +1 -1
- package/dist/ripple/{p-11d98b00.system.entry.js → p-1bad4efe.system.entry.js} +1 -1
- package/dist/ripple/{p-252ba295.system.entry.js → p-2ff923ee.system.entry.js} +1 -1
- package/dist/ripple/{p-a6afe65a.entry.js → p-31712996.entry.js} +1 -1
- package/dist/ripple/{p-f69276d5.system.entry.js → p-31c18f5e.system.entry.js} +1 -1
- package/dist/ripple/{p-df28f438.system.js → p-32944b70.system.js} +1 -1
- package/dist/ripple/{p-73d277ba.system.entry.js → p-36effc40.system.entry.js} +1 -1
- package/dist/ripple/{p-0be94e77.entry.js → p-3807bcae.entry.js} +1 -1
- package/dist/ripple/{p-88d17f6b.system.entry.js → p-3aa48fad.system.entry.js} +1 -1
- package/dist/ripple/{p-82a97531.system.entry.js → p-419f133c.system.entry.js} +1 -1
- package/dist/ripple/{p-13ec8ac0.entry.js → p-438a1e8e.entry.js} +1 -1
- package/dist/ripple/{p-19689aac.js → p-4698b365.js} +1 -1
- package/dist/ripple/{p-f8d45250.system.entry.js → p-54086f7b.system.entry.js} +1 -1
- package/dist/ripple/{p-47f53321.entry.js → p-5497694c.entry.js} +1 -1
- package/dist/ripple/{p-fb370a69.entry.js → p-58fbf116.entry.js} +1 -1
- package/dist/ripple/{p-14dfc4e7.entry.js → p-65a741c1.entry.js} +1 -1
- package/dist/ripple/{p-ac63b3aa.entry.js → p-7e74274b.entry.js} +1 -1
- package/dist/ripple/{p-81752607.system.js → p-81ad3fe5.system.js} +1 -1
- package/dist/ripple/{p-f3e42327.system.entry.js → p-89db9c27.system.entry.js} +1 -1
- package/dist/ripple/{p-4753fbfc.system.entry.js → p-947f01e2.system.entry.js} +1 -1
- package/dist/ripple/{p-3aee75e7.entry.js → p-978429f9.entry.js} +1 -1
- package/dist/ripple/{p-2c8fd902.system.entry.js → p-97d5b4bd.system.entry.js} +1 -1
- package/dist/ripple/{p-67c0ad56.system.entry.js → p-9d6a574b.system.entry.js} +1 -1
- package/dist/ripple/{p-c545fe1c.entry.js → p-a3ba2bdd.entry.js} +1 -1
- package/dist/ripple/{p-c7567fd3.entry.js → p-a42f5231.entry.js} +1 -1
- package/dist/ripple/p-a51aec3f.entry.js +1 -0
- package/dist/ripple/{p-b831988d.entry.js → p-a5b86b47.entry.js} +1 -1
- package/dist/ripple/{p-4cadf985.entry.js → p-a90b8a08.entry.js} +1 -1
- package/dist/ripple/{p-d9b66dca.system.entry.js → p-aabe172c.system.entry.js} +1 -1
- package/dist/ripple/{p-69121ad1.entry.js → p-ab2a0aee.entry.js} +1 -1
- package/dist/ripple/{p-5fb0aa58.js → p-aed93a25.js} +1 -1
- package/dist/ripple/{p-f39ee84b.entry.js → p-b2d75e7d.entry.js} +1 -1
- package/dist/ripple/{p-19b897ce.js → p-b410c675.js} +1 -1
- package/dist/ripple/{p-4809e419.system.entry.js → p-b6f558f7.system.entry.js} +1 -1
- package/dist/ripple/p-bb048fe7.entry.js +1 -0
- package/dist/ripple/{p-2805fed6.system.entry.js → p-bced37cf.system.entry.js} +1 -1
- package/dist/ripple/{p-c9a1834d.system.entry.js → p-bd0c1e7c.system.entry.js} +1 -1
- package/dist/ripple/{p-89f1991f.entry.js → p-c0e183f4.entry.js} +1 -1
- package/dist/ripple/{p-7eca18bd.system.entry.js → p-c27eda00.system.entry.js} +1 -1
- package/dist/ripple/{p-894bc6c4.system.entry.js → p-cd3e0b8b.system.entry.js} +1 -1
- package/dist/ripple/{p-f6b2e4ac.system.js → p-d1af63b5.system.js} +1 -1
- package/dist/ripple/{p-30572b71.system.js → p-d41ba263.system.js} +1 -1
- package/dist/ripple/{p-db7e6e89.entry.js → p-d8993992.entry.js} +1 -1
- package/dist/ripple/{p-f13b239c.system.entry.js → p-da525ed1.system.entry.js} +1 -1
- package/dist/ripple/{p-33af1eee.entry.js → p-e6f46289.entry.js} +1 -1
- package/dist/ripple/{p-e928f350.entry.js → p-fc967b2c.entry.js} +1 -1
- package/dist/ripple/ripple.esm.js +1 -1
- package/dist/ripple/ripple.js +1 -1
- package/dist/types/components/charts/chartFunctions.d.ts +37 -37
- package/dist/types/components/charts/priv-chart-popover/priv-chart-popover.d.ts +27 -27
- package/dist/types/components/charts/wm-chart/wm-chart-slice.d.ts +11 -11
- package/dist/types/components/charts/wm-chart/wm-chart.d.ts +47 -47
- package/dist/types/components/charts/wm-progress-monitor/wm-progress-indicator.d.ts +29 -29
- package/dist/types/components/charts/wm-progress-monitor/wm-progress-monitor.d.ts +20 -20
- package/dist/types/components/charts/wm-progress-monitor/wm-progress-slice.d.ts +10 -10
- package/dist/types/components/wm-action-menu/wm-action-menu.d.ts +49 -49
- package/dist/types/components/wm-button/wm-button.d.ts +44 -44
- package/dist/types/components/wm-datepicker/priv-datepicker/priv-datepicker.d.ts +80 -80
- package/dist/types/components/wm-datepicker/wm-datepicker.d.ts +42 -42
- package/dist/types/components/wm-file/wm-file.d.ts +40 -40
- package/dist/types/components/wm-file-list/wm-file-list.d.ts +16 -16
- package/dist/types/components/wm-input/wm-input.d.ts +57 -57
- package/dist/types/components/wm-menuitem/wm-menuitem.d.ts +34 -34
- package/dist/types/components/wm-modal/wm-modal-footer.d.ts +14 -14
- package/dist/types/components/wm-modal/wm-modal-header.d.ts +10 -10
- package/dist/types/components/wm-modal/wm-modal.d.ts +40 -40
- package/dist/types/components/wm-navigation/wm-navigation-hamburger.d.ts +16 -16
- package/dist/types/components/wm-navigation/wm-navigation-item.d.ts +13 -13
- package/dist/types/components/wm-navigation/wm-navigation.d.ts +26 -26
- package/dist/types/components/wm-navigator/priv-navigator-button/priv-navigator-button.d.ts +10 -10
- package/dist/types/components/wm-navigator/priv-navigator-item/priv-navigator-item.d.ts +13 -13
- package/dist/types/components/wm-navigator/wm-navigator.d.ts +61 -61
- package/dist/types/components/wm-option/wm-option.d.ts +34 -34
- package/dist/types/components/wm-pagination/wm-pagination.d.ts +32 -32
- package/dist/types/components/wm-search/wm-search.d.ts +77 -77
- package/dist/types/components/wm-select/wm-select.d.ts +101 -101
- package/dist/types/components/wm-snackbar/wm-snackbar.d.ts +30 -30
- package/dist/types/components/wm-tabs/wm-tab-item/wm-tab-item.d.ts +37 -37
- package/dist/types/components/wm-tabs/wm-tab-list/wm-tab-list.d.ts +52 -52
- package/dist/types/components/wm-tabs/wm-tab-panel/wm-tab-panel.d.ts +20 -20
- package/dist/types/components/wm-tag-input/wm-tag-input-row/wm-tag-input-row.d.ts +11 -11
- package/dist/types/components/wm-tag-input/wm-tag-input.d.ts +137 -136
- package/dist/types/components/wm-timepicker/wm-timepicker.d.ts +62 -62
- package/dist/types/components/wm-toggletip/wm-toggletip.d.ts +25 -25
- package/dist/types/components/wm-uploader/wm-network-uploader/wm-network-uploader.d.ts +85 -85
- package/dist/types/components/wm-uploader/wm-uploader.d.ts +99 -99
- package/dist/types/components/wm-wrapper/wm-wrapper.d.ts +7 -7
- package/dist/types/components.d.ts +27 -27
- package/dist/types/global/__mocks__/functions.d.ts +6 -6
- package/dist/types/global/functions.d.ts +40 -40
- package/dist/types/global/global.d.ts +1 -1
- package/dist/types/global/interfaces.d.ts +74 -74
- package/dist/types/global/intl.d.ts +29 -29
- package/dist/types/global/services/__mocks__/http-service.d.ts +6 -6
- package/dist/types/global/services/http-service.d.ts +4 -4
- package/dist/types/lang/lang.d.ts +5 -5
- package/package.json +46 -46
- package/dist/ripple/p-37de8e2f.entry.js +0 -1
- package/dist/ripple/p-b378e064.system.entry.js +0 -1
- package/dist/ripple/p-d2037549.entry.js +0 -1
- /package/dist/esm-es5/{functions-f32b1ca4.js → functions-cbb19d50.js} +0 -0
- /package/dist/esm-es5/{http-service-5d037e16.js → http-service-3dc3b3e7.js} +0 -0
- /package/dist/esm-es5/{interfaces-61c6305b.js → interfaces-2b97fab2.js} +0 -0
- /package/dist/ripple/{p-888bec42.js → p-43f1298b.js} +0 -0
- /package/dist/ripple/{p-cfa80f5b.js → p-91480a89.js} +0 -0
- /package/dist/ripple/{p-313b6073.system.js → p-9d02957d.system.js} +0 -0
- /package/dist/ripple/{p-9eb5a71e.system.js → p-b267e710.system.js} +0 -0
- /package/dist/ripple/{p-08b7ec08.system.js → p-f5df5903.system.js} +0 -0
- /package/dist/ripple/{p-a6d6eae7.js → p-fd8070fb.js} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as e,h as i,H as s,g as o,f as r}from"./p-b5dee715.js";import{i as n,d as a,g as l,m as h,w as p}from"./p-cfa80f5b.js";import{g as d}from"./p-19689aac.js";const c=class{constructor(i){t(this,i),this.wmOptionSelected=e(this,"wmOptionSelected",7),this.wmKeyUpPressed=e(this,"wmKeyUpPressed",7),this.wmKeyDownPressed=e(this,"wmKeyDownPressed",7),this.wmEscKeyPressed=e(this,"wmEscKeyPressed",7),this.wmHomeKeyPressed=e(this,"wmHomeKeyPressed",7),this.wmEndKeyPressed=e(this,"wmEndKeyPressed",7),this.wmEnterKeyPressed=e(this,"wmEnterKeyPressed",7),this.wmLetterPressed=e(this,"wmLetterPressed",7),this.wmOptionBlurred=e(this,"wmOptionBlurred",7),this.value=void 0,this.subinfo=void 0,this.disabled=!1,this.selected=!1,this.focused=!1,this.searchTerm=""}get hostClasses(){let t=[];return this.subinfo&&t.push("hassubinfo"),this.parentSelectEl.multiple&&t.push("multi-option"),this.el.textContent.toLowerCase().includes(this.searchTerm)||t.push("filtered-out"),t.join(" ")}get parentSelectEl(){var t;return"WM-SELECT"!==(null===(t=this.el.parentElement)||void 0===t?void 0:t.nodeName)?this.el.getRootNode().host:this.el.parentElement}handleKeydown(t){switch(t.key){case"ArrowUp":t.preventDefault(),this.wmKeyUpPressed.emit(this.el);break;case"ArrowDown":t.preventDefault(),this.wmKeyDownPressed.emit(this.el);break;case"Enter":t.preventDefault(),this.disabled||(this.el.click(),this.wmEnterKeyPressed.emit(this.el));break;case" ":t.preventDefault(),this.el.click();break;case"Escape":t.preventDefault(),t.stopPropagation(),this.wmEscKeyPressed.emit();break;case"Home":t.preventDefault(),this.wmHomeKeyPressed.emit();break;case"End":t.preventDefault(),this.wmEndKeyPressed.emit();break;default:1===t.key.length&&this.wmLetterPressed.emit(t.key)}}handleSelection(){this.disabled||this.wmOptionSelected.emit(this.el)}handleBlur(t){this.wmOptionBlurred.emit({relatedTarget:t.relatedTarget})}syncAriaSelected(){this.selected?this.el.setAttribute("aria-selected","true"):this.el.removeAttribute("aria-selected")}syncAriaDisabled(){this.disabled?this.el.setAttribute("aria-disabled","true"):this.el.removeAttribute("aria-disabled")}updateDisabledOnClick(){this.disabled&&this.el.onclick?(this.onClickFunc=this.el.onclick,this.el.onclick=null):!this.disabled&&this.onClickFunc&&(this.el.onclick=this.onClickFunc)}handleSearch(t){if(this.searchTerm=t.detail.searchTerm.toLowerCase(),this.searchTerm){const t=new RegExp(`${this.searchTerm}`,"gi"),e=this.el.textContent.replace(t,(t=>`<strong>${t}</strong>`));this.textEl.innerHTML=e}else this.textEl.innerHTML=this.el.textContent}componentWillLoad(){this.syncAriaSelected(),this.syncAriaDisabled(),this.updateDisabledOnClick(),this.parentSelectEl.addEventListener("wmSelectSearchChanged",(t=>this.handleSearch(t)))}render(){return i(s,{role:"option",tabindex:this.focused?0:-1,class:this.hostClasses},i("div",{class:"option-wrapper "+(this.parentSelectEl.multiple?"checkbox":"")},i("span",{"aria-hidden":"true",ref:t=>this.textEl=t},this.el.textContent),i("span",{class:"sr-only"},this.el.textContent)),i("div",{class:"subinfo"},this.subinfo))}get el(){return o(this)}static get watchers(){return{selected:["syncAriaSelected"],disabled:["syncAriaDisabled","updateDisabledOnClick"]}}};c.style=':host(:not(:last-child)),wm-option:not(:last-child){border-bottom:2px solid rgba(46, 27, 70, 0.05)}:host,wm-option{display:block;cursor:pointer;position:relative;padding:1.25rem;background:#fff;font-family:inherit;list-style:none;color:#4a4a4a;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}:host:focus,:host.focus,wm-option:focus,wm-option.focus{outline:none;background:#f4f4f4}:host.icon,wm-option.icon{color:#575195}:host .sr-only,wm-option .sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}.checkbox:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f131";display:inline-block;margin-right:0.25rem;color:#575195}:host([aria-selected=true]),wm-option[aria-selected=true]{background:rgba(46, 27, 70, 0.05);font-weight:500}:host([aria-selected=true]) .checkbox:before,wm-option[aria-selected=true] .checkbox:before{content:"\\f132"}:host([aria-disabled=true]),wm-option[aria-disabled=true]{font-style:italic;color:#6b6b6b;cursor:default}:host([aria-disabled=true]) .checkbox:before,wm-option[aria-disabled=true] .checkbox:before{color:#6b6b6b}:host(.multi-option),wm-option.multi-option{background:unset}:host(.hidden),wm-option.hidden,:host(.filtered-out),wm-option.filtered-out{display:none}:host(.duplicate.last),wm-option.duplicate.last{border-bottom:12px solid rgba(46, 27, 70, 0.05)}:host(.hassubinfo),wm-option.hassubinfo{display:-ms-flexbox;display:flex}:host(.hassubinfo) .option-wrapper,wm-option.hassubinfo .option-wrapper{-ms-flex:1;flex:1}:host(.hassubinfo) .subinfo,wm-option.hassubinfo .subinfo{-ms-flex:none;flex:none}.subinfo{font-style:italic}.option-wrapper{display:inline-block}::slotted{font-family:inherit}::slotted(i){font-size:0.875rem}::slotted(i):before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;display:inline-block;margin-right:0.625rem;pointer-events:none}:host(:focus),wm-option:focus{outline:none;background:#f4f4f4}:host(:hover){background:#f4f4f4;outline:none}';const b=class{constructor(i){t(this,i),this.wmSelectDidLoad=e(this,"wmSelectDidLoad",7),this.wmSelectBlurred=e(this,"wmSelectBlurred",7),this.wmSelectChanged=e(this,"wmSelectChanged",7),this.wmComponentBlurred=e(this,"wmComponentBlurred",7),this.wmSelectSearchChanged=e(this,"wmSelectSearchChanged",7),this.selectAllMessage=n.formatMessage({id:"select.selectAll",defaultMessage:"Select All"}),this.deselectAllMessage=n.formatMessage({id:"select.deselectAll",defaultMessage:"Deselect All"}),this.allOptionsSelectedMessage=n.formatMessage({id:"select.allOptionsSelected",defaultMessage:"All options selected"}),this.allOptionsDeselectedMessage=n.formatMessage({id:"select.allOptionsDeselected",defaultMessage:"All options deselected"}),this.keysSoFar="",this.searchIndex=0,this.openUp=!1,this.overflowCount=0,this.displayedOptions=[],this.debouncedClearKeysSoFar=a((()=>{this.keysSoFar=""}),500),this.debouncedSearch=a((()=>{this.wmSelectSearchChanged.emit({searchTerm:this.searchTerm}),this.announce(this.filteredOptions.length?this.resultsFoundMessage:this.noResultsFoundMessage)}),150),this.disabled=!1,this.invalid=!1,this.maxHeight=void 0,this.label=void 0,this.labelPosition="top",this.requiredField=!1,this.errorMessage="",this.multiple=!1,this.search=!1,this.selectAll=!1,this.placeholder=n.formatMessage({id:"select.multiPlaceholder",defaultMessage:"Make a selection",description:"Placeholder text. Use imperative"}),this.searchPlaceholder=n.formatMessage({id:"select.searchPlaceholder",defaultMessage:"Search",description:"Placeholder text. Use imperative"}),this.allSelectedMessage=n.formatMessage({id:"select.allSelected",defaultMessage:"All selected",description:"Text displayed when all options are selected"}),this.isTabbing=!1,this.isExpanded=!1,this.announcement=""}get childOptions(){return Array.from(this.el.querySelectorAll("wm-option"))}get duplicateOptions(){return Array.from(this.el.shadowRoot.querySelectorAll("wm-option"))}get allOptionEls(){return this.duplicateOptions.concat(this.childOptions)}get visibleOptionEls(){return this.allOptionEls.filter((t=>!t.classList.contains("hidden")&&!t.classList.contains("filtered-out")))}get searchTerm(){return this.searchFieldEl?this.searchFieldEl.value:""}get filteredOptions(){return this.childOptions.filter((t=>{var e;return null===(e=t.textContent)||void 0===e?void 0:e.toLowerCase().includes(this.searchTerm.toLowerCase())}))}get selectedOptions(){return Array.from(this.el.querySelectorAll("wm-option")).filter((t=>t.selected))}get allSelected(){return this.childOptions.every((t=>t.selected))}get resultsFoundMessage(){return n.formatMessage({id:"select.searchResultsFound",defaultMessage:"{numResults, plural, one {1 option found} other {# options found}}",description:"The message read by the screen reader, indicating how many results a search returned"},{numResults:this.filteredOptions.length})}get noResultsFoundMessage(){return n.formatMessage({id:"select.noSearchResults",defaultMessage:"No results found. Please try your search again.",description:"The message displayed when no options pass the search filter"})}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleOptionSelection(t){const e=t.detail;if(this.focusOption(e),this.multiple){this.selectOption(e);const t={changedOption:e.classList.contains("duplicate")?this.findCorrespondingOption(e):e,selectedOptions:this.childOptions.filter((t=>t.selected))};this.wmSelectChanged.emit(t);const i=new CustomEvent("change",{detail:t});this.el.dispatchEvent(i)}else{if(!e.selected){this.selectOption(e);const t={changedOption:e,selectedOptions:[e]};this.wmSelectChanged.emit(t);const i=new CustomEvent("change",{detail:t});this.el.dispatchEvent(i)}this.close()}}handleChildEnter(){this.close()}handleChildUp(t){this.moveUp(t.detail)}handleChildDown(t){this.moveDown(t.detail)}moveToFirstOption(){this.focusOption(this.visibleOptionEls[0])}moveToLastOption(){this.focusOption(this.visibleOptionEls[this.visibleOptionEls.length-1])}closePopupOnEscape(){this.close()}handleOptionBlur(t){if(!this.isElOrChild(t.detail.relatedTarget)){const e=new CustomEvent("blur");e.relatedTarget=t.detail.relatedTarget,this.el.dispatchEvent(e)}}handleClick(t){this.isElOrChild(t.target)||this.close()}handleSelectAllClick(){this.allSelected?this.deselectAllOptions():this.selectAllOptions()}selectAllOptions(){this.allOptionEls.forEach((t=>t.selected=!0)),this.setSelectAllButton(),this.setButtonText(),this.wmSelectChanged.emit({changedOption:null,selectedOptions:this.childOptions})}deselectAllOptions(){this.allOptionEls.forEach((t=>t.selected=!1)),this.setSelectAllButton(),this.setButtonText(),this.wmSelectChanged.emit({changedOption:null,selectedOptions:[]})}handleButtonBlur(t){this.isElOrChild(t.relatedTarget)&&t.stopPropagation()}handleSearchFieldBlur(t){this.searchFieldWrapperEl.classList.remove("focus"),this.isElOrChild(t.relatedTarget)&&t.stopPropagation()}handleKey(t){switch(t.key){case"ArrowDown":!1===this.isExpanded&&(t.preventDefault(),this.open("next"));break;case"ArrowUp":!1===this.isExpanded&&(t.preventDefault(),this.open("previous"))}}componentWillLoad(){this.label||console.error("For accessibility purposes, this component requires a label (even if `label-position` is set to `none`)."),this.uid=this.el.id?this.el.id:l(),document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn(),this.selectedOptions.length>0?this.selectedOptions.forEach((t=>{this.displayedOptions.push(t)})):this.multiple||this.selectOption(this.allOptionEls[0])}componentDidLoad(){this.wmSelectDidLoad.emit(),this.dropdownEl.classList.add("hidden"),r(this.el),this.maxHeight&&(this.listboxEl.style.maxHeight=this.maxHeight),this.multiple&&this.updateOptionVisibility(),this.setButtonText()}componentWillUpdate(){if(this.multiple){const t=this.visibleOptionEls.filter((t=>t.classList.contains("duplicate")));t.forEach(((e,i)=>{i===t.length-1?e.classList.add("last"):e.classList.remove("last")}))}}moveUp(t){const e=this.visibleOptionEls;this.selectAllEl&&e.unshift(this.selectAllEl),this.searchFieldEl&&e.unshift(this.searchFieldEl);const i=e[e.indexOf(t)-1]||e[e.length-1];i&&this.focusOption(i)}moveDown(t){const e=this.visibleOptionEls;this.selectAllEl&&e.unshift(this.selectAllEl),this.searchFieldEl&&e.unshift(this.searchFieldEl);const i=e[e.indexOf(t)+1]||e[0];i&&this.focusOption(i)}open(t){this.disabled||(this.openUp=h(this.el,this.dropdownEl.clientHeight,this.el.clientHeight,this.buttonEl.clientHeight),this.isExpanded=!0,this.dropdownEl.classList.remove("hidden"),window.requestAnimationFrame((()=>{switch(t){case"next":this.search?(this.searchFieldEl.focus(),this.listboxEl.scrollTop=0):this.moveDown(this.visibleOptionEls.filter((t=>t.selected)).slice(-1)[0]);break;case"previous":this.search?this.focusOption(this.visibleOptionEls[this.visibleOptionEls.length-1]):this.moveUp(this.visibleOptionEls.filter((t=>t.selected))[0]);break;default:this.search?(this.searchFieldEl.focus(),this.listboxEl.scrollTop=0):this.focusOption(this.selectedOptions.length>0?this.visibleOptionEls.filter((t=>t.selected))[0]:this.visibleOptionEls[0])}})))}close(t=!0){this.isExpanded&&(this.isExpanded=!1,this.allOptionEls.map((t=>t.focused=!1)),window.setTimeout((()=>{this.dropdownEl.classList.add("hidden"),this.multiple&&this.updateOptionVisibility(),this.search&&(this.searchFieldEl.value="",this.wmSelectSearchChanged.emit({searchTerm:this.searchTerm})),t&&this.buttonEl.focus()}),150))}updateOptionVisibility(){this.childOptions.forEach(((t,e)=>{const i=this.duplicateOptions[e];t.selected?(t.classList.add("hidden"),i.classList.remove("hidden")):(t.classList.remove("hidden"),i.classList.add("hidden"))}))}focusOption(t){this.allOptionEls.forEach((e=>e.focused=e===t)),t.scrollIntoView({block:"nearest"}),window.setTimeout((()=>t.scrollIntoView({block:"nearest"})),60),t.focus()}selectOption(t){if(t.classList.contains("duplicate")){const e=this.findCorrespondingOption(t);e.selected=!e.selected,r(this.el)}else this.multiple?t.selected=!t.selected:this.childOptions.forEach((e=>e.selected=e===t));this.selectAllEl&&this.setSelectAllButton(),this.setButtonText()}findAndFocusOption(t){const e=t.detail.toLowerCase();this.keysSoFar||this.visibleOptionEls.forEach(((t,e)=>{t.focused&&(this.searchIndex=e)})),this.keysSoFar+=e;let i=this.findMatchInRange(this.visibleOptionEls,this.searchIndex+1,this.visibleOptionEls.length);i||(i=this.findMatchInRange(this.visibleOptionEls,0,this.searchIndex)),i&&this.focusOption(i),this.debouncedClearKeysSoFar()}findMatchInRange(t,e,i){let s=null;return t.slice(e,i).forEach((t=>{const e=t.textContent;!s&&e&&e.toLowerCase().startsWith(this.keysSoFar)&&(s=t)})),s}findCorrespondingOption(t){return t.classList.contains("duplicate")?this.childOptions[this.duplicateOptions.indexOf(t)]:this.duplicateOptions[this.childOptions.indexOf(t)]}isElOrChild(t){var e;return t===this.el||this.el.contains(t)||(null===(e=this.el.shadowRoot)||void 0===e?void 0:e.contains(t))}exposeErrors(){const t=l();this.errorContainer.id=`wm-errors-${t}`,this.buttonEl.setAttribute("aria-describedby",`wm-errors-${t}`)}renderErrorContainer(){return i("div",{id:"wm-errors",class:this.errorMessage?"error-message":"",ref:t=>this.errorContainer=t,"aria-live":"assertive","aria-atomic":"true"},this.errorMessage)}handleComponentBlur(t){this.el.contains(t.relatedTarget)||(this.close(!1),this.wmSelectBlurred.emit(),this.wmComponentBlurred.emit())}handleKeyDown(t){const e=t.target;switch(t.key){case"ArrowDown":t.preventDefault(),this.moveDown(t.target);break;case"ArrowUp":t.preventDefault(),this.moveUp(t.target);break;case"Escape":t.preventDefault(),this.close();break;case"Enter":e===this.selectAllEl&&(t.preventDefault(),this.handleSelectAllClick(),this.close());break;case" ":e===this.selectAllEl&&(t.preventDefault(),this.handleSelectAllClick())}}setButtonText(){if(this.displayedOptions=this.childOptions.filter((t=>t.selected)).map((t=>t.classList.contains("hidden")?this.findCorrespondingOption(t):t)),this.multiple){const t=38,e=window.getComputedStyle(this.buttonEl),i=parseInt(e.getPropertyValue("padding-left").slice(0,-2)),s=parseInt(e.getPropertyValue("padding-right").slice(0,-2)),o=this.buttonEl.clientWidth-i-s-t;let r=this.displayedOptions.map((t=>t.shadowRoot.querySelector(".option-wrapper").clientWidth)),n=r.reduce(((t,e)=>t+e),0);for(this.overflowCount=0;n>o&&this.displayedOptions.length>1;)this.overflowCount++,n-=r[r.length-1],r.pop(),this.displayedOptions.pop()}}setSelectAllButton(){this.allSelected?(this.selectAllEl.textContent=this.deselectAllMessage,this.announce(this.allOptionsSelectedMessage)):(this.selectAllEl.textContent=this.selectAllMessage,0===this.selectedOptions.length&&this.announce(this.allOptionsDeselectedMessage))}announce(t){this.liveRegionEl.textContent===t&&(t+=" "),this.announcement=t}renderButtonText(){return this.multiple&&this.displayedOptions.length<1?i("span",null,this.placeholder):this.multiple&&this.allSelected&&this.overflowCount>0?this.allSelectedMessage:this.displayedOptions.map(((t,e)=>i("span",null,e>0?", ":"",t.textContent)))}renderSubinfo(){if(!this.multiple&&this.selectedOptions.length>0&&this.selectedOptions[0].subinfo)return i("span",{class:"subinfo"},this.selectedOptions[0].subinfo)}renderOverflowCount(){if(this.overflowCount>0&&!this.allSelected)return i("span",null,i("span",{class:"overflow-counter"},"+",this.overflowCount))}renderSearchField(){return i("div",{class:"search"},i("div",{class:"searchfield-wrapper",ref:t=>this.searchFieldWrapperEl=t},i("div",{class:"icon"}),i("input",{ref:t=>this.searchFieldEl=t,class:"searchfield",role:"combobox","aria-controls":`list-${this.uid}`,"aria-expanded":this.isExpanded?"true":"false",onKeyDown:t=>this.handleKeyDown(t),onFocus:()=>this.searchFieldWrapperEl.classList.add("focus"),onBlur:t=>this.handleSearchFieldBlur(t),onInput:()=>this.debouncedSearch(),placeholder:this.searchPlaceholder})))}renderSearchFailedMessage(){return i("div",{class:"search-results-message"},this.noResultsFoundMessage)}renderSelectAllButton(){if(this.selectAll&&this.multiple&&""==this.searchTerm)return i("button",{ref:t=>this.selectAllEl=t,class:"select-all",onClick:()=>this.handleSelectAllClick(),onKeyDown:t=>this.handleKeyDown(t),tabindex:"-1"},this.allSelected?this.deselectAllMessage:this.selectAllMessage)}renderDuplicateOptions(){return Array.from(this.el.children).map((t=>i("wm-option",{class:"duplicate",selected:t.selected},t.textContent)))}render(){const t={id:`selectbtn-${this.uid}`,disabled:this.disabled,"aria-controls":`list-${this.uid}`,"aria-labelledby":`label-${this.uid} selectbtn-${this.uid}`,"aria-describedby":"wm-errors","aria-expanded":this.isExpanded?"true":"false",onClick:()=>this.isExpanded?this.close():this.open()};return i(s,{onBlur:t=>this.handleComponentBlur(t)},i("div",{class:`wrapper ${p()} label-${this.labelPosition} ${this.invalid||this.errorMessage?"invalid":""}`},i("div",{class:"label-wrapper"},i("label",{class:"label",id:`label-${this.uid}`,htmlFor:`selectbtn-${this.uid}`},this.label,this.requiredField?i("span",{class:"required"},i("span",{class:"sr-only"},d.requiredField),i("span",{"aria-hidden":"true"},"*")):"")),i("div",{class:"button-wrapper"},i("button",Object.assign({},t,{class:"displayedoption "+(this.isTabbing?"user-is-tabbing":""),ref:t=>this.buttonEl=t,onBlur:t=>this.handleButtonBlur(t),onFocus:()=>this.close()}),i("span",{class:this.selectedOptions.length>0&&this.selectedOptions.filter((t=>t.subinfo)).length>0?"overflowcontrol hassubinfo":"overflowcontrol"},i("span",{class:"button-text"},this.renderButtonText()),this.renderSubinfo()),this.renderOverflowCount()),i("div",{class:`dropdown ${this.isExpanded?"open":""} ${this.openUp?"upwards":""}`,ref:t=>this.dropdownEl=t},this.search&&this.renderSearchField(),i("div",{id:`list-${this.uid}`,class:"options-wrapper",tabindex:-1,role:"listbox","aria-multiselectable":this.multiple?"true":null,"aria-labelledby":`label-${this.uid}`,ref:t=>this.listboxEl=t},this.search&&0===this.filteredOptions.length&&this.renderSearchFailedMessage(),this.renderSelectAllButton(),this.multiple&&this.renderDuplicateOptions(),i("slot",null))),this.renderErrorContainer(),i("div",{id:"announcement","aria-live":"polite",class:"sr-only",ref:t=>this.liveRegionEl=t},this.announcement))))}static get delegatesFocus(){return!0}get el(){return o(this)}static get watchers(){return{errorMessage:["exposeErrors"]}}};b.style=':host{position:relative;display:block;-webkit-box-sizing:border-box;box-sizing:border-box;font-family:inherit}:host .sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}.wrapper{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-size:0.875rem}.wrapper .label{display:block;line-height:normal;font-weight:600;white-space:nowrap;margin-bottom:0.25rem}.wrapper .label .required{color:#c0392b}.wrapper.label-left{-ms-flex-direction:row;flex-direction:row}.wrapper.label-left .label-wrapper{line-height:2.5rem}.wrapper.label-left .label-wrapper .label{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;min-height:2.5rem;white-space:normal;margin-bottom:0;margin-right:0.75rem}.wrapper.label-none label{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}.wrapper.invalid .label{color:#c0392b}.wrapper.invalid .label:after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f026";margin-left:0.3125rem}[dir=RTL] .wrapper.invalid .label:after{margin-left:0;margin-right:0.3125rem}.wrapper.rtl.label-left .label{margin-right:0;margin-left:0.75rem}.wrapper .button-wrapper{position:relative;-ms-flex:1;flex:1;font-size:1.125rem;color:#575195;min-width:8.75rem}.wrapper .button-wrapper .displayedoption{-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-wrap:nowrap;flex-wrap:nowrap;background:transparent;width:100%;border:solid 1px rgba(35, 35, 35, 0.6);padding:0 1.875rem 0 0.9375rem;cursor:pointer;height:2.5rem;line-height:normal;font-family:inherit;color:#575195;font-weight:400;font-size:0.875rem;text-transform:none;text-align:left}@media only screen and (max-width: 768px){.wrapper .button-wrapper .displayedoption{height:2.75rem}}.wrapper .button-wrapper .displayedoption:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f140";position:absolute;right:0.5625rem;pointer-events:none;font-size:1.12rem}.wrapper .button-wrapper .displayedoption:hover:not(:disabled):not(.-disabled):not(.-raised){background:transparent;text-decoration:none}.wrapper .button-wrapper .displayedoption:active{-ms-transform:scale(1, 1) !important;-webkit-transform:scale(1, 1) !important;transform:scale(1, 1) !important}.wrapper .button-wrapper .displayedoption:focus{outline:none}.wrapper .button-wrapper .displayedoption::-moz-focus-inner{border:0}.wrapper .button-wrapper .displayedoption.user-is-tabbing:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}.wrapper .button-wrapper .displayedoption.user-is-tabbing:focus::-moz-focus-inner{border:0}.wrapper .button-wrapper .displayedoption .overflowcontrol{display:block;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;-ms-flex:1;flex:1}.wrapper .button-wrapper .displayedoption .overflowcontrol.hassubinfo{display:-ms-flexbox;display:flex}.wrapper .button-wrapper .displayedoption .overflowcontrol.hassubinfo .button-text{-ms-flex:1;flex:1;text-overflow:ellipsis;overflow:hidden;min-width:0}.wrapper .button-wrapper .displayedoption .overflowcontrol.hassubinfo .subinfo{-ms-flex:none;flex:none;font-style:italic}.wrapper .button-wrapper .displayedoption .overflow-counter{font-weight:bold;margin-left:0.5rem}.wrapper .button-wrapper>.displayedoption[disabled]{color:#6b6b6b;border-color:#8a8a8a;background:#f0f0f0;cursor:default}.wrapper .button-wrapper>.dropdown{-webkit-overflow-scrolling:touch;-webkit-box-shadow:0 4px 15px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 4px 15px 0 rgba(0, 0, 0, 0.2);box-shadow:0 4px 15px 0 rgba(0, 0, 0, 0.2);-ms-transition:transform 0.25s ease;-webkit-transition:transform 0.25s ease;-moz-transition:transform 0.25s ease;-webkit-transition:-webkit-transform 0.25s ease;transition:-webkit-transform 0.25s ease;transition:transform 0.25s ease;transition:transform 0.25s ease, -webkit-transform 0.25s ease;-ms-transform:scale(1, 0);-webkit-transform:scale(1, 0);-moz-transform:scale(1, 0);transform:scale(1, 0);-ms-transform-origin:center top;-webkit-transform-origin:center top;-moz-transform-origin:center top;transform-origin:center top;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;position:absolute;top:0;right:0;background:#fff;z-index:100;width:100%;font-size:0.875rem}.wrapper .button-wrapper>.dropdown.upwards{top:unset;bottom:calc(100% - 2.5rem);-ms-transform-origin:center bottom;-webkit-transform-origin:center bottom;-moz-transform-origin:center bottom;transform-origin:center bottom}.wrapper .button-wrapper>.dropdown.hidden{visibility:hidden}.wrapper .button-wrapper>.dropdown.open{-ms-transform:scale(1, 1);-webkit-transform:scale(1, 1);-moz-transform:scale(1, 1);transform:scale(1, 1)}.wrapper.invalid .button-wrapper .displayedoption{-webkit-box-shadow:0 0 0 1px #c0392b;-moz-box-shadow:0 0 0 1px #c0392b;box-shadow:0 0 0 1px #c0392b;border-color:#c0392b}.wrapper .error-message{display:block;font-style:italic;color:#c0392b;font-size:0.875rem;margin-top:0.25rem;margin-bottom:0.25rem;top:100%;left:0}.options-wrapper{max-height:12.5rem;overflow:auto}.select-all{width:100%;cursor:pointer;padding:1.25rem;border:none;margin:0;border-bottom:2px solid rgba(46, 27, 70, 0.05);background:#fff;font-family:inherit;font-size:inherit;text-align:left;text-align:start;font-weight:500;color:#575195;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.select-all:hover,.select-all:focus{outline:none;background:#f4f4f4}.search{-webkit-box-sizing:border-box;box-sizing:border-box;border-bottom:2px solid rgba(46, 27, 70, 0.05);padding:1.25rem}.search .searchfield-wrapper{-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;height:2.75rem;width:100%;padding:0 0.75rem;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;border:1px solid #4a4a4a}.search .searchfield-wrapper:focus,.search .searchfield-wrapper.focus{-webkit-box-shadow:0 0 0 1px #19a1a9;-moz-box-shadow:0 0 0 1px #19a1a9;box-shadow:0 0 0 1px #19a1a9;outline:none;border-color:#19a1a9}.search .searchfield{width:100%;border:none;outline:none;font-family:inherit;font-size:0.875rem;margin-left:0.25rem}.search .icon:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f349";color:#6b6b6b;font-size:1.12rem}.search-results-message{padding:1.25rem;color:#4a4a4a;font-size:0.875rem;font-style:italic}.rtl>.dropdown{-ms-transform-origin:left top;-webkit-transform-origin:left top;-moz-transform-origin:left top;transform-origin:left top;left:0;right:auto}.rtl>.dropdown .option{padding-left:3rem;padding-right:1.25rem}.rtl>.displayedoption{padding:0 0.9375rem 0 1.875rem;text-align:right}.rtl>.displayedoption:before{right:auto;left:0.5625rem}';export{c as wm_option,b as wm_select}
|
|
1
|
+
import{r as t,c as e,h as i,H as s,g as o,f as r}from"./p-b5dee715.js";import{i as n,d as a,g as l,m as h,w as p}from"./p-91480a89.js";import{g as d}from"./p-4698b365.js";const c=class{constructor(i){t(this,i),this.wmOptionSelected=e(this,"wmOptionSelected",7),this.wmKeyUpPressed=e(this,"wmKeyUpPressed",7),this.wmKeyDownPressed=e(this,"wmKeyDownPressed",7),this.wmEscKeyPressed=e(this,"wmEscKeyPressed",7),this.wmHomeKeyPressed=e(this,"wmHomeKeyPressed",7),this.wmEndKeyPressed=e(this,"wmEndKeyPressed",7),this.wmEnterKeyPressed=e(this,"wmEnterKeyPressed",7),this.wmLetterPressed=e(this,"wmLetterPressed",7),this.wmOptionBlurred=e(this,"wmOptionBlurred",7),this.value=void 0,this.subinfo=void 0,this.disabled=!1,this.selected=!1,this.focused=!1,this.searchTerm=""}get hostClasses(){let t=[];return this.subinfo&&t.push("hassubinfo"),this.parentSelectEl.multiple&&t.push("multi-option"),this.el.textContent.toLowerCase().includes(this.searchTerm)||t.push("filtered-out"),t.join(" ")}get parentSelectEl(){var t;return"WM-SELECT"!==(null===(t=this.el.parentElement)||void 0===t?void 0:t.nodeName)?this.el.getRootNode().host:this.el.parentElement}handleKeydown(t){switch(t.key){case"ArrowUp":t.preventDefault(),this.wmKeyUpPressed.emit(this.el);break;case"ArrowDown":t.preventDefault(),this.wmKeyDownPressed.emit(this.el);break;case"Enter":t.preventDefault(),this.disabled||(this.el.click(),this.wmEnterKeyPressed.emit(this.el));break;case" ":t.preventDefault(),this.el.click();break;case"Escape":t.preventDefault(),t.stopPropagation(),this.wmEscKeyPressed.emit();break;case"Home":t.preventDefault(),this.wmHomeKeyPressed.emit();break;case"End":t.preventDefault(),this.wmEndKeyPressed.emit();break;default:1===t.key.length&&this.wmLetterPressed.emit(t.key)}}handleSelection(){this.disabled||this.wmOptionSelected.emit(this.el)}handleBlur(t){this.wmOptionBlurred.emit({relatedTarget:t.relatedTarget})}syncAriaSelected(){this.selected?this.el.setAttribute("aria-selected","true"):this.el.removeAttribute("aria-selected")}syncAriaDisabled(){this.disabled?this.el.setAttribute("aria-disabled","true"):this.el.removeAttribute("aria-disabled")}updateDisabledOnClick(){this.disabled&&this.el.onclick?(this.onClickFunc=this.el.onclick,this.el.onclick=null):!this.disabled&&this.onClickFunc&&(this.el.onclick=this.onClickFunc)}handleSearch(t){if(this.searchTerm=t.detail.searchTerm.toLowerCase(),this.searchTerm){const t=new RegExp(`${this.searchTerm}`,"gi"),e=this.el.textContent.replace(t,(t=>`<strong>${t}</strong>`));this.textEl.innerHTML=e}else this.textEl.innerHTML=this.el.textContent}componentWillLoad(){this.syncAriaSelected(),this.syncAriaDisabled(),this.updateDisabledOnClick(),this.parentSelectEl.addEventListener("wmSelectSearchChanged",(t=>this.handleSearch(t)))}render(){return i(s,{role:"option",tabindex:this.focused?0:-1,class:this.hostClasses},i("div",{class:"option-wrapper "+(this.parentSelectEl.multiple?"checkbox":"")},i("span",{"aria-hidden":"true",ref:t=>this.textEl=t},this.el.textContent),i("span",{class:"sr-only"},this.el.textContent)),i("div",{class:"subinfo"},this.subinfo))}get el(){return o(this)}static get watchers(){return{selected:["syncAriaSelected"],disabled:["syncAriaDisabled","updateDisabledOnClick"]}}};c.style=':host(:not(:last-child)),wm-option:not(:last-child){border-bottom:2px solid rgba(46, 27, 70, 0.05)}:host,wm-option{display:block;cursor:pointer;position:relative;padding:1.25rem;background:#fff;font-family:inherit;list-style:none;color:#4a4a4a;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}:host:focus,:host.focus,wm-option:focus,wm-option.focus{outline:none;background:#f4f4f4}:host.icon,wm-option.icon{color:#575195}:host .sr-only,wm-option .sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}.checkbox:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f131";display:inline-block;margin-right:0.25rem;color:#575195}:host([aria-selected=true]),wm-option[aria-selected=true]{background:rgba(46, 27, 70, 0.05);font-weight:500}:host([aria-selected=true]) .checkbox:before,wm-option[aria-selected=true] .checkbox:before{content:"\\f132"}:host([aria-disabled=true]),wm-option[aria-disabled=true]{font-style:italic;color:#6b6b6b;cursor:default}:host([aria-disabled=true]) .checkbox:before,wm-option[aria-disabled=true] .checkbox:before{color:#6b6b6b}:host(.multi-option),wm-option.multi-option{background:unset}:host(.hidden),wm-option.hidden,:host(.filtered-out),wm-option.filtered-out{display:none}:host(.duplicate.last),wm-option.duplicate.last{border-bottom:12px solid rgba(46, 27, 70, 0.05)}:host(.hassubinfo),wm-option.hassubinfo{display:-ms-flexbox;display:flex}:host(.hassubinfo) .option-wrapper,wm-option.hassubinfo .option-wrapper{-ms-flex:1;flex:1}:host(.hassubinfo) .subinfo,wm-option.hassubinfo .subinfo{-ms-flex:none;flex:none}.subinfo{font-style:italic}.option-wrapper{display:inline-block}::slotted{font-family:inherit}::slotted(i){font-size:0.875rem}::slotted(i):before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;display:inline-block;margin-right:0.625rem;pointer-events:none}:host(:focus),wm-option:focus{outline:none;background:#f4f4f4}:host(:hover){background:#f4f4f4;outline:none}';const b=class{constructor(i){t(this,i),this.wmSelectDidLoad=e(this,"wmSelectDidLoad",7),this.wmSelectBlurred=e(this,"wmSelectBlurred",7),this.wmSelectChanged=e(this,"wmSelectChanged",7),this.wmComponentBlurred=e(this,"wmComponentBlurred",7),this.wmSelectSearchChanged=e(this,"wmSelectSearchChanged",7),this.selectAllMessage=n.formatMessage({id:"select.selectAll",defaultMessage:"Select All"}),this.deselectAllMessage=n.formatMessage({id:"select.deselectAll",defaultMessage:"Deselect All"}),this.allOptionsSelectedMessage=n.formatMessage({id:"select.allOptionsSelected",defaultMessage:"All options selected"}),this.allOptionsDeselectedMessage=n.formatMessage({id:"select.allOptionsDeselected",defaultMessage:"All options deselected"}),this.keysSoFar="",this.searchIndex=0,this.openUp=!1,this.overflowCount=0,this.displayedOptions=[],this.debouncedClearKeysSoFar=a((()=>{this.keysSoFar=""}),500),this.debouncedSearch=a((()=>{this.wmSelectSearchChanged.emit({searchTerm:this.searchTerm}),this.announce(this.filteredOptions.length?this.resultsFoundMessage:this.noResultsFoundMessage)}),150),this.disabled=!1,this.invalid=!1,this.maxHeight=void 0,this.label=void 0,this.labelPosition="top",this.requiredField=!1,this.errorMessage="",this.multiple=!1,this.search=!1,this.selectAll=!1,this.placeholder=n.formatMessage({id:"select.multiPlaceholder",defaultMessage:"Make a selection",description:"Placeholder text. Use imperative"}),this.searchPlaceholder=n.formatMessage({id:"select.searchPlaceholder",defaultMessage:"Search",description:"Placeholder text. Use imperative"}),this.allSelectedMessage=n.formatMessage({id:"select.allSelected",defaultMessage:"All selected",description:"Text displayed when all options are selected"}),this.isTabbing=!1,this.isExpanded=!1,this.announcement=""}get childOptions(){return Array.from(this.el.querySelectorAll("wm-option"))}get duplicateOptions(){return Array.from(this.el.shadowRoot.querySelectorAll("wm-option"))}get allOptionEls(){return this.duplicateOptions.concat(this.childOptions)}get visibleOptionEls(){return this.allOptionEls.filter((t=>!t.classList.contains("hidden")&&!t.classList.contains("filtered-out")))}get searchTerm(){return this.searchFieldEl?this.searchFieldEl.value:""}get filteredOptions(){return this.childOptions.filter((t=>{var e;return null===(e=t.textContent)||void 0===e?void 0:e.toLowerCase().includes(this.searchTerm.toLowerCase())}))}get selectedOptions(){return Array.from(this.el.querySelectorAll("wm-option")).filter((t=>t.selected))}get allSelected(){return this.childOptions.every((t=>t.selected))}get resultsFoundMessage(){return n.formatMessage({id:"select.searchResultsFound",defaultMessage:"{numResults, plural, one {1 option found} other {# options found}}",description:"The message read by the screen reader, indicating how many results a search returned"},{numResults:this.filteredOptions.length})}get noResultsFoundMessage(){return n.formatMessage({id:"select.noSearchResults",defaultMessage:"No results found. Please try your search again.",description:"The message displayed when no options pass the search filter"})}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleOptionSelection(t){const e=t.detail;if(this.focusOption(e),this.multiple){this.selectOption(e);const t={changedOption:e.classList.contains("duplicate")?this.findCorrespondingOption(e):e,selectedOptions:this.childOptions.filter((t=>t.selected))};this.wmSelectChanged.emit(t);const i=new CustomEvent("change",{detail:t});this.el.dispatchEvent(i)}else{if(!e.selected){this.selectOption(e);const t={changedOption:e,selectedOptions:[e]};this.wmSelectChanged.emit(t);const i=new CustomEvent("change",{detail:t});this.el.dispatchEvent(i)}this.close()}}handleChildEnter(){this.close()}handleChildUp(t){this.moveUp(t.detail)}handleChildDown(t){this.moveDown(t.detail)}moveToFirstOption(){this.focusOption(this.visibleOptionEls[0])}moveToLastOption(){this.focusOption(this.visibleOptionEls[this.visibleOptionEls.length-1])}closePopupOnEscape(){this.close()}handleOptionBlur(t){if(!this.isElOrChild(t.detail.relatedTarget)){const e=new CustomEvent("blur");e.relatedTarget=t.detail.relatedTarget,this.el.dispatchEvent(e)}}handleClick(t){this.isElOrChild(t.target)||this.close()}handleSelectAllClick(){this.allSelected?this.deselectAllOptions():this.selectAllOptions()}selectAllOptions(){this.allOptionEls.forEach((t=>t.selected=!0)),this.setSelectAllButton(),this.setButtonText(),this.wmSelectChanged.emit({changedOption:null,selectedOptions:this.childOptions})}deselectAllOptions(){this.allOptionEls.forEach((t=>t.selected=!1)),this.setSelectAllButton(),this.setButtonText(),this.wmSelectChanged.emit({changedOption:null,selectedOptions:[]})}handleButtonBlur(t){this.isElOrChild(t.relatedTarget)&&t.stopPropagation()}handleSearchFieldBlur(t){this.searchFieldWrapperEl.classList.remove("focus"),this.isElOrChild(t.relatedTarget)&&t.stopPropagation()}handleKey(t){switch(t.key){case"ArrowDown":!1===this.isExpanded&&(t.preventDefault(),this.open("next"));break;case"ArrowUp":!1===this.isExpanded&&(t.preventDefault(),this.open("previous"))}}componentWillLoad(){this.label||console.error("For accessibility purposes, this component requires a label (even if `label-position` is set to `none`)."),this.uid=this.el.id?this.el.id:l(),document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn(),this.selectedOptions.length>0?this.selectedOptions.forEach((t=>{this.displayedOptions.push(t)})):this.multiple||this.selectOption(this.allOptionEls[0])}componentDidLoad(){this.wmSelectDidLoad.emit(),this.dropdownEl.classList.add("hidden"),r(this.el),this.maxHeight&&(this.listboxEl.style.maxHeight=this.maxHeight),this.multiple&&this.updateOptionVisibility(),this.setButtonText()}componentWillUpdate(){if(this.multiple){const t=this.visibleOptionEls.filter((t=>t.classList.contains("duplicate")));t.forEach(((e,i)=>{i===t.length-1?e.classList.add("last"):e.classList.remove("last")}))}}moveUp(t){const e=this.visibleOptionEls;this.selectAllEl&&e.unshift(this.selectAllEl),this.searchFieldEl&&e.unshift(this.searchFieldEl);const i=e[e.indexOf(t)-1]||e[e.length-1];i&&this.focusOption(i)}moveDown(t){const e=this.visibleOptionEls;this.selectAllEl&&e.unshift(this.selectAllEl),this.searchFieldEl&&e.unshift(this.searchFieldEl);const i=e[e.indexOf(t)+1]||e[0];i&&this.focusOption(i)}open(t){this.disabled||(this.openUp=h(this.el,this.dropdownEl.clientHeight,this.el.clientHeight,this.buttonEl.clientHeight),this.isExpanded=!0,this.dropdownEl.classList.remove("hidden"),window.requestAnimationFrame((()=>{switch(t){case"next":this.search?(this.searchFieldEl.focus(),this.listboxEl.scrollTop=0):this.moveDown(this.visibleOptionEls.filter((t=>t.selected)).slice(-1)[0]);break;case"previous":this.search?this.focusOption(this.visibleOptionEls[this.visibleOptionEls.length-1]):this.moveUp(this.visibleOptionEls.filter((t=>t.selected))[0]);break;default:this.search?(this.searchFieldEl.focus(),this.listboxEl.scrollTop=0):this.focusOption(this.selectedOptions.length>0?this.visibleOptionEls.filter((t=>t.selected))[0]:this.visibleOptionEls[0])}})))}close(t=!0){this.isExpanded&&(this.isExpanded=!1,this.allOptionEls.map((t=>t.focused=!1)),window.setTimeout((()=>{this.dropdownEl.classList.add("hidden"),this.multiple&&this.updateOptionVisibility(),this.search&&(this.searchFieldEl.value="",this.wmSelectSearchChanged.emit({searchTerm:this.searchTerm})),t&&this.buttonEl.focus()}),150))}updateOptionVisibility(){this.childOptions.forEach(((t,e)=>{const i=this.duplicateOptions[e];t.selected?(t.classList.add("hidden"),i.classList.remove("hidden")):(t.classList.remove("hidden"),i.classList.add("hidden"))}))}focusOption(t){this.allOptionEls.forEach((e=>e.focused=e===t)),t.scrollIntoView({block:"nearest"}),window.setTimeout((()=>t.scrollIntoView({block:"nearest"})),60),t.focus()}selectOption(t){if(t.classList.contains("duplicate")){const e=this.findCorrespondingOption(t);e.selected=!e.selected,r(this.el)}else this.multiple?t.selected=!t.selected:this.childOptions.forEach((e=>e.selected=e===t));this.selectAllEl&&this.setSelectAllButton(),this.setButtonText()}findAndFocusOption(t){const e=t.detail.toLowerCase();this.keysSoFar||this.visibleOptionEls.forEach(((t,e)=>{t.focused&&(this.searchIndex=e)})),this.keysSoFar+=e;let i=this.findMatchInRange(this.visibleOptionEls,this.searchIndex+1,this.visibleOptionEls.length);i||(i=this.findMatchInRange(this.visibleOptionEls,0,this.searchIndex)),i&&this.focusOption(i),this.debouncedClearKeysSoFar()}findMatchInRange(t,e,i){let s=null;return t.slice(e,i).forEach((t=>{const e=t.textContent;!s&&e&&e.toLowerCase().startsWith(this.keysSoFar)&&(s=t)})),s}findCorrespondingOption(t){return t.classList.contains("duplicate")?this.childOptions[this.duplicateOptions.indexOf(t)]:this.duplicateOptions[this.childOptions.indexOf(t)]}isElOrChild(t){var e;return t===this.el||this.el.contains(t)||(null===(e=this.el.shadowRoot)||void 0===e?void 0:e.contains(t))}exposeErrors(){const t=l();this.errorContainer.id=`wm-errors-${t}`,this.buttonEl.setAttribute("aria-describedby",`wm-errors-${t}`)}renderErrorContainer(){return i("div",{id:"wm-errors",class:this.errorMessage?"error-message":"",ref:t=>this.errorContainer=t,"aria-live":"assertive","aria-atomic":"true"},this.errorMessage)}handleComponentBlur(t){this.el.contains(t.relatedTarget)||(this.close(!1),this.wmSelectBlurred.emit(),this.wmComponentBlurred.emit())}handleKeyDown(t){const e=t.target;switch(t.key){case"ArrowDown":t.preventDefault(),this.moveDown(t.target);break;case"ArrowUp":t.preventDefault(),this.moveUp(t.target);break;case"Escape":t.preventDefault(),this.close();break;case"Enter":e===this.selectAllEl&&(t.preventDefault(),this.handleSelectAllClick(),this.close());break;case" ":e===this.selectAllEl&&(t.preventDefault(),this.handleSelectAllClick())}}setButtonText(){if(this.displayedOptions=this.childOptions.filter((t=>t.selected)).map((t=>t.classList.contains("hidden")?this.findCorrespondingOption(t):t)),this.multiple){const t=38,e=window.getComputedStyle(this.buttonEl),i=parseInt(e.getPropertyValue("padding-left").slice(0,-2)),s=parseInt(e.getPropertyValue("padding-right").slice(0,-2)),o=this.buttonEl.clientWidth-i-s-t;let r=this.displayedOptions.map((t=>t.shadowRoot.querySelector(".option-wrapper").clientWidth)),n=r.reduce(((t,e)=>t+e),0);for(this.overflowCount=0;n>o&&this.displayedOptions.length>1;)this.overflowCount++,n-=r[r.length-1],r.pop(),this.displayedOptions.pop()}}setSelectAllButton(){this.allSelected?(this.selectAllEl.textContent=this.deselectAllMessage,this.announce(this.allOptionsSelectedMessage)):(this.selectAllEl.textContent=this.selectAllMessage,0===this.selectedOptions.length&&this.announce(this.allOptionsDeselectedMessage))}announce(t){this.liveRegionEl.textContent===t&&(t+=" "),this.announcement=t}renderButtonText(){return this.multiple&&this.displayedOptions.length<1?i("span",null,this.placeholder):this.multiple&&this.allSelected&&this.overflowCount>0?this.allSelectedMessage:this.displayedOptions.map(((t,e)=>i("span",null,e>0?", ":"",t.textContent)))}renderSubinfo(){if(!this.multiple&&this.selectedOptions.length>0&&this.selectedOptions[0].subinfo)return i("span",{class:"subinfo"},this.selectedOptions[0].subinfo)}renderOverflowCount(){if(this.overflowCount>0&&!this.allSelected)return i("span",null,i("span",{class:"overflow-counter"},"+",this.overflowCount))}renderSearchField(){return i("div",{class:"search"},i("div",{class:"searchfield-wrapper",ref:t=>this.searchFieldWrapperEl=t},i("div",{class:"icon"}),i("input",{ref:t=>this.searchFieldEl=t,class:"searchfield",role:"combobox","aria-controls":`list-${this.uid}`,"aria-expanded":this.isExpanded?"true":"false",onKeyDown:t=>this.handleKeyDown(t),onFocus:()=>this.searchFieldWrapperEl.classList.add("focus"),onBlur:t=>this.handleSearchFieldBlur(t),onInput:()=>this.debouncedSearch(),placeholder:this.searchPlaceholder})))}renderSearchFailedMessage(){return i("div",{class:"search-results-message"},this.noResultsFoundMessage)}renderSelectAllButton(){if(this.selectAll&&this.multiple&&""==this.searchTerm)return i("button",{ref:t=>this.selectAllEl=t,class:"select-all",onClick:()=>this.handleSelectAllClick(),onKeyDown:t=>this.handleKeyDown(t),tabindex:"-1"},this.allSelected?this.deselectAllMessage:this.selectAllMessage)}renderDuplicateOptions(){return Array.from(this.el.children).map((t=>i("wm-option",{class:"duplicate",selected:t.selected},t.textContent)))}render(){const t={id:`selectbtn-${this.uid}`,disabled:this.disabled,"aria-controls":`list-${this.uid}`,"aria-labelledby":`label-${this.uid} selectbtn-${this.uid}`,"aria-describedby":"wm-errors","aria-expanded":this.isExpanded?"true":"false",onClick:()=>this.isExpanded?this.close():this.open()};return i(s,{onBlur:t=>this.handleComponentBlur(t)},i("div",{class:`wrapper ${p()} label-${this.labelPosition} ${this.invalid||this.errorMessage?"invalid":""}`},i("div",{class:"label-wrapper"},i("label",{class:"label",id:`label-${this.uid}`,htmlFor:`selectbtn-${this.uid}`},this.label,this.requiredField?i("span",{class:"required"},i("span",{class:"sr-only"},d.requiredField),i("span",{"aria-hidden":"true"},"*")):"")),i("div",{class:"button-wrapper"},i("button",Object.assign({},t,{class:"displayedoption "+(this.isTabbing?"user-is-tabbing":""),ref:t=>this.buttonEl=t,onBlur:t=>this.handleButtonBlur(t),onFocus:()=>this.close()}),i("span",{class:this.selectedOptions.length>0&&this.selectedOptions.filter((t=>t.subinfo)).length>0?"overflowcontrol hassubinfo":"overflowcontrol"},i("span",{class:"button-text"},this.renderButtonText()),this.renderSubinfo()),this.renderOverflowCount()),i("div",{class:`dropdown ${this.isExpanded?"open":""} ${this.openUp?"upwards":""}`,ref:t=>this.dropdownEl=t},this.search&&this.renderSearchField(),i("div",{id:`list-${this.uid}`,class:"options-wrapper",tabindex:-1,role:"listbox","aria-multiselectable":this.multiple?"true":null,"aria-labelledby":`label-${this.uid}`,ref:t=>this.listboxEl=t},this.search&&0===this.filteredOptions.length&&this.renderSearchFailedMessage(),this.renderSelectAllButton(),this.multiple&&this.renderDuplicateOptions(),i("slot",null))),this.renderErrorContainer(),i("div",{id:"announcement","aria-live":"polite",class:"sr-only",ref:t=>this.liveRegionEl=t},this.announcement))))}static get delegatesFocus(){return!0}get el(){return o(this)}static get watchers(){return{errorMessage:["exposeErrors"]}}};b.style=':host{position:relative;display:block;-webkit-box-sizing:border-box;box-sizing:border-box;font-family:inherit}:host .sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}.wrapper{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-size:0.875rem}.wrapper .label{display:block;line-height:normal;font-weight:600;white-space:nowrap;margin-bottom:0.25rem}.wrapper .label .required{color:#c0392b}.wrapper.label-left{-ms-flex-direction:row;flex-direction:row}.wrapper.label-left .label-wrapper{line-height:2.5rem}.wrapper.label-left .label-wrapper .label{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;min-height:2.5rem;white-space:normal;margin-bottom:0;margin-right:0.75rem}.wrapper.label-none label{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}.wrapper.invalid .label{color:#c0392b}.wrapper.invalid .label:after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f026";margin-left:0.3125rem}[dir=RTL] .wrapper.invalid .label:after{margin-left:0;margin-right:0.3125rem}.wrapper.rtl.label-left .label{margin-right:0;margin-left:0.75rem}.wrapper .button-wrapper{position:relative;-ms-flex:1;flex:1;font-size:1.125rem;color:#575195;min-width:8.75rem}.wrapper .button-wrapper .displayedoption{-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-wrap:nowrap;flex-wrap:nowrap;background:transparent;width:100%;border:solid 1px rgba(35, 35, 35, 0.6);padding:0 1.875rem 0 0.9375rem;cursor:pointer;height:2.5rem;line-height:normal;font-family:inherit;color:#575195;font-weight:400;font-size:0.875rem;text-transform:none;text-align:left}@media only screen and (max-width: 768px){.wrapper .button-wrapper .displayedoption{height:2.75rem}}.wrapper .button-wrapper .displayedoption:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f140";position:absolute;right:0.5625rem;pointer-events:none;font-size:1.12rem}.wrapper .button-wrapper .displayedoption:hover:not(:disabled):not(.-disabled):not(.-raised){background:transparent;text-decoration:none}.wrapper .button-wrapper .displayedoption:active{-ms-transform:scale(1, 1) !important;-webkit-transform:scale(1, 1) !important;transform:scale(1, 1) !important}.wrapper .button-wrapper .displayedoption:focus{outline:none}.wrapper .button-wrapper .displayedoption::-moz-focus-inner{border:0}.wrapper .button-wrapper .displayedoption.user-is-tabbing:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}.wrapper .button-wrapper .displayedoption.user-is-tabbing:focus::-moz-focus-inner{border:0}.wrapper .button-wrapper .displayedoption .overflowcontrol{display:block;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;-ms-flex:1;flex:1}.wrapper .button-wrapper .displayedoption .overflowcontrol.hassubinfo{display:-ms-flexbox;display:flex}.wrapper .button-wrapper .displayedoption .overflowcontrol.hassubinfo .button-text{-ms-flex:1;flex:1;text-overflow:ellipsis;overflow:hidden;min-width:0}.wrapper .button-wrapper .displayedoption .overflowcontrol.hassubinfo .subinfo{-ms-flex:none;flex:none;font-style:italic}.wrapper .button-wrapper .displayedoption .overflow-counter{font-weight:bold;margin-left:0.5rem}.wrapper .button-wrapper>.displayedoption[disabled]{color:#6b6b6b;border-color:#8a8a8a;background:#f0f0f0;cursor:default}.wrapper .button-wrapper>.dropdown{-webkit-overflow-scrolling:touch;-webkit-box-shadow:0 4px 15px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 4px 15px 0 rgba(0, 0, 0, 0.2);box-shadow:0 4px 15px 0 rgba(0, 0, 0, 0.2);-ms-transition:transform 0.25s ease;-webkit-transition:transform 0.25s ease;-moz-transition:transform 0.25s ease;-webkit-transition:-webkit-transform 0.25s ease;transition:-webkit-transform 0.25s ease;transition:transform 0.25s ease;transition:transform 0.25s ease, -webkit-transform 0.25s ease;-ms-transform:scale(1, 0);-webkit-transform:scale(1, 0);-moz-transform:scale(1, 0);transform:scale(1, 0);-ms-transform-origin:center top;-webkit-transform-origin:center top;-moz-transform-origin:center top;transform-origin:center top;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;position:absolute;top:0;right:0;background:#fff;z-index:100;width:100%;font-size:0.875rem}.wrapper .button-wrapper>.dropdown.upwards{top:unset;bottom:calc(100% - 2.5rem);-ms-transform-origin:center bottom;-webkit-transform-origin:center bottom;-moz-transform-origin:center bottom;transform-origin:center bottom}.wrapper .button-wrapper>.dropdown.hidden{visibility:hidden}.wrapper .button-wrapper>.dropdown.open{-ms-transform:scale(1, 1);-webkit-transform:scale(1, 1);-moz-transform:scale(1, 1);transform:scale(1, 1)}.wrapper.invalid .button-wrapper .displayedoption{-webkit-box-shadow:0 0 0 1px #c0392b;-moz-box-shadow:0 0 0 1px #c0392b;box-shadow:0 0 0 1px #c0392b;border-color:#c0392b}.wrapper .error-message{display:block;font-style:italic;color:#c0392b;font-size:0.875rem;margin-top:0.25rem;margin-bottom:0.25rem;top:100%;left:0}.options-wrapper{max-height:12.5rem;overflow:auto}.select-all{width:100%;cursor:pointer;padding:1.25rem;border:none;margin:0;border-bottom:2px solid rgba(46, 27, 70, 0.05);background:#fff;font-family:inherit;font-size:inherit;text-align:left;text-align:start;font-weight:500;color:#575195;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.select-all:hover,.select-all:focus{outline:none;background:#f4f4f4}.search{-webkit-box-sizing:border-box;box-sizing:border-box;border-bottom:2px solid rgba(46, 27, 70, 0.05);padding:1.25rem}.search .searchfield-wrapper{-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;height:2.75rem;width:100%;padding:0 0.75rem;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;border:1px solid #4a4a4a}.search .searchfield-wrapper:focus,.search .searchfield-wrapper.focus{-webkit-box-shadow:0 0 0 1px #19a1a9;-moz-box-shadow:0 0 0 1px #19a1a9;box-shadow:0 0 0 1px #19a1a9;outline:none;border-color:#19a1a9}.search .searchfield{width:100%;border:none;outline:none;font-family:inherit;font-size:0.875rem;margin-left:0.25rem}.search .icon:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f349";color:#6b6b6b;font-size:1.12rem}.search-results-message{padding:1.25rem;color:#4a4a4a;font-size:0.875rem;font-style:italic}.rtl>.dropdown{-ms-transform-origin:left top;-webkit-transform-origin:left top;-moz-transform-origin:left top;transform-origin:left top;left:0;right:auto}.rtl>.dropdown .option{padding-left:3rem;padding-right:1.25rem}.rtl>.displayedoption{padding:0 0.9375rem 0 1.875rem;text-align:right}.rtl>.displayedoption:before{right:auto;left:0.5625rem}';export{c as wm_option,b as wm_select}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as i,h as e,H as r,g as
|
|
1
|
+
import{r as t,c as i,h as e,H as r,g as s}from"./p-b5dee715.js";import{i as a,g as p,b as n}from"./p-91480a89.js";import{g as l}from"./p-4698b365.js";const o=class{constructor(e){t(this,e),this.wmInputValueChanged=i(this,"wmInputValueChanged",7),this.uid="",this.previousBlurredValue="",this.numberErrorMessage=a.formatMessage({id:"input.numberError",defaultMessage:"Please enter a valid number."}),this.label=void 0,this.labelPosition="top",this.value="",this.disabled=!1,this.info=void 0,this.inputWidth="",this.placeholder="",this.requiredField=!1,this.requiredFieldMessage=void 0,this.errorMessage=void 0,this.characterLimit=void 0,this.symbolBefore=void 0,this.symbolAfter=void 0,this.textAfter=void 0,this.preventValidation=void 0,this.type="text",this.step=1,this.min=void 0,this.max=void 0,this.announcement="",this.displayedErrorMessage=""}getInputWidth(){return this.inputWidth?{width:this.inputWidth}:{flex:"1"}}get charCount(){return this.value.length}componentWillLoad(){this.uid=this.el.id?this.el.id:p(),this.label||console.error("wm-input requires the label property")}componentDidLoad(){this.value&&(this.inputEl.value=this.value,this.previousBlurredValue=this.inputEl.value)}handleErrorMessage(t){this.displayedErrorMessage=t}handleKeyDown(t){const i=t.ctrlKey||t.metaKey||t.altKey;/^.$/.test(t.key)&&!i&&this.characterLimit&&this.inputEl.value.length>=this.characterLimit&&this.announce(this.generateCharacterLimitWarning(this.charCount,this.characterLimit))}handleBlur(t){this.value!==this.previousBlurredValue&&this.wmInputValueChanged.emit({value:this.value}),this.previousBlurredValue=this.value,this.preventValidation&&n(t,this.preventValidation)||(this.displayedErrorMessage=this.validate()),this.inputWrapperEl.classList.remove("focus")}handleInput(t){this.value=t.target.value,this.characterLimit&&this.charCount>=this.characterLimit-5&&this.announce(this.generateCharacterLimitWarning(this.charCount,this.characterLimit))}handleFocus(){this.inputWrapperEl.classList.add("focus")}validate(){const t=[this.validateNumber.bind(this),this.validateRequired.bind(this)];return this.errorMessage?this.errorMessage:t.reduce(((t,i)=>t||i()),"")}validateRequired(){return this.requiredField&&""===this.value?this.requiredFieldMessage||l.requiredError:""}validateNumber(){return"number"===this.type&&this.inputEl.validity.badInput?this.numberErrorMessage:""}announce(t){this.liveRegionEl.textContent===t&&(t+=" "),this.announcement=t}generateCharacterLimitWarning(t,i){let e=l.getCharactersEntered(t,i);return t>=i&&(e+=` ${l.characterLimitReached}`),e}descriptors(){return this.symbolBefore||this.symbolAfter||this.textAfter?`symbol-before-${this.uid} inputfield-${this.uid} symbol-after-${this.uid} text-after-${this.uid} info-${this.uid} error-${this.uid}`:`info-${this.uid} error-${this.uid}`}renderErrorMessage(){return this.errorMessage||this.displayedErrorMessage}render(){return e(r,{id:this.uid},e("div",{class:`wrapper label-${this.labelPosition} ${this.errorMessage||this.displayedErrorMessage?"invalid":""}`,ref:t=>this.inputWrapperEl=t},e("div",{class:"label-wrapper"},e("label",{htmlFor:`inputfield-${this.uid}`,class:"label"},this.label,this.characterLimit&&e("span",{class:"sr-only"}," ",l.getCharacterLimit(this.characterLimit)),this.requiredField&&e("span",{class:"required","aria-hidden":"true"},"*"))),e("div",{class:"inner-wrapper"},e("div",{class:"text-after-wrapper"},e("div",{class:"inputfield-wrapper "+(this.disabled?"disabled":""),style:this.getInputWidth()},this.symbolBefore&&e("span",{class:"symbol",id:`symbol-before-${this.uid}`},this.symbolBefore),e("input",{ref:t=>this.inputEl=t,id:`inputfield-${this.uid}`,disabled:this.disabled,"aria-describedby":this.descriptors(),onInput:t=>this.handleInput(t),onKeyDown:t=>this.handleKeyDown(t),onBlur:t=>this.handleBlur(t),onFocus:this.handleFocus.bind(this),placeholder:this.placeholder,autocomplete:"off","aria-required":this.requiredField?"true":null,maxLength:this.characterLimit||void 0,type:this.type,step:this.step,max:this.max,min:this.min}),this.symbolAfter&&e("span",{class:"symbol",id:`symbol-after-${this.uid}`},this.symbolAfter),this.characterLimit&&"number"==typeof this.characterLimit?e("div",{class:"character-count"},this.charCount,"/",this.characterLimit):""),this.textAfter&&e("span",{class:"text-after",id:`text-after-${this.uid}`},this.textAfter)),this.info&&e("div",{id:`info-${this.uid}`,class:"info"},this.info),e("div",{id:`error-${this.uid}`,"aria-live":"assertive",class:"error-message","aria-atomic":"true"},this.renderErrorMessage()),e("div",{class:"sr-only","aria-live":"polite","aria-atomic":"true",ref:t=>this.liveRegionEl=t},this.announcement))))}static get delegatesFocus(){return!0}get el(){return s(this)}static get watchers(){return{errorMessage:["handleErrorMessage"]}}};o.style=':host,wm-input{font-family:inherit;width:100%}:host *,wm-input *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .wrapper,wm-input .wrapper{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-size:0.875rem}:host .wrapper .label,wm-input .wrapper .label{display:block;line-height:normal;font-weight:600;white-space:nowrap;margin-bottom:0.25rem}:host .wrapper .label .required,wm-input .wrapper .label .required{color:#c0392b}:host .wrapper.label-left,wm-input .wrapper.label-left{-ms-flex-direction:row;flex-direction:row}:host .wrapper.label-left .label-wrapper,wm-input .wrapper.label-left .label-wrapper{line-height:2.5rem}:host .wrapper.label-left .label-wrapper .label,wm-input .wrapper.label-left .label-wrapper .label{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;min-height:2.5rem;white-space:normal;margin-bottom:0;margin-right:0.75rem}:host .wrapper.label-none label,wm-input .wrapper.label-none label{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}:host .wrapper.invalid .label,wm-input .wrapper.invalid .label{color:#c0392b}:host .wrapper.invalid .label:after,wm-input .wrapper.invalid .label:after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f026";margin-left:0.3125rem}[dir=RTL] :host .wrapper.invalid .label:after,[dir=RTL] wm-input .wrapper.invalid .label:after{margin-left:0;margin-right:0.3125rem}:host .wrapper.rtl.label-left .label,wm-input .wrapper.rtl.label-left .label{margin-right:0;margin-left:0.75rem}:host .wrapper .inner-wrapper,wm-input .wrapper .inner-wrapper{width:100%}:host .wrapper .text-after-wrapper,wm-input .wrapper .text-after-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:8px}:host .wrapper .text-after,wm-input .wrapper .text-after{-ms-flex:0 1 fit-content;flex:0 1 fit-content}:host .wrapper .inputfield-wrapper,wm-input .wrapper .inputfield-wrapper{height:2.5rem;min-width:6.25rem;border:1px solid #4a4a4a;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;display:-ms-flexbox;display:flex}:host .wrapper .inputfield-wrapper.disabled,wm-input .wrapper .inputfield-wrapper.disabled{background-color:#f0f0f0;color:#737373}:host .wrapper .inputfield-wrapper.disabled .symbol,wm-input .wrapper .inputfield-wrapper.disabled .symbol{background:none}:host .wrapper .symbol,wm-input .wrapper .symbol{display:-ms-flexbox;display:flex;background-color:rgba(74, 74, 74, 0.03);-ms-flex:0 0 44px;flex:0 0 44px;padding-inline:8px;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center}:host .wrapper .character-count,wm-input .wrapper .character-count{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;min-width:5rem;background-color:rgba(74, 74, 74, 0.05);font-size:0.875rem;font-weight:500;-ms-flex-item-align:stretch;align-self:stretch}:host .wrapper input,wm-input .wrapper input{-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;border:none;font-family:inherit;font-size:0.875rem;height:100%;-ms-flex:1;flex:1;padding:0.75rem 1rem;width:100%}:host .wrapper input:focus,wm-input .wrapper input:focus{outline:none}:host .wrapper input[type=number],wm-input .wrapper input[type=number]{padding-right:0}:host .wrapper .info,wm-input .wrapper .info{font-style:italic;line-height:100%;margin:4px 0}:host .wrapper.invalid .inputfield-wrapper,wm-input .wrapper.invalid .inputfield-wrapper{-webkit-box-shadow:0 0 0 1px #c0392b;-moz-box-shadow:0 0 0 1px #c0392b;box-shadow:0 0 0 1px #c0392b;border-color:#c0392b}:host .wrapper.invalid .error-message,wm-input .wrapper.invalid .error-message{display:block;font-style:italic;color:#c0392b;font-size:0.875rem;margin-top:0.25rem;line-height:100%}:host .wrapper:focus .inputfield-wrapper,:host .wrapper.focus .inputfield-wrapper,wm-input .wrapper:focus .inputfield-wrapper,wm-input .wrapper.focus .inputfield-wrapper{-webkit-box-shadow:0 0 0 1px #19a1a9;-moz-box-shadow:0 0 0 1px #19a1a9;box-shadow:0 0 0 1px #19a1a9;outline:none;border-color:#19a1a9}:host .sr-only,wm-input .sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}';export{o as wm_input}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as e,f as o,h as i,H as r,g as n}from"./p-b5dee715.js";import{g as a,v as s}from"./p-cfa80f5b.js";import{u as l}from"./p-19689aac.js";const d=class{constructor(o){t(this,o),this.wmUploaderFilesSelected=e(this,"wmUploaderFilesSelected",7),this.wmFilesSelected=e(this,"wmFilesSelected",7),this.wmUploaderDeleteFile=e(this,"wmUploaderDeleteFile",7),this.wmDeleteFile=e(this,"wmDeleteFile",7),this.wmUploaderDownloadFile=e(this,"wmUploaderDownloadFile",7),this.wmDownloadFile=e(this,"wmDownloadFile",7),this.wmUploaderPreviewFile=e(this,"wmUploaderPreviewFile",7),this.wmFileDelete=e(this,"wmFileDelete",7),this.wmFileDownload=e(this,"wmFileDownload",7),this.wmFilePreview=e(this,"wmFilePreview",7),this.inputId=a(),this.uploaderType=void 0,this.type=void 0,this.label=void 0,this.buttonText=void 0,this.info=void 0,this.emptyStateText=void 0,this.icon=void 0,this.fileTypes="pdf txt log xml doc docx xls xlsx ppt pptx gif jpg jpeg png csv",this.maxSize=void 0,this.maxFiles=void 0,this.sortBy="date",this.showInfo="time",this.errorMessage=void 0,this.requiredField=void 0,this.files=void 0,this.fileList=[],this.filesToUpload=[],this.isTabbing=!1,this.rejectedFiles=void 0,this.errorList=[],this.notif=void 0,this.internalErrorMessage=void 0,this.announcement="",this.numFilesInProgress=void 0,this.isCondensed=!1}get uploadButtonEl(){return this.el.shadowRoot.querySelector(`#${this.inputId}`)}get tempUploaderType(){return this.type||this.uploaderType}get effectiveMaxSize(){return this.maxSize?Math.min(this.maxSize,100):100}get fileLimitReached(){return this.maxFiles&&this.fileList.length>=this.maxFiles}get displayedErrorMessage(){return this.errorMessage||this.internalErrorMessage||""}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleUploadProgress(t){if(this.fileList.map((e=>{e.id===t.detail.id&&(e.progress=t.detail.progress,o(this.el))})),100===t.detail.progress&&(this.numFilesInProgress-=1),!this.srProgress&&this.numFilesInProgress){const t=this.numFilesInProgress;this.srProgress=setInterval((()=>{const e=this.fileList.reduce(((t,e)=>e.progress?t+e.progress:t),0);this.announce(l.getUploadProgress(Math.floor(e/t)))}),5e3)}}handleFileErrorCleared(t){const e=t.detail.name;this.errorList=this.errorList.filter((t=>t.name!=e)),this.uploadButtonEl.focus()}handleFileDeleted(t){this.clearErrors(),o(this.el),this.wmUploaderDeleteFile.emit(t.detail),this.wmFileDelete.emit(t.detail),this.wmDeleteFile.emit(t.detail)}handleFilePreviewed(t){this.clearErrors(),this.wmUploaderPreviewFile.emit(t.detail),this.wmFilePreview.emit(t.detail)}handleFileDownloaded(t){this.clearErrors(),this.wmUploaderDownloadFile.emit(t.detail),this.wmFileDownload.emit(t.detail),this.wmDownloadFile.emit(t.detail)}parseFiles(){if(this.files){if("string"!=typeof this.files)throw new Error("Attribute 'files' should be a string");{let t=JSON.parse(this.files);if("object"!=typeof t)throw new Error("could not parse string passed to files attribute");t.forEach((t=>{if(t.size&&("number"==typeof t.size||t.size.match(/^[0-9]+$/))){const e=this.convertBytes(t.size);t.size=`${e.size.toFixed(0)} ${e.unit}`}})),this.fileList=t}}}focusAfterRemoval(t,e){if(this.isTabbing&&t.length<e.length){const o=t.map((t=>t.id)),i=e.map((t=>t.id)),r=i.filter((t=>!o.includes(t)))[0];if(i.indexOf(r)>0){const o=i[i.indexOf(r)-1],n=this.el.shadowRoot.querySelector("#file-"+o),a=null==n?void 0:n.shadowRoot.querySelectorAll("wm-button");a&&a.length>0?a[a.length-1].focus():this.focusAfterRemoval(t.filter((t=>t.id!==o)),e)}else this.uploadButtonEl.focus()}}parseRejectedFiles(){if(this.rejectedFiles){if("string"!=typeof this.files)throw new Error("Attribute 'rejected-files' should be a string");{const t=JSON.parse(this.rejectedFiles);if("object"!=typeof t)throw new Error("could not parse string passed to errors attribute");this.errorList=t}}}uploadNotifications(t,e){e>0&&0===t?(setTimeout((()=>{this.notif="",this.internalErrorMessage=""}),2e4),this.notif=l.finishedUploading,this.announce(l.finishedUploading),this.numFilesInProgress=null,clearInterval(this.srProgress),o(this.el)):t>0&&t!=e&&(this.notif=l.getFilesUploading(t),this.announce(l.getFilesUploading(t)),o(this.el))}handleErrorMessageChange(){this.errorMessage&&this.announce(this.errorMessage)}isValidSize(t){return this.convertBytes(t,"MB").size<=this.effectiveMaxSize}convertBytes(t,e){const o=["bytes","KB","MB","GB","TB"];let i=0,r="number"==typeof t?t:parseInt(t);if(e)for(;o.indexOf(e)>i;)r/=1024,i++;else for(;r>1e3;)r/=1024,i++;return{size:r,unit:o[i]}}isDuplicate(t){const e=this.filesToUpload.some((e=>e.name===t)),o=this.fileList.some((e=>(e.type?e.name+"."+e.type:e.name)===t));return e||o}isEmpty(){return!this.fileList.length&&!this.errorList.length}get isDisabled(){return this.fileLimitReached||this.numFilesInProgress>0}isItemUploading(t){return t.hasOwnProperty("progress")&&t.progress<100}announce(t){this.liveRegion.textContent===t&&(t+=" "),this.announcement=t}clearErrors(){this.errorList=[],this.notif="",this.internalErrorMessage=""}handleFiles(t){this.filesToUpload=[];const e=Array.from(t.target.files),o=this.fileTypes.split(" ").join(", ");this.maxFiles&&this.fileList.length+e.length>this.maxFiles?(this.internalErrorMessage=l.fileLimitExceeded,this.announce(l.fileLimitExceeded)):(e&&e.map((t=>{if(s(t,this.fileTypes))if(0===t.size)this.errorList.push({name:t.name,message:l.zeroFileSize});else if(this.isValidSize(t.size))this.isDuplicate(t.name)?this.errorList.push({name:t.name,message:l.duplicateName}):this.filesToUpload.push(t);else{const e={name:t.name,message:l.getFileTooLarge(this.effectiveMaxSize)};this.errorList.push(e)}else{const e={name:t.name,message:l.getInvalidFileType(o)};this.errorList.push(e)}})),this.filesToUpload.length>0&&(this.numFilesInProgress=this.filesToUpload.length,this.wmUploaderFilesSelected.emit(this.filesToUpload),this.wmFilesSelected.emit(this.filesToUpload))),t.target.value=""}componentWillLoad(){if(!this.buttonText)throw new Error("wm-uploader: button-text is a required prop");if(this.type&&console.warn("wm-uploader: type has been deprecated as of v3.1.0. Please use uploader-type instead."),"1"===this.tempUploaderType&&!this.emptyStateText)throw new Error("wm-uploader: empty-state-text is a required prop");this.parseFiles(),this.clearErrors(),this.parseRejectedFiles()}componentDidLoad(){document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn()}uploadButtonOnClick(t){this.isDisabled?(t.preventDefault(),this.numFilesInProgress>0?this.announce(l.waitToUpload):this.fileLimitReached&&(this.internalErrorMessage=l.fileLimitReached,this.announce(l.fileLimitReached))):this.clearErrors()}renderUploadSvg(){return i("svg",{class:"upload-file",width:"91",height:"84",viewBox:"0 0 91 84"},i("path",{transform:"rotate(-180.000000) translate(-452, -255.5)",fill:"#eae8ec",d:"M361,249.681818 L361,197.318182 C361,194.118182 365.555061,191.5 371.122358,191.5 L391.316463,191.5 L391.286495,200.562515 L369.871211,200.600292 L369.885404,200.622146 L369.886423,246.655947 L443.657038,246.840767 L443.657038,200.622146 L421.683537,200.622146 L421.683537,191.5 L441.978865,191.5 C447.546162,191.5 452,194.118182 452,197.318182 L452,249.681818 C452,252.881818 447.546162,255.5 441.978865,255.5 L371.122358,255.5 C365.504449,255.5 361,252.881818 361,249.681818 Z M391.5,207 L406,221 L420.5,207 L409.625,207 L409.625,172 L402.375,172 L402.375,207 L391.5,207 Z"}))}renderIcon(){return this.icon&&i("span",{class:"mdi "+(this.icon&&"f066"===this.icon?"rotate":"")},String.fromCodePoint(parseInt(`0x${this.icon}`)))}renderInfo(){return this.info&&"2"===this.tempUploaderType?i("span",{class:"info"},this.info):""}renderNotif(){return i("div",{class:"notif"},this.notif)}renderError(){return i("div",{id:"error"},this.displayedErrorMessage)}renderUploadButton(t){return i("div",{class:"info-wrapper"},i("input",{name:this.inputId,id:this.inputId,class:"sr-only","aria-label":`${this.label&&this.label!==this.buttonText?`${this.label}, `:""}${this.buttonText}`,"aria-required":this.requiredField?"true":null,"aria-describedby":(this.displayedErrorMessage?"error ":"")+"file-count max-size accepted-types",type:"file",multiple:!0,onClick:t=>this.uploadButtonOnClick(t),onChange:t=>this.handleFiles(t)}),i("label",{htmlFor:this.inputId,class:`wm-button ${t}${this.isTabbing?" user-is-tabbing":""}`},this.renderIcon(),this.buttonText),this.renderInfo())}renderEmptyState(){return i("div",{class:"empty-block"},this.renderUploadSvg(),i("div",{class:"empty-message"},this.emptyStateText),this.renderUploadButton("-primary empty-button"),this.notif&&this.renderNotif(),this.displayedErrorMessage&&this.renderError())}renderErrorList(){let t=this.errorList.reduce((function(t,e){return t+`${e.name}: ${e.message} `}),"");return this.announce(t),i("ul",{class:"error-list"},this.errorList.map((t=>i("wm-file",{file:`{"name": "${t.name}"}`,"error-message":t.message}))))}formatTimestamp(t){const e=new Date(Date.parse(t)),o=e.getDate();return`${e.getMonth()+1}/${o}/${e.getFullYear()} ${e.toLocaleTimeString("en-us",{hour:"numeric",minute:"2-digit"})}`}renderInProgressFileList(){return i("ul",{class:"inprogress-list"},this.fileList.filter((t=>this.isItemUploading(t))).map((t=>i("wm-file",{file:JSON.stringify(t),"show-info":this.showInfo}))))}renderUploadedFileList(){return i("ul",{class:"file-list"},this.fileList.filter((t=>!this.isItemUploading(t))).map((t=>(t.lastUpdated=this.formatTimestamp(t.lastUpdated),i("wm-file",{id:`file-${t.id}`,file:JSON.stringify(t),"show-info":this.showInfo})))))}renderFiles(){return this.fileList.sort("name"===this.sortBy?(t,e)=>t.name.localeCompare(e.name):(t,e)=>Date.parse(t.lastUpdated)-Date.parse(e.lastUpdated)),i("div",null,this.renderInProgressFileList(),this.renderUploadedFileList())}legacyRenderHeader(){return i("div",{class:"header "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},i("div",{class:"slot-wrapper"},i("slot",null),i("div",{class:"notif-wrapper "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},this.renderUploadButton("-secondary "+(this.isDisabled?"disabled":"")),this.notif&&this.renderNotif(),this.displayedErrorMessage&&this.renderError())))}renderHeader(){const t="."+this.fileTypes.split(" ").join(", .");return i("div",{class:"header "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},i("div",{class:"notif-wrapper "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},this.renderUploadButton("-secondary "+(this.isDisabled?"disabled":"")),this.renderRequirements()),i("div",{id:"accepted-types",class:"accepted-types"},l.getAcceptedFileTypes(t,this.fileTypes.split(" ").length)),this.notif&&this.renderNotif(),this.displayedErrorMessage&&this.renderError())}renderRequirements(){return i("div",{class:"requirements"},this.maxFiles&&i("span",{id:"file-count"},l.getFileCount(this.fileList.length,this.maxFiles)),this.maxSize&&i("span",{id:"max-size"},l.getMaxSize(this.effectiveMaxSize)))}renderFooter(){return i("div",{class:"footer"},i("div",{class:"notif-wrapper "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},i("div",{class:"filecount-wrapper"},i("div",{class:"filecount"},l.getFilesAdded(this.fileList.length)),this.renderUploadButton("-primary "+(this.isDisabled?"disabled":""))),this.notif&&this.renderNotif(),this.displayedErrorMessage&&this.renderError()))}renderWithItems(){const t=this.fileList.filter((t=>t.progress===("number"==typeof t.progress?100:"100"))).length>0;return i("div",null,!this.tempUploaderType&&this.renderHeader(),"2"===this.tempUploaderType&&this.legacyRenderHeader(),i("div",{class:`list-container type${this.tempUploaderType} ${!this.tempUploaderType&&t?"checkmark-spacer":""}`},this.errorList.length>0&&this.renderErrorList(),this.fileList.length>0&&this.renderFiles()),"1"===this.tempUploaderType&&this.renderFooter())}renderLabel(){return i("div",{class:"wrapper "+(this.displayedErrorMessage?"invalid":"")},i("div",{id:"label",class:"label"},this.label,this.requiredField&&i("span",{class:"required","aria-hidden":"true"},"*")))}render(){return i(r,null,this.label&&this.renderLabel(),this.isEmpty()&&"1"===this.tempUploaderType?this.renderEmptyState():this.renderWithItems(),i("div",{ref:t=>this.liveRegion=t,class:"live-region sr-only","aria-live":"assertive","aria-atomic":"true"},this.announcement))}static get delegatesFocus(){return!0}get el(){return n(this)}static get watchers(){return{files:["parseFiles"],fileList:["focusAfterRemoval"],rejectedFiles:["parseRejectedFiles"],numFilesInProgress:["uploadNotifications"],errorMessage:["handleErrorMessageChange"]}}};d.style=':host .wm-button,wm-uploader .wm-button{-ms-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-webkit-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-moz-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-webkit-border-radius:5px;-moz-border-radius:5px;-ms-border-radius:5px;border-radius:5px;width:100%;border:2px solid #575195;color:#575195;font-family:inherit;font-size:0.75rem;font-weight:700;min-height:2.75rem;padding:12px 1.3333333333em;cursor:pointer;position:relative;background:#fff;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;text-decoration:none;text-transform:uppercase;letter-spacing:0.01875rem;overflow-wrap:break-word;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}@media screen and (min-width: 48rem){:host .wm-button,wm-uploader .wm-button{min-height:3.3333333333em}}:host .wm-button.nowrap,wm-uploader .wm-button.nowrap{display:inline-block;width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host .wm-button:focus,wm-uploader .wm-button:focus{outline:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button::-moz-focus-inner,wm-uploader .wm-button::-moz-focus-inner{border:0;outline:none}:host .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) :host .wm-button.-textonly .button-text,wm-uploader .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) :host .wm-button.-textonly .button-text,:host .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) wm-uploader .wm-button.-textonly .button-text,wm-uploader .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) wm-uploader .wm-button.-textonly .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled),wm-uploader .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark),wm-uploader .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark){-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark)::-moz-focus-inner,wm-uploader .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark)::-moz-focus-inner{border:0}:host .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled),wm-uploader .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled){background:transparent;border:2px solid #fff;color:#fff}:host .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled):hover,wm-uploader .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled):hover{color:#575195;background:#e6e6e6;border:2px solid #e6e6e6}:host .wm-button.dark.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled).dark,wm-uploader .wm-button.dark.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled).dark{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;outline:none}:host .wm-button:active:not(:disabled):not(.disabled):not(.-textonly):not(.-actionbutton):not(.displayedoption),wm-uploader .wm-button:active:not(:disabled):not(.disabled):not(.-textonly):not(.-actionbutton):not(.displayedoption){-ms-transform:scale(0.9, 0.9);-webkit-transform:scale(0.9, 0.9);-moz-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9)}:host .wm-button .mdi,wm-uploader .wm-button .mdi{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button:not(.-icononly):not(.-navigational) .mdi,wm-uploader .wm-button:not(.-icononly):not(.-navigational) .mdi{margin-right:0.3125rem;font-size:0.875rem}:host .wm-button[dir=RTL] :not(.-icononly) .mdi,wm-uploader .wm-button[dir=RTL] :not(.-icononly) .mdi{margin-left:0.3125rem;margin-right:0}:host .wm-button.-primary:not(.-textonly),wm-uploader .wm-button.-primary:not(.-textonly){background:#575195;color:#fff}:host .wm-button.-primary:not(.-textonly):not(:focus),wm-uploader .wm-button.-primary:not(.-textonly):not(:focus){-webkit-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2)}:host .wm-button.-primary:not(.-textonly):hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-primary:not(.-textonly):hover:not(:disabled):not(.disabled){background:#464177}:host .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled),wm-uploader .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled){color:#575195;background:#fff;border:2px solid #fff}:host .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled):hover,wm-uploader .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled):hover{color:#575195;background:#e6e6e6;border:2px solid #e6e6e6}:host .wm-button.-secondary:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-secondary:hover:not(:disabled):not(.disabled),:host .wm-button.-selector:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-selector:hover:not(:disabled):not(.disabled),:host .wm-button.-icononly:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-icononly:hover:not(:disabled):not(.disabled){background:#464177;color:#fff}:host .wm-button.-textonly,wm-uploader .wm-button.-textonly{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;display:inline-block;letter-spacing:0;text-transform:none;text-align:initial;font-size:0.875rem;border:none;background:transparent;padding:0;height:auto;min-height:unset;border-radius:0;line-height:1;overflow-wrap:anywhere}:host .wm-button.-textonly+.-textonly,wm-uploader .wm-button.-textonly+.-textonly{margin-left:0.3125rem}:host .wm-button.-textonly:focus,wm-uploader .wm-button.-textonly:focus{outline:none}:host .wm-button.-textonly::-moz-focus-inner,wm-uploader .wm-button.-textonly::-moz-focus-inner{border:0;outline:none}:host .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled) .button-text,wm-uploader .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled) .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled).dark .button-text,wm-uploader .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled).dark .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #fff), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #fff 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.-textonly.small,wm-uploader .wm-button.-textonly.small{font-size:0.625rem}:host .wm-button.-textonly:hover:not(:disabled):not(.disabled):not(.-permanentlydelete),wm-uploader .wm-button.-textonly:hover:not(:disabled):not(.disabled):not(.-permanentlydelete){text-decoration:underline}:host .wm-button.-textonly.-permanentlydelete,wm-uploader .wm-button.-textonly.-permanentlydelete{color:#c0392b}:host .wm-button.-textonly.-permanentlydelete:hover:not(:disabled):not(.disabled):not(.dark),wm-uploader .wm-button.-textonly.-permanentlydelete:hover:not(:disabled):not(.disabled):not(.dark){text-decoration:underline;color:#c0392b !important}:host .wm-button.-textonly.dark,wm-uploader .wm-button.-textonly.dark{color:#fff}:host .wm-button.-textonly.dark:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-textonly.dark:hover:not(:disabled):not(.disabled){text-decoration:underline;color:#fff !important}:host .wm-button.-icononly,wm-uploader .wm-button.-icononly,:host .wm-button.-navigational,wm-uploader .wm-button.-navigational{-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;font-size:1rem;padding:0;height:auto;line-height:1;min-width:2.75rem;min-height:2.75rem;text-align:center;letter-spacing:normal}:host .wm-button.-icononly:not(:focus),wm-uploader .wm-button.-icononly:not(:focus),:host .wm-button.-navigational:not(:focus),wm-uploader .wm-button.-navigational:not(:focus){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}@media screen and (min-width: 48rem){:host .wm-button.-icononly,wm-uploader .wm-button.-icononly,:host .wm-button.-navigational,wm-uploader .wm-button.-navigational{min-width:2.5rem;min-height:2.5rem}}:host .wm-button.-icononly .mdi,wm-uploader .wm-button.-icononly .mdi,:host .wm-button.-navigational .mdi,wm-uploader .wm-button.-navigational .mdi{font-size:1.12rem}:host .wm-button.-icononly,wm-uploader .wm-button.-icononly{border-width:1px !important}:host .wm-button.-icononly:before,wm-uploader .wm-button.-icononly:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button.-navigational,wm-uploader .wm-button.-navigational{border:none !important;background-color:transparent}:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled),wm-uploader .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled){color:#575195}:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled):hover,wm-uploader .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled):hover,:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled).selected,wm-uploader .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled).selected{background-color:#d7d6d9}:host .wm-button.-navigational:before,wm-uploader .wm-button.-navigational:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button.-permanentlydelete:not(.-textonly),wm-uploader .wm-button.-permanentlydelete:not(.-textonly){background:#c0392b;border-color:#c0392b;color:#fff}:host .wm-button.-permanentlydelete:not(.-textonly):hover:not(:disabled):not(.disabled):not(.dark),wm-uploader .wm-button.-permanentlydelete:not(.-textonly):hover:not(:disabled):not(.disabled):not(.dark){background:#9a2e22;border-color:#9a2e22}:host .wm-button.-pairnegative,wm-uploader .wm-button.-pairnegative{background:#cc4c3e;border-color:#cc4c3e;color:#fff}:host .wm-button.-pairnegative:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-pairnegative:hover:not(:disabled):not(.disabled){background:#a33d32;border-color:#a33d32}:host .wm-button.-pairpositive,wm-uploader .wm-button.-pairpositive{background:#15868d;border-color:#15868d;color:#fff}:host .wm-button.-pairpositive:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-pairpositive:hover:not(:disabled):not(.disabled){background:#116b71;border-color:#116b71}:host .wm-button.-selector,wm-uploader .wm-button.-selector,:host .wm-button.-selector-primary,wm-uploader .wm-button.-selector-primary{-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;display:block;background:transparent;border:2px solid #575195;border-radius:3px;height:2.75rem;min-width:11.4375rem;padding:0 1.875rem 0 0.9375rem;line-height:normal;font-family:inherit;color:#575195;font-weight:700;font-size:0.75rem;text-transform:uppercase;letter-spacing:0.01875rem;text-align:left}@media screen and (min-width: 48rem){:host .wm-button.-selector,wm-uploader .wm-button.-selector,:host .wm-button.-selector-primary,wm-uploader .wm-button.-selector-primary{height:2.5rem}}:host .wm-button.-selector:before,wm-uploader .wm-button.-selector:before,:host .wm-button.-selector-primary:before,wm-uploader .wm-button.-selector-primary:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f140";position:absolute;right:0.5625rem;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%);font-size:1.12rem;font-weight:700;pointer-events:none}:host .wm-button.-selector:active,wm-uploader .wm-button.-selector:active,:host .wm-button.-selector-primary:active,wm-uploader .wm-button.-selector-primary:active{-ms-transform:scale(1, 1) !important;-webkit-transform:scale(1, 1) !important;transform:scale(1, 1) !important}:host .wm-button.-selector::-moz-focus-inner,wm-uploader .wm-button.-selector::-moz-focus-inner,:host .wm-button.-selector-primary::-moz-focus-inner,wm-uploader .wm-button.-selector-primary::-moz-focus-inner{border:0}:host .wm-button.-selector .overflowcontrol,wm-uploader .wm-button.-selector .overflowcontrol,:host .wm-button.-selector-primary .overflowcontrol,wm-uploader .wm-button.-selector-primary .overflowcontrol{display:block;white-space:nowrap;text-overflow:ellipsis;overflow:visible}:host .wm-button.-selector.dark:not(:disabled):not(.disabled):hover,wm-uploader .wm-button.-selector.dark:not(:disabled):not(.disabled):hover,:host .wm-button.-selector-primary.dark:not(:disabled):not(.disabled):hover,wm-uploader .wm-button.-selector-primary.dark:not(:disabled):not(.disabled):hover{color:#575195;background:#e6e6e6;border:2px solid #e6e6e6}:host .wm-button.-selector-primary,wm-uploader .wm-button.-selector-primary{background:#575195;color:#fff}:host .wm-button.-selector-primary:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-selector-primary:hover:not(:disabled):not(.disabled){background:#464177}:host .wm-button.-selector-primary.dark:not(:disabled):not(.disabled),wm-uploader .wm-button.-selector-primary.dark:not(:disabled):not(.disabled){color:#575195;background:#fff;border:2px solid #fff}:host .wm-button:disabled,wm-uploader .wm-button:disabled,:host .wm-button.disabled,wm-uploader .wm-button.disabled{background:inherit;border-color:#737373;color:#737373;cursor:default;pointer-events:none}:host .wm-button:disabled.-primary,wm-uploader .wm-button:disabled.-primary,:host .wm-button:disabled.-permanentlydelete,wm-uploader .wm-button:disabled.-permanentlydelete,:host .wm-button:disabled.-pairnegative,wm-uploader .wm-button:disabled.-pairnegative,:host .wm-button:disabled.-pairpositive,wm-uploader .wm-button:disabled.-pairpositive,:host .wm-button.disabled.-primary,wm-uploader .wm-button.disabled.-primary,:host .wm-button.disabled.-permanentlydelete,wm-uploader .wm-button.disabled.-permanentlydelete,:host .wm-button.disabled.-pairnegative,wm-uploader .wm-button.disabled.-pairnegative,:host .wm-button.disabled.-pairpositive,wm-uploader .wm-button.disabled.-pairpositive{background:#737373;color:#fff;border-color:#737373}:host .wm-button:disabled.-secondary,wm-uploader .wm-button:disabled.-secondary,:host .wm-button.disabled.-secondary,wm-uploader .wm-button.disabled.-secondary{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button:disabled.-selector,wm-uploader .wm-button:disabled.-selector,:host .wm-button.disabled.-selector,wm-uploader .wm-button.disabled.-selector{color:#737373}:host .wm-button:disabled.-selector-primary,wm-uploader .wm-button:disabled.-selector-primary,:host .wm-button.disabled.-selector-primary,wm-uploader .wm-button.disabled.-selector-primary{background:#737373;color:#fff;border-color:#737373}:host .wm-button:disabled.-textonly,wm-uploader .wm-button:disabled.-textonly,:host .wm-button.disabled.-textonly,wm-uploader .wm-button.disabled.-textonly{color:#6b6b6b;background:transparent}:host .wm-button:disabled.dark.-secondary:not(.-permanentlydelete),wm-uploader .wm-button:disabled.dark.-secondary:not(.-permanentlydelete),:host .wm-button:disabled.dark.-selector,wm-uploader .wm-button:disabled.dark.-selector,:host .wm-button:disabled.dark.-textonly,wm-uploader .wm-button:disabled.dark.-textonly,:host .wm-button:disabled.dark.-navigational,wm-uploader .wm-button:disabled.dark.-navigational,:host .wm-button:disabled.dark.-icononly,wm-uploader .wm-button:disabled.dark.-icononly,:host .wm-button.disabled.dark.-secondary:not(.-permanentlydelete),wm-uploader .wm-button.disabled.dark.-secondary:not(.-permanentlydelete),:host .wm-button.disabled.dark.-selector,wm-uploader .wm-button.disabled.dark.-selector,:host .wm-button.disabled.dark.-textonly,wm-uploader .wm-button.disabled.dark.-textonly,:host .wm-button.disabled.dark.-navigational,wm-uploader .wm-button.disabled.dark.-navigational,:host .wm-button.disabled.dark.-icononly,wm-uploader .wm-button.disabled.dark.-icononly{color:#b5b5b5;border-color:#b5b5b5}:host .wm-button:disabled.dark.-primary,wm-uploader .wm-button:disabled.dark.-primary,:host .wm-button:disabled.dark.-selector-primary,wm-uploader .wm-button:disabled.dark.-selector-primary,:host .wm-button:disabled.dark.-permanentlydelete:not(.-textonly),wm-uploader .wm-button:disabled.dark.-permanentlydelete:not(.-textonly),:host .wm-button.disabled.dark.-primary,wm-uploader .wm-button.disabled.dark.-primary,:host .wm-button.disabled.dark.-selector-primary,wm-uploader .wm-button.disabled.dark.-selector-primary,:host .wm-button.disabled.dark.-permanentlydelete:not(.-textonly),wm-uploader .wm-button.disabled.dark.-permanentlydelete:not(.-textonly){background:#a6a6a6;border-color:#a6a6a6;color:#353b48}:host a.wm-button,wm-uploader a.wm-button,:host label.wm-button,wm-uploader label.wm-button{height:auto;padding-top:0.75rem;padding-bottom:0.75rem}:host,wm-uploader{display:block;position:relative;max-width:1140px}:host[dir=RTL] .mdi,wm-uploader[dir=RTL] .mdi{margin-left:0.3125rem;margin-right:0}:host input:focus+.wm-button.user-is-tabbing,wm-uploader input:focus+.wm-button.user-is-tabbing{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e !important;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e !important;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e !important}:host *,wm-uploader *{-webkit-box-sizing:border-box;box-sizing:border-box}.wm-button.disabled{pointer-events:initial !important}.wrapper{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-size:0.875rem}.wrapper .label{display:block;line-height:normal;font-weight:600;white-space:nowrap;margin-bottom:0.25rem}.wrapper .label .required{color:#c0392b}.wrapper.label-left{-ms-flex-direction:row;flex-direction:row}.wrapper.label-left .label-wrapper{line-height:2.5rem}.wrapper.label-left .label-wrapper .label{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;min-height:2.5rem;white-space:normal;margin-bottom:0;margin-right:0.75rem}.wrapper.label-none label{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}.wrapper.invalid .label{color:#c0392b}.wrapper.invalid .label:after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f026";margin-left:0.3125rem}[dir=RTL] .wrapper.invalid .label:after{margin-left:0;margin-right:0.3125rem}.wrapper.rtl.label-left .label{margin-right:0;margin-left:0.75rem}#label{margin-bottom:0.5rem}.header .info-wrapper{-ms-flex-align:center;align-items:center}.header .info-wrapper .info{font-size:0.875rem;margin-left:1rem}.header .accepted-types{font-size:0.875rem}.header .requirements{font-size:0.875rem;margin-left:1rem}.footer{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:end;align-items:flex-end;padding:0.9375rem 1.875rem}.footer .notif-wrapper{-ms-flex-align:end;align-items:flex-end}.footer .filecount-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.footer .filecount-wrapper .filecount{font-size:0.875rem;margin-right:1rem}.notif-wrapper{position:relative;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;margin-bottom:0.75rem}.notif-wrapper .requirements{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.notif,#error{padding-top:0.25rem;font-size:0.875rem;font-style:italic}.notif#error,#error#error{display:block;font-style:italic;color:#c0392b;font-size:0.875rem;margin-top:0.25rem}.info-wrapper{position:relative;display:-ms-flexbox;display:flex}.list-container{overflow-y:unset}.list-container.checkmark-spacer{margin-right:2.75rem}.list-container:has(.error-list,.inprogress-list,.file-list){margin-top:2.5rem}.list-container ul{padding:0;width:100%;margin:0}.list-container ul wm-file{margin-bottom:0.5rem}.sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}.empty-block{margin:5rem auto;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center}.empty-block .upload-file{margin-bottom:1.875rem}.empty-block .empty-message{font-size:0.875rem;margin-bottom:0.4375rem}.empty-block .empty-message.large{font-size:1.5rem}.empty-block .info-wrapper{-ms-flex-pack:center;justify-content:center;width:100%}.empty-block .info-wrapper .wm-button{width:auto}.header.type1,.header.type2{margin-bottom:1rem}.header .slot-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:start;justify-content:flex-start;-ms-flex-align:start;align-items:flex-start}.notif-wrapper.type1,.notif-wrapper.type2{-ms-flex-direction:column;flex-direction:column;margin-bottom:1rem}.list-container.type1,.list-container.type2{overflow-y:auto}.list-container.type1 ul,.list-container.type2 ul{margin:revert}.list-container.type1 .file-list li,.list-container.type1 .inprogress-list li,.list-container.type2 .file-list li,.list-container.type2 .inprogress-list li{margin-bottom:1.625rem}.list-container.type1 .error-list li,.list-container.type2 .error-list li{margin-bottom:1.25rem}.list-container.type1{padding:0 1.875rem;height:16.25rem}';export{d as wm_uploader}
|
|
1
|
+
import{r as t,c as e,f as o,h as i,H as r,g as n}from"./p-b5dee715.js";import{g as a,v as s}from"./p-91480a89.js";import{u as l}from"./p-4698b365.js";const d=class{constructor(o){t(this,o),this.wmUploaderFilesSelected=e(this,"wmUploaderFilesSelected",7),this.wmFilesSelected=e(this,"wmFilesSelected",7),this.wmUploaderDeleteFile=e(this,"wmUploaderDeleteFile",7),this.wmDeleteFile=e(this,"wmDeleteFile",7),this.wmUploaderDownloadFile=e(this,"wmUploaderDownloadFile",7),this.wmDownloadFile=e(this,"wmDownloadFile",7),this.wmUploaderPreviewFile=e(this,"wmUploaderPreviewFile",7),this.wmFileDelete=e(this,"wmFileDelete",7),this.wmFileDownload=e(this,"wmFileDownload",7),this.wmFilePreview=e(this,"wmFilePreview",7),this.inputId=a(),this.uploaderType=void 0,this.type=void 0,this.label=void 0,this.buttonText=void 0,this.info=void 0,this.emptyStateText=void 0,this.icon=void 0,this.fileTypes="pdf txt log xml doc docx xls xlsx ppt pptx gif jpg jpeg png csv",this.maxSize=void 0,this.maxFiles=void 0,this.sortBy="date",this.showInfo="time",this.errorMessage=void 0,this.requiredField=void 0,this.files=void 0,this.fileList=[],this.filesToUpload=[],this.isTabbing=!1,this.rejectedFiles=void 0,this.errorList=[],this.notif=void 0,this.internalErrorMessage=void 0,this.announcement="",this.numFilesInProgress=void 0,this.isCondensed=!1}get uploadButtonEl(){return this.el.shadowRoot.querySelector(`#${this.inputId}`)}get tempUploaderType(){return this.type||this.uploaderType}get effectiveMaxSize(){return this.maxSize?Math.min(this.maxSize,100):100}get fileLimitReached(){return this.maxFiles&&this.fileList.length>=this.maxFiles}get displayedErrorMessage(){return this.errorMessage||this.internalErrorMessage||""}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleUploadProgress(t){if(this.fileList.map((e=>{e.id===t.detail.id&&(e.progress=t.detail.progress,o(this.el))})),100===t.detail.progress&&(this.numFilesInProgress-=1),!this.srProgress&&this.numFilesInProgress){const t=this.numFilesInProgress;this.srProgress=setInterval((()=>{const e=this.fileList.reduce(((t,e)=>e.progress?t+e.progress:t),0);this.announce(l.getUploadProgress(Math.floor(e/t)))}),5e3)}}handleFileErrorCleared(t){const e=t.detail.name;this.errorList=this.errorList.filter((t=>t.name!=e)),this.uploadButtonEl.focus()}handleFileDeleted(t){this.clearErrors(),o(this.el),this.wmUploaderDeleteFile.emit(t.detail),this.wmFileDelete.emit(t.detail),this.wmDeleteFile.emit(t.detail)}handleFilePreviewed(t){this.clearErrors(),this.wmUploaderPreviewFile.emit(t.detail),this.wmFilePreview.emit(t.detail)}handleFileDownloaded(t){this.clearErrors(),this.wmUploaderDownloadFile.emit(t.detail),this.wmFileDownload.emit(t.detail),this.wmDownloadFile.emit(t.detail)}parseFiles(){if(this.files){if("string"!=typeof this.files)throw new Error("Attribute 'files' should be a string");{let t=JSON.parse(this.files);if("object"!=typeof t)throw new Error("could not parse string passed to files attribute");t.forEach((t=>{if(t.size&&("number"==typeof t.size||t.size.match(/^[0-9]+$/))){const e=this.convertBytes(t.size);t.size=`${e.size.toFixed(0)} ${e.unit}`}})),this.fileList=t}}}focusAfterRemoval(t,e){if(this.isTabbing&&t.length<e.length){const o=t.map((t=>t.id)),i=e.map((t=>t.id)),r=i.filter((t=>!o.includes(t)))[0];if(i.indexOf(r)>0){const o=i[i.indexOf(r)-1],n=this.el.shadowRoot.querySelector("#file-"+o),a=null==n?void 0:n.shadowRoot.querySelectorAll("wm-button");a&&a.length>0?a[a.length-1].focus():this.focusAfterRemoval(t.filter((t=>t.id!==o)),e)}else this.uploadButtonEl.focus()}}parseRejectedFiles(){if(this.rejectedFiles){if("string"!=typeof this.files)throw new Error("Attribute 'rejected-files' should be a string");{const t=JSON.parse(this.rejectedFiles);if("object"!=typeof t)throw new Error("could not parse string passed to errors attribute");this.errorList=t}}}uploadNotifications(t,e){e>0&&0===t?(setTimeout((()=>{this.notif="",this.internalErrorMessage=""}),2e4),this.notif=l.finishedUploading,this.announce(l.finishedUploading),this.numFilesInProgress=null,clearInterval(this.srProgress),o(this.el)):t>0&&t!=e&&(this.notif=l.getFilesUploading(t),this.announce(l.getFilesUploading(t)),o(this.el))}handleErrorMessageChange(){this.errorMessage&&this.announce(this.errorMessage)}isValidSize(t){return this.convertBytes(t,"MB").size<=this.effectiveMaxSize}convertBytes(t,e){const o=["bytes","KB","MB","GB","TB"];let i=0,r="number"==typeof t?t:parseInt(t);if(e)for(;o.indexOf(e)>i;)r/=1024,i++;else for(;r>1e3;)r/=1024,i++;return{size:r,unit:o[i]}}isDuplicate(t){const e=this.filesToUpload.some((e=>e.name===t)),o=this.fileList.some((e=>(e.type?e.name+"."+e.type:e.name)===t));return e||o}isEmpty(){return!this.fileList.length&&!this.errorList.length}get isDisabled(){return this.fileLimitReached||this.numFilesInProgress>0}isItemUploading(t){return t.hasOwnProperty("progress")&&t.progress<100}announce(t){this.liveRegion.textContent===t&&(t+=" "),this.announcement=t}clearErrors(){this.errorList=[],this.notif="",this.internalErrorMessage=""}handleFiles(t){this.filesToUpload=[];const e=Array.from(t.target.files),o=this.fileTypes.split(" ").join(", ");this.maxFiles&&this.fileList.length+e.length>this.maxFiles?(this.internalErrorMessage=l.fileLimitExceeded,this.announce(l.fileLimitExceeded)):(e&&e.map((t=>{if(s(t,this.fileTypes))if(0===t.size)this.errorList.push({name:t.name,message:l.zeroFileSize});else if(this.isValidSize(t.size))this.isDuplicate(t.name)?this.errorList.push({name:t.name,message:l.duplicateName}):this.filesToUpload.push(t);else{const e={name:t.name,message:l.getFileTooLarge(this.effectiveMaxSize)};this.errorList.push(e)}else{const e={name:t.name,message:l.getInvalidFileType(o)};this.errorList.push(e)}})),this.filesToUpload.length>0&&(this.numFilesInProgress=this.filesToUpload.length,this.wmUploaderFilesSelected.emit(this.filesToUpload),this.wmFilesSelected.emit(this.filesToUpload))),t.target.value=""}componentWillLoad(){if(!this.buttonText)throw new Error("wm-uploader: button-text is a required prop");if(this.type&&console.warn("wm-uploader: type has been deprecated as of v3.1.0. Please use uploader-type instead."),"1"===this.tempUploaderType&&!this.emptyStateText)throw new Error("wm-uploader: empty-state-text is a required prop");this.parseFiles(),this.clearErrors(),this.parseRejectedFiles()}componentDidLoad(){document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn()}uploadButtonOnClick(t){this.isDisabled?(t.preventDefault(),this.numFilesInProgress>0?this.announce(l.waitToUpload):this.fileLimitReached&&(this.internalErrorMessage=l.fileLimitReached,this.announce(l.fileLimitReached))):this.clearErrors()}renderUploadSvg(){return i("svg",{class:"upload-file",width:"91",height:"84",viewBox:"0 0 91 84"},i("path",{transform:"rotate(-180.000000) translate(-452, -255.5)",fill:"#eae8ec",d:"M361,249.681818 L361,197.318182 C361,194.118182 365.555061,191.5 371.122358,191.5 L391.316463,191.5 L391.286495,200.562515 L369.871211,200.600292 L369.885404,200.622146 L369.886423,246.655947 L443.657038,246.840767 L443.657038,200.622146 L421.683537,200.622146 L421.683537,191.5 L441.978865,191.5 C447.546162,191.5 452,194.118182 452,197.318182 L452,249.681818 C452,252.881818 447.546162,255.5 441.978865,255.5 L371.122358,255.5 C365.504449,255.5 361,252.881818 361,249.681818 Z M391.5,207 L406,221 L420.5,207 L409.625,207 L409.625,172 L402.375,172 L402.375,207 L391.5,207 Z"}))}renderIcon(){return this.icon&&i("span",{class:"mdi "+(this.icon&&"f066"===this.icon?"rotate":"")},String.fromCodePoint(parseInt(`0x${this.icon}`)))}renderInfo(){return this.info&&"2"===this.tempUploaderType?i("span",{class:"info"},this.info):""}renderNotif(){return i("div",{class:"notif"},this.notif)}renderError(){return i("div",{id:"error"},this.displayedErrorMessage)}renderUploadButton(t){return i("div",{class:"info-wrapper"},i("input",{name:this.inputId,id:this.inputId,class:"sr-only","aria-label":`${this.label&&this.label!==this.buttonText?`${this.label}, `:""}${this.buttonText}`,"aria-required":this.requiredField?"true":null,"aria-describedby":(this.displayedErrorMessage?"error ":"")+"file-count max-size accepted-types",type:"file",multiple:!0,onClick:t=>this.uploadButtonOnClick(t),onChange:t=>this.handleFiles(t)}),i("label",{htmlFor:this.inputId,class:`wm-button ${t}${this.isTabbing?" user-is-tabbing":""}`},this.renderIcon(),this.buttonText),this.renderInfo())}renderEmptyState(){return i("div",{class:"empty-block"},this.renderUploadSvg(),i("div",{class:"empty-message"},this.emptyStateText),this.renderUploadButton("-primary empty-button"),this.notif&&this.renderNotif(),this.displayedErrorMessage&&this.renderError())}renderErrorList(){let t=this.errorList.reduce((function(t,e){return t+`${e.name}: ${e.message} `}),"");return this.announce(t),i("ul",{class:"error-list"},this.errorList.map((t=>i("wm-file",{file:`{"name": "${t.name}"}`,"error-message":t.message}))))}formatTimestamp(t){const e=new Date(Date.parse(t)),o=e.getDate();return`${e.getMonth()+1}/${o}/${e.getFullYear()} ${e.toLocaleTimeString("en-us",{hour:"numeric",minute:"2-digit"})}`}renderInProgressFileList(){return i("ul",{class:"inprogress-list"},this.fileList.filter((t=>this.isItemUploading(t))).map((t=>i("wm-file",{file:JSON.stringify(t),"show-info":this.showInfo}))))}renderUploadedFileList(){return i("ul",{class:"file-list"},this.fileList.filter((t=>!this.isItemUploading(t))).map((t=>(t.lastUpdated=this.formatTimestamp(t.lastUpdated),i("wm-file",{id:`file-${t.id}`,file:JSON.stringify(t),"show-info":this.showInfo})))))}renderFiles(){return this.fileList.sort("name"===this.sortBy?(t,e)=>t.name.localeCompare(e.name):(t,e)=>Date.parse(t.lastUpdated)-Date.parse(e.lastUpdated)),i("div",null,this.renderInProgressFileList(),this.renderUploadedFileList())}legacyRenderHeader(){return i("div",{class:"header "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},i("div",{class:"slot-wrapper"},i("slot",null),i("div",{class:"notif-wrapper "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},this.renderUploadButton("-secondary "+(this.isDisabled?"disabled":"")),this.notif&&this.renderNotif(),this.displayedErrorMessage&&this.renderError())))}renderHeader(){const t="."+this.fileTypes.split(" ").join(", .");return i("div",{class:"header "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},i("div",{class:"notif-wrapper "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},this.renderUploadButton("-secondary "+(this.isDisabled?"disabled":"")),this.renderRequirements()),i("div",{id:"accepted-types",class:"accepted-types"},l.getAcceptedFileTypes(t,this.fileTypes.split(" ").length)),this.notif&&this.renderNotif(),this.displayedErrorMessage&&this.renderError())}renderRequirements(){return i("div",{class:"requirements"},this.maxFiles&&i("span",{id:"file-count"},l.getFileCount(this.fileList.length,this.maxFiles)),this.maxSize&&i("span",{id:"max-size"},l.getMaxSize(this.effectiveMaxSize)))}renderFooter(){return i("div",{class:"footer"},i("div",{class:"notif-wrapper "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},i("div",{class:"filecount-wrapper"},i("div",{class:"filecount"},l.getFilesAdded(this.fileList.length)),this.renderUploadButton("-primary "+(this.isDisabled?"disabled":""))),this.notif&&this.renderNotif(),this.displayedErrorMessage&&this.renderError()))}renderWithItems(){const t=this.fileList.filter((t=>t.progress===("number"==typeof t.progress?100:"100"))).length>0;return i("div",null,!this.tempUploaderType&&this.renderHeader(),"2"===this.tempUploaderType&&this.legacyRenderHeader(),i("div",{class:`list-container type${this.tempUploaderType} ${!this.tempUploaderType&&t?"checkmark-spacer":""}`},this.errorList.length>0&&this.renderErrorList(),this.fileList.length>0&&this.renderFiles()),"1"===this.tempUploaderType&&this.renderFooter())}renderLabel(){return i("div",{class:"wrapper "+(this.displayedErrorMessage?"invalid":"")},i("div",{id:"label",class:"label"},this.label,this.requiredField&&i("span",{class:"required","aria-hidden":"true"},"*")))}render(){return i(r,null,this.label&&this.renderLabel(),this.isEmpty()&&"1"===this.tempUploaderType?this.renderEmptyState():this.renderWithItems(),i("div",{ref:t=>this.liveRegion=t,class:"live-region sr-only","aria-live":"assertive","aria-atomic":"true"},this.announcement))}static get delegatesFocus(){return!0}get el(){return n(this)}static get watchers(){return{files:["parseFiles"],fileList:["focusAfterRemoval"],rejectedFiles:["parseRejectedFiles"],numFilesInProgress:["uploadNotifications"],errorMessage:["handleErrorMessageChange"]}}};d.style=':host .wm-button,wm-uploader .wm-button{-ms-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-webkit-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-moz-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-webkit-border-radius:5px;-moz-border-radius:5px;-ms-border-radius:5px;border-radius:5px;width:100%;border:2px solid #575195;color:#575195;font-family:inherit;font-size:0.75rem;font-weight:700;min-height:2.75rem;padding:12px 1.3333333333em;cursor:pointer;position:relative;background:#fff;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;text-decoration:none;text-transform:uppercase;letter-spacing:0.01875rem;overflow-wrap:break-word;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}@media screen and (min-width: 48rem){:host .wm-button,wm-uploader .wm-button{min-height:3.3333333333em}}:host .wm-button.nowrap,wm-uploader .wm-button.nowrap{display:inline-block;width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host .wm-button:focus,wm-uploader .wm-button:focus{outline:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button::-moz-focus-inner,wm-uploader .wm-button::-moz-focus-inner{border:0;outline:none}:host .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) :host .wm-button.-textonly .button-text,wm-uploader .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) :host .wm-button.-textonly .button-text,:host .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) wm-uploader .wm-button.-textonly .button-text,wm-uploader .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) wm-uploader .wm-button.-textonly .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled),wm-uploader .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark),wm-uploader .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark){-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark)::-moz-focus-inner,wm-uploader .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark)::-moz-focus-inner{border:0}:host .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled),wm-uploader .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled){background:transparent;border:2px solid #fff;color:#fff}:host .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled):hover,wm-uploader .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled):hover{color:#575195;background:#e6e6e6;border:2px solid #e6e6e6}:host .wm-button.dark.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled).dark,wm-uploader .wm-button.dark.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled).dark{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;outline:none}:host .wm-button:active:not(:disabled):not(.disabled):not(.-textonly):not(.-actionbutton):not(.displayedoption),wm-uploader .wm-button:active:not(:disabled):not(.disabled):not(.-textonly):not(.-actionbutton):not(.displayedoption){-ms-transform:scale(0.9, 0.9);-webkit-transform:scale(0.9, 0.9);-moz-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9)}:host .wm-button .mdi,wm-uploader .wm-button .mdi{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button:not(.-icononly):not(.-navigational) .mdi,wm-uploader .wm-button:not(.-icononly):not(.-navigational) .mdi{margin-right:0.3125rem;font-size:0.875rem}:host .wm-button[dir=RTL] :not(.-icononly) .mdi,wm-uploader .wm-button[dir=RTL] :not(.-icononly) .mdi{margin-left:0.3125rem;margin-right:0}:host .wm-button.-primary:not(.-textonly),wm-uploader .wm-button.-primary:not(.-textonly){background:#575195;color:#fff}:host .wm-button.-primary:not(.-textonly):not(:focus),wm-uploader .wm-button.-primary:not(.-textonly):not(:focus){-webkit-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2)}:host .wm-button.-primary:not(.-textonly):hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-primary:not(.-textonly):hover:not(:disabled):not(.disabled){background:#464177}:host .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled),wm-uploader .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled){color:#575195;background:#fff;border:2px solid #fff}:host .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled):hover,wm-uploader .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled):hover{color:#575195;background:#e6e6e6;border:2px solid #e6e6e6}:host .wm-button.-secondary:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-secondary:hover:not(:disabled):not(.disabled),:host .wm-button.-selector:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-selector:hover:not(:disabled):not(.disabled),:host .wm-button.-icononly:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-icononly:hover:not(:disabled):not(.disabled){background:#464177;color:#fff}:host .wm-button.-textonly,wm-uploader .wm-button.-textonly{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;display:inline-block;letter-spacing:0;text-transform:none;text-align:initial;font-size:0.875rem;border:none;background:transparent;padding:0;height:auto;min-height:unset;border-radius:0;line-height:1;overflow-wrap:anywhere}:host .wm-button.-textonly+.-textonly,wm-uploader .wm-button.-textonly+.-textonly{margin-left:0.3125rem}:host .wm-button.-textonly:focus,wm-uploader .wm-button.-textonly:focus{outline:none}:host .wm-button.-textonly::-moz-focus-inner,wm-uploader .wm-button.-textonly::-moz-focus-inner{border:0;outline:none}:host .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled) .button-text,wm-uploader .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled) .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled).dark .button-text,wm-uploader .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled).dark .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #fff), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #fff 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.-textonly.small,wm-uploader .wm-button.-textonly.small{font-size:0.625rem}:host .wm-button.-textonly:hover:not(:disabled):not(.disabled):not(.-permanentlydelete),wm-uploader .wm-button.-textonly:hover:not(:disabled):not(.disabled):not(.-permanentlydelete){text-decoration:underline}:host .wm-button.-textonly.-permanentlydelete,wm-uploader .wm-button.-textonly.-permanentlydelete{color:#c0392b}:host .wm-button.-textonly.-permanentlydelete:hover:not(:disabled):not(.disabled):not(.dark),wm-uploader .wm-button.-textonly.-permanentlydelete:hover:not(:disabled):not(.disabled):not(.dark){text-decoration:underline;color:#c0392b !important}:host .wm-button.-textonly.dark,wm-uploader .wm-button.-textonly.dark{color:#fff}:host .wm-button.-textonly.dark:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-textonly.dark:hover:not(:disabled):not(.disabled){text-decoration:underline;color:#fff !important}:host .wm-button.-icononly,wm-uploader .wm-button.-icononly,:host .wm-button.-navigational,wm-uploader .wm-button.-navigational{-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;font-size:1rem;padding:0;height:auto;line-height:1;min-width:2.75rem;min-height:2.75rem;text-align:center;letter-spacing:normal}:host .wm-button.-icononly:not(:focus),wm-uploader .wm-button.-icononly:not(:focus),:host .wm-button.-navigational:not(:focus),wm-uploader .wm-button.-navigational:not(:focus){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}@media screen and (min-width: 48rem){:host .wm-button.-icononly,wm-uploader .wm-button.-icononly,:host .wm-button.-navigational,wm-uploader .wm-button.-navigational{min-width:2.5rem;min-height:2.5rem}}:host .wm-button.-icononly .mdi,wm-uploader .wm-button.-icononly .mdi,:host .wm-button.-navigational .mdi,wm-uploader .wm-button.-navigational .mdi{font-size:1.12rem}:host .wm-button.-icononly,wm-uploader .wm-button.-icononly{border-width:1px !important}:host .wm-button.-icononly:before,wm-uploader .wm-button.-icononly:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button.-navigational,wm-uploader .wm-button.-navigational{border:none !important;background-color:transparent}:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled),wm-uploader .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled){color:#575195}:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled):hover,wm-uploader .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled):hover,:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled).selected,wm-uploader .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled).selected{background-color:#d7d6d9}:host .wm-button.-navigational:before,wm-uploader .wm-button.-navigational:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button.-permanentlydelete:not(.-textonly),wm-uploader .wm-button.-permanentlydelete:not(.-textonly){background:#c0392b;border-color:#c0392b;color:#fff}:host .wm-button.-permanentlydelete:not(.-textonly):hover:not(:disabled):not(.disabled):not(.dark),wm-uploader .wm-button.-permanentlydelete:not(.-textonly):hover:not(:disabled):not(.disabled):not(.dark){background:#9a2e22;border-color:#9a2e22}:host .wm-button.-pairnegative,wm-uploader .wm-button.-pairnegative{background:#cc4c3e;border-color:#cc4c3e;color:#fff}:host .wm-button.-pairnegative:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-pairnegative:hover:not(:disabled):not(.disabled){background:#a33d32;border-color:#a33d32}:host .wm-button.-pairpositive,wm-uploader .wm-button.-pairpositive{background:#15868d;border-color:#15868d;color:#fff}:host .wm-button.-pairpositive:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-pairpositive:hover:not(:disabled):not(.disabled){background:#116b71;border-color:#116b71}:host .wm-button.-selector,wm-uploader .wm-button.-selector,:host .wm-button.-selector-primary,wm-uploader .wm-button.-selector-primary{-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;display:block;background:transparent;border:2px solid #575195;border-radius:3px;height:2.75rem;min-width:11.4375rem;padding:0 1.875rem 0 0.9375rem;line-height:normal;font-family:inherit;color:#575195;font-weight:700;font-size:0.75rem;text-transform:uppercase;letter-spacing:0.01875rem;text-align:left}@media screen and (min-width: 48rem){:host .wm-button.-selector,wm-uploader .wm-button.-selector,:host .wm-button.-selector-primary,wm-uploader .wm-button.-selector-primary{height:2.5rem}}:host .wm-button.-selector:before,wm-uploader .wm-button.-selector:before,:host .wm-button.-selector-primary:before,wm-uploader .wm-button.-selector-primary:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f140";position:absolute;right:0.5625rem;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%);font-size:1.12rem;font-weight:700;pointer-events:none}:host .wm-button.-selector:active,wm-uploader .wm-button.-selector:active,:host .wm-button.-selector-primary:active,wm-uploader .wm-button.-selector-primary:active{-ms-transform:scale(1, 1) !important;-webkit-transform:scale(1, 1) !important;transform:scale(1, 1) !important}:host .wm-button.-selector::-moz-focus-inner,wm-uploader .wm-button.-selector::-moz-focus-inner,:host .wm-button.-selector-primary::-moz-focus-inner,wm-uploader .wm-button.-selector-primary::-moz-focus-inner{border:0}:host .wm-button.-selector .overflowcontrol,wm-uploader .wm-button.-selector .overflowcontrol,:host .wm-button.-selector-primary .overflowcontrol,wm-uploader .wm-button.-selector-primary .overflowcontrol{display:block;white-space:nowrap;text-overflow:ellipsis;overflow:visible}:host .wm-button.-selector.dark:not(:disabled):not(.disabled):hover,wm-uploader .wm-button.-selector.dark:not(:disabled):not(.disabled):hover,:host .wm-button.-selector-primary.dark:not(:disabled):not(.disabled):hover,wm-uploader .wm-button.-selector-primary.dark:not(:disabled):not(.disabled):hover{color:#575195;background:#e6e6e6;border:2px solid #e6e6e6}:host .wm-button.-selector-primary,wm-uploader .wm-button.-selector-primary{background:#575195;color:#fff}:host .wm-button.-selector-primary:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-selector-primary:hover:not(:disabled):not(.disabled){background:#464177}:host .wm-button.-selector-primary.dark:not(:disabled):not(.disabled),wm-uploader .wm-button.-selector-primary.dark:not(:disabled):not(.disabled){color:#575195;background:#fff;border:2px solid #fff}:host .wm-button:disabled,wm-uploader .wm-button:disabled,:host .wm-button.disabled,wm-uploader .wm-button.disabled{background:inherit;border-color:#737373;color:#737373;cursor:default;pointer-events:none}:host .wm-button:disabled.-primary,wm-uploader .wm-button:disabled.-primary,:host .wm-button:disabled.-permanentlydelete,wm-uploader .wm-button:disabled.-permanentlydelete,:host .wm-button:disabled.-pairnegative,wm-uploader .wm-button:disabled.-pairnegative,:host .wm-button:disabled.-pairpositive,wm-uploader .wm-button:disabled.-pairpositive,:host .wm-button.disabled.-primary,wm-uploader .wm-button.disabled.-primary,:host .wm-button.disabled.-permanentlydelete,wm-uploader .wm-button.disabled.-permanentlydelete,:host .wm-button.disabled.-pairnegative,wm-uploader .wm-button.disabled.-pairnegative,:host .wm-button.disabled.-pairpositive,wm-uploader .wm-button.disabled.-pairpositive{background:#737373;color:#fff;border-color:#737373}:host .wm-button:disabled.-secondary,wm-uploader .wm-button:disabled.-secondary,:host .wm-button.disabled.-secondary,wm-uploader .wm-button.disabled.-secondary{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button:disabled.-selector,wm-uploader .wm-button:disabled.-selector,:host .wm-button.disabled.-selector,wm-uploader .wm-button.disabled.-selector{color:#737373}:host .wm-button:disabled.-selector-primary,wm-uploader .wm-button:disabled.-selector-primary,:host .wm-button.disabled.-selector-primary,wm-uploader .wm-button.disabled.-selector-primary{background:#737373;color:#fff;border-color:#737373}:host .wm-button:disabled.-textonly,wm-uploader .wm-button:disabled.-textonly,:host .wm-button.disabled.-textonly,wm-uploader .wm-button.disabled.-textonly{color:#6b6b6b;background:transparent}:host .wm-button:disabled.dark.-secondary:not(.-permanentlydelete),wm-uploader .wm-button:disabled.dark.-secondary:not(.-permanentlydelete),:host .wm-button:disabled.dark.-selector,wm-uploader .wm-button:disabled.dark.-selector,:host .wm-button:disabled.dark.-textonly,wm-uploader .wm-button:disabled.dark.-textonly,:host .wm-button:disabled.dark.-navigational,wm-uploader .wm-button:disabled.dark.-navigational,:host .wm-button:disabled.dark.-icononly,wm-uploader .wm-button:disabled.dark.-icononly,:host .wm-button.disabled.dark.-secondary:not(.-permanentlydelete),wm-uploader .wm-button.disabled.dark.-secondary:not(.-permanentlydelete),:host .wm-button.disabled.dark.-selector,wm-uploader .wm-button.disabled.dark.-selector,:host .wm-button.disabled.dark.-textonly,wm-uploader .wm-button.disabled.dark.-textonly,:host .wm-button.disabled.dark.-navigational,wm-uploader .wm-button.disabled.dark.-navigational,:host .wm-button.disabled.dark.-icononly,wm-uploader .wm-button.disabled.dark.-icononly{color:#b5b5b5;border-color:#b5b5b5}:host .wm-button:disabled.dark.-primary,wm-uploader .wm-button:disabled.dark.-primary,:host .wm-button:disabled.dark.-selector-primary,wm-uploader .wm-button:disabled.dark.-selector-primary,:host .wm-button:disabled.dark.-permanentlydelete:not(.-textonly),wm-uploader .wm-button:disabled.dark.-permanentlydelete:not(.-textonly),:host .wm-button.disabled.dark.-primary,wm-uploader .wm-button.disabled.dark.-primary,:host .wm-button.disabled.dark.-selector-primary,wm-uploader .wm-button.disabled.dark.-selector-primary,:host .wm-button.disabled.dark.-permanentlydelete:not(.-textonly),wm-uploader .wm-button.disabled.dark.-permanentlydelete:not(.-textonly){background:#a6a6a6;border-color:#a6a6a6;color:#353b48}:host a.wm-button,wm-uploader a.wm-button,:host label.wm-button,wm-uploader label.wm-button{height:auto;padding-top:0.75rem;padding-bottom:0.75rem}:host,wm-uploader{display:block;position:relative;max-width:1140px}:host[dir=RTL] .mdi,wm-uploader[dir=RTL] .mdi{margin-left:0.3125rem;margin-right:0}:host input:focus+.wm-button.user-is-tabbing,wm-uploader input:focus+.wm-button.user-is-tabbing{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e !important;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e !important;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e !important}:host *,wm-uploader *{-webkit-box-sizing:border-box;box-sizing:border-box}.wm-button.disabled{pointer-events:initial !important}.wrapper{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-size:0.875rem}.wrapper .label{display:block;line-height:normal;font-weight:600;white-space:nowrap;margin-bottom:0.25rem}.wrapper .label .required{color:#c0392b}.wrapper.label-left{-ms-flex-direction:row;flex-direction:row}.wrapper.label-left .label-wrapper{line-height:2.5rem}.wrapper.label-left .label-wrapper .label{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;min-height:2.5rem;white-space:normal;margin-bottom:0;margin-right:0.75rem}.wrapper.label-none label{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}.wrapper.invalid .label{color:#c0392b}.wrapper.invalid .label:after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f026";margin-left:0.3125rem}[dir=RTL] .wrapper.invalid .label:after{margin-left:0;margin-right:0.3125rem}.wrapper.rtl.label-left .label{margin-right:0;margin-left:0.75rem}#label{margin-bottom:0.5rem}.header .info-wrapper{-ms-flex-align:center;align-items:center}.header .info-wrapper .info{font-size:0.875rem;margin-left:1rem}.header .accepted-types{font-size:0.875rem}.header .requirements{font-size:0.875rem;margin-left:1rem}.footer{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:end;align-items:flex-end;padding:0.9375rem 1.875rem}.footer .notif-wrapper{-ms-flex-align:end;align-items:flex-end}.footer .filecount-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.footer .filecount-wrapper .filecount{font-size:0.875rem;margin-right:1rem}.notif-wrapper{position:relative;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;margin-bottom:0.75rem}.notif-wrapper .requirements{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.notif,#error{padding-top:0.25rem;font-size:0.875rem;font-style:italic}.notif#error,#error#error{display:block;font-style:italic;color:#c0392b;font-size:0.875rem;margin-top:0.25rem}.info-wrapper{position:relative;display:-ms-flexbox;display:flex}.list-container{overflow-y:unset}.list-container.checkmark-spacer{margin-right:2.75rem}.list-container:has(.error-list,.inprogress-list,.file-list){margin-top:2.5rem}.list-container ul{padding:0;width:100%;margin:0}.list-container ul wm-file{margin-bottom:0.5rem}.sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}.empty-block{margin:5rem auto;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center}.empty-block .upload-file{margin-bottom:1.875rem}.empty-block .empty-message{font-size:0.875rem;margin-bottom:0.4375rem}.empty-block .empty-message.large{font-size:1.5rem}.empty-block .info-wrapper{-ms-flex-pack:center;justify-content:center;width:100%}.empty-block .info-wrapper .wm-button{width:auto}.header.type1,.header.type2{margin-bottom:1rem}.header .slot-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:start;justify-content:flex-start;-ms-flex-align:start;align-items:flex-start}.notif-wrapper.type1,.notif-wrapper.type2{-ms-flex-direction:column;flex-direction:column;margin-bottom:1rem}.list-container.type1,.list-container.type2{overflow-y:auto}.list-container.type1 ul,.list-container.type2 ul{margin:revert}.list-container.type1 .file-list li,.list-container.type1 .inprogress-list li,.list-container.type2 .file-list li,.list-container.type2 .inprogress-list li{margin-bottom:1.625rem}.list-container.type1 .error-list li,.list-container.type2 .error-list li{margin-bottom:1.25rem}.list-container.type1{padding:0 1.875rem;height:16.25rem}';export{d as wm_uploader}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
System.register(["./p-c4ca5d46.system.js","./p-df28f438.system.js"],(function(e,t){"use strict";var a,i;return{setters:[function(t){a=t.p;i=t.b;e("setNonce",t.s)},function(){}],execute:function(){var e=function(){var e=t.meta.url;var i={};if(e!==""){i.resourcesUrl=new URL(".",e).href}return a(i)};e().then((function(e){return i(JSON.parse('[["p-b617b64f.system",[[17,"wm-uploader",{"uploaderType":[1025,"uploader-type"],"type":[1],"label":[1],"buttonText":[1,"button-text"],"info":[1],"emptyStateText":[1,"empty-state-text"],"icon":[1],"fileTypes":[1,"file-types"],"maxSize":[2,"max-size"],"maxFiles":[2,"max-files"],"sortBy":[1,"sort-by"],"showInfo":[1,"show-info"],"errorMessage":[1,"error-message"],"requiredField":[4,"required-field"],"files":[1],"filesToUpload":[1040],"rejectedFiles":[1,"rejected-files"],"fileList":[32],"isTabbing":[32],"errorList":[32],"notif":[32],"internalErrorMessage":[32],"announcement":[32],"numFilesInProgress":[32],"isCondensed":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"wmUploadProgress","handleUploadProgress"],[0,"wmFileClearErrorClicked","handleFileErrorCleared"],[0,"wmIntFileDeleted","handleFileDeleted"],[0,"wmIntFilePreviewed","handleFilePreviewed"],[0,"wmIntFileDownloaded","handleFileDownloaded"]]]]],["p-b97de06f.system",[[17,"wm-tab-list",{"customBackground":[1,"custom-background"],"customPadding":[1,"custom-padding"],"selectedTab":[1,"selected-tab"],"controllerEnabled":[4,"controller-enabled"]},[[0,"tabItemLoaded","tabItemLoaded"],[0,"wmTabSelected","handleTabSelected"],[0,"keydownOnTabItem","handleKeydown"],[9,"resize","setLayout"]]],[17,"wm-tab-item",{"selected":[4],"show":[4],"tabId":[1,"tab-id"]},[[4,"keydown","toggleTabbingOn"],[4,"click","toggleTabbingOff"]]],[0,"wm-tab-panel",{"active":[1028],"tabId":[1025,"tab-id"]},[[4,"keydown","toggleTabbingOn"],[4,"click","toggleTabbingOff"]]]]],["p-2805fed6.system",[[17,"wm-navigator",{"userName":[1,"user-name"],"email":[1],"authType":[2,"auth-type"],"connectionName":[1,"connection-name"],"logoutUrl":[1,"logout-url"],"products":[1],"loadFromUserinfo":[4,"load-from-userinfo"],"isOpen":[32],"isTabbing":[32],"itemIndexToFocus":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"keydown","handleKeys"],[0,"keydownOnNavItem","handleKeydown"],[4,"click","handleClick"],[0,"buttonActivated","handleButtonClick"]]]]],["p-725c14b0.system",[[1,"wm-network-uploader",{"getPath":[1,"get-path"],"requestUploadPath":[1,"request-upload-path"],"uploadPath":[1,"upload-path"],"requestDownloadPath":[1,"request-download-path"],"deletePath":[1,"delete-path"],"associatedData":[1,"associated-data"],"buttonText":[1,"button-text"],"emptyStateText":[1,"empty-state-text"],"icon":[1],"fileTypes":[1,"file-types"],"maxSize":[1026,"max-size"],"maxFiles":[2,"max-files"],"sortBy":[1,"sort-by"],"isTabbing":[32],"fileList":[32],"inProgressList":[32],"errorList":[32],"notif":[32],"snackbar":[32],"numFilesInProgress":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"wmUploadProgress","handleUploadProgress"],[0,"userFinishedSnack","handleFinishedSnack"]]]]],["p-122da0d1.system",[[17,"wm-navigation",{"open":[1540],"isTabbing":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"keydown","closeOnEscape"],[9,"resize","handleWindowResize"],[8,"wmNavigationHamburgerClicked","handleHamburgerClicked"],[0,"wmNavigationItemClicked","handleClickOnItem"]]],[17,"wm-navigation-hamburger",{"navId":[1,"nav-id"],"isTabbing":[32],"open":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[4,"wmNavigationStateChanged","handleNavigationStateChanged"]]],[17,"wm-navigation-item",{"href":[1],"text":[1],"active":[4],"isTabbing":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"]]]]],["p-67c0ad56.system",[[17,"wm-progress-indicator",{"label":[1],"subinfo":[1],"completionMessage":[1,"completion-message"],"showLegend":[4,"show-legend"],"isTabbing":[32],"mode":[32],"userIsNavigating":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"keydown","handleKeydown"],[0,"wmProgressSliceUpdated","handleSliceUpdate"]]],[17,"wm-progress-monitor",{"breakpoint":[8],"groupLegend":[1,"group-legend"],"barLabelsWidth":[1,"bar-labels-width"]}],[1,"wm-progress-slice",{"legend":[1],"amount":[1],"popoverTitle":[1,"popover-title"],"popoverText":[1,"popover-text"],"popoverButtonText":[1,"popover-button-text"]}]]],["p-4809e419.system",[[17,"wm-chart",{"chartType":[1,"chart-type"],"label":[1],"labelWidth":[1,"label-width"],"subinfo":[1],"completionMessage":[1,"completion-message"],"valueFormat":[1,"value-format"],"showValues":[1,"show-values"],"showGrid":[4,"show-grid"],"showLegend":[4,"show-legend"],"showBarLegend":[4,"show-bar-legend"],"notStartedColor":[4,"not-started-color"],"labelPosition":[1,"label-position"],"isTabbing":[32],"userIsNavigating":[32],"hasHiddenBarValue":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"keydown","handleKeydown"],[0,"wmChartSliceUpdated","handleSliceUpdate"]]]]],["p-d9b66dca.system",[[17,"wm-datepicker",{"value":[1025],"disabled":[4],"dateFormat":[1025,"date-format"],"errorMessage":[513,"error-message"],"labelPosition":[1025,"label-position"],"label":[1025],"requiredField":[4,"required-field"],"requiredFieldMessage":[1,"required-field-message"],"preventValidation":[1,"prevent-validation"],"displayError":[32]},[[0,"keydown","handleTabbingOn"],[0,"click","handleTabbingOff"],[0,"popupBlurred","handlePopupBlurred"],[0,"cellTriggered","handleCellTriggered"]]]]],["p-4b48ae88.system",[[0,"wm-modal-footer",{"secondaryText":[1,"secondary-text"],"primaryText":[1,"primary-text"],"infoText":[1,"info-text"],"primaryActionDisabled":[4,"primary-action-disabled"],"deleteStyle":[4,"delete-style"]}]]],["p-f69276d5.system",[[0,"wm-modal-header",{"heading":[1],"subheading":[1]}]]],["p-894bc6c4.system",[[17,"wm-search",{"searchType":[1025,"search-type"],"disabled":[516],"placeholder":[1],"label":[1],"numResults":[1026,"num-results"],"value":[1537],"highlightedId":[1,"highlighted-id"],"highlightedName":[1,"highlighted-name"],"isTabbing":[32],"highlightedNum":[32],"previousBlurredValue":[32],"parentModal":[32],"announcement":[32],"updateValue":[64]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"]]]]],["p-63d9956d.system",[[0,"wm-chart-slice",{"legend":[1],"amount":[1],"popoverTitle":[1,"popover-title"],"popoverText":[1,"popover-text"],"popoverButtonText":[1,"popover-button-text"]}]]],["p-11d98b00.system",[[17,"wm-input",{"label":[1],"labelPosition":[1,"label-position"],"value":[1537],"disabled":[516],"info":[1],"inputWidth":[1,"input-width"],"placeholder":[1],"requiredField":[4,"required-field"],"requiredFieldMessage":[1,"required-field-message"],"errorMessage":[1,"error-message"],"characterLimit":[2,"character-limit"],"symbolBefore":[1,"symbol-before"],"symbolAfter":[1,"symbol-after"],"textAfter":[1,"text-after"],"preventValidation":[1,"prevent-validation"],"type":[1],"step":[2],"min":[2],"max":[2],"announcement":[32],"displayedErrorMessage":[32]}]]],["p-4753fbfc.system",[[0,"wm-modal",{"open":[1540],"isOpen":[1540,"is-open"],"elementToFocus":[1025,"element-to-focus"],"modalType":[513,"modal-type"],"isTypeDialog":[516,"is-type-dialog"],"uid":[1537],"emitCloseEvent":[64],"emitPrimaryEvent":[64],"emitSecondaryEvent":[64]},[[0,"click","handleClick"],[0,"keydown","closeModalOnEscape"]]]]],["p-f3e42327.system",[[17,"wm-pagination",{"currentPage":[2,"current-page"],"totalItems":[2,"total-items"],"itemsPerPage":[2,"items-per-page"],"value":[2],"isLargeViewport":[4,"is-large-viewport"],"isTabbing":[32],"srAnnouncement":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[9,"resize","handleResize"]]]]],["p-b378e064.system",[[17,"wm-tag-input",{"label":[1],"labelPosition":[1,"label-position"],"options":[1025],"selectedTags":[1537,"selected-tags"],"info":[1],"errorMessage":[1,"error-message"],"addNew":[4,"add-new"],"placeholder":[1025],"requiredField":[4,"required-field"],"characterLimit":[2,"character-limit"],"maxTags":[2,"max-tags"],"tagInputType":[1,"tag-input-type"],"colHeaders":[1,"col-headers"],"colWidths":[1,"col-widths"],"colWrap":[1,"col-wrap"],"messageConfig":[1,"message-config"],"focusedListItem":[32],"focusedTag":[32],"tablePosition":[32],"isExpanded":[32],"tagsList":[32],"optionsList":[32],"charCount":[32],"liveRegionMessage":[32]},[[0,"wmTagInputRowUpdated","handleRowUpdate"],[4,"click","closeIfNotElOrChild"],[11,"scroll","dismissTooltip"]]]]],["p-0f98235a.system",[[0,"wm-tag-input-row",{"col1":[1],"col2":[1],"col3":[1],"col4":[1],"locked":[4]}]]],["p-c9a1834d.system",[[17,"wm-timepicker",{"disabled":[4],"value":[1537],"errorMessage":[1,"error-message"],"label":[1],"labelPosition":[1,"label-position"],"requiredField":[4,"required-field"],"requiredFieldMessage":[1,"required-field-message"],"preventValidation":[1,"prevent-validation"],"selectedOption":[32],"isExpanded":[32],"isTabbing":[32],"displayedErrorMessage":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"keydown","handleKey"]]]]],["p-88d17f6b.system",[[17,"wm-toggletip",{"label":[1],"tooltip":[1025],"tooltipText":[1,"tooltip-text"],"tooltipPosition":[1537,"tooltip-position"],"isOpen":[32],"isTabbing":[32]},[[0,"keydown","handleKeydown"],[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[4,"click","handleClick"]]]]],["p-57fbc01e.system",[[0,"wm-wrapper"]]],["p-2c8fd902.system",[[0,"priv-datepicker",{"disabled":[4],"isExpanded":[1540,"is-expanded"],"view":[1537],"date":[1040],"selectedYear":[1026,"selected-year"],"selectedMonth":[1026,"selected-month"],"selectedDay":[1026,"selected-day"],"monthInFocus":[1026,"month-in-focus"],"yearInFocus":[1026,"year-in-focus"],"dayInFocus":[1026,"day-in-focus"],"parentId":[1537,"parent-id"],"monthNumInFocus":[32],"isTabbing":[32]},[[0,"keydown","handleKey"],[0,"keydown","toggleTabbingOn"],[9,"mousedown","toggleTabbingOff"],[4,"click","blurHandler"],[8,"blur","handleBlurOnWindow"]]]]],["p-4438d44f.system",[[17,"priv-navigator-button",{"expanded":[1028],"altText":[1,"alt-text"],"isTabbing":[1028,"is-tabbing"]}]]],["p-c73f604f.system",[[1,"priv-navigator-item",{"selected":[1028],"focused":[1028],"link":[1025]},[[0,"keydown","handleKeyDown"]]]]],["p-f13b239c.system",[[1,"wm-snackbar",{"notifications":[1537],"isTabbing":[32],"announcement":[32]},[[4,"keydown","checkForTabbing"],[5,"mouseover","handleMouse"]]]]],["p-f8d45250.system",[[0,"priv-chart-popover",{"sliceRef":[16],"popoverTitle":[1,"popover-title"],"popoverText":[1,"popover-text"],"buttonText":[1,"button-text"],"open":[1028],"coords":[16]},[[4,"click","handleClickOnDocument"],[0,"click","handleClick"]]]]],["p-252ba295.system",[[17,"wm-select",{"disabled":[516],"invalid":[1028],"maxHeight":[1,"max-height"],"label":[1025],"labelPosition":[1,"label-position"],"requiredField":[4,"required-field"],"errorMessage":[1025,"error-message"],"multiple":[4],"search":[4],"selectAll":[4,"select-all"],"placeholder":[1],"searchPlaceholder":[1,"search-placeholder"],"allSelectedMessage":[1,"all-selected-message"],"isTabbing":[32],"isExpanded":[32],"announcement":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"wmOptionSelected","handleOptionSelection"],[0,"wmEnterKeyPressed","handleChildEnter"],[0,"wmKeyUpPressed","handleChildUp"],[0,"wmKeyDownPressed","handleChildDown"],[0,"wmHomeKeyPressed","moveToFirstOption"],[0,"wmEndKeyPressed","moveToLastOption"],[0,"wmEscKeyPressed","closePopupOnEscape"],[0,"wmOptionBlurred","handleOptionBlur"],[6,"click","handleClick"],[0,"keydown","handleKey"],[0,"wmLetterPressed","findAndFocusOption"]]],[1,"wm-option",{"value":[1],"subinfo":[1025],"disabled":[516],"selected":[516],"focused":[4],"searchTerm":[32]},[[0,"keydown","handleKeydown"],[0,"click","handleSelection"],[0,"blur","handleBlur"]]]]],["p-73d277ba.system",[[17,"wm-button",{"disabled":[516],"buttonType":[1025,"button-type"],"buttonStyle":[1025,"button-style"],"icon":[1537],"iconSize":[1,"icon-size"],"iconRotate":[2,"icon-rotate"],"iconFlip":[1,"icon-flip"],"tooltip":[1537],"labelForIdenticalButtons":[1,"label-for-identical-buttons"],"tooltipPosition":[1,"tooltip-position"],"permanentlyDelete":[4,"permanently-delete"],"textWrap":[4,"text-wrap"],"customBackground":[1,"custom-background"],"isTabbing":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[11,"scroll","handleScroll"],[0,"keydown","handleKeydown"]]]]],["p-7eca18bd.system",[[17,"wm-action-menu",{"tooltipPosition":[1,"tooltip-position"],"actionMenuType":[1,"action-menu-type"],"buttonType":[1,"button-type"],"buttonText":[1,"button-text"],"disabled":[516],"tooltip":[1],"labelForIdenticalButtons":[1,"label-for-identical-buttons"],"darkMode":[4,"dark-mode"],"isExpanded":[32]},[[0,"wmMenuitemClicked","handleClickedItem"],[0,"wmKeyUpPressed","handleKeyUp"],[0,"wmKeyDownPressed","handleKeyDown"],[0,"wmHomeKeyPressed","handleHomeKey"],[0,"wmEndKeyPressed","handleEndKey"],[0,"wmTabKeyPressed","handleTabKey"],[0,"wmEscKeyPressed","handleEscKey"],[0,"keydown","handleKey"],[0,"wmMenuitemBlurred","handleMenuitemBlur"],[0,"wmLetterPressed","findAndFocusItem"]]],[1,"wm-menuitem",{"disabled":[4],"focused":[4],"icon":[1025],"description":[1],"isKeying":[32]},[[8,"wmUserIsKeying","toggleKeyingOn"],[8,"wmUserIsTabbing","toggleKeyingOn"],[8,"wmUserIsNotKeying","toggleKeyingOff"],[8,"wmUserIsNotTabbing","toggleKeyingOff"],[0,"keydown","handleKeydown"],[0,"click","handleClick"],[0,"blur","handleBlur"]]]]],["p-82a97531.system",[[17,"wm-file",{"file":[1],"showInfo":[1,"show-info"],"errorMessage":[1,"error-message"],"isCondensed":[32]}]]],["p-e434a4b5.system",[[17,"wm-file-list",{"files":[1],"showInfo":[1,"show-info"]},[[0,"wmIntFileDownloaded","handleFileDownloaded"],[0,"wmIntFilePreviewed","handleFilePreviewed"],[0,"wmIntFileDeleted","handleFileDeleted"]]]]]]'),e)}))}}}));
|
|
1
|
+
System.register(["./p-c4ca5d46.system.js","./p-32944b70.system.js"],(function(e,t){"use strict";var a,i;return{setters:[function(t){a=t.p;i=t.b;e("setNonce",t.s)},function(){}],execute:function(){var e=function(){var e=t.meta.url;var i={};if(e!==""){i.resourcesUrl=new URL(".",e).href}return a(i)};e().then((function(e){return i(JSON.parse('[["p-15779c22.system",[[17,"wm-uploader",{"uploaderType":[1025,"uploader-type"],"type":[1],"label":[1],"buttonText":[1,"button-text"],"info":[1],"emptyStateText":[1,"empty-state-text"],"icon":[1],"fileTypes":[1,"file-types"],"maxSize":[2,"max-size"],"maxFiles":[2,"max-files"],"sortBy":[1,"sort-by"],"showInfo":[1,"show-info"],"errorMessage":[1,"error-message"],"requiredField":[4,"required-field"],"files":[1],"filesToUpload":[1040],"rejectedFiles":[1,"rejected-files"],"fileList":[32],"isTabbing":[32],"errorList":[32],"notif":[32],"internalErrorMessage":[32],"announcement":[32],"numFilesInProgress":[32],"isCondensed":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"wmUploadProgress","handleUploadProgress"],[0,"wmFileClearErrorClicked","handleFileErrorCleared"],[0,"wmIntFileDeleted","handleFileDeleted"],[0,"wmIntFilePreviewed","handleFilePreviewed"],[0,"wmIntFileDownloaded","handleFileDownloaded"]]]]],["p-0450cdbe.system",[[17,"wm-tab-list",{"customBackground":[1,"custom-background"],"customPadding":[1,"custom-padding"],"selectedTab":[1,"selected-tab"],"controllerEnabled":[4,"controller-enabled"]},[[0,"tabItemLoaded","tabItemLoaded"],[0,"wmTabSelected","handleTabSelected"],[0,"keydownOnTabItem","handleKeydown"],[9,"resize","setLayout"]]],[17,"wm-tab-item",{"selected":[4],"show":[4],"tabId":[1,"tab-id"]},[[4,"keydown","toggleTabbingOn"],[4,"click","toggleTabbingOff"]]],[0,"wm-tab-panel",{"active":[1028],"tabId":[1025,"tab-id"]},[[4,"keydown","toggleTabbingOn"],[4,"click","toggleTabbingOff"]]]]],["p-bced37cf.system",[[17,"wm-navigator",{"userName":[1,"user-name"],"email":[1],"authType":[2,"auth-type"],"connectionName":[1,"connection-name"],"logoutUrl":[1,"logout-url"],"products":[1],"loadFromUserinfo":[4,"load-from-userinfo"],"isOpen":[32],"isTabbing":[32],"itemIndexToFocus":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"keydown","handleKeys"],[0,"keydownOnNavItem","handleKeydown"],[4,"click","handleClick"],[0,"buttonActivated","handleButtonClick"]]]]],["p-00022d17.system",[[1,"wm-network-uploader",{"getPath":[1,"get-path"],"requestUploadPath":[1,"request-upload-path"],"uploadPath":[1,"upload-path"],"requestDownloadPath":[1,"request-download-path"],"deletePath":[1,"delete-path"],"associatedData":[1,"associated-data"],"buttonText":[1,"button-text"],"emptyStateText":[1,"empty-state-text"],"icon":[1],"fileTypes":[1,"file-types"],"maxSize":[1026,"max-size"],"maxFiles":[2,"max-files"],"sortBy":[1,"sort-by"],"isTabbing":[32],"fileList":[32],"inProgressList":[32],"errorList":[32],"notif":[32],"snackbar":[32],"numFilesInProgress":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"wmUploadProgress","handleUploadProgress"],[0,"userFinishedSnack","handleFinishedSnack"]]]]],["p-197c83de.system",[[17,"wm-navigation",{"open":[1540],"isTabbing":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"keydown","closeOnEscape"],[9,"resize","handleWindowResize"],[8,"wmNavigationHamburgerClicked","handleHamburgerClicked"],[0,"wmNavigationItemClicked","handleClickOnItem"]]],[17,"wm-navigation-hamburger",{"navId":[1,"nav-id"],"isTabbing":[32],"open":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[4,"wmNavigationStateChanged","handleNavigationStateChanged"]]],[17,"wm-navigation-item",{"href":[1],"text":[1],"active":[4],"isTabbing":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"]]]]],["p-9d6a574b.system",[[17,"wm-progress-indicator",{"label":[1],"subinfo":[1],"completionMessage":[1,"completion-message"],"showLegend":[4,"show-legend"],"isTabbing":[32],"mode":[32],"userIsNavigating":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"keydown","handleKeydown"],[0,"wmProgressSliceUpdated","handleSliceUpdate"]]],[17,"wm-progress-monitor",{"breakpoint":[8],"groupLegend":[1,"group-legend"],"barLabelsWidth":[1,"bar-labels-width"]}],[1,"wm-progress-slice",{"legend":[1],"amount":[1],"popoverTitle":[1,"popover-title"],"popoverText":[1,"popover-text"],"popoverButtonText":[1,"popover-button-text"]}]]],["p-b6f558f7.system",[[17,"wm-chart",{"chartType":[1,"chart-type"],"label":[1],"labelWidth":[1,"label-width"],"subinfo":[1],"completionMessage":[1,"completion-message"],"valueFormat":[1,"value-format"],"showValues":[1,"show-values"],"showGrid":[4,"show-grid"],"showLegend":[4,"show-legend"],"showBarLegend":[4,"show-bar-legend"],"notStartedColor":[4,"not-started-color"],"labelPosition":[1,"label-position"],"isTabbing":[32],"userIsNavigating":[32],"hasHiddenBarValue":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"keydown","handleKeydown"],[0,"wmChartSliceUpdated","handleSliceUpdate"]]]]],["p-aabe172c.system",[[17,"wm-datepicker",{"value":[1025],"disabled":[4],"dateFormat":[1025,"date-format"],"errorMessage":[513,"error-message"],"labelPosition":[1025,"label-position"],"label":[1025],"requiredField":[4,"required-field"],"requiredFieldMessage":[1,"required-field-message"],"preventValidation":[1,"prevent-validation"],"displayError":[32]},[[0,"keydown","handleTabbingOn"],[0,"click","handleTabbingOff"],[0,"popupBlurred","handlePopupBlurred"],[0,"cellTriggered","handleCellTriggered"]]]]],["p-4b48ae88.system",[[0,"wm-modal-footer",{"secondaryText":[1,"secondary-text"],"primaryText":[1,"primary-text"],"infoText":[1,"info-text"],"primaryActionDisabled":[4,"primary-action-disabled"],"deleteStyle":[4,"delete-style"]}]]],["p-31c18f5e.system",[[0,"wm-modal-header",{"heading":[1],"subheading":[1]}]]],["p-cd3e0b8b.system",[[17,"wm-search",{"searchType":[1025,"search-type"],"disabled":[516],"placeholder":[1],"label":[1],"numResults":[1026,"num-results"],"value":[1537],"highlightedId":[1,"highlighted-id"],"highlightedName":[1,"highlighted-name"],"isTabbing":[32],"highlightedNum":[32],"previousBlurredValue":[32],"parentModal":[32],"announcement":[32],"updateValue":[64]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"]]]]],["p-63d9956d.system",[[0,"wm-chart-slice",{"legend":[1],"amount":[1],"popoverTitle":[1,"popover-title"],"popoverText":[1,"popover-text"],"popoverButtonText":[1,"popover-button-text"]}]]],["p-1bad4efe.system",[[17,"wm-input",{"label":[1],"labelPosition":[1,"label-position"],"value":[1537],"disabled":[516],"info":[1],"inputWidth":[1,"input-width"],"placeholder":[1],"requiredField":[4,"required-field"],"requiredFieldMessage":[1,"required-field-message"],"errorMessage":[1,"error-message"],"characterLimit":[2,"character-limit"],"symbolBefore":[1,"symbol-before"],"symbolAfter":[1,"symbol-after"],"textAfter":[1,"text-after"],"preventValidation":[1,"prevent-validation"],"type":[1],"step":[2],"min":[2],"max":[2],"announcement":[32],"displayedErrorMessage":[32]}]]],["p-947f01e2.system",[[0,"wm-modal",{"open":[1540],"isOpen":[1540,"is-open"],"elementToFocus":[1025,"element-to-focus"],"modalType":[513,"modal-type"],"isTypeDialog":[516,"is-type-dialog"],"uid":[1537],"emitCloseEvent":[64],"emitPrimaryEvent":[64],"emitSecondaryEvent":[64]},[[0,"click","handleClick"],[0,"keydown","closeModalOnEscape"]]]]],["p-89db9c27.system",[[17,"wm-pagination",{"currentPage":[2,"current-page"],"totalItems":[2,"total-items"],"itemsPerPage":[2,"items-per-page"],"value":[2],"isLargeViewport":[4,"is-large-viewport"],"isTabbing":[32],"srAnnouncement":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[9,"resize","handleResize"]]]]],["p-0b6a7b77.system",[[17,"wm-tag-input",{"label":[1],"labelPosition":[1,"label-position"],"options":[1025],"selectedTags":[1537,"selected-tags"],"info":[1],"errorMessage":[1,"error-message"],"addNew":[4,"add-new"],"placeholder":[1025],"requiredField":[4,"required-field"],"characterLimit":[2,"character-limit"],"maxTags":[2,"max-tags"],"tagInputType":[1,"tag-input-type"],"colHeaders":[1,"col-headers"],"colWidths":[1,"col-widths"],"colWrap":[1,"col-wrap"],"messageConfig":[1,"message-config"],"focusedListItem":[32],"focusedTag":[32],"tablePosition":[32],"isExpanded":[32],"tagsList":[32],"optionsList":[32],"charCount":[32],"liveRegionMessage":[32]},[[0,"wmTagInputRowUpdated","handleRowUpdate"],[4,"click","closeIfNotElOrChild"],[11,"scroll","dismissTooltip"]]]]],["p-0f98235a.system",[[0,"wm-tag-input-row",{"col1":[1],"col2":[1],"col3":[1],"col4":[1],"locked":[4]}]]],["p-bd0c1e7c.system",[[17,"wm-timepicker",{"disabled":[4],"value":[1537],"errorMessage":[1,"error-message"],"label":[1],"labelPosition":[1,"label-position"],"requiredField":[4,"required-field"],"requiredFieldMessage":[1,"required-field-message"],"preventValidation":[1,"prevent-validation"],"selectedOption":[32],"isExpanded":[32],"isTabbing":[32],"displayedErrorMessage":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"keydown","handleKey"]]]]],["p-3aa48fad.system",[[17,"wm-toggletip",{"label":[1],"tooltip":[1025],"tooltipText":[1,"tooltip-text"],"tooltipPosition":[1537,"tooltip-position"],"isOpen":[32],"isTabbing":[32]},[[0,"keydown","handleKeydown"],[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[4,"click","handleClick"]]]]],["p-57fbc01e.system",[[0,"wm-wrapper"]]],["p-97d5b4bd.system",[[0,"priv-datepicker",{"disabled":[4],"isExpanded":[1540,"is-expanded"],"view":[1537],"date":[1040],"selectedYear":[1026,"selected-year"],"selectedMonth":[1026,"selected-month"],"selectedDay":[1026,"selected-day"],"monthInFocus":[1026,"month-in-focus"],"yearInFocus":[1026,"year-in-focus"],"dayInFocus":[1026,"day-in-focus"],"parentId":[1537,"parent-id"],"monthNumInFocus":[32],"isTabbing":[32]},[[0,"keydown","handleKey"],[0,"keydown","toggleTabbingOn"],[9,"mousedown","toggleTabbingOff"],[4,"click","blurHandler"],[8,"blur","handleBlurOnWindow"]]]]],["p-4438d44f.system",[[17,"priv-navigator-button",{"expanded":[1028],"altText":[1,"alt-text"],"isTabbing":[1028,"is-tabbing"]}]]],["p-c73f604f.system",[[1,"priv-navigator-item",{"selected":[1028],"focused":[1028],"link":[1025]},[[0,"keydown","handleKeyDown"]]]]],["p-da525ed1.system",[[1,"wm-snackbar",{"notifications":[1537],"isTabbing":[32],"announcement":[32]},[[4,"keydown","checkForTabbing"],[5,"mouseover","handleMouse"]]]]],["p-54086f7b.system",[[0,"priv-chart-popover",{"sliceRef":[16],"popoverTitle":[1,"popover-title"],"popoverText":[1,"popover-text"],"buttonText":[1,"button-text"],"open":[1028],"coords":[16]},[[4,"click","handleClickOnDocument"],[0,"click","handleClick"]]]]],["p-2ff923ee.system",[[17,"wm-select",{"disabled":[516],"invalid":[1028],"maxHeight":[1,"max-height"],"label":[1025],"labelPosition":[1,"label-position"],"requiredField":[4,"required-field"],"errorMessage":[1025,"error-message"],"multiple":[4],"search":[4],"selectAll":[4,"select-all"],"placeholder":[1],"searchPlaceholder":[1,"search-placeholder"],"allSelectedMessage":[1,"all-selected-message"],"isTabbing":[32],"isExpanded":[32],"announcement":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[0,"wmOptionSelected","handleOptionSelection"],[0,"wmEnterKeyPressed","handleChildEnter"],[0,"wmKeyUpPressed","handleChildUp"],[0,"wmKeyDownPressed","handleChildDown"],[0,"wmHomeKeyPressed","moveToFirstOption"],[0,"wmEndKeyPressed","moveToLastOption"],[0,"wmEscKeyPressed","closePopupOnEscape"],[0,"wmOptionBlurred","handleOptionBlur"],[6,"click","handleClick"],[0,"keydown","handleKey"],[0,"wmLetterPressed","findAndFocusOption"]]],[1,"wm-option",{"value":[1],"subinfo":[1025],"disabled":[516],"selected":[516],"focused":[4],"searchTerm":[32]},[[0,"keydown","handleKeydown"],[0,"click","handleSelection"],[0,"blur","handleBlur"]]]]],["p-36effc40.system",[[17,"wm-button",{"disabled":[516],"buttonType":[1025,"button-type"],"buttonStyle":[1025,"button-style"],"icon":[1537],"iconSize":[1,"icon-size"],"iconRotate":[2,"icon-rotate"],"iconFlip":[1,"icon-flip"],"tooltip":[1537],"labelForIdenticalButtons":[1,"label-for-identical-buttons"],"tooltipPosition":[1,"tooltip-position"],"permanentlyDelete":[4,"permanently-delete"],"textWrap":[4,"text-wrap"],"customBackground":[1,"custom-background"],"isTabbing":[32]},[[8,"wmUserIsTabbing","toggleTabbingOn"],[8,"wmUserIsNotTabbing","toggleTabbingOff"],[11,"scroll","handleScroll"],[0,"keydown","handleKeydown"]]]]],["p-c27eda00.system",[[17,"wm-action-menu",{"tooltipPosition":[1,"tooltip-position"],"actionMenuType":[1,"action-menu-type"],"buttonType":[1,"button-type"],"buttonText":[1,"button-text"],"disabled":[516],"tooltip":[1],"labelForIdenticalButtons":[1,"label-for-identical-buttons"],"darkMode":[4,"dark-mode"],"isExpanded":[32]},[[0,"wmMenuitemClicked","handleClickedItem"],[0,"wmKeyUpPressed","handleKeyUp"],[0,"wmKeyDownPressed","handleKeyDown"],[0,"wmHomeKeyPressed","handleHomeKey"],[0,"wmEndKeyPressed","handleEndKey"],[0,"wmTabKeyPressed","handleTabKey"],[0,"wmEscKeyPressed","handleEscKey"],[0,"keydown","handleKey"],[0,"wmMenuitemBlurred","handleMenuitemBlur"],[0,"wmLetterPressed","findAndFocusItem"]]],[1,"wm-menuitem",{"disabled":[4],"focused":[4],"icon":[1025],"description":[1],"isKeying":[32]},[[8,"wmUserIsKeying","toggleKeyingOn"],[8,"wmUserIsTabbing","toggleKeyingOn"],[8,"wmUserIsNotKeying","toggleKeyingOff"],[8,"wmUserIsNotTabbing","toggleKeyingOff"],[0,"keydown","handleKeydown"],[0,"click","handleClick"],[0,"blur","handleBlur"]]]]],["p-419f133c.system",[[17,"wm-file",{"file":[1],"showInfo":[1,"show-info"],"errorMessage":[1,"error-message"],"isCondensed":[32]}]]],["p-e434a4b5.system",[[17,"wm-file-list",{"files":[1],"showInfo":[1,"show-info"]},[[0,"wmIntFileDownloaded","handleFileDownloaded"],[0,"wmIntFilePreviewed","handleFilePreviewed"],[0,"wmIntFileDeleted","handleFileDeleted"]]]]]]'),e)}))}}}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var __spreadArray=this&&this.__spreadArray||function(e,t,a){if(a||arguments.length===2)for(var n=0,r=t.length,i;n<r;n++){if(i||!(n in t)){if(!i)i=Array.prototype.slice.call(t,0,n);i[n]=t[n]}}return e.concat(i||Array.prototype.slice.call(t))};System.register(["./p-c4ca5d46.system.js","./p-9eb5a71e.system.js"],(function(e){"use strict";var t,a,n,r,i;return{setters:[function(e){t=e.r;a=e.c;n=e.h;r=e.g},function(e){i=e.d}],execute:function(){var s='nav .largescreen,nav .smallscreen{margin-bottom:0.625rem;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:flex-end;-ms-flex-pack:flex-end;-webkit-justify-content:flex-end;justify-content:flex-end;font-size:0.875rem}nav .largescreen .pageview,nav .smallscreen .pageview{font-size:0.875rem;margin:0 0.625rem}nav .largescreen .paginationbtn,nav .smallscreen .paginationbtn{position:relative;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;-ms-transition:none;-webkit-transition:none;-moz-transition:none;transition:none;border:none;color:#575195;background-color:transparent;margin:0;padding:0;height:2.5rem;width:2.5rem;font-family:inherit;letter-spacing:0.3px;font-size:0.875rem;font-weight:500;cursor:pointer;text-transform:none}nav .largescreen .paginationbtn svg *,nav .smallscreen .paginationbtn svg *{fill:#565397}nav .largescreen .paginationbtn:hover:not([aria-current=page]):not([disabled]),nav .smallscreen .paginationbtn:hover:not([aria-current=page]):not([disabled]){text-decoration:underline}nav .largescreen .paginationbtn:focus,nav .smallscreen .paginationbtn:focus{outline:none}nav .largescreen .paginationbtn::-moz-focus-inner,nav .smallscreen .paginationbtn::-moz-focus-inner{border:0;outline:none}nav .largescreen .paginationbtn[disabled],nav .smallscreen .paginationbtn[disabled]{color:#9f9f9f;pointer-events:none}nav .largescreen .paginationbtn[disabled] svg *,nav .smallscreen .paginationbtn[disabled] svg *{fill:#9f9f9f}nav .largescreen .previousbtn,nav .smallscreen .previousbtn{margin-right:0.625rem;width:auto !important}nav .largescreen .nextbtn,nav .smallscreen .nextbtn{margin-left:0.625rem;margin-right:0;width:auto !important}nav .largescreen .previousbtn,nav .largescreen .nextbtn,nav .smallscreen .previousbtn,nav .smallscreen .nextbtn{-ms-transition:none;-webkit-transition:none;-moz-transition:none;transition:none}nav .largescreen .ellipsis,nav .smallscreen .ellipsis{display:inline-block;width:2.5rem;text-align:center}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]),nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]):before,nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]):before{position:absolute;content:"";height:auto;width:16px;top:0;bottom:0;left:12px;right:0;background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 2px;background-position:0 2em;border-radius:0;line-height:normal}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).previousbtn:focus:before,nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).previousbtn:focus:before{left:0 !important}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).nextbtn:focus:before,nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).nextbtn:focus:before{left:0 !important}nav .largescreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus,nav .smallscreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}nav .largescreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus::-moz-focus-inner,nav .smallscreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus::-moz-focus-inner{border:0}nav .largescreen .user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).previousbtn:focus:before{width:56px !important}nav .largescreen .user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).nextbtn:focus:before{width:32px !important}nav .largescreen .paginationbtn[aria-current=page]{-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;-webkit-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);background-color:#575195;color:#fff}nav .largescreen .paginationbtn[aria-current=page]:hover{-webkit-box-shadow:0 4px 2px 0 rgba(87, 81, 149, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 4px 2px 0 rgba(87, 81, 149, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 4px 2px 0 rgba(87, 81, 149, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.2);background:#4e4986}.sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}';var o=e("wm_pagination",function(){function e(e){var n=this;t(this,e);this.wmPaginationPageClicked=a(this,"wmPaginationPageClicked",7);this.pageClicked=a(this,"pageClicked",7);this.focusCurrentPage=a(this,"focusCurrentPage",7);this.totalPages=0;this.debouncedResize=i((function(){n.isLargeViewport=window.innerWidth>600}),250);this.getMiddlePageNums=function(){var e;if(n.currentPage<4){e=[2,3,4]}else if(n.currentPage>n.totalPages-3){e=[n.totalPages-3,n.totalPages-2,n.totalPages-1]}else{e=[n.currentPage-1,n.currentPage,n.currentPage+1]}return e};this.currentPage=1;this.totalItems=undefined;this.itemsPerPage=undefined;this.value=1;this.isLargeViewport=window.innerWidth>600;this.isTabbing=false;this.srAnnouncement=""}e.prototype.toggleTabbingOn=function(){this.isTabbing=true};e.prototype.toggleTabbingOff=function(){this.isTabbing=false};e.prototype.maintainFocusOnNumberChange=function(e){var t=this;window.requestAnimationFrame((function(){switch(e){case"previous":t.currentPage===1&&t.el.shadowRoot.querySelector("button#wm-1").focus();break;case"next":t.currentPage===t.totalPages&&t.el.shadowRoot.querySelector("button#wm-".concat(t.totalPages)).focus();break;case"prev-arrow":t.currentPage===1&&t.el.shadowRoot.querySelector("#next-arw").focus();break;case"next-arrow":t.currentPage===t.totalPages&&t.el.shadowRoot.querySelector("#previous-arw").focus();break;case"page":t.el.shadowRoot.querySelector("button#wm-".concat(t.currentPage)).focus();default:return}}))};e.prototype.handleResize=function(){this.debouncedResize()};e.prototype.calculateTotalPages=function(){this.totalPages=Math.ceil(this.totalItems/this.itemsPerPage)};e.prototype.componentWillLoad=function(){var e=this;if(!this.totalItems||!this.itemsPerPage||!this.currentPage){throw new Error("Please check the required attributes")}this.calculateTotalPages();if(document.body.classList.contains("wmcl-user-is-tabbing")){this.toggleTabbingOn()}this.el.focus=function(){if(e.isLargeViewport){e.el.shadowRoot.getElementById("wm-".concat(e.currentPage)).focus()}else{e.currentPage===1?e.el.shadowRoot.getElementById("next-arw").focus():e.el.shadowRoot.getElementById("wm-1-arw").focus()}}};e.prototype.updatePageDisplayed=function(e){this.value=e;this.wmPaginationPageClicked.emit();this.pageClicked.emit();this.srAnnouncement="Current page, ".concat(this.currentPage,". ").concat(this.getCurrentPagesInView())};e.prototype.displayShortPagination=function(){var e=[];for(var t=1;t<=this.totalPages;t++){e.push(this.displayPageNumber(t))}return e};e.prototype.displayLongPagination=function(){var e=this;var t=__spreadArray(__spreadArray([this.displayPageNumber(1),this.currentPage>3&&this.displayEllipsis()],this.getMiddlePageNums().map((function(t){return e.displayPageNumber(t)})),true),[this.currentPage+2<this.totalPages&&this.displayEllipsis(),this.displayPageNumber(this.totalPages)],false);return t};e.prototype.displayPageNumber=function(e){var t=this;return n("button",{id:"wm-".concat(e),class:"paginationbtn",onClick:function(){t.currentPage=e;t.updatePageDisplayed(e);t.maintainFocusOnNumberChange("page")},value:e,"aria-label":this.currentPage!==e?"Go to page ".concat(e):"","aria-current":this.currentPage===e?"page":undefined},e)};e.prototype.displayEllipsis=function(){return n("span",{class:"ellipsis"},"...")};e.prototype.getCurrentPagesInView=function(){var e=this.itemsPerPage*this.currentPage;var t=e-this.itemsPerPage+1;if(e>this.totalItems){e=this.totalItems}return"Viewing "+(t===e?"".concat(t):"".concat(t,"–").concat(e," of ").concat(this.totalItems))};e.prototype.renderLarge=function(){var e=this;return n("div",{class:"largescreen"},n("div",{class:"pageview"},this.getCurrentPagesInView()),n("div",{class:"pagebtncontainer ".concat(this.isTabbing?"user-is-tabbing":"")},n("button",{id:"previous",class:"paginationbtn previousbtn",onClick:function(){e.currentPage=e.currentPage-1;e.updatePageDisplayed(e.currentPage);e.maintainFocusOnNumberChange("previous")},disabled:this.currentPage===1,"aria-label":"Go to previous page","aria-controls":"status"},"Previous"),this.totalPages<6?this.displayShortPagination():this.displayLongPagination(),n("button",{id:"next",class:"paginationbtn nextbtn",onClick:function(){e.currentPage=e.currentPage+1;e.updatePageDisplayed(e.currentPage);e.maintainFocusOnNumberChange("next")},disabled:this.currentPage===this.totalPages,"aria-label":"Go to next page","aria-controls":"status"},"Next")))};e.prototype.renderSmall=function(){var e=this;return n("div",{class:"smallscreen"},n("div",{class:"pagebtncontainer ".concat(this.isTabbing?"user-is-tabbing":"")},n("button",{id:"wm-1-arw",class:"paginationbtn",onClick:function(){e.currentPage=1;e.updatePageDisplayed(1);e.maintainFocusOnNumberChange("prev-arrow")},value:1,"aria-current":this.currentPage===1?"page":undefined,"aria-label":"Go to page 1","aria-controls":"status",disabled:this.currentPage===1},n("svg",{width:"16",height:"12",xmlns:"http://www.w3.org/2000/svg"},n("path",{d:"M7.41 10.59L2.83 6l4.58-4.59L6 0 0 6l6 6zM15.41 10.59L10.83 6l4.58-4.59L14 0 8 6l6 6z"}))),n("button",{id:"previous-arw",class:"paginationbtn previousbtn",onClick:function(){e.currentPage-=1;e.updatePageDisplayed(e.currentPage);e.maintainFocusOnNumberChange("prev-arrow")},disabled:this.currentPage===1,"aria-label":"Go to previous page"},n("svg",{width:"8",height:"12",xmlns:"http://www.w3.org/2000/svg"},n("path",{d:"M7.41 10.59L2.83 6l4.58-4.59L6 0 0 6l6 6z"}))),"Page ",this.currentPage," of ",this.totalPages,n("button",{id:"next-arw",class:"paginationbtn nextbtn",onClick:function(){e.currentPage+=1;e.updatePageDisplayed(e.currentPage);e.maintainFocusOnNumberChange("next-arrow")},disabled:this.currentPage===this.totalPages,"aria-label":"Go to next page"},n("svg",{width:"8",height:"12",xmlns:"http://www.w3.org/2000/svg"},n("path",{d:"M.59 10.59L5.17 6 .59 1.41 2 0l6 6-6 6z"}))),n("button",{id:"wm-".concat(this.totalPages,"-arw"),class:"paginationbtn",onClick:function(){e.currentPage=e.totalPages;e.updatePageDisplayed(e.totalPages);e.maintainFocusOnNumberChange("next-arrow")},value:this.totalPages,"aria-current":this.currentPage===this.totalPages?"page":undefined,"aria-label":"Go to last page, page ".concat(this.totalPages),"aria-controls":"status",disabled:this.currentPage===this.totalPages},n("svg",{width:"17",height:"12",xmlns:"http://www.w3.org/2000/svg"},n("path",{d:"M.59 10.59L5.17 6 .59 1.41 2 0l6 6-6 6zM9.59 10.59L14.17 6 9.59 1.41 11 0l6 6-6 6z"})))))};e.prototype.render=function(){return this.totalItems>this.itemsPerPage&&n("nav",{"aria-label":"Pagination Navigation. ".concat(this.getCurrentPagesInView(),". Current page, ").concat(this.currentPage,".")},this.isLargeViewport?this.renderLarge():this.renderSmall(),n("div",{id:"status",class:"sr-only","aria-live":"polite","aria-relevant":"text","aria-atomic":"true"},this.srAnnouncement))};Object.defineProperty(e,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"el",{get:function(){return r(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{totalItems:["calculateTotalPages"],itemsPerPage:["calculateTotalPages"]}},enumerable:false,configurable:true});return e}());o.style=s}}}));
|
|
1
|
+
var __spreadArray=this&&this.__spreadArray||function(e,t,a){if(a||arguments.length===2)for(var n=0,r=t.length,i;n<r;n++){if(i||!(n in t)){if(!i)i=Array.prototype.slice.call(t,0,n);i[n]=t[n]}}return e.concat(i||Array.prototype.slice.call(t))};System.register(["./p-c4ca5d46.system.js","./p-b267e710.system.js"],(function(e){"use strict";var t,a,n,r,i;return{setters:[function(e){t=e.r;a=e.c;n=e.h;r=e.g},function(e){i=e.d}],execute:function(){var s='nav .largescreen,nav .smallscreen{margin-bottom:0.625rem;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:flex-end;-ms-flex-pack:flex-end;-webkit-justify-content:flex-end;justify-content:flex-end;font-size:0.875rem}nav .largescreen .pageview,nav .smallscreen .pageview{font-size:0.875rem;margin:0 0.625rem}nav .largescreen .paginationbtn,nav .smallscreen .paginationbtn{position:relative;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;-ms-transition:none;-webkit-transition:none;-moz-transition:none;transition:none;border:none;color:#575195;background-color:transparent;margin:0;padding:0;height:2.5rem;width:2.5rem;font-family:inherit;letter-spacing:0.3px;font-size:0.875rem;font-weight:500;cursor:pointer;text-transform:none}nav .largescreen .paginationbtn svg *,nav .smallscreen .paginationbtn svg *{fill:#565397}nav .largescreen .paginationbtn:hover:not([aria-current=page]):not([disabled]),nav .smallscreen .paginationbtn:hover:not([aria-current=page]):not([disabled]){text-decoration:underline}nav .largescreen .paginationbtn:focus,nav .smallscreen .paginationbtn:focus{outline:none}nav .largescreen .paginationbtn::-moz-focus-inner,nav .smallscreen .paginationbtn::-moz-focus-inner{border:0;outline:none}nav .largescreen .paginationbtn[disabled],nav .smallscreen .paginationbtn[disabled]{color:#9f9f9f;pointer-events:none}nav .largescreen .paginationbtn[disabled] svg *,nav .smallscreen .paginationbtn[disabled] svg *{fill:#9f9f9f}nav .largescreen .previousbtn,nav .smallscreen .previousbtn{margin-right:0.625rem;width:auto !important}nav .largescreen .nextbtn,nav .smallscreen .nextbtn{margin-left:0.625rem;margin-right:0;width:auto !important}nav .largescreen .previousbtn,nav .largescreen .nextbtn,nav .smallscreen .previousbtn,nav .smallscreen .nextbtn{-ms-transition:none;-webkit-transition:none;-moz-transition:none;transition:none}nav .largescreen .ellipsis,nav .smallscreen .ellipsis{display:inline-block;width:2.5rem;text-align:center}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]),nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]):before,nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]):before{position:absolute;content:"";height:auto;width:16px;top:0;bottom:0;left:12px;right:0;background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 2px;background-position:0 2em;border-radius:0;line-height:normal}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).previousbtn:focus:before,nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).previousbtn:focus:before{left:0 !important}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).nextbtn:focus:before,nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).nextbtn:focus:before{left:0 !important}nav .largescreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus,nav .smallscreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}nav .largescreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus::-moz-focus-inner,nav .smallscreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus::-moz-focus-inner{border:0}nav .largescreen .user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).previousbtn:focus:before{width:56px !important}nav .largescreen .user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).nextbtn:focus:before{width:32px !important}nav .largescreen .paginationbtn[aria-current=page]{-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;-webkit-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);background-color:#575195;color:#fff}nav .largescreen .paginationbtn[aria-current=page]:hover{-webkit-box-shadow:0 4px 2px 0 rgba(87, 81, 149, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 4px 2px 0 rgba(87, 81, 149, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 4px 2px 0 rgba(87, 81, 149, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.2);background:#4e4986}.sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}';var o=e("wm_pagination",function(){function e(e){var n=this;t(this,e);this.wmPaginationPageClicked=a(this,"wmPaginationPageClicked",7);this.pageClicked=a(this,"pageClicked",7);this.focusCurrentPage=a(this,"focusCurrentPage",7);this.totalPages=0;this.debouncedResize=i((function(){n.isLargeViewport=window.innerWidth>600}),250);this.getMiddlePageNums=function(){var e;if(n.currentPage<4){e=[2,3,4]}else if(n.currentPage>n.totalPages-3){e=[n.totalPages-3,n.totalPages-2,n.totalPages-1]}else{e=[n.currentPage-1,n.currentPage,n.currentPage+1]}return e};this.currentPage=1;this.totalItems=undefined;this.itemsPerPage=undefined;this.value=1;this.isLargeViewport=window.innerWidth>600;this.isTabbing=false;this.srAnnouncement=""}e.prototype.toggleTabbingOn=function(){this.isTabbing=true};e.prototype.toggleTabbingOff=function(){this.isTabbing=false};e.prototype.maintainFocusOnNumberChange=function(e){var t=this;window.requestAnimationFrame((function(){switch(e){case"previous":t.currentPage===1&&t.el.shadowRoot.querySelector("button#wm-1").focus();break;case"next":t.currentPage===t.totalPages&&t.el.shadowRoot.querySelector("button#wm-".concat(t.totalPages)).focus();break;case"prev-arrow":t.currentPage===1&&t.el.shadowRoot.querySelector("#next-arw").focus();break;case"next-arrow":t.currentPage===t.totalPages&&t.el.shadowRoot.querySelector("#previous-arw").focus();break;case"page":t.el.shadowRoot.querySelector("button#wm-".concat(t.currentPage)).focus();default:return}}))};e.prototype.handleResize=function(){this.debouncedResize()};e.prototype.calculateTotalPages=function(){this.totalPages=Math.ceil(this.totalItems/this.itemsPerPage)};e.prototype.componentWillLoad=function(){var e=this;if(!this.totalItems||!this.itemsPerPage||!this.currentPage){throw new Error("Please check the required attributes")}this.calculateTotalPages();if(document.body.classList.contains("wmcl-user-is-tabbing")){this.toggleTabbingOn()}this.el.focus=function(){if(e.isLargeViewport){e.el.shadowRoot.getElementById("wm-".concat(e.currentPage)).focus()}else{e.currentPage===1?e.el.shadowRoot.getElementById("next-arw").focus():e.el.shadowRoot.getElementById("wm-1-arw").focus()}}};e.prototype.updatePageDisplayed=function(e){this.value=e;this.wmPaginationPageClicked.emit();this.pageClicked.emit();this.srAnnouncement="Current page, ".concat(this.currentPage,". ").concat(this.getCurrentPagesInView())};e.prototype.displayShortPagination=function(){var e=[];for(var t=1;t<=this.totalPages;t++){e.push(this.displayPageNumber(t))}return e};e.prototype.displayLongPagination=function(){var e=this;var t=__spreadArray(__spreadArray([this.displayPageNumber(1),this.currentPage>3&&this.displayEllipsis()],this.getMiddlePageNums().map((function(t){return e.displayPageNumber(t)})),true),[this.currentPage+2<this.totalPages&&this.displayEllipsis(),this.displayPageNumber(this.totalPages)],false);return t};e.prototype.displayPageNumber=function(e){var t=this;return n("button",{id:"wm-".concat(e),class:"paginationbtn",onClick:function(){t.currentPage=e;t.updatePageDisplayed(e);t.maintainFocusOnNumberChange("page")},value:e,"aria-label":this.currentPage!==e?"Go to page ".concat(e):"","aria-current":this.currentPage===e?"page":undefined},e)};e.prototype.displayEllipsis=function(){return n("span",{class:"ellipsis"},"...")};e.prototype.getCurrentPagesInView=function(){var e=this.itemsPerPage*this.currentPage;var t=e-this.itemsPerPage+1;if(e>this.totalItems){e=this.totalItems}return"Viewing "+(t===e?"".concat(t):"".concat(t,"–").concat(e," of ").concat(this.totalItems))};e.prototype.renderLarge=function(){var e=this;return n("div",{class:"largescreen"},n("div",{class:"pageview"},this.getCurrentPagesInView()),n("div",{class:"pagebtncontainer ".concat(this.isTabbing?"user-is-tabbing":"")},n("button",{id:"previous",class:"paginationbtn previousbtn",onClick:function(){e.currentPage=e.currentPage-1;e.updatePageDisplayed(e.currentPage);e.maintainFocusOnNumberChange("previous")},disabled:this.currentPage===1,"aria-label":"Go to previous page","aria-controls":"status"},"Previous"),this.totalPages<6?this.displayShortPagination():this.displayLongPagination(),n("button",{id:"next",class:"paginationbtn nextbtn",onClick:function(){e.currentPage=e.currentPage+1;e.updatePageDisplayed(e.currentPage);e.maintainFocusOnNumberChange("next")},disabled:this.currentPage===this.totalPages,"aria-label":"Go to next page","aria-controls":"status"},"Next")))};e.prototype.renderSmall=function(){var e=this;return n("div",{class:"smallscreen"},n("div",{class:"pagebtncontainer ".concat(this.isTabbing?"user-is-tabbing":"")},n("button",{id:"wm-1-arw",class:"paginationbtn",onClick:function(){e.currentPage=1;e.updatePageDisplayed(1);e.maintainFocusOnNumberChange("prev-arrow")},value:1,"aria-current":this.currentPage===1?"page":undefined,"aria-label":"Go to page 1","aria-controls":"status",disabled:this.currentPage===1},n("svg",{width:"16",height:"12",xmlns:"http://www.w3.org/2000/svg"},n("path",{d:"M7.41 10.59L2.83 6l4.58-4.59L6 0 0 6l6 6zM15.41 10.59L10.83 6l4.58-4.59L14 0 8 6l6 6z"}))),n("button",{id:"previous-arw",class:"paginationbtn previousbtn",onClick:function(){e.currentPage-=1;e.updatePageDisplayed(e.currentPage);e.maintainFocusOnNumberChange("prev-arrow")},disabled:this.currentPage===1,"aria-label":"Go to previous page"},n("svg",{width:"8",height:"12",xmlns:"http://www.w3.org/2000/svg"},n("path",{d:"M7.41 10.59L2.83 6l4.58-4.59L6 0 0 6l6 6z"}))),"Page ",this.currentPage," of ",this.totalPages,n("button",{id:"next-arw",class:"paginationbtn nextbtn",onClick:function(){e.currentPage+=1;e.updatePageDisplayed(e.currentPage);e.maintainFocusOnNumberChange("next-arrow")},disabled:this.currentPage===this.totalPages,"aria-label":"Go to next page"},n("svg",{width:"8",height:"12",xmlns:"http://www.w3.org/2000/svg"},n("path",{d:"M.59 10.59L5.17 6 .59 1.41 2 0l6 6-6 6z"}))),n("button",{id:"wm-".concat(this.totalPages,"-arw"),class:"paginationbtn",onClick:function(){e.currentPage=e.totalPages;e.updatePageDisplayed(e.totalPages);e.maintainFocusOnNumberChange("next-arrow")},value:this.totalPages,"aria-current":this.currentPage===this.totalPages?"page":undefined,"aria-label":"Go to last page, page ".concat(this.totalPages),"aria-controls":"status",disabled:this.currentPage===this.totalPages},n("svg",{width:"17",height:"12",xmlns:"http://www.w3.org/2000/svg"},n("path",{d:"M.59 10.59L5.17 6 .59 1.41 2 0l6 6-6 6zM9.59 10.59L14.17 6 9.59 1.41 11 0l6 6-6 6z"})))))};e.prototype.render=function(){return this.totalItems>this.itemsPerPage&&n("nav",{"aria-label":"Pagination Navigation. ".concat(this.getCurrentPagesInView(),". Current page, ").concat(this.currentPage,".")},this.isLargeViewport?this.renderLarge():this.renderSmall(),n("div",{id:"status",class:"sr-only","aria-live":"polite","aria-relevant":"text","aria-atomic":"true"},this.srAnnouncement))};Object.defineProperty(e,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"el",{get:function(){return r(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{totalItems:["calculateTotalPages"],itemsPerPage:["calculateTotalPages"]}},enumerable:false,configurable:true});return e}());o.style=s}}}));
|