noice.nvim
noice.nvim copied to clipboard
"max_width" and "max_height" support percentage string
The size of view:
size = {
max_height = '50%',
max_width = '50%',
width = 'auto',
height = 'auto',
}
would perhaps make more sense to use a float number
noice uses nui to show popups. The nui supports number
or percentage string
or table
for size.
@adoyle-h the max_width
and max_height
options are added by Noice. Will see to upstream those and make it so we can have percentages as well
@folke Noice calculate the width. size.width = minmax(size.min_width, size.max_width, dim.width)
https://github.com/folke/noice.nvim/blob/d0eea152566c1f7e15eb297959e4efbd1420a11c/lua/noice/util/nui.lua#L198-L201