Jelajahi Sumber

Blockbase: Update font customization approach (#4389)

* Blockbase: Set the fonts directly in settings not in custom

* fix the reset button

* update child themes

* remove unused variable

* add google font to theme.json default

* inherit font family from body

* Set pullquote to use the heading font in all themes
Ben Dwyer 4 tahun lalu
induk
melakukan
9a4a21d211

+ 5 - 7
blockbase/assets/ponyfill.css

@@ -201,7 +201,7 @@ textarea {
 	border-radius: var(--wp--custom--form--border--radius);
 	box-shadow: var(--wp--custom--form--color--box-shadow);
 	color: var(--wp--custom--form--color--text);
-	font-family: var(--wp--custom--body--typography--font-family);
+	font-family: inherit;
 	padding: var(--wp--custom--form--padding);
 }
 
@@ -255,7 +255,7 @@ input[type=checkbox] + label {
 	padding-left: calc( var(--wp--custom--button--spacing--padding--left) + var(--wp--custom--button--border--width));
 	padding-right: calc( var(--wp--custom--button--spacing--padding--right) + var(--wp--custom--button--border--width));
 	font-weight: var(--wp--custom--button--typography--font-weight);
-	font-family: var(--wp--custom--button--typography--font-family);
+	font-family: inherit;
 	font-size: var(--wp--custom--button--typography--font-size);
 	line-height: var(--wp--custom--button--typography--line-height);
 	text-decoration: none;
@@ -392,7 +392,6 @@ p.has-text-color a {
 
 p.has-drop-cap:not(:focus):first-letter {
 	font-size: var(--wp--custom--paragraph--dropcap--typography--font-size);
-	font-family: var(--wp--custom--paragraph--dropcap--typography--font-family);
 	font-weight: var(--wp--custom--paragraph--dropcap--typography--font-weight);
 	margin: var(--wp--custom--paragraph--dropcap--margin);
 }
@@ -417,7 +416,7 @@ p.has-background {
 	padding-left: calc( var(--wp--custom--button--spacing--padding--left) + var(--wp--custom--button--border--width));
 	padding-right: calc( var(--wp--custom--button--spacing--padding--right) + var(--wp--custom--button--border--width));
 	font-weight: var(--wp--custom--button--typography--font-weight);
-	font-family: var(--wp--custom--button--typography--font-family);
+	font-family: inherit;
 	font-size: var(--wp--custom--button--typography--font-size);
 	line-height: var(--wp--custom--button--typography--line-height);
 	text-decoration: none;
@@ -501,7 +500,6 @@ p.has-background {
 .wp-block-pullquote blockquote cite {
 	display: block;
 	font-size: var(--wp--custom--pullquote--citation--typography--font-size);
-	font-family: var(--wp--custom--pullquote--citation--typography--font-family);
 	font-style: var(--wp--custom--pullquote--citation--typography--font-style);
 	font-weight: var(--wp--custom--pullquote--citation--typography--font-weight);
 	margin-top: var(--wp--custom--pullquote--citation--spacing--margin--top);
@@ -595,7 +593,7 @@ p.has-background {
 	padding-left: calc( var(--wp--custom--button--spacing--padding--left) + var(--wp--custom--button--border--width));
 	padding-right: calc( var(--wp--custom--button--spacing--padding--right) + var(--wp--custom--button--border--width));
 	font-weight: var(--wp--custom--button--typography--font-weight);
-	font-family: var(--wp--custom--button--typography--font-family);
+	font-family: inherit;
 	font-size: var(--wp--custom--button--typography--font-size);
 	line-height: var(--wp--custom--button--typography--line-height);
 	text-decoration: none;
@@ -653,7 +651,7 @@ p.has-background {
 	padding-left: calc( var(--wp--custom--button--spacing--padding--left) + var(--wp--custom--button--border--width));
 	padding-right: calc( var(--wp--custom--button--spacing--padding--right) + var(--wp--custom--button--border--width));
 	font-weight: var(--wp--custom--button--typography--font-weight);
-	font-family: var(--wp--custom--button--typography--font-family);
+	font-family: inherit;
 	font-size: var(--wp--custom--button--typography--font-size);
 	line-height: var(--wp--custom--button--typography--line-height);
 	text-decoration: none;

+ 16 - 5
blockbase/functions.php

@@ -78,16 +78,27 @@ function blockbase_fonts_url() {
 	}
 
 	$theme_data = WP_Theme_JSON_Resolver_Gutenberg::get_merged_data()->get_settings();
-	if ( empty( $theme_data ) || empty( $theme_data['custom'] ) ) {
+	if ( empty( $theme_data ) || empty( $theme_data['typography'] ) || empty( $theme_data['typography']['fontFamilies'] ) ) {
 		return '';
 	}
 
-	$custom_data = $theme_data['custom'];
-	if ( ! array_key_exists( 'fontsToLoadFromGoogle', $custom_data ) ) {
-		return '';
+	$font_families = [];
+	if ( ! empty( $theme_data['typography']['fontFamilies']['theme'] ) ) {
+		foreach( $theme_data['typography']['fontFamilies']['theme'] as $font ) {
+			if ( ! empty( $font['google'] ) ) {
+				$font_families[] = $font['google'];
+			}
+		}
+	}
+
+	if ( ! empty( $theme_data['typography']['fontFamilies']['user'] ) ) {
+		foreach( $theme_data['typography']['fontFamilies']['user'] as $font ) {
+			if ( ! empty( $font['google'] ) ) {
+				$font_families[] = $font['google'];
+			}
+		}
 	}
 
-	$font_families   = $theme_data['custom']['fontsToLoadFromGoogle'];
 	$font_families[] = 'display=swap';
 
 	// Make a single request for the theme fonts.

+ 7 - 4
blockbase/inc/customizer/wp-customize-fonts-preview.js

@@ -13,10 +13,13 @@ if ( fontSettings ) {
 }
 
 function blockBaseUpdateFontPreview() {
-	// Build the new CSS variables.
-	let innerHTML = ':root,body{';
-	innerHTML += `--wp--custom--body--typography--font-family:${ fontSettings[ 'body' ] };`;
-	innerHTML += `--wp--custom--heading--typography--font-family:${ fontSettings[ 'heading' ] };`;
+	// Build the new body CSS
+	let innerHTML = 'body{';
+	innerHTML += `font-family:${ fontSettings[ 'body' ] };`;
+	innerHTML += '}';
+	// Build the new heading CSS
+	innerHTML += 'h1,h2,h3,h4,h5,h6,.wp-block-post-title,.wp-block-pullquote{';
+	innerHTML += `font-family:${ fontSettings[ 'heading' ] };`;
 	innerHTML += '}';
 
 	// Inject them into the body.

+ 68 - 21
blockbase/inc/customizer/wp-customize-fonts.php

@@ -232,9 +232,11 @@ class GlobalStylesFontsCustomizer {
 
 	function create_customization_style_element( $wp_customize ) {
 		wp_enqueue_style( 'global-styles-fonts-customizations', ' ', array( 'global-styles' ) ); // This needs to load after global_styles, hence the dependency
-		$css  = ':root,body{';
-		$css .= '--wp--custom--body--typography--font-family:' . $this->font_settings['body'] . ';';
-		$css .= '--wp--custom--heading--typography--font-family: ' . $this->font_settings['heading'] . '}';
+		$css  = 'body{';
+		$css .= 'font-family:' . $this->font_settings['body'] . ';';
+		$css .= '}';
+		$css .= 'h1,h2,h3,h4,h5,h6,.wp-block-post-title,.wp-block-pullquote{';
+		$css .= 'font-family:' . $this->font_settings['heading'] . ';';
 		$css .= '}';
 		wp_add_inline_style( 'global-styles-fonts-customizations', $css );
 	}
@@ -267,16 +269,15 @@ class GlobalStylesFontsCustomizer {
 	}
 
 	function initialize( $wp_customize ) {
-
 		$theme       = wp_get_theme();
 		$merged_json = WP_Theme_JSON_Resolver_Gutenberg::get_merged_data()->get_raw_data();
 		$theme_json  = WP_Theme_JSON_Resolver_Gutenberg::get_theme_data()->get_raw_data();
 
-		$body_font_default    = $this->get_font_family( 'body', $theme_json );
-		$heading_font_default = $this->get_font_family( 'heading', $theme_json );
+		$body_font_default    = $this->get_font_family( array( 'styles', 'typography', 'fontFamily' ), $theme_json );
+		$heading_font_default = $this->get_font_family( array( 'styles', 'elements', 'h1', 'typography', 'fontFamily' ), $theme_json );
 
-		$body_font_selected    = $this->get_font_family( 'body', $merged_json );
-		$heading_font_selected = $this->get_font_family( 'heading', $merged_json );
+		$body_font_selected    = $this->get_font_family( array( 'styles', 'typography', 'fontFamily' ), $merged_json );
+		$heading_font_selected = $this->get_font_family( array( 'styles', 'elements', 'h1', 'typography', 'fontFamily' ), $merged_json );
 
 		$this->font_settings = array(
 			'body'    => $body_font_selected['fontFamily'],
@@ -313,8 +314,8 @@ class GlobalStylesFontsCustomizer {
 		$this->add_setting_and_control( $wp_customize, 'heading', __( 'Heading font', 'blockbase' ), $heading_font_default['slug'], $heading_font_selected['slug'] );
 	}
 
-	function get_font_family( $location, $configuration ) {
-		$variable = $configuration['settings']['custom'][ $location ]['typography']['fontFamily'];
+	function get_font_family( $array, $configuration ) {
+		$variable = get_settings_array( $array, $configuration );
 		$slug     = preg_replace( '/var\(--wp--preset--font-family--(.*)\)/', '$1', $variable );
 		if ( ! isset( $this->fonts[ $slug ] ) ) {
 			$this->fonts[ $slug ] = $this->build_font_from_theme_data( $slug, $location, $configuration );
@@ -432,33 +433,79 @@ class GlobalStylesFontsCustomizer {
 			$font_families
 		);
 
-		// Set the custom body settings.
+		// Set the body typography settings.
 		$user_theme_json_post_content = set_settings_array(
 			$user_theme_json_post_content,
-			array( 'settings', 'custom', 'body', 'typography', 'fontFamily' ),
+			array( 'styles', 'typography', 'fontFamily' ),
 			$body_font_family_variable
 		);
 
-		// Set the custom heading settings.
 		$user_theme_json_post_content = set_settings_array(
 			$user_theme_json_post_content,
-			array( 'settings', 'custom', 'heading', 'typography', 'fontFamily' ),
+			array( 'styles', 'blocks', 'core/button', 'typography', 'fontFamily' ),
+			$heading_font_family_variable
+		);
+
+		// Set the heading typography settings.
+		$user_theme_json_post_content = set_settings_array(
+			$user_theme_json_post_content,
+			array( 'styles', 'elements', 'h1', 'typography', 'fontFamily' ),
+			$heading_font_family_variable
+		);
+
+		$user_theme_json_post_content = set_settings_array(
+			$user_theme_json_post_content,
+			array( 'styles', 'elements', 'h2', 'typography', 'fontFamily' ),
+			$heading_font_family_variable
+		);
+
+		$user_theme_json_post_content = set_settings_array(
+			$user_theme_json_post_content,
+			array( 'styles', 'elements', 'h3', 'typography', 'fontFamily' ),
+			$heading_font_family_variable
+		);
+
+		$user_theme_json_post_content = set_settings_array(
+			$user_theme_json_post_content,
+			array( 'styles', 'elements', 'h4', 'typography', 'fontFamily' ),
+			$heading_font_family_variable
+		);
+
+		$user_theme_json_post_content = set_settings_array(
+			$user_theme_json_post_content,
+			array( 'styles', 'elements', 'h5', 'typography', 'fontFamily' ),
 			$heading_font_family_variable
 		);
 
-		// Set the custom google fonts settings.
 		$user_theme_json_post_content = set_settings_array(
 			$user_theme_json_post_content,
-			array( 'settings', 'custom', 'fontsToLoadFromGoogle' ),
-			$google_font_array
+			array( 'styles', 'elements', 'h6', 'typography', 'fontFamily' ),
+			$heading_font_family_variable
+		);
+
+		$user_theme_json_post_content = set_settings_array(
+			$user_theme_json_post_content,
+			array( 'styles', 'blocks', 'core/post-title', 'typography', 'fontFamily' ),
+			$heading_font_family_variable
+		);
+
+		$user_theme_json_post_content = set_settings_array(
+			$user_theme_json_post_content,
+			array( 'styles', 'blocks', 'core/pullquote', 'typography', 'fontFamily' ),
+			$heading_font_family_variable
 		);
 
 		//If the typeface choices === the default then we remove it instead
 		if ( $body_value === $body_default && $heading_value === $heading_default ) {
-			unset( $user_theme_json_post_content->settings->typography->fontFamilies );
-			unset( $user_theme_json_post_content->settings->custom->body->typography->fontFamily );
-			unset( $user_theme_json_post_content->settings->custom->heading->typography->fontFamily );
-			unset( $user_theme_json_post_content->settings->custom->fontsToLoadFromGoogle );
+			unset( $user_theme_json_post_content->styles->typography->fontFamilies );
+			unset( $user_theme_json_post_content->styles->blocks->{'core/button'}->typography->fontFamilies );
+			unset( $user_theme_json_post_content->styles->elemenets->h1->typography->fontFamilies );
+			unset( $user_theme_json_post_content->styles->elemenets->h2->typography->fontFamilies );
+			unset( $user_theme_json_post_content->styles->elemenets->h3->typography->fontFamilies );
+			unset( $user_theme_json_post_content->styles->elemenets->h4->typography->fontFamilies );
+			unset( $user_theme_json_post_content->styles->elemenets->h5->typography->fontFamilies );
+			unset( $user_theme_json_post_content->styles->elemenets->h6->typography->fontFamilies );
+			unset( $user_theme_json_post_content->styles->blocks->{'core/post-title'}->typography->fontFamilies );
 		}
 
 		// Update the theme.json with the new settings.

+ 17 - 0
blockbase/inc/customizer/wp-customize-utils.php

@@ -23,3 +23,20 @@ function set_settings_array( $target, $array, $value ) {
 	$current->{ $key } = $value;
 	return $target;
 }
+
+/**
+ *
+ * Get a value from an object at the given location.
+ *
+ * @param   array   $array  The array describing the location of the property to update.
+ * @param   object  $object The object.
+ * @return  object          The value at the location.
+ *
+ */
+function get_settings_array( $array, $object ) {
+	foreach( $array as $property ) {
+		$object = $object[ $property ];
+	}
+
+	return $object;
+}

+ 2 - 2
blockbase/sass/blocks/_button-mixins.scss

@@ -28,7 +28,7 @@
 
 @mixin button-typography-styles {
 	font-weight: var(--wp--custom--button--typography--font-weight);
-	font-family: var(--wp--custom--button--typography--font-family);
+	font-family: inherit;
 	font-size: var(--wp--custom--button--typography--font-size);
 	line-height: var(--wp--custom--button--typography--line-height);
 	text-decoration: none; // Needed because link styles inside .entry-content add a text decoration
@@ -61,4 +61,4 @@
 			border-color: var(--wp--custom--button--border--color);
 		}
 	}
-}
+}

+ 0 - 1
blockbase/sass/blocks/_paragraph.scss

@@ -8,7 +8,6 @@ p {
 
 	&.has-drop-cap:not(:focus):first-letter {
 		font-size: var(--wp--custom--paragraph--dropcap--typography--font-size);
-		font-family: var(--wp--custom--paragraph--dropcap--typography--font-family);
 		font-weight: var(--wp--custom--paragraph--dropcap--typography--font-weight);
 		margin: var(--wp--custom--paragraph--dropcap--margin);
 	}

+ 0 - 2
blockbase/sass/blocks/_pullquote.scss

@@ -15,7 +15,6 @@
 		cite {
 			display: block;
 			font-size: var(--wp--custom--pullquote--citation--typography--font-size);
-			font-family: var(--wp--custom--pullquote--citation--typography--font-family);
 			font-style: var(--wp--custom--pullquote--citation--typography--font-style);
 			font-weight: var(--wp--custom--pullquote--citation--typography--font-weight);
 			margin-top: var(--wp--custom--pullquote--citation--spacing--margin--top);
@@ -27,4 +26,3 @@
 		color: var(--wp--custom--color--background);
 	}
 }
-

+ 1 - 1
blockbase/sass/elements/_forms.scss

@@ -20,7 +20,7 @@ textarea {
 	border-radius: var(--wp--custom--form--border--radius);
 	box-shadow: var(--wp--custom--form--color--box-shadow);
 	color: var(--wp--custom--form--color--text);
-	font-family: var(--wp--custom--body--typography--font-family);
+	font-family: inherit;
 	padding: var(--wp--custom--form--padding);
 
 	&:focus {

+ 9 - 13
blockbase/theme.json

@@ -98,7 +98,6 @@
 					}
 				},
 				"typography": {
-					"fontFamily": "var(--wp--custom--body--typography--font-family)",
 					"fontSize": "var(--wp--preset--font-size--normal)",
 					"fontWeight": "normal",
 					"lineHeight": 2
@@ -180,13 +179,11 @@
 			},
 			"body": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--system-font)",
 					"lineHeight": 1.6
 				}
 			},
 			"heading": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--system-font)",
 					"fontWeight": 400,
 					"lineHeight": 1.125
 				}
@@ -217,7 +214,6 @@
 				"dropcap": {
 					"margin": ".1em .1em 0 0",
 					"typography": {
-						"fontFamily": "var(--wp--custom--body--typography--font-family)",
 						"fontSize": "110px",
 						"fontWeight": "400"
 					}
@@ -352,7 +348,7 @@
 					"text": "var(--wp--custom--button--color--text)"
 				},
 				"typography": {
-					"fontFamily": "var(--wp--custom--button--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--system-font)",
 					"fontSize": "var(--wp--custom--button--typography--font-size)",
 					"fontWeight": "var(--wp--custom--button--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--button--typography--line-height)"
@@ -381,7 +377,7 @@
 			},
 			"core/post-title": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--system-font)",
 					"fontSize": "var(--wp--preset--font-size--huge)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)"
 				}
@@ -453,7 +449,7 @@
 		"elements": {
 			"h1": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--system-font)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "48px"
@@ -461,7 +457,7 @@
 			},
 			"h2": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--system-font)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "32px"
@@ -469,7 +465,7 @@
 			},
 			"h3": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--system-font)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "var(--wp--preset--font-size--huge)"
@@ -477,7 +473,7 @@
 			},
 			"h4": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--system-font)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "var(--wp--preset--font-size--large)"
@@ -485,7 +481,7 @@
 			},
 			"h5": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--system-font)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "var(--wp--preset--font-size--normal)"
@@ -493,7 +489,7 @@
 			},
 			"h6": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--system-font)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "var(--wp--preset--font-size--small)"
@@ -507,7 +503,7 @@
 		},
 		"typography": {
 			"lineHeight": "var(--wp--custom--body--typography--line-height)",
-			"fontFamily": "var(--wp--custom--body--typography--font-family)",
+			"fontFamily": "var(--wp--preset--font-family--system-font)",
 			"fontSize": "var(--wp--preset--font-size--normal)"
 		}
 	}

+ 18 - 16
mayland-blocks/child-theme.json

@@ -78,20 +78,6 @@
 				"background": "var(--wp--preset--color--background)",
 				"selection": "var(--wp--preset--color--selection)"
 			},
-			"fontsToLoadFromGoogle": [
-				"family=Poppins:ital,wght@0,400;0,600;1,400"
-			],
-			"body": {
-				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--poppins)"
-				}
-			},
-			"heading": {
-				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--poppins)",
-					"fontWeight": 600
-				}
-			},
 			"margin": {
 				"horizontal": "32px"
 			},
@@ -115,7 +101,8 @@
 				{
 					"fontFamily": "\"Poppins\", sans-serif",
 					"slug": "poppins",
-					"name": "Poppins"
+					"name": "Poppins",
+					"google": "family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900"
 				},
 				{
 					"fontFamily": "-apple-system,BlinkMacSystemFont,\"Segoe UI\",Roboto,Oxygen-Sans,Ubuntu,Cantarell,\"Helvetica Neue\",sans-serif",
@@ -165,6 +152,11 @@
 	},
 	"styles": {
 		"blocks": {
+			"core/button": {
+				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--poppins)"
+				}
+			},
 			"core/navigation": {
 				"typography": {
 					"fontSize": "var(--wp--preset--font-size--small)"
@@ -173,7 +165,7 @@
 			"core/post-date": {
 				"color": {
 					"link": null,
-					"text": null 
+					"text": null
 				},
 				"typography": {
 					"fontSize": "var(--wp--preset--font-size--small)"
@@ -181,6 +173,7 @@
 			},
 			"core/post-title": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontSize": "var(--wp--preset--font-size--huge)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)"
 				}
@@ -198,31 +191,37 @@
 		"elements": {
 			"h1": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontSize": "41.47px"
 				}
 			},
 			"h2": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontSize": "var(--wp--preset--font-size--huge)"
 				}
 			},
 			"h3": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontSize": "var(--wp--preset--font-size--large)"
 				}
 			},
 			"h4": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontSize": "24px"
 				}
 			},
 			"h5": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontSize": "var(--wp--preset--font-size--normal)"
 				}
 			},
 			"h6": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontSize": "var(--wp--preset--font-size--small)"
 				}
 			},
@@ -231,6 +230,9 @@
 					"text": "var(--wp--custom--color--foreground)"
 				}
 			}
+		},
+		"typography": {
+			"fontFamily": "var(--wp--preset--font-family--poppins)"
 		}
 	}
 }

+ 12 - 18
mayland-blocks/theme.json

@@ -106,7 +106,6 @@
 					}
 				},
 				"typography": {
-					"fontFamily": "var(--wp--custom--body--typography--font-family)",
 					"fontSize": "var(--wp--preset--font-size--small)",
 					"fontWeight": 600,
 					"lineHeight": 2
@@ -188,14 +187,12 @@
 			},
 			"body": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"lineHeight": 1.6
 				}
 			},
 			"heading": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--poppins)",
-					"fontWeight": 600,
+					"fontWeight": 400,
 					"lineHeight": 1.125
 				}
 			},
@@ -225,7 +222,6 @@
 				"dropcap": {
 					"margin": ".1em .1em 0 0",
 					"typography": {
-						"fontFamily": "var(--wp--custom--body--typography--font-family)",
 						"fontSize": "110px",
 						"fontWeight": "400"
 					}
@@ -295,9 +291,6 @@
 					"margin": "var(--wp--custom--margin--vertical) auto"
 				}
 			},
-			"fontsToLoadFromGoogle": [
-				"family=Poppins:ital,wght@0,400;0,600;1,400"
-			],
 			"width": {
 				"default": "750px",
 				"wide": "1022px"
@@ -324,7 +317,8 @@
 				{
 					"fontFamily": "\"Poppins\", sans-serif",
 					"slug": "poppins",
-					"name": "Poppins"
+					"name": "Poppins",
+					"google": "family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900"
 				},
 				{
 					"fontFamily": "-apple-system,BlinkMacSystemFont,\"Segoe UI\",Roboto,Oxygen-Sans,Ubuntu,Cantarell,\"Helvetica Neue\",sans-serif",
@@ -383,7 +377,7 @@
 					"text": "var(--wp--custom--button--color--text)"
 				},
 				"typography": {
-					"fontFamily": "var(--wp--custom--button--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontSize": "var(--wp--custom--button--typography--font-size)",
 					"fontWeight": "var(--wp--custom--button--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--button--typography--line-height)"
@@ -412,7 +406,7 @@
 			},
 			"core/post-title": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontSize": "var(--wp--preset--font-size--huge)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)"
 				}
@@ -484,7 +478,7 @@
 		"elements": {
 			"h1": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "41.47px"
@@ -492,7 +486,7 @@
 			},
 			"h2": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "var(--wp--preset--font-size--huge)"
@@ -500,7 +494,7 @@
 			},
 			"h3": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "var(--wp--preset--font-size--large)"
@@ -508,7 +502,7 @@
 			},
 			"h4": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "24px"
@@ -516,7 +510,7 @@
 			},
 			"h5": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "var(--wp--preset--font-size--normal)"
@@ -524,7 +518,7 @@
 			},
 			"h6": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--poppins)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "var(--wp--preset--font-size--small)"
@@ -538,7 +532,7 @@
 		},
 		"typography": {
 			"lineHeight": "var(--wp--custom--body--typography--line-height)",
-			"fontFamily": "var(--wp--custom--body--typography--font-family)",
+			"fontFamily": "var(--wp--preset--font-family--poppins)",
 			"fontSize": "var(--wp--preset--font-size--normal)"
 		}
 	}

+ 11 - 6
quadrat/child-theme.json

@@ -146,9 +146,6 @@
 					}
 				}
 			],
-			"fontsToLoadFromGoogle": [
-				"family=DM+Sans:ital,wght@0,400;0,500;0,700;1,400;1,500;1,700"
-			],
 			"form": {
 				"border": {
 					"color": "var(--wp--custom--color--foreground)"
@@ -157,13 +154,11 @@
 			},
 			"body": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"lineHeight": 1.7
 				}
 			},
 			"heading": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontWeight": "500"
 				}
 			},
@@ -231,7 +226,8 @@
 				{
 					"fontFamily": "\"DM Sans\", sans-serif",
 					"slug": "dm-sans",
-					"name": "DM Sans"
+					"name": "DM Sans",
+					"google": "family=DM+Sans:ital,wght@0,400;0,500;0,700;1,400;1,500;1,700"
 				}
 			],
 			"fontSizes": [
@@ -276,6 +272,7 @@
 					"text": "var(--wp--custom--button--color--text)"
 				},
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontSize": "var(--wp--custom--button--typography--font-size)",
 					"fontWeight": "var(--wp--custom--button--typography--font-weight)"
 				}
@@ -306,6 +303,7 @@
 			},
 			"core/post-title": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontSize": "min(max(48px, 7vw), 80px)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": 1.2
@@ -383,36 +381,42 @@
 		"elements": {
 			"h1": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontSize": "min(max(48px, 7vw), 80px)",
 					"lineHeight": 1.2
 				}
 			},
 			"h2": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontSize": "min(max(36px, 6vw), 65px)",
 					"lineHeight": 1.2
 				}
 			},
 			"h3": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontSize": "min(max(28px, 5vw), 38px)",
 					"lineHeight": 1.2
 				}
 			},
 			"h4": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontSize": "20px",
 					"lineHeight": 1.4
 				}
 			},
 			"h5": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontSize": "18px",
 					"lineHeight": 1.4
 				}
 			},
 			"h6": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontSize": "16px",
 					"lineHeight": 1.4
 				}
@@ -424,6 +428,7 @@
 			}
 		},
 		"typography": {
+			"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 			"fontWeight": "400"
 		},
 		"core/site-logo": {

+ 11 - 17
quadrat/theme.json

@@ -96,7 +96,6 @@
 					}
 				},
 				"typography": {
-					"fontFamily": "var(--wp--custom--body--typography--font-family)",
 					"fontSize": "20px",
 					"fontWeight": "700",
 					"lineHeight": 2
@@ -226,13 +225,11 @@
 			},
 			"body": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"lineHeight": 1.7
 				}
 			},
 			"heading": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontWeight": "500",
 					"lineHeight": 1.125
 				}
@@ -263,7 +260,6 @@
 				"dropcap": {
 					"margin": "0 .2em .2em 0",
 					"typography": {
-						"fontFamily": "var(--wp--custom--body--typography--font-family)",
 						"fontSize": "var(--wp--preset--font-size--huge)",
 						"fontWeight": "400"
 					}
@@ -334,9 +330,6 @@
 					"margin": "var(--wp--custom--margin--vertical) auto"
 				}
 			},
-			"fontsToLoadFromGoogle": [
-				"family=DM+Sans:ital,wght@0,400;0,500;0,700;1,400;1,500;1,700"
-			],
 			"line-height": {
 				"body": 1.7
 			}
@@ -362,7 +355,8 @@
 				{
 					"fontFamily": "\"DM Sans\", sans-serif",
 					"slug": "dm-sans",
-					"name": "DM Sans"
+					"name": "DM Sans",
+					"google": "family=DM+Sans:ital,wght@0,400;0,500;0,700;1,400;1,500;1,700"
 				}
 			],
 			"fontSizes": [
@@ -410,7 +404,7 @@
 					"text": "var(--wp--custom--button--color--text)"
 				},
 				"typography": {
-					"fontFamily": "var(--wp--custom--button--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontSize": "var(--wp--custom--button--typography--font-size)",
 					"fontWeight": "var(--wp--custom--button--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--button--typography--line-height)"
@@ -447,7 +441,7 @@
 			},
 			"core/post-title": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontSize": "min(max(48px, 7vw), 80px)",
 					"lineHeight": 1.2,
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)"
@@ -560,7 +554,7 @@
 		"elements": {
 			"h1": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": 1.2,
 					"fontSize": "min(max(48px, 7vw), 80px)"
@@ -568,7 +562,7 @@
 			},
 			"h2": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": 1.2,
 					"fontSize": "min(max(36px, 6vw), 65px)"
@@ -576,7 +570,7 @@
 			},
 			"h3": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": 1.2,
 					"fontSize": "min(max(28px, 5vw), 38px)"
@@ -584,7 +578,7 @@
 			},
 			"h4": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": 1.4,
 					"fontSize": "20px"
@@ -592,7 +586,7 @@
 			},
 			"h5": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": 1.4,
 					"fontSize": "18px"
@@ -600,7 +594,7 @@
 			},
 			"h6": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": 1.4,
 					"fontSize": "16px"
@@ -614,7 +608,7 @@
 		},
 		"typography": {
 			"lineHeight": "var(--wp--custom--body--typography--line-height)",
-			"fontFamily": "var(--wp--custom--body--typography--font-family)",
+			"fontFamily": "var(--wp--preset--font-family--dm-sans)",
 			"fontSize": "var(--wp--preset--font-size--normal)",
 			"fontWeight": "400"
 		},

+ 50 - 20
seedlet-blocks/child-theme.json

@@ -82,11 +82,6 @@
 			]
 		},
 		"custom": {
-			"body": {
-				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--fira-sans)"
-				}
-			},
 			"button": {
 				"border": {
 					"color": "var(--wp--custom--color--primary)"
@@ -100,15 +95,6 @@
 					}
 				}
 			},
-			"fontsToLoadFromGoogle": [
-				"family=Fira+Sans:ital,wght@0,400;0,500;1,400",
-				"family=Playfair+Display:ital,wght@0,400;0,700;1,400"
-			],
-			"heading": {
-				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--playfair-display)"
-				}	
-			},
 			"latest-posts": {
 				"meta": {
 					"color": {
@@ -122,9 +108,6 @@
 			},
 			"pullquote": {
 				"citation": {
-					"typography": {
-						"fontFamily": "var(--wp--custom--body--typography--font-family)"
-					},
 					"spacing": {
 						"margin": {
 							"top": "20px"
@@ -147,12 +130,14 @@
 				{
 					"fontFamily": "'Fira Sans', Helvetica, Arial, sans-serif",
 					"slug": "fira-sans",
-					"name": "Fira Sans"
+					"name": "Fira Sans",
+					"google": "family=Fira+Sans:ital,wght@0,100..900;1,100..900"
 				},
 				{
 					"fontFamily": "'Playfair Display', Georgia, Times, serif",
 					"slug": "playfair-display",
-					"name": "Playfair Display"
+					"name": "Playfair Display",
+					"google": "family=Playfair+Display:ital,wght@0,400..900;1,400..900"
 				}
 			],
 			"fontSizes": [
@@ -190,6 +175,16 @@
 	},
 	"styles": {
 		"blocks": {
+			"core/button": {
+				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--fira-sans)"
+				}
+			},
+			"core/post-title": {
+				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)"
+				}
+			},
 			"core/pullquote": {
 				"border": {
 					"style": "none"
@@ -206,7 +201,7 @@
 					"fontSize": "32px",
 					"fontStyle": "italic",
 					"lineHeight": "1.3",
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)"
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)"
 				}
 			},
 			"core/separator": {
@@ -219,6 +214,41 @@
 					"link": "var(--wp--custom--color--primary)"
 				}
 			}
+		},
+		"elements": {
+			"h1": {
+				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)"
+				}
+			},
+			"h2": {
+				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)"
+				}
+			},
+			"h3": {
+				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)"
+				}
+			},
+			"h4": {
+				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)"
+				}
+			},
+			"h5": {
+				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)"
+				}
+			},
+			"h6": {
+				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)"
+				}
+			}
+		},
+		"typography": {
+			"fontFamily": "var(--wp--preset--font-family--fira-sans)"
 		}
 	}
 }

+ 16 - 22
seedlet-blocks/theme.json

@@ -139,7 +139,6 @@
 					}
 				},
 				"typography": {
-					"fontFamily": "var(--wp--custom--body--typography--font-family)",
 					"fontSize": "var(--wp--preset--font-size--normal)",
 					"fontWeight": "normal",
 					"lineHeight": 2
@@ -221,13 +220,11 @@
 			},
 			"body": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--fira-sans)",
 					"lineHeight": 1.6
 				}
 			},
 			"heading": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--playfair-display)",
 					"fontWeight": 400,
 					"lineHeight": 1.125
 				}
@@ -258,7 +255,6 @@
 				"dropcap": {
 					"margin": ".1em .1em 0 0",
 					"typography": {
-						"fontFamily": "var(--wp--custom--body--typography--font-family)",
 						"fontSize": "110px",
 						"fontWeight": "400"
 					}
@@ -285,7 +281,7 @@
 				"citation": {
 					"typography": {
 						"fontSize": "var(--wp--preset--font-size--tiny)",
-						"fontFamily": "var(--wp--custom--body--typography--font-family)",
+						"fontFamily": "inherit",
 						"fontStyle": "italic"
 					},
 					"spacing": {
@@ -327,11 +323,7 @@
 					"textAlign": "center",
 					"margin": "var(--wp--custom--margin--vertical) auto"
 				}
-			},
-			"fontsToLoadFromGoogle": [
-				"family=Fira+Sans:ital,wght@0,400;0,500;1,400",
-				"family=Playfair+Display:ital,wght@0,400;0,700;1,400"
-			]
+			}
 		},
 		"layout": {
 			"contentSize": "620px",
@@ -354,12 +346,14 @@
 				{
 					"fontFamily": "'Fira Sans', Helvetica, Arial, sans-serif",
 					"slug": "fira-sans",
-					"name": "Fira Sans"
+					"name": "Fira Sans",
+					"google": "family=Fira+Sans:ital,wght@0,100..900;1,100..900"
 				},
 				{
 					"fontFamily": "'Playfair Display', Georgia, Times, serif",
 					"slug": "playfair-display",
-					"name": "Playfair Display"
+					"name": "Playfair Display",
+					"google": "family=Playfair+Display:ital,wght@0,400..900;1,400..900"
 				}
 			],
 			"fontSizes": [
@@ -412,7 +406,7 @@
 					"text": "var(--wp--custom--button--color--text)"
 				},
 				"typography": {
-					"fontFamily": "var(--wp--custom--button--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--fira-sans)",
 					"fontSize": "var(--wp--custom--button--typography--font-size)",
 					"fontWeight": "var(--wp--custom--button--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--button--typography--line-height)"
@@ -441,7 +435,7 @@
 			},
 			"core/post-title": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)",
 					"fontSize": "var(--wp--preset--font-size--huge)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)"
 				}
@@ -464,7 +458,7 @@
 					"fontStyle": "italic",
 					"fontSize": "32px",
 					"lineHeight": "1.3",
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)"
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)"
 				},
 				"spacing": {
 					"padding": {
@@ -518,7 +512,7 @@
 		"elements": {
 			"h1": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "48px"
@@ -526,7 +520,7 @@
 			},
 			"h2": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "32px"
@@ -534,7 +528,7 @@
 			},
 			"h3": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "var(--wp--preset--font-size--huge)"
@@ -542,7 +536,7 @@
 			},
 			"h4": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "var(--wp--preset--font-size--large)"
@@ -550,7 +544,7 @@
 			},
 			"h5": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "var(--wp--preset--font-size--normal)"
@@ -558,7 +552,7 @@
 			},
 			"h6": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--playfair-display)",
 					"fontWeight": "var(--wp--custom--heading--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)",
 					"fontSize": "var(--wp--preset--font-size--small)"
@@ -572,7 +566,7 @@
 		},
 		"typography": {
 			"lineHeight": "var(--wp--custom--body--typography--line-height)",
-			"fontFamily": "var(--wp--custom--body--typography--font-family)",
+			"fontFamily": "var(--wp--preset--font-family--fira-sans)",
 			"fontSize": "var(--wp--preset--font-size--normal)"
 		}
 	}

+ 15 - 6
skatepark/child-theme.json

@@ -80,7 +80,6 @@
 			},
 			"body": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"lineHeight": 1.6
 				}
 			},
@@ -146,12 +145,8 @@
 					"fontSize": "var(--wp--preset--font-size--small)"
 				}
 			},
-			"fontsToLoadFromGoogle": [
-				"family=Red+Hat+Display:ital,wght@0,400;0,500;0,700;0,900;1,400;1,500;1,700;1,900"
-			],
 			"heading": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontWeight": "700"
 				}
 			},
@@ -178,7 +173,8 @@
 				{
 					"fontFamily": "\"Red Hat Display\", sans-serif",
 					"slug": "red-hat-display",
-					"name": "Red Hat Display"
+					"name": "Red Hat Display",
+					"google": "family=Red+Hat+Display:ital,wght@0,400;0,500;0,700;0,900;1,400;1,500;1,700;1,900"
 				}
 			],
 			"fontSizes": [
@@ -223,11 +219,17 @@
 					"text": "var(--wp--custom--button--color--text)"
 				},
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontSize": "var(--wp--custom--button--typography--font-size)",
 					"fontWeight": "var(--wp--custom--button--typography--font-weight)",
 					"letterSpacing": "0.1em"
 				}
 			},
+			"core/post-title": {
+				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)"
+				}
+			},
 			"core/site-title": {
 				"typography": {
 					"fontSize": "var(--wp--preset--font-size--medium)",
@@ -245,6 +247,7 @@
 		"elements": {
 			"h1": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontSize": "min(max(48px, 7vw), 72px)",
 					"fontWeight": "700",
 					"lineHeight": 1.2
@@ -252,6 +255,7 @@
 			},
 			"h2": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontSize": "min(max(36px, 5vw), 64px)",
 					"fontWeight": "900",
 					"lineHeight": 1.2
@@ -259,6 +263,7 @@
 			},
 			"h3": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontSize": "min(max(30px, 5vw), 48px)",
 					"fontWeight": "900",
 					"lineHeight": 1.3
@@ -266,6 +271,7 @@
 			},
 			"h4": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontSize": "var(--wp--preset--font-size--small)",
 					"fontWeight": "900",
 					"letterSpacing": "0.1em",
@@ -275,6 +281,7 @@
 			},
 			"h5": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontSize": "var(--wp--preset--font-size--small)",
 					"fontWeight": "900",
 					"letterSpacing": "0.1em",
@@ -284,6 +291,7 @@
 			},
 			"h6": {
 				"typography": {
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontSize": "var(--wp--preset--font-size--tiny)",
 					"fontWeight": "900",
 					"letterSpacing": "0.1em",
@@ -293,6 +301,7 @@
 			}
 		},
 		"typography": {
+			"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 			"fontWeight": "400"
 		}
 	}

+ 11 - 17
skatepark/theme.json

@@ -133,7 +133,6 @@
 					}
 				},
 				"typography": {
-					"fontFamily": "var(--wp--custom--body--typography--font-family)",
 					"fontSize": "16px",
 					"fontWeight": "700",
 					"lineHeight": 2
@@ -222,13 +221,11 @@
 			},
 			"body": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"lineHeight": 1.6
 				}
 			},
 			"heading": {
 				"typography": {
-					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontWeight": "700",
 					"lineHeight": 1.125
 				}
@@ -259,7 +256,6 @@
 				"dropcap": {
 					"margin": ".1em .1em 0 0",
 					"typography": {
-						"fontFamily": "var(--wp--custom--body--typography--font-family)",
 						"fontSize": "110px",
 						"fontWeight": "400"
 					}
@@ -329,9 +325,6 @@
 					"margin": "var(--wp--custom--margin--vertical) auto"
 				}
 			},
-			"fontsToLoadFromGoogle": [
-				"family=Red+Hat+Display:ital,wght@0,400;0,500;0,700;0,900;1,400;1,500;1,700;1,900"
-			],
 			"line-height": {
 				"body": 1.6
 			}
@@ -357,7 +350,8 @@
 				{
 					"fontFamily": "\"Red Hat Display\", sans-serif",
 					"slug": "red-hat-display",
-					"name": "Red Hat Display"
+					"name": "Red Hat Display",
+					"google": "family=Red+Hat+Display:ital,wght@0,400;0,500;0,700;0,900;1,400;1,500;1,700;1,900"
 				}
 			],
 			"fontSizes": [
@@ -405,7 +399,7 @@
 					"text": "var(--wp--custom--button--color--text)"
 				},
 				"typography": {
-					"fontFamily": "var(--wp--custom--button--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontSize": "var(--wp--custom--button--typography--font-size)",
 					"fontWeight": "var(--wp--custom--button--typography--font-weight)",
 					"lineHeight": "var(--wp--custom--button--typography--line-height)",
@@ -436,7 +430,7 @@
 			},
 			"core/post-title": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontSize": "var(--wp--preset--font-size--huge)",
 					"lineHeight": "var(--wp--custom--heading--typography--line-height)"
 				}
@@ -510,7 +504,7 @@
 		"elements": {
 			"h1": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontWeight": "700",
 					"lineHeight": 1.2,
 					"fontSize": "min(max(48px, 7vw), 72px)"
@@ -518,7 +512,7 @@
 			},
 			"h2": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontWeight": "900",
 					"lineHeight": 1.2,
 					"fontSize": "min(max(36px, 5vw), 64px)"
@@ -526,7 +520,7 @@
 			},
 			"h3": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontWeight": "900",
 					"lineHeight": 1.3,
 					"fontSize": "min(max(30px, 5vw), 48px)"
@@ -534,7 +528,7 @@
 			},
 			"h4": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontWeight": "900",
 					"lineHeight": 1.3,
 					"fontSize": "var(--wp--preset--font-size--small)",
@@ -544,7 +538,7 @@
 			},
 			"h5": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontWeight": "900",
 					"lineHeight": 1.3,
 					"fontSize": "var(--wp--preset--font-size--small)",
@@ -554,7 +548,7 @@
 			},
 			"h6": {
 				"typography": {
-					"fontFamily": "var(--wp--custom--heading--typography--font-family)",
+					"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 					"fontWeight": "900",
 					"lineHeight": 1.3,
 					"fontSize": "var(--wp--preset--font-size--tiny)",
@@ -570,7 +564,7 @@
 		},
 		"typography": {
 			"lineHeight": "var(--wp--custom--body--typography--line-height)",
-			"fontFamily": "var(--wp--custom--body--typography--font-family)",
+			"fontFamily": "var(--wp--preset--font-family--red-hat-display)",
 			"fontSize": "var(--wp--preset--font-size--normal)",
 			"fontWeight": "400"
 		}