Commit 5098207a4b7 for woocommerce

commit 5098207a4b763ac939f7cc5eb28be6118f3c0bec
Author: Ann <annchichi@users.noreply.github.com>
Date:   Mon Jul 20 20:32:08 2026 +0800

    [Email Editor] Fix global typography rendering (#66620)

    * Fix missing global font weight in email renderer

    * Add changelog entry for email font weight fix

    * Update email font weight documentation

    * Render additional global email typography styles

    * Rename global email typography changelog

    * Fix email theme documentation wording

diff --git a/packages/php/email-editor/changelog/fix-global-email-typography-rendering b/packages/php/email-editor/changelog/fix-global-email-typography-rendering
new file mode 100644
index 00000000000..51edfcb7a93
--- /dev/null
+++ b/packages/php/email-editor/changelog/fix-global-email-typography-rendering
@@ -0,0 +1,4 @@
+Significance: patch
+Type: fix
+
+Ensure emails render global font weight, style, and letter spacing.
diff --git a/packages/php/email-editor/src/Engine/Renderer/class-renderer.php b/packages/php/email-editor/src/Engine/Renderer/class-renderer.php
index 0cc03956e86..816c0b16927 100644
--- a/packages/php/email-editor/src/Engine/Renderer/class-renderer.php
+++ b/packages/php/email-editor/src/Engine/Renderer/class-renderer.php
@@ -139,6 +139,9 @@ class Renderer {
 					'padding-top'      => $email_styles['spacing']['padding']['top'] ?? '0px',
 					'padding-bottom'   => $email_styles['spacing']['padding']['bottom'] ?? '0px',
 					'font-family'      => $email_styles['typography']['fontFamily'] ?? 'inherit',
+					'font-weight'      => $email_styles['typography']['fontWeight'] ?? 'inherit',
+					'font-style'       => $email_styles['typography']['fontStyle'] ?? 'inherit',
+					'letter-spacing'   => $email_styles['typography']['letterSpacing'] ?? 'normal',
 					'line-height'      => $email_styles['typography']['lineHeight'] ?? '1.5',
 					'font-size'        => $email_styles['typography']['fontSize'] ?? 'inherit',
 					'direction'        => $rendering_context->get_text_direction(),
diff --git a/packages/php/email-editor/src/Engine/theme.md b/packages/php/email-editor/src/Engine/theme.md
index fb218d3b5dd..7d289746698 100644
--- a/packages/php/email-editor/src/Engine/theme.md
+++ b/packages/php/email-editor/src/Engine/theme.md
@@ -11,7 +11,7 @@ In this file we want to document settings and styles that are specific to the em
 - **layout**: We set content width to 660px, because it's the most common width for emails. This is meant as a default value.
 - **spacing**: We allow only px units, because they are the most reliable in email clients. We may add the support for other units later with some sort of conversion to px. We also disable margins because they are not supported in our renderer (margin collapsing might be tricky).
 - **border**: We want to allow all types of borders and border styles.
-- **typography**: We disabled fontWeight and dropCap appearance settings, because they are not supported in our renderer. We may add the support later. We also define a set of basic font families that are safe to use with emails. The list was copied from the battle tested legacy editor.
+- **typography**: We enable fontWeight, fontStyle, and letterSpacing because they are supported by our renderer. We disable the dropCap appearance setting because it is not supported. We also define a set of basic font families that are safe to use with emails. The list was copied from the battle-tested legacy editor.

 ## Styles

diff --git a/packages/php/email-editor/tests/integration/Engine/Renderer/Renderer_Test.php b/packages/php/email-editor/tests/integration/Engine/Renderer/Renderer_Test.php
index 0be742522c8..39c6dcfb2a7 100644
--- a/packages/php/email-editor/tests/integration/Engine/Renderer/Renderer_Test.php
+++ b/packages/php/email-editor/tests/integration/Engine/Renderer/Renderer_Test.php
@@ -46,7 +46,10 @@ class Renderer_Test extends \Email_Editor_Integration_Test_Case {
 				),
 			),
 			'typography' => array(
-				'fontFamily' => 'Test Font Family',
+				'fontFamily'    => 'Test Font Family',
+				'fontWeight'    => '300',
+				'fontStyle'     => 'italic',
+				'letterSpacing' => '-0.1px',
 			),
 			'color'      => array(
 				'background' => '#123456',
@@ -267,6 +270,9 @@ class Renderer_Test extends \Email_Editor_Integration_Test_Case {
 		$style = $this->getStylesValueForTag( $rendered['html'], array( 'tag_name' => 'body' ) );
 		$this->assertIsString( $style );
 		$this->assertStringContainsString( 'background-color: #123456', $style );
+		$this->assertStringContainsString( 'font-weight: 300;', $style );
+		$this->assertStringContainsString( 'font-style: italic;', $style );
+		$this->assertStringContainsString( 'letter-spacing: -.1px;', $style );

 		// Verify layout element styles.
 		$doc = new \DOMDocument();
@@ -281,6 +287,9 @@ class Renderer_Test extends \Email_Editor_Integration_Test_Case {
 		$style = $wrapper->getAttribute( 'style' );
 		$this->assertStringContainsString( 'background-color: #123456', $style );
 		$this->assertStringContainsString( 'font-family: Test Font Family;', $style );
+		$this->assertStringContainsString( 'font-weight: 300;', $style );
+		$this->assertStringContainsString( 'font-style: italic;', $style );
+		$this->assertStringContainsString( 'letter-spacing: -.1px;', $style );
 		$this->assertStringContainsString( 'padding-top: 3px;', $style );
 		$this->assertStringContainsString( 'padding-bottom: 4px;', $style );
 		// Horizontal padding is now distributed to individual block wrappers via Spacing_Preprocessor.