You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(menu): add selectedIdentifier prop for controlled selection
- Add selectedIdentifier prop to native interfaces
- Update Android and iOS implementations to respect the prop
- Modify example app to demonstrate controlled usage
Use the `selectedIdentifier` prop to fully control which item is marked as selected. Update it in your `onMenuSelect` handler to keep iOS and Android behavior consistent.
| Selection State | Controlled via `selectedIdentifier`| use `selectedIdentifier` for cross-platform parity |
238
262
| Appearance | iOS system theme | White background with rounded corners |
239
263
240
264
## Example Project
@@ -272,6 +296,10 @@ yarn android
272
296
273
297
**Android:** Ensure your child component doesn't have `onPress` or other touch handlers that might interfere. The MenuView intercepts all touch events at the parent level.
274
298
299
+
### Checkmark not updating on iOS/Android
300
+
301
+
Pass and update `selectedIdentifier`. iOS does not shift the checkmark automatically—reflect selection in props via your `onMenuSelect` handler.
302
+
275
303
### Children prop is required
276
304
277
305
The MenuView component requires a child component to act as the trigger. Always wrap your trigger in the MenuView:
0 commit comments