Table

DTable is a thin, data-agnostic wrapper around daisy's table classes: you bring the rows (plain <thead>/<tbody>, a loop, a data source) and the component emits table plus the modifiers table-zebra, table-pin-rows, table-pin-cols and table-xs|sm|lg. Because it renders real HTML, all of it works in static SSR too. Expand the Razor block under any example for the markup behind it.

Table— thead + tbody, with a th column for the row number
NameJobFavorite Color
1Cy GandertonQuality Control SpecialistBlue
2Hart HagertyDesktop Support TechnicianPurple
3Brice SwyreTax AccountantRed
<DTable Class="w-full max-w-2xl">
    <thead>
        <tr><th></th><th>Name</th><th>Job</th><th>Favorite Color</th></tr>
    </thead>
    <tbody>
        @foreach (var p in _people.Take(3))
        {
            <tr><th>@p.Id</th><td>@p.Name</td><td>@p.Job</td><td>@p.Color</td></tr>
        }
    </tbody>
</DTable>
 
@code {
    private sealed record Person(
        int Id, string Name, string Job, string Company, string Country,
        string LastLogin, string Color, bool Online)
    {
        public string Avatar => $"https://picsum.photos/id/{AvatarIds[Id % AvatarIds.Length]}/96/96";
        public DaisyStatus Status => Online ? DaisyStatus.Online : DaisyStatus.Offline;
    }
 
    private static readonly int[] AvatarIds = [1027, 1012, 1035, 1043, 1024, 1016, 1011, 1084, 64, 65];
 
    private static readonly Person[] _people =
    [
        new(1, "Cy Ganderton", "Quality Control Specialist", "Littel, Schaden and Vandervort", "Canada", "12/16/2020", "Blue", true),
        new(2, "Hart Hagerty", "Desktop Support Technician", "Zemlak, Daniel and Leannon", "United States", "12/5/2020", "Purple", true),
        new(3, "Brice Swyre", "Tax Accountant", "Carroll Group", "China", "8/15/2020", "Red", false),
        new(4, "Marjy Ferencz", "Office Assistant I", "Rowe-Schoen", "Russia", "3/25/2021", "Crimson", true),
        new(5, "Yancy Tear", "Community Outreach Specialist", "Wyman-Ledner", "Brazil", "5/22/2020", "Indigo", false),
        new(6, "Irma Vasilik", "Editor", "Wiza, Bins and Emard", "Venezuela", "12/8/2020", "Purple", true),
        new(7, "Meghann Durtnal", "Staff Accountant IV", "Schuster-Schimmel", "Philippines", "2/17/2021", "Yellow", true),
        new(8, "Sammy Seston", "Accountant I", "O'Hara, Welch and Keebler", "Indonesia", "5/23/2020", "Crimson", false),
        new(9, "Lesya Tinham", "Safety Technician IV", "Turner-Kuhlman", "Philippines", "2/21/2021", "Maroon", true),
        new(10, "Zaneta Tewkesbury", "VP Marketing", "Sauer LLC", "Chad", "6/23/2020", "Green", true),
        new(11, "Andy Tipple", "Librarian", "Hilpert Group", "Poland", "7/9/2020", "Indigo", false),
        new(12, "Sophi Biles", "Recruiting Manager", "Emerson Group", "Indonesia", "3/13/2021", "Aquamarine", true),
    ];
}
Table with border and background— No table class needed - wrap it in a rounded-box + border container
NameJobFavorite Color
1Cy GandertonQuality Control SpecialistBlue
2Hart HagertyDesktop Support TechnicianPurple
3Brice SwyreTax AccountantRed
<div class="overflow-x-auto rounded-box border border-base-300 bg-base-100 w-full max-w-2xl">
    <DTable>
        <thead>
            <tr><th></th><th>Name</th><th>Job</th><th>Favorite Color</th></tr>
        </thead>
        <tbody>
            @foreach (var p in _people.Take(3))
            {
                <tr><th>@p.Id</th><td>@p.Name</td><td>@p.Job</td><td>@p.Color</td></tr>
            }
        </tbody>
    </DTable>
</div>
Table with an active row— daisy has no table-active class - a bg-base-200 utility on the tr is the pattern
NameJobFavorite Color
1Cy GandertonQuality Control SpecialistBlue
2Hart HagertyDesktop Support TechnicianPurple
3Brice SwyreTax AccountantRed
<DTable Class="w-full max-w-2xl">
    <thead>
        <tr><th></th><th>Name</th><th>Job</th><th>Favorite Color</th></tr>
    </thead>
    <tbody>
        <tr class="bg-base-200"><th>1</th><td>Cy Ganderton</td><td>Quality Control Specialist</td><td>Blue</td></tr>
        <tr><th>2</th><td>Hart Hagerty</td><td>Desktop Support Technician</td><td>Purple</td></tr>
        <tr><th>3</th><td>Brice Swyre</td><td>Tax Accountant</td><td>Red</td></tr>
    </tbody>
</DTable>
Table with a row that highlights on hover— Same trick with a hover: utility - written as an arbitrary value so the CDN Tailwind build emits it
NameJobFavorite Color
1Cy GandertonQuality Control SpecialistBlue
2Hart HagertyDesktop Support TechnicianPurple
3Brice SwyreTax AccountantRed
<DTable Class="w-full max-w-2xl">
    <thead>
        <tr><th></th><th>Name</th><th>Job</th><th>Favorite Color</th></tr>
    </thead>
    <tbody>
        <tr><th>1</th><td>Cy Ganderton</td><td>Quality Control Specialist</td><td>Blue</td></tr>
        <tr class="hover:bg-[var(--color-base-300)]"><th>2</th><td>Hart Hagerty</td><td>Desktop Support Technician</td><td>Purple</td></tr>
        <tr><th>3</th><td>Brice Swyre</td><td>Tax Accountant</td><td>Red</td></tr>
    </tbody>
</DTable>
Zebra— Zebra="true" emits table-zebra
NameJobFavorite Color
1Cy GandertonQuality Control SpecialistBlue
2Hart HagertyDesktop Support TechnicianPurple
3Brice SwyreTax AccountantRed
4Marjy FerenczOffice Assistant ICrimson
5Yancy TearCommunity Outreach SpecialistIndigo
<DTable Zebra="true" Class="w-full max-w-2xl">
    <thead>
        <tr><th></th><th>Name</th><th>Job</th><th>Favorite Color</th></tr>
    </thead>
    <tbody>
        @foreach (var p in _people.Take(5))
        {
            <tr><th>@p.Id</th><td>@p.Name</td><td>@p.Job</td><td>@p.Color</td></tr>
        }
    </tbody>
</DTable>
Sizes— Size = table-xs / table-sm / default (md) / table-lg - click to switch the table below
NameJobCompanyLocationLast LoginFavorite Color
1Cy GandertonQuality Control SpecialistLittel, Schaden and Vandervort Canada12/16/2020Blue
2Hart HagertyDesktop Support TechnicianZemlak, Daniel and Leannon United States12/5/2020Purple
3Brice SwyreTax AccountantCarroll Group China8/15/2020Red
4Marjy FerenczOffice Assistant IRowe-Schoen Russia3/25/2021Crimson

Current: xs (table-xs)

<div class="join mb-4">
    @foreach (var size in _sizes)
    {
        <DButton Size="DaisySize.Small" Color="@(_size == size ? DaisyColor.Primary : DaisyColor.Default)"
                 OnClick="@(() => _size = size)" Class="@(_size == size ? "btn-active" : null)">@SizeLabel(size)</DButton>
    }
</div>
<DTable Size="_size" Zebra="true" Class="w-full">
    <thead>
        <tr><th></th><th>Name</th><th>Job</th><th>Company</th><th>Location</th><th>Last Login</th><th>Favorite Color</th></tr>
    </thead>
    <tbody>
        @foreach (var p in _people.Take(4))
        {
            <tr>
                <th>@p.Id</th><td>@p.Name</td><td>@p.Job</td><td>@p.Company</td>
                <td>@p.Country</td><td>@p.LastLogin</td><td>@p.Color</td>
            </tr>
        }
    </tbody>
</DTable>
<p class="mt-2 text-sm opacity-60">Current: <code>@SizeLabel(_size)</code> (@(SizeClassOf(_size) ?? "no size class - daisy default"))</p>
 
@code {
    private DaisySize _size = DaisySize.ExtraSmall;
    private static readonly DaisySize[] _sizes = [DaisySize.ExtraSmall, DaisySize.Small, DaisySize.Medium, DaisySize.Large];
 
    private static string SizeLabel(DaisySize size) => size switch
    {
        DaisySize.ExtraSmall => "xs",
        DaisySize.Small => "sm",
        DaisySize.Medium => "md",
        _ => "lg",
    };
 
    private static string? SizeClassOf(DaisySize size) => size switch
    {
        DaisySize.ExtraSmall => "table-xs",
        DaisySize.Small => "table-sm",
        DaisySize.Large => "table-lg",
        _ => null,
    };
}
Table with visual elements— The cells are just markup, so every DaisyBlazorUI component fits inside: DCheckbox, DAvatar, DBadge, DStatus, DTooltip, DButton
Name Job Favorite Color
Cy Ganderton
Cy Ganderton
Canada
Littel, Schaden and Vandervort
Quality Control Specialist
Blue
Hart Hagerty
Hart Hagerty
United States
Zemlak, Daniel and Leannon
Desktop Support Technician
Purple
Brice Swyre
Brice Swyre
China
Carroll Group
Tax Accountant
Red
<div class="overflow-x-auto w-full max-w-4xl">
    <DTable>
        <thead>
            <tr>
                <th><DCheckbox aria-label="Select all" /></th>
                <th>Name</th>
                <th>Job</th>
                <th>Favorite Color</th>
                <th></th>
            </tr>
        </thead>
        <tbody>
            @foreach (var p in _people.Take(3))
            {
                <tr>
                    <th><DCheckbox aria-label="@($"Select {p.Name}")" /></th>
                    <td>
                        <div class="flex items-center gap-3">
                            <DAvatar Src="@p.Avatar" Alt="@p.Name" SizeClass="w-12"
                                     Shape="DaisyAvatarShape.Circle" Status="@p.Status" />
                            <div>
                                <div class="font-bold">@p.Name</div>
                                <div class="text-sm opacity-50">@p.Country</div>
                            </div>
                        </div>
                    </td>
                    <td>
                        @p.Company
                        <br />
                        <DBadge Color="DaisyColor.Ghost" Size="DaisySize.Small">@p.Job</DBadge>
                    </td>
                    <td>
                        <span class="flex items-center gap-2">
                            <DStatus Color="@DotColor(p.Color)" Size="DaisyStatusSize.Medium" />
                            @p.Color
                        </span>
                    </td>
                    <th>
                        <DTooltip Tip="@($"Open {p.Name}")" Position="DaisyTooltipPosition.Left">
                            <DButton Color="DaisyColor.Ghost" Size="DaisySize.ExtraSmall">details</DButton>
                        </DTooltip>
                    </th>
                </tr>
            }
        </tbody>
    </DTable>
</div>
 
@code {
    private static DaisyColor DotColor(string color) => color switch
    {
        "Blue" or "Indigo" or "Aquamarine" => DaisyColor.Info,
        "Purple" => DaisyColor.Secondary,
        "Red" or "Crimson" or "Maroon" => DaisyColor.Error,
        "Green" => DaisyColor.Success,
        "Yellow" => DaisyColor.Warning,
        _ => DaisyColor.Primary,
    };
}
Table with pinned rows— PinRows makes every thead sticky - put the table in a scroll container
A
Ant-Man
Aquaman
Asterix
The Atom
The Avengers
B
Batgirl
Batman
Batwoman
Black Canary
Black Panther
C
Captain America
Captain Marvel
Catwoman
Conan the Barbarian
D
Daredevil
The Defenders
Doc Savage
Doctor Strange
E
Elektra
F
Fantastic Four
Flash
G
Ghost Rider
Green Arrow
Green Lantern
Guardians of the Galaxy
H
Hawkeye
Hellboy
Incredible Hulk
I
Iron Fist
Iron Man
M
Marvelman
Miss Martian
R
Robin
The Rocketeer
S
The Shadow
Spider-Man
Sub-Mariner
Supergirl
Superman
T
Teenage Mutant Ninja Turtles
Thor
The Thing
W
Watchmen
Wonder Woman
<div class="overflow-x-auto h-72 rounded-box border border-base-300 w-full max-w-md">
    <DTable PinRows="true" Class="bg-base-200">
        @foreach (var group in _groups)
        {
            <thead>
                <tr><th>@group.Letter</th></tr>
            </thead>
            <tbody>
                @foreach (var name in group.Names)
                {
                    <tr><td>@name</td></tr>
                }
            </tbody>
        }
    </DTable>
</div>
 
@code {
    private static readonly (string Letter, string[] Names)[] _groups =
    [
        ("A", ["Ant-Man", "Aquaman", "Asterix", "The Atom", "The Avengers"]),
        ("B", ["Batgirl", "Batman", "Batwoman", "Black Canary", "Black Panther"]),
        ("C", ["Captain America", "Captain Marvel", "Catwoman", "Conan the Barbarian"]),
        ("D", ["Daredevil", "The Defenders", "Doc Savage", "Doctor Strange"]),
        ("E", ["Elektra"]),
        ("F", ["Fantastic Four", "Flash"]),
        ("G", ["Ghost Rider", "Green Arrow", "Green Lantern", "Guardians of the Galaxy"]),
        ("H", ["Hawkeye", "Hellboy", "Incredible Hulk"]),
        ("I", ["Iron Fist", "Iron Man"]),
        ("M", ["Marvelman", "Miss Martian"]),
        ("R", ["Robin", "The Rocketeer"]),
        ("S", ["The Shadow", "Spider-Man", "Sub-Mariner", "Supergirl", "Superman"]),
        ("T", ["Teenage Mutant Ninja Turtles", "Thor", "The Thing"]),
        ("W", ["Watchmen", "Wonder Woman"]),
    ];
}
Table with pinned rows and pinned cols— PinRows + PinCols in both directions; the first AND last column stay put (table-xs keeps it compact)
NameJobCompanyLocation Last LoginFavorite Color
1Cy GandertonQuality Control SpecialistLittel, Schaden and Vandervort Canada12/16/2020Blue1
2Hart HagertyDesktop Support TechnicianZemlak, Daniel and Leannon United States12/5/2020Purple2
3Brice SwyreTax AccountantCarroll Group China8/15/2020Red3
4Marjy FerenczOffice Assistant IRowe-Schoen Russia3/25/2021Crimson4
5Yancy TearCommunity Outreach SpecialistWyman-Ledner Brazil5/22/2020Indigo5
6Irma VasilikEditorWiza, Bins and Emard Venezuela12/8/2020Purple6
7Meghann DurtnalStaff Accountant IVSchuster-Schimmel Philippines2/17/2021Yellow7
8Sammy SestonAccountant IO'Hara, Welch and Keebler Indonesia5/23/2020Crimson8
9Lesya TinhamSafety Technician IVTurner-Kuhlman Philippines2/21/2021Maroon9
10Zaneta TewkesburyVP MarketingSauer LLC Chad6/23/2020Green10
11Andy TippleLibrarianHilpert Group Poland7/9/2020Indigo11
12Sophi BilesRecruiting ManagerEmerson Group Indonesia3/13/2021Aquamarine12

Scroll sideways: the # columns on both edges stay pinned (daisy pins the first and last cell of each row).

<div class="overflow-auto h-72 w-full max-w-xl rounded-box border border-base-300">
    <DTable PinRows="true" PinCols="true" Size="DaisySize.ExtraSmall">
        <thead>
            <tr>
                <th></th><th>Name</th><th>Job</th><th>Company</th><th>Location</th>
                <th>Last Login</th><th>Favorite Color</th><th></th>
            </tr>
        </thead>
        <tbody>
            @foreach (var p in _people)
            {
                <tr>
                    <th>@p.Id</th><td>@p.Name</td><td>@p.Job</td><td>@p.Company</td>
                    <td>@p.Country</td><td>@p.LastLogin</td><td>@p.Color</td><th>@p.Id</th>
                </tr>
            }
        </tbody>
    </DTable>
</div>
Search, sort, select and paginate— A working data grid in pure Blazor: DInput search, clickable sort headers, DCheckbox selection with a select-all, DPagination. Filtering runs on Enter/blur (Blazor's default bind event)
12 of 12 rows
# Name Job Location Color
1 Cy Ganderton Quality Control Specialist Canada Blue
2 Hart Hagerty Desktop Support Technician United States Purple
3 Brice Swyre Tax Accountant China Red
4 Marjy Ferencz Office Assistant I Russia Crimson
5 Yancy Tear Community Outreach Specialist Brazil Indigo
page 1 of 3
<DInput @bind-Value="_search" @bind-Value:after="@ResetPage"
        Placeholder="Search name, job, company..." Size="DaisySize.Small"
        Class="w-full max-w-xs" />
<DButton Size="DaisySize.Small" Color="DaisyColor.Error" IconStart="@DaisyIcons.Trash"
         Disabled="@(_selected.Count == 0)" OnClick="DeleteSelected">
    @(_selected.Count == 0 ? "Delete selected" : $"Delete {_selected.Count} selected")
</DButton>
<DButton Size="DaisySize.Small" Variant="DaisyVariant.Outline" OnClick="Reset">Reset</DButton>
<span class="text-sm opacity-60">@Filtered().Count() of @_rows.Count rows</span>
 
<DTable Zebra="true" Class="w-full">
    <thead>
        <tr>
            <th>
                <DCheckbox Value="@AllSelected" ValueChanged="@((bool v) => ToggleAll(v))"
                           aria-label="Select all rows on this page" />
            </th>
            <th class="@SortHeaderClass" @onclick='() => ToggleSort("Id")'># @SortGlyph("Id")</th>
            <th class="@SortHeaderClass" @onclick='() => ToggleSort("Name")'>Name @SortGlyph("Name")</th>
            <th class="@SortHeaderClass" @onclick='() => ToggleSort("Job")'>Job @SortGlyph("Job")</th>
            <th class="@SortHeaderClass" @onclick='() => ToggleSort("Country")'>Location @SortGlyph("Country")</th>
            <th>Color</th>
        </tr>
    </thead>
    <tbody>
        @foreach (var p in PagedRows)
        {
            <tr class="@(_selected.Contains(p.Id) ? "bg-base-200" : null)">
                <th>
                    <DCheckbox Value="@_selected.Contains(p.Id)"
                               ValueChanged="@((bool v) => Toggle(p.Id, v))"
                               aria-label="@($"Select {p.Name}")" />
                </th>
                <th>@p.Id</th>
                <td class="font-semibold">@p.Name</td>
                <td>@p.Job</td>
                <td>@p.Country</td>
                <td><span class="flex items-center gap-2"><DStatus Color="@DotColor(p.Color)" Size="DaisyStatusSize.Medium" />@p.Color</span></td>
            </tr>
        }
        @if (PagedRows.Count == 0)
        {
            <tr><td colspan="6" class="text-center opacity-60 py-6">No row matches &ldquo;@_search&rdquo;</td></tr>
        }
    </tbody>
</DTable>
 
<DPagination @bind-Page="_page" PageCount="@PageCount" Size="DaisySize.Small" />
<span class="text-sm opacity-70">page @CurrentPage of @Math.Max(PageCount, 1)</span>
 
@code {
    private static DaisyColor DotColor(string color) => color switch
    {
        "Blue" or "Indigo" or "Aquamarine" => DaisyColor.Info,
        "Purple" => DaisyColor.Secondary,
        "Red" or "Crimson" or "Maroon" => DaisyColor.Error,
        "Green" => DaisyColor.Success,
        "Yellow" => DaisyColor.Warning,
        _ => DaisyColor.Primary,
    };
 
    private List<Person> _rows = [];
    private readonly HashSet<int> _selected = [];
    private string _search = "";
    private string _sortKey = "Id";
    private bool _sortAscending = true;
    private int _page = 1;
    private const int PageSize = 5;
 
    protected override void OnInitialized() => _rows = [.. _people];
 
    private IEnumerable<Person> Filtered()
    {
        IEnumerable<Person> query = _rows;
        if (!string.IsNullOrWhiteSpace(_search))
        {
            query = query.Where(p =>
                p.Name.Contains(_search, StringComparison.OrdinalIgnoreCase) ||
                p.Job.Contains(_search, StringComparison.OrdinalIgnoreCase) ||
                p.Company.Contains(_search, StringComparison.OrdinalIgnoreCase));
        }
 
        return _sortKey switch
        {
            "Name" => _sortAscending ? query.OrderBy(p => p.Name) : query.OrderByDescending(p => p.Name),
            "Job" => _sortAscending ? query.OrderBy(p => p.Job) : query.OrderByDescending(p => p.Job),
            "Country" => _sortAscending ? query.OrderBy(p => p.Country) : query.OrderByDescending(p => p.Country),
            _ => _sortAscending ? query.OrderBy(p => p.Id) : query.OrderByDescending(p => p.Id),
        };
    }
 
    private int PageCount => (int)Math.Ceiling(Filtered().Count() / (double)PageSize);
 
    private int CurrentPage => Math.Min(_page, Math.Max(PageCount, 1));
 
    private List<Person> PagedRows => Filtered().Skip((CurrentPage - 1) * PageSize).Take(PageSize).ToList();
 
    private bool AllSelected => PagedRows.Count > 0 && PagedRows.All(p => _selected.Contains(p.Id));
 
    private void Toggle(int id, bool selected)
    {
        if (selected)
        {
            _selected.Add(id);
        }
        else
        {
            _selected.Remove(id);
        }
    }
 
    private void ToggleAll(bool select)
    {
        foreach (var p in PagedRows)
        {
            if (select)
            {
                _selected.Add(p.Id);
            }
            else
            {
                _selected.Remove(p.Id);
            }
        }
    }
 
    private const string SortHeaderClass = "cursor-pointer select-none whitespace-nowrap";
 
    /// <summary>Dim chevron on inactive columns, pointing up when the column sorts ascending.</summary>
    private string SortIconClass(string key)
        => _sortKey == key ? (_sortAscending ? "opacity-100 rotate-180" : "opacity-100") : "opacity-30";
 
    private RenderFragment SortGlyph(string key) => builder =>
    {
        builder.OpenComponent<DIcon>(0);
        builder.AddComponentParameter(1, nameof(DIcon.Icon), DaisyIcons.ChevronDown);
        builder.AddComponentParameter(2, nameof(DIcon.Size), DaisySize.ExtraSmall);
        builder.AddComponentParameter(3, nameof(DIcon.Class), SortIconClass(key));
        builder.CloseComponent();
    };
 
    private void ToggleSort(string key)
    {
        if (_sortKey == key)
        {
            _sortAscending = !_sortAscending;
        }
        else
        {
            _sortKey = key;
            _sortAscending = true;
        }
    }
 
    private void DeleteSelected()
    {
        _rows = _rows.Where(p => !_selected.Contains(p.Id)).ToList();
        _selected.Clear();
    }
 
    private void Reset()
    {
        _rows = [.. _people];
        _selected.Clear();
        _search = "";
        _sortKey = "Id";
        _sortAscending = true;
        _page = 1;
    }
 
    private void ResetPage() => _page = 1;
}

Tips

  • table-pin-rows / table-pin-cols only do something inside a scroll container (a div with overflow-auto and a height/width cap) - daisy pins with position: sticky.
  • daisy pins the first and last column, not an arbitrary one.
  • There is no table-active or hover class in daisy v5: put a Tailwind bg-base-200 / hover:bg-base-300 utility on the <tr>.
  • The wrapper usually wants overflow-x-auto so wide tables scroll instead of breaking the layout.
  • DTable is data-agnostic on purpose: sorting, paging and selection are ordinary C# (see the grid above), so they keep working while the markup stays daisy's.

API

DTable

Parameters

Name Type Default Binding Description
Zebra bool False — Alternating row background ( table-zebra ).
PinRows bool False — Sticky header row(s) ( table-pin-rows ).
PinCols bool False — Sticky first column ( table-pin-cols ).
Size DaisySize Medium — Density: table-xs / table-sm / table-lg (Medium = daisy default).
ExtraSmallSmallMediumLargeExtraLarge
ChildContent RenderFragment — — The table markup (caption, thead, tbody, ...).
Class string — — Additional CSS classes appended to the component's computed daisyUI classes.
Style string — — Inline styles applied to the root element.
DInput

Parameters

Name Type Default Binding Description
Type string text — The HTML input type (text, password, email, number, date, ...). Default: text.
Placeholder string — — Placeholder text shown inside the input when empty.
Label string — — Optional label rendered above the input.
Size DaisySize Medium — Sizes the input via daisyUI (input-xs, input-sm, input-lg).
ExtraSmallSmallMediumLargeExtraLarge
Disabled bool False — Disables the input.
Validator bool False — Adds daisyUI's validator class so a sibling DValidator hint can appear purely via CSS ( :user-invalid ) — no Blazor validation required.
Class string — — —
Style string — — —
Value string — @bind-Value —
ValueExpression Expression<Func<string>> — — —
DisplayName string — — —
DCheckbox

Parameters

Name Type Default Binding Description
Label string — — Optional label rendered next to the checkbox.
Disabled bool False — Disables the checkbox.
Size DaisySize Medium — Size via daisyUI (checkbox-xs/sm/lg).
ExtraSmallSmallMediumLargeExtraLarge
Class string — — —
Style string — — —
Value bool False @bind-Value —
ValueExpression Expression<Func<bool>> — — —
DisplayName string — — —
DPagination

Parameters

Name Type Default Binding Description
Page int 1 @bind-Page Current page (1-based) — use with @bind-Page .
PageCount int 1 — Total number of pages.
MaxButtons int 5 — Maximum number of numbered slots before ellipses kick in.
Size DaisySize Medium — Button size (btn-xs ... btn-lg).
ExtraSmallSmallMediumLargeExtraLarge
Color DaisyColor Default — Color for all buttons (the active page additionally gets btn-active ).
DefaultPrimarySecondaryAccentInfoSuccessWarningErrorGhostNeutral
ShowPrevNext bool True — Show the « and » buttons.
PrevText string « — Label of the previous button.
NextText string » — Label of the next button.
EllipsisText string … — Label rendered in ellipse slots.
Class string — — Additional CSS classes appended to the component's computed daisyUI classes.
Style string — — Inline styles applied to the root element.
DAvatar

Parameters

Name Type Default Binding Description
Src string — — Image URL. When empty, the avatar renders in placeholder mode using the Placeholder content.
Alt string — — The alt attribute of the rendered <img> .
SizeClass string w-12 — Tailwind width/size utility for the inner element, e.g. w-24 .
Shape DaisyAvatarShape Squircle — Corner shape of the avatar ( rounded-box , rounded-full , or square).
SquareSquircleCircle
Status DaisyStatus None — Online/offline indicator rendered by daisyUI.
NoneOnlineOffline
Placeholder RenderFragment — — Content shown when Src is not set (initials, icon, ...).
Class string — — Additional CSS classes appended to the component's computed daisyUI classes.
Style string — — Inline styles applied to the root element.
DBadge

Parameters

Name Type Default Binding Description
Color DaisyColor Default — Contextual color (e.g. badge-primary , badge-ghost ); Default emits no class.
DefaultPrimarySecondaryAccentInfoSuccessWarningErrorGhostNeutral
Variant DaisyVariant Default — Style variant (e.g. badge-outline ); Default emits no class.
DefaultOutlineDashSoftLink
Size DaisySize Medium — Size (e.g. badge-xs , badge-lg ); Medium emits no class.
ExtraSmallSmallMediumLargeExtraLarge
Shape DaisyShape Default — Corner shape ( badge-circle , badge-rect ); Default emits no class.
DefaultCircleRect
IconStart DaisyIcon — — Icon rendered before the badge content.
IconEnd DaisyIcon — — Icon rendered after the badge content.
IconSize DaisySize? — — Icon size; defaults to the badge Size when null .
ExtraSmallSmallMediumLargeExtraLarge
ChildContent RenderFragment — — The badge's inner text and content.
Class string — — Additional CSS classes appended to the component's computed daisyUI classes.
Style string — — Inline styles applied to the root element.
DStatus

Parameters

Name Type Default Binding Description
Color DaisyColor Default — Semantic color of the dot ( status-primary , status-error , ...).
DefaultPrimarySecondaryAccentInfoSuccessWarningErrorGhostNeutral
Size DaisyStatusSize Default — Dot size ( status-xs ... status-xl ).
DefaultXSmallSmallMediumLargeExtraLarge
Label string — — Accessible label (rendered as aria-label ).
Class string — — Additional CSS classes appended to the component's computed daisyUI classes.
Style string — — Inline styles applied to the root element.
DTooltip

Parameters

Name Type Default Binding Description
Tip string — — The tooltip text. Keep it short; it is rendered as a CSS pseudo-element.
Position DaisyTooltipPosition Top — Which side the tooltip appears on. Top is the default.
TopBottomLeftRight
Open bool False — Forces the tooltip to stay visible ( tooltip-open ), useful for demos and touch devices.
ChildContent RenderFragment — — The element the tooltip is attached to.
Class string — — Additional CSS classes appended to the component's computed daisyUI classes.
Style string — — Inline styles applied to the root element.
DIcon

Parameters

Name Type Default Binding Description
Icon DaisyIcon — — The icon to render (built-in from DaisyIcons or String) ).
Size DaisySize Medium — Rendered size (xs=12px, sm=14px, md=16px, lg=20px) via inline width/height.
ExtraSmallSmallMediumLargeExtraLarge
StrokeWidth double 1.5 — Stroke width for built-in glyphs (heroicons geometry is designed for 1.5).
Label string — — Accessible label. When set the icon gets role="img" + aria-label ; otherwise it is hidden from assistive tech (decorative).
Class string — — Additional CSS classes appended to the component's computed daisyUI classes.
Style string — — Inline styles applied to the root element.
DButton

Parameters

Name Type Default Binding Description
Type string button — The native type attribute: button , submit or reset .
Color DaisyColor Default — Contextual color (e.g. btn-primary , btn-ghost ); Default emits no class.
DefaultPrimarySecondaryAccentInfoSuccessWarningErrorGhostNeutral
Variant DaisyVariant Default — Style variant (e.g. btn-outline , btn-soft ); Default emits no class.
DefaultOutlineDashSoftLink
Size DaisySize Medium — Size (e.g. btn-xs , btn-lg ); Medium emits no class.
ExtraSmallSmallMediumLargeExtraLarge
Disabled bool False — Disables the button (native disabled ).
IconStart DaisyIcon — — Icon rendered before the button content (daisy's btn gap handles spacing).
IconEnd DaisyIcon — — Icon rendered after the button content.
IconSize DaisySize? — — Icon size; defaults to the button Size when null .
ExtraSmallSmallMediumLargeExtraLarge
Shape DaisyButtonShape Default — btn-square / btn-circle — use with an icon and no text for icon-only buttons.
DefaultSquareCircle
Wide bool False — btn-wide : widens the button to width:100% of its container, capped at 16rem . When both Wide and Block are set, btn-block wins on width (it is declared later in daisyUI's cascade at equal specificity) and the button fills its container, still capped at 16rem by btn-wide 's max-width .
Block bool False — btn-block : the button fills the full width of its container ( width:100% ). When both Block and Wide are set, btn-block wins on width (it is declared later in daisyUI's cascade at equal specificity).
ChildContent RenderFragment — — The button's inner text and content.
OnClick EventCallback<MouseEventArgs> — — Invoked when the button is clicked.
Class string — — Additional CSS classes appended to the component's computed daisyUI classes.
Style string — — Inline styles applied to the root element.
Connection lost — reconnecting…
Connection failed.
The server has stopped.