Feature/refactor v 1 fe#22
Merged
Merged
Conversation
- Implements route guard for user-only routes like /profile - Checks for valid access token before rendering protected content - Redirects to login if authentication is missing
- Implements route guard for admin-only routes like /admin, /characters/edit/:id, /characters/new - Validates both authentication and admin role - Redirects unauthorized users appropriately
- Creates persistent navigation wrapper for all routes - Replaces old view-based routing with React Router structure - Integrates Navigation component as fixed header
- Implements fixed top navigation bar with glassmorphism effect - Shows different nav items based on authentication state - Includes Logo, Characters link, User menu (Profile, Admin, Logout), and Auth buttons
- Documents standardized button usage across the application - Shows primary (SpaceBtn), secondary (Button), and destructive button patterns - Part of Phase 1 design system standardization
- Replaced ViewRouter with React Router Routes - Added route guards (ProtectedRoute, AdminRoute) - Implemented routes: /, /characters, /characters/:id, /login, /register, /profile, /admin - Added nested routing with Layout component
- Removed view-based routing state (setView, view) - Updated handleLogout to use window.location for navigation - Simplified context to focus on auth state management
- Added useNavigate and useLocation hooks for client-side routing - Implemented href prop handling with smooth scroll for hash links - Fixed navigation to prevent full page reloads
- Replaced Link wrappers with direct Button/SpaceBtn href props - Updated navigation buttons to use href prop for routing - Removed unused Link import
- Fixed navigation buttons to use href props instead of Link wrappers - Ensured compatibility with updated Button and SpaceBtn components
…tion - Fixed all Link wrappers to use Button href props - Added Return to Home button at bottom of list - Fixed error state Return to Home navigation - Updated character name links and Edit buttons to use href prop
…tion - Fixed Back button to use Button href prop instead of Link wrapper - Fixed Edit button to use SpaceBtn href prop - Removed unused Link import
- Fixed navigation after successful login - Updated to work with React Router navigation patterns
- Fixed navigation after successful registration - Updated to work with React Router navigation patterns
- Fixed navigation after form submission - Updated to work with React Router navigation patterns
…ports - Added http://127.0.0.1:5173 to allowed origins - Added alternative Vite ports (5174) for development - Fixed CORS errors when accessing via 127.0.0.1 instead of localhost
- Added missing next() call when password not modified - Added next() after successful hashing - Changed error handling from throw to next(err) - Fixed new user registration password storage issue
- Removed obsolete view-based routing component - Replaced with React Router v6 implementation in App.jsx
- Added comprehensive Phase 1 Foundation completion summary - Documented all 8 implementation areas with completion status - Listed all 18 git commits with descriptions - Updated Status to Phase 1 Complete - Ready for Phase 2
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
UI Refactor Phrase 1.