Muuri: Elements in 'item' container unclickable in Mobile Safari.

Created on 22 Aug 2019  路  5Comments  路  Source: haltu/muuri

Anchors, images or anything within the 'item' container cannot be clicked. If i tap away and really try to trigger it it sometimes succeeds after a while, but even spamming doesn't always reliably trigger it.
I have tried to create my own dragPredicate which returns false immediately if any of my target elements are the event.target. I also changed the z-index and tried reposition the elements in different ways, but nothing works.

question

Most helpful comment

@emilime93 To fix that issue on ios I use next approach:
1) perfect scrollbar to be able to scroll
2) and dragCssProps option as follows:

dragCssProps: {
        touchAction: this.platform.IOS ? 'auto' : 'none'
}

All 5 comments

@emilime93 could you create a reduced test case and explain what you expect to happen and what really happens? Is this happening only on Mobile Safari?

Try disabling dragEnabled option. Mobile Safari has some incompatibilities with touch-action css property. See the dragCssProps section on the README file as well.

@emilime93 To fix that issue on ios I use next approach:
1) perfect scrollbar to be able to scroll
2) and dragCssProps option as follows:

dragCssProps: {
        touchAction: this.platform.IOS ? 'auto' : 'none'
}

@D2Phoenix Hah 馃槃clever! Another approach would be using a drag handle (dragStartPredicate.handle), but of course that would set restrictions to the UI/UX.

Okay, now that v0.9.0 is released I'd in general recommend using a dedicated dragHandle within the item element.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

syfgkjasdkn picture syfgkjasdkn  路  3Comments

aljimenez2 picture aljimenez2  路  3Comments

argie09 picture argie09  路  6Comments

claudchan picture claudchan  路  6Comments

dedurus picture dedurus  路  4Comments