Fix Gif Select dialog search bar scrolling away (#8874)
* fix flatlist dialogs on web * tweak gif select dialog, add style prop to textfield
This commit is contained in:
@@ -48,9 +48,11 @@ const Context = createContext<{
|
||||
})
|
||||
Context.displayName = 'TextFieldContext'
|
||||
|
||||
export type RootProps = React.PropsWithChildren<{isInvalid?: boolean}>
|
||||
export type RootProps = React.PropsWithChildren<
|
||||
{isInvalid?: boolean} & TextStyleProp
|
||||
>
|
||||
|
||||
export function Root({children, isInvalid = false}: RootProps) {
|
||||
export function Root({children, isInvalid = false, style}: RootProps) {
|
||||
const inputRef = useRef<TextInput>(null)
|
||||
const {
|
||||
state: hovered,
|
||||
@@ -85,7 +87,14 @@ export function Root({children, isInvalid = false}: RootProps) {
|
||||
return (
|
||||
<Context.Provider value={context}>
|
||||
<View
|
||||
style={[a.flex_row, a.align_center, a.relative, a.w_full, a.px_md]}
|
||||
style={[
|
||||
a.flex_row,
|
||||
a.align_center,
|
||||
a.relative,
|
||||
a.w_full,
|
||||
a.px_md,
|
||||
style,
|
||||
]}
|
||||
{...web({
|
||||
onClick: () => inputRef.current?.focus(),
|
||||
onMouseOver: onHoverIn,
|
||||
|
||||
Reference in New Issue
Block a user