Skip to content
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

Webview contentInset property doesn't work in Android. But, work well in iOS #16111

Closed
rogerluo410 opened this issue Sep 27, 2017 · 1 comment
Labels
Good first issue Interested in collaborating? Take a stab at fixing one of these issues. Help Wanted :octocat: Issues ideal for external contributors. Resolution: Locked This issue was locked by the bot.

Comments

@rogerluo410
Copy link

rogerluo410 commented Sep 27, 2017

Is this a bug report?

(write your answer here) yes

Have you read the Contributing Guidelines?

(Write your answer here.) Yes

Environment

OS:  macOS Sierra 10.12.6
Node:  8.4.0
Yarn:  0.27.5
npm:  5.4.0
Watchman:  4.7.0
Xcode:  Xcode 8.3.3 Build version 8E3004b
Android Studio:  2.3 AI-162.4069837

react-native: 0.44.2
react: 16.0.0-alpha.12 

Steps to Reproduce

(Write your steps here:)

contentInset={{top: -8, left: -8}} contentInset property doesn't work in Android, but, this is not marked as an iOS property in Docs.

Expected Behavior

(Write what you thought would happen.)

How to fix it ? move or remove the content offset? No space between webview and content.

which RN version could solve the problem and use the contentInset property??

Thank you.

Actual Behavior

(Write what happened. Add screenshots!)

image

I am hoping in Android:

image

Reproducible Demo

(Paste the link to an example project and exact instructions to reproduce the issue.)

@janicduplessis
Copy link
Contributor

Android doesn't have the concept of insets so I think this is more of a documentation issue, the prop should be marked as iOS only. Is it possible to achieve the effect you are looking for on Android using padding instead?

@janicduplessis janicduplessis added Documentation Good first issue Interested in collaborating? Take a stab at fixing one of these issues. Help Wanted :octocat: Issues ideal for external contributors. labels Sep 29, 2017
facebook-github-bot pushed a commit that referenced this issue Oct 7, 2017
Summary:
Addresses #16111

**No tests needed, non functional change. Test suite ran: PASS**
Closes #16138

Differential Revision: D6004974

Pulled By: hramos

fbshipit-source-id: 3f47aab417ec0181fe8c3029d72e7729a709a754
@facebook facebook locked as resolved and limited conversation to collaborators Dec 25, 2018
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Dec 25, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Good first issue Interested in collaborating? Take a stab at fixing one of these issues. Help Wanted :octocat: Issues ideal for external contributors. Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

3 participants