Skip to content

Commit

Permalink
Fix the missing archive template in Poetry (#140)
Browse files Browse the repository at this point in the history
* Creates a basic template for categories, tags and other base archives

* Removes the ID from the template query block

* created global font sizes for the theme, replaced headings on header pattern

* more heading fixes

---------

Co-authored-by: MaggieCabrera <[email protected]>
  • Loading branch information
sandroschutt and MaggieCabrera authored Apr 18, 2024
1 parent c099a5a commit 0218f99
Show file tree
Hide file tree
Showing 3 changed files with 59 additions and 18 deletions.
14 changes: 7 additions & 7 deletions poetry/patterns/header.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@
<!-- wp:group {"style":{"spacing":{"padding":{"top":"32px","bottom":"64px"}}},"layout":{"type":"constrained"}} -->
<div class="wp-block-group" style="padding-top:32px;padding-bottom:64px"><!-- wp:group {"style":{"spacing":{"blockGap":"64px"}},"layout":{"type":"flex","flexWrap":"nowrap"}} -->
<div class="wp-block-group"><!-- wp:group {"style":{"spacing":{"blockGap":"88px"}},"layout":{"type":"flex","orientation":"vertical"}} -->
<div class="wp-block-group"><!-- wp:site-title {"level":0,"isLink":false,"style":{"typography":{"fontSize":"24px","fontStyle":"normal","fontWeight":"600"}},"textColor":"custom-text"} /-->
<div class="wp-block-group"><!-- wp:site-title {"level":0,"isLink":false,"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:heading {"level":1} -->
<h1>Food <br>for thoughts</h1>
<!-- /wp:heading -->
<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>
<!-- /wp:paragraph -->

<!-- wp:heading {"level":5} -->
<h5>A collection of valuable thoughts by a very egocentric person.</h5>
<!-- /wp:heading --></div>
<!-- wp:paragraph {"style":{"typography":{"lineHeight":"1.5"}},"fontSize":"medium"} -->
<p class="has-medium-font-size" style="line-height:1.5">A collection of valuable thoughts by a very egocentric person.</p>
<!-- /wp:paragraph --></div>
<!-- /wp:group --></div>
<!-- /wp:group -->

Expand Down
23 changes: 23 additions & 0 deletions poetry/templates/archive.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<!-- wp:template-part {"slug":"header","area":"header"} /-->

<!-- wp:group {"layout":{"type":"constrained"}} -->
<div class="wp-block-group"><!-- wp:query-title {"type":"archive","style":{"spacing":{"padding":{"bottom":"var:preset|spacing|40"}}},"fontSize":"x-large"} /-->

<!-- wp:query {"query":{"perPage":10,"pages":0,"offset":0,"postType":"post","order":"desc","orderBy":"date","author":"","search":"","exclude":[],"sticky":"","inherit":true},"layout":{"type":"default"}} -->
<div class="wp-block-query"><!-- wp:post-template -->
<!-- wp:post-title {"isLink":true,"style":{"elements":{"link":{"color":{"text":"var:preset|color|custom-text"}}}},"textColor":"custom-text","fontSize":"large"} /-->

<!-- wp:post-featured-image {"isLink":true,"align":"wide"} /-->

<!-- wp:post-excerpt /-->

<!-- wp:separator {"opacity":"css"} -->
<hr class="wp-block-separator has-css-opacity"/>
<!-- /wp:separator -->

<!-- wp:post-date /-->
<!-- /wp:post-template --></div>
<!-- /wp:query --></div>
<!-- /wp:group -->

<!-- wp:template-part {"slug":"footer","area":"footer"} /-->
40 changes: 29 additions & 11 deletions poetry/theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,33 @@
"fontFamily": "Inter",
"slug": "inter"
}
],
"fontSizes": [
{
"name": "Small",
"size": "1rem",
"slug": "small"
},
{
"name": "Medium",
"size": "1.5rem",
"slug": "medium"
},
{
"name": "Large",
"size": "2.75rem",
"slug": "large"
},
{
"name": "Extra Large",
"size": "5rem",
"slug": "x-large"
},
{
"name": "Extra Extra Large",
"size": "7.5rem",
"slug": "xx-large"
}
]
}
},
Expand All @@ -101,7 +128,7 @@
"h1": {
"typography": {
"fontFamily": "Rozha One",
"fontSize": "120px",
"fontSize": "var(--wp--preset--font-size--xx-large)",
"fontStyle": "normal",
"fontWeight": "400",
"lineHeight": 0.8
Expand All @@ -110,19 +137,10 @@
"h2": {
"typography": {
"fontFamily": "Rozha One",
"fontSize": "80px",
"fontSize": "var(--wp--preset--font-size--x-large)",
"lineHeight": "0.8"
}
},
"h5": {
"typography": {
"fontFamily": "Inter",
"fontSize": "24px",
"fontStyle": "normal",
"fontWeight": "400",
"lineHeight": 1.5
}
},
"heading": {
"typography": {
"fontFamily": "Rozha One"
Expand Down

0 comments on commit 0218f99

Please sign in to comment.