2026-03-25 08:39:31 +09:00
|
|
|
package editor
|
|
|
|
|
|
|
|
|
|
import (
|
|
|
|
|
"tea.kareha.org/lab/levi/internal/console"
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
const Esc rune = 0x1b
|
|
|
|
|
|
2026-03-25 10:47:11 +09:00
|
|
|
type Keyboard struct{}
|
2026-03-25 08:39:31 +09:00
|
|
|
|
|
|
|
|
func NewKeyboard() Keyboard {
|
|
|
|
|
return Keyboard{}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
func (kb *Keyboard) ReadRune() rune {
|
|
|
|
|
return console.ReadRune()
|
|
|
|
|
}
|