asciidoctor-dita-topic 1.1.4 → 1.1.5

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.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/README.adoc +3 -1
  3. data/lib/dita-topic.rb +7 -1
  4. metadata +3 -6
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c8500891ad21dc6be419992bbb3ce0746bfb3c5e96f4cdb5c0faea28cd00fe59
4
- data.tar.gz: df920f7ae7d468b8e981a05d1a16c932e2fcd31d9e22d22b5e7406cef880ca01
3
+ metadata.gz: 21b3a4a2065dec2230fd5c554325dc804cc37b69a95caa246ff3dbf43c5ecd9d
4
+ data.tar.gz: 57a4b6a9275e71b8388d4cadb10e99a25d566ba106871fc02f2c965f4fd042b7
5
5
  SHA512:
6
- metadata.gz: d788246489a2ce5c11b1f293401d70efbc373c4561e266a497bee45a7de82fc20cae10a3cf3dcded6635e1054279a51250405d36fb6bd219c7602636d6ed2aa9
7
- data.tar.gz: 9d4a9e9638f983baf60e401d3d4477c29036d028a12c751acd9e6e88527bcb97238838cccd9234cb750b560b76b23693bfa50726b483c853355eedaee0bf5f52
6
+ metadata.gz: 5ed40b0ee61e31a1d03880b3bcbd20c831dff0e9204acd7b7e334ea3d22dde069fd8e7e2fae737e06e59a86d948e905ec698b381d5709a500284d6bdf31ab903
7
+ data.tar.gz: 7387aa7846f42eb746e0f37b2484052f259f2e64aa4578fee5fb9bacb3563b49020279ff0c8cafb1f6dbad8831b66ff1aba0b388b1d4f889f2ba8522e206a6aa
data/README.adoc CHANGED
@@ -166,6 +166,8 @@ Block titles not supported in DITA:: AsciiDoc allows you to include `._Block tit
166
166
 
167
167
  Callouts not supported in DITA:: AsciiDoc allows you to use `<1>`, `<2>`, `<3>` and so on in verbatim blocks to add annotations to the specific lines. Unlike AsciiDoc, DITA does not provide a direct equivalent for this functionality. `dita-topic` issues this warning when the `-a dita-topic-callouts=off` option is specified and these annotations are present in the converted AsciiDoc file.
168
168
 
169
+ Examples not supported within _object_ in DITA:: AsciiDoc allows you to use an example block anywhere in the document. Unlike AsciiDoc, DITA only allows examples to appear directly in the topic body. `dita-topic` issues a warning whenever an example is nested in another AsciiDoc element.
170
+
169
171
  Floating titles not supported in DITA:: AsciiDoc allows you to use floating titles anywhere in the document. Unlike AsciiDoc, DITA does not support floating titles. `dita-topic` issues this warning when the `-a dita-topic-titles=off` option is specified and a floating title is present in the converted AsciiDoc file.
170
172
 
171
173
  Inline breaks not supported in DITA:: AsciiDoc provides multiple ways to insert line breaks in paragraphs, such as inserting `{nbsp}+` at the end of the line or specifying `[%hardbreaks]` on the line preceding the paragraph. Unlike AsciiDoc, DITA does not provide direct equivalent for this functionality. `dita-topic` issues this warning whenever an inline line break is present in the converted AsciiDoc file and places the `<!-- break -\->` comment in the output file to mark its place.
@@ -174,7 +176,7 @@ Nesting of sections not supported in DITA:: AsciiDoc allows you to nest sections
174
176
 
175
177
  Page breaks not supported in DITA:: AsciiDoc allows you to use `<<<` on a separate line to enforce a page break in output formats that support it. Unlike AsciiDoc, DITA does not support page breaks. `dita-topic` issues this warning whenever a page break is present in the converted AsciiDoc file and places the `<p outputclass="page-break"></p>` in the output file to mark its place.
176
178
 
177
- Possible invalid reference: _reference_:: AsciiDoc allows you to cross reference by using an ID no matter if this ID is defined within or outside of the converted document. Unlike AsciiDoc, DITA requires both the target ID and the ID of the target topic to be included in the cross reference if the reference leads outside of the current file. As `dita-topic` is meant to be run on individual AsciiDoc files, it does not have access to information from referenced files during conversion. `dita-topic` issues this warning whenever a cross reference is present in the converted AsciiDoc file.
179
+ Possible invalid reference: _reference_:: AsciiDoc allows you to cross reference by using an ID no matter if this ID is defined within or outside of the converted document. Unlike AsciiDoc, DITA requires both the target ID and the ID of the target topic to be included in the cross reference if the reference leads outside of the current file. As `dita-topic` is meant to be run on individual AsciiDoc files, it does not have access to information from referenced files during conversion. `dita-topic` issues this warning whenever the cross reference target is not present in the converted AsciiDoc file.
178
180
 
179
181
  STEM support not implemented:: AsciiDoc provides multiple ways to insert Science, Technology, Engineering and Math (STEM) expressions in the document, including the `\stem:[_formula_]` inline macro and the `[stem]` delimited block. `dita-topic` does not implement this feature and issues this warning whenever such an expression is present in the converted AsciiDoc file.
180
182
 
data/lib/dita-topic.rb CHANGED
@@ -222,6 +222,12 @@ class DitaTopic < Asciidoctor::Converter::Base
222
222
  end
223
223
 
224
224
  def convert_example node
225
+ # Issue a warning if the example is nested:
226
+ unless (parent = node.parent.context) == :document
227
+ logger.warn "#{NAME}: Examples not supported within #{parent} in DITA"
228
+ end
229
+
230
+ # Return the XML output:
225
231
  <<~EOF.chomp
226
232
  <example#{compose_id node.id}>
227
233
  #{node.title ? %(<title>#{node.title}</title>\n) : ''}#{node.content}
@@ -352,7 +358,7 @@ class DitaTopic < Asciidoctor::Converter::Base
352
358
  end
353
359
 
354
360
  # Return the XML entity:
355
- compose_circled_number node.text.to_i
361
+ %(<b outputclass="callout">#{compose_circled_number node.text.to_i}</b>)
356
362
  end
357
363
 
358
364
  def convert_inline_footnote node
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: asciidoctor-dita-topic
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.4
4
+ version: 1.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jaromir Hradilek
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2025-04-02 00:00:00.000000000 Z
10
+ date: 2025-04-19 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: asciidoctor
@@ -90,7 +89,6 @@ metadata:
90
89
  homepage_uri: https://github.com/jhradilek/asciidoctor-dita-topic
91
90
  bug_tracker_uri: https://github.com/jhradilek/asciidoctor-dita-topic/issues
92
91
  documentation_uri: https://github.com/jhradilek/asciidoctor-dita-topic/blob/main/README.adoc
93
- post_install_message:
94
92
  rdoc_options: []
95
93
  require_paths:
96
94
  - lib
@@ -105,8 +103,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
105
103
  - !ruby/object:Gem::Version
106
104
  version: '0'
107
105
  requirements: []
108
- rubygems_version: 3.5.22
109
- signing_key:
106
+ rubygems_version: 3.6.2
110
107
  specification_version: 4
111
108
  summary: A custom AsciiDoc converter that generates individual DITA topics
112
109
  test_files: []