Commit Graph

1396 Commits (f9d7ec89711e29a7c1fdf060abf9599b65c9f515)

Author SHA1 Message Date
alpaca-tc f9d7ec8971 ActiveRecord::Relation does not respond to `#id` (#1834) 8 years ago
Matt Jankowski 40fd1de488 Account search service refactor (#1791)
* Begin coverage for account search service

* Coverage for hashtag query

* Coverage for calling local vs remote find based on domain presence

* Spec to check that exact matches are not duped

* Coverage of resolve option

* Coverage for account being provided

* Start to refactor account search service

* Isolate query username and domain methods

* Isolate exact_match method

* Extract methods for local and remote results

* Simplify local vs remote and account isoliation

* Extract methods for local and remote results

* Simplify de-dupe of exact match

* Simplify logic to check for non exact remotes

* Cache some methods

* Remove nil from exact_match from results array

* Return exact matches first

* Use find_remote even with no domain

Account.find_local is just an alias for Account.find_remote(user, nil) - so we
can not bother with the conditional here, and call find_remote directly.
8 years ago
ThibG 31f0bcf804 Refresh webfinger (#1323)
* Refresh local info for remote accounts when webfinger returns new values

It only refreshes account info if one of the URLs or the public-key changes,
in which cases it refreshes the full info, re-downloading the feeds from that
user.

Some special handling should probably be done when the public key changes,
but I have been unable to find any use for it in Mastodon yet.

* Re-fetch remote users we aren't subscribed to.

This might induce performance issues, we might want to only do that for users
we explicitly attempted to subscribe but failed to.

* Refactor changes

* Do not refresh existing remote account details more than once a day

* Avoid re-fetching webfinger info in tests unless otherwise specified
8 years ago
Matt Jankowski 09540192c9 Rename admin/accounts_helper to admin/filter_helper (#1816)
- Add some spec coverage for both methods
- Add explicit constant call-outs for where the params are from
8 years ago
Koala Yeung 08059ddda9 jslint: fix jslint warnings (#1704)
* jslint: remove trailing space

* jslint: fix no-nested-ternary issue

Follow the jslint [no-nested-ternary](http://eslint.org/docs/rules/no-nested-ternary)
rule. Rewritten ternary with if-then.
8 years ago
Koala Yeung ec9999cdfe Update Traditional Chinese, HK (zh-HK) translation (#1759)
* Fix missing string in javascript locale (zh-HK)

* Change javascript locale (zh-HK)

* Fix some other strings that were still English.
* Improve `search.status_by`.
* Fix `notification.follow`. ("開始開始你")
* Changes according to user feedback.
  * "Back": "較前顯示" -> "返回"
  * "Home": "家" -> "主頁"

* Update ruby locale (zh-HK)

* Fix missing translation
* Normalize yml
* Update translation strings
8 years ago
Fjoerfoks 4ba6acd518 Update nl.jxs (#1766)
Some rewording and switching to infinitive localization.
8 years ago
Ratmir Karabut 5d8d827436 Update Russian translation (#1733)
* 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
8 years ago
Matt Jankowski cde1f37d93 Use site title on tags#show page (#1802) 8 years ago
Thor Harald Johansen 4bebeb27d3 More Norwegian translations (#1805)
* Working translation for Norwegian.

* Fixes to Norwegian translation.

* Further adjustments to Norwegian translation.

* Further adjustments to Norwegian translation.

* Yet more improvements to the Norwegian translation.

* More Norwegian translations. Better terminology.
8 years ago
Joachim Viide ef879a8839 Send initial state in a <script type="application/json"> tag (#1806) 8 years ago
Alex Dunn 0655f16cc1 [css] reduce spacing between text elements on about pages (#1510) 8 years ago
ThibG a9529d3b4b Allow running mastodon on a different domain as the one used for identifying users (#1267)
* Allow running mastodon on a different domain as the one used for identifying users

* Alter documentation of WEB_DOMAIN to make clear it shouldn't be used unless the admin knows what they are doing

* Compare to web_domain instead of local_domain when dealing with feeds/API

* Correctly identify mentions to local accounts

Mentions URLs point to the person's web profile, i.e., the user page served on WEB_DOMAIN.
8 years ago
Patrick Figel fe8dd58bc1 Add list of muted user to UI and Getting Started (#1799)
Add the same UI that already exists for blocked users for muted
ones and add it to the "Getting Started" menu.
8 years ago
Matt Jankowski f5cd138323 Improve i18n chooser (#1804)
* Add locale spec with failing locale plus region check

* Use a more accurate locale when supplied by browser headers

Previously we were using a matching option which would use the first locale
available which matched the locale portion, even if a region was specified.

This changes to first try to find an exact match, and then fall back to the
region, and then fall back to the  default.

* Clean up default_locale method
8 years ago
Luc Didry fa89deb4eb Add title attribute to URLs in statuses (#1755)
Since URLs in statuses are truncated, it would be pleasant to see the
full URL when hovering the URL (like on twitter, yes).
8 years ago
Matt Jankowski 26a892dd90 Fix invalid byte sequence issue in nl.jsx (#1751) 8 years ago
Effy Elden 8321884eef Change usage of gsub to delete, as per Code Climate/Rubocop recommendation (#1753) 8 years ago
西小倉宏信 290e8ef854 Remove .keep in models (#1748) 8 years ago
JP DeVries 1467515d3d Use landmark regions on columns (#1732)
Closes mastodon#1720
8 years ago
Matt Jankowski 8b74aa4217 Admin reports controller improvements (#1714)
* Simplify admin/reports controller filtering for index

* Rename parameter to resolved

* Fix issue where reports view could not access filter_link_to

* Add coverage for admin/reports controller

* DRY up resolution of related reports for target account

* Clean up admin/reports routes

* Add Report#statuses method

* DRY up current account action taken params

* Rubocop styles
8 years ago
maxypy a6807201d2 Implementing Subresource Integrity (#1729)
* Add sprockets-rails to Gemfile

* Add sprockets-rails to Gemfile.lock

* Update show.html.haml

* Update index.html.haml

* Update admin.html.haml

* Update auth.html.haml

* Update embedded.html.haml

* Update public.html.haml
8 years ago
Eugen Rochko 41c697fd81 Merge branch 'master' of git://github.com/matteoaquila/mastodon into matteoaquila-master 8 years ago
Eugen c5afe573da Fix drag & drop overlay not appearing on firefox (#1721) 8 years ago
Thomas Citharel c0c56db0fa Translate admin (#1702)
* Translate the domain_block panel

Signed-off-by: Thomas Citharel <tcit@tcit.fr>

* Translate PubSubHubbub section

Signed-off-by: Thomas Citharel <tcit@tcit.fr>

* translate account section and correct typos

* move reports translation & translate sidebar

Signed-off-by: Thomas Citharel <tcit@tcit.fr>

* normalize l18n
8 years ago
Alyssa Ross 55b56e3f95 terms: remove redundant words (#1578)
"at least X" and "X or older" have identical meanings.
Using both together feels a little jarring.
8 years ago
R Tucker c4d39b1b3d quick typo fix in en.jsx: Rejec -> Reject (#1701) 8 years ago
Eugen ac54da9394 Fix #1220, fix #1671 - Hook up comment box to the Redux comment value (#1699)
Fix username styling regression introduced in #1063
Fix report screen background regression introduced in #1415
8 years ago
Eugen 043862f411 Fix #1609, fix #1628 - Revert #1397 (#1700)
When transmitting data in a HTML-encoded element like <content type="html" />,
relying on newlines being preserved is not wise, since HTML by itself
does not care for newlines - it cares for <p> and <br>

Additional fix: reset NSFW toggle after sending toot
8 years ago
INAGAKI Hiroshi 5619099564 translation: Fix comment out issue in en.jsx (#1698) 8 years ago
Koala Yeung ce80d0b0a9 Fix minor jslint issue (#1697)
* Undefined propType in react component `ColumnSettings`.
  Add proper PropTypes definition.
8 years ago
Eugen Rochko 5f8155482a Add overlay style to buttons, continue video after expanding it 8 years ago
Matteo Aquila efcf9448da Update settings_helper.rb 8 years ago
Eugen Rochko e70b84b1dc Merge branch 'videolightbox' of git://github.com/blackle/mastodon into blackle-videolightbox 8 years ago
Rachel H 9362700137 Convert emoji shortnames when sending status (#1666) 8 years ago
Koala Yeung 1206627c59 Add Dutch translation (nl) (#1682)
* Dutch language files for Ruby code

 * Created RoR translation ymls:
   * config/locales/devise.nl.yml
   * config/locales/doorkeeper.nl.yml
   * config/locales/nl.yml
   * config/locales/simple_form.nl.yml

 * Modified RoR config and helper
   * app/helpers/settings_helper.rb
   * config/application.rb

* Dutch language javascript locale

 * Created javascript locale files:
   * app/assets/javascripts/components/locales/index.jsx
   * app/assets/javascripts/components/locales/nl.jsx

 * Reference the newly created locale files:
   * app/assets/javascripts/components/containers/mastodon.jsx

* Fix syntax error in locale file (nl)

* Fix missing translate in js locale (nl)

* Convert all ruby Dutch locale (nl) file to utf8

Fix yml conversion issues.

* Fix duplicated key in devise.nl.yml

* Fix indentation error in doorkeeper.nl.yml
8 years ago
Isabelle Knott edefcfcf42 Fix issue where 'sensitive content click to show' item takes up whole screen on public view (#1692) 8 years ago
Matt Jankowski b330d1f000 Organize coverage dirs (#1695)
* Add `Presenters` group to SimpleCov configuration

* Move validators to app/validators, add to simplecov config
8 years ago
Eugen 1a5a54eb4b Merge branch 'master' into master 8 years ago
Isabelle Knott 447b8bc44e Do not show media attachment as og:image if it was marked as NSFW (#1693) 8 years ago
Matt Jankowski 093879c177 Fix language export variables (#1689)
* Fix naming of JS locale constants

* Improve the translation instructions re: const names
8 years ago
Matteo Aquila 905a4faa1c Update settings_helper.rb 8 years ago
Matteo Aquila 5355b7d930 Update settings_helper.rb 8 years ago
blackle 00cc3066a2 Allow video to be expanded into lightbox 8 years ago
YOSHIOKA Eiichiro a57d30c680 [l10n] ja: update missing Japanese translations (#1687) 8 years ago
Musee U 467d32fce3 [l10n] ja: update missing Japanese translations (#1684) 8 years ago
Hugo Gameiro 282bb55c3c fix Portuguese translation (#1661)
* update portuguese translation

added the missing fields and improved the translation

* pt translations fix

* improve last translation commit

* fix damn quotes
8 years ago
新都心(Neet Shin) 0e4479bb3a Update Japanese translation files (#1640)
* [l10n] ja: Improve Japanese Translations

* ja: about: Fix highlighting
* ja: Update Translations
* ja: Translate admin settings

Signed-off-by: lindwurm <lindwurm.q@gmail.com>

* Update ja.jsx

* Update doorkeeper.ja.yml

* Update ja.yml

* Update ja.jsx

* Update ja.jsx
8 years ago
Ratmir Karabut af7e880df5 Update Russian translation (#1570)
* Add Russian translation (ru)

* Fix a missing comma

* Fix the wording for better consistency

* Update Russian translation

* Arrange Russian setting alphabetically

* Fix syntax error
8 years ago
Svetlozar Todorov aa7bf1515c Fix #624 - Add localization for Bulgarian (#645)
* Add translation files and declarations for Bulgarian

* Add a bunch of translations to bg.jsx

* Add rest of translations to bg.jsx

* Add devise translations

* Fix devise translations
8 years ago