From c4ea89dfd952e05da6edd0d47473fd4bd4834dae Mon Sep 17 00:00:00 2001 From: Claire Date: Mon, 8 Jun 2026 16:03:56 +0200 Subject: [PATCH] Change media attachment limit to 10000 characters (#39306) --- app/javascript/mastodon/features/alt_text_modal/index.tsx | 3 ++- app/models/media_attachment.rb | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app/javascript/mastodon/features/alt_text_modal/index.tsx b/app/javascript/mastodon/features/alt_text_modal/index.tsx index fc00e60a51d..fafd4609477 100644 --- a/app/javascript/mastodon/features/alt_text_modal/index.tsx +++ b/app/javascript/mastodon/features/alt_text_modal/index.tsx @@ -54,7 +54,8 @@ const messages = defineMessages({ }, }); -const MAX_LENGTH = 1500; +// TODO: use `description_limit` from the `/api/v2/instance` response +const MAX_LENGTH = 10000; type FocalPoint = [number, number]; diff --git a/app/models/media_attachment.rb b/app/models/media_attachment.rb index 1a65a447529..5ba5277d33d 100644 --- a/app/models/media_attachment.rb +++ b/app/models/media_attachment.rb @@ -40,7 +40,7 @@ class MediaAttachment < ApplicationRecord SHORTCODE_LENGTH = 19 - MAX_DESCRIPTION_LENGTH = 1_500 + MAX_DESCRIPTION_LENGTH = 10_000 MAX_DESCRIPTION_HARD_LENGTH_LIMIT = 10_000 IMAGE_LIMIT = 16.megabytes