Factor out a separate auxpanel, and cleanup the maxHeight management
Basically two changes here: 1. Factor out auxpanel from RoomView 2. Rather than setting maxHeight attributes by poking directly into the DOM, pass them down as properties.
This commit is contained in:
@@ -22,6 +22,9 @@ module.exports = React.createClass({
|
||||
displayName: 'VideoFeed',
|
||||
|
||||
propTypes: {
|
||||
// maxHeight style attribute for the video element
|
||||
maxHeight: React.PropTypes.number,
|
||||
|
||||
// a callback which is called when the video element is resized
|
||||
// due to a change in video metadata
|
||||
onResize: React.PropTypes.func,
|
||||
@@ -43,7 +46,7 @@ module.exports = React.createClass({
|
||||
|
||||
render: function() {
|
||||
return (
|
||||
<video ref="vid">
|
||||
<video ref="vid" style={{maxHeight: this.props.maxHeight}}>
|
||||
</video>
|
||||
);
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user