metanorma-document 0.2.6 → 0.2.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.rubocop_todo.yml +41 -168
- data/Gemfile +2 -0
- data/lib/metanorma/basic_document/ancillary_blocks/figure_block.rb +3 -1
- data/lib/metanorma/basic_document/blocks/basic_block.rb +5 -1
- data/lib/metanorma/basic_document/blocks/note_block.rb +5 -0
- data/lib/metanorma/basic_document/blocks.rb +3 -24
- data/lib/metanorma/basic_document/lists/list.rb +2 -1
- data/lib/metanorma/basic_document/lists/list_item.rb +17 -0
- data/lib/metanorma/basic_document/lists.rb +1 -0
- data/lib/metanorma/basic_document/paragraphs/paragraph_with_footnote.rb +3 -1
- data/lib/metanorma/basic_document/reference_elements/callout.rb +1 -1
- data/lib/metanorma/basic_document/reference_elements/footnote.rb +1 -1
- data/lib/metanorma/basic_document/text_elements/mathml.rb +1 -1
- data/lib/metanorma/bipm_document/root.rb +10 -50
- data/lib/metanorma/bipm_document.rb +0 -2
- data/lib/metanorma/bsi_document/metadata/bsi_bib_data_extension_type.rb +10 -0
- data/lib/metanorma/bsi_document/metadata/bsi_bibliographic_item.rb +15 -0
- data/lib/metanorma/bsi_document/metadata.rb +12 -0
- data/lib/metanorma/bsi_document/root.rb +29 -0
- data/lib/metanorma/bsi_document/sections/bsi_annex_section.rb +25 -0
- data/lib/metanorma/bsi_document/sections/bsi_clause_section.rb +25 -0
- data/lib/metanorma/bsi_document/sections/bsi_sections.rb +27 -0
- data/lib/metanorma/bsi_document/sections.rb +11 -0
- data/lib/metanorma/bsi_document.rb +11 -0
- data/lib/metanorma/cc_document/root.rb +10 -50
- data/lib/metanorma/cc_document.rb +0 -2
- data/lib/metanorma/collection.rb +0 -2
- data/lib/metanorma/document/components/ancillary_blocks/example_block.rb +3 -3
- data/lib/metanorma/document/components/ancillary_blocks/figure_block.rb +2 -0
- data/lib/metanorma/document/components/ancillary_blocks/sourcecode_block.rb +2 -0
- data/lib/metanorma/document/components/blocks/passthrough.rb +21 -0
- data/lib/metanorma/document/components/blocks/requirement_model.rb +159 -0
- data/lib/metanorma/document/components/blocks.rb +10 -0
- data/lib/metanorma/document/components/contrib_metadata/contribution_element_metadata.rb +3 -1
- data/lib/metanorma/document/components/id_elements/image.rb +2 -0
- data/lib/metanorma/document/components/inline/xref_element.rb +8 -0
- data/lib/metanorma/document/components/lists/definition_list.rb +6 -0
- data/lib/metanorma/document/components/lists/list_item.rb +1 -1
- data/lib/metanorma/document/components/lists/ordered_list.rb +6 -0
- data/lib/metanorma/document/components/lists/unordered_list.rb +8 -0
- data/lib/metanorma/document/components/multi_paragraph/admonition_block.rb +8 -0
- data/lib/metanorma/document/components/multi_paragraph/review_block.rb +3 -0
- data/lib/metanorma/document/components/paragraphs/paragraph_block.rb +6 -2
- data/lib/metanorma/document/components/reference_elements/source_element.rb +57 -0
- data/lib/metanorma/document/components/reference_elements.rb +6 -0
- data/lib/metanorma/document/components/sections/references_section.rb +1 -1
- data/lib/metanorma/document/components/tables/table_block.rb +10 -0
- data/lib/metanorma/document/components/tables/table_cell.rb +2 -1
- data/lib/metanorma/document/data_types.rb +0 -4
- data/lib/metanorma/document/elements/add.rb +18 -0
- data/lib/metanorma/document/elements/del.rb +18 -0
- data/lib/metanorma/document/elements.rb +10 -0
- data/lib/metanorma/document/relaton/address.rb +16 -0
- data/lib/metanorma/document/root.rb +1 -3
- data/lib/metanorma/document/version.rb +1 -1
- data/lib/metanorma/document.rb +11 -2
- data/lib/metanorma/gb_document/metadata/gb_bib_data_extension_type.rb +10 -0
- data/lib/metanorma/gb_document/metadata/gb_bibliographic_item.rb +15 -0
- data/lib/metanorma/gb_document/metadata.rb +12 -0
- data/lib/metanorma/gb_document/root.rb +29 -0
- data/lib/metanorma/gb_document.rb +10 -0
- data/lib/metanorma/generic_document/root.rb +31 -0
- data/lib/metanorma/generic_document.rb +7 -0
- data/lib/metanorma/html/base_renderer.rb +206 -120
- data/lib/metanorma/html/bipm_renderer.rb +16 -8
- data/lib/metanorma/html/cc_renderer.rb +0 -1
- data/lib/metanorma/html/component/base.rb +5 -1
- data/lib/metanorma/html/component/footnote_collector.rb +3 -3
- data/lib/metanorma/html/component/index_section.rb +27 -9
- data/lib/metanorma/html/component/index_term_collector.rb +8 -3
- data/lib/metanorma/html/component.rb +2 -1
- data/lib/metanorma/html/drops/figure_drop.rb +14 -5
- data/lib/metanorma/html/drops/formula_drop.rb +7 -2
- data/lib/metanorma/html/drops/sourcecode_drop.rb +6 -2
- data/lib/metanorma/html/drops.rb +2 -1
- data/lib/metanorma/html/generator.rb +16 -6
- data/lib/metanorma/html/iec_renderer.rb +0 -1
- data/lib/metanorma/html/ieee_renderer.rb +0 -1
- data/lib/metanorma/html/ietf_renderer.rb +0 -1
- data/lib/metanorma/html/iho_renderer.rb +1 -2
- data/lib/metanorma/html/iso_renderer.rb +68 -23
- data/lib/metanorma/html/itu_renderer.rb +0 -1
- data/lib/metanorma/html/ogc_renderer.rb +0 -1
- data/lib/metanorma/html/oiml_renderer.rb +0 -1
- data/lib/metanorma/html/pdfa_renderer.rb +0 -1
- data/lib/metanorma/html/ribose_renderer.rb +0 -1
- data/lib/metanorma/html/standard_renderer.rb +61 -28
- data/lib/metanorma/html/theme.rb +2 -2
- data/lib/metanorma/html.rb +48 -1
- data/lib/metanorma/iec_document/root.rb +8 -47
- data/lib/metanorma/iec_document.rb +2 -3
- data/lib/metanorma/ieee_document/root.rb +14 -50
- data/lib/metanorma/ieee_document/sections/ieee_sections.rb +31 -0
- data/lib/metanorma/ieee_document/sections.rb +9 -0
- data/lib/metanorma/ieee_document.rb +3 -3
- data/lib/metanorma/ietf_document/metadata/ietf_bib_data_extension_type.rb +0 -2
- data/lib/metanorma/ietf_document/metadata/ietf_bibliographic_item.rb +0 -2
- data/lib/metanorma/ietf_document/root.rb +14 -50
- data/lib/metanorma/ietf_document/sections/ietf_annex_section.rb +26 -0
- data/lib/metanorma/ietf_document/sections/ietf_clause_section.rb +26 -0
- data/lib/metanorma/ietf_document/sections/ietf_content_section.rb +25 -0
- data/lib/metanorma/ietf_document/sections/ietf_sections.rb +35 -0
- data/lib/metanorma/ietf_document/sections.rb +4 -23
- data/lib/metanorma/ietf_document.rb +4 -3
- data/lib/metanorma/iho_document/metadata/iho_bib_data_extension_type.rb +0 -2
- data/lib/metanorma/iho_document/root.rb +10 -50
- data/lib/metanorma/iho_document.rb +0 -3
- data/lib/metanorma/iso_document/annotation_container.rb +1 -10
- data/lib/metanorma/iso_document/boilerplate.rb +1 -11
- data/lib/metanorma/iso_document/metadata/iso_bibliographic_item.rb +2 -2
- data/lib/metanorma/iso_document/metadata/iso_localized_title.rb +4 -3
- data/lib/metanorma/iso_document/metadata/metanorma_extension.rb +1 -12
- data/lib/metanorma/iso_document/root.rb +7 -73
- data/lib/metanorma/iso_document/sections/colophon.rb +1 -16
- data/lib/metanorma/iso_document/sections/iso_annex_section.rb +11 -133
- data/lib/metanorma/iso_document/sections/iso_clause_section.rb +9 -166
- data/lib/metanorma/iso_document/sections/iso_foreword_section.rb +5 -90
- data/lib/metanorma/iso_document/sections/iso_preface.rb +15 -21
- data/lib/metanorma/iso_document/sections/iso_sections.rb +19 -29
- data/lib/metanorma/iso_document/sections/iso_terms_section.rb +9 -22
- data/lib/metanorma/iso_document/terms/term_expression.rb +2 -47
- data/lib/metanorma/iso_document/terms/term_origin.rb +2 -24
- data/lib/metanorma/iso_document/terms/term_source.rb +4 -32
- data/lib/metanorma/iso_document.rb +2 -2
- data/lib/metanorma/itu_document/root.rb +10 -50
- data/lib/metanorma/itu_document.rb +0 -2
- data/lib/metanorma/jis_document/metadata/jis_bib_data_extension_type.rb +10 -0
- data/lib/metanorma/jis_document/metadata/jis_bibliographic_item.rb +15 -0
- data/lib/metanorma/jis_document/metadata.rb +12 -0
- data/lib/metanorma/jis_document/root.rb +29 -0
- data/lib/metanorma/jis_document/sections/jis_annex_section.rb +20 -0
- data/lib/metanorma/jis_document/sections.rb +9 -0
- data/lib/metanorma/jis_document.rb +11 -0
- data/lib/metanorma/m3d_document/metadata/m3d_bib_data_extension_type.rb +10 -0
- data/lib/metanorma/m3d_document/metadata/m3d_bibliographic_item.rb +15 -0
- data/lib/metanorma/m3d_document/metadata.rb +12 -0
- data/lib/metanorma/m3d_document/root.rb +29 -0
- data/lib/metanorma/m3d_document.rb +10 -0
- data/lib/metanorma/nist_document/metadata/nist_bib_data_extension_type.rb +10 -0
- data/lib/metanorma/nist_document/metadata/nist_bibliographic_item.rb +15 -0
- data/lib/metanorma/nist_document/metadata.rb +12 -0
- data/lib/metanorma/nist_document/root.rb +29 -0
- data/lib/metanorma/nist_document/sections/errata.rb +16 -0
- data/lib/metanorma/nist_document/sections/errata_clause.rb +20 -0
- data/lib/metanorma/nist_document/sections/errata_row.rb +22 -0
- data/lib/metanorma/nist_document/sections/nist_preface.rb +30 -0
- data/lib/metanorma/nist_document/sections.rb +12 -0
- data/lib/metanorma/nist_document.rb +11 -0
- data/lib/metanorma/ogc_document/root.rb +10 -50
- data/lib/metanorma/ogc_document.rb +0 -2
- data/lib/metanorma/oiml_document/root.rb +8 -47
- data/lib/metanorma/oiml_document.rb +2 -3
- data/lib/metanorma/plateau_document/metadata/plateau_bibliographic_item.rb +13 -0
- data/lib/metanorma/plateau_document/metadata.rb +10 -0
- data/lib/metanorma/plateau_document/root.rb +29 -0
- data/lib/metanorma/plateau_document.rb +10 -0
- data/lib/metanorma/registers/setup.rb +162 -0
- data/lib/metanorma/registers.rb +7 -0
- data/lib/metanorma/ribose_document/root.rb +10 -52
- data/lib/metanorma/ribose_document.rb +0 -2
- data/lib/metanorma/standard_document/annotation_container.rb +14 -0
- data/lib/metanorma/standard_document/block_attributes.rb +268 -0
- data/lib/metanorma/standard_document/blocks/passthrough.rb +1 -18
- data/lib/metanorma/standard_document/blocks/requirement_model.rb +18 -163
- data/lib/metanorma/standard_document/boilerplate.rb +14 -0
- data/lib/metanorma/standard_document/elements/add.rb +1 -17
- data/lib/metanorma/standard_document/elements/del.rb +1 -17
- data/lib/metanorma/standard_document/metadata/metanorma_extension.rb +16 -0
- data/lib/metanorma/standard_document/metadata.rb +2 -0
- data/lib/metanorma/standard_document/refs/reference_to_term.rb +2 -1
- data/lib/metanorma/standard_document/root_attributes.rb +78 -0
- data/lib/metanorma/standard_document/sections/abstract.rb +1 -3
- data/lib/metanorma/standard_document/sections/acknowledgements.rb +1 -3
- data/lib/metanorma/standard_document/sections/annex_section.rb +56 -19
- data/lib/metanorma/standard_document/sections/bibliography_section.rb +1 -2
- data/lib/metanorma/standard_document/sections/clause_section.rb +75 -13
- data/lib/metanorma/standard_document/sections/colophon.rb +16 -0
- data/lib/metanorma/standard_document/sections/definition_section.rb +43 -46
- data/lib/metanorma/standard_document/sections/floating_section_title.rb +23 -0
- data/lib/metanorma/standard_document/sections/foreword.rb +1 -3
- data/lib/metanorma/standard_document/sections/introduction.rb +1 -4
- data/lib/metanorma/standard_document/sections/misc_container.rb +5 -2
- data/lib/metanorma/standard_document/sections/preface.rb +36 -0
- data/lib/metanorma/standard_document/sections/sections.rb +40 -0
- data/lib/metanorma/standard_document/sections/standard_content_section.rb +26 -12
- data/lib/metanorma/standard_document/sections/terms_section.rb +45 -13
- data/lib/metanorma/standard_document/sections.rb +6 -2
- data/lib/metanorma/standard_document/terms/designation.rb +1 -1
- data/lib/metanorma/standard_document/terms/term_expression.rb +51 -0
- data/lib/metanorma/standard_document/terms.rb +1 -0
- data/lib/metanorma/standard_document.rb +10 -2
- data/lib/metanorma/un_document/metadata/un_bib_data_extension_type.rb +10 -0
- data/lib/metanorma/un_document/metadata/un_bibliographic_item.rb +15 -0
- data/lib/metanorma/un_document/metadata.rb +12 -0
- data/lib/metanorma/un_document/root.rb +29 -0
- data/lib/metanorma/un_document/sections/un_preface.rb +23 -0
- data/lib/metanorma/un_document/sections/un_sections.rb +24 -0
- data/lib/metanorma/un_document/sections.rb +10 -0
- data/lib/metanorma/un_document.rb +11 -0
- metadata +77 -3
- data/lib/metanorma/html/whitespace_patch.rb +0 -47
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 4c66a8c91095adeaaa7d4cde6aacda4cbeae30670484c0dbb28a85d663d4d5dd
|
|
4
|
+
data.tar.gz: 6287b7a61c71833682c54f94e35e4d8dd423db10a5fc6c2086f00c50d865a185
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ed0522009ebcffc3b73c0717ff518d7fc3d422cc8e7be88ade3aa6c893b6569a07db035cd40ba6738cc1602261e588307b5264c0139a122d35d65ae86e2c7a81
|
|
7
|
+
data.tar.gz: 6456bc28350855d30cbeed7e6b807220b390560d030e5ae1f85733d4672df15e834badc1e07cdeee5af59a804a0ac96fc12830e1bee2a3e74836a9f8b0cce349
|
data/.rubocop_todo.yml
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# This configuration was generated by
|
|
2
2
|
# `rubocop --auto-gen-config`
|
|
3
|
-
# on 2026-05-
|
|
3
|
+
# on 2026-05-21 09:20:40 UTC using RuboCop version 1.86.1.
|
|
4
4
|
# The point is for the user to remove these configuration records
|
|
5
5
|
# one by one as the offenses are removed from the code base.
|
|
6
6
|
# Note that changes in the inspected code, or installation of new
|
|
@@ -11,67 +11,28 @@ Gemspec/RequiredRubyVersion:
|
|
|
11
11
|
Exclude:
|
|
12
12
|
- 'metanorma-document.gemspec'
|
|
13
13
|
|
|
14
|
-
# Offense count:
|
|
14
|
+
# Offense count: 9
|
|
15
15
|
# This cop supports safe autocorrection (--autocorrect).
|
|
16
16
|
# Configuration parameters: EnforcedStyle, IndentationWidth.
|
|
17
17
|
# SupportedStyles: with_first_argument, with_fixed_indentation
|
|
18
18
|
Layout/ArgumentAlignment:
|
|
19
19
|
Exclude:
|
|
20
|
-
- 'lib/metanorma/
|
|
21
|
-
- 'spec/metanorma/
|
|
20
|
+
- 'lib/metanorma/standard_document.rb'
|
|
21
|
+
- 'spec/metanorma/flavor_roots/flavor_roots_spec.rb'
|
|
22
22
|
|
|
23
|
-
# Offense count:
|
|
24
|
-
# This cop supports safe autocorrection (--autocorrect).
|
|
25
|
-
Layout/EmptyLineAfterGuardClause:
|
|
26
|
-
Exclude:
|
|
27
|
-
- 'lib/metanorma/html/generator.rb'
|
|
28
|
-
- 'lib/metanorma/iso_document/metadata/iso_localized_title.rb'
|
|
29
|
-
|
|
30
|
-
# Offense count: 11
|
|
31
|
-
# This cop supports safe autocorrection (--autocorrect).
|
|
32
|
-
# Configuration parameters: EnforcedStyle.
|
|
33
|
-
# SupportedStyles: empty_lines, empty_lines_except_namespace, empty_lines_special, no_empty_lines, beginning_only, ending_only
|
|
34
|
-
Layout/EmptyLinesAroundClassBody:
|
|
35
|
-
Exclude:
|
|
36
|
-
- 'lib/metanorma/html/bipm_renderer.rb'
|
|
37
|
-
- 'lib/metanorma/html/cc_renderer.rb'
|
|
38
|
-
- 'lib/metanorma/html/iec_renderer.rb'
|
|
39
|
-
- 'lib/metanorma/html/ieee_renderer.rb'
|
|
40
|
-
- 'lib/metanorma/html/ietf_renderer.rb'
|
|
41
|
-
- 'lib/metanorma/html/iho_renderer.rb'
|
|
42
|
-
- 'lib/metanorma/html/itu_renderer.rb'
|
|
43
|
-
- 'lib/metanorma/html/ogc_renderer.rb'
|
|
44
|
-
- 'lib/metanorma/html/oiml_renderer.rb'
|
|
45
|
-
- 'lib/metanorma/html/pdfa_renderer.rb'
|
|
46
|
-
- 'lib/metanorma/html/ribose_renderer.rb'
|
|
47
|
-
|
|
48
|
-
# Offense count: 5
|
|
49
|
-
# This cop supports safe autocorrection (--autocorrect).
|
|
50
|
-
# Configuration parameters: AllowForAlignment, AllowBeforeTrailingComments, ForceEqualSignAlignment.
|
|
51
|
-
Layout/ExtraSpacing:
|
|
52
|
-
Exclude:
|
|
53
|
-
- 'lib/metanorma/html/bipm_renderer.rb'
|
|
54
|
-
- 'lib/metanorma/html/generator.rb'
|
|
55
|
-
- 'lib/metanorma/html/iho_renderer.rb'
|
|
56
|
-
- 'lib/metanorma/html/theme.rb'
|
|
57
|
-
|
|
58
|
-
# Offense count: 801
|
|
23
|
+
# Offense count: 666
|
|
59
24
|
# This cop supports safe autocorrection (--autocorrect).
|
|
60
25
|
# Configuration parameters: Max, AllowHeredoc, AllowURI, AllowQualifiedName, URISchemes, AllowRBSInlineAnnotation, AllowCopDirectives, AllowedPatterns, SplitStrings.
|
|
61
26
|
# URISchemes: http, https
|
|
62
27
|
Layout/LineLength:
|
|
63
28
|
Enabled: false
|
|
64
29
|
|
|
65
|
-
# Offense count:
|
|
30
|
+
# Offense count: 1
|
|
66
31
|
# This cop supports safe autocorrection (--autocorrect).
|
|
67
|
-
# Configuration parameters:
|
|
68
|
-
|
|
69
|
-
# SupportedStylesForRationalLiterals: space, no_space
|
|
70
|
-
Layout/SpaceAroundOperators:
|
|
32
|
+
# Configuration parameters: AllowInHeredoc.
|
|
33
|
+
Layout/TrailingWhitespace:
|
|
71
34
|
Exclude:
|
|
72
|
-
- 'lib/metanorma/
|
|
73
|
-
- 'lib/metanorma/html/iho_renderer.rb'
|
|
74
|
-
- 'lib/metanorma/html/theme.rb'
|
|
35
|
+
- 'lib/metanorma/standard_document.rb'
|
|
75
36
|
|
|
76
37
|
# Offense count: 1
|
|
77
38
|
# Configuration parameters: AllowedMethods.
|
|
@@ -107,37 +68,23 @@ Lint/StructNewOverride:
|
|
|
107
68
|
Exclude:
|
|
108
69
|
- 'lib/metanorma/html/component/index_term_collector.rb'
|
|
109
70
|
|
|
110
|
-
# Offense count:
|
|
111
|
-
# This cop supports safe autocorrection (--autocorrect).
|
|
112
|
-
# Configuration parameters: AllowUnusedKeywordArguments, IgnoreEmptyMethods, IgnoreNotImplementedMethods, NotImplementedExceptions.
|
|
113
|
-
# NotImplementedExceptions: NotImplementedError
|
|
114
|
-
Lint/UnusedMethodArgument:
|
|
115
|
-
Exclude:
|
|
116
|
-
- 'lib/metanorma/html/component/index_section.rb'
|
|
117
|
-
- 'lib/metanorma/html/generator.rb'
|
|
118
|
-
|
|
119
|
-
# Offense count: 1
|
|
120
|
-
Lint/UselessConstantScoping:
|
|
121
|
-
Exclude:
|
|
122
|
-
- 'lib/metanorma/html/base_renderer.rb'
|
|
123
|
-
|
|
124
|
-
# Offense count: 78
|
|
71
|
+
# Offense count: 80
|
|
125
72
|
# Configuration parameters: AllowedMethods, AllowedPatterns, CountRepeatedAttributes, Max.
|
|
126
73
|
Metrics/AbcSize:
|
|
127
74
|
Enabled: false
|
|
128
75
|
|
|
129
|
-
# Offense count:
|
|
76
|
+
# Offense count: 23
|
|
130
77
|
# Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns, inherit_mode.
|
|
131
78
|
# AllowedMethods: refine
|
|
132
79
|
Metrics/BlockLength:
|
|
133
|
-
Max:
|
|
80
|
+
Max: 80
|
|
134
81
|
|
|
135
|
-
# Offense count:
|
|
82
|
+
# Offense count: 1
|
|
136
83
|
# Configuration parameters: CountBlocks, CountModifierForms.
|
|
137
84
|
Metrics/BlockNesting:
|
|
138
85
|
Max: 4
|
|
139
86
|
|
|
140
|
-
# Offense count:
|
|
87
|
+
# Offense count: 56
|
|
141
88
|
# Configuration parameters: AllowedMethods, AllowedPatterns, Max.
|
|
142
89
|
Metrics/CyclomaticComplexity:
|
|
143
90
|
Exclude:
|
|
@@ -145,10 +92,8 @@ Metrics/CyclomaticComplexity:
|
|
|
145
92
|
- 'lib/metanorma/html/base_renderer.rb'
|
|
146
93
|
- 'lib/metanorma/html/bipm_renderer.rb'
|
|
147
94
|
- 'lib/metanorma/html/component/index_term_collector.rb'
|
|
148
|
-
- 'lib/metanorma/html/drops/example_drop.rb'
|
|
149
95
|
- 'lib/metanorma/html/drops/figure_drop.rb'
|
|
150
96
|
- 'lib/metanorma/html/drops/formula_drop.rb'
|
|
151
|
-
- 'lib/metanorma/html/drops/note_drop.rb'
|
|
152
97
|
- 'lib/metanorma/html/generator.rb'
|
|
153
98
|
- 'lib/metanorma/html/iso_renderer.rb'
|
|
154
99
|
- 'lib/metanorma/html/ogc_renderer.rb'
|
|
@@ -156,17 +101,17 @@ Metrics/CyclomaticComplexity:
|
|
|
156
101
|
- 'lib/metanorma/html/theme.rb'
|
|
157
102
|
- 'lib/metanorma/iso_document/metadata/iso_localized_title.rb'
|
|
158
103
|
|
|
159
|
-
# Offense count:
|
|
104
|
+
# Offense count: 101
|
|
160
105
|
# Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns.
|
|
161
106
|
Metrics/MethodLength:
|
|
162
|
-
Max:
|
|
107
|
+
Max: 95
|
|
163
108
|
|
|
164
109
|
# Offense count: 1
|
|
165
110
|
# Configuration parameters: CountKeywordArgs, MaxOptionalParameters.
|
|
166
111
|
Metrics/ParameterLists:
|
|
167
112
|
Max: 7
|
|
168
113
|
|
|
169
|
-
# Offense count:
|
|
114
|
+
# Offense count: 51
|
|
170
115
|
# Configuration parameters: AllowedMethods, AllowedPatterns, Max.
|
|
171
116
|
Metrics/PerceivedComplexity:
|
|
172
117
|
Exclude:
|
|
@@ -174,10 +119,8 @@ Metrics/PerceivedComplexity:
|
|
|
174
119
|
- 'lib/metanorma/html/base_renderer.rb'
|
|
175
120
|
- 'lib/metanorma/html/bipm_renderer.rb'
|
|
176
121
|
- 'lib/metanorma/html/component/index_term_collector.rb'
|
|
177
|
-
- 'lib/metanorma/html/drops/example_drop.rb'
|
|
178
122
|
- 'lib/metanorma/html/drops/figure_drop.rb'
|
|
179
123
|
- 'lib/metanorma/html/drops/formula_drop.rb'
|
|
180
|
-
- 'lib/metanorma/html/drops/note_drop.rb'
|
|
181
124
|
- 'lib/metanorma/html/generator.rb'
|
|
182
125
|
- 'lib/metanorma/html/iso_renderer.rb'
|
|
183
126
|
- 'lib/metanorma/html/ogc_renderer.rb'
|
|
@@ -185,15 +128,6 @@ Metrics/PerceivedComplexity:
|
|
|
185
128
|
- 'lib/metanorma/html/theme.rb'
|
|
186
129
|
- 'lib/metanorma/iso_document/metadata/iso_localized_title.rb'
|
|
187
130
|
|
|
188
|
-
# Offense count: 4
|
|
189
|
-
# This cop supports safe autocorrection (--autocorrect).
|
|
190
|
-
# Configuration parameters: EnforcedStyle, BlockForwardingName.
|
|
191
|
-
# SupportedStyles: anonymous, explicit
|
|
192
|
-
Naming/BlockForwarding:
|
|
193
|
-
Exclude:
|
|
194
|
-
- 'lib/metanorma/html/base_renderer.rb'
|
|
195
|
-
- 'lib/metanorma/html/component/footnote_collector.rb'
|
|
196
|
-
|
|
197
131
|
# Offense count: 28
|
|
198
132
|
# Configuration parameters: MinNameLength, AllowNamesEndingInNumbers, AllowedNames, ForbiddenNames.
|
|
199
133
|
# AllowedNames: as, at, by, cc, db, id, if, in, io, ip, of, on, os, pp, to
|
|
@@ -223,47 +157,50 @@ Naming/PredicatePrefix:
|
|
|
223
157
|
Exclude:
|
|
224
158
|
- 'lib/metanorma/html/standard_renderer.rb'
|
|
225
159
|
|
|
226
|
-
# Offense count:
|
|
160
|
+
# Offense count: 1
|
|
161
|
+
Performance/MapMethodChain:
|
|
162
|
+
Exclude:
|
|
163
|
+
- 'spec/metanorma/flavor_roots/flavor_roots_spec.rb'
|
|
164
|
+
|
|
165
|
+
# Offense count: 7
|
|
166
|
+
RSpec/BeforeAfterAll:
|
|
167
|
+
Exclude:
|
|
168
|
+
- 'spec/metanorma/flavor_roots/flavor_roots_spec.rb'
|
|
169
|
+
|
|
170
|
+
# Offense count: 18
|
|
227
171
|
# Configuration parameters: IgnoredMetadata.
|
|
228
172
|
RSpec/DescribeClass:
|
|
229
|
-
|
|
230
|
-
- 'spec/metanorma/document_spec.rb'
|
|
231
|
-
- 'spec/metanorma/html/renderer/architecture_spec.rb'
|
|
232
|
-
- 'spec/metanorma/html/renderer/class_ownership_spec.rb'
|
|
233
|
-
- 'spec/metanorma/html/renderer/dead_code_removal_spec.rb'
|
|
234
|
-
- 'spec/metanorma/html/renderer/section_rendering_spec.rb'
|
|
235
|
-
- 'spec/metanorma/html/renderer/type_registry_spec.rb'
|
|
236
|
-
- 'spec/metanorma/iso_document/metadata/title_roundtrip_spec.rb'
|
|
237
|
-
- 'spec/metanorma/iso_document/roundtrip/bipm_roundtrip_spec.rb'
|
|
238
|
-
- 'spec/metanorma/iso_document/roundtrip/cc_roundtrip_spec.rb'
|
|
239
|
-
- 'spec/metanorma/iso_document/roundtrip/iso_amd_roundtrip_spec.rb'
|
|
240
|
-
- 'spec/metanorma/iso_document/roundtrip/iso_is_roundtrip_spec.rb'
|
|
241
|
-
- 'spec/metanorma/iso_document/roundtrip/itu_roundtrip_spec.rb'
|
|
242
|
-
- 'spec/metanorma/iso_document/roundtrip/ogc_roundtrip_spec.rb'
|
|
243
|
-
- 'spec/metanorma/iso_document/roundtrip/oiml_collection_roundtrip_spec.rb'
|
|
244
|
-
- 'spec/metanorma/iso_document/roundtrip/oiml_roundtrip_spec.rb'
|
|
173
|
+
Enabled: false
|
|
245
174
|
|
|
246
|
-
# Offense count:
|
|
175
|
+
# Offense count: 95
|
|
247
176
|
# Configuration parameters: CountAsOne.
|
|
248
177
|
RSpec/ExampleLength:
|
|
249
|
-
Max:
|
|
178
|
+
Max: 29
|
|
250
179
|
|
|
251
180
|
# Offense count: 1
|
|
252
181
|
RSpec/LeakyConstantDeclaration:
|
|
253
182
|
Exclude:
|
|
254
183
|
- 'spec/metanorma/html/renderer/class_ownership_spec.rb'
|
|
255
184
|
|
|
256
|
-
# Offense count:
|
|
185
|
+
# Offense count: 2
|
|
257
186
|
RSpec/MultipleDescribes:
|
|
258
187
|
Exclude:
|
|
259
188
|
- 'spec/metanorma/document_spec.rb'
|
|
189
|
+
- 'spec/metanorma/standard_document/sections_spec.rb'
|
|
260
190
|
|
|
261
191
|
# Offense count: 1
|
|
262
192
|
# Configuration parameters: AllowSubject.
|
|
263
193
|
RSpec/MultipleMemoizedHelpers:
|
|
264
194
|
Max: 7
|
|
265
195
|
|
|
266
|
-
# Offense count:
|
|
196
|
+
# Offense count: 30
|
|
197
|
+
# Configuration parameters: EnforcedStyle, IgnoreSharedExamples.
|
|
198
|
+
# SupportedStyles: always, named_only
|
|
199
|
+
RSpec/NamedSubject:
|
|
200
|
+
Exclude:
|
|
201
|
+
- 'spec/metanorma/flavor_roots/flavor_roots_spec.rb'
|
|
202
|
+
|
|
203
|
+
# Offense count: 599
|
|
267
204
|
# Configuration parameters: AllowedPatterns.
|
|
268
205
|
# AllowedPatterns: ^expect_, ^assert_
|
|
269
206
|
RSpec/NoExpectationExample:
|
|
@@ -275,28 +212,6 @@ RSpec/NoExpectationExample:
|
|
|
275
212
|
RSpec/SpecFilePathFormat:
|
|
276
213
|
Enabled: false
|
|
277
214
|
|
|
278
|
-
# Offense count: 4
|
|
279
|
-
# This cop supports safe autocorrection (--autocorrect).
|
|
280
|
-
# Configuration parameters: AllowOnlyRestArgument, UseAnonymousForwarding, RedundantRestArgumentNames, RedundantKeywordRestArgumentNames, RedundantBlockArgumentNames.
|
|
281
|
-
# RedundantRestArgumentNames: args, arguments
|
|
282
|
-
# RedundantKeywordRestArgumentNames: kwargs, options, opts
|
|
283
|
-
# RedundantBlockArgumentNames: blk, block, proc
|
|
284
|
-
Style/ArgumentsForwarding:
|
|
285
|
-
Exclude:
|
|
286
|
-
- 'lib/metanorma/html/base_renderer.rb'
|
|
287
|
-
- 'lib/metanorma/html/component/footnote_collector.rb'
|
|
288
|
-
|
|
289
|
-
# Offense count: 1
|
|
290
|
-
# This cop supports safe autocorrection (--autocorrect).
|
|
291
|
-
# Configuration parameters: EnforcedStyle, ProceduralMethods, FunctionalMethods, AllowedMethods, AllowedPatterns, AllowBracesOnProceduralOneLiners, BracesRequiredMethods.
|
|
292
|
-
# SupportedStyles: line_count_based, semantic, braces_for_chaining, always_braces
|
|
293
|
-
# ProceduralMethods: benchmark, bm, bmbm, create, each_with_object, measure, new, realtime, tap, with_object
|
|
294
|
-
# FunctionalMethods: let, let!, subject, watch
|
|
295
|
-
# AllowedMethods: lambda, proc, it
|
|
296
|
-
Style/BlockDelimiters:
|
|
297
|
-
Exclude:
|
|
298
|
-
- 'lib/metanorma/iso_document/metadata/iso_bibliographic_item.rb'
|
|
299
|
-
|
|
300
215
|
# Offense count: 5
|
|
301
216
|
# This cop supports safe autocorrection (--autocorrect).
|
|
302
217
|
Style/ComparableClamp:
|
|
@@ -305,13 +220,6 @@ Style/ComparableClamp:
|
|
|
305
220
|
- 'lib/metanorma/html/iso_renderer.rb'
|
|
306
221
|
- 'lib/metanorma/html/standard_renderer.rb'
|
|
307
222
|
|
|
308
|
-
# Offense count: 1
|
|
309
|
-
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
310
|
-
# Configuration parameters: InverseMethods, InverseBlocks.
|
|
311
|
-
Style/InverseMethods:
|
|
312
|
-
Exclude:
|
|
313
|
-
- 'lib/metanorma/html/component/index_term_collector.rb'
|
|
314
|
-
|
|
315
223
|
# Offense count: 1
|
|
316
224
|
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
317
225
|
# Configuration parameters: EnforcedStyle.
|
|
@@ -319,38 +227,3 @@ Style/InverseMethods:
|
|
|
319
227
|
Style/MutableConstant:
|
|
320
228
|
Exclude:
|
|
321
229
|
- 'lib/metanorma/html/base_renderer.rb'
|
|
322
|
-
|
|
323
|
-
# Offense count: 1
|
|
324
|
-
# This cop supports safe autocorrection (--autocorrect).
|
|
325
|
-
Style/NegatedIfElseCondition:
|
|
326
|
-
Exclude:
|
|
327
|
-
- 'lib/metanorma/iso_document/metadata/iso_localized_title.rb'
|
|
328
|
-
|
|
329
|
-
# Offense count: 1
|
|
330
|
-
# This cop supports safe autocorrection (--autocorrect).
|
|
331
|
-
Style/RedundantRegexpArgument:
|
|
332
|
-
Exclude:
|
|
333
|
-
- 'lib/metanorma/html/bipm_renderer.rb'
|
|
334
|
-
|
|
335
|
-
# Offense count: 2
|
|
336
|
-
# This cop supports safe autocorrection (--autocorrect).
|
|
337
|
-
Style/RescueModifier:
|
|
338
|
-
Exclude:
|
|
339
|
-
- 'lib/metanorma/html/generator.rb'
|
|
340
|
-
|
|
341
|
-
# Offense count: 1
|
|
342
|
-
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
343
|
-
# Configuration parameters: ConvertCodeThatCanStartToReturnNil, AllowedMethods, MaxChainLength.
|
|
344
|
-
# AllowedMethods: present?, blank?, presence, try, try!
|
|
345
|
-
Style/SafeNavigation:
|
|
346
|
-
Exclude:
|
|
347
|
-
- 'lib/metanorma/html/bipm_renderer.rb'
|
|
348
|
-
|
|
349
|
-
# Offense count: 2
|
|
350
|
-
# This cop supports safe autocorrection (--autocorrect).
|
|
351
|
-
# Configuration parameters: EnforcedStyleForMultiline.
|
|
352
|
-
# SupportedStylesForMultiline: comma, consistent_comma, diff_comma, no_comma
|
|
353
|
-
Style/TrailingCommaInArguments:
|
|
354
|
-
Exclude:
|
|
355
|
-
- 'lib/metanorma/html/component/footnote_collector.rb'
|
|
356
|
-
- 'lib/metanorma/html/component/index_term_collector.rb'
|
data/Gemfile
CHANGED
|
@@ -42,7 +42,9 @@ module Metanorma
|
|
|
42
42
|
attribute :definitions, Metanorma::BasicDocument::Lists::DefinitionList
|
|
43
43
|
|
|
44
44
|
# Optional footnotes specific to the figure.
|
|
45
|
-
attribute :footnotes,
|
|
45
|
+
attribute :footnotes,
|
|
46
|
+
Metanorma::BasicDocument::ReferenceElements::Footnote,
|
|
47
|
+
collection: true
|
|
46
48
|
|
|
47
49
|
xml do
|
|
48
50
|
element "figure"
|
|
@@ -3,9 +3,13 @@
|
|
|
3
3
|
module Metanorma
|
|
4
4
|
module BasicDocument
|
|
5
5
|
module Blocks
|
|
6
|
-
class BasicBlock <
|
|
6
|
+
class BasicBlock < Metanorma::BasicDocument::Blocks::BasicBlockNoNotes
|
|
7
|
+
attribute :notes, "Metanorma::BasicDocument::Blocks::NoteBlock",
|
|
8
|
+
collection: true
|
|
9
|
+
|
|
7
10
|
xml do
|
|
8
11
|
element "basic-block"
|
|
12
|
+
map_element "notes", to: :notes
|
|
9
13
|
end
|
|
10
14
|
end
|
|
11
15
|
end
|
|
@@ -4,8 +4,13 @@ module Metanorma
|
|
|
4
4
|
module BasicDocument
|
|
5
5
|
module Blocks
|
|
6
6
|
class NoteBlock < Metanorma::BasicDocument::Blocks::BasicBlockNoNotes
|
|
7
|
+
attribute :content,
|
|
8
|
+
"Metanorma::BasicDocument::Paragraphs::ParagraphBlock",
|
|
9
|
+
collection: true
|
|
10
|
+
|
|
7
11
|
xml do
|
|
8
12
|
element "note"
|
|
13
|
+
map_element "content", to: :content
|
|
9
14
|
end
|
|
10
15
|
end
|
|
11
16
|
end
|
|
@@ -1,32 +1,11 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
require_relative "blocks/basic_block_no_notes"
|
|
4
|
-
require_relative "blocks/basic_block"
|
|
5
|
-
require_relative "blocks/note_block"
|
|
6
|
-
|
|
7
3
|
module Metanorma
|
|
8
4
|
module BasicDocument
|
|
9
5
|
module Blocks
|
|
6
|
+
autoload :BasicBlock, "#{__dir__}/blocks/basic_block"
|
|
7
|
+
autoload :BasicBlockNoNotes, "#{__dir__}/blocks/basic_block_no_notes"
|
|
8
|
+
autoload :NoteBlock, "#{__dir__}/blocks/note_block"
|
|
10
9
|
end
|
|
11
10
|
end
|
|
12
11
|
end
|
|
13
|
-
|
|
14
|
-
Metanorma::BasicDocument::Blocks::BasicBlock.class_eval do
|
|
15
|
-
attribute :notes, Metanorma::BasicDocument::Blocks::NoteBlock,
|
|
16
|
-
collection: true
|
|
17
|
-
|
|
18
|
-
xml do
|
|
19
|
-
map_element "notes", to: :notes
|
|
20
|
-
end
|
|
21
|
-
end
|
|
22
|
-
|
|
23
|
-
require_relative "paragraphs"
|
|
24
|
-
|
|
25
|
-
Metanorma::BasicDocument::Blocks::NoteBlock.class_eval do
|
|
26
|
-
attribute :content,
|
|
27
|
-
Metanorma::BasicDocument::Paragraphs::ParagraphBlock, collection: true
|
|
28
|
-
|
|
29
|
-
xml do
|
|
30
|
-
map_element "content", to: :content
|
|
31
|
-
end
|
|
32
|
-
end
|
|
@@ -5,7 +5,8 @@ module Metanorma
|
|
|
5
5
|
module Lists
|
|
6
6
|
# List block.
|
|
7
7
|
class List < Metanorma::BasicDocument::Blocks::BasicBlock
|
|
8
|
-
attribute :listitem,
|
|
8
|
+
attribute :listitem, Metanorma::BasicDocument::Lists::ListItem,
|
|
9
|
+
collection: true
|
|
9
10
|
|
|
10
11
|
xml do
|
|
11
12
|
element "list"
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Metanorma
|
|
4
|
+
module BasicDocument
|
|
5
|
+
module Lists
|
|
6
|
+
class ListItem < Lutaml::Model::Serializable
|
|
7
|
+
attribute :content, :string, collection: true
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "listitem"
|
|
11
|
+
mixed_content
|
|
12
|
+
map_content to: :content
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
17
|
+
end
|
|
@@ -6,6 +6,7 @@ module Metanorma
|
|
|
6
6
|
autoload :Definition, "#{__dir__}/lists/definition"
|
|
7
7
|
autoload :DefinitionList, "#{__dir__}/lists/definition_list"
|
|
8
8
|
autoload :List, "#{__dir__}/lists/list"
|
|
9
|
+
autoload :ListItem, "#{__dir__}/lists/list_item"
|
|
9
10
|
autoload :OrderedList, "#{__dir__}/lists/ordered_list"
|
|
10
11
|
autoload :OrderedListType, "#{__dir__}/lists/ordered_list_type"
|
|
11
12
|
autoload :UnorderedList, "#{__dir__}/lists/unordered_list"
|
|
@@ -9,7 +9,9 @@ module Metanorma
|
|
|
9
9
|
# annotations).
|
|
10
10
|
class ParagraphWithFootnote < Metanorma::BasicDocument::Paragraphs::ParagraphBlock
|
|
11
11
|
# Footnotes contained in the paragraph.
|
|
12
|
-
attribute :footnotes,
|
|
12
|
+
attribute :footnotes,
|
|
13
|
+
Metanorma::BasicDocument::ReferenceElements::Footnote,
|
|
14
|
+
collection: true
|
|
13
15
|
|
|
14
16
|
xml do
|
|
15
17
|
element "paragraph-with-footnote"
|
|
@@ -7,7 +7,7 @@ module Metanorma
|
|
|
7
7
|
# The target of the callout is understood to be the location of the callout within the source code;
|
|
8
8
|
# the extent of the target is not expressed overtly.
|
|
9
9
|
class Callout < Metanorma::BasicDocument::ReferenceElements::ReferenceToIdElement
|
|
10
|
-
attribute :type,
|
|
10
|
+
attribute :type, :string
|
|
11
11
|
attribute :text, Metanorma::BasicDocument::TextElements::TextElement
|
|
12
12
|
|
|
13
13
|
xml do
|
|
@@ -5,7 +5,7 @@ module Metanorma
|
|
|
5
5
|
module ReferenceElements
|
|
6
6
|
# Inline reference to a paragraph or paragraphs, appearing as a footnote.
|
|
7
7
|
class Footnote < Metanorma::BasicDocument::ReferenceElements::ReferenceToIdWithParagraphElement
|
|
8
|
-
attribute :type,
|
|
8
|
+
attribute :type, :string
|
|
9
9
|
|
|
10
10
|
xml do
|
|
11
11
|
element "footnote"
|
|
@@ -1,64 +1,24 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
require "metanorma/standard_document"
|
|
4
|
-
require "metanorma/iso_document"
|
|
5
|
-
|
|
6
3
|
module Metanorma
|
|
7
4
|
module BipmDocument
|
|
8
|
-
class Root <
|
|
9
|
-
|
|
10
|
-
attribute :type, :string
|
|
11
|
-
attribute :schema_version, :string
|
|
12
|
-
attribute :flavor, :string
|
|
5
|
+
class Root < Lutaml::Model::Serializable
|
|
6
|
+
include Metanorma::StandardDocument::RootAttributes
|
|
13
7
|
|
|
14
8
|
attribute :bibdata, Metadata::BipmBibliographicItem
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
9
|
+
attribute :preface,
|
|
10
|
+
Metanorma::StandardDocument::Sections::Preface
|
|
11
|
+
attribute :sections,
|
|
12
|
+
Metanorma::StandardDocument::Sections::Sections
|
|
13
|
+
attribute :annex,
|
|
14
|
+
Metanorma::StandardDocument::Sections::AnnexSection,
|
|
18
15
|
collection: true
|
|
19
16
|
|
|
20
|
-
attribute :preface, Metanorma::IsoDocument::Sections::IsoPreface
|
|
21
|
-
attribute :sections, Metanorma::IsoDocument::Sections::IsoSections
|
|
22
|
-
attribute :annex, Metanorma::IsoDocument::Sections::IsoAnnexSection,
|
|
23
|
-
collection: true
|
|
24
|
-
attribute :bibliography,
|
|
25
|
-
Metanorma::StandardDocument::Sections::BibliographySection
|
|
26
|
-
attribute :boilerplate, Metanorma::IsoDocument::Boilerplate
|
|
27
|
-
attribute :metanorma_extension,
|
|
28
|
-
Metanorma::IsoDocument::Metadata::MetanormaExtension
|
|
29
|
-
attribute :annotation_container, Metanorma::IsoDocument::AnnotationContainer
|
|
30
|
-
attribute :indexsect,
|
|
31
|
-
Metanorma::Document::Components::Sections::BasicSection
|
|
32
|
-
attribute :autonum, :string
|
|
33
|
-
attribute :fmt_xref_label, :string
|
|
34
|
-
attribute :localized_strings,
|
|
35
|
-
Metanorma::Document::Components::Inline::LocalizedStringsElement
|
|
36
|
-
attribute :fmt_footnote_container,
|
|
37
|
-
Metanorma::Document::Components::Inline::FmtFootnoteContainerElement
|
|
38
|
-
attribute :colophon, Metanorma::IsoDocument::Sections::Colophon
|
|
39
|
-
|
|
40
17
|
xml do
|
|
41
18
|
element "metanorma"
|
|
42
19
|
namespace Metanorma::StandardDocument::Namespace
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
map_attribute "schema-version", to: :schema_version
|
|
46
|
-
map_attribute "flavor", to: :flavor
|
|
47
|
-
map_element "bibdata", to: :bibdata
|
|
48
|
-
map_element "termdocsource", to: :term_sources
|
|
49
|
-
map_element "metanorma-extension", to: :metanorma_extension
|
|
50
|
-
map_element "boilerplate", to: :boilerplate
|
|
51
|
-
map_element "preface", to: :preface
|
|
52
|
-
map_element "sections", to: :sections
|
|
53
|
-
map_element "annex", to: :annex
|
|
54
|
-
map_element "bibliography", to: :bibliography
|
|
55
|
-
map_element "annotation-container", to: :annotation_container
|
|
56
|
-
map_element "indexsect", to: :indexsect
|
|
57
|
-
map_element "localized-strings", to: :localized_strings
|
|
58
|
-
map_element "fmt-footnote-container", to: :fmt_footnote_container
|
|
59
|
-
map_element "colophon", to: :colophon
|
|
60
|
-
map_attribute "autonum", to: :autonum
|
|
61
|
-
map_attribute "fmt-xref-label", to: :fmt_xref_label
|
|
20
|
+
|
|
21
|
+
Metanorma::StandardDocument::RootXmlMapping.apply(self)
|
|
62
22
|
end
|
|
63
23
|
end
|
|
64
24
|
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Metanorma
|
|
4
|
+
module BsiDocument
|
|
5
|
+
module Metadata
|
|
6
|
+
class BsiBibliographicItem < Metanorma::IsoDocument::Metadata::IsoBibliographicItem
|
|
7
|
+
attribute :ext, BsiBibDataExtensionType
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "bibdata"
|
|
11
|
+
end
|
|
12
|
+
end
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Metanorma
|
|
4
|
+
module BsiDocument
|
|
5
|
+
module Metadata
|
|
6
|
+
autoload :BsiBibDataExtensionType,
|
|
7
|
+
"#{__dir__}/metadata/bsi_bib_data_extension_type"
|
|
8
|
+
autoload :BsiBibliographicItem,
|
|
9
|
+
"#{__dir__}/metadata/bsi_bibliographic_item"
|
|
10
|
+
end
|
|
11
|
+
end
|
|
12
|
+
end
|