catalog-model: deprecated usage of yup-based validators

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
This commit is contained in:
Patrik Oldsberg
2021-06-17 11:20:27 +02:00
parent daf29617d8
commit 74f8b8fcb1
2 changed files with 6 additions and 3 deletions
+3 -3
View File
@@ -10,7 +10,7 @@ import { JsonValue } from '@backstage/config';
import { SerializedError } from '@backstage/errors';
import * as yup from 'yup';
// @public (undocumented)
// @public @deprecated (undocumented)
export const analyzeLocationSchema: yup.ObjectSchema<{
location: LocationSpec;
}, object>;
@@ -316,7 +316,7 @@ export { LocationEntityV1alpha1 }
// @public (undocumented)
export const locationEntityV1alpha1Validator: KindValidator;
// @public (undocumented)
// @public @deprecated (undocumented)
export const locationSchema: yup.ObjectSchema<Location_2, object>;
// @public (undocumented)
@@ -326,7 +326,7 @@ export type LocationSpec = {
presence?: 'optional' | 'required';
};
// @public (undocumented)
// @public @deprecated (undocumented)
export const locationSpecSchema: yup.ObjectSchema<LocationSpec, object>;
// @public (undocumented)
@@ -17,6 +17,7 @@
import * as yup from 'yup';
import { LocationSpec, Location } from './types';
/** @deprecated */
export const locationSpecSchema = yup
.object<LocationSpec>({
type: yup.string().required(),
@@ -26,6 +27,7 @@ export const locationSpecSchema = yup
.noUnknown()
.required();
/** @deprecated */
export const locationSchema = yup
.object<Location>({
id: yup.string().required(),
@@ -35,6 +37,7 @@ export const locationSchema = yup
.noUnknown()
.required();
/** @deprecated */
export const analyzeLocationSchema = yup
.object<{ location: LocationSpec }>({
location: locationSpecSchema,