Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Poetry variations and header font fixing (#199) #210

Open
wants to merge 1 commit into
base: trunk
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added poetry/assets/fonts/Alice-Regular.ttf
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added poetry/assets/fonts/Trocchi-Regular.ttf
Binary file not shown.
Binary file added poetry/assets/fonts/Unna-Bold.ttf
Binary file not shown.
Binary file added poetry/assets/fonts/Unna-BoldItalic.ttf
Binary file not shown.
Binary file added poetry/assets/fonts/Unna-Italic.ttf
Binary file not shown.
Binary file added poetry/assets/fonts/Unna-Regular.ttf
Binary file not shown.
4 changes: 2 additions & 2 deletions poetry/patterns/header.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
<div class="wp-block-group"><!-- wp:site-title {"level":0,"isLink":true,"style":{"typography":{"fontStyle":"normal","fontWeight":"600"}},"fontSize":"medium"} /-->

<!-- wp:group {"style":{"spacing":{"blockGap":"48px"}},"layout":{"type":"flex","orientation":"vertical"}} -->
<div class="wp-block-group"><!-- wp:paragraph {"style":{"typography":{"lineHeight":"0.8"}},"fontSize":"xx-large","fontFamily":"rozha-one"} -->
<p class="has-rozha-one-font-family has-xx-large-font-size" style="line-height:0.8">Food <br>for thoughts</p>
<div class="wp-block-group"><!-- wp:paragraph {"style":{"typography":{"lineHeight":"0.8"}},"fontSize":"xx-large","fontFamily":"heading"} -->
<h2 class="has-heading-font-family has-xx-large-font-size" style="line-height:0.8">Food <br>for thoughts</h2>
Copy link
Collaborator

Choose a reason for hiding this comment

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

we made this change but then we don't assign a "heading" font family in the .json files. The class has-heading-font-family is not resolving to anything so this change is not really doing anything. We could remove the class altogether and just let the theme default to whatever the theme.json sets for all headings. That is probably the best case for this particular theme, but that means that no templates/patterns can select specific font families and expect the theme to be able to adapt when we change to a different variation that doesn't have that specific font family.

<!-- /wp:paragraph -->

<!-- wp:paragraph {"style":{"typography":{"lineHeight":"1.5"}},"fontSize":"medium"} -->
Expand Down
175 changes: 175 additions & 0 deletions poetry/styles/my-typo.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,175 @@
{
"settings": {
"color": {
"palette": [
{
"color": "#ffffff",
"name": "Background",
"slug": "custom-background"
},
{
"color": "#000000",
"name": "Text",
"slug": "custom-text"
},
{
"color": "#faf6f4",
"name": "Background Light",
"slug": "custom-background-light"
},
{
"color": "#676e74",
"name": "Contrast",
"slug": "custom-contrast"
}
],
"duotone": [
{
"colors": [ "#676e74", "#fff" ],
"slug": "grey-and-light",
"name": "Grey and light pink"
}
]
},
"typography": {
"fontFamilies": [
{
"fontFamily": "-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif",
"name": "System Font",
"slug": "system-font"
},
{
"fontFace": [
{
"fontFamily": "Rozha One",
"fontStyle": "normal",
"fontWeight": "400",
"src": [
"file:./assets/fonts/rozha-one_normal_400.ttf"
]
}
],
"fontFamily": "Rozha One",
"name": "Rozha One",
"slug": "rozha-one"
},
{
"fontFace": [
{
"fontFamily": "Inter",
"fontStyle": "normal",
"fontWeight": "300",
"src": [
"file:./assets/fonts/inter_normal_300.ttf"
]
},
{
"fontFamily": "Inter",
"fontStyle": "normal",
"fontWeight": "600",
"src": [
"file:./assets/fonts/inter_normal_600.ttf"
]
},
{
"fontFamily": "Inter",
"fontStyle": "normal",
"fontWeight": "700",
"src": [
"file:./assets/fonts/inter_normal_700.ttf"
]
}
],
"fontFamily": "Inter",
"name": "Inter",
"slug": "inter"
},
{
"fontFace": [
{
"fontFamily": "Trocchi",
"fontStyle": "normal",
"fontWeight": "400",
"src": "file:./assets/fonts/Trocchi-Regular.ttf"
}
],
"fontFamily": "Trocchi, serif",
"name": "Trocchi",
"slug": "trocchi"
},
{
"fontFace": [
{
"fontFamily": "Unna",
"fontStyle": "normal",
"fontWeight": "400",
"src": "file:./assets/fonts/Unna-Regular.ttf"
},
{
"fontFamily": "Unna",
"fontStyle": "normal",
"fontWeight": "700",
"src": "file:./assets/fonts/Unna-Bold.ttf"
},
{
"fontFamily": "Unna",
"fontStyle": "italic",
"fontWeight": "400",
"src": "file:./assets/fonts/Unna-Italic.ttf"
},
{
"fontFamily": "Unna",
"fontStyle": "italic",
"fontWeight": "700",
"src": "file:./assets/fonts/Unna-BoldItalic.ttf"
}
],
"fontFamily": "Unna, serif",
"name": "Unna",
"slug": "unna"
}
]
}
},
"styles": {
"blocks": {
"core/image": {
"filter": {
"duotone": "var(--wp--preset--duotone--grey-and-light)"
}
}
},
"color": {
"text": "var(--wp--preset--color--custom-text)"
},
"elements": {
"h1": {
"typography": {
"fontFamily": "var(--wp--preset--font-family--trocchi)",
"fontSize": "var(--wp--preset--font-size--xx-large)",
"fontStyle": "normal",
"fontWeight": "400",
"lineHeight": "0.8"
}
},
"h2": {
"typography": {
"fontFamily": "var(--wp--preset--font-family--trocchi)",
"fontSize": "var(--wp--preset--font-size--x-large)",
"lineHeight": "0.8"
}
},
"heading": {
"typography": {
"fontFamily": "var(--wp--preset--font-family--trocchi)"
}
}
},
"typography": {
"fontFamily": "var(--wp--preset--font-family--unna)"
}
},
"title": "My Typo",
"version": 2,
"$schema": "https://schemas.wp.org/wp/6.5/theme.json"
}
156 changes: 156 additions & 0 deletions poetry/styles/old-times.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,156 @@
{
"settings": {
"color": {
"palette": [
{
"color": "#ffffff",
"name": "Background",
"slug": "custom-background"
},
{
"color": "#57473f",
"name": "Text",
"slug": "custom-text"
},
{
"color": "#f5f4f4",
"name": "Background Light",
"slug": "custom-background-light"
},
{
"color": "#cc1b1b",
"name": "Contrast",
"slug": "custom-contrast"
}
]
},
"typography": {
"fontFamilies": [
{
"fontFamily": "-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif",
"name": "System Font",
"slug": "system-font"
},
{
"fontFace": [
{
"fontFamily": "Rozha One",
"fontStyle": "normal",
"fontWeight": "400",
"src": [
"file:./assets/fonts/rozha-one_normal_400.ttf"
]
}
],
"fontFamily": "Rozha One",
"name": "Rozha One",
"slug": "rozha-one"
},
{
"fontFace": [
{
"fontFamily": "Inter",
"fontStyle": "normal",
"fontWeight": "300",
"src": [
"file:./assets/fonts/inter_normal_300.ttf"
]
},
{
"fontFamily": "Inter",
"fontStyle": "normal",
"fontWeight": "600",
"src": [
"file:./assets/fonts/inter_normal_600.ttf"
]
},
{
"fontFamily": "Inter",
"fontStyle": "normal",
"fontWeight": "700",
"src": [
"file:./assets/fonts/inter_normal_700.ttf"
]
}
],
"fontFamily": "Inter",
"name": "Inter",
"slug": "inter"
},
{
"fontFace": [
{
"fontFamily": "Alice",
"fontStyle": "normal",
"fontWeight": "400",
"src": "file:./assets/fonts/Alice-Regular.ttf"
}
],
"fontFamily": "Alice",
"name": "Alice",
"slug": "alice"
},
{
"fontFace": [
{
"fontFamily": "\"Josefin Sans\"",
"fontStyle": "normal",
"fontWeight": "100 300 600",
"src": "file:./assets/fonts/JosefinSans-VariableFont_wght.ttf"
},
{
"fontFamily": "\"Josefin Sans\"",
"fontStyle": "italic",
"fontWeight": "100 300 600",
"src": "file:./assets/fonts/JosefinSans-Italic-VariableFont_wght.ttf"
}
],
"fontFamily": "\"Josefin Sans\", sans-serif",
"name": "Josefin Sans",
"slug": "josefin-sans"
}
]
}
},
"styles": {
"blocks": {
"core/image": {
"filter": {
"duotone": "var(--wp--preset--duotone--grayscale)"
}
}
},
"color": {
"text": "var(--wp--preset--color--custom-text)"
},
"elements": {
"h1": {
"typography": {
"fontFamily": "var(--wp--preset--font-family--alice)",
"fontSize": "var(--wp--preset--font-size--xx-large)",
"fontStyle": "normal",
"fontWeight": "400",
"lineHeight": "0.8"
}
},
"h2": {
"typography": {
"fontFamily": "var(--wp--preset--font-family--alice)",
"fontSize": "var(--wp--preset--font-size--x-large)",
"lineHeight": "0.8"
}
},
"heading": {
"typography": {
"fontFamily": "var(--wp--preset--font-family--alice)"
}
}
},
"typography": {
"fontFamily": "var(--wp--preset--font-family--josefin-sans)"
}
},
"title": "Old Times",
"version": 2,
"$schema": "https://schemas.wp.org/wp/6.5/theme.json"
}
Loading
Loading