vivlio_pack 0.2.1 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/vivlio_pack/generator.rb +2 -2
- data/lib/vivlio_pack/renderer.rb +3 -3
- data/lib/vivlio_pack/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: d710919b947c8a40694024f7170b42ec4f0590fefaa68084214eebf6e9173fad
|
|
4
|
+
data.tar.gz: 44aac280241a598ee9576bd2a98ba8b3bb90f0fa9065b0893b6e72f71107353e
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 27d8e6c6774b8cd908c93b3d940e0646f4eb23063b3b0083e85dfab7e3a125bf8ce490bf81222ef2afc6dbd170814ca13827f19848e7512869ceb4901644cf5f
|
|
7
|
+
data.tar.gz: a5770a3189f171bf8143067bd090d4ad1fd7a458ab3b55a45c65152927325d9ea57c2d3346e4233e20d0829a587017386c7b90e2f798b1339a3d2cbe9001cfb9
|
|
@@ -12,7 +12,7 @@ module VivlioPack
|
|
|
12
12
|
if File.exist?("#{@workdir}/plugin.rb")
|
|
13
13
|
load "#{@workdir}/plugin.rb"
|
|
14
14
|
end
|
|
15
|
-
@markdown = Redcarpet::Markdown.new(Renderer, autolink: true, tables: true, fenced_code_blocks: true)
|
|
15
|
+
@markdown = Redcarpet::Markdown.new(Renderer, autolink: true, tables: true, fenced_code_blocks: true, no_intra_emphasis: true)
|
|
16
16
|
end
|
|
17
17
|
|
|
18
18
|
def generate(html_path)
|
|
@@ -25,6 +25,7 @@ module VivlioPack
|
|
|
25
25
|
<meta charset="utf-8">
|
|
26
26
|
<link rel="stylesheet" type="text/css" href="contents/css/style.css">
|
|
27
27
|
<link rel="stylesheet" type="text/css" href="contents/css/bw.css">
|
|
28
|
+
<link rel="stylesheet" type="text/css" href="contents/css/custom.css">
|
|
28
29
|
<link href="https://fonts.googleapis.com/css?family=M+PLUS+Rounded+1c" rel="stylesheet">
|
|
29
30
|
</head>
|
|
30
31
|
<body>
|
|
@@ -35,7 +36,6 @@ module VivlioPack
|
|
|
35
36
|
<h1>目次</h1>
|
|
36
37
|
#{TocRenderer.render(file_paths)}
|
|
37
38
|
</div>
|
|
38
|
-
<div class="page-break"></div>
|
|
39
39
|
HTML
|
|
40
40
|
|
|
41
41
|
file_paths.each do |path|
|
data/lib/vivlio_pack/renderer.rb
CHANGED
|
@@ -56,15 +56,15 @@ module VivlioPack
|
|
|
56
56
|
return "<div class='page-break'></div>\n"
|
|
57
57
|
when /\A%([a-z][a-z0-9\-]*):(.*)/m
|
|
58
58
|
return "<div class='#{$1}'>#{$2}</div>\n"
|
|
59
|
-
when /\A\[begin
|
|
59
|
+
when /\A\[begin\s+(\w+)(\s+(.+))?\]\z/
|
|
60
60
|
plugin_name = $~[1]
|
|
61
61
|
plugin = Renderer.plugin(plugin_name)
|
|
62
62
|
if plugin
|
|
63
63
|
@state.push plugin_name
|
|
64
|
-
result = plugin.process_begin
|
|
64
|
+
result = plugin.process_begin($~[3])
|
|
65
65
|
return result if result
|
|
66
66
|
end
|
|
67
|
-
when /\A\[end
|
|
67
|
+
when /\A\[end\s+(\w+)\]\z/
|
|
68
68
|
plugin_name = $~[1]
|
|
69
69
|
plugin = Renderer.plugin(plugin_name)
|
|
70
70
|
if plugin
|
data/lib/vivlio_pack/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: vivlio_pack
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.3.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- youchan
|
|
@@ -110,7 +110,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
110
110
|
- !ruby/object:Gem::Version
|
|
111
111
|
version: '0'
|
|
112
112
|
requirements: []
|
|
113
|
-
rubygems_version: 4.0.
|
|
113
|
+
rubygems_version: 4.0.6
|
|
114
114
|
specification_version: 4
|
|
115
115
|
summary: Create books with vivliostyle.
|
|
116
116
|
test_files: []
|