tailwind-styled-v4 1.0.1 → 5.0.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.
- package/dist/animate.cjs +771 -0
- package/dist/animate.cjs.map +1 -0
- package/dist/animate.d.cts +73 -0
- package/dist/animate.d.ts +73 -0
- package/dist/animate.js +752 -0
- package/dist/animate.js.map +1 -0
- package/dist/chunk-VZEJV27B.js +11 -0
- package/dist/chunk-VZEJV27B.js.map +1 -0
- package/dist/chunk-Y5D3E72P.cjs +13 -0
- package/dist/chunk-Y5D3E72P.cjs.map +1 -0
- package/dist/css.cjs +121 -0
- package/dist/css.cjs.map +1 -0
- package/dist/css.d.cts +30 -0
- package/dist/css.d.ts +30 -0
- package/dist/css.js +112 -0
- package/dist/css.js.map +1 -0
- package/dist/devtools.cjs +1071 -0
- package/dist/devtools.cjs.map +1 -0
- package/dist/devtools.d.cts +22 -0
- package/dist/devtools.d.ts +22 -0
- package/dist/devtools.js +1064 -0
- package/dist/devtools.js.map +1 -0
- package/dist/index.cjs +1353 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +655 -0
- package/dist/index.d.ts +508 -968
- package/dist/index.js +1304 -3
- package/dist/index.js.map +1 -1
- package/dist/next.cjs +248 -0
- package/dist/next.cjs.map +1 -0
- package/dist/next.d.cts +54 -0
- package/dist/next.d.ts +54 -0
- package/dist/next.js +241 -0
- package/dist/next.js.map +1 -0
- package/dist/preset.cjs +423 -0
- package/dist/preset.cjs.map +1 -0
- package/dist/preset.d.cts +276 -0
- package/dist/preset.d.ts +276 -0
- package/dist/preset.js +416 -0
- package/dist/preset.js.map +1 -0
- package/dist/turbopackLoader.cjs +37 -0
- package/dist/turbopackLoader.cjs.map +1 -0
- package/dist/turbopackLoader.d.cts +12 -0
- package/dist/turbopackLoader.d.ts +12 -0
- package/dist/turbopackLoader.js +35 -0
- package/dist/turbopackLoader.js.map +1 -0
- package/dist/vite.cjs +138 -0
- package/dist/vite.cjs.map +1 -0
- package/dist/vite.d.cts +51 -0
- package/dist/vite.d.ts +51 -0
- package/dist/vite.js +128 -0
- package/dist/vite.js.map +1 -0
- package/dist/webpackLoader.cjs +51 -0
- package/dist/webpackLoader.cjs.map +1 -0
- package/dist/webpackLoader.d.cts +17 -0
- package/dist/webpackLoader.d.ts +17 -0
- package/dist/webpackLoader.js +49 -0
- package/dist/webpackLoader.js.map +1 -0
- package/package.json +65 -32
- package/CHANGELOG.md +0 -75
- package/LICENSE +0 -21
- package/README.md +0 -608
- package/dist/cli/init.js +0 -208
- package/dist/compiler/index.d.mts +0 -214
- package/dist/compiler/index.d.ts +0 -214
- package/dist/compiler/index.js +0 -546
- package/dist/compiler/index.js.map +0 -1
- package/dist/compiler/index.mjs +0 -504
- package/dist/compiler/index.mjs.map +0 -1
- package/dist/index.d.mts +0 -1115
- package/dist/index.mjs +0 -4
- package/dist/index.mjs.map +0 -1
- package/dist/turbopack-loader.js +0 -232
- package/dist/webpack-loader.js +0 -213
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../shared/dist/index.js","../../animate/src/binding.ts","../../animate/src/preset.ts","../../analyzer/dist/index.js","../../animate/src/registry.ts","../../animate/src/index.ts"],"names":["path","fileURLToPath","createRequire","fs","DEBUG_NAMESPACE","formatErrorMessage","debugLog","initAnimate"],"mappings":";;;;;;;;;;;;;;;;;AACA,IAAI,WAAW,MAAM;AAAA,EACnB,WAAA,CAAY,GAAA,GAAM,GAAA,EAAK,KAAA,GAAQ,IAAA,EAAM;AACnC,IAAA,IAAA,CAAK,GAAA,uBAA0B,GAAA,EAAI;AACnC,IAAA,IAAA,CAAK,GAAA,GAAM,GAAA;AACX,IAAA,IAAA,CAAK,KAAA,GAAQ,KAAA;AAAA,EACf;AAAA,EACA,IAAI,GAAA,EAAK;AACP,IAAA,MAAM,KAAA,GAAQ,IAAA,CAAK,GAAA,CAAI,GAAA,CAAI,GAAG,CAAA;AAC9B,IAAA,IAAI,CAAC,OAA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QAAA,GAAW,MAAA,CAAA;AACzF,EAAA,IAAI,CAAC,cAAA,EAAgB;AACnB,IAAA,IAAI,QAAQ,MAAA,EAAQ;AACpB,IAAA,MAAM,IAAI,MAAM,iDAAiD,CAAA;AAAA,EACnE;AAEA,EAAA,MAAM,OAAA,GAAU,QAAQ,OAAA,IAAW,uBAAA;AACnC,EAAA,IAAI,OAAA,GAAU,cAAA,CAAe,cAAA,CAAe,OAAO,CAAA;AACnD,EAAA,IAAI,CAAC,OAAA,EAAS;AACZ,IAAA,IAAI,CAAC,eAAe,IAAA,EAAM;AACxB,MAAA,IAAI,QAAQ,MAAA,EAAQ;AACpB,MAAA,MAAM,IAAI,MAAM,qDAAqD,CAAA;AAAA,IACvE;AACA,IAAA,OAAA,GAAU,cAAA,CAAe,cAAc,OAAO,CAAA;AAC9C,IAAA,OAAA,CAAQ,EAAA,GAAK,OAAA;AACb,IAAA,cAAA,CAAe,IAAA,CAAK,YAAY,OAAO,CAAA;AAAA,EACzC;AAEA,EAAA,OAAA,CAAQ,WAAA,GAAc,SAAS,UAAA,EAAW;AAC5C;AAIO,IAAM,UAAA,GAAa,uBAAuB,eAAe","file":"animate.cjs","sourcesContent":["// src/cache.ts\nvar LRUCache = class {\n constructor(max = 256, ttlMs = null) {\n this.map = /* @__PURE__ */ new Map();\n this.max = max;\n this.ttlMs = ttlMs;\n }\n get(key) {\n const entry = this.map.get(key);\n if (!entry) return void 0;\n if (this.ttlMs !== null && Date.now() - entry.ts > this.ttlMs) {\n this.map.delete(key);\n return void 0;\n }\n this.map.delete(key);\n this.map.set(key, entry);\n return entry.value;\n }\n set(key, value) {\n if (this.map.has(key)) this.map.delete(key);\n else if (this.map.size >= this.max) {\n this.map.delete(this.map.keys().next().value);\n }\n this.map.set(key, { value, ts: Date.now() });\n }\n has(key) {\n return this.get(key) !== void 0;\n }\n delete(key) {\n this.map.delete(key);\n }\n clear() {\n this.map.clear();\n }\n get size() {\n return this.map.size;\n }\n keys() {\n return this.map.keys();\n }\n *values() {\n for (const entry of this.map.values()) {\n yield entry.value;\n }\n }\n *entries() {\n for (const [key, entry] of this.map.entries()) {\n yield [key, entry.value];\n }\n }\n};\n\n// src/nativeBinding.ts\nimport fs from \"fs\";\nimport { createRequire } from \"module\";\nimport path from \"path\";\nimport { fileURLToPath } from \"url\";\nfunction formatErrorMessage(error) {\n return error instanceof Error ? error.message : String(error);\n}\nfunction resolveRuntimeDir(dirnameValue, moduleImportUrl) {\n if (typeof dirnameValue === \"string\" && dirnameValue.length > 0) return dirnameValue;\n return path.dirname(fileURLToPath(moduleImportUrl));\n}\nfunction resolveNativeBindingCandidates(options) {\n const out = [];\n const envVarNames = options.envVarNames ?? [];\n for (const envVarName of envVarNames) {\n const raw = process.env[envVarName]?.trim();\n if (!raw) continue;\n const resolved = path.resolve(raw);\n if (options.enforceNodeExtensionForEnvPath) {\n if (path.extname(resolved).toLowerCase() !== \".node\") {\n throw new Error(\n `Invalid native binding path from ${envVarName}=\"${raw}\". Expected a .node file.`\n );\n }\n }\n out.push(resolved);\n }\n if (options.includeDefaultCandidates !== false) {\n out.push(path.resolve(process.cwd(), \"native\", \"tailwind_styled_parser.node\"));\n out.push(path.resolve(options.runtimeDir, \"..\", \"..\", \"..\", \"native\", \"tailwind_styled_parser.node\"));\n }\n return Array.from(new Set(out));\n}\nfunction parseDebugToken(namespace, token) {\n if (token === \"*\" || token === namespace || token === \"tailwind-styled:*\") return true;\n return token.endsWith(\"*\") && namespace.startsWith(token.slice(0, -1));\n}\nfunction isDebugNamespaceEnabled(namespace) {\n if (process.env.TWS_DEBUG === \"1\" || process.env.TAILWIND_STYLED_DEBUG === \"1\") return true;\n const raw = process.env.DEBUG;\n if (!raw) return false;\n return raw.split(\",\").map((token) => token.trim()).some((token) => parseDebugToken(namespace, token));\n}\nfunction createDebugLogger(namespace, label = namespace) {\n const debugEnabled = isDebugNamespaceEnabled(namespace);\n return (message) => {\n if (!debugEnabled) return;\n console.debug(`[${label}] ${message}`);\n };\n}\nfunction loadNativeBinding(options) {\n const req = createRequire(path.join(options.runtimeDir, \"noop.cjs\"));\n const loadErrors = [];\n for (const candidate of options.candidates) {\n if (!fs.existsSync(candidate)) continue;\n try {\n const mod = req(candidate);\n if (options.isValid(mod)) {\n return {\n binding: mod,\n loadedPath: candidate,\n loadErrors\n };\n }\n loadErrors.push({\n path: candidate,\n message: options.invalidExportMessage\n });\n } catch (error) {\n loadErrors.push({\n path: candidate,\n message: formatErrorMessage(error)\n });\n }\n }\n return {\n binding: null,\n loadedPath: null,\n loadErrors\n };\n}\n\n// src/logger.ts\nvar LEVELS = { silent: 0, error: 1, warn: 2, info: 3, debug: 4 };\nfunction getEnvLevel() {\n const env = process.env.TWS_LOG_LEVEL?.toLowerCase();\n if (env && env in LEVELS) return env;\n return process.env.TWS_DEBUG_SCANNER === \"1\" ? \"debug\" : \"info\";\n}\nfunction createLogger(prefix, level) {\n let currentLevel = level ?? getEnvLevel();\n const log = (msgLevel, stream, args) => {\n if (LEVELS[msgLevel] > LEVELS[currentLevel]) return;\n const line = `[${prefix}] ${args.map(String).join(\" \")}\n`;\n process[stream].write(line);\n };\n return {\n error: (...a) => log(\"error\", \"stderr\", a),\n warn: (...a) => log(\"warn\", \"stderr\", a),\n info: (...a) => log(\"info\", \"stdout\", a),\n debug: (...a) => log(\"debug\", \"stderr\", a),\n setLevel: (l) => {\n currentLevel = l;\n }\n };\n}\nvar logger = createLogger(\"tailwind-styled\");\n\n// src/hash.ts\nimport { createHash } from \"crypto\";\nimport fs2 from \"fs\";\nfunction hashContent(content, algorithm = \"md5\", length = 8) {\n return createHash(algorithm).update(content).digest(\"hex\").slice(0, length);\n}\nfunction hashFile(filePath, algorithm = \"md5\", length = 8) {\n try {\n const content = fs2.readFileSync(filePath, \"utf8\");\n return hashContent(content, algorithm, length);\n } catch {\n return \"00000000\";\n }\n}\n\n// src/timing.ts\nfunction debounce(fn, ms) {\n let timer = null;\n return ((...args) => {\n if (timer) clearTimeout(timer);\n timer = setTimeout(() => {\n timer = null;\n fn(...args);\n }, ms);\n });\n}\nfunction throttle(fn, ms) {\n let last = 0;\n return ((...args) => {\n const now = Date.now();\n if (now - last >= ms) {\n last = now;\n fn(...args);\n }\n });\n}\n\n// src/version.ts\nfunction parseVersion(v) {\n const parts = v.replace(/^v/, \"\").split(\".\").map((p) => {\n const n = Number(p);\n return Number.isNaN(n) ? 0 : n;\n });\n const [major = 0, minor = 0, patch = 0] = parts;\n return { major, minor, patch };\n}\nfunction satisfiesMinVersion(version, minVersion) {\n const v = parseVersion(version);\n const min = parseVersion(minVersion);\n if (v.major !== min.major) return v.major > min.major;\n if (v.minor !== min.minor) return v.minor > min.minor;\n return v.patch >= min.patch;\n}\nexport {\n LRUCache,\n createDebugLogger,\n createLogger,\n debounce,\n formatErrorMessage,\n hashContent,\n hashFile,\n isDebugNamespaceEnabled,\n loadNativeBinding,\n logger,\n parseVersion,\n resolveNativeBindingCandidates,\n resolveRuntimeDir,\n satisfiesMinVersion,\n throttle\n};\n","import {\n createDebugLogger,\n loadNativeBinding,\n resolveNativeBindingCandidates,\n resolveRuntimeDir,\n} from \"@tailwind-styled/shared\"\n\nimport type { NativeAnimateBinding } from \"./types\"\n\nlet bindingPromise: Promise<NativeAnimateBinding> | null = null\nconst DEBUG_NAMESPACE = \"tailwind-styled:animate\"\nconst debugLog = createDebugLogger(DEBUG_NAMESPACE, \"tailwind-styled/animate\")\n\nfunction isAnimateModule(module: unknown): module is NativeAnimateBinding {\n const candidate = module as Partial<NativeAnimateBinding> | null | undefined\n return (\n typeof candidate?.compileAnimation === \"function\" &&\n typeof candidate?.compileKeyframes === \"function\"\n )\n}\n\nfunction resolveBindingCandidates(runtimeDir: string): string[] {\n return resolveNativeBindingCandidates({\n runtimeDir,\n envVarNames: [\"TWS_ANIMATE_NATIVE_PATH\", \"TWS_NATIVE_PATH\"],\n enforceNodeExtensionForEnvPath: true,\n })\n}\n\nfunction loadAnimateBinding(): NativeAnimateBinding {\n if (process.env.TWS_NO_NATIVE === \"1\" || process.env.TWS_NO_RUST === \"1\") {\n throw new Error(\"Native animate backend is required in v5. TWS_NO_NATIVE/TWS_NO_RUST is not supported.\")\n }\n\n const runtimeDir = resolveRuntimeDir(\n typeof __dirname === \"string\" ? __dirname : undefined,\n import.meta.url\n )\n const candidates = resolveBindingCandidates(runtimeDir)\n const { binding, loadErrors, loadedPath } = loadNativeBinding<NativeAnimateBinding>({\n runtimeDir,\n candidates,\n isValid: isAnimateModule,\n invalidExportMessage: \"Module loaded but missing compileAnimation/compileKeyframes exports.\",\n })\n\n if (binding) {\n debugLog(`native animate binding loaded from: ${loadedPath}`)\n return binding\n }\n\n if (loadErrors.length > 0) {\n debugLog(\n `native animate binding load failed for ${loadErrors.length} candidate(s): ${loadErrors\n .map((entry) => `${entry.path} (${entry.message})`)\n .join(\"; \")}`\n )\n } else {\n debugLog(\"native animate binding not found in any candidate path\")\n }\n\n const lines = [\n \"Native animate backend not found. Ensure `tailwind_styled_parser.node` is built.\",\n \"Checked paths:\",\n ...candidates.map((candidate) => `- ${candidate}`),\n ]\n if (loadErrors.length > 0) {\n lines.push(\"Load errors:\")\n for (const error of loadErrors) lines.push(`- ${error.path}: ${error.message}`)\n }\n throw new Error(lines.join(\"\\n\"))\n}\n\nexport async function getAnimateBinding(): Promise<NativeAnimateBinding> {\n if (!bindingPromise) {\n bindingPromise = Promise.resolve().then(loadAnimateBinding)\n }\n return bindingPromise\n}\n\nexport async function initAnimate(): Promise<void> {\n await getAnimateBinding()\n}\n","import { LRUCache } from \"@tailwind-styled/shared\"\n\nimport type { AnimationRegistry } from \"./registry\"\n\nconst DEFAULT_PRESET_CACHE_LIMIT = 32\n\nexport function createAnimationPresets(registry: AnimationRegistry) {\n const cache = new LRUCache<string, Promise<string>>(DEFAULT_PRESET_CACHE_LIMIT)\n\n const withCache = (\n cacheKey: string,\n factory: () => Promise<string>\n ): (() => Promise<string>) => async () => {\n const cached = cache.get(cacheKey)\n if (cached) {\n const className = await cached\n if (registry.has(className)) return className\n cache.delete(cacheKey)\n }\n\n const pending = factory()\n cache.set(cacheKey, pending)\n try {\n return await pending\n } catch (error) {\n cache.delete(cacheKey)\n throw error\n }\n }\n\n return {\n fadeIn: withCache(\n \"fadeIn\",\n async () =>\n (await registry.compileAnimation({ from: \"opacity-0\", to: \"opacity-100\", duration: 200 }))\n .className\n ),\n fadeOut: withCache(\n \"fadeOut\",\n async () =>\n (await registry.compileAnimation({ from: \"opacity-100\", to: \"opacity-0\", duration: 200 }))\n .className\n ),\n slideUp: withCache(\n \"slideUp\",\n async () =>\n (\n await registry.compileAnimation({\n from: \"opacity-0 translate-y-4\",\n to: \"opacity-100 translate-y-0\",\n duration: 300,\n })\n ).className\n ),\n slideDown: withCache(\n \"slideDown\",\n async () =>\n (\n await registry.compileAnimation({\n from: \"opacity-0 -translate-y-4\",\n to: \"opacity-100 translate-y-0\",\n duration: 300,\n })\n ).className\n ),\n slideLeft: withCache(\n \"slideLeft\",\n async () =>\n (\n await registry.compileAnimation({\n from: \"opacity-0 translate-x-4\",\n to: \"opacity-100 translate-x-0\",\n duration: 300,\n })\n ).className\n ),\n slideRight: withCache(\n \"slideRight\",\n async () =>\n (\n await registry.compileAnimation({\n from: \"opacity-0 -translate-x-4\",\n to: \"opacity-100 translate-x-0\",\n duration: 300,\n })\n ).className\n ),\n scaleIn: withCache(\n \"scaleIn\",\n async () =>\n (\n await registry.compileAnimation({\n from: \"opacity-0 scale-95\",\n to: \"opacity-100 scale-100\",\n duration: 200,\n easing: \"cubic-bezier(0.16,1,0.3,1)\",\n })\n ).className\n ),\n scaleOut: withCache(\n \"scaleOut\",\n async () =>\n (\n await registry.compileAnimation({\n from: \"opacity-100 scale-100\",\n to: \"opacity-0 scale-95\",\n duration: 150,\n })\n ).className\n ),\n blurIn: withCache(\n \"blurIn\",\n async () =>\n (\n await registry.compileAnimation({\n from: \"opacity-0 blur-sm\",\n to: \"opacity-100 blur-none\",\n duration: 300,\n })\n ).className\n ),\n bounceIn: withCache(\n \"bounceIn\",\n async () =>\n (\n await registry.compileAnimation({\n from: \"opacity-0 scale-50\",\n to: \"opacity-100 scale-100\",\n duration: 400,\n easing: \"cubic-bezier(0.34,1.56,0.64,1)\",\n })\n ).className\n ),\n spinIn: withCache(\n \"spinIn\",\n async () =>\n (\n await registry.compileAnimation({\n from: \"opacity-0 rotate-180 scale-50\",\n to: \"opacity-100 rotate-0 scale-100\",\n duration: 400,\n easing: \"cubic-bezier(0.16,1,0.3,1)\",\n })\n ).className\n ),\n } as const\n}\n","// src/analyzeWorkspace.ts\nimport path2 from \"path\";\nimport { scanWorkspaceAsync } from \"@tailwind-styled/scanner\";\n\n// src/binding.ts\nimport {\n loadNativeBinding,\n resolveNativeBindingCandidates,\n resolveRuntimeDir\n} from \"@tailwind-styled/shared\";\n\n// src/utils.ts\nimport fs from \"fs\";\nimport { createDebugLogger } from \"@tailwind-styled/shared\";\nvar DEFAULT_TOP_LIMIT = 10;\nvar DEFAULT_FREQUENT_THRESHOLD = 2;\nvar DEBUG_NAMESPACE = \"tailwind-styled:analyzer\";\nfunction formatErrorMessage(error) {\n return error instanceof Error ? error.message : String(error);\n}\nfunction isRecord(value) {\n if (!value || typeof value !== \"object\" || Array.isArray(value)) return false;\n const proto = Object.getPrototypeOf(value);\n return proto === Object.prototype || proto === null;\n}\nasync function pathExists(filePath) {\n try {\n await fs.promises.access(filePath, fs.constants.F_OK);\n return true;\n } catch {\n return false;\n }\n}\nvar debugLog = createDebugLogger(DEBUG_NAMESPACE, \"tailwind-styled/analyzer\");\nfunction sanitizeTopLimit(value) {\n if (!Number.isFinite(value)) return DEFAULT_TOP_LIMIT;\n return Math.max(1, Math.trunc(value));\n}\nfunction sanitizeFrequentThreshold(value) {\n if (!Number.isFinite(value)) return DEFAULT_FREQUENT_THRESHOLD;\n return Math.max(1, Math.trunc(value));\n}\n\n// src/binding.ts\nvar bindingCache;\nvar bindingCandidateCache = [];\nvar bindingLoadErrorsCache = [];\nvar loadedBindingPathCache = null;\nfunction isAnalyzerModule(module) {\n const candidate = module;\n return typeof candidate?.analyzeClasses === \"function\";\n}\nfunction getNativeBinding() {\n if (bindingCache !== void 0) return bindingCache;\n if (process.env.TWS_NO_NATIVE === \"1\" || process.env.TWS_NO_RUST === \"1\") {\n bindingCandidateCache = [];\n bindingLoadErrorsCache = [];\n loadedBindingPathCache = null;\n debugLog(\"native binding disabled by TWS_NO_NATIVE/TWS_NO_RUST\");\n bindingCache = null;\n return bindingCache;\n }\n const runtimeDir = resolveRuntimeDir(\n typeof __dirname === \"string\" ? __dirname : void 0,\n import.meta.url\n );\n const candidates = resolveNativeBindingCandidates({\n runtimeDir,\n envVarNames: [\"TWS_NATIVE_PATH\"]\n });\n const { binding, loadErrors, loadedPath } = loadNativeBinding({\n runtimeDir,\n candidates,\n isValid: isAnalyzerModule,\n invalidExportMessage: \"Module loaded but missing `analyzeClasses` export.\"\n });\n bindingCandidateCache = candidates;\n bindingLoadErrorsCache = loadErrors;\n loadedBindingPathCache = loadedPath;\n if (binding) {\n debugLog(`native binding loaded from: ${loadedPath}`);\n bindingCache = binding;\n return bindingCache;\n }\n if (bindingLoadErrorsCache.length > 0) {\n debugLog(\n `native binding load failed for ${bindingLoadErrorsCache.length} candidate(s): ${bindingLoadErrorsCache.map((entry) => `${entry.path} (${entry.message})`).join(\"; \")}`\n );\n } else {\n debugLog(\"native binding not found in any candidate path\");\n }\n bindingCache = null;\n return bindingCache;\n}\nfunction requireNativeBinding() {\n const binding = getNativeBinding();\n if (binding?.analyzeClasses) return binding;\n const lines = [\n \"Native analyzer binding not found. Ensure `tailwind_styled_parser.node` is built.\"\n ];\n if (process.env.TWS_NO_NATIVE === \"1\" || process.env.TWS_NO_RUST === \"1\") {\n lines.push(\"Native loading is disabled by TWS_NO_NATIVE/TWS_NO_RUST.\");\n } else {\n lines.push(\"Checked paths:\");\n for (const candidate of bindingCandidateCache) lines.push(`- ${candidate}`);\n if (bindingLoadErrorsCache.length > 0) {\n lines.push(\"Load errors:\");\n for (const failure of bindingLoadErrorsCache) {\n lines.push(`- ${failure.path}: ${failure.message}`);\n }\n }\n }\n throw new Error(lines.join(\"\\n\"));\n}\nfunction requireNativeCssCompiler() {\n const binding = requireNativeBinding();\n if (typeof binding.compileCss === \"function\") return binding;\n const loadedPathText = loadedBindingPathCache ? ` (${loadedBindingPathCache})` : \"\";\n throw new Error(`Native analyzer compileCss binding is missing in v5${loadedPathText}.`);\n}\n\n// src/semantic.ts\nimport fs2 from \"fs\";\nimport path from \"path\";\nimport { pathToFileURL } from \"url\";\nvar SUPPORTED_TAILWIND_CONFIG_EXTENSIONS = /* @__PURE__ */ new Set([\".ts\", \".js\", \".cjs\", \".mjs\"]);\nvar KNOWN_UTILITY_PREFIXES = /* @__PURE__ */ new Set([\n \"absolute\",\n \"align\",\n \"animate\",\n \"arbitrary\",\n \"aspect\",\n \"backdrop\",\n \"basis\",\n \"bg\",\n \"block\",\n \"border\",\n \"bottom\",\n \"col\",\n \"container\",\n \"contents\",\n \"cursor\",\n \"dark\",\n \"display\",\n \"divide\",\n \"fill\",\n \"fixed\",\n \"flex\",\n \"float\",\n \"font\",\n \"from\",\n \"gap\",\n \"grid\",\n \"grow\",\n \"h\",\n \"hidden\",\n \"inset\",\n \"inline\",\n \"isolate\",\n \"items\",\n \"justify\",\n \"left\",\n \"leading\",\n \"line\",\n \"list\",\n \"m\",\n \"max-h\",\n \"max-w\",\n \"mb\",\n \"min-h\",\n \"min-w\",\n \"ml\",\n \"mr\",\n \"mt\",\n \"mx\",\n \"my\",\n \"object\",\n \"opacity\",\n \"order\",\n \"origin\",\n \"outline\",\n \"overflow\",\n \"overscroll\",\n \"p\",\n \"pb\",\n \"pe\",\n \"perspective\",\n \"place\",\n \"pl\",\n \"pointer\",\n \"position\",\n \"pr\",\n \"ps\",\n \"pt\",\n \"px\",\n \"py\",\n \"relative\",\n \"right\",\n \"ring\",\n \"rotate\",\n \"rounded\",\n \"row\",\n \"scale\",\n \"shadow\",\n \"shrink\",\n \"size\",\n \"skew\",\n \"snap\",\n \"space-x\",\n \"space-y\",\n \"sr\",\n \"start\",\n \"static\",\n \"sticky\",\n \"stroke\",\n \"table\",\n \"text\",\n \"to\",\n \"top\",\n \"touch\",\n \"tracking\",\n \"transform\",\n \"transition\",\n \"translate\",\n \"truncate\",\n \"underline\",\n \"via\",\n \"visible\",\n \"w\",\n \"whitespace\",\n \"z\"\n]);\nvar tailwindConfigCache = /* @__PURE__ */ new Map();\nfunction splitVariantAndBase(className) {\n const parts = className.split(\":\");\n if (parts.length <= 1) return { variantKey: \"\", base: className };\n const base = parts.pop() ?? className;\n return { variantKey: parts.join(\":\"), base };\n}\nfunction isArbitraryUtility(baseClass) {\n return baseClass.includes(\"[\") && baseClass.includes(\"]\");\n}\nfunction resolveConflictGroup(base) {\n if (isArbitraryUtility(base)) return null;\n if ([\"block\", \"inline\", \"inline-block\", \"inline-flex\", \"flex\", \"grid\", \"hidden\"].includes(base))\n return \"display\";\n if (base.startsWith(\"bg-\")) return \"bg\";\n if (base.startsWith(\"text-\")) return \"text\";\n if (base.startsWith(\"font-\")) return \"font\";\n if (base.startsWith(\"rounded\")) return \"rounded\";\n if (base.startsWith(\"shadow\")) return \"shadow\";\n if (base.startsWith(\"border-\")) return \"border\";\n if (base.startsWith(\"opacity-\")) return \"opacity\";\n if (base.startsWith(\"w-\") || base.startsWith(\"min-w-\") || base.startsWith(\"max-w-\")) return \"width\";\n if (base.startsWith(\"h-\") || base.startsWith(\"min-h-\") || base.startsWith(\"max-h-\")) return \"height\";\n if (base.startsWith(\"p-\") || base.startsWith(\"px-\") || base.startsWith(\"py-\")) return \"padding\";\n if (base.startsWith(\"m-\") || base.startsWith(\"mx-\") || base.startsWith(\"my-\")) return \"margin\";\n return null;\n}\nfunction detectConflicts(usages) {\n const buckets = /* @__PURE__ */ new Map();\n for (const usage of usages) {\n const { variantKey, base } = splitVariantAndBase(usage.name);\n const group = resolveConflictGroup(base);\n if (!group) continue;\n const key = `${variantKey}::${group}`;\n const bucket = buckets.get(key) ?? {\n variantKey,\n group,\n classes: /* @__PURE__ */ new Set()\n };\n bucket.classes.add(usage.name);\n buckets.set(key, bucket);\n }\n const conflicts = [];\n const conflictedClassNames = /* @__PURE__ */ new Set();\n for (const bucket of buckets.values()) {\n if (bucket.classes.size <= 1) continue;\n const classes = Array.from(bucket.classes).sort();\n for (const className of classes) conflictedClassNames.add(className);\n const variantLabel = bucket.variantKey.length > 0 ? bucket.variantKey : \"base\";\n conflicts.push({\n className: bucket.group,\n variants: bucket.variantKey.length > 0 ? bucket.variantKey.split(\":\") : [],\n classes,\n message: `Multiple ${bucket.group} utilities detected for \"${variantLabel}\".`\n });\n }\n conflicts.sort((left, right) => {\n if (right.classes.length !== left.classes.length) return right.classes.length - left.classes.length;\n return left.className.localeCompare(right.className);\n });\n return { conflicts, conflictedClassNames };\n}\nfunction isSupportedTailwindConfigPath(configPath) {\n return SUPPORTED_TAILWIND_CONFIG_EXTENSIONS.has(path.extname(configPath).toLowerCase());\n}\nasync function resolveTailwindConfigPath(root, explicitPath) {\n if (explicitPath) {\n const resolved = path.resolve(root, explicitPath);\n if (!await pathExists(resolved)) return null;\n return resolved;\n }\n const candidates = [\n \"tailwind.config.ts\",\n \"tailwind.config.js\",\n \"tailwind.config.cjs\",\n \"tailwind.config.mjs\"\n ];\n for (const candidate of candidates) {\n const fullPath = path.resolve(root, candidate);\n if (await pathExists(fullPath)) return fullPath;\n }\n return null;\n}\nfunction collectSafelistFromConfig(config) {\n const raw = config.safelist;\n if (!Array.isArray(raw)) return [];\n const out = /* @__PURE__ */ new Set();\n for (const entry of raw) {\n if (typeof entry === \"string\" && entry.length > 0) {\n out.add(entry);\n continue;\n }\n if (!entry || typeof entry !== \"object\") continue;\n const pattern = entry.pattern;\n if (typeof pattern === \"string\" && pattern.length > 0) {\n out.add(pattern);\n }\n }\n return Array.from(out);\n}\nfunction collectCustomUtilities(config) {\n const out = /* @__PURE__ */ new Set();\n const theme = config.theme;\n if (!theme || typeof theme !== \"object\") return out;\n const extend = theme.extend;\n if (!extend || typeof extend !== \"object\") return out;\n for (const [section, value] of Object.entries(extend)) {\n if (!value || typeof value !== \"object\" || Array.isArray(value)) continue;\n for (const key of Object.keys(value)) {\n out.add(`${section}-${key}`);\n if (section === \"colors\") {\n out.add(`bg-${key}`);\n out.add(`text-${key}`);\n out.add(`border-${key}`);\n } else if (section === \"spacing\") {\n out.add(`p-${key}`);\n out.add(`m-${key}`);\n out.add(`gap-${key}`);\n out.add(`w-${key}`);\n out.add(`h-${key}`);\n } else if (section === \"fontSize\") {\n out.add(`text-${key}`);\n } else if (section === \"borderRadius\") {\n out.add(`rounded-${key}`);\n } else if (section === \"boxShadow\") {\n out.add(`shadow-${key}`);\n }\n }\n }\n return out;\n}\nasync function collectSafelistFromSource(configPath) {\n const source = await fs2.promises.readFile(configPath, \"utf8\");\n const safelistBlock = source.match(/safelist\\s*:\\s*\\[([\\s\\S]*?)\\]/m)?.[1];\n if (!safelistBlock) return [];\n const out = /* @__PURE__ */ new Set();\n const tokenRegex = /[\"'`]([^\"'`]+)[\"'`]/g;\n let token = tokenRegex.exec(safelistBlock);\n while (token) {\n const value = token[1].trim();\n if (value.length > 0) out.add(value);\n token = tokenRegex.exec(safelistBlock);\n }\n return Array.from(out);\n}\nasync function loadTailwindConfig(root, semanticOption) {\n const startMs = Date.now();\n const configPath = await resolveTailwindConfigPath(root, semanticOption?.tailwindConfigPath);\n if (!configPath) return null;\n if (!isSupportedTailwindConfigPath(configPath)) {\n return {\n path: configPath,\n loaded: false,\n warning: `Unsupported Tailwind config extension at \"${configPath}\". Supported extensions: .ts, .js, .cjs, .mjs.`,\n safelist: /* @__PURE__ */ new Set(),\n customUtilities: /* @__PURE__ */ new Set()\n };\n }\n const configStat = await fs2.promises.stat(configPath).catch(() => null);\n if (configStat) {\n const cached = tailwindConfigCache.get(configPath);\n if (cached && cached.mtimeMs === configStat.mtimeMs && cached.size === configStat.size) {\n debugLog(\n `tailwind config cache hit: ${configPath} (${cached.config.safelist.size} safelist entries)`\n );\n return cached.config;\n }\n }\n let config = null;\n let warning;\n try {\n const cacheBustToken = Math.trunc(configStat?.mtimeMs ?? Date.now());\n const imported = await import(`${pathToFileURL(configPath).href}?tws_mtime=${cacheBustToken}`);\n const candidate = imported.default ?? imported;\n if (isRecord(candidate)) {\n config = candidate;\n } else if (typeof candidate === \"function\") {\n const evaluated = candidate();\n if (isRecord(evaluated)) {\n config = evaluated;\n } else {\n warning = \"Tailwind config export function must return an object.\";\n }\n } else {\n warning = \"Tailwind config export must be an object or a function returning an object.\";\n }\n } catch (error) {\n warning = formatErrorMessage(error);\n }\n const safelist = /* @__PURE__ */ new Set();\n const customUtilities = /* @__PURE__ */ new Set();\n if (config) {\n for (const item of collectSafelistFromConfig(config)) safelist.add(item);\n for (const item of collectCustomUtilities(config)) customUtilities.add(item);\n }\n if (safelist.size === 0) {\n try {\n for (const item of await collectSafelistFromSource(configPath)) safelist.add(item);\n } catch (error) {\n debugLog(\n `failed to parse safelist from source at \"${configPath}\": ${formatErrorMessage(error)}`\n );\n }\n }\n const loaded = {\n path: configPath,\n loaded: config !== null,\n warning,\n safelist,\n customUtilities\n };\n if (configStat) {\n tailwindConfigCache.set(configPath, {\n mtimeMs: configStat.mtimeMs,\n size: configStat.size,\n config: loaded\n });\n }\n debugLog(\n `tailwind config loaded from \"${configPath}\" in ${Date.now() - startMs}ms (loaded=${loaded.loaded}, safelist=${loaded.safelist.size}, custom=${loaded.customUtilities.size})`\n );\n return loaded;\n}\nfunction utilityPrefix(baseClass) {\n const normalized = baseClass.startsWith(\"-\") ? baseClass.slice(1) : baseClass;\n if (normalized.includes(\"[\") && normalized.includes(\"]\")) return \"arbitrary\";\n if (normalized.startsWith(\"min-w-\")) return \"min-w\";\n if (normalized.startsWith(\"max-w-\")) return \"max-w\";\n if (normalized.startsWith(\"min-h-\")) return \"min-h\";\n if (normalized.startsWith(\"max-h-\")) return \"max-h\";\n if (normalized.startsWith(\"space-x-\")) return \"space-x\";\n if (normalized.startsWith(\"space-y-\")) return \"space-y\";\n if (normalized.startsWith(\"inline-\")) return \"inline\";\n if (normalized.startsWith(\"border-\")) return \"border\";\n if (normalized.startsWith(\"text-\")) return \"text\";\n if (normalized.startsWith(\"bg-\")) return \"bg\";\n if (normalized.startsWith(\"rounded\")) return \"rounded\";\n if (normalized.startsWith(\"shadow\")) return \"shadow\";\n const hyphen = normalized.indexOf(\"-\");\n if (hyphen < 0) return normalized;\n return normalized.slice(0, hyphen);\n}\nfunction isKnownTailwindClass(className, safelist, customUtilities) {\n if (safelist.has(className) || customUtilities.has(className)) return true;\n const { base } = splitVariantAndBase(className);\n if (customUtilities.has(base)) return true;\n const prefix = utilityPrefix(base);\n return KNOWN_UTILITY_PREFIXES.has(prefix);\n}\nasync function buildSemanticReport(usages, root, semanticOption) {\n const loadedConfig = await loadTailwindConfig(root, semanticOption);\n const safelist = loadedConfig?.safelist ?? /* @__PURE__ */ new Set();\n const customUtilities = loadedConfig?.customUtilities ?? /* @__PURE__ */ new Set();\n const usageNames = new Set(usages.map((usage) => usage.name));\n const unusedClasses = Array.from(safelist).filter((className) => !usageNames.has(className)).sort().map((className) => ({ name: className, count: 0, isUnused: true }));\n const unknownClasses = usages.filter((usage) => !isKnownTailwindClass(usage.name, safelist, customUtilities)).map((usage) => ({ ...usage, isUnused: true }));\n const { conflicts } = detectConflicts(usages);\n return {\n unusedClasses,\n unknownClasses,\n conflicts,\n ...loadedConfig ? {\n tailwindConfig: {\n path: loadedConfig.path,\n loaded: loadedConfig.loaded,\n safelistCount: loadedConfig.safelist.size,\n customUtilityCount: loadedConfig.customUtilities.size,\n ...loadedConfig.warning ? { warning: loadedConfig.warning } : {}\n }\n } : {}\n };\n}\n\n// src/analyzeWorkspace.ts\nfunction normalizeScan(scan, includeClass) {\n if (!includeClass) return scan;\n const filteredFiles = scan.files.map((file) => ({\n file: file.file,\n classes: file.classes.filter((className) => includeClass(className))\n }));\n const unique = /* @__PURE__ */ new Set();\n for (const file of filteredFiles) {\n for (const className of file.classes) unique.add(className);\n }\n return {\n files: filteredFiles,\n totalFiles: scan.totalFiles,\n uniqueClasses: Array.from(unique).sort()\n };\n}\nfunction collectClassCounts(scan) {\n const counts = /* @__PURE__ */ new Map();\n for (const file of scan.files) {\n for (const className of file.classes) {\n counts.set(className, (counts.get(className) ?? 0) + 1);\n }\n }\n return counts;\n}\nfunction buildClassUsage(counts) {\n return Array.from(counts.entries()).map(([name, count]) => ({ name, count })).sort((left, right) => {\n if (right.count !== left.count) return right.count - left.count;\n return left.name.localeCompare(right.name);\n });\n}\nfunction buildDistribution(usages) {\n const distribution = {\n \"1\": 0,\n \"2-3\": 0,\n \"4-7\": 0,\n \"8+\": 0\n };\n for (const usage of usages) {\n if (usage.count === 1) {\n distribution[\"1\"] += 1;\n continue;\n }\n if (usage.count <= 3) {\n distribution[\"2-3\"] += 1;\n continue;\n }\n if (usage.count <= 7) {\n distribution[\"4-7\"] += 1;\n continue;\n }\n distribution[\"8+\"] += 1;\n }\n return distribution;\n}\nasync function analyzeWorkspace(root, options = {}) {\n const startedAtMs = Date.now();\n const resolvedRoot = path2.resolve(root);\n const scanStartedAtMs = Date.now();\n let scan;\n try {\n scan = await scanWorkspaceAsync(resolvedRoot, options.scanner);\n } catch (error) {\n throw new Error(\n `Failed to scan workspace at \"${resolvedRoot}\": ${formatErrorMessage(error)}`,\n { cause: error }\n );\n }\n debugLog(`scanWorkspaceAsync processed ${scan.totalFiles} files in ${Date.now() - scanStartedAtMs}ms`);\n const normalizedScan = normalizeScan(scan, options.includeClass);\n const topLimit = sanitizeTopLimit(options.classStats?.top);\n const frequentThreshold = sanitizeFrequentThreshold(options.classStats?.frequentThreshold);\n const binding = requireNativeBinding();\n const filesJson = JSON.stringify(\n normalizedScan.files.map((file) => ({ file: file.file, classes: file.classes }))\n );\n let nativeReport = null;\n try {\n nativeReport = binding.analyzeClasses(filesJson, resolvedRoot, topLimit);\n } catch (error) {\n throw new Error(\n `Native analyzer failed for \"${resolvedRoot}\": ${formatErrorMessage(error)}`,\n { cause: error }\n );\n }\n if (!nativeReport) {\n throw new Error(`Native analyzer returned no report for \"${resolvedRoot}\".`);\n }\n const counts = collectClassCounts(normalizedScan);\n let all = buildClassUsage(counts);\n let semanticReport;\n if (options.semantic) {\n const semanticOption = typeof options.semantic === \"object\" ? options.semantic : void 0;\n const semanticStartedAtMs = Date.now();\n try {\n semanticReport = await buildSemanticReport(all, resolvedRoot, semanticOption);\n } catch (error) {\n throw new Error(\n `Failed to build semantic report for \"${resolvedRoot}\": ${formatErrorMessage(error)}`,\n { cause: error }\n );\n }\n debugLog(`semantic report built in ${Date.now() - semanticStartedAtMs}ms`);\n if (semanticReport.conflicts.length > 0) {\n const conflicted = new Set(\n semanticReport.conflicts.flatMap((conflict) => conflict.classes)\n );\n all = all.map(\n (usage) => conflicted.has(usage.name) ? { ...usage, isConflict: true } : usage\n );\n }\n }\n const top = all.slice(0, topLimit);\n const frequent = all.filter((usage) => usage.count >= frequentThreshold).slice(0, topLimit);\n const unique = all.filter((usage) => usage.count === 1);\n const totalClassOccurrences = all.reduce((sum, usage) => sum + usage.count, 0);\n debugLog(\n `analyzeWorkspace completed in ${Date.now() - startedAtMs}ms (files=${normalizedScan.totalFiles}, uniqueClasses=${all.length})`\n );\n return {\n root: nativeReport.root || resolvedRoot,\n totalFiles: nativeReport.totalFiles,\n uniqueClassCount: all.length,\n totalClassOccurrences,\n classStats: {\n all,\n top,\n frequent,\n unique,\n distribution: buildDistribution(all)\n },\n safelist: all.map((usage) => usage.name),\n ...semanticReport ? { semantic: semanticReport } : {}\n };\n}\n\n// src/classToCss.ts\nfunction normalizeClassInput(input) {\n if (typeof input === \"string\") {\n return input.split(/\\s+/).map((item) => item.trim()).filter((item) => item.length > 0);\n }\n if (!Array.isArray(input)) {\n throw new TypeError(\"classToCss input must be a string or an array of strings.\");\n }\n const out = [];\n for (const item of input) {\n if (typeof item !== \"string\") {\n throw new TypeError(\"classToCss input array must contain only strings.\");\n }\n const value = item.trim();\n if (value.length > 0) out.push(value);\n }\n return out;\n}\nfunction normalizeClassToCssOptions(options) {\n if (!options || typeof options !== \"object\" || Array.isArray(options)) {\n throw new TypeError(\"classToCss options must be an object.\");\n }\n const strict = options.strict ?? false;\n if (typeof strict !== \"boolean\") {\n throw new TypeError(\"classToCss options.strict must be a boolean when provided.\");\n }\n const prefix = options.prefix ?? null;\n if (prefix !== null && typeof prefix !== \"string\") {\n throw new TypeError(\"classToCss options.prefix must be a string or null when provided.\");\n }\n return { prefix, strict };\n}\nfunction mergeDeclarationMap(target, css) {\n const ruleRegex = /\\{([^}]*)\\}/g;\n let ruleMatch = ruleRegex.exec(css);\n while (ruleMatch) {\n const body = ruleMatch[1];\n for (const raw of body.split(\";\")) {\n const declaration = raw.trim();\n if (declaration.length === 0) continue;\n const colonIndex = declaration.indexOf(\":\");\n if (colonIndex <= 0) continue;\n const property = declaration.slice(0, colonIndex).trim();\n const value = declaration.slice(colonIndex + 1).trim();\n if (property.length === 0 || value.length === 0) continue;\n if (target.has(property)) target.delete(property);\n target.set(property, value);\n }\n ruleMatch = ruleRegex.exec(css);\n }\n}\nfunction declarationMapToString(declarationMap) {\n return Array.from(declarationMap.entries()).map(([property, value]) => `${property}: ${value}`).join(\"; \");\n}\nasync function classToCss(input, options = {}) {\n const inputClasses = normalizeClassInput(input);\n const normalizedOptions = normalizeClassToCssOptions(options);\n if (inputClasses.length === 0) {\n return {\n inputClasses: [],\n css: \"\",\n declarations: \"\",\n resolvedClasses: [],\n unknownClasses: [],\n sizeBytes: 0\n };\n }\n const binding = requireNativeCssCompiler();\n const prefix = normalizedOptions.prefix;\n const cssChunks = [];\n const resolvedClasses = [];\n const unknownClasses = [];\n let sizeBytes = 0;\n const declarationMap = /* @__PURE__ */ new Map();\n for (const className of inputClasses) {\n let compiled = null;\n try {\n compiled = binding.compileCss([className], prefix);\n } catch (error) {\n throw new Error(\n `Native analyzer failed while compiling class \"${className}\": ${formatErrorMessage(error)}`,\n { cause: error }\n );\n }\n if (!compiled) {\n throw new Error(`Native analyzer returned no result for class \"${className}\".`);\n }\n cssChunks.push(compiled.css);\n resolvedClasses.push(...compiled.resolvedClasses);\n unknownClasses.push(...compiled.unknownClasses);\n sizeBytes += compiled.sizeBytes;\n mergeDeclarationMap(declarationMap, compiled.css);\n }\n const uniqueUnknown = Array.from(new Set(unknownClasses));\n if (normalizedOptions.strict && uniqueUnknown.length > 0) {\n throw new Error(`Unknown Tailwind classes: ${uniqueUnknown.join(\", \")}`);\n }\n return {\n inputClasses,\n css: cssChunks.filter((chunk) => chunk.length > 0).join(\"\\n\"),\n declarations: declarationMapToString(declarationMap),\n resolvedClasses: Array.from(new Set(resolvedClasses)),\n unknownClasses: uniqueUnknown,\n sizeBytes\n };\n}\n\n// src/index.ts\nvar __internal = {\n normalizeClassInput,\n splitVariantAndBase,\n resolveConflictGroup,\n collectClassCounts,\n buildDistribution,\n utilityPrefix\n};\nexport {\n __internal,\n analyzeWorkspace,\n classToCss\n};\n","import { classToCss } from \"@tailwind-styled/analyzer\"\nimport { LRUCache, formatErrorMessage } from \"@tailwind-styled/shared\"\n\nimport { getAnimateBinding } from \"./binding\"\nimport type {\n AnimateOptions,\n AnimationRegistryOptions,\n CompiledAnimation,\n KeyframesDefinition,\n} from \"./types\"\n\nconst DEFAULT_DURATION = 300\nconst DEFAULT_EASING = \"ease-out\"\nconst DEFAULT_DELAY = 0\nconst DEFAULT_FILL = \"both\"\nconst DEFAULT_ITERATIONS = 1\nconst DEFAULT_DIRECTION = \"normal\"\nconst DEFAULT_CACHE_LIMIT = 512\n\nfunction normalizeNumber(value: number | undefined, fallback: number): number {\n if (!Number.isFinite(value)) return fallback\n return Math.max(0, Math.trunc(value as number))\n}\n\nfunction normalizeCacheLimit(value: number | undefined): number {\n if (!Number.isFinite(value)) return DEFAULT_CACHE_LIMIT\n return Math.max(1, Math.trunc(value as number))\n}\n\nfunction normalizeIterations(value: AnimateOptions[\"iterations\"]): string {\n if (value === \"infinite\") return \"infinite\"\n if (!Number.isFinite(value)) return String(DEFAULT_ITERATIONS)\n return String(Math.max(0, Math.trunc(value as number)))\n}\n\nfunction stableKeyframesEntries(stops: KeyframesDefinition): Array<{ offset: string; classes: string }> {\n return Object.entries(stops)\n .map(([offset, classes]) => ({ offset, classes }))\n .sort((left, right) => left.offset.localeCompare(right.offset))\n}\n\nfunction animationCacheKey(opts: AnimateOptions): string {\n const normalized = {\n from: opts.from.trim(),\n to: opts.to.trim(),\n duration: normalizeNumber(opts.duration, DEFAULT_DURATION),\n easing: (opts.easing ?? DEFAULT_EASING).trim(),\n delay: normalizeNumber(opts.delay, DEFAULT_DELAY),\n fill: opts.fill ?? DEFAULT_FILL,\n iterations: normalizeIterations(opts.iterations),\n direction: opts.direction ?? DEFAULT_DIRECTION,\n name: opts.name ?? \"\",\n }\n return JSON.stringify(normalized)\n}\n\nfunction keyframesCacheKey(name: string, stops: KeyframesDefinition): string {\n return `${name}::${JSON.stringify(stableKeyframesEntries(stops))}`\n}\n\nfunction splitClasses(classList: string): string[] {\n return classList\n .split(/\\s+/)\n .map((item) => item.trim())\n .filter((item) => item.length > 0)\n}\n\nasync function validateTailwindClasses(\n entries: Array<{ classList: string; context: string }>\n): Promise<void> {\n const binding = await getAnimateBinding()\n const unknownByContext = new Map<string, Set<string>>()\n const failures: string[] = []\n\n for (const entry of entries) {\n const classes = splitClasses(entry.classList)\n if (classes.length === 0) continue\n\n try {\n if (typeof binding.compileCss === \"function\") {\n const compiled = binding.compileCss(classes, null)\n if (!compiled) {\n failures.push(`Animation ${entry.context} failed validation: native compileCss returned no result.`)\n continue\n }\n if (compiled.unknownClasses.length > 0) {\n const bucket = unknownByContext.get(entry.context) ?? new Set<string>()\n for (const className of compiled.unknownClasses) bucket.add(className)\n unknownByContext.set(entry.context, bucket)\n }\n continue\n }\n\n const checked = await classToCss(classes, { strict: false })\n if (checked.unknownClasses.length > 0) {\n const bucket = unknownByContext.get(entry.context) ?? new Set<string>()\n for (const className of checked.unknownClasses) bucket.add(className)\n unknownByContext.set(entry.context, bucket)\n }\n } catch (error) {\n failures.push(`Animation ${entry.context} failed validation: ${formatErrorMessage(error)}`)\n }\n }\n\n const issues: string[] = []\n for (const [context, classes] of unknownByContext.entries()) {\n issues.push(`Animation ${context} contains unknown Tailwind classes: ${Array.from(classes).join(\", \")}`)\n }\n issues.push(...failures)\n\n if (issues.length > 0) {\n throw new Error(issues.join(\"\\n\"))\n }\n}\n\nexport class AnimationRegistry {\n private readonly animations: LRUCache<string, CompiledAnimation>\n private readonly animationBySignature: LRUCache<string, string>\n private readonly keyframesBySignature: LRUCache<string, string>\n\n constructor(options: AnimationRegistryOptions = {}) {\n const cacheLimit = normalizeCacheLimit(options.cacheLimit)\n this.animations = new LRUCache(cacheLimit)\n this.animationBySignature = new LRUCache(cacheLimit)\n this.keyframesBySignature = new LRUCache(cacheLimit)\n }\n\n async compileAnimation(opts: AnimateOptions): Promise<CompiledAnimation> {\n const signature = animationCacheKey(opts)\n const existingClassName = this.animationBySignature.get(signature)\n if (existingClassName) {\n const cached = this.animations.get(existingClassName)\n if (cached) return cached\n this.animationBySignature.delete(signature)\n }\n\n await validateTailwindClasses([\n { classList: opts.from, context: `\"from\" in ${opts.name ?? \"anonymous animation\"}` },\n { classList: opts.to, context: `\"to\" in ${opts.name ?? \"anonymous animation\"}` },\n ])\n\n const binding = await getAnimateBinding()\n const duration = normalizeNumber(opts.duration, DEFAULT_DURATION)\n const easing = opts.easing ?? DEFAULT_EASING\n const delay = normalizeNumber(opts.delay, DEFAULT_DELAY)\n const fill = opts.fill ?? DEFAULT_FILL\n const iterations = normalizeIterations(opts.iterations)\n const direction = opts.direction ?? DEFAULT_DIRECTION\n\n const compiled = binding.compileAnimation?.(\n opts.from,\n opts.to,\n opts.name ?? null,\n duration,\n easing,\n delay,\n fill,\n iterations,\n direction\n )\n\n if (!compiled) {\n throw new Error(\n `Native animate backend failed to compile animation \"${opts.name ?? \"anonymous animation\"}\".`\n )\n }\n\n const result: CompiledAnimation = {\n className: compiled.className,\n keyframesCss: compiled.keyframesCss,\n animationCss: compiled.animationCss,\n }\n\n this.animations.set(result.className, result)\n this.animationBySignature.set(signature, result.className)\n return result\n }\n\n async compileKeyframes(name: string, stops: KeyframesDefinition): Promise<CompiledAnimation> {\n const signature = keyframesCacheKey(name, stops)\n const existingClassName = this.keyframesBySignature.get(signature)\n if (existingClassName) {\n const cached = this.animations.get(existingClassName)\n if (cached) return cached\n this.keyframesBySignature.delete(signature)\n }\n\n await validateTailwindClasses(\n Object.entries(stops).map(([offset, classes]) => ({\n classList: classes,\n context: `\"${offset}\" stop in keyframes \"${name}\"`,\n }))\n )\n\n const binding = await getAnimateBinding()\n const stopsJson = JSON.stringify(stableKeyframesEntries(stops))\n const compiled = binding.compileKeyframes?.(name, stopsJson)\n\n if (!compiled) {\n throw new Error(`Native animate backend failed to compile keyframes \"${name}\".`)\n }\n\n const result: CompiledAnimation = {\n className: compiled.className,\n keyframesCss: compiled.keyframesCss,\n animationCss: compiled.animationCss,\n }\n\n this.animations.set(result.className, result)\n this.keyframesBySignature.set(signature, result.className)\n return result\n }\n\n extractCss(): string {\n const lines: string[] = []\n for (const [, compiled] of this.animations.entries()) {\n lines.push(compiled.keyframesCss)\n lines.push(`.${compiled.className} { ${compiled.animationCss} }`)\n }\n return lines.join(\"\\n\\n\")\n }\n\n reset(): void {\n this.animations.clear()\n this.animationBySignature.clear()\n this.keyframesBySignature.clear()\n }\n\n has(className: string): boolean {\n return this.animations.has(className)\n }\n}\n\nexport function createAnimationRegistry(options: AnimationRegistryOptions = {}): AnimationRegistry {\n return new AnimationRegistry(options)\n}\n","import { initAnimate as initAnimateBackend } from \"./binding\"\nimport { createAnimationPresets } from \"./preset\"\nimport { AnimationRegistry, createAnimationRegistry } from \"./registry\"\nimport type {\n AnimateOptions,\n AnimationRegistryOptions,\n CompiledAnimation,\n KeyframesDefinition,\n} from \"./types\"\n\nexport type {\n AnimateOptions,\n AnimationRegistryOptions,\n CompiledAnimation,\n CSSDirection,\n CSSEasing,\n CSSFillMode,\n CSSIterationCount,\n CubicBezierEasing,\n KeyframesDefinition,\n PresetEasing,\n StepsEasing,\n} from \"./types\"\n\nconst defaultRegistry = createAnimationRegistry()\n\nexport async function initAnimate(): Promise<void> {\n await initAnimateBackend()\n}\n\nexport function getDefaultAnimationRegistry(): AnimationRegistry {\n return defaultRegistry\n}\n\nexport async function compileAnimation(\n opts: AnimateOptions,\n registry: AnimationRegistry = defaultRegistry\n): Promise<CompiledAnimation> {\n return registry.compileAnimation(opts)\n}\n\nexport async function compileKeyframes(\n name: string,\n stops: KeyframesDefinition,\n registry: AnimationRegistry = defaultRegistry\n): Promise<CompiledAnimation> {\n return registry.compileKeyframes(name, stops)\n}\n\nexport async function animate(\n opts: AnimateOptions,\n registry: AnimationRegistry = defaultRegistry\n): Promise<string> {\n return (await registry.compileAnimation(opts)).className\n}\n\nexport async function keyframes(\n name: string,\n stops: KeyframesDefinition,\n registry: AnimationRegistry = defaultRegistry\n): Promise<string> {\n return (await registry.compileKeyframes(name, stops)).className\n}\n\nexport function extractAnimationCss(registry: AnimationRegistry = defaultRegistry): string {\n return registry.extractCss()\n}\n\nexport function resetAnimationRegistry(registry: AnimationRegistry = defaultRegistry): void {\n registry.reset()\n}\n\nexport interface InjectAnimationCssOptions {\n document?: Document\n styleId?: string\n silent?: boolean\n}\n\nexport function injectAnimationCss(\n registry: AnimationRegistry = defaultRegistry,\n options: InjectAnimationCssOptions = {}\n): void {\n const targetDocument = options.document ?? (typeof document !== \"undefined\" ? document : undefined)\n if (!targetDocument) {\n if (options.silent) return\n throw new Error(\"injectAnimationCss requires a browser Document.\")\n }\n\n const styleId = options.styleId ?? \"__tw_animate_styles__\"\n let styleEl = targetDocument.getElementById(styleId) as HTMLStyleElement | null\n if (!styleEl) {\n if (!targetDocument.head) {\n if (options.silent) return\n throw new Error(\"injectAnimationCss requires document.head to exist.\")\n }\n styleEl = targetDocument.createElement(\"style\")\n styleEl.id = styleId\n targetDocument.head.appendChild(styleEl)\n }\n\n styleEl.textContent = registry.extractCss()\n}\n\nexport { AnimationRegistry, createAnimationRegistry } from \"./registry\"\n\nexport const animations = createAnimationPresets(defaultRegistry)\n"]}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
type CSSFillMode = "none" | "forwards" | "backwards" | "both";
|
|
2
|
+
type CSSDirection = "normal" | "reverse" | "alternate" | "alternate-reverse";
|
|
3
|
+
type CSSIterationCount = number | "infinite";
|
|
4
|
+
type PresetEasing = "linear" | "ease" | "ease-in" | "ease-out" | "ease-in-out" | "step-start" | "step-end";
|
|
5
|
+
type CubicBezierEasing = `cubic-bezier(${string})`;
|
|
6
|
+
type StepsEasing = `steps(${string})`;
|
|
7
|
+
type CSSEasing = PresetEasing | CubicBezierEasing | StepsEasing;
|
|
8
|
+
interface AnimateOptions {
|
|
9
|
+
from: string;
|
|
10
|
+
to: string;
|
|
11
|
+
duration?: number;
|
|
12
|
+
easing?: CSSEasing;
|
|
13
|
+
delay?: number;
|
|
14
|
+
fill?: CSSFillMode;
|
|
15
|
+
iterations?: CSSIterationCount;
|
|
16
|
+
direction?: CSSDirection;
|
|
17
|
+
name?: string;
|
|
18
|
+
}
|
|
19
|
+
interface KeyframesDefinition {
|
|
20
|
+
[stop: string]: string;
|
|
21
|
+
}
|
|
22
|
+
interface CompiledAnimation {
|
|
23
|
+
className: string;
|
|
24
|
+
keyframesCss: string;
|
|
25
|
+
animationCss: string;
|
|
26
|
+
}
|
|
27
|
+
interface AnimationRegistryOptions {
|
|
28
|
+
cacheLimit?: number;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
declare class AnimationRegistry {
|
|
32
|
+
private readonly animations;
|
|
33
|
+
private readonly animationBySignature;
|
|
34
|
+
private readonly keyframesBySignature;
|
|
35
|
+
constructor(options?: AnimationRegistryOptions);
|
|
36
|
+
compileAnimation(opts: AnimateOptions): Promise<CompiledAnimation>;
|
|
37
|
+
compileKeyframes(name: string, stops: KeyframesDefinition): Promise<CompiledAnimation>;
|
|
38
|
+
extractCss(): string;
|
|
39
|
+
reset(): void;
|
|
40
|
+
has(className: string): boolean;
|
|
41
|
+
}
|
|
42
|
+
declare function createAnimationRegistry(options?: AnimationRegistryOptions): AnimationRegistry;
|
|
43
|
+
|
|
44
|
+
declare function initAnimate(): Promise<void>;
|
|
45
|
+
declare function getDefaultAnimationRegistry(): AnimationRegistry;
|
|
46
|
+
declare function compileAnimation(opts: AnimateOptions, registry?: AnimationRegistry): Promise<CompiledAnimation>;
|
|
47
|
+
declare function compileKeyframes(name: string, stops: KeyframesDefinition, registry?: AnimationRegistry): Promise<CompiledAnimation>;
|
|
48
|
+
declare function animate(opts: AnimateOptions, registry?: AnimationRegistry): Promise<string>;
|
|
49
|
+
declare function keyframes(name: string, stops: KeyframesDefinition, registry?: AnimationRegistry): Promise<string>;
|
|
50
|
+
declare function extractAnimationCss(registry?: AnimationRegistry): string;
|
|
51
|
+
declare function resetAnimationRegistry(registry?: AnimationRegistry): void;
|
|
52
|
+
interface InjectAnimationCssOptions {
|
|
53
|
+
document?: Document;
|
|
54
|
+
styleId?: string;
|
|
55
|
+
silent?: boolean;
|
|
56
|
+
}
|
|
57
|
+
declare function injectAnimationCss(registry?: AnimationRegistry, options?: InjectAnimationCssOptions): void;
|
|
58
|
+
|
|
59
|
+
declare const animations: {
|
|
60
|
+
readonly fadeIn: () => Promise<string>;
|
|
61
|
+
readonly fadeOut: () => Promise<string>;
|
|
62
|
+
readonly slideUp: () => Promise<string>;
|
|
63
|
+
readonly slideDown: () => Promise<string>;
|
|
64
|
+
readonly slideLeft: () => Promise<string>;
|
|
65
|
+
readonly slideRight: () => Promise<string>;
|
|
66
|
+
readonly scaleIn: () => Promise<string>;
|
|
67
|
+
readonly scaleOut: () => Promise<string>;
|
|
68
|
+
readonly blurIn: () => Promise<string>;
|
|
69
|
+
readonly bounceIn: () => Promise<string>;
|
|
70
|
+
readonly spinIn: () => Promise<string>;
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
export { type AnimateOptions, AnimationRegistry, type AnimationRegistryOptions, type CSSDirection, type CSSEasing, type CSSFillMode, type CSSIterationCount, type CompiledAnimation, type CubicBezierEasing, type InjectAnimationCssOptions, type KeyframesDefinition, type PresetEasing, type StepsEasing, animate, animations, compileAnimation, compileKeyframes, createAnimationRegistry, extractAnimationCss, getDefaultAnimationRegistry, initAnimate, injectAnimationCss, keyframes, resetAnimationRegistry };
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
type CSSFillMode = "none" | "forwards" | "backwards" | "both";
|
|
2
|
+
type CSSDirection = "normal" | "reverse" | "alternate" | "alternate-reverse";
|
|
3
|
+
type CSSIterationCount = number | "infinite";
|
|
4
|
+
type PresetEasing = "linear" | "ease" | "ease-in" | "ease-out" | "ease-in-out" | "step-start" | "step-end";
|
|
5
|
+
type CubicBezierEasing = `cubic-bezier(${string})`;
|
|
6
|
+
type StepsEasing = `steps(${string})`;
|
|
7
|
+
type CSSEasing = PresetEasing | CubicBezierEasing | StepsEasing;
|
|
8
|
+
interface AnimateOptions {
|
|
9
|
+
from: string;
|
|
10
|
+
to: string;
|
|
11
|
+
duration?: number;
|
|
12
|
+
easing?: CSSEasing;
|
|
13
|
+
delay?: number;
|
|
14
|
+
fill?: CSSFillMode;
|
|
15
|
+
iterations?: CSSIterationCount;
|
|
16
|
+
direction?: CSSDirection;
|
|
17
|
+
name?: string;
|
|
18
|
+
}
|
|
19
|
+
interface KeyframesDefinition {
|
|
20
|
+
[stop: string]: string;
|
|
21
|
+
}
|
|
22
|
+
interface CompiledAnimation {
|
|
23
|
+
className: string;
|
|
24
|
+
keyframesCss: string;
|
|
25
|
+
animationCss: string;
|
|
26
|
+
}
|
|
27
|
+
interface AnimationRegistryOptions {
|
|
28
|
+
cacheLimit?: number;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
declare class AnimationRegistry {
|
|
32
|
+
private readonly animations;
|
|
33
|
+
private readonly animationBySignature;
|
|
34
|
+
private readonly keyframesBySignature;
|
|
35
|
+
constructor(options?: AnimationRegistryOptions);
|
|
36
|
+
compileAnimation(opts: AnimateOptions): Promise<CompiledAnimation>;
|
|
37
|
+
compileKeyframes(name: string, stops: KeyframesDefinition): Promise<CompiledAnimation>;
|
|
38
|
+
extractCss(): string;
|
|
39
|
+
reset(): void;
|
|
40
|
+
has(className: string): boolean;
|
|
41
|
+
}
|
|
42
|
+
declare function createAnimationRegistry(options?: AnimationRegistryOptions): AnimationRegistry;
|
|
43
|
+
|
|
44
|
+
declare function initAnimate(): Promise<void>;
|
|
45
|
+
declare function getDefaultAnimationRegistry(): AnimationRegistry;
|
|
46
|
+
declare function compileAnimation(opts: AnimateOptions, registry?: AnimationRegistry): Promise<CompiledAnimation>;
|
|
47
|
+
declare function compileKeyframes(name: string, stops: KeyframesDefinition, registry?: AnimationRegistry): Promise<CompiledAnimation>;
|
|
48
|
+
declare function animate(opts: AnimateOptions, registry?: AnimationRegistry): Promise<string>;
|
|
49
|
+
declare function keyframes(name: string, stops: KeyframesDefinition, registry?: AnimationRegistry): Promise<string>;
|
|
50
|
+
declare function extractAnimationCss(registry?: AnimationRegistry): string;
|
|
51
|
+
declare function resetAnimationRegistry(registry?: AnimationRegistry): void;
|
|
52
|
+
interface InjectAnimationCssOptions {
|
|
53
|
+
document?: Document;
|
|
54
|
+
styleId?: string;
|
|
55
|
+
silent?: boolean;
|
|
56
|
+
}
|
|
57
|
+
declare function injectAnimationCss(registry?: AnimationRegistry, options?: InjectAnimationCssOptions): void;
|
|
58
|
+
|
|
59
|
+
declare const animations: {
|
|
60
|
+
readonly fadeIn: () => Promise<string>;
|
|
61
|
+
readonly fadeOut: () => Promise<string>;
|
|
62
|
+
readonly slideUp: () => Promise<string>;
|
|
63
|
+
readonly slideDown: () => Promise<string>;
|
|
64
|
+
readonly slideLeft: () => Promise<string>;
|
|
65
|
+
readonly slideRight: () => Promise<string>;
|
|
66
|
+
readonly scaleIn: () => Promise<string>;
|
|
67
|
+
readonly scaleOut: () => Promise<string>;
|
|
68
|
+
readonly blurIn: () => Promise<string>;
|
|
69
|
+
readonly bounceIn: () => Promise<string>;
|
|
70
|
+
readonly spinIn: () => Promise<string>;
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
export { type AnimateOptions, AnimationRegistry, type AnimationRegistryOptions, type CSSDirection, type CSSEasing, type CSSFillMode, type CSSIterationCount, type CompiledAnimation, type CubicBezierEasing, type InjectAnimationCssOptions, type KeyframesDefinition, type PresetEasing, type StepsEasing, animate, animations, compileAnimation, compileKeyframes, createAnimationRegistry, extractAnimationCss, getDefaultAnimationRegistry, initAnimate, injectAnimationCss, keyframes, resetAnimationRegistry };
|