-
Notifications
You must be signed in to change notification settings - Fork 792
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New Rule: css-orientation-is-not-locked #851
Comments
I don't really understand the checks you are proposing. What I would suggest is that we check if someone used this CSS orientation lock trick: https://css-tricks.com/snippets/css/orientation-lock/ |
I think one of your tags in inaccurate. The Orientation success criterion in WCAG 2.1 is 2.6.2, not 2.6.1. |
It seems to me that an automated rule for this SC will only be able to raise a "needs review" at best because of the "essential" exemption:
Just an observation. |
Implementation Options: Option 1:
Option 2: (this is possible via an extension)
|
I think option 2 would be best. |
Preliminary commits for these work are below: |
PR - #971 |
**Note: This PR was branched from previous PR - #971 to have a cleaner commit history (without all the trials to fix CI failures). All reviews/ comments from the above PR has been tacked.** New rule: - WCAG 2.1 rule - Rule Id: `css-orientation-lock` - Description: Ensures that the content is not locked to any specific display orientation, and functionality of the content is operable in all display orientations (portrait/ landscape). Closes Issue: - #851 ## Reviewer checks **Required fields, to be filled out by PR reviewer(s)** - [ ] Follows the commit message policy, appropriate for next version - [ ] Has documentation updated, a DU ticket, or requires no documentation change - [ ] Includes new tests, or was unnecessary - [ ] Code is reviewed for security by: << Name here >>
#1081 merged. Closing issue. |
css-orientation-is-not-locked
The rule should test that the content is not locked to any specific display orientation, and functionality of the content is operable in all display orientations (portrait/ landscape).
Tags: wcag21, wcag262
Matcher
Element(s) to be tested is deciphered at run-time based on the tag(s) for which the orientation style is applied.
Checks
Needs review
Check media-queries targeting orientation, and look for transform styles applied to any elements, which aims to lock orientation.
An example snippet is as below:
Note: This should also cover portrait mode.
Proposal
Refer - #906
The text was updated successfully, but these errors were encountered: