title | contributors | description | |
---|---|---|---|
How to Edit Wiki |
|
Ways to help us improve our wiki |
Robonomics Wiki is open source. Any corrections are welcome: fixing errors, typos, some unclear or outdated information, translation into any language. You'll need a GitHub account.
If you need to edit docs of Robonomics Wiki, please, follow these steps
Make sure, you have Node.js and Gridsome installed.
At first, you need to clone the wiki repository:
git clone https://github.com/airalab/robonomics-wiki.git
Go to the directory of the repository and run the following commands:
using npm
cd robonomics-wiki
npm install
using yarn
cd robonomics-wiki
yarn install
Then deploy the project locally:
gridsome develop
If you have the error
node: --openssl-legacy-provider is not allowed in NODE_OPTIONS
, run the following command:
gridsome develop-m1
Make pull request to wiki repo
Robonomics Wiki has support for Asciinema. To insert Asciinema, please, follow these instructions:
- Import component after frontmatter block
import Asciinema from '~/components/Asciinema.vue'
- Insert as separate paragraph
<Asciinema vid="WCFcx8C6M8e52UKDNei1xZloU"/>
, where is vid is ID of specific asciicast
You can get the widget script for a specific asciicast by clicking on “Embed” link on asciicast page. It looks like this:
<script src="https://asciinema.org/a/14.js" id="asciicast-14" async></script>
Asciinema docs
In the example above vid is 14.
You can add helpful extras to your code:
code with copy button
<code-helper copy>
YOUR CODE HERE
</code-helper>
or code with additional line
<code-helper additionalLine="this line will be added above your code :)">
YOUR CODE HERE
</code-helper>
Properties for code-helper
$ ls -l /dev/serial/by-id
$ ls -l /dev/serial/by-id
Docs in Robonomics Wiki contain frontmatter block. It must be at the top of the Markdown file, and must take the form of valid YAML set between triple-dashed lines. Between the triple-dashed lines, you can set or edit folowing options:
---
title: How to contribute # Title for the page, you do not need to duplicate it in text
contributors: [positivecrash] # Main contributors (who actively curates this page). GitHub nickname required, without any additional symbols
tools:
- rust 1.62.0
https://blog.rust-lang.org/2022/06/30/Rust-1.62.0.html
- Robonomics 1.4.0
- baxter
http://wiki.ros.org/melodic/Installation
# Tools that were used for technology testing
---
Helps to add grid layout to elements:
- Use grid wrapper component first:
<robo-wiki-grid-element-wrapper></robo-wiki-grid-element-wrapper>
- And then use as many grid items components as you like inside wrapper:
<robo-wiki-grid-element-wrapper :columns="2" textAlign="center">
<robo-wiki-grid-element>
<robo-wiki-picture src="home-assistant/need_5.png" />
<p>Zigbee smart devices (any from <a href="https://slsys.io/action/supported_devices.html">supported devices</a>)</p>
</robo-wiki-grid-element>
<robo-wiki-grid-element>
<robo-wiki-picture src="home-assistant/need_6.png" />
<p>Zigbee adapter <a href="https://jethome.ru/z2/">JetHome USB JetStick Z2</a> (or one of <a href="https://www.zigbee2mqtt.io/information/supported_adapters.html">supported</a>) or
<a href="https://easyeda.com/ludovich88/robonomics_sls_gateway_v01">Robonomics SLS Gateway</a></p>
</robo-wiki-grid-element/>
</robo-wiki-grid-element-wrapper>
Properties for robo-wiki-grid-element-wrapper
Home Assistant as control system software
Raspberry Pi 4 (at least 2 GB RAM)
SD card (minimum 16 GB)
SD adapter
Zigbee smart devices (any from supported devices)
Zigbee adapter JetHome USB JetStick Z2 (or one of supported) or Robonomics SLS Gateway
Upload image in folder /docs/images/url-of-your-doc
- If image needs to be localized, insert all of them in one folder
- Use locale appendix in name of images if it's localized, e.g.
image_en.jpg
- Make sure your image is web optimized and at the same time it looks good
There are two ways for inserting pictures in your documents:
It is recommended to insert pictures with built-in tag <robo-wiki-picture>
, however you may also use standard way for Markdown files.
with caption
<robo-wiki-picture link="/docs/community" src="example_image.jpg" caption="EXPLORE ROBONOMICS WIKI" />
or without caption
<robo-wiki-picture link="/docs/community" src="example_image.jpg" />
or simple image
<robo-wiki-picture src="example_image.jpg" />
or simple image with caption
<robo-wiki-picture src="example_image.jpg" caption="EXPLORE ROBONOMICS WIKI" />
image with alt
<robo-wiki-picture src="example_image.jpg" caption="EXPLORE ROBONOMICS WIKI" alt="this is alternative text for image" />
Properties for robo-wiki-picture:
You can add notes and give them specific types:
- warning (orange color)
- okay (green color)
- note (grey color)
note with title
<robo-wiki-note type="okay" title="Some information about robots" />
note with content
<robo-wiki-note type="okay">Fascinating information about robonomics here only</robo-wiki-note>
note with title and content
<robo-wiki-note type="okay" title="Robonomics for you">
Fascinating information about robonomics here only
</robo-wiki-note>
Join Robonomics Developers Discord to connect with community and get technical support.
Join Robonomics Developers Discord to connect with community and get technical support.
Join Robonomics Developers Discord to connect with community and get technical support.
Properties for robo-wiki-note
You can add tabs to the doc:
- Use tabs wrapper component:
<robo-wiki-tabs></robo-wiki-tabs>
- And then use as many tab items components as you like inside wrapper:
<robo-wiki-tabs>
<robo-wiki-tab title="Linux">
<pre>ip a</pre>
</robo-wiki-tab>
<robo-wiki-tab title="OSX">
ifconfig
</robo-wiki-tab>
</robo-wiki-tabs>
horizontal tabs
<robo-wiki-tabs>
<robo-wiki-tab title="Linux">
<pre>ip a</pre>
</robo-wiki-tab>
<robo-wiki-tab title="OSX">
ifconfig
</robo-wiki-tab>
</robo-wiki-tabs>
vertical tabs
<robo-wiki-tabs mode="vertical">
<robo-wiki-tab title="Linux">
<pre>ip a</pre>
</robo-wiki-tab>
<robo-wiki-tab title="OSX">
<pre>ifconfig</pre>
</robo-wiki-tab>
</robo-wiki-tabs>
tab item with border
<robo-wiki-tabs>
<robo-wiki-tab title="Linux">
<pre>ip a</pre>
</robo-wiki-tab>
<robo-wiki-tab title="OSX" border>
ifconfig
</robo-wiki-tab>
</robo-wiki-tabs>
Properties for robo-wiki-tabs (wrapper)
Properties for robo-wiki-tab (item)
ip aifconfig
ip a
ifconfig
You can create custom titles with anchors and give them certain value
title with anchor
<robo-wiki-title :type="2" anchor="Some information about robots">
Learn Robonomics :)
</robo-wiki-title>
or
title without anchor
<robo-wiki-title :type="5">
Learn with us ;)
</robo-wiki-title>
Properties for robo-wiki-title
I'm custom title :)There are two ways for inserting videos in your documents:
It is recommended to insert videos with built-in tag <robo-wiki-video>
, however you may also use standard way for Markdown files.
You need to specify format of video
<robo-wiki-video autoplay loop controls :videos="[{src: 'https://cloudflare-ipfs.com/ipfs/QmdZKkPJCa9GEN43iUBX81jfrFTDxcn7J6wWURrwNVwcKx', type:'webm'}, {src: 'https://cloudflare-ipfs.com/ipfs/QmStCDsEHCYwVYvnDdmZBMnobPmrgZx3iJLm65b8XNzKQa', type:'mp4'}]" />
<robo-wiki-video autoplay loop controls :videos="[{src: '/videos/add-ext.mp4', type:'mp4'}]" />
-
If you adding a file with the size of more than 10MB, please, upload it on server, not in repo.
-
You may use any properties for HTML5 video tag.
-
Acceptable formats - mp4, webm, ogg.
You can embed any YouTube video in doc by inserting share link as separate paragraph without any additional quotes or tags, e.g.: https://youtu.be/kQaSwNYHJQ8
However, if you need an autoplay you must use special component:
<robo-wiki-youtube autoplay link="https://www.youtube.com/watch?v=5s4-S_z4VYE" />
Properties for robo-wiki-youtube
If you need to edit sidebar navigation of Robonomics Wiki, please, follow these steps:
-
Edit file
/data/sidebar_docs.yaml
. -
Decide where to place your doc
-
Use valid YAML for
/data/sidebar_docs.yaml
and rely on the existing file structure -
IMPORTANT NOTE: if you're using the same doc in different sections/subsections e.g:
- title_en: Upgrade Home Assistant OS
items:
- title_en: Buying a Subscription
link: /docs/sub-activate
- title_en: Pre-installed Image For Raspberry Pi
items:
- title_en: Buying a Subscription
link: /docs/sub-activate
MAKE SURE TO ADD topic
PARAMETER LIKE THIS:
(for navigation to work properly)
- title_en: Upgrade Home Assistant OS
items:
- title_en: Buying a Subscription
link: /docs/sub-activate
topic: Upgrade Home Assistant OS
- title_en: Pre-installed Image For Raspberry Pi
items:
- title_en: Buying a Subscription
link: /docs/sub-activate
topic: Pre-installed Image For Raspberry Pi
-
Edit file
/data/sidebar_docs.yaml
. -
Find the right doc and add parameters
prev
andnext
like this:
- title_en: How to Edit Wiki
link: /docs/edit-wiki
prev:
- title: title of the previous page
link: /docs/prev_page_url
next:
- title: title of the next page
link: /docs/next_page_url
- If you want to remove navigation completely than add
withoutNav
parameter:
- title_en: How to Edit Wiki
link: /docs/edit-wiki
withoutNav: true
- If you want to remove just
previous page
ornext page
navigation than addwithoutPrev
orwithoutNext
parameter:
- title_en: How to Edit Wiki
link: /docs/edit-wiki
withoutPrev: true
or
- title_en: How to Edit Wiki
link: /docs/edit-wiki
withoutNext: true