feat: add flex

This commit is contained in:
TJ DeVries
2020-09-09 00:18:54 -04:00
parent fe7dec6339
commit a6e8b63709

View File

@@ -138,6 +138,14 @@ layout_strategies.vertical = function(self, max_columns, max_lines, prompt_title
} }
end end
layout_strategies.flex = function(self, max_columns, max_lines, prompt_title)
if max_columns < 100 and max_lines > 20 then
return layout_strategies.vertical(self, max_columns, max_lines, prompt_title)
else
return layout_strategies.horizontal(self, max_columns, max_lines, prompt_title)
end
end
-- TODO: Add "flex" -- TODO: Add "flex"
-- If you don't have enough width, use the height one -- If you don't have enough width, use the height one
-- etc. -- etc.