isodoc 2.2.3 → 2.2.3.1

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: efcdfcde0ed6b8878845a1b030b1bf7f375dc21f7daae1589ba6b8324e06a333
4
- data.tar.gz: 6498b1dc8efa9f850c2fed954ec9f7067d847fb932d86b4e353125754e780dad
3
+ metadata.gz: 0aabb80b1f5ef79e1898ee6304efa075760c5bed1ef1241a78e8b481f7e291e2
4
+ data.tar.gz: 67f4dc2ddb0e3ac6a0702eac75478b450a65e5cfcab009fbac55cb1728bef0f2
5
5
  SHA512:
6
- metadata.gz: 0b6a7404d5021f2ef2db93b83803a122a842febd05e30fb0fbda876407c8b8673382ef818038f73899376d6ba1b465410d12c4076c782829a8292adefd65e758
7
- data.tar.gz: 251e5f94894578f8d5e365333a1512a1c8bac91d0c6020afa95d409eb1c9299f4bbb73762c94e2103775e85f5bb43e5b6710161c9f79ebee2fa0d29d5d94f0f1
6
+ metadata.gz: f66cff989b8e7ea39834fe1b200a95af35aa6c4b3c80fb8b6623369f501bddd7e656c8d6ca112ffd68f903a5ef9e5daa0e40d90fae6f05f94eaaa4fb98000c73
7
+ data.tar.gz: dbc8d4969a5554f8ed8b60e440a80679890da6704915021da9740c9a2644d8fc2c7c6317eec7eeab1ddab949b95aaed3afa6efce91c0042f5211e2e14ea3bb16
@@ -81,7 +81,7 @@ module IsoDoc
81
81
  end
82
82
 
83
83
  def bibliography_bibitem_number1(bibitem, idx)
84
- ins = bibitem.at(ns(".//docidentifier")).previous_element
84
+ ins = bibliography_bibitem_number_insert_pt(bibitem)
85
85
  mn = bibitem.at(ns(".//docidentifier[@type = 'metanorma']")) and
86
86
  /^\[?\d+\]?$/.match?(mn.text) and
87
87
  mn.remove # ignore numbers already inserted
@@ -93,6 +93,14 @@ module IsoDoc
93
93
  idx
94
94
  end
95
95
 
96
+ def bibliography_bibitem_number_insert_pt(bibitem)
97
+ unless ins = bibitem.at(ns(".//docidentifier")).previous_element
98
+ bibitem.at(ns(".//docidentifier")).previous = " "
99
+ ins = bibitem.at(ns(".//docidentifier")).previous
100
+ end
101
+ ins
102
+ end
103
+
96
104
  def docid_prefixes(docxml)
97
105
  docxml.xpath(ns("//references/bibitem/docidentifier")).each do |i|
98
106
  i.children = @xrefs.klass.docid_prefix(i["type"], i.text)
@@ -1,3 +1,3 @@
1
1
  module IsoDoc
2
- VERSION = "2.2.3".freeze
2
+ VERSION = "2.2.3.1".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: isodoc
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.3
4
+ version: 2.2.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-09-05 00:00:00.000000000 Z
11
+ date: 2022-09-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: asciimath