Prevent screen 'shaking' on invocation of a popup window

This commit is contained in:
Aljaž Grilc 2024-04-04 14:33:08 +02:00
parent ccbd80dcb7
commit 5b13bd3d28

View File

@ -900,9 +900,7 @@ class BesPopupEl extends HTMLElement {
this.shadowRoot.innerHTML = `
<style>
:host {
position: relative;
display: inline-block;
z-index: -1
display: none;
}
:host(.show){
z-index: 10;
@ -981,6 +979,7 @@ class BesPopupEl extends HTMLElement {
this.style.position = 'fixed'
this.style.left = `${x}px`
this.style.top = `${y}px`
this.style.display = 'block'
const viewportWidth = window.innerWidth
const viewportHeight = window.innerHeight