@limetech/lime-elements 38.34.0 → 38.35.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (127) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/dist/cjs/lime-elements.cjs.js +1 -1
  3. package/dist/cjs/limel-action-bar_2.cjs.entry.js +1 -1
  4. package/dist/cjs/limel-ai-avatar.cjs.entry.js +1 -1
  5. package/dist/cjs/limel-callout.cjs.entry.js +1 -1
  6. package/dist/cjs/limel-chart.cjs.entry.js +7 -4
  7. package/dist/cjs/limel-chart.cjs.entry.js.map +1 -1
  8. package/dist/cjs/limel-chip_2.cjs.entry.js +1 -1
  9. package/dist/cjs/limel-collapsible-section.cjs.entry.js +1 -1
  10. package/dist/cjs/limel-dialog.cjs.entry.js +4 -4
  11. package/dist/cjs/limel-dialog.cjs.entry.js.map +1 -1
  12. package/dist/cjs/limel-drag-handle.cjs.entry.js +1 -1
  13. package/dist/cjs/limel-file-viewer.cjs.entry.js +1 -1
  14. package/dist/cjs/limel-file.cjs.entry.js +1 -1
  15. package/dist/cjs/limel-flatpickr-adapter.cjs.entry.js +1 -1
  16. package/dist/cjs/limel-linear-progress.cjs.entry.js +1 -1
  17. package/dist/cjs/limel-list-item.cjs.entry.js +1 -1
  18. package/dist/cjs/limel-profile-picture.cjs.entry.js +1 -1
  19. package/dist/cjs/limel-prosemirror-adapter.cjs.entry.js +1 -1
  20. package/dist/cjs/limel-snackbar.cjs.entry.js +1 -1
  21. package/dist/cjs/limel-table.cjs.entry.js +1 -1
  22. package/dist/cjs/loader.cjs.js +1 -1
  23. package/dist/cjs/{translations-a42886f2.js → translations-e58b6da5.js} +9 -1
  24. package/dist/cjs/translations-e58b6da5.js.map +1 -0
  25. package/dist/collection/components/chart/chart.css +53 -0
  26. package/dist/collection/components/chart/chart.js +42 -3
  27. package/dist/collection/components/chart/chart.js.map +1 -1
  28. package/dist/collection/components/dialog/dialog.js +4 -4
  29. package/dist/collection/components/dialog/dialog.js.map +1 -1
  30. package/dist/collection/components/dialog/dialog.types.js.map +1 -1
  31. package/dist/collection/translations/da.js +1 -0
  32. package/dist/collection/translations/da.js.map +1 -1
  33. package/dist/collection/translations/de.js +1 -0
  34. package/dist/collection/translations/de.js.map +1 -1
  35. package/dist/collection/translations/en.js +1 -0
  36. package/dist/collection/translations/en.js.map +1 -1
  37. package/dist/collection/translations/fi.js +1 -0
  38. package/dist/collection/translations/fi.js.map +1 -1
  39. package/dist/collection/translations/fr.js +1 -0
  40. package/dist/collection/translations/fr.js.map +1 -1
  41. package/dist/collection/translations/nl.js +1 -0
  42. package/dist/collection/translations/nl.js.map +1 -1
  43. package/dist/collection/translations/no.js +1 -0
  44. package/dist/collection/translations/no.js.map +1 -1
  45. package/dist/collection/translations/sv.js +1 -0
  46. package/dist/collection/translations/sv.js.map +1 -1
  47. package/dist/esm/lime-elements.js +1 -1
  48. package/dist/esm/limel-action-bar_2.entry.js +1 -1
  49. package/dist/esm/limel-ai-avatar.entry.js +1 -1
  50. package/dist/esm/limel-callout.entry.js +1 -1
  51. package/dist/esm/limel-chart.entry.js +7 -4
  52. package/dist/esm/limel-chart.entry.js.map +1 -1
  53. package/dist/esm/limel-chip_2.entry.js +1 -1
  54. package/dist/esm/limel-collapsible-section.entry.js +1 -1
  55. package/dist/esm/limel-dialog.entry.js +4 -4
  56. package/dist/esm/limel-dialog.entry.js.map +1 -1
  57. package/dist/esm/limel-drag-handle.entry.js +1 -1
  58. package/dist/esm/limel-file-viewer.entry.js +1 -1
  59. package/dist/esm/limel-file.entry.js +1 -1
  60. package/dist/esm/limel-flatpickr-adapter.entry.js +1 -1
  61. package/dist/esm/limel-linear-progress.entry.js +1 -1
  62. package/dist/esm/limel-list-item.entry.js +1 -1
  63. package/dist/esm/limel-profile-picture.entry.js +1 -1
  64. package/dist/esm/limel-prosemirror-adapter.entry.js +1 -1
  65. package/dist/esm/limel-snackbar.entry.js +1 -1
  66. package/dist/esm/limel-table.entry.js +1 -1
  67. package/dist/esm/loader.js +1 -1
  68. package/dist/esm/{translations-9bfde9f4.js → translations-4151479a.js} +9 -1
  69. package/dist/esm/translations-4151479a.js.map +1 -0
  70. package/dist/lime-elements/lime-elements.esm.js +1 -1
  71. package/dist/lime-elements/lime-elements.esm.js.map +1 -1
  72. package/dist/lime-elements/{p-ee5c4112.entry.js → p-13bd2797.entry.js} +2 -2
  73. package/dist/lime-elements/{p-df9bcace.entry.js → p-158897dd.entry.js} +2 -2
  74. package/dist/lime-elements/{p-e00465fa.entry.js → p-182ce303.entry.js} +2 -2
  75. package/dist/lime-elements/{p-d79c85e2.entry.js → p-23de215d.entry.js} +2 -2
  76. package/dist/lime-elements/{p-8ea3b80a.entry.js → p-3746c217.entry.js} +2 -2
  77. package/dist/lime-elements/{p-aa1e7319.entry.js → p-61b2e426.entry.js} +2 -2
  78. package/dist/lime-elements/{p-92aa9610.entry.js → p-68799403.entry.js} +2 -2
  79. package/dist/lime-elements/{p-3311eaf3.entry.js → p-6d9fb8e8.entry.js} +2 -2
  80. package/dist/lime-elements/{p-fbac230b.entry.js → p-7da20f22.entry.js} +2 -2
  81. package/dist/lime-elements/{p-cd2f780a.entry.js → p-7e1a548a.entry.js} +2 -2
  82. package/dist/lime-elements/{p-ef1d26ac.entry.js → p-874f06f0.entry.js} +3 -3
  83. package/dist/lime-elements/p-874f06f0.entry.js.map +1 -0
  84. package/dist/lime-elements/{p-b0acf522.entry.js → p-99f5e70b.entry.js} +2 -2
  85. package/dist/lime-elements/{p-40542ccc.entry.js → p-bf527989.entry.js} +2 -2
  86. package/dist/lime-elements/p-c582027f.js +2 -0
  87. package/dist/lime-elements/p-c582027f.js.map +1 -0
  88. package/dist/lime-elements/{p-31f1cb08.entry.js → p-d76d70ce.entry.js} +2 -2
  89. package/dist/lime-elements/p-dc55f5ca.entry.js +2 -0
  90. package/dist/lime-elements/p-dc55f5ca.entry.js.map +1 -0
  91. package/dist/lime-elements/{p-5e976a59.entry.js → p-f529b510.entry.js} +2 -2
  92. package/dist/lime-elements/{p-42e889d8.entry.js → p-ffedb0be.entry.js} +2 -2
  93. package/dist/types/components/chart/chart.d.ts +13 -0
  94. package/dist/types/components/dialog/dialog.d.ts +1 -1
  95. package/dist/types/components/dialog/dialog.types.d.ts +1 -1
  96. package/dist/types/components.d.ts +22 -2
  97. package/dist/types/translations/da.d.ts +1 -0
  98. package/dist/types/translations/de.d.ts +1 -0
  99. package/dist/types/translations/en.d.ts +1 -0
  100. package/dist/types/translations/fi.d.ts +1 -0
  101. package/dist/types/translations/fr.d.ts +1 -0
  102. package/dist/types/translations/nl.d.ts +1 -0
  103. package/dist/types/translations/no.d.ts +1 -0
  104. package/dist/types/translations/sv.d.ts +1 -0
  105. package/package.json +1 -1
  106. package/dist/cjs/translations-a42886f2.js.map +0 -1
  107. package/dist/esm/translations-9bfde9f4.js.map +0 -1
  108. package/dist/lime-elements/p-5df2361b.js +0 -2
  109. package/dist/lime-elements/p-5df2361b.js.map +0 -1
  110. package/dist/lime-elements/p-84e00842.entry.js +0 -2
  111. package/dist/lime-elements/p-84e00842.entry.js.map +0 -1
  112. package/dist/lime-elements/p-ef1d26ac.entry.js.map +0 -1
  113. /package/dist/lime-elements/{p-ee5c4112.entry.js.map → p-13bd2797.entry.js.map} +0 -0
  114. /package/dist/lime-elements/{p-df9bcace.entry.js.map → p-158897dd.entry.js.map} +0 -0
  115. /package/dist/lime-elements/{p-e00465fa.entry.js.map → p-182ce303.entry.js.map} +0 -0
  116. /package/dist/lime-elements/{p-d79c85e2.entry.js.map → p-23de215d.entry.js.map} +0 -0
  117. /package/dist/lime-elements/{p-8ea3b80a.entry.js.map → p-3746c217.entry.js.map} +0 -0
  118. /package/dist/lime-elements/{p-aa1e7319.entry.js.map → p-61b2e426.entry.js.map} +0 -0
  119. /package/dist/lime-elements/{p-92aa9610.entry.js.map → p-68799403.entry.js.map} +0 -0
  120. /package/dist/lime-elements/{p-3311eaf3.entry.js.map → p-6d9fb8e8.entry.js.map} +0 -0
  121. /package/dist/lime-elements/{p-fbac230b.entry.js.map → p-7da20f22.entry.js.map} +0 -0
  122. /package/dist/lime-elements/{p-cd2f780a.entry.js.map → p-7e1a548a.entry.js.map} +0 -0
  123. /package/dist/lime-elements/{p-b0acf522.entry.js.map → p-99f5e70b.entry.js.map} +0 -0
  124. /package/dist/lime-elements/{p-40542ccc.entry.js.map → p-bf527989.entry.js.map} +0 -0
  125. /package/dist/lime-elements/{p-31f1cb08.entry.js.map → p-d76d70ce.entry.js.map} +0 -0
  126. /package/dist/lime-elements/{p-5e976a59.entry.js.map → p-f529b510.entry.js.map} +0 -0
  127. /package/dist/lime-elements/{p-42e889d8.entry.js.map → p-ffedb0be.entry.js.map} +0 -0
@@ -1 +0,0 @@
1
- {"version":3,"names":["createFocusTrapInstance","surfaceEl","focusTrapFactory","initialFocusEl","isScrollable","el","scrollHeight","offsetHeight","isScrollAtTop","scrollTop","isScrollAtBottom","Math","ceil","clientHeight","areTopsMisaligned","els","tops","Set","forEach","call","add","offsetTop","size","FOCUS_SENTINEL_CLASS","FocusTrap","root","options","this","elFocusedBeforeTrapFocus","prototype","trapFocus","focusableEls","getFocusableElements","length","Error","document","activeElement","HTMLElement","wrapTabFocus","skipInitialFocus","focusInitialElement","releaseFocus","slice","querySelectorAll","sentinelEl","parentElement","removeChild","skipRestoreFocus","focus","_this","sentinelStart","createSentinel","sentinelEnd","addEventListener","insertBefore","children","appendChild","focusIndex","max","indexOf","filter","isDisabledOrHidden","getAttribute","isTabbableAndVisible","tabIndex","getBoundingClientRect","width","classList","contains","isProgrammaticallyHidden","style","getComputedStyle","display","visibility","sentinel","createElement","setAttribute","cssClasses","CLOSING","OPEN","OPENING","SCROLLABLE","SCROLL_LOCK","STACKED","FULLSCREEN","SCROLL_DIVIDER_HEADER","SCROLL_DIVIDER_FOOTER","SURFACE_SCRIM_SHOWN","SURFACE_SCRIM_SHOWING","SURFACE_SCRIM_HIDING","SCRIM_HIDDEN","strings","ACTION_ATTRIBUTE","BUTTON_DEFAULT_ATTRIBUTE","BUTTON_SELECTOR","CLOSED_EVENT","CLOSE_ACTION","CLOSING_EVENT","CONTAINER_SELECTOR","CONTENT_SELECTOR","DESTROY_ACTION","INITIAL_FOCUS_ATTRIBUTE","OPENED_EVENT","OPENING_EVENT","SCRIM_SELECTOR","SUPPRESS_DEFAULT_PRESS_SELECTOR","join","SURFACE_SELECTOR","numbers","DIALOG_ANIMATION_CLOSE_TIME_MS","DIALOG_ANIMATION_OPEN_TIME_MS","AnimationKeys","MDCDialogFoundation","_super","__extends","adapter","__assign","defaultAdapter","dialogOpen","isFullscreen","animationFrame","animationTimer","escapeKeyAction","scrimClickAction","autoStackButtons","areButtonsStacked","suppressDefaultPressSelector","animFrame","AnimationFrame","contentScrollHandler","handleScrollEvent","windowResizeHandler","layout","windowOrientationChangeHandler","Object","defineProperty","get","enumerable","configurable","addBodyClass","undefined","addClass","clickDefaultButton","eventTargetMatches","getActionFromEvent","getInitialFocusEl","hasClass","isContentScrollable","notifyClosed","notifyClosing","notifyOpened","notifyOpening","removeBodyClass","removeClass","reverseButtons","registerContentEventHandler","deregisterContentEventHandler","isScrollableContentAtTop","isScrollableContentAtBottom","registerWindowEventHandler","deregisterWindowEventHandler","init","setAutoStackButtons","destroy","clearTimeout","handleAnimationTimerEnd","cancelAll","open","dialogOptions","isAboveFullscreenDialog","runNextAnimationFrame","setTimeout","close","action","cancelAnimationFrame","showSurfaceScrim","hideSurfaceScrim","handleSurfaceScrimTransitionEnd","isOpen","getEscapeKeyAction","setEscapeKeyAction","getScrimClickAction","setScrimClickAction","getAutoStackButtons","autoStack","getSuppressDefaultPressSelector","setSuppressDefaultPressSelector","selector","request","POLL_LAYOUT_CHANGE","layoutInternal","handleClick","evt","isScrim","target","handleKeydown","isEnter","key","keyCode","composedPath","isDefault","handleDocumentKeydown","isEscape","POLL_SCROLL_POS","toggleScrollDividerHeader","toggleScrollDividerFooter","detectStackedButtons","toggleScrollableClasses","callback","requestAnimationFrame","MDCFoundation","MDCDialog","apply","arguments","foundation","set","attachTo","initialize","e_1","_a","focusOptions","container","querySelector","content","buttons","defaultButton","buttonRipples","_b","__values","_c","next","done","buttonEl","value","push","MDCRipple","e_1_1","error","return","initialSyncWithDOM","focusTrap","util.createFocusTrapInstance","bind","handleOpening","handleClosing","removeEventListener","listen","unlisten","ripple","getDefaultFoundation","className","body","util.areTopsMisaligned","disabled","click","matches","element","closest","util.isScrollable","emit","remove","reverse","button","handler","util.isScrollAtTop","util.isScrollAtBottom","window","MDCComponent","dialogCss","Dialog","constructor","hostRef","escapeKey","scrimClick","handleMdcOpened","handleMdcClosed","handleMdcClosing","connectedCallback","componentWillLoad","id","createRandomString","componentDidLoad","host","shadowRoot","mdcDialog","setClosingActions","disconnectedCallback","render","h","class","fullscreen","role","hidden","type","renderHeading","renderFooter","watchHandler","newValue","oldValue","closingActionsChanged","isEqual","waitForUiToRender","dispatchResizeEvent","closing","isBadgeHeading","heading","title","icon","subtitle","supportingText","subheading","name","slot","closingActions"],"sources":["./node_modules/@material/dialog/util.js","./node_modules/@material/dom/focus-trap.js","./node_modules/@material/dialog/constants.js","./node_modules/@material/dialog/foundation.js","./node_modules/@material/dialog/component.js","./src/components/dialog/dialog.scss?tag=limel-dialog&encapsulation=shadow","./src/components/dialog/dialog.tsx"],"sourcesContent":["/**\n * @license\n * Copyright 2016 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nexport function createFocusTrapInstance(surfaceEl, focusTrapFactory, initialFocusEl) {\n return focusTrapFactory(surfaceEl, { initialFocusEl: initialFocusEl });\n}\nexport function isScrollable(el) {\n return el ? el.scrollHeight > el.offsetHeight : false;\n}\n/**\n * For scrollable content, returns true if the content has not been scrolled\n * (that is, the scroll content is as the \"top\"). This is used in full-screen\n * dialogs, where the scroll divider is expected only to appear once the\n * content has been scrolled \"underneath\" the header bar.\n */\nexport function isScrollAtTop(el) {\n return el ? el.scrollTop === 0 : false;\n}\n/**\n * For scrollable content, returns true if the content has been scrolled all the\n * way to the bottom. This is used in full-screen dialogs, where the footer\n * scroll divider is expected only to appear when the content is \"cut-off\" by\n * the footer bar.\n */\nexport function isScrollAtBottom(el) {\n return el ? Math.ceil(el.scrollHeight - el.scrollTop) === el.clientHeight :\n false;\n}\nexport function areTopsMisaligned(els) {\n var tops = new Set();\n [].forEach.call(els, function (el) { return tops.add(el.offsetTop); });\n return tops.size > 1;\n}\n//# sourceMappingURL=util.js.map","/**\n * @license\n * Copyright 2020 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nvar FOCUS_SENTINEL_CLASS = 'mdc-dom-focus-sentinel';\n/**\n * Utility to trap focus in a given root element, e.g. for modal components such\n * as dialogs. The root should have at least one focusable child element,\n * for setting initial focus when trapping focus.\n * Also tracks the previously focused element, and restores focus to that\n * element when releasing focus.\n */\nvar FocusTrap = /** @class */ (function () {\n function FocusTrap(root, options) {\n if (options === void 0) { options = {}; }\n this.root = root;\n this.options = options;\n // Previously focused element before trapping focus.\n this.elFocusedBeforeTrapFocus = null;\n }\n /**\n * Traps focus in `root`. Also focuses on either `initialFocusEl` if set;\n * otherwises sets initial focus to the first focusable child element.\n */\n FocusTrap.prototype.trapFocus = function () {\n var focusableEls = this.getFocusableElements(this.root);\n if (focusableEls.length === 0) {\n throw new Error('FocusTrap: Element must have at least one focusable child.');\n }\n this.elFocusedBeforeTrapFocus =\n document.activeElement instanceof HTMLElement ? document.activeElement :\n null;\n this.wrapTabFocus(this.root);\n if (!this.options.skipInitialFocus) {\n this.focusInitialElement(focusableEls, this.options.initialFocusEl);\n }\n };\n /**\n * Releases focus from `root`. Also restores focus to the previously focused\n * element.\n */\n FocusTrap.prototype.releaseFocus = function () {\n [].slice.call(this.root.querySelectorAll(\".\" + FOCUS_SENTINEL_CLASS))\n .forEach(function (sentinelEl) {\n sentinelEl.parentElement.removeChild(sentinelEl);\n });\n if (!this.options.skipRestoreFocus && this.elFocusedBeforeTrapFocus) {\n this.elFocusedBeforeTrapFocus.focus();\n }\n };\n /**\n * Wraps tab focus within `el` by adding two hidden sentinel divs which are\n * used to mark the beginning and the end of the tabbable region. When\n * focused, these sentinel elements redirect focus to the first/last\n * children elements of the tabbable region, ensuring that focus is trapped\n * within that region.\n */\n FocusTrap.prototype.wrapTabFocus = function (el) {\n var _this = this;\n var sentinelStart = this.createSentinel();\n var sentinelEnd = this.createSentinel();\n sentinelStart.addEventListener('focus', function () {\n var focusableEls = _this.getFocusableElements(el);\n if (focusableEls.length > 0) {\n focusableEls[focusableEls.length - 1].focus();\n }\n });\n sentinelEnd.addEventListener('focus', function () {\n var focusableEls = _this.getFocusableElements(el);\n if (focusableEls.length > 0) {\n focusableEls[0].focus();\n }\n });\n el.insertBefore(sentinelStart, el.children[0]);\n el.appendChild(sentinelEnd);\n };\n /**\n * Focuses on `initialFocusEl` if defined and a child of the root element.\n * Otherwise, focuses on the first focusable child element of the root.\n */\n FocusTrap.prototype.focusInitialElement = function (focusableEls, initialFocusEl) {\n var focusIndex = 0;\n if (initialFocusEl) {\n focusIndex = Math.max(focusableEls.indexOf(initialFocusEl), 0);\n }\n focusableEls[focusIndex].focus();\n };\n FocusTrap.prototype.getFocusableElements = function (root) {\n var focusableEls = [].slice.call(root.querySelectorAll('[autofocus], [tabindex], a, input, textarea, select, button'));\n return focusableEls.filter(function (el) {\n var isDisabledOrHidden = el.getAttribute('aria-disabled') === 'true' ||\n el.getAttribute('disabled') != null ||\n el.getAttribute('hidden') != null ||\n el.getAttribute('aria-hidden') === 'true';\n var isTabbableAndVisible = el.tabIndex >= 0 &&\n el.getBoundingClientRect().width > 0 &&\n !el.classList.contains(FOCUS_SENTINEL_CLASS) && !isDisabledOrHidden;\n var isProgrammaticallyHidden = false;\n if (isTabbableAndVisible) {\n var style = getComputedStyle(el);\n isProgrammaticallyHidden =\n style.display === 'none' || style.visibility === 'hidden';\n }\n return isTabbableAndVisible && !isProgrammaticallyHidden;\n });\n };\n FocusTrap.prototype.createSentinel = function () {\n var sentinel = document.createElement('div');\n sentinel.setAttribute('tabindex', '0');\n // Don't announce in screen readers.\n sentinel.setAttribute('aria-hidden', 'true');\n sentinel.classList.add(FOCUS_SENTINEL_CLASS);\n return sentinel;\n };\n return FocusTrap;\n}());\nexport { FocusTrap };\n//# sourceMappingURL=focus-trap.js.map","/**\n * @license\n * Copyright 2016 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nexport var cssClasses = {\n CLOSING: 'mdc-dialog--closing',\n OPEN: 'mdc-dialog--open',\n OPENING: 'mdc-dialog--opening',\n SCROLLABLE: 'mdc-dialog--scrollable',\n SCROLL_LOCK: 'mdc-dialog-scroll-lock',\n STACKED: 'mdc-dialog--stacked',\n FULLSCREEN: 'mdc-dialog--fullscreen',\n // Class for showing a scroll divider on full-screen dialog header element.\n // Should only be displayed on scrollable content, when the dialog content is\n // scrolled \"underneath\" the header.\n SCROLL_DIVIDER_HEADER: 'mdc-dialog-scroll-divider-header',\n // Class for showing a scroll divider on a full-screen dialog footer element.\n // Should only be displayed on scrolalble content, when the dialog content is\n // obscured \"underneath\" the footer.\n SCROLL_DIVIDER_FOOTER: 'mdc-dialog-scroll-divider-footer',\n // The \"surface scrim\" is a scrim covering only the surface of a dialog. This\n // is used in situations where a confirmation dialog is shown over an already\n // opened full-screen dialog. On larger screen-sizes, the full-screen dialog\n // is sized as a modal and so in these situations we display a \"surface scrim\"\n // to prevent a \"double scrim\" (where the scrim from the secondary\n // confirmation dialog would overlap with the scrim from the full-screen\n // dialog).\n SURFACE_SCRIM_SHOWN: 'mdc-dialog__surface-scrim--shown',\n // \"Showing\" animating class for the surface-scrim.\n SURFACE_SCRIM_SHOWING: 'mdc-dialog__surface-scrim--showing',\n // \"Hiding\" animating class for the surface-scrim.\n SURFACE_SCRIM_HIDING: 'mdc-dialog__surface-scrim--hiding',\n // Class to hide a dialog's scrim (used in conjunction with a surface-scrim).\n // Note that we only hide the original scrim rather than removing it entirely\n // to prevent interactions with the content behind this scrim, and to capture\n // scrim clicks.\n SCRIM_HIDDEN: 'mdc-dialog__scrim--hidden',\n};\nexport var strings = {\n ACTION_ATTRIBUTE: 'data-mdc-dialog-action',\n BUTTON_DEFAULT_ATTRIBUTE: 'data-mdc-dialog-button-default',\n BUTTON_SELECTOR: '.mdc-dialog__button',\n CLOSED_EVENT: 'MDCDialog:closed',\n CLOSE_ACTION: 'close',\n CLOSING_EVENT: 'MDCDialog:closing',\n CONTAINER_SELECTOR: '.mdc-dialog__container',\n CONTENT_SELECTOR: '.mdc-dialog__content',\n DESTROY_ACTION: 'destroy',\n INITIAL_FOCUS_ATTRIBUTE: 'data-mdc-dialog-initial-focus',\n OPENED_EVENT: 'MDCDialog:opened',\n OPENING_EVENT: 'MDCDialog:opening',\n SCRIM_SELECTOR: '.mdc-dialog__scrim',\n SUPPRESS_DEFAULT_PRESS_SELECTOR: [\n 'textarea',\n '.mdc-menu .mdc-list-item',\n '.mdc-menu .mdc-deprecated-list-item',\n ].join(', '),\n SURFACE_SELECTOR: '.mdc-dialog__surface',\n};\nexport var numbers = {\n DIALOG_ANIMATION_CLOSE_TIME_MS: 75,\n DIALOG_ANIMATION_OPEN_TIME_MS: 150,\n};\n//# sourceMappingURL=constants.js.map","/**\n * @license\n * Copyright 2017 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport { __assign, __extends } from \"tslib\";\nimport { AnimationFrame } from '@material/animation/animationframe';\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses, numbers, strings } from './constants';\nvar AnimationKeys;\n(function (AnimationKeys) {\n AnimationKeys[\"POLL_SCROLL_POS\"] = \"poll_scroll_position\";\n AnimationKeys[\"POLL_LAYOUT_CHANGE\"] = \"poll_layout_change\";\n})(AnimationKeys || (AnimationKeys = {}));\nvar MDCDialogFoundation = /** @class */ (function (_super) {\n __extends(MDCDialogFoundation, _super);\n function MDCDialogFoundation(adapter) {\n var _this = _super.call(this, __assign(__assign({}, MDCDialogFoundation.defaultAdapter), adapter)) || this;\n _this.dialogOpen = false;\n _this.isFullscreen = false;\n _this.animationFrame = 0;\n _this.animationTimer = 0;\n _this.escapeKeyAction = strings.CLOSE_ACTION;\n _this.scrimClickAction = strings.CLOSE_ACTION;\n _this.autoStackButtons = true;\n _this.areButtonsStacked = false;\n _this.suppressDefaultPressSelector = strings.SUPPRESS_DEFAULT_PRESS_SELECTOR;\n _this.animFrame = new AnimationFrame();\n _this.contentScrollHandler = function () {\n _this.handleScrollEvent();\n };\n _this.windowResizeHandler = function () {\n _this.layout();\n };\n _this.windowOrientationChangeHandler = function () {\n _this.layout();\n };\n return _this;\n }\n Object.defineProperty(MDCDialogFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(MDCDialogFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(MDCDialogFoundation, \"numbers\", {\n get: function () {\n return numbers;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(MDCDialogFoundation, \"defaultAdapter\", {\n get: function () {\n return {\n addBodyClass: function () { return undefined; },\n addClass: function () { return undefined; },\n areButtonsStacked: function () { return false; },\n clickDefaultButton: function () { return undefined; },\n eventTargetMatches: function () { return false; },\n getActionFromEvent: function () { return ''; },\n getInitialFocusEl: function () { return null; },\n hasClass: function () { return false; },\n isContentScrollable: function () { return false; },\n notifyClosed: function () { return undefined; },\n notifyClosing: function () { return undefined; },\n notifyOpened: function () { return undefined; },\n notifyOpening: function () { return undefined; },\n releaseFocus: function () { return undefined; },\n removeBodyClass: function () { return undefined; },\n removeClass: function () { return undefined; },\n reverseButtons: function () { return undefined; },\n trapFocus: function () { return undefined; },\n registerContentEventHandler: function () { return undefined; },\n deregisterContentEventHandler: function () { return undefined; },\n isScrollableContentAtTop: function () { return false; },\n isScrollableContentAtBottom: function () { return false; },\n registerWindowEventHandler: function () { return undefined; },\n deregisterWindowEventHandler: function () { return undefined; },\n };\n },\n enumerable: false,\n configurable: true\n });\n MDCDialogFoundation.prototype.init = function () {\n if (this.adapter.hasClass(cssClasses.STACKED)) {\n this.setAutoStackButtons(false);\n }\n this.isFullscreen = this.adapter.hasClass(cssClasses.FULLSCREEN);\n };\n MDCDialogFoundation.prototype.destroy = function () {\n if (this.animationTimer) {\n clearTimeout(this.animationTimer);\n this.handleAnimationTimerEnd();\n }\n if (this.isFullscreen) {\n this.adapter.deregisterContentEventHandler('scroll', this.contentScrollHandler);\n }\n this.animFrame.cancelAll();\n this.adapter.deregisterWindowEventHandler('resize', this.windowResizeHandler);\n this.adapter.deregisterWindowEventHandler('orientationchange', this.windowOrientationChangeHandler);\n };\n MDCDialogFoundation.prototype.open = function (dialogOptions) {\n var _this = this;\n this.dialogOpen = true;\n this.adapter.notifyOpening();\n this.adapter.addClass(cssClasses.OPENING);\n if (this.isFullscreen) {\n // A scroll event listener is registered even if the dialog is not\n // scrollable on open, since the window resize event, or orientation\n // change may make the dialog scrollable after it is opened.\n this.adapter.registerContentEventHandler('scroll', this.contentScrollHandler);\n }\n if (dialogOptions && dialogOptions.isAboveFullscreenDialog) {\n this.adapter.addClass(cssClasses.SCRIM_HIDDEN);\n }\n this.adapter.registerWindowEventHandler('resize', this.windowResizeHandler);\n this.adapter.registerWindowEventHandler('orientationchange', this.windowOrientationChangeHandler);\n // Wait a frame once display is no longer \"none\", to establish basis for\n // animation\n this.runNextAnimationFrame(function () {\n _this.adapter.addClass(cssClasses.OPEN);\n _this.adapter.addBodyClass(cssClasses.SCROLL_LOCK);\n _this.layout();\n _this.animationTimer = setTimeout(function () {\n _this.handleAnimationTimerEnd();\n _this.adapter.trapFocus(_this.adapter.getInitialFocusEl());\n _this.adapter.notifyOpened();\n }, numbers.DIALOG_ANIMATION_OPEN_TIME_MS);\n });\n };\n MDCDialogFoundation.prototype.close = function (action) {\n var _this = this;\n if (action === void 0) { action = ''; }\n if (!this.dialogOpen) {\n // Avoid redundant close calls (and events), e.g. from keydown on elements\n // that inherently emit click\n return;\n }\n this.dialogOpen = false;\n this.adapter.notifyClosing(action);\n this.adapter.addClass(cssClasses.CLOSING);\n this.adapter.removeClass(cssClasses.OPEN);\n this.adapter.removeBodyClass(cssClasses.SCROLL_LOCK);\n if (this.isFullscreen) {\n this.adapter.deregisterContentEventHandler('scroll', this.contentScrollHandler);\n }\n this.adapter.deregisterWindowEventHandler('resize', this.windowResizeHandler);\n this.adapter.deregisterWindowEventHandler('orientationchange', this.windowOrientationChangeHandler);\n cancelAnimationFrame(this.animationFrame);\n this.animationFrame = 0;\n clearTimeout(this.animationTimer);\n this.animationTimer = setTimeout(function () {\n _this.adapter.releaseFocus();\n _this.handleAnimationTimerEnd();\n _this.adapter.notifyClosed(action);\n }, numbers.DIALOG_ANIMATION_CLOSE_TIME_MS);\n };\n /**\n * Used only in instances of showing a secondary dialog over a full-screen\n * dialog. Shows the \"surface scrim\" displayed over the full-screen dialog.\n */\n MDCDialogFoundation.prototype.showSurfaceScrim = function () {\n var _this = this;\n this.adapter.addClass(cssClasses.SURFACE_SCRIM_SHOWING);\n this.runNextAnimationFrame(function () {\n _this.adapter.addClass(cssClasses.SURFACE_SCRIM_SHOWN);\n });\n };\n /**\n * Used only in instances of showing a secondary dialog over a full-screen\n * dialog. Hides the \"surface scrim\" displayed over the full-screen dialog.\n */\n MDCDialogFoundation.prototype.hideSurfaceScrim = function () {\n this.adapter.removeClass(cssClasses.SURFACE_SCRIM_SHOWN);\n this.adapter.addClass(cssClasses.SURFACE_SCRIM_HIDING);\n };\n /**\n * Handles `transitionend` event triggered when surface scrim animation is\n * finished.\n */\n MDCDialogFoundation.prototype.handleSurfaceScrimTransitionEnd = function () {\n this.adapter.removeClass(cssClasses.SURFACE_SCRIM_HIDING);\n this.adapter.removeClass(cssClasses.SURFACE_SCRIM_SHOWING);\n };\n MDCDialogFoundation.prototype.isOpen = function () {\n return this.dialogOpen;\n };\n MDCDialogFoundation.prototype.getEscapeKeyAction = function () {\n return this.escapeKeyAction;\n };\n MDCDialogFoundation.prototype.setEscapeKeyAction = function (action) {\n this.escapeKeyAction = action;\n };\n MDCDialogFoundation.prototype.getScrimClickAction = function () {\n return this.scrimClickAction;\n };\n MDCDialogFoundation.prototype.setScrimClickAction = function (action) {\n this.scrimClickAction = action;\n };\n MDCDialogFoundation.prototype.getAutoStackButtons = function () {\n return this.autoStackButtons;\n };\n MDCDialogFoundation.prototype.setAutoStackButtons = function (autoStack) {\n this.autoStackButtons = autoStack;\n };\n MDCDialogFoundation.prototype.getSuppressDefaultPressSelector = function () {\n return this.suppressDefaultPressSelector;\n };\n MDCDialogFoundation.prototype.setSuppressDefaultPressSelector = function (selector) {\n this.suppressDefaultPressSelector = selector;\n };\n MDCDialogFoundation.prototype.layout = function () {\n var _this = this;\n this.animFrame.request(AnimationKeys.POLL_LAYOUT_CHANGE, function () {\n _this.layoutInternal();\n });\n };\n /** Handles click on the dialog root element. */\n MDCDialogFoundation.prototype.handleClick = function (evt) {\n var isScrim = this.adapter.eventTargetMatches(evt.target, strings.SCRIM_SELECTOR);\n // Check for scrim click first since it doesn't require querying ancestors.\n if (isScrim && this.scrimClickAction !== '') {\n this.close(this.scrimClickAction);\n }\n else {\n var action = this.adapter.getActionFromEvent(evt);\n if (action) {\n this.close(action);\n }\n }\n };\n /** Handles keydown on the dialog root element. */\n MDCDialogFoundation.prototype.handleKeydown = function (evt) {\n var isEnter = evt.key === 'Enter' || evt.keyCode === 13;\n if (!isEnter) {\n return;\n }\n var action = this.adapter.getActionFromEvent(evt);\n if (action) {\n // Action button callback is handled in `handleClick`,\n // since space/enter keydowns on buttons trigger click events.\n return;\n }\n // `composedPath` is used here, when available, to account for use cases\n // where a target meant to suppress the default press behaviour\n // may exist in a shadow root.\n // For example, a textarea inside a web component:\n // <mwc-dialog>\n // <horizontal-layout>\n // #shadow-root (open)\n // <mwc-textarea>\n // #shadow-root (open)\n // <textarea></textarea>\n // </mwc-textarea>\n // </horizontal-layout>\n // </mwc-dialog>\n var target = evt.composedPath ? evt.composedPath()[0] : evt.target;\n var isDefault = this.suppressDefaultPressSelector ?\n !this.adapter.eventTargetMatches(target, this.suppressDefaultPressSelector) :\n true;\n if (isEnter && isDefault) {\n this.adapter.clickDefaultButton();\n }\n };\n /** Handles keydown on the document. */\n MDCDialogFoundation.prototype.handleDocumentKeydown = function (evt) {\n var isEscape = evt.key === 'Escape' || evt.keyCode === 27;\n if (isEscape && this.escapeKeyAction !== '') {\n this.close(this.escapeKeyAction);\n }\n };\n /**\n * Handles scroll event on the dialog's content element -- showing a scroll\n * divider on the header or footer based on the scroll position. This handler\n * should only be registered on full-screen dialogs with scrollable content.\n */\n MDCDialogFoundation.prototype.handleScrollEvent = function () {\n var _this = this;\n // Since scroll events can fire at a high rate, we throttle these events by\n // using requestAnimationFrame.\n this.animFrame.request(AnimationKeys.POLL_SCROLL_POS, function () {\n _this.toggleScrollDividerHeader();\n _this.toggleScrollDividerFooter();\n });\n };\n MDCDialogFoundation.prototype.layoutInternal = function () {\n if (this.autoStackButtons) {\n this.detectStackedButtons();\n }\n this.toggleScrollableClasses();\n };\n MDCDialogFoundation.prototype.handleAnimationTimerEnd = function () {\n this.animationTimer = 0;\n this.adapter.removeClass(cssClasses.OPENING);\n this.adapter.removeClass(cssClasses.CLOSING);\n };\n /**\n * Runs the given logic on the next animation frame, using setTimeout to\n * factor in Firefox reflow behavior.\n */\n MDCDialogFoundation.prototype.runNextAnimationFrame = function (callback) {\n var _this = this;\n cancelAnimationFrame(this.animationFrame);\n this.animationFrame = requestAnimationFrame(function () {\n _this.animationFrame = 0;\n clearTimeout(_this.animationTimer);\n _this.animationTimer = setTimeout(callback, 0);\n });\n };\n MDCDialogFoundation.prototype.detectStackedButtons = function () {\n // Remove the class first to let us measure the buttons' natural positions.\n this.adapter.removeClass(cssClasses.STACKED);\n var areButtonsStacked = this.adapter.areButtonsStacked();\n if (areButtonsStacked) {\n this.adapter.addClass(cssClasses.STACKED);\n }\n if (areButtonsStacked !== this.areButtonsStacked) {\n this.adapter.reverseButtons();\n this.areButtonsStacked = areButtonsStacked;\n }\n };\n MDCDialogFoundation.prototype.toggleScrollableClasses = function () {\n // Remove the class first to let us measure the natural height of the\n // content.\n this.adapter.removeClass(cssClasses.SCROLLABLE);\n if (this.adapter.isContentScrollable()) {\n this.adapter.addClass(cssClasses.SCROLLABLE);\n if (this.isFullscreen) {\n // If dialog is full-screen and scrollable, check if a scroll divider\n // should be shown.\n this.toggleScrollDividerHeader();\n this.toggleScrollDividerFooter();\n }\n }\n };\n MDCDialogFoundation.prototype.toggleScrollDividerHeader = function () {\n if (!this.adapter.isScrollableContentAtTop()) {\n this.adapter.addClass(cssClasses.SCROLL_DIVIDER_HEADER);\n }\n else if (this.adapter.hasClass(cssClasses.SCROLL_DIVIDER_HEADER)) {\n this.adapter.removeClass(cssClasses.SCROLL_DIVIDER_HEADER);\n }\n };\n MDCDialogFoundation.prototype.toggleScrollDividerFooter = function () {\n if (!this.adapter.isScrollableContentAtBottom()) {\n this.adapter.addClass(cssClasses.SCROLL_DIVIDER_FOOTER);\n }\n else if (this.adapter.hasClass(cssClasses.SCROLL_DIVIDER_FOOTER)) {\n this.adapter.removeClass(cssClasses.SCROLL_DIVIDER_FOOTER);\n }\n };\n return MDCDialogFoundation;\n}(MDCFoundation));\nexport { MDCDialogFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCDialogFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2017 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport { __extends, __values } from \"tslib\";\nimport { MDCComponent } from '@material/base/component';\nimport { FocusTrap } from '@material/dom/focus-trap';\nimport { closest, matches } from '@material/dom/ponyfill';\nimport { MDCRipple } from '@material/ripple/component';\nimport { MDCDialogFoundation } from './foundation';\nimport * as util from './util';\nvar strings = MDCDialogFoundation.strings;\nvar MDCDialog = /** @class */ (function (_super) {\n __extends(MDCDialog, _super);\n function MDCDialog() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n Object.defineProperty(MDCDialog.prototype, \"isOpen\", {\n get: function () {\n return this.foundation.isOpen();\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(MDCDialog.prototype, \"escapeKeyAction\", {\n get: function () {\n return this.foundation.getEscapeKeyAction();\n },\n set: function (action) {\n this.foundation.setEscapeKeyAction(action);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(MDCDialog.prototype, \"scrimClickAction\", {\n get: function () {\n return this.foundation.getScrimClickAction();\n },\n set: function (action) {\n this.foundation.setScrimClickAction(action);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(MDCDialog.prototype, \"autoStackButtons\", {\n get: function () {\n return this.foundation.getAutoStackButtons();\n },\n set: function (autoStack) {\n this.foundation.setAutoStackButtons(autoStack);\n },\n enumerable: false,\n configurable: true\n });\n MDCDialog.attachTo = function (root) {\n return new MDCDialog(root);\n };\n MDCDialog.prototype.initialize = function (focusTrapFactory) {\n var e_1, _a;\n if (focusTrapFactory === void 0) { focusTrapFactory = function (el, focusOptions) {\n return new FocusTrap(el, focusOptions);\n }; }\n var container = this.root.querySelector(strings.CONTAINER_SELECTOR);\n if (!container) {\n throw new Error(\"Dialog component requires a \" + strings.CONTAINER_SELECTOR + \" container element\");\n }\n this.container = container;\n this.content =\n this.root.querySelector(strings.CONTENT_SELECTOR);\n this.buttons = [].slice.call(this.root.querySelectorAll(strings.BUTTON_SELECTOR));\n this.defaultButton = this.root.querySelector(\"[\" + strings.BUTTON_DEFAULT_ATTRIBUTE + \"]\");\n this.focusTrapFactory = focusTrapFactory;\n this.buttonRipples = [];\n try {\n for (var _b = __values(this.buttons), _c = _b.next(); !_c.done; _c = _b.next()) {\n var buttonEl = _c.value;\n this.buttonRipples.push(new MDCRipple(buttonEl));\n }\n }\n catch (e_1_1) { e_1 = { error: e_1_1 }; }\n finally {\n try {\n if (_c && !_c.done && (_a = _b.return)) _a.call(_b);\n }\n finally { if (e_1) throw e_1.error; }\n }\n };\n MDCDialog.prototype.initialSyncWithDOM = function () {\n var _this = this;\n this.focusTrap = util.createFocusTrapInstance(this.container, this.focusTrapFactory, this.getInitialFocusEl() || undefined);\n this.handleClick = this.foundation.handleClick.bind(this.foundation);\n this.handleKeydown = this.foundation.handleKeydown.bind(this.foundation);\n this.handleDocumentKeydown =\n this.foundation.handleDocumentKeydown.bind(this.foundation);\n // this.handleLayout = this.layout.bind(this);\n this.handleOpening = function () {\n document.addEventListener('keydown', _this.handleDocumentKeydown);\n };\n this.handleClosing = function () {\n document.removeEventListener('keydown', _this.handleDocumentKeydown);\n };\n this.listen('click', this.handleClick);\n this.listen('keydown', this.handleKeydown);\n this.listen(strings.OPENING_EVENT, this.handleOpening);\n this.listen(strings.CLOSING_EVENT, this.handleClosing);\n };\n MDCDialog.prototype.destroy = function () {\n this.unlisten('click', this.handleClick);\n this.unlisten('keydown', this.handleKeydown);\n this.unlisten(strings.OPENING_EVENT, this.handleOpening);\n this.unlisten(strings.CLOSING_EVENT, this.handleClosing);\n this.handleClosing();\n this.buttonRipples.forEach(function (ripple) {\n ripple.destroy();\n });\n _super.prototype.destroy.call(this);\n };\n MDCDialog.prototype.layout = function () {\n this.foundation.layout();\n };\n MDCDialog.prototype.open = function () {\n this.foundation.open();\n };\n MDCDialog.prototype.close = function (action) {\n if (action === void 0) { action = ''; }\n this.foundation.close(action);\n };\n MDCDialog.prototype.getDefaultFoundation = function () {\n var _this = this;\n // DO NOT INLINE this variable. For backward compatibility, foundations take a Partial<MDCFooAdapter>.\n // To ensure we don't accidentally omit any methods, we need a separate, strongly typed adapter variable.\n var adapter = {\n addBodyClass: function (className) { return document.body.classList.add(className); },\n addClass: function (className) { return _this.root.classList.add(className); },\n areButtonsStacked: function () { return util.areTopsMisaligned(_this.buttons); },\n clickDefaultButton: function () {\n if (_this.defaultButton && !_this.defaultButton.disabled) {\n _this.defaultButton.click();\n }\n },\n eventTargetMatches: function (target, selector) {\n return target ? matches(target, selector) : false;\n },\n getActionFromEvent: function (evt) {\n if (!evt.target) {\n return '';\n }\n var element = closest(evt.target, \"[\" + strings.ACTION_ATTRIBUTE + \"]\");\n return element && element.getAttribute(strings.ACTION_ATTRIBUTE);\n },\n getInitialFocusEl: function () { return _this.getInitialFocusEl(); },\n hasClass: function (className) { return _this.root.classList.contains(className); },\n isContentScrollable: function () { return util.isScrollable(_this.content); },\n notifyClosed: function (action) { return _this.emit(strings.CLOSED_EVENT, action ? { action: action } : {}); },\n notifyClosing: function (action) { return _this.emit(strings.CLOSING_EVENT, action ? { action: action } : {}); },\n notifyOpened: function () { return _this.emit(strings.OPENED_EVENT, {}); },\n notifyOpening: function () { return _this.emit(strings.OPENING_EVENT, {}); },\n releaseFocus: function () {\n _this.focusTrap.releaseFocus();\n },\n removeBodyClass: function (className) { return document.body.classList.remove(className); },\n removeClass: function (className) { return _this.root.classList.remove(className); },\n reverseButtons: function () {\n _this.buttons.reverse();\n _this.buttons.forEach(function (button) {\n button.parentElement.appendChild(button);\n });\n },\n trapFocus: function () {\n _this.focusTrap.trapFocus();\n },\n registerContentEventHandler: function (evt, handler) {\n if (_this.content instanceof HTMLElement) {\n _this.content.addEventListener(evt, handler);\n }\n },\n deregisterContentEventHandler: function (evt, handler) {\n if (_this.content instanceof HTMLElement) {\n _this.content.removeEventListener(evt, handler);\n }\n },\n isScrollableContentAtTop: function () {\n return util.isScrollAtTop(_this.content);\n },\n isScrollableContentAtBottom: function () {\n return util.isScrollAtBottom(_this.content);\n },\n registerWindowEventHandler: function (evt, handler) {\n window.addEventListener(evt, handler);\n },\n deregisterWindowEventHandler: function (evt, handler) {\n window.removeEventListener(evt, handler);\n },\n };\n return new MDCDialogFoundation(adapter);\n };\n MDCDialog.prototype.getInitialFocusEl = function () {\n return this.root.querySelector(\"[\" + strings.INITIAL_FOCUS_ATTRIBUTE + \"]\");\n };\n return MDCDialog;\n}(MDCComponent));\nexport { MDCDialog };\n//# sourceMappingURL=component.js.map","@use '../../style/functions';\n@use '../../style/mixins';\n\n@use '@material/dialog';\n\n/**\n * @prop --dialog-width: Width of the dialog.\n * @prop --dialog-height: Height of the dialog.\n * @prop --dialog-z-index: z-index of the dialog container, including the scrim.\n * @prop --dialog-heading-title-color: Color of the title.\n * @prop --dialog-heading-subtitle-color: Color of the subtitle.\n * @prop --dialog-heading-supporting-text-color: Color of the supporting text.\n * @prop --dialog-heading-icon-color: Color of the icon.\n * @prop --dialog-heading-icon-background-color: Background color of the icon when displayed as a badge.\n * @prop --dialog-max-width: Max width of the dialog.\n * @prop --dialog-max-height: Max height of the dialog.\n * @prop --dialog-padding-top-bottom: Padding on top and bottom of dialog content. Affects the height of fade-out effects on top and bottom edges when the content is scrollable and has overflowed out of the content area. Defaults to `1.5rem`. Note that if you use this variable and set it to numbers smaller than 1rem, you will loose the fade-out effects on the edges. If you have set these paddings to `0`, losing the fade out effects should be however fine for your use case! Because in such a case your intention is to handle the `overflow` internally in the component that is displayed in the dialog's content.\n * @prop --dialog-padding-left-right: Padding on the sides of dialog content. Defaults to `1.25rem`.\n */\n\n:host {\n --dialog-background-color: var(--lime-elevated-surface-background-color);\n --header-heading-color: var(--dialog-heading-title-color);\n --header-subheading-color: var(--dialog-heading-subtitle-color);\n --header-supporting-text-color: var(--dialog-heading-supporting-text-color);\n --header-icon-color: var(--dialog-heading-icon-color);\n --header-icon-background-color: var(--dialog-heading-icon-background-color);\n}\n\n$responsive-body-padding: 3vw; // 3% of viewport's width\n\n@include dialog.core-styles;\n\n.mdc-dialog__content {\n // As long as this component is depended on MDC,\n // we need to force it to be font-agnostic.\n // When MDC-dependency is removed, this block can also be removed.\n // However, on removal of MDC-dependency, we should also make sure to check\n // other font-related styles that might be set by MDC,\n // such as `letter-spacing` or `font-size`.\n font-family: inherit;\n font-size: var(--limel-theme-default-font-size);\n}\n\n.mdc-dialog {\n @include dialog.max-width(16000px, dialog.$margin);\n\n z-index: var(--dialog-z-index, dialog.$z-index);\n padding: env(safe-area-inset-top) env(safe-area-inset-right)\n env(safe-area-inset-bottom) env(safe-area-inset-left);\n\n &.full-screen {\n @include dialog.max-height(16000px, dialog.$margin);\n .mdc-dialog__container {\n height: 100%;\n width: 100%;\n\n .mdc-dialog__surface {\n height: 100%;\n width: 100%;\n }\n }\n }\n\n .mdc-dialog__scrim {\n background-color: rgba(var(--color-black), 0.4);\n }\n\n .mdc-dialog__container {\n height: 100%;\n width: var(--dialog-width, auto);\n }\n\n .mdc-dialog__surface {\n width: var(--dialog-width, auto);\n height: var(--dialog-height, auto);\n background-color: var(--dialog-background-color);\n box-shadow: var(--shadow-depth-64);\n\n max-width: var(--dialog-max-width, calc(100vw - 2rem));\n max-height: var(--dialog-max-height, calc(100% - 2rem));\n border-radius: 0.75rem;\n }\n\n .mdc-dialog__content {\n --limel-top-edge-fade-height: var(--dialog-padding-top-bottom, 1.5rem);\n --limel-bottom-edge-fade-height: var(\n --dialog-padding-top-bottom,\n 1.5rem\n );\n @include mixins.fade-out-overflowed-content-on-edges(vertically);\n\n color: var(--limel-theme-on-surface-color);\n padding-left: var(\n --dialog-padding-left-right,\n min(1.25rem, $responsive-body-padding)\n );\n padding-right: var(\n --dialog-padding-left-right,\n min(1.25rem, $responsive-body-padding)\n );\n }\n}\n\n#initialFocusElement {\n position: absolute;\n opacity: 0;\n pointer-events: none;\n z-index: -1;\n}\n\nslot[name='header'] {\n display: none;\n}\n\nslot[name='button'] {\n display: flex;\n gap: 0.5rem; // Makes sure buttons get some default distance\n width: 100%;\n justify-content: flex-end;\n}\n\nfooter.mdc-dialog__actions {\n min-height: unset;\n padding: 0.375rem; // 6px\n}\n\n@media screen and (max-width: #{mixins.$narrow-dialog-breakpoint}) {\n slot[name='button'] {\n flex-direction: column-reverse;\n }\n .mdc-dialog__actions {\n padding: min(1.5rem, $responsive-body-padding);\n padding-top: 1rem;\n }\n}\n","import { DialogHeading, ClosingActions } from './dialog.types';\nimport { MDCDialog } from '@material/dialog';\nimport {\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Prop,\n Watch,\n} from '@stencil/core';\nimport { isEqual } from 'lodash-es';\nimport { dispatchResizeEvent } from '../../util/dispatch-resize-event';\nimport { createRandomString } from '../../util/random-string';\n\n/**\n * :::note\n * Regarding the `close` event: When putting other elements that emit `close`\n * events inside a dialog, those events must be caught and stopped inside the\n * dialog. If not, they will bubble to the event handler listening for `close`\n * events on the dialog, which will close the dialog too.\n *\n * See the example _Nested `close` events_.\n * :::\n *\n * :::important\n * Are you developing for\n * [Lime CRM](https://www.lime-technologies.com/en/lime-crm/)? Please note that\n * you should use the [DialogRenderer](https://lundalogik.github.io/lime-web-components/versions/latest/interfaces/DialogRenderer.html)\n * from Lime Web Components to open dialogs in Lime CRM.\n * :::\n *\n * @exampleComponent limel-example-dialog\n * @exampleComponent limel-example-dialog-nested-close-events\n * @exampleComponent limel-example-dialog-heading\n * @exampleComponent limel-example-dialog-heading-actions\n * @exampleComponent limel-example-dialog-form\n * @exampleComponent limel-example-dialog-size\n * @exampleComponent limel-example-dialog-fullscreen\n * @exampleComponent limel-example-dialog-closing-actions\n * @exampleComponent limel-example-dialog-action-buttons\n * @slot - Content to put inside the dialog\n * @slot header-actions - The dialog header buttons\n * @slot button - The dialog buttons\n */\n@Component({\n tag: 'limel-dialog',\n shadow: true,\n styleUrl: 'dialog.scss',\n})\nexport class Dialog {\n /**\n * The heading for the dialog, if any.\n */\n @Prop()\n public heading: string | DialogHeading;\n\n /**\n * Set to `true` to make the dialog \"fullscreen\".\n */\n @Prop({ reflect: true })\n public fullscreen = false;\n\n /**\n * `true` if the dialog is open, `false` otherwise.\n */\n @Prop({ mutable: true, reflect: true })\n public open = false;\n\n /**\n * Defines which action triggers a close-event.\n */\n @Prop({ reflect: true })\n public closingActions: ClosingActions = {\n escapeKey: true,\n scrimClick: true,\n };\n /**\n * Emitted when the dialog is closed from inside the component.\n * (*Not* emitted when the consumer sets the `open`-property to `false`.)\n */\n @Event()\n private close: EventEmitter<void>;\n\n /**\n * Emitted when the dialog is in the process of being closed.\n */\n @Event()\n private closing: EventEmitter<void>;\n\n @Element()\n private host: HTMLLimelDialogElement;\n\n private mdcDialog: MDCDialog;\n\n private id: string;\n\n constructor() {\n this.handleMdcOpened = this.handleMdcOpened.bind(this);\n this.handleMdcClosed = this.handleMdcClosed.bind(this);\n this.handleMdcClosing = this.handleMdcClosing.bind(this);\n }\n\n public connectedCallback() {\n this.initialize();\n }\n\n public componentWillLoad() {\n this.id = createRandomString();\n }\n\n public componentDidLoad() {\n this.initialize();\n }\n\n private initialize() {\n const element = this.host.shadowRoot.querySelector('.mdc-dialog');\n if (!element) {\n return;\n }\n\n this.mdcDialog = new MDCDialog(element);\n if (this.open) {\n this.mdcDialog.open();\n }\n\n this.mdcDialog.listen('MDCDialog:opened', this.handleMdcOpened);\n this.mdcDialog.listen('MDCDialog:closed', this.handleMdcClosed);\n this.mdcDialog.listen('MDCDialog:closing', this.handleMdcClosing);\n\n this.setClosingActions();\n }\n\n public disconnectedCallback() {\n this.mdcDialog.unlisten('MDCDialog:opened', this.handleMdcOpened);\n this.mdcDialog.unlisten('MDCDialog:closed', this.handleMdcClosed);\n this.mdcDialog.unlisten('MDCDialog:closing', this.handleMdcClosing);\n this.mdcDialog.destroy();\n }\n\n public render() {\n return (\n <div\n class={{\n 'mdc-dialog': true,\n 'full-screen': !!this.fullscreen,\n }}\n role=\"alertdialog\"\n aria-modal=\"true\"\n aria-labelledby={'limel-dialog-title-' + this.id}\n aria-describedby={'limel-dialog-content-' + this.id}\n >\n <input hidden={true} id=\"initialFocusEl\" />\n <div class=\"mdc-dialog__container\">\n <div class=\"mdc-dialog__surface\">\n {/*\n The `initialFocusElement` below is needed to make\n focus trapping work. At the time of writing, the\n focusable elements inside the slots are not\n detected, so we supply our own hidden element for\n the focus trap to use. Read more here:\n https://github.com/material-components/material-components-web/tree/v11.0.0/packages/mdc-dialog#handling-focus-trapping\n */}\n <input type=\"button\" id=\"initialFocusElement\" />\n {this.renderHeading()}\n <div\n class=\"mdc-dialog__content\"\n id={'limel-dialog-content-' + this.id}\n >\n <slot />\n </div>\n {this.renderFooter()}\n </div>\n </div>\n <div class=\"mdc-dialog__scrim\" />\n </div>\n );\n }\n\n @Watch('open')\n protected watchHandler(newValue: boolean, oldValue: boolean) {\n if (oldValue === newValue) {\n return;\n }\n\n if (!this.mdcDialog) {\n return;\n }\n\n if (newValue) {\n this.mdcDialog.open();\n } else {\n this.mdcDialog.close();\n }\n }\n\n @Watch('closingActions')\n protected closingActionsChanged(\n newValue: ClosingActions,\n oldValue: ClosingActions\n ) {\n if (isEqual(newValue, oldValue)) {\n return;\n }\n\n this.setClosingActions();\n }\n\n private handleMdcOpened() {\n // When the opening-animation has completed, dispatch a\n // resize-event so that any content that depends on\n // javascript for layout has a chance to update to the\n // final layout of the dialog. /Ads\n const waitForUiToRender = 100;\n setTimeout(dispatchResizeEvent, waitForUiToRender);\n }\n\n private handleMdcClosed() {\n if (this.open) {\n this.close.emit();\n }\n\n this.open = false;\n }\n\n private handleMdcClosing() {\n this.closing.emit();\n }\n\n private isBadgeHeading(\n heading: string | DialogHeading\n ): heading is DialogHeading {\n return typeof heading === 'object' && !!heading.title && !!heading.icon;\n }\n\n private renderHeading() {\n if (this.isBadgeHeading(this.heading)) {\n const { title, subtitle, supportingText, icon } = this.heading;\n\n return (\n <limel-header\n icon={icon}\n heading={title}\n subheading={subtitle}\n supportingText={supportingText}\n >\n <slot name=\"header-actions\" slot=\"actions\" />\n </limel-header>\n );\n } else if (typeof this.heading === 'string') {\n return <limel-header heading={this.heading}></limel-header>;\n }\n\n return null;\n }\n\n private renderFooter() {\n return (\n <footer class=\"mdc-dialog__actions\">\n <slot name=\"button\" />\n </footer>\n );\n }\n\n private setClosingActions() {\n this.mdcDialog.scrimClickAction = '';\n if (this.closingActions.scrimClick) {\n this.mdcDialog.scrimClickAction = 'close';\n }\n\n this.mdcDialog.escapeKeyAction = '';\n if (this.closingActions.escapeKey) {\n this.mdcDialog.escapeKeyAction = 'close';\n }\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;GAsBO,SAASA,EAAwBC,EAAWC,EAAkBC,GACjE,OAAOD,EAAiBD,EAAW,CAAEE,eAAgBA,GACzD,CACO,SAASC,EAAaC,GACzB,OAAOA,EAAKA,EAAGC,aAAeD,EAAGE,aAAe,KACpD,CAOO,SAASC,EAAcH,GAC1B,OAAOA,EAAKA,EAAGI,YAAc,EAAI,KACrC,CAOO,SAASC,EAAiBL,GAC7B,OAAOA,EAAKM,KAAKC,KAAKP,EAAGC,aAAeD,EAAGI,aAAeJ,EAAGQ,aACzD,KACR,CACO,SAASC,EAAkBC,GAC9B,IAAIC,EAAO,IAAIC,IACf,GAAGC,QAAQC,KAAKJ,GAAK,SAAUV,GAAM,OAAOW,EAAKI,IAAIf,EAAGgB,UAAW,IACnE,OAAOL,EAAKM,KAAO,CACvB;;;;;;;;;;;;;;;;;;;;;;GC7BA,IAAIC,EAAuB,yBAQ3B,IAAIC,EAA2B,WAC3B,SAASA,EAAUC,EAAMC,GACrB,GAAIA,SAAiB,EAAG,CAAEA,EAAU,EAAG,CACvCC,KAAKF,KAAOA,EACZE,KAAKD,QAAUA,EAEfC,KA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