@@ -210,10 +210,11 @@ require('render-markdown').setup({
210
210
end ,
211
211
-- Additional events that will trigger this plugin's render loop.
212
212
change_events = {},
213
- -- Out of the box language injections for known filetypes that allow markdown to be interpreted
214
- -- in specified locations, see :h treesitter-language-injections.
215
- -- Set enabled to false in order to disable.
216
213
injections = {
214
+ -- Out of the box language injections for known filetypes that allow markdown to be interpreted
215
+ -- in specified locations, see :h treesitter-language-injections.
216
+ -- Set enabled to false in order to disable.
217
+
217
218
gitcommit = {
218
219
enabled = true ,
219
220
query = [[
@@ -224,8 +225,9 @@ require('render-markdown').setup({
224
225
]] ,
225
226
},
226
227
},
227
- -- Highlight patterns to disable for filetypes, i.e. lines concealed around code blocks
228
228
patterns = {
229
+ -- Highlight patterns to disable for filetypes, i.e. lines concealed around code blocks
230
+
229
231
markdown = {
230
232
disable = true ,
231
233
directives = {
@@ -301,10 +303,11 @@ require('render-markdown').setup({
301
303
end ,
302
304
},
303
305
},
304
- -- Useful context to have when evaluating values.
305
- -- | level | the number of '#' in the heading marker |
306
- -- | sections | for each level how deeply nested the heading is |
307
306
heading = {
307
+ -- Useful context to have when evaluating values.
308
+ -- | level | the number of '#' in the heading marker |
309
+ -- | sections | for each level how deeply nested the heading is |
310
+
308
311
-- Turn on / off heading icon & background rendering.
309
312
enabled = true ,
310
313
-- Additional modes to render headings.
@@ -387,9 +390,10 @@ require('render-markdown').setup({
387
390
-- | foreground | optional override for the foreground |
388
391
custom = {},
389
392
},
390
- -- Useful context to have when evaluating values.
391
- -- | text | text value of the node |
392
393
paragraph = {
394
+ -- Useful context to have when evaluating values.
395
+ -- | text | text value of the node |
396
+
393
397
-- Turn on / off paragraph rendering.
394
398
enabled = true ,
395
399
-- Additional modes to render paragraphs.
@@ -508,11 +512,12 @@ require('render-markdown').setup({
508
512
line_patterns = {},
509
513
},
510
514
},
511
- -- Useful context to have when evaluating values.
512
- -- | level | how deeply nested the list is, 1-indexed |
513
- -- | index | how far down the item is at that level, 1-indexed |
514
- -- | value | text value of the marker node |
515
515
bullet = {
516
+ -- Useful context to have when evaluating values.
517
+ -- | level | how deeply nested the list is, 1-indexed |
518
+ -- | index | how far down the item is at that level, 1-indexed |
519
+ -- | value | text value of the marker node |
520
+
516
521
-- Turn on / off list bullet rendering
517
522
enabled = true ,
518
523
-- Additional modes to render list bullets
@@ -547,9 +552,10 @@ require('render-markdown').setup({
547
552
-- Output is evaluated using the same logic as 'icons'.
548
553
scope_highlight = {},
549
554
},
550
- -- Checkboxes are a special instance of a 'list_item' that start with a 'shortcut_link'.
551
- -- There are two special states for unchecked & checked defined in the markdown grammar.
552
555
checkbox = {
556
+ -- Checkboxes are a special instance of a 'list_item' that start with a 'shortcut_link'.
557
+ -- There are two special states for unchecked & checked defined in the markdown grammar.
558
+
553
559
-- Turn on / off checkbox state rendering.
554
560
enabled = true ,
555
561
-- Additional modes to render checkboxes.
@@ -655,15 +661,15 @@ require('render-markdown').setup({
655
661
-- Highlight for inline padding used to add back concealed space.
656
662
filler = ' RenderMarkdownTableFill' ,
657
663
},
658
- -- Callouts are a special instance of a 'block_quote' that start with a 'shortcut_link'.
659
- -- The key is for healthcheck and to allow users to change its values, value type below.
660
- -- | raw | matched against the raw text of a 'shortcut_link', case insensitive |
661
- -- | rendered | replaces the 'raw' value when rendering |
662
- -- | highlight | highlight for the 'rendered' text and quote markers |
663
- -- | quote_icon | optional override for quote.icon value for individual callout |
664
- -- | category | optional metadata useful for filtering |
665
- -- stylua: ignore
666
664
callout = {
665
+ -- Callouts are a special instance of a 'block_quote' that start with a 'shortcut_link'.
666
+ -- The key is for healthcheck and to allow users to change its values, value type below.
667
+ -- | raw | matched against the raw text of a 'shortcut_link', case insensitive |
668
+ -- | rendered | replaces the 'raw' value when rendering |
669
+ -- | highlight | highlight for the 'rendered' text and quote markers |
670
+ -- | quote_icon | optional override for quote.icon value for individual callout |
671
+ -- | category | optional metadata useful for filtering |
672
+
667
673
note = { raw = ' [!NOTE]' , rendered = ' Note' , highlight = ' RenderMarkdownInfo' , category = ' github' },
668
674
tip = { raw = ' [!TIP]' , rendered = ' Tip' , highlight = ' RenderMarkdownSuccess' , category = ' github' },
669
675
important = { raw = ' [!IMPORTANT]' , rendered = ' Important' , highlight = ' RenderMarkdownHint' , category = ' github' },
@@ -755,19 +761,21 @@ require('render-markdown').setup({
755
761
-- Applies to background of sign text.
756
762
highlight = ' RenderMarkdownSign' ,
757
763
},
758
- -- Mimics Obsidian inline highlights when content is surrounded by double equals.
759
- -- The equals on both ends are concealed and the inner content is highlighted.
760
764
inline_highlight = {
765
+ -- Mimics Obsidian inline highlights when content is surrounded by double equals.
766
+ -- The equals on both ends are concealed and the inner content is highlighted.
767
+
761
768
-- Turn on / off inline highlight rendering.
762
769
enabled = true ,
763
770
-- Additional modes to render inline highlights.
764
771
render_modes = false ,
765
772
-- Applies to background of surrounded text.
766
773
highlight = ' RenderMarkdownInlineHighlight' ,
767
774
},
768
- -- Mimic org-indent-mode behavior by indenting everything under a heading based on the level of
769
- -- the heading. Indenting starts from level 2 headings onward by default.
770
775
indent = {
776
+ -- Mimic org-indent-mode behavior by indenting everything under a heading based on the
777
+ -- level of the heading. Indenting starts from level 2 headings onward by default.
778
+
771
779
-- Turn on / off org-indent-mode.
772
780
enabled = false ,
773
781
-- Additional modes to render indents.
@@ -803,8 +811,9 @@ require('render-markdown').setup({
803
811
-- | highlight | highlight for the icon |
804
812
tag = {},
805
813
},
806
- -- Window options to use that change between rendered and raw view.
807
814
win_options = {
815
+ -- Window options to use that change between rendered and raw view.
816
+
808
817
-- @see :h 'conceallevel'
809
818
conceallevel = {
810
819
-- Used when not being rendered, get user setting.
@@ -820,13 +829,14 @@ require('render-markdown').setup({
820
829
rendered = ' ' ,
821
830
},
822
831
},
823
- -- More granular configuration mechanism, allows different aspects of buffers to have their own
824
- -- behavior. Values default to the top level configuration if no override is provided. Supports
825
- -- the following fields:
826
- -- enabled, max_file_size, debounce, render_modes, anti_conceal, padding, heading, paragraph,
827
- -- code, dash, bullet, checkbox, quote, pipe_table, callout, link, sign, indent, latex, html,
828
- -- win_options
829
832
overrides = {
833
+ -- More granular configuration mechanism, allows different aspects of buffers to have their own
834
+ -- behavior. Values default to the top level configuration if no override is provided. Supports
835
+ -- the following fields:
836
+ -- enabled, max_file_size, debounce, render_modes, anti_conceal, padding, heading, paragraph,
837
+ -- code, dash, bullet, checkbox, quote, pipe_table, callout, link, sign, indent, latex, html,
838
+ -- win_options
839
+
830
840
-- Override for different buflisted values, @see :h 'buflisted'.
831
841
buflisted = {},
832
842
-- Override for different buftype values, @see :h 'buftype'.
@@ -865,10 +875,11 @@ We use the following definitions when discussing indexing into lists:
865
875
866
876
``` lua
867
877
require (' render-markdown' ).setup ({
868
- -- Useful context to have when evaluating values.
869
- -- | level | the number of '#' in the heading marker |
870
- -- | sections | for each level how deeply nested the heading is |
871
878
heading = {
879
+ -- Useful context to have when evaluating values.
880
+ -- | level | the number of '#' in the heading marker |
881
+ -- | sections | for each level how deeply nested the heading is |
882
+
872
883
-- Turn on / off heading icon & background rendering.
873
884
enabled = true ,
874
885
-- Additional modes to render headings.
@@ -966,9 +977,10 @@ require('render-markdown').setup({
966
977
967
978
``` lua
968
979
require (' render-markdown' ).setup ({
969
- -- Useful context to have when evaluating values.
970
- -- | text | text value of the node |
971
980
paragraph = {
981
+ -- Useful context to have when evaluating values.
982
+ -- | text | text value of the node |
983
+
972
984
-- Turn on / off paragraph rendering.
973
985
enabled = true ,
974
986
-- Additional modes to render paragraphs.
@@ -1118,11 +1130,12 @@ require('render-markdown').setup({
1118
1130
1119
1131
``` lua
1120
1132
require (' render-markdown' ).setup ({
1121
- -- Useful context to have when evaluating values.
1122
- -- | level | how deeply nested the list is, 1-indexed |
1123
- -- | index | how far down the item is at that level, 1-indexed |
1124
- -- | value | text value of the marker node |
1125
1133
bullet = {
1134
+ -- Useful context to have when evaluating values.
1135
+ -- | level | how deeply nested the list is, 1-indexed |
1136
+ -- | index | how far down the item is at that level, 1-indexed |
1137
+ -- | value | text value of the marker node |
1138
+
1126
1139
-- Turn on / off list bullet rendering
1127
1140
enabled = true ,
1128
1141
-- Additional modes to render list bullets
@@ -1172,9 +1185,10 @@ require('render-markdown').setup({
1172
1185
1173
1186
``` lua
1174
1187
require (' render-markdown' ).setup ({
1175
- -- Checkboxes are a special instance of a 'list_item' that start with a 'shortcut_link'.
1176
- -- There are two special states for unchecked & checked defined in the markdown grammar.
1177
1188
checkbox = {
1189
+ -- Checkboxes are a special instance of a 'list_item' that start with a 'shortcut_link'.
1190
+ -- There are two special states for unchecked & checked defined in the markdown grammar.
1191
+
1178
1192
-- Turn on / off checkbox state rendering.
1179
1193
enabled = true ,
1180
1194
-- Additional modes to render checkboxes.
@@ -1325,15 +1339,15 @@ require('render-markdown').setup({
1325
1339
1326
1340
``` lua
1327
1341
require (' render-markdown' ).setup ({
1328
- -- Callouts are a special instance of a 'block_quote' that start with a 'shortcut_link'.
1329
- -- The key is for healthcheck and to allow users to change its values, value type below.
1330
- -- | raw | matched against the raw text of a 'shortcut_link', case insensitive |
1331
- -- | rendered | replaces the 'raw' value when rendering |
1332
- -- | highlight | highlight for the 'rendered' text and quote markers |
1333
- -- | quote_icon | optional override for quote.icon value for individual callout |
1334
- -- | category | optional metadata useful for filtering |
1335
- -- stylua: ignore
1336
1342
callout = {
1343
+ -- Callouts are a special instance of a 'block_quote' that start with a 'shortcut_link'.
1344
+ -- The key is for healthcheck and to allow users to change its values, value type below.
1345
+ -- | raw | matched against the raw text of a 'shortcut_link', case insensitive |
1346
+ -- | rendered | replaces the 'raw' value when rendering |
1347
+ -- | highlight | highlight for the 'rendered' text and quote markers |
1348
+ -- | quote_icon | optional override for quote.icon value for individual callout |
1349
+ -- | category | optional metadata useful for filtering |
1350
+
1337
1351
note = { raw = ' [!NOTE]' , rendered = ' Note' , highlight = ' RenderMarkdownInfo' , category = ' github' },
1338
1352
tip = { raw = ' [!TIP]' , rendered = ' Tip' , highlight = ' RenderMarkdownSuccess' , category = ' github' },
1339
1353
important = { raw = ' [!IMPORTANT]' , rendered = ' Important' , highlight = ' RenderMarkdownHint' , category = ' github' },
@@ -1470,9 +1484,10 @@ require('render-markdown').setup({
1470
1484
1471
1485
``` lua
1472
1486
require (' render-markdown' ).setup ({
1473
- -- Mimic org-indent-mode behavior by indenting everything under a heading based on the level of
1474
- -- the heading. Indenting starts from level 2 headings onward by default.
1475
1487
indent = {
1488
+ -- Mimic org-indent-mode behavior by indenting everything under a heading based on the
1489
+ -- level of the heading. Indenting starts from level 2 headings onward by default.
1490
+
1476
1491
-- Turn on / off org-indent-mode.
1477
1492
enabled = false ,
1478
1493
-- Additional modes to render indents.
0 commit comments