diff --git a/Directory.Packages.props b/Directory.Packages.props index 64d72e4b24d..06a8e1d77f5 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -88,8 +88,8 @@ - - + + diff --git a/src/Aspire.Dashboard/Components/Controls/FixedFluentCombobox.razor b/src/Aspire.Dashboard/Components/Controls/FixedFluentCombobox.razor deleted file mode 100644 index 7af1fa97be9..00000000000 --- a/src/Aspire.Dashboard/Components/Controls/FixedFluentCombobox.razor +++ /dev/null @@ -1,8 +0,0 @@ -@namespace Aspire.Dashboard.Components -@inherits FluentCombobox -@typeparam TOption - -@{ - /* Write the base component content here */ - base.BuildRenderTree(__builder); -} diff --git a/src/Aspire.Dashboard/Components/Controls/FixedFluentCombobox.razor.cs b/src/Aspire.Dashboard/Components/Controls/FixedFluentCombobox.razor.cs deleted file mode 100644 index 2d464b9b202..00000000000 --- a/src/Aspire.Dashboard/Components/Controls/FixedFluentCombobox.razor.cs +++ /dev/null @@ -1,18 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using Microsoft.AspNetCore.Components; -using Microsoft.FluentUI.AspNetCore.Components; - -namespace Aspire.Dashboard.Components; - -// TODO: This is a temporary fix for https://github.com/dotnet/aspire/issues/8343 and https://github.com/microsoft/fluentui-blazor/issues/3600 -// Remove once FluentUI is fixed and dashboard is using the fixed version. -[CascadingTypeParameter(nameof(TOption))] -public partial class FixedFluentCombobox : FluentCombobox where TOption : notnull -{ - protected override async Task ChangeHandlerAsync(ChangeEventArgs e) - { - await InvokeAsync(async () => await base.ChangeHandlerAsync(e)); - } -} diff --git a/src/Aspire.Dashboard/Components/Dialogs/FilterDialog.razor b/src/Aspire.Dashboard/Components/Dialogs/FilterDialog.razor index b01aa005cab..f7b921482c2 100644 --- a/src/Aspire.Dashboard/Components/Dialogs/FilterDialog.razor +++ b/src/Aspire.Dashboard/Components/Dialogs/FilterDialog.razor @@ -33,7 +33,7 @@
- - +
diff --git a/src/Aspire.Dashboard/Model/IconResolver.cs b/src/Aspire.Dashboard/Model/IconResolver.cs index 5f1733ce1c7..6f9289f980d 100644 --- a/src/Aspire.Dashboard/Model/IconResolver.cs +++ b/src/Aspire.Dashboard/Model/IconResolver.cs @@ -44,21 +44,13 @@ private sealed record IconKey(string IconName, IconSize DesiredIconSize, IconVar private static bool TryGetIcon(IconKey key, IconSize size, [NotNullWhen(true)] out CustomIcon? icon) { - try + var iconInfo = new IconInfo { - icon = (new IconInfo - { - Name = key.IconName, - Variant = key.IconVariant, - Size = size - }).GetInstance(); - return true; - } - catch - { - // Icon name or size couldn't be found. - icon = null; - return false; - } + Name = key.IconName, + Variant = key.IconVariant, + Size = size + }; + + return iconInfo.TryGetInstance(out icon); } } diff --git a/tests/Aspire.Dashboard.Components.Tests/Pages/ConsoleLogsTests.cs b/tests/Aspire.Dashboard.Components.Tests/Pages/ConsoleLogsTests.cs index c28d481786d..40e487c15a7 100644 --- a/tests/Aspire.Dashboard.Components.Tests/Pages/ConsoleLogsTests.cs +++ b/tests/Aspire.Dashboard.Components.Tests/Pages/ConsoleLogsTests.cs @@ -559,6 +559,7 @@ private void SetupConsoleLogsServices(TestDashboardClient? dashboardClient = nul Services.AddSingleton(timeProvider ?? new TestTimeProvider()); Services.AddSingleton(); Services.AddSingleton(); + Services.AddSingleton(); Services.AddSingleton>(Options.Create(new DashboardOptions())); Services.AddSingleton(); Services.AddSingleton();