asciidoctor-lists 1.0.7 → 1.0.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.adoc +6 -1
- data/lib/asciidoctor-lists/extensions.rb +5 -5
- data/lib/asciidoctor-lists/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ead5ee1e020cd52bc49b607b2ab219392dbb6b71f4fb9699efac7cff62fc534c
|
4
|
+
data.tar.gz: e1b765e0d8532d830999c5361c274765c694f6bcba9e631c256104a78c7df771
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 033e98081a58246e5f64f8cbb7e1944ced204608e51cb487acb462fe82c5b4e1530e9203a2b952c714a92b38d50bea527b9de23f0d7a63f7d2e2ccc9828856ad
|
7
|
+
data.tar.gz: '0320822b27c2a5a48d0f38ec904a7ac8b93655a40c0aebb955da9bcca0a8b2bae301892bdcfb0716e7d626845a34d90c4ca1b3fb18a41291523f395ea0f922b9'
|
data/README.adoc
CHANGED
@@ -1,11 +1,13 @@
|
|
1
1
|
= asciidoctor-lists
|
2
2
|
|
3
|
+
image:https://img.shields.io/gem/dt/asciidoctor-lists[Gem, link=https://rubygems.org/gems/asciidoctor-lists]
|
3
4
|
image:https://github.com/Alwinator/asciidoctor-lists/actions/workflows/test.yml/badge.svg[Test, link=https://github.com/Alwinator/asciidoctor-lists/actions/workflows/test.yml]
|
4
5
|
image:https://github.com/Alwinator/asciidoctor-lists/actions/workflows/publish_gem.yml/badge.svg[Build, link=https://github.com/Alwinator/asciidoctor-lists/actions/workflows/publish_gem.yml]
|
5
6
|
image:https://img.shields.io/gem/v/asciidoctor-lists.svg[Latest Release, link=https://rubygems.org/gems/asciidoctor-lists]
|
6
7
|
image:https://img.shields.io/github/stars/Alwinator/asciidoctor-lists[Stars, link=https://github.com/Alwinator/asciidoctor-lists]
|
7
8
|
|
8
9
|
|
10
|
+
|
9
11
|
An https://asciidoctor.org/[asciidoctor] extension that adds a list of figures, a list of tables, or a list of anything you want!
|
10
12
|
|
11
13
|
*Pull Requests are always welcome! :)*
|
@@ -53,7 +55,7 @@ Sample: link:samples/enhanced-rendering.adoc[]
|
|
53
55
|
=== hide_empty_section
|
54
56
|
Removes the section when no elements are found
|
55
57
|
|
56
|
-
Sample: link:samples/hide-if-empty-list-sample.adoc
|
58
|
+
Sample: link:samples/hide-if-empty-list-sample.adoc[]
|
57
59
|
|
58
60
|
== Docker
|
59
61
|
[source,bash]
|
@@ -79,3 +81,6 @@ asciidoctor -r ./lib/asciidoctor-lists.rb samples/list-sample.adoc
|
|
79
81
|
gem build asciidoctor-lists.gemspec
|
80
82
|
gem install asciidoctor-lists-x.x.x.gem
|
81
83
|
----
|
84
|
+
|
85
|
+
== Docker Image
|
86
|
+
- Support in official asciidoctor Docker image is waiting for approval (See https://github.com/asciidoctor/docker-asciidoctor/pull/262)
|
@@ -40,7 +40,7 @@ module AsciidoctorLists
|
|
40
40
|
enhanced_rendering = params[:enhanced_rendering]
|
41
41
|
hide_empty_section = params[:hide_empty_section]
|
42
42
|
|
43
|
-
elements = document.find_by(context: params[:element].to_sym)
|
43
|
+
elements = document.find_by(traverse_documents: true, context: params[:element].to_sym)
|
44
44
|
if elements.length > 0
|
45
45
|
elements.each do |element|
|
46
46
|
|
@@ -51,14 +51,14 @@ module AsciidoctorLists
|
|
51
51
|
|
52
52
|
if enhanced_rendering
|
53
53
|
if element.caption
|
54
|
-
references_asciidoc << %(xref:#{element.id}[#{element.caption}]#{element.instance_variable_get(:@title)} +)
|
55
|
-
else
|
54
|
+
references_asciidoc << %(xref:#{element.id}[#{element.caption.rstrip()}] #{element.instance_variable_get(:@title)} +)
|
55
|
+
else
|
56
56
|
references_asciidoc << %(xref:#{element.id}[#{element.instance_variable_get(:@title)}] +)
|
57
57
|
end
|
58
58
|
else
|
59
59
|
if element.caption
|
60
|
-
references_asciidoc << %(xref:#{element.id}[#{element.caption}]#{element.title} +)
|
61
|
-
else
|
60
|
+
references_asciidoc << %(xref:#{element.id}[#{element.caption.rstrip()}] #{element.title} +)
|
61
|
+
else
|
62
62
|
references_asciidoc << %(xref:#{element.id}[#{element.title}] +)
|
63
63
|
end
|
64
64
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: asciidoctor-lists
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alwin Schuster
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-08-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: asciidoctor
|
@@ -54,7 +54,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
54
54
|
- !ruby/object:Gem::Version
|
55
55
|
version: '0'
|
56
56
|
requirements: []
|
57
|
-
rubygems_version: 3.
|
57
|
+
rubygems_version: 3.3.5
|
58
58
|
signing_key:
|
59
59
|
specification_version: 4
|
60
60
|
summary: An asciidoctor extension that adds a list of figures, a list of tables, or
|