aboutsummaryrefslogtreecommitdiff
path: root/html_template.go
AgeCommit message (Collapse)Author
2026-01-23all: use separate file with go:embed for default CSSShulhan
Using separate file allow tracking and modifying the style as needed.
2025-02-13all: add default HTML stylesheetShulhan
The generated HTML now contains the default stylesheet. The stylesheet is copied from HTML file generated by Asciidoctor v2.0.23.
2022-12-16all: detach parsing preamble from contentShulhan
This is to prevent empty preamble being rendered in HTML content.
2022-07-24all: sort the generated HTML meta by namesShulhan
The order of meta names are "author", "description", "generator", and then "keywords".
2022-07-24all: add default metadata "generator"Shulhan
The generator metadata contains the library name and its current version.
2022-07-16all: reformat all Go filesShulhan
2022-02-21all: relicense the asciidoctor-go under GPL 3.0 or laterShulhan
Signed-off-by: Shulhan <ms@kilabit.info>
2020-12-13html_template: change generator name from ciigo to asciidoctor-goShulhan
ciigo is original repository name where the code splitted up into library.
2020-11-15all: minimize number of short HTML templatesShulhan
Inlining all short HTML templates to HTML backend.
2020-11-15all: add method ToEmbeddedHTMLShulhan
The ToEmbeddedHTML will generate the document content only, without header and footer.
2020-11-15all: support meta "noheader"Shulhan
If the meta "noheader" is set, the document header will not be rendered.
2020-11-12all: rewrite HTML backend template without text/templateShulhan
Instead of using text/template, we use constants of strings. This is give us more simple template and allow us to minimize duplicate code.
2020-11-08all: replace BLOCK_IMAGE template with string constantsShulhan
2020-11-06all: replace some text/template with functions and constantsShulhan
At first thought, using template looks make sense, but when more sub-template added and with more conditionals, using functions and constants I think will give clearer code.
2020-11-05all: support meta attributes "description" and "keywords"Shulhan
2020-11-04all: parse inline format on list description item labelShulhan
2020-11-04all: support inline image with link optionShulhan
2020-11-03all: export the document Attributes fieldShulhan
This is to allow client of library to consume custom attributes that they defined in their document.
2020-11-03all: make the "icons" attribute only applicable to nodeShulhan
2020-11-03all: implement section numbering with sectnums and sectnumlevelsShulhan
2020-11-01all: implement parser for inline and natural cross referenceShulhan
2020-10-31all: implement parser for block anchor and inline anchorShulhan
2020-10-30all: use consistent names and rules between literal and listing blocksShulhan
2020-10-30all: store the src and href on adocNode Attrs instead of valueShulhan
The field value should be only used by lineKindAttribute.
2020-10-30all: fix rendering toc by levelsShulhan
Also, apply div element with class sectionbody only on section L1.
2020-10-29all: add support to set ToC position to "left" or "right"Shulhan
2020-10-29all: implement parser and HTML renderer for table of contentsShulhan
The current implementation only support toc position "auto" (default) and "preamble" with option to set toc level and title.
2020-10-29all: parse inline formatting on section titleShulhan
2020-10-29all: implement parser for inline imageShulhan
2020-10-29all: implement parser for inline URL and linkShulhan
2020-10-27all: implement parser for single quote curveShulhan
Single quote curve is the one that start with ('`) and end with (`'). If (`') does not have a start format it will turn into apostrophe.
2020-10-26all: implement parser for inline formatting bold, italic, and monoShulhan
Finally, I can get this works with all the quirks of how it should be rendered. Its not perfect, at least it started working. It take me couple of weeks to figuring it out how it should be worked.
2020-10-15asciidoctor-go: asciidoctor markup parser for GoShulhan
This is the first commit that can parser whole document line by line and provide convertion to HTML. Things that does not working: inline style, table, passthrough, dynamic attributes, include.