metanorma-iec 2.7.0 → 2.7.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.
- checksums.yaml +4 -4
- data/README.adoc +1 -1
- data/lib/isodoc/iec/iec.international-standard.xsl +294 -92
- data/lib/isodoc/iec/metadata.rb +1 -2
- data/lib/isodoc/iec/xref.rb +4 -5
- data/lib/metanorma/iec/basicdoc.rng +6 -6
- data/lib/metanorma/iec/isodoc.rng +8 -60
- data/lib/metanorma/iec/version.rb +1 -1
- data/metanorma-iec.gemspec +1 -1
- metadata +3 -3
data/lib/isodoc/iec/metadata.rb
CHANGED
@@ -7,11 +7,10 @@ module IsoDoc
|
|
7
7
|
def docstatus(isoxml, _out)
|
8
8
|
docstatus = isoxml.at(ns("//bibdata/status/stage"))
|
9
9
|
substage = isoxml.at(ns("//bibdata/status/substage"))
|
10
|
-
|
10
|
+
published_default(isoxml)
|
11
11
|
if docstatus
|
12
12
|
set(:stage, docstatus.text)
|
13
13
|
set(:stage_int, docstatus.text.to_i)
|
14
|
-
set(:unpublished, unpublished(docstatus.text))
|
15
14
|
set(:statusabbr, substage["abbreviation"])
|
16
15
|
unpublished(docstatus.text) and
|
17
16
|
set(:stageabbr, docstatus["abbreviation"])
|
data/lib/isodoc/iec/xref.rb
CHANGED
@@ -28,15 +28,14 @@ module IsoDoc
|
|
28
28
|
docxml.xpath(ns("//sections/clause/terms")).each_with_index do |t, i|
|
29
29
|
num = semx(t, "#{@iev_part}-%02d" % [i + 1])
|
30
30
|
@anchors[t["id"]] =
|
31
|
-
{ label: num,
|
32
|
-
|
33
|
-
xref: labelled_autonum(@labels['section_iev'], num),
|
31
|
+
{ label: num,
|
32
|
+
xref: labelled_autonum(@labels["section_iev"], num),
|
34
33
|
level: 2, type: "clause", elem: @labels["section_iev"] }
|
35
34
|
j = 0
|
36
35
|
t.xpath(ns("./term")).each do |c|
|
37
36
|
c["unnumbered"] == "true" and next
|
38
37
|
num2 = semx(c, "%02d" % [j + 1])
|
39
|
-
#section_names1(c, "#{num}#{delim_wrap("-")}#{num2}", 3)
|
38
|
+
# section_names1(c, "#{num}#{delim_wrap("-")}#{num2}", 3)
|
40
39
|
section_names1(c, num, num2, 3)
|
41
40
|
j += 1
|
42
41
|
end
|
@@ -54,7 +53,7 @@ module IsoDoc
|
|
54
53
|
clause["obligation"] == "normative" and
|
55
54
|
obl = l10n("(#{@labels['norm_annex']})")
|
56
55
|
obl = "<span class='fmt-obligation'>#{l10n obl}</fmt>"
|
57
|
-
s = labelled_autonum(@labels[
|
56
|
+
s = labelled_autonum(@labels["annex"], num)
|
58
57
|
l10n("<strong><span class='fmt-caption-label'>#{s}</span></strong><br/>#{obl}")
|
59
58
|
end
|
60
59
|
end
|
@@ -198,14 +198,14 @@ Applicable to modify and delete</a:documentation>
|
|
198
198
|
</zeroOrMore>
|
199
199
|
</element>
|
200
200
|
</optional>
|
201
|
-
<
|
201
|
+
<zeroOrMore>
|
202
202
|
<element name="description">
|
203
|
-
<a:documentation>Description of the change described in this block</a:documentation>
|
204
|
-
<
|
203
|
+
<a:documentation>Description(s) of the change described in this block</a:documentation>
|
204
|
+
<oneOrMore>
|
205
205
|
<ref name="BasicBlock"/>
|
206
|
-
</
|
206
|
+
</oneOrMore>
|
207
207
|
</element>
|
208
|
-
</
|
208
|
+
</zeroOrMore>
|
209
209
|
<optional>
|
210
210
|
<element name="newcontent">
|
211
211
|
<a:documentation>New content to be added to the document; applicable to add and modify</a:documentation>
|
@@ -1291,13 +1291,13 @@ Restricted recursively to contain only other such inline elements with no identi
|
|
1291
1291
|
<ref name="pure_strike"/>
|
1292
1292
|
<ref name="pure_smallcap"/>
|
1293
1293
|
<ref name="br"/>
|
1294
|
+
<ref name="stem"/>
|
1294
1295
|
</choice>
|
1295
1296
|
</define>
|
1296
1297
|
<define name="NestedTextElement">
|
1297
1298
|
<a:documentation>Contents of TextElement tags: leaves out tags that should occur only at top level of block: bookmark image hr pagebreak</a:documentation>
|
1298
1299
|
<choice>
|
1299
1300
|
<ref name="PureTextElement"/>
|
1300
|
-
<ref name="stem"/>
|
1301
1301
|
<ref name="eref"/>
|
1302
1302
|
<ref name="xref"/>
|
1303
1303
|
<ref name="hyperlink"/>
|
@@ -1,6 +1,6 @@
|
|
1
1
|
<?xml version="1.0" encoding="UTF-8"?>
|
2
2
|
<grammar xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0" xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
|
3
|
-
<!-- VERSION v2.0
|
3
|
+
<!-- VERSION v2.1.0 -->
|
4
4
|
|
5
5
|
<!--
|
6
6
|
ALERT: cannot have root comments, because of https://github.com/metanorma/metanorma/issues/437
|
@@ -42,36 +42,6 @@ All IdRefType instances point not to `@id` in Semantic XML, which is the Content
|
|
42
42
|
but to `@anchor`, the user-supplied cross-reference</a:documentation>
|
43
43
|
<text/>
|
44
44
|
</define>
|
45
|
-
<define name="index-primary">
|
46
|
-
<element name="primary">
|
47
|
-
<oneOrMore>
|
48
|
-
<choice>
|
49
|
-
<ref name="PureTextElement"/>
|
50
|
-
<ref name="stem"/>
|
51
|
-
</choice>
|
52
|
-
</oneOrMore>
|
53
|
-
</element>
|
54
|
-
</define>
|
55
|
-
<define name="index-secondary">
|
56
|
-
<element name="secondary">
|
57
|
-
<oneOrMore>
|
58
|
-
<choice>
|
59
|
-
<ref name="PureTextElement"/>
|
60
|
-
<ref name="stem"/>
|
61
|
-
</choice>
|
62
|
-
</oneOrMore>
|
63
|
-
</element>
|
64
|
-
</define>
|
65
|
-
<define name="index-tertiary">
|
66
|
-
<element name="tertiary">
|
67
|
-
<oneOrMore>
|
68
|
-
<choice>
|
69
|
-
<ref name="PureTextElement"/>
|
70
|
-
<ref name="stem"/>
|
71
|
-
</choice>
|
72
|
-
</oneOrMore>
|
73
|
-
</element>
|
74
|
-
</define>
|
75
45
|
<define name="review">
|
76
46
|
<a:documentation>Generalise BasicDoc element from just review comments, to general annotations;
|
77
47
|
the type attribute defaults to `review` for reviews</a:documentation>
|
@@ -592,28 +562,6 @@ normative or informative references, some split references into sections organiz
|
|
592
562
|
</oneOrMore>
|
593
563
|
</element>
|
594
564
|
</define>
|
595
|
-
<define name="sub">
|
596
|
-
<a:documentation>Subscript text. Corresponds to HTML `sub</a:documentation>
|
597
|
-
<element name="sub">
|
598
|
-
<zeroOrMore>
|
599
|
-
<choice>
|
600
|
-
<ref name="PureTextElement"/>
|
601
|
-
<ref name="stem"/>
|
602
|
-
</choice>
|
603
|
-
</zeroOrMore>
|
604
|
-
</element>
|
605
|
-
</define>
|
606
|
-
<define name="sup">
|
607
|
-
<a:documentation>Superscript text. Corresponds to HTML `sup`</a:documentation>
|
608
|
-
<element name="sup">
|
609
|
-
<zeroOrMore>
|
610
|
-
<choice>
|
611
|
-
<ref name="PureTextElement"/>
|
612
|
-
<ref name="stem"/>
|
613
|
-
</choice>
|
614
|
-
</zeroOrMore>
|
615
|
-
</element>
|
616
|
-
</define>
|
617
565
|
<define name="pagebreak">
|
618
566
|
<a:documentation>Page break. Only applicable in paged layouts (e.g. PDF, Word), and not flow layouts (e.g. HTML)</a:documentation>
|
619
567
|
<element name="pagebreak">
|
@@ -735,6 +683,12 @@ titlecase, or lowercase</a:documentation>
|
|
735
683
|
<ref name="BlockAttributes"/>
|
736
684
|
</define>
|
737
685
|
<define name="TableAttributes" combine="interleave">
|
686
|
+
<optional>
|
687
|
+
<attribute name="plain">
|
688
|
+
<a:documentation>Render as a plain attribute, with no shading or borders</a:documentation>
|
689
|
+
<data type="boolean"/>
|
690
|
+
</attribute>
|
691
|
+
</optional>
|
738
692
|
<optional>
|
739
693
|
<attribute name="width">
|
740
694
|
<a:documentation>Width of the table block in rendering</a:documentation>
|
@@ -1088,7 +1042,6 @@ That concept may be defined as a term within the current document, or it may be
|
|
1088
1042
|
<zeroOrMore>
|
1089
1043
|
<choice>
|
1090
1044
|
<ref name="PureTextElement"/>
|
1091
|
-
<ref name="stem"/>
|
1092
1045
|
<ref name="index"/>
|
1093
1046
|
<ref name="index-xref"/>
|
1094
1047
|
</choice>
|
@@ -1101,7 +1054,6 @@ That concept may be defined as a term within the current document, or it may be
|
|
1101
1054
|
<zeroOrMore>
|
1102
1055
|
<choice>
|
1103
1056
|
<ref name="PureTextElement"/>
|
1104
|
-
<ref name="stem"/>
|
1105
1057
|
<ref name="index"/>
|
1106
1058
|
<ref name="index-xref"/>
|
1107
1059
|
</choice>
|
@@ -2019,10 +1971,7 @@ used in document amendments</a:documentation>
|
|
2019
1971
|
<element name="name">
|
2020
1972
|
<a:documentation>The symbolic form of the designation</a:documentation>
|
2021
1973
|
<oneOrMore>
|
2022
|
-
<
|
2023
|
-
<ref name="PureTextElement"/>
|
2024
|
-
<ref name="stem"/>
|
2025
|
-
</choice>
|
1974
|
+
<ref name="PureTextElement"/>
|
2026
1975
|
</oneOrMore>
|
2027
1976
|
</element>
|
2028
1977
|
</element>
|
@@ -2075,7 +2024,6 @@ used in document amendments</a:documentation>
|
|
2075
2024
|
<zeroOrMore>
|
2076
2025
|
<choice>
|
2077
2026
|
<ref name="PureTextElement"/>
|
2078
|
-
<ref name="stem"/>
|
2079
2027
|
<ref name="index"/>
|
2080
2028
|
<ref name="index-xref"/>
|
2081
2029
|
</choice>
|
data/metanorma-iec.gemspec
CHANGED
@@ -45,6 +45,6 @@ spec.add_development_dependency "rubocop-performance"
|
|
45
45
|
spec.add_development_dependency "sassc-embedded", "~> 1"
|
46
46
|
spec.add_development_dependency "simplecov", "~> 0.15"
|
47
47
|
spec.add_development_dependency "timecop", "~> 0.9"
|
48
|
-
spec.add_development_dependency "
|
48
|
+
spec.add_development_dependency "canon"
|
49
49
|
# spec.metadata["rubygems_mfa_required"] = "true"
|
50
50
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-iec
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.7.
|
4
|
+
version: 2.7.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-
|
11
|
+
date: 2025-08-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: metanorma-iso
|
@@ -207,7 +207,7 @@ dependencies:
|
|
207
207
|
- !ruby/object:Gem::Version
|
208
208
|
version: '0.9'
|
209
209
|
- !ruby/object:Gem::Dependency
|
210
|
-
name:
|
210
|
+
name: canon
|
211
211
|
requirement: !ruby/object:Gem::Requirement
|
212
212
|
requirements:
|
213
213
|
- - ">="
|