Full explainer available here
This proposal introduces additional ways for web applications to introspect and control their windows, to enable critical window management functionality on the web platform.
The proposed enhancement would allow web applications to maximize, minimize, and restore their windows and introspect that window display state. Further, it allows applications to be notified when the window is repositioned, and control whether the window can be resized. The window placement permission will be required for these capabilities.
Virtual Desktop Infrastructure (VDI) web clients have limited abilities to integrate remote application windows with the local desktop environment, which creates suboptimal experiences for their users. Currently, they can only present full disjoint remote desktop environments (e.g. in a local fullscreen window), or present individual remote applications in separate local windows with titlebar window controls that are inoperative, redundant, and confusing for users.
Remote window presented within a local window
Several VDI clients, including Citrix and VMWare, have reported that their users strongly desire an integrated experience as their work is increasingly happening both on local client and remote host devices.
Unfortunately, the web platform offers no means for web applications to signal the user agent when users interact with remote application (or custom) window controls. Further, web applications cannot introspect the local window’s display state, and must poll for local window position changes. These platform gaps create disconnects between local and remote windows, and prevent web VDI clients from offering functionality expected by users.
These missing capabilities also prevent a broader set of web applications from offering compelling window management experiences for their users.
This proposal seeks to enable local web applications to convey a user’s intended window control interactions with remote (or custom) window controls. Summary of the API proposals, which are generally gated by Window Management (“window-placement”) permission:
await window.minimize()/maximize()/restore()changes the window display state
window.displayStateyields the current display state
window.ondisplaystatechangeevent is fired when the window display state changes
window.onmoveevent is fired when the window moves
await window.setResizable(bool)sets whether the window is user resizable
window.resizableyields whether the window is user resizable
Use cases explored here also rely upon a parallel effort to standardize the existing CSS property -webkit-app-region/app-region.