metanorma-generic 1.4.7 → 1.5.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/macos.yml +8 -1
- data/.github/workflows/ubuntu.yml +20 -7
- data/.github/workflows/windows.yml +8 -1
- data/lib/asciidoctor/generic/biblio.rng +36 -6
- data/lib/asciidoctor/generic/converter.rb +66 -41
- data/lib/asciidoctor/generic/isodoc.rng +450 -4
- data/lib/asciidoctor/generic/reqt.rng +23 -0
- data/lib/isodoc/generic.rb +1 -0
- data/lib/isodoc/generic/base_convert.rb +6 -1
- data/lib/isodoc/generic/html/scripts.html +10 -6
- data/lib/isodoc/generic/html_convert.rb +2 -4
- data/lib/isodoc/generic/metadata.rb +3 -0
- data/lib/isodoc/generic/presentation_xml_convert.rb +10 -0
- data/lib/isodoc/generic/xref.rb +6 -0
- data/lib/metanorma/generic.rb +19 -0
- data/lib/metanorma/generic/processor.rb +27 -10
- data/lib/metanorma/generic/version.rb +1 -1
- data/metanorma-generic.gemspec +2 -2
- data/metanorma.yml.example +40 -0
- metadata +12 -12
- data/lib/isodoc/generic/html/scripts.pdf.html +0 -72
@@ -30,9 +30,22 @@
|
|
30
30
|
<data type="boolean"/>
|
31
31
|
</attribute>
|
32
32
|
</optional>
|
33
|
+
<optional>
|
34
|
+
<attribute name="number"/>
|
35
|
+
</optional>
|
33
36
|
<optional>
|
34
37
|
<attribute name="subsequence"/>
|
35
38
|
</optional>
|
39
|
+
<optional>
|
40
|
+
<attribute name="keep-with-next">
|
41
|
+
<data type="boolean"/>
|
42
|
+
</attribute>
|
43
|
+
</optional>
|
44
|
+
<optional>
|
45
|
+
<attribute name="keep-lines-together">
|
46
|
+
<data type="boolean"/>
|
47
|
+
</attribute>
|
48
|
+
</optional>
|
36
49
|
<attribute name="id">
|
37
50
|
<data type="ID"/>
|
38
51
|
</attribute>
|
@@ -141,6 +154,16 @@
|
|
141
154
|
<data type="boolean"/>
|
142
155
|
</attribute>
|
143
156
|
</optional>
|
157
|
+
<optional>
|
158
|
+
<attribute name="keep-with-next">
|
159
|
+
<data type="boolean"/>
|
160
|
+
</attribute>
|
161
|
+
</optional>
|
162
|
+
<optional>
|
163
|
+
<attribute name="keep-lines-together">
|
164
|
+
<data type="boolean"/>
|
165
|
+
</attribute>
|
166
|
+
</optional>
|
144
167
|
<oneOrMore>
|
145
168
|
<ref name="BasicBlock"/>
|
146
169
|
</oneOrMore>
|
data/lib/isodoc/generic.rb
CHANGED
@@ -1,5 +1,6 @@
|
|
1
1
|
require "isodoc"
|
2
2
|
require_relative "metadata"
|
3
|
+
require_relative "xref"
|
3
4
|
require "fileutils"
|
4
5
|
|
5
6
|
module IsoDoc
|
@@ -9,6 +10,10 @@ module IsoDoc
|
|
9
10
|
@meta = Metadata.new(lang, script, labels)
|
10
11
|
end
|
11
12
|
|
13
|
+
def xref_init(lang, script, klass, labels, options)
|
14
|
+
@xrefs = Xref.new(lang, script, klass, labels, options)
|
15
|
+
end
|
16
|
+
|
12
17
|
def baselocation(loc)
|
13
18
|
return nil if loc.nil?
|
14
19
|
File.expand_path(File.join(File.dirname(self.class::_file || __FILE__), "..", "..", "..", loc))
|
@@ -16,7 +21,7 @@ module IsoDoc
|
|
16
21
|
|
17
22
|
def annex_name(annex, name, div)
|
18
23
|
div.h1 **{ class: "Annex" } do |t|
|
19
|
-
t << "#{anchor(annex['id'], :label)} "
|
24
|
+
t << "#{@xrefs.anchor(annex['id'], :label)} "
|
20
25
|
t.br
|
21
26
|
t.b do |b|
|
22
27
|
name&.children&.each { |c2| parse(c2, b) }
|
@@ -41,12 +41,16 @@ $('#toggle').on('click', function(){
|
|
41
41
|
</script>
|
42
42
|
|
43
43
|
<script>
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
44
|
+
// @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt Expat
|
45
|
+
//
|
46
|
+
// AnchorJS - v4.2.2 - 2020-04-20
|
47
|
+
// https://www.bryanbraun.com/anchorjs/
|
48
|
+
// Copyright (c) 2020 Bryan Braun; Licensed MIT
|
49
|
+
//
|
50
|
+
// @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt Expat
|
51
|
+
!function(A,e){"use strict";"function"==typeof define&&define.amd?define([],e):"object"==typeof module&&module.exports?module.exports=e():(A.AnchorJS=e(),A.anchors=new A.AnchorJS)}(this,function(){"use strict";return function(A){function f(A){A.icon=A.hasOwnProperty("icon")?A.icon:"",A.visible=A.hasOwnProperty("visible")?A.visible:"hover",A.placement=A.hasOwnProperty("placement")?A.placement:"right",A.ariaLabel=A.hasOwnProperty("ariaLabel")?A.ariaLabel:"Anchor",A.class=A.hasOwnProperty("class")?A.class:"",A.base=A.hasOwnProperty("base")?A.base:"",A.truncate=A.hasOwnProperty("truncate")?Math.floor(A.truncate):64,A.titleText=A.hasOwnProperty("titleText")?A.titleText:""}function p(A){var e;if("string"==typeof A||A instanceof String)e=[].slice.call(document.querySelectorAll(A));else{if(!(Array.isArray(A)||A instanceof NodeList))throw new Error("The selector provided to AnchorJS was invalid.");e=[].slice.call(A)}return e}this.options=A||{},this.elements=[],f(this.options),this.isTouchDevice=function(){return!!("ontouchstart"in window||window.DocumentTouch&&document instanceof DocumentTouch)},this.add=function(A){var e,t,i,n,o,s,a,r,c,h,l,u,d=[];if(f(this.options),"touch"===(l=this.options.visible)&&(l=this.isTouchDevice()?"always":"hover"),0===(e=p(A=A||"h2, h3, h4, h5, h6")).length)return this;for(!function(){if(null!==document.head.querySelector("style.anchorjs"))return;var A,e=document.createElement("style");e.className="anchorjs",e.appendChild(document.createTextNode("")),void 0===(A=document.head.querySelector('[rel="stylesheet"],style'))?document.head.appendChild(e):document.head.insertBefore(e,A);e.sheet.insertRule(".anchorjs-link{opacity:0;text-decoration:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}",e.sheet.cssRules.length),e.sheet.insertRule(":hover>.anchorjs-link,.anchorjs-link:focus{opacity:1}",e.sheet.cssRules.length),e.sheet.insertRule("[data-anchorjs-icon]::after{content:attr(data-anchorjs-icon)}",e.sheet.cssRules.length),e.sheet.insertRule('@font-face{font-family:anchorjs-icons;src:url(data:n/a;base64,AAEAAAALAIAAAwAwT1MvMg8yG2cAAAE4AAAAYGNtYXDp3gC3AAABpAAAAExnYXNwAAAAEAAAA9wAAAAIZ2x5ZlQCcfwAAAH4AAABCGhlYWQHFvHyAAAAvAAAADZoaGVhBnACFwAAAPQAAAAkaG10eASAADEAAAGYAAAADGxvY2EACACEAAAB8AAAAAhtYXhwAAYAVwAAARgAAAAgbmFtZQGOH9cAAAMAAAAAunBvc3QAAwAAAAADvAAAACAAAQAAAAEAAHzE2p9fDzz1AAkEAAAAAADRecUWAAAAANQA6R8AAAAAAoACwAAAAAgAAgAAAAAAAAABAAADwP/AAAACgAAA/9MCrQABAAAAAAAAAAAAAAAAAAAAAwABAAAAAwBVAAIAAAAAAAIAAAAAAAAAAAAAAAAAAAAAAAMCQAGQAAUAAAKZAswAAACPApkCzAAAAesAMwEJAAAAAAAAAAAAAAAAAAAAARAAAAAAAAAAAAAAAAAAAAAAQAAg//0DwP/AAEADwABAAAAAAQAAAAAAAAAAAAAAIAAAAAAAAAIAAAACgAAxAAAAAwAAAAMAAAAcAAEAAwAAABwAAwABAAAAHAAEADAAAAAIAAgAAgAAACDpy//9//8AAAAg6cv//f///+EWNwADAAEAAAAAAAAAAAAAAAAACACEAAEAAAAAAAAAAAAAAAAxAAACAAQARAKAAsAAKwBUAAABIiYnJjQ3NzY2MzIWFxYUBwcGIicmNDc3NjQnJiYjIgYHBwYUFxYUBwYGIwciJicmNDc3NjIXFhQHBwYUFxYWMzI2Nzc2NCcmNDc2MhcWFAcHBgYjARQGDAUtLXoWOR8fORYtLTgKGwoKCjgaGg0gEhIgDXoaGgkJBQwHdR85Fi0tOAobCgoKOBoaDSASEiANehoaCQkKGwotLXoWOR8BMwUFLYEuehYXFxYugC44CQkKGwo4GkoaDQ0NDXoaShoKGwoFBe8XFi6ALjgJCQobCjgaShoNDQ0NehpKGgobCgoKLYEuehYXAAAADACWAAEAAAAAAAEACAAAAAEAAAAAAAIAAwAIAAEAAAAAAAMACAAAAAEAAAAAAAQACAAAAAEAAAAAAAUAAQALAAEAAAAAAAYACAAAAAMAAQQJAAEAEAAMAAMAAQQJAAIABgAcAAMAAQQJAAMAEAAMAAMAAQQJAAQAEAAMAAMAAQQJAAUAAgAiAAMAAQQJAAYAEAAMYW5jaG9yanM0MDBAAGEAbgBjAGgAbwByAGoAcwA0ADAAMABAAAAAAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAH//wAP) format("truetype")}',e.sheet.cssRules.length)}(),t=document.querySelectorAll("[id]"),i=[].map.call(t,function(A){return A.id}),o=0;o<e.length;o++)if(this.hasAnchorJSLink(e[o]))d.push(o);else{if(e[o].hasAttribute("id"))n=e[o].getAttribute("id");else if(e[o].hasAttribute("data-anchor-id"))n=e[o].getAttribute("data-anchor-id");else{for(c=r=this.urlify(e[o].textContent),a=0;void 0!==s&&(c=r+"-"+a),a+=1,-1!==(s=i.indexOf(c)););s=void 0,i.push(c),e[o].setAttribute("id",c),n=c}(h=document.createElement("a")).className="anchorjs-link "+this.options.class,h.setAttribute("aria-label",this.options.ariaLabel),h.setAttribute("data-anchorjs-icon",this.options.icon),this.options.titleText&&(h.title=this.options.titleText),u=document.querySelector("base")?window.location.pathname+window.location.search:"",u=this.options.base||u,h.href=u+"#"+n,"always"===l&&(h.style.opacity="1"),""===this.options.icon&&(h.style.font="1em/1 anchorjs-icons","left"===this.options.placement&&(h.style.lineHeight="inherit")),"left"===this.options.placement?(h.style.position="absolute",h.style.marginLeft="-1em",h.style.paddingRight="0.5em",e[o].insertBefore(h,e[o].firstChild)):(h.style.paddingLeft="0.375em",e[o].appendChild(h))}for(o=0;o<d.length;o++)e.splice(d[o]-o,1);return this.elements=this.elements.concat(e),this},this.remove=function(A){for(var e,t,i=p(A),n=0;n<i.length;n++)(t=i[n].querySelector(".anchorjs-link"))&&(-1!==(e=this.elements.indexOf(i[n]))&&this.elements.splice(e,1),i[n].removeChild(t));return this},this.removeAll=function(){this.remove(this.elements)},this.urlify=function(A){return this.options.truncate||f(this.options),A.trim().replace(/\'/gi,"").replace(/[& +$,:;=?@"#{}|^~[`%!'<>\]\.\/\(\)\*\\\n\t\b\v]/g,"-").replace(/-{2,}/g,"-").substring(0,this.options.truncate).replace(/^-+|-+$/gm,"").toLowerCase()},this.hasAnchorJSLink=function(A){var e=A.firstChild&&-1<(" "+A.firstChild.className+" ").indexOf(" anchorjs-link "),t=A.lastChild&&-1<(" "+A.lastChild.className+" ").indexOf(" anchorjs-link ");return e||t||!1}}});
|
52
|
+
// @license-end
|
53
|
+
</script>
|
50
54
|
|
51
55
|
<script>
|
52
56
|
/*
|
@@ -50,10 +50,8 @@ module IsoDoc
|
|
50
50
|
end
|
51
51
|
|
52
52
|
def googlefonts
|
53
|
-
|
54
|
-
|
55
|
-
<link href="https://fonts.googleapis.com/css?family=Overpass:300,300i,600,900" rel="stylesheet">
|
56
|
-
HEAD
|
53
|
+
return unless configuration.webfont
|
54
|
+
Array(configuration.webfont).map { |x| %{<link href="#{x.gsub(/\&/, '&')}" rel="stylesheet">} }.join("\n")
|
57
55
|
end
|
58
56
|
|
59
57
|
include BaseConvert
|
@@ -9,6 +9,9 @@ module IsoDoc
|
|
9
9
|
here = File.dirname(__FILE__)
|
10
10
|
default_logo_path = File.expand_path(File.join(here, "html", "logo.jpg"))
|
11
11
|
set(:logo, baselocation(configuration.logo_path) || default_logo_path)
|
12
|
+
unless configuration.logo_paths.nil?
|
13
|
+
set(:logo_paths, Array(configuration.logo_paths).map { |p| baselocation(p) })
|
14
|
+
end
|
12
15
|
end
|
13
16
|
|
14
17
|
class << self
|
data/lib/metanorma/generic.rb
CHANGED
@@ -14,10 +14,14 @@ module Metanorma
|
|
14
14
|
CONFIG_ATTRS = %i[
|
15
15
|
organization_name_short
|
16
16
|
organization_name_long
|
17
|
+
bibliography_titles
|
17
18
|
document_namespace
|
18
19
|
docid_template
|
20
|
+
doctypes
|
21
|
+
default_doctype
|
19
22
|
i18nyaml
|
20
23
|
logo_path
|
24
|
+
logo_paths
|
21
25
|
header
|
22
26
|
htmlcoverpage
|
23
27
|
htmlintropage
|
@@ -26,12 +30,18 @@ module Metanorma
|
|
26
30
|
html_headerfont
|
27
31
|
html_monospacefont
|
28
32
|
metadata_extensions
|
33
|
+
metanorma_name
|
34
|
+
normref_titles
|
29
35
|
published_stages
|
36
|
+
default_stage
|
30
37
|
stage_abbreviations
|
31
38
|
scripts
|
32
39
|
scripts_pdf
|
33
40
|
standardstylesheet
|
41
|
+
symbols_titles
|
42
|
+
termsdefs_titles
|
34
43
|
validate_rng_file
|
44
|
+
webfont
|
35
45
|
wordcoverpage
|
36
46
|
wordintropage
|
37
47
|
wordstylesheet
|
@@ -59,6 +69,15 @@ module Metanorma
|
|
59
69
|
self.organization_name_short ||= ORGANIZATION_NAME_SHORT
|
60
70
|
self.organization_name_long ||= ORGANIZATION_NAME_LONG
|
61
71
|
self.document_namespace ||= DOCUMENT_NAMESPACE
|
72
|
+
self.termsdefs_titles ||=
|
73
|
+
["Terms and definitions", "Terms, definitions, symbols and abbreviated terms",
|
74
|
+
"Terms, definitions, symbols and abbreviations", "Terms, definitions and symbols",
|
75
|
+
"Terms, definitions and abbreviations", "Terms, definitions and abbreviated terms"]
|
76
|
+
self.symbols_titles ||=
|
77
|
+
["Symbols and abbreviated terms", "Symbols", "Abbreviated terms", "Abbreviations"]
|
78
|
+
self.normref_titles ||=
|
79
|
+
["Normative references"]
|
80
|
+
self.bibliography_titles ||= ["Bibliography"]
|
62
81
|
end
|
63
82
|
|
64
83
|
def set_default_values_from_yaml_file(config_file)
|
@@ -2,11 +2,30 @@ require "metanorma/processor"
|
|
2
2
|
|
3
3
|
module Metanorma
|
4
4
|
module Generic
|
5
|
+
def self.fonts_used
|
6
|
+
{
|
7
|
+
html: [
|
8
|
+
configuration.html_bodyfont || "Overpass", configuration.html_headerfont || "Overpass",
|
9
|
+
configuration.html_monospacefont || "Space Mono"
|
10
|
+
].uniq,
|
11
|
+
doc: [
|
12
|
+
configuration.word_bodyfont || "Overpass", configuration.word_headerfont || "Overpass",
|
13
|
+
configuration.word_monospacefont || "Space Mono"].uniq,
|
14
|
+
pdf: [
|
15
|
+
configuration.word_bodyfont || "Overpass", configuration.word_headerfont || "Overpass",
|
16
|
+
configuration.word_monospacefont || "Space Mono"].uniq,
|
17
|
+
}
|
18
|
+
end
|
19
|
+
|
5
20
|
class Processor < Metanorma::Processor
|
21
|
+
def configuration
|
22
|
+
Metanorma::Generic.configuration
|
23
|
+
end
|
24
|
+
|
6
25
|
def initialize
|
7
|
-
@short = :generic
|
26
|
+
@short = configuration&.metanorma_name&.to_sym || :generic
|
8
27
|
@input_format = :asciidoc
|
9
|
-
@asciidoctor_backend = :generic
|
28
|
+
@asciidoctor_backend = configuration&.metanorma_name&.to_sym || :generic
|
10
29
|
end
|
11
30
|
|
12
31
|
def output_formats
|
@@ -21,10 +40,6 @@ module Metanorma
|
|
21
40
|
"Metanorma::Generic #{Metanorma::Generic::VERSION}"
|
22
41
|
end
|
23
42
|
|
24
|
-
def input_to_isodoc(file, filename)
|
25
|
-
Metanorma::Input::Asciidoc.new.process(file, filename, @asciidoctor_backend)
|
26
|
-
end
|
27
|
-
|
28
43
|
def extract_options(file)
|
29
44
|
head = file.sub(/\n\n.*$/m, "\n")
|
30
45
|
/\n:htmlstylesheet: (?<htmlstylesheet>[^\n]+)\n/ =~ head
|
@@ -54,14 +69,16 @@ module Metanorma
|
|
54
69
|
super.merge(new_options)
|
55
70
|
end
|
56
71
|
|
57
|
-
def output(isodoc_node, outname, format, options={})
|
72
|
+
def output(isodoc_node, inname, outname, format, options={})
|
58
73
|
case format
|
59
74
|
when :html
|
60
|
-
IsoDoc::Generic::HtmlConvert.new(options).convert(
|
75
|
+
IsoDoc::Generic::HtmlConvert.new(options).convert(inname, isodoc_node, nil, outname)
|
61
76
|
when :doc
|
62
|
-
IsoDoc::Generic::WordConvert.new(options).convert(
|
77
|
+
IsoDoc::Generic::WordConvert.new(options).convert(inname, isodoc_node, nil, outname)
|
63
78
|
when :pdf
|
64
|
-
IsoDoc::Generic::PdfConvert.new(options).convert(
|
79
|
+
IsoDoc::Generic::PdfConvert.new(options).convert(inname, isodoc_node, nil, outname)
|
80
|
+
when :presentation
|
81
|
+
IsoDoc::Generic::PresentationXMLConvert.new(options).convert(inname, isodoc_node, nil, outname)
|
65
82
|
else
|
66
83
|
super
|
67
84
|
end
|
data/metanorma-generic.gemspec
CHANGED
@@ -28,8 +28,8 @@ Gem::Specification.new do |spec|
|
|
28
28
|
|
29
29
|
spec.add_dependency "htmlentities", "~> 4.3.4"
|
30
30
|
spec.add_dependency "ruby-jing"
|
31
|
-
spec.add_dependency "metanorma-standoc", "~> 1.
|
32
|
-
spec.add_dependency "isodoc", "~> 1.
|
31
|
+
spec.add_dependency "metanorma-standoc", "~> 1.4.0"
|
32
|
+
spec.add_dependency "isodoc", "~> 1.1.0"
|
33
33
|
|
34
34
|
spec.add_development_dependency "byebug", "~> 9.1"
|
35
35
|
spec.add_development_dependency "equivalent-xml", "~> 0.6"
|
data/metanorma.yml.example
CHANGED
@@ -1,12 +1,19 @@
|
|
1
|
+
metanorma_name: generic
|
1
2
|
organization_name_short: My Organization
|
2
3
|
organization_name_long: My Organization name
|
3
4
|
document_namespace: https://open.ribose.com/standards/mine
|
4
5
|
xml_root_tag: 'mine-standard'
|
5
6
|
logo_path: /metanorma-mine/lib/isodoc/mine/html/logo.jpg
|
7
|
+
logo_paths:
|
8
|
+
- /metanorma-mine/lib/isodoc/mine/html/logo1.jpg
|
9
|
+
- /metanorma-mine/lib/isodoc/mine/html/logo2.jpg
|
6
10
|
validate_rng_file: /metanorma-mine/lib/asciidoctor/mine/mine.rng
|
7
11
|
htmlcoverpage: /metanorma-mine/lib/isodoc/mine/html/html_mine_titlepage.html
|
8
12
|
htmlintropage: /metanorma-mine/lib/isodoc/mine/html/html_mine_intro.html
|
9
13
|
htmlstylesheet: /metanorma-mine/lib/isodoc/mine/html/htmlstyle.scss
|
14
|
+
html_bodyfont: '"Source Sans Pro",sans-serif'
|
15
|
+
html_headerfont: '"Source Sans Pro",sans-serif'
|
16
|
+
html_monospacefont: '"Source Code Pro",monospace'
|
10
17
|
scripts: /metanorma-mine/lib/isodoc/mine/html/scripts.html
|
11
18
|
scripts_pdf: /metanorma-mine/lib/isodoc/mine/html/scripts.prd.html
|
12
19
|
standardstylesheet: /metanorma-mine/lib/isodoc/mine/html/
|
@@ -14,8 +21,41 @@ header: /metanorma-mine/lib/isodoc/mine/html/header.html
|
|
14
21
|
wordcoverpage: /metanorma-mine/lib/isodoc/mine/html/word_mine_titlepage.html
|
15
22
|
wordintropage: /metanorma-mine/lib/isodoc/mine/html/word_mine_intro.html
|
16
23
|
wordstylesheet: /metanorma-mine/lib/isodoc/mine/html/wordstyle.scss
|
24
|
+
word_bodyfont: '"Source Sans Pro","Arial",sans-serif'
|
25
|
+
word_headerfont: '"Source Sans Pro","Arial",sans-serif'
|
26
|
+
word_monospacefont: '"Source Code Pro",monospace'
|
17
27
|
docid_template: "{{ organization_name_short }} {{ docnumeric }}"
|
18
28
|
metadata_extensions:
|
19
29
|
- security
|
20
30
|
published_stages:
|
21
31
|
- published
|
32
|
+
stage_abbreviations:
|
33
|
+
draft-proposal:
|
34
|
+
draft-development:
|
35
|
+
draft-testing:
|
36
|
+
draft-implementation:
|
37
|
+
in-force:
|
38
|
+
retired:
|
39
|
+
metadata_extensions:
|
40
|
+
- security
|
41
|
+
- recipient
|
42
|
+
doctypes:
|
43
|
+
- standard
|
44
|
+
- recommendation
|
45
|
+
default_doctype: standard
|
46
|
+
termsdefs_titles:
|
47
|
+
- Terms and definitions
|
48
|
+
- Terms, definitions, symbols and abbreviated terms
|
49
|
+
- Terms, definitions, symbols and abbreviations
|
50
|
+
- Terms, definitions and symbls
|
51
|
+
- Terms, definitions and abbreviations
|
52
|
+
- Terms, definitions and abbreviated terms
|
53
|
+
symbols_titles:
|
54
|
+
- Symbols and abbreviated terms
|
55
|
+
- Symbols
|
56
|
+
- Abbreviated terms
|
57
|
+
- Abbreviations
|
58
|
+
normref_titles:
|
59
|
+
- Normative references
|
60
|
+
bibliography_titles
|
61
|
+
- Bibliography
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-generic
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.5.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-07-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: htmlentities
|
@@ -44,28 +44,28 @@ dependencies:
|
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: 1.
|
47
|
+
version: 1.4.0
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: 1.
|
54
|
+
version: 1.4.0
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: isodoc
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: 1.
|
61
|
+
version: 1.1.0
|
62
62
|
type: :runtime
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: 1.
|
68
|
+
version: 1.1.0
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: byebug
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
@@ -235,14 +235,15 @@ files:
|
|
235
235
|
- lib/isodoc/generic/html/htmlstyle.scss
|
236
236
|
- lib/isodoc/generic/html/logo.jpg
|
237
237
|
- lib/isodoc/generic/html/scripts.html
|
238
|
-
- lib/isodoc/generic/html/scripts.pdf.html
|
239
238
|
- lib/isodoc/generic/html/word_generic_intro.html
|
240
239
|
- lib/isodoc/generic/html/word_generic_titlepage.html
|
241
240
|
- lib/isodoc/generic/html/wordstyle.scss
|
242
241
|
- lib/isodoc/generic/html_convert.rb
|
243
242
|
- lib/isodoc/generic/metadata.rb
|
244
243
|
- lib/isodoc/generic/pdf_convert.rb
|
244
|
+
- lib/isodoc/generic/presentation_xml_convert.rb
|
245
245
|
- lib/isodoc/generic/word_convert.rb
|
246
|
+
- lib/isodoc/generic/xref.rb
|
246
247
|
- lib/metanorma-generic.rb
|
247
248
|
- lib/metanorma/generic.rb
|
248
249
|
- lib/metanorma/generic/processor.rb
|
@@ -253,7 +254,7 @@ homepage: https://github.com/metanorma/metanorma-generic
|
|
253
254
|
licenses:
|
254
255
|
- BSD-2-Clause
|
255
256
|
metadata: {}
|
256
|
-
post_install_message:
|
257
|
+
post_install_message:
|
257
258
|
rdoc_options: []
|
258
259
|
require_paths:
|
259
260
|
- lib
|
@@ -268,9 +269,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
268
269
|
- !ruby/object:Gem::Version
|
269
270
|
version: '0'
|
270
271
|
requirements: []
|
271
|
-
|
272
|
-
|
273
|
-
signing_key:
|
272
|
+
rubygems_version: 3.0.3
|
273
|
+
signing_key:
|
274
274
|
specification_version: 4
|
275
275
|
summary: Metanorma template gem for customisation.
|
276
276
|
test_files: []
|
@@ -1,72 +0,0 @@
|
|
1
|
-
<script>
|
2
|
-
//TOC generation
|
3
|
-
$('#toc').toc({
|
4
|
-
'selectors': toclevel(), //elements to use as headings
|
5
|
-
'container': 'main', //element to find all selectors in
|
6
|
-
'smoothScrolling': true, //enable or disable smooth scrolling on click
|
7
|
-
'prefix': 'toc', //prefix for anchor tags and class names
|
8
|
-
'onHighlight': function(el) {}, //called when a new section is highlighted
|
9
|
-
'highlightOnScroll': false, //add class to heading that is currently in focus
|
10
|
-
'highlightOffset': 100, //offset to trigger the next headline
|
11
|
-
'anchorName': function(i, heading, prefix) { //custom function for anchor name
|
12
|
-
return prefix+i;
|
13
|
-
},
|
14
|
-
'headerText': function(i, heading, $heading) { //custom function building the header-item text
|
15
|
-
return $heading.text();
|
16
|
-
},
|
17
|
-
'itemClass': function(i, heading, $heading, prefix) { // custom function for item class
|
18
|
-
return $heading[0].tagName.toLowerCase();
|
19
|
-
}
|
20
|
-
});
|
21
|
-
|
22
|
-
</script>
|
23
|
-
|
24
|
-
<script>
|
25
|
-
//TOC toggle animation
|
26
|
-
$('#toggle').on('click', function(){
|
27
|
-
if( $('nav').is(':visible') ) {
|
28
|
-
$('nav').animate({ 'left': '-353px' }, 'slow', function(){
|
29
|
-
$('nav').hide();
|
30
|
-
});
|
31
|
-
$('.container').animate({ 'padding-left': '31px' }, 'slow');
|
32
|
-
}
|
33
|
-
else {
|
34
|
-
$('nav').show();
|
35
|
-
$('nav').animate({ 'left': '0px' }, 'slow');
|
36
|
-
$('.container').animate({ 'padding-left': '360px' }, 'slow');
|
37
|
-
}
|
38
|
-
});
|
39
|
-
</script>
|
40
|
-
|
41
|
-
<script>
|
42
|
-
// Scroll to top button
|
43
|
-
window.onscroll = function() {scrollFunction()};
|
44
|
-
|
45
|
-
function scrollFunction() {
|
46
|
-
if (document.body.scrollTop > 100 || document.documentElement.scrollTop > 100) {
|
47
|
-
document.getElementById("myBtn").style.display = "block";
|
48
|
-
} else {
|
49
|
-
document.getElementById("myBtn").style.display = "none";
|
50
|
-
}
|
51
|
-
}
|
52
|
-
|
53
|
-
// When the user clicks on the button, scroll to the top of the document
|
54
|
-
function topFunction() {
|
55
|
-
document.body.scrollTop = 0;
|
56
|
-
document.documentElement.scrollTop = 0;
|
57
|
-
}
|
58
|
-
</script>
|
59
|
-
|
60
|
-
<script>
|
61
|
-
/*
|
62
|
-
$(document).ready(function() {
|
63
|
-
$('[id^=toc]').each(function ()
|
64
|
-
{
|
65
|
-
var currentToc = $(this);
|
66
|
-
var url = window.location.href;
|
67
|
-
currentToc.wrap("<a href='" + url + "#" + currentToc.attr("id") + "' </a>");
|
68
|
-
});
|
69
|
-
});
|
70
|
-
*/
|
71
|
-
</script>
|
72
|
-
|