mirror of
https://github.com/tiennm99/try-gstack.git
synced 2026-05-26 17:56:08 +00:00
3b9feb3ecd8d13679980a4d56c2ae92ef3cf9721
2 Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
3b9feb3ecd |
v0.0.2.0 feat(module-3): drag-to-explore góc nội tiếp (lớp 9) (#2)
* chore: ignore .gstack/ deploy reports /land-and-deploy writes per-deploy artifacts to .gstack/deploy-reports/. Those shouldn't enter the repo. Captured here so future runs don't surface stale diffs. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * feat(geom-engine): circle module + inscribed-angle invariance test Add the second pure module per autoplan eng decision E1: src/geom-engine/circle.ts with circle(), pointOnCircle(), projectToCircle() (snap-to-circle for Module 3 drag), and angleAtVertex() (clamped against IEEE-754 drift to prevent acos NaN at exactly collinear angles). The killer-demo property test pins the inscribed-angle theorem as a CI gate: pick two fixed points A and B on a unit circle, sample 7 different M positions on the major arc, and assert all sampled inscribed angles AMB stay within 0.5° of the reference. If this test ever fails, Module 3's central premise is broken. 13 new unit tests, total 29 passing. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * feat(module-3): drag-to-explore góc nội tiếp page (lớp 9) Ship the first interactive theorem demo. Page lives at /lop-9/goc-noi-tiep/. Component: src/components/inscribed-angle.ts wires Pointer Events + setPointerCapture per autoplan eng decision E1. Drag M; on every pointermove, project the pointer to the circle (M = center + r·normalize(pointer − center)) so M never escapes the circle. Live readouts: ∠AMB at M (inscribed, pair1 red), ∠AOB at center O (central, pair2 teal). All listeners use AbortController keyed on astro:before-swap so view-transition navigation doesn't leak. Page: src/pages/lop-9/goc-noi-tiep.astro holds the SVG canvas (viewBox 400x400, touch-action: none scoped to canvas), theorem panel, and one worked example walking the 120°/60° canonical case. Astro bundles the script inline so the single page ships ~7KB total (including the entire geom-engine + component). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * feat(hub): link lớp 9 card to góc nội tiếp module Hub landing page now branches each grade card on grade.href: - live cards render as <a> with hover affordance (lớp 9 only, for now) - coming-soon cards stay as <li> with opacity 0.7 and "Sắp ra mắt" badge Status taxonomy extended: 'sap-ra-mat' | 'live' so future modules just flip the status when their page ships. i18n/vi.ts gains module3.* (intro, theorem, example, instruction copy) plus a new 'live' status string ("Khám phá") so every user-facing string stays inside vi.ts. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * chore: VERSION 0.0.2.0 + CHANGELOG entry First feature release. v0.0.2.0 = scaffold + Module 3 góc nội tiếp. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * chore: mark TODOS items completed by v0.0.2.0 - Drag M with circle constraint → DONE in src/components/inscribed-angle.ts - TheoremCanvas primitive first cut → DONE (built directly in Astro) - Theorem panel + worked examples → PARTIAL (1 of 3 examples shipped) Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> --------- Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> |
||
|
|
d8c7ed0e2c |
v0.0.1.0 chore: scaffold Hình Học Sống (Astro + GitHub Pages) (#1)
* chore: add gstack skill routing rules to CLAUDE.md Append a "## Skill routing" section so future Claude Code sessions in this repo route each task through the matching gstack skill (e.g., /investigate for bugs, /ship for PRs, /office-hours for product brainstorming). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * chore: scaffold Astro 5 + TypeScript strict with base /try-gstack/ Initialize the project per the autoplan-locked decisions: - Astro 5 SSG, output static, base path /try-gstack/ for GitHub Pages subdirectory hosting - TypeScript strict (Astro's strict tsconfig + path alias ~/* -> src/*) - @astrojs/sitemap for SEO meta - bun as the package manager (lockfile committed) Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * feat: Vietnamese landing page with Be Vietnam Pro + i18n stub Implement the locked design decisions D2 (typography) and D3 (palette) plus the i18n discipline from autoplan eng review: - Be Vietnam Pro single family (woff2, weights 400/500/700, vietnamese subset) self-hosted via @fontsource so KaTeX/CDN-blocking ISPs cannot break the page - font-feature-settings: "kern", "locl" for proper VN diacritic positioning - 17px body / 1.6 line-height / max-w-prose 56ch (denser than English) - 3-color SGK-aligned palette in tailwind config: pair1 #D7263D, pair2 #1B998B, pair3 #F46036 - BaseLayout with lang="vi", canonical URL, OpenGraph (vi_VN), X-Frame-Options DENY - src/i18n/vi.ts holds every user-facing string; t() helper resolves the active locale. Adding English later means adding en.ts; no string churn through templates. - Landing page lists three grade cards with "Sắp ra mắt" status (modules ship later) Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * test: bootstrap Vitest with pure geom-engine vec module Establish the math-engine boundary and test discipline from autoplan eng decision E2: - src/geom-engine/ is pure (no DOM imports allowed); first module is vec.ts - Vec2 helpers: vec, add, sub, scale, dot, len, dist, normalize, approxEqualLen - EPSILON_LEN=0.5 viewBox units justified vs ~4px human drag precision - scale() normalizes IEEE-754 -0 back to +0 so consumers don't see signed-zero ghosts - Vitest config gates the module at 95% line/function/statement, 90% branch - 16 unit tests covering commutativity, mutation safety, orthogonality, normalization, and EPSILON tolerance behavior Property tests via fast-check come with the first canvas module; this commit establishes the test scaffold so adding them later is one dependency away. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * ci: GitHub Actions test workflow + Pages deploy via deploy-pages@v4 Wire the autoplan-locked CI/CD pipeline (decision E3) for GitHub Pages hosting: - ci.yml: typecheck + tests + build on every PR and push to main - deploy.yml: build + actions/deploy-pages@v4 on push to main, concurrency-grouped so a force-push retry doesn't abort an in-flight rollback - Build env pins SITE_URL=https://tiennm99.github.io and SITE_BASE=/try-gstack so astro.config.mjs produces correct canonical/OG URLs against the subdirectory host - bun 1.3.13 pinned for both workflows Lighthouse-CI + size-limit gates deferred until the first canvas module ships (no JS bundle to budget yet — current pages are zero-JS). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * chore: VERSION 0.0.1.0 + CHANGELOG + RUNBOOK + README rewrite Initial 4-digit gstack version (matches package.json), changelog entry for the scaffold, operations runbook covering rollback and the deferred .vn domain trigger (500 sessions/30d OR 1 organic teacher share OR 5+ modules shipped). README rewritten as the project README for Hình Học Sống with the locked architectural decisions visible to teammates. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * chore: TODOS.md tracking deferred autoplan items Capture the deferred work surfaced by the /office-hours + /autoplan reviews so the backlog is visible to teammates and bisectable from the source-of-truth design doc. Organized by component (Phase 0 distribution, TheoremCanvas, Module 3/1/2, testing infrastructure, retention, domain) then priority P0–P4. Per the gstack TODOS.md format conventions. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> --------- Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> |