Commit Graph

1484 Commits

Author SHA1 Message Date
Matt Jankowski 66d8f99a30 Admin reports with accounts (#2092)
* Add a ReportFilter class

* Add reports and targeted_reports relationships to Account

* Use ReportFilter from admin/reports controller

* Link to admin/reports filtered views from admin account show view

* Add indexes to reports.account_id and reports.target_account_id
2017-04-18 19:36:18 +02:00
Tomohiro Suwa f23281e31e Disable toot button when above 500 characters (#2088)
* Disable toot button when above 500 characters

* Consider multibyte characters

* Consider spoiler_text
2017-04-18 19:35:55 +02:00
spf 9783d8b6c0 fix admin input display (#1633) 2017-04-18 17:25:44 +02:00
JP DeVries 7525971561 Moving aria-label to div.column (#1769)
* Use landmark regions on columns

Closes mastodon#1720

* Moving aria-label to div.column
2017-04-18 17:21:25 +02:00
Matt Jankowski 84b5fae8e3 Simplify renders in views (#2084)
* Simplify render in mailer views

* Simplify render in about/more view

* Simplify render in accounts follow views

* Simplify render in recovery code views

* Simplify render in stream entry embed

* Simplify render in stream entries status partial

* Simplify render in authorize follow new view
2017-04-18 17:15:30 +02:00
ik-fib 23ecc681c4 Add "Mastodon" to user agent (#2073)
Remove non-const version string

Freeze option is unnecessary
2017-04-18 16:04:13 +02:00
Keiji, Yoshimi 82bbf57e7a Translate onboarding dialog to japanese (#2062)
* translate onboarding modal to japanese

* fixed translation by feedback
2017-04-18 16:03:27 +02:00
839 e2a1b574ab Avoid dynamic methods due to processing speed (#2080) 2017-04-18 15:57:46 +02:00
Andrey Blinov 880590ad0d Fix header icons in navigation bar (#2081) 2017-04-18 15:57:16 +02:00
Koala Yeung 0a1b024600 Add Occitan (oc) translation (#2077)
* Added oc.yml

* Added `config/locales/oc.yml`.
  Translated in General Occitan (Quent-in).

* Added oc.jsx (Occitan translation)

* Written in General Occitan (lengadocian)
* Added `app/assets/javascripts/components/locales/oc.js`

* Added doorkeeper.oc.yml

* Added `config/locales/doorkeeper.oc.yml` (Quent-in)

* Added simple_form.oc.yml

* Added `config/locales/simple_form.oc.yml` (Quent-in).

* Merge en.yml changes into oc.yml

Added new strings for translations

* Fix typo in oc.yml

* Update javascript locale support (oc)

* Update ruby locale list (oc)

* Fix oc.yml

* Remove obsoleted translations
* Moved old translation of `reports` to `admin.reports`
2017-04-18 15:21:16 +02:00
Ratmir Karabut 50ed72767d Update Russian translation (#1967)
* Add Russian translation (ru)

* Fix a missing comma

* Fix the wording for better consistency

* Update Russian translation

* Arrange Russian setting alphabetically

* Fix syntax error

* Update Russian translation

* Fix formatting error

* Update Russian translation

* Update Russian translation

* Update ru.jsx

* Fix syntax error

* Remove two_factor_auth.warning (appears obsolete)

* Add missing strings in ru.yml

A lot of new strings translated, especially for the newly added admin section

* Fix translation consistency
2017-04-18 15:20:37 +02:00
geta6 75910abd8f Add hasMore field to account timeline (#2066) 2017-04-18 13:10:49 +02:00
Eugen Rochko 42d54dc9ea Adjust visuals of non-autoplaying GIFV 2017-04-18 01:57:50 +02:00
Eugen Rochko 57d784f1e4 Merge branch 'pause-gif' of git://github.com/patf/mastodon into patf-pause-gif 2017-04-18 01:25:50 +02:00
Matt Jankowski 16d50f60d1 Remove unused methods (#1730)
* Remove unused method #set_counters_maps from api controller

* Remove unused method #set_account_counters_maps from api controller

* Remove unused method Account#followers_domains

* Remove unused User.prolific scope

* Add mastodon:users:admins task to list all admin emails

* Use interpolated query style in Account.triadic_closures

* Coverage for Account.triadic_closures
2017-04-18 01:21:55 +02:00
Eugen Rochko f5cd0b4956 Rename cache key to exclude_account_ids_for:id, adjust formatting 2017-04-18 01:14:02 +02:00
Eugen Rochko 2fd0473aa1 Merge branch 'fix/cache_blocking' of git://github.com/pixiv/mastodon into pixiv-fix/cache_blocking 2017-04-18 01:09:57 +02:00
Damien Erambert 9cefb5731d Add FR locales to the onboarding modal (#1976)
* Add FR locale for the onboarding modal component

* Slightly increase the max-width and max-height of the onboarding modal

This is done so it doesn't break with locales whose strings would be
too long

* Update FR locales for onboarding upon PR comments
2017-04-18 01:02:02 +02:00
Mingye Wang 00a85f31ca Add simplified Chinese js translation (#2044)
This single-file commit, heavily based on the zh-hk version as of
ec9999c, fixes the missing js locale. Intentional, significant
departures from current zh-cn yml localizations have been marked with
rationales given.
2017-04-18 01:01:32 +02:00
Matt Jankowski 389f8f8249 Instance helper to replace site title helper (#2038)
* Move site title helper to instance helper (name change only)

* Remove newline in <title> tag

* Add site_hostname helper method to wrap up local_domain value

* Use site_hostname helper in places that need local_domain value
2017-04-18 00:16:32 +02:00
jeroenpraat e1e15adf1d Updated, improved and fixed Dutch language strings (#2030)
* Fixed some words

* Improved and more consistent

* Fixes and a bit less 'je'

* Improved and more consistent

* Another round of improvements and consistency

* More improvements and less 'je'

* Update

* Updated with admin strings

* More improvements and additions - not complete yet, but most is there

* This is what we call in Dutch 'the English disease' :-)

* fix comma

* admin.reportsi

* not needed

* hopefully now fixed
2017-04-18 00:16:03 +02:00
Matt Jankowski f96f8d0176 Use .presence instead of ternary on site description for og: content (#2033) 2017-04-17 23:19:45 +02:00
Sam Hewitt a05e7582e4 optimized logo (#2020)
- adjusted elements to fit the pixel grid for better scaling
- optimized the PNG asset and the SVG asset
2017-04-17 21:49:51 +02:00
Andrey Blinov 7d1e653ec1 Fix import pt_br locale in mastodon.jsx (#2011) 2017-04-17 21:01:42 +02:00
Zac Anger 7b397b1452 Return early from submit if no text. (#1962) 2017-04-17 20:30:38 +02:00
Matt Jankowski cc1361c149 Media controller specs (#2022)
* Add spec for media controller

* Add MediaAttachment.attached scope

* Simplify methods in media controller
2017-04-17 20:02:00 +02:00
Eugen 15ec4ae07b Fix #1972, fix #1870 - Fix special characters in XML, add tests (#1988)
Also improve efficiency of the mastodon:maintenance:add_static_avatars task
2017-04-17 19:58:54 +02:00
Eugen e43071a2f9 Fix #1897 - Return reblogged: false on unreblog (was wrongly named variable) (#1989) 2017-04-17 19:58:38 +02:00
Matt Jankowski 21a767dcfa Improve handling of HTTP_ACCEPT for webfinger (#2008)
This change includes:

- Improve the spec coverage for incoming request to the webfinger action
- For requests without an accept header (ie, what a browser might look like),
  return a JSON response.
- For requests with an explicit format of xml or json, return that format.
- For requests using an accept header, return that format.

Also adds failing spec showing webfinger does not return xml, which covers the
issue described in: https://github.com/tootsuite/mastodon/issues/1983
2017-04-17 19:58:03 +02:00
Tomohiro Suwa 3399dd7a66 Fix nil query_username (#2013) 2017-04-17 19:57:02 +02:00
alpaca-tc 630de52fdd Required foreign keys (#2003)
* Add `required: true` option to foreign column

* Fixes NoMethodError

```
> Favourite.new.valid?
NoMethodError: undefined method `reblog?' for nil:NilClass
```
2017-04-17 15:54:33 +02:00
Christophe Gesché 4082e1ac7f Update fr.jsx "clear" (Nettoyer peut-être ambigu) (#1987)
Un utiliser mal expérimenté pourrait comprendre "retirer les erreurs".
Ici il s'agit d'une suppression pure et simple, pas une épuration/nettoyage.

clear would be translated "remove" instead of "cleaning" Cleaning can be unterstood "keep but clean"
2017-04-17 15:15:14 +02:00
tom 6b8e95ea00 Make contents of boost confirmation dialog scroll (#1710)
This is necessary for boosting long posts on small screens - see this post for video: https://slime.global/@masklayer/102308
2017-04-17 12:27:19 +02:00
Patrick Figel ffb99325ca Add gif auto-play/pause preference
This introduces a new per-user preference called
"Auto-play animated GIFs", which is enabled by default. When a
user disables this setting, gifs in toots become click-to-play.

Previews of animated gifs were changed to display the video play
button so that users can distinguish them from regular images.

This setting also affects account avatars in the detailed account
view, which was changed to use the same hover-to-play mechanism
that is used for animated avatars in timelines.

Fixes #1652
2017-04-17 12:14:03 +02:00
Dale Price f3b86c1bda Add mask-icon.svg (#1572) (#1585)
* Add mask-icon (#1572)

* use updated svg logo for mask-icon
2017-04-17 10:39:54 +02:00
Hugo Gameiro 6685106daa Add Brazilian Portuguese and fix European Portuguese (#1966)
* update portuguese translation

added the missing fields and improved the translation

* pt translations fix

* improve last translation commit

* fix damn quotes

* add pt_br to index.jsx

* add pt-BR to import index.jsx

* add pt-BR to mastodon.jsx

* add pt-BR to settings_helper.rb

* add pt-BR to application.rb

* order alphabetically pt.jsx

* create pt-BR.jsx

* Create devise.pt-BR.yml

* language improvements to devise.pt.yml

* created doorkeeper.pt-BR.yml

* fixes to doorkeeper.pt.yml

* create pt-BR.yml

* improvements to pt.yml

* Create simple_form.pt-BR.yml

* Improvements to simple_form.pt.yml

* improvements to pt.yml
2017-04-17 10:38:27 +02:00
May Kittens Devour Your Soul 8ad6722eea Create hr.jsx (#1945)
* Create hr.jsx

Start of Croatian translation

* Update settings_helper.rb

* Update application.rb

* Update application.rb

* Update index.jsx
2017-04-17 10:38:13 +02:00
Yuki Nakagawa 548ff54714 Optimize user setting page for mobile browser (#1924)
* Remove overflow because it blocks scrolling on mobile safari.

* Add “-webkit-overflow-scrolling: touch;” to enable smooth scroll on mobile safari and other webkit browsers.

* Use radio buttons in user setting page.

Because select tags with long text are not fit in the width of mobile devices.

* Add flex property to fit labels to devise width.

* Change font size of select.

It causes auto zooming on mobile safari.
2017-04-17 10:37:00 +02:00
Yamagishi Kazutoshi 6afe70db95 Add human locales for zh-tw (#1984) 2017-04-17 10:35:06 +02:00
usagi-f b87a08e160 Add function color remaining text (#1980) 2017-04-17 10:34:33 +02:00
anon f8ae12909c Fix tiny typo, and added link to terms and conditions in confirmation email for Japanese. (#1975) (#1975) 2017-04-17 10:32:09 +02:00
saturday06 d87ee1167e Assign user locale on signup (#1982) 2017-04-17 10:29:08 +02:00
Keiji, Yoshimi 7a5086729a reduce unneed query when post without attachements. (#1907)
* reduce unneed query when post without attachements.

This commit reduce following query:

```
 MediaAttachment Load (0.9ms)  SELECT "media_attachments".* FROM "media_attachments" WHERE "media_attachments"."status
_id" IS NULL AND 1=0 ORDER BY id asc
```

* fixed for more simple changes.
2017-04-17 04:23:13 +02:00
Eugen 1955a3f444 Do not display "reset password" in admin UI for remote accounts (#1960) 2017-04-16 23:15:58 +02:00
Eugen 8ebed7fc68 Fix #1957 - WhatLanguage can return null. Fallback to 'en' (#1959) 2017-04-16 23:12:19 +02:00
Eugen f902a335f9 Fix #1870 - Strip control characters out of strings in AtomSerializer (#1876)
* Fix #1870 - Strip control characters out of strings in AtomSerializer

* Adjust according to comment by @alpaca-tc
2017-04-16 20:32:27 +02:00
Eugen e4af4898de Add language detection (#1772)
* Add language detection via WhatLanguage and (de)serialization of it through Atom

* Fix default language in ProcessFeedService

* Re-add newline before 'react-rails' Gem to fix groupings

Fixes Code Climate issue
2017-04-16 20:32:17 +02:00
Eugen 6d70a80263 Onboarding modal (#1883)
* Basic onboarding modal that's shown to users once

* Lay out pages 2 through 5, add images, style modals (#1509)

* Lay out pages 2 through 5

Added images and laid out pages 2 through 5 in the jsx file. SCSS will
come, still working on just seeing if this works at all.

* Fix jsx errors, add images to modal pages, style modal pages

* Add animations to onboarding pager changes, improve wording and styling

* Finishing touches on the onboarding

* Add missing propTypes

* Update wording
2017-04-16 20:32:00 +02:00
Matt Jankowski f87b51fda8 I18n health warnings (#1949)
* Rename admin.domain_block to admin.domain_blocks in prep for i18n improvement

* Use implicit controller/action path for i18n in admin/domain_blocks

* Add DomainBlock#accounts has_many

* Avoid i18n health warning for `en` locale by using symbol scope with :count

* Remove unused i18n key: plaintext_secret_html

* Remove unused i18n key two_factor_auth.warning

* Remove final will_paginate i18n keys

* Remove unused key two_factor_auth.recovery_codes

* Remove unused key: admin.reports.comment.none

* Remove unused reports. i18n namespace (moved to admin.reports)

* Ignore keys from locales which override activemodel and activerecord errors

* Revert "Remove unused key: admin.reports.comment.none"

This reverts commit 350ef2685fadc069e619bb6d1066190de195d942.

* Update i18n key reference to match moved location

* Add missing `en` keys to i18n

* Tell i18n-tasks to ignore missing attributes that dont need overwriting

* Add i18n-tasks unused to travis
2017-04-16 19:37:01 +02:00
alpaca-tc 19f63ff801 Check @recipient.user at the first (#1939) 2017-04-16 18:04:05 +02:00