@inherits ComponentBase

<TableContainer T="ViewModel"
                @ref="Container"
                @bind-Search="Search"
                Title="@Title"
                Breadcrumbs="@Breadcrumbs"
                Data="LoadDataAsync">
    <Header>
        <MudTh>
            <MudTableSortLabel SortLabel="Customer" T="ViewModel">
                Customer
            </MudTableSortLabel>
        </MudTh>
        <MudTh>
            <MudTableSortLabel SortLabel="Host" T="ViewModel">
                Host
            </MudTableSortLabel>
        </MudTh>
        <MudTh>
            <MudTableSortLabel SortLabel="ProcessId" T="ViewModel">
                ProcessId
            </MudTableSortLabel>
        </MudTh>
        <MudTh>
            <MudTableSortLabel SortLabel="Account" T="ViewModel">
                Account
            </MudTableSortLabel>
        </MudTh>
        <MudTh>
            <MudTableSortLabel SortLabel="StartMode" T="ViewModel">
                StartMode
            </MudTableSortLabel>
        </MudTh>
        <MudTh>
            <MudTableSortLabel SortLabel="Delay" T="ViewModel">
                Delay
            </MudTableSortLabel>
        </MudTh>
        <MudTh>
            <MudTableSortLabel SortLabel="State" T="ViewModel">
                State
            </MudTableSortLabel>
        </MudTh>
    </Header>
    <RowTemplate>
        <MudTd DataLabel="Customer">
            <MudLink Href="@Navigation.Management.Customers.DetailsHref(@context?.Customers?.Id)" Typo="Typo.inherit" Underline="Underline.None">
                @context?.Customers?.Name
            </MudLink>
        </MudTd>
        <MudTd DataLabel="Host">
            <MudLink Href="@Navigation.Management.Hosts.DetailsHref(@context?.Hosts?.Id)" Typo="Typo.inherit" Underline="Underline.None">
                @context?.Hosts?.Name
            </MudLink>
        </MudTd>
        <MudTd DataLabel="ProcessId">
            @context?.ProcessId
        </MudTd>
        <MudTd DataLabel="Account">
            @context?.Account
        </MudTd>
        <MudTd DataLabel="StartMode">
            @context?.StartMode
        </MudTd>
        <MudTd DataLabel="Delay">
            <MudCheckBox Checked="@context?.Delay" Disabled DisableRipple />
        </MudTd>
        <MudTd DataLabel="State">
            @{
                var color = context?.State == "Running" ? Color.Success : Color.Error;
                        <MudText Color="color" Typo="Typo.inherit">@context?.State</MudText>
            }
        </MudTd>
    </RowTemplate>
</TableContainer>