-
Notifications
You must be signed in to change notification settings - Fork 36
feat: add returnKeyType, submitBehavior, onSubmitEditing, returnKeyLabel props #379
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
kacperzolkiewski
merged 16 commits into
software-mansion:main
from
IslamRustamov:feature/add-submit-related-props
Mar 20, 2026
Merged
Changes from all commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
b4f7cb8
feat: add returnKeyType submitBehavior and onSubmitEditing on iOS
IslamRustamov ed7c6f1
feat: add returnKeyType returnKeyLabel submitBehavior and onSubmitEdi…
IslamRustamov cdea712
chore: cleanup
IslamRustamov 91e68e4
chore: refactoring
IslamRustamov f4feec2
fix: android crash on ime action label press
IslamRustamov 63ed83e
fix: bluring input
kacperzolkiewski 388bc52
fix: add comment to onEditorAction
kacperzolkiewski 1dc2939
Merge branch 'main' into feature/add-submit-related-props
exploIF 75e2afd
feat: checkbox list - android (#363)
exploIF ea47a40
Merge branch 'main' into feature/add-submit-related-props
IslamRustamov bbb9fbf
Merge branch 'main' into feature/add-submit-related-props
kacperzolkiewski 5234f7e
Merge branch 'main' into feature/add-submit-related-props
kacperzolkiewski acc5fba
Merge branch 'main' into feature/add-submit-related-props
kacperzolkiewski 4e50c95
fix: add submit edditing event to Dev and Test screens
kacperzolkiewski a69cff0
Merge branch 'main' into feature/add-submit-related-props
pkaramon 3c8eadd
refactor: destructure props explicitly
pkaramon File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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
29 changes: 29 additions & 0 deletions
29
android/src/main/java/com/swmansion/enriched/textinput/events/OnSubmitEditingEvent.kt
This file contains hidden or 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,29 @@ | ||
| package com.swmansion.enriched.textinput.events | ||
|
|
||
| import android.text.Editable | ||
| import com.facebook.react.bridge.Arguments | ||
| import com.facebook.react.bridge.WritableMap | ||
| import com.facebook.react.uimanager.events.Event | ||
|
|
||
| class OnSubmitEditingEvent( | ||
| surfaceId: Int, | ||
| viewId: Int, | ||
| private val editable: Editable?, | ||
| private val experimentalSynchronousEvents: Boolean, | ||
| ) : Event<OnSubmitEditingEvent>(surfaceId, viewId) { | ||
| override fun getEventName(): String = EVENT_NAME | ||
|
|
||
| override fun getEventData(): WritableMap { | ||
| val eventData: WritableMap = Arguments.createMap() | ||
| val text = editable.toString() | ||
| val normalizedText = text.replace(Regex("\\u200B"), "") | ||
| eventData.putString("text", normalizedText) | ||
| return eventData | ||
| } | ||
|
|
||
| override fun experimental_isSynchronous(): Boolean = experimentalSynchronousEvents | ||
|
|
||
| companion object { | ||
| const val EVENT_NAME: String = "onSubmitEditing" | ||
| } | ||
| } |
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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,7 @@ | ||
| #import <UIKit/UIKit.h> | ||
| #pragma once | ||
|
|
||
| @interface KeyboardUtils : NSObject | ||
| + (UIReturnKeyType)getUIReturnKeyTypeFromReturnKeyType: | ||
| (NSString *)returnKeyType; | ||
| @end |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.