nandorojo / zeego

Menus for React (Native) done right.
https://zeego.dev
MIT License
1.42k stars 41 forks source link

Open menu programatically #49

Closed hariettem closed 8 months ago

hariettem commented 1 year ago

Is there a way to get a ref and just do .open()? Or better yet, a open={true} flag?

nandorojo commented 9 months ago

I'm actually not sure. They differ quite a bit across platforms. It's possible for Web, will have to look into iOS.

midrizi commented 8 months ago

@nandorojo This would be quite useful, menu positioning is hard to get to look the same for both platforms without tinkering with component trigger width. Ex: Aligning menu to the right of the screen but wanting it to trigger for the full width of parent element.

nandorojo commented 8 months ago

I don't think Apple allows this. Is it really necessary? Can't it just be triggered by tapping/long pressing?

midrizi commented 8 months ago

@nandorojo On Android there is an prop that you can pass isAnchoredToRight but I'm not sure if there is something similar for iOS.

nandorojo commented 8 months ago

Isn't that entirely unrelated to this issue?

nandorojo commented 8 months ago

iOS won’t allow this so I am closing.