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 JSDoc to PostVisibility, PostVisibilityCheck, and PostVisibilityLabel #61735

Merged
merged 3 commits into from
May 18, 2024

Conversation

dbrian
Copy link
Contributor

@dbrian dbrian commented May 16, 2024

What?

Part of: #60358

This PR adds JSDoc comments to the PostVisibility, PostVisibilityCheck, and PostVisibilityLabel to improve code documentation and maintainability.

Copy link

github-actions bot commented May 16, 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: dbrian <bgosnell@git.wordpress.org>
Co-authored-by: colorful-tones <colorful-tones@git.wordpress.org>
Co-authored-by: ntsekouras <ntsekouras@git.wordpress.org>

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

@github-actions github-actions bot added the First-time Contributor Pull request opened by a first-time contributor to Gutenberg repository label May 16, 2024
Copy link

👋 Thanks for your first Pull Request and for helping build the future of Gutenberg and WordPress, @dbrian! In case you missed it, we'd love to have you join us in our Slack community.

If you want to learn more about WordPress development in general, check out the Core Handbook full of helpful information.

@colorful-tones colorful-tones self-assigned this May 16, 2024
Co-authored-by: dbrian <bgosnell@git.wordpress.org>
Copy link
Contributor

@ntsekouras ntsekouras left a comment

Choose a reason for hiding this comment

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

I left a couple of small comments, but this looks good. Thanks!

* @param {string} props.label - The label for the visibility option.
* @param {string} props.info - Additional information about the visibility option.
* @return {JSX.Element} The rendered component.
*/
Copy link
Contributor

Choose a reason for hiding this comment

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

This is not exported so we could leave it as is, though it doesn't hurt to have it 😄 .

@@ -17,6 +17,15 @@ import { __experimentalInspectorPopoverHeader as InspectorPopoverHeader } from '
import { visibilityOptions } from './utils';
import { store as editorStore } from '../../store';

/**
* PostVisibility component.
Copy link
Contributor

Choose a reason for hiding this comment

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

We need to remove this PostVisibility component. from every component because the generated docs include the component's name, so it's kind of duplicate..

Copy link
Contributor

@ntsekouras ntsekouras left a comment

Choose a reason for hiding this comment

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

Thank you!

@ntsekouras ntsekouras enabled auto-merge (squash) May 18, 2024 05:10
@ntsekouras ntsekouras merged commit 6398d34 into WordPress:trunk May 18, 2024
62 checks passed
@github-actions github-actions bot added this to the Gutenberg 18.5 milestone May 18, 2024
patil-vipul pushed a commit to patil-vipul/gutenberg that referenced this pull request Jun 17, 2024
…abel (WordPress#61735)

Co-authored-by: dbrian <bgosnell@git.wordpress.org>
Co-authored-by: colorful-tones <colorful-tones@git.wordpress.org>
Co-authored-by: ntsekouras <ntsekouras@git.wordpress.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
First-time Contributor Pull request opened by a first-time contributor to Gutenberg repository [Type] Developer Documentation Documentation for developers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants