Minor bug: `[...]` and `[...]+` buttons break HTML formatting

It’s a minor thing, but a little frustrating. For instance, a piece of code like this:

<span><span>some content</span></span>

Selecting this text and hitting one of the cloze deletion buttons places the {{c1::cloze tag}} outside the parent <span>. This means it breaks formatting for CSS.

You can see a video of the problem here. I understand if it’s not something fixable, but thought I’d point it out.

Typing out the cloze deletion tag manually seems to cure the problem.

I’ve logged this on Manipulate the DOM when creating cloze deletions? · Issue #2991 · ankitects/anki · GitHub

Great. So it’s a known issue. I’m sure there are a good number of issues to look at so appreciate it.

It’s strange that typing in the cloze deletion manually (a least so far in my tests) doesn’t do that. I’d love to be able to just add it to a fenced code block like this:

{{c1::(functionCall number string)::what is this function called?}}

And compile it with Pandoc. It compiles, but Anki complains that there’s no cloze deletion been added.

I’m guessing text manipulation is a hard problem to solve.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.