From 80a525eba572a6c5bded69efb7f3e092f631d07a Mon Sep 17 00:00:00 2001 From: 2047 <2047@users.noreply.github.com> Date: Sun, 22 Jan 2017 23:09:27 +0800 Subject: [PATCH 1/3] Added ordered by site title. --- js/all.js | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/js/all.js b/js/all.js index 1cee1a1..eb77255 100644 --- a/js/all.js +++ b/js/all.js @@ -2301,9 +2301,9 @@ username_match = body.match(/^(([a-zA-Z0-9\.]+)@[a-zA-Z0-9\.]+|@(.*?)):/); if (username_match) { if (username_match[2]) { - username_formatted = username_match[2] + " › "; + username_formatted = username_match[2] + " 鈥?"; } else { - username_formatted = username_match[3] + " › "; + username_formatted = username_match[3] + " 鈥?"; } body = body.replace(/> \[(.*?)\].*/g, "$1: "); body = body.replace(/^[ ]*>.*/gm, ""); @@ -3051,6 +3051,13 @@ }; })(this)), orderby === "modified" ]); + this.menu_settings.items.push([ + "Order sites by site titles", ((function(_this) { + return function() { + return _this.handleOrderbyClick("title"); + }; + })(this)), orderby === "title" + ]); this.menu_settings.items.push([ "Order sites by add time", ((function(_this) { return function() { @@ -3824,6 +3831,10 @@ rows.sort(function(a, b) { return b.row.settings.modified - a.row.settings.modified; }); + } else if (Page.local_storage.sites_orderby === "title") { + rows.sort(function(b, a) { + return (b.row.content.title > a.row.content.title) - (a.row.content.title > b.row.content.title); + }); } else if (Page.local_storage.sites_orderby === "addtime") { rows.sort(function(a, b) { return (b.row.settings.added || 0) - (a.row.settings.added || 0); @@ -4237,4 +4248,4 @@ window.Page.createProjector(); -}).call(this); \ No newline at end of file +}).call(this); From 337cf57d5b4ee0b2247a486840aa96eec456c39d Mon Sep 17 00:00:00 2001 From: 2047 <2047@users.noreply.github.com> Date: Mon, 23 Jan 2017 08:26:00 +0800 Subject: [PATCH 2/3] Small fix --- js/all.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/js/all.js b/js/all.js index eb77255..be594ed 100644 --- a/js/all.js +++ b/js/all.js @@ -2301,9 +2301,9 @@ username_match = body.match(/^(([a-zA-Z0-9\.]+)@[a-zA-Z0-9\.]+|@(.*?)):/); if (username_match) { if (username_match[2]) { - username_formatted = username_match[2] + " 鈥?"; + username_formatted = username_match[2] + " > "; } else { - username_formatted = username_match[3] + " 鈥?"; + username_formatted = username_match[3] + " > "; } body = body.replace(/> \[(.*?)\].*/g, "$1: "); body = body.replace(/^[ ]*>.*/gm, ""); From 85bdf1766ffeded5189d3a8a4aa61b224c4fa73c Mon Sep 17 00:00:00 2001 From: 2047 <2047@users.noreply.github.com> Date: Mon, 23 Jan 2017 08:29:32 +0800 Subject: [PATCH 3/3] =?UTF-8?q?Small=20fix=20"=20=E2=80=BA=20"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- js/all.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/js/all.js b/js/all.js index be594ed..c715ab2 100644 --- a/js/all.js +++ b/js/all.js @@ -2301,9 +2301,9 @@ username_match = body.match(/^(([a-zA-Z0-9\.]+)@[a-zA-Z0-9\.]+|@(.*?)):/); if (username_match) { if (username_match[2]) { - username_formatted = username_match[2] + " > "; + username_formatted = username_match[2] + " › "; } else { - username_formatted = username_match[3] + " > "; + username_formatted = username_match[3] + " › "; } body = body.replace(/> \[(.*?)\].*/g, "$1: "); body = body.replace(/^[ ]*>.*/gm, "");