Skip to content

Quote posts from servers that use RE: <url> HTML but don't populate the structured quote API field now render correctly#25

Merged
cbl merged 1 commit into
mainfrom
fix/quote-post-rendering
Apr 16, 2026
Merged

Quote posts from servers that use RE: <url> HTML but don't populate the structured quote API field now render correctly#25
cbl merged 1 commit into
mainfrom
fix/quote-post-rendering

Conversation

@cbl

@cbl cbl commented Apr 16, 2026

Copy link
Copy Markdown
Member

Fixed

  • RE: paragraph not stripped — regex used [^<]* inside anchors, which fails on Mastodon's <span class="invisible/ellipsis"> link markup. Changed to [\s\S]*?.
  • Quote card not rendering — API returns quoted_status (snake_case) but code only checked quotedStatus (camelCase). Now handles both.
  • StatusDetailMain missing quotes — the detail view component had no StatusQuote rendering at all.

Changed

  • useCleanContent.ts — always strips RE: paragraph (no longer gated on hasQuote); exports extractQuoteUrl()
  • Status.vue / StatusDetailMain.vue — snake_case-safe quote extraction; detail view now renders StatusQuote
  • @[acct]/[id]/index.vue — wires @status-click on StatusDetailMain for quote navigation

Added

  • useQuoteResolver.ts — watches feed statuses, resolves unresolved quote URLs via v2.search, patches the status store reactively
  • index.vue (home feed) — calls useQuoteResolver on allStatuses
  • StatusQuoteRendering.test.ts — 7 component tests (camelCase, snake_case, null, both components)
  • useCleanContent.test.ts — 2 new cases for nested-span anchors and extractQuoteUrl

@cbl cbl merged commit ea9cd9d into main Apr 16, 2026
2 checks passed
@cbl cbl deleted the fix/quote-post-rendering branch April 16, 2026 11:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant