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

Blockbase: Update Blockbase and children to use flex #4468

Merged
merged 7 commits into from
Aug 30, 2021
Merged
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
8 changes: 0 additions & 8 deletions blockbase/assets/ponyfill.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions blockbase/block-template-parts/header.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<!-- wp:group {"align":"full","style":{"spacing":{"padding":{"bottom":"40px"}}},"className":"site-header"} -->
<!-- wp:group {"align":"full","layout":{"type":"flex"},"style":{"spacing":{"padding":{"bottom":"40px"}}},"className":"site-header"} -->
<div class="wp-block-group alignfull site-header" style="padding-bottom:40px">
<!-- wp:site-title /-->
<!-- wp:navigation {"isResponsive":true,"__unstableLocation":"primary"} /-->
</div>
<!-- /wp:group -->
<!-- /wp:group -->
4 changes: 0 additions & 4 deletions blockbase/sass/base/_header.scss
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
// This is needed until something like https://github.com/WordPress/gutenberg/issues/24473 exists
.site-header {
align-items: center;
flex-wrap: wrap;
justify-content: space-between;
display: flex;
overflow: inherit;

.wp-block-site-title a {
Expand Down
3 changes: 1 addition & 2 deletions blockbase/sass/base/_mixins.scss
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@

@mixin post-meta-icon {
display: flex;
margin-right: calc(2 * var(--wp--custom--margin--baseline) );
&:before {
align-self: center;
content: '';
Expand All @@ -29,4 +28,4 @@
-webkit-mask-repeat: no-repeat;
background-color: currentColor;
}
}
}
3 changes: 0 additions & 3 deletions blockbase/sass/post/_meta.scss
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
.post-meta {
// TODO - needed until https://github.com/WordPress/gutenberg/issues/24473
display: flex;

.wp-block-post-author,
.wp-block-post-date,
.taxonomy-post_tag,
Expand Down
3 changes: 3 additions & 0 deletions blockbase/theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -563,6 +563,9 @@
}
}
},
"spacing": {
"blockGap": "var(--wp--custom--margin--vertical)"
},
"typography": {
"lineHeight": "var(--wp--custom--body--typography--line-height)",
"fontFamily": "var(--wp--preset--font-family--system-font)",
Expand Down
4 changes: 2 additions & 2 deletions mayland-blocks/block-template-parts/header.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<!-- wp:group {"align":"full","className":"site-header"} -->
<!-- wp:group {"align":"full","layout":{"type":"flex"},"className":"site-header"} -->
<div class="wp-block-group alignfull site-header">
<!-- wp:site-logo /-->
<!-- wp:site-title /-->
<!-- wp:navigation {"orientation":"horizontal","textColor":"foreground-light","itemsJustification":"right","fontSize":"small","isResponsive":true,"__unstableLocation":"primary"} -->
<!-- /wp:navigation -->
</div>
<!-- /wp:group -->
<!-- /wp:group -->
2 changes: 1 addition & 1 deletion mayland-blocks/block-template-parts/post-meta.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<!-- wp:group {"textColor":"gray","className":"post-meta"} -->
<!-- wp:group {"textColor":"gray","className":"post-meta","layout":{"type":"flex"}} -->
<div class="post-meta wp-block-group post-meta has-gray-color has-text-color"><!-- wp:post-author {"showAvatar":false,"showBio":false,"fontSize":"small"} /-->

<!-- wp:post-date {"fontSize":"small","isLink":true} /-->
Expand Down
3 changes: 3 additions & 0 deletions mayland-blocks/theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -592,6 +592,9 @@
}
}
},
"spacing": {
"blockGap": "var(--wp--custom--margin--vertical)"
},
"typography": {
"lineHeight": "var(--wp--custom--body--typography--line-height)",
"fontFamily": "var(--wp--preset--font-family--poppins)",
Expand Down
6 changes: 0 additions & 6 deletions quadrat/assets/theme.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions quadrat/block-template-parts/header.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<!-- wp:group {"tagName":"header","style":{"spacing":{"padding":{"bottom":"170px"}}},"className":"site-header"} -->
<!-- wp:group {"tagName":"header","layout":{"type":"flex"},"style":{"spacing":{"padding":{"bottom":"170px"}}},"className":"site-header"} -->
<header class="wp-block-group site-header" style="padding-bottom:170px">
<!-- wp:site-logo /-->
<!-- wp:site-title /-->
<!-- wp:site-tagline {"style":{"spacing":{"padding":{"top":"0px","right":"0px","bottom":"0px","left":"20px"},"margin":{"right":"auto"}}},"fontSize":"tiny"} /-->
<!-- wp:navigation {"isResponsive":true,"__unstableLocation":"primary"} /-->
</header>
<!-- /wp:group -->
<!-- /wp:group -->
2 changes: 1 addition & 1 deletion quadrat/block-templates/single.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<!-- wp:group {"tagName":"main"} -->
<main class="wp-block-group">

<!-- wp:group {"className":"post-meta"} -->
<!-- wp:group {"className":"post-meta","layout":{"type":"flex"}} -->
<div class="wp-block-group post-meta">
<!-- wp:post-date {"textAlign":"center","fontSize":"tiny","isLink":true} /-->
<!-- wp:post-terms {"term":"category","textAlign":"center","fontSize":"tiny"} /-->
Expand Down
2 changes: 1 addition & 1 deletion quadrat/inc/patterns/query-diamond.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<div class="wp-block-query alignwide is-style-quadrat-diamond-posts"><!-- wp:post-template -->
<!-- wp:columns -->
<div class="wp-block-columns"><!-- wp:column {"verticalAlignment":"center"} -->
<div class="wp-block-column is-vertically-aligned-center"><!-- wp:group {"className":"post-meta"} -->
<div class="wp-block-column is-vertically-aligned-center"><!-- wp:group {"className":"post-meta","layout":{"type":"flex"}} -->
<div class="wp-block-group post-meta"><!-- wp:post-date {"fontSize":"tiny","isLink":true} /-->

<!-- wp:post-terms {"term":"category","fontSize":"tiny"} /--></div>
Expand Down
2 changes: 0 additions & 2 deletions quadrat/sass/templates/_meta.scss
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,12 @@

> *,
.wp-block-post-date {
margin: 0 8px;
&::before {
content: "";
}
}

.wp-block-post-terms {
margin-left: 0;
&::before {
color: var(--wp--custom--color--foreground);
content: "·";
Expand Down
3 changes: 3 additions & 0 deletions quadrat/theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -668,6 +668,9 @@
}
}
},
"spacing": {
"blockGap": "var(--wp--custom--margin--vertical)"
},
"typography": {
"lineHeight": "var(--wp--custom--body--typography--line-height)",
"fontFamily": "var(--wp--preset--font-family--dm-sans)",
Expand Down
2 changes: 1 addition & 1 deletion seedlet-blocks/block-template-parts/post-meta.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<hr class="wp-block-separator is-style-wide"/>
<!-- /wp:separator -->

<!-- wp:group {"className":"post-meta"} -->
<!-- wp:group {"className":"post-meta","layout":{"type":"flex"}} -->
<div class="wp-block-group post-meta"><!-- wp:post-author {"showAvatar":false,"showBio":false,"fontSize":"tiny"} /-->

<!-- wp:post-date {"fontSize":"tiny","isLink":true} /-->
Expand Down
3 changes: 3 additions & 0 deletions seedlet-blocks/theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -626,6 +626,9 @@
}
}
},
"spacing": {
"blockGap": "var(--wp--custom--margin--vertical)"
},
"typography": {
"lineHeight": "var(--wp--custom--body--typography--line-height)",
"fontFamily": "var(--wp--preset--font-family--fira-sans)",
Expand Down
4 changes: 3 additions & 1 deletion skatepark/assets/theme.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion skatepark/block-templates/single.html
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
<div class="wp-block-column"><!-- wp:separator {"className":"is-style-wide"} -->
<hr class="wp-block-separator is-style-wide"/>
<!-- /wp:separator -->
<!-- wp:group {"className":"post-meta"} -->
<!-- wp:group {"className":"post-meta","layout":{"type":"flex"}} -->
<div class="wp-block-group post-meta">
<!-- wp:post-date {"fontSize":"tiny","isLink":true} /-->
<!-- wp:post-terms {"term":"category","fontSize":"tiny"} /-->
Expand Down
6 changes: 5 additions & 1 deletion skatepark/sass/elements/_post-meta.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
.post-meta {
flex-direction: column;
&.wp-block-group {
flex-direction: column;
align-items: start;
gap: .5em;
}

.wp-block-post-date,
.taxonomy-category,
Expand Down
3 changes: 3 additions & 0 deletions skatepark/theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -649,6 +649,9 @@
}
}
},
"spacing": {
"blockGap": "var(--wp--custom--margin--vertical)"
},
"typography": {
"lineHeight": "var(--wp--custom--body--typography--line-height)",
"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
Expand Down