johannschopplich / kirby-highlighter

🌐 Server-side syntax highlighting for the code block & KirbyText
https://kirbyseo.com
MIT License
20 stars 4 forks source link

Add support for code blocks #10

Closed MaluNoPeleke closed 3 years ago

MaluNoPeleke commented 3 years ago

Is it possible to activate it for code blocks as well?

johannschopplich commented 3 years ago

Great idea! Done: https://github.com/johannschopplich/kirby-highlighter/releases/tag/v2.0.0

MaluNoPeleke commented 3 years ago

Wow, that was super quick, thanks a lot!

johannschopplich commented 3 years ago

You're welcome! I had some spare time coincidentally. 😉 Feel welcome to give feedback if something doesn't work.

MaluNoPeleke commented 3 years ago

I just tested it and it works flawlessly as excpected. 👍 Is there an option to copy the whole code block to the clipboard?

johannschopplich commented 3 years ago

Glad to hear.

That you will have to implement yourself, as it's much more dependent on the architecture/styling of your website.

johannschopplich commented 3 years ago

@MaluNoPeleke Just thought of you, when I found: https://github.com/github/clipboard-copy-element

Pretty simple and maybe interesting to you!

MaluNoPeleke commented 3 years ago

Thanks a lot

MaluNoPeleke commented 3 years ago

Now I only need to find out how to inject it correctly ;)