[🐴] A few tweaks to message input on native (#4035)

* tweaks

* only apply the padding on ios

* use a hitslop of 10 instead

* version bump
zio/stable
Hailey 2024-05-16 08:09:14 -07:00 committed by GitHub
parent aded49f65b
commit 9499d4343d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 10 additions and 2 deletions

View File

@ -1,6 +1,6 @@
{ {
"name": "bsky.app", "name": "bsky.app",
"version": "1.82.0", "version": "1.83.0",
"private": true, "private": true,
"engines": { "engines": {
"node": ">=18" "node": ">=18"

View File

@ -19,6 +19,7 @@ import {
useMessageDraft, useMessageDraft,
useSaveMessageDraft, useSaveMessageDraft,
} from '#/state/messages/message-drafts' } from '#/state/messages/message-drafts'
import {isIOS} from 'platform/detection'
import * as Toast from '#/view/com/util/Toast' import * as Toast from '#/view/com/util/Toast'
import {atoms as a, useTheme} from '#/alf' import {atoms as a, useTheme} from '#/alf'
import {PaperPlane_Stroke2_Corner0_Rounded as PaperPlane} from '#/components/icons/PaperPlane' import {PaperPlane_Stroke2_Corner0_Rounded as PaperPlane} from '#/components/icons/PaperPlane'
@ -97,13 +98,20 @@ export function MessageInput({
value={message} value={message}
multiline={true} multiline={true}
onChangeText={setMessage} onChangeText={setMessage}
style={[a.flex_1, a.text_md, a.px_sm, t.atoms.text, {maxHeight}]} style={[
a.flex_1,
a.text_md,
a.px_sm,
t.atoms.text,
{maxHeight, paddingBottom: isIOS ? 5 : 0},
]}
keyboardAppearance={t.name === 'light' ? 'light' : 'dark'} keyboardAppearance={t.name === 'light' ? 'light' : 'dark'}
scrollEnabled={isInputScrollable} scrollEnabled={isInputScrollable}
blurOnSubmit={false} blurOnSubmit={false}
onFocus={scrollToEnd} onFocus={scrollToEnd}
onContentSizeChange={onInputLayout} onContentSizeChange={onInputLayout}
ref={inputRef} ref={inputRef}
hitSlop={HITSLOP_10}
/> />
<Pressable <Pressable
accessibilityRole="button" accessibilityRole="button"