com.hydroper.rb
v1.0.11
Published
Generate reference portals using Markdown.
Readme
RB (Reference Builder)
Create reference portals using Markdown.
Getting started
Install the command line tool with:
npm i -g com.hydroper.rbBuild a reference portal into HTML (out directory) by running the following command:
hydroper-rb buildDocumentation
Configuration file
The configuration file consists of the filename rb.xml.
Example
Note that the portal and references may contain a favicon.png file as the page's icon (not the top bar's icon).
<?xml version="1.0"?>
<portal>
<title>My Reference Portal</title>
<base-path>src</base-path>
<!-- Optional description -->
<description>My reference portal.</description>
<!-- Icon -->
<icon>icon.png</icon>
<!-- Icon used in light mode -->
<dark-icon>dark-icon.png</dark-icon>
<!-- Increases the icon size in the top bar -->
<expand-icon>true</expand-icon>
<!-- Optional company logo generally 43x72 pixels (attached to the right below the top bar) -->
<company-logo>qux.png</company-logo>
<!-- Optional top bar colors. The light mode usually has a #fff background -->
<top-bar-colors top="#aaa" bottom="#fff"/>
<!-- Top bar colors used in dark mode. The dark mode usually has a #454545 background -->
<dark-top-bar-colors top="#999" bottom="#454545"/>
<references>
<reference>
<base-path>demo-reference</base-path>
<title>Demo Reference</title>
<!-- Optional description -->
<description>Demo reference.</description>
<!-- Icon -->
<icon>icon.png</icon>
<!-- Optional top bar colors -->
<top-bar-colors top="#999" bottom="#000"/>
<home>
<!-- src/demo-reference/index.md -->
<title>Demo</title>
<path>index.md</path>
</home>
<sections>
<section>
<!-- src/demo-reference/foo.md -->
<title>Foo</title>
<path>foo.md</path>
<sections>
<section>
<!-- src/demo-reference/foo/bar.md -->
<title>Bar</title>
<path>foo/bar.md</path>
</section>
</sections>
</section>
</sections>
</reference>
</references>
</portal>Media
Media (PNG, BMP, GIF, JPG/JPEG, SVG, MP4) get copied from the <base-path> path of the <portal> element, where for instance, given <base-path>src</base-path>, a file such as src/demo-reference/img.png will have the static path equals /demo-reference/img.png.
The favicon.png file is what is used for the document icon; both the portal and reference can specify one.
License
Apache 2.0
