Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions src/Aspire.Dashboard/Components/Pages/TraceDetail.razor
Original file line number Diff line number Diff line change
Expand Up @@ -166,10 +166,14 @@
<div class="tick" style="grid-column: 3;"></div>
<span class="tick-label" style="grid-column: 3;">@DurationFormatter.FormatDuration(trace.Duration / 4 * 2)</span>

@* Grid column 4 shows two labels. Hide the left aligned label on mobile to avoid them overlapping *@
<div class="tick" style="grid-column: 4;"></div>
<span class="tick-label" style="grid-column: 4;">@DurationFormatter.FormatDuration(trace.Duration / 4 * 3)</span>
@if (_manager.ViewportInformation.IsDesktop)
Copy link
Member Author

Choose a reason for hiding this comment

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

Using this instead of hidden-on-mobile so it works when details view is open.

{
<span class="tick-label" style="grid-column: 4;">@DurationFormatter.FormatDuration(trace.Duration / 4 * 3)</span>
}

<span class="tick-label end-tick hidden-on-mobile" style="grid-column: 4;">@DurationFormatter.FormatDuration(trace.Duration)</span>
<span class="tick-label end-tick" style="grid-column: 4;">@DurationFormatter.FormatDuration(trace.Duration)</span>
<div class="tick" style="grid-column: 5;"></div>
</div>
</HeaderCellItemTemplate>
Expand Down
2 changes: 2 additions & 0 deletions src/Aspire.Dashboard/Components/Resize/GridColumnManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ public class GridColumnManager : ComponentBase, IDisposable
[Parameter]
public RenderFragment? ChildContent { get; set; }

public ViewportInformation ViewportInformation => _gridViewportInformation ?? DimensionManager.ViewportInformation;

protected override void OnInitialized()
{
DimensionManager.OnViewportSizeChanged += OnViewportSizeChanged;
Expand Down
13 changes: 9 additions & 4 deletions src/Aspire.Dashboard/wwwroot/css/app.css
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,15 @@ fluent-toolbar[orientation=horizontal] {
width: 100%;
}

fluent-toolbar::part(positioning-region) {
row-gap: calc(var(--design-unit) * 1.5px);
}

fluent-toolbar::part(end) {
flex-wrap: wrap;
row-gap: calc(var(--design-unit) * 1.5px);
}

/* Hide any web components that haven't been */
:not(:defined),
.before-upgrade {
Expand Down Expand Up @@ -620,7 +629,3 @@ fluent-data-grid-cell.no-ellipsis {
.layout fluent-toolbar > .fluent-input-label {
margin-bottom: 0;
}

.page-content-container fluent-toolbar::part(end) {
flex-wrap: wrap;
}
Loading