callstack / callstack/react-native-paper

Menu onDismiss Animation

Offen
#4,813 0 Kommentare 2 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
feature request
Vorherrschende Sprache
TypeScript
Sterne
14.5k
Forks
2.2k
Ø Merge
5 T. 23 Std.
Gemergte PRs (30 T.)
12

Beschreibung

**Is your feature request related to a problem? Please describe.**
Some of the menu component's onDismiss handling ([1](https://github.com/callstack/react-native-paper/blob/ff0df5454eb13d6e8e2d8f1c87c0bca8bb3635f0/src/components/Menu/Menu.tsx#L643),[2](https://github.com/callstack/react-native-paper/blob/ff0df5454eb13d6e8e2d8f1c87c0bca8bb3635f0/src/components/Menu/Menu.tsx#L654)) does NOT call hide(); if I change the menu's visibility within ondismiss it cancels the animation entirely

**Describe the solution you'd like**
[make hide accepts a callback](https://github.com/lovegaoshi/azusa-player-mobile/blob/2648f55f4cb6c6dd72433a871a63249cbed79d1e/patches/react-native-paper%2B5.14.5.patch#L18), calls the callback at the end of the animation, and replace the onDismiss to `() => hide(onDismiss)`

**Describe alternatives you've considered**
I might have totally missed the memo on how to control the menu visibility via onDismiss.

**Additional context**
Add any other context or screenshots about the feature request here.

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.