bubbles icon indicating copy to clipboard operation
bubbles copied to clipboard

fix(viewport): preempt potential panics when calculating visible lines

Open meowgorithm opened this issue 5 months ago • 0 comments

This adds some checks to prevent slice out-of-bounds errors when calculating visible lines in the viewport.

This will fix the panic we're seeing in https://github.com/charmbracelet/gum/issues/660#issuecomment-2323328662 (though we still need to address the zero-height-by-default thing).

meowgorithm avatar Sep 02 '24 01:09 meowgorithm