Skip to content

Commit

Permalink
fix: make extra definitions optional
Browse files Browse the repository at this point in the history
  • Loading branch information
pooriamehregan committed Sep 6, 2023
1 parent bf60364 commit c73f3e6
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 40 deletions.
12 changes: 6 additions & 6 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -111,40 +111,44 @@ export const schema = Yup.object().shape({
.nullable()
})
}),
folkeligForklaring: Yup.object().shape({
kildebeskrivelse: Yup.object()
.nullable()
.shape({
forholdTilKilde: Yup.string().nullable(),
kilde: Yup.array()
.of(
Yup.object().shape({
tekst: Yup.string()
.nullable()
.min(2, localization.validationMin2),
uri: Yup.string().nullable().url(localization.validationUrl)
})
)
.nullable()
})
}),
rettsligForklaring: Yup.object().shape({
kildebeskrivelse: Yup.object()
.nullable()
.shape({
forholdTilKilde: Yup.string().nullable(),
kilde: Yup.array()
.of(
Yup.object().shape({
tekst: Yup.string()
.nullable()
.min(2, localization.validationMin2),
uri: Yup.string().nullable().url(localization.validationUrl)
})
)
.nullable()
})
}),
folkeligForklaring: Yup.object()
.shape({
kildebeskrivelse: Yup.object()
.nullable()
.shape({
forholdTilKilde: Yup.string().nullable(),
kilde: Yup.array()
.of(
Yup.object().shape({
tekst: Yup.string()
.nullable()
.min(2, localization.validationMin2),
uri: Yup.string().nullable().url(localization.validationUrl)
})
)
.nullable()
})
})
.nullable(),
rettsligForklaring: Yup.object()
.shape({
kildebeskrivelse: Yup.object()
.nullable()
.shape({
forholdTilKilde: Yup.string().nullable(),
kilde: Yup.array()
.of(
Yup.object().shape({
tekst: Yup.string()
.nullable()
.min(2, localization.validationMin2),
uri: Yup.string().nullable().url(localization.validationUrl)
})
)
.nullable()
})
})
.nullable(),
merknad: tekstMedSpraakKodeArray,
eksempel: tekstMedSpraakKodeArray,
fagområde: tekstMedSpraakKodeArray,
Expand Down

0 comments on commit c73f3e6

Please sign in to comment.