mirror of
https://github.com/Jellify-Music/App.git
synced 2026-04-22 18:10:31 -05:00
alignment things
This commit is contained in:
@@ -76,6 +76,7 @@ export default function Item({
|
||||
<YStack
|
||||
marginLeft={"$1"}
|
||||
alignContent="center"
|
||||
alignItems="center"
|
||||
justifyContent="flex-start"
|
||||
flex={3}
|
||||
>
|
||||
|
||||
@@ -1,18 +1,11 @@
|
||||
import React from 'react';
|
||||
import { Input as TamaguiInput, useTheme} from 'tamagui';
|
||||
import { Input as TamaguiInput, InputProps as TamaguiInputProps} from 'tamagui';
|
||||
|
||||
interface InputProps {
|
||||
onChangeText: (value: string | undefined) => void,
|
||||
placeholder: string
|
||||
value: string | undefined;
|
||||
secureTextEntry?: boolean | undefined;
|
||||
flexGrow?: boolean | undefined
|
||||
interface InputProps extends TamaguiInputProps {
|
||||
}
|
||||
|
||||
export default function Input(props: InputProps): React.JSX.Element {
|
||||
|
||||
const theme = useTheme();
|
||||
|
||||
return (
|
||||
<TamaguiInput
|
||||
placeholder={props.placeholder}
|
||||
|
||||
@@ -7,7 +7,7 @@ import { StackParamList } from "../types";
|
||||
import { QueryKeys } from "../../enums/query-keys";
|
||||
import { fetchSearchResults } from "../../api/queries/functions/search";
|
||||
import { useQuery } from "@tanstack/react-query";
|
||||
import { FlatList } from "react-native";
|
||||
import { FlatList, useColorScheme } from "react-native";
|
||||
|
||||
export default function Search({
|
||||
navigation
|
||||
@@ -15,6 +15,7 @@ export default function Search({
|
||||
navigation: NativeStackNavigationProp<StackParamList>
|
||||
}): React.JSX.Element {
|
||||
|
||||
const isDarkMode = useColorScheme() === 'dark';
|
||||
const [searchString, setSearchString] = useState<string | undefined>(undefined);
|
||||
|
||||
const { data: items, refetch, isFetched, isFetching } = useQuery({
|
||||
@@ -38,6 +39,7 @@ export default function Search({
|
||||
<FlatList
|
||||
contentInsetAdjustmentBehavior="automatic"
|
||||
progressViewOffset={10}
|
||||
indicatorStyle={isDarkMode ? 'white' : 'default'}
|
||||
ListHeaderComponent={(
|
||||
<Input
|
||||
placeholder="Seek and ye shall find..."
|
||||
|
||||
Reference in New Issue
Block a user