Skip to content

fix(dashboard): hide UTC timestamps option when Show timestamps is off - #19967

Open
Longhao Wang (GISWLH) wants to merge 2 commits into
microsoft:mainfrom
GISWLH:fix/hide-utc-when-timestamps-disabled
Open

fix(dashboard): hide UTC timestamps option when Show timestamps is off#19967
Longhao Wang (GISWLH) wants to merge 2 commits into
microsoft:mainfrom
GISWLH:fix/hide-utc-when-timestamps-disabled

Conversation

@GISWLH

Copy link
Copy Markdown

Summary

Hides the UTC timestamps menu item in the logs filter unless Show timestamps is enabled, matching expected UX.

Fixes #19019

Test plan

  • Added UI coverage for hidden vs shown UTC menu item
  • Manual dashboard check

The console logs settings menu previously showed a disabled UTC timestamps
checkbox whenever timestamps were hidden. Hide the option entirely so it
only appears when timestamps are enabled.

Fixes microsoft#19019
Covers the console logs settings menu so UTC timestamps is absent when
Show timestamps is disabled and present after timestamps are enabled.
Copilot AI balanced review requested due to automatic review settings September 6, 2026 03:03
@github-actions

github-actions Bot commented Sep 6, 2026

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 -- 19967

Or

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

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 behavior change is small, directly matches the reported UX bug, and includes targeted automated coverage to prevent regression.

Pull request overview

This PR updates the Console Logs settings menu in the Aspire Dashboard so the “UTC timestamps” option is only shown when “Show timestamps” is enabled, aligning the UI with the expected UX described in issue #19019.

Changes:

  • Hide the “UTC timestamps” menu item unless timestamps are currently enabled.
  • Add a component test covering both the hidden (disabled timestamps) and shown (enabled timestamps) cases.
File summaries
File Description
src/Aspire.Dashboard/Components/Pages/ConsoleLogs.razor.cs Conditions the “UTC timestamps” menu item on _showTimestamp so it’s hidden when timestamps are off.
tests/Aspire.Dashboard.Components.Tests/Pages/ConsoleLogsTests.cs Adds a bUnit test validating the UTC menu item is absent when timestamps are off and present after enabling timestamps.
Review details
  • Files reviewed: 2/2 changed files
  • Comments generated: 0
  • Review effort level: Lite

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

@GISWLH

Copy link
Copy Markdown
Author

@microsoft-github-policy-service agree

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[13.5] Logs filter should hide UTC timestamps option when Show timestamps is disabled

2 participants