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

Use a plural array type like "permissions" for simplicity #614

Merged
merged 2 commits into from
May 23, 2024

Conversation

solomonkinard
Copy link
Contributor

No description provided.

Copy link
Member

@dotproto dotproto left a comment

Choose a reason for hiding this comment

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

LGTM

@xeenon xeenon requested review from xeenon and Rob--W May 20, 2024 17:59
@mukul-p mukul-p merged commit 1aa7f75 into w3c:main May 23, 2024
3 checks passed
github-actions bot added a commit that referenced this pull request May 23, 2024
SHA: 1aa7f75
Reason: push, by mukul-p

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
github-actions bot added a commit that referenced this pull request May 23, 2024
SHA: 1aa7f75
Reason: push, by mukul-p

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@carlosjeurissen
Copy link
Contributor

There is one "color-schemes" instead of "color_schemes" in the commit.

Basically with this PR the ability to set the color scheme to a single string value is dropped?

@solomonkinard
Copy link
Contributor Author

This PR was created a week before the previous Tuesday more as a question than a directive. I like the idea of color_scheme accepting string or string[]. However, I was thinking about "permissions" as a string[] when I wrote this PR. This is not necessarily set in stone here, so it could have been discussed in this thread or in the meeting today before merge. Even still, it's not too late to make a case for something other than color_schemes as a string[]. Some ideas:

  1. Revert this change to return to color_scheme: string | string[]
  2. Keep this change which supports color_schemes: string[].
  3. Support color_schemes: string | string[].
  4. Support {color_scheme: string, color_schemes: string[]}.

Maybe you have other ideas beyond those. Perhaps you could share your ideas here or better yet create a PR with your preference and rationale.

@carlosjeurissen
Copy link
Contributor

Thinking out loud the most common use case seems to be either set color_scheme to "light" or "dark", or omit it to indicate it is for all color schemes.

Requiring an array would mean the syntax is more verbose with the benefit of having a single syntax for any situation and indicate other color_schemes can be added here.

In any case, I feel we either go with this PR, always use color_schemes which requires an array (string[]). OR keep as was before (color_scheme as string | string[]).

Would love to hear about other contributors who helped decide on this before @hanguokai @xeenon

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.

6 participants