From 1d843c8ac257d512a96cf054ab24e6a3c2f34e26 Mon Sep 17 00:00:00 2001 From: Wu Cheng-Han Date: Fri, 3 Jul 2015 09:14:49 +0800 Subject: Added random color option in blockquote tag --- public/js/index.js | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'public/js') diff --git a/public/js/index.js b/public/js/index.js index 5f7e6992..4d617adb 100644 --- a/public/js/index.js +++ b/public/js/index.js @@ -118,11 +118,21 @@ var supportBlockquoteTags = [ }, }, { - text: '[color tag]', + text: '[my color tag]', search: '[]', command: function () { return '[color=' + personalInfo.color + ']'; } + }, + { + text: '[random color tag]', + search: '[]', + command: function () { + var color = randomColor({ + luminosity: 'light' + }); + return '[color=' + color + ']'; + } } ]; var modeType = { -- cgit v1.2.3