feat:Input add beforeTextChange API

This commit is contained in:
pengfei.zhou
2021-06-11 17:47:06 +08:00
committed by osborn
parent e528630f71
commit 9fed9e431c
11 changed files with 95 additions and 2 deletions

View File

@@ -75,6 +75,14 @@ export class Input extends View {
@Property
onSubmitEditing?: (text: string) => void
@Property
beforeTextChange?: (change: {
editing: string,
start: number,
length: number,
replacement: string,
}) => boolean
getText(context: BridgeContext) {
return this.nativeChannel(context, 'getText')() as Promise<string>
}