import { ButtonHTMLAttributes, HTMLProps } from 'react';
export interface ITagged extends HTMLProps {
tag?: string;
}
export interface IColumn extends ITagged {
columnClass?: string;
pushClass?: string;
}
export interface ITable extends HTMLProps {
headerRows?: JSX.Element[][];
bodyRows?: JSX.Element[][];
}
export interface IPicture extends HTMLProps {
sources: ISource[];
}
export interface ISource {
srcSet: string;
media: string;
}
export interface IButton extends ButtonHTMLAttributes {
iconLeft?: SVGElement | JSX.Element;
iconRight?: SVGElement | JSX.Element;
}
export interface IRadioButton extends ButtonHTMLAttributes {
checked: boolean;
}
export interface ILinkButton extends IButton {
to: string;
}
export interface IField extends HTMLProps, IFormError {
}
export interface IInput extends HTMLProps, IFormError, IFormValid {
}
export interface ITextArea extends HTMLProps, IFormError, IFormValid {
}
export interface ISelect extends HTMLProps, IFormError, IFormValid {
options: IOption[];
initialField: string;
}
export interface IFormError {
error?: string | null;
}
export interface IFormValid {
valid?: string | null;
}
export interface ISwitchButton extends ButtonHTMLAttributes, IFormError {
active: boolean;
}
export interface ISwitchField extends ButtonHTMLAttributes, IFormError {
active: boolean;
label: string;
}
export interface IOption {
name: string;
value: any;
}