metanorma-ogc 2.8.4 → 2.8.5
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/lib/isodoc/ogc/init.rb +5 -3
- data/lib/isodoc/ogc/ogc.abstract-specification-topic.xsl +103 -111
- data/lib/isodoc/ogc/ogc.best-practice.xsl +103 -111
- data/lib/isodoc/ogc/ogc.change-request-supporting-document.xsl +103 -111
- data/lib/isodoc/ogc/ogc.community-practice.xsl +103 -111
- data/lib/isodoc/ogc/ogc.community-standard.xsl +103 -111
- data/lib/isodoc/ogc/ogc.discussion-paper.xsl +103 -111
- data/lib/isodoc/ogc/ogc.draft-standard.xsl +103 -111
- data/lib/isodoc/ogc/ogc.engineering-report.xsl +103 -111
- data/lib/isodoc/ogc/ogc.other.xsl +103 -111
- data/lib/isodoc/ogc/ogc.policy.xsl +103 -111
- data/lib/isodoc/ogc/ogc.reference-model.xsl +103 -111
- data/lib/isodoc/ogc/ogc.release-notes.xsl +103 -111
- data/lib/isodoc/ogc/ogc.standard.xsl +103 -111
- data/lib/isodoc/ogc/ogc.test-suite.xsl +103 -111
- data/lib/isodoc/ogc/ogc.user-guide.xsl +103 -111
- data/lib/isodoc/ogc/ogc.white-paper.xsl +39 -50
- data/lib/isodoc/ogc/presentation_sections.rb +1 -1
- data/lib/metanorma/ogc/cleanup.rb +17 -1
- data/lib/metanorma/ogc/converter.rb +31 -100
- data/lib/metanorma/ogc/sections.rb +110 -0
- data/lib/metanorma/ogc/version.rb +1 -1
- metadata +3 -2
@@ -156,67 +156,70 @@
|
|
156
156
|
</xsl:variable>
|
157
157
|
|
158
158
|
<xsl:variable name="toc_recommendations_">
|
159
|
-
<xsl:
|
160
|
-
<xsl:
|
161
|
-
|
162
|
-
<
|
163
|
-
|
164
|
-
<xsl:
|
165
|
-
|
166
|
-
<xsl:
|
167
|
-
|
168
|
-
<
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
<xsl:
|
175
|
-
|
176
|
-
<xsl:
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
<xsl:
|
186
|
-
|
187
|
-
|
188
|
-
<xsl:
|
189
|
-
<xsl:
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
<xsl:
|
203
|
-
|
204
|
-
|
205
|
-
<
|
206
|
-
|
207
|
-
|
208
|
-
<
|
209
|
-
|
210
|
-
|
211
|
-
|
159
|
+
<xsl:if test="//mn:metanorma/mn:metanorma-extension/mn:toc[@type='recommendation']/mn:title">
|
160
|
+
<xsl:for-each select="//mn:table[.//mn:p[@class = 'RecommendationTitle']]">
|
161
|
+
<xsl:variable name="table_id" select="@id"/>
|
162
|
+
<recommendation alt-text="{.//mn:p[@class = 'RecommendationTitle'][1]}">
|
163
|
+
<xsl:copy-of select="@id"/>
|
164
|
+
<xsl:variable name="title">
|
165
|
+
<xsl:apply-templates select=".//mn:p[@class = 'RecommendationTitle'][ancestor::mn:table[1][@id= $table_id]]/mn:fmt-name/node()"/>
|
166
|
+
<xsl:if test=".//mn:p[@class = 'RecommendationLabel'][ancestor::mn:table[1][@id= $table_id]]/node()">
|
167
|
+
<xsl:text>: </xsl:text>
|
168
|
+
<xsl:variable name="recommendationLabel">
|
169
|
+
<tt><xsl:copy-of select=".//mn:p[@class = 'RecommendationLabel'][ancestor::mn:table[1][@id= $table_id]]/mn:fmt-name/node()"/></tt>
|
170
|
+
</xsl:variable>
|
171
|
+
<xsl:apply-templates select="xalan:nodeset($recommendationLabel)/node()"/>
|
172
|
+
</xsl:if>
|
173
|
+
</xsl:variable>
|
174
|
+
<xsl:variable name="bookmark">
|
175
|
+
<xsl:value-of select="normalize-space(.//mn:p[@class = 'RecommendationTitle'][ancestor::mn:table[1][@id= $table_id]]/mn:fmt-name)"/>
|
176
|
+
<xsl:if test=".//mn:p[@class = 'RecommendationLabel'][ancestor::mn:table[1][@id= $table_id]]/node()">
|
177
|
+
<xsl:text>: </xsl:text>
|
178
|
+
<xsl:value-of select="normalize-space(.//mn:p[@class = 'RecommendationLabel'][ancestor::mn:table[1][@id= $table_id]]/mn:fmt-name)"/>
|
179
|
+
</xsl:if>
|
180
|
+
</xsl:variable>
|
181
|
+
<xsl:variable name="regex_str" select="'^([^0-9]+) (\d+).*'"/>
|
182
|
+
<xsl:variable name="class" select="java:replaceAll(java:java.lang.String.new($bookmark), $regex_str, '$1')"/>
|
183
|
+
<xsl:variable name="num" select="java:replaceAll(java:java.lang.String.new($bookmark), $regex_str, '$2')"/>
|
184
|
+
<xsl:variable name="class_lc" select="java:toLowerCase(java:java.lang.String.new($class))"/>
|
185
|
+
<!-- <xsl:attribute name="class_str">
|
186
|
+
<xsl:value-of select="$class"/>
|
187
|
+
</xsl:attribute> -->
|
188
|
+
<xsl:attribute name="class">
|
189
|
+
<xsl:choose>
|
190
|
+
<xsl:when test="$class_lc = 'requirements class'">1</xsl:when>
|
191
|
+
<xsl:when test="$class_lc = 'requirement'">2</xsl:when>
|
192
|
+
<xsl:when test="$class_lc = 'recommendation'">3</xsl:when>
|
193
|
+
<xsl:when test="$class_lc = 'permission'">4</xsl:when>
|
194
|
+
<xsl:when test="$class_lc = 'conformance class'">5</xsl:when>
|
195
|
+
<xsl:when test="$class_lc = 'abstract test'">6</xsl:when>
|
196
|
+
<xsl:when test="$class_lc = 'requirement test'">7</xsl:when>
|
197
|
+
<xsl:when test="$class_lc = 'recommendation test'">8</xsl:when>
|
198
|
+
<xsl:when test="$class_lc = 'permission test'">9</xsl:when>
|
199
|
+
<xsl:otherwise>9999</xsl:otherwise>
|
200
|
+
</xsl:choose>
|
201
|
+
</xsl:attribute>
|
202
|
+
<xsl:attribute name="num">
|
203
|
+
<xsl:value-of select="$num"/>
|
204
|
+
</xsl:attribute>
|
205
|
+
<title>
|
206
|
+
<xsl:copy-of select="$title"/>
|
207
|
+
</title>
|
208
|
+
<bookmark>
|
209
|
+
<xsl:value-of select="$bookmark"/>
|
210
|
+
</bookmark>
|
211
|
+
</recommendation>
|
212
|
+
</xsl:for-each>
|
213
|
+
</xsl:if>
|
212
214
|
</xsl:variable>
|
213
|
-
<xsl:variable name="
|
215
|
+
<xsl:variable name="toc_recommendations__">
|
214
216
|
<xsl:for-each select="xalan:nodeset($toc_recommendations_)/*">
|
215
217
|
<xsl:sort select="@class" data-type="number"/>
|
216
218
|
<xsl:sort select="@num" data-type="number"/>
|
217
219
|
<xsl:copy-of select="."/>
|
218
220
|
</xsl:for-each>
|
219
221
|
</xsl:variable>
|
222
|
+
<xsl:variable name="toc_recommendations" select="xalan:nodeset($toc_recommendations__)"/>
|
220
223
|
|
221
224
|
<xsl:variable name="contents_">
|
222
225
|
<mnx:contents>
|
@@ -226,9 +229,9 @@
|
|
226
229
|
<xsl:call-template name="processMainSectionsDefault_Contents"/>
|
227
230
|
<xsl:apply-templates select="//mn:indexsect" mode="contents"/>
|
228
231
|
|
229
|
-
<xsl:call-template name="processTablesFigures_Contents"
|
230
|
-
|
231
|
-
</xsl:call-template>
|
232
|
+
<xsl:call-template name="processTablesFigures_Contents"/>
|
233
|
+
<!-- <xsl:with-param name="always">true</xsl:with-param>
|
234
|
+
</xsl:call-template> -->
|
232
235
|
</mnx:contents>
|
233
236
|
</xsl:variable>
|
234
237
|
<xsl:variable name="contents" select="xalan:nodeset($contents_)"/>
|
@@ -298,7 +301,7 @@
|
|
298
301
|
<xsl:call-template name="addBookmarks">
|
299
302
|
<xsl:with-param name="contents" select="$contents"/>
|
300
303
|
<xsl:with-param name="contents_addon">
|
301
|
-
<xsl:if test="$contents//mnx:tables/mnx:table or $contents//mnx:figures/mnx:figure or
|
304
|
+
<xsl:if test="$contents//mnx:tables/mnx:table or $contents//mnx:figures/mnx:figure or $toc_recommendations/*[normalize-space(@id) != '']">
|
302
305
|
<fo:bookmark internal-destination="empty_bookmark">
|
303
306
|
<fo:bookmark-title>—————</fo:bookmark-title>
|
304
307
|
</fo:bookmark>
|
@@ -336,12 +339,12 @@
|
|
336
339
|
</fo:bookmark>
|
337
340
|
</xsl:if>
|
338
341
|
|
339
|
-
<xsl:if test="
|
342
|
+
<xsl:if test="$toc_recommendations/*[normalize-space(@id) != '']">
|
340
343
|
<fo:bookmark internal-destination="empty_bookmark" starting-state="hide">
|
341
344
|
<fo:bookmark-title>
|
342
345
|
<xsl:value-of select="$title-list-recommendations"/>
|
343
346
|
</fo:bookmark-title>
|
344
|
-
<xsl:for-each select="
|
347
|
+
<xsl:for-each select="$toc_recommendations/*[normalize-space(@id) != '']">
|
345
348
|
<fo:bookmark internal-destination="{@id}">
|
346
349
|
<fo:bookmark-title><xsl:value-of select="bookmark"/></fo:bookmark-title>
|
347
350
|
</fo:bookmark>
|
@@ -353,6 +356,8 @@
|
|
353
356
|
|
354
357
|
<xsl:call-template name="cover-page"/>
|
355
358
|
|
359
|
+
<xsl:call-template name="inner-cover-page"/>
|
360
|
+
|
356
361
|
<!-- Copyright, Content, Foreword, etc. pages -->
|
357
362
|
<fo:page-sequence master-reference="preface" initial-page-number="2" format="i" force-page-count="no-force">
|
358
363
|
<xsl:call-template name="insertFootnoteSeparator"/>
|
@@ -527,6 +532,8 @@
|
|
527
532
|
|
528
533
|
</xsl:for-each>
|
529
534
|
|
535
|
+
<xsl:call-template name="back-page"/>
|
536
|
+
|
530
537
|
</fo:root>
|
531
538
|
|
532
539
|
</xsl:template>
|
@@ -781,6 +788,12 @@
|
|
781
788
|
</fo:page-sequence>
|
782
789
|
</xsl:template> <!-- END: cover-page -->
|
783
790
|
|
791
|
+
<xsl:template name="inner-cover-page">
|
792
|
+
</xsl:template>
|
793
|
+
|
794
|
+
<xsl:template name="back-page">
|
795
|
+
</xsl:template>
|
796
|
+
|
784
797
|
<xsl:template name="processPrefaceAndMainSectionsOGC_items">
|
785
798
|
<xsl:variable name="updated_xml_step_move_pagebreak">
|
786
799
|
|
@@ -967,12 +980,12 @@
|
|
967
980
|
</xsl:if>
|
968
981
|
|
969
982
|
<!-- List of Recommendations -->
|
970
|
-
<xsl:if test="
|
983
|
+
<xsl:if test="$toc_recommendations/*[normalize-space(@id) != '']">
|
971
984
|
<xsl:call-template name="insertListOf_Title">
|
972
985
|
<xsl:with-param name="title" select="$title-list-recommendations"/>
|
973
986
|
</xsl:call-template>
|
974
987
|
<fo:block-container line-height="130%" role="TOC">
|
975
|
-
<xsl:for-each select="
|
988
|
+
<xsl:for-each select="$toc_recommendations/*[normalize-space(@id) != '']">
|
976
989
|
<fo:block text-align-last="justify" margin-top="6pt" role="TOCI">
|
977
990
|
<fo:basic-link internal-destination="{@id}">
|
978
991
|
<xsl:call-template name="setAltText">
|
@@ -3581,7 +3594,6 @@
|
|
3581
3594
|
</xsl:attribute-set> <!-- feedback-statement-title-style -->
|
3582
3595
|
|
3583
3596
|
<xsl:template name="refine_feedback-statement-title-style">
|
3584
|
-
|
3585
3597
|
</xsl:template>
|
3586
3598
|
|
3587
3599
|
<xsl:attribute-set name="feedback-statement-p-style">
|
@@ -9503,16 +9515,23 @@
|
|
9503
9515
|
</xsl:attribute-set> <!-- quote-style -->
|
9504
9516
|
|
9505
9517
|
<xsl:template name="refine_quote-style">
|
9506
|
-
</xsl:template>
|
9518
|
+
</xsl:template> <!-- refine_quote-style -->
|
9507
9519
|
|
9508
9520
|
<xsl:attribute-set name="quote-source-style">
|
9509
9521
|
<xsl:attribute name="text-align">right</xsl:attribute>
|
9510
9522
|
<xsl:attribute name="margin-right">25mm</xsl:attribute>
|
9511
|
-
</xsl:attribute-set>
|
9523
|
+
</xsl:attribute-set> <!-- quote-source-style -->
|
9512
9524
|
|
9513
9525
|
<xsl:template name="refine_quote-source-style">
|
9514
9526
|
</xsl:template>
|
9515
9527
|
|
9528
|
+
<xsl:attribute-set name="source-style">
|
9529
|
+
</xsl:attribute-set> <!-- source-style -->
|
9530
|
+
|
9531
|
+
<xsl:template name="refine_source-style">
|
9532
|
+
|
9533
|
+
</xsl:template> <!-- refine_source-style -->
|
9534
|
+
|
9516
9535
|
<!-- ====== -->
|
9517
9536
|
<!-- quote -->
|
9518
9537
|
<!-- source -->
|
@@ -9560,7 +9579,9 @@
|
|
9560
9579
|
</xsl:if>
|
9561
9580
|
<xsl:choose>
|
9562
9581
|
<xsl:when test="not(parent::quote)">
|
9563
|
-
<fo:block>
|
9582
|
+
<fo:block xsl:use-attribute-sets="source-style">
|
9583
|
+
<xsl:call-template name="refine_source-style"/>
|
9584
|
+
|
9564
9585
|
<xsl:call-template name="insert_basic_link">
|
9565
9586
|
<xsl:with-param name="element">
|
9566
9587
|
<fo:basic-link internal-destination="{@bibitemid}" fox:alt-text="{@citeas}">
|
@@ -11680,7 +11701,7 @@
|
|
11680
11701
|
|
11681
11702
|
<xsl:template name="refine_fn-reference-style">
|
11682
11703
|
<!-- https://github.com/metanorma/metanorma-ieee/issues/595 -->
|
11683
|
-
<xsl:if test="preceding-sibling::node()[normalize-space() != ''][1][self::mn:fn]"
|
11704
|
+
<xsl:if test="preceding-sibling::node()[normalize-space() != ''][1][self::mn:fn]">, </xsl:if><!-- <xsl:if test="$namespace = 'bsi' or $namespace = 'pas'"></xsl:if> -->
|
11684
11705
|
</xsl:template> <!-- refine_fn-reference-style -->
|
11685
11706
|
|
11686
11707
|
<xsl:attribute-set name="fn-style">
|
@@ -11691,6 +11712,7 @@
|
|
11691
11712
|
</xsl:template>
|
11692
11713
|
|
11693
11714
|
<xsl:attribute-set name="fn-num-style">
|
11715
|
+
<xsl:attribute name="role">Reference</xsl:attribute>
|
11694
11716
|
<xsl:attribute name="keep-with-previous.within-line">always</xsl:attribute>
|
11695
11717
|
<xsl:attribute name="font-size">65%</xsl:attribute>
|
11696
11718
|
<xsl:attribute name="vertical-align">super</xsl:attribute>
|
@@ -11767,33 +11789,16 @@
|
|
11767
11789
|
<xsl:variable name="ref_id" select="@target"/>
|
11768
11790
|
|
11769
11791
|
<xsl:variable name="footnote_inline">
|
11770
|
-
<fo:inline
|
11792
|
+
<fo:inline xsl:use-attribute-sets="fn-num-style">
|
11771
11793
|
|
11772
|
-
<xsl:
|
11773
|
-
<xsl:choose>
|
11774
|
-
<xsl:when test="ancestor::mn:bibitem">
|
11775
|
-
<fn_styles xsl:use-attribute-sets="bibitem-note-fn-style">
|
11776
|
-
<xsl:call-template name="refine_bibitem-note-fn-style"/>
|
11777
|
-
</fn_styles>
|
11778
|
-
</xsl:when>
|
11779
|
-
<xsl:otherwise>
|
11780
|
-
<fn_styles xsl:use-attribute-sets="fn-num-style">
|
11781
|
-
<xsl:call-template name="refine_fn-num-style"/>
|
11782
|
-
</fn_styles>
|
11783
|
-
</xsl:otherwise>
|
11784
|
-
</xsl:choose>
|
11785
|
-
</xsl:variable>
|
11786
|
-
|
11787
|
-
<xsl:for-each select="xalan:nodeset($fn_styles)/fn_styles/@*">
|
11788
|
-
<xsl:copy-of select="."/>
|
11789
|
-
</xsl:for-each>
|
11794
|
+
<xsl:call-template name="refine_fn-num-style"/>
|
11790
11795
|
|
11791
11796
|
<!-- https://github.com/metanorma/metanorma-ieee/issues/595 -->
|
11792
11797
|
<!-- <xsl:if test="following-sibling::node()[normalize-space() != ''][1][self::mn:fn]">
|
11793
11798
|
<xsl:attribute name="padding-right">0.5mm</xsl:attribute>
|
11794
11799
|
</xsl:if> -->
|
11795
11800
|
|
11796
|
-
<xsl:if test="preceding-sibling::node()[normalize-space() != ''][1][self::mn:fn]"
|
11801
|
+
<xsl:if test="preceding-sibling::node()[normalize-space() != ''][1][self::mn:fn]">, </xsl:if>
|
11797
11802
|
|
11798
11803
|
<xsl:call-template name="insert_basic_link">
|
11799
11804
|
<xsl:with-param name="element">
|
@@ -12109,30 +12114,6 @@
|
|
12109
12114
|
<xsl:template name="refine_bibitem-non-normative-list-body-style">
|
12110
12115
|
</xsl:template>
|
12111
12116
|
|
12112
|
-
<!-- footnote reference number for bibitem, in the text -->
|
12113
|
-
<xsl:attribute-set name="bibitem-note-fn-style">
|
12114
|
-
<xsl:attribute name="keep-with-previous.within-line">always</xsl:attribute>
|
12115
|
-
<xsl:attribute name="font-size">65%</xsl:attribute>
|
12116
|
-
<xsl:attribute name="vertical-align">super</xsl:attribute>
|
12117
|
-
</xsl:attribute-set> <!-- bibitem-note-fn-style -->
|
12118
|
-
|
12119
|
-
<xsl:template name="refine_bibitem-note-fn-style">
|
12120
|
-
</xsl:template>
|
12121
|
-
|
12122
|
-
<!-- footnote number on the page bottom -->
|
12123
|
-
<xsl:attribute-set name="bibitem-note-fn-number-style">
|
12124
|
-
<xsl:attribute name="keep-with-next.within-line">always</xsl:attribute>
|
12125
|
-
<xsl:attribute name="font-size">60%</xsl:attribute>
|
12126
|
-
<xsl:attribute name="vertical-align">super</xsl:attribute>
|
12127
|
-
</xsl:attribute-set> <!-- bibitem-note-fn-number-style -->
|
12128
|
-
|
12129
|
-
<!-- footnote body (text) on the page bottom -->
|
12130
|
-
<xsl:attribute-set name="bibitem-note-fn-body-style">
|
12131
|
-
<xsl:attribute name="font-size">10pt</xsl:attribute>
|
12132
|
-
<xsl:attribute name="margin-bottom">12pt</xsl:attribute>
|
12133
|
-
<xsl:attribute name="start-indent">0pt</xsl:attribute>
|
12134
|
-
</xsl:attribute-set> <!-- bibitem-note-fn-body-style -->
|
12135
|
-
|
12136
12117
|
<xsl:attribute-set name="references-non-normative-style">
|
12137
12118
|
<xsl:attribute name="line-height">120%</xsl:attribute>
|
12138
12119
|
</xsl:attribute-set> <!-- references-non-normative-style -->
|
@@ -14467,6 +14448,17 @@
|
|
14467
14448
|
</xsl:attribute-set>
|
14468
14449
|
|
14469
14450
|
<xsl:template name="refine_clause-style">
|
14451
|
+
<!-- commented for https://github.com/metanorma/metanorma-ribose/issues/421 -->
|
14452
|
+
<!-- <xsl:if test="$namespace = 'rsd'">
|
14453
|
+
<xsl:variable name="level">
|
14454
|
+
<xsl:call-template name="getLevel">
|
14455
|
+
<xsl:with-param name="depth" select="mn:fmt-title/@depth"/>
|
14456
|
+
</xsl:call-template>
|
14457
|
+
</xsl:variable>
|
14458
|
+
<xsl:if test="$level >= 4">
|
14459
|
+
<xsl:attribute name="margin-left">13mm</xsl:attribute>
|
14460
|
+
</xsl:if>
|
14461
|
+
</xsl:if> -->
|
14470
14462
|
</xsl:template>
|
14471
14463
|
|
14472
14464
|
<!-- main sections -->
|