metanorma-iho 0.6.13 → 0.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/isodoc/iho/iho.specification.xsl +83 -33
- data/lib/isodoc/iho/iho.standard.xsl +83 -33
- data/lib/metanorma/iho/basicdoc.rng +3 -0
- data/lib/metanorma/iho/isodoc.rng +1 -0
- data/lib/metanorma/iho/version.rb +1 -1
- data/metanorma-iho.gemspec +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1340067bd6efc8f1651dabb526b2ec76dd66335b5a66a61db8343029c1ee8a8b
|
4
|
+
data.tar.gz: 154d9df5ac5eb11ac659b9eec41cb8ed76b03ae22bad9e5decf59eb7773475ea
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9183c1385f0914009343d4d81db0f18f4bf44a8f1902589d49dc544fc67eba4ec34c5275046b76400ca347eeafbacf0178d9d5fb4b6e1fdc93df1be327885f5a
|
7
|
+
data.tar.gz: a9675063b1b0b1fd5fa793a2b4c0a1b802a586fe08d60151cb890f6228a9317b0c3d7beacace2ed16dcc929781262757d8bc6a130c7016e0a8f2f6825e52cc2b
|
@@ -335,29 +335,32 @@
|
|
335
335
|
|
336
336
|
<!-- Document Pages -->
|
337
337
|
|
338
|
-
<
|
339
|
-
|
340
|
-
|
341
|
-
|
342
|
-
|
343
|
-
|
344
|
-
|
345
|
-
|
346
|
-
<
|
338
|
+
<xsl:if test="/iho:iho-standard/iho:sections/*">
|
339
|
+
|
340
|
+
<fo:page-sequence master-reference="document" initial-page-number="1" format="1" force-page-count="no-force">
|
341
|
+
<fo:static-content flow-name="xsl-footnote-separator">
|
342
|
+
<fo:block>
|
343
|
+
<fo:leader leader-pattern="rule" leader-length="30%"/>
|
344
|
+
</fo:block>
|
345
|
+
</fo:static-content>
|
346
|
+
<xsl:call-template name="insertHeaderFooter"/>
|
347
|
+
<fo:flow flow-name="xsl-region-body">
|
348
|
+
<fo:block-container>
|
347
349
|
|
348
|
-
|
350
|
+
<!-- <fo:block font-size="16pt" font-weight="bold" margin-bottom="18pt" role="H1"><xsl:value-of select="$title-en"/></fo:block> -->
|
349
351
|
|
350
|
-
|
351
|
-
|
352
|
-
|
353
|
-
|
354
|
-
|
355
|
-
|
356
|
-
|
352
|
+
<xsl:apply-templates select="/*/*[local-name()='sections']/*[local-name()='clause'][@type='scope']"/>
|
353
|
+
<!-- Normative references -->
|
354
|
+
<xsl:apply-templates select="/*/*[local-name()='bibliography']/*[local-name()='references'][@normative='true']"/>
|
355
|
+
<!-- Terms and definitions -->
|
356
|
+
<xsl:apply-templates select="/*/*[local-name()='sections']/*[local-name()='terms']"/>
|
357
|
+
<xsl:apply-templates select="/*/*[local-name()='sections']/*[local-name()='definitions']"/>
|
358
|
+
<xsl:apply-templates select="/*/*[local-name()='sections']/*[local-name() != 'terms' and local-name() != 'definitions' and not(@type='scope')]"/>
|
357
359
|
|
358
|
-
|
359
|
-
|
360
|
-
|
360
|
+
</fo:block-container>
|
361
|
+
</fo:flow>
|
362
|
+
</fo:page-sequence>
|
363
|
+
</xsl:if>
|
361
364
|
|
362
365
|
<xsl:if test="/iho:iho-standard/iho:annex">
|
363
366
|
<fo:page-sequence master-reference="document">
|
@@ -484,6 +487,10 @@
|
|
484
487
|
|
485
488
|
</xsl:template>
|
486
489
|
|
490
|
+
<xsl:template match="*[local-name() = 'strong']" mode="contents_item" priority="2">
|
491
|
+
<xsl:apply-templates mode="contents_item"/>
|
492
|
+
</xsl:template>
|
493
|
+
|
487
494
|
<!-- ============================= -->
|
488
495
|
<!-- END CONTENTS -->
|
489
496
|
<!-- ============================= -->
|
@@ -3443,6 +3450,10 @@
|
|
3443
3450
|
<xsl:variable name="footnote_inline">
|
3444
3451
|
<fo:inline xsl:use-attribute-sets="fn-num-style">
|
3445
3452
|
|
3453
|
+
<xsl:if test="following-sibling::*[1][local-name() = 'fn']">
|
3454
|
+
<xsl:attribute name="padding-right">0.5mm</xsl:attribute>
|
3455
|
+
</xsl:if>
|
3456
|
+
|
3446
3457
|
<fo:basic-link internal-destination="{$ref_id}" fox:alt-text="footnote {$current_fn_number}">
|
3447
3458
|
<xsl:value-of select="$current_fn_number_text"/>
|
3448
3459
|
</fo:basic-link>
|
@@ -4667,6 +4678,23 @@
|
|
4667
4678
|
<xsl:apply-templates/>
|
4668
4679
|
</xsl:template>
|
4669
4680
|
|
4681
|
+
<!-- Don't break standard's numbers -->
|
4682
|
+
<!-- Example : <span class="stdpublisher">ISO</span> <span class="stddocNumber">10303</span>-<span class="stddocPartNumber">1</span>:<span class="stdyear">1994</span> -->
|
4683
|
+
<xsl:template match="*[local-name() = 'span'][@class = 'stdpublisher' or @class = 'stddocNumber' or @class = 'stddocPartNumber' or @class = 'stdyear']" priority="2">
|
4684
|
+
<xsl:choose>
|
4685
|
+
<xsl:when test="ancestor::*[local-name() = 'table']"><xsl:apply-templates/></xsl:when>
|
4686
|
+
<xsl:when test="following-sibling::*[2][local-name() = 'span'][@class = 'stdpublisher' or @class = 'stddocNumber' or @class = 'stddocPartNumber' or @class = 'stdyear']">
|
4687
|
+
<fo:inline keep-with-next.within-line="always"><xsl:apply-templates/></fo:inline>
|
4688
|
+
</xsl:when>
|
4689
|
+
<xsl:otherwise>
|
4690
|
+
<xsl:apply-templates/>
|
4691
|
+
</xsl:otherwise>
|
4692
|
+
</xsl:choose>
|
4693
|
+
</xsl:template>
|
4694
|
+
<xsl:template match="text()[not(ancestor::*[local-name() = 'table']) and preceding-sibling::*[1][local-name() = 'span'][@class = 'stdpublisher' or @class = 'stddocNumber' or @class = 'stddocPartNumber' or @class = 'stdyear'] and following-sibling::*[1][local-name() = 'span'][@class = 'stdpublisher' or @class = 'stddocNumber' or @class = 'stddocPartNumber' or @class = 'stdyear']]" priority="2">
|
4695
|
+
<fo:inline keep-with-next.within-line="always"><xsl:value-of select="."/></fo:inline>
|
4696
|
+
</xsl:template>
|
4697
|
+
|
4670
4698
|
<!-- ========================= -->
|
4671
4699
|
<!-- END Rich text formatting -->
|
4672
4700
|
<!-- ========================= -->
|
@@ -5062,7 +5090,7 @@
|
|
5062
5090
|
<xsl:choose>
|
5063
5091
|
<xsl:when test="@colspan">
|
5064
5092
|
<xsl:variable name="td">
|
5065
|
-
<xsl:element name="
|
5093
|
+
<xsl:element name="{local-name()}">
|
5066
5094
|
<xsl:attribute name="divide"><xsl:value-of select="@colspan"/></xsl:attribute>
|
5067
5095
|
<xsl:if test="local-name()='th'">
|
5068
5096
|
<xsl:attribute name="font-weight">bold</xsl:attribute>
|
@@ -5077,7 +5105,7 @@
|
|
5077
5105
|
</xsl:call-template>
|
5078
5106
|
</xsl:when>
|
5079
5107
|
<xsl:otherwise>
|
5080
|
-
<xsl:element name="
|
5108
|
+
<xsl:element name="{local-name()}">
|
5081
5109
|
<xsl:apply-templates select="@*" mode="simple-table-colspan"/>
|
5082
5110
|
<xsl:if test="local-name()='th'">
|
5083
5111
|
<xsl:attribute name="font-weight">bold</xsl:attribute>
|
@@ -5144,7 +5172,7 @@
|
|
5144
5172
|
<xsl:variable name="currentRow" select="."/>
|
5145
5173
|
|
5146
5174
|
<xsl:variable name="normalizedTDs">
|
5147
|
-
<xsl:for-each select="xalan:nodeset($previousRow)
|
5175
|
+
<xsl:for-each select="xalan:nodeset($previousRow)//*[self::td or self::th]">
|
5148
5176
|
<xsl:choose>
|
5149
5177
|
<xsl:when test="@rowspan > 1">
|
5150
5178
|
<xsl:copy>
|
@@ -5156,7 +5184,7 @@
|
|
5156
5184
|
</xsl:copy>
|
5157
5185
|
</xsl:when>
|
5158
5186
|
<xsl:otherwise>
|
5159
|
-
<xsl:copy-of select="$currentRow
|
5187
|
+
<xsl:copy-of select="$currentRow/*[self::td or self::th][1 + count(current()/preceding-sibling::*[self::td or self::th][not(@rowspan) or (@rowspan = 1)])]"/>
|
5160
5188
|
</xsl:otherwise>
|
5161
5189
|
</xsl:choose>
|
5162
5190
|
</xsl:for-each>
|
@@ -5826,12 +5854,6 @@
|
|
5826
5854
|
|
5827
5855
|
<fo:block-container margin-left="0mm">
|
5828
5856
|
|
5829
|
-
<!-- <xsl:if test="$namespace = 'iho'">
|
5830
|
-
<xsl:if test="ancestor::iho:td">
|
5831
|
-
<xsl:attribute name="font-size">12pt</xsl:attribute>
|
5832
|
-
</xsl:if>
|
5833
|
-
</xsl:if> -->
|
5834
|
-
|
5835
5857
|
<fo:block>
|
5836
5858
|
|
5837
5859
|
<fo:inline xsl:use-attribute-sets="note-name-style">
|
@@ -6335,6 +6357,31 @@
|
|
6335
6357
|
<xsl:apply-templates mode="svg_update"/>
|
6336
6358
|
</xsl:copy>
|
6337
6359
|
</xsl:template>
|
6360
|
+
|
6361
|
+
<!-- regex for 'display: inline-block;' -->
|
6362
|
+
<xsl:variable name="regex_svg_style_notsupported">display(\s|\h)*:(\s|\h)*inline-block(\s|\h)*;</xsl:variable>
|
6363
|
+
<xsl:template match="*[local-name() = 'svg']//*[local-name() = 'style']/text()" mode="svg_update">
|
6364
|
+
<xsl:value-of select="java:replaceAll(java:java.lang.String.new(.), $regex_svg_style_notsupported, '')"/>
|
6365
|
+
</xsl:template>
|
6366
|
+
|
6367
|
+
<!-- replace
|
6368
|
+
stroke="rgba(r, g, b, alpha)" to
|
6369
|
+
stroke="rgb(r,g,b)" stroke-opacity="alpha", and
|
6370
|
+
fill="rgba(r, g, b, alpha)" to
|
6371
|
+
fill="rgb(r,g,b)" fill-opacity="alpha" -->
|
6372
|
+
<xsl:template match="@*[local-name() = 'stroke' or local-name() = 'fill'][starts-with(normalize-space(.), 'rgba')]" mode="svg_update">
|
6373
|
+
<xsl:variable name="components_">
|
6374
|
+
<xsl:call-template name="split">
|
6375
|
+
<xsl:with-param name="pText" select="substring-before(substring-after(., '('), ')')"/>
|
6376
|
+
<xsl:with-param name="sep" select="','"/>
|
6377
|
+
</xsl:call-template>
|
6378
|
+
</xsl:variable>
|
6379
|
+
<xsl:variable name="components" select="xalan:nodeset($components_)"/>
|
6380
|
+
<xsl:variable name="att_name" select="local-name()"/>
|
6381
|
+
<xsl:attribute name="{$att_name}"><xsl:value-of select="concat('rgb(', $components/item[1], ',', $components/item[2], ',', $components/item[3], ')')"/></xsl:attribute>
|
6382
|
+
<xsl:attribute name="{$att_name}-opacity"><xsl:value-of select="$components/item[4]"/></xsl:attribute>
|
6383
|
+
</xsl:template>
|
6384
|
+
|
6338
6385
|
<!-- ============== -->
|
6339
6386
|
<!-- END: svg_update -->
|
6340
6387
|
<!-- ============== -->
|
@@ -6977,7 +7024,7 @@
|
|
6977
7024
|
<xsl:element name="sourcecode_attributes" use-attribute-sets="sourcecode-style">
|
6978
7025
|
<xsl:variable name="_font-size">
|
6979
7026
|
|
6980
|
-
|
7027
|
+
9.5
|
6981
7028
|
<!-- 9 -->
|
6982
7029
|
|
6983
7030
|
<!-- <xsl:if test="$namespace = 'ieee'">
|
@@ -9247,7 +9294,9 @@
|
|
9247
9294
|
<!-- Update xml -->
|
9248
9295
|
<!-- ===================================== -->
|
9249
9296
|
<!-- =========================================================================== -->
|
9250
|
-
<!-- STEP1:
|
9297
|
+
<!-- STEP1: -->
|
9298
|
+
<!-- - Re-order elements in 'preface', 'sections' based on @displayorder -->
|
9299
|
+
<!-- - Ignore 'span' without style -->
|
9251
9300
|
<!-- =========================================================================== -->
|
9252
9301
|
<xsl:template match="@*|node()" mode="update_xml_step1">
|
9253
9302
|
<xsl:copy>
|
@@ -9330,7 +9379,8 @@
|
|
9330
9379
|
</xsl:copy>
|
9331
9380
|
</xsl:template>
|
9332
9381
|
|
9333
|
-
|
9382
|
+
<!-- Example with 'class': <span class="stdpublisher">ISO</span> <span class="stddocNumber">10303</span>-<span class="stddocPartNumber">1</span>:<span class="stdyear">1994</span> -->
|
9383
|
+
<xsl:template match="*[local-name() = 'span'][@style or @class = 'stdpublisher' or @class = 'stddocNumber' or @class = 'stddocPartNumber' or @class = 'stdyear']" mode="update_xml_step1" priority="2">
|
9334
9384
|
<xsl:copy>
|
9335
9385
|
<xsl:copy-of select="@*"/>
|
9336
9386
|
<xsl:apply-templates mode="update_xml_step1"/>
|
@@ -335,29 +335,32 @@
|
|
335
335
|
|
336
336
|
<!-- Document Pages -->
|
337
337
|
|
338
|
-
<
|
339
|
-
|
340
|
-
|
341
|
-
|
342
|
-
|
343
|
-
|
344
|
-
|
345
|
-
|
346
|
-
<
|
338
|
+
<xsl:if test="/iho:iho-standard/iho:sections/*">
|
339
|
+
|
340
|
+
<fo:page-sequence master-reference="document" initial-page-number="1" format="1" force-page-count="no-force">
|
341
|
+
<fo:static-content flow-name="xsl-footnote-separator">
|
342
|
+
<fo:block>
|
343
|
+
<fo:leader leader-pattern="rule" leader-length="30%"/>
|
344
|
+
</fo:block>
|
345
|
+
</fo:static-content>
|
346
|
+
<xsl:call-template name="insertHeaderFooter"/>
|
347
|
+
<fo:flow flow-name="xsl-region-body">
|
348
|
+
<fo:block-container>
|
347
349
|
|
348
|
-
|
350
|
+
<!-- <fo:block font-size="16pt" font-weight="bold" margin-bottom="18pt" role="H1"><xsl:value-of select="$title-en"/></fo:block> -->
|
349
351
|
|
350
|
-
|
351
|
-
|
352
|
-
|
353
|
-
|
354
|
-
|
355
|
-
|
356
|
-
|
352
|
+
<xsl:apply-templates select="/*/*[local-name()='sections']/*[local-name()='clause'][@type='scope']"/>
|
353
|
+
<!-- Normative references -->
|
354
|
+
<xsl:apply-templates select="/*/*[local-name()='bibliography']/*[local-name()='references'][@normative='true']"/>
|
355
|
+
<!-- Terms and definitions -->
|
356
|
+
<xsl:apply-templates select="/*/*[local-name()='sections']/*[local-name()='terms']"/>
|
357
|
+
<xsl:apply-templates select="/*/*[local-name()='sections']/*[local-name()='definitions']"/>
|
358
|
+
<xsl:apply-templates select="/*/*[local-name()='sections']/*[local-name() != 'terms' and local-name() != 'definitions' and not(@type='scope')]"/>
|
357
359
|
|
358
|
-
|
359
|
-
|
360
|
-
|
360
|
+
</fo:block-container>
|
361
|
+
</fo:flow>
|
362
|
+
</fo:page-sequence>
|
363
|
+
</xsl:if>
|
361
364
|
|
362
365
|
<xsl:if test="/iho:iho-standard/iho:annex">
|
363
366
|
<fo:page-sequence master-reference="document">
|
@@ -484,6 +487,10 @@
|
|
484
487
|
|
485
488
|
</xsl:template>
|
486
489
|
|
490
|
+
<xsl:template match="*[local-name() = 'strong']" mode="contents_item" priority="2">
|
491
|
+
<xsl:apply-templates mode="contents_item"/>
|
492
|
+
</xsl:template>
|
493
|
+
|
487
494
|
<!-- ============================= -->
|
488
495
|
<!-- END CONTENTS -->
|
489
496
|
<!-- ============================= -->
|
@@ -3443,6 +3450,10 @@
|
|
3443
3450
|
<xsl:variable name="footnote_inline">
|
3444
3451
|
<fo:inline xsl:use-attribute-sets="fn-num-style">
|
3445
3452
|
|
3453
|
+
<xsl:if test="following-sibling::*[1][local-name() = 'fn']">
|
3454
|
+
<xsl:attribute name="padding-right">0.5mm</xsl:attribute>
|
3455
|
+
</xsl:if>
|
3456
|
+
|
3446
3457
|
<fo:basic-link internal-destination="{$ref_id}" fox:alt-text="footnote {$current_fn_number}">
|
3447
3458
|
<xsl:value-of select="$current_fn_number_text"/>
|
3448
3459
|
</fo:basic-link>
|
@@ -4667,6 +4678,23 @@
|
|
4667
4678
|
<xsl:apply-templates/>
|
4668
4679
|
</xsl:template>
|
4669
4680
|
|
4681
|
+
<!-- Don't break standard's numbers -->
|
4682
|
+
<!-- Example : <span class="stdpublisher">ISO</span> <span class="stddocNumber">10303</span>-<span class="stddocPartNumber">1</span>:<span class="stdyear">1994</span> -->
|
4683
|
+
<xsl:template match="*[local-name() = 'span'][@class = 'stdpublisher' or @class = 'stddocNumber' or @class = 'stddocPartNumber' or @class = 'stdyear']" priority="2">
|
4684
|
+
<xsl:choose>
|
4685
|
+
<xsl:when test="ancestor::*[local-name() = 'table']"><xsl:apply-templates/></xsl:when>
|
4686
|
+
<xsl:when test="following-sibling::*[2][local-name() = 'span'][@class = 'stdpublisher' or @class = 'stddocNumber' or @class = 'stddocPartNumber' or @class = 'stdyear']">
|
4687
|
+
<fo:inline keep-with-next.within-line="always"><xsl:apply-templates/></fo:inline>
|
4688
|
+
</xsl:when>
|
4689
|
+
<xsl:otherwise>
|
4690
|
+
<xsl:apply-templates/>
|
4691
|
+
</xsl:otherwise>
|
4692
|
+
</xsl:choose>
|
4693
|
+
</xsl:template>
|
4694
|
+
<xsl:template match="text()[not(ancestor::*[local-name() = 'table']) and preceding-sibling::*[1][local-name() = 'span'][@class = 'stdpublisher' or @class = 'stddocNumber' or @class = 'stddocPartNumber' or @class = 'stdyear'] and following-sibling::*[1][local-name() = 'span'][@class = 'stdpublisher' or @class = 'stddocNumber' or @class = 'stddocPartNumber' or @class = 'stdyear']]" priority="2">
|
4695
|
+
<fo:inline keep-with-next.within-line="always"><xsl:value-of select="."/></fo:inline>
|
4696
|
+
</xsl:template>
|
4697
|
+
|
4670
4698
|
<!-- ========================= -->
|
4671
4699
|
<!-- END Rich text formatting -->
|
4672
4700
|
<!-- ========================= -->
|
@@ -5062,7 +5090,7 @@
|
|
5062
5090
|
<xsl:choose>
|
5063
5091
|
<xsl:when test="@colspan">
|
5064
5092
|
<xsl:variable name="td">
|
5065
|
-
<xsl:element name="
|
5093
|
+
<xsl:element name="{local-name()}">
|
5066
5094
|
<xsl:attribute name="divide"><xsl:value-of select="@colspan"/></xsl:attribute>
|
5067
5095
|
<xsl:if test="local-name()='th'">
|
5068
5096
|
<xsl:attribute name="font-weight">bold</xsl:attribute>
|
@@ -5077,7 +5105,7 @@
|
|
5077
5105
|
</xsl:call-template>
|
5078
5106
|
</xsl:when>
|
5079
5107
|
<xsl:otherwise>
|
5080
|
-
<xsl:element name="
|
5108
|
+
<xsl:element name="{local-name()}">
|
5081
5109
|
<xsl:apply-templates select="@*" mode="simple-table-colspan"/>
|
5082
5110
|
<xsl:if test="local-name()='th'">
|
5083
5111
|
<xsl:attribute name="font-weight">bold</xsl:attribute>
|
@@ -5144,7 +5172,7 @@
|
|
5144
5172
|
<xsl:variable name="currentRow" select="."/>
|
5145
5173
|
|
5146
5174
|
<xsl:variable name="normalizedTDs">
|
5147
|
-
<xsl:for-each select="xalan:nodeset($previousRow)
|
5175
|
+
<xsl:for-each select="xalan:nodeset($previousRow)//*[self::td or self::th]">
|
5148
5176
|
<xsl:choose>
|
5149
5177
|
<xsl:when test="@rowspan > 1">
|
5150
5178
|
<xsl:copy>
|
@@ -5156,7 +5184,7 @@
|
|
5156
5184
|
</xsl:copy>
|
5157
5185
|
</xsl:when>
|
5158
5186
|
<xsl:otherwise>
|
5159
|
-
<xsl:copy-of select="$currentRow
|
5187
|
+
<xsl:copy-of select="$currentRow/*[self::td or self::th][1 + count(current()/preceding-sibling::*[self::td or self::th][not(@rowspan) or (@rowspan = 1)])]"/>
|
5160
5188
|
</xsl:otherwise>
|
5161
5189
|
</xsl:choose>
|
5162
5190
|
</xsl:for-each>
|
@@ -5826,12 +5854,6 @@
|
|
5826
5854
|
|
5827
5855
|
<fo:block-container margin-left="0mm">
|
5828
5856
|
|
5829
|
-
<!-- <xsl:if test="$namespace = 'iho'">
|
5830
|
-
<xsl:if test="ancestor::iho:td">
|
5831
|
-
<xsl:attribute name="font-size">12pt</xsl:attribute>
|
5832
|
-
</xsl:if>
|
5833
|
-
</xsl:if> -->
|
5834
|
-
|
5835
5857
|
<fo:block>
|
5836
5858
|
|
5837
5859
|
<fo:inline xsl:use-attribute-sets="note-name-style">
|
@@ -6335,6 +6357,31 @@
|
|
6335
6357
|
<xsl:apply-templates mode="svg_update"/>
|
6336
6358
|
</xsl:copy>
|
6337
6359
|
</xsl:template>
|
6360
|
+
|
6361
|
+
<!-- regex for 'display: inline-block;' -->
|
6362
|
+
<xsl:variable name="regex_svg_style_notsupported">display(\s|\h)*:(\s|\h)*inline-block(\s|\h)*;</xsl:variable>
|
6363
|
+
<xsl:template match="*[local-name() = 'svg']//*[local-name() = 'style']/text()" mode="svg_update">
|
6364
|
+
<xsl:value-of select="java:replaceAll(java:java.lang.String.new(.), $regex_svg_style_notsupported, '')"/>
|
6365
|
+
</xsl:template>
|
6366
|
+
|
6367
|
+
<!-- replace
|
6368
|
+
stroke="rgba(r, g, b, alpha)" to
|
6369
|
+
stroke="rgb(r,g,b)" stroke-opacity="alpha", and
|
6370
|
+
fill="rgba(r, g, b, alpha)" to
|
6371
|
+
fill="rgb(r,g,b)" fill-opacity="alpha" -->
|
6372
|
+
<xsl:template match="@*[local-name() = 'stroke' or local-name() = 'fill'][starts-with(normalize-space(.), 'rgba')]" mode="svg_update">
|
6373
|
+
<xsl:variable name="components_">
|
6374
|
+
<xsl:call-template name="split">
|
6375
|
+
<xsl:with-param name="pText" select="substring-before(substring-after(., '('), ')')"/>
|
6376
|
+
<xsl:with-param name="sep" select="','"/>
|
6377
|
+
</xsl:call-template>
|
6378
|
+
</xsl:variable>
|
6379
|
+
<xsl:variable name="components" select="xalan:nodeset($components_)"/>
|
6380
|
+
<xsl:variable name="att_name" select="local-name()"/>
|
6381
|
+
<xsl:attribute name="{$att_name}"><xsl:value-of select="concat('rgb(', $components/item[1], ',', $components/item[2], ',', $components/item[3], ')')"/></xsl:attribute>
|
6382
|
+
<xsl:attribute name="{$att_name}-opacity"><xsl:value-of select="$components/item[4]"/></xsl:attribute>
|
6383
|
+
</xsl:template>
|
6384
|
+
|
6338
6385
|
<!-- ============== -->
|
6339
6386
|
<!-- END: svg_update -->
|
6340
6387
|
<!-- ============== -->
|
@@ -6977,7 +7024,7 @@
|
|
6977
7024
|
<xsl:element name="sourcecode_attributes" use-attribute-sets="sourcecode-style">
|
6978
7025
|
<xsl:variable name="_font-size">
|
6979
7026
|
|
6980
|
-
|
7027
|
+
9.5
|
6981
7028
|
<!-- 9 -->
|
6982
7029
|
|
6983
7030
|
<!-- <xsl:if test="$namespace = 'ieee'">
|
@@ -9247,7 +9294,9 @@
|
|
9247
9294
|
<!-- Update xml -->
|
9248
9295
|
<!-- ===================================== -->
|
9249
9296
|
<!-- =========================================================================== -->
|
9250
|
-
<!-- STEP1:
|
9297
|
+
<!-- STEP1: -->
|
9298
|
+
<!-- - Re-order elements in 'preface', 'sections' based on @displayorder -->
|
9299
|
+
<!-- - Ignore 'span' without style -->
|
9251
9300
|
<!-- =========================================================================== -->
|
9252
9301
|
<xsl:template match="@*|node()" mode="update_xml_step1">
|
9253
9302
|
<xsl:copy>
|
@@ -9330,7 +9379,8 @@
|
|
9330
9379
|
</xsl:copy>
|
9331
9380
|
</xsl:template>
|
9332
9381
|
|
9333
|
-
|
9382
|
+
<!-- Example with 'class': <span class="stdpublisher">ISO</span> <span class="stddocNumber">10303</span>-<span class="stddocPartNumber">1</span>:<span class="stdyear">1994</span> -->
|
9383
|
+
<xsl:template match="*[local-name() = 'span'][@style or @class = 'stdpublisher' or @class = 'stddocNumber' or @class = 'stddocPartNumber' or @class = 'stdyear']" mode="update_xml_step1" priority="2">
|
9334
9384
|
<xsl:copy>
|
9335
9385
|
<xsl:copy-of select="@*"/>
|
9336
9386
|
<xsl:apply-templates mode="update_xml_step1"/>
|
data/metanorma-iho.gemspec
CHANGED
@@ -27,7 +27,7 @@ Gem::Specification.new do |spec|
|
|
27
27
|
spec.require_paths = ["lib"]
|
28
28
|
spec.required_ruby_version = Gem::Requirement.new(">= 2.7.0")
|
29
29
|
|
30
|
-
spec.add_dependency "metanorma-generic", "~> 2.
|
30
|
+
spec.add_dependency "metanorma-generic", "~> 2.3.0"
|
31
31
|
|
32
32
|
spec.add_development_dependency "debug"
|
33
33
|
spec.add_development_dependency "equivalent-xml", "~> 0.6"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-iho
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.7.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-12-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: metanorma-generic
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 2.
|
19
|
+
version: 2.3.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.
|
26
|
+
version: 2.3.0
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: debug
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -247,7 +247,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
247
247
|
- !ruby/object:Gem::Version
|
248
248
|
version: '0'
|
249
249
|
requirements: []
|
250
|
-
rubygems_version: 3.3.
|
250
|
+
rubygems_version: 3.3.26
|
251
251
|
signing_key:
|
252
252
|
specification_version: 4
|
253
253
|
summary: metanorma-iho lets you write IHO in AsciiDoc.
|