Skip to content

Tasking: offer "open in a new window" when there's no Beacon Remote tab - #456

Merged
OSPFNeighbour merged 1 commit into
master-devfrom
fix/tasking-open-in-new-window-fallback
Sep 9, 2026
Merged

Tasking: offer "open in a new window" when there's no Beacon Remote tab#456
OSPFNeighbour merged 1 commit into
master-devfrom
fix/tasking-open-in-new-window-fallback

Conversation

@OSPFNeighbour

@OSPFNeighbour OSPFNeighbour commented Sep 9, 2026

Copy link
Copy Markdown
Collaborator

What

When Tasking tries to open a URL in the Beacon Remote tab (openURLInBeacon) and there's no tab to reuse — none registered, or it was closed — the warning alert now:

  • Explains the specific cause (no remote tab / tab closed / sent from the remote tab itself / unknown) and what to do about it, instead of echoing the raw background-script string.
  • Includes an "Open this page in a new window" link to the target URL (target="_blank" rel="noopener noreferrer").
  • Is centre-aligned and persists until dismissed, then auto-dismisses once the link is clicked.

Also guards against an undefined sendMessage response (previously threw on response.message).

Changes

  • chromeRunTime.js — reason mapping + link + click-to-dismiss.
  • windowAlert.jsshowAlert returns the alert id; new closeAlert(id) helper (the timeout path reuses it).

Testing

  • npx eslint clean on both files.
  • Manual: not yet exercised in the extension — needs a check that the alert renders and the link opens/dismisses.

🤖 Generated with Claude Code

When openURLInBeacon can't reuse a Beacon Remote tab (none registered, or
it was closed), the warning alert now includes a link that opens the
target URL in a new window. Also guards against an undefined sendMessage
response.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@OSPFNeighbour
OSPFNeighbour force-pushed the fix/tasking-open-in-new-window-fallback branch from 94f64c5 to fc8facd Compare September 9, 2026 06:26
@OSPFNeighbour
OSPFNeighbour changed the base branch from refactor/beaconclient-core to master-dev September 9, 2026 06:26
@OSPFNeighbour
OSPFNeighbour merged commit 157f5c7 into master-dev Sep 9, 2026
1 check passed
@OSPFNeighbour
OSPFNeighbour deleted the fix/tasking-open-in-new-window-fallback branch September 9, 2026 06:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant