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