diff options
author | Starfall <us@starfall.systems> | 2022-12-15 08:50:10 -0600 |
---|---|---|
committer | Starfall <us@starfall.systems> | 2022-12-15 08:50:10 -0600 |
commit | 957c21273ff42d5b2b4a5e16b7869bbb09aeb865 (patch) | |
tree | cffc6b225a011f48d664a7df17997d790df055df /app | |
parent | e073e66d3b0c8eeb1ed66c67881c33ab5924aa8c (diff) |
remove color-changing lightbox background, hope it just stays grey
Diffstat (limited to 'app')
-rw-r--r-- | app/javascript/mastodon/features/ui/components/media_modal.js | 19 | ||||
-rw-r--r-- | app/javascript/mastodon/features/ui/components/video_modal.js | 6 |
2 files changed, 0 insertions, 25 deletions
diff --git a/app/javascript/mastodon/features/ui/components/media_modal.js b/app/javascript/mastodon/features/ui/components/media_modal.js index ae937d1cd..7f50572e7 100644 --- a/app/javascript/mastodon/features/ui/components/media_modal.js +++ b/app/javascript/mastodon/features/ui/components/media_modal.js @@ -91,25 +91,6 @@ class MediaModal extends ImmutablePureComponent { componentDidMount () { window.addEventListener('keydown', this.handleKeyDown, false); - - this._sendBackgroundColor(); - } - - componentDidUpdate (prevProps, prevState) { - if (prevState.index !== this.state.index) { - this._sendBackgroundColor(); - } - } - - _sendBackgroundColor () { - const { media, onChangeBackgroundColor } = this.props; - const index = this.getIndex(); - const blurhash = media.getIn([index, 'blurhash']); - - if (blurhash) { - const backgroundColor = getAverageFromBlurhash(blurhash); - onChangeBackgroundColor(backgroundColor); - } } componentWillUnmount () { diff --git a/app/javascript/mastodon/features/ui/components/video_modal.js b/app/javascript/mastodon/features/ui/components/video_modal.js index f3ee89dfd..d3bd034cb 100644 --- a/app/javascript/mastodon/features/ui/components/video_modal.js +++ b/app/javascript/mastodon/features/ui/components/video_modal.js @@ -22,12 +22,6 @@ export default class VideoModal extends ImmutablePureComponent { componentDidMount () { const { media, onChangeBackgroundColor } = this.props; - - const backgroundColor = getAverageFromBlurhash(media.get('blurhash')); - - if (backgroundColor) { - onChangeBackgroundColor(backgroundColor); - } } render () { |