@@ -445,7 +445,11 @@ func (p *permissionDialogCmp) render() string {
445445 contentFinal := p.getOrGenerateContent()
446446
447447 // Always set viewport content (the caching is handled in getOrGenerateContent)
448− contentHeight := min(p.height-9, lipgloss.Height(contentFinal))
448+ const minContentHeight = 9
449+ contentHeight := min(
450+ max(minContentHeight, p.height-minContentHeight),
451+ lipgloss.Height(contentFinal),
452+ )
449453 p.contentViewPort.SetHeight(contentHeight)
450454 p.contentViewPort.SetContent(contentFinal)
451455