asciidoctor-html 0.1.10 → 0.1.11

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c99bb6f2d60f804587c86b5806f544a2a3c543f8e2cf257715b637ede3bdcfee
4
- data.tar.gz: '0603291e74a63453de5eb837de838e8b2e2b420bc547dd39e881eff8a1b04adc'
3
+ metadata.gz: b31a232ef36bff4b9833aa68e7304c0616a1acd0ade2e82555bdb28da3c1f262
4
+ data.tar.gz: bcbb6f25581b2b1c87bbb0aa8fd97875d4eb7e04cbdd5eac9d729606b109a58f
5
5
  SHA512:
6
- metadata.gz: ac48827c04f5c761754f38e1186c71ce4a7cf3b46c5a9cb783df33ed2290683ec04d72b82ca4368addb0043cf525f653c55762914b3ade036a0b74840861f7a5
7
- data.tar.gz: 6922436490654113090a9586efd0c8d32279e375f5d570382a5582a308d42cf162f2b3fe33415fee2e3f4a07cc244ecbabfbf91e90cc8203241bb52e58e13947
6
+ metadata.gz: 9c6d4903f2c15300c89e5aa485e7fde24cfd496c6243406e24e7273aa22896f092f77b5fd79151f62e8933e954f0e1fad38d4aaf8a43b5641462925ad6f7ccd5
7
+ data.tar.gz: 2aec7771279959980129181973f8a83d3803bcf9c585d65660859c60568fc3d0b2d4f00134451d8539bbcd799478dc564a4df10bc6ab5f0874ca44cc5552b420
data/.rubocop.yml CHANGED
@@ -6,10 +6,10 @@ Metrics/AbcSize:
6
6
  Max: 50
7
7
 
8
8
  Metrics/CyclomaticComplexity:
9
- Max: 20
9
+ Max: 25
10
10
 
11
11
  Metrics/PerceivedComplexity:
12
- Max: 20
12
+ Max: 25
13
13
 
14
14
  Metrics/BlockNesting:
15
15
  Max: 5
data/CHANGELOG.md CHANGED
@@ -63,3 +63,7 @@
63
63
  - The text macro adds support for semantic inline text formatting as well
64
64
  as SmallCaps and other styles.
65
65
  - Some documentation improvements.
66
+
67
+ ## [0.1.11] - 2025-08-10
68
+
69
+ - Added continue attribute for ordered lists.
@@ -113,7 +113,14 @@ module Asciidoctor
113
113
  end
114
114
 
115
115
  def offset(list)
116
- list.attr?("start") ? (list.attr("start").to_i - 1) : 0
116
+ return (list.attr("start").to_i - 1) if list.attr?("start")
117
+ return 0 unless list.attr?("continue")
118
+
119
+ id = list.attr "continue"
120
+ node = list.document.catalog[:refs][id]
121
+ return node.attr("nflatitems") || node.items.size if node&.context == :olist
122
+
123
+ 0
117
124
  end
118
125
 
119
126
  def shift(list)
@@ -227,7 +234,7 @@ module Asciidoctor
227
234
  elsif olist? block
228
235
  if listdepth.zero?
229
236
  flat_style = (block.style == "pseudocode")
230
- flat_idx = offset block # rubocop:disable Lint/UselessAssignment
237
+ flat_idx = offset block
231
238
  end
232
239
  process_olist! block, listdepth, flat_style:
233
240
  elsif olist_item?(block) && flat_style
@@ -245,6 +252,7 @@ module Asciidoctor
245
252
  listdepth -= 1 if olist_item?(block) && move == :retreat
246
253
  bulletdepth += 1 if ulist?(block) && move == :explore
247
254
  bulletdepth -= 1 if ulist_item?(block) && move == :retreat
255
+ block.set_attr("nflatitems", flat_idx) if olist?(block) && flat_style && move == :retreat
248
256
  end
249
257
  end
250
258
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: asciidoctor-html
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.10
4
+ version: 0.1.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ravi Rajani