@watermarkinsights/ripple 5.3.0-0 → 5.3.0-2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{chartFunctions-9075d687.js → chartFunctions-246529c5.js} +3 -3
- package/dist/cjs/{functions-b73604c3.js → functions-be4156cf.js} +7 -104
- package/dist/{esm/app-globals-0c592c57.js → cjs/global-6b1a23e9.js} +2 -7
- package/dist/cjs/index-f8ef86de.js +2582 -0
- package/dist/cjs/{intl-b20d5420.js → intl-a13884e8.js} +1 -1
- package/dist/cjs/loader.cjs.js +3 -4
- package/dist/cjs/priv-calendar.cjs.entry.js +5 -6
- package/dist/cjs/priv-chart-popover.cjs.entry.js +5 -6
- package/dist/cjs/priv-navigator-button.cjs.entry.js +3 -4
- package/dist/cjs/priv-navigator-item.cjs.entry.js +3 -4
- package/dist/cjs/ripple.cjs.js +11 -12
- package/dist/cjs/wm-action-menu_2.cjs.entry.js +6 -8
- package/dist/cjs/wm-button.cjs.entry.js +4 -5
- package/dist/cjs/wm-chart-slice.cjs.entry.js +1 -1
- package/dist/cjs/wm-chart.cjs.entry.js +6 -7
- package/dist/cjs/wm-date-range.cjs.entry.js +7 -8
- package/dist/cjs/wm-datepicker.cjs.entry.js +7 -8
- package/dist/cjs/wm-file-list.cjs.entry.js +3 -4
- package/dist/cjs/wm-file.cjs.entry.js +4 -5
- package/dist/cjs/wm-input.cjs.entry.js +5 -6
- package/dist/cjs/wm-line-chart.cjs.entry.js +14 -15
- package/dist/cjs/wm-modal-footer.cjs.entry.js +3 -4
- package/dist/cjs/wm-modal-header.cjs.entry.js +5 -6
- package/dist/cjs/wm-modal.cjs.entry.js +5 -6
- package/dist/cjs/wm-navigation_3.cjs.entry.js +10 -13
- package/dist/cjs/wm-navigator.cjs.entry.js +3 -4
- package/dist/cjs/wm-option_2.cjs.entry.js +8 -10
- package/dist/cjs/wm-pagination.cjs.entry.js +4 -5
- package/dist/cjs/wm-progress-indicator_3.cjs.entry.js +7 -9
- package/dist/cjs/wm-search.cjs.entry.js +6 -7
- package/dist/cjs/wm-snackbar.cjs.entry.js +69 -35
- package/dist/cjs/wm-tab-item_3.cjs.entry.js +8 -11
- package/dist/cjs/wm-tag-input.cjs.entry.js +7 -8
- package/dist/cjs/wm-tag-option.cjs.entry.js +2 -2
- package/dist/cjs/wm-textarea.cjs.entry.js +5 -6
- package/dist/cjs/wm-timepicker.cjs.entry.js +5 -6
- package/dist/cjs/wm-toggletip.cjs.entry.js +5 -6
- package/dist/cjs/wm-uploader.cjs.entry.js +6 -7
- package/dist/cjs/wm-wrapper.cjs.entry.js +1 -1
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/charts/chartFunctions.js +1 -1
- package/dist/collection/components/charts/chartFunctions.spec.js +16 -0
- package/dist/collection/components/charts/priv-chart-popover/priv-chart-popover.e2e.js +81 -0
- package/dist/collection/components/charts/priv-chart-popover/priv-chart-popover.js +2 -2
- package/dist/collection/components/charts/screenshots.e2e.js +96 -0
- package/dist/collection/components/charts/wm-chart/wm-chart.e2e.js +213 -0
- package/dist/collection/components/charts/wm-chart/wm-chart.js +1 -1
- package/dist/collection/components/charts/wm-chart/wm-chart.spec.js +37 -0
- package/dist/collection/components/charts/wm-line-chart/wm-line-chart.e2e.js +176 -0
- package/dist/collection/components/charts/wm-line-chart/wm-line-chart.js +9 -9
- package/dist/collection/components/charts/wm-line-chart/wm-line-chart.spec.js +163 -0
- package/dist/collection/components/charts/wm-progress-monitor/wm-progress-indicator.js +1 -1
- package/dist/collection/components/charts/wm-progress-monitor/wm-progress-monitor.e2e.js +69 -0
- package/dist/collection/components/charts/wm-progress-monitor/wm-progress-monitor.js +1 -1
- package/dist/collection/components/charts/wm-progress-monitor/wm-progress-monitor.spec.js +79 -0
- package/dist/collection/components/datepickers/priv-calendar/priv-calendar.js +2 -2
- package/dist/collection/components/datepickers/priv-calendar/priv-calendar.spec.js +89 -0
- package/dist/collection/components/datepickers/wm-date-range.e2e.js +443 -0
- package/dist/collection/components/datepickers/wm-date-range.js +12 -16
- package/dist/collection/components/datepickers/wm-date-range.spec.js +22 -0
- package/dist/collection/components/datepickers/wm-datepicker.e2e.js +382 -0
- package/dist/collection/components/datepickers/wm-datepicker.js +12 -16
- package/dist/collection/components/datepickers/wm-datepicker.spec.js +21 -0
- package/dist/collection/components/wm-action-menu/wm-action-menu.e2e.js +200 -0
- package/dist/collection/components/wm-action-menu/wm-action-menu.js +1 -1
- package/dist/collection/components/wm-action-menu/wm-action-menu.spec.js +48 -0
- package/dist/collection/components/wm-button/wm-button.e2e.js +55 -0
- package/dist/collection/components/wm-button/wm-button.js +1 -1
- package/dist/collection/components/wm-button/wm-button.spec.js +74 -0
- package/dist/collection/components/wm-file/wm-file.js +1 -1
- package/dist/collection/components/wm-file/wm-file.spec.js +194 -0
- package/dist/collection/components/wm-file-list/wm-file-list.js +1 -1
- package/dist/collection/components/wm-file-list/wm-file-list.spec.js +69 -0
- package/dist/collection/components/wm-input/wm-input.e2e.js +32 -0
- package/dist/collection/components/wm-input/wm-input.js +1 -1
- package/dist/collection/components/wm-input/wm-input.spec.js +173 -0
- package/dist/collection/components/wm-menuitem/wm-menuitem.e2e.js +23 -0
- package/dist/collection/components/wm-menuitem/wm-menuitem.js +1 -1
- package/dist/collection/components/wm-menuitem/wm-menuitem.spec.js +54 -0
- package/dist/collection/components/wm-modal/wm-modal-footer.js +1 -1
- package/dist/collection/components/wm-modal/wm-modal-footer.spec.js +11 -0
- package/dist/collection/components/wm-modal/wm-modal-header.js +1 -1
- package/dist/collection/components/wm-modal/wm-modal-header.spec.js +8 -0
- package/dist/collection/components/wm-modal/wm-modal.e2e.js +104 -0
- package/dist/collection/components/wm-modal/wm-modal.js +2 -2
- package/dist/collection/components/wm-modal/wm-modal.spec.js +30 -0
- package/dist/collection/components/wm-navigation/wm-navigation-hamburger.js +1 -1
- package/dist/collection/components/wm-navigation/wm-navigation-item.js +1 -1
- package/dist/collection/components/wm-navigation/wm-navigation.e2e.js +102 -0
- package/dist/collection/components/wm-navigation/wm-navigation.js +2 -2
- package/dist/collection/components/wm-navigation/wm-navigation.spec.js +91 -0
- package/dist/collection/components/wm-navigator/priv-navigator-button/priv-navigator-button.e2e.js +50 -0
- package/dist/collection/components/wm-navigator/priv-navigator-button/priv-navigator-button.js +1 -1
- package/dist/collection/components/wm-navigator/priv-navigator-item/priv-navigator-item.js +1 -1
- package/dist/collection/components/wm-navigator/wm-navigator.e2e.js +209 -0
- package/dist/collection/components/wm-navigator/wm-navigator.spec.js +177 -0
- package/dist/collection/components/wm-option/wm-option.e2e.js +22 -0
- package/dist/collection/components/wm-option/wm-option.js +1 -1
- package/dist/collection/components/wm-option/wm-option.spec.js +63 -0
- package/dist/collection/components/wm-pagination/wm-pagination.e2e.js +312 -0
- package/dist/collection/components/wm-pagination/wm-pagination.js +1 -1
- package/dist/collection/components/wm-search/wm-search.e2e.js +76 -0
- package/dist/collection/components/wm-search/wm-search.js +4 -5
- package/dist/collection/components/wm-search/wm-search.spec.js +71 -0
- package/dist/collection/components/wm-select/wm-select.e2e.js +521 -0
- package/dist/collection/components/wm-select/wm-select.js +2 -2
- package/dist/collection/components/wm-select/wm-select.spec.js +271 -0
- package/dist/collection/components/wm-snackbar/wm-snackbar.css +69 -46
- package/dist/collection/components/wm-snackbar/wm-snackbar.e2e.js +112 -0
- package/dist/collection/components/wm-snackbar/wm-snackbar.js +66 -31
- package/dist/collection/components/wm-snackbar/wm-snackbar.spec.js +9 -0
- package/dist/collection/components/wm-tabs/wm-tab-item/wm-tab-item.js +1 -1
- package/dist/collection/components/wm-tabs/wm-tab-list/wm-tab-list.js +1 -1
- package/dist/collection/components/wm-tabs/wm-tab-panel/wm-tab-panel.js +1 -1
- package/dist/collection/components/wm-tabs/wm-tabs.e2e.js +91 -0
- package/dist/collection/components/wm-tabs/wm-tabs.spec.js +12 -0
- package/dist/collection/components/wm-tag-input/wm-tag-input.e2e.js +204 -0
- package/dist/collection/components/wm-tag-input/wm-tag-input.js +3 -3
- package/dist/collection/components/wm-tag-input/wm-tag-input.spec.js +195 -0
- package/dist/collection/components/wm-textarea/wm-textarea.e2e.js +41 -0
- package/dist/collection/components/wm-textarea/wm-textarea.js +1 -1
- package/dist/collection/components/wm-textarea/wm-textarea.spec.js +79 -0
- package/dist/collection/components/wm-timepicker/wm-timepicker.e2e.js +163 -0
- package/dist/collection/components/wm-timepicker/wm-timepicker.js +8 -11
- package/dist/collection/components/wm-timepicker/wm-timepicker.spec.js +147 -0
- package/dist/collection/components/wm-toggletip/wm-toggletip.e2e.js +69 -0
- package/dist/collection/components/wm-toggletip/wm-toggletip.js +2 -2
- package/dist/collection/components/wm-toggletip/wm-toggletip.spec.js +21 -0
- package/dist/collection/components/wm-uploader/wm-uploader.e2e.js +70 -0
- package/dist/collection/components/wm-uploader/wm-uploader.js +2 -2
- package/dist/collection/components/wm-uploader/wm-uploader.spec.js +234 -0
- package/dist/collection/dev/snackbar.js +48 -32
- package/dist/collection/global/functions.spec.js +126 -0
- package/dist/collection/lang/lang.spec.js +20 -0
- package/dist/esm/{chartFunctions-730742b7.js → chartFunctions-e2554a36.js} +3 -3
- package/dist/esm/{functions-eda88c5f.js → functions-f65dbb96.js} +8 -105
- package/dist/{cjs/app-globals-7025eb63.js → esm/global-b3bbb95e.js} +1 -10
- package/dist/esm/index-f164fbca.js +2552 -0
- package/dist/esm/{intl-de8432e2.js → intl-f7f77de7.js} +1 -1
- package/dist/esm/loader.js +4 -5
- 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-calendar.entry.js +5 -6
- package/dist/esm/priv-chart-popover.entry.js +5 -6
- package/dist/esm/priv-navigator-button.entry.js +3 -4
- package/dist/esm/priv-navigator-item.entry.js +3 -4
- package/dist/esm/ripple.js +12 -13
- package/dist/esm/wm-action-menu_2.entry.js +6 -8
- package/dist/esm/wm-button.entry.js +4 -5
- package/dist/esm/wm-chart-slice.entry.js +1 -1
- package/dist/esm/wm-chart.entry.js +6 -7
- package/dist/esm/wm-date-range.entry.js +7 -8
- package/dist/esm/wm-datepicker.entry.js +7 -8
- package/dist/esm/wm-file-list.entry.js +3 -4
- package/dist/esm/wm-file.entry.js +4 -5
- package/dist/esm/wm-input.entry.js +5 -6
- package/dist/esm/wm-line-chart.entry.js +14 -15
- package/dist/esm/wm-modal-footer.entry.js +3 -4
- package/dist/esm/wm-modal-header.entry.js +5 -6
- package/dist/esm/wm-modal.entry.js +5 -6
- package/dist/esm/wm-navigation_3.entry.js +10 -13
- package/dist/esm/wm-navigator.entry.js +3 -4
- package/dist/esm/wm-option_2.entry.js +8 -10
- package/dist/esm/wm-pagination.entry.js +4 -5
- package/dist/esm/wm-progress-indicator_3.entry.js +7 -9
- package/dist/esm/wm-search.entry.js +6 -7
- package/dist/esm/wm-snackbar.entry.js +69 -35
- package/dist/esm/wm-tab-item_3.entry.js +8 -11
- package/dist/esm/wm-tag-input.entry.js +7 -8
- package/dist/esm/wm-tag-option.entry.js +2 -2
- package/dist/esm/wm-textarea.entry.js +5 -6
- package/dist/esm/wm-timepicker.entry.js +5 -6
- package/dist/esm/wm-toggletip.entry.js +5 -6
- package/dist/esm/wm-uploader.entry.js +6 -7
- package/dist/esm/wm-wrapper.entry.js +1 -1
- package/dist/esm-es5/{chartFunctions-730742b7.js → chartFunctions-e2554a36.js} +1 -1
- package/dist/esm-es5/functions-f65dbb96.js +1 -0
- package/dist/esm-es5/global-b3bbb95e.js +1 -0
- package/dist/esm-es5/index-f164fbca.js +1 -0
- package/dist/esm-es5/{intl-de8432e2.js → intl-f7f77de7.js} +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/priv-calendar.entry.js +1 -1
- package/dist/esm-es5/priv-chart-popover.entry.js +1 -1
- package/dist/esm-es5/priv-navigator-button.entry.js +1 -1
- package/dist/esm-es5/priv-navigator-item.entry.js +1 -1
- package/dist/esm-es5/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-slice.entry.js +1 -1
- package/dist/esm-es5/wm-chart.entry.js +1 -1
- package/dist/esm-es5/wm-date-range.entry.js +1 -1
- package/dist/esm-es5/wm-datepicker.entry.js +1 -1
- package/dist/esm-es5/wm-file-list.entry.js +1 -1
- package/dist/esm-es5/wm-file.entry.js +1 -1
- package/dist/esm-es5/wm-input.entry.js +1 -1
- package/dist/esm-es5/wm-line-chart.entry.js +1 -1
- package/dist/esm-es5/wm-modal-footer.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-option_2.entry.js +1 -1
- package/dist/esm-es5/wm-pagination.entry.js +1 -1
- package/dist/esm-es5/wm-progress-indicator_3.entry.js +1 -1
- package/dist/esm-es5/wm-search.entry.js +1 -1
- package/dist/esm-es5/wm-snackbar.entry.js +1 -1
- package/dist/esm-es5/wm-tab-item_3.entry.js +1 -1
- package/dist/esm-es5/wm-tag-input.entry.js +1 -1
- package/dist/esm-es5/wm-tag-option.entry.js +1 -1
- package/dist/esm-es5/wm-textarea.entry.js +1 -1
- package/dist/esm-es5/wm-timepicker.entry.js +1 -1
- package/dist/esm-es5/wm-toggletip.entry.js +1 -1
- package/dist/esm-es5/wm-uploader.entry.js +1 -1
- package/dist/esm-es5/wm-wrapper.entry.js +1 -1
- package/dist/loader/cdn.js +2 -1
- package/dist/loader/index.cjs.js +2 -1
- package/dist/loader/index.d.ts +0 -3
- package/dist/loader/index.es2017.js +2 -1
- package/dist/loader/index.js +2 -1
- package/dist/ripple/p-04bf6c89.entry.js +1 -0
- package/dist/ripple/{p-98e77431.entry.js → p-0b77b2a1.entry.js} +1 -1
- package/dist/ripple/p-0fe97e85.system.js +2 -0
- package/dist/ripple/p-109684b1.entry.js +1 -0
- package/dist/ripple/p-11383396.system.entry.js +1 -0
- package/dist/ripple/{p-7b5ac088.entry.js → p-19dec591.entry.js} +1 -1
- package/dist/ripple/p-1cb6b37e.entry.js +1 -0
- package/dist/ripple/p-2197287c.entry.js +1 -0
- package/dist/ripple/{p-5ab8174c.entry.js → p-22e6104e.entry.js} +1 -1
- package/dist/ripple/p-24d88d8d.system.entry.js +1 -0
- package/dist/ripple/{p-ff095cec.entry.js → p-25446670.entry.js} +1 -1
- package/dist/ripple/p-2bac4b4e.system.entry.js +1 -0
- package/dist/ripple/p-30a9ba6e.entry.js +1 -0
- package/dist/ripple/p-32cf6907.system.entry.js +1 -0
- package/dist/ripple/p-379fe53e.entry.js +1 -0
- package/dist/ripple/{p-4aae5688.entry.js → p-3a070f35.entry.js} +1 -1
- package/dist/ripple/{p-181068af.system.entry.js → p-3db9e0d8.system.entry.js} +1 -1
- package/dist/ripple/p-41e8a079.entry.js +1 -0
- package/dist/ripple/p-4272aa37.system.js +1 -0
- package/dist/ripple/p-45126063.system.entry.js +1 -0
- package/dist/ripple/{p-fd34619f.system.entry.js → p-48a6acfa.system.entry.js} +1 -1
- package/dist/ripple/p-4de51706.js +2 -0
- package/dist/ripple/{p-245f0080.entry.js → p-4e616347.entry.js} +1 -1
- package/dist/ripple/p-577ea283.system.entry.js +1 -0
- package/dist/ripple/p-5a04c222.entry.js +1 -0
- package/dist/ripple/{p-3036a712.js → p-5b2c1bd1.js} +1 -1
- package/dist/ripple/{p-e0929c38.system.js → p-5bbf7fdc.system.js} +1 -1
- package/dist/ripple/p-5dbad2ff.entry.js +1 -0
- package/dist/ripple/p-625aeeec.system.entry.js +1 -0
- package/dist/ripple/p-635f40b1.entry.js +1 -0
- package/dist/ripple/p-63fabfed.entry.js +1 -0
- package/dist/ripple/p-6dc3ee86.system.js +1 -0
- package/dist/ripple/p-7144d185.system.entry.js +1 -0
- package/dist/ripple/p-720b6ab0.entry.js +1 -0
- package/dist/ripple/p-7573a2fa.entry.js +1 -0
- package/dist/ripple/p-76d2dada.entry.js +1 -0
- package/dist/ripple/{p-0f117524.system.entry.js → p-780d4673.system.entry.js} +1 -1
- package/dist/ripple/p-79af9baf.entry.js +1 -0
- package/dist/ripple/{p-b6dcc6d8.system.entry.js → p-7a9ffbcb.system.entry.js} +1 -1
- package/dist/ripple/{p-f170963b.system.entry.js → p-7e56da2e.system.entry.js} +1 -1
- package/dist/ripple/p-7f4b4071.system.entry.js +1 -0
- package/dist/ripple/{p-a36f5e7d.system.entry.js → p-8081f931.system.entry.js} +1 -1
- package/dist/ripple/p-84926b89.system.entry.js +1 -0
- package/dist/ripple/p-88406560.system.entry.js +1 -0
- package/dist/ripple/{p-f95bc54b.entry.js → p-8f38dc86.entry.js} +1 -1
- package/dist/ripple/p-92c1ff36.system.entry.js +1 -0
- package/dist/ripple/{p-0e1523db.entry.js → p-98120733.entry.js} +1 -1
- package/dist/ripple/p-9c6d6b26.system.entry.js +1 -0
- package/dist/ripple/{p-e3a15de3.system.entry.js → p-9d8c2a52.system.entry.js} +1 -1
- package/dist/ripple/{p-47d993b9.system.entry.js → p-a99b05de.system.entry.js} +1 -1
- package/dist/ripple/{p-ce028b38.system.js → p-ae32eb8d.system.js} +1 -1
- package/dist/ripple/p-ae8ad491.entry.js +1 -0
- package/dist/ripple/p-b0579a2a.system.entry.js +1 -0
- package/dist/ripple/p-b0f14557.system.entry.js +1 -0
- package/dist/ripple/p-ba751ca4.js +1 -0
- package/dist/ripple/{p-39f4fca0.system.entry.js → p-bd27ded2.system.entry.js} +1 -1
- package/dist/ripple/p-c38f2a00.system.entry.js +1 -0
- package/dist/ripple/p-c51293e2.entry.js +1 -0
- package/dist/ripple/p-c717d895.entry.js +1 -0
- package/dist/ripple/p-c8873e0c.system.entry.js +1 -0
- package/dist/ripple/p-ca9d9447.system.entry.js +1 -0
- package/dist/ripple/p-cda6c77e.entry.js +1 -0
- package/dist/ripple/{p-ecd26b33.system.entry.js → p-ce5455a3.system.entry.js} +1 -1
- package/dist/ripple/p-d265a41e.entry.js +1 -0
- package/dist/ripple/p-d325a37b.entry.js +1 -0
- package/dist/ripple/p-d7c47dc0.system.entry.js +1 -0
- package/dist/ripple/p-d88d806e.js +1 -0
- package/dist/ripple/p-dcfdbd30.entry.js +1 -0
- package/dist/ripple/p-eb649319.system.js +1 -0
- package/dist/ripple/p-ef3fe609.system.entry.js +1 -0
- package/dist/ripple/p-f6f29a56.entry.js +1 -0
- package/dist/ripple/{p-96cc3c63.js → p-f79a6e32.js} +1 -1
- package/dist/ripple/p-f93858ad.system.entry.js +1 -0
- package/dist/ripple/p-fc7e5296.entry.js +1 -0
- package/dist/ripple/p-ff80aadd.system.entry.js +1 -0
- package/dist/ripple/ripple.esm.js +1 -1
- package/dist/ripple/ripple.js +1 -1
- package/dist/types/components/wm-snackbar/wm-snackbar.d.ts +6 -3
- package/dist/types/global/interfaces.d.ts +3 -0
- package/dist/types/stencil-public-runtime.d.ts +10 -3
- package/package.json +1 -1
- package/dist/cjs/index-3c3d6c9f.js +0 -1810
- package/dist/esm/index-0ed3ed7d.js +0 -1780
- package/dist/esm-es5/app-globals-0c592c57.js +0 -1
- package/dist/esm-es5/functions-eda88c5f.js +0 -1
- package/dist/esm-es5/index-0ed3ed7d.js +0 -1
- package/dist/ripple/p-0096e233.system.entry.js +0 -1
- package/dist/ripple/p-0ad27de3.system.entry.js +0 -1
- package/dist/ripple/p-0ccf9f96.entry.js +0 -1
- package/dist/ripple/p-0f7a85f4.entry.js +0 -1
- package/dist/ripple/p-13760c2c.entry.js +0 -1
- package/dist/ripple/p-14bab3fa.system.entry.js +0 -1
- package/dist/ripple/p-1e536698.js +0 -1
- package/dist/ripple/p-2c18b6d1.system.entry.js +0 -1
- package/dist/ripple/p-340b18ea.entry.js +0 -1
- package/dist/ripple/p-37c39a40.system.entry.js +0 -1
- package/dist/ripple/p-3f5e94e3.system.js +0 -1
- package/dist/ripple/p-48beea19.system.js +0 -1
- package/dist/ripple/p-4ea963f3.system.entry.js +0 -1
- package/dist/ripple/p-501d3115.entry.js +0 -1
- package/dist/ripple/p-527581c5.entry.js +0 -1
- package/dist/ripple/p-563b5820.entry.js +0 -1
- package/dist/ripple/p-57695dba.js +0 -2
- package/dist/ripple/p-5c6c325e.system.entry.js +0 -1
- package/dist/ripple/p-5f4c8d63.system.entry.js +0 -1
- package/dist/ripple/p-68e3e7c0.entry.js +0 -1
- package/dist/ripple/p-68fec757.system.entry.js +0 -1
- package/dist/ripple/p-6982bc34.entry.js +0 -1
- package/dist/ripple/p-6a793c40.system.entry.js +0 -1
- package/dist/ripple/p-6c31f0ad.system.entry.js +0 -1
- package/dist/ripple/p-6daf1bd3.system.entry.js +0 -1
- package/dist/ripple/p-6e406e8b.entry.js +0 -1
- package/dist/ripple/p-77210f26.entry.js +0 -1
- package/dist/ripple/p-7a844f5d.system.js +0 -2
- package/dist/ripple/p-7d5aaa73.system.entry.js +0 -1
- package/dist/ripple/p-80c92919.system.entry.js +0 -1
- package/dist/ripple/p-81fd2ed5.system.entry.js +0 -1
- package/dist/ripple/p-84d294d1.system.js +0 -1
- package/dist/ripple/p-85178a0d.entry.js +0 -1
- package/dist/ripple/p-8768ba4d.system.entry.js +0 -1
- package/dist/ripple/p-8af21b69.entry.js +0 -1
- package/dist/ripple/p-a30eef53.entry.js +0 -1
- package/dist/ripple/p-ad6c979f.entry.js +0 -1
- package/dist/ripple/p-af8c1cfa.entry.js +0 -1
- package/dist/ripple/p-b19be746.entry.js +0 -1
- package/dist/ripple/p-b483ec14.entry.js +0 -1
- package/dist/ripple/p-b4a34241.entry.js +0 -1
- package/dist/ripple/p-be28a95e.system.entry.js +0 -1
- package/dist/ripple/p-c6d970a4.entry.js +0 -1
- package/dist/ripple/p-dba63006.system.entry.js +0 -1
- package/dist/ripple/p-dbb37269.system.entry.js +0 -1
- package/dist/ripple/p-e19f8c43.js +0 -1
- package/dist/ripple/p-e3d66797.entry.js +0 -1
- package/dist/ripple/p-e64276f2.entry.js +0 -1
- package/dist/ripple/p-e9978b2f.entry.js +0 -1
- package/dist/ripple/p-ecbd3ea9.system.entry.js +0 -1
- package/dist/ripple/p-ee49cb03.entry.js +0 -1
- package/dist/ripple/p-f0fbb86b.system.entry.js +0 -1
- package/dist/ripple/p-f4f3bf9f.system.entry.js +0 -1
- package/dist/types/components/datepickers/priv-calendar/priv-calendar.d.ts +0 -72
- package/dist/types/components/datepickers/wm-date-range.d.ts +0 -68
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { h } from "@stencil/core";
|
|
1
|
+
import { h, Host } from "@stencil/core";
|
|
2
2
|
import { generateId, hideTooltip, showTooltip } from "../../global/functions";
|
|
3
3
|
import { globalMessages } from "../../global/intl";
|
|
4
4
|
export class Snackbar {
|
|
@@ -6,18 +6,30 @@ export class Snackbar {
|
|
|
6
6
|
this.parsedNotifications = [];
|
|
7
7
|
this.uid = this.el.id ? this.el.id : generateId();
|
|
8
8
|
this.focusOnDismiss = null;
|
|
9
|
-
this.timers =
|
|
9
|
+
this.timers = {};
|
|
10
10
|
this.notifications = "[]";
|
|
11
11
|
this.isTabbing = false;
|
|
12
12
|
this.announcement = "";
|
|
13
13
|
}
|
|
14
|
+
componentDidLoad() {
|
|
15
|
+
const snackObserver = new MutationObserver((snackMutations) => snackMutations.forEach((mutationRecord) => this.handleSnackMutation(mutationRecord)));
|
|
16
|
+
snackObserver.observe(this.snackAreaEl, { childList: true });
|
|
17
|
+
}
|
|
18
|
+
handleSnackMutation(mutationRecord) {
|
|
19
|
+
const addedSnacks = Array.from(mutationRecord.addedNodes);
|
|
20
|
+
if (addedSnacks.length > 0) {
|
|
21
|
+
addedSnacks.forEach((s) => s.querySelector(".wm-snackbar").classList.add("grow"));
|
|
22
|
+
addedSnacks[0].scrollIntoView();
|
|
23
|
+
}
|
|
24
|
+
}
|
|
14
25
|
updateSnacks(newValue) {
|
|
15
|
-
const
|
|
26
|
+
const prevParsedNotifications = [...this.parsedNotifications];
|
|
16
27
|
this.parsedNotifications = [...JSON.parse(newValue)];
|
|
17
|
-
|
|
28
|
+
this.refreshUpdatedNotifications(prevParsedNotifications);
|
|
29
|
+
if (prevParsedNotifications.length < this.parsedNotifications.length) {
|
|
18
30
|
const latestNotification = this.parsedNotifications[0];
|
|
19
|
-
const newTimer = window.setTimeout(() => this.snackExpired(),
|
|
20
|
-
this.timers = [newTimer,
|
|
31
|
+
const newTimer = window.setTimeout(() => this.snackExpired(latestNotification.id), 6000);
|
|
32
|
+
this.timers = Object.assign({ [latestNotification.id]: newTimer }, this.timers);
|
|
21
33
|
// don't announce link if user is tabbing because link is focused after announcement
|
|
22
34
|
this.announce(`${latestNotification.message} ${this.isTabbing ? "" : latestNotification.link}`);
|
|
23
35
|
if (this.isTabbing && latestNotification.link) {
|
|
@@ -30,22 +42,38 @@ export class Snackbar {
|
|
|
30
42
|
});
|
|
31
43
|
}
|
|
32
44
|
}
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
45
|
+
this.setMinWidths();
|
|
46
|
+
}
|
|
47
|
+
refreshUpdatedNotifications(prevNotifications) {
|
|
48
|
+
let updatedNotifications = [];
|
|
49
|
+
prevNotifications.forEach((prevNotification) => {
|
|
50
|
+
this.parsedNotifications.forEach((newNotification) => {
|
|
51
|
+
if (newNotification.id == prevNotification.id && newNotification.message != prevNotification.message) {
|
|
52
|
+
updatedNotifications.push(newNotification);
|
|
53
|
+
}
|
|
54
|
+
});
|
|
55
|
+
});
|
|
56
|
+
updatedNotifications.forEach((updatedNotification) => {
|
|
57
|
+
const notifEl = this.el.shadowRoot.querySelector(`#snack-${updatedNotification.id}`);
|
|
58
|
+
if (notifEl) {
|
|
59
|
+
notifEl.classList.remove("grow");
|
|
60
|
+
window.requestAnimationFrame(() => notifEl.classList.add("grow"));
|
|
61
|
+
}
|
|
62
|
+
this.stopTimer(updatedNotification);
|
|
63
|
+
const newTimer = window.setTimeout(() => this.snackExpired(updatedNotification.id), 6000);
|
|
64
|
+
this.timers = Object.assign({ [updatedNotification.id]: newTimer }, this.timers);
|
|
65
|
+
this.announce(`${updatedNotification.message} ${this.isTabbing ? "" : updatedNotification.link}`);
|
|
66
|
+
});
|
|
39
67
|
}
|
|
40
68
|
checkForTabbing(ev) {
|
|
41
69
|
if (ev.key === "Tab") {
|
|
42
|
-
this.
|
|
70
|
+
this.isTabbing = true;
|
|
43
71
|
}
|
|
44
72
|
}
|
|
45
73
|
// Workaround for screenreader's triggering click event on "enter"
|
|
46
74
|
// This is why we manually handle this.isTabbing instead of listening to wmUserIsTabbing
|
|
47
75
|
handleMouse() {
|
|
48
|
-
this.
|
|
76
|
+
this.isTabbing = false;
|
|
49
77
|
}
|
|
50
78
|
snackDismissed(notification) {
|
|
51
79
|
this.endSnack(notification);
|
|
@@ -56,9 +84,11 @@ export class Snackbar {
|
|
|
56
84
|
}
|
|
57
85
|
}
|
|
58
86
|
//Remove snack from notification list once timer runs out
|
|
59
|
-
snackExpired() {
|
|
60
|
-
const
|
|
61
|
-
|
|
87
|
+
snackExpired(expiredID) {
|
|
88
|
+
const expiredNotification = this.parsedNotifications.find((n) => n.id == expiredID);
|
|
89
|
+
if (expiredNotification) {
|
|
90
|
+
this.endSnack(expiredNotification);
|
|
91
|
+
}
|
|
62
92
|
}
|
|
63
93
|
endSnack(notification) {
|
|
64
94
|
//App listens for wmSnackbarSnackFinished event and deletes the emitted notification.
|
|
@@ -82,15 +112,21 @@ export class Snackbar {
|
|
|
82
112
|
}
|
|
83
113
|
//Delete the timer corresponding to the dismissed notification
|
|
84
114
|
stopTimer(notification) {
|
|
85
|
-
this.
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
115
|
+
if (this.timers[notification.id]) {
|
|
116
|
+
clearTimeout(this.timers[notification.id]);
|
|
117
|
+
delete this.timers[notification.id];
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
setMinWidths() {
|
|
121
|
+
// wait for render to get updated scrollWidth
|
|
122
|
+
requestAnimationFrame(() => {
|
|
123
|
+
const msgEls = this.el.shadowRoot.querySelectorAll(".msg");
|
|
124
|
+
msgEls.forEach((msgEl) => {
|
|
125
|
+
msgEl.classList.remove("long");
|
|
126
|
+
if (msgEl.scrollWidth > 216) {
|
|
127
|
+
msgEl.classList.add("long");
|
|
128
|
+
}
|
|
129
|
+
});
|
|
94
130
|
});
|
|
95
131
|
}
|
|
96
132
|
announce(message) {
|
|
@@ -100,16 +136,15 @@ export class Snackbar {
|
|
|
100
136
|
this.announcement = message;
|
|
101
137
|
}
|
|
102
138
|
renderSnackbars() {
|
|
103
|
-
return this.parsedNotifications.map((notification) => (h("div", { class: "wm-snack-wrapper" }, h("div", { id: `snack-${
|
|
139
|
+
return [...this.parsedNotifications].reverse().map((notification) => (h("div", { class: "wm-snack-wrapper" }, h("div", { id: `snack-${notification.id}`, class: "wm-snackbar active neutral" }, h("div", { class: "sr-only", tabindex: notification.link ? 0 : -1, onFocus: () => notification.link && this.snackDismissed(notification) }), h("div", { class: "wm-snackbarmsg" }, h("div", { class: "msgtext" }, h("span", { class: "msg" }, notification.message), notification.link && (h("a", { id: `action-${notification.id}`, class: `link ${notification.newWindow ? "new-window" : ""}`, "aria-label": `Click to ${notification.link}...${notification.newWindow ? " " + globalMessages.newWindow : ""}`, tabindex: 0, onClick: () => {
|
|
104
140
|
this.snackLinkClicked(notification);
|
|
105
141
|
}, onKeyDown: (ev) => ev.key === "Enter" && this.snackLinkClicked(notification) }, h("span", { "aria-hidden": "true" }, notification.link)))), h("button", { id: `close-button-${notification.id}`, "aria-label": "Close this notification", class: "closesnack", tabindex: notification.link ? 0 : -1, onClick: () => this.snackDismissed(notification), onMouseEnter: (ev) => showTooltip("bottom", ev.target, globalMessages.close), onMouseLeave: () => hideTooltip(), onFocus: (ev) => this.isTabbing && showTooltip("bottom", ev.target, globalMessages.close), onBlur: () => hideTooltip() })), h("div", { class: "sr-only", tabindex: notification.link ? 0 : -1, onFocus: () => notification.link && this.snackDismissed(notification) })))));
|
|
106
142
|
}
|
|
107
143
|
render() {
|
|
108
|
-
return (h("div", {
|
|
109
|
-
"
|
|
110
|
-
empty: this.parsedNotifications.length === 0,
|
|
144
|
+
return (h(Host, null, h("div", { ref: (el) => (this.snackAreaEl = el), class: {
|
|
145
|
+
"list-wrapper": true,
|
|
111
146
|
"user-is-tabbing": this.isTabbing,
|
|
112
|
-
} }, h("div", {
|
|
147
|
+
} }, this.renderSnackbars()), h("div", { class: "sr-only", "aria-live": "polite", "aria-atomic": "false", id: `wm-live-region-${this.uid}`, ref: (el) => (this.liveRegionEl = el) }, this.announcement)));
|
|
113
148
|
}
|
|
114
149
|
static get is() { return "wm-snackbar"; }
|
|
115
150
|
static get encapsulation() { return "shadow"; }
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { newSpecPage } from "@stencil/core/testing";
|
|
2
|
+
jest.mock("../../global/functions");
|
|
3
|
+
import { Snackbar } from "./wm-snackbar";
|
|
4
|
+
describe("wm-snackbar", () => {
|
|
5
|
+
it("builds", async () => {
|
|
6
|
+
const comp = await newSpecPage({ components: [Snackbar], html: "<wm-snackbar><wm-snackbar>" });
|
|
7
|
+
expect(comp.root).toMatchSnapshot();
|
|
8
|
+
});
|
|
9
|
+
});
|
|
@@ -40,7 +40,7 @@ export class TabItem {
|
|
|
40
40
|
"background-size": `calc(100% - ${bkgSize}${units}) 3px`,
|
|
41
41
|
};
|
|
42
42
|
}
|
|
43
|
-
return (h(Host, {
|
|
43
|
+
return (h(Host, { role: "presentation" }, h("li", { class: "tab-item", role: "presentation" }, h("a", { class: `tab ${classes}`, style: styles, role: "tab", ref: (el) => (this.linkEl = el), onClick: this.tabClicked, id: `tab-link-${this.tabId}`, onKeyDown: (ev) => this.tabPressed(ev), "aria-selected": this.selected ? "true" : "false", tabindex: this.selected ? 0 : -1 }, h("slot", null)))));
|
|
44
44
|
}
|
|
45
45
|
static get is() { return "wm-tab-item"; }
|
|
46
46
|
static get encapsulation() { return "shadow"; }
|
|
@@ -155,7 +155,7 @@ export class TabList {
|
|
|
155
155
|
} }, t.textContent)));
|
|
156
156
|
}
|
|
157
157
|
render() {
|
|
158
|
-
return h(Host, {
|
|
158
|
+
return h(Host, { class: this.menuLayout ? "menu" : "" }, this.renderMenuOrTabs());
|
|
159
159
|
}
|
|
160
160
|
static get is() { return "wm-tab-list"; }
|
|
161
161
|
static get encapsulation() { return "shadow"; }
|
|
@@ -12,7 +12,7 @@ export class TabPanel {
|
|
|
12
12
|
this.tabPanelLoaded.emit({ tabId: this.tabId });
|
|
13
13
|
}
|
|
14
14
|
render() {
|
|
15
|
-
return h(Host, {
|
|
15
|
+
return h(Host, { role: "tabpanel", class: { "tab-hidden": !this.active } });
|
|
16
16
|
}
|
|
17
17
|
static get is() { return "wm-tab-panel"; }
|
|
18
18
|
static get originalStyleUrls() {
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import { newE2EPage } from "@stencil/core/testing";
|
|
2
|
+
describe("wm-tab-item", () => {
|
|
3
|
+
let page; //, mock: any;
|
|
4
|
+
beforeEach(async () => {
|
|
5
|
+
page = await newE2EPage();
|
|
6
|
+
await page.setContent(`<html lang='en' dir="ltr">
|
|
7
|
+
<head><title>Page</title></head>
|
|
8
|
+
<body>
|
|
9
|
+
<main style="height: 3000px">
|
|
10
|
+
<h1>Title</h1>
|
|
11
|
+
<div id="tab-container">
|
|
12
|
+
<wm-tab-list id="test-tab" selected-tab="first">
|
|
13
|
+
<wm-tab-item tab-id="first" id="first-tab">First</wm-tab-item>
|
|
14
|
+
<wm-tab-item tab-id="second" id="second-tab">Second</wm-tab-item>
|
|
15
|
+
</wm-tab-list>
|
|
16
|
+
<wm-tab-panel tab-id="first" id="dynamic-panel">Tab Content First</wm-tab-panel>
|
|
17
|
+
</div>
|
|
18
|
+
<div id="test-div"></div>
|
|
19
|
+
</main>
|
|
20
|
+
</body>
|
|
21
|
+
</html>`);
|
|
22
|
+
await page.evaluate(async () => {
|
|
23
|
+
const container = document.querySelector("#tab-container");
|
|
24
|
+
container.addEventListener("wmTabSelected", (ev) => {
|
|
25
|
+
const tabList = document.querySelector("#test-tab");
|
|
26
|
+
tabList.selectedTab = ev.detail.tabId;
|
|
27
|
+
});
|
|
28
|
+
});
|
|
29
|
+
await page.waitForChanges();
|
|
30
|
+
});
|
|
31
|
+
it("renders a list item with a role of presentation and with a link that has a role of tab", async () => {
|
|
32
|
+
const tabItem = await page.find("wm-tab-item");
|
|
33
|
+
const listItem = await tabItem.shadowRoot.querySelector("li");
|
|
34
|
+
expect(listItem).not.toBeNull();
|
|
35
|
+
expect(listItem.getAttribute("role")).toEqual("presentation");
|
|
36
|
+
const link = await tabItem.shadowRoot.querySelector("a");
|
|
37
|
+
expect(link).not.toBeNull();
|
|
38
|
+
expect(link.getAttribute("role")).toEqual("tab");
|
|
39
|
+
});
|
|
40
|
+
it("emits an event when clicked or enter is pressed", async () => {
|
|
41
|
+
const wmTabSelectedSpy = await page.spyOnEvent("wmTabSelected");
|
|
42
|
+
await page.keyboard.press("Tab");
|
|
43
|
+
await page.keyboard.press("ArrowRight");
|
|
44
|
+
await page.keyboard.press("Enter");
|
|
45
|
+
expect(wmTabSelectedSpy).toHaveReceivedEventDetail({ tabId: "second" });
|
|
46
|
+
jest.restoreAllMocks();
|
|
47
|
+
});
|
|
48
|
+
it("has an aria-selected attribute set to true when it is selected", async () => {
|
|
49
|
+
await page.keyboard.press("Tab"); // To next tab component
|
|
50
|
+
await page.keyboard.press("ArrowRight");
|
|
51
|
+
await page.keyboard.press("Enter");
|
|
52
|
+
await page.waitForChanges();
|
|
53
|
+
let secondTabItemUncontrolled = await page.find("#second-tab");
|
|
54
|
+
const linkUncontrolled = await secondTabItemUncontrolled.shadowRoot.querySelector("#tab-link-second");
|
|
55
|
+
const selectedStatusUncontrolled = await linkUncontrolled.getAttribute("aria-selected");
|
|
56
|
+
expect(selectedStatusUncontrolled).toBe("true");
|
|
57
|
+
});
|
|
58
|
+
it("renders an unordered list with a role of tablist", async () => {
|
|
59
|
+
const ulElement = await page.find("wm-tab-list >>> ul");
|
|
60
|
+
expect(ulElement).not.toBeNull();
|
|
61
|
+
expect(ulElement.getAttribute("role")).toEqual("tablist");
|
|
62
|
+
});
|
|
63
|
+
it("has a role of tabpanel", async () => {
|
|
64
|
+
const tabPanel = await page.find("wm-tab-panel");
|
|
65
|
+
expect(tabPanel.getAttribute("role")).toEqual("tabpanel");
|
|
66
|
+
});
|
|
67
|
+
it("displays if the tab item with the same tabId is selected", async () => {
|
|
68
|
+
const dynamicPanel = await page.find("#dynamic-panel");
|
|
69
|
+
expect(dynamicPanel).not.toHaveClass("tab-hidden");
|
|
70
|
+
});
|
|
71
|
+
it("does not display if the tab item with the same tabId is not selected", async () => { });
|
|
72
|
+
it("has an aria-labelledby attribute that corresponds to the correct tab", async () => {
|
|
73
|
+
//uncontrolled -- tab panel attribute is dynamic
|
|
74
|
+
let changingTabPanel = await page.find("#dynamic-panel");
|
|
75
|
+
const label = await changingTabPanel.getAttribute("aria-labelledby");
|
|
76
|
+
expect(label).toEqual("tab-link-first");
|
|
77
|
+
let secondTabItemUncontrolled = await page.find("#second-tab");
|
|
78
|
+
await secondTabItemUncontrolled.click();
|
|
79
|
+
await page.waitForChanges();
|
|
80
|
+
changingTabPanel = await page.find("#dynamic-panel");
|
|
81
|
+
const newLabel = await changingTabPanel.getAttribute("aria-labelledby");
|
|
82
|
+
expect(newLabel).toEqual("tab-link-second");
|
|
83
|
+
});
|
|
84
|
+
it("switches to a dropdown at the appropriate breakpoint", async () => {
|
|
85
|
+
const comp = await page.find("wm-tab-list");
|
|
86
|
+
expect(comp).toMatchSnapshot();
|
|
87
|
+
page.setViewport({ width: 300, height: 900 });
|
|
88
|
+
await page.waitForChanges();
|
|
89
|
+
expect(comp).toMatchSnapshot();
|
|
90
|
+
});
|
|
91
|
+
});
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { newSpecPage } from "@stencil/core/testing";
|
|
2
|
+
import { TabList } from "./wm-tab-list/wm-tab-list";
|
|
3
|
+
import { TabItem } from "./wm-tab-item/wm-tab-item";
|
|
4
|
+
describe("wm-tabs", () => {
|
|
5
|
+
it("builds", async () => {
|
|
6
|
+
const page = await newSpecPage({
|
|
7
|
+
components: [TabList, TabItem],
|
|
8
|
+
html: '<wm-tab-list><wm-tab-item id="tab1"></wm-tab-item></wm-tab-list>',
|
|
9
|
+
});
|
|
10
|
+
expect(page.root).toMatchSnapshot();
|
|
11
|
+
});
|
|
12
|
+
});
|
|
@@ -0,0 +1,204 @@
|
|
|
1
|
+
import AxePuppeteer from "@axe-core/puppeteer";
|
|
2
|
+
import { newE2EPage } from "@stencil/core/testing";
|
|
3
|
+
describe("wm-tag-input", () => {
|
|
4
|
+
// ts throws erroneous warning about vars being unused...
|
|
5
|
+
// @ts-ignore
|
|
6
|
+
let page, el, input;
|
|
7
|
+
beforeEach(async () => {
|
|
8
|
+
page = await newE2EPage();
|
|
9
|
+
await page.setContent(`<html lang='en'><head><title>Page</title></head><body><main><h1>Title</h1>
|
|
10
|
+
<wm-tag-input label='label'>
|
|
11
|
+
<wm-tag-option>One</wm-tag-option>
|
|
12
|
+
<wm-tag-option>Two</wm-tag-option>
|
|
13
|
+
<wm-tag-option>Three</wm-tag-option>
|
|
14
|
+
</wm-tag-input>
|
|
15
|
+
</main></body></html>`);
|
|
16
|
+
el = await page.find("wm-tag-input");
|
|
17
|
+
input = await page.find("wm-tag-input >>> input");
|
|
18
|
+
await page.waitForChanges();
|
|
19
|
+
});
|
|
20
|
+
it("passes Axe checks", async () => {
|
|
21
|
+
const results = await new AxePuppeteer(page).analyze();
|
|
22
|
+
expect(results.violations.length).toBe(0);
|
|
23
|
+
});
|
|
24
|
+
it.skip("uses Enter and Comma to add a new tag", async () => {
|
|
25
|
+
page = await newE2EPage();
|
|
26
|
+
await page.setContent(`<html lang='en'><head><title>Page</title></head><body><main><h1>Title</h1>
|
|
27
|
+
<wm-tag-input label='label'></wm-tag-input>
|
|
28
|
+
</main></body></html>`);
|
|
29
|
+
await page.waitForChanges();
|
|
30
|
+
await page.keyboard.press("Tab");
|
|
31
|
+
await page.waitForChanges();
|
|
32
|
+
await page.keyboard.type("Hello");
|
|
33
|
+
await page.waitForChanges();
|
|
34
|
+
await page.keyboard.press("Enter");
|
|
35
|
+
await page.waitForChanges();
|
|
36
|
+
let tags = await page.findAll("wm-tag-input >>> .tag");
|
|
37
|
+
expect(tags[0].textContent).toBe("Hello");
|
|
38
|
+
await page.keyboard.type("Apple");
|
|
39
|
+
await page.waitForChanges();
|
|
40
|
+
await page.keyboard.type(",");
|
|
41
|
+
await page.waitForChanges();
|
|
42
|
+
tags = await page.findAll("wm-tag-input >>> .tag");
|
|
43
|
+
expect(tags[1].textContent).toBe("Apple");
|
|
44
|
+
// it clears the input when adding a tag
|
|
45
|
+
const input = await page.find("wm-tag-input >>> input");
|
|
46
|
+
const inputValue = await input.getProperty("value");
|
|
47
|
+
expect(inputValue).toBe("");
|
|
48
|
+
// it includes user-added options in the dropdown
|
|
49
|
+
const listItems = await page.findAll("wm-tag-input >>> .option");
|
|
50
|
+
expect(listItems[0].textContent).toBe("Apple");
|
|
51
|
+
expect(listItems[1].textContent).toBe("Hello");
|
|
52
|
+
// it shows tags in the order they are added
|
|
53
|
+
await page.keyboard.type("Third");
|
|
54
|
+
await page.waitForChanges();
|
|
55
|
+
await page.keyboard.press("Enter");
|
|
56
|
+
await page.waitForChanges();
|
|
57
|
+
tags = await page.findAll("wm-tag-input >>> .tag");
|
|
58
|
+
expect(tags[0].textContent).toBe("Hello");
|
|
59
|
+
expect(tags[1].textContent).toBe("Apple");
|
|
60
|
+
expect(tags[2].textContent).toBe("Third");
|
|
61
|
+
});
|
|
62
|
+
it("displays column1 text instead of id for table variant", async () => {
|
|
63
|
+
page = await newE2EPage();
|
|
64
|
+
await page.setContent(`<html lang='en'><head><title>Page</title></head><body><main><h1>Title</h1>
|
|
65
|
+
<wm-tag-input
|
|
66
|
+
tag-input-type="table"
|
|
67
|
+
label="Share Access"
|
|
68
|
+
col-headers="Name,Email,Role"
|
|
69
|
+
col-widths=",40%,20%"
|
|
70
|
+
col-wrap="wrap,trunc,wrap"
|
|
71
|
+
>
|
|
72
|
+
<wm-tag-option selected id="johnprice1" col1="John Price" col2="john.price1@university.edu" col3="Admin" locked></wm-tag-option>
|
|
73
|
+
<wm-tag-option id="johnprice2" col1="John Price" col2="john.price2@university.edu" col3="Faculty"></wm-tag-option>
|
|
74
|
+
<wm-tag-option id="samsandwich" col1="Sam Sandwich" col2="sam.sandwich@university.edu" col3="Faculty"></wm-tag-option>
|
|
75
|
+
</wm-tag-input>
|
|
76
|
+
</main></body></html>`);
|
|
77
|
+
await page.waitForChanges();
|
|
78
|
+
let tagTextList = await page.findAll("wm-tag-input >>> .tag-text");
|
|
79
|
+
expect(tagTextList[0].textContent).toBe("John Price");
|
|
80
|
+
});
|
|
81
|
+
it("does not allow adding tags if add-new prop is false", async () => {
|
|
82
|
+
page = await newE2EPage();
|
|
83
|
+
await page.setContent(`<html lang='en'><head><title>Page</title></head><body><main><h1>Title</h1>
|
|
84
|
+
<wm-tag-input label='label' add-new="false"></wm-tag-input>
|
|
85
|
+
</main></body></html>`);
|
|
86
|
+
await page.keyboard.press("Tab");
|
|
87
|
+
await page.waitForChanges();
|
|
88
|
+
await page.keyboard.press("Tab");
|
|
89
|
+
await page.waitForChanges();
|
|
90
|
+
await page.keyboard.type("New Tag");
|
|
91
|
+
await page.waitForChanges();
|
|
92
|
+
await page.keyboard.press("Enter");
|
|
93
|
+
await page.waitForChanges();
|
|
94
|
+
const tags = await page.findAll("wm-tag-input >>> .tag");
|
|
95
|
+
expect(tags.length).toBe(0);
|
|
96
|
+
});
|
|
97
|
+
it("does not allow duplicate tags to be added", async () => {
|
|
98
|
+
page = await newE2EPage();
|
|
99
|
+
await page.setContent(`<html lang='en'><head><title>Page</title></head><body><main><h1>Title</h1>
|
|
100
|
+
<wm-tag-input label='label'>
|
|
101
|
+
<wm-tag-option selected>one</wm-tag-option>
|
|
102
|
+
</wm-tag-input>
|
|
103
|
+
</main></body></html>`);
|
|
104
|
+
let tags = await page.findAll("wm-tag-input >>> .tag");
|
|
105
|
+
expect(tags.length).toBe(1);
|
|
106
|
+
await page.keyboard.press("Tab");
|
|
107
|
+
await page.waitForChanges();
|
|
108
|
+
await page.keyboard.press("Tab");
|
|
109
|
+
await page.waitForChanges();
|
|
110
|
+
await page.keyboard.type("one");
|
|
111
|
+
await page.waitForChanges();
|
|
112
|
+
await page.keyboard.press("Enter");
|
|
113
|
+
await page.waitForChanges();
|
|
114
|
+
await page.keyboard.press("Delete");
|
|
115
|
+
await page.keyboard.press("Delete");
|
|
116
|
+
await page.keyboard.press("Delete");
|
|
117
|
+
await page.waitForChanges();
|
|
118
|
+
// it is case insensitive
|
|
119
|
+
await page.keyboard.type("OnE");
|
|
120
|
+
await page.waitForChanges();
|
|
121
|
+
await page.keyboard.press("Enter");
|
|
122
|
+
await page.waitForChanges();
|
|
123
|
+
expect(tags.length).toBe(1);
|
|
124
|
+
});
|
|
125
|
+
it("opens dropdown when input field is focused", async () => {
|
|
126
|
+
const dropdown = await page.find("wm-tag-input >>> .dropdown-wrapper");
|
|
127
|
+
expect(dropdown).not.toHaveClass("open");
|
|
128
|
+
await input.focus();
|
|
129
|
+
expect(dropdown).toHaveClass("open");
|
|
130
|
+
});
|
|
131
|
+
it("closes dropdown", async () => {
|
|
132
|
+
//
|
|
133
|
+
// when pressing escape twice
|
|
134
|
+
// when clicking outside of component
|
|
135
|
+
// when tabbing out of component
|
|
136
|
+
// not while tabbing inside of component
|
|
137
|
+
});
|
|
138
|
+
it("renders the add new button when typing in the input", async () => { });
|
|
139
|
+
it("removes only user-added tags from the dropdown", async () => {
|
|
140
|
+
// Removing a pre-existing tag will have it still in the dropdown
|
|
141
|
+
// removing a user-added tag will remove it from the dropdown
|
|
142
|
+
});
|
|
143
|
+
it("navigates the dropdown with arrow keys", async () => {
|
|
144
|
+
let options = await page.findAll("wm-tag-input >>> .option");
|
|
145
|
+
await page.keyboard.press("Tab");
|
|
146
|
+
await page.waitForChanges();
|
|
147
|
+
await page.keyboard.press("ArrowDown");
|
|
148
|
+
await page.waitForChanges();
|
|
149
|
+
expect(options[0]).toHaveClass("focused");
|
|
150
|
+
expect(options[1]).not.toHaveClass("focused");
|
|
151
|
+
expect(options[2]).not.toHaveClass("focused");
|
|
152
|
+
await page.keyboard.press("ArrowDown");
|
|
153
|
+
await page.waitForChanges();
|
|
154
|
+
expect(options[0]).not.toHaveClass("focused");
|
|
155
|
+
expect(options[1]).toHaveClass("focused");
|
|
156
|
+
expect(options[2]).not.toHaveClass("focused");
|
|
157
|
+
await page.keyboard.press("ArrowDown");
|
|
158
|
+
await page.waitForChanges();
|
|
159
|
+
expect(options[0]).not.toHaveClass("focused");
|
|
160
|
+
expect(options[1]).not.toHaveClass("focused");
|
|
161
|
+
expect(options[2]).toHaveClass("focused");
|
|
162
|
+
await page.keyboard.press("ArrowDown");
|
|
163
|
+
await page.waitForChanges();
|
|
164
|
+
expect(options[0]).toHaveClass("focused");
|
|
165
|
+
expect(options[1]).not.toHaveClass("focused");
|
|
166
|
+
expect(options[2]).not.toHaveClass("focused");
|
|
167
|
+
await page.keyboard.press("ArrowUp");
|
|
168
|
+
await page.waitForChanges();
|
|
169
|
+
expect(options[0]).not.toHaveClass("focused");
|
|
170
|
+
expect(options[1]).not.toHaveClass("focused");
|
|
171
|
+
expect(options[2]).toHaveClass("focused");
|
|
172
|
+
});
|
|
173
|
+
it("navigates tags with left and right keys", async () => {
|
|
174
|
+
page = await newE2EPage();
|
|
175
|
+
await page.setContent(`<html lang='en'><head><title>Page</title></head><body><main><h1>Title</h1>
|
|
176
|
+
<wm-tag-input label='label'>
|
|
177
|
+
<wm-tag-option selected>One</wm-tag-option>
|
|
178
|
+
<wm-tag-option selected>Two</wm-tag-option>
|
|
179
|
+
<wm-tag-option selected>Three</wm-tag-option>
|
|
180
|
+
</wm-tag-input>
|
|
181
|
+
</main></body></html>`);
|
|
182
|
+
let tags = await page.findAll("wm-tag-input >>> .tag");
|
|
183
|
+
await page.keyboard.press("Tab");
|
|
184
|
+
await page.waitForChanges();
|
|
185
|
+
expect(tags[0]).toHaveClass("focused");
|
|
186
|
+
expect(tags[1]).not.toHaveClass("focused");
|
|
187
|
+
expect(tags[2]).not.toHaveClass("focused");
|
|
188
|
+
await page.keyboard.press("ArrowRight");
|
|
189
|
+
await page.waitForChanges();
|
|
190
|
+
expect(tags[0]).not.toHaveClass("focused");
|
|
191
|
+
expect(tags[1]).toHaveClass("focused");
|
|
192
|
+
expect(tags[2]).not.toHaveClass("focused");
|
|
193
|
+
await page.keyboard.press("ArrowLeft");
|
|
194
|
+
await page.waitForChanges();
|
|
195
|
+
expect(tags[0]).toHaveClass("focused");
|
|
196
|
+
expect(tags[1]).not.toHaveClass("focused");
|
|
197
|
+
expect(tags[2]).not.toHaveClass("focused");
|
|
198
|
+
await page.keyboard.press("ArrowLeft");
|
|
199
|
+
await page.waitForChanges();
|
|
200
|
+
expect(tags[0]).not.toHaveClass("focused");
|
|
201
|
+
expect(tags[1]).not.toHaveClass("focused");
|
|
202
|
+
expect(tags[2]).toHaveClass("focused");
|
|
203
|
+
});
|
|
204
|
+
});
|
|
@@ -858,12 +858,12 @@ export class TagInput {
|
|
|
858
858
|
}
|
|
859
859
|
}
|
|
860
860
|
render() {
|
|
861
|
-
return (h("div", {
|
|
861
|
+
return (h("div", { class: `wrapper label-${this.labelPosition} ${this.errorMessage ? "invalid" : ""}` }, h("div", { class: "label-wrapper" }, h("label", { class: "label", htmlFor: "input" }, this.label, this.requiredField && (h("span", { class: "required", "aria-hidden": "true" }, "*")))), h("div", { class: `field-wrapper ${this.el.shadowRoot.activeElement === this.inputEl ? "focused" : ""} ${this.errorMessage ? "invalid" : ""}`, ref: (el) => (this.fieldWrapperEl = el) }, h("div", { class: "upper-row" }, h("div", { class: `tags-and-input-wrapper ${this.inModal ? "in-modal" : ""}` }, h("ul", { ref: (el) => (this.tagAreaEl = el), class: `tag-area ${this.taggedOptions.length === 0 && "empty"} ${this.isKeying ? "user-is-keying" : ""}`, role: "listbox", "aria-activedescendant": this.focusedTag ? this.focusedTag.id : null, "aria-orientation": "horizontal", "aria-label": `${this.label} ${this.tagAreaInstructions}`, tabindex: this._tagEls.length > 0 ? 0 : -1, "aria-describedby": `info max-tags`, onFocus: (ev) => this.handleTagAreaFocus(ev), onBlur: (ev) => {
|
|
862
862
|
this.focusedTagIndex = undefined;
|
|
863
863
|
this.handleBlur(ev);
|
|
864
|
-
}, onKeyDown: (ev) => this.handleTagAreaKeyDown(ev) }, this.renderTags()), h("input", {
|
|
864
|
+
}, onKeyDown: (ev) => this.handleTagAreaKeyDown(ev) }, this.renderTags()), h("input", { id: "input", class: "input", role: "combobox", ref: (el) => (this.inputEl = el), autocomplete: "off", "aria-required": this.requiredField ? "true" : null, "aria-controls": this.tagInputType, "aria-describedby": `help-text${this.errorMessage ? " error " : ""} max-tags`, "aria-label": `${this.label} ${this.isDropdown ? globalMessages.getCharacterLimit(this.characterLimit) : ""}`, "aria-expanded": this.isDropdown ? this.isExpanded.toString() : null, "aria-activedescendant": this.inputActiveDescendantId, placeholder: this.placeholder, maxLength: this.isDropdown ? this.characterLimit : undefined, onInput: (ev) => this.handleInputChanged(ev), onBlur: (ev) => {
|
|
865
865
|
this.handleBlur(ev);
|
|
866
|
-
}, onFocus: () => this.handleInputFocus(), onKeyDown: (ev) => this.handleInputKeyDown(ev) })), this.isDropdown && (h("div", {
|
|
866
|
+
}, onFocus: () => this.handleInputFocus(), onKeyDown: (ev) => this.handleInputKeyDown(ev) })), this.isDropdown && (h("div", { class: "character-count" }, this.charCount, "/", this.characterLimit))), this.renderTagCounter(), this.isDropdown && this.renderDropdown()), this.info && (h("div", { id: "info", class: "info-text" }, this.info)), h("div", { id: "error" }, this.errorMessage), h("div", { class: "sr-only", "aria-live": "polite", ref: (el) => (this.liveRegionEl = el), "aria-atomic": "true" }, this.liveRegionMessage), this.isTable && this.renderTable()));
|
|
867
867
|
}
|
|
868
868
|
static get is() { return "wm-tag-input"; }
|
|
869
869
|
static get encapsulation() { return "shadow"; }
|