ionic-team / ionic-v1

The repo for Ionic 1.x. For the latest version of Ionic, please see https://github.com/ionic-team/ionic
Other
193 stars 187 forks source link

Ionic custom modal with native scroll #253

Open jgw96 opened 7 years ago

jgw96 commented 7 years ago

From @arondn2 on May 9, 2017 18:51

Ionic version: 1.3.1 I'm submitting a bug report Current behavior: I am trying to make a custom responsive modal with native scroll, without ion-modal directive, but with $ionicModal service. It works fine in desktop browsers, but in mobile browsers, the touchmove event in div.modal-backdrop is locking the scroll in the child element. I know that because removing this event in chrome’s console makes the modal work like I am expecting.

screen shot 2017-05-09 at 2 50 13 pm

Steps to reproduce: link to code here http://plnkr.co/edit/8KGnuj?p=preview. (open in a mobile browser or chrome’s device emulator).

Copied from original issue: driftyco/ionic#11582

tomIQME commented 5 years ago

any news on this?

ygyg70 commented 5 years ago

You can try to use the ion-modal directive add a css class to that tag, such as "responsive-modal", and use css to override the ionic style rules to match your needs.

tomIQME commented 5 years ago

My solution was to wrap the modal template in an ionic-content and adapt my css. Thanks for replying.