summaryrefslogtreecommitdiffstats
path: root/public/js/gogs.js
diff options
context:
space:
mode:
authorFlorian Kaiser <florian.kaiser@fnkr.net>2016-02-01 22:48:04 +0000
committerFlorian Kaiser <florian.kaiser@fnkr.net>2016-02-01 22:50:22 +0000
commit0d41827f23c04678f1ff7db236d5150cc8ee539d (patch)
tree6a18168cee26a7046616e3008818c66439c9c032 /public/js/gogs.js
parent32efc3ec0ae7228daca6bb5cec8c1e0be068ab43 (diff)
downloadgitea-0d41827f23c04678f1ff7db236d5150cc8ee539d.tar.gz
gitea-0d41827f23c04678f1ff7db236d5150cc8ee539d.zip
Fix syntax highlighting for markdown code blocks on issue description/comment save
Diffstat (limited to 'public/js/gogs.js')
-rw-r--r--public/js/gogs.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/public/js/gogs.js b/public/js/gogs.js
index 71f4859c3c..3459658585 100644
--- a/public/js/gogs.js
+++ b/public/js/gogs.js
@@ -385,6 +385,9 @@ function initRepository() {
} else {
$render_content.html(data.content);
emojify.run($render_content[0]);
+ $('pre code', $render_content[0]).each(function(i, block) {
+ hljs.highlightBlock(block);
+ });
}
});
});