akulubala / vue-product-zoomer

Zoom Prodct Image, useful for e-shop website
http://www.yoohooworld.com/demo.html
MIT License
292 stars 69 forks source link

Nuxt.js with Bootstrap Vue Ui #54

Closed metinjakupi closed 4 years ago

metinjakupi commented 4 years ago

Hello 👋, im using productzoomer with b-modal and it doesn't works below is the code is use

` <b-modal ref="my-modal" centered modal-class="wcModal" hide-footer hide-header >

`

and look how it looks inside of the modal Screenshot 2020-03-31 at 18 14 57

smaharj1 commented 4 years ago

Looks like the issue here is that the modal is not rendered when the page loads. I see that using nextTick would solve this issue.

@akulubala , can I grab this issue and work on it?

akulubala commented 4 years ago

Hi, @smaharj1 , thanks helping, I'll merge and publish your pull request later.

smaharj1 commented 4 years ago

Hi, @smaharj1 , thanks helping, I'll merge and publish your pull request later.

I think this would also solve #51

metinjakupi commented 4 years ago

@smaharj1 Does your fix works? Because i forked and changed window load thing added nextTick still same issue :/

smaharj1 commented 4 years ago

@smaharj1 Does your fix works? Because i forked and changed window load thing added nextTick still same issue :/

I didn't try it in Nuxt but I just did it regularly in a web app with vue bootstrap. changing it to nextTick worked for me. Also, do you have the ProductZoomer somewhere else in that same page? If that's the case, it won't work but that's a separate issue.

For reference,

Screen Shot 2020-04-01 at 6 12 23 PM
metinjakupi commented 4 years ago

@smaharj1 I added setTimeout (500) and it works.