From c4d84b1ffdf2073b0d37894d5898307a832b2249 Mon Sep 17 00:00:00 2001 From: Jakub Piasecki Date: Wed, 17 Jun 2026 06:39:30 -0700 Subject: [PATCH] Fix Fabric reusing nodes with a stale font scale (#57246) Summary: Fixes https://github.com/react/react-native/issues/52895 The original solution to this issue approached this by comparing the font scale used to lay out respective root nodes and re-cloning measurable nodes in the entire tree when it was different. This didn't work when a node within the tree was cloned from a node with an obsolete font scale stored (with root having the correct one). The new node would use the obsolete value in that pass. This PR changes this approach - instead of comparing font scale in `SurfaceHandler::constraintLayout` (only when it changes), it moves the comparison to happen as part of `configureYogaTree`, similarly to `pointScaleFactor`. This way, nodes with an obsolete value stored get re-cloned using the correct one on each commit instead of only on the first one. ## Changelog: [GENERAL][FIXED] - Fixed Fabric reusing nodes with a stale font scale Test Plan: Issue reproducer ||Before|After| |-|-|-| |Android|