UNPKG

jb-notification

Version:
3 lines (2 loc) 1.34 kB
!function(n,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((n="undefined"!=typeof globalThis?globalThis:n||self).JBNotificationWrapper={})}(this,(function(n){"use strict";class e extends HTMLElement{constructor(){super(),this.initWebComponent()}initWebComponent(){const n=this.attachShadow({mode:"open"}),e=document.createElement("template");e.innerHTML='<style>.jb-notification-wrapper-web-component {\n position: var(--jb-notification-wrapper-position, absolute);\n box-sizing: border-box;\n overflow: hidden;\n display: flex;\n align-items: center;\n flex-direction: column;\n gap: 0.5rem;\n width: 100vw;\n height: 100vh;\n padding-top: var(--jb-notification-wrapper-padding-top, 64px);\n z-index: 9999;\n top: 0;\n left: 0;\n pointer-events: none;\n}</style>\n<div class="jb-notification-wrapper-web-component">\r\n <slot></slot>\r\n</div>',n.appendChild(e.content.cloneNode(!0))}static get observedAttributes(){return["x-position","y-position"]}attributeChangedCallback(n,e,t){this.onAttributeChange(n,t)}onAttributeChange(n,e){}}!customElements.get("jb-notification-wrapper")&&window.customElements.define("jb-notification-wrapper",e),n.JBNotificationWrapperWebComponent=e})); //# sourceMappingURL=jb-notification-wrapper.umd.js.map