Compare commits

..

24 Commits

Author SHA1 Message Date
cutls
783ceec8de typo 2020-05-10 22:02:51 +09:00
cutls
b1ccfa85ba TheDesk 21.0.0(Mayu) 2020-05-10 21:59:25 +09:00
cutls
7e6d03fd53 fix: utl loading 2020-05-10 21:52:01 +09:00
cutls
dd0e1279c4 icon, en-splash, add remote-only pub 2020-05-10 19:39:49 +09:00
cutls
1b3e676b30 Add splash screen 2020-05-10 17:32:49 +09:00
cutls
a4582bb18a splash animation 2020-05-10 13:26:07 +09:00
cutls
25e99725d2 Add: show utl as a column 2020-05-07 00:31:11 +09:00
cutls
da011cd302 pwa compat 2020-05-06 18:09:00 +09:00
cutls
53010751ee pwa compat 2020-05-06 18:06:05 +09:00
cutls
19401b61cb del asterte-compat 2020-05-06 18:03:33 +09:00
cutls
82271f1c17 platform compat 2020-05-06 18:02:14 +09:00
cutls
a74d0ecf8d Bug wo mitsuketa 2020-05-05 23:37:58 +09:00
cutls
7ee4205f8a Add: Last.fm 2020-05-05 23:36:31 +09:00
cutls
9aef043344 cors 2020-05-03 22:46:55 +09:00
cutls
4dbc673719 fix 2020-05-03 22:32:41 +09:00
cutls
d44cecf21f show 2020-05-03 22:27:11 +09:00
cutls
3c0ea8f40d test 2020-05-03 22:23:59 +09:00
cutls
06b806532e test fin 2020-05-03 22:20:28 +09:00
cutls
1983864294 mv 2020-05-03 22:16:36 +09:00
cutls
c523a274e1 headers 2020-05-03 22:14:39 +09:00
cutls
03563eb1f2 mv 2020-05-03 22:11:23 +09:00
cutls
2f14d18126 toml 2020-05-03 22:06:41 +09:00
cutls
d1309a82ec np 2020-05-03 22:05:55 +09:00
cutls
2a2607eb4b follow request 2020-05-03 22:05:45 +09:00
55 changed files with 1043 additions and 646 deletions

View File

@@ -28,7 +28,6 @@ The icon is provided under [Creative Commons BY-NC-SA](https://creativecommons.o
* [SVG 4095x4096](https://d2upiril6ywqp9.cloudfront.net/press/thedesk-fullcolor.svg)
* [ico 256x256](https://d2upiril6ywqp9.cloudfront.net/press/thedesk.ico)
* [icns old](https://d2upiril6ywqp9.cloudfront.net/press/thedesk.icns)
* [Illustrator .ai](https://d2upiril6ywqp9.cloudfront.net/press/thedesk.ai)
The default sounds of notifications is provided [Creative Commons BY](https://creativecommons.org/licenses/by/4.0/)

View File

@@ -1,135 +1,139 @@
<!doctype html>
<!DOCTYPE html>
<html lang="ja">
<head>
<title>TheDesk</title>
<meta content="width=device-width,initial-scale=1.0" name="viewport" />
<link href="./node_modules/materialize-css/dist/css/materialize.css" type="text/css" rel="stylesheet" />
<link href="./css/font-awesome.css" rel="stylesheet" type="text/css" />
<link href="./css/themes.css" type="text/css" rel="stylesheet" />
<link href="./css/master.css" type="text/css" rel="stylesheet" />
<link href="https://fonts.googleapis.com/icon?family=Material+Icons|Open+Sans:300|Baloo+Bhai" rel="stylesheet" />
<meta charset="utf-8" />
<style>
body {
font-family: 'Open Sans';
-webkit-app-region: drag;
cursor: move;
padding: 5px;
padding-top: 15px;
}
<head>
<title>TheDesk</title>
<meta content="width=device-width,initial-scale=1.0" name="viewport">
<link href="./node_modules/materialize-css/dist/css/materialize.css" type="text/css" rel="stylesheet">
<link href='./css/font-awesome.css' rel='stylesheet' type='text/css'>
<link href="./css/themes.css" type="text/css" rel="stylesheet">
<link href="./css/master.css" type="text/css" rel="stylesheet">
<link href="https://fonts.googleapis.com/icon?family=Material+Icons|Open+Sans:300|Baloo+Bhai" rel="stylesheet">
<meta charset="utf-8">
<style>
body {
font-family: 'Open Sans';
-webkit-app-region: drag;
cursor: move;
padding: 5px;
padding-top: 15px;
}
a,
button {
-webkit-app-region: no-drag;
}
a,
button {
-webkit-app-region: no-drag;
}
.container {
width: 100%;
display: grid;
grid-template-columns: 1fr 1fr;
grid-template-rows: 1fr 1fr 1fr 1fr 1fr;
grid-template-areas: 'name1 data1' 'name2 data2' 'name3 data3' 'name4 data4' 'name5 data5' 'name6 data6';
text-align: left;
margin: 5px;
}
.container {
width: 100%;
display: grid;
grid-template-columns: 1fr 1fr;
grid-template-rows: 1fr 1fr 1fr 1fr 1fr;
grid-template-areas: 'name1 data1''name2 data2''name3 data3''name4 data4''name5 data5''name6 data6';
text-align: left;
margin: 5px;
}
.area-name1 {
grid-area: name1;
}
.area-name1 {
grid-area: name1;
}
.area-data1 {
grid-area: data1;
}
.area-data1 {
grid-area: data1;
}
.area-name2 {
grid-area: name2;
}
.area-name2 {
grid-area: name2;
}
.area-data2 {
grid-area: data2;
}
.area-data2 {
grid-area: data2;
}
.area-name3 {
grid-area: name3;
}
.area-name3 {
grid-area: name3;
}
.area-data3 {
grid-area: data3;
}
.area-data3 {
grid-area: data3;
}
.area-name4 {
grid-area: name4;
}
.area-name4 {
grid-area: name4;
}
.area-data4 {
grid-area: data4;
}
.area-data4 {
grid-area: data4;
}
.area-name5 {
grid-area: name5;
}
.area-name5 {
grid-area: name5;
}
.area-data5 {
grid-area: data5;
}
.area-data5 {
grid-area: data5;
}
.area-name6 {
grid-area: name6;
}
.area-name6 {
grid-area: name6;
}
.area-data6 {
grid-area: data6;
}
</style>
</head>
.area-data6 {
grid-area: data6;
}
</style>
</head>
<body class="center " style="overflow:hidden">
<script type="text/javascript" src="./node_modules/jquery/dist/jquery.js"></script>
<script type="text/javascript" src="./js/platform/first-not-view.js"></script>
<script type="text/javascript" src="./node_modules/materialize-css/dist/js/materialize.js"></script>
<img src="./img/desk.svg" style="max-width:62%;">
<h5>TheDesk</h5>
<div class="container">
<div class="area-name1">Display version</div>
<div class="area-data1" id="now"></div>
<div class="area-name2">Internal version</div>
<div class="area-data2" id="ver"></div>
<div class="area-name3">Commit(7chars)</div>
<div class="area-data3" id="hash"></div>
<div class="area-name4">Chromium</div>
<div class="area-data4" id="chrome"></div>
<div class="area-name5">Electron</div>
<div class="area-data5" id="electron"></div>
<div class="area-name6">Node.js</div>
<div class="area-data6" id="node"></div>
</div>
<div class="cp">Copyright &copy; TheDesk 2018<br>
Main developer(author): <a href="https://cutls.com/@Cutls" target="_blank">Cutls P</a><br>
Thanks:<a href="https://minohdon.jp/@toneji" target="_blank">toneji</a>/<a
href="https://popon.pptdn.jp/@popn_ja" target="_blank">popn_ja</a>/<a href="https://pl.kpherox.dev/kPherox"
target="_blank">kPherox</a> and all users
<img draggable="false" style="width:0.8rem;top: 1px;margin-left: 1px;position: relative;" alt="❤️"
title=":heart:" src="https://twemoji.maxcdn.com/2/72x72/2764.png">
<br><a href="https://thedesk.top" target="_blank">Web site</a></div>
<button onclick="window.close()" class="btn waves-effect indigo" style="width:calc(100% - 10px);"><i
class="material-icons left">close</i>Close</button>
<script type="text/javascript" src="./js/ui/theme.js"></script>
<script>
var about = JSON.parse(localStorage.getItem("about"));
$("#now").text(localStorage.getItem("ver"));
$("#node").text(about[0]);
$("#chrome").text(about[1]);
$("#electron").text(about[2]);
if (location.search) {
var m = location.search.match(/\?ver=([a-zA-Z-0-9.]+)/);
var ver = m[1];
$("#ver").text(ver);
}
$("#hash").html('<a href="https://github.com/cutls/TheDesk/commits/' + about[3] + '" target="_blank">' + about[3].slice(0, 7) + '</a>');
$(document).on('click', 'a', e => {
var url = $(e.target).attr('href');
postMessage(["openUrl", url], "*")
return false;
});
</script>
<body class="center" style="overflow: hidden;">
<script type="text/javascript" src="./node_modules/jquery/dist/jquery.js"></script>
<script type="text/javascript" src="./js/platform/first-not-view.js"></script>
<script type="text/javascript" src="./node_modules/materialize-css/dist/js/materialize.js"></script>
<img src="./img/desk.svg" style="max-width: 62%;" />
<h5>TheDesk</h5>
<div class="container">
<div class="area-name1">Display version</div>
<div class="area-data1" id="now"></div>
<div class="area-name2">Internal version</div>
<div class="area-data2" id="ver"></div>
<div class="area-name3">Commit(7chars)</div>
<div class="area-data3" id="hash"></div>
<div class="area-name4">Chromium</div>
<div class="area-data4" id="chrome"></div>
<div class="area-name5">Electron</div>
<div class="area-data5" id="electron"></div>
<div class="area-name6">Node.js</div>
<div class="area-data6" id="node"></div>
</div>
<div class="cp">
Copyright &copy; TheDesk 2018<br />
Main developer(author): <a href="https://cutls.com/@Cutls" target="_blank">Cutls P</a><br />
Thanks:<a href="https://minohdon.jp/@toneji" target="_blank">toneji</a>/<a href="https://popon.pptdn.jp/@popn_ja" target="_blank">popn_ja</a>/<a
href="https://pl.kpherox.dev/kPherox"
target="_blank"
>kPherox</a
>
and all users
<img draggable="false" style="width: 0.8rem; top: 1px; margin-left: 1px; position: relative;" alt="❤️" title=":heart:" src="https://twemoji.maxcdn.com/2/72x72/2764.png" />
<br /><a href="https://thedesk.top" target="_blank">Web site</a>
</div>
<button onclick="window.close()" class="btn waves-effect indigo" style="width: calc(100% - 10px);"><i class="material-icons left">close</i>Close</button>
<script type="text/javascript" src="./js/ui/theme.js"></script>
<script>
var about = JSON.parse(localStorage.getItem('about'))
$('#now').text(localStorage.getItem('ver'))
$('#node').text(about[0])
$('#chrome').text(about[1])
$('#electron').text(about[2])
if (location.search) {
var m = location.search.match(/\?ver=([a-zA-Z-0-9.]+)/)
var ver = m[1]
$('#ver').text(ver)
}
$('#hash').html('<a href="https://github.com/cutls/TheDesk/commits/' + about[3] + '" target="_blank">' + about[3].slice(0, 7) + '</a>')
$(document).on('click', 'a', (e) => {
var url = $(e.target).attr('href')
postMessage(['openUrl', url], '*')
return false
})
</script>
</body>
</html>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.4 KiB

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 29 KiB

After

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.4 KiB

After

Width:  |  Height:  |  Size: 9.7 KiB

View File

@@ -9,7 +9,9 @@ body {
height: 100vh;
color: var(--color);
}
.titlebar, .menubar-menu-container, .action-menu-item {
.titlebar,
.menubar-menu-container,
.action-menu-item {
background-color: var(--notfbox) !important;
filter: brightness(110%) !important;
color: var(--color) !important;
@@ -25,10 +27,10 @@ body {
display: none;
}
.accessMark {
font-size: 12px;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
font-size: 12px;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
background-color: var(--emphasized);
padding-left: 5px;
padding-right: 5px;
@@ -519,18 +521,18 @@ textarea {
width: 300px;
max-width: 100%;
background-color: var(--box);
z-index: 501;
padding: 5px;
z-index: 501;
padding: 5px;
}
#pageSrcInput {
width: 160px;
width: 160px;
}
.voice {
clip: rect(1px, 1px, 1px, 1px);
position: absolute !important;
height: 1px;
width: 1px;
overflow: hidden;
position: absolute !important;
height: 1px;
width: 1px;
overflow: hidden;
}
@media (max-width: 500px) {
@@ -561,17 +563,14 @@ textarea {
font-family: 'Open Sans';
font-style: normal;
font-weight: 300;
src: local('Open Sans Light'), local('OpenSans-Light'),
url(https://fonts.gstatic.com/s/opensans/v17/mem5YaGs126MiZpBA-UN_r8OUuhp.woff2) format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F,
U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
src: local('Open Sans Light'), local('OpenSans-Light'), url('../fonts/OpenSans-Light.ttf') format('truetype');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
font-family: 'Material Icons';
font-style: normal;
font-weight: 400;
src: url(https://fonts.gstatic.com/s/materialicons/v48/flUhRq6tzZclQEJ-Vdg-IuiaDsNc.woff2)
format('woff2');
src: url(https://fonts.gstatic.com/s/materialicons/v48/flUhRq6tzZclQEJ-Vdg-IuiaDsNc.woff2) format('woff2');
}
.material-icons {
font-family: 'Material Icons';
@@ -588,3 +587,16 @@ textarea {
-webkit-font-feature-settings: 'liga';
-webkit-font-smoothing: antialiased;
}
.pwaView .pwa,
.pwaView .mac,
.pwaView .win {
display: none;
}
.win32 .mac,
.linux .mac {
display: none;
}
.linux .win,
.darwin .win {
display: none;
}

View File

@@ -124,6 +124,7 @@ textarea {
}
#posttgl,#toot-post-btn {
background-color: var(--accentbtn);
color: var(--color);
}
/*mini*/
.mini-post .mize {

View File

@@ -1,7 +1,7 @@
/*アイコンをクリックした時とかにでてくるユーザーデータ*/
#his-data {
background-repeat: no-repeat;
background-image: url("../../loading.svg");
background-image: url("../img/loading.svg");
overflow-y: hidden;
}
#his-data .btn .material-icons{

Binary file not shown.

View File

@@ -0,0 +1,37 @@
<?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 4096 4096" 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="TheDesk">
<g id="back">
<g transform="matrix(1,0,0,1.53232,-11.8871,-1144.65)">
<rect x="1044.02" y="1686.36" width="2335.77" height="782.558" style="fill:rgba(255,255,255,0);">
<animate attributeName="fill" begin="0.5s" dur="0.1s" fill="freeze" values="rgba(255,255,255,0);rgba(255,255,255,1)" />
</rect>
</g>
<rect x="1058.89" y="609.971" width="711.146" height="2885.69" style="fill:rgba(255,255,255,0);">
<animate attributeName="fill" begin="0.5s" dur="0.1s" fill="freeze" values="rgba(255,255,255,0);rgba(255,255,255,1)" />
</rect>
<g transform="matrix(1.08582,0,0,1,-142.973,0)">
<rect x="1665.9" y="1021.89" width="776.607" height="2050.26" style="fill:rgba(255,255,255,0);">
<animate attributeName="fill" begin="0.5s" dur="0.1s" fill="freeze" values="rgba(255,255,255,0);rgba(255,255,255,1)" />
</rect>
</g>
</g>
<g transform="matrix(1,0,0,0.998821,0,4.65666)" id="gray">
<rect x="678.5" y="128.48" width="450" height="3821.5" style="fill:rgb(84,82,81);"/>
</g>
<g transform="matrix(0.999978,-5.55112e-17,-2.20005e-08,0.996112,-1237.17,972.039)" id="orange">
<rect x="1915.71" y="-583.55" width="450" height="3117.62" style="fill:rgb(240,132,46);" r="3117.62">
<animateTransform attributeName="transform" attributeType="XML" type="rotate" from="0,1915.71,-583.55" to="-60,1915.71,-583.55" dur="0.5s" repeatCount="1" fill="freeze" />
</rect>
</g>
<g transform="matrix(0.999978,5.55112e-17,-5.55112e-17,0.999978,-1236.96,-1164.58)" id="blue">
<rect x="1915.5" y="1775.41" width="450" height="3105.58" style="fill:rgb(54,76,159);" r="3117.62">
<animateTransform attributeName="transform" attributeType="XML" type="rotate" from="0,1915.71,4881" to="60,1915.71,4881" dur="0.5s" repeatCount="1" fill="freeze" />
</rect>
</g>
<path id="cat" 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:rgba(0,0,0,0);">
<animate attributeName="fill" begin="0.6s" dur="0.5s" fill="freeze" values="rgba(0,0,0,0);rgba(0,0,0,1)" repeatCount="1" />
</path>
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 22 KiB

View File

@@ -1,39 +1,26 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
TheDesk icon, Cutls P.
This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/4.0/ or send a letter to Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
-->
<!-- Generator: Adobe Illustrator 23.0.3, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 4096 4096" style="enable-background:new 0 0 4096 4096;" xml:space="preserve">
<style type="text/css">
.st0{display:none;}
.st1{fill:#FFFFFF;}
.st2{fill:#545251;stroke:#040000;stroke-miterlimit:10;}
.st3{fill:#F0842E;}
.st4{fill:#364C9F;}
.st5{fill:#FFFFFF;stroke:#040000;stroke-miterlimit:10;}
.st6{fill-rule:evenodd;clip-rule:evenodd;fill:#040000;}
.st7{fill-rule:evenodd;clip-rule:evenodd;fill:none;}
</style>
<g id="レイヤー_1" class="st0">
</g>
<g id="レイヤー_2">
<polyline class="st1" points="1128.5,650.67 3378,1950 3378,2137 1128.5,3432.67 "/>
<rect x="678.5" y="128.48" class="st2" width="450" height="3821.5"/>
<rect x="1915.71" y="-583.55" transform="matrix(0.5 -0.866 0.866 0.5 225.753 2341.5386)" class="st3" width="450" height="3117.62"/>
<rect x="1915.5" y="1555.41" transform="matrix(0.5 0.866 -0.866 0.5 3762.031 -299.6245)" class="st4" width="450" height="3105.58"/>
<path class="st5" d="M714.5,2953.5"/>
<path id="path1891" class="st6" d="M1592.47,2584h456.47c0-64.89-4.63-77.76-112.1-77.76c17.17-51.5,86.95-176.11,125.73-176.11
c34.31,0,75.24,1.89,75.24,80.17c0,88.87,149.56,232.16,185.82,173.7c54.04-87.12-92.91-60.55-92.91-270.65
c0-287.43,167.74-246.51,167.74-407.99c0-80.79-22.32-91.7-22.32-149.46c0-76.34,67.25-71.91,54.17-135.2
c-9.04-43.72-16.11-78.78-21.38-131.65c-3.74-37.51-4.93-77.5-43.9-75.89c-45.78,1.89-63.15,82.47-134.31,88.25
c-71.02,5.77-131.57-60.46-159.06-51c-27.25,9.38-18.68,83.32-2.52,135.83c25.4,82.54,80.79,189.86-20.2,206.02
c-100.99,16.16-274.69,32.32-399.92,197.94s-120.6,359.99-169.66,420.11C1314.72,2612.08,1146,2529.23,1146,2697.11
c0,75.16,127.35,129.27,147.55,105.03c20.2-24.24-171.62-96.46,43.01-181.78C1519.91,2547.46,1536.28,2532.58,1592.47,2584z"/>
<rect class="st7" width="4096" height="4096"/>
<path class="st1" d="M-58,1122"/>
</g>
<?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 4096 4096" 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="TheDesk">
<g>
<g transform="matrix(1,0,0,1.53232,-11.8871,-1144.65)">
<rect x="1044.02" y="1686.36" width="2335.77" height="782.558" style="fill:white;"/>
</g>
<rect x="1058.89" y="609.971" width="711.146" height="2885.69" style="fill:white;"/>
<g transform="matrix(1.08582,0,0,1,-142.973,0)">
<rect x="1665.9" y="1021.89" width="776.607" height="2050.26" style="fill:white;"/>
</g>
</g>
<g transform="matrix(1,0,0,0.998821,0,4.65666)">
<rect x="678.5" y="128.48" width="450" height="3821.5" style="fill:rgb(84,82,81);"/>
</g>
<g transform="matrix(0.5,-0.866,0.862652,0.498067,224.046,2340.41)">
<rect x="1915.71" y="-583.55" width="450" height="3117.62" style="fill:rgb(240,132,46);"/>
</g>
<g transform="matrix(0.5,0.866,-0.866,0.5,3757.17,-299.625)">
<rect x="1915.5" y="1555.41" width="450" height="3105.58" style="fill:rgb(54,76,159);"/>
</g>
<path id="cat" 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(4,0,0);"/>
<rect x="0" y="0" width="4096" height="4096" style="fill:none;"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.4 KiB

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.0 KiB

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.1 KiB

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.5 KiB

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.0 KiB

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.4 KiB

After

Width:  |  Height:  |  Size: 15 KiB

View File

@@ -1,8 +1,9 @@
//バージョンチェッカー
function verck(ver, jp) {
console.log('%c Welcome😊 ' + ver, 'color: red;font-size:200%;')
$('body').addClass(localStorage.getItem('platform'))
var date = new Date()
var show = false
var showVer = false
if (localStorage.getItem('ver') != ver && localStorage.getItem('winstore')) {
//ちょっと削除とリンク解析の都合上アレ(s)
//対象外のアプデ:storageが20の最初まで"Usamin (18.6.5)"
@@ -15,10 +16,10 @@ function verck(ver, jp) {
}
}
//ちょっと削除とリンク解析の都合上アレ(e)
show = true
showVer = true
console.log('%c Thank you for your update🎉', 'color: red;font-size:200%;')
$(document).ready(function() {
if (localStorage.getItem('winstore')) {
if (localStorage.getItem('winstore') && !pwa) {
$('#releasenote').modal('open')
}
verp = ver.replace('(', '')
@@ -37,8 +38,8 @@ function verck(ver, jp) {
})
}
localStorage.setItem('ver', ver)
if (!show) {
console.log(show)
if (!showVer) {
console.log(showVer)
if (
date.getFullYear() * 100 + date.getMonth() + 1 >= localStorage.getItem('showSupportMe') ||
!localStorage.getItem('showSupportMe')
@@ -68,7 +69,7 @@ function verck(ver, jp) {
}
var platform = localStorage.getItem('platform')
console.log('Your platform:' + platform)
if (!localStorage.getItem('winstore')) {
if (!localStorage.getItem('winstore') && !pwa) {
$('#start').css('display', 'flex')
}
if (
@@ -142,9 +143,10 @@ function verck(ver, jp) {
if (!localStorage.getItem('last-notice-id')) {
localStorage.setItem('last-notice-id', 0)
}
var start = 'https://thedesk.top/notice?since_id=' + localStorage.getItem('last-notice-id')
var start = 'https://thedesk.top/notice/index.php?since_id=' + localStorage.getItem('last-notice-id')
fetch(start, {
method: 'GET'
method: 'GET',
cors: true
})
.then(function(response) {
if (!response.ok) {
@@ -172,7 +174,7 @@ function verck(ver, jp) {
} else {
if (obj.type == 'textv2') {
if (~obj.languages.indexOf(lang.language)) {
var show = true
var showVer = true
if (obj.toot != '') {
var toot =
'<button class="btn-flat toast-action" onclick="detEx(\'' +
@@ -183,25 +185,25 @@ function verck(ver, jp) {
}
if (obj.ver != '') {
if (obj.ver == ver) {
show = true
showVer = true
} else {
show = false
showVer = false
}
}
if (obj.domain != '') {
var multi = localStorage.getItem('multi')
if (multi) {
show = false
showVer = false
var accts = JSON.parse(multi)
Object.keys(accts).forEach(function(key) {
var acct = accts[key]
if (acct.domain == obj.domain) {
show = true
showVer = true
}
})
}
}
if (show) {
if (showVer) {
M.toast({
html:
escapeHTML(obj.text) +
@@ -231,7 +233,7 @@ function infowebsocket() {
if (obj.type == 'textv2') {
if (~obj.languages.indexOf(lang.language)) {
localStorage.setItem('last-notice-id', obj.id)
var show = true
var showVer = true
if (obj.toot != '') {
var toot =
'<button class="btn-flat toast-action" onclick="detEx(\'' +
@@ -242,25 +244,25 @@ function infowebsocket() {
}
if (obj.ver != '') {
if (obj.ver == ver) {
show = true
showVer = true
} else {
show = false
showVer = false
}
}
if (obj.domain != '') {
var multi = localStorage.getItem('multi')
if (multi) {
show = false
showVer = false
var accts = JSON.parse(multi)
Object.keys(accts).forEach(function(key) {
var acct = accts[key]
if (acct.domain == obj.domain) {
show = true
showVer = true
}
})
}
}
if (show) {
if (showVer) {
console.log(obj.text)
console.log(escapeHTML(obj.text))
M.toast({
@@ -351,7 +353,8 @@ function storeDialog(platform, ver) {
localStorage.setItem('winstore', 'localinstall')
}
localStorage.setItem('ver', ver)
show = true
showVer = true
if(pwa) return false
console.log('%c Thank you for your update🎉', 'color: red;font-size:200%;')
$(document).ready(function() {
$('#releasenote').modal('open')
@@ -372,9 +375,10 @@ function storeDialog(platform, ver) {
})
} else {
localStorage.setItem('ver', ver)
show = true
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('.', '-')

View File

@@ -590,9 +590,10 @@ function enc(ver) {
}
//インスタンスティッカー
function ticker() {
var start = 'https://toot.app/toot/'
var start = 'https://toot.app/toot/index.php'
fetch(start, {
method: 'GET',
cors: true,
headers: {
'content-type': 'application/json'
}

View File

@@ -150,10 +150,10 @@ onmessage = function(e) {
} else if (e.data[0] == 'post') {
post('pass')
} else if (e.data[0] == 'toastSaved') {
var show = `${lang.lang_img_DLDone}${
var showTxt = `${lang.lang_img_DLDone}${
e.data[1][0]
}<button class="btn-flat toast-action" onclick="openFinder('${e.data[1][1]}')">Show</button>`
M.toast({ html: show, displayLength: 5000 })
M.toast({ html: showTxt, displayLength: 5000 })
} else if (e.data[0] == 'parseColumn') {
parseColumn(e.data[1])
} else if (e.data[0] == 'exportSettingsCore') {

View File

@@ -1,4 +1,3 @@
document.title = 'TheDesk'
$.strip_tags = function(str, allowed) {
if (!str) {
return ''

View File

@@ -4,6 +4,7 @@ var ipc = electron.ipcRenderer
//title bar
const customTitlebar = require('custom-electron-titlebar')
window.addEventListener('DOMContentLoaded', () => {
document.title = 'TheDesk'
ipc.send('acsCheck', '')
ipc.send('frameCheck', '')
ipc.on('frame', function(event, args) {

View File

@@ -14,6 +14,46 @@ function mediaToggle(tlid) {
$('#timeline_' + tlid).addClass('media-filter')
}
}
/* Remote only */
function remoteOnly(tlid, type) {
var multi = localStorage.getItem('column')
var obj = JSON.parse(multi)
if (obj[tlid].data) {
if (obj[tlid].data.remote) {
obj[tlid].data.remote = false
var json = JSON.stringify(obj)
localStorage.setItem('column', json)
$('#sta-remote-' + tlid).text('Off')
$('#sta-remote-' + tlid).css('color', '#009688')
} else {
obj[tlid].data.remote = true
var json = JSON.stringify(obj)
localStorage.setItem('column', json)
$('#sta-remote-' + tlid).text('On')
$('#sta-remote-' + tlid).css('color', 'red')
}
} else {
obj[tlid].data = {}
obj[tlid].data.remote = true
var json = JSON.stringify(obj)
localStorage.setItem('column', json)
$('#sta-remote-' + tlid).text('On')
$('#sta-remote-' + tlid).css('color', 'red')
}
columnReload(tlid, type)
}
function remoteOnlyCk(tlid) {
var multi = localStorage.getItem('column')
var obj = JSON.parse(multi)
if (obj[tlid].data) {
if (obj[tlid].data.remote) {
$('#sta-remote-' + tlid).text('On')
$('#sta-remote-' + tlid).css('color', 'red')
return true
}
}
return false
}
//各TL上方のBT[BTOnly/BTExc/Off]
function ebtToggle(tlid) {
var ebt = localStorage.getItem('ebt_' + tlid)
@@ -117,26 +157,26 @@ function filter() {
method: 'GET',
headers: {
'content-type': 'application/json',
Authorization: 'Bearer ' + at
}
Authorization: 'Bearer ' + at,
},
})
.then(function(response) {
.then(function (response) {
if (!response.ok) {
response.text().then(function(text) {
response.text().then(function (text) {
setLog(response.url, response.status, text)
})
}
return response.json()
})
.catch(function(error) {
.catch(function (error) {
todo(error)
setLog(start, 'JSON', error)
console.error(error)
})
.then(function(json) {
.then(function (json) {
if (json) {
var filters = ''
Object.keys(json).forEach(function(key) {
Object.keys(json).forEach(function (key) {
var filterword = json[key]
var context = filterword.context.join(',')
filters =
@@ -191,10 +231,7 @@ function makeNewFilter() {
if (!who) {
who = false
}
var time =
$('#days_filter').val() * 24 * 60 * 60 +
$('#hours_filter').val() * 60 * 60 +
$('#mins_filter').val() * 60
var time = $('#days_filter').val() * 24 * 60 * 60 + $('#hours_filter').val() * 60 * 60 + $('#mins_filter').val() * 60
var domain = localStorage.getItem('domain_' + acct_id)
var at = localStorage.getItem('acct_' + acct_id + '_at')
if ($('#filter-edit-id').val()) {
@@ -216,10 +253,10 @@ function makeNewFilter() {
context: cont,
irreversible: exc,
whole_word: who,
expires_in: time
expires_in: time,
})
)
httpreq.onreadystatechange = function() {
httpreq.onreadystatechange = function () {
if (httpreq.readyState === 4) {
var json = httpreq.response
if (this.status !== 200) {
@@ -263,29 +300,29 @@ function filterEdit(id, acct_id) {
method: 'GET',
headers: {
'content-type': 'application/json',
Authorization: 'Bearer ' + at
}
Authorization: 'Bearer ' + at,
},
})
.then(function(response) {
.then(function (response) {
if (!response.ok) {
response.text().then(function(text) {
response.text().then(function (text) {
setLog(response.url, response.status, text)
})
}
return response.json()
})
.catch(function(error) {
.catch(function (error) {
todo(error)
setLog(start, 'JSON', error)
console.error(error)
})
.then(function(json) {
.then(function (json) {
if (json) {
var now = new Date()
now = now.getTime()
var now = Math.floor(now / 1000)
$('#filter-add-word').val(json.phrase)
Object.keys(json.context).forEach(function(key) {
Object.keys(json.context).forEach(function (key) {
var context = json.context[key]
$('[value=' + context + ']').prop('checked', true)
})
@@ -315,7 +352,7 @@ function filterDel(id, acct_id) {
httpreq.setRequestHeader('Authorization', 'Bearer ' + at)
httpreq.responseType = 'json'
httpreq.send()
httpreq.onreadystatechange = function() {
httpreq.onreadystatechange = function () {
if (httpreq.readyState === 4) {
var json = httpreq.response
if (this.status !== 200) {
@@ -335,23 +372,23 @@ function getFilter(acct_id) {
method: 'GET',
headers: {
'content-type': 'application/json',
Authorization: 'Bearer ' + at
}
Authorization: 'Bearer ' + at,
},
})
.then(function(response) {
.then(function (response) {
if (!response.ok) {
response.text().then(function(text) {
response.text().then(function (text) {
setLog(response.url, response.status, text)
})
}
return response.json()
})
.catch(function(error) {
.catch(function (error) {
todo(error)
setLog(start, 'JSON', error)
console.error(error)
})
.then(function(json) {
.then(function (json) {
localStorage.setItem('filter_' + acct_id, JSON.stringify(json))
})
} else {
@@ -370,13 +407,13 @@ function getFilterType(json, type) {
type = 'notifi'
}
var mutedfilters = []
Object.keys(json).forEach(function(key) {
Object.keys(json).forEach(function (key) {
var filterword = json[key]
var phrases = filterword.phrase
var arr = filterword.context
if (arr.join(',').indexOf(type) !== -1) {
mutedfilters.push(phrases)
} else if (type == 'mix'){
} else if (type == 'mix') {
if (arr.indexOf('home') !== -1 || arr.indexOf('public') !== -1) {
mutedfilters.push(phrases)
}
@@ -400,23 +437,23 @@ function filterUpdate(acct_id) {
method: 'GET',
headers: {
'content-type': 'application/json',
Authorization: 'Bearer ' + at
}
Authorization: 'Bearer ' + at,
},
})
.then(function(response) {
.then(function (response) {
if (!response.ok) {
response.text().then(function(text) {
response.text().then(function (text) {
setLog(response.url, response.status, text)
})
}
return response.json()
})
.catch(function(error) {
.catch(function (error) {
todo(error)
setLog(start, 'JSON', error)
console.error(error)
})
.then(function(json) {
.then(function (json) {
localStorage.setItem('filter_' + acct_id, JSON.stringify(json))
filterUpdateInternal(json, 'home')
filterUpdateInternal(json, 'local')
@@ -432,13 +469,11 @@ function filterUpdateInternal(json, type) {
home = home.concat(wordmute)
}
if (home) {
$('[data-acct=' + acct_id + '] [data-type=' + type + '] .cvo').each(function(i, elem) {
$('[data-acct=' + acct_id + '] [data-type=' + type + '] .cvo').each(function (i, elem) {
var id = $(elem).attr('toot-id')
$('[toot-id=' + id + ']').removeClass('hide')
var text = $(elem)
.find('.toot')
.html()
Object.keys(home).forEach(function(key8) {
var text = $(elem).find('.toot').html()
Object.keys(home).forEach(function (key8) {
var word = home[key8]
var regExp = new RegExp(word.replace(/[.*+?^=!:${}()|[\]\/\\]/g, '\\$&'), 'g')
if ($.strip_tags(text).match(regExp)) {

View File

@@ -239,8 +239,10 @@ function notfWS(misskey, acct_id, tlid, domain, at) {
localStorage.setItem('lastnotf_' + acct_id, obj.id)
if (!$('#unread_' + tlid + ' .material-icons').hasClass('teal-text')) {
//markers show中はダメ
if (obj.type != 'follow') {
if (obj.type != 'follow' && obj.type != 'follow_request') {
templete = parse([obj], 'notf', acct_id, 'notf', popup)
} else if (obj.type == 'follow_request') {
templete = userparse([obj.account], 'request', acct_id, 'notf', -1)
} else {
templete = userparse([obj], obj.type, acct_id, 'notf', popup)
}

View File

@@ -90,6 +90,19 @@ function tl(type, data, acct_id, tlid, delc, voice, mode) {
)
$('#notice_icon_' + tlid).text('bookmark')
return
} else if (type == 'utl') {
//UTLなら飛ばす
getUtl(acct_id, tlid, data, false)
$('#notice_' + tlid).text(
cap(type, data, acct_id) +
'(' +
localStorage.getItem('user_' + acct_id) +
'@' +
domain +
')'
)
$('#notice_icon_' + tlid).text('person')
return
} else if (type == 'home') {
//ホームならお知らせ「も」取りに行く
announ(acct_id, tlid)
@@ -145,7 +158,7 @@ function tl(type, data, acct_id, tlid, delc, voice, mode) {
}
} else {
var misskey = false
var url = com(type, data)
var url = com(type, data, tlid)
if (type == 'tag') {
var tag = localStorage.getItem('tag-range')
if (tag == 'local') {
@@ -243,10 +256,17 @@ function reload(type, cc, acct_id, tlid, data, mute, delc, voice, mode) {
if (type == 'home') {
var start = wss + '/api/v1/streaming/?stream=user&access_token=' + at
} else if (type == 'pub') {
var start = wss + '/api/v1/streaming/?stream=public&access_token=' + at
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 start =
wss + '/api/v1/streaming/?stream=public:media&access_token=' + at
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
@@ -464,6 +484,10 @@ function moreload(type, tlid) {
} else if (type == 'bookmark') {
getBookmark(acct_id, tlid, true)
return
} else if (type == 'utl') {
var data = obj[tlid].data
getUtl(acct_id, tlid, data, true)
return
}
moreloading = true
localStorage.setItem('now', type)
@@ -515,7 +539,7 @@ function moreload(type, tlid) {
'https://' +
domain +
'/api/v1/timelines/' +
com(type, data) +
com(type, data, tlid) +
'max_id=' +
sid
if (type == 'dm') {
@@ -648,7 +672,7 @@ function tlDiff(type, data, acct_id, tlid, delc, voice, mode) {
'https://' +
domain +
'/api/v1/timelines/' +
com(type, data) +
com(type, data, tlid) +
'since_id=' +
sid
if (type == 'dm') {
@@ -826,12 +850,14 @@ function cap(type, data, acct_id) {
var response = 'tootsearch(' + escapeHTML(data) + ')'
} else if (type == 'bookmark') {
var response = 'Bookmarks'
} else if (type == 'utl') {
var response = 'User TL(' + data.acct + ')'
}
return response
}
//TLのURL
function com(type, data) {
function com(type, data, tlid) {
if (type == 'home') {
return 'home?'
} else if (type == 'local' || type == 'noauth') {
@@ -839,9 +865,17 @@ function com(type, data) {
} else if (type == 'local-media') {
return 'public?local=true&only_media=true&'
} else if (type == 'pub') {
return 'public?'
var add = ''
if(remoteOnlyCk(tlid)){
add = 'remote=true&'
}
return 'public?' + add
} else if (type == 'pub-media') {
return 'public?only_media=true&'
var add = ''
if(remoteOnlyCk(tlid)){
add = 'remote=true&'
}
return 'public?only_media=true&' + add
} else if (type == 'tag') {
if (data.name) {
var name = data.name
@@ -1310,6 +1344,47 @@ function getBookmark(acct_id, tlid, more) {
}
}
}
function getUtl(acct_id, tlid, data, more) {
moreloading = true
if (more) {
var sid = $('#timeline_' + tlid + ' .cvo')
.last()
.attr('unique-id')
var ad = '?max_id=' + sid
} else {
var ad = ''
}
var at = localStorage.getItem('acct_' + acct_id + '_at')
var domain = localStorage.getItem('domain_' + acct_id)
var start = "https://" + domain + "/api/v1/accounts/" + data.id + "/statuses" + ad
var httpreq = new XMLHttpRequest()
httpreq.open('GET', start, true)
httpreq.setRequestHeader('Content-Type', 'application/json')
httpreq.setRequestHeader('Authorization', 'Bearer ' + at)
httpreq.responseType = 'json'
httpreq.send()
httpreq.onreadystatechange = function () {
if (httpreq.readyState === 4) {
var json = httpreq.response
if (this.status !== 200) {
setLog(start, this.status, this.response)
}
var templete = parse(json, 'bookmark', acct_id, tlid, -1, null)
templete =
templete
if (more) {
$('#timeline_' + tlid).append(templete)
} else {
$('#timeline_' + tlid).html(templete)
}
$('#landing_' + tlid).hide()
jQuery('time.timeago').timeago()
moreloading = false
todc()
}
}
}
//Announcement
function announ(acct_id, tlid) {
var at = localStorage.getItem('acct_' + acct_id + '_at')

View File

@@ -14,7 +14,7 @@ function addColumnMenu() {
$('#add-box').removeClass('hide')
addselCk()
}
$('.type').click(function() {
$('.type').click(function () {
$('.type').removeClass('active')
$(this).addClass('active')
$('#type-sel').val($(this).attr('data-type'))
@@ -44,7 +44,7 @@ function parseColumn(target, dontclose) {
var obj = JSON.parse(multi)
var templete
Object.keys(obj).forEach(function(key) {
Object.keys(obj).forEach(function (key) {
var acct = obj[key]
localStorage.setItem('name_' + key, acct.name)
@@ -76,8 +76,8 @@ function parseColumn(target, dontclose) {
var obj = [
{
domain: 0,
type: 'local'
}
type: 'local',
},
]
var json = JSON.stringify(obj)
localStorage.setItem('column', json)
@@ -122,10 +122,7 @@ function parseColumn(target, dontclose) {
var if_notf = ''
}
if (localStorage.getItem('notification_' + acct.domain)) {
var unique_notf = lang.lang_layout_thisacct.replace(
'{{notf}}',
localStorage.getItem('notification_' + acct.domain)
)
var unique_notf = lang.lang_layout_thisacct.replace('{{notf}}', localStorage.getItem('notification_' + acct.domain))
} else {
if (lang.language == 'ja') {
var notflocale = '通知'
@@ -191,17 +188,7 @@ function parseColumn(target, dontclose) {
} else {
var animecss = ''
}
unstreamingTL(
acct.type,
key,
basekey,
insert,
icnsert,
acct.left_fold,
css,
animecss,
acct.data
)
unstreamingTL(acct.type, key, basekey, insert, icnsert, acct.left_fold, css, animecss, acct.data)
} else if (acct.type == 'bookmark') {
if (!acct.left_fold) {
basekey = key
@@ -213,17 +200,19 @@ function parseColumn(target, dontclose) {
} else {
var animecss = ''
}
unstreamingTL(
acct.type,
key,
basekey,
insert,
icnsert,
acct.left_fold,
css,
animecss,
acct.domain
)
unstreamingTL(acct.type, key, basekey, insert, icnsert, acct.left_fold, css, animecss, acct.domain)
} else if (acct.type == 'utl') {
if (!acct.left_fold) {
basekey = key
}
var anime = localStorage.getItem('animation')
if (anime == 'yes' || !anime) {
var animecss = 'box-anime'
} else {
var animecss = ''
}
unstreamingTL(acct.type, key, basekey, insert, icnsert, acct.left_fold, css, animecss, { acct: acct.domain, data: acct.data })
} else {
var anime = localStorage.getItem('animation')
if (anime == 'yes' || !anime) {
@@ -292,7 +281,7 @@ function parseColumn(target, dontclose) {
${lang.lang_layout_excludingbt}
<br>`
} else if (acct.type == 'tag') {
if(acct.data.name) {
if (acct.data.name) {
var name = acct.data.name
var all = acct.data.all
var any = acct.data.any
@@ -352,9 +341,7 @@ function parseColumn(target, dontclose) {
if (key === 0) {
left_hold = ''
}
if (
localStorage.getItem('mode_' + localStorage.getItem('domain_' + acct.domain)) == 'misskey'
) {
if (localStorage.getItem('mode_' + localStorage.getItem('domain_' + acct.domain)) == 'misskey') {
var isMisRed = ''
exclude = ''
var if_misskey_hide = 'hide'
@@ -367,6 +354,18 @@ function parseColumn(target, dontclose) {
} else {
var addHeight = ''
}
if (acct.type != 'pub' && acct.type != 'pub-media') {
console.log(acct.type, key)
var mediaFil = `<a onclick="mediaToggle('${key}')" class="setting nex">
<i class="material-icons waves-effect nex" title="${lang.lang_layout_mediafil}">perm_media</i>
<span id="sta-media-${key}">On</span>
</a>${lang.lang_layout_mediafil}`
} else {
var mediaFil = `<a onclick="remoteOnly('${key}','${acct.type}')" class="setting nex">
<i class="material-icons waves-effect nex" title="${lang.lang_layout_remoteOnly}">perm_media</i>
<span id="sta-remote-${key}">Off</span>
</a>${lang.lang_layout_remoteOnly}`
}
var html = `
<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}">
@@ -421,11 +420,7 @@ function parseColumn(target, dontclose) {
<div class="column-hide notf-indv-box" id="util-box_${key}" style="padding:5px;">
${unread}
${exclude}${left_hold}
<a onclick="mediaToggle('${key}')" class="setting nex">
<i class="material-icons waves-effect nex" title="${lang.lang_layout_mediafil}">perm_media</i>
<span id="sta-media-${key}">On</span>
</a>
${lang.lang_layout_mediafil}<br>
${mediaFil}<br>
<a onclick="cardToggle('${key}')" class="setting nex">
<i class="material-icons waves-effect nex" title="${lang.lang_layout_linkanades}">link</i>
<span id="sta-card-${key}">On</span>
@@ -517,13 +512,13 @@ function parseColumn(target, dontclose) {
minHeight: 50,
minWidth: 50,
grid: 50,
resize: function(event, ui) {
resize: function (event, ui) {
$(this).css('min-width', ui.size.width + 'px')
$(this).css('max-width', ui.size.width + 'px')
$(this).css('min-height', ui.size.height + 'px')
$(this).css('max-height', ui.size.height + 'px')
},
stop: function(event, ui) {
stop: function (event, ui) {
var col = localStorage.getItem('column')
var o = JSON.parse(col)
var width = ui.size.width
@@ -538,16 +533,14 @@ function parseColumn(target, dontclose) {
} else {
//横幅。その縦幅を持つカラムのidは
console.log('yoko')
var key = $(this)
.find('.boxIn')
.attr('tlid')
var key = $(this).find('.boxIn').attr('tlid')
var obj = o[key]
obj.width = width
o[key] = obj
}
var json = JSON.stringify(o)
localStorage.setItem('column', json)
}
},
})
}
function checkStr(type, data, acct_id, key, delc, voice) {
@@ -597,7 +590,7 @@ function addColumn() {
}
var add = {
domain: acct,
type: type
type: type,
}
var multi = localStorage.getItem('column')
var obj = JSON.parse(multi)
@@ -631,9 +624,7 @@ function addselCk() {
$('#webview-add').addClass('hide')
}
if (domain == 'knzk.me' || domain == 'mstdn.y-zu.org') {
$('#type-sel').append(
'<option value="dm" data-trans="dm" id="direct-add">' + lang.layout_dm + '</option>'
)
$('#type-sel').append('<option value="dm" data-trans="dm" id="direct-add">' + lang.layout_dm + '</option>')
} else {
$('#direct-add').remove()
}
@@ -650,8 +641,8 @@ function removeColumn(tlid) {
confirmButtonColor: '#3085d6',
cancelButtonColor: '#d33',
confirmButtonText: lang.lang_yesno,
cancelButtonText: lang.lang_no
}).then(result => {
cancelButtonText: lang.lang_no,
}).then((result) => {
if (result.value) {
var multi = localStorage.getItem('column')
var obj = JSON.parse(multi)
@@ -673,28 +664,28 @@ function setToggle(tlid) {
$('#util-box_' + tlid).css('display', 'block')
$('#util-box_' + tlid).animate(
{
height: '200px'
height: '200px',
},
{
duration: 300,
complete: function() {
complete: function () {
$('#util-box_' + tlid).css('overflow-y', 'scroll')
$('#util-box_' + tlid).removeClass('column-hide')
}
},
}
)
} else {
$('#util-box_' + tlid).css('overflow-y', 'hidden')
$('#util-box_' + tlid).animate(
{
height: '0'
height: '0',
},
{
duration: 300,
complete: function() {
complete: function () {
$('#util-box_' + tlid).addClass('column-hide')
$('#util-box_' + tlid).css('display', 'none')
}
},
}
)
}
@@ -706,28 +697,28 @@ function setToggleTag(tlid) {
$('#tag-box_' + tlid).css('display', 'block')
$('#tag-box_' + tlid).animate(
{
height: '200px'
height: '200px',
},
{
duration: 300,
complete: function() {
complete: function () {
$('#tag-box_' + tlid).css('overflow-y', 'scroll')
$('#tag-box_' + tlid).removeClass('column-hide')
}
},
}
)
} else {
$('#tag-box_' + tlid).css('overflow-y', 'hidden')
$('#tag-box_' + tlid).animate(
{
height: '0'
height: '0',
},
{
duration: 300,
complete: function() {
complete: function () {
$('#tag-box_' + tlid).addClass('column-hide')
$('#tag-box_' + tlid).css('display', 'none')
}
},
}
)
}
@@ -834,11 +825,16 @@ function unstreamingTL(type, key, basekey, insert, icnsert, left_fold, css, anim
${lang.lang_layout_leftUnfold}
</span><br>`
}
if(type == 'utl') {
var dataHtml = false
} else {
var dataHtml = data
}
var html = `<div class="boxIn" id="timeline_box_${key}_box" tlid="${key}">
<div class="notice-box z-depth-2" id="menu_${key}" style="${insert} ">
<div class="area-notice">
<i class="material-icons waves-effect" id="notice_icon_${key}" style="font-size:40px; padding-top:25%;"
onclick="${type}('${key}','${data}');" title="${lang.lang_layout_gotop}"></i>
onclick="${type}('${key}','${dataHtml}');" title="${lang.lang_layout_gotop}"></i>
</div>
<div class="area-notice_name">
<span id="notice_${key}" class="tl-title"></span>
@@ -879,6 +875,8 @@ function unstreamingTL(type, key, basekey, insert, icnsert, left_fold, css, anim
} else if (type == 'bookmark') {
console.log(key, data)
bookmark(key, data)
} else if (type == 'utl') {
utl(key, data.acct, data.data)
}
cardCheck(key)
ebtCheck(key)
@@ -896,6 +894,22 @@ function bookmark(key, data) {
}
tl('bookmark', '', data, key, 'false', voice, '')
}
function utl(key, acct_id, 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
} else {
var voice = false
}
tl('utl', data, acct_id, key, 'false', voice, '')
}
function leftFoldSet(key) {
var multi = localStorage.getItem('column')
var obj = JSON.parse(multi)

View File

@@ -58,10 +58,10 @@ function show() {
mdCheck()
}
$(function() {
$(function () {
$('#post-box').draggable({
handle: '#post-bar',
stop: function() {
stop: function () {
var left = $('#post-box').offset().left
if (left > $('body').width() - $('#post-box').width()) {
left = $('body').width() - $('#post-box').width()
@@ -76,15 +76,15 @@ $(function() {
}
localStorage.setItem('postbox-left', left)
localStorage.setItem('postbox-top', top)
}
},
})
$('#post-box').resizable({
minHeight: 150,
minWidth: 100,
stop: function(event, ui) {
stop: function (event, ui) {
$('#textarea').blur()
localStorage.setItem('postbox-width', ui.size.width)
}
},
})
})
@@ -101,41 +101,44 @@ if (location.search) {
$('.mini-btn').text('expand_less')
}
}
$('#posttgl').click(function(e) {
if (!$('#post-box').hasClass('appear')) {
show()
} else {
hide()
}
$('.cvo').removeClass('selectedToot')
selectedColumn = 0
selectedToot = 0
})
$('#timeline-container,#group').click(function(e) {
if (localStorage.getItem('box') != 'absolute') {
if ($('#post-box').hasClass('appear') && !localStorage.getItem('nohide')) {
window.onload = initPostbox
function initPostbox() {
$('#posttgl').click(function (e) {
if (!$('#post-box').hasClass('appear')) {
show()
} else {
hide()
}
}
$('.cvo').removeClass('selectedToot')
selectedColumn = 0
selectedToot = 0
localStorage.removeItem('nohide')
srcBox('close')
})
$('#contextWrap').click(function(e) {
$('#contextWrap').addClass('hide')
$('.contextMenu').addClass('hide')
$('.act-icon').text('expand_more')
})
$('#textarea,#cw-text').focusout(function(e) {
localStorage.setItem('nohide', true)
var countup = function() {
$('.cvo').removeClass('selectedToot')
selectedColumn = 0
selectedToot = 0
})
$('#timeline-container,#group').click(function (e) {
if (localStorage.getItem('box') != 'absolute') {
if ($('#post-box').hasClass('appear') && !localStorage.getItem('nohide')) {
hide()
}
}
$('.cvo').removeClass('selectedToot')
selectedColumn = 0
selectedToot = 0
localStorage.removeItem('nohide')
}
//setTimeout(remove, 100);
$('.cvo').removeClass('selectedToot')
selectedColumn = 0
selectedToot = 0
})
srcBox('close')
})
$('#contextWrap').click(function (e) {
$('#contextWrap').addClass('hide')
$('.contextMenu').addClass('hide')
$('.act-icon').text('expand_more')
})
$('#textarea,#cw-text').focusout(function (e) {
localStorage.setItem('nohide', true)
var countup = function () {
localStorage.removeItem('nohide')
}
//setTimeout(remove, 100);
$('.cvo').removeClass('selectedToot')
selectedColumn = 0
selectedToot = 0
})
}

View File

@@ -3,7 +3,7 @@ var envView = new Vue({
el: '#envView',
data: { config: envConstruction },
methods: {
complete: function(i, val) {
complete: function (i, val) {
var ls = envView.config[i].storage
M.toast({ html: 'Complete', displayLength: 3000 })
if (!val) {
@@ -21,14 +21,14 @@ var envView = new Vue({
frameSet(val)
}
return true
}
}
},
},
})
var tlView = new Vue({
el: '#tlView',
data: { config: tlConstruction },
methods: {
complete: function(i, val) {
complete: function (i, val) {
var ls = tlView.config[i]
if (val) {
localStorage.setItem(ls.storage, val)
@@ -46,18 +46,18 @@ var tlView = new Vue({
}
}
return true
}
}
},
},
})
var postView = new Vue({
el: '#postView',
data: {
config: postConstruction,
kirishima: localStorage.getItem('kirishima'),
quoters: localStorage.getItem('quoters')
quoters: localStorage.getItem('quoters'),
},
methods: {
complete: function(i, val) {
complete: function (i, val) {
var ls = postView.config[i]
if (val) {
localStorage.setItem(ls.storage, val)
@@ -75,8 +75,8 @@ var postView = new Vue({
}
}
return true
}
}
},
},
})
//設定ボタン押した。
function settings() {
@@ -177,6 +177,7 @@ function load() {
$('#soundVolVal').text(cvol * 100)
}
//$("#log").val(localStorage.getItem("errors"))
$('#lastFmUser').val(localStorage.getItem('lastFmUser'))
}
function customVol() {
var cvol = $('#soundvol').val()
@@ -215,7 +216,7 @@ function climute() {
return
}
var templete
Object.keys(obj).forEach(function(key) {
Object.keys(obj).forEach(function (key) {
var cli = obj[key]
var list = key * 1 + 1
templete =
@@ -250,7 +251,7 @@ function wordmute() {
obj = []
}
$('#wordmute').chips({
data: obj
data: obj,
})
}
function wordmuteSave() {
@@ -266,7 +267,7 @@ function wordemp() {
obj = []
}
$('#wordemp').chips({
data: obj
data: obj,
})
}
function wordempSave() {
@@ -278,7 +279,7 @@ function notftest() {
var os = localStorage.getItem('platform')
var options = {
body: lang.lang_setting_notftest + '(' + lang.lang_setting_notftestprof + ')',
icon: localStorage.getItem('prof_0')
icon: localStorage.getItem('prof_0'),
}
var n = new Notification('TheDesk' + lang.lang_setting_notftest, options)
}
@@ -303,7 +304,7 @@ function changelang(lang) {
}
function exportSettings() {
var exp = exportSettingsCore()
$("#imp-exp").val(JSON5.stringify(exp))
$('#imp-exp').val(JSON5.stringify(exp))
Swal.fire({
title: lang.lang_setting_exportwarn,
type: 'warning',
@@ -311,8 +312,8 @@ function exportSettings() {
confirmButtonColor: '#3085d6',
cancelButtonColor: '#d33',
confirmButtonText: lang.lang_yesno,
cancelButtonText: lang.lang_no
}).then(result => {
cancelButtonText: lang.lang_no,
}).then((result) => {
if (result.value) {
postMessage(['exportSettings', ''], '*')
}
@@ -351,11 +352,7 @@ function exportSettingsCore() {
config.font = localStorage.getItem('font')
exp.config = config
//keysc
exp.ksc = [
localStorage.getItem('oks-1'),
localStorage.getItem('oks-2'),
localStorage.getItem('oks-3')
]
exp.ksc = [localStorage.getItem('oks-1'), localStorage.getItem('oks-2'), localStorage.getItem('oks-3')]
//climu
var cli = localStorage.getItem('client_mute')
var climu = JSON.parse(cli)
@@ -384,8 +381,8 @@ function exportSettingsCore() {
return exp
}
function importSettings() {
if($("#imp-exp").val()) {
importSettingsCore(JSON5.parse($("#imp-exp").val()))
if ($('#imp-exp').val()) {
importSettingsCore(JSON5.parse($('#imp-exp').val()))
return false
}
Swal.fire({
@@ -395,8 +392,8 @@ function importSettings() {
confirmButtonColor: '#3085d6',
cancelButtonColor: '#d33',
confirmButtonText: lang.lang_yesno,
cancelButtonText: lang.lang_no
}).then(result => {
cancelButtonText: lang.lang_no,
}).then((result) => {
if (result.value) {
postMessage(['importSettings', ''], '*')
}
@@ -490,7 +487,7 @@ function importSettingsCore(obj) {
} else {
Swal.fire({
type: 'error',
title: 'Error'
title: 'Error',
})
}
}
@@ -505,21 +502,13 @@ function fontList(arg) {
$('#fonts').removeClass('hide')
for (var i = 0; i < arg.length; i++) {
var font = arg[i]
$('#fonts').append(
'<div class="font pointer" style="font-family:' +
font +
'" onclick="insertFont(\'' +
font +
'\')">' +
font +
'</div>'
)
$('#fonts').append('<div class="font pointer" style="font-family:' + font + '" onclick="insertFont(\'' + font + '\')">' + font + '</div>')
}
}
function insertFont(name) {
$('#font').val(name)
}
$('.color-picker').each(function(i, elem) {
$('.color-picker').each(function (i, elem) {
pickerDefine(i, 'fff')
})
function pickerDefine(i, color) {
@@ -536,17 +525,16 @@ function pickerDefine(i, color) {
hue: true, // Hue slider
interaction: {
rgba: false, // rgba option (red green blue and alpha)
input: true // input / output element
}
input: true, // input / output element
},
},
strings: {
save: 'Save', // Default for save button
clear: 'Clear' // Default for clear button
}
clear: 'Clear', // Default for clear button
},
})
pickr.on('change', (...args) => {
var rgb =
'rgb(' + args[0].toRGBA()[0] + ',' + args[0].toRGBA()[1] + ',' + args[0].toRGBA()[2] + ')'
var rgb = 'rgb(' + args[0].toRGBA()[0] + ',' + args[0].toRGBA()[1] + ',' + args[0].toRGBA()[2] + ')'
$('#color-picker' + i + '_value').val(rgb)
})
}
@@ -600,7 +588,7 @@ function customComp() {
TheDeskModal: modalC,
TheDeskBottom: bottomC,
TheDeskPostbox: postboxC,
TheDeskSubcolor: subcolorC
TheDeskSubcolor: subcolorC,
}
} else {
var advanceTheme = {}
@@ -620,10 +608,10 @@ function customComp() {
vars: {
primary: primaryC,
secondary: secondaryC,
text: textC
text: textC,
},
props: advanceTheme,
id: id
id: id,
}
$('#custom_json').val(JSON.stringify(json))
themes('custom')
@@ -633,9 +621,7 @@ function customComp() {
$('#dark').prop('checked', true)
$('#custom_json').val('')
for (var i = 0; i <= 8; i++) {
$('#color-picker' + i + '-wrap').html(
'<div class="color-picker" id="color-picker' + i + '"></div>'
)
$('#color-picker' + i + '-wrap').html('<div class="color-picker" id="color-picker' + i + '"></div>')
$('#color-picker' + i + '_value').val('')
pickerDefine(i, 'fff')
}
@@ -648,9 +634,7 @@ function deleteIt() {
$('#dark').prop('checked', true)
$('#custom_json').val('')
for (var i = 0; i <= 8; i++) {
$('#color-picker' + i + '-wrap').html(
'<div class="color-picker" id="color-picker' + i + '"></div>'
)
$('#color-picker' + i + '-wrap').html('<div class="color-picker" id="color-picker' + i + '"></div>')
$('#color-picker' + i + '_value').val('')
pickerDefine(i, 'fff')
}
@@ -661,7 +645,7 @@ function ctLoad() {
}
function ctLoadCore(args) {
var templete = ''
Object.keys(args).forEach(function(key) {
Object.keys(args).forEach(function (key) {
var theme = args[key]
var themeid = theme.id
templete = templete + '<option value="' + themeid + '">' + theme.name + '</option>'
@@ -670,8 +654,7 @@ function ctLoadCore(args) {
localStorage.setItem('customtheme-id', args[0].id)
}
$('#custom-sel-sel').html(templete)
templete =
'<option value="add_new">' + $('#edit-selector').attr('data-add') + '</option>' + templete
templete = '<option value="add_new">' + $('#edit-selector').attr('data-add') + '</option>' + templete
$('#custom-edit-sel').html(templete)
$('select').formSelect()
}
@@ -687,9 +670,7 @@ function custom() {
$('#dark').prop('checked', true)
$('#custom_json').val('')
for (var i = 0; i <= 8; i++) {
$('#color-picker' + i + '-wrap').html(
'<div class="color-picker" id="color-picker' + i + '"></div>'
)
$('#color-picker' + i + '-wrap').html('<div class="color-picker" id="color-picker' + i + '"></div>')
$('#color-picker' + i + '_value').val('')
pickerDefine(i, 'fff')
}
@@ -737,9 +718,7 @@ function advancedConncet(args, tar, sub, i) {
} else {
var color = args.vars[sub]
}
$('#color-picker' + i + '-wrap').html(
'<div class="color-picker" id="color-picker' + i + '"></div>'
)
$('#color-picker' + i + '-wrap').html('<div class="color-picker" id="color-picker' + i + '"></div>')
$('#color-picker' + i + '_value').val(color)
pickerDefine(i, rgbToHex(color))
}
@@ -750,7 +729,7 @@ function customImp() {
} else {
Swal.fire({
type: 'error',
title: 'Error'
title: 'Error',
})
}
}
@@ -777,7 +756,7 @@ function customSoundSave(key, file) {
localStorage.setItem('custom' + key, file)
$('#c1-file').text(file)
}
window.onload = function() {
window.onload = function () {
//最初に読む
load()
climute()
@@ -787,17 +766,14 @@ window.onload = function() {
voiceSettingLoad()
oksload()
ctLoad()
$('body').addClass(localStorage.getItem('platform'))
}
//設定画面で未読マーカーは要らない
function asReadEnd() {
postMessage(['asReadComp', ''], '*')
}
function checkupd() {
if (
localStorage.getItem('winstore') == 'brewcask' ||
localStorage.getItem('winstore') == 'snapcraft' ||
localStorage.getItem('winstore') == 'winstore'
) {
if (localStorage.getItem('winstore') == 'brewcask' || localStorage.getItem('winstore') == 'snapcraft' || localStorage.getItem('winstore') == 'winstore') {
var winstore = true
} else {
var winstore = false
@@ -805,22 +781,22 @@ function checkupd() {
var ver = localStorage.getItem('ver')
var start = 'https://thedesk.top/ver.json'
fetch(start, {
method: 'GET'
method: 'GET',
})
.then(function(response) {
.then(function (response) {
if (!response.ok) {
response.text().then(function(text) {
response.text().then(function (text) {
setLog(response.url, response.status, text)
})
}
return response.json()
})
.catch(function(error) {
.catch(function (error) {
todo(error)
setLog(start, 'JSON', error)
console.error(error)
})
.then(function(mess) {
.then(function (mess) {
console.table(mess)
if (mess) {
var platform = localStorage.getItem('platform')
@@ -833,13 +809,13 @@ function checkupd() {
Swal.fire({
type: 'info',
title: lang.lang_setting_noupd,
html: ver
html: ver,
})
} else if (ver.indexOf('beta') != -1 || winstore) {
Swal.fire({
type: 'info',
title: lang.lang_setting_thisisbeta,
html: ver
html: ver,
})
} else {
localStorage.removeItem('new-ver-skip')
@@ -848,3 +824,11 @@ function checkupd() {
}
})
}
function lastFmSet() {
if ($('#lastFmUser').val()) {
localStorage.setItem('lastFmUser', $('#lastFmUser').val())
} else {
localStorage.removeItem('lastFmUser')
}
M.toast({ html: 'Complete: last.fm', displayLength: 3000 })
}

View File

@@ -138,6 +138,76 @@ function nowplaying(mode) {
}
} else if (mode == 'itunes') {
postMessage(['itunes', ''], '*')
} else if (mode == 'lastFm') {
var user = localStorage.getItem('lastFmUser')
var start = 'https://ws.audioscrobbler.com/2.0/?method=user.getrecenttracks&user=' + user + '&limit=1&api_key=8f113803bfea951b6dde9e56d32458b2&format=json'
if (user) {
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) {
console.table(json)
if (!json || !json.recenttracks) {
console.error('no data')
return false
}
var item = json.recenttracks.track[0]
if(!item['@attr']) return false
var img = item.image[3]['#text']
var isImg = item.streamable*1
var flag = localStorage.getItem('artwork')
if (flag && isImg && img) {
postMessage(['bmpImage', [img, 0]], '*')
}
var content = localStorage.getItem('np-temp')
if (!content || content == '' || content == 'null') {
var content = '#NowPlaying {song} / {album} / {artist}\n{url}'
}
var regExp = new RegExp('{song}', 'g')
content = content.replace(regExp, item.name)
var regExp = new RegExp('{album}', 'g')
content = content.replace(regExp, item.album['#text'])
var regExp = new RegExp('{artist}', 'g')
content = content.replace(regExp, item.artist['#text'])
var regExp = new RegExp('{url}', 'g')
content = content.replace(regExp,'')
var regExp = new RegExp('{composer}', 'g')
content = content.replace(regExp, '')
var regExp = new RegExp('{hz}', 'g')
content = content.replace(regExp, '')
var regExp = new RegExp('{bitRate}', 'g')
content = content.replace(regExp, '')
var regExp = new RegExp('{lyricist}', 'g')
content = content.replace(regExp, '')
var regExp = new RegExp('{bpm}', 'g')
content = content.replace(regExp, '')
var regExp = new RegExp('{genre}', 'g')
content = content.replace(regExp, '')
$('#textarea').val(content)
})
} else {
Swal.fire({
type: 'info',
title: lang.lang_spotify_acct,
})
}
}
}
async function npCore(arg) {
@@ -148,6 +218,7 @@ async function npCore(arg) {
}
var flag = localStorage.getItem('artwork')
var platform = localStorage.getItem('platform')
var aaw = { aaw: '', album: '' }
if (platform == 'win32') {
if (flag && arg.path) {
media(arg.path, 'image/png', 'new')
@@ -157,7 +228,7 @@ async function npCore(arg) {
media(arg.artwork, 'image/png', 'new')
} else if (flag && localStorage.getItem('complete-artwork')) {
var q = arg.artist + ' ' + arg.album.name + ' ' + arg.name
var aaw = await getUnknownAA(q)
aaw = await getUnknownAA(q)
postMessage(['bmpImage', [aaw.aaw, 0]], '*')
}
}
@@ -168,11 +239,11 @@ async function npCore(arg) {
if (arg.album.name) {
content = content.replace(regExp, arg.album.name)
} else {
if(aaw.album) content.replace(regExp, aaw.album)
if (aaw.album) content = content.replace(regExp, aaw.album)
content = content.replace(regExp, '-')
}
} else {
if(aaw.album) content.replace(regExp, aaw.album)
if (aaw.album) content = content.replace(regExp, aaw.album)
content = content.replace(regExp, '-')
}
var regExp = new RegExp('{artist}', 'g')

View File

@@ -30,7 +30,7 @@ function tips(mode) {
localStorage.getItem('ver') +
' git: ' +
gitHash +
'\')">TheDesk ' +
'\')"> ' +
localStorage.getItem('ver') +
' {' +
gitHash.slice(0, 7) +

View File

@@ -1,6 +1,6 @@
//ユーザーデータ表示
//タイムライン
function utl(user, more, acct_id) {
function utlShow(user, more, acct_id) {
if (!acct_id) {
var acct_id = $("#his-data").attr("use-acct");
}
@@ -79,6 +79,26 @@ function utl(user, more, acct_id) {
jQuery("time.timeago").timeago();
});
}
function utlAdd() {
var acct_id = $("#his-data").attr("use-acct");
var user = $("#his-data").attr("user-id");
var add = {
domain: acct_id,
type: 'utl',
data: {
id: user,
acct: $("#his-acct").attr('fullname')
}
}
var multi = localStorage.getItem('column')
var obj = JSON.parse(multi)
localStorage.setItem('card_' + obj.length, 'true')
obj.push(add)
var json = JSON.stringify(obj)
localStorage.setItem('column', json)
parseColumn('add')
hisclose()
}
//ピン留めTL
function pinutl(before, user, acct_id) {
if (!acct_id) {

View File

@@ -115,7 +115,7 @@ function udg(user, acct_id) {
$("#his-data").attr("remote", "false");
var fullname = json.acct + "@" + domain;
}
utl(json.id, "", acct_id);
utlShow(json.id, "", acct_id);
flw(json.id, "", acct_id);
fer(json.id, "", acct_id);
var dis_name = escapeHTML(json.display_name);
@@ -298,7 +298,7 @@ function misskeyUdg(user, acct_id) {
$("#his-data").attr("remote", "false");
var fullname = json.acct + "@" + domain;
}
utl(json.id, "", acct_id);
utlShow(json.id, "", acct_id);
flw(json.id, "", acct_id);
fer(json.id, "", acct_id);
if (json.name) {

View File

@@ -3,6 +3,10 @@ var dir = 'file://' + __dirname
var base = dir + '/view/'
// Electronのモジュール
const electron = require('electron')
// アプリケーションをコントロールするモジュール
const app = electron.app
// Electronの初期化完了後に実行
app.on('ready', createWindow)
const fs = require('fs')
const language = require('./main/language.js')
const css = require('./main/css.js')
@@ -12,9 +16,6 @@ const np = require('./main/np.js')
const systemFunc = require('./main/system.js')
const Menu = electron.Menu
const join = require('path').join
// アプリケーションをコントロールするモジュール
const app = electron.app
// ウィンドウを作成するモジュール
const BrowserWindow = electron.BrowserWindow
// メインウィンドウはGCされないようにグローバル宣言
@@ -36,60 +37,11 @@ if (!gotTheLock) {
})
}
if (process.argv.indexOf('--dev') === -1) {
var packaged = true
} else {
var packaged = false
console.log(
'||\\\\\\ \n' +
'|||| \\\\\\\\ \n' +
'|||| \\\\\\\\ \n' +
'|||| Am I a \\\\\\\\ \n' +
'|||| cat? ^ ^ \\\\\\\\\\ _____ _ ____ _ \n' +
'|||| (.-.) \\\\\\\\\\ |_ _| |__ ___| _ \\ ___ ___| | __\n' +
"|||| ___> ) ||||| | | | '_ \\ / _ \\ | | |/ _ \\/ __| |/ /\n" +
'|||| < _ _) ////// | | | | | | __/ |_| | __/__ \\ < \n' +
'|||| |_||_| ///// |_| |_| |_|\\___|____/ \\___||___/_|\\_\\ \n' +
'|||| ///// \n' +
'|||| /////\n' +
'|||| /////\n' +
'||||//////'
)
console.log('If it does not show the window, you might forget `npm run construct`.')
}
var info_path = join(app.getPath('userData'), 'window-size.json')
var max_info_path = join(app.getPath('userData'), 'max-window-size.json')
var lang_path = join(app.getPath('userData'), 'language')
var ha_path = join(app.getPath('userData'), 'hardwareAcceleration')
var ua_path = join(app.getPath('userData'), 'useragent')
var frame_path = join(app.getPath('userData'), 'frame')
try {
fs.readFileSync(ha_path, 'utf8')
app.disableHardwareAcceleration()
if (!packaged) console.log('disabled: Hardware Acceleration')
} catch {
if (!packaged) console.log('enabled: Hardware Acceleration')
}
var window_size
try {
window_size = JSON.parse(fs.readFileSync(info_path, 'utf8'))
} catch (e) {
window_size = {
width: 1000,
height: 750
} // デフォルトバリュー
}
var max_window_size
try {
max_window_size = JSON.parse(fs.readFileSync(max_info_path, 'utf8'))
} catch (e) {
max_window_size = {
width: 'string',
height: 'string',
x: 'string',
y: 'string'
} // デフォルトバリュー
}
// 全てのウィンドウが閉じたら終了
app.on('window-all-closed', function () {
electron.session.defaultSession.clearCache(() => {})
app.quit()
})
function isFile(file) {
try {
fs.statSync(file)
@@ -98,24 +50,8 @@ function isFile(file) {
if (err.code === 'ENOENT') return false
}
}
try {
var frameRaw = fs.readFileSync(frame_path, 'utf8')
if(frameRaw == 'false') {
var frame = false
var frameTitle = 'hidden'
} else {
var frame = true
var frameTitle = 'default'
}
} catch {
var frame = true
}
// 全てのウィンドウが閉じたら終了
app.on('window-all-closed', function() {
electron.session.defaultSession.clearCache(() => {})
app.quit()
})
function createWindow() {
var lang_path = join(app.getPath('userData'), 'language')
if (isFile(lang_path)) {
var lang = fs.readFileSync(lang_path, 'utf8')
} else {
@@ -132,68 +68,128 @@ function createWindow() {
} else {
lang = 'en'
}
fs.mkdir(app.getPath('userData'), function(err) {
fs.mkdir(app.getPath('userData'), function (err) {
fs.writeFileSync(lang_path, lang)
})
}
if (!packaged) console.log('your lang:' + app.getLocale())
if (!packaged) console.log('launch:' + lang)
//Opening
const package = fs.readFileSync(__dirname + '/package.json')
if(lang == 'ja') {
const maxims = JSON.parse(fs.readFileSync(__dirname + '/maxim.ja.json'))
var show = maxims[Math.floor(Math.random() * maxims.length)]
} else {
var show = 'TheDesk 2018'
}
const data = JSON.parse(package)
const version = data.version
const codename = data.codename
var openingWindow = new BrowserWindow({
width: 300,
height: 400,
transparent: false,
frame: false,
resizable: false,
})
openingWindow.loadURL(`${__dirname}/opening.html?ver=${version}&codename=${codename}&maxim=${encodeURI(show)}`)
if (process.argv.indexOf('--dev') === -1) {
var packaged = true
} else {
var packaged = false
console.log(
'||\\\\\\ \n' +
'|||| \\\\\\\\ \n' +
'|||| \\\\\\\\ \n' +
'|||| Am I a \\\\\\\\ \n' +
'|||| cat? ^ ^ \\\\\\\\\\ _____ _ ____ _ \n' +
'|||| (.-.) \\\\\\\\\\ |_ _| |__ ___| _ \\ ___ ___| | __\n' +
"|||| ___> ) ||||| | | | '_ \\ / _ \\ | | |/ _ \\/ __| |/ /\n" +
'|||| < _ _) ////// | | | | | | __/ |_| | __/__ \\ < \n' +
'|||| |_||_| ///// |_| |_| |_|\\___|____/ \\___||___/_|\\_\\ \n' +
'|||| ///// \n' +
'|||| /////\n' +
'|||| /////\n' +
'||||//////'
)
console.log('If it does not show the window, you might forget `npm run construct`.')
}
var info_path = join(app.getPath('userData'), 'window-size.json')
var max_info_path = join(app.getPath('userData'), 'max-window-size.json')
var ha_path = join(app.getPath('userData'), 'hardwareAcceleration')
var ua_path = join(app.getPath('userData'), 'useragent')
var frame_path = join(app.getPath('userData'), 'frame')
try {
fs.readFileSync(ha_path, 'utf8')
app.disableHardwareAcceleration()
if (!packaged) console.log('disabled: Hardware Acceleration')
} catch {
if (!packaged) console.log('enabled: Hardware Acceleration')
}
var window_size
try {
window_size = JSON.parse(fs.readFileSync(info_path, 'utf8'))
} catch (e) {
window_size = {
width: 1000,
height: 750,
} // デフォルトバリュー
}
var max_window_size
try {
max_window_size = JSON.parse(fs.readFileSync(max_info_path, 'utf8'))
} catch (e) {
max_window_size = {
width: 'string',
height: 'string',
x: 'string',
y: 'string',
} // デフォルトバリュー
}
try {
var frameRaw = fs.readFileSync(frame_path, 'utf8')
if (frameRaw == 'false') {
var frame = false
var frameTitle = 'hidden'
} else {
var frame = true
var frameTitle = 'default'
}
} catch {
var frame = true
}
// メイン画面の表示。ウィンドウの幅、高さを指定できる
var platform = process.platform
var bit = process.arch
var arg = {
webPreferences: {
webviewTag: true,
nodeIntegration: false,
contextIsolation: true,
preload: join(__dirname, 'js', 'platform', 'preload.js'),
},
width: window_size.width,
height: window_size.height,
x: window_size.x,
y: window_size.y,
show: false,
frame: frame,
}
if (platform == 'linux') {
var arg = {
webPreferences: {
webviewTag: true,
nodeIntegration: false,
contextIsolation: true,
preload: join(__dirname, 'js', 'platform', 'preload.js')
},
width: window_size.width,
height: window_size.height,
x: window_size.x,
y: window_size.y,
icon: __dirname + '/desk.png',
show: false,
frame: frame,
resizable: true
}
arg.resizable = true
arg.icon = __dirname + '/desk.png'
} else if (platform == 'win32') {
var arg = {
webPreferences: {
webviewTag: true,
nodeIntegration: false,
contextIsolation: true,
preload: join(__dirname, 'js', 'platform', 'preload.js')
},
width: window_size.width,
height: window_size.height,
x: window_size.x,
y: window_size.y,
simpleFullscreen: true,
show: false,
frame: frame
}
arg.simpleFullscreen = true
} else if (platform == 'darwin') {
var arg = {
webPreferences: {
webviewTag: true,
nodeIntegration: false,
contextIsolation: true,
preload: join(__dirname, 'js', 'platform', 'preload.js')
},
width: window_size.width,
height: window_size.height,
x: window_size.x,
y: window_size.y,
simpleFullscreen: true,
show: false,
titleBarStyle: frameTitle,
frame: frame,
}
arg.simpleFullscreen = true
arg.titleBarStyle = frameTitle
}
mainWindow = new BrowserWindow(arg)
mainWindow.once('page-title-updated', () => {
openingWindow.close()
mainWindow.show()
console.log('Accessibility: ' + app.accessibilitySupportEnabled)
if (window_size.max) {
@@ -226,40 +222,35 @@ function createWindow() {
// Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) thedesk/18.11.3 Chrome/76.0.3809.146 Electron/6.0.12 Safari/537.36
const crypto = require('crypto')
const N = 100
var ua =
'Mastodon client: ' +
crypto
.randomBytes(N)
.toString('base64')
.substring(0, N)
var ua = 'Mastodon client: ' + crypto.randomBytes(N).toString('base64').substring(0, N)
}
mainWindow.loadURL(base + lang + '/index.html' + plus, { userAgent: ua })
if (!window_size.x && !window_size.y) {
mainWindow.center()
}
// ウィンドウが閉じられたらアプリも終了
mainWindow.on('closed', function() {
mainWindow.on('closed', function () {
electron.ipcMain.removeAllListeners()
mainWindow = null
})
closeArg = false
mainWindow.on('close', function(e, arg) {
mainWindow.on('close', function (e, arg) {
writePos(mainWindow)
if (!closeArg) {
e.preventDefault()
}
const promise = new Promise(function(resolve) {
const promise = new Promise(function (resolve) {
mainWindow.webContents.send('asReadEnd', '')
setTimeout(function() {
setTimeout(function () {
resolve()
}, 3000)
})
promise.then(function(response) {
promise.then(function (response) {
closeArg = true
mainWindow.close()
})
})
electron.ipcMain.on('sendMarkersComplete', function(e, arg) {
electron.ipcMain.on('sendMarkersComplete', function (e, arg) {
closeArg = true
mainWindow.close()
})
@@ -275,33 +266,31 @@ function createWindow() {
height: mainWindow.getBounds().height,
x: mainWindow.getBounds().x,
y: mainWindow.getBounds().y,
max: true
max: true,
}
} else {
var size = {
width: mainWindow.getBounds().width,
height: mainWindow.getBounds().height,
x: mainWindow.getBounds().x,
y: mainWindow.getBounds().y
y: mainWindow.getBounds().y,
}
}
fs.writeFileSync(info_path, JSON.stringify(size))
}
mainWindow.on('maximize', function() {
mainWindow.on('maximize', function () {
writePos(mainWindow)
fs.writeFileSync(max_info_path, JSON.stringify(mainWindow.getBounds()))
})
mainWindow.on('minimize', function() {
mainWindow.on('minimize', function () {
writePos(mainWindow)
mainWindow.webContents.send('asRead', '')
})
var platform = process.platform
var bit = process.arch
Menu.setApplicationMenu(
Menu.buildFromTemplate(language.template(lang, mainWindow, packaged, dir, dirname, frame))
)
if(!frame) {
Menu.setApplicationMenu(Menu.buildFromTemplate(language.template(lang, mainWindow, packaged, dir, dirname, frame)))
if (!frame) {
mainWindow.setMenu(null)
}
//CSS
@@ -314,7 +303,7 @@ function createWindow() {
np.TheDeskNowPlaying(mainWindow)
//その他system
systemFunc.system(mainWindow, dir, lang, dirname)
setInterval(function() {
setInterval(function () {
mouseTrack(mainWindow)
}, 1000)
}
@@ -340,10 +329,5 @@ function mouseTrack(mainWindow) {
x = xNow
y = yNow
}
// Electronの初期化完了後に実行
app.on('ready', createWindow)
var onError = function(err, response) {
console.error(err, response)
}
app.setAsDefaultProtocolClient('thedesk')

View File

@@ -24,10 +24,14 @@ function dl(mainWindow, lang_path, base, dirname) {
height: 400,
transparent: false, // ウィンドウの背景を透過
frame: false, // 枠の無いウィンドウ
resizable: false
resizable: false,
show: false
})
var lang = fs.readFileSync(lang_path, 'utf8')
updatewin.loadURL(base + lang + '/update.html')
updatewin.webContents.once('dom-ready', () => {
updatewin.show()
})
return 'true'
} else {
return false
@@ -36,7 +40,7 @@ function dl(mainWindow, lang_path, base, dirname) {
//アプデDL
ipc.on('download-btn', async (e, args) => {
function dl(url, file, dir, e) {
e.sender.webContents.send('mess', 'ダウンロードを開始します。')
e.sender.webContents.send('mess', 'Start...')
const opts = {
directory: dir,
filename: file,

41
app/maxim.ja.json Normal file
View File

@@ -0,0 +1,41 @@
[
"TheDeskは自称ステイホームの必須アイテム",
"あと数秒でPCのファンが全力で回り始める",
"カラムの数だけ夢があるがネットワークは逼迫する",
"朝起きたらストリーミングが止まっていた…",
"誰も使ってない機能1: 未読管理",
"誰も使ってない機能2: スタンプ機能",
"TheDeskは重い(ダブルミーニング)",
"今日も生茶が美味しい(4ケース96本の在庫)",
"jQueryは死すべき(流れ弾)",
"なんでTheDeskのバージョン19は無いの",
"デレマス要素なくない?",
"今日も「TheDesk」でエゴサが捗る",
"開発者はTheDeskのヘビーユーザではない",
"アイコンは猫だが開発者は犬派",
"#TheDeskのアイコンは猫虐待",
"上のアニメーションからしてこの猫は完全に仮想化されている",
"TheDeskの歴史は2016年まで遡ることができる",
"WIP: Croudia, ネコ型SNS",
"リリース間隔は平均1桁日(昔1日に6回アプデを提供したせい)",
"node_modulesをignoreせずに上げてしまったせいでCode Frequencyが破壊された",
"TheDesk XSS Hunt をしなければならない()",
"毎月出る支援お願いしますダイアログで月初めを知る人 #いろいろな人",
"Integrated TLは目玉機能なので消せないが消せるものなら消したいくらい内部構造がヤバい",
"「アンケート」か「投票」か。「時間指定投稿」か「予約投稿」か",
"実装当初は言語を「関西弁」にするとお問い合わせフォームまで関西弁だった",
"Ctrl+Kでメニューが出ます",
"検索ボックスは入力後Enterで確定できる",
"開発者の推しカラーテーマはPolar Night",
"TheDeskのユーザーエージェントは毎回起動時に変わります。TheDeskと確定させることはできません",
"AppData/Roaming/TheDesk(Windows)の中にcutsom.cssを入れるとカスタムCSSを導入できます",
"環境設定の「ウィンドウフレーム」は「オフ」がおすすめ",
"各トゥートの右上の時刻表示を押すとトゥートのリンクがコピーされます",
"各トゥートの左下の公開範囲のアイコンを押すとそのトゥートの本文がコピーされますが挙動にバグがあります",
"TheDeskをMisskeyクライアントだと思って使ってはいけません",
"この迷文を追加したい場合はapp/maxim.ja.jsonを編集",
"本当はTheDesk 21.0.0(Mayu)専用のアイコンを用意していた",
"TheDesk 20.x.xと21.x.xではアイコンがちょっと違う",
"三大見てはいけないもの: TheDeskのコード、TheDeskのDevTool console、あと一つは",
"この画面がずっと出続けているのは多分yarn construct忘れてる"
]

View File

@@ -128,7 +128,7 @@
</select>
</div>
<button onclick="set()" id="setting">Setting</button>
<textarea id="textarea" style="width:55%; background-color:transparent" placeholder="Post someyhing new"></textarea>
<textarea id="textarea" style="width:55%; background-color:transparent" placeholder="Post something new"></textarea>
<button class="btn" onclick="post()">Post</button>
<button onclick="window.close()">x</button><br />
<div id="timeline_nano">Click "settings" to show TL</div>

96
app/opening.html Normal file
View File

@@ -0,0 +1,96 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<title>TheDesk</title>
<meta content="width=device-width,initial-scale=1.0" name="viewport" />
<meta charset="utf-8" />
<style>
@font-face {
font-family: 'Open Sans';
font-style: normal;
font-weight: 300;
src: local('Open Sans Light'), local('OpenSans-Light'), url('./fonts/OpenSans-Light.ttf') format('truetype');
}
body {
font-family: 'Open Sans';
-webkit-app-region: drag;
cursor: move;
padding: 5px;
padding-top: 15px;
background-color: #222222;
color: white;
text-align: center;
}
.loading {
animation: throbber-loader 1000ms 300ms infinite ease-out;
background: #3d3d3d;
display: inline-block;
position: relative;
text-indent: -9999px;
width: 0.9em;
height: 0.9em;
margin: 0 .9em;
}
.loading:before,
.loading:after {
background: #3d3d3d;
content: '\x200B';
display: inline-block;
width: 0.9em;
height: 0.9em;
position: absolute;
top: 0;
}
.loading:before {
animation: throbber-loader 1000ms 150ms infinite ease-out;
left: -1.9em;
}
.loading:after {
animation: throbber-loader 1000ms 450ms infinite ease-out;
right: -1.9em;
}
@keyframes throbber-loader {
0% {
background: #3d3d3d;
}
10% {
background: #6b9dc8;
}
40% {
background: #3d3d3d;
}
}
a,
button {
-webkit-app-region: no-drag;
}
h1 {
margin: 0;
}
#maxim {
font-size: 0.7rem;
}
</style>
</head>
<body class="center" style="overflow: hidden;">
<img src="./img/desk-animation.svg" style="max-width: 62%;" />
<h1>TheDesk</h1>
<span id="ver"></span><br />
<span class="loading"></span><br />
<div class="cp">
<span id="maxim"></span><br />
<script>
if (location.search) {
var m = location.search.match(/\?ver=([0-9.]+)&codename=([a-zA-Z]+)&maxim=(.+)/)
var ver = m[1]
var code = m[2]
var maxim = m[3]
document.getElementById('ver').innerText = `${ver}(${code})`
document.getElementById('maxim').innerText = `${decodeURI(maxim)}`
}
</script>
</div>
</body>
</html>

View File

@@ -1,7 +1,7 @@
{
"name": "thedesk",
"version": "20.3.3",
"codename": "Kawaii",
"version": "21.0.0",
"codename": "Mayu",
"description": "TheDesk is a Mastodon client for PC.",
"repository": "https://github.com/cutls/TheDesk",
"main": "main.js",
@@ -124,8 +124,8 @@
]
},
"electronDownload": {
"version": "6.0.0"
"version": "8.0.0"
},
"electronVersion": "6.0.0"
"electronVersion": "8.0.0"
}
}

View File

@@ -29,7 +29,7 @@
@@pwa@@
</head>
<body id="mainView">
<body id="mainView" class="@@pwaClass@@">
<script type="text/javascript" src="../../@@node_base@@/jquery/dist/jquery.js"></script>
<script type="text/javascript" src="../../js/platform/first.js"></script>
<script
@@ -63,12 +63,14 @@
<input type="text" id="url" style="width:70%" placeholder="ex)mstdn.jp" />
<div id="ins-suggest"></div>
<button class="btn waves-effect" onclick="instance()">Login</button><br />
@@codesetupwarn@@<br />
<label>
<input type="checkbox" class="filled-in" id="linux" />
<span>@@codesetup@@</span>
</label>
<br />
<div class="pwa">
@@codesetupwarn@@<br />
<label>
<input type="checkbox" class="filled-in" id="linux" />
<span>@@codesetup@@</span>
</label>
<br />
</div>
<label>
<input type="checkbox" class="filled-in" id="misskey" />
<span>@@thisismisskey@@</span> </label
@@ -144,5 +146,6 @@
<script type="text/javascript" src="../../js/login/instance.js"></script>
<script type="text/javascript" src="../../js/login/manager.js"></script>
<script type="text/javascript" src="../../js/tl/date.js"></script>
<script>$('body').addClass(localStorage.getItem('platform'))</script>
</body>
</html>

View File

@@ -34,7 +34,7 @@
@@comment-end@@ @@pwa@@
</head>
<body>
<body class="@@pwaClass@@">
<script>
var ver = '@@versionLetter@@'
var gitHash = '@@gitHash@@'
@@ -356,7 +356,7 @@
<a class="waves-effect gray" id="cw" onclick="cw()" title="@@cwDes@@">CW</a>
<span
><span id="imgup"></span
><span id="imgsel"
><span id="imgsel" class="pwa"
><i
class="waves-effect material-icons gray"
onclick="fileselect()"
@@ -389,7 +389,7 @@
<span class=" sml mize"
><span>@@replyMode@@</span>: <span id="rec">@@no@@</span>/<span>@@temp@@</span>:
<span id="mec">@@nothing@@</span>
<a onclick="stamp()" class="pointer" title="@@stampWarn@@"
<a onclick="stamp()" class="pointer pwa" title="@@stampWarn@@"
>@@stamp@@: <span id="stamp">Off</span></a
>
/@@poll@@:<span id="pollsta">@@no@@</span>
@@ -442,10 +442,13 @@
<!-- その他 Dropdown Structure -->
<ul id="dropdown2" class="dropdown-content">
<li>
<a onclick="nowplaying('spotify');">@@NPSpotify@@</a>
<a onclick="nowplaying('spotify');">NowPlaying (Spotify)</a>
</li>
<li class="mac">
<a onclick="nowplaying('itunes');">NowPlaying (iTunes macOS)</a>
</li>
<li>
<a onclick="nowplaying('itunes');">@@NPiTunes@@</a>
<a onclick="nowplaying('lastFm');">NowPlaying (Last.fm)</a>
</li>
<li>
<a onclick="schedule();">@@schedule@@</a>
@@ -897,11 +900,18 @@
</ul>
</div>
<div id="his-tl" class="his-var-content">
<button
class="btn waves-effect grey"
style="width:100%; padding:0;"
onclick="utlAdd()"
>
@@utlColumn@@
</button>
<div id="his-tl-contents" class="cont-series"></div>
<button
class="btn waves-effect "
style="width:100%; padding:0;"
onclick="utl('--now','more')"
onclick="utlShow('--now','more')"
>
@@more@@
</button>
@@ -1189,17 +1199,22 @@
<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-20-3-3_Kawaii" class="release-do" style="display:none; ">
<div id="release-21-0-0_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 20.3.3 (Kawaii)</h5>
アクセシビリティの改善 <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><br>
<h5>Release Note 21.0.0 (Mayu)</h5>
フォロリクをストリーミングで受け取ったときにNo status hereになる <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>
Apple MusicのNowPlayingでアルバム情報がないときの挙動を改善 <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 NowPlaying <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>
テーマCSSに関するバグ <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>
・プラットフォームやPWAか否か等で表示を切り替える <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="">anonymous user<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>
・FTLのRemote only <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>
</div>
<div id="release-en" style="display:none">
@@ -1601,7 +1616,7 @@
</div>
</div>
</div>
<a onclick="about()" class="nex waves-effect">
<a onclick="about()" class="nex waves-effect pwa">
<i class="material-icons" style="font-size: 1rem;">info</i>@@about@@ </a
>&nbsp;|&nbsp;
<a onclick="bottomReverse()" class="nex waves-effect">
@@ -1650,7 +1665,7 @@
<a href="setting.html" class="nex waves-effect">
<i class="material-icons nex" title="@@setting@@(Ctrl+Shift+S)">settings</i>
</a>
<a onclick="nano()" class="nex waves-effect">
<a onclick="nano()" class="nex waves-effect pwa">
<i class="material-icons" title="@@nanoDes@@TheDesk Nano" data-trans-title="nano_desp"
>remove_from_queue</i
>
@@ -1683,7 +1698,7 @@
>access_time</i
>
</a>
<a onclick="tips('memory')" class="nex waves-effect">
<a onclick="tips('memory')" class="nex waves-effect pwa">
<i class="material-icons nex" title="@@ramTips@@" data-trans-title="memory">memory</i>
</a>
<a onclick="tips('trend')" class="nex waves-effect imasonly" style="display:none;">

View File

@@ -11,8 +11,6 @@
"cwDes":"Hide text behind warning",
"selfile":"Attach..",
"insertEmoji":"Emojis",
"NPSpotify":"NowPlaying(Spotify)",
"NPiTunes":"NowPlaying(macOS)",
"schedule":"Scheduled toot",
"postat":"Post at",
"scheduleWarn":"2.7.0~ Minimum time gap:5min(clock on the server may not be accurate.)",
@@ -77,6 +75,7 @@
"toots":"Toots",
"follow":"Follow",
"follower":"Follower",
"utlColumn":"Show as a column",
"timeline":"Timeline",
"operateOtherAcct":"Cross-account",
"list":"List",

View File

@@ -127,6 +127,7 @@
"lang_layout_delthis": "Remove this column",
"lang_layout_setthis": "Preferences of this column",
"lang_layout_mediafil": "Media filtering",
"lang_layout_remoteOnly": "Remote only",
"lang_layout_linkana": "Auto Link Analyzer",
"lang_layout_linkanades": "Auto link analyzer",
"lang_layout_tts": "Text to speech ",

View File

@@ -167,6 +167,7 @@
"linkwarn": "TheDesk save your data on thedesk.top server.",
"connect": "Connect",
"disconnect": "Disconnect",
"lastFmWarn": "User name...(empty to disconnect) You cannot hide your recent play log at last.fm privacy settings.",
"templateedit": "Edit a template",
"templateeditwarn": "",
"template1": "Spotify:{song}:Song name/{album}:Album name/{artist}:Artist name/{url}:URL to Spotify",

View File

@@ -11,8 +11,6 @@
"cwDes":"コンテンツワーニング(ほんまに見るんか?って聞く)",
"selfile":"ファイル選ぶ",
"insertEmoji":"絵文字入れる",
"NPSpotify":"NowPlaying(Spotify)",
"NPiTunes":"NowPlaying(macOS)",
"schedule":"時間指定投稿",
"postat":"時間指定投稿",
"scheduleWarn":"2.7.0~ 5分は待ってな。サーバーの時計おうてるかは知らんで。",
@@ -75,6 +73,7 @@
"toots":"トゥート",
"follow":"フォロー",
"follower":"フォロワー",
"utlColumn":"カラムとして追加",
"timeline":"タイムライン",
"operateOtherAcct":"他のアカウント使うて何かする",
"list":"リスト",

View File

@@ -128,6 +128,7 @@
"lang_layout_mediafil": "メディアフィルター",
"lang_layout_linkana": "リンク解析",
"lang_layout_linkanades": "リンクの解析を切り替え",
"lang_layout_remoteOnly": "リモートのみ",
"lang_layout_tts": "読み上げ",
"lang_layout_reconnect": "カラム再読込",
"lang_layout_headercolor": "TLヘッダーカラー",

View File

@@ -165,6 +165,7 @@
"linkwarn": "APIの性質上thedesk.topへもアクセスするけどしゃーない。",
"connect": "接続",
"disconnect": "切断",
"lastFmWarn": "ユーザー名を入れてや。空白にすると消すで。last.fmの「最近のリスニング情報を表示しない」にチェックを入れんといてな。",
"templateedit": "テンプレートの編集",
"templateeditwarn": "以下を編集してテンプレートを変更できんで。",
"template1": "Spotify:{song}:曲名/{album}:アルバム名/{artist}:アーティスト名/{url}:各曲のSpotifyのURL",

View File

@@ -11,8 +11,6 @@
"cwDes":"コンテンツワーニング(トゥートを表示する前にメッセージで隠す)",
"selfile":"ファイルを選択",
"insertEmoji":"絵文字を挿入",
"NPSpotify":"NowPlaying(Spotify)",
"NPiTunes":"NowPlaying(macOS)",
"schedule":"時間指定投稿",
"postat":"時間指定投稿",
"scheduleWarn":"2.7.0~ 5分以内には投稿できません。サーバーの時計が正確とは限りません。",
@@ -77,6 +75,7 @@
"toots":"トゥート",
"follow":"フォロー",
"follower":"フォロワー",
"utlColumn":"カラムとして追加",
"timeline":"タイムライン",
"operateOtherAcct":"他のアカウントで操作",
"list":"リスト",

View File

@@ -127,6 +127,7 @@
"lang_layout_thisacct": "このアカウントの{{notf}}",
"lang_layout_delthis": "このカラムを削除",
"lang_layout_setthis": "このカラムの設定",
"lang_layout_remoteOnly": "リモートのみ",
"lang_layout_mediafil": "メディアフィルター",
"lang_layout_linkana": "リンク解析",
"lang_layout_linkanades": "リンクの解析を切り替え",

View File

@@ -167,6 +167,7 @@
"linkwarn": "APIの性質上thedesk.topへアクセスします。",
"connect": "接続",
"disconnect": "切断",
"lastFmWarn": "ユーザー名を入れてください。空白にすると解除されます。last.fmの「最近のリスニング情報を表示しない」にチェックを入れないでください。",
"templateedit": "テンプレートの編集",
"templateeditwarn": "以下を編集してテンプレートを変更できます。",
"template1": "Spotify:{song}:曲名/{album}:アルバム名/{artist}:アーティスト名/{url}:各曲のSpotifyのURL",

View File

@@ -147,9 +147,11 @@ function main(ver, basefile, pwa) {
source = source.replace(/@@pwa@@/g, `<link rel="manifest" href="/manifest.json" />
<script>var pwa = true;"serviceWorker"in navigator&&navigator.serviceWorker.register("/sw.pwa.js").then(e=>{});</script>`)
source = source.replace(/@@node_base@@/g, 'dependencies')
source = source.replace(/@@pwaClass@@/g, 'pwaView')
} else {
source = source.replace(/@@pwa@@/g, '<script>var pwa = false;</script>')
source = source.replace(/@@node_base@@/g, 'node_modules')
source = source.replace(/@@pwaClass@@/g, '')
}
fs.writeFileSync(basefile + 'view/' + lang + '/' + pages[i], source)
}

View File

@@ -32,7 +32,7 @@
@@pwa@@
</head>
<body id="mainView" style="overflow-y:scroll">
<body id="mainView" style="overflow-y:scroll" class="@@pwaClass@@">
<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>
@@ -388,7 +388,7 @@
<i class="fab fa-spotify"></i>@@spotify@@
</div>
<div class="collapsible-body">
<h5>@@link@@</h5>
<h5>@@link@@(Spotify)</h5>
@@linkwarn@@<br>
<div id="spotify-code-show" class="hide"><input type="text" id="spotify-code"><button
onclick="spotifyAuth()" class="btn waves-effect" style="width:100px;">@@set@@</button></div>
@@ -398,13 +398,16 @@
<a onclick="spotifyDisconnect()" class="btn waves-effect nex disabled"
style="width:100%; max-width:200px; background-color:#1ed760;" id="spotify-disable"><i
class="fab fa-spotify left"></i>@@disconnect@@</a>
<h5>@@link@@(Last.fm)</h5>
@@lastFmWarn@@<br />
<input type="text" style="width:150px" id="lastFmUser">
<button onclick="lastFmSet()" class="btn waves-effect" style="width:100px;">@@set@@</button>
<h5>@@templateedit@@</h5>
@@templateeditwarn@@<br>
<textarea id="np-temp" class="materialize-textarea" data-length="500">#NowPlaying {song} / {album} / {artist}
{url}</textarea><br>
@@template1@@<br>
@@template2@@<br>
@@template3@@<br>
<span class="mac">>@@template2@@</span><br>
<button onclick="spotifySave()" class="btn waves-effect" style="width:100px;">@@set@@</button>
<h5>@@postartwork@@</h5>
<label>
@@ -417,19 +420,21 @@
value="no" />
<span>@@no@@</span>
</label>
<h5>@@searchArtwork@@</h5>
@@searchArtworkWarn@@<br />
<label>
<input class="with-gap" onchange="aMusicFlagSave()" name="amw" type="radio" id="amw_yes"
value="yes" />
<span>@@yes@@</span>
</label>
<label>
<input class="with-gap" onchange="aMusicFlagSave()" name="amw" type="radio" id="amw_no"
value="no" />
<span>@@no@@</span>
</label>
<br>
<div class="mac">
<h5>@@searchArtwork@@</h5>
@@searchArtworkWarn@@<br />
<label>
<input class="with-gap" onchange="aMusicFlagSave()" name="amw" type="radio" id="amw_yes"
value="yes" />
<span>@@yes@@</span>
</label>
<label>
<input class="with-gap" onchange="aMusicFlagSave()" name="amw" type="radio" id="amw_no"
value="no" />
<span>@@no@@</span>
</label>
<br>
</div>
</div>
</li>
<li>
@@ -502,11 +507,6 @@
以下Markdownに対応したインスタンスのみ。
<br>
<li>Ctrl+B/I/S/U:太字/斜字/取り消し/下線</li>
以下アスタルテにログインしている場合のみ
<br>
<li>Ctrl+R:
<a href="https://astarte.thedesk.top">アスタルテ暇人ランキング</a>を開く
</li><br>
@@whenSelected@@
<li>F:@@fav@@</li>
<li>B:@@bt@@</li>
@@ -515,7 +515,7 @@
<button class="btn waves-effect red" style="width:100%; max-width:500px;"
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" onclick="about()" style="width:100%; max-width:500px;"><i
<button class="btn waves-effect indigo pwa" onclick="about()" style="width:100%; max-width:500px;"><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:500px;"><i
class="material-icons left">web</i>@@hp@@</a>
@@ -535,7 +535,7 @@
style="padding-top:5px;">Main author: Cutls@cutls.com</a>
<br>
TheDesk @ <a href="https://github.com/cutls/TheDesk/commits/@@gitHash@@">@@gitHash@@</a> - <a onclick="checkupd(); return localStorage.removeItem('new-ver-skip'); location.href='index.html';"
class="pointer">@@checkup@@</a><br>
class="pointer pwa">@@checkup@@</a><br>
<br>
Kyash<br>
<img src="../../img/kyash.png" width="100"><br>