f6819d50b7fa1c812ae3f6ab95c04137c3a537ea
Resolves #72 ## Description This PR implements the theme toggle mechanism, client-side persistence, and comprehensive light mode style overrides for the mobile reader layout in **NexusReader**. ### Key Changes 1. **ThemeService & State Management**: - Enhanced `ThemeService` with `InitializeAsync` and `ToggleTheme` using JS Interop. - Synchronized theme state changes via `OnThemeChanged` event. 2. **Local Storage Persistence & FOUC Prevention**: - Added client-side script in `App.razor` and MAUI `index.html` to instantly apply `.theme-light` from `localStorage` before prerendering/rendering to prevent a Flash of Unthemed Content (FOUC). - Created `theme.js` containing JS helper methods (`themeInterop.isLightMode`, `themeInterop.setLightMode`) to interface with `localStorage` and `document.documentElement` class list. 3. **UI Theme Toggle**: - Added a minimalist glassmorphic theme toggle button in the header of the `ReaderCanvas.razor` with dynamic transitions and icon morphing between sun and moon SVG icons. 4. **Light Mode Stylesheets Overrides**: - Added detailed light mode scoped styles (`.theme-light`) for the `ReaderCanvas` and the bottom-sheet `GlobalIntelligence` AI chat panel, utilizing earthy gray text (`#2d2a26`) on warm paper-like backgrounds (`rgba(244, 241, 234, 0.95)` / `#faf8f5`) to maintain high-quality aesthetic consistency. ### Verification - Solution built successfully without errors (`dotnet build NexusReader.slnx --no-restore`). - Scoped CSS isolation checked and validated for both Web and MAUI contexts. --------- Co-authored-by: Marek Jasiński <jasins.marek@gmail.com> Reviewed-on: #71 Co-authored-by: Antigravity <antigravity@google.com> Co-committed-by: Antigravity <antigravity@google.com>
feat(infra): Docker-compose configuration and environment-specific security guards for Beta deployment to Test environment (#56)
feat(mobile-ux): implement theme toggle, client-side persistence, and light mode style overrides (#71)
feat(infra): Docker-compose configuration and environment-specific security guards for Beta deployment to Test environment (#56)
feat(infra): Docker-compose configuration and environment-specific security guards for Beta deployment to Test environment (#56)
feat(infra): Docker-compose configuration and environment-specific security guards for Beta deployment to Test environment (#56)
style(ui): refactor reader layout grid, fix focus mode layout collapse, fix SVG rendering dots, reorganize intelligence toolbar (#69)
📖 Nexus Reader
Nexus Reader is a state-of-the-art, cross-platform Blazor .NET 10 immersive e-book reader, powered by Native AOT, Clean Architecture, CQRS, and interactive D3.js Relationship Graphs built on vector-based AI semantics.
✨ Features & Architecture Highlights
📁 Ingestion & Description persistence
- Extracted and persistent book descriptions from EPUB package metadata during book ingestion.
- The
Descriptionfield propagates cleanly from theEbookentity through Mapster toLastReadBookDtoandUserProfileDto.
🔗 Deep-Link Routing
- Implemented deep-link route activation:
/reader/{bookId}?chapter=N. - Allows instant resume of reading session coordinates and loads the specific chapter chapter directly via URL query parameters.
🛡️ Downstream AI Resilience
- Standard resilience engine in
DependencyInjection.csutilizing the Polly package (ai-retry). - Automatically intercepts, handles, and retries on both rate-limits (
429 Too Many Requests) and downstream capacity overloads (503 ServiceUnavailable/high demand).
⚙️ Concurrent Request Deduplication
- Multi-client InteractiveAuto Blazor circuit synchronization is backed by a thread-safe active task registry in
KnowledgeServicewhich ensures that identical concurrent requests await a single shared task instance, eliminating redundant LLM queries.
🛠️ Build & Verification Gate
Ensure the dotnet workload matches the active SDK, and compile the full solution utilizing:
dotnet build NexusReader.slnx --no-restore
Run test suite:
dotnet test --no-restore
🗄️ Database Migrations
Automatic database migrations at startup (MigrateAsync()) have been disabled to ensure compatibility with Native AOT compilation and prevent locking issues in multi-instance environments.
To apply database migrations locally, run the EF Core migration command from the solution root:
dotnet ef database update --project src/NexusReader.Infrastructure --startup-project src/NexusReader.Web
Description
Languages
C#
46.2%
HTML
25.8%
CSS
23%
JavaScript
4.1%
Shell
0.8%
Other
0.1%