diff --git a/src/@types/MetaData.d.ts b/src/@types/MetaData.d.ts index f49368b38..d3a474282 100644 --- a/src/@types/MetaData.d.ts +++ b/src/@types/MetaData.d.ts @@ -25,8 +25,8 @@ export interface MetadataPublishForm { author: string license: string price: { - cost: string - tokensToMint: string + cost: number + tokensToMint: number } access: 'Download' | 'Compute' | string termsAndConditions: boolean diff --git a/src/components/pages/Publish/validation.ts b/src/components/pages/Publish/validation.ts index e2c948855..639afd984 100644 --- a/src/components/pages/Publish/validation.ts +++ b/src/components/pages/Publish/validation.ts @@ -7,8 +7,8 @@ export const validationSchema = Yup.object().shape({ name: Yup.string().required('Required'), author: Yup.string().required('Required'), price: Yup.object().shape({ - cost: Yup.string().required('Required'), - tokensToMint: Yup.string().required('Required') + cost: Yup.number().required('Required'), + tokensToMint: Yup.number().required('Required') }), files: Yup.array().required('Required').nullable(), description: Yup.string().required('Required'), @@ -28,8 +28,8 @@ export const initialValues: MetadataPublishForm = { name: '', author: '', price: { - cost: '', - tokensToMint: '' + cost: 0, + tokensToMint: null }, files: '', description: '',