Skip to content
This repository has been archived by the owner on Jan 26, 2022. It is now read-only.

Try updated font sizes #298

Merged
merged 9 commits into from Dec 17, 2021
Merged

Try updated font sizes #298

merged 9 commits into from Dec 17, 2021

Conversation

kjellr
Copy link
Collaborator

@kjellr kjellr commented Dec 14, 2021

This PR changes our font sizes a bit, to align with the upcoming font-size changes in Core, and the work being done in WordPress/gutenberg#37038.

For Twenty Twenty-Two's purposes, we had to rename some of the size slugs: The "Normal" font size can't just be dropped outright since it's the base size used for the entire theme. So I changed that to Medium, and scaled things up from there. Here are the changes:

Old preset sizes:

  • Small
  • Normal
  • Medium
  • Large
  • Huge

New preset sizes:

  • Small
  • Medium
  • Large
  • Extra Large

Changes:

  • Small ➡️ (no change)
  • Normal ➡️ Medium
  • Medium ➡️ Large
  • Large ➡️ Extra Large
  • Huge ➡️ (custom variable, same name)

@kjellr kjellr self-assigned this Dec 14, 2021
@kjellr
Copy link
Collaborator Author

kjellr commented Dec 15, 2021

In bd39c49, I realized that we had to change the markup for all the items that used to be "Huge" too. Previously, they were using the is-font-size-huge class, which fell back to the Gutenberg default instead of our custom variable. 😕

I think I sorted that all out, but in any case, this could use a solid review if we move forward with it.

@kjellr kjellr marked this pull request as ready for review December 17, 2021 13:55
@kjellr
Copy link
Collaborator Author

kjellr commented Dec 17, 2021

Ok, while I was here I made some very subtle refinements to the type scale so that it works better responsively.

This is a pretty large PR, but it's mostly find & replace, and I feel pretty confident about it. I'd like to merge this in sooner rather than later so that more folks are able to test it.

@kjellr kjellr requested review from MaggieCabrera, scruffian and jffng and removed request for MaggieCabrera December 17, 2021 15:40
Copy link
Collaborator

@jffng jffng left a comment

Choose a reason for hiding this comment

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

To confirm, I should I be seeing just four preset sizes in the typography panel, instead of the previous five:

Screen Shot 2021-12-17 at 8 46 40 AM

Left a couple minor comments, once those are addressed I think we can bring this in.

inc/patterns/general-pricing-table.php Outdated Show resolved Hide resolved
inc/patterns/hidden-heading-and-bird.php Outdated Show resolved Hide resolved
@jffng
Copy link
Collaborator

jffng commented Dec 17, 2021

I did notice a bug on trunk which this PR fixes, but it could be an issue for other themes — the normal font size in the editor is being overridden by Gutenberg's default normal font size:

Screen Shot 2021-12-17 at 8 50 23 AM

@kjellr
Copy link
Collaborator Author

kjellr commented Dec 17, 2021

To confirm, I should I be seeing just four preset sizes in the typography panel, instead of the previous five

Thats right. 👍

I did notice a bug on trunk which this PR fixes, but it could be an issue for other themes — the normal font size in the editor is being overridden by Gutenberg's default normal font size:

I think it was doing that before, right? In any case, I'll leave a note in the corresponding Gutenberg PR to double check.

@kjellr kjellr merged commit 7257a11 into trunk Dec 17, 2021
@kjellr kjellr deleted the try-updated-font-sizes branch December 17, 2021 17:00
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants