Skip to content

Commit

Permalink
Update to v4.3.0
Browse files Browse the repository at this point in the history
  • Loading branch information
SlyEcho authored Oct 9, 2024
2 parents ab36c15 + ce73f82 commit 1be3c92
Show file tree
Hide file tree
Showing 8 changed files with 45 additions and 2 deletions.
17 changes: 17 additions & 0 deletions .github/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Mastodon fork for [est.social](https://est.social/)

Forked from [Mastodon](https://github.com/mastodon/mastodon/).

This is mainly to increase character limit and to manage localization ahead of the official releases.

## Changes made

Up the char limit to 10,000:

- [instance_serializer.rb](app/serializers/rest/instance_serializer.rb)
- [v1/instance_serializer.rb](app/serializers/rest/v1/instance_serializer.rb)
- [status_length_validator.rb](app/validators/status_length_validator.rb)

Increase the feed item count to 10,000:

- [feed_manager.rb](app/lib/feed_manager.rb)
11 changes: 11 additions & 0 deletions app/javascript/mastodon/locales/et.json
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@
"alert.rate_limited.title": "Kiiruspiirang",
"alert.unexpected.message": "Tekkis ootamatu viga.",
"alert.unexpected.title": "Oih!",
"alt_text_badge.title": "Alternatiivtekst",
"announcement.announcement": "Teadaanne",
"attachments_list.unprocessed": "(töötlemata)",
"audio.hide": "Peida audio",
Expand Down Expand Up @@ -221,6 +222,8 @@
"domain_block_modal.they_cant_follow": "Sellest serverist ei saa keegi sind jälgida.",
"domain_block_modal.they_wont_know": "Nad ei tea, et nad on blokeeritud.",
"domain_block_modal.title": "Blokeerida domeen?",
"domain_block_modal.you_will_lose_num_followers": "Sult kaob {followersCount, plural, one {{followersCountDisplay} jälgija} other {{followersCountDisplay} jälgijat}} ja {followingCount, plural, one {{followingCountDisplay} inimene} other {{followingCountDisplay} inimest}}, keda sa ise jälgid.",
"domain_block_modal.you_will_lose_relationships": "Sa kaotad kõik oma jälgijad ja inimesed, kes sind jälgivad sellest serverist.",
"domain_block_modal.you_wont_see_posts": "Sa ei näe selle serveri kasutajate postitusi ega teavitusi.",
"domain_pill.activitypub_lets_connect": "See võimaldab sul ühenduda inimestega ja nendega suhelda mitte ainult Mastodonis, vaid ka teistes suhtlusrakendustes.",
"domain_pill.activitypub_like_language": "ActivityPub on nagu keel, mida Mastodon räägib teiste suhtlusvõrgustikega.",
Expand Down Expand Up @@ -433,6 +436,8 @@
"lightbox.close": "Sulge",
"lightbox.next": "Järgmine",
"lightbox.previous": "Eelmine",
"lightbox.zoom_in": "Näita algsuuruses",
"lightbox.zoom_out": "Näita kõik",
"limited_account_hint.action": "Näita profilli sellegipoolest",
"limited_account_hint.title": "See profiil on peidetud {domain} moderaatorite poolt.",
"link_preview.author": "{name} poolt",
Expand Down Expand Up @@ -511,6 +516,7 @@
"notification.label.private_reply": "Privaatne vastus",
"notification.label.reply": "Vastus",
"notification.mention": "Mainimine",
"notification.mentioned_you": "{name} mainis sind",
"notification.moderation-warning.learn_more": "Vaata lisa",
"notification.moderation_warning": "Said modereerimise hoiatuse",
"notification.moderation_warning.action_delete_statuses": "Mõni su postitus on eemaldatud.",
Expand Down Expand Up @@ -847,6 +853,11 @@
"upload_error.poll": "Küsitlustes pole faili üleslaadimine lubatud.",
"upload_form.audio_description": "Kirjelda kuulmispuudega inimeste jaoks",
"upload_form.description": "Kirjelda vaegnägijatele",
"upload_form.drag_and_drop.instructions": "Vajuta tühikut või enterit, et tõsta manus. Lohistamise ajal kasuta nooleklahve, et manust liigutada teatud suunas. Vajuta tühikut või enterit uuesti, et paigutada manus oma uuele kohale, või escape tühistamiseks.",
"upload_form.drag_and_drop.on_drag_cancel": "Lohistamine tühistati. Manus {item} on asetatud.",
"upload_form.drag_and_drop.on_drag_end": "Manus {item} on asetatud.",
"upload_form.drag_and_drop.on_drag_over": "Manus {item} on liigutatud.",
"upload_form.drag_and_drop.on_drag_start": "Tõstetud on manus {item}.",
"upload_form.edit": "Muuda",
"upload_form.thumbnail": "Muuda pisipilti",
"upload_form.video_description": "Kirjelda kuulmis- või nägemispuudega inimeste jaoks",
Expand Down
2 changes: 1 addition & 1 deletion app/lib/feed_manager.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ class FeedManager
include Redisable

# Maximum number of items stored in a single feed
MAX_ITEMS = 800
MAX_ITEMS = 10_000

# Number of items in the feed since last reblog of status
# before the new reblog will be inserted. Must be <= MAX_ITEMS
Expand Down
5 changes: 5 additions & 0 deletions app/serializers/rest/instance_serializer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ class ContactSerializer < ActiveModel::Serializer

attributes :domain, :title, :version, :source_url, :description,
:usage, :thumbnail, :icon, :languages, :configuration,
:max_toot_chars,
:registrations, :api_versions

has_one :contact, serializer: ContactSerializer
Expand Down Expand Up @@ -111,6 +112,10 @@ def api_versions
Mastodon::Version.api_versions
end

def max_toot_chars
StatusLengthValidator::MAX_CHARS
end

private

def registrations_enabled?
Expand Down
5 changes: 5 additions & 0 deletions app/serializers/rest/v1/instance_serializer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ class REST::V1::InstanceSerializer < ActiveModel::Serializer
attributes :uri, :title, :short_description, :description, :email,
:version, :urls, :stats, :thumbnail,
:languages, :registrations, :approval_required, :invites_enabled,
:max_toot_chars,
:configuration

has_one :contact_account, serializer: REST::AccountSerializer
Expand Down Expand Up @@ -98,6 +99,10 @@ def invites_enabled
UserRole.everyone.can?(:invite_users)
end

def max_toot_chars
StatusLengthValidator::MAX_CHARS
end

private

def instance_presenter
Expand Down
2 changes: 1 addition & 1 deletion app/validators/status_length_validator.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

class StatusLengthValidator < ActiveModel::Validator
MAX_CHARS = 500
MAX_CHARS = 10_000
URL_PLACEHOLDER_CHARS = 23
URL_PLACEHOLDER = 'x' * 23

Expand Down
1 change: 1 addition & 0 deletions config/locales/doorkeeper.et.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ et:
error:
title: Ilmnes viga
new:
prompt_html: "%{client_name} soovib saada ligipääsu su kontole. <strong>Kinnita see taotlus ainult siis, kui sa tunned ja usaldad seda allikat.</strong>"
review_permissions: Lubade ülevaade
title: Autoriseerimine vajalik
show:
Expand Down
4 changes: 4 additions & 0 deletions config/locales/et.yml
Original file line number Diff line number Diff line change
Expand Up @@ -875,6 +875,9 @@ et:
message_html: Serverireegleid pole defineeritud.
sidekiq_process_check:
message_html: Ühtegi Sidekiq protsessi pole %{value} järjekorra jaoks. Sidekiq seadistus vajab üle vaatamist
software_version_check:
action: Vaata saadaval uuendusi
message_html: Mastodoni uuendus on saadaval.
software_version_critical_check:
action: Vaata saadaolevaid uuendusi
message_html: Saadaval on Mastodoni kriitiline uuendus, uuenda nii kiiresti kui võimalik.
Expand Down Expand Up @@ -1692,6 +1695,7 @@ et:
delete: Konto kustutamine
development: Arendus
edit_profile: Muuda profiili
export: Eksport
featured_tags: Esile toodud sildid
import: Impordi
import_and_export: Import / eksport
Expand Down

0 comments on commit 1be3c92

Please sign in to comment.