Skip to content

Conversation

@oandregal
Copy link
Member

@oandregal oandregal commented Jul 1, 2021

Part of #20331

WordPress 5.8 comes with support for theme.json, so we need to update the docs accordingly: remove references to "experimental", highlight which parts only work on Gutenberg vs WordPress 5.8, etc.

See the document.

Note that there're a few call-outs that will be displayed differently in the block editor handbook. For reference, this is how the current call-out looks:

Captura de ecrã de 2021-07-01 12-10-37

@oandregal oandregal requested review from DaisyOlsen and mkaz July 1, 2021 10:09
@oandregal oandregal self-assigned this Jul 1, 2021
@oandregal oandregal added [Type] Developer Documentation Documentation for developers Global Styles Anything related to the broader Global Styles efforts, including Styles Engine and theme.json labels Jul 1, 2021
The settings section has the following structure:

{% codetabs %}
{% WordPress %}
Copy link
Member Author

Choose a reason for hiding this comment

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

I thought about naming this "WordPress 5.8" instead.

The reason I didn't was that I believe this text has to be a single string without spaces. When I introduced the "Input"/"Output" for sections like this one https://developer.wordpress.org/block-editor/how-to-guides/themes/theme-json/#css-custom-properties-presets-custom I have a vague memory of having used "theme.json"/"CSS styles" and that it was problematic. Will look it up to confirm.

Copy link
Member Author

@oandregal oandregal Jul 1, 2021

Choose a reason for hiding this comment

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

#28655 illustrates what happened when using spaces in the codetabs texts.


### Settings

<div class="callout callout-alert">
Copy link
Member Author

Choose a reason for hiding this comment

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

This would be styled as a callout.


### Styles

<div class="callout callout-alert">
Copy link
Member Author

Choose a reason for hiding this comment

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

This would be styled as a callout.


### customTemplates

<div class="callout callout-alert">
Copy link
Member Author

Choose a reason for hiding this comment

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

This would be styled as a callout.


### templateParts

<div class="callout callout-alert">
Copy link
Member Author

Choose a reason for hiding this comment

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

This would be styled as a callout.

@oandregal oandregal changed the title Update theme.json docs for 5 8 Update theme.json docs for WordPress 5.8 Jul 1, 2021
@oandregal oandregal requested review from JustinyAhin and annezazu July 1, 2021 10:21
Copy link
Member

@jorgefilipecosta jorgefilipecosta 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 for these updates. They look good to me 👍

"duotone": [],
"gradients": [],
"link": false,
"palette": []
Copy link
Member

Choose a reason for hiding this comment

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

It may be helpful to define a preset like a color so people know how to do it.

Copy link
Member Author

Choose a reason for hiding this comment

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

There's a section fully focused on presets.

@oandregal oandregal merged commit 3938f14 into trunk Jul 2, 2021
@oandregal oandregal deleted the update/theme-json-for-5-8 branch July 2, 2021 08:09
@github-actions github-actions bot added this to the Gutenberg 11.1 milestone Jul 2, 2021
@oandregal oandregal mentioned this pull request Jul 2, 2021
82 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Global Styles Anything related to the broader Global Styles efforts, including Styles Engine and theme.json [Type] Developer Documentation Documentation for developers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants