metanorma-iso 3.0.1 → 3.0.2

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.
@@ -142,16 +142,6 @@ module IsoDoc
142
142
  end
143
143
  end
144
144
 
145
- # def clause(docxml)
146
- # docxml.xpath(ns("//clause[not(ancestor::annex)] | " \
147
- # "//terms | //definitions | //references | " \
148
- # "//preface/introduction[clause]")).each do |f|
149
- # f.parent.name == "annex" &&
150
- # @xrefs.klass.single_term_clause?(f.parent) and next
151
- # clause1(f)
152
- # end
153
- # end
154
-
155
145
  def admonition1(elem)
156
146
  super
157
147
  admonition_outside_clauses(elem)
@@ -209,7 +199,7 @@ module IsoDoc
209
199
  if elem["class"] == "modspec"
210
200
  if n = elem.at(ns(".//fmt-name"))
211
201
  n.remove.name = "name"
212
- elem.add_first_child(n)
202
+ elem.add_first_child(n)
213
203
  end
214
204
  elem.at(ns("./thead"))&.remove
215
205
  super
@@ -319,6 +309,16 @@ module IsoDoc
319
309
  true
320
310
  end
321
311
 
312
+ def fn_ref_label(fnote)
313
+ if fnote.ancestors("table, figure").empty? ||
314
+ !fnote.ancestors("name, fmt-name").empty?
315
+ "<sup>#{fn_label(fnote)}" \
316
+ "<span class='fmt-label-delim'>)</span></sup>"
317
+ else
318
+ super
319
+ end
320
+ end
321
+
322
322
  include Init
323
323
  end
324
324
  end
@@ -131,6 +131,7 @@ module IsoDoc
131
131
  TOC
132
132
  end
133
133
 
134
+ # KILL
134
135
  def footnote_reference_format(link)
135
136
  link.children =
136
137
  "<span class='MsoFootnoteReference'>#{to_xml(link.children)}</span>)"
@@ -249,6 +250,8 @@ module IsoDoc
249
250
  node.xpath(ns("./source")).each { |n| parse(n, out) }
250
251
  node.xpath(ns("./note[not(@type = 'units')]"))
251
252
  .each { |n| parse(n, out) }
253
+ node.xpath(ns("./fmt-footnote-container/fmt-fn-body"))
254
+ .each { |n| parse(n, out) }
252
255
  end
253
256
 
254
257
  include BaseConvert
@@ -33,6 +33,15 @@
33
33
  </zeroOrMore>
34
34
  </element>
35
35
  </define>
36
+ <define name="fn" combine="interleave">
37
+ <optional>
38
+ <attribute name="hiddenref">
39
+ <a:documentation>If true, number the footnote as normal, but suppress display of the footnote reference in the document body.
40
+ This is done if the footnote reference is already presented in some other form, e.g. within a figure image.</a:documentation>
41
+ <data type="boolean"/>
42
+ </attribute>
43
+ </optional>
44
+ </define>
36
45
  <define name="index-primary">
37
46
  <element name="primary">
38
47
  <oneOrMore>
@@ -63,14 +63,6 @@
63
63
  </choice>
64
64
  </element>
65
65
  </define>
66
- <define name="organization">
67
- <element name="organization">
68
- <choice>
69
- <ref name="OrganizationType"/>
70
- <ref name="IsoOrganizationType"/>
71
- </choice>
72
- </element>
73
- </define>
74
66
  <define name="DocumentType">
75
67
  <choice>
76
68
  <value>international-standard</value>
@@ -219,18 +211,4 @@
219
211
  <text/>
220
212
  </element>
221
213
  </define>
222
- <define name="IsoOrganizationType">
223
- <optional>
224
- <ref name="technical-committee"/>
225
- </optional>
226
- <optional>
227
- <ref name="subcommittee"/>
228
- </optional>
229
- <optional>
230
- <ref name="workgroup"/>
231
- </optional>
232
- <optional>
233
- <ref name="secretariat"/>
234
- </optional>
235
- </define>
236
214
  </grammar>
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module Iso
3
- VERSION = "3.0.1".freeze
3
+ VERSION = "3.0.2".freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metanorma-iso
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.1
4
+ version: 3.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-03-04 00:00:00.000000000 Z
11
+ date: 2025-03-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: metanorma-standoc