react-native-windows icon indicating copy to clipboard operation
react-native-windows copied to clipboard

Avoid ReplaceView in TextInputViewManager

Open rozele opened this issue 1 year ago • 0 comments

Description

Type of Change

Erase all that don't apply.

  • Bug fix (non-breaking change which fixes an issue)

Why

Since we now have props in the CreateView method for core view managers, we can avoid the creation of a TextBox initially in TextInputViewManager when "secureTextEntry" is set to true.

Towards #7143

What

Checks the props passed into CreateViewCore for secureTextEntry == true and conditionally creates a PasswordBox, rather than a TextBox.

Testing

Ran TextInput example in RNTester and everything works fine.

Optional: Describe the tests that you ran locally to verify your changes.

Microsoft Reviewers: Open in CodeFlow

rozele avatar Aug 01 '22 21:08 rozele