From 4b94e9c65efd227c58f8be9b3db6b667d403ed3c Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Sat, 19 May 2018 14:46:47 +0200 Subject: Improve payload format of Web Push API now that it's open (#7521) > Good lord what is happening in there Previously the contents of the Web Push API payloads closely resembled the structure of JavaScript's [Notification](https://developer.mozilla.org/en-US/docs/Web/API/Notification). But now that the API is open to non-browser apps, and given that there is no required coupling between contents of the payload and a Notification object, here is how I changed the payload: ```json { "access_token": "...", "preferred_locale": "en", "notification_id": "12345", "notification_type": "follow", "title": "So and so followed you", "body": "This is my bio", "icon": "https://example.com/avatar.png" } ``` The title, body and icon attributes are included as a fallback so you can construct a minimal notification if you cannot perform a network request to the API to get more data. --- config/locales/ar.yml | 13 ------------- config/locales/ca.yml | 14 -------------- config/locales/co.yml | 14 -------------- config/locales/de.yml | 14 -------------- config/locales/en.yml | 14 -------------- config/locales/eo.yml | 14 -------------- config/locales/es.yml | 14 -------------- config/locales/fa.yml | 14 -------------- config/locales/fi.yml | 14 -------------- config/locales/fr.yml | 14 -------------- config/locales/gl.yml | 14 -------------- config/locales/hu.yml | 14 -------------- config/locales/it.yml | 12 ------------ config/locales/ja.yml | 14 -------------- config/locales/ko.yml | 14 -------------- config/locales/nl.yml | 14 -------------- config/locales/no.yml | 14 -------------- config/locales/oc.yml | 14 -------------- config/locales/pl.yml | 14 -------------- config/locales/pt-BR.yml | 14 -------------- config/locales/pt.yml | 14 -------------- config/locales/ru.yml | 14 -------------- config/locales/sk.yml | 14 -------------- config/locales/sr-Latn.yml | 14 -------------- config/locales/sr.yml | 14 -------------- config/locales/sv.yml | 14 -------------- config/locales/zh-CN.yml | 14 -------------- config/locales/zh-HK.yml | 14 -------------- 28 files changed, 389 deletions(-) (limited to 'config') diff --git a/config/locales/ar.yml b/config/locales/ar.yml index 194d91cb0..f187bd6ac 100644 --- a/config/locales/ar.yml +++ b/config/locales/ar.yml @@ -576,19 +576,6 @@ ar: other: إعدادات أخرى publishing: النشر web: الويب - push_notifications: - favourite: - title: أعجب %{name} بمنشورك - follow: - title: "%{name} من متتبعيك الآن" - group: - title: "%{count} إخطارات" - mention: - action_boost: ترقية - action_expand: عرض المزيد - title: أشار إليك %{name} - reblog: - title: قام %{name} بترقية منشورك remote_follow: acct: قم بإدخال عنوان حسابك username@domain الذي من خلاله تود المتابعة missing_resource: تعذر العثور على رابط التحويل المطلوب الخاص بحسابك diff --git a/config/locales/ca.yml b/config/locales/ca.yml index 97b52cfa5..4e051bc36 100644 --- a/config/locales/ca.yml +++ b/config/locales/ca.yml @@ -594,20 +594,6 @@ ca: other: Altre publishing: Publicació web: Web - push_notifications: - favourite: - title: "%{name} ha marcat com a preferit el teu estat" - follow: - title: "%{name} ara et segueix" - group: - title: "%{count} notificacions" - mention: - action_boost: Retooteja - action_expand: Mostra'n més - action_favourite: Preferit - title: "%{name} t'ha mencionat" - reblog: - title: "%{name} t'ha retootejat" remote_follow: acct: Escriu el teu usuari@domini des del qual vols seguir missing_resource: No s'ha pogut trobar la URL de redirecció necessaria per al compte diff --git a/config/locales/co.yml b/config/locales/co.yml index 637491d6b..32661b2c5 100644 --- a/config/locales/co.yml +++ b/config/locales/co.yml @@ -593,20 +593,6 @@ co: other: Altre publishing: Pubblicazione web: Web - push_notifications: - favourite: - title: "%{name} hà aghjuntu u vostru statutu à i so favuriti" - follow: - title: "%{name} vi seguita" - group: - title: "%{count} nutificazioni" - mention: - action_boost: Sparte - action_expand: Vede di più - action_favourite: Aghjunghje à i favuriti - title: "%{name} v’hà mintuvatu·a" - reblog: - title: "%{name} hà spartutu u vostru statutu" remote_follow: acct: Entrate u vostru cugnome@istanza da induve vulete siguità stu contu missing_resource: Ùn avemu pussutu à truvà l’indirizzu di ridirezzione diff --git a/config/locales/de.yml b/config/locales/de.yml index c0254f73f..75c8b11cf 100644 --- a/config/locales/de.yml +++ b/config/locales/de.yml @@ -594,20 +594,6 @@ de: other: Weiteres publishing: Beiträge web: Web - push_notifications: - favourite: - title: "%{name} hat deinen Beitrag favorisiert" - follow: - title: "%{name} folgt dir nun" - group: - title: "%{count} Benachrichtigungen" - mention: - action_boost: Teilen - action_expand: Mehr anzeigen - action_favourite: Favorisieren - title: "%{name} hat dich erwähnt" - reblog: - title: "%{name} hat deinen Beitrag geteilt" remote_follow: acct: Profilname@Domain, von wo aus du dieser Person folgen möchtest missing_resource: Die erforderliche Weiterleitungs-URL für dein Konto konnte nicht gefunden werden diff --git a/config/locales/en.yml b/config/locales/en.yml index 0257241cf..b9429dbee 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -595,20 +595,6 @@ en: other: Other publishing: Publishing web: Web - push_notifications: - favourite: - title: "%{name} favourited your status" - follow: - title: "%{name} is now following you" - group: - title: "%{count} notifications" - mention: - action_boost: Boost - action_expand: Show more - action_favourite: Favourite - title: "%{name} mentioned you" - reblog: - title: "%{name} boosted your status" remote_follow: acct: Enter your username@domain you want to follow from missing_resource: Could not find the required redirect URL for your account diff --git a/config/locales/eo.yml b/config/locales/eo.yml index 0903e3517..892070914 100644 --- a/config/locales/eo.yml +++ b/config/locales/eo.yml @@ -596,20 +596,6 @@ eo: other: Aliaj aferoj publishing: Publikado web: Reto - push_notifications: - favourite: - title: "%{name} stelumis vian mesaĝon" - follow: - title: "%{name} eksekvis vin" - group: - title: "%{count} sciigoj" - mention: - action_boost: Diskonigi - action_expand: Montri pli - action_favourite: Stelumi - title: "%{name} menciis vin" - reblog: - title: "%{name} diskonigis vian mesaĝon" remote_follow: acct: Enmetu vian uzantnomo@domajno de kie vi volas sekvi missing_resource: La URL de plusendado ne estis trovita diff --git a/config/locales/es.yml b/config/locales/es.yml index 593716b16..3e22e2643 100644 --- a/config/locales/es.yml +++ b/config/locales/es.yml @@ -593,20 +593,6 @@ es: other: Otros publishing: Publicación web: Web - push_notifications: - favourite: - title: "%A {name} le gustó tu estado" - follow: - title: "%{name} te ha empezado a seguir" - group: - title: "%{count} notificaciones" - mention: - action_boost: Retoot - action_expand: Mostrar más - action_favourite: Me Gusta - title: "%{name} te mencionó" - reblog: - title: "%{name} boosteó tu estado" remote_follow: acct: Ingesa tu usuario@dominio desde el que quieres seguir missing_resource: No se pudo encontrar la URL de redirección requerida para tu cuenta diff --git a/config/locales/fa.yml b/config/locales/fa.yml index 1a8372d63..b73f2401d 100644 --- a/config/locales/fa.yml +++ b/config/locales/fa.yml @@ -593,20 +593,6 @@ fa: other: سایر publishing: انتشار web: وب - push_notifications: - favourite: - title: "%{name} نوشتهٔ شما را پسندید" - follow: - title: "%{name} هم‌اینک پیگیر شماست" - group: - title: "%{count} اعلان" - mention: - action_boost: بازبوق - action_expand: نمایش بیشتر - action_favourite: پسندیدن - title: "%{name} از شما نام برد" - reblog: - title: "%{name} نوشتهٔ شما را بازبوقید" remote_follow: acct: نشانی حساب username@domain خود را این‌جا بنویسید missing_resource: نشانی اینترنتی برای رسیدن به حساب شما پیدا نشد diff --git a/config/locales/fi.yml b/config/locales/fi.yml index 68a239ba3..1e02efbd2 100644 --- a/config/locales/fi.yml +++ b/config/locales/fi.yml @@ -590,20 +590,6 @@ fi: other: Muut publishing: Julkaiseminen web: Web - push_notifications: - favourite: - title: "%{name} tykkäsi tilastasi" - follow: - title: "%{name} seuraa nyt sinua" - group: - title: "%{count} ilmoitusta" - mention: - action_boost: Buustaa - action_expand: Näytä lisää - action_favourite: Tykkää - title: "%{nimi} mainitsi sinut" - reblog: - title: "%{name} buustasi tilaasi" remote_follow: acct: Syötä se käyttäjätunnus@verkkotunnus, josta haluat seurata missing_resource: Vaadittavaa uudelleenohjaus-URL:ää tiliisi ei löytynyt diff --git a/config/locales/fr.yml b/config/locales/fr.yml index f8f9026c8..4265a7248 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -594,20 +594,6 @@ fr: other: Autre publishing: Publication web: Web - push_notifications: - favourite: - title: "%{name} a mis votre statut en favori" - follow: - title: "%{name} vous suit" - group: - title: "%{count} notifications" - mention: - action_boost: Partager - action_expand: Montrer plus - action_favourite: Ajouter aux favoris - title: "%{name} vous a mentionné·e" - reblog: - title: "%{name} a partagé votre statut" remote_follow: acct: Entrez votre pseudo@instance depuis lequel vous voulez suivre cet·te utilisateur⋅ice missing_resource: L’URL de redirection n’a pas pu être trouvée diff --git a/config/locales/gl.yml b/config/locales/gl.yml index 6cf83ca27..d38cffb96 100644 --- a/config/locales/gl.yml +++ b/config/locales/gl.yml @@ -594,20 +594,6 @@ gl: other: Outro publishing: Publicando web: Web - push_notifications: - favourite: - title: "%{name} marcou favorito o seu estado" - follow: - title: "%{name} agora está a seguila" - group: - title: "%{count} notificacións" - mention: - action_boost: Promover - action_expand: Mostar máis - action_favourite: Favorito - title: "%{name} mencionouna" - reblog: - title: "%{name} promoveu un dos seus estados" remote_follow: acct: Introduza o seu nomedeusuaria@dominio desde onde quere facer seguimento missing_resource: Non se puido atopar o URL de redirecionamento requerido para a súa conta diff --git a/config/locales/hu.yml b/config/locales/hu.yml index 0cd0021c1..41093aa43 100644 --- a/config/locales/hu.yml +++ b/config/locales/hu.yml @@ -531,20 +531,6 @@ hu: other: Egyéb publishing: Közzététel web: Web - push_notifications: - favourite: - title: "%{name} a kedvenceihez adta a tülköd" - follow: - title: "%{name} mostantól követ téged" - group: - title: "%{count} értesítés" - mention: - action_boost: Reblog - action_expand: Mutass többet - action_favourite: Kedvencekhez adás - title: "%{name} megemlített téged" - reblog: - title: "%{name} reblogolta a tülköd" remote_follow: acct: Írd be a felhasználódat, amelyről követni szeretnéd felhasznalonev@domain formátumban missing_resource: A fiókodnál nem található a szükséges átirányítási URL diff --git a/config/locales/it.yml b/config/locales/it.yml index b53645c9f..a761bff4e 100644 --- a/config/locales/it.yml +++ b/config/locales/it.yml @@ -506,18 +506,6 @@ it: other: Altro publishing: Pubblicazione web: Web - push_notifications: - favourite: - title: "%{name} ha segnato il tuo status come apprezzato" - follow: - title: "%{name} ha iniziato a seguirti" - group: - title: "%{count} notifiche" - mention: - action_expand: Mostra altro - action_favourite: Apprezzato - reblog: - title: "%{name} ha condiviso il tuo status" remote_follow: acct: Inserisci il tuo username@dominio da cui vuoi seguire questo utente missing_resource: Impossibile trovare l'URL di reindirizzamento richiesto per il tuo account diff --git a/config/locales/ja.yml b/config/locales/ja.yml index b6c8f7bcc..cb7340dde 100644 --- a/config/locales/ja.yml +++ b/config/locales/ja.yml @@ -594,20 +594,6 @@ ja: other: その他 publishing: 投稿 web: ウェブ - push_notifications: - favourite: - title: あなたのトゥートが %{name} さんにお気に入り登録されました - follow: - title: "%{name} さんにフォローされました" - group: - title: "%{count} 件の通知" - mention: - action_boost: ブースト - action_expand: もっと見る - action_favourite: お気に入り - title: "%{name} さんから返信がありました" - reblog: - title: あなたのトゥートが %{name} さんにブーストされました remote_follow: acct: あなたの ユーザー名@ドメイン を入力してください missing_resource: リダイレクト先が見つかりませんでした diff --git a/config/locales/ko.yml b/config/locales/ko.yml index c0da95db3..38f411dd5 100644 --- a/config/locales/ko.yml +++ b/config/locales/ko.yml @@ -596,20 +596,6 @@ ko: other: 기타 publishing: 퍼블리싱 web: 웹 - push_notifications: - favourite: - title: "%{name} 님이 당신의 툿를 즐겨찾기에 등록했습니다" - follow: - title: "%{name} 님이 나를 팔로우 하고 있습니다" - group: - title: "%{count} 건의 알림" - mention: - action_boost: 부스트 - action_expand: 더보기 - action_favourite: 즐겨찾기 - title: "%{name} 님이 답장을 보냈습니다" - reblog: - title: "%{name} 님이 당신의 툿을 부스트 했습니다" remote_follow: acct: 아이디@도메인을 입력해 주십시오 missing_resource: 리디렉션 대상을 찾을 수 없습니다 diff --git a/config/locales/nl.yml b/config/locales/nl.yml index 53468a67d..7ec512d9e 100644 --- a/config/locales/nl.yml +++ b/config/locales/nl.yml @@ -594,20 +594,6 @@ nl: other: Overig publishing: Publiceren web: Webapp - push_notifications: - favourite: - title: "%{name} markeerde jouw toot als favoriet" - follow: - title: "%{name} volgt jou nu" - group: - title: "%{count} meldingen" - mention: - action_boost: Boost - action_expand: Meer tonen - action_favourite: Favoriet - title: "%{name} vermeldde jou" - reblog: - title: "%{name} boostte jouw toot" remote_follow: acct: Geef jouw account@domein.tld op waarvandaan je wilt volgen missing_resource: Kon vereiste doorverwijzings-URL voor jouw account niet vinden diff --git a/config/locales/no.yml b/config/locales/no.yml index 837042f85..eb1d27a19 100644 --- a/config/locales/no.yml +++ b/config/locales/no.yml @@ -531,20 +531,6 @@ other: Annet publishing: Publisering web: Web - push_notifications: - favourite: - title: "%{name} favoriserte din status" - follow: - title: "%{name} følger deg nå" - group: - title: "%{count} varslinger" - mention: - action_boost: Fremhev - action_expand: Vis mer - action_favourite: Favoritter - title: "%{name} nevnte deg" - reblog: - title: "%{name} fremhevde din status" remote_follow: acct: Tast inn brukernavn@domene som du vil følge fra missing_resource: Kunne ikke finne URLen for din konto diff --git a/config/locales/oc.yml b/config/locales/oc.yml index c9a33aad6..4a8453457 100644 --- a/config/locales/oc.yml +++ b/config/locales/oc.yml @@ -668,20 +668,6 @@ oc: other: Autre publishing: Publicar web: Interfàcia Web - push_notifications: - favourite: - title: "%{name} a mes vòstre estatut en favorit" - follow: - title: "%{name} vos sèc ara" - group: - title: "%{count} notificacions" - mention: - action_boost: Partejar - action_expand: Ne veire mai - action_favourite: Ajustar als favorits - title: "%{name} vos a mencionat" - reblog: - title: "%{name} a partejat vòstre estatut" remote_follow: acct: Picatz vòstre utilizaire@instància que cal utilizar per sègre aqueste utilizaire missing_resource: URL de redireccion pas trobada diff --git a/config/locales/pl.yml b/config/locales/pl.yml index e465388e2..15dfdf740 100644 --- a/config/locales/pl.yml +++ b/config/locales/pl.yml @@ -603,20 +603,6 @@ pl: other: Pozostałe publishing: Publikowanie web: Sieć - push_notifications: - favourite: - title: "%{name} dodał Twój wpis do ulubionych" - follow: - title: "%{name} zaczął Cię śledzić" - group: - title: "%{count} powiadomień" - mention: - action_boost: Podbij - action_expand: Pokaż więcej - action_favourite: Dodaj do ulubionych - title: "%{name} wspomniał o Tobie" - reblog: - title: "%{name} podbił Twój wpis" remote_follow: acct: Podaj swój adres (nazwa@domena), z którego chcesz śledzić missing_resource: Nie udało się znaleźć adresu przekierowania z Twojej domeny diff --git a/config/locales/pt-BR.yml b/config/locales/pt-BR.yml index 702236198..cf7584999 100644 --- a/config/locales/pt-BR.yml +++ b/config/locales/pt-BR.yml @@ -593,20 +593,6 @@ pt-BR: other: Outro publishing: Publicação web: Web - push_notifications: - favourite: - title: "%{name} favoritou a sua postagem" - follow: - title: "%{name} está te seguindo" - group: - title: "%{count} notificações" - mention: - action_boost: Compartilhar - action_expand: Mostrar mais - action_favourite: Favoritar - title: "%{name} mencionou você" - reblog: - title: "%{name} compartilhou a sua postagem" remote_follow: acct: Insira o seu usuário@domínio do qual você quer seguir missing_resource: Não foi possível encontrar a URL de direcionamento para a sua conta diff --git a/config/locales/pt.yml b/config/locales/pt.yml index 7c10124ff..a1370c91d 100644 --- a/config/locales/pt.yml +++ b/config/locales/pt.yml @@ -534,20 +534,6 @@ pt: other: Outro publishing: Publicação web: Web - push_notifications: - favourite: - title: "%{name} adicionou o teu post aos favoritos" - follow: - title: "%{name} começou a seguir-te" - group: - title: "%{count} notificações" - mention: - action_boost: Partilhar - action_expand: Mostrar mais - action_favourite: Adicionar aos favoritos - title: "%{name} mencionou-te" - reblog: - title: "%{name} partilhou o teu post" remote_follow: acct: Entre seu usuário@domínio do qual quer seguir missing_resource: Não foi possível achar a URL de redirecionamento para sua conta diff --git a/config/locales/ru.yml b/config/locales/ru.yml index 2363bba12..19b844612 100644 --- a/config/locales/ru.yml +++ b/config/locales/ru.yml @@ -606,20 +606,6 @@ ru: other: Другое publishing: Публикация web: WWW - push_notifications: - favourite: - title: Ваш статус понравился %{name} - follow: - title: "%{name} теперь подписан(а) на Вас" - group: - title: "%{count} уведомлений" - mention: - action_boost: Продвинуть - action_expand: Развернуть - action_favourite: Нравится - title: Вас упомянул(а) %{name} - reblog: - title: "%{name} продвинул(а) Ваш статус" remote_follow: acct: Введите username@domain, откуда Вы хотите подписаться missing_resource: Поиск требуемого перенаправления URL для Вашего аккаунта завершился неудачей diff --git a/config/locales/sk.yml b/config/locales/sk.yml index 8debd87ff..3e1300b2b 100644 --- a/config/locales/sk.yml +++ b/config/locales/sk.yml @@ -591,20 +591,6 @@ sk: other: Ostatné publishing: Publikovanie web: Web - push_notifications: - favourite: - title: "%{name} si obľúbil/a tvoj príspevok" - follow: - title: "%{name} ťa teraz následuje" - group: - title: "%{count} notifikácie" - mention: - action_boost: Pozdvihni - action_expand: Ukáž viac - action_favourite: Obľúbené - title: "%{name} ťa spomenul/a" - reblog: - title: "%{name} vyzdvihli tvoj príspevok" remote_follow: acct: Napíš svoju prezývku@doménu z ktorej chceš následovať missing_resource: Nemôžeme nájsť potrebnú presmerovaciu adresu k tvojmu účtu diff --git a/config/locales/sr-Latn.yml b/config/locales/sr-Latn.yml index 0c7756c53..15c6b00ac 100644 --- a/config/locales/sr-Latn.yml +++ b/config/locales/sr-Latn.yml @@ -525,20 +525,6 @@ sr-Latn: other: Ostali publishing: Objavljivanje web: Veb - push_notifications: - favourite: - title: "%{name} je stavio Vaš status za omiljeni" - follow: - title: "%{name} Vas je zapratio" - group: - title: "%{count} obaveštenja" - mention: - action_boost: Podrži - action_expand: Prikaži još - action_favourite: Omiljeni - title: "%{name} Vas je pomenuo" - reblog: - title: "%{name} je podržao(la) Vaš status" remote_follow: acct: Unesite Vaš korisnik@domen sa koga želite da pratite missing_resource: Ne mogu da nađem zahtevanu adresu preusmeravanja za Vaš nalog diff --git a/config/locales/sr.yml b/config/locales/sr.yml index 1cb87ff30..d34a2ecbf 100644 --- a/config/locales/sr.yml +++ b/config/locales/sr.yml @@ -525,20 +525,6 @@ sr: other: Остали publishing: Објављивање web: Веб - push_notifications: - favourite: - title: "%{name} је ставио Ваш статус за омиљени" - follow: - title: "%{name} Вас је запратио" - group: - title: "%{count} обавештења" - mention: - action_boost: Подржи - action_expand: Прикажи још - action_favourite: Омиљени - title: "%{name} Вас је поменуо" - reblog: - title: "%{name} је подржао(ла) Ваш статус" remote_follow: acct: Унесите Ваш корисник@домен са кога желите да пратите missing_resource: Не могу да нађем захтевану адресу преусмеравања за Ваш налог diff --git a/config/locales/sv.yml b/config/locales/sv.yml index 1b0965655..73645d013 100644 --- a/config/locales/sv.yml +++ b/config/locales/sv.yml @@ -592,20 +592,6 @@ sv: other: Annat publishing: Publicering web: Webb - push_notifications: - favourite: - title: "%{name} favoriserade din status" - follow: - title: "%{name} följer nu dig" - group: - title: "%{count} meddelanden" - mention: - action_boost: Knuffa - action_expand: Visa mer - action_favourite: Favoriter - title: "%{name} nämnde dig" - reblog: - title: "%{name} boostade din status" remote_follow: acct: Ange ditt användarnamn@domän du vill följa från missing_resource: Det gick inte att hitta den begärda omdirigeringsadressen för ditt konto diff --git a/config/locales/zh-CN.yml b/config/locales/zh-CN.yml index 5eca9e6a5..9f98a893d 100644 --- a/config/locales/zh-CN.yml +++ b/config/locales/zh-CN.yml @@ -523,20 +523,6 @@ zh-CN: other: 其他 publishing: 发布 web: 站内 - push_notifications: - favourite: - title: "%{name} 收藏了你的嘟文" - follow: - title: "%{name} 关注了你" - group: - title: "%{count} 条新通知" - mention: - action_boost: 转嘟 - action_expand: 显示更多 - action_favourite: 收藏 - title: "%{name} 提到了你" - reblog: - title: "%{name} 转嘟了你的嘟文" remote_follow: acct: 请输入你的“用户名@实例域名” missing_resource: 无法确定你的帐户的跳转 URL diff --git a/config/locales/zh-HK.yml b/config/locales/zh-HK.yml index 04df558b1..14eedc9ba 100644 --- a/config/locales/zh-HK.yml +++ b/config/locales/zh-HK.yml @@ -593,20 +593,6 @@ zh-HK: other: 其他 publishing: 發佈 web: 站内 - push_notifications: - favourite: - title: "%{name} 收藏了你的文章" - follow: - title: "%{name} 關注了你" - group: - title: "%{count} 條新通知" - mention: - action_boost: 轉推 - action_expand: 顯示更多 - action_favourite: 收藏 - title: "%{name} 提到了你" - reblog: - title: "%{name} 轉推了你的文章" remote_follow: acct: 請輸入你的︰用戶名稱@服務點域名 missing_resource: 無法找到你用戶的轉接網址 -- cgit