@@ -124,7 +124,45 @@ function InfoModal(props) {
124
124
{ mode === VIDEO_MODE ? (
125
125
< VideoFeed topic = { CAMERA_FEED_TOPIC } updateRateHz = { 10 } webrtcURL = { props . webrtcURL } />
126
126
) : mode === TELEOP_MODE ? (
127
- < TeleopSubcomponent allowIncreasingForceThreshold = { true } allowRetaringFTSensor = { true } />
127
+ < View
128
+ style = { {
129
+ flex : 1 ,
130
+ flexDirection : 'column' ,
131
+ justifyContent : 'center' ,
132
+ alignItems : 'center' ,
133
+ width : '100%' ,
134
+ height : '100%'
135
+ } }
136
+ >
137
+ { props . showVideoFeedDuringTeleop ? (
138
+ < View
139
+ style = { {
140
+ flex : 5 ,
141
+ flexDirection : 'column' ,
142
+ justifyContent : 'center' ,
143
+ alignItems : 'center' ,
144
+ width : '100%' ,
145
+ height : '100%'
146
+ } }
147
+ >
148
+ < VideoFeed topic = { CAMERA_FEED_TOPIC } updateRateHz = { 10 } webrtcURL = { props . webrtcURL } />
149
+ </ View >
150
+ ) : (
151
+ < > </ >
152
+ ) }
153
+ < View
154
+ style = { {
155
+ flex : 7 ,
156
+ flexDirection : 'column' ,
157
+ justifyContent : 'center' ,
158
+ alignItems : 'center' ,
159
+ width : '100%' ,
160
+ height : '100%'
161
+ } }
162
+ >
163
+ < TeleopSubcomponent allowIncreasingForceThreshold = { true } allowRetaringFTSensor = { true } />
164
+ </ View >
165
+ </ View >
128
166
) : mode === SYSTEM_STATUS_MODE ? (
129
167
< div > System Status</ div >
130
168
) : (
@@ -141,7 +179,12 @@ InfoModal.propTypes = {
141
179
// Callback function for when the modal is hidden
142
180
onHide : PropTypes . func . isRequired ,
143
181
// The URL of the webrtc signalling server
144
- webrtcURL : PropTypes . string . isRequired
182
+ webrtcURL : PropTypes . string . isRequired ,
183
+ // Whether to show the video feed when teleoperating the robot
184
+ showVideoFeedDuringTeleop : PropTypes . bool . isRequired
185
+ }
186
+ InfoModal . defaultProps = {
187
+ showVideoFeedDuringTeleop : false
145
188
}
146
189
147
190
export default InfoModal
0 commit comments