hi-tm 0.12.2 → 0.12.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -152,6 +152,14 @@ pageIndex = 0, // Default to first page (0-indexed)
|
|
|
152
152
|
const hasAllSelected = descendantIds.every((id) => selectedRows.includes(id));
|
|
153
153
|
return ((hasAnySelected && !hasAllSelected) || (!isRowSelected && hasAnySelected));
|
|
154
154
|
};
|
|
155
|
+
(0, react_1.useEffect)(() => {
|
|
156
|
+
console.time("isIndeterminate-all-rows"); // شروع اندازهگیری زمان کل
|
|
157
|
+
// اجرای تابع برای همه رکوردها
|
|
158
|
+
rows?.forEach((row) => {
|
|
159
|
+
isIndeterminate(row.id);
|
|
160
|
+
});
|
|
161
|
+
console.timeEnd("isIndeterminate-all-rows"); // پایان اندازهگیری زمان کل
|
|
162
|
+
}, [rows, selectedRows]); // وابستگیها: تغییر در دادهها یا انتخابها
|
|
155
163
|
const handleCheckboxChange = (id) => {
|
|
156
164
|
const row = findRowById(id);
|
|
157
165
|
if (!row)
|