glutanimate / mini-format-pack

Extends Anki 2.1 with a number of additional text formatting buttons
https://ankiweb.net/shared/info/295889520
Other
49 stars 13 forks source link

About the code block button #6

Closed Juddd closed 3 years ago

Juddd commented 5 years ago

The current button of Insert code block will build a tag <pre> without any attribute. The old Power Format Pack can build a such tag like <pre class="myCodeClass">text</pre> This very convenient to composing...

And the current code block button just can generate a block code. Hope an inline code block to add, please... The old Power Format Pack will generate <code class="myCodeClass">text</code>.

Please help, I can pay you for these two functions

glutanimate commented 3 years ago

Hey @Juddd,

Thanks again for the suggestions! Both of these sound perfectly reasonable. The code button is available now with the merge of #13. As for adding customizable classes to the generated HTML elements: I think that's a neat idea, but it's not something I have time to work on for now. However, I've created a separate issue to track the progress on that and marked it as help-wanted: https://github.com/glutanimate/mini-format-pack/issues/24

If anyone stumbles on this and thinks this would be a cool thing to work on: Please feel free to jump in!

(Closing this issue for now in favor of #24)