import * as Haptics from 'expo-haptics'

// fire-and-forget wrappers so a haptic can never fail or delay a flow

export const hapticSuccess = (): void => {
  void Haptics.notificationAsync(
    Haptics.NotificationFeedbackType.Success,
  ).catch(() => {})
}

export const hapticSelection = (): void => {
  void Haptics.selectionAsync().catch(() => {})
}

export const hapticWarning = (): void => {
  void Haptics.notificationAsync(
    Haptics.NotificationFeedbackType.Warning,
  ).catch(() => {})
}
