feat: add border and borderchars
This commit is contained in:
@@ -13,8 +13,6 @@ local function first_non_null(...)
|
|||||||
end
|
end
|
||||||
|
|
||||||
-- TODO: Add other major configuration points here.
|
-- TODO: Add other major configuration points here.
|
||||||
-- border
|
|
||||||
-- borderchars
|
|
||||||
-- selection_strategy
|
-- selection_strategy
|
||||||
|
|
||||||
local config = {}
|
local config = {}
|
||||||
@@ -38,6 +36,9 @@ function config.set_defaults(defaults)
|
|||||||
set("width", 0.75)
|
set("width", 0.75)
|
||||||
set("winblend", 0)
|
set("winblend", 0)
|
||||||
|
|
||||||
|
set("border", {})
|
||||||
|
set("borderchars", { '─', '│', '─', '│', '╭', '╮', '╯', '╰'})
|
||||||
|
|
||||||
-- Builtin configuration
|
-- Builtin configuration
|
||||||
|
|
||||||
-- List that will be executed.
|
-- List that will be executed.
|
||||||
|
|||||||
@@ -116,8 +116,8 @@ function Picker:new(opts)
|
|||||||
results_width = get_default(opts.results_width, 0.8),
|
results_width = get_default(opts.results_width, 0.8),
|
||||||
|
|
||||||
-- Border config
|
-- Border config
|
||||||
border = get_default(opts.border, {}),
|
border = get_default(opts.border, config.values.border),
|
||||||
borderchars = get_default(opts.borderchars, { '─', '│', '─', '│', '╭', '╮', '╯', '╰'}),
|
borderchars = get_default(opts.borderchars, config.values.borderchars),
|
||||||
|
|
||||||
-- WIP:
|
-- WIP:
|
||||||
horizontal_config = get_default(opts.horizontal_config, config.values.horizontal_config),
|
horizontal_config = get_default(opts.horizontal_config, config.values.horizontal_config),
|
||||||
|
|||||||
Reference in New Issue
Block a user