1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2026-04-28 23:16:32 -04:00

Convert Form Components to TypeScript

This commit is contained in:
Mark McDowall
2024-10-26 14:54:23 -07:00
committed by GitHub
parent c114e2ddb7
commit 682d2b4e1b
158 changed files with 5225 additions and 6112 deletions
+2 -1
View File
@@ -8,6 +8,7 @@ import PageContent from 'Components/Page/PageContent';
import PageContentBody from 'Components/Page/PageContentBody';
import { icons } from 'Helpers/Props';
import { clear, fetch } from 'Store/Actions/parseActions';
import { InputChanged } from 'typings/inputs';
import getErrorMessage from 'Utilities/Object/getErrorMessage';
import translate from 'Utilities/String/translate';
import ParseResult from './ParseResult';
@@ -21,7 +22,7 @@ function Parse() {
const dispatch = useDispatch();
const onInputChange = useCallback(
({ value }: { value: string }) => {
({ value }: InputChanged<string>) => {
const trimmedValue = value.trim();
setTitle(value);
+2 -1
View File
@@ -10,6 +10,7 @@ import ModalFooter from 'Components/Modal/ModalFooter';
import ModalHeader from 'Components/Modal/ModalHeader';
import { icons } from 'Helpers/Props';
import { clear, fetch } from 'Store/Actions/parseActions';
import { InputChanged } from 'typings/inputs';
import getErrorMessage from 'Utilities/Object/getErrorMessage';
import translate from 'Utilities/String/translate';
import ParseResult from './ParseResult';
@@ -28,7 +29,7 @@ function ParseModalContent(props: ParseModalContentProps) {
const dispatch = useDispatch();
const onInputChange = useCallback(
({ value }: { value: string }) => {
({ value }: InputChanged<string>) => {
const trimmedValue = value.trim();
setTitle(value);