From 61aeeea541587cee47e55283e9c935c406a4b24d Mon Sep 17 00:00:00 2001 From: Abhishek B R Date: Sun, 18 Oct 2026 12:12:02 +0530 Subject: [PATCH 1/2] fix(react-email): keep a longhand padding of 0 on Button parsePadding returned undefined for a longhand set to the number 0 because it used a truthiness check before converting to px. Button spreads the original style first and then the parsed longhands, so an undefined paddingTop is omitted and the padding shorthand wins: with { padding: '12px 20px', paddingTop: 0 } the button rendered 12px of top padding in every client, while the Outlook spacer was computed as if it were 0. Only skip undefined and empty strings, so 0 is passed through. --- .changeset/button-zero-padding-longhand.md | 5 +++++ .../src/components/button/button.spec.tsx | 11 +++++++++++ .../src/components/button/utils/parse-padding.ts | 13 +++++++++---- .../src/components/button/utils/utils.spec.ts | 10 ++++++++++ 4 files changed, 35 insertions(+), 4 deletions(-) create mode 100644 .changeset/button-zero-padding-longhand.md diff --git a/.changeset/button-zero-padding-longhand.md b/.changeset/button-zero-padding-longhand.md new file mode 100644 index 0000000000..5e72433c01 --- /dev/null +++ b/.changeset/button-zero-padding-longhand.md @@ -0,0 +1,5 @@ +--- +"react-email": patch +--- + +`