Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
85 commits
Select commit Hold shift + click to select a range
a5fbe2f
Fix missing icons and subtitle in mobile boost/quote menu (#36038)
diondiondion Sep 8, 2025
b99c945
Revert change to EmojiHTML (#36051)
ChaosExAnima Sep 8, 2025
24fb862
Remove old search results with new search (#36053)
ChaosExAnima Sep 8, 2025
0153b49
Visibility modal: Match dropdown width to button (#36054)
diondiondion Sep 8, 2025
c0af458
Visibility dialog: Add visual dropdown indicator to Dropdown componen…
diondiondion Sep 8, 2025
e9e107c
New Crowdin Translations (automated) (#36045)
github-actions[bot] Sep 8, 2025
3ca4793
fix(deps): update dependency sass to v1.92.1 (#36046)
renovate[bot] Sep 8, 2025
9d0e73d
fix(deps): update dependency vite to v7.1.5 (#36056)
renovate[bot] Sep 8, 2025
2347354
Fix unresponsive areas around GIFV modals in some cases (#36059)
ClearlyClaire Sep 8, 2025
e7d7da9
chore(deps): update dependency rubocop-performance to v1.26.0 (#36047)
renovate[bot] Sep 8, 2025
13d970b
chore(deps): update dependency rubyzip to v3.1.0 (#36048)
renovate[bot] Sep 8, 2025
1c89909
Move quote post fallback removal import-time (#36055)
ClearlyClaire Sep 8, 2025
3c79c51
New Crowdin Translations (automated) (#36063)
github-actions[bot] Sep 9, 2025
cf20c5d
Show hint explaining post visibility when quoting a "quiet public" po…
diondiondion Sep 9, 2025
beca0fa
Upgrade transitive deps with security advisories to latest version (#…
renchap Sep 9, 2025
e2cbef7
Remove unused definitions from `OStatus::TagManager` (#36067)
ClearlyClaire Sep 9, 2025
66d73fc
Lighten up modal background colours in light mode (#36069)
diondiondion Sep 9, 2025
377e870
Improve accessibility of visibility modal dropdowns (#36068)
diondiondion Sep 9, 2025
e1dc960
Rework FEP-7888 implementation (#36064)
ClearlyClaire Sep 9, 2025
eb118d8
New Crowdin Translations (automated) (#36076)
github-actions[bot] Sep 10, 2025
ffaa672
Display Valkey version on admin dashboard (#35785)
ykzts Sep 10, 2025
8412127
Allow disabled dropdown menu items to be focused (#36078)
diondiondion Sep 10, 2025
2314583
chore(deps): update dependency hiredis-client to v0.25.3 (#36079)
renovate[bot] Sep 11, 2025
8a0d002
Add basic HTML parser for converting strings to React components (#36…
ChaosExAnima Sep 11, 2025
b60ee19
Fix QuoteAuthorization id not being properly serialized when federati…
ClearlyClaire Sep 11, 2025
75f7824
New Crowdin Translations (automated) (#36082)
github-actions[bot] Sep 11, 2025
f7289b2
Add migration to fill unset default quote policy based on default pos…
ClearlyClaire Sep 11, 2025
aacc829
Fix missing memoization in `Web::PushNotificationWorker` (#36085)
ClearlyClaire Sep 11, 2025
e35dfbf
Fix accpeted quotes sometimes not generating notifications (#36087)
ClearlyClaire Sep 11, 2025
8720444
Update labels in Posting defaults settings (#36084)
diondiondion Sep 11, 2025
84d1ba9
Allow removing deleted quotes from composer (#36080)
diondiondion Sep 11, 2025
946721f
Fix local quote notifications (#36091)
ClearlyClaire Sep 11, 2025
45a996f
Fix "Post revoked" label & "Pending" tooltip text (#36090)
diondiondion Sep 11, 2025
b59e06f
New Crowdin Translations (automated) (#36092)
github-actions[bot] Sep 12, 2025
30b31a8
Add schema.org markup to SEO-enabled posts (#36075)
Gargron Sep 12, 2025
82b2660
Fix quote posts with CW and no text being rejected (#36095)
ClearlyClaire Sep 12, 2025
0680342
Make Vite respect CSP for styles (#36089)
ChaosExAnima Sep 12, 2025
8e46252
chore(deps): update dependency pundit to v2.5.1 (#36097)
renovate[bot] Sep 15, 2025
93c977e
New Crowdin Translations (automated) (#36105)
github-actions[bot] Sep 15, 2025
38c0c9b
chore(deps): update dependency libvips to v8.17.2 (#36117)
renovate[bot] Sep 15, 2025
681a9cf
In composer, show when quoted post is also a quote post (#36119)
diondiondion Sep 15, 2025
4702e36
Fix: clicking a status header opens the status details, no longer nav…
Lycolia Sep 15, 2025
94dcf8c
fix(deps): update dependency axios to v1.12.0 [security] (#36116)
renovate[bot] Sep 15, 2025
f559134
Add `following_url` to `accounts` (#36093)
ClearlyClaire Sep 15, 2025
e4bb0fc
Add server-side support for handling posts with a quote policy allowi…
ClearlyClaire Sep 15, 2025
887e982
Don't show more than one quote removal hint on notifications page (#3…
diondiondion Sep 15, 2025
943cdc5
Add example post with manual quote approval policy to `dev:populate_s…
ClearlyClaire Sep 15, 2025
38fa010
Fix logged-out quote menu UX, simplify Interaction dialog copy (#36124)
diondiondion Sep 15, 2025
6c5a470
Use default quote policy setting in the absence of API parameter (#36…
ClearlyClaire Sep 15, 2025
96d0f6f
New Crowdin Translations (automated) (#36133)
github-actions[bot] Sep 16, 2025
41ab10f
Change wording of disabled quote state to “You are not allowed to quo…
ClearlyClaire Sep 16, 2025
d1402af
Change reblog button to immediately show the interaction modal when l…
ClearlyClaire Sep 16, 2025
d9b70bb
Fix login page linking to other pages within OAuth authorization flow…
Gargron Sep 16, 2025
9ac2a66
Merge remote-tracking branch 'parent/main' into upstream-20250917
kmycode Sep 17, 2025
f884e78
Fix test
kmycode Sep 17, 2025
3055afd
Fix applying user's default quote policy if API parameter is not spec…
tribela Sep 17, 2025
ff03938
New Crowdin Translations (automated) (#36143)
github-actions[bot] Sep 17, 2025
dfef7d9
Refactor: Replace all display name usage for new component (#36137)
ChaosExAnima Sep 17, 2025
72fff2e
chore(deps): update dependency ruby to v3.4.6 (#36135)
renovate[bot] Sep 17, 2025
de3692c
chore(deps): update docker.io/ruby docker tag to v3.4.6 (#36145)
renovate[bot] Sep 17, 2025
8a6ef2e
fix(deps): update dependency jsdom to v27 (#36107)
renovate[bot] Sep 17, 2025
2664bb6
Fix quote with CW but no text being shown without CW (#36150)
ClearlyClaire Sep 17, 2025
fbf093a
Fix CW being moved to text when posting quote posts with empty text (…
ClearlyClaire Sep 17, 2025
db0cd94
Bump version to v4.4.4 (#36152)
ClearlyClaire Sep 17, 2025
085e9ea
Create reusable Alert/Snackbar component (#36141)
diondiondion Sep 17, 2025
9076534
Fix posts when omitting quote policy and default policy is `nobody` (…
ClearlyClaire Sep 17, 2025
bb3f9ed
New Crowdin Translations (automated) (#36160)
github-actions[bot] Sep 18, 2025
c368a16
Fix translate button width in Safari (#36164)
diondiondion Sep 18, 2025
20ce109
Fix test
kmycode Sep 18, 2025
16a6e5c
Add click-through for quoted limited accounts (#36167)
ClearlyClaire Sep 18, 2025
e2171f5
Change quoted posts from silenced accounts not to be hidden (#36166)
ClearlyClaire Sep 18, 2025
48005c5
Add short-time HTTP caching of quote authorizations for public posts …
ClearlyClaire Sep 18, 2025
23efdf1
New Crowdin Translations (automated) (#36187)
github-actions[bot] Sep 19, 2025
b6bc42a
Fix getting `Create` and `Update` out of order (#36176)
ClearlyClaire Sep 19, 2025
a0a56a4
Fix processing of out-of-order `Update` as implicit updates (#36190)
ClearlyClaire Sep 19, 2025
938b54d
Switch stoplight back to upstream releases (#36188)
ClearlyClaire Sep 19, 2025
468cdf0
Merge remote-tracking branch 'parent/main' into upstream-20250917
kmycode Sep 19, 2025
4ff215f
Update dependency `rexml` (#36192)
ClearlyClaire Sep 19, 2025
ea7371c
Return 404 for quote approval when either quoted or quoting status is…
ClearlyClaire Sep 19, 2025
f316cd5
Enable GH actions scanning with CodeQL (#36193)
oneiros Sep 19, 2025
854aaec
Spec for newline in request lib initialize (#36170)
mjankowski Sep 19, 2025
f82c7f9
Fix test
kmycode Sep 20, 2025
d2892eb
Merge remote-tracking branch 'parent/main' into upstream-20250917
kmycode Sep 22, 2025
06e894e
Merge branch 'kb_development' into upstream-20250917
kmycode Sep 22, 2025
835413d
Fix reference link
kmycode Sep 22, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 2 additions & 2 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ jobs:
strategy:
fail-fast: false
matrix:
language: ['javascript', 'ruby']
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
language: ['actions', 'javascript', 'ruby']
# CodeQL supports [ 'actions', 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support

steps:
Expand Down
2 changes: 1 addition & 1 deletion .ruby-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.4.5
3.4.6
2 changes: 2 additions & 0 deletions .storybook/preview-body.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
<html class="no-reduce-motion">
</html>
28 changes: 28 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,34 @@

All notable changes to this project will be documented in this file.

## [4.4.4] - 2025-09-16

### Security

- Update dependencies

### Fixed

- Fix missing memoization in `Web::PushNotificationWorker` (#36085 by @ClearlyClaire)
- Fix unresponsive areas around GIFV modals in some cases (#36059 by @ClearlyClaire)
- Fix missing `beforeUnload` confirmation when a poll is being authored (#36030 by @ClearlyClaire)
- Fix processing of remote edited statuses with new media and no text (#35970 by @unfokus)
- Fix polls not being displayed in moderation interface (#35644 and #35933 by @ThisIsMissEm)
- Fix WebUI handling of deleted quoted posts (#35909 and #35918 by @ClearlyClaire and @diondiondion)
- Fix “Edit” and “Delete & Redraft” on a poll not inserting empty option (#35892 by @ClearlyClaire)
- Fix loading of some compatibility CSS on some configurations (#35876 by @shleeable)
- Fix HttpLog not being enabled with `RAILS_LOG_LEVEL=debug` (#35833 by @mjankowski)
- Fix self-destruct scheduler behavior on some Redis setups (#35823 by @ClearlyClaire)
- Fix `tootctl admin create` not bypassing reserved username checks (#35779 by @ClearlyClaire)
- Fix interaction policy changes in implicit updates not being saved (#35751 by @ClearlyClaire)
- Fix quote revocation not being streamed (#35710 by @ClearlyClaire)
- Fix export of large user archives by enabling Zip64 (#35850 by @ClearlyClaire)

### Changed

- Change labels for quote policy settings (#35893 by @ClearlyClaire)
- Change standalone “Share” page to redirect to web interface after posting (#35763 by @ChaosExAnima)

## [4.4.3] - 2025-08-05

### Security
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ARG BASE_REGISTRY="docker.io"

# Ruby image to use for base image, change with [--build-arg RUBY_VERSION="3.4.x"]
# renovate: datasource=docker depName=docker.io/ruby
ARG RUBY_VERSION="3.4.5"
ARG RUBY_VERSION="3.4.6"
# # Node.js version to use in base image, change with [--build-arg NODE_MAJOR_VERSION="20"]
# renovate: datasource=node-version depName=node
ARG NODE_MAJOR_VERSION="22"
Expand Down Expand Up @@ -183,7 +183,7 @@ FROM build AS libvips

# libvips version to compile, change with [--build-arg VIPS_VERSION="8.15.2"]
# renovate: datasource=github-releases depName=libvips packageName=libvips/libvips
ARG VIPS_VERSION=8.17.1
ARG VIPS_VERSION=8.17.2
# libvips download URL, change with [--build-arg VIPS_URL="https://github.com/libvips/libvips/releases/download"]
ARG VIPS_URL=https://github.com/libvips/libvips/releases/download

Expand Down
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ gem 'sidekiq-scheduler', '~> 6.0'
gem 'sidekiq-unique-jobs', '> 8'
gem 'simple_form', '~> 5.2'
gem 'simple-navigation', '~> 4.4'
gem 'stoplight', github: 'ClearlyClaire/stoplight', ref: 'f13e0c0d5e6d34af8d3cfc888871caa84237db42'
gem 'stoplight'
gem 'strong_migrations'
gem 'tty-prompt', '~> 0.23', require: false
gem 'twitter-text', '~> 3.1.0'
Expand Down
30 changes: 12 additions & 18 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,11 +1,3 @@
GIT
remote: https://github.com/ClearlyClaire/stoplight.git
revision: f13e0c0d5e6d34af8d3cfc888871caa84237db42
ref: f13e0c0d5e6d34af8d3cfc888871caa84237db42
specs:
stoplight (5.3.1)
zeitwerk

GIT
remote: https://github.com/mastodon/webpush.git
revision: 9631ac63045cfabddacc69fc06e919b4c13eb913
Expand Down Expand Up @@ -129,7 +121,7 @@ GEM
erubi (>= 1.0.0)
rack (>= 0.9.0)
rouge (>= 1.0.0)
bigdecimal (3.2.2)
bigdecimal (3.2.3)
bindata (2.5.1)
binding_of_caller (1.0.1)
debug_inspector (>= 1.2.0)
Expand Down Expand Up @@ -308,8 +300,8 @@ GEM
highline (3.1.2)
reline
hiredis (0.6.3)
hiredis-client (0.25.2)
redis-client (= 0.25.2)
hiredis-client (0.25.3)
redis-client (= 0.25.3)
hkdf (0.3.0)
htmlentities (4.3.4)
http (5.3.1)
Expand Down Expand Up @@ -645,7 +637,7 @@ GEM
public_suffix (6.0.2)
puma (6.6.1)
nio4r (~> 2.0)
pundit (2.5.0)
pundit (2.5.1)
activesupport (>= 3.0.0)
raabro (1.4.0)
racc (1.8.1)
Expand Down Expand Up @@ -725,7 +717,7 @@ GEM
reline
redcarpet (3.6.1)
redis (4.8.1)
redis-client (0.25.2)
redis-client (0.25.3)
connection_pool
regexp_parser (2.11.2)
reline (0.6.2)
Expand All @@ -735,7 +727,7 @@ GEM
responders (3.1.1)
actionpack (>= 5.2)
railties (>= 5.2)
rexml (3.4.1)
rexml (3.4.4)
rotp (6.3.0)
rouge (4.6.0)
rpam2 (4.0.2)
Expand Down Expand Up @@ -791,10 +783,10 @@ GEM
rubocop-i18n (3.2.3)
lint_roller (~> 1.1)
rubocop (>= 1.72.1)
rubocop-performance (1.25.0)
rubocop-performance (1.26.0)
lint_roller (~> 1.1)
rubocop (>= 1.75.0, < 2.0)
rubocop-ast (>= 1.38.0, < 2.0)
rubocop-ast (>= 1.44.0, < 2.0)
rubocop-rails (2.33.3)
activesupport (>= 4.2.0)
lint_roller (~> 1.1)
Expand All @@ -817,7 +809,7 @@ GEM
ruby-vips (2.2.5)
ffi (~> 1.12)
logger
rubyzip (3.0.2)
rubyzip (3.1.0)
rufus-scheduler (3.9.2)
fugit (~> 1.1, >= 1.11.1)
safety_net_attestation (0.4.0)
Expand Down Expand Up @@ -861,6 +853,8 @@ GEM
stackprof (0.2.27)
starry (0.2.0)
base64
stoplight (5.3.5)
zeitwerk
stringio (3.1.7)
strong_migrations (2.5.0)
activerecord (>= 7.1)
Expand Down Expand Up @@ -1092,7 +1086,7 @@ DEPENDENCIES
simplecov (~> 0.22)
simplecov-lcov (~> 0.8)
stackprof
stoplight!
stoplight
strong_migrations
test-prof
thor (~> 1.2)
Expand Down
3 changes: 2 additions & 1 deletion app/controllers/activitypub/contexts_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ def account_required?
end

def set_conversation
@conversation = Conversation.local.find(params[:id])
account_id, status_id = params[:id].split('-')
@conversation = Conversation.local.find_by(parent_account_id: account_id, parent_status_id: status_id)
end

def set_items
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ class ActivityPub::QuoteAuthorizationsController < ActivityPub::BaseController
before_action :set_quote_authorization

def show
expires_in 0, public: @quote.status.distributable? && public_fetch_mode?
expires_in 30.seconds, public: true if @quote.status.distributable? && public_fetch_mode?
render json: @quote, serializer: ActivityPub::QuoteAuthorizationSerializer, adapter: ActivityPub::Adapter, content_type: 'application/activity+json'
end

Expand All @@ -21,6 +21,8 @@ def pundit_user

def set_quote_authorization
@quote = Quote.accepted.where(quoted_account: @account).find(params[:id])
return not_found unless @quote.status.present? && @quote.quoted_status.present?

authorize @quote.status, :show?
rescue Mastodon::NotPermittedError
not_found
Expand Down
5 changes: 2 additions & 3 deletions app/controllers/concerns/api/interaction_policies_concern.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,9 @@ module Api::InteractionPoliciesConcern
extend ActiveSupport::Concern

def quote_approval_policy
# TODO: handle `nil` separately
return nil unless Mastodon::Feature.outgoing_quotes_enabled? && status_params[:quote_approval_policy].present?
return nil unless Mastodon::Feature.outgoing_quotes_enabled?

case status_params[:quote_approval_policy]
case status_params[:quote_approval_policy].presence || current_user.setting_default_quote_policy
when 'public'
Status::QUOTE_APPROVAL_POLICY_FLAGS[:public] << 16
when 'followers'
Expand Down
4 changes: 4 additions & 0 deletions app/helpers/application_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,10 @@ def app_store_url_android
'https://play.google.com/store/apps/details?id=org.joinmastodon.android'
end

def within_authorization_flow?
session[:user_return_to].present? && Rails.application.routes.recognize_path(session[:user_return_to])[:controller] == 'oauth/authorizations'
end

private

def storage_host_var
Expand Down
12 changes: 12 additions & 0 deletions app/helpers/statuses_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -67,4 +67,16 @@ def visibility_icon(status)
def prefers_autoplay?
ActiveModel::Type::Boolean.new.cast(params[:autoplay]) || current_user&.setting_auto_play_gif
end

def render_seo_schema(status)
json = ActiveModelSerializers::SerializableResource.new(
status,
serializer: SEO::SocialMediaPostingSerializer,
adapter: SEO::Adapter
).to_json

# rubocop:disable Rails/OutputSafety
content_tag(:script, json_escape(json).html_safe, type: 'application/ld+json')
# rubocop:enable Rails/OutputSafety
end
end
27 changes: 27 additions & 0 deletions app/javascript/entrypoints/public.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -351,6 +351,31 @@ const setInputDisabled = (
}
};

const setInputHint = (
input: HTMLInputElement | HTMLSelectElement,
hintPrefix: string,
) => {
const fieldWrapper = input.closest<HTMLElement>('.fields-group > .input');
if (!fieldWrapper) return;

const hint = fieldWrapper.dataset[`${hintPrefix}Hint`];
const hintElement =
fieldWrapper.querySelector<HTMLSpanElement>(':scope > .hint');

if (hint) {
if (hintElement) {
hintElement.textContent = hint;
} else {
const newHintElement = document.createElement('span');
newHintElement.className = 'hint';
newHintElement.textContent = hint;
fieldWrapper.appendChild(newHintElement);
}
} else {
hintElement?.remove();
}
};

Rails.delegate(
document,
'#account_statuses_cleanup_policy_enabled',
Expand Down Expand Up @@ -379,6 +404,8 @@ const updateDefaultQuotePrivacyFromPrivacy = (
);
if (!select) return;

setInputHint(select, privacySelect.value);

if (privacySelect.value === 'private') {
select.value = 'nobody';
setInputDisabled(select, true);
Expand Down
21 changes: 20 additions & 1 deletion app/javascript/mastodon/actions/compose_typed.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import type { Status } from '../models/status';

import { showAlert } from './alerts';
import { focusCompose } from './compose';
import { openModal } from './modal';

const messages = defineMessages({
quoteErrorUpload: {
Expand Down Expand Up @@ -110,7 +111,15 @@ export const quoteCompose = createAppThunk(

export const quoteComposeByStatus = createAppThunk(
(status: Status, { dispatch, getState }) => {
const composeState = getState().compose;
const state = getState();
const composeState = state.compose;
// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
const wasQuietPostHintModalDismissed: boolean =
// eslint-disable-next-line @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-member-access
state.settings.getIn(
['dismissed_banners', 'quote/quiet_post_hint'],
false,
);

if (composeState.get('is_uploading')) {
dispatch(showAlert({ message: messages.quoteErrorUpload }));
Expand All @@ -121,6 +130,16 @@ export const quoteComposeByStatus = createAppThunk(
status.getIn(['quote_approval', 'current_user']) !== 'manual'
) {
dispatch(showAlert({ message: messages.quoteErrorUnauthorized }));
} else if (
status.get('visibility') === 'unlisted' &&
!wasQuietPostHintModalDismissed
) {
dispatch(
openModal({
modalType: 'CONFIRM_QUIET_QUOTE',
modalProps: { status },
}),
);
} else {
dispatch(quoteCompose(status));
}
Expand Down
21 changes: 20 additions & 1 deletion app/javascript/mastodon/actions/importer/normalizer.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,15 @@ export function normalizeFilterResult(result) {
return normalResult;
}

function stripQuoteFallback(text) {
const wrapper = document.createElement('div');
wrapper.innerHTML = text;

wrapper.querySelector('.quote-inline')?.remove();

return wrapper.innerHTML;
}

export function normalizeStatus(status, normalOldStatus, options = undefined) {
const normalStatus = { ...status };

Expand Down Expand Up @@ -84,7 +93,7 @@ export function normalizeStatus(status, normalOldStatus, options = undefined) {
} else {
// If the status has a CW but no contents, treat the CW as if it were the
// status' contents, to avoid having a CW toggle with seemingly no effect.
if (normalStatus.spoiler_text && !normalStatus.content) {
if (normalStatus.spoiler_text && !normalStatus.content && !normalStatus.quote) {
normalStatus.content = normalStatus.spoiler_text;
normalStatus.spoiler_text = '';
}
Expand All @@ -102,6 +111,11 @@ export function normalizeStatus(status, normalOldStatus, options = undefined) {
normalStatus.spoilerHtml = emojify(escapeTextContentForBrowser(spoilerText), emojiMap);
normalStatus.hidden = expandSpoilers ? false : spoilerText.length > 0 || normalStatus.sensitive;

// Remove quote fallback link from the DOM so it doesn't mess with paragraph margins
if (normalStatus.quote) {
normalStatus.contentHtml = stripQuoteFallback(normalStatus.contentHtml);
}

if (normalStatus.url && !(normalStatus.url.startsWith('http://') || normalStatus.url.startsWith('https://'))) {
normalStatus.url = null;
}
Expand Down Expand Up @@ -152,6 +166,11 @@ export function normalizeStatusTranslation(translation, status) {
spoiler_text: translation.spoiler_text,
};

// Remove quote fallback link from the DOM so it doesn't mess with paragraph margins
if (status.get('quote')) {
normalTranslation.contentHtml = stripQuoteFallback(normalTranslation.contentHtml);
}

return normalTranslation;
}

Expand Down
1 change: 1 addition & 0 deletions app/javascript/mastodon/api_types/quotes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ export type ApiQuoteState = 'accepted' | 'pending' | 'revoked' | 'unauthorized';
export type ApiQuotePolicy =
| 'public'
| 'followers'
| 'following'
| 'nobody'
| 'unsupported_policy';
export type ApiUserQuotePolicy = 'automatic' | 'manual' | 'denied' | 'unknown';
Expand Down
Loading
Loading