Commit Graph

9 Commits

Author SHA1 Message Date
argenis de la rosa
c280ae5045 fix(web): address CodeRabbit review feedback
Fixes issues identified in PR #3076:

1. mock-server.mjs: Fix HTTP line ending escape sequence
   - Changed `\\r\\n\\r\\n` to `\r\n\r\n` for proper HTTP CRLF terminators

2. App.tsx: Add accessibility attributes to pairing form
   - Added aria-label, aria-invalid, aria-describedby to input
   - Added id="pairing-error" and role="alert" to error message

3. Header.tsx: Add accessible name to logout button
   - Added aria-label for screen readers on mobile (icon-only) view

4. Layout.tsx: Guard localStorage access with try-catch
   - Prevents runtime errors when storage is blocked/unavailable

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-09 16:43:08 -04:00
argenis de la rosa
3f5c57634b feat(web): replace native language selects with custom dropdown and fix RTL text alignment
This commit modernizes the language selector UI across the ZeroClaw web dashboard by replacing
native <select> elements with a shared custom dropdown component featuring styled flag icons,
proper RTL/LTR text direction support, and consistent left-aligned text for all languages.

Changes:
- Add LanguageSelector component with custom dropdown, flag badges, and check mark for selected option
- Wire document direction updates on locale change for Arabic, Hebrew, Urdu, and other RTL languages
- Fix RTL text alignment in dropdown options by applying dir attribute only to text spans
- Update pairing dialog and authenticated header to use the shared LanguageSelector
- Add locale metadata helpers: getLanguageOption, getLanguageOptionLabel, getLocaleDirection, applyLocaleToDocument
- Add Vitest configuration and unit tests for i18n helpers
- Add Playwright E2E tests verifying all 31 locales with flag visibility and lang/dir attributes

Testing:
- Unit tests: 5 passed (npm run test:unit)
- Build: passed (npm run build)
- E2E tests: 34 passed (npx playwright test)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-09 13:50:21 -04:00
argenis de la rosa
c56c66a21d Revert "feat(web): port electric dashboard UI from source repo"
This reverts commit b248d40abc.
2026-03-07 17:56:15 -05:00
argenis de la rosa
b248d40abc feat(web): port electric dashboard UI from source repo 2026-03-07 17:37:46 -05:00
reidliu41
2fb72438f8
fix(gateway): skip pairing dialog in web UI when require_pairing is false 2026-02-24 16:03:00 +08:00
argenis de la rosa
1a0e5547d7
fix(web): call doctor endpoint with authenticated POST 2026-02-24 16:02:59 +08:00
Will Sarg
f3dcbc99d6
chore(license): normalize repo to MIT OR Apache-2.0 (#1271) 2026-02-21 11:31:21 -05:00
chumyin0912@gmail.com
179e7949c2 fix(gateway): align dashboard API client and embed built web assets 2026-02-21 16:14:01 +08:00
Zeki Kocabıyık
79337c76e8 feat(gateway): add embedded web dashboard with React frontend
Add a complete web management panel for ZeroClaw, served directly from
the binary via rust-embed. The dashboard provides real-time monitoring,
agent chat, configuration editing, and system diagnostics — all
accessible at http://localhost:5555/ after pairing.

Backend (Rust):
- Add 15+ REST API endpoints under /api/* with bearer token auth
- Add WebSocket agent chat at /ws/chat with query param auth
- Add SSE event stream at /api/events via BroadcastObserver
- Add rust-embed static file serving at /_app/* with SPA fallback
- Extend AppState with tools_registry, cost_tracker, event_tx
- Extract doctor::diagnose() for structured diagnostic results
- Add Serialize derives to IntegrationStatus, CliCategory, DiscoveredCli

Frontend (React + Vite + Tailwind CSS):
- 10 dashboard pages: Dashboard, AgentChat, Tools, Cron, Integrations,
  Memory, Config, Cost, Logs, Doctor
- WebSocket client with auto-reconnect for agent chat
- SSE client (fetch-based, supports auth headers) for live events
- Full EN/TR internationalization (~190 translation keys)
- Dark theme with responsive layouts
- Auth flow via 6-digit pairing code, token stored in localStorage

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-21 16:14:01 +08:00