Skip to content

Conversation

@ellatrix
Copy link
Member

@ellatrix ellatrix commented Nov 25, 2025

What?

image

Adds some style options to the math block. @jasmussen is correct to point out that the math format inside paragraphs etc. does have styling options, being in a paragraph, but the block ("display" math) does not.

Why?

Unlike other text blocks, the styles options are currently missing.

How?

Just opt-in with block.json.

Testing Instructions

Create a math block and try the options in the inspector.

Testing Instructions for Keyboard

Screenshots or screencast

Before After

@github-actions
Copy link

github-actions bot commented Nov 25, 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: ellatrix <[email protected]>
Co-authored-by: jasmussen <[email protected]>

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

@ellatrix ellatrix added the [Type] Enhancement A suggestion for improvement. label Nov 25, 2025
@ellatrix ellatrix requested a review from jasmussen November 25, 2025 11:58
Copy link
Contributor

@jasmussen jasmussen left a comment

Choose a reason for hiding this comment

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

Outstanding, I love it:
state

Note, pretty sure you already removed the Link format from the color panel, as that's irrelevant here. So this GIF is based on an earlier pull of this branch.

Also confirming an important piece, this is the Typography panel:
Screenshot 2025-11-25 at 13 02 59

This is super solid. I want to change the font size, and that works perfectly. None of the other options—letter spacing, all caps—would work here, so it's good that those are simply not there, yet it's the same recognizable font panel.

@ellatrix
Copy link
Member Author

Yes, I copied all the supports settings from the paragraph block and tested everything, removed everything that doesn't work for math.

@ellatrix ellatrix merged commit 6524f50 into trunk Nov 25, 2025
35 checks passed
@ellatrix ellatrix deleted the add/math-styles-options branch November 25, 2025 14:53
@github-actions github-actions bot added this to the Gutenberg 22.2 milestone Nov 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Block] Math [Type] Enhancement A suggestion for improvement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants