diff options
author | Frederic Hemberger <mail@frederic-hemberger.de> | 2011-09-18 21:27:42 +0200 |
---|---|---|
committer | Frederic Hemberger <mail@frederic-hemberger.de> | 2011-09-18 21:27:42 +0200 |
commit | 44e4a991cf7cab619edecc23bed667e4a3233560 (patch) | |
tree | b05a2c803896ee86ddf73aa3ac045bb03bc14bed | |
parent | 31adeee1dfda4907cadebceda5d59ac0845624a1 (diff) | |
download | my_new_personal_website-44e4a991cf7cab619edecc23bed667e4a3233560.tar.xz my_new_personal_website-44e4a991cf7cab619edecc23bed667e4a3233560.zip |
Fixes styling of <figure> code header
Diffstat (limited to '')
-rw-r--r-- | plugins/code_block.rb | 6 | ||||
-rw-r--r-- | plugins/include_code.rb | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/plugins/code_block.rb b/plugins/code_block.rb index 00b0b438..bf89feab 100644 --- a/plugins/code_block.rb +++ b/plugins/code_block.rb @@ -24,7 +24,7 @@ # # Output: # -# <figure role=code> +# <figure class='code'> # <figcaption><span>Got pain? painrelief.sh</span> <a href="http://site.com/painrelief.sh">Download it!</a> # <div class="highlight"><pre><code class="sh"> # -- nicely escaped highlighted code -- @@ -37,7 +37,7 @@ # <sarcasm>Ooooh, sarcasm... How original!</sarcasm> # {% endcodeblock %} # -# <figure role=code> +# <figure class='code'> # <pre><code><sarcasm> Ooooh, sarcasm... How original!</sarcasm></code></pre> # </figure> # @@ -80,7 +80,7 @@ module Jekyll def render(context) output = super code = super.join - source = "<figure role=code>" + source = "<figure class='code'>" source += @caption if @caption if @filetype source += " #{highlight(code, @filetype)}</figure>" diff --git a/plugins/include_code.rb b/plugins/include_code.rb index 80951cb5..fc6daa36 100644 --- a/plugins/include_code.rb +++ b/plugins/include_code.rb @@ -61,7 +61,7 @@ module Jekyll @filetype = file.extname.sub('.','') if @filetype.nil? title = @title ? "#{@title} (#{file.basename})" : file.basename url = "/#{code_dir}/#{@file}" - source = "<figure role=code><figcaption><span>#{title}</span> <a href='#{url}'>download</a></figcaption>\n" + source = "<figure class='code'><figcaption><span>#{title}</span> <a href='#{url}'>download</a></figcaption>\n" source += " #{highlight(code, @filetype)}</figure>" safe_wrap(source) end |