asciidoctor-tabs 1.0.0.beta.5 → 1.0.0.beta.6
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 +14 -0
- data/README.adoc +1 -1
- data/lib/asciidoctor/tabs/block.rb +8 -11
- data/lib/asciidoctor/tabs/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: d453d4bfdf6f6b92e7a098908890fb85643aaee9d4fde38bd94aeae1f9576139
|
4
|
+
data.tar.gz: 7a6d50452588a2785e201fd76aa7cd6b61294f507456ad10aeb2fab76e97b1fc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4697b8dd5e29a82a88d2102cc9d983568416c8a4d14dbb54469e4f343fd1d0311c0d77e65ee4cecb2cd5446a4bb4431b6831b9a36d35927f1391e5125ac6b7da
|
7
|
+
data.tar.gz: 7ee4072275cf65f19d34715714e51e52d767830a278dd133b6eb9663a9c81c3f89f3eb9acbc4177562f65c6c6c3e5170547ba51f1991ff218d03b8e4226e0ec9
|
data/CHANGELOG.adoc
CHANGED
@@ -4,6 +4,20 @@
|
|
4
4
|
This document provides a curated view of the changes to Asciidoctor Tabs per release.
|
5
5
|
For a detailed view of what has changed, refer to the {url-repo}/commits/main[commit history] on GitHub.
|
6
6
|
|
7
|
+
== 1.0.0-beta.6 (2023-08-01) - @mojavelinux
|
8
|
+
|
9
|
+
=== Changed
|
10
|
+
|
11
|
+
* Repurpose example block as open block if filetype is not html
|
12
|
+
|
13
|
+
=== Fixed
|
14
|
+
|
15
|
+
* Preserve attribute entries above tabs block (#64)
|
16
|
+
|
17
|
+
=== Details
|
18
|
+
|
19
|
+
{url-repo}/releases/tag/v1.0.0-beta.6[git tag] | {url-repo}/compare/v1.0.0-beta.5\...v1.0.0-beta.6[full diff]
|
20
|
+
|
7
21
|
== 1.0.0-beta.5 (2023-05-28) - @mojavelinux
|
8
22
|
|
9
23
|
=== Changed
|
data/README.adoc
CHANGED
@@ -7,23 +7,20 @@ module Asciidoctor
|
|
7
7
|
on_context :example
|
8
8
|
|
9
9
|
def process parent, reader, attrs
|
10
|
-
|
10
|
+
doc = parent.document
|
11
|
+
return create_open_block parent, nil, attrs unless doc.attr? 'filetype', 'html'
|
12
|
+
tabs_number = doc.counter 'tabs-number'
|
11
13
|
block = create_block parent, attrs['cloaked-context'], nil, attrs, content_model: :compound
|
12
14
|
children = (parse_content block, reader).blocks
|
13
|
-
|
14
|
-
|
15
|
-
end
|
16
|
-
unless doc.attr? 'filetype', 'html'
|
17
|
-
(id = attrs['id']) && (doc.register :refs, [(seed_tabs.id = id), seed_tabs]) unless seed_tabs.id
|
18
|
-
(reftext = attrs['reftext']) && (seed_tabs.set_attr 'reftext', reftext) unless seed_tabs.reftext?
|
19
|
-
parent << seed_tabs
|
20
|
-
return reset_counter doc, 'tabs-number', (tabs_number - 1)
|
21
|
-
end
|
15
|
+
return (reset_counter doc, 'tabs-number', (tabs_number - 1)) || block unless children.size == 1 &&
|
16
|
+
(seed_tabs = children[0]).context == :dlist && seed_tabs.items?
|
22
17
|
tabs_id = attrs['id'] || (generate_id %(tabs #{tabs_number}), doc)
|
23
18
|
tabs_role = 'tabs' + (!(block.option? 'nosync') && ((block.option? 'sync') || (doc.option? 'tabs-sync')) ?
|
24
19
|
((gid = attrs['sync-group-id']) ? %( is-sync data-sync-group-id=#{gid.gsub ' ', ?\u00a0}) : ' is-sync') : '')
|
25
20
|
tabs_role += (tabs_user_role = attrs['role']) ? %( #{tabs_user_role} is-loading) : ' is-loading'
|
26
|
-
|
21
|
+
tabs_attrs = { 'id' => tabs_id, 'role' => tabs_role }
|
22
|
+
tabs_attrs[:attribute_entries] = attrs[:attribute_entries] if attrs.key? :attribute_entries
|
23
|
+
(tabs = create_open_block parent, nil, tabs_attrs).title = attrs['title']
|
27
24
|
tablist = create_list parent, :ulist, { 'role' => 'tablist' }
|
28
25
|
panes = {}
|
29
26
|
set_id_on_tab = (doc.backend == 'html5') || (list_item_supports_id? doc)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: asciidoctor-tabs
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.0.beta.
|
4
|
+
version: 1.0.0.beta.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dan Allen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-08-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: asciidoctor
|