immanuelfodor / shaarli-markdown-toolbar

Shaarli plugin to easily insert markdown syntax into the Description field when editing a link
https://github.com/shaarli/Shaarli
MIT License
17 stars 0 forks source link
editor-plugin editorconfig javascript markdown markdown-editor php plugin shaarli shaarli-markdown-toolbar shaarli-plugins

Shaarli Markdown Toolbar Plugin

Shaarli plugin to easily insert markdown syntax into the Description field when editing a link.

Tested on Shaarli 0.11.1 with the Shaarli-Material and the built-in default themes using desktop and Android Chrome browsers. Should be compatible with Shaarli 0.12.0-beta as well which introduced a major internal rewrite (#1511).

Features

Screenshots

Plugin Administration page

After plugin enabled with default MD_TOOLBAR_LOCALE settings:

Shaarli Markdown Toolbar admin settings

Edit Link page

After plugin enabled and the Shaarli Descriptor Plugin's DESCRIPTION_ROWS parameter is set to 12 to have more vertical space in the editor area:

Shaarli Markdown Toolbar edit link page

Fullscreen mode

Distraction-free writing can be enabled by clicking on the fullscreen button while editing a link:

Shaarli Markdown Toolbar distraction-free writing

Usage

Installation

The plugin's folder (markdown_toolbar) should be placed in the <shaarli>/plugins/ directory.

The directory structure should look like:

└── plugins
    └── markdown_toolbar
        ├── includes/...
        ├── markdown_toolbar.html
        ├── markdown_toolbar.meta
        └── markdown_toolbar.php

To enable the plugin, just check it in the Plugin Administration page (?do=pluginadmin).

You can also add markdown_toolbar to your list of enabled plugins in data/config.json.php.\ The general.enabled_plugins list should look like then:

"general": {
  "enabled_plugins": [
    "markdown_toolbar",
    [...]
  ],
}

Configuration

Go to the Plugin Administration page, and edit the following settings (with the plugin enabled):

Note: this setting can also be set in data/config.json.php, in the plugins section:

"general": {
    "plugins": {
        "MD_TOOLBAR_LOCALE": "ja",
        [...]
    },
}

Known issues

If you fix an issue from the list or some newly discovered one, please open a pull request here.

Credits

This project would not come to life without:

Contact

Immánuel Fodor\ fodor.it | Linkedin