X Tutup
The Wayback Machine - https://web.archive.org/web/20201218003201/https://github.com/gitpoint/git-point/pull/447
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

fix: show new issue submit button when keyboard is open #447

Open
wants to merge 7 commits into
base: master
from

Conversation

@acurat
Copy link
Contributor

@acurat acurat commented Oct 7, 2017

Fixes #289

iOS screenshot

simulator screen shot - iphone 6 - 2017-10-07 at 12 24 34

Android screenshot

screenshot_1507399484

acurat added 6 commits Oct 7, 2017
Move contributors to CONTRIBUTORS.md as the list is getting lon in CONTRIBUTING.md

#359
Renaming to official name.
adding dot
show issue submit button when issue comment is large, so it is not hidden under the keyboard
show submit button in new issue screen when keyboard is open

289
<SectionList>
<View style={styles.listItemContainer}>
<KeyboardAvoidingView
style={{ flex: 1 }}

This comment has been minimized.

@lex111

lex111 Oct 7, 2017
Member

Style need move to styles.

This comment has been minimized.

@acurat

acurat Oct 7, 2017
Author Contributor

Done.

style={{ flex: 1 }}
behavior={'padding'}
keyboardVerticalOffset={Platform.select({
ios: 65,

This comment has been minimized.

@lex111

lex111 Oct 7, 2017
Member

Why are the different values depending on the platform?

This comment has been minimized.

@acurat

acurat Oct 7, 2017
Author Contributor

The keyboardVerticalOffset is different because the height of the following vary by platform.

  • React navigation headers.
  • Height of the auto suggestion bar.
    So I figured both platforms needs separate offset heights.
Moving inline styles to style object
@andrewda andrewda changed the title Show new issue submit btn when keyboard is open fix: show new issue submit button when keyboard is open Oct 7, 2017
@andrewda
Copy link
Member

@andrewda andrewda commented Oct 7, 2017

@acurat What if the user is using a custom keyboard that isn't the default system size? GBoard for iOS, for example, is at least another 50px larger than the system default. There's probably a more fluid way to do this.

@acurat
Copy link
Contributor Author

@acurat acurat commented Oct 8, 2017

Here is a screenshot with the GBoard keyboard. It looks fine.

screen shot 2017-10-08 at 12 52 33 am

Now, that I re-read the KeyboardAvoidingView's documentation, it makes sense. Need to only offset the react navigation header, the height of which is fixed in this app.

_ keyboardVerticalOffset: number

This is the distance between the top of the user screen and the react native view, may be non-zero in some use cases. _

Anyways, let me know if there is a better way to do this.

@lex111
Copy link
Member

@lex111 lex111 commented Oct 8, 2017

@acurat it does not work for me (Russian keyboard):

image

@housseindjirdeh
Copy link
Member

@housseindjirdeh housseindjirdeh commented Oct 20, 2017

Friendly ping @acurat, just wanted to check in and see if you need any help with this at all :)

@acurat
Copy link
Contributor Author

@acurat acurat commented Oct 21, 2017

@housseindjirdeh Yes, I am not sure I know a better solution for this. Any help is appreciated.

@machour
Copy link
Member

@machour machour commented Mar 31, 2018

Seems like React Native 0.55 will ship with something interesting for this PR:
https://twitter.com/brunolemos/status/977037390429777920

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

5 participants
You can’t perform that action at this time.
X Tutup