File tree 4 files changed +25
-17
lines changed
4 files changed +25
-17
lines changed Original file line number Diff line number Diff line change 1
1
<div align =" center " >
2
2
3
- 🚨 ** leetcode.nvim is currently in the _ alpha stage_ of development** 🚨
4
-
5
- ---
6
-
7
3
# leetcode.nvim
8
4
9
5
🔥 Solve [ LeetCode] problems within [ Neovim] 🔥
14
10
15
11
https://github.com/kawre/leetcode.nvim/assets/69250723/aee6584c-e099-4409-b114-123cb32b7563
16
12
13
+ > [ !CAUTION]
14
+ > This plugin has been exclusively tested with ` Java ` .
15
+ > If you encounter any errors while using other languages,
16
+ > please open an issue to report them.
17
+
17
18
## ✨ Features
18
19
19
20
- 📌 an intuitive dashboard for effortless navigation within [ leetcode.nvim]
@@ -268,8 +269,9 @@ hooks = {
268
269
269
270
Whether to render question description images using [ image.nvim]
270
271
271
- Enabling this will disable question description wrap,
272
- because of https://github.com/3rd/image.nvim/issues/62#issuecomment-1778082534
272
+ > [ !WARNING]
273
+ > Enabling this will disable question description wrap,
274
+ > because of https://github.com/3rd/image.nvim/issues/62#issuecomment-1778082534
273
275
274
276
``` lua
275
277
--- @type boolean
@@ -365,8 +367,9 @@ https://github.com/kawre/leetcode.nvim/assets/69250723/b7be8b95-5e2c-4153-8845-4
365
367
366
368
### 💤 lazy loading with [ lazy.nvim]
367
369
368
- <small >🚨 _ ** opting for either option makes the alternative
369
- launch method unavailable due to lazy loading.** _ </small >
370
+ > [ !WARNING]
371
+ > opting for either option makes the alternative
372
+ > launch method unavailable due to lazy loading
370
373
371
374
- with [ ` arg ` ] ( #arg )
372
375
Original file line number Diff line number Diff line change 1
1
<div align =" center " >
2
2
3
- 🚨 ** leetcode.nvim 目前处于 _ alpha 阶段_ 开发中** 🚨
4
-
5
- ---
6
-
7
3
# leetcode.nvim
8
4
9
5
🔥 在 [ Neovim] 中解决 [ LeetCode] 问题 🔥
14
10
15
11
https://github.com/kawre/leetcode.nvim/assets/69250723/aee6584c-e099-4409-b114-123cb32b7563
16
12
13
+ > [ !CAUTION]
14
+ > 此插件仅与` Java ` 进行了专门测试。
15
+ > 如果您在使用其他语言时遇到任何错误,请打开一个问题报告它们。
16
+
17
17
## ✨ 特性
18
18
19
19
- 📌 直观的仪表板,轻松导航 [ leetcode.nvim] 内
@@ -271,8 +271,9 @@ hooks = {
271
271
272
272
是否使用 [ image.nvim] 渲染问题描述中的图片
273
273
274
- 启用此选项将禁用问题描述的换行,因为
275
- https://github.com/3rd/image.nvim/issues/62#issuecomment-1778082534
274
+ > [ !WARNING]
275
+ > 启用此选项将禁用问题描述的换行,因为
276
+ > https://github.com/3rd/image.nvim/issues/62#issuecomment-1778082534
276
277
277
278
``` lua
278
279
--- @type boolean
@@ -367,7 +368,8 @@ https://github.com/kawre/leetcode.nvim/assets/69250723/b7be8b95-5e2c-4153-8845-4
367
368
368
369
### 💤 使用 [ lazy.nvim] 进行延迟加载
369
370
370
- <small >🚨 _ ** 选择其中任一选项将由于延迟加载而使另一启动方法不可用。** _ </small >
371
+ > [ !WARNING]
372
+ > 选择其中任一选项将由于延迟加载而使另一启动方法不可用。
371
373
372
374
- 使用 [ ` arg ` ] ( #arg )
373
375
Original file line number Diff line number Diff line change @@ -52,6 +52,7 @@ function ResultPopup:init(parent)
52
52
win_options = {
53
53
winhighlight = " Normal:NormalSB,FloatBorder:FloatBorder" ,
54
54
wrap = true ,
55
+ linebreak = true ,
55
56
},
56
57
})
57
58
Original file line number Diff line number Diff line change @@ -73,9 +73,10 @@ function Testcase:draw_extmarks()
73
73
if not md .params then return end
74
74
75
75
local j = 1
76
+ local pad = (" " ):rep (2 )
76
77
local function get_param (idx )
77
78
return {
78
- { ( " " ): rep ( 2 ) },
79
+ { pad },
79
80
{ " " , " Operator" },
80
81
{ " " },
81
82
{ md .params [idx ].name , " Comment" },
@@ -94,7 +95,7 @@ function Testcase:draw_extmarks()
94
95
if line ~= " " then
95
96
local ok , text = pcall (get_param , j )
96
97
if not ok or invalid then
97
- text = { { ( " " ): rep ( 2 ) }, { (" %s" ):format (t (" invalid" )), " leetcode_error" } }
98
+ text = { { pad }, { (" %s" ):format (t (" invalid" )), " leetcode_error" } }
98
99
end
99
100
100
101
self :add_extmark (i - 1 , - 1 , { virt_text = text })
@@ -163,6 +164,7 @@ function Testcase:init(parent)
163
164
win_options = {
164
165
winhighlight = " Normal:NormalSB,FloatBorder:FloatBorder" ,
165
166
wrap = true ,
167
+ linebreak = true ,
166
168
},
167
169
})
168
170
You can’t perform that action at this time.
0 commit comments