TrimRows
Members
PLUGIN_KEY
TrimRows.PLUGIN_KEY
Returns the plugin key used to identify this plugin in Handsontable settings.
PLUGIN_PRIORITY
TrimRows.PLUGIN_PRIORITY
Returns the priority order used to determine the order in which plugins are initialized.
SETTING_KEYS
TrimRows.SETTING_KEYS
Returns the list of settings keys observed by the plugin for configuration changes.
Methods
destroy
trimRows.destroy()
Destroys the plugin instance.
disablePlugin
trimRows.disablePlugin()
Disables the plugin functionality for this Handsontable instance.
enablePlugin
trimRows.enablePlugin()
Enables the plugin functionality for this Handsontable instance.
getTrimmedRows
trimRows.getTrimmedRows() ⇒ Array
Get list of trimmed rows.
Returns: Array - Physical rows.
isEnabled
trimRows.isEnabled() ⇒ boolean
Checks if the plugin is enabled in the handsontable settings. This method is executed in Hooks#beforeInit
hook and if it returns true then the TrimRows#enablePlugin method is called.
When [[Options#dataProvider]] is a complete server-backed configuration, the DataProvider plugin blocks this plugin from enabling.
isTrimmed
trimRows.isTrimmed(physicalRow) ⇒ boolean
Checks if given row is hidden.
| Param | Type | Description |
|---|---|---|
| physicalRow | number | Physical row index. |
isValidConfig
trimRows.isValidConfig(trimmedRows) ⇒ boolean
Get if trim config is valid. Check whether all of the provided physical row indexes are within source data.
| Param | Type | Description |
|---|---|---|
| trimmedRows | Array | List of physical row indexes. |
trimRow
trimRows.trimRow(…row)
Trims the row provided as a physical row index (counting from 0).
| Param | Type | Description |
|---|---|---|
| …row | number | Physical row index. |
trimRows
trimRows.trimRows(rows)
Trims the rows provided in the array.
Emits: Hooks#event:beforeTrimRow, Hooks#event:afterTrimRow
| Param | Type | Description |
|---|---|---|
| rows | Array<number> | Array of physical row indexes. |
untrimAll
trimRows.untrimAll()
Untrims all trimmed rows.
untrimRow
trimRows.untrimRow(…row)
Untrims the row provided as a physical row index (counting from 0).
| Param | Type | Description |
|---|---|---|
| …row | number | Physical row index. |
untrimRows
trimRows.untrimRows(rows)
Untrims the rows provided in the array.
Emits: Hooks#event:beforeUntrimRow, Hooks#event:afterUntrimRow
| Param | Type | Description |
|---|---|---|
| rows | Array<number> | Array of physical row indexes. |
updatePlugin
trimRows.updatePlugin()
Updates the plugin’s state.
This method is executed when updateSettings() is invoked with any of the following configuration options: