Removed unused keys disable
This commit is contained in:
parent
d80cb707fe
commit
3f896f5603
|
|
@ -70,10 +70,10 @@ export class Scroller {
|
||||||
}
|
}
|
||||||
|
|
||||||
private handleKeydown = (event: KeyboardEvent) => {
|
private handleKeydown = (event: KeyboardEvent) => {
|
||||||
event.preventDefault()
|
|
||||||
console.log(event.key)
|
console.log(event.key)
|
||||||
//* Navigation
|
//* Navigation
|
||||||
if (['ArrowLeft', 'ArrowRight', 'ArrowUp', 'ArrowDown'].includes(event.key)) {
|
if (['ArrowLeft', 'ArrowRight', 'ArrowUp', 'ArrowDown'].includes(event.key)) {
|
||||||
|
event.preventDefault()
|
||||||
this.root.selection.selectedRange = null
|
this.root.selection.selectedRange = null
|
||||||
switch (event.key) {
|
switch (event.key) {
|
||||||
case 'ArrowLeft': {
|
case 'ArrowLeft': {
|
||||||
|
|
@ -109,11 +109,13 @@ export class Scroller {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (event.key === 'F2') {
|
if (event.key === 'F2') {
|
||||||
|
event.preventDefault()
|
||||||
if (!this.root.selection.selectedCell) return;
|
if (!this.root.selection.selectedCell) return;
|
||||||
this.root.showEditor(this.root.selection.selectedCell)
|
this.root.showEditor(this.root.selection.selectedCell)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (event.key === 'Delete') {
|
if (event.key === 'Delete') {
|
||||||
|
event.preventDefault()
|
||||||
this.root.deleteSelectedCellsValues()
|
this.root.deleteSelectedCellsValues()
|
||||||
this.root.renderSheet()
|
this.root.renderSheet()
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue