#445 hidable some tools and show badge if it has a thread on detail of toot
This commit is contained in:
parent
7f79f1773d
commit
f80b8d031e
|
@ -5,6 +5,12 @@ function details(id, acct_id, tlid, mode) {
|
|||
} else {
|
||||
$('.dm-hide').show()
|
||||
}
|
||||
const context = localStorage.getItem('moreContext')
|
||||
if(context != 'yes') {
|
||||
$('.contextTool').hide()
|
||||
} else {
|
||||
$('.contextTool').show()
|
||||
}
|
||||
$('.toot-reset').html('<span class="no-data">' + lang.lang_details_nodata + '</span>')
|
||||
var html = $('#timeline_' + tlid + ' [toot-id=' + id + ']').html()
|
||||
$('#toot-this').html(html)
|
||||
|
@ -222,6 +228,10 @@ function getContext(id, acct_id) {
|
|||
var templete = parse(json.descendants, '', acct_id, '', '', mute)
|
||||
if (templete != '') {
|
||||
$('#toot-after .no-data').hide()
|
||||
$('#toot-after-new').removeClass('hide')
|
||||
} else {
|
||||
$('#toot-after-new').addClass('hide')
|
||||
$('#toot-after').html('<span class="no-data">' + lang.lang_details_nodata + '</span>')
|
||||
}
|
||||
$('#toot-after').html(templete)
|
||||
$('#toot-after .hide').html(lang.lang_details_filtered)
|
||||
|
@ -230,6 +240,9 @@ function getContext(id, acct_id) {
|
|||
var templete = parse(json.ancestors, '', acct_id, '', '', mute)
|
||||
if (templete != '') {
|
||||
$('#toot-reply .no-data').hide()
|
||||
$('#toot-reply-new').removeClass('hide')
|
||||
} else {
|
||||
$('#toot-reply-new').addClass('hide')
|
||||
}
|
||||
$('#toot-reply').prepend(templete)
|
||||
$('#toot-reply .hide').html(lang.lang_details_filtered)
|
||||
|
|
|
@ -390,25 +390,26 @@
|
|||
<div id="tootmodal" class="modal modal-fixed-footer">
|
||||
<div class="modal-content">
|
||||
<ul class="collapsible" id="det-col">
|
||||
<li class="dm-hide">
|
||||
<li class="dm-hide contextTool">
|
||||
<div class="collapsible-header">
|
||||
<i class="material-icons">people_outline</i>@@afterLTL@@
|
||||
</div>
|
||||
<div class="collapsible-body toot-reset" id="ltl-after"></div>
|
||||
</li>
|
||||
<li class="dm-hide">
|
||||
<li class="dm-hide contextTool">
|
||||
<div class="collapsible-header">
|
||||
<i class="material-icons">person_outline</i>@@afterUTL@@
|
||||
</div>
|
||||
<div class="collapsible-body toot-reset" id="user-after"></div>
|
||||
</li>
|
||||
<li class="dm-hide">
|
||||
<li class="dm-hide contextTool">
|
||||
<div class="collapsible-header"><i class="material-icons">language</i>@@afterFTL@@</div>
|
||||
<div class="collapsible-body toot-reset" id="ftl-after"></div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="collapsible-header">
|
||||
<i class="material-icons">arrow_upward</i>@@contextBefore@@
|
||||
<i class="material-icons red-text hide" id="toot-reply-new">new_releases</i>
|
||||
</div>
|
||||
<div class="collapsible-body toot-reset" id="toot-reply"></div>
|
||||
</li>
|
||||
|
@ -423,16 +424,17 @@
|
|||
<li>
|
||||
<div class="collapsible-header">
|
||||
<i class="material-icons">arrow_downward</i>@@contextAfter@@
|
||||
<i class="material-icons red-text hide" id="toot-after-new">new_releases</i>
|
||||
</div>
|
||||
<div class="collapsible-body toot-reset" id="toot-after"></div>
|
||||
</li>
|
||||
<li class="dm-hide">
|
||||
<li class="dm-hide contextTool">
|
||||
<div class="collapsible-header">
|
||||
<i class="material-icons">people_outline</i>@@beforeLTL@@
|
||||
</div>
|
||||
<div class="collapsible-body toot-reset" id="toot-before"></div>
|
||||
</li>
|
||||
<li class="dm-hide">
|
||||
<li class="dm-hide contextTool">
|
||||
<div class="collapsible-header">
|
||||
<i class="material-icons">person_outline</i>@@beforeUTL@@
|
||||
</div>
|
||||
|
|
|
@ -114,6 +114,8 @@
|
|||
"markerswarn": "Mastodon 3.0~. Shared on WebUI and third-party supported clients.",
|
||||
"remote_img": "Get images from the remote server",
|
||||
"remote_imgWarn": "All previews are got from your loginned cache server.",
|
||||
"moreContextMode": "Context Tool",
|
||||
"moreContextModeWarn": "On detail of the toot modal, show toots before / after the toot on LTL, FTL, UTL",
|
||||
"replySound": "Sound(Reply)",
|
||||
"favSound": "Sound(Fav)",
|
||||
"btSound": "Sound(Boost)",
|
||||
|
|
|
@ -113,6 +113,8 @@
|
|||
"markerswarn": "Mastodon 3.0相当以上。WebUIと対応クライアントで共有するやつや。",
|
||||
"remote_img": "画像をリモートから取得",
|
||||
"remote_imgWarn": "プレビューはログインサーバーのキャッシュからどちらにしろ取得する。ビューワーのみに適用されるで。",
|
||||
"moreContextMode": "コンテキストツール",
|
||||
"moreContextModeWarn": "トゥート詳細の、トゥート前後のトゥートを表示する機能",
|
||||
"replySound": "リプライの通知音",
|
||||
"favSound": "お気に入り登録の通知音",
|
||||
"btSound": "ブーストの通知音",
|
||||
|
|
|
@ -146,6 +146,8 @@
|
|||
"thin": "細い",
|
||||
"normal": "普通",
|
||||
"thick": "太い",
|
||||
"moreContextMode": "コンテキストツール",
|
||||
"moreContextModeWarn": "トゥート詳細の、トゥート前後のトゥートを表示する機能",
|
||||
"main": "投稿後や起動時のアカウント",
|
||||
"mainwarn": "メインアカウントはアカウント設定で指定できます。投稿以外のアカウント選択にも影響します。",
|
||||
"lastacct": "最後に使用したアカウント",
|
||||
|
|
|
@ -453,6 +453,17 @@ var tlConstruction = [
|
|||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
id: 'mcm',
|
||||
storage: 'moreContext',
|
||||
checkbox: true,
|
||||
setValue: 'no',
|
||||
text: {
|
||||
head: '@@moreContextMode@@',
|
||||
desc: '@@moreContextModeWarn@@',
|
||||
checkbox: yesno
|
||||
}
|
||||
},
|
||||
{
|
||||
id: 'replySound',
|
||||
storage: 'replySound',
|
||||
|
|
Loading…
Reference in New Issue
Block a user