UNPKG

@anyframe/css

Version:

Fast, lightweight, customizable, and modern utility-first CSS framework.

85 lines (84 loc) 2.84 kB
import type { ProcessedStyle } from '@tenoxui/moxie'; import type { Aliases } from '@tenoxui/types'; import type { TenoxUIConfig, Config, ApplyStyleObject } from './types'; import Moxie from '@tenoxui/moxie'; export declare class AnyCSS { private main; private prefixLoader; private engine; private variants; private customVariants; private property; private values; private classes; private alias; private breakpoints; private useResetter; private useLayer; private tabSize; private tuiConfig; private layerOrder; private apply; private themeConfig; private baseConfig; private componentsConfig; private layers; constructor({ sizing, colorVariant, colors, tabSize, showLayerDirective, preflight, layerOrder, variants, customVariants, property, values, classes, alias, breakpoints, apply, theme, base, components, moxie, moxieOptions }?: Partial<Config>); /** * Utility methods */ addTabs(str: string, size?: number, fixedTabs?: boolean): string; createEngine(inputConfig?: Partial<TenoxUIConfig>): Moxie; generateRulesFromClass(classNames: string | string[]): string; getConfig(): TenoxUIConfig; getLayerStyle(): { base: ApplyStyleObject; theme: ApplyStyleObject; components: ApplyStyleObject; }; getAliases(): Aliases; addAliases(newAliases: Aliases): this; /** * Layer Modifier */ addLayer(layerName: string): this; removeLayer(layerName: string): this; setLayerOrder(order: string[]): this; /** * Prefix Handling Methods */ private getPseudoSyntax; private getBreakpointQuery; private isCustomPrefix; private processCustomPrefix; /** * Formats CSS rules from cssRules and value */ private formatRules; /** * Creates the CSS selector string */ private createSelector; /** * Generates the CSS wrapper based on prefix type */ private generateCSSWrapper; /** * Main Generator */ private processApplyObject; generate(item: ProcessedStyle, rulesOnly?: boolean, custom?: boolean): string; addStyle(layer?: string, config?: ApplyStyleObject): this; createStyles(finalUtilities?: string): string; render(classNames?: string | string[]): string; } export { is, merge, transformClasses as createUtilityClass } from '@nousantx/someutils'; export { TenoxUI } from '@tenoxui/moxie'; export * from './types'; export { resetter as preflight } from './style/preflight'; export { properties } from './lib/property'; export { values } from './lib/value'; export { classes } from './lib/classes'; export { defaultColors as colors, colorLib } from './lib/color'; export { createColor as createColorValue } from '@/utils/createColorValue'; export default AnyCSS;