0
0

fix: change mastodon limit

This commit is contained in:
オスカー、 2024-09-28 11:52:18 +09:00
parent d558a3020b
commit f5413366f9
Signed by: SWREI
GPG Key ID: 139D6573F92DA9F7
5 changed files with 5 additions and 4 deletions

View File

@ -28,7 +28,7 @@ const mapStateToProps = state => ({
anyMedia: state.getIn(['compose', 'media_attachments']).size > 0,
isInReply: state.getIn(['compose', 'in_reply_to']) !== null,
lang: state.getIn(['compose', 'language']),
maxChars: state.getIn(['server', 'server', 'configuration', 'statuses', 'max_characters'], 500),
maxChars: state.getIn(['server', 'server', 'configuration', 'statuses', 'max_characters'], 4096),
});
const mapDispatchToProps = (dispatch) => ({

View File

@ -5,6 +5,7 @@ module Account::Avatar
IMAGE_MIME_TYPES = ['image/jpeg', 'image/png', 'image/gif', 'image/webp'].freeze
LIMIT = 200.megabytes
MAX_PIXELS = 5_000_000 # 1500x500px
class_methods do
def avatar_styles(file)

View File

@ -5,7 +5,7 @@ module Account::Header
IMAGE_MIME_TYPES = ['image/jpeg', 'image/png', 'image/gif', 'image/webp'].freeze
LIMIT = 200.megabytes
MAX_PIXELS = 750_000 # 1500x500px
MAX_PIXELS = 5_000_000 # 1500x500px
class_methods do
def header_styles(file)

View File

@ -39,7 +39,7 @@ class Status < ApplicationRecord
include Status::SnapshotConcern
include Status::ThreadingConcern
MEDIA_ATTACHMENTS_LIMIT = 4
MEDIA_ATTACHMENTS_LIMIT = 16
rate_limit by: :account, family: :statuses

View File

@ -1,7 +1,7 @@
# frozen_string_literal: true
class StatusLengthValidator < ActiveModel::Validator
MAX_CHARS = 500
MAX_CHARS = 4096
URL_PLACEHOLDER_CHARS = 23
URL_PLACEHOLDER = 'x' * 23