export const WarningComponent = ({ text, rules, message }: WarningComponentProps) =>
rules.find(aRule => text.match(aRule) !== null)
? message
export const WarningComponent = ({ text, rules, message }: WarningComponentProps) =>
rules.find(aRule => text.match(aRule) !== null)
? message