react-native-ios-context-menu
                                
                                 react-native-ios-context-menu copied to clipboard
                                
                                    react-native-ios-context-menu copied to clipboard
                            
                            
                            
                        [SOLVED] Pressable Event duplicates longPress with navigation
I recently updated react-native-ios-context-menu and noticed the behavior is not the same as before.
I have a list of cards and when you click it it navigate to the associated profile page. Before that, the longpress was correctly handled, but now if I release my finger as soon as I feel the vibration of the longPress, the shortPress fires too. But if I press long enough, the shortPress is not fired and everything works fine.
Expected behavior
https://github.com/user-attachments/assets/2d8dc7ef-c160-46ec-8760-c0d728ea0a35
Not too long press behavior
https://github.com/user-attachments/assets/4e7def60-9d1e-4a02-b905-14b103d20e30
It was working very well on 1.X
My package.json:
"expo": "^51.0.24",
"@react-navigation/native": "^6.1.6",
"react-native-elements": "^3.4.3",
"react-native-ios-context-menu": "^2.5.1",
"react-native-ios-utilities": "^4.4.5",
"react": "18.2.0",
"react-native": "0.74.3"
The code I use for this :
import { ListItem } from "react-native-elements";
import { ContextMenuView } from "react-native-ios-context-menu";
import { useNavigation } from "@react-navigation/native";
const Card = () => {
  const navigation = useNavigation();
  return (
    <ContextMenuView
      menuConfig={{
        menuTitle: "",
        menuItems: [
          {
            actionKey: "key-00",
            actionTitle: "Edit",
          },
          {
            actionKey: "key-01",
            actionTitle: "Delete",
            menuAttributes: ["destructive"],
          },
        ],
      }}
      onPressMenuItem={({ nativeEvent }) => {
        switch (nativeEvent.actionKey) {
          case "key-00":
            navigation.navigate("EditPartner", { partnerId: partner._id });
            break;
          case "key-01":
            Alert.alert(
              "Are you sure you want to remove this partner?",
              "This action is irreversible and cannot be undone.",
              [
                {
                  text: "Cancel",
                  style: "cancel",
                },
                {
                  text: "Delete",
                  onPress: () => deletePartner(partner._id),
                  style: "destructive",
                },
              ]
            );
            break;
        }
      }}
    >
      <ListItem
        onPress={() =>
          navigation.navigate("Partner", {
            partnerId: partner._id,
          })
        }
      >
        <ListItem.Content>
          <ListItem.Title>
            <Text>Title</Text>
          </ListItem.Title>
        </ListItem.Content>
      </ListItem>
    </ContextMenuView>
  );
};
I can't find anywhere in the doc a navigation inside the ContextMenuView.