Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Add brightness-mode-explainer.md. #334
Changes from 21 commits
44a4285
746a70b
6b44cac
67e3898
76dce08
413a603
8bd1bdc
95a2a04
6db1026
fc98916
2cb91a8
ca0eab5
fd2a152
ab5d893
6f1577a
7aad217
fb25303
b85c6f5
5be36bb
3505713
b271b84
b5e2603
5d7eafa
87c16ad
ef91054
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
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
There was a problem hiding this comment.
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"?
There was a problem hiding this comment.
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/
There was a problem hiding this comment.
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?
There was a problem hiding this comment.
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
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we implemented one of the proposals above featuring a
requestIncreasedBrighness()
method then I would polyfill this proposal roughly as,Polyfilled in this way all the same abuse mitigations would apply with the advantage that the browser has some insight into how the page content relates to the developer's desire for increased brightness and can do things like offer to increase brightness when the element is visible (instead of automatically doing so) or increase brightness gradually as the element enters the viewport.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't that bypass the user gesture requirement and allow one to add the max-brightness style to
<body>
?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not necessarily. The browser could still require the user interact with the page in some way before the property took effect or else it would display its own UI prompting the user with something like "tap here to make this page easier to scan".