Skip to content

Commit

Permalink
fix: add background to component
Browse files Browse the repository at this point in the history
  • Loading branch information
fbaiodias committed Mar 22, 2018
1 parent f00975f commit 9e5e514
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 25 deletions.
1 change: 1 addition & 0 deletions src/video-recorder.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ const Wrapper = styled.div`
height: 100%;
overflow: hidden;
min-height: 119px;
background-color: #000;
`

const CameraView = styled.div`
Expand Down
48 changes: 23 additions & 25 deletions src/video-recorder.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,29 +6,27 @@ import VideoRecorder from './video-recorder'

const Wrapper = styled.div`
height: 100vh;
background-color: #000;
`
storiesOf('VideoRecorder', module)
.add('default', () => {
return (
<Wrapper>
<VideoRecorder
onRecordingComplete={(
videoBlob,
startedAt,
thumbnailBlob,
duration
) => {
const urlCreator = window.URL || window.webkitURL
const thumbUrl = urlCreator.createObjectURL(thumbnailBlob)
const videoUrl = urlCreator.createObjectURL(videoBlob)
console.log('Video Blob', videoBlob.size, videoBlob, videoUrl)
console.log('Thumb Blob', thumbnailBlob, thumbUrl)
console.log('Started:', startedAt)
console.log('Duration:', duration)
action('returned')
}}
/>
</Wrapper>
)
})
storiesOf('VideoRecorder', module).add('default', () => {
return (
<Wrapper>
<VideoRecorder
onRecordingComplete={(
videoBlob,
startedAt,
thumbnailBlob,
duration
) => {
const urlCreator = window.URL || window.webkitURL
const thumbUrl = urlCreator.createObjectURL(thumbnailBlob)
const videoUrl = urlCreator.createObjectURL(videoBlob)
console.log('Video Blob', videoBlob.size, videoBlob, videoUrl)
console.log('Thumb Blob', thumbnailBlob, thumbUrl)
console.log('Started:', startedAt)
console.log('Duration:', duration)
action('returned')
}}
/>
</Wrapper>
)
})

0 comments on commit 9e5e514

Please sign in to comment.