[pve-devel] [PATCH widget-toolkit] fix #6312: limit consent window to viewport size
Thomas Lamprecht
t.lamprecht at proxmox.com
Wed May 14 14:37:22 CEST 2025
Am 11.04.25 um 12:01 schrieb Dominik Csapak:
> The consent window will try to size itself according to the max/min
> constraints set, but those might be too large for some viewport sizes.
>
> Since it's not possible to set those to relative viewport sizes (ExtJS
> does it's own layout, so we can't use CSS), we have to save the original
> size (while factoring in the constraints) and on resize of the viewport
> (or the window) limit ourselves to that (minus 10 px safety margin).
The window is now quite a bit shorter, requiring much more scrolling even
though my Browser Viewport has lots of (vertical) space left.
Without looking into this much it seems your original size calculation
might be off.
>
> Even with that the window will adhere to the set constraint sizes,
> but it should be viewable with any sensible display/viewport size.
>
> Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
> ---
> we could think about implementing such a limit for all of our windows
> in e.g. Toolkit.js, but I'm not sure if that's wise, since not all
> windows are as flexible with the size as the consent window.
With both ExtJS and our layouting on top this would probably indeed not
work out really well in practice, so I'd not do that for now.
More information about the pve-devel
mailing list