[PR #1587] [MERGED] fix(long-term-memory): keyboard and focus fixes in Sources, Review, Vault, place picker and backup (1.4.85) #1578

Closed
opened 2026-10-23 04:03:21 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

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

Base: staging ← Head: fix(long-term-memory)/ui-keyboard-focus


📝 Commits (3)

  • 9d7118b fix(long-term-memory): keyboard and focus fixes in Sources, Review, Vault, place picker and backup (#1584)
  • beb553a Merge upstream/staging into fix(long-term-memory)/ui-keyboard-focus; release long-term-memory 1.4.85
  • 5bb6530 fix(long-term-memory): announce the Review context refresh to screen readers (#1584)

📊 Changes

17 files changed (+350 additions, -201 deletions)

View changed files

➕ artifacts/long-term-memory-1.4.85.zip (+0 -0)
📝 catalog/catalog.json (+6 -6)
📝 catalog/notes.json (+6 -6)
📝 catalog/v2/catalog.json (+6 -6)
📝 catalog/v2/notes.json (+6 -6)
📝 catalog/v3/catalog.json (+6 -6)
📝 catalog/v3/notes.json (+6 -6)
📝 packages/long-term-memory/CHANGELOG.md (+4 -0)
📝 packages/long-term-memory/client.js (+21 -21)
📝 packages/long-term-memory/manifest.json (+3 -3)
📝 packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/SourceScopeCombobox.tsx (+1 -0)
📝 packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/review/ReviewQueue.tsx (+21 -5)
📝 packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/settings/MaintenancePanel.tsx (+2 -0)
📝 packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/sources/SourcesWorkspace.tsx (+7 -2)
📝 packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/vault/MemoryVault.tsx (+117 -120)
📝 scripts/build-feature-packages.mjs (+1 -1)
📝 tests/long-term-memory-browser.regression.ts (+137 -13)

📄 Description

Pull request

Linked issue

Closes #1584

Why this change

  • The Long-Term Memory UI audit (2026-10-22) found five places where the keyboard or the screen gets stuck. In Sources, imported chat and character rows can only be opened with a mouse. In Review, accepting a change hides the whole queue while it reloads, so you lose your place and keyboard position. On a narrow panel, the Vault's Rename details and unsaved-changes dialogs open invisibly and freeze the page. Arrow keys in the place picker move the highlight out of sight. In backup settings, a hidden file input is an extra invisible Tab stop that screen readers name twice.
  • These are the audit's P1s. The P2 polish follows later as one bundled PR.

What changed

  • long-term-memory 1.4.85, client only. No server, storage, setting or string changes.

Sources: the row's name is a button, so it can be reached with Tab. Its click goes to the row's existing open handler.

 <ClickSurface role="listitem" onClick={open source in the workbench}>
   [selection checkbox]
-  <span>{title, summary}</span>
+  <button type="button" data-ltm-source-open>{title, summary}</button>
   [Import / row actions]

Review Queue: the queue hides only on first load or an error. A refetch keeps it on screen, with a small spinner beside the heading.

 notes = useQuery(["notes", "review-context", contextNoteIds],
+  placeholderData: keepPreviousData)          # a changed id list keeps the last context on screen
 reviewContextBusy    = !isError && (!isSuccess || isFetching)
+reviewContextLoading = reviewContextBusy && !isSuccess
-reviewContextReady   = isSuccess && !isFetching
+reviewContextReady   = isSuccess && !isFetching && !isPlaceholderData
-workspace hidden / loading StatusSurface when reviewContextBusy
+workspace hidden / loading StatusSurface when reviewContextLoading
+reviewContextRefreshing = reviewContextBusy && !reviewContextLoading
+<Loader2 aria-hidden data-ltm-review-context-refreshing> beside "Review Queue" when refreshing
+<span role="status" class="sr-only">"Loading memory context." when refreshing</span>   # always mounted, outside the panes

Every action, including Accept, stays off until reviewContextReady, so nothing is applied against a stale context while it reloads. Preflight results still reset when the context changes. Missing-source warnings still show only on a ready context.

Memory Vault: the two modal dialogs leave the navigator pane, which is hidden below 48rem while the details show. The blocks moved unchanged.

 <section data-ltm-surface="vault">
   <LtmWorkspace navigator={… list …
-    <dialog unsaved-changes/> <dialog rename-details/>
   } … />
+  <dialog unsaved-changes/> <dialog rename-details/>
 </section>
  • Place picker (SourceScopeCombobox): moveHighlight scrolls the highlighted option into view (block: "nearest").
  • Backup (MaintenancePanel): the hidden file input gets tabIndex={-1} and aria-hidden="true". The visible "Choose backup" button opens it.
  • Five browser regression cases in tests/long-term-memory-browser.regression.ts, tagged #1584. CHANGELOG entry. Rebuilt packages/long-term-memory client bundle, manifest, artifacts/long-term-memory-1.4.85.zip and catalog entries.

Package and security impact

  • Affected package IDs: long-term-memory
  • Engine compatibility impact: none.
  • New or changed permissions/entrypoints: none.
  • Restart, storage, update, or uninstall impact: none. Client UI only.

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

Manual verification notes

  • Each browser case fails on staging's copy of its file (reverted one at a time, rebuilt) and passes with the fix:
case (viewport)                          staging failure
place picker: ArrowDown x20              "the highlighted place is inside the visible list" (option top 1168, list 440-728)
vault Rename details (390x844)           dialog open but {"width":0,"height":0}, the frozen screen
backup input                             [tabIndex, aria-hidden] = [0, null], expected [-1, "true"]
review accept, reload held (390x844)     "the queue stays on screen while its context reloads"
sources: Tab from the imported filter    "Tab reaches the name of the imported source row"
  • The Review case holds the memory-context reload and checks, while it is held: the queue stays visible, the spinner shows, no review action is enabled, and the queue was never hidden. It runs on two accepts. The first keeps the same id list, and also checks that the next draft stays and Tab continues inside the queue. The second drops a merge target, so the id list changes. With only the placeholderData line removed, the second accept fails, so the test covers both parts of the fix.
  • On the implementation commit 9d7118b6d: the package typecheck, format and lint, the feature build, the catalog-lane, locale, catalog and release-notes checks, and every CI-listed Long-Term Memory suite run one by one (31, plus the regression helpers) passed. The host-styles guard reports 0 missing classes.
  • On the release commit beb553a61 (1.4.85, after merging staging, which only changed a Dottore workflow file): the rebuild is clean. Format and lint, git diff --check, the package typecheck, the catalog-lane, locale, catalog and release-notes checks, and the browser, installation, host-styles, feedback-clarity-ui, review-queue-ambiguous-link, loading, tab-keys, scope-targets, source-task and source-pagination suites pass. Hosted CI runs the full regression set.
  • Dottore repair, 5bb6530d1: a reload with the queue on screen is announced to screen readers again. An always-mounted sr-only status line (role="status", data-ltm-review-context-status) reads "Loading memory context." during a refresh, and the refresh condition is named reviewContextRefreshing. The Review case checks the line before, during and after each held reload, and fails against beb553a61. On 5bb6530d1 the same 17 land checks pass, and the rebuilt bundle, manifest, archive and catalog entries are in the commit.
  • Not installed through a running Engine; the installation suite installs the rebuilt archive.
  • Known limits, left for the P2 bundle: at 390px with the details pane showing, the spinner sits in the hidden list pane, and actions are still off meanwhile. During a reload, a memory that wasn't in the previous context reads "Loading memory context". Clicking a row's name leaves the row's focus ring, as clicking its icon buttons already did.

Documentation impact

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

UI evidence (if applicable)

No screenshots. The browser cases above measure the visible results: the dialog's size, the highlighted option's position, focus, and the queue's visibility.

🤖 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/1587 **Author:** [@Promansis](https://github.com/Promansis) **Created:** 10/22/2026 **Status:** ✅ Merged **Merged:** 10/22/2026 **Merged by:** [@Promansis](https://github.com/Promansis) **Base:** `staging` ← **Head:** `fix(long-term-memory)/ui-keyboard-focus` --- ### 📝 Commits (3) - [`9d7118b`](https://github.com/Pasta-Devs/Marinara-Agents/commit/9d7118b6da23769569363edc7dd12d873ca1dfce) fix(long-term-memory): keyboard and focus fixes in Sources, Review, Vault, place picker and backup (#1584) - [`beb553a`](https://github.com/Pasta-Devs/Marinara-Agents/commit/beb553a61c523267d23972091dddaf8dc417c4c1) Merge upstream/staging into fix(long-term-memory)/ui-keyboard-focus; release long-term-memory 1.4.85 - [`5bb6530`](https://github.com/Pasta-Devs/Marinara-Agents/commit/5bb6530d10736540a188323e109d7379e8b0b463) fix(long-term-memory): announce the Review context refresh to screen readers (#1584) ### 📊 Changes **17 files changed** (+350 additions, -201 deletions) <details> <summary>View changed files</summary> ➕ `artifacts/long-term-memory-1.4.85.zip` (+0 -0) 📝 `catalog/catalog.json` (+6 -6) 📝 `catalog/notes.json` (+6 -6) 📝 `catalog/v2/catalog.json` (+6 -6) 📝 `catalog/v2/notes.json` (+6 -6) 📝 `catalog/v3/catalog.json` (+6 -6) 📝 `catalog/v3/notes.json` (+6 -6) 📝 `packages/long-term-memory/CHANGELOG.md` (+4 -0) 📝 `packages/long-term-memory/client.js` (+21 -21) 📝 `packages/long-term-memory/manifest.json` (+3 -3) 📝 `packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/SourceScopeCombobox.tsx` (+1 -0) 📝 `packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/review/ReviewQueue.tsx` (+21 -5) 📝 `packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/settings/MaintenancePanel.tsx` (+2 -0) 📝 `packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/sources/SourcesWorkspace.tsx` (+7 -2) 📝 `packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/vault/MemoryVault.tsx` (+117 -120) 📝 `scripts/build-feature-packages.mjs` (+1 -1) 📝 `tests/long-term-memory-browser.regression.ts` (+137 -13) </details> ### 📄 Description # Pull request ## Linked issue Closes #1584 ## Why this change - The Long-Term Memory UI audit (2026-10-22) found five places where the keyboard or the screen gets stuck. In Sources, imported chat and character rows can only be opened with a mouse. In Review, accepting a change hides the whole queue while it reloads, so you lose your place and keyboard position. On a narrow panel, the Vault's Rename details and unsaved-changes dialogs open invisibly and freeze the page. Arrow keys in the place picker move the highlight out of sight. In backup settings, a hidden file input is an extra invisible Tab stop that screen readers name twice. - These are the audit's P1s. The P2 polish follows later as one bundled PR. ## What changed - `long-term-memory` 1.4.85, client only. No server, storage, setting or string changes. Sources: the row's name is a button, so it can be reached with Tab. Its click goes to the row's existing open handler. ```diff <ClickSurface role="listitem" onClick={open source in the workbench}> [selection checkbox] - <span>{title, summary}</span> + <button type="button" data-ltm-source-open>{title, summary}</button> [Import / row actions] ``` Review Queue: the queue hides only on first load or an error. A refetch keeps it on screen, with a small spinner beside the heading. ```diff notes = useQuery(["notes", "review-context", contextNoteIds], + placeholderData: keepPreviousData) # a changed id list keeps the last context on screen reviewContextBusy = !isError && (!isSuccess || isFetching) +reviewContextLoading = reviewContextBusy && !isSuccess -reviewContextReady = isSuccess && !isFetching +reviewContextReady = isSuccess && !isFetching && !isPlaceholderData -workspace hidden / loading StatusSurface when reviewContextBusy +workspace hidden / loading StatusSurface when reviewContextLoading +reviewContextRefreshing = reviewContextBusy && !reviewContextLoading +<Loader2 aria-hidden data-ltm-review-context-refreshing> beside "Review Queue" when refreshing +<span role="status" class="sr-only">"Loading memory context." when refreshing</span> # always mounted, outside the panes ``` Every action, including Accept, stays off until `reviewContextReady`, so nothing is applied against a stale context while it reloads. Preflight results still reset when the context changes. Missing-source warnings still show only on a ready context. Memory Vault: the two modal dialogs leave the navigator pane, which is hidden below 48rem while the details show. The blocks moved unchanged. ```diff <section data-ltm-surface="vault"> <LtmWorkspace navigator={… list … - <dialog unsaved-changes/> <dialog rename-details/> } … /> + <dialog unsaved-changes/> <dialog rename-details/> </section> ``` - Place picker (`SourceScopeCombobox`): `moveHighlight` scrolls the highlighted option into view (`block: "nearest"`). - Backup (`MaintenancePanel`): the hidden file input gets `tabIndex={-1}` and `aria-hidden="true"`. The visible "Choose backup" button opens it. - Five browser regression cases in `tests/long-term-memory-browser.regression.ts`, tagged #1584. CHANGELOG entry. Rebuilt `packages/long-term-memory` client bundle, manifest, `artifacts/long-term-memory-1.4.85.zip` and catalog entries. ## Package and security impact - Affected package IDs: `long-term-memory` - Engine compatibility impact: none. - New or changed permissions/entrypoints: none. - Restart, storage, update, or uninstall impact: none. Client UI only. ## 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` ### Manual verification notes - Each browser case fails on staging's copy of its file (reverted one at a time, rebuilt) and passes with the fix: ```text case (viewport) staging failure place picker: ArrowDown x20 "the highlighted place is inside the visible list" (option top 1168, list 440-728) vault Rename details (390x844) dialog open but {"width":0,"height":0}, the frozen screen backup input [tabIndex, aria-hidden] = [0, null], expected [-1, "true"] review accept, reload held (390x844) "the queue stays on screen while its context reloads" sources: Tab from the imported filter "Tab reaches the name of the imported source row" ``` - The Review case holds the memory-context reload and checks, while it is held: the queue stays visible, the spinner shows, no review action is enabled, and the queue was never hidden. It runs on two accepts. The first keeps the same id list, and also checks that the next draft stays and Tab continues inside the queue. The second drops a merge target, so the id list changes. With only the `placeholderData` line removed, the second accept fails, so the test covers both parts of the fix. - On the implementation commit 9d7118b6d: the package typecheck, format and lint, the feature build, the catalog-lane, locale, catalog and release-notes checks, and every CI-listed Long-Term Memory suite run one by one (31, plus the regression helpers) passed. The host-styles guard reports 0 missing classes. - On the release commit beb553a61 (1.4.85, after merging staging, which only changed a Dottore workflow file): the rebuild is clean. Format and lint, `git diff --check`, the package typecheck, the catalog-lane, locale, catalog and release-notes checks, and the browser, installation, host-styles, feedback-clarity-ui, review-queue-ambiguous-link, loading, tab-keys, scope-targets, source-task and source-pagination suites pass. Hosted CI runs the full regression set. - Dottore repair, 5bb6530d1: a reload with the queue on screen is announced to screen readers again. An always-mounted `sr-only` status line (`role="status"`, `data-ltm-review-context-status`) reads "Loading memory context." during a refresh, and the refresh condition is named `reviewContextRefreshing`. The Review case checks the line before, during and after each held reload, and fails against beb553a61. On 5bb6530d1 the same 17 land checks pass, and the rebuilt bundle, manifest, archive and catalog entries are in the commit. - Not installed through a running Engine; the installation suite installs the rebuilt archive. - Known limits, left for the P2 bundle: at 390px with the details pane showing, the spinner sits in the hidden list pane, and actions are still off meanwhile. During a reload, a memory that wasn't in the previous context reads "Loading memory context". Clicking a row's name leaves the row's focus ring, as clicking its icon buttons already did. ## Documentation impact - [ ] No documentation changes needed - [ ] Updated this README catalog and package guidance - [ ] Updated linked Marinara Engine documentation ## UI evidence (if applicable) No screenshots. The browser cases above measure the visible results: the dialog's size, the highlighted option's position, focus, and the queue's visibility. 🤖 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-10-23 04:03:21 +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#1578
No description provided.