local function no_dir_attribute (elem) elem.attributes.dir = nil elem.attributes['custom-style'] = nil if 'Div' == elem.t or 'Span' == elem.t then if "" == elem.identifier then if 0 == #elem.classes then if 0 == #elem.attributes then return elem.content end end end end return elem end return { { CodeBlock = no_dir_attribute, Div = no_dir_attribute, Header = no_dir_attribute, Code = no_dir_attribute, Image = no_dir_attribute, Link = no_dir_attribute, Span = no_dir_attribute, } }