metanorma-iec 1.3.4 → 1.3.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c6f864a1028a766280c059aa02ec5e56a78806b0e2f2c4ae61efce3f0d254053
4
- data.tar.gz: 6e7c6439b85da10d02dc1b9aaf518338e1dfe4cbb3e5b754a4d4c4ccfb3e222a
3
+ metadata.gz: 1927ece3a09c61d4d12c9f6daa48bbadf0168bee1bfcde52392123308c44edb6
4
+ data.tar.gz: 1c92e46aa15e727af3438267cf5f9e72d78c00a959a8bcc354f384d0cc21102b
5
5
  SHA512:
6
- metadata.gz: 98311ebb5879d224265d355f83ea6f0d64044b3de4d185c6eda67a85705a40a1646e1ec0c6493f7dbf27269768dd6402e21da60639cb7bf880e1902bc463cca3
7
- data.tar.gz: 3dcb74e07eaf077c4a6cacec0e60133ab8f53d8d2a4baa8f97d6becd0e20392b8b72ca20a3f73cb7262ded33e3a15d2388657aca308ce03917b80aa715382d4a
6
+ metadata.gz: 98fd5f51acfe167d57c8f465d69d2f8fe7c4c24fd1393ed1377b27c36735066fbe1b71aeb6970e4e16ede2ed98f7143c602a4b3a091ad19f8b799dd3618639fb
7
+ data.tar.gz: da6cd485af116325a064b085d0533a0f895129de6a240129b233d1b9ea278df14a8a4a3931218b3ab34c87250fbd88df2a94a2177d0925a37458c97c8c88b348
data/.rubocop.yml CHANGED
@@ -7,4 +7,4 @@ inherit_from:
7
7
  # ...
8
8
 
9
9
  AllCops:
10
- TargetRubyVersion: 2.4
10
+ TargetRubyVersion: 2.5
@@ -18,8 +18,8 @@ module IsoDoc
18
18
  s.h1(**{ class: "ForewordTitle" }) { |h1| h1 << @i18n.foreword }
19
19
  @meta.get[:doctype] == "Amendment" or
20
20
  s.div **attr_code(class: "boilerplate_legal") do |s1|
21
- b&.elements&.each { |e| parse(e, s1) }
22
- end
21
+ b&.elements&.each { |e| parse(e, s1) }
22
+ end
23
23
  f&.elements&.each { |e| parse(e, s) unless e.name == "title" }
24
24
  end
25
25
  end
@@ -40,12 +40,12 @@ module IsoDoc
40
40
  @meta.get[:doctitlepartlabel] and
41
41
  title2 = "#{@meta.get[:doctitlepartlabel]}: #{title2}"
42
42
  end
43
- out.p(**{ class: "zzSTDTitle1" }) do |p|
43
+ out.p(**{ class: "zzSTDTitle1" }) do |p|
44
44
  p.b { |b| b << title1 }
45
45
  end
46
46
  if @meta.get[:doctitlepart]
47
47
  out.p(**{ class: "zzSTDTitle1" }) { |p| p << "&nbsp;" }
48
- out.p(**{ class: "zzSTDTitle2" }) do |p|
48
+ out.p(**{ class: "zzSTDTitle2" }) do |p|
49
49
  p.b { |b| b << title2 }
50
50
  end
51
51
  end
@@ -58,7 +58,7 @@ module IsoDoc
58
58
 
59
59
  def biblio_list(f, div, biblio)
60
60
  return super unless @is_iev
61
- i = 0
61
+
62
62
  f.children.each do |b|
63
63
  parse(b, div) unless %w(title bibitem).include? b.name
64
64
  end
@@ -66,6 +66,7 @@ module IsoDoc
66
66
 
67
67
  def terms_parse(node, out)
68
68
  return super unless @is_iev
69
+
69
70
  page_break(out)
70
71
  out.div **attr_code(id: node["id"]) do |div|
71
72
  out.p(**{ class: "zzSTDTitle2" }) do |p|
@@ -81,12 +82,14 @@ module IsoDoc
81
82
 
82
83
  def termref_cleanup(docxml)
83
84
  return super unless @is_iev
84
- docxml.
85
- gsub(%r{\s*\[/TERMREF\]\s*</p>\s*<p>\s*\[TERMREF\]}, "; ").
86
- gsub(/\[TERMREF\]\s*/, l10n("#{@i18n.source}: ")).
87
- gsub(/\s*\[MODIFICATION\]\s*\[\/TERMREF\]/, l10n(", #{@i18n.modified} [/TERMREF]")).
88
- gsub(/\s*\[\/TERMREF\]\s*/, l10n("")).
89
- gsub(/\s*\[MODIFICATION\]/, l10n(", #{@i18n.modified} &mdash; "))
85
+
86
+ docxml
87
+ .gsub(%r{\s*\[/TERMREF\]\s*</p>\s*<p>\s*\[TERMREF\]}, "; ")
88
+ .gsub(/\[TERMREF\]\s*/, l10n("#{@i18n.source}: "))
89
+ .gsub(/\s*\[MODIFICATION\]\s*\[\/TERMREF\]/,
90
+ l10n(", #{@i18n.modified} [/TERMREF]"))
91
+ .gsub(/\s*\[\/TERMREF\]\s*/, l10n(""))
92
+ .gsub(/\s*\[MODIFICATION\]/, l10n(", #{@i18n.modified} &mdash; "))
90
93
  end
91
94
 
92
95
  def set_termdomain(termdomain)
@@ -95,13 +98,15 @@ module IsoDoc
95
98
 
96
99
  def term_suffix(node, out)
97
100
  return unless @is_iev
101
+
98
102
  domain = node&.at(ns("../domain"))&.text
99
103
  return unless domain
104
+
100
105
  out << ", &lt;#{domain}&gt;"
101
106
  end
102
107
 
103
108
  def deprecated_term_parse(node, out)
104
- out.p **{ class: "DeprecatedTerms", style:"text-align:left;" } do |p|
109
+ out.p **{ class: "DeprecatedTerms", style: "text-align:left;" } do |p|
105
110
  p << l10n("#{@i18n.deprecated}: ")
106
111
  node.children.each { |c| parse(c, p) }
107
112
  term_suffix(node, p)
@@ -109,7 +114,7 @@ module IsoDoc
109
114
  end
110
115
 
111
116
  def admitted_term_parse(node, out)
112
- out.p **{ class: "AltTerms", style:"text-align:left;" } do |p|
117
+ out.p **{ class: "AltTerms", style: "text-align:left;" } do |p|
113
118
  node.children.each { |c| parse(c, p) }
114
119
  term_suffix(node, p)
115
120
  end
@@ -117,7 +122,8 @@ module IsoDoc
117
122
 
118
123
  def term_parse(node, out)
119
124
  return super unless @is_iev
120
- out.p **{ class: "Terms", style:"text-align:left;" } do |p|
125
+
126
+ out.p **{ class: "Terms", style: "text-align:left;" } do |p|
121
127
  node.children.each { |c| parse(c, p) }
122
128
  term_suffix(node, p)
123
129
  end
@@ -14,14 +14,14 @@ module IsoDoc
14
14
  def default_fonts(options)
15
15
  {
16
16
  bodyfont: (options[:script] == "Hans" ? '"Source Han Sans",serif' : '"Arial",sans-serif'),
17
- headerfont: (options[:script] == "Hans" ? '"Source Han Sans",sans-serif' : '"Arial",sans-serif'),
18
- monospacefont: ('"Courier New",monospace'),
19
- monospacefontsize: "1.0em",
20
- footnotefontsize: "0.9em",
17
+ headerfont: (options[:script] == "Hans" ? '"Source Han Sans",sans-serif' : '"Arial",sans-serif'),
18
+ monospacefont: '"Courier New",monospace',
19
+ monospacefontsize: "1.0em",
20
+ footnotefontsize: "0.9em",
21
21
  }
22
22
  end
23
23
 
24
- def default_file_locations(options)
24
+ def default_file_locations(_options)
25
25
  @libdir = File.dirname(__FILE__)
26
26
  {
27
27
  htmlstylesheet: html_doc_path("htmlstyle.scss"),
@@ -30,7 +30,7 @@ module IsoDoc
30
30
  }
31
31
  end
32
32
 
33
- def htmlstyle(docxml)
33
+ def htmlstyle(_docxml)
34
34
  docxml = super
35
35
  b = docxml.at("div[@class = 'boilerplate_legal']/ol")
36
36
  b and b["type"] = "1"
@@ -2694,7 +2694,7 @@
2694
2694
 
2695
2695
 
2696
2696
 
2697
-
2697
+
2698
2698
  </xsl:attribute-set><xsl:attribute-set name="example-style">
2699
2699
 
2700
2700
 
@@ -2753,6 +2753,7 @@
2753
2753
 
2754
2754
 
2755
2755
 
2756
+
2756
2757
  </xsl:attribute-set><xsl:attribute-set name="table-name-style">
2757
2758
  <xsl:attribute name="keep-with-next">always</xsl:attribute>
2758
2759
 
@@ -2774,6 +2775,8 @@
2774
2775
 
2775
2776
 
2776
2777
 
2778
+ </xsl:attribute-set><xsl:attribute-set name="table-footer-cell-style">
2779
+
2777
2780
  </xsl:attribute-set><xsl:attribute-set name="appendix-style">
2778
2781
 
2779
2782
 
@@ -2821,6 +2824,7 @@
2821
2824
 
2822
2825
 
2823
2826
 
2827
+
2824
2828
  </xsl:attribute-set><xsl:variable name="note-body-indent">10mm</xsl:variable><xsl:variable name="note-body-indent-table">5mm</xsl:variable><xsl:attribute-set name="note-name-style">
2825
2829
 
2826
2830
 
@@ -2864,10 +2868,12 @@
2864
2868
 
2865
2869
 
2866
2870
 
2871
+
2867
2872
  </xsl:attribute-set><xsl:attribute-set name="termnote-name-style">
2868
2873
 
2869
2874
 
2870
2875
 
2876
+
2871
2877
  </xsl:attribute-set><xsl:attribute-set name="quote-style">
2872
2878
 
2873
2879
 
@@ -2930,6 +2936,7 @@
2930
2936
 
2931
2937
 
2932
2938
 
2939
+
2933
2940
 
2934
2941
 
2935
2942
 
@@ -3007,6 +3014,8 @@
3007
3014
  <xsl:attribute name="font-family">STIX Two Math</xsl:attribute>
3008
3015
 
3009
3016
 
3017
+ </xsl:attribute-set><xsl:attribute-set name="list-style">
3018
+
3010
3019
  </xsl:attribute-set><xsl:variable name="border-block-added">2.5pt solid rgb(0, 176, 80)</xsl:variable><xsl:variable name="border-block-deleted">2.5pt solid rgb(255, 0, 0)</xsl:variable><xsl:template name="processPrefaceSectionsDefault_Contents">
3011
3020
  <xsl:apply-templates select="/*/*[local-name()='preface']/*[local-name()='abstract']" mode="contents"/>
3012
3021
  <xsl:apply-templates select="/*/*[local-name()='preface']/*[local-name()='foreword']" mode="contents"/>
@@ -3060,11 +3069,11 @@
3060
3069
  <xsl:variable name="table">
3061
3070
 
3062
3071
  <xsl:variable name="simple-table">
3063
- <xsl:call-template name="getSimpleTable"/>
3072
+ <xsl:call-template name="getSimpleTable"/>
3064
3073
  </xsl:variable>
3065
3074
 
3066
3075
  <!-- <xsl:if test="$namespace = 'bipm'">
3067
- <fo:block>&#xA0;</fo:block>
3076
+ <fo:block>&#xA0;</fo:block>
3068
3077
  </xsl:if> -->
3069
3078
 
3070
3079
  <!-- $namespace = 'iso' or -->
@@ -3174,6 +3183,7 @@
3174
3183
 
3175
3184
 
3176
3185
 
3186
+
3177
3187
  </xsl:variable>
3178
3188
 
3179
3189
 
@@ -3315,6 +3325,9 @@
3315
3325
  <fo:block xsl:use-attribute-sets="table-name-style">
3316
3326
 
3317
3327
 
3328
+
3329
+
3330
+
3318
3331
  <xsl:choose>
3319
3332
  <xsl:when test="$continued = 'true'">
3320
3333
  <!-- <xsl:if test="$namespace = 'bsi'"></xsl:if> -->
@@ -3462,6 +3475,7 @@
3462
3475
  <!-- font-weight="bold" -->
3463
3476
  <fo:table-header>
3464
3477
 
3478
+
3465
3479
  <xsl:apply-templates/>
3466
3480
  </fo:table-header>
3467
3481
  </xsl:template><xsl:template name="table-header-title">
@@ -3737,6 +3751,10 @@
3737
3751
 
3738
3752
 
3739
3753
 
3754
+
3755
+
3756
+
3757
+
3740
3758
  <!-- <xsl:if test="$namespace = 'bipm'">
3741
3759
  <xsl:attribute name="height">8mm</xsl:attribute>
3742
3760
  </xsl:if> -->
@@ -3841,6 +3859,9 @@
3841
3859
 
3842
3860
 
3843
3861
 
3862
+
3863
+
3864
+
3844
3865
  <xsl:if test=".//*[local-name() = 'table']">
3845
3866
  <xsl:attribute name="padding-right">1mm</xsl:attribute>
3846
3867
  </xsl:if>
@@ -4080,6 +4101,7 @@
4080
4101
 
4081
4102
 
4082
4103
 
4104
+
4083
4105
  <fo:basic-link internal-destination="{@reference}_{ancestor::*[@id][1]/@id}" fox:alt-text="{@reference}"> <!-- @reference | ancestor::*[local-name()='clause'][1]/@id-->
4084
4106
 
4085
4107
 
@@ -4398,6 +4420,7 @@
4398
4420
 
4399
4421
  <fo:table-row>
4400
4422
 
4423
+
4401
4424
  <fo:table-cell>
4402
4425
 
4403
4426
  <fo:block margin-top="6pt">
@@ -4417,6 +4440,7 @@
4417
4440
 
4418
4441
 
4419
4442
 
4443
+
4420
4444
  <xsl:apply-templates/>
4421
4445
  <!-- <xsl:if test="$namespace = 'gb'">
4422
4446
  <xsl:if test="ancestor::*[local-name()='formula']">
@@ -4964,7 +4988,15 @@
4964
4988
  <xsl:copy>
4965
4989
  <xsl:apply-templates select="@*|node()" mode="mathml"/>
4966
4990
  </xsl:copy>
4967
- <mathml:mspace width="0.5ex"/>
4991
+ <xsl:choose>
4992
+ <!-- if in msub, then don't add space -->
4993
+ <xsl:when test="ancestor::mathml:mrow[parent::mathml:msub and preceding-sibling::*[1][self::mathml:mrow]]"/>
4994
+ <!-- if next char in digit, don't add space -->
4995
+ <xsl:when test="translate(substring(following-sibling::*[1]/text(),1,1),'0123456789','') = ''"/>
4996
+ <xsl:otherwise>
4997
+ <mathml:mspace width="0.5ex"/>
4998
+ </xsl:otherwise>
4999
+ </xsl:choose>
4968
5000
  </xsl:template><xsl:template match="mathml:math/*[local-name()='unit']" mode="mathml"/><xsl:template match="mathml:math/*[local-name()='prefix']" mode="mathml"/><xsl:template match="mathml:math/*[local-name()='dimension']" mode="mathml"/><xsl:template match="mathml:math/*[local-name()='quantity']" mode="mathml"/><xsl:template match="*[local-name()='localityStack']"/><xsl:template match="*[local-name()='link']" name="link">
4969
5001
  <xsl:variable name="target">
4970
5002
  <xsl:choose>
@@ -4992,6 +5024,7 @@
4992
5024
  <xsl:attribute name="color">blue</xsl:attribute>
4993
5025
  </xsl:if>
4994
5026
 
5027
+
4995
5028
  <xsl:choose>
4996
5029
  <xsl:when test="$target_text = ''">
4997
5030
  <xsl:apply-templates/>
@@ -5143,6 +5176,7 @@
5143
5176
  </xsl:choose>
5144
5177
  </xsl:template><xsl:template match="*[local-name() = 'termnote']">
5145
5178
  <fo:block id="{@id}" xsl:use-attribute-sets="termnote-style">
5179
+
5146
5180
  <fo:inline xsl:use-attribute-sets="termnote-name-style">
5147
5181
 
5148
5182
  <xsl:apply-templates select="*[local-name() = 'name']" mode="presentation"/>
@@ -5218,6 +5252,7 @@
5218
5252
  </xsl:call-template>
5219
5253
 
5220
5254
  <fo:block>
5255
+
5221
5256
  <xsl:apply-templates/>
5222
5257
  </fo:block>
5223
5258
  <xsl:call-template name="fn_display_figure"/>
@@ -5502,6 +5537,7 @@
5502
5537
  <xsl:if test="normalize-space() != ''">
5503
5538
  <fo:block xsl:use-attribute-sets="figure-name-style">
5504
5539
 
5540
+
5505
5541
  <xsl:apply-templates/>
5506
5542
  </fo:block>
5507
5543
  </xsl:if>
@@ -5582,6 +5618,7 @@
5582
5618
 
5583
5619
  <fo:block-container margin-left="0mm">
5584
5620
  <xsl:copy-of select="@id"/>
5621
+
5585
5622
  <xsl:if test="parent::*[local-name() = 'note']">
5586
5623
  <xsl:attribute name="margin-left">
5587
5624
  <xsl:choose>
@@ -5592,7 +5629,9 @@
5592
5629
 
5593
5630
  </xsl:if>
5594
5631
  <fo:block-container margin-left="0mm">
5595
-
5632
+
5633
+
5634
+
5596
5635
  <fo:block xsl:use-attribute-sets="sourcecode-style">
5597
5636
  <xsl:variable name="_font-size">
5598
5637
 
@@ -5621,10 +5660,14 @@
5621
5660
  </xsl:choose>
5622
5661
  </xsl:attribute>
5623
5662
  </xsl:if>
5624
- <xsl:apply-templates/>
5625
- </fo:block>
5663
+
5664
+ <xsl:apply-templates/>
5665
+ </fo:block>
5666
+
5667
+
5626
5668
  <xsl:apply-templates select="*[local-name()='name']" mode="presentation"/>
5627
5669
 
5670
+
5628
5671
  </fo:block-container>
5629
5672
  </fo:block-container>
5630
5673
  </xsl:template><xsl:template match="*[local-name()='sourcecode']/text()" priority="2">
@@ -5970,6 +6013,8 @@
5970
6013
 
5971
6014
 
5972
6015
 
6016
+
6017
+
5973
6018
  <xsl:call-template name="getTitle">
5974
6019
  <xsl:with-param name="name" select="'title-source'"/>
5975
6020
  </xsl:call-template>
@@ -6197,6 +6242,7 @@
6197
6242
  <xsl:call-template name="setId"/>
6198
6243
 
6199
6244
 
6245
+
6200
6246
  <xsl:apply-templates/>
6201
6247
  </fo:block>
6202
6248
  </xsl:template><xsl:template match="*[local-name() = 'definitions']">
@@ -6443,17 +6489,17 @@
6443
6489
  <xsl:variable name="_doc_ident" select="*[local-name() = 'docidentifier'][not(@type = 'DOI' or @type = 'metanorma' or @type = 'ISSN' or @type = 'ISBN' or @type = 'rfc-anchor')]"/>
6444
6490
  <xsl:choose>
6445
6491
  <xsl:when test="normalize-space($_doc_ident) != ''">
6446
- <xsl:variable name="type" select="*[local-name() = 'docidentifier'][not(@type = 'DOI' or @type = 'metanorma' or @type = 'ISSN' or @type = 'ISBN' or @type = 'rfc-anchor')]/@type"/>
6492
+ <!-- <xsl:variable name="type" select="*[local-name() = 'docidentifier'][not(@type = 'DOI' or @type = 'metanorma' or @type = 'ISSN' or @type = 'ISBN' or @type = 'rfc-anchor')]/@type"/>
6447
6493
  <xsl:if test="$type != '' and not(contains($_doc_ident, $type))">
6448
6494
  <xsl:value-of select="$type"/><xsl:text> </xsl:text>
6449
- </xsl:if>
6495
+ </xsl:if> -->
6450
6496
  <xsl:value-of select="$_doc_ident"/>
6451
6497
  </xsl:when>
6452
6498
  <xsl:otherwise>
6453
- <xsl:variable name="type" select="*[local-name() = 'docidentifier'][not(@type = 'metanorma')]/@type"/>
6499
+ <!-- <xsl:variable name="type" select="*[local-name() = 'docidentifier'][not(@type = 'metanorma')]/@type"/>
6454
6500
  <xsl:if test="$type != ''">
6455
6501
  <xsl:value-of select="$type"/><xsl:text> </xsl:text>
6456
- </xsl:if>
6502
+ </xsl:if> -->
6457
6503
  <xsl:value-of select="*[local-name() = 'docidentifier'][not(@type = 'metanorma')]"/>
6458
6504
  </xsl:otherwise>
6459
6505
  </xsl:choose>
@@ -6959,4 +7005,14 @@
6959
7005
  <xsl:value-of select="$align"/>
6960
7006
  </xsl:when>
6961
7007
  </xsl:choose>
7008
+ </xsl:template><xsl:template name="setTextAlignment">
7009
+ <xsl:param name="default">left</xsl:param>
7010
+ <xsl:attribute name="text-align">
7011
+ <xsl:choose>
7012
+ <xsl:when test="@align"><xsl:value-of select="@align"/></xsl:when>
7013
+ <xsl:when test="ancestor::*[local-name() = 'td']/@align"><xsl:value-of select="ancestor::*[local-name() = 'td']/@align"/></xsl:when>
7014
+ <xsl:when test="ancestor::*[local-name() = 'th']/@align"><xsl:value-of select="ancestor::*[local-name() = 'th']/@align"/></xsl:when>
7015
+ <xsl:otherwise><xsl:value-of select="$default"/></xsl:otherwise>
7016
+ </xsl:choose>
7017
+ </xsl:attribute>
6962
7018
  </xsl:template></xsl:stylesheet>
@@ -16,7 +16,7 @@ module IsoDoc
16
16
  unpublished(docstatus.text) and
17
17
  set(:stageabbr, docstatus["abbreviation"])
18
18
  end
19
- revdate = isoxml.at(ns("//version/revision-date"))
19
+ revdate = isoxml.at(ns("//bibdata/version/revision-date"))
20
20
  set(:revdate, revdate&.text)
21
21
  end
22
22
 
@@ -13,7 +13,7 @@ module IsoDoc
13
13
  super
14
14
  end
15
15
 
16
- def pdf_stylesheet(docxml)
16
+ def pdf_stylesheet(_docxml)
17
17
  "iec.international-standard.xsl"
18
18
  end
19
19
  end
@@ -7,8 +7,8 @@ module IsoDoc
7
7
  def clause(docxml)
8
8
  docxml.xpath(ns("//clause[not(ancestor::annex)] | "\
9
9
  "//definitions | //references | "\
10
- "//preface/introduction[clause]")).
11
- each do |f|
10
+ "//preface/introduction[clause]"))
11
+ .each do |f|
12
12
  clause1(f)
13
13
  end
14
14
  docxml.xpath(ns("//terms")).each do |f|
@@ -16,27 +16,28 @@ module IsoDoc
16
16
  end
17
17
  end
18
18
 
19
- def termclause1(f)
20
- return clause1(f) unless @is_iev
21
- return if @suppressheadingnumbers || f["unnumbered"]
22
- lbl = @xrefs.anchor(f['id'], :label, true) or return
23
- prefix_name(f, " ", "#{lbl}#{clausedelim}", "title")
19
+ def termclause1(elem)
20
+ return clause1(elem) unless @is_iev
21
+ return if @suppressheadingnumbers || elem["unnumbered"]
22
+
23
+ lbl = @xrefs.anchor(elem["id"], :label, true) or return
24
+ prefix_name(elem, " ", "#{lbl}#{clausedelim}", "title")
24
25
  end
25
26
 
26
- def clause1(f)
27
- IsoDoc::PresentationXMLConvert.instance_method(:clause1).bind(self).
28
- call(f)
27
+ def clause1(elem)
28
+ IsoDoc::PresentationXMLConvert.instance_method(:clause1).bind(self)
29
+ .call(elem)
29
30
  end
30
31
 
31
- def bibdata_i18n(b)
32
+ def bibdata_i18n(bib)
32
33
  fr = IsoDoc::Iec::I18n.new("fr", "Latn")
33
34
  en = IsoDoc::Iec::I18n.new("en", "Latn")
34
35
  [{ lang: "en", i18n: en }, { lang: "fr", i18n: fr }].each do |v|
35
- hash_translate(b, v[:i18n].get["doctype_dict"], "./ext/doctype", v[:lang])
36
- hash_translate(b, v[:i18n].get["stage_dict"], "./status/stage", v[:lang])
37
- hash_translate(b, v[:i18n].get["substage_dict"], "./status/substage", v[:lang])
38
- hash_translate(b, v[:i18n].get["function_dict"], "./ext/function", v[:lang])
39
- hash_translate(b, v[:i18n].get["horizontal_dict"], "./ext/horizontal", v[:lang])
36
+ { doctype_dict: "./ext/doctype", stage_dict: "./status/stage",
37
+ substage_dict: "./status/substage", function_dict: "./ext/function",
38
+ horizontal_dict: "./ext/horizontal" }.each do |lbl, xpath|
39
+ hash_translate(bib, v[:i18n].get[lbl.to_s], xpath, v[:lang])
40
+ end
40
41
  end
41
42
  end
42
43
 
@@ -44,4 +45,3 @@ module IsoDoc
44
45
  end
45
46
  end
46
47
  end
47
-