Skip to content

Commit

Permalink
chore: move account address in confirm modal
Browse files Browse the repository at this point in the history
  • Loading branch information
PhearZero committed Nov 13, 2024
1 parent 7b2ff73 commit e3f2e8f
Showing 1 changed file with 7 additions and 10 deletions.
17 changes: 7 additions & 10 deletions ui/modals/confirm/confirm.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package confirm

import (
"fmt"
"github.com/algorandfoundation/hack-tui/api"
"github.com/algorandfoundation/hack-tui/internal"
"github.com/algorandfoundation/hack-tui/ui/app"
Expand Down Expand Up @@ -68,13 +67,11 @@ func (m ViewModel) View() string {
}

func renderDeleteConfirmationModal(partKey *api.ParticipationKey) string {
modalStyle := lipgloss.NewStyle().
Width(60).
Height(7).
Align(lipgloss.Center).
Padding(1, 2)

modalContent := fmt.Sprintf("Participation Key: %v\nAccount Address: %v", partKey.Id, partKey.Address)

return modalStyle.Render("Are you sure you want to delete this key from your node?\n" + modalContent)
return lipgloss.NewStyle().Padding(1).Render(lipgloss.JoinVertical(lipgloss.Center,
"Are you sure you want to delete this key from your node?\n",
style.Cyan.Render("Account Address:"),
partKey.Address+"\n",
style.Cyan.Render("Participation Key:"),
partKey.Id,
))
}

0 comments on commit e3f2e8f

Please sign in to comment.