-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Version 1.0.0
- Loading branch information
Showing
38 changed files
with
2,516 additions
and
239 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
import "native-base"; | ||
import { theme } from "../theme"; | ||
|
||
type MyThemeType = typeof theme; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
export declare global { | ||
namespace ReactNavigation { | ||
interface RootParamList { | ||
CategoryDetails: { | ||
id: number; | ||
}; | ||
DrinkDetails: { | ||
id: number; | ||
}; | ||
Tabs: any; | ||
SearchResponse: { | ||
placeholder: string; | ||
categories?: boolean; | ||
drinks?: boolean; | ||
selected: "Drinks" | "Categories"; | ||
}; | ||
} | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
import { FontAwesome5 } from "@expo/vector-icons"; | ||
import { useNavigation } from "@react-navigation/native"; | ||
import { Icon, Input } from "native-base"; | ||
import React from "react"; | ||
|
||
type SearchBarProps = { | ||
placeholder: string; | ||
categories?: boolean; | ||
drinks?: boolean; | ||
selected: "Drinks" | "Categories"; | ||
}; | ||
|
||
export function SearchBar({ | ||
placeholder, | ||
categories, | ||
drinks, | ||
selected, | ||
}: SearchBarProps) { | ||
const navigation = useNavigation(); | ||
return ( | ||
<Input | ||
mx={"1.5rem"} | ||
mt={"0.75rem"} | ||
variant={"filled"} | ||
borderRadius={"0.75rem"} | ||
bgColor={"white"} | ||
placeholder={placeholder} | ||
fontSize={"0.9375rem"} | ||
fontWeight={"medium"} | ||
h={"2.25rem"} | ||
py={"0"} | ||
InputLeftElement={ | ||
<Icon as={FontAwesome5} name="search" size={"1rem"} px={"0.875rem"} /> | ||
} | ||
onClick={() => | ||
navigation.navigate("SearchResponse", { | ||
placeholder: placeholder, | ||
categories: categories, | ||
drinks: drinks, | ||
selected: selected, | ||
}) | ||
} | ||
readonly | ||
/> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
import { Box, Flex, Image, Text } from "native-base"; | ||
import React from "react"; | ||
import { Animated, Pressable } from "react-native"; | ||
import { scaleAnimation } from "../../utils/animations/scale"; | ||
|
||
export function TodaysCategory() { | ||
const animation = scaleAnimation(1, 0.98, 100); | ||
return ( | ||
<Flex mx={"1.5rem"} mt={"1rem"}> | ||
<Text fontSize={"1.25rem"} fontWeight={"bold"} mb={"0.5rem"}> | ||
Today's Category | ||
</Text> | ||
<Pressable | ||
onPressIn={animation.onPressIn} | ||
onPressOut={animation.onPressOut} | ||
> | ||
<Animated.View style={animation.style}> | ||
<Box | ||
w={"100%"} | ||
height={"12.5rem"} | ||
borderRadius={"lg"} | ||
position={"relative"} | ||
shadow={"2"} | ||
> | ||
<Text | ||
position={"absolute"} | ||
bottom={"1rem"} | ||
left={"1.5rem"} | ||
zIndex={"4"} | ||
fontWeight={"black"} | ||
fontSize={"1.5rem"} | ||
color={"white"} | ||
> | ||
Ordinary Drinks | ||
</Text> | ||
<Box | ||
w={"100%"} | ||
h={"50%"} | ||
bottom={0} | ||
zIndex={"3"} | ||
position={"absolute"} | ||
borderRadius={"lg"} | ||
bg={{ | ||
linearGradient: { | ||
colors: ["rgba(196, 196, 196, 0)", "rgba(0, 210, 255, 0.6)"], | ||
}, | ||
}} | ||
/> | ||
<Box | ||
w={"100%"} | ||
h={"100%"} | ||
zIndex={"2"} | ||
position={"absolute"} | ||
borderRadius={"lg"} | ||
bg={"rgba(0,0,0,0.1)"} | ||
/> | ||
<Box | ||
w={"100%"} | ||
h={"100%"} | ||
zIndex={"1"} | ||
position={"absolute"} | ||
borderRadius={"lg"} | ||
bg={"rgba(21, 214, 255, 0.3)"} | ||
/> | ||
<Image | ||
borderRadius={"lg"} | ||
resizeMode={"cover"} | ||
size={"100%"} | ||
zIndex={"0"} | ||
alt={"Imagem de um drink"} | ||
source={{ | ||
uri: "https://www.thecocktaildb.com/images/media/drink/rrtssw1472668972.jpg", | ||
cache: "force-cache" | ||
}} | ||
/> | ||
</Box> | ||
</Animated.View> | ||
</Pressable> | ||
</Flex> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
import { Box, Flex, Image, Text } from "native-base"; | ||
import React from "react"; | ||
|
||
export function TodaysDrink() { | ||
return ( | ||
<Flex mx={"1.5rem"} mt={"1rem"}> | ||
<Text fontSize={"1.25rem"} fontWeight={"bold"} mb={"0.5rem"}> | ||
Today's Drink | ||
</Text> | ||
<Box | ||
w={"100%"} | ||
height={"12.5rem"} | ||
borderRadius={"lg"} | ||
position={"relative"} | ||
shadow={"2"} | ||
> | ||
<Text | ||
position={"absolute"} | ||
bottom={"1rem"} | ||
left={"1.5rem"} | ||
zIndex={"4"} | ||
fontWeight={"black"} | ||
fontSize={"1.5rem"} | ||
color={"white"} | ||
> | ||
Dry Martini | ||
</Text> | ||
<Box | ||
w={"100%"} | ||
h={"50%"} | ||
bottom={0} | ||
zIndex={"3"} | ||
position={"absolute"} | ||
borderRadius={"lg"} | ||
bg={{ | ||
linearGradient: { | ||
colors: ["rgba(196, 196, 196, 0)", "rgba(0, 210, 255, 0.6)"], | ||
}, | ||
}} | ||
/> | ||
<Box | ||
w={"100%"} | ||
h={"100%"} | ||
zIndex={"2"} | ||
position={"absolute"} | ||
borderRadius={"lg"} | ||
bg={"rgba(0,0,0,0.1)"} | ||
/> | ||
<Box | ||
w={"100%"} | ||
h={"100%"} | ||
zIndex={"1"} | ||
position={"absolute"} | ||
borderRadius={"lg"} | ||
bg={"rgba(21, 214, 255, 0.3)"} | ||
/> | ||
<Image | ||
borderRadius={"lg"} | ||
resizeMode={"cover"} | ||
size={"100%"} | ||
zIndex={"0"} | ||
alt={"Imagem de um drink"} | ||
source={{ | ||
uri: "https://www.thecocktaildb.com/images/media/drink/6ck9yi1589574317.jpg", | ||
cache: "force-cache" | ||
}} | ||
/> | ||
</Box> | ||
</Flex> | ||
); | ||
} |
Oops, something went wrong.