Skip to content

iOS dictation is adding OBJ to string value #36521

@gkasireddy202

Description

@gkasireddy202

Description

Hi,

When I use dictation adding text to TextInput in iOS.
OBJ is added to the text input value.
I am using iOS 16.
Please find the attached screenshot.

Thanks,
Screenshot 2023-03-15 at 6 43 07 PM

React Native Version

0.71.4

Output of npx react-native info

System:
OS: macOS 13.2.1
CPU: (12) x64 Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz
Memory: 118.30 MB / 16.00 GB
Shell: 5.8.1 - /bin/zsh
Binaries:
Node: 19.8.1 - /usr/local/bin/node
Yarn: Not Found
npm: 9.5.1 - /usr/local/bin/npm
Watchman: 2023.03.13.00 - /usr/local/bin/watchman
Managers:
CocoaPods: 1.12.0 - /Users/gopi/.rvm/gems/ruby-2.7.6/bin/pod
SDKs:
iOS SDK:
Platforms: DriverKit 22.2, iOS 16.2, macOS 13.1, tvOS 16.1, watchOS 9.1
Android SDK:
API Levels: 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33
Build Tools: 28.0.3, 29.0.2, 30.0.2, 30.0.3, 31.0.0, 32.0.0, 32.1.0, 33.0.0
System Images: android-30 | Google APIs Intel x86 Atom, android-32 | Google APIs Intel x86 Atom_64, android-32 | Google Play Intel x86 Atom_64, android-33 | Google APIs Intel x86 Atom_64, android-33 | Google Play Intel x86 Atom_64
Android NDK: Not Found
IDEs:
Android Studio: 2021.2 AI-212.5712.43.2112.8609683
Xcode: 14.2/14C18 - /usr/bin/xcodebuild
Languages:
Java: 11.0.15 - /usr/bin/javac
npmPackages:
@react-native-community/cli: Not Found
react: 18.2.0 => 18.2.0
react-native: 0.71.4 => 0.71.4
react-native-macos: Not Found
npmGlobalPackages:
react-native: Not Found

Steps to reproduce

  1. Click on dictation and start speaking.
  2. After the ending of the sentence.

Screenshot 2023-03-15 at 6 43 07 PM

A unique character OBJ is added to the text input value.

Snack, code example, screenshot, or link to a repository

import React, { Component } from 'react';
import { StyleSheet, View, Text, TouchableOpacity, TextInput } from 'react-native';
export default class App extends Component {

constructor(props) {
super(props);
this.state = {

  internalValue: ''


}

}

render() {
return (<View style={{ flex: 1 }}>

  <View style={{ flex: 1 }}>

  </View>

  <View style={{ flex: 2 }}>
    <View style={{ flex: 8 }}>
      <TextInput
        style={styles.textarea}
        onChangeText={(text) => this.setState({ internalValue: text })}
        value={this.state.internalValue}
        maxLength={120}
        multiline={true}
        placeholder={'Enter Text'}
        placeholderTextColor={'#c7c7c7'}
        underlineColorAndroid={'transparent'}
      />

    </View>
    <TouchableOpacity onPress={() => this.handleClickMe()} style={{ flex: 2, backgroundColor: 'green', margin: 20, alignItems: 'center', justifyContent: 'center' }}>

      <Text>Click me</Text>


    </TouchableOpacity>
  </View>
  <View style={{ flex: 3 }}>

  </View>




</View>)

}

}

const styles = StyleSheet.create({
container: {
flex: 1,
padding: 30,
justifyContent: 'center',
alignItems: 'center',
},
textareaContainer: {
height: 180,
padding: 5,
backgroundColor: '#F5FCFF',
},
textarea: {
textAlignVertical: 'top', // hack android
height: 170,
fontSize: 14,
color: '#333',
backgroundColor: 'white'
},
});

Metadata

Metadata

Assignees

No one assigned

    Labels

    Needs: Triage 🔍Platform: iOSiOS applications.StaleThere has been a lack of activity on this issue and it may be closed soon.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions