Box
ClassNamespace:
RazorConsole.ComponentsAssembly:
RazorConsole.CoreDefinition
public class Box : ComponentBase, IComponent, IHandleEvent, IHandleAfterRenderConstructors
1| Name | Type | Description |
|---|---|---|
Box() | Constructor | — |
Properties
16| Name | Type | Description |
|---|---|---|
Appearance | ||
Border | BoxBorder | Optional border style used by panel-compatible boxes. |
BorderColor | Nullable<Color> | Optional border color used by panel-compatible boxes. |
Class | String | CSS class emitted for translator compatibility. Default is box. |
FillHeight | Boolean | Whether the box should fill the height offered by its parent. |
FillWidth | Boolean | Whether the box should fill the width offered by its parent. |
Height | Nullable<Int32> | Explicit height in terminal rows. |
TitleColor | Nullable<Color> | Optional title color used by panel-compatible boxes. |
Width | Nullable<Int32> | Explicit width in terminal cells. |
Common | ||
ChildContent | RenderFragment | Content rendered inside the box. |
Title | String | Optional title used by panel-compatible boxes. |
Other | ||
AdditionalAttributes | IReadOnlyDictionary<String, Object> | Additional attributes applied to the emitted box element. |
Expand | Boolean | Whether the box should expand when a parent container allocates remaining space. Prefer FillWidth and FillHeight for new code. |
Horizontal | Nullable<HorizontalAlignment> | Horizontal child alignment used by align-compatible boxes. |
Margin | Nullable<Padding> | Margin outside the box border. |
Padding | Nullable<Padding> | Padding around the child content. |
Vertical | Nullable<VerticalAlignment> | Vertical child alignment used by align-compatible boxes. |
Methods
1| Name | Type | Description |
|---|---|---|
BuildRenderTree(RenderTreeBuilder)() | Method | Renders the component to the supplied RenderTreeBuilder. |