mirror of
https://github.com/spectreconsole/spectre.console.git
synced 2025-10-25 15:19:23 +00:00
41 lines
1.5 KiB
C#
41 lines
1.5 KiB
C#
using System;
|
|
|
|
namespace Spectre.Console.Rendering
|
|
{
|
|
/// <summary>
|
|
/// Represents a minimal border with a heavy header.
|
|
/// </summary>
|
|
public sealed class MinimalHeavyHeadTableBorder : TableBorder
|
|
{
|
|
/// <inheritdoc/>
|
|
public override TableBorder? SafeBorder => TableBorder.Minimal;
|
|
|
|
/// <inheritdoc/>
|
|
public override string GetPart(TableBorderPart part)
|
|
{
|
|
return part switch
|
|
{
|
|
TableBorderPart.HeaderTopLeft => " ",
|
|
TableBorderPart.HeaderTop => " ",
|
|
TableBorderPart.HeaderTopSeparator => " ",
|
|
TableBorderPart.HeaderTopRight => " ",
|
|
TableBorderPart.HeaderLeft => " ",
|
|
TableBorderPart.HeaderSeparator => "│",
|
|
TableBorderPart.HeaderRight => " ",
|
|
TableBorderPart.HeaderBottomLeft => " ",
|
|
TableBorderPart.HeaderBottom => "━",
|
|
TableBorderPart.HeaderBottomSeparator => "┿",
|
|
TableBorderPart.HeaderBottomRight => " ",
|
|
TableBorderPart.CellLeft => " ",
|
|
TableBorderPart.CellSeparator => "│",
|
|
TableBorderPart.CellRight => " ",
|
|
TableBorderPart.FooterBottomLeft => " ",
|
|
TableBorderPart.FooterBottom => " ",
|
|
TableBorderPart.FooterBottomSeparator => " ",
|
|
TableBorderPart.FooterBottomRight => " ",
|
|
_ => throw new InvalidOperationException("Unknown border part."),
|
|
};
|
|
}
|
|
}
|
|
}
|