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 brightness-mode-explainer.md. #334

Merged
merged 25 commits into from
Jan 26, 2022

Conversation

rakuco
Copy link
Member

@rakuco rakuco commented Dec 17, 2021

Related to #129 and w3c/devicesensors-wg#51 for more context. The contents
come from
https://docs.google.com/document/d/1skbEBafMjKnYVC7UoJfRgnnhAkp-jx0k_Z4j6eZeOwc/edit?usp=sharing
which was used while hashing out the basics and the structure.

Now that the contents have matured a bit, it is time to move this to an
explainer and continue iterating here.

Related to w3c#129 and w3c/devicesensors-wg#51 for more context. The contents
come from
https://docs.google.com/document/d/1skbEBafMjKnYVC7UoJfRgnnhAkp-jx0k_Z4j6eZeOwc/edit?usp=sharing
which was used while hashing out the basics and the structure.

Now that the contents have matured a bit, it is time to move this to an
explainer and continue iterating here.
@rakuco
Copy link
Member Author

rakuco commented Dec 17, 2021

+@willmorgan who doesn't seem to be part of the WG so I couldn't formally add as a reviewer.

Compared to a regular explainer, this one has a slightly different structure: we don't have the API fully hashed out, and the "considered alternatives" section was renamed to "proposed solutions", which serves a somewhat different purpose and indicates that we are still open to the ideas presented there.

Copy link
Member

@anssiko anssiko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I like there are multiple proposed solutions. It really shows this seemingly simple API has received careful scrutiny from various perspectives.

This is how most specs are made, it is just that usually the sausage making process is not this carefully documented :)

Copy link
Member

@marcoscaceres marcoscaceres left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The "API" is just another proposed solution.

@marcoscaceres
Copy link
Member

(despite my objection, I'm still really thankful that this is coming along ... great work @rakuco and team)

@anssiko
Copy link
Member

anssiko commented Dec 21, 2021

Thanks @marcoscaceres, I think it is reasonable to put all the ideas under the proposed solutions, including the API draft.

@rakuco was simply implementing the group's resolution https://www.w3.org/2021/11/17-dap-minutes.html#r01 that did not perhaps have the best wording ever. That error is on me, my apologies for that.

Copy link
Contributor

@willmorgan willmorgan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for amalgamating the various voices here @rakuco.

Copy link
Contributor

@beaufortfrancois beaufortfrancois left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with nits

brightness-mode-explainer.md Show resolved Hide resolved
brightness-mode-explainer.md Outdated Show resolved Hide resolved

- Things to consider in the spec proposal
- UAs should be free to limit maximum brightness level and/or do other things like increase contrast.
- Idea is to focus on mobile first (i.e. not worry about external displays). How to indicate that in the spec? Does it *need* to be indicated in the spec?
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might make sense to file a TAG early review request, highlighting that you would like feedback on these points.

- Should this trigger "`prefers-contrast: more`" in [CSS Media Queries](https://drafts.csswg.org/mediaqueries-5/#prefers-contrast)?
- From [https://github.com/w3c/devicesensors-wg/issues/51](https://github.com/w3c/devicesensors-wg/issues/51)
- Brightness levels
- How bright is too bright? Consider 100% brightness with HDR displays, for example.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess you could talk about specific nit values

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you mean by "nit values"?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is a unit for light intensity: https://en.wikipedia.org/wiki/Candela_per_square_metre - it is very common to use it for displays.

Good article: https://www.maketecheasier.com/what-is-nit-of-screen-brightness/

"Technically, a device starts counting as “sunlight-readable” when it hits at least 1,000 nits, but very few mobile displays go that high. As a general rule, anything above 400 to 500 nits will do pretty well on a sunny day, but at 200 nits, you may have to find some shade to answer texts."

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see. I'm used to "nit' being short for "nitpick", which makes some of those sentences very funny to read :-)

Do you know if nits are exposed by any platform?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know sorry. But on Android you at least seem to be able to get the max range: https://stackoverflow.com/questions/4544967/get-preferred-screen-brightness-in-android/8114307#8114307

@rakuco
Copy link
Member Author

rakuco commented Jan 26, 2022

Thanks for the edits, @tomayac! It's finally time to merge this PR \o/

@rakuco rakuco merged commit 81485f3 into w3c:gh-pages Jan 26, 2022
@rakuco rakuco deleted the add-brightness-mode-explainer branch January 26, 2022 14:51
@beaufortfrancois
Copy link
Contributor

About additional reviews, once merged it would be good to share the document in Apple’s and Mozilla’s standards position repos to see if it might be of interest to them. They are generally good at identifying things we may have overlooked or possibly provide novel solutions that leverage existing standards.

@rakuco Do you want to share https://github.com/w3c/screen-wake-lock/blob/gh-pages/brightness-mode-explainer.md with Apple and Mozilla?

@rakuco
Copy link
Member Author

rakuco commented Feb 7, 2022

@rakuco Do you want to share https://github.com/w3c/screen-wake-lock/blob/gh-pages/brightness-mode-explainer.md with Apple and Mozilla?

My plate's a bit full at the moment, so I'd appreciate it if someone like @marcoscaceres could take this up after having provided so much valuable feedback :-)

@beaufortfrancois
Copy link
Contributor

@marcoscaceres (gentle ping)

@beaufortfrancois
Copy link
Contributor

beaufortfrancois commented Mar 21, 2022

If @marcoscaceres is okay with that, I can start sending an email to webkit-dev@ and request a position at https://github.com/mozilla/standards-positions/

@rakuco
Copy link
Member Author

rakuco commented Mar 21, 2022

I'd say go for it :-)

@beaufortfrancois
Copy link
Contributor

Here it is:

Feel free to star/subscribe to those threads to follow along.

@rakuco
Copy link
Member Author

rakuco commented Mar 22, 2022

Awesome, thanks!

@beaufortfrancois
Copy link
Contributor

FYI Mozilla folks have started giving feedback on this document at mozilla/standards-positions#623
Feel free to join the conversation

@anssiko
Copy link
Member

anssiko commented Apr 21, 2022

I opened #335 for API design discussion based on Mozilla's feedback.

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.

8 participants