jekyll-drawio 0.0.5 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6fbe444671f6cfd66efe7239cede4745a9b444ef7b03425ff24283d198dbb34a
4
- data.tar.gz: b8c9ce1eab7b0f9ed73253b45fe36680c0661f0a6a2406540ba76bb1a8985bad
3
+ metadata.gz: 97d28b88662422e5a90c85b6b01faf9195cdd9041ae302dafb55fff94ddfe101
4
+ data.tar.gz: a822c03eef5073e26e7d494e3b60c9c6b0ee1bea8d0fcbe922d4a02fb30e9539
5
5
  SHA512:
6
- metadata.gz: 54b62ade3690caecbe6825c8615822c9fe9d509ccb546167561ef89aa905550341d92d994433a52c0d618761ce4353051618e15a98e2128381fa577f36b055f1
7
- data.tar.gz: 6e5939e5b0b38ecd2b29ba4e34ab76889ba7010ad393189b04581444cfd60cf1c924e12a3024e5df7ca04d3633d2ce5a3a2775a232f5b167caa45d076cf303e4
6
+ metadata.gz: af7f6f4063834fee805f7c2b541a98eee83cc95cf2347028d20120280a69277004b003159d32c1be29d74cb3ae5317c7dff374d941785f21b7de7a6cad29345e
7
+ data.tar.gz: 5c9e365bfef257cd8164f258b1cb97d87e0d16db5f56f96b1661ed1907ffd33fc79ebfdabe5d27c0ebc02b18c00a77c5a83550a751e440f2e5cd2f4cca03d365
@@ -1,5 +1,5 @@
1
1
  module Jekyll
2
2
  module DrawIO
3
- VERSION = "0.0.5"
3
+ VERSION = "1.0.0"
4
4
  end
5
5
  end
data/lib/jekyll-drawio.rb CHANGED
@@ -31,12 +31,12 @@ class DrawIOConverter < Liquid::Tag
31
31
  doc = File.open(path) { |f| Nokogiri::XML(f) }
32
32
  diagrams = doc.xpath("//mxfile//diagram")
33
33
  puts "Diagrams found at \"#{ path }\": #{ diagrams.length }. " \
34
- "Selected: #{ @selected_diagram_num }. " \
35
- "Height: #{ @diagram_height }"
34
+ "Selected: #{ @selected_diagram_num }. "
35
+
36
36
  diagram = diagrams[selected_diagram_num]
37
37
 
38
38
  diagram_name = diagram["name"]
39
- diagram_content = diagram.content
39
+ diagram_content = diagram.content.to_s
40
40
 
41
41
  return diagram_name, diagram_content
42
42
  end
@@ -46,6 +46,8 @@ class DrawIOConverter < Liquid::Tag
46
46
  encoded_diagram = ERB::Util.url_encode diagram_content
47
47
  encoded_diagram_name = ERB::Util.url_encode diagram_name
48
48
 
49
+ puts "Parsed diagram: name=#{ diagram_name } length=#{ diagram_content.length } height=#{ @diagram_height }"
50
+
49
51
  viewer_url_base = "https://viewer.diagrams.net/?highlight=0000ff&edit=_blank&layers=1&nav=1"
50
52
  viewer_url = "#{ viewer_url_base }&title=#{ encoded_diagram_name }\#R#{ encoded_diagram }"
51
53
  viewer_style = "style=\"width:100%;height:#{ @diagram_height }px\""
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-drawio
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 1.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Illia Gorbatiuk
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-10-26 00:00:00.000000000 Z
11
+ date: 2023-04-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -16,42 +16,42 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '3.9'
19
+ version: '4.3'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '3.9'
26
+ version: '4.3'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: nokogiri
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '1.10'
33
+ version: '1.14'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '1.10'
40
+ version: '1.14'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: erb
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: '2.2'
47
+ version: '4.0'
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: '2.2'
54
+ version: '4.0'
55
55
  description:
56
56
  email:
57
57
  - ilya.gorbatiuk@gmail.com
@@ -82,8 +82,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
82
82
  - !ruby/object:Gem::Version
83
83
  version: '0'
84
84
  requirements: []
85
- rubyforge_project:
86
- rubygems_version: 2.7.6
85
+ rubygems_version: 3.2.3
87
86
  signing_key:
88
87
  specification_version: 4
89
88
  summary: Jekyll plugin to generate HTML snippets for embedding draw.io diagrams