import React from "react"; type ClassedAugmentedProps = Props & { className?: string; ref?: React.Ref; }; type ClassedFinalProps = Component extends React.HTMLElementType ? React.HTMLProps & ClassedAugmentedProps : ClassedAugmentedProps; /** * This utility allows to extend a component a là `styled-components` but for * a className based styling solution like Tailwind, * * It also plays nicely with tailwind intellisense: * - https://github.com/tailwindlabs/tailwindcss-intellisense#tailwindcssclassattributes * * For references about tagged functions: * - https://javascript.plainenglish.io/how-css-in-js-libraries-work-da4145b1b6c7 * - https://makersden.io/blog/reverse-engineering-styled-components * - https://typesafe.blog/article/the-logic-behind-javascript-tag-functions * - https://flaming.codes/posts/typescript-and-javascript-tagged-template-strings * * Similar projects: * - https://reactjsexample.com/style-radix-ui-components-with-tailwindcss/ * * Discussions and Q/A: * - https://stackoverflow.com/q/73055695/1938970 */ export declare let classed: (component: Component) => (strings: TemplateStringsArray, ...args: ((props: Props) => string)[] | string[]) => React.ForwardRefExoticComponent> & React.RefAttributes>; export default classed;