Skip to content

Commit

Permalink
Merge pull request #5845 from WoltLab/auto-completion-smiley
Browse files Browse the repository at this point in the history
Auto completion smiley
  • Loading branch information
Cyperghost authored Apr 12, 2024
2 parents 73b1f71 + ee86c24 commit c29e603
Show file tree
Hide file tree
Showing 6 changed files with 257 additions and 217 deletions.
10 changes: 9 additions & 1 deletion com.woltlab.wcf/templates/shared_wysiwyg.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,14 @@
label: '{jslang}wcf.editor.button.media{/jslang}',
});
}
const smileys = [
{foreach from=$__wcf->getSmileyCache()->getEmojis() key=__code item=__smiley}
{
code: '{@$__code|encodeJS}',
html: '{@$__smiley->getHtml()|encodeJS}',
},
{/foreach}
];
const codeBlockLanguages = [
{ language: "", label: '{jslang}wcf.editor.code.highlighter.detect{/jslang}' },
Expand All @@ -106,6 +114,6 @@
{/foreach}
];
void setupCkeditor(element, features, bbcodes, codeBlockLanguages, '{@$__wcf->getBBCodeHandler()->getCkeditorLicenseKey()|encodeJS}');
void setupCkeditor(element, features, bbcodes, smileys, codeBlockLanguages, '{@$__wcf->getBBCodeHandler()->getCkeditorLicenseKey()|encodeJS}');
});
</script>
Loading

0 comments on commit c29e603

Please sign in to comment.