55 references to Enabled
Aspire.Dashboard (6)
Components\Controls\TerminalDisconnectedBanner.razor.cs (2)
95return commands.OrderBy(c => c.State != CommandViewModelState.Enabled) 100private bool RestartDisabled => _executing || RestartCommand is not { State: CommandViewModelState.Enabled } command ||
Model\DashboardCommandExecutor.cs (1)
62if (command is not { State: CommandViewModelState.Enabled } ||
Model\ResourceMenuBuilder.cs (1)
341!resource.IsParameter && !_dashboardClient.IsReadOnly && command.State == CommandViewModelState.Enabled && !isCommandExecuting(resource, command);
Model\TelemetryExportService.cs (1)
773.Where(c => c.State == CommandViewModelState.Enabled)
ServiceClient\Partials.cs (1)
142ResourceCommandState.Enabled => CommandViewModelState.Enabled,
Aspire.Dashboard.Components.Tests (32)
Controls\MissingParametersPanelTests.cs (1)
141new(CommandViewModel.SetParameterCommand, CommandViewModelState.Enabled, "Set", string.Empty, string.Empty, [input], isHighlighted: false, iconName: string.Empty, iconVariant: Microsoft.FluentUI.AspNetCore.Components.IconVariant.Regular);
Controls\ResourceDetailsTests.cs (3)
799CommandViewModelState.Enabled, 845CommandViewModelState.Enabled, 891CommandViewModelState.Enabled,
Controls\TerminalDisconnectedBannerTests.cs (1)
205private static CommandViewModel CreateCommand(string name, CommandViewModelState state = CommandViewModelState.Enabled) =>
Controls\TerminalViewTests.cs (1)
624commands: [new CommandViewModel(CommandViewModel.StartCommand, CommandViewModelState.Enabled,
Layout\ResourcesLayoutTests.cs (21)
644Command("enabled", CommandViewModelState.Enabled), 1544var command = new CommandViewModel("resource-stop", CommandViewModelState.Enabled, "Stop", "Stop resource", confirmationMessage: "", argumentInputs: [], isHighlighted: true, iconName: iconName, iconVariant: IconVariant.Filled); 1586var stop = new CommandViewModel("resource-stop", CommandViewModelState.Enabled, "Stop", "Stop resource", confirmationMessage: "", argumentInputs: [], isHighlighted: true, iconName: "Stop", iconVariant: IconVariant.Filled); 1587var other = new CommandViewModel("custom", CommandViewModelState.Enabled, "Custom command", "", confirmationMessage: "", argumentInputs: [], isHighlighted: false, iconName: string.Empty, iconVariant: IconVariant.Regular); 1618var enabled = Stop(CommandViewModelState.Enabled); 1626new CommandViewModel(CommandViewModel.SetParameterCommand, CommandViewModelState.Enabled, "Set parameter", "", 1673var command = new CommandViewModel("refresh", CommandViewModelState.Enabled, "Refresh", "", 1712var stop = new CommandViewModel("resource-stop", CommandViewModelState.Enabled, "Stop", "Stop resource", confirmationMessage: "", argumentInputs: [], isHighlighted: true, iconName: "Stop", iconVariant: IconVariant.Filled); 1752Command(CommandViewModel.StopCommand, CommandViewModelState.Enabled, true), 1753Command(CommandViewModel.RestartCommand, CommandViewModelState.Enabled, false) 1790Command(CommandViewModel.StopCommand, CommandViewModelState.Enabled, false), 1792Command("deploy", CommandViewModelState.Enabled, true), 1794Command("extra", CommandViewModelState.Enabled, true) 1824[InlineData(CommandViewModelState.Enabled, false, false, ResourceListDensity.Comfortable)] 1825[InlineData(CommandViewModelState.Enabled, true, false, ResourceListDensity.Compact)] 1827[InlineData(CommandViewModelState.Enabled, true, true, ResourceListDensity.Compact)] 1838Command("custom", "Custom", CommandViewModelState.Enabled, true), 1839Command(CommandViewModel.DeleteParameterCommand, "Delete parameter", CommandViewModelState.Enabled, true) 1895Command(CommandViewModel.StopCommand, CommandViewModelState.Enabled), 1897Command("deploy", CommandViewModelState.Enabled), 2012var stop = new CommandViewModel("resource-stop", CommandViewModelState.Enabled, "Stop", "Stop resource", confirmationMessage: "", argumentInputs: [], isHighlighted: true, iconName: "Stop", iconVariant: IconVariant.Filled);
Model\DashboardCommandExecutorTests.cs (1)
81state: CommandViewModelState.Enabled,
Pages\ConsoleLogsTests.cs (3)
839commands: [new CommandViewModel("test-name", CommandViewModelState.Enabled, "test-displayname", "test-displaydescription", confirmationMessage: "", argumentInputs: [], isHighlighted: true, iconName: string.Empty, iconVariant: IconVariant.Regular)]); 906CommandViewModelState.Enabled, 948commands: [new CommandViewModel("test-name", CommandViewModelState.Enabled, "test-displayname", "test-displaydescription", confirmationMessage: "", argumentInputs: [], isHighlighted: true, iconName: string.Empty, iconVariant: IconVariant.Regular)]);
Pages\ResourcesTests.cs (1)
277CommandViewModelState.Enabled,
Aspire.Dashboard.Playwright.Tests (2)
Integration\Playwright\ResourcePaneResponsiveTests.cs (2)
264commands: [new("inspect", CommandViewModelState.Enabled, "Inspect", "", "", [], 2847new(name, CommandViewModelState.Enabled, name, "", confirmationMessage: "", argumentInputs: [],
Aspire.Dashboard.Tests (15)
Model\DashboardClientTests.cs (1)
1511CommandViewModelState.Enabled,
Model\DashboardCommandExecutorTests.cs (2)
92[InlineData(CommandViewModelState.Enabled, "Are you sure?")] 429private static CommandViewModel CreateCommand(string name = "test-command", CommandViewModelState state = CommandViewModelState.Enabled, string confirmationMessage = "")
Model\ResourceMenuBuilderTests.cs (12)
93var first = ModelTestHelpers.CreateResource(resourceName: "first", commands: [CreateCommand("Refresh", CommandViewModelState.Enabled)]); 94var second = ModelTestHelpers.CreateResource(resourceName: "second", commands: [CreateCommand("Refresh", CommandViewModelState.Enabled)]); 99var busy = ModelTestHelpers.CreateResource(resourceName: "busy", commands: [CreateCommand("Refresh", CommandViewModelState.Enabled)]); 100var removed = ModelTestHelpers.CreateResource(resourceName: "removed", commands: [CreateCommand("Refresh", CommandViewModelState.Enabled)]); 128var newlyAdded = ModelTestHelpers.CreateResource(resourceName: "new", commands: [CreateCommand("Refresh", CommandViewModelState.Enabled)]); 144[InlineData(true, CommandViewModelState.Enabled)] 150var member = ModelTestHelpers.CreateResource(resourceName: "first", commands: [CreateCommand("Refresh", CommandViewModelState.Enabled)]); 411CommandViewModelState.Enabled, 421CommandViewModelState.Enabled, 459CommandViewModelState.Enabled, 504CommandViewModelState.Enabled, 547CommandViewModelState.Enabled,