diff --git a/textarea/textarea.go b/textarea/textarea.go index 991c803..1d3aa97 100644 --- a/textarea/textarea.go +++ b/textarea/textarea.go @@ -1138,10 +1138,7 @@ func (m Model) View() string { s.WriteString(prompt) displayLine++ - if m.ShowLineNumbers { - lineNumber := m.style.EndOfBuffer.Render(string(m.EndOfBufferCharacter)) - s.WriteString(lineNumber) - } + s.WriteString(m.style.EndOfBuffer.Render(string(m.EndOfBufferCharacter))) s.WriteRune('\n') } diff --git a/textarea/textarea_test.go b/textarea/textarea_test.go index d9776e6..d37a74d 100644 --- a/textarea/textarea_test.go +++ b/textarea/textarea_test.go @@ -478,11 +478,11 @@ func TestView(t *testing.T) { }, expected: heredoc.Doc(` > the first line - > - > - > - > - > + > ~ + > ~ + > ~ + > ~ + > ~ `), }, { @@ -497,9 +497,9 @@ func TestView(t *testing.T) { > the first line > the second line > the third line - > - > - > + > ~ + > ~ + > ~ `), }, { @@ -547,11 +547,11 @@ func TestView(t *testing.T) { }, expected: heredoc.Doc(` > the first line - > - > - > - > - > + > * + > * + > * + > * + > * `), }, { @@ -567,9 +567,9 @@ func TestView(t *testing.T) { > the first line > the second line > the third line - > - > - > + > * + > * + > * `), }, {