metanorma-nist 0.2.10 → 0.2.11

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: 5a26f12758a0930fa38d84162c26122ba2fadd5b519ebfaf5bc9b2df0d3008a4
4
- data.tar.gz: b89c1a6d17f7899ef7c4cd11700ed60d0c402ad891a679f3c96732f4c50088ee
3
+ metadata.gz: a899632e402df0dc79c98a92830e0f6ea5941e60c410504a34eceebea90a1b67
4
+ data.tar.gz: f5bbaa08e05325d217f978047318b6db8cb8f3c43975efd1f7e2d408e82d67dd
5
5
  SHA512:
6
- metadata.gz: 8bb15f1320bad6569a35f6a0d65791c3d12b9726f53cfcaf982157e19ded2e3e1c59c849b111174bd15bbb093723087db0d3722885968e911aab1bd121626807
7
- data.tar.gz: b06e45fd042adb8228c4c8ed75210547dab5fa45708ded8f7bb7c0d0fe83119773b8523b55b6373bcdae044420c376463b3e261279b14f2d89d90bce3c95b846
6
+ metadata.gz: '0699e2165c30e88fe51339a96a32dab112baba4fc59abd9c0a8c42af14a48965252ceb5c2fb6a021fbcdb2f953b4eb9ded1352bc16e64ef0310843b357f60f63'
7
+ data.tar.gz: 3d46db5e093e0f3507bf22ac24f1d259857865d9fc5b9d7f8c5ceae5fe4e5f4e234e9b67900645af0586f2fb5323dfc9dc432ee918edb8ff951e563db832f96f
@@ -638,9 +638,9 @@
638
638
  <zeroOrMore>
639
639
  <ref name="license"/>
640
640
  </zeroOrMore>
641
- <optional>
641
+ <zeroOrMore>
642
642
  <ref name="bclassification"/>
643
- </optional>
643
+ </zeroOrMore>
644
644
  <zeroOrMore>
645
645
  <ref name="bkeyword"/>
646
646
  </zeroOrMore>
@@ -119,12 +119,60 @@
119
119
  <zeroOrMore>
120
120
  <ref name="note"/>
121
121
  </zeroOrMore>
122
- <choice>
123
- <zeroOrMore>
122
+ <zeroOrMore>
123
+ <choice>
124
124
  <ref name="clause-hanging-paragraph-with-footnote"/>
125
- </zeroOrMore>
126
- <ref name="terms"/>
127
- </choice>
125
+ <ref name="terms"/>
126
+ <ref name="definitions"/>
127
+ <ref name="references"/>
128
+ </choice>
129
+ </zeroOrMore>
130
+ </element>
131
+ </define>
132
+ <define name="clause-hanging-paragraph-with-footnote">
133
+ <element name="clause">
134
+ <optional>
135
+ <attribute name="id">
136
+ <data type="ID"/>
137
+ </attribute>
138
+ </optional>
139
+ <optional>
140
+ <attribute name="language"/>
141
+ </optional>
142
+ <optional>
143
+ <attribute name="script"/>
144
+ </optional>
145
+ <optional>
146
+ <attribute name="inline-header">
147
+ <data type="boolean"/>
148
+ </attribute>
149
+ </optional>
150
+ <optional>
151
+ <attribute name="obligation">
152
+ <choice>
153
+ <value>normative</value>
154
+ <value>informative</value>
155
+ </choice>
156
+ </attribute>
157
+ </optional>
158
+ <optional>
159
+ <ref name="section-title"/>
160
+ </optional>
161
+ <zeroOrMore>
162
+ <!-- allow hanging paragraphs in annexes: they introduce lists -->
163
+ <ref name="BasicBlock"/>
164
+ </zeroOrMore>
165
+ <zeroOrMore>
166
+ <ref name="note"/>
167
+ </zeroOrMore>
168
+ <zeroOrMore>
169
+ <choice>
170
+ <ref name="clause-hanging-paragraph-with-footnote"/>
171
+ <ref name="terms"/>
172
+ <ref name="definitions"/>
173
+ <ref name="references"/>
174
+ </choice>
175
+ </zeroOrMore>
128
176
  </element>
129
177
  </define>
130
178
  <define name="BibDataExtensionType">
@@ -192,7 +240,9 @@
192
240
  <zeroOrMore>
193
241
  <ref name="annex"/>
194
242
  </zeroOrMore>
195
- <ref name="bibliography"/>
243
+ <optional>
244
+ <ref name="bibliography"/>
245
+ </optional>
196
246
  </element>
197
247
  </define>
198
248
  </grammar>
@@ -39,6 +39,12 @@
39
39
  <optional>
40
40
  <attribute name="filename"/>
41
41
  </optional>
42
+ <optional>
43
+ <attribute name="model"/>
44
+ </optional>
45
+ <optional>
46
+ <attribute name="type"/>
47
+ </optional>
42
48
  <optional>
43
49
  <ref name="reqtitle"/>
44
50
  </optional>
@@ -60,7 +60,7 @@ module IsoDoc
60
60
  def requirement_cleanup(docxml)
61
61
  docxml.xpath("//div[@class = 'recommend' or @class = 'require' "\
62
62
  "or @class = 'permission']").each do |d|
63
- title = d.at("./p[@class = 'AdmonitionTitle']") or next
63
+ title = d.at("./p[@class = 'RecommendationTitle']") or next
64
64
  title.name = "b"
65
65
  title.delete("class")
66
66
  n = title.next_element
@@ -135,6 +135,18 @@ span.nistvariable {
135
135
  margin: 2em 0 1em 0;
136
136
  }
137
137
 
138
+ .recommend {
139
+ @include recommendationBlock();
140
+ }
141
+
142
+ .require {
143
+ @include recommendationBlock();
144
+ }
145
+
146
+ .permission {
147
+ @include recommendationBlock();
148
+ }
149
+
138
150
 
139
151
  /* TYPOGRAPHY */
140
152
 
@@ -256,7 +256,7 @@ p.SourceTitle
256
256
  mso-fareast-font-family:$bodyfont;
257
257
  mso-bidi-font-family:$bodyfont;
258
258
  mso-ansi-language:EN-GB;}
259
- p.AdmonitionTitle
259
+ p.AdmonitionTitle, p.RecommendationTitle
260
260
  {mso-style-unhide:no;
261
261
  mso-style-qformat:yes;
262
262
  mso-style-parent:"";
@@ -215,7 +215,7 @@ p.SourceTitle
215
215
  mso-fareast-font-family:$bodyfont;
216
216
  mso-bidi-font-family:$bodyfont;
217
217
  mso-ansi-language:EN-GB;}
218
- p.AdmonitionTitle
218
+ p.AdmonitionTitle, p.RecommendationTitle
219
219
  {mso-style-unhide:no;
220
220
  mso-style-qformat:yes;
221
221
  mso-style-parent:"";
@@ -14,7 +14,7 @@ module IsoDoc
14
14
  end
15
15
 
16
16
  def convert1(docxml, filename, dir)
17
- @bibliographycount = docxml.xpath(ns("//bibliography/references | //annex/references | //bibliography/clause/references")).size
17
+ @bibliographycount = docxml.xpath(ns("//references")).size
18
18
  super
19
19
  end
20
20
 
@@ -129,8 +129,7 @@ module IsoDoc
129
129
  isoxml.xpath(ns("//bibliography/clause | //bibliography/references")).each do |f|
130
130
  out.div do |div|
131
131
  div.h1 **{ class: "Section3" } do |h1|
132
- if @bibliographycount == 1
133
- h1 << "References"
132
+ if @bibliographycount == 1 then h1 << "References"
134
133
  else
135
134
  f&.at(ns("./title"))&.children.each { |n| parse(n, h1) }
136
135
  end
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module NIST
3
- VERSION = "0.2.10"
3
+ VERSION = "0.2.11"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metanorma-nist
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.10
4
+ version: 0.2.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-12-24 00:00:00.000000000 Z
11
+ date: 2020-01-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: htmlentities
@@ -323,7 +323,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
323
323
  version: '0'
324
324
  requirements: []
325
325
  rubyforge_project:
326
- rubygems_version: 2.7.6
326
+ rubygems_version: 2.7.7
327
327
  signing_key:
328
328
  specification_version: 4
329
329
  summary: Metanorma NIST gem.