mirror of
https://github.com/formbricks/formbricks.git
synced 2026-04-19 19:21:15 -05:00
Fixed where empty pattern was passed when switching from phone
This commit is contained in:
@@ -79,8 +79,8 @@ export default function OpenTextQuestion({
|
||||
type={question.inputType}
|
||||
onInput={(e) => handleInputChange(e.currentTarget.value)}
|
||||
autoFocus={autoFocus}
|
||||
pattern={question.inputType === "phone" ? "[+][0-9]+" : undefined}
|
||||
title={question.inputType === "phone" ? "Enter a valid phone number (+123...)" : undefined}
|
||||
pattern={question.inputType === "phone" ? "[+][0-9 ]+" : ".*"}
|
||||
title={question.inputType === "phone" ? "Enter a valid phone number" : undefined}
|
||||
className={`block w-full rounded-md border
|
||||
border-slate-100
|
||||
bg-slate-50 p-2 shadow-sm focus:border-slate-500 focus:outline-none focus:ring-0 sm:text-sm`}
|
||||
@@ -96,7 +96,7 @@ export default function OpenTextQuestion({
|
||||
type={question.inputType}
|
||||
onInput={(e) => handleInputChange(e.currentTarget.value)}
|
||||
autoFocus={autoFocus}
|
||||
pattern={question.inputType === "phone" ? "[+][0-9]+" : undefined}
|
||||
pattern={question.inputType === "phone" ? "[+][0-9 ]+" : ".*"}
|
||||
title={question.inputType === "phone" ? "Please enter a valid phone number" : undefined}
|
||||
className={`block w-full rounded-md border
|
||||
border-slate-100
|
||||
|
||||
Reference in New Issue
Block a user