From e349920524a2f2084f15d7d3f3e1b24f56ed6074 Mon Sep 17 00:00:00 2001 From: Austin Schey Date: Mon, 28 Feb 2022 18:58:14 -0600 Subject: [PATCH] Add Blink method to textinput to return blink state --- textinput/textinput.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/textinput/textinput.go b/textinput/textinput.go index 21f352b..09cd315 100644 --- a/textinput/textinput.go +++ b/textinput/textinput.go @@ -203,6 +203,11 @@ func (m Model) Cursor() int { return m.pos } +// Blink returns whether or not to draw the cursor. +func (m Model) Blink() bool { + return m.blink +} + // SetCursor moves the cursor to the given position. If the position is // out of bounds the cursor will be moved to the start or end accordingly. func (m *Model) SetCursor(pos int) {