csharpdeeb25a2 | 1 | namespace CascadeIDE.Models; |
| 2 | |
| 3 | /// <summary>Presentation tier (ADR 0171): compact = standard IDE; cockpit = P/F/M spatial layout.</summary> |
| 4 | public enum PresentationTierKind |
| 5 | { |
| 6 | Compact, |
| 7 | Cockpit, |
| 8 | } |
| 9 | |
| 10 | public static class PresentationTierKindExtensions |
| 11 | { |
| 12 | public const string AutoValue = "auto"; |
| 13 | public const string CompactValue = "compact"; |
| 14 | public const string CockpitValue = "cockpit"; |
| 15 | |
| 16 | public static string ToTomlValue(this PresentationTierKind kind) => |
| 17 | kind == PresentationTierKind.Cockpit ? CockpitValue : CompactValue; |
| 18 | |
| 19 | public static PresentationTierKind ParseTomlValue(string? raw) => |
| 20 | string.Equals(raw, CockpitValue, StringComparison.OrdinalIgnoreCase) |
| 21 | ? PresentationTierKind.Cockpit |
| 22 | : PresentationTierKind.Compact; |
| 23 | } |
| 24 | |
View only · write via MCP/CIDE