(e: KeyboardEvent)
| 250 | } |
| 251 | |
| 252 | const onScopeKeyDown = (e: KeyboardEvent) => { |
| 253 | if (e.key !== "ArrowLeft" && e.key !== "ArrowRight") return |
| 254 | e.preventDefault() |
| 255 | const step = e.key === "ArrowRight" ? 1 : -1 |
| 256 | const i = mod( |
| 257 | scopes.findIndex(s => s.index === scope) + step, |
| 258 | scopes.length |
| 259 | ) |
| 260 | chooseScope(scopes[i].index) |
| 261 | const radios = e.currentTarget.querySelectorAll<HTMLElement>("[role=radio]") |
| 262 | radios[i]?.focus() |
| 263 | } |
| 264 | |
| 265 | return ( |
| 266 | <div |
nothing calls this directly
no test coverage detected