1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2026-04-20 21:54:58 -04:00

Improve typings in FormInputGroup

This commit is contained in:
Mark McDowall
2025-01-03 09:47:17 -08:00
parent ebb0aab2f5
commit aad8ba0f9b
44 changed files with 321 additions and 281 deletions
@@ -1,5 +1,4 @@
/* eslint-disable no-bitwise */
import PropTypes from 'prop-types';
import React, { SyntheticEvent } from 'react';
import { InputChanged } from 'typings/inputs';
import translate from 'Utilities/String/translate';
@@ -67,7 +66,7 @@ function formatPermissions(permissions: number) {
return result;
}
interface UMaskInputProps {
export interface UMaskInputProps {
name: string;
value: string;
hasError?: boolean;
@@ -129,14 +128,4 @@ function UMaskInput({ name, value, onChange }: UMaskInputProps) {
);
}
UMaskInput.propTypes = {
name: PropTypes.string.isRequired,
value: PropTypes.string.isRequired,
hasError: PropTypes.bool,
hasWarning: PropTypes.bool,
onChange: PropTypes.func.isRequired,
onFocus: PropTypes.func,
onBlur: PropTypes.func,
};
export default UMaskInput;