Skip to content

Commit 2be9da2

Browse files
authored
fix(fabric): Add typingAttributes to RCTUITextField to fix crash (#2461)
## Summary: `typingAttributes` was added in a recent React Native release, but not brought to `RCTUITextField` (where we have to port some iOS only props to macOS). This caused an `unrecognized selector` style crash when trying to set `typingAttributes`. ## Test Plan: Booting RNTester-macOS with the new architecture no longer crashes,
1 parent 28bab0d commit 2be9da2

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

packages/react-native/Libraries/Text/TextInput/Singleline/RCTUITextField.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ NS_ASSUME_NONNULL_BEGIN
5959
@property (nonatomic, copy, nullable) NSString *text;
6060
@property (nonatomic, copy, nullable) NSAttributedString *attributedText;
6161
@property (nonatomic, copy) NSDictionary<NSAttributedStringKey, id> *defaultTextAttributes;
62+
@property (nullable, nonatomic, copy) NSDictionary<NSAttributedStringKey, id> *typingAttributes;
6263
@property (nonatomic, assign) NSTextAlignment textAlignment;
6364
@property (nonatomic, getter=isAutomaticTextReplacementEnabled) BOOL automaticTextReplacementEnabled;
6465
@property (nonatomic, getter=isAutomaticSpellingCorrectionEnabled) BOOL automaticSpellingCorrectionEnabled;

0 commit comments

Comments
 (0)