Skip to content

Commit

Permalink
fix: add support for snacks.nvim (#148)
Browse files Browse the repository at this point in the history
  • Loading branch information
kawre committed Dec 2, 2024
1 parent 9197cf8 commit ab0dd6e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lua/leetcode/logger/spinner/init.lua
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
local config = require("leetcode.config")
local t = require("leetcode.translator")
local log = require("leetcode.logger")

---@class lc.Spinner
---@field spinner lc.spinner | nil
Expand Down Expand Up @@ -73,11 +74,14 @@ function spinner:set(msg, lvl, opts)
end
lvl = lvl or vim.log.levels.INFO

local id = self.noti and (self.noti.id or self.noti)

opts = vim.tbl_deep_extend("force", {
hide_from_history = true,
title = config.name,
timeout = false,
replace = self.noti,
replace = id,
id = id,
}, opts or {})

self.noti = vim.notify(self.msg, lvl, opts)
Expand Down

0 comments on commit ab0dd6e

Please # to comment.