From 7e81bca50041b578f2219b5c795af104b4a46a08 Mon Sep 17 00:00:00 2001 From: Sam Schlinkert Date: Mon, 28 Jan 2019 16:57:42 -0500 Subject: [PATCH 01/11] Bumps copyright year in README.md to 2019 (#9939) This is so incredibly small, but assuming this is a needed change. Might want to check year in other files. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 5ad6894ca7..03c8472b9b 100644 --- a/README.md +++ b/README.md @@ -86,7 +86,7 @@ You can open issues for bugs you've found or features you think are missing. You ## License -Copyright (C) 2016-2018 Eugen Rochko & other Mastodon contributors (see [AUTHORS.md](AUTHORS.md)) +Copyright (C) 2016-2019 Eugen Rochko & other Mastodon contributors (see [AUTHORS.md](AUTHORS.md)) This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. From 4079b831e6d8430080307dc3ef3350e382f624db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?marcin=20miko=C5=82ajczak?= Date: Tue, 29 Jan 2019 20:21:15 +0100 Subject: [PATCH 02/11] =?UTF-8?q?i18n:=20Update=20Polish=20translation=20?= =?UTF-8?q?=F0=9F=87=B5=F0=9F=87=B1=20(#9945)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Update Polish translation Signed-off-by: Marcin Mikołajczak * normalize Signed-off-by: Marcin Mikołajczak * inconsistentInterpolations-- Signed-off-by: Marcin Mikołajczak --- config/locales/pl.yml | 33 ++++++++++++++++++++++++++++++--- 1 file changed, 30 insertions(+), 3 deletions(-) diff --git a/config/locales/pl.yml b/config/locales/pl.yml index beadae14de..188f5c22b9 100644 --- a/config/locales/pl.yml +++ b/config/locales/pl.yml @@ -565,8 +565,11 @@ pl: warning_title: Dostępność usuniętej zawartości directories: directory: Katalog profilów + enabled: Jesteś obecnie zapisany(-a) do katalogu + enabled_but_waiting: Jesteś zapisany(-a) do katalogu, ale jeszcze nie śledzi Cię wystarczająca liczba osób (%{min_followers}), aby się tam pojawić. explanation: Poznaj profile na podstawie zainteresowań explore_mastodon: Odkrywaj %{title} + how_to_enable: Nie jesteś obecnie zapisany(-a) do katalogu. Poniżej możesz zapisać się. Użyj hashtagów w swoim opisie, aby zostać wyświetlonym pod określonymi hashtagami! people: few: "%{count} osoby" many: "%{count} osób" @@ -621,7 +624,11 @@ pl: followers_count: Liczba śledzących lock_link: Zablokuj swoje konto purge: Przestań śledzić - success: W trakcie usuwania śledzących z %{count} domen… + success: + few: W trakcie usuwania śledzących z %{count} domen… + many: W trakcie usuwania śledzących z %{count} domen… + one: W trakcie usuwania śledzących z jednej domeny… + other: W trakcie usuwania śledzących z %{count} domen… true_privacy_html: Pamiętaj, że rzeczywista prywatność może zostać uzyskana wyłącznie dzięki szyfrowaniu end-to-end. unlocked_warning_html: Każdy może Cię śledzić, dzięki czemu może zobaczyć Twoje niepubliczne wpisy. %{lock_link} aby móc kontrolować, kto Cię śledzi. unlocked_warning_title: Twoje konto nie jest zablokowane @@ -631,6 +638,7 @@ pl: resources: Zasoby generic: changes_saved_msg: Ustawienia zapisane! + copy: Kopiuj save_changes: Zapisz zmiany validation_errors: few: Coś jest wciąż nie tak! Przejrzyj %{count} poniższe błędy @@ -750,10 +758,25 @@ pl: no_account_html: Nie masz konta? Możesz zarejestrować się tutaj proceed: Śledź prompt: 'Zamierzasz śledzić:' + reason_html: "Dlaczego ten krok jest konieczny? %{instance} może nie być serwerem na którym jesteś zarejestrowany(-a), więc musisz zostać przekierowany(-a) na swój serwer." + remote_interaction: + favourite: + proceed: Przejdź do dodania do ulubionych + prompt: 'Chcesz dodać ten wpis do ulubionych:' + reblog: + proceed: Przejdź do podbicia + prompt: 'Chcesz podbić ten wpis:' + reply: + proceed: Przejdź do dodawania odpowiedzi + prompt: 'Chcesz odpowiedzieć na ten wpis:' remote_unfollow: error: Błąd title: Tytuł - unfollowed: Przestałeś śledzić + unfollowed: Przestałeś(-aś) śledzić + scheduled_statuses: + over_daily_limit: Przekroczyłeś(-aś) limit %{limit} zaplanowanych wpisów na ten dzień + over_total_limit: Przekroczyłeś(-aś) limit %{limit} zaplanowanych wpisów + too_soon: Zaplanowana data musi wypadać w przyszłości sessions: activity: Ostatnia aktywność browser: Przeglądarka @@ -825,7 +848,11 @@ pl: other: "%{count} filmów" boosted_from_html: Podbito przez %{acct_link} content_warning: 'Ostrzeżenie o zawartości: %{warning}' - disallowed_hashtags: 'zawiera niedozwolone hashtagi: %{tags}' + disallowed_hashtags: + few: 'zawiera niedozwolone hashtagi: %{tags}' + many: 'zawiera niedozwolone hashtagi: %{tags}' + one: 'zawiera niedozwolony hashtag: %{tags}' + other: 'zawiera niedozwolone hashtagi: %{tags}' language_detection: Automatycznie wykrywaj język open_in_web: Otwórz w przeglądarce over_character_limit: limit %{max} znaków przekroczony From 6c513c75efa7d9af646ffebb46c1e3b04f0824f8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Wed, 30 Jan 2019 04:22:59 +0900 Subject: [PATCH 03/11] Bump rails-i18n from 5.1.2 to 5.1.3 (#9943) Bumps [rails-i18n](https://github.com/svenfuchs/rails-i18n) from 5.1.2 to 5.1.3. - [Release notes](https://github.com/svenfuchs/rails-i18n/releases) - [Changelog](https://github.com/svenfuchs/rails-i18n/blob/master/CHANGELOG.md) - [Commits](https://github.com/svenfuchs/rails-i18n/commits) Signed-off-by: dependabot[bot] --- Gemfile.lock | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 7b8ffec9ad..8f661fc242 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -269,7 +269,7 @@ GEM httplog (1.2.0) rack (>= 1.0) rainbow (>= 2.0.0) - i18n (1.5.2) + i18n (1.5.3) concurrent-ruby (~> 1.0) i18n-tasks (0.9.28) activesupport (>= 4.0.2) @@ -455,7 +455,7 @@ GEM nokogiri (>= 1.6) rails-html-sanitizer (1.0.4) loofah (~> 2.2, >= 2.2.2) - rails-i18n (5.1.2) + rails-i18n (5.1.3) i18n (>= 0.7, < 2) railties (>= 5.0, < 6) rails-settings-cached (0.6.6) From 6513f6c953cdaad9118ea24a21f22fd2978bed28 Mon Sep 17 00:00:00 2001 From: Clar Charr Date: Thu, 31 Jan 2019 07:45:15 -0500 Subject: [PATCH 04/11] Replace unlock-alt icon with unlock (#9952) --- app/helpers/stream_entries_helper.rb | 2 +- app/javascript/mastodon/components/account.js | 2 +- app/javascript/mastodon/components/domain.js | 2 +- app/javascript/mastodon/features/account/components/header.js | 2 +- .../mastodon/features/compose/components/privacy_dropdown.js | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/app/helpers/stream_entries_helper.rb b/app/helpers/stream_entries_helper.rb index 033d435c49..7a74c0b7d0 100644 --- a/app/helpers/stream_entries_helper.rb +++ b/app/helpers/stream_entries_helper.rb @@ -170,7 +170,7 @@ module StreamEntriesHelper when 'public' fa_icon 'globe fw' when 'unlisted' - fa_icon 'unlock-alt fw' + fa_icon 'unlock fw' when 'private' fa_icon 'lock fw' when 'direct' diff --git a/app/javascript/mastodon/components/account.js b/app/javascript/mastodon/components/account.js index 206030c006..2705a60013 100644 --- a/app/javascript/mastodon/components/account.js +++ b/app/javascript/mastodon/components/account.js @@ -88,7 +88,7 @@ class Account extends ImmutablePureComponent { if (requested) { buttons = ; } else if (blocking) { - buttons = ; + buttons = ; } else if (muting) { let hidingNotificationsButton; if (account.getIn(['relationship', 'muting_notifications'])) { diff --git a/app/javascript/mastodon/components/domain.js b/app/javascript/mastodon/components/domain.js index 24f80e7888..85729ca943 100644 --- a/app/javascript/mastodon/components/domain.js +++ b/app/javascript/mastodon/components/domain.js @@ -32,7 +32,7 @@ class Account extends ImmutablePureComponent {
- +
diff --git a/app/javascript/mastodon/features/account/components/header.js b/app/javascript/mastodon/features/account/components/header.js index 2ab25cde44..4f6d0712d1 100644 --- a/app/javascript/mastodon/features/account/components/header.js +++ b/app/javascript/mastodon/features/account/components/header.js @@ -132,7 +132,7 @@ class Header extends ImmutablePureComponent { } else if (account.getIn(['relationship', 'blocking'])) { actionBtn = (
- +
); } diff --git a/app/javascript/mastodon/features/compose/components/privacy_dropdown.js b/app/javascript/mastodon/features/compose/components/privacy_dropdown.js index 5698765d94..e8f57a4661 100644 --- a/app/javascript/mastodon/features/compose/components/privacy_dropdown.js +++ b/app/javascript/mastodon/features/compose/components/privacy_dropdown.js @@ -214,7 +214,7 @@ class PrivacyDropdown extends React.PureComponent { this.options = [ { icon: 'globe', value: 'public', text: formatMessage(messages.public_short), meta: formatMessage(messages.public_long) }, - { icon: 'unlock-alt', value: 'unlisted', text: formatMessage(messages.unlisted_short), meta: formatMessage(messages.unlisted_long) }, + { icon: 'unlock', value: 'unlisted', text: formatMessage(messages.unlisted_short), meta: formatMessage(messages.unlisted_long) }, { icon: 'lock', value: 'private', text: formatMessage(messages.private_short), meta: formatMessage(messages.private_long) }, { icon: 'envelope', value: 'direct', text: formatMessage(messages.direct_short), meta: formatMessage(messages.direct_long) }, ]; From 0167659f5f0b61e5a44df33df2510c2388a1a297 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20=C4=BDach?= <45913977+marek-lach@users.noreply.github.com> Date: Fri, 1 Feb 2019 00:07:08 +0100 Subject: [PATCH 05/11] Distinguish error messaging for mystyped URLs and deleted accounts (#9957) --- config/locales/en.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/config/locales/en.yml b/config/locales/en.yml index 10749b21b4..fc0f634159 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -563,8 +563,8 @@ en: other: "%{count} people" errors: '403': You don't have permission to view this page. - '404': The page you were looking for doesn't exist. - '410': The page you were looking for doesn't exist anymore. + '404': The page you are looking for isn't here. + '410': The page you were looking for doesn't exist here anymore. '422': content: Security verification failed. Are you blocking cookies? title: Security verification failed @@ -577,7 +577,7 @@ en: archive_takeout: date: Date download: Download your archive - hint_html: You can request an archive of your toots and uploaded media. The exported data will be in ActivityPub format, readable by any compliant software. You can request an archive every 7 days. + hint_html: You can request an archive of your toots and uploaded media. The exported data will be in the ActivityPub format, readable by any compliant software. You can request an archive every 7 days. in_progress: Compiling your archive... request: Request your archive size: Size From 3383ed7573866f086ac49b0e975d5c502cdf4b89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20=C4=BDach?= <45913977+marek-lach@users.noreply.github.com> Date: Fri, 1 Feb 2019 00:13:47 +0100 Subject: [PATCH 06/11] Update the Slovak translation (#9958) --- config/locales/sk.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/config/locales/sk.yml b/config/locales/sk.yml index d8a81bbbf7..c2099ea1c9 100644 --- a/config/locales/sk.yml +++ b/config/locales/sk.yml @@ -570,16 +570,16 @@ sk: other: "%{count} ľudia" errors: '403': Nemáš povolenie na zobrazenie tejto stránky. - '404': Stránka ktorú si hľadal/a sa tu nenachádza. - '410': Stránka ktorú si tu hľadal/a už viac neexistuje. + '404': Stránka ktorú hľadáš nieje tu. + '410': Stránka ktorú si tu hľadal/a sa tu už viac nenachádza. '422': content: Bezpečtnostné overenie zlyhalo. Blokuješ cookies? title: Bezpečtnostné overenie zlyhalo '429': Zamlčané '500': - content: Ospravedlňujeme sa. Niečo sa pokazilo na našom konci. + content: Ospravedlňujem sa. Niečo sa pokazilo na našom konci. title: Táto stránka nieje v poriadku - noscript_html: Aby bolo možné používať Mastodon web aplikáciu, prosím povoľte JavaScript. Alebo skúste jednu z aplikácii dostupných pre vašu platformu. + noscript_html: Aby bolo možné používať Mastodon web aplikáciu, povoľ prosím JavaScript. Alebo skús jednu z aplikácii dostupných pre vašu platformu. exports: archive_takeout: date: Dátum @@ -607,7 +607,7 @@ sk: invalid_context: Nebola poskytnutá žiadna, alebo ide o neplatnú súvislosť invalid_irreversible: Nezvratné filtrovanie funguje iba so súvislostiami domovskej osi a oboznámení index: - delete: Vymazať + delete: Vymaž title: Triedenia new: title: Pridaj nové triedenie @@ -615,7 +615,7 @@ sk: domain: Doména explanation_html: Pokiaľ chceš zaručiť súkromie svojích príspevkov, musíš mať na vedomí, kto ťa sleduje. Tvoje súkromné príspevky sú doručené na každý server z ktorého ťa niekto následuje. Takže možno by si ich chcel/a skontrolovať, a odstrániť tých následovníkov, čo sú na serveroch ktorím nedôveruješ, že ich moderátori, alebo úpravbuy kódu budú tiež rešpektovať tvoje súkromie. followers_count: Počet následovateľov - lock_link: Zamknite svoj účet + lock_link: Zamkni svoj účet purge: Odstrániť následovateľa success: few: Počas utišovania sledovateľov z %{count} domén... From 1f9519020296c8c24a73d3f99d3c1ad94a627f3b Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Fri, 1 Feb 2019 00:14:05 +0100 Subject: [PATCH 07/11] Refactor icons in web UI to use Icon component (#9951) * Refactor uses of icons to an Icon component in web UI * Refactor options passed to the Icon component * Make tests work with absolute component paths --- .eslintrc.js | 5 +++++ .../mastodon/components/attachment_list.js | 5 +++-- .../mastodon/components/column_back_button.js | 3 ++- .../components/column_back_button_slim.js | 3 ++- .../mastodon/components/column_header.js | 15 ++++++------- app/javascript/mastodon/components/icon.js | 21 +++++++++++++++++++ .../mastodon/components/icon_button.js | 5 +++-- .../mastodon/components/load_gap.js | 3 ++- app/javascript/mastodon/components/status.js | 5 +++-- .../mastodon/components/status_content.js | 3 ++- .../features/account/components/header.js | 5 +++-- .../account_gallery/components/media_item.js | 3 ++- .../account_timeline/components/moved_note.js | 3 ++- .../compose/components/compose_form.js | 3 ++- .../compose/components/privacy_dropdown.js | 3 ++- .../features/compose/components/search.js | 5 +++-- .../compose/components/search_results.js | 11 +++++----- .../features/compose/components/upload.js | 5 +++-- .../compose/components/upload_progress.js | 3 ++- .../mastodon/features/compose/index.js | 15 ++++++------- .../features/getting_started/index.js | 3 ++- .../features/list_adder/components/list.js | 3 ++- .../features/list_editor/components/search.js | 5 +++-- .../mastodon/features/list_timeline/index.js | 5 +++-- .../components/clear_column_button.js | 3 ++- .../notifications/components/filter_bar.js | 9 ++++---- .../notifications/components/notification.js | 7 ++++--- .../features/status/components/card.js | 7 ++++--- .../status/components/detailed_status.js | 11 +++++----- .../mastodon/features/status/index.js | 3 ++- .../features/ui/components/boost_modal.js | 3 ++- .../features/ui/components/column_header.js | 3 ++- .../features/ui/components/column_link.js | 5 +++-- .../features/ui/components/columns_area.js | 3 ++- .../features/ui/components/media_modal.js | 5 +++-- .../features/ui/components/tabs_bar.js | 13 ++++++------ .../mastodon/features/video/index.js | 13 ++++++------ jest.config.js | 4 ++++ 38 files changed, 147 insertions(+), 82 deletions(-) create mode 100644 app/javascript/mastodon/components/icon.js diff --git a/.eslintrc.js b/.eslintrc.js index 56e3d0530f..177496d3a3 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -41,6 +41,11 @@ module.exports = { 'node_modules', '\\.(css|scss|json)$', ], + 'import/resolver': { + node: { + paths: ['app/javascript'], + }, + }, }, rules: { diff --git a/app/javascript/mastodon/components/attachment_list.js b/app/javascript/mastodon/components/attachment_list.js index 8e5bb0e0be..5dfa1464c4 100644 --- a/app/javascript/mastodon/components/attachment_list.js +++ b/app/javascript/mastodon/components/attachment_list.js @@ -2,6 +2,7 @@ import React from 'react'; import ImmutablePropTypes from 'react-immutable-proptypes'; import PropTypes from 'prop-types'; import ImmutablePureComponent from 'react-immutable-pure-component'; +import Icon from 'mastodon/components/icon'; const filename = url => url.split('/').pop().split('#')[0].split('?')[0]; @@ -24,7 +25,7 @@ export default class AttachmentList extends ImmutablePureComponent { return (
  • - {filename(displayUrl)} + {filename(displayUrl)}
  • ); })} @@ -36,7 +37,7 @@ export default class AttachmentList extends ImmutablePureComponent { return (
    - +
      diff --git a/app/javascript/mastodon/components/column_back_button.js b/app/javascript/mastodon/components/column_back_button.js index 8a60c4192a..f41045787e 100644 --- a/app/javascript/mastodon/components/column_back_button.js +++ b/app/javascript/mastodon/components/column_back_button.js @@ -1,6 +1,7 @@ import React from 'react'; import { FormattedMessage } from 'react-intl'; import PropTypes from 'prop-types'; +import Icon from 'mastodon/components/icon'; export default class ColumnBackButton extends React.PureComponent { @@ -19,7 +20,7 @@ export default class ColumnBackButton extends React.PureComponent { render () { return ( ); diff --git a/app/javascript/mastodon/components/column_back_button_slim.js b/app/javascript/mastodon/components/column_back_button_slim.js index 964c100bef..cc8bfb1515 100644 --- a/app/javascript/mastodon/components/column_back_button_slim.js +++ b/app/javascript/mastodon/components/column_back_button_slim.js @@ -1,6 +1,7 @@ import React from 'react'; import { FormattedMessage } from 'react-intl'; import ColumnBackButton from './column_back_button'; +import Icon from 'mastodon/components/icon'; export default class ColumnBackButtonSlim extends ColumnBackButton { @@ -8,7 +9,7 @@ export default class ColumnBackButtonSlim extends ColumnBackButton { return (
      - +
      diff --git a/app/javascript/mastodon/components/column_header.js b/app/javascript/mastodon/components/column_header.js index f68e4155eb..f33c689e7c 100644 --- a/app/javascript/mastodon/components/column_header.js +++ b/app/javascript/mastodon/components/column_header.js @@ -2,6 +2,7 @@ import React from 'react'; import PropTypes from 'prop-types'; import classNames from 'classnames'; import { FormattedMessage, injectIntl, defineMessages } from 'react-intl'; +import Icon from 'mastodon/components/icon'; const messages = defineMessages({ show: { id: 'column_header.show_settings', defaultMessage: 'Show settings' }, @@ -109,22 +110,22 @@ class ColumnHeader extends React.PureComponent { } if (multiColumn && pinned) { - pinButton = ; + pinButton = ; moveButtons = (
      - - + +
      ); } else if (multiColumn) { - pinButton = ; + pinButton = ; } if (!pinned && (multiColumn || showBackButton)) { backButton = ( ); @@ -140,7 +141,7 @@ class ColumnHeader extends React.PureComponent { } if (children || multiColumn) { - collapseButton = ; + collapseButton = ; } const hasTitle = icon && title; @@ -150,7 +151,7 @@ class ColumnHeader extends React.PureComponent {

      {hasTitle && ( )} diff --git a/app/javascript/mastodon/components/icon.js b/app/javascript/mastodon/components/icon.js new file mode 100644 index 0000000000..d8a17722fe --- /dev/null +++ b/app/javascript/mastodon/components/icon.js @@ -0,0 +1,21 @@ +import React from 'react'; +import PropTypes from 'prop-types'; +import classNames from 'classnames'; + +export default class Icon extends React.PureComponent { + + static propTypes = { + id: PropTypes.string.isRequired, + className: PropTypes.string, + fixedWidth: PropTypes.bool, + }; + + render () { + const { id, className, fixedWidth, ...other } = this.props; + + return ( + + ); + } + +} diff --git a/app/javascript/mastodon/components/icon_button.js b/app/javascript/mastodon/components/icon_button.js index b96e48fd09..fbb42f78f8 100644 --- a/app/javascript/mastodon/components/icon_button.js +++ b/app/javascript/mastodon/components/icon_button.js @@ -3,6 +3,7 @@ import Motion from '../features/ui/util/optional_motion'; import spring from 'react-motion/lib/spring'; import PropTypes from 'prop-types'; import classNames from 'classnames'; +import Icon from 'mastodon/components/icon'; export default class IconButton extends React.PureComponent { @@ -86,7 +87,7 @@ export default class IconButton extends React.PureComponent { style={style} tabIndex={tabIndex} > -