Skip to content

Commit

Permalink
fix(calendar): give calendar enough space to render (#950)
Browse files Browse the repository at this point in the history
  • Loading branch information
TJ-Adams authored Jun 20, 2023
1 parent 9a55117 commit 6fece15
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lua/neorg/modules/core/ui/calendar/module.lua
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,11 @@ module.private = {
end,

open_window = function(options)
local MIN_HEIGHT = 14

local buffer, window = module.required["core.ui"].create_split(
"calendar-" .. tostring(os.clock()):gsub("%.", "-"),
{},
options.height or math.floor(vim.opt.lines:get() * 0.3)
{}, options.height or MIN_HEIGHT + (options.padding or 0)
)

vim.api.nvim_create_autocmd({ "WinClosed", "BufDelete" }, {
Expand Down

0 comments on commit 6fece15

Please sign in to comment.