From d0450dcce8d84f613f8ab1be20eddaef93e829b8 Mon Sep 17 00:00:00 2001 From: ardevd Date: Mon, 8 Jan 2024 09:21:10 +0100 Subject: [PATCH] fix(invoice): added width boundary to invoice string (#16) --- internal/tui/invoice.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/tui/invoice.go b/internal/tui/invoice.go index 461ee5f..12dd584 100644 --- a/internal/tui/invoice.go +++ b/internal/tui/invoice.go @@ -297,7 +297,7 @@ func (m InvoiceModel) View() string { case huh.StateCompleted: b := strings.Builder{} fmt.Fprintf(&b, "\n%s\n", s.HeaderText.Render("Invoice Ready")) - fmt.Fprintf(&b, "\n%s\n\n", invoiceVal) + fmt.Fprintf(&b, "\n%s\n\n", s.Base.Width(windowSizeMsg.Width-10).Render(invoiceVal)) fmt.Fprintf(&b, "%s\n", m.printQrCode()) return lipgloss.JoinVertical(lipgloss.Left, s.BorderedStyle.Render(b.String()))