hakimel / reveal.js

The HTML Presentation Framework
https://revealjs.com
MIT License
67.62k stars 16.63k forks source link

Iframes can not scroll on iOS #1613

Open Huxpro opened 8 years ago

Huxpro commented 8 years ago

We can still click into the iframe, but scrolling not works. It only occurs in iOS Safari and It's wired that the scroll(touchmove) also trigger the whole wrapper scrolling instead of the iframe.

Huxpro commented 8 years ago

There is a quick demonstration created with slides.com: http://slides.com/huxpro/deck-5#/1 View it in the iOS Safari

bnjmnt4n commented 8 years ago

Try adding the data-prevent-swipe attribute to the element (see the readme).

Huxpro commented 8 years ago

@demoneaux Hey bro. I tried data-prevent-swipe but no, it not works. Check out this demo on iOS, the scrolling is still disabled.

Huxpro commented 8 years ago

@demoneaux

After checking the implementation of data-prevent-swipe. I found It's actually achieve it by detecting the e.target but all touch events occurred inside the iframe are not fire a touch event on the iframe tag itself, which means e.target would never be iframe thus data-prevent-swipe would never work for iframe.

I convinced it's a bug instead of a question and should not be closed yet.

Huxpro commented 8 years ago

@hakimel @demoneaux Well. It should be re-opened.

G1305 commented 6 years ago

https://user-images.githubusercontent.com/34474564/34071282-78e7a24e-e28d-11e7-83c1-d4865c5ec915.png how to fix responsive dimensions?

G1305 commented 6 years ago

image how to fix mobile mode?

ESnark commented 5 years ago

Same problem in Android. Is there any progress?