RN 0.76 Regression - RCTWindowFrameDidChangeNotification is not called when dark mode is toggled #47234
Labels
Impact: Regression
Describes a behavior that used to work on a prior release, but stopped working recently.
Resolution: Fixed
A PR that fixes this issue has been merged.
Description
I’ve noticed another discrepancy between RN 0.75.x and RN 0.76. With the new bare starter, my iOS native notification listener is no longer called when the user changes the color scheme. Previously, I was using the
RCTWindowFrameDidChangeNotification
notification to receive information about screen and native color scheme changes.RN 0.75 repo - https://github.com/jpudysz/rn-0.75-jsi-reproducer/tree/feature/repro2
Steps to reproduce
Pods/Development Pods/Unistyles/ios/NativePlatformListener+ios.swift
For RN 0.75 - the event is reported
For RN 0.76 - the breakpoint is not hit
React Native Version
0.76.0
Affected Platforms
Runtime - iOS
Output of
npx react-native info
Stacktrace or Logs
Reproducer
https://github.com/jpudysz/rn-0.76-jsi-reproducer/tree/feature/repro2
Screenshots and Videos
RN 0.75:
Unistyles theme event was applied.
Screen.Recording.2024-10-28.at.06.52.01.mov
RN 0.76:
Unistyles theme is not applied as event was not called.
Screen.Recording.2024-10-28.at.06.55.55.mov
The text was updated successfully, but these errors were encountered: