import { VimMode } from '../main/neovim/types' ; export const normalizeVimMode = ( mode ) : VimMode => { if ( mode === 't' ) return VimMode . Terminal ; if ( mode === 'n' || mode === 'normal' ) return VimMode . Normal ; if ( mode === 'i' || mode === 'insert' ) return VimMode . Insert ; if ( mode === 'V' || mode === 'visual' ) return VimMode . Visual ; if ( mode === 'R' || mode === 'replace' ) return VimMode . Replace ; if ( mode === 'no' || mode === 'operator' ) return VimMode . Operator ; if ( mode === 'c' || mode === 'cmdline_normal' ) return VimMode . CommandNormal ; if ( mode === 'cmdline_insert' ) return VimMode . CommandInsert ; if ( mode === 'cmdline_replace' ) return VimMode . CommandReplace ; else return VimMode . SomeModeThatIProbablyDontCareAbout ; } ;