Files
try-gstack/package.json
T
tiennm99 638af314ea v0.0.3.0 feat(module-1): drag-to-explore tam giác bằng nhau (lớp 7, SSS) (#3)
* feat(geom-engine): triangle module + position-strict congruentSSS

Third pure module under src/geom-engine/. Adds Triangle type, sides() (returns
named AB / BC / CA lengths), and congruentSSS() with position-strict semantics:
labels define the correspondence (AB↔A'B', BC↔B'C', CA↔C'A'), permuted matches
are NOT counted as congruent. This preserves SGK pedagogy where the labels and
the matched-pair encoding (color + tick marks) carry meaning.

10 new unit tests: identical, translated-congruent, similar-not-congruent (2x scale),
shape-different, EPSILON_LEN tolerance (within and just outside), label-permutation
rejection, and symmetry of the relation.

Total tests: 29 → 39.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* feat(module-1): drag-to-explore tam giác bằng nhau (lớp 7, SSS)

Second interactive theorem demo. Page at /lop-7/tam-giac-bang-nhau/.

Component: src/components/congruence-sss.ts owns 6 draggable vertices (3 per
triangle), each independently captured via setPointerCapture per vertex.
Drag-clamping (16px viewBox padding) keeps every vertex on-screen.

Encoding per autoplan Decision D3 (a11y + SGK-correct in one move):
  AB / A'B' → pair1 #D7263D + 1 tick
  BC / B'C' → pair2 #1B998B + 2 ticks
  CA / C'A' → pair3 #F46036 + 3 ticks
Tick marks are SVG line segments perpendicular to each side at the midpoint,
spaced 5 viewBox-units apart for multi-tick. Redrawn live during drag.

Page: viewBox 400x300 (4:3, side-by-side triangles), single 6KB page including
inline JS bundle (entire geom-engine + canvas controller, minified).

Live side-length readout table + green badge "Hai tam giác bằng nhau (c.c.c)"
that appears when SSS condition holds within EPSILON_LEN. Badge has
role="status" + aria-live="polite" so screen readers announce the moment the
triangles become congruent.

Rigid-motion overlay animation EXPLICITLY DROPPED per autoplan — color+tick
match is the success state.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* feat(hub): activate lớp 7 card linking to tam giác bằng nhau module

Status flips from sap-ra-mat to live; href points at the new module.
i18n/vi.ts gains module1.* strings (intro, instruction, theorem, example,
SGK-aligned theorem statement) so every user-facing string still routes
through t() — adding English in the future is one en.ts file away.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* chore: VERSION 0.0.3.0 + CHANGELOG + TODOS update

v0.0.3.0 = scaffold + Module 3 (góc nội tiếp) + Module 1 (tam giác bằng nhau).
2 of 3 MVP modules now live. Module 2 (tam giác đồng dạng) is next.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* chore: TODOS Module 1 reflects v0.0.3.0 (SSS shipped)

Original P1 items "SSS detector" + "SGK tick-mark encoding" already moved to
Completed in the previous commit. Replace the still-pending M1 section with
the actual remaining work: P2 toggles for SAS/ASA/AAS/cạnh huyền cases, P3 for
extra examples.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-30 00:17:26 +07:00

29 lines
755 B
JSON

{
"name": "try-gstack",
"version": "0.0.3.0",
"private": true,
"type": "module",
"description": "Hình Học Sống — Interactive Vietnamese THCS geometry visualizer (lớp 7-9). Static site, drag-to-explore theorems.",
"scripts": {
"dev": "astro dev",
"build": "astro build",
"preview": "astro preview",
"typecheck": "astro check",
"test": "vitest run",
"test:watch": "vitest"
},
"dependencies": {
"@astrojs/sitemap": "^3.4.0",
"@astrojs/tailwind": "^6.0.0",
"@fontsource/be-vietnam-pro": "^5.2.0",
"astro": "^5.14.0",
"tailwindcss": "^3.4.17"
},
"devDependencies": {
"@astrojs/check": "^0.9.9",
"@types/node": "^22.10.0",
"typescript": "^5.7.0",
"vitest": "^3.2.0"
}
}