import type { CssFunction } from '../types'; type WithConditionalCSSProp = 'className' extends keyof TProps ? string extends TProps['className' & keyof TProps] ? { /** * ## CSS prop * * Style a JSX element. * For further details [read the API documentation](https://compiledcssinjs.com/docs/api-css-prop). * * ### Style with objects * * @example * ``` * import { css } from '@evensix-compiled/react'; * *
* ``` * * ### Style with template literals * * @example * ``` * import { css } from '@evensix-compiled/react'; * *
* ``` * * ### Compose styles with arrays * * @example * ``` * import { css } from '@evensix-compiled/react'; * *
* ``` */ css?: CssFunction | CssFunction[]; } : // eslint-disable-next-line @typescript-eslint/ban-types {} : // eslint-disable-next-line @typescript-eslint/ban-types {}; // Unpack all here to avoid infinite self-referencing when defining our own JSX namespace type ReactJSXElement = JSX.Element; type ReactJSXElementClass = JSX.ElementClass; type ReactJSXElementAttributesProperty = JSX.ElementAttributesProperty; type ReactJSXElementChildrenAttribute = JSX.ElementChildrenAttribute; type ReactJSXLibraryManagedAttributes = JSX.LibraryManagedAttributes; type ReactJSXIntrinsicAttributes = JSX.IntrinsicAttributes; type ReactJSXIntrinsicClassAttributes = JSX.IntrinsicClassAttributes; type ReactJSXIntrinsicElements = JSX.IntrinsicElements; export namespace CompiledJSX { export type Element = ReactJSXElement; export type ElementClass = ReactJSXElementClass; export type ElementAttributesProperty = ReactJSXElementAttributesProperty; export type ElementChildrenAttribute = ReactJSXElementChildrenAttribute; export type LibraryManagedAttributes = WithConditionalCSSProp

& ReactJSXLibraryManagedAttributes; export type IntrinsicAttributes = ReactJSXIntrinsicAttributes; export type IntrinsicClassAttributes = ReactJSXIntrinsicClassAttributes; export type IntrinsicElements = { [K in keyof ReactJSXIntrinsicElements]: ReactJSXIntrinsicElements[K] & { css?: CssFunction | CssFunction[]; }; }; }