GKit.UI.MudBlazorExt 1.1.2

There is a newer version of this package available.
See the version list below for details.
dotnet add package GKit.UI.MudBlazorExt --version 1.1.2
                    
NuGet\Install-Package GKit.UI.MudBlazorExt -Version 1.1.2
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="GKit.UI.MudBlazorExt" Version="1.1.2" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="GKit.UI.MudBlazorExt" Version="1.1.2" />
                    
Directory.Packages.props
<PackageReference Include="GKit.UI.MudBlazorExt" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add GKit.UI.MudBlazorExt --version 1.1.2
                    
#r "nuget: GKit.UI.MudBlazorExt, 1.1.2"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package GKit.UI.MudBlazorExt@1.1.2
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=GKit.UI.MudBlazorExt&version=1.1.2
                    
Install as a Cake Addin
#tool nuget:?package=GKit.UI.MudBlazorExt&version=1.1.2
                    
Install as a Cake Tool

GKit.UI.MudBlazorExt

MudBlazor adapter for the GKit UI components. Succeeds GKit.MudBlazorExt.

The components here are presentation only; paging, the DbContext lifecycle, CRUD orchestration, ordering and export live in GKit.UI.Data and reference no component library. GKit.UI.RadzenExt is the sibling adapter over the same engine.

An application picks one adapter. Both expose the same component names, type parameters and parameter names, so moving a page between them is a package swap, an @using change, and a rewrite of the column markup and form bodies — see GKit.UI.RadzenExt's README for the differences that survive the abstraction.

Setup

builder.Services.AddMudServices();          // MudBlazor's own setup
builder.Services.AddMudTranslations();      // optional, MudBlazor's internal strings
builder.Services.AddGKitBlazorServices();   // GKit.BlazorExt
builder.Services.AddGKitMudBlazorUi();      // this package (calls AddGKitUiCore internally)
builder.Services.AddGKitUiLocalization();   // optional, for Italian
@* _Imports.razor *@
@using MudBlazor
@using GKit.BlazorExt
@using GKit.UI
@using GKit.UI.Data
@using GKit.UI.MudBlazorExt

Components

Component Purpose
ManagedGrid<T> Virtualised server-side MudDataGrid with toolbar, row controls and XLSX export
EntityGrid<T, TDialog> ManagedGrid plus create / edit / delete against an EF entity
EditEntityDialog<T, TForm, TValidator> Dialog shell hosting a form, validated by FluentValidation
EntityAutocomplete<T> / EntityItemAutocomplete<T, TItem> Lookup over a DbContext, with inline create
ManagedAutocomplete<T> / ManagedItemAutocomplete<T, TItem> Lookup over an arbitrary fetch delegate
DataAutocomplete<T> Lookup over a pre-built query
ManagedText Text with copy-to-clipboard and optional masking

Revealing clipped cell values

A column narrow enough to be readable is narrow enough to clip its own content. GKitCellReveal clips the value to one line and, on hover, opens a panel over the cell showing the whole of it. The panel's text is selectable — that is how a user copies it, so there is no copy button.

There are two ways in, and which you want depends on whether you are also supplying your own cell content.

1. The column — automatic

GKitPropertyColumn<T, TProperty> derives from MudBlazor's PropertyColumn<T, TProperty> and supplies the reveal for you. Adopting it is a one-token edit:

- <PropertyColumn T="Order" TProperty="string" Property="x => x.Notes" Title="Notes" />
+ <GKitPropertyColumn T="Order" TProperty="string" Property="x => x.Notes" Title="Notes" />

Every inherited parameter keeps working — sorting, filtering, Format, width, visibility — because they are inherited rather than reimplemented.

Parameter Default Purpose
Ellipsis true Set false for a column whose values are short enough that clipping only adds noise
PopoverClass — CSS classes for the revealed panel's popover
ListClass — CSS classes for the list around the panel

2. The component — anywhere you author cell content

GKitCellReveal is public, so you can place it yourself — in a TemplateColumn, or anywhere else:

<TemplateColumn T="Order" Title="Notes">
  <CellTemplate>
    <GKitCellReveal Value="@context.Item.Notes" />
  </CellTemplate>
</TemplateColumn>

How the two relate

Supplying your own CellTemplate on a GKitPropertyColumn opts out of the automatic reveal — the library renders your content and never wraps or discards it. If you want custom content and the reveal, place the component inside your own template:

<GKitPropertyColumn T="Order" TProperty="string" Property="x => x.Notes" Title="Notes">
  <CellTemplate>
    <MudIcon Icon="@Icons.Material.Filled.Notes" Size="Size.Small" />
    <GKitCellReveal Value="@context.Item.Notes" />
  </CellTemplate>
</GKitPropertyColumn>

Worth knowing

  • The reveal opens whether or not the value actually overflows. Suppressing it for text that happens to fit needs DOM measurement the component model cannot do without JavaScript, and the cost outweighs the benefit.
  • No setup is required. The appearance ships as scoped CSS, which a Razor Class Library bundles into your application's styles — no <link>, no asset copy.
  • It is a menu, not a tooltip. A tooltip hides when the pointer leaves the cell and sits outside the cell's subtree, so the pointer can never reach the revealed text to select it. That is the reason this is built on MudMenu.
  • There is no grid-level switch. ManagedGrid receives your columns as an opaque RenderFragment, and MudDataGrid exposes only row-level hooks, so the per-column edit above is the whole available surface.

Migrating from GKit.MudBlazorExt

The namespace changed and the grid state types are now neutral, so that the same application code compiles against either adapter.

Before After
namespace GKit.MudBlazorExt namespace GKit.UI (contracts) / GKit.UI.MudBlazorExt (components)
ManagedGridRowControlDescriptor<T> GridRowControl<T>
ManagedGridRowControlsVariant GridRowControlsVariant
CellContext<T> in row controls RowContext<T>
Color.Error UiColor.Error
Icons.Material.Filled.Edit UiIcon.Edit, or IconOverride = Icons.Material.Filled.Edit
GridStateVirtualize<T> / GridData<T> in LoadServerData GridQuery<T> / GridPage<T>
QueryFilterExtensions.Where(q, state.FilterDefinitions) state.ApplyFilters(q)
grid.FilterDefinitions grid.Filters (a GridFilterSet<T>)
IEnumerable<IFilterDefinition<T>> parameters GridFilterSet<T>
AbstractValidatorBase<T>, IEditEntityForm<T>, IEditEntityDialog<T> unchanged, now in GKit.UI

Validator classes, EditEntityDialog subclasses, form @code blocks and query factories need no changes beyond the @using.

Loading data

- private async Task<GridData<Item>> LoadServerData(GridStateVirtualize<Item> state, CancellationToken token)
+ private async Task<GridPage<Item>> LoadServerData(GridQuery<Item> state, CancellationToken token)
  {
    using var ctx = await factory.CreateDbContextAsync();
    var query = ctx.Set<Item>().AsQueryable();
-   query = QueryFilterExtensions.Where(query, state.FilterDefinitions);
-   query = QuerySortExtensions.OrderBy(query, state.SortDefinitions);
+   query = state.Apply(query);

-   return new GridData<Item> { TotalItems = await query.CountAsync(token), Items = … };
+   return new GridPage<Item> { TotalItems = await query.CountAsync(token), Items = … };
  }

Row controls

- new ManagedGridRowControlDescriptor<Item> {
+ new GridRowControl<Item> {
    Text = "Download",
-   Icon = Icons.Material.Filled.Download,
-   Color = Color.Primary,
+   Icon = UiIcon.Download,
+   Color = UiColor.Primary,
-   Action = ctx => DoAsync(ctx.Item)
+   Action = ctx => DoAsync(ctx.Item)      // ctx is now RowContext<Item>
  }

Behaviour notes

  • Validation is unchanged. MudForm still drives validation, so the touched-gated save button and ValidationDelay behave exactly as before. Only the Radzen adapter uses EditContext.
  • Filtering and sorting are unchanged. GridQuery<T> carries MudBlazor's own filter and sort application across as delegates rather than reinterpreting them, so a filtered grid produces the same SQL as before.
  • Strings default to English. Reference GKit.UI.Localization and run under it-IT for the previous Italian wording.
  • Delete confirmations are HTML-encoded. The entity description interpolated into the confirmation prompt used to be raw, which made any user-controlled field a stored-XSS sink.
Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.1.5 96 11/5/2026
1.1.3 91 11/4/2026
1.1.2 93 11/4/2026
1.0.0 129 9/23/2026