SimpleMDE Markdown Editor for Kirby

Disabling the green highlighting is not possible right now, but I will add an issue and try to add this functionality. I might be able to optimize the visuals though — why exactly do you want to disable it?

I want to completely move away from modals for this rewrite. That’s why the page button is not yet implemented. I have a local proof-of-concept displaying the page list inside the toolbar. Keep an eye on this issue: https://github.com/medienbaecker/kirby-simplemde/issues/2

For me, it would be too distracting from the content to have highlighting within the text.

I definitely will :slightly_smiling_face:

Nice! :slight_smile: I hope you will continue with this field to future versions of Kirby as well.

@texnixe I added an option to disable the Kirbytag highlighting:
c::set('simplemde.kirbytagHighlighting', false);

@jenstornell Thank you! I hesitated at first because of Kirby 3 — maybe this field will not even be needed anymore. But I thought it would be a great project for my first Kirby 3 plugin. It’s very straight forward and not as bloated as the Enhanced Textarea.

1 Like

Wonderful! You are fantastic!

I have now implemented a completely different page link functionality and released version 1.1:

pagelink

5 Likes

Very cool :sunglasses: (and some more chars)

1 Like

This is amazing! No more reason to feel wary of using kirby builder for text-heavy blocks!

(though I’m sure Kirby 3 will implement a kirby-builder system built-in :stuck_out_tongue: )

Thank you

1 Like

@thguenther

how would you go to implement a custom button?

I need to add one for the code syntax (by using inline code like `text`).

Should I extend editor.js?

Thanks!

@afincato I just added a code button in the editor.js and released version 1.3.8.

As there is already a code function in SimpleMDE it was very easy. But adding more buttons is quite straight forward too. Just have a look at the existing button functions.

Great thank you.

Therefore, editor.js is the file to work with whenever you want to extend the plugin with custom buttons? Cool. Will look at simplemd’s readme as well.

When you use this plugin on a textarea with validate: minLength/maxLength the counter does not count up/down any more …

@raschid I just added the live validation script and released version 1.3.11.
Please let me know if this works for you.

@thguenther tried it on 2.5.5 and validator-count works on normal textarea and on textarea in a modal (structure).

Validator maxLength works as expected. Thanks!

And the Problem I hat this morning (klick) disappeared!

@thguenther
issues in simpleMDE

SimpleMDE seems to not find the translation.json files because the path set is wrong.

http://website/panel/plugins/simplemde/translation.json

I am not using any custom routing.

Happening only to me?

It works for me.
If it can’t find the translation.json on your installation, it probably won’t find the index.json for the page link search either.

Can you access the files directly?

The panel routes are defined in line 16 and line 33 of the simplemde.php and a data-json attribute with the url is added to the field.
Maybe there’s a better way of adding panel routes? I couldn’t find anything in the documentation about that.

Yes, I cannot use the search page inline toolbar as well.

How can I go about to debug it? I installed it with kirby cli.

Is there an known issue between this (awesome) plugin and the latest version (2.10) of Kirby? I have it running on several sites with version 2.8 without any issues, but just installed it on a site with 2.10, and it doesn’t seem to work at all - ie., none of the editor buttons show up…

Is anyone else experiencing this?

Never mind, sorted my own problem: browser caching… (Doh!!!)