Skip to content
Merged
14 changes: 12 additions & 2 deletions bin/api-docs/gen-block-lib-list.js
Original file line number Diff line number Diff line change
Expand Up @@ -155,14 +155,20 @@ function readBlockJSON( filename ) {
? processObjWithInnerKeys( augmentSupports( blockjson.supports ) )
: [];
const attributes = getTruthyKeys( blockjson.attributes );
const parent = blockjson.parent
? '\n' + `- **Parent:** ${ blockjson.parent }`
: '';
const experimental = blockjson.__experimental
? '\n' + `- **Experimental:** ${ blockjson.__experimental }`
: '';

return `
## ${ blockjson.title }

${ blockjson.description } ([Source](${ sourcefile }))

- **Name:** ${ blockjson.name }
- **Category:** ${ blockjson.category }
- **Name:** ${ blockjson.name }${ experimental }
- **Category:** ${ blockjson.category }${ parent }
- **Supports:** ${ supportsList.sort().join( ', ' ) }
- **Attributes:** ${ attributes.sort().join( ', ' ) }
`;
Expand All @@ -176,6 +182,10 @@ const files = glob.sync(

let autogen = '';

autogen += `Last updated: ${
new Date().toISOString().split( 'T' )[ 0 ]
}. \n\n`;

files.forEach( ( file ) => {
const markup = readBlockJSON( file );
autogen += markup;
Expand Down
37 changes: 33 additions & 4 deletions docs/reference-guides/core-blocks.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
# Core Blocks Reference

This page lists the core blocks included in the block-library package.
This page lists the blocks included in the block-library package.

- Items marked with a strikeout (~~strikeout~~) are explicitly disabled.
- Blocks marked with **Experimental:** true are only available when Gutenberg is active.
- Blocks marked with **Experimental:** fse are only available in the Site Editor.

<div class="callout callout-info">
Items marked with a strikeout (~~strikeout~~) are explicitly disabled.
</div>

<!-- START TOKEN Autogenerated - DO NOT EDIT -->
Last updated: 2023-03-02.


## Archives

Expand Down Expand Up @@ -50,6 +53,7 @@ Prompt visitors to take action with a button-style link. ([Source](https://githu

- **Name:** core/button
- **Category:** design
- **Parent:** core/buttons
- **Supports:** anchor, color (background, gradients, text), shadow, spacing (padding), typography (fontSize, lineHeight), ~~alignWide~~, ~~align~~, ~~reusable~~
- **Attributes:** backgroundColor, gradient, linkTarget, placeholder, rel, text, textAlign, textColor, title, url, width

Expand Down Expand Up @@ -95,6 +99,7 @@ A single column within a columns block. ([Source](https://github.com/WordPress/g

- **Name:** core/column
- **Category:** text
- **Parent:** core/columns
- **Supports:** anchor, color (background, gradients, link, text), spacing (blockGap, padding), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:** allowedBlocks, templateLock, verticalAlignment, width

Expand All @@ -112,6 +117,7 @@ Display content in multiple columns, with blocks added to each column. ([Source]
This block is deprecated. Please use the Avatar block instead. ([Source](https://github.com/WordPress/gutenberg/tree/trunk/packages/block-library/src/comment-author-avatar))

- **Name:** core/comment-author-avatar
- **Experimental:** fse
- **Category:** theme
- **Supports:** anchor, color (background, ~~text~~), spacing (margin, padding), ~~html~~, ~~inserter~~
- **Attributes:** height, width
Expand Down Expand Up @@ -167,6 +173,7 @@ Contains the block elements used to display a comment, like the title, date, aut

- **Name:** core/comment-template
- **Category:** design
- **Parent:** core/comments
- **Supports:** align, anchor, spacing (margin, padding), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:**

Expand All @@ -185,6 +192,7 @@ Displays a paginated navigation to next/previous set of comments, when applicabl

- **Name:** core/comments-pagination
- **Category:** theme
- **Parent:** core/comments
- **Supports:** align, anchor, color (background, gradients, link, text), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:** paginationArrow

Expand All @@ -194,6 +202,7 @@ Displays the next comment's page link. ([Source](https://github.com/WordPress/gu

- **Name:** core/comments-pagination-next
- **Category:** theme
- **Parent:** core/comments-pagination
- **Supports:** anchor, color (background, gradients, ~~text~~), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:** label

Expand All @@ -203,6 +212,7 @@ Displays a list of page numbers for comments pagination. ([Source](https://githu

- **Name:** core/comments-pagination-numbers
- **Category:** theme
- **Parent:** core/comments-pagination
- **Supports:** anchor, color (background, gradients, ~~text~~), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:**

Expand All @@ -212,6 +222,7 @@ Displays the previous comment's page link. ([Source](https://github.com/WordPres

- **Name:** core/comments-pagination-previous
- **Category:** theme
- **Parent:** core/comments-pagination
- **Supports:** anchor, color (background, gradients, ~~text~~), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:** label

Expand Down Expand Up @@ -320,6 +331,7 @@ Create a link that always points to the homepage of the site. Usually not necess

- **Name:** core/home-link
- **Category:** design
- **Parent:** core/navigation
- **Supports:** anchor, typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:** label

Expand Down Expand Up @@ -374,6 +386,7 @@ Create a list item. ([Source](https://github.com/WordPress/gutenberg/tree/trunk/

- **Name:** core/list-item
- **Category:** text
- **Parent:** core/list
- **Supports:** typography (fontSize, lineHeight), ~~className~~
- **Attributes:** content, placeholder

Expand Down Expand Up @@ -428,6 +441,7 @@ Add a page, link, or another item to your navigation. ([Source](https://github.c

- **Name:** core/navigation-link
- **Category:** design
- **Parent:** core/navigation
- **Supports:** typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:** description, id, isTopLevelLink, kind, label, opensInNewTab, rel, title, type, url

Expand All @@ -437,6 +451,7 @@ Add a submenu to your navigation. ([Source](https://github.com/WordPress/gutenbe

- **Name:** core/navigation-submenu
- **Category:** design
- **Parent:** core/navigation
- **Supports:** ~~html~~, ~~reusable~~
- **Attributes:** description, id, isTopLevelItem, kind, label, opensInNewTab, rel, title, type, url

Expand All @@ -446,6 +461,7 @@ Separate your content into a multi-page experience. ([Source](https://github.com

- **Name:** core/nextpage
- **Category:** design
- **Parent:** core/post-content
- **Supports:** ~~className~~, ~~customClassName~~, ~~html~~
- **Attributes:**

Expand All @@ -464,6 +480,7 @@ Displays a page inside a list of all pages. ([Source](https://github.com/WordPre

- **Name:** core/page-list-item
- **Category:** widgets
- **Parent:** core/page-list
- **Supports:** ~~html~~, ~~inserter~~, ~~lock~~, ~~reusable~~
- **Attributes:** hasChildren, id, label, link, title

Expand Down Expand Up @@ -517,6 +534,7 @@ The author name. ([Source](https://github.com/WordPress/gutenberg/tree/trunk/pac
This block is deprecated. Please use the Comments block instead. ([Source](https://github.com/WordPress/gutenberg/tree/trunk/packages/block-library/src/post-comment))

- **Name:** core/post-comment
- **Experimental:** fse
- **Category:** theme
- **Supports:** ~~html~~, ~~inserter~~
- **Attributes:** commentId
Expand All @@ -526,6 +544,7 @@ This block is deprecated. Please use the Comments block instead. ([Source](https
Display a post's comments count. ([Source](https://github.com/WordPress/gutenberg/tree/trunk/packages/block-library/src/post-comments-count))

- **Name:** core/post-comments-count
- **Experimental:** fse
- **Category:** theme
- **Supports:** anchor, color (background, gradients, text), spacing (margin, padding), typography (fontSize, lineHeight), ~~html~~
- **Attributes:** textAlign
Expand All @@ -544,6 +563,7 @@ Display a post's comments form. ([Source](https://github.com/WordPress/gutenberg
Displays the link to the current post comments. ([Source](https://github.com/WordPress/gutenberg/tree/trunk/packages/block-library/src/post-comments-link))

- **Name:** core/post-comments-link
- **Experimental:** fse
- **Category:** theme
- **Supports:** anchor, color (background, link, ~~text~~), spacing (margin, padding), typography (fontSize, lineHeight), ~~html~~
- **Attributes:** textAlign
Expand Down Expand Up @@ -599,6 +619,7 @@ Contains the block elements used to render a post, like the title, date, feature

- **Name:** core/post-template
- **Category:** theme
- **Parent:** core/query
- **Supports:** align (full, wide), anchor, color (background, gradients, link, text), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:**

Expand All @@ -616,6 +637,7 @@ Post terms. ([Source](https://github.com/WordPress/gutenberg/tree/trunk/packages
Show minutes required to finish reading the post. ([Source](https://github.com/WordPress/gutenberg/tree/trunk/packages/block-library/src/post-time-to-read))

- **Name:** core/post-time-to-read
- **Experimental:** true
- **Category:** theme
- **Supports:** color (background, gradients, text), spacing (margin, padding), typography (fontSize, lineHeight), ~~html~~
- **Attributes:** textAlign
Expand Down Expand Up @@ -662,6 +684,7 @@ Contains the block elements used to render content when no query results are fou

- **Name:** core/query-no-results
- **Category:** theme
- **Parent:** core/query
- **Supports:** align, anchor, color (background, gradients, link, text), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:**

Expand All @@ -671,6 +694,7 @@ Displays a paginated navigation to next/previous set of posts, when applicable.

- **Name:** core/query-pagination
- **Category:** theme
- **Parent:** core/query
- **Supports:** align, anchor, color (background, gradients, link, text), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:** paginationArrow

Expand All @@ -680,6 +704,7 @@ Displays the next posts page link. ([Source](https://github.com/WordPress/gutenb

- **Name:** core/query-pagination-next
- **Category:** theme
- **Parent:** core/query-pagination
- **Supports:** anchor, color (background, gradients, ~~text~~), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:** label

Expand All @@ -689,6 +714,7 @@ Displays a list of page numbers for pagination ([Source](https://github.com/Word

- **Name:** core/query-pagination-numbers
- **Category:** theme
- **Parent:** core/query-pagination
- **Supports:** anchor, color (background, gradients, ~~text~~), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:**

Expand All @@ -698,6 +724,7 @@ Displays the previous posts page link. ([Source](https://github.com/WordPress/gu

- **Name:** core/query-pagination-previous
- **Category:** theme
- **Parent:** core/query-pagination
- **Supports:** anchor, color (background, gradients, ~~text~~), typography (fontSize, lineHeight), ~~html~~, ~~reusable~~
- **Attributes:** label

Expand Down Expand Up @@ -797,6 +824,7 @@ Display an icon linking to a social media profile or site. ([Source](https://git

- **Name:** core/social-link
- **Category:** widgets
- **Parent:** core/social-links
- **Supports:** anchor, ~~html~~, ~~reusable~~
- **Attributes:** label, rel, service, url

Expand Down Expand Up @@ -832,6 +860,7 @@ Create structured content in rows and columns to display information. ([Source](
Summarize your post with a list of headings. Add HTML anchors to Heading blocks to link them here. ([Source](https://github.com/WordPress/gutenberg/tree/trunk/packages/block-library/src/table-of-contents))

- **Name:** core/table-of-contents
- **Experimental:** true
- **Category:** layout
- **Supports:** color (background, gradients, link, text), spacing (margin, padding), typography (fontSize, lineHeight), ~~html~~
- **Attributes:** headings, onlyIncludeCurrentPage
Expand Down