From 5c95c352c300614a6720cf222d4f1f1ef3ae5c83 Mon Sep 17 00:00:00 2001 From: Evelyn Eastmond Date: Tue, 21 May 2019 14:03:48 -0400 Subject: [PATCH 01/11] Trying VideoStep component. --- src/components/cards/cards.jsx | 49 ++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) diff --git a/src/components/cards/cards.jsx b/src/components/cards/cards.jsx index 83e40bf49..9c194d422 100644 --- a/src/components/cards/cards.jsx +++ b/src/components/cards/cards.jsx @@ -3,6 +3,7 @@ import React, {Fragment} from 'react'; import classNames from 'classnames'; import {FormattedMessage} from 'react-intl'; import Draggable from 'react-draggable'; +import bindAll from 'lodash.bindall'; import styles from './card.css'; @@ -109,6 +110,54 @@ const VideoStep = ({video, dragging}) => ( ); +/* class VideoStep extends React.Component { + constructor (props) { + super(props); + bindAll(this, [ + 'handleLoadIFrame' + ]); + } + componentDidMount () { + console.log('Video1 step did mount.'); + } + handleLoadIFrame () { + console.log('iframe loaded!!!'); + // window._wq = window._wq || []; + window._wq.push({ + id: 'ir0j8ljsgm', + onReady: function (video) { + console.log('I got a handle to the video!', video); + } + }); + // console.log('Wistia', document.getElementsByTagName('iframe')[0].contentWindow.location.href); + } + render () { + return ( +
+ {this.props.dragging ? ( +
+ ) : null} +