1 files changed, 0 insertions(+), 20 deletions(-)
test.ts deleted-20| ... | @@ -1,20 +0,0 @@ | ||
| 1 | const option = collectionDetails | ||
| 2 | .fields | ||
| 3 | .find( | ||
| 4 | (field): field is { type: "Option", slug: string, validations: WebflowValidations["Option"] } => | ||
| 5 | field.slug === fieldData.path | ||
| 6 | )! | ||
| 7 | .validations; | ||
| 8 | |||
| 9 | if (fieldData.type | ||
| 10 | "Option" && typeof rawValue | ||
| 11 | "string") | ||
| 12 | return ( | ||
| 13 | ( | ||
| 14 | collectionDetails.fields. find (predicate: (field) ⇒ field.slug | ||
| 15 | | WebflowValidations["Option"] | ||
| 16 | | undefined | ||
| 17 | fieldData.path) ?. validations as | ||
| 18 | )?. options.find(predicate: (option) ⇒ option.id | ||
| 19 | rawValue) ?. name ?? fullMatch | ||
| 20 | ); | ||