From a1ad2ad9519fda525858ba5aef86815a6f6385f2 Mon Sep 17 00:00:00 2001 From: ThibG Date: Fri, 26 Jun 2020 14:31:13 +0200 Subject: [PATCH] Change sensitive preview cards to not blur text (#14143) Also only require click-through for interactive embeds. --- .../mastodon/features/status/components/card.js | 8 +++----- app/javascript/styles/mastodon/components.scss | 5 ----- 2 files changed, 3 insertions(+), 10 deletions(-) diff --git a/app/javascript/mastodon/features/status/components/card.js b/app/javascript/mastodon/features/status/components/card.js index e35b1fd5f..0af7c54e4 100644 --- a/app/javascript/mastodon/features/status/components/card.js +++ b/app/javascript/mastodon/features/status/components/card.js @@ -6,7 +6,6 @@ import { FormattedMessage } from 'react-intl'; import punycode from 'punycode'; import classnames from 'classnames'; import Icon from 'mastodon/components/icon'; -import classNames from 'classnames'; import { useBlurhash } from 'mastodon/initial_state'; import { decode } from 'blurhash'; import { debounce } from 'lodash'; @@ -231,7 +230,7 @@ export default class Card extends React.PureComponent { const height = (compact && !embedded) ? (width / (16 / 9)) : (width / ratio); const description = ( -
+
{title} {!(horizontal || compact) &&

{trim(card.get('description') || '', maxDescription)}

} {provider} @@ -239,7 +238,7 @@ export default class Card extends React.PureComponent { ); let embed = ''; - let canvas = ; + let canvas = ; let thumbnail = ; let spoilerButton = ( ); spoilerButton = ( -
+
{spoilerButton}
); @@ -305,7 +304,6 @@ export default class Card extends React.PureComponent { {embed} {description} - {!revealed && spoilerButton} ); } diff --git a/app/javascript/styles/mastodon/components.scss b/app/javascript/styles/mastodon/components.scss index e3da780ef..7a22aeb04 100644 --- a/app/javascript/styles/mastodon/components.scss +++ b/app/javascript/styles/mastodon/components.scss @@ -3105,11 +3105,6 @@ a.status-card { flex: 1 1 auto; overflow: hidden; padding: 14px 14px 14px 8px; - - &--blurred { - filter: blur(2px); - pointer-events: none; - } } .status-card__description {