1
0
mirror of https://github.com/danog/blackfriday.git synced 2024-12-02 09:27:49 +01:00
Commit Graph

13 Commits

Author SHA1 Message Date
Vytautas Šaltenis
c9ea588e6f Convert uint32 fields to ints
The former is a bit too inconvenient despite being more accurate.
2016-04-11 11:15:15 +03:00
Vytautas Šaltenis
9da90c5929 Allow NodeVisitor to have some control over traversal
Make NodeVisitor return status and decide upon it which node to go to
next. So far, this allows to skip subtrees and quit early.
2016-04-05 12:48:28 +03:00
Vytautas Šaltenis
e7d45749ff Give node visitor callback type a name and docs 2016-04-05 12:48:28 +03:00
Vytautas Šaltenis
d7f18785f1 Implement TOC and OmitContents
Move these two flags from HTML renderer's flags to extensions. Implement
both since they were not yet implemented in the AST rewrite. Add tests.

Note: the expected test strings differ very slightly from v1. The HTML
produced by v2 has a few extra newlines compared to the old one, but
it's now uniform with other sections of the generated document. If the
newline placement gets cleaned up in the future, this will get fixed
automatically, since the renderer is agnostic about the TOC list.
2016-04-04 12:04:20 +03:00
Vytautas Šaltenis
02a5ce37ff Go style: Html{Block|Span} -> HTML{Block|Span} 2016-04-01 13:15:47 +03:00
Vytautas Šaltenis
f1361aa0da Make ForEachNode func a Walk method on Node 2016-04-01 12:36:56 +03:00
Vytautas Šaltenis
04673c9f28 Improve documentation for Node struct 2016-04-01 12:33:05 +03:00
Vytautas Šaltenis
8a4d4fa0cd Move Header-related fields to a nested struct 2016-04-01 11:48:52 +03:00
Vytautas Šaltenis
bcd5b5b780 Move table cell fields to a nested struct 2016-04-01 11:46:09 +03:00
Vytautas Šaltenis
4ba991937b Store cell alignment in own type instead of int 2016-04-01 11:44:59 +03:00
Vytautas Šaltenis
67f85cf540 Move code block fields to a nested struct 2016-04-01 11:29:15 +03:00
Vytautas Šaltenis
60026cc3c6 Make ListData a nested struct instead of pointer 2016-04-01 11:21:25 +03:00
Vytautas Šaltenis
2bbed304fb Add AST data structures
The main Node structure that holds every AST node and some supplementary
substructs. A bit of helper code to handle the nodes.
2016-03-30 12:54:12 +03:00