Skip to content

Fix metric filter tag overflow - #20220

Merged
James Newton-King (JamesNK) merged 1 commit into
mainfrom
jamesnk/fix-metric-filter-tag-overflow
Sep 18, 2026
Merged

James Newton-King (JamesNK) merged 1 commit into
mainfrom
jamesnk/fix-metric-filter-tag-overflow

Conversation

@JamesNK

Copy link
Copy Markdown
Member

Description

Metric filter tags could truncate the first value while several other values were still visible. This change keeps each tag at its natural width while multiple tags are displayed, moves values that do not fit into the overflow count, and only ellipsizes the first tag when it is the sole displayed value and still cannot fit.

The filter overflow now uses the same zero threshold as resource URL overflow. Its button-specific styling keys off FluentOverflow's hidden markers because text overflow on the wrapper does not truncate a nested button label.

User-facing behavior

Metric dimension values remain fully readable whenever multiple tag buttons are displayed. A tag receives an ellipsis only when it is the only displayed value and the available width is too narrow for its full text.

Screenshots / Recordings

This PR includes UI changes. Please add screenshots or screen recordings so reviewers can evaluate the visual changes without running locally.

  • For before/after comparisons, place them side-by-side or label them clearly.
  • For interactive changes (animations, transitions, new flows), prefer a short screen recording (GIF or video).
  • If you cannot capture visuals now, note what scenario to test and mark this section as TODO.

TODO: Add before/after screenshots. The integrated browser rendered the comparison correctly, but locally saved captures were blank. To verify manually, open a metric with several dimension values at a width where some values overflow. Multiple visible tags should remain complete; constrain the tag area until one value remains to verify that only the final visible tag is ellipsized.

Validation

  • dotnet test --project tests/Aspire.Dashboard.Components.Tests/Aspire.Dashboard.Components.Tests.csproj --no-launch-profile -- --filter-class "*.ChartFiltersTests" --filter-not-trait "quarantined=true" --filter-not-trait "outerloop=true"
  • Native AOT Terminals playground dashboard: verified three complete peer.id tags with four values overflowed at 962 px viewport width.
  • Constrained the tag overflow host to 80 px: verified one visible tag with ellipsis.

Fixes # (issue)

Checklist

  • Is this feature complete?
    • Yes. Ready to ship.
    • No. Follow-up changes expected.
  • Are you including unit tests for the changes and scenario tests if relevant?
    • Yes
    • No
  • Did you add public API?
    • Yes
      • If yes, did you have an API Review for it?
        • Yes
        • No
      • Did you add <remarks /> and <code /> elements on your triple slash comments?
        • Yes
        • No
    • No
  • Does the change make any security assumptions or guarantees?
    • Yes
      • If yes, have you done a threat model and had a security review?
        • Yes
        • No
    • No

@github-actions

Copy link
Copy Markdown
Contributor

🚀 Dogfood this PR with:

⚠️ WARNING: Do not do this without first carefully reviewing the code of this PR to satisfy yourself it is safe.

curl -fsSL https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 20220

Or

  • Run remotely in PowerShell:
iex "& { $(irm https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 20220"

@github-actions

This comment has been minimized.

Copilot AI 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.

🟢 Approval recommended

The focused changes match the described behavior and introduce no unresolved correctness issues.

Pull request overview

Fixes metric filter tag overflow so visible tags remain readable and only a lone constrained tag is ellipsized.

Changes:

  • Uses a zero overflow threshold.
  • Applies ellipsis styling only when the first tag is the sole visible value.
  • Verifies the threshold in component tests.
File summaries
File Description
ChartFilterTags.razor Sets the overflow threshold to zero.
ChartFilterTags.razor.css Refines tag sizing and ellipsis behavior.
ChartFiltersTests.cs Verifies the configured overflow threshold.
Review details
  • Files reviewed: 3/3 changed files
  • Comments generated: 0
  • Review effort level: Balanced

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

Copilot AI 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.

🟢 Approval recommended

The focused changes align with the described behavior and introduce no unresolved issues.

Review details
  • Files reviewed: 3/3 changed files
  • Comments generated: 0 new
  • Review effort level: Balanced

@github-actions

Copy link
Copy Markdown
Contributor

Tests selector

10 / 99 PR test projects · 3 PR jobs, from 3 changed files.

Selected PR test projects (10 / 99)

Aspire.Cli.EndToEnd.Tests, Aspire.Dashboard.Components.Tests, Aspire.Dashboard.Tests, Aspire.Hosting.DotnetTool.Tests, Aspire.Hosting.JavaScript.Tests, Aspire.Hosting.RemoteHost.Tests, Aspire.Hosting.Testing.Tests, Aspire.Managed.Tests, Aspire.Playground.Tests, Aspire.Templates.Tests

Selected PR jobs (3)

cli-starter-validation, extension-e2e, polyglot


How these were chosen — grouped by what changed

⚠️ 7 of the 10 selected test projects come from a single change — src/Aspire.Dashboard/Components/Controls/Chart/ChartFilterTags.razor.

🔧 src/Aspire.Dashboard/Components/Controls/Chart/ChartFilterTags.razor (changed source)
→ 7 via the project graph: Aspire.Dashboard.Tests, Aspire.Hosting.DotnetTool.Tests (2 hops), Aspire.Hosting.JavaScript.Tests, Aspire.Hosting.RemoteHost.Tests (2 hops), Aspire.Hosting.Testing.Tests, Aspire.Managed.Tests (2 hops), Aspire.Playground.Tests (2 hops)

📦 affected project Aspire.Dashboard
→ 1 test: Aspire.Templates.Tests

📦 affected project Aspire.Managed
→ 1 test: Aspire.Cli.EndToEnd.Tests

🧪 tests/Aspire.Dashboard.Components.Tests/Controls/ChartFiltersTests.cs (changed test)
→ 1 directly: Aspire.Dashboard.Components.Tests

Job reasons

Job Triggered by
cli-starter-validation affected project Aspire.Managed
extension-e2e • src/Aspire.Dashboard/Components/Controls/Chart/ChartFilterTags.razor, src/Aspire.Dashboard/Components/Controls/Chart/ChartFilterTags.razor.css
• affected project Aspire.Dashboard
polyglot affected project Aspire.Managed

Selection computed for commit af65c0b.

@github-actions

Copy link
Copy Markdown
Contributor

Retrying the failed CI jobs for this pull request from the CI run attempt. The rerun is being tracked in the rerun attempt.

@JamesNK
James Newton-King (JamesNK) merged commit e60b105 into main Sep 18, 2026
435 of 438 checks passed
@JamesNK
James Newton-King (JamesNK) deleted the jamesnk/fix-metric-filter-tag-overflow branch September 18, 2026 06:00
@microsoft-github-policy-service microsoft-github-policy-service Bot added this to the 13.6 milestone Sep 18, 2026
aspire-repo-bot Bot added a commit to microsoft/aspire.dev that referenced this pull request Sep 18, 2026
Documents the fix in microsoft/aspire#20220 where dimension filter tag
values keep their natural width while multiple tags are displayed, and
are only ellipsized when a single tag is the sole displayed value and
too narrow to fit.

Co-authored-by: Copilot <[email protected]>
@aspire-repo-bot

Copy link
Copy Markdown
Contributor

Pull request created: #1696

Generated by PR Documentation Check · auto · 42.3 AIC · ⌖ 6.07 AIC · ⊞ 18K

@aspire-repo-bot

Copy link
Copy Markdown
Contributor

📝 Documentation has been drafted in microsoft/aspire.dev#1696 targeting release/13.6.

Drafted a documentation clarification for #20220 (metric filter tag overflow fix).

  • Updated src/frontend/src/content/docs/dashboard/explore.mdx: clarified the Metrics page dimension filter tag description to state that tag values keep their natural width while multiple tags are visible, and are only ellipsized when a single tag is the sole displayed value and too narrow to fit.

Note

This draft PR needs human review before merging.

@github-actions

Copy link
Copy Markdown
Contributor

⚠️ CI Failure Analysis: Possible Flaky Test(s)

The CI build failed due to test failure(s) that appear unrelated to the PR changes. These may be flaky tests.

Suspected flaky test(s):

  • Aspire Blazor browser debugger E2E hits a managed breakpoint for hosted-global in job Tests / Run VS Code extension E2E tests / VS Code extension E2E (Linux, browser-debugger)
    • Error: Failed to apply E2E control revision 1789712257741: Error: Timed out after 299565ms waiting for Blazor WASM root session for resource 'hosted-global'. Last error: .
    • Stack Trace (first frames):
Error: Failed to apply E2E control revision 1789712257741: Error: Timed out after 299565ms waiting for Blazor WASM root session for resource 'hosted-global'. Last error: <none>. State: {"debugSessions":[{"id":"dfce4a6f-d879-4a19-a83d-a86dbd3e37e8","type":"monovsdbg_wasm","name":"Wasm Managed Debugger", ... }
  • Why likely flaky: Timing-related debug session attach timeout in VS Code extension E2E infra, unrelated to the PR which only modifies Aspire.Dashboard Razor/CSS/test files. Matches recurring known pattern with 20 prior occurrences.
  • Aspire Blazor browser debugger E2E hits a managed breakpoint for hosted-per-page in job Tests / Run VS Code extension E2E tests / VS Code extension E2E (Linux, browser-debugger)
    • Error: Failed to apply E2E control revision 1789712257744: Error: Timed out after 299609ms waiting for Blazor WASM root session for resource 'hosted-per-page'. Last error: .
    • Stack Trace (first frames):
Error: Failed to apply E2E control revision 1789712257744: Error: Timed out after 299609ms waiting for Blazor WASM root session for resource 'hosted-per-page'. Last error: <none>. State: {"debugSessions":[{"id":"ce912e8f-0d13-4915-b07c-a5c896872cda","type":"monovsdbg_wasm","name":"Wasm Managed Debugger", ... }
  • Why likely flaky: Timing-related debug session attach timeout in VS Code extension E2E infra, unrelated to the PR which only modifies Aspire.Dashboard Razor/CSS/test files. Matches recurring known pattern with 20 prior occurrences.
  • Aspire dynamic debug configuration E2E "after each" hook for "does not launch an AppHost when the ambiguous AppHost picker is dismissed" in job Tests / Run VS Code extension E2E tests / VS Code extension E2E (Windows, dynamic-debug-configuration)
    • Error: Dynamic debug configuration E2E teardown failed. 1. Error: EBUSY: resource busy or locked, rmdir 'C:\Users\runneradmin\AppData\Local\Temp\aev-7gE1WH\workspace.e2e-dynamic-debug\ambiguous'
    • Stack Trace (first frames):
AggregateError: Dynamic debug configuration E2E teardown failed.
1. Error: EBUSY: resource busy or locked, rmdir 'C:\Users\runneradmin\AppData\Local\Temp\aev-7gE1WH\workspace\.e2e-dynamic-debug\ambiguous'
    at runE2eTeardown (out\test-e2e\test-e2e\helpers\fixtures.js:217:15)
    at async Context.<anonymous> (out\test-e2e\test-e2e\dynamicDebugConfiguration.e2e.test.js:62:9)
  • Why likely flaky: Windows file-locking race during E2E temp workspace cleanup, unrelated to the PR which only modifies Aspire.Dashboard files. Matches recurring known pattern with 27 prior occurrences on this exact shard.

Suggested actions:

  • Re-run the failed CI jobs to confirm if the failure is intermittent
  • If the test continues to fail, consider quarantining it using /quarantine-test <test name> <issue URL>
  • Search existing issues to see if this test is already known to be flaky

You can re-run the failed jobs from the workflow run page.

@github-actions github-actions Bot locked and limited conversation to collaborators Oct 18, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants