[Paragraph Block] add font family support#37586
Conversation
There was a desire to delay surfacing this block support until we have a better way to manage custom fonts. A summary from a chat with @mtias can be found in #34064 (comment) My understanding was we'd only keep font-family as an option for the blocks that already had opted into that support and ensure it wasn't displayed as a default control within the typography panel. |
Should we revert this then? I wish we could have this in the block markup even if the UI doesn't show it to the user |
|
I think we should revert this based on previous conversations linked. Let's please get more reviews and ping folks working in this area before merging, we are happy to help. |
This reverts commit 2336519.
|
Based on the committed file, a temporarily hack: or, to show up as default controls: will do the trick for now until official solution. |
|
@alan-la-chen-478 Thank Edit: I found a solution. I did it in JavaScript and it works |
Description
Closes #36234
This PR adds font family support to the paragraph block. I don't know if there's a reason why this wasn't added before, but I agree with the reasons over at #36234. I've encountered a few cases where the paragraph block was the best option in terms of markup but wanted the text to look like a heading block instead.
How has this been tested?
Tested this using Seedlet Blocks.
To test use a theme that provides multiple fonts, check that you can change the font family to the paragraph block, it should look like the screenshot.
Screenshots
Types of changes
New feature (non-breaking change which adds functionality)
Checklist:
*.native.jsfiles for terms that need renaming or removal).