@navinc/base-react-components
Version:
Nav's Pattern Library
22 lines (21 loc) • 1.4 kB
TypeScript
import { MouseEventHandler, MutableRefObject, ReactNode } from 'react';
import { Input } from './form-elements/shared.js';
import { IconName } from './icons/index.js';
import { InferComponentProps } from './types.js';
declare type InputFieldProps = {
label?: string;
hasSpaceForErrors?: boolean;
helperIcon?: IconName;
helperLinkAction?: MouseEventHandler<HTMLDivElement>;
helperText?: string;
isStatic?: boolean;
errors?: string[];
lede?: ReactNode;
touched?: boolean;
childrenBeforeErrors?: ReactNode;
innerRef?: MutableRefObject<HTMLInputElement | undefined>;
tooltipText?: string;
} & InferComponentProps<typeof Input>;
export declare const InputField: ({ autoFocus, children, className, label, hasSpaceForErrors, helperIcon, helperLinkAction, helperText, isInvalid, isStatic, value, required, type, errors, lede, touched, placeholder, childrenBeforeErrors, innerRef, tooltipText, ...props }: InputFieldProps) => JSX.Element;
declare const StyledInput: import("styled-components").StyledComponent<({ autoFocus, children, className, label, hasSpaceForErrors, helperIcon, helperLinkAction, helperText, isInvalid, isStatic, value, required, type, errors, lede, touched, placeholder, childrenBeforeErrors, innerRef, tooltipText, ...props }: InputFieldProps) => JSX.Element, import("styled-components").DefaultTheme, {}, never>;
export default StyledInput;