-
Notifications
You must be signed in to change notification settings - Fork 1
feat(profile): complete profile page and related pages #46
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
Open
Psamcyite
wants to merge
11
commits into
master
Choose a base branch
from
feat/profile-pages
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 4 commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
bffba31
feat(profile): complete profile page and related pages
Psamcyite 4850f63
chore: fix TextInput background color
Psamcyite 531d7e6
chore: fix conflict issues
Psamcyite 83c7957
format the code correctly
FleetAdmiralJakob ad4efcd
fix lockfile and updated pnpm version
FleetAdmiralJakob f626f99
fix lint issues
FleetAdmiralJakob 0e5f91c
removed unused package
FleetAdmiralJakob ca92fd3
fix coderabbit issues
FleetAdmiralJakob 949f7b9
fix issues
FleetAdmiralJakob 90e9b79
Merge branch 'refs/heads/master' into feat/profile-pages
FleetAdmiralJakob 6d5f4d8
fixed coderabbitai issues
FleetAdmiralJakob File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 @@ | ||
| { | ||
| "java.compile.nullAnalysis.mode": "automatic" | ||
| "java.compile.nullAnalysis.mode": "automatic", | ||
| "cSpell.words": ["Verticborder"] | ||
| } |
This file contains hidden or 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or 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,4 +1,5 @@ | ||
| packages: | ||
| - "src/*" | ||
| - "." | ||
|
|
||
| onlyBuiltDependencies: | ||
|
|
||
This file contains hidden or 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 hidden or 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,47 @@ | ||
| import React from "react"; | ||
| import { ThemeProvider } from "~/contexts/ThemeContext"; | ||
| import { ProfileScreen } from "~/components/profile/ProfileScreen"; | ||
| import { LimitsScreen } from "~/components/profile/Limits"; | ||
| import { IncomeScreen } from "~/components/profile/Income"; | ||
| import { NotificationScreen } from "~/components/profile/Notification"; | ||
| import { UserProfileScreen } from "~/components/profile/UserProfile"; | ||
| import { BankAccountsScreen } from "~/components/profile/BankAccounts"; | ||
|
|
||
| const ProfileAppContent: React.FC = () => { | ||
| const [currentScreen, setCurrentScreen] = React.useState("Profile"); | ||
|
|
||
| const handleNavigate = (screen: string) => { | ||
| setCurrentScreen(screen); | ||
| }; | ||
|
|
||
| const renderScreen = () => { | ||
| switch (currentScreen) { | ||
| case "Profile": | ||
| return <ProfileScreen onNavigate={handleNavigate} />; | ||
| case "Limits": | ||
| return <LimitsScreen onNavigate={handleNavigate} />; | ||
| case "Income": | ||
| return <IncomeScreen onNavigate={handleNavigate} />; | ||
| case "Notification": | ||
| return <NotificationScreen onNavigate={handleNavigate} />; | ||
| case "UserProfile": | ||
| return <UserProfileScreen onNavigate={handleNavigate} />; | ||
| case "BankAccounts": | ||
| return <BankAccountsScreen onNavigate={handleNavigate} />; | ||
| default: | ||
| return <ProfileScreen onNavigate={handleNavigate} />; | ||
| } | ||
| }; | ||
|
|
||
| return renderScreen(); | ||
| }; | ||
|
|
||
| const ProfileApp: React.FC = () => { | ||
| return ( | ||
| <ThemeProvider> | ||
| <ProfileAppContent /> | ||
| </ThemeProvider> | ||
| ); | ||
| }; | ||
|
|
||
| export default ProfileApp; |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or 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 hidden or 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,75 @@ | ||
| import type React from "react"; | ||
| import { View, TouchableOpacity, Image } from "react-native"; | ||
| import { useTheme } from "../contexts/ThemeContext"; | ||
| import AppText from "./ui/AppText"; | ||
|
|
||
| interface BottomNavigationProps { | ||
| activeTab: "Banking" | "Insights" | "Settings"; | ||
| onTabPress: (tab: "Banking" | "Insights" | "Settings") => void; | ||
| } | ||
|
|
||
| export const BottomNavigation: React.FC<BottomNavigationProps> = ({ | ||
| activeTab, | ||
| onTabPress, | ||
| }) => { | ||
| const { colors } = useTheme(); | ||
|
|
||
| const TabItem = ({ | ||
| tab, | ||
| label, | ||
| iconSource, | ||
| }: { | ||
| tab: "Banking" | "Insights" | "Settings"; | ||
| label: string; | ||
| iconSource: any; | ||
| }) => { | ||
| const isActive = activeTab === tab; | ||
| return ( | ||
| <TouchableOpacity | ||
| className="flex-1 items-center py-3" | ||
| onPress={() => onTabPress(tab)} | ||
| > | ||
| <Image | ||
| source={iconSource} | ||
| style={{ | ||
| width: 20, | ||
| height: 20, | ||
| }} | ||
| resizeMode="contain" | ||
| /> | ||
| <AppText | ||
| className="mt-1 text-xs" | ||
| style={{ color: isActive ? colors.text : colors.text }} | ||
| > | ||
| {label} | ||
| </AppText> | ||
coderabbitai[bot] marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| </TouchableOpacity> | ||
| ); | ||
| }; | ||
|
|
||
| return ( | ||
| <View | ||
| className="flex-row border-t pb-3" | ||
| style={{ | ||
| borderTopColor: colors.border, | ||
| backgroundColor: colors.cardBackground, | ||
| }} | ||
| > | ||
| <TabItem | ||
| tab="Banking" | ||
| label="Banking" | ||
| iconSource={require("~/assets/Icons/banking.png")} | ||
| /> | ||
| <TabItem | ||
| tab="Insights" | ||
| label="Insights" | ||
| iconSource={require("~/assets/Icons/insights.png")} | ||
| /> | ||
| <TabItem | ||
| tab="Settings" | ||
| label="Settings" | ||
| iconSource={require("~/assets/Icons/settings.png")} | ||
| /> | ||
| </View> | ||
| ); | ||
| }; | ||
This file contains hidden or 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,39 @@ | ||
| import React from "react"; | ||
| import { TouchableOpacity } from "react-native"; | ||
| import AppText from "./ui/AppText"; | ||
|
|
||
| type ButtonProps = { | ||
| title: string; | ||
| onPress: () => void; | ||
| className?: string; | ||
| textClassName?: string; | ||
| disabled?: boolean; | ||
| }; | ||
|
|
||
| export default function Button({ | ||
| title, | ||
| onPress, | ||
| className = "", | ||
| textClassName = "", | ||
| disabled = false, | ||
| }: ButtonProps) { | ||
| return ( | ||
| <TouchableOpacity | ||
| onPress={onPress} | ||
| disabled={disabled} | ||
| className={`items-center justify-center rounded-xl px-4 py-3 ${ | ||
| disabled ? "bg-gray-400" : "bg-blue-600" | ||
| } ${className}`} | ||
| > | ||
| <AppText | ||
| semibold | ||
| className={`text-base ${ | ||
| disabled ? "text-gray-200" : "text-white" | ||
| } ${textClassName}`} | ||
| style={{ color: undefined }} | ||
| > | ||
| {title} | ||
| </AppText> | ||
| </TouchableOpacity> | ||
| ); | ||
| } |
This file contains hidden or 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,52 @@ | ||
| import type React from "react"; | ||
| import { TouchableOpacity, Image } from "react-native"; | ||
| import Animated, { | ||
| useSharedValue, | ||
| useAnimatedStyle, | ||
| withSpring, | ||
| } from "react-native-reanimated"; | ||
| import { useTheme } from "~/contexts/ThemeContext"; | ||
|
|
||
| interface FloatingActionButtonProps { | ||
| onPress: () => void; | ||
| } | ||
|
|
||
| export const FloatingActionButton: React.FC<FloatingActionButtonProps> = ({ | ||
| onPress, | ||
| }) => { | ||
| const { colors } = useTheme(); | ||
| const scale = useSharedValue(1); | ||
|
|
||
| const animatedStyle = useAnimatedStyle(() => ({ | ||
| transform: [{ scale: scale.value }], | ||
| })); | ||
|
|
||
| const handlePressIn = () => { | ||
| scale.value = withSpring(0.95); | ||
| }; | ||
|
|
||
| const handlePressOut = () => { | ||
| scale.value = withSpring(1); | ||
| }; | ||
|
|
||
| return ( | ||
| <Animated.View | ||
| className="absolute bottom-24 right-5 h-12 w-12 items-center justify-center rounded-full shadow-lg" | ||
| style={[{ backgroundColor: colors.primary }, animatedStyle]} | ||
| > | ||
| <TouchableOpacity | ||
| className="h-full w-full items-center justify-center" | ||
| onPress={onPress} | ||
| onPressIn={handlePressIn} | ||
| onPressOut={handlePressOut} | ||
| activeOpacity={1} | ||
| > | ||
| <Image | ||
| source={require("~/assets/Icons/plus.png")} | ||
| style={{ width: 12, height: 12 }} | ||
| resizeMode="contain" | ||
| /> | ||
| </TouchableOpacity> | ||
| </Animated.View> | ||
| ); | ||
| }; |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.