← Back to Pull requests

fix(ui): keep MCP connection toasts above native dialogs #5871

Closed
unknown closed this pull request without merging on Oct 03, 2026 20:31 UTC
View on GitHub
unknown unknown commented on Sep 30, 2026 06:35 UTC
Author

Summary

Fixes #5870

Testing an MCP connection while its detail dialog is open now shows a readable, dismissible result above the backdrop. Astryx's shared toast viewport uses a stable portal host inside the active native modal, then opens its popover; raising z-index or reopening a popover outside the modal leaves the notification obscured or inert. The host moves back when the dialog closes without remounting toast rows. Environments without native popover and modal-selector support retain the inline viewport.

The change extends the existing Astryx dependency patch (source and distributed JavaScript), documents its removal condition, and adds browser hit-testing, keyboard-focus and dismissal assertions to the existing MCP detail story.

| Before | After |
| --- | --- |
| !Toast blurred behind dialog | !Toast readable above dialog |

Dark-mode capture

Verification

  • Regression reproduced before the patch: the toast-center hit test returned the native dialog, and the new Storybook assertion failed. It passes with the patch.

  • Storybook build and 10 focused smoke jobs passed: all six Toast stories, MCP detail, removal confirmation, and editor in light/dark.

  • Additional Chromium checks passed in light/dark at 1280 × 900 and light at 720 × 900; the same toast remains connected and clickable after the detail dialog closes.

  • Full @maka/ui test suite: 694 passed. Full @maka/desktop test suite: 3070 passed, including the LinkeDOM and minimal DOM component tests that exposed the missing capability guard in the initial CI run.

  • npm run lint, npm run build, npm run typecheck, and both required knip workspace checks passed.

  • Formatting passed for all Git-tracked files. npm run format:check also scanned 16 pre-existing untracked research/probe files and reported formatting errors there; those files are excluded from this PR.

  • The full workspace test suite was not run locally; CI will run it.
  • AI use

  • No generative tool made a substantive contribution

  • Generative tooling made a substantive contribution
  • Tool(s) and scope: Codex implemented the patch and regression assertions, ran validation, and prepared this issue/PR on behalf of @liuxiaocs7. The commit includes Generated-by: Codex.

    Checklist

  • Tests cover the change and fail without it

  • Lint, format, typecheck and the affected suites pass locally
  • Does this PR entail a change in behavior?

  • Yes — described under Summary above

  • No
  • Diff: 351 lines (+263 / -88) across 4 files Reviewer: hqhq1025 Review duration: 5156m
    All Vouch review confidence checks passed
    Residual risk 0.17 = Change Risk (0.42) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.42 · 351 lines diff across 4 files
    0.42
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.351
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #5871"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 42.5% (MEDIUM) · Higher = larger blast radius
    42.5%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 16.8% · Safe to merge
    16.8%
    Repository