@watermarkinsights/ripple 3.36.0 → 3.37.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{chartFunctions-41c67866.js → chartFunctions-4d828b26.js} +2 -2
- package/dist/cjs/{functions-45f36418.js → functions-0c27162e.js} +38 -22
- package/dist/{esm/global-1dca883b.js → cjs/global-a2ca8069.js} +13 -3
- package/dist/cjs/{index-670c5d2a.js → index-fae02cd7.js} +386 -8
- package/dist/cjs/{intl-a84cd5ef.js → intl-022a42a1.js} +1 -1
- package/dist/cjs/loader.cjs.js +3 -3
- package/dist/cjs/priv-chart-popover.cjs.entry.js +2 -2
- package/dist/cjs/priv-datepicker.cjs.entry.js +2 -2
- package/dist/cjs/priv-navigator-button.cjs.entry.js +1 -1
- package/dist/cjs/priv-navigator-item.cjs.entry.js +1 -1
- package/dist/cjs/ripple.cjs.js +3 -3
- package/dist/cjs/wm-action-menu_2.cjs.entry.js +2 -2
- package/dist/cjs/wm-button.cjs.entry.js +2 -2
- package/dist/cjs/wm-chart-slice.cjs.entry.js +1 -1
- package/dist/cjs/wm-chart.cjs.entry.js +4 -4
- package/dist/cjs/wm-datepicker.cjs.entry.js +2 -2
- package/dist/cjs/wm-file-list.cjs.entry.js +1 -1
- package/dist/cjs/wm-file.cjs.entry.js +2 -2
- package/dist/cjs/wm-input.cjs.entry.js +3 -3
- package/dist/cjs/wm-line-chart.cjs.entry.js +4 -4
- package/dist/cjs/wm-modal-footer.cjs.entry.js +13 -16
- package/dist/cjs/wm-modal-header.cjs.entry.js +8 -18
- package/dist/cjs/wm-modal.cjs.entry.js +27 -58
- package/dist/cjs/wm-navigation_3.cjs.entry.js +3 -3
- package/dist/cjs/wm-navigator.cjs.entry.js +2 -2
- package/dist/cjs/wm-network-uploader.cjs.entry.js +3 -3
- package/dist/cjs/wm-option_2.cjs.entry.js +3 -3
- package/dist/cjs/wm-pagination.cjs.entry.js +2 -2
- package/dist/cjs/wm-progress-indicator_3.cjs.entry.js +3 -3
- package/dist/cjs/wm-search.cjs.entry.js +3 -3
- package/dist/cjs/wm-snackbar.cjs.entry.js +3 -3
- package/dist/cjs/wm-tab-item_3.cjs.entry.js +2 -2
- package/dist/cjs/wm-tag-input-row.cjs.entry.js +1 -1
- package/dist/cjs/wm-tag-input.cjs.entry.js +3 -3
- package/dist/cjs/wm-timepicker.cjs.entry.js +2 -2
- package/dist/cjs/wm-toggletip.cjs.entry.js +2 -2
- package/dist/cjs/wm-uploader.cjs.entry.js +3 -3
- package/dist/cjs/wm-wrapper.cjs.entry.js +1 -1
- package/dist/collection/components/wm-modal/wm-modal-footer.css +1 -1
- package/dist/collection/components/wm-modal/wm-modal-footer.js +11 -14
- package/dist/collection/components/wm-modal/wm-modal-header.css +1 -1
- package/dist/collection/components/wm-modal/wm-modal-header.js +4 -14
- package/dist/collection/components/wm-modal/wm-modal.css +27 -65
- package/dist/collection/components/wm-modal/wm-modal.js +24 -71
- package/dist/collection/components/wm-modal/wm-modal.spec.js +0 -28
- package/dist/collection/global/functions.js +38 -22
- package/dist/collection/global/global.js +10 -2
- package/dist/esm/{chartFunctions-e539d991.js → chartFunctions-f4f3252e.js} +2 -2
- package/dist/esm/{functions-7fc7cf30.js → functions-d52b728c.js} +39 -23
- package/dist/{cjs/global-c795cff3.js → esm/global-06801d00.js} +11 -5
- package/dist/esm/{index-294d486f.js → index-7e11ea42.js} +386 -8
- package/dist/esm/{intl-f0475a8e.js → intl-9809c77c.js} +1 -1
- package/dist/esm/loader.js +4 -4
- 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 +2 -2
- package/dist/esm/priv-datepicker.entry.js +2 -2
- package/dist/esm/priv-navigator-button.entry.js +1 -1
- package/dist/esm/priv-navigator-item.entry.js +1 -1
- package/dist/esm/ripple.js +4 -4
- package/dist/esm/wm-action-menu_2.entry.js +2 -2
- package/dist/esm/wm-button.entry.js +2 -2
- package/dist/esm/wm-chart-slice.entry.js +1 -1
- package/dist/esm/wm-chart.entry.js +4 -4
- package/dist/esm/wm-datepicker.entry.js +2 -2
- package/dist/esm/wm-file-list.entry.js +1 -1
- package/dist/esm/wm-file.entry.js +2 -2
- package/dist/esm/wm-input.entry.js +3 -3
- package/dist/esm/wm-line-chart.entry.js +4 -4
- package/dist/esm/wm-modal-footer.entry.js +13 -16
- package/dist/esm/wm-modal-header.entry.js +8 -18
- package/dist/esm/wm-modal.entry.js +27 -58
- package/dist/esm/wm-navigation_3.entry.js +3 -3
- package/dist/esm/wm-navigator.entry.js +2 -2
- package/dist/esm/wm-network-uploader.entry.js +3 -3
- package/dist/esm/wm-option_2.entry.js +3 -3
- package/dist/esm/wm-pagination.entry.js +2 -2
- package/dist/esm/wm-progress-indicator_3.entry.js +3 -3
- package/dist/esm/wm-search.entry.js +3 -3
- package/dist/esm/wm-snackbar.entry.js +3 -3
- package/dist/esm/wm-tab-item_3.entry.js +2 -2
- package/dist/esm/wm-tag-input-row.entry.js +1 -1
- package/dist/esm/wm-tag-input.entry.js +3 -3
- package/dist/esm/wm-timepicker.entry.js +2 -2
- package/dist/esm/wm-toggletip.entry.js +2 -2
- package/dist/esm/wm-uploader.entry.js +3 -3
- package/dist/esm/wm-wrapper.entry.js +1 -1
- package/dist/esm-es5/{chartFunctions-e539d991.js → chartFunctions-f4f3252e.js} +1 -1
- package/dist/esm-es5/{functions-7fc7cf30.js → functions-d52b728c.js} +1 -1
- package/dist/esm-es5/{global-1dca883b.js → global-06801d00.js} +1 -1
- package/dist/esm-es5/index-7e11ea42.js +2 -0
- package/dist/esm-es5/{intl-f0475a8e.js → intl-9809c77c.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/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-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-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-row.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/esm-es5/wm-wrapper.entry.js +1 -1
- package/dist/ripple/p-0631be01.system.entry.js +1 -0
- package/dist/ripple/{p-a6317ac6.entry.js → p-06871476.entry.js} +1 -1
- package/dist/ripple/{p-5e109597.entry.js → p-0d9f70ab.entry.js} +1 -1
- package/dist/ripple/{p-6639cf6c.entry.js → p-11763c02.entry.js} +1 -1
- package/dist/ripple/p-185c3645.entry.js +1 -0
- package/dist/ripple/{p-42cd9ae6.entry.js → p-19773c40.entry.js} +1 -1
- package/dist/ripple/{p-69c802aa.entry.js → p-198f596b.entry.js} +1 -1
- package/dist/ripple/{p-2bbf689a.system.entry.js → p-20df08be.system.entry.js} +1 -1
- package/dist/ripple/p-24d9f6fe.entry.js +1 -0
- package/dist/ripple/p-25c1bd67.system.entry.js +1 -0
- package/dist/ripple/{p-77ea81c7.system.entry.js → p-26031cd0.system.entry.js} +1 -1
- package/dist/ripple/{p-936e078c.system.js → p-27efb4d0.system.js} +1 -1
- package/dist/ripple/{p-766a4a70.system.entry.js → p-2acf8af1.system.entry.js} +1 -1
- package/dist/ripple/{p-1cb7bdc5.entry.js → p-2ebac749.entry.js} +1 -1
- package/dist/ripple/p-30bf24f8.system.js +2 -0
- package/dist/ripple/{p-bde26da9.system.entry.js → p-3248c0fa.system.entry.js} +1 -1
- package/dist/ripple/p-364753eb.js +1 -0
- package/dist/ripple/p-39e17683.system.js +1 -0
- package/dist/ripple/{p-935eafa7.system.entry.js → p-3b50511c.system.entry.js} +1 -1
- package/dist/ripple/p-3c80bf67.entry.js +1 -0
- package/dist/ripple/{p-6f36e973.entry.js → p-3ec4ae19.entry.js} +1 -1
- package/dist/ripple/p-42aeb9bb.js +1 -0
- package/dist/ripple/{p-5d78937a.entry.js → p-4b59b16a.entry.js} +1 -1
- package/dist/ripple/{p-770f02d4.entry.js → p-50623da2.entry.js} +1 -1
- package/dist/ripple/p-50be6128.system.entry.js +1 -0
- package/dist/ripple/{p-f3ff86da.entry.js → p-535e7286.entry.js} +1 -1
- package/dist/ripple/{p-cabf1867.system.entry.js → p-53f5e969.system.entry.js} +1 -1
- package/dist/ripple/{p-0412d22d.system.entry.js → p-56d64283.system.entry.js} +1 -1
- package/dist/ripple/{p-d9268ba1.system.entry.js → p-5c1b2132.system.entry.js} +1 -1
- package/dist/ripple/{p-29960160.system.entry.js → p-5d592297.system.entry.js} +1 -1
- package/dist/ripple/{p-d4ebbe84.system.js → p-5e55eb56.system.js} +1 -1
- package/dist/ripple/{p-0872dd92.entry.js → p-697ba13b.entry.js} +1 -1
- package/dist/ripple/{p-b22858cd.entry.js → p-725c757a.entry.js} +1 -1
- package/dist/ripple/{p-24ac418e.system.entry.js → p-74a92541.system.entry.js} +1 -1
- package/dist/ripple/{p-fcbd4194.entry.js → p-7962f562.entry.js} +1 -1
- package/dist/ripple/{p-cd67e184.entry.js → p-7f722888.entry.js} +1 -1
- package/dist/ripple/{p-08e0007e.system.entry.js → p-80ca72ff.system.entry.js} +1 -1
- package/dist/ripple/{p-53b84f6d.entry.js → p-84e55d9e.entry.js} +1 -1
- package/dist/ripple/{p-0730d70d.system.entry.js → p-89bf36c8.system.entry.js} +1 -1
- package/dist/ripple/p-8ea68cb3.system.entry.js +1 -0
- package/dist/ripple/{p-7b91eba4.system.entry.js → p-8f273c5b.system.entry.js} +1 -1
- package/dist/ripple/{p-a7a9c931.entry.js → p-9cb8f41b.entry.js} +1 -1
- package/dist/ripple/{p-23a5adae.entry.js → p-9e29176c.entry.js} +1 -1
- package/dist/ripple/{p-6cc52a23.system.entry.js → p-a1e95b05.system.entry.js} +1 -1
- package/dist/ripple/{p-38b67301.entry.js → p-a52c5a1c.entry.js} +1 -1
- package/dist/ripple/{p-71ecba7e.system.entry.js → p-aae11e37.system.entry.js} +1 -1
- package/dist/ripple/{p-b111bc7d.entry.js → p-adf76148.entry.js} +1 -1
- package/dist/ripple/{p-765b53d8.system.entry.js → p-ae97bf6c.system.entry.js} +1 -1
- package/dist/ripple/p-b5bedd63.js +2 -0
- package/dist/ripple/{p-00850d97.entry.js → p-b982a342.entry.js} +1 -1
- package/dist/ripple/{p-e4f352fe.system.js → p-ba31d982.system.js} +1 -1
- package/dist/ripple/p-c1857a16.entry.js +1 -0
- package/dist/ripple/{p-d601c5a1.entry.js → p-c32d10f7.entry.js} +1 -1
- package/dist/ripple/{p-a9012b82.system.entry.js → p-c3915cfe.system.entry.js} +1 -1
- package/dist/ripple/{p-4d5e075b.system.entry.js → p-cab12cec.system.entry.js} +1 -1
- package/dist/ripple/{p-2b378ac6.js → p-cd7cc5c6.js} +1 -1
- package/dist/ripple/{p-0a846e45.entry.js → p-d72b00a0.entry.js} +1 -1
- package/dist/ripple/{p-f1aed810.system.entry.js → p-d8de670a.system.entry.js} +1 -1
- package/dist/ripple/{p-68f11410.entry.js → p-da01c531.entry.js} +1 -1
- package/dist/ripple/{p-4a58b0ff.system.entry.js → p-dd01929e.system.entry.js} +1 -1
- package/dist/ripple/{p-5da6b9ff.system.entry.js → p-e0f270e2.system.entry.js} +1 -1
- package/dist/ripple/{p-64abb6d9.system.entry.js → p-e882a31f.system.entry.js} +1 -1
- package/dist/ripple/{p-c459ef8e.entry.js → p-ec13e325.entry.js} +1 -1
- package/dist/ripple/{p-dc069d46.entry.js → p-ed3e41ed.entry.js} +1 -1
- package/dist/ripple/{p-458c1c0b.system.entry.js → p-f635c1ec.system.entry.js} +1 -1
- package/dist/ripple/{p-eb0d569a.system.entry.js → p-f865899a.system.entry.js} +1 -1
- package/dist/ripple/{p-fd0fc5e1.system.entry.js → p-f9539737.system.entry.js} +1 -1
- package/dist/ripple/{p-6628e036.system.entry.js → p-fbb44f76.system.entry.js} +1 -1
- package/dist/ripple/{p-74880dac.system.entry.js → p-fcdd9e03.system.entry.js} +1 -1
- package/dist/ripple/{p-1a7b1578.system.js → p-fd354e00.system.js} +1 -1
- package/dist/ripple/{p-6546dda7.entry.js → p-fd91cd58.entry.js} +1 -1
- package/dist/ripple/{p-f9e942f6.entry.js → p-fea4bc00.entry.js} +1 -1
- package/dist/ripple/{p-20495238.js → p-ff888d78.js} +1 -1
- package/dist/ripple/ripple.esm.js +1 -1
- package/dist/ripple/ripple.js +1 -1
- package/dist/types/components/wm-modal/wm-modal-footer.d.ts +0 -1
- package/dist/types/components/wm-modal/wm-modal-header.d.ts +0 -1
- package/dist/types/components/wm-modal/wm-modal.d.ts +4 -10
- package/package.json +1 -1
- package/dist/esm-es5/index-294d486f.js +0 -2
- package/dist/ripple/p-11b416c7.js +0 -2
- package/dist/ripple/p-16708229.js +0 -1
- package/dist/ripple/p-212d0c64.entry.js +0 -1
- package/dist/ripple/p-2b59a09f.entry.js +0 -1
- package/dist/ripple/p-4418858d.entry.js +0 -1
- package/dist/ripple/p-56747d40.system.entry.js +0 -1
- package/dist/ripple/p-5e005259.system.entry.js +0 -1
- package/dist/ripple/p-63466d04.entry.js +0 -1
- package/dist/ripple/p-89bc016a.js +0 -1
- package/dist/ripple/p-8a38e526.system.js +0 -1
- package/dist/ripple/p-8c6ffd70.system.entry.js +0 -1
- package/dist/ripple/p-c467a1e1.system.js +0 -2
- package/dist/ripple/p-c5942ad6.system.entry.js +0 -1
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const functions = require('./functions-
|
|
5
|
+
const index = require('./index-fae02cd7.js');
|
|
6
|
+
const functions = require('./functions-0c27162e.js');
|
|
7
7
|
|
|
8
8
|
const wmToggletipCss = ":host{--wmcolor-toggletip-background:var(--wmcolor-background-dark);--wmcolor-toggletip-icon-background:var(--wmcolor-background-dark);--wmcolor-toggletip-icon-text:var(--wmcolor-text-ondark);--wmcolor-toggletip-text:var(--wmcolor-text-ondark);display:inline-block;position:relative;height:40px;width:40px}:host .button{display:-ms-flexbox;display:flex;background:none;border:none;padding:0;width:inherit;height:inherit;border-radius:50%;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;position:relative;cursor:pointer}:host .button: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:\"\\f2fc\";font-size:16px;color:var(--wmcolor-toggletip-icon-background);background:radial-gradient(var(--wmcolor-toggletip-icon-text) 40%, transparent 0%)}:host .button:focus{outline:none}:host .button:focus.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 var(--wmcolor-interactive-focus);-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 var(--wmcolor-interactive-focus);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 var(--wmcolor-interactive-focus)}:host .button:focus.user-is-tabbing::-moz-focus-inner{border:0}:host .tooltip{position:absolute;opacity:0;width:1px;height:1px;overflow:hidden;clip:rect(0, 0, 0, 0);pointer-events:none;font-family:inherit;font-size:0.875rem;text-transform:none;font-weight:normal;background:var(--wmcolor-tooltip-background);color:var(--wmcolor-tooltip-text);padding:0.375rem;line-height:normal;z-index:30;white-space:nowrap}:host .tooltip.hover{clip:auto;width:auto;height:auto;opacity:1;-webkit-transition:opacity 500ms 500ms;transition:opacity 500ms 500ms;padding:0.375rem;white-space:nowrap}:host .toggletip{position:absolute;max-width:13.75rem;width:-webkit-max-content;width:-moz-max-content;width:max-content;padding:0.5rem 0.75rem;border-radius:0.1875rem;background:var(--wmcolor-toggletip-background);color:var(--wmcolor-toggletip-text);font-size:14px;z-index:30}:host .toggletip.top:before{content:\"\";position:absolute;border:solid transparent;height:0;width:0;pointer-events:none;top:100%;border-top-color:var(--wmcolor-toggletip-background);border-top-width:0.25rem;border-left-width:0.375rem;border-right-width:0.375rem;margin-left:-0.375rem;left:50%}:host .toggletip.bottom:before{content:\"\";position:absolute;border:solid transparent;height:0;width:0;pointer-events:none;bottom:100%;border-bottom-color:var(--wmcolor-toggletip-background);border-bottom-width:0.25rem;border-left-width:0.375rem;border-right-width:0.375rem;margin-left:-0.375rem;left:50%}:host .toggletip.right:before{content:\"\";position:absolute;border:solid transparent;height:0;width:0;pointer-events:none;bottom:100%;border-right-color:var(--wmcolor-toggletip-background);border-right-width:0.25rem;border-top-width:0.375rem;border-bottom-width:0.375rem;border-left-width:0px;top:calc(50% - 6px);left:-0.1875rem}:host .toggletip.left:before{content:\"\";position:absolute;border:solid transparent;height:0;width:0;pointer-events:none;bottom:100%;border-left-color:var(--wmcolor-toggletip-background);border-left-width:0.25rem;border-top-width:0.375rem;border-bottom-width:0.375rem;border-right-width:0px;top:calc(50% - 6px);right:-0.1875rem}:host .toggletip.bottom-right:before{content:\"\";position:absolute;border:solid transparent;height:0;width:0;pointer-events:none;bottom:100%;border-bottom-color:var(--wmcolor-toggletip-background);border-bottom-width:0.25rem;border-left-width:0.375rem;border-right-width:0.375rem;margin-left:-0.375rem;left:50%;margin-left:unset;left:0.875rem}:host .toggletip.bottom-left:before{content:\"\";position:absolute;border:solid transparent;height:0;width:0;pointer-events:none;bottom:100%;border-bottom-color:var(--wmcolor-toggletip-background);border-bottom-width:0.25rem;border-left-width:0.375rem;border-right-width:0.375rem;margin-left:-0.375rem;left:50%;left:unset;margin-left:unset;right:0.875rem}:host .toggletip.top-right:before{content:\"\";position:absolute;border:solid transparent;height:0;width:0;pointer-events:none;top:100%;border-top-color:var(--wmcolor-toggletip-background);border-top-width:0.25rem;border-left-width:0.375rem;border-right-width:0.375rem;margin-left:-0.375rem;left:50%;margin-left:unset;left:0.875rem}:host .toggletip.top-left:before{content:\"\";position:absolute;border:solid transparent;height:0;width:0;pointer-events:none;top:100%;border-top-color:var(--wmcolor-toggletip-background);border-top-width:0.25rem;border-left-width:0.375rem;border-right-width:0.375rem;margin-left:-0.375rem;left:50%;left:unset;margin-left:unset;right:0.875rem}:host .toggletip.hidden{-webkit-transform:scale(0, 0) !important;transform:scale(0, 0) !important;visibility:hidden}:host .toggletip.top,:host .tooltip.top{-webkit-transform:translate(-50%, 0%);transform:translate(-50%, 0%);bottom:40px;left:20px}:host .toggletip.bottom,:host .tooltip.bottom{-webkit-transform:translate(-50%, 0%);transform:translate(-50%, 0%);top:40px;left:20px}:host .toggletip.right,:host .tooltip.right{-webkit-transform:translate(100%, calc(-50% - 20px));transform:translate(100%, calc(-50% - 20px));right:0px}:host .toggletip.left,:host .tooltip.left{-webkit-transform:translate(-100%, calc(-50% - 20px));transform:translate(-100%, calc(-50% - 20px));left:0px}:host .toggletip.bottom-right,:host .tooltip.bottom-right{top:40px;left:0px}:host .toggletip.bottom-left,:host .tooltip.bottom-left{top:40px;right:0px}:host .toggletip.top-right,:host .tooltip.top-right{bottom:40px;left:0px}:host .toggletip.top-left,:host .tooltip.top-left{bottom:40px;right:0px}: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}";
|
|
9
9
|
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const functions = require('./functions-
|
|
7
|
-
const intl = require('./intl-
|
|
5
|
+
const index = require('./index-fae02cd7.js');
|
|
6
|
+
const functions = require('./functions-0c27162e.js');
|
|
7
|
+
const intl = require('./intl-022a42a1.js');
|
|
8
8
|
|
|
9
9
|
const wmUploaderCss = ":host .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 transparent;font-family:inherit;font-size:0.75rem;font-weight:700;min-height:2.75rem;padding:12px 1.3333333333em;cursor:pointer;position:relative;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;box-shadow:none}@media screen and (min-width: 48rem){:host .wm-button{min-height:3.3333333333em}}:host .wm-button.nowrap{display:inline-block;width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host .wm-button:focus{outline:none;-webkit-box-shadow:none;box-shadow:none}:host .wm-button::-moz-focus-inner{border:0;outline:none}:host .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 var(--wmcolor-interactive-focus);-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 var(--wmcolor-interactive-focus);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 var(--wmcolor-interactive-focus)}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark)::-moz-focus-inner{border:0}:host .wm-button.dark.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled).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 var(--wmcolor-interactive-focus-ondark);-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 var(--wmcolor-interactive-focus-ondark);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 var(--wmcolor-interactive-focus-ondark);outline:none}:host .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{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{margin-right:0.3125rem;font-size:0.875rem}:host .wm-button[dir=RTL] :not(.-icononly) .mdi{margin-left:0.3125rem;margin-right:0}:host .wm-button.-primary:not(.-textonly){background:var(--wmcolor-button-background-primary);color:var(--wmcolor-button-text-primary)}:host .wm-button.-primary:not(.-textonly):not(:focus){-webkit-box-shadow:0 0 4px 0 rgba(0, 0, 0, 0.14), 0 3px 4px 0 rgba(0, 0, 0, 0.12), 0 1px 5px 0 rgba(0, 0, 0, 0.2);box-shadow:0 0 4px 0 rgba(0, 0, 0, 0.14), 0 3px 4px 0 rgba(0, 0, 0, 0.12), 0 1px 5px 0 rgba(0, 0, 0, 0.2)}:host .wm-button.-primary:not(.-textonly):hover:not(:disabled):not(.disabled){background:var(--wmcolor-button-background-primary-hover)}:host .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled){color:var(--wmcolor-button-text-primary-ondark);background:var(--wmcolor-button-background-primary-ondark)}:host .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled):hover{background:var(--wmcolor-button-background-primary-hover-ondark)}:host .wm-button.-secondary{color:var(--wmcolor-button-text-secondary);border:2px solid var(--wmcolor-button-border-secondary);background:var(--wmcolor-button-background-secondary)}:host .wm-button.-secondary:hover:not(:disabled):not(.disabled){background:var(--wmcolor-button-background-secondary-hover);color:var(--wmcolor-button-text-secondary-hover);border-color:transparent}:host .wm-button.-secondary.dark:not(:disabled):not(.disabled){color:var(--wmcolor-button-text-secondary-ondark);background:var(--wmcolor-button-background-secondary-ondark);border-color:var(--wmcolor-button-border-secondary-ondark)}:host .wm-button.-secondary.dark:not(:disabled):not(.disabled):hover{color:var(--wmcolor-button-text-secondary-hover-ondark);background:var(--wmcolor-button-background-secondary-hover-ondark);border-color:transparent}:host .wm-button.-textonly{color:var(--wmcolor-button-text-textonly);-webkit-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{margin-left:0.3125rem}:host .wm-button.-textonly:focus{outline:none}:host .wm-button.-textonly::-moz-focus-inner{border:0;outline:none}:host .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled) .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, var(--wmcolor-interactive-focus-textonly)), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, var(--wmcolor-interactive-focus-textonly) 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{background:-webkit-gradient(linear, left top, right top, color-stop(66%, var(--wmcolor-interactive-focus-textonly-ondark)), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, var(--wmcolor-interactive-focus-textonly-ondark) 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.-textonly.small{font-size:0.625rem}:host .wm-button.-textonly:hover:not(:disabled):not(.disabled):not(.-permanentlydelete){text-decoration:underline}:host .wm-button.-textonly.dark{color:var(--wmcolor-button-text-textonly-ondark)}:host .wm-button.-textonly.dark:hover:not(:disabled):not(.disabled){text-decoration:underline}:host .wm-button.-textonly.-permanentlydelete{color:var(--wmcolor-button-background-delete)}:host .wm-button.-textonly.-permanentlydelete:hover:not(:disabled):not(.disabled):not(.dark){text-decoration:underline}:host .wm-button.-textonly.-permanentlydelete.dark:not(:disabled):not(.disabled){color:var(--wmcolor-button-text-textonly-ondark)}:host .wm-button.-icononly,:host .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),:host .wm-button.-navigational:not(:focus){-webkit-box-shadow:none;box-shadow:none}@media screen and (min-width: 48rem){:host .wm-button.-icononly,:host .wm-button.-navigational{min-width:2.5rem;min-height:2.5rem}}:host .wm-button.-icononly .mdi,:host .wm-button.-navigational .mdi{font-size:1.12rem}:host .wm-button.-icononly{border-width:1px !important;color:var(--wmcolor-button-icon-icononly);border-color:var(--wmcolor-button-border-icononly);background-color:var(--wmcolor-button-background-icononly)}:host .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.-icononly:hover:not(:disabled):not(.disabled){background:var(--wmcolor-button-background-icononly-hover);color:var(--wmcolor-button-icon-icononly-hover);border-color:transparent}:host .wm-button.-icononly.dark:not(:disabled):not(.disabled){color:var(--wmcolor-button-icon-icononly-ondark);background:var(--wmcolor-button-background-icononly-ondark);border-color:var(--wmcolor-button-border-icononly-ondark)}:host .wm-button.-icononly.dark:not(:disabled):not(.disabled):hover{color:var(--wmcolor-button-icon-icononly-hover-ondark);background:var(--wmcolor-button-background-icononly-hover-ondark);border-color:transparent}:host .wm-button.-navigational{border:none !important;background-color:var(--wmcolor-button-background-navigational)}:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled){color:var(--wmcolor-button-icon-navigational)}:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled):hover,:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled).selected{background-color:var(--wmcolor-button-background-navigational-hover)}:host .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.-navigational.dark:not(:disabled):not(.disabled){color:var(--wmcolor-button-icon-navigational-ondark);background:var(--wmcolor-button-background-navigational-ondark)}:host .wm-button.-navigational.dark:not(:disabled):not(.disabled):hover{color:var(--wmcolor-button-icon-navigational-hover-ondark);background:var(--wmcolor-button-background-navigational-hover-ondark)}:host .wm-button.-permanentlydelete:not(.-textonly){background:var(--wmcolor-button-background-delete);border-color:var(--wmcolor-button-background-delete);color:var(--wmcolor-button-text-delete)}:host .wm-button.-permanentlydelete:not(.-textonly):hover:not(:disabled):not(.disabled):not(.dark){background:var(--wmcolor-button-background-delete-hover);border-color:var(--wmcolor-button-background-delete-hover)}:host .wm-button.-permanentlydelete:not(.-textonly).dark:not(:disabled):not(.disabled){background:var(--wmcolor-button-background-delete);border-color:var(--wmcolor-button-background-delete);color:var(--wmcolor-button-text-delete)}:host .wm-button.-permanentlydelete:not(.-textonly).dark:not(:disabled):not(.disabled):hover{background:var(--wmcolor-button-background-delete-hover);border-color:var(--wmcolor-button-background-delete-hover)}:host .wm-button.-pairnegative{background:var(--wmcolor-button-background-negative);border-color:var(--wmcolor-button-background-negative);color:var(--wmcolor-button-text-negative)}:host .wm-button.-pairnegative:hover:not(:disabled):not(.disabled){background:var(--wmcolor-button-background-negative-hover);border-color:var(--wmcolor-button-background-negative-hover)}:host .wm-button.-pairpositive{background:var(--wmcolor-button-background-positive);border-color:var(--wmcolor-button-background-positive);color:var(--wmcolor-button-text-positive)}:host .wm-button.-pairpositive:hover:not(:disabled):not(.disabled){background:var(--wmcolor-button-background-positive-hover);border-color:var(--wmcolor-button-background-positive-hover)}:host .wm-button.-selector,:host .wm-button.-selector-primary{-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;display:block;border-radius:3px;height:2.75rem;min-width:11.4375rem;padding:0 1.875rem 0 0.9375rem;line-height:normal;font-family:inherit;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,:host .wm-button.-selector-primary{height:2.5rem}}:host .wm-button.-selector:before,:host .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,:host .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,:host .wm-button.-selector-primary::-moz-focus-inner{border:0}:host .wm-button.-selector .overflowcontrol,:host .wm-button.-selector-primary .overflowcontrol{display:block;white-space:nowrap;text-overflow:ellipsis;overflow:visible}:host .wm-button.-selector{background:var(--wmcolor-button-background-selector);color:var(--wmcolor-button-text-selector);border-color:var(--wmcolor-button-border-selector)}:host .wm-button.-selector:hover:not(:disabled):not(.disabled){background:var(--wmcolor-button-background-selector-hover);color:var(--wmcolor-button-text-selector-hover);border-color:transparent}:host .wm-button.-selector.dark:not(:disabled):not(.disabled){color:var(--wmcolor-button-text-selector-ondark);border-color:var(--wmcolor-button-border-selector-ondark);background:var(--wmcolor-button-background-selector-ondark)}:host .wm-button.-selector.dark:not(:disabled):not(.disabled):hover{color:var(--wmcolor-button-text-selector-hover-ondark);background:var(--wmcolor-button-background-selector-hover-ondark);border-color:transparent}:host .wm-button.-selector-primary{background:var(--wmcolor-button-background-selectorprimary);color:var(--wmcolor-button-text-selectorprimary)}:host .wm-button.-selector-primary:hover:not(:disabled):not(.disabled){background:var(--wmcolor-button-background-selectorprimary-hover)}:host .wm-button.-selector-primary.dark:not(:disabled):not(.disabled){color:var(--wmcolor-button-text-selectorprimary-ondark);background:var(--wmcolor-button-background-selectorprimary-ondark)}:host .wm-button.-selector-primary.dark:not(:disabled):not(.disabled):hover{color:var(--wmcolor-button-text-selectorprimary-hover-ondark);background:var(--wmcolor-button-background-selectorprimary-hover-ondark)}:host .wm-button:disabled,:host .wm-button.disabled{cursor:default;pointer-events:none}:host .wm-button:disabled.-secondary:not(.-permanentlydelete),:host .wm-button.disabled.-secondary:not(.-permanentlydelete){-webkit-box-shadow:none;box-shadow:none;border-color:var(--wmcolor-button-border-secondary-disabled);color:var(--wmcolor-button-text-secondary-disabled)}:host .wm-button:disabled.-primary,:host .wm-button.disabled.-primary{background:var(--wmcolor-button-background-primary-disabled);color:var(--wmcolor-button-text-primary-disabled)}:host .wm-button:disabled.-permanentlydelete,:host .wm-button.disabled.-permanentlydelete{background:var(--wmcolor-button-background-delete-disabled);color:var(--wmcolor-button-text-delete-disabled);border-color:var(--wmcolor-button-background-delete-disabled)}:host .wm-button:disabled.-pairnegative,:host .wm-button.disabled.-pairnegative{background:var(--wmcolor-button-background-negative-disabled);border-color:var(--wmcolor-button-background-negative-disabled);color:var(--wmcolor-button-text-negative-disabled)}:host .wm-button:disabled.-pairpositive,:host .wm-button.disabled.-pairpositive{background:var(--wmcolor-button-background-positive-disabled);border-color:var(--wmcolor-button-background-positive-disabled);color:var(--wmcolor-button-text-positive-disabled)}:host .wm-button:disabled.-selector,:host .wm-button.disabled.-selector{color:var(--wmcolor-button-text-selector-disabled);border-color:var(--wmcolor-button-border-selector-disabled)}:host .wm-button:disabled.-selector-primary,:host .wm-button.disabled.-selector-primary{background:var(--wmcolor-button-background-selectorprimary-disabled);color:var(--wmcolor-button-text-selectorprimary-disabled)}:host .wm-button:disabled.-navigational,:host .wm-button.disabled.-navigational{color:var(--wmcolor-button-icon-navigational-disabled)}:host .wm-button:disabled.-icononly,:host .wm-button.disabled.-icononly{color:var(--wmcolor-button-icon-icononly-disabled);border-color:var(--wmcolor-button-border-icononly-disabled)}:host .wm-button:disabled.-textonly,:host .wm-button.disabled.-textonly{color:var(--wmcolor-button-text-textonly-disabled);background:transparent}:host .wm-button:disabled.dark.-icononly,:host .wm-button.disabled.dark.-icononly{background:transparent;color:var(--wmcolor-button-icon-icononly-disabled-ondark);border-color:var(--wmcolor-button-border-icononly-disabled-ondark)}:host .wm-button:disabled.dark.-navigational,:host .wm-button.disabled.dark.-navigational{color:var(--wmcolor-button-icon-navigational-disabled-ondark)}:host .wm-button:disabled.dark.-textonly,:host .wm-button.disabled.dark.-textonly{color:var(--wmcolor-button-text-textonly-disabled-ondark)}:host .wm-button:disabled.dark.-primary,:host .wm-button.disabled.dark.-primary{color:var(--wmcolor-button-text-primary-disabled-ondark);background:var(--wmcolor-button-background-primary-disabled-ondark)}:host .wm-button:disabled.dark.-secondary,:host .wm-button.disabled.dark.-secondary{background:transparent;color:var(--wmcolor-button-text-secondary-disabled-ondark);border-color:var(--wmcolor-button-border-secondary-disabled-ondark)}:host .wm-button:disabled.dark.-selector,:host .wm-button.disabled.dark.-selector{color:var(--wmcolor-button-text-selector-disabled-ondark);border-color:var(--wmcolor-button-border-selector-disabled-ondark);background:var(--wmcolor-button-background-selector-disabled-ondark)}:host .wm-button:disabled.dark.-selector-primary,:host .wm-button.disabled.dark.-selector-primary{color:var(--wmcolor-button-text-selectorprimary-disabled-ondark);background:var(--wmcolor-button-background-selectorprimary-disabled-ondark)}:host .wm-button:disabled.dark.-permanentlydelete:not(.-textonly),:host .wm-button.disabled.dark.-permanentlydelete:not(.-textonly){background:var(--wmcolor-button-background-delete-disabled-ondark);color:var(--wmcolor-button-text-delete-disabled-ondark)}:host a.wm-button,:host label.wm-button{height:auto;padding-top:0.75rem;padding-bottom:0.75rem}:host{--wmcolor-uploader-button-focus:var(--wmcolor-interactive-focus);display:block;position:relative;max-width:1140px}:host[dir=RTL] .mdi{margin-left:0.3125rem;margin-right:0}:host 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 var(--wmcolor-uploader-button-focus) !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 var(--wmcolor-uploader-button-focus) !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 var(--wmcolor-uploader-button-focus) !important}:host *{-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:var(--wmcolor-text-required)}.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:var(--wmcolor-text-error)}.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:var(--wmcolor-text-error);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}";
|
|
10
10
|
|
|
@@ -30,11 +30,11 @@
|
|
|
30
30
|
(they can't be aligned on the baseline because of possible description text and error message)
|
|
31
31
|
-------------------------------------- */
|
|
32
32
|
wm-modal-footer {
|
|
33
|
+
display: block;
|
|
33
34
|
-webkit-border-radius: 0px 0px 5px 5px;
|
|
34
35
|
-moz-border-radius: 0px 0px 5px 5px;
|
|
35
36
|
-ms-border-radius: 0px 0px 5px 5px;
|
|
36
37
|
border-radius: 0px 0px 5px 5px;
|
|
37
|
-
margin-top: -1px;
|
|
38
38
|
}
|
|
39
39
|
wm-modal-footer .wm-wrapper {
|
|
40
40
|
display: -webkit-box;
|
|
@@ -8,26 +8,23 @@ export class ModalFooter {
|
|
|
8
8
|
this.deleteStyle = false;
|
|
9
9
|
}
|
|
10
10
|
componentWillLoad() {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
// NB @Listen doesn't allow to listen on a specific element (the parent modal)
|
|
14
|
-
// if we listen to the whole doc each modal on the page reacts to every event
|
|
15
|
-
this.el.parentElement.addEventListener("focusLastElement", () => {
|
|
16
|
-
this.lastElement.focus();
|
|
17
|
-
});
|
|
11
|
+
const parentModal = this.el.closest("wm-modal");
|
|
12
|
+
this.uid = parentModal.uid;
|
|
18
13
|
}
|
|
19
14
|
emitParentPrimaryEvent() {
|
|
20
|
-
const parentModal = this.el.
|
|
21
|
-
|
|
22
|
-
|
|
15
|
+
const parentModal = this.el.closest("wm-modal");
|
|
16
|
+
if (parentModal) {
|
|
17
|
+
parentModal.emitPrimaryEvent();
|
|
18
|
+
}
|
|
23
19
|
}
|
|
24
20
|
emitParentSecondaryEvent() {
|
|
25
|
-
const parentModal = this.el.
|
|
26
|
-
|
|
27
|
-
|
|
21
|
+
const parentModal = this.el.closest("wm-modal");
|
|
22
|
+
if (parentModal) {
|
|
23
|
+
parentModal.emitSecondaryEvent();
|
|
24
|
+
}
|
|
28
25
|
}
|
|
29
26
|
render() {
|
|
30
|
-
return (h("div", { class: `wm-wrapper ${this.infoText ? " footer-text" : ""}` }, h("div", { class: "wm-info", "aria-live": "polite" }, this.infoText), h("div", { class: "wm-button-collection" }, this.secondaryText && (h("wm-button", { onClick: () => this.emitParentSecondaryEvent(), id: `wm-secondary-${this.uid}
|
|
27
|
+
return (h("div", { class: `wm-wrapper ${this.infoText ? " footer-text" : ""}` }, h("div", { class: "wm-info", "aria-live": "polite" }, this.infoText), h("div", { class: "wm-button-collection" }, this.secondaryText && (h("wm-button", { onClick: () => this.emitParentSecondaryEvent(), id: `wm-secondary-${this.uid}` }, this.secondaryText)), h("wm-button", { "button-type": this.deleteStyle ? "secondary" : "primary", "permanently-delete": this.deleteStyle, onClick: () => this.emitParentPrimaryEvent(), disabled: this.primaryActionDisabled, id: `wm-primary-${this.uid}` }, this.primaryText))));
|
|
31
28
|
}
|
|
32
29
|
static get is() { return "wm-modal-footer"; }
|
|
33
30
|
static get originalStyleUrls() {
|
|
@@ -30,11 +30,11 @@
|
|
|
30
30
|
(they can't be aligned on the baseline because of possible description text and error message)
|
|
31
31
|
-------------------------------------- */
|
|
32
32
|
wm-modal-header {
|
|
33
|
+
display: block;
|
|
33
34
|
-webkit-border-radius: 5px 5px 0 0px;
|
|
34
35
|
-moz-border-radius: 5px 5px 0 0px;
|
|
35
36
|
-ms-border-radius: 5px 5px 0 0px;
|
|
36
37
|
border-radius: 5px 5px 0 0px;
|
|
37
|
-
margin-bottom: -1px;
|
|
38
38
|
}
|
|
39
39
|
wm-modal-header .wm-wrapper {
|
|
40
40
|
display: -webkit-box;
|
|
@@ -6,26 +6,16 @@ export class ModalHeader {
|
|
|
6
6
|
this.subheading = "";
|
|
7
7
|
}
|
|
8
8
|
componentWillLoad() {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
// NB @Listen doesn't allow to listen on a specific element (the parent modal)
|
|
12
|
-
// if we listen to the whole doc each modal on the page reacts to every event
|
|
13
|
-
this.el.parentElement.addEventListener("focusFirstElement", () => {
|
|
14
|
-
this.closeButtonEl.focus();
|
|
15
|
-
});
|
|
9
|
+
const parentModal = this.el.closest("wm-modal");
|
|
10
|
+
this.uid = parentModal.uid;
|
|
16
11
|
}
|
|
17
12
|
emitParentCloseEvent() {
|
|
18
|
-
const parentModal = this.el.
|
|
13
|
+
const parentModal = this.el.closest("wm-modal");
|
|
19
14
|
//@ts-ignore
|
|
20
15
|
parentModal.emitCloseEvent();
|
|
21
16
|
}
|
|
22
|
-
// @Listen("click")
|
|
23
|
-
// directFocusOnClick() {
|
|
24
|
-
// this.headingElement.tabIndex = 0;
|
|
25
|
-
// this.headingElement.focus();
|
|
26
|
-
// }
|
|
27
17
|
render() {
|
|
28
|
-
return (h(Host, null, h("div", { class: "wm-wrapper" }, h("div", null, h("h2", { class: "title", id: `wm-modal-heading-text-${this.uid}` }, this.heading, h("span", { class: "subtitle" }, this.subheading))), h("wm-button", { "button-type": "navigational", icon: "f156", tooltip: globalMessages.close, "tooltip-position": "left", id: `wm-modal-close-${this.uid}`,
|
|
18
|
+
return (h(Host, null, h("div", { class: "wm-wrapper" }, h("div", null, h("h2", { class: "title", id: `wm-modal-heading-text-${this.uid}` }, this.heading, h("span", { class: "subtitle" }, this.subheading))), h("wm-button", { "button-type": "navigational", icon: "f156", tooltip: globalMessages.close, "tooltip-position": "left", id: `wm-modal-close-${this.uid}`, onClick: () => this.emitParentCloseEvent() }))));
|
|
29
19
|
}
|
|
30
20
|
static get is() { return "wm-modal-header"; }
|
|
31
21
|
static get originalStyleUrls() {
|
|
@@ -34,103 +34,65 @@ wm-modal {
|
|
|
34
34
|
--wmcolor-modal-border: var(--wmcolor-border);
|
|
35
35
|
--wmcolor-modal-heading: var(--wmcolor-text);
|
|
36
36
|
--wmcolor-modal-overlay: var(--wmcolor-overlay);
|
|
37
|
-
display: -webkit-box;
|
|
38
|
-
display: -webkit-flex;
|
|
39
|
-
display: -ms-flexbox;
|
|
40
|
-
display: flex;
|
|
41
|
-
-webkit-box-pack: center;
|
|
42
|
-
-ms-flex-pack: center;
|
|
43
|
-
-webkit-justify-content: center;
|
|
44
|
-
justify-content: center;
|
|
45
|
-
-webkit-box-align: center;
|
|
46
|
-
-webkit-align-items: center;
|
|
47
|
-
-ms-flex-align: center;
|
|
48
|
-
align-items: center;
|
|
49
|
-
flex-direction: column;
|
|
50
|
-
position: fixed;
|
|
51
|
-
top: 50%;
|
|
52
|
-
left: 50%;
|
|
53
|
-
transform: translate(-50%, -50%);
|
|
54
|
-
z-index: 2001;
|
|
55
|
-
width: 80vw;
|
|
56
|
-
max-width: 750px;
|
|
57
|
-
max-height: 80vh;
|
|
58
|
-
-webkit-box-shadow: 0px 11px 15px 0px rgba(0, 0, 0, 0.2), 0px 9px 46px 8px rgba(0, 0, 0, 0.12), 0px 24px 38px 3px rgba(0, 0, 0, 0.14);
|
|
59
|
-
-moz-box-shadow: 0px 11px 15px 0px rgba(0, 0, 0, 0.2), 0px 9px 46px 8px rgba(0, 0, 0, 0.12), 0px 24px 38px 3px rgba(0, 0, 0, 0.14);
|
|
60
|
-
box-shadow: 0px 11px 15px 0px rgba(0, 0, 0, 0.2), 0px 9px 46px 8px rgba(0, 0, 0, 0.12), 0px 24px 38px 3px rgba(0, 0, 0, 0.14);
|
|
61
37
|
}
|
|
62
38
|
wm-modal * {
|
|
63
39
|
box-sizing: border-box;
|
|
64
40
|
}
|
|
65
|
-
wm-modal
|
|
41
|
+
wm-modal dialog {
|
|
42
|
+
overflow: hidden;
|
|
43
|
+
padding: 0;
|
|
66
44
|
width: 80vw;
|
|
67
45
|
max-width: 750px;
|
|
46
|
+
max-height: 80vh;
|
|
47
|
+
-webkit-border-radius: 5px 5px 5px 5px;
|
|
48
|
+
-moz-border-radius: 5px 5px 5px 5px;
|
|
49
|
+
-ms-border-radius: 5px 5px 5px 5px;
|
|
50
|
+
border-radius: 5px 5px 5px 5px;
|
|
51
|
+
border: none;
|
|
68
52
|
background: var(--wmcolor-modal-background);
|
|
69
53
|
}
|
|
70
|
-
wm-modal >
|
|
71
|
-
|
|
72
|
-
}
|
|
73
|
-
wm-modal wm-modal-header,
|
|
74
|
-
wm-modal wm-modal-footer {
|
|
75
|
-
padding: 1.25rem 1.875rem;
|
|
76
|
-
}
|
|
77
|
-
wm-modal wm-modal-header {
|
|
78
|
-
z-index: 2003;
|
|
54
|
+
wm-modal dialog > :not(wm-modal-header):not(wm-modal-footer) {
|
|
55
|
+
max-height: calc(80vh - 166px);
|
|
79
56
|
}
|
|
80
|
-
wm-modal
|
|
81
|
-
|
|
57
|
+
wm-modal dialog::backdrop {
|
|
58
|
+
background: rgba(25, 25, 25, 0.4);
|
|
82
59
|
}
|
|
83
|
-
wm-modal
|
|
84
|
-
|
|
85
|
-
|
|
60
|
+
wm-modal dialog[open] {
|
|
61
|
+
-webkit-box-shadow: 0px 11px 15px 0px rgba(0, 0, 0, 0.2), 0px 9px 46px 8px rgba(0, 0, 0, 0.12), 0px 24px 38px 3px rgba(0, 0, 0, 0.14);
|
|
62
|
+
-moz-box-shadow: 0px 11px 15px 0px rgba(0, 0, 0, 0.2), 0px 9px 46px 8px rgba(0, 0, 0, 0.12), 0px 24px 38px 3px rgba(0, 0, 0, 0.14);
|
|
63
|
+
box-shadow: 0px 11px 15px 0px rgba(0, 0, 0, 0.2), 0px 9px 46px 8px rgba(0, 0, 0, 0.12), 0px 24px 38px 3px rgba(0, 0, 0, 0.14);
|
|
86
64
|
}
|
|
87
|
-
wm-modal.wm-modal wm-modal-header {
|
|
65
|
+
wm-modal dialog.wm-modal > wm-modal-header {
|
|
88
66
|
border-bottom: 1px solid var(--wmcolor-modal-border);
|
|
89
67
|
}
|
|
90
|
-
wm-modal.wm-modal wm-modal-footer {
|
|
68
|
+
wm-modal dialog.wm-modal > wm-modal-footer {
|
|
91
69
|
border-top: 1px solid var(--wmcolor-modal-border);
|
|
92
70
|
}
|
|
93
71
|
@media only screen and (max-width: 768px) {
|
|
94
|
-
wm-modal.wm-modal {
|
|
72
|
+
wm-modal dialog.wm-modal {
|
|
95
73
|
height: 100%;
|
|
96
74
|
max-height: none;
|
|
97
75
|
max-width: none;
|
|
98
76
|
width: 100vw;
|
|
99
77
|
}
|
|
100
|
-
wm-modal.wm-modal > * {
|
|
78
|
+
wm-modal dialog.wm-modal > * {
|
|
101
79
|
max-width: none;
|
|
102
80
|
width: 100vw;
|
|
103
81
|
}
|
|
104
|
-
wm-modal.wm-modal > *:not(wm-modal-header):not(wm-modal-footer) {
|
|
82
|
+
wm-modal dialog.wm-modal > *:not(wm-modal-header):not(wm-modal-footer) {
|
|
105
83
|
max-height: none;
|
|
106
84
|
height: calc(100vh - 166px);
|
|
107
85
|
}
|
|
108
86
|
}
|
|
109
|
-
wm-modal.wm-dialog > :not(wm-modal-header):not(wm-modal-footer) {
|
|
87
|
+
wm-modal dialog.wm-dialog > :not(wm-modal-header):not(wm-modal-footer):not(.wm-tooltip) {
|
|
110
88
|
padding: 0 1.875rem 1.25rem 1.875rem;
|
|
111
89
|
font-size: 0.875rem;
|
|
112
90
|
border: none;
|
|
113
91
|
}
|
|
114
|
-
wm-modal
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
max-height: none;
|
|
119
|
-
position: fixed !important;
|
|
120
|
-
top: -1;
|
|
121
|
-
bottom: 1;
|
|
122
|
-
left: -1;
|
|
123
|
-
right: 1;
|
|
124
|
-
transform: translate(0%, 0%);
|
|
125
|
-
background-color: var(--wmcolor-modal-overlay);
|
|
126
|
-
-ms-transition: opacity 0.5s ease-out;
|
|
127
|
-
-webkit-transition: opacity 0.5s ease-out;
|
|
128
|
-
-moz-transition: opacity 0.5s ease-out;
|
|
129
|
-
transition: opacity 0.5s ease-out;
|
|
130
|
-
z-index: 2000;
|
|
131
|
-
}
|
|
132
|
-
wm-modal.hide {
|
|
133
|
-
visibility: hidden;
|
|
92
|
+
wm-modal wm-modal-header,
|
|
93
|
+
wm-modal wm-modal-footer {
|
|
94
|
+
padding: 1.25rem 1.875rem;
|
|
95
|
+
width: 100%;
|
|
134
96
|
}
|
|
135
97
|
wm-modal .sr-only {
|
|
136
98
|
position: absolute !important;
|
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
import { h
|
|
2
|
-
import { checkForActiveElInShadow } from "../../global/functions";
|
|
1
|
+
import { h } from "@stencil/core";
|
|
3
2
|
import { generateId } from "../../global/functions";
|
|
4
3
|
export class Modal {
|
|
5
4
|
constructor() {
|
|
6
|
-
this.bodyFocusListener = () => this.redirectFocusFromBody();
|
|
7
5
|
this.open = false;
|
|
8
6
|
this.isOpen = false;
|
|
9
7
|
this.elementToFocus = "";
|
|
@@ -28,50 +26,31 @@ export class Modal {
|
|
|
28
26
|
!customElementToFocus &&
|
|
29
27
|
console.warn("Ripple Component Library: The modal component couldn't find an element matching the id you passed for 'elementToFocus'. It will fall back to the default and focus the close button when the modal opens.");
|
|
30
28
|
}
|
|
31
|
-
|
|
32
|
-
|
|
29
|
+
return customElementToFocus;
|
|
30
|
+
}
|
|
31
|
+
get hasBrowserPopoverSupport() {
|
|
32
|
+
// for browsers without popover support, render an additional tooltip in the top-layer so that it can be displayed above the dialog element
|
|
33
|
+
const tooltipEl = document.getElementById("wm-tooltip");
|
|
34
|
+
//@ts-ignore
|
|
35
|
+
return tooltipEl ? !!tooltipEl.showPopover : false;
|
|
33
36
|
}
|
|
34
|
-
//App can open modal by toggling the prop
|
|
35
37
|
toggleModal() {
|
|
36
38
|
this.tempOpen ? this.showModal() : this.hideModal();
|
|
37
39
|
}
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
// @Listen("wmShowModal", { target: "window" })
|
|
41
|
-
// doesEventMatchId(ev: CustomEvent) {
|
|
42
|
-
// ev.detail === this.uid && this.showModal();
|
|
43
|
-
// }
|
|
44
|
-
handleClick(ev) {
|
|
45
|
-
this.tempOpen && ev.target === this.overlayEl && this.focusOnOpenEl.focus();
|
|
46
|
-
}
|
|
47
|
-
closeModalOnEscape(ev) {
|
|
48
|
-
if (ev.key === "Escape") {
|
|
49
|
-
// stops propagation prevents nested modal from closing all at once
|
|
50
|
-
ev.stopPropagation();
|
|
51
|
-
this.wmModalCloseTriggered.emit();
|
|
52
|
-
this.wmCloseTriggered.emit(); // deprecated
|
|
53
|
-
this.open = false;
|
|
54
|
-
}
|
|
40
|
+
handleDialogClose() {
|
|
41
|
+
this.open = false;
|
|
55
42
|
}
|
|
56
43
|
showModal() {
|
|
57
44
|
this.setAriaDescribedbyOnModal();
|
|
58
|
-
this.setElToFocusOnClose(); //Record where the user was before the modal opened so that focus can return to it when the modal closes
|
|
59
45
|
document.body.style.overflow = "hidden"; //Keeps the page below the modal from scrolling
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
window.requestAnimationFrame(() => {
|
|
65
|
-
// nested requestAnimationFrames allow all elements to become visible on page before assigning focus
|
|
66
|
-
window.requestAnimationFrame(() => this.focusOnOpenEl.focus()); //Bring focus to element inside modal
|
|
67
|
-
});
|
|
46
|
+
this.dialogEl.showModal();
|
|
47
|
+
if (this.focusOnOpenEl) {
|
|
48
|
+
this.focusOnOpenEl.focus();
|
|
49
|
+
}
|
|
68
50
|
}
|
|
69
|
-
//Close the modal and focus the triggering element when the modal buttons emit their events
|
|
70
51
|
hideModal() {
|
|
71
52
|
document.body.style.overflow = "visible";
|
|
72
|
-
|
|
73
|
-
document.body.removeEventListener("focus", this.bodyFocusListener, true);
|
|
74
|
-
window.requestAnimationFrame(() => this.focusOnCloseEl.focus()); //Return focus
|
|
53
|
+
this.dialogEl.close();
|
|
75
54
|
}
|
|
76
55
|
componentWillLoad() {
|
|
77
56
|
if (this.isOpen) {
|
|
@@ -86,7 +65,13 @@ export class Modal {
|
|
|
86
65
|
}
|
|
87
66
|
}
|
|
88
67
|
this.el.focus = () => {
|
|
89
|
-
this.focusOnOpenEl
|
|
68
|
+
if (this.focusOnOpenEl) {
|
|
69
|
+
this.focusOnOpenEl.focus();
|
|
70
|
+
}
|
|
71
|
+
else {
|
|
72
|
+
const closeButton = this.el.querySelector(`#wm-modal-close-${this.uid}`);
|
|
73
|
+
closeButton.focus();
|
|
74
|
+
}
|
|
90
75
|
};
|
|
91
76
|
this.uid = this.el.id ? this.el.id : generateId();
|
|
92
77
|
}
|
|
@@ -94,6 +79,7 @@ export class Modal {
|
|
|
94
79
|
if (this.tempOpen) {
|
|
95
80
|
this.showModal();
|
|
96
81
|
}
|
|
82
|
+
this.dialogEl.addEventListener("close", () => this.handleDialogClose());
|
|
97
83
|
}
|
|
98
84
|
async emitCloseEvent() {
|
|
99
85
|
this.wmModalCloseTriggered.emit();
|
|
@@ -116,26 +102,8 @@ export class Modal {
|
|
|
116
102
|
this.el.setAttribute("aria-describedby", `wm-modal-heading-text-${this.uid} content-${this.uid}`);
|
|
117
103
|
}
|
|
118
104
|
}
|
|
119
|
-
setElToFocusOnClose() {
|
|
120
|
-
const elToFocus = document.activeElement;
|
|
121
|
-
if (elToFocus.tagName === "WM-MENUITEM") {
|
|
122
|
-
this.focusOnCloseEl = elToFocus.parentElement;
|
|
123
|
-
}
|
|
124
|
-
else {
|
|
125
|
-
this.focusOnCloseEl = checkForActiveElInShadow(elToFocus);
|
|
126
|
-
}
|
|
127
|
-
}
|
|
128
|
-
redirectFocusFromBody() {
|
|
129
|
-
if (document.activeElement.tagName === "BODY") {
|
|
130
|
-
this.focusOnOpenEl.focus();
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
105
|
render() {
|
|
134
|
-
return (h(
|
|
135
|
-
this.focusLastElement.emit();
|
|
136
|
-
} }, h("div", { class: "overlay", ref: (el) => (this.overlayEl = el) }), h("div", { class: "sr-only", tabIndex: 0, onFocus: () => {
|
|
137
|
-
this.focusFirstElement.emit();
|
|
138
|
-
} })));
|
|
106
|
+
return (h("dialog", { class: `${"wm-" + this.modalType}`, ref: (el) => (this.dialogEl = el) }, !this.hasBrowserPopoverSupport && h("div", { class: "wm-tooltip" }), h("slot", null)));
|
|
139
107
|
}
|
|
140
108
|
static get is() { return "wm-modal"; }
|
|
141
109
|
static get originalStyleUrls() {
|
|
@@ -444,19 +412,4 @@ export class Modal {
|
|
|
444
412
|
"methodName": "toggleModal"
|
|
445
413
|
}];
|
|
446
414
|
}
|
|
447
|
-
static get listeners() {
|
|
448
|
-
return [{
|
|
449
|
-
"name": "click",
|
|
450
|
-
"method": "handleClick",
|
|
451
|
-
"target": undefined,
|
|
452
|
-
"capture": false,
|
|
453
|
-
"passive": false
|
|
454
|
-
}, {
|
|
455
|
-
"name": "keydown",
|
|
456
|
-
"method": "closeModalOnEscape",
|
|
457
|
-
"target": undefined,
|
|
458
|
-
"capture": false,
|
|
459
|
-
"passive": false
|
|
460
|
-
}];
|
|
461
|
-
}
|
|
462
415
|
}
|
|
@@ -28,32 +28,4 @@ describe("wm-modal", () => {
|
|
|
28
28
|
expect(mockHideModal).toHaveBeenCalledTimes(1);
|
|
29
29
|
jest.resetAllMocks();
|
|
30
30
|
});
|
|
31
|
-
it("when modal is visible-- changes body style, adds focus listener, focuses modal", () => {
|
|
32
|
-
//showModal
|
|
33
|
-
const component = new Modal();
|
|
34
|
-
const mockSetElToFocusOnClose = (component.setElToFocusOnClose = jest.fn());
|
|
35
|
-
const mockSetAriaDescribedBy = (component.setAriaDescribedbyOnModal = jest.fn());
|
|
36
|
-
const mockFocus = jest.fn();
|
|
37
|
-
const spyFocusOnOpenEl = jest.spyOn(component, "focusOnOpenEl", "get");
|
|
38
|
-
let mockEl = { focus: mockFocus };
|
|
39
|
-
spyFocusOnOpenEl.mockReturnValue(mockEl);
|
|
40
|
-
const removeEventListenerSpy = jest.spyOn(document.body, "removeEventListener");
|
|
41
|
-
const addEventListenerSpy = jest.spyOn(document.body, "addEventListener");
|
|
42
|
-
jest
|
|
43
|
-
.spyOn(window, "requestAnimationFrame")
|
|
44
|
-
//@ts-ignore
|
|
45
|
-
.mockImplementation((cb) => cb());
|
|
46
|
-
component.showModal();
|
|
47
|
-
expect(mockSetElToFocusOnClose).toHaveBeenCalledTimes(1);
|
|
48
|
-
expect(document.body.tabIndex).toBe(0);
|
|
49
|
-
// body focus event listener is removed then attached
|
|
50
|
-
expect(removeEventListenerSpy).toHaveBeenCalledTimes(1);
|
|
51
|
-
// @ts-ignore
|
|
52
|
-
expect(removeEventListenerSpy).toHaveBeenCalledWith("focus", component.bodyFocusListener, true);
|
|
53
|
-
expect(addEventListenerSpy).toHaveBeenCalledTimes(1);
|
|
54
|
-
// @ts-ignore
|
|
55
|
-
expect(addEventListenerSpy).toHaveBeenCalledWith("focus", component.bodyFocusListener, true);
|
|
56
|
-
expect(mockSetAriaDescribedBy).toHaveBeenCalledTimes(1);
|
|
57
|
-
expect(mockFocus).toHaveBeenCalledTimes(1);
|
|
58
|
-
});
|
|
59
31
|
});
|
|
@@ -194,30 +194,46 @@ export function adjustTooltipPlacement(placement, anchorEl, tooltipHeight, toolt
|
|
|
194
194
|
return placement;
|
|
195
195
|
}
|
|
196
196
|
export function showTooltip(placement, anchorEl, tooltipText) {
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
tooltipEl.
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
tooltipEl.classList.
|
|
207
|
-
tooltipEl.
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
197
|
+
// until popover is supported by firefox, we have to check for and position additional tooltip rendered within the modal's dialog element
|
|
198
|
+
// this additional tooltip is only rendered in browsers that do not support popover
|
|
199
|
+
const tooltipEls = document.querySelectorAll(".wm-tooltip");
|
|
200
|
+
tooltipEls.forEach((tooltipEl) => {
|
|
201
|
+
//@ts-ignore
|
|
202
|
+
if (!!tooltipEl.showPopover) {
|
|
203
|
+
//@ts-ignore
|
|
204
|
+
tooltipEl.showPopover();
|
|
205
|
+
}
|
|
206
|
+
tooltipEl.classList.add("show");
|
|
207
|
+
tooltipEl.textContent = tooltipText;
|
|
208
|
+
// tooltip only has a maxWidth if it contains whitespace and can break
|
|
209
|
+
const hasNoWhitespace = tooltipText.match(/^[^\s]+$/);
|
|
210
|
+
if (hasNoWhitespace) {
|
|
211
|
+
tooltipEl.classList.add("single-word");
|
|
212
|
+
tooltipEl.style.setProperty("--wmTooltipMaxWidth", "none");
|
|
213
|
+
}
|
|
214
|
+
else {
|
|
215
|
+
tooltipEl.classList.remove("single-word");
|
|
216
|
+
tooltipEl.style.removeProperty("--wmTooltipMaxWidth");
|
|
217
|
+
}
|
|
218
|
+
const tooltipRect = tooltipEl.getBoundingClientRect();
|
|
219
|
+
const anchorRect = anchorEl.getBoundingClientRect();
|
|
220
|
+
const adjustedPlacement = adjustTooltipPlacement(placement, anchorEl, tooltipRect.height, tooltipRect.width);
|
|
221
|
+
let verticalPos, horizontalPos;
|
|
222
|
+
[verticalPos, horizontalPos] = positionTooltip(adjustedPlacement, anchorRect, tooltipRect.height, tooltipRect.width);
|
|
223
|
+
tooltipEl.style.setProperty("--wmTooltipTop", verticalPos + "px");
|
|
224
|
+
tooltipEl.style.setProperty("--wmTooltipLeft", horizontalPos + "px");
|
|
225
|
+
});
|
|
217
226
|
}
|
|
218
227
|
export function hideTooltip() {
|
|
219
|
-
const
|
|
220
|
-
|
|
228
|
+
const tooltipEls = document.querySelectorAll(".wm-tooltip");
|
|
229
|
+
tooltipEls.forEach((tooltipEl) => {
|
|
230
|
+
//@ts-ignore
|
|
231
|
+
if (!!tooltipEl.hidePopover) {
|
|
232
|
+
//@ts-ignore
|
|
233
|
+
tooltipEl.hidePopover();
|
|
234
|
+
}
|
|
235
|
+
tooltipEl.classList.remove("show");
|
|
236
|
+
});
|
|
221
237
|
}
|
|
222
238
|
function positionTooltip(placement, anchorRect, tooltipHeight, tooltipWidth) {
|
|
223
239
|
// to get the center positions, calculate the difference between the button width and the tooltip width
|
|
@@ -43,10 +43,12 @@ const tooltipContainer = document.createElement("div");
|
|
|
43
43
|
tooltipContainer.id = "wm-tooltip-container";
|
|
44
44
|
const tooltipEl = document.createElement("div");
|
|
45
45
|
tooltipEl.id = "wm-tooltip";
|
|
46
|
+
tooltipEl.classList.add("wm-tooltip");
|
|
47
|
+
tooltipEl.setAttribute("popover", "manual");
|
|
46
48
|
tooltipEl.setAttribute("aria-hidden", "true");
|
|
47
49
|
const tooltipStyles = document.createElement("style");
|
|
48
50
|
tooltipStyles.textContent = `
|
|
49
|
-
|
|
51
|
+
.wm-tooltip {
|
|
50
52
|
position: fixed;
|
|
51
53
|
overflow: hidden;
|
|
52
54
|
pointer-events: none;
|
|
@@ -64,14 +66,20 @@ tooltipStyles.textContent = `
|
|
|
64
66
|
transition-property: opacity;
|
|
65
67
|
transition-delay: 0s;
|
|
66
68
|
opacity: 0;
|
|
69
|
+
inset: unset;
|
|
67
70
|
top: 0;
|
|
68
71
|
left: 0;
|
|
69
72
|
transform: translateZ(0);
|
|
70
73
|
will-change: transform;
|
|
71
74
|
transform: translate(var(--wmTooltipLeft), var(--wmTooltipTop));
|
|
75
|
+
border: none;
|
|
72
76
|
}
|
|
73
77
|
|
|
74
|
-
|
|
78
|
+
.wm-tooltip:popover-open {
|
|
79
|
+
opacity: 0;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.wm-tooltip.show {
|
|
75
83
|
transition-delay: 500ms;
|
|
76
84
|
opacity: 1;
|
|
77
85
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { h } from './index-
|
|
2
|
-
import { i as intl, c as
|
|
1
|
+
import { h } from './index-7e11ea42.js';
|
|
2
|
+
import { i as intl, c as getPosition, f as findParentWithScrollbar, e as checkForActiveElInShadow, d as debounce } from './functions-d52b728c.js';
|
|
3
3
|
|
|
4
4
|
const colors = {
|
|
5
5
|
salmon: "#ff5f4e",
|