mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-26 09:36:21 +00:00
fix: limpiar html remoto
This commit is contained in:
parent
b8e7e53ebd
commit
01c042b512
3 changed files with 12 additions and 10 deletions
|
@ -3,18 +3,18 @@
|
|||
.py-2
|
||||
%dl
|
||||
%dt= t('.profile_name')
|
||||
%dd= sanitize remote_profile['name']
|
||||
%dd= text_plain remote_profile['name']
|
||||
|
||||
%dt= t('.preferred_name')
|
||||
%dd= sanitize remote_profile['preferredUsername']
|
||||
%dd= text_plain remote_profile['preferredUsername']
|
||||
|
||||
%dt= t('.profile_id')
|
||||
%dd
|
||||
= link_to sanitize(remote_profile['id'])
|
||||
= link_to text_plain(remote_profile['id'])
|
||||
|
||||
- if remote_profile['published'].present?
|
||||
%dt= t('.profile_published')
|
||||
%dd
|
||||
= render 'layouts/time', time: sanitize(remote_profile['published'])
|
||||
= render 'layouts/time', time: text_plain(remote_profile['published'])
|
||||
%dt= t('.profile_summary')
|
||||
%dd= sanitize remote_profile['summary']
|
||||
|
|
|
@ -3,9 +3,9 @@
|
|||
= render 'components/checkbox', id: actor_moderation.id, name: 'actor_moderation[]', value: actor_moderation.id, data: { target: 'select-all.input' }
|
||||
.col-11
|
||||
%h4
|
||||
= link_to sanitize(profile['name']), site_actor_moderation_path(id: actor_moderation)
|
||||
= link_to text_plain(profile['name']), site_actor_moderation_path(id: actor_moderation)
|
||||
.mb-3
|
||||
= sanitize profile['summary'].html_safe
|
||||
= sanitize profile['summary']
|
||||
|
||||
-# Botones de Moderación
|
||||
- cache actor_moderation do
|
||||
|
|
|
@ -1,24 +1,26 @@
|
|||
-# Componente Comentario
|
||||
|
||||
- in_reply_to = text_plain comment['inReplyTo']
|
||||
|
||||
.row.no-gutters
|
||||
.col-1
|
||||
= render 'components/checkbox', id: comment['id']
|
||||
.col-11
|
||||
.d-flex.flex-row.align-items-center.justify-content-between
|
||||
%h4.mb-0
|
||||
%a{ href: comment['attributedTo'] }= sanitize profile['preferredUsername']
|
||||
%a{ href: text_plain(comment['attributedTo']) }= text_plain profile['preferredUsername']
|
||||
%small
|
||||
= render 'layouts/time', time: comment['published']
|
||||
- if comment['inReplyTo'].present?
|
||||
- if in_reply_to.present?
|
||||
%dl
|
||||
%dt.d-inline
|
||||
%small= t('.reply_to')
|
||||
%dd.d-inline
|
||||
%small
|
||||
%a{ href: comment['inReplyTo'] }= sanitize comment['inReplyTo']
|
||||
%a{ href: in_reply_to) }= in_reply_to
|
||||
%div
|
||||
- if comment['summary'].present?
|
||||
= render 'layouts/details', summary: comment['summary'], summary_class: 'h5' do
|
||||
= render 'layouts/details', summary: text_plain(comment['summary']), summary_class: 'h5' do
|
||||
= sanitize comment['content']
|
||||
- else
|
||||
= sanitize comment['content']
|
||||
|
|
Loading…
Reference in a new issue