w3c / wcag

Web Content Accessibility Guidelines
https://w3c.github.io/wcag/guidelines/22/
Other
1.11k stars 251 forks source link

1.3.4 Orientation - F97 (Locking orientation) - screen size irrelevant in testing? #877

Closed detlevhfischer closed 5 months ago

detlevhfischer commented 5 years ago

The test procedure of https://www.w3.org/WAI/WCAG21/Techniques/failures/F97.html currently does not specify a specific screen size and/or device type. I wonder whether there are situations where the fact that orientation change is prevented may depend on the screen size detected which could mean that the SC needs to be tested at particular screen size bands. After all, there are even desktop screens that can swivel ( and I would predict that changing orientation here will rarely be prevented).

The practical reason I am asking is that we currently specify for the test of 1.3.4 Orientation to use a smartphone "with a screen diagonal of between 4 and 6 inch". This may be unnecessarily specific - orientation locking may equally be detected when using a tablet. However, on a larger screen, another layout may be used with other (possibly viewport-size-dependent) rules regarding the locking behaviour. Any thoughts?

patrickhlauke commented 5 years ago

screen size should not matter. and some sites may, even on desktop, prevent a particular orientation by checking things like the ratio between width and height (irrespective of actual dimensions) and do some weird stuff like apply a transform that counteracts the rotation or something. it's technically feasible in any case.

detlevhfischer commented 5 years ago

Sylvia Egger made me aware that with iPadOS the desktop version will be loaded by default which might suggest that orientation is better tested on a smartphone - even though orientation should apply to desktop as well (swivelling desktop screens).

patrickhlauke commented 5 years ago

In theory, you'd need to test the SCs (including this one) at all responsive variations separately, no? (per the new note in https://www.w3.org/TR/WCAG21/#cc2)

jake-abma commented 5 years ago

The new Note does not specifically mentioned it, but this should also be the use or portrait / landscape properties, not only the 'break points'

patrickhlauke commented 5 years ago

could argue that changing orientation is a change of screen size (the width and height are swapped around)

alastc commented 5 years ago

My understanding is that there are two principle means of detecting orientation:

  1. An orientation setting, e.g. a media query or JS call that asks the device and is told what the orientation is set as.
  2. Detecting the viewport size and working it out. E.g. 1024 wide by 768 high = landscape.

Ideally we'd ignore the mechanism, but is there a concrete improvement we can make to test procedures? (Or elsewhere)

JAWS-test commented 4 years ago

In theory, you'd need to test the SCs (including this one) at all responsive variations separately, no? (per the new note in https://www.w3.org/TR/WCAG21/#cc2)

That's right, However, the question would still be how high the display is for the test if the breakpoints are only defined for the width. For example, if I have a fixed header and footer, turning the device can cause me to not see the page content, even if no new breakpoint of the media query has been reached. I.e. the page height plays an important role. Which minimum page height must work? In my opinion, this is not defined and prevents objective test results.

patrickhlauke commented 3 years ago

My understanding is that there are two principle means of detecting orientation:

  1. An orientation setting, e.g. a media query or JS call that asks the device and is told what the orientation is set as.
  2. Detecting the viewport size and working it out. E.g. 1024 wide by 768 high = landscape.

Ideally we'd ignore the mechanism, but is there a concrete improvement we can make to test procedures? (Or elsewhere)

I would suggest that we need to provide more explicit failure techniques/examples, that demonstrate how a site may fall foul of the SC:

For these, you then have different tests. For the deviceorientation and orientation ones, you'd have to test either with a real device that allows (and exposes) rotation, or use an emulator that lets you define this explicitly. for the others, resizing your browser viewport on a desktop to be more landscap-y or portrait-y would work.

And, as noted, you'd need to run the tests at all possible breakpoints, per https://www.w3.org/TR/WCAG21/#cc2

fstrr commented 5 months ago

This issue looks like it can be closed. If it needs to be re-opened, please do that and convert it to a Discussion.