@navinc/base-react-components
Version:
Nav's Pattern Library
46 lines (45 loc) • 2.62 kB
TypeScript
import { Property } from 'csstype';
import { ReactNode } from 'react';
import { InferComponentProps } from './types.js';
declare const sizeVariants: {
readonly sm: {
readonly checkRight: "7px";
readonly checkBottom: "7.5px";
readonly checkboxSize: "20px";
readonly thickness: "2.5px";
};
readonly md: {
readonly checkRight: "8px";
readonly checkBottom: "9px";
readonly checkboxSize: "24px";
readonly thickness: "3px";
};
};
type SizeVarientKey = keyof typeof sizeVariants;
declare const StyledCheckbox: import("styled-components/dist/types.js").IStyledComponentBase<"web", import("styled-components/dist/types.js").Substitute<import("styled-components").FastOmit<import("styled-components/dist/types.js").Substitute<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>>, never>, {
isInvalid?: boolean;
}>> & string;
type CheckboxProps = InferComponentProps<typeof StyledCheckbox> & {
asideContent?: ReactNode;
label?: ReactNode;
checkedBackgroundColor?: Property.BackgroundColor;
hasBorder?: boolean;
hasSpaceForErrors?: boolean;
errors?: string[];
size?: SizeVarientKey;
};
/**
* @deprecated This component is deprecated and will be removed in a future release. Avoid using it in new code.
*/
export declare const Checkbox: import("styled-components/dist/types.js").IStyledComponentBase<"web", import("styled-components").FastOmit<InferComponentProps<import("styled-components/dist/types.js").IStyledComponentBase<"web", import("styled-components/dist/types.js").Substitute<import("styled-components").FastOmit<import("styled-components/dist/types.js").Substitute<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>>, never>, {
isInvalid?: boolean;
}>> & string> & {
asideContent?: ReactNode;
label?: ReactNode;
checkedBackgroundColor?: Property.BackgroundColor;
hasBorder?: boolean;
hasSpaceForErrors?: boolean;
errors?: string[];
size?: SizeVarientKey;
}, never>> & string & Omit<({ asideContent, label, checked, checkedBackgroundColor, disabled, className, hasBorder, hasSpaceForErrors, errors, size, isInvalid, ...props }: CheckboxProps) => import("react/jsx-runtime").JSX.Element, keyof import("react").Component<any, {}, any>>;
export {};