-
Notifications
You must be signed in to change notification settings - Fork 24.5k
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
RN.Linking.openURL does not pre-populate message body on Pixel devices #23992
Comments
It looks like you are using an older version of React Native. Please update to the latest release, v0.59 and verify if the issue still exists. The "Resolution: Old Version" label will be removed automatically once you edit your original post with the results of running `react-native info` on a project using the latest release.
|
I can confirm this issue does exist on the latest version of React Native:
|
I ended up using https://www.npmjs.com/package/react-native-sms as I found linking with SMS links to work differently on a lot of API versions and devices. |
I am closing this issue because it does not appear to have been verified on the latest release, and there has been no followup in a while. If you found this thread after encountering the same issue in the latest release, please feel free to create a new issue with up-to-date information by clicking here. |
Looks like the repro was confirmed on the latest release but the bot wasn't smart enough to see that. Can someone file a new issue on the latest release? |
I still have the same issue with RN 0.59.4 |
We've seen this on devices other than the pixel running android 9. The emulator works correctly. |
This is not working on react native version 61.5, testing it on Android Q on Nexus emulator |
🐛 Bug Report
On Pixel devices, when using the url scheme
sms:?body=Hello%20World
inRN.Linking.openURL(url)
, the Messages app opens, but upon choosing a message recipient, the body of the message does not get pre-populated. This url scheme works on iOS and other Android devices, populating the message body in their respective default SMS apps, but does not produce a pre-filled message body on Pixel devices.Note: It seems to work on Pixel emulators via Android Studio but not on Pixel hardware.
To Reproduce
RN.Linking.openURL(url)
with the url schemesms:?body=Hello%20World
in your code.Expected Behavior
The default messaging app on the Pixel device (likely Google Messages) opens and you are given the option to select a contact or type in a phone number to send the message to. Upon choosing the recipient, you are navigated to a conversation screen in which the text input is set to "Hello World".
Code Example
RN.Linking.openURL("sms:?body=Hello%20World");
Environment
React Native Environment Info:
System:
OS: macOS 10.14.3
CPU: (8) x64 Intel(R) Core(TM) i7-7820HQ CPU @ 2.90GHz
Memory: 171.01 MB / 16.00 GB
Shell: 3.2.57 - /bin/bash
Binaries:
Node: 8.12.0 - /usr/local/bin/node
Yarn: 1.9.4 - /usr/local/bin/yarn
npm: 6.5.0 - /usr/local/bin/npm
SDKs:
iOS SDK:
Platforms: iOS 12.1, macOS 10.14, tvOS 12.1, watchOS 5.1
Android SDK:
API Levels: 23, 25, 26, 27, 28
Build Tools: 27.0.3, 28.0.2, 28.0.3
System Images: android-27 | Google APIs Intel x86 Atom, android-27 | Google Play Intel x86 Atom, android-28 | Google APIs Intel x86 Atom
IDEs:
Android Studio: 3.1 AI-173.4907809
Xcode: 10.1/10B61 - /usr/bin/xcodebuild
npmPackages:
react: 16.6.1 => 16.6.1
react-native: 0.57.7 => 0.57.7
The text was updated successfully, but these errors were encountered: