You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,7 +15,7 @@ Record of bug fixes, enhancements, and changes.
15
15
## [1.1.3] – 2022-07-07-16
16
16
17
17
### Fixed
18
-
- The global and case-insensitive flags (ig) are now parsing correctly: using ii or gg will cause prevent the callout block from being processed. Thanks to Hakim Cassimally for finding the bug.
18
+
- The global and case-insensitive flags (ig) are now parsing correctly: using ii or gg prevented the callout block from being processed. Thanks to Hakim Cassimally for finding the bug.
19
19
- Escaped slash characters were not being processed in the search. Thanks to Hakim Cassimally for finding the bug.
20
20
21
21
## [1.1.2] – 2022-07-07
@@ -43,7 +43,7 @@ Record of bug fixes, enhancements, and changes.
43
43
44
44
### Changed
45
45
46
-
- Ordered lists were only processes if they occurred directly beneath a source listing block. This turns out to be quite restrictive, and doesn't follow Asciidoc's stance on processing standard callouts, which allows for intermediate blocks to separate the source list from the attached callout list.\
46
+
- Ordered lists were only processes if they occurred directly beneath a source listing block. This turns out to be quite restrictive and doesn't follow Asciidoc's stance on processing standard callouts, which allows for intermediate blocks to separate the source list from the attached callout list.\
47
47
The processor will now allow intermediate blocks to separate the source listing from the ordered list containing callouts.
48
-
- Fixed a few spelling mistakes and a code line where I was picking up a formatted item, rather than a raw item.
48
+
- Fixed a few spelling mistakes and a code line where I was picking up a formatted item, rather than a raw item.
Copy file name to clipboardExpand all lines: README.md
+10-9Lines changed: 10 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ An [Asciidoctor](https://asciidoctor.org/) extension which adds support for call
6
6
7
7
## Motivation
8
8
9
-
Aside from getting little practice around Ruby and JavaScript, I decided to have a crack at this to help with a problem that comes up at work every so often.
9
+
Aside from getting little practice around Ruby and JavaScript, I decided to have a crack at this to help with a problem that comes up at work every so often.
10
10
11
11
The [callout mechanism](https://docs.asciidoctor.org/asciidoc/latest/verbatim/callouts/) for Asciidoc works extremely well in 99% of the cases I run into:
12
12
@@ -48,7 +48,7 @@ end
48
48
. Response block @5
49
49
```
50
50
51
-
Rather than tagging the code, you add a location token at the end of a list item, which will then add the tag at the specified line number. Run the source text through Asciidoctor+extension, and it'll spit the same source block complete with callouts.
51
+
Rather than tagging the code, you add a location token at the end of a list item, which will then add the tag at the specified line number. Run the source text through Asciidoctor+extension, and it'll split the same source block complete with callouts.
52
52
53
53
Two types of location token are supported:
54
54
@@ -57,7 +57,7 @@ Two types of location token are supported:
57
57
58
58
**@/_text_/**
59
59
: The text between the two slashes will be used in a regex search. A callout will be placed at the end of the first matching line.
60
-
If you have a large listing then it may be preferable to use the text search rather than counting all the lines. It may also be preferable to use a smaller listing, as a long listing might mean that your description is a bit too general. +
60
+
If you have a large listing, then it may be preferable to use the text search rather than counting all the lines. It may also be preferable to use a smaller listing, as a long listing might mean that your description is a bit too general. +
61
61
Using the text search method means that the location of the callout will move with the line; handy if you're referencing a source file that might get the occasional tweak outside your control.
62
62
63
63
**@/_text_/g**
@@ -70,7 +70,8 @@ Using the text search method means that the location of the callout will move wi
70
70
: And of course, you can combine the two, though I'm not sure why you'd want to.
71
71
72
72
## Standalone callout lists
73
-
You can create a standalone callout list by adding the `calloutlist` role to an ordered list. This simply styles the list to make it look like a list of callouts so you can use it as a reference to annoted images etc.
73
+
You can create a standalone callout list by adding the `calloutlist` role to an ordered list.
74
+
This simply styles the list to make it look like a list of callouts, so you can use it as a reference to annoted images etc.
74
75
```asciidoc
75
76
[calloutlist]
76
77
. This list can be used to add references to annotated images
## Use with the [IntelliJ Asciidoc Plugin](https://plugins.jetbrains.com/plugin/7391-asciidoc)
108
+
## Use the [IntelliJ Asciidoc Plugin](https://plugins.jetbrains.com/plugin/7391-asciidoc)
108
109
109
-
If you're not using the excellent Asciidoc plugin then you're really missing out.
110
-
One if its lesser known features is that it supports Asciidoc extensions written in Ruby:
110
+
If you're not using the excellent Asciidoc plugin, then you're really missing out.
111
+
One of its lesser known features is that it supports Asciidoc extensions written in Ruby:
111
112
112
113
1. Create a new folder structure in the root of your IntelliJ project called `.asciidoctor/lib`.
113
114
2. Copy the file `asciidoctor-external-calllout.rb` from this distribution to `.asciidoctor/lib`.
@@ -128,7 +129,7 @@ The callout attaches a class called `external-callout-block` to each source list
128
129
129
130
The extension also adds a class called `external-callout-list` to the list of definitions at the bottom of the source block. (There's probably no need to adjust the styling for this.)
130
131
131
-
Then to convert a document with a stylesheet, use something like this:
132
+
To convert a document with a stylesheet, use something like this:
0 commit comments