From e9d86512089b4a0375a9c40f319f3e54c9d913f4 Mon Sep 17 00:00:00 2001 From: crockwave Date: Tue, 19 May 2020 16:37:25 -0500 Subject: [PATCH 1/2] Adjusted scss for sidebar mobile menu to prevent rendering problems --- app/styles/gabsocial/components/sidebar-menu.scss | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/app/styles/gabsocial/components/sidebar-menu.scss b/app/styles/gabsocial/components/sidebar-menu.scss index 538e22ca3..288ea46bd 100644 --- a/app/styles/gabsocial/components/sidebar-menu.scss +++ b/app/styles/gabsocial/components/sidebar-menu.scss @@ -1,11 +1,10 @@ .sidebar-menu { display: flex; - position: fixed; + position: absolute; flex-direction: column; width: 275px; - height: 100vh; + height: auto; top: 0; - bottom: 0; left: 0; background-color: #fff; transform: translateX(-275px); From 62b04be83b40bbccc8158540faa671fab1187149 Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Wed, 20 May 2020 19:19:53 -0500 Subject: [PATCH 2/2] Refactor video preload, disable for now --- app/gabsocial/features/video/index.js | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) diff --git a/app/gabsocial/features/video/index.js b/app/gabsocial/features/video/index.js index c1c8fad34..3e75469b3 100644 --- a/app/gabsocial/features/video/index.js +++ b/app/gabsocial/features/video/index.js @@ -374,8 +374,21 @@ class Video extends React.PureComponent { this.props.onCloseVideo(); } + getPreload = () => { + const { startTime, detailed } = this.props; + const { dragging, fullscreen } = this.state; + + if (startTime || fullscreen || dragging) { + return 'auto'; + } else if (detailed) { + return 'metadata'; + } else { + return 'none'; + } + } + render() { - const { preview, src, inline, startTime, onOpenVideo, onCloseVideo, intl, alt, detailed, sensitive, link, aspectRatio } = this.props; + const { preview, src, inline, onOpenVideo, onCloseVideo, intl, alt, detailed, sensitive, link, aspectRatio } = this.props; const { containerWidth, currentTime, duration, volume, buffer, dragging, paused, fullscreen, hovered, muted, revealed } = this.state; const progress = (currentTime / duration) * 100; @@ -400,16 +413,6 @@ class Video extends React.PureComponent { playerStyle.height = height; } - let preload; - - if (startTime || fullscreen || dragging) { - preload = 'auto'; - } else if (detailed) { - preload = 'metadata'; - } else { - preload = 'none'; - } - let warning; if (sensitive) { @@ -435,7 +438,7 @@ class Video extends React.PureComponent { ref={this.setVideoRef} src={src} poster={preview} - preload={preload} + // preload={this.getPreload()} loop role='button' tabIndex='0'