ant-design-blazor/components/layout/AntLayout.razor

29 lines
561 B
Plaintext

@namespace AntBlazor
@inherits AntDomComponentBase
<CascadingValue Value="this">
<div class="@ClassMapper.Class" style="@Style" @attributes="Attributes" Id="@Id">
@ChildContent
</div>
</CascadingValue>
@code
{
[Parameter]
public RenderFragment ChildContent { get; set; }
[Parameter]
public bool HasSider { get; set; }
protected override void OnInitialized()
{
base.OnInitialized();
ClassMapper
.Add("ant-layout")
.If("ant-layout-has-sider", () => HasSider);
}
}