From 59fcfbf78d25a011cced58bb7e126647628ece2d Mon Sep 17 00:00:00 2001 From: SophieMdl Date: Wed, 22 Jul 2020 09:53:53 +0200 Subject: [PATCH] replace select by single input --- src/modals/sections/SkillModal.js | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/src/modals/sections/SkillModal.js b/src/modals/sections/SkillModal.js index 38ecd275..457af683 100644 --- a/src/modals/sections/SkillModal.js +++ b/src/modals/sections/SkillModal.js @@ -7,17 +7,9 @@ import ModalEvents from '../../constants/ModalEvents'; import { getFieldProps } from '../../utils'; import DataModal from '../DataModal'; -const SKILL_LEVELS = [ - 'Fundamental Awareness', - 'Novice', - 'Intermediate', - 'Advanced', - 'Expert', -]; - const initialValues = { name: '', - level: SKILL_LEVELS[0], + level: '', }; const SkillModal = () => { @@ -25,9 +17,7 @@ const SkillModal = () => { const schema = Yup.object().shape({ name: Yup.string().required(t('shared.forms.validation.required')), - level: Yup.string() - .oneOf(SKILL_LEVELS) - .required(t('shared.forms.validation.required')), + level: Yup.string().required(t('shared.forms.validation.required')), }); return ( @@ -51,8 +41,7 @@ const SkillModal = () => {