mirror of
https://github.com/LazyVim/LazyVim.git
synced 2025-07-13 02:44:39 +02:00
feat: consistent prompt symbols for all pickers
This commit is contained in:
parent
dd5a5fb4cd
commit
0d05715411
1 changed files with 16 additions and 4 deletions
|
@ -31,7 +31,7 @@ return {
|
||||||
{
|
{
|
||||||
"ibhagwan/fzf-lua",
|
"ibhagwan/fzf-lua",
|
||||||
event = "VeryLazy",
|
event = "VeryLazy",
|
||||||
opts = function()
|
opts = function(_, opts)
|
||||||
local config = require("fzf-lua.config")
|
local config = require("fzf-lua.config")
|
||||||
local actions = require("fzf-lua.actions")
|
local actions = require("fzf-lua.actions")
|
||||||
|
|
||||||
|
@ -51,10 +51,22 @@ return {
|
||||||
end
|
end
|
||||||
config.defaults.actions.files["alt-c"] = config.defaults.actions.files["ctrl-r"]
|
config.defaults.actions.files["alt-c"] = config.defaults.actions.files["ctrl-r"]
|
||||||
|
|
||||||
return {
|
-- use the same prompt for all
|
||||||
[1] = "default-title",
|
local defaults = require("fzf-lua.profiles.default-title")
|
||||||
|
local function fix(t)
|
||||||
|
t.prompt = t.prompt ~= nil and " " or nil
|
||||||
|
for _, v in pairs(t) do
|
||||||
|
if type(v) == "table" then
|
||||||
|
fix(v)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
fix(defaults)
|
||||||
|
|
||||||
|
return vim.tbl_deep_extend("force", opts, defaults, {
|
||||||
fzf_colors = true,
|
fzf_colors = true,
|
||||||
files = {
|
files = {
|
||||||
|
cwd_prompt = false,
|
||||||
actions = {
|
actions = {
|
||||||
["alt-i"] = { actions.toggle_ignore },
|
["alt-i"] = { actions.toggle_ignore },
|
||||||
["alt-h"] = { actions.toggle_hidden },
|
["alt-h"] = { actions.toggle_hidden },
|
||||||
|
@ -66,7 +78,7 @@ return {
|
||||||
["alt-h"] = { actions.toggle_hidden },
|
["alt-h"] = { actions.toggle_hidden },
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
})
|
||||||
end,
|
end,
|
||||||
keys = {
|
keys = {
|
||||||
{ "<esc>", "<cmd>close<cr>", ft = "fzf", mode = "t", nowait = true },
|
{ "<esc>", "<cmd>close<cr>", ft = "fzf", mode = "t", nowait = true },
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue