8000 Browser zoom unit for accessibility [css-values-and-units] · Issue #6869 · w3c/csswg-drafts · GitHub
[go: up one dir, main page]

Skip to content

Browser zoom unit for accessibility [css-values-and-units] #6869

@scottkellum

Description

@scottkellum
< 6F10 /div>

Currently all browsers scale the size of a pixel in order to zoom into a page by default. As a result, a zoomed in viewport is indistinguishable from a narrower viewport. This may result in unintended layout shifts as media queries are triggered as well as problems scaling responsive typography to be compatible with SC 1.4.4.

CSS authors need a way to identify zoom level so that we can create affordances for accessibility issues that may arise as a result of how zoom is currently implemented.

Two possible solutions:

  1. A CSS keyword value that is effectively a unitless scale factor and can be used in calc functions.
h1 {
  font-size: calc(6vw * zoom);
}
  1. Setting a standard for browsers to zoom the root font size instead of the size of a pixel. This will enable people to have finite control over what scales using relative units. Scale factor can be discovered with calc(1rem / 16px).
    Note: I don’t expect this to be an acceptable solution as the web has tried this and moved away from it to create a more consistent experience as many websites don’t use relative units.

Metadata

Metadata

Assignees

No one assigned

    Labels

    a11y-trackerGroup bringing to attention of a11y, or tracked by the a11y Group but not needing response.css-fonts-5css-values-5

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0