aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/collections/CollectionVideoView.tsx
diff options
context:
space:
mode:
authorTyler Schicke <tyler_schicke@brown.edu>2019-04-08 22:22:50 -0400
committerTyler Schicke <tyler_schicke@brown.edu>2019-04-08 22:22:50 -0400
commitcecbafdd8e42b1fa021a54fe624c3cf68e8645bd (patch)
tree4fc210bc1d903a99831a618b8e4556f10d8b503a /src/client/views/collections/CollectionVideoView.tsx
parentfbb5f2c19ffd1278d31b432a74ec3ae747b85894 (diff)
Renamed CollectionViewBase to CollectionSubView
Fixed bug with adding documents to PDF and videos
Diffstat (limited to 'src/client/views/collections/CollectionVideoView.tsx')
-rw-r--r--src/client/views/collections/CollectionVideoView.tsx14
1 files changed, 5 insertions, 9 deletions
diff --git a/src/client/views/collections/CollectionVideoView.tsx b/src/client/views/collections/CollectionVideoView.tsx
index afadfeefb..1acc76c85 100644
--- a/src/client/views/collections/CollectionVideoView.tsx
+++ b/src/client/views/collections/CollectionVideoView.tsx
@@ -1,20 +1,16 @@
-import { action, computed, observable, trace } from "mobx";
+import { action, observable, trace } from "mobx";
import { observer } from "mobx-react";
-import { Document } from "../../../fields/Document";
import { KeyStore } from "../../../fields/KeyStore";
import { ContextMenu } from "../ContextMenu";
-import { CollectionView } from "./CollectionView";
import { CollectionViewType, CollectionBaseView, CollectionRenderProps } from "./CollectionBaseView";
-import { CollectionViewProps } from "./CollectionViewBase";
import React = require("react");
-import { FieldId } from "../../../fields/Field";
import "./CollectionVideoView.scss"
import { CollectionFreeFormView } from "./collectionFreeForm/CollectionFreeFormView";
-import { FieldView } from "../nodes/FieldView";
+import { FieldView, FieldViewProps } from "../nodes/FieldView";
@observer
-export class CollectionVideoView extends React.Component<CollectionViewProps> {
+export class CollectionVideoView extends React.Component<FieldViewProps> {
private _intervalTimer: any = undefined;
private _player: HTMLVideoElement | undefined = undefined;
@@ -25,7 +21,7 @@ export class CollectionVideoView extends React.Component<CollectionViewProps> {
return FieldView.LayoutString(CollectionVideoView, fieldKey);
}
private get uIButtons() {
- let scaling = Math.min(1.8, this.props.ScreenToLocalTransform().transformDirection(1, 1)[0]);
+ let scaling = Math.min(1.8, this.props.ScreenToLocalTransform().Scale);
return ([
<div className="collectionVideoView-time" key="time" onPointerDown={this.onResetDown} style={{ transform: `scale(${scaling}, ${scaling})` }}>
<span>{"" + Math.round(this._currentTimecode)}</span>
@@ -109,7 +105,7 @@ export class CollectionVideoView extends React.Component<CollectionViewProps> {
}
private subView = (_type: CollectionViewType, renderProps: CollectionRenderProps) => {
- let props = { ...renderProps, ...this.props };
+ let props = { ...this.props, ...renderProps };
return (
<>
<CollectionFreeFormView {...props} />