diff --git a/change/react-native-windows-93b836bd-dd5f-4524-a53b-cd17b7f9c334.json b/change/react-native-windows-93b836bd-dd5f-4524-a53b-cd17b7f9c334.json new file mode 100644 index 00000000000..d75e82da5f5 --- /dev/null +++ b/change/react-native-windows-93b836bd-dd5f-4524-a53b-cd17b7f9c334.json @@ -0,0 +1,7 @@ +{ + "type": "patch", + "comment": "Fixes misalignment with TextInput on different display scales", + "packageName": "react-native-windows", + "email": "dlucas@seabird.com", + "dependentChangeType": "patch" +} diff --git a/vnext/Microsoft.ReactNative/Fabric/Composition/TextInput/WindowsTextInputComponentView.cpp b/vnext/Microsoft.ReactNative/Fabric/Composition/TextInput/WindowsTextInputComponentView.cpp index d78ab76afab..91ae1551daf 100644 --- a/vnext/Microsoft.ReactNative/Fabric/Composition/TextInput/WindowsTextInputComponentView.cpp +++ b/vnext/Microsoft.ReactNative/Fabric/Composition/TextInput/WindowsTextInputComponentView.cpp @@ -1329,7 +1329,7 @@ void WindowsTextInputComponentView::updateLayoutMetrics( facebook::react::LayoutMetrics const &oldLayoutMetrics) noexcept { // Set Position & Size Properties - if ((layoutMetrics.pointScaleFactor != m_layoutMetrics.pointScaleFactor)) { + if (m_textServices && layoutMetrics.pointScaleFactor > 0) { LRESULT res; winrt::check_hresult(m_textServices->TxSendMessage( (WM_USER + 328), // EM_SETDPI