Commit Graph

13 Commits

Author SHA1 Message Date
LiBr
f778060b79 refactor: Rename 2026-04-13 17:39:00 +08:00
LiBr
0d4c9bf8d9 Merge pull request #1 from lbr77/refactor/react-tailwind-docker
Migrate frontend to React + Tailwind, add Docker + tests
2026-04-13 17:29:33 +08:00
Lakr
3f79912b5c ci: add Docker image publish workflow to GHCR
Build on push to main and version tags, push to ghcr.io with
semver/branch/sha tags. PRs get build-only validation.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-13 17:21:11 +08:00
Lakr
aef3c71ed4 fix: show 2FA errors in modal, fix stale device check, add dark mode
- Keep TwoFactorModal open after code submit; display server-side
  errors inline instead of silently closing the modal
- handlePair now returns PairedDeviceInfo so handleInstall uses the
  fresh UDID instead of stale closure state
- Add explicit /wisp/ location in nginx.conf returning 502 to prevent
  SPA fallback from swallowing websocket upgrades
- Add prefers-color-scheme dark mode via CSS custom property overrides;
  replace hardcoded rgba/hex with color-mix() for automatic adaptation
2026-04-13 17:18:07 +08:00
Lakr
afec333aa0 refactor: migrate frontend to React + Tailwind, add Docker + tests
Replace the vanilla-TS innerHTML frontend with a type-checked React
component tree (React 19 + Tailwind v4 + Vite).

Frontend:
- 14 components: Header, Stepper, LoginPage, LoginModal, SignPage,
  DropZone, DevicePicker, ProgressCard, SavedAccountsList, TrustModal,
  TwoFactorModal, Button, Field, Chip, Modal
- lib/ extracts: storage (10 localStorage keys preserved), pair-record,
  account-session, log-parser, ids, use-log hook
- flows/ encapsulate async pair/login/sign/install with dependency injection
- Accounts page as main view with Add Account modal
- Fullscreen progress overlay during sign/install
- Account selector + device picker on Sign page
- Security notice in login modal (server trust warning)
- All addLog calls mirrored to console.log for devtools debugging

Build:
- bun run dev: submodule init + install + wasm dist + vite + wrangler
- bun run setup: one-shot project bootstrap
- Docker: multi-stage bun build → nginx on :3000
- build:wasm:dist copies pre-built src→dist (no Rust/Emscripten needed)
- jszip/node-forge/fflate pre-bundled for CJS→ESM conversion

Tests:
- 163 vitest tests (happy-dom): all lib, components, App integration,
  WASM dist artifact checks, libcurl Apple connectivity, anisette init
  error handling

Cleanup:
- Delete yarn.lock (bun.lock canonical), expand .gitignore
- Remove README.zh.md, rewrite README.md + AGENTS.md
- Update libcurl.js submodule to f65d440 (CI build artifacts)
2026-04-13 17:02:45 +08:00
LiBr
1f9a7e005f update submodules 2026-04-13 15:59:22 +08:00
LiBr
3ed8ddc5dc submodule update 2026-04-10 20:39:13 +08:00
LiBr
72123cc922 more refactor 2026-04-10 20:34:14 +08:00
LiBr
8d31144741 refactor directory 2026-04-10 08:53:51 +08:00
libr
41d3f700b9 feat: add two-factor authentication modal and handling 2026-03-03 15:30:28 +08:00
libr
da0a5e29cc add backend & full support for cloudflare workers 2026-03-03 15:22:40 +08:00
libr
8dada7f9e3 feat: new style 2026-03-03 12:43:04 +08:00
libr
ae4c58e56d init 2026-03-03 10:12:22 +08:00