Commit 237d9813 by rmrf

Add button for code

parent be36941f
Pipeline #31425 passed with stages
in 1 minute 16 seconds
......@@ -108,6 +108,13 @@ module Jekyll
end
# Is there a link for code
if entry.field?(:code)
code_url = "<div class=\"pure-button csl-slides\"><a href=\"" + entry.code.to_s + "\">CODE</a></div>"
puts "Found code: " + entry.code.to_s
reference.insert(reference.rindex('</div>'), code_url.to_s )
end
content_tag config['bibliography_item_tag'], reference
content_tag "li class=\"" + render_ref_img(entry) + "\"", reference
}.join("\n")
......
......@@ -132,6 +132,14 @@ module Jekyll
end
end
# Is there a link for code
if entry.field?(:code)
code_url = "<div class=\"pure-button csl-slides\"><a href=\"" + entry.code.to_s + "\">CODE</a></div>"
puts "Found code: " + entry.code.to_s
reference.insert(reference.rindex('</div>'), code_url.to_s )
end
end
# Content tag is dependent on type of article.
......
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