-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Docs: Add block patterns list component readme #24983
Docs: Add block patterns list component readme #24983
Conversation
|
||
const MyBreadcrumb = () => ( | ||
<BlockPatternList | ||
onClickPattern={ onClick } |
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.
@ntsekouras I was wondering if it is necessary to add the onClickPattern={ onClick }
to this code sample.
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.
Also, I was wondering if there could be ways I can make these code samples more detailed. Til now, for the packages I documented, I basically added a const with a simple use case of the component.
I know these packages component are not intended to be uses by third parties, but was just wondering.
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.
This component requires three props
shownPatterns={ shownBlockPatterns }
blockPatterns={ shownBlockPatterns }
onClickPattern={ onSelectBlockPattern }
Ideally, we pass a valid prop and explain what these props are about. (Some READMEs have a props section for the explanations)
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.
Still having to find what the props do exactly. On my list for next week.
packages/block-editor/src/components/block-patterns-list/README.md
Outdated
Show resolved
Hide resolved
packages/block-editor/src/components/block-patterns-list/README.md
Outdated
Show resolved
Hide resolved
a5ffb06
to
8efb740
Compare
Something has been mixed up here. Can you rebase to include only your changes in the PR? |
…s-list-component-readme
packages/block-editor/src/components/block-patterns-list/README.md
Outdated
Show resolved
Hide resolved
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.
Thank you for the improvements to the block editor documentation :)
Description
Added documentation for the block patterns list component (see #22891)
How has this been tested?
N/A, documentation only
Types of changes
Documentation
Checklist: