Skip to content
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

Add 'motion-preference' media feature #778

Closed
wants to merge 2 commits into from
Closed

Conversation

inoas
Copy link

@inoas inoas commented Nov 30, 2016

Implements Issue: #442
Alternative to #586

Having a good wording of the feature also gets around default value evaluating to true instead of false. Ref: #586 (comment)

Alternative to w3c#586
Having a good wording of the feature also gets around default value evaluating to true instead of false. Ref: w3c#586 (comment)
@nattarnoff
Copy link

This makes sense to me as solid way to implement in CSS. By default motion is on, and we can reduce action from there. I'm struggling to see how this gets implemented though in a real world example.
For instance, as a media query, I expect something like:

@medis (motion-preference: none {
  // Base CSS - no motion
}
@media (motion-preference: reduced) {
  // CSS for limited motion
}
 // Balance of CSS with full animation

Of course this is an ideal, and most folks will probably retrofit and use these in the opposite manner initially. Is there anyway this can be read and acted upon by WAAPI/JS animation implementations?

@cookiecrook
Copy link
Contributor

cookiecrook commented Dec 6, 2016

Why split the conversation into this alternative PR? Please just continue in either of the original threads: #442 or #586. PR #586 was raised because the CSSWG hadn't taken action in over two years, since this was proposed in 2014. We can come to an agreement in a single thread I believe.

@inoas
Copy link
Author

inoas commented Dec 6, 2016

The suggestion already is in #442 - precisely here: #442 (comment)

However it wasn't picked and as far as I can see there wasn't any argument against it (yet!).

Do you see any issues with this PR here?
Does it not solve anything?
Is it anywhere unclear?
@grorg Where would this not work for you?

@cookiecrook
Copy link
Contributor

@inoas wrote:

as far as I can see there wasn't any argument against it

Your last comment in that thread suggested all as a falsey value which doesn't seem right to me.

You also seemed to agree with the "prefers-" prefix over your suggested "-preference" suffix with the following comment:

the idea with the prefers- prefix seems to be a good one!

@cookiecrook
Copy link
Contributor

@inoas wrote:

Where would this not work for you?

I think the forced-all-animation-off idea (motion-preference: disable;) is unlikely to be implemented because it would break too many things, which is why I proposed the opt-in. I'd rather see that forced-all-animation-off idea incubated. If you get author and browser support, bring it back.

@cookiecrook
Copy link
Contributor

As for the motion-preference versus prefers-reduced-motion property name, let's keep discussing that in PR #586.

@cookiecrook
Copy link
Contributor

Also I think your proposal would not be backwards compatible:

@media (motion-preference: all) /* this would be the default, but works in no browsers today */

@cookiecrook
Copy link
Contributor

I suggest closing this one and duping it to #586

@inoas
Copy link
Author

inoas commented Dec 6, 2016

  • I think it is really bad to design keywords around what is currently possible. If you think it is not the right time to support 'disabled' then either the browser-vendor can decide so or the PR can be restricted to values default and reduced leaving the OPTION to later have disabled. However personally I'd love to be able to know if a user does not like any animations. It is still a preference setting. E.g. you can still offer animations, but maybe .1s long instead of .3s.
  • There is no all but only default, reduced and disable. Where would this not work in browsers?
  • I am perfectly fine discussing in Add 'prefers-reduced-motion' media feature #586 I was just setting up a PR so that it isn't just words.
  • I don't understand what you mean by duping it to Add 'prefers-reduced-motion' media feature #586.

inoas added a commit to inoas/csswg-drafts that referenced this pull request Dec 6, 2016
Ref: w3c#778
Implements Issue: w3c#442
Alternative to w3c#586
inoas added a commit to inoas/csswg-drafts that referenced this pull request Dec 6, 2016
Ref: w3c#778
Implements Issue: w3c#442
Alternative to w3c#586
@frivoal
Copy link
Collaborator

frivoal commented Dec 7, 2016

This discussion is kind of spreading over a bunch of places. I made a comment in #442 (comment) to try and summarize all that's been said in terms of naming options, and try to find a winner.

@inoas
Copy link
Author

inoas commented Dec 28, 2016

Closing as there has been made a decision.

@inoas inoas closed this Dec 28, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants