[!Note] Please note that this control has been deprecated and replaced with the Grid component, and as such, we recommend migrating to that control. This will not be receiving any new features, bug fixes will be deprioritized. For help or questions on migrating your codebase to the Data Grid, please contact support.
Web Components Selección de cuadrícula
La tabla de datos Ignite UI for Web Components / cuadrícula de datos admite la selección de una o varias filas y celdas.
Web Components Grid Selection Example
Descripción general
Selection in the Web Components data grid is enabled on a row and cell level and can be configured by using the selectionMode option of the Web Components grid. This property takes five different options, listed below:
None: La selección no está activada.SingleCell: Se habilita la selección de una sola celda.SingleRow: Se habilita la selección de una sola fila.MultipleCell: Se habilita la selección de varias celdas.MultipleRow: Está habilitada la selección de varias filas.RangeCell: Se habilita la selección de un rango de varias celdas haciendo clic y arrastrando.
selectionBehaviorpor defectoModifierBased, donde solo se selecciona una fila o celda a la vez y se requieren teclas modificadoras (CTRL) para seleccionar múltiples elementos.selectionBehavior Configurado paraToggle permitir seleccionar varias filas o celdas con un solo clic.
MultipleRowincluye la siguiente funcionalidad:
- Haga clic y arrastre para seleccionar filas
- SHIFT y haga clic para seleccionar varias filas.
- SHIFT y pulse las teclas de ↑ flecha+ ↓ para seleccionar varias filas.
Pulsar la barra espaciadora activa la selección de fila activa medianteMultipleRow oSingleRow.
Row Range Selection
El siguiente ejemplo demuestra cómo seleccionar o desseleccionar todas las filas de la cuadrícula. Nota,selectionMode debe estar configurado en Múltiples Filas.