chaincss 2.0.6 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (159) hide show
  1. package/CHANGELOG.md +30 -0
  2. package/CODE_OF_CONDUCT.md +21 -0
  3. package/CONTRIBUTING.md +28 -0
  4. package/README.md +454 -231
  5. package/demo/demo/node_modules/caniuse-db/fulldata-json/data-2.0.json +1 -0
  6. package/demo/index.html +16 -0
  7. package/demo/package.json +20 -0
  8. package/demo/src/App.tsx +117 -0
  9. package/demo/src/chaincss-barrel.ts +9 -0
  10. package/demo/src/main.tsx +8 -0
  11. package/demo/src/styles.chain.ts +300 -0
  12. package/demo/vite.config.ts +46 -0
  13. package/dist/cli/commands/build.d.ts +0 -1
  14. package/dist/cli/commands/cache.d.ts +1 -0
  15. package/dist/cli/commands/init.d.ts +6 -3
  16. package/dist/cli/commands/timeline.d.ts +0 -1
  17. package/dist/cli/commands/watch.d.ts +0 -1
  18. package/dist/cli/index.d.ts +0 -1
  19. package/dist/cli/index.js +3213 -5296
  20. package/dist/cli/types.d.ts +51 -20
  21. package/dist/cli/utils/config-loader.d.ts +0 -1
  22. package/dist/cli/utils/file-utils.d.ts +27 -3
  23. package/dist/cli/utils/logger.d.ts +0 -1
  24. package/dist/compiler/Chain.d.ts +215 -0
  25. package/dist/compiler/animations.d.ts +76 -0
  26. package/dist/compiler/atomic-optimizer.d.ts +47 -12
  27. package/dist/compiler/breakpoints.d.ts +46 -0
  28. package/dist/compiler/btt.d.ts +36 -60
  29. package/dist/compiler/cache-manager.d.ts +58 -4
  30. package/dist/compiler/commonProps.d.ts +0 -1
  31. package/dist/compiler/content-addressable-cache.d.ts +78 -0
  32. package/dist/compiler/helpers.d.ts +54 -0
  33. package/dist/compiler/index.d.ts +16 -9
  34. package/dist/compiler/index.js +4450 -4316
  35. package/dist/compiler/prefixer.d.ts +17 -1
  36. package/dist/compiler/shorthands.d.ts +28 -0
  37. package/dist/compiler/suggestions.d.ts +43 -0
  38. package/dist/compiler/theme-contract.d.ts +16 -27
  39. package/dist/compiler/token-resolver.d.ts +69 -0
  40. package/dist/compiler/tokens.d.ts +33 -8
  41. package/dist/core/auto-detector.d.ts +34 -0
  42. package/dist/core/common-utils.d.ts +97 -0
  43. package/dist/core/compiler.d.ts +63 -23
  44. package/dist/core/constants.d.ts +137 -36
  45. package/dist/core/smart-chain.d.ts +3 -0
  46. package/dist/core/types.d.ts +122 -15
  47. package/dist/core/utils.d.ts +134 -17
  48. package/dist/index.d.ts +52 -8
  49. package/dist/index.js +7090 -5578
  50. package/dist/plugins/vite.d.ts +7 -5
  51. package/dist/plugins/vite.js +2964 -25641
  52. package/dist/plugins/webpack.d.ts +24 -1
  53. package/dist/plugins/webpack.js +209 -72
  54. package/dist/runtime/Chain.d.ts +32 -0
  55. package/dist/runtime/auto-hooks.d.ts +11 -0
  56. package/dist/runtime/hmr.d.ts +22 -2
  57. package/dist/runtime/index.d.ts +3 -2
  58. package/dist/runtime/index.js +3649 -301
  59. package/dist/runtime/injector.d.ts +39 -71
  60. package/dist/runtime/react.d.ts +17 -12
  61. package/dist/runtime/svelte.d.ts +15 -0
  62. package/dist/runtime/types.d.ts +126 -4
  63. package/dist/runtime/utils.d.ts +0 -1
  64. package/dist/runtime/vue.d.ts +34 -14
  65. package/package.json +59 -66
  66. package/src/cli/commands/build.ts +133 -0
  67. package/src/cli/commands/cache.ts +371 -0
  68. package/src/cli/commands/init.ts +230 -0
  69. package/src/cli/commands/timeline.ts +435 -0
  70. package/src/cli/commands/watch.ts +211 -0
  71. package/src/cli/index.ts +226 -0
  72. package/src/cli/types.ts +100 -0
  73. package/src/cli/utils/config-loader.ts +174 -0
  74. package/src/cli/utils/file-utils.ts +139 -0
  75. package/src/cli/utils/logger.ts +74 -0
  76. package/src/compiler/Chain.ts +831 -0
  77. package/src/compiler/animations.ts +517 -0
  78. package/src/compiler/atomic-optimizer.ts +786 -0
  79. package/src/compiler/breakpoints.ts +347 -0
  80. package/src/compiler/btt.ts +1147 -0
  81. package/src/compiler/cache-manager.ts +446 -0
  82. package/src/compiler/commonProps.ts +18 -0
  83. package/src/compiler/content-addressable-cache.ts +478 -0
  84. package/src/compiler/helpers.ts +407 -0
  85. package/src/compiler/index.ts +72 -0
  86. package/src/compiler/prefixer.ts +724 -0
  87. package/src/compiler/shorthands.ts +558 -0
  88. package/src/compiler/suggestions.ts +436 -0
  89. package/src/compiler/theme-contract.ts +197 -0
  90. package/src/compiler/token-resolver.ts +241 -0
  91. package/src/compiler/tokens.ts +612 -0
  92. package/src/core/auto-detector.ts +187 -0
  93. package/src/core/common-utils.ts +423 -0
  94. package/src/core/compiler.ts +835 -0
  95. package/src/core/constants.ts +424 -0
  96. package/src/core/index.ts +107 -0
  97. package/src/core/smart-chain.ts +163 -0
  98. package/src/core/types.ts +257 -0
  99. package/src/core/utils.ts +598 -0
  100. package/src/index.ts +208 -0
  101. package/src/plugins/vite.d.ts +316 -0
  102. package/src/plugins/vite.ts +424 -0
  103. package/src/plugins/webpack.d.ts +289 -0
  104. package/src/plugins/webpack.ts +416 -0
  105. package/src/runtime/Chain.ts +242 -0
  106. package/src/runtime/auto-hooks.tsx +127 -0
  107. package/src/runtime/auto-vue.ts +72 -0
  108. package/src/runtime/hmr.ts +212 -0
  109. package/src/runtime/index.ts +82 -0
  110. package/src/runtime/injector.ts +273 -0
  111. package/src/runtime/react.tsx +269 -0
  112. package/src/runtime/svelte.ts +15 -0
  113. package/src/runtime/types.ts +256 -0
  114. package/src/runtime/utils.ts +128 -0
  115. package/src/runtime/vite-env.d.ts +120 -0
  116. package/src/runtime/vue.ts +231 -0
  117. package/tsconfig.build.json +41 -0
  118. package/tsconfig.json +25 -0
  119. package/tsconfig.runtimes.json +18 -0
  120. package/dist/cli/cli.cjs +0 -7
  121. package/dist/cli/commands/build.d.ts.map +0 -1
  122. package/dist/cli/commands/compile.d.ts +0 -3
  123. package/dist/cli/commands/compile.d.ts.map +0 -1
  124. package/dist/cli/commands/init.d.ts.map +0 -1
  125. package/dist/cli/commands/timeline.d.ts.map +0 -1
  126. package/dist/cli/commands/watch.d.ts.map +0 -1
  127. package/dist/cli/index.d.ts.map +0 -1
  128. package/dist/cli/types.d.ts.map +0 -1
  129. package/dist/cli/utils/config-loader.d.ts.map +0 -1
  130. package/dist/cli/utils/file-utils.d.ts.map +0 -1
  131. package/dist/cli/utils/logger.d.ts.map +0 -1
  132. package/dist/compiler/atomic-optimizer.d.ts.map +0 -1
  133. package/dist/compiler/btt.d.ts.map +0 -1
  134. package/dist/compiler/cache-manager.d.ts.map +0 -1
  135. package/dist/compiler/commonProps.d.ts.map +0 -1
  136. package/dist/compiler/index.d.ts.map +0 -1
  137. package/dist/compiler/prefixer.d.ts.map +0 -1
  138. package/dist/compiler/theme-contract.d.ts.map +0 -1
  139. package/dist/compiler/tokens.d.ts.map +0 -1
  140. package/dist/compiler/types.d.ts +0 -57
  141. package/dist/compiler/types.d.ts.map +0 -1
  142. package/dist/core/compiler.d.ts.map +0 -1
  143. package/dist/core/constants.d.ts.map +0 -1
  144. package/dist/core/index.d.ts +0 -4
  145. package/dist/core/index.d.ts.map +0 -1
  146. package/dist/core/types.d.ts.map +0 -1
  147. package/dist/core/utils.d.ts.map +0 -1
  148. package/dist/index.d.ts.map +0 -1
  149. package/dist/plugins/vite.d.ts.map +0 -1
  150. package/dist/plugins/webpack.d.ts.map +0 -1
  151. package/dist/runtime/hmr.d.ts.map +0 -1
  152. package/dist/runtime/index.d.ts.map +0 -1
  153. package/dist/runtime/injector.d.ts.map +0 -1
  154. package/dist/runtime/react.d.ts.map +0 -1
  155. package/dist/runtime/react.js +0 -270
  156. package/dist/runtime/types.d.ts.map +0 -1
  157. package/dist/runtime/utils.d.ts.map +0 -1
  158. package/dist/runtime/vue.d.ts.map +0 -1
  159. package/dist/runtime/vue.js +0 -232
@@ -1,5 +1,7 @@
1
1
  import { DesignTokens } from './tokens.js';
2
2
  import type { AtomicOptimizer } from './atomic-optimizer.js';
3
+ export { setBreakpoints } from './breakpoints.js';
4
+ export { chain, enableDebug } from './Chain.js';
3
5
  interface StyleSnapshot {
4
6
  id: string;
5
7
  timestamp: number;
@@ -32,49 +34,21 @@ interface ComponentInfo {
32
34
  }
33
35
  export declare function generateComponentCode(info: ComponentInfo): string;
34
36
  export declare function setSourceComments(enabled: boolean): void;
35
- declare function calc(expression: string): string;
36
- declare function add(a: string | number, b: string | number): string;
37
- declare function subtract(a: string | number, b: string | number): string;
38
- declare function multiply(a: string | number, b: string | number): string;
39
- declare function divide(a: string | number, b: string | number): string;
40
- declare function percent(value: number): string;
41
- declare function vw(value: number): string;
42
- declare function vh(value: number): string;
43
- declare function rem(value: number): string;
44
- declare function em(value: number): string;
45
- declare function px(value: number): string;
46
- declare function min(...values: (string | number)[]): string;
47
- declare function max(...values: (string | number)[]): string;
48
- declare function clamp(min: string | number, preferred: string | number, max: string | number): string;
49
- declare const helpers: {
50
- calc: typeof calc;
51
- add: typeof add;
52
- subtract: typeof subtract;
53
- sub: typeof subtract;
54
- multiply: typeof multiply;
55
- mul: typeof multiply;
56
- divide: typeof divide;
57
- div: typeof divide;
58
- percent: typeof percent;
59
- vw: typeof vw;
60
- vh: typeof vh;
61
- rem: typeof rem;
62
- em: typeof em;
63
- px: typeof px;
64
- min: typeof min;
65
- max: typeof max;
66
- clamp: typeof clamp;
67
- };
68
- declare function enableDebug(enable?: boolean): void;
69
- declare function setBreakpoints(breakpoints: Record<string, string>): void;
70
- export interface StyleDefinition {
71
- selectors: string[];
72
- hover?: Record<string, string | number>;
73
- atRules?: AtRule[];
74
- nestedRules?: NestedRule[];
75
- themes?: ThemeBlock[];
76
- [cssProperty: string]: any;
37
+ export interface ChainObject {
38
+ cssOutput: string;
39
+ cachedValidProperties: string[];
40
+ classMap: Record<string, string>;
41
+ atomicStats: any;
42
+ componentMap?: Map<string, any>;
43
+ initializeProperties: () => Promise<void>;
44
+ getCachedProperties: () => string[] | null;
77
45
  }
46
+ export declare const chains: ChainObject;
47
+ declare let atomicOptimizer: AtomicOptimizer | null;
48
+ export declare function setAtomicOptimizer(optimizer: AtomicOptimizer | null): void;
49
+ export declare function configureAtomic(opts: Record<string, any>): void;
50
+ export declare const tokens: DesignTokens;
51
+ export declare function createTokens(tokenValues: Record<string, any>): DesignTokens;
78
52
  export interface AtRule {
79
53
  type: 'media' | 'keyframes' | 'font-face' | 'supports' | 'container' | 'layer' | 'counter-style' | 'property';
80
54
  query?: string;
@@ -95,23 +69,14 @@ export interface ThemeBlock {
95
69
  tokens: any;
96
70
  fallback: any;
97
71
  }
98
- export interface ChainObject {
99
- cssOutput: string;
100
- catcher: any;
101
- cachedValidProperties: string[];
102
- classMap: Record<string, string>;
103
- atomicStats: any;
104
- componentMap?: Map<string, any>;
105
- initializeProperties: () => Promise<void>;
106
- getCachedProperties: () => string[] | null;
72
+ export interface StyleDefinition {
73
+ selectors: string[];
74
+ hover?: Record<string, string | number>;
75
+ atRules?: AtRule[];
76
+ nestedRules?: NestedRule[];
77
+ themes?: ThemeBlock[];
78
+ [cssProperty: string]: any;
107
79
  }
108
- export declare const chain: ChainObject;
109
- declare let atomicOptimizer: AtomicOptimizer | null;
110
- export declare function setAtomicOptimizer(optimizer: AtomicOptimizer | null): void;
111
- export declare function configureAtomic(opts: Record<string, any>): void;
112
- export declare const tokens: DesignTokens;
113
- export declare function createTokens(tokenValues: Record<string, any>): DesignTokens;
114
- export declare const $: any;
115
80
  export declare const run: (...args: any[]) => string;
116
81
  export declare const compile: (obj: Record<string, StyleDefinition>) => string;
117
82
  export interface RecipeOptions<TVariants extends Record<string, Record<string, any>>> {
@@ -140,7 +105,18 @@ export type Recipe<TVariants extends Record<string, Record<string, any>>> = {
140
105
  [K in keyof TVariants]: keyof TVariants[K];
141
106
  }>>;
142
107
  compileAll: () => string;
108
+ getVariantClassNames: () => Record<string, string>;
143
109
  };
144
110
  export declare function recipe<TVariants extends Record<string, Record<string, any>>>(options: RecipeOptions<TVariants>): Recipe<TVariants>;
145
- export { atomicOptimizer, chain as chainObject, setBreakpoints, enableDebug, helpers };
146
- //# sourceMappingURL=btt.d.ts.map
111
+ /**
112
+ * The "Brain": Extracts ChainCSS calls from raw text
113
+ */
114
+ export declare const scanContent: (text: string) => string[];
115
+ /**
116
+ * The "Worker": Reads the file, uses the Brain, feeds the Optimizer
117
+ */
118
+ export declare function scanFileForStyles(filePath: string, optimizer: any, source?: string | null): {
119
+ foundCount: number;
120
+ errors: Error[];
121
+ };
122
+ export { atomicOptimizer, chains as chainObject };
@@ -1,20 +1,74 @@
1
1
  export interface CacheData {
2
2
  version: string;
3
3
  created: string;
4
+ updated: string;
4
5
  atomic: Record<string, any>;
5
6
  usage: Record<string, any>;
7
+ componentMap: Record<string, any>;
8
+ stats: {
9
+ totalStyles: number;
10
+ atomicStyles: number;
11
+ cacheHits: number;
12
+ cacheMisses: number;
13
+ };
6
14
  [key: string]: any;
7
15
  }
16
+ export interface CacheOptions {
17
+ maxAge?: number;
18
+ maxSize?: number;
19
+ compress?: boolean;
20
+ autoSave?: boolean;
21
+ saveInterval?: number;
22
+ }
8
23
  export declare class CacheManager {
9
24
  cachePath: string;
10
25
  cacheDir: string;
11
26
  cache: CacheData | Record<string, any>;
12
- constructor(cachePath?: string);
27
+ private dirty;
28
+ private saveTimer;
29
+ private stats;
30
+ private options;
31
+ constructor(cachePath?: string, options?: CacheOptions);
32
+ private startAutoSave;
33
+ private stopAutoSave;
13
34
  load(): void;
35
+ private getDefaultCache;
36
+ private isExpired;
37
+ private checkAndPrune;
38
+ private isCompressed;
39
+ private compress;
40
+ private decompress;
14
41
  get(key: string): any;
15
- set(key: string, value: any): void;
16
- save(): void;
42
+ set(key: string, value: any, ttl?: number): void;
43
+ has(key: string): boolean;
44
+ delete(key: string): boolean;
17
45
  clear(): void;
46
+ prune(): void;
47
+ save(): void;
48
+ getStats(): {
49
+ hits: number;
50
+ misses: number;
51
+ reads: number;
52
+ writes: number;
53
+ hitRate: number;
54
+ size: number;
55
+ entryCount: number;
56
+ };
57
+ getCacheSize(): number;
58
+ getCacheAge(): number;
59
+ getKeys(): string[];
60
+ getSize(): number;
61
+ isDirty(): boolean;
62
+ flush(): Promise<void>;
63
+ destroy(): void;
64
+ getEntry(key: string): {
65
+ value: any;
66
+ cachedAt: number;
67
+ expires?: number;
68
+ } | undefined;
69
+ setWithTTL(key: string, value: any, ttlSeconds: number): void;
70
+ setBulk(entries: Record<string, any>): void;
71
+ getBulk(keys: string[]): Record<string, any>;
72
+ getOrCompute<T>(key: string, compute: () => Promise<T>, ttl?: number): Promise<T>;
18
73
  }
19
74
  export { CacheManager as default };
20
- //# sourceMappingURL=cache-manager.d.ts.map
@@ -1,2 +1 @@
1
1
  export declare const COMMON_CSS_PROPERTIES: string[];
2
- //# sourceMappingURL=commonProps.d.ts.map
@@ -0,0 +1,78 @@
1
+ export interface PersistentCacheEntry {
2
+ hash: string;
3
+ result: any;
4
+ dependencies: Record<string, string>;
5
+ timestamp: number;
6
+ version: string;
7
+ compilerVersion: string;
8
+ createdAt?: number;
9
+ lastAccessed?: number;
10
+ accessCount?: number;
11
+ size?: number;
12
+ value?: any;
13
+ }
14
+ export interface PersistentCacheOptions {
15
+ cacheDir?: string;
16
+ maxAgeDays?: number;
17
+ maxSizeMB?: number;
18
+ enabled?: boolean;
19
+ verbose?: boolean;
20
+ }
21
+ export declare class PersistentCache {
22
+ private cacheDir;
23
+ private options;
24
+ private memoryCache;
25
+ private metadataPath;
26
+ private metadata;
27
+ constructor(options?: PersistentCacheOptions);
28
+ private hash;
29
+ private hashFile;
30
+ getByContent(source: string): Promise<any | null>;
31
+ getByFile(filePath: string): Promise<any | null>;
32
+ getByHash(hash: string): Promise<any | null>;
33
+ setByContent(source: string, result: any, dependencies?: string[]): Promise<string>;
34
+ setByFile(filePath: string, result: any, dependencies?: string[]): Promise<string>;
35
+ setByHash(hash: string, result: any, dependencies?: string[]): Promise<string>;
36
+ getByHashSync(hash: string): any | null;
37
+ setByHashSync(hash: string, result: any, source: any, dependencies?: string[]): void;
38
+ invalidateByHash(hash: string): void;
39
+ clear(): Promise<void>;
40
+ getStats(): Promise<{
41
+ entryCount: number;
42
+ totalSizeMB: number;
43
+ totalSizeBytes: number;
44
+ oldestEntry: number;
45
+ newestEntry: number;
46
+ hitRate?: number;
47
+ }>;
48
+ prune(): Promise<void>;
49
+ private isExpired;
50
+ private loadMetadata;
51
+ private updateMetadata;
52
+ private updateMetadataSync;
53
+ enforceSizeLimit(): Promise<void>;
54
+ private enforceSizeLimitSync;
55
+ private ensureDir;
56
+ /**
57
+ * List all cache entries
58
+ */
59
+ listEntries(): Promise<Array<{
60
+ key: string;
61
+ size: number;
62
+ timestamp: number;
63
+ createdAt: number;
64
+ lastAccessed?: number;
65
+ }>>;
66
+ /**
67
+ * Get a cache entry by key
68
+ */
69
+ get(key: string): Promise<PersistentCacheEntry | null>;
70
+ /**
71
+ * Delete a cache entry by key
72
+ */
73
+ delete(key: string): Promise<boolean>;
74
+ /**
75
+ * Validate a cache entry
76
+ */
77
+ validate(key: string): Promise<boolean>;
78
+ }
@@ -0,0 +1,54 @@
1
+ export type Unit = 'px' | 'rem' | 'em' | '%' | 'vw' | 'vh' | 'vmin' | 'vmax' | 'ch' | 'ex';
2
+ export type MathOperation = 'add' | 'subtract' | 'multiply' | 'divide';
3
+ export interface CalcOptions {
4
+ precision?: number;
5
+ simplify?: boolean;
6
+ }
7
+ export declare const helpers: {
8
+ calc: (expr: string, options?: CalcOptions) => string;
9
+ add: (a: any, b: any, options?: CalcOptions) => string;
10
+ subtract: (a: any, b: any, options?: CalcOptions) => string;
11
+ sub: (a: any, b: any, options?: CalcOptions) => string;
12
+ multiply: (a: any, b: any, options?: CalcOptions) => string;
13
+ mul: (a: any, b: any, options?: CalcOptions) => string;
14
+ divide: (a: any, b: any, options?: CalcOptions) => string;
15
+ div: (a: any, b: any, options?: CalcOptions) => string;
16
+ sum: (...values: any[]) => string;
17
+ difference: (a: any, ...rest: any[]) => string;
18
+ product: (...values: any[]) => string;
19
+ quotient: (a: any, ...rest: any[]) => string;
20
+ mpx: (value: number | string) => string;
21
+ rem: (value: number | string, base?: number) => string;
22
+ em: (value: number | string, context?: number) => string;
23
+ percent: (value: number | string) => string;
24
+ vw: (value: number | string) => string;
25
+ vh: (value: number | string) => string;
26
+ vmin: (value: number | string) => string;
27
+ vmax: (value: number | string) => string;
28
+ ch: (value: number | string) => string;
29
+ ex: (value: number | string) => string;
30
+ convert: (value: string | number, fromUnit: Unit, toUnit: Unit, context?: number) => string;
31
+ min: (...values: any[]) => string;
32
+ max: (...values: any[]) => string;
33
+ clamp: (min: any, preferred: any, max: any, options?: CalcOptions) => string;
34
+ round: (value: number | string, precision?: number) => string;
35
+ ceil: (value: number | string) => string;
36
+ floor: (value: number | string) => string;
37
+ rgba: (r: number, g: number, b: number, a?: number) => string;
38
+ hsla: (h: number, s: number, l: number, a?: number) => string;
39
+ url: (path: string) => string;
40
+ format: (strings: TemplateStringsArray, ...values: any[]) => string;
41
+ if: (condition: boolean, trueValue: any, falseValue: any) => any;
42
+ camelToKebab: (str: string) => string;
43
+ kebabToCamel: (str: string) => string;
44
+ toPx: (value: number | string) => string;
45
+ toRem: (value: number | string, base?: number) => string;
46
+ };
47
+ export type MathHelpers = typeof helpers;
48
+ export declare function withUnit(value: number | string, unit: Unit): string;
49
+ export declare function extractNumeric(value: string): number;
50
+ export declare function extractUnit(value: string): Unit | null;
51
+ export declare function fluidType(minSize: number, maxSize: number, minWidth?: number, maxWidth?: number, unit?: 'px' | 'rem'): string;
52
+ export default helpers;
53
+ export declare const toPx: (v: number | string) => string;
54
+ export declare const toRem: (v: number | string) => string;
@@ -1,12 +1,19 @@
1
- export { chain, $, run, compile, createTokens, configureAtomic, setAtomicOptimizer, recipe, tokens } from './btt.js';
1
+ export { chain, chains, run, compile, createTokens, configureAtomic, setAtomicOptimizer, recipe, tokens, enableDebug, setBreakpoints, enableTimeline, getStyleHistory, getStyleChanges, getStyleDiff, exportTimeline, clearTimeline, setSourceComments } from './btt.js';
2
2
  export { AtomicOptimizer } from './atomic-optimizer.js';
3
+ export type { AtomicClass, AtomicOptimizerOptions, AtomicOptimizerStats, ComponentClassMapEntry, OptimizeResult } from './atomic-optimizer.js';
3
4
  export { ChainCSSPrefixer } from './prefixer.js';
4
- export { DesignTokens, tokens as tokenInstance, createTokens as createTokensUtil, responsive } from './tokens.js';
5
- export { createThemeContract, validateTheme, createTheme } from './theme-contract.js';
5
+ export type { PrefixerConfig, PrefixerResult } from './prefixer.js';
6
+ export { DesignTokens, createTokens as createDesignTokens } from './tokens.js';
7
+ export type { TokensStructure, FlattenedTokens } from './tokens.js';
8
+ export { createThemeContract, validateTheme, createTheme, Theme } from './theme-contract.js';
9
+ export type { ThemeContract, ThemeTokens } from './theme-contract.js';
6
10
  export { CacheManager } from './cache-manager.js';
7
- export type { StyleDefinition, AtRule, NestedRule, ThemeBlock } from './btt.js';
8
- export type { AtomicClass, AtomicOptimizerOptions, AtomicOptimizerStats } from './atomic-optimizer.js';
9
- export type { PrefixerConfig } from './prefixer.js';
10
- export type { TokensStructure, DesignTokens as DesignTokensType } from './tokens.js';
11
- export type { CacheData } from './cache-manager.js';
12
- //# sourceMappingURL=index.d.ts.map
11
+ export { PersistentCache } from './content-addressable-cache.js';
12
+ export type { CacheData, CacheOptions } from './cache-manager.js';
13
+ export type { PersistentCacheOptions, PersistentCacheEntry } from './content-addressable-cache.js';
14
+ export { shorthandMap, macros, handleShorthand, isShorthand, expandShorthand, getAvailableShorthands } from './shorthands.js';
15
+ export { helpers } from './helpers.js';
16
+ export { animationPresets, createAnimation, getAnimationPreset, hasAnimationPreset, getAnimationPresetNames } from './animations.js';
17
+ export { setBreakpoints as setBreakpointsUtil, getBreakpoint, getAllBreakpoints, resetBreakpoints, addBreakpoint, removeBreakpoint } from './breakpoints.js';
18
+ export { getSuggestion, getSuggestions, getPropertySuggestion, getShorthandSuggestion } from './suggestions.js';
19
+ export { resolveToken, setTokenContext, getTokenContext, clearTokenContext, TokenResolver } from './token-resolver.js';