/** * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * * */ import type { CompiledStyles, InlineStyles, Keyframes, MapNamespaces, StaticStyles, StaticStylesWithout, StyleX$Create, StyleX$CreateTheme, StyleX$DefineVars, StyleX$DefineConsts, StyleXArray, StyleXClassNameFor, StyleXStyles, StyleXStylesWithout, StyleXVar, Theme, VarGroup, PositionTry, ViewTransitionClass, StyleX$When, MapNamespace, StyleX$DefineMarker, StyleX$Env, } from './types/StyleXTypes'; import type { ValueWithDefault } from './types/StyleXUtils'; import * as Types from './types/VarTypes'; export type { CompiledStyles, InlineStyles, Keyframes, MapNamespaces, StaticStyles, StaticStylesWithout, StyleXArray, StyleXClassNameFor, StyleXStyles, StyleXStylesWithout, StyleXVar, Theme, Types, VarGroup, PositionTry, }; export declare const create: StyleX$Create; export declare type create = typeof create; export declare const createTheme: StyleX$CreateTheme; export declare type createTheme = typeof createTheme; export declare const defineConsts: StyleX$DefineConsts; export declare type defineConsts = typeof defineConsts; export declare const defineVars: StyleX$DefineVars; export declare type defineVars = typeof defineVars; export declare const defineMarker: StyleX$DefineMarker; export declare type defineMarker = typeof defineMarker; export declare const firstThatWorks: ( ..._styles: ReadonlyArray ) => ReadonlyArray; export declare type firstThatWorks = typeof firstThatWorks; export declare const keyframes: (_keyframes: Keyframes) => string; export declare type keyframes = typeof keyframes; export declare const positionTry: (_positionTry: PositionTry) => string; export declare type positionTry = typeof positionTry; export declare function props( this: null | undefined | unknown, ...styles: ReadonlyArray< StyleXArray< | (null | undefined | CompiledStyles) | boolean | Readonly<[CompiledStyles, InlineStyles]> > > ): Readonly<{ className?: string; 'data-style-src'?: string; style?: Readonly<{ [$$Key$$: string]: string | number }>; }>; export declare function attrs( this: null | undefined | unknown, ...styles: ReadonlyArray< StyleXArray< | (null | undefined | CompiledStyles) | boolean | Readonly<[CompiledStyles, InlineStyles]> > > ): Readonly<{ class?: string; 'data-style-src'?: string; style?: string }>; export declare const viewTransitionClass: ( _viewTransitionClass: ViewTransitionClass, ) => string; export declare type viewTransitionClass = typeof viewTransitionClass; export declare const defaultMarker: () => MapNamespace< Readonly<{ marker: 'default-marker' }> >; export declare type defaultMarker = typeof defaultMarker; export declare const when: StyleX$When; export declare type when = typeof when; export declare const env: StyleX$Env; export declare type env = typeof env; export declare const types: { angle: ( _v: ValueWithDefault, ) => Types.Angle; color: (_v: ValueWithDefault) => Types.Color; url: (_v: ValueWithDefault) => Types.Url; image: (_v: ValueWithDefault) => Types.Image; integer: ( _v: ValueWithDefault, ) => Types.Integer; lengthPercentage: ( _v: ValueWithDefault, ) => Types.LengthPercentage; length: ( _v: ValueWithDefault, ) => Types.Length; percentage: ( _v: ValueWithDefault, ) => Types.Percentage; number: (_v: ValueWithDefault) => Types.Num; resolution: ( _v: ValueWithDefault, ) => Types.Resolution; time: ( _v: ValueWithDefault, ) => Types.Time; transformFunction: ( _v: ValueWithDefault, ) => Types.TransformFunction; transformList: ( _v: ValueWithDefault, ) => Types.TransformList; }; export declare type types = typeof types; /** * DO NOT USE. Legacy export for Meta */ /** * DO NOT USE. Legacy export for Meta */ type IStyleX = { ( ...styles: ReadonlyArray< StyleXArray<(null | undefined | CompiledStyles) | boolean> > ): string; create: StyleX$Create; createTheme: StyleX$CreateTheme; defineConsts: StyleX$DefineConsts; defineVars: StyleX$DefineVars; env: StyleX$Env; defaultMarker: () => MapNamespace>; defineMarker: StyleX$DefineMarker; firstThatWorks: ( ...v: ReadonlyArray ) => ReadonlyArray; keyframes: (keyframes: Keyframes) => string; positionTry: (positionTry: PositionTry) => string; props: ( this: null | undefined | unknown, ...styles: ReadonlyArray< StyleXArray< | (null | undefined | CompiledStyles) | boolean | Readonly<[CompiledStyles, InlineStyles]> > > ) => Readonly<{ className?: string; 'data-style-src'?: string; style?: Readonly<{ [$$Key$$: string]: string | number }>; }>; attrs: ( this: null | undefined | unknown, ...styles: ReadonlyArray< StyleXArray< | (null | undefined | CompiledStyles) | boolean | Readonly<[CompiledStyles, InlineStyles]> > > ) => Readonly<{ class?: string; 'data-style-src'?: string; style?: string }>; viewTransitionClass: (viewTransitionClass: ViewTransitionClass) => string; types: typeof types; when: typeof when; __customProperties?: { [$$Key$$: string]: unknown }; }; export declare const legacyMerge: IStyleX; export declare type legacyMerge = typeof legacyMerge;