diff --git a/xtablo-expo/components/SwipeableChannelPreview.tsx b/xtablo-expo/components/SwipeableChannelPreview.tsx index 102a135..3b78baf 100644 --- a/xtablo-expo/components/SwipeableChannelPreview.tsx +++ b/xtablo-expo/components/SwipeableChannelPreview.tsx @@ -31,7 +31,6 @@ const ACTION_WIDTH = 80; export const SwipeableChannelPreview: React.FC< SwipeableChannelPreviewProps > = ({ channel, children }) => { - const id = channel.id ?? ""; const translateX = useSharedValue(0); const handleArchiveChannel = async () => { @@ -52,25 +51,25 @@ export const SwipeableChannelPreview: React.FC< { text: "Archiver", style: "destructive", - onPress: async () => { - try { - // Hide the channel for the current user - await channel.hide(); + // onPress: async () => { + // try { + // // Hide the channel for the current user + // await channel.hide(); - // Close the swipe action - translateX.value = withSpring(0); + // // Close the swipe action + // translateX.value = withSpring(0); - // Show success message - Alert.alert( - "Succès", - "La conversation a été archivée avec succès", - [{ text: "OK" }] - ); - } catch (error) { - console.error("Error archiving channel:", error); - Alert.alert("Erreur", "Impossible d'archiver la conversation"); - } - }, + // // Show success message + // Alert.alert( + // "Succès", + // "La conversation a été archivée avec succès", + // [{ text: "OK" }] + // ); + // } catch (error) { + // console.error("Error archiving channel:", error); + // Alert.alert("Erreur", "Impossible d'archiver la conversation"); + // } + // }, }, ], { cancelable: true }