diff options
| author | Shulhan <ms@kilabit.info> | 2026-02-09 13:00:04 +0700 |
|---|---|---|
| committer | Shulhan <ms@kilabit.info> | 2026-02-09 13:00:04 +0700 |
| commit | 4956de038af8b52db6d03f0b6f5b77e6b7cfa721 (patch) | |
| tree | 60bd4268068fd4c59af097d976c1df09d01c66a5 /CHANGELOG.adoc | |
| parent | 0fc91c39caefa0e00832cce55ae5a0073e67f6a8 (diff) | |
| download | asciidoctor-go-0.7.3.tar.xz | |
Release asciidoctor-go v0.7.3 (2026-02-09)v0.7.3
**🌼 all: add aria-label to the anchor when sectanchor enabled**
The aria-label help user with screen reader to discern and navigate
the anchor.
For more information see
https://dequeuniversity.com/rules/axe/4.11/link-name .
**🌼 all: update default CSS to asciidoctor v2.0.26**
The default CSS now split into separate file to simplify tracking and
modifying the style as needed.
Diffstat (limited to 'CHANGELOG.adoc')
| -rw-r--r--[l---------] | CHANGELOG.adoc | 662 |
1 files changed, 661 insertions, 1 deletions
diff --git a/CHANGELOG.adoc b/CHANGELOG.adoc index a75130b..325d1eb 120000..100644 --- a/CHANGELOG.adoc +++ b/CHANGELOG.adoc @@ -1 +1,661 @@ -CHANGELOG
\ No newline at end of file +// SPDX-License-Identifier: GPL-3.0-or-later +// SPDX-FileCopyrightText: 2021 M. Shulhan <ms@kilabit.info> + += Changelog for asciidoctor-go +:sectanchors: +:toc: + +Legend, + +* 🪵: Breaking changes +* 🌱: New feature +* 🌼: Enhancement +* 💧: Chores + +[#v0_7_3] +== asciidoctor-go v0.7.3 (2026-02-09) + +**🌼 all: add aria-label to the anchor when sectanchor enabled** + +The aria-label help user with screen reader to discern and navigate +the anchor. + +For more information see +https://dequeuniversity.com/rules/axe/4.11/link-name . + +**🌼 all: update default CSS to asciidoctor v2.0.26** + +The default CSS now split into separate file to simplify tracking and +modifying the style as needed. + + +[#v0_7_2] +== asciidoctor-go v0.7.2 (2025-12-27) + +This release update the README so the _doc directory can be served under +https://kilabit.info/project/asciidoctor-go . + +The go.mod is updated to use minimum Go 1.24.0 and all dependencies has been +updated to latest release. + + +[#v0_7_1] +== asciidoctor-go v0.7.1 (2025-04-18) + +[BUG FIX] **Fix the logic when applying default embedded CSS.** + +By default, the document contains ":stylesheet:" attribute, which +means using the default embedded CSS. +To disable it, unset the attribute using ":stylesheet!:". +To overwrite it, set the attribute to path of CSS file +":stylesheet: my.css". + +[ENHANCEMENT] Export the constant for document attribute "stylesheet". + + +[#v0_7_0] +== asciidoctor-go v0.7.0 (2025-04-18) + +[NEW FEATURE] **Support include directive inside block code**. + +Example of block code with include directive, + +.... +---- +... +include::file[] +... +---- +.... + +[NEW FEATURE] **Support document attribute "docdir"** + +The "docdir" attribute contains the full path of the directory that +contains the source document. +By default it is set to the directory where the Document resided. + +[NEW FEATURE] **Add default HTML stylesheet.** + +The generated HTML now contains the default stylesheet. +The stylesheet is copied from HTML file generated by Asciidoctor v2.0.23. + + +[#v0_6_2] +== asciidoctor-go v0.6.2 (2025-02-01) + +[BUG FIX] **Fix section detected as paragraph after list and comment.** + +Previously, given the following markup, +---- +* Sub list ++ +Sub list content. + +//}}} +//{{{ +== Sub 2 +//}} +---- +The section "Sub 2" will be parsed as paragraph instead of new section. + +[CHORE] +In the linter, we replace the fieldalignment and shadow using our internal +gocheck command. +This linters actually have an API that can be combined into a program, +which provided by package "pakakeh.go/lib/goanalysis". + + +[#v0_6_1] +== asciidoctor-go v0.6.1 (2024-12-08) + +[#v0_6_1__bug_fixes] +=== Bug fixes + +all: fix error log when failed to open included file:: ++ +The log use the wrong variable when printing path for failed include +file. + +all: fix reading include file when parent path is absolute:: ++ +Previously, if the parent document is opened using absolute path and +it contains include directive, the included file will fail to read +because the parent path is joined with current working directory. + + +[#v0_6_0] +== asciidoctor-go v0.6.0 (2024-09-07) + +[#v0_6_0__breaking_changes] +=== Breaking changes + +all: rename struct "AttributeEntry" to "DocumentAttribute":: ++ +This is to make the struct is clear that it represent the document +attribute. + +all: rename struct "AttributeEntry" to "DocumentAttribute":: ++ +This is to make the struct is clear that it represent the document +attribute. + +all: refactoring DocumentAttribute into struct:: ++ +Using struct limit the value to only string, while some attributes +can be an integer value, for example "leveloffset". + +[#v0_6_0__new_features] +=== New features + +all: support document attribute "leveloffset":: ++ +-- +The ":leveloffset:" on document attribute allow increment +or decrement the heading level on included files. + +Reference: https://docs.asciidoctor.org/asciidoc/latest/directives/include-with-leveloffset/ +-- + +[#v0_6_0__enhancements] +=== Enhancements + +all: use strict document header format:: ++ +-- +Previously, an empty line before Document Title cause the parser +stop parsing the document header, now an empty lines are skipped. +Also document attribute can be place anywhere, either before or +after title, and in between attributes; now it can be only placed +after revision or author or title. +-- + +all: remove unnecessary TrimRight:: ++ +Each lines to be parsed has been trimmed on the first load, so +there is no need to do it again, on some cases. + + +[#v0_5_2] +== asciidoctor-go v0.5.2 (2023-04-04) + +This release only contains chores. + +all: replace module "share" with "pakakeh.go":: ++ +-- +The "share" module has been moved to new repository with new name at +"https://sr.ht/~shulhan/pakakeh.go". +For more information see the change logs at "pakakeh.go" module. +-- + +all: comply with linter recommendations:: ++ +Most of the code changes related to refactoring if-else witch switch +statement. + +all: replace if-else bytes.Equals with static string case comparisons:: ++ +Using string instead of [bytes.Equal] give code much more readable. + + +[#v0_5_1] +== asciidoctor-go v0.5.1 (2023-12-14) + +[#v0_5_1__bug_fixes] +=== Bug fixes + +all: fix custom IDs on first section always got replaced:: ++ +-- +Any custom ID on the first section always replaced with the subsection +because, first, when detecting preamble we did not check for line with +kind ID "[[...]]" an short ID "[#...]". +Second, when parsing preamble we did not stop when we found line kind +ID and short ID. + +This preamble thing is kind of annoying. +We need to revisit again how to detect preamble, maybe not calling +separate block parser, but making it linear as the default first child of +parent element. +-- + +[#v0_5_1__chores] +=== Chores + +all: replace "lib/parser" with "strings/parser":: ++ +The lib/parser has been deprecated in share module. + +all: remove dependency to "git.sr.ht/~shulhan/pakakeh.go/lib/debug":: + +all: replace linter golangci-lint with revive and shadow:: ++ +-- +The golangci-lint does not output any results anymore +Either we are getting good at writing Go or the linter itself is become +less good. +We also have seen that the latest golangci-lint is failed to build +with Go tip, a simple "make" on the golangci-lint never success in my +experiences. + +This changes fix all the output reported by the revive and shadow. +-- + + +[#v0_5_0] +== asciidoctor-go v0.5.0 (2023-06-04) + +[#v0_5_0__new_features] +=== New features + +all: add support for unordered list with '-':: ++ +-- +The unordered list item with hyphen ('-') cause too much confusion and +inconsistency, nevertheless most of still use it. + +Case one, given the following markup, + +---- +- Item 1 ++ +"A line +of quote" +-- Author +---- + +Is the "Author" the sub item in list or we are parsing author of quote +paragraph? + +Case two, the writer want to write em dash (`—` in HTML Unicode) but +somehow the editor wrap it and start in new line. + +As a reminder, the official documentation only recommend using hyphen for +simple list item [1]. + +[1] https://docs.asciidoctor.org/asciidoc/latest/lists/unordered/#basic-unordered-list +-- + +[#v0_5_0__bug_fixes] +=== Bug fixes + +all: fix rendering blockquote without attribution:: ++ +-- +Previously, in the htmlWriteBlockQuoteEnd, if attribution is set +we add HTML tag <div> and close it later after we add citation. + +The issue is we did not check if attribution is true again when we +add closing tag for div, which make the div above of blockquote get +closed. +-- + +all: handle custom marker in between unordered list:: ++ +-- +Given the following markup, + +---- +[square] +* item 1 +[circle] +** item 2 +---- + +The list on item 2 now start with `<div class="ulist circle">`. +-- + + +[#v0_4_1] +== asciidoctor-go v0.4.1 (2023-03-03) + +[#v0_4_1__bug_fixes] +=== Bug fixes + +all: fix empty line printed on ToHTMLBody or ToHTMLEmbedded:: ++ +-- +Given the following adoc, + +---- += T +---- + +If we call ToHTMLBody, the output is + +---- +(empty line here) +<div id="header"> +<h1>T</h1> +---- + +This changes remove the empty line at the top. +-- + + +all: ignore parsing block image in paragraph:: ++ +-- +Previously, if we have block image in paragraph, we parse it as inline +image but with invalid src, for example + +---- +image::my.png[multi +line]. +---- + +would be parsed as <img src=":imy.png" alt="multi line">. +This is incorrect according to asciidoctor output. +-- + + +[#v0_4_1__enhancements] +=== Enhancements + +all: handle empty preamble:: ++ +If the document contains empty preamble do not output the HTML wrapper of it. + + +[#v0_4_0] +== asciidoctor-go v0.4.0 (2023-02-12) + +[#v0_4_0_new_features] +=== New features + +all: add support for document attribute "last-update-label":: ++ +-- +By default the last-update-label value set to "Last updated" and the value is +the document modification time. + +If the label is suppressed with "!", no "Last updated" will be print on the +footer. +-- + + +all: implement inline macro for passthrough ("pass:"):: ++ +-- +The inline passthrough "pass:" can be used to control the substitutions +applied to a run of text. + +Ref: https://docs.asciidoctor.org/asciidoc/latest/pass/pass-macro/ +-- + + +all: implement macro "footnote:":: ++ +-- +Macro footnote grammar, + +---- +"footnote:" [ REF_ID ] "[" STRING "]" +---- + +In asciidoctor, footnote can be placed anywhere, even after WORD without +space in between. + +The REF_ID, define the unique ID for footnote and can be used to reference +the previous footnote. +The first footnote with REF_ID, should have the STRING defined. +The next footnote with the same REF_ID, should not have the STRING +defined; if its defined, the STRING is ignored. +-- + + +[#v0_4_0_bug_fixes] +=== Bug fixes + +all: detach parsing preamble from content:: ++ +This is to prevent empty preamble being rendered in HTML content. + + +all: fix the orders of generated HTML meta:: ++ +-- +The meta tags from original asciidoctor are ordered as viewport, generator, +description, keywords, and then author. + +While at it remove empty style tag due to when testing we use empty.css not +"stylesheet!". +-- + + +[#v0_4_0_enhancements] +=== Enhancements + +all: support multi line attribute values:: ++ +If the attribute value end with backslash '\\', the value continue to the +next line. + + +[#v0_3_2] +== asciidoctor-go v0.3.2 (2022-09-05) + +[#v0_3_2_bug_fix] +=== Bug fix + +all: fix parsing list description inside include directive:: ++ +-- +Previously, given the following include statements in the main document + +---- +include::list_desc.adoc[] + +include::list_desc.adoc[] +---- + +Where list_desc.adoc content is, + +---- +Item 00:: ++ +-- +* Bullet 0 ++ +Description 0. + +* Bullet 1 +-- +---- + +The first include is parsed correctly, but the second include is parsed +as is. +-- + +[#v0_3_2_chores] +=== Chores + +all: update share module to v0.41.0:: + +all: move all documentation into directory _doc:: ++ +While at it reformat the README, add section for development, add +link for Go documentation. + + +[#v0_3_1] +== asciidoctor-go v0.3.1 (2022-08-06) + +[#v0_3_1_chores] +=== Chores + +all: rewrite unit tests for inlineParser using test.Data:: ++ +-- +Using string literal for testing string input that may contains backtick +or double quote make the test code become unreadable and hard to modify. + +The test.Data help this by moving the input and expected output into +a file that can we write as is. +-- + +all: cleaning up codes:: Use raw string literal whenever possible. + +go.mod: update share to v0.40.0:: ++ +-- +This update fix some issues related to new line on test.Data. +-- + + +[#v0_3_0] +== asciidoctor-go v0.3.0 (2022-07-24) + +This release set the minimum Go version to 1.18. + +[#v0_3_0_breaking_changes] +=== Breaking changes + +all: refactoring handling generate ref ID:: ++ +-- +Previously, we always set the ID prefix and separator default to "\_" if +its not set, this cause all of the ID is prefixed with "\_". + +This changes use strict rules when generating ID following the Mozilla +specification [1] and latest AsciiDoc Language [2]. + +The idprefix must be ASCII string. +It must start with "\_", "-", or ASCII letters, otherwise the "\_" will +be added to the beginning. +If one of the character is not valid, it will replaced with "\_". + +The `idseparator` can be empty or single ASCII character ('\_' or '-', +ASCII letter, or digit). +It is used to replace invalid characters in the REF_ID. + +[1] https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/id + +[2] https://docs.asciidoctor.org/asciidoc/latest/sections/id-prefix-and-separator/ +-- + +[#v0_3_0_enhancements] +=== Enhancements + +all: sort the generated HTML meta by names:: ++ +-- +The order of meta names are "author", "description", "generator", and +then "keywords". +-- + +all: store the list of author names under Attributes "author_names":: ++ +-- +Previously, to get list of author names, we need to iterate each of +the Authors field. + +This changes set the Attributes "author_names" to list of author full +names, each separated by comma. +-- + +all: add default metadata "generator":: ++ +-- +The generator metadata contains the library name and its current version. +-- + +all: realign all structs:: ++ +-- +This is to minimize memory allocation when using asciidoctor. +-- + +[#v0_3_0_chores] +=== Chores + +all: rewrite test using lib/test.Data:: ++ +-- +Previously, to test parser and check the generated HTML, we write AsciDoc +input and expected HTML output using literal string `...`. +The text of input and output sometimes long, take multiple lines, which +makes the test code ugly, hard to write, and read. + +Using lib/test.Data we can write the input and output as the AsciiDoc +markup and the HTML markup as is, simplify writing the test and more +readable. +-- + + +[#v0_2_0] +== asciidoctor-go v0.2.0 (2022-03-04) + +This release changes the license of asciidoctor-go from BSD to GPL 3.0 or +later. + +[#v0_2_0_bug_fixes] +=== Bug fixes + +all: fix list check box text get cut one character:: ++ +-- +Given the following asciidoc check box markup, + + * [ ] abc + +It will rendereded as "❏ bc" instead of "❏ abc". +-- + +[#v0_2_0_chores] +=== Chores + +all: replace bytes.Title and strings.Title with function:: ++ +-- +Both of those functions has been deprecated. + +Since the Title function is to convert the adminition string into a +human title (first letter uppercase), we can use a function to do that. +Any unknown admonition will be returned as is. +-- + + +[#v0_1_1] +== asciidoctor-go v0.1.1 (2021-12-06) + + +[#v0_1_1_bug_fixes] +=== Bug fixes + +all: fix parsing and rendering cross reference:: ++ +-- +Previously, when parsing cross reference we assume that if the string +contains upper-case letter then it's a label so we store it as title +to search for ID later. + +The bug is when ID is set manually and its contains upper-case for +example "[#Id]". + +This changes fix this issue by storing cross reference first, not +assuming it as ID or title, and then when doing rendering we check +whether its ID or title. +-- + +all: allow colon ':' and period '.' on the ID:: ++ +-- +According to XML spec [1], the colon is allowed as the first and the next +character. While period is only allowed on the next characters. + +[1] https://www.w3.org/TR/REC-xml/#NT-Name +-- + + +[#v0_1_0] +== asciidoctor-go v0.1.0 (2021-03-06) + +The asciidoctor-go is the Go module to parse the AsciiDoc (TM) markup +and convert it into HTML5. + +This first release bring almost all AsciiDoc syntax except for include +directive, inter-document cross-reference, macros, and non-primary syntax +features. + +I hope this library can be useful for Gophers who need the power of AsciiDoc +in their workflows. |
