[PR #1590] [MERGED] fix(gacha-forge): keep the cast and outfit theme lists in place when ticking (1.8.15) #1939

Closed
opened 2026-11-07 16:38:07 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Agents/pull/1590
Author: @SpicyMarinara
Created: 10/22/2026
Status: ✅ Merged
Merged: 10/22/2026
Merged by: @SpicyMarinara

Base: staging ← Head: claude/gacha-forge-cast-scroll


📝 Commits (2)

  • 52d72aa fix(gacha-forge): keep the cast and outfit theme lists in place when ticking (1.8.15)
  • ad50f47 chore(gacha-forge): record the bundles' hand edits since the 1.8.12 drop

📊 Changes

13 files changed (+326 additions, -24 deletions)

View changed files

➕ artifacts/gacha-forge-1.8.15.zip (+0 -0)
📝 catalog/catalog.json (+6 -6)
📝 catalog/notes.json (+6 -0)
📝 catalog/v2/catalog.json (+6 -6)
📝 catalog/v2/notes.json (+6 -0)
📝 catalog/v3/catalog.json (+6 -6)
📝 catalog/v3/notes.json (+6 -0)
📝 packages/gacha-forge/CHANGELOG.md (+3 -0)
📝 packages/gacha-forge/README.md (+4 -0)
➕ packages/gacha-forge/bundle-patches.json (+154 -0)
📝 packages/gacha-forge/client.js (+2 -2)
📝 packages/gacha-forge/manifest.json (+3 -3)
📝 tests/gacha-forge-location-ids.regression.mjs (+124 -1)

📄 Description

Pull request

Important

Contributions target staging. Only SpicyMarinara may promote this repository's staging branch to main.
Outside and first-time contributors also require an approving review from SpicyMarinara.

Linked issue

Closes #1589

Why this change

The maintainer reported that every time they tick a character to add to their cast in Gacha Forge's world creation, the list jumps back to the top.

The cause is WebKit, which every iPhone browser and Safari on the Mac use. Each tick rebuilds the list's rows (innerHTML in w()), and WebKit drops the scroll position of a box whose rows are rebuilt, along with the boxes around it. Chromium keeps it.

  • The list reset predates 1.8.14. w() is byte-identical in 1.8.13.
  • 1.8.14 made the whole world-creation page one scroll area on a sideways phone, so that page jumps up as well.
  • 1.8.14's obScroll is not involved: a build with it emptied resets the same way.
  • The outfit theme list (vi()) has the same bug.

What changed

Package gacha-forge 1.8.14 → 1.8.15:

  • The cast list stays where it was when you tick a character, change its star rating or reorder it. On a sideways phone the world-creation page stays put too.
    • Before rebuilding the rows, w() notes the scroll position of the list and every scrolling box around it, and puts them back afterwards.
    • The cast list in the Expand pop-up is covered by the same code.
  • The outfit theme list (vi()) does the same.
  • 1.8.14's behaviour is unchanged: a new step still starts at the top, and an error still scrolls into view.
  • A side effect of the same fix: in WebKit, typing in the cast search or the library finishing loading now also keeps the list's position (clamped as results shrink) instead of jumping to the top. Chrome already behaved this way.
  • Release metadata and build outputs:
    • Version 1.8.15 in manifest.json and the in-bundle version constant.
    • A new in-game changelog entry; the previous top entry is now labelled 1.8.14.
    • CHANGELOG.md and README.md entries.
    • Rebuilt with node scripts/build-gacha-forge-package.mjs: manifest hash and size, artifacts/gacha-forge-1.8.15.zip (older zips kept), catalog v1/v2/v3 entries and notes.
  • tests/gacha-forge-location-ids.regression.mjs:
    • pins both save/restore pairs around the rebuild;
    • runs the shipped statements in vm against a fake frame → grid → list chain whose innerHTML setter resets them the way WebKit does, and checks the positions come back;
    • checks the in-game changelog labels.
    • It fails against the 1.8.14 bundle, without the theme restore, and with a mislabelled entry.

Process note: like 1.8.13 and 1.8.14, this is a hand edit to the pre-built bundle, whose source lives outside this repository. ponytail: comments mark both fixes for mirroring into the package's upstream source.

Bundle patch record (ad50f476f, for Dottore's "digest certifies bytes no build can regenerate"). packages/gacha-forge/bundle-patches.json names the last upstream drop, SonaGat3's 1.8.12 (aa0cece0f, by sha256 and size). It then lists every hand edit since, as find/replace steps:

  • client.js: 1.8.13, 1.8.14 and 1.8.15 (21 edits);
  • server.mjs: 1.8.13 (3 edits).

Every other payload is byte-identical to that drop. tests/gacha-forge-location-ids.regression.mjs, which CI runs, now:

  • undoes the edits on the committed files and checks they give back the recorded 1.8.12 bytes;
  • redoes them and checks they give the manifest's sha256 and size;
  • requires the newest client.js patch to be the manifest version, so the next hand edit must be recorded too.

The file is not a payload: the builder ignores it, and nothing in the manifest, zip or catalogs changed. A new upstream drop should carry these edits and then reset the record to its own base.

Package and security impact

  • Affected package IDs: gacha-forge
  • Engine compatibility impact: none (engine.min/maxExclusive unchanged)
  • New or changed permissions/entrypoints: none
  • Restart, storage, update, or uninstall impact: none. The executable change is limited to saving and restoring scrollTop around two list rebuilds.

Validation

  • node scripts/validate-catalog.mjs passes locally
  • git diff --check passes locally
  • Rebuilt every affected manifest, payload, artifact, and catalog entry
  • Installed or updated the affected package through Marinara Engine
  • Checked supported modes, restart behavior, and uninstall cleanup
  • Read and followed CONTRIBUTING.md

Agent-run checks on head ad50f476f (the fix is 52d72aaf9; ad50f476f adds the bundle patch record):

  • npm run check passed.
  • node scripts/test-catalog-lanes.mjs passed.
  • node scripts/validate-package-locales.mjs passed.
  • node scripts/validate-catalog.mjs passed (41 packages; v2=41, v3=41).
  • node scripts/tests/catalog-release-notes.regression.mjs passed.
  • node tests/gacha-forge-location-ids.regression.mjs passed.
  • git diff --check is clean.
  • Rerunning the builder after the commit changed nothing.

Playwright WebKit harness (each cell is a scroll position):

Run 1.8.14 1.8.15
Cast, sideways phone, tick a card (page 196, list 150) page 74, list 0 page 196, list 150
Cast, sideways phone, then 5★ 74 / 0 196 / 150
Cast, desktop, tick (grid 53, list 150) 0 / 0 53 / 150
Expand pop-up cast list (300) 0 300
Outfit theme list, sideways phone and desktop (200) 0 200
  • After the fix, Next and Back still land at the top (0), and an error still scrolls to its place.
  • Chromium was unaffected before and after.

Manual verification notes

Still needs a human:

  • Manually verify on a real iPhone (portrait isn't available for world creation; use landscape) that ticking several characters, changing stars and reordering keep the list where it was.
  • Manually verify the same on that iPhone for outfit themes.
  • Manually verify in desktop Safari that ticking characters keeps the list in place.
  • Manually verify that searching the cast list still behaves sensibly. It now keeps the position instead of jumping to the top.
  • Manually verify the update from 1.8.14 → 1.8.15 through Download Agents on an Engine staging checkout.

Documentation impact

  • No documentation changes needed
  • Updated this README catalog and package guidance
  • Updated linked Marinara Engine documentation

packages/gacha-forge/README.md and CHANGELOG.md have the 1.8.15 entry.

UI evidence (if applicable)

Not attached. Harness measurements are above.

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Pasta-Devs/Marinara-Agents/pull/1590 **Author:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Created:** 10/22/2026 **Status:** ✅ Merged **Merged:** 10/22/2026 **Merged by:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Base:** `staging` ← **Head:** `claude/gacha-forge-cast-scroll` --- ### 📝 Commits (2) - [`52d72aa`](https://github.com/Pasta-Devs/Marinara-Agents/commit/52d72aaf9a1cb440a158714f4928493950c18f22) fix(gacha-forge): keep the cast and outfit theme lists in place when ticking (1.8.15) - [`ad50f47`](https://github.com/Pasta-Devs/Marinara-Agents/commit/ad50f476f5dfd57286aa9bbb9b8abcef3a9b4c02) chore(gacha-forge): record the bundles' hand edits since the 1.8.12 drop ### 📊 Changes **13 files changed** (+326 additions, -24 deletions) <details> <summary>View changed files</summary> ➕ `artifacts/gacha-forge-1.8.15.zip` (+0 -0) 📝 `catalog/catalog.json` (+6 -6) 📝 `catalog/notes.json` (+6 -0) 📝 `catalog/v2/catalog.json` (+6 -6) 📝 `catalog/v2/notes.json` (+6 -0) 📝 `catalog/v3/catalog.json` (+6 -6) 📝 `catalog/v3/notes.json` (+6 -0) 📝 `packages/gacha-forge/CHANGELOG.md` (+3 -0) 📝 `packages/gacha-forge/README.md` (+4 -0) ➕ `packages/gacha-forge/bundle-patches.json` (+154 -0) 📝 `packages/gacha-forge/client.js` (+2 -2) 📝 `packages/gacha-forge/manifest.json` (+3 -3) 📝 `tests/gacha-forge-location-ids.regression.mjs` (+124 -1) </details> ### 📄 Description # Pull request > [!IMPORTANT] > Contributions target `staging`. Only `SpicyMarinara` may promote this repository's `staging` branch to `main`. > Outside and first-time contributors also require an approving review from `SpicyMarinara`. ## Linked issue Closes #1589 ## Why this change The maintainer reported that every time they tick a character to add to their cast in Gacha Forge's world creation, the list jumps back to the top. The cause is WebKit, which every iPhone browser and Safari on the Mac use. Each tick rebuilds the list's rows (`innerHTML` in `w()`), and WebKit drops the scroll position of a box whose rows are rebuilt, along with the boxes around it. Chromium keeps it. - The list reset predates 1.8.14. `w()` is byte-identical in 1.8.13. - 1.8.14 made the whole world-creation page one scroll area on a sideways phone, so that page jumps up as well. - 1.8.14's `obScroll` is not involved: a build with it emptied resets the same way. - The outfit theme list (`vi()`) has the same bug. ## What changed Package `gacha-forge` 1.8.14 → **1.8.15**: - **The cast list stays where it was** when you tick a character, change its star rating or reorder it. On a sideways phone the world-creation page stays put too. - Before rebuilding the rows, `w()` notes the scroll position of the list and every scrolling box around it, and puts them back afterwards. - The cast list in the Expand pop-up is covered by the same code. - **The outfit theme list** (`vi()`) does the same. - 1.8.14's behaviour is unchanged: a new step still starts at the top, and an error still scrolls into view. - A side effect of the same fix: in WebKit, typing in the cast search or the library finishing loading now also keeps the list's position (clamped as results shrink) instead of jumping to the top. Chrome already behaved this way. - Release metadata and build outputs: - Version 1.8.15 in `manifest.json` and the in-bundle version constant. - A new in-game changelog entry; the previous top entry is now labelled 1.8.14. - `CHANGELOG.md` and `README.md` entries. - Rebuilt with `node scripts/build-gacha-forge-package.mjs`: manifest hash and size, `artifacts/gacha-forge-1.8.15.zip` (older zips kept), catalog v1/v2/v3 entries and notes. - `tests/gacha-forge-location-ids.regression.mjs`: - pins both save/restore pairs around the rebuild; - runs the shipped statements in `vm` against a fake frame → grid → list chain whose `innerHTML` setter resets them the way WebKit does, and checks the positions come back; - checks the in-game changelog labels. - It fails against the 1.8.14 bundle, without the theme restore, and with a mislabelled entry. **Process note:** like 1.8.13 and 1.8.14, this is a hand edit to the pre-built bundle, whose source lives outside this repository. `ponytail:` comments mark both fixes for mirroring into the package's upstream source. **Bundle patch record (`ad50f476f`, for Dottore's "digest certifies bytes no build can regenerate").** `packages/gacha-forge/bundle-patches.json` names the last upstream drop, SonaGat3's 1.8.12 (`aa0cece0f`, by sha256 and size). It then lists every hand edit since, as find/replace steps: - `client.js`: 1.8.13, 1.8.14 and 1.8.15 (21 edits); - `server.mjs`: 1.8.13 (3 edits). Every other payload is byte-identical to that drop. `tests/gacha-forge-location-ids.regression.mjs`, which CI runs, now: - undoes the edits on the committed files and checks they give back the recorded 1.8.12 bytes; - redoes them and checks they give the manifest's sha256 and size; - requires the newest `client.js` patch to be the manifest version, so the next hand edit must be recorded too. The file is not a payload: the builder ignores it, and nothing in the manifest, zip or catalogs changed. A new upstream drop should carry these edits and then reset the record to its own base. ## Package and security impact - Affected package IDs: `gacha-forge` - Engine compatibility impact: none (`engine.min`/`maxExclusive` unchanged) - New or changed permissions/entrypoints: none - Restart, storage, update, or uninstall impact: none. The executable change is limited to saving and restoring `scrollTop` around two list rebuilds. ## Validation - [ ] `node scripts/validate-catalog.mjs` passes locally - [ ] `git diff --check` passes locally - [ ] Rebuilt every affected manifest, payload, artifact, and catalog entry - [ ] Installed or updated the affected package through Marinara Engine - [ ] Checked supported modes, restart behavior, and uninstall cleanup - [ ] Read and followed `CONTRIBUTING.md` Agent-run checks on head `ad50f476f` (the fix is `52d72aaf9`; `ad50f476f` adds the bundle patch record): - `npm run check` passed. - `node scripts/test-catalog-lanes.mjs` passed. - `node scripts/validate-package-locales.mjs` passed. - `node scripts/validate-catalog.mjs` passed (41 packages; v2=41, v3=41). - `node scripts/tests/catalog-release-notes.regression.mjs` passed. - `node tests/gacha-forge-location-ids.regression.mjs` passed. - `git diff --check` is clean. - Rerunning the builder after the commit changed nothing. Playwright WebKit harness (each cell is a scroll position): | Run | 1.8.14 | 1.8.15 | |---|---|---| | Cast, sideways phone, tick a card (page 196, list 150) | page 74, list 0 | page 196, list 150 | | Cast, sideways phone, then 5★ | 74 / 0 | 196 / 150 | | Cast, desktop, tick (grid 53, list 150) | 0 / 0 | 53 / 150 | | Expand pop-up cast list (300) | 0 | 300 | | Outfit theme list, sideways phone and desktop (200) | 0 | 200 | - After the fix, Next and Back still land at the top (0), and an error still scrolls to its place. - Chromium was unaffected before and after. ### Manual verification notes Still needs a human: - Manually verify on a real iPhone (portrait isn't available for world creation; use landscape) that ticking several characters, changing stars and reordering keep the list where it was. - Manually verify the same on that iPhone for outfit themes. - Manually verify in desktop Safari that ticking characters keeps the list in place. - Manually verify that searching the cast list still behaves sensibly. It now keeps the position instead of jumping to the top. - Manually verify the update from 1.8.14 → 1.8.15 through Download Agents on an Engine `staging` checkout. ## Documentation impact - [ ] No documentation changes needed - [ ] Updated this README catalog and package guidance - [ ] Updated linked Marinara Engine documentation `packages/gacha-forge/README.md` and `CHANGELOG.md` have the 1.8.15 entry. ## UI evidence (if applicable) Not attached. Harness measurements are above. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-07 16:38:07 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Agents#1939
No description provided.