Yu-Gi-Oh! Deck Building and Card Inventory Management web interface written in Common Lisp, utilizing HTMX.
No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.

41 líneas
1.9KB

  1. <script src="/js/tinymce/tinymce.min.js" referrerpolicy="origin"></script>
  2. <script>
  3. function tinymce_init(element, id) {
  4. tinymce.remove(element);
  5. tinymce.init({
  6. selector: element + '#' + id,
  7. auto_focus: id,
  8. highlight_on_focus: true,
  9. skin: '{{ skin | default:'oxide' }}',
  10. content_css: '{{ css | default:'dark' }}',
  11. min_height: {{ min_height | default:500 }},
  12. plugins: 'accordion lists advlist anchor autolink autoresize autosave ' +
  13. 'charmap code codesample directionality emoticons fullscreen ' +
  14. 'help image insertdatetime link media nonbreaking ' +
  15. 'pagebreak preview quickbars save searchreplace table template ' +
  16. 'visualblocks visualchars wordcount',
  17. toolbar1: 'bold italic underline strikethrough | alignleft aligncenter alignright alignjustify alignnone | styles | emoticons',
  18. toolbar2: 'cut copy paste pastetext | bullist numlist | outdent indent | redo undo blockquote | link unlink openlink anchor image',
  19. toolbar3: 'table | hr removeformat visualblocks | subscript superscript | charmap media insertdatetime | visualchars nonbreaking pagebreak fullscreen | searchreplace | help code',
  20. end_container_on_empty_block: true,
  21. promotion: false,
  22. style_formats_autohide: true,
  23. style_formats_merge: true
  24. });
  25. }
  26. document.addEventListener("DOMContentLoaded", function(event) {
  27. // If you want to make the editor accept Markdown or Org mode:
  28. // https://www.tiny.cloud/docs/tinymce/6/content-behavior-options/#text_patterns
  29. // you can add text_patterns:
  30. tinymce_init('{{ element }}', '{{ id }}');
  31. });
  32. /* https://stackoverflow.com/a/74274127 */
  33. document.addEventListener('htmx:afterRequest', function(evt) {
  34. tinymce_init('{{ element }}', '{{ id }}');
  35. });
  36. </script>