asciidoctor-html5s 0.1.0.beta.4 → 0.1.0.beta.5

Sign up to get free protection for your applications and to get access to all the features.
@@ -5,10 +5,8 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
5
5
 
6
6
  #------------------------------ Begin of Helpers ------------------------------#
7
7
 
8
- require 'asciidoctor'
9
8
  require 'asciidoctor/html5s'
10
- require 'date'
11
- require 'json'
9
+ require 'date' unless RUBY_PLATFORM == 'opal'
12
10
 
13
11
  # Add custom functions to this module that you want to use in your Slim
14
12
  # templates. Within the template you can invoke them as top-level functions
@@ -16,27 +14,31 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
16
14
  module Helpers
17
15
 
18
16
  # URIs of external assets.
19
- FONT_AWESOME_URI = '//cdnjs.cloudflare.com/ajax/libs/font-awesome/4.1.0/css/font-awesome.min.css'
20
- HIGHLIGHTJS_BASE_URI = '//cdnjs.cloudflare.com/ajax/libs/highlight.js/7.4'
21
- MATHJAX_JS_URI = '//cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-MML-AM_HTMLorMML'
17
+ FONT_AWESOME_URI = '//cdn.jsdelivr.net/npm/font-awesome@4.7.0/css/font-awesome.min.css'
18
+ HIGHLIGHTJS_BASE_URI = '//cdn.jsdelivr.net/gh/highlightjs/cdn-release@9.12.0/build/'
19
+ KATEX_CSS_URI = '//cdn.jsdelivr.net/npm/katex@0.8.3/dist/katex.min.css'
20
+ KATEX_JS_URI = '//cdn.jsdelivr.net/npm/katex@0.8.3/dist/katex.min.js'
22
21
 
23
22
  # Defaults
24
23
  DEFAULT_HIGHLIGHTJS_THEME = 'github'
25
24
  DEFAULT_SECTNUMLEVELS = 3
26
25
  DEFAULT_TOCLEVELS = 2
27
26
 
28
- # The MathJax configuration.
29
- MATHJAX_CONFIG = {
30
- tex2jax: {
31
- inlineMath: [::Asciidoctor::INLINE_MATH_DELIMITERS[:latexmath].inspect],
32
- displayMath: [::Asciidoctor::BLOCK_MATH_DELIMITERS[:latexmath].inspect],
33
- ignoreClass: 'nostem|nolatexmath',
34
- },
35
- asciimath2jax: {
36
- delimiters: [::Asciidoctor::BLOCK_MATH_DELIMITERS[:asciimath].inspect],
37
- ignoreClass: 'nostem|noasciimath',
38
- }
39
- }.to_json
27
+ KATEX_RENDER_CODE = <<-JS.gsub(/\s+/, ' ')
28
+ document.addEventListener("DOMContentLoaded", function() {
29
+ var elements = document.getElementsByClassName("math");
30
+ for (var i = 0; i < elements.length; i++) {
31
+ var el = elements[i];
32
+ if (el.getAttribute("data-lang") !== "tex") {
33
+ continue;
34
+ }
35
+ katex.render(el.textContent.slice(2, -2), el, {
36
+ "displayMode": el.nodeName.toUpperCase() !== "SPAN",
37
+ "throwOnError": false,
38
+ });
39
+ }
40
+ });
41
+ JS
40
42
 
41
43
  VOID_ELEMENTS = %w(area base br col command embed hr img input keygen link
42
44
  meta param source track wbr)
@@ -221,6 +223,9 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
221
223
  ##
222
224
  # Delimite the given equation as a STEM of the specified type.
223
225
  #
226
+ # Note: This is not needed nor used for KaTeX, but keep this for the case
227
+ # user wants to use a different method.
228
+ #
224
229
  # @param equation [String] the equation to delimite.
225
230
  # @param type [#to_sym] the type of the STEM renderer (latexmath, or asciimath).
226
231
  # @return [String] the delimited equation.
@@ -367,6 +372,13 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
367
372
  end
368
373
  end
369
374
 
375
+ ##
376
+ # @return [String] language of STEM block or inline node (tex or asciimath).
377
+ def stem_lang
378
+ value = (inline? ? type : style).to_s
379
+ value == 'latexmath' ? 'tex' : value
380
+ end
381
+
370
382
  def link_rel
371
383
  'noopener' if option?('noopener') || attr(:window) == '_blank'
372
384
  end
@@ -521,7 +533,7 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
521
533
  # @return [String, nil] the revision date in ISO 8601, or nil if not
522
534
  # available or in invalid format.
523
535
  def revdate_iso
524
- ::Date.parse(revdate).iso8601
536
+ ::Date.parse(revdate).iso8601 if defined? ::Date
525
537
  rescue ArgumentError
526
538
  nil
527
539
  end
@@ -567,8 +579,9 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
567
579
  end
568
580
 
569
581
  if attr? 'stem'
570
- scripts << { src: MATHJAX_JS_URI }
571
- scripts << { type: 'text/x-mathjax-config', text: "MathJax.Hub.Config(#{MATHJAX_CONFIG});" }
582
+ styles << { href: KATEX_CSS_URI }
583
+ scripts << { src: KATEX_JS_URI }
584
+ scripts << { text: KATEX_RENDER_CODE }
572
585
  end
573
586
 
574
587
  case attr 'source-highlighter'
@@ -586,7 +599,6 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
586
599
  hjs_theme = attr 'highlightjs-theme', DEFAULT_HIGHLIGHTJS_THEME
587
600
 
588
601
  scripts << { src: [hjs_base, 'highlight.min.js'] }
589
- scripts << { src: [hjs_base, 'lang/common.min.js'] }
590
602
  scripts << { text: 'hljs.initHighlightingOnLoad()' }
591
603
  styles << { href: [hjs_base, "styles/#{hjs_theme}.min.css"] }
592
604
  end
@@ -692,136 +704,19 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
692
704
  node.extend(Helpers)
693
705
  node.instance_eval do
694
706
  converter.set_local_variables(binding, opts) unless opts.empty?
695
- _buf = ''
696
- capture do
697
- _buf << ("<h6".freeze)
698
- _temple_html_attributeremover1 = ''
699
- _temple_html_attributemerger1 = []
700
- _temple_html_attributemerger1[0] = "block-title"
701
- _temple_html_attributemerger1[1] = ''
702
- _slim_codeattributes1 = ('label-only' unless title?)
703
- if Array === _slim_codeattributes1
704
- _slim_codeattributes1 = _slim_codeattributes1.flatten
705
- _slim_codeattributes1.map!(&:to_s)
706
- _slim_codeattributes1.reject!(&:empty?)
707
- _temple_html_attributemerger1[1] << ((_slim_codeattributes1.join(" ")).to_s)
708
- else
709
- _temple_html_attributemerger1[1] << ((_slim_codeattributes1).to_s)
710
- end
711
- _temple_html_attributemerger1[1]
712
- _temple_html_attributeremover1 << ((_temple_html_attributemerger1.reject(&:empty?).join(" ")).to_s)
713
- _temple_html_attributeremover1
714
- if !_temple_html_attributeremover1.empty?
715
- _buf << (" class=\"".freeze)
716
- _buf << ((_temple_html_attributeremover1).to_s)
717
- _buf << ("\"".freeze)
718
- end
719
- _buf << ("><span class=\"title-label\">".freeze)
720
- _buf << (("#{local_attr :textlabel}: ").to_s)
721
- _buf << ("</span>".freeze)
722
- _buf << ((title).to_s)
723
- _buf << ("</h6>".freeze)
724
- _slim_controls1 = html_tag_if !blocks?, :p do
725
- _slim_controls2 = ''
726
- _slim_controls2 << ((content).to_s)
727
- _slim_controls2
728
- end
729
- _buf << ((_slim_controls1).to_s)
730
- end
731
- if admonition_aside?
732
- _buf << ("<aside".freeze)
733
- _temple_html_attributeremover2 = ''
734
- _temple_html_attributemerger2 = []
735
- _temple_html_attributemerger2[0] = "admonition-block"
736
- _temple_html_attributemerger2[1] = ''
737
- _slim_codeattributes2 = [(attr :name), role]
738
- if Array === _slim_codeattributes2
739
- _slim_codeattributes2 = _slim_codeattributes2.flatten
740
- _slim_codeattributes2.map!(&:to_s)
741
- _slim_codeattributes2.reject!(&:empty?)
742
- _temple_html_attributemerger2[1] << ((_slim_codeattributes2.join(" ")).to_s)
743
- else
744
- _temple_html_attributemerger2[1] << ((_slim_codeattributes2).to_s)
745
- end
746
- _temple_html_attributemerger2[1]
747
- _temple_html_attributeremover2 << ((_temple_html_attributemerger2.reject(&:empty?).join(" ")).to_s)
748
- _temple_html_attributeremover2
749
- if !_temple_html_attributeremover2.empty?
750
- _buf << (" class=\"".freeze)
751
- _buf << ((_temple_html_attributeremover2).to_s)
752
- _buf << ("\"".freeze)
753
- end
754
- _slim_codeattributes3 = id
755
- if _slim_codeattributes3
756
- if _slim_codeattributes3 == true
757
- _buf << (" id".freeze)
758
- else
759
- _buf << (" id=\"".freeze)
760
- _buf << ((_slim_codeattributes3).to_s)
761
- _buf << ("\"".freeze)
762
- end
763
- end
764
- _slim_codeattributes4 = admonition_aria
765
- if _slim_codeattributes4
766
- if _slim_codeattributes4 == true
767
- _buf << (" role".freeze)
768
- else
769
- _buf << (" role=\"".freeze)
770
- _buf << ((_slim_codeattributes4).to_s)
771
- _buf << ("\"".freeze)
772
- end
773
- end
774
- _buf << (">".freeze)
775
- yield_capture
776
- _buf << ("</aside>".freeze)
777
- else
778
- _buf << ("<section".freeze)
779
- _temple_html_attributeremover3 = ''
780
- _temple_html_attributemerger3 = []
781
- _temple_html_attributemerger3[0] = "admonition-block"
782
- _temple_html_attributemerger3[1] = ''
783
- _slim_codeattributes5 = [(attr :name), role]
784
- if Array === _slim_codeattributes5
785
- _slim_codeattributes5 = _slim_codeattributes5.flatten
786
- _slim_codeattributes5.map!(&:to_s)
787
- _slim_codeattributes5.reject!(&:empty?)
788
- _temple_html_attributemerger3[1] << ((_slim_codeattributes5.join(" ")).to_s)
789
- else
790
- _temple_html_attributemerger3[1] << ((_slim_codeattributes5).to_s)
791
- end
792
- _temple_html_attributemerger3[1]
793
- _temple_html_attributeremover3 << ((_temple_html_attributemerger3.reject(&:empty?).join(" ")).to_s)
794
- _temple_html_attributeremover3
795
- if !_temple_html_attributeremover3.empty?
796
- _buf << (" class=\"".freeze)
797
- _buf << ((_temple_html_attributeremover3).to_s)
798
- _buf << ("\"".freeze)
799
- end
800
- _slim_codeattributes6 = id
801
- if _slim_codeattributes6
802
- if _slim_codeattributes6 == true
803
- _buf << (" id".freeze)
804
- else
805
- _buf << (" id=\"".freeze)
806
- _buf << ((_slim_codeattributes6).to_s)
807
- _buf << ("\"".freeze)
808
- end
809
- end
810
- _slim_codeattributes7 = admonition_aria
811
- if _slim_codeattributes7
812
- if _slim_codeattributes7 == true
813
- _buf << (" role".freeze)
814
- else
815
- _buf << (" role=\"".freeze)
816
- _buf << ((_slim_codeattributes7).to_s)
817
- _buf << ("\"".freeze)
818
- end
819
- end
820
- _buf << (">".freeze)
821
- yield_capture
822
- _buf << ("</section>".freeze)
823
- end
824
- _buf
707
+ _buf = []; capture do;
708
+ ; _buf << ("<h6"); _temple_html_attributeremover1 = []; _temple_html_attributemerger1 = []; _temple_html_attributemerger1[0] = "block-title"; _temple_html_attributemerger1[1] = []; _slim_codeattributes1 = ('label-only' unless title?); if Array === _slim_codeattributes1; _slim_codeattributes1 = _slim_codeattributes1.flatten; _slim_codeattributes1.map!(&:to_s); _slim_codeattributes1.reject!(&:empty?); _temple_html_attributemerger1[1] << (_slim_codeattributes1.join(" ")); else; _temple_html_attributemerger1[1] << (_slim_codeattributes1); end; _temple_html_attributemerger1[1] = _temple_html_attributemerger1[1].join(""); _temple_html_attributeremover1 << (_temple_html_attributemerger1.reject(&:empty?).join(" ")); _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover1); _buf << ("\""); end; _buf << ("><span class=\"title-label\">");
709
+ ; _buf << ("#{local_attr :textlabel}: ");
710
+ ; _buf << ("</span>"); _buf << (title);
711
+ ; _buf << ("</h6>"); _slim_controls1 = html_tag_if !blocks?, :p do; _slim_controls2 = [];
712
+ ; _slim_controls2 << (content);
713
+ ; _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); end; if admonition_aside?;
714
+ ; _buf << ("<aside"); _temple_html_attributeremover2 = []; _temple_html_attributemerger2 = []; _temple_html_attributemerger2[0] = "admonition-block"; _temple_html_attributemerger2[1] = []; _slim_codeattributes2 = [(attr :name), role]; if Array === _slim_codeattributes2; _slim_codeattributes2 = _slim_codeattributes2.flatten; _slim_codeattributes2.map!(&:to_s); _slim_codeattributes2.reject!(&:empty?); _temple_html_attributemerger2[1] << (_slim_codeattributes2.join(" ")); else; _temple_html_attributemerger2[1] << (_slim_codeattributes2); end; _temple_html_attributemerger2[1] = _temple_html_attributemerger2[1].join(""); _temple_html_attributeremover2 << (_temple_html_attributemerger2.reject(&:empty?).join(" ")); _temple_html_attributeremover2 = _temple_html_attributeremover2.join(""); if !_temple_html_attributeremover2.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover2); _buf << ("\""); end; _slim_codeattributes3 = id; if _slim_codeattributes3; if _slim_codeattributes3 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes3); _buf << ("\""); end; end; _slim_codeattributes4 = admonition_aria; if _slim_codeattributes4; if _slim_codeattributes4 == true; _buf << (" role"); else; _buf << (" role=\""); _buf << (_slim_codeattributes4); _buf << ("\""); end; end; _buf << (">");
715
+ ; yield_capture;
716
+ ; _buf << ("</aside>"); else;
717
+ ; _buf << ("<section"); _temple_html_attributeremover3 = []; _temple_html_attributemerger3 = []; _temple_html_attributemerger3[0] = "admonition-block"; _temple_html_attributemerger3[1] = []; _slim_codeattributes5 = [(attr :name), role]; if Array === _slim_codeattributes5; _slim_codeattributes5 = _slim_codeattributes5.flatten; _slim_codeattributes5.map!(&:to_s); _slim_codeattributes5.reject!(&:empty?); _temple_html_attributemerger3[1] << (_slim_codeattributes5.join(" ")); else; _temple_html_attributemerger3[1] << (_slim_codeattributes5); end; _temple_html_attributemerger3[1] = _temple_html_attributemerger3[1].join(""); _temple_html_attributeremover3 << (_temple_html_attributemerger3.reject(&:empty?).join(" ")); _temple_html_attributeremover3 = _temple_html_attributeremover3.join(""); if !_temple_html_attributeremover3.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover3); _buf << ("\""); end; _slim_codeattributes6 = id; if _slim_codeattributes6; if _slim_codeattributes6 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes6); _buf << ("\""); end; end; _slim_codeattributes7 = admonition_aria; if _slim_codeattributes7; if _slim_codeattributes7 == true; _buf << (" role"); else; _buf << (" role=\""); _buf << (_slim_codeattributes7); _buf << ("\""); end; end; _buf << (">");
718
+ ; yield_capture;
719
+ ; _buf << ("</section>"); end; _buf = _buf.join("")
825
720
  end
826
721
  end
827
722
 
@@ -829,55 +724,14 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
829
724
  node.extend(Helpers)
830
725
  node.instance_eval do
831
726
  converter.set_local_variables(binding, opts) unless opts.empty?
832
- _buf = ''
833
- _slim_controls1 = block_with_caption :bottom, :class=>'audio-block' do
834
- _slim_controls2 = ''
835
- _slim_controls2 << ("<audio".freeze)
836
- _slim_codeattributes1 = media_uri(attr :target)
837
- if _slim_codeattributes1
838
- if _slim_codeattributes1 == true
839
- _slim_controls2 << (" src".freeze)
840
- else
841
- _slim_controls2 << (" src=\"".freeze)
842
- _slim_controls2 << ((_slim_codeattributes1).to_s)
843
- _slim_controls2 << ("\"".freeze)
844
- end
845
- end
846
- _slim_codeattributes2 = (option? 'autoplay')
847
- if _slim_codeattributes2
848
- if _slim_codeattributes2 == true
849
- _slim_controls2 << (" autoplay".freeze)
850
- else
851
- _slim_controls2 << (" autoplay=\"".freeze)
852
- _slim_controls2 << ((_slim_codeattributes2).to_s)
853
- _slim_controls2 << ("\"".freeze)
854
- end
855
- end
856
- _slim_codeattributes3 = !(option? 'nocontrols')
857
- if _slim_codeattributes3
858
- if _slim_codeattributes3 == true
859
- _slim_controls2 << (" controls".freeze)
860
- else
861
- _slim_controls2 << (" controls=\"".freeze)
862
- _slim_controls2 << ((_slim_codeattributes3).to_s)
863
- _slim_controls2 << ("\"".freeze)
864
- end
865
- end
866
- _slim_codeattributes4 = (option? 'loop')
867
- if _slim_codeattributes4
868
- if _slim_codeattributes4 == true
869
- _slim_controls2 << (" loop".freeze)
870
- else
871
- _slim_controls2 << (" loop=\"".freeze)
872
- _slim_controls2 << ((_slim_codeattributes4).to_s)
873
- _slim_controls2 << ("\"".freeze)
874
- end
875
- end
876
- _slim_controls2 << (">Your browser does not support the audio tag.</audio>".freeze)
877
- _slim_controls2
878
- end
879
- _buf << ((_slim_controls1).to_s)
880
- _buf
727
+ _buf = []; _slim_controls1 = block_with_caption :bottom, :class=>'audio-block' do; _slim_controls2 = [];
728
+ ;
729
+ ;
730
+ ;
731
+ ;
732
+ ; _slim_controls2 << ("<audio"); _slim_codeattributes1 = media_uri(attr :target); if _slim_codeattributes1; if _slim_codeattributes1 == true; _slim_controls2 << (" src"); else; _slim_controls2 << (" src=\""); _slim_controls2 << (_slim_codeattributes1); _slim_controls2 << ("\""); end; end; _slim_codeattributes2 = (option? 'autoplay'); if _slim_codeattributes2; if _slim_codeattributes2 == true; _slim_controls2 << (" autoplay"); else; _slim_controls2 << (" autoplay=\""); _slim_controls2 << (_slim_codeattributes2); _slim_controls2 << ("\""); end; end; _slim_codeattributes3 = !(option? 'nocontrols'); if _slim_codeattributes3; if _slim_codeattributes3 == true; _slim_controls2 << (" controls"); else; _slim_controls2 << (" controls=\""); _slim_controls2 << (_slim_codeattributes3); _slim_controls2 << ("\""); end; end; _slim_codeattributes4 = (option? 'loop'); if _slim_codeattributes4; if _slim_codeattributes4 == true; _slim_controls2 << (" loop"); else; _slim_controls2 << (" loop=\""); _slim_controls2 << (_slim_codeattributes4); _slim_controls2 << ("\""); end; end; _slim_controls2 << (">Your browser does not support the audio tag.</audio>");
733
+ ;
734
+ ; _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
881
735
  end
882
736
  end
883
737
 
@@ -885,47 +739,11 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
885
739
  node.extend(Helpers)
886
740
  node.instance_eval do
887
741
  converter.set_local_variables(binding, opts) unless opts.empty?
888
- _buf = ''
889
- _buf << ("<ol".freeze)
890
- _temple_html_attributeremover1 = ''
891
- _temple_html_attributemerger1 = []
892
- _temple_html_attributemerger1[0] = "callout-list"
893
- _temple_html_attributemerger1[1] = ''
894
- _slim_codeattributes1 = [style, role]
895
- if Array === _slim_codeattributes1
896
- _slim_codeattributes1 = _slim_codeattributes1.flatten
897
- _slim_codeattributes1.map!(&:to_s)
898
- _slim_codeattributes1.reject!(&:empty?)
899
- _temple_html_attributemerger1[1] << ((_slim_codeattributes1.join(" ")).to_s)
900
- else
901
- _temple_html_attributemerger1[1] << ((_slim_codeattributes1).to_s)
902
- end
903
- _temple_html_attributemerger1[1]
904
- _temple_html_attributeremover1 << ((_temple_html_attributemerger1.reject(&:empty?).join(" ")).to_s)
905
- _temple_html_attributeremover1
906
- if !_temple_html_attributeremover1.empty?
907
- _buf << (" class=\"".freeze)
908
- _buf << ((_temple_html_attributeremover1).to_s)
909
- _buf << ("\"".freeze)
910
- end
911
- _slim_codeattributes2 = id
912
- if _slim_codeattributes2
913
- if _slim_codeattributes2 == true
914
- _buf << (" id".freeze)
915
- else
916
- _buf << (" id=\"".freeze)
917
- _buf << ((_slim_codeattributes2).to_s)
918
- _buf << ("\"".freeze)
919
- end
920
- end
921
- _buf << (">".freeze)
922
- items.each do |item|
923
- _buf << ("<li>".freeze)
924
- _buf << ((item.text).to_s)
925
- _buf << ("</li>".freeze)
926
- end
927
- _buf << ("</ol>".freeze)
928
- _buf
742
+ _buf = [];
743
+ ; _buf << ("<ol"); _temple_html_attributeremover1 = []; _temple_html_attributemerger1 = []; _temple_html_attributemerger1[0] = "callout-list"; _temple_html_attributemerger1[1] = []; _slim_codeattributes1 = [style, role]; if Array === _slim_codeattributes1; _slim_codeattributes1 = _slim_codeattributes1.flatten; _slim_codeattributes1.map!(&:to_s); _slim_codeattributes1.reject!(&:empty?); _temple_html_attributemerger1[1] << (_slim_codeattributes1.join(" ")); else; _temple_html_attributemerger1[1] << (_slim_codeattributes1); end; _temple_html_attributemerger1[1] = _temple_html_attributemerger1[1].join(""); _temple_html_attributeremover1 << (_temple_html_attributemerger1.reject(&:empty?).join(" ")); _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover1); _buf << ("\""); end; _slim_codeattributes2 = id; if _slim_codeattributes2; if _slim_codeattributes2 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes2); _buf << ("\""); end; end; _buf << (">");
744
+ ; items.each do |item|;
745
+ ; _buf << ("<li>"); _buf << (item.text);
746
+ ; _buf << ("</li>"); end; _buf << ("</ol>"); _buf = _buf.join("")
929
747
  end
930
748
  end
931
749
 
@@ -933,137 +751,52 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
933
751
  node.extend(Helpers)
934
752
  node.instance_eval do
935
753
  converter.set_local_variables(binding, opts) unless opts.empty?
936
- _buf = ''
937
- case style
938
- when 'qanda'
939
- _slim_controls1 = block_with_title :class=>'qlist qanda', :role=>'doc-qna' do
940
- _slim_controls2 = ''
941
- _slim_controls2 << ("<dl class=\"qanda\">".freeze)
942
- items.each do |questions, answer|
943
- [*questions].each do |question|
944
- _slim_controls2 << ("<dt class=\"qanda-question\">".freeze)
945
- _slim_controls2 << ((question.text).to_s)
946
- _slim_controls2 << ("</dt>".freeze)
947
- end
948
- unless answer.nil?
949
- _slim_controls2 << ("<dd class=\"qanda-answer\">".freeze)
950
- if answer.text?
951
- _slim_controls3 = html_tag_if answer.blocks?, :p do
952
- _slim_controls4 = ''
953
- _slim_controls4 << ((answer.text).to_s)
954
- _slim_controls4
955
- end
956
- _slim_controls2 << ((_slim_controls3).to_s)
957
- end
958
- if answer.blocks?
959
- _slim_controls2 << ((answer.content).to_s)
960
- end
961
- _slim_controls2 << ("</dd>".freeze)
962
- end
963
- end
964
- _slim_controls2 << ("</dl>".freeze)
965
- _slim_controls2
966
- end
967
- _buf << ((_slim_controls1).to_s)
968
- when 'horizontal'
969
- _slim_controls5 = block_with_title :class=>'hdlist' do
970
- _slim_controls6 = ''
971
- _slim_controls6 << ("<table>".freeze)
972
- if (attr? :labelwidth) || (attr? :itemwidth)
973
- _slim_controls6 << ("<colgroup><col".freeze)
974
- _slim_codeattributes1 = style_value(width: [(attr :labelwidth), '%'])
975
- if _slim_codeattributes1
976
- if _slim_codeattributes1 == true
977
- _slim_controls6 << (" style".freeze)
978
- else
979
- _slim_controls6 << (" style=\"".freeze)
980
- _slim_controls6 << ((_slim_codeattributes1).to_s)
981
- _slim_controls6 << ("\"".freeze)
982
- end
983
- end
984
- _slim_controls6 << ("><col".freeze)
985
- _slim_codeattributes2 = style_value(width: [(attr :itemwidth), '%'])
986
- if _slim_codeattributes2
987
- if _slim_codeattributes2 == true
988
- _slim_controls6 << (" style".freeze)
989
- else
990
- _slim_controls6 << (" style=\"".freeze)
991
- _slim_controls6 << ((_slim_codeattributes2).to_s)
992
- _slim_controls6 << ("\"".freeze)
993
- end
994
- end
995
- _slim_controls6 << ("></colgroup>".freeze)
996
- end
997
- items.each do |terms, dd|
998
- _slim_controls6 << ("<tr><th".freeze)
999
- _temple_html_attributeremover1 = ''
1000
- _temple_html_attributemerger1 = []
1001
- _temple_html_attributemerger1[0] = "hdlist1"
1002
- _temple_html_attributemerger1[1] = ''
1003
- _slim_codeattributes3 = ('strong' if option? 'strong')
1004
- if Array === _slim_codeattributes3
1005
- _slim_codeattributes3 = _slim_codeattributes3.flatten
1006
- _slim_codeattributes3.map!(&:to_s)
1007
- _slim_codeattributes3.reject!(&:empty?)
1008
- _temple_html_attributemerger1[1] << ((_slim_codeattributes3.join(" ")).to_s)
1009
- else
1010
- _temple_html_attributemerger1[1] << ((_slim_codeattributes3).to_s)
1011
- end
1012
- _temple_html_attributemerger1[1]
1013
- _temple_html_attributeremover1 << ((_temple_html_attributemerger1.reject(&:empty?).join(" ")).to_s)
1014
- _temple_html_attributeremover1
1015
- if !_temple_html_attributeremover1.empty?
1016
- _slim_controls6 << (" class=\"".freeze)
1017
- _slim_controls6 << ((_temple_html_attributeremover1).to_s)
1018
- _slim_controls6 << ("\"".freeze)
1019
- end
1020
- _slim_controls6 << (">".freeze)
1021
- terms = [*terms]
1022
- terms.each_with_index do |dt, idx|
1023
- _slim_controls6 << ((dt.text).to_s)
1024
- unless idx >= terms.count - 1
1025
- _slim_controls6 << ("<br>".freeze)
1026
- end
1027
- end
1028
- _slim_controls6 << ("</th><td class=\"hdlist2\">".freeze)
1029
- unless dd.nil?
1030
- if dd.text?
1031
- _slim_controls6 << ("<p>".freeze)
1032
- _slim_controls6 << ((dd.text).to_s)
1033
- _slim_controls6 << ("</p>".freeze)
1034
- end
1035
- if dd.blocks?
1036
- _slim_controls6 << ((dd.content).to_s)
1037
- end
1038
- end
1039
- _slim_controls6 << ("</td></tr>".freeze)
1040
- end
1041
- _slim_controls6 << ("</table>".freeze)
1042
- _slim_controls6
1043
- end
1044
- _buf << ((_slim_controls5).to_s)
1045
- else
1046
- _slim_controls7 = block_with_title :class=>['dlist', style] do
1047
- _slim_controls8 = ''
1048
- _slim_controls8 << ("<dl>".freeze)
1049
- items.each do |terms, dd|
1050
- [*terms].each do |dt|
1051
- _slim_controls8 << ("<dt>".freeze)
1052
- _slim_controls8 << ((dt.text).to_s)
1053
- _slim_controls8 << ("</dt>".freeze)
1054
- end
1055
- unless dd.nil?
1056
- _slim_controls8 << ("<dd>".freeze)
1057
- _slim_controls8 << (((print_item_content dd)).to_s)
1058
- _slim_controls8 << ("</dd>".freeze)
1059
- end
1060
- end
1061
- _slim_controls8 << ("</dl>".freeze)
1062
- _slim_controls8
1063
- end
1064
- _buf << ((_slim_controls7).to_s)
1065
- end
1066
- _buf
754
+ _buf = []; case style;
755
+ ; when 'qanda';
756
+ ; _slim_controls1 = block_with_title :class=>'qlist qanda', :role=>'doc-qna' do; _slim_controls2 = [];
757
+ ; _slim_controls2 << ("<dl class=\"qanda\">");
758
+ ; items.each do |questions, answer|;
759
+ ; [*questions].each do |question|;
760
+ ; _slim_controls2 << ("<dt class=\"qanda-question\">"); _slim_controls2 << (question.text);
761
+ ; _slim_controls2 << ("</dt>"); end; unless answer.nil?;
762
+ ; _slim_controls2 << ("<dd class=\"qanda-answer\">");
763
+ ; if answer.text?;
764
+ ; _slim_controls3 = html_tag_if answer.blocks?, :p do; _slim_controls4 = [];
765
+ ; _slim_controls4 << (answer.text);
766
+ ; _slim_controls4 = _slim_controls4.join(""); end; _slim_controls2 << (_slim_controls3); end; if answer.blocks?;
767
+ ; _slim_controls2 << (answer.content);
768
+ ; end; _slim_controls2 << ("</dd>"); end; end; _slim_controls2 << ("</dl>"); _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1);
769
+ ; when 'horizontal';
770
+ ; _slim_controls5 = block_with_title :class=>'hdlist' do; _slim_controls6 = [];
771
+ ; _slim_controls6 << ("<table>");
772
+ ; if (attr? :labelwidth) || (attr? :itemwidth);
773
+ ; _slim_controls6 << ("<colgroup><col");
774
+ ; _slim_codeattributes1 = style_value(width: [(attr :labelwidth), '%']); if _slim_codeattributes1; if _slim_codeattributes1 == true; _slim_controls6 << (" style"); else; _slim_controls6 << (" style=\""); _slim_controls6 << (_slim_codeattributes1); _slim_controls6 << ("\""); end; end; _slim_controls6 << ("><col");
775
+ ; _slim_codeattributes2 = style_value(width: [(attr :itemwidth), '%']); if _slim_codeattributes2; if _slim_codeattributes2 == true; _slim_controls6 << (" style"); else; _slim_controls6 << (" style=\""); _slim_controls6 << (_slim_codeattributes2); _slim_controls6 << ("\""); end; end; _slim_controls6 << ("></colgroup>");
776
+ ; end; items.each do |terms, dd|;
777
+ ; _slim_controls6 << ("<tr><th");
778
+ ; _temple_html_attributeremover1 = []; _temple_html_attributemerger1 = []; _temple_html_attributemerger1[0] = "hdlist1"; _temple_html_attributemerger1[1] = []; _slim_codeattributes3 = ('strong' if option? 'strong'); if Array === _slim_codeattributes3; _slim_codeattributes3 = _slim_codeattributes3.flatten; _slim_codeattributes3.map!(&:to_s); _slim_codeattributes3.reject!(&:empty?); _temple_html_attributemerger1[1] << (_slim_codeattributes3.join(" ")); else; _temple_html_attributemerger1[1] << (_slim_codeattributes3); end; _temple_html_attributemerger1[1] = _temple_html_attributemerger1[1].join(""); _temple_html_attributeremover1 << (_temple_html_attributemerger1.reject(&:empty?).join(" ")); _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _slim_controls6 << (" class=\""); _slim_controls6 << (_temple_html_attributeremover1); _slim_controls6 << ("\""); end; _slim_controls6 << (">");
779
+ ; terms = [*terms];
780
+ ; terms.each_with_index do |dt, idx|;
781
+ ; _slim_controls6 << (dt.text);
782
+ ; unless idx >= terms.count - 1;
783
+ ; _slim_controls6 << ("<br>");
784
+ ; end; end; _slim_controls6 << ("</th><td class=\"hdlist2\">");
785
+ ; unless dd.nil?;
786
+ ; if dd.text?;
787
+ ; _slim_controls6 << ("<p>"); _slim_controls6 << (dd.text);
788
+ ; _slim_controls6 << ("</p>"); end; if dd.blocks?;
789
+ ; _slim_controls6 << (dd.content);
790
+ ; end; end; _slim_controls6 << ("</td></tr>"); end; _slim_controls6 << ("</table>"); _slim_controls6 = _slim_controls6.join(""); end; _buf << (_slim_controls5);
791
+ ; else;
792
+ ; _slim_controls7 = block_with_title :class=>['dlist', style] do; _slim_controls8 = [];
793
+ ; _slim_controls8 << ("<dl>");
794
+ ; items.each do |terms, dd|;
795
+ ; [*terms].each do |dt|;
796
+ ; _slim_controls8 << ("<dt>"); _slim_controls8 << (dt.text);
797
+ ; _slim_controls8 << ("</dt>"); end; unless dd.nil?;
798
+ ; _slim_controls8 << ("<dd>"); _slim_controls8 << ((print_item_content dd));
799
+ ; _slim_controls8 << ("</dd>"); end; end; _slim_controls8 << ("</dl>"); _slim_controls8 = _slim_controls8.join(""); end; _buf << (_slim_controls7); end; _buf = _buf.join("")
1067
800
  end
1068
801
  end
1069
802
 
@@ -1071,222 +804,87 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1071
804
  node.extend(Helpers)
1072
805
  node.instance_eval do
1073
806
  converter.set_local_variables(binding, opts) unless opts.empty?
1074
- _buf = ''
1075
- _buf << ("<!DOCTYPE html><html".freeze)
1076
- _slim_codeattributes1 = (attr :lang, 'en' unless attr? :nolang)
1077
- if _slim_codeattributes1
1078
- if _slim_codeattributes1 == true
1079
- _buf << (" lang".freeze)
1080
- else
1081
- _buf << (" lang=\"".freeze)
1082
- _buf << ((_slim_codeattributes1).to_s)
1083
- _buf << ("\"".freeze)
1084
- end
1085
- end
1086
- _buf << ("><head><meta".freeze)
1087
- _slim_codeattributes2 = (attr :encoding, 'UTF-8')
1088
- if _slim_codeattributes2
1089
- if _slim_codeattributes2 == true
1090
- _buf << (" charset".freeze)
1091
- else
1092
- _buf << (" charset=\"".freeze)
1093
- _buf << ((_slim_codeattributes2).to_s)
1094
- _buf << ("\"".freeze)
1095
- end
1096
- end
1097
- _buf << ("><!--[if IE]><meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge\"><![endif]--><meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\"><meta name=\"generator\" content=\"Asciidoctor ".freeze)
1098
- _buf << ((attr 'asciidoctor-version').to_s)
1099
- _buf << ("\">".freeze)
1100
- _buf << ((html_meta_if 'application-name', (attr 'app-name')).to_s)
1101
- _buf << ((html_meta_if 'author', (attr :authors)).to_s)
1102
- _buf << ((html_meta_if 'copyright', (attr :copyright)).to_s)
1103
- _buf << ((html_meta_if 'description', (attr :description)).to_s)
1104
- _buf << ((html_meta_if 'keywords', (attr :keywords)).to_s)
1105
- _buf << ("<title>".freeze)
1106
- _buf << ((((doctitle sanitize: true) || (attr 'untitled-label'))).to_s)
1107
- _buf << ("</title>".freeze)
1108
- _buf << ((styles_and_scripts).to_s)
1109
- unless (docinfo_content = docinfo).empty?
1110
- _buf << ((docinfo_content).to_s)
1111
- end
1112
- _buf << ("</head><body".freeze)
1113
- _slim_codeattributes3 = id
1114
- if _slim_codeattributes3
1115
- if _slim_codeattributes3 == true
1116
- _buf << (" id".freeze)
1117
- else
1118
- _buf << (" id=\"".freeze)
1119
- _buf << ((_slim_codeattributes3).to_s)
1120
- _buf << ("\"".freeze)
1121
- end
1122
- end
1123
- _temple_html_attributeremover1 = ''
1124
- _slim_codeattributes4 = [(attr :doctype), ("#{attr 'toc-class'} toc-#{attr 'toc-position', 'left'}" if (attr? 'toc-class') && (attr? :toc) && (attr? 'toc-placement', 'auto'))]
1125
- if Array === _slim_codeattributes4
1126
- _slim_codeattributes4 = _slim_codeattributes4.flatten
1127
- _slim_codeattributes4.map!(&:to_s)
1128
- _slim_codeattributes4.reject!(&:empty?)
1129
- _temple_html_attributeremover1 << ((_slim_codeattributes4.join(" ")).to_s)
1130
- else
1131
- _temple_html_attributeremover1 << ((_slim_codeattributes4).to_s)
1132
- end
1133
- _temple_html_attributeremover1
1134
- if !_temple_html_attributeremover1.empty?
1135
- _buf << (" class=\"".freeze)
1136
- _buf << ((_temple_html_attributeremover1).to_s)
1137
- _buf << ("\"".freeze)
1138
- end
1139
- _slim_codeattributes5 = style_value(max_width: (attr 'max-width'))
1140
- if _slim_codeattributes5
1141
- if _slim_codeattributes5 == true
1142
- _buf << (" style".freeze)
1143
- else
1144
- _buf << (" style=\"".freeze)
1145
- _buf << ((_slim_codeattributes5).to_s)
1146
- _buf << ("\"".freeze)
1147
- end
1148
- end
1149
- _buf << (">".freeze)
1150
- unless noheader
1151
- _buf << ("<header>".freeze)
1152
- if has_header?
1153
- unless notitle
1154
- _buf << ("<h1>".freeze)
1155
- _buf << ((header.title).to_s)
1156
- _buf << ("</h1>".freeze)
1157
- end
1158
- if [:author, :revnumber, :revdate, :revremark].any? {|a| attr? a }
1159
- _buf << ("<div class=\"details\">".freeze)
1160
- if attr? :author
1161
- _buf << ("<span class=\"author\" id=\"author\">".freeze)
1162
- _buf << (((attr :author)).to_s)
1163
- _buf << ("</span><br>".freeze)
1164
- if attr? :email
1165
- _buf << ("<span class=\"email\" id=\"email\">".freeze)
1166
- _buf << ((sub_macros(attr :email)).to_s)
1167
- _buf << ("</span><br>".freeze)
1168
- end
1169
- if (authorcount = (attr :authorcount).to_i) > 1
1170
- (2..authorcount).each do |idx|
1171
- _buf << ("<span class=\"author\" id=\"author".freeze)
1172
- _buf << ((idx).to_s)
1173
- _buf << ("\">".freeze)
1174
- _buf << (((attr "author_#{idx}")).to_s)
1175
- _buf << ("</span><br>".freeze)
1176
- if attr? "email_#{idx}"
1177
- _buf << ("<span class=\"email\" id=\"email".freeze)
1178
- _buf << ((idx).to_s)
1179
- _buf << ("\">".freeze)
1180
- _buf << ((sub_macros(attr "email_#{idx}")).to_s)
1181
- _buf << ("</span>".freeze)
1182
- end
1183
- end
1184
- end
1185
- end
1186
- if attr? :revnumber
1187
- _buf << ("<span id=\"revnumber\">".freeze)
1188
- _buf << ((((attr 'version-label') || '').downcase).to_s)
1189
- _buf << (" ".freeze)
1190
- _buf << ((attr :revnumber).to_s)
1191
- _buf << ((',' if attr? :revdate).to_s)
1192
- _buf << ("</span> ".freeze)
1193
- end
1194
- if attr? :revdate
1195
- _buf << ("<time id=\"revdate\"".freeze)
1196
- _slim_codeattributes6 = revdate_iso
1197
- if _slim_codeattributes6
1198
- if _slim_codeattributes6 == true
1199
- _buf << (" datetime".freeze)
1200
- else
1201
- _buf << (" datetime=\"".freeze)
1202
- _buf << ((_slim_codeattributes6).to_s)
1203
- _buf << ("\"".freeze)
1204
- end
1205
- end
1206
- _buf << (">".freeze)
1207
- _buf << (((attr :revdate)).to_s)
1208
- _buf << ("</time>".freeze)
1209
- end
1210
- if attr? :revremark
1211
- _buf << ("<br><span id=\"revremark\">".freeze)
1212
- _buf << (((attr :revremark)).to_s)
1213
- _buf << ("</span>".freeze)
1214
- end
1215
- _buf << ("</div>".freeze)
1216
- end
1217
- end
1218
- if (attr? :toc) && (attr? 'toc-placement', 'auto')
1219
- _buf << ("<nav id=\"toc\"".freeze)
1220
- _temple_html_attributeremover2 = ''
1221
- _slim_codeattributes7 = (attr 'toc-class', 'toc')
1222
- if Array === _slim_codeattributes7
1223
- _slim_codeattributes7 = _slim_codeattributes7.flatten
1224
- _slim_codeattributes7.map!(&:to_s)
1225
- _slim_codeattributes7.reject!(&:empty?)
1226
- _temple_html_attributeremover2 << ((_slim_codeattributes7.join(" ")).to_s)
1227
- else
1228
- _temple_html_attributeremover2 << ((_slim_codeattributes7).to_s)
1229
- end
1230
- _temple_html_attributeremover2
1231
- if !_temple_html_attributeremover2.empty?
1232
- _buf << (" class=\"".freeze)
1233
- _buf << ((_temple_html_attributeremover2).to_s)
1234
- _buf << ("\"".freeze)
1235
- end
1236
- _buf << (" role=\"doc-toc\"><h2 id=\"toc-title\">".freeze)
1237
- _buf << (((attr 'toc-title')).to_s)
1238
- _buf << ("</h2>".freeze)
1239
- _buf << ((converter.convert document, 'outline').to_s)
1240
- _buf << ("</nav>".freeze)
1241
- end
1242
- _buf << ("</header>".freeze)
1243
- end
1244
- _buf << ("<div id=\"content\">".freeze)
1245
- _buf << ((content).to_s)
1246
- _buf << ("</div>".freeze)
1247
- unless !footnotes? || (attr? :nofootnotes)
1248
- _buf << ("<section class=\"footnotes\" aria-label=\"Footnotes\" role=\"doc-endnotes\"><hr><ol class=\"footnotes\">".freeze)
1249
- footnotes.each do |fn|
1250
- _buf << ("<li class=\"footnote\"".freeze)
1251
- _slim_codeattributes8 = (footnote_id fn.index)
1252
- if _slim_codeattributes8
1253
- if _slim_codeattributes8 == true
1254
- _buf << (" id".freeze)
1255
- else
1256
- _buf << (" id=\"".freeze)
1257
- _buf << ((_slim_codeattributes8).to_s)
1258
- _buf << ("\"".freeze)
1259
- end
1260
- end
1261
- _buf << (" role=\"doc-endnote\">".freeze)
1262
- _buf << (("#{fn.text} ").to_s)
1263
- _buf << ("<a class=\"footnote-backref\" href=\"#".freeze)
1264
- _buf << ((footnoteref_id fn.index).to_s)
1265
- _buf << ("\" role=\"doc-backlink\" title=\"Jump to the first occurrence in the text\">&#8617;</a></li>".freeze)
1266
- end
1267
- _buf << ("</ol></section>".freeze)
1268
- end
1269
- unless nofooter
1270
- _buf << ("<footer><div id=\"footer-text\">".freeze)
1271
- if attr? :revnumber
1272
- _buf << ((attr 'version-label').to_s)
1273
- _buf << (" ".freeze)
1274
- _buf << ((attr :revnumber).to_s)
1275
- end
1276
- if attr? 'last-update-label'
1277
- _buf << ("<br>".freeze)
1278
- _buf << ((attr 'last-update-label').to_s)
1279
- _buf << (" ".freeze)
1280
- _buf << ((attr :docdatetime).to_s)
1281
- end
1282
- _buf << ("</div>".freeze)
1283
- unless (docinfo_content = (docinfo :footer)).empty?
1284
- _buf << ((docinfo_content).to_s)
1285
- end
1286
- _buf << ("</footer>".freeze)
1287
- end
1288
- _buf << ("</body></html>".freeze)
1289
- _buf
807
+ _buf = []; _buf << ("<!DOCTYPE html><html");
808
+ ; _slim_codeattributes1 = (attr :lang, 'en' unless attr? :nolang); if _slim_codeattributes1; if _slim_codeattributes1 == true; _buf << (" lang"); else; _buf << (" lang=\""); _buf << (_slim_codeattributes1); _buf << ("\""); end; end; _buf << ("><head><meta");
809
+ ;
810
+ ; _slim_codeattributes2 = (attr :encoding, 'UTF-8'); if _slim_codeattributes2; if _slim_codeattributes2 == true; _buf << (" charset"); else; _buf << (" charset=\""); _buf << (_slim_codeattributes2); _buf << ("\""); end; end; _buf << ("><!--[if IE]><meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge\"><![endif]--><meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\"><meta name=\"generator\" content=\"Asciidoctor ");
811
+ ;
812
+ ;
813
+ ;
814
+ ; _buf << (attr 'asciidoctor-version'); _buf << ("\">");
815
+ ; _buf << (html_meta_if 'application-name', (attr 'app-name'));
816
+ ; _buf << (html_meta_if 'author', (attr :authors));
817
+ ; _buf << (html_meta_if 'copyright', (attr :copyright));
818
+ ; _buf << (html_meta_if 'description', (attr :description));
819
+ ; _buf << (html_meta_if 'keywords', (attr :keywords));
820
+ ; _buf << ("<title>"); _buf << (((doctitle sanitize: true) || (attr 'untitled-label')));
821
+ ; _buf << ("</title>"); _buf << (styles_and_scripts);
822
+ ; unless (docinfo_content = docinfo).empty?;
823
+ ; _buf << (docinfo_content);
824
+ ; end; _buf << ("</head><body");
825
+ ;
826
+ ;
827
+ ; _slim_codeattributes3 = id; if _slim_codeattributes3; if _slim_codeattributes3 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes3); _buf << ("\""); end; end; _temple_html_attributeremover1 = []; _slim_codeattributes4 = [(attr :doctype), ("#{attr 'toc-class'} toc-#{attr 'toc-position', 'left'}" if (attr? 'toc-class') && (attr? :toc) && (attr? 'toc-placement', 'auto'))]; if Array === _slim_codeattributes4; _slim_codeattributes4 = _slim_codeattributes4.flatten; _slim_codeattributes4.map!(&:to_s); _slim_codeattributes4.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes4.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes4); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover1); _buf << ("\""); end; _slim_codeattributes5 = style_value(max_width: (attr 'max-width')); if _slim_codeattributes5; if _slim_codeattributes5 == true; _buf << (" style"); else; _buf << (" style=\""); _buf << (_slim_codeattributes5); _buf << ("\""); end; end; _buf << (">");
828
+ ; unless noheader;
829
+ ; _buf << ("<header>");
830
+ ; if has_header?;
831
+ ; unless notitle;
832
+ ; _buf << ("<h1>"); _buf << (header.title);
833
+ ; _buf << ("</h1>"); end; if [:author, :revnumber, :revdate, :revremark].any? {|a| attr? a };
834
+ ; _buf << ("<div class=\"details\">");
835
+ ; if attr? :author;
836
+ ; _buf << ("<span class=\"author\" id=\"author\">"); _buf << ((attr :author));
837
+ ; _buf << ("</span><br>");
838
+ ; if attr? :email;
839
+ ; _buf << ("<span class=\"email\" id=\"email\">"); _buf << (sub_macros(attr :email));
840
+ ; _buf << ("</span><br>");
841
+ ; end; if (authorcount = (attr :authorcount).to_i) > 1;
842
+ ; (2..authorcount).each do |idx|;
843
+ ; _buf << ("<span class=\"author\" id=\"author"); _buf << (idx); _buf << ("\">"); _buf << ((attr "author_#{idx}"));
844
+ ; _buf << ("</span><br>");
845
+ ; if attr? "email_#{idx}";
846
+ ; _buf << ("<span class=\"email\" id=\"email"); _buf << (idx); _buf << ("\">"); _buf << (sub_macros(attr "email_#{idx}"));
847
+ ; _buf << ("</span>"); end; end; end; end; if attr? :revnumber;
848
+ ; _buf << ("<span id=\"revnumber\">"); _buf << (((attr 'version-label') || '').downcase); _buf << (" "); _buf << (attr :revnumber); _buf << (',' if attr? :revdate); _buf << ("</span> ");
849
+ ;
850
+ ; end; if attr? :revdate;
851
+ ; _buf << ("<time id=\"revdate\""); _slim_codeattributes6 = revdate_iso; if _slim_codeattributes6; if _slim_codeattributes6 == true; _buf << (" datetime"); else; _buf << (" datetime=\""); _buf << (_slim_codeattributes6); _buf << ("\""); end; end; _buf << (">"); _buf << ((attr :revdate));
852
+ ; _buf << ("</time>"); end; if attr? :revremark;
853
+ ; _buf << ("<br><span id=\"revremark\">");
854
+ ; _buf << ((attr :revremark));
855
+ ; _buf << ("</span>"); end; _buf << ("</div>"); end; end; if (attr? :toc) && (attr? 'toc-placement', 'auto');
856
+ ; _buf << ("<nav id=\"toc\""); _temple_html_attributeremover2 = []; _slim_codeattributes7 = (attr 'toc-class', 'toc'); if Array === _slim_codeattributes7; _slim_codeattributes7 = _slim_codeattributes7.flatten; _slim_codeattributes7.map!(&:to_s); _slim_codeattributes7.reject!(&:empty?); _temple_html_attributeremover2 << (_slim_codeattributes7.join(" ")); else; _temple_html_attributeremover2 << (_slim_codeattributes7); end; _temple_html_attributeremover2 = _temple_html_attributeremover2.join(""); if !_temple_html_attributeremover2.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover2); _buf << ("\""); end; _buf << (" role=\"doc-toc\"><h2 id=\"toc-title\">");
857
+ ; _buf << ((attr 'toc-title'));
858
+ ; _buf << ("</h2>");
859
+ ; _buf << (converter.convert document, 'outline');
860
+ ; _buf << ("</nav>");
861
+ ; end;
862
+ ; _buf << ("</header>"); end; _buf << ("<div id=\"content\">"); _buf << (content);
863
+ ; _buf << ("</div>"); unless !footnotes? || (attr? :nofootnotes);
864
+ ; _buf << ("<section class=\"footnotes\" aria-label=\"Footnotes\" role=\"doc-endnotes\"><hr><ol class=\"footnotes\">");
865
+ ;
866
+ ;
867
+ ; footnotes.each do |fn|;
868
+ ; _buf << ("<li class=\"footnote\""); _slim_codeattributes8 = (footnote_id fn.index); if _slim_codeattributes8; if _slim_codeattributes8 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes8); _buf << ("\""); end; end; _buf << (" role=\"doc-endnote\">");
869
+ ; _buf << ("#{fn.text} ");
870
+ ;
871
+ ;
872
+ ;
873
+ ; _buf << ("<a class=\"footnote-backref\" href=\"#"); _buf << (footnoteref_id fn.index); _buf << ("\" role=\"doc-backlink\" title=\"Jump to the first occurrence in the text\">&#8617;</a></li>");
874
+ ;
875
+ ; end; _buf << ("</ol></section>");
876
+ ; end; unless nofooter;
877
+ ; _buf << ("<footer><div id=\"footer-text\">");
878
+ ;
879
+ ; if attr? :revnumber;
880
+ ; _buf << (attr 'version-label'); _buf << (" "); _buf << (attr :revnumber);
881
+ ; end; if attr? 'last-update-label';
882
+ ; _buf << ("<br>");
883
+ ; _buf << (attr 'last-update-label'); _buf << (" "); _buf << (attr :docdatetime);
884
+ ; end; _buf << ("</div>"); unless (docinfo_content = (docinfo :footer)).empty?;
885
+ ; _buf << (docinfo_content);
886
+ ; end;
887
+ ; _buf << ("</footer>"); end; _buf << ("</body></html>"); _buf = _buf.join("")
1290
888
  end
1291
889
  end
1292
890
 
@@ -1294,71 +892,29 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1294
892
  node.extend(Helpers)
1295
893
  node.instance_eval do
1296
894
  converter.set_local_variables(binding, opts) unless opts.empty?
1297
- _buf = ''
1298
- if !notitle && has_header?
1299
- _buf << ("<h1".freeze)
1300
- _slim_codeattributes1 = id
1301
- if _slim_codeattributes1
1302
- if _slim_codeattributes1 == true
1303
- _buf << (" id".freeze)
1304
- else
1305
- _buf << (" id=\"".freeze)
1306
- _buf << ((_slim_codeattributes1).to_s)
1307
- _buf << ("\"".freeze)
1308
- end
1309
- end
1310
- _buf << (">".freeze)
1311
- _buf << ((header.title).to_s)
1312
- _buf << ("</h1>".freeze)
1313
- end
1314
- if node.sections? && (attr? :toc) && (attr 'toc-placement', 'auto') == 'auto'
1315
- _buf << ("<nav id=\"toc\"".freeze)
1316
- _temple_html_attributeremover1 = ''
1317
- _slim_codeattributes2 = (attr 'toc-class', 'toc')
1318
- if Array === _slim_codeattributes2
1319
- _slim_codeattributes2 = _slim_codeattributes2.flatten
1320
- _slim_codeattributes2.map!(&:to_s)
1321
- _slim_codeattributes2.reject!(&:empty?)
1322
- _temple_html_attributeremover1 << ((_slim_codeattributes2.join(" ")).to_s)
1323
- else
1324
- _temple_html_attributeremover1 << ((_slim_codeattributes2).to_s)
1325
- end
1326
- _temple_html_attributeremover1
1327
- if !_temple_html_attributeremover1.empty?
1328
- _buf << (" class=\"".freeze)
1329
- _buf << ((_temple_html_attributeremover1).to_s)
1330
- _buf << ("\"".freeze)
1331
- end
1332
- _buf << (" role=\"doc-toc\"><h2 id=\"toc-title\">".freeze)
1333
- _buf << (((attr 'toc-title')).to_s)
1334
- _buf << ("</h2>".freeze)
1335
- _buf << ((converter.convert document, 'outline').to_s)
1336
- _buf << ("</nav>".freeze)
1337
- end
1338
- _buf << ((content).to_s)
1339
- if footnotes? && !(attr? :nofootnotes)
1340
- _buf << ("<section class=\"footnotes\" aria-label=\"Footnotes\" role=\"doc-endnotes\"><hr><ol class=\"footnotes\">".freeze)
1341
- footnotes.each do |fn|
1342
- _buf << ("<li class=\"footnote\"".freeze)
1343
- _slim_codeattributes3 = (footnote_id fn.index)
1344
- if _slim_codeattributes3
1345
- if _slim_codeattributes3 == true
1346
- _buf << (" id".freeze)
1347
- else
1348
- _buf << (" id=\"".freeze)
1349
- _buf << ((_slim_codeattributes3).to_s)
1350
- _buf << ("\"".freeze)
1351
- end
1352
- end
1353
- _buf << (" role=\"doc-endnote\">".freeze)
1354
- _buf << (("#{fn.text} ").to_s)
1355
- _buf << ("<a class=\"footnote-backref\" href=\"#".freeze)
1356
- _buf << ((footnoteref_id fn.index).to_s)
1357
- _buf << ("\" role=\"doc-backlink\" title=\"Jump to the first occurrence in the text\">&#8617;</a></li>".freeze)
1358
- end
1359
- _buf << ("</ol></section>".freeze)
1360
- end
1361
- _buf
895
+ _buf = []; if !notitle && has_header?;
896
+ ; _buf << ("<h1"); _slim_codeattributes1 = id; if _slim_codeattributes1; if _slim_codeattributes1 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes1); _buf << ("\""); end; end; _buf << (">"); _buf << (header.title);
897
+ ; _buf << ("</h1>"); end; if node.sections? && (attr? :toc) && (attr 'toc-placement', 'auto') == 'auto';
898
+ ; _buf << ("<nav id=\"toc\""); _temple_html_attributeremover1 = []; _slim_codeattributes2 = (attr 'toc-class', 'toc'); if Array === _slim_codeattributes2; _slim_codeattributes2 = _slim_codeattributes2.flatten; _slim_codeattributes2.map!(&:to_s); _slim_codeattributes2.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes2.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes2); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover1); _buf << ("\""); end; _buf << (" role=\"doc-toc\"><h2 id=\"toc-title\">");
899
+ ; _buf << ((attr 'toc-title'));
900
+ ; _buf << ("</h2>");
901
+ ; _buf << (converter.convert document, 'outline');
902
+ ; _buf << ("</nav>");
903
+ ; end; _buf << (content);
904
+ ; if footnotes? && !(attr? :nofootnotes);
905
+ ; _buf << ("<section class=\"footnotes\" aria-label=\"Footnotes\" role=\"doc-endnotes\"><hr><ol class=\"footnotes\">");
906
+ ;
907
+ ;
908
+ ; footnotes.each do |fn|;
909
+ ; _buf << ("<li class=\"footnote\""); _slim_codeattributes3 = (footnote_id fn.index); if _slim_codeattributes3; if _slim_codeattributes3 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes3); _buf << ("\""); end; end; _buf << (" role=\"doc-endnote\">");
910
+ ; _buf << ("#{fn.text} ");
911
+ ;
912
+ ;
913
+ ;
914
+ ; _buf << ("<a class=\"footnote-backref\" href=\"#"); _buf << (footnoteref_id fn.index); _buf << ("\" role=\"doc-backlink\" title=\"Jump to the first occurrence in the text\">&#8617;</a></li>");
915
+ ;
916
+ ; end; _buf << ("</ol></section>");
917
+ ; end; _buf = _buf.join("")
1362
918
  end
1363
919
  end
1364
920
 
@@ -1366,16 +922,10 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1366
922
  node.extend(Helpers)
1367
923
  node.instance_eval do
1368
924
  converter.set_local_variables(binding, opts) unless opts.empty?
1369
- _buf = ''
1370
- _slim_controls1 = block_with_caption :top, :class=>'example-block' do
1371
- _slim_controls2 = ''
1372
- _slim_controls2 << ("<div class=\"example\">".freeze)
1373
- _slim_controls2 << ((content).to_s)
1374
- _slim_controls2 << ("</div>".freeze)
1375
- _slim_controls2
1376
- end
1377
- _buf << ((_slim_controls1).to_s)
1378
- _buf
925
+ _buf = []; _slim_controls1 = block_with_caption :top, :class=>'example-block' do; _slim_controls2 = [];
926
+ ; _slim_controls2 << ("<div class=\"example\">");
927
+ ; _slim_controls2 << (content);
928
+ ; _slim_controls2 << ("</div>"); _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
1379
929
  end
1380
930
  end
1381
931
 
@@ -1383,42 +933,9 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1383
933
  node.extend(Helpers)
1384
934
  node.instance_eval do
1385
935
  converter.set_local_variables(binding, opts) unless opts.empty?
1386
- _buf = ''
1387
- _slim_htag_filter1 = ((level + 1)).to_s
1388
- _buf << ("<h".freeze)
1389
- _buf << ((_slim_htag_filter1).to_s)
1390
- _slim_codeattributes1 = id
1391
- if _slim_codeattributes1
1392
- if _slim_codeattributes1 == true
1393
- _buf << (" id".freeze)
1394
- else
1395
- _buf << (" id=\"".freeze)
1396
- _buf << ((_slim_codeattributes1).to_s)
1397
- _buf << ("\"".freeze)
1398
- end
1399
- end
1400
- _temple_html_attributeremover1 = ''
1401
- _slim_codeattributes2 = [style, role]
1402
- if Array === _slim_codeattributes2
1403
- _slim_codeattributes2 = _slim_codeattributes2.flatten
1404
- _slim_codeattributes2.map!(&:to_s)
1405
- _slim_codeattributes2.reject!(&:empty?)
1406
- _temple_html_attributeremover1 << ((_slim_codeattributes2.join(" ")).to_s)
1407
- else
1408
- _temple_html_attributeremover1 << ((_slim_codeattributes2).to_s)
1409
- end
1410
- _temple_html_attributeremover1
1411
- if !_temple_html_attributeremover1.empty?
1412
- _buf << (" class=\"".freeze)
1413
- _buf << ((_temple_html_attributeremover1).to_s)
1414
- _buf << ("\"".freeze)
1415
- end
1416
- _buf << (">".freeze)
1417
- _buf << ((title).to_s)
1418
- _buf << ("</h".freeze)
1419
- _buf << ((_slim_htag_filter1).to_s)
1420
- _buf << (">".freeze)
1421
- _buf
936
+ _buf = []; _slim_htag_filter1 = ((level + 1)).to_s; _buf << ("<h"); _buf << (_slim_htag_filter1); _slim_codeattributes1 = id; if _slim_codeattributes1; if _slim_codeattributes1 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes1); _buf << ("\""); end; end; _temple_html_attributeremover1 = []; _slim_codeattributes2 = [style, role]; if Array === _slim_codeattributes2; _slim_codeattributes2 = _slim_codeattributes2.flatten; _slim_codeattributes2.map!(&:to_s); _slim_codeattributes2.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes2.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes2); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover1); _buf << ("\""); end; _buf << (">");
937
+ ; _buf << (title);
938
+ ; _buf << ("</h"); _buf << (_slim_htag_filter1); _buf << (">"); _buf = _buf.join("")
1422
939
  end
1423
940
  end
1424
941
 
@@ -1426,60 +943,10 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1426
943
  node.extend(Helpers)
1427
944
  node.instance_eval do
1428
945
  converter.set_local_variables(binding, opts) unless opts.empty?
1429
- _buf = ''
1430
- _slim_controls1 = block_with_caption(:bottom, :class=>'image-block', :style=>style_value(text_align: (attr :align), float: (attr :float))) do
1431
- _slim_controls2 = ''
1432
- _slim_controls3 = html_tag_if(attr?(:link), :a, :class=>'image', :href=>(attr :link), :target=>(attr :window), :rel=>link_rel) do
1433
- _slim_controls4 = ''
1434
- _slim_controls4 << ("<img".freeze)
1435
- _slim_codeattributes1 = image_uri(attr :target)
1436
- if _slim_codeattributes1
1437
- if _slim_codeattributes1 == true
1438
- _slim_controls4 << (" src".freeze)
1439
- else
1440
- _slim_controls4 << (" src=\"".freeze)
1441
- _slim_controls4 << ((_slim_codeattributes1).to_s)
1442
- _slim_controls4 << ("\"".freeze)
1443
- end
1444
- end
1445
- _slim_codeattributes2 = (attr :alt)
1446
- if _slim_codeattributes2
1447
- if _slim_codeattributes2 == true
1448
- _slim_controls4 << (" alt".freeze)
1449
- else
1450
- _slim_controls4 << (" alt=\"".freeze)
1451
- _slim_controls4 << ((_slim_codeattributes2).to_s)
1452
- _slim_controls4 << ("\"".freeze)
1453
- end
1454
- end
1455
- _slim_codeattributes3 = (attr :width)
1456
- if _slim_codeattributes3
1457
- if _slim_codeattributes3 == true
1458
- _slim_controls4 << (" width".freeze)
1459
- else
1460
- _slim_controls4 << (" width=\"".freeze)
1461
- _slim_controls4 << ((_slim_codeattributes3).to_s)
1462
- _slim_controls4 << ("\"".freeze)
1463
- end
1464
- end
1465
- _slim_codeattributes4 = (attr :height)
1466
- if _slim_codeattributes4
1467
- if _slim_codeattributes4 == true
1468
- _slim_controls4 << (" height".freeze)
1469
- else
1470
- _slim_controls4 << (" height=\"".freeze)
1471
- _slim_controls4 << ((_slim_codeattributes4).to_s)
1472
- _slim_controls4 << ("\"".freeze)
1473
- end
1474
- end
1475
- _slim_controls4 << (">".freeze)
1476
- _slim_controls4
1477
- end
1478
- _slim_controls2 << ((_slim_controls3).to_s)
1479
- _slim_controls2
1480
- end
1481
- _buf << ((_slim_controls1).to_s)
1482
- _buf
946
+ _buf = []; _slim_controls1 = block_with_caption(:bottom, :class=>'image-block', :style=>style_value(text_align: (attr :align), float: (attr :float))) do; _slim_controls2 = [];
947
+ ; _slim_controls3 = html_tag_if(attr?(:link), :a, :class=>'image', :href=>(attr :link), :target=>(attr :window), :rel=>link_rel) do; _slim_controls4 = [];
948
+ ; _slim_controls4 << ("<img"); _slim_codeattributes1 = image_uri(attr :target); if _slim_codeattributes1; if _slim_codeattributes1 == true; _slim_controls4 << (" src"); else; _slim_controls4 << (" src=\""); _slim_controls4 << (_slim_codeattributes1); _slim_controls4 << ("\""); end; end; _slim_codeattributes2 = (attr :alt); if _slim_codeattributes2; if _slim_codeattributes2 == true; _slim_controls4 << (" alt"); else; _slim_controls4 << (" alt=\""); _slim_controls4 << (_slim_codeattributes2); _slim_controls4 << ("\""); end; end; _slim_codeattributes3 = (attr :width); if _slim_codeattributes3; if _slim_codeattributes3 == true; _slim_controls4 << (" width"); else; _slim_controls4 << (" width=\""); _slim_controls4 << (_slim_codeattributes3); _slim_controls4 << ("\""); end; end; _slim_codeattributes4 = (attr :height); if _slim_codeattributes4; if _slim_codeattributes4 == true; _slim_controls4 << (" height"); else; _slim_controls4 << (" height=\""); _slim_controls4 << (_slim_codeattributes4); _slim_controls4 << ("\""); end; end; _slim_controls4 << (">");
949
+ ; _slim_controls4 = _slim_controls4.join(""); end; _slim_controls2 << (_slim_controls3); _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
1483
950
  end
1484
951
  end
1485
952
 
@@ -1487,123 +954,19 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1487
954
  node.extend(Helpers)
1488
955
  node.instance_eval do
1489
956
  converter.set_local_variables(binding, opts) unless opts.empty?
1490
- _buf = ''
1491
- case type
1492
- when :xref
1493
- _buf << ("<a".freeze)
1494
- _slim_codeattributes1 = target
1495
- if _slim_codeattributes1
1496
- if _slim_codeattributes1 == true
1497
- _buf << (" href".freeze)
1498
- else
1499
- _buf << (" href=\"".freeze)
1500
- _buf << ((_slim_codeattributes1).to_s)
1501
- _buf << ("\"".freeze)
1502
- end
1503
- end
1504
- _buf << (">".freeze)
1505
- _buf << ((xref_text).to_s)
1506
- _buf << ("</a>".freeze)
1507
- when :ref
1508
- _buf << ("<a".freeze)
1509
- _slim_codeattributes2 = (id || target)
1510
- if _slim_codeattributes2
1511
- if _slim_codeattributes2 == true
1512
- _buf << (" id".freeze)
1513
- else
1514
- _buf << (" id=\"".freeze)
1515
- _buf << ((_slim_codeattributes2).to_s)
1516
- _buf << ("\"".freeze)
1517
- end
1518
- end
1519
- _buf << (" aria-hidden=\"true\"></a>".freeze)
1520
- when :bibref
1521
- _buf << ("<a".freeze)
1522
- _slim_codeattributes3 = (id || target)
1523
- if _slim_codeattributes3
1524
- if _slim_codeattributes3 == true
1525
- _buf << (" id".freeze)
1526
- else
1527
- _buf << (" id=\"".freeze)
1528
- _buf << ((_slim_codeattributes3).to_s)
1529
- _buf << ("\"".freeze)
1530
- end
1531
- end
1532
- _buf << (" aria-hidden=\"true\"></a>".freeze)
1533
- _buf << ((bibref_text).to_s)
1534
- else
1535
- _buf << ("<a".freeze)
1536
- _slim_codeattributes4 = id
1537
- if _slim_codeattributes4
1538
- if _slim_codeattributes4 == true
1539
- _buf << (" id".freeze)
1540
- else
1541
- _buf << (" id=\"".freeze)
1542
- _buf << ((_slim_codeattributes4).to_s)
1543
- _buf << ("\"".freeze)
1544
- end
1545
- end
1546
- _temple_html_attributeremover1 = ''
1547
- _slim_codeattributes5 = role
1548
- if Array === _slim_codeattributes5
1549
- _slim_codeattributes5 = _slim_codeattributes5.flatten
1550
- _slim_codeattributes5.map!(&:to_s)
1551
- _slim_codeattributes5.reject!(&:empty?)
1552
- _temple_html_attributeremover1 << ((_slim_codeattributes5.join(" ")).to_s)
1553
- else
1554
- _temple_html_attributeremover1 << ((_slim_codeattributes5).to_s)
1555
- end
1556
- _temple_html_attributeremover1
1557
- if !_temple_html_attributeremover1.empty?
1558
- _buf << (" class=\"".freeze)
1559
- _buf << ((_temple_html_attributeremover1).to_s)
1560
- _buf << ("\"".freeze)
1561
- end
1562
- _slim_codeattributes6 = target
1563
- if _slim_codeattributes6
1564
- if _slim_codeattributes6 == true
1565
- _buf << (" href".freeze)
1566
- else
1567
- _buf << (" href=\"".freeze)
1568
- _buf << ((_slim_codeattributes6).to_s)
1569
- _buf << ("\"".freeze)
1570
- end
1571
- end
1572
- _slim_codeattributes7 = (attr :window)
1573
- if _slim_codeattributes7
1574
- if _slim_codeattributes7 == true
1575
- _buf << (" target".freeze)
1576
- else
1577
- _buf << (" target=\"".freeze)
1578
- _buf << ((_slim_codeattributes7).to_s)
1579
- _buf << ("\"".freeze)
1580
- end
1581
- end
1582
- _slim_codeattributes8 = link_rel
1583
- if _slim_codeattributes8
1584
- if _slim_codeattributes8 == true
1585
- _buf << (" rel".freeze)
1586
- else
1587
- _buf << (" rel=\"".freeze)
1588
- _buf << ((_slim_codeattributes8).to_s)
1589
- _buf << ("\"".freeze)
1590
- end
1591
- end
1592
- _slim_codeattributes9 = (attr :title)
1593
- if _slim_codeattributes9
1594
- if _slim_codeattributes9 == true
1595
- _buf << (" title".freeze)
1596
- else
1597
- _buf << (" title=\"".freeze)
1598
- _buf << ((_slim_codeattributes9).to_s)
1599
- _buf << ("\"".freeze)
1600
- end
1601
- end
1602
- _buf << (">".freeze)
1603
- _buf << ((text).to_s)
1604
- _buf << ("</a>".freeze)
1605
- end
1606
- _buf
957
+ _buf = []; case type;
958
+ ; when :xref;
959
+ ; _buf << ("<a"); _slim_codeattributes1 = target; if _slim_codeattributes1; if _slim_codeattributes1 == true; _buf << (" href"); else; _buf << (" href=\""); _buf << (_slim_codeattributes1); _buf << ("\""); end; end; _buf << (">"); _buf << (xref_text);
960
+ ; _buf << ("</a>"); when :ref;
961
+ ;
962
+ ; _buf << ("<a"); _slim_codeattributes2 = (id || target); if _slim_codeattributes2; if _slim_codeattributes2 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes2); _buf << ("\""); end; end; _buf << (" aria-hidden=\"true\"></a>");
963
+ ; when :bibref;
964
+ ;
965
+ ; _buf << ("<a"); _slim_codeattributes3 = (id || target); if _slim_codeattributes3; if _slim_codeattributes3 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes3); _buf << ("\""); end; end; _buf << (" aria-hidden=\"true\"></a>");
966
+ ; _buf << (bibref_text);
967
+ ; else;
968
+ ; _buf << ("<a"); _slim_codeattributes4 = id; if _slim_codeattributes4; if _slim_codeattributes4 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes4); _buf << ("\""); end; end; _temple_html_attributeremover1 = []; _slim_codeattributes5 = role; if Array === _slim_codeattributes5; _slim_codeattributes5 = _slim_codeattributes5.flatten; _slim_codeattributes5.map!(&:to_s); _slim_codeattributes5.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes5.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes5); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover1); _buf << ("\""); end; _slim_codeattributes6 = target; if _slim_codeattributes6; if _slim_codeattributes6 == true; _buf << (" href"); else; _buf << (" href=\""); _buf << (_slim_codeattributes6); _buf << ("\""); end; end; _slim_codeattributes7 = (attr :window); if _slim_codeattributes7; if _slim_codeattributes7 == true; _buf << (" target"); else; _buf << (" target=\""); _buf << (_slim_codeattributes7); _buf << ("\""); end; end; _slim_codeattributes8 = link_rel; if _slim_codeattributes8; if _slim_codeattributes8 == true; _buf << (" rel"); else; _buf << (" rel=\""); _buf << (_slim_codeattributes8); _buf << ("\""); end; end; _slim_codeattributes9 = (attr :title); if _slim_codeattributes9; if _slim_codeattributes9 == true; _buf << (" title"); else; _buf << (" title=\""); _buf << (_slim_codeattributes9); _buf << ("\""); end; end; _buf << (">"); _buf << (text);
969
+ ; _buf << ("</a>"); end; _buf = _buf.join("")
1607
970
  end
1608
971
  end
1609
972
 
@@ -1611,10 +974,9 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1611
974
  node.extend(Helpers)
1612
975
  node.instance_eval do
1613
976
  converter.set_local_variables(binding, opts) unless opts.empty?
1614
- _buf = ''
1615
- _buf << ((text).to_s)
1616
- _buf << ("<br>".freeze)
1617
- _buf
977
+ _buf = []; _buf << (text);
978
+ ; _buf << ("<br>");
979
+ ; _buf = _buf.join("")
1618
980
  end
1619
981
  end
1620
982
 
@@ -1622,11 +984,8 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1622
984
  node.extend(Helpers)
1623
985
  node.instance_eval do
1624
986
  converter.set_local_variables(binding, opts) unless opts.empty?
1625
- _buf = ''
1626
- _buf << ("<b class=\"button\">".freeze)
1627
- _buf << ((text).to_s)
1628
- _buf << ("</b>".freeze)
1629
- _buf
987
+ _buf = []; _buf << ("<b class=\"button\">"); _buf << (text);
988
+ ; _buf << ("</b>"); _buf = _buf.join("")
1630
989
  end
1631
990
  end
1632
991
 
@@ -1634,11 +993,8 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1634
993
  node.extend(Helpers)
1635
994
  node.instance_eval do
1636
995
  converter.set_local_variables(binding, opts) unless opts.empty?
1637
- _buf = ''
1638
- _buf << ("<b class=\"conum\">".freeze)
1639
- _buf << ((text).to_s)
1640
- _buf << ("</b>".freeze)
1641
- _buf
996
+ _buf = []; _buf << ("<b class=\"conum\">"); _buf << (text);
997
+ ; _buf << ("</b>"); _buf = _buf.join("")
1642
998
  end
1643
999
  end
1644
1000
 
@@ -1646,32 +1002,16 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1646
1002
  node.extend(Helpers)
1647
1003
  node.instance_eval do
1648
1004
  converter.set_local_variables(binding, opts) unless opts.empty?
1649
- _buf = ''
1650
- if (index = local_attr :index)
1651
- _buf << ("<a class=\"footnote-ref\"".freeze)
1652
- _slim_codeattributes1 = (footnoteref_id unless type == :xref)
1653
- if _slim_codeattributes1
1654
- if _slim_codeattributes1 == true
1655
- _buf << (" id".freeze)
1656
- else
1657
- _buf << (" id=\"".freeze)
1658
- _buf << ((_slim_codeattributes1).to_s)
1659
- _buf << ("\"".freeze)
1660
- end
1661
- end
1662
- _buf << (" href=\"#".freeze)
1663
- _buf << ((footnote_id).to_s)
1664
- _buf << ("\" title=\"View footnote ".freeze)
1665
- _buf << ((index).to_s)
1666
- _buf << ("\" role=\"doc-noteref\">[".freeze)
1667
- _buf << ((index).to_s)
1668
- _buf << ("]</a>".freeze)
1669
- else
1670
- _buf << ("<a class=\"footnote-ref broken\" title=\"Unresolved footnote reference.\">[".freeze)
1671
- _buf << ((text).to_s)
1672
- _buf << ("]</a>".freeze)
1673
- end
1674
- _buf
1005
+ _buf = []; if (index = local_attr :index);
1006
+ ;
1007
+ ;
1008
+ ;
1009
+ ;
1010
+ ; _buf << ("<a class=\"footnote-ref\""); _slim_codeattributes1 = (footnoteref_id unless type == :xref); if _slim_codeattributes1; if _slim_codeattributes1 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes1); _buf << ("\""); end; end; _buf << (" href=\"#"); _buf << (footnote_id); _buf << ("\" title=\"View footnote "); _buf << (index); _buf << ("\" role=\"doc-noteref\">[");
1011
+ ; _buf << (index); _buf << ("]</a>");
1012
+ ; else;
1013
+ ; _buf << ("<a class=\"footnote-ref broken\" title=\"Unresolved footnote reference.\">["); _buf << (text); _buf << ("]</a>");
1014
+ ; end; _buf = _buf.join("")
1675
1015
  end
1676
1016
  end
1677
1017
 
@@ -1679,153 +1019,17 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1679
1019
  node.extend(Helpers)
1680
1020
  node.instance_eval do
1681
1021
  converter.set_local_variables(binding, opts) unless opts.empty?
1682
- _buf = ''
1683
- _slim_controls1 = html_tag_if((attr? :link), :a, :class=>'image', :href=>(attr :link), :target=>(attr :window), :rel=>link_rel) do
1684
- _slim_controls2 = ''
1685
- if type == 'icon' && (document.attr? :icons, 'font')
1686
- _slim_controls2 << ("<i".freeze)
1687
- _temple_html_attributeremover1 = ''
1688
- _slim_codeattributes1 = [*icon_fa_classes, role]
1689
- if Array === _slim_codeattributes1
1690
- _slim_codeattributes1 = _slim_codeattributes1.flatten
1691
- _slim_codeattributes1.map!(&:to_s)
1692
- _slim_codeattributes1.reject!(&:empty?)
1693
- _temple_html_attributeremover1 << ((_slim_codeattributes1.join(" ")).to_s)
1694
- else
1695
- _temple_html_attributeremover1 << ((_slim_codeattributes1).to_s)
1696
- end
1697
- _temple_html_attributeremover1
1698
- if !_temple_html_attributeremover1.empty?
1699
- _slim_controls2 << (" class=\"".freeze)
1700
- _slim_controls2 << ((_temple_html_attributeremover1).to_s)
1701
- _slim_controls2 << ("\"".freeze)
1702
- end
1703
- _slim_codeattributes2 = (attr :title)
1704
- if _slim_codeattributes2
1705
- if _slim_codeattributes2 == true
1706
- _slim_controls2 << (" title".freeze)
1707
- else
1708
- _slim_controls2 << (" title=\"".freeze)
1709
- _slim_controls2 << ((_slim_codeattributes2).to_s)
1710
- _slim_controls2 << ("\"".freeze)
1711
- end
1712
- end
1713
- _slim_controls2 << ("></i>".freeze)
1714
- elsif type == 'icon' && !(document.attr? :icons)
1715
- _slim_controls2 << ("<b".freeze)
1716
- _temple_html_attributeremover2 = ''
1717
- _slim_codeattributes3 = ['icon', role]
1718
- if Array === _slim_codeattributes3
1719
- _slim_codeattributes3 = _slim_codeattributes3.flatten
1720
- _slim_codeattributes3.map!(&:to_s)
1721
- _slim_codeattributes3.reject!(&:empty?)
1722
- _temple_html_attributeremover2 << ((_slim_codeattributes3.join(" ")).to_s)
1723
- else
1724
- _temple_html_attributeremover2 << ((_slim_codeattributes3).to_s)
1725
- end
1726
- _temple_html_attributeremover2
1727
- if !_temple_html_attributeremover2.empty?
1728
- _slim_controls2 << (" class=\"".freeze)
1729
- _slim_controls2 << ((_temple_html_attributeremover2).to_s)
1730
- _slim_controls2 << ("\"".freeze)
1731
- end
1732
- _slim_codeattributes4 = (attr :title)
1733
- if _slim_codeattributes4
1734
- if _slim_codeattributes4 == true
1735
- _slim_controls2 << (" title".freeze)
1736
- else
1737
- _slim_controls2 << (" title=\"".freeze)
1738
- _slim_controls2 << ((_slim_codeattributes4).to_s)
1739
- _slim_controls2 << ("\"".freeze)
1740
- end
1741
- end
1742
- _slim_controls2 << (">[".freeze)
1743
- _slim_controls2 << ((attr :alt).to_s)
1744
- _slim_controls2 << ("]</b>".freeze)
1745
- else
1746
- _slim_controls2 << ("<img".freeze)
1747
- _slim_codeattributes5 = (type == 'icon' ? (icon_uri target) : (image_uri target))
1748
- if _slim_codeattributes5
1749
- if _slim_codeattributes5 == true
1750
- _slim_controls2 << (" src".freeze)
1751
- else
1752
- _slim_controls2 << (" src=\"".freeze)
1753
- _slim_controls2 << ((_slim_codeattributes5).to_s)
1754
- _slim_controls2 << ("\"".freeze)
1755
- end
1756
- end
1757
- _slim_codeattributes6 = (attr :alt)
1758
- if _slim_codeattributes6
1759
- if _slim_codeattributes6 == true
1760
- _slim_controls2 << (" alt".freeze)
1761
- else
1762
- _slim_controls2 << (" alt=\"".freeze)
1763
- _slim_controls2 << ((_slim_codeattributes6).to_s)
1764
- _slim_controls2 << ("\"".freeze)
1765
- end
1766
- end
1767
- _slim_codeattributes7 = (attr :width)
1768
- if _slim_codeattributes7
1769
- if _slim_codeattributes7 == true
1770
- _slim_controls2 << (" width".freeze)
1771
- else
1772
- _slim_controls2 << (" width=\"".freeze)
1773
- _slim_controls2 << ((_slim_codeattributes7).to_s)
1774
- _slim_controls2 << ("\"".freeze)
1775
- end
1776
- end
1777
- _slim_codeattributes8 = (attr :height)
1778
- if _slim_codeattributes8
1779
- if _slim_codeattributes8 == true
1780
- _slim_controls2 << (" height".freeze)
1781
- else
1782
- _slim_controls2 << (" height=\"".freeze)
1783
- _slim_controls2 << ((_slim_codeattributes8).to_s)
1784
- _slim_controls2 << ("\"".freeze)
1785
- end
1786
- end
1787
- _slim_codeattributes9 = (attr :title)
1788
- if _slim_codeattributes9
1789
- if _slim_codeattributes9 == true
1790
- _slim_controls2 << (" title".freeze)
1791
- else
1792
- _slim_controls2 << (" title=\"".freeze)
1793
- _slim_controls2 << ((_slim_codeattributes9).to_s)
1794
- _slim_controls2 << ("\"".freeze)
1795
- end
1796
- end
1797
- _temple_html_attributeremover3 = ''
1798
- _slim_codeattributes10 = [(type if type != 'image'), role]
1799
- if Array === _slim_codeattributes10
1800
- _slim_codeattributes10 = _slim_codeattributes10.flatten
1801
- _slim_codeattributes10.map!(&:to_s)
1802
- _slim_codeattributes10.reject!(&:empty?)
1803
- _temple_html_attributeremover3 << ((_slim_codeattributes10.join(" ")).to_s)
1804
- else
1805
- _temple_html_attributeremover3 << ((_slim_codeattributes10).to_s)
1806
- end
1807
- _temple_html_attributeremover3
1808
- if !_temple_html_attributeremover3.empty?
1809
- _slim_controls2 << (" class=\"".freeze)
1810
- _slim_controls2 << ((_temple_html_attributeremover3).to_s)
1811
- _slim_controls2 << ("\"".freeze)
1812
- end
1813
- _slim_codeattributes11 = style_value(float: (attr :float))
1814
- if _slim_codeattributes11
1815
- if _slim_codeattributes11 == true
1816
- _slim_controls2 << (" style".freeze)
1817
- else
1818
- _slim_controls2 << (" style=\"".freeze)
1819
- _slim_controls2 << ((_slim_codeattributes11).to_s)
1820
- _slim_controls2 << ("\"".freeze)
1821
- end
1822
- end
1823
- _slim_controls2 << (">".freeze)
1824
- end
1825
- _slim_controls2
1826
- end
1827
- _buf << ((_slim_controls1).to_s)
1828
- _buf
1022
+ _buf = []; _slim_controls1 = html_tag_if((attr? :link), :a, :class=>'image', :href=>(attr :link), :target=>(attr :window), :rel=>link_rel) do; _slim_controls2 = [];
1023
+ ; if type == 'icon' && (document.attr? :icons, 'font');
1024
+ ; _slim_controls2 << ("<i"); _temple_html_attributeremover1 = []; _slim_codeattributes1 = [*icon_fa_classes, role]; if Array === _slim_codeattributes1; _slim_codeattributes1 = _slim_codeattributes1.flatten; _slim_codeattributes1.map!(&:to_s); _slim_codeattributes1.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes1.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes1); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _slim_controls2 << (" class=\""); _slim_controls2 << (_temple_html_attributeremover1); _slim_controls2 << ("\""); end; _slim_codeattributes2 = (attr :title); if _slim_codeattributes2; if _slim_codeattributes2 == true; _slim_controls2 << (" title"); else; _slim_controls2 << (" title=\""); _slim_controls2 << (_slim_codeattributes2); _slim_controls2 << ("\""); end; end; _slim_controls2 << ("></i>");
1025
+ ; elsif type == 'icon' && !(document.attr? :icons);
1026
+ ; _slim_controls2 << ("<b"); _temple_html_attributeremover2 = []; _slim_codeattributes3 = ['icon', role]; if Array === _slim_codeattributes3; _slim_codeattributes3 = _slim_codeattributes3.flatten; _slim_codeattributes3.map!(&:to_s); _slim_codeattributes3.reject!(&:empty?); _temple_html_attributeremover2 << (_slim_codeattributes3.join(" ")); else; _temple_html_attributeremover2 << (_slim_codeattributes3); end; _temple_html_attributeremover2 = _temple_html_attributeremover2.join(""); if !_temple_html_attributeremover2.empty?; _slim_controls2 << (" class=\""); _slim_controls2 << (_temple_html_attributeremover2); _slim_controls2 << ("\""); end; _slim_codeattributes4 = (attr :title); if _slim_codeattributes4; if _slim_codeattributes4 == true; _slim_controls2 << (" title"); else; _slim_controls2 << (" title=\""); _slim_controls2 << (_slim_codeattributes4); _slim_controls2 << ("\""); end; end; _slim_controls2 << (">[");
1027
+ ; _slim_controls2 << (attr :alt); _slim_controls2 << ("]</b>");
1028
+ ; else;
1029
+ ;
1030
+ ;
1031
+ ; _slim_controls2 << ("<img"); _slim_codeattributes5 = (type == 'icon' ? (icon_uri target) : (image_uri target)); if _slim_codeattributes5; if _slim_codeattributes5 == true; _slim_controls2 << (" src"); else; _slim_controls2 << (" src=\""); _slim_controls2 << (_slim_codeattributes5); _slim_controls2 << ("\""); end; end; _slim_codeattributes6 = (attr :alt); if _slim_codeattributes6; if _slim_codeattributes6 == true; _slim_controls2 << (" alt"); else; _slim_controls2 << (" alt=\""); _slim_controls2 << (_slim_codeattributes6); _slim_controls2 << ("\""); end; end; _slim_codeattributes7 = (attr :width); if _slim_codeattributes7; if _slim_codeattributes7 == true; _slim_controls2 << (" width"); else; _slim_controls2 << (" width=\""); _slim_controls2 << (_slim_codeattributes7); _slim_controls2 << ("\""); end; end; _slim_codeattributes8 = (attr :height); if _slim_codeattributes8; if _slim_codeattributes8 == true; _slim_controls2 << (" height"); else; _slim_controls2 << (" height=\""); _slim_controls2 << (_slim_codeattributes8); _slim_controls2 << ("\""); end; end; _slim_codeattributes9 = (attr :title); if _slim_codeattributes9; if _slim_codeattributes9 == true; _slim_controls2 << (" title"); else; _slim_controls2 << (" title=\""); _slim_controls2 << (_slim_codeattributes9); _slim_controls2 << ("\""); end; end; _temple_html_attributeremover3 = []; _slim_codeattributes10 = [(type if type != 'image'), role]; if Array === _slim_codeattributes10; _slim_codeattributes10 = _slim_codeattributes10.flatten; _slim_codeattributes10.map!(&:to_s); _slim_codeattributes10.reject!(&:empty?); _temple_html_attributeremover3 << (_slim_codeattributes10.join(" ")); else; _temple_html_attributeremover3 << (_slim_codeattributes10); end; _temple_html_attributeremover3 = _temple_html_attributeremover3.join(""); if !_temple_html_attributeremover3.empty?; _slim_controls2 << (" class=\""); _slim_controls2 << (_temple_html_attributeremover3); _slim_controls2 << ("\""); end; _slim_codeattributes11 = style_value(float: (attr :float)); if _slim_codeattributes11; if _slim_codeattributes11 == true; _slim_controls2 << (" style"); else; _slim_controls2 << (" style=\""); _slim_controls2 << (_slim_codeattributes11); _slim_controls2 << ("\""); end; end; _slim_controls2 << (">");
1032
+ ; end; _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
1829
1033
  end
1830
1034
  end
1831
1035
 
@@ -1833,11 +1037,9 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1833
1037
  node.extend(Helpers)
1834
1038
  node.instance_eval do
1835
1039
  converter.set_local_variables(binding, opts) unless opts.empty?
1836
- _buf = ''
1837
- if type == :visible
1838
- _buf << ((text).to_s)
1839
- end
1840
- _buf
1040
+ _buf = []; if type == :visible;
1041
+ ; _buf << (text);
1042
+ ; end; _buf = _buf.join("")
1841
1043
  end
1842
1044
  end
1843
1045
 
@@ -1845,22 +1047,14 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1845
1047
  node.extend(Helpers)
1846
1048
  node.instance_eval do
1847
1049
  converter.set_local_variables(binding, opts) unless opts.empty?
1848
- _buf = ''
1849
- if (keys = attr 'keys').size == 1
1850
- _buf << ("<kbd>".freeze)
1851
- _buf << ((keys.first).to_s)
1852
- _buf << ("</kbd>".freeze)
1853
- else
1854
- _buf << ("<kbd class=\"keyseq\">".freeze)
1855
- keys.each_with_index do |key, idx|
1856
- _buf << (("+" unless idx.zero?).to_s)
1857
- _buf << ("<kbd>".freeze)
1858
- _buf << ((key).to_s)
1859
- _buf << ("</kbd>".freeze)
1860
- end
1861
- _buf << ("</kbd>".freeze)
1862
- end
1863
- _buf
1050
+ _buf = []; if (keys = attr 'keys').size == 1;
1051
+ ; _buf << ("<kbd>"); _buf << (keys.first);
1052
+ ; _buf << ("</kbd>"); else;
1053
+ ; _buf << ("<kbd class=\"keyseq\">");
1054
+ ; keys.each_with_index do |key, idx|;
1055
+ ; _buf << ("+" unless idx.zero?);
1056
+ ; _buf << ("<kbd>"); _buf << (key);
1057
+ ; _buf << ("</kbd>"); end; _buf << ("</kbd>"); end; _buf = _buf.join("")
1864
1058
  end
1865
1059
  end
1866
1060
 
@@ -1868,30 +1062,22 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1868
1062
  node.extend(Helpers)
1869
1063
  node.instance_eval do
1870
1064
  converter.set_local_variables(binding, opts) unless opts.empty?
1871
- _buf = ''
1872
- if local_attr :menuitem
1873
- capture do
1874
- _buf << ("&#160;<b class=\"caret\">&#8250;</b>".freeze)
1875
- end
1876
- _buf << ("<span class=\"menuseq\"><b class=\"menu\">".freeze)
1877
- _buf << (((attr :menu)).to_s)
1878
- yield_capture
1879
- _buf << ("</b>".freeze)
1880
- (attr 'submenus').each do |submenu|
1881
- _buf << ("<b class=\"submenu\">".freeze)
1882
- _buf << ((submenu).to_s)
1883
- yield_capture
1884
- _buf << ("</b>".freeze)
1885
- end
1886
- _buf << ("<b class=\"menuitem\">".freeze)
1887
- _buf << (((local_attr :menuitem)).to_s)
1888
- _buf << ("</b></span>".freeze)
1889
- else
1890
- _buf << ("<b class=\"menuref\">".freeze)
1891
- _buf << (((attr :menu)).to_s)
1892
- _buf << ("</b>".freeze)
1893
- end
1894
- _buf
1065
+ _buf = []; if local_attr :menuitem;
1066
+ ; capture do;
1067
+ ; _buf << ("&#160;<b class=\"caret\">&#8250;</b>");
1068
+ ;
1069
+ ; end; _buf << ("<span class=\"menuseq\"><b class=\"menu\">");
1070
+ ;
1071
+ ; _buf << ((attr :menu));
1072
+ ; yield_capture;
1073
+ ; _buf << ("</b>"); (attr 'submenus').each do |submenu|;
1074
+ ; _buf << ("<b class=\"submenu\">");
1075
+ ; _buf << (submenu);
1076
+ ; yield_capture;
1077
+ ; _buf << ("</b>"); end; _buf << ("<b class=\"menuitem\">"); _buf << ((local_attr :menuitem));
1078
+ ; _buf << ("</b></span>"); else;
1079
+ ; _buf << ("<b class=\"menuref\">"); _buf << ((attr :menu));
1080
+ ; _buf << ("</b>"); end; _buf = _buf.join("")
1895
1081
  end
1896
1082
  end
1897
1083
 
@@ -1899,179 +1085,36 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
1899
1085
  node.extend(Helpers)
1900
1086
  node.instance_eval do
1901
1087
  converter.set_local_variables(binding, opts) unless opts.empty?
1902
- _buf = ''
1903
- unless id.nil?
1904
- _buf << ("<a".freeze)
1905
- _slim_codeattributes1 = id
1906
- if _slim_codeattributes1
1907
- if _slim_codeattributes1 == true
1908
- _buf << (" id".freeze)
1909
- else
1910
- _buf << (" id=\"".freeze)
1911
- _buf << ((_slim_codeattributes1).to_s)
1912
- _buf << ("\"".freeze)
1913
- end
1914
- end
1915
- _buf << (" aria-hidden=\"true\"></a>".freeze)
1916
- end
1917
- case type
1918
- when :emphasis
1919
- _buf << ("<em".freeze)
1920
- _temple_html_attributeremover1 = ''
1921
- _slim_codeattributes2 = role
1922
- if Array === _slim_codeattributes2
1923
- _slim_codeattributes2 = _slim_codeattributes2.flatten
1924
- _slim_codeattributes2.map!(&:to_s)
1925
- _slim_codeattributes2.reject!(&:empty?)
1926
- _temple_html_attributeremover1 << ((_slim_codeattributes2.join(" ")).to_s)
1927
- else
1928
- _temple_html_attributeremover1 << ((_slim_codeattributes2).to_s)
1929
- end
1930
- _temple_html_attributeremover1
1931
- if !_temple_html_attributeremover1.empty?
1932
- _buf << (" class=\"".freeze)
1933
- _buf << ((_temple_html_attributeremover1).to_s)
1934
- _buf << ("\"".freeze)
1935
- end
1936
- _buf << (">".freeze)
1937
- _buf << ((text).to_s)
1938
- _buf << ("</em>".freeze)
1939
- when :strong
1940
- _buf << ("<strong".freeze)
1941
- _temple_html_attributeremover2 = ''
1942
- _slim_codeattributes3 = role
1943
- if Array === _slim_codeattributes3
1944
- _slim_codeattributes3 = _slim_codeattributes3.flatten
1945
- _slim_codeattributes3.map!(&:to_s)
1946
- _slim_codeattributes3.reject!(&:empty?)
1947
- _temple_html_attributeremover2 << ((_slim_codeattributes3.join(" ")).to_s)
1948
- else
1949
- _temple_html_attributeremover2 << ((_slim_codeattributes3).to_s)
1950
- end
1951
- _temple_html_attributeremover2
1952
- if !_temple_html_attributeremover2.empty?
1953
- _buf << (" class=\"".freeze)
1954
- _buf << ((_temple_html_attributeremover2).to_s)
1955
- _buf << ("\"".freeze)
1956
- end
1957
- _buf << (">".freeze)
1958
- _buf << ((text).to_s)
1959
- _buf << ("</strong>".freeze)
1960
- when :monospaced
1961
- _buf << ("<code".freeze)
1962
- _temple_html_attributeremover3 = ''
1963
- _slim_codeattributes4 = role
1964
- if Array === _slim_codeattributes4
1965
- _slim_codeattributes4 = _slim_codeattributes4.flatten
1966
- _slim_codeattributes4.map!(&:to_s)
1967
- _slim_codeattributes4.reject!(&:empty?)
1968
- _temple_html_attributeremover3 << ((_slim_codeattributes4.join(" ")).to_s)
1969
- else
1970
- _temple_html_attributeremover3 << ((_slim_codeattributes4).to_s)
1971
- end
1972
- _temple_html_attributeremover3
1973
- if !_temple_html_attributeremover3.empty?
1974
- _buf << (" class=\"".freeze)
1975
- _buf << ((_temple_html_attributeremover3).to_s)
1976
- _buf << ("\"".freeze)
1977
- end
1978
- _buf << (">".freeze)
1979
- _buf << ((text).to_s)
1980
- _buf << ("</code>".freeze)
1981
- when :superscript
1982
- _buf << ("<sup".freeze)
1983
- _temple_html_attributeremover4 = ''
1984
- _slim_codeattributes5 = role
1985
- if Array === _slim_codeattributes5
1986
- _slim_codeattributes5 = _slim_codeattributes5.flatten
1987
- _slim_codeattributes5.map!(&:to_s)
1988
- _slim_codeattributes5.reject!(&:empty?)
1989
- _temple_html_attributeremover4 << ((_slim_codeattributes5.join(" ")).to_s)
1990
- else
1991
- _temple_html_attributeremover4 << ((_slim_codeattributes5).to_s)
1992
- end
1993
- _temple_html_attributeremover4
1994
- if !_temple_html_attributeremover4.empty?
1995
- _buf << (" class=\"".freeze)
1996
- _buf << ((_temple_html_attributeremover4).to_s)
1997
- _buf << ("\"".freeze)
1998
- end
1999
- _buf << (">".freeze)
2000
- _buf << ((text).to_s)
2001
- _buf << ("</sup>".freeze)
2002
- when :subscript
2003
- _buf << ("<sub".freeze)
2004
- _temple_html_attributeremover5 = ''
2005
- _slim_codeattributes6 = role
2006
- if Array === _slim_codeattributes6
2007
- _slim_codeattributes6 = _slim_codeattributes6.flatten
2008
- _slim_codeattributes6.map!(&:to_s)
2009
- _slim_codeattributes6.reject!(&:empty?)
2010
- _temple_html_attributeremover5 << ((_slim_codeattributes6.join(" ")).to_s)
2011
- else
2012
- _temple_html_attributeremover5 << ((_slim_codeattributes6).to_s)
2013
- end
2014
- _temple_html_attributeremover5
2015
- if !_temple_html_attributeremover5.empty?
2016
- _buf << (" class=\"".freeze)
2017
- _buf << ((_temple_html_attributeremover5).to_s)
2018
- _buf << ("\"".freeze)
2019
- end
2020
- _buf << (">".freeze)
2021
- _buf << ((text).to_s)
2022
- _buf << ("</sub>".freeze)
2023
- when :mark
2024
- _buf << ("<mark".freeze)
2025
- _temple_html_attributeremover6 = ''
2026
- _slim_codeattributes7 = role
2027
- if Array === _slim_codeattributes7
2028
- _slim_codeattributes7 = _slim_codeattributes7.flatten
2029
- _slim_codeattributes7.map!(&:to_s)
2030
- _slim_codeattributes7.reject!(&:empty?)
2031
- _temple_html_attributeremover6 << ((_slim_codeattributes7.join(" ")).to_s)
2032
- else
2033
- _temple_html_attributeremover6 << ((_slim_codeattributes7).to_s)
2034
- end
2035
- _temple_html_attributeremover6
2036
- if !_temple_html_attributeremover6.empty?
2037
- _buf << (" class=\"".freeze)
2038
- _buf << ((_temple_html_attributeremover6).to_s)
2039
- _buf << ("\"".freeze)
2040
- end
2041
- _buf << (">".freeze)
2042
- _buf << ((text).to_s)
2043
- _buf << ("</mark>".freeze)
2044
- when :double
2045
- _slim_controls1 = html_tag_if role?, :span, :class=>role do
2046
- _slim_controls2 = ''
2047
- _slim_controls2 << ("&#8220;".freeze)
2048
- _slim_controls2 << ((text).to_s)
2049
- _slim_controls2 << ("&#8221;".freeze)
2050
- _slim_controls2
2051
- end
2052
- _buf << ((_slim_controls1).to_s)
2053
- when :single
2054
- _slim_controls3 = html_tag_if role?, :span, :class=>role do
2055
- _slim_controls4 = ''
2056
- _slim_controls4 << ("&#8216;".freeze)
2057
- _slim_controls4 << ((text).to_s)
2058
- _slim_controls4 << ("&#8217;".freeze)
2059
- _slim_controls4
2060
- end
2061
- _buf << ((_slim_controls3).to_s)
2062
- when :asciimath, :latexmath
2063
- _buf << ("<span class=\"math\">".freeze)
2064
- _buf << ((delimit_stem text, type).to_s)
2065
- _buf << ("</span>".freeze)
2066
- else
2067
- _slim_controls5 = html_tag_if role?, :span, :class=>role do
2068
- _slim_controls6 = ''
2069
- _slim_controls6 << ((text).to_s)
2070
- _slim_controls6
2071
- end
2072
- _buf << ((_slim_controls5).to_s)
2073
- end
2074
- _buf
1088
+ _buf = []; unless id.nil?;
1089
+ ; _buf << ("<a"); _slim_codeattributes1 = id; if _slim_codeattributes1; if _slim_codeattributes1 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes1); _buf << ("\""); end; end; _buf << (" aria-hidden=\"true\"></a>");
1090
+ ; end; case type;
1091
+ ; when :emphasis;
1092
+ ; _buf << ("<em"); _temple_html_attributeremover1 = []; _slim_codeattributes2 = role; if Array === _slim_codeattributes2; _slim_codeattributes2 = _slim_codeattributes2.flatten; _slim_codeattributes2.map!(&:to_s); _slim_codeattributes2.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes2.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes2); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover1); _buf << ("\""); end; _buf << (">"); _buf << (text);
1093
+ ; _buf << ("</em>"); when :strong;
1094
+ ; _buf << ("<strong"); _temple_html_attributeremover2 = []; _slim_codeattributes3 = role; if Array === _slim_codeattributes3; _slim_codeattributes3 = _slim_codeattributes3.flatten; _slim_codeattributes3.map!(&:to_s); _slim_codeattributes3.reject!(&:empty?); _temple_html_attributeremover2 << (_slim_codeattributes3.join(" ")); else; _temple_html_attributeremover2 << (_slim_codeattributes3); end; _temple_html_attributeremover2 = _temple_html_attributeremover2.join(""); if !_temple_html_attributeremover2.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover2); _buf << ("\""); end; _buf << (">"); _buf << (text);
1095
+ ; _buf << ("</strong>"); when :monospaced;
1096
+ ; _buf << ("<code"); _temple_html_attributeremover3 = []; _slim_codeattributes4 = role; if Array === _slim_codeattributes4; _slim_codeattributes4 = _slim_codeattributes4.flatten; _slim_codeattributes4.map!(&:to_s); _slim_codeattributes4.reject!(&:empty?); _temple_html_attributeremover3 << (_slim_codeattributes4.join(" ")); else; _temple_html_attributeremover3 << (_slim_codeattributes4); end; _temple_html_attributeremover3 = _temple_html_attributeremover3.join(""); if !_temple_html_attributeremover3.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover3); _buf << ("\""); end; _buf << (">"); _buf << (text);
1097
+ ; _buf << ("</code>"); when :superscript;
1098
+ ; _buf << ("<sup"); _temple_html_attributeremover4 = []; _slim_codeattributes5 = role; if Array === _slim_codeattributes5; _slim_codeattributes5 = _slim_codeattributes5.flatten; _slim_codeattributes5.map!(&:to_s); _slim_codeattributes5.reject!(&:empty?); _temple_html_attributeremover4 << (_slim_codeattributes5.join(" ")); else; _temple_html_attributeremover4 << (_slim_codeattributes5); end; _temple_html_attributeremover4 = _temple_html_attributeremover4.join(""); if !_temple_html_attributeremover4.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover4); _buf << ("\""); end; _buf << (">"); _buf << (text);
1099
+ ; _buf << ("</sup>"); when :subscript;
1100
+ ; _buf << ("<sub"); _temple_html_attributeremover5 = []; _slim_codeattributes6 = role; if Array === _slim_codeattributes6; _slim_codeattributes6 = _slim_codeattributes6.flatten; _slim_codeattributes6.map!(&:to_s); _slim_codeattributes6.reject!(&:empty?); _temple_html_attributeremover5 << (_slim_codeattributes6.join(" ")); else; _temple_html_attributeremover5 << (_slim_codeattributes6); end; _temple_html_attributeremover5 = _temple_html_attributeremover5.join(""); if !_temple_html_attributeremover5.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover5); _buf << ("\""); end; _buf << (">"); _buf << (text);
1101
+ ; _buf << ("</sub>"); when :mark;
1102
+ ; _buf << ("<mark"); _temple_html_attributeremover6 = []; _slim_codeattributes7 = role; if Array === _slim_codeattributes7; _slim_codeattributes7 = _slim_codeattributes7.flatten; _slim_codeattributes7.map!(&:to_s); _slim_codeattributes7.reject!(&:empty?); _temple_html_attributeremover6 << (_slim_codeattributes7.join(" ")); else; _temple_html_attributeremover6 << (_slim_codeattributes7); end; _temple_html_attributeremover6 = _temple_html_attributeremover6.join(""); if !_temple_html_attributeremover6.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover6); _buf << ("\""); end; _buf << (">"); _buf << (text);
1103
+ ; _buf << ("</mark>"); when :double;
1104
+ ; _slim_controls1 = html_tag_if role?, :span, :class=>role do; _slim_controls2 = [];
1105
+ ; _slim_controls2 << ("&#8220;"); _slim_controls2 << (text); _slim_controls2 << ("&#8221;");
1106
+ ; _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); when :single;
1107
+ ; _slim_controls3 = html_tag_if role?, :span, :class=>role do; _slim_controls4 = [];
1108
+ ; _slim_controls4 << ("&#8216;"); _slim_controls4 << (text); _slim_controls4 << ("&#8217;");
1109
+ ; _slim_controls4 = _slim_controls4.join(""); end; _buf << (_slim_controls3); when :asciimath, :latexmath;
1110
+ ; _buf << ("<span class=\"math\""); _slim_codeattributes8 = stem_lang; if _slim_codeattributes8; if _slim_codeattributes8 == true; _buf << (" data-lang"); else; _buf << (" data-lang=\""); _buf << (_slim_codeattributes8); _buf << ("\""); end; end; _buf << (">"); _buf << ((delimit_stem text, type));
1111
+ ; _buf << ("</span>"); else;
1112
+ ; if role == 'line-through' || role == 'del';
1113
+ ; _buf << ("<del>"); _buf << (text);
1114
+ ; _buf << ("</del>"); else;
1115
+ ; _slim_controls5 = html_tag_if role?, :span, :class=>role do; _slim_controls6 = [];
1116
+ ; _slim_controls6 << (text);
1117
+ ; _slim_controls6 = _slim_controls6.join(""); end; _buf << (_slim_controls5); end; end; _buf = _buf.join("")
2075
1118
  end
2076
1119
  end
2077
1120
 
@@ -2079,106 +1122,22 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2079
1122
  node.extend(Helpers)
2080
1123
  node.instance_eval do
2081
1124
  converter.set_local_variables(binding, opts) unless opts.empty?
2082
- _buf = ''
2083
- _slim_controls1 = block_with_caption :top, :class=>'listing-block' do
2084
- _slim_controls2 = ''
2085
- if style == 'source'
2086
- if highlighter == 'html-pipeline'
2087
- _slim_controls2 << ("<pre><code".freeze)
2088
- _slim_codeattributes1 = source_lang
2089
- if _slim_codeattributes1
2090
- if _slim_codeattributes1 == true
2091
- _slim_controls2 << (" data-lang".freeze)
2092
- else
2093
- _slim_controls2 << (" data-lang=\"".freeze)
2094
- _slim_controls2 << ((_slim_codeattributes1).to_s)
2095
- _slim_controls2 << ("\"".freeze)
2096
- end
2097
- end
2098
- _slim_controls2 << (">".freeze)
2099
- _slim_controls2 << ((content).to_s)
2100
- _slim_controls2 << ("</code></pre>".freeze)
2101
- else
2102
- unless highlighter == 'CodeRay'
2103
- code_class = "language-#{source_lang}" if source_lang
2104
- end
2105
- _slim_controls2 << ("<pre".freeze)
2106
- _temple_html_attributeremover1 = ''
2107
- _slim_codeattributes2 = [highlighter, 'highlight', ('linenums' if attr? :linenums), nowrap?]
2108
- if Array === _slim_codeattributes2
2109
- _slim_codeattributes2 = _slim_codeattributes2.flatten
2110
- _slim_codeattributes2.map!(&:to_s)
2111
- _slim_codeattributes2.reject!(&:empty?)
2112
- _temple_html_attributeremover1 << ((_slim_codeattributes2.join(" ")).to_s)
2113
- else
2114
- _temple_html_attributeremover1 << ((_slim_codeattributes2).to_s)
2115
- end
2116
- _temple_html_attributeremover1
2117
- if !_temple_html_attributeremover1.empty?
2118
- _slim_controls2 << (" class=\"".freeze)
2119
- _slim_controls2 << ((_temple_html_attributeremover1).to_s)
2120
- _slim_controls2 << ("\"".freeze)
2121
- end
2122
- _slim_controls2 << ("><code".freeze)
2123
- _temple_html_attributeremover2 = ''
2124
- _slim_codeattributes3 = code_class
2125
- if Array === _slim_codeattributes3
2126
- _slim_codeattributes3 = _slim_codeattributes3.flatten
2127
- _slim_codeattributes3.map!(&:to_s)
2128
- _slim_codeattributes3.reject!(&:empty?)
2129
- _temple_html_attributeremover2 << ((_slim_codeattributes3.join(" ")).to_s)
2130
- else
2131
- _temple_html_attributeremover2 << ((_slim_codeattributes3).to_s)
2132
- end
2133
- _temple_html_attributeremover2
2134
- if !_temple_html_attributeremover2.empty?
2135
- _slim_controls2 << (" class=\"".freeze)
2136
- _slim_controls2 << ((_temple_html_attributeremover2).to_s)
2137
- _slim_controls2 << ("\"".freeze)
2138
- end
2139
- _slim_codeattributes4 = source_lang
2140
- if _slim_codeattributes4
2141
- if _slim_codeattributes4 == true
2142
- _slim_controls2 << (" data-lang".freeze)
2143
- else
2144
- _slim_controls2 << (" data-lang=\"".freeze)
2145
- _slim_controls2 << ((_slim_codeattributes4).to_s)
2146
- _slim_controls2 << ("\"".freeze)
2147
- end
2148
- end
2149
- _slim_controls2 << (">".freeze)
2150
- _slim_controls2 << ((content).to_s)
2151
- _slim_controls2 << ("</code></pre>".freeze)
2152
- end
2153
- else
2154
- _slim_controls2 << ("<pre".freeze)
2155
- _temple_html_attributeremover3 = ''
2156
- _slim_codeattributes5 = nowrap?
2157
- if Array === _slim_codeattributes5
2158
- _slim_codeattributes5 = _slim_codeattributes5.flatten
2159
- _slim_codeattributes5.map!(&:to_s)
2160
- _slim_codeattributes5.reject!(&:empty?)
2161
- _temple_html_attributeremover3 << ((_slim_codeattributes5.join(" ")).to_s)
2162
- else
2163
- _temple_html_attributeremover3 << ((_slim_codeattributes5).to_s)
2164
- end
2165
- _temple_html_attributeremover3
2166
- if !_temple_html_attributeremover3.empty?
2167
- _slim_controls2 << (" class=\"".freeze)
2168
- _slim_controls2 << ((_temple_html_attributeremover3).to_s)
2169
- _slim_controls2 << ("\"".freeze)
2170
- end
2171
- _slim_controls2 << (">".freeze)
2172
- _slim_controls2 << ((content).to_s)
2173
- _slim_controls2 << ("</pre>".freeze)
2174
- end
2175
- if callout_list
2176
- _slim_controls2 << ((converter.convert callout_list, 'colist').to_s)
2177
- end
2178
- _slim_controls2
2179
- end
2180
- _buf << ((_slim_controls1).to_s)
2181
- _buf
1125
+ _buf = []; _slim_controls1 = block_with_caption :top, :class=>'listing-block' do; _slim_controls2 = [];
1126
+ ; if style == 'source';
1127
+ ; if highlighter == 'html-pipeline';
1128
+ ; _slim_controls2 << ("<pre><code"); _slim_codeattributes1 = source_lang; if _slim_codeattributes1; if _slim_codeattributes1 == true; _slim_controls2 << (" data-lang"); else; _slim_controls2 << (" data-lang=\""); _slim_controls2 << (_slim_codeattributes1); _slim_controls2 << ("\""); end; end; _slim_controls2 << (">"); _slim_controls2 << (content);
1129
+ ; _slim_controls2 << ("</code></pre>"); else;
1130
+ ; unless highlighter == 'CodeRay';
1131
+ ; code_class = "language-#{source_lang}" if source_lang;
1132
+ ; end; _slim_controls2 << ("<pre"); _temple_html_attributeremover1 = []; _slim_codeattributes2 = [highlighter, 'highlight', ('linenums' if attr? :linenums), nowrap?]; if Array === _slim_codeattributes2; _slim_codeattributes2 = _slim_codeattributes2.flatten; _slim_codeattributes2.map!(&:to_s); _slim_codeattributes2.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes2.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes2); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _slim_controls2 << (" class=\""); _slim_controls2 << (_temple_html_attributeremover1); _slim_controls2 << ("\""); end; _slim_controls2 << ("><code");
1133
+ ; _temple_html_attributeremover2 = []; _slim_codeattributes3 = code_class; if Array === _slim_codeattributes3; _slim_codeattributes3 = _slim_codeattributes3.flatten; _slim_codeattributes3.map!(&:to_s); _slim_codeattributes3.reject!(&:empty?); _temple_html_attributeremover2 << (_slim_codeattributes3.join(" ")); else; _temple_html_attributeremover2 << (_slim_codeattributes3); end; _temple_html_attributeremover2 = _temple_html_attributeremover2.join(""); if !_temple_html_attributeremover2.empty?; _slim_controls2 << (" class=\""); _slim_controls2 << (_temple_html_attributeremover2); _slim_controls2 << ("\""); end; _slim_codeattributes4 = source_lang; if _slim_codeattributes4; if _slim_codeattributes4 == true; _slim_controls2 << (" data-lang"); else; _slim_controls2 << (" data-lang=\""); _slim_controls2 << (_slim_codeattributes4); _slim_controls2 << ("\""); end; end; _slim_controls2 << (">"); _slim_controls2 << (content);
1134
+ ; _slim_controls2 << ("</code></pre>"); end; else;
1135
+ ; _slim_controls2 << ("<pre"); _temple_html_attributeremover3 = []; _slim_codeattributes5 = nowrap?; if Array === _slim_codeattributes5; _slim_codeattributes5 = _slim_codeattributes5.flatten; _slim_codeattributes5.map!(&:to_s); _slim_codeattributes5.reject!(&:empty?); _temple_html_attributeremover3 << (_slim_codeattributes5.join(" ")); else; _temple_html_attributeremover3 << (_slim_codeattributes5); end; _temple_html_attributeremover3 = _temple_html_attributeremover3.join(""); if !_temple_html_attributeremover3.empty?; _slim_controls2 << (" class=\""); _slim_controls2 << (_temple_html_attributeremover3); _slim_controls2 << ("\""); end; _slim_controls2 << (">"); _slim_controls2 << (content);
1136
+ ; _slim_controls2 << ("</pre>");
1137
+ ;
1138
+ ; end; if callout_list;
1139
+ ; _slim_controls2 << (converter.convert callout_list, 'colist');
1140
+ ; end; _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
2182
1141
  end
2183
1142
  end
2184
1143
 
@@ -2186,33 +1145,9 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2186
1145
  node.extend(Helpers)
2187
1146
  node.instance_eval do
2188
1147
  converter.set_local_variables(binding, opts) unless opts.empty?
2189
- _buf = ''
2190
- _slim_controls1 = block_with_title :class=>'literal-block' do
2191
- _slim_controls2 = ''
2192
- _slim_controls2 << ("<pre".freeze)
2193
- _temple_html_attributeremover1 = ''
2194
- _slim_codeattributes1 = nowrap?
2195
- if Array === _slim_codeattributes1
2196
- _slim_codeattributes1 = _slim_codeattributes1.flatten
2197
- _slim_codeattributes1.map!(&:to_s)
2198
- _slim_codeattributes1.reject!(&:empty?)
2199
- _temple_html_attributeremover1 << ((_slim_codeattributes1.join(" ")).to_s)
2200
- else
2201
- _temple_html_attributeremover1 << ((_slim_codeattributes1).to_s)
2202
- end
2203
- _temple_html_attributeremover1
2204
- if !_temple_html_attributeremover1.empty?
2205
- _slim_controls2 << (" class=\"".freeze)
2206
- _slim_controls2 << ((_temple_html_attributeremover1).to_s)
2207
- _slim_controls2 << ("\"".freeze)
2208
- end
2209
- _slim_controls2 << (">".freeze)
2210
- _slim_controls2 << ((content).to_s)
2211
- _slim_controls2 << ("</pre>".freeze)
2212
- _slim_controls2
2213
- end
2214
- _buf << ((_slim_controls1).to_s)
2215
- _buf
1148
+ _buf = []; _slim_controls1 = block_with_title :class=>'literal-block' do; _slim_controls2 = [];
1149
+ ; _slim_controls2 << ("<pre"); _temple_html_attributeremover1 = []; _slim_codeattributes1 = nowrap?; if Array === _slim_codeattributes1; _slim_codeattributes1 = _slim_codeattributes1.flatten; _slim_codeattributes1.map!(&:to_s); _slim_codeattributes1.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes1.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes1); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _slim_controls2 << (" class=\""); _slim_controls2 << (_temple_html_attributeremover1); _slim_controls2 << ("\""); end; _slim_controls2 << (">"); _slim_controls2 << (content);
1150
+ ; _slim_controls2 << ("</pre>"); _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
2216
1151
  end
2217
1152
  end
2218
1153
 
@@ -2220,67 +1155,11 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2220
1155
  node.extend(Helpers)
2221
1156
  node.instance_eval do
2222
1157
  converter.set_local_variables(binding, opts) unless opts.empty?
2223
- _buf = ''
2224
- _slim_controls1 = block_with_title :class=>['olist', style] do
2225
- _slim_controls2 = ''
2226
- _slim_controls2 << ("<ol".freeze)
2227
- _temple_html_attributeremover1 = ''
2228
- _slim_codeattributes1 = style
2229
- if Array === _slim_codeattributes1
2230
- _slim_codeattributes1 = _slim_codeattributes1.flatten
2231
- _slim_codeattributes1.map!(&:to_s)
2232
- _slim_codeattributes1.reject!(&:empty?)
2233
- _temple_html_attributeremover1 << ((_slim_codeattributes1.join(" ")).to_s)
2234
- else
2235
- _temple_html_attributeremover1 << ((_slim_codeattributes1).to_s)
2236
- end
2237
- _temple_html_attributeremover1
2238
- if !_temple_html_attributeremover1.empty?
2239
- _slim_controls2 << (" class=\"".freeze)
2240
- _slim_controls2 << ((_temple_html_attributeremover1).to_s)
2241
- _slim_controls2 << ("\"".freeze)
2242
- end
2243
- _slim_codeattributes2 = (attr :start)
2244
- if _slim_codeattributes2
2245
- if _slim_codeattributes2 == true
2246
- _slim_controls2 << (" start".freeze)
2247
- else
2248
- _slim_controls2 << (" start=\"".freeze)
2249
- _slim_controls2 << ((_slim_codeattributes2).to_s)
2250
- _slim_controls2 << ("\"".freeze)
2251
- end
2252
- end
2253
- _slim_codeattributes3 = list_marker_keyword
2254
- if _slim_codeattributes3
2255
- if _slim_codeattributes3 == true
2256
- _slim_controls2 << (" type".freeze)
2257
- else
2258
- _slim_controls2 << (" type=\"".freeze)
2259
- _slim_controls2 << ((_slim_codeattributes3).to_s)
2260
- _slim_controls2 << ("\"".freeze)
2261
- end
2262
- end
2263
- _slim_codeattributes4 = (option? 'reversed')
2264
- if _slim_codeattributes4
2265
- if _slim_codeattributes4 == true
2266
- _slim_controls2 << (" reversed".freeze)
2267
- else
2268
- _slim_controls2 << (" reversed=\"".freeze)
2269
- _slim_controls2 << ((_slim_codeattributes4).to_s)
2270
- _slim_controls2 << ("\"".freeze)
2271
- end
2272
- end
2273
- _slim_controls2 << (">".freeze)
2274
- items.each do |item|
2275
- _slim_controls2 << ("<li>".freeze)
2276
- _slim_controls2 << (((print_item_content item)).to_s)
2277
- _slim_controls2 << ("</li>".freeze)
2278
- end
2279
- _slim_controls2 << ("</ol>".freeze)
2280
- _slim_controls2
2281
- end
2282
- _buf << ((_slim_controls1).to_s)
2283
- _buf
1158
+ _buf = []; _slim_controls1 = block_with_title :class=>['olist', style] do; _slim_controls2 = [];
1159
+ ; _slim_controls2 << ("<ol"); _temple_html_attributeremover1 = []; _slim_codeattributes1 = style; if Array === _slim_codeattributes1; _slim_codeattributes1 = _slim_codeattributes1.flatten; _slim_codeattributes1.map!(&:to_s); _slim_codeattributes1.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes1.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes1); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _slim_controls2 << (" class=\""); _slim_controls2 << (_temple_html_attributeremover1); _slim_controls2 << ("\""); end; _slim_codeattributes2 = (attr :start); if _slim_codeattributes2; if _slim_codeattributes2 == true; _slim_controls2 << (" start"); else; _slim_controls2 << (" start=\""); _slim_controls2 << (_slim_codeattributes2); _slim_controls2 << ("\""); end; end; _slim_codeattributes3 = list_marker_keyword; if _slim_codeattributes3; if _slim_codeattributes3 == true; _slim_controls2 << (" type"); else; _slim_controls2 << (" type=\""); _slim_controls2 << (_slim_codeattributes3); _slim_controls2 << ("\""); end; end; _slim_codeattributes4 = (option? 'reversed'); if _slim_codeattributes4; if _slim_codeattributes4 == true; _slim_controls2 << (" reversed"); else; _slim_controls2 << (" reversed=\""); _slim_controls2 << (_slim_codeattributes4); _slim_controls2 << ("\""); end; end; _slim_controls2 << (">");
1160
+ ; items.each do |item|;
1161
+ ; _slim_controls2 << ("<li>"); _slim_controls2 << ((print_item_content item));
1162
+ ; _slim_controls2 << ("</li>"); end; _slim_controls2 << ("</ol>"); _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
2284
1163
  end
2285
1164
  end
2286
1165
 
@@ -2288,29 +1167,14 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2288
1167
  node.extend(Helpers)
2289
1168
  node.instance_eval do
2290
1169
  converter.set_local_variables(binding, opts) unless opts.empty?
2291
- _buf = ''
2292
- if style == 'abstract'
2293
- if abstract_allowed?
2294
- _slim_controls1 = block_with_title :class=>'quote-block abstract' do
2295
- _slim_controls2 = ''
2296
- _slim_controls2 << ("<blockquote>".freeze)
2297
- _slim_controls2 << ((content).to_s)
2298
- _slim_controls2 << ("</blockquote>".freeze)
2299
- _slim_controls2
2300
- end
2301
- _buf << ((_slim_controls1).to_s)
2302
- end
2303
- elsif style != 'partintro' || partintro_allowed?
2304
- _slim_controls3 = block_with_title :class=>['open-block', (style if style != 'open')] do
2305
- _slim_controls4 = ''
2306
- _slim_controls4 << ("<div class=\"content\">".freeze)
2307
- _slim_controls4 << ((content).to_s)
2308
- _slim_controls4 << ("</div>".freeze)
2309
- _slim_controls4
2310
- end
2311
- _buf << ((_slim_controls3).to_s)
2312
- end
2313
- _buf
1170
+ _buf = []; if style == 'abstract';
1171
+ ; if abstract_allowed?;
1172
+ ; _slim_controls1 = block_with_title :class=>'quote-block abstract' do; _slim_controls2 = [];
1173
+ ; _slim_controls2 << ("<blockquote>"); _slim_controls2 << (content);
1174
+ ; _slim_controls2 << ("</blockquote>"); _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); end; elsif style != 'partintro' || partintro_allowed?;
1175
+ ; _slim_controls3 = block_with_title :class=>['open-block', (style if style != 'open')] do; _slim_controls4 = [];
1176
+ ; _slim_controls4 << ("<div class=\"content\">"); _slim_controls4 << (content);
1177
+ ; _slim_controls4 << ("</div>"); _slim_controls4 = _slim_controls4.join(""); end; _buf << (_slim_controls3); end; _buf = _buf.join("")
2314
1178
  end
2315
1179
  end
2316
1180
 
@@ -2318,27 +1182,16 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2318
1182
  node.extend(Helpers)
2319
1183
  node.instance_eval do
2320
1184
  converter.set_local_variables(binding, opts) unless opts.empty?
2321
- _buf = ''
2322
- unless sections.empty?
2323
- toclevels ||= (document.attr 'toclevels', DEFAULT_TOCLEVELS).to_i
2324
- slevel = section_level sections.first
2325
- _buf << ("<ol class=\"toc-list level-".freeze)
2326
- _buf << ((slevel).to_s)
2327
- _buf << ("\">".freeze)
2328
- sections.each do |sec|
2329
- _buf << ("<li><a href=\"#".freeze)
2330
- _buf << ((sec.id).to_s)
2331
- _buf << ("\">".freeze)
2332
- _buf << ((section_title sec).to_s)
2333
- _buf << ("</a>".freeze)
2334
- if (sec.level < toclevels) && (child_toc = converter.convert sec, 'outline')
2335
- _buf << ((child_toc).to_s)
2336
- end
2337
- _buf << ("</li>".freeze)
2338
- end
2339
- _buf << ("</ol>".freeze)
2340
- end
2341
- _buf
1185
+ _buf = []; unless sections.empty?;
1186
+ ; toclevels ||= (document.attr 'toclevels', DEFAULT_TOCLEVELS).to_i;
1187
+ ; slevel = section_level sections.first;
1188
+ ; _buf << ("<ol class=\"toc-list level-"); _buf << (slevel); _buf << ("\">");
1189
+ ; sections.each do |sec|;
1190
+ ; _buf << ("<li><a href=\"#");
1191
+ ; _buf << (sec.id); _buf << ("\">"); _buf << (section_title sec);
1192
+ ; _buf << ("</a>"); if (sec.level < toclevels) && (child_toc = converter.convert sec, 'outline');
1193
+ ; _buf << (child_toc);
1194
+ ; end; _buf << ("</li>"); end; _buf << ("</ol>"); end; _buf = _buf.join("")
2342
1195
  end
2343
1196
  end
2344
1197
 
@@ -2346,9 +1199,8 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2346
1199
  node.extend(Helpers)
2347
1200
  node.instance_eval do
2348
1201
  converter.set_local_variables(binding, opts) unless opts.empty?
2349
- _buf = ''
2350
- _buf << ("<div role=\"doc-pagebreak\" style=\"page-break-after: always;\"></div>".freeze)
2351
- _buf
1202
+ _buf = []; _buf << ("<div role=\"doc-pagebreak\" style=\"page-break-after: always;\"></div>");
1203
+ ; _buf = _buf.join("")
2352
1204
  end
2353
1205
  end
2354
1206
 
@@ -2356,74 +1208,13 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2356
1208
  node.extend(Helpers)
2357
1209
  node.instance_eval do
2358
1210
  converter.set_local_variables(binding, opts) unless opts.empty?
2359
- _buf = ''
2360
- if title?
2361
- _buf << ("<section class=\"paragraph\"".freeze)
2362
- _slim_codeattributes1 = id
2363
- if _slim_codeattributes1
2364
- if _slim_codeattributes1 == true
2365
- _buf << (" id".freeze)
2366
- else
2367
- _buf << (" id=\"".freeze)
2368
- _buf << ((_slim_codeattributes1).to_s)
2369
- _buf << ("\"".freeze)
2370
- end
2371
- end
2372
- _buf << ("><h6 class=\"block-title\">".freeze)
2373
- _buf << ((title).to_s)
2374
- _buf << ("</h6><p".freeze)
2375
- _temple_html_attributeremover1 = ''
2376
- _slim_codeattributes2 = role
2377
- if Array === _slim_codeattributes2
2378
- _slim_codeattributes2 = _slim_codeattributes2.flatten
2379
- _slim_codeattributes2.map!(&:to_s)
2380
- _slim_codeattributes2.reject!(&:empty?)
2381
- _temple_html_attributeremover1 << ((_slim_codeattributes2.join(" ")).to_s)
2382
- else
2383
- _temple_html_attributeremover1 << ((_slim_codeattributes2).to_s)
2384
- end
2385
- _temple_html_attributeremover1
2386
- if !_temple_html_attributeremover1.empty?
2387
- _buf << (" class=\"".freeze)
2388
- _buf << ((_temple_html_attributeremover1).to_s)
2389
- _buf << ("\"".freeze)
2390
- end
2391
- _buf << (">".freeze)
2392
- _buf << ((content).to_s)
2393
- _buf << ("</p></section>".freeze)
2394
- else
2395
- _buf << ("<p".freeze)
2396
- _slim_codeattributes3 = id
2397
- if _slim_codeattributes3
2398
- if _slim_codeattributes3 == true
2399
- _buf << (" id".freeze)
2400
- else
2401
- _buf << (" id=\"".freeze)
2402
- _buf << ((_slim_codeattributes3).to_s)
2403
- _buf << ("\"".freeze)
2404
- end
2405
- end
2406
- _temple_html_attributeremover2 = ''
2407
- _slim_codeattributes4 = role
2408
- if Array === _slim_codeattributes4
2409
- _slim_codeattributes4 = _slim_codeattributes4.flatten
2410
- _slim_codeattributes4.map!(&:to_s)
2411
- _slim_codeattributes4.reject!(&:empty?)
2412
- _temple_html_attributeremover2 << ((_slim_codeattributes4.join(" ")).to_s)
2413
- else
2414
- _temple_html_attributeremover2 << ((_slim_codeattributes4).to_s)
2415
- end
2416
- _temple_html_attributeremover2
2417
- if !_temple_html_attributeremover2.empty?
2418
- _buf << (" class=\"".freeze)
2419
- _buf << ((_temple_html_attributeremover2).to_s)
2420
- _buf << ("\"".freeze)
2421
- end
2422
- _buf << (">".freeze)
2423
- _buf << ((content).to_s)
2424
- _buf << ("</p>".freeze)
2425
- end
2426
- _buf
1211
+ _buf = []; if title?;
1212
+ ; _buf << ("<section class=\"paragraph\""); _slim_codeattributes1 = id; if _slim_codeattributes1; if _slim_codeattributes1 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes1); _buf << ("\""); end; end; _buf << ("><h6 class=\"block-title\">");
1213
+ ; _buf << (title);
1214
+ ; _buf << ("</h6><p"); _temple_html_attributeremover1 = []; _slim_codeattributes2 = role; if Array === _slim_codeattributes2; _slim_codeattributes2 = _slim_codeattributes2.flatten; _slim_codeattributes2.map!(&:to_s); _slim_codeattributes2.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes2.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes2); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover1); _buf << ("\""); end; _buf << (">"); _buf << (content);
1215
+ ; _buf << ("</p></section>"); else;
1216
+ ; _buf << ("<p"); _slim_codeattributes3 = id; if _slim_codeattributes3; if _slim_codeattributes3 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes3); _buf << ("\""); end; end; _temple_html_attributeremover2 = []; _slim_codeattributes4 = role; if Array === _slim_codeattributes4; _slim_codeattributes4 = _slim_codeattributes4.flatten; _slim_codeattributes4.map!(&:to_s); _slim_codeattributes4.reject!(&:empty?); _temple_html_attributeremover2 << (_slim_codeattributes4.join(" ")); else; _temple_html_attributeremover2 << (_slim_codeattributes4); end; _temple_html_attributeremover2 = _temple_html_attributeremover2.join(""); if !_temple_html_attributeremover2.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover2); _buf << ("\""); end; _buf << (">"); _buf << (content);
1217
+ ; _buf << ("</p>"); end; _buf = _buf.join("")
2427
1218
  end
2428
1219
  end
2429
1220
 
@@ -2431,9 +1222,8 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2431
1222
  node.extend(Helpers)
2432
1223
  node.instance_eval do
2433
1224
  converter.set_local_variables(binding, opts) unless opts.empty?
2434
- _buf = ''
2435
- _buf << ((content).to_s)
2436
- _buf
1225
+ _buf = []; _buf << (content);
1226
+ ; _buf = _buf.join("")
2437
1227
  end
2438
1228
  end
2439
1229
 
@@ -2441,35 +1231,15 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2441
1231
  node.extend(Helpers)
2442
1232
  node.instance_eval do
2443
1233
  converter.set_local_variables(binding, opts) unless opts.empty?
2444
- _buf = ''
2445
- _buf << ("<section id=\"preamble\" aria-label=\"Preamble\">".freeze)
2446
- _buf << ((content).to_s)
2447
- _buf << ("</section>".freeze)
2448
- if (attr? :toc) && (attr? 'toc-placement', 'preamble')
2449
- _buf << ("<nav id=\"toc\"".freeze)
2450
- _temple_html_attributeremover1 = ''
2451
- _slim_codeattributes1 = (attr 'toc-class', 'toc')
2452
- if Array === _slim_codeattributes1
2453
- _slim_codeattributes1 = _slim_codeattributes1.flatten
2454
- _slim_codeattributes1.map!(&:to_s)
2455
- _slim_codeattributes1.reject!(&:empty?)
2456
- _temple_html_attributeremover1 << ((_slim_codeattributes1.join(" ")).to_s)
2457
- else
2458
- _temple_html_attributeremover1 << ((_slim_codeattributes1).to_s)
2459
- end
2460
- _temple_html_attributeremover1
2461
- if !_temple_html_attributeremover1.empty?
2462
- _buf << (" class=\"".freeze)
2463
- _buf << ((_temple_html_attributeremover1).to_s)
2464
- _buf << ("\"".freeze)
2465
- end
2466
- _buf << (" role=\"doc-toc\"><h2 id=\"toc-title\">".freeze)
2467
- _buf << (((attr 'toc-title')).to_s)
2468
- _buf << ("</h2>".freeze)
2469
- _buf << ((converter.convert document, 'outline').to_s)
2470
- _buf << ("</nav>".freeze)
2471
- end
2472
- _buf
1234
+ _buf = []; _buf << ("<section id=\"preamble\" aria-label=\"Preamble\">");
1235
+ ; _buf << (content);
1236
+ ; _buf << ("</section>"); if (attr? :toc) && (attr? 'toc-placement', 'preamble');
1237
+ ; _buf << ("<nav id=\"toc\""); _temple_html_attributeremover1 = []; _slim_codeattributes1 = (attr 'toc-class', 'toc'); if Array === _slim_codeattributes1; _slim_codeattributes1 = _slim_codeattributes1.flatten; _slim_codeattributes1.map!(&:to_s); _slim_codeattributes1.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes1.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes1); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover1); _buf << ("\""); end; _buf << (" role=\"doc-toc\"><h2 id=\"toc-title\">");
1238
+ ; _buf << ((attr 'toc-title'));
1239
+ ; _buf << ("</h2>");
1240
+ ; _buf << (converter.convert document, 'outline');
1241
+ ; _buf << ("</nav>");
1242
+ ; end; _buf = _buf.join("")
2473
1243
  end
2474
1244
  end
2475
1245
 
@@ -2477,26 +1247,17 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2477
1247
  node.extend(Helpers)
2478
1248
  node.instance_eval do
2479
1249
  converter.set_local_variables(binding, opts) unless opts.empty?
2480
- _buf = ''
2481
- _slim_controls1 = block_with_title :class=>'quote-block' do
2482
- _slim_controls2 = ''
2483
- _slim_controls2 << ("<blockquote>".freeze)
2484
- _slim_controls3 = html_tag_if !blocks?, :p do
2485
- _slim_controls4 = ''
2486
- _slim_controls4 << ((content).to_s)
2487
- _slim_controls4
2488
- end
2489
- _slim_controls2 << ((_slim_controls3).to_s)
2490
- if attr?(:attribution) || attr?(:citetitle)
2491
- _slim_controls2 << ("<footer>&#8212; <cite>".freeze)
2492
- _slim_controls2 << (([(attr :attribution), (attr :citetitle)].compact.join(', ')).to_s)
2493
- _slim_controls2 << ("</cite></footer>".freeze)
2494
- end
2495
- _slim_controls2 << ("</blockquote>".freeze)
2496
- _slim_controls2
2497
- end
2498
- _buf << ((_slim_controls1).to_s)
2499
- _buf
1250
+ _buf = []; _slim_controls1 = block_with_title :class=>'quote-block' do; _slim_controls2 = [];
1251
+ ; _slim_controls2 << ("<blockquote>");
1252
+ ; _slim_controls3 = html_tag_if !blocks?, :p do; _slim_controls4 = [];
1253
+ ; _slim_controls4 << (content);
1254
+ ; _slim_controls4 = _slim_controls4.join(""); end; _slim_controls2 << (_slim_controls3); if attr?(:attribution) || attr?(:citetitle);
1255
+ ; _slim_controls2 << ("<footer>&#8212; <cite>");
1256
+ ;
1257
+ ;
1258
+ ; _slim_controls2 << ([(attr :attribution), (attr :citetitle)].compact.join(', '));
1259
+ ; _slim_controls2 << ("</cite></footer>");
1260
+ ; end; _slim_controls2 << ("</blockquote>"); _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
2500
1261
  end
2501
1262
  end
2502
1263
 
@@ -2504,68 +1265,19 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2504
1265
  node.extend(Helpers)
2505
1266
  node.instance_eval do
2506
1267
  converter.set_local_variables(binding, opts) unless opts.empty?
2507
- _buf = ''
2508
- _buf << ("<section".freeze)
2509
- _temple_html_attributeremover1 = ''
2510
- _temple_html_attributemerger1 = []
2511
- _temple_html_attributemerger1[0] = "doc-section"
2512
- _temple_html_attributemerger1[1] = ''
2513
- _slim_codeattributes1 = ["level-#{section_level}", role]
2514
- if Array === _slim_codeattributes1
2515
- _slim_codeattributes1 = _slim_codeattributes1.flatten
2516
- _slim_codeattributes1.map!(&:to_s)
2517
- _slim_codeattributes1.reject!(&:empty?)
2518
- _temple_html_attributemerger1[1] << ((_slim_codeattributes1.join(" ")).to_s)
2519
- else
2520
- _temple_html_attributemerger1[1] << ((_slim_codeattributes1).to_s)
2521
- end
2522
- _temple_html_attributemerger1[1]
2523
- _temple_html_attributeremover1 << ((_temple_html_attributemerger1.reject(&:empty?).join(" ")).to_s)
2524
- _temple_html_attributeremover1
2525
- if !_temple_html_attributeremover1.empty?
2526
- _buf << (" class=\"".freeze)
2527
- _buf << ((_temple_html_attributeremover1).to_s)
2528
- _buf << ("\"".freeze)
2529
- end
2530
- _buf << (">".freeze)
2531
- _slim_htag_filter1 = ((section_level + 1)).to_s
2532
- _buf << ("<h".freeze)
2533
- _buf << ((_slim_htag_filter1).to_s)
2534
- _slim_codeattributes2 = id
2535
- if _slim_codeattributes2
2536
- if _slim_codeattributes2 == true
2537
- _buf << (" id".freeze)
2538
- else
2539
- _buf << (" id=\"".freeze)
2540
- _buf << ((_slim_codeattributes2).to_s)
2541
- _buf << ("\"".freeze)
2542
- end
2543
- end
2544
- _buf << (">".freeze)
2545
- if id
2546
- if document.attr? :sectanchors
2547
- _buf << ("<a class=\"anchor\" href=\"#".freeze)
2548
- _buf << ((id).to_s)
2549
- _buf << ("\" aria-hidden=\"true\"></a>".freeze)
2550
- end
2551
- if document.attr? :sectlinks
2552
- _buf << ("<a class=\"link\" href=\"#".freeze)
2553
- _buf << ((id).to_s)
2554
- _buf << ("\">".freeze)
2555
- _buf << ((section_title).to_s)
2556
- _buf << ("</a>".freeze)
2557
- else
2558
- _buf << ((section_title).to_s)
2559
- end
2560
- else
2561
- _buf << ((section_title).to_s)
2562
- end
2563
- _buf << ("</h".freeze)
2564
- _buf << ((_slim_htag_filter1).to_s)
2565
- _buf << (">".freeze)
2566
- _buf << ((content).to_s)
2567
- _buf << ("</section>".freeze)
2568
- _buf
1268
+ _buf = []; _buf << ("<section"); _temple_html_attributeremover1 = []; _temple_html_attributemerger1 = []; _temple_html_attributemerger1[0] = "doc-section"; _temple_html_attributemerger1[1] = []; _slim_codeattributes1 = ["level-#{section_level}", role]; if Array === _slim_codeattributes1; _slim_codeattributes1 = _slim_codeattributes1.flatten; _slim_codeattributes1.map!(&:to_s); _slim_codeattributes1.reject!(&:empty?); _temple_html_attributemerger1[1] << (_slim_codeattributes1.join(" ")); else; _temple_html_attributemerger1[1] << (_slim_codeattributes1); end; _temple_html_attributemerger1[1] = _temple_html_attributemerger1[1].join(""); _temple_html_attributeremover1 << (_temple_html_attributemerger1.reject(&:empty?).join(" ")); _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover1); _buf << ("\""); end; _buf << (">");
1269
+ ; _slim_htag_filter1 = ((section_level + 1)).to_s; _buf << ("<h"); _buf << (_slim_htag_filter1); _slim_codeattributes2 = id; if _slim_codeattributes2; if _slim_codeattributes2 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes2); _buf << ("\""); end; end; _buf << (">");
1270
+ ; if id;
1271
+ ; if document.attr? :sectanchors;
1272
+ ; _buf << ("<a class=\"anchor\" href=\"#"); _buf << (id); _buf << ("\" aria-hidden=\"true\"></a>");
1273
+ ; end; if document.attr? :sectlinks;
1274
+ ; _buf << ("<a class=\"link\" href=\"#"); _buf << (id); _buf << ("\">"); _buf << (section_title);
1275
+ ; _buf << ("</a>"); else;
1276
+ ; _buf << (section_title);
1277
+ ; end; else;
1278
+ ; _buf << (section_title);
1279
+ ; end; _buf << ("</h"); _buf << (_slim_htag_filter1); _buf << (">"); _buf << (content);
1280
+ ; _buf << ("</section>"); _buf = _buf.join("")
2569
1281
  end
2570
1282
  end
2571
1283
 
@@ -2573,48 +1285,11 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2573
1285
  node.extend(Helpers)
2574
1286
  node.instance_eval do
2575
1287
  converter.set_local_variables(binding, opts) unless opts.empty?
2576
- _buf = ''
2577
- _buf << ("<aside".freeze)
2578
- _temple_html_attributeremover1 = ''
2579
- _temple_html_attributemerger1 = []
2580
- _temple_html_attributemerger1[0] = "sidebar"
2581
- _temple_html_attributemerger1[1] = ''
2582
- _slim_codeattributes1 = role
2583
- if Array === _slim_codeattributes1
2584
- _slim_codeattributes1 = _slim_codeattributes1.flatten
2585
- _slim_codeattributes1.map!(&:to_s)
2586
- _slim_codeattributes1.reject!(&:empty?)
2587
- _temple_html_attributemerger1[1] << ((_slim_codeattributes1.join(" ")).to_s)
2588
- else
2589
- _temple_html_attributemerger1[1] << ((_slim_codeattributes1).to_s)
2590
- end
2591
- _temple_html_attributemerger1[1]
2592
- _temple_html_attributeremover1 << ((_temple_html_attributemerger1.reject(&:empty?).join(" ")).to_s)
2593
- _temple_html_attributeremover1
2594
- if !_temple_html_attributeremover1.empty?
2595
- _buf << (" class=\"".freeze)
2596
- _buf << ((_temple_html_attributeremover1).to_s)
2597
- _buf << ("\"".freeze)
2598
- end
2599
- _slim_codeattributes2 = id
2600
- if _slim_codeattributes2
2601
- if _slim_codeattributes2 == true
2602
- _buf << (" id".freeze)
2603
- else
2604
- _buf << (" id=\"".freeze)
2605
- _buf << ((_slim_codeattributes2).to_s)
2606
- _buf << ("\"".freeze)
2607
- end
2608
- end
2609
- _buf << (">".freeze)
2610
- if title?
2611
- _buf << ("<h6 class=\"block-title\">".freeze)
2612
- _buf << ((title).to_s)
2613
- _buf << ("</h6>".freeze)
2614
- end
2615
- _buf << ((content).to_s)
2616
- _buf << ("</aside>".freeze)
2617
- _buf
1288
+ _buf = []; _buf << ("<aside"); _temple_html_attributeremover1 = []; _temple_html_attributemerger1 = []; _temple_html_attributemerger1[0] = "sidebar"; _temple_html_attributemerger1[1] = []; _slim_codeattributes1 = role; if Array === _slim_codeattributes1; _slim_codeattributes1 = _slim_codeattributes1.flatten; _slim_codeattributes1.map!(&:to_s); _slim_codeattributes1.reject!(&:empty?); _temple_html_attributemerger1[1] << (_slim_codeattributes1.join(" ")); else; _temple_html_attributemerger1[1] << (_slim_codeattributes1); end; _temple_html_attributemerger1[1] = _temple_html_attributemerger1[1].join(""); _temple_html_attributeremover1 << (_temple_html_attributemerger1.reject(&:empty?).join(" ")); _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover1); _buf << ("\""); end; _slim_codeattributes2 = id; if _slim_codeattributes2; if _slim_codeattributes2 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes2); _buf << ("\""); end; end; _buf << (">");
1289
+ ; if title?;
1290
+ ; _buf << ("<h6 class=\"block-title\">"); _buf << (title);
1291
+ ; _buf << ("</h6>"); end; _buf << (content);
1292
+ ; _buf << ("</aside>"); _buf = _buf.join("")
2618
1293
  end
2619
1294
  end
2620
1295
 
@@ -2622,16 +1297,9 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2622
1297
  node.extend(Helpers)
2623
1298
  node.instance_eval do
2624
1299
  converter.set_local_variables(binding, opts) unless opts.empty?
2625
- _buf = ''
2626
- _slim_controls1 = block_with_caption :top, :class=>'stem-block' do
2627
- _slim_controls2 = ''
2628
- _slim_controls2 << ("<div class=\"math\">".freeze)
2629
- _slim_controls2 << (((delimit_stem content, style)).to_s)
2630
- _slim_controls2 << ("</div>".freeze)
2631
- _slim_controls2
2632
- end
2633
- _buf << ((_slim_controls1).to_s)
2634
- _buf
1300
+ _buf = []; _slim_controls1 = block_with_caption :top, :class=>'stem-block' do; _slim_controls2 = [];
1301
+ ; _slim_controls2 << ("<div class=\"math\""); _slim_codeattributes1 = stem_lang; if _slim_codeattributes1; if _slim_codeattributes1 == true; _slim_controls2 << (" data-lang"); else; _slim_controls2 << (" data-lang=\""); _slim_controls2 << (_slim_codeattributes1); _slim_controls2 << ("\""); end; end; _slim_controls2 << (">"); _slim_controls2 << ((delimit_stem content, style));
1302
+ ; _slim_controls2 << ("</div>"); _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
2635
1303
  end
2636
1304
  end
2637
1305
 
@@ -2639,104 +1307,46 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2639
1307
  node.extend(Helpers)
2640
1308
  node.instance_eval do
2641
1309
  converter.set_local_variables(binding, opts) unless opts.empty?
2642
- _buf = ''
2643
- _slim_controls1 = block_with_caption :top, :class=>'table-block' do
2644
- _slim_controls2 = ''
2645
- _slim_controls2 << ("<table".freeze)
2646
- _temple_html_attributeremover1 = ''
2647
- _slim_codeattributes1 = ["frame-#{attr :frame, 'all'}", "grid-#{attr :grid, 'all'}", spread?]
2648
- if Array === _slim_codeattributes1
2649
- _slim_codeattributes1 = _slim_codeattributes1.flatten
2650
- _slim_codeattributes1.map!(&:to_s)
2651
- _slim_codeattributes1.reject!(&:empty?)
2652
- _temple_html_attributeremover1 << ((_slim_codeattributes1.join(" ")).to_s)
2653
- else
2654
- _temple_html_attributeremover1 << ((_slim_codeattributes1).to_s)
2655
- end
2656
- _temple_html_attributeremover1
2657
- if !_temple_html_attributeremover1.empty?
2658
- _slim_controls2 << (" class=\"".freeze)
2659
- _slim_controls2 << ((_temple_html_attributeremover1).to_s)
2660
- _slim_controls2 << ("\"".freeze)
2661
- end
2662
- _slim_codeattributes2 = style_value(width: ("#{attr :tablepcwidth}%" if !autowidth? && !spread? || (local_attr :width)),
2663
- float: (attr :float))
2664
- if _slim_codeattributes2
2665
- if _slim_codeattributes2 == true
2666
- _slim_controls2 << (" style".freeze)
2667
- else
2668
- _slim_controls2 << (" style=\"".freeze)
2669
- _slim_controls2 << ((_slim_codeattributes2).to_s)
2670
- _slim_controls2 << ("\"".freeze)
2671
- end
2672
- end
2673
- _slim_controls2 << (">".freeze)
2674
- unless (attr :rowcount).zero?
2675
- _slim_controls2 << ("<colgroup>".freeze)
2676
- if autowidth?
2677
- columns.each do
2678
- _slim_controls2 << ("<col>".freeze)
2679
- end
2680
- else
2681
- columns.each do |col|
2682
- _slim_controls2 << ("<col style=\"width: ".freeze)
2683
- _slim_controls2 << ((col.attr :colpcwidth).to_s)
2684
- _slim_controls2 << ("%;\">".freeze)
2685
- end
2686
- end
2687
- _slim_controls2 << ("</colgroup>".freeze)
2688
- [:head, :foot, :body].reject { |tblsec| rows[tblsec].empty? }.each do |tblsec|
2689
- _slim_controls2 << ("<t".freeze)
2690
- _slim_controls2 << ((tblsec).to_s)
2691
- _slim_controls2 << (">".freeze)
2692
- rows[tblsec].each do |row|
2693
- _slim_controls2 << ("<tr>".freeze)
2694
- row.each do |cell|
2695
- _slim_controls3 = html_tag(tblsec == :head || cell.style == :header ? 'th' : 'td',
2696
- :class=>["halign-#{cell.attr :halign}", "valign-#{cell.attr :valign}"],
2697
- :colspan=>cell.colspan,
2698
- :rowspan=>cell.rowspan,
2699
- :style=>style_value(background_color: (document.attr :cellbgcolor))) do
2700
- _slim_controls4 = ''
2701
- if tblsec == :head
2702
- _slim_controls4 << ((cell.text).to_s)
2703
- else
2704
- case cell.style
2705
- when :asciidoc
2706
- _slim_controls4 << ((cell.content).to_s)
2707
- when :verse
2708
- _slim_controls4 << ("<div class=\"verse\"><pre>".freeze)
2709
- _slim_controls4 << ((cell.text).to_s)
2710
- _slim_controls4 << ("</pre></div>".freeze)
2711
- when :literal
2712
- _slim_controls4 << ("<div class=\"literal\"><pre>".freeze)
2713
- _slim_controls4 << ((cell.text).to_s)
2714
- _slim_controls4 << ("</pre></div>".freeze)
2715
- else
2716
- if cell.content.one?
2717
- _slim_controls4 << ((cell.content.first).to_s)
2718
- else
2719
- cell.content.each do |text|
2720
- _slim_controls4 << ("<p>".freeze)
2721
- _slim_controls4 << ((text).to_s)
2722
- _slim_controls4 << ("</p>".freeze)
2723
- end
2724
- end
2725
- end
2726
- end
2727
- _slim_controls4
2728
- end
2729
- _slim_controls2 << ((_slim_controls3).to_s)
2730
- end
2731
- _slim_controls2 << ("</tr>".freeze)
2732
- end
2733
- end
2734
- end
2735
- _slim_controls2 << ("</table>".freeze)
2736
- _slim_controls2
2737
- end
2738
- _buf << ((_slim_controls1).to_s)
2739
- _buf
1310
+ _buf = []; _slim_controls1 = block_with_caption :top, :class=>'table-block' do; _slim_controls2 = [];
1311
+ ;
1312
+ ;
1313
+ ; _slim_controls2 << ("<table"); _temple_html_attributeremover1 = []; _slim_codeattributes1 = ["frame-#{attr :frame, 'all'}", "grid-#{attr :grid, 'all'}", spread?]; if Array === _slim_codeattributes1; _slim_codeattributes1 = _slim_codeattributes1.flatten; _slim_codeattributes1.map!(&:to_s); _slim_codeattributes1.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes1.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes1); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _slim_controls2 << (" class=\""); _slim_controls2 << (_temple_html_attributeremover1); _slim_controls2 << ("\""); end; _slim_codeattributes2 = style_value(width: ("#{attr :tablepcwidth}%" if !autowidth? && !spread? || (local_attr :width)),
1314
+ float: (attr :float)); if _slim_codeattributes2; if _slim_codeattributes2 == true; _slim_controls2 << (" style"); else; _slim_controls2 << (" style=\""); _slim_controls2 << (_slim_codeattributes2); _slim_controls2 << ("\""); end; end; _slim_controls2 << (">");
1315
+ ; unless (attr :rowcount).zero?;
1316
+ ; _slim_controls2 << ("<colgroup>");
1317
+ ; if autowidth?;
1318
+ ; columns.each do;
1319
+ ; _slim_controls2 << ("<col>");
1320
+ ; end; else;
1321
+ ; columns.each do |col|;
1322
+ ; _slim_controls2 << ("<col style=\"width: "); _slim_controls2 << (col.attr :colpcwidth); _slim_controls2 << ("%;\">");
1323
+ ; end; end; _slim_controls2 << ("</colgroup>"); [:head, :foot, :body].reject { |tblsec| rows[tblsec].empty? }.each do |tblsec|;
1324
+ ; _slim_controls2 << ("<t"); _slim_controls2 << (tblsec); _slim_controls2 << (">");
1325
+ ; rows[tblsec].each do |row|;
1326
+ ; _slim_controls2 << ("<tr>");
1327
+ ; row.each do |cell|;
1328
+ ; _slim_controls3 = html_tag(tblsec == :head || cell.style == :header ? 'th' : 'td',
1329
+ :class=>["halign-#{cell.attr :halign}", "valign-#{cell.attr :valign}"],
1330
+ :colspan=>cell.colspan,
1331
+ :rowspan=>cell.rowspan,
1332
+ :style=>style_value(background_color: (document.attr :cellbgcolor))) do; _slim_controls4 = [];
1333
+ ; if tblsec == :head;
1334
+ ; _slim_controls4 << (cell.text);
1335
+ ; else;
1336
+ ; case cell.style;
1337
+ ; when :asciidoc;
1338
+ ; _slim_controls4 << (cell.content);
1339
+ ; when :verse;
1340
+ ; _slim_controls4 << ("<div class=\"verse\"><pre>"); _slim_controls4 << (cell.text);
1341
+ ; _slim_controls4 << ("</pre></div>"); when :literal;
1342
+ ; _slim_controls4 << ("<div class=\"literal\"><pre>"); _slim_controls4 << (cell.text);
1343
+ ; _slim_controls4 << ("</pre></div>"); else;
1344
+ ; if cell.content.one?;
1345
+ ; _slim_controls4 << (cell.content.first);
1346
+ ; else;
1347
+ ; cell.content.each do |text|;
1348
+ ; _slim_controls4 << ("<p>"); _slim_controls4 << (text);
1349
+ ; _slim_controls4 << ("</p>"); end; end; end; end; _slim_controls4 = _slim_controls4.join(""); end; _slim_controls2 << (_slim_controls3); end; _slim_controls2 << ("</tr>"); end; end; end; _slim_controls2 << ("</table>"); _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
2740
1350
  end
2741
1351
  end
2742
1352
 
@@ -2744,9 +1354,8 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2744
1354
  node.extend(Helpers)
2745
1355
  node.instance_eval do
2746
1356
  converter.set_local_variables(binding, opts) unless opts.empty?
2747
- _buf = ''
2748
- _buf << ("<hr>".freeze)
2749
- _buf
1357
+ _buf = []; _buf << ("<hr>");
1358
+ ; _buf = _buf.join("")
2750
1359
  end
2751
1360
  end
2752
1361
 
@@ -2754,61 +1363,18 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2754
1363
  node.extend(Helpers)
2755
1364
  node.instance_eval do
2756
1365
  converter.set_local_variables(binding, opts) unless opts.empty?
2757
- _buf = ''
2758
- if document.attr?(:toc) && document.sections?
2759
- toc_id = id || ('toc' if document.embedded? || !document.attr?('toc-placement'))
2760
- _buf << ("<nav".freeze)
2761
- _slim_codeattributes1 = toc_id
2762
- if _slim_codeattributes1
2763
- if _slim_codeattributes1 == true
2764
- _buf << (" id".freeze)
2765
- else
2766
- _buf << (" id=\"".freeze)
2767
- _buf << ((_slim_codeattributes1).to_s)
2768
- _buf << ("\"".freeze)
2769
- end
2770
- end
2771
- _temple_html_attributeremover1 = ''
2772
- _slim_codeattributes2 = (attr :role, (document.attr 'toc-class', 'toc'))
2773
- if Array === _slim_codeattributes2
2774
- _slim_codeattributes2 = _slim_codeattributes2.flatten
2775
- _slim_codeattributes2.map!(&:to_s)
2776
- _slim_codeattributes2.reject!(&:empty?)
2777
- _temple_html_attributeremover1 << ((_slim_codeattributes2.join(" ")).to_s)
2778
- else
2779
- _temple_html_attributeremover1 << ((_slim_codeattributes2).to_s)
2780
- end
2781
- _temple_html_attributeremover1
2782
- if !_temple_html_attributeremover1.empty?
2783
- _buf << (" class=\"".freeze)
2784
- _buf << ((_temple_html_attributeremover1).to_s)
2785
- _buf << ("\"".freeze)
2786
- end
2787
- _buf << (" role=\"doc-toc\">".freeze)
2788
- _slim_htag_filter1 = ((level + 2)).to_s
2789
- _buf << ("<h".freeze)
2790
- _buf << ((_slim_htag_filter1).to_s)
2791
- _slim_codeattributes3 = ("#{toc_id}-title" if toc_id)
2792
- if _slim_codeattributes3
2793
- if _slim_codeattributes3 == true
2794
- _buf << (" id".freeze)
2795
- else
2796
- _buf << (" id=\"".freeze)
2797
- _buf << ((_slim_codeattributes3).to_s)
2798
- _buf << ("\"".freeze)
2799
- end
2800
- end
2801
- _buf << (">".freeze)
2802
- _buf << (((title || (document.attr 'toc-title'))).to_s)
2803
- _buf << ("</h".freeze)
2804
- _buf << ((_slim_htag_filter1).to_s)
2805
- _buf << (">".freeze)
2806
- _buf << ((converter.convert document, 'outline', :toclevels=>((attr :levels).to_i if attr? :levels)).to_s)
2807
- _buf << ("</nav>".freeze)
2808
- else
2809
- _buf << ("<!--toc disabled-->".freeze)
2810
- end
2811
- _buf
1366
+ _buf = [];
1367
+ ;
1368
+ ; if document.attr?(:toc) && document.sections?;
1369
+ ; toc_id = id || ('toc' if document.embedded? || !document.attr?('toc-placement'));
1370
+ ; _buf << ("<nav"); _slim_codeattributes1 = toc_id; if _slim_codeattributes1; if _slim_codeattributes1 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes1); _buf << ("\""); end; end; _temple_html_attributeremover1 = []; _slim_codeattributes2 = (attr :role, (document.attr 'toc-class', 'toc')); if Array === _slim_codeattributes2; _slim_codeattributes2 = _slim_codeattributes2.flatten; _slim_codeattributes2.map!(&:to_s); _slim_codeattributes2.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes2.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes2); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _buf << (" class=\""); _buf << (_temple_html_attributeremover1); _buf << ("\""); end; _buf << (" role=\"doc-toc\">");
1371
+ ; _slim_htag_filter1 = ((level + 2)).to_s; _buf << ("<h"); _buf << (_slim_htag_filter1); _slim_codeattributes3 = ("#{toc_id}-title" if toc_id); if _slim_codeattributes3; if _slim_codeattributes3 == true; _buf << (" id"); else; _buf << (" id=\""); _buf << (_slim_codeattributes3); _buf << ("\""); end; end; _buf << (">");
1372
+ ; _buf << ((title || (document.attr 'toc-title')));
1373
+ ; _buf << ("</h"); _buf << (_slim_htag_filter1); _buf << (">");
1374
+ ; _buf << (converter.convert document, 'outline', :toclevels=>((attr :levels).to_i if attr? :levels));
1375
+ ; _buf << ("</nav>"); else;
1376
+ ; _buf << ("<!--toc disabled-->");
1377
+ ; end; _buf = _buf.join("")
2812
1378
  end
2813
1379
  end
2814
1380
 
@@ -2816,55 +1382,18 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2816
1382
  node.extend(Helpers)
2817
1383
  node.instance_eval do
2818
1384
  converter.set_local_variables(binding, opts) unless opts.empty?
2819
- _buf = ''
2820
- checklist = 'task-list' if option? 'checklist'
2821
- _slim_controls1 = block_with_title :class=>['ulist', style] do
2822
- _slim_controls2 = ''
2823
- _slim_controls2 << ("<ul".freeze)
2824
- _temple_html_attributeremover1 = ''
2825
- _slim_codeattributes1 = (checklist || style)
2826
- if Array === _slim_codeattributes1
2827
- _slim_codeattributes1 = _slim_codeattributes1.flatten
2828
- _slim_codeattributes1.map!(&:to_s)
2829
- _slim_codeattributes1.reject!(&:empty?)
2830
- _temple_html_attributeremover1 << ((_slim_codeattributes1.join(" ")).to_s)
2831
- else
2832
- _temple_html_attributeremover1 << ((_slim_codeattributes1).to_s)
2833
- end
2834
- _temple_html_attributeremover1
2835
- if !_temple_html_attributeremover1.empty?
2836
- _slim_controls2 << (" class=\"".freeze)
2837
- _slim_controls2 << ((_temple_html_attributeremover1).to_s)
2838
- _slim_controls2 << ("\"".freeze)
2839
- end
2840
- _slim_controls2 << (">".freeze)
2841
- items.each do |item|
2842
- if checklist && (item.attr? :checkbox)
2843
- _slim_controls2 << ("<li class=\"task-list-item\"><input class=\"task-list-item-checkbox\" type=\"checkbox\" disabled".freeze)
2844
- _slim_codeattributes2 = (item.attr? :checked)
2845
- if _slim_codeattributes2
2846
- if _slim_codeattributes2 == true
2847
- _slim_controls2 << (" checked".freeze)
2848
- else
2849
- _slim_controls2 << (" checked=\"".freeze)
2850
- _slim_controls2 << ((_slim_codeattributes2).to_s)
2851
- _slim_controls2 << ("\"".freeze)
2852
- end
2853
- end
2854
- _slim_controls2 << ("> ".freeze)
2855
- _slim_controls2 << ((item.text).to_s)
2856
- _slim_controls2 << ("</li>".freeze)
2857
- else
2858
- _slim_controls2 << ("<li>".freeze)
2859
- _slim_controls2 << (((print_item_content item)).to_s)
2860
- _slim_controls2 << ("</li>".freeze)
2861
- end
2862
- end
2863
- _slim_controls2 << ("</ul>".freeze)
2864
- _slim_controls2
2865
- end
2866
- _buf << ((_slim_controls1).to_s)
2867
- _buf
1385
+ _buf = []; checklist = 'task-list' if option? 'checklist';
1386
+ ; _slim_controls1 = block_with_title :class=>['ulist', style] do; _slim_controls2 = [];
1387
+ ; _slim_controls2 << ("<ul"); _temple_html_attributeremover1 = []; _slim_codeattributes1 = (checklist || style); if Array === _slim_codeattributes1; _slim_codeattributes1 = _slim_codeattributes1.flatten; _slim_codeattributes1.map!(&:to_s); _slim_codeattributes1.reject!(&:empty?); _temple_html_attributeremover1 << (_slim_codeattributes1.join(" ")); else; _temple_html_attributeremover1 << (_slim_codeattributes1); end; _temple_html_attributeremover1 = _temple_html_attributeremover1.join(""); if !_temple_html_attributeremover1.empty?; _slim_controls2 << (" class=\""); _slim_controls2 << (_temple_html_attributeremover1); _slim_controls2 << ("\""); end; _slim_controls2 << (">");
1388
+ ; items.each do |item|;
1389
+ ; if checklist && (item.attr? :checkbox);
1390
+ ; _slim_controls2 << ("<li class=\"task-list-item\"><input class=\"task-list-item-checkbox\" type=\"checkbox\" disabled");
1391
+ ; _slim_codeattributes2 = (item.attr? :checked); if _slim_codeattributes2; if _slim_codeattributes2 == true; _slim_controls2 << (" checked"); else; _slim_controls2 << (" checked=\""); _slim_controls2 << (_slim_codeattributes2); _slim_controls2 << ("\""); end; end; _slim_controls2 << ("> ");
1392
+ ; _slim_controls2 << (item.text);
1393
+ ; _slim_controls2 << ("</li>"); else;
1394
+ ; _slim_controls2 << ("<li>");
1395
+ ; _slim_controls2 << ((print_item_content item));
1396
+ ; _slim_controls2 << ("</li>"); end; end; _slim_controls2 << ("</ul>"); _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
2868
1397
  end
2869
1398
  end
2870
1399
 
@@ -2872,24 +1401,18 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2872
1401
  node.extend(Helpers)
2873
1402
  node.instance_eval do
2874
1403
  converter.set_local_variables(binding, opts) unless opts.empty?
2875
- _buf = ''
2876
- _slim_controls1 = block_with_title :class=>'verse-block' do
2877
- _slim_controls2 = ''
2878
- if attr?(:attribution) || attr?(:citetitle)
2879
- _slim_controls2 << ("<blockquote class=\"verse\"><pre class=\"verse\">".freeze)
2880
- _slim_controls2 << ((content).to_s)
2881
- _slim_controls2 << ("</pre><footer>&#8212; <cite>".freeze)
2882
- _slim_controls2 << (([(attr :attribution), (attr :citetitle)].compact.join(', ')).to_s)
2883
- _slim_controls2 << ("</cite></footer></blockquote>".freeze)
2884
- else
2885
- _slim_controls2 << ("<pre class=\"verse\">".freeze)
2886
- _slim_controls2 << ((content).to_s)
2887
- _slim_controls2 << ("</pre>".freeze)
2888
- end
2889
- _slim_controls2
2890
- end
2891
- _buf << ((_slim_controls1).to_s)
2892
- _buf
1404
+ _buf = []; _slim_controls1 = block_with_title :class=>'verse-block' do; _slim_controls2 = [];
1405
+ ; if attr?(:attribution) || attr?(:citetitle);
1406
+ ; _slim_controls2 << ("<blockquote class=\"verse\"><pre class=\"verse\">");
1407
+ ; _slim_controls2 << (content);
1408
+ ; _slim_controls2 << ("</pre><footer>&#8212; <cite>");
1409
+ ;
1410
+ ;
1411
+ ; _slim_controls2 << ([(attr :attribution), (attr :citetitle)].compact.join(', '));
1412
+ ; _slim_controls2 << ("</cite></footer></blockquote>");
1413
+ ; else;
1414
+ ; _slim_controls2 << ("<pre class=\"verse\">"); _slim_controls2 << (content);
1415
+ ; _slim_controls2 << ("</pre>"); end; _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
2893
1416
  end
2894
1417
  end
2895
1418
 
@@ -2897,140 +1420,25 @@ class Asciidoctor::Html5s::Converter < ::Asciidoctor::Converter::Base
2897
1420
  node.extend(Helpers)
2898
1421
  node.instance_eval do
2899
1422
  converter.set_local_variables(binding, opts) unless opts.empty?
2900
- _buf = ''
2901
- _slim_controls1 = block_with_caption :bottom, :class=>'video-block' do
2902
- _slim_controls2 = ''
2903
- if video_iframe?
2904
- _slim_controls2 << ("<iframe".freeze)
2905
- _slim_codeattributes1 = video_uri
2906
- if _slim_codeattributes1
2907
- if _slim_codeattributes1 == true
2908
- _slim_controls2 << (" src".freeze)
2909
- else
2910
- _slim_controls2 << (" src=\"".freeze)
2911
- _slim_controls2 << ((_slim_codeattributes1).to_s)
2912
- _slim_controls2 << ("\"".freeze)
2913
- end
2914
- end
2915
- _slim_codeattributes2 = (attr :width)
2916
- if _slim_codeattributes2
2917
- if _slim_codeattributes2 == true
2918
- _slim_controls2 << (" width".freeze)
2919
- else
2920
- _slim_controls2 << (" width=\"".freeze)
2921
- _slim_controls2 << ((_slim_codeattributes2).to_s)
2922
- _slim_controls2 << ("\"".freeze)
2923
- end
2924
- end
2925
- _slim_codeattributes3 = (attr :height)
2926
- if _slim_codeattributes3
2927
- if _slim_codeattributes3 == true
2928
- _slim_controls2 << (" height".freeze)
2929
- else
2930
- _slim_controls2 << (" height=\"".freeze)
2931
- _slim_controls2 << ((_slim_codeattributes3).to_s)
2932
- _slim_controls2 << ("\"".freeze)
2933
- end
2934
- end
2935
- _slim_codeattributes4 = 0
2936
- if _slim_codeattributes4
2937
- if _slim_codeattributes4 == true
2938
- _slim_controls2 << (" frameborder".freeze)
2939
- else
2940
- _slim_controls2 << (" frameborder=\"".freeze)
2941
- _slim_controls2 << ((_slim_codeattributes4).to_s)
2942
- _slim_controls2 << ("\"".freeze)
2943
- end
2944
- end
2945
- _slim_codeattributes5 = !(option? 'nofullscreen')
2946
- if _slim_codeattributes5
2947
- if _slim_codeattributes5 == true
2948
- _slim_controls2 << (" allowfullscreen".freeze)
2949
- else
2950
- _slim_controls2 << (" allowfullscreen=\"".freeze)
2951
- _slim_controls2 << ((_slim_codeattributes5).to_s)
2952
- _slim_controls2 << ("\"".freeze)
2953
- end
2954
- end
2955
- _slim_controls2 << ("></iframe>".freeze)
2956
- else
2957
- _slim_controls2 << ("<video".freeze)
2958
- _slim_codeattributes6 = video_uri
2959
- if _slim_codeattributes6
2960
- if _slim_codeattributes6 == true
2961
- _slim_controls2 << (" src".freeze)
2962
- else
2963
- _slim_controls2 << (" src=\"".freeze)
2964
- _slim_controls2 << ((_slim_codeattributes6).to_s)
2965
- _slim_controls2 << ("\"".freeze)
2966
- end
2967
- end
2968
- _slim_codeattributes7 = (attr :width)
2969
- if _slim_codeattributes7
2970
- if _slim_codeattributes7 == true
2971
- _slim_controls2 << (" width".freeze)
2972
- else
2973
- _slim_controls2 << (" width=\"".freeze)
2974
- _slim_controls2 << ((_slim_codeattributes7).to_s)
2975
- _slim_controls2 << ("\"".freeze)
2976
- end
2977
- end
2978
- _slim_codeattributes8 = (attr :height)
2979
- if _slim_codeattributes8
2980
- if _slim_codeattributes8 == true
2981
- _slim_controls2 << (" height".freeze)
2982
- else
2983
- _slim_controls2 << (" height=\"".freeze)
2984
- _slim_controls2 << ((_slim_codeattributes8).to_s)
2985
- _slim_controls2 << ("\"".freeze)
2986
- end
2987
- end
2988
- _slim_codeattributes9 = (media_uri(attr :poster) if attr? :poster)
2989
- if _slim_codeattributes9
2990
- if _slim_codeattributes9 == true
2991
- _slim_controls2 << (" poster".freeze)
2992
- else
2993
- _slim_controls2 << (" poster=\"".freeze)
2994
- _slim_controls2 << ((_slim_codeattributes9).to_s)
2995
- _slim_controls2 << ("\"".freeze)
2996
- end
2997
- end
2998
- _slim_codeattributes10 = (option? 'autoplay')
2999
- if _slim_codeattributes10
3000
- if _slim_codeattributes10 == true
3001
- _slim_controls2 << (" autoplay".freeze)
3002
- else
3003
- _slim_controls2 << (" autoplay=\"".freeze)
3004
- _slim_controls2 << ((_slim_codeattributes10).to_s)
3005
- _slim_controls2 << ("\"".freeze)
3006
- end
3007
- end
3008
- _slim_codeattributes11 = !(option? 'nocontrols')
3009
- if _slim_codeattributes11
3010
- if _slim_codeattributes11 == true
3011
- _slim_controls2 << (" controls".freeze)
3012
- else
3013
- _slim_controls2 << (" controls=\"".freeze)
3014
- _slim_controls2 << ((_slim_codeattributes11).to_s)
3015
- _slim_controls2 << ("\"".freeze)
3016
- end
3017
- end
3018
- _slim_codeattributes12 = (option? 'loop')
3019
- if _slim_codeattributes12
3020
- if _slim_codeattributes12 == true
3021
- _slim_controls2 << (" loop".freeze)
3022
- else
3023
- _slim_controls2 << (" loop=\"".freeze)
3024
- _slim_controls2 << ((_slim_codeattributes12).to_s)
3025
- _slim_controls2 << ("\"".freeze)
3026
- end
3027
- end
3028
- _slim_controls2 << (">Your browser does not support the video tag.</video>".freeze)
3029
- end
3030
- _slim_controls2
3031
- end
3032
- _buf << ((_slim_controls1).to_s)
3033
- _buf
1423
+ _buf = []; _slim_controls1 = block_with_caption :bottom, :class=>'video-block' do; _slim_controls2 = [];
1424
+ ; if video_iframe?;
1425
+ ;
1426
+ ;
1427
+ ;
1428
+ ;
1429
+ ;
1430
+ ; _slim_controls2 << ("<iframe"); _slim_codeattributes1 = video_uri; if _slim_codeattributes1; if _slim_codeattributes1 == true; _slim_controls2 << (" src"); else; _slim_controls2 << (" src=\""); _slim_controls2 << (_slim_codeattributes1); _slim_controls2 << ("\""); end; end; _slim_codeattributes2 = (attr :width); if _slim_codeattributes2; if _slim_codeattributes2 == true; _slim_controls2 << (" width"); else; _slim_controls2 << (" width=\""); _slim_controls2 << (_slim_codeattributes2); _slim_controls2 << ("\""); end; end; _slim_codeattributes3 = (attr :height); if _slim_codeattributes3; if _slim_codeattributes3 == true; _slim_controls2 << (" height"); else; _slim_controls2 << (" height=\""); _slim_controls2 << (_slim_codeattributes3); _slim_controls2 << ("\""); end; end; _slim_codeattributes4 = 0; if _slim_codeattributes4; if _slim_codeattributes4 == true; _slim_controls2 << (" frameborder"); else; _slim_controls2 << (" frameborder=\""); _slim_controls2 << (_slim_codeattributes4); _slim_controls2 << ("\""); end; end; _slim_codeattributes5 = !(option? 'nofullscreen'); if _slim_codeattributes5; if _slim_codeattributes5 == true; _slim_controls2 << (" allowfullscreen"); else; _slim_controls2 << (" allowfullscreen=\""); _slim_controls2 << (_slim_codeattributes5); _slim_controls2 << ("\""); end; end; _slim_controls2 << ("></iframe>");
1431
+ ; else;
1432
+ ;
1433
+ ;
1434
+ ;
1435
+ ;
1436
+ ;
1437
+ ;
1438
+ ;
1439
+ ; _slim_controls2 << ("<video"); _slim_codeattributes6 = video_uri; if _slim_codeattributes6; if _slim_codeattributes6 == true; _slim_controls2 << (" src"); else; _slim_controls2 << (" src=\""); _slim_controls2 << (_slim_codeattributes6); _slim_controls2 << ("\""); end; end; _slim_codeattributes7 = (attr :width); if _slim_codeattributes7; if _slim_codeattributes7 == true; _slim_controls2 << (" width"); else; _slim_controls2 << (" width=\""); _slim_controls2 << (_slim_codeattributes7); _slim_controls2 << ("\""); end; end; _slim_codeattributes8 = (attr :height); if _slim_codeattributes8; if _slim_codeattributes8 == true; _slim_controls2 << (" height"); else; _slim_controls2 << (" height=\""); _slim_controls2 << (_slim_codeattributes8); _slim_controls2 << ("\""); end; end; _slim_codeattributes9 = (media_uri(attr :poster) if attr? :poster); if _slim_codeattributes9; if _slim_codeattributes9 == true; _slim_controls2 << (" poster"); else; _slim_controls2 << (" poster=\""); _slim_controls2 << (_slim_codeattributes9); _slim_controls2 << ("\""); end; end; _slim_codeattributes10 = (option? 'autoplay'); if _slim_codeattributes10; if _slim_codeattributes10 == true; _slim_controls2 << (" autoplay"); else; _slim_controls2 << (" autoplay=\""); _slim_controls2 << (_slim_codeattributes10); _slim_controls2 << ("\""); end; end; _slim_codeattributes11 = !(option? 'nocontrols'); if _slim_codeattributes11; if _slim_codeattributes11 == true; _slim_controls2 << (" controls"); else; _slim_controls2 << (" controls=\""); _slim_controls2 << (_slim_codeattributes11); _slim_controls2 << ("\""); end; end; _slim_codeattributes12 = (option? 'loop'); if _slim_codeattributes12; if _slim_codeattributes12 == true; _slim_controls2 << (" loop"); else; _slim_controls2 << (" loop=\""); _slim_controls2 << (_slim_codeattributes12); _slim_controls2 << ("\""); end; end; _slim_controls2 << (">Your browser does not support the video tag.</video>");
1440
+ ;
1441
+ ; end; _slim_controls2 = _slim_controls2.join(""); end; _buf << (_slim_controls1); _buf = _buf.join("")
3034
1442
  end
3035
1443
  end
3036
1444
  #------------------ End of generated transformation methods ------------------#