diff --git a/lua/keymap.lua b/lua/keymap.lua index 3c2ed23..9fb0071 100644 --- a/lua/keymap.lua +++ b/lua/keymap.lua @@ -45,6 +45,8 @@ do local term = require('toggleterm.terminal').Terminal:new({ direction = wide and 'horizontal' or 'vertical', cmd = cmd, + -- 横屏→高度 10 行;竖屏→宽度 ≈ nvimtree(30 列) + size = wide and 10 or math.floor(ui.width * 0.3), }) term:toggle() end