mirror of
https://github.com/ankitects/anki.git
synced 2025-09-21 07:22:23 -04:00
use the first hint occurrence for any subsequent clozes
This commit is contained in:
parent
47a61abebb
commit
933bee43a0
1 changed files with 4 additions and 2 deletions
|
@ -199,8 +199,10 @@ class Template(object):
|
||||||
return ""
|
return ""
|
||||||
# replace chosen cloze with type
|
# replace chosen cloze with type
|
||||||
if type == "q":
|
if type == "q":
|
||||||
if m.group(2):
|
if m.group(3):
|
||||||
txt = re.sub(reg%ord, "<span class=cloze>[\\3...]</span>", txt)
|
txt = re.sub(
|
||||||
|
reg%ord, "<span class=cloze>[%s...]</span>" % m.group(3),
|
||||||
|
txt)
|
||||||
else:
|
else:
|
||||||
txt = re.sub(reg%ord, "<span class=cloze>[...]</span>", txt)
|
txt = re.sub(reg%ord, "<span class=cloze>[...]</span>", txt)
|
||||||
elif type == "a":
|
elif type == "a":
|
||||||
|
|
Loading…
Reference in a new issue