Directory

Improve docs for block variation `isActive` property by talldan · Pull Request #60801 · WordPress/gutenberg · GitHub
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

Improve docs for block variation isActive property #60801

Merged
merged 3 commits into from
Apr 17, 2024

Conversation

talldan
Copy link
Contributor

@talldan talldan commented Apr 17, 2024

What?

While answering #60797, I noticed the docs for isActive aren't that clear, and I think it's easy for implementors to be confused about how to use it. I spent a few minutes working on the docs.

How?

Note that I only made changes to the isActive section, the rest of the changes are from auto-formatting made by my IDE or post commit hook.

  • I've removed some references to BlockCard and Breadcrumbs, as non-contributors may not know what they are
  • I found it confusing the way the providerNameSlug is mentioned in the same paragraph as some of the API details, you can see in the issue I mentioned above this was misinterpreted. I've broken it into a separate paragraph and made clear it's an example of API usage.
  • More clearly broken the function version of the property and array of string version of the property into separate paragraphs
  • Cleared up the code example by not mentioning 'YouTube' so concretely, as I think it's confusing that the code example doesn't mention 'YouTube' anywhere.

@talldan talldan added [Type] Developer Documentation Documentation for developers [Feature] Block Variations Block variations, including introducing new variations and variations as a feature labels Apr 17, 2024
@talldan talldan self-assigned this Apr 17, 2024
Copy link

github-actions bot commented Apr 17, 2024

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: talldan <talldanwp@git.wordpress.org>
Co-authored-by: fabiankaegy <fabiankaegy@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

Copy link
Member

@fabiankaegy fabiankaegy left a comment

Choose a reason for hiding this comment

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

These are nice updates :)

@fabiankaegy fabiankaegy merged commit 671b9ed into trunk Apr 17, 2024
61 checks passed
@fabiankaegy fabiankaegy deleted the update/block-variation-is-active-docs branch April 17, 2024 06:01
@github-actions github-actions bot added this to the Gutenberg 18.2 milestone Apr 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Block Variations Block variations, including introducing new variations and variations as a feature [Type] Developer Documentation Documentation for developers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants