EditSettings

Represents the configuration options for enabling and customizing editing behavior in a grid component. This interface provides control over record-level operations such as adding, editing, and deleting, as well as customization of edit modes, confirmation dialogs, and integration of custom templates.

Props

The following table outlines the props for the EditSettings:

NameTypeDefaultDescription
allowAdd
boolean
false

Determines whether new records can be added to the grid. When this property is set to true, new rows can be inserted either through programmatic methods or by using toolbar 'Add' action. To enable this functionality, at least one column must be defined as a primary key using the isPrimaryKey property in the column configuration.

allowDelete
boolean
false

Determines whether records can be deleted from the grid. When this property is enabled, rows can be removed either programmatically or through toolbar 'Delete' action. Deletion operations require that at least one column is configured as a primary key.

allowEdit
boolean
false

Determines whether existing records in the grid can be edited. When this property is set to true, users can modify cell values in existing rows either through programmatic updates or via toolbar 'Edit' interaction. Editing requires that at least one column is marked as a primary key using the isPrimaryKey property.

confirmOnDelete
boolean
false

Controls whether a confirmation dialog is displayed before deleting a record. When enabled, users are prompted to confirm the deletion action to prevent accidental data loss. If disabled, records are deleted immediately without confirmation.

confirmOnEdit
boolean
true

Controls whether a confirmation dialog is displayed when saving or discarding changes. When enabled, the grid prompts users to confirm actions such as saving edits, cancelling changes, or navigating away from an edited row. If disabled, these actions proceed without confirmation.

editOnDoubleClick
boolean
true

Indicates whether double-clicking a row should activate edit mode in the Data Grid. When set to true, users can initiate editing by double-clicking a row. If set to false, double-click interactions will not trigger edit mode. This property is useful for controlling interaction behavior in editable grids.

mode
'Normal'

Specifies the editing mode used within the grid. The editing mode defines how users interact with editable cells. Supported modes include:

  • Normal :- Inline editing directly within grid cells.
  • Popup :- Modal dialog with auto-generated form fields.
  • PopupTemplate :- Modal dialog with custom template.
newRowPosition
'Top' | NewRowPosition.Top

Specifies the position at which a new row is inserted into the grid. Supported values include:

  • Top: Inserts the new row at the beginning of the grid.
  • Bottom: Inserts the new row at the end of the grid.
popupSettings
null

Configuration settings for customizing the Syncfusion Dialog component used in popup edit mode. Accepts any valid Dialog component props for popup styling, positioning, and behavior customization.

popupTemplate
ComponentType<PopupTemplateProps<T>>
null

Custom React component template for rendering the popup edit form. Used with PopupTemplate mode to display custom form layouts in the modal dialog.

template
ComponentType<EditFormTemplate<T>>
null

Specifies a custom React component to be used as the edit template for grid rows. This component replaces the default editing interface and receives the current row data as props. It can be used to implement advanced form layouts, validation logic, or custom component integrations.