Compare commits
9 Commits
v21.1.0
...
rewrite-ov
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8eadb8287d | ||
|
|
541ebbbb19 | ||
|
|
d92a9ae1ae | ||
|
|
47749dde7b | ||
|
|
78a8c2bdce | ||
|
|
2c54e43e37 | ||
|
|
fba3b99b54 | ||
|
|
489d95f23f | ||
|
|
5d01dafeb3 |
2
.github/FUNDING.yml
vendored
2
.github/FUNDING.yml
vendored
@@ -5,4 +5,4 @@ patreon: cutls
|
||||
open_collective: # Replace with a single Open Collective username
|
||||
ko_fi: # Replace with a single Ko-fi username
|
||||
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
|
||||
custom: https://cutls.fanbox.cc
|
||||
custom: https://www.pixiv.net/fanbox/creator/28105985
|
||||
|
||||
15
README.md
15
README.md
@@ -1,3 +1,18 @@
|
||||
# rewrite-overallブランチへようこそ🎃
|
||||
|
||||
このブランチはコードを最初から全部読み直して書き直そうという途方もなく壮大なプロジェクトです。
|
||||
|
||||
1周目では、
|
||||
|
||||
* 脱jQuery
|
||||
* 脱onclick
|
||||
* 脱コールバック地獄
|
||||
* 重複してるやつや使ってないやつを消す
|
||||
|
||||
という極めて当たり前のやつをやっていきます。
|
||||
|
||||
# 以下いつものREADME
|
||||
|
||||
<img src="https://thedesk.top/img/top.png" width="300" align="left">
|
||||
<img src="https://thedesk.top/img/desk.png" width="150" align="right">
|
||||
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
js/common/blurhash.js
|
||||
js/common/hammer.min.js
|
||||
js/common/sha256.js
|
||||
js/platform/punycode.js
|
||||
js/platform/tj-deck.js
|
||||
@@ -1,14 +0,0 @@
|
||||
{
|
||||
"extends": "eslint:recommended",
|
||||
"env": {"browser": true},
|
||||
"rules": {
|
||||
"no-console": "off",
|
||||
"semi": ["error", "never"]
|
||||
},
|
||||
"globals": {
|
||||
"$": false,
|
||||
"ver": true,
|
||||
"pwa": true,
|
||||
"lang": true
|
||||
}
|
||||
}
|
||||
@@ -21,15 +21,6 @@ html {
|
||||
align-items: flex-start;
|
||||
}
|
||||
|
||||
#acct-list .btn-flat.white-text {
|
||||
color: inherit !important;
|
||||
}
|
||||
|
||||
#acct-list .btn-flat.red-text {
|
||||
background-color: white !important;
|
||||
}
|
||||
|
||||
|
||||
.lts {
|
||||
font-size: 150%;
|
||||
}
|
||||
|
||||
@@ -231,7 +231,6 @@ blockquote:before,
|
||||
width: 100vw;
|
||||
height: calc(100vh - 3rem);
|
||||
background-color: var(--bg);
|
||||
filter: brightness(50%);
|
||||
color: var(--color);
|
||||
z-index: 99999;
|
||||
justify-content: center;
|
||||
@@ -341,7 +340,7 @@ blockquote:before,
|
||||
}
|
||||
#menu {
|
||||
position: fixed;
|
||||
z-index: 999;
|
||||
z-index: 9999;
|
||||
background-color: var(--postbox);
|
||||
width: 540px;
|
||||
top: calc(50% - 150px);
|
||||
@@ -378,9 +377,6 @@ blockquote:before,
|
||||
#left-menu a.active {
|
||||
background-color: var(--emphasized);
|
||||
}
|
||||
#left-menu a.active span {
|
||||
text-decoration: underline;
|
||||
}
|
||||
#right-menu {
|
||||
width: 100%;
|
||||
overflow-y: scroll;
|
||||
@@ -609,7 +605,4 @@ textarea {
|
||||
.linux .win,
|
||||
.darwin .win {
|
||||
display: none;
|
||||
}
|
||||
.dropdown-content.header:hover {
|
||||
background-color: white;
|
||||
}
|
||||
@@ -157,8 +157,7 @@ iframe,
|
||||
}
|
||||
.box {
|
||||
overflow: hidden;
|
||||
min-width: 300px;
|
||||
max-width: 600px;
|
||||
min-width: 23rem;
|
||||
flex: 1;
|
||||
border-top: none;
|
||||
display: flex;
|
||||
@@ -218,14 +217,10 @@ iframe,
|
||||
.emoji,
|
||||
.emoji-img {
|
||||
width: 1.153rem;
|
||||
height: 1.153rem;
|
||||
object-fit: cover;
|
||||
}
|
||||
.area-toot .emoji,
|
||||
.area-toot .emoji-img {
|
||||
width: 1.538rem;
|
||||
height: 1.538rem;
|
||||
object-fit: cover;
|
||||
vertical-align: middle;
|
||||
margin: -1px 0;
|
||||
}
|
||||
@@ -243,7 +238,6 @@ iframe,
|
||||
flex: 1;
|
||||
overflow-y: scroll;
|
||||
overflow-x: hidden;
|
||||
background-color: var(--bg);
|
||||
}
|
||||
.additional {
|
||||
overflow-x: scroll;
|
||||
|
||||
@@ -87,7 +87,6 @@
|
||||
overflow-y: scroll;
|
||||
overflow-x: hidden;
|
||||
height: calc(100% - 3.4rem);
|
||||
padding-bottom: 60px;
|
||||
}
|
||||
#my-data-nav .btn {
|
||||
width: 10.7rem;
|
||||
@@ -143,9 +142,6 @@
|
||||
#hisdropdown{
|
||||
background-color: var(--bg);
|
||||
}
|
||||
#hisdropdown li a {
|
||||
color: white;
|
||||
}
|
||||
#hisdropdown li:hover{
|
||||
background-color: var(--active);
|
||||
}
|
||||
@@ -1,69 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||
<svg width="100%" height="100%" viewBox="0 0 600 600" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2;">
|
||||
<g id="輝き" transform="matrix(0.892356,0,0,0.892356,36.941,-15.9516)">
|
||||
<g transform="matrix(2.39479,0,0,2.21494,-178.97,-182.183)">
|
||||
<ellipse cx="123.217" cy="151.049" rx="36.923" ry="35.804" style="fill:rgb(84,82,81);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,8.39159,-32.1678)">
|
||||
<ellipse cx="120.479" cy="305.524" rx="112.5" ry="52" style="fill:rgb(84,82,81);"/>
|
||||
</g>
|
||||
<g transform="matrix(0.952046,-0.305955,0.305955,0.952046,-139.881,8.62199)">
|
||||
<ellipse cx="134.479" cy="430.524" rx="46.5" ry="84" style="fill:rgb(84,82,81);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,2.39158,-65.1678)">
|
||||
<ellipse cx="130.479" cy="561.024" rx="72.5" ry="74.5" style="fill:rgb(84,82,81);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,8.39159,-32.1678)">
|
||||
<ellipse cx="156.979" cy="651.76" rx="68" ry="60.235" style="fill:rgb(84,82,81);"/>
|
||||
</g>
|
||||
<g transform="matrix(0.954888,0.296965,-0.296965,0.954888,55.6063,-54.2336)">
|
||||
<ellipse cx="199.479" cy="158.995" rx="98.5" ry="51" style="fill:rgb(240,132,46);"/>
|
||||
</g>
|
||||
<g transform="matrix(0.931851,0.362841,-0.362841,0.931851,63.1962,-89.0819)">
|
||||
<ellipse cx="344.979" cy="135.857" rx="74" ry="90.137" style="fill:rgb(240,132,46);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,-56.6084,-45.1678)">
|
||||
<ellipse cx="493.479" cy="301.22" rx="126.5" ry="55.5" style="fill:rgb(240,132,46);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,-14.6084,-70.1678)">
|
||||
<ellipse cx="531.479" cy="368.22" rx="58.5" ry="54.5" style="fill:rgb(240,132,46);"/>
|
||||
</g>
|
||||
<g transform="matrix(0.973706,-0.227807,0.227807,0.973706,-124.722,44.48)">
|
||||
<ellipse cx="265.479" cy="614.97" rx="98.5" ry="37.5" style="fill:rgb(54,76,159);"/>
|
||||
</g>
|
||||
<g transform="matrix(0.982834,-0.184492,0.184492,0.982834,-148.417,-31.379)">
|
||||
<ellipse cx="407.479" cy="676.47" rx="71.5" ry="96" style="fill:rgb(54,76,159);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,-34.6084,-22.1678)">
|
||||
<ellipse cx="468.979" cy="511.47" rx="48" ry="31" style="fill:rgb(54,76,159);"/>
|
||||
</g>
|
||||
<g transform="matrix(0.880625,0.473815,-0.473815,0.880625,260.236,-235.714)">
|
||||
<ellipse cx="533.979" cy="472.97" rx="46" ry="99.5" style="fill:rgb(54,76,159);"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,9.39159,-36.1678)">
|
||||
<circle cx="69.229" cy="310.72" r="24.25" style="fill:white;"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,8.39159,-48.1678)">
|
||||
<circle cx="98.229" cy="417.72" r="25.25" style="fill:white;"/>
|
||||
</g>
|
||||
<g transform="matrix(0.76,0,0,0.76,96.9465,101.545)">
|
||||
<circle cx="375.229" cy="646.72" r="56.25" style="fill:white;"/>
|
||||
</g>
|
||||
<g transform="matrix(1,0,0,1,8.39159,-32.1678)">
|
||||
<circle cx="427.729" cy="287.22" r="32.75" style="fill:white;"/>
|
||||
</g>
|
||||
<g id="cat" transform="matrix(0.0249784,0,0,0.0249784,346.146,563.341)">
|
||||
<path d="M1592.47,2584L2048.94,2584C2048.94,2519.11 2044.31,2506.24 1936.84,2506.24C1954.01,2454.74 2023.79,2330.13 2062.57,2330.13C2096.88,2330.13 2137.81,2332.02 2137.81,2410.3C2137.81,2499.17 2287.37,2642.46 2323.63,2584C2377.67,2496.88 2230.72,2523.45 2230.72,2313.35C2230.72,2025.92 2398.46,2066.84 2398.46,1905.36C2398.46,1824.57 2376.14,1813.66 2376.14,1755.9C2376.14,1679.56 2443.39,1683.99 2430.31,1620.7C2421.27,1576.98 2414.2,1541.92 2408.93,1489.05C2405.19,1451.54 2404,1411.55 2365.03,1413.16C2319.25,1415.05 2301.88,1495.63 2230.72,1501.41C2159.7,1507.18 2099.15,1440.95 2071.66,1450.41C2044.41,1459.79 2052.98,1533.73 2069.14,1586.24C2094.54,1668.78 2149.93,1776.1 2048.94,1792.26C1947.95,1808.42 1774.25,1824.58 1649.02,1990.2C1523.79,2155.82 1528.42,2350.19 1479.36,2410.31C1314.72,2612.08 1146,2529.23 1146,2697.11C1146,2772.27 1273.35,2826.38 1293.55,2802.14C1313.75,2777.9 1121.93,2705.68 1336.56,2620.36C1519.91,2547.46 1536.28,2532.58 1592.47,2584Z" style="fill:rgb(5,127,254);"/>
|
||||
</g>
|
||||
<g id="cat1" serif:id="cat" transform="matrix(-0.0249784,0,0,0.0249784,147.519,318.341)">
|
||||
<path d="M1592.47,2584L2048.94,2584C2048.94,2519.11 2044.31,2506.24 1936.84,2506.24C1954.01,2454.74 2023.79,2330.13 2062.57,2330.13C2096.88,2330.13 2137.81,2332.02 2137.81,2410.3C2137.81,2499.17 2287.37,2642.46 2323.63,2584C2377.67,2496.88 2230.72,2523.45 2230.72,2313.35C2230.72,2025.92 2398.46,2066.84 2398.46,1905.36C2398.46,1824.57 2376.14,1813.66 2376.14,1755.9C2376.14,1679.56 2443.39,1683.99 2430.31,1620.7C2421.27,1576.98 2414.2,1541.92 2408.93,1489.05C2405.19,1451.54 2404,1411.55 2365.03,1413.16C2319.25,1415.05 2301.88,1495.63 2230.72,1501.41C2159.7,1507.18 2099.15,1440.95 2071.66,1450.41C2044.41,1459.79 2052.98,1533.73 2069.14,1586.24C2094.54,1668.78 2149.93,1776.1 2048.94,1792.26C1947.95,1808.42 1774.25,1824.58 1649.02,1990.2C1523.79,2155.82 1528.42,2350.19 1479.36,2410.31C1314.72,2612.08 1146,2529.23 1146,2697.11C1146,2772.27 1273.35,2826.38 1293.55,2802.14C1313.75,2777.9 1121.93,2705.68 1336.56,2620.36C1519.91,2547.46 1536.28,2532.58 1592.47,2584Z" style="fill:rgb(5,127,254);"/>
|
||||
</g>
|
||||
<g id="cat2" serif:id="cat" transform="matrix(-0.0249784,0,0,0.0249784,120.519,222.341)">
|
||||
<path d="M1592.47,2584L2048.94,2584C2048.94,2519.11 2044.31,2506.24 1936.84,2506.24C1954.01,2454.74 2023.79,2330.13 2062.57,2330.13C2096.88,2330.13 2137.81,2332.02 2137.81,2410.3C2137.81,2499.17 2287.37,2642.46 2323.63,2584C2377.67,2496.88 2230.72,2523.45 2230.72,2313.35C2230.72,2025.92 2398.46,2066.84 2398.46,1905.36C2398.46,1824.57 2376.14,1813.66 2376.14,1755.9C2376.14,1679.56 2443.39,1683.99 2430.31,1620.7C2421.27,1576.98 2414.2,1541.92 2408.93,1489.05C2405.19,1451.54 2404,1411.55 2365.03,1413.16C2319.25,1415.05 2301.88,1495.63 2230.72,1501.41C2159.7,1507.18 2099.15,1440.95 2071.66,1450.41C2044.41,1459.79 2052.98,1533.73 2069.14,1586.24C2094.54,1668.78 2149.93,1776.1 2048.94,1792.26C1947.95,1808.42 1774.25,1824.58 1649.02,1990.2C1523.79,2155.82 1528.42,2350.19 1479.36,2410.31C1314.72,2612.08 1146,2529.23 1146,2697.11C1146,2772.27 1273.35,2826.38 1293.55,2802.14C1313.75,2777.9 1121.93,2705.68 1336.56,2620.36C1519.91,2547.46 1536.28,2532.58 1592.47,2584Z" style="fill:rgb(5,127,254);"/>
|
||||
</g>
|
||||
<g id="cat3" serif:id="cat" transform="matrix(0.0249784,0,0,0.0249784,390.146,196.341)">
|
||||
<path d="M1592.47,2584L2048.94,2584C2048.94,2519.11 2044.31,2506.24 1936.84,2506.24C1954.01,2454.74 2023.79,2330.13 2062.57,2330.13C2096.88,2330.13 2137.81,2332.02 2137.81,2410.3C2137.81,2499.17 2287.37,2642.46 2323.63,2584C2377.67,2496.88 2230.72,2523.45 2230.72,2313.35C2230.72,2025.92 2398.46,2066.84 2398.46,1905.36C2398.46,1824.57 2376.14,1813.66 2376.14,1755.9C2376.14,1679.56 2443.39,1683.99 2430.31,1620.7C2421.27,1576.98 2414.2,1541.92 2408.93,1489.05C2405.19,1451.54 2404,1411.55 2365.03,1413.16C2319.25,1415.05 2301.88,1495.63 2230.72,1501.41C2159.7,1507.18 2099.15,1440.95 2071.66,1450.41C2044.41,1459.79 2052.98,1533.73 2069.14,1586.24C2094.54,1668.78 2149.93,1776.1 2048.94,1792.26C1947.95,1808.42 1774.25,1824.58 1649.02,1990.2C1523.79,2155.82 1528.42,2350.19 1479.36,2410.31C1314.72,2612.08 1146,2529.23 1146,2697.11C1146,2772.27 1273.35,2826.38 1293.55,2802.14C1313.75,2777.9 1121.93,2705.68 1336.56,2620.36C1519.91,2547.46 1536.28,2532.58 1592.47,2584Z" style="fill:rgb(5,127,254);"/>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 7.8 KiB |
@@ -1,5 +1,5 @@
|
||||
//@ts-check
|
||||
//このソフトについて
|
||||
function about() {
|
||||
postMessage(["sendSinmpleIpc", "about"], "*")
|
||||
}
|
||||
}
|
||||
document.getElementById('onClickAbout').addEventListener('click', about)
|
||||
38
app/js/common/api.js
Normal file
38
app/js/common/api.js
Normal file
@@ -0,0 +1,38 @@
|
||||
async function getApi(start, at) {
|
||||
let json = {}
|
||||
let response = null
|
||||
response = await fetch(start, {
|
||||
method: 'GET',
|
||||
headers: {
|
||||
'content-type': 'application/json',
|
||||
'Authorization': `Bearer ${at}`
|
||||
}
|
||||
})
|
||||
if (!response.ok) {
|
||||
response.text().then(function (text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
}
|
||||
json = await response.json()
|
||||
return json
|
||||
}
|
||||
async function postApi(url, body, at, ideKey) {
|
||||
let json = {}
|
||||
let response = null
|
||||
response = await fetch(url, {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'content-type': 'application/json',
|
||||
'Authorization': `Bearer ${at}`,
|
||||
'Idempotency-Key': ideKey
|
||||
},
|
||||
body: JSON.stringify(body)
|
||||
})
|
||||
if (!response.ok) {
|
||||
response.text().then(function (text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
}
|
||||
json = await response.json()
|
||||
return json
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
var digitCharacters = [
|
||||
const digitCharacters = [
|
||||
"0", "1", "2", "3", "4", "5", "6", "7", "8", "9",
|
||||
"A", "B", "C", "D", "E", "F", "G", "H", "I", "J",
|
||||
"K", "L", "M", "N", "O", "P", "Q", "R", "S", "T",
|
||||
@@ -10,16 +10,16 @@ var digitCharacters = [
|
||||
"|", "}", "~",
|
||||
];
|
||||
function decode83(str) {
|
||||
var value = 0;
|
||||
for (var i = 0; i < str.length; i++) {
|
||||
var c = str[i];
|
||||
var digit = digitCharacters.indexOf(c);
|
||||
let value = 0;
|
||||
for (let i = 0; i < str.length; i++) {
|
||||
const c = str[i];
|
||||
const digit = digitCharacters.indexOf(c);
|
||||
value = value * 83 + digit;
|
||||
}
|
||||
return value;
|
||||
}
|
||||
function linearTosRGB(value) {
|
||||
var v = Math.max(0, Math.min(1, value));
|
||||
const v = Math.max(0, Math.min(1, value));
|
||||
if (v <= 0.0031308) {
|
||||
return Math.round(v * 12.92 * 255 + 0.5);
|
||||
}
|
||||
@@ -28,7 +28,7 @@ function linearTosRGB(value) {
|
||||
}
|
||||
}
|
||||
function sRGBToLinear(value) {
|
||||
var v = value / 255;
|
||||
const v = value / 255;
|
||||
if (v <= 0.04045) {
|
||||
return v / 12.92;
|
||||
}
|
||||
@@ -37,18 +37,18 @@ function sRGBToLinear(value) {
|
||||
}
|
||||
}
|
||||
function decodeDC(value) {
|
||||
var intR = value >> 16;
|
||||
var intG = (value >> 8) & 255;
|
||||
var intB = value & 255;
|
||||
const intR = value >> 16;
|
||||
const intG = (value >> 8) & 255;
|
||||
const intB = value & 255;
|
||||
return [sRGBToLinear(intR), sRGBToLinear(intG), sRGBToLinear(intB)];
|
||||
};
|
||||
function sign(n) { return (n < 0 ? -1 : 1); }
|
||||
function signPow(val, exp) { return sign(val) * Math.pow(Math.abs(val), exp); }
|
||||
function decodeDC2(value, maximumValue) {
|
||||
var quantR = Math.floor(value / (19 * 19));
|
||||
var quantG = Math.floor(value / 19) % 19;
|
||||
var quantB = value % 19;
|
||||
var rgb = [
|
||||
const quantR = Math.floor(value / (19 * 19));
|
||||
const quantG = Math.floor(value / 19) % 19;
|
||||
const quantB = value % 19;
|
||||
const rgb = [
|
||||
signPow((quantR - 9) / 9, 2.0) * maximumValue,
|
||||
signPow((quantG - 9) / 9, 2.0) * maximumValue,
|
||||
signPow((quantB - 9) / 9, 2.0) * maximumValue,
|
||||
@@ -61,45 +61,45 @@ function decodeblur(blurhash, width, height, punch) {
|
||||
console.error('too short blurhash');
|
||||
return null;
|
||||
}
|
||||
var sizeFlag = decode83(blurhash[0]);
|
||||
var numY = Math.floor(sizeFlag / 9) + 1;
|
||||
var numX = (sizeFlag % 9) + 1;
|
||||
var quantisedMaximumValue = decode83(blurhash[1]);
|
||||
var maximumValue = (quantisedMaximumValue + 1) / 166;
|
||||
const sizeFlag = decode83(blurhash[0]);
|
||||
const numY = Math.floor(sizeFlag / 9) + 1;
|
||||
const numX = (sizeFlag % 9) + 1;
|
||||
const quantisedMaximumValue = decode83(blurhash[1]);
|
||||
const maximumValue = (quantisedMaximumValue + 1) / 166;
|
||||
if (blurhash.length !== 4 + 2 * numX * numY) {
|
||||
console.error('blurhash length mismatch', blurhash.length, 4 + 2 * numX * numY);
|
||||
return null;
|
||||
}
|
||||
var colors = new Array(numX * numY);
|
||||
for (var i = 0; i < colors.length; i++) {
|
||||
let colors = new Array(numX * numY);
|
||||
for (let i = 0; i < colors.length; i++) {
|
||||
if (i === 0) {
|
||||
var value = decode83(blurhash.substring(2, 6));
|
||||
const value = decode83(blurhash.substring(2, 6));
|
||||
colors[i] = decodeDC(value);
|
||||
}
|
||||
else {
|
||||
var value = decode83(blurhash.substring(4 + i * 2, 6 + i * 2));
|
||||
const value = decode83(blurhash.substring(4 + i * 2, 6 + i * 2));
|
||||
colors[i] = decodeDC2(value, maximumValue * punch);
|
||||
}
|
||||
}
|
||||
var bytesPerRow = width * 4;
|
||||
var pixels = new Uint8ClampedArray(bytesPerRow * height);
|
||||
const bytesPerRow = width * 4;
|
||||
let pixels = new Uint8ClampedArray(bytesPerRow * height);
|
||||
for (var y = 0; y < height; y++) {
|
||||
for (var x = 0; x < width; x++) {
|
||||
var r = 0;
|
||||
var g = 0;
|
||||
var b = 0;
|
||||
for (var j = 0; j < numY; j++) {
|
||||
for (var i = 0; i < numX; i++) {
|
||||
var basis = Math.cos(Math.PI * x * i / width) * Math.cos(Math.PI * y * j / height);
|
||||
var color = colors[i + j * numX];
|
||||
for (let j = 0; j < numY; j++) {
|
||||
for (let i = 0; i < numX; i++) {
|
||||
let basis = Math.cos(Math.PI * x * i / width) * Math.cos(Math.PI * y * j / height);
|
||||
let color = colors[i + j * numX];
|
||||
r += color[0] * basis;
|
||||
g += color[1] * basis;
|
||||
b += color[2] * basis;
|
||||
}
|
||||
}
|
||||
var intR = linearTosRGB(r);
|
||||
var intG = linearTosRGB(g);
|
||||
var intB = linearTosRGB(b);
|
||||
const intR = linearTosRGB(r);
|
||||
const intG = linearTosRGB(g);
|
||||
const intB = linearTosRGB(b);
|
||||
pixels[4 * x + 0 + y * bytesPerRow] = intR;
|
||||
pixels[4 * x + 1 + y * bytesPerRow] = intG;
|
||||
pixels[4 * x + 2 + y * bytesPerRow] = intB;
|
||||
@@ -109,9 +109,9 @@ function decodeblur(blurhash, width, height, punch) {
|
||||
return pixels;
|
||||
}
|
||||
function parseBlur(blur) {
|
||||
var canvas = document.getElementById('canvas');
|
||||
var ctx = canvas.getContext('2d');
|
||||
var pixels = decodeblur(blur, 32, 32)
|
||||
const canvas = document.getElementById('canvas');
|
||||
const ctx = canvas.getContext('2d');
|
||||
const pixels = decodeblur(blur, 32, 32)
|
||||
const imageData = new ImageData(pixels, 32, 32);
|
||||
|
||||
ctx.putImageData(imageData, 0, 0);
|
||||
|
||||
@@ -1,26 +1,19 @@
|
||||
selectedColumn = 0
|
||||
selectedToot = 0
|
||||
$(function($) {
|
||||
let selectedColumn = 0
|
||||
let selectedToot = 0
|
||||
$(function ($) {
|
||||
//キーボードショートカット
|
||||
$(window).keydown(function(e) {
|
||||
var hasFocus = $('input').is(':focus')
|
||||
var hasFocus2 = $('textarea').is(':focus')
|
||||
if (document.getElementById('webview')) {
|
||||
if ($('#webviewsel:checked').val()) {
|
||||
var wv = false
|
||||
} else {
|
||||
var wv = true
|
||||
}
|
||||
} else {
|
||||
var wv = true
|
||||
}
|
||||
$(window).keydown(function (e) {
|
||||
const hasFocus = isFocused('input')
|
||||
const hasFocus2 = isFocused('textarea')
|
||||
const postBox = document.querySelector('#textarea')
|
||||
let wv = false
|
||||
//Enter
|
||||
if (e.keyCode === 13) {
|
||||
if ($('#src').is(':focus')) {
|
||||
if (isFocused('#src')) {
|
||||
src()
|
||||
return false
|
||||
}
|
||||
if ($('#list-add').is(':focus')) {
|
||||
if (isFocused('#list-add')) {
|
||||
makeNewList()
|
||||
return false
|
||||
}
|
||||
@@ -92,7 +85,7 @@ $(function($) {
|
||||
}
|
||||
//X:開閉
|
||||
if (e.keyCode === 88) {
|
||||
if (!$('#post-box').hasClass('appear')) {
|
||||
if (!document.querySelector('#post-box').classList.contains('appear')) {
|
||||
show()
|
||||
$('textarea').focus()
|
||||
} else {
|
||||
@@ -102,10 +95,10 @@ $(function($) {
|
||||
}
|
||||
//N:新トゥート
|
||||
if (e.keyCode === 78) {
|
||||
if (!$('#post-box').hasClass('appear')) {
|
||||
if (!document.querySelector('#post-box').classList.contains('appear')) {
|
||||
show()
|
||||
}
|
||||
$('textarea').focus()
|
||||
postBox.focus()
|
||||
return false
|
||||
}
|
||||
//Ctrl+E:全ての通知未読を既読にする
|
||||
@@ -153,7 +146,7 @@ $(function($) {
|
||||
//数字:TL
|
||||
if (event.metaKey || event.ctrlKey) {
|
||||
if (e.keyCode >= 49 && e.keyCode <= 57) {
|
||||
var kz = e.keyCode - 49
|
||||
const kz = e.keyCode - 49
|
||||
goColumn(kz)
|
||||
return false
|
||||
}
|
||||
@@ -161,7 +154,7 @@ $(function($) {
|
||||
//矢印:選択
|
||||
if (e.code == 'ArrowLeft') {
|
||||
//left
|
||||
if ($('#imagemodal').hasClass('open')) {
|
||||
if (document.querySelector('#imagemodal').classList.contains('open')) {
|
||||
imgCont('prev')
|
||||
return false
|
||||
}
|
||||
@@ -172,7 +165,7 @@ $(function($) {
|
||||
return false
|
||||
} else if (e.code == 'ArrowUp') {
|
||||
//up
|
||||
if ($('#imagemodal').hasClass('open')) {
|
||||
if (document.querySelector('#imagemodal').classList.contains('open')) {
|
||||
return false
|
||||
}
|
||||
if (selectedToot > 0) {
|
||||
@@ -182,7 +175,7 @@ $(function($) {
|
||||
return false
|
||||
} else if (e.code == 'ArrowRight') {
|
||||
//right
|
||||
if ($('#imagemodal').hasClass('open')) {
|
||||
if (document.querySelector('#imagemodal').classList.contains('open')) {
|
||||
imgCont('next')
|
||||
return false
|
||||
}
|
||||
@@ -193,7 +186,7 @@ $(function($) {
|
||||
return false
|
||||
} else if (e.code == 'ArrowDown') {
|
||||
//down
|
||||
if ($('#imagemodal').hasClass('open')) {
|
||||
if (document.querySelector('#imagemodal').classList.contains('open')) {
|
||||
return false
|
||||
}
|
||||
selectedToot++
|
||||
@@ -210,24 +203,21 @@ $(function($) {
|
||||
}
|
||||
}
|
||||
//選択時
|
||||
const selectedId = document.querySelector('.selectedToot').getAttribute('unique-id')
|
||||
const selectedAcctIds = document.querySelector(`#timeline_${selectedColumn}`).getAttribute('data-acct')
|
||||
if (e.keyCode == 70) {
|
||||
var id = $('.selectedToot').attr('unique-id')
|
||||
var acct_id = $('#timeline_' + selectedColumn).attr('data-acct')
|
||||
fav(id, acct_id, false)
|
||||
fav(selectedId, selectedAcctIds, false)
|
||||
return false
|
||||
}
|
||||
if (e.keyCode == 66) {
|
||||
var id = $('.selectedToot').attr('unique-id')
|
||||
var acct_id = $('#timeline_' + selectedColumn).attr('data-acct')
|
||||
rt(id, acct_id, false)
|
||||
rt(selectedId, selectedAcctIds, false)
|
||||
return false
|
||||
}
|
||||
if (e.keyCode == 82) {
|
||||
var id = $('.selectedToot').attr('unique-id')
|
||||
var acct_id = $('#timeline_' + selectedColumn).attr('data-acct')
|
||||
var ats_cm = $('.selectedToot .rep-btn').attr('data-men')
|
||||
var mode = $('.selectedToot .rep-btn').attr('data-visen')
|
||||
re(id, ats_cm, acct_id, mode)
|
||||
const target = document.querySelector('.selectedToot .rep-btn')
|
||||
const ats_cm = target.getAttribute('data-men')
|
||||
const mode = target.getAttribute('data-visen')
|
||||
re(selectedId, ats_cm, selectedAcctIds, mode)
|
||||
return false
|
||||
}
|
||||
}
|
||||
@@ -237,9 +227,10 @@ $(function($) {
|
||||
//C+S+(No):ワンクリ
|
||||
if ((event.metaKey || event.ctrlKey) && event.shiftKey) {
|
||||
if (e.keyCode >= 49 && e.keyCode <= 51) {
|
||||
var no = e.keyCode - 48
|
||||
if (localStorage.getItem('oks-' + no)) {
|
||||
$('#textarea').val($('#textarea').val() + localStorage.getItem('oks-' + no))
|
||||
const no = e.keyCode - 48
|
||||
const oks = localStorage.getItem('oks-' + no)
|
||||
if (oks) {
|
||||
postBox.value = postBox.value + oks
|
||||
}
|
||||
return false
|
||||
}
|
||||
@@ -248,28 +239,29 @@ $(function($) {
|
||||
}
|
||||
})
|
||||
//クリアボタン
|
||||
$('#clear').click(function() {
|
||||
clear()
|
||||
})
|
||||
document.getElementById('clear').addEventListener('click', clear)
|
||||
})
|
||||
//選択する
|
||||
function tootSelector(column, toot) {
|
||||
$('.cvo').removeClass('selectedToot')
|
||||
$('#timeline_' + column + ' .cvo')
|
||||
.eq(toot)
|
||||
.addClass('selectedToot')
|
||||
var scr = $('.tl-box[tlid=' + column + ']').scrollTop()
|
||||
var elem = $('.selectedToot').offset().top
|
||||
var top = elem - $('.tl-box').height() + scr
|
||||
const selectedToot = document.querySelector('.selectedToot')
|
||||
let rect = {top: 0}
|
||||
if (selectedToot) {
|
||||
selectedToot.classList.remove('selectedToot')
|
||||
rect = selectedToot.getBoundingClientRect()
|
||||
}
|
||||
document.querySelectorAll(`#timeline_${column} .cvo`)[toot].classList.add('selectedToot')
|
||||
const scr = document.querySelector(`#tlBox${column}`).scrollTop
|
||||
const elem = rect.top + document.body.scrollTop
|
||||
let top = elem - getHeight('.tl-box') + scr
|
||||
if (top > 0) {
|
||||
top = top + $('.selectedToot').height()
|
||||
top = top + getHeight('.selectedToot')
|
||||
if (top > scr) {
|
||||
$('.tl-box[tlid=' + column + ']').animate({ scrollTop: top })
|
||||
$(`#tlBox${column}`).animate({ scrollTop: top })
|
||||
}
|
||||
} else if (elem < 0) {
|
||||
var to = scr + elem - $('.selectedToot').height()
|
||||
const to = scr + elem - getHeight('.selectedToot')
|
||||
if (to < scr) {
|
||||
$('.tl-box[tlid=' + column + ']').animate({ scrollTop: to })
|
||||
$(`#tlBox${column}`).animate({ scrollTop: to })
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,8 @@
|
||||
//モーダル・ドロップダウンの各種設定
|
||||
$(document).ready(function () {
|
||||
// the "href" attribute of the modal trigger must specify the modal ID that wants to be triggered
|
||||
$('.modal').modal({
|
||||
const modals = document.querySelectorAll('.modal')
|
||||
M.Modal.init(modals, {
|
||||
inDuration: 300,
|
||||
outDuration: 225,
|
||||
constrainWidth: false, // Does not change width of dropdown to that of the activator
|
||||
@@ -11,7 +12,8 @@ $(document).ready(function () {
|
||||
alignment: 'left', // Displays dropdown with edge aligned to the left of button
|
||||
stopPropagation: false
|
||||
})
|
||||
$('.dropdown-trigger').dropdown({
|
||||
const dropdown = document.querySelectorAll('.modal')
|
||||
M.Dropdown.init(dropdown, {
|
||||
inDuration: 300,
|
||||
outDuration: 225,
|
||||
constrainWidth: false, // Does not change width of dropdown to that of the activator
|
||||
@@ -20,10 +22,10 @@ $(document).ready(function () {
|
||||
belowOrigin: false, // Displays dropdown below the button
|
||||
alignment: 'left', // Displays dropdown with edge aligned to the left of button
|
||||
stopPropagation: false // Stops event propagation
|
||||
}
|
||||
)
|
||||
$('.collapsible').collapsible()
|
||||
$('#videomodal').modal({
|
||||
})
|
||||
M.Collapsible.init(document.querySelectorAll('.collapsible'));
|
||||
const videoModal = document.querySelectorAll('#videomodal')
|
||||
M.Modal.init(videoModal, {
|
||||
onCloseEnd: stopVideo
|
||||
})
|
||||
})
|
||||
@@ -1,31 +1,31 @@
|
||||
var sha256 = function sha256(ascii) {
|
||||
const sha256 = function sha256(ascii) {
|
||||
function rightRotate(value, amount) {
|
||||
return (value >>> amount) | (value << (32 - amount));
|
||||
};
|
||||
|
||||
var mathPow = Math.pow;
|
||||
var maxWord = mathPow(2, 32);
|
||||
var lengthProperty = 'length'
|
||||
var i, j; // Used as a counter across the whole file
|
||||
var result = ''
|
||||
const mathPow = Math.pow;
|
||||
const maxWord = mathPow(2, 32);
|
||||
const lengthProperty = 'length'
|
||||
let i, j; // Used as a counter across the whole file
|
||||
let result = ''
|
||||
|
||||
var words = [];
|
||||
var asciiBitLength = ascii[lengthProperty] * 8;
|
||||
let words = [];
|
||||
const asciiBitLength = ascii[lengthProperty] * 8;
|
||||
|
||||
//* caching results is optional - remove/add slash from front of this line to toggle
|
||||
// Initial hash value: first 32 bits of the fractional parts of the square roots of the first 8 primes
|
||||
// (we actually calculate the first 64, but extra values are just ignored)
|
||||
var hash = sha256.h = sha256.h || [];
|
||||
let hash = sha256.h = sha256.h || [];
|
||||
// Round constants: first 32 bits of the fractional parts of the cube roots of the first 64 primes
|
||||
var k = sha256.k = sha256.k || [];
|
||||
var primeCounter = k[lengthProperty];
|
||||
let k = sha256.k = sha256.k || [];
|
||||
let primeCounter = k[lengthProperty];
|
||||
/*/
|
||||
var hash = [], k = [];
|
||||
var primeCounter = 0;
|
||||
//*/
|
||||
|
||||
var isComposite = {};
|
||||
for (var candidate = 2; primeCounter < 64; candidate++) {
|
||||
let isComposite = {};
|
||||
for (let candidate = 2; primeCounter < 64; candidate++) {
|
||||
if (!isComposite[candidate]) {
|
||||
for (i = 0; i < 313; i += candidate) {
|
||||
isComposite[i] = candidate;
|
||||
@@ -47,21 +47,21 @@ var sha256 = function sha256(ascii) {
|
||||
|
||||
// process each chunk
|
||||
for (j = 0; j < words[lengthProperty];) {
|
||||
var w = words.slice(j, j += 16); // The message is expanded into 64 words as part of the iteration
|
||||
var oldHash = hash;
|
||||
let w = words.slice(j, j += 16); // The message is expanded into 64 words as part of the iteration
|
||||
const oldHash = hash;
|
||||
// This is now the undefinedworking hash", often labelled as variables a...g
|
||||
// (we have to truncate as well, otherwise extra entries at the end accumulate
|
||||
hash = hash.slice(0, 8);
|
||||
|
||||
for (i = 0; i < 64; i++) {
|
||||
var i2 = i + j;
|
||||
const i2 = i + j;
|
||||
// Expand the message into 64 words
|
||||
// Used below if
|
||||
var w15 = w[i - 15], w2 = w[i - 2];
|
||||
const w15 = w[i - 15], w2 = w[i - 2];
|
||||
|
||||
// Iterate
|
||||
var a = hash[0], e = hash[4];
|
||||
var temp1 = hash[7]
|
||||
const a = hash[0], e = hash[4];
|
||||
const temp1 = hash[7]
|
||||
+ (rightRotate(e, 6) ^ rightRotate(e, 11) ^ rightRotate(e, 25)) // S1
|
||||
+ ((e & hash[5]) ^ ((~e) & hash[6])) // ch
|
||||
+ k[i]
|
||||
@@ -74,7 +74,7 @@ var sha256 = function sha256(ascii) {
|
||||
) | 0
|
||||
);
|
||||
// This is only used once, so *could* be moved below, but it only saves 4 bytes and makes things unreadble
|
||||
var temp2 = (rightRotate(a, 2) ^ rightRotate(a, 13) ^ rightRotate(a, 22)) // S0
|
||||
const temp2 = (rightRotate(a, 2) ^ rightRotate(a, 13) ^ rightRotate(a, 22)) // S0
|
||||
+ ((a & hash[1]) ^ (a & hash[2]) ^ (hash[1] & hash[2])); // maj
|
||||
|
||||
hash = [(temp1 + temp2) | 0].concat(hash); // We don't bother trimming off the extra ones, they're harmless as long as we're truncating when we do the slice()
|
||||
@@ -88,7 +88,7 @@ var sha256 = function sha256(ascii) {
|
||||
|
||||
for (i = 0; i < 8; i++) {
|
||||
for (j = 3; j + 1; j--) {
|
||||
var b = (hash[i] >> (j * 8)) & 255;
|
||||
const b = (hash[i] >> (j * 8)) & 255;
|
||||
result += ((b < 16) ? 0 : '') + b.toString(16);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,26 +17,26 @@
|
||||
(function (factory) {
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// AMD. Register as an anonymous module.
|
||||
define(['jquery'], factory)
|
||||
define(['jquery'], factory);
|
||||
} else if (typeof module === 'object' && typeof module.exports === 'object') {
|
||||
factory(require('jquery'))
|
||||
factory(require('jquery'));
|
||||
} else {
|
||||
// Browser globals
|
||||
factory(jQuery)
|
||||
factory(jQuery);
|
||||
}
|
||||
}(function ($) {
|
||||
$.timeago = function (timestamp) {
|
||||
if (timestamp instanceof Date) {
|
||||
return inWords(timestamp)
|
||||
return inWords(timestamp);
|
||||
} else if (typeof timestamp === "string") {
|
||||
return inWords($.timeago.parse(timestamp))
|
||||
return inWords($.timeago.parse(timestamp));
|
||||
} else if (typeof timestamp === "number") {
|
||||
return inWords(new Date(timestamp))
|
||||
return inWords(new Date(timestamp));
|
||||
} else {
|
||||
return inWords($.timeago.datetime(timestamp))
|
||||
return inWords($.timeago.datetime(timestamp));
|
||||
}
|
||||
}
|
||||
var $t = $.timeago
|
||||
};
|
||||
const $t = $.timeago;
|
||||
$.extend($.timeago, {
|
||||
settings: {
|
||||
refreshMillis: 60000,
|
||||
@@ -69,36 +69,36 @@
|
||||
|
||||
inWords: function (distanceMillis) {
|
||||
if (!this.settings.allowPast && !this.settings.allowFuture) {
|
||||
throw 'timeago allowPast and allowFuture settings can not both be set to false.'
|
||||
throw 'timeago allowPast and allowFuture settings can not both be set to false.';
|
||||
}
|
||||
|
||||
var $l = this.settings.strings
|
||||
var prefix = $l.prefixAgo
|
||||
var suffix = $l.suffixAgo
|
||||
const $l = this.settings.strings;
|
||||
let prefix = $l.prefixAgo;
|
||||
let suffix = $l.suffixAgo;
|
||||
if (this.settings.allowFuture) {
|
||||
if (distanceMillis < 0) {
|
||||
prefix = $l.prefixFromNow
|
||||
suffix = $l.suffixFromNow
|
||||
prefix = $l.prefixFromNow;
|
||||
suffix = $l.suffixFromNow;
|
||||
}
|
||||
}
|
||||
|
||||
if (!this.settings.allowPast && distanceMillis >= 0) {
|
||||
return this.settings.strings.inPast
|
||||
return this.settings.strings.inPast;
|
||||
}
|
||||
|
||||
var seconds = Math.abs(distanceMillis) / 1000
|
||||
var minutes = seconds / 60
|
||||
var hours = minutes / 60
|
||||
var days = hours / 24
|
||||
var years = days / 365
|
||||
const seconds = Math.abs(distanceMillis) / 1000;
|
||||
const minutes = seconds / 60;
|
||||
const hours = minutes / 60;
|
||||
const days = hours / 24;
|
||||
const years = days / 365;
|
||||
|
||||
function substitute(stringOrFunction, number) {
|
||||
var string = $.isFunction(stringOrFunction) ? stringOrFunction(number, distanceMillis) : stringOrFunction
|
||||
var value = ($l.numbers && $l.numbers[number]) || number
|
||||
return string.replace(/%d/i, value)
|
||||
const string = $.isFunction(stringOrFunction) ? stringOrFunction(number, distanceMillis) : stringOrFunction;
|
||||
const value = ($l.numbers && $l.numbers[number]) || number;
|
||||
return string.replace(/%d/i, value);
|
||||
}
|
||||
|
||||
var words = seconds < 45 && substitute($l.seconds, Math.round(seconds)) ||
|
||||
const words = seconds < 45 && substitute($l.seconds, Math.round(seconds)) ||
|
||||
seconds < 90 && substitute($l.minute, 1) ||
|
||||
minutes < 45 && substitute($l.minutes, Math.round(minutes)) ||
|
||||
minutes < 90 && substitute($l.hour, 1) ||
|
||||
@@ -108,124 +108,124 @@
|
||||
days < 45 && substitute($l.month, 1) ||
|
||||
days < 365 && substitute($l.months, Math.round(days / 30)) ||
|
||||
years < 1.5 && substitute($l.year, 1) ||
|
||||
substitute($l.years, Math.round(years))
|
||||
substitute($l.years, Math.round(years));
|
||||
|
||||
var separator = $l.wordSeparator || ""
|
||||
if ($l.wordSeparator === undefined) { separator = " " }
|
||||
return $.trim([prefix, words, suffix].join(separator))
|
||||
const separator = $l.wordSeparator || "";
|
||||
if ($l.wordSeparator === undefined) { separator = " "; }
|
||||
return $.trim([prefix, words, suffix].join(separator));
|
||||
},
|
||||
|
||||
parse: function (iso8601) {
|
||||
var s = $.trim(iso8601)
|
||||
s = s.replace(/\.\d+/, "") // remove milliseconds
|
||||
s = s.replace(/-/, "/").replace(/-/, "/")
|
||||
s = s.replace(/T/, " ").replace(/Z/, " UTC")
|
||||
s = s.replace(/([\+\-]\d\d)\:?(\d\d)/, " $1$2") // -04:00 -> -0400
|
||||
s = s.replace(/([\+\-]\d\d)$/, " $100") // +09 -> +0900
|
||||
return new Date(s)
|
||||
let s = $.trim(iso8601);
|
||||
s = s.replace(/\.\d+/, ""); // remove milliseconds
|
||||
s = s.replace(/-/, "/").replace(/-/, "/");
|
||||
s = s.replace(/T/, " ").replace(/Z/, " UTC");
|
||||
s = s.replace(/([\+\-]\d\d)\:?(\d\d)/, " $1$2"); // -04:00 -> -0400
|
||||
s = s.replace(/([\+\-]\d\d)$/, " $100"); // +09 -> +0900
|
||||
return new Date(s);
|
||||
},
|
||||
datetime: function (elem) {
|
||||
var iso8601 = $t.isTime(elem) ? $(elem).attr("datetime") : $(elem).attr("title")
|
||||
return $t.parse(iso8601)
|
||||
const iso8601 = $t.isTime(elem) ? $(elem).attr("datetime") : $(elem).attr("title");
|
||||
return $t.parse(iso8601);
|
||||
},
|
||||
isTime: function (elem) {
|
||||
// jQuery's `is()` doesn't play well with HTML5 in IE
|
||||
return $(elem).get(0).tagName.toLowerCase() === "time" // $(elem).is("time");
|
||||
return $(elem).get(0).tagName.toLowerCase() === "time"; // $(elem).is("time");
|
||||
}
|
||||
})
|
||||
});
|
||||
|
||||
// functions that can be called via $(el).timeago('action')
|
||||
// init is default when no action is given
|
||||
// functions are called with context of a single element
|
||||
var functions = {
|
||||
const functions = {
|
||||
init: function () {
|
||||
functions.dispose.call(this)
|
||||
var refresh_el = $.proxy(refresh, this)
|
||||
refresh_el()
|
||||
var $s = $t.settings
|
||||
functions.dispose.call(this);
|
||||
const refresh_el = $.proxy(refresh, this);
|
||||
refresh_el();
|
||||
const $s = $t.settings;
|
||||
if ($s.refreshMillis > 0) {
|
||||
this._timeagoInterval = setInterval(refresh_el, $s.refreshMillis)
|
||||
this._timeagoInterval = setInterval(refresh_el, $s.refreshMillis);
|
||||
}
|
||||
},
|
||||
update: function (timestamp) {
|
||||
var date = (timestamp instanceof Date) ? timestamp : $t.parse(timestamp)
|
||||
$(this).data('timeago', { datetime: date })
|
||||
const date = (timestamp instanceof Date) ? timestamp : $t.parse(timestamp);
|
||||
$(this).data('timeago', { datetime: date });
|
||||
if ($t.settings.localeTitle) {
|
||||
$(this).attr("title", date.toLocaleString())
|
||||
$(this).attr("title", date.toLocaleString());
|
||||
}
|
||||
refresh.apply(this)
|
||||
refresh.apply(this);
|
||||
},
|
||||
updateFromDOM: function () {
|
||||
$(this).data('timeago', { datetime: $t.parse($t.isTime(this) ? $(this).attr("datetime") : $(this).attr("title")) })
|
||||
refresh.apply(this)
|
||||
$(this).data('timeago', { datetime: $t.parse($t.isTime(this) ? $(this).attr("datetime") : $(this).attr("title")) });
|
||||
refresh.apply(this);
|
||||
},
|
||||
dispose: function () {
|
||||
if (this._timeagoInterval) {
|
||||
window.clearInterval(this._timeagoInterval)
|
||||
this._timeagoInterval = null
|
||||
window.clearInterval(this._timeagoInterval);
|
||||
this._timeagoInterval = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
$.fn.timeago = function (action, options) {
|
||||
var fn = action ? functions[action] : functions.init
|
||||
const fn = action ? functions[action] : functions.init;
|
||||
if (!fn) {
|
||||
throw new Error("Unknown function name '" + action + "' for timeago")
|
||||
throw new Error("Unknown function name '" + action + "' for timeago");
|
||||
}
|
||||
// each over objects here and call the requested function
|
||||
this.each(function () {
|
||||
fn.call(this, options)
|
||||
})
|
||||
return this
|
||||
}
|
||||
fn.call(this, options);
|
||||
});
|
||||
return this;
|
||||
};
|
||||
|
||||
function refresh() {
|
||||
var $s = $t.settings
|
||||
const $s = $t.settings;
|
||||
|
||||
//check if it's still visible
|
||||
if ($s.autoDispose && !$.contains(document.documentElement, this)) {
|
||||
//stop if it has been removed
|
||||
$(this).timeago("dispose")
|
||||
return this
|
||||
$(this).timeago("dispose");
|
||||
return this;
|
||||
}
|
||||
|
||||
var data = prepareData(this)
|
||||
const data = prepareData(this);
|
||||
|
||||
if (!isNaN(data.datetime)) {
|
||||
if ($s.cutoff === 0 || Math.abs(distance(data.datetime)) < $s.cutoff) {
|
||||
$(this).text(inWords(data.datetime))
|
||||
$(this).text(inWords(data.datetime));
|
||||
} else {
|
||||
if ($(this).attr('title').length > 0) {
|
||||
$(this).text($(this).attr('title'))
|
||||
$(this).text($(this).attr('title'));
|
||||
}
|
||||
}
|
||||
}
|
||||
return this
|
||||
return this;
|
||||
}
|
||||
|
||||
function prepareData(element) {
|
||||
element = $(element)
|
||||
element = $(element);
|
||||
if (!element.data("timeago")) {
|
||||
element.data("timeago", { datetime: $t.datetime(element) })
|
||||
var text = $.trim(element.text())
|
||||
element.data("timeago", { datetime: $t.datetime(element) });
|
||||
const text = $.trim(element.text());
|
||||
if ($t.settings.localeTitle) {
|
||||
element.attr("title", element.data('timeago').datetime.toLocaleString())
|
||||
element.attr("title", element.data('timeago').datetime.toLocaleString());
|
||||
} else if (text.length > 0 && !($t.isTime(element) && element.attr("title"))) {
|
||||
element.attr("title", text)
|
||||
element.attr("title", text);
|
||||
}
|
||||
}
|
||||
return element.data("timeago")
|
||||
return element.data("timeago");
|
||||
}
|
||||
|
||||
function inWords(date) {
|
||||
return $t.inWords(distance(date))
|
||||
return $t.inWords(distance(date));
|
||||
}
|
||||
|
||||
function distance(date) {
|
||||
return (new Date().getTime() - date.getTime())
|
||||
return (new Date().getTime() - date.getTime());
|
||||
}
|
||||
|
||||
// fix for IE6 suckage
|
||||
document.createElement("abbr")
|
||||
document.createElement("time")
|
||||
}))
|
||||
document.createElement("abbr");
|
||||
document.createElement("time");
|
||||
}));
|
||||
@@ -1,44 +1,15 @@
|
||||
//バージョンチェッカー
|
||||
function verck(ver, jp) {
|
||||
async function verck(ver) {
|
||||
console.log('%c Welcome😊 ' + ver, 'color: red;font-size:200%;')
|
||||
$('body').addClass(localStorage.getItem('platform'))
|
||||
var date = new Date()
|
||||
var showVer = false
|
||||
//Spotify
|
||||
if (localStorage.getItem('spotify')) {
|
||||
localStorage.removeItem('spotify')
|
||||
localStorage.removeItem('spotify-refresh')
|
||||
var spDc = 'Spotify NowPlaying sysytem was changed, please re-login to Spotify'
|
||||
if(lang.language == 'ja') {
|
||||
spDc = 'Spotify NowPlayingの機能が変更されたため、もう一度ログインしてください'
|
||||
}
|
||||
Swal.fire({
|
||||
type: 'info',
|
||||
title: spDc,
|
||||
})
|
||||
}
|
||||
//Spotify(e)
|
||||
document.querySelector('body').classList.add(localStorage.getItem('platform'))
|
||||
const date = new Date()
|
||||
let showVer = false
|
||||
if (localStorage.getItem('ver') != ver && localStorage.getItem('winstore')) {
|
||||
showVer = true
|
||||
console.log('%c Thank you for your update🎉', 'color: red;font-size:200%;')
|
||||
$(document).ready(function() {
|
||||
if (localStorage.getItem('winstore') && !pwa) {
|
||||
$('#releasenote').modal('open')
|
||||
}
|
||||
verp = ver.replace('(', '')
|
||||
verp = verp.replace('.', '-')
|
||||
verp = verp.replace('.', '-')
|
||||
verp = verp.replace('[', '-')
|
||||
verp = verp.replace(']', '')
|
||||
verp = verp.replace(')', '')
|
||||
verp = verp.replace(' ', '_')
|
||||
console.log('%c ' + verp, 'color: red;font-size:200%;')
|
||||
if (lang.language == 'ja') {
|
||||
$('#release-' + verp).show()
|
||||
} else {
|
||||
$('#release-en').show()
|
||||
}
|
||||
})
|
||||
if (localStorage.getItem('winstore') && !pwa) {
|
||||
openRN()
|
||||
}
|
||||
}
|
||||
localStorage.setItem('ver', ver)
|
||||
if (!showVer) {
|
||||
@@ -48,295 +19,224 @@ function verck(ver, jp) {
|
||||
!localStorage.getItem('showSupportMe')
|
||||
) {
|
||||
if (date.getMonth() == 11) {
|
||||
var yrs = date.getFullYear() + 1
|
||||
var nextmonth = yrs * 100 + 1
|
||||
yrs = date.getFullYear() + 1
|
||||
nextmonth = yrs * 100 + 1
|
||||
} else {
|
||||
var yrs = date.getFullYear()
|
||||
var nextmonth = yrs * 100 + date.getMonth() + 2
|
||||
yrs = date.getFullYear()
|
||||
nextmonth = yrs * 100 + date.getMonth() + 2
|
||||
}
|
||||
if (lang.language != 'ja') {
|
||||
$('#support-btm-ja').addClass('hide')
|
||||
$('#support-btm-en').removeClass('hide')
|
||||
document.querySelector('#support-btm-ja').classList.add('hide')
|
||||
document.querySelector('#support-btm-en').classList.remove('hide')
|
||||
}
|
||||
localStorage.setItem('showSupportMe', nextmonth)
|
||||
$('#support-btm').removeClass('hide')
|
||||
$('#support-btm').animate(
|
||||
document.querySelector('#support-btm').classList.remove('hide')
|
||||
document.querySelector('#support-btm').animate([
|
||||
{
|
||||
bottom: '0'
|
||||
bottom: '-500px'
|
||||
},
|
||||
{
|
||||
duration: 300
|
||||
bottom: '0'
|
||||
}
|
||||
)
|
||||
], 300);
|
||||
}
|
||||
}
|
||||
var platform = localStorage.getItem('platform')
|
||||
const platform = localStorage.getItem('platform')
|
||||
console.log('Your platform:' + platform)
|
||||
if (!localStorage.getItem('winstore') && !pwa) {
|
||||
$('#start').css('display', 'flex')
|
||||
document.querySelector('#start').style.display = 'flex'
|
||||
}
|
||||
let winstore = false
|
||||
if (
|
||||
localStorage.getItem('winstore') == 'brewcask' ||
|
||||
localStorage.getItem('winstore') == 'snapcraft' ||
|
||||
localStorage.getItem('winstore') == 'winstore'
|
||||
) {
|
||||
var winstore = true
|
||||
winstore = true
|
||||
} else {
|
||||
var winstore = false
|
||||
winstore = false
|
||||
}
|
||||
var l = 5
|
||||
const l = 5
|
||||
// 生成する文字列に含める文字セット
|
||||
var c = 'abcdefghijklmnopqrstuvwxyz0123456789'
|
||||
var cl = c.length
|
||||
var r = ''
|
||||
const c = 'abcdefghijklmnopqrstuvwxyz0123456789'
|
||||
const cl = c.length
|
||||
let r = ''
|
||||
for (var i = 0; i < l; i++) {
|
||||
r += c[Math.floor(Math.random() * cl)]
|
||||
}
|
||||
var start = 'https://thedesk.top/ver.json'
|
||||
fetch(start, {
|
||||
method: 'GET'
|
||||
})
|
||||
.then(function(response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
}
|
||||
return response.json()
|
||||
})
|
||||
.catch(function(error) {
|
||||
todo(error)
|
||||
setLog(start, 'JSON', error)
|
||||
setLog(start, 'JSON', error)
|
||||
console.error(error)
|
||||
})
|
||||
.then(function(mess) {
|
||||
console.table(mess)
|
||||
if (mess) {
|
||||
//askjp_jp_ua: 2019年10月24日、mstdn.jpによるユーザーエージェントアクセス制限
|
||||
if (jp && mess.jp_ua && !localStorage.getItem('askjp_jp_ua')) {
|
||||
localStorage.setItem('askjp_jp_ua', true)
|
||||
$('#askjp_jp_ua').removeClass('hide')
|
||||
}
|
||||
var platform = localStorage.getItem('platform')
|
||||
if (platform == 'darwin') {
|
||||
var newest = mess.desk_mac
|
||||
} else {
|
||||
var newest = mess.desk
|
||||
}
|
||||
if (newest == ver) {
|
||||
todo(lang.lang_version_usever.replace('{{ver}}', mess.desk))
|
||||
//betaかWinstoreならアプデチェックしない
|
||||
} else if (ver.indexOf('beta') != -1 || winstore) {
|
||||
} else {
|
||||
localStorage.removeItem('instance')
|
||||
if (localStorage.getItem('new-ver-skip')) {
|
||||
if (localStorage.getItem('next-ver') != newest) {
|
||||
postMessage(['sendSinmpleIpc', 'update'], '*')
|
||||
} else {
|
||||
console.warn(lang.lang_version_skipver)
|
||||
todo(lang.lang_version_skipver)
|
||||
}
|
||||
} else {
|
||||
postMessage(['sendSinmpleIpc', 'update'], '*')
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
if (!localStorage.getItem('last-notice-id')) {
|
||||
localStorage.setItem('last-notice-id', 0)
|
||||
const start = 'https://thedesk.top/ver.json'
|
||||
let mess
|
||||
try {
|
||||
mess = await getApi(start, null)
|
||||
} catch {
|
||||
return false
|
||||
}
|
||||
var start = 'https://thedesk.top/notice/index.php?since_id=' + localStorage.getItem('last-notice-id')
|
||||
fetch(start, {
|
||||
method: 'GET',
|
||||
cors: true
|
||||
})
|
||||
.then(function(response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
}
|
||||
return response.json()
|
||||
})
|
||||
.catch(function(error) {
|
||||
todo(error)
|
||||
setLog(start, 'JSON', error)
|
||||
console.error(error)
|
||||
})
|
||||
.then(function(mess) {
|
||||
if (mess.length < 1) {
|
||||
return false
|
||||
} else {
|
||||
var last = localStorage.getItem('last-notice-id')
|
||||
localStorage.setItem('last-notice-id', mess[0].ID)
|
||||
for (i = 0; i < mess.length; i++) {
|
||||
var obj = mess[i]
|
||||
if (obj.ID * 1 <= last) {
|
||||
break
|
||||
} else {
|
||||
if (obj.type == 'textv2') {
|
||||
if (~obj.languages.indexOf(lang.language)) {
|
||||
var showVer = true
|
||||
if (obj.toot != '') {
|
||||
var toot =
|
||||
'<button class="btn-flat toast-action" onclick="detEx(\'' +
|
||||
obj.toot +
|
||||
"','main')\">Show</button>"
|
||||
} else {
|
||||
var toot = ''
|
||||
}
|
||||
if (obj.ver != '') {
|
||||
if (obj.ver == ver) {
|
||||
showVer = true
|
||||
} else {
|
||||
showVer = false
|
||||
}
|
||||
}
|
||||
if (obj.domain != '') {
|
||||
var multi = localStorage.getItem('multi')
|
||||
if (multi) {
|
||||
showVer = false
|
||||
var accts = JSON.parse(multi)
|
||||
Object.keys(accts).forEach(function(key) {
|
||||
var acct = accts[key]
|
||||
if (acct.domain == obj.domain) {
|
||||
showVer = true
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
if (showVer) {
|
||||
M.toast({
|
||||
html:
|
||||
escapeHTML(obj.text) +
|
||||
toot +
|
||||
'<span class="sml grey-text">(スライドして消去)</span>',
|
||||
displayLength: 86400
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
console.table(mess)
|
||||
if (mess) {
|
||||
let newest = null
|
||||
if (platform == 'darwin') {
|
||||
newest = mess.desk_mac
|
||||
} else {
|
||||
newest = mess.desk
|
||||
}
|
||||
if (newest == ver) {
|
||||
todo(lang.lang_version_usever.replace('{{ver}}', mess.desk))
|
||||
//betaかWinstoreならアプデチェックしない
|
||||
} else if (ver.indexOf('beta') != -1 || winstore) {
|
||||
//skipped
|
||||
} else {
|
||||
if (localStorage.getItem('new-ver-skip')) {
|
||||
if (localStorage.getItem('next-ver') != newest) {
|
||||
postMessage(['sendSinmpleIpc', 'update'], '*')
|
||||
} else {
|
||||
console.warn(lang.lang_version_skipver)
|
||||
todo(lang.lang_version_skipver)
|
||||
}
|
||||
} else {
|
||||
postMessage(['sendSinmpleIpc', 'update'], '*')
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
let lni = localStorage.getItem('last-notice-id')
|
||||
if (!lni) {
|
||||
localStorage.setItem('last-notice-id', 0)
|
||||
lni = 0
|
||||
}
|
||||
const getNotice = 'https://thedesk.top/notice/index.php?since_id=' + lni
|
||||
let notices
|
||||
try {
|
||||
notices = await getApi(getNotice, null)
|
||||
} catch {
|
||||
return false
|
||||
}
|
||||
if (notices.length < 1) {
|
||||
return false
|
||||
} else {
|
||||
localStorage.setItem('last-notice-id', notices[0].ID)
|
||||
for (i = 0; i < notices.length; i++) {
|
||||
var obj = notices[i]
|
||||
if (obj.ID * 1 <= lni) {
|
||||
break
|
||||
} else {
|
||||
toastInterpret(obj)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
var infostreaming = false
|
||||
let infostreaming = false
|
||||
function infowebsocket() {
|
||||
infows = new WebSocket('wss://thedesk.top/ws/')
|
||||
infows.onopen = function(mess) {
|
||||
infows.onopen = function (mess) {
|
||||
console.log([tlid, ':Connect Streaming Info:', mess])
|
||||
infostreaming = true
|
||||
}
|
||||
infows.onmessage = function(mess) {
|
||||
infows.onmessage = function (mess) {
|
||||
console.log([tlid, ':Receive Streaming:', JSON.parse(mess.data)])
|
||||
var obj = JSON.parse(mess.data)
|
||||
const obj = JSON.parse(mess.data)
|
||||
localStorage.setItem('last-notice-id', obj.id)
|
||||
if (obj.type != 'counter') {
|
||||
if (obj.type == 'textv2') {
|
||||
if (~obj.languages.indexOf(lang.language)) {
|
||||
localStorage.setItem('last-notice-id', obj.id)
|
||||
var showVer = true
|
||||
if (obj.toot != '') {
|
||||
var toot =
|
||||
'<button class="btn-flat toast-action" onclick="detEx(\'' +
|
||||
obj.toot +
|
||||
"','main')\">Show</button>"
|
||||
} else {
|
||||
var toot = ''
|
||||
}
|
||||
if (obj.ver != '') {
|
||||
if (obj.ver == ver) {
|
||||
showVer = true
|
||||
} else {
|
||||
showVer = false
|
||||
}
|
||||
}
|
||||
if (obj.domain != '') {
|
||||
var multi = localStorage.getItem('multi')
|
||||
if (multi) {
|
||||
showVer = false
|
||||
var accts = JSON.parse(multi)
|
||||
Object.keys(accts).forEach(function(key) {
|
||||
var acct = accts[key]
|
||||
if (acct.domain == obj.domain) {
|
||||
showVer = true
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
if (showVer) {
|
||||
console.log(obj.text)
|
||||
console.log(escapeHTML(obj.text))
|
||||
M.toast({
|
||||
html:
|
||||
escapeHTML(obj.text) +
|
||||
toot +
|
||||
'<span class="sml grey-text">(スライドして消去)</span>',
|
||||
displayLength: 86400
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
toastInterpret(obj)
|
||||
} else {
|
||||
$('#persons').text(obj.text)
|
||||
const people = document.querySelector('#persons')
|
||||
if(people) {
|
||||
people.innerText = obj.text
|
||||
}
|
||||
}
|
||||
}
|
||||
infows.onerror = function(error) {
|
||||
infows.onerror = function (error) {
|
||||
infostreaming = false
|
||||
console.error('Error closing:info')
|
||||
console.error(error)
|
||||
return false
|
||||
}
|
||||
infows.onclose = function() {
|
||||
infows.onclose = function () {
|
||||
infostreaming = false
|
||||
console.error('Closing:info')
|
||||
}
|
||||
}
|
||||
setInterval(function() {
|
||||
setInterval(function () {
|
||||
if (!infostreaming) {
|
||||
console.log('try to connect to base-streaming')
|
||||
infowebsocket()
|
||||
}
|
||||
}, 10000)
|
||||
function openRN() {
|
||||
$('#releasenote').modal('open')
|
||||
if (lang.language == 'ja') {
|
||||
verp = ver.replace('(', '')
|
||||
verp = verp.replace('.', '-')
|
||||
verp = verp.replace('.', '-')
|
||||
verp = verp.replace('[', '-')
|
||||
verp = verp.replace(']', '')
|
||||
verp = verp.replace(')', '')
|
||||
verp = verp.replace(' ', '_')
|
||||
$('#release-' + verp).show()
|
||||
} else {
|
||||
$('#release-en').show()
|
||||
}
|
||||
}
|
||||
function closeSupport() {
|
||||
$('#support-btm').animate(
|
||||
{
|
||||
bottom: '-300px'
|
||||
},
|
||||
{
|
||||
duration: 300,
|
||||
complete: function() {
|
||||
$('#support-btm').addClass('hide')
|
||||
async function toastInterpret(obj) {
|
||||
if (obj.type == 'textv2') {
|
||||
if (~obj.languages.indexOf(lang.language)) {
|
||||
let showVer = true
|
||||
let toot = null
|
||||
if (obj.toot != '') {
|
||||
toot = `<button class="btn-flat toast-action" data-toot="${obj.toot}">Show</button>`
|
||||
}
|
||||
if (obj.ver == ver) {
|
||||
showVer = true
|
||||
} else {
|
||||
showVer = false
|
||||
}
|
||||
if (obj.domain != '') {
|
||||
const multi = localStorage.getItem('multi')
|
||||
if (multi) {
|
||||
showVer = false
|
||||
const accts = JSON.parse(multi)
|
||||
const keys = Object.keys(accts)
|
||||
for (let i = 0; i < accts.length; i++) {
|
||||
const key = keys[i]
|
||||
const acct = accts[key]
|
||||
if (acct.domain == obj.domain) {
|
||||
showVer = true
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (showVer) {
|
||||
M.toast({
|
||||
html: `${escapeHTML(obj.text)} ${toot} <span class="sml grey-text">(スライドして消去)</span>`,
|
||||
displayLength: 86400
|
||||
})
|
||||
await sleep(500)
|
||||
const targets = document.querySelectorAll('.toast-action')
|
||||
for (let j = 0; j < targets.length; j++) {
|
||||
const target = targets[j]
|
||||
const toot = target.getAttribute('data-toot')
|
||||
target.addEventListener('click', () => detEx(toot, 'main'))
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
)
|
||||
}
|
||||
}
|
||||
function openRN() {
|
||||
console.log(kirishima)
|
||||
M.Modal.getInstance(document.querySelector('#releasenote')).open()
|
||||
if (lang.language == 'ja') {
|
||||
verp = ver.replace('(', '').replace('.', '-').replace('.', '-').replace('[', '-').replace(']', '').replace(')', '').replace(' ', '_')
|
||||
showElm(`#release-${verp}`)
|
||||
} else {
|
||||
showElm('#release-en')
|
||||
}
|
||||
}
|
||||
async function closeSupport() {
|
||||
document.querySelector('#support-btm').animate([
|
||||
{
|
||||
bottom: '0'
|
||||
},
|
||||
{
|
||||
bottom: '-300px'
|
||||
}
|
||||
], 300);
|
||||
await sleep(300)
|
||||
document.querySelector('#support-btm').classList.add('hide')
|
||||
}
|
||||
function storeDialog(platform, ver) {
|
||||
if($('body').hasClass('accessibility')) return false
|
||||
if (document.querySelector('body').classList.contain('accessibility')) return false
|
||||
let mes = false
|
||||
if (platform == 'win32') {
|
||||
var mes = lang.lang_version_platform
|
||||
mes = lang.lang_version_platform
|
||||
} else if (platform == 'linux') {
|
||||
var mes = lang.lang_version_platform_linux
|
||||
mes = lang.lang_version_platform_linux
|
||||
} else if (platform == 'darwin') {
|
||||
var mes = lang.lang_version_platform_mac
|
||||
} else {
|
||||
var mes = false
|
||||
mes = lang.lang_version_platform_mac
|
||||
}
|
||||
if (mes) {
|
||||
Swal.fire({
|
||||
@@ -357,52 +257,22 @@ function storeDialog(platform, ver) {
|
||||
}
|
||||
localStorage.setItem('ver', ver)
|
||||
showVer = true
|
||||
if(pwa) return false
|
||||
if (pwa) return false
|
||||
console.log('%c Thank you for your update🎉', 'color: red;font-size:200%;')
|
||||
$(document).ready(function() {
|
||||
$('#releasenote').modal('open')
|
||||
verp = ver.replace('(', '')
|
||||
verp = verp.replace('.', '-')
|
||||
verp = verp.replace('.', '-')
|
||||
verp = verp.replace('[', '-')
|
||||
verp = verp.replace(']', '')
|
||||
verp = verp.replace(')', '')
|
||||
verp = verp.replace(' ', '_')
|
||||
console.log('%c ' + verp, 'color: red;font-size:200%;')
|
||||
if (lang.language == 'ja') {
|
||||
$('#release-' + verp).show()
|
||||
} else {
|
||||
$('#release-en').show()
|
||||
}
|
||||
})
|
||||
openRN()
|
||||
})
|
||||
} else {
|
||||
localStorage.setItem('ver', ver)
|
||||
showVer = true
|
||||
console.log('%c Thank you for your update🎉', 'color: red;font-size:200%;')
|
||||
$(document).ready(function() {
|
||||
if(pwa) return false
|
||||
$('#releasenote').modal('open')
|
||||
verp = ver.replace('(', '')
|
||||
verp = verp.replace('.', '-')
|
||||
verp = verp.replace('.', '-')
|
||||
verp = verp.replace('[', '-')
|
||||
verp = verp.replace(']', '')
|
||||
verp = verp.replace(')', '')
|
||||
verp = verp.replace(' ', '_')
|
||||
console.log('%c ' + verp, 'color: red;font-size:200%;')
|
||||
if (lang.language == 'ja') {
|
||||
$('#release-' + verp).show()
|
||||
} else {
|
||||
$('#release-en').show()
|
||||
}
|
||||
})
|
||||
showVer = true
|
||||
console.log('%c Thank you for your update🎉', 'color: red;font-size:200%;')
|
||||
openRN()
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
function closeStart() {
|
||||
$('#start').css('display', 'none')
|
||||
var platform = localStorage.getItem('platform')
|
||||
var ver = localStorage.getItem('ver')
|
||||
document.querySelector('#start').style.display = 'none'
|
||||
const platform = localStorage.getItem('platform')
|
||||
const ver = localStorage.getItem('ver')
|
||||
storeDialog(platform, ver)
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
var defaultemojiList = ['activity', 'flag', 'food', 'nature', 'object', 'people', 'place', 'symbol']
|
||||
var defaultemoji = {
|
||||
const defaultemojiList = ['activity', 'flag', 'food', 'nature', 'object', 'people', 'place', 'symbol']
|
||||
const defaultemoji = {
|
||||
activity: activity,
|
||||
flag: flag,
|
||||
food: food,
|
||||
@@ -9,8 +9,18 @@ var defaultemoji = {
|
||||
place: place,
|
||||
symbol: symbol
|
||||
}
|
||||
let defaultemojiname = {
|
||||
activity: 'Activities',
|
||||
flag: 'Flags',
|
||||
food: 'Foods',
|
||||
nature: 'Nature',
|
||||
object: 'Tools',
|
||||
people: 'People',
|
||||
place: 'Places',
|
||||
symbol: 'Symbols'
|
||||
}
|
||||
if (lang == 'ja') {
|
||||
var defaultemojiname = {
|
||||
defaultemojiname = {
|
||||
activity: '活動',
|
||||
flag: '国旗',
|
||||
food: '食べ物',
|
||||
@@ -20,33 +30,23 @@ if (lang == 'ja') {
|
||||
place: '場所',
|
||||
symbol: '記号'
|
||||
}
|
||||
} else {
|
||||
var defaultemojiname = {
|
||||
activity: 'Activities',
|
||||
flag: 'Flags',
|
||||
food: 'Foods',
|
||||
nature: 'Nature',
|
||||
object: 'Tools',
|
||||
people: 'People',
|
||||
place: 'Places',
|
||||
symbol: 'Symbols'
|
||||
}
|
||||
}
|
||||
|
||||
function defaultEmoji(target) {
|
||||
var announcement = false
|
||||
if ($('#media').val() == 'announcement') {
|
||||
announcement = true
|
||||
}
|
||||
var json = defaultemoji[target]
|
||||
var emojis = ''
|
||||
Object.keys(json).forEach(function(key) {
|
||||
var emoji = json[key]
|
||||
if (announcement) {
|
||||
var def = `<a onclick="emojiReactionDef('${emoji['shortcode']}')" class="pointer">`
|
||||
} else {
|
||||
var def = `<a onclick="defEmoji('${emoji['shortcode']}')" class="pointer">`
|
||||
}
|
||||
let announcement = false
|
||||
if (document.querySelector('#media').value == 'announcement') {
|
||||
announcement = true
|
||||
}
|
||||
const json = defaultemoji[target]
|
||||
const keymap = Object.keys(json)
|
||||
let emojis = ''
|
||||
for (let i = 0; i < json.length; i++) {
|
||||
const key = keymap[i]
|
||||
const emoji = json[key]
|
||||
let def = `<a data-shortcode="${emoji['shortcode']}" class="pointer defEmoji">`
|
||||
if (announcement) {
|
||||
def = `<a data-shortcode="${emoji['shortcode']}" class="pointer defEmoji">`
|
||||
}
|
||||
emojis =
|
||||
emojis +
|
||||
`${def}
|
||||
@@ -54,52 +54,39 @@ function defaultEmoji(target) {
|
||||
width: 20px; height: 20px; display: inline-block; background-image: url('../../img/sheet.png'); background-size: 4900%;
|
||||
background-position:${emoji['css']};"></span>
|
||||
</a>`
|
||||
})
|
||||
$('#emoji-list').html(emojis)
|
||||
$('#now-emoji').text(lang.lang_defaultemojis_text.replace('{{cat}}', defaultemojiname[target]))
|
||||
$('.emoji-control').addClass('hide')
|
||||
}
|
||||
document.querySelector('#emoji-list').innerHTML = emojis
|
||||
document.querySelector('#now-emoji').innerText = lang.lang_defaultemojis_text.replace('{{cat}}', defaultemojiname[target])
|
||||
document.querySelector('.emoji-control').classList.add('hide')
|
||||
const targets = document.querySelectorAll('.defEmoji')
|
||||
for (let j = 0; j < targets.length; j++) {
|
||||
const target = targets[j]
|
||||
const sc = target.getAttribute('data-shortcode')
|
||||
target.addEventListener('click', () => defEmoji(sc))
|
||||
}
|
||||
}
|
||||
|
||||
function customEmoji() {
|
||||
$('#emoji-suggest').val('')
|
||||
$('.emoji-control').removeClass('hide')
|
||||
document.querySelector('#emoji-suggest').value = ''
|
||||
document.querySelector('.emoji-control').classList.remove('hide')
|
||||
emojiList('home')
|
||||
}
|
||||
|
||||
function defEmoji(target) {
|
||||
var selin = $('#textarea').prop('selectionStart')
|
||||
const textarea = document.querySelector('#textarea')
|
||||
let selin = textarea.selectionStart
|
||||
if (!selin) {
|
||||
selin = 0
|
||||
}
|
||||
var emojiraw = newpack.filter(function(item, index) {
|
||||
if (item.short_name == target) return true
|
||||
})
|
||||
var hex = emojiraw[0].unified.split('-')
|
||||
const hex = emojipack[target].unified.split('-')
|
||||
let emoji = twemoji.convert.fromCodePoint(hex[0])
|
||||
if (hex.length === 2) {
|
||||
emoji = twemoji.convert.fromCodePoint(hex[0]) + twemoji.convert.fromCodePoint(hex[1])
|
||||
} else {
|
||||
emoji = twemoji.convert.fromCodePoint(hex[0])
|
||||
}
|
||||
var now = $('#textarea').val()
|
||||
var before = now.substr(0, selin)
|
||||
var after = now.substr(selin, now.length)
|
||||
newt = before + emoji + after
|
||||
$('#textarea').val(newt)
|
||||
$('#textarea').focus()
|
||||
}
|
||||
function faicon() {
|
||||
var json = faicons
|
||||
var emojis = ''
|
||||
Object.keys(json).forEach(function(key) {
|
||||
var emoji = json[key]
|
||||
var eje = emoji.replace(/fa-/g, '')
|
||||
emojis =
|
||||
emojis +
|
||||
'<a onclick="emojiInsert(\'[faicon]' +
|
||||
eje +
|
||||
'[/faicon]\')" class="pointer white-text" style="font-size:24px"><i class="fa ' +
|
||||
emoji +
|
||||
'"></i></a>'
|
||||
})
|
||||
$('#emoji-list').html(emojis)
|
||||
$('#now-emoji').text('faicon')
|
||||
$('.emoji-control').addClass('hide')
|
||||
const now = textarea.value
|
||||
const before = now.substr(0, selin)
|
||||
const after = now.substr(selin, now.length)
|
||||
const newt = before + emoji + after
|
||||
textarea.value = newt
|
||||
textarea.focus()
|
||||
}
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1,5 +1,5 @@
|
||||
//インスタンスリスト
|
||||
var idata = {
|
||||
const idata = {
|
||||
"kirishima.cloud": "instance",
|
||||
"kirishima.cloud_name": "アスタルテ",
|
||||
"kirishima.cloud_letters": "6229",
|
||||
@@ -83,6 +83,4 @@ var idata = {
|
||||
"nitiasa.com_quote":"enabled",
|
||||
"biwakodon.com_quote":"enabled",
|
||||
"comm.cx_quote":"enabled"
|
||||
}
|
||||
|
||||
localStorage.setItem("instance", JSON.stringify(idata))
|
||||
};
|
||||
|
||||
@@ -1,618 +1,276 @@
|
||||
/*ログイン処理・認証までのJS*/
|
||||
//最初に読むやつ
|
||||
//アスタルテ判定初期化
|
||||
|
||||
localStorage.removeItem('kirishima')
|
||||
localStorage.removeItem('quoters')
|
||||
localStorage.removeItem('imas')
|
||||
localStorage.removeItem('image')
|
||||
//stable, 固定タグのことらしい。ふざけるな。
|
||||
localStorage.removeItem('stable')
|
||||
localStorage.setItem('mode_misskey.xyz', 'misskey')
|
||||
function ck() {
|
||||
var main = localStorage.getItem('main')
|
||||
const acctList = JSON.parse(localStorage.getItem('multi'))
|
||||
|
||||
async function ck() {
|
||||
const main = localStorage.getItem('main')
|
||||
if (!main) {
|
||||
localStorage.setItem('main', 0)
|
||||
localStorage.setItem('main', '0')
|
||||
}
|
||||
|
||||
//コード受信
|
||||
if (location.search) {
|
||||
var m = location.search.match(/\?mode=([a-zA-Z-0-9]+)\&code=(.+)/)
|
||||
var mode = m[1]
|
||||
var codex = m[2]
|
||||
const m = location.search.match(/\?mode=([a-zA-Z-0-9]+)\&code=(.+)/)
|
||||
const mode = m[1]
|
||||
const codex = m[2]
|
||||
if (mode == 'manager' || mode == 'login') {
|
||||
code(codex, mode)
|
||||
} else {
|
||||
}
|
||||
}
|
||||
var multi = localStorage.getItem('multi')
|
||||
const multi = localStorage.getItem('multi')
|
||||
if (!multi || multi == '[]') {
|
||||
var date = new Date()
|
||||
const date = new Date()
|
||||
localStorage.setItem('showSupportMe', date.getMonth() + 2)
|
||||
location.href = 'acct.html?mode=first&code=true'
|
||||
} else {
|
||||
var obj = JSON.parse(multi)
|
||||
var jp = false
|
||||
Object.keys(obj).forEach(function(key) {
|
||||
var acct = obj[key]
|
||||
const obj = JSON.parse(multi)
|
||||
const keymap = Object.keys(obj)
|
||||
let req = false
|
||||
for (let i = 0; i < keymap.length; i++) {
|
||||
const key = keymap[i]
|
||||
const acct = obj[key]
|
||||
if (acct.domain) {
|
||||
refresh(key, true)
|
||||
let refreshed = await refresh(key, true)
|
||||
if (refreshed) req = true
|
||||
}
|
||||
if (acct.domain == 'mstdn.jp') {
|
||||
jp = true
|
||||
}
|
||||
})
|
||||
}
|
||||
if (req) {
|
||||
Swal.fire({
|
||||
title: 'Reload required',
|
||||
text: lang.lang_login_changedData,
|
||||
type: 'info',
|
||||
showCancelButton: true,
|
||||
confirmButtonText: lang.lang_no,
|
||||
cancelButtonText: lang.lang_yesno
|
||||
}).then(result => {
|
||||
if (result) location.reload()
|
||||
})
|
||||
}
|
||||
if (obj[0].domain) {
|
||||
$('#tl').show()
|
||||
showElm('#tl')
|
||||
ticker()
|
||||
multiSelector(false)
|
||||
verck(ver, jp)
|
||||
$('.stw').show()
|
||||
if (localStorage.getItem('tips')) {
|
||||
tips(localStorage.getItem('tips'))
|
||||
parseColumn()
|
||||
verck(ver)
|
||||
showElm('.stw')
|
||||
const tipsType = localStorage.getItem('tips')
|
||||
if (tipsType) {
|
||||
tips(tipsType)
|
||||
}
|
||||
$('#something-wrong img').attr('src', '../../img/thinking.svg')
|
||||
document.querySelector('#something-wrong img').setAttribute('src', '../../img/thinking.svg')
|
||||
}
|
||||
}
|
||||
}
|
||||
ck()
|
||||
|
||||
//ログインポップアップ
|
||||
function login(url) {
|
||||
if ($('#linux:checked').val() == 'on') {
|
||||
var red = 'urn:ietf:wg:oauth:2.0:oob'
|
||||
} else {
|
||||
var red = 'thedesk://login'
|
||||
}
|
||||
localStorage.setItem('redirect', red)
|
||||
var start = 'https://' + url + '/api/v1/apps'
|
||||
var httpreq = new XMLHttpRequest()
|
||||
httpreq.open('POST', start, true)
|
||||
httpreq.setRequestHeader('Content-Type', 'application/json')
|
||||
httpreq.responseType = 'json'
|
||||
httpreq.send(
|
||||
JSON.stringify({
|
||||
scopes: 'read write follow',
|
||||
client_name: 'TheDesk(PC)',
|
||||
redirect_uris: red,
|
||||
website: 'https://thedesk.top'
|
||||
})
|
||||
)
|
||||
httpreq.onreadystatechange = function() {
|
||||
if (httpreq.readyState === 4) {
|
||||
var json = httpreq.response
|
||||
if (this.status !== 200) {
|
||||
setLog(start, this.status, json)
|
||||
}
|
||||
var auth =
|
||||
'https://' +
|
||||
url +
|
||||
'/oauth/authorize?client_id=' +
|
||||
json['client_id'] +
|
||||
'&client_secret=' +
|
||||
json['client_secret'] +
|
||||
'&response_type=code&redirect_uri=' +
|
||||
red +
|
||||
'&scope=read+write+follow'
|
||||
localStorage.setItem('domain_' + acct_id, url)
|
||||
localStorage.setItem('client_id', json['client_id'])
|
||||
localStorage.setItem('client_secret', json['client_secret'])
|
||||
$('#auth').show()
|
||||
$('#masara').hide()
|
||||
postMessage(['openUrl', auth], '*')
|
||||
|
||||
if ($('#linux:checked').val() == 'on') {
|
||||
} else {
|
||||
postMessage(['sendSinmpleIpc', 'quit'], '*')
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//テキストボックスにURL入れた
|
||||
function instance() {
|
||||
var url = $('#url').val()
|
||||
login(url)
|
||||
}
|
||||
|
||||
//コードを入れた後認証
|
||||
function code(code, mode) {
|
||||
var red = localStorage.getItem('redirect')
|
||||
localStorage.removeItem('redirect')
|
||||
if (!code) {
|
||||
var code = $('#code').val()
|
||||
}
|
||||
if (localStorage.getItem('domain_tmp')) {
|
||||
var url = localStorage.getItem('domain_tmp')
|
||||
} else {
|
||||
var url = localStorage.getItem('domain_' + acct_id)
|
||||
}
|
||||
var start = 'https://' + url + '/oauth/token'
|
||||
var id = localStorage.getItem('client_id')
|
||||
var secret = localStorage.getItem('client_secret')
|
||||
fetch(start, {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'content-type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify({
|
||||
grant_type: 'authorization_code',
|
||||
redirect_uri: red,
|
||||
client_id: id,
|
||||
client_secret: secret,
|
||||
code: code
|
||||
})
|
||||
})
|
||||
.then(function(response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
}
|
||||
return response.json()
|
||||
})
|
||||
.catch(function(error) {
|
||||
todo(error)
|
||||
setLog(start, 'JSON', error)
|
||||
console.error(error)
|
||||
})
|
||||
.then(function(json) {
|
||||
todo(json)
|
||||
if (json['access_token']) {
|
||||
localStorage.setItem(url + '_at', json['access_token'])
|
||||
if (mode == 'manager') {
|
||||
getdataAdv(url, json['access_token'])
|
||||
} else {
|
||||
getdata()
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
//ユーザーデータ取得(最初)
|
||||
function getdata() {
|
||||
var acct_id = 0
|
||||
var domain = localStorage.getItem('domain_' + acct_id)
|
||||
var at = localStorage.getItem('acct_' + acct_id + '_at')
|
||||
var start = 'https://' + domain + '/api/v1/accounts/verify_credentials'
|
||||
fetch(start, {
|
||||
method: 'GET',
|
||||
headers: {
|
||||
'content-type': 'application/json',
|
||||
Authorization: 'Bearer ' + at
|
||||
}
|
||||
})
|
||||
.then(function(response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
}
|
||||
return response.json()
|
||||
})
|
||||
.catch(function(error) {
|
||||
todo(error)
|
||||
setLog(start, 'JSON', error)
|
||||
console.error(error)
|
||||
})
|
||||
.then(function(json) {
|
||||
if (json.error) {
|
||||
console.error('Error:' + json.error)
|
||||
M.toast({ html: lang.lang_fatalerroroccured + 'Error:' + json.error, displayLength: 5000 })
|
||||
return
|
||||
}
|
||||
var avatar = json['avatar']
|
||||
//missingがmissingなやつ
|
||||
if (avatar == '/avatars/original/missing.png') {
|
||||
avatar = './img/missing.svg'
|
||||
}
|
||||
var obj = [
|
||||
{
|
||||
at: at,
|
||||
name: json['display_name'],
|
||||
domain: domain,
|
||||
user: json['acct'],
|
||||
prof: avatar,
|
||||
id: json['id'],
|
||||
vis: json['source']['privacy']
|
||||
}
|
||||
]
|
||||
var json = JSON.stringify(obj)
|
||||
localStorage.setItem('multi', json)
|
||||
localStorage.setItem('name_' + acct_id, json['display_name'])
|
||||
localStorage.setItem('user_' + acct_id, json['acct'])
|
||||
localStorage.setItem('user-id_' + acct_id, json['id'])
|
||||
localStorage.setItem('prof_' + acct_id, avatar)
|
||||
$('#masara').hide()
|
||||
$('#auth').hide()
|
||||
$('#tl').show()
|
||||
parseColumn()
|
||||
ckdb()
|
||||
})
|
||||
}
|
||||
//ユーザーデータ取得(追加)
|
||||
function getdataAdv(domain, at) {
|
||||
var start = 'https://' + domain + '/api/v1/accounts/verify_credentials'
|
||||
fetch(start, {
|
||||
method: 'GET',
|
||||
headers: {
|
||||
'content-type': 'application/json',
|
||||
Authorization: 'Bearer ' + at
|
||||
}
|
||||
})
|
||||
.then(function(response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
}
|
||||
return response.json()
|
||||
})
|
||||
.catch(function(error) {
|
||||
todo(error)
|
||||
setLog(start, 'JSON', error)
|
||||
console.error(error)
|
||||
})
|
||||
.then(function(json) {
|
||||
if (json.error) {
|
||||
console.error('Error:' + json.error)
|
||||
M.toast({ html: lang.lang_fatalerroroccured + 'Error:' + json.error, displayLength: 5000 })
|
||||
return
|
||||
}
|
||||
var avatar = json['avatar']
|
||||
//missingがmissingなやつ
|
||||
if (avatar == '/avatars/original/missing.png') {
|
||||
avatar = '../../img/missing.svg'
|
||||
}
|
||||
if (json['source']['privacy']) {
|
||||
var priv = json['source']['privacy']
|
||||
} else {
|
||||
var priv = 'public'
|
||||
}
|
||||
var add = {
|
||||
at: at,
|
||||
name: json['display_name'],
|
||||
domain: domain,
|
||||
user: json['acct'],
|
||||
prof: avatar,
|
||||
id: json['id'],
|
||||
vis: priv
|
||||
}
|
||||
var multi = localStorage.getItem('multi')
|
||||
var obj = JSON.parse(multi)
|
||||
var target = obj.lengtth
|
||||
obj.push(add)
|
||||
localStorage.setItem('name_' + target, json['display_name'])
|
||||
localStorage.setItem('user_' + target, json['acct'])
|
||||
localStorage.setItem('user-id_' + target, json['id'])
|
||||
localStorage.setItem('prof_' + target, avatar)
|
||||
var json = JSON.stringify(obj)
|
||||
localStorage.setItem('multi', json)
|
||||
location.href = 'index.html'
|
||||
})
|
||||
}
|
||||
//ユーザーデータ更新
|
||||
function refresh(target, loadskip) {
|
||||
var multi = localStorage.getItem('multi')
|
||||
var obj = JSON.parse(multi)
|
||||
if (obj[target].mode == 'misskey') {
|
||||
async function refresh(target, loadskip) {
|
||||
let obj = acctList
|
||||
let requireReload = false
|
||||
const { mode, domain, at, background, text, name, prof, vis } = obj[target]
|
||||
if (mode == 'misskey') {
|
||||
return
|
||||
}
|
||||
var start = 'https://' + obj[target].domain + '/api/v1/accounts/verify_credentials'
|
||||
fetch(start, {
|
||||
method: 'GET',
|
||||
headers: {
|
||||
'content-type': 'application/json',
|
||||
Authorization: 'Bearer ' + obj[target].at
|
||||
const start = `https://${domain}/api/v1/accounts/verify_credentials`
|
||||
let json
|
||||
try {
|
||||
json = await getApi(start, at)
|
||||
} catch {
|
||||
return false
|
||||
}
|
||||
if (json.error) {
|
||||
console.error('Error:' + json.error)
|
||||
M.toast({ html: lang.lang_fatalerroroccured + 'Error:' + json.error, displayLength: 5000 })
|
||||
return
|
||||
}
|
||||
if (!json) return false
|
||||
let avatar = json['avatar']
|
||||
//missingがmissingなやつ
|
||||
if (avatar == '/avatars/original/missing.png' || !avatar) {
|
||||
avatar = './img/missing.svg'
|
||||
}
|
||||
const newName = json.display_name
|
||||
const newProf = avatar
|
||||
const newVis = json.source.privacy
|
||||
if (newName != name || newProf != prof || newVis != vis) {
|
||||
let ref = {
|
||||
at: at,
|
||||
name: newName,
|
||||
domain: domain,
|
||||
user: json['acct'],
|
||||
prof: avatar,
|
||||
id: json['id'],
|
||||
vis: newVis
|
||||
}
|
||||
})
|
||||
.then(function(response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
}
|
||||
return response.json()
|
||||
})
|
||||
.catch(function(error) {
|
||||
todo(error)
|
||||
setLog(start, 'JSON', error)
|
||||
console.error(error)
|
||||
})
|
||||
.then(function(json) {
|
||||
if (json.error) {
|
||||
console.error('Error:' + json.error)
|
||||
M.toast({ html: lang.lang_fatalerroroccured + 'Error:' + json.error, displayLength: 5000 })
|
||||
return
|
||||
}
|
||||
var avatar = json['avatar']
|
||||
//missingがmissingなやつ
|
||||
if (avatar == '/avatars/original/missing.png' || !avatar) {
|
||||
avatar = './img/missing.svg'
|
||||
}
|
||||
var ref = {
|
||||
at: obj[target].at,
|
||||
name: json['display_name'],
|
||||
domain: obj[target].domain,
|
||||
user: json['acct'],
|
||||
prof: avatar,
|
||||
id: json['id'],
|
||||
vis: json['source']['privacy']
|
||||
}
|
||||
if (obj[target].background) {
|
||||
ref.background = obj[target].background
|
||||
}
|
||||
if (obj[target].text) {
|
||||
ref.text = obj[target].text
|
||||
}
|
||||
localStorage.setItem('name_' + target, json['display_name'])
|
||||
localStorage.setItem('user_' + target, json['acct'])
|
||||
localStorage.setItem('user-id_' + target, json['id'])
|
||||
localStorage.setItem('prof_' + target, avatar)
|
||||
localStorage.setItem('follow_' + target, json['following_count'])
|
||||
if (json['source']['sensitive']) {
|
||||
localStorage.setItem('nsfw_' + target, 'true')
|
||||
} else {
|
||||
localStorage.removeItem('nsfw_' + target)
|
||||
}
|
||||
obj[target] = ref
|
||||
var json = JSON.stringify(obj)
|
||||
localStorage.setItem('multi', json)
|
||||
if (!loadskip) {
|
||||
load()
|
||||
}
|
||||
})
|
||||
if (background) {
|
||||
ref.background = background
|
||||
}
|
||||
if (text) {
|
||||
ref.text = text
|
||||
}
|
||||
if (json['source']['sensitive']) {
|
||||
localStorage.setItem('nsfw_' + target, true)
|
||||
} else {
|
||||
localStorage.removeItem('nsfw_' + target)
|
||||
}
|
||||
obj[target] = ref
|
||||
const save = JSON.stringify(obj)
|
||||
localStorage.setItem('multi', save)
|
||||
requireReload = true
|
||||
}
|
||||
if (!loadskip) {
|
||||
load()
|
||||
} else {
|
||||
return requireReload
|
||||
}
|
||||
}
|
||||
//MarkdownやBBCodeの対応、文字数制限をチェック
|
||||
//絶対ストリーミングを閉じさせないマン
|
||||
function ckdb(acct_id) {
|
||||
var domain = localStorage.getItem('domain_' + acct_id)
|
||||
localStorage.removeItem('home_' + acct_id)
|
||||
localStorage.removeItem('bb_' + acct_id)
|
||||
localStorage.removeItem('md_' + acct_id)
|
||||
localStorage.removeItem('local_' + acct_id)
|
||||
localStorage.removeItem('public_' + acct_id)
|
||||
localStorage.removeItem('notification_' + acct_id)
|
||||
localStorage.removeItem('post_' + acct_id)
|
||||
localStorage.removeItem('fav_' + acct_id)
|
||||
localStorage.removeItem('bt_' + acct_id)
|
||||
localStorage.removeItem('followlocale_' + acct_id)
|
||||
async function ckdb(acct_id) {
|
||||
const domain = localStorage.getItem(`domain_${acct_id}`)
|
||||
if (domain == 'kirishima.cloud') {
|
||||
localStorage.setItem('kirishima', 'true')
|
||||
localStorage.setItem('kirishima', true)
|
||||
} else if (domain == 'imastodon.net') {
|
||||
localStorage.setItem('imas', 'true')
|
||||
$('.imasonly').show()
|
||||
localStorage.setItem('imas', true)
|
||||
showElm('.imasonly')
|
||||
}
|
||||
var at = localStorage.getItem('acct_' + acct_id + '_at')
|
||||
var bbcode = domain + '_bbcode'
|
||||
var letters = domain + '_letters'
|
||||
var quoteMarker = domain + '_quote'
|
||||
if (localStorage.getItem('instance')) {
|
||||
var json = JSON.parse(localStorage.getItem('instance'))
|
||||
if (json[quoteMarker] == 'enabled') {
|
||||
localStorage.setItem('quoters', 'true')
|
||||
localStorage.setItem('quote_' + acct_id, 'true')
|
||||
}
|
||||
if (json[bbcode]) {
|
||||
if (json[bbcode] == 'enabled') {
|
||||
localStorage.setItem('bb_' + acct_id, 'true')
|
||||
} else {
|
||||
localStorage.removeItem('bb_' + acct_id)
|
||||
$("[data-activates='bbcode']").addClass('disabled')
|
||||
$("[data-activates='bbcode']").prop('disabled', true)
|
||||
}
|
||||
} else {
|
||||
localStorage.removeItem('bb_' + acct_id)
|
||||
$("[data-activates='bbcode']").addClass('disabled')
|
||||
$("[data-activates='bbcode']").addClass('disabled', true)
|
||||
}
|
||||
const at = localStorage.getItem(`acct_${acct_id}_at`)
|
||||
const letters = `${domain}_letters`
|
||||
const quoteMarker = `${domain}_quote`
|
||||
|
||||
if (json[domain + '_markdown'] == 'enabled') {
|
||||
localStorage.setItem('md_' + acct_id, 'true')
|
||||
$('.markdown').show()
|
||||
} else {
|
||||
$('.anti-markdown').hide()
|
||||
$('.markdown').hide()
|
||||
localStorage.removeItem('bb_' + acct_id)
|
||||
}
|
||||
if (json[domain + '_home']) {
|
||||
localStorage.setItem('home_' + acct_id, json[domain + '_home'])
|
||||
}
|
||||
if (json[domain + '_local']) {
|
||||
localStorage.setItem('local_' + acct_id, json[domain + '_local'])
|
||||
}
|
||||
if (json[domain + '_public']) {
|
||||
localStorage.setItem('public_' + acct_id, json[domain + '_public'])
|
||||
}
|
||||
if (json[domain + '_notification']) {
|
||||
localStorage.setItem('notification_' + acct_id, json[domain + '_notification'])
|
||||
}
|
||||
if (json[domain + '_post']) {
|
||||
localStorage.setItem('post_' + acct_id, json[domain + '_post'])
|
||||
}
|
||||
if (json[domain + '_fav']) {
|
||||
localStorage.setItem('fav_' + acct_id, json[domain + '_fav'])
|
||||
}
|
||||
if (json[domain + '_bt']) {
|
||||
localStorage.setItem('bt_' + acct_id, json[domain + '_bt'])
|
||||
}
|
||||
if (json[domain + '_follow']) {
|
||||
localStorage.setItem('followlocale_' + acct_id, json[domain + '_follow'])
|
||||
if (idata) {
|
||||
//check and replace json to idata
|
||||
const json = idata
|
||||
if (json[quoteMarker] == 'enabled') {
|
||||
localStorage.setItem('quoters', true)
|
||||
localStorage.setItem(quoteMarker, true)
|
||||
}
|
||||
}
|
||||
if (localStorage.getItem('mode_' + domain) != 'misskey') {
|
||||
var start = 'https://' + domain + '/api/v1/instance'
|
||||
fetch(start, {
|
||||
method: 'GET',
|
||||
headers: {
|
||||
'content-type': 'application/json'
|
||||
}
|
||||
})
|
||||
.then(function(response) {
|
||||
return response.json()
|
||||
})
|
||||
.catch(function(error) {
|
||||
console.error(error)
|
||||
})
|
||||
.then(function(json) {
|
||||
if (json.error) {
|
||||
console.error(json.error)
|
||||
return
|
||||
}
|
||||
if (json) {
|
||||
if (json['max_toot_chars']) {
|
||||
localStorage.setItem('letters_' + acct_id, json['max_toot_chars'])
|
||||
}
|
||||
if (json['urls']['streaming_api']) {
|
||||
localStorage.setItem('streaming_' + acct_id, json['urls']['streaming_api'])
|
||||
} else {
|
||||
localStorage.removeItem('streaming_' + acct_id)
|
||||
}
|
||||
}
|
||||
})
|
||||
} else {
|
||||
if (!isMisskey(domain)) {
|
||||
const start = `https://${domain}/api/v1/instance`
|
||||
let json
|
||||
try {
|
||||
json = await getApi(start, null)
|
||||
} catch {
|
||||
return null
|
||||
}
|
||||
if (!json || json.error) {
|
||||
return
|
||||
}
|
||||
const mtc = json['max_toot_chars']
|
||||
if (mtc) {
|
||||
localStorage.setItem(letters, mtc)
|
||||
}
|
||||
if (json['feature_quote']) {
|
||||
localStorage.setItem(quoteMarker, true)
|
||||
}
|
||||
const str = json['urls']['streaming_api']
|
||||
if (str) {
|
||||
localStorage.setItem(`streaming_${domain}`, str)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//アカウントを選択…を実装
|
||||
function multiSelector(parseC) {
|
||||
var multi = localStorage.getItem('multi')
|
||||
if (!multi) {
|
||||
var obj = []
|
||||
var json = JSON.stringify(obj)
|
||||
localStorage.setItem('multi', json)
|
||||
} else {
|
||||
var obj = JSON.parse(multi)
|
||||
}
|
||||
var templete
|
||||
function multiSelector() {
|
||||
let obj = acctList
|
||||
//if (!obj) obj = JSON.parse(localStorage.getItem('multi'))
|
||||
let template = ''
|
||||
//StringなのはlocalStorageがStringしか返さないから
|
||||
let lastUsed = '0'
|
||||
if (localStorage.getItem('mainuse') == 'main') {
|
||||
var last = localStorage.getItem('main')
|
||||
lastUsed = localStorage.getItem('main')
|
||||
} else if (localStorage.getItem('last-use')) {
|
||||
var last = localStorage.getItem('last-use')
|
||||
if (last == 'webview' || last == 'noauth') {
|
||||
last = '0'
|
||||
lastUsed = localStorage.getItem('last-use')
|
||||
if (lastUsed == 'webview' || lastUsed == 'noauth') {
|
||||
lastUsed = '0'
|
||||
}
|
||||
} else {
|
||||
var last = '0'
|
||||
lastUsed = '0'
|
||||
}
|
||||
last = last + ''
|
||||
var sel
|
||||
let sel
|
||||
if (obj.length < 1) {
|
||||
$('#src-acct-sel').html('<option value="tootsearch">Tootsearch</option>')
|
||||
$('#add-acct-sel').html('<option value="noauth">' + lang.lang_login_noauth + '</option>')
|
||||
document.querySelector('#src-acct-sel').innerHTML = '<option value="tootsearch">Tootsearch</option>'
|
||||
document.querySelector('#add-acct-sel').innerHTML = `<option value="noauth">${lang.lang_login_noauth}</option>`
|
||||
} else {
|
||||
Object.keys(obj).forEach(function(key) {
|
||||
var acct = obj[key]
|
||||
var list = key * 1 + 1
|
||||
if (key + '' === last) {
|
||||
for (let i = 0; i < obj.length; i++) {
|
||||
const acct = obj[i]
|
||||
const strKey = i.toString()
|
||||
if (strKey == lastUsed) {
|
||||
sel = 'selected'
|
||||
var domain = acct.domain
|
||||
localStorage.setItem('domain_' + key, domain)
|
||||
if (idata[domain + '_letters']) {
|
||||
$('#textarea').attr('data-length', idata[domain + '_letters'])
|
||||
const domain = acct.domain
|
||||
const letters = idata[`${domain}_letters`]
|
||||
const textarea = document.querySelector('#textarea')
|
||||
if (letters) {
|
||||
textarea.setAttribute('data-length', letters)
|
||||
} else {
|
||||
var maxletters = localStorage.getItem('letters_' + key)
|
||||
if (maxletters > 0) {
|
||||
$('#textarea').attr('data-length', maxletters)
|
||||
//手動でアカマネで変えれちゃうから
|
||||
const maxLetters = localStorage.getItem(`${domain}_letters`)
|
||||
if (maxLetters > 0) {
|
||||
textarea.setAttribute('data-length', maxLetters)
|
||||
} else {
|
||||
$('#textarea').attr('data-length', 500)
|
||||
textarea.setAttribute('data-length', 500)
|
||||
}
|
||||
}
|
||||
if (idata[domain + '_glitch']) {
|
||||
$('#local-button').removeClass('hide')
|
||||
if (idata[`${domain}_glitch`]) {
|
||||
document.querySelector('#local-button').classList.remove('hide')
|
||||
}
|
||||
var profimg = acct.prof
|
||||
//localStorage.setItem("prof_" + key, profimg);
|
||||
let profimg = acct.prof
|
||||
if (!profimg) {
|
||||
profimg = '../../img/missing.svg'
|
||||
}
|
||||
$('#acct-sel-prof').attr('src', profimg)
|
||||
document.querySelector('#acct-sel-prof').setAttribute('src', profimg)
|
||||
let cc = ''
|
||||
if (domain) {
|
||||
var cc = '(' + domain + ')'
|
||||
} else {
|
||||
var cc = ''
|
||||
cc = `(${domain})`
|
||||
}
|
||||
$('#toot-post-btn').text(lang.lang_toot + cc)
|
||||
const tpb = document.querySelector('#toot-post-btn')
|
||||
tpb.innerText = lang.lang_toot + cc
|
||||
if (acct.background && acct.background != 'def' && acct.text && acct.text != 'def') {
|
||||
$('#toot-post-btn').removeClass('indigo')
|
||||
$('#toot-post-btn').css('background-color', '#' + acct.background)
|
||||
$('#toot-post-btn').css('color', acct.text)
|
||||
} else {
|
||||
}
|
||||
if (domain == 'kirishima.cloud') {
|
||||
$('#faicon-btn').show()
|
||||
} else {
|
||||
$('#faicon-btn').hide()
|
||||
tpb.classList.remove('indigo')
|
||||
tpb.style.backgroundColor = `#${acct.background}`
|
||||
tpb.style.color = `#${acct.text}`
|
||||
}
|
||||
if (domain == 'imastodon.net') {
|
||||
trendTag()
|
||||
} else {
|
||||
$('#trendtag').html('')
|
||||
if (document.querySelector('#trendtag')) document.querySelector('#trendtag').innerHTML = ''
|
||||
}
|
||||
} else {
|
||||
sel = ''
|
||||
}
|
||||
templete =
|
||||
'<option value="' +
|
||||
key +
|
||||
'" data-icon="' +
|
||||
acct.prof +
|
||||
'" class="left circle" ' +
|
||||
sel +
|
||||
'>' +
|
||||
acct.user +
|
||||
'@' +
|
||||
acct.domain +
|
||||
'</option>'
|
||||
$('.acct-sel').append(templete)
|
||||
})
|
||||
$('#src-acct-sel').append('<option value="tootsearch">Tootsearch</option>')
|
||||
$('#add-acct-sel').append(
|
||||
'<option value="noauth">' +
|
||||
lang.lang_login_noauth +
|
||||
'</option><option value="webview">Twitter</option>'
|
||||
)
|
||||
$('#dir-acct-sel').append('<option value="noauth">' + lang.lang_login_noauth + '</option>')
|
||||
template = template + `
|
||||
<option value="${strKey}" data-icon="${acct.prof}" class="left circle" ${sel}>@${acct.user}@${acct.domain}
|
||||
</option>
|
||||
`
|
||||
}
|
||||
const forSrc = template + '<option value="tootsearch">Tootsearch</option>'
|
||||
const forAdd = template + `
|
||||
<option value="noauth">${lang.lang_login_noauth}</option>
|
||||
<option value="webview">Twitter</option>
|
||||
`
|
||||
const forDir = template + `<option value="noauth">${lang.lang_login_noauth}</option>`
|
||||
document.querySelector('#post-acct-sel').innerHTML = template
|
||||
document.querySelector('#list-acct-sel').innerHTML = template
|
||||
document.querySelector('#filter-acct-sel').innerHTML = template
|
||||
document.querySelector('#src-acct-sel').innerHTML = forSrc
|
||||
document.querySelector('#add-acct-sel').innerHTML = forAdd
|
||||
document.querySelector('#dir-acct-sel').innerHTML = forDir
|
||||
}
|
||||
$('select').formSelect()
|
||||
if (!parseC) {
|
||||
parseColumn(null, true)
|
||||
}
|
||||
}
|
||||
|
||||
//バージョンエンコ
|
||||
function enc(ver) {
|
||||
var ver = ver.replace(/\s/g, '')
|
||||
var ver = ver.replace(/\(/g, '-')
|
||||
var ver = ver.replace(/\)/g, '')
|
||||
var ver = ver.replace(/\[/g, '_')
|
||||
var ver = ver.replace(/\]/g, '')
|
||||
return ver
|
||||
const elems = document.querySelectorAll('select')
|
||||
M.FormSelect.init(elems, null)
|
||||
}
|
||||
//インスタンスティッカー
|
||||
function ticker() {
|
||||
var start = 'https://s.0px.io/json'
|
||||
fetch(start, {
|
||||
method: 'GET',
|
||||
cors: true,
|
||||
headers: {
|
||||
'content-type': 'application/json'
|
||||
}
|
||||
})
|
||||
.then(function(response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
}
|
||||
return response.json()
|
||||
})
|
||||
.catch(function(error) {
|
||||
console.error(error)
|
||||
})
|
||||
.then(function(json) {
|
||||
if (json) {
|
||||
localStorage.removeItem('ticker')
|
||||
localStorage.setItem('sticker', JSON.stringify(json))
|
||||
}
|
||||
})
|
||||
async function ticker() {
|
||||
const start = 'https://toot-app.thedesk.top/toot/index.php'
|
||||
const json = await getApi(start, null)
|
||||
if (json) localStorage.setItem('ticker', JSON.stringify(json))
|
||||
}
|
||||
function isMisskey(domain) {
|
||||
return localStorage.getItem(`mode_${domain}`) == 'misskey'
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
//ログアウトします
|
||||
function logout() {
|
||||
localStorage.removeItem("acct_" + acct_id + "_at")
|
||||
localStorage.removeItem("domain_" + acct_id)
|
||||
location.href = "index.html"
|
||||
localStorage.removeItem(`acct_${acct_id}_at`)
|
||||
localStorage.removeItem(`domain_${acct_id}`)
|
||||
location.href = 'index.html'
|
||||
todc()
|
||||
}
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -130,11 +130,17 @@ function playSound() {
|
||||
volumeControl.gain.value = vol
|
||||
source.start(0)
|
||||
soundFile = source
|
||||
|
||||
function newFunction() {
|
||||
var source
|
||||
return source
|
||||
}
|
||||
}
|
||||
function nano() {
|
||||
postMessage(['nano', null], '*')
|
||||
}
|
||||
onmessage = function(e) {
|
||||
console.log(e)
|
||||
if (e.data[0] == 'details') {
|
||||
details(e.data[1][0], e.data[1][1])
|
||||
} else if (e.data[0] == 'udg') {
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
$.strip_tags = function(str, allowed) {
|
||||
$.strip_tags = function (str, allowed) {
|
||||
if (!str) {
|
||||
return ''
|
||||
}
|
||||
allowed = (((allowed || '') + '').toLowerCase().match(/<[a-z][a-z0-9]*>/g) || []).join('')
|
||||
var tags = /<\/?([a-z][a-z0-9]*)\b[^>]*>?/gi,
|
||||
commentsAndPhpTags = /<!--[\s\S]*?-->|<\?(?:php)?[\s\S]*?\?>/gi
|
||||
return str.replace(commentsAndPhpTags, '').replace(tags, function($0, $1) {
|
||||
return str.replace(commentsAndPhpTags, '').replace(tags, function ($0, $1) {
|
||||
return allowed.indexOf('<' + $1.toLowerCase() + '>') > -1 ? $0 : ''
|
||||
})
|
||||
}
|
||||
@@ -13,12 +13,7 @@ function escapeHTML(str) {
|
||||
if (!str) {
|
||||
return ''
|
||||
}
|
||||
return str
|
||||
.replace(/&/g, '&')
|
||||
.replace(/</g, '<')
|
||||
.replace(/>/g, '>')
|
||||
.replace(/"/g, '"')
|
||||
.replace(/'/g, ''')
|
||||
return str.replace(/&/g, '&').replace(/</g, '<').replace(/>/g, '>').replace(/"/g, '"').replace(/'/g, ''')
|
||||
}
|
||||
//PHPのnl2brと同様
|
||||
function nl2br(str) {
|
||||
@@ -88,17 +83,18 @@ function formattimeutc(date) {
|
||||
}
|
||||
postMessage(['sendSinmpleIpc', 'custom-css-request'], '*')
|
||||
function makeCID() {
|
||||
return (
|
||||
randomStr(8) +
|
||||
'-' +
|
||||
randomStr(4) +
|
||||
'-' +
|
||||
randomStr(4) +
|
||||
'-' +
|
||||
randomStr(4) +
|
||||
'-' +
|
||||
randomStr(12)
|
||||
)
|
||||
let chars = 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.split('')
|
||||
for (let i = 0, len = chars.length; i < len; i++) {
|
||||
switch (chars[i]) {
|
||||
case 'x':
|
||||
chars[i] = Math.floor(Math.random() * 16).toString(16)
|
||||
break
|
||||
case 'y':
|
||||
chars[i] = (Math.floor(Math.random() * 4) + 8).toString(16)
|
||||
break
|
||||
}
|
||||
}
|
||||
return chars.join('')
|
||||
}
|
||||
function randomStr(l) {
|
||||
// 生成する文字列に含める文字セット
|
||||
@@ -129,7 +125,7 @@ function rgbToHex(color) {
|
||||
// RGBからHEXへ変換
|
||||
parseInt(regex[1]).toString(16),
|
||||
parseInt(regex[2]).toString(16),
|
||||
parseInt(regex[3]).toString(16)
|
||||
parseInt(regex[3]).toString(16),
|
||||
]
|
||||
|
||||
for (var i = 0; i < rgb.length; ++i) {
|
||||
@@ -147,15 +143,15 @@ function rgbToHex(color) {
|
||||
console.error(color + ':第1引数はRGB形式で入力')
|
||||
}
|
||||
/*マルチバイト用切り出し*/
|
||||
$.isSurrogatePear = function(upper, lower) {
|
||||
$.isSurrogatePear = function (upper, lower) {
|
||||
return 0xd800 <= upper && upper <= 0xdbff && 0xdc00 <= lower && lower <= 0xdfff
|
||||
}
|
||||
$.mb_strlen = function(str) {
|
||||
$.mb_strlen = function (str) {
|
||||
var splitter = new GraphemeSplitter()
|
||||
var arr = splitter.splitGraphemes(str)
|
||||
return arr.length
|
||||
}
|
||||
$.mb_substr = function(str, begin, end) {
|
||||
$.mb_substr = function (str, begin, end) {
|
||||
//配列にする
|
||||
var splitter = new GraphemeSplitter()
|
||||
var arr = splitter.splitGraphemes(str)
|
||||
@@ -175,7 +171,7 @@ function object_array_sort(data, key, order, fn) {
|
||||
num_a = 1
|
||||
num_b = -1
|
||||
}
|
||||
data = data.sort(function(a, b) {
|
||||
data = data.sort(function (a, b) {
|
||||
var x = a[key]
|
||||
var y = b[key]
|
||||
if (x > y) return num_a
|
||||
@@ -252,7 +248,7 @@ function statusModel(now) {
|
||||
reblog: null,
|
||||
application: {
|
||||
name: null,
|
||||
website: null
|
||||
website: null,
|
||||
},
|
||||
account: {
|
||||
id: '',
|
||||
@@ -273,12 +269,53 @@ function statusModel(now) {
|
||||
statuses_count: 0,
|
||||
last_status_at: now,
|
||||
emojis: [],
|
||||
fields: []
|
||||
fields: [],
|
||||
},
|
||||
media_attachments: [],
|
||||
mentions: [],
|
||||
tags: [],
|
||||
card: null,
|
||||
poll: null
|
||||
poll: null,
|
||||
}
|
||||
}
|
||||
|
||||
function isFocused(query) {
|
||||
const allTarget = document.querySelectorAll(query)
|
||||
const active = document.activeElement
|
||||
let is = false
|
||||
for (let i = 0; i < allTarget.length; i++) {
|
||||
if (allTarget[i] == active) {
|
||||
is = true
|
||||
break
|
||||
}
|
||||
}
|
||||
return is
|
||||
}
|
||||
function getHeight(query) {
|
||||
const elm = document.querySelector(query)
|
||||
return parseFloat(getComputedStyle(elm, null).height.replace('px', ''))
|
||||
}
|
||||
function showElm(query) {
|
||||
const allTarget = document.querySelectorAll(query)
|
||||
for (let i = 0; i < allTarget.length; i++) {
|
||||
const target = allTarget[i]
|
||||
target.style.display = 'inherit'
|
||||
}
|
||||
}
|
||||
function setAllClasses(query, className, action) {
|
||||
const allTarget = document.querySelectorAll(query)
|
||||
for (let i = 0; i < allTarget.length; i++) {
|
||||
const target = allTarget[i]
|
||||
if (action == 'add') target.classList.add(className)
|
||||
if (action == 'remove') target.classList.remove(className)
|
||||
}
|
||||
}
|
||||
function appendPrepend(query, elm, action) {
|
||||
const allTarget = document.querySelectorAll(query)
|
||||
for (let i = 0; i < allTarget.length; i++) {
|
||||
const target = allTarget[i]
|
||||
if (action == 'prepend') target.insertBefore(elm, target.firstChild)
|
||||
if (action == 'append') target.appendChild(document.createTextNode(elm))
|
||||
}
|
||||
}
|
||||
const sleep = (msec) => new Promise((resolve) => setTimeout(resolve, msec))
|
||||
|
||||
@@ -2,11 +2,12 @@
|
||||
//アカウント変えた時にBBとかMDとか
|
||||
function mdCheck() {
|
||||
var acct_id = $('#post-acct-sel').val()
|
||||
var profimg = localStorage.getItem('prof_' + acct_id)
|
||||
/*var profimg = localStorage.getItem('prof_' + acct_id)
|
||||
if (!profimg) {
|
||||
profimg = '../../img/missing.svg'
|
||||
}
|
||||
$('#acct-sel-prof').attr('src', profimg)
|
||||
*/
|
||||
if (localStorage.getItem('post_' + acct_id)) {
|
||||
$('#toot-post-btn').text(
|
||||
localStorage.getItem('post_' + acct_id) +
|
||||
@@ -50,7 +51,7 @@ function mdCheck() {
|
||||
if (idata[domain + '_letters']) {
|
||||
$('#textarea').attr('data-length', idata[domain + '_letters'])
|
||||
} else {
|
||||
var maxletters = localStorage.getItem('letters_' + acct_id)
|
||||
var maxletters = localStorage.getItem(domain + 'letters_')
|
||||
if (maxletters > 0) {
|
||||
$('#textarea').attr('data-length', maxletters)
|
||||
} else {
|
||||
|
||||
@@ -108,7 +108,6 @@ async function media(b64, type, no, stamped) {
|
||||
}
|
||||
$('.toot-btn-group').prop('disabled', true)
|
||||
$('#post-acct-sel').prop('disabled', true)
|
||||
localStorage.setItem('image', 'busy')
|
||||
todo('Image Upload...')
|
||||
var media = toBlob(b64, type)
|
||||
var fd = new FormData()
|
||||
@@ -159,7 +158,6 @@ async function media(b64, type, no, stamped) {
|
||||
M.toast({ html: '<span>' + lang.lang_postimg_sync + '</span><button class="btn-flat toast-action" onclick="syncDetail()">Click</button>', displayLength: 3000 })
|
||||
$('#imgup').text('')
|
||||
$('#imgsel').show()
|
||||
localStorage.removeItem('image')
|
||||
}
|
||||
} catch {
|
||||
var start = 'https://' + domain + '/api/v1/media'
|
||||
|
||||
@@ -342,7 +342,6 @@ function clear() {
|
||||
$('.mastodon-choice').map(function() {
|
||||
$(this).val('')
|
||||
})
|
||||
localStorage.removeItem('image')
|
||||
if (localStorage.getItem('mainuse') == 'main') {
|
||||
$('#post-acct-sel').val(localStorage.getItem('main'))
|
||||
}
|
||||
|
||||
@@ -680,8 +680,7 @@ function staEx(mode) {
|
||||
})
|
||||
return
|
||||
}
|
||||
function toggleAction(elem, ct) {
|
||||
var height = ct * 39 + 6
|
||||
function toggleAction(elem, height) {
|
||||
var cont = elem.parents('.cvo').find('.contextMenu')
|
||||
if (cont.hasClass('hide')) {
|
||||
$('#contextWrap').removeClass('hide')
|
||||
@@ -692,7 +691,6 @@ function toggleAction(elem, ct) {
|
||||
cont.removeClass('bottom')
|
||||
cont.addClass('top')
|
||||
} else {
|
||||
top = elem.offset().top - 105
|
||||
cont.removeClass('top')
|
||||
cont.addClass('bottom')
|
||||
}
|
||||
|
||||
@@ -1,98 +1,95 @@
|
||||
//日付パーサー
|
||||
function date(str, datetype, lastStatus) {
|
||||
if (lastStatus) {
|
||||
var date = new Date(str)
|
||||
return date.getFullYear() + "/" + (date.getMonth() + 1) + "/" + date.getDate()
|
||||
} else if (datetype == "relative") {
|
||||
return '<time class="timeago" datetime="' + str + '"></time>'
|
||||
function date(str, datetype) {
|
||||
if (datetype == "relative") {
|
||||
return '<time class="timeago" datetime="' + str + '"></time>';
|
||||
} else {
|
||||
var date = new Date(str)
|
||||
var date = new Date(str);
|
||||
if (datetype == "unix") {
|
||||
var unixm = date.getTime()
|
||||
return Math.floor(unixm / 1000)
|
||||
var unixm = date.getTime();
|
||||
return Math.floor(unixm / 1000);
|
||||
}
|
||||
var now = new Date()
|
||||
var month = date.getMonth() + 1
|
||||
var now = new Date();
|
||||
var month = date.getMonth() + 1;
|
||||
if (date.getMinutes() < 10) {
|
||||
var min = "0" + date.getMinutes()
|
||||
var min = "0" + date.getMinutes();
|
||||
} else {
|
||||
var min = date.getMinutes()
|
||||
var min = date.getMinutes();
|
||||
}
|
||||
var sec = null
|
||||
var sec = null;
|
||||
if (date.getSeconds() < 10) {
|
||||
sec = "0" + date.getSeconds()
|
||||
sec = "0" + date.getSeconds();
|
||||
} else {
|
||||
sec = date.getSeconds()
|
||||
sec = date.getSeconds();
|
||||
}
|
||||
if (datetype == "full") {
|
||||
var ret = date.getFullYear() + "/" + month + "/" + date.getDate() + "/ " +
|
||||
date.getHours() + ":" + min + ":" + sec
|
||||
date.getHours() + ":" + min + ":" + sec;
|
||||
}
|
||||
if (date.getFullYear() == now.getFullYear()) {
|
||||
if (date.getMonth() == now.getMonth()) {
|
||||
if (date.getDate() == now.getDate()) {
|
||||
if (datetype == "medium") {
|
||||
var ret = '<time class="timeago" datetime="' + str + '"></time>'
|
||||
var ret = '<time class="timeago" datetime="' + str + '"></time>';
|
||||
} else {
|
||||
var ret = date.getHours() + ":" + min + ":" + sec
|
||||
var ret = date.getHours() + ":" + min + ":" + sec;
|
||||
}
|
||||
|
||||
} else {
|
||||
var ret = month + "/" + date.getDate() + " " + date.getHours() + ":" +
|
||||
min + ":" + sec
|
||||
min + ":" + sec;
|
||||
}
|
||||
} else {
|
||||
var ret = month + "/" + date.getDate() + " " + date.getHours() + ":" + min +
|
||||
":" + sec
|
||||
":" + sec;
|
||||
}
|
||||
} else {
|
||||
var ret = date.getFullYear() + "/" + month + "/" + date.getDate() + " " +
|
||||
date.getHours() + ":" + min + ":" + sec
|
||||
date.getHours() + ":" + min + ":" + sec;
|
||||
}
|
||||
if (datetype == "double") {
|
||||
return '<time class="timeago" datetime="' + str + '"></time>/' + ret
|
||||
return '<time class="timeago" datetime="' + str + '"></time>/' + ret;
|
||||
} else {
|
||||
return ret
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//特殊フォーマット(インスタンス情報で利用)
|
||||
function crat(str) {
|
||||
var date = new Date(str)
|
||||
var mnt = null
|
||||
var date = new Date(str);
|
||||
var mnt = null;
|
||||
if (date.getMonth() < 9) {
|
||||
mnt = "0" + (date.getMonth() + 1)
|
||||
mnt = "0" + (date.getMonth() + 1);
|
||||
} else {
|
||||
mnt = date.getMonth() + 1
|
||||
mnt = date.getMonth() + 1;
|
||||
}
|
||||
if (date.getDate() < 10) {
|
||||
var dat = "0" + date.getDate()
|
||||
var dat = "0" + date.getDate();
|
||||
} else {
|
||||
var dat = date.getDate()
|
||||
var dat = date.getDate();
|
||||
}
|
||||
if (date.getHours() < 10) {
|
||||
var hrs = "0" + date.getHours()
|
||||
var hrs = "0" + date.getHours();
|
||||
} else {
|
||||
var hrs = date.getHours()
|
||||
var hrs = date.getHours();
|
||||
}
|
||||
if (date.getMinutes() < 10) {
|
||||
var mns = "0" + date.getMinutes()
|
||||
var mns = "0" + date.getMinutes();
|
||||
} else {
|
||||
var mns = date.getMinutes()
|
||||
var mns = date.getMinutes();
|
||||
}
|
||||
if (date.getSeconds() < 10) {
|
||||
var sec = "0" + date.getSeconds()
|
||||
var sec = "0" + date.getSeconds();
|
||||
} else {
|
||||
var sec = date.getSeconds()
|
||||
var sec = date.getSeconds();
|
||||
}
|
||||
format_str = 'YYYY-MM-DD hh:mm:ss'
|
||||
format_str = format_str.replace(/YYYY/g, date.getFullYear())
|
||||
format_str = format_str.replace(/MM/g, mnt)
|
||||
format_str = format_str.replace(/DD/g, dat)
|
||||
format_str = format_str.replace(/hh/g, hrs)
|
||||
format_str = format_str.replace(/mm/g, mns)
|
||||
format_str = format_str.replace(/ss/g, sec)
|
||||
format_str = 'YYYY-MM-DD hh:mm:ss';
|
||||
format_str = format_str.replace(/YYYY/g, date.getFullYear());
|
||||
format_str = format_str.replace(/MM/g, mnt);
|
||||
format_str = format_str.replace(/DD/g, dat);
|
||||
format_str = format_str.replace(/hh/g, hrs);
|
||||
format_str = format_str.replace(/mm/g, mns);
|
||||
format_str = format_str.replace(/ss/g, sec);
|
||||
|
||||
return format_str
|
||||
return format_str;
|
||||
}
|
||||
|
||||
@@ -1,49 +1,49 @@
|
||||
//ディレクトリ
|
||||
//ディレクトリトグル
|
||||
function dirMenu() {
|
||||
$("#dir-contents").html("")
|
||||
directory()
|
||||
$("#left-menu a").removeClass("active")
|
||||
$("#dirMenu").addClass("active")
|
||||
$(".menu-content").addClass("hide")
|
||||
$("#dir-box").removeClass("hide")
|
||||
$("#dir-contents").html("");
|
||||
directory();
|
||||
$("#left-menu a").removeClass("active");
|
||||
$("#dirMenu").addClass("active");
|
||||
$(".menu-content").addClass("hide");
|
||||
$("#dir-box").removeClass("hide");
|
||||
}
|
||||
function dirselCk() {
|
||||
var acct = $("#dir-acct-sel").val()
|
||||
var acct = $("#dir-acct-sel").val();
|
||||
if (acct == "noauth") {
|
||||
$("#dirNoAuth").removeClass("hide")
|
||||
$("#dirNoAuth").removeClass("hide");
|
||||
} else {
|
||||
$("#dirNoAuth").addClass("hide")
|
||||
directory()
|
||||
$("#dirNoAuth").addClass("hide");
|
||||
directory();
|
||||
}
|
||||
}
|
||||
function directory(isMore) {
|
||||
var order = $("[name=sort]:checked").val()
|
||||
var order = $("[name=sort]:checked").val();
|
||||
if (!order) {
|
||||
order = "active"
|
||||
order = "active";
|
||||
}
|
||||
var local_only = $("#local_only:checked").val()
|
||||
var local_only = $("#local_only:checked").val();
|
||||
if (local_only) {
|
||||
local_only = "true"
|
||||
local_only = "true";
|
||||
} else {
|
||||
local_only = "false"
|
||||
local_only = "false";
|
||||
}
|
||||
var acct_id = $("#dir-acct-sel").val()
|
||||
var acct_id = $("#dir-acct-sel").val();
|
||||
if (acct_id == "noauth") {
|
||||
var domain = $("#dirNoAuth-url").val()
|
||||
var at = ""
|
||||
var domain = $("#dirNoAuth-url").val();
|
||||
var at = "";
|
||||
} else {
|
||||
var domain = localStorage.getItem("domain_" + acct_id)
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at")
|
||||
var domain = localStorage.getItem("domain_" + acct_id);
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at");
|
||||
}
|
||||
if (isMore) {
|
||||
var addOffset = $("#dir-contents .cvo").length
|
||||
var addOffset = $("#dir-contents .cvo").length;
|
||||
} else {
|
||||
var addOffset = 0
|
||||
$("#dir-contents").html("")
|
||||
var addOffset = 0;
|
||||
$("#dir-contents").html("");
|
||||
}
|
||||
var start = "https://" + domain + "/api/v1/directory?order=" + order + "&local=" + local_only + "&offset=" + addOffset
|
||||
console.log(start)
|
||||
var start = "https://" + domain + "/api/v1/directory?order=" + order + "&local=" + local_only + "&offset=" + addOffset;
|
||||
console.log(start);
|
||||
fetch(start, {
|
||||
method: "GET",
|
||||
headers: {
|
||||
@@ -54,23 +54,23 @@ function directory(isMore) {
|
||||
.then(function(response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
setLog(response.url, response.status, text);
|
||||
});
|
||||
}
|
||||
return response.json()
|
||||
return response.json();
|
||||
})
|
||||
.catch(function(error) {
|
||||
setLog(start, "JSON", error)
|
||||
console.error(error)
|
||||
setLog(start, "JSON", error);
|
||||
console.error(error);
|
||||
})
|
||||
.then(function(json) {
|
||||
if (json) {
|
||||
$("#moreDir").removeClass("disabled")
|
||||
var html = userparse(json, null, acct_id, "dir", null)
|
||||
$("#dir-contents").append(html)
|
||||
jQuery("time.timeago").timeago()
|
||||
$("#moreDir").removeClass("disabled");
|
||||
var html = userparse(json, null, acct_id, "dir", null);
|
||||
$("#dir-contents").append(html);
|
||||
jQuery("time.timeago").timeago();
|
||||
} else {
|
||||
$("#moreDir").addClass("disabled")
|
||||
$("#moreDir").addClass("disabled");
|
||||
}
|
||||
})
|
||||
});
|
||||
}
|
||||
|
||||
488
app/js/tl/dm.js
488
app/js/tl/dm.js
@@ -1,8 +1,8 @@
|
||||
//DM(Conv) TL
|
||||
function dm(acct_id, tlid, type, delc, voice) {
|
||||
var domain = localStorage.getItem("domain_" + acct_id)
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at")
|
||||
var start = "https://" + domain + "/api/v1/conversations"
|
||||
var domain = localStorage.getItem("domain_" + acct_id);
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at");
|
||||
var start = "https://" + domain + "/api/v1/conversations";
|
||||
fetch(start, {
|
||||
method: "GET",
|
||||
headers: {
|
||||
@@ -13,38 +13,38 @@ function dm(acct_id, tlid, type, delc, voice) {
|
||||
.then(function(response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
setLog(response.url, response.status, text);
|
||||
});
|
||||
}
|
||||
return response.json()
|
||||
return response.json();
|
||||
})
|
||||
.catch(function(error) {
|
||||
todo(error)
|
||||
setLog(start, "JSON", error)
|
||||
console.error(error)
|
||||
todo(error);
|
||||
setLog(start, "JSON", error);
|
||||
console.error(error);
|
||||
})
|
||||
.then(function(json) {
|
||||
var templete = '<div id="convList' + tlid + '">' + dmListParse(json, type, acct_id, tlid, "", mute) + "</div>"
|
||||
localStorage.setItem("lastobj_" + tlid, json[0].id)
|
||||
$("#timeline_" + tlid).html(templete)
|
||||
additional(acct_id, tlid)
|
||||
jQuery("time.timeago").timeago()
|
||||
todc()
|
||||
var templete = '<div id="convList' + tlid + '">' + dmListParse(json, type, acct_id, tlid, "", mute) + "</div>";
|
||||
localStorage.setItem("lastobj_" + tlid, json[0].id);
|
||||
$("#timeline_" + tlid).html(templete);
|
||||
additional(acct_id, tlid);
|
||||
jQuery("time.timeago").timeago();
|
||||
todc();
|
||||
//reload(type, '', acct_id, tlid, data, mute, delc,voice);
|
||||
$(window).scrollTop(0)
|
||||
})
|
||||
$(window).scrollTop(0);
|
||||
});
|
||||
}
|
||||
function dmmore(tlid) {
|
||||
var multi = localStorage.getItem("column")
|
||||
var obj = JSON.parse(multi)
|
||||
var acct_id = obj[tlid].domain
|
||||
var domain = localStorage.getItem("domain_" + acct_id)
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at")
|
||||
var multi = localStorage.getItem("column");
|
||||
var obj = JSON.parse(multi);
|
||||
var acct_id = obj[tlid].domain;
|
||||
var domain = localStorage.getItem("domain_" + acct_id);
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at");
|
||||
var sid = $("#timeline_" + tlid + " .cvo")
|
||||
.last()
|
||||
.attr("unique-id")
|
||||
var start = "https://" + domain + "/api/v1/conversations?max_id=" + sid
|
||||
var type = "dm"
|
||||
.attr("unique-id");
|
||||
var start = "https://" + domain + "/api/v1/conversations?max_id=" + sid;
|
||||
var type = "dm";
|
||||
fetch(start, {
|
||||
method: "GET",
|
||||
headers: {
|
||||
@@ -55,444 +55,444 @@ function dmmore(tlid) {
|
||||
.then(function(response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
setLog(response.url, response.status, text);
|
||||
});
|
||||
}
|
||||
return response.json()
|
||||
return response.json();
|
||||
})
|
||||
.catch(function(error) {
|
||||
todo(error)
|
||||
setLog(start, "JSON", error)
|
||||
console.error(error)
|
||||
todo(error);
|
||||
setLog(start, "JSON", error);
|
||||
console.error(error);
|
||||
})
|
||||
.then(function(json) {
|
||||
var templete = '<div id="convList' + tlid + '">' + dmListParse(json, type, acct_id, tlid, "", mute) + "</div>"
|
||||
$("#timeline_" + tlid).append(templete)
|
||||
additional(acct_id, tlid)
|
||||
jQuery("time.timeago").timeago()
|
||||
moreloading = false
|
||||
})
|
||||
var templete = '<div id="convList' + tlid + '">' + dmListParse(json, type, acct_id, tlid, "", mute) + "</div>";
|
||||
$("#timeline_" + tlid).append(templete);
|
||||
additional(acct_id, tlid);
|
||||
jQuery("time.timeago").timeago();
|
||||
moreloading = false;
|
||||
});
|
||||
}
|
||||
//DMオブジェクトパーサー(トゥート)
|
||||
function dmListParse(obj, mix, acct_id, tlid, popup, mutefilter) {
|
||||
var templete = ""
|
||||
var templete = "";
|
||||
if (obj[0]) {
|
||||
localStorage.setItem("lastunix_" + tlid, date(obj[0].created_at, "unix"))
|
||||
localStorage.setItem("lastunix_" + tlid, date(obj[0].created_at, "unix"));
|
||||
}
|
||||
|
||||
var actb = localStorage.getItem("action_btns")
|
||||
var actb = "re,rt,fav,qt,del,pin,red"
|
||||
var actb = localStorage.getItem("action_btns");
|
||||
var actb = "re,rt,fav,qt,del,pin,red";
|
||||
if (actb) {
|
||||
var actb = actb.split(",")
|
||||
var disp = {}
|
||||
var actb = actb.split(",");
|
||||
var disp = {};
|
||||
for (var k = 0; k < actb.length; k++) {
|
||||
if (k < 4) {
|
||||
var tp = "type-a"
|
||||
var tp = "type-a";
|
||||
} else {
|
||||
var tp = "type-b"
|
||||
var tp = "type-b";
|
||||
}
|
||||
disp[actb[k]] = tp
|
||||
disp[actb[k]] = tp;
|
||||
}
|
||||
}
|
||||
var datetype = localStorage.getItem("datetype")
|
||||
var nsfwtype = localStorage.getItem("nsfw")
|
||||
var sent = localStorage.getItem("sentence")
|
||||
var ltr = localStorage.getItem("letters")
|
||||
var gif = localStorage.getItem("gif")
|
||||
var imh = localStorage.getItem("img-height")
|
||||
var datetype = localStorage.getItem("datetype");
|
||||
var nsfwtype = localStorage.getItem("nsfw");
|
||||
var sent = localStorage.getItem("sentence");
|
||||
var ltr = localStorage.getItem("letters");
|
||||
var gif = localStorage.getItem("gif");
|
||||
var imh = localStorage.getItem("img-height");
|
||||
//独自ロケール
|
||||
var locale = localStorage.getItem("locale")
|
||||
var locale = localStorage.getItem("locale");
|
||||
if (locale == "yes") {
|
||||
var locale = false
|
||||
var locale = false;
|
||||
}
|
||||
//ネイティブ通知
|
||||
var native = localStorage.getItem("nativenotf")
|
||||
var native = localStorage.getItem("nativenotf");
|
||||
if (!native) {
|
||||
native = "yes"
|
||||
native = "yes";
|
||||
}
|
||||
//クライアント強調
|
||||
var emp = localStorage.getItem("client_emp")
|
||||
var emp = localStorage.getItem("client_emp");
|
||||
if (emp) {
|
||||
var emp = JSON.parse(emp)
|
||||
var emp = JSON.parse(emp);
|
||||
}
|
||||
//クライアントミュート
|
||||
var mute = localStorage.getItem("client_mute")
|
||||
var mute = localStorage.getItem("client_mute");
|
||||
if (mute) {
|
||||
var mute = JSON.parse(mute)
|
||||
var mute = JSON.parse(mute);
|
||||
}
|
||||
//ユーザー強調
|
||||
var useremp = localStorage.getItem("user_emp")
|
||||
var useremp = localStorage.getItem("user_emp");
|
||||
if (useremp) {
|
||||
var useremp = JSON.parse(useremp)
|
||||
var useremp = JSON.parse(useremp);
|
||||
}
|
||||
//ワード強調
|
||||
var wordemp = localStorage.getItem("word_emp")
|
||||
var wordemp = localStorage.getItem("word_emp");
|
||||
if (wordemp) {
|
||||
var wordemp = JSON.parse(wordemp)
|
||||
var wordemp = JSON.parse(wordemp);
|
||||
}
|
||||
//ワードミュート
|
||||
var wordmute = localStorage.getItem("word_mute")
|
||||
var wordmute = localStorage.getItem("word_mute");
|
||||
if (wordmute) {
|
||||
var wordmute = JSON.parse(wordmute)
|
||||
wordmute = wordmute.concat(mutefilter)
|
||||
var wordmute = JSON.parse(wordmute);
|
||||
wordmute = wordmute.concat(mutefilter);
|
||||
} else {
|
||||
wordmute = mutefilter
|
||||
wordmute = mutefilter;
|
||||
}
|
||||
//Ticker
|
||||
var tickerck = localStorage.getItem("ticker_ok")
|
||||
var tickerck = localStorage.getItem("ticker_ok");
|
||||
if (tickerck) {
|
||||
var ticker = true
|
||||
var ticker = true;
|
||||
} else {
|
||||
var ticker = false
|
||||
var ticker = false;
|
||||
}
|
||||
//Cards
|
||||
var card = localStorage.getItem("card_" + tlid)
|
||||
var card = localStorage.getItem("card_" + tlid);
|
||||
|
||||
if (!sent) {
|
||||
var sent = 500
|
||||
var sent = 500;
|
||||
}
|
||||
if (!ltr) {
|
||||
var ltr = 500
|
||||
var ltr = 500;
|
||||
}
|
||||
if (!nsfwtype || nsfwtype == "yes") {
|
||||
var nsfw = "ok"
|
||||
var nsfw = "ok";
|
||||
} else {
|
||||
var nsfw
|
||||
var nsfw;
|
||||
}
|
||||
var cwtype = localStorage.getItem("cw")
|
||||
var cwtype = localStorage.getItem("cw");
|
||||
if (!cwtype || cwtype == "yes") {
|
||||
var cw = "ok"
|
||||
var cw = "ok";
|
||||
} else {
|
||||
var cw
|
||||
var cw;
|
||||
}
|
||||
if (!datetype) {
|
||||
datetype = "absolute"
|
||||
datetype = "absolute";
|
||||
}
|
||||
if (!gif) {
|
||||
var gif = "yes"
|
||||
var gif = "yes";
|
||||
}
|
||||
if (!imh) {
|
||||
var imh = "200"
|
||||
var imh = "200";
|
||||
}
|
||||
if (!emp) {
|
||||
var emp = []
|
||||
var emp = [];
|
||||
}
|
||||
if (!mute) {
|
||||
var mute = []
|
||||
var mute = [];
|
||||
}
|
||||
if (!useremp) {
|
||||
var useremp = []
|
||||
var useremp = [];
|
||||
}
|
||||
if (!wordemp) {
|
||||
var wordemp = []
|
||||
var wordemp = [];
|
||||
}
|
||||
if (!wordmute) {
|
||||
var wordmute = []
|
||||
var wordmute = [];
|
||||
}
|
||||
//via通知
|
||||
var viashow = localStorage.getItem("viashow")
|
||||
var viashow = localStorage.getItem("viashow");
|
||||
if (!viashow) {
|
||||
viashow = "via-hide"
|
||||
viashow = "via-hide";
|
||||
}
|
||||
if (viashow == "hide") {
|
||||
viashow = "via-hide"
|
||||
viashow = "via-hide";
|
||||
}
|
||||
//認証なしTL
|
||||
if (mix == "noauth") {
|
||||
var noauth = "hide"
|
||||
var antinoauth = ""
|
||||
var noauth = "hide";
|
||||
var antinoauth = "";
|
||||
} else {
|
||||
var noauth = ""
|
||||
var antinoauth = "hide"
|
||||
var noauth = "";
|
||||
var antinoauth = "hide";
|
||||
}
|
||||
//マウスオーバーのみ
|
||||
var mouseover = localStorage.getItem("mouseover")
|
||||
var mouseover = localStorage.getItem("mouseover");
|
||||
if (!mouseover) {
|
||||
mouseover = ""
|
||||
mouseover = "";
|
||||
} else if (mouseover == "yes" || mouseover == "click") {
|
||||
mouseover = "hide"
|
||||
mouseover = "hide";
|
||||
} else if (mouseover == "no") {
|
||||
mouseover = ""
|
||||
mouseover = "";
|
||||
}
|
||||
var local = []
|
||||
var times = []
|
||||
var local = [];
|
||||
var times = [];
|
||||
Object.keys(obj).forEach(function(key) {
|
||||
var conv_id = obj[key].id
|
||||
var toot = obj[key].last_status
|
||||
var dis_name = escapeHTML(toot.account.display_name)
|
||||
var conv_id = obj[key].id;
|
||||
var toot = obj[key].last_status;
|
||||
var dis_name = escapeHTML(toot.account.display_name);
|
||||
if (toot.account.emojis) {
|
||||
var actemojick = toot.account.emojis[0]
|
||||
var actemojick = toot.account.emojis[0];
|
||||
} else {
|
||||
var actemojick = false
|
||||
var actemojick = false;
|
||||
}
|
||||
//絵文字があれば
|
||||
if (actemojick) {
|
||||
Object.keys(toot.account.emojis).forEach(function(key5) {
|
||||
var emoji = toot.account.emojis[key5]
|
||||
var shortcode = emoji.shortcode
|
||||
var emoji_url = '<img src="' + emoji.url + '" class="emoji-img" data-emoji="' + shortcode + '" alt=" :' + shortcode + ': ">'
|
||||
var regExp = new RegExp(":" + shortcode + ":", "g")
|
||||
dis_name = dis_name.replace(regExp, emoji_url)
|
||||
})
|
||||
var emoji = toot.account.emojis[key5];
|
||||
var shortcode = emoji.shortcode;
|
||||
var emoji_url = '<img src="' + emoji.url + '" class="emoji-img" data-emoji="' + shortcode + '" alt=" :' + shortcode + ': ">';
|
||||
var regExp = new RegExp(":" + shortcode + ":", "g");
|
||||
dis_name = dis_name.replace(regExp, emoji_url);
|
||||
});
|
||||
}
|
||||
var noticeavatar = ""
|
||||
var if_notf = ""
|
||||
var uniqueid = toot.id
|
||||
var notice = ""
|
||||
var boostback = ""
|
||||
var noticeavatar = "";
|
||||
var if_notf = "";
|
||||
var uniqueid = toot.id;
|
||||
var notice = "";
|
||||
var boostback = "";
|
||||
//ユーザー強調
|
||||
if (toot.account.username != toot.account.acct) {
|
||||
var fullname = toot.account.acct
|
||||
var fullname = toot.account.acct;
|
||||
} else {
|
||||
var domain = localStorage.getItem("domain_" + acct_id)
|
||||
var fullname = toot.account.acct + "@" + domain
|
||||
var domain = localStorage.getItem("domain_" + acct_id);
|
||||
var fullname = toot.account.acct + "@" + domain;
|
||||
}
|
||||
if (useremp) {
|
||||
Object.keys(useremp).forEach(function(key10) {
|
||||
var user = useremp[key10]
|
||||
var user = useremp[key10];
|
||||
if (user == fullname) {
|
||||
boostback = "emphasized"
|
||||
boostback = "emphasized";
|
||||
}
|
||||
})
|
||||
});
|
||||
}
|
||||
var id = toot.id
|
||||
var home = ""
|
||||
var id = toot.id;
|
||||
var home = "";
|
||||
if (toot.account.locked) {
|
||||
var locked = ' <i class="fas fa-lock red-text"></i>'
|
||||
var locked = ' <i class="fas fa-lock red-text"></i>';
|
||||
} else {
|
||||
var locked = ""
|
||||
var locked = "";
|
||||
}
|
||||
if (!toot.application) {
|
||||
var via = ""
|
||||
viashow = "hide"
|
||||
var via = "";
|
||||
viashow = "hide";
|
||||
} else {
|
||||
var via = escapeHTML(toot.application.name)
|
||||
var via = escapeHTML(toot.application.name);
|
||||
//強調チェック
|
||||
Object.keys(emp).forEach(function(key6) {
|
||||
var cli = emp[key6]
|
||||
var cli = emp[key6];
|
||||
if (cli == via) {
|
||||
boostback = "emphasized"
|
||||
boostback = "emphasized";
|
||||
}
|
||||
})
|
||||
});
|
||||
//ミュートチェック
|
||||
Object.keys(mute).forEach(function(key7) {
|
||||
var cli = mute[key7]
|
||||
var cli = mute[key7];
|
||||
if (cli == via) {
|
||||
boostback = "hide"
|
||||
boostback = "hide";
|
||||
}
|
||||
})
|
||||
});
|
||||
}
|
||||
if (mix == "pinned") {
|
||||
boostback = "emphasized"
|
||||
boostback = "emphasized";
|
||||
}
|
||||
if (toot.spoiler_text && cw) {
|
||||
var content = toot.content
|
||||
var spoil = escapeHTML(toot.spoiler_text)
|
||||
var spoiler = "cw cw_hide_" + toot.id
|
||||
var api_spoil = "gray"
|
||||
var spoiler_show = '<a href="#" onclick="cw_show(\'' + toot.id + '\')" class="nex parsed">' + lang.lang_parse_cwshow + "</a><br>"
|
||||
var content = toot.content;
|
||||
var spoil = escapeHTML(toot.spoiler_text);
|
||||
var spoiler = "cw cw_hide_" + toot.id;
|
||||
var api_spoil = "gray";
|
||||
var spoiler_show = '<a href="#" onclick="cw_show(\'' + toot.id + '\')" class="nex parsed">' + lang.lang_parse_cwshow + "</a><br>";
|
||||
} else {
|
||||
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 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;
|
||||
if (ct1 > ct2) {
|
||||
var ct = ct1
|
||||
var ct = ct1;
|
||||
} else {
|
||||
var ct = ct2
|
||||
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)) {
|
||||
var content = '<span class="gray">' + lang.lang_parse_fulltext + "</span><br>" + toot.content
|
||||
var spoil = '<span class="cw-long-' + toot.id + '">' + $.mb_substr($.strip_tags(toot.content), 0, 100) + '</span><span class="gray">' + lang.lang_parse_autofold + "</span>"
|
||||
var spoiler = "cw cw_hide_" + toot.id
|
||||
var spoiler_show = '<a href="#" onclick="cw_show(\'' + toot.id + '\')" class="nex parsed">' + lang.lang_parse_more + "</a><br>"
|
||||
var content = '<span class="gray">' + lang.lang_parse_fulltext + "</span><br>" + toot.content;
|
||||
var spoil = '<span class="cw-long-' + toot.id + '">' + $.mb_substr($.strip_tags(toot.content), 0, 100) + '</span><span class="gray">' + lang.lang_parse_autofold + "</span>";
|
||||
var spoiler = "cw cw_hide_" + toot.id;
|
||||
var spoiler_show = '<a href="#" onclick="cw_show(\'' + toot.id + '\')" class="nex parsed">' + lang.lang_parse_more + "</a><br>";
|
||||
} else {
|
||||
var content = toot.content
|
||||
var spoil = escapeHTML(toot.spoiler_text)
|
||||
var spoiler = ""
|
||||
var spoiler_show = ""
|
||||
var content = toot.content;
|
||||
var spoil = escapeHTML(toot.spoiler_text);
|
||||
var spoiler = "";
|
||||
var spoiler_show = "";
|
||||
}
|
||||
}
|
||||
var urls = $.strip_tags(content)
|
||||
.replace(/\n/g, " ")
|
||||
.match(/https?:\/\/([-a-zA-Z0-9@.]+)\/?(?!.*((media|tags)|mentions)).*([-_.!~*\'()a-zA-Z0-9;\/?:\@&=+\$,%#]+)?/)
|
||||
.match(/https?:\/\/([-a-zA-Z0-9@.]+)\/?(?!.*((media|tags)|mentions)).*([-_.!~*\'()a-zA-Z0-9;\/?:\@&=+\$,%#]+)?/);
|
||||
if (urls) {
|
||||
var analyze = "<a onclick=\"additionalIndv('" + tlid + "'," + acct_id + ",'" + id + '\')" class="add-show pointer">' + lang.lang_parse_url + "</a><br>"
|
||||
var analyze = "<a onclick=\"additionalIndv('" + tlid + "'," + acct_id + ",'" + id + '\')" class="add-show pointer">' + lang.lang_parse_url + "</a><br>";
|
||||
} else {
|
||||
var analyze = ""
|
||||
var analyze = "";
|
||||
}
|
||||
var viewer = ""
|
||||
var hasmedia = ""
|
||||
var youtube = ""
|
||||
var viewer = "";
|
||||
var hasmedia = "";
|
||||
var youtube = "";
|
||||
if (toot.emojis) {
|
||||
var emojick = toot.emojis[0]
|
||||
var emojick = toot.emojis[0];
|
||||
} else {
|
||||
var emojick = false
|
||||
var emojick = false;
|
||||
}
|
||||
//絵文字があれば
|
||||
if (emojick) {
|
||||
Object.keys(toot.emojis).forEach(function(key5) {
|
||||
var emoji = toot.emojis[key5]
|
||||
var shortcode = emoji.shortcode
|
||||
var emoji_url = '<img src="' + emoji.url + '" class="emoji-img" data-emoji="' + shortcode + '" alt=" :' + shortcode + ': ">'
|
||||
var regExp = new RegExp(":" + shortcode + ":", "g")
|
||||
content = content.replace(regExp, emoji_url)
|
||||
spoil = spoil.replace(regExp, emoji_url)
|
||||
})
|
||||
var emoji = toot.emojis[key5];
|
||||
var shortcode = emoji.shortcode;
|
||||
var emoji_url = '<img src="' + emoji.url + '" class="emoji-img" data-emoji="' + shortcode + '" alt=" :' + shortcode + ': ">';
|
||||
var regExp = new RegExp(":" + shortcode + ":", "g");
|
||||
content = content.replace(regExp, emoji_url);
|
||||
spoil = spoil.replace(regExp, emoji_url);
|
||||
});
|
||||
}
|
||||
//ニコフレ絵文字
|
||||
if (toot.profile_emojis) {
|
||||
var nicoemojick = toot.profile_emojis[0]
|
||||
var nicoemojick = toot.profile_emojis[0];
|
||||
} else {
|
||||
var nicoemojick = false
|
||||
var nicoemojick = false;
|
||||
}
|
||||
//絵文字があれば
|
||||
if (nicoemojick) {
|
||||
Object.keys(toot.profile_emojis).forEach(function(keynico) {
|
||||
var emoji = toot.profile_emojis[keynico]
|
||||
var shortcode = emoji.shortcode
|
||||
var emoji_url = '<img src="' + emoji.url + '" class="emoji-img" data-emoji="' + shortcode + '" alt=" :' + shortcode + ': ">'
|
||||
var regExp = new RegExp(":" + shortcode + ":", "g")
|
||||
content = content.replace(regExp, emoji_url)
|
||||
spoil = spoil.replace(regExp, emoji_url)
|
||||
})
|
||||
var emoji = toot.profile_emojis[keynico];
|
||||
var shortcode = emoji.shortcode;
|
||||
var emoji_url = '<img src="' + emoji.url + '" class="emoji-img" data-emoji="' + shortcode + '" alt=" :' + shortcode + ': ">';
|
||||
var regExp = new RegExp(":" + shortcode + ":", "g");
|
||||
content = content.replace(regExp, emoji_url);
|
||||
spoil = spoil.replace(regExp, emoji_url);
|
||||
});
|
||||
}
|
||||
//デフォ絵文字
|
||||
content = twemoji.parse(content)
|
||||
content = twemoji.parse(content);
|
||||
if (dis_name) {
|
||||
dis_name = twemoji.parse(dis_name)
|
||||
dis_name = twemoji.parse(dis_name);
|
||||
}
|
||||
if (spoil) {
|
||||
spoil = twemoji.parse(spoil)
|
||||
spoil = twemoji.parse(spoil);
|
||||
}
|
||||
var mediack = toot.media_attachments[0]
|
||||
var mediack = toot.media_attachments[0];
|
||||
//メディアがあれば
|
||||
var media_ids = ""
|
||||
var media_ids = "";
|
||||
if (mediack) {
|
||||
hasmedia = "hasmedia"
|
||||
var cwdt = 100 / toot.media_attachments.length
|
||||
hasmedia = "hasmedia";
|
||||
var cwdt = 100 / toot.media_attachments.length;
|
||||
Object.keys(toot.media_attachments).forEach(function(key2) {
|
||||
var media = toot.media_attachments[key2]
|
||||
var purl = media.preview_url
|
||||
media_ids = media_ids + media.id + ","
|
||||
var url = media.url
|
||||
var media = toot.media_attachments[key2];
|
||||
var purl = media.preview_url;
|
||||
media_ids = media_ids + media.id + ",";
|
||||
var url = media.url;
|
||||
if (toot.sensitive && nsfw) {
|
||||
var sense = "sensitive"
|
||||
var sense = "sensitive";
|
||||
} else {
|
||||
var sense = ""
|
||||
var sense = "";
|
||||
}
|
||||
viewer = viewer + "<a onclick=\"imgv('" + id + "','" + key2 + "','" + acct_id + '\')" id="' + id + "-image-" + key2 + '" data-url="' + url + '" data-type="' + media.type + '" class="img-parsed"><img src="' + purl + '" class="' + sense + ' toot-img pointer" style="width:' + cwdt + "%; height:" + imh + 'px;"></a></span>'
|
||||
})
|
||||
media_ids = media_ids.slice(0, -1)
|
||||
viewer = viewer + "<a onclick=\"imgv('" + id + "','" + key2 + "','" + acct_id + '\')" id="' + id + "-image-" + key2 + '" data-url="' + url + '" data-type="' + media.type + '" class="img-parsed"><img src="' + purl + '" class="' + sense + ' toot-img pointer" style="width:' + cwdt + "%; height:" + imh + 'px;"></a></span>';
|
||||
});
|
||||
media_ids = media_ids.slice(0, -1);
|
||||
} else {
|
||||
viewer = ""
|
||||
hasmedia = "nomedia"
|
||||
viewer = "";
|
||||
hasmedia = "nomedia";
|
||||
}
|
||||
var menck = toot.mentions[0]
|
||||
var mentions = ""
|
||||
var menck = toot.mentions[0];
|
||||
var mentions = "";
|
||||
//メンションであれば
|
||||
if (menck) {
|
||||
mentions = ""
|
||||
mentions = "";
|
||||
Object.keys(toot.mentions).forEach(function(key3) {
|
||||
var mention = toot.mentions[key3]
|
||||
mentions = mentions + "<a onclick=\"udg('" + mention.id + "'," + acct_id + ')" class="pointer">@' + mention.acct + "</a> "
|
||||
})
|
||||
mentions = '<div style="float:right">' + mentions + "</div>"
|
||||
var mention = toot.mentions[key3];
|
||||
mentions = mentions + "<a onclick=\"udg('" + mention.id + "'," + acct_id + ')" class="pointer">@' + mention.acct + "</a> ";
|
||||
});
|
||||
mentions = '<div style="float:right">' + mentions + "</div>";
|
||||
}
|
||||
var tagck = toot.tags[0]
|
||||
var tags = ""
|
||||
var tagck = toot.tags[0];
|
||||
var tags = "";
|
||||
//タグであれば
|
||||
if (tagck) {
|
||||
Object.keys(toot.tags).forEach(function(key4) {
|
||||
var tag = toot.tags[key4]
|
||||
tags = tags + '<span class="hide" data-tag="' + tag.name + '">#' + tag.name + ":<a onclick=\"tl('tag','" + tag.name + "'," + acct_id + ',\'add\')" class="pointer" title="' + lang.lang_parse_tagTL.replace("{{tag}}", "#" + tag.name) + '">TL</a> <a onclick="brInsert(\'#' + tag.name + '\')" class="pointer" title="' + lang.lang_parse_tagtoot.replace("{{tag}}", "#" + tag.name) + '">Toot</a> ' + "<a onclick=\"tagPin('" + tag.name + '\')" class="pointer" title="' + lang.lang_parse_tagpin.replace("{{tag}}", "#" + tag.name) + '">Pin</a></span> '
|
||||
})
|
||||
tags = '<div style="float:right">' + tags + "</div>"
|
||||
var tag = toot.tags[key4];
|
||||
tags = tags + '<span class="hide" data-tag="' + tag.name + '">#' + tag.name + ":<a onclick=\"tl('tag','" + tag.name + "'," + acct_id + ',\'add\')" class="pointer" title="' + lang.lang_parse_tagTL.replace("{{tag}}", "#" + tag.name) + '">TL</a> <a onclick="brInsert(\'#' + tag.name + '\')" class="pointer" title="' + lang.lang_parse_tagtoot.replace("{{tag}}", "#" + tag.name) + '">Toot</a> ' + "<a onclick=\"tagPin('" + tag.name + '\')" class="pointer" title="' + lang.lang_parse_tagpin.replace("{{tag}}", "#" + tag.name) + '">Pin</a></span> ';
|
||||
});
|
||||
tags = '<div style="float:right">' + tags + "</div>";
|
||||
}
|
||||
//アニメ再生
|
||||
if (gif == "yes") {
|
||||
var avatar = toot.account.avatar
|
||||
var avatar = toot.account.avatar;
|
||||
} else {
|
||||
var avatar = toot.account.avatar_static
|
||||
var avatar = toot.account.avatar_static;
|
||||
}
|
||||
//ワードミュート
|
||||
if (wordmute) {
|
||||
Object.keys(wordmute).forEach(function(key8) {
|
||||
var worde = wordmute[key8]
|
||||
var worde = wordmute[key8];
|
||||
if (worde) {
|
||||
if (worde.tag) {
|
||||
var word = worde.tag
|
||||
var word = worde.tag;
|
||||
} else {
|
||||
var word = worde
|
||||
var word = worde;
|
||||
}
|
||||
var regExp = new RegExp(word, "g")
|
||||
var regExp = new RegExp(word, "g");
|
||||
if ($.strip_tags(content).match(regExp)) {
|
||||
boostback = "hide by_filter"
|
||||
boostback = "hide by_filter";
|
||||
}
|
||||
}
|
||||
})
|
||||
});
|
||||
}
|
||||
//ワード強調
|
||||
if (wordemp) {
|
||||
Object.keys(wordemp).forEach(function(key9) {
|
||||
var word = wordemp[key9]
|
||||
var word = wordemp[key9];
|
||||
if (word) {
|
||||
var word = word.tag
|
||||
var regExp = new RegExp(word, "g")
|
||||
content = content.replace(regExp, '<span class="emp">' + escapeHTML(word) + "</span>")
|
||||
var word = word.tag;
|
||||
var regExp = new RegExp(word, "g");
|
||||
content = content.replace(regExp, '<span class="emp">' + escapeHTML(word) + "</span>");
|
||||
}
|
||||
})
|
||||
});
|
||||
}
|
||||
//日本語じゃない
|
||||
if (toot.language != "ja") {
|
||||
var trans = '<div class="action pin"><a onclick="trans(\'' + toot.language + '\')" class="waves-effect waves-dark btn-flat" style="padding:0" title="' + lang.lang_parse_trans + '"><i class="material-icons">g_translate</i></a></div>'
|
||||
var trans = '<div class="action pin"><a onclick="trans(\'' + toot.language + '\')" class="waves-effect waves-dark btn-flat" style="padding:0" title="' + lang.lang_parse_trans + '"><i class="material-icons">g_translate</i></a></div>';
|
||||
} else {
|
||||
var trans = ""
|
||||
var trans = "";
|
||||
}
|
||||
if (toot.favourited) {
|
||||
var if_fav = " yellow-text"
|
||||
var fav_app = "faved"
|
||||
var if_fav = " yellow-text";
|
||||
var fav_app = "faved";
|
||||
} else {
|
||||
var if_fav = ""
|
||||
var fav_app = ""
|
||||
var if_fav = "";
|
||||
var fav_app = "";
|
||||
}
|
||||
//Cards
|
||||
if (!card && toot.card) {
|
||||
var cards = toot.card
|
||||
var cards = toot.card;
|
||||
if (cards.provider_name == "Twitter") {
|
||||
if (cards.image) {
|
||||
var twiImg = '<br><img src="' + cards.image + '">'
|
||||
var twiImg = '<br><img src="' + cards.image + '">';
|
||||
} else {
|
||||
var twiImg = ""
|
||||
var twiImg = "";
|
||||
}
|
||||
analyze = '<blockquote class="twitter-tweet"><b>' + escapeHTML(cards.author_name) + "</b><br>" + escapeHTML(cards.description) + twiImg + "</blockquote>"
|
||||
analyze = '<blockquote class="twitter-tweet"><b>' + escapeHTML(cards.author_name) + "</b><br>" + escapeHTML(cards.description) + twiImg + "</blockquote>";
|
||||
}
|
||||
if (cards.title) {
|
||||
analyze = '<span class="gray">URL' + lang.lang_cards_check + ":<br>Title:" + escapeHTML(cards.title) + "<br>" + escapeHTML(cards.description) + "</span>"
|
||||
analyze = '<span class="gray">URL' + lang.lang_cards_check + ":<br>Title:" + escapeHTML(cards.title) + "<br>" + escapeHTML(cards.description) + "</span>";
|
||||
}
|
||||
if (cards.html) {
|
||||
analyze = cards.html + '<i class="material-icons" onclick="pip(' + id + ')" title="' + lang.lang_cards_pip + '">picture_in_picture_alt</i>'
|
||||
analyze = cards.html + '<i class="material-icons" onclick="pip(' + id + ')" title="' + lang.lang_cards_pip + '">picture_in_picture_alt</i>';
|
||||
}
|
||||
}
|
||||
//Ticker
|
||||
var tickerdom = ""
|
||||
var tickerdom = "";
|
||||
if (ticker) {
|
||||
var tickerdata = localStorage.getItem("ticker")
|
||||
var tickerdata = localStorage.getItem("ticker");
|
||||
if (tickerdata) {
|
||||
var tickerdata = JSON.parse(tickerdata)
|
||||
var tickerdata = JSON.parse(tickerdata);
|
||||
|
||||
var thisdomain = toot.account.acct.split("@")
|
||||
var thisdomain = toot.account.acct.split("@");
|
||||
if (thisdomain.length > 1) {
|
||||
thisdomain = thisdomain[1]
|
||||
thisdomain = thisdomain[1];
|
||||
}
|
||||
for (var i = 0; i < tickerdata.length; i++) {
|
||||
var value = tickerdata[i]
|
||||
var value = tickerdata[i];
|
||||
if (value.domain == thisdomain) {
|
||||
var tickerdom = '<div style="background:linear-gradient(to left,transparent, ' + value.bg + " 96%) !important; color:" + value.text + ';width:100%; height:0.9rem; font-size:0.8rem;"><img src="' + value.image + '" style="height:100%;"><span style="position:relative; top:-0.2rem;"> ' + escapeHTML(value.name) + "</span></div>"
|
||||
break
|
||||
var tickerdom = '<div style="background:linear-gradient(to left,transparent, ' + value.bg + " 96%) !important; color:" + value.text + ';width:100%; height:0.9rem; font-size:0.8rem;"><img src="' + value.image + '" style="height:100%;"><span style="position:relative; top:-0.2rem;"> ' + escapeHTML(value.name) + "</span></div>";
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
templete = templete + '<div id="pub_' + toot.id + '" class="cvo ' + boostback + " " + fav_app + " " + hasmedia + '" toot-id="' + id + '" unique-id="' + uniqueid + '" data-medias="' + media_ids + ' " unixtime="' + date(obj[key].created_at, "unix") + '" ' + if_notf + ' onclick="dmStatus()">' + '<div class="area-notice"><span class="gray sharesta">' + notice + home + "</span></div>" + '<div class="area-icon"><a onclick="udg(\'' + toot.account.id + "'," + acct_id + ');" user="' + toot.account.acct + '" class="udg">' + '<img src="' + avatar + '" width="40" class="prof-img" user="' + toot.account.acct + '"></a>' + noticeavatar + "</div>" + '<div class="area-display_name"><div class="flex-name"><span class="user">' + dis_name + '</span><span class="sml gray" style="overflow: hidden;white-space: nowrap;text-overflow: ellipsis; cursor:text;"> @' + toot.account.acct + locked + "</span></div>" + '<div class="flex-time"><span class="cbadge cbadge-hover pointer waves-effect" onclick="tootUriCopy(\'' + toot.url + '\');" title="' + date(toot.created_at, "absolute") + "(" + lang.lang_parse_clickcopyurl + ')"><i class="far fa-clock-o"></i>' + date(toot.created_at, datetype) + "</span>" + "</div></div>" + '<div class="area-toot">' + tickerdom + '<span class="' + api_spoil + " cw_text_" + toot.id + '"><span class="cw_text">' + spoil + "</span>" + spoiler_show + '</span><span class="toot ' + spoiler + '">' + content + "</span>" + "" + viewer + "" + "<br><a onclick=\"details('" + toot.id + "'," + acct_id + ",'" + tlid + "','dm')\" class=\"pointer waves-effect\">" + lang.lang_parse_thread + "</a></div>" + '<div class="area-vis"></div>' + "</div></div>"
|
||||
})
|
||||
return templete
|
||||
templete = templete + '<div id="pub_' + toot.id + '" class="cvo ' + boostback + " " + fav_app + " " + hasmedia + '" toot-id="' + id + '" unique-id="' + uniqueid + '" data-medias="' + media_ids + ' " unixtime="' + date(obj[key].created_at, "unix") + '" ' + if_notf + ' onclick="dmStatus()">' + '<div class="area-notice"><span class="gray sharesta">' + notice + home + "</span></div>" + '<div class="area-icon"><a onclick="udg(\'' + toot.account.id + "'," + acct_id + ');" user="' + toot.account.acct + '" class="udg">' + '<img src="' + avatar + '" width="40" class="prof-img" user="' + toot.account.acct + '"></a>' + noticeavatar + "</div>" + '<div class="area-display_name"><div class="flex-name"><span class="user">' + dis_name + '</span><span class="sml gray" style="overflow: hidden;white-space: nowrap;text-overflow: ellipsis; cursor:text;"> @' + toot.account.acct + locked + "</span></div>" + '<div class="flex-time"><span class="cbadge cbadge-hover pointer waves-effect" onclick="tootUriCopy(\'' + toot.url + '\');" title="' + date(toot.created_at, "absolute") + "(" + lang.lang_parse_clickcopyurl + ')"><i class="far fa-clock-o"></i>' + date(toot.created_at, datetype) + "</span>" + "</div></div>" + '<div class="area-toot">' + tickerdom + '<span class="' + api_spoil + " cw_text_" + toot.id + '"><span class="cw_text">' + spoil + "</span>" + spoiler_show + '</span><span class="toot ' + spoiler + '">' + content + "</span>" + "" + viewer + "" + "<br><a onclick=\"details('" + toot.id + "'," + acct_id + ",'" + tlid + "','dm')\" class=\"pointer waves-effect\">" + lang.lang_parse_thread + "</a></div>" + '<div class="area-vis"></div>' + "</div></div>";
|
||||
});
|
||||
return templete;
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -19,22 +19,7 @@ async function mixtl(acct_id, tlid, type, delc, voice) {
|
||||
additional(acct_id, tlid)
|
||||
jQuery('time.timeago').timeago()
|
||||
todc()
|
||||
if(mastodonBaseWsStatus[domain] == 'cannnotopen') {
|
||||
mixre(acct_id, tlid, 'mix', mute, voice, '')
|
||||
} else if(mastodonBaseWs[domain] == 'undetected') {
|
||||
const mbws = setInterval(function () {
|
||||
if(mastodonBaseWsStatus[domain] == 'cannnotopen') {
|
||||
mixre(acct_id, tlid, 'mix', mute, voice, '')
|
||||
clearInterval(mbws)
|
||||
} else if(mastodonBaseWsStatus[domain] == 'available') {
|
||||
mastodonBaseWs[domain].send(`{"type":"subscribe","stream":"public:local"}`)
|
||||
clearInterval(mbws)
|
||||
}
|
||||
}, 1000)
|
||||
} else if(mastodonBaseWsStatus[domain] == 'available') {
|
||||
mastodonBaseWs[domain].send(`{"type":"subscribe","stream":"public:local"}`)
|
||||
}
|
||||
|
||||
mixre(acct_id, tlid, 'mix', mute, voice, '')
|
||||
$(window).scrollTop(0)
|
||||
lastId = integrated[0].id
|
||||
beforeLastId = integrated[1].id
|
||||
|
||||
@@ -194,7 +194,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
}
|
||||
var local = []
|
||||
var times = []
|
||||
Object.keys(obj).forEach(function (key) {
|
||||
Object.keys(obj).forEach(function(key) {
|
||||
var domain = localStorage.getItem('domain_' + acct_id)
|
||||
var toot = obj[key]
|
||||
if (type == 'dm') {
|
||||
@@ -214,7 +214,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
}
|
||||
//絵文字があれば
|
||||
if (actemojick) {
|
||||
Object.keys(toot.account.emojis).forEach(function (key5) {
|
||||
Object.keys(toot.account.emojis).forEach(function(key5) {
|
||||
var emoji = toot.account.emojis[key5]
|
||||
var shortcode = emoji.shortcode
|
||||
if (gif == 'yes') {
|
||||
@@ -273,7 +273,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
</i><span class="voice">${lang.lang_parse_notffilter}</span></span>
|
||||
<span class="cbadge cbadge-hover" title="${date(toot.created_at, 'absolute')}(${
|
||||
lang.lang_parse_notftime
|
||||
})" aria-hidden="true"><i class="far fa-clock"></i>
|
||||
})" aria-hidden="true"><i class="far fa-clock"></i>
|
||||
${date(toot.created_at, datetype)}
|
||||
</span>
|
||||
<span class="voice">${date(toot.created_at, 'absolute')}(${lang.lang_parse_notftime})</span>
|
||||
@@ -369,7 +369,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
}
|
||||
//絵文字があれば
|
||||
if (actemojick) {
|
||||
Object.keys(toot.account.emojis).forEach(function (key5) {
|
||||
Object.keys(toot.account.emojis).forEach(function(key5) {
|
||||
var emoji = toot.account.emojis[key5]
|
||||
var shortcode = emoji.shortcode
|
||||
if (gif == 'yes') {
|
||||
@@ -426,7 +426,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
}
|
||||
//絵文字があれば
|
||||
if (actemojick) {
|
||||
Object.keys(toot.account.emojis).forEach(function (key5) {
|
||||
Object.keys(toot.account.emojis).forEach(function(key5) {
|
||||
var emoji = toot.account.emojis[key5]
|
||||
var shortcode = emoji.shortcode
|
||||
if (gif == 'yes') {
|
||||
@@ -454,7 +454,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
var fullname = toot.account.acct + '@' + domain
|
||||
}
|
||||
if (useremp) {
|
||||
Object.keys(useremp).forEach(function (key10) {
|
||||
Object.keys(useremp).forEach(function(key10) {
|
||||
var user = useremp[key10]
|
||||
if (user == fullname) {
|
||||
boostback = 'emphasized'
|
||||
@@ -494,7 +494,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
var via = escapeHTML(toot.application.name)
|
||||
if (empCli) {
|
||||
//強調チェック
|
||||
Object.keys(empCli).forEach(function (key6) {
|
||||
Object.keys(empCli).forEach(function(key6) {
|
||||
var empCliList = empCli[key6]
|
||||
if (empCliList == via) {
|
||||
boostback = 'emphasized'
|
||||
@@ -503,7 +503,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
}
|
||||
if (muteCli) {
|
||||
//ミュートチェック
|
||||
Object.keys(muteCli).forEach(function (key7) {
|
||||
Object.keys(muteCli).forEach(function(key7) {
|
||||
var muteCliList = muteCli[key7]
|
||||
if (muteCliList == via) {
|
||||
boostback = 'hide'
|
||||
@@ -597,7 +597,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
if (mediack) {
|
||||
hasmedia = 'hasmedia'
|
||||
var cwdt = 100 / toot.media_attachments.length
|
||||
Object.keys(toot.media_attachments).forEach(function (key2) {
|
||||
Object.keys(toot.media_attachments).forEach(function(key2) {
|
||||
var media = toot.media_attachments[key2]
|
||||
var purl = media.preview_url
|
||||
media_ids = media_ids + media.id + ','
|
||||
@@ -628,7 +628,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
var mty = media.remote_url.match(/.+(\..+)$/)[1]
|
||||
viewer =
|
||||
viewer +
|
||||
`<a href="${media.url ? media.url : media.remote_url}" title="${media.remote_url} from ${media.url}">[${lang.lang_parse_unknown}(${mty})]</a> `
|
||||
`<a href="${media.remote_url}" title="${media.remote_url}">[${lang.lang_parse_unknown}(${mty})]</a> `
|
||||
} else if (media.type == 'audio') {
|
||||
viewer =
|
||||
viewer +
|
||||
@@ -669,7 +669,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
if (menck) {
|
||||
mentions = ''
|
||||
var to_mention = []
|
||||
Object.keys(toot.mentions).forEach(function (key3) {
|
||||
Object.keys(toot.mentions).forEach(function(key3) {
|
||||
var mention = toot.mentions[key3]
|
||||
//自分は除外
|
||||
//自インスタンスかどうかを確認し、IDの一致
|
||||
@@ -704,19 +704,19 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
var tags = ''
|
||||
//タグであれば
|
||||
if (tagck) {
|
||||
Object.keys(toot.tags).forEach(function (key4) {
|
||||
Object.keys(toot.tags).forEach(function(key4) {
|
||||
var tag = toot.tags[key4]
|
||||
var featured = ` <a onclick="tagFeature('${tag.name}','${acct_id}')" class="pointer" title="add it to Featured tags">Feature</a> `
|
||||
tags =
|
||||
tags +
|
||||
`<span class="hide" data-tag="${tag.name}" data-regTag="${tag.name.toLowerCase()}">#${
|
||||
tag.name
|
||||
tag.name
|
||||
}:
|
||||
<a onclick="tl('tag','${tag.name}','${acct_id}','add')" class="pointer"
|
||||
title="${lang.lang_parse_tagTL.replace(
|
||||
'{{tag}}',
|
||||
'#' + tag.name
|
||||
)}">TL</a> <a onclick="brInsert('#${tag.name}')"
|
||||
'{{tag}}',
|
||||
'#' + tag.name
|
||||
)}">TL</a> <a onclick="brInsert('#${tag.name}')"
|
||||
class="pointer" title="${lang.lang_parse_tagtoot.replace('{{tag}}', '#' + tag.name)}">Toot</a>
|
||||
<a onclick="tagPin('${tag.name}')" class="pointer" title="${lang.lang_parse_tagpin.replace(
|
||||
'{{tag}}',
|
||||
@@ -812,7 +812,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
}
|
||||
//ワードミュート
|
||||
if (wordmuteList) {
|
||||
Object.keys(wordmuteList).forEach(function (key8) {
|
||||
Object.keys(wordmuteList).forEach(function(key8) {
|
||||
var worde = wordmuteList[key8]
|
||||
if (worde) {
|
||||
if (worde.tag) {
|
||||
@@ -829,7 +829,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
}
|
||||
//ワード強調
|
||||
if (wordempList) {
|
||||
Object.keys(wordempList).forEach(function (key9) {
|
||||
Object.keys(wordempList).forEach(function(key9) {
|
||||
var wordList = wordempList[key9]
|
||||
if (wordList) {
|
||||
var wordList = wordList.tag
|
||||
@@ -845,7 +845,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
}
|
||||
//絵文字があれば
|
||||
if (emojick) {
|
||||
Object.keys(toot.emojis).forEach(function (key5) {
|
||||
Object.keys(toot.emojis).forEach(function(key5) {
|
||||
var emoji = toot.emojis[key5]
|
||||
var shortcode = emoji.shortcode
|
||||
if (gif == 'yes') {
|
||||
@@ -871,7 +871,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
}
|
||||
//絵文字があれば(nico)
|
||||
if (nicoemojick) {
|
||||
Object.keys(toot.profile_emojis).forEach(function (keynico) {
|
||||
Object.keys(toot.profile_emojis).forEach(function(keynico) {
|
||||
var emoji = toot.profile_emojis[keynico]
|
||||
var shortcode = emoji.shortcode
|
||||
var emoji_url = `<img draggable="false" src="${emoji.url}" class="emoji-img" data-emoji="${shortcode}" alt=" :${shortcode}: "
|
||||
@@ -918,10 +918,9 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
//Ticker
|
||||
var tickerdom = ''
|
||||
if (ticker) {
|
||||
var tickerdata = localStorage.getItem('sticker')
|
||||
var tickerdata = localStorage.getItem('ticker')
|
||||
if (tickerdata) {
|
||||
var tickerdataRaw = JSON.parse(tickerdata)
|
||||
var tickerdata = tickerdataRaw.data
|
||||
var tickerdata = JSON.parse(tickerdata)
|
||||
|
||||
var thisdomain = toot.account.acct.split('@')
|
||||
if (thisdomain.length > 1) {
|
||||
@@ -930,41 +929,14 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
for (var i = 0; i < tickerdata.length; i++) {
|
||||
var value = tickerdata[i]
|
||||
if (value.domain == thisdomain) {
|
||||
var bgColor = value.bgColor
|
||||
var fontColor = value.fontColor
|
||||
if (!value.bgColor || !value.fontColor) {
|
||||
if (value.type == 'mastodon') {
|
||||
if (!value.bgColor) bgColor = tickerdataRaw.default.mastodon.bgColor
|
||||
if (!value.fontColor) fontColor = tickerdataRaw.default.mastodon.fontColor
|
||||
} else if (value.type == 'pleroma') {
|
||||
if (!value.bgColor) bgColor = tickerdataRaw.default.pleroma.bgColor
|
||||
if (!value.fontColor) fontColor = tickerdataRaw.default.pleroma.fontColor
|
||||
} else if (value.type == 'misskey') {
|
||||
if (!value.bgColor) bgColor = tickerdataRaw.default.misskey.bgColor
|
||||
if (!value.fontColor) fontColor = tickerdataRaw.default.misskey.fontColor
|
||||
} else if (value.type == 'misskeylegacy') {
|
||||
if (!value.bgColor) bgColor = tickerdataRaw.default.misskeylegacy.bgColor
|
||||
if (!value.fontColor) fontColor = tickerdataRaw.default.misskeylegacy.fontColor
|
||||
} else if (value.type == 'pixelfed') {
|
||||
if (!value.bgColor) bgColor = tickerdataRaw.default.pixelfed.bgColor
|
||||
if (!value.fontColor) fontColor = tickerdataRaw.default.pixelfed.fontColor
|
||||
}
|
||||
} else {
|
||||
var bgColor = value.bgColor
|
||||
var fontColor = value.fontColor
|
||||
}
|
||||
bgColorCSS = ''
|
||||
for (let j = 0; j < bgColor.length; j++) {
|
||||
const bg = bgColor[j]
|
||||
bgColorCSS = bgColorCSS + bg + ','
|
||||
}
|
||||
bgColorCSS = `linear-gradient(90deg, ${bgColorCSS} transparent)`
|
||||
var tickerdom = `<div aria-hidden="true" style="user-select:none;cursor:default;background:${bgColorCSS} !important; color:${
|
||||
fontColor
|
||||
};width:100%; height:0.9rem; font-size:0.8rem;" class="tickers">
|
||||
var tickerdom = `<div aria-hidden="true" style="user-select:none;cursor:default;background:linear-gradient(90deg, ${
|
||||
value.bg
|
||||
}, transparent 96%) !important; color:${
|
||||
value.text
|
||||
};width:100%; height:0.9rem; font-size:0.8rem;" class="tickers">
|
||||
<img draggable="false" src="${
|
||||
value.favicon
|
||||
}" style="height:100%;" onerror="this.src=\'../../img/loading.svg\'">
|
||||
value.image
|
||||
}" style="height:100%;" onerror="this.src=\'../../img/loading.svg\'">
|
||||
<span style="position:relative; top:-0.2rem;">${escapeHTML(value.name)}</span>
|
||||
</div>`
|
||||
break
|
||||
@@ -978,14 +950,14 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
if (!quoteUser) {
|
||||
quoteUser = toot.quote.account.acct
|
||||
}
|
||||
if (!toot.quote.quote_muted) {
|
||||
if(!toot.quote.quote_muted) {
|
||||
poll =
|
||||
poll +
|
||||
`<div class="quote-renote">
|
||||
poll +
|
||||
`<div class="quote-renote">
|
||||
<div class="renote-icon">
|
||||
<a onclick="udg('${toot.quote.account.id}','${acct_id}');" user="${
|
||||
toot.quote.account.acct
|
||||
}" class="udg">
|
||||
}" class="udg">
|
||||
<img draggable="false" src="${toot.quote.account.avatar}">
|
||||
</a>
|
||||
</div>
|
||||
@@ -997,18 +969,18 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
</div>
|
||||
<div class="renote-details">
|
||||
<a onclick="details('${
|
||||
toot.quote.id
|
||||
}','${acct_id}','${tlid}','normal')" class="waves-effect waves-dark btn-flat details" style="padding:0">
|
||||
toot.quote.id
|
||||
}','${acct_id}','${tlid}','normal')" class="waves-effect waves-dark btn-flat details" style="padding:0">
|
||||
<i class="text-darken-3 material-icons">more_vert</i>
|
||||
</a>
|
||||
</div>
|
||||
</div>`
|
||||
} else {
|
||||
poll =
|
||||
poll +
|
||||
`<span class="gray sml">${lang.lang_parse_hidden}</span>`
|
||||
poll +
|
||||
`<span class="gray sml">${lang.lang_parse_hidden}</span>`
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
//menuは何個?
|
||||
var menuct = 2
|
||||
@@ -1097,8 +1069,8 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
</div>
|
||||
<div class="action ${can_rt} ${disp['rt']} ${noauth}">
|
||||
<a onclick="rt('${
|
||||
toot.id
|
||||
}','${acct_id}','${tlid}')" class="waves-effect waves-dark btn-flat actct bt-btn"
|
||||
toot.id
|
||||
}','${acct_id}','${tlid}')" class="waves-effect waves-dark btn-flat actct bt-btn"
|
||||
style="padding:0" title="${lang.lang_parse_bt}">
|
||||
<i class="fas fa-retweet ${if_rt} rt_${toot.id}"></i>
|
||||
<span class="voice">${lang.lang_parse_bt} </span>
|
||||
@@ -1132,7 +1104,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter, type) {
|
||||
</div>
|
||||
<div class="area-side">
|
||||
<div class="action ${noauth}">
|
||||
<a onclick="toggleAction($(this), ${menuct})"
|
||||
<a onclick="toggleAction($(this), ${menuct * 39 + 6})"
|
||||
class="ctxMenu waves-effect waves-dark btn-flat" style="padding:0">
|
||||
<i class="text-darken-3 material-icons act-icon" aria-hidden="true">expand_more</i>
|
||||
<span class="voice">Other actions</span>
|
||||
@@ -1209,7 +1181,7 @@ function userparse(obj, auth, acct_id, tlid, popup) {
|
||||
}
|
||||
var templete = ''
|
||||
var datetype = localStorage.getItem('datetype')
|
||||
Object.keys(obj).forEach(function (key) {
|
||||
Object.keys(obj).forEach(function(key) {
|
||||
var toot = obj[key]
|
||||
if (toot) {
|
||||
if (!toot.username) {
|
||||
@@ -1246,6 +1218,7 @@ function userparse(obj, auth, acct_id, tlid, popup) {
|
||||
} else if (auth == 'request') {
|
||||
var ftxt = lang.lang_parse_request
|
||||
}
|
||||
console.log(auth, ftxt)
|
||||
if (popup > 0 || popup == -1 || notf) {
|
||||
var notftext = ftxt + '<br>'
|
||||
} else {
|
||||
@@ -1285,7 +1258,7 @@ function userparse(obj, auth, acct_id, tlid, popup) {
|
||||
}
|
||||
//絵文字があれば
|
||||
if (actemojick) {
|
||||
Object.keys(toot.emojis).forEach(function (key5) {
|
||||
Object.keys(toot.emojis).forEach(function(key5) {
|
||||
var emoji = toot.emojis[key5]
|
||||
var shortcode = emoji.shortcode
|
||||
if (gif == 'yes') {
|
||||
@@ -1318,7 +1291,7 @@ function userparse(obj, auth, acct_id, tlid, popup) {
|
||||
} else {
|
||||
var udg = `<a onclick="udg('${toot.id}','${acct_id}');" user="${toot.acct}" class="udg">`
|
||||
}
|
||||
var latest = date(toot.last_status_at, 'relative', true)
|
||||
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>`
|
||||
} else {
|
||||
@@ -1396,7 +1369,7 @@ function client(name) {
|
||||
M.toast({ html: escapeHTML(name) + lang.lang_status_emphas, displayLength: 2000 })
|
||||
} else {
|
||||
var can
|
||||
Object.keys(obj).forEach(function (key) {
|
||||
Object.keys(obj).forEach(function(key) {
|
||||
var cliT = obj[key]
|
||||
if (cliT != name && !can) {
|
||||
can = false
|
||||
@@ -1484,7 +1457,7 @@ function pollParse(poll, acct_id, emojis) {
|
||||
var max = 0
|
||||
}
|
||||
|
||||
Object.keys(choices).forEach(function (keyc) {
|
||||
Object.keys(choices).forEach(function(keyc) {
|
||||
var choice = choices[keyc]
|
||||
var voteit = ''
|
||||
for (var i = 0; i < minechoice.length; i++) {
|
||||
@@ -1519,7 +1492,7 @@ function pollParse(poll, acct_id, emojis) {
|
||||
var choiceText = escapeHTML(choice.title)
|
||||
if (emojis) {
|
||||
//絵文字があれば
|
||||
Object.keys(emojis).forEach(function (key5) {
|
||||
Object.keys(emojis).forEach(function(key5) {
|
||||
var emoji = emojis[key5]
|
||||
var shortcode = emoji.shortcode
|
||||
if (gif == 'yes') {
|
||||
@@ -1559,283 +1532,3 @@ function pollParse(poll, acct_id, emojis) {
|
||||
</div>`
|
||||
return pollHtml
|
||||
}
|
||||
|
||||
//MastodonBaseStreaming
|
||||
var mastodonBaseWs = {}
|
||||
var mastodonBaseWsStatus = {}
|
||||
function mastodonBaseStreaming(acct_id) {
|
||||
const domain = localStorage.getItem(`domain_${acct_id}`)
|
||||
if(mastodonBaseWsStatus[domain]) return
|
||||
mastodonBaseWsStatus[domain] = 'undetected'
|
||||
const at = localStorage.getItem(`acct_${acct_id}_at`)
|
||||
const start = `wss://${domain}/api/v1/streaming/?access_token=${at}`
|
||||
mastodonBaseWs[domain] = new WebSocket(start)
|
||||
mastodonBaseWs[domain].onopen = function () {
|
||||
mastodonBaseWsStatus[domain] = 'connecting'
|
||||
setTimeout(function () {
|
||||
mastodonBaseWsStatus[domain] = 'available'
|
||||
}, 3000)
|
||||
mastodonBaseWs[domain].send(`{"type":"subscribe","stream":"user"}`)
|
||||
$('.notice_icon_acct_' + acct_id).removeClass('red-text')
|
||||
}
|
||||
mastodonBaseWs[domain].onmessage = function (mess) {
|
||||
const typeA = JSON.parse(mess.data).event
|
||||
if (typeA == 'delete') {
|
||||
$(`[unique-id=${JSON.parse(mess.data).payload}]`).hide()
|
||||
$(`[unique-id=${JSON.parse(mess.data).payload}]`).remove()
|
||||
} else if (typeA == 'update' || typeA == 'conversation') {
|
||||
//markers show中はダメ
|
||||
const tl = JSON.parse(mess.data).stream
|
||||
const obj = JSON.parse(JSON.parse(mess.data).payload)
|
||||
const tls = getTlMeta(tl[0], tl, acct_id, obj)
|
||||
insertTl(obj, tls)
|
||||
} else if (typeA == 'filters_changed') {
|
||||
filterUpdate(acct_id)
|
||||
} else if (~typeA.indexOf('announcement')) {
|
||||
announ(acct_id, tlid)
|
||||
} else if (typeA == 'notification') {
|
||||
const obj = JSON.parse(JSON.parse(mess.data).payload)
|
||||
let template = ''
|
||||
localStorage.setItem('lastnotf_' + acct_id, obj.id)
|
||||
let popup = localStorage.getItem('popup')
|
||||
if (!popup) {
|
||||
popup = 0
|
||||
}
|
||||
if (obj.type != 'follow' && obj.type != 'follow_request') {
|
||||
template = parse([obj], 'notf', acct_id, 'notf', popup)
|
||||
} else if (obj.type == 'follow_request') {
|
||||
template = userparse([obj.account], 'request', acct_id, 'notf', -1)
|
||||
} else {
|
||||
template = userparse([obj], obj.type, acct_id, 'notf', popup)
|
||||
}
|
||||
if (!$('div[data-notfIndv=' + acct_id + '_' + obj.id + ']').length) {
|
||||
$('div[data-notf=' + acct_id + ']').prepend(template)
|
||||
$('div[data-const=notf_' + acct_id + ']').prepend(template)
|
||||
}
|
||||
jQuery('time.timeago').timeago()
|
||||
} else {
|
||||
console.error('unknown type ' + typeA)
|
||||
}
|
||||
}
|
||||
mastodonBaseWs[domain].onerror = function (error) {
|
||||
notf(acct_id, 0) //fallback
|
||||
console.error("Error closing " + domain)
|
||||
console.error(error)
|
||||
if (mastodonBaseWsStatus[domain] == 'available') alert(domain)
|
||||
mastodonBaseWsStatus[domain] = 'cannotuse'
|
||||
setTimeout(function () {
|
||||
mastodonBaseWsStatus[domain] = 'cannotuse'
|
||||
}, 3000)
|
||||
mastodonBaseWs[domain] = false
|
||||
return false
|
||||
}
|
||||
mastodonBaseWs[domain].onclose = function () {
|
||||
notf(acct_id, 0) //fallback
|
||||
console.warn("Closing " + domain)
|
||||
if (mastodonBaseWsStatus[domain] == 'available') alert(domain)
|
||||
mastodonBaseWs[domain] = false
|
||||
mastodonBaseWsStatus[domain] = 'cannotuse'
|
||||
setTimeout(function () {
|
||||
mastodonBaseWsStatus[domain] = 'cannotuse'
|
||||
}, 3000)
|
||||
return false
|
||||
}
|
||||
}
|
||||
function insertTl(obj, tls) {
|
||||
for (const timeline of tls) {
|
||||
const { id, voice, type, acct_id } = timeline
|
||||
const mute = getFilterTypeByAcct(acct_id, type)
|
||||
if ($(`#unread_${id} .material-icons`).hasClass('teal-text')) continue
|
||||
if (!$(`#timeline_${id} [toot-id=${obj.id}]`).length) {
|
||||
if (voice) {
|
||||
say(obj.content)
|
||||
}
|
||||
const template = parse([obj], type, acct_id, id, '', mute, type)
|
||||
console.log($(`#timeline_box_${id}_box .tl-box`).scrollTop(), `timeline_box_${id}_box .tl-box`)
|
||||
if (
|
||||
$(`#timeline_box_${id}_box .tl-box`).scrollTop() === 0
|
||||
) {
|
||||
$(`#timeline_${id}`).prepend(template)
|
||||
} else {
|
||||
let pool = localStorage.getItem('pool_' + id)
|
||||
if (pool) {
|
||||
pool = template + pool
|
||||
} else {
|
||||
pool = template
|
||||
}
|
||||
localStorage.setItem('pool_' + id, pool)
|
||||
}
|
||||
scrollck()
|
||||
additional(acct_id, id)
|
||||
jQuery('time.timeago').timeago()
|
||||
}
|
||||
}
|
||||
}
|
||||
function getTlMeta(type, data, num, status) {
|
||||
const acct_id = num.toString()
|
||||
const columns = localStorage.getItem('column')
|
||||
const obj = JSON.parse(columns)
|
||||
let ret = []
|
||||
let i = 0
|
||||
switch (type) {
|
||||
case 'user':
|
||||
for (const tl of obj) {
|
||||
if (tl.domain != acct_id) continue
|
||||
if (tl.type == 'mix' || tl.type == 'home') {
|
||||
let voice = false
|
||||
if (localStorage.getItem('voice_' + i)) voice = true
|
||||
ret.push({
|
||||
id: i,
|
||||
voice: voice,
|
||||
type: tl.type,
|
||||
acct_id: tl.domain
|
||||
})
|
||||
}
|
||||
i++
|
||||
}
|
||||
break
|
||||
case 'public:local':
|
||||
for (const tl of obj) {
|
||||
if (tl.domain != acct_id) continue
|
||||
if (tl.type == 'mix' || tl.type == 'local') {
|
||||
let voice = false
|
||||
if (localStorage.getItem('voice_' + i)) voice = true
|
||||
ret.push({
|
||||
id: i,
|
||||
voice: voice,
|
||||
type: tl.type,
|
||||
acct_id: tl.domain
|
||||
})
|
||||
}
|
||||
i++
|
||||
}
|
||||
break
|
||||
case 'public:local:media':
|
||||
for (const tl of obj) {
|
||||
if (tl.domain != acct_id) continue
|
||||
if (tl.type == 'local-media') {
|
||||
let voice = false
|
||||
if (localStorage.getItem('voice_' + i)) voice = true
|
||||
ret.push({
|
||||
id: i,
|
||||
voice: voice,
|
||||
type: tl.type,
|
||||
acct_id: tl.domain
|
||||
})
|
||||
}
|
||||
i++
|
||||
}
|
||||
break;
|
||||
case 'public':
|
||||
for (const tl of obj) {
|
||||
if (tl.domain != acct_id) continue
|
||||
if (tl.type == 'pub') {
|
||||
let voice = false
|
||||
if (localStorage.getItem('voice_' + i)) voice = true
|
||||
ret.push({
|
||||
id: i,
|
||||
voice: voice,
|
||||
type: tl.type,
|
||||
acct_id: tl.domain
|
||||
})
|
||||
}
|
||||
i++
|
||||
}
|
||||
break;
|
||||
case 'public:media':
|
||||
for (const tl of obj) {
|
||||
if (tl.domain != acct_id) continue
|
||||
if (tl.type == 'pub-media') {
|
||||
let voice = false
|
||||
if (localStorage.getItem('voice_' + i)) voice = true
|
||||
ret.push({
|
||||
id: i,
|
||||
voice: voice,
|
||||
type: tl.type,
|
||||
acct_id: tl.domain
|
||||
})
|
||||
}
|
||||
i++
|
||||
}
|
||||
break;
|
||||
case 'list':
|
||||
for (const tl of obj) {
|
||||
if (tl.domain != acct_id) continue
|
||||
if (tl.type == 'list' && tl.data == data[1]) {
|
||||
let voice = false
|
||||
if (localStorage.getItem('voice_' + i)) voice = true
|
||||
ret.push({
|
||||
id: i,
|
||||
voice: voice,
|
||||
type: tl.type,
|
||||
acct_id: tl.domain
|
||||
})
|
||||
}
|
||||
i++
|
||||
}
|
||||
break;
|
||||
case 'direct':
|
||||
for (const tl of obj) {
|
||||
if (tl.domain != acct_id) continue
|
||||
if (tl.type == 'dm') {
|
||||
let voice = false
|
||||
if (localStorage.getItem('voice_' + i)) voice = true
|
||||
ret.push({
|
||||
id: i,
|
||||
voice: voice,
|
||||
type: tl.type,
|
||||
acct_id: tl.domain
|
||||
})
|
||||
}
|
||||
i++
|
||||
}
|
||||
break;
|
||||
case 'hashtag':
|
||||
for (const tl of obj) {
|
||||
if (tl.domain != acct_id) continue
|
||||
const columnDataRaw = tl.data
|
||||
let columnData
|
||||
if (!columnDataRaw.name) {
|
||||
columnData = { name: columnDataRaw }
|
||||
} else {
|
||||
columnData = columnDataRaw
|
||||
}
|
||||
if (tl.type == 'tag') {
|
||||
let voice = false
|
||||
let can = false
|
||||
if (columnData.name == data[1]) can = true
|
||||
//any
|
||||
if (columnData.any.split(',').includes(data[1])) can = true
|
||||
//all
|
||||
const { tags } = status
|
||||
if (columnData.all) can = true
|
||||
for (const { name } of tags) {
|
||||
if (!columnData.all.split(',').includes(name)) {
|
||||
can = false
|
||||
break
|
||||
}
|
||||
}
|
||||
//none
|
||||
if (columnData.none) can = true
|
||||
for (const { name } of tags) {
|
||||
if (columnData.none.split(',').includes(name)) {
|
||||
can = false
|
||||
break
|
||||
}
|
||||
}
|
||||
if (localStorage.getItem('voice_' + i)) voice = true
|
||||
ret.push({
|
||||
id: i,
|
||||
voice: voice,
|
||||
type: tl.type,
|
||||
acct_id: tl.domain
|
||||
})
|
||||
}
|
||||
i++
|
||||
}
|
||||
break;
|
||||
default:
|
||||
console.error(`Cannot catch`);
|
||||
}
|
||||
return ret
|
||||
}
|
||||
498
app/js/tl/tl.js
498
app/js/tl/tl.js
@@ -44,10 +44,10 @@ function tl(type, data, acct_id, tlid, delc, voice, mode) {
|
||||
//Integratedなら飛ばす
|
||||
$('#notice_' + tlid).text(
|
||||
'Integrated TL(' +
|
||||
localStorage.getItem('user_' + acct_id) +
|
||||
'@' +
|
||||
domain +
|
||||
')'
|
||||
localStorage.getItem('user_' + acct_id) +
|
||||
'@' +
|
||||
domain +
|
||||
')'
|
||||
)
|
||||
$('#notice_icon_' + tlid).text('merge_type')
|
||||
mixtl(acct_id, tlid, 'integrated', delc, voice)
|
||||
@@ -56,10 +56,10 @@ function tl(type, data, acct_id, tlid, delc, voice, mode) {
|
||||
//Local+なら飛ばす
|
||||
$('#notice_' + tlid).text(
|
||||
'Local+ TL(' +
|
||||
localStorage.getItem('user_' + acct_id) +
|
||||
'@' +
|
||||
domain +
|
||||
')'
|
||||
localStorage.getItem('user_' + acct_id) +
|
||||
'@' +
|
||||
domain +
|
||||
')'
|
||||
)
|
||||
$('#notice_icon_' + tlid).text('people_outline')
|
||||
mixtl(acct_id, tlid, 'plus', delc, voice)
|
||||
@@ -69,11 +69,11 @@ function tl(type, data, acct_id, tlid, delc, voice, mode) {
|
||||
notf(acct_id, tlid, 'direct')
|
||||
$('#notice_' + tlid).text(
|
||||
cap(type, data, acct_id) +
|
||||
'(' +
|
||||
localStorage.getItem('user_' + acct_id) +
|
||||
'@' +
|
||||
domain +
|
||||
')'
|
||||
'(' +
|
||||
localStorage.getItem('user_' + acct_id) +
|
||||
'@' +
|
||||
domain +
|
||||
')'
|
||||
)
|
||||
$('#notice_icon_' + tlid).text('notifications')
|
||||
return
|
||||
@@ -82,11 +82,11 @@ function tl(type, data, acct_id, tlid, delc, voice, mode) {
|
||||
getBookmark(acct_id, tlid)
|
||||
$('#notice_' + tlid).text(
|
||||
cap(type, data, acct_id) +
|
||||
'(' +
|
||||
localStorage.getItem('user_' + acct_id) +
|
||||
'@' +
|
||||
domain +
|
||||
')'
|
||||
'(' +
|
||||
localStorage.getItem('user_' + acct_id) +
|
||||
'@' +
|
||||
domain +
|
||||
')'
|
||||
)
|
||||
$('#notice_icon_' + tlid).text('bookmark')
|
||||
return
|
||||
@@ -95,11 +95,11 @@ function tl(type, data, acct_id, tlid, delc, voice, mode) {
|
||||
getUtl(acct_id, tlid, data, false)
|
||||
$('#notice_' + tlid).text(
|
||||
cap(type, data, acct_id) +
|
||||
'(' +
|
||||
localStorage.getItem('user_' + acct_id) +
|
||||
'@' +
|
||||
domain +
|
||||
')'
|
||||
'(' +
|
||||
localStorage.getItem('user_' + acct_id) +
|
||||
'@' +
|
||||
domain +
|
||||
')'
|
||||
)
|
||||
$('#notice_icon_' + tlid).text('person')
|
||||
return
|
||||
@@ -117,11 +117,11 @@ function tl(type, data, acct_id, tlid, delc, voice, mode) {
|
||||
}
|
||||
$('#notice_' + tlid).text(
|
||||
cap(type, data, acct_id) +
|
||||
'(' +
|
||||
localStorage.getItem('user_' + acct_id) +
|
||||
'@' +
|
||||
domain +
|
||||
')'
|
||||
'(' +
|
||||
localStorage.getItem('user_' + acct_id) +
|
||||
'@' +
|
||||
domain +
|
||||
')'
|
||||
)
|
||||
} else {
|
||||
var hdr = {
|
||||
@@ -206,7 +206,7 @@ function tl(type, data, acct_id, tlid, delc, voice, mode) {
|
||||
additional(acct_id, tlid)
|
||||
jQuery('time.timeago').timeago()
|
||||
todc()
|
||||
reload(type, 'from timeline to reload', acct_id, tlid, data, mute, delc, voice)
|
||||
reload(type, '', acct_id, tlid, data, mute, delc, voice)
|
||||
if (type == 'home' || type == 'notf') {
|
||||
//Markers
|
||||
var markers = localStorage.getItem('markers')
|
||||
@@ -247,243 +247,194 @@ function reload(type, cc, acct_id, tlid, data, mute, delc, voice, mode) {
|
||||
}
|
||||
}, 100)
|
||||
} else {
|
||||
var domain = localStorage.getItem('domain_' + acct_id)
|
||||
if (mastodonBaseWsStatus[domain] == 'cannotuse') {
|
||||
oldStreaming(type, cc, acct_id, tlid, data, mute, delc, voice, mode)
|
||||
} else if (mastodonBaseWsStatus[domain] == 'undetected' || mastodonBaseWsStatus[domain] == 'connecting') {
|
||||
const mbws = setInterval(function () {
|
||||
if (mastodonBaseWsStatus[domain] == 'cannotuse') {
|
||||
oldStreaming(type, cc, acct_id, tlid, data, mute, delc, voice, mode)
|
||||
clearInterval(mbws)
|
||||
} else if (mastodonBaseWsStatus[domain] == 'available') {
|
||||
$('#notice_icon_' + tlid).removeClass('red-text')
|
||||
stremaingSubscribe(type, acct_id, data)
|
||||
clearInterval(mbws)
|
||||
var misskey = false
|
||||
if (localStorage.getItem('streaming_' + acct_id)) {
|
||||
var wss = localStorage.getItem('streaming_' + acct_id)
|
||||
} else {
|
||||
var wss = 'wss://' + domain
|
||||
}
|
||||
if (type == 'home') {
|
||||
var start = wss + '/api/v1/streaming/?stream=user&access_token=' + at
|
||||
} else if (type == 'pub') {
|
||||
var add = ''
|
||||
if(remoteOnlyCk(tlid)){
|
||||
add = '&remote=true'
|
||||
}
|
||||
var start = wss + '/api/v1/streaming/?stream=public&access_token=' + at + add
|
||||
} else if (type == 'pub-media') {
|
||||
var add = ''
|
||||
if(remoteOnlyCk(tlid)){
|
||||
add = '&remote=true'
|
||||
}var start =
|
||||
wss + '/api/v1/streaming/?stream=public:media&access_token=' + at + add
|
||||
} else if (type == 'local') {
|
||||
var start =
|
||||
wss + '/api/v1/streaming/?stream=public:local&access_token=' + at
|
||||
} else if (type == 'local-media') {
|
||||
var start =
|
||||
wss +
|
||||
'/api/v1/streaming/?stream=public:local:media&only_media=true&access_token=' +
|
||||
at
|
||||
} else if (type == 'tag') {
|
||||
if (type == 'tag') {
|
||||
var tag = localStorage.getItem('tag-range')
|
||||
if (tag == 'local') {
|
||||
data = data + '&local=true'
|
||||
}
|
||||
}, 1000)
|
||||
} else if (mastodonBaseWsStatus[domain] == 'available') {
|
||||
}
|
||||
var start =
|
||||
wss +
|
||||
'/api/v1/streaming/?stream=hashtag&tag=' +
|
||||
data +
|
||||
'&access_token=' +
|
||||
at
|
||||
} else if (type == 'noauth') {
|
||||
var start = 'wss://' + acct_id + '/api/v1/streaming/?stream=public:local'
|
||||
} else if (type == 'list') {
|
||||
var start =
|
||||
wss +
|
||||
'/api/v1/streaming/?stream=list&list=' +
|
||||
data +
|
||||
'&access_token=' +
|
||||
at
|
||||
} else if (type == 'dm') {
|
||||
var start = wss + '/api/v1/streaming/?stream=direct&access_token=' + at
|
||||
}
|
||||
var wsid = websocket.length
|
||||
localStorage.setItem('wss_' + tlid, wsid)
|
||||
websocket[wsid] = new WebSocket(start)
|
||||
websocket[wsid].onopen = function (mess) {
|
||||
console.table({
|
||||
tlid: tlid,
|
||||
type: 'Connect Streaming API' + type,
|
||||
domain: domain,
|
||||
message: [mess],
|
||||
})
|
||||
errorct = 0
|
||||
$('#notice_icon_' + tlid).removeClass('red-text')
|
||||
stremaingSubscribe(type, acct_id, data)
|
||||
}
|
||||
}
|
||||
}
|
||||
function stremaingSubscribe(type, acct_id, data, unsubscribe) {
|
||||
let command = 'subscribe'
|
||||
if (unsubscribe) command = 'unsubscribe'
|
||||
let stream
|
||||
const domain = localStorage.getItem('domain_' + acct_id)
|
||||
if(type == 'home') return false
|
||||
if (type === 'local' || type === 'mix') { stream = 'public:local' }
|
||||
else if (type === 'local-media') { stream = 'public:local:media' }
|
||||
else if (type === 'pub') { stream = 'public' }
|
||||
else if (type === 'pub-media') { stream = 'public:media' }
|
||||
else if (type === 'list') {
|
||||
mastodonBaseWs[domain].send(`{"type":"${command}","stream":"list","list":"${data}"}`)
|
||||
return true
|
||||
} else if (type === 'tag') {
|
||||
let arr = []
|
||||
let name = data
|
||||
if (data.name) name = data.name
|
||||
arr.push(name)
|
||||
if (data.any) arr = arr.concat(data.any.split(','))
|
||||
if (data.all) arr = arr.concat(data.all.split(','))
|
||||
for (const tag of arr) {
|
||||
mastodonBaseWs[domain].send(`{"type":"${command}","stream":"hashtag","tag":"${tag}"}`)
|
||||
}
|
||||
return true
|
||||
}
|
||||
mastodonBaseWs[domain].send(`{"type":"${command}","stream":"${stream}"`)
|
||||
}
|
||||
function oldStreaming(type, cc, acct_id, tlid, data, mute, delc, voice, mode) {
|
||||
var misskey = false
|
||||
const domain = localStorage.getItem(`domain_${acct_id}`)
|
||||
var at = localStorage.getItem('acct_' + acct_id + '_at')
|
||||
if (localStorage.getItem('streaming_' + acct_id)) {
|
||||
var wss = localStorage.getItem('streaming_' + acct_id)
|
||||
} else {
|
||||
var wss = 'wss://' + domain
|
||||
}
|
||||
if (type == 'home') {
|
||||
var start = wss + '/api/v1/streaming/?stream=user&access_token=' + at
|
||||
} else if (type == 'pub') {
|
||||
var add = ''
|
||||
if (remoteOnlyCk(tlid)) {
|
||||
add = '&remote=true'
|
||||
}
|
||||
var start = wss + '/api/v1/streaming/?stream=public&access_token=' + at + add
|
||||
} else if (type == 'pub-media') {
|
||||
var add = ''
|
||||
if (remoteOnlyCk(tlid)) {
|
||||
add = '&remote=true'
|
||||
} var start =
|
||||
wss + '/api/v1/streaming/?stream=public:media&access_token=' + at + add
|
||||
} else if (type == 'local') {
|
||||
var start =
|
||||
wss + '/api/v1/streaming/?stream=public:local&access_token=' + at
|
||||
} else if (type == 'local-media') {
|
||||
var start =
|
||||
wss +
|
||||
'/api/v1/streaming/?stream=public:local:media&only_media=true&access_token=' +
|
||||
at
|
||||
} else if (type == 'tag') {
|
||||
var tag = localStorage.getItem('tag-range')
|
||||
if (tag == 'local') {
|
||||
data = data + '&local=true'
|
||||
}
|
||||
if (data.name) {
|
||||
data = data.name
|
||||
}
|
||||
var start =
|
||||
wss +
|
||||
'/api/v1/streaming/?stream=hashtag&tag=' +
|
||||
data +
|
||||
'&access_token=' +
|
||||
at + add
|
||||
} else if (type == 'noauth') {
|
||||
var start = 'wss://' + acct_id + '/api/v1/streaming/?stream=public:local'
|
||||
} else if (type == 'list') {
|
||||
var start =
|
||||
wss +
|
||||
'/api/v1/streaming/?stream=list&list=' +
|
||||
data +
|
||||
'&access_token=' +
|
||||
at
|
||||
} else if (type == 'dm') {
|
||||
var start = wss + '/api/v1/streaming/?stream=direct&access_token=' + at
|
||||
}
|
||||
var wsid = websocket.length
|
||||
localStorage.setItem('wss_' + tlid, wsid)
|
||||
websocket[wsid] = new WebSocket(start)
|
||||
websocket[wsid].onopen = function (mess) {
|
||||
console.table({
|
||||
tlid: tlid,
|
||||
type: 'Connect Streaming API' + type,
|
||||
domain: domain,
|
||||
message: [mess],
|
||||
})
|
||||
errorct = 0
|
||||
$('#notice_icon_' + tlid).removeClass('red-text')
|
||||
}
|
||||
websocket[wsid].onmessage = function (mess) {
|
||||
console.log([tlid + ':Receive Streaming API:', JSON.parse(mess.data)])
|
||||
if (misskey) {
|
||||
if (JSON.parse(mess.data).type == 'note') {
|
||||
var obj = JSON.parse(mess.data).body
|
||||
if (voice) {
|
||||
say(obj.text)
|
||||
}
|
||||
websocketNotf[acct_id].send(
|
||||
JSON.stringify({
|
||||
type: 'capture',
|
||||
id: obj.id,
|
||||
})
|
||||
)
|
||||
var templete = misskeyParse([obj], type, acct_id, tlid, '', mute)
|
||||
var pool = localStorage.getItem('pool_' + tlid)
|
||||
if (pool) {
|
||||
pool = templete + pool
|
||||
} else {
|
||||
pool = templete
|
||||
}
|
||||
localStorage.setItem('pool_' + tlid, pool)
|
||||
scrollck()
|
||||
jQuery('time.timeago').timeago()
|
||||
}
|
||||
} else {
|
||||
var typeA = JSON.parse(mess.data).event
|
||||
if (typeA == 'delete') {
|
||||
var obj = JSON.parse(mess.data).payload
|
||||
if (delc == 'true') {
|
||||
$(
|
||||
'#timeline_' +
|
||||
tlid +
|
||||
' [unique-id=' +
|
||||
JSON.parse(mess.data).payload +
|
||||
']'
|
||||
).addClass('emphasized')
|
||||
$(
|
||||
'#timeline_' +
|
||||
tlid +
|
||||
' [unique-id=' +
|
||||
JSON.parse(mess.data).payload +
|
||||
']'
|
||||
).addClass('by_delcatch')
|
||||
} else {
|
||||
$('[unique-id=' + JSON.parse(mess.data).payload + ']').hide()
|
||||
$('[unique-id=' + JSON.parse(mess.data).payload + ']').remove()
|
||||
}
|
||||
} else if (typeA == 'update' || typeA == 'conversation') {
|
||||
if (
|
||||
!$('#unread_' + tlid + ' .material-icons').hasClass('teal-text')
|
||||
) {
|
||||
//markers show中はダメ
|
||||
var obj = JSON.parse(JSON.parse(mess.data).payload)
|
||||
if (
|
||||
$('#timeline_' + tlid + ' [toot-id=' + obj.id + ']').length < 1
|
||||
) {
|
||||
if (voice) {
|
||||
say(obj.content)
|
||||
}
|
||||
var templete = parse([obj], type, acct_id, tlid, '', mute, type)
|
||||
if (
|
||||
$('timeline_box_' + tlid + '_box .tl-box').scrollTop() === 0
|
||||
) {
|
||||
$('#timeline_' + tlid).prepend(templete)
|
||||
} else {
|
||||
var pool = localStorage.getItem('pool_' + tlid)
|
||||
if (pool) {
|
||||
pool = templete + pool
|
||||
} else {
|
||||
pool = templete
|
||||
}
|
||||
localStorage.setItem('pool_' + tlid, pool)
|
||||
}
|
||||
scrollck()
|
||||
additional(acct_id, tlid)
|
||||
jQuery('time.timeago').timeago()
|
||||
} else {
|
||||
todo('二重取得発生中')
|
||||
websocket[wsid].onmessage = function (mess) {
|
||||
console.log([tlid + ':Receive Streaming API:', JSON.parse(mess.data)])
|
||||
if (misskey) {
|
||||
if (JSON.parse(mess.data).type == 'note') {
|
||||
var obj = JSON.parse(mess.data).body
|
||||
if (voice) {
|
||||
say(obj.text)
|
||||
}
|
||||
|
||||
todc()
|
||||
websocketNotf[acct_id].send(
|
||||
JSON.stringify({
|
||||
type: 'capture',
|
||||
id: obj.id,
|
||||
})
|
||||
)
|
||||
var templete = misskeyParse([obj], type, acct_id, tlid, '', mute)
|
||||
var pool = localStorage.getItem('pool_' + tlid)
|
||||
if (pool) {
|
||||
pool = templete + pool
|
||||
} else {
|
||||
pool = templete
|
||||
}
|
||||
localStorage.setItem('pool_' + tlid, pool)
|
||||
scrollck()
|
||||
jQuery('time.timeago').timeago()
|
||||
}
|
||||
} else {
|
||||
var typeA = JSON.parse(mess.data).event
|
||||
if (typeA == 'delete') {
|
||||
var obj = JSON.parse(mess.data).payload
|
||||
if (delc == 'true') {
|
||||
$(
|
||||
'#timeline_' +
|
||||
tlid +
|
||||
' [unique-id=' +
|
||||
JSON.parse(mess.data).payload +
|
||||
']'
|
||||
).addClass('emphasized')
|
||||
$(
|
||||
'#timeline_' +
|
||||
tlid +
|
||||
' [unique-id=' +
|
||||
JSON.parse(mess.data).payload +
|
||||
']'
|
||||
).addClass('by_delcatch')
|
||||
} else {
|
||||
$('[unique-id=' + JSON.parse(mess.data).payload + ']').hide()
|
||||
$('[unique-id=' + JSON.parse(mess.data).payload + ']').remove()
|
||||
}
|
||||
} else if (typeA == 'update' || typeA == 'conversation') {
|
||||
if (
|
||||
!$('#unread_' + tlid + ' .material-icons').hasClass('teal-text')
|
||||
) {
|
||||
//markers show中はダメ
|
||||
var obj = JSON.parse(JSON.parse(mess.data).payload)
|
||||
if (
|
||||
$('#timeline_' + tlid + ' [toot-id=' + obj.id + ']').length < 1
|
||||
) {
|
||||
if (voice) {
|
||||
say(obj.content)
|
||||
}
|
||||
var templete = parse([obj], type, acct_id, tlid, '', mute, type)
|
||||
if (
|
||||
$('timeline_box_' + tlid + '_box .tl-box').scrollTop() === 0
|
||||
) {
|
||||
$('#timeline_' + tlid).prepend(templete)
|
||||
} else {
|
||||
var pool = localStorage.getItem('pool_' + tlid)
|
||||
if (pool) {
|
||||
pool = templete + pool
|
||||
} else {
|
||||
pool = templete
|
||||
}
|
||||
localStorage.setItem('pool_' + tlid, pool)
|
||||
}
|
||||
scrollck()
|
||||
additional(acct_id, tlid)
|
||||
jQuery('time.timeago').timeago()
|
||||
} else {
|
||||
todo('二重取得発生中')
|
||||
}
|
||||
|
||||
todc()
|
||||
}
|
||||
} else if (typeA == 'filters_changed') {
|
||||
filterUpdate(acct_id)
|
||||
} else if (~typeA.indexOf('announcement')) {
|
||||
announ(acct_id, tlid)
|
||||
}
|
||||
} else if (typeA == 'filters_changed') {
|
||||
filterUpdate(acct_id)
|
||||
} else if (~typeA.indexOf('announcement')) {
|
||||
announ(acct_id, tlid)
|
||||
}
|
||||
}
|
||||
}
|
||||
websocket[wsid].onerror = function (error) {
|
||||
console.error('Error closing')
|
||||
console.error(error)
|
||||
if (mode == 'error') {
|
||||
$('#notice_icon_' + tlid).addClass('red-text')
|
||||
todo('WebSocket Error ' + error)
|
||||
} else {
|
||||
errorct++
|
||||
console.log(errorct)
|
||||
if (errorct < 3) {
|
||||
reconnector(tlid, type, acct_id, data, 'error')
|
||||
websocket[wsid].onerror = function (error) {
|
||||
console.error('Error closing')
|
||||
console.error(error)
|
||||
if (mode == 'error') {
|
||||
$('#notice_icon_' + tlid).addClass('red-text')
|
||||
todo('WebSocket Error ' + error)
|
||||
} else {
|
||||
errorct++
|
||||
console.log(errorct)
|
||||
if (errorct < 3) {
|
||||
reconnector(tlid, type, acct_id, data, 'error')
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
return false
|
||||
}
|
||||
websocket[wsid].onclose = function () {
|
||||
console.warn('Closing ' + tlid)
|
||||
if (mode == 'error') {
|
||||
$('#notice_icon_' + tlid).addClass('red-text')
|
||||
todo('WebSocket Closed')
|
||||
} else {
|
||||
errorct++
|
||||
console.log(errorct)
|
||||
if (errorct < 3) {
|
||||
reconnector(tlid, type, acct_id, data, 'error')
|
||||
websocket[wsid].onclose = function () {
|
||||
console.warn('Closing ' + tlid)
|
||||
if (mode == 'error') {
|
||||
$('#notice_icon_' + tlid).addClass('red-text')
|
||||
todo('WebSocket Closed')
|
||||
} else {
|
||||
errorct++
|
||||
console.log(errorct)
|
||||
if (errorct < 3) {
|
||||
reconnector(tlid, type, acct_id, data, 'error')
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
//一定のスクロールで発火
|
||||
function moreload(type, tlid) {
|
||||
var multi = localStorage.getItem('column')
|
||||
@@ -915,13 +866,13 @@ function com(type, data, tlid) {
|
||||
return 'public?local=true&only_media=true&'
|
||||
} else if (type == 'pub') {
|
||||
var add = ''
|
||||
if (remoteOnlyCk(tlid)) {
|
||||
if(remoteOnlyCk(tlid)){
|
||||
add = 'remote=true&'
|
||||
}
|
||||
return 'public?' + add
|
||||
} else if (type == 'pub-media') {
|
||||
var add = ''
|
||||
if (remoteOnlyCk(tlid)) {
|
||||
if(remoteOnlyCk(tlid)){
|
||||
add = 'remote=true&'
|
||||
}
|
||||
return 'public?only_media=true&' + add
|
||||
@@ -1047,7 +998,7 @@ function reconnector(tlid, type, acct_id, data, mode) {
|
||||
var voice = false
|
||||
}
|
||||
var mute = getFilterTypeByAcct(acct_id, type)
|
||||
var domain = localStorage.getItem('domain_' + acct_id)
|
||||
reload(type, '', acct_id, tlid, data, mute, '', voice, mode)
|
||||
}
|
||||
M.toast({ html: lang.lang_tl_reconnect, displayLength: 2000 })
|
||||
}
|
||||
@@ -1057,12 +1008,6 @@ function columnReload(tlid, type) {
|
||||
var multi = localStorage.getItem('column')
|
||||
var obj = JSON.parse(multi)
|
||||
var acct_id = obj[tlid].domain
|
||||
var domain = localStorage.getItem('domain_' + acct_id)
|
||||
if (mastodonBaseWsStatus[domain] == 'available') {
|
||||
stremaingSubscribe(type, acct_id, obj[tlid].data, true)
|
||||
parseColumn(tlid, true)
|
||||
return true
|
||||
}
|
||||
if (type == 'mix' || type == 'integrated' || type == 'plus') {
|
||||
if (localStorage.getItem('voice_' + tlid)) {
|
||||
var voice = true
|
||||
@@ -1082,10 +1027,15 @@ function columnReload(tlid, type) {
|
||||
$('#notice_icon_' + tlid).removeClass('red-text')
|
||||
getBookmark(acct_id, tlid, false)
|
||||
} else {
|
||||
|
||||
var wss = localStorage.getItem('wss_' + tlid)
|
||||
websocket[wss].close()
|
||||
parseColumn(tlid, false)
|
||||
if (localStorage.getItem('voice_' + tlid)) {
|
||||
var voice = true
|
||||
} else {
|
||||
var voice = false
|
||||
}
|
||||
var mute = getFilterTypeByAcct(acct_id, type)
|
||||
parseColumn(tlid)
|
||||
}
|
||||
}
|
||||
//Markers
|
||||
@@ -1128,10 +1078,10 @@ function getMarker(tlid, type, acct_id) {
|
||||
$('#unread_' + tlid).attr(
|
||||
'title',
|
||||
lang.lang_layout_unread +
|
||||
':' +
|
||||
json.updated_at +
|
||||
' v' +
|
||||
json.version
|
||||
':' +
|
||||
json.updated_at +
|
||||
' v' +
|
||||
json.version
|
||||
)
|
||||
$('#unread_' + tlid).attr('data-id', json.last_read_id)
|
||||
} else {
|
||||
@@ -1335,8 +1285,8 @@ function asReadEnd() {
|
||||
onBeforeOpen: () => {
|
||||
Swal.showLoading()
|
||||
},
|
||||
onClose: () => { },
|
||||
}).then((result) => { })
|
||||
onClose: () => {},
|
||||
}).then((result) => {})
|
||||
} else {
|
||||
postMessage(['asReadComp', ''], '*')
|
||||
}
|
||||
@@ -1399,8 +1349,8 @@ function getUtl(acct_id, tlid, data, more) {
|
||||
moreloading = true
|
||||
if (more) {
|
||||
var sid = $('#timeline_' + tlid + ' .cvo')
|
||||
.last()
|
||||
.attr('unique-id')
|
||||
.last()
|
||||
.attr('unique-id')
|
||||
var ad = '?max_id=' + sid
|
||||
} else {
|
||||
var ad = ''
|
||||
@@ -1468,7 +1418,7 @@ function announ(acct_id, tlid) {
|
||||
$('.notf-announ_' + acct_id).addClass('hide')
|
||||
}
|
||||
var templete = announParse(json, acct_id, tlid)
|
||||
$('.announce_' + acct_id).html(templete)
|
||||
$('#announce_' + tlid).html(templete)
|
||||
jQuery('time.timeago').timeago()
|
||||
todc()
|
||||
}
|
||||
@@ -1476,7 +1426,7 @@ function announ(acct_id, tlid) {
|
||||
}
|
||||
//buildQuery
|
||||
function buildQuery(name, data) {
|
||||
if (!data || data == '') return ''
|
||||
if(!data || data == '') return ''
|
||||
var arr = data.split(',')
|
||||
var str = ''
|
||||
for (var i = 0; i < arr.length; i++) {
|
||||
|
||||
@@ -120,7 +120,7 @@ function imageXhr(id, key, murl) {
|
||||
element.onload = function() {
|
||||
var width = element.naturalWidth
|
||||
if(width < 650) {
|
||||
width = 650
|
||||
width = 650;
|
||||
}
|
||||
var height = element.naturalHeight
|
||||
var windowH = $(window).height()
|
||||
@@ -182,7 +182,7 @@ function zoom(z) {
|
||||
$('#imagewrap img').css('height', hgt + 'px')
|
||||
}
|
||||
//スマホ対応ドラッグ移動システム
|
||||
(function() {
|
||||
;(function() {
|
||||
$.fn.dragScroll = function() {
|
||||
var target = this
|
||||
$(this)
|
||||
|
||||
@@ -45,13 +45,14 @@ function parseColumn(target, dontclose) {
|
||||
var templete
|
||||
Object.keys(obj).forEach(function (key) {
|
||||
var acct = obj[key]
|
||||
|
||||
localStorage.setItem('name_' + key, acct.name)
|
||||
localStorage.setItem('user_' + key, acct.user)
|
||||
localStorage.setItem('user-id_' + key, acct.id)
|
||||
localStorage.setItem('prof_' + key, acct.prof)
|
||||
localStorage.setItem('domain_' + key, acct.domain)
|
||||
localStorage.setItem('acct_' + key + '_at', acct.at)
|
||||
if(!target) mastodonBaseStreaming(key)
|
||||
notf(key, 0)
|
||||
ckdb(key)
|
||||
//フィルターデータ読もう
|
||||
getFilter(key)
|
||||
@@ -72,14 +73,10 @@ function parseColumn(target, dontclose) {
|
||||
var col = localStorage.getItem('column')
|
||||
if (!col) {
|
||||
var obj = [
|
||||
{
|
||||
domain: 0,
|
||||
type: 'home',
|
||||
},
|
||||
{
|
||||
domain: 0,
|
||||
type: 'local',
|
||||
}
|
||||
},
|
||||
]
|
||||
var json = JSON.stringify(obj)
|
||||
localStorage.setItem('column', json)
|
||||
@@ -104,6 +101,7 @@ function parseColumn(target, dontclose) {
|
||||
$('.box, .boxIn').resizable('destroy')
|
||||
}
|
||||
}
|
||||
console.log(obj)
|
||||
var basekey = 0
|
||||
for (var key = 0; key < obj.length; key++) {
|
||||
var next = key + 1
|
||||
@@ -160,21 +158,15 @@ function parseColumn(target, dontclose) {
|
||||
} else {
|
||||
localStorage.removeItem('hasNotfC_' + acct.domain)
|
||||
}
|
||||
var css = ''
|
||||
var width = localStorage.getItem('width')
|
||||
if (width) {
|
||||
css = ' min-width:' + width + 'px;'
|
||||
}
|
||||
var maxWidth = localStorage.getItem('max-width')
|
||||
if (maxWidth) {
|
||||
css = css +'max-width:' + maxWidth + 'px;'
|
||||
}
|
||||
var margin = localStorage.getItem('margin')
|
||||
if (margin) {
|
||||
css = css +'margin-right:' + margin + 'px;'
|
||||
var css = ' min-width:' + width + 'px;'
|
||||
}
|
||||
if (acct.width) {
|
||||
css = css + ' min-width:' + acct.width + 'px !important;max-width:' + acct.width + 'px !important;'
|
||||
var css = ' min-width:' + acct.width + 'px;max-width:' + acct.width + 'px;'
|
||||
}
|
||||
if (!css) {
|
||||
var css = ''
|
||||
}
|
||||
if (acct.type == 'webview') {
|
||||
if (localStorage.getItem('fixwidth')) {
|
||||
@@ -378,7 +370,7 @@ function parseColumn(target, dontclose) {
|
||||
<div class="boxIn" id="timeline_box_${key}_box" tlid="${key}" data-acct="${acct.domain}" style="${addHeight}">
|
||||
<div class="notice-box z-depth-2" id="menu_${key}" style="${insert}">
|
||||
<div class="area-notice">
|
||||
<i class="material-icons waves-effect ${isMisRed} notice_icon_acct_${acct.domain}" id="notice_icon_${key}" ${notf_attr}
|
||||
<i class="material-icons waves-effect ${isMisRed}" id="notice_icon_${key}" ${notf_attr}
|
||||
style="font-size:40px; padding-top:25%;"
|
||||
onclick="checkStr('${acct.type}','${data}','${acct.domain}', '${key}', '${delc}','${voice}',null)"
|
||||
title="${lang.lang_layout_gotop}" aria-hidden="true">
|
||||
@@ -421,7 +413,7 @@ function parseColumn(target, dontclose) {
|
||||
</div>
|
||||
</div>
|
||||
<div class="column-hide notf-indv-box z-depth-4" id="notf-box_${notfKey}">
|
||||
<div class="announce_${acct.domain}" style="border: 1px solid"></div>
|
||||
<div id="announce_${notfKey}" style="border: 1px solid"></div>
|
||||
<div id="notifications_${notfKey}" data-notf="${notfDomain}" data-type="notf" class="notf-timeline">
|
||||
</div>
|
||||
</div>
|
||||
@@ -452,7 +444,7 @@ function parseColumn(target, dontclose) {
|
||||
<br>
|
||||
<div id="picker_${key}" class="color-picker"></div>
|
||||
</div>${if_tag}
|
||||
<div class="tl-box" tlid="${key}">
|
||||
<div class="tl-box" tlid="${key}" id="tlBox${key}">
|
||||
<div id="timeline_${key}" class="tl ${acct.type}-timeline " tlid="${key}"
|
||||
data-type="${acct.type}" data-acct="${acct.domain}" data-const="${acct.type}_${acct.domain}">
|
||||
<div id="landing_${key}" style="text-align:center">
|
||||
@@ -516,6 +508,8 @@ function parseColumn(target, dontclose) {
|
||||
}
|
||||
}
|
||||
}
|
||||
console.log('multiSelector')
|
||||
multiSelector()
|
||||
$('.box, .boxIn').resizable({
|
||||
minHeight: 50,
|
||||
minWidth: 50,
|
||||
@@ -660,7 +654,7 @@ function removeColumn(tlid) {
|
||||
localStorage.setItem('column', json)
|
||||
sortLoad()
|
||||
$('#timeline_box_' + tlid + '_box').remove()
|
||||
if (!data.left_fold) {
|
||||
if(!data.left_fold) {
|
||||
$('#timeline_box_' + tlid + '_parentBox').remove()
|
||||
}
|
||||
}
|
||||
@@ -794,8 +788,7 @@ function webviewParse(url, key, insert, icnsert, css) {
|
||||
<i class="fab fa-twitter waves-effect" id="notice_icon_${key}" style="font-size:40px; padding-top:25%;"></i>
|
||||
</div>
|
||||
<div class="area-notice_name tl-title">WebView('${url}')</div>
|
||||
<div class="area-sta">
|
||||
</div>
|
||||
<div class="area-sta"></div>
|
||||
<div class="area-a2">
|
||||
<a onclick="removeColumn('${key}')" class="setting nex">
|
||||
<i class="material-icons waves-effect nex" title="${lang.lang_layout_delthis}" ${icnsert}>cancel</i>
|
||||
@@ -813,7 +806,7 @@ function webviewParse(url, key, insert, icnsert, css) {
|
||||
<br>
|
||||
<div id="picker_${key}" class="color-picker"></div>
|
||||
</div>
|
||||
<div class="tl-box" tlid="${key}" style="width:100%;height:100%;">
|
||||
<div class="tl-box" tlid="${key}" style="width:100%;height:100%;" id="tlBox${key}">
|
||||
<div id="timeline_${key}" class="tl" tlid="${key}" data-type="webview" style="width:100%;height:100%;">
|
||||
<webview src="${url}" style="width:100%;height:100%;" id="webview" preload="./js/platform/twitter.js"></webview>
|
||||
</div>
|
||||
@@ -838,7 +831,7 @@ function unstreamingTL(type, key, basekey, insert, icnsert, left_fold, css, anim
|
||||
${lang.lang_layout_leftUnfold}
|
||||
</span><br>`
|
||||
}
|
||||
if (type == 'utl') {
|
||||
if(type == 'utl') {
|
||||
var dataHtml = false
|
||||
} else {
|
||||
var dataHtml = data
|
||||
@@ -875,7 +868,7 @@ function unstreamingTL(type, key, basekey, insert, icnsert, left_fold, css, anim
|
||||
${lang.lang_layout_headercolor}<br>
|
||||
<div id="picker_${key}" class="color-picker"></div>
|
||||
</div>
|
||||
<div class="tl-box" tlid="${key}">
|
||||
<div class="tl-box" tlid="${key}" id="tlBox${key}">
|
||||
<div id="timeline_${key}" class="tl ${type}-timeline" tlid="${key}" data-type="${type}" data-acct="${data}">
|
||||
<div id="landing_${key}" style="text-align:center">
|
||||
${lang.lang_layout_nodata}
|
||||
@@ -908,13 +901,13 @@ function bookmark(key, data) {
|
||||
tl('bookmark', '', data, key, 'false', voice, '')
|
||||
}
|
||||
function utl(key, acct_id, data) {
|
||||
if (!data) {
|
||||
if(!data) {
|
||||
var multi = localStorage.getItem('column')
|
||||
var obj = JSON.parse(multi)
|
||||
data = obj[key].data
|
||||
acct_id = obj[key].domain
|
||||
}
|
||||
|
||||
|
||||
console.log(key, data)
|
||||
if (localStorage.getItem('voice_' + key)) {
|
||||
var voice = true
|
||||
|
||||
@@ -1,24 +1,24 @@
|
||||
function menu() {
|
||||
localStorage.setItem("menu-done", true)
|
||||
localStorage.setItem("menu-done", true);
|
||||
$("#fukidashi").addClass("hide")
|
||||
if (!$("#menu").hasClass("appear")) {
|
||||
$("#menu").addClass("appear")
|
||||
var left = localStorage.getItem("menu-left")
|
||||
var left = localStorage.getItem("menu-left");
|
||||
if (left > $('body').width() - $('#menu').width()) {
|
||||
left = $('body').width() - $('#menu').width()
|
||||
left = $('body').width() - $('#menu').width();
|
||||
} else if (left < 0) {
|
||||
left = 0
|
||||
left = 0;
|
||||
}
|
||||
var top = localStorage.getItem("menu-top")
|
||||
var top = localStorage.getItem("menu-top");
|
||||
if (top > $('body').height() - $('#menu').height()) {
|
||||
top = $('body').height() - $('#menu').height()
|
||||
top = $('body').height() - $('#menu').height();
|
||||
} else if (top < 0) {
|
||||
top = 0
|
||||
top = 0;
|
||||
}
|
||||
$('#menu').css("left", left + "px")
|
||||
$('#menu').css("top", top + "px")
|
||||
var height = localStorage.getItem("menu-height")
|
||||
var width = localStorage.getItem("menu-width")
|
||||
var height = localStorage.getItem("menu-height");
|
||||
var width = localStorage.getItem("menu-width");
|
||||
if(height){
|
||||
$('#menu').css("height", height + "px")
|
||||
}else{
|
||||
@@ -27,13 +27,13 @@ function menu() {
|
||||
if(width){
|
||||
$('#menu').css("width", width + "px")
|
||||
}
|
||||
$('#menu').fadeIn()
|
||||
$("#menu-bar").html("TheDesk " + localStorage.getItem("ver"))
|
||||
$(".menu-content").addClass("hide")
|
||||
$("#add-box").removeClass("hide")
|
||||
$("#left-menu div").removeClass("active")
|
||||
$("#addColumnMenu").addClass("active")
|
||||
$("#addColumnMenu").click()
|
||||
$('#menu').fadeIn();
|
||||
$("#menu-bar").html("TheDesk " + localStorage.getItem("ver"));
|
||||
$(".menu-content").addClass("hide");
|
||||
$("#add-box").removeClass("hide");
|
||||
$("#left-menu div").removeClass("active");
|
||||
$("#addColumnMenu").addClass("active");
|
||||
$("#addColumnMenu").click();
|
||||
} else {
|
||||
$('#menu').fadeOut()
|
||||
$("#menu").removeClass("appear")
|
||||
@@ -44,35 +44,35 @@ $(function () {
|
||||
$("#menu").draggable({
|
||||
handle: "#menu-bar",
|
||||
stop: function () {
|
||||
var left = $('#menu').offset().left
|
||||
var left = $('#menu').offset().left;
|
||||
if (left > $('body').width() - $('#menu').width()) {
|
||||
left = $('body').width() - $('#menu').width()
|
||||
left = $('body').width() - $('#menu').width();
|
||||
} else if (left < 0) {
|
||||
left = 0
|
||||
left = 0;
|
||||
}
|
||||
var top = $('#menu').offset().top
|
||||
var top = $('#menu').offset().top;
|
||||
if (top > $('body').height() - $('#menu').height()) {
|
||||
top = $('body').height() - $('#menu').height()
|
||||
top = $('body').height() - $('#menu').height();
|
||||
} else if (top < 0) {
|
||||
top = 0
|
||||
top = 0;
|
||||
}
|
||||
localStorage.setItem("menu-left", left)
|
||||
localStorage.setItem("menu-top", top)
|
||||
localStorage.setItem("menu-left", left);
|
||||
localStorage.setItem("menu-top", top);
|
||||
}
|
||||
})
|
||||
});
|
||||
$("#menu").resizable({
|
||||
minHeight: 150,
|
||||
minWidth: 200,
|
||||
stop: function (event, ui) {
|
||||
localStorage.setItem("menu-height", ui.size.height)
|
||||
localStorage.setItem("menu-width", ui.size.width)
|
||||
localStorage.setItem("menu-height", ui.size.height);
|
||||
localStorage.setItem("menu-width", ui.size.width);
|
||||
}
|
||||
})
|
||||
})
|
||||
});
|
||||
});
|
||||
function help() {
|
||||
$("#left-menu a").removeClass("active")
|
||||
$("#helpMenu").addClass("active")
|
||||
$(".menu-content").addClass("hide")
|
||||
$("#help-box").removeClass("hide")
|
||||
$("#left-menu a").removeClass("active");
|
||||
$("#helpMenu").addClass("active");
|
||||
$(".menu-content").addClass("hide");
|
||||
$("#help-box").removeClass("hide");
|
||||
postMessage(["sendSinmpleIpc", "getLogs"], "*")
|
||||
}
|
||||
@@ -1,32 +1,32 @@
|
||||
function pip(id) {
|
||||
$("#pip-content").html($("[toot-id=" + id + "] .additional").html())
|
||||
$("#pip").removeClass("hide")
|
||||
$("#pip-content").html($("[toot-id=" + id + "] .additional").html());
|
||||
$("#pip").removeClass("hide");
|
||||
}
|
||||
function endPip() {
|
||||
$("#pip-content").html("")
|
||||
$("#pip").addClass("hide")
|
||||
$("#pip-content").html("");
|
||||
$("#pip").addClass("hide");
|
||||
}
|
||||
|
||||
function pipHoriz() {
|
||||
if ($("#pip").hasClass("pip-left")) {
|
||||
$("#pip").removeClass("pip-left")
|
||||
$(".pip-horiz").text("chevron_left")
|
||||
$("#pip").addClass("pip-right")
|
||||
$("#pip").removeClass("pip-left");
|
||||
$(".pip-horiz").text("chevron_left");
|
||||
$("#pip").addClass("pip-right");
|
||||
} else {
|
||||
$("#pip").addClass("pip-left")
|
||||
$("#pip").removeClass("pip-right")
|
||||
$(".pip-horiz").text("chevron_right")
|
||||
$("#pip").addClass("pip-left");
|
||||
$("#pip").removeClass("pip-right");
|
||||
$(".pip-horiz").text("chevron_right");
|
||||
}
|
||||
}
|
||||
|
||||
function pipVert() {
|
||||
if ($("#pip").hasClass("pip-top")) {
|
||||
$("#pip").removeClass("pip-top")
|
||||
$("#pip").addClass("pip-bottom")
|
||||
$(".pip-vert").text("expand_less")
|
||||
$("#pip").removeClass("pip-top");
|
||||
$("#pip").addClass("pip-bottom");
|
||||
$(".pip-vert").text("expand_less");
|
||||
} else {
|
||||
$("#pip").addClass("pip-top")
|
||||
$("#pip").removeClass("pip-bottom")
|
||||
$(".pip-vert").text("expand_more")
|
||||
$("#pip").addClass("pip-top");
|
||||
$("#pip").removeClass("pip-bottom");
|
||||
$(".pip-vert").text("expand_more");
|
||||
}
|
||||
}
|
||||
@@ -32,7 +32,6 @@ function mini() {
|
||||
function show() {
|
||||
$('#post-box').addClass('appear')
|
||||
$('#textarea').focus()
|
||||
console.log('show' + localStorage.getItem('postbox-left'))
|
||||
var left = localStorage.getItem('postbox-left')
|
||||
if (left > $('body').width() - $('#post-box').width()) {
|
||||
left = $('body').width() - $('#post-box').width()
|
||||
@@ -55,10 +54,12 @@ function show() {
|
||||
}
|
||||
$('#post-box').fadeIn()
|
||||
$('#textarea').characterCounter()
|
||||
|
||||
mdCheck()
|
||||
}
|
||||
|
||||
$(function () {
|
||||
|
||||
$('#post-box').draggable({
|
||||
handle: '#post-bar',
|
||||
stop: function () {
|
||||
|
||||
@@ -1,38 +1,38 @@
|
||||
var r = document.getElementById("radio")
|
||||
var r = document.getElementById("radio");
|
||||
function Rtoggle() {
|
||||
if ($("#radio").hasClass("play")) {
|
||||
Rstop()
|
||||
Rstop();
|
||||
} else {
|
||||
$("#radio-view").toggleClass("hide")
|
||||
$("#radio-view").toggleClass("show")
|
||||
$("#radio-input").addClass("hide")
|
||||
$("#radio-view").toggleClass("hide");
|
||||
$("#radio-view").toggleClass("show");
|
||||
$("#radio-input").addClass("hide");
|
||||
}
|
||||
}
|
||||
function Rplay(url, name) {
|
||||
$("#radio").attr('src', url)
|
||||
r.load()
|
||||
r.play()
|
||||
$("#radio").addClass("play")
|
||||
$("#radio-btn").addClass("teal-text")
|
||||
$("#radio-sta").html("<br>Now Playing:" + name)
|
||||
$("#radio").attr('src', url);
|
||||
r.load();
|
||||
r.play();
|
||||
$("#radio").addClass("play");
|
||||
$("#radio-btn").addClass("teal-text");
|
||||
$("#radio-sta").html("<br>Now Playing:" + name);
|
||||
}
|
||||
function Rstop() {
|
||||
$("#radio").attr("src", "")
|
||||
r.pause()
|
||||
$("#radio").removeClass("play")
|
||||
$("#radio-btn").removeClass("teal-text")
|
||||
$("#radio-sta").html("")
|
||||
$("#radio").attr("src", "");
|
||||
r.pause();
|
||||
$("#radio").removeClass("play");
|
||||
$("#radio-btn").removeClass("teal-text");
|
||||
$("#radio-sta").html("");
|
||||
}
|
||||
function Ryourself() {
|
||||
$("#radio-input").removeClass("hide")
|
||||
$("#radio-view").addClass("hide")
|
||||
$("#radio-input").removeClass("hide");
|
||||
$("#radio-view").addClass("hide");
|
||||
}
|
||||
function Rselect() {
|
||||
$("#radio-input").addClass("hide")
|
||||
$("#radio-view").removeClass("hide")
|
||||
$("#radio-input").addClass("hide");
|
||||
$("#radio-view").removeClass("hide");
|
||||
}
|
||||
function Rinput() {
|
||||
var url = $("#radio-url").val()
|
||||
var url = $("#radio-url").val();
|
||||
Rplay(url, url)
|
||||
}
|
||||
/*
|
||||
|
||||
@@ -1,44 +1,44 @@
|
||||
//ソートデータ読み込み
|
||||
function sortLoad () {
|
||||
$("#sort").html("")
|
||||
var col = localStorage.getItem("column")
|
||||
$("#sort").html("");
|
||||
var col = localStorage.getItem("column");
|
||||
if (col) {
|
||||
var obj = JSON.parse(col)
|
||||
var obj = JSON.parse(col);
|
||||
}
|
||||
Object.keys(obj).forEach(function (key) {
|
||||
var acct = obj[key]
|
||||
var flag = "false"
|
||||
var acct = obj[key];
|
||||
var flag = "false";
|
||||
if (localStorage.getItem("card_" + key) == "true") {
|
||||
flag = "true"
|
||||
}
|
||||
var insert = ""
|
||||
var insert = "";
|
||||
|
||||
if (acct.background) {
|
||||
if (acct.text == "def") {
|
||||
|
||||
} else {
|
||||
if (acct.text == "black") {
|
||||
var txhex = "000000"
|
||||
var txhex = "000000";
|
||||
} else if (acct.text == "white") {
|
||||
var txhex = "ffffff"
|
||||
var txhex = "ffffff";
|
||||
}
|
||||
insert = ' style="background-color:#' + acct.background + '; color: #' + txhex + '" '
|
||||
insert = ' style="background-color:#' + acct.background + '; color: #' + txhex + '" ';
|
||||
}
|
||||
}
|
||||
var user = localStorage.getItem("user_" + acct.domain)
|
||||
var domain = localStorage.getItem("domain_" + acct.domain)
|
||||
var user = localStorage.getItem("user_" + acct.domain);
|
||||
var domain = localStorage.getItem("domain_" + acct.domain);
|
||||
if (!user || !domain) {
|
||||
var acctdata = ""
|
||||
var acctdata = "";
|
||||
} else {
|
||||
var acctdata = user + "@" + domain
|
||||
var acctdata = user + "@" + domain;
|
||||
}
|
||||
|
||||
var html = '<li class="drag-content" data-id="' + key + '" data-flag="' + flag + '"' + insert + '><div class="sorticon"><i class="material-icons">' + icon(acct.type) + '</i></div><div class="sorttitle">' + cap(acct.type, acct.data, acct.domain) + '</div><div class="sortaction"><a onclick="goColumn(' + key +
|
||||
')" class="setting nex"><i class="material-icons waves-effect nex" title="' + lang.lang_sort_gothis + '">forward</i></a> <a onclick="removeColumn(' + key +
|
||||
')" class="setting nex"><i class="material-icons waves-effect nex" title="このカラムを削除">cancel</i></a></div><div class="sortacct">' + acctdata + '</div></li>'
|
||||
$("#sort").append(html)
|
||||
})
|
||||
drag()
|
||||
')" class="setting nex"><i class="material-icons waves-effect nex" title="このカラムを削除">cancel</i></a></div><div class="sortacct">' + acctdata + '</div></li>';
|
||||
$("#sort").append(html);
|
||||
});
|
||||
drag();
|
||||
}
|
||||
|
||||
//TLのタイトル
|
||||
@@ -62,59 +62,59 @@ function Scap(type, data) {
|
||||
} else if (type == "tootsearch") {
|
||||
return "tootsearch(" + data + ")"
|
||||
} else {
|
||||
console.error("unknown timeline type: " + type)
|
||||
console.error("unknown timeline type: " + type);
|
||||
}
|
||||
}
|
||||
|
||||
//jquery-ui依存
|
||||
function drag() {
|
||||
$('#sort').sortable()
|
||||
$('#sort').disableSelection()
|
||||
$('#sort').sortable();
|
||||
$('#sort').disableSelection();
|
||||
}
|
||||
|
||||
//ソート指定
|
||||
function sort() {
|
||||
var arr = []
|
||||
var flags = []
|
||||
var arr = [];
|
||||
var flags = [];
|
||||
$(".drag-content").each(function (i, elem) {
|
||||
var id = $(this).attr("data-id")
|
||||
var flag = $(this).attr("data-flag")
|
||||
var id = $(this).attr("data-id");
|
||||
var flag = $(this).attr("data-flag");
|
||||
arr.push(id)
|
||||
flags.push(flag)
|
||||
})
|
||||
var col = localStorage.getItem("column")
|
||||
var obj = JSON.parse(col)
|
||||
var newobj = []
|
||||
flags.push(flag);
|
||||
});
|
||||
var col = localStorage.getItem("column");
|
||||
var obj = JSON.parse(col);
|
||||
var newobj = [];
|
||||
for (i = 0; i < arr.length; i++) {
|
||||
var data = obj[arr[i]]
|
||||
var data = obj[arr[i]];
|
||||
var add = {
|
||||
domain: data.domain,
|
||||
type: data.type,
|
||||
data: data.data,
|
||||
background: data.background,
|
||||
text: data.text
|
||||
}
|
||||
newobj.push(add)
|
||||
};
|
||||
newobj.push(add);
|
||||
if (flags[i] == "true") {
|
||||
localStorage.setItem("card_" + i, "true")
|
||||
localStorage.setItem("card_" + i, "true");
|
||||
} else {
|
||||
localStorage.removeItem("card_" + i)
|
||||
localStorage.removeItem("card_" + i);
|
||||
}
|
||||
}
|
||||
var json = JSON.stringify(newobj)
|
||||
localStorage.setItem("column", json)
|
||||
$("#sort").html("")
|
||||
var json = JSON.stringify(newobj);
|
||||
localStorage.setItem("column", json);
|
||||
$("#sort").html("");
|
||||
M.toast({ html: "Sorted", displayLength: 3000 })
|
||||
sortLoad()
|
||||
parseColumn()
|
||||
sortLoad();
|
||||
parseColumn();
|
||||
sortMenu()
|
||||
}
|
||||
//ソートボタントグル
|
||||
function sortMenu() {
|
||||
$("#left-menu a").removeClass("active")
|
||||
$("#sortMenu").addClass("active")
|
||||
$(".menu-content").addClass("hide")
|
||||
$("#sort-box").removeClass("hide")
|
||||
$("#sort").html("")
|
||||
sortLoad()
|
||||
$("#left-menu a").removeClass("active");
|
||||
$("#sortMenu").addClass("active");
|
||||
$(".menu-content").addClass("hide");
|
||||
$("#sort-box").removeClass("hide");
|
||||
$("#sort").html("");
|
||||
sortLoad();
|
||||
}
|
||||
@@ -1,44 +1,30 @@
|
||||
function spotifyConnect() {
|
||||
var auth = 'https://spotify.thedesk.top/connect'
|
||||
$('#spotify-code-show').removeClass('hide')
|
||||
postMessage(['openUrl', auth], '*')
|
||||
var auth = 'https://accounts.spotify.com/authorize?client_id=0f18e54abe0b4aedb4591e353d3aff69&redirect_uri=https://thedesk.top/spotify-connect&response_type=code&scope=user-read-currently-playing'
|
||||
var platform = localStorage.getItem('platform')
|
||||
if (platform == 'win32') {
|
||||
postMessage(['openUrl', auth], '*')
|
||||
postMessage(['sendSinmpleIpc', 'quit'], '*')
|
||||
} else {
|
||||
auth = auth + '&state=code'
|
||||
$('#spotify-code-show').removeClass('hide')
|
||||
postMessage(['openUrl', auth], '*')
|
||||
}
|
||||
}
|
||||
function spotifyAuth() {
|
||||
var code = $('#spotify-code').val()
|
||||
localStorage.setItem('spotify-token', code)
|
||||
localStorage.setItem('spotify', 'code')
|
||||
localStorage.setItem('spotify-refresh', code)
|
||||
$('#spotify-code-show').addClass('hide')
|
||||
$('#spotify-enable').addClass('disabled')
|
||||
$('#spotify-disable').removeClass('disabled')
|
||||
}
|
||||
function spotifyDisconnect() {
|
||||
var start = 'https://spotify.thedesk.top/disconnect?code=' + localStorage.getItem('spotify-token')
|
||||
fetch(start, {
|
||||
method: 'GET',
|
||||
headers: {
|
||||
'content-type': 'application/json',
|
||||
},
|
||||
})
|
||||
.then(function (response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function (text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
}
|
||||
return response.json()
|
||||
})
|
||||
.catch(function (error) {
|
||||
todo(error)
|
||||
setLog(start, 'JSON', error)
|
||||
console.error(error)
|
||||
})
|
||||
.then(function (json) {
|
||||
if (!json.success) alert('error')
|
||||
localStorage.removeItem('spotify-token')
|
||||
checkSpotify()
|
||||
})
|
||||
localStorage.removeItem('spotify')
|
||||
localStorage.removeItem('spotify-refresh')
|
||||
checkSpotify()
|
||||
}
|
||||
function checkSpotify() {
|
||||
if (localStorage.getItem('spotify-token')) {
|
||||
if (localStorage.getItem('spotify')) {
|
||||
$('#spotify-enable').addClass('disabled')
|
||||
$('#spotify-disable').removeClass('disabled')
|
||||
} else {
|
||||
@@ -85,8 +71,8 @@ function aMusicFlagSave() {
|
||||
}
|
||||
function nowplaying(mode) {
|
||||
if (mode == 'spotify') {
|
||||
var start = 'https://spotify.thedesk.top/current-playing?code=' + localStorage.getItem('spotify-token')
|
||||
var at = localStorage.getItem('spotify-token')
|
||||
var start = 'https://thedesk.top/now-playing?at=' + localStorage.getItem('spotify') + '&rt=' + localStorage.getItem('spotify-refresh')
|
||||
var at = localStorage.getItem('spotify')
|
||||
if (at) {
|
||||
fetch(start, {
|
||||
method: 'GET',
|
||||
@@ -107,10 +93,7 @@ function nowplaying(mode) {
|
||||
setLog(start, 'JSON', error)
|
||||
console.error(error)
|
||||
})
|
||||
.then(function (jsonRaw) {
|
||||
var code = jsonRaw.token
|
||||
localStorage.setItem('spotify-token', code)
|
||||
var json = jsonRaw.data
|
||||
.then(function (json) {
|
||||
console.table(json)
|
||||
if (json.length < 1) {
|
||||
return false
|
||||
@@ -186,10 +169,11 @@ function nowplaying(mode) {
|
||||
return false
|
||||
}
|
||||
var item = json.recenttracks.track[0]
|
||||
if (!item['@attr']) return false
|
||||
if(!item['@attr']) return false
|
||||
var img = item.image[3]['#text']
|
||||
var isImg = item.streamable*1
|
||||
var flag = localStorage.getItem('artwork')
|
||||
if (flag && img != 'https://lastfm.freetls.fastly.net/i/u/300x300/2a96cbd8b46e442fc41c2b86b821562f.png' && img) {
|
||||
if (flag && isImg && img) {
|
||||
postMessage(['bmpImage', [img, 0]], '*')
|
||||
}
|
||||
var content = localStorage.getItem('np-temp')
|
||||
@@ -203,7 +187,7 @@ function nowplaying(mode) {
|
||||
var regExp = new RegExp('{artist}', 'g')
|
||||
content = content.replace(regExp, item.artist['#text'])
|
||||
var regExp = new RegExp('{url}', 'g')
|
||||
content = content.replace(regExp, '')
|
||||
content = content.replace(regExp,'')
|
||||
var regExp = new RegExp('{composer}', 'g')
|
||||
content = content.replace(regExp, '')
|
||||
var regExp = new RegExp('{hz}', 'g')
|
||||
|
||||
@@ -131,8 +131,12 @@ function trendTagonTip() {
|
||||
spotint = null
|
||||
function spotifytips() {
|
||||
if (spotint) clearInterval(spotint)
|
||||
var start = 'https://spotify.thedesk.top/current-playing?code=' + localStorage.getItem('spotify-token')
|
||||
var at = localStorage.getItem('spotify-token')
|
||||
var start =
|
||||
'https://thedesk.top/now-playing?at=' +
|
||||
localStorage.getItem('spotify') +
|
||||
'&rt=' +
|
||||
localStorage.getItem('spotify-refresh')
|
||||
var at = localStorage.getItem('spotify')
|
||||
if (at) {
|
||||
fetch(start, {
|
||||
method: 'GET',
|
||||
@@ -153,10 +157,7 @@ function spotifytips() {
|
||||
setLog(start, 'JSON', error)
|
||||
console.error(error)
|
||||
})
|
||||
.then(function(jsonRaw) {
|
||||
var code = jsonRaw.token
|
||||
localStorage.setItem('spotify-token', code)
|
||||
var json = jsonRaw.data
|
||||
.then(async function(json) {
|
||||
var ms = json.progress_ms
|
||||
if(!ms) {
|
||||
tips('ver')
|
||||
@@ -174,7 +175,7 @@ function spotifytips() {
|
||||
}
|
||||
}
|
||||
artisttxt = escapeHTML(artisttxt)
|
||||
sleep(last)
|
||||
await sleep(last)
|
||||
var tms = item.duration_ms
|
||||
var per = (ms / item.duration_ms) * 100
|
||||
ms = ms / 1000
|
||||
@@ -250,10 +251,10 @@ function trendTagonTipInterval() {
|
||||
}
|
||||
//時計
|
||||
var clockint
|
||||
function clock() {
|
||||
async function clock() {
|
||||
var now = new Date()
|
||||
var last = 1000 - (now.getTime() % 1000)
|
||||
sleep(last)
|
||||
await sleep(last)
|
||||
clockint = setInterval(clockStart, 1000)
|
||||
}
|
||||
function clockStart() {
|
||||
@@ -285,10 +286,6 @@ function clockStart() {
|
||||
'</span>'
|
||||
$('#tips-text').html(msg)
|
||||
}
|
||||
function sleep(waitMsec) {
|
||||
var startMsec = new Date()
|
||||
while (new Date() - startMsec < waitMsec);
|
||||
}
|
||||
function tipsToggle() {
|
||||
$('#tips').toggleClass('hide')
|
||||
$('#tips-menu').toggleClass('hide')
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,22 +1,24 @@
|
||||
//プロフ編集
|
||||
//文字系
|
||||
function profedit() {
|
||||
var acct_id = $('#his-data').attr("use-acct")
|
||||
todo("Updating...")
|
||||
var domain = localStorage.getItem("domain_" + acct_id)
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at")
|
||||
var start = "https://" + domain + "/api/v1/accounts/update_credentials"
|
||||
var name = $("#his-name-val").val()
|
||||
var des = $("#his-des-val").val()
|
||||
var acct_id = $('#his-data').attr('use-acct')
|
||||
todo('Updating...')
|
||||
var domain = localStorage.getItem('domain_' + acct_id)
|
||||
var at = localStorage.getItem('acct_' + acct_id + '_at')
|
||||
var start = 'https://' + domain + '/api/v1/accounts/update_credentials'
|
||||
var name = $('#his-name-val').val()
|
||||
var des = $('#his-des-val').val()
|
||||
var httpreq = new XMLHttpRequest()
|
||||
httpreq.open('PATCH', start, true)
|
||||
httpreq.setRequestHeader('Content-Type', 'application/json')
|
||||
httpreq.setRequestHeader('Authorization', 'Bearer ' + at)
|
||||
httpreq.responseType = "json"
|
||||
httpreq.send(JSON.stringify({
|
||||
display_name: name,
|
||||
note: des,
|
||||
}))
|
||||
httpreq.responseType = 'json'
|
||||
httpreq.send(
|
||||
JSON.stringify({
|
||||
display_name: name,
|
||||
note: des,
|
||||
})
|
||||
)
|
||||
httpreq.onreadystatechange = function () {
|
||||
if (httpreq.readyState === 4) {
|
||||
$('#his-data').modal('close')
|
||||
@@ -27,10 +29,10 @@ function profedit() {
|
||||
|
||||
//画像系
|
||||
function imgChange(imgfile, target) {
|
||||
var acct_id = $('#his-data').attr("use-acct")
|
||||
todo("アップロードしています")
|
||||
var acct_id = $('#his-data').attr('use-acct')
|
||||
todo('アップロードしています')
|
||||
if (!imgfile.files.length) {
|
||||
console.warn("No Image to upload")
|
||||
console.warn('No Image to upload')
|
||||
return
|
||||
}
|
||||
var file = imgfile.files[0]
|
||||
@@ -40,26 +42,27 @@ function imgChange(imgfile, target) {
|
||||
var blob = toBlob(b64, 'image/png')
|
||||
var fd = new FormData()
|
||||
fd.append(target, blob)
|
||||
var domain = localStorage.getItem("domain_" + acct_id)
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at")
|
||||
var start = "https://" + domain + "/api/v1/accounts/update_credentials"
|
||||
var domain = localStorage.getItem('domain_' + acct_id)
|
||||
var at = localStorage.getItem('acct_' + acct_id + '_at')
|
||||
var start = 'https://' + domain + '/api/v1/accounts/update_credentials'
|
||||
var httpreq = new XMLHttpRequest()
|
||||
httpreq.open('PATCH', start, true)
|
||||
httpreq.upload.addEventListener("progress", progshow, false)
|
||||
httpreq.upload.addEventListener('progress', progshow, false)
|
||||
httpreq.setRequestHeader('Authorization', 'Bearer ' + at)
|
||||
httpreq.responseType = "json"
|
||||
httpreq.responseType = 'json'
|
||||
httpreq.send(fd)
|
||||
httpreq.onreadystatechange = function () {
|
||||
if (httpreq.readyState === 4) {
|
||||
var json = httpreq.response
|
||||
if(this.status!==200){ setLog(start, this.status, this.response) }
|
||||
if (this.status !== 200) {
|
||||
setLog(start, this.status, this.response)
|
||||
}
|
||||
$('#his-data').modal('close')
|
||||
todc()
|
||||
localStorage.removeItem("image")
|
||||
}
|
||||
}
|
||||
}
|
||||
$("#prof-change").html($("#prof-change").html())
|
||||
$("#header-change").html($("#header-change").html())
|
||||
$('#prof-change').html($('#prof-change').html())
|
||||
$('#header-change').html($('#header-change').html())
|
||||
fr.readAsDataURL(file)
|
||||
}
|
||||
|
||||
@@ -1,31 +1,31 @@
|
||||
//ユーザーデータ表示
|
||||
localStorage.removeItem("history")
|
||||
localStorage.removeItem("history");
|
||||
//コード受信
|
||||
if (location.search) {
|
||||
var m = location.search.match(/\?mode=([a-zA-Z-0-9]+)\&code=(.+)/)
|
||||
var mode = m[1]
|
||||
var codex = m[2]
|
||||
var m = location.search.match(/\?mode=([a-zA-Z-0-9]+)\&code=(.+)/);
|
||||
var mode = m[1];
|
||||
var codex = m[2];
|
||||
if (mode == "user") {
|
||||
udgEx(codex, "main")
|
||||
udgEx(codex, "main");
|
||||
}
|
||||
}
|
||||
function udgEx(user, acct_id) {
|
||||
if (user == "selector") {
|
||||
user = $("#his-acct").attr("fullname")
|
||||
user = $("#his-acct").attr("fullname");
|
||||
}
|
||||
if (acct_id == "selector") {
|
||||
acct_id = $("#user-acct-sel").val()
|
||||
acct_id = $("#user-acct-sel").val();
|
||||
}
|
||||
if (acct_id == "main") {
|
||||
acct_id = localStorage.getItem("main")
|
||||
acct_id = localStorage.getItem("main");
|
||||
}
|
||||
console.log("Get user data of " + user)
|
||||
var domain = localStorage.getItem("domain_" + acct_id)
|
||||
console.log("Get user data of " + user);
|
||||
var domain = localStorage.getItem("domain_" + acct_id);
|
||||
if (localStorage.getItem("mode_" + domain) == "misskey") {
|
||||
return false
|
||||
return false;
|
||||
}
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at")
|
||||
var start = "https://" + domain + "/api/v2/search?resolve=true&q=" + encodeURIComponent(user)
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at");
|
||||
var start = "https://" + domain + "/api/v2/search?resolve=true&q=" + encodeURIComponent(user);
|
||||
fetch(start, {
|
||||
method: "GET",
|
||||
headers: {
|
||||
@@ -33,42 +33,42 @@ function udgEx(user, acct_id) {
|
||||
Authorization: "Bearer " + at
|
||||
}
|
||||
})
|
||||
.then(function(response) {
|
||||
.then(function (response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
response.text().then(function (text) {
|
||||
setLog(response.url, response.status, text);
|
||||
});
|
||||
}
|
||||
return response.json()
|
||||
return response.json();
|
||||
})
|
||||
.catch(function(error) {
|
||||
todo(error)
|
||||
setLog(start, "JSON", error)
|
||||
console.error(error)
|
||||
.catch(function (error) {
|
||||
todo(error);
|
||||
setLog(start, "JSON", error);
|
||||
console.error(error);
|
||||
})
|
||||
.then(function(json) {
|
||||
.then(function (json) {
|
||||
if (json.accounts[0]) {
|
||||
var id = json.accounts[0].id
|
||||
udg(id, acct_id)
|
||||
var id = json.accounts[0].id;
|
||||
udg(id, acct_id);
|
||||
} else {
|
||||
postMessage(["openUrl", user], "*")
|
||||
postMessage(["openUrl", user], "*");
|
||||
}
|
||||
})
|
||||
return true
|
||||
});
|
||||
return true;
|
||||
}
|
||||
function udg(user, acct_id) {
|
||||
reset()
|
||||
reset();
|
||||
if (!user) {
|
||||
user = localStorage.getItem("user-id_" + acct_id)
|
||||
user = localStorage.getItem("user-id_" + acct_id);
|
||||
}
|
||||
todo("User Data Loading...")
|
||||
var domain = localStorage.getItem("domain_" + acct_id)
|
||||
todo("User Data Loading...");
|
||||
var domain = localStorage.getItem("domain_" + acct_id);
|
||||
if (localStorage.getItem("mode_" + domain) == "misskey") {
|
||||
misskeyUdg(user, acct_id)
|
||||
return
|
||||
misskeyUdg(user, acct_id);
|
||||
return;
|
||||
}
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at")
|
||||
var start = "https://" + domain + "/api/v1/accounts/" + user
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at");
|
||||
var start = "https://" + domain + "/api/v1/accounts/" + user;
|
||||
fetch(start, {
|
||||
method: "GET",
|
||||
headers: {
|
||||
@@ -76,191 +76,191 @@ function udg(user, acct_id) {
|
||||
Authorization: "Bearer " + at
|
||||
}
|
||||
})
|
||||
.then(function(response) {
|
||||
.then(function (response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
response.text().then(function (text) {
|
||||
setLog(response.url, response.status, text);
|
||||
});
|
||||
}
|
||||
return response.json()
|
||||
return response.json();
|
||||
})
|
||||
.catch(function(error) {
|
||||
todo(error)
|
||||
setLog(start, "JSON", error)
|
||||
console.error(error)
|
||||
.catch(function (error) {
|
||||
todo(error);
|
||||
setLog(start, "JSON", error);
|
||||
console.error(error);
|
||||
})
|
||||
.then(function(json) {
|
||||
.then(function (json) {
|
||||
//一つ前のユーザーデータ
|
||||
if (!localStorage.getItem("history")) {
|
||||
$("#his-history-btn").prop("disabled", true)
|
||||
$("#his-history-btn").prop("disabled", true);
|
||||
} else {
|
||||
$("#his-history-btn").prop("disabled", false)
|
||||
$("#his-data").attr("history", localStorage.getItem("history"))
|
||||
$("#his-history-btn").prop("disabled", false);
|
||||
$("#his-data").attr("history", localStorage.getItem("history"));
|
||||
}
|
||||
//moved設定時
|
||||
if (json.moved) {
|
||||
M.toast({
|
||||
html: lang.lang_showontl_movetxt + '<button class="btn-flat toast-action" onclick="udg(\'' + json.moved.id + "','" + acct_id + "')\">" + lang.lang_showontl_movebtn + "</button>",
|
||||
displayLength: 4000
|
||||
})
|
||||
});
|
||||
}
|
||||
$("#his-data").modal("open")
|
||||
$("#his-data").attr("user-id", user)
|
||||
$("#his-data").attr("use-acct", acct_id)
|
||||
$("#his-data").modal("open");
|
||||
$("#his-data").attr("user-id", user);
|
||||
$("#his-data").attr("use-acct", acct_id);
|
||||
if (json.username != json.acct) {
|
||||
//Remote
|
||||
$("#his-data").attr("remote", "true")
|
||||
var fullname = json.acct
|
||||
$("#his-data").attr("remote", "true");
|
||||
var fullname = json.acct;
|
||||
} else {
|
||||
$("#his-data").attr("remote", "false")
|
||||
var fullname = json.acct + "@" + domain
|
||||
$("#his-data").attr("remote", "false");
|
||||
var fullname = json.acct + "@" + domain;
|
||||
}
|
||||
utlShow(json.id, "", acct_id)
|
||||
flw(json.id, "", acct_id)
|
||||
fer(json.id, "", acct_id)
|
||||
var dis_name = escapeHTML(json.display_name)
|
||||
dis_name = twemoji.parse(dis_name)
|
||||
utlShow(json.id, "", acct_id);
|
||||
flw(json.id, "", acct_id);
|
||||
fer(json.id, "", acct_id);
|
||||
var dis_name = escapeHTML(json.display_name);
|
||||
dis_name = twemoji.parse(dis_name);
|
||||
|
||||
var note = json.note
|
||||
var note = json.note;
|
||||
if (json.emojis) {
|
||||
var actemojick = json.emojis[0]
|
||||
var actemojick = json.emojis[0];
|
||||
} else {
|
||||
var actemojick = false
|
||||
var actemojick = false;
|
||||
}
|
||||
//絵文字があれば
|
||||
if (actemojick) {
|
||||
Object.keys(json.emojis).forEach(function(key5) {
|
||||
var emoji = json.emojis[key5]
|
||||
var shortcode = emoji.shortcode
|
||||
var emoji_url = '<img src="' + emoji.url + '" class="emoji-img" data-emoji="' + shortcode + '" draggable="false">'
|
||||
var regExp = new RegExp(":" + shortcode + ":", "g")
|
||||
dis_name = dis_name.replace(regExp, emoji_url)
|
||||
note = note.replace(regExp, emoji_url)
|
||||
})
|
||||
Object.keys(json.emojis).forEach(function (key5) {
|
||||
var emoji = json.emojis[key5];
|
||||
var shortcode = emoji.shortcode;
|
||||
var emoji_url = '<img src="' + emoji.url + '" class="emoji-img" data-emoji="' + shortcode + '" draggable="false">';
|
||||
var regExp = new RegExp(":" + shortcode + ":", "g");
|
||||
dis_name = dis_name.replace(regExp, emoji_url);
|
||||
note = note.replace(regExp, emoji_url);
|
||||
});
|
||||
}
|
||||
//noteの解析
|
||||
//var tags = '<a onclick="tl(\'tag\',\'$1\',' + acct_id +',\'add\')" class="pointer parsed">#$1</a>';
|
||||
//var mens = '<a onclick="udgEx(\'$1\',' + acct_id +')" class="pointer parsed">@$1</a>';
|
||||
//note=note.replace(/#(\S+)/gi, tags)
|
||||
//note=note.replace(/\s@([a-zA-Z_0-9@.-]+)/gi, mens)
|
||||
$("#his-name").html(dis_name)
|
||||
$("#his-acct").text(json.acct)
|
||||
$("#his-acct").attr("fullname", fullname)
|
||||
$("#his-prof").attr("src", json.avatar)
|
||||
$("#his-data").css("background-image", "url(" + json.header + ")")
|
||||
$("#his-sta").text(json.statuses_count)
|
||||
$("#his-follow").text(json.following_count)
|
||||
var flerc = json.followers_count
|
||||
$("#his-name").html(dis_name);
|
||||
$("#his-acct").text(json.acct);
|
||||
$("#his-acct").attr("fullname", fullname);
|
||||
$("#his-prof").attr("src", json.avatar);
|
||||
$("#his-data").css("background-image", "url(" + json.header + ")");
|
||||
$("#his-sta").text(json.statuses_count);
|
||||
$("#his-follow").text(json.following_count);
|
||||
var flerc = json.followers_count;
|
||||
if (flerc < 0) {
|
||||
flerc = "-"
|
||||
flerc = "-";
|
||||
}
|
||||
$("#his-follower").text(flerc)
|
||||
$("#his-since").text(crat(json.created_at))
|
||||
$("#his-openin").attr("data-href", json.url)
|
||||
$("#his-follower").text(flerc);
|
||||
$("#his-since").text(crat(json.created_at));
|
||||
$("#his-openin").attr("data-href", json.url);
|
||||
if (json.fields) {
|
||||
var table = ""
|
||||
var table = "";
|
||||
if (json.fields.length > 0) {
|
||||
$("#his-des").css("max-height", "250px")
|
||||
table = '<table id="his-field">'
|
||||
$("#his-des").css("max-height", "250px");
|
||||
table = '<table id="his-field">';
|
||||
for (var i = 0; i < json.fields.length; i++) {
|
||||
var fname = json.fields[i].name
|
||||
var fval = json.fields[i].value
|
||||
var fname = json.fields[i].name;
|
||||
var fval = json.fields[i].value;
|
||||
if (json.fields[i].verified_at) {
|
||||
var when = lang.lang_showontl_verified + ":" + crat(json.fields[i].verified_at)
|
||||
var color = "rgba(121,189,154,.25);"
|
||||
var when = lang.lang_showontl_verified + ":" + crat(json.fields[i].verified_at);
|
||||
var color = "rgba(121,189,154,.25);";
|
||||
} else {
|
||||
var when = ""
|
||||
var color = "inherit"
|
||||
var when = "";
|
||||
var color = "inherit";
|
||||
}
|
||||
table = table + '<tr><td class="his-field-title">' + escapeHTML(fname) + '</td><td class="his-field-content" title="' + when + '" style="background-color:' + color + '">' + fval + "</td></tr>"
|
||||
table = table + '<tr><td class="his-field-title">' + escapeHTML(fname) + '</td><td class="his-field-content" title="' + when + '" style="background-color:' + color + '">' + fval + "</td></tr>";
|
||||
}
|
||||
table = table + "</table>"
|
||||
$("#his-des").html(twemoji.parse(note))
|
||||
table = table + "</table>";
|
||||
$("#his-des").html(twemoji.parse(note));
|
||||
} else {
|
||||
$("#his-des").css("max-height", "400px")
|
||||
$("#his-des").css("max-height", "400px");
|
||||
}
|
||||
$("#his-table").html(twemoji.parse(table))
|
||||
$("#his-table").html(twemoji.parse(table));
|
||||
} else {
|
||||
$("#his-des").css("max-height", "400px")
|
||||
$("#his-des").css("max-height", "400px");
|
||||
}
|
||||
$("#his-des").html(twemoji.parse(note))
|
||||
$("#his-des").html(twemoji.parse(note));
|
||||
if (json.bot) {
|
||||
$("#his-bot").html(lang.lang_showontl_botacct)
|
||||
$("#his-bot").html(lang.lang_showontl_botacct);
|
||||
}
|
||||
$("#his-des").attr("data-acct", acct_id)
|
||||
$("#his-data").css("background-size", "cover")
|
||||
$("#his-float-timeline").css("height", $("#his-data-show").height() + "px")
|
||||
localStorage.setItem("history", user)
|
||||
$("#his-des").attr("data-acct", acct_id);
|
||||
$("#his-data").css("background-size", "cover");
|
||||
$("#his-float-timeline").css("height", $("#his-data-show").height() + "px");
|
||||
localStorage.setItem("history", user);
|
||||
//自分の時
|
||||
if (json.acct == localStorage.getItem("user_" + acct_id)) {
|
||||
showFav("", acct_id)
|
||||
showBlo("", acct_id)
|
||||
showMut("", acct_id)
|
||||
showDom("", acct_id)
|
||||
showReq("", acct_id)
|
||||
showFrl("", acct_id)
|
||||
$("#his-name-val").val(json.display_name)
|
||||
showFav("", acct_id);
|
||||
showBlo("", acct_id);
|
||||
showMut("", acct_id);
|
||||
showDom("", acct_id);
|
||||
showReq("", acct_id);
|
||||
showFrl("", acct_id);
|
||||
$("#his-name-val").val(json.display_name);
|
||||
if (json.fields.length > 0) {
|
||||
if (json.fields[0]) {
|
||||
$("#his-f1-name").val(json.fields[0].name)
|
||||
$("#his-f1-val").val($.strip_tags(json.fields[0].value))
|
||||
$("#his-f1-name").val(json.fields[0].name);
|
||||
$("#his-f1-val").val($.strip_tags(json.fields[0].value));
|
||||
}
|
||||
if (json.fields[1]) {
|
||||
$("#his-f2-name").val(json.fields[1].name)
|
||||
$("#his-f2-val").val($.strip_tags(json.fields[1].value))
|
||||
$("#his-f2-name").val(json.fields[1].name);
|
||||
$("#his-f2-val").val($.strip_tags(json.fields[1].value));
|
||||
}
|
||||
if (json.fields[2]) {
|
||||
$("#his-f3-name").val(json.fields[2].name)
|
||||
$("#his-f3-val").val($.strip_tags(json.fields[2].value))
|
||||
$("#his-f3-name").val(json.fields[2].name);
|
||||
$("#his-f3-val").val($.strip_tags(json.fields[2].value));
|
||||
}
|
||||
if (json.fields[3]) {
|
||||
$("#his-f4-name").val(json.fields[3].name)
|
||||
$("#his-f4-val").val($.strip_tags(json.fields[3].value))
|
||||
$("#his-f4-name").val(json.fields[3].name);
|
||||
$("#his-f4-val").val($.strip_tags(json.fields[3].value));
|
||||
}
|
||||
}
|
||||
var des = json.note
|
||||
des = des.replace(/<br \/>/g, "\n")
|
||||
des = $.strip_tags(des)
|
||||
$("#his-des-val").val(des)
|
||||
$("#his-follow-btn").hide()
|
||||
$("#his-block-btn").hide()
|
||||
$("#his-mute-btn").hide()
|
||||
$("#his-notf-btn").hide()
|
||||
$("#his-domain-btn").hide()
|
||||
$("#his-emp-btn").hide()
|
||||
$(".only-my-data").show()
|
||||
$(".only-his-data").hide()
|
||||
var des = json.note;
|
||||
des = des.replace(/<br \/>/g, "\n");
|
||||
des = $.strip_tags(des);
|
||||
$("#his-des-val").val(des);
|
||||
$("#his-follow-btn").hide();
|
||||
$("#his-block-btn").hide();
|
||||
$("#his-mute-btn").hide();
|
||||
$("#his-notf-btn").hide();
|
||||
$("#his-domain-btn").hide();
|
||||
$("#his-emp-btn").hide();
|
||||
$(".only-my-data").show();
|
||||
$(".only-his-data").hide();
|
||||
if (localStorage.getItem("main") == acct_id) {
|
||||
$("#his-main-acct").hide()
|
||||
$("#his-main-acct").hide();
|
||||
}
|
||||
} else {
|
||||
relations(user, acct_id)
|
||||
$(".only-my-data").hide()
|
||||
$(".only-his-data").show()
|
||||
relations(user, acct_id);
|
||||
$(".only-my-data").hide();
|
||||
$(".only-his-data").show();
|
||||
}
|
||||
todc()
|
||||
if(json.locked) {
|
||||
todc();
|
||||
if (json.locked) {
|
||||
$('#his-data').addClass('locked')
|
||||
} else {
|
||||
$('#his-data').removeClass('locked')
|
||||
}
|
||||
//外部データ取得(死かもしれないので)
|
||||
udAdd(acct_id, user, json.url)
|
||||
})
|
||||
udAdd(acct_id, user, json.url);
|
||||
});
|
||||
}
|
||||
function misskeyUdg(user, acct_id) {
|
||||
reset()
|
||||
reset();
|
||||
if (!user) {
|
||||
user = localStorage.getItem("user-id_" + acct_id)
|
||||
user = localStorage.getItem("user-id_" + acct_id);
|
||||
}
|
||||
todo("User Data Loading...")
|
||||
var domain = localStorage.getItem("domain_" + acct_id)
|
||||
todo("User Data Loading...");
|
||||
var domain = localStorage.getItem("domain_" + acct_id);
|
||||
if (localStorage.getItem("mode_" + domain) != "misskey") {
|
||||
udg(user, acct_id)
|
||||
return
|
||||
udg(user, acct_id);
|
||||
return;
|
||||
}
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at")
|
||||
var start = "https://" + domain + "/api/users/show"
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at");
|
||||
var start = "https://" + domain + "/api/users/show";
|
||||
fetch(start, {
|
||||
method: "POST",
|
||||
headers: {
|
||||
@@ -271,130 +271,130 @@ function misskeyUdg(user, acct_id) {
|
||||
userId: user
|
||||
})
|
||||
})
|
||||
.then(function(response) {
|
||||
.then(function (response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
response.text().then(function (text) {
|
||||
setLog(response.url, response.status, text);
|
||||
});
|
||||
}
|
||||
return response.json()
|
||||
return response.json();
|
||||
})
|
||||
.catch(function(error) {
|
||||
todo(error)
|
||||
setLog(start, "JSON", error)
|
||||
console.error(error)
|
||||
.catch(function (error) {
|
||||
todo(error);
|
||||
setLog(start, "JSON", error);
|
||||
console.error(error);
|
||||
})
|
||||
.then(function(json) {
|
||||
.then(function (json) {
|
||||
//一つ前のユーザーデータ
|
||||
if (!localStorage.getItem("history")) {
|
||||
$("#his-history-btn").prop("disabled", true)
|
||||
$("#his-history-btn").prop("disabled", true);
|
||||
} else {
|
||||
$("#his-history-btn").prop("disabled", false)
|
||||
$("#his-data").attr("history", localStorage.getItem("history"))
|
||||
$("#his-history-btn").prop("disabled", false);
|
||||
$("#his-data").attr("history", localStorage.getItem("history"));
|
||||
}
|
||||
$("#his-data").modal("open")
|
||||
$("#his-data").attr("user-id", user)
|
||||
$("#his-data").attr("use-acct", acct_id)
|
||||
$("#his-data").modal("open");
|
||||
$("#his-data").attr("user-id", user);
|
||||
$("#his-data").attr("use-acct", acct_id);
|
||||
if (json.host) {
|
||||
//Remote
|
||||
$("#his-data").attr("remote", "false")
|
||||
var fullname = json.username + "@" + json.host
|
||||
$("#his-data").attr("remote", "false");
|
||||
var fullname = json.username + "@" + json.host;
|
||||
} else {
|
||||
$("#his-data").attr("remote", "false")
|
||||
var fullname = json.acct + "@" + domain
|
||||
$("#his-data").attr("remote", "false");
|
||||
var fullname = json.acct + "@" + domain;
|
||||
}
|
||||
utlShow(json.id, "", acct_id)
|
||||
flw(json.id, "", acct_id)
|
||||
fer(json.id, "", acct_id)
|
||||
utlShow(json.id, "", acct_id);
|
||||
flw(json.id, "", acct_id);
|
||||
fer(json.id, "", acct_id);
|
||||
if (json.name) {
|
||||
var dis_name = escapeHTML(json.name)
|
||||
dis_name = twemoji.parse(dis_name)
|
||||
var dis_name = escapeHTML(json.name);
|
||||
dis_name = twemoji.parse(dis_name);
|
||||
} else {
|
||||
var dis_name = json.name
|
||||
var dis_name = json.name;
|
||||
}
|
||||
$("#his-name").html(dis_name)
|
||||
$("#his-acct").text(json.username)
|
||||
$("#his-acct").attr("fullname", fullname)
|
||||
$("#his-prof").attr("src", json.avatarUrl)
|
||||
$("#his-data").css("background-image", "url(" + json.bannerUrl + ")")
|
||||
$("#his-sta").text(json.notesCount)
|
||||
$("#his-follow").text(json.followingCount)
|
||||
$("#his-follower").text(json.followersCount)
|
||||
$("#his-since").text(crat(json.createdAt))
|
||||
var note = escapeHTML(json.description)
|
||||
$("#his-des").html(twemoji.parse(note))
|
||||
$("#his-name").html(dis_name);
|
||||
$("#his-acct").text(json.username);
|
||||
$("#his-acct").attr("fullname", fullname);
|
||||
$("#his-prof").attr("src", json.avatarUrl);
|
||||
$("#his-data").css("background-image", "url(" + json.bannerUrl + ")");
|
||||
$("#his-sta").text(json.notesCount);
|
||||
$("#his-follow").text(json.followingCount);
|
||||
$("#his-follower").text(json.followersCount);
|
||||
$("#his-since").text(crat(json.createdAt));
|
||||
var note = escapeHTML(json.description);
|
||||
$("#his-des").html(twemoji.parse(note));
|
||||
if (json.isCat) {
|
||||
$("#his-bot").html("Cat" + twemoji.parse("😺"))
|
||||
$("#his-bot").html("Cat" + twemoji.parse("😺"));
|
||||
}
|
||||
$("#his-data").css("background-size", "cover")
|
||||
localStorage.setItem("history", user)
|
||||
$("#his-data").css("background-size", "cover");
|
||||
localStorage.setItem("history", user);
|
||||
//自分の時
|
||||
if (json.username == localStorage.getItem("user_" + acct_id) && !json.host) {
|
||||
//showFav('', acct_id);
|
||||
//showMut('', acct_id);
|
||||
//showReq('', acct_id);
|
||||
showFrl("", acct_id)
|
||||
$("#his-name-val").val(json.name)
|
||||
var des = json.note
|
||||
des = nl2br(des)
|
||||
des = $.strip_tags(des)
|
||||
$("#his-des-val").val(des)
|
||||
$("#his-follow-btn").hide()
|
||||
$("#his-block-btn").hide()
|
||||
$("#his-mute-btn").hide()
|
||||
$("#his-notf-btn").hide()
|
||||
$("#his-domain-btn").hide()
|
||||
$("#his-emp-btn").hide()
|
||||
$(".only-my-data").show()
|
||||
$(".only-his-data").hide()
|
||||
showFrl("", acct_id);
|
||||
$("#his-name-val").val(json.name);
|
||||
var des = json.note;
|
||||
des = nl2br(des);
|
||||
des = $.strip_tags(des);
|
||||
$("#his-des-val").val(des);
|
||||
$("#his-follow-btn").hide();
|
||||
$("#his-block-btn").hide();
|
||||
$("#his-mute-btn").hide();
|
||||
$("#his-notf-btn").hide();
|
||||
$("#his-domain-btn").hide();
|
||||
$("#his-emp-btn").hide();
|
||||
$(".only-my-data").show();
|
||||
$(".only-his-data").hide();
|
||||
if (localStorage.getItem("main") == acct_id) {
|
||||
$("#his-main-acct").hide()
|
||||
$("#his-main-acct").hide();
|
||||
}
|
||||
} else {
|
||||
if (json.isFollowing) {
|
||||
//自分がフォローしている
|
||||
$("#his-data").addClass("following")
|
||||
$("#his-follow-btn-text").text(lang.lang_status_unfollow)
|
||||
hisList(user, acct_id)
|
||||
$("#his-data").addClass("following");
|
||||
$("#his-follow-btn-text").text(lang.lang_status_unfollow);
|
||||
hisList(user, acct_id);
|
||||
} else {
|
||||
$("#his-follow-btn-text").text(lang.lang_status_follow)
|
||||
$("#his-follow-btn-text").text(lang.lang_status_follow);
|
||||
}
|
||||
if (json.isFollowed) {
|
||||
//フォローされてる
|
||||
$("#his-relation").text(lang.lang_showontl_followed)
|
||||
$("#his-relation").text(lang.lang_showontl_followed);
|
||||
}
|
||||
$("#his-block-btn").hide()
|
||||
$("#his-block-btn").hide();
|
||||
if (json.isMuted) {
|
||||
$("#his-data").addClass("muting")
|
||||
$("#his-mute-btn-text").text(lang.lang_status_unmute)
|
||||
$("#his-data").addClass("muting");
|
||||
$("#his-mute-btn-text").text(lang.lang_status_unmute);
|
||||
} else {
|
||||
$("#his-mute-btn-text").text(lang.lang_status_mute)
|
||||
$("#his-mute-btn-text").text(lang.lang_status_mute);
|
||||
}
|
||||
$(".only-my-data").hide()
|
||||
$(".only-his-data").show()
|
||||
$(".only-my-data").hide();
|
||||
$(".only-his-data").show();
|
||||
}
|
||||
todc()
|
||||
})
|
||||
todc();
|
||||
});
|
||||
}
|
||||
//一つ前のユーザーデータ表示
|
||||
function historyShow() {
|
||||
var acct_id = $("#his-data").attr("use-acct")
|
||||
var user = $("#his-data").attr("history")
|
||||
udg(user, acct_id, "true")
|
||||
var acct_id = $("#his-data").attr("use-acct");
|
||||
var user = $("#his-data").attr("history");
|
||||
udg(user, acct_id, "true");
|
||||
}
|
||||
//選択アカウントのプロフ
|
||||
function profShow() {
|
||||
var acct_id = $("#post-acct-sel").val()
|
||||
var user = localStorage.getItem("user-id_" + acct_id)
|
||||
udg(user, acct_id)
|
||||
hide()
|
||||
var acct_id = $("#post-acct-sel").val();
|
||||
var user = localStorage.getItem("user-id_" + acct_id);
|
||||
udg(user, acct_id);
|
||||
hide();
|
||||
}
|
||||
|
||||
//FF関係取得
|
||||
function relations(user, acct_id) {
|
||||
var domain = localStorage.getItem("domain_" + acct_id)
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at")
|
||||
var start = "https://" + domain + "/api/v1/accounts/relationships?id=" + user
|
||||
var domain = localStorage.getItem("domain_" + acct_id);
|
||||
var at = localStorage.getItem("acct_" + acct_id + "_at");
|
||||
var start = "https://" + domain + "/api/v1/accounts/relationships?id=" + user;
|
||||
fetch(start, {
|
||||
method: "GET",
|
||||
headers: {
|
||||
@@ -402,22 +402,22 @@ function relations(user, acct_id) {
|
||||
Authorization: "Bearer " + at
|
||||
}
|
||||
})
|
||||
.then(function(response) {
|
||||
.then(function (response) {
|
||||
if (!response.ok) {
|
||||
response.text().then(function(text) {
|
||||
setLog(response.url, response.status, text)
|
||||
})
|
||||
response.text().then(function (text) {
|
||||
setLog(response.url, response.status, text);
|
||||
});
|
||||
}
|
||||
return response.json()
|
||||
return response.json();
|
||||
})
|
||||
.catch(function(error) {
|
||||
todo(error)
|
||||
setLog(start, "JSON", error)
|
||||
console.error(error)
|
||||
.catch(function (error) {
|
||||
todo(error);
|
||||
setLog(start, "JSON", error);
|
||||
console.error(error);
|
||||
})
|
||||
.then(function(json) {
|
||||
var json = json[0]
|
||||
if(json.requested) {
|
||||
.then(function (json) {
|
||||
var json = json[0];
|
||||
if (json.requested) {
|
||||
//フォロリク中
|
||||
$('#his-data').addClass('following')
|
||||
$("#his-follow-btn-text").text(lang.lang_status_requesting)
|
||||
@@ -425,138 +425,138 @@ function relations(user, acct_id) {
|
||||
if (json.following) {
|
||||
//自分がフォローしている
|
||||
$("#his-data").addClass("following")
|
||||
$("#his-follow-btn-text").text(lang.lang_status_unfollow)
|
||||
hisList(user, acct_id)
|
||||
$("#his-follow-btn-text").text(lang.lang_status_unfollow);
|
||||
hisList(user, acct_id);
|
||||
} else {
|
||||
$("#his-follow-btn-text").text(lang.lang_status_follow)
|
||||
$("#his-follow-btn-text").text(lang.lang_status_follow);
|
||||
}
|
||||
if (json.followed_by) {
|
||||
//フォローされてる
|
||||
$("#his-relation").text(lang.lang_showontl_followed)
|
||||
$("#his-relation").text(lang.lang_showontl_followed);
|
||||
}
|
||||
if (json.blocking) {
|
||||
$("#his-data").addClass("blocking")
|
||||
$("#his-block-btn-text").text(lang.lang_status_unblock)
|
||||
$("#his-data").addClass("blocking");
|
||||
$("#his-block-btn-text").text(lang.lang_status_unblock);
|
||||
} else {
|
||||
$("#his-block-btn-text").text(lang.lang_status_block)
|
||||
$("#his-block-btn-text").text(lang.lang_status_block);
|
||||
}
|
||||
if (json.muting) {
|
||||
$("#his-data").addClass("muting")
|
||||
$("#his-mute-btn-text").text(lang.lang_status_unmute)
|
||||
$("#his-data").addClass("muting");
|
||||
$("#his-mute-btn-text").text(lang.lang_status_unmute);
|
||||
} else {
|
||||
$("#his-mute-btn-text").text(lang.lang_status_mute)
|
||||
$("#his-mute-btn-text").text(lang.lang_status_mute);
|
||||
}
|
||||
if (json.muting_notifications) {
|
||||
$("#his-data").addClass("mutingNotf")
|
||||
$("#his-notf-btn-text").text(lang.lang_showontl_notf + lang.lang_status_unmute)
|
||||
$("#his-data").addClass("mutingNotf");
|
||||
$("#his-notf-btn-text").text(lang.lang_showontl_notf + lang.lang_status_unmute);
|
||||
} else {
|
||||
$("#his-notf-btn-text").text(lang.lang_showontl_notf + lang.lang_status_mute)
|
||||
$("#his-notf-btn-text").text(lang.lang_showontl_notf + lang.lang_status_mute);
|
||||
}
|
||||
if (json.domain_blocking) {
|
||||
$("#his-data").addClass("blockingDom")
|
||||
$("#his-domain-btn-text").text(lang.lang_showontl_domain + lang.lang_status_unblock)
|
||||
$("#his-data").addClass("blockingDom");
|
||||
$("#his-domain-btn-text").text(lang.lang_showontl_domain + lang.lang_status_unblock);
|
||||
} else {
|
||||
$("#his-domain-btn-text").text(lang.lang_showontl_domain + lang.lang_status_block)
|
||||
$("#his-domain-btn-text").text(lang.lang_showontl_domain + lang.lang_status_block);
|
||||
}
|
||||
//Endorsed
|
||||
if (json.endorsed) {
|
||||
$("#his-end-btn").addClass("endorsed")
|
||||
$("#his-end-btn-text").text(lang.lang_status_unendorse)
|
||||
$("#his-end-btn").addClass("endorsed");
|
||||
$("#his-end-btn-text").text(lang.lang_status_unendorse);
|
||||
} else {
|
||||
$("#his-end-btn").removeClass("endorsed")
|
||||
$("#his-end-btn-text").text(lang.lang_status_endorse)
|
||||
$("#his-end-btn").removeClass("endorsed");
|
||||
$("#his-end-btn-text").text(lang.lang_status_endorse);
|
||||
}
|
||||
//Blocked
|
||||
if (json.blocked_by) {
|
||||
$("#my-data-nav .btn").addClass("disabled")
|
||||
$(".his-var-content").hide()
|
||||
$("#his-float-blocked").show()
|
||||
$("#his-follow-btn").hide()
|
||||
$("#my-data-nav .btn").addClass("disabled");
|
||||
$(".his-var-content").hide();
|
||||
$("#his-float-blocked").show();
|
||||
$("#his-follow-btn").hide();
|
||||
}
|
||||
})
|
||||
});
|
||||
}
|
||||
function profbrws() {
|
||||
var url = $("#his-openin").attr("data-href")
|
||||
postMessage(["openUrl", url], "*")
|
||||
var url = $("#his-openin").attr("data-href");
|
||||
postMessage(["openUrl", url], "*");
|
||||
}
|
||||
function setMain() {
|
||||
var acct_id = $("#his-data").attr("use-acct")
|
||||
localStorage.setItem("main", acct_id)
|
||||
multiSelector(true)
|
||||
M.toast({ html: lang.lang_manager_mainAcct, displayLength: 3000 })
|
||||
var acct_id = $("#his-data").attr("use-acct");
|
||||
localStorage.setItem("main", acct_id);
|
||||
multiSelector();
|
||||
M.toast({ html: lang.lang_manager_mainAcct, displayLength: 3000 });
|
||||
}
|
||||
//オールリセット
|
||||
function hisclose() {
|
||||
$("#his-data").modal("close")
|
||||
reset()
|
||||
$("#his-data").attr("history", "")
|
||||
localStorage.removeItem("history")
|
||||
$("#his-data").modal("close");
|
||||
reset();
|
||||
$("#his-data").attr("history", "");
|
||||
localStorage.removeItem("history");
|
||||
}
|
||||
function reset() {
|
||||
$(".his-var-content:eq(0)").show()
|
||||
$(".his-var-content:gt(0)").hide()
|
||||
$("#my-data-nav .btn").removeClass("disabled")
|
||||
$(".active-back").removeClass("active-back")
|
||||
$(".column-first").addClass("active-back")
|
||||
$("#his-name").text("Loading")
|
||||
$("#his-acct").text("")
|
||||
$("#his-prof").attr("src", "../../img/loading.svg")
|
||||
$("#his-data").css("background-image", "url(../../img/loading.svg)")
|
||||
$("#his-sta").text("")
|
||||
$("#his-follow").text("")
|
||||
$("#his-follower").text("")
|
||||
$("#his-des").html("")
|
||||
$("#his-data").css("background-size", "cover")
|
||||
$("#his-since").text("")
|
||||
$("#his-data").removeClass("following")
|
||||
$("#his-data").removeClass("muting")
|
||||
$("#his-data").removeClass("blocking")
|
||||
$("#his-data").removeClass("mutingNotf")
|
||||
$("#his-data").removeClass("blockingDom")
|
||||
$("#his-end-btn").removeClass("endorsed")
|
||||
$("#his-des").css("max-height", "250px")
|
||||
$("#his-bot").html("")
|
||||
$("#his-follow-btn").show()
|
||||
$("#his-block-btn").show()
|
||||
$("#his-mute-btn").show()
|
||||
$("#his-notf-btn").show()
|
||||
$("#his-domain-btn").show()
|
||||
$("#his-emp-btn").show()
|
||||
$("#his-follow-btn-text").text(lang.lang_status_follow)
|
||||
$("#his-mute-btn-text").text(lang.lang_status_mute)
|
||||
$("#his-block-btn-text").text(lang.lang_status_block)
|
||||
$("#his-notf-btn").text(lang.lang_showontl_notf + lang.lang_status_mute)
|
||||
$("#his-domain-btn").text(lang.lang_showontl_domain + lang.lang_status_block)
|
||||
$("#his-relation").text("")
|
||||
$(".cont-series").html("")
|
||||
$("#domainblock").val("")
|
||||
$("#his-lists-a").html(lang.lang_showontl_listwarn)
|
||||
$("#his-lists-b").html("")
|
||||
$("#his-name-val").val("")
|
||||
$("#his-des-val").val("")
|
||||
$("#his-f1-name").val("")
|
||||
$("#his-f1-val").val("")
|
||||
$("#his-f2-name").val("")
|
||||
$("#his-f2-val").val("")
|
||||
$("#his-f3-name").val("")
|
||||
$("#his-f3-val").val("")
|
||||
$("#his-f4-name").val("")
|
||||
$("#his-f4-val").val("")
|
||||
$("#his-endorse").html("")
|
||||
$("#his-openin").attr("data-href", "")
|
||||
$("#his-float-timeline").show()
|
||||
$("#his-float-blocked").hide()
|
||||
$("#his-main-acct").show()
|
||||
$("#his-proof-prof").html("")
|
||||
$(".his-var-content:eq(0)").show();
|
||||
$(".his-var-content:gt(0)").hide();
|
||||
$("#my-data-nav .btn").removeClass("disabled");
|
||||
$(".active-back").removeClass("active-back");
|
||||
$(".column-first").addClass("active-back");
|
||||
$("#his-name").text("Loading");
|
||||
$("#his-acct").text("");
|
||||
$("#his-prof").attr("src", "../../img/loading.svg");
|
||||
$("#his-data").css("background-image", "url(../../img/loading.svg)");
|
||||
$("#his-sta").text("");
|
||||
$("#his-follow").text("");
|
||||
$("#his-follower").text("");
|
||||
$("#his-des").html("");
|
||||
$("#his-data").css("background-size", "cover");
|
||||
$("#his-since").text("");
|
||||
$("#his-data").removeClass("following");
|
||||
$("#his-data").removeClass("muting");
|
||||
$("#his-data").removeClass("blocking");
|
||||
$("#his-data").removeClass("mutingNotf");
|
||||
$("#his-data").removeClass("blockingDom");
|
||||
$("#his-end-btn").removeClass("endorsed");
|
||||
$("#his-des").css("max-height", "250px");
|
||||
$("#his-bot").html("");
|
||||
$("#his-follow-btn").show();
|
||||
$("#his-block-btn").show();
|
||||
$("#his-mute-btn").show();
|
||||
$("#his-notf-btn").show();
|
||||
$("#his-domain-btn").show();
|
||||
$("#his-emp-btn").show();
|
||||
$("#his-follow-btn-text").text(lang.lang_status_follow);
|
||||
$("#his-mute-btn-text").text(lang.lang_status_mute);
|
||||
$("#his-block-btn-text").text(lang.lang_status_block);
|
||||
$("#his-notf-btn").text(lang.lang_showontl_notf + lang.lang_status_mute);
|
||||
$("#his-domain-btn").text(lang.lang_showontl_domain + lang.lang_status_block);
|
||||
$("#his-relation").text("");
|
||||
$(".cont-series").html("");
|
||||
$("#domainblock").val("");
|
||||
$("#his-lists-a").html(lang.lang_showontl_listwarn);
|
||||
$("#his-lists-b").html("");
|
||||
$("#his-name-val").val("");
|
||||
$("#his-des-val").val("");
|
||||
$("#his-f1-name").val("");
|
||||
$("#his-f1-val").val("");
|
||||
$("#his-f2-name").val("");
|
||||
$("#his-f2-val").val("");
|
||||
$("#his-f3-name").val("");
|
||||
$("#his-f3-val").val("");
|
||||
$("#his-f4-name").val("");
|
||||
$("#his-f4-val").val("");
|
||||
$("#his-endorse").html("");
|
||||
$("#his-openin").attr("data-href", "");
|
||||
$("#his-float-timeline").show();
|
||||
$("#his-float-blocked").hide();
|
||||
$("#his-main-acct").show();
|
||||
$("#his-proof-prof").html("");
|
||||
$('#his-data').removeClass('locked')
|
||||
$('#his-data').removeClass('requesting')
|
||||
}
|
||||
$("#my-data-nav .anc-link").on("click", function() {
|
||||
var target = $(this).attr("go")
|
||||
$("#my-data-nav .anc-link").on("click", function () {
|
||||
var target = $(this).attr("go");
|
||||
if (target) {
|
||||
$("#my-data-nav .anc-link").removeClass("active-back")
|
||||
$(this).addClass("active-back")
|
||||
$(target).show()
|
||||
$(".his-var-content:not(" + target + ")").hide()
|
||||
$("#my-data-nav .anc-link").removeClass("active-back");
|
||||
$(this).addClass("active-back");
|
||||
$(target).show();
|
||||
$(".his-var-content:not(" + target + ")").hide();
|
||||
}
|
||||
})
|
||||
});
|
||||
|
||||
@@ -28,7 +28,6 @@ function dl(mainWindow, lang_path, base, dirname) {
|
||||
show: false
|
||||
})
|
||||
var lang = fs.readFileSync(lang_path, 'utf8')
|
||||
//updatewin.toggleDevTools()
|
||||
updatewin.loadURL(base + lang + '/update.html')
|
||||
updatewin.webContents.once('dom-ready', () => {
|
||||
updatewin.show()
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
[
|
||||
"TheDeskは自称ステイホームの必須アイテム",
|
||||
"あと数秒でPCのファンが全力で回り始める",
|
||||
"カラムの数だけ夢があるがネットワークは逼迫する",
|
||||
"朝起きたらストリーミングが止まっていた…",
|
||||
@@ -49,7 +50,5 @@
|
||||
"N押すとトゥートのボックスが出て、すぐ打ち込める。",
|
||||
"Xを押すとトゥートのボックスは出るけど、打ち込めない。その代わりもう一度押すと消せる。",
|
||||
"トゥートした後ボックスを閉じるとかそのままにしておくとかは、設定で変えられます。",
|
||||
"OpenStickerへの登録データ募集中",
|
||||
"Microsoft Store版のアップデートは向こうに止められてます",
|
||||
"いのちの輝き版ロゴ"
|
||||
]
|
||||
"ヌァ=スコ゜、ケエンョ゛ハー゛オセム゛ヌトョ!。シレモゥチャスモハァーワ」。チスョ「ラネ゛ワフン(ァクミス"
|
||||
]
|
||||
@@ -6,7 +6,6 @@
|
||||
<link href="./css/tl.css" type="text/css" rel="stylesheet" />
|
||||
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet" />
|
||||
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" type="text/css" rel="stylesheet">
|
||||
<script type="text/javascript" src="./node_modules/grapheme-splitter/index.js"></script>
|
||||
<title>TheDesk Nano</title>
|
||||
<style>
|
||||
html {
|
||||
@@ -83,16 +82,12 @@
|
||||
.cvo {
|
||||
grid-template-rows: auto 1rem 1fr auto 2rem;
|
||||
}
|
||||
.voice {
|
||||
display: none;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<script type="text/javascript" src="./node_modules/jquery/dist/jquery.js"></script>
|
||||
<script>
|
||||
var pwa = false
|
||||
$.strip_tags = function(str, allowed) {
|
||||
if (!str) {
|
||||
return "";
|
||||
@@ -146,7 +141,7 @@
|
||||
}
|
||||
</script>
|
||||
<script src="https://twemoji.maxcdn.com/2/twemoji.min.js?2.7"></script>
|
||||
<script type="text/javascript" src="./js/platform/first.js"></script>
|
||||
<script type="text/javascript" src="view/en/main.js"></script>
|
||||
<script type="text/javascript" src="./js/post/status.js"></script>
|
||||
<script type="text/javascript" src="./js/post/post.js"></script>
|
||||
<script type="text/javascript" src="./js/post/use-txtbox.js"></script>
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
</head>
|
||||
|
||||
<body class="center" style="overflow: hidden;">
|
||||
<img src="./img/desk-animation.svg" id="leader" style="max-width: 62%;" />
|
||||
<img src="./img/desk-animation.svg" style="max-width: 62%;" />
|
||||
<h1>TheDesk</h1>
|
||||
<span id="ver"></span><br />
|
||||
<span class="loading"></span><br />
|
||||
@@ -84,12 +84,11 @@
|
||||
<script>
|
||||
if (location.search) {
|
||||
var m = location.search.match(/\?ver=([0-9.]+)&codename=([a-zA-Z]+)&maxim=(.+)/)
|
||||
var maxim = decodeURI(m[3])
|
||||
if(maxim == 'いのちの輝き版ロゴ') document.getElementById('leader').setAttribute('src', './img/2025.svg')
|
||||
var ver = m[1]
|
||||
var code = m[2]
|
||||
var maxim = m[3]
|
||||
document.getElementById('ver').innerText = `${ver}(${code})`
|
||||
document.getElementById('maxim').innerText = maxim
|
||||
document.getElementById('maxim').innerText = `${decodeURI(maxim)}`
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "thedesk",
|
||||
"version": "21.1.0",
|
||||
"version": "21.0.4",
|
||||
"codename": "Mayu",
|
||||
"description": "TheDesk is a Mastodon client for PC.",
|
||||
"repository": "https://github.com/cutls/TheDesk",
|
||||
@@ -15,9 +15,7 @@
|
||||
"build": "node view/make/make.js --automatic && npx electron-builder",
|
||||
"build:all": "npx electron-builder --win --linux",
|
||||
"build:win": "npx electron-builder --win",
|
||||
"build:pwa": "node view/make/make.js --automatic --pwa",
|
||||
"lint:fix": "eslint js --fix" ,
|
||||
"lint": "eslint js"
|
||||
"build:pwa": "node view/make/make.js --automatic --pwa"
|
||||
},
|
||||
"keywords": [
|
||||
"mastodon",
|
||||
@@ -35,8 +33,7 @@
|
||||
"url": "https://cutls.dev",
|
||||
"email": "p@cutls.com"
|
||||
},
|
||||
"contributor": [
|
||||
{
|
||||
"contributor": [{
|
||||
"name": "とねぢ",
|
||||
"url": "https://minohdon.jp/@toneji",
|
||||
"email": "solfa.tono@gmail.com"
|
||||
@@ -54,17 +51,17 @@
|
||||
],
|
||||
"license": "GPL-3.0",
|
||||
"dependencies": {
|
||||
"@fortawesome/fontawesome-free": "^5.14.0",
|
||||
"custom-electron-titlebar": "^3.2.3",
|
||||
"@fortawesome/fontawesome-free": "^5.13.1",
|
||||
"custom-electron-titlebar": "^3.2.2-hotfix62",
|
||||
"electron-dl": "^3.0.1",
|
||||
"jimp": "^0.14.0",
|
||||
"jquery": "^3.5.1",
|
||||
"jquery-ui-dist": "^1.12.1",
|
||||
"json5": "^2.1.3",
|
||||
"lodash": "^4.17.19",
|
||||
"lodash": "^4.17.15",
|
||||
"materialize-css": "git://github.com/cutls/materialize#v1-dev",
|
||||
"sumchecker": "^3.0.1",
|
||||
"sweetalert2": "^9.17.0",
|
||||
"sweetalert2": "^9.15.2",
|
||||
"system-font-families": "^0.4.1",
|
||||
"vue": "^2.6.11"
|
||||
},
|
||||
@@ -72,11 +69,10 @@
|
||||
"itunes-nowplaying-mac": "0.3.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"chokidar": "^3.4.1",
|
||||
"electron": "^9.1.1",
|
||||
"chokidar": "^3.4.0",
|
||||
"electron": "^9.0.5",
|
||||
"electron-builder": "^22.7.0",
|
||||
"electron-rebuild": "^1.11.0",
|
||||
"eslint": "^7.6.0",
|
||||
"readline-sync": "1.4.10"
|
||||
},
|
||||
"build": {
|
||||
@@ -131,4 +127,4 @@
|
||||
},
|
||||
"electronVersion": "9.0.5"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,5 @@
|
||||
{
|
||||
"latest":[],
|
||||
"3.2.0": [],
|
||||
"3.1.5": [],
|
||||
"3.1.4": [
|
||||
"リモート限定の連合タイムライン"
|
||||
],
|
||||
|
||||
@@ -69,7 +69,7 @@
|
||||
<div class="pwa">
|
||||
@@codesetupwarn@@<br />
|
||||
<label>
|
||||
<input type="checkbox" class="filled-in" id="linux" />
|
||||
<input type="checkbox" class="filled-in checked" id="linux" checked />
|
||||
<span>@@codesetup@@</span>
|
||||
</label>
|
||||
<br />
|
||||
@@ -128,17 +128,17 @@
|
||||
<div id="instance-data">
|
||||
Some instance data by
|
||||
<a href="https://instances.social" target="_blank">instances.social API</a><br />
|
||||
<h5 id="ins-title"></h5>
|
||||
Administered by:<a id="ins-admin"></a><br />
|
||||
<span id="ins-desc"></span><br />
|
||||
<h5 id="ins-title" class="ins-loading"></h5>
|
||||
Administered by:<a id="ins-admin" class="ins-loading"></a><br />
|
||||
<span id="ins-desc" class="ins-loading"></span><br />
|
||||
<img src="../../img/loading.svg" id="ins-prof" width="200" /><br />
|
||||
<br />
|
||||
@@domain@@:<span id="ins-name"></span><br />
|
||||
@@connect@@:<span id="ins-connect"></span>@@ko@@<br />
|
||||
@@toots@@:<span id="ins-toot"></span>@@ko@@<br />
|
||||
@@users@@:<span id="ins-user"></span>@@users@@<br />
|
||||
@@safety@@:<span id="ins-per"></span>%<br />
|
||||
@@ver@@:<span id="ins-ver"></span>@<span id="ins-upd"></span><br />
|
||||
@@domain@@:<span id="ins-name" class="ins-loading"></span><br />
|
||||
@@connect@@:<span id="ins-connect" class="ins-loading"></span>@@ko@@<br />
|
||||
@@toots@@:<span id="ins-toot" class="ins-loading"></span>@@ko@@<br />
|
||||
@@users@@:<span id="ins-user" class="ins-loading"></span>@@users@@<br />
|
||||
@@safety@@:<span id="ins-per" class="ins-loading"></span>%<br />
|
||||
@@ver@@:<span id="ins-ver" class="ins-loading"></span>@<span id="ins-upd" class="ins-loading"></span><br />
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript" src="../../js/ui/theme.js"></script>
|
||||
|
||||
@@ -417,6 +417,9 @@
|
||||
</div>
|
||||
<!-- 公開範囲 Dropdown Structure -->
|
||||
<ul id="dropdown1" class="dropdown-content">
|
||||
<li style="font-size: 1.2rem; display: block; line-height: 1.69rem; padding: 1.1rem 1.23rem;">
|
||||
@@selectVis@@
|
||||
</li>
|
||||
<li>
|
||||
<a onclick="vis('public')">@@publicJP@@(Public)</a>
|
||||
</li>
|
||||
@@ -1124,28 +1127,16 @@
|
||||
<a href="https://thedesk.top" target="_blank">HP</a><br />
|
||||
<a href="https://github.com/cutls/TheDesk" target="_blank">GitHub</a><br />
|
||||
<br />
|
||||
<div id="release-21-1-0_Mayu" class="release-do" style="display:none; ">
|
||||
<div id="release-21-0-4_Mayu" class="release-do" style="display:none; ">
|
||||
<br />
|
||||
<a href="https://ja.mstdn.wiki/TheDesk" target="_blank">機能一覧</a><br />
|
||||
Pixiv
|
||||
FanboxやPatreonでは支援者様限定で様々なTheDeskに関する記事をご覧いただけます。最低月一更新。<br />
|
||||
困ったときは、<a href="https://docs.thedesk.top">TheDesk Docs</a>をご覧ください。
|
||||
<h5>Release Note 21.1.0 (Mayu)</h5>
|
||||
<h5>Release Note 21.0.4 (Mayu)</h5>
|
||||
<!--上のdivのidも変えてね-->
|
||||
・コンテキストメニューが大きくずれるのを修正(今でもそれなりにズレます) <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・last_statusが日付だけ返すように変更されたことを受けての変更 <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・アクセシビリティ対応の向上(色覚異常者用) <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・Last.fmのアルバムアートワークについて、暫定的に添付可能に <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・ハッシュタグストリーミングについて、追加のタグのストリーミングを実装(master追従インスタンスのみ対応) <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・TheDesk Nanoについて全く動いていなかったのを修正 <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・サブスクリプションタイプのストリーミングに対応し、軽量化や安定性の向上が見込まれます。(master追従インスタンスのみ対応) <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・Unknownなメディアに対して、proxyを使うようにした。 <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・タイムライン間のマージンを変更できるように <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a> <img src="https://user-images.githubusercontent.com/17561618/92328367-4b2c1a00-f09b-11ea-9d7f-e2b2f586d806.png">axfelix<br>
|
||||
・アナウンスメントでリアクションが付与できないバグを修正 <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・ストリーミングが切れる可能性があるときに、画面を再読み込みするように。(master追従インスタンスのみ対応) <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・セレクタやドロップダウンのデザインの変更 <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・フォローやフォロワー、お気に入りの遡りが上手くできていなかった <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・一部のカスタム絵文字を含むユーザー名の表示が崩れる <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a> <a onclick="udgEx('AmaiSaeta@oransns.com','main')" class="contributor"><img src="https://user-images.githubusercontent.com/17561618/92328483-1a001980-f09c-11ea-92c7-4c30a276b8f8.png">AmaiSaeta</a><br>
|
||||
・起動しないバグ <a onclick="udgEx('Cutls@cutls.com','main')" class="contributor"><img src="https://media.thedesk.top/accounts/avatars/000/000/001/original/d34ef8bb49d5e011.png">cutls</a><br>
|
||||
・引用可能なインスタンスで、すべてのトゥートがミュートされた引用になってしまうバグ heguro<br>
|
||||
|
||||
</div>
|
||||
<div id="release-en" style="display:none">
|
||||
@@ -1547,7 +1538,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<a onclick="about()" class="nex waves-effect pwa">
|
||||
<a id="onClickAbout" class="nex waves-effect pwa">
|
||||
<i class="material-icons" style="font-size: 1rem;">info</i>@@about@@ </a
|
||||
> |
|
||||
<a onclick="bottomReverse()" class="nex waves-effect">
|
||||
@@ -1732,6 +1723,7 @@
|
||||
<!--JS-->
|
||||
<script type="text/javascript" src="../../@@node_base@@/jquery/dist/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../js/platform/first.js"></script>
|
||||
<script type="text/javascript" src="../../js/common/api.js"></script>
|
||||
<script type="text/javascript" src="../../@@node_base@@/grapheme-splitter/index.js"></script>
|
||||
<script
|
||||
type="text/javascript"
|
||||
|
||||
@@ -130,7 +130,7 @@
|
||||
"notf":"Notifications",
|
||||
"bookmark": "Bookmarks",
|
||||
"showThisTL":"Show this TL:",
|
||||
"webviewWarn":"TweetDeck with customed TJDeck(<a href='https://gist.github.com/cutls/8787a55d2c1c53274e68a427966046a6' target='_blank'>Code</a>/<a href='https://gist.github.com/totoraj930/d1394dadb51d75666a76829f61e7280c' target='_blank'>TJDeck</a>).",
|
||||
"webviewWarn":"TweetDeck with customed TJDeck(<a href='https://gist.github.com/cutls/8787a55d2c1c53274e68a427966046a6' target='_blank'>Code</a>/<a href='https://gist.github.com/totoraj930/d1394dadb51d75666a76829f61e7280c' target='_blank'>TJDeck</a>). Keyboard shortcuts will irritate you. When you feel so, you check 'Prefer WebView' on top of the column.",
|
||||
"add":"Add",
|
||||
"search":"Search",
|
||||
"sortSet":"Sort",
|
||||
|
||||
@@ -24,11 +24,10 @@
|
||||
"nativenotf": "Native notification",
|
||||
"nnwarn": "This does not work on Windows Portable ver.",
|
||||
"nntest": "Notification test",
|
||||
"width": "Width of columns",
|
||||
"widthwarn": "Scroll bar will be shown when your window size is more than ammounts of columns.",
|
||||
"minwidth": "Minimum width of columns",
|
||||
"minwidthwarn": "Scroll bar will be shown when your window size is more than ammounts of columns.",
|
||||
"fixwidth": "Minimum width of TweetDeck browser",
|
||||
"fixwidthwarn": "",
|
||||
"margin": "Margin between timelines",
|
||||
"above": "above",
|
||||
"font": "Font",
|
||||
"fontwarn": "Select your favorite font to 'Select'(On Linux, it may not work.)",
|
||||
@@ -102,8 +101,8 @@
|
||||
"or": "or",
|
||||
"imgheight": "Height of images",
|
||||
"imgheightwarn": "Option:Set \"full\" to uncrop.",
|
||||
"ticker": "Enable OpenSticker",
|
||||
"tickerwarn": "Show the instance name and favicon of tooters <a href=\"https://opensticker.0px.io\">About OpenSticker</a>",
|
||||
"ticker": "Enable #InstanceTicker",
|
||||
"tickerwarn": "Show colorful stickers about the server. <a href=\"https://github.com/MiyonMiyon/InstanceTicker_List\">About #InstanceTicker</a> (c)2018-2020 MiyonMiyon. Released under the MIT License.",
|
||||
"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.",
|
||||
|
||||
@@ -128,7 +128,7 @@
|
||||
"notf":"通知",
|
||||
"bookmark": "ブックマーク",
|
||||
"showThisTL":"表示するタイムライン",
|
||||
"webviewWarn":"TweetDeckを出すで。TJDeckをカスタムしたものが読み込まれる(<a href='https://gist.github.com/cutls/8787a55d2c1c53274e68a427966046a6' target='_blank'>Code</a>/<a href='https://gist.github.com/totoraj930/d1394dadb51d75666a76829f61e7280c' target='_blank'>TJDeck</a>)。",
|
||||
"webviewWarn":"TweetDeckを出すで。TJDeckをカスタムしたものが読み込まれる(<a href='https://gist.github.com/cutls/8787a55d2c1c53274e68a427966046a6' target='_blank'>Code</a>/<a href='https://gist.github.com/totoraj930/d1394dadb51d75666a76829f61e7280c' target='_blank'>TJDeck</a>)。キーボードショートカットと干渉しはるから、文字入れる時はカラムの「WebView優先」にチェック入れてからしてな。",
|
||||
"add":"追加",
|
||||
"search":"検索",
|
||||
"sortSet":"並べ替え設定",
|
||||
|
||||
@@ -3,8 +3,8 @@
|
||||
"lang_toot": "トゥート",
|
||||
"lang_there": "あり",
|
||||
"lang_nothing": "なし",
|
||||
"lang_yesno": "はい",
|
||||
"lang_no": "いいえ",
|
||||
"lang_yesno": "せやな",
|
||||
"lang_no": "ちゃうわ",
|
||||
"lang_progress": "処理中",
|
||||
"lang_edit": "編集",
|
||||
"lang_del": "削除",
|
||||
@@ -38,6 +38,7 @@
|
||||
"lang_version_platform_linux": "このソフトウェアSnapcraftからダウンロードしたんか?普通はホームページからインストールするし「いいえ」でええんやけど。「はい」にしたらSnapcraftはんがアップデートするからTheDeskはアップデートせえへん?とか言わへんようになる。",
|
||||
"lang_version_platform_mac": "このソフトウェアHomebrew caskからダウンロードしたんか?普通はホームページからインストールするし「いいえ」でええんやけど。「はい」にしたらHomebrew caskはんがアップデートするからTheDeskはアップデートせえへん?とか言わへんようになる。",
|
||||
"lang_login_noauth": "認証せんと見る",
|
||||
"lang_login_changedData": "プロフの情報が変わってしもたけど、もっかい読み込んだ方がええんちゃうか?",
|
||||
"lang_manager_info": "インスタンス情報",
|
||||
"lang_manager_refresh": "情報更新",
|
||||
"lang_manager_delete": "削除",
|
||||
|
||||
@@ -23,11 +23,10 @@
|
||||
"nativenotf": "ネイティブ通知設定",
|
||||
"nnwarn": "Portableバージョンでは表示できんかも知れん。",
|
||||
"nntest": "通知テスト",
|
||||
"width": "カラムの横幅",
|
||||
"widthwarn": "画面全体の横幅÷カラム数で計算してそれ超してもうたら横スクロール入るで。",
|
||||
"minwidth": "マルチカラムの最低横幅",
|
||||
"minwidthwarn": "画面全体の横幅÷コラム数で計算してそれ超してもうたら横スクロール入るで。",
|
||||
"fixwidth": "TweetDeckの限定の最低横幅",
|
||||
"fixwidthwarn": "",
|
||||
"margin": "TL間のマージン",
|
||||
"above": "以上",
|
||||
"font": "フォント",
|
||||
"fontwarn": "「選択」を押してフォントを選んでな。(Linuxでは動かんかもしれん。)",
|
||||
@@ -101,8 +100,8 @@
|
||||
"or": "または",
|
||||
"imgheight": "画像の高さ",
|
||||
"imgheightwarn": "オプション:「full」と指定すると全ての画像をクロップせず全部出すで。",
|
||||
"ticker": "OpenStickerを使う",
|
||||
"tickerwarn": "そのトゥートの発信者のサーバー名やFaviconを表示します。<a href=\"https://opensticker.0px.io\">OpenStickerについて</a>",
|
||||
"ticker": "#InstanceTickerを使う",
|
||||
"tickerwarn": "トゥートした人の所属サーバーをわかりやすく彩ります(自サーバー以外のトゥート向け)。<a href=\"https://github.com/MiyonMiyon/InstanceTicker_List\">#InstanceTickerってなんや?</a> (c)2018-2020 MiyonMiyon. Released under the MIT License.",
|
||||
"animation": "タイムラインのアニメーション",
|
||||
"markers": "ホームと通知の未読管理",
|
||||
"markerswarn": "Mastodon 3.0相当以上。WebUIと対応クライアントで共有するやつや。",
|
||||
|
||||
@@ -130,7 +130,7 @@
|
||||
"notf":"通知",
|
||||
"bookmark": "ブックマーク",
|
||||
"showThisTL":"表示するタイムライン",
|
||||
"webviewWarn":"TweetDeckを表示します。TJDeckをカスタムしたものが読み込まれます(<a href='https://gist.github.com/cutls/8787a55d2c1c53274e68a427966046a6' target='_blank'>Code</a>/<a href='https://gist.github.com/totoraj930/d1394dadb51d75666a76829f61e7280c' target='_blank'>TJDeck</a>)。",
|
||||
"webviewWarn":"TweetDeckを表示します。TJDeckをカスタムしたものが読み込まれます(<a href='https://gist.github.com/cutls/8787a55d2c1c53274e68a427966046a6' target='_blank'>Code</a>/<a href='https://gist.github.com/totoraj930/d1394dadb51d75666a76829f61e7280c' target='_blank'>TJDeck</a>)。キーボードショートカットが邪魔をするので、文字入力時はカラムの「WebView優先」にチェックを入れてください。",
|
||||
"add":"追加",
|
||||
"search":"検索",
|
||||
"sortSet":"並べ替え設定",
|
||||
|
||||
@@ -38,6 +38,7 @@
|
||||
"lang_version_platform_linux": "このソフトウェアはSnapcraft(snapd)からインストールしましたか?通常はホームページからインストールするため「いいえ」を選んでください。「はい」を選ぶとSnapcraftからアップデートが提供され、アップデートの通知を出しません。",
|
||||
"lang_version_platform_mac": "このソフトウェアはHomebrew Caskからインストールしましたか?通常はホームページからインストールするため「いいえ」を選んでください。「はい」を選ぶとアップデートの通知を出しません。",
|
||||
"lang_login_noauth": "認証せずに見る",
|
||||
"lang_login_changedData": "プロフィール情報が変更されました。再読み込みしますか?",
|
||||
"lang_manager_info": "インスタンス情報",
|
||||
"lang_manager_refresh": "情報更新",
|
||||
"lang_manager_delete": "削除",
|
||||
|
||||
@@ -24,11 +24,10 @@
|
||||
"nativenotf": "ネイティブ通知設定",
|
||||
"nnwarn": "Portableバージョンでは表示できません。",
|
||||
"nntest": "通知テスト",
|
||||
"width": "カラムの横幅",
|
||||
"widthwarn": "画面全体の横幅÷カラム数がこの値を超えた時、横スクロールとなります。",
|
||||
"minwidth": "マルチカラムの最低横幅",
|
||||
"minwidthwarn": "画面全体の横幅÷コラム数がこの値を超えた時、横スクロールとなります。",
|
||||
"fixwidth": "TweetDeckの限定の最低横幅",
|
||||
"fixwidthwarn": "",
|
||||
"margin": "TL間のマージン",
|
||||
"above": "以上",
|
||||
"font": "フォント",
|
||||
"fontwarn": "「選択」を押してフォントを選んでください。(Linuxでは動かない場合があります。)",
|
||||
@@ -102,8 +101,8 @@
|
||||
"or": "または",
|
||||
"imgheight": "画像の高さ",
|
||||
"imgheightwarn": "オプション:「full」と指定すると全ての画像をクロップしません。",
|
||||
"ticker": "OpenStickerを使う",
|
||||
"tickerwarn": "そのトゥートの発信者のサーバー名やFaviconを表示します。<a href=\"https://opensticker.0px.io\">OpenStickerについて</a>",
|
||||
"ticker": "#InstanceTickerを使う",
|
||||
"tickerwarn": "トゥートした人の所属サーバーをわかりやすく彩ります(自サーバー以外のトゥート向け)。<a href=\"https://github.com/MiyonMiyon/InstanceTicker_List\">#InstanceTickerについて</a> (c)2018-2020 MiyonMiyon. Released under the MIT License.",
|
||||
"animation": "タイムラインのアニメーション",
|
||||
"markers": "ホームと通知の未読管理",
|
||||
"markerswarn": "Mastodon 3.0相当以上。WebUIと対応クライアントで共有されます。",
|
||||
|
||||
@@ -515,7 +515,7 @@
|
||||
<button class="btn waves-effect red" style="width:100%; max-width:40rem;"
|
||||
onclick="if(confirm('@@resetconfirm@@')){ localStorage.clear(); location.href='index.html'; }"><i
|
||||
class="material-icons left">delete</i>@@reset@@</button><br><br>
|
||||
<button class="btn waves-effect indigo pwa" onclick="about()" style="width:100%; max-width:40rem;"><i
|
||||
<button class="btn waves-effect indigo pwa" id="onClickAbout" style="width:100%; max-width:40rem;"><i
|
||||
class="material-icons left">info</i>@@about@@</button>
|
||||
<a href="https://thedesk.top" class="btn waves-effect deep-purple lighten-2" style="width:100%; max-width:40rem;"><i
|
||||
class="material-icons left">web</i>@@hp@@</a>
|
||||
|
||||
@@ -60,40 +60,16 @@ var envConstruction = [
|
||||
}
|
||||
},
|
||||
{
|
||||
checkbox: false,
|
||||
doubleText: true,
|
||||
data: [
|
||||
{
|
||||
id: 'width',
|
||||
storage: 'width',
|
||||
width: 50,
|
||||
setValue: 300,
|
||||
text: { after: 'px ~ ' }
|
||||
},
|
||||
{
|
||||
id: 'maxWidth',
|
||||
storage: 'max-width',
|
||||
width: 50,
|
||||
setValue: 600,
|
||||
text: { after: 'px' }
|
||||
}
|
||||
],
|
||||
text: {
|
||||
head: '@@width@@',
|
||||
desc: '@@widthwarn@@'
|
||||
}
|
||||
},
|
||||
{
|
||||
id: 'margin',
|
||||
storage: 'margin',
|
||||
id: 'width',
|
||||
storage: 'width',
|
||||
checkbox: false,
|
||||
doubleText: false,
|
||||
setValue: 0,
|
||||
width: 50,
|
||||
setValue: 300,
|
||||
text: {
|
||||
head: '@@margin@@',
|
||||
desc: '',
|
||||
after: 'px'
|
||||
head: '@@minwidth@@',
|
||||
desc: '@@minwidthwarn@@',
|
||||
after: 'px @@above@@'
|
||||
}
|
||||
},
|
||||
{
|
||||
|
||||
@@ -83,10 +83,10 @@
|
||||
<script type="text/javascript" src="../../@@node_base@@/jquery/dist/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../js/platform/first.js"></script>
|
||||
<script type="text/javascript" src="../../@@node_base@@/materialize-css/dist/js/materialize.js"></script>
|
||||
<i class="material-icons pointer waves-effect" onclick="about();">info</i>
|
||||
<i class="material-icons pointer waves-effect" id="onClickAbout">info</i>
|
||||
<i class="material-icons pointer waves-effect" onclick="skipper();">clear</i>
|
||||
<!--a href="update.html">Reload</a-->
|
||||
<div id="start" style="filter: brightness(100%)">
|
||||
<div id="start">
|
||||
<div id="box" class="show">
|
||||
<h2>TheDesk</h2>
|
||||
<p>@@updatehere@@</p>
|
||||
|
||||
446
app/yarn.lock
446
app/yarn.lock
@@ -7,27 +7,6 @@
|
||||
resolved "https://registry.yarnpkg.com/7zip-bin/-/7zip-bin-5.0.3.tgz#bc5b5532ecafd923a61f2fb097e3b108c0106a3f"
|
||||
integrity sha512-GLyWIFBbGvpKPGo55JyRZAo4lVbnBiD52cKlw/0Vt+wnmKvWJkpZvsjVoaIolyBXDeAQKSicRtqFNPem9w0WYA==
|
||||
|
||||
"@babel/code-frame@^7.0.0":
|
||||
version "7.10.4"
|
||||
resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.10.4.tgz#168da1a36e90da68ae8d49c0f1b48c7c6249213a"
|
||||
integrity sha512-vG6SvB6oYEhvgisZNFRmRCUkLz11c7rp+tbNTynGqc6mS1d5ATd/sGyV6W0KZZnXRKMTzZDRgQT3Ou9jhpAfUg==
|
||||
dependencies:
|
||||
"@babel/highlight" "^7.10.4"
|
||||
|
||||
"@babel/helper-validator-identifier@^7.10.4":
|
||||
version "7.10.4"
|
||||
resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.10.4.tgz#a78c7a7251e01f616512d31b10adcf52ada5e0d2"
|
||||
integrity sha512-3U9y+43hz7ZM+rzG24Qe2mufW5KhvFg/NhnNph+i9mgCtdTCtMJuI1TMkrIUiK7Ix4PYlRF9I5dhqaLYA/ADXw==
|
||||
|
||||
"@babel/highlight@^7.10.4":
|
||||
version "7.10.4"
|
||||
resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.10.4.tgz#7d1bdfd65753538fabe6c38596cdb76d9ac60143"
|
||||
integrity sha512-i6rgnR/YgPEQzZZnbTHHuZdlE8qyoBNalD6F+q4vAFlcMEcqmkoG+mPqJYJCo63qPf74+Y1UZsl3l6f7/RIkmA==
|
||||
dependencies:
|
||||
"@babel/helper-validator-identifier" "^7.10.4"
|
||||
chalk "^2.0.0"
|
||||
js-tokens "^4.0.0"
|
||||
|
||||
"@babel/runtime@^7.7.2":
|
||||
version "7.8.4"
|
||||
resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.8.4.tgz#d79f5a2040f7caa24d53e563aad49cbc05581308"
|
||||
@@ -58,10 +37,10 @@
|
||||
global-agent "^2.0.2"
|
||||
global-tunnel-ng "^2.7.1"
|
||||
|
||||
"@fortawesome/fontawesome-free@^5.14.0":
|
||||
version "5.14.0"
|
||||
resolved "https://registry.yarnpkg.com/@fortawesome/fontawesome-free/-/fontawesome-free-5.14.0.tgz#a371e91029ebf265015e64f81bfbf7d228c9681f"
|
||||
integrity sha512-OfdMsF+ZQgdKHP9jUbmDcRrP0eX90XXrsXIdyjLbkmSBzmMXPABB8eobUJtivaupucYaByz6WNe1PI1JuYm3qA==
|
||||
"@fortawesome/fontawesome-free@^5.13.1":
|
||||
version "5.13.1"
|
||||
resolved "https://registry.yarnpkg.com/@fortawesome/fontawesome-free/-/fontawesome-free-5.13.1.tgz#c53b4066edae16cd1fd669f687baf031b45fb9d6"
|
||||
integrity sha512-D819f34FLHeBN/4xvw0HR0u7U2G7RqjPSggXqf7LktsxWQ48VAfGwvMrhcVuaZV2fF069c/619RdgCCms0DHhw==
|
||||
|
||||
"@jimp/bmp@^0.14.0":
|
||||
version "0.14.0"
|
||||
@@ -409,31 +388,11 @@ abbrev@1:
|
||||
resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8"
|
||||
integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==
|
||||
|
||||
acorn-jsx@^5.2.0:
|
||||
version "5.2.0"
|
||||
resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.2.0.tgz#4c66069173d6fdd68ed85239fc256226182b2ebe"
|
||||
integrity sha512-HiUX/+K2YpkpJ+SzBffkM/AQ2YE03S0U1kjTLVpoJdhZMOWy8qvXVN9JdLqv2QsaQ6MPYQIuNmwD8zOiYUofLQ==
|
||||
|
||||
acorn@^7.3.1:
|
||||
version "7.3.1"
|
||||
resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.3.1.tgz#85010754db53c3fbaf3b9ea3e083aa5c5d147ffd"
|
||||
integrity sha512-tLc0wSnatxAQHVHUapaHdz72pi9KUyHjq5KyHjGg9Y8Ifdc79pTh2XvI6I1/chZbnM7QtNKzh66ooDogPZSleA==
|
||||
|
||||
ajv-keywords@^3.4.1:
|
||||
version "3.4.1"
|
||||
resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-3.4.1.tgz#ef916e271c64ac12171fd8384eaae6b2345854da"
|
||||
integrity sha512-RO1ibKvd27e6FEShVFfPALuHI3WjSVNeK5FIsmme/LYRNxjKuNj+Dt7bucLa6NdSv3JcVTyMlm9kGR84z1XpaQ==
|
||||
|
||||
ajv@^6.10.0, ajv@^6.10.2:
|
||||
version "6.12.3"
|
||||
resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.3.tgz#18c5af38a111ddeb4f2697bd78d68abc1cabd706"
|
||||
integrity sha512-4K0cK3L1hsqk9xIb2z9vs/XU+PGJZ9PNpJRDS9YLzmNdX6jmVPfamLvTJr0aDAusnHyCHO6MjzlkAsgtqp9teA==
|
||||
dependencies:
|
||||
fast-deep-equal "^3.1.1"
|
||||
fast-json-stable-stringify "^2.0.0"
|
||||
json-schema-traverse "^0.4.1"
|
||||
uri-js "^4.2.2"
|
||||
|
||||
ajv@^6.12.0:
|
||||
version "6.12.0"
|
||||
resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.0.tgz#06d60b96d87b8454a5adaba86e7854da629db4b7"
|
||||
@@ -461,11 +420,6 @@ ansi-align@^3.0.0:
|
||||
dependencies:
|
||||
string-width "^3.0.0"
|
||||
|
||||
ansi-colors@^4.1.1:
|
||||
version "4.1.1"
|
||||
resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-4.1.1.tgz#cbb9ae256bf750af1eab344f229aa27fe94ba348"
|
||||
integrity sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==
|
||||
|
||||
ansi-regex@^2.0.0:
|
||||
version "2.1.1"
|
||||
resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df"
|
||||
@@ -579,11 +533,6 @@ assert-plus@1.0.0, assert-plus@^1.0.0:
|
||||
resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz#f12e0f3c5d77b0b1cdd9146942e4e96c1e4dd525"
|
||||
integrity sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=
|
||||
|
||||
astral-regex@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/astral-regex/-/astral-regex-1.0.0.tgz#6c8c3fb827dd43ee3918f27b82782ab7658a6fd9"
|
||||
integrity sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==
|
||||
|
||||
async-exit-hook@^2.0.1:
|
||||
version "2.0.1"
|
||||
resolved "https://registry.yarnpkg.com/async-exit-hook/-/async-exit-hook-2.0.1.tgz#8bd8b024b0ec9b1c01cccb9af9db29bd717dfaf3"
|
||||
@@ -763,11 +712,6 @@ cacheable-request@^6.0.0:
|
||||
normalize-url "^4.1.0"
|
||||
responselike "^1.0.2"
|
||||
|
||||
callsites@^3.0.0:
|
||||
version "3.1.0"
|
||||
resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73"
|
||||
integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==
|
||||
|
||||
camelcase@^5.0.0, camelcase@^5.3.1:
|
||||
version "5.3.1"
|
||||
resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320"
|
||||
@@ -778,7 +722,7 @@ caseless@~0.12.0:
|
||||
resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc"
|
||||
integrity sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=
|
||||
|
||||
chalk@^2.0.0, chalk@^2.0.1, chalk@^2.4.2:
|
||||
chalk@^2.0.1, chalk@^2.4.2:
|
||||
version "2.4.2"
|
||||
resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424"
|
||||
integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==
|
||||
@@ -803,10 +747,10 @@ chalk@^4.0.0:
|
||||
ansi-styles "^4.1.0"
|
||||
supports-color "^7.1.0"
|
||||
|
||||
chokidar@^3.4.1:
|
||||
version "3.4.1"
|
||||
resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.4.1.tgz#e905bdecf10eaa0a0b1db0c664481cc4cbc22ba1"
|
||||
integrity sha512-TQTJyr2stihpC4Sya9hs2Xh+O2wf+igjL36Y75xx2WdHuiICcn/XJza46Jwt0eT5hVpQOzo3FpY3cj3RVYLX0g==
|
||||
chokidar@^3.4.0:
|
||||
version "3.4.0"
|
||||
resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.4.0.tgz#b30611423ce376357c765b9b8f904b9fba3c0be8"
|
||||
integrity sha512-aXAaho2VJtisB/1fg1+3nlLJqGOuewTzQpd/Tz0yTg2R0e4IGtshYvtjowyEumcBv2z+y4+kc75Mz7j5xJskcQ==
|
||||
dependencies:
|
||||
anymatch "~3.1.1"
|
||||
braces "~3.0.2"
|
||||
@@ -976,24 +920,15 @@ core-util-is@1.0.2, core-util-is@~1.0.0:
|
||||
resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7"
|
||||
integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=
|
||||
|
||||
cross-spawn@^7.0.2:
|
||||
version "7.0.3"
|
||||
resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.3.tgz#f73a85b9d5d41d045551c177e2882d4ac85728a6"
|
||||
integrity sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==
|
||||
dependencies:
|
||||
path-key "^3.1.0"
|
||||
shebang-command "^2.0.0"
|
||||
which "^2.0.1"
|
||||
|
||||
crypto-random-string@^2.0.0:
|
||||
version "2.0.0"
|
||||
resolved "https://registry.yarnpkg.com/crypto-random-string/-/crypto-random-string-2.0.0.tgz#ef2a7a966ec11083388369baa02ebead229b30d5"
|
||||
integrity sha512-v1plID3y9r/lPhviJ1wrXpLeyUIGAZ2SHNYTEapm7/8A9nLPoyvVp3RK/EPFqn5kEznyWgYZNsRtYYIWbuG8KA==
|
||||
|
||||
custom-electron-titlebar@^3.2.3:
|
||||
version "3.2.3"
|
||||
resolved "https://registry.yarnpkg.com/custom-electron-titlebar/-/custom-electron-titlebar-3.2.3.tgz#41da10b97958639e96a04275051bb5f78a666fc3"
|
||||
integrity sha512-7DIZELlDoiAKT+i73XF9EG778M3/SYMmGa867cn3d0mLEEXDtEJq9sqM/u57vrtjolXKJ5ZJQ9hCCL2uxx9nxQ==
|
||||
custom-electron-titlebar@^3.2.2-hotfix62:
|
||||
version "3.2.2-hotfix62"
|
||||
resolved "https://registry.yarnpkg.com/custom-electron-titlebar/-/custom-electron-titlebar-3.2.2-hotfix62.tgz#94b908f0f2bf812e4f65447a26b93b88f7a76088"
|
||||
integrity sha512-Kh86xAolkCpqj4AD/H4HcR2pEtxUyIHzMzqwkxqZkSqE7R9tRfN8G3fVpiiNIAJlX8rbN3VwxaoHi1B1sSMn/Q==
|
||||
|
||||
dashdash@^1.12.0:
|
||||
version "1.14.1"
|
||||
@@ -1009,7 +944,7 @@ debug@2.6.9, debug@^2.5.1:
|
||||
dependencies:
|
||||
ms "2.0.0"
|
||||
|
||||
debug@^4.0.1, debug@^4.1.0, debug@^4.1.1:
|
||||
debug@^4.1.0, debug@^4.1.1:
|
||||
version "4.1.1"
|
||||
resolved "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz#3b72260255109c6b589cee050f1d516139664791"
|
||||
integrity sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==
|
||||
@@ -1040,11 +975,6 @@ deep-extend@^0.6.0:
|
||||
resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.6.0.tgz#c4fa7c95404a17a9c3e8ca7e1537312b736330ac"
|
||||
integrity sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==
|
||||
|
||||
deep-is@^0.1.3:
|
||||
version "0.1.3"
|
||||
resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34"
|
||||
integrity sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=
|
||||
|
||||
defaults@^1.0.3:
|
||||
version "1.0.3"
|
||||
resolved "https://registry.yarnpkg.com/defaults/-/defaults-1.0.3.tgz#c656051e9817d9ff08ed881477f3fe4019f3ef7d"
|
||||
@@ -1096,13 +1026,6 @@ dmg-builder@22.7.0:
|
||||
js-yaml "^3.14.0"
|
||||
sanitize-filename "^1.6.3"
|
||||
|
||||
doctrine@^3.0.0:
|
||||
version "3.0.0"
|
||||
resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-3.0.0.tgz#addebead72a6574db783639dc87a121773973961"
|
||||
integrity sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==
|
||||
dependencies:
|
||||
esutils "^2.0.2"
|
||||
|
||||
dom-walk@^0.1.0:
|
||||
version "0.1.1"
|
||||
resolved "https://registry.yarnpkg.com/dom-walk/-/dom-walk-0.1.1.tgz#672226dc74c8f799ad35307df936aba11acd6018"
|
||||
@@ -1203,10 +1126,10 @@ electron-rebuild@^1.11.0:
|
||||
spawn-rx "^3.0.0"
|
||||
yargs "^14.2.0"
|
||||
|
||||
electron@^9.1.1:
|
||||
version "9.1.1"
|
||||
resolved "https://registry.yarnpkg.com/electron/-/electron-9.1.1.tgz#d52c9873be4113287c3eb2b02f85bad6644b100e"
|
||||
integrity sha512-BYvroBLV9x7G4iN33P/IxeZqwjl62/9VuBAF1CoM0m6OeheaiLog1ZMKLlCqVXycJvvrAvLHc454DDEmwnqqhA==
|
||||
electron@^9.0.5:
|
||||
version "9.0.5"
|
||||
resolved "https://registry.yarnpkg.com/electron/-/electron-9.0.5.tgz#189ee117cc2a2777cccf40fae0766acec5faae57"
|
||||
integrity sha512-bnL9H48LuQ250DML8xUscsKiuSu+xv5umXbpBXYJ0BfvYVmFfNbG3jCfhrsH7aP6UcQKVxOG1R/oQExd0EFneQ==
|
||||
dependencies:
|
||||
"@electron/get" "^1.0.1"
|
||||
"@types/node" "^12.0.12"
|
||||
@@ -1234,13 +1157,6 @@ end-of-stream@^1.1.0:
|
||||
dependencies:
|
||||
once "^1.4.0"
|
||||
|
||||
enquirer@^2.3.5:
|
||||
version "2.3.6"
|
||||
resolved "https://registry.yarnpkg.com/enquirer/-/enquirer-2.3.6.tgz#2a7fe5dd634a1e4125a975ec994ff5456dc3734d"
|
||||
integrity sha512-yjNnPr315/FjS4zIsUxYguYUPP2e1NK4d7E7ZOLiyYCcbFBiTMyID+2wvm2w6+pZ/odMA7cRkjhsPbltwBOrLg==
|
||||
dependencies:
|
||||
ansi-colors "^4.1.1"
|
||||
|
||||
env-paths@^2.2.0:
|
||||
version "2.2.0"
|
||||
resolved "https://registry.yarnpkg.com/env-paths/-/env-paths-2.2.0.tgz#cdca557dc009152917d6166e2febe1f039685e43"
|
||||
@@ -1291,111 +1207,11 @@ escape-string-regexp@^2.0.0:
|
||||
resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz#a30304e99daa32e23b2fd20f51babd07cffca344"
|
||||
integrity sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w==
|
||||
|
||||
eslint-scope@^5.1.0:
|
||||
version "5.1.0"
|
||||
resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-5.1.0.tgz#d0f971dfe59c69e0cada684b23d49dbf82600ce5"
|
||||
integrity sha512-iiGRvtxWqgtx5m8EyQUJihBloE4EnYeGE/bz1wSPwJE6tZuJUtHlhqDM4Xj2ukE8Dyy1+HCZ4hE0fzIVMzb58w==
|
||||
dependencies:
|
||||
esrecurse "^4.1.0"
|
||||
estraverse "^4.1.1"
|
||||
|
||||
eslint-utils@^2.1.0:
|
||||
version "2.1.0"
|
||||
resolved "https://registry.yarnpkg.com/eslint-utils/-/eslint-utils-2.1.0.tgz#d2de5e03424e707dc10c74068ddedae708741b27"
|
||||
integrity sha512-w94dQYoauyvlDc43XnGB8lU3Zt713vNChgt4EWwhXAP2XkBvndfxF0AgIqKOOasjPIPzj9JqgwkwbCYD0/V3Zg==
|
||||
dependencies:
|
||||
eslint-visitor-keys "^1.1.0"
|
||||
|
||||
eslint-visitor-keys@^1.1.0, eslint-visitor-keys@^1.3.0:
|
||||
version "1.3.0"
|
||||
resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz#30ebd1ef7c2fdff01c3a4f151044af25fab0523e"
|
||||
integrity sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==
|
||||
|
||||
eslint@^7.6.0:
|
||||
version "7.6.0"
|
||||
resolved "https://registry.yarnpkg.com/eslint/-/eslint-7.6.0.tgz#522d67cfaea09724d96949c70e7a0550614d64d6"
|
||||
integrity sha512-QlAManNtqr7sozWm5TF4wIH9gmUm2hE3vNRUvyoYAa4y1l5/jxD/PQStEjBMQtCqZmSep8UxrcecI60hOpe61w==
|
||||
dependencies:
|
||||
"@babel/code-frame" "^7.0.0"
|
||||
ajv "^6.10.0"
|
||||
chalk "^4.0.0"
|
||||
cross-spawn "^7.0.2"
|
||||
debug "^4.0.1"
|
||||
doctrine "^3.0.0"
|
||||
enquirer "^2.3.5"
|
||||
eslint-scope "^5.1.0"
|
||||
eslint-utils "^2.1.0"
|
||||
eslint-visitor-keys "^1.3.0"
|
||||
espree "^7.2.0"
|
||||
esquery "^1.2.0"
|
||||
esutils "^2.0.2"
|
||||
file-entry-cache "^5.0.1"
|
||||
functional-red-black-tree "^1.0.1"
|
||||
glob-parent "^5.0.0"
|
||||
globals "^12.1.0"
|
||||
ignore "^4.0.6"
|
||||
import-fresh "^3.0.0"
|
||||
imurmurhash "^0.1.4"
|
||||
is-glob "^4.0.0"
|
||||
js-yaml "^3.13.1"
|
||||
json-stable-stringify-without-jsonify "^1.0.1"
|
||||
levn "^0.4.1"
|
||||
lodash "^4.17.19"
|
||||
minimatch "^3.0.4"
|
||||
natural-compare "^1.4.0"
|
||||
optionator "^0.9.1"
|
||||
progress "^2.0.0"
|
||||
regexpp "^3.1.0"
|
||||
semver "^7.2.1"
|
||||
strip-ansi "^6.0.0"
|
||||
strip-json-comments "^3.1.0"
|
||||
table "^5.2.3"
|
||||
text-table "^0.2.0"
|
||||
v8-compile-cache "^2.0.3"
|
||||
|
||||
espree@^7.2.0:
|
||||
version "7.2.0"
|
||||
resolved "https://registry.yarnpkg.com/espree/-/espree-7.2.0.tgz#1c263d5b513dbad0ac30c4991b93ac354e948d69"
|
||||
integrity sha512-H+cQ3+3JYRMEIOl87e7QdHX70ocly5iW4+dttuR8iYSPr/hXKFb+7dBsZ7+u1adC4VrnPlTkv0+OwuPnDop19g==
|
||||
dependencies:
|
||||
acorn "^7.3.1"
|
||||
acorn-jsx "^5.2.0"
|
||||
eslint-visitor-keys "^1.3.0"
|
||||
|
||||
esprima@^4.0.0:
|
||||
version "4.0.1"
|
||||
resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71"
|
||||
integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==
|
||||
|
||||
esquery@^1.2.0:
|
||||
version "1.3.1"
|
||||
resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.3.1.tgz#b78b5828aa8e214e29fb74c4d5b752e1c033da57"
|
||||
integrity sha512-olpvt9QG0vniUBZspVRN6lwB7hOZoTRtT+jzR+tS4ffYx2mzbw+z0XCOk44aaLYKApNX5nMm+E+P6o25ip/DHQ==
|
||||
dependencies:
|
||||
estraverse "^5.1.0"
|
||||
|
||||
esrecurse@^4.1.0:
|
||||
version "4.2.1"
|
||||
resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.2.1.tgz#007a3b9fdbc2b3bb87e4879ea19c92fdbd3942cf"
|
||||
integrity sha512-64RBB++fIOAXPw3P9cy89qfMlvZEXZkqqJkjqqXIvzP5ezRZjW+lPWjw35UX/3EhUPFYbg5ER4JYgDw4007/DQ==
|
||||
dependencies:
|
||||
estraverse "^4.1.0"
|
||||
|
||||
estraverse@^4.1.0, estraverse@^4.1.1:
|
||||
version "4.3.0"
|
||||
resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d"
|
||||
integrity sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==
|
||||
|
||||
estraverse@^5.1.0:
|
||||
version "5.1.0"
|
||||
resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.1.0.tgz#374309d39fd935ae500e7b92e8a6b4c720e59642"
|
||||
integrity sha512-FyohXK+R0vE+y1nHLoBM7ZTyqRpqAlhdZHCWIWEviFLiGB8b04H6bQs8G+XTthacvT8VuwvteiP7RJSxMs8UEw==
|
||||
|
||||
esutils@^2.0.2:
|
||||
version "2.0.3"
|
||||
resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64"
|
||||
integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==
|
||||
|
||||
exif-parser@^0.1.12:
|
||||
version "0.1.12"
|
||||
resolved "https://registry.yarnpkg.com/exif-parser/-/exif-parser-0.1.12.tgz#58a9d2d72c02c1f6f02a0ef4a9166272b7760922"
|
||||
@@ -1456,11 +1272,6 @@ fast-json-stable-stringify@^2.0.0:
|
||||
resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2"
|
||||
integrity sha1-1RQsDK7msRifh9OnYREGT4bIu/I=
|
||||
|
||||
fast-levenshtein@^2.0.6:
|
||||
version "2.0.6"
|
||||
resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917"
|
||||
integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=
|
||||
|
||||
fd-slicer@~1.0.1:
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/fd-slicer/-/fd-slicer-1.0.1.tgz#8b5bcbd9ec327c5041bf9ab023fd6750f1177e65"
|
||||
@@ -1468,13 +1279,6 @@ fd-slicer@~1.0.1:
|
||||
dependencies:
|
||||
pend "~1.2.0"
|
||||
|
||||
file-entry-cache@^5.0.1:
|
||||
version "5.0.1"
|
||||
resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-5.0.1.tgz#ca0f6efa6dd3d561333fb14515065c2fafdf439c"
|
||||
integrity sha512-bCg29ictuBaKUwwArK4ouCaqDgLZcysCFLmM/Yn/FDoqndh/9vNuQfXRDvTuXKLxfD/JtZQGKFT8MGcJBK644g==
|
||||
dependencies:
|
||||
flat-cache "^2.0.1"
|
||||
|
||||
file-type@^9.0.0:
|
||||
version "9.0.0"
|
||||
resolved "https://registry.yarnpkg.com/file-type/-/file-type-9.0.0.tgz#a68d5ad07f486414dfb2c8866f73161946714a18"
|
||||
@@ -1509,20 +1313,6 @@ find-up@^4.1.0:
|
||||
locate-path "^5.0.0"
|
||||
path-exists "^4.0.0"
|
||||
|
||||
flat-cache@^2.0.1:
|
||||
version "2.0.1"
|
||||
resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-2.0.1.tgz#5d296d6f04bda44a4630a301413bdbc2ec085ec0"
|
||||
integrity sha512-LoQe6yDuUMDzQAEH8sgmh4Md6oZnc/7PjtwjNFSzveXqSHt6ka9fPBuso7IGf9Rz4uqnSnWiFH2B/zj24a5ReA==
|
||||
dependencies:
|
||||
flatted "^2.0.0"
|
||||
rimraf "2.6.3"
|
||||
write "1.0.3"
|
||||
|
||||
flatted@^2.0.0:
|
||||
version "2.0.2"
|
||||
resolved "https://registry.yarnpkg.com/flatted/-/flatted-2.0.2.tgz#4575b21e2bcee7434aa9be662f4b7b5f9c2b5138"
|
||||
integrity sha512-r5wGx7YeOwNWNlCA0wQ86zKyDLMQr+/RB8xy74M4hTphfmjlijTSSXGuH8rnvKZnfT9i+75zmd8jcKdMR4O6jA==
|
||||
|
||||
for-each@^0.3.3:
|
||||
version "0.3.3"
|
||||
resolved "https://registry.yarnpkg.com/for-each/-/for-each-0.3.3.tgz#69b447e88a0a5d32c3e7084f3f1710034b21376e"
|
||||
@@ -1585,11 +1375,6 @@ function-bind@^1.1.1:
|
||||
resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d"
|
||||
integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==
|
||||
|
||||
functional-red-black-tree@^1.0.1:
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327"
|
||||
integrity sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc=
|
||||
|
||||
gauge@~2.7.3:
|
||||
version "2.7.4"
|
||||
resolved "https://registry.yarnpkg.com/gauge/-/gauge-2.7.4.tgz#2c03405c7538c39d7eb37b317022e325fb018bf7"
|
||||
@@ -1638,13 +1423,6 @@ gifwrap@^0.9.2:
|
||||
image-q "^1.1.1"
|
||||
omggif "^1.0.10"
|
||||
|
||||
glob-parent@^5.0.0:
|
||||
version "5.1.1"
|
||||
resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.1.tgz#b6c1ef417c4e5663ea498f1c45afac6916bbc229"
|
||||
integrity sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ==
|
||||
dependencies:
|
||||
is-glob "^4.0.1"
|
||||
|
||||
glob-parent@~5.1.0:
|
||||
version "5.1.0"
|
||||
resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.0.tgz#5f4c1d1e748d30cd73ad2944b3577a81b081e8c2"
|
||||
@@ -1702,13 +1480,6 @@ global@~4.3.0:
|
||||
min-document "^2.19.0"
|
||||
process "~0.5.1"
|
||||
|
||||
globals@^12.1.0:
|
||||
version "12.4.0"
|
||||
resolved "https://registry.yarnpkg.com/globals/-/globals-12.4.0.tgz#a18813576a41b00a24a97e7f815918c2e19925f8"
|
||||
integrity sha512-BWICuzzDvDoH54NHKCseDanAhE3CeDorgDL5MT6LMXXj2WCnd9UC2szdk4AWLfjdgNBCXLUanXYcpBBKOSWGwg==
|
||||
dependencies:
|
||||
type-fest "^0.8.1"
|
||||
|
||||
globalthis@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/globalthis/-/globalthis-1.0.0.tgz#c5fb98213a9b4595f59cf3e7074f141b4169daae"
|
||||
@@ -1828,24 +1599,11 @@ ieee754@^1.1.4:
|
||||
resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.1.13.tgz#ec168558e95aa181fd87d37f55c32bbcb6708b84"
|
||||
integrity sha512-4vf7I2LYV/HaWerSo3XmlMkp5eZ83i+/CDluXi/IGTs/O1sejBNhTtnxzmRZfvOUqj7lZjqHkeTvpgSFDlWZTg==
|
||||
|
||||
ignore@^4.0.6:
|
||||
version "4.0.6"
|
||||
resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc"
|
||||
integrity sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg==
|
||||
|
||||
image-q@^1.1.1:
|
||||
version "1.1.1"
|
||||
resolved "https://registry.yarnpkg.com/image-q/-/image-q-1.1.1.tgz#fc84099664460b90ca862d9300b6bfbbbfbf8056"
|
||||
integrity sha1-/IQJlmRGC5DKhi2TALa/u7+/gFY=
|
||||
|
||||
import-fresh@^3.0.0:
|
||||
version "3.2.1"
|
||||
resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.2.1.tgz#633ff618506e793af5ac91bf48b72677e15cbe66"
|
||||
integrity sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ==
|
||||
dependencies:
|
||||
parent-module "^1.0.0"
|
||||
resolve-from "^4.0.0"
|
||||
|
||||
import-lazy@^2.1.0:
|
||||
version "2.1.0"
|
||||
resolved "https://registry.yarnpkg.com/import-lazy/-/import-lazy-2.1.0.tgz#05698e3d45c88e8d7e9d92cb0584e77f096f3e43"
|
||||
@@ -1925,7 +1683,7 @@ is-function@^1.0.1:
|
||||
resolved "https://registry.yarnpkg.com/is-function/-/is-function-1.0.1.tgz#12cfb98b65b57dd3d193a3121f5f6e2f437602b5"
|
||||
integrity sha1-Es+5i2W1fdPRk6MSH19uL0N2ArU=
|
||||
|
||||
is-glob@^4.0.0, is-glob@^4.0.1, is-glob@~4.0.1:
|
||||
is-glob@^4.0.1, is-glob@~4.0.1:
|
||||
version "4.0.1"
|
||||
resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.1.tgz#7567dbe9f2f5e2467bc77ab83c4a29482407a5dc"
|
||||
integrity sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==
|
||||
@@ -2050,11 +1808,6 @@ jquery@^3.5.1:
|
||||
resolved "https://registry.yarnpkg.com/jquery/-/jquery-3.5.1.tgz#d7b4d08e1bfdb86ad2f1a3d039ea17304717abb5"
|
||||
integrity sha512-XwIBPqcMn57FxfT+Go5pzySnm4KWkT1Tv7gjrpT1srtf8Weynl6R273VJ5GjkRb51IzMp5nbaPjJXMWeju2MKg==
|
||||
|
||||
js-tokens@^4.0.0:
|
||||
version "4.0.0"
|
||||
resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499"
|
||||
integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==
|
||||
|
||||
js-yaml@^3.13.1:
|
||||
version "3.13.1"
|
||||
resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.1.tgz#aff151b30bfdfa8e49e05da22e7415e9dfa37847"
|
||||
@@ -2091,11 +1844,6 @@ json-schema@0.2.3:
|
||||
resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13"
|
||||
integrity sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=
|
||||
|
||||
json-stable-stringify-without-jsonify@^1.0.1:
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651"
|
||||
integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE=
|
||||
|
||||
json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1:
|
||||
version "5.0.1"
|
||||
resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb"
|
||||
@@ -2153,14 +1901,6 @@ lazy-val@^1.0.4:
|
||||
resolved "https://registry.yarnpkg.com/lazy-val/-/lazy-val-1.0.4.tgz#882636a7245c2cfe6e0a4e3ba6c5d68a137e5c65"
|
||||
integrity sha512-u93kb2fPbIrfzBuLjZE+w+fJbUUMhNDXxNmMfaqNgpfQf1CO5ZSe2LfsnBqVAk7i/2NF48OSoRj+Xe2VT+lE8Q==
|
||||
|
||||
levn@^0.4.1:
|
||||
version "0.4.1"
|
||||
resolved "https://registry.yarnpkg.com/levn/-/levn-0.4.1.tgz#ae4562c007473b932a6200d403268dd2fffc6ade"
|
||||
integrity sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==
|
||||
dependencies:
|
||||
prelude-ls "^1.2.1"
|
||||
type-check "~0.4.0"
|
||||
|
||||
load-bmfont@^1.3.1, load-bmfont@^1.4.0:
|
||||
version "1.4.0"
|
||||
resolved "https://registry.yarnpkg.com/load-bmfont/-/load-bmfont-1.4.0.tgz#75f17070b14a8c785fe7f5bee2e6fd4f98093b6b"
|
||||
@@ -2195,10 +1935,10 @@ lodash.assign@^4.2.0:
|
||||
resolved "https://registry.yarnpkg.com/lodash.assign/-/lodash.assign-4.2.0.tgz#0d99f3ccd7a6d261d19bdaeb9245005d285808e7"
|
||||
integrity sha1-DZnzzNem0mHRm9rrkkUAXShYCOc=
|
||||
|
||||
lodash@^4.17.10, lodash@^4.17.14, lodash@^4.17.19:
|
||||
version "4.17.19"
|
||||
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.19.tgz#e48ddedbe30b3321783c5b4301fbd353bc1e4a4b"
|
||||
integrity sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==
|
||||
lodash@^4.17.10, lodash@^4.17.15:
|
||||
version "4.17.15"
|
||||
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.15.tgz#b447f6670a0455bbfeedd11392eff330ea097548"
|
||||
integrity sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A==
|
||||
|
||||
log-symbols@^2.2.0:
|
||||
version "2.2.0"
|
||||
@@ -2240,7 +1980,7 @@ matcher@^2.0.0:
|
||||
|
||||
"materialize-css@git://github.com/cutls/materialize#v1-dev":
|
||||
version "1.0.0"
|
||||
resolved "git://github.com/cutls/materialize#6007f1cbd3cef9ffd71e203ee4a91056911e9bfe"
|
||||
resolved "git://github.com/cutls/materialize#e7fedb112cc28af96cc0119bccf3f8c13c4a98a6"
|
||||
dependencies:
|
||||
grapheme-splitter "^1.0.4"
|
||||
|
||||
@@ -2337,11 +2077,6 @@ ms@2.1.2, ms@^2.1.1:
|
||||
resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009"
|
||||
integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==
|
||||
|
||||
natural-compare@^1.4.0:
|
||||
version "1.4.0"
|
||||
resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7"
|
||||
integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=
|
||||
|
||||
node-abi@^2.11.0:
|
||||
version "2.12.0"
|
||||
resolved "https://registry.yarnpkg.com/node-abi/-/node-abi-2.12.0.tgz#40e9cfabdda1837863fa825e7dfa0b15686adf6f"
|
||||
@@ -2464,18 +2199,6 @@ onetime@^2.0.0:
|
||||
dependencies:
|
||||
mimic-fn "^1.0.0"
|
||||
|
||||
optionator@^0.9.1:
|
||||
version "0.9.1"
|
||||
resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.9.1.tgz#4f236a6373dae0566a6d43e1326674f50c291499"
|
||||
integrity sha512-74RlY5FCnhq4jRxVUPKDaRwrVNXMqsGsiW6AJw4XK8hmtm10wC0ypZBLw5IIp85NZMr91+qd1RvvENwg7jjRFw==
|
||||
dependencies:
|
||||
deep-is "^0.1.3"
|
||||
fast-levenshtein "^2.0.6"
|
||||
levn "^0.4.1"
|
||||
prelude-ls "^1.2.1"
|
||||
type-check "^0.4.0"
|
||||
word-wrap "^1.2.3"
|
||||
|
||||
ora@^3.4.0:
|
||||
version "3.4.0"
|
||||
resolved "https://registry.yarnpkg.com/ora/-/ora-3.4.0.tgz#bf0752491059a3ef3ed4c85097531de9fdbcd318"
|
||||
@@ -2559,13 +2282,6 @@ pako@^1.0.5:
|
||||
resolved "https://registry.yarnpkg.com/pako/-/pako-1.0.10.tgz#4328badb5086a426aa90f541977d4955da5c9732"
|
||||
integrity sha512-0DTvPVU3ed8+HNXOu5Bs+o//Mbdj9VNQMUOe9oKCwh8l0GNwpTDMKCWbRjgtD291AWnkAgkqA/LOnQS8AmS1tw==
|
||||
|
||||
parent-module@^1.0.0:
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/parent-module/-/parent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2"
|
||||
integrity sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==
|
||||
dependencies:
|
||||
callsites "^3.0.0"
|
||||
|
||||
parse-bmfont-ascii@^1.0.3:
|
||||
version "1.0.6"
|
||||
resolved "https://registry.yarnpkg.com/parse-bmfont-ascii/-/parse-bmfont-ascii-1.0.6.tgz#11ac3c3ff58f7c2020ab22769079108d4dfa0285"
|
||||
@@ -2607,11 +2323,6 @@ path-is-absolute@^1.0.0:
|
||||
resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f"
|
||||
integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18=
|
||||
|
||||
path-key@^3.1.0:
|
||||
version "3.1.1"
|
||||
resolved "https://registry.yarnpkg.com/path-key/-/path-key-3.1.1.tgz#581f6ade658cbba65a0d3380de7753295054f375"
|
||||
integrity sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==
|
||||
|
||||
path-parse@^1.0.6:
|
||||
version "1.0.6"
|
||||
resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.6.tgz#d62dbb5679405d72c4737ec58600e9ddcf06d24c"
|
||||
@@ -2659,11 +2370,6 @@ pngjs@^3.0.0, pngjs@^3.3.3:
|
||||
resolved "https://registry.yarnpkg.com/pngjs/-/pngjs-3.4.0.tgz#99ca7d725965fb655814eaf65f38f12bbdbf555f"
|
||||
integrity sha512-NCrCHhWmnQklfH4MtJMRjZ2a8c80qXeMlQMv2uVp9ISJMTt562SbGd6n2oq0PaPgKm7Z6pL9E2UlLIhC+SHL3w==
|
||||
|
||||
prelude-ls@^1.2.1:
|
||||
version "1.2.1"
|
||||
resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.2.1.tgz#debc6489d7a6e6b0e7611888cec880337d316396"
|
||||
integrity sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==
|
||||
|
||||
prepend-http@^2.0.0:
|
||||
version "2.0.0"
|
||||
resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-2.0.0.tgz#e92434bfa5ea8c19f41cdfd401d741a3c819d897"
|
||||
@@ -2679,11 +2385,6 @@ process@~0.5.1:
|
||||
resolved "https://registry.yarnpkg.com/process/-/process-0.5.2.tgz#1638d8a8e34c2f440a91db95ab9aeb677fc185cf"
|
||||
integrity sha1-FjjYqONML0QKkduVq5rrZ3/Bhc8=
|
||||
|
||||
progress@^2.0.0:
|
||||
version "2.0.3"
|
||||
resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.3.tgz#7e8cf8d8f5b8f239c1bc68beb4eb78567d572ef8"
|
||||
integrity sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==
|
||||
|
||||
proto-list@~1.2.1:
|
||||
version "1.2.4"
|
||||
resolved "https://registry.yarnpkg.com/proto-list/-/proto-list-1.2.4.tgz#212d5bfe1318306a420f6402b8e26ff39647a849"
|
||||
@@ -2785,11 +2486,6 @@ regenerator-runtime@^0.13.2, regenerator-runtime@^0.13.3:
|
||||
resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.3.tgz#7cf6a77d8f5c6f60eb73c5fc1955b2ceb01e6bf5"
|
||||
integrity sha512-naKIZz2GQ8JWh///G7L3X6LaQUAMp2lvb1rvwwsURe/VXwD6VMfr+/1NuNw3ag8v2kY1aQ/go5SNn79O9JU7yw==
|
||||
|
||||
regexpp@^3.1.0:
|
||||
version "3.1.0"
|
||||
resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-3.1.0.tgz#206d0ad0a5648cffbdb8ae46438f3dc51c9f78e2"
|
||||
integrity sha512-ZOIzd8yVsQQA7j8GCSlPGXwg5PfmA1mrq0JP4nGhh54LaKN3xdai/vHUDu74pKwV8OxseMS65u2NImosQcSD0Q==
|
||||
|
||||
registry-auth-token@^4.0.0:
|
||||
version "4.0.0"
|
||||
resolved "https://registry.yarnpkg.com/registry-auth-token/-/registry-auth-token-4.0.0.tgz#30e55961eec77379da551ea5c4cf43cbf03522be"
|
||||
@@ -2841,11 +2537,6 @@ require-main-filename@^2.0.0:
|
||||
resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-2.0.0.tgz#d0b329ecc7cc0f61649f62215be69af54aa8989b"
|
||||
integrity sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==
|
||||
|
||||
resolve-from@^4.0.0:
|
||||
version "4.0.0"
|
||||
resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6"
|
||||
integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==
|
||||
|
||||
resolve@^1.10.0:
|
||||
version "1.12.0"
|
||||
resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.12.0.tgz#3fc644a35c84a48554609ff26ec52b66fa577df6"
|
||||
@@ -2868,13 +2559,6 @@ restore-cursor@^2.0.0:
|
||||
onetime "^2.0.0"
|
||||
signal-exit "^3.0.2"
|
||||
|
||||
rimraf@2.6.3:
|
||||
version "2.6.3"
|
||||
resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz#b2d104fe0d8fb27cf9e0a1cda8262dd3833c6cab"
|
||||
integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==
|
||||
dependencies:
|
||||
glob "^7.1.3"
|
||||
|
||||
rimraf@^2.6.3:
|
||||
version "2.7.1"
|
||||
resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.7.1.tgz#35797f13a7fdadc566142c29d4f07ccad483e3ec"
|
||||
@@ -2950,7 +2634,7 @@ semver@^6.0.0, semver@^6.2.0, semver@^6.3.0:
|
||||
resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d"
|
||||
integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==
|
||||
|
||||
semver@^7.2.1, semver@^7.3.2:
|
||||
semver@^7.3.2:
|
||||
version "7.3.2"
|
||||
resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.2.tgz#604962b052b81ed0786aae84389ffba70ffd3938"
|
||||
integrity sha512-OrOb32TeeambH6UrhtShmF7CRDqhL6/5XpPNp2DuRH6+9QLw/orhp72j87v8Qa1ScDkvrrBNpZcDejAirJmfXQ==
|
||||
@@ -2967,32 +2651,11 @@ set-blocking@^2.0.0, set-blocking@~2.0.0:
|
||||
resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7"
|
||||
integrity sha1-BF+XgtARrppoA93TgrJDkrPYkPc=
|
||||
|
||||
shebang-command@^2.0.0:
|
||||
version "2.0.0"
|
||||
resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-2.0.0.tgz#ccd0af4f8835fbdc265b82461aaf0c36663f34ea"
|
||||
integrity sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==
|
||||
dependencies:
|
||||
shebang-regex "^3.0.0"
|
||||
|
||||
shebang-regex@^3.0.0:
|
||||
version "3.0.0"
|
||||
resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172"
|
||||
integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==
|
||||
|
||||
signal-exit@^3.0.0, signal-exit@^3.0.2:
|
||||
version "3.0.2"
|
||||
resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d"
|
||||
integrity sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=
|
||||
|
||||
slice-ansi@^2.1.0:
|
||||
version "2.1.0"
|
||||
resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-2.1.0.tgz#cacd7693461a637a5788d92a7dd4fba068e81636"
|
||||
integrity sha512-Qu+VC3EwYLldKa1fCxuuvULvSJOKEgk9pi8dZeCVK7TqBfUNTH4sFkk4joj8afVSfAYgJoSOetjx9QWOJ5mYoQ==
|
||||
dependencies:
|
||||
ansi-styles "^3.2.0"
|
||||
astral-regex "^1.0.0"
|
||||
is-fullwidth-code-point "^2.0.0"
|
||||
|
||||
sort-keys-length@^1.0.0:
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/sort-keys-length/-/sort-keys-length-1.0.1.tgz#9cb6f4f4e9e48155a6aa0671edd336ff1479a188"
|
||||
@@ -3180,11 +2843,6 @@ strip-ansi@^6.0.0:
|
||||
dependencies:
|
||||
ansi-regex "^5.0.0"
|
||||
|
||||
strip-json-comments@^3.1.0:
|
||||
version "3.1.1"
|
||||
resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006"
|
||||
integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==
|
||||
|
||||
strip-json-comments@~2.0.1:
|
||||
version "2.0.1"
|
||||
resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a"
|
||||
@@ -3211,10 +2869,10 @@ supports-color@^7.1.0:
|
||||
dependencies:
|
||||
has-flag "^4.0.0"
|
||||
|
||||
sweetalert2@^9.17.0:
|
||||
version "9.17.0"
|
||||
resolved "https://registry.yarnpkg.com/sweetalert2/-/sweetalert2-9.17.0.tgz#9ea457f3c44295a3629ed5998fee6a51940c3891"
|
||||
integrity sha512-tOby96N1FlTT8Xi7Y7QlTiswNJTySgghmRSyFwb3pO3zdrhsR2PUp4ucmye7a3CTLbLdqjHdszsGlCJ0v6pGaQ==
|
||||
sweetalert2@^9.15.2:
|
||||
version "9.15.2"
|
||||
resolved "https://registry.yarnpkg.com/sweetalert2/-/sweetalert2-9.15.2.tgz#d26f1e6dee91d9ff57b3b98b3d92a0d6c3fa6fc1"
|
||||
integrity sha512-evJfoa49s5ZzSmVc62tslNkzlQoCg2GHjB3MQxawfESppvY5AlXKLGQ3nNKxHXKdodKmIHbkl39DgUhcOK7LgQ==
|
||||
|
||||
system-font-families@^0.4.1:
|
||||
version "0.4.1"
|
||||
@@ -3224,16 +2882,6 @@ system-font-families@^0.4.1:
|
||||
babel-polyfill "^6.23.0"
|
||||
ttfinfo "https://github.com/rBurgett/ttfinfo.git"
|
||||
|
||||
table@^5.2.3:
|
||||
version "5.4.6"
|
||||
resolved "https://registry.yarnpkg.com/table/-/table-5.4.6.tgz#1292d19500ce3f86053b05f0e8e7e4a3bb21079e"
|
||||
integrity sha512-wmEc8m4fjnob4gt5riFRtTu/6+4rSe12TpAELNSqHMfF3IqnA+CH37USM6/YR3qRZv7e56kAEAtd6nKZaxe0Ug==
|
||||
dependencies:
|
||||
ajv "^6.10.2"
|
||||
lodash "^4.17.14"
|
||||
slice-ansi "^2.1.0"
|
||||
string-width "^3.0.0"
|
||||
|
||||
tar@^4.4.12:
|
||||
version "4.4.13"
|
||||
resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.13.tgz#43b364bc52888d555298637b10d60790254ab525"
|
||||
@@ -3260,11 +2908,6 @@ term-size@^2.1.0:
|
||||
resolved "https://registry.yarnpkg.com/term-size/-/term-size-2.2.0.tgz#1f16adedfe9bdc18800e1776821734086fcc6753"
|
||||
integrity sha512-a6sumDlzyHVJWb8+YofY4TW112G6p2FCPEAFk+59gIYHv3XHRhm9ltVQ9kli4hNWeQBwSpe8cRN25x0ROunMOw==
|
||||
|
||||
text-table@^0.2.0:
|
||||
version "0.2.0"
|
||||
resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4"
|
||||
integrity sha1-f17oI66AUgfACvLfSoTsP8+lcLQ=
|
||||
|
||||
timm@^1.6.1:
|
||||
version "1.6.2"
|
||||
resolved "https://registry.yarnpkg.com/timm/-/timm-1.6.2.tgz#dfd8c6719f7ba1fcfc6295a32670a1c6d166c0bd"
|
||||
@@ -3328,13 +2971,6 @@ tweetnacl@^0.14.3, tweetnacl@~0.14.0:
|
||||
resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64"
|
||||
integrity sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=
|
||||
|
||||
type-check@^0.4.0, type-check@~0.4.0:
|
||||
version "0.4.0"
|
||||
resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.4.0.tgz#07b8203bfa7056c0657050e3ccd2c37730bab8f1"
|
||||
integrity sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==
|
||||
dependencies:
|
||||
prelude-ls "^1.2.1"
|
||||
|
||||
type-fest@^0.8.0, type-fest@^0.8.1:
|
||||
version "0.8.1"
|
||||
resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.8.1.tgz#09e249ebde851d3b1e48d27c105444667f17b83d"
|
||||
@@ -3440,11 +3076,6 @@ uuid@^3.3.2:
|
||||
resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.3.tgz#4568f0216e78760ee1dbf3a4d2cf53e224112866"
|
||||
integrity sha512-pW0No1RGHgzlpHJO1nsVrHKpOEIxkGg1xB+v0ZmdNH5OAeAwzAVrCnI2/6Mtx+Uys6iaylxa+D3g4j63IKKjSQ==
|
||||
|
||||
v8-compile-cache@^2.0.3:
|
||||
version "2.1.1"
|
||||
resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.1.1.tgz#54bc3cdd43317bca91e35dcaf305b1a7237de745"
|
||||
integrity sha512-8OQ9CL+VWyt3JStj7HX7/ciTL2V3Rl1Wf5OL+SNTm0yK1KvtReVulksyeRnCANHHuUxHlQig+JJDlUhBt1NQDQ==
|
||||
|
||||
validate-npm-package-license@^3.0.1:
|
||||
version "3.0.4"
|
||||
resolved "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz#fc91f6b9c7ba15c857f4cb2c5defeec39d4f410a"
|
||||
@@ -3486,13 +3117,6 @@ which@^1.3.1:
|
||||
dependencies:
|
||||
isexe "^2.0.0"
|
||||
|
||||
which@^2.0.1:
|
||||
version "2.0.2"
|
||||
resolved "https://registry.yarnpkg.com/which/-/which-2.0.2.tgz#7c6a8dd0a636a0327e10b59c9286eee93f3f51b1"
|
||||
integrity sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==
|
||||
dependencies:
|
||||
isexe "^2.0.0"
|
||||
|
||||
wide-align@^1.1.0:
|
||||
version "1.1.3"
|
||||
resolved "https://registry.yarnpkg.com/wide-align/-/wide-align-1.1.3.tgz#ae074e6bdc0c14a431e804e624549c633b000457"
|
||||
@@ -3507,11 +3131,6 @@ widest-line@^3.1.0:
|
||||
dependencies:
|
||||
string-width "^4.0.0"
|
||||
|
||||
word-wrap@^1.2.3:
|
||||
version "1.2.3"
|
||||
resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c"
|
||||
integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==
|
||||
|
||||
wrap-ansi@^5.1.0:
|
||||
version "5.1.0"
|
||||
resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-5.1.0.tgz#1fd1f67235d5b6d0fee781056001bfb694c03b09"
|
||||
@@ -3545,13 +3164,6 @@ write-file-atomic@^3.0.0:
|
||||
signal-exit "^3.0.2"
|
||||
typedarray-to-buffer "^3.1.5"
|
||||
|
||||
write@1.0.3:
|
||||
version "1.0.3"
|
||||
resolved "https://registry.yarnpkg.com/write/-/write-1.0.3.tgz#0800e14523b923a387e415123c865616aae0f5c3"
|
||||
integrity sha512-/lg70HAjtkUgWPVZhZcm+T4hkL8Zbtp1nFNOn3lRrxnlv50SRBv7cR7RqR+GMsd3hUXy9hWBo4CHTbFTcOYwig==
|
||||
dependencies:
|
||||
mkdirp "^0.5.1"
|
||||
|
||||
xdg-basedir@^4.0.0:
|
||||
version "4.0.0"
|
||||
resolved "https://registry.yarnpkg.com/xdg-basedir/-/xdg-basedir-4.0.0.tgz#4bc8d9984403696225ef83a1573cbbcb4e79db13"
|
||||
|
||||
Reference in New Issue
Block a user