Skip to content

Conversation

@aduth
Copy link
Member

@aduth aduth commented Dec 12, 2025

What?

Updates @wordpress/theme's README.md to describe the behavior of the density prop.

Why?

  • For consistency with how we're documenting color
  • To clarify usage of the ThemeProvider component and its available features
  • To acknowledge and capture the intended purpose of the available density options

Testing Instructions

Review proposed documentation for accuracy.

@aduth aduth requested a review from jameskoster December 12, 2025 16:29
@aduth aduth requested a review from a team as a code owner December 12, 2025 16:29
@github-actions
Copy link

github-actions bot commented Dec 12, 2025

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: aduth <aduth@git.wordpress.org>
Co-authored-by: juanfra <juanfra@git.wordpress.org>

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

@aduth aduth added [Type] Developer Documentation Documentation for developers [Package] Theme /packages/theme labels Dec 12, 2025
In earlier iterations, this sentence was specifically talking about density, but was later generalized since all of the values inherit from the closest ThemeProvider.
@github-actions
Copy link

Flaky tests detected in 3f3d40a.
Some tests passed with failed attempts. The failures may not be related to this commit but are still reported for visibility. See the documentation for more information.

🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/20173375481
📝 Reported issues:

Copy link
Member

@juanfra juanfra left a comment

Choose a reason for hiding this comment

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

LGTM ✅

Comment on lines 157 to 159
- `'default'`: Standard spacing for general use
- `'compact'`: Reduced spacing for information-dense interfaces like data tables or dashboards
- `'comfortable'`: Increased spacing for focused experiences like modals, dialogs, or full-screen settings panels
Copy link
Member

Choose a reason for hiding this comment

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

Nit: we might want to end these list items with a full stop, to stay consistent with the style used elsewhere.

Suggested change
- `'default'`: Standard spacing for general use
- `'compact'`: Reduced spacing for information-dense interfaces like data tables or dashboards
- `'comfortable'`: Increased spacing for focused experiences like modals, dialogs, or full-screen settings panels
- `'default'`: Standard spacing for general use.
- `'compact'`: Reduced spacing for information-dense interfaces like data tables or dashboards.
- `'comfortable'`: Increased spacing for focused experiences like modals, dialogs, or full-screen settings panels.

Copy link
Member Author

Choose a reason for hiding this comment

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

Could you clarify what you mean by "elsewhere" ? We're not especially consistent in this file 😅 The original proposed content follows from the color prop listing above, though there's also lists elsewhere in the file (e.g. "Building") that include periods.

I guess it's a broader question of whether we have content guidelines for this and whether they're discoverable enough.

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 some guidance in the documentation copy guide for bulleted lists, though it's more about consistency and less about prescribing dots or not dots.

In any case, I pushed changes in b3bb942 to make it consistent across the files: Dots at the end of list items, and no dots within tables.

Copy link
Member

@juanfra juanfra Dec 15, 2025

Choose a reason for hiding this comment

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

Fair point 😅

Before leaving the nit I just checked a couple of other readme's as a reference, like dataviews, which felt fairly up to date and uses full stops in lists.

No strong feelings either way though. But indeed, maybe it’s a sign we could use a lightweight guideline at some point (updated after you shared the copy guide)

Copy link
Member

Choose a reason for hiding this comment

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

I also have a preference for full stops at the end of bullet points 🙂

@aduth aduth merged commit a01f66e into trunk Dec 15, 2025
33 of 34 checks passed
@aduth aduth deleted the add/theme-density-docs branch December 15, 2025 15:59
@github-actions github-actions bot added this to the Gutenberg 22.4 milestone Dec 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Package] Theme /packages/theme [Type] Developer Documentation Documentation for developers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants