From 2c767f44bf8d453bf118a0d131b1ca6e1187b96b Mon Sep 17 00:00:00 2001 From: Thibaut Girka Date: Tue, 7 May 2019 22:12:11 +0200 Subject: Fix front-end crash when a video has a blurhash and is hidden behind a CW --- app/javascript/flavours/glitch/features/video/index.js | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'app/javascript') diff --git a/app/javascript/flavours/glitch/features/video/index.js b/app/javascript/flavours/glitch/features/video/index.js index 8291ff3c8..2e0d59d47 100644 --- a/app/javascript/flavours/glitch/features/video/index.js +++ b/app/javascript/flavours/glitch/features/video/index.js @@ -166,6 +166,10 @@ export default class Video extends React.PureComponent { setCanvasRef = c => { this.canvas = c; + + if (c && this.props.blurhash) { + this._decode(); + } } handleMouseDownRoot = e => { @@ -310,6 +314,8 @@ export default class Video extends React.PureComponent { } _decode () { + if (!this.canvas) return; + const hash = this.props.blurhash; const pixels = decode(hash, 32, 32); -- cgit From 3191c3b349f67442f3ae42be6e1b141e2392a293 Mon Sep 17 00:00:00 2001 From: Thibaut Girka Date: Wed, 8 May 2019 00:04:48 +0200 Subject: Fix tabs bar on mobile Fixes #1037 --- app/javascript/flavours/glitch/styles/components/index.scss | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'app/javascript') diff --git a/app/javascript/flavours/glitch/styles/components/index.scss b/app/javascript/flavours/glitch/styles/components/index.scss index f12f8b7fa..63211392e 100644 --- a/app/javascript/flavours/glitch/styles/components/index.scss +++ b/app/javascript/flavours/glitch/styles/components/index.scss @@ -565,8 +565,8 @@ font-size: 14px; font-weight: 500; border-bottom: 2px solid lighten($ui-base-color, 8%); - transition: all 200ms linear; - transition-property: background; + transition: all 50ms linear; + transition-property: border-bottom, background, color; .fa { font-weight: 400; @@ -583,8 +583,6 @@ &:active { @include multi-columns('screen and (min-width: 631px)') { background: lighten($ui-base-color, 14%); - transition: all 100ms linear; - transition-property: background; } } -- cgit From d4d4e84324701243ce05930f45b2dc876e38c7d0 Mon Sep 17 00:00:00 2001 From: Thibaut Girka Date: Fri, 10 May 2019 11:27:59 +0200 Subject: Fix media description confirmation modal Fixes #1040 --- .../glitch/features/compose/containers/compose_form_container.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'app/javascript') diff --git a/app/javascript/flavours/glitch/features/compose/containers/compose_form_container.js b/app/javascript/flavours/glitch/features/compose/containers/compose_form_container.js index 2da0770d3..814f9a97a 100644 --- a/app/javascript/flavours/glitch/features/compose/containers/compose_form_container.js +++ b/app/javascript/flavours/glitch/features/compose/containers/compose_form_container.js @@ -1,5 +1,5 @@ import { connect } from 'react-redux'; -import { defineMessages } from 'react-intl'; +import { defineMessages, injectIntl } from 'react-intl'; import ComposeForm from '../components/compose_form'; import { changeCompose, @@ -133,4 +133,4 @@ const mapDispatchToProps = (dispatch, { intl }) => ({ }); -export default connect(mapStateToProps, mapDispatchToProps)(ComposeForm); +export default injectIntl(connect(mapStateToProps, mapDispatchToProps)(ComposeForm)); -- cgit