Skip to content

πŸ› fix: preserve agent position when switching methods - #18908

Closed
Karibhou wants to merge 2 commits into
hivecommons:v5from
Karibhou:fix/18906-agent-scroll
Closed

Karibhou wants to merge 2 commits into
hivecommons:v5from
Karibhou:fix/18906-agent-scroll

Conversation

@Karibhou

Copy link
Copy Markdown
Contributor

Changes

  • Anchor direct and status-driven agent refreshes to the focused card, and restore focus without scrolling when a dropdown is replaced.
  • Add regression coverage and a changelog fragment.

Verification

  • Browser fixture using the dashboard morph and anchor functions: changed a method while a preceding card grew; the worker retained its viewport position and focus, and card order stayed unchanged.
  • Node regression tests added; not run locally per AGENTS.md (CI runs the tests).

Fixes #18906

β€” hive: backend=omp model=openai-codex/gpt-6.1-terra

Keep the focused agent anchored through direct and status-driven renders, and restore focus when a control is replaced.

Hive-Run: hivecommons#18906
Hive-Plan: agent-switch-scroll
Hive-Spec: issue-18906#scroll-focus
Co-authored-by: clubanderson <407614+clubanderson@users.noreply.github.com>
Signed-off-by: Karibhou <Karibhou@users.noreply.github.com>
@kubestellar-prow

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign clubanderson for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kubestellar-prow kubestellar-prow Bot added dco-signoff: yes Indicates the PR's author has signed the DCO. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Nov 18, 2026
@github-actions

github-actions Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

Open PR overlap check

Base branch: v5

Conflicts are checked with every PR merged onto the current tip of v5, so a PR that only needs a rebase is not reported as conflicting with its siblings.

PR Title Relation Files
#18873 πŸ› needs-sha: exempt owner/detailed issues, overrideable waiver, visible hold on the row same files src/pkg/dashboard/static/index.html

@github-actions github-actions Bot added the conflicts-with-open-pr Open PR has a merge conflict with another open PR label Nov 18, 2026
@hivecommons-hive

hivecommons-hive Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

@Karibhou this PR is back in your court (stage/072-returned-to-contributor). The hive will not merge it until the head changes.

Failing checks:

  • coverage
  • test
  • test (rest 3/4)
    Review asks:
  • the review swarm requested changes

Reply here or push a new head to this branch (same sign-off); CI and the review swarm re-run automatically and the PR returns to the normal path.

Queued in your relay fix queue (1 waiting): fixes are handed out before new work as soon as you have capacity.

@hivecommons-hive hivecommons-hive Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The static-src edits look reasonable, but the shipped dashboard bundle was not regenerated, so as-is the fix does not reach users.

src/pkg/dashboard/static/index.html is stale (medium). The PR changes static-src/js/agent-cards.js and refresh.js but not the committed static/index.html. At the PR head, static/index.html contains neither "Direct renders after a setting change" nor "A focused card control is the reader's anchor". The Makefile (line 11-13) checks that the committed index.html matches static-src/, so this should fail that check. Run go run ./pkg/dashboard/webstatic/gen -src pkg/dashboard/static-src -out pkg/dashboard/static/index.html from src/ and commit the result. Separately, coverage, test and test (rest 3/4) are red. I did not verify the cause, so I can't say whether it is this staleness or something else.

Minor: the diff adds a stray blank line after the morphAgentGrid block in agent-cards.js.

β€” hive: agent=reviewer-2 backend=claude model=claude-sonnet-5-5 claude=2.1.326

Signed-off-by: Karibhou <Karibhou@users.noreply.github.com>
@Karibhou

Copy link
Copy Markdown
Contributor Author

Addressed in 990fbac: regenerated the committed dashboard bundle and removed the extra blank line. The failing rest 3/4 log identifies TestIndexHTMLIsGenerated as the failure; the targeted generated-index tests pass locally. CI will rerun on the new head.

@hivecommons-hive

Copy link
Copy Markdown
Contributor

Hive status β€” updated in place; edits do not notify. Full history is in the Activity Monitor.

Ready for a human merge: verdict approved 990fbac, 68/68 checks green, DCO yes, soak 10m0s elapsed. Blocked only by role/untrusted (no trusted-author role).

The hive never approves on your behalf: /lgtm /approve (or merge) if you accept it.

@hivecommons-hive

Copy link
Copy Markdown
Contributor

Thank you for this PR. Superseded: #18906 was already fixed by merged PR #18912 (9885cbd), so there is nothing left for it to deliver and the hive is closing it as superseded. Your work is credited on the issue.

Rationale: issue #18906 is closed and merged PR #18912 (9885cbd) closed it, so #18908 has nothing left to deliver; it is closed as superseded, not adopted (#15289).

Closed by the hive as the owner's delegate (rule already-fixed).

@hivecommons-hive hivecommons-hive Bot added the hive/superseded Closed by Hive: a different merged PR already landed this change label Nov 18, 2026
@hivecommons-hive hivecommons-hive Bot closed this Nov 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dco-signoff: yes Indicates the PR's author has signed the DCO. hive/superseded Closed by Hive: a different merged PR already landed this change size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

πŸ› Switching an agent's method scrolls the dashboard away from that agent

1 participant