openpencil/tests
Anton A S 036f486571 Fix layout blowup from 100×100 text fallback, skip compute for read-only AI tools
Two fixes:

1. layout.ts: Add estimateTextSize() fallback (~0.6 × fontSize per char)
   for when MeasureFunc returns null (font not loaded) or CanvasKit is
   unavailable. Previously fell back to child.width/child.height which
   defaults to 100×100 for new nodes, blowing up every HUG container.

2. ai/tools.ts: Only call computeAllLayouts + requestRender + push undo
   for mutating tools (def.mutates). Read-only tools (describe, get_jsx,
   node_bounds, etc.) were triggering full layout recompute on every call,
   wasting cycles and potentially destabilizing layouts during AI sessions.
2026-03-13 10:17:07 +03:00
..
e2e Fix double-click rename in layer tree and pages panel 2026-03-08 22:58:38 +03:00
engine Fix layout blowup from 100×100 text fallback, skip compute for read-only AI tools 2026-03-13 10:17:07 +03:00
figma Playwright visual regression testing with Figma CDP reference 2026-02-28 07:32:15 +03:00
fixtures Fix CJK text garbled when font unavailable (#89) 2026-03-10 16:58:57 +03:00
helpers Merge PR #70: E2E test coverage + mutation unit tests 2026-03-07 23:47:00 +03:00