Skip to content

RowCommitDetail

Detail payload for a committed row edit (may or may not include changes).

Fired when a row editing session ends (focus leaves the row). The event is cancelable - call preventDefault() to revert the entire row to its state before editing began.

Use this for row-level validation: if any cells are invalid, reject the entire row edit and force the user to correct the values.

grid.on('row-commit', (detail, e) => {
const editingPlugin = grid.getPluginByName('editing');
if (editingPlugin?.hasInvalidCells(detail.rowId)) {
e.preventDefault(); // Revert row to original values
alert('Please fix validation errors before leaving the row');
}
});
PropertyTypeDescription
rowIndexnumberRow index that lost edit focus.
rowIdstringStable row identifier (from getRowId).
rowTRowRow object reference (current state after edits).
oldValueTRow | undefinedSnapshot of the row before edits (for comparison).
newValueTRowCurrent row value after edits (same as row).
changedbooleanWhether any cell changes were actually committed in this row during the session.
changedRowsTRow[]Current changed row collection.
changedRowIdsstring[]IDs of changed rows.
AI assistants: For complete API documentation, implementation guides, and code examples for this library, see https://raw.githubusercontent.com/OysteinAmundsen/toolbox/main/llms-full.txt