aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormehekj <mehek.jethani@gmail.com>2022-05-01 23:17:09 -0400
committermehekj <mehek.jethani@gmail.com>2022-05-01 23:17:09 -0400
commit113b4ce125a125afd36b675e8d00844bca07c260 (patch)
tree3eaeb3bb8dc63c26de15db815d1ce0d5a3c8a434 /src
parent4d130a85618f4e88cf8fdb4763e1a21bb71e689b (diff)
centered controls
Diffstat (limited to 'src')
-rw-r--r--src/client/views/nodes/VideoBox.tsx6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/client/views/nodes/VideoBox.tsx b/src/client/views/nodes/VideoBox.tsx
index 80ad63e72..0344295bb 100644
--- a/src/client/views/nodes/VideoBox.tsx
+++ b/src/client/views/nodes/VideoBox.tsx
@@ -383,7 +383,6 @@ export class VideoBox extends ViewBoxAnnotatableComponent<ViewBoxAnnotatableProp
return !field ? <div key="loading">Loading</div> :
<div className="videoBox-contentContainer" key="container" style={{ mixBlendMode: "multiply" }}>
<div className={classname} ref={this.setContentRef} onPointerDown={(e) => this._fullScreen && e.stopPropagation()}>
- {/* {this._fullScreen && this.componentUI(0, 0)} */}
{this._fullScreen && <div className="videoBox-ui">
{this.UIButtons}
</div>}
@@ -702,9 +701,10 @@ export class VideoBox extends ViewBoxAnnotatableComponent<ViewBoxAnnotatableProp
const top = bounds?.top || 0;
const height = (bounds?.bottom || 0) - top;
const yPos = height * this.heightPercent / 100 - 60 + top;
- const width = Math.max(right - left - 20, 300);
+ const width = Math.max(right - left, 300);
+ const overflow = (width - right + left) / 2;
return this._fullScreen ? null : <div className="videoBox-ui-wrapper" style={{ clip: `rect(${boundsTop}px, 10000px, 10000px, ${boundsLeft}px)` }}>
- <div className="videoBox-ui" style={{ left: left + 10, top: yPos, width: width }}>
+ <div className="videoBox-ui" style={{ left: left - overflow, top: yPos, width: width }}>
{this.UIButtons}
</div>
</div>