-
Notifications
You must be signed in to change notification settings - Fork 199
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add TextInput windows-specific properties to documentation (#927)
## Description Adds TextInput into components so we can document windows-specific properties. ### Why There is currently no documentation for these properties even though they get used quite often. This adds a section to the components so it's easily discoverable. But let me know if there's a better place for these properties! Resolves #916 ## Screenshots ![image](https://github.com/microsoft/react-native-windows-samples/assets/42554868/7067c78a-e3db-480c-882e-bdcc1c28c683) ###### Microsoft Reviewers: [Open in CodeFlow](https://microsoft.github.io/open-pr/?codeflow=https://github.com/microsoft/react-native-windows-samples/pull/927) --------- Co-authored-by: Chris Glein <26607885+chrisglein@users.noreply.github.com>
- Loading branch information
1 parent
07fe224
commit 5f22fe7
Showing
3 changed files
with
38 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
--- | ||
id: textinput-component | ||
title: TextInput | ||
--- | ||
|
||
# Reference | ||
|
||
## Props | ||
|
||
Inherits [TextInput Props](https://reactnative.dev/docs/textinput). | ||
|
||
## Windows-Specific Properties | ||
|
||
### `submitKeyEvent` | ||
|
||
A property that registers a set of KeyEvents that may trigger `onSubmitEditing` in a multiline scenario. | ||
|
||
| type | required | | ||
|:--|:--| | ||
| { code: 'Enter', shiftKey: bool } | No | | ||
|
||
### `clearTextOnSubmit` | ||
|
||
If `true`, the text field will clear when submitted. The default value is false. | ||
|
||
| type | required | | ||
|:--|:--| | ||
| bool | No | | ||
|
||
## Examples | ||
|
||
Examples can be found in the [React Native Gallery App](https://github.com/microsoft/react-native-gallery/blob/main/src/examples/TextInputExamplePage.tsx) available in the [Microsoft Store](http://aka.ms/reactnativegalleryapp) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters