From 37f49588ef97c02c00b10030ceeda9df184deaad Mon Sep 17 00:00:00 2001 From: maliktunga Date: Wed, 4 Nov 2015 19:25:01 -0500 Subject: [PATCH 01/10] Ido Revision More extensive use of metaphors to describe actions and concepts. A few tweaks. --- locale/io.json | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/locale/io.json b/locale/io.json index 6ac715e..ea771a6 100644 --- a/locale/io.json +++ b/locale/io.json @@ -8,7 +8,7 @@ "loginForgotPassword": "Ka vu obliviis vua pas-vorto?", "notices": "Mesaji", "followers": "Sequanti", - "following": "Sequante", + "following": "Sequanta", "groups": "Grupi", "compose": "Kompozez nova mesajo…", "queetVerb": "Sendar", @@ -66,9 +66,9 @@ "shortDateFormatDate": "{day} {month}", "shortDateFormatDateAndY": "{day} {month} {year}", "now": "nun", - "posting": "publikigante", - "viewMoreInConvBefore": "← Vidar plue dil konverso", - "viewMoreInConvAfter": "Vidar plue dil konverso →", + "posting": "publikiganta", + "viewMoreInConvBefore": "← Vidar plu multe dil konverso", + "viewMoreInConvAfter": "Vidar plu multe dil konverso →", "mentions": "Mencioni", "timeline": "Tempolineo", "publicTimeline": "Che {site-title}", @@ -80,7 +80,7 @@ "userExternalFollow": "Sequar", "userExternalFollowHelp": "L'identifikilo di vua konto (ex. uzero@quitter.no)", "userFollow": "Sequar", - "userFollowing": "Sequante", + "userFollowing": "Sequanta", "userUnfollow": "Cesar sequar", "joinGroup": "Membreskar", "joinExternalGroup": "Membreskar", @@ -98,14 +98,14 @@ "signUpEmail": "E-adreso", "signUpButtonText": "Registragar me che {site-title}", "welcomeHeading": "Bonvenez che {site-title}!", - "welcomeText": "Ni esas
\"Federo\" signifikas, ke konto che {site-title} esas fakultativa por sequar, esar sequata da, od interagar kun uzeri di {site-title}. Vu povas registragar vu en servilo di GNU Social od en irga servado fondita sur la protokolo OStatus! Vu ne mem mustas juntar vu a servado: probez instalar l'aminda programo GNU Social ye vua propra servilo! :)
federo
de mikroblogeri qui sucias etiko e solidareso, e qui deziras abandonar la centraligita e kapitalista servadi.", + "welcomeText": "Ni esas
\"Federo\" signifikas, ke konto che {site-title} esas fakultativa por sequar, esar sequata da, od interagar kun uzeri di {site-title}. Vu povas registragar vu en servilo di GNU Social od en irga servado fondita sur la protokolo OStatus! Vu ne mem mustas juntar vu a servado: probez instalar l'aminda programo GNU Social en vua propra servilo! :)
federo
de mikroblogeri qui sucias etiko e solidareso, e qui deziras abandonar la centraligita e kapitalista servadi.", "registerNickname": "Uzer-nomo", "registerHomepage": "Frontispico", "registerBio": "Biografio", "registerLocation": "Loko", "registerRepeatPassword": "Repetez la pas-vorto", "moreSettings": "Plusa ajusti", - "otherServers": "Altre vu povas krear konto ye altra servilo di la reto GNU Social. Komparar", + "otherServers": "Altre vu povas krear konto en altra servilo di la reto GNU Social. Komparar", "editMyProfile": "Modifikar mea profilo", "notifications": "Avizi", "xFavedYourQueet": "favoras vua mesajo", @@ -121,10 +121,10 @@ "blockUser": "Blokusar {username}", "goToOriginalNotice": "Irar al originala mesajo", "goToTheUsersRemoteProfile": "Irar al profilo di la uzero", - "clickToDrag":"Klikez por tranar la imajo", - "keyboardShortcuts":"Agi per klavaro", + "clickToDrag":"Kliktigez por tranar", + "keyboardShortcuts":"Agi klavarala", "classicInterface":"Klasika {site-title}", - "accessibilityToggleLink":"Por plu bona acesebleso, klikez ica ligilo por enswichar la klasika uzer-interfacio.", + "accessibilityToggleLink":"Por plu bona acesebleso, kliktigez sur ica ligilo por enswichar la klasika uzer-interfacio.", "tooltipBookmarkStream":"Adjuntar ica disktuto-fluo a vua marko-rubandi", "tooltipTopMenu":"Menuo ed ajusti", "tooltipAttachImage":"Atachar imajo", From 132d0d8966e4e2953c25c5479375296505a02b01 Mon Sep 17 00:00:00 2001 From: maliktunga Date: Fri, 6 Nov 2015 13:38:59 -0500 Subject: [PATCH 02/10] =?UTF-8?q?=C2=ABSequanta=C2=BB=20divenas=20=C2=ABSe?= =?UTF-8?q?quati=C2=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- locale/io.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/locale/io.json b/locale/io.json index ea771a6..79e2ac6 100644 --- a/locale/io.json +++ b/locale/io.json @@ -8,7 +8,7 @@ "loginForgotPassword": "Ka vu obliviis vua pas-vorto?", "notices": "Mesaji", "followers": "Sequanti", - "following": "Sequanta", + "following": "Sequati", "groups": "Grupi", "compose": "Kompozez nova mesajo…", "queetVerb": "Sendar", From b85621c76a7068a114dd5306c6e4a7414387033f Mon Sep 17 00:00:00 2001 From: Hannes Mannerheim Date: Mon, 16 Nov 2015 15:42:53 +0100 Subject: [PATCH 03/10] fix --- actions/qvitter.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/actions/qvitter.php b/actions/qvitter.php index 6f9c3b1..5b93b09 100644 --- a/actions/qvitter.php +++ b/actions/qvitter.php @@ -350,7 +350,7 @@ class QvitterAction extends ApiAction if($logged_in_user) { ?> -
+
-
-
-
+
+
+
  • From 111f57a269cffe789ca211ae5caa0bb5d0dcd1c5 Mon Sep 17 00:00:00 2001 From: Hannes Mannerheim Date: Mon, 16 Nov 2015 16:09:01 +0100 Subject: [PATCH 04/10] browser detection library and no basicauth popup hack in microsoft browsers --- actions/qvitter.php | 9 ++------- js/lib/bowser.min.js | 6 ++++++ js/qvitter.js | 6 ++++++ 3 files changed, 14 insertions(+), 7 deletions(-) create mode 100644 js/lib/bowser.min.js diff --git a/actions/qvitter.php b/actions/qvitter.php index 5b93b09..21f0c0f 100644 --- a/actions/qvitter.php +++ b/actions/qvitter.php @@ -224,15 +224,9 @@ class QvitterAction extends ApiAction window.timeBetweenPolling = ; window.apiRoot = js/lib/load-image.min.js?changed="> + diff --git a/js/lib/bowser.min.js b/js/lib/bowser.min.js new file mode 100644 index 0000000..66a3cdf --- /dev/null +++ b/js/lib/bowser.min.js @@ -0,0 +1,6 @@ +/*! + * Bowser - a browser detector + * https://github.com/ded/bowser + * MIT License | (c) Dustin Diaz 2015 + */ +!function(e,t){typeof module!="undefined"&&module.exports?module.exports=t():typeof define=="function"&&define.amd?define(t):this[e]=t()}("bowser",function(){function t(t){function n(e){var n=t.match(e);return n&&n.length>1&&n[1]||""}function r(e){var n=t.match(e);return n&&n.length>1&&n[2]||""}var i=n(/(ipod|iphone|ipad)/i).toLowerCase(),s=/like android/i.test(t),o=!s&&/android/i.test(t),u=/CrOS/.test(t),a=n(/edge\/(\d+(\.\d+)?)/i),f=n(/version\/(\d+(\.\d+)?)/i),l=/tablet/i.test(t),c=!l&&/[^-]mobi/i.test(t),h;/opera|opr/i.test(t)?h={name:"Opera",opera:e,version:f||n(/(?:opera|opr)[\s\/](\d+(\.\d+)?)/i)}:/yabrowser/i.test(t)?h={name:"Yandex Browser",yandexbrowser:e,version:f||n(/(?:yabrowser)[\s\/](\d+(\.\d+)?)/i)}:/windows phone/i.test(t)?(h={name:"Windows Phone",windowsphone:e},a?(h.msedge=e,h.version=a):(h.msie=e,h.version=n(/iemobile\/(\d+(\.\d+)?)/i))):/msie|trident/i.test(t)?h={name:"Internet Explorer",msie:e,version:n(/(?:msie |rv:)(\d+(\.\d+)?)/i)}:u?h={name:"Chrome",chromeBook:e,chrome:e,version:n(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)}:/chrome.+? edge/i.test(t)?h={name:"Microsoft Edge",msedge:e,version:a}:/chrome|crios|crmo/i.test(t)?h={name:"Chrome",chrome:e,version:n(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)}:i?(h={name:i=="iphone"?"iPhone":i=="ipad"?"iPad":"iPod"},f&&(h.version=f)):/sailfish/i.test(t)?h={name:"Sailfish",sailfish:e,version:n(/sailfish\s?browser\/(\d+(\.\d+)?)/i)}:/seamonkey\//i.test(t)?h={name:"SeaMonkey",seamonkey:e,version:n(/seamonkey\/(\d+(\.\d+)?)/i)}:/firefox|iceweasel/i.test(t)?(h={name:"Firefox",firefox:e,version:n(/(?:firefox|iceweasel)[ \/](\d+(\.\d+)?)/i)},/\((mobile|tablet);[^\)]*rv:[\d\.]+\)/i.test(t)&&(h.firefoxos=e)):/silk/i.test(t)?h={name:"Amazon Silk",silk:e,version:n(/silk\/(\d+(\.\d+)?)/i)}:o?h={name:"Android",version:f}:/phantom/i.test(t)?h={name:"PhantomJS",phantom:e,version:n(/phantomjs\/(\d+(\.\d+)?)/i)}:/blackberry|\bbb\d+/i.test(t)||/rim\stablet/i.test(t)?h={name:"BlackBerry",blackberry:e,version:f||n(/blackberry[\d]+\/(\d+(\.\d+)?)/i)}:/(web|hpw)os/i.test(t)?(h={name:"WebOS",webos:e,version:f||n(/w(?:eb)?osbrowser\/(\d+(\.\d+)?)/i)},/touchpad\//i.test(t)&&(h.touchpad=e)):/bada/i.test(t)?h={name:"Bada",bada:e,version:n(/dolfin\/(\d+(\.\d+)?)/i)}:/tizen/i.test(t)?h={name:"Tizen",tizen:e,version:n(/(?:tizen\s?)?browser\/(\d+(\.\d+)?)/i)||f}:/safari/i.test(t)?h={name:"Safari",safari:e,version:f}:h={name:n(/^(.*)\/(.*) /),version:r(/^(.*)\/(.*) /)},!h.msedge&&/(apple)?webkit/i.test(t)?(h.name=h.name||"Webkit",h.webkit=e,!h.version&&f&&(h.version=f)):!h.opera&&/gecko\//i.test(t)&&(h.name=h.name||"Gecko",h.gecko=e,h.version=h.version||n(/gecko\/(\d+(\.\d+)?)/i)),!h.msedge&&(o||h.silk)?h.android=e:i&&(h[i]=e,h.ios=e);var p="";h.windowsphone?p=n(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i):i?(p=n(/os (\d+([_\s]\d+)*) like mac os x/i),p=p.replace(/[_\s]/g,".")):o?p=n(/android[ \/-](\d+(\.\d+)*)/i):h.webos?p=n(/(?:web|hpw)os\/(\d+(\.\d+)*)/i):h.blackberry?p=n(/rim\stablet\sos\s(\d+(\.\d+)*)/i):h.bada?p=n(/bada\/(\d+(\.\d+)*)/i):h.tizen&&(p=n(/tizen[\/\s](\d+(\.\d+)*)/i)),p&&(h.osversion=p);var d=p.split(".")[0];if(l||i=="ipad"||o&&(d==3||d==4&&!c)||h.silk)h.tablet=e;else if(c||i=="iphone"||i=="ipod"||o||h.blackberry||h.webos||h.bada)h.mobile=e;return h.msedge||h.msie&&h.version>=10||h.yandexbrowser&&h.version>=15||h.chrome&&h.version>=20||h.firefox&&h.version>=20||h.safari&&h.version>=6||h.opera&&h.version>=10||h.ios&&h.osversion&&h.osversion.split(".")[0]>=6||h.blackberry&&h.version>=10.1?h.a=e:h.msie&&h.version<10||h.chrome&&h.version<20||h.firefox&&h.version<20||h.safari&&h.version<6||h.opera&&h.version<10||h.ios&&h.osversion&&h.osversion.split(".")[0]<6?h.c=e:h.x=e,h}var e=!0,n=t(typeof navigator!="undefined"?navigator.userAgent:"");return n.test=function(e){for(var t=0;t Date: Mon, 16 Nov 2015 16:37:47 +0100 Subject: [PATCH 05/10] error reporting for status code 0 --- js/dom-functions.js | 3 +++ locale/ar.json | 3 ++- locale/ast.json | 3 ++- locale/ca.json | 3 ++- locale/de.json | 3 ++- locale/en.json | 3 ++- locale/eo.json | 3 ++- locale/es.json | 3 ++- locale/es_ahorita.json | 3 ++- locale/eu.json | 3 ++- locale/fa.json | 3 ++- locale/fi.json | 3 ++- locale/fr.json | 3 ++- locale/gl.json | 3 ++- locale/he.json | 3 ++- locale/io.json | 3 ++- locale/it.json | 3 ++- locale/no.json | 3 ++- locale/pt_br.json | 3 ++- locale/sv.json | 3 ++- locale/zh_cn.json | 3 ++- locale/zh_tw.json | 3 ++- 22 files changed, 45 insertions(+), 21 deletions(-) diff --git a/js/dom-functions.js b/js/dom-functions.js index 0343bdb..25bf4ea 100644 --- a/js/dom-functions.js +++ b/js/dom-functions.js @@ -678,6 +678,9 @@ function setNewCurrentStream(streamObject,setLocation,fallbackId,actionOnSuccess else if(error.status == 410 && streamObject.name == 'notice') { showErrorMessage(window.sL.ERRORnoticeRemoved); } + else if(error.status == 0) { + showErrorMessage(window.sL.ERRORnoContactWithServer + ' (' + replaceHtmlSpecialChars(error.statusText) + ')'); + } else { showErrorMessage(window.sL.ERRORsomethingWentWrong + '

    \ url: ' + url + '

    \ diff --git a/locale/ar.json b/locale/ar.json index a9ccb29..7813f1a 100644 --- a/locale/ar.json +++ b/locale/ar.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/ast.json b/locale/ast.json index 5e74903..06fefa1 100644 --- a/locale/ast.json +++ b/locale/ast.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/ca.json b/locale/ca.json index 014335d..2cb7297 100644 --- a/locale/ca.json +++ b/locale/ca.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"No s'ha pogut trobar l'usuari amb el sobrenom \"{nickname}\" en aquest servidor", "ERRORcouldNotFindGroupWithNickname":"No s'ha pogut trobar el grup amb el nom \"{nickname}\" en aquest servidor", "ERRORcouldNotFindPage":"No s'ha pogut trobar aquesta pàgina", - "ERRORnoticeRemoved": "Aquest avís s'ha eliminat." + "ERRORnoticeRemoved": "Aquest avís s'ha eliminat.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/de.json b/locale/de.json index 2243dd5..d05723f 100644 --- a/locale/de.json +++ b/locale/de.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Konnte Nutzer mit Name \"{nickname}\" nicht finden", "ERRORcouldNotFindGroupWithNickname":"Konnte Gruppe mit Bezeichnung \"{nickname}\" nicht finden", "ERRORcouldNotFindPage":"Konnte Seite nicht finden.", - "ERRORnoticeRemoved": "Dieser Queet wurde gelöscht." + "ERRORnoticeRemoved": "Dieser Queet wurde gelöscht.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/en.json b/locale/en.json index 9aff8bb..bfed28e 100644 --- a/locale/en.json +++ b/locale/en.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/eo.json b/locale/eo.json index 02730f2..6d2d806 100644 --- a/locale/eo.json +++ b/locale/eo.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/es.json b/locale/es.json index 0572ff2..def6fc9 100644 --- a/locale/es.json +++ b/locale/es.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"No se ha encontrado el usuario con el apodo \"{nickname}\" en este servidor", "ERRORcouldNotFindGroupWithNickname":"No se ha encontrado el grupo con el nombre \"{nickname}\" en este servidor", "ERRORcouldNotFindPage":"No se pudo encontrar la página.", - "ERRORnoticeRemoved": "Este aviso se ha eliminado." + "ERRORnoticeRemoved": "Este aviso se ha eliminado.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/es_ahorita.json b/locale/es_ahorita.json index fc45a3a..a08f214 100644 --- a/locale/es_ahorita.json +++ b/locale/es_ahorita.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/eu.json b/locale/eu.json index 9f186a9..16ce331 100644 --- a/locale/eu.json +++ b/locale/eu.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/fa.json b/locale/fa.json index 3dc2c0b..8f037d9 100644 --- a/locale/fa.json +++ b/locale/fa.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/fi.json b/locale/fi.json index 587aa6d..18427da 100644 --- a/locale/fi.json +++ b/locale/fi.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/fr.json b/locale/fr.json index 1c703e1..ab9520b 100644 --- a/locale/fr.json +++ b/locale/fr.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/gl.json b/locale/gl.json index 7651a6e..2aabebd 100644 --- a/locale/gl.json +++ b/locale/gl.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/he.json b/locale/he.json index 485042d..e3baadb 100644 --- a/locale/he.json +++ b/locale/he.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/io.json b/locale/io.json index 79e2ac6..48b58e7 100644 --- a/locale/io.json +++ b/locale/io.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"On ne trovis uzero kun la nomo \"{nickname}\" en ica servilo.", "ERRORcouldNotFindGroupWithNickname":"On ne trovis grupo kun la nomo \"{nickname}\" en ica servilo.", "ERRORcouldNotFindPage":"On ne trovis ica pagino.", - "ERRORnoticeRemoved": "Ica mesajo esas supresita." + "ERRORnoticeRemoved": "Ica mesajo esas supresita.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/it.json b/locale/it.json index 535faf4..f35511b 100644 --- a/locale/it.json +++ b/locale/it.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/no.json b/locale/no.json index 198b227..ca4fd85 100644 --- a/locale/no.json +++ b/locale/no.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Kan ikke finne en bruker med brukerid \"{nickname}\" på denne instansen", "ERRORcouldNotFindGroupWithNickname":"Kan ikke finne en gruppe med gruppenavnet \"{nickname}\" på denne instansen", "ERRORcouldNotFindPage":"Kan ikke finne siden.", - "ERRORnoticeRemoved": "Denne notisen er slettet." + "ERRORnoticeRemoved": "Denne notisen er slettet.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/pt_br.json b/locale/pt_br.json index 277b4e6..7ef346f 100644 --- a/locale/pt_br.json +++ b/locale/pt_br.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/sv.json b/locale/sv.json index 025de51..7b9e939 100644 --- a/locale/sv.json +++ b/locale/sv.json @@ -137,5 +137,6 @@ "ERRORcouldNotFindUserWithNickname":"Det finns ingen användare med namet \"{nickname}\" på den här servern.", "ERRORcouldNotFindGroupWithNickname":"Det finns ingen grupp med namnet \"{nickname}\" på den här servern.", "ERRORcouldNotFindPage":"Sidan hittades inte.", - "ERRORnoticeRemoved": "Den här qvittringen är borttagen." + "ERRORnoticeRemoved": "Den här qvittringen är borttagen.", + "ERRORnoContactWithServer": "Kan inte ansluta till servern. Servern kanske är överbelastad, eller så har du ett problem med din internetuppkoppling. Försök igen senare!" } diff --git a/locale/zh_cn.json b/locale/zh_cn.json index c3721ab..ff0067b 100644 --- a/locale/zh_cn.json +++ b/locale/zh_cn.json @@ -136,5 +136,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } diff --git a/locale/zh_tw.json b/locale/zh_tw.json index 843df04..93a6dca 100644 --- a/locale/zh_tw.json +++ b/locale/zh_tw.json @@ -136,5 +136,6 @@ "ERRORcouldNotFindUserWithNickname":"Could not find a user with nickname \"{nickname}\" on this server", "ERRORcouldNotFindGroupWithNickname":"Could not find a group with nickname \"{nickname}\" on this server", "ERRORcouldNotFindPage":"Could not find that page.", - "ERRORnoticeRemoved": "This notice has been removed." + "ERRORnoticeRemoved": "This notice has been removed.", + "ERRORnoContactWithServer": "Can not establish a connection to the server. The server could be overloaded, or there might be a problem with your internet connecton. Please try again later!" } From 819504224b35403765e7fdb9602fa7c033001513 Mon Sep 17 00:00:00 2001 From: Hannes Mannerheim Date: Mon, 16 Nov 2015 16:54:54 +0100 Subject: [PATCH 06/10] enable javascript message --- actions/qvitter.php | 1 + css/qvitter.css | 9 +++++++++ 2 files changed, 10 insertions(+) diff --git a/actions/qvitter.php b/actions/qvitter.php index 21f0c0f..e831a6d 100644 --- a/actions/qvitter.php +++ b/actions/qvitter.php @@ -413,6 +413,7 @@ class QvitterAction extends ApiAction
+
Please enable javascript to use this site.
Date: Mon, 16 Nov 2015 17:13:26 +0100 Subject: [PATCH 07/10] fixes #283 --- js/dom-functions.js | 1 + js/qvitter.js | 4 +--- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/js/dom-functions.js b/js/dom-functions.js index 25bf4ea..9a19e25 100644 --- a/js/dom-functions.js +++ b/js/dom-functions.js @@ -727,6 +727,7 @@ function setNewCurrentStream(streamObject,setLocation,fallbackId,actionOnSuccess $('#new-queets-bar').parent().addClass('hidden'); document.title = window.siteTitle; // hide new queets bar if it's visible there addToFeed(queet_data, false,'visible'); // add stream items to feed element $('#feed').animate({opacity:'1'},150); // fade in + $('.reload-stream').show(); $('#feed-body').removeAttr('data-end-reached'); $('body').removeClass('loading-older');$('body').removeClass('loading-newer'); $('html,body').scrollTop(0); // scroll to top diff --git a/js/qvitter.js b/js/qvitter.js index fdc9f3c..4b610ab 100644 --- a/js/qvitter.js +++ b/js/qvitter.js @@ -2384,9 +2384,7 @@ $('body').on('click','button.shorten',function () { · · · · · · · · · · · · · */ $('body').on('click','.reload-stream',function () { $('.reload-stream').hide(); - setNewCurrentStream(URLtoStreamRouter(window.location.href),false,false,function(){ - $('.reload-stream').show(); - }); + setNewCurrentStream(URLtoStreamRouter(window.location.href),false,false,false); }); From 2ffe165d411ec25117dc6156fab8ebbdd3f46ed0 Mon Sep 17 00:00:00 2001 From: Hannes Mannerheim Date: Mon, 16 Nov 2015 17:40:04 +0100 Subject: [PATCH 08/10] honour start time hash in youtube videos #273, and make youtu.be links embed the video #270 --- js/dom-functions.js | 10 +++++----- js/misc-functions.js | 20 ++++++++++++++++++++ 2 files changed, 25 insertions(+), 5 deletions(-) diff --git a/js/dom-functions.js b/js/dom-functions.js index 9a19e25..1208baf 100644 --- a/js/dom-functions.js +++ b/js/dom-functions.js @@ -950,14 +950,14 @@ function expand_queet(q,doScrolling) { // if there's only one thumb and it's a youtube video, show it inline if(q.children('.queet').find('.queet-thumbs.thumb-num-1').children('.thumb-container.play-button.youtube').length == 1) { - var youtubeId = q.children('.queet').find('.queet-thumbs.thumb-num-1').children('.thumb-container.play-button.youtube').children('.attachment-thumb').attr('data-full-image-url').replace('http://www.youtube.com/watch?v=','').replace('https://www.youtube.com/watch?v=','').replace('http://youtu.be/','').replace('https://youtu.be/','').substr(0,11); - if(q.children('.queet').find('.expanded-content').children('.media').children('iframe[src="//www.youtube.com/embed/' + youtubeId + '"]').length < 1) { // not if already showed + var youtubeURL = q.children('.queet').find('.queet-thumbs.thumb-num-1').children('.thumb-container.play-button.youtube').children('.attachment-thumb').attr('data-full-image-url'); + if(q.children('.queet').find('.expanded-content').children('.media').children('iframe[src="' + youTubeEmbedLinkFromURL(youtubeURL) + '"]').length < 1) { // not if already showed // hide video thumbnail if it's the only one if(q.children('.queet').find('.queet-thumbs').children('.thumb-container').length < 2) { q.children('.queet').find('.queet-thumbs').addClass('hide-thumbs'); } // show video - q.children('.queet').find('.expanded-content').prepend('
'); + q.children('.queet').find('.expanded-content').prepend('
'); } } @@ -1841,14 +1841,14 @@ function buildQueetHtml(obj, idInStream, extraClassesThisRun, requeeted_by, isCo // play button for videos and animated gifs var playButtonClass = ''; - if(this.url.indexOf('://www.youtube.com') > -1 + if((this.url.indexOf('://www.youtube.com') > -1 || this.url.indexOf('://youtu.be') > -1) || (typeof this.animated != 'undefined' && this.animated === true)) { var playButtonClass = ' play-button'; } // youtube class var youTubeClass = ''; - if(this.url.indexOf('://www.youtube.com') > -1) { + if(this.url.indexOf('://www.youtube.com') > -1 || this.url.indexOf('://youtu.be') > -1) { youTubeClass = ' youtube'; } diff --git a/js/misc-functions.js b/js/misc-functions.js index 4044812..285b8c7 100644 --- a/js/misc-functions.js +++ b/js/misc-functions.js @@ -1645,3 +1645,23 @@ function theUserOrGroupThisStreamBelongsTo(stream) { return stream; } } + +/* · + · + · Youtube embed link from youtube url + · + · · · · · · · · · · · · · */ + +function youTubeEmbedLinkFromURL(url) { + var youtubeId = url.replace('http://www.youtube.com/watch?v=','').replace('https://www.youtube.com/watch?v=','').replace('http://youtu.be/','').replace('https://youtu.be/','').substr(0,11); + + // get start time hash + var l = document.createElement("a"); + l.href = url; + if(l.hash.substring(0,3) == '#t=') { + return '//www.youtube.com/embed/' + youtubeId + '?start=' + l.hash.substring(3); + } + else { + return '//www.youtube.com/embed/' + youtubeId; + } + } From 8a76a28a66eff76c7e982a6cb7411701d3a3cffe Mon Sep 17 00:00:00 2001 From: Hannes Mannerheim Date: Mon, 16 Nov 2015 18:13:48 +0100 Subject: [PATCH 09/10] handle conversation links, fixes #269 --- QvitterPlugin.php | 4 ++++ js/dom-functions.js | 2 +- js/stream-router.js | 27 ++++++++++++++++++++++----- 3 files changed, 27 insertions(+), 6 deletions(-) diff --git a/QvitterPlugin.php b/QvitterPlugin.php index d348ab0..face439 100644 --- a/QvitterPlugin.php +++ b/QvitterPlugin.php @@ -282,6 +282,10 @@ class QvitterPlugin extends Plugin { array('action' => 'shownotice'), array('notice' => '[0-9]+'), 'qvitter'); + URLMapperOverwrite::overwrite_variable($m, 'conversation/:id', + array('action' => 'conversation'), + array('id' => '[0-9]+'), + 'qvitter'); } // if qvitter is opt-out, disable the default register page (if we don't have a valid invitation code) diff --git a/js/dom-functions.js b/js/dom-functions.js index 1208baf..1d440a6 100644 --- a/js/dom-functions.js +++ b/js/dom-functions.js @@ -567,6 +567,7 @@ function setNewCurrentStream(streamObject,setLocation,fallbackId,actionOnSuccess $('#feed').show(); $('#feed-body').removeAttr('data-end-reached'); $('#feed-header-inner h2').css('opacity','0.2'); + $('#feed-header-inner h2').html(h2FeedHeader); // update header (could be wrong in cache) $('#feed-header-inner h2').animate({opacity:'1'},1000); // set location bar from stream @@ -723,7 +724,6 @@ function setNewCurrentStream(streamObject,setLocation,fallbackId,actionOnSuccess remove_spinner(); $('#feed-body').html(''); // empty feed body - $('#feed-header-inner h2').html(h2FeedHeader); // update header (could be wrong in cache) $('#new-queets-bar').parent().addClass('hidden'); document.title = window.siteTitle; // hide new queets bar if it's visible there addToFeed(queet_data, false,'visible'); // add stream items to feed element $('#feed').animate({opacity:'1'},150); // fade in diff --git a/js/stream-router.js b/js/stream-router.js index 1e148c6..8cbf724 100644 --- a/js/stream-router.js +++ b/js/stream-router.js @@ -74,11 +74,6 @@ function URLtoStreamRouter(url) { // we don't expect protocol to matter url = removeProtocolFromUrl(url); - // remove anchor tags - if(url.indexOf('#')>-1) { - url = url.substring(0,url.indexOf('#')); - } - // not a local URL if(url != window.siteRootDomain && url.indexOf(window.siteRootDomain + '/') != 0) { // console.log('not a local url: ' + url); @@ -102,6 +97,13 @@ function URLtoStreamRouter(url) { function pathToStreamRouter(path) { + // remove and remember anchor tags + var anchor = false; + if(path.indexOf('#')>-1) { + anchor = path.substring(path.indexOf('#')); + path = path.substring(0,path.indexOf('#')); + } + // remove starting slash if(path.indexOf('/') == 0) { path = path.substring(1); @@ -201,6 +203,21 @@ function pathToStreamRouter(path) { return streamObject; } + // conversation/{id} + if(pathSplit.length == 2 && pathSplit[0] == 'conversation' && /^[0-9]+$/.test(pathSplit[1])) { + streamObject.name = 'notice'; + streamObject.id = pathSplit[1]; + // conversation links are redirected to notice page, if the link is to a + // non root notice, then the notice we want to link to and expand is in the hash + if(anchor && anchor.indexOf('#notice-') == 0) { + streamObject.id = anchor.substring(8); + } + streamObject.path = 'notice/' + streamObject.id; + streamObject.streamHeader = replaceHtmlSpecialChars(streamObject.path); + streamObject.stream = 'statuses/show/' + streamObject.id + '.json'; + return streamObject; + } + // user/{id} if(pathSplit.length == 2 && pathSplit[0] == 'user' && /^[0-9]+$/.test(pathSplit[1])) { streamObject.name = 'profile by id'; From 789c397ddc420c0ebda1bac94491d3e0351c4e83 Mon Sep 17 00:00:00 2001 From: Hannes Mannerheim Date: Mon, 16 Nov 2015 18:24:34 +0100 Subject: [PATCH 10/10] fixes #278 --- js/qvitter.js | 1 + 1 file changed, 1 insertion(+) diff --git a/js/qvitter.js b/js/qvitter.js index 4b610ab..ec9818d 100644 --- a/js/qvitter.js +++ b/js/qvitter.js @@ -1310,6 +1310,7 @@ $('body').on('click','a', function(e) { e.preventDefault(); if($(this).closest('.modal-container').attr('id') != 'edit-profile-popup') { // no popup if we're editing our profile popUpAction('popup-profile-picture', $('.profile-card-inner .screen-name').html(),'',false); + $('.hover-card,.hover-card-caret').remove(); } } // hijack link if we find a matching link that qvitter can handle