Repository navigation
feat: 1-Click Live SLCM Sync Agent Bridge & Electric Teal Theme Overhaul - #3
Merged
Merged
Conversation
…ent, and performance optimizations
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Address the agent security/concurrency issues and fix the ineffective automatic onboarding sync.
Get a fresh assessment by requesting another Copilot review.
Review effort: Lite
Findings: 1
Open (2)
What changed in this PR
Adds a local 1-click SLCM synchronization agent, onboarding/settings integration, electric teal theming, lazy chat loading, and updated documentation.
Changes:
- Added modular Playwright login/sync flows and local HTTP agent.
- Integrated synchronization into onboarding and Settings.
- Replaced violet styling with teal theme tokens.
- Updated performance configuration, scripts, and documentation.
| File | Summary |
|---|---|
src/components/SyncModal.tsx |
Teal theme updates |
src/components/SubjectsView.tsx |
Teal theme updates |
src/components/SlotModal.tsx |
Teal theme and import cleanup |
src/components/SettingsView.tsx |
One-click sync UI and fallback upload |
src/components/SectionImportModal.tsx |
Teal theme updates |
src/components/OnboardingWizard.tsx |
SLCM onboarding sync flow; automatic matching requires correction |
src/components/Navigation.tsx |
Teal navigation styling |
src/components/HomeView.tsx |
Teal styling |
src/components/CourseModal.tsx |
Teal styling and defaults |
src/components/ChatWidget.tsx |
Teal chatbot styling |
src/components/CalendarView.tsx |
Teal styling and chart colors |
src/app/page.tsx |
Lazy-loaded chatbot |
src/app/login/page.tsx |
Teal login styling |
src/app/layout.tsx |
Teal selection styling |
src/app/globals.css |
Updated theme tokens |
scraper/sync.js |
Modular scraper implementation |
scraper/login.js |
Modular login implementation |
scraper/agent.js |
Local HTTP bridge; restrict origins and serialize requests |
README.md |
Sync setup documentation |
package.json |
Scraper agent script |
docs/ARCHITECTURE.md |
Agent architecture documentation |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
+11
to
+15
| function setCorsHeaders(res) { | ||
| res.setHeader('Access-Control-Allow-Origin', '*'); | ||
| res.setHeader('Access-Control-Allow-Methods', 'GET, POST, OPTIONS'); | ||
| res.setHeader('Access-Control-Allow-Headers', 'Content-Type'); | ||
| } |
Comment on lines
+127
to
+134
| apply: true, | ||
| merges: json.courses.map((c: any) => ({ | ||
| incomingCode: c.code, | ||
| incomingName: c.name, | ||
| present: c.present, | ||
| absent: c.absent, | ||
| targetCourseId: 'AUTO_MATCH', | ||
| })), |
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.


Summary of Upgrades
🔄 1. Seamless 1-Click Live SLCM Attendance Sync (No manual file picking!)
scraper/agent.js): Lightweight Node HTTP server onhttp://localhost:4747with CORS support forhttp://localhost:3000.GET /status: Validates session existence.POST /sync: Executes Playwright session interception directly, auto-prompting browser SSO/MFA if needed, and returns JSON payload directly in HTTP response body.scraper/login.jsandscraper/sync.jsso they function seamlessly both as imported modules and standalone CLI scripts.SettingsView.tsx: High-visibility "Sync Now (1-Click)" button. If the local daemon is not running, displays an instant copy-command card (cd scraper && node agent.js) and retry button.OnboardingWizard.tsx: Actionable "Synchronize Live SLCM Attendance?" step right after section timetable import.🎨 2. Electric Teal/Cyan Primary Accent Overhaul
#0D9488(teal-600) on warm cream paper (#FFFDF5).#2DD4BF(teal-400) on warm charcoal (#15131A).#F472B6), tertiary amber (#FBBF24), and mint (#34D399) remain as rotating geometric accents.Navigation,HomeView,SubjectsView,CalendarView,SettingsView,ChatWidget,CourseModal,SlotModal,SyncModal,SectionImportModal,login/page.tsx) with semantic theme tokens.⚡ 3. Performance & Bundle Optimizations
ChatWidgetlazy-loaded vianext/dynamicwithssr: false, reducing main thread hydration footprint.next/font/googlefor zero-render-blocking font preloading.Promise.allbatching for all database queries.📚 4. Comprehensive Documentation
README.mdanddocs/ARCHITECTURE.mddetailing agent daemon lifecycle, API routes, and setup instructions.