Add haptic feedback to VoiceFAB on press

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Sergei 2026-01-27 16:26:18 -08:00
parent 9b4d39fdc5
commit 66a8395602

View File

@ -15,6 +15,7 @@ import {
} from 'react-native'; } from 'react-native';
import { Ionicons } from '@expo/vector-icons'; import { Ionicons } from '@expo/vector-icons';
import { useSafeAreaInsets } from 'react-native-safe-area-context'; import { useSafeAreaInsets } from 'react-native-safe-area-context';
import * as Haptics from 'expo-haptics';
import { AppColors, BorderRadius } from '@/constants/theme'; import { AppColors, BorderRadius } from '@/constants/theme';
import { useVoiceCall } from '@/contexts/VoiceCallContext'; import { useVoiceCall } from '@/contexts/VoiceCallContext';
@ -66,8 +67,9 @@ export function VoiceFAB({ onPress, style, disabled = false }: VoiceFABProps) {
} }
}, [isCallActive, scale, opacity]); }, [isCallActive, scale, opacity]);
// Press animation // Press animation with haptic feedback
const handlePressIn = () => { const handlePressIn = () => {
Haptics.impactAsync(Haptics.ImpactFeedbackStyle.Medium);
Animated.spring(scale, { Animated.spring(scale, {
toValue: 0.9, toValue: 0.9,
friction: 5, friction: 5,