Fixed accessibility issue where few dialogs are not rendering properly

when we zoomed in browser window 200% and screen resolution is low.

Fixes #5662
This commit is contained in:
Murtuza Zabuawala
2020-07-09 18:18:37 +05:30
committed by Akshay Joshi
parent 3c08e618bd
commit 2db9242f5c
9 changed files with 61 additions and 10 deletions
+29
View File
@@ -171,12 +171,41 @@ define('pgadmin.browser', [
md: 700,
lg: 900,
default: 500,
// If you change above values then make sure to update
// calc method logic
calc: () => {
let iw = window.innerWidth;
if (iw > pgAdmin.Browser.stdW.lg)
return pgAdmin.Browser.stdW.lg;
else if (iw > pgAdmin.Browser.stdW.md)
return pgAdmin.Browser.stdW.md;
else if (iw > pgAdmin.Browser.stdW.sm)
return pgAdmin.Browser.stdW.sm;
else
// if avilable screen resolution is still
// less then return the width value as it
return iw;
},
},
stdH: {
sm: 200,
md: 400,
lg: 550,
default: 550,
// If you change above values then make sure to update
// calc method logic
calc: () => {
// We are excluding sm as it is too small for dialog
let ih = window.innerHeight;
if (ih > pgAdmin.Browser.stdH.lg)
return pgAdmin.Browser.stdH.lg;
else if (ih > pgAdmin.Browser.stdH.md)
return pgAdmin.Browser.stdH.md;
else
// if avilable screen resolution is still
// less then return the height value as it
return ih;
},
},
// Default panels
panels: {