diff --git a/.travis.yml b/.travis.yml
index c4a466f7..c8afd434 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,10 +1,28 @@
-os: windows
-language: node_js
-node_js:
-- '9.9.0'
-script: node -v
-before_deploy:
+language: objective-c
+cache:
+ directories:
+ - node_modules
+env:
+ - NODE_VERSION="9.9.0"
+before_install:
+ # nvm をインストールする。Travis の OS X 環境には nvm はデフォルトで入っていない
+ - git clone https://github.com/creationix/nvm.git /tmp/.nvm
+ - source /tmp/.nvm/nvm.sh
+ # 指定バージョンの Node をインストールする
+ - nvm install $NODE_VERSION
+ # 指定バージョンの Node を有効にする
+ - nvm use --delete-prefix $NODE_VERSION
+ - node --version
+install:
- cd app
+ - npm install
+script:
+ - npm test
+before_deploy:
+ - brew update
+ - brew install wine
+ - wine --version
+ - brew install makensis
- npm install electron-builder -g
- npm install
- electron-builder --win --ia32
@@ -13,18 +31,23 @@ before_deploy:
- electron-builder --win --x64
- mv ../build/TheDesk-setup.exe ../TheDesk-setup.exe
- mv ../build/TheDesk*.exe ../TheDesk.exe
- - cd ../
- - ls
-after_deploy: ls
+ - electron-builder --linux --x64
+ - mv ../build/TheDesk*.snap ../TheDesk.snap
+ - electron-builder --mac --x64
+ - mv ../build/TheDesk*.dmg ../TheDesk.dmg
deploy:
- skip_cleanup: true
provider: releases
+ # GitHub にリリースするための API KEY を暗号化した値
api_key:
secure: jndR02p5KRTtcJk18b3YsXL2cC+yzEf1AOqXdpWciF8f3lO5oY01jlxd17xdHIcK7VywSsLVZpLToSdqAoIEhJ5OxEQ/FmA3FlmbwwD6ou13gLa4VGIvsBHveCmKGjVu0Z++atIy76tZYU1SOWFWv4B0ZhnVz2ca2VZynvLgw3YNsPJH7rHO966GXgRkGYJAJ4UvLg3sj/iztVh2FSfbUj5IGO1e/JHJO63wAo1MSQtRjkutVgl/djnBLC6vbL4YHkM3Ynpkx/YQEcxwrmeY0Ra8D5yYDq4MNIDMmZahWC+k4u2eA2Cj2ifBFNxbZvTN75vLwRBp6DsTNHsiqkXrSPDBdNeet31RbwTQ6LtsK8jqmL4S/59dmLcj7uCU2WxyBLPbJdbdZWlqW2ZQvfQY8QVAYy7S3MiHQWQN0oP5wqXk89jcgR42ig/zsqFNPpXHM4mExR7l/gDLPg0j9c3XEF6sWtk3FmJN1i4+B+9kn09b6UKlV7EFPKp8XcFNrz4ZcE9/I8lKwsqLVG2jAXIk7Z9LwDRcAmK5eG348X5zwFtOY6raKIvRw2cn92bPnEI+55v8A4WANS2647GFTgxHj30D0d/sOZmJ5BS34zpdWTgE0AlKg7sOqkncjqoW5J5zCh5Ow7b3KXvEvlAts44mAag8tZTectxMP4iguXvTnv4=
- file:
+ # Releases ページにアップロードするファイル
+ file:
- TheDesk.exe
- TheDesk-setup.exe
- TheDesk-ia32.exe
- TheDesk-setup-ia32.exe
+ - TheDesk.snap
+ - TheDesk.dmg
+ skip_cleanup: true
on:
- repo: cutls/TheDesk
+ repo: cutls/TheDesk
\ No newline at end of file
diff --git a/README.md b/README.md
index f0edb664..e2905cb4 100644
--- a/README.md
+++ b/README.md
@@ -95,6 +95,14 @@ macOS
Config is all on package.json
ビルド設定はすべてpackage.jsonに記載しています。
+## Pleroma support
+
+Did you find a bug with Pleroma accounts?
+Pleroma **does not** follow Mastodon API rules completely although Pleroma developers say so.
+Please write issues to improve TheDesk affinity with Pleroma.
+Pleromaは、Mastodon APIとの互換性を謳っていますが、実際には様々な差異があり、TheDeskで不具合が発生することがあります。
+Issuesに書いてある問題についてはなるべく対処しますので、ぜひお知らせください。
+
## See also/詳しく
[TheDesk - マストドン日本語ウィキ](https://ja.mstdn.wiki/TheDesk)
diff --git a/app/js/platform/nano.js b/app/js/platform/nano.js
index 83385bfd..e960e293 100644
--- a/app/js/platform/nano.js
+++ b/app/js/platform/nano.js
@@ -29,16 +29,10 @@ function tl(data) {
var templete = parse([json[0]], '', acct_id, tlid);
$("#timeline_nano").html(templete);
jQuery("time.timeago").timeago();
- reload(type, '', acct_id, data);
});
-}
-
//Streaming接続
var websocket=[];
-function reload(type, cc, acct_id, data) {
var tlid=0;
- var domain = localStorage.getItem("domain_" + acct_id);
- var at = localStorage.getItem("acct_"+ acct_id + "_at");
if (type == "home") {
var start = "wss://" + domain +
"/api/v1/streaming/?stream=user&access_token=" + at;
diff --git a/app/js/post/status.js b/app/js/post/status.js
index c98c4c90..13860500 100644
--- a/app/js/post/status.js
+++ b/app/js/post/status.js
@@ -279,9 +279,11 @@ function redraft(id, acct_id){
show();
$("#textarea").val(html);
var cwtxt=$("[toot-id="+id+"] .cw_text").html();
- cwtxt=$.strip_tags(cwtxt);
- cw();
- $("#cw-text").val(cwtxt);
+ if(cwtxt!=""){
+ cwtxt=$.strip_tags(cwtxt);
+ cw();
+ $("#cw-text").val(cwtxt);
+ }
}
}
//ピン留め
diff --git a/app/js/tl/date.js b/app/js/tl/date.js
index 7eed1337..3ab4d752 100644
--- a/app/js/tl/date.js
+++ b/app/js/tl/date.js
@@ -56,14 +56,38 @@ function date(str, datetype) {
//特殊フォーマット(インスタンス情報で利用)
function crat(str) {
var date = new Date(str);
-
+ if(date.getMonth()<9){
+ var mnt="0"+(date.getMonth()+1);
+ }else{
+ var mnt=date.getMonth()+1;
+ }
+ if(date.getDate()<10){
+ var dat="0"+date.getDate();
+ }else{
+ var dat=date.getDate();
+ }
+ if(date.getHours()<10){
+ var hrs="0"+date.getHours();
+ }else{
+ var hrs=date.getHours();
+ }
+ if(date.getMinutes()<10){
+ var mns="0"+date.getMinutes();
+ }else{
+ var mns=date.getMinutes();
+ }
+ if(date.getSeconds()<10){
+ var sec="0"+date.getSeconds();
+ }else{
+ var sec=date.getSeconds();
+ }
format_str = 'YYYY-MM-DD hh:mm:ss';
format_str = format_str.replace(/YYYY/g, date.getFullYear());
- format_str = format_str.replace(/MM/g, date.getMonth()+1);
- format_str = format_str.replace(/DD/g, date.getDate());
- format_str = format_str.replace(/hh/g, date.getHours());
- format_str = format_str.replace(/mm/g, date.getMinutes());
- format_str = format_str.replace(/ss/g, date.getSeconds());
+ format_str = format_str.replace(/MM/g, mnt);
+ format_str = format_str.replace(/DD/g, dat);
+ format_str = format_str.replace(/hh/g, hrs);
+ format_str = format_str.replace(/mm/g, mns);
+ format_str = format_str.replace(/ss/g, sec);
return format_str;
}
diff --git a/app/js/tl/filter.js b/app/js/tl/filter.js
index dd9de540..63ddfe32 100644
--- a/app/js/tl/filter.js
+++ b/app/js/tl/filter.js
@@ -391,6 +391,9 @@ function exclude(key){
}
function excludeCk(key,target){
var exc=localStorage.getItem("exclude-"+key);
+ if(!exc){
+ return "";
+ }
if(~exc.indexOf(target)){
return "checked"
}else{
diff --git a/app/js/tl/parse.js b/app/js/tl/parse.js
index ccdf3929..eb6226e7 100644
--- a/app/js/tl/parse.js
+++ b/app/js/tl/parse.js
@@ -357,6 +357,7 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter) {
}
if (!toot.application) {
var via = '';
+ viashow="hide";
} else {
var via = toot.application.name;
//強調チェック
@@ -374,6 +375,9 @@ function parse(obj, mix, acct_id, tlid, popup, mutefilter) {
}
});
}
+ if(mix=="pinned"){
+ boostback = "emphasized";
+ }
if (toot.spoiler_text && cw) {
var content = toot.content;
var spoil = escapeHTML(toot.spoiler_text);
diff --git a/app/js/ui/layout.js b/app/js/ui/layout.js
index 1a632aaf..eb5eb0cc 100644
--- a/app/js/ui/layout.js
+++ b/app/js/ui/layout.js
@@ -149,7 +149,7 @@ function parseColumn() {
key + '">On'+lang.lang_layout_linkana +'
hearingOn'+lang.lang_layout_tts +'TL
low_priority'+lang.lang_layout_reconnect[lang]+'
'+lang.lang_layout_headercolor +'