This commit is contained in:
Michal Kunc 2021-11-18 23:32:01 +01:00
parent 41a32accfd
commit 9641173758
Signed by: michal
GPG Key ID: 4CA5FB6559E0BDF8

View File

@ -19,6 +19,7 @@ with open("./db_explorer/en.json") as f:
def filter_vtt(text):
compendium_re = re.compile(r"@Compendium\[([^\]]+)\]\{([^\}]+)\}")
def compendium_return(m):
# TODO: Actually add links
return f"<a>{m.group(2)}</a>"
macro_re = re.compile(r"\[\[\/\S?r\s(?:(?P<sdice>[^\{\] ]+)[^\{\]]*|(?:\{(?P<ldice>[^\}]+)\}\[[^\]]+\])?)\]\](?:\{(?P<alt>[^\}]+)\})?")
def macro_return(m):