metanorma-generic 2.7.4 → 3.0.1

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: c0df93886595c4231d7468467314c0d9b4c44e96963c92d257b5cd5f3c4a411a
4
- data.tar.gz: 1d2e1f00ffe3384508577eae8bde782fa630eeda674625f3fc0e9090fe60660c
3
+ metadata.gz: 7b9fbaa1e091c0f6edaa501c80a824e4ff03da4f2298cc0c7eb448b8022559d0
4
+ data.tar.gz: 74607e5b5d24376bde715a7e00596265b3d32c1b5b4550608783d089109f813b
5
5
  SHA512:
6
- metadata.gz: a8f2df814eff57cf832b50d74283910aadd71d71b5a16c4443ebdba3b4e55cd85db055e488f1f1bc68443d9954a69af2308a049975f0f3aa70c029d67e8bd311
7
- data.tar.gz: b32d41f697ac6102de55b65c85f51b66f487e27b8cbf66f519ec19a6c3691e1ae4db475f40f8e6122867eda72e74f4246bb130b14cfeb0ea1bae07a31a5e23d7
6
+ metadata.gz: f898b9d663f6619d91ad5d46d7d9e48a656f4c013006124d76b95a992b3ff87821d98fa4eae34aacdcc076c5a31c9b597bf957371d6abcca79c0ca1eb3bf9fa2
7
+ data.tar.gz: d29162d79ecfb40d3f4b3655ebb856a48d575b19f727302cf2cad5b9b77c58228e027ce01102af616fc64059da2c7a3d14c6e00ccf66e46d2de6c413304b0e79
@@ -7,7 +7,7 @@
7
7
  License: none (public domain)
8
8
  */
9
9
 
10
- @import 'base_style/all';
10
+ @use 'base_style/all' as *;
11
11
 
12
12
  body {
13
13
  @include bodyStyle1(15px, 1.4em, #1d1d1d, #ffffff, 300);
@@ -599,17 +599,9 @@ It is included for convenience, in case processing the citation to extract the a
599
599
  <a:documentation>The caption of the block</a:documentation>
600
600
  </ref>
601
601
  </optional>
602
- <oneOrMore>
603
- <choice>
604
- <text>
605
- <a:documentation>The computer code or other such text presented in the block, as a single unformatted string.
606
- (The string should be treated as pre-formatted text, with whitespace treated as significant)</a:documentation>
607
- </text>
608
- <ref name="callout">
609
- <a:documentation>Zero or more cross-references; these are intended to be embedded within the content string, and link to annotations</a:documentation>
610
- </ref>
611
- </choice>
612
- </oneOrMore>
602
+ <ref name="sourcecodebody">
603
+ <a:documentation>The sourcecode content</a:documentation>
604
+ </ref>
613
605
  <zeroOrMore>
614
606
  <ref name="annotation">
615
607
  <a:documentation>Annotations to the source code; each annotation consists of zero or more paragraphs,
@@ -628,17 +620,9 @@ and is intended to be referenced by a callout within the source code</a:document
628
620
  <a:documentation>The caption of the block</a:documentation>
629
621
  </ref>
630
622
  </optional>
631
- <oneOrMore>
632
- <choice>
633
- <text>
634
- <a:documentation>The computer code or other such text presented in the block, as a single unformatted string.
635
- (The string should be treated as pre-formatted text, with whitespace treated as significant)</a:documentation>
636
- </text>
637
- <ref name="callout">
638
- <a:documentation>Zero or more cross-references; these are intended to be embedded within the content string, and link to annotations</a:documentation>
639
- </ref>
640
- </choice>
641
- </oneOrMore>
623
+ <ref name="sourcecodebody">
624
+ <a:documentation>The sourcecode content</a:documentation>
625
+ </ref>
642
626
  <zeroOrMore>
643
627
  <ref name="annotation">
644
628
  <a:documentation>Annotations to the source code; each annotation consists of zero or more paragraphs,
@@ -651,6 +635,20 @@ and is intended to be referenced by a callout within the source code</a:document
651
635
  </ref>
652
636
  </zeroOrMore>
653
637
  </define>
638
+ <define name="sourcecodebody">
639
+ <a:documentation>The computer code or other such text presented in the block, as a single unformatted string.
640
+ (The string should be treated as pre-formatted text, with whitespace treated as significant)</a:documentation>
641
+ <element name="body">
642
+ <oneOrMore>
643
+ <choice>
644
+ <text/>
645
+ <ref name="callout">
646
+ <a:documentation>Zero or more cross-references; these are intended to be embedded within the content string, and link to annotations</a:documentation>
647
+ </ref>
648
+ </choice>
649
+ </oneOrMore>
650
+ </element>
651
+ </define>
654
652
  <define name="pre">
655
653
  <a:documentation>Pre-formatted block. Wrapper for text to be rendered with fixed-width typeface, and preserving spaces including line breaks.
656
654
  They are intended for a restricted number of functions, most typically ASCII Art (which is still in prominent use in some
@@ -1672,18 +1670,25 @@ which can be bookmarks as well as block or section references</a:documentation>
1672
1670
  </optional>
1673
1671
  </define>
1674
1672
  <define name="XrefBody">
1675
- <oneOrMore>
1676
- <ref name="PureTextElement">
1677
- <a:documentation>The textual content of the element. The `text` is what we wish to show the link as (e.g., the "content" of `&lt;xx&gt;my link text&lt;/xx&gt;`)</a:documentation>
1678
- </ref>
1679
- </oneOrMore>
1673
+ <a:documentation>The textual content of the element. The `text` is what we wish to show the link as (e.g., the "content" of `&lt;xx&gt;my link text&lt;/xx&gt;`)</a:documentation>
1674
+ <optional>
1675
+ <element name="display-text">
1676
+ <oneOrMore>
1677
+ <ref name="PureTextElement"/>
1678
+ </oneOrMore>
1679
+ </element>
1680
+ </optional>
1680
1681
  </define>
1681
1682
  <define name="ErefBody">
1682
- <oneOrMore>
1683
- <ref name="PureTextElement">
1684
- <a:documentation>The textual content of the element. The `text` is what we wish to show the link as (e.g., the "content" of `&lt;xx&gt;my link text&lt;/xx&gt;`)</a:documentation>
1685
- </ref>
1686
- </oneOrMore>
1683
+ <optional>
1684
+ <element name="display-text">
1685
+ <oneOrMore>
1686
+ <ref name="PureTextElement">
1687
+ <a:documentation>The textual content of the element. The `text` is what we wish to show the link as (e.g., the "content" of `&lt;xx&gt;my link text&lt;/xx&gt;`)</a:documentation>
1688
+ </ref>
1689
+ </oneOrMore>
1690
+ </element>
1691
+ </optional>
1687
1692
  </define>
1688
1693
  <define name="fn">
1689
1694
  <a:documentation>Inline reference to a paragraph or paragraphs, appearing as a footnote.
@@ -267,11 +267,11 @@ Detailed in https://www.relaton.org/model/creator/</a:documentation>
267
267
  <a:documentation>An identifier of the person according to an international identifier scheme</a:documentation>
268
268
  </ref>
269
269
  </zeroOrMore>
270
- <zeroOrMore>
270
+ <optional>
271
271
  <ref name="contact">
272
272
  <a:documentation>Contact information for the person, including URI, address, phone number, and email</a:documentation>
273
273
  </ref>
274
- </zeroOrMore>
274
+ </optional>
275
275
  </element>
276
276
  </define>
277
277
  <define name="fullname">
@@ -454,11 +454,11 @@ real names (if the person is named with a pseudonym or user name); previous lega
454
454
  <a:documentation>An identifier of the organization according to an international identifier scheme</a:documentation>
455
455
  </ref>
456
456
  </zeroOrMore>
457
- <zeroOrMore>
457
+ <optional>
458
458
  <ref name="contact">
459
459
  <a:documentation>Contact information for the organization, including address, phone number, and email</a:documentation>
460
460
  </ref>
461
- </zeroOrMore>
461
+ </optional>
462
462
  <optional>
463
463
  <ref name="logo">
464
464
  <a:documentation>A logo for the organization</a:documentation>
@@ -540,12 +540,18 @@ real names (if the person is named with a pseudonym or user name); previous lega
540
540
  <!-- TODO may change -->
541
541
  <define name="contact">
542
542
  <a:documentation>Contact information for a person or organization</a:documentation>
543
- <choice>
543
+ <zeroOrMore>
544
544
  <ref name="address"/>
545
+ </zeroOrMore>
546
+ <zeroOrMore>
545
547
  <ref name="phone"/>
548
+ </zeroOrMore>
549
+ <zeroOrMore>
546
550
  <ref name="email"/>
551
+ </zeroOrMore>
552
+ <zeroOrMore>
547
553
  <ref name="uri"/>
548
- </choice>
554
+ </zeroOrMore>
549
555
  </define>
550
556
  <define name="phone">
551
557
  <a:documentation>The phone number associated with a person or organization</a:documentation>
@@ -941,6 +947,8 @@ May be electronic (e.g. Twitter direct message, email) or voice (e.g. a remark m
941
947
  typically cited as "personal communication")</a:documentation>
942
948
  <value>conversation</value>
943
949
  <a:documentation>An exchange of messages between two or more persons. May be electronic (e.g. web chat) or voice (e.g. phone call)</a:documentation>
950
+ <value>collection</value>
951
+ <a:documentation>A compound resource consisting of other resources, which are themselves presupposed to have their type specified..</a:documentation>
944
952
  <value>misc</value>
945
953
  <a:documentation>Bibliographic type not adequately described in the foregoing</a:documentation>
946
954
  </choice>
@@ -1271,17 +1279,17 @@ for which this claim of validity is made, if applicable</a:documentation>
1271
1279
  </define>
1272
1280
  <define name="validityBegins">
1273
1281
  <element name="validityBegins">
1274
- <ref name="ISO8601DateTime"/>
1282
+ <ref name="ISO8601Date"/>
1275
1283
  </element>
1276
1284
  </define>
1277
1285
  <define name="validityEnds">
1278
1286
  <element name="validityEnds">
1279
- <ref name="ISO8601DateTime"/>
1287
+ <ref name="ISO8601Date"/>
1280
1288
  </element>
1281
1289
  </define>
1282
1290
  <define name="validityRevision">
1283
1291
  <element name="revision">
1284
- <ref name="ISO8601DateTime"/>
1292
+ <ref name="ISO8601Date"/>
1285
1293
  </element>
1286
1294
  </define>
1287
1295
  <define name="TypedTitleString">
@@ -13,13 +13,13 @@ module Metanorma
13
13
 
14
14
  register_for "generic"
15
15
 
16
- def xml_root_tag
17
- configuration.xml_root_tag || XML_ROOT_TAG
18
- end
19
-
20
- def xml_namespace
21
- configuration.document_namespace || XML_NAMESPACE
22
- end
16
+ #def xml_root_tag
17
+ #configuration.xml_root_tag || XML_ROOT_TAG
18
+ #end
19
+ #
20
+ #def xml_namespace
21
+ #configuration.document_namespace || XML_NAMESPACE
22
+ #end
23
23
 
24
24
  def baselocation(loc)
25
25
  loc.nil? and return nil
@@ -1,5 +1,5 @@
1
1
  <?xml version="1.0" encoding="UTF-8"?>
2
- <grammar ns='https://www.metanorma.org/ns/generic' xmlns="http://relaxng.org/ns/structure/1.0">
2
+ <grammar ns='https://www.metanorma.org/ns/standoc' xmlns="http://relaxng.org/ns/structure/1.0">
3
3
  <!--
4
4
  VERSION v1.2.1
5
5
  Currently we inherit from a namespaced grammar, isostandard. Until we inherit from isodoc,
@@ -8,34 +8,31 @@
8
8
  -->
9
9
  <include href="biblio-standoc.rng"/>
10
10
  <include href="isodoc.rng">
11
- <start>
12
- <ref name="generic-standard"/>
13
- </start>
11
+ <define name="standard-document">
12
+ <element name="metanorma">
13
+ <ref name="Root-Attributes"/>
14
+ <ref name="bibdata"/>
15
+ <zeroOrMore>
16
+ <ref name="termdocsource"/>
17
+ </zeroOrMore>
18
+ <optional>
19
+ <ref name="misccontainer"/>
20
+ </optional>
21
+ <optional>
22
+ <ref name="boilerplate"/>
23
+ </optional>
24
+ <ref name="preface"/>
25
+ <oneOrMore>
26
+ <ref name="sections"/>
27
+ </oneOrMore>
28
+ <zeroOrMore>
29
+ <ref name="annex"/>
30
+ </zeroOrMore>
31
+ <ref name="bibliography"/>
32
+ <zeroOrMore>
33
+ <ref name="indexsect"/>
34
+ </zeroOrMore>
35
+ </element>
36
+ </define>
14
37
  </include>
15
- <define name="generic-standard">
16
- <element name="generic-standard">
17
- <ref name="Root-Attributes"/>
18
- <ref name="bibdata"/>
19
- <zeroOrMore>
20
- <ref name="termdocsource"/>
21
- </zeroOrMore>
22
- <optional>
23
- <ref name="misccontainer"/>
24
- </optional>
25
- <optional>
26
- <ref name="boilerplate"/>
27
- </optional>
28
- <ref name="preface"/>
29
- <oneOrMore>
30
- <ref name="sections"/>
31
- </oneOrMore>
32
- <zeroOrMore>
33
- <ref name="annex"/>
34
- </zeroOrMore>
35
- <ref name="bibliography"/>
36
- <zeroOrMore>
37
- <ref name="indexsect"/>
38
- </zeroOrMore>
39
- </element>
40
- </define>
41
38
  </grammar>
@@ -17,7 +17,7 @@
17
17
  these elements; we just want one namespace for any child grammars
18
18
  of this.
19
19
  -->
20
- <!-- VERSION v1.4.1 -->
20
+ <!-- VERSION v2.0.0 -->
21
21
  <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">
22
22
  <include href="reqt.rng"/>
23
23
  <include href="basicdoc.rng">
@@ -245,23 +245,9 @@
245
245
  <a:documentation>The caption of the block</a:documentation>
246
246
  </ref>
247
247
  </optional>
248
- <oneOrMore>
249
- <choice>
250
- <text>
251
- <a:documentation>The computer code or other such text presented in the block, as a single unformatted string.
252
- (The string should be treated as pre-formatted text, with whitespace treated as significant)</a:documentation>
253
- </text>
254
- <ref name="callout">
255
- <a:documentation>Zero or more cross-references; these are intended to be embedded within the content string, and link to annotations</a:documentation>
256
- </ref>
257
- <ref name="xref">
258
- <a:documentation>Hyperlink of code segment to another part of the document</a:documentation>
259
- </ref>
260
- <ref name="eref">
261
- <a:documentation>Hyperlink of code segment to external bibliographic resource</a:documentation>
262
- </ref>
263
- </choice>
264
- </oneOrMore>
248
+ <ref name="sourcecodebody">
249
+ <a:documentation>The sourcecode content</a:documentation>
250
+ </ref>
265
251
  <zeroOrMore>
266
252
  <ref name="annotation">
267
253
  <a:documentation>Annotations to the source code; each annotation consists of zero or more paragraphs,
@@ -277,6 +263,26 @@ and is intended to be referenced by a callout within the source code</a:document
277
263
  <a:documentation>A source for the block</a:documentation>
278
264
  </ref>
279
265
  </define>
266
+ <define name="sourcecodebody">
267
+ <a:documentation>The computer code or other such text presented in the block, as a single unformatted string.
268
+ (The string should be treated as pre-formatted text, with whitespace treated as significant)</a:documentation>
269
+ <element name="body">
270
+ <oneOrMore>
271
+ <choice>
272
+ <text/>
273
+ <ref name="callout">
274
+ <a:documentation>Zero or more cross-references; these are intended to be embedded within the content string, and link to annotations</a:documentation>
275
+ </ref>
276
+ <ref name="xref">
277
+ <a:documentation>Hyperlink of code segment to another part of the document</a:documentation>
278
+ </ref>
279
+ <ref name="eref">
280
+ <a:documentation>Hyperlink of code segment to external bibliographic resource</a:documentation>
281
+ </ref>
282
+ </choice>
283
+ </oneOrMore>
284
+ </element>
285
+ </define>
280
286
  <define name="sections">
281
287
  <element name="sections">
282
288
  <oneOrMore>
@@ -459,11 +465,14 @@ gives an explicit page orientation</a:documentation>
459
465
  <a:documentation>Description of location in a reference, which can be combined with other locations in a single citation</a:documentation>
460
466
  </ref>
461
467
  </zeroOrMore>
462
- <zeroOrMore>
463
- <ref name="PureTextElement">
468
+ <optional>
469
+ <element name="display-text">
464
470
  <a:documentation>The textual content of the element. The `text` is what we wish to show the link as (e.g., the "content" of `&lt;xx&gt;my link text&lt;/xx&gt;`)</a:documentation>
465
- </ref>
466
- </zeroOrMore>
471
+ <oneOrMore>
472
+ <ref name="PureTextElement"/>
473
+ </oneOrMore>
474
+ </element>
475
+ </optional>
467
476
  </define>
468
477
  </include>
469
478
  <!-- end overrides -->
@@ -1205,10 +1214,13 @@ numbers</a:documentation>
1205
1214
  <value>presentation</value>
1206
1215
  </choice>
1207
1216
  </attribute>
1217
+ <attribute name="flavor">
1218
+ <a:documentation>Metanorma flavor, indicating SDO whose requiremnts the realisation aligns to</a:documentation>
1219
+ </attribute>
1208
1220
  </define>
1209
1221
  <define name="standard-document">
1210
1222
  <a:documentation>Representation of a standardisation document</a:documentation>
1211
- <element name="standard-document">
1223
+ <element name="metanorma">
1212
1224
  <ref name="Root-Attributes"/>
1213
1225
  <ref name="bibdata">
1214
1226
  <a:documentation>Bibliographic description of the document itself, expressed in the Relaton model</a:documentation>
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module Generic
3
- VERSION = "2.7.4".freeze
3
+ VERSION = "3.0.1".freeze
4
4
  end
5
5
  end
@@ -27,7 +27,7 @@ Gem::Specification.new do |spec|
27
27
  spec.require_paths = ["lib"]
28
28
  spec.required_ruby_version = Gem::Requirement.new(">= 3.1.0")
29
29
 
30
- spec.add_dependency "metanorma-standoc", "~> 2.10.2"
30
+ spec.add_dependency "metanorma-standoc", "~> 3.0.0"
31
31
 
32
32
  spec.add_development_dependency "debug"
33
33
  spec.add_development_dependency "equivalent-xml", "~> 0.6"
@@ -35,8 +35,9 @@ Gem::Specification.new do |spec|
35
35
  spec.add_development_dependency "guard-rspec", "~> 4.7"
36
36
  spec.add_development_dependency "rake", "~> 13.0"
37
37
  spec.add_development_dependency "rspec", "~> 3.6"
38
- spec.add_development_dependency "rubocop", "~> 1.5.2"
39
- spec.add_development_dependency "sassc", "2.4.0"
38
+ spec.add_development_dependency "rubocop", "~> 1"
39
+ spec.add_development_dependency "rubocop-performance"
40
+ spec.add_development_dependency "sassc-embedded", "~> 1"
40
41
  spec.add_development_dependency "simplecov", "~> 0.15"
41
42
  spec.add_development_dependency "timecop", "~> 0.9"
42
43
  spec.add_development_dependency "xml-c14n"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metanorma-generic
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.7.4
4
+ version: 3.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-12-10 00:00:00.000000000 Z
11
+ date: 2025-03-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: metanorma-standoc
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 2.10.2
19
+ version: 3.0.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 2.10.2
26
+ version: 3.0.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: debug
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -114,28 +114,42 @@ dependencies:
114
114
  requirements:
115
115
  - - "~>"
116
116
  - !ruby/object:Gem::Version
117
- version: 1.5.2
117
+ version: '1'
118
118
  type: :development
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
122
  - - "~>"
123
123
  - !ruby/object:Gem::Version
124
- version: 1.5.2
124
+ version: '1'
125
125
  - !ruby/object:Gem::Dependency
126
- name: sassc
126
+ name: rubocop-performance
127
127
  requirement: !ruby/object:Gem::Requirement
128
128
  requirements:
129
- - - '='
129
+ - - ">="
130
130
  - !ruby/object:Gem::Version
131
- version: 2.4.0
131
+ version: '0'
132
132
  type: :development
133
133
  prerelease: false
134
134
  version_requirements: !ruby/object:Gem::Requirement
135
135
  requirements:
136
- - - '='
136
+ - - ">="
137
+ - !ruby/object:Gem::Version
138
+ version: '0'
139
+ - !ruby/object:Gem::Dependency
140
+ name: sassc-embedded
141
+ requirement: !ruby/object:Gem::Requirement
142
+ requirements:
143
+ - - "~>"
144
+ - !ruby/object:Gem::Version
145
+ version: '1'
146
+ type: :development
147
+ prerelease: false
148
+ version_requirements: !ruby/object:Gem::Requirement
149
+ requirements:
150
+ - - "~>"
137
151
  - !ruby/object:Gem::Version
138
- version: 2.4.0
152
+ version: '1'
139
153
  - !ruby/object:Gem::Dependency
140
154
  name: simplecov
141
155
  requirement: !ruby/object:Gem::Requirement
@@ -240,7 +254,7 @@ homepage: https://github.com/metanorma/metanorma-generic
240
254
  licenses:
241
255
  - BSD-2-Clause
242
256
  metadata: {}
243
- post_install_message:
257
+ post_install_message:
244
258
  rdoc_options: []
245
259
  require_paths:
246
260
  - lib
@@ -255,8 +269,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
255
269
  - !ruby/object:Gem::Version
256
270
  version: '0'
257
271
  requirements: []
258
- rubygems_version: 3.3.27
259
- signing_key:
272
+ rubygems_version: 3.5.22
273
+ signing_key:
260
274
  specification_version: 4
261
275
  summary: Metanorma template gem for customisation.
262
276
  test_files: []