11/* eslint-disable jsx-a11y/label-has-associated-control */
22import React , { useState , useContext , useCallback } from 'react' ;
3- import { DashboardContext } from '../context/DashboardContext' ;
4- import '../stylesheets /AddModal.scss' ;
3+ import { DashboardContext } from '../../ context/DashboardContext' ;
4+ import './AddModal.scss' ;
55
6- import { TModalSetter } from '../components/Occupied/types/Occupied' ;
6+ import { TModalSetter } from '../../components/Occupied/types/Occupied' ;
7+ import ServiceDBType from './ServiceDBType' ;
8+ import ServicesDescription from './ServicesDescription' ;
79
810interface IFields {
911 typeOfService : string ;
@@ -60,7 +62,8 @@ const AddModal: React.FC<TModalSetter> = React.memo(({ setModal }) => {
6062 </ div >
6163 < form onSubmit = { handleSubmit } >
6264 < p > Required*</ p >
63- < div >
65+ < ServiceDBType typeOfService = { typeOfService } handleChange = { handleChange } database = { database } />
66+ { /* <div>
6467 <label htmlFor="serv-type">
6568 Type of Service<span>*</span>
6669 </label>
@@ -84,8 +87,9 @@ const AddModal: React.FC<TModalSetter> = React.memo(({ setModal }) => {
8487 <option value="SQL">SQL</option>
8588 <option value="MongoDB">MongoDB</option>
8689 </select>
87- </ div >
88- < div >
90+ </div> */ }
91+ < ServicesDescription URI = { URI } name = { name } description = { description } />
92+ { /* <div>
8993 <label htmlFor="db-uri">
9094 URI<span>*</span>
9195 </label>
@@ -121,7 +125,7 @@ const AddModal: React.FC<TModalSetter> = React.memo(({ setModal }) => {
121125 onChange={e => handleChange(e)}
122126 placeholder="Add a short description"
123127 />
124- </ div >
128+ </div> */ }
125129 < button > Submit</ button >
126130 </ form >
127131 </ div >
0 commit comments