metanorma-bipm 2.5.10 → 2.5.11

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: b54e4575b187a3b6c3bb568788f70b027f29840db9e12d5597473d218a9ad1c8
4
- data.tar.gz: c388b7c9ce1cb0f67ec1491c95658b3a6e92f0de5c7557b049122f0fe52547c4
3
+ metadata.gz: 3d4aed7bcf0822c30f0867a36b7aa34948699aaba20087ddb9e05030ab9953a5
4
+ data.tar.gz: 225e3d0e17616b6e1902611712a275a121fe2107705bd9b65c502cb9030aeb8b
5
5
  SHA512:
6
- metadata.gz: 148a5f5f5f9d85bbca594bb95a5c3853994c062d0d4d30bf4990433ff1a0ef766eb35474236dbe28bdf7a25d1c9fcc37e47a90230de0ea5b070dbaec1f2ee547
7
- data.tar.gz: e9888cd28e1c21033621d2e448ef9c2a6f2ae9af115fb14fff6b9abbb115ee0fa4824ffbfac5def55d350ed5f7dd0167285da5e203c92d09b540cad44b034372
6
+ metadata.gz: 6bbcac2628c54b9c84a5129efa6f2cf5698d77be0df9e546bdb9773a770699b1909adc1fd773b95ebf21b6323ce41c0e8fba90f3167c63c5921e4ccf146a92a2
7
+ data.tar.gz: e995196ed4fa98671bd41f6da45e3f1a1972f2262fef54727e9244be62dff4b71c88ea5b8b93607f9d830970d9e4794d9bfc6b7f766d9f0402f6b1e80ad8730f
@@ -5186,6 +5186,9 @@
5186
5186
 
5187
5187
  </xsl:attribute-set>
5188
5188
 
5189
+ <xsl:attribute-set name="related-block-style" use-attribute-sets="preferred-block-style">
5190
+ </xsl:attribute-set>
5191
+
5189
5192
  <xsl:attribute-set name="definition-style">
5190
5193
 
5191
5194
  </xsl:attribute-set>
@@ -7484,7 +7487,9 @@
7484
7487
  <xsl:with-param name="element">
7485
7488
  <fo:basic-link internal-destination="{$ref_id}" fox:alt-text="footnote {$current_fn_number}"> <!-- note: role="Lbl" removed in https://github.com/metanorma/mn2pdf/issues/291 -->
7486
7489
  <fo:inline role="Lbl"> <!-- need for https://github.com/metanorma/metanorma-iso/issues/1003 -->
7490
+
7487
7491
  <xsl:copy-of select="$current_fn_number_text"/>
7492
+
7488
7493
  </fo:inline>
7489
7494
  </fo:basic-link>
7490
7495
  </xsl:with-param>
@@ -7503,8 +7508,7 @@
7503
7508
 
7504
7509
  <fo:block-container xsl:use-attribute-sets="fn-container-body-style" role="SKIP">
7505
7510
 
7506
- <fo:block xsl:use-attribute-sets="fn-body-style" role="SKIP">
7507
-
7511
+ <xsl:variable name="fn_block">
7508
7512
  <xsl:call-template name="refine_fn-body-style"/>
7509
7513
 
7510
7514
  <fo:inline id="{$ref_id}" xsl:use-attribute-sets="fn-body-num-style" role="Lbl">
@@ -7512,9 +7516,15 @@
7512
7516
  <xsl:call-template name="refine_fn-body-num-style"/>
7513
7517
 
7514
7518
  <xsl:value-of select="$current_fn_number_text"/>
7519
+
7515
7520
  </fo:inline>
7516
7521
  <xsl:apply-templates/>
7517
- </fo:block>
7522
+ </xsl:variable>
7523
+
7524
+ <fo:block xsl:use-attribute-sets="fn-body-style" role="SKIP">
7525
+ <xsl:copy-of select="$fn_block"/>
7526
+ </fo:block>
7527
+
7518
7528
  </fo:block-container>
7519
7529
  </fo:footnote-body>
7520
7530
  </fo:footnote>
@@ -13625,14 +13635,17 @@
13625
13635
  </fo:block>
13626
13636
  </xsl:template>
13627
13637
 
13628
- <xsl:template match="*[local-name() = 'domain']">
13638
+ <!-- <xsl:template match="*[local-name() = 'domain']"> -->
13629
13639
  <!-- https://github.com/metanorma/isodoc/issues/607
13630
13640
  <fo:inline xsl:use-attribute-sets="domain-style">&lt;<xsl:apply-templates/>&gt;</fo:inline>
13631
13641
  <xsl:text> </xsl:text> -->
13632
- <xsl:if test="not(@hidden = 'true')">
13642
+ <!-- <xsl:if test="not(@hidden = 'true')">
13633
13643
  <xsl:apply-templates/>
13634
13644
  </xsl:if>
13635
- </xsl:template>
13645
+ </xsl:template> -->
13646
+
13647
+ <!-- https://github.com/metanorma/isodoc/issues/632#issuecomment-2567163931 -->
13648
+ <xsl:template match="*[local-name() = 'domain']"/>
13636
13649
 
13637
13650
  <xsl:template match="*[local-name() = 'admitted']">
13638
13651
  <fo:block xsl:use-attribute-sets="admitted-style">
@@ -13647,9 +13660,11 @@
13647
13660
  </xsl:template>
13648
13661
 
13649
13662
  <xsl:template name="setStyle_preferred">
13650
- <xsl:if test="*[local-name() = 'strong']">
13651
- <xsl:attribute name="font-weight">normal</xsl:attribute>
13652
- </xsl:if>
13663
+
13664
+ <xsl:if test="*[local-name() = 'strong']">
13665
+ <xsl:attribute name="font-weight">normal</xsl:attribute>
13666
+ </xsl:if>
13667
+
13653
13668
  </xsl:template>
13654
13669
 
13655
13670
  <!-- regarding ISO 10241-1:2011, If there is more than one preferred term, each preferred term follows the previous one on a new line. -->
@@ -13659,6 +13674,17 @@
13659
13674
  </xsl:template>
13660
13675
  <!-- End Preferred, admitted, deprecated -->
13661
13676
 
13677
+ <xsl:template match="*[local-name() = 'fmt-related']">
13678
+ <fo:block role="SKIP" xsl:use-attribute-sets="related-block-style">
13679
+ <xsl:apply-templates/>
13680
+ </fo:block>
13681
+ </xsl:template>
13682
+ <xsl:template match="*[local-name() = 'fmt-related']/*[local-name() = 'p']" priority="4">
13683
+ <fo:block>
13684
+ <xsl:apply-templates/>
13685
+ </fo:block>
13686
+ </xsl:template>
13687
+
13662
13688
  <!-- ========== -->
13663
13689
  <!-- definition -->
13664
13690
  <!-- ========== -->
@@ -14564,6 +14590,7 @@
14564
14590
 
14565
14591
  <!-- Normative references -->
14566
14592
  <xsl:template match="*[local-name() = 'references'][@normative='true']/*[local-name() = 'bibitem']" name="bibitem" priority="2">
14593
+ <xsl:param name="skip" select="normalize-space(preceding-sibling::*[1][local-name() = 'bibitem'] and 1 = 1)"/> <!-- current bibiitem is non-first -->
14567
14594
 
14568
14595
  <fo:block id="{@id}" xsl:use-attribute-sets="bibitem-normative-style">
14569
14596
 
@@ -15279,7 +15306,8 @@
15279
15306
  <!-- add @id - first element with @id plus '_element_name' -->
15280
15307
  <xsl:variable name="prefix_id_" select="(.//*[@id])[1]/@id"/>
15281
15308
  <xsl:variable name="prefix_id"><xsl:value-of select="$prefix_id_"/><xsl:if test="normalize-space($prefix_id_) = ''"><xsl:value-of select="generate-id()"/></xsl:if></xsl:variable>
15282
- <xsl:attribute name="id"><xsl:value-of select="$prefix_id"/>_<xsl:value-of select="local-name()"/></xsl:attribute>
15309
+ <xsl:variable name="document_suffix" select="ancestor::*[contains(local-name(), '-standard')]/@document_suffix"/>
15310
+ <xsl:attribute name="id"><xsl:value-of select="concat($prefix_id, '_', local-name(), '_', $document_suffix)"/></xsl:attribute>
15283
15311
  </xsl:if>
15284
15312
  </xsl:template>
15285
15313
 
@@ -15336,6 +15364,31 @@
15336
15364
  <xsl:template match="*[local-name() = 'name'][following-sibling::*[1][local-name() = 'fmt-name']]" mode="update_xml_pres"/>
15337
15365
  <xsl:template match="*[local-name() = 'section-title'][following-sibling::*[1][local-name() = 'p'][@type = 'section-title' or @type = 'floating-title']]" mode="update_xml_step1"/>
15338
15366
  <xsl:template match="*[local-name() = 'section-title'][following-sibling::*[1][local-name() = 'p'][@type = 'section-title' or @type = 'floating-title']]" mode="update_xml_pres"/>
15367
+ <!-- <xsl:template match="*[local-name() = 'preferred'][following-sibling::*[not(local-name() = 'preferred')][1][local-name() = 'fmt-preferred']]" mode="update_xml_step1"/> -->
15368
+ <xsl:template match="*[local-name() = 'preferred']" mode="update_xml_step1"/>
15369
+ <!-- <xsl:template match="*[local-name() = 'preferred'][following-sibling::*[not(local-name() = 'preferred')][1][local-name() = 'fmt-preferred']]" mode="update_xml_pres"/> -->
15370
+ <xsl:template match="*[local-name() = 'preferred']" mode="update_xml_pres"/>
15371
+ <!-- <xsl:template match="*[local-name() = 'admitted'][following-sibling::*[not(local-name() = 'admitted')][1][local-name() = 'fmt-admitted']]" mode="update_xml_step1"/> -->
15372
+ <xsl:template match="*[local-name() = 'admitted']" mode="update_xml_step1"/>
15373
+ <!-- <xsl:template match="*[local-name() = 'admitted'][following-sibling::*[not(local-name() = 'admitted')][1][local-name() = 'fmt-admitted']]" mode="update_xml_pres"/> -->
15374
+ <xsl:template match="*[local-name() = 'admitted']" mode="update_xml_pres"/>
15375
+ <!-- <xsl:template match="*[local-name() = 'deprecates'][following-sibling::*[not(local-name() = 'deprecates')][1][local-name() = 'fmt-deprecates']]" mode="update_xml_step1"/> -->
15376
+ <xsl:template match="*[local-name() = 'deprecates']" mode="update_xml_step1"/>
15377
+ <xsl:template match="*[local-name() = 'related']" mode="update_xml_step1"/>
15378
+ <!-- <xsl:template match="*[local-name() = 'deprecates'][following-sibling::*[not(local-name() = 'deprecates')][1][local-name() = 'fmt-deprecates']]" mode="update_xml_pres"/> -->
15379
+ <xsl:template match="*[local-name() = 'deprecates']" mode="update_xml_pres"/>
15380
+ <xsl:template match="*[local-name() = 'related']" mode="update_xml_pres"/>
15381
+ <!-- <xsl:template match="*[local-name() = 'definition'][following-sibling::*[1][local-name() = 'fmt-definition']]" mode="update_xml_step1"/> -->
15382
+ <xsl:template match="*[local-name() = 'definition']" mode="update_xml_step1"/>
15383
+ <!-- <xsl:template match="*[local-name() = 'definition'][following-sibling::*[1][local-name() = 'fmt-definition']]" mode="update_xml_pres"/> -->
15384
+ <xsl:template match="*[local-name() = 'definition']" mode="update_xml_pres"/>
15385
+ <!-- <xsl:template match="*[local-name() = 'termsource'][following-sibling::*[1][local-name() = 'fmt-termsource']]" mode="update_xml_step1"/> -->
15386
+ <xsl:template match="*[local-name() = 'termsource']" mode="update_xml_step1"/>
15387
+ <!-- <xsl:template match="*[local-name() = 'termsource'][following-sibling::*[1][local-name() = 'fmt-termsource']]" mode="update_xml_pres"/> -->
15388
+ <xsl:template match="*[local-name() = 'termsource']" mode="update_xml_pres"/>
15389
+
15390
+ <xsl:template match="*[local-name() = 'term'][@unnumbered = 'true'][not(.//*[starts-with(local-name(), 'fmt-')])]" mode="update_xml_step1"/>
15391
+ <xsl:template match="*[local-name() = 'term'][@unnumbered = 'true'][not(.//*[starts-with(local-name(), 'fmt-')])]" mode="update_xml_pres"/>
15339
15392
 
15340
15393
  <xsl:template match="*[local-name() = 'p'][@type = 'section-title' or @type = 'floating-title'][preceding-sibling::*[1][local-name() = 'section-title']]" mode="update_xml_step1">
15341
15394
  <xsl:copy>
@@ -15380,6 +15433,94 @@
15380
15433
  </xsl:element>
15381
15434
  </xsl:template>
15382
15435
 
15436
+ <xsl:template match="*[local-name() = 'fmt-preferred']"/>
15437
+ <xsl:template match="*[local-name() = 'fmt-preferred'][*[local-name() = 'p']]" mode="update_xml_step1">
15438
+ <xsl:apply-templates mode="update_xml_step1"/>
15439
+ </xsl:template>
15440
+ <xsl:template match="*[local-name() = 'fmt-preferred'][not(*[local-name() = 'p'])] | *[local-name() = 'fmt-preferred']/*[local-name() = 'p']" mode="update_xml_step1">
15441
+ <xsl:element name="preferred" namespace="{$namespace_full}">
15442
+ <xsl:copy-of select="@*"/>
15443
+ <xsl:apply-templates mode="update_xml_step1"/>
15444
+ </xsl:element>
15445
+ </xsl:template>
15446
+ <xsl:template match="*[local-name() = 'fmt-preferred'][*[local-name() = 'p']]" mode="update_xml_pres">
15447
+ <xsl:apply-templates mode="update_xml_pres"/>
15448
+ </xsl:template>
15449
+ <xsl:template match="*[local-name() = 'fmt-preferred'][not(*[local-name() = 'p'])] | *[local-name() = 'fmt-preferred']/*[local-name() = 'p']" mode="update_xml_pres">
15450
+ <xsl:element name="preferred" namespace="{$namespace_full}">
15451
+ <xsl:copy-of select="@*"/>
15452
+ <xsl:apply-templates mode="update_xml_pres"/>
15453
+ </xsl:element>
15454
+ </xsl:template>
15455
+
15456
+ <xsl:template match="*[local-name() = 'fmt-admitted']"/>
15457
+ <xsl:template match="*[local-name() = 'fmt-admitted'][*[local-name() = 'p']]" mode="update_xml_step1">
15458
+ <xsl:apply-templates mode="update_xml_step1"/>
15459
+ </xsl:template>
15460
+ <xsl:template match="*[local-name() = 'fmt-admitted'][not(*[local-name() = 'p'])] | *[local-name() = 'fmt-admitted']/*[local-name() = 'p']" mode="update_xml_step1">
15461
+ <xsl:element name="admitted" namespace="{$namespace_full}">
15462
+ <xsl:copy-of select="@*"/>
15463
+ <xsl:apply-templates mode="update_xml_step1"/>
15464
+ </xsl:element>
15465
+ </xsl:template>
15466
+ <xsl:template match="*[local-name() = 'fmt-admitted'][*[local-name() = 'p']]" mode="update_xml_pres">
15467
+ <xsl:apply-templates mode="update_xml_pres"/>
15468
+ </xsl:template>
15469
+ <xsl:template match="*[local-name() = 'fmt-admitted'][not(*[local-name() = 'p'])] | *[local-name() = 'fmt-admitted']/*[local-name() = 'p']" mode="update_xml_pres">
15470
+ <xsl:element name="admitted" namespace="{$namespace_full}">
15471
+ <xsl:copy-of select="@*"/>
15472
+ <xsl:apply-templates mode="update_xml_pres"/>
15473
+ </xsl:element>
15474
+ </xsl:template>
15475
+
15476
+ <xsl:template match="*[local-name() = 'fmt-deprecates']"/>
15477
+ <xsl:template match="*[local-name() = 'fmt-deprecates'][*[local-name() = 'p']]" mode="update_xml_step1">
15478
+ <xsl:apply-templates mode="update_xml_step1"/>
15479
+ </xsl:template>
15480
+ <xsl:template match="*[local-name() = 'fmt-deprecates'][not(*[local-name() = 'p'])] | *[local-name() = 'fmt-deprecates']/*[local-name() = 'p']" mode="update_xml_step1">
15481
+ <xsl:element name="deprecates" namespace="{$namespace_full}">
15482
+ <xsl:copy-of select="@*"/>
15483
+ <xsl:apply-templates mode="update_xml_step1"/>
15484
+ </xsl:element>
15485
+ </xsl:template>
15486
+ <xsl:template match="*[local-name() = 'fmt-deprecates'][*[local-name() = 'p']]" mode="update_xml_pres">
15487
+ <xsl:apply-templates mode="update_xml_pres"/>
15488
+ </xsl:template>
15489
+ <xsl:template match="*[local-name() = 'fmt-deprecates'][not(*[local-name() = 'p'])] | *[local-name() = 'fmt-deprecates']/*[local-name() = 'p']" mode="update_xml_pres">
15490
+ <xsl:element name="deprecates" namespace="{$namespace_full}">
15491
+ <xsl:copy-of select="@*"/>
15492
+ <xsl:apply-templates mode="update_xml_pres"/>
15493
+ </xsl:element>
15494
+ </xsl:template>
15495
+
15496
+ <xsl:template match="*[local-name() = 'fmt-definition']"/>
15497
+ <xsl:template match="*[local-name() = 'fmt-definition']" mode="update_xml_step1">
15498
+ <xsl:element name="definition" namespace="{$namespace_full}">
15499
+ <xsl:copy-of select="@*"/>
15500
+ <xsl:apply-templates mode="update_xml_step1"/>
15501
+ </xsl:element>
15502
+ </xsl:template>
15503
+ <xsl:template match="*[local-name() = 'fmt-definition']" mode="update_xml_pres">
15504
+ <xsl:element name="definition" namespace="{$namespace_full}">
15505
+ <xsl:copy-of select="@*"/>
15506
+ <xsl:apply-templates mode="update_xml_pres"/>
15507
+ </xsl:element>
15508
+ </xsl:template>
15509
+
15510
+ <xsl:template match="*[local-name() = 'fmt-termsource']"/>
15511
+ <xsl:template match="*[local-name() = 'fmt-termsource']" mode="update_xml_step1">
15512
+ <xsl:element name="termsource" namespace="{$namespace_full}">
15513
+ <xsl:copy-of select="@*"/>
15514
+ <xsl:apply-templates mode="update_xml_step1"/>
15515
+ </xsl:element>
15516
+ </xsl:template>
15517
+ <xsl:template match="*[local-name() = 'fmt-termsource']" mode="update_xml_pres">
15518
+ <xsl:element name="termsource" namespace="{$namespace_full}">
15519
+ <xsl:copy-of select="@*"/>
15520
+ <xsl:apply-templates mode="update_xml_pres"/>
15521
+ </xsl:element>
15522
+ </xsl:template>
15523
+
15383
15524
  <xsl:template match="*[local-name() = 'span'][ @class = 'fmt-caption-label' or @class = 'fmt-element-name' or @class = 'fmt-caption-delim' or @class = 'fmt-autonum-delim']" mode="update_xml_step1" priority="3">
15384
15525
  <xsl:apply-templates mode="update_xml_step1"/>
15385
15526
  </xsl:template>
@@ -16518,7 +16659,7 @@
16518
16659
  </xsl:template>
16519
16660
 
16520
16661
  <xsl:template name="namespaceCheck">
16521
- <xsl:variable name="documentNS" select="namespace-uri(/*)"/>
16662
+ <xsl:variable name="documentNS" select="$namespace_full"/> <!-- namespace-uri(/*) -->
16522
16663
  <xsl:variable name="XSLNS">
16523
16664
 
16524
16665
  <xsl:value-of select="document('')//*/namespace::bipm"/>
@@ -16608,6 +16749,9 @@
16608
16749
  <xsl:when test="$formatted = 'true' and string-length($bibdata_updated) != ''">
16609
16750
  <xsl:apply-templates select="xalan:nodeset($bibdata_updated)//*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang]"/>
16610
16751
  </xsl:when>
16752
+ <xsl:when test="string-length($bibdata_updated) != ''">
16753
+ <xsl:value-of select="xalan:nodeset($bibdata_updated)//*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang]"/>
16754
+ </xsl:when>
16611
16755
  <xsl:when test="$formatted = 'true'">
16612
16756
  <xsl:apply-templates select="xalan:nodeset($bibdata)//*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang]"/>
16613
16757
  </xsl:when>
@@ -5186,6 +5186,9 @@
5186
5186
 
5187
5187
  </xsl:attribute-set>
5188
5188
 
5189
+ <xsl:attribute-set name="related-block-style" use-attribute-sets="preferred-block-style">
5190
+ </xsl:attribute-set>
5191
+
5189
5192
  <xsl:attribute-set name="definition-style">
5190
5193
 
5191
5194
  </xsl:attribute-set>
@@ -7484,7 +7487,9 @@
7484
7487
  <xsl:with-param name="element">
7485
7488
  <fo:basic-link internal-destination="{$ref_id}" fox:alt-text="footnote {$current_fn_number}"> <!-- note: role="Lbl" removed in https://github.com/metanorma/mn2pdf/issues/291 -->
7486
7489
  <fo:inline role="Lbl"> <!-- need for https://github.com/metanorma/metanorma-iso/issues/1003 -->
7490
+
7487
7491
  <xsl:copy-of select="$current_fn_number_text"/>
7492
+
7488
7493
  </fo:inline>
7489
7494
  </fo:basic-link>
7490
7495
  </xsl:with-param>
@@ -7503,8 +7508,7 @@
7503
7508
 
7504
7509
  <fo:block-container xsl:use-attribute-sets="fn-container-body-style" role="SKIP">
7505
7510
 
7506
- <fo:block xsl:use-attribute-sets="fn-body-style" role="SKIP">
7507
-
7511
+ <xsl:variable name="fn_block">
7508
7512
  <xsl:call-template name="refine_fn-body-style"/>
7509
7513
 
7510
7514
  <fo:inline id="{$ref_id}" xsl:use-attribute-sets="fn-body-num-style" role="Lbl">
@@ -7512,9 +7516,15 @@
7512
7516
  <xsl:call-template name="refine_fn-body-num-style"/>
7513
7517
 
7514
7518
  <xsl:value-of select="$current_fn_number_text"/>
7519
+
7515
7520
  </fo:inline>
7516
7521
  <xsl:apply-templates/>
7517
- </fo:block>
7522
+ </xsl:variable>
7523
+
7524
+ <fo:block xsl:use-attribute-sets="fn-body-style" role="SKIP">
7525
+ <xsl:copy-of select="$fn_block"/>
7526
+ </fo:block>
7527
+
7518
7528
  </fo:block-container>
7519
7529
  </fo:footnote-body>
7520
7530
  </fo:footnote>
@@ -13625,14 +13635,17 @@
13625
13635
  </fo:block>
13626
13636
  </xsl:template>
13627
13637
 
13628
- <xsl:template match="*[local-name() = 'domain']">
13638
+ <!-- <xsl:template match="*[local-name() = 'domain']"> -->
13629
13639
  <!-- https://github.com/metanorma/isodoc/issues/607
13630
13640
  <fo:inline xsl:use-attribute-sets="domain-style">&lt;<xsl:apply-templates/>&gt;</fo:inline>
13631
13641
  <xsl:text> </xsl:text> -->
13632
- <xsl:if test="not(@hidden = 'true')">
13642
+ <!-- <xsl:if test="not(@hidden = 'true')">
13633
13643
  <xsl:apply-templates/>
13634
13644
  </xsl:if>
13635
- </xsl:template>
13645
+ </xsl:template> -->
13646
+
13647
+ <!-- https://github.com/metanorma/isodoc/issues/632#issuecomment-2567163931 -->
13648
+ <xsl:template match="*[local-name() = 'domain']"/>
13636
13649
 
13637
13650
  <xsl:template match="*[local-name() = 'admitted']">
13638
13651
  <fo:block xsl:use-attribute-sets="admitted-style">
@@ -13647,9 +13660,11 @@
13647
13660
  </xsl:template>
13648
13661
 
13649
13662
  <xsl:template name="setStyle_preferred">
13650
- <xsl:if test="*[local-name() = 'strong']">
13651
- <xsl:attribute name="font-weight">normal</xsl:attribute>
13652
- </xsl:if>
13663
+
13664
+ <xsl:if test="*[local-name() = 'strong']">
13665
+ <xsl:attribute name="font-weight">normal</xsl:attribute>
13666
+ </xsl:if>
13667
+
13653
13668
  </xsl:template>
13654
13669
 
13655
13670
  <!-- regarding ISO 10241-1:2011, If there is more than one preferred term, each preferred term follows the previous one on a new line. -->
@@ -13659,6 +13674,17 @@
13659
13674
  </xsl:template>
13660
13675
  <!-- End Preferred, admitted, deprecated -->
13661
13676
 
13677
+ <xsl:template match="*[local-name() = 'fmt-related']">
13678
+ <fo:block role="SKIP" xsl:use-attribute-sets="related-block-style">
13679
+ <xsl:apply-templates/>
13680
+ </fo:block>
13681
+ </xsl:template>
13682
+ <xsl:template match="*[local-name() = 'fmt-related']/*[local-name() = 'p']" priority="4">
13683
+ <fo:block>
13684
+ <xsl:apply-templates/>
13685
+ </fo:block>
13686
+ </xsl:template>
13687
+
13662
13688
  <!-- ========== -->
13663
13689
  <!-- definition -->
13664
13690
  <!-- ========== -->
@@ -14564,6 +14590,7 @@
14564
14590
 
14565
14591
  <!-- Normative references -->
14566
14592
  <xsl:template match="*[local-name() = 'references'][@normative='true']/*[local-name() = 'bibitem']" name="bibitem" priority="2">
14593
+ <xsl:param name="skip" select="normalize-space(preceding-sibling::*[1][local-name() = 'bibitem'] and 1 = 1)"/> <!-- current bibiitem is non-first -->
14567
14594
 
14568
14595
  <fo:block id="{@id}" xsl:use-attribute-sets="bibitem-normative-style">
14569
14596
 
@@ -15279,7 +15306,8 @@
15279
15306
  <!-- add @id - first element with @id plus '_element_name' -->
15280
15307
  <xsl:variable name="prefix_id_" select="(.//*[@id])[1]/@id"/>
15281
15308
  <xsl:variable name="prefix_id"><xsl:value-of select="$prefix_id_"/><xsl:if test="normalize-space($prefix_id_) = ''"><xsl:value-of select="generate-id()"/></xsl:if></xsl:variable>
15282
- <xsl:attribute name="id"><xsl:value-of select="$prefix_id"/>_<xsl:value-of select="local-name()"/></xsl:attribute>
15309
+ <xsl:variable name="document_suffix" select="ancestor::*[contains(local-name(), '-standard')]/@document_suffix"/>
15310
+ <xsl:attribute name="id"><xsl:value-of select="concat($prefix_id, '_', local-name(), '_', $document_suffix)"/></xsl:attribute>
15283
15311
  </xsl:if>
15284
15312
  </xsl:template>
15285
15313
 
@@ -15336,6 +15364,31 @@
15336
15364
  <xsl:template match="*[local-name() = 'name'][following-sibling::*[1][local-name() = 'fmt-name']]" mode="update_xml_pres"/>
15337
15365
  <xsl:template match="*[local-name() = 'section-title'][following-sibling::*[1][local-name() = 'p'][@type = 'section-title' or @type = 'floating-title']]" mode="update_xml_step1"/>
15338
15366
  <xsl:template match="*[local-name() = 'section-title'][following-sibling::*[1][local-name() = 'p'][@type = 'section-title' or @type = 'floating-title']]" mode="update_xml_pres"/>
15367
+ <!-- <xsl:template match="*[local-name() = 'preferred'][following-sibling::*[not(local-name() = 'preferred')][1][local-name() = 'fmt-preferred']]" mode="update_xml_step1"/> -->
15368
+ <xsl:template match="*[local-name() = 'preferred']" mode="update_xml_step1"/>
15369
+ <!-- <xsl:template match="*[local-name() = 'preferred'][following-sibling::*[not(local-name() = 'preferred')][1][local-name() = 'fmt-preferred']]" mode="update_xml_pres"/> -->
15370
+ <xsl:template match="*[local-name() = 'preferred']" mode="update_xml_pres"/>
15371
+ <!-- <xsl:template match="*[local-name() = 'admitted'][following-sibling::*[not(local-name() = 'admitted')][1][local-name() = 'fmt-admitted']]" mode="update_xml_step1"/> -->
15372
+ <xsl:template match="*[local-name() = 'admitted']" mode="update_xml_step1"/>
15373
+ <!-- <xsl:template match="*[local-name() = 'admitted'][following-sibling::*[not(local-name() = 'admitted')][1][local-name() = 'fmt-admitted']]" mode="update_xml_pres"/> -->
15374
+ <xsl:template match="*[local-name() = 'admitted']" mode="update_xml_pres"/>
15375
+ <!-- <xsl:template match="*[local-name() = 'deprecates'][following-sibling::*[not(local-name() = 'deprecates')][1][local-name() = 'fmt-deprecates']]" mode="update_xml_step1"/> -->
15376
+ <xsl:template match="*[local-name() = 'deprecates']" mode="update_xml_step1"/>
15377
+ <xsl:template match="*[local-name() = 'related']" mode="update_xml_step1"/>
15378
+ <!-- <xsl:template match="*[local-name() = 'deprecates'][following-sibling::*[not(local-name() = 'deprecates')][1][local-name() = 'fmt-deprecates']]" mode="update_xml_pres"/> -->
15379
+ <xsl:template match="*[local-name() = 'deprecates']" mode="update_xml_pres"/>
15380
+ <xsl:template match="*[local-name() = 'related']" mode="update_xml_pres"/>
15381
+ <!-- <xsl:template match="*[local-name() = 'definition'][following-sibling::*[1][local-name() = 'fmt-definition']]" mode="update_xml_step1"/> -->
15382
+ <xsl:template match="*[local-name() = 'definition']" mode="update_xml_step1"/>
15383
+ <!-- <xsl:template match="*[local-name() = 'definition'][following-sibling::*[1][local-name() = 'fmt-definition']]" mode="update_xml_pres"/> -->
15384
+ <xsl:template match="*[local-name() = 'definition']" mode="update_xml_pres"/>
15385
+ <!-- <xsl:template match="*[local-name() = 'termsource'][following-sibling::*[1][local-name() = 'fmt-termsource']]" mode="update_xml_step1"/> -->
15386
+ <xsl:template match="*[local-name() = 'termsource']" mode="update_xml_step1"/>
15387
+ <!-- <xsl:template match="*[local-name() = 'termsource'][following-sibling::*[1][local-name() = 'fmt-termsource']]" mode="update_xml_pres"/> -->
15388
+ <xsl:template match="*[local-name() = 'termsource']" mode="update_xml_pres"/>
15389
+
15390
+ <xsl:template match="*[local-name() = 'term'][@unnumbered = 'true'][not(.//*[starts-with(local-name(), 'fmt-')])]" mode="update_xml_step1"/>
15391
+ <xsl:template match="*[local-name() = 'term'][@unnumbered = 'true'][not(.//*[starts-with(local-name(), 'fmt-')])]" mode="update_xml_pres"/>
15339
15392
 
15340
15393
  <xsl:template match="*[local-name() = 'p'][@type = 'section-title' or @type = 'floating-title'][preceding-sibling::*[1][local-name() = 'section-title']]" mode="update_xml_step1">
15341
15394
  <xsl:copy>
@@ -15380,6 +15433,94 @@
15380
15433
  </xsl:element>
15381
15434
  </xsl:template>
15382
15435
 
15436
+ <xsl:template match="*[local-name() = 'fmt-preferred']"/>
15437
+ <xsl:template match="*[local-name() = 'fmt-preferred'][*[local-name() = 'p']]" mode="update_xml_step1">
15438
+ <xsl:apply-templates mode="update_xml_step1"/>
15439
+ </xsl:template>
15440
+ <xsl:template match="*[local-name() = 'fmt-preferred'][not(*[local-name() = 'p'])] | *[local-name() = 'fmt-preferred']/*[local-name() = 'p']" mode="update_xml_step1">
15441
+ <xsl:element name="preferred" namespace="{$namespace_full}">
15442
+ <xsl:copy-of select="@*"/>
15443
+ <xsl:apply-templates mode="update_xml_step1"/>
15444
+ </xsl:element>
15445
+ </xsl:template>
15446
+ <xsl:template match="*[local-name() = 'fmt-preferred'][*[local-name() = 'p']]" mode="update_xml_pres">
15447
+ <xsl:apply-templates mode="update_xml_pres"/>
15448
+ </xsl:template>
15449
+ <xsl:template match="*[local-name() = 'fmt-preferred'][not(*[local-name() = 'p'])] | *[local-name() = 'fmt-preferred']/*[local-name() = 'p']" mode="update_xml_pres">
15450
+ <xsl:element name="preferred" namespace="{$namespace_full}">
15451
+ <xsl:copy-of select="@*"/>
15452
+ <xsl:apply-templates mode="update_xml_pres"/>
15453
+ </xsl:element>
15454
+ </xsl:template>
15455
+
15456
+ <xsl:template match="*[local-name() = 'fmt-admitted']"/>
15457
+ <xsl:template match="*[local-name() = 'fmt-admitted'][*[local-name() = 'p']]" mode="update_xml_step1">
15458
+ <xsl:apply-templates mode="update_xml_step1"/>
15459
+ </xsl:template>
15460
+ <xsl:template match="*[local-name() = 'fmt-admitted'][not(*[local-name() = 'p'])] | *[local-name() = 'fmt-admitted']/*[local-name() = 'p']" mode="update_xml_step1">
15461
+ <xsl:element name="admitted" namespace="{$namespace_full}">
15462
+ <xsl:copy-of select="@*"/>
15463
+ <xsl:apply-templates mode="update_xml_step1"/>
15464
+ </xsl:element>
15465
+ </xsl:template>
15466
+ <xsl:template match="*[local-name() = 'fmt-admitted'][*[local-name() = 'p']]" mode="update_xml_pres">
15467
+ <xsl:apply-templates mode="update_xml_pres"/>
15468
+ </xsl:template>
15469
+ <xsl:template match="*[local-name() = 'fmt-admitted'][not(*[local-name() = 'p'])] | *[local-name() = 'fmt-admitted']/*[local-name() = 'p']" mode="update_xml_pres">
15470
+ <xsl:element name="admitted" namespace="{$namespace_full}">
15471
+ <xsl:copy-of select="@*"/>
15472
+ <xsl:apply-templates mode="update_xml_pres"/>
15473
+ </xsl:element>
15474
+ </xsl:template>
15475
+
15476
+ <xsl:template match="*[local-name() = 'fmt-deprecates']"/>
15477
+ <xsl:template match="*[local-name() = 'fmt-deprecates'][*[local-name() = 'p']]" mode="update_xml_step1">
15478
+ <xsl:apply-templates mode="update_xml_step1"/>
15479
+ </xsl:template>
15480
+ <xsl:template match="*[local-name() = 'fmt-deprecates'][not(*[local-name() = 'p'])] | *[local-name() = 'fmt-deprecates']/*[local-name() = 'p']" mode="update_xml_step1">
15481
+ <xsl:element name="deprecates" namespace="{$namespace_full}">
15482
+ <xsl:copy-of select="@*"/>
15483
+ <xsl:apply-templates mode="update_xml_step1"/>
15484
+ </xsl:element>
15485
+ </xsl:template>
15486
+ <xsl:template match="*[local-name() = 'fmt-deprecates'][*[local-name() = 'p']]" mode="update_xml_pres">
15487
+ <xsl:apply-templates mode="update_xml_pres"/>
15488
+ </xsl:template>
15489
+ <xsl:template match="*[local-name() = 'fmt-deprecates'][not(*[local-name() = 'p'])] | *[local-name() = 'fmt-deprecates']/*[local-name() = 'p']" mode="update_xml_pres">
15490
+ <xsl:element name="deprecates" namespace="{$namespace_full}">
15491
+ <xsl:copy-of select="@*"/>
15492
+ <xsl:apply-templates mode="update_xml_pres"/>
15493
+ </xsl:element>
15494
+ </xsl:template>
15495
+
15496
+ <xsl:template match="*[local-name() = 'fmt-definition']"/>
15497
+ <xsl:template match="*[local-name() = 'fmt-definition']" mode="update_xml_step1">
15498
+ <xsl:element name="definition" namespace="{$namespace_full}">
15499
+ <xsl:copy-of select="@*"/>
15500
+ <xsl:apply-templates mode="update_xml_step1"/>
15501
+ </xsl:element>
15502
+ </xsl:template>
15503
+ <xsl:template match="*[local-name() = 'fmt-definition']" mode="update_xml_pres">
15504
+ <xsl:element name="definition" namespace="{$namespace_full}">
15505
+ <xsl:copy-of select="@*"/>
15506
+ <xsl:apply-templates mode="update_xml_pres"/>
15507
+ </xsl:element>
15508
+ </xsl:template>
15509
+
15510
+ <xsl:template match="*[local-name() = 'fmt-termsource']"/>
15511
+ <xsl:template match="*[local-name() = 'fmt-termsource']" mode="update_xml_step1">
15512
+ <xsl:element name="termsource" namespace="{$namespace_full}">
15513
+ <xsl:copy-of select="@*"/>
15514
+ <xsl:apply-templates mode="update_xml_step1"/>
15515
+ </xsl:element>
15516
+ </xsl:template>
15517
+ <xsl:template match="*[local-name() = 'fmt-termsource']" mode="update_xml_pres">
15518
+ <xsl:element name="termsource" namespace="{$namespace_full}">
15519
+ <xsl:copy-of select="@*"/>
15520
+ <xsl:apply-templates mode="update_xml_pres"/>
15521
+ </xsl:element>
15522
+ </xsl:template>
15523
+
15383
15524
  <xsl:template match="*[local-name() = 'span'][ @class = 'fmt-caption-label' or @class = 'fmt-element-name' or @class = 'fmt-caption-delim' or @class = 'fmt-autonum-delim']" mode="update_xml_step1" priority="3">
15384
15525
  <xsl:apply-templates mode="update_xml_step1"/>
15385
15526
  </xsl:template>
@@ -16518,7 +16659,7 @@
16518
16659
  </xsl:template>
16519
16660
 
16520
16661
  <xsl:template name="namespaceCheck">
16521
- <xsl:variable name="documentNS" select="namespace-uri(/*)"/>
16662
+ <xsl:variable name="documentNS" select="$namespace_full"/> <!-- namespace-uri(/*) -->
16522
16663
  <xsl:variable name="XSLNS">
16523
16664
 
16524
16665
  <xsl:value-of select="document('')//*/namespace::bipm"/>
@@ -16608,6 +16749,9 @@
16608
16749
  <xsl:when test="$formatted = 'true' and string-length($bibdata_updated) != ''">
16609
16750
  <xsl:apply-templates select="xalan:nodeset($bibdata_updated)//*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang]"/>
16610
16751
  </xsl:when>
16752
+ <xsl:when test="string-length($bibdata_updated) != ''">
16753
+ <xsl:value-of select="xalan:nodeset($bibdata_updated)//*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang]"/>
16754
+ </xsl:when>
16611
16755
  <xsl:when test="$formatted = 'true'">
16612
16756
  <xsl:apply-templates select="xalan:nodeset($bibdata)//*[local-name() = 'localized-string'][@key = $key and @language = $curr_lang]"/>
16613
16757
  </xsl:when>