Multi-Range Selection
Select, edit, clear, and copy disjoint cell ranges. Read the guide
SelectionPlugin is the master entry point for spreadsheet-style selection in
RevoGrid Pro. It composes the compatible cell, row, and column selection
runtimes while keeping their existing events, configuration, and public methods
available.
import { SelectionPlugin, rowHeaders,} from '@revolist/revogrid-pro';
const grid = document.createElement('revo-grid');
grid.range = true;grid.rowHeaders = rowHeaders({ showHeaderFocusBtn: false });grid.columns = [ { prop: 'selected', name: '', size: 52, rowSelect: true }, { prop: 'name', name: 'Name' }, { prop: 'team', name: 'Team' },];grid.plugins = [SelectionPlugin];One registration enables Ctrl/Cmd multi-range selection, whole-row selection
from row headers, whole-column selection from column headers, checkbox row
selection for rowSelect columns, and optional range constraints.
| Runtime | Responsibility | Activation/configuration |
|---|---|---|
MultiRangeSelectionPlugin | Disjoint cell ranges, shared range rendering, clipboard operations, and range edits | Set grid.range = true for range gestures; configure grid.multiRangeSelection when needed |
RowHeaderPlugin | Excel-style whole-row selection and full-width row ranges | Configure grid.rowHeaders |
ColumnSelectionPlugin | Whole-column selection from headers and keyboard shortcuts | Active when the suite is installed |
RowSelectPlugin | Independent checkbox/programmatic row selection | Add rowSelect: true to a column; configure grid.rowSelect when needed |
RangeSelectionLimitPlugin | Optional row-only or column-only interactive ranges | Disabled until grid.rangeSelectionLimit is set |
The suite installs these runtimes in dependency order and reuses any instance that is already present. This is safe, although redundant:
grid.plugins = [SelectionPlugin, RowSelectPlugin];// There is still only one RowSelectPlugin runtime.Use individual plugins instead of SelectionPlugin when the application needs
only a smaller subset.
The master plugin does not introduce another selection store. Each included plugin remains the sole owner of its existing state:
rowselected events.const plugins = await grid.getPlugins();const ranges = plugins .find(plugin => plugin instanceof MultiRangeSelectionPlugin) ?.getSelectedRanges();Multi-Range Selection
Select, edit, clear, and copy disjoint cell ranges. Read the guide
Column Selection
Select, extend, and toggle complete columns. Read the guide
Row Selection
Configure checkbox rows and Excel-style row-header gestures. Read the guide
Range Selection Limit
Restrict interactive ranges to one row or one column. Read the guide
Range Copy Preview
Add the optional exact-copy drag preview. Read the guide
See the SelectionPlugin API reference for the exported
class and dependency metadata.