From f2de95e30aac507bf7fa785e13a8edcbdc604605 Mon Sep 17 00:00:00 2001 From: Riley Bruins Date: Sat, 18 Nov 2023 17:20:51 -0800 Subject: feat(markdown): conceals for bullets, block quotes * feat(markdown): conceals for bullets, block quotes * fix: remove conceals for block quotes, change list minus to em dash * fix(markdown): allow empty bullets to be concealed --- queries/markdown/highlights.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'queries') diff --git a/queries/markdown/highlights.scm b/queries/markdown/highlights.scm index 23f1fb60f..085a1d827 100644 --- a/queries/markdown/highlights.scm +++ b/queries/markdown/highlights.scm @@ -34,6 +34,24 @@ (info_string (language) @conceal (#set! conceal ""))) +;; Conceal bullet points +([(list_marker_plus) (list_marker_star)] + @punctuation.special + (#offset! @punctuation.special 0 0 0 -1) + (#set! conceal "•")) +([(list_marker_plus) (list_marker_star)] + @punctuation.special + (#any-of? @punctuation.special "+" "*") + (#set! conceal "•")) +((list_marker_minus) + @punctuation.special + (#offset! @punctuation.special 0 0 0 -1) + (#set! conceal "—")) +((list_marker_minus) + @punctuation.special + (#eq? @punctuation.special "-") + (#set! conceal "—")) + (code_fence_content) @none [ -- cgit v1.2.3-70-g09d2