LibKa
v2.0.4One LibKa Markdown file to web pages, PDFs, slides and Word files, each checked and signed.
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
libka_list_blocks List LibKa blocks
Every LibKa block with the content it fits ("use when"), grouped; plus content that has no block, and what to write for it instead.
| Parameter | Type | Description |
|---|---|---|
group | string | Only this group: text, how-to, explain, highlight, media, data, ui |
libka_get_block Get one LibKa block
Full definition of a block: example syntax, attributes, what the web page, PDF, slides and Word file do with it, accessibility rules, anti-patterns and its JSON schema.
| Parameter | Type | Description |
|---|---|---|
name * | string | Block name, such as steps, tabs, chart or ui |
libka_check Check LibKa Markdown
Parse LibKa Markdown without building: problems with line numbers (fix all of them), the outline, block counts, how many slides the deck will have and the design it is built with. Fast; call it after every change.
| Parameter | Type | Description |
|---|---|---|
markdown * | string | The complete LibKa Markdown document, including front matter |
path | string | Where the document is or will be saved (.md), so its brand and theme files (brand:, theme:, the project's _brand.yml) are found and checked too |
libka_build Build a LibKa document
Write the LibKa Markdown to a folder and build it: the outputs the document asks for in its front matter (outputs: web, pdf, deck, docx; default web and pdf), or the outputs given here. Guard checks every output (the pages in Chrome, the PDF with veraPDF when Java and veraPDF are installed, the Word file's structure); passing outputs are signed. Returns the files and every Guard finding to fix. Writes files on this machine, and removes this document's own earlier outputs that this build did not make again.
| Parameter | Type | Description |
|---|---|---|
markdown | string | The document; or give path instead, not both |
name | string | File name without extension when markdown is given (default: document) |
outDir | string | Output folder (default: LIBKA_OUT, or ./libka-out) |
outputs | array | Build these instead of the document's own outputs, e.g. ["web", "deck"] to check slide fit quickly |
path | string | An existing .md file to build, only read (images are found next to it) |