import { ElementType, ReactElement } from 'react'; import { PolymorphicPropsWithRef } from 'react-polymorphic-types'; import { StyleProps, TW, StyleConfig } from 'twind/style'; export * from 'twind/style'; interface ShouldForwardProp { (prop: string, defaultValidatorFn: (prop: string) => boolean): boolean; } interface StyledOptions { shouldForwardProp?: ShouldForwardProp; } interface StyledComponent { (props: PolymorphicPropsWithRef, T>): ReactElement | null; /** * CSS Selector associated with the current component. * * ```js * const button = style({ * base: { * color: "DarkSlateGray" * } * }) * * const article = style({ * base: { * [button]: { boxShadow: "0 0 0 5px" } * } * }) * ``` */ toString(): string; /** * CSS Class associated with the current component. * * ```js * const button = style({ * base: { * color: "DarkSlateGray" * } * }) * *
* ``` */ readonly className: string; /** * CSS Selector associated with the current component. * * ```js * const button = style({ * base: { * color: "DarkSlateGray" * } * }) * * const Card = styled({ * base: { * [Button.selector]: { boxShadow: "0 0 0 5px" } * } * }) * ``` */ readonly selector: string; } declare function styled(this: TW | null | undefined | void, base: StyledComponent, config?: StyledOptions & StyleConfig): StyledComponent & string; declare function styled(this: TW | null | undefined | void, tag?: Tag, config?: StyledOptions & StyleConfig): StyledComponent & string; export { ShouldForwardProp, StyledComponent, StyledOptions, styled }; //# sourceMappingURL=react.d.ts.map