asciidoctor-diagram 2.2.13 → 2.2.14
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/CHANGELOG.adoc +6 -0
- data/lib/asciidoctor-diagram/blockdiag/converter.rb +7 -1
- data/lib/asciidoctor-diagram/diagram_source.rb +4 -0
- data/lib/asciidoctor-diagram/meme/converter.rb +3 -3
- data/lib/asciidoctor-diagram/structurizr/renderers.rb +1 -1
- data/lib/asciidoctor-diagram/version.rb +1 -1
- data/lib/asciidoctor-diagram/wavedrom/converter.rb +2 -2
- 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: c2447be8f4a47717d6ef4856ed210cbf44eaa09cd0ae154bb64119f3e309384d
|
4
|
+
data.tar.gz: 8e40700cddd6d026c7ae4cd7cfafdf22704e01b4941eba2d274db91e103d700e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2e4c640aaa5ce31f00f94a10398d9ab9a29eca0a97359073645a82cd777ec860ad2a90ebc5ed549e65186a88d3e1c43a9f39250c1d2b6ba2745f31d4b3dd3679
|
7
|
+
data.tar.gz: 9f54def1db4fd022b510a46daf33328b4854fb0d1dd7d3ba4bbc5a5dc1c966e4a37f548fdaa82c626024fdb31bdbf62218e1edbb1e8bdf1a7bf43fbf10116567
|
data/CHANGELOG.adoc
CHANGED
@@ -13,13 +13,19 @@ module Asciidoctor
|
|
13
13
|
[:png, :pdf, :svg]
|
14
14
|
end
|
15
15
|
|
16
|
+
def collect_options(source)
|
17
|
+
{
|
18
|
+
:font_path => source.attr('fontpath')
|
19
|
+
}
|
20
|
+
end
|
21
|
+
|
16
22
|
def convert(source, format, options)
|
17
23
|
# On Debian based systems the Python 3.x packages python3-(act|block|nw|seq)diag executables with
|
18
24
|
# a '3' suffix.
|
19
25
|
cmd_name = self.class.const_get(:TOOL)
|
20
26
|
alt_cmd_name = "#{cmd_name}3"
|
21
27
|
|
22
|
-
font_path =
|
28
|
+
font_path = options[:font_path]
|
23
29
|
|
24
30
|
generate_stdin(source.find_command(cmd_name, :alt_cmds => [alt_cmd_name]), format.to_s, source.to_s) do |tool_path, output_path|
|
25
31
|
args = [tool_path, '-a', '-o', Platform.native_path(output_path), "-T#{format.to_s}"]
|
@@ -34,6 +34,10 @@ module Asciidoctor
|
|
34
34
|
attr(name) || attr(name, default_value, 'diagram')
|
35
35
|
end
|
36
36
|
|
37
|
+
def opt(opt)
|
38
|
+
attr("#{opt}-option")
|
39
|
+
end
|
40
|
+
|
37
41
|
# Get the value for the specified attribute. First look in the attributes on
|
38
42
|
# this document and return the value of the attribute if found. Otherwise, if
|
39
43
|
# this document is a child of the Document document, look in the attributes of the
|
@@ -19,7 +19,6 @@ module Asciidoctor
|
|
19
19
|
bg_img = source.attr('background')
|
20
20
|
raise "background attribute is required" unless bg_img
|
21
21
|
|
22
|
-
options = source.attr('options', '').split(',')
|
23
22
|
margin = source.attr('margin', '')
|
24
23
|
margin_parts = margin.split(' ')
|
25
24
|
case margin_parts.length
|
@@ -55,7 +54,8 @@ module Asciidoctor
|
|
55
54
|
:margin_right => mr,
|
56
55
|
:margin_top => mt,
|
57
56
|
:margin_bottom => mb,
|
58
|
-
:noupcase =>
|
57
|
+
:noupcase => source.opt('noupcase'),
|
58
|
+
:imagesdir => source.attr('imagesdir')
|
59
59
|
}
|
60
60
|
end
|
61
61
|
|
@@ -74,7 +74,7 @@ module Asciidoctor
|
|
74
74
|
bg_img = options[:bg_img]
|
75
75
|
raise "background attribute is required" unless bg_img
|
76
76
|
|
77
|
-
bg_img = source.resolve_path(bg_img,
|
77
|
+
bg_img = source.resolve_path(bg_img, options[:imagesdir])
|
78
78
|
|
79
79
|
top_label = options[:top_label]
|
80
80
|
bottom_label = options[:bottom_label]
|
@@ -18,9 +18,9 @@ module Asciidoctor
|
|
18
18
|
def convert(source, format, options)
|
19
19
|
wavedrom_cli = source.find_command('wavedrom-cli', :raise_on_error => false)
|
20
20
|
if wavedrom_cli
|
21
|
-
|
21
|
+
generate_file(wavedrom_cli, 'wvd', format.to_s, source.to_s) do |tool_path, input_path, output_path|
|
22
22
|
{
|
23
|
-
:args => [Platform.native_path(tool_path), '--input',
|
23
|
+
:args => [Platform.native_path(tool_path), '--input', Platform.native_path(input_path), "--#{format.to_s}", Platform.native_path(output_path)],
|
24
24
|
:chdir => source.base_dir
|
25
25
|
}
|
26
26
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: asciidoctor-diagram
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.2.
|
4
|
+
version: 2.2.14
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Pepijn Van Eeckhoudt
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-09-
|
11
|
+
date: 2023-09-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|