laravel-spark-camera icon indicating copy to clipboard operation
laravel-spark-camera copied to clipboard

Webcam.js Error: No width and/or height for webcam. Please call set() first, or attach to a visible element.

Open DavidLambauer opened this issue 8 years ago • 5 comments

Hi! I just added your module in my fresh installed spark application. The button is displayed correctly and a modal opens when I click the rendered button. But instead of opening the camera, an alert message appear and says:

Webcam.js Error: No width and/or height for webcam. Please call set() first, or attach to a visible element.

My Spark Application is 3.0.5

DavidLambauer avatar Dec 30 '16 10:12 DavidLambauer

Any updates on this @DavidLambauer ? I'm trying to get this working.

midnightcipher avatar May 08 '17 05:05 midnightcipher

@ashleybakernz Nothing happened until I opened the Issue. Thank you for handling this one! :)

DavidLambauer avatar May 08 '17 06:05 DavidLambauer

@ashbakernz could you figure it out, yet? Want to make it together? I'll think this Repo isn't supported anymore, but I'll like the functionality. We may can combine the forces? xD

https://media.giphy.com/media/6IMXN40a9E9Es/giphy.gif

DavidLambauer avatar Jun 24 '17 05:06 DavidLambauer

It is supported, but I can't reproduce the issue on my end.

cretueusebiu avatar Jun 25 '17 23:06 cretueusebiu

This is because the css included after the video modal is not being parsed.

<style>
    #profile-photo-camera-preview,
    #profile-photo-camera-preview video {
        width: 100% !important;
        height: auto !important;
        min-width: 100px;
        min-height: 100px;
    }
</style>

- Templates should only be responsible for mapping the state to the UI. Avoid placing tags with side-effects in your templates, such as <style>, as they will not be parsed.
- Templates should only be responsible for mapping the state to the UI. Avoid placing tags with side-effects in your templates, such as <style>, as they will not be parsed.

danieladarve avatar Dec 19 '17 12:12 danieladarve