adopted-ember-addons / adopted-ember-addons/ember-light-table

Row selection has no keyboard support

Offen
#236 10 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
enhancement
Vorherrschende Sprache
JavaScript
Sterne
311
Forks
130
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

One idea is to allow `tab` to focus on each row. While focused, an `enter` (or `space`) press would select that row. If the `ctrl` / `cmd` modifier is used when selecting, it would add/remove the row to the existing selection. If `shift` modifier is used, it would select a range of rows.

While a row is selected, the `up` and `down` arrows could move from one row to another (without activating them) -- this is where the `shift` modifier would be useful.

Row states:
- focused (user used `tab` to focus the row); with a mouse, this is achieve via a `click`
- selected (user hit `enter` while row was `focused`; with a mouse, this is achieved a `click`
- highlighted (user uses `up` or `down` to move between rows without focusing the row); with a mouse, this is achieve via `hovering`

I've built something like this before with angular and it wasn't too bad to implement (but I wasn't working with a general purpose table widget so I could use more hacks and dirty tricks that would be acceptable for a large project).

Would PRs implementing something like this be accepted? I don't really have a ton of time to focus on this right now but perhaps with a little guidance on implementation strategy me or someone else could take a stab at this.

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.