From 21b72f78546fe8fde457be780c57c5bed6fdb40a Mon Sep 17 00:00:00 2001 From: syuilo Date: Thu, 9 Feb 2017 19:41:17 +0900 Subject: #139 --- src/web/app/base.styl | 23 +++++++++++++++++++++++ src/web/app/common/scripts/text-compiler.js | 2 +- 2 files changed, 24 insertions(+), 1 deletion(-) (limited to 'src/web') diff --git a/src/web/app/base.styl b/src/web/app/base.styl index 5eab205480..4082fa24ca 100644 --- a/src/web/app/base.styl +++ b/src/web/app/base.styl @@ -107,6 +107,29 @@ a * cursor pointer +pre > code + .comment + opacity 0.5 + + .string + color #e96900 + + .keyword + color #2973b7 + + &.true + &.false + &.null + &.nil + &.undefined + color #ae81ff + + .symbol + color #42b983 + + .number + color #ae81ff + mk-locker display block position fixed diff --git a/src/web/app/common/scripts/text-compiler.js b/src/web/app/common/scripts/text-compiler.js index ab322764f3..29b700e628 100644 --- a/src/web/app/common/scripts/text-compiler.js +++ b/src/web/app/common/scripts/text-compiler.js @@ -31,7 +31,7 @@ module.exports = function(tokens, shouldBreak, shouldEscape) { case 'hashtag': // TODO return '' + escape(token.content) + ''; case 'code': - return '
' + escape(token.code) + '
'; + return '
' + token.codeHtml + '
'; } }).join(''); -- cgit v1.2.3-freya