diff --git a/server/static/client.js b/server/static/client.js index 1d9f1b4..40e39e3 100644 --- a/server/static/client.js +++ b/server/static/client.js @@ -394,6 +394,8 @@ class NeovimClient { translateKey(event) { const { key, code, ctrlKey, altKey, shiftKey, metaKey } = event; + // for See + // https://pkg.go.dev/github.com/neovim/go-client/nvim#Nvim.Input const specialKeys = { Enter: "", Escape: "", @@ -410,6 +412,7 @@ class NeovimClient { ArrowLeft: "", ArrowRight: "", " ": "", + "<": "", }; for (let i = 1; i <= 12; i++) { @@ -417,10 +420,22 @@ class NeovimClient { } let modifiers = ""; - if (ctrlKey) modifiers += "C-"; - if (altKey) modifiers += "A-"; - if (metaKey) modifiers += "D-"; - if (shiftKey && !this.isShiftableKey(key)) modifiers += "S-"; + + if (ctrlKey) { + modifiers += "C-"; + } + + if (altKey) { + modifiers += "A-"; + } + + if (metaKey) { + modifiers += "D-"; + } + + if (shiftKey && !this.isShiftableKey(key)) { + modifiers += "S-"; + } if (specialKeys[key]) { if (modifiers) {