From 778bfc337a010a5276b4736174c7c544b70236b5 Mon Sep 17 00:00:00 2001 From: Jonathan Lopez Date: Thu, 9 Jun 2022 10:32:05 -0400 Subject: [PATCH] Conceal markdown links --- queries/markdown/highlights.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/queries/markdown/highlights.scm b/queries/markdown/highlights.scm index 977f0f28a..b7b75b350 100644 --- a/queries/markdown/highlights.scm +++ b/queries/markdown/highlights.scm @@ -88,3 +88,25 @@ (inline_link "[" @conceal (#set! conceal "")) + +;; Conceal @text.uri preceding '(' +([ + (link_label) + (link_text) + (image_description) +] ["("] @conceal +(#set! conceal "")) + +;; Conceal @text.uri text +([ + (link_destination) + (uri_autolink) +] @conceal +(#set! conceal "")) + +;; Conceal @text.uri proceding '(' +([ + (link_destination) + (uri_autolink) +] [")"] @conceal +(#set! conceal ""))