Unread misc
This commit is contained in:
parent
c86a99df06
commit
e04b64a326
|
@ -41,6 +41,7 @@ The default sounds of notifications is provided [Creative Commons BY](https://cr
|
||||||
|
|
||||||
* 日本語(Japanese)
|
* 日本語(Japanese)
|
||||||
* English
|
* English
|
||||||
|
* de, cs, bg(from Crowdin)
|
||||||
|
|
||||||
### Translation
|
### Translation
|
||||||
|
|
||||||
|
|
|
@ -40,6 +40,7 @@ Download:[TheDesk](https://thedesk.top) [![check](https://status.cutls.com/badge
|
||||||
|
|
||||||
* 日本語
|
* 日本語
|
||||||
* English(英語)
|
* English(英語)
|
||||||
|
* ドイツ語, チェコ語, ブルガリア語(from Crowdin)
|
||||||
|
|
||||||
### 翻訳
|
### 翻訳
|
||||||
|
|
||||||
|
@ -72,7 +73,7 @@ Linuxビルダー
|
||||||
|
|
||||||
* [ぽぷんじゃ](https://popon.pptdn.jp/@popn_ja)
|
* [ぽぷんじゃ](https://popon.pptdn.jp/@popn_ja)
|
||||||
|
|
||||||
iTunes NowPlayingにアルバムアートワークを付けてくれた人
|
コーダー
|
||||||
|
|
||||||
* [kPherox](https://pl.kpherox.dev/kPherox)
|
* [kPherox](https://pl.kpherox.dev/kPherox)
|
||||||
|
|
||||||
|
|
|
@ -191,6 +191,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||||
var times = [];
|
var times = [];
|
||||||
Object.keys(obj).forEach(function (key) {
|
Object.keys(obj).forEach(function (key) {
|
||||||
var toot = obj[key];
|
var toot = obj[key];
|
||||||
|
|
||||||
if (type == "dm") {
|
if (type == "dm") {
|
||||||
var dmid = toot.id;
|
var dmid = toot.id;
|
||||||
toot = toot.last_status;
|
toot = toot.last_status;
|
||||||
|
@ -425,6 +426,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (toot.content) {
|
||||||
var id = toot.id;
|
var id = toot.id;
|
||||||
if (mix == "home") {
|
if (mix == "home") {
|
||||||
var home = ""
|
var home = ""
|
||||||
|
@ -473,8 +475,13 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||||
var spoiler_show = '<a href="#" onclick="cw_show(\'' + toot.id +
|
var spoiler_show = '<a href="#" onclick="cw_show(\'' + toot.id +
|
||||||
'\')" class="nex parsed cw_btn">' + lang.lang_parse_cwshow + '</a><br>';
|
'\')" class="nex parsed cw_btn">' + lang.lang_parse_cwshow + '</a><br>';
|
||||||
} else {
|
} else {
|
||||||
|
if (toot.content) {
|
||||||
var ct1 = toot.content.split('</p>').length + toot.content.split('<br />').length - 2;
|
var ct1 = toot.content.split('</p>').length + toot.content.split('<br />').length - 2;
|
||||||
var ct2 = toot.content.split('</p>').length + toot.content.split('<br>').length - 2;
|
var ct2 = toot.content.split('</p>').length + toot.content.split('<br>').length - 2;
|
||||||
|
} else {
|
||||||
|
var ct1 = 100;
|
||||||
|
var ct2 = 100;
|
||||||
|
}
|
||||||
if (ct1 > ct2) { var ct = ct1; } else { var ct = ct2; }
|
if (ct1 > ct2) { var ct = ct1; } else { var ct = ct2; }
|
||||||
if ((sent < ct && $.mb_strlen($.strip_tags(toot.content)) > 5) || ($.strip_tags(toot.content).length > ltr && $.mb_strlen($.strip_tags(toot.content)) > 5)) {
|
if ((sent < ct && $.mb_strlen($.strip_tags(toot.content)) > 5) || ($.strip_tags(toot.content).length > ltr && $.mb_strlen($.strip_tags(toot.content)) > 5)) {
|
||||||
var content = '<span class="gray">' + lang.lang_parse_fulltext + '</span><br>' + toot.content
|
var content = '<span class="gray">' + lang.lang_parse_fulltext + '</span><br>' + toot.content
|
||||||
|
@ -917,6 +924,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||||
',\'' + tlid + '\',\'normal\')" class="waves-effect waves-dark btn-flat details ' + dmHide + '" style="padding:0"><i class="text-darken-3 material-icons">more_vert</i></a></div>' +
|
',\'' + tlid + '\',\'normal\')" class="waves-effect waves-dark btn-flat details ' + dmHide + '" style="padding:0"><i class="text-darken-3 material-icons">more_vert</i></a></div>' +
|
||||||
'</div></div>' +
|
'</div></div>' +
|
||||||
'</div></div>';
|
'</div></div>';
|
||||||
|
}
|
||||||
});
|
});
|
||||||
if (mix == "mix") {
|
if (mix == "mix") {
|
||||||
return [templete, local, times]
|
return [templete, local, times]
|
||||||
|
|
|
@ -919,7 +919,6 @@ function getMarker(tlid, type, acct_id) {
|
||||||
}
|
}
|
||||||
function showUnread(tlid, type, acct_id) {
|
function showUnread(tlid, type, acct_id) {
|
||||||
if ($("#unread_" + tlid + " .material-icons").hasClass("teal-text")) {
|
if ($("#unread_" + tlid + " .material-icons").hasClass("teal-text")) {
|
||||||
$("#unread_" + tlid + " .material-icons").removeClass("teal-text")
|
|
||||||
goTop(tlid)
|
goTop(tlid)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -945,7 +944,7 @@ function showUnread(tlid, type, acct_id) {
|
||||||
todo(error);
|
todo(error);
|
||||||
console.error(error);
|
console.error(error);
|
||||||
}).then(function (json) {
|
}).then(function (json) {
|
||||||
if (!json) {
|
if (!json || !json.length) {
|
||||||
columnReload(tlid, type)
|
columnReload(tlid, type)
|
||||||
}
|
}
|
||||||
if (localStorage.getItem("filter_" + acct_id) != "undefined") {
|
if (localStorage.getItem("filter_" + acct_id) != "undefined") {
|
||||||
|
@ -953,11 +952,13 @@ function showUnread(tlid, type, acct_id) {
|
||||||
} else {
|
} else {
|
||||||
var mute = [];
|
var mute = [];
|
||||||
}
|
}
|
||||||
var templete = parse(json, '', acct_id, tlid, "", mute, type);
|
var templete = parse(json, type, acct_id, tlid, "", mute, type);
|
||||||
var len = json.length - 1
|
var len = json.length - 1
|
||||||
$("#timeline_" + tlid).html(templete);
|
$("#timeline_" + tlid).html(templete);
|
||||||
|
if ($("#timeline_" + tlid + " .cvo:eq(" + len + ")").length) {
|
||||||
var to = $("#timeline_" + tlid + " .cvo:eq(" + len + ")").offset().top
|
var to = $("#timeline_" + tlid + " .cvo:eq(" + len + ")").offset().top
|
||||||
$("#timeline_box_" + tlid + "_box .tl-box").scrollTop(to)
|
$("#timeline_box_" + tlid + "_box .tl-box").scrollTop(to)
|
||||||
|
}
|
||||||
additional(acct_id, tlid);
|
additional(acct_id, tlid);
|
||||||
jQuery("time.timeago").timeago();
|
jQuery("time.timeago").timeago();
|
||||||
todc();
|
todc();
|
||||||
|
@ -1005,8 +1006,10 @@ function ueload(tlid) {
|
||||||
var templete = parse(json, '', acct_id, tlid, "", mute, type);
|
var templete = parse(json, '', acct_id, tlid, "", mute, type);
|
||||||
var len = json.length - 1
|
var len = json.length - 1
|
||||||
$("#timeline_" + tlid).prepend(templete);
|
$("#timeline_" + tlid).prepend(templete);
|
||||||
|
if ($("#timeline_" + tlid + " .cvo:eq(" + len + ")").length) {
|
||||||
var to = $("#timeline_" + tlid + " .cvo:eq(" + len + ")").offset().top
|
var to = $("#timeline_" + tlid + " .cvo:eq(" + len + ")").offset().top
|
||||||
$("#timeline_box_" + tlid + "_box .tl-box").scrollTop(to)
|
$("#timeline_box_" + tlid + "_box .tl-box").scrollTop(to)
|
||||||
|
}
|
||||||
additional(acct_id, tlid);
|
additional(acct_id, tlid);
|
||||||
jQuery("time.timeago").timeago();
|
jQuery("time.timeago").timeago();
|
||||||
todc();
|
todc();
|
||||||
|
|
|
@ -212,6 +212,15 @@ function parseColumn(target, dontclose) {
|
||||||
var exclude = "";
|
var exclude = "";
|
||||||
unread = ""
|
unread = ""
|
||||||
}
|
}
|
||||||
|
var markers = localStorage.getItem("markers");
|
||||||
|
if (markers == "no") {
|
||||||
|
markers = false;
|
||||||
|
} else {
|
||||||
|
markers = true
|
||||||
|
}
|
||||||
|
if (!markers) {
|
||||||
|
unread = ""
|
||||||
|
}
|
||||||
if (!acct.left_fold) {
|
if (!acct.left_fold) {
|
||||||
basekey = key;
|
basekey = key;
|
||||||
if (!numtarget) {
|
if (!numtarget) {
|
||||||
|
|
|
@ -41,6 +41,11 @@ function scrollck() {
|
||||||
function goTop(id) {
|
function goTop(id) {
|
||||||
if ($("#unread_" + id + " .material-icons").hasClass("teal-text")) {
|
if ($("#unread_" + id + " .material-icons").hasClass("teal-text")) {
|
||||||
$("#unread_" + id + " .material-icons").removeClass("teal-text")
|
$("#unread_" + id + " .material-icons").removeClass("teal-text")
|
||||||
|
var multi = localStorage.getItem("column")
|
||||||
|
var obj = JSON.parse(multi)
|
||||||
|
var acct_id = obj[id * 1].domain
|
||||||
|
var type = obj[id * 1].type
|
||||||
|
console.log(id, type)
|
||||||
columnReload(id, type)
|
columnReload(id, type)
|
||||||
}
|
}
|
||||||
if ($("#timeline_box_" + id + "_box .tl-box").scrollTop() > 500) {
|
if ($("#timeline_box_" + id + "_box .tl-box").scrollTop() > 500) {
|
||||||
|
|
|
@ -87,6 +87,8 @@
|
||||||
"ticker": "Enable #InstanceTicker",
|
"ticker": "Enable #InstanceTicker",
|
||||||
"tickerwarn": "Show colorful stickers about the server. <a href=\"https://cdn.weep.me/mastodon/\">About #InstanceTicker</a> Copyright 2018 weepjp, kyori19.",
|
"tickerwarn": "Show colorful stickers about the server. <a href=\"https://cdn.weep.me/mastodon/\">About #InstanceTicker</a> Copyright 2018 weepjp, kyori19.",
|
||||||
"animation": "Анимация на времевата линия",
|
"animation": "Анимация на времевата линия",
|
||||||
|
"markers": "Markers(mark as read) on HTL and notifications",
|
||||||
|
"markerswarn": "Mastodon 3.0~. Shared on WebUI and third-party supported clients.",
|
||||||
"replySound": "Звук (Отговор)",
|
"replySound": "Звук (Отговор)",
|
||||||
"favSound": "Звук(Фаворит)",
|
"favSound": "Звук(Фаворит)",
|
||||||
"btSound": "Звук(Подсилване)",
|
"btSound": "Звук(Подсилване)",
|
||||||
|
|
|
@ -87,6 +87,8 @@
|
||||||
"ticker": "Enable #InstanceTicker",
|
"ticker": "Enable #InstanceTicker",
|
||||||
"tickerwarn": "Show colorful stickers about the server. <a href=\"https://cdn.weep.me/mastodon/\">About #InstanceTicker</a> Copyright 2018 weepjp, kyori19.",
|
"tickerwarn": "Show colorful stickers about the server. <a href=\"https://cdn.weep.me/mastodon/\">About #InstanceTicker</a> Copyright 2018 weepjp, kyori19.",
|
||||||
"animation": "Animation of timelines",
|
"animation": "Animation of timelines",
|
||||||
|
"markers": "Markers(mark as read) on HTL and notifications",
|
||||||
|
"markerswarn": "Mastodon 3.0~. Shared on WebUI and third-party supported clients.",
|
||||||
"replySound": "Sound(Reply)",
|
"replySound": "Sound(Reply)",
|
||||||
"favSound": "Sound(Fav)",
|
"favSound": "Sound(Fav)",
|
||||||
"btSound": "Sound(Boost)",
|
"btSound": "Sound(Boost)",
|
||||||
|
|
|
@ -87,6 +87,8 @@
|
||||||
"ticker": "Aktiviere #InstanceTicker",
|
"ticker": "Aktiviere #InstanceTicker",
|
||||||
"tickerwarn": "Zeigt bunte Sticker über den Server. <a href=\"https://wee.jp/\">Über #InstanceTicker</a> Copyright 2018 weepjp, kyori19.",
|
"tickerwarn": "Zeigt bunte Sticker über den Server. <a href=\"https://wee.jp/\">Über #InstanceTicker</a> Copyright 2018 weepjp, kyori19.",
|
||||||
"animation": "Animation der Verläufe",
|
"animation": "Animation der Verläufe",
|
||||||
|
"markers": "Markers(mark as read) on HTL and notifications",
|
||||||
|
"markerswarn": "Mastodon 3.0~. Shared on WebUI and third-party supported clients.",
|
||||||
"replySound": "Ton bei Antwort",
|
"replySound": "Ton bei Antwort",
|
||||||
"favSound": "Ton bei Favorit",
|
"favSound": "Ton bei Favorit",
|
||||||
"btSound": "Ton bei Verstärkung",
|
"btSound": "Ton bei Verstärkung",
|
||||||
|
|
|
@ -87,6 +87,8 @@
|
||||||
"ticker": "Enable #InstanceTicker",
|
"ticker": "Enable #InstanceTicker",
|
||||||
"tickerwarn": "Show colorful stickers about the server. <a href=\"https://wee.jp/\">About #InstanceTicker</a> Copyright 2018 weepjp, kyori19.",
|
"tickerwarn": "Show colorful stickers about the server. <a href=\"https://wee.jp/\">About #InstanceTicker</a> Copyright 2018 weepjp, kyori19.",
|
||||||
"animation": "Animation of timelines",
|
"animation": "Animation of timelines",
|
||||||
|
"markers": "Markers(mark as read) on HTL and notifications",
|
||||||
|
"markerswarn": "Mastodon 3.0~. Shared on WebUI and third-party supported clients.",
|
||||||
"replySound": "Sound(Reply)",
|
"replySound": "Sound(Reply)",
|
||||||
"favSound": "Sound(Fav)",
|
"favSound": "Sound(Fav)",
|
||||||
"btSound": "Sound(Boost)",
|
"btSound": "Sound(Boost)",
|
||||||
|
|
|
@ -87,6 +87,8 @@
|
||||||
"ticker": "#InstanceTickerを使う",
|
"ticker": "#InstanceTickerを使う",
|
||||||
"tickerwarn": "トゥートした人の所属サーバーをわかりやすく彩ります(自サーバー以外のトゥート向け)。<a href=\"https://https://wee.jp/\">#InstanceTickerについて</a> Copyright 2018 weepjp, kyori19.",
|
"tickerwarn": "トゥートした人の所属サーバーをわかりやすく彩ります(自サーバー以外のトゥート向け)。<a href=\"https://https://wee.jp/\">#InstanceTickerについて</a> Copyright 2018 weepjp, kyori19.",
|
||||||
"animation": "タイムラインのアニメーション",
|
"animation": "タイムラインのアニメーション",
|
||||||
|
"markers": "ホームと通知の未読管理",
|
||||||
|
"markerswarn": "Mastodon 3.0相当以上。WebUIと対応クライアントで共有されます。",
|
||||||
"replySound": "リプライの通知音",
|
"replySound": "リプライの通知音",
|
||||||
"favSound": "お気に入り登録の通知音",
|
"favSound": "お気に入り登録の通知音",
|
||||||
"btSound": "ブーストの通知音",
|
"btSound": "ブーストの通知音",
|
||||||
|
|
|
@ -307,6 +307,16 @@ var tlConstruction = [
|
||||||
desc: "",
|
desc: "",
|
||||||
checkbox: yesno
|
checkbox: yesno
|
||||||
}
|
}
|
||||||
|
}, {
|
||||||
|
id: "markers",
|
||||||
|
storage: "markers",
|
||||||
|
checkbox: true,
|
||||||
|
setValue: "yes",
|
||||||
|
text: {
|
||||||
|
head: "@@markers@@",
|
||||||
|
desc: "@@markerswarn@@",
|
||||||
|
checkbox: yesno
|
||||||
|
}
|
||||||
}, {
|
}, {
|
||||||
id: "replySound",
|
id: "replySound",
|
||||||
storage: "replySound",
|
storage: "replySound",
|
||||||
|
|
Loading…
Reference in New Issue
Block a user