Commit e8051316 authored by Alexandre Leray's avatar Alexandre Leray
Browse files

dc:title data is marked up with cite element

parent b046a888
......@@ -58,12 +58,27 @@ def aa_make_link(rel, target, label):
return a
def aa_make_elt (rel, target, label):
if rel == "dc:title":
elt = markdown.util.etree.Element('cite')
elt = markdown.util.etree.Element('span')
elt.set('content', target)
elt.text = label or target
if rel:
elt.set('property', rel)
return elt
def get_markdown(simple=False):
Returns a Markdown instance with the appropriate extensions for active
archives wiki.
extension_configs = {'semanticwikilinks': [('make_link', aa_make_link)]}
extension_configs = {
'semanticwikilinks': [('make_link', aa_make_link)],
'semanticdata': [('make_elt', aa_make_elt)],
extensions = ["attr_list", "cite", "def_list", "del_ins", "semanticdata",
"semanticwikilinks", mdx_timecodes.makeExtension()]
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment