jobiqo-cl
Version:
[](https://circleci.com/gh/jobiqo/jobiqo-cl)
25 lines (24 loc) • 846 B
TypeScript
/**
* @file index.tsx
*
* @fileoverview Input component. Renders a button input together with its label.
*/
import React from 'react';
export interface InputProps extends React.InputHTMLAttributes<HTMLInputElement> {
/**
* The label to be shown next to the input.
*/
label?: string;
/**
* Marks if a field is in an error state.
*
* @default false
*/
error?: boolean;
}
/**
* A input is a form element where users can type information on. The input can be of several types (the parent component can set that via the "type" property).
* The component inherits props from the "InputHTMLAttributes" so any property for a checkbox can be used with this component.
*/
export declare const Input: ({ label, id, disabled, required, error, ...props }: InputProps) => JSX.Element;
export default Input;