Use Marked and marked-mfm for MFM rendering (#29)

Reviewed-on: https://akkoma.dev/AkkomaGang/pleroma-fe/pulls/29
Co-authored-by: sfr <sol@solfisher.com>
Co-committed-by: sfr <sol@solfisher.com>
This commit is contained in:
sfr 2022-07-15 09:57:17 +00:00 committed by floatingghost
parent 28d5a55352
commit 931ed3d3c7
9 changed files with 3812 additions and 2817 deletions

View file

@ -44,18 +44,13 @@
<div
v-if="!hideSubjectStatus && !(singleLine && status.summary_raw_html)"
>
<MFMContent
v-if="renderMisskeyMarkdown && status.mfm_content"
class="RichContent text media-body mfm-post-content"
:status="status"
/>
<RichContent
v-else
:class="{ '-single-line': singleLine }"
class="text media-body"
:html="status.raw_html"
:emoji="status.emojis"
:handle-links="true"
:mfm="renderMisskeyMarkdown && (status.media_type === 'text/x.misskeymarkdown')"
:greentext="mergedConfig.greentext"
:attentions="status.attentions"
@parseReady="onParseReady"