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

Pixel: update navigation menu #6509

Merged
merged 3 commits into from
Sep 7, 2022
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
Binary file added pixel/assets/fonts/uni05_53.ttf
Binary file not shown.
4 changes: 2 additions & 2 deletions pixel/parts/header.html
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<!-- wp:group {"layout":{"inherit":"true","type":"constrained"},"style":{"spacing":{"blockGap":"0","padding":{"top":"0","right":"calc(2 * var(\u002d\u002dwp\u002d\u002dcustom\u002d\u002dspacing\u002d\u002douter))","bottom":"0","left":"calc(2 * var(\u002d\u002dwp\u002d\u002dcustom\u002d\u002dspacing\u002d\u002douter))"}}}} -->
<div class="wp-block-group" style="padding-top:0;padding-right:calc(2 * var(--wp--custom--spacing--outer));padding-bottom:0;padding-left:calc(2 * var(--wp--custom--spacing--outer))"><!-- wp:group {"layout":{"type":"flex","justifyContent":"space-between"},"align":"full","style":{"spacing":{"padding":{"bottom":"var:preset|spacing|30","top":"var:preset|spacing|30","right":"var:preset|spacing|30","left":"var:preset|spacing|30"},"blockGap":"0"},"border":{"width":"2px"}},"className":"pixel-shadow"} -->
<div class="wp-block-group alignfull pixel-shadow" style="border-width:2px;padding-top:var(--wp--preset--spacing--30);padding-right:var(--wp--preset--spacing--30);padding-bottom:var(--wp--preset--spacing--30);padding-left:var(--wp--preset--spacing--30)"><!-- wp:group {"layout":{"type":"flex"},"style":{"spacing":{"padding":{"right":"var:preset|spacing|20","bottom":"0","left":"var:preset|spacing|20"}}}} -->
<div class="wp-block-group" style="padding-right:var(--wp--preset--spacing--20);padding-bottom:0;padding-left:var(--wp--preset--spacing--20)"><!-- wp:site-logo {"width":64} /-->
<div class="wp-block-group" style="padding-right:var(--wp--preset--spacing--20);padding-bottom:0;padding-left:var(--wp--preset--spacing--20)">

<!-- wp:site-title /--></div>
<!-- /wp:group -->

<!-- wp:navigation {"layout":{"type":"flex","setCascadingProperties":true,"justifyContent":"right","orientation":"horizontal"},"style":{"spacing":{"margin":{"top":"0"}}}} /--></div>
<!-- wp:navigation {"__unstableLocation":"primary","overlayBackgroundColor":"background","overlayTextColor":"foreground","layout":{"type":"flex","setCascadingProperties":true,"justifyContent":"left","orientation":"horizontal"},"style":{"spacing":{"margin":{"top":"0"}}}} /--></div>
<!-- /wp:group --></div>
<!-- /wp:group -->

Expand Down
13 changes: 13 additions & 0 deletions pixel/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -56,3 +56,16 @@ Tags: one-column, custom-colors, custom-menu, custom-logo, editor-style, feature
box-shadow: var(--wp--custom--shadow);
margin-right: var(--wp--preset--spacing--20);
}

/*
* Navigation styles
*/
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content .wp-block-navigation__submenu-container {
padding-top: 0.25rem;
padding-bottom: 0.25rem;
}
.wp-block-navigation__responsive-container .wp-block-navigation__responsive-container-content .wp-block-navigation__submenu-container {
background-color: var(--wp--preset--color--background);
color: var(--wp--preset--color--foreground);
border-color: var(--wp--preset--color--primary);
}
27 changes: 26 additions & 1 deletion pixel/theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,23 @@
]
}
]
},
{
"fontFamily": "'uni 05_53', sans-serif",
"name": "uni 05_53",
"slug": "uni-05_53",
"fontFace": [
{
"fontDisplay": "block",
"fontFamily": "uni 05_53",
"fontWeight": "400",
"fontStyle": "normal",
"fontStretch": "normal",
"src": [
"file:./assets/fonts/uni05_53.ttf"
]
}
]
}
],
"fontSizes": [
Expand Down Expand Up @@ -251,7 +268,14 @@
},
"core/navigation": {
"typography": {
"fontSize": "1.125rem"
"fontSize": "0.875rem"
},
"spacing": {
"blockGap": "1rem",
"padding": {
"left": "0.25rem !important",
"right": "0.25rem !important"
}
}
},
"core/post-date": {
Expand Down Expand Up @@ -342,6 +366,7 @@
},
"core/site-title": {
"typography": {
"fontFamily": "var(--wp--preset--font-family--uni-05-53)",
"fontSize": "0.875rem",
"fontWeight": "400",
"textTransform": "uppercase",
Expand Down