w3c / window-management

Window Management API
https://www.w3.org/TR/window-management/
Other
95 stars 25 forks source link

Localization of the screen `label` #126

Open aphillips opened 1 year ago

aphillips commented 1 year ago

Section 2.1 Screen https://www.w3.org/TR/window-placement/#screen-label

A screen has a label, which is a string that meaningfully describes the screen to a user to help them identify and differentiate screens.

Note: The label can be an arbitrary string selected by the user agent. It could describe the screen relative to the device, e.g. "internal" vs. "external", it could include the dimensions, e.g. "640×480", it could include hardware model information, e.g. "Acme Telletube 1000x" from VESA E-EDID data, it could include a distinguishing number, e.g. "screen 1" vs. "screen 2", or all of the preceding. The label can be an empty string if underlying display details are unknown or the user agent chooses to hide that information. Applications can’t assume that the label contains any specific information, such as the device type, model, dimensions, density, etc.

There is no mention of how the label should be localized. I18N thinks it would be helpful if there was at least a nod to providing localized labels. An interesting question might be whether the caller can (try to) specify the locale for the label (in JS by passing an Intl.Locale, for example) or if the host environment or user agent solely determines the value(s).