metanorma-standoc 2.4.4 → 2.4.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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8989224ddc5bb169f13c102066f005b7c72e0d6ff0cd7a2c2122ef57ed7f6923
|
4
|
+
data.tar.gz: ff257fb02f7feb16d680f111ae39c8806abaff034e087659586bbd43bc34a6e5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 837c2c91f59f93374b747c23b71f5740b1e64d0e29e06d8e7e4076bb7c0ce24700b29b17434ece743d1e1fbcd7b6fa5b245526207525f2b6cbfb6c5a2be6dd29
|
7
|
+
data.tar.gz: ab6f75ce5add0b40f99d47a47b123ccfc090291b5e6adb4f1c41687e541f53f111dff9fecb6c6ecb46ff5aeaee8ad0af97bd444da8f9b00525b210fa8c1d7430
|
@@ -26,6 +26,7 @@ module Metanorma
|
|
26
26
|
preprocessor Metanorma::Plugin::Datastruct::Json2TextPreprocessor
|
27
27
|
preprocessor Metanorma::Plugin::Datastruct::Yaml2TextPreprocessor
|
28
28
|
inline_macro Metanorma::Standoc::PreferredTermInlineMacro
|
29
|
+
inline_macro Metanorma::Standoc::DateInlineMacro
|
29
30
|
inline_macro Metanorma::Standoc::SpanInlineMacro
|
30
31
|
inline_macro Metanorma::Standoc::AltTermInlineMacro
|
31
32
|
inline_macro Metanorma::Standoc::AdmittedTermInlineMacro
|
@@ -1012,6 +1012,7 @@
|
|
1012
1012
|
<ref name="del"/>
|
1013
1013
|
<ref name="span"/>
|
1014
1014
|
<ref name="erefstack"/>
|
1015
|
+
<ref name="date_inline"/>
|
1015
1016
|
</choice>
|
1016
1017
|
</define>
|
1017
1018
|
<define name="add">
|
@@ -1053,6 +1054,23 @@
|
|
1053
1054
|
</oneOrMore>
|
1054
1055
|
</element>
|
1055
1056
|
</define>
|
1057
|
+
<define name="date_inline">
|
1058
|
+
<element name="date">
|
1059
|
+
<attribute name="value"/>
|
1060
|
+
<optional>
|
1061
|
+
<attribute name="format"/>
|
1062
|
+
</optional>
|
1063
|
+
<optional>
|
1064
|
+
<attribute name="language"/>
|
1065
|
+
</optional>
|
1066
|
+
<optional>
|
1067
|
+
<attribute name="script"/>
|
1068
|
+
</optional>
|
1069
|
+
<optional>
|
1070
|
+
<attribute name="locale"/>
|
1071
|
+
</optional>
|
1072
|
+
</element>
|
1073
|
+
</define>
|
1056
1074
|
<define name="concept">
|
1057
1075
|
<element name="concept">
|
1058
1076
|
<optional>
|
@@ -27,7 +27,7 @@ module Metanorma
|
|
27
27
|
|
28
28
|
def process(_parent, target, attr)
|
29
29
|
args = preprocess_attrs(attr) or return
|
30
|
-
ret = "<index-xref also='#{target == 'also'}'>"\
|
30
|
+
ret = "<index-xref also='#{target == 'also'}'>" \
|
31
31
|
"<primary>#{args[:primary]}</primary>"
|
32
32
|
ret += "<secondary>#{args[:secondary]}</secondary>" if args[:secondary]
|
33
33
|
ret += "<tertiary>#{args[:tertiary]}</tertiary>" if args[:tertiary]
|
@@ -69,7 +69,7 @@ module Metanorma
|
|
69
69
|
rpend = attributes["rpend"]
|
70
70
|
end
|
71
71
|
|
72
|
-
"<ruby>#{target}<rp>#{rpbegin}</rp><rt>#{rt}</rt>"\
|
72
|
+
"<ruby>#{target}<rp>#{rpbegin}</rp><rt>#{rt}</rt>" \
|
73
73
|
"<rp>#{rpend}</rp></ruby>"
|
74
74
|
end
|
75
75
|
end
|
@@ -101,6 +101,18 @@ module Metanorma
|
|
101
101
|
end
|
102
102
|
end
|
103
103
|
|
104
|
+
class DateInlineMacro < Asciidoctor::Extensions::InlineMacroProcessor
|
105
|
+
use_dsl
|
106
|
+
named :date
|
107
|
+
using_format :short
|
108
|
+
|
109
|
+
def process(_parent, _target, attrs)
|
110
|
+
format = "%F"
|
111
|
+
attrs.size >= 2 and format = attrs[2]
|
112
|
+
%{<date format='#{format}' value='#{attrs[1]}'/>}
|
113
|
+
end
|
114
|
+
end
|
115
|
+
|
104
116
|
class AddMacro < Asciidoctor::Extensions::InlineMacroProcessor
|
105
117
|
use_dsl
|
106
118
|
named :add
|
@@ -122,7 +122,7 @@ module Metanorma
|
|
122
122
|
err2 = "There is a crossreference to an instance of #{inner.name} " \
|
123
123
|
"nested within #{outer.name}: #{i.to_xml}"
|
124
124
|
@log.add("Style", i, err2)
|
125
|
-
@fatalerror << err2
|
125
|
+
# @fatalerror << err2
|
126
126
|
end
|
127
127
|
|
128
128
|
def concept_validate(doc, tag, refterm)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-standoc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.4.
|
4
|
+
version: 2.4.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-05
|
11
|
+
date: 2023-06-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: asciidoctor
|