Kjell Reigstad 4 years ago
parent
commit
74ab44ec11

+ 4 - 4
mayland-blocks/block-template-parts/footer.html

@@ -9,13 +9,13 @@
 
 
 <!-- wp:column {"verticalAlignment":"center"} -->
 <!-- wp:column {"verticalAlignment":"center"} -->
 <div class="wp-block-column is-vertically-aligned-center"><!-- wp:navigation {"orientation":"horizontal","itemsJustification":"right","fontSize":"small"} -->
 <div class="wp-block-column is-vertically-aligned-center"><!-- wp:navigation {"orientation":"horizontal","itemsJustification":"right","fontSize":"small"} -->
-<!-- wp:navigation-link {"label":"Home","url":"http://dotcomthemes.test"} /-->
+<!-- wp:navigation-link {"label":"Home","url":"#"} /-->
 
 
-<!-- wp:navigation-link {"label":"Services","url":"https://gutenberg.test/?page_id=2170"} /-->
+<!-- wp:navigation-link {"label":"Services","url":"#"} /-->
 
 
-<!-- wp:navigation-link {"label":"Portfolio","url":"https://gutenberg.test/?page_id=2165"} /-->
+<!-- wp:navigation-link {"label":"Portfolio","url":"#"} /-->
 
 
-<!-- wp:navigation-link {"label":"Contact","url":"https://gutenberg.test/?page_id=2175"} /-->
+<!-- wp:navigation-link {"label":"Contact","url":"#"} /-->
 <!-- /wp:navigation --></div>
 <!-- /wp:navigation --></div>
 <!-- /wp:column --></div>
 <!-- /wp:column --></div>
 <!-- /wp:columns -->
 <!-- /wp:columns -->

+ 3 - 0
mayland-blocks/block-template-parts/header.html

@@ -1,3 +1,6 @@
+<!-- wp:spacer -->
+<div style="height:12px" aria-hidden="true" class="wp-block-spacer"></div>
+<!-- /wp:spacer -->
 <!-- wp:columns {"verticalAlignment":"bottom","align":"full"} -->
 <!-- wp:columns {"verticalAlignment":"bottom","align":"full"} -->
 <div class="wp-block-columns alignfull are-vertically-aligned-bottom"><!-- wp:column {"verticalAlignment":"bottom"} -->
 <div class="wp-block-columns alignfull are-vertically-aligned-bottom"><!-- wp:column {"verticalAlignment":"bottom"} -->
 <div class="wp-block-column is-vertically-aligned-bottom"><!-- wp:site-title /--></div>
 <div class="wp-block-column is-vertically-aligned-bottom"><!-- wp:site-title /--></div>

+ 1 - 1
mayland-blocks/block-templates/index.html

@@ -6,7 +6,7 @@
 
 
 <!-- wp:post-excerpt /-->
 <!-- wp:post-excerpt /-->
 
 
-<!-- wp:post-date {"fontSize":"small"} /-->
+<!-- wp:post-date /-->
 
 
 <!-- wp:spacer -->
 <!-- wp:spacer -->
 <div style="height:100px" aria-hidden="true" class="wp-block-spacer"></div>
 <div style="height:100px" aria-hidden="true" class="wp-block-spacer"></div>

+ 4 - 0
mayland-blocks/block-templates/page.html

@@ -1,5 +1,9 @@
 <!-- wp:template-part {"slug":"header","theme":"mayland-blocks","align":"full", "tagName":"header","className":"site-header"} /-->
 <!-- wp:template-part {"slug":"header","theme":"mayland-blocks","align":"full", "tagName":"header","className":"site-header"} /-->
 
 
+<!-- wp:spacer {"height":32} -->
+<div style="height:32px" aria-hidden="true" class="wp-block-spacer"></div>
+<!-- /wp:spacer -->
+
 <!-- wp:post-title {"level":1} /-->
 <!-- wp:post-title {"level":1} /-->
 
 
 <!-- wp:post-content /-->
 <!-- wp:post-content /-->

+ 18 - 0
mayland-blocks/block-templates/single.html

@@ -1,9 +1,27 @@
 <!-- wp:template-part {"slug":"header","theme":"mayland-blocks","align":"full", "tagName":"header","className":"site-header"} /-->
 <!-- wp:template-part {"slug":"header","theme":"mayland-blocks","align":"full", "tagName":"header","className":"site-header"} /-->
 
 
+<!-- wp:spacer {"height":32} -->
+<div style="height:32px" aria-hidden="true" class="wp-block-spacer"></div>
+<!-- /wp:spacer -->
+
+<!-- wp:post-date /-->
+
 <!-- wp:post-title {"level":1} /-->
 <!-- wp:post-title {"level":1} /-->
 
 
 <!-- wp:post-content /-->
 <!-- wp:post-content /-->
 
 
+<!-- wp:post-date /-->
+
+<!-- wp:spacer {"height":64} -->
+<div style="height:64px" aria-hidden="true" class="wp-block-spacer"></div>
+<!-- /wp:spacer -->
+
+<!-- wp:post-author {"showAvatar":false,"showBio":true,"byline":"Published by","fontSize":"huge"} /-->
+
+<!-- wp:spacer {"height":32} -->
+<div style="height:32px" aria-hidden="true" class="wp-block-spacer"></div>
+<!-- /wp:spacer -->
+
 <!-- wp:post-comments /-->
 <!-- wp:post-comments /-->
 
 
 <!-- wp:template-part {"slug":"footer","theme":"mayland-blocks","align":"full","tagName":"footer","className":"site-footer"} /-->
 <!-- wp:template-part {"slug":"footer","theme":"mayland-blocks","align":"full","tagName":"footer","className":"site-footer"} /-->

+ 67 - 0
mayland-blocks/experimental-theme.json

@@ -121,6 +121,73 @@
 			}
 			}
 		}
 		}
 	},
 	},
+	"core/heading/h1": {
+		"styles": {
+			"typography": {
+				"fontSize": "41.47px",
+				"lineHeight": "var(--wp--custom--line-height--headings)"
+			}
+		}
+	},
+	"core/heading/h2": {
+		"styles": {
+			"typography": {
+				"fontSize": "var(--wp--preset--font-size--huge)",
+				"lineHeight": "var(--wp--custom--line-height--headings)"
+			}
+		}
+	},
+	"core/heading/h3": {
+		"styles": {
+			"typography": {
+				"fontSize": "var(--wp--preset--font-size--large)",
+				"lineHeight": "var(--wp--custom--line-height--headings)"
+			}
+		}
+	},
+	"core/heading/h4": {
+		"styles": {
+			"typography": {
+				"fontSize": "24px",
+				"lineHeight": "var(--wp--custom--line-height--headings)"
+			}
+		}
+	},
+	"core/heading/h5": {
+		"styles": {
+			"typography": {
+				"fontSize": "var(--wp--preset--font-size--normal)",
+				"lineHeight": "var(--wp--custom--line-height--headings)"
+			}
+		}
+	},
+	"core/heading/h6": {
+		"styles": {
+			"typography": {
+				"fontSize": "var(--wp--preset--font-size--small)",
+				"lineHeight": "var(--wp--custom--line-height--headings)"
+			}
+		}
+	},
+	"core/post-title": {
+		"styles": {
+			"typography": {
+				"fontSize": "var(--wp--preset--font-size--huge)",
+				"lineHeight": "var(--wp--custom--line-height--headings)"
+			}
+		}
+	},
+	"core/post-date": {
+		"styles": {
+			"color": {
+				"text": "var(--wp--preset--color--foreground-light)",
+				"link": "var(--wp--preset--color--foreground-light)"
+			},
+			"typography": {
+				"fontSize": "var(--wp--preset--font-size--small)"
+			}
+		}
+	},
 	"core/site-title": {
 	"core/site-title": {
 		"styles": {
 		"styles": {
 			"typography": {
 			"typography": {

+ 3 - 3
mayland-blocks/functions.php

@@ -3,7 +3,7 @@
 if ( ! function_exists( 'mayland_blocks_support' ) ) :
 if ( ! function_exists( 'mayland_blocks_support' ) ) :
 	function mayland_blocks_support()  {
 	function mayland_blocks_support()  {
 
 
-		// Alignwide and alignfull classes in the block editor
+		// Alignwide and alignfull classes in the block editor.
 		add_theme_support( 'align-wide' );
 		add_theme_support( 'align-wide' );
 
 
 		// Adding support for core block visual styles.
 		// Adding support for core block visual styles.
@@ -28,7 +28,7 @@ if ( ! function_exists( 'mayland_blocks_support' ) ) :
 endif;
 endif;
 
 
 /**
 /**
- * Add Google webfonts, if necessary
+ * Add Google webfonts, if necessary.
  *
  *
  * - See: http://themeshaper.com/2014/08/13/how-to-add-google-fonts-to-wordpress-themes/
  * - See: http://themeshaper.com/2014/08/13/how-to-add-google-fonts-to-wordpress-themes/
  */
  */
@@ -68,7 +68,7 @@ function mayland_blocks_scripts() {
 	// Enqueue front-end styles.
 	// Enqueue front-end styles.
 	wp_enqueue_style( 'mayland-blocks-block-styles', get_template_directory_uri() . '/assets/alignments.css' );
 	wp_enqueue_style( 'mayland-blocks-block-styles', get_template_directory_uri() . '/assets/alignments.css' );
 
 
-	// Enqueue Google fonts, if necessary
+	// Enqueue Google fonts, if necessary.
 	wp_enqueue_style( 'mayland-blocks-fonts', mayland_blocks_fonts_url(), array(), null );
 	wp_enqueue_style( 'mayland-blocks-fonts', mayland_blocks_fonts_url(), array(), null );
 }
 }
 add_action( 'wp_enqueue_scripts', 'mayland_blocks_scripts' );
 add_action( 'wp_enqueue_scripts', 'mayland_blocks_scripts' );

+ 34 - 5
mayland-blocks/style.css

@@ -15,12 +15,15 @@ This theme, like WordPress, is licensed under the GPL.
 Use it to make something cool, have fun, and share what you've learned with others.
 Use it to make something cool, have fun, and share what you've learned with others.
 */
 */
 
 
+
+/* Smooth out the fonts. */
+
 body {
 body {
 	-webkit-font-smoothing: antialiased;
 	-webkit-font-smoothing: antialiased;
 	-moz-osx-font-smoothing: grayscale;
 	-moz-osx-font-smoothing: grayscale;
 }
 }
 
 
-/* Editor widths */
+/* Set editor widths. */
 
 
 .wp-block {
 .wp-block {
 	max-width: var(--wp--custom--width--default);
 	max-width: var(--wp--custom--width--default);
@@ -34,17 +37,17 @@ body {
 	max-width: inherit;
 	max-width: inherit;
 }
 }
 
 
-/* Header spacing adjustments */
+/* Adjust header spacing. */
 
 
-.wp-block-site-title {
+.site-header .wp-block-site-title {
 	margin-bottom: 0.2rem;
 	margin-bottom: 0.2rem;
 }
 }
 
 
-.wp-block-site-title a {
+.site-header .wp-block-site-title a {
 	text-decoration: none;
 	text-decoration: none;
 }
 }
 
 
-.wp-block-navigation {
+.site-header .wp-block-navigation {
 	margin-bottom: 0;
 	margin-bottom: 0;
 }
 }
 
 
@@ -54,4 +57,30 @@ body {
 		padding-left: var(--wp--custom--margin--horizontal);
 		padding-left: var(--wp--custom--margin--horizontal);
 		padding-right: var(--wp--custom--margin--horizontal);
 		padding-right: var(--wp--custom--margin--horizontal);
 	}
 	}
+}
+
+/* Adjust heading letter spacing. */
+
+h1 {
+	letter-spacing: -0.015em;
+}
+
+h2 {
+	letter-spacing: -0.015em;
+}
+
+h3 {
+	letter-spacing: -0.015em;
+}
+
+h4 {
+	letter-spacing: normal;
+}
+
+h5 {
+	letter-spacing: normal;
+}
+
+h6 {
+	letter-spacing: normal;
 }
 }