metanorma-iho 0.9.8 → 0.9.11
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/isodoc/iho/html/htmlstyle.css +1 -1
- data/lib/isodoc/iho/html/htmlstyle.scss +1 -1
- data/lib/isodoc/iho/iho.specification.xsl +1793 -1316
- data/lib/isodoc/iho/iho.standard.xsl +1793 -1316
- data/lib/isodoc/iho/xref.rb +18 -0
- data/lib/metanorma/iho/version.rb +1 -1
- data/metanorma-iho.gemspec +1 -1
- data/metanorma.yml +0 -2
- metadata +3 -4
- data/lib/isodoc/iho/html/scripts.html +0 -70
data/lib/isodoc/iho/xref.rb
CHANGED
@@ -35,6 +35,24 @@ module IsoDoc
|
|
35
35
|
hierarchical_asset_names(clause, num)
|
36
36
|
end
|
37
37
|
|
38
|
+
def clause_order_main(docxml)
|
39
|
+
if docxml.at(ns("//sections/clause//references"))
|
40
|
+
[
|
41
|
+
{ path: "//sections/clause[@type = 'scope']" },
|
42
|
+
{ path: "//sections/terms | //sections/definitions | " \
|
43
|
+
"//sections/references | " \
|
44
|
+
"//sections/clause[not(@type = 'scope')]", multi: true },
|
45
|
+
]
|
46
|
+
else
|
47
|
+
[
|
48
|
+
{ path: "//sections/clause[@type = 'scope']" },
|
49
|
+
{ path: @klass.norm_ref_xpath },
|
50
|
+
{ path: "//sections/terms | //sections/definitions | " \
|
51
|
+
"//sections/clause[not(@type = 'scope')]", multi: true },
|
52
|
+
]
|
53
|
+
end
|
54
|
+
end
|
55
|
+
|
38
56
|
def clause_order_annex(_docxml)
|
39
57
|
[{ path: "//annex[not(@obligation = 'informative')]", multi: true },
|
40
58
|
{ path: "//annex[@obligation = 'informative']", multi: true }]
|
data/metanorma-iho.gemspec
CHANGED
@@ -25,7 +25,7 @@ Gem::Specification.new do |spec|
|
|
25
25
|
spec.bindir = "exe"
|
26
26
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
27
27
|
spec.require_paths = ["lib"]
|
28
|
-
spec.required_ruby_version = Gem::Requirement.new(">=
|
28
|
+
spec.required_ruby_version = Gem::Requirement.new(">= 3.1.0")
|
29
29
|
|
30
30
|
spec.add_dependency "metanorma-generic", "~> 2.6.2"
|
31
31
|
|
data/metanorma.yml
CHANGED
@@ -21,8 +21,6 @@ html_footnotefontsize: "0.9em"
|
|
21
21
|
boilerplate: lib/metanorma/iho/boilerplate.adoc
|
22
22
|
webfont:
|
23
23
|
- "https://fonts.googleapis.com/css2?family=Fira+Code&display=swap"
|
24
|
-
scripts: lib/isodoc/iho/html/scripts.html
|
25
|
-
scripts_pdf: lib/isodoc/iho/html/scripts.pdf.html
|
26
24
|
standardstylesheet: lib/isodoc/iho/html/iho.scss
|
27
25
|
header: lib/isodoc/iho/html/header.html
|
28
26
|
wordcoverpage: lib/isodoc/iho/html/word_iho_titlepage.html
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-iho
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.11
|
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-
|
11
|
+
date: 2024-07-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: metanorma-generic
|
@@ -194,7 +194,6 @@ files:
|
|
194
194
|
- lib/isodoc/iho/html/image003.png
|
195
195
|
- lib/isodoc/iho/html/logo.png
|
196
196
|
- lib/isodoc/iho/html/logo.svg
|
197
|
-
- lib/isodoc/iho/html/scripts.html
|
198
197
|
- lib/isodoc/iho/html/word_iho_intro.html
|
199
198
|
- lib/isodoc/iho/html/word_iho_titlepage.html
|
200
199
|
- lib/isodoc/iho/html/wordstyle.css
|
@@ -240,7 +239,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
240
239
|
requirements:
|
241
240
|
- - ">="
|
242
241
|
- !ruby/object:Gem::Version
|
243
|
-
version:
|
242
|
+
version: 3.1.0
|
244
243
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
245
244
|
requirements:
|
246
245
|
- - ">="
|
@@ -1,70 +0,0 @@
|
|
1
|
-
<script>
|
2
|
-
$("#toc").on('click', 'li', function(e) {
|
3
|
-
$(this).parent().find('li.toc-active').removeClass('toc-active');
|
4
|
-
$(this).addClass('toc-active');
|
5
|
-
});
|
6
|
-
</script>
|
7
|
-
|
8
|
-
<script>
|
9
|
-
//TOC toggle animation
|
10
|
-
$('#toggle').on('click', function(){
|
11
|
-
if( $('nav').is(':visible') ) {
|
12
|
-
$('nav').animate({ 'left': '-353px' }, 'slow', function(){
|
13
|
-
$('nav').hide();
|
14
|
-
});
|
15
|
-
$('.container').animate({ 'padding-left': '31px' }, 'slow');
|
16
|
-
}
|
17
|
-
else {
|
18
|
-
$('nav').show();
|
19
|
-
$('nav').animate({ 'left': '0px' }, 'slow');
|
20
|
-
}
|
21
|
-
});
|
22
|
-
</script>
|
23
|
-
|
24
|
-
<script>
|
25
|
-
// Scroll to top button
|
26
|
-
window.onscroll = function() {scrollFunction()};
|
27
|
-
|
28
|
-
function scrollFunction() {
|
29
|
-
if (document.body.scrollTop > 100 || document.documentElement.scrollTop > 100) {
|
30
|
-
document.getElementById("myBtn").style.display = "block";
|
31
|
-
} else {
|
32
|
-
document.getElementById("myBtn").style.display = "none";
|
33
|
-
}
|
34
|
-
}
|
35
|
-
|
36
|
-
// When the user clicks on the button, scroll to the top of the document
|
37
|
-
function topFunction() {
|
38
|
-
document.body.scrollTop = 0;
|
39
|
-
document.documentElement.scrollTop = 0;
|
40
|
-
}
|
41
|
-
</script>
|
42
|
-
|
43
|
-
<script>
|
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>
|
54
|
-
<script>
|
55
|
-
/*
|
56
|
-
$(document).ready(function() {
|
57
|
-
$('[id^=toc]').each(function ()
|
58
|
-
{
|
59
|
-
var currentToc = $(this);
|
60
|
-
var url = window.location.href;
|
61
|
-
currentToc.wrap("<a href='" + url + "#" + currentToc.attr("id") + "' </a>");
|
62
|
-
});
|
63
|
-
});
|
64
|
-
*/
|
65
|
-
anchors.options = {
|
66
|
-
placement: 'left'
|
67
|
-
};
|
68
|
-
anchors.add('h1, h2, h3, h4');
|
69
|
-
</script>
|
70
|
-
|