@momentum-ui/web-components 3.0.0-alpha.3 → 3.0.0-alpha.4

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 (36) hide show
  1. package/dist/1323.js +1 -1
  2. package/dist/2555.js +7 -7
  3. package/dist/591.js +1 -1
  4. package/dist/6273.js +2 -2
  5. package/dist/6396.js +1 -5
  6. package/dist/6408.js +2 -2
  7. package/dist/8210.js +1 -1
  8. package/dist/8345.js +1 -1
  9. package/dist/comp/md-advance-list-entry.js +9 -9
  10. package/dist/comp/md-alert-banner-entry.js +7 -7
  11. package/dist/comp/md-alert-entry.js +2 -8
  12. package/dist/comp/md-audio-player-entry.js +8 -8
  13. package/dist/comp/md-checkbox-entry.js +1 -1
  14. package/dist/comp/md-coachmark-popover-entry.js +4 -4
  15. package/dist/comp/md-country-code-picker-entry.js +1 -1
  16. package/dist/comp/md-datepicker-entry.js +2 -2
  17. package/dist/comp/md-dropdown-entry.js +1 -1
  18. package/dist/comp/md-floating-minimize-entry.js +2 -2
  19. package/dist/comp/md-floating-modal-entry.js +2 -2
  20. package/dist/comp/md-grabber-entry.js +6 -6
  21. package/dist/comp/md-input-entry.js +2 -2
  22. package/dist/comp/md-label-entry.js +1 -5
  23. package/dist/comp/md-menu-overlay-entry.js +1 -1
  24. package/dist/comp/md-modal-entry.js +7 -7
  25. package/dist/comp/md-phone-input-entry.js +5 -5
  26. package/dist/comp/md-popover-entry.js +4 -4
  27. package/dist/comp/md-tabs-entry.js +3 -3
  28. package/dist/comp/md-task-item-entry.js +1 -1
  29. package/dist/comp/md-timepicker-entry.js +4 -4
  30. package/dist/index-entry.js +57 -67
  31. package/dist/types/components/advance-list/AdvanceList.d.ts +1 -0
  32. package/dist/types/components/alert-banner/AlertBanner.d.ts +1 -0
  33. package/dist/types/components/combobox/ComboBox.d.ts +1 -1
  34. package/dist/types/components/popover/Popover.d.ts +4 -0
  35. package/dist/types/components/popover/Popover.utils.d.ts +4 -0
  36. package/package.json +1 -1
@@ -50,15 +50,15 @@
50
50
  ${this.renderHeader()} ${this.renderBody()} ${this.renderFooter()}
51
51
  </div>
52
52
  </md-popover>
53
- `}};h([(0,l.property)({type:String})],t.prototype,"placement",void 0),h([(0,l.property)({type:String,reflect:!0})],t.prototype,"triggerID",void 0),h([(0,l.property)({type:String})],t.prototype,"headerIconName",void 0),h([(0,l.property)({type:String})],t.prototype,"header",void 0),h([(0,l.property)({type:String})],t.prototype,"message",void 0),h([(0,l.property)({type:Boolean})],t.prototype,"show",void 0),h([(0,l.property)({type:Boolean,reflect:!0,attribute:"hide-close-button"})],t.prototype,"hideCloseButton",void 0),h([(0,l.property)({type:String})],t.prototype,"primaryButton",void 0),h([(0,l.property)({type:String})],t.prototype,"secondaryButton",void 0),h([(0,l.property)({type:String})],t.prototype,"linkText",void 0),h([(0,l.property)({type:String})],t.prototype,"href",void 0),h([(0,l.query)(".md-coachmark__trigger-component")],t.prototype,"triggerComponent",void 0),h([(0,l.query)(".md-coachmark__popper")],t.prototype,"popper",void 0),t=h([(0,o.w)("md-coachmark-popover")],t),e.ELEMENT=t}(r||(r={}))},32022:e=>{e.exports=s},60554:e=>{e.exports=n},70429:e=>{e.exports=t},71128:(e,t,i)=>{i(96798),i(61200);var r=i(31890),o=i(28373),s=i(66677),n=i(5784),l=i(87161),a=i(70429),p=i(20291),h=i(68419),c=i(36365),d=i(3998),u=i(33759),v=i(86210),m=function(e,t,i,r){var o,s=arguments.length,n=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,r);else for(var l=e.length-1;l>=0;l--)(o=e[l])&&(n=(s<3?o(n):s>3?o(t,i,n):o(t,i))||n);return s>3&&n&&Object.defineProperty(t,i,n),n},g=function(e,t,i,r){return new(i||(i=Promise))(function(o,s){function n(e){try{a(r.next(e))}catch(e){s(e)}}function l(e){try{a(r.throw(e))}catch(e){s(e)}}function a(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(n,l)}a((r=r.apply(e,t||[])).next())})};let y=class extends((0,o.d)(l.LitElement)){set controller(e){e?(e.show=(e=!1)=>this.showPopover(e),e.hide=()=>this.hidePopover(),e.toggle=()=>this.togglePopoverVisible(),e.isVisible=()=>this.visible,this._controller=e):this._controller=null}get controller(){return this._controller}constructor(){super(),this.id="",this.triggerID="",this.trigger=h.zY.TRIGGER,this.placement=h.zY.PLACEMENT,this.strategy=h.zY.STRATEGY,this.color=h.zY.COLOR,this.visible=h.zY.VISIBLE,this.offset=h.zY.OFFSET,this.focusTrap=h.zY.FOCUS_TRAP,this.preventScroll=h.zY.PREVENT_SCROLL,this.showArrow=h.zY.ARROW,this.closeButton=h.zY.CLOSE_BUTTON,this.interactive=h.zY.INTERACTIVE,this.delay=h.zY.DELAY,this.hideOnEscape=h.zY.HIDE_ON_ESCAPE,this.hideOnBlur=h.zY.HIDE_ON_BLUR,this.hideOnWindowBlur=h.zY.HIDE_ON_WINDOW_BLUR,this.hideOnOutsideClick=h.zY.HIDE_ON_CLICK_OUTSIDE,this.focusBackToTrigger=h.zY.FOCUS_BACK,this.backdrop=h.zY.BACKDROP,this.flip=h.zY.FLIP,this.size=h.zY.SIZE,this.zIndex=h.zY.Z_INDEX,this.appendTo="",this.closeButtonAriaLabel=null,this.role=h.zY.ROLE,this.ariaLabelledby=null,this.ariaDescribedby=null,this.disableAriaExpanded=h.zY.DISABLE_ARIA_EXPANDED,this.animationFrame=h.zY.ANIMATION_FRAME,this._controller=null,this.arrowElement=null,this.triggerElement=null,this.hoverTimer=null,this.isTriggerClicked=!1,this.openDelay=0,this.closeDelay=0,this.backdropElement=null,this.useLegacyFindFocusable=()=>!1,this.cleanupAutoUpdate=null,this.previousActiveElement=null,this.onOutsidePopoverClick=e=>{const t=e.composedPath();this.triggerElement&&t.includes(this.triggerElement)||t.includes(this)||d.S.shouldDeferToTopForOutsideClick(this)||this.hideThisPopover()},this.hideThisPopover=()=>{setTimeout(()=>{this.visible=!1,this.isTriggerClicked=!1,this.utils.handleAppendTo(!1)},this.closeDelay)},this.onEscapeKeydown=e=>{this.visible&&"Escape"===e.code&&(e.preventDefault(),this.hidePopover())},this.onPopoverFocusOut=e=>{const t=e.relatedTarget;!t||this.isElementInPopover(t)?t||setTimeout(()=>{const e=(0,s.dw)();this.isElementInPopover(e)||this.hidePopover()},0):this.hidePopover()},this.handleWindowBlurEvent=()=>{this.visible&&this.hidePopover()},this.startCloseDelay=()=>{if(this.interactive){if(this.isTriggerClicked)return;this.hoverTimer=window.setTimeout(()=>{this.visible=!1},this.closeDelay)}else this.hidePopover()},this.cancelCloseDelay=()=>{this.hoverTimer&&(clearTimeout(this.hoverTimer),this.hoverTimer=null)},this.showPopover=(e=!1)=>{this.cancelCloseDelay(),e&&this.openDelay>0?setTimeout(()=>{this.utils.handleAppendTo(!0),this.visible=!0},this.openDelay):(this.utils.handleAppendTo(!0),this.visible=!0)},this.hidePopover=()=>{d.S.peek()===this&&setTimeout(()=>{this.visible=!1,this.isTriggerClicked=!1,this.utils.handleAppendTo(!1)},this.closeDelay)},this.togglePopoverVisible=()=>{this.isTriggerClicked?this.hidePopover():(this.showPopover(),this.isTriggerClicked=!0)},this.onMouseEnterTrigger=()=>{this.trigger.includes("mouseenter")&&(this.visible||(this.previousActiveElement=(0,s.dw)()),this.showPopover(!0))},this.onFocusInTrigger=()=>{this.trigger.includes("focusin")&&this.showPopover(!1)},this.onTriggerClick=e=>{this.trigger.includes("mouseenter")&&this.isMouseOverTrigger(e)||this.togglePopoverVisible()},this.utils=new u.h(this),this.preventClickOutside=!0}firstUpdated(e){const t=Object.create(null,{firstUpdated:{get:()=>super.firstUpdated}});return g(this,void 0,void 0,function*(){t.firstUpdated.call(this,e),[this.openDelay,this.closeDelay]=this.utils.setupDelay(),this.utils.setupAccessibility(),this.style.zIndex=`${this.zIndex}`,c.T.onCreatedPopover(this),this.visible&&(this.utils.handleAppendTo(!0),this.positionPopover(),yield this.handleCreatePopoverFirstUpdate())})}disconnectedCallback(){const e=Object.create(null,{disconnectedCallback:{get:()=>super.disconnectedCallback}});return g(this,void 0,void 0,function*(){e.disconnectedCallback.call(this),this.cleanupAutoUpdate&&(this.cleanupAutoUpdate(),this.cleanupAutoUpdate=null),this._controller=null,this.previousActiveElement=null,this.removeEventListeners(),c.T.onDestroyedPopover(this),d.S.remove(this)})}setupTriggerListener(){if(!this.triggerID)return;const e=this.getRootNode();if(this.triggerElement=(0,s.qi)(`[id="${this.triggerID}"]`,e),!this.triggerElement){const t=null==e?void 0:e.host;if(t){const e=t.querySelector("[slot]");(null==e?void 0:e.id)===this.triggerID&&(this.triggerElement=e)}}if(this.triggerElement){if("mouseenter"===this.trigger&&(this.interactive?this.trigger="mouseenter click":this.trigger="mouseenter focusin"),this.trigger.includes("click")&&this.triggerElement.addEventListener("click",this.onTriggerClick),this.trigger.includes("mouseenter")){const e=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.addEventListener("mouseenter",this.onMouseEnterTrigger),this.triggerElement.addEventListener("mouseleave",this.startCloseDelay),this.addEventListener("mouseenter",this.cancelCloseDelay),this.addEventListener("mouseleave",this.startCloseDelay),null==e||e.addEventListener("mouseenter",this.cancelCloseDelay)}this.trigger.includes("focusin")&&(this.triggerElement.addEventListener("focusin",this.onFocusInTrigger),this.interactive||this.triggerElement.addEventListener("focusout",this.hidePopover)),this.addEventListener("focus-trap-exit",this.hidePopover)}}removeEventListeners(){if(!this.triggerElement)return;const e=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.removeEventListener("click",this.onTriggerClick),this.triggerElement.removeEventListener("mouseenter",this.onMouseEnterTrigger),this.triggerElement.removeEventListener("mouseleave",this.hidePopover),this.removeEventListener("mouseenter",this.cancelCloseDelay),this.removeEventListener("mouseleave",this.startCloseDelay),this.triggerElement.removeEventListener("focusin",this.onFocusInTrigger),this.triggerElement.removeEventListener("focusout",this.hidePopover),null==e||e.removeEventListener("mouseenter",this.cancelCloseDelay),this.removeEventListener("focus-trap-exit",this.hidePopover)}updated(e){const t=Object.create(null,{updated:{get:()=>super.updated}});return g(this,void 0,void 0,function*(){if(t.updated.call(this,e),e.has("visible")){const t=e.get("visible")||!1;yield this.isOpenUpdated(t,this.visible),this.utils.updateAriaExpandedAttribute()}if(e.has("placement")&&this.setAttribute("placement",Object.values(h.ME).includes(this.placement)?this.placement:h.zY.PLACEMENT),e.has("delay")&&([this.openDelay,this.closeDelay]=this.utils.setupDelay()),e.has("trigger")){const e=this.trigger.split(" ").filter(e=>Object.values(h.tr).includes(e));this.setAttribute("trigger",e.length>0?this.trigger:h.zY.TRIGGER),this.removeEventListeners(),this.setupTriggerListener()}e.has("triggerID")&&(this.removeEventListeners(),this.setupTriggerListener(),this.utils.setupAccessibility()),e.has("color")&&this.setAttribute("color",Object.values(h.o$).includes(this.color)?this.color:h.zY.COLOR),e.has("zIndex")&&this.setAttribute("z-index",`${this.zIndex}`),(e.has("interactive")||e.has("aria-label")||e.has("aria-labelledby"))&&this.utils.setupAccessibility(),e.has("disableAriaExpanded")&&this.utils.updateAriaExpandedAttribute(),e.has("interactive")&&this.utils.updateAriaHasPopupAttribute()})}isElementInPopover(e){return!!e&&(!!this.contains(e)||(0,s.QZ)("md-popover",e)===this)}isOpenUpdated(e,t){const i=Object.create(null,{preventScroll:{get:()=>super.preventScroll,set:e=>super.preventScroll=e}});return g(this,void 0,void 0,function*(){var r,o,s,n;if(e!==t&&this.triggerElement)if(t)d.S.peek()!==this&&d.S.push(this),i.preventScroll=this.preventScroll,this.focusTrap&&(null===(r=this.activateFocusTrap)||void 0===r||r.call(this)),this.backdrop&&(this.utils.createBackdrop(),this.triggerElement.style.zIndex=`${this.zIndex}`),this.positionPopover(),yield this.handleCreatePopoverFirstUpdate(),this.hideOnBlur&&(this.addEventListener("focusout",this.onPopoverFocusOut),"click"===this.trigger&&(this.triggerElement.style.pointerEvents="none")),this.hideOnWindowBlur&&window.addEventListener("blur",this.handleWindowBlurEvent),this.hideOnOutsideClick&&document.addEventListener("click",this.onOutsidePopoverClick),this.hideOnEscape&&document.addEventListener("keydown",this.onEscapeKeydown),c.T.onShowPopover(this);else{if(this.cleanupAutoUpdate&&(this.cleanupAutoUpdate(),this.cleanupAutoUpdate=null),d.S.removeItem(this),this.backdropElement&&(null===(o=this.backdropElement)||void 0===o||o.remove(),this.backdropElement=null),this.hideOnBlur&&(this.removeEventListener("focusout",this.onPopoverFocusOut),"click"===this.trigger&&(this.triggerElement.style.pointerEvents="")),this.hideOnWindowBlur&&window.removeEventListener("blur",this.handleWindowBlurEvent),this.hideOnOutsideClick&&document.removeEventListener("click",this.onOutsidePopoverClick),this.hideOnEscape&&document.removeEventListener("keydown",this.onEscapeKeydown),null===(s=this.deactivateFocusTrap)||void 0===s||s.call(this),this.disableAriaExpanded||this.triggerElement.removeAttribute("aria-expanded"),this.interactive){const e=this.triggerElement.getAttribute("aria-haspopup");"dialog"!==e&&"alertdialog"!==e||this.triggerElement.removeAttribute("aria-haspopup")}this.focusBackToTrigger&&(this.previousActiveElement instanceof HTMLElement?this.previousActiveElement.focus():null===(n=this.setFocusOnDeepestNestedElement)||void 0===n||n.call(this,this.triggerElement)),this.previousActiveElement=null,c.T.onHidePopover(this)}})}isRectOverTrigger(e,t){if(this.triggerElement&&"undefined"!=typeof window&&"undefined"!=typeof document){const i=this.triggerElement.getBoundingClientRect();return e>=i.left&&e<=i.right&&t>=i.top&&t<=i.bottom}return!1}isMouseOverTrigger(e){const{clientX:t,clientY:i}=e instanceof MouseEvent?e:{clientX:0,clientY:0};return this.isRectOverTrigger(t,i)}handleCreatePopoverFirstUpdate(){return g(this,void 0,void 0,function*(){var e,t;this.visible&&this.interactive&&(null===(e=this.setFocusableElements)||void 0===e||e.call(this),yield this.updateComplete,null===(t=this.setInitialFocus)||void 0===t||t.call(this))})}positionPopover(){if(!this.triggerElement)return;this.cleanupAutoUpdate&&(this.cleanupAutoUpdate(),this.cleanupAutoUpdate=null);const e=[(0,n.shift)()];let t=this.offset;if(this.flip&&e.push((0,n.flip)()),this.size){const t=this.renderRoot.querySelector('[part="popover-content"]');e.push((0,n.size)({apply({availableHeight:e}){t&&Object.assign(t.style,{maxHeight:`${e}px`,overflowY:"auto"})},padding:50}))}if(this.showArrow&&(this.arrowElement=this.renderRoot.querySelector(".popover-arrow"),this.arrowElement)){const i=this.arrowElement.offsetHeight;t=Math.sqrt(2*i**2)/2+this.offset,e.push((0,n.arrow)({element:this.arrowElement,padding:12}))}e.push((0,n.offset)(t)),this.cleanupAutoUpdate=(0,n.autoUpdate)(this.triggerElement,this,()=>g(this,void 0,void 0,function*(){if(!this.triggerElement)return;const{x:t,y:i,middlewareData:r,placement:o}=yield(0,n.computePosition)(this.triggerElement,this,{placement:this.placement,middleware:e,strategy:this.strategy});this.utils.updatePopoverStyle(t,i),r.arrow&&this.arrowElement&&this.utils.updateArrowStyle(r.arrow,o),this.trigger.includes("mouseenter")&&this.utils.setupHoverBridge(o)}),{animationFrame:this.animationFrame})}render(){return l.html`
53
+ `}};h([(0,l.property)({type:String})],t.prototype,"placement",void 0),h([(0,l.property)({type:String,reflect:!0})],t.prototype,"triggerID",void 0),h([(0,l.property)({type:String})],t.prototype,"headerIconName",void 0),h([(0,l.property)({type:String})],t.prototype,"header",void 0),h([(0,l.property)({type:String})],t.prototype,"message",void 0),h([(0,l.property)({type:Boolean})],t.prototype,"show",void 0),h([(0,l.property)({type:Boolean,reflect:!0,attribute:"hide-close-button"})],t.prototype,"hideCloseButton",void 0),h([(0,l.property)({type:String})],t.prototype,"primaryButton",void 0),h([(0,l.property)({type:String})],t.prototype,"secondaryButton",void 0),h([(0,l.property)({type:String})],t.prototype,"linkText",void 0),h([(0,l.property)({type:String})],t.prototype,"href",void 0),h([(0,l.query)(".md-coachmark__trigger-component")],t.prototype,"triggerComponent",void 0),h([(0,l.query)(".md-coachmark__popper")],t.prototype,"popper",void 0),t=h([(0,o.w)("md-coachmark-popover")],t),e.ELEMENT=t}(r||(r={}))},32022:e=>{e.exports=s},60554:e=>{e.exports=n},70429:e=>{e.exports=t},71128:(e,t,i)=>{i(96798),i(61200);var r=i(31890),o=i(28373),s=i(66677),n=i(5784),l=i(87161),a=i(70429),p=i(68419),h=i(36365),c=i(3998),d=i(33759),u=i(86210),v=function(e,t,i,r){var o,s=arguments.length,n=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,r);else for(var l=e.length-1;l>=0;l--)(o=e[l])&&(n=(s<3?o(n):s>3?o(t,i,n):o(t,i))||n);return s>3&&n&&Object.defineProperty(t,i,n),n},m=function(e,t,i,r){return new(i||(i=Promise))(function(o,s){function n(e){try{a(r.next(e))}catch(e){s(e)}}function l(e){try{a(r.throw(e))}catch(e){s(e)}}function a(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(n,l)}a((r=r.apply(e,t||[])).next())})};let g=class extends((0,o.d)(l.LitElement)){set controller(e){e?(e.show=(e=!1)=>this.showPopover(e),e.hide=()=>this.hidePopover(),e.toggle=()=>this.togglePopoverVisible(),e.isVisible=()=>this.visible,this._controller=e):this._controller=null}get controller(){return this._controller}constructor(){super(),this.id="",this.triggerID="",this.trigger=p.zY.TRIGGER,this.placement=p.zY.PLACEMENT,this.strategy=p.zY.STRATEGY,this.color=p.zY.COLOR,this.visible=p.zY.VISIBLE,this.offset=p.zY.OFFSET,this.focusTrap=p.zY.FOCUS_TRAP,this.preventScroll=p.zY.PREVENT_SCROLL,this.showArrow=p.zY.ARROW,this.closeButton=p.zY.CLOSE_BUTTON,this.interactive=p.zY.INTERACTIVE,this.delay=p.zY.DELAY,this.hideOnEscape=p.zY.HIDE_ON_ESCAPE,this.hideOnBlur=p.zY.HIDE_ON_BLUR,this.hideOnWindowBlur=p.zY.HIDE_ON_WINDOW_BLUR,this.hideOnOutsideClick=p.zY.HIDE_ON_CLICK_OUTSIDE,this.focusBackToTrigger=p.zY.FOCUS_BACK,this.backdrop=p.zY.BACKDROP,this.flip=p.zY.FLIP,this.size=p.zY.SIZE,this.zIndex=p.zY.Z_INDEX,this.appendTo="",this.closeButtonAriaLabel=null,this.role=p.zY.ROLE,this.ariaLabelledby=null,this.ariaDescribedby=null,this.disableAriaExpanded=p.zY.DISABLE_ARIA_EXPANDED,this.animationFrame=p.zY.ANIMATION_FRAME,this._controller=null,this.arrowElement=null,this.triggerElement=null,this.hoverTimer=null,this.isTriggerClicked=!1,this.openDelay=0,this.closeDelay=0,this.backdropElement=null,this.useLegacyFindFocusable=()=>!1,this.cleanupAutoUpdate=null,this.previousActiveElement=null,this.onOutsidePopoverClick=e=>{const t=e.composedPath();this.triggerElement&&t.includes(this.triggerElement)||t.includes(this)||c.S.shouldDeferToTopForOutsideClick(this)||this.hideThisPopover()},this.hideThisPopover=()=>{setTimeout(()=>{this.visible=!1,this.isTriggerClicked=!1,this.utils.handleAppendTo(!1)},this.closeDelay)},this.onEscapeKeydown=e=>{this.visible&&"Escape"===e.code&&(e.preventDefault(),this.hidePopover())},this.onPopoverFocusOut=e=>{const t=e.relatedTarget;!t||this.isElementInPopover(t)?t||setTimeout(()=>{const e=(0,s.dw)();this.isElementInPopover(e)||this.hidePopover()},0):this.hidePopover()},this.handleWindowBlurEvent=()=>{this.visible&&this.hidePopover()},this.startCloseDelay=()=>{if(this.interactive){if(this.isTriggerClicked)return;this.hoverTimer=window.setTimeout(()=>{this.visible=!1},this.closeDelay)}else this.hidePopover()},this.cancelCloseDelay=()=>{this.hoverTimer&&(clearTimeout(this.hoverTimer),this.hoverTimer=null)},this.showPopover=(e=!1)=>{this.cancelCloseDelay(),e&&this.openDelay>0?setTimeout(()=>{this.utils.handleAppendTo(!0),this.visible=!0},this.openDelay):(this.utils.handleAppendTo(!0),this.visible=!0)},this.hidePopover=()=>{c.S.peek()===this&&setTimeout(()=>{this.visible=!1,this.isTriggerClicked=!1,this.utils.handleAppendTo(!1)},this.closeDelay)},this.togglePopoverVisible=()=>{this.isTriggerClicked?this.hidePopover():(this.showPopover(),this.isTriggerClicked=!0)},this.onMouseEnterTrigger=()=>{this.trigger.includes("mouseenter")&&(this.visible||(this.previousActiveElement=(0,s.dw)()),this.showPopover(!0))},this.onFocusInTrigger=()=>{this.trigger.includes("focusin")&&this.showPopover(!1)},this.onTriggerClick=e=>{this.trigger.includes("mouseenter")&&this.isMouseOverTrigger(e)||this.togglePopoverVisible()},this.utils=new d.h(this),this.preventClickOutside=!0}firstUpdated(e){const t=Object.create(null,{firstUpdated:{get:()=>super.firstUpdated}});return m(this,void 0,void 0,function*(){t.firstUpdated.call(this,e),[this.openDelay,this.closeDelay]=this.utils.setupDelay(),this.utils.setupAccessibility(),this.style.zIndex=`${this.zIndex}`,h.T.onCreatedPopover(this),this.visible&&(this.utils.handleAppendTo(!0),this.positionPopover(),yield this.handleCreatePopoverFirstUpdate())})}disconnectedCallback(){const e=Object.create(null,{disconnectedCallback:{get:()=>super.disconnectedCallback}});return m(this,void 0,void 0,function*(){e.disconnectedCallback.call(this),this.cleanupAutoUpdate&&(this.cleanupAutoUpdate(),this.cleanupAutoUpdate=null),this._controller=null,this.previousActiveElement=null,this.removeEventListeners(),h.T.onDestroyedPopover(this),c.S.remove(this)})}setupTriggerListener(){if(!this.triggerID)return;const e=this.getRootNode();if(this.triggerElement=(0,s.qi)(`[id="${this.triggerID}"]`,e),!this.triggerElement){const t=null==e?void 0:e.host;if(t){const e=t.querySelector("[slot]");(null==e?void 0:e.id)===this.triggerID&&(this.triggerElement=e)}}if(this.triggerElement){if("mouseenter"===this.trigger&&(this.interactive?this.trigger="mouseenter click":this.trigger="mouseenter focusin"),this.trigger.includes("click")&&this.triggerElement.addEventListener("click",this.onTriggerClick),this.trigger.includes("mouseenter")){const e=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.addEventListener("mouseenter",this.onMouseEnterTrigger),this.triggerElement.addEventListener("mouseleave",this.startCloseDelay),this.addEventListener("mouseenter",this.cancelCloseDelay),this.addEventListener("mouseleave",this.startCloseDelay),null==e||e.addEventListener("mouseenter",this.cancelCloseDelay)}this.trigger.includes("focusin")&&(this.triggerElement.addEventListener("focusin",this.onFocusInTrigger),this.interactive||this.triggerElement.addEventListener("focusout",this.hidePopover)),this.addEventListener("focus-trap-exit",this.hidePopover)}}removeEventListeners(){if(!this.triggerElement)return;const e=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.removeEventListener("click",this.onTriggerClick),this.triggerElement.removeEventListener("mouseenter",this.onMouseEnterTrigger),this.triggerElement.removeEventListener("mouseleave",this.hidePopover),this.removeEventListener("mouseenter",this.cancelCloseDelay),this.removeEventListener("mouseleave",this.startCloseDelay),this.triggerElement.removeEventListener("focusin",this.onFocusInTrigger),this.triggerElement.removeEventListener("focusout",this.hidePopover),null==e||e.removeEventListener("mouseenter",this.cancelCloseDelay),this.removeEventListener("focus-trap-exit",this.hidePopover)}updated(e){const t=Object.create(null,{updated:{get:()=>super.updated}});return m(this,void 0,void 0,function*(){if(t.updated.call(this,e),e.has("visible")){const t=e.get("visible")||!1;yield this.isOpenUpdated(t,this.visible),this.utils.updateAriaExpandedAttribute()}if(e.has("placement")&&this.setAttribute("placement",Object.values(p.ME).includes(this.placement)?this.placement:p.zY.PLACEMENT),e.has("delay")&&([this.openDelay,this.closeDelay]=this.utils.setupDelay()),e.has("trigger")){const e=this.trigger.split(" ").filter(e=>Object.values(p.tr).includes(e));this.setAttribute("trigger",e.length>0?this.trigger:p.zY.TRIGGER),this.removeEventListeners(),this.setupTriggerListener()}e.has("triggerID")&&(this.removeEventListeners(),this.setupTriggerListener(),this.utils.setupAccessibility()),e.has("color")&&this.setAttribute("color",Object.values(p.o$).includes(this.color)?this.color:p.zY.COLOR),e.has("zIndex")&&this.setAttribute("z-index",`${this.zIndex}`),(e.has("interactive")||e.has("aria-label")||e.has("aria-labelledby"))&&this.utils.setupAccessibility(),e.has("disableAriaExpanded")&&this.utils.updateAriaExpandedAttribute(),e.has("interactive")&&this.utils.updateAriaHasPopupAttribute()})}isElementInPopover(e){return!!e&&(!!this.contains(e)||(0,s.QZ)("md-popover",e)===this)}isOpenUpdated(e,t){const i=Object.create(null,{preventScroll:{get:()=>super.preventScroll,set:e=>super.preventScroll=e}});return m(this,void 0,void 0,function*(){var r,o,s,n;if(e!==t&&this.triggerElement)if(t)c.S.peek()!==this&&c.S.push(this),i.preventScroll=this.preventScroll,this.focusTrap&&(null===(r=this.activateFocusTrap)||void 0===r||r.call(this)),this.backdrop&&(this.utils.createBackdrop(),this.triggerElement.style.zIndex=`${this.zIndex}`),this.utils.handleAppendTo(!0),this.positionPopover(),yield this.handleCreatePopoverFirstUpdate(),this.hideOnBlur&&(this.addEventListener("focusout",this.onPopoverFocusOut),"click"===this.trigger&&(this.triggerElement.style.pointerEvents="none")),this.hideOnWindowBlur&&window.addEventListener("blur",this.handleWindowBlurEvent),this.hideOnOutsideClick&&document.addEventListener("click",this.onOutsidePopoverClick),this.hideOnEscape&&document.addEventListener("keydown",this.onEscapeKeydown),h.T.onShowPopover(this);else{if(this.cleanupAutoUpdate&&(this.cleanupAutoUpdate(),this.cleanupAutoUpdate=null),c.S.removeItem(this),this.utils.handleAppendTo(!1),this.backdropElement&&(null===(o=this.backdropElement)||void 0===o||o.remove(),this.backdropElement=null),this.hideOnBlur&&(this.removeEventListener("focusout",this.onPopoverFocusOut),"click"===this.trigger&&(this.triggerElement.style.pointerEvents="")),this.hideOnWindowBlur&&window.removeEventListener("blur",this.handleWindowBlurEvent),this.hideOnOutsideClick&&document.removeEventListener("click",this.onOutsidePopoverClick),this.hideOnEscape&&document.removeEventListener("keydown",this.onEscapeKeydown),null===(s=this.deactivateFocusTrap)||void 0===s||s.call(this),this.disableAriaExpanded||this.triggerElement.removeAttribute("aria-expanded"),this.interactive){const e=this.triggerElement.getAttribute("aria-haspopup");"dialog"!==e&&"alertdialog"!==e||this.triggerElement.removeAttribute("aria-haspopup")}this.focusBackToTrigger&&(this.previousActiveElement instanceof HTMLElement?this.previousActiveElement.focus():null===(n=this.setFocusOnDeepestNestedElement)||void 0===n||n.call(this,this.triggerElement)),this.previousActiveElement=null,h.T.onHidePopover(this)}})}isRectOverTrigger(e,t){if(this.triggerElement&&"undefined"!=typeof window&&"undefined"!=typeof document){const i=this.triggerElement.getBoundingClientRect();return e>=i.left&&e<=i.right&&t>=i.top&&t<=i.bottom}return!1}isMouseOverTrigger(e){const{clientX:t,clientY:i}=e instanceof MouseEvent?e:{clientX:0,clientY:0};return this.isRectOverTrigger(t,i)}setFocusableElements(){var e;null===(e=super.setFocusableElements)||void 0===e||e.call(this);const t=this.triggerElement;this.appendTo&&this.activeFocusTrap&&t&&this.focusableElements&&(this.focusableElements.includes(t)||this.focusableElements.push(t))}handleCreatePopoverFirstUpdate(){return m(this,void 0,void 0,function*(){var e,t;this.visible&&this.interactive&&(null===(e=this.setFocusableElements)||void 0===e||e.call(this),yield this.updateComplete,null===(t=this.setInitialFocus)||void 0===t||t.call(this))})}positionPopover(){if(!this.triggerElement)return;this.cleanupAutoUpdate&&(this.cleanupAutoUpdate(),this.cleanupAutoUpdate=null);const e=[(0,n.shift)()];let t=this.offset;if(this.flip&&e.push((0,n.flip)()),this.size){const t=this.renderRoot.querySelector('[part="popover-content"]');e.push((0,n.size)({apply({availableHeight:e}){t&&Object.assign(t.style,{maxHeight:`${e}px`,overflowY:"auto"})},padding:50}))}if(this.showArrow&&(this.arrowElement=this.renderRoot.querySelector(".popover-arrow"),this.arrowElement)){const i=this.arrowElement.offsetHeight;t=Math.sqrt(2*i**2)/2+this.offset,e.push((0,n.arrow)({element:this.arrowElement,padding:12}))}e.push((0,n.offset)(t)),this.cleanupAutoUpdate=(0,n.autoUpdate)(this.triggerElement,this,()=>m(this,void 0,void 0,function*(){if(!this.triggerElement)return;const{x:t,y:i,middlewareData:r,placement:o}=yield(0,n.computePosition)(this.triggerElement,this,{placement:this.placement,middleware:e,strategy:this.strategy});this.utils.updatePopoverStyle(t,i),r.arrow&&this.arrowElement&&this.utils.updateArrowStyle(r.arrow,o),this.trigger.includes("mouseenter")&&this.utils.setupHoverBridge(o)}),{animationFrame:this.animationFrame})}render(){return l.html`
54
54
  <div class="popover-hover-bridge"></div>
55
55
  ${this.closeButton?l.html` <md-button
56
56
  class="popover-close"
57
57
  hasRemoveStyle
58
58
  size="20"
59
59
  circle
60
- ariaLabel=${(0,p.ifDefined)(this.closeButtonAriaLabel)||""}
61
- @button-click="${this.hidePopover}"
60
+ .ariaLabel=${this.closeButtonAriaLabel}
61
+ @button-click=${this.hidePopover}
62
62
  >
63
63
  <md-icon name="cancel-bold" size="16" iconSet="momentumDesign"></md-icon>
64
64
  </md-button>`:l.nothing}
@@ -66,4 +66,4 @@
66
66
  <div part="popover-content">
67
67
  <slot></slot>
68
68
  </div>
69
- `}static get styles(){return[v.A]}};m([(0,a.property)({type:String,reflect:!0})],y.prototype,"id",void 0),m([(0,a.property)({type:String,reflect:!0})],y.prototype,"triggerID",void 0),m([(0,a.property)({type:String,reflect:!0})],y.prototype,"trigger",void 0),m([(0,a.property)({type:String,reflect:!0})],y.prototype,"placement",void 0),m([(0,a.property)({type:String,reflect:!0})],y.prototype,"strategy",void 0),m([(0,a.property)({type:String,reflect:!0})],y.prototype,"color",void 0),m([(0,a.property)({type:Boolean,reflect:!0})],y.prototype,"visible",void 0),m([(0,a.property)({type:Number,reflect:!0})],y.prototype,"offset",void 0),m([(0,a.property)({type:Boolean,reflect:!0,attribute:"focus-trap"})],y.prototype,"focusTrap",void 0),m([(0,a.property)({type:Boolean,reflect:!0,attribute:"prevent-scroll"})],y.prototype,"preventScroll",void 0),m([(0,a.property)({type:Boolean,reflect:!0,attribute:"show-arrow"})],y.prototype,"showArrow",void 0),m([(0,a.property)({type:Boolean,reflect:!0,attribute:"close-button"})],y.prototype,"closeButton",void 0),m([(0,a.property)({type:Boolean,reflect:!0})],y.prototype,"interactive",void 0),m([(0,a.property)({type:String,reflect:!0})],y.prototype,"delay",void 0),m([(0,a.property)({type:Boolean,reflect:!0,attribute:"hide-on-escape"})],y.prototype,"hideOnEscape",void 0),m([(0,a.property)({type:Boolean,reflect:!0,attribute:"hide-on-blur"})],y.prototype,"hideOnBlur",void 0),m([(0,a.property)({type:Boolean,reflect:!0,attribute:"hide-on-window-blur"})],y.prototype,"hideOnWindowBlur",void 0),m([(0,a.property)({type:Boolean,reflect:!0,attribute:"hide-on-outside-click"})],y.prototype,"hideOnOutsideClick",void 0),m([(0,a.property)({type:Boolean,reflect:!0,attribute:"focus-back-to-trigger"})],y.prototype,"focusBackToTrigger",void 0),m([(0,a.property)({type:Boolean,reflect:!0})],y.prototype,"backdrop",void 0),m([(0,a.property)({type:Boolean,reflect:!0})],y.prototype,"flip",void 0),m([(0,a.property)({type:Boolean,reflect:!0})],y.prototype,"size",void 0),m([(0,a.property)({type:Number,reflect:!0,attribute:"z-index"})],y.prototype,"zIndex",void 0),m([(0,a.property)({type:String,reflect:!0,attribute:"append-to"})],y.prototype,"appendTo",void 0),m([(0,a.property)({type:String,attribute:"close-button-aria-label",reflect:!0})],y.prototype,"closeButtonAriaLabel",void 0),m([(0,a.property)({type:String,reflect:!0})],y.prototype,"role",void 0),m([(0,a.property)({type:String,reflect:!0,attribute:"aria-labelledby"})],y.prototype,"ariaLabelledby",void 0),m([(0,a.property)({type:String,reflect:!0,attribute:"aria-describedby"})],y.prototype,"ariaDescribedby",void 0),m([(0,a.property)({type:Boolean,reflect:!0,attribute:"disable-aria-expanded"})],y.prototype,"disableAriaExpanded",void 0),m([(0,a.property)({type:Boolean,reflect:!0,attribute:"animation-frame"})],y.prototype,"animationFrame",void 0),m([(0,a.property)({type:Object,attribute:!1})],y.prototype,"controller",null),y=m([(0,r.w)("md-popover")],y)},85125:e=>{e.exports=i},85314:e=>{e.exports=l},87161:t=>{t.exports=e}},c={};function d(e){var t=c[e];if(void 0!==t)return t.exports;var i=c[e]={exports:{}};return h[e](i,i.exports,d),i.exports}d.m=h,p=[],d.O=(e,t,i,r)=>{if(!t){var o=1/0;for(a=0;a<p.length;a++){for(var[t,i,r]=p[a],s=!0,n=0;n<t.length;n++)(!1&r||o>=r)&&Object.keys(d.O).every(e=>d.O[e](t[n]))?t.splice(n--,1):(s=!1,r<o&&(o=r));if(s){p.splice(a--,1);var l=i();void 0!==l&&(e=l)}}return e}r=r||0;for(var a=p.length;a>0&&p[a-1][2]>r;a--)p[a]=p[a-1];p[a]=[t,i,r]},d.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return d.d(t,{a:t}),t},d.d=(e,t)=>{for(var i in t)d.o(t,i)&&!d.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},d.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),d.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{var e={3413:0,4131:0};d.O.j=t=>0===e[t];var t=(t,i)=>{var r,o,[s,n,l]=i,a=0;if(s.some(t=>0!==e[t])){for(r in n)d.o(n,r)&&(d.m[r]=n[r]);if(l)var p=l(d)}for(t&&t(i);a<s.length;a++)o=s[a],d.o(e,o)&&e[o]&&e[o][0](),e[o]=0;return d.O(p)},i=self["momentum-web-components-[id]"]=self["momentum-web-components-[id]"]||[];i.forEach(t.bind(null,0)),i.push=t.bind(null,i.push.bind(i))})();var u=d.O(void 0,[6633,1890,4313,510,6283,5087,2176,6798,6865,1200,2576,8210,1270,3135,8345,1439,2924],()=>d(29895));return d.O(u)})());
69
+ `}static get styles(){return[u.A]}};v([(0,a.property)({type:String,reflect:!0})],g.prototype,"id",void 0),v([(0,a.property)({type:String,reflect:!0})],g.prototype,"triggerID",void 0),v([(0,a.property)({type:String,reflect:!0})],g.prototype,"trigger",void 0),v([(0,a.property)({type:String,reflect:!0})],g.prototype,"placement",void 0),v([(0,a.property)({type:String,reflect:!0})],g.prototype,"strategy",void 0),v([(0,a.property)({type:String,reflect:!0})],g.prototype,"color",void 0),v([(0,a.property)({type:Boolean,reflect:!0})],g.prototype,"visible",void 0),v([(0,a.property)({type:Number,reflect:!0})],g.prototype,"offset",void 0),v([(0,a.property)({type:Boolean,reflect:!0,attribute:"focus-trap"})],g.prototype,"focusTrap",void 0),v([(0,a.property)({type:Boolean,reflect:!0,attribute:"prevent-scroll"})],g.prototype,"preventScroll",void 0),v([(0,a.property)({type:Boolean,reflect:!0,attribute:"show-arrow"})],g.prototype,"showArrow",void 0),v([(0,a.property)({type:Boolean,reflect:!0,attribute:"close-button"})],g.prototype,"closeButton",void 0),v([(0,a.property)({type:Boolean,reflect:!0})],g.prototype,"interactive",void 0),v([(0,a.property)({type:String,reflect:!0})],g.prototype,"delay",void 0),v([(0,a.property)({type:Boolean,reflect:!0,attribute:"hide-on-escape"})],g.prototype,"hideOnEscape",void 0),v([(0,a.property)({type:Boolean,reflect:!0,attribute:"hide-on-blur"})],g.prototype,"hideOnBlur",void 0),v([(0,a.property)({type:Boolean,reflect:!0,attribute:"hide-on-window-blur"})],g.prototype,"hideOnWindowBlur",void 0),v([(0,a.property)({type:Boolean,reflect:!0,attribute:"hide-on-outside-click"})],g.prototype,"hideOnOutsideClick",void 0),v([(0,a.property)({type:Boolean,reflect:!0,attribute:"focus-back-to-trigger"})],g.prototype,"focusBackToTrigger",void 0),v([(0,a.property)({type:Boolean,reflect:!0})],g.prototype,"backdrop",void 0),v([(0,a.property)({type:Boolean,reflect:!0})],g.prototype,"flip",void 0),v([(0,a.property)({type:Boolean,reflect:!0})],g.prototype,"size",void 0),v([(0,a.property)({type:Number,reflect:!0,attribute:"z-index"})],g.prototype,"zIndex",void 0),v([(0,a.property)({type:String,reflect:!0,attribute:"append-to"})],g.prototype,"appendTo",void 0),v([(0,a.property)({type:String,attribute:"close-button-aria-label",reflect:!0})],g.prototype,"closeButtonAriaLabel",void 0),v([(0,a.property)({type:String,reflect:!0})],g.prototype,"role",void 0),v([(0,a.property)({type:String,reflect:!0,attribute:"aria-labelledby"})],g.prototype,"ariaLabelledby",void 0),v([(0,a.property)({type:String,reflect:!0,attribute:"aria-describedby"})],g.prototype,"ariaDescribedby",void 0),v([(0,a.property)({type:Boolean,reflect:!0,attribute:"disable-aria-expanded"})],g.prototype,"disableAriaExpanded",void 0),v([(0,a.property)({type:Boolean,reflect:!0,attribute:"animation-frame"})],g.prototype,"animationFrame",void 0),v([(0,a.property)({type:Object,attribute:!1})],g.prototype,"controller",null),g=v([(0,r.w)("md-popover")],g)},85125:e=>{e.exports=i},85314:e=>{e.exports=l},87161:t=>{t.exports=e}},c={};function d(e){var t=c[e];if(void 0!==t)return t.exports;var i=c[e]={exports:{}};return h[e](i,i.exports,d),i.exports}d.m=h,p=[],d.O=(e,t,i,r)=>{if(!t){var o=1/0;for(a=0;a<p.length;a++){for(var[t,i,r]=p[a],s=!0,n=0;n<t.length;n++)(!1&r||o>=r)&&Object.keys(d.O).every(e=>d.O[e](t[n]))?t.splice(n--,1):(s=!1,r<o&&(o=r));if(s){p.splice(a--,1);var l=i();void 0!==l&&(e=l)}}return e}r=r||0;for(var a=p.length;a>0&&p[a-1][2]>r;a--)p[a]=p[a-1];p[a]=[t,i,r]},d.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return d.d(t,{a:t}),t},d.d=(e,t)=>{for(var i in t)d.o(t,i)&&!d.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},d.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),d.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{var e={3413:0,4131:0};d.O.j=t=>0===e[t];var t=(t,i)=>{var r,o,[s,n,l]=i,a=0;if(s.some(t=>0!==e[t])){for(r in n)d.o(n,r)&&(d.m[r]=n[r]);if(l)var p=l(d)}for(t&&t(i);a<s.length;a++)o=s[a],d.o(e,o)&&e[o]&&e[o][0](),e[o]=0;return d.O(p)},i=self["momentum-web-components-[id]"]=self["momentum-web-components-[id]"]||[];i.forEach(t.bind(null,0)),i.push=t.bind(null,i.push.bind(i))})();var u=d.O(void 0,[6633,1890,4313,510,6283,5087,2176,6798,6865,1200,2576,8210,1270,3135,8345,1439,2924],()=>d(29895));return d.O(u)})());
@@ -27,7 +27,7 @@
27
27
  ariaLabel=${this.ariaLabel}
28
28
  placeholder="${this.codePlaceholder}"
29
29
  .value="${this.countryCallingCode?[this.getFormatedCountryCallingCode()]:[]}"
30
- @change-selected="${e=>this.handleCountryChange(e)}"
30
+ @change-selected=${e=>this.handleCountryChange(e)}
31
31
  with-custom-content
32
32
  ?newMomentum=${this.newMomentum}
33
33
  ?is-dropdown-arrow=${this.isDropdownArrow}
@@ -71,7 +71,7 @@
71
71
  auxiliaryContentPosition="before"
72
72
  ?required=${this.required}
73
73
  @keydown=${e=>this.handleInputKeyDown(e)}
74
- @input-change="${e=>this.handleDateInputChange(e)}"
74
+ @input-change=${e=>this.handleDateInputChange(e)}
75
75
  ?disabled=${this.disabled}
76
76
  ?hide-message=${!this.errorMessage||this.isValueValid()}
77
77
  ariaInvalid=${!!this.errorMessage||!this.isValueValid()}
@@ -109,7 +109,7 @@
109
109
  auxiliaryContentPosition="before"
110
110
  ?required=${this.required}
111
111
  @keydown=${e=>this.handleInputKeyDown(e)}
112
- @input-change="${e=>this.handleDateInputChange(e)}"
112
+ @input-change=${e=>this.handleDateInputChange(e)}
113
113
  ?disabled=${this.disabled}
114
114
  ?hide-message=${!this.errorMessage||this.isValueValid()}
115
115
  ariaInvalid=${!!this.errorMessage||!this.isValueValid()}
@@ -91,7 +91,7 @@
91
91
  aria-controls="md-dropdown-list"
92
92
  aria-haspopup="listbox"
93
93
  ?disabled="${this.disabled}"
94
- @click="${()=>this.onLabelClick()}"
94
+ @click=${this.onLabelClick}
95
95
  part="dropdown-header"
96
96
  role="combobox"
97
97
  tabindex="0"
@@ -3,7 +3,7 @@
3
3
  <div
4
4
  class="md-floating ${this.minimize?"":"hide"} md-floating-minimize"
5
5
  @click=${this.handleMinimize}
6
- @keydown="${this.handleKeyDown}"
6
+ @keydown=${this.handleKeyDown}
7
7
  role="dialog"
8
8
  tabindex="-1"
9
9
  part="floating-minimized"
@@ -31,7 +31,7 @@
31
31
  aria-label="${this.closeAriaLabel}"
32
32
  circle
33
33
  @click=${this.handleClose}
34
- @keydown="${this.handleKeyDownClose}"
34
+ @keydown=${this.handleKeyDownClose}
35
35
  >
36
36
  <md-icon name="cancel-bold" size="16" iconSet="momentumDesign"></md-icon>
37
37
  </md-button>
@@ -3,7 +3,7 @@
3
3
  <div
4
4
  class="md-floating ${this.minimize?"":"hide"} md-floating-minimize"
5
5
  @click=${this.handleMinimize}
6
- @keydown="${this.handleKeyDown}"
6
+ @keydown=${this.handleKeyDown}
7
7
  role="dialog"
8
8
  tabindex="-1"
9
9
  part="floating-minimized"
@@ -31,7 +31,7 @@
31
31
  aria-label="${this.closeAriaLabel}"
32
32
  circle
33
33
  @click=${this.handleClose}
34
- @keydown="${this.handleKeyDownClose}"
34
+ @keydown=${this.handleKeyDownClose}
35
35
  >
36
36
  <md-icon name="cancel-bold" size="16" iconSet="momentumDesign"></md-icon>
37
37
  </md-button>
@@ -9,12 +9,12 @@
9
9
  aria-label=${(0,u.ifDefined)(this.label.length?this.label:void 0)}
10
10
  type="button"
11
11
  role="button"
12
- @click="${()=>this.handleMouseDown()}"
13
- @keydown="${e=>this.handleKeyDown(e)}"
14
- @mouseenter="${()=>this.handleMouseEnter()}"
15
- @mouseleave="${()=>this.handleMouseLeave()}"
16
- @focus="${()=>this.handleFocus()}"
17
- @blur="${()=>this.handleBlur()}"
12
+ @click=${this.handleMouseDown}
13
+ @keydown=${this.handleKeyDown}
14
+ @mouseenter=${this.handleMouseEnter}
15
+ @mouseleave=${this.handleMouseLeave}
16
+ @focus=${this.handleFocus}
17
+ @blur=${this.handleBlur}
18
18
  >
19
19
  <md-icon name="${this.iconName}" size="${this.iconSize}" iconSet="momentumDesign"></md-icon>
20
20
  </button>
@@ -108,7 +108,7 @@
108
108
  secondaryLabel
109
109
  .htmlFor=${this.htmlId}
110
110
  .label=${this.secondaryLabel}
111
- @label-click="${()=>this.handleLabelClick()}"
111
+ @label-click=${()=>this.handleLabelClick()}
112
112
  ></md-label>
113
113
  `:n.nothing}helpTextTemplate(){return this.helpText?n.html`
114
114
  <md-help-text
@@ -132,7 +132,7 @@
132
132
  class="md-input__label ${(0,d.classMap)({disabled:this.disabled,newMomentum:this.newMomentum})}"
133
133
  .htmlFor=${this.htmlId}
134
134
  .label=${this.label}
135
- @label-click="${()=>this.handleLabelClick()}"
135
+ @label-click=${()=>this.handleLabelClick()}
136
136
  ></md-label>
137
137
  `:n.nothing}static get styles(){return[r.A,c.A]}render(){return n.html`
138
138
  <div class="md-input-container ${(0,d.classMap)(this.inputClassMap)}" part="md-input-container">
@@ -1,9 +1,5 @@
1
1
  !function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("lit"),require("lit/decorators.js"),require("lit/directives/class-map.js"));else if("function"==typeof define&&define.amd)define(["lit","lit/decorators.js","lit/directives/class-map.js"],t);else{var o="object"==typeof exports?t(require("lit"),require("lit/decorators.js"),require("lit/directives/class-map.js")):t(e.lit,e["lit/decorators.js"],e["lit/directives/class-map.js"]);for(var r in o)("object"==typeof exports?exports:e)[r]=o[r]}}(self,(e,t,o)=>(()=>{"use strict";var r,i={6396:(e,t,o)=>{o.r(t),o.d(t,{Label:()=>r});var r,i=o(31890),l=o(4313),s=o(87161),a=o(70429),p=o(85125),n=o(31013),d=function(e,t,o,r){var i,l=arguments.length,s=l<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,o):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,o,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(l<3?i(s):l>3?i(t,o,s):i(t,o))||s);return l>3&&s&&Object.defineProperty(t,o,s),s};!function(e){let t=class extends s.LitElement{constructor(){super(...arguments),this.label="",this.theme="",this.radioLabel=!1,this.checkboxLabel=!1,this.toggleSwitchLabel=!1,this.htmlFor="",this.active=!1,this.disabled=!1,this.indeterminate=!1,this.secondaryLabel=!1}static get styles(){return[l.A,n.A]}setFocus(){this.dispatchEvent(new CustomEvent("setFocus"))}get labelClassMap(){return{[`md-label--${this.theme}`]:!!this.theme,"md-radio__label":this.radioLabel,"md-checkbox__label":this.checkboxLabel,"md-secondary-label":this.secondaryLabel,active:this.active,disabled:this.disabled,indeterminate:this.indeterminate}}handleClick(){this.setFocus(),this.dispatchEvent(new CustomEvent("label-click",{composed:!0,bubbles:!0,detail:{htmlFor:this.htmlFor}}))}render(){return s.html`
2
- <label
3
- @click="${()=>this.handleClick()}"
4
- class="md-label ${(0,p.classMap)(this.labelClassMap)}"
5
- for="${this.htmlFor}"
6
- >
2
+ <label @click=${this.handleClick} class="md-label ${(0,p.classMap)(this.labelClassMap)}" for="${this.htmlFor}">
7
3
  ${this.label?s.html` <span>${this.label}</span> `:s.html` <slot></slot> `}
8
4
  </label>
9
5
  `}};d([(0,a.property)({type:String})],t.prototype,"label",void 0),d([(0,a.property)({type:String})],t.prototype,"theme",void 0),d([(0,a.property)({type:Boolean})],t.prototype,"radioLabel",void 0),d([(0,a.property)({type:Boolean})],t.prototype,"checkboxLabel",void 0),d([(0,a.property)({type:Boolean})],t.prototype,"toggleSwitchLabel",void 0),d([(0,a.property)({type:String})],t.prototype,"htmlFor",void 0),d([(0,a.property)({type:Boolean})],t.prototype,"active",void 0),d([(0,a.property)({type:Boolean})],t.prototype,"disabled",void 0),d([(0,a.property)({type:Boolean})],t.prototype,"indeterminate",void 0),d([(0,a.property)({type:Boolean})],t.prototype,"secondaryLabel",void 0),t=d([(0,i.w)("md-label")],t),e.ELEMENT=t}(r||(r={}))},70429:e=>{e.exports=t},85125:e=>{e.exports=o},87161:t=>{t.exports=e}},l={};function s(e){var t=l[e];if(void 0!==t)return t.exports;var o=l[e]={exports:{}};return i[e](o,o.exports,s),o.exports}s.m=i,r=[],s.O=(e,t,o,i)=>{if(!t){var l=1/0;for(d=0;d<r.length;d++){for(var[t,o,i]=r[d],a=!0,p=0;p<t.length;p++)(!1&i||l>=i)&&Object.keys(s.O).every(e=>s.O[e](t[p]))?t.splice(p--,1):(a=!1,i<l&&(l=i));if(a){r.splice(d--,1);var n=o();void 0!==n&&(e=n)}}return e}i=i||0;for(var d=r.length;d>0&&r[d-1][2]>i;d--)r[d]=r[d-1];r[d]=[t,o,i]},s.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return s.d(t,{a:t}),t},s.d=(e,t)=>{for(var o in t)s.o(t,o)&&!s.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},s.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),s.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{var e={4928:0,6396:0};s.O.j=t=>0===e[t];var t=(t,o)=>{var r,i,[l,a,p]=o,n=0;if(l.some(t=>0!==e[t])){for(r in a)s.o(a,r)&&(s.m[r]=a[r]);if(p)var d=p(s)}for(t&&t(o);n<l.length;n++)i=l[n],s.o(e,i)&&e[i]&&e[i][0](),e[i]=0;return s.O(d)},o=self["momentum-web-components-[id]"]=self["momentum-web-components-[id]"]||[];o.forEach(t.bind(null,0)),o.push=t.bind(null,o.push.bind(o))})();var a=s.O(void 0,[1890,4313,1013],()=>s(6396));return s.O(a)})());
@@ -9,7 +9,7 @@
9
9
  `}connectedCallback(){super.connectedCallback(),this.handleWindowBlurEvent=this.handleWindowBlurEvent.bind(this),window.addEventListener("blur",this.handleWindowBlurEvent),document.addEventListener("keydown",this.handleOutsideOverlayKeydown),this.addEventListener("menu-overlay-open",this.updateActiveMenuOverlayOpened),this.addEventListener("menu-overlay-close",this.updateActiveMenuOverlayClosed),this.updateComplete.then(()=>{this.handleTriggerSlotChange()})}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.handleOutsideOverlayClick),document.removeEventListener("keydown",this.handleOutsideOverlayKeydown),window.removeEventListener("blur",this.handleWindowBlurEvent),this.removeEventListener("menu-overlay-open",this.updateActiveMenuOverlayOpened),this.removeEventListener("menu-overlay-close",this.updateActiveMenuOverlayClosed),this.removeTriggerEventListeners()}checkIsInputField(e){var t;return"md-input"===(null===(t=null==e?void 0:e.tagName)||void 0===t?void 0:t.toLowerCase())}updateTriggerElementAriaExpanded(){this.triggerElement&&(this.isOpen?(this.triggerElement.setAttribute("aria-expanded","true"),this.triggerElement.hasAttribute("ariaexpanded")&&this.triggerElement.setAttribute("ariaexpanded","true")):(this.triggerElement.removeAttribute("aria-expanded"),this.triggerElement.hasAttribute("ariaexpanded")&&this.triggerElement.setAttribute("ariaexpanded","false")))}handleTriggerSlotChange(){this.removeTriggerEventListeners(),this.setupTriggerEventListeners(),this.updateTriggerElementAriaExpanded(),this.popperInstance&&this.destroy(),this.isOpen&&(this.create(),this.overlayContainer&&this.overlayContainer.toggleAttribute("data-show",this.isOpen))}removeTriggerEventListeners(){this.triggerElement&&(this.triggerElement.removeEventListener("click",this.handleTriggerClick),this.triggerElement.removeEventListener("keydown",this.handleTriggerKeyDown),this.allowHoverToggle&&(this.triggerElement.removeEventListener("mouseenter",this.expandPopup),this.triggerElement.removeEventListener("mouseleave",this.collapsePopup),this.overlayContainer.removeEventListener("mouseenter",this.expandPopup),this.overlayContainer.removeEventListener("mouseleave",this.collapsePopup)),this.triggerElement=null)}setupTriggerEventListeners(){if(this.trigger){if(this.triggerElement=this.trigger[0],!this.triggerElement)return;this.triggerElement.addEventListener("click",this.handleTriggerClick),this.allowHoverToggle&&(this.triggerElement.addEventListener("mouseenter",this.expandPopup),this.triggerElement.addEventListener("mouseleave",this.collapsePopup),this.overlayContainer.addEventListener("mouseenter",this.expandPopup),this.overlayContainer.addEventListener("mouseleave",this.collapsePopup)),this.arrow&&this.showArrow&&this.arrow.toggleAttribute("data-show",!0),this.checkIsInputField(this.triggerElement)||this.triggerElement.addEventListener("keydown",this.handleTriggerKeyDown),this.triggerElement.setAttribute("aria-haspopup","true")}}update(e){super.update(e),e.has("isOpen")&&(this.isOpen?(this.activateFocusTrap(),document.addEventListener("menu-item-click",this.handleTriggerClick)):(this.deactivateFocusTrap(),document.removeEventListener("menu-item-click",this.handleTriggerClick))),e.has("showArrow")&&this.arrow&&this.arrow.toggleAttribute("data-show",this.showArrow)}updated(e){super.updated(e),e.has("isOpen")&&(this.isOpen?(this.dispatchMenuOpen(),requestAnimationFrame(()=>{document.addEventListener("click",this.handleOutsideOverlayClick)}),this.updateTriggerElementAriaExpanded()):(this.dispatchMenuClose(),document.removeEventListener("click",this.handleOutsideOverlayClick),this.updateTriggerElementAriaExpanded()))}dispatchMenuOpen(){this.dispatchEvent(new CustomEvent("menu-overlay-open",{composed:!0,bubbles:!0}))}dispatchMenuClose(){this.dispatchEvent(new CustomEvent("menu-overlay-close",{composed:!0,bubbles:!0}))}handleInstance(e){e?this.create():this.destroy()}create(){this.triggerElement&&(this.popperInstance=(0,y.createPopper)(this.triggerElement,this.overlayContainer,{onFirstUpdate:()=>x(this,void 0,void 0,function*(){var e;this.isOpen&&(null===(e=this.popperInstance)||void 0===e||e.update(),this.setFocusableElements(),yield this.updateComplete,this.focusInsideOverlay())}),placement:this.placement,strategy:this.positioningStrategy,modifiers:[...y.defaultModifiers,v(),c(),m(),d(),{name:"preventOverflow",options:{padding:16}},{name:"offset",options:{offset:({placement:e,reference:t})=>"left-end"===e||"right-end"===e?[t.height+t.y+3,14]:[0,this.overlayOffset]}},{name:"arrow",options:{element:this.arrow,padding:5}},{name:"computeStyles",options:{adaptive:!1}}]}))}destroy(){this.popperInstance&&(this.popperInstance.destroy(),this.popperInstance=null)}toggleOverlay(){this.disabled||(this.isOpen=!this.isOpen)}focusOnTrigger(){requestAnimationFrame(()=>{var e;(null===(e=this.focusableElements)||void 0===e?void 0:e.length)&&this.focusableElements[0].focus()})}focusInsideOverlay(){this.focusableElements&&(this.focusableElements.length>1?this.setInitialFocus(1):this.focusableElements.length&&this.setInitialFocus())}focusOnNestedTrigger(e){var t;null===(t=this.setFocusOnTrigger)||void 0===t||t.call(this,e)}handleWindowBlurEvent(){this._isOpen&&!this.keepOpenOnWindowBlur&&(this.isOpen=!1)}static get styles(){return[b.A]}render(){return f.html`
10
10
  ${this.getStyles()}
11
11
  <div class="md-menu-overlay">
12
- <slot @slotchange="${this.handleTriggerSlotChange}" name="menu-trigger"></slot>
12
+ <slot @slotchange=${this.handleTriggerSlotChange} name="menu-trigger"></slot>
13
13
  <div
14
14
  part="overlay"
15
15
  class="overlay-container"
@@ -5,8 +5,8 @@
5
5
  size="20"
6
6
  circle
7
7
  class="md-close md-modal__close"
8
- @click="${this.hideModal}"
9
- @keydown="${this.handleKeyDown}"
8
+ @click=${this.hideModal}
9
+ @keydown=${this.handleKeyDown}
10
10
  ariaLabel=${this.ariaLabelClose}
11
11
  >
12
12
  <md-icon name="cancel-bold" size="16" iconSet="momentumDesign"></md-icon>
@@ -29,8 +29,8 @@
29
29
  <div part="modal-footer" class="md-modal__footer">
30
30
  <md-button
31
31
  aria-label=${this.ariaLabelCancel}
32
- @click="${this.handleFooterClick}"
33
- @keydown="${this.handleKeyDown}"
32
+ @click=${this.handleFooterClick}
33
+ @keydown=${this.handleKeyDown}
34
34
  variant="secondary"
35
35
  >
36
36
  <span>Cancel</span>
@@ -39,8 +39,8 @@
39
39
  type="submit"
40
40
  variant="primary"
41
41
  aria-label=${this.ariaLabelSubmit}
42
- @click="${this.handleFooterClick}"
43
- @keydown="${this.handleKeyDown}"
42
+ @click=${this.handleFooterClick}
43
+ @keydown=${this.handleKeyDown}
44
44
  >
45
45
  <span>${this.closeBtnName}</span>
46
46
  </md-button>
@@ -48,7 +48,7 @@
48
48
  `}get modalBackDropClassMap(){return{in:this.show&&this.animating}}get modalContainerClassMap(){return{in:this.show,[`md-modal--${this.size}`]:!!this.size,[`md-modal--${this.computedAlignment}`]:!!this.computedAlignment}}render(){return l.html`
49
49
  ${this.show?l.html`
50
50
  <div part="modal-backdrop" class="md-modal__backdrop fade ${(0,p.classMap)(this.modalBackDropClassMap)}">
51
- ${this.backdropClickExit?l.html` <div class="md-modal_overlay" @click="${this.handleCloseBackdrop}"></div> `:l.nothing}
51
+ ${this.backdropClickExit?l.html` <div class="md-modal_overlay" @click=${this.handleCloseBackdrop}></div> `:l.nothing}
52
52
 
53
53
  <div
54
54
  part="modal-container"
@@ -27,7 +27,7 @@
27
27
  ariaLabel=${this.ariaLabel}
28
28
  placeholder="${this.codePlaceholder}"
29
29
  .value="${this.countryCallingCode?[this.getFormatedCountryCallingCode()]:[]}"
30
- @change-selected="${e=>this.handleCountryChange(e)}"
30
+ @change-selected=${e=>this.handleCountryChange(e)}
31
31
  with-custom-content
32
32
  ?newMomentum=${this.newMomentum}
33
33
  ?is-dropdown-arrow=${this.isDropdownArrow}
@@ -47,7 +47,7 @@
47
47
  ariaLabel=${this.countryCodeAriaLabel}
48
48
  codePlaceholder="${this.codePlaceholder}"
49
49
  .countryCallingCode="${this.countryCallingCode}"
50
- @country-code-changed="${e=>this.handleCountryChange(e)}"
50
+ @country-code-changed=${e=>this.handleCountryChange(e)}
51
51
  ?newMomentum=${this.newMomentum}
52
52
  ?isDropdownArrow=${!0}
53
53
  .clearAriaLabel="${this.clearCountryCodeAriaLabel}"
@@ -59,9 +59,9 @@
59
59
  placeholder=${this.numberPlaceholder}
60
60
  .ariaInvalid=${this.isValid?"false":"true"}
61
61
  .ariaLabel=${`${this.dialNumberAriaLabel}`}
62
- @input-change="${e=>this.handlePhoneChange(e)}"
63
- @input-blur="${e=>this.handleBlur(e)}"
64
- @input-keydown="${e=>this.handleKeydown(e)}"
62
+ @input-change=${e=>this.handlePhoneChange(e)}
63
+ @input-blur=${e=>this.handleBlur(e)}
64
+ @input-keydown=${e=>this.handleKeydown(e)}
65
65
  shape="${this.pill?"pill":"none"}"
66
66
  .ariaControls=${this.id}
67
67
  clear
@@ -1,12 +1,12 @@
1
- !function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("lit"),require("lit/decorators.js"),require("lit/directives/class-map.js"),require("lit/directives/style-map.js"),require("lit/directives/if-defined.js"),require("@momentum-ui/icons/data/momentumUiIconsNames.json"),require("@momentum-ui/utils/lib/getColorValue"),require("mobx"),require("@floating-ui/dom"));else if("function"==typeof define&&define.amd)define(["lit","lit/decorators.js","lit/directives/class-map.js","lit/directives/style-map.js","lit/directives/if-defined.js","@momentum-ui/icons/data/momentumUiIconsNames.json","@momentum-ui/utils/lib/getColorValue","mobx","@floating-ui/dom"],t);else{var i="object"==typeof exports?t(require("lit"),require("lit/decorators.js"),require("lit/directives/class-map.js"),require("lit/directives/style-map.js"),require("lit/directives/if-defined.js"),require("@momentum-ui/icons/data/momentumUiIconsNames.json"),require("@momentum-ui/utils/lib/getColorValue"),require("mobx"),require("@floating-ui/dom")):t(e.lit,e["lit/decorators.js"],e["lit/directives/class-map.js"],e["lit/directives/style-map.js"],e["lit/directives/if-defined.js"],e["@momentum-ui/icons/data/momentumUiIconsNames.json"],e["@momentum-ui/utils/lib/getColorValue"],e.mobx,e["@floating-ui/dom"]);for(var r in i)("object"==typeof exports?exports:e)[r]=i[r]}}(self,(e,t,i,r,o,s,n,l,p)=>(()=>{"use strict";var a,h={5784:e=>{e.exports=p},10318:e=>{e.exports=r},20291:e=>{e.exports=o},32022:e=>{e.exports=s},60554:e=>{e.exports=n},70429:e=>{e.exports=t},71128:(e,t,i)=>{i.r(t),i.d(t,{Popover:()=>f,PopoverController:()=>y}),i(96798),i(61200);var r=i(31890),o=i(28373),s=i(66677),n=i(5784),l=i(87161),p=i(70429),a=i(20291),h=i(68419),d=i(36365),c=i(3998),u=i(33759),v=i(86210),g=function(e,t,i,r){var o,s=arguments.length,n=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,r);else for(var l=e.length-1;l>=0;l--)(o=e[l])&&(n=(s<3?o(n):s>3?o(t,i,n):o(t,i))||n);return s>3&&n&&Object.defineProperty(t,i,n),n},m=function(e,t,i,r){return new(i||(i=Promise))(function(o,s){function n(e){try{p(r.next(e))}catch(e){s(e)}}function l(e){try{p(r.throw(e))}catch(e){s(e)}}function p(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(n,l)}p((r=r.apply(e,t||[])).next())})};class y{show(e){}hide(){}toggle(){}isVisible(){return!1}}let f=class extends((0,o.d)(l.LitElement)){set controller(e){e?(e.show=(e=!1)=>this.showPopover(e),e.hide=()=>this.hidePopover(),e.toggle=()=>this.togglePopoverVisible(),e.isVisible=()=>this.visible,this._controller=e):this._controller=null}get controller(){return this._controller}constructor(){super(),this.id="",this.triggerID="",this.trigger=h.zY.TRIGGER,this.placement=h.zY.PLACEMENT,this.strategy=h.zY.STRATEGY,this.color=h.zY.COLOR,this.visible=h.zY.VISIBLE,this.offset=h.zY.OFFSET,this.focusTrap=h.zY.FOCUS_TRAP,this.preventScroll=h.zY.PREVENT_SCROLL,this.showArrow=h.zY.ARROW,this.closeButton=h.zY.CLOSE_BUTTON,this.interactive=h.zY.INTERACTIVE,this.delay=h.zY.DELAY,this.hideOnEscape=h.zY.HIDE_ON_ESCAPE,this.hideOnBlur=h.zY.HIDE_ON_BLUR,this.hideOnWindowBlur=h.zY.HIDE_ON_WINDOW_BLUR,this.hideOnOutsideClick=h.zY.HIDE_ON_CLICK_OUTSIDE,this.focusBackToTrigger=h.zY.FOCUS_BACK,this.backdrop=h.zY.BACKDROP,this.flip=h.zY.FLIP,this.size=h.zY.SIZE,this.zIndex=h.zY.Z_INDEX,this.appendTo="",this.closeButtonAriaLabel=null,this.role=h.zY.ROLE,this.ariaLabelledby=null,this.ariaDescribedby=null,this.disableAriaExpanded=h.zY.DISABLE_ARIA_EXPANDED,this.animationFrame=h.zY.ANIMATION_FRAME,this._controller=null,this.arrowElement=null,this.triggerElement=null,this.hoverTimer=null,this.isTriggerClicked=!1,this.openDelay=0,this.closeDelay=0,this.backdropElement=null,this.useLegacyFindFocusable=()=>!1,this.cleanupAutoUpdate=null,this.previousActiveElement=null,this.onOutsidePopoverClick=e=>{const t=e.composedPath();this.triggerElement&&t.includes(this.triggerElement)||t.includes(this)||c.S.shouldDeferToTopForOutsideClick(this)||this.hideThisPopover()},this.hideThisPopover=()=>{setTimeout(()=>{this.visible=!1,this.isTriggerClicked=!1,this.utils.handleAppendTo(!1)},this.closeDelay)},this.onEscapeKeydown=e=>{this.visible&&"Escape"===e.code&&(e.preventDefault(),this.hidePopover())},this.onPopoverFocusOut=e=>{const t=e.relatedTarget;!t||this.isElementInPopover(t)?t||setTimeout(()=>{const e=(0,s.dw)();this.isElementInPopover(e)||this.hidePopover()},0):this.hidePopover()},this.handleWindowBlurEvent=()=>{this.visible&&this.hidePopover()},this.startCloseDelay=()=>{if(this.interactive){if(this.isTriggerClicked)return;this.hoverTimer=window.setTimeout(()=>{this.visible=!1},this.closeDelay)}else this.hidePopover()},this.cancelCloseDelay=()=>{this.hoverTimer&&(clearTimeout(this.hoverTimer),this.hoverTimer=null)},this.showPopover=(e=!1)=>{this.cancelCloseDelay(),e&&this.openDelay>0?setTimeout(()=>{this.utils.handleAppendTo(!0),this.visible=!0},this.openDelay):(this.utils.handleAppendTo(!0),this.visible=!0)},this.hidePopover=()=>{c.S.peek()===this&&setTimeout(()=>{this.visible=!1,this.isTriggerClicked=!1,this.utils.handleAppendTo(!1)},this.closeDelay)},this.togglePopoverVisible=()=>{this.isTriggerClicked?this.hidePopover():(this.showPopover(),this.isTriggerClicked=!0)},this.onMouseEnterTrigger=()=>{this.trigger.includes("mouseenter")&&(this.visible||(this.previousActiveElement=(0,s.dw)()),this.showPopover(!0))},this.onFocusInTrigger=()=>{this.trigger.includes("focusin")&&this.showPopover(!1)},this.onTriggerClick=e=>{this.trigger.includes("mouseenter")&&this.isMouseOverTrigger(e)||this.togglePopoverVisible()},this.utils=new u.h(this),this.preventClickOutside=!0}firstUpdated(e){const t=Object.create(null,{firstUpdated:{get:()=>super.firstUpdated}});return m(this,void 0,void 0,function*(){t.firstUpdated.call(this,e),[this.openDelay,this.closeDelay]=this.utils.setupDelay(),this.utils.setupAccessibility(),this.style.zIndex=`${this.zIndex}`,d.T.onCreatedPopover(this),this.visible&&(this.utils.handleAppendTo(!0),this.positionPopover(),yield this.handleCreatePopoverFirstUpdate())})}disconnectedCallback(){const e=Object.create(null,{disconnectedCallback:{get:()=>super.disconnectedCallback}});return m(this,void 0,void 0,function*(){e.disconnectedCallback.call(this),this.cleanupAutoUpdate&&(this.cleanupAutoUpdate(),this.cleanupAutoUpdate=null),this._controller=null,this.previousActiveElement=null,this.removeEventListeners(),d.T.onDestroyedPopover(this),c.S.remove(this)})}setupTriggerListener(){if(!this.triggerID)return;const e=this.getRootNode();if(this.triggerElement=(0,s.qi)(`[id="${this.triggerID}"]`,e),!this.triggerElement){const t=null==e?void 0:e.host;if(t){const e=t.querySelector("[slot]");(null==e?void 0:e.id)===this.triggerID&&(this.triggerElement=e)}}if(this.triggerElement){if("mouseenter"===this.trigger&&(this.interactive?this.trigger="mouseenter click":this.trigger="mouseenter focusin"),this.trigger.includes("click")&&this.triggerElement.addEventListener("click",this.onTriggerClick),this.trigger.includes("mouseenter")){const e=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.addEventListener("mouseenter",this.onMouseEnterTrigger),this.triggerElement.addEventListener("mouseleave",this.startCloseDelay),this.addEventListener("mouseenter",this.cancelCloseDelay),this.addEventListener("mouseleave",this.startCloseDelay),null==e||e.addEventListener("mouseenter",this.cancelCloseDelay)}this.trigger.includes("focusin")&&(this.triggerElement.addEventListener("focusin",this.onFocusInTrigger),this.interactive||this.triggerElement.addEventListener("focusout",this.hidePopover)),this.addEventListener("focus-trap-exit",this.hidePopover)}}removeEventListeners(){if(!this.triggerElement)return;const e=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.removeEventListener("click",this.onTriggerClick),this.triggerElement.removeEventListener("mouseenter",this.onMouseEnterTrigger),this.triggerElement.removeEventListener("mouseleave",this.hidePopover),this.removeEventListener("mouseenter",this.cancelCloseDelay),this.removeEventListener("mouseleave",this.startCloseDelay),this.triggerElement.removeEventListener("focusin",this.onFocusInTrigger),this.triggerElement.removeEventListener("focusout",this.hidePopover),null==e||e.removeEventListener("mouseenter",this.cancelCloseDelay),this.removeEventListener("focus-trap-exit",this.hidePopover)}updated(e){const t=Object.create(null,{updated:{get:()=>super.updated}});return m(this,void 0,void 0,function*(){if(t.updated.call(this,e),e.has("visible")){const t=e.get("visible")||!1;yield this.isOpenUpdated(t,this.visible),this.utils.updateAriaExpandedAttribute()}if(e.has("placement")&&this.setAttribute("placement",Object.values(h.ME).includes(this.placement)?this.placement:h.zY.PLACEMENT),e.has("delay")&&([this.openDelay,this.closeDelay]=this.utils.setupDelay()),e.has("trigger")){const e=this.trigger.split(" ").filter(e=>Object.values(h.tr).includes(e));this.setAttribute("trigger",e.length>0?this.trigger:h.zY.TRIGGER),this.removeEventListeners(),this.setupTriggerListener()}e.has("triggerID")&&(this.removeEventListeners(),this.setupTriggerListener(),this.utils.setupAccessibility()),e.has("color")&&this.setAttribute("color",Object.values(h.o$).includes(this.color)?this.color:h.zY.COLOR),e.has("zIndex")&&this.setAttribute("z-index",`${this.zIndex}`),(e.has("interactive")||e.has("aria-label")||e.has("aria-labelledby"))&&this.utils.setupAccessibility(),e.has("disableAriaExpanded")&&this.utils.updateAriaExpandedAttribute(),e.has("interactive")&&this.utils.updateAriaHasPopupAttribute()})}isElementInPopover(e){return!!e&&(!!this.contains(e)||(0,s.QZ)("md-popover",e)===this)}isOpenUpdated(e,t){const i=Object.create(null,{preventScroll:{get:()=>super.preventScroll,set:e=>super.preventScroll=e}});return m(this,void 0,void 0,function*(){var r,o,s,n;if(e!==t&&this.triggerElement)if(t)c.S.peek()!==this&&c.S.push(this),i.preventScroll=this.preventScroll,this.focusTrap&&(null===(r=this.activateFocusTrap)||void 0===r||r.call(this)),this.backdrop&&(this.utils.createBackdrop(),this.triggerElement.style.zIndex=`${this.zIndex}`),this.positionPopover(),yield this.handleCreatePopoverFirstUpdate(),this.hideOnBlur&&(this.addEventListener("focusout",this.onPopoverFocusOut),"click"===this.trigger&&(this.triggerElement.style.pointerEvents="none")),this.hideOnWindowBlur&&window.addEventListener("blur",this.handleWindowBlurEvent),this.hideOnOutsideClick&&document.addEventListener("click",this.onOutsidePopoverClick),this.hideOnEscape&&document.addEventListener("keydown",this.onEscapeKeydown),d.T.onShowPopover(this);else{if(this.cleanupAutoUpdate&&(this.cleanupAutoUpdate(),this.cleanupAutoUpdate=null),c.S.removeItem(this),this.backdropElement&&(null===(o=this.backdropElement)||void 0===o||o.remove(),this.backdropElement=null),this.hideOnBlur&&(this.removeEventListener("focusout",this.onPopoverFocusOut),"click"===this.trigger&&(this.triggerElement.style.pointerEvents="")),this.hideOnWindowBlur&&window.removeEventListener("blur",this.handleWindowBlurEvent),this.hideOnOutsideClick&&document.removeEventListener("click",this.onOutsidePopoverClick),this.hideOnEscape&&document.removeEventListener("keydown",this.onEscapeKeydown),null===(s=this.deactivateFocusTrap)||void 0===s||s.call(this),this.disableAriaExpanded||this.triggerElement.removeAttribute("aria-expanded"),this.interactive){const e=this.triggerElement.getAttribute("aria-haspopup");"dialog"!==e&&"alertdialog"!==e||this.triggerElement.removeAttribute("aria-haspopup")}this.focusBackToTrigger&&(this.previousActiveElement instanceof HTMLElement?this.previousActiveElement.focus():null===(n=this.setFocusOnDeepestNestedElement)||void 0===n||n.call(this,this.triggerElement)),this.previousActiveElement=null,d.T.onHidePopover(this)}})}isRectOverTrigger(e,t){if(this.triggerElement&&"undefined"!=typeof window&&"undefined"!=typeof document){const i=this.triggerElement.getBoundingClientRect();return e>=i.left&&e<=i.right&&t>=i.top&&t<=i.bottom}return!1}isMouseOverTrigger(e){const{clientX:t,clientY:i}=e instanceof MouseEvent?e:{clientX:0,clientY:0};return this.isRectOverTrigger(t,i)}handleCreatePopoverFirstUpdate(){return m(this,void 0,void 0,function*(){var e,t;this.visible&&this.interactive&&(null===(e=this.setFocusableElements)||void 0===e||e.call(this),yield this.updateComplete,null===(t=this.setInitialFocus)||void 0===t||t.call(this))})}positionPopover(){if(!this.triggerElement)return;this.cleanupAutoUpdate&&(this.cleanupAutoUpdate(),this.cleanupAutoUpdate=null);const e=[(0,n.shift)()];let t=this.offset;if(this.flip&&e.push((0,n.flip)()),this.size){const t=this.renderRoot.querySelector('[part="popover-content"]');e.push((0,n.size)({apply({availableHeight:e}){t&&Object.assign(t.style,{maxHeight:`${e}px`,overflowY:"auto"})},padding:50}))}if(this.showArrow&&(this.arrowElement=this.renderRoot.querySelector(".popover-arrow"),this.arrowElement)){const i=this.arrowElement.offsetHeight;t=Math.sqrt(2*i**2)/2+this.offset,e.push((0,n.arrow)({element:this.arrowElement,padding:12}))}e.push((0,n.offset)(t)),this.cleanupAutoUpdate=(0,n.autoUpdate)(this.triggerElement,this,()=>m(this,void 0,void 0,function*(){if(!this.triggerElement)return;const{x:t,y:i,middlewareData:r,placement:o}=yield(0,n.computePosition)(this.triggerElement,this,{placement:this.placement,middleware:e,strategy:this.strategy});this.utils.updatePopoverStyle(t,i),r.arrow&&this.arrowElement&&this.utils.updateArrowStyle(r.arrow,o),this.trigger.includes("mouseenter")&&this.utils.setupHoverBridge(o)}),{animationFrame:this.animationFrame})}render(){return l.html`
1
+ !function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("lit"),require("lit/decorators.js"),require("lit/directives/class-map.js"),require("lit/directives/style-map.js"),require("lit/directives/if-defined.js"),require("@momentum-ui/icons/data/momentumUiIconsNames.json"),require("@momentum-ui/utils/lib/getColorValue"),require("mobx"),require("@floating-ui/dom"));else if("function"==typeof define&&define.amd)define(["lit","lit/decorators.js","lit/directives/class-map.js","lit/directives/style-map.js","lit/directives/if-defined.js","@momentum-ui/icons/data/momentumUiIconsNames.json","@momentum-ui/utils/lib/getColorValue","mobx","@floating-ui/dom"],t);else{var i="object"==typeof exports?t(require("lit"),require("lit/decorators.js"),require("lit/directives/class-map.js"),require("lit/directives/style-map.js"),require("lit/directives/if-defined.js"),require("@momentum-ui/icons/data/momentumUiIconsNames.json"),require("@momentum-ui/utils/lib/getColorValue"),require("mobx"),require("@floating-ui/dom")):t(e.lit,e["lit/decorators.js"],e["lit/directives/class-map.js"],e["lit/directives/style-map.js"],e["lit/directives/if-defined.js"],e["@momentum-ui/icons/data/momentumUiIconsNames.json"],e["@momentum-ui/utils/lib/getColorValue"],e.mobx,e["@floating-ui/dom"]);for(var r in i)("object"==typeof exports?exports:e)[r]=i[r]}}(self,(e,t,i,r,o,s,n,l,p)=>(()=>{"use strict";var a,h={5784:e=>{e.exports=p},10318:e=>{e.exports=r},20291:e=>{e.exports=o},32022:e=>{e.exports=s},60554:e=>{e.exports=n},70429:e=>{e.exports=t},71128:(e,t,i)=>{i.r(t),i.d(t,{Popover:()=>y,PopoverController:()=>m}),i(96798),i(61200);var r=i(31890),o=i(28373),s=i(66677),n=i(5784),l=i(87161),p=i(70429),a=i(68419),h=i(36365),d=i(3998),c=i(33759),u=i(86210),v=function(e,t,i,r){var o,s=arguments.length,n=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,r);else for(var l=e.length-1;l>=0;l--)(o=e[l])&&(n=(s<3?o(n):s>3?o(t,i,n):o(t,i))||n);return s>3&&n&&Object.defineProperty(t,i,n),n},g=function(e,t,i,r){return new(i||(i=Promise))(function(o,s){function n(e){try{p(r.next(e))}catch(e){s(e)}}function l(e){try{p(r.throw(e))}catch(e){s(e)}}function p(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(n,l)}p((r=r.apply(e,t||[])).next())})};class m{show(e){}hide(){}toggle(){}isVisible(){return!1}}let y=class extends((0,o.d)(l.LitElement)){set controller(e){e?(e.show=(e=!1)=>this.showPopover(e),e.hide=()=>this.hidePopover(),e.toggle=()=>this.togglePopoverVisible(),e.isVisible=()=>this.visible,this._controller=e):this._controller=null}get controller(){return this._controller}constructor(){super(),this.id="",this.triggerID="",this.trigger=a.zY.TRIGGER,this.placement=a.zY.PLACEMENT,this.strategy=a.zY.STRATEGY,this.color=a.zY.COLOR,this.visible=a.zY.VISIBLE,this.offset=a.zY.OFFSET,this.focusTrap=a.zY.FOCUS_TRAP,this.preventScroll=a.zY.PREVENT_SCROLL,this.showArrow=a.zY.ARROW,this.closeButton=a.zY.CLOSE_BUTTON,this.interactive=a.zY.INTERACTIVE,this.delay=a.zY.DELAY,this.hideOnEscape=a.zY.HIDE_ON_ESCAPE,this.hideOnBlur=a.zY.HIDE_ON_BLUR,this.hideOnWindowBlur=a.zY.HIDE_ON_WINDOW_BLUR,this.hideOnOutsideClick=a.zY.HIDE_ON_CLICK_OUTSIDE,this.focusBackToTrigger=a.zY.FOCUS_BACK,this.backdrop=a.zY.BACKDROP,this.flip=a.zY.FLIP,this.size=a.zY.SIZE,this.zIndex=a.zY.Z_INDEX,this.appendTo="",this.closeButtonAriaLabel=null,this.role=a.zY.ROLE,this.ariaLabelledby=null,this.ariaDescribedby=null,this.disableAriaExpanded=a.zY.DISABLE_ARIA_EXPANDED,this.animationFrame=a.zY.ANIMATION_FRAME,this._controller=null,this.arrowElement=null,this.triggerElement=null,this.hoverTimer=null,this.isTriggerClicked=!1,this.openDelay=0,this.closeDelay=0,this.backdropElement=null,this.useLegacyFindFocusable=()=>!1,this.cleanupAutoUpdate=null,this.previousActiveElement=null,this.onOutsidePopoverClick=e=>{const t=e.composedPath();this.triggerElement&&t.includes(this.triggerElement)||t.includes(this)||d.S.shouldDeferToTopForOutsideClick(this)||this.hideThisPopover()},this.hideThisPopover=()=>{setTimeout(()=>{this.visible=!1,this.isTriggerClicked=!1,this.utils.handleAppendTo(!1)},this.closeDelay)},this.onEscapeKeydown=e=>{this.visible&&"Escape"===e.code&&(e.preventDefault(),this.hidePopover())},this.onPopoverFocusOut=e=>{const t=e.relatedTarget;!t||this.isElementInPopover(t)?t||setTimeout(()=>{const e=(0,s.dw)();this.isElementInPopover(e)||this.hidePopover()},0):this.hidePopover()},this.handleWindowBlurEvent=()=>{this.visible&&this.hidePopover()},this.startCloseDelay=()=>{if(this.interactive){if(this.isTriggerClicked)return;this.hoverTimer=window.setTimeout(()=>{this.visible=!1},this.closeDelay)}else this.hidePopover()},this.cancelCloseDelay=()=>{this.hoverTimer&&(clearTimeout(this.hoverTimer),this.hoverTimer=null)},this.showPopover=(e=!1)=>{this.cancelCloseDelay(),e&&this.openDelay>0?setTimeout(()=>{this.utils.handleAppendTo(!0),this.visible=!0},this.openDelay):(this.utils.handleAppendTo(!0),this.visible=!0)},this.hidePopover=()=>{d.S.peek()===this&&setTimeout(()=>{this.visible=!1,this.isTriggerClicked=!1,this.utils.handleAppendTo(!1)},this.closeDelay)},this.togglePopoverVisible=()=>{this.isTriggerClicked?this.hidePopover():(this.showPopover(),this.isTriggerClicked=!0)},this.onMouseEnterTrigger=()=>{this.trigger.includes("mouseenter")&&(this.visible||(this.previousActiveElement=(0,s.dw)()),this.showPopover(!0))},this.onFocusInTrigger=()=>{this.trigger.includes("focusin")&&this.showPopover(!1)},this.onTriggerClick=e=>{this.trigger.includes("mouseenter")&&this.isMouseOverTrigger(e)||this.togglePopoverVisible()},this.utils=new c.h(this),this.preventClickOutside=!0}firstUpdated(e){const t=Object.create(null,{firstUpdated:{get:()=>super.firstUpdated}});return g(this,void 0,void 0,function*(){t.firstUpdated.call(this,e),[this.openDelay,this.closeDelay]=this.utils.setupDelay(),this.utils.setupAccessibility(),this.style.zIndex=`${this.zIndex}`,h.T.onCreatedPopover(this),this.visible&&(this.utils.handleAppendTo(!0),this.positionPopover(),yield this.handleCreatePopoverFirstUpdate())})}disconnectedCallback(){const e=Object.create(null,{disconnectedCallback:{get:()=>super.disconnectedCallback}});return g(this,void 0,void 0,function*(){e.disconnectedCallback.call(this),this.cleanupAutoUpdate&&(this.cleanupAutoUpdate(),this.cleanupAutoUpdate=null),this._controller=null,this.previousActiveElement=null,this.removeEventListeners(),h.T.onDestroyedPopover(this),d.S.remove(this)})}setupTriggerListener(){if(!this.triggerID)return;const e=this.getRootNode();if(this.triggerElement=(0,s.qi)(`[id="${this.triggerID}"]`,e),!this.triggerElement){const t=null==e?void 0:e.host;if(t){const e=t.querySelector("[slot]");(null==e?void 0:e.id)===this.triggerID&&(this.triggerElement=e)}}if(this.triggerElement){if("mouseenter"===this.trigger&&(this.interactive?this.trigger="mouseenter click":this.trigger="mouseenter focusin"),this.trigger.includes("click")&&this.triggerElement.addEventListener("click",this.onTriggerClick),this.trigger.includes("mouseenter")){const e=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.addEventListener("mouseenter",this.onMouseEnterTrigger),this.triggerElement.addEventListener("mouseleave",this.startCloseDelay),this.addEventListener("mouseenter",this.cancelCloseDelay),this.addEventListener("mouseleave",this.startCloseDelay),null==e||e.addEventListener("mouseenter",this.cancelCloseDelay)}this.trigger.includes("focusin")&&(this.triggerElement.addEventListener("focusin",this.onFocusInTrigger),this.interactive||this.triggerElement.addEventListener("focusout",this.hidePopover)),this.addEventListener("focus-trap-exit",this.hidePopover)}}removeEventListeners(){if(!this.triggerElement)return;const e=this.renderRoot.querySelector(".popover-hover-bridge");this.triggerElement.removeEventListener("click",this.onTriggerClick),this.triggerElement.removeEventListener("mouseenter",this.onMouseEnterTrigger),this.triggerElement.removeEventListener("mouseleave",this.hidePopover),this.removeEventListener("mouseenter",this.cancelCloseDelay),this.removeEventListener("mouseleave",this.startCloseDelay),this.triggerElement.removeEventListener("focusin",this.onFocusInTrigger),this.triggerElement.removeEventListener("focusout",this.hidePopover),null==e||e.removeEventListener("mouseenter",this.cancelCloseDelay),this.removeEventListener("focus-trap-exit",this.hidePopover)}updated(e){const t=Object.create(null,{updated:{get:()=>super.updated}});return g(this,void 0,void 0,function*(){if(t.updated.call(this,e),e.has("visible")){const t=e.get("visible")||!1;yield this.isOpenUpdated(t,this.visible),this.utils.updateAriaExpandedAttribute()}if(e.has("placement")&&this.setAttribute("placement",Object.values(a.ME).includes(this.placement)?this.placement:a.zY.PLACEMENT),e.has("delay")&&([this.openDelay,this.closeDelay]=this.utils.setupDelay()),e.has("trigger")){const e=this.trigger.split(" ").filter(e=>Object.values(a.tr).includes(e));this.setAttribute("trigger",e.length>0?this.trigger:a.zY.TRIGGER),this.removeEventListeners(),this.setupTriggerListener()}e.has("triggerID")&&(this.removeEventListeners(),this.setupTriggerListener(),this.utils.setupAccessibility()),e.has("color")&&this.setAttribute("color",Object.values(a.o$).includes(this.color)?this.color:a.zY.COLOR),e.has("zIndex")&&this.setAttribute("z-index",`${this.zIndex}`),(e.has("interactive")||e.has("aria-label")||e.has("aria-labelledby"))&&this.utils.setupAccessibility(),e.has("disableAriaExpanded")&&this.utils.updateAriaExpandedAttribute(),e.has("interactive")&&this.utils.updateAriaHasPopupAttribute()})}isElementInPopover(e){return!!e&&(!!this.contains(e)||(0,s.QZ)("md-popover",e)===this)}isOpenUpdated(e,t){const i=Object.create(null,{preventScroll:{get:()=>super.preventScroll,set:e=>super.preventScroll=e}});return g(this,void 0,void 0,function*(){var r,o,s,n;if(e!==t&&this.triggerElement)if(t)d.S.peek()!==this&&d.S.push(this),i.preventScroll=this.preventScroll,this.focusTrap&&(null===(r=this.activateFocusTrap)||void 0===r||r.call(this)),this.backdrop&&(this.utils.createBackdrop(),this.triggerElement.style.zIndex=`${this.zIndex}`),this.utils.handleAppendTo(!0),this.positionPopover(),yield this.handleCreatePopoverFirstUpdate(),this.hideOnBlur&&(this.addEventListener("focusout",this.onPopoverFocusOut),"click"===this.trigger&&(this.triggerElement.style.pointerEvents="none")),this.hideOnWindowBlur&&window.addEventListener("blur",this.handleWindowBlurEvent),this.hideOnOutsideClick&&document.addEventListener("click",this.onOutsidePopoverClick),this.hideOnEscape&&document.addEventListener("keydown",this.onEscapeKeydown),h.T.onShowPopover(this);else{if(this.cleanupAutoUpdate&&(this.cleanupAutoUpdate(),this.cleanupAutoUpdate=null),d.S.removeItem(this),this.utils.handleAppendTo(!1),this.backdropElement&&(null===(o=this.backdropElement)||void 0===o||o.remove(),this.backdropElement=null),this.hideOnBlur&&(this.removeEventListener("focusout",this.onPopoverFocusOut),"click"===this.trigger&&(this.triggerElement.style.pointerEvents="")),this.hideOnWindowBlur&&window.removeEventListener("blur",this.handleWindowBlurEvent),this.hideOnOutsideClick&&document.removeEventListener("click",this.onOutsidePopoverClick),this.hideOnEscape&&document.removeEventListener("keydown",this.onEscapeKeydown),null===(s=this.deactivateFocusTrap)||void 0===s||s.call(this),this.disableAriaExpanded||this.triggerElement.removeAttribute("aria-expanded"),this.interactive){const e=this.triggerElement.getAttribute("aria-haspopup");"dialog"!==e&&"alertdialog"!==e||this.triggerElement.removeAttribute("aria-haspopup")}this.focusBackToTrigger&&(this.previousActiveElement instanceof HTMLElement?this.previousActiveElement.focus():null===(n=this.setFocusOnDeepestNestedElement)||void 0===n||n.call(this,this.triggerElement)),this.previousActiveElement=null,h.T.onHidePopover(this)}})}isRectOverTrigger(e,t){if(this.triggerElement&&"undefined"!=typeof window&&"undefined"!=typeof document){const i=this.triggerElement.getBoundingClientRect();return e>=i.left&&e<=i.right&&t>=i.top&&t<=i.bottom}return!1}isMouseOverTrigger(e){const{clientX:t,clientY:i}=e instanceof MouseEvent?e:{clientX:0,clientY:0};return this.isRectOverTrigger(t,i)}setFocusableElements(){var e;null===(e=super.setFocusableElements)||void 0===e||e.call(this);const t=this.triggerElement;this.appendTo&&this.activeFocusTrap&&t&&this.focusableElements&&(this.focusableElements.includes(t)||this.focusableElements.push(t))}handleCreatePopoverFirstUpdate(){return g(this,void 0,void 0,function*(){var e,t;this.visible&&this.interactive&&(null===(e=this.setFocusableElements)||void 0===e||e.call(this),yield this.updateComplete,null===(t=this.setInitialFocus)||void 0===t||t.call(this))})}positionPopover(){if(!this.triggerElement)return;this.cleanupAutoUpdate&&(this.cleanupAutoUpdate(),this.cleanupAutoUpdate=null);const e=[(0,n.shift)()];let t=this.offset;if(this.flip&&e.push((0,n.flip)()),this.size){const t=this.renderRoot.querySelector('[part="popover-content"]');e.push((0,n.size)({apply({availableHeight:e}){t&&Object.assign(t.style,{maxHeight:`${e}px`,overflowY:"auto"})},padding:50}))}if(this.showArrow&&(this.arrowElement=this.renderRoot.querySelector(".popover-arrow"),this.arrowElement)){const i=this.arrowElement.offsetHeight;t=Math.sqrt(2*i**2)/2+this.offset,e.push((0,n.arrow)({element:this.arrowElement,padding:12}))}e.push((0,n.offset)(t)),this.cleanupAutoUpdate=(0,n.autoUpdate)(this.triggerElement,this,()=>g(this,void 0,void 0,function*(){if(!this.triggerElement)return;const{x:t,y:i,middlewareData:r,placement:o}=yield(0,n.computePosition)(this.triggerElement,this,{placement:this.placement,middleware:e,strategy:this.strategy});this.utils.updatePopoverStyle(t,i),r.arrow&&this.arrowElement&&this.utils.updateArrowStyle(r.arrow,o),this.trigger.includes("mouseenter")&&this.utils.setupHoverBridge(o)}),{animationFrame:this.animationFrame})}render(){return l.html`
2
2
  <div class="popover-hover-bridge"></div>
3
3
  ${this.closeButton?l.html` <md-button
4
4
  class="popover-close"
5
5
  hasRemoveStyle
6
6
  size="20"
7
7
  circle
8
- ariaLabel=${(0,a.ifDefined)(this.closeButtonAriaLabel)||""}
9
- @button-click="${this.hidePopover}"
8
+ .ariaLabel=${this.closeButtonAriaLabel}
9
+ @button-click=${this.hidePopover}
10
10
  >
11
11
  <md-icon name="cancel-bold" size="16" iconSet="momentumDesign"></md-icon>
12
12
  </md-button>`:l.nothing}
@@ -14,4 +14,4 @@
14
14
  <div part="popover-content">
15
15
  <slot></slot>
16
16
  </div>
17
- `}static get styles(){return[v.A]}};g([(0,p.property)({type:String,reflect:!0})],f.prototype,"id",void 0),g([(0,p.property)({type:String,reflect:!0})],f.prototype,"triggerID",void 0),g([(0,p.property)({type:String,reflect:!0})],f.prototype,"trigger",void 0),g([(0,p.property)({type:String,reflect:!0})],f.prototype,"placement",void 0),g([(0,p.property)({type:String,reflect:!0})],f.prototype,"strategy",void 0),g([(0,p.property)({type:String,reflect:!0})],f.prototype,"color",void 0),g([(0,p.property)({type:Boolean,reflect:!0})],f.prototype,"visible",void 0),g([(0,p.property)({type:Number,reflect:!0})],f.prototype,"offset",void 0),g([(0,p.property)({type:Boolean,reflect:!0,attribute:"focus-trap"})],f.prototype,"focusTrap",void 0),g([(0,p.property)({type:Boolean,reflect:!0,attribute:"prevent-scroll"})],f.prototype,"preventScroll",void 0),g([(0,p.property)({type:Boolean,reflect:!0,attribute:"show-arrow"})],f.prototype,"showArrow",void 0),g([(0,p.property)({type:Boolean,reflect:!0,attribute:"close-button"})],f.prototype,"closeButton",void 0),g([(0,p.property)({type:Boolean,reflect:!0})],f.prototype,"interactive",void 0),g([(0,p.property)({type:String,reflect:!0})],f.prototype,"delay",void 0),g([(0,p.property)({type:Boolean,reflect:!0,attribute:"hide-on-escape"})],f.prototype,"hideOnEscape",void 0),g([(0,p.property)({type:Boolean,reflect:!0,attribute:"hide-on-blur"})],f.prototype,"hideOnBlur",void 0),g([(0,p.property)({type:Boolean,reflect:!0,attribute:"hide-on-window-blur"})],f.prototype,"hideOnWindowBlur",void 0),g([(0,p.property)({type:Boolean,reflect:!0,attribute:"hide-on-outside-click"})],f.prototype,"hideOnOutsideClick",void 0),g([(0,p.property)({type:Boolean,reflect:!0,attribute:"focus-back-to-trigger"})],f.prototype,"focusBackToTrigger",void 0),g([(0,p.property)({type:Boolean,reflect:!0})],f.prototype,"backdrop",void 0),g([(0,p.property)({type:Boolean,reflect:!0})],f.prototype,"flip",void 0),g([(0,p.property)({type:Boolean,reflect:!0})],f.prototype,"size",void 0),g([(0,p.property)({type:Number,reflect:!0,attribute:"z-index"})],f.prototype,"zIndex",void 0),g([(0,p.property)({type:String,reflect:!0,attribute:"append-to"})],f.prototype,"appendTo",void 0),g([(0,p.property)({type:String,attribute:"close-button-aria-label",reflect:!0})],f.prototype,"closeButtonAriaLabel",void 0),g([(0,p.property)({type:String,reflect:!0})],f.prototype,"role",void 0),g([(0,p.property)({type:String,reflect:!0,attribute:"aria-labelledby"})],f.prototype,"ariaLabelledby",void 0),g([(0,p.property)({type:String,reflect:!0,attribute:"aria-describedby"})],f.prototype,"ariaDescribedby",void 0),g([(0,p.property)({type:Boolean,reflect:!0,attribute:"disable-aria-expanded"})],f.prototype,"disableAriaExpanded",void 0),g([(0,p.property)({type:Boolean,reflect:!0,attribute:"animation-frame"})],f.prototype,"animationFrame",void 0),g([(0,p.property)({type:Object,attribute:!1})],f.prototype,"controller",null),f=g([(0,r.w)("md-popover")],f)},85125:e=>{e.exports=i},85314:e=>{e.exports=l},87161:t=>{t.exports=e}},d={};function c(e){var t=d[e];if(void 0!==t)return t.exports;var i=d[e]={exports:{}};return h[e](i,i.exports,c),i.exports}c.m=h,a=[],c.O=(e,t,i,r)=>{if(!t){var o=1/0;for(p=0;p<a.length;p++){for(var[t,i,r]=a[p],s=!0,n=0;n<t.length;n++)(!1&r||o>=r)&&Object.keys(c.O).every(e=>c.O[e](t[n]))?t.splice(n--,1):(s=!1,r<o&&(o=r));if(s){a.splice(p--,1);var l=i();void 0!==l&&(e=l)}}return e}r=r||0;for(var p=a.length;p>0&&a[p-1][2]>r;p--)a[p]=a[p-1];a[p]=[t,i,r]},c.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return c.d(t,{a:t}),t},c.d=(e,t)=>{for(var i in t)c.o(t,i)&&!c.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},c.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),c.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{var e={3413:0};c.O.j=t=>0===e[t];var t=(t,i)=>{var r,o,[s,n,l]=i,p=0;if(s.some(t=>0!==e[t])){for(r in n)c.o(n,r)&&(c.m[r]=n[r]);if(l)var a=l(c)}for(t&&t(i);p<s.length;p++)o=s[p],c.o(e,o)&&e[o]&&e[o][0](),e[o]=0;return c.O(a)},i=self["momentum-web-components-[id]"]=self["momentum-web-components-[id]"]||[];i.forEach(t.bind(null,0)),i.push=t.bind(null,i.push.bind(i))})();var u=c.O(void 0,[6633,1890,4313,510,6283,5087,2176,6798,6865,1200,2576,8210,1270,3135,8345,1439],()=>c(71128));return c.O(u)})());
17
+ `}static get styles(){return[u.A]}};v([(0,p.property)({type:String,reflect:!0})],y.prototype,"id",void 0),v([(0,p.property)({type:String,reflect:!0})],y.prototype,"triggerID",void 0),v([(0,p.property)({type:String,reflect:!0})],y.prototype,"trigger",void 0),v([(0,p.property)({type:String,reflect:!0})],y.prototype,"placement",void 0),v([(0,p.property)({type:String,reflect:!0})],y.prototype,"strategy",void 0),v([(0,p.property)({type:String,reflect:!0})],y.prototype,"color",void 0),v([(0,p.property)({type:Boolean,reflect:!0})],y.prototype,"visible",void 0),v([(0,p.property)({type:Number,reflect:!0})],y.prototype,"offset",void 0),v([(0,p.property)({type:Boolean,reflect:!0,attribute:"focus-trap"})],y.prototype,"focusTrap",void 0),v([(0,p.property)({type:Boolean,reflect:!0,attribute:"prevent-scroll"})],y.prototype,"preventScroll",void 0),v([(0,p.property)({type:Boolean,reflect:!0,attribute:"show-arrow"})],y.prototype,"showArrow",void 0),v([(0,p.property)({type:Boolean,reflect:!0,attribute:"close-button"})],y.prototype,"closeButton",void 0),v([(0,p.property)({type:Boolean,reflect:!0})],y.prototype,"interactive",void 0),v([(0,p.property)({type:String,reflect:!0})],y.prototype,"delay",void 0),v([(0,p.property)({type:Boolean,reflect:!0,attribute:"hide-on-escape"})],y.prototype,"hideOnEscape",void 0),v([(0,p.property)({type:Boolean,reflect:!0,attribute:"hide-on-blur"})],y.prototype,"hideOnBlur",void 0),v([(0,p.property)({type:Boolean,reflect:!0,attribute:"hide-on-window-blur"})],y.prototype,"hideOnWindowBlur",void 0),v([(0,p.property)({type:Boolean,reflect:!0,attribute:"hide-on-outside-click"})],y.prototype,"hideOnOutsideClick",void 0),v([(0,p.property)({type:Boolean,reflect:!0,attribute:"focus-back-to-trigger"})],y.prototype,"focusBackToTrigger",void 0),v([(0,p.property)({type:Boolean,reflect:!0})],y.prototype,"backdrop",void 0),v([(0,p.property)({type:Boolean,reflect:!0})],y.prototype,"flip",void 0),v([(0,p.property)({type:Boolean,reflect:!0})],y.prototype,"size",void 0),v([(0,p.property)({type:Number,reflect:!0,attribute:"z-index"})],y.prototype,"zIndex",void 0),v([(0,p.property)({type:String,reflect:!0,attribute:"append-to"})],y.prototype,"appendTo",void 0),v([(0,p.property)({type:String,attribute:"close-button-aria-label",reflect:!0})],y.prototype,"closeButtonAriaLabel",void 0),v([(0,p.property)({type:String,reflect:!0})],y.prototype,"role",void 0),v([(0,p.property)({type:String,reflect:!0,attribute:"aria-labelledby"})],y.prototype,"ariaLabelledby",void 0),v([(0,p.property)({type:String,reflect:!0,attribute:"aria-describedby"})],y.prototype,"ariaDescribedby",void 0),v([(0,p.property)({type:Boolean,reflect:!0,attribute:"disable-aria-expanded"})],y.prototype,"disableAriaExpanded",void 0),v([(0,p.property)({type:Boolean,reflect:!0,attribute:"animation-frame"})],y.prototype,"animationFrame",void 0),v([(0,p.property)({type:Object,attribute:!1})],y.prototype,"controller",null),y=v([(0,r.w)("md-popover")],y)},85125:e=>{e.exports=i},85314:e=>{e.exports=l},87161:t=>{t.exports=e}},d={};function c(e){var t=d[e];if(void 0!==t)return t.exports;var i=d[e]={exports:{}};return h[e](i,i.exports,c),i.exports}c.m=h,a=[],c.O=(e,t,i,r)=>{if(!t){var o=1/0;for(p=0;p<a.length;p++){for(var[t,i,r]=a[p],s=!0,n=0;n<t.length;n++)(!1&r||o>=r)&&Object.keys(c.O).every(e=>c.O[e](t[n]))?t.splice(n--,1):(s=!1,r<o&&(o=r));if(s){a.splice(p--,1);var l=i();void 0!==l&&(e=l)}}return e}r=r||0;for(var p=a.length;p>0&&a[p-1][2]>r;p--)a[p]=a[p-1];a[p]=[t,i,r]},c.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return c.d(t,{a:t}),t},c.d=(e,t)=>{for(var i in t)c.o(t,i)&&!c.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},c.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),c.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{var e={3413:0};c.O.j=t=>0===e[t];var t=(t,i)=>{var r,o,[s,n,l]=i,p=0;if(s.some(t=>0!==e[t])){for(r in n)c.o(n,r)&&(c.m[r]=n[r]);if(l)var a=l(c)}for(t&&t(i);p<s.length;p++)o=s[p],c.o(e,o)&&e[o]&&e[o][0](),e[o]=0;return c.O(a)},i=self["momentum-web-components-[id]"]=self["momentum-web-components-[id]"]||[];i.forEach(t.bind(null,0)),i.push=t.bind(null,i.push.bind(i))})();var u=c.O(void 0,[6633,1890,4313,510,6283,5087,2176,6798,6865,1200,2576,8210,1270,3135,8345,1439],()=>c(71128));return c.O(u)})());
@@ -63,7 +63,7 @@
63
63
  id="${this.getCopyTabId(e)}"
64
64
  aria-label=${e.ariaLabel}
65
65
  aria-controls="${this.getAriaControlId(e)}"
66
- @click="${()=>this.handleOverlayClose()}"
66
+ @click=${this.handleOverlayClose}
67
67
  tabIndex="${this.tabHiddenIdPositiveTabIndex===e.id?0:-1}"
68
68
  role="menuitem"
69
69
  ?newMomentum=${this.newMomentum}
@@ -80,8 +80,8 @@
80
80
  max-height="${"288px"}"
81
81
  class="md-menu-overlay__more ${(0,b.classMap)({"md-menu-overlay__more--hidden":this.isMoreTabMenuMeasured&&!this.isMoreTabMenuVisible})}"
82
82
  placement="bottom-end"
83
- @menu-overlay-open="${()=>this.isMoreTabMenuOpen=!0}"
84
- @menu-overlay-close="${()=>this.isMoreTabMenuOpen=!1}"
83
+ @menu-overlay-open=${()=>this.isMoreTabMenuOpen=!0}
84
+ @menu-overlay-close=${()=>this.isMoreTabMenuOpen=!1}
85
85
  >
86
86
  ${this.moreMenuButtonTemplate}
87
87
  <div
@@ -85,7 +85,7 @@
85
85
  ${this.lastmessage?l.nothing:l.html` <slot name="lastmessage"></slot> `}
86
86
  </div>
87
87
  <div class="md-taskitem__addition ${(0,p.classMap)({empty_addition:this.additionEmptyMargin})}">
88
- <slot @slotchange="${this.handleAdditionSlotChange}"></slot>
88
+ <slot @slotchange=${this.handleAdditionSlotChange}></slot>
89
89
  ${(0,h.Um)(this.quantity,this.isRestyle,this)}
90
90
  </div>
91
91
  </div>
@@ -12,9 +12,9 @@
12
12
  max=${(0,h.ifDefined)(e.max)}
13
13
  maxLength=${2}
14
14
  placeholder="${y[t]}"
15
- @input-change="${e=>this.handleTimeChange(e,t)}"
16
- @input-keydown="${e=>this.handleTimeKeyDown(e,t)}"
17
- @input-blur="${e=>this.handleTimeBlur(e,t)}"
15
+ @input-change=${e=>this.handleTimeChange(e,t)}
16
+ @input-keydown=${e=>this.handleTimeKeyDown(e,t)}
17
+ @input-blur=${e=>this.handleTimeBlur(e,t)}
18
18
  .messageArr=${[{message:"",type:this.messageType(this.timeValidity[t])}]}
19
19
  .ariaLabel="${t}-input"
20
20
  ariaInvalid="${!this.timeValidity[t]}"
@@ -31,7 +31,7 @@
31
31
  no-clear-icon
32
32
  .inputValue=${this.timeValue[s.R5.AM_PM]}
33
33
  .ariaLabel=${this.timeValue[s.R5.AM_PM]}
34
- @change-selected="${t=>this.handleTimeChange(t,s.R5.AM_PM)}"
34
+ @change-selected=${t=>this.handleTimeChange(t,s.R5.AM_PM)}
35
35
  >
36
36
  </md-combobox>
37
37
  `}get timePickerClassMap(){return{"twenty-four-hour-format":this.finalTwentyFourFormat}}connectedCallback(){super.connectedCallback(),this.initializeTimeValues()}updated(t){super.updated(t),["value","locale","twentyFourHourFormat","showDefaultNowTime","timeSpecificity"].some(e=>t.has(e))&&this.initializeTimeValues()}initializeTimeValues(){if(this.showDefaultNowTime||this.value){const t=this.value||(0,r.tB)().toISOTime({suppressMilliseconds:!0});t&&this.updateValue(t)}else{const t=c.DateTime.now().setLocale(this.locale),e=this.getLocaleTimeFormat(t);this.finalTwentyFourFormat=this.twentyFourHourFormat||e;const i=this.timeSpecificity===s.R5.MINUTE||this.timeSpecificity===s.R5.SECOND,o=this.timeSpecificity===s.R5.SECOND;this.timeValue={[s.R5.HOUR]:"",[s.R5.MINUTE]:i?"":"00",[s.R5.SECOND]:o?"":"00",[s.R5.AM_PM]:"AM"}}}updateValue(t){const e=t||this.value;if(!e)return;this.timeObject=c.DateTime.fromISO(e,{locale:this.locale});const i=this.getLocaleTimeFormat(this.timeObject);this.finalTwentyFourFormat=this.twentyFourHourFormat||i,this.value=this.timeObject.toISOTime({suppressMilliseconds:!0}),this.updateTimeValues()}dispatchTimeChangeEvent(){this.dispatchEvent(new CustomEvent("time-selection-change",{bubbles:!0,composed:!0,detail:{time:this.value,data:this.timeObject,isValid:this.isEntireTimeValid()}}))}handleTimeChange(t,e){var i,o,r;this.timeValue[e]=null===(i=null==t?void 0:t.detail)||void 0===i?void 0:i.value,this.requestUpdate(),this.formatTimeUnit(e);const a=this.timeValue[e];if(this.twoDigitAutoTab&&this.tabNext&&(e!==s.R5.AM_PM&&2===a.length&&"0"!==a[0]||"00"===a)){t.preventDefault();const e=null==t?void 0:t.target,i=null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelectorAll("md-input, md-combobox");if(i){const t=Array.prototype.findIndex.call(i,t=>null==e?void 0:e.isEqualNode(t)),s=(t+1)%i.length;if(t<i.length-1){const t=null===(r=i[s].shadowRoot)||void 0===r?void 0:r.querySelector("input");null==t||t.focus()}}}else e===s.R5.AM_PM&&this.updateTimeUnit(e);t.stopPropagation(),this.dispatchEvent(new CustomEvent(`${e}-change`,{bubbles:!0,composed:!0,detail:{srcEvent:t,value:`${this.timeValue[e]}`,isValid:this.timeValidity[e]}}))}handleTimeKeyDown(t,e){var i;const o=null===(i=null==t?void 0:t.detail)||void 0===i?void 0:i.srcEvent;if(!o)return void console.warn("srcEvent is undefined");const{key:r}=o;r===s.Uz.ArrowDown||r===s.Uz.ArrowUp?this.tabNext=!1:this.tabNext=!0,this.timeValidity[e]=!0,this.requestUpdate(),t.stopPropagation(),this.dispatchEvent(new CustomEvent(`${e}-keydown`,{bubbles:!0,composed:!0,detail:{srcEvent:t,value:`${this.timeValue[e]}`}}))}handleTimeBlur(t,e){"0"===this.timeValue[e]&&(this.timeValue[e]="00"),this.updateTimeUnit(e),this.requestUpdate(),t.stopPropagation(),this.dispatchEvent(new CustomEvent(`${e}-blur`,{bubbles:!0,composed:!0,detail:{srcEvent:t,time:this.value,isValid:this.timeValidity[e]}}))}static get styles(){return[n.A,d.A]}render(){return l.html`