d2 icon indicating copy to clipboard operation
d2 copied to clipboard

fix: add url escaping to markdown processing #1898

Open jeengland opened this issue 1 year ago • 4 comments

Fix for issue #1898

I saw in the issue thread it was suggested to create a goldmark extension, which I'm still open to doing but I wanted to suggest a simpler regex based solution in this PR. Works on the md from the issue as well as a few other test cases:

memo: |md
  <a href="https://www.google.com/search?q=d2&newwindow=1">d2</a>
|

jeengland avatar May 03 '24 18:05 jeengland

Reference

Looking at adding a test now, should I be adding a test within the TestCompile block? Also when I do do that, it prompts me to rerun the test with $TA=1 and it edits a bunch of files. Is that correct or am I doing something incorrectly?

jeengland avatar May 03 '24 21:05 jeengland

@jeengland Yeah that's right

TA=1 ./ci/test.sh ./d2compiler to rerun compiler tests and accept the results. You don't need to verify the AST for this test because you're just checking it compiles at all.

alixander avatar May 04 '24 12:05 alixander

Hi @jeengland are you still interested in pursuing this PR? If not I can push to this branch, it's just the test remaining

alixander avatar May 23 '24 18:05 alixander

Hi @alixander sorry about the delay, I had an uptick in obligations this last few weeks. I'll make this a priority to look at tomorrow!

jeengland avatar May 30 '24 18:05 jeengland