metanorma-un 0.12.7 → 0.12.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/isodoc/un/un.plenary-attachment.xsl +129 -30
- data/lib/isodoc/un/un.plenary.xsl +129 -30
- data/lib/isodoc/un/un.recommendation.xsl +129 -30
- data/lib/metanorma/un/biblio.rng +22 -23
- data/lib/metanorma/un/isodoc.rng +37 -116
- data/lib/metanorma/un/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 219c898d77e60a55f391c5435cfd53c33b285394b51c5f754a0bd177261fbc20
|
4
|
+
data.tar.gz: 223a9a2cdf5c42a3c8e2404640ead1d99e58208fa3c743b36f5fdc3c2f7d5a22
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f064ded953d4e110dd098da3216c87fb5651ec3ed0a1a67a906d636a586e4e948079c0a3949ad92c828ae40fe2a98fa4ae87a620fd9579d56115acea82ac621a
|
7
|
+
data.tar.gz: 9fb904a6da6bcd1476e160699b63e3f361cf785743f6ef511fe6774f2eb15e646a228c5cec43ae34e5a2dd032cd1ced256f5974b53d3ebedd5dd4103bd5af0f2
|
@@ -6918,10 +6918,11 @@
|
|
6918
6918
|
</xsl:template>
|
6919
6919
|
|
6920
6920
|
<xsl:template match="*[local-name() = 'image']">
|
6921
|
+
<xsl:param name="indent">0</xsl:param>
|
6921
6922
|
<xsl:variable name="isAdded" select="../@added"/>
|
6922
6923
|
<xsl:variable name="isDeleted" select="../@deleted"/>
|
6923
6924
|
<xsl:choose>
|
6924
|
-
<xsl:when test="ancestor::*[local-name() = 'title'] or not(parent::*[local-name() = 'figure']) or parent::*[local-name() = 'p']">
|
6925
|
+
<xsl:when test="ancestor::*[local-name() = 'title'] or not(parent::*[local-name() = 'figure']) or parent::*[local-name() = 'p']"> <!-- inline image ( 'image:path' in adoc, with one colon after image) -->
|
6925
6926
|
<fo:inline padding-left="1mm" padding-right="1mm">
|
6926
6927
|
<xsl:if test="not(parent::*[local-name() = 'figure']) or parent::*[local-name() = 'p']">
|
6927
6928
|
<xsl:attribute name="padding-left">0mm</xsl:attribute>
|
@@ -6930,7 +6931,43 @@
|
|
6930
6931
|
<xsl:variable name="src">
|
6931
6932
|
<xsl:call-template name="image_src"/>
|
6932
6933
|
</xsl:variable>
|
6933
|
-
|
6934
|
+
|
6935
|
+
<xsl:variable name="scale">
|
6936
|
+
<xsl:call-template name="getImageScale">
|
6937
|
+
<xsl:with-param name="indent" select="$indent"/>
|
6938
|
+
</xsl:call-template>
|
6939
|
+
</xsl:variable>
|
6940
|
+
|
6941
|
+
<!-- debug scale='<xsl:value-of select="$scale"/>', indent='<xsl:value-of select="$indent"/>' -->
|
6942
|
+
|
6943
|
+
<!-- <fo:external-graphic src="{$src}" fox:alt-text="Image {@alt}" vertical-align="middle"/> -->
|
6944
|
+
<fo:external-graphic src="{$src}" fox:alt-text="Image {@alt}" vertical-align="middle">
|
6945
|
+
|
6946
|
+
<xsl:variable name="width">
|
6947
|
+
<xsl:call-template name="setImageWidth"/>
|
6948
|
+
</xsl:variable>
|
6949
|
+
<xsl:if test="$width != ''">
|
6950
|
+
<xsl:attribute name="width"><xsl:value-of select="$width"/></xsl:attribute>
|
6951
|
+
</xsl:if>
|
6952
|
+
<xsl:variable name="height">
|
6953
|
+
<xsl:call-template name="setImageHeight"/>
|
6954
|
+
</xsl:variable>
|
6955
|
+
<xsl:if test="$height != ''">
|
6956
|
+
<xsl:attribute name="height"><xsl:value-of select="$height"/></xsl:attribute>
|
6957
|
+
</xsl:if>
|
6958
|
+
|
6959
|
+
<xsl:if test="$width = '' and $height = ''">
|
6960
|
+
<xsl:if test="number($scale) < 100">
|
6961
|
+
<xsl:attribute name="content-width"><xsl:value-of select="number($scale)"/>%</xsl:attribute>
|
6962
|
+
<!-- <xsl:attribute name="content-width">scale-to-fit</xsl:attribute>
|
6963
|
+
<xsl:attribute name="content-height">100%</xsl:attribute>
|
6964
|
+
<xsl:attribute name="width">100%</xsl:attribute>
|
6965
|
+
<xsl:attribute name="scaling">uniform</xsl:attribute> -->
|
6966
|
+
</xsl:if>
|
6967
|
+
</xsl:if>
|
6968
|
+
|
6969
|
+
</fo:external-graphic>
|
6970
|
+
|
6934
6971
|
</fo:inline>
|
6935
6972
|
</xsl:when>
|
6936
6973
|
<xsl:otherwise>
|
@@ -6951,25 +6988,23 @@
|
|
6951
6988
|
<xsl:attribute name="content-width">scale-down-to-fit</xsl:attribute>
|
6952
6989
|
<xsl:attribute name="scaling">uniform</xsl:attribute>
|
6953
6990
|
|
6954
|
-
|
6991
|
+
<xsl:apply-templates select="." mode="cross_image"/>
|
6955
6992
|
|
6956
6993
|
</fo:instream-foreign-object>
|
6957
6994
|
</xsl:when>
|
6958
6995
|
<xsl:otherwise>
|
6996
|
+
<!-- <fo:block>debug block image:
|
6997
|
+
<xsl:variable name="scale">
|
6998
|
+
<xsl:call-template name="getImageScale">
|
6999
|
+
<xsl:with-param name="indent" select="$indent"/>
|
7000
|
+
</xsl:call-template>
|
7001
|
+
</xsl:variable>
|
7002
|
+
<xsl:value-of select="concat('scale=', $scale,', indent=', $indent)"/>
|
7003
|
+
</fo:block> -->
|
6959
7004
|
<fo:external-graphic src="{$src}" fox:alt-text="Image {@alt}" xsl:use-attribute-sets="image-graphic-style">
|
6960
7005
|
<xsl:if test="not(@mimetype = 'image/svg+xml') and (../*[local-name() = 'name'] or parent::*[local-name() = 'figure'][@unnumbered = 'true']) and not(ancestor::*[local-name() = 'table'])">
|
6961
7006
|
|
6962
|
-
<xsl:
|
6963
|
-
<xsl:attribute name="width">
|
6964
|
-
<xsl:value-of select="@width"/>
|
6965
|
-
</xsl:attribute>
|
6966
|
-
</xsl:if>
|
6967
|
-
|
6968
|
-
<xsl:if test="@height != '' and @height != 'auto'">
|
6969
|
-
<xsl:attribute name="height">
|
6970
|
-
<xsl:value-of select="@height"/>
|
6971
|
-
</xsl:attribute>
|
6972
|
-
</xsl:if>
|
7007
|
+
<xsl:call-template name="setImageWidthHeight"/>
|
6973
7008
|
|
6974
7009
|
<xsl:choose>
|
6975
7010
|
<xsl:when test="@width != '' and @width != 'auto' and @height != '' and @height != 'auto'">
|
@@ -6977,24 +7012,18 @@
|
|
6977
7012
|
</xsl:when>
|
6978
7013
|
<xsl:otherwise>
|
6979
7014
|
|
6980
|
-
<xsl:variable name="
|
6981
|
-
<xsl:
|
6982
|
-
<xsl:
|
6983
|
-
|
6984
|
-
</xsl:choose>
|
7015
|
+
<xsl:variable name="scale">
|
7016
|
+
<xsl:call-template name="getImageScale">
|
7017
|
+
<xsl:with-param name="indent" select="$indent"/>
|
7018
|
+
</xsl:call-template>
|
6985
7019
|
</xsl:variable>
|
6986
7020
|
|
6987
|
-
<xsl:variable name="
|
6988
|
-
|
6989
|
-
<xsl:value-of select="$width_effective"/>
|
6990
|
-
|
7021
|
+
<xsl:variable name="scaleRatio">
|
7022
|
+
0.985
|
6991
7023
|
</xsl:variable>
|
6992
7024
|
|
6993
|
-
<xsl:variable name="scale" select="java:org.metanorma.fop.Util.getImageScale($img_src, $image_width_effective, $height_effective)"/>
|
6994
7025
|
<xsl:if test="number($scale) < 100">
|
6995
|
-
|
6996
|
-
<xsl:attribute name="content-width"><xsl:value-of select="$scale * 0.985"/>%</xsl:attribute><!-- 0.985 due border around image -->
|
6997
|
-
|
7026
|
+
<xsl:attribute name="content-width"><xsl:value-of select="number($scale) * number($scaleRatio)"/>%</xsl:attribute>
|
6998
7027
|
</xsl:if>
|
6999
7028
|
</xsl:otherwise>
|
7000
7029
|
</xsl:choose>
|
@@ -7010,6 +7039,62 @@
|
|
7010
7039
|
</xsl:choose>
|
7011
7040
|
</xsl:template>
|
7012
7041
|
|
7042
|
+
<xsl:template name="setImageWidth">
|
7043
|
+
<xsl:if test="@width != '' and @width != 'auto' and @width != 'text-width' and @width != 'full-page-width' and @width != 'narrow'">
|
7044
|
+
<xsl:value-of select="@width"/>
|
7045
|
+
</xsl:if>
|
7046
|
+
</xsl:template>
|
7047
|
+
<xsl:template name="setImageHeight">
|
7048
|
+
<xsl:if test="@height != '' and @height != 'auto'">
|
7049
|
+
<xsl:value-of select="@height"/>
|
7050
|
+
</xsl:if>
|
7051
|
+
</xsl:template>
|
7052
|
+
<xsl:template name="setImageWidthHeight">
|
7053
|
+
<xsl:variable name="width">
|
7054
|
+
<xsl:call-template name="setImageWidth"/>
|
7055
|
+
</xsl:variable>
|
7056
|
+
<xsl:if test="$width != ''">
|
7057
|
+
<xsl:attribute name="width">
|
7058
|
+
<xsl:value-of select="$width"/>
|
7059
|
+
</xsl:attribute>
|
7060
|
+
</xsl:if>
|
7061
|
+
<xsl:variable name="height">
|
7062
|
+
<xsl:call-template name="setImageHeight"/>
|
7063
|
+
</xsl:variable>
|
7064
|
+
<xsl:if test="$height != ''">
|
7065
|
+
<xsl:attribute name="height">
|
7066
|
+
<xsl:value-of select="$height"/>
|
7067
|
+
</xsl:attribute>
|
7068
|
+
</xsl:if>
|
7069
|
+
</xsl:template>
|
7070
|
+
|
7071
|
+
<xsl:template name="getImageScale">
|
7072
|
+
<xsl:param name="indent"/>
|
7073
|
+
<xsl:variable name="indent_left">
|
7074
|
+
<xsl:choose>
|
7075
|
+
<xsl:when test="$indent != ''"><xsl:value-of select="$indent"/></xsl:when>
|
7076
|
+
<xsl:otherwise>0</xsl:otherwise>
|
7077
|
+
</xsl:choose>
|
7078
|
+
</xsl:variable>
|
7079
|
+
<xsl:variable name="img_src">
|
7080
|
+
<xsl:choose>
|
7081
|
+
<xsl:when test="not(starts-with(@src, 'data:'))"><xsl:value-of select="concat($basepath, @src)"/></xsl:when>
|
7082
|
+
<xsl:otherwise><xsl:value-of select="@src"/></xsl:otherwise>
|
7083
|
+
</xsl:choose>
|
7084
|
+
</xsl:variable>
|
7085
|
+
|
7086
|
+
<xsl:variable name="image_width_effective">
|
7087
|
+
|
7088
|
+
<xsl:value-of select="$width_effective - number($indent_left)"/>
|
7089
|
+
|
7090
|
+
</xsl:variable>
|
7091
|
+
<!-- <xsl:message>width_effective=<xsl:value-of select="$width_effective"/></xsl:message>
|
7092
|
+
<xsl:message>indent_left=<xsl:value-of select="$indent_left"/></xsl:message>
|
7093
|
+
<xsl:message>image_width_effective=<xsl:value-of select="$image_width_effective"/> for <xsl:value-of select="ancestor::ogc:p[1]/@id"/></xsl:message> -->
|
7094
|
+
<xsl:variable name="scale" select="java:org.metanorma.fop.Util.getImageScale($img_src, $image_width_effective, $height_effective)"/>
|
7095
|
+
<xsl:value-of select="$scale"/>
|
7096
|
+
</xsl:template>
|
7097
|
+
|
7013
7098
|
<xsl:template name="image_src">
|
7014
7099
|
<xsl:choose>
|
7015
7100
|
<xsl:when test="@mimetype = 'image/svg+xml' and $images/images/image[@id = current()/@id]">
|
@@ -9690,6 +9775,7 @@
|
|
9690
9775
|
</xsl:template>
|
9691
9776
|
|
9692
9777
|
<xsl:template match="*[local-name() = 'ul'] | *[local-name() = 'ol']">
|
9778
|
+
<xsl:param name="indent">0</xsl:param>
|
9693
9779
|
<xsl:choose>
|
9694
9780
|
<xsl:when test="parent::*[local-name() = 'note'] or parent::*[local-name() = 'termnote']">
|
9695
9781
|
<fo:block-container role="SKIP">
|
@@ -9704,7 +9790,9 @@
|
|
9704
9790
|
|
9705
9791
|
<fo:block-container margin-left="0mm" role="SKIP">
|
9706
9792
|
<fo:block>
|
9707
|
-
<xsl:apply-templates select="." mode="list"
|
9793
|
+
<xsl:apply-templates select="." mode="list">
|
9794
|
+
<xsl:with-param name="indent" select="$indent"/>
|
9795
|
+
</xsl:apply-templates>
|
9708
9796
|
</fo:block>
|
9709
9797
|
</fo:block-container>
|
9710
9798
|
</fo:block-container>
|
@@ -9712,7 +9800,9 @@
|
|
9712
9800
|
<xsl:otherwise>
|
9713
9801
|
|
9714
9802
|
<fo:block role="SKIP">
|
9715
|
-
<xsl:apply-templates select="." mode="list"
|
9803
|
+
<xsl:apply-templates select="." mode="list">
|
9804
|
+
<xsl:with-param name="indent" select="$indent"/>
|
9805
|
+
</xsl:apply-templates>
|
9716
9806
|
</fo:block>
|
9717
9807
|
|
9718
9808
|
</xsl:otherwise>
|
@@ -9801,6 +9891,13 @@
|
|
9801
9891
|
</xsl:template>
|
9802
9892
|
|
9803
9893
|
<xsl:template match="*[local-name()='li']">
|
9894
|
+
<xsl:param name="indent">0</xsl:param>
|
9895
|
+
<!-- <fo:list-item xsl:use-attribute-sets="list-item-style">
|
9896
|
+
<fo:list-item-label end-indent="label-end()"><fo:block>x</fo:block></fo:list-item-label>
|
9897
|
+
<fo:list-item-body start-indent="body-start()" xsl:use-attribute-sets="list-item-body-style">
|
9898
|
+
<fo:block>debug li indent=<xsl:value-of select="$indent"/></fo:block>
|
9899
|
+
</fo:list-item-body>
|
9900
|
+
</fo:list-item> -->
|
9804
9901
|
<fo:list-item xsl:use-attribute-sets="list-item-style">
|
9805
9902
|
<xsl:copy-of select="@id"/>
|
9806
9903
|
|
@@ -9825,7 +9922,9 @@
|
|
9825
9922
|
|
9826
9923
|
<xsl:call-template name="refine_list-item-body-style"/>
|
9827
9924
|
|
9828
|
-
<xsl:apply-templates
|
9925
|
+
<xsl:apply-templates>
|
9926
|
+
<xsl:with-param name="indent" select="$indent"/>
|
9927
|
+
</xsl:apply-templates>
|
9829
9928
|
|
9830
9929
|
<!-- <xsl:apply-templates select="node()[not(local-name() = 'note')]" />
|
9831
9930
|
|
@@ -6918,10 +6918,11 @@
|
|
6918
6918
|
</xsl:template>
|
6919
6919
|
|
6920
6920
|
<xsl:template match="*[local-name() = 'image']">
|
6921
|
+
<xsl:param name="indent">0</xsl:param>
|
6921
6922
|
<xsl:variable name="isAdded" select="../@added"/>
|
6922
6923
|
<xsl:variable name="isDeleted" select="../@deleted"/>
|
6923
6924
|
<xsl:choose>
|
6924
|
-
<xsl:when test="ancestor::*[local-name() = 'title'] or not(parent::*[local-name() = 'figure']) or parent::*[local-name() = 'p']">
|
6925
|
+
<xsl:when test="ancestor::*[local-name() = 'title'] or not(parent::*[local-name() = 'figure']) or parent::*[local-name() = 'p']"> <!-- inline image ( 'image:path' in adoc, with one colon after image) -->
|
6925
6926
|
<fo:inline padding-left="1mm" padding-right="1mm">
|
6926
6927
|
<xsl:if test="not(parent::*[local-name() = 'figure']) or parent::*[local-name() = 'p']">
|
6927
6928
|
<xsl:attribute name="padding-left">0mm</xsl:attribute>
|
@@ -6930,7 +6931,43 @@
|
|
6930
6931
|
<xsl:variable name="src">
|
6931
6932
|
<xsl:call-template name="image_src"/>
|
6932
6933
|
</xsl:variable>
|
6933
|
-
|
6934
|
+
|
6935
|
+
<xsl:variable name="scale">
|
6936
|
+
<xsl:call-template name="getImageScale">
|
6937
|
+
<xsl:with-param name="indent" select="$indent"/>
|
6938
|
+
</xsl:call-template>
|
6939
|
+
</xsl:variable>
|
6940
|
+
|
6941
|
+
<!-- debug scale='<xsl:value-of select="$scale"/>', indent='<xsl:value-of select="$indent"/>' -->
|
6942
|
+
|
6943
|
+
<!-- <fo:external-graphic src="{$src}" fox:alt-text="Image {@alt}" vertical-align="middle"/> -->
|
6944
|
+
<fo:external-graphic src="{$src}" fox:alt-text="Image {@alt}" vertical-align="middle">
|
6945
|
+
|
6946
|
+
<xsl:variable name="width">
|
6947
|
+
<xsl:call-template name="setImageWidth"/>
|
6948
|
+
</xsl:variable>
|
6949
|
+
<xsl:if test="$width != ''">
|
6950
|
+
<xsl:attribute name="width"><xsl:value-of select="$width"/></xsl:attribute>
|
6951
|
+
</xsl:if>
|
6952
|
+
<xsl:variable name="height">
|
6953
|
+
<xsl:call-template name="setImageHeight"/>
|
6954
|
+
</xsl:variable>
|
6955
|
+
<xsl:if test="$height != ''">
|
6956
|
+
<xsl:attribute name="height"><xsl:value-of select="$height"/></xsl:attribute>
|
6957
|
+
</xsl:if>
|
6958
|
+
|
6959
|
+
<xsl:if test="$width = '' and $height = ''">
|
6960
|
+
<xsl:if test="number($scale) < 100">
|
6961
|
+
<xsl:attribute name="content-width"><xsl:value-of select="number($scale)"/>%</xsl:attribute>
|
6962
|
+
<!-- <xsl:attribute name="content-width">scale-to-fit</xsl:attribute>
|
6963
|
+
<xsl:attribute name="content-height">100%</xsl:attribute>
|
6964
|
+
<xsl:attribute name="width">100%</xsl:attribute>
|
6965
|
+
<xsl:attribute name="scaling">uniform</xsl:attribute> -->
|
6966
|
+
</xsl:if>
|
6967
|
+
</xsl:if>
|
6968
|
+
|
6969
|
+
</fo:external-graphic>
|
6970
|
+
|
6934
6971
|
</fo:inline>
|
6935
6972
|
</xsl:when>
|
6936
6973
|
<xsl:otherwise>
|
@@ -6951,25 +6988,23 @@
|
|
6951
6988
|
<xsl:attribute name="content-width">scale-down-to-fit</xsl:attribute>
|
6952
6989
|
<xsl:attribute name="scaling">uniform</xsl:attribute>
|
6953
6990
|
|
6954
|
-
|
6991
|
+
<xsl:apply-templates select="." mode="cross_image"/>
|
6955
6992
|
|
6956
6993
|
</fo:instream-foreign-object>
|
6957
6994
|
</xsl:when>
|
6958
6995
|
<xsl:otherwise>
|
6996
|
+
<!-- <fo:block>debug block image:
|
6997
|
+
<xsl:variable name="scale">
|
6998
|
+
<xsl:call-template name="getImageScale">
|
6999
|
+
<xsl:with-param name="indent" select="$indent"/>
|
7000
|
+
</xsl:call-template>
|
7001
|
+
</xsl:variable>
|
7002
|
+
<xsl:value-of select="concat('scale=', $scale,', indent=', $indent)"/>
|
7003
|
+
</fo:block> -->
|
6959
7004
|
<fo:external-graphic src="{$src}" fox:alt-text="Image {@alt}" xsl:use-attribute-sets="image-graphic-style">
|
6960
7005
|
<xsl:if test="not(@mimetype = 'image/svg+xml') and (../*[local-name() = 'name'] or parent::*[local-name() = 'figure'][@unnumbered = 'true']) and not(ancestor::*[local-name() = 'table'])">
|
6961
7006
|
|
6962
|
-
<xsl:
|
6963
|
-
<xsl:attribute name="width">
|
6964
|
-
<xsl:value-of select="@width"/>
|
6965
|
-
</xsl:attribute>
|
6966
|
-
</xsl:if>
|
6967
|
-
|
6968
|
-
<xsl:if test="@height != '' and @height != 'auto'">
|
6969
|
-
<xsl:attribute name="height">
|
6970
|
-
<xsl:value-of select="@height"/>
|
6971
|
-
</xsl:attribute>
|
6972
|
-
</xsl:if>
|
7007
|
+
<xsl:call-template name="setImageWidthHeight"/>
|
6973
7008
|
|
6974
7009
|
<xsl:choose>
|
6975
7010
|
<xsl:when test="@width != '' and @width != 'auto' and @height != '' and @height != 'auto'">
|
@@ -6977,24 +7012,18 @@
|
|
6977
7012
|
</xsl:when>
|
6978
7013
|
<xsl:otherwise>
|
6979
7014
|
|
6980
|
-
<xsl:variable name="
|
6981
|
-
<xsl:
|
6982
|
-
<xsl:
|
6983
|
-
|
6984
|
-
</xsl:choose>
|
7015
|
+
<xsl:variable name="scale">
|
7016
|
+
<xsl:call-template name="getImageScale">
|
7017
|
+
<xsl:with-param name="indent" select="$indent"/>
|
7018
|
+
</xsl:call-template>
|
6985
7019
|
</xsl:variable>
|
6986
7020
|
|
6987
|
-
<xsl:variable name="
|
6988
|
-
|
6989
|
-
<xsl:value-of select="$width_effective"/>
|
6990
|
-
|
7021
|
+
<xsl:variable name="scaleRatio">
|
7022
|
+
0.985
|
6991
7023
|
</xsl:variable>
|
6992
7024
|
|
6993
|
-
<xsl:variable name="scale" select="java:org.metanorma.fop.Util.getImageScale($img_src, $image_width_effective, $height_effective)"/>
|
6994
7025
|
<xsl:if test="number($scale) < 100">
|
6995
|
-
|
6996
|
-
<xsl:attribute name="content-width"><xsl:value-of select="$scale * 0.985"/>%</xsl:attribute><!-- 0.985 due border around image -->
|
6997
|
-
|
7026
|
+
<xsl:attribute name="content-width"><xsl:value-of select="number($scale) * number($scaleRatio)"/>%</xsl:attribute>
|
6998
7027
|
</xsl:if>
|
6999
7028
|
</xsl:otherwise>
|
7000
7029
|
</xsl:choose>
|
@@ -7010,6 +7039,62 @@
|
|
7010
7039
|
</xsl:choose>
|
7011
7040
|
</xsl:template>
|
7012
7041
|
|
7042
|
+
<xsl:template name="setImageWidth">
|
7043
|
+
<xsl:if test="@width != '' and @width != 'auto' and @width != 'text-width' and @width != 'full-page-width' and @width != 'narrow'">
|
7044
|
+
<xsl:value-of select="@width"/>
|
7045
|
+
</xsl:if>
|
7046
|
+
</xsl:template>
|
7047
|
+
<xsl:template name="setImageHeight">
|
7048
|
+
<xsl:if test="@height != '' and @height != 'auto'">
|
7049
|
+
<xsl:value-of select="@height"/>
|
7050
|
+
</xsl:if>
|
7051
|
+
</xsl:template>
|
7052
|
+
<xsl:template name="setImageWidthHeight">
|
7053
|
+
<xsl:variable name="width">
|
7054
|
+
<xsl:call-template name="setImageWidth"/>
|
7055
|
+
</xsl:variable>
|
7056
|
+
<xsl:if test="$width != ''">
|
7057
|
+
<xsl:attribute name="width">
|
7058
|
+
<xsl:value-of select="$width"/>
|
7059
|
+
</xsl:attribute>
|
7060
|
+
</xsl:if>
|
7061
|
+
<xsl:variable name="height">
|
7062
|
+
<xsl:call-template name="setImageHeight"/>
|
7063
|
+
</xsl:variable>
|
7064
|
+
<xsl:if test="$height != ''">
|
7065
|
+
<xsl:attribute name="height">
|
7066
|
+
<xsl:value-of select="$height"/>
|
7067
|
+
</xsl:attribute>
|
7068
|
+
</xsl:if>
|
7069
|
+
</xsl:template>
|
7070
|
+
|
7071
|
+
<xsl:template name="getImageScale">
|
7072
|
+
<xsl:param name="indent"/>
|
7073
|
+
<xsl:variable name="indent_left">
|
7074
|
+
<xsl:choose>
|
7075
|
+
<xsl:when test="$indent != ''"><xsl:value-of select="$indent"/></xsl:when>
|
7076
|
+
<xsl:otherwise>0</xsl:otherwise>
|
7077
|
+
</xsl:choose>
|
7078
|
+
</xsl:variable>
|
7079
|
+
<xsl:variable name="img_src">
|
7080
|
+
<xsl:choose>
|
7081
|
+
<xsl:when test="not(starts-with(@src, 'data:'))"><xsl:value-of select="concat($basepath, @src)"/></xsl:when>
|
7082
|
+
<xsl:otherwise><xsl:value-of select="@src"/></xsl:otherwise>
|
7083
|
+
</xsl:choose>
|
7084
|
+
</xsl:variable>
|
7085
|
+
|
7086
|
+
<xsl:variable name="image_width_effective">
|
7087
|
+
|
7088
|
+
<xsl:value-of select="$width_effective - number($indent_left)"/>
|
7089
|
+
|
7090
|
+
</xsl:variable>
|
7091
|
+
<!-- <xsl:message>width_effective=<xsl:value-of select="$width_effective"/></xsl:message>
|
7092
|
+
<xsl:message>indent_left=<xsl:value-of select="$indent_left"/></xsl:message>
|
7093
|
+
<xsl:message>image_width_effective=<xsl:value-of select="$image_width_effective"/> for <xsl:value-of select="ancestor::ogc:p[1]/@id"/></xsl:message> -->
|
7094
|
+
<xsl:variable name="scale" select="java:org.metanorma.fop.Util.getImageScale($img_src, $image_width_effective, $height_effective)"/>
|
7095
|
+
<xsl:value-of select="$scale"/>
|
7096
|
+
</xsl:template>
|
7097
|
+
|
7013
7098
|
<xsl:template name="image_src">
|
7014
7099
|
<xsl:choose>
|
7015
7100
|
<xsl:when test="@mimetype = 'image/svg+xml' and $images/images/image[@id = current()/@id]">
|
@@ -9690,6 +9775,7 @@
|
|
9690
9775
|
</xsl:template>
|
9691
9776
|
|
9692
9777
|
<xsl:template match="*[local-name() = 'ul'] | *[local-name() = 'ol']">
|
9778
|
+
<xsl:param name="indent">0</xsl:param>
|
9693
9779
|
<xsl:choose>
|
9694
9780
|
<xsl:when test="parent::*[local-name() = 'note'] or parent::*[local-name() = 'termnote']">
|
9695
9781
|
<fo:block-container role="SKIP">
|
@@ -9704,7 +9790,9 @@
|
|
9704
9790
|
|
9705
9791
|
<fo:block-container margin-left="0mm" role="SKIP">
|
9706
9792
|
<fo:block>
|
9707
|
-
<xsl:apply-templates select="." mode="list"
|
9793
|
+
<xsl:apply-templates select="." mode="list">
|
9794
|
+
<xsl:with-param name="indent" select="$indent"/>
|
9795
|
+
</xsl:apply-templates>
|
9708
9796
|
</fo:block>
|
9709
9797
|
</fo:block-container>
|
9710
9798
|
</fo:block-container>
|
@@ -9712,7 +9800,9 @@
|
|
9712
9800
|
<xsl:otherwise>
|
9713
9801
|
|
9714
9802
|
<fo:block role="SKIP">
|
9715
|
-
<xsl:apply-templates select="." mode="list"
|
9803
|
+
<xsl:apply-templates select="." mode="list">
|
9804
|
+
<xsl:with-param name="indent" select="$indent"/>
|
9805
|
+
</xsl:apply-templates>
|
9716
9806
|
</fo:block>
|
9717
9807
|
|
9718
9808
|
</xsl:otherwise>
|
@@ -9801,6 +9891,13 @@
|
|
9801
9891
|
</xsl:template>
|
9802
9892
|
|
9803
9893
|
<xsl:template match="*[local-name()='li']">
|
9894
|
+
<xsl:param name="indent">0</xsl:param>
|
9895
|
+
<!-- <fo:list-item xsl:use-attribute-sets="list-item-style">
|
9896
|
+
<fo:list-item-label end-indent="label-end()"><fo:block>x</fo:block></fo:list-item-label>
|
9897
|
+
<fo:list-item-body start-indent="body-start()" xsl:use-attribute-sets="list-item-body-style">
|
9898
|
+
<fo:block>debug li indent=<xsl:value-of select="$indent"/></fo:block>
|
9899
|
+
</fo:list-item-body>
|
9900
|
+
</fo:list-item> -->
|
9804
9901
|
<fo:list-item xsl:use-attribute-sets="list-item-style">
|
9805
9902
|
<xsl:copy-of select="@id"/>
|
9806
9903
|
|
@@ -9825,7 +9922,9 @@
|
|
9825
9922
|
|
9826
9923
|
<xsl:call-template name="refine_list-item-body-style"/>
|
9827
9924
|
|
9828
|
-
<xsl:apply-templates
|
9925
|
+
<xsl:apply-templates>
|
9926
|
+
<xsl:with-param name="indent" select="$indent"/>
|
9927
|
+
</xsl:apply-templates>
|
9829
9928
|
|
9830
9929
|
<!-- <xsl:apply-templates select="node()[not(local-name() = 'note')]" />
|
9831
9930
|
|
@@ -7045,10 +7045,11 @@
|
|
7045
7045
|
</xsl:template>
|
7046
7046
|
|
7047
7047
|
<xsl:template match="*[local-name() = 'image']">
|
7048
|
+
<xsl:param name="indent">0</xsl:param>
|
7048
7049
|
<xsl:variable name="isAdded" select="../@added"/>
|
7049
7050
|
<xsl:variable name="isDeleted" select="../@deleted"/>
|
7050
7051
|
<xsl:choose>
|
7051
|
-
<xsl:when test="ancestor::*[local-name() = 'title'] or not(parent::*[local-name() = 'figure']) or parent::*[local-name() = 'p']">
|
7052
|
+
<xsl:when test="ancestor::*[local-name() = 'title'] or not(parent::*[local-name() = 'figure']) or parent::*[local-name() = 'p']"> <!-- inline image ( 'image:path' in adoc, with one colon after image) -->
|
7052
7053
|
<fo:inline padding-left="1mm" padding-right="1mm">
|
7053
7054
|
<xsl:if test="not(parent::*[local-name() = 'figure']) or parent::*[local-name() = 'p']">
|
7054
7055
|
<xsl:attribute name="padding-left">0mm</xsl:attribute>
|
@@ -7057,7 +7058,43 @@
|
|
7057
7058
|
<xsl:variable name="src">
|
7058
7059
|
<xsl:call-template name="image_src"/>
|
7059
7060
|
</xsl:variable>
|
7060
|
-
|
7061
|
+
|
7062
|
+
<xsl:variable name="scale">
|
7063
|
+
<xsl:call-template name="getImageScale">
|
7064
|
+
<xsl:with-param name="indent" select="$indent"/>
|
7065
|
+
</xsl:call-template>
|
7066
|
+
</xsl:variable>
|
7067
|
+
|
7068
|
+
<!-- debug scale='<xsl:value-of select="$scale"/>', indent='<xsl:value-of select="$indent"/>' -->
|
7069
|
+
|
7070
|
+
<!-- <fo:external-graphic src="{$src}" fox:alt-text="Image {@alt}" vertical-align="middle"/> -->
|
7071
|
+
<fo:external-graphic src="{$src}" fox:alt-text="Image {@alt}" vertical-align="middle">
|
7072
|
+
|
7073
|
+
<xsl:variable name="width">
|
7074
|
+
<xsl:call-template name="setImageWidth"/>
|
7075
|
+
</xsl:variable>
|
7076
|
+
<xsl:if test="$width != ''">
|
7077
|
+
<xsl:attribute name="width"><xsl:value-of select="$width"/></xsl:attribute>
|
7078
|
+
</xsl:if>
|
7079
|
+
<xsl:variable name="height">
|
7080
|
+
<xsl:call-template name="setImageHeight"/>
|
7081
|
+
</xsl:variable>
|
7082
|
+
<xsl:if test="$height != ''">
|
7083
|
+
<xsl:attribute name="height"><xsl:value-of select="$height"/></xsl:attribute>
|
7084
|
+
</xsl:if>
|
7085
|
+
|
7086
|
+
<xsl:if test="$width = '' and $height = ''">
|
7087
|
+
<xsl:if test="number($scale) < 100">
|
7088
|
+
<xsl:attribute name="content-width"><xsl:value-of select="number($scale)"/>%</xsl:attribute>
|
7089
|
+
<!-- <xsl:attribute name="content-width">scale-to-fit</xsl:attribute>
|
7090
|
+
<xsl:attribute name="content-height">100%</xsl:attribute>
|
7091
|
+
<xsl:attribute name="width">100%</xsl:attribute>
|
7092
|
+
<xsl:attribute name="scaling">uniform</xsl:attribute> -->
|
7093
|
+
</xsl:if>
|
7094
|
+
</xsl:if>
|
7095
|
+
|
7096
|
+
</fo:external-graphic>
|
7097
|
+
|
7061
7098
|
</fo:inline>
|
7062
7099
|
</xsl:when>
|
7063
7100
|
<xsl:otherwise>
|
@@ -7078,25 +7115,23 @@
|
|
7078
7115
|
<xsl:attribute name="content-width">scale-down-to-fit</xsl:attribute>
|
7079
7116
|
<xsl:attribute name="scaling">uniform</xsl:attribute>
|
7080
7117
|
|
7081
|
-
|
7118
|
+
<xsl:apply-templates select="." mode="cross_image"/>
|
7082
7119
|
|
7083
7120
|
</fo:instream-foreign-object>
|
7084
7121
|
</xsl:when>
|
7085
7122
|
<xsl:otherwise>
|
7123
|
+
<!-- <fo:block>debug block image:
|
7124
|
+
<xsl:variable name="scale">
|
7125
|
+
<xsl:call-template name="getImageScale">
|
7126
|
+
<xsl:with-param name="indent" select="$indent"/>
|
7127
|
+
</xsl:call-template>
|
7128
|
+
</xsl:variable>
|
7129
|
+
<xsl:value-of select="concat('scale=', $scale,', indent=', $indent)"/>
|
7130
|
+
</fo:block> -->
|
7086
7131
|
<fo:external-graphic src="{$src}" fox:alt-text="Image {@alt}" xsl:use-attribute-sets="image-graphic-style">
|
7087
7132
|
<xsl:if test="not(@mimetype = 'image/svg+xml') and (../*[local-name() = 'name'] or parent::*[local-name() = 'figure'][@unnumbered = 'true']) and not(ancestor::*[local-name() = 'table'])">
|
7088
7133
|
|
7089
|
-
<xsl:
|
7090
|
-
<xsl:attribute name="width">
|
7091
|
-
<xsl:value-of select="@width"/>
|
7092
|
-
</xsl:attribute>
|
7093
|
-
</xsl:if>
|
7094
|
-
|
7095
|
-
<xsl:if test="@height != '' and @height != 'auto'">
|
7096
|
-
<xsl:attribute name="height">
|
7097
|
-
<xsl:value-of select="@height"/>
|
7098
|
-
</xsl:attribute>
|
7099
|
-
</xsl:if>
|
7134
|
+
<xsl:call-template name="setImageWidthHeight"/>
|
7100
7135
|
|
7101
7136
|
<xsl:choose>
|
7102
7137
|
<xsl:when test="@width != '' and @width != 'auto' and @height != '' and @height != 'auto'">
|
@@ -7104,24 +7139,18 @@
|
|
7104
7139
|
</xsl:when>
|
7105
7140
|
<xsl:otherwise>
|
7106
7141
|
|
7107
|
-
<xsl:variable name="
|
7108
|
-
<xsl:
|
7109
|
-
<xsl:
|
7110
|
-
|
7111
|
-
</xsl:choose>
|
7142
|
+
<xsl:variable name="scale">
|
7143
|
+
<xsl:call-template name="getImageScale">
|
7144
|
+
<xsl:with-param name="indent" select="$indent"/>
|
7145
|
+
</xsl:call-template>
|
7112
7146
|
</xsl:variable>
|
7113
7147
|
|
7114
|
-
<xsl:variable name="
|
7115
|
-
|
7116
|
-
<xsl:value-of select="$width_effective"/>
|
7117
|
-
|
7148
|
+
<xsl:variable name="scaleRatio">
|
7149
|
+
1
|
7118
7150
|
</xsl:variable>
|
7119
7151
|
|
7120
|
-
<xsl:variable name="scale" select="java:org.metanorma.fop.Util.getImageScale($img_src, $image_width_effective, $height_effective)"/>
|
7121
7152
|
<xsl:if test="number($scale) < 100">
|
7122
|
-
|
7123
|
-
<xsl:attribute name="content-width"><xsl:value-of select="$scale"/>%</xsl:attribute>
|
7124
|
-
|
7153
|
+
<xsl:attribute name="content-width"><xsl:value-of select="number($scale) * number($scaleRatio)"/>%</xsl:attribute>
|
7125
7154
|
</xsl:if>
|
7126
7155
|
</xsl:otherwise>
|
7127
7156
|
</xsl:choose>
|
@@ -7137,6 +7166,62 @@
|
|
7137
7166
|
</xsl:choose>
|
7138
7167
|
</xsl:template>
|
7139
7168
|
|
7169
|
+
<xsl:template name="setImageWidth">
|
7170
|
+
<xsl:if test="@width != '' and @width != 'auto' and @width != 'text-width' and @width != 'full-page-width' and @width != 'narrow'">
|
7171
|
+
<xsl:value-of select="@width"/>
|
7172
|
+
</xsl:if>
|
7173
|
+
</xsl:template>
|
7174
|
+
<xsl:template name="setImageHeight">
|
7175
|
+
<xsl:if test="@height != '' and @height != 'auto'">
|
7176
|
+
<xsl:value-of select="@height"/>
|
7177
|
+
</xsl:if>
|
7178
|
+
</xsl:template>
|
7179
|
+
<xsl:template name="setImageWidthHeight">
|
7180
|
+
<xsl:variable name="width">
|
7181
|
+
<xsl:call-template name="setImageWidth"/>
|
7182
|
+
</xsl:variable>
|
7183
|
+
<xsl:if test="$width != ''">
|
7184
|
+
<xsl:attribute name="width">
|
7185
|
+
<xsl:value-of select="$width"/>
|
7186
|
+
</xsl:attribute>
|
7187
|
+
</xsl:if>
|
7188
|
+
<xsl:variable name="height">
|
7189
|
+
<xsl:call-template name="setImageHeight"/>
|
7190
|
+
</xsl:variable>
|
7191
|
+
<xsl:if test="$height != ''">
|
7192
|
+
<xsl:attribute name="height">
|
7193
|
+
<xsl:value-of select="$height"/>
|
7194
|
+
</xsl:attribute>
|
7195
|
+
</xsl:if>
|
7196
|
+
</xsl:template>
|
7197
|
+
|
7198
|
+
<xsl:template name="getImageScale">
|
7199
|
+
<xsl:param name="indent"/>
|
7200
|
+
<xsl:variable name="indent_left">
|
7201
|
+
<xsl:choose>
|
7202
|
+
<xsl:when test="$indent != ''"><xsl:value-of select="$indent"/></xsl:when>
|
7203
|
+
<xsl:otherwise>0</xsl:otherwise>
|
7204
|
+
</xsl:choose>
|
7205
|
+
</xsl:variable>
|
7206
|
+
<xsl:variable name="img_src">
|
7207
|
+
<xsl:choose>
|
7208
|
+
<xsl:when test="not(starts-with(@src, 'data:'))"><xsl:value-of select="concat($basepath, @src)"/></xsl:when>
|
7209
|
+
<xsl:otherwise><xsl:value-of select="@src"/></xsl:otherwise>
|
7210
|
+
</xsl:choose>
|
7211
|
+
</xsl:variable>
|
7212
|
+
|
7213
|
+
<xsl:variable name="image_width_effective">
|
7214
|
+
|
7215
|
+
<xsl:value-of select="$width_effective - number($indent_left)"/>
|
7216
|
+
|
7217
|
+
</xsl:variable>
|
7218
|
+
<!-- <xsl:message>width_effective=<xsl:value-of select="$width_effective"/></xsl:message>
|
7219
|
+
<xsl:message>indent_left=<xsl:value-of select="$indent_left"/></xsl:message>
|
7220
|
+
<xsl:message>image_width_effective=<xsl:value-of select="$image_width_effective"/> for <xsl:value-of select="ancestor::ogc:p[1]/@id"/></xsl:message> -->
|
7221
|
+
<xsl:variable name="scale" select="java:org.metanorma.fop.Util.getImageScale($img_src, $image_width_effective, $height_effective)"/>
|
7222
|
+
<xsl:value-of select="$scale"/>
|
7223
|
+
</xsl:template>
|
7224
|
+
|
7140
7225
|
<xsl:template name="image_src">
|
7141
7226
|
<xsl:choose>
|
7142
7227
|
<xsl:when test="@mimetype = 'image/svg+xml' and $images/images/image[@id = current()/@id]">
|
@@ -9817,6 +9902,7 @@
|
|
9817
9902
|
</xsl:template>
|
9818
9903
|
|
9819
9904
|
<xsl:template match="*[local-name() = 'ul'] | *[local-name() = 'ol']">
|
9905
|
+
<xsl:param name="indent">0</xsl:param>
|
9820
9906
|
<xsl:choose>
|
9821
9907
|
<xsl:when test="parent::*[local-name() = 'note'] or parent::*[local-name() = 'termnote']">
|
9822
9908
|
<fo:block-container role="SKIP">
|
@@ -9831,7 +9917,9 @@
|
|
9831
9917
|
|
9832
9918
|
<fo:block-container margin-left="0mm" role="SKIP">
|
9833
9919
|
<fo:block>
|
9834
|
-
<xsl:apply-templates select="." mode="list"
|
9920
|
+
<xsl:apply-templates select="." mode="list">
|
9921
|
+
<xsl:with-param name="indent" select="$indent"/>
|
9922
|
+
</xsl:apply-templates>
|
9835
9923
|
</fo:block>
|
9836
9924
|
</fo:block-container>
|
9837
9925
|
</fo:block-container>
|
@@ -9839,7 +9927,9 @@
|
|
9839
9927
|
<xsl:otherwise>
|
9840
9928
|
|
9841
9929
|
<fo:block role="SKIP">
|
9842
|
-
<xsl:apply-templates select="." mode="list"
|
9930
|
+
<xsl:apply-templates select="." mode="list">
|
9931
|
+
<xsl:with-param name="indent" select="$indent"/>
|
9932
|
+
</xsl:apply-templates>
|
9843
9933
|
</fo:block>
|
9844
9934
|
|
9845
9935
|
</xsl:otherwise>
|
@@ -9928,6 +10018,13 @@
|
|
9928
10018
|
</xsl:template>
|
9929
10019
|
|
9930
10020
|
<xsl:template match="*[local-name()='li']">
|
10021
|
+
<xsl:param name="indent">0</xsl:param>
|
10022
|
+
<!-- <fo:list-item xsl:use-attribute-sets="list-item-style">
|
10023
|
+
<fo:list-item-label end-indent="label-end()"><fo:block>x</fo:block></fo:list-item-label>
|
10024
|
+
<fo:list-item-body start-indent="body-start()" xsl:use-attribute-sets="list-item-body-style">
|
10025
|
+
<fo:block>debug li indent=<xsl:value-of select="$indent"/></fo:block>
|
10026
|
+
</fo:list-item-body>
|
10027
|
+
</fo:list-item> -->
|
9931
10028
|
<fo:list-item xsl:use-attribute-sets="list-item-style">
|
9932
10029
|
<xsl:copy-of select="@id"/>
|
9933
10030
|
|
@@ -9952,7 +10049,9 @@
|
|
9952
10049
|
|
9953
10050
|
<xsl:call-template name="refine_list-item-body-style"/>
|
9954
10051
|
|
9955
|
-
<xsl:apply-templates
|
10052
|
+
<xsl:apply-templates>
|
10053
|
+
<xsl:with-param name="indent" select="$indent"/>
|
10054
|
+
</xsl:apply-templates>
|
9956
10055
|
|
9957
10056
|
<!-- <xsl:apply-templates select="node()[not(local-name() = 'note')]" />
|
9958
10057
|
|
data/lib/metanorma/un/biblio.rng
CHANGED
@@ -95,7 +95,7 @@
|
|
95
95
|
<text/>
|
96
96
|
</element>
|
97
97
|
</define>
|
98
|
-
<define name="
|
98
|
+
<define name="LocalizedStringAttrs">
|
99
99
|
<optional>
|
100
100
|
<!-- multiple languages and scripts possible: comma delimit them if so -->
|
101
101
|
<attribute name="language"/>
|
@@ -106,6 +106,10 @@
|
|
106
106
|
<optional>
|
107
107
|
<attribute name="script"/>
|
108
108
|
</optional>
|
109
|
+
</define>
|
110
|
+
<define name="LocalizedString1">
|
111
|
+
<!-- multiple languages and scripts possible: comma delimit them if so -->
|
112
|
+
<ref name="LocalizedStringAttrs"/>
|
109
113
|
<text/>
|
110
114
|
</define>
|
111
115
|
<define name="LocalizedString">
|
@@ -142,16 +146,8 @@
|
|
142
146
|
<ref name="LocalizedStringOrXsAny"/>
|
143
147
|
</define>
|
144
148
|
<define name="LocalizedStringOrXsAny1">
|
145
|
-
|
146
|
-
|
147
|
-
<attribute name="language"/>
|
148
|
-
</optional>
|
149
|
-
<optional>
|
150
|
-
<attribute name="locale"/>
|
151
|
-
</optional>
|
152
|
-
<optional>
|
153
|
-
<attribute name="script"/>
|
154
|
-
</optional>
|
149
|
+
<!-- multiple languages and scripts possible: comma delimit them if so -->
|
150
|
+
<ref name="LocalizedStringAttrs"/>
|
155
151
|
<oneOrMore>
|
156
152
|
<choice>
|
157
153
|
<text/>
|
@@ -208,6 +204,7 @@
|
|
208
204
|
</define>
|
209
205
|
<define name="roledescription">
|
210
206
|
<element name="description">
|
207
|
+
<ref name="LocalizedStringAttrs"/>
|
211
208
|
<oneOrMore>
|
212
209
|
<ref name="TextElement"/>
|
213
210
|
</oneOrMore>
|
@@ -335,6 +332,7 @@
|
|
335
332
|
</define>
|
336
333
|
<define name="affiliationdescription">
|
337
334
|
<element name="description">
|
335
|
+
<ref name="LocalizedStringAttrs"/>
|
338
336
|
<oneOrMore>
|
339
337
|
<ref name="TextElement"/>
|
340
338
|
</oneOrMore>
|
@@ -948,6 +946,7 @@
|
|
948
946
|
<optional>
|
949
947
|
<attribute name="type"/>
|
950
948
|
</optional>
|
949
|
+
<ref name="LocalizedStringAttrs"/>
|
951
950
|
<zeroOrMore>
|
952
951
|
<ref name="TextElement"/>
|
953
952
|
</zeroOrMore>
|
@@ -1041,15 +1040,7 @@
|
|
1041
1040
|
<data type="boolean"/>
|
1042
1041
|
</attribute>
|
1043
1042
|
</optional>
|
1044
|
-
<
|
1045
|
-
<attribute name="language"/>
|
1046
|
-
</optional>
|
1047
|
-
<optional>
|
1048
|
-
<attribute name="locale"/>
|
1049
|
-
</optional>
|
1050
|
-
<optional>
|
1051
|
-
<attribute name="script"/>
|
1052
|
-
</optional>
|
1043
|
+
<ref name="LocalizedStringAttrs"/>
|
1053
1044
|
<oneOrMore>
|
1054
1045
|
<ref name="TextElement"/>
|
1055
1046
|
</oneOrMore>
|
@@ -1277,6 +1268,7 @@
|
|
1277
1268
|
<optional>
|
1278
1269
|
<attribute name="type"/>
|
1279
1270
|
</optional>
|
1271
|
+
<ref name="LocalizedStringAttrs"/>
|
1280
1272
|
<oneOrMore>
|
1281
1273
|
<ref name="TextElement"/>
|
1282
1274
|
</oneOrMore>
|
@@ -1284,9 +1276,15 @@
|
|
1284
1276
|
</define>
|
1285
1277
|
<define name="bibabstract">
|
1286
1278
|
<element name="abstract">
|
1287
|
-
<
|
1288
|
-
|
1289
|
-
|
1279
|
+
<ref name="LocalizedStringAttrs"/>
|
1280
|
+
<choice>
|
1281
|
+
<oneOrMore>
|
1282
|
+
<ref name="BasicBlock"/>
|
1283
|
+
</oneOrMore>
|
1284
|
+
<oneOrMore>
|
1285
|
+
<ref name="TextElement"/>
|
1286
|
+
</oneOrMore>
|
1287
|
+
</choice>
|
1290
1288
|
</element>
|
1291
1289
|
</define>
|
1292
1290
|
<define name="copyright">
|
@@ -1391,6 +1389,7 @@
|
|
1391
1389
|
</attribute>
|
1392
1390
|
<optional>
|
1393
1391
|
<element name="description">
|
1392
|
+
<ref name="LocalizedStringAttrs"/>
|
1394
1393
|
<oneOrMore>
|
1395
1394
|
<ref name="TextElement"/>
|
1396
1395
|
</oneOrMore>
|
data/lib/metanorma/un/isodoc.rng
CHANGED
@@ -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.3.
|
20
|
+
<!-- VERSION v1.3.1 -->
|
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">
|
@@ -1346,38 +1346,41 @@
|
|
1346
1346
|
</oneOrMore>
|
1347
1347
|
</element>
|
1348
1348
|
</define>
|
1349
|
+
<define name="Section-Attributes">
|
1350
|
+
<optional>
|
1351
|
+
<attribute name="id">
|
1352
|
+
<data type="ID"/>
|
1353
|
+
</attribute>
|
1354
|
+
</optional>
|
1355
|
+
<optional>
|
1356
|
+
<attribute name="language"/>
|
1357
|
+
</optional>
|
1358
|
+
<optional>
|
1359
|
+
<attribute name="script"/>
|
1360
|
+
</optional>
|
1361
|
+
<optional>
|
1362
|
+
<attribute name="inline-header">
|
1363
|
+
<data type="boolean"/>
|
1364
|
+
</attribute>
|
1365
|
+
</optional>
|
1366
|
+
<optional>
|
1367
|
+
<attribute name="number"/>
|
1368
|
+
</optional>
|
1369
|
+
<optional>
|
1370
|
+
<attribute name="branch-number"/>
|
1371
|
+
</optional>
|
1372
|
+
<optional>
|
1373
|
+
<attribute name="obligation">
|
1374
|
+
<choice>
|
1375
|
+
<value>normative</value>
|
1376
|
+
<value>informative</value>
|
1377
|
+
</choice>
|
1378
|
+
</attribute>
|
1379
|
+
</optional>
|
1380
|
+
</define>
|
1349
1381
|
<define name="reference-clause">
|
1350
1382
|
<element name="clause">
|
1351
|
-
<
|
1352
|
-
<attribute name="id">
|
1353
|
-
<data type="ID"/>
|
1354
|
-
</attribute>
|
1355
|
-
</optional>
|
1356
|
-
<optional>
|
1357
|
-
<attribute name="language"/>
|
1358
|
-
</optional>
|
1359
|
-
<optional>
|
1360
|
-
<attribute name="script"/>
|
1361
|
-
</optional>
|
1362
|
-
<optional>
|
1363
|
-
<attribute name="inline-header">
|
1364
|
-
<data type="boolean"/>
|
1365
|
-
</attribute>
|
1366
|
-
</optional>
|
1367
|
-
<optional>
|
1368
|
-
<attribute name="number"/>
|
1369
|
-
</optional>
|
1370
|
-
<optional>
|
1371
|
-
<attribute name="branch-number"/>
|
1372
|
-
</optional>
|
1373
|
-
<optional>
|
1374
|
-
<attribute name="obligation">
|
1375
|
-
<choice>
|
1376
|
-
<value>normative</value>
|
1377
|
-
<value>informative</value>
|
1378
|
-
</choice>
|
1379
|
-
</attribute>
|
1380
|
-
</optional>
|
1383
|
+
<ref name="Section-Attributes"/>
|
1381
1384
|
<optional>
|
1382
1385
|
<ref name="section-title"/>
|
1383
1386
|
</optional>
|
@@ -1566,36 +1569,7 @@
|
|
1566
1569
|
</element>
|
1567
1570
|
</define>
|
1568
1571
|
<define name="Content-Section">
|
1569
|
-
<
|
1570
|
-
<attribute name="id">
|
1571
|
-
<data type="ID"/>
|
1572
|
-
</attribute>
|
1573
|
-
</optional>
|
1574
|
-
<optional>
|
1575
|
-
<attribute name="language"/>
|
1576
|
-
</optional>
|
1577
|
-
<optional>
|
1578
|
-
<attribute name="script"/>
|
1579
|
-
</optional>
|
1580
|
-
<optional>
|
1581
|
-
<attribute name="inline-header">
|
1582
|
-
<data type="boolean"/>
|
1583
|
-
</attribute>
|
1584
|
-
</optional>
|
1585
|
-
<optional>
|
1586
|
-
<attribute name="obligation">
|
1587
|
-
<choice>
|
1588
|
-
<value>normative</value>
|
1589
|
-
<value>informative</value>
|
1590
|
-
</choice>
|
1591
|
-
</attribute>
|
1592
|
-
</optional>
|
1593
|
-
<optional>
|
1594
|
-
<attribute name="number"/>
|
1595
|
-
</optional>
|
1596
|
-
<optional>
|
1597
|
-
<attribute name="branch-number"/>
|
1598
|
-
</optional>
|
1572
|
+
<ref name="Section-Attributes"/>
|
1599
1573
|
<optional>
|
1600
1574
|
<attribute name="type"/>
|
1601
1575
|
</optional>
|
@@ -1617,39 +1591,10 @@
|
|
1617
1591
|
</element>
|
1618
1592
|
</define>
|
1619
1593
|
<define name="Clause-Section">
|
1620
|
-
<
|
1621
|
-
<attribute name="id">
|
1622
|
-
<data type="ID"/>
|
1623
|
-
</attribute>
|
1624
|
-
</optional>
|
1625
|
-
<optional>
|
1626
|
-
<attribute name="language"/>
|
1627
|
-
</optional>
|
1628
|
-
<optional>
|
1629
|
-
<attribute name="script"/>
|
1630
|
-
</optional>
|
1631
|
-
<optional>
|
1632
|
-
<attribute name="inline-header">
|
1633
|
-
<data type="boolean"/>
|
1634
|
-
</attribute>
|
1635
|
-
</optional>
|
1636
|
-
<optional>
|
1637
|
-
<attribute name="obligation">
|
1638
|
-
<choice>
|
1639
|
-
<value>normative</value>
|
1640
|
-
<value>informative</value>
|
1641
|
-
</choice>
|
1642
|
-
</attribute>
|
1643
|
-
</optional>
|
1594
|
+
<ref name="Section-Attributes"/>
|
1644
1595
|
<optional>
|
1645
1596
|
<attribute name="type"/>
|
1646
1597
|
</optional>
|
1647
|
-
<optional>
|
1648
|
-
<attribute name="number"/>
|
1649
|
-
</optional>
|
1650
|
-
<optional>
|
1651
|
-
<attribute name="branch-number"/>
|
1652
|
-
</optional>
|
1653
1598
|
<optional>
|
1654
1599
|
<ref name="section-title"/>
|
1655
1600
|
</optional>
|
@@ -1730,34 +1675,10 @@
|
|
1730
1675
|
</define>
|
1731
1676
|
<define name="terms">
|
1732
1677
|
<element name="terms">
|
1733
|
-
<
|
1734
|
-
<attribute name="id">
|
1735
|
-
<data type="ID"/>
|
1736
|
-
</attribute>
|
1737
|
-
</optional>
|
1738
|
-
<optional>
|
1739
|
-
<attribute name="language"/>
|
1740
|
-
</optional>
|
1741
|
-
<optional>
|
1742
|
-
<attribute name="script"/>
|
1743
|
-
</optional>
|
1678
|
+
<ref name="Section-Attributes"/>
|
1744
1679
|
<optional>
|
1745
1680
|
<attribute name="type"/>
|
1746
1681
|
</optional>
|
1747
|
-
<optional>
|
1748
|
-
<attribute name="number"/>
|
1749
|
-
</optional>
|
1750
|
-
<optional>
|
1751
|
-
<attribute name="branch-number"/>
|
1752
|
-
</optional>
|
1753
|
-
<optional>
|
1754
|
-
<attribute name="obligation">
|
1755
|
-
<choice>
|
1756
|
-
<value>normative</value>
|
1757
|
-
<value>informative</value>
|
1758
|
-
</choice>
|
1759
|
-
</attribute>
|
1760
|
-
</optional>
|
1761
1682
|
<optional>
|
1762
1683
|
<ref name="section-title"/>
|
1763
1684
|
</optional>
|
data/lib/metanorma/un/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-un
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.12.
|
4
|
+
version: 0.12.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-04-
|
11
|
+
date: 2024-04-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: iso-639
|