{"version":3,"sources":["../packages/domain/plugin-registry/registry.json","../node_modules/tsup/assets/esm_shims.js","../packages/domain/plugin-registry/src/index.ts"],"sourcesContent":["{\n  \"version\": \"5.0.0\",\n  \"updatedAt\": \"2026-03-23\",\n  \"official\": [\n    {\n      \"name\": \"@tailwind-styled/plugin-animation\",\n      \"description\": \"Animation presets and keyframes — enter/exit transitions, spring physics, scroll-triggered\",\n      \"version\": \"5.0.0\",\n      \"tags\": [\"animation\", \"motion\", \"transition\", \"keyframes\"],\n      \"docs\": \"https://github.com/tailwind-styled/tailwind-styled-v5/tree/main/packages/animate\",\n      \"install\": \"npm install @tailwind-styled/plugin-animation@5.0.0\",\n      \"integrity\": \"sha256-abc123\"\n    },\n    {\n      \"name\": \"@tailwind-styled/plugin-typography\",\n      \"description\": \"Prose and typography utilities — headings, body, code blocks, with dark mode\",\n      \"version\": \"5.0.0\",\n      \"tags\": [\"typography\", \"prose\", \"markdown\", \"content\"],\n      \"docs\": \"https://github.com/tailwind-styled/tailwind-styled-v5/tree/main/docs/plugins\",\n      \"install\": \"npm install @tailwind-styled/plugin-typography@5.0.0\",\n      \"integrity\": \"sha256-def456\"\n    },\n    {\n      \"name\": \"@tailwind-styled/plugin-forms\",\n      \"description\": \"Form input styling helpers — reset, validation states, custom checkboxes/radios\",\n      \"version\": \"5.0.0\",\n      \"tags\": [\"forms\", \"inputs\", \"validation\", \"checkbox\", \"radio\"],\n      \"docs\": \"https://github.com/tailwind-styled/tailwind-styled-v5/tree/main/docs/plugins\",\n      \"install\": \"npm install @tailwind-styled/plugin-forms@5.0.0\",\n      \"integrity\": \"sha256-ghi789\"\n    },\n    {\n      \"name\": \"@tailwind-styled/plugin-container-queries\",\n      \"description\": \"Container query utilities — @container breakpoints for component-level responsiveness\",\n      \"version\": \"5.0.0\",\n      \"tags\": [\"container-queries\", \"responsive\", \"layout\"],\n      \"docs\": \"https://github.com/tailwind-styled/tailwind-styled-v5/tree/main/docs/plugins\",\n      \"install\": \"npm install @tailwind-styled/plugin-container-queries@5.0.0\",\n      \"integrity\": \"sha256-jkl012\"\n    }\n  ],\n  \"community\": [\n    {\n      \"name\": \"tailwind-styled-animate\",\n      \"description\": \"Community animation variants — bounce, pulse, wiggle, and more\",\n      \"version\": \"0.1.0\",\n      \"tags\": [\"animation\", \"community\"],\n      \"author\": \"community\",\n      \"install\": \"npm install tailwind-styled-animate\"\n    },\n    {\n      \"name\": \"tailwind-styled-icons\",\n      \"description\": \"SVG icon system integrated with tw() variant API\",\n      \"version\": \"0.1.0\",\n      \"tags\": [\"icons\", \"svg\", \"community\"],\n      \"author\": \"community\",\n      \"install\": \"npm install tailwind-styled-icons\"\n    }\n  ]\n}\n","// Shim globals in esm bundle\nimport path from 'node:path'\nimport { fileURLToPath } from 'node:url'\n\nconst getFilename = () => fileURLToPath(import.meta.url)\nconst getDirname = () => path.dirname(getFilename())\n\nexport const __dirname = /* @__PURE__ */ getDirname()\nexport const __filename = /* @__PURE__ */ getFilename()\n","import { spawnSync } from \"node:child_process\"\nimport { existsSync, readFileSync } from \"node:fs\"\nimport { createRequire } from \"node:module\"\nimport { join, resolve } from \"node:path\"\nimport { fileURLToPath } from \"node:url\"\n\n// ── Native bridge (lazy-loaded to avoid circular deps) ──────────────────────\ntype NativePluginRegistry = {\n  pluginSearch: (pluginsJson: string, query: string) => string\n  pluginValidateName: (name: string) => boolean\n  pluginVerifyIntegrity: (content: string, expectedIntegrity: string) => boolean\n  pluginSemverHasUpdate: (current: string, latest: string) => boolean\n  pluginCheckAllUpdates: (installedJson: string, registryJson: string) => string\n}\nlet _native: NativePluginRegistry | null | undefined = undefined\nfunction getNative(): NativePluginRegistry | null {\n  if (_native !== undefined) return _native\n  try {\n    const runtimeDir = typeof __dirname === \"string\" && __dirname.length > 0\n      ? __dirname\n      : typeof import.meta !== \"undefined\" && import.meta.url\n        ? fileURLToPath(new URL(\".\", import.meta.url))\n        : process.cwd()\n    const req = createRequire(join(runtimeDir, \"noop.cjs\"))\n    const _pa = `${process.platform}-${process.arch}`\n    const _paGnu = _pa === \"linux-x64\" ? \"linux-x64-gnu\" : _pa === \"linux-arm64\" ? \"linux-arm64-gnu\" : _pa\n    const candidates = [\n      // npm install case: dist/../native/\n      resolve(runtimeDir, \"..\", \"native\", \"tailwind-styled-native.node\"),\n      resolve(runtimeDir, \"..\", \"native\", `tailwind-styled-native.${_pa}.node`),\n      resolve(runtimeDir, \"..\", \"native\", `tailwind-styled-native.${_paGnu}.node`),\n      resolve(runtimeDir, \"..\", \"native\", \"tailwind_styled_parser.node\"),\n      // cwd fallback\n      resolve(process.cwd(), \"native\", \"tailwind-styled-native.node\"),\n      resolve(process.cwd(), \"native\", \"tailwind_styled_parser.node\"),\n      // monorepo dev: 4-level up\n      resolve(runtimeDir, \"..\", \"..\", \"..\", \"..\", \"native\", \"tailwind-styled-native.node\"),\n      resolve(runtimeDir, \"..\", \"..\", \"..\", \"..\", \"native\", \"tailwind_styled_parser.node\"),\n      // 3-level fallback\n      resolve(runtimeDir, \"..\", \"..\", \"..\", \"native\", \"tailwind-styled-native.node\"),\n      resolve(runtimeDir, \"..\", \"..\", \"..\", \"native\", \"tailwind_styled_parser.node\"),\n    ]\n    for (const c of candidates) {\n      try {\n        const mod = req(c) as Record<string, unknown>\n        if (typeof mod?.pluginSearch === \"function\") {\n          return (_native = mod as unknown as NativePluginRegistry)\n        }\n      } catch { /* continue */ }\n    }\n  } catch { /* ignore */ }\n  return (_native = null)\n}\n\nconst NATIVE_UNAVAILABLE_MESSAGE =\n  \"[tailwind-styled/plugin-registry] Native binding is required but not available.\\n\" +\n  \"Please ensure you have run: npm run build:rust\"\n\n/**\n * Native-only accessor. Throws if the Rust binding is missing.\n * The TS layer is a thin wrapper — no JS fallbacks (native-first philosophy).\n */\nfunction requireNative(): NativePluginRegistry {\n  const native = getNative()\n  if (!native) throw new Error(NATIVE_UNAVAILABLE_MESSAGE)\n  return native\n}\n\nconst PLUGIN_NAME_REGEX = /^(@[a-z0-9-]+\\/)?[a-z0-9-]+(@[0-9]+\\.[0-9]+\\.[0-9]+)?$/\n\nexport interface PluginInfo {\n  name: string\n  description: string\n  version: string\n  tags: string[]\n  official?: boolean\n  docs?: string\n  install?: string\n  integrity?: string\n}\n\ninterface RegistryData {\n  version: string\n  official: PluginInfo[]\n  community: PluginInfo[]\n}\n\nexport interface InstallResult {\n  plugin: string\n  installed: boolean\n  command: string\n  exitCode: number\n}\n\nexport type PluginRegistryErrorCode =\n  | \"INVALID_PLUGIN_NAME\"\n  | \"PLUGIN_NOT_FOUND\"\n  | \"EXTERNAL_CONFIRMATION_REQUIRED\"\n  | \"INSTALL_COMMAND_FAILED\"\n  | \"INSTALL_FAILED\"\n  | \"NETWORK_ERROR\"\n  | \"REGISTRY_LOAD_FAILED\"\n\nexport interface PluginRegistryErrorPayload {\n  code: PluginRegistryErrorCode\n  message: string\n  context?: Record<string, unknown>\n}\n\nexport class PluginRegistryError extends Error {\n  readonly code: PluginRegistryErrorCode\n  readonly context?: Record<string, unknown>\n\n  constructor(payload: PluginRegistryErrorPayload) {\n    super(payload.message)\n    this.name = \"PluginRegistryError\"\n    this.code = payload.code\n    this.context = payload.context\n  }\n\n  toObject(): PluginRegistryErrorPayload {\n    return {\n      code: this.code,\n      message: this.message,\n      context: this.context,\n    }\n  }\n}\n\nexport interface InstallOptions {\n  dryRun?: boolean\n  npmBin?: string\n  allowExternal?: boolean\n  confirmExternal?: boolean\n}\n\nexport interface RegistryOptions {\n  registryUrl?: string\n}\n\nexport class PluginRegistry {\n  private readonly plugins: PluginInfo[]\n  private readonly registryVersion: string\n\n  constructor(registryData?: RegistryData, options: RegistryOptions = {}) {\n    if (options.registryUrl) {\n      this.plugins = []\n      this.registryVersion = \"0.0.0\"\n    } else {\n      const data = registryData\n      const version = data?.version ?? \"4.2.0\"\n      const official = (data?.official ?? []).map((item) => ({\n        name: item.name,\n        description: item.description,\n        version: item.version,\n        tags: [...item.tags],\n        official: true,\n        docs: item.docs,\n        install: item.install,\n        integrity: item.integrity,\n      }))\n      const community = (data?.community ?? []).map((item) => ({\n        name: item.name,\n        description: item.description,\n        version: item.version,\n        tags: [...item.tags],\n        official: false,\n      }))\n      this.plugins = [...official, ...community]\n      this.registryVersion = version\n    }\n  }\n\n  static async loadFromUrl(url: string): Promise<PluginRegistry> {\n    try {\n      const response = await fetch(url)\n      if (!response.ok) {\n        throw new PluginRegistryError({\n          code: \"NETWORK_ERROR\",\n          message: `Failed to fetch registry: ${response.status} ${response.statusText}`,\n          context: { url, status: response.status },\n        })\n      }\n      const data = (await response.json()) as RegistryData\n      return new PluginRegistry(data, { registryUrl: url })\n    } catch (error) {\n      if (error instanceof PluginRegistryError) throw error\n      throw new PluginRegistryError({\n        code: \"NETWORK_ERROR\",\n        message: `Failed to load registry: ${error instanceof Error ? error.message : String(error)}`,\n        context: { url },\n      })\n    }\n  }\n\n  getVersion(): string {\n    return this.registryVersion\n  }\n\n  search(query: string): PluginInfo[] {\n    const native = requireNative()\n    return JSON.parse(native.pluginSearch(JSON.stringify(this.plugins), query)) as PluginInfo[]\n  }\n\n  getAll(): PluginInfo[] {\n    return [...this.plugins]\n  }\n\n  getByName(pluginName: string): PluginInfo | undefined {\n    const nameWithoutVersion = pluginName.split(\"@\").slice(0, 2).join(\"@\")\n    return this.plugins.find((plugin) => plugin.name === nameWithoutVersion)\n  }\n\n  install(pluginName: string, options: InstallOptions = {}): InstallResult {\n    const npmBin = options.npmBin ?? process.env.TW_PLUGIN_NPM_BIN ?? \"npm\"\n\n    const native = requireNative()\n    const isValidName = native.pluginValidateName(pluginName)\n\n    if (!isValidName) {\n      throw new PluginRegistryError({\n        code: \"INVALID_PLUGIN_NAME\",\n        message: `Nama plugin tidak valid: '${pluginName}'.`,\n        context: {\n          pluginName,\n          expectedPattern: String(PLUGIN_NAME_REGEX),\n        },\n      })\n    }\n\n    const knownPlugin = this.getByName(pluginName)\n    const isExternal = !knownPlugin\n\n    if (isExternal && !options.allowExternal) {\n      throw new PluginRegistryError({\n        code: \"PLUGIN_NOT_FOUND\",\n        message: `Plugin '${pluginName}' tidak ditemukan di registry. Coba cari dengan 'tw-plugin search <keyword>'.`,\n        context: {\n          pluginName,\n          allowExternal: false,\n        },\n      })\n    }\n\n    if (isExternal && options.allowExternal && !options.confirmExternal) {\n      throw new PluginRegistryError({\n        code: \"EXTERNAL_CONFIRMATION_REQUIRED\",\n        message: `Plugin eksternal '${pluginName}' butuh konfirmasi. Jalankan ulang dengan --allow-external --yes.`,\n        context: {\n          pluginName,\n          allowExternal: true,\n        },\n      })\n    }\n\n    const command = `${npmBin} install ${pluginName}`\n    if (options.dryRun) {\n      return { plugin: pluginName, installed: true, command, exitCode: 0 }\n    }\n\n    const child = spawnSync(npmBin, [\"install\", pluginName], { stdio: \"inherit\" })\n    if (child.error) {\n      throw new PluginRegistryError({\n        code: \"INSTALL_COMMAND_FAILED\",\n        message: `Gagal menjalankan perintah install: ${command}`,\n        context: {\n          pluginName,\n          command,\n          reason: child.error.message,\n        },\n      })\n    }\n\n    if (child.status !== 0) {\n      throw new PluginRegistryError({\n        code: \"INSTALL_FAILED\",\n        message: `Install gagal (${child.status ?? 1}): ${command}`,\n        context: {\n          pluginName,\n          command,\n          exitCode: child.status ?? 1,\n        },\n      })\n    }\n\n    return {\n      plugin: pluginName,\n      installed: true,\n      command,\n      exitCode: 0,\n    }\n  }\n\n  uninstall(\n    pluginName: string,\n    options: { dryRun?: boolean; npmBin?: string } = {}\n  ): {\n    plugin: string\n    uninstalled: boolean\n    command: string\n    exitCode: number\n  } {\n    const npmBin = options.npmBin ?? process.env.TW_PLUGIN_NPM_BIN ?? \"npm\"\n    const command = `${npmBin} uninstall ${pluginName}`\n\n    if (options.dryRun) {\n      return { plugin: pluginName, uninstalled: true, command, exitCode: 0 }\n    }\n\n    const child = spawnSync(npmBin, [\"uninstall\", pluginName], { stdio: \"inherit\" })\n    if (child.status !== 0 && child.status !== null) {\n      throw new PluginRegistryError({\n        code: \"INSTALL_FAILED\",\n        message: `Uninstall gagal (${child.status}): ${command}`,\n        context: { pluginName, command, exitCode: child.status },\n      })\n    }\n\n    return {\n      plugin: pluginName,\n      uninstalled: true,\n      command,\n      exitCode: child.status ?? 0,\n    }\n  }\n\n  verifyIntegrity(pluginName: string): { ok: boolean; reason?: string } {\n    const plugin = this.getByName(pluginName)\n    if (!plugin) return { ok: false, reason: `Plugin '${pluginName}' not in registry` }\n    if (!plugin.integrity) {\n      return { ok: true, reason: \"no checksum registered (skip)\" }\n    }\n    try {\n      const pkgPath = join(process.cwd(), \"node_modules\", pluginName, \"package.json\")\n      if (!existsSync(pkgPath)) return { ok: false, reason: \"plugin not installed\" }\n      const content = readFileSync(pkgPath, \"utf8\")\n      const native = requireNative()\n      const ok = native.pluginVerifyIntegrity(content, plugin.integrity!)\n      return ok ? { ok: true } : { ok: false, reason: `Integrity mismatch: expected ${plugin.integrity}` }\n    } catch (e: unknown) {\n      return {\n        ok: false,\n        reason: `Integrity check failed: ${e instanceof Error ? e.message : String(e)}`,\n      }\n    }\n  }\n\n  checkForUpdate(pluginName: string): {\n    hasUpdate: boolean\n    current?: string\n    latest?: string\n    error?: string\n  } {\n    const plugin = this.getByName(pluginName)\n    if (!plugin) return { hasUpdate: false, error: `Plugin '${pluginName}' not in registry` }\n    try {\n      const pkgPath = join(process.cwd(), \"node_modules\", pluginName, \"package.json\")\n      if (!existsSync(pkgPath)) return { hasUpdate: false, error: \"plugin not installed\" }\n      const current = JSON.parse(readFileSync(pkgPath, \"utf8\")).version ?? \"0.0.0\"\n      const latest = plugin.version\n      const native = requireNative()\n      const hasUpdate = native.pluginSemverHasUpdate(current as string, latest)\n      return { hasUpdate, current: current as string, latest }\n    } catch (e: unknown) {\n      return {\n        hasUpdate: false,\n        error: `Update check failed: ${e instanceof Error ? e.message : String(e)}`,\n      }\n    }\n  }\n\n  checkAllUpdates(): Array<{\n    name: string\n    hasUpdate: boolean\n    current?: string\n    latest?: string\n    error?: string\n  }> {\n    type UpdateResult = {\n      name: string\n      hasUpdate: boolean\n      current?: string\n      latest?: string\n      error?: string\n    }\n    const native = requireNative()\n\n    // FS I/O stays in JS — gather installed versions for every registry plugin.\n    const installed: Array<{ name: string; version: string }> = []\n    const byName = new Map<string, UpdateResult>()\n    for (const p of this.plugins) {\n      try {\n        const pkgPath = join(process.cwd(), \"node_modules\", p.name, \"package.json\")\n        if (!existsSync(pkgPath)) {\n          byName.set(p.name, { name: p.name, hasUpdate: false, error: \"plugin not installed\" })\n          continue\n        }\n        const version = JSON.parse(readFileSync(pkgPath, \"utf8\")).version ?? \"0.0.0\"\n        installed.push({ name: p.name, version: version as string })\n      } catch (e: unknown) {\n        byName.set(p.name, {\n          name: p.name,\n          hasUpdate: false,\n          error: `Update check failed: ${e instanceof Error ? e.message : String(e)}`,\n        })\n      }\n    }\n\n    // Single native batch call does all semver comparisons (1 FFI crossing, not N).\n    const results = JSON.parse(\n      native.pluginCheckAllUpdates(JSON.stringify(installed), JSON.stringify(this.plugins))\n    ) as UpdateResult[]\n    for (const r of results) byName.set(r.name, r)\n\n    // Preserve registry order.\n    return this.plugins.map((p) => byName.get(p.name)).filter((r): r is UpdateResult => r !== undefined)\n  }\n}\n\nconst _state = { defaultRegistry: null as PluginRegistry | null }\n\nexport function getRegistry(): PluginRegistry {\n  if (!_state.defaultRegistry) {\n    const registryData = require(\"../registry.json\") as RegistryData\n    _state.defaultRegistry = new PluginRegistry(registryData)\n  }\n  return _state.defaultRegistry\n}\n\nexport const registry = getRegistry()"],"mappings":";;;;;;AAAA;AAAA;AAAA;AAAA,MACE,SAAW;AAAA,MACX,WAAa;AAAA,MACb,UAAY;AAAA,QACV;AAAA,UACE,MAAQ;AAAA,UACR,aAAe;AAAA,UACf,SAAW;AAAA,UACX,MAAQ,CAAC,aAAa,UAAU,cAAc,WAAW;AAAA,UACzD,MAAQ;AAAA,UACR,SAAW;AAAA,UACX,WAAa;AAAA,QACf;AAAA,QACA;AAAA,UACE,MAAQ;AAAA,UACR,aAAe;AAAA,UACf,SAAW;AAAA,UACX,MAAQ,C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