feat: uncomment custom key event handler (#5831)
This commit is contained in:
@@ -193,16 +193,16 @@ export function useTerminal(options: UseTerminalOptions): UseTerminalReturn {
|
|||||||
term.options.disableStdin = true
|
term.options.disableStdin = true
|
||||||
term.write('\x1b[?25l')
|
term.write('\x1b[?25l')
|
||||||
|
|
||||||
// term.attachCustomKeyEventHandler((e) => {
|
term.attachCustomKeyEventHandler((e) => {
|
||||||
// if (e.type !== 'keydown') return true
|
if (e.type !== 'keydown') return true
|
||||||
// const mod = e.ctrlKey || e.metaKey
|
const mod = e.ctrlKey || e.metaKey
|
||||||
// if (!mod) return true
|
if (!mod) return true
|
||||||
// const key = e.key.toLowerCase()
|
const key = e.key.toLowerCase()
|
||||||
// if (key === 'c' || key === 'insert' || key === 'a') {
|
if (key === 'c' || key === 'insert' || key === 'a') {
|
||||||
// return false
|
return false
|
||||||
// }
|
}
|
||||||
// return true
|
return true
|
||||||
// })
|
})
|
||||||
|
|
||||||
wheelHandler = (e: WheelEvent) => {
|
wheelHandler = (e: WheelEvent) => {
|
||||||
e.preventDefault()
|
e.preventDefault()
|
||||||
|
|||||||
Reference in New Issue
Block a user