Improve: font-size-change

This commit is contained in:
cutls
2020-05-15 12:47:01 +09:00
parent 917cd322fc
commit cf6e5b5dd5
14 changed files with 350 additions and 342 deletions

View File

@@ -51,7 +51,7 @@ function defaultEmoji(target) {
emojis +
`${def}
<span style="
width: 20px; height: 20px; display: inline-block; background-image: url('../../img/sheet.png'); background-size: 4900%;
width: 1.538rem; height: 1.538rem; display: inline-block; background-image: url('../../img/sheet.png'); background-size: 4900%;
background-position:${emoji['css']};"></span>
</a>`
})
@@ -95,7 +95,7 @@ function faicon() {
emojis +
'<a onclick="emojiInsert(\'[faicon]' +
eje +
'[/faicon]\')" class="pointer white-text" style="font-size:24px"><i class="fa ' +
'[/faicon]\')" class="pointer white-text" style="font-size:1.8rem"><i class="fa ' +
emoji +
'"></i></a>'
})

View File

@@ -430,7 +430,7 @@ function redraft(id, acct_id) {
$('#preview').append(
'<img src="' +
json.media_attachments[i].preview_url +
'" style="width:50px; max-height:100px;">'
'" style="width:3.8rem; max-height:7.7rem;">'
)
} else {
break

View File

@@ -186,7 +186,7 @@ function misskeyParse(obj, mix, acct_id, tlid, popup, mutefilter) {
noticeavatar = '<a onclick="udg(\'' + toot.user.id +
'\',' + acct_id + ');" user="' + toot.user.username + '" class="udg notf-icon">' +
'<img src="' + noticeavatar +
'" width="20" class="prof-img" user="' + toot.user.username +
'" class="prof-img prof-img-sml" user="' + toot.user.username +
'"></a>';
if (toot.type == "reply") {
var what = lang.lang_parse_mentioned;
@@ -773,7 +773,7 @@ function misskeyParse(obj, mix, acct_id, tlid, popup, mutefilter) {
'<div class="area-icon"><a onclick="udg(\'' + toot.user.id +
'\',' + acct_id + ');" user="' + toot.user.username + '" class="udg">' +
'<img src="' + avatar +
'" width="40" class="prof-img" user="' + toot.user.username +
'" class="prof-img" user="' + toot.user.username +
'" onerror="this.src=\'../../img/loading.svg\'"></a></div>' +
'<div class="area-display_name"><div class="flex-name"><span class="user">' +
dis_name +

View File

@@ -241,7 +241,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
noticeavatar = toot.account.avatar_static
}
noticeavatar = `<a onclick="udg('${toot.account.id}','${acct_id}');" user="${toot.account.acct}" class="udg">
<img draggable="false" src="${noticeavatar}" width="20" class="notf-icon prof-img" user="${toot.account.acct}" alt="">
<img draggable="false" src="${noticeavatar}" class="notf-icon prof-img prof-img-sml" user="${toot.account.acct}" alt="">
</a>`
if (toot.type == 'mention') {
var what = lang.lang_parse_mentioned
@@ -394,7 +394,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
noticeavatar = toot.account.avatar_static
}
noticeavatar = `<a onclick="udg('${toot.account.id}','${acct_id}');" user="${toot.account.acct}" class="notf-icon udg" aria-hidden="true">
<img draggable="false" src="${noticeavatar}" width="20" class="prof-img"
<img draggable="false" src="${noticeavatar}" class="prof-img prof-img-sml"
user="${toot.account.acct}" onerror="this.src=\'../../img/loading.svg\'">
</a>`
var rebtxt = lang.lang_parse_btedsimple
@@ -1286,20 +1286,19 @@ function userparse(obj, auth, acct_id, tlid, popup) {
}
var latest = date(toot.last_status_at, 'relative')
if (toot.last_status_at) {
var latesthtml = `<div class="cbadge" style="width:100px;">Last <span class="voice">toot</span>: ${latest}</div>`
var latesthtml = `<div class="cbadge" style="width:7.7rem;">Last <span class="voice">toot</span>: ${latest}</div>`
} else {
var latesthtml = ''
}
templete =
templete +
`<div class="cusr" style="padding-top:5px;" user-id="${toot.id}">
`<div class="cusr" style="padding-top:0.4rem;" user-id="${toot.id}">
<div class="area-notice">${notftext}</div>
<div class="area-icon">
${udg}
<img
draggable="false"
src="${avatar}"
width="40"
class="prof-img"
user="${toot.acct}"
onerror="this.src='../../img/loading.svg'"
@@ -1317,10 +1316,10 @@ function userparse(obj, auth, acct_id, tlid, popup) {
</div>
</div>
<div class="area-status">
<div class="cbadge" style="width:100px;">
<div class="cbadge" style="width:7.7rem;">
${lang.lang_status_follow}:${toot.following_count}
</div>
<div class="cbadge" style="width:100px;">
<div class="cbadge" style="width:7.7rem;">
${lang.lang_status_followers}:${toot.followers_count}
</div>
${latesthtml}

View File

@@ -133,7 +133,7 @@ function trendTag() {
</span> `
})
$('#taglist').append(
'<div class="trendtag">アイマストドントレンドタグ<i class="material-icons pointer" onclick="trendTag()" style="font-size:12px">refresh</i>:' +
'<div class="trendtag">アイマストドントレンドタグ<i class="material-icons pointer" onclick="trendTag()" style="font-size:0.9rem">refresh</i>:' +
tags +
'</div>'
)

View File

@@ -28,9 +28,7 @@ function parseColumn(target, dontclose) {
console.log('%c Parse column', 'color:red;font-size:125%')
var size = localStorage.getItem('size')
if (size) {
$('#timeline-container').css('font-size', size + 'px')
$('.toot-reset').css('font-size', size + 'px')
$('.cont-series').css('font-size', size + 'px')
$('html').css('font-size', size + 'px')
}
if (localStorage.getItem('menu-done')) {
$('#fukidashi').addClass('hide')
@@ -262,11 +260,11 @@ function parseColumn(target, dontclose) {
<i class="fas fa-tasks exc-icons"></i>
</span>
</label>
<button class="btn waves-effect" style="width:60px; padding:0;" onclick="exclude('${key}')">Filter</button>`
<button class="btn waves-effect" style="width:4.6rem; padding:0;" onclick="exclude('${key}')">Filter</button>`
if (checkNotfFilter(key)) {
exclude =
exclude +
`<button class="btn red waves-effect" style="width:60px; padding:0;" onclick="resetNotfFilter('${key}')">
`<button class="btn red waves-effect" style="width:4.6rem; padding:0;" onclick="resetNotfFilter('${key}')">
Clear all
</button>`
}
@@ -275,7 +273,7 @@ function parseColumn(target, dontclose) {
notfKey = 'dummy'
} else if (acct.type == 'home') {
var exclude = `<a onclick="ebtToggle('${key}')" class="setting nex">
<i class="fas fa-retweet waves-effect nex" title="${lang.lang_layout_excludingbt}" style="font-size:24px"></i>
<i class="fas fa-retweet waves-effect nex" title="${lang.lang_layout_excludingbt}" style="font-size:1.84rem"></i>
<span id="sta-bt-${key}">Off</span>
</a>
${lang.lang_layout_excludingbt}
@@ -292,7 +290,7 @@ function parseColumn(target, dontclose) {
var any = ''
var none = ''
}
if_tag = `<div class="column-hide notf-indv-box" id="tag-box_${key}" style="padding:5px;">
if_tag = `<div class="column-hide notf-indv-box" id="tag-box_${key}" style="padding:0.4rem;">
Base: ${name}<br>
<div id="tagManager-${key}">
all: <input type="text" id="all_tm-${key}"" value="${all}">
@@ -302,7 +300,7 @@ function parseColumn(target, dontclose) {
<button onclick="addTag('${key}')" class="btn waves-effect" style="width: 100%">Refresh</button>
</div>`
if_tag_btn = `<a onclick="setToggleTag('${key}')" class="setting nex"
title="${lang.lang_layout_tagManager}" style="width:30px">
title="${lang.lang_layout_tagManager}" style="width:2.4rem">
<i class="material-icons waves-effect nex">note_add</i>
</a>`
unread = ''
@@ -371,7 +369,7 @@ function parseColumn(target, dontclose) {
<div class="notice-box z-depth-2" id="menu_${key}" style="${insert}">
<div class="area-notice">
<i class="material-icons waves-effect ${isMisRed}" id="notice_icon_${key}" ${notf_attr}
style="font-size:40px; padding-top:25%;"
style="font-size:3rem; padding-top:25%;"
onclick="checkStr('${acct.type}','${data}','${acct.domain}', '${key}', '${delc}','${voice}',null)"
title="${lang.lang_layout_gotop}" aria-hidden="true">
</i>
@@ -417,7 +415,7 @@ function parseColumn(target, dontclose) {
<div id="notifications_${notfKey}" data-notf="${notfDomain}" data-type="notf" class="notf-timeline">
</div>
</div>
<div class="column-hide notf-indv-box" id="util-box_${key}" style="padding:5px;">
<div class="column-hide notf-indv-box" id="util-box_${key}" style="padding:0.4rem;">
${unread}
${exclude}${left_hold}
${mediaFil}<br>
@@ -779,7 +777,7 @@ function webviewParse(url, key, insert, icnsert, css) {
var html = `<div class="box" id="timeline_box_${key}_box" tlid="${key}" style="${css}">
<div class="notice-box z-depth-2" id="menu_${key}" style="${insert}">
<div class="area-notice">
<i class="fab fa-twitter waves-effect" id="notice_icon_${key}" style="font-size:40px; padding-top:25%;"></i>
<i class="fab fa-twitter waves-effect" id="notice_icon_${key}" style="font-size:3rem; padding-top:25%;"></i>
</div>
<div class="area-notice_name tl-title">WebView('${url}')</div>
<div class="area-sta"></div>
@@ -795,7 +793,7 @@ function webviewParse(url, key, insert, icnsert, css) {
</div>
</div>
<div class="column-hide notf-indv-box z-depth-4" id="notf-box_${key}"></div>
<div class="column-hide notf-indv-box" id="util-box_${key}" style="padding:5px;">
<div class="column-hide notf-indv-box" id="util-box_${key}" style="padding:0.4rem;">
${lang.lang_layout_headercolor}
<br>
<div id="picker_${key}" class="color-picker"></div>
@@ -833,7 +831,7 @@ function unstreamingTL(type, key, basekey, insert, icnsert, left_fold, css, anim
var html = `<div class="boxIn" id="timeline_box_${key}_box" tlid="${key}">
<div class="notice-box z-depth-2" id="menu_${key}" style="${insert} ">
<div class="area-notice">
<i class="material-icons waves-effect" id="notice_icon_${key}" style="font-size:40px; padding-top:25%;"
<i class="material-icons waves-effect" id="notice_icon_${key}" style="font-size:3rem; padding-top:25%;"
onclick="${type}('${key}','${dataHtml}');" title="${lang.lang_layout_gotop}"></i>
</div>
<div class="area-notice_name">
@@ -852,7 +850,7 @@ function unstreamingTL(type, key, basekey, insert, icnsert, left_fold, css, anim
</a>
</div>
</div>
<div class="column-hide notf-indv-box" id="util-box_${key}" style="padding:5px;">
<div class="column-hide notf-indv-box" id="util-box_${key}" style="padding:0.4rem;">
${left_hold}
<a onclick="mediaToggle('${key}')" class="setting nex">
<i class="material-icons waves-effect nex" title="${lang.lang_layout_mediafil}">perm_media</i>

View File

@@ -26,7 +26,7 @@ function tips(mode) {
if (mode == 'ver') {
tipsToggle()
$('#tips-text').html(
'<img src="../../img/desk.png" width="20" onclick="todo(\'TheDesk is a nice client!: TheDesk ' +
'<img src="../../img/desk.png" class="prof-img-sml" onclick="todo(\'TheDesk is a nice client!: TheDesk ' +
localStorage.getItem('ver') +
' git: ' +
gitHash +
@@ -34,7 +34,7 @@ function tips(mode) {
localStorage.getItem('ver') +
' {' +
gitHash.slice(0, 7) +
'} [<i class="material-icons" style="font-size:1.2rem;top: 3px;position: relative;">supervisor_account</i><span id="persons">1+</span>]'
'} [<i class="material-icons" style="font-size:1.2rem;top: 0.23rem;position: relative;">supervisor_account</i><span id="persons">1+</span>]'
)
localStorage.setItem('tips', 'ver')
} else if (mode == 'clock') {
@@ -117,7 +117,7 @@ function trendTagonTip() {
</span><br>`
})
$('#tips-text').html(
'<div class="trendtag">トレンドタグ<i class="material-icons pointer" onclick="trendTagonTip()" style="font-size:12px">refresh</i>:<br>' +
'<div class="trendtag">トレンドタグ<i class="material-icons pointer" onclick="trendTagonTip()" style="font-size:0.9rem">refresh</i>:<br>' +
tags +
'</div>'
)
@@ -193,8 +193,8 @@ function spotifytips() {
var html = `
<div id="spot-box">
<div id="spot-refresh">
<i class="material-icons pointer" onclick="spotifytips()" style="font-size:20px">refresh</i>
<i class="material-icons pointer" onclick="nowplaying('spotify');show()" style="font-size:20px">send</i>
<i class="material-icons pointer" onclick="spotifytips()" style="font-size:1.5rem">refresh</i>
<i class="material-icons pointer" onclick="nowplaying('spotify');show()" style="font-size:1.5rem">send</i>
</div>
<div id="spot-cover">
<img src="${img}" id="spot-img">
@@ -277,7 +277,7 @@ function clockStart() {
(nowTime.getMonth() + 1) +
'/' +
nowTime.getDate() +
'<span style="font-size:20px; font-family:Open Sans">' +
'<span style="font-size:1.5rem; font-family:Open Sans">' +
nowHour +
':' +
nowMin +

View File

@@ -709,7 +709,7 @@ function udAdd(acct_id, id, start) {
.then(function(json) {
var fields = json;
for (var i = 0; i < fields.length; i++) {
var html = '<a href="' + fields[i].proof_url + '" target="_blank" class="cbadge teal waves-effect" style="max-width:200px;" title="' + lang.lang_hisdata_key.replace("{{set}}", escapeHTML(fields[i].provider)) + '"><i class="fas fa-key" aria-hidden="true"></i>' + escapeHTML(fields[i].provider) + ":" + escapeHTML(fields[i].provider_username) + "</a>";
var html = '<a href="' + fields[i].proof_url + '" target="_blank" class="cbadge teal waves-effect" style="max-width:15.4rem;" title="' + lang.lang_hisdata_key.replace("{{set}}", escapeHTML(fields[i].provider)) + '"><i class="fas fa-key" aria-hidden="true"></i>' + escapeHTML(fields[i].provider) + ":" + escapeHTML(fields[i].provider_username) + "</a>";
$("#his-proof-prof").append(html);
}
});
@@ -734,7 +734,7 @@ function udAdd(acct_id, id, start) {
})
.then(function(json) {
if (json.user.public_view) {
var html = '<a href="' + json.user.url + '" target="_blank" class="cbadge purple waves-effect" style="max-width:200px;" title="Notestock">Notestock</a>';
var html = '<a href="' + json.user.url + '" target="_blank" class="cbadge purple waves-effect" style="max-width:15.4rem;" title="Notestock">Notestock</a>';
$("#his-proof-prof").append(html);
}
});