chanan / BlazorStrap

Bootstrap 4 Components for Blazor Framework
https://blazorstrap.io
The Unlicense
916 stars 157 forks source link

Added NoDataColspan in BSDataTableBase #547

Closed VulpesSARL closed 2 years ago

VulpesSARL commented 2 years ago

Added Colspan to a TD element, to allow spanning over the entire row, when no data is available ...

<BSDataTable Items="Lst" Context="L" PaginationBottom="false" IsStriped="true" IsResponsive="true" NoDataColspan="3">
    <Header>
        <BSTD>Firstname</BSTD>
        <BSTD>Lastname</BSTD>
        <BSTD>a number</BSTD>
    </Header>
    <NoData>
        No Data
    </NoData>
    <Body>
        <BSDataTableRow>
            <BSTD>@L.FirstName</BSTD>
            <BSTD>@L.Lastname</BSTD>
            <BSTD>@L.Number.ToString()</BSTD>
        </BSDataTableRow>
    </Body>
</BSDataTable>