import { string } from 'yup'

import { fields } from '@/constants/fields'

export const phoneNumberRule = string()
  .required()
  .matches(/^09\d{9}$/, ({ path }) => `${fields[path] || path} نامعتبر است`)
