Skip to content

Latest commit

 

History

History
229 lines (149 loc) · 5.3 KB

README.md

File metadata and controls

229 lines (149 loc) · 5.3 KB

Utils docs

IPFS

This library helps to upload files to the IPFS network. In order to get around the limitation on the length of metadata, you can store a description in IPFS network. Since the IPFS hash is calculated cryptographically, it is protected from modify data. Vote UI supporting a Markdown in IPFS description text.

To automatically validate and upload a description to IPFS, you can use a function upload_vote_description_to_ipfs from utils.ipfs. To calculate without uploading, for example for tests, you can use a function calculate_vote_ipfs_description from utils.ipfs. Then you may provide the result to create_vote and confirm_vote_script into desc_info argument. Here is example of vote with ipfs description vote_2023_08_15.py.

Here are examples of supported syntax:

Special LIDO vote elements

Wallets

`0xf73a1260d222f447210581DDf212D915c09a3249`

⚫0xf7...3249

IPFS hashes

`bafybeifx7yeb55armcsxwwitkymga5xf53dxiarykms3ygqic223w5sk3m`

bafy...sk3m

Heading

# h1 Heading
## h2 Heading
### h3 Heading
#### h4 Heading
##### h5 Heading
###### h6 Heading

h1 Heading

h2 Heading

h3 Heading

h4 Heading

h5 Heading
h6 Heading

Horizontal Rules

___

---

***



Emphasis

**This is bold text**

__This is bold text__

*This is italic text*

_This is italic text_

~~Strikethrough~~

This is bold text

This is bold text

This is italic text

This is italic text

Strikethrough

Blockquotes

> Blockquotes can also be nested...
>> ...by using additional greater-than signs right next to each other...
> > > ...or with spaces between arrows.

Blockquotes can also be nested...

...by using additional greater-than signs right next to each other...

...or with spaces between arrows.

Lists

+ Create a list by starting a line with `+`, `-`, or `*`
+ Sub-lists are made by indenting 2 spaces:
  - Marker character change forces new list start:
    * Ac tristique libero volutpat at
    + Facilisis in pretium nisl aliquet
    - Nulla volutpat aliquam velit
+ Very easy!

Unordered

  • Create a list by starting a line with +, -, or *
  • Sub-lists are made by indenting 2 spaces:
    • Marker character change forces new list start:
      • Ac tristique libero volutpat at
      • Facilisis in pretium nisl aliquet
      • Nulla volutpat aliquam velit
  • Very easy!

Ordered

1. Lorem ipsum dolor sit amet
2. Consectetur adipiscing elit
3. Integer molestie lorem at massa
  1. Lorem ipsum dolor sit amet

  2. Consectetur adipiscing elit

  3. Integer molestie lorem at massa

    1. You can use sequential numbers...
    2. ...or keep all the numbers as `1.
  4. You can use sequential numbers...

  5. ...or keep all the numbers as 1.

Start numbering with offset:

57. foo
1. bar
  1. foo
  2. bar

Code

Inline `code`

Inline code

    // Some comments
    line 1 of code
    line 2 of code
    line 3 of code

Indented code

// Some comments
line 1 of code
line 2 of code
line 3 of code

Block code "fences"

```
Sample text here...
```
Sample text here...

Tables

| Option | Description |
| ------ | ----------- |
| data   | path to data files to supply the data that will be passed into templates. |
| engine | engine to be used for processing templates. Handlebars is the default. |
| ext    | extension to be used for dest files. |
Option Description
data path to data files to supply the data that will be passed into templates.
engine engine to be used for processing templates. Handlebars is the default.
ext extension to be used for dest files.

Right aligned columns

| Option | Description |
| ------:| -----------:|
| data   | path to data files to supply the data that will be passed into templates. |
| engine | engine to be used for processing templates. Handlebars is the default. |
| ext    | extension to be used for dest files. |
Option Description
data path to data files to supply the data that will be passed into templates.
engine engine to be used for processing templates. Handlebars is the default.
ext extension to be used for dest files.

External Links

[link text](https://vote.lido.fi/)

[link with title](https://vote.lido.fi/ "title text!")

link text

link with title

Images (will be shown as links in vote UI)

![lido](https://vote.lido.fi/favicon-1080x1080.svg)
![lido](https://vote.lido.fi/favicon-1080x1080.svg "The LIDO VOTE")

lido lido

Like links, Images also have a footnote style syntax

![Alt text][id]

Alt text

With a reference later in the document defining the URL location:

[id]: https://vote.lido.fi/favicon-1080x1080.svg  "The LIOD"