feat: add configurable floating window support for memo list

- Added `window` configuration options (enable_float, width, height, border).
- Implemented LazyVim-style floating window logic in UI.
- Updated README (EN/CN) and help docs with new configuration examples.
This commit is contained in:
Elflare
2025-11-29 14:11:38 +08:00
parent 052120b726
commit b4a381c52c
4 changed files with 161 additions and 98 deletions

View File

@@ -43,6 +43,13 @@ require("memos").setup({
-- Number of memos to fetch per page
pageSize = 50,
auto_save = false,
-- Window configuration
window = {
enable_float = false, -- Set to true to open the list in a floating window
width = 0.85, -- Width ratio (0.0 to 1.0)
height = 0.85, -- Height ratio (0.0 to 1.0)
border = "rounded", -- Border style: "single", "double", "rounded", "solid", "shadow"
},
-- Set to false or nil to disable a keymap
keymaps = {
-- Keymap to open the memos list. Default: <leader>mm