Skip to content

Commit

Permalink
Theme.json: Add custom properties for Inter Heading font sizes (#164)
Browse files Browse the repository at this point in the history
* Theme.json: Add custom properties for Inter Heading font sizes

* Use new small sizes
  • Loading branch information
ryelle authored Dec 5, 2024
1 parent 69b84e2 commit 412f17d
Show file tree
Hide file tree
Showing 2 changed files with 56 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,10 @@ body[class] {
--wp--preset--font-size--heading-4: var(--wp--custom--heading--level-4--breakpoint--small-only--typography--font-size);
--wp--preset--font-size--heading-5: var(--wp--custom--heading--level-5--breakpoint--small-only--typography--font-size);
--wp--preset--font-size--heading-6: var(--wp--custom--heading--level-6--breakpoint--small-only--typography--font-size);
--wp--custom--heading--level-3--inter--typography--font-size: var(--wp--custom--heading--level-3--inter--breakpoint--small-only--typography--font-size);
--wp--custom--heading--level-4--inter--typography--font-size: var(--wp--custom--heading--level-4--inter--breakpoint--small-only--typography--font-size);
--wp--custom--heading--level-5--inter--typography--font-size: var(--wp--custom--heading--level-5--inter--breakpoint--small-only--typography--font-size);
--wp--custom--heading--level-6--inter--typography--font-size: var(--wp--custom--heading--level-6--inter--breakpoint--small-only--typography--font-size);
--wp--preset--font-size--extra-large: var(--wp--custom--body--extra-large--breakpoint--small-only--typography--font-size);

--wp--custom--heading--cta--typography--line-height: var(--wp--custom--heading--cta--breakpoint--small-only--typography--line-height);
Expand Down
52 changes: 52 additions & 0 deletions source/wp-content/themes/wporg-parent-2021/theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -395,6 +395,19 @@
"lineHeight": 1.15
}
}
},
"inter": {
"typography": {
"fontSize": "29px",
"lineHeight": 1.4
},
"breakpoint": {
"small-only": {
"typography": {
"fontSize": "21px"
}
}
}
}
},
"level-4": {
Expand All @@ -408,6 +421,19 @@
"lineHeight": 1.09
}
}
},
"inter": {
"typography": {
"fontSize": "24px",
"lineHeight": 1.4
},
"breakpoint": {
"small-only": {
"typography": {
"fontSize": "19px"
}
}
}
}
},
"level-5": {
Expand All @@ -421,6 +447,19 @@
"lineHeight": 1.2
}
}
},
"inter": {
"typography": {
"fontSize": "20px",
"lineHeight": 1.4
},
"breakpoint": {
"small-only": {
"typography": {
"fontSize": "17px"
}
}
}
}
},
"level-6": {
Expand All @@ -434,6 +473,19 @@
"lineHeight": 1.22
}
}
},
"inter": {
"typography": {
"fontSize": "18px",
"lineHeight": 1.4
},
"breakpoint": {
"small-only": {
"typography": {
"fontSize": "16px"
}
}
}
}
}
},
Expand Down

0 comments on commit 412f17d

Please sign in to comment.