diff --git a/Havit.Blazor.Documentation/Pages/Components/HxGridDoc/HxGrid_Documentation.razor b/Havit.Blazor.Documentation/Pages/Components/HxGridDoc/HxGrid_Documentation.razor
index 8ac28d5b..6a629dda 100644
--- a/Havit.Blazor.Documentation/Pages/Components/HxGridDoc/HxGrid_Documentation.razor
+++ b/Havit.Blazor.Documentation/Pages/Components/HxGridDoc/HxGrid_Documentation.razor
@@ -31,11 +31,11 @@
- When loading data asynchronously, always ensure that the DataProvider
waits for the data to be available;
- otherwise, the skeleton UI (placeholders) will not display correctly.
- If you are preloading data and using the request.ApplyTo(data)
extension method,
- you can leverage TaskCompletionSource
to handle waiting until the data is loaded.
-
DataProvider
waits for the data to be available;
+ otherwise, the skeleton UI (placeholders) will not display correctly.request.ApplyTo(data)
extension method,
+ you can leverage TaskCompletionSource
to handle waiting until the data is loaded.
+
@nameof(HxGrid.SelectedDataItems)
,
+ but their corresponding checkboxes are not marked in the UI after paging or other navigation,
+ it is likely due to issues with data identity.
+
+ By default, equality in C# for class
instances relies on reference equality,
+ meaning two instances with identical data are not considered equal unless they are the same reference.
+
Equals
: Implement a custom equality logic for your data items (e.g., compare by Id
or other key properties).record
: For data items defined as record
, equality is automatically generated by the compiler based on all properties.
+ This issue typically arises when the grid's DataProvider
returns new instances for the same rows during subsequent requests.
+ Since these new instances are not equal to the previously selected ones (based on reference equality),
+ their corresponding rows are not marked as selected in the UI.
+
@nameof(GridContentNavigationMode.InfiniteScroll)
, @nameof(HxGrid.PreserveSelection)="true"
is required for multi-row selection to work.
Attempting to use @nameof(HxGrid.MultiSelectionEnabled)="true"
without enabling PreserveSelection
will result in an exception. Additionally, the "select/deselect all" checkbox is intentionally hidden in this mode,