anmcgrath / BlazorDatasheet

Simple excel-like datasheet Blazor component
MIT License
163 stars 40 forks source link

Better handle empty rows/empty columns. #79

Closed anmcgrath closed 3 months ago

anmcgrath commented 3 months ago

This PR handles better handles rendering an empty sheet (rows/cols = 0)

The visual sheet should no longer cause a crash as issue #78.

If the sheet has no columns or rows, the fallback is now to render the EmptyColumnsTemplate or EmptyRowsTemplate on the datasheet:

    [Parameter] public RenderFragment? EmptyColumnsTemplate { get; set; }

    [Parameter] public RenderFragment? EmptyRowsTemplate { get; set; }
ADefWebserver commented 3 months ago

Works fine :)
image