-
Notifications
You must be signed in to change notification settings - Fork 4
feat/api safesearch #20
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
Astrol99
wants to merge
68
commits into
main
Choose a base branch
from
feat/api-safesearch
base: main
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 all commits
Commits
Show all changes
68 commits
Select commit
Hold shift + click to select a range
b437175
init: template
Astrol99 787d60f
feat: added basic button variants and cleaned up screens
Astrol99 20ba107
ops: added zod react-hook-form and resolver
Astrol99 2ab7b1d
feat: added basic login form
Astrol99 e164800
feat: auth flow
Astrol99 3872a73
feat: fixed some styling
Astrol99 b934970
fix: auth flow bug
Astrol99 04433a4
fix: types
Astrol99 dbec280
fix: entire auth flow
Astrol99 cc03bb0
fix: auth store
Astrol99 a35238e
feat: added more tabs
Astrol99 830a936
ops: added recommended vscode extensions
Astrol99 ce1777a
updated extensions
Astrol99 6db2dba
feat: added user registration
Astrol99 7ed4def
chore: cleaned up some packages
Astrol99 fe92976
feat: added google oauth
Astrol99 66813ab
ops: supabase init
Astrol99 9008492
fix: migration history
Astrol99 846c47a
feat: spot db structure init
Astrol99 ca46303
feat: added local google oauth
Astrol99 64ef39e
fix: supabase RLS and indexings
Astrol99 fde3fa1
feat: added create spot modal
Astrol99 01cf780
chore: some cleanup
Astrol99 854ba70
feat: WORKING PERSISTENT AUTH FLOW
Astrol99 a83b7a0
feat: added database types with supazod
Astrol99 ffa44a9
fix: small auth flow error
Astrol99 495126d
style: updated colors
Astrol99 5041201
feat: added auth uid as default for user_id
Astrol99 0636592
feat: added spot creation
Astrol99 a9a023a
feat: added tagging feature
Astrol99 7b29286
feat: added spots list
Astrol99 4dc29c0
style: made it look better
Astrol99 2272721
style: added tab bar icons
Astrol99 2ac82a3
feat: added spot list refresh
Astrol99 c14e9f1
added owner
Astrol99 7a9f65a
feat: updated schema
Astrol99 61f1769
feat: added small loading shimmer
Astrol99 6976704
style: added tab bar icon active colors
Astrol99 d0887a0
feat: added image upload
Astrol99 581b0cb
refact: removed extra image item info
Astrol99 1f323d8
feat: added image upload!!!
Astrol99 3b2f8f5
fix: upsert slug tag conflict duplicates and removed created_by for tags
Astrol99 5fd8b4d
feat: fetched media coorelating to spot
Astrol99 1dbb7a8
feat: made storage buckets public
Astrol99 13722ff
pkgs: expo-clipboard
Astrol99 fd49288
feat: added image preview
Astrol99 c5f8167
feat: preview image uses user position index
Astrol99 cc18f7c
Merge branch 'main' of https://github.com/Longhorn-Developers/Longhor…
Astrol99 7fba92b
cleanup
Astrol99 09a27e8
fix: image upload to use Promise to prevent race condition
Astrol99 2bbb6d6
feat: hovering new spot button
Astrol99 b3dd56e
dep: bumped expo version to sdk 53 for expo-map support
Astrol99 2791798
feat: added basic map
Astrol99 1205725
feat: added location picker and image exif gps info
Astrol99 7de8d63
feat: added react hook form validation to location picker with zod
Astrol99 ff120fa
feat: call auth api to check on initial sessions
Astrol99 5c3ddf5
feat: saved geolocation data on backend
Astrol99 e3ceca2
feat: added db view of spots + tags + media + geo
Astrol99 e3a40ab
feat: added spot fetch with map markers
Astrol99 dd42523
feat: refetch spots on map screen + misc design updates
Astrol99 05f41bf
refact: used spots view instead of manual joining for explore
Astrol99 91fd774
feat: qualify of life stuff: fixed pin on map picker + image exif geo…
Astrol99 cb39a91
feat: removed groups for now
Astrol99 4e09cc0
feat: moved database types to supabase folder
Astrol99 db8763a
feat: moved spot creation to edge function
Astrol99 2eb1106
fix: zustand dependency bug
Astrol99 3165944
feat: added Safesearch APi
Astrol99 b8ca5da
Merge branch 'main' into feat/api-safesearch
Astrol99 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
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
19 changes: 0 additions & 19 deletions
19
longhorn-studies/app/(app)/(protected)/(tabs)/groups/index.tsx
This file was deleted.
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
65 changes: 51 additions & 14 deletions
65
longhorn-studies/app/(app)/(protected)/(tabs)/map/index.tsx
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,19 +1,56 @@ | ||
| import { View } from 'react-native'; | ||
| import { AppleMaps, GoogleMaps } from 'expo-maps'; | ||
| import { AppleMapsMarker } from 'expo-maps/build/apple/AppleMaps.types'; | ||
| import { useFocusEffect } from 'expo-router'; | ||
| import { useCallback, useState } from 'react'; | ||
| import { Platform } from 'react-native'; | ||
|
|
||
| import { Button } from '~/components/Button'; | ||
| import { useAuth } from '~/store/AuthProvider'; | ||
| import { PublicSpotsWithDetailsRowSchema } from '~/supabase/functions/new-spot/types/schemas_infer'; | ||
| import { supabase } from '~/utils/supabase'; | ||
|
|
||
| export default function Home() { | ||
| const { signOut } = useAuth(); | ||
| return ( | ||
| <View style={{ flex: 1, justifyContent: 'center', alignItems: 'center' }}> | ||
| <Button | ||
| title="Sign Out" | ||
| onPress={() => { | ||
| // The `app/(app)/_layout.tsx` will redirect to the sign-in screen. | ||
| signOut(); | ||
| }} | ||
| /> | ||
| </View> | ||
| const [spots, setSpots] = useState<PublicSpotsWithDetailsRowSchema[] | null>(null); | ||
|
|
||
| // Fetch spots from Supabase whenever the screen comes into focus | ||
| useFocusEffect( | ||
| useCallback(() => { | ||
| const fetchSpots = async () => { | ||
| const { data, error } = await supabase.from('spots_with_details').select(); | ||
|
|
||
| if (error) { | ||
| console.error('Error fetching spots:', error); | ||
| return; | ||
| } | ||
|
|
||
| if (data) { | ||
| console.log('Map fetched spots'); | ||
| setSpots(data); | ||
| } | ||
| }; | ||
|
|
||
| fetchSpots(); | ||
| }, []) | ||
| ); | ||
|
|
||
| return Platform.OS === 'ios' ? ( | ||
| <AppleMaps.View | ||
| style={{ flex: 1 }} | ||
| cameraPosition={{ coordinates: { latitude: 30.285, longitude: -97.739 }, zoom: 14.5 }} | ||
| markers={ | ||
| spots | ||
| ? spots.map<AppleMapsMarker>((spot) => ({ | ||
| id: spot.id ?? '', | ||
| title: spot.title ?? '', | ||
| tintColor: '#ff7603', | ||
| systemImage: 'bookmark.fill', | ||
| coordinates: { | ||
| latitude: spot.latitude ?? undefined, | ||
| longitude: spot.longitude ?? undefined, | ||
| }, | ||
| })) | ||
| : undefined | ||
| } | ||
| /> | ||
| ) : ( | ||
| <GoogleMaps.View style={{ flex: 1 }} /> | ||
| ); | ||
| } |
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.