Implements B1 from docs/Extra.md Part 1, safety-critical (golden rule #1). - Domain: UserCommand (id/name/executable/arguments). - Application: IUserCommandStore port + UserCommandFactory.ToDefinition, which FORCES RequiresAdmin=false and namespaces the id as "user:" so it can never be routed to — or accepted by — the Elevator. - Infrastructure: JsonUserCommandStore -> %AppData%\CommandForge\ user-commands.json, fully separate from the embedded catalog. No telemetry; corrupt-file fallback. - WPF: new "My commands" section (sidebar + View menu) with a persistent warning banner. Create/edit/save/delete; Run shows the exact command line and that it runs without admin, then executes asInvoker via the forced-non-elevated definition. Console bound to the shared execution. - EN/VI .resx; docs/Security.md §2.1 (threat model). - Tests: ToDefinition never RequiresAdmin, id is namespaced, the definition routes to the executor (never elevation), store round-trip. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
30 lines
805 B
C#
30 lines
805 B
C#
namespace CommandForge.Wpf.ViewModels;
|
|
|
|
/// <summary>The active section of the main shell content area.</summary>
|
|
public enum ShellSection
|
|
{
|
|
/// <summary>The Home dashboard (recent commands, favorites, system status).</summary>
|
|
Home,
|
|
|
|
/// <summary>The command catalog (browse/search/run).</summary>
|
|
Catalog,
|
|
|
|
/// <summary>The execution-history screen (past runs, re-run).</summary>
|
|
History,
|
|
|
|
/// <summary>The recipes screen (build/run command chains).</summary>
|
|
Recipes,
|
|
|
|
/// <summary>The user-defined commands screen (non-elevated, separate from the catalog).</summary>
|
|
UserCommands,
|
|
|
|
/// <summary>The Settings screen.</summary>
|
|
Settings,
|
|
|
|
/// <summary>The Log Viewer.</summary>
|
|
LogViewer,
|
|
|
|
/// <summary>The Debug panel.</summary>
|
|
Debug,
|
|
}
|