-
Notifications
You must be signed in to change notification settings - Fork 91
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 more Caniuse keys #2476
base: main
Are you sure you want to change the base?
Add more Caniuse keys #2476
Conversation
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.
Thanks for adding these!
I have two comments, which are more questions/thoughts than things to fix. That's why I'm not setting the "request changes" state here. Let me know what you think about those two.
features/safe-area-inset.yml
Outdated
@@ -2,6 +2,8 @@ name: Safe area inset environment variables | |||
description: The `safe-area-inset-` CSS environment variables represent a rectangle that cannot cut off content within a non-rectangular screen. For example, `top:\ env(safe-area-inset-top);` positions the top of an element below the notch on an iPhone. | |||
spec: https://drafts.csswg.org/css-env-1/#safe-area-insets | |||
group: environment-variables | |||
# Caniuse is for env(), but this currently is the only supported value. |
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.
There's also titlebar-area-x/y/width/height, so safe-area-inset isn't the only variable that's supported in env(). I believe there may also be some virtual keyboard variables too.
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.
Good point. I misremembered the support on title-bar-area-*. I still think this is a valid mapping since it was the first one (and I updated the comment).
@@ -2,6 +2,7 @@ name: Named colors | |||
description: Some CSS color values can be referenced by name, such as `red` or `limegreen`. They stand in for specific RGB color values. | |||
spec: https://drafts.csswg.org/css-color-4/#named-colors | |||
group: color-types | |||
caniuse: css-rebeccapurple |
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.
Is there also a caniuse entry for named colors? If not, is it ok to only have a caniuse entry that corresponds to a sub-part of our feature, or is there a risk that this would be confusing?
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.
There is not a caniuse entry for named colors. It's a valid question, though. For the main use case of caniuse adding a Baseline banner to rebeccapurple
, it would not be confusing. But are there other potential uses of a caniuse key that this would break?
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.
Our docs say Setting a
caniuse value says that a feature is approximately equivalent to or a superset of a Can I Use feature.
Since named-colors contains rebeccapurple on web-features, this is okay. I'll open a separate PR with another set of similar situations I identified, but in many cases, it looks like the subfeature that caniuse has as a standalone feature has a distinct support story.
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.
Going back through my list, most of the superset features have significant discrepancies, so I ended up just adding caniuse for display
, events
, and font-kerning
on this branch. Apologies for adding after the approval!
I confirmed that versions match