Documentation Guide
About this guide
Who is this guide for?
This guide is intended for parties interested in contributing to this documentation.
What is it about?
This guide describes a recommended workflow and required conventions to be used when creating content.
Workflow
Setup Environment
While the online editor may be used, the most efficient way to create documentation is to install the GitBook Toolchain locally. See https://toolchain.gitbook.com/ for detailed instructions. The short version follows.
The following is required:
NodeJS (v4.0.0 and above is recommended)
git
A Markdown editor/IDE (ATOM is a good open source choice)
Windows, Linux, Unix, or Mac OS X
Install
gitbook-cli
using npm:Clone the mdEditor GitBook:
Setup GitBook
Start the local GitBook server
Open a browser to: http://localhost:4000
Style Guide
This section covers styling conventions required for this documentations. Some of the conventions rely on plug-ins that enhance the native GitBook Markdown functionality. In some instances, the effects of the plugins are not displayed until after the book has been generated.
Headings
Please use headings to define page sections. Heading levels should appear sequentially without gaps (don't skip heading levels). Headings should start at Level 1 for the page title. Headings should not be used purely to define font styles - if absolutely necessary, use CSS for that. Following this convention will make it possible to parse the markdown programmatically, e.g. to dynamically create a table of contents.
Lists
Ordered lists
Ordered lists are processed irrespective of the actual number assigned to each list item. For Example:
first
second
third
is rendered the same as:
first
twelfth
thirtieth
Therefore, one recommended convention is to use 1.
for every item in an ordered list. This makes it easier to insert or remove items from the list, at the expense of slightly less readable Markdown. If you choose to sequentially order the list items, you must make sure the numbers are sequential to avoid confusion.
List headings
Headings may be use in lists. However, special handling is required to ensure bullets for ordered lists are styled appropriately.
The tasks
tag is available for styling "task lists". For simplicity, all of the various heading levels are styled the same.
Example without task tag
Level 2
Level 3
Level 6
Example with task tag
Level 2
Level 3
Level 6
Icons
FontAwesome icons are available. Use an <i>
tag to render the chosen icon.
Happy Birthday
Buttons
Bootstrap 3 style buttons are supported. Use a <span>
tag since these are for documentation only. Icons may be combined with buttons.
Default Primary Success Info Extra - Small Warning - Small Danger - Large Link
Hints
Styled hint blocks are supported.
There are five supported variations.
info
(default)tip
danger
working
plain
Info: this note needs to be highlighted.
Tip: 20% is customary.
Danger: this is going to blow up!
Working: for the man every night and day...
Plain: booooooorrrrring.
Screenshots
The following software is required:
A tool to capture screenshots
Windows, Linux, Unix, or Mac OS X
Types of screenshots
basic screenshots have no annotation or markup applied
annotated screenshots have markup applied, e.g. callouts, highlights, etc.
Requirements for all screenshots
Minimum 1200px wide
Must include a caption
PNG format
Generally browser window captures should only contain minimum user interface controls, without navigation toolbar, tab bar, bookmarks toolbar, or status bar. See Bookmarlet for Screenshots.
Images should be stored in the
assets
directory corresponding to the section in which the image appears. Exceptions to this requirement are made for images used in multiple sections.Image sizes should be as small as possible without sacrificing quality.
Usually significant size reduction can be achieved by color-type or bit-depth
reduction. pngcrush is a good tool for this.
Requirements for annotated screenshots
Use LibreOffice Draw to create the annotations
A template is available here
/assets/documentation-guide/callouts-template.odg
Each screenshot should be placed on a new page
Whenever possible place annotations in callouts outside of the image or
in a way that does not cover user interface elements
Name the page using the name of the PNG file
Export the screenshot to PNG
only export the
compression level 6
1200 pixels wide
All annotated screenshots for a section should be stored in a single
.odg
file.Save the LibreOffice Draw file (.odg) in the directory with the screenshots
Screenshot captions
To apply a caption to a screenshot use this syntax in the Markdown.
To apply a border to a screenshot, add class=border
.
Applying the {caption}
to a image will also indent the image from the surrounding text.
Bookmarlet for Screenshots
Use this bookmarlet: Plain Window. Drag the link to your bookmarks bar or create a bookmark with the code below. Clicking the bookmark will open the current webpage in a plain window that is 1200px wide. Re-size to needed height and take a screenshot. More about bookmarlets here: https://www.wikipedia.org/wiki/Bookmarklet.
Last updated