Conversation
responsive ui fixes
notification popup added
idle state issue fixes
recent files get api added
Session changes
protected route and private route added
skip and forward 10 seconds in the video player changes
…previous folder again
Darkmode, lightmode and Ui responsive changes as well as Toggle accesslevel changes
lazy loading implemented for routes
api token ui changes
share files changes
Refresh token implemented
Sidebar and home page changes
notifications modified to the new cursor technique to improve performance
|
Caution Review failedThe pull request is closed. 📝 WalkthroughWalkthroughThis pull request introduces comprehensive authentication, session, and file management features: API token generation/revocation, PIN-based verification, active session management, file access-level controls (public/protected/private), a notification UI system, theme support (light/dark/system), multipart file uploads, and token refresh mechanisms with queue management. It also adds dependencies, lazy-loads routes, and updates settings and file management pages accordingly. Changes
Sequence DiagramssequenceDiagram
participant Client as Client/Browser
participant Axios as Axios Interceptor
participant API as Backend API
participant Queue as Request Queue
participant Storage as LocalStorage
participant App as App State
Note over Client,App: Token Refresh Flow with Queue Management
rect rgb(200, 220, 240)
Note over Client,Queue: Initial 401 Response (Multiple Concurrent Requests)
Client->>API: Request with Access Token
API-->>Axios: 401 Unauthorized
Client->>API: Request 2 with Access Token (concurrent)
API-->>Axios: 401 Unauthorized
end
rect rgb(220, 240, 220)
Note over Axios,Storage: Token Refresh Sequence
Axios->>Axios: isRefreshing = true
Axios->>Queue: Queue failed Request 1
Axios->>Queue: Queue failed Request 2
Axios->>API: POST /auth/refresh<br/>(with refresh_token)
API-->>Axios: New Access Token
end
rect rgb(240, 220, 200)
Note over App,Storage: Update State & Retry
Axios->>App: Update auth store<br/>(new access_token)
Axios->>Storage: Save new token
Axios->>Queue: Process queued requests
Queue->>API: Retry Request 1 (new token)
Queue->>API: Retry Request 2 (new token)
API-->>Queue: Success 200
Axios->>Axios: isRefreshing = false
end
rect rgb(240, 200, 200)
Note over Axios,App: Error Handling
alt Refresh Token Invalid
API-->>Axios: 401/403 on refresh
Axios->>App: Clear tokens<br/>logoutUser()
Axios->>Storage: Clear localStorage
Axios->>Client: Redirect to /login
end
end
Estimated code review effort🎯 4 (Complex) | ⏱️ ~60 minutes Poem
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: defaults Review profile: CHILL Plan: Pro ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (60)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary by CodeRabbit
New Features
Improvements
✏️ Tip: You can customize this high-level summary in your review settings.