From f3eac9f1c353f6131733c5b6036e071a7d8eb450 Mon Sep 17 00:00:00 2001 From: sammyette Date: Sun, 17 Dec 2023 22:21:25 -0400 Subject: [PATCH] fix(nature/greenhouse): fix style override on bottom titles --- nature/greenhouse/init.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/nature/greenhouse/init.lua b/nature/greenhouse/init.lua index d5877e8..e3cac13 100644 --- a/nature/greenhouse/init.lua +++ b/nature/greenhouse/init.lua @@ -82,14 +82,15 @@ function Greenhouse:draw() self.sink:write(ansikit.getCSI(self.start .. ';1', 'H')) self.sink:write(ansikit.getCSI(2, 'J')) + local writer = self.sink.writeln for i = offset, offset + self.region.height - 1 do if i > #lines then break end - local writer = self.sink.writeln if i == offset + self.region.height - 1 then writer = self.sink.write end writer(self.sink, sub(lines[i]:gsub('\t', ' '), self.region.width)) end + writer(self.sink, '\27[0m') self:render() end