fix(web): complete some ts type (#1148)

This commit is contained in:
Rhon Joe
2023-09-11 09:30:17 +08:00
committed by GitHub
parent 642842d61b
commit 38b9901274
5 changed files with 15 additions and 15 deletions

View File

@@ -239,7 +239,7 @@ const Completed: FC<ICompletedProps> = ({
// the current segment id and whether to show the modal
const [currSegment, setCurrSegment] = useState<{ segInfo?: SegmentDetailModel; showModal: boolean }>({ showModal: false })
const [searchValue, setSearchValue] = useState() // the search value
const [searchValue, setSearchValue] = useState<string>() // the search value
const [selectedStatus, setSelectedStatus] = useState<boolean | 'all'>('all') // the selected status, enabled/disabled/undefined
const [lastSegmentsRes, setLastSegmentsRes] = useState<SegmentsResponse | undefined>(undefined)

View File

@@ -100,7 +100,7 @@ const KeyValidator = ({
className='mb-4'
name={form.title}
placeholder={form.placeholder}
value={value[form.key] || ''}
value={value[form.key] as string || ''}
onChange={v => handleChange(form, v)}
onFocus={() => handleFocus(form)}
validating={validating}