Editor.md编辑器新增Unicode表情符号
Before Width: | Height: | Size: 5.7 KiB |
Before Width: | Height: | Size: 6.0 KiB |
Before Width: | Height: | Size: 7.4 KiB |
Before Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 7.8 KiB |
Before Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 2.0 KiB |
Before Width: | Height: | Size: 2.6 KiB |
Before Width: | Height: | Size: 3.0 KiB |
Before Width: | Height: | Size: 3.3 KiB |
Before Width: | Height: | Size: 3.6 KiB |
Before Width: | Height: | Size: 4.7 KiB |
@ -19,19 +19,6 @@
|
||||
var emojiData = [];
|
||||
var selecteds = [];
|
||||
|
||||
var logoPrefix = "editormd-logo";
|
||||
var logos = [
|
||||
logoPrefix,
|
||||
logoPrefix + "-1x",
|
||||
logoPrefix + "-2x",
|
||||
logoPrefix + "-3x",
|
||||
logoPrefix + "-4x",
|
||||
logoPrefix + "-5x",
|
||||
logoPrefix + "-6x",
|
||||
logoPrefix + "-7x",
|
||||
logoPrefix + "-8x"
|
||||
];
|
||||
|
||||
var langs = {
|
||||
"zh-cn" : {
|
||||
toolbar : {
|
||||
@ -139,7 +126,7 @@
|
||||
});
|
||||
}
|
||||
|
||||
var category = ["Github emoji", "Twemoji", "Font awesome", "Editor.md logo"];
|
||||
var category = ["Github emoji", "Twemoji", "Font awesome", "Unicode emoji"];
|
||||
var tab = dialog.find("." + classPrefix + "tab");
|
||||
|
||||
if (tab.html() === "")
|
||||
@ -169,7 +156,7 @@
|
||||
}
|
||||
|
||||
var tabBoxs = tab.find("." + classPrefix + "tab-box");
|
||||
var emojiCategories = ["github-emoji", "twemoji", "font-awesome", logoPrefix];
|
||||
var emojiCategories = ["github-emoji", "twemoji", "font-awesome", "unicode-emoji"];
|
||||
|
||||
var drawTable = function() {
|
||||
var cname = emojiCategories[emojiTabIndex];
|
||||
@ -219,11 +206,10 @@
|
||||
icon = "<i class=\"fa fa-" + emoji + " fa-emoji\" title=\"" + emoji + "\"></i>";
|
||||
row += "<a href=\"javascript:;\" value=\":fa-" + emoji + ":\" title=\":fa-" + emoji + ":\" class=\"" + classPrefix + "emoji-btn\">" + icon + "</a>";
|
||||
}
|
||||
else if (type === "editormd-logo")
|
||||
{
|
||||
icon = "<i class=\"" + emoji + "\" title=\"Editor.md logo (" + emoji + ")\"></i>";
|
||||
row += "<a href=\"javascript:;\" value=\":" + emoji + ":\" title=\":" + emoji + ":\" style=\"width:20%;\" class=\"" + classPrefix + "emoji-btn\">" + icon + "</a>";
|
||||
}
|
||||
else if(type === 'unicode-emoji'){
|
||||
icon = unescape(emoji)
|
||||
row += "<a href=\"javascript:;\" value=\"" + emoji + "\" style=\"width:5%;\" class=\"" + classPrefix + "emoji-btn\">" + icon + "</a>";
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -278,7 +264,6 @@
|
||||
}
|
||||
|
||||
emojiData = json;
|
||||
emojiData[logoPrefix] = logos;
|
||||
drawTable();
|
||||
});
|
||||
}
|
||||
|