mirror of
https://github.com/sparksuite/simplemde-markdown-editor.git
synced 2024-05-22 07:36:43 +02:00
Fix README inaccuracy
This commit is contained in:
parent
94d02639f9
commit
5ba95f1ba6
25
README.md
25
README.md
|
@ -86,27 +86,28 @@ var simplemde = new SimpleMDE({
|
|||
|
||||
#### Toolbar icons
|
||||
|
||||
Below are the available toolbar icons, which can be reorganized however you like. "Name" is just the friendly name for reference purposes. "Action" is either a function or a URL to open. "Class" is the class given to the icon. "Tooltip" is the small tooltip that appears via the `title=""` attribute. The `Ctrl` and `Alt` in the title tags will be changed automatically to their Mac equivalents when needed. Additionally, you can add a separator between any icons by adding `"|"` to the toolbar array.
|
||||
Below are the available toolbar icons, which can be reorganized however you like. "Name" is the name of the icon, referenced in the JS. "Action" is either a function or a URL to open. "Class" is the class given to the icon. "Tooltip" is the small tooltip that appears via the `title=""` attribute. The `Ctrl` and `Alt` in the title tags will be changed automatically to their Mac equivalents when needed. Additionally, you can add a separator between any icons by adding `"|"` to the toolbar array.
|
||||
|
||||
Name | Action | Class | Tooltip
|
||||
---- | ------ | ----- | -----
|
||||
Bold | toggleBold | fa fa-bold | Bold (Ctrl+B)
|
||||
Italic | toggleItalic | fa fa-italic | Italic (Ctrl+I)
|
||||
Code | toggleCodeBlock | fa fa-code | Code (Ctrl+Alt+C)
|
||||
Blockquote | toggleBlockquote | fa fa-quote-left | Quote (Ctrl+')
|
||||
Unordered List | toggleUnorderedList | fa fa-list-ul | Generic List (Ctrl+L)
|
||||
Numbered List | toggleOrderedList | fa fa-list-ol | Numbered List (Ctrl+Alt+L)
|
||||
Link | drawLink | fa fa-link | Create Link (Ctrl+K)
|
||||
Image | drawImage | fa fa-picture-o | Insert Image (Ctrl+Alt+I)
|
||||
Horizontal Rule | drawHorizontalRule | fa fa-minus | Insert Horizontal Line
|
||||
Preview | togglePreview | fa fa-eye | Toggle Preview (Ctrl+P)
|
||||
Markdown Guide | [This link](http://nextstepwebs.github.io/simplemde-markdown-editor/markdown-guide) | fa fa-question-circle | Markdown Guide
|
||||
bold | toggleBold | fa fa-bold | Bold (Ctrl+B)
|
||||
italic | toggleItalic | fa fa-italic | Italic (Ctrl+I)
|
||||
code | toggleCodeBlock | fa fa-code | Code (Ctrl+Alt+C)
|
||||
quote | toggleBlockquote | fa fa-quote-left | Quote (Ctrl+')
|
||||
unordered-list | toggleUnorderedList | fa fa-list-ul | Generic List (Ctrl+L)
|
||||
numbered-list | toggleOrderedList | fa fa-list-ol | Numbered List (Ctrl+Alt+L)
|
||||
link | drawLink | fa fa-link | Create Link (Ctrl+K)
|
||||
image | drawImage | fa fa-picture-o | Insert Image (Ctrl+Alt+I)
|
||||
horizontal-rule | drawHorizontalRule | fa fa-minus | Insert Horizontal Line
|
||||
preview | togglePreview | fa fa-eye | Toggle Preview (Ctrl+P)
|
||||
guide | [This link](http://nextstepwebs.github.io/simplemde-markdown-editor/markdown-guide) | fa fa-question-circle | Markdown Guide
|
||||
|
||||
Customize the toolbar using the `toolbar` option like:
|
||||
|
||||
```JavaScript
|
||||
var simplemde = new SimpleMDE({
|
||||
toolbar: [{
|
||||
name: "bold",
|
||||
action: toggleBold,
|
||||
className: "fa fa-bold",
|
||||
title: "Bold (Ctrl+B)",
|
||||
|
|
Loading…
Reference in a new issue