How hamzaatef722/world-wise works
WorldWise is a travel journal: users sign in, explore a map, record visited cities with trip details, and browse saved cities or countries. The app routes between public informational pages and a protected journal workspace. City records are loaded and changed through shared context backed by a remote API; map clicks and reverse geocoding support creating entries. The source index documents several component relationships, but unsampled implementations are represented at their exact paths without inferring internal behavior beyond those references.
Main entry points: App.jsx Route composition · Map.jsx Interactive map · CitiesContext.jsx City state and actions · Form.jsx Trip entry form
Components 21
App and pages
- Route composition
src/App.jsx - Public pages
src/pages - Journal layout
src/pages/AppLayout.jsx - Page navigation
src/components/PageNav.jsx
Authentication
- Login form
src/pages/Login.jsx - Fake authentication
src/contexts/FakeAuthContext.jsx - Protected route
src/pages/ProtectedRoute.jsx - Signed-in user
src/components/User.jsx
City journal
- City and country lists
src/components/CityList.jsx - City detail
src/components/City.jsx - Trip entry form
src/components/Form.jsx - City state and actions
src/contexts/CitiesContext.jsx - Cities API
- Form controls and feedback
src/components/Button.jsx
Map and location
- Interactive map
src/components/Map.jsx - Browser location hook
src/hooks/useGeolocation.js - URL coordinates hook
src/hooks/useUrlPosition.js - Reverse geocoding
Other components
- Traveler
- Browser geolocation
- OpenStreetMap tiles
Connections 31
- Traveler → Route composition: uses
- Route composition → Public pages: routes to
src/App.jsx - Route composition → Journal layout: routes to
src/App.jsx - Route composition → Login form: routes to
src/App.jsx - Route composition → Protected route: protects route
src/App.jsx - Route composition → Fake authentication: provides auth
src/App.jsx - Route composition → City state and actions: provides city state
src/App.jsx - Public pages → Page navigation: uses
src/pages/Homepage.jsx - Login form → Page navigation: uses
src/pages/Login.jsx - Login form → Fake authentication: submits credentials
src/pages/Login.jsx - Protected route → Fake authentication: checks session
src/pages/ProtectedRoute.jsx - Journal layout → Interactive map: renders
src/pages/AppLayout.jsx - Journal layout → Signed-in user: renders
src/pages/AppLayout.jsx - Signed-in user → Fake authentication: reads session
src/components/User.jsx - Route composition → City and country lists: routes to
src/App.jsx - Route composition → City detail: routes to
src/App.jsx - Route composition → Trip entry form: routes to
src/App.jsx - City and country lists → City state and actions: reads city state
src/components/CityList.jsx - City detail → City state and actions: loads city
src/components/City.jsx - City detail → Form controls and feedback: uses back button
src/components/City.jsx - Trip entry form → City state and actions: creates city
src/components/Form.jsx - Trip entry form → URL coordinates hook: reads coordinates
src/components/Form.jsx - Trip entry form → Reverse geocoding: looks up location
src/components/Form.jsx - Trip entry form → Form controls and feedback: uses controls
src/components/Form.jsx - City state and actions → Cities API: loads and updates
src/contexts/CitiesContext.jsx - Interactive map → City state and actions: reads cities
src/components/Map.jsx - Interactive map → Browser location hook: gets position
src/components/Map.jsx - Interactive map → URL coordinates hook: reads coordinates
src/components/Map.jsx - Interactive map → Form controls and feedback: uses position button
src/components/Map.jsx - Interactive map → OpenStreetMap tiles: loads tiles
src/components/Map.jsx - Browser location hook → Browser geolocation: requests position
src/hooks/useGeolocation.js