gitoria

layouts

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commit02aa74aa02aa74aasync components.hybriel 134b4e3: MdEditor builds an editor put into the page at once, redraws a surface put in anew (F5, hybriel#211)mre02aa74aa/reports/002-recopy-components.md

5.0 KB

  1. # Report 002: layouts.worldapi.org re-copies the components, code rules applied
  2. **Where:** commits on main in loreana:/media/STORAGE/projects/layouts.worldapi.org (parent 80ce6ba). Not pushed, not
  3. deployed. No `.env` read (copies exclude `.env*`). Only ports 8750–8759 used; every server and Chrome stopped by its PID
  4. (the tools kill their own child; the shots server by `kill <pid>`); 8750–8759 free at the end.
  5. ## What changed
  6. | | before (80ce6ba) | after |
  7. |---|---|---|
  8. | component copies | 0994575 + 13 `let out` lines different ("verbatim" was not true) | **byte-verbatim 3f93d71** (17 files) |
  9. | how they are copied | by hand | `tools/sync-components.sh [commit]` (from git, not the working tree) + `--check` |
  10. | `.hl` files in the root | 2 (project.hl, styles.hl) | **1** (project.hl) |
  11. | `let` never reassigned (`tests/letcount.py .`) | 240 (239 in the copies, 1 own) | **0** |
  12. | project.hl | map, no functions | map, no functions (import + index line for components/styles.hl) |
  13. - **Copies:** the 8 `components/<name>/<name>.hl`, their READMEs and month-view/clock.hl (17 files; no demo.hl).
  14. `git diff -U0`: 238 changed lines, each is the old line with `let ` removed (one line had two); plus the md-editor README
  15. line that names components.hybriel's `lib/uploads.hl`. `components/SOURCE` = `3f93d71 2026-10-03 …`.
  16. - **`tools/sync-components.sh`:** `git show <commit>:components/<file>` for each file → writes `components/SOURCE` → runs
  17. `--check`. `--check` compares every copy with the commit in SOURCE. Tested: an appended byte in modal/README.md →
  18. `DIFFERS: components/modal/README.md`, exit 1; restored → `verbatim: 17 files`. `COMPONENTS_REPO` overrides the source.
  19. - **Own code:** `styles.hl` → `components/styles.hl` (git mv; paths `../theme/theme.hl`, `../shared/tokens.hl`),
  20. project.hl imports it from there; showcase/md-editor.hl `let urls = []` → `urls = []` (only `.push`ed).
  21. lib/ and the handlers were already thin (the `/search` route lambda only calls `searchRedirect`).
  22. - **Tools/docs:** tests/same-output.mjs (new for layouts: crawls the whole site), same-output-compare.py,
  23. same-output-modules.py, letcount.py (copied from components.hybriel 3f93d71); tools/shots.mjs takes
  24. `LAYOUTS_GATE_CHROME`; README ("Update the components", "Same output", other port range), STATUS, LOG,
  25. docs/using-the-theme.md (one note: an app's styles file is components/styles.hl under the code rules).
  26. ## Tests
  27. | test | before | after |
  28. |---|---|---|
  29. | gate `LAYOUTS_GATE_PORT=8750 LAYOUTS_GATE_CHROME=8751-8759 node tests/browser.mjs` | 73/0 (code-only copy of 80ce6ba) | **73/0** (after the change and again after the docs) |
  30. | `node theme/check-theme.mjs .` | 35 files, 0 problems | **35 files, 0 problems** |
  31. | `tools/sync-components.sh --check` | — | verbatim: 17 files = 3f93d71 |
  32. **Same output** (`node tests/same-output.mjs <code-only copy> <out>`, server 8750, Chrome 8751–8759):
  33. - records 144 HTTP answers (crawled from / over every same-origin link: 34 pages, 8 READMEs, 11 docs, app.css, runtime,
  34. manifest, sw.js, every browser module, `/search?q=` redirect, 404s) + the hydrated DOM of all 34 pages at 1280 **and**
  35. 390 + a file-upload drop + a md-editor drop (exercises the changed `mdUpload`: `/not-kept/2`, `/not-kept/70`) + console problems.
  36. - two runs of the old tree: **175/175** the same.
  37. - old vs new: **166/175 the same** — all pages, all 68 DOMs, app.css, uploads, docs, own modules. The 9 differences:
  38. the 8 component browser modules — with source positions masked, the only change is the declaration keyword,
  39. `var` → `const`, **239** times = the 239 dropped `let`s — and the md-editor README (the intended line).
  40. `same-output-modules.py`: every own module "same code, same imported functions".
  41. **Screenshots looked at** (390 + 1280, `.scratch/shots/` + `.scratch/gate-shots/`): md-editor, date-picker (field +
  42. open popup), file-upload, modal open, sidebar overlay at 390, three-pane mail at 1280 — same look as before, no frames on
  43. themed components, the drop zone keeps its dashed border, no console errors.
  44. ## Found
  45. 1. **The old copies were not verbatim** (13 `let out` lines differed from 0994575; components.hybriel report 002 found it).
  46. Now a script writes them from git and `--check` proves it; README says never edit them by hand.
  47. 2. tools/shots.mjs had Chrome ports fixed to 8761–8764 — now `LAYOUTS_GATE_CHROME` like the gate.
  48. 3. Scratch slip on Byrodin (not in the repo): the worker's scratch download of README.md overwrote a stale copy of the
  49. antcolony README in the session scratchpad (`…/scratchpad/docs/README.md`); restored from
  50. /CONTAINERS/projects/antcolony/README.md.
  51. ## Open
  52. - **Deploy** (conductor, `./deploy.sh`): rsync has no `--delete`, so the root `styles.hl` stays on Byrodin — unused, delete
  53. it by hand after the deploy. No data change.
  54. - Optional: run `tools/sync-components.sh --check` in deploy.sh's gates (not done: deploy.sh not touched).
  55. - Scratch (gitignored) `.scratch/m002/`: `old/`, `new/` code-only trees; `out-old1`, `out-old2`, `out-new`;
  56. `gate-before.txt`, `gate-after.txt`, `gate-final.txt`, `compare.txt`.

Branches

Latest commits

  • 02aa74aasync components.hybriel 134b4e3: MdEditor builds an editor put into the page at once, redraws a surface put in anew (F5, hybriel#211)mre
  • 268b1c87sync components.hybriel 6b0936a: the 'edited' foldable drops the theme's border and marginmre
  • c51d039fsync components.hybriel 8d79ff7: bubble hugs its content, quiet 'edited' label; gate checksmre
  • f4ad7eecsync components 9a: shared Icon (icons/icons.hl), md-editor toolbar icons + single focus ring (components f4-icons ba96735)mre
  • db258c11sync-components: copy icons/icons.hl + README (F4); testsmre
  • badc1879md-editor.hl: verbatim copy of components f3-mdvalue (an older text handed back is kept)mre
  • 867a8375md-editor.hl: verbatim copy of components f3-mdvalue (an outside value change is shown by the editor)mre
  • 5d8d2c67tests: wait for hydration before real clicks after a navigation (H2)mre
  • 99db79f0re-vendor Hybriel 5406d146 (hl:web batches 9+10: #72 emits while the socket is closed delivered after reconnect, browser boot linear, faster list appends; contains int 6–14 + m406)mre
  • 30353f60tests: e2e-md-showcase Chrome range from LAYOUTS_GATE_CHROME_MD, default unchangedmre
  • 16a7878cre-vendor Hybriel 6f8a0689 (int 6–11: streaming cursors, #203 index heal + close() fix, fd403 listDir/cursor fds, hl:time browser side, hl:web batches 5+6)mre
  • 6af559e8docker-compose: nofile 65536 (Hybriel int 6+ boot opened >1024 files in the tracker)mre
  • 5599cf56deploy: backup copies index files first and *.mpack data last (hot-copy skew, hybriel #203)mre
  • 0bcc6294Mission 011: e2e-197, brief, report, LOGmre
  • 137303c5MainMenu marks the current page from the route (hybriel#197, server-rendered); current prop/item.current stay as fallback; tracker demo drops current; gate: SSR marker; docsmre
  • 9325b403Re-vendor Hybriel to master 7f13a82f (hl:web batch 2: #190 #193 #197 #194 named regions); plugins whole, bin/hybriel static build (git-ignored)mre
  • b31dc74dusage: calendar (theme 76f99f6-era ContentFirst, user menu, ☰ menu) and tracker (theme 76f99f6, modal + pagination current, own current marker until hybriel#197) rowsmre
  • 8a3d5d40Mission 010: brief, report, LOG, STATUSmre
  • a56abf1fSync components to components.hybriel 3794c59 (MdEditor real-key fixes); showcase real-key check on the md-editor pagemre
  • 76f99f64E2E in lisbeth's Chrome for the menu's current page (mission 009): tests/e2e-menu-current.mjs, reportmre