Improve: sorting
This commit is contained in:
parent
15f428528b
commit
4fa7d07500
|
@ -91,7 +91,7 @@ input.addEventListener("focus", function () {
|
|||
var his = tag.history;
|
||||
var uses = his[0].uses * 1 + his[1].uses * 1 + his[2].uses * 1 + his[3].uses * 1 + his[4].uses * 1 + his[5].uses * 1 + his[6].uses * 1;
|
||||
tagHTML = '<br><a onclick="tagInsert(\'#' + escapeHTML(tag.name) + '\',\'#' + q + '\')" class="pointer">#' +
|
||||
escapeHTML(tag.name) + '</a> ' + uses + 'toots'
|
||||
escapeHTML(tag.name) + '</a> ' + uses + 'toot(s)'
|
||||
var item = {
|
||||
"uses": uses,
|
||||
"html": tagHTML
|
||||
|
@ -108,8 +108,13 @@ input.addEventListener("focus", function () {
|
|||
return 0;
|
||||
});
|
||||
var ins = ""
|
||||
var nev = false
|
||||
Object.keys(tags).forEach(function (key7) {
|
||||
ins = ins + tags[key7].html
|
||||
if (key7 <= 0 && !nev) {
|
||||
ins = ins + '<br>'
|
||||
nev = true
|
||||
}
|
||||
});
|
||||
$("#suggest").html(ins);
|
||||
$("#right-side").show()
|
||||
|
|
|
@ -177,12 +177,12 @@ function graphDraw(tag, acct_id) {
|
|||
var zero = 50 - (his[0].uses / max * 50);
|
||||
if (max === 0) {
|
||||
tags = '<br><br><svg version="1.1" viewbox="0 0 60 50" width="60" height="50">' +
|
||||
'</svg><span style="font-size:200%">' + his[0].uses + '</span>toots <a onclick="tl(\'tag\',\'' + escapeHTML(tag.name) + '\',\'' + acct_id +
|
||||
'</svg><span style="font-size:200%">' + his[0].uses + '</span>toot(s) <a onclick="tl(\'tag\',\'' + escapeHTML(tag.name) + '\',\'' + acct_id +
|
||||
'\',\'add\')" class="pointer">#' + escapeHTML(tag.name) + '</a> ' + his[0].accounts + lang.lang_src_people;
|
||||
} else {
|
||||
tags = '<br><br><svg version="1.1" viewbox="0 0 60 50" width="60" height="50">' +
|
||||
'<g><path d="M0,' + six + ' L10,' + five + ' 20,' + four + ' 30,' + three + ' 40,' + two + ' 50,' + one + ' 60,' + zero + '" style="stroke: #9e9e9e; stroke-width: 1;fill: none;"></path></g>' +
|
||||
'</svg><span style="font-size:200%">' + his[0].uses + '</span>toots <a onclick="tl(\'tag\',\'' + escapeHTML(tag.name) + '\',\'' + acct_id +
|
||||
'</svg><span style="font-size:200%">' + his[0].uses + '</span>toot <a onclick="tl(\'tag\',\'' + escapeHTML(tag.name) + '\',\'' + acct_id +
|
||||
'\',\'add\')" class="pointer">#' + escapeHTML(tag.name) + '</a> ' + his[0].accounts + lang.lang_src_people;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user