vessel-agent 0.0.0-stage → 2.3.0-beta.2

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 (1095) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +466 -2
  3. package/README.zh-CN.md +476 -0
  4. package/apps/web/dist/Vela.png +0 -0
  5. package/apps/web/dist/Vessel.svg +24 -0
  6. package/apps/web/dist/apple-touch-icon.png +0 -0
  7. package/apps/web/dist/assets/ConfigView-BKdxb1s5.js +1 -0
  8. package/apps/web/dist/assets/DesignLabContent-CY5HfVn_.js +4 -0
  9. package/apps/web/dist/assets/DesignLabView-DTBWv5-E.js +1 -0
  10. package/apps/web/dist/assets/action-menu.preview-CpIL3tay.js +1 -0
  11. package/apps/web/dist/assets/agent-message.preview-CSYnJxgr.js +1 -0
  12. package/apps/web/dist/assets/assistant-text.preview-Bc2Is6sW.js +2 -0
  13. package/apps/web/dist/assets/badges.preview-DP0oPcs5.js +1 -0
  14. package/apps/web/dist/assets/buttons.preview-Y84aT4k3.js +1 -0
  15. package/apps/web/dist/assets/card-shell.preview-mwRwhVb8.js +1 -0
  16. package/apps/web/dist/assets/chip-tones.preview-dQ_6pwft.js +1 -0
  17. package/apps/web/dist/assets/composer-controls.preview-CBtJVrMo.js +1 -0
  18. package/apps/web/dist/assets/confirm-dialog.preview-BkNEtLld.js +1 -0
  19. package/apps/web/dist/assets/data-table.preview-DPZ7Pnn8.js +1 -0
  20. package/apps/web/dist/assets/depth-color.preview-CtCbAgCH.js +1 -0
  21. package/apps/web/dist/assets/entity-header.preview-BxPLNUSH.js +1 -0
  22. package/apps/web/dist/assets/env-card.preview-Bv4UlMjr.js +1 -0
  23. package/apps/web/dist/assets/failure-card.preview-DD3-RMju.js +1 -0
  24. package/apps/web/dist/assets/filter-popover.preview-D7Q7Kws8.js +1 -0
  25. package/apps/web/dist/assets/form.preview-D_Qltx-j.js +1 -0
  26. package/apps/web/dist/assets/index-ee36IO2F.js +600 -0
  27. package/apps/web/dist/assets/index-uU9N5oTa.css +1 -0
  28. package/apps/web/dist/assets/key-value.preview-B0gzxwtK.js +1 -0
  29. package/apps/web/dist/assets/mention-popover.preview-Duza1RgL.js +1 -0
  30. package/apps/web/dist/assets/message-fold.preview-Cx-CD3Y4.js +1 -0
  31. package/apps/web/dist/assets/modal-shell.preview-DYKwUk2S.js +1 -0
  32. package/apps/web/dist/assets/nav-item.preview-FTbsBQ2g.js +1 -0
  33. package/apps/web/dist/assets/nav-status-legend.preview-bS4LDFbd.js +1 -0
  34. package/apps/web/dist/assets/page-scaffold.preview-bzBFkjZ6.js +1 -0
  35. package/apps/web/dist/assets/plugin-ui-BxTydP3l.js +1 -0
  36. package/apps/web/dist/assets/projection-card.preview-BV0P-y8e.js +6 -0
  37. package/apps/web/dist/assets/queued.preview-zQqFe4Zr.js +1 -0
  38. package/apps/web/dist/assets/react-vendor-CUu194FT.js +9 -0
  39. package/apps/web/dist/assets/reasoning.preview-DtHXgW_8.js +2 -0
  40. package/apps/web/dist/assets/section.preview-A-PRm-rh.js +1 -0
  41. package/apps/web/dist/assets/sidebar-shell.preview-DFKMwNoo.js +1 -0
  42. package/apps/web/dist/assets/stat.preview-BzChSFLL.js +1 -0
  43. package/apps/web/dist/assets/states.preview-CyXZWnZ-.js +1 -0
  44. package/apps/web/dist/assets/status-icons.preview-DHdWwUis.js +1 -0
  45. package/apps/web/dist/assets/tabs.preview-CHbK1Two.js +1 -0
  46. package/apps/web/dist/assets/tool-card.preview-Z48fekTD.js +2 -0
  47. package/apps/web/dist/assets/toolbar.preview-Bl6hLYXX.js +1 -0
  48. package/apps/web/dist/assets/tooltip.preview-GKGTGfMP.js +1 -0
  49. package/apps/web/dist/assets/user-bubble.preview-CHYvio9z.js +1 -0
  50. package/apps/web/dist/assets/vendor/jsx-runtime.mjs +7 -0
  51. package/apps/web/dist/assets/vendor/plugin-sdk.mjs +12 -0
  52. package/apps/web/dist/assets/vendor/react-dom-client.mjs +6 -0
  53. package/apps/web/dist/assets/vendor/react-dom.mjs +11 -0
  54. package/apps/web/dist/assets/vendor/react.mjs +39 -0
  55. package/apps/web/dist/build.json +5 -0
  56. package/apps/web/dist/favicon.ico +0 -0
  57. package/apps/web/dist/index.html +24 -0
  58. package/package.json +70 -4
  59. package/packages/agent/package.json +32 -0
  60. package/packages/agent/src/address-display.ts +141 -0
  61. package/packages/agent/src/conversation-budget.ts +651 -0
  62. package/packages/agent/src/conversation-store.ts +351 -0
  63. package/packages/agent/src/distress.ts +161 -0
  64. package/packages/agent/src/env-info-scope.ts +153 -0
  65. package/packages/agent/src/error-text.ts +28 -0
  66. package/packages/agent/src/inbox-source.ts +73 -0
  67. package/packages/agent/src/inbox.ts +2335 -0
  68. package/packages/agent/src/index.ts +273 -0
  69. package/packages/agent/src/member-cwd.ts +128 -0
  70. package/packages/agent/src/member-ports.ts +162 -0
  71. package/packages/agent/src/refs.ts +51 -0
  72. package/packages/agent/src/registry.ts +741 -0
  73. package/packages/agent/src/runtime.ts +2501 -0
  74. package/packages/agent/src/self-card-delta.ts +428 -0
  75. package/packages/agent/src/service.ts +9212 -0
  76. package/packages/agent/src/snapshot.ts +614 -0
  77. package/packages/agent/src/team-address.ts +96 -0
  78. package/packages/agent/src/team-log.ts +487 -0
  79. package/packages/agent/src/team-service.ts +1966 -0
  80. package/packages/agent/src/team-slug.ts +167 -0
  81. package/packages/agent/src/team-store.ts +619 -0
  82. package/packages/agent/src/tool.ts +1306 -0
  83. package/packages/agent/src/types/budget.ts +168 -0
  84. package/packages/agent/src/types/constants.ts +17 -0
  85. package/packages/agent/src/types/dispatch.ts +133 -0
  86. package/packages/agent/src/types/events.ts +132 -0
  87. package/packages/agent/src/types/execution.ts +289 -0
  88. package/packages/agent/src/types/lifecycle.ts +372 -0
  89. package/packages/agent/src/types/member.ts +221 -0
  90. package/packages/agent/src/types/message.ts +113 -0
  91. package/packages/agent/src/types/results.ts +64 -0
  92. package/packages/agent/src/types/roster.ts +137 -0
  93. package/packages/agent/src/types/service.ts +702 -0
  94. package/packages/agent/src/types/session.ts +102 -0
  95. package/packages/agent/src/types/team.ts +558 -0
  96. package/packages/agent/src/types.ts +22 -0
  97. package/packages/agent/tsconfig.json +8 -0
  98. package/packages/config/package.json +32 -0
  99. package/packages/config/src/auth-origins.ts +85 -0
  100. package/packages/config/src/auth-strategies/avatar-ref.ts +40 -0
  101. package/packages/config/src/auth-strategies/gitee.ts +72 -0
  102. package/packages/config/src/auth-strategies/github.ts +64 -0
  103. package/packages/config/src/auth-strategies/index.ts +47 -0
  104. package/packages/config/src/auth-strategies/match.ts +82 -0
  105. package/packages/config/src/auth-strategies/microsoft.ts +100 -0
  106. package/packages/config/src/auth-strategies/oauth-exchange.ts +192 -0
  107. package/packages/config/src/auth-strategies/password.ts +34 -0
  108. package/packages/config/src/auth-strategies/registry.ts +105 -0
  109. package/packages/config/src/auth-strategies/shapes.ts +138 -0
  110. package/packages/config/src/auth-strategies/types.ts +190 -0
  111. package/packages/config/src/auth.ts +305 -0
  112. package/packages/config/src/config-lock.ts +328 -0
  113. package/packages/config/src/defaults.ts +271 -0
  114. package/packages/config/src/env-file.ts +175 -0
  115. package/packages/config/src/env-injection.ts +117 -0
  116. package/packages/config/src/explain.ts +283 -0
  117. package/packages/config/src/gateway.ts +107 -0
  118. package/packages/config/src/index.ts +253 -0
  119. package/packages/config/src/loader.ts +871 -0
  120. package/packages/config/src/model-migration.ts +534 -0
  121. package/packages/config/src/model-registry.ts +374 -0
  122. package/packages/config/src/models-disk.ts +72 -0
  123. package/packages/config/src/models-validation.ts +467 -0
  124. package/packages/config/src/node-registration.ts +583 -0
  125. package/packages/config/src/root-secret.ts +402 -0
  126. package/packages/config/src/secrets.ts +452 -0
  127. package/packages/config/src/sources.ts +82 -0
  128. package/packages/config/src/team-policy.ts +422 -0
  129. package/packages/config/src/types/agent.ts +263 -0
  130. package/packages/config/src/types/attention.ts +28 -0
  131. package/packages/config/src/types/auth.ts +126 -0
  132. package/packages/config/src/types/connect.ts +21 -0
  133. package/packages/config/src/types/hub.ts +59 -0
  134. package/packages/config/src/types/models.ts +153 -0
  135. package/packages/config/src/types/node.ts +202 -0
  136. package/packages/config/src/types/observability.ts +84 -0
  137. package/packages/config/src/types/root.ts +240 -0
  138. package/packages/config/src/types/runtime.ts +123 -0
  139. package/packages/config/src/types/security.ts +43 -0
  140. package/packages/config/src/types/serve.ts +34 -0
  141. package/packages/config/src/types/snapshot.ts +28 -0
  142. package/packages/config/src/types/team.ts +112 -0
  143. package/packages/config/src/types/ui.ts +179 -0
  144. package/packages/config/src/types.ts +22 -0
  145. package/packages/config/src/user-config.ts +175 -0
  146. package/packages/config/src/utils.ts +55 -0
  147. package/packages/config/src/validator/auth.ts +302 -0
  148. package/packages/config/src/validator/hub.ts +329 -0
  149. package/packages/config/src/validator/models.ts +1304 -0
  150. package/packages/config/src/validator/serve.ts +784 -0
  151. package/packages/config/src/validator/settings.ts +244 -0
  152. package/packages/config/src/validator/shared.ts +304 -0
  153. package/packages/config/src/validator/tenant-keys.ts +91 -0
  154. package/packages/config/src/validator/unknown-keys.ts +452 -0
  155. package/packages/config/src/validator.ts +1146 -0
  156. package/packages/config/tsconfig.json +8 -0
  157. package/packages/core/package.json +38 -0
  158. package/packages/core/src/context/anchor.ts +57 -0
  159. package/packages/core/src/context/archive-notice.ts +283 -0
  160. package/packages/core/src/context/cleared-tool-result.ts +262 -0
  161. package/packages/core/src/context/compaction-index.ts +381 -0
  162. package/packages/core/src/context/composition.ts +251 -0
  163. package/packages/core/src/context/context-manager.ts +1585 -0
  164. package/packages/core/src/context/context-notice.ts +218 -0
  165. package/packages/core/src/context/index.ts +220 -0
  166. package/packages/core/src/context/model-change-notice.ts +81 -0
  167. package/packages/core/src/context/projection-policy.ts +719 -0
  168. package/packages/core/src/context/prompt-context.ts +66 -0
  169. package/packages/core/src/context/read-side-mask.ts +63 -0
  170. package/packages/core/src/context/request-sequence.ts +423 -0
  171. package/packages/core/src/context/request-view.ts +256 -0
  172. package/packages/core/src/context/session-breaker.ts +100 -0
  173. package/packages/core/src/context/tool-result-whitelist.ts +135 -0
  174. package/packages/core/src/events/event-stream.ts +271 -0
  175. package/packages/core/src/events/file-event-store.ts +119 -0
  176. package/packages/core/src/events/index.ts +15 -0
  177. package/packages/core/src/events/replay.ts +82 -0
  178. package/packages/core/src/events/summarize-event.ts +135 -0
  179. package/packages/core/src/index.ts +475 -0
  180. package/packages/core/src/kernel/cancellation.ts +54 -0
  181. package/packages/core/src/kernel/event-bus.ts +65 -0
  182. package/packages/core/src/kernel/index.ts +32 -0
  183. package/packages/core/src/kernel/internal.ts +32 -0
  184. package/packages/core/src/kernel/scheduler.ts +406 -0
  185. package/packages/core/src/kernel/types.ts +269 -0
  186. package/packages/core/src/limits/index.ts +23 -0
  187. package/packages/core/src/limits/limit-checker.ts +270 -0
  188. package/packages/core/src/limits/limit-error.ts +29 -0
  189. package/packages/core/src/log-format.ts +722 -0
  190. package/packages/core/src/log-hub.ts +278 -0
  191. package/packages/core/src/logging.ts +64 -0
  192. package/packages/core/src/observability/index.ts +24 -0
  193. package/packages/core/src/observability/metrics.ts +279 -0
  194. package/packages/core/src/observability/read-trace.ts +163 -0
  195. package/packages/core/src/observability/rebuild-metrics.ts +37 -0
  196. package/packages/core/src/observability/trace-prune.ts +248 -0
  197. package/packages/core/src/observability/trace-recorder.ts +484 -0
  198. package/packages/core/src/observability/trace-redactor.ts +93 -0
  199. package/packages/core/src/pii/index.ts +88 -0
  200. package/packages/core/src/pii/notice.ts +156 -0
  201. package/packages/core/src/pii/reveal.ts +198 -0
  202. package/packages/core/src/pii/rules.ts +545 -0
  203. package/packages/core/src/pii/types.ts +140 -0
  204. package/packages/core/src/pii/vault.ts +764 -0
  205. package/packages/core/src/provider/errors.ts +41 -0
  206. package/packages/core/src/provider/index.ts +19 -0
  207. package/packages/core/src/provider/providers.ts +1011 -0
  208. package/packages/core/src/provider/request-extras.ts +285 -0
  209. package/packages/core/src/provider/stream-accumulator.ts +168 -0
  210. package/packages/core/src/provider/usage.ts +112 -0
  211. package/packages/core/src/runtime/error-envelope.ts +451 -0
  212. package/packages/core/src/runtime/error-summary.ts +174 -0
  213. package/packages/core/src/runtime/execution-unit.ts +6675 -0
  214. package/packages/core/src/runtime/guardrail-runner.ts +86 -0
  215. package/packages/core/src/runtime/hook-runner.ts +137 -0
  216. package/packages/core/src/runtime/index.ts +123 -0
  217. package/packages/core/src/runtime/permission-policy.ts +267 -0
  218. package/packages/core/src/runtime/plugin-host.ts +489 -0
  219. package/packages/core/src/runtime/plugin-install.ts +144 -0
  220. package/packages/core/src/runtime/policy/index.ts +21 -0
  221. package/packages/core/src/runtime/prompt-prefix-guard.ts +166 -0
  222. package/packages/core/src/runtime/provider-retry.ts +220 -0
  223. package/packages/core/src/runtime/resume-markers.ts +114 -0
  224. package/packages/core/src/runtime/resume-recovery.ts +164 -0
  225. package/packages/core/src/runtime/run-journal.ts +382 -0
  226. package/packages/core/src/runtime/run-timing.ts +217 -0
  227. package/packages/core/src/runtime/runtime.ts +349 -0
  228. package/packages/core/src/runtime/safepoint-pause.ts +29 -0
  229. package/packages/core/src/runtime/tool-attachment.ts +170 -0
  230. package/packages/core/src/runtime/tool-calling-loop.ts +1219 -0
  231. package/packages/core/src/runtime/tool-name.ts +215 -0
  232. package/packages/core/src/runtime/tool-pipeline.ts +459 -0
  233. package/packages/core/src/runtime/tool-provenance.ts +48 -0
  234. package/packages/core/src/runtime/tool-result-gate.ts +329 -0
  235. package/packages/core/src/session/atomic-write.ts +335 -0
  236. package/packages/core/src/session/compaction-index-derive.ts +173 -0
  237. package/packages/core/src/session/compaction-index-store.ts +161 -0
  238. package/packages/core/src/session/compaction-recall.ts +375 -0
  239. package/packages/core/src/session/delete-session.ts +198 -0
  240. package/packages/core/src/session/file-backend.ts +1311 -0
  241. package/packages/core/src/session/index.ts +118 -0
  242. package/packages/core/src/session/message-identity.ts +272 -0
  243. package/packages/core/src/session/project-messages.ts +908 -0
  244. package/packages/core/src/session/projection-cache.ts +254 -0
  245. package/packages/core/src/session/prune.ts +153 -0
  246. package/packages/core/src/session/run-record-store.ts +307 -0
  247. package/packages/core/src/session/session-index.ts +158 -0
  248. package/packages/core/src/session/session-log-dir.ts +39 -0
  249. package/packages/core/src/session/session-store.ts +266 -0
  250. package/packages/core/src/session/sqlite-backend.ts +391 -0
  251. package/packages/core/src/socket-inherit-guard.ts +188 -0
  252. package/packages/core/src/storage/metadata-sidecar.ts +124 -0
  253. package/packages/core/src/tenant/index.ts +13 -0
  254. package/packages/core/src/tenant/resolve-tenant.ts +19 -0
  255. package/packages/core/src/tenant/tenant-paths.ts +83 -0
  256. package/packages/core/src/timeline/archive-audit.ts +316 -0
  257. package/packages/core/src/timeline/archive-lock.ts +124 -0
  258. package/packages/core/src/timeline/blocks.ts +1639 -0
  259. package/packages/core/src/timeline/enum-stats.ts +34 -0
  260. package/packages/core/src/timeline/holes.ts +431 -0
  261. package/packages/core/src/timeline/index.ts +387 -0
  262. package/packages/core/src/timeline/legacy-format.ts +97 -0
  263. package/packages/core/src/timeline/read-port.ts +582 -0
  264. package/packages/core/src/timeline/types.ts +371 -0
  265. package/packages/core/src/timeline/wal.ts +2485 -0
  266. package/packages/core/src/timeline/writer.ts +2079 -0
  267. package/packages/core/src/timeout.ts +93 -0
  268. package/packages/core/src/transport/in-process.ts +86 -0
  269. package/packages/core/src/transport/index.ts +6 -0
  270. package/packages/core/src/types/context.ts +229 -0
  271. package/packages/core/src/types/env-cadence.ts +35 -0
  272. package/packages/core/src/types/error-registry.ts +343 -0
  273. package/packages/core/src/types/error.ts +107 -0
  274. package/packages/core/src/types/event.ts +496 -0
  275. package/packages/core/src/types/guardrail.ts +35 -0
  276. package/packages/core/src/types/hook.ts +122 -0
  277. package/packages/core/src/types/index.ts +28 -0
  278. package/packages/core/src/types/lease.ts +91 -0
  279. package/packages/core/src/types/limits.ts +112 -0
  280. package/packages/core/src/types/logging.ts +54 -0
  281. package/packages/core/src/types/member-port.ts +194 -0
  282. package/packages/core/src/types/plugin.ts +392 -0
  283. package/packages/core/src/types/projection-cache.ts +80 -0
  284. package/packages/core/src/types/projection.ts +100 -0
  285. package/packages/core/src/types/provider.ts +319 -0
  286. package/packages/core/src/types/run-journal.ts +178 -0
  287. package/packages/core/src/types/run-record-store.ts +128 -0
  288. package/packages/core/src/types/run.ts +140 -0
  289. package/packages/core/src/types/session.ts +328 -0
  290. package/packages/core/src/types/source-module.ts +68 -0
  291. package/packages/core/src/types/tenant.ts +41 -0
  292. package/packages/core/src/types/tool-name.ts +57 -0
  293. package/packages/core/src/types/tool.ts +122 -0
  294. package/packages/core/src/types/trace.ts +38 -0
  295. package/packages/core/src/types/vision.ts +219 -0
  296. package/packages/core/src/vision/blobs.ts +328 -0
  297. package/packages/core/src/vision/index.ts +73 -0
  298. package/packages/core/src/vision/ingest.ts +126 -0
  299. package/packages/core/src/vision/notice.ts +58 -0
  300. package/packages/core/src/vision/plan.ts +358 -0
  301. package/packages/core/src/vision/staging.ts +81 -0
  302. package/packages/core/tsconfig.json +8 -0
  303. package/packages/permission/package.json +31 -0
  304. package/packages/permission/src/index.ts +60 -0
  305. package/packages/plugin-sdk/package.json +21 -0
  306. package/packages/plugin-sdk/src/index.ts +478 -0
  307. package/packages/plugin-sdk/src/semver.ts +154 -0
  308. package/packages/plugin-ui/package.json +33 -0
  309. package/packages/plugin-ui/src/Badge.tsx +41 -0
  310. package/packages/plugin-ui/src/Button.tsx +84 -0
  311. package/packages/plugin-ui/src/ComposerAttachments.tsx +87 -0
  312. package/packages/plugin-ui/src/ComposerContextMeter.tsx +209 -0
  313. package/packages/plugin-ui/src/ComposerToolbar.tsx +233 -0
  314. package/packages/plugin-ui/src/CountBadge.tsx +57 -0
  315. package/packages/plugin-ui/src/DataTable.tsx +168 -0
  316. package/packages/plugin-ui/src/Field.tsx +543 -0
  317. package/packages/plugin-ui/src/KeyValueList.tsx +32 -0
  318. package/packages/plugin-ui/src/Page.tsx +39 -0
  319. package/packages/plugin-ui/src/Pager.tsx +63 -0
  320. package/packages/plugin-ui/src/SearchInput.tsx +33 -0
  321. package/packages/plugin-ui/src/Section.tsx +47 -0
  322. package/packages/plugin-ui/src/Stat.tsx +25 -0
  323. package/packages/plugin-ui/src/TableToolbar.tsx +27 -0
  324. package/packages/plugin-ui/src/Tabs.tsx +77 -0
  325. package/packages/plugin-ui/src/card-surface.ts +11 -0
  326. package/packages/plugin-ui/src/cn.ts +7 -0
  327. package/packages/plugin-ui/src/dom-globals.d.ts +124 -0
  328. package/packages/plugin-ui/src/host.ts +270 -0
  329. package/packages/plugin-ui/src/index.ts +26 -0
  330. package/packages/plugin-ui/src/styles.css +386 -0
  331. package/packages/plugin-ui/src/useStaleWhileRevalidate.ts +211 -0
  332. package/packages/serve/package.json +32 -0
  333. package/packages/serve/src/agent-control.ts +595 -0
  334. package/packages/serve/src/agents-registry.ts +409 -0
  335. package/packages/serve/src/auth/avatar.ts +352 -0
  336. package/packages/serve/src/auth/bootstrap.ts +184 -0
  337. package/packages/serve/src/auth/credentials.ts +275 -0
  338. package/packages/serve/src/auth/github-oauth.ts +33 -0
  339. package/packages/serve/src/auth/index.ts +121 -0
  340. package/packages/serve/src/auth/oauth.ts +394 -0
  341. package/packages/serve/src/auth/origins.ts +145 -0
  342. package/packages/serve/src/auth/password.ts +187 -0
  343. package/packages/serve/src/auth/ratelimit.ts +249 -0
  344. package/packages/serve/src/auth/routes.ts +1757 -0
  345. package/packages/serve/src/auth/session.ts +407 -0
  346. package/packages/serve/src/auth/totp.ts +183 -0
  347. package/packages/serve/src/backpressure.ts +91 -0
  348. package/packages/serve/src/durable.ts +216 -0
  349. package/packages/serve/src/evals.ts +140 -0
  350. package/packages/serve/src/event-buffer.ts +92 -0
  351. package/packages/serve/src/event-summary.ts +11 -0
  352. package/packages/serve/src/federation.ts +1100 -0
  353. package/packages/serve/src/feishu.ts +51 -0
  354. package/packages/serve/src/gateway/auth.ts +773 -0
  355. package/packages/serve/src/gateway/errors.ts +21 -0
  356. package/packages/serve/src/gateway/frames.ts +195 -0
  357. package/packages/serve/src/gateway/methods/admin.ts +530 -0
  358. package/packages/serve/src/gateway/methods/agents.ts +1727 -0
  359. package/packages/serve/src/gateway/methods/attachments.ts +354 -0
  360. package/packages/serve/src/gateway/methods/common.ts +50 -0
  361. package/packages/serve/src/gateway/methods/config.ts +883 -0
  362. package/packages/serve/src/gateway/methods/evals.ts +87 -0
  363. package/packages/serve/src/gateway/methods/feishu.ts +52 -0
  364. package/packages/serve/src/gateway/methods/fleet.ts +225 -0
  365. package/packages/serve/src/gateway/methods/images.ts +196 -0
  366. package/packages/serve/src/gateway/methods/interactions.ts +721 -0
  367. package/packages/serve/src/gateway/methods/jobs.ts +148 -0
  368. package/packages/serve/src/gateway/methods/kanban.ts +637 -0
  369. package/packages/serve/src/gateway/methods/mcp.ts +82 -0
  370. package/packages/serve/src/gateway/methods/observability.ts +264 -0
  371. package/packages/serve/src/gateway/methods/permissions.ts +397 -0
  372. package/packages/serve/src/gateway/methods/rpc-namespaces.ts +80 -0
  373. package/packages/serve/src/gateway/methods/runs.ts +434 -0
  374. package/packages/serve/src/gateway/methods/schemas.ts +1196 -0
  375. package/packages/serve/src/gateway/methods/sessions.ts +2568 -0
  376. package/packages/serve/src/gateway/methods/subscription.ts +515 -0
  377. package/packages/serve/src/gateway/methods/teams.ts +638 -0
  378. package/packages/serve/src/gateway/sse.ts +130 -0
  379. package/packages/serve/src/gateway/static.ts +66 -0
  380. package/packages/serve/src/gateway/timeline-protocol.ts +532 -0
  381. package/packages/serve/src/gateway.ts +4974 -0
  382. package/packages/serve/src/hub-control.ts +86 -0
  383. package/packages/serve/src/hub-frames.ts +435 -0
  384. package/packages/serve/src/hub-protocol.ts +182 -0
  385. package/packages/serve/src/index.ts +511 -0
  386. package/packages/serve/src/interactions-registry.ts +1362 -0
  387. package/packages/serve/src/interactions-store.ts +360 -0
  388. package/packages/serve/src/local.ts +48 -0
  389. package/packages/serve/src/log-event.ts +57 -0
  390. package/packages/serve/src/mcp.ts +73 -0
  391. package/packages/serve/src/metrics.ts +137 -0
  392. package/packages/serve/src/platform/auth.ts +146 -0
  393. package/packages/serve/src/platform/index.ts +54 -0
  394. package/packages/serve/src/platform/listen-guard.ts +68 -0
  395. package/packages/serve/src/platform/metrics.ts +123 -0
  396. package/packages/serve/src/platform/proxy-config.ts +368 -0
  397. package/packages/serve/src/platform/proxy-ws.ts +737 -0
  398. package/packages/serve/src/platform/proxy.ts +909 -0
  399. package/packages/serve/src/platform/registry.ts +130 -0
  400. package/packages/serve/src/platform/rpc.ts +445 -0
  401. package/packages/serve/src/platform/server.ts +1148 -0
  402. package/packages/serve/src/platform/types.ts +276 -0
  403. package/packages/serve/src/plugin-host/catalog.ts +212 -0
  404. package/packages/serve/src/plugin-host/child.ts +767 -0
  405. package/packages/serve/src/plugin-host/dto.ts +191 -0
  406. package/packages/serve/src/plugin-host/errors.ts +50 -0
  407. package/packages/serve/src/plugin-host/events.ts +114 -0
  408. package/packages/serve/src/plugin-host/expose.ts +142 -0
  409. package/packages/serve/src/plugin-host/http.ts +823 -0
  410. package/packages/serve/src/plugin-host/index.ts +170 -0
  411. package/packages/serve/src/plugin-host/manager.ts +2027 -0
  412. package/packages/serve/src/plugin-host/ndjson.ts +136 -0
  413. package/packages/serve/src/plugin-host/proxy.ts +358 -0
  414. package/packages/serve/src/plugin-host/registry.ts +208 -0
  415. package/packages/serve/src/plugin-host/static.ts +162 -0
  416. package/packages/serve/src/plugin-host/types.ts +529 -0
  417. package/packages/serve/src/plugin-host/ws-proxy.ts +431 -0
  418. package/packages/serve/src/prometheus.ts +98 -0
  419. package/packages/serve/src/protocol.ts +332 -0
  420. package/packages/serve/src/replay-budget.ts +481 -0
  421. package/packages/serve/src/rpc.ts +614 -0
  422. package/packages/serve/src/run-control.ts +106 -0
  423. package/packages/serve/src/session-search.ts +142 -0
  424. package/packages/serve/src/shutdown-step.ts +128 -0
  425. package/packages/serve/src/team-control.ts +282 -0
  426. package/packages/serve/src/tenant-event-hub.ts +194 -0
  427. package/packages/serve/src/tenant.ts +169 -0
  428. package/packages/serve/src/tool-events.ts +244 -0
  429. package/packages/tui/package.json +40 -0
  430. package/packages/tui/src/commands/agents-command.ts +402 -0
  431. package/packages/tui/src/commands/capabilities-command.ts +356 -0
  432. package/packages/tui/src/commands/commands.ts +1361 -0
  433. package/packages/tui/src/commands/config-command.ts +541 -0
  434. package/packages/tui/src/commands/context-command.ts +348 -0
  435. package/packages/tui/src/commands/cost-command.ts +66 -0
  436. package/packages/tui/src/commands/details-command.ts +47 -0
  437. package/packages/tui/src/commands/errors-command.ts +205 -0
  438. package/packages/tui/src/commands/export-command.ts +193 -0
  439. package/packages/tui/src/commands/feishu-command.ts +101 -0
  440. package/packages/tui/src/commands/mcp-command.ts +319 -0
  441. package/packages/tui/src/commands/metrics-command.ts +314 -0
  442. package/packages/tui/src/commands/permissions-command.ts +117 -0
  443. package/packages/tui/src/commands/runs-command.ts +421 -0
  444. package/packages/tui/src/commands/sessions-command.ts +367 -0
  445. package/packages/tui/src/commands/settings-command.ts +180 -0
  446. package/packages/tui/src/commands/status-command.ts +30 -0
  447. package/packages/tui/src/commands/trace-command.ts +382 -0
  448. package/packages/tui/src/components/AskUserDialog.tsx +663 -0
  449. package/packages/tui/src/components/BottomBar.tsx +44 -0
  450. package/packages/tui/src/components/ConfirmDialog.tsx +175 -0
  451. package/packages/tui/src/components/DataTable.tsx +99 -0
  452. package/packages/tui/src/components/DetailPanel.tsx +80 -0
  453. package/packages/tui/src/components/EmptyState.tsx +27 -0
  454. package/packages/tui/src/components/InlineAutocomplete.tsx +319 -0
  455. package/packages/tui/src/components/InteractiveViewHost.tsx +652 -0
  456. package/packages/tui/src/components/KeyHints.tsx +41 -0
  457. package/packages/tui/src/components/Markdown.tsx +489 -0
  458. package/packages/tui/src/components/PanelFrame.tsx +113 -0
  459. package/packages/tui/src/components/QueuePreview.tsx +113 -0
  460. package/packages/tui/src/components/QuickHelp.tsx +91 -0
  461. package/packages/tui/src/components/ReasoningBlock.tsx +42 -0
  462. package/packages/tui/src/components/SessionTable.tsx +523 -0
  463. package/packages/tui/src/components/SpinnerWithVerb.tsx +116 -0
  464. package/packages/tui/src/components/StateTracker.ts +102 -0
  465. package/packages/tui/src/components/StatusBar.tsx +315 -0
  466. package/packages/tui/src/components/StreamOutput.tsx +302 -0
  467. package/packages/tui/src/components/SubagentActivity.tsx +57 -0
  468. package/packages/tui/src/components/TextViewer.tsx +100 -0
  469. package/packages/tui/src/components/ToolDisplay.tsx +248 -0
  470. package/packages/tui/src/components/ToolTrail.tsx +104 -0
  471. package/packages/tui/src/components/UiItemView.tsx +460 -0
  472. package/packages/tui/src/components/UpdateBanner.tsx +48 -0
  473. package/packages/tui/src/components/indicator.ts +61 -0
  474. package/packages/tui/src/error-classifier.ts +255 -0
  475. package/packages/tui/src/i18n/index.ts +67 -0
  476. package/packages/tui/src/i18n/messages/en.ts +543 -0
  477. package/packages/tui/src/i18n/messages/zh-CN.ts +528 -0
  478. package/packages/tui/src/index.ts +335 -0
  479. package/packages/tui/src/renderer/ask-user.ts +431 -0
  480. package/packages/tui/src/renderer/notify-user.ts +184 -0
  481. package/packages/tui/src/renderer/stream-renderer.ts +149 -0
  482. package/packages/tui/src/renderer/tool-confirm.ts +47 -0
  483. package/packages/tui/src/repl/agent-registry.ts +747 -0
  484. package/packages/tui/src/repl/cache-metrics.ts +241 -0
  485. package/packages/tui/src/repl/clear-on-start.ts +28 -0
  486. package/packages/tui/src/repl/error-archive.ts +95 -0
  487. package/packages/tui/src/repl/error-log.ts +212 -0
  488. package/packages/tui/src/repl/ink-repl.tsx +1735 -0
  489. package/packages/tui/src/repl/layout.ts +303 -0
  490. package/packages/tui/src/repl/limit-info.ts +630 -0
  491. package/packages/tui/src/repl/permission-pending.ts +49 -0
  492. package/packages/tui/src/repl/project/ui-item.ts +1307 -0
  493. package/packages/tui/src/repl/queue-info.ts +109 -0
  494. package/packages/tui/src/repl/resume-picker.ts +24 -0
  495. package/packages/tui/src/repl/run-turn.ts +60 -0
  496. package/packages/tui/src/repl/runtime-counters.ts +91 -0
  497. package/packages/tui/src/repl/startup-header.ts +144 -0
  498. package/packages/tui/src/repl/startup-notice.ts +100 -0
  499. package/packages/tui/src/repl/status-format.ts +513 -0
  500. package/packages/tui/src/repl/status-metrics.ts +88 -0
  501. package/packages/tui/src/repl/status-snapshot.ts +454 -0
  502. package/packages/tui/src/repl/use-repl-state.ts +548 -0
  503. package/packages/tui/src/repl-context.ts +349 -0
  504. package/packages/tui/src/rich-renderer.ts +63 -0
  505. package/packages/tui/src/rpc-events.ts +161 -0
  506. package/packages/tui/src/rpc.ts +149 -0
  507. package/packages/tui/src/theme.ts +180 -0
  508. package/packages/tui/src/types/events.ts +284 -0
  509. package/packages/tui/src/utils/dialog.ts +35 -0
  510. package/packages/tui/src/utils/diff.ts +124 -0
  511. package/packages/tui/src/utils/display-labels.ts +56 -0
  512. package/packages/tui/src/utils/file-reference.ts +180 -0
  513. package/packages/tui/src/utils/git.ts +24 -0
  514. package/packages/tui/src/utils/sanitize-terminal-text.ts +109 -0
  515. package/packages/tui/src/utils/text-layout.ts +127 -0
  516. package/packages/tui/src/utils/time.ts +25 -0
  517. package/packages/tui/src/utils/tool-input-summary.ts +70 -0
  518. package/packages/tui/src/views/keys.ts +344 -0
  519. package/packages/tui/src/views/layout.ts +224 -0
  520. package/packages/tui/src/views/render-text.ts +154 -0
  521. package/packages/tui/src/views/selection.ts +57 -0
  522. package/packages/tui/src/views/session-picker.ts +215 -0
  523. package/packages/tui/src/views/tones.ts +24 -0
  524. package/packages/tui/src/views/types.ts +200 -0
  525. package/packages/tui/src/wizard/setup-wizard.ts +439 -0
  526. package/packages/tui/tsconfig.json +10 -0
  527. package/plugins/context/doc-subscription/package.json +32 -0
  528. package/plugins/context/doc-subscription/src/agent.ts +151 -0
  529. package/plugins/context/doc-subscription/src/auto-sub.ts +80 -0
  530. package/plugins/context/doc-subscription/src/config.ts +358 -0
  531. package/plugins/context/doc-subscription/src/diff.ts +107 -0
  532. package/plugins/context/doc-subscription/src/friend-edges.ts +118 -0
  533. package/plugins/context/doc-subscription/src/health.ts +163 -0
  534. package/plugins/context/doc-subscription/src/hook.ts +1222 -0
  535. package/plugins/context/doc-subscription/src/implicit.ts +84 -0
  536. package/plugins/context/doc-subscription/src/index.ts +288 -0
  537. package/plugins/context/doc-subscription/src/lifecycle-listener.ts +58 -0
  538. package/plugins/context/doc-subscription/src/lifecycle.ts +186 -0
  539. package/plugins/context/doc-subscription/src/mute.ts +39 -0
  540. package/plugins/context/doc-subscription/src/notice.ts +347 -0
  541. package/plugins/context/doc-subscription/src/script.ts +288 -0
  542. package/plugins/context/doc-subscription/src/sources.ts +187 -0
  543. package/plugins/context/doc-subscription/src/store.ts +748 -0
  544. package/plugins/context/doc-subscription/src/team-log.ts +155 -0
  545. package/plugins/context/doc-subscription/src/tool.ts +2132 -0
  546. package/plugins/context/skills/package.json +182 -0
  547. package/plugins/context/skills/src/config.ts +178 -0
  548. package/plugins/context/skills/src/frontmatter.ts +166 -0
  549. package/plugins/context/skills/src/index.ts +144 -0
  550. package/plugins/context/skills/src/rpc.ts +274 -0
  551. package/plugins/context/skills/src/scanner.ts +262 -0
  552. package/plugins/context/skills/src/service.ts +277 -0
  553. package/plugins/context/skills/src/store.ts +333 -0
  554. package/plugins/context/skills/src/tool.ts +354 -0
  555. package/plugins/context/skills/src/trust.ts +71 -0
  556. package/plugins/context/skills/src/types.ts +130 -0
  557. package/plugins/context/skills/src/watch.ts +83 -0
  558. package/plugins/context/skills/tsconfig.web.json +29 -0
  559. package/plugins/context/skills/vite.config.embed.ts +107 -0
  560. package/plugins/context/skills/vite.config.ts +121 -0
  561. package/plugins/context/skills/web/assets/skills-8su2cNqF.css +2 -0
  562. package/plugins/context/skills/web/assets/skills-BhiDTAac.js +10 -0
  563. package/plugins/context/skills/web/embed/index.css +3 -0
  564. package/plugins/context/skills/web/embed/index.mjs +4251 -0
  565. package/plugins/context/skills/web/skills.html +13 -0
  566. package/plugins/context/skills/web-src/App.tsx +47 -0
  567. package/plugins/context/skills/web-src/SkillsView.tsx +649 -0
  568. package/plugins/context/skills/web-src/embed.css +153 -0
  569. package/plugins/context/skills/web-src/embed.tsx +36 -0
  570. package/plugins/context/skills/web-src/env.d.ts +2 -0
  571. package/plugins/context/skills/web-src/i18n.ts +195 -0
  572. package/plugins/context/skills/web-src/main.tsx +14 -0
  573. package/plugins/context/skills/web-src/shared.tsx +226 -0
  574. package/plugins/context/skills/web-src/skills.html +12 -0
  575. package/plugins/context/skills/web-src/styles.css +62 -0
  576. package/plugins/context/skills/web-src/types.ts +85 -0
  577. package/plugins/context/thinking-intensity/package.json +201 -0
  578. package/plugins/context/thinking-intensity/src/index.ts +285 -0
  579. package/plugins/context/thinking-intensity/src/mapping.ts +175 -0
  580. package/plugins/context/thinking-intensity/src/state.ts +134 -0
  581. package/plugins/evals/harness/package.json +32 -0
  582. package/plugins/evals/harness/src/assertions.ts +99 -0
  583. package/plugins/evals/harness/src/errors.ts +23 -0
  584. package/plugins/evals/harness/src/index.ts +48 -0
  585. package/plugins/evals/harness/src/mock-provider.ts +64 -0
  586. package/plugins/evals/harness/src/plugin.ts +48 -0
  587. package/plugins/evals/harness/src/report.ts +66 -0
  588. package/plugins/evals/harness/src/runner.ts +417 -0
  589. package/plugins/evals/harness/src/suite.ts +352 -0
  590. package/plugins/evals/harness/src/types.ts +154 -0
  591. package/plugins/fleet/compose/README.md +40 -0
  592. package/plugins/fleet/compose/package.json +172 -0
  593. package/plugins/fleet/compose/src/cli.ts +347 -0
  594. package/plugins/fleet/compose/src/i18n.ts +99 -0
  595. package/plugins/fleet/compose/src/index.ts +3 -0
  596. package/plugins/fleet/compose/src/manifest.ts +194 -0
  597. package/plugins/im/feishu/FEISHU.md +142 -0
  598. package/plugins/im/feishu/package.json +33 -0
  599. package/plugins/im/feishu/src/channel.ts +360 -0
  600. package/plugins/im/feishu/src/config.ts +133 -0
  601. package/plugins/im/feishu/src/dedupe.ts +30 -0
  602. package/plugins/im/feishu/src/errors.ts +21 -0
  603. package/plugins/im/feishu/src/index.ts +47 -0
  604. package/plugins/im/feishu/src/messages.ts +41 -0
  605. package/plugins/im/feishu/src/queue.ts +71 -0
  606. package/plugins/im/feishu/src/runner.ts +356 -0
  607. package/plugins/im/feishu/src/sdk-transport.ts +220 -0
  608. package/plugins/im/feishu/src/text.ts +56 -0
  609. package/plugins/im/feishu/src/types.ts +150 -0
  610. package/plugins/marketplace/marketplace/package.json +166 -0
  611. package/plugins/marketplace/marketplace/registry-template/README.md +105 -0
  612. package/plugins/marketplace/marketplace/registry-template/index.sample.json +71 -0
  613. package/plugins/marketplace/marketplace/registry-template/validate.mjs +272 -0
  614. package/plugins/marketplace/marketplace/registry-template/validate.yml +35 -0
  615. package/plugins/marketplace/marketplace/src/config-lock.ts +325 -0
  616. package/plugins/marketplace/marketplace/src/config.ts +432 -0
  617. package/plugins/marketplace/marketplace/src/errors.ts +79 -0
  618. package/plugins/marketplace/marketplace/src/index.ts +364 -0
  619. package/plugins/marketplace/marketplace/src/install.ts +930 -0
  620. package/plugins/marketplace/marketplace/src/jobs.ts +155 -0
  621. package/plugins/marketplace/marketplace/src/registry.ts +508 -0
  622. package/plugins/marketplace/marketplace/src/semver.ts +162 -0
  623. package/plugins/marketplace/marketplace/src/settings.ts +108 -0
  624. package/plugins/marketplace/marketplace/src/tar.ts +269 -0
  625. package/plugins/marketplace/marketplace/tsconfig.ui.json +26 -0
  626. package/plugins/marketplace/marketplace/vite.config.ts +107 -0
  627. package/plugins/marketplace/marketplace/web/assets/index-B2V7bx73.css +2 -0
  628. package/plugins/marketplace/marketplace/web/assets/index-B4NAz59m.js +13 -0
  629. package/plugins/marketplace/marketplace/web/index.html +13 -0
  630. package/plugins/marketplace/marketplace/web-src/App.tsx +193 -0
  631. package/plugins/marketplace/marketplace/web-src/api.ts +153 -0
  632. package/plugins/marketplace/marketplace/web-src/catalog.ts +27 -0
  633. package/plugins/marketplace/marketplace/web-src/components/ConfirmDialog.tsx +96 -0
  634. package/plugins/marketplace/marketplace/web-src/components/InstalledTable.tsx +152 -0
  635. package/plugins/marketplace/marketplace/web-src/components/JobStatus.tsx +70 -0
  636. package/plugins/marketplace/marketplace/web-src/components/Permissions.tsx +116 -0
  637. package/plugins/marketplace/marketplace/web-src/components/RegistryBanners.tsx +22 -0
  638. package/plugins/marketplace/marketplace/web-src/components/RegistrySetup.tsx +69 -0
  639. package/plugins/marketplace/marketplace/web-src/components/States.tsx +97 -0
  640. package/plugins/marketplace/marketplace/web-src/i18n.ts +337 -0
  641. package/plugins/marketplace/marketplace/web-src/index.html +12 -0
  642. package/plugins/marketplace/marketplace/web-src/main.tsx +17 -0
  643. package/plugins/marketplace/marketplace/web-src/styles.css +37 -0
  644. package/plugins/marketplace/marketplace/web-src/types.ts +175 -0
  645. package/plugins/marketplace/marketplace/web-src/views/InstalledView.tsx +150 -0
  646. package/plugins/marketplace/marketplace/web-src/views/MarketplaceView.tsx +479 -0
  647. package/plugins/marketplace/marketplace/web-src/views/UpdatesView.tsx +207 -0
  648. package/plugins/marketplace/marketplace/web-src/vite-env.d.ts +1 -0
  649. package/plugins/mcp/client/package.json +31 -0
  650. package/plugins/mcp/client/src/config-validate.ts +37 -0
  651. package/plugins/mcp/client/src/http-transport.ts +369 -0
  652. package/plugins/mcp/client/src/index.ts +35 -0
  653. package/plugins/mcp/client/src/json-rpc.ts +104 -0
  654. package/plugins/mcp/client/src/logging.ts +51 -0
  655. package/plugins/mcp/client/src/naming.ts +36 -0
  656. package/plugins/mcp/client/src/plugin.ts +310 -0
  657. package/plugins/mcp/client/src/registration.ts +143 -0
  658. package/plugins/mcp/client/src/server-connection.ts +556 -0
  659. package/plugins/mcp/client/src/stdio-transport.ts +377 -0
  660. package/plugins/mcp/client/src/transport.ts +11 -0
  661. package/plugins/mcp/client/src/types.ts +147 -0
  662. package/plugins/media/media/package.json +33 -0
  663. package/plugins/media/media/src/binaries.ts +88 -0
  664. package/plugins/media/media/src/config.ts +184 -0
  665. package/plugins/media/media/src/exec.ts +172 -0
  666. package/plugins/media/media/src/index.ts +125 -0
  667. package/plugins/media/media/src/tool.ts +640 -0
  668. package/plugins/observability/hook-logging/package.json +31 -0
  669. package/plugins/observability/hook-logging/src/index.ts +286 -0
  670. package/plugins/observability/usage/package.json +163 -0
  671. package/plugins/observability/usage/src/aggregate.ts +919 -0
  672. package/plugins/observability/usage/src/index.ts +362 -0
  673. package/plugins/observability/usage/src/query.ts +322 -0
  674. package/plugins/observability/usage/src/store.ts +1455 -0
  675. package/plugins/observability/usage/src/worker-client.ts +263 -0
  676. package/plugins/observability/usage/src/worker.ts +87 -0
  677. package/plugins/observability/usage/tsconfig.web.json +29 -0
  678. package/plugins/observability/usage/vite.config.embed.ts +105 -0
  679. package/plugins/observability/usage/vite.config.ts +121 -0
  680. package/plugins/observability/usage/web/assets/main-DD4g5VDL.css +2 -0
  681. package/plugins/observability/usage/web/assets/main-DVmWaf73.js +10 -0
  682. package/plugins/observability/usage/web/embed/index.css +3 -0
  683. package/plugins/observability/usage/web/embed/index.mjs +4560 -0
  684. package/plugins/observability/usage/web/logs.html +13 -0
  685. package/plugins/observability/usage/web/usage.html +13 -0
  686. package/plugins/observability/usage/web-src/App.tsx +54 -0
  687. package/plugins/observability/usage/web-src/LogsView.tsx +505 -0
  688. package/plugins/observability/usage/web-src/ModelTable.tsx +102 -0
  689. package/plugins/observability/usage/web-src/UsageView.tsx +210 -0
  690. package/plugins/observability/usage/web-src/embed.css +96 -0
  691. package/plugins/observability/usage/web-src/embed.tsx +75 -0
  692. package/plugins/observability/usage/web-src/env.d.ts +2 -0
  693. package/plugins/observability/usage/web-src/format.ts +88 -0
  694. package/plugins/observability/usage/web-src/i18n.ts +261 -0
  695. package/plugins/observability/usage/web-src/logs.html +12 -0
  696. package/plugins/observability/usage/web-src/main.tsx +19 -0
  697. package/plugins/observability/usage/web-src/shared.tsx +187 -0
  698. package/plugins/observability/usage/web-src/styles.css +22 -0
  699. package/plugins/observability/usage/web-src/usage.html +12 -0
  700. package/plugins/provider/anthropic/package.json +31 -0
  701. package/plugins/provider/anthropic/src/index.ts +75 -0
  702. package/plugins/provider/anthropic/src/retry.ts +266 -0
  703. package/plugins/provider/anthropic/src/timeout.ts +84 -0
  704. package/plugins/provider/model-registry/package.json +167 -0
  705. package/plugins/provider/model-registry/src/connectivity.ts +123 -0
  706. package/plugins/provider/model-registry/src/credential-store.ts +219 -0
  707. package/plugins/provider/model-registry/src/index.ts +453 -0
  708. package/plugins/provider/model-registry/src/registry-store.ts +223 -0
  709. package/plugins/provider/model-registry/tsconfig.web.json +29 -0
  710. package/plugins/provider/model-registry/vite.config.embed.ts +105 -0
  711. package/plugins/provider/model-registry/vite.config.ts +122 -0
  712. package/plugins/provider/model-registry/web/assets/main-BofPzD0n.js +10 -0
  713. package/plugins/provider/model-registry/web/assets/main-DkpGgdsZ.css +2 -0
  714. package/plugins/provider/model-registry/web/credentials.html +13 -0
  715. package/plugins/provider/model-registry/web/embed/index.css +3 -0
  716. package/plugins/provider/model-registry/web/embed/index.mjs +4887 -0
  717. package/plugins/provider/model-registry/web/models.html +13 -0
  718. package/plugins/provider/model-registry/web-src/App.tsx +54 -0
  719. package/plugins/provider/model-registry/web-src/CredentialsView.tsx +357 -0
  720. package/plugins/provider/model-registry/web-src/ModelForm.tsx +489 -0
  721. package/plugins/provider/model-registry/web-src/ModelsView.tsx +383 -0
  722. package/plugins/provider/model-registry/web-src/credentials.html +12 -0
  723. package/plugins/provider/model-registry/web-src/embed.css +96 -0
  724. package/plugins/provider/model-registry/web-src/embed.tsx +43 -0
  725. package/plugins/provider/model-registry/web-src/env.d.ts +2 -0
  726. package/plugins/provider/model-registry/web-src/i18n.ts +323 -0
  727. package/plugins/provider/model-registry/web-src/main.tsx +21 -0
  728. package/plugins/provider/model-registry/web-src/models.html +12 -0
  729. package/plugins/provider/model-registry/web-src/shared.tsx +147 -0
  730. package/plugins/provider/model-registry/web-src/styles.css +22 -0
  731. package/plugins/provider/model-registry/web-src/types.ts +120 -0
  732. package/plugins/provider/openai/package.json +31 -0
  733. package/plugins/provider/openai/src/index.ts +104 -0
  734. package/plugins/provider/openai/src/retry.ts +266 -0
  735. package/plugins/provider/openai/src/timeout.ts +84 -0
  736. package/plugins/provider/openai/src/vision.ts +121 -0
  737. package/plugins/security/guardrail-pii/package.json +31 -0
  738. package/plugins/security/guardrail-pii/src/index.ts +285 -0
  739. package/plugins/security/guardrail-pii/src/rules.ts +197 -0
  740. package/plugins/security/redact-secrets/package.json +31 -0
  741. package/plugins/security/redact-secrets/src/index.ts +145 -0
  742. package/plugins/security/redact-secrets/src/redactor.ts +83 -0
  743. package/plugins/security/redact-secrets/src/rules.ts +137 -0
  744. package/plugins/security/tool-policy/package.json +31 -0
  745. package/plugins/security/tool-policy/src/index.ts +184 -0
  746. package/plugins/tools/basic-tools/package.json +32 -0
  747. package/plugins/tools/basic-tools/src/background-jobs.ts +356 -0
  748. package/plugins/tools/basic-tools/src/bash-source.ts +58 -0
  749. package/plugins/tools/basic-tools/src/call-scope.ts +80 -0
  750. package/plugins/tools/basic-tools/src/config.ts +130 -0
  751. package/plugins/tools/basic-tools/src/index.ts +202 -0
  752. package/plugins/tools/basic-tools/src/path-boundary.ts +258 -0
  753. package/plugins/tools/basic-tools/src/shared.ts +221 -0
  754. package/plugins/tools/basic-tools/src/text.ts +49 -0
  755. package/plugins/tools/basic-tools/src/tools/bash-async.ts +1830 -0
  756. package/plugins/tools/basic-tools/src/tools/bash-exec.ts +567 -0
  757. package/plugins/tools/basic-tools/src/tools/bash.ts +300 -0
  758. package/plugins/tools/basic-tools/src/tools/edit.ts +160 -0
  759. package/plugins/tools/basic-tools/src/tools/grep.ts +601 -0
  760. package/plugins/tools/basic-tools/src/tools/read.ts +151 -0
  761. package/plugins/tools/basic-tools/src/tools/write.ts +494 -0
  762. package/plugins/tools/basic-tools/src/write-coord.ts +291 -0
  763. package/plugins/tools/basic-tools/src/write-lock.ts +353 -0
  764. package/plugins/tools/engine-client/package.json +34 -0
  765. package/plugins/tools/engine-client/src/client.ts +276 -0
  766. package/plugins/tools/engine-client/src/forward.ts +164 -0
  767. package/plugins/tools/engine-client/src/index.ts +18 -0
  768. package/plugins/tools/engine-client/src/pending.ts +101 -0
  769. package/plugins/tools/engine-client/src/pool.ts +1173 -0
  770. package/plugins/tools/engine-client/src/protocol.ts +249 -0
  771. package/plugins/tools/engine-client/src/registry.ts +138 -0
  772. package/plugins/tools/file-refs/README.md +68 -0
  773. package/plugins/tools/file-refs/package.json +135 -0
  774. package/plugins/tools/file-refs/src/index.ts +24 -0
  775. package/plugins/tools/file-refs/tsconfig.web.json +27 -0
  776. package/plugins/tools/file-refs/vite.config.embed.ts +88 -0
  777. package/plugins/tools/file-refs/web/embed/index.css +3 -0
  778. package/plugins/tools/file-refs/web/embed/index.mjs +879 -0
  779. package/plugins/tools/file-refs/web-src/AttachSheet.tsx +613 -0
  780. package/plugins/tools/file-refs/web-src/FileRefCard.tsx +206 -0
  781. package/plugins/tools/file-refs/web-src/FileRefLinkCard.tsx +90 -0
  782. package/plugins/tools/file-refs/web-src/attach-handler.tsx +116 -0
  783. package/plugins/tools/file-refs/web-src/attach-paths.ts +69 -0
  784. package/plugins/tools/file-refs/web-src/drop-handler.ts +15 -0
  785. package/plugins/tools/file-refs/web-src/embed.css +518 -0
  786. package/plugins/tools/file-refs/web-src/embed.tsx +18 -0
  787. package/plugins/tools/file-refs/web-src/env.d.ts +2 -0
  788. package/plugins/tools/file-refs/web-src/i18n.ts +137 -0
  789. package/plugins/tools/file-refs/web-src/icons.tsx +122 -0
  790. package/plugins/tools/file-refs/web-src/staging.ts +120 -0
  791. package/plugins/tools/file-refs/web-src/thumbnail.tsx +36 -0
  792. package/plugins/tools/recall/package.json +31 -0
  793. package/plugins/tools/recall/src/config.ts +74 -0
  794. package/plugins/tools/recall/src/index.ts +151 -0
  795. package/plugins/tools/recall/src/tool.ts +307 -0
  796. package/plugins/tools/web-tools/README.md +330 -0
  797. package/plugins/tools/web-tools/package.json +184 -0
  798. package/plugins/tools/web-tools/src/backends.ts +61 -0
  799. package/plugins/tools/web-tools/src/budget.ts +80 -0
  800. package/plugins/tools/web-tools/src/cache.ts +94 -0
  801. package/plugins/tools/web-tools/src/config.ts +412 -0
  802. package/plugins/tools/web-tools/src/deepseek-client.ts +406 -0
  803. package/plugins/tools/web-tools/src/deepseek-fetch.ts +168 -0
  804. package/plugins/tools/web-tools/src/extract.ts +373 -0
  805. package/plugins/tools/web-tools/src/fetch/local.ts +36 -0
  806. package/plugins/tools/web-tools/src/fetch/provider.ts +56 -0
  807. package/plugins/tools/web-tools/src/http.ts +415 -0
  808. package/plugins/tools/web-tools/src/index.ts +649 -0
  809. package/plugins/tools/web-tools/src/limits.ts +388 -0
  810. package/plugins/tools/web-tools/src/provider-http.ts +102 -0
  811. package/plugins/tools/web-tools/src/render.ts +248 -0
  812. package/plugins/tools/web-tools/src/robots.ts +187 -0
  813. package/plugins/tools/web-tools/src/search/custom.ts +595 -0
  814. package/plugins/tools/web-tools/src/search/deepseek.ts +111 -0
  815. package/plugins/tools/web-tools/src/search/index.ts +725 -0
  816. package/plugins/tools/web-tools/src/search/provider.ts +200 -0
  817. package/plugins/tools/web-tools/src/search/serper.ts +157 -0
  818. package/plugins/tools/web-tools/src/search/tavily.ts +146 -0
  819. package/plugins/tools/web-tools/src/secrets.ts +87 -0
  820. package/plugins/tools/web-tools/src/ssrf.ts +287 -0
  821. package/plugins/tools/web-tools/src/types.ts +137 -0
  822. package/skills/code-writing.md +33 -0
  823. package/src/agent/agent-control.ts +409 -0
  824. package/src/agent/agent-owner-client.ts +150 -0
  825. package/src/agent/agent-owner-server.ts +689 -0
  826. package/src/agent/agent-service-wiring.ts +675 -0
  827. package/src/agent/agent-wiring.ts +48 -0
  828. package/src/agent/ask-answer-delivery.ts +215 -0
  829. package/src/agent/local-run-adapter.ts +335 -0
  830. package/src/agent/peer-notices.ts +459 -0
  831. package/src/agent/peer-source.ts +63 -0
  832. package/src/agent/self-card.ts +52 -0
  833. package/src/agent/team-human-delivery.ts +144 -0
  834. package/src/assembly/collect.ts +161 -0
  835. package/src/assembly/feature.ts +133 -0
  836. package/src/assembly/features/attachments.ts +38 -0
  837. package/src/assembly/features/fleet.ts +31 -0
  838. package/src/assembly/features/jobs.ts +32 -0
  839. package/src/assembly/features/kanban.ts +56 -0
  840. package/src/assembly/features/restart.ts +35 -0
  841. package/src/assembly/features/subscription.ts +32 -0
  842. package/src/assembly/features.ts +30 -0
  843. package/src/cli/agent-call.ts +107 -0
  844. package/src/cli/args.ts +551 -0
  845. package/src/cli/ask-channel.ts +447 -0
  846. package/src/cli/command-spec/agent.ts +306 -0
  847. package/src/cli/command-spec/config.ts +179 -0
  848. package/src/cli/command-spec/define.ts +86 -0
  849. package/src/cli/command-spec/federation.ts +333 -0
  850. package/src/cli/command-spec/flags.ts +668 -0
  851. package/src/cli/command-spec/gateway.ts +350 -0
  852. package/src/cli/command-spec/hub.ts +290 -0
  853. package/src/cli/command-spec/kanban.ts +134 -0
  854. package/src/cli/command-spec/misc.ts +1032 -0
  855. package/src/cli/command-spec/model.ts +338 -0
  856. package/src/cli/command-spec/node.ts +160 -0
  857. package/src/cli/command-spec/plugin.ts +148 -0
  858. package/src/cli/command-spec/shared.ts +86 -0
  859. package/src/cli/command-spec/team.ts +582 -0
  860. package/src/cli/command-spec/token.ts +111 -0
  861. package/src/cli/command-spec.ts +270 -0
  862. package/src/cli/command-support.ts +53 -0
  863. package/src/cli/commands/agent/agent-command.ts +279 -0
  864. package/src/cli/commands/agent/agent-inbox-command.ts +141 -0
  865. package/src/cli/commands/agent/agents-command.ts +145 -0
  866. package/src/cli/commands/attention.ts +896 -0
  867. package/src/cli/commands/cli-update.ts +283 -0
  868. package/src/cli/commands/completion-command.ts +29 -0
  869. package/src/cli/commands/config-command.ts +545 -0
  870. package/src/cli/commands/dev-command.ts +429 -0
  871. package/src/cli/commands/doctor-command.ts +873 -0
  872. package/src/cli/commands/doctor-fleet.ts +410 -0
  873. package/src/cli/commands/errors-command.ts +469 -0
  874. package/src/cli/commands/eval-command.ts +168 -0
  875. package/src/cli/commands/federation-pair.ts +426 -0
  876. package/src/cli/commands/federation-peer.ts +445 -0
  877. package/src/cli/commands/federation.ts +527 -0
  878. package/src/cli/commands/fleet/fleet-inventory.ts +222 -0
  879. package/src/cli/commands/fleet/fleet-status-command.ts +433 -0
  880. package/src/cli/commands/fleet/ps-command.ts +387 -0
  881. package/src/cli/commands/fleet/restart-command.ts +745 -0
  882. package/src/cli/commands/fleet/start-command.ts +176 -0
  883. package/src/cli/commands/fleet/status-command.ts +318 -0
  884. package/src/cli/commands/fleet/stop-command.ts +548 -0
  885. package/src/cli/commands/gateway/gateway-command.ts +4204 -0
  886. package/src/cli/commands/gateway/gateway-nodes-command.ts +401 -0
  887. package/src/cli/commands/hub-command.ts +1007 -0
  888. package/src/cli/commands/kanban-command.ts +204 -0
  889. package/src/cli/commands/logs-command.ts +148 -0
  890. package/src/cli/commands/migrate-command.ts +131 -0
  891. package/src/cli/commands/model.ts +427 -0
  892. package/src/cli/commands/node-command.ts +805 -0
  893. package/src/cli/commands/permission/permission-show-command.ts +189 -0
  894. package/src/cli/commands/plugin/plugin-cli-command.ts +831 -0
  895. package/src/cli/commands/plugin/plugin-cli-local.ts +267 -0
  896. package/src/cli/commands/plugin/plugin-command.ts +407 -0
  897. package/src/cli/commands/prune-command.ts +233 -0
  898. package/src/cli/commands/resume-command.ts +100 -0
  899. package/src/cli/commands/rpc-command.ts +226 -0
  900. package/src/cli/commands/session/session-status-command.ts +352 -0
  901. package/src/cli/commands/team-command.ts +722 -0
  902. package/src/cli/commands/token-command.ts +494 -0
  903. package/src/cli/commands/trace-command.ts +133 -0
  904. package/src/cli/completion-script.ts +627 -0
  905. package/src/cli/completion-spec.ts +101 -0
  906. package/src/cli/control-plane-target.ts +295 -0
  907. package/src/cli/control-plane-types.ts +189 -0
  908. package/src/cli/feishu-command.ts +45 -0
  909. package/src/cli/headless-runner.ts +354 -0
  910. package/src/cli/help-search.ts +320 -0
  911. package/src/cli/help.ts +489 -0
  912. package/src/cli/output.ts +141 -0
  913. package/src/cli/parse-engine.ts +701 -0
  914. package/src/cli/parse-validators.ts +155 -0
  915. package/src/cli/project.ts +355 -0
  916. package/src/cli/registry.ts +25 -0
  917. package/src/cli.ts +2272 -0
  918. package/src/config/cli-overrides.ts +74 -0
  919. package/src/config/config-error-format.ts +44 -0
  920. package/src/config/config-snapshot.ts +15 -0
  921. package/src/config/config-watch.ts +436 -0
  922. package/src/config/config-write-apply.ts +98 -0
  923. package/src/config/empty-response-settings.ts +49 -0
  924. package/src/config/hot-apply-appliers.ts +527 -0
  925. package/src/config/hot-apply-assembly.ts +317 -0
  926. package/src/config/legacy-tool-names.ts +48 -0
  927. package/src/config/permission-defaults.ts +26 -0
  928. package/src/config/ui-settings.ts +568 -0
  929. package/src/config/vision-settings.ts +98 -0
  930. package/src/data/attachment-ingest.ts +101 -0
  931. package/src/data/attachment-staging.ts +377 -0
  932. package/src/data/attachments-list.ts +240 -0
  933. package/src/data/auto-prune.ts +342 -0
  934. package/src/data/data-lock.ts +580 -0
  935. package/src/data/data-paths.ts +265 -0
  936. package/src/data/image-blob-gc.ts +341 -0
  937. package/src/data/migrate.ts +480 -0
  938. package/src/data/path-resolution.ts +172 -0
  939. package/src/data/permission-store.ts +322 -0
  940. package/src/data/prune-wiring.ts +1037 -0
  941. package/src/data/refs-notice-hook.ts +417 -0
  942. package/src/federation/attention-client.ts +196 -0
  943. package/src/federation/attention-nodes.ts +142 -0
  944. package/src/federation/federation-address.ts +276 -0
  945. package/src/federation/federation-client.ts +620 -0
  946. package/src/federation/federation-config.ts +222 -0
  947. package/src/federation/federation-outbox.ts +374 -0
  948. package/src/federation/federation-pair-store.ts +236 -0
  949. package/src/federation/federation-pairing.ts +176 -0
  950. package/src/federation/federation-peer-store.ts +145 -0
  951. package/src/federation/federation-secrets.ts +140 -0
  952. package/src/federation/federation-send-port.ts +436 -0
  953. package/src/gateway/clean-spawn.ts +260 -0
  954. package/src/gateway/daemon.ts +336 -0
  955. package/src/gateway/fleet-index.ts +262 -0
  956. package/src/gateway/gateway-banner.ts +199 -0
  957. package/src/gateway/gateway-config-control.ts +53 -0
  958. package/src/gateway/gateway-reload-wiring.ts +512 -0
  959. package/src/gateway/gateway-wiring.ts +113 -0
  960. package/src/gateway/handoff.ts +131 -0
  961. package/src/gateway/instance-lock.ts +244 -0
  962. package/src/gateway/interactions-dir.ts +27 -0
  963. package/src/gateway/node-listen.ts +123 -0
  964. package/src/gateway/node-registry.ts +401 -0
  965. package/src/gateway/node-supervisor.ts +2226 -0
  966. package/src/gateway/pid.ts +827 -0
  967. package/src/gateway/pool-supervisor.ts +1150 -0
  968. package/src/gateway/reload.ts +238 -0
  969. package/src/gateway/restart-stop-exemption.ts +43 -0
  970. package/src/gateway/self-restart.ts +147 -0
  971. package/src/gateway/serve-auth.ts +184 -0
  972. package/src/gateway/serve-config.ts +135 -0
  973. package/src/gateway/service.ts +361 -0
  974. package/src/gateway/shutdown-report.ts +47 -0
  975. package/src/gateway/shutdown-sequence.ts +70 -0
  976. package/src/gateway/stop-drain.ts +299 -0
  977. package/src/gateway/stop-nodes-marker.ts +151 -0
  978. package/src/gateway/transport-factory.ts +53 -0
  979. package/src/gateway/watchdog.ts +622 -0
  980. package/src/gateway/web-dist.ts +1155 -0
  981. package/src/hub/client-protocol.ts +43 -0
  982. package/src/hub/derive-origins.ts +193 -0
  983. package/src/hub/hub-wiring.ts +310 -0
  984. package/src/hub/inbound-control.ts +432 -0
  985. package/src/hub/join-policy.ts +75 -0
  986. package/src/hub/join-store.ts +243 -0
  987. package/src/hub/node-credential-store.ts +295 -0
  988. package/src/hub/node-state.ts +279 -0
  989. package/src/hub/node-url.ts +33 -0
  990. package/src/hub/outbound-client.ts +509 -0
  991. package/src/hub/outbound-wiring.ts +168 -0
  992. package/src/hub/pairing-code.ts +27 -0
  993. package/src/hub/registry.ts +575 -0
  994. package/src/hub/runtime.ts +599 -0
  995. package/src/hub/secret-store.ts +571 -0
  996. package/src/hub/server.ts +1032 -0
  997. package/src/hub/snapshot-policy.ts +67 -0
  998. package/src/hub/types.ts +258 -0
  999. package/src/i18n/index.ts +94 -0
  1000. package/src/i18n/messages/en.ts +1462 -0
  1001. package/src/i18n/messages/zh-CN.ts +1323 -0
  1002. package/src/mock/scenarios.ts +165 -0
  1003. package/src/node/node-auto-resume.ts +264 -0
  1004. package/src/node/node-drain.ts +520 -0
  1005. package/src/node/node-identity.ts +240 -0
  1006. package/src/node/node-resume.ts +511 -0
  1007. package/src/node/resume-scan.ts +97 -0
  1008. package/src/node/token-derive.ts +504 -0
  1009. package/src/observability/logging.ts +72 -0
  1010. package/src/observability/observability-wiring.ts +82 -0
  1011. package/src/observability/startup-timing.ts +151 -0
  1012. package/src/observability/trace-wiring.ts +250 -0
  1013. package/src/observability/usage-pricing.ts +80 -0
  1014. package/src/plugin/eval-wiring.ts +175 -0
  1015. package/src/plugin/feishu-wiring.ts +250 -0
  1016. package/src/plugin/mcp-wiring.ts +200 -0
  1017. package/src/plugin/plugin-config.ts +491 -0
  1018. package/src/plugin/plugin-host-assembly.ts +448 -0
  1019. package/src/plugin/plugin-lifecycle.ts +130 -0
  1020. package/src/plugin/plugin-loader.ts +788 -0
  1021. package/src/plugin/plugin-manifest.ts +1936 -0
  1022. package/src/plugin/plugin-selection.ts +200 -0
  1023. package/src/plugin/plugin-surface.ts +207 -0
  1024. package/src/plugin/plugin-watch.ts +114 -0
  1025. package/src/rpc/http-client.ts +579 -0
  1026. package/src/rpc/index.ts +34 -0
  1027. package/src/rpc/local-client.ts +55 -0
  1028. package/src/rpc/types.ts +125 -0
  1029. package/src/run/connect-run-wait.ts +544 -0
  1030. package/src/run/durable-wiring.ts +133 -0
  1031. package/src/run/lease-service.ts +510 -0
  1032. package/src/run/run-control.ts +160 -0
  1033. package/src/run/run-record-store-factory.ts +89 -0
  1034. package/src/runtime/agent-activity-watch.ts +335 -0
  1035. package/src/runtime/agent-assembly.ts +818 -0
  1036. package/src/runtime/agent-events-bridge.ts +86 -0
  1037. package/src/runtime/bash-job-delivery.ts +291 -0
  1038. package/src/runtime/bootstrap-connect.ts +644 -0
  1039. package/src/runtime/bootstrap-types.ts +303 -0
  1040. package/src/runtime/bootstrap.ts +1020 -0
  1041. package/src/runtime/bus-source.ts +62 -0
  1042. package/src/runtime/gc-assembly.ts +214 -0
  1043. package/src/runtime/local-rpc-surface.ts +301 -0
  1044. package/src/runtime/model-registry-wiring.ts +653 -0
  1045. package/src/runtime/node-health-watch.ts +484 -0
  1046. package/src/runtime/node-restart.ts +444 -0
  1047. package/src/runtime/process-handlers.ts +164 -0
  1048. package/src/runtime/provider-factory.ts +86 -0
  1049. package/src/runtime/reasoning.ts +47 -0
  1050. package/src/runtime/repl-context.ts +234 -0
  1051. package/src/runtime/runtime-notice-hook.ts +357 -0
  1052. package/src/runtime/runtime-notice.ts +273 -0
  1053. package/src/runtime/session-id.ts +15 -0
  1054. package/src/runtime/shutdown-sequence.ts +429 -0
  1055. package/src/runtime/subscription-mute-bridge.ts +99 -0
  1056. package/src/runtime/subscription-rpc-port.ts +597 -0
  1057. package/src/runtime/team-log-bridge.ts +46 -0
  1058. package/src/runtime/tenant-runtime-factory.ts +1838 -0
  1059. package/src/runtime/thinking-agent-bridge.ts +57 -0
  1060. package/src/runtime/tool-output-env.ts +80 -0
  1061. package/src/runtime/vessel-meta.ts +338 -0
  1062. package/src/session/context-composition.ts +147 -0
  1063. package/src/session/context-ratio-source.ts +165 -0
  1064. package/src/session/context-usage.ts +346 -0
  1065. package/src/session/image-delivery.ts +297 -0
  1066. package/src/session/session-control.ts +135 -0
  1067. package/src/session/session-events.ts +144 -0
  1068. package/src/session/session-factory.ts +73 -0
  1069. package/src/session/session-liveness.ts +405 -0
  1070. package/src/session/session-lock-runtime.ts +64 -0
  1071. package/src/session/session-lock.ts +399 -0
  1072. package/src/session/session-resume.ts +282 -0
  1073. package/src/session/system-context.ts +235 -0
  1074. package/src/session/timeline-dual-write.ts +2129 -0
  1075. package/src/session/timeline-session-log.ts +140 -0
  1076. package/src/shared/port-in-use.ts +27 -0
  1077. package/src/shared/socket-inherit-guard.ts +13 -0
  1078. package/src/shared/version.ts +38 -0
  1079. package/src/tools-engine/engine.ts +286 -0
  1080. package/src/tools-engine/entry.ts +757 -0
  1081. package/src/tools-engine/mcp-engine-wiring.ts +354 -0
  1082. package/src/tools-engine/mcp.ts +324 -0
  1083. package/src/tools-engine/supervisor.ts +234 -0
  1084. package/src/tools-engine/tools-list.ts +148 -0
  1085. package/src/tools-engine/validate.ts +395 -0
  1086. package/src/tools-engine/wiring.ts +88 -0
  1087. package/src/tools-engine/worker.ts +110 -0
  1088. package/src/update/background.ts +64 -0
  1089. package/src/update/cache.ts +70 -0
  1090. package/src/update/check.ts +138 -0
  1091. package/src/update/gateway-check.ts +231 -0
  1092. package/src/update/install-detect.ts +125 -0
  1093. package/src/update/manifest.ts +132 -0
  1094. package/src/update/semver.ts +70 -0
  1095. package/src/update/stage.ts +219 -0
@@ -0,0 +1,4560 @@
1
+ /* biome-ignore-all lint format assist: generated by `bun run build:ui` */
2
+ import { jsx as a, jsxs as R, Fragment as Ee } from "react/jsx-runtime";
3
+ import { forwardRef as fe, useState as V, useRef as q, useId as Ut, useImperativeHandle as Bt, useCallback as Y, useEffect as Q, useLayoutEffect as Wt, isValidElement as Kt, Fragment as Yt, useMemo as ge } from "react";
4
+ import { createPortal as Jt } from "react-dom";
5
+ const dt = {
6
+ "common.loading": "Loading…",
7
+ "common.updating": "Updating…",
8
+ "common.stale": "Update failed; showing data from {time}.",
9
+ "common.retry": "Retry",
10
+ "common.refresh": "Refresh",
11
+ "common.apply": "Apply",
12
+ "common.loadMore": "Load more",
13
+ "common.loadError": "Could not load this view",
14
+ "common.loadMoreError": "Could not load more logs",
15
+ "common.status.ok": "ok",
16
+ "common.status.failed": "failed",
17
+ "range.label": "Time range",
18
+ "range.1": "Today",
19
+ "range.7": "7 days",
20
+ "range.30": "30 days",
21
+ "range.90": "90 days",
22
+ "range.0": "All time",
23
+ "range.custom": "Custom range",
24
+ "range.from": "From",
25
+ "range.to": "To",
26
+ "range.apply": "Apply range",
27
+ "range.clear": "Back to presets",
28
+ "range.invalid": "Pick a start before the end.",
29
+ "usage.title": "Usage",
30
+ "usage.description": "Token usage, cache hits and cost.",
31
+ "usage.toolbar": "Usage controls",
32
+ "usage.requests": "Requests",
33
+ "usage.promptTokens": "Prompt tokens",
34
+ "usage.completionTokens": "Completion tokens",
35
+ "usage.cacheRead": "Cache read",
36
+ "usage.inputShare": "Input share",
37
+ "usage.prefixHealth": "Prefix health",
38
+ "usage.cost": "Cost",
39
+ "usage.failedRuns": "{n} failed run(s)",
40
+ "usage.promptHint": "Includes cache counters",
41
+ "usage.cacheNotReported": "Not reported by provider",
42
+ "usage.cacheHint": "Read from the prompt cache",
43
+ "usage.inputShareHint": "Cache read / prompt tokens",
44
+ "usage.prefixHealthHint": "Cache read / (read + write)",
45
+ "usage.costNoPrice": "No configured price for these models",
46
+ "usage.costPartial": "{n} unpriced request(s); total covers priced models",
47
+ "usage.costHint": "USD, from configured prices",
48
+ "usage.byDay": "By day",
49
+ "usage.byModel": "By model",
50
+ "usage.empty.title": "No usage data yet",
51
+ "usage.empty.description": "Run a request through Vessel. Usage appears here once the event log has records in the selected range.",
52
+ "usage.th.day": "Day",
53
+ "usage.th.requests": "Requests",
54
+ "usage.th.prompt": "Prompt",
55
+ "usage.th.completion": "Completion",
56
+ "usage.th.cacheRead": "Cache read",
57
+ "usage.th.failed": "Failed",
58
+ "usage.th.unpriced": "Unpriced",
59
+ "usage.th.cost": "Cost",
60
+ "ratio.noRequests": "No requests in range",
61
+ "ratio.noCacheFields": "Provider did not report cache",
62
+ "ratio.zeroDenominator": "No cache activity in range",
63
+ "ratio.promptNotInclusive": "Cache counters exceed prompt tokens",
64
+ "ratio.writeNotReported": "Cache writes were not reported",
65
+ "logs.title": "Logs",
66
+ "logs.description": "Per-request usage and latency, newest first.",
67
+ "logs.toolbar": "Log filters",
68
+ "logs.session": "Session",
69
+ "logs.model": "Model",
70
+ "logs.status": "Status",
71
+ "logs.sessionPlaceholder": "Session id",
72
+ "logs.modelPlaceholder": "Model",
73
+ "logs.allStatuses": "All statuses",
74
+ "logs.optionOk": "OK",
75
+ "logs.optionFailed": "Failed",
76
+ "logs.th.time": "Time",
77
+ "logs.th.status": "Status",
78
+ "logs.th.model": "Model",
79
+ "logs.th.session": "Session",
80
+ "logs.th.prompt": "Prompt",
81
+ "logs.th.completion": "Completion",
82
+ "logs.th.cacheRead": "Cache read",
83
+ "logs.th.duration": "Duration",
84
+ "logs.th.cost": "Cost",
85
+ "logs.empty.title": "No request logs yet",
86
+ "logs.empty.filtered": "No matching requests",
87
+ "logs.empty.description": "Logs are read from each session’s timeline (wal.log).",
88
+ "logs.state.range": "Range: {range}",
89
+ "logs.state.custom": "Range: {from} to {to}",
90
+ "logs.state.loaded": "{n} loaded",
91
+ "logs.state.more": "more available",
92
+ "logs.state.end": "no more rows",
93
+ "logs.state.conditions": "Filters: {conditions}",
94
+ "logs.truncated.files": "Read cap reached: only {files} of {total} session timelines in this range were counted. Sessions in the same range that were not read are missing, so this is a partial count, not the total.",
95
+ "logs.truncated.partial": "Partial read: {files} session timeline(s) in this range were only counted partially (only their newest events were read), so those sessions may be missing requests.",
96
+ "source.retired": "Usage cannot be computed: this page reads the session timeline (sessions/<id>/wal.log), and no session on disk has one. Sessions from before 0.55 only carry events.ndjson, which Vessel can no longer read. The numbers here are empty because the source is unreadable, not because there was no usage.",
97
+ "source.unreadable": "Not counted: {files} session(s) on disk have no readable timeline (pre-0.55 events.ndjson only). Their usage is missing from these totals, not zero.",
98
+ "leaderboard.th.model": "Model",
99
+ "leaderboard.th.requests": "Requests",
100
+ "leaderboard.th.tokens": "Tokens",
101
+ "leaderboard.th.cacheRead": "Cache read",
102
+ "leaderboard.th.cost": "Cost",
103
+ "leaderboard.empty.title": "No model usage yet",
104
+ "leaderboard.empty.description": "Run a request through Vessel. Models appear here once usage records exist."
105
+ }, Zt = {
106
+ "common.loading": "加载中…",
107
+ "common.updating": "更新中…",
108
+ "common.stale": "更新失败,显示 {time} 的数据。",
109
+ "common.retry": "重试",
110
+ "common.refresh": "刷新",
111
+ "common.apply": "应用",
112
+ "common.loadMore": "加载更多",
113
+ "common.loadError": "无法加载此视图",
114
+ "common.loadMoreError": "无法加载更多日志",
115
+ "common.status.ok": "成功",
116
+ "common.status.failed": "失败",
117
+ "range.label": "时间范围",
118
+ "range.1": "今天",
119
+ "range.7": "7 天",
120
+ "range.30": "30 天",
121
+ "range.90": "90 天",
122
+ "range.0": "全部时间",
123
+ "range.custom": "自定义区间",
124
+ "range.from": "开始",
125
+ "range.to": "结束",
126
+ "range.apply": "应用区间",
127
+ "range.clear": "回到预设范围",
128
+ "range.invalid": "开始时间必须早于结束时间。",
129
+ "usage.title": "用量",
130
+ "usage.description": "Token 用量、缓存命中与成本概览。",
131
+ "usage.toolbar": "用量控件",
132
+ "usage.requests": "请求数",
133
+ "usage.promptTokens": "Prompt Token",
134
+ "usage.completionTokens": "Completion Token",
135
+ "usage.cacheRead": "缓存读取",
136
+ "usage.inputShare": "输入占比",
137
+ "usage.prefixHealth": "前缀健康度",
138
+ "usage.cost": "成本",
139
+ "usage.failedRuns": "{n} 次运行失败",
140
+ "usage.promptHint": "包含缓存计数",
141
+ "usage.cacheNotReported": "提供商未上报",
142
+ "usage.cacheHint": "从 prompt 缓存读取",
143
+ "usage.inputShareHint": "缓存读取 / prompt Token",
144
+ "usage.prefixHealthHint": "缓存读取 / (读取 + 写入)",
145
+ "usage.costNoPrice": "这些模型未配置价格",
146
+ "usage.costPartial": "{n} 次请求未计价;合计仅含已定价模型",
147
+ "usage.costHint": "美元,按已配置价格计算",
148
+ "usage.byDay": "按天",
149
+ "usage.byModel": "按模型",
150
+ "usage.empty.title": "暂无用量数据",
151
+ "usage.empty.description": "在 Vessel 中发起一次请求。事件日志有所选范围内的记录后,用量会显示在这里。",
152
+ "usage.th.day": "日期",
153
+ "usage.th.requests": "请求数",
154
+ "usage.th.prompt": "Prompt",
155
+ "usage.th.completion": "Completion",
156
+ "usage.th.cacheRead": "缓存读取",
157
+ "usage.th.failed": "失败",
158
+ "usage.th.unpriced": "未计价",
159
+ "usage.th.cost": "成本",
160
+ "ratio.noRequests": "范围内没有请求",
161
+ "ratio.noCacheFields": "提供商未上报缓存",
162
+ "ratio.zeroDenominator": "范围内没有缓存活动",
163
+ "ratio.promptNotInclusive": "缓存计数超过 prompt Token",
164
+ "ratio.writeNotReported": "未上报缓存写入",
165
+ "logs.title": "日志",
166
+ "logs.description": "按时间查看每次请求的用量与延迟。",
167
+ "logs.toolbar": "日志筛选",
168
+ "logs.session": "会话",
169
+ "logs.model": "模型",
170
+ "logs.status": "状态",
171
+ "logs.sessionPlaceholder": "会话 ID",
172
+ "logs.modelPlaceholder": "模型",
173
+ "logs.allStatuses": "全部状态",
174
+ "logs.optionOk": "成功",
175
+ "logs.optionFailed": "失败",
176
+ "logs.th.time": "时间",
177
+ "logs.th.status": "状态",
178
+ "logs.th.model": "模型",
179
+ "logs.th.session": "会话",
180
+ "logs.th.prompt": "Prompt",
181
+ "logs.th.completion": "Completion",
182
+ "logs.th.cacheRead": "缓存读取",
183
+ "logs.th.duration": "耗时",
184
+ "logs.th.cost": "成本",
185
+ "logs.empty.title": "暂无请求日志",
186
+ "logs.empty.filtered": "没有匹配的请求",
187
+ "logs.empty.description": "日志来自每个会话的时间线(wal.log)。",
188
+ "logs.state.range": "范围:{range}",
189
+ "logs.state.custom": "范围:{from} 至 {to}",
190
+ "logs.state.loaded": "已加载 {n} 条",
191
+ "logs.state.more": "还有更多",
192
+ "logs.state.end": "已到底",
193
+ "logs.state.conditions": "筛选:{conditions}",
194
+ "logs.truncated.files": "已触及读取上限:该范围内只统计了 {files}/{total} 个会话时间线,同一范围内未读取的会话没有计入 —— 这是真实截断后的部分合计,不是总量。",
195
+ "logs.truncated.partial": "部分读取:该范围内有 {files} 个会话时间线只统计了尾部(更早的事件没读),这些会话可能缺少请求记录。",
196
+ "source.retired": "用量无法统计:本页读取会话时间线(sessions/<id>/wal.log),而盘上没有任何会话带有它。0.55 之前的会话只有 events.ndjson,Vessel 已经无法解析。这里的空数字是数据源读不到,不是没有用量。",
197
+ "source.unreadable": "未计入:盘上有 {files} 个会话没有可读的时间线(只有 0.55 之前的 events.ndjson)。它们的用量不在这些合计里 —— 不是 0。",
198
+ "leaderboard.th.model": "模型",
199
+ "leaderboard.th.requests": "请求数",
200
+ "leaderboard.th.tokens": "Token",
201
+ "leaderboard.th.cacheRead": "缓存读取",
202
+ "leaderboard.th.cost": "成本",
203
+ "leaderboard.empty.title": "暂无模型用量",
204
+ "leaderboard.empty.description": "在 Vessel 中发起一次请求。有用量记录后模型会显示在这里。"
205
+ };
206
+ function Xt(e) {
207
+ return e?.trim().toLowerCase().startsWith("zh") === !0 ? "zh-CN" : "en";
208
+ }
209
+ function Qt(e, t) {
210
+ if (t === void 0) return e;
211
+ let o = e;
212
+ for (const [r, n] of Object.entries(t))
213
+ o = o.split(`{${r}}`).join(String(n));
214
+ return o;
215
+ }
216
+ function ut(e) {
217
+ const t = eo[Xt(e)];
218
+ return (o, r) => Qt(t[o] ?? dt[o] ?? o, r);
219
+ }
220
+ const eo = {
221
+ en: dt,
222
+ "zh-CN": Zt
223
+ };
224
+ function mt(e) {
225
+ var t, o, r = "";
226
+ if (typeof e == "string" || typeof e == "number") r += e;
227
+ else if (typeof e == "object") if (Array.isArray(e)) {
228
+ var n = e.length;
229
+ for (t = 0; t < n; t++) e[t] && (o = mt(e[t])) && (r && (r += " "), r += o);
230
+ } else for (o in e) e[o] && (r && (r += " "), r += o);
231
+ return r;
232
+ }
233
+ function pt() {
234
+ for (var e, t, o = 0, r = "", n = arguments.length; o < n; o++) (e = arguments[o]) && (t = mt(e)) && (r && (r += " "), r += t);
235
+ return r;
236
+ }
237
+ const qe = (e) => typeof e == "boolean" ? `${e}` : e === 0 ? "0" : e, Ue = pt, gt = (e, t) => (o) => {
238
+ var r;
239
+ if (t?.variants == null) return Ue(e, o?.class, o?.className);
240
+ const { variants: n, defaultVariants: s } = t, i = Object.keys(n).map((l) => {
241
+ const f = o?.[l], b = s?.[l];
242
+ if (f === null) return null;
243
+ const w = qe(f) || qe(b);
244
+ return n[l][w];
245
+ }), d = o && Object.entries(o).reduce((l, f) => {
246
+ let [b, w] = f;
247
+ return w === void 0 || (l[b] = w), l;
248
+ }, {}), c = t == null || (r = t.compoundVariants) === null || r === void 0 ? void 0 : r.reduce((l, f) => {
249
+ let { class: b, className: w, ...C } = f;
250
+ return Object.entries(C).every((P) => {
251
+ let [v, M] = P;
252
+ return Array.isArray(M) ? M.includes({
253
+ ...s,
254
+ ...d
255
+ }[v]) : {
256
+ ...s,
257
+ ...d
258
+ }[v] === M;
259
+ }) ? [
260
+ ...l,
261
+ b,
262
+ w
263
+ ] : l;
264
+ }, []);
265
+ return Ue(e, i, c, o?.class, o?.className);
266
+ }, to = (e, t) => {
267
+ const o = new Array(e.length + t.length);
268
+ for (let r = 0; r < e.length; r++)
269
+ o[r] = e[r];
270
+ for (let r = 0; r < t.length; r++)
271
+ o[e.length + r] = t[r];
272
+ return o;
273
+ }, oo = (e, t) => ({
274
+ classGroupId: e,
275
+ validator: t
276
+ }), ft = (e = /* @__PURE__ */ new Map(), t = null, o) => ({
277
+ nextPart: e,
278
+ validators: t,
279
+ classGroupId: o
280
+ }), Ae = "-", Be = [], ro = "arbitrary..", no = (e) => {
281
+ const t = ao(e), {
282
+ conflictingClassGroups: o,
283
+ conflictingClassGroupModifiers: r
284
+ } = e;
285
+ return {
286
+ getClassGroupId: (i) => {
287
+ if (i.startsWith("[") && i.endsWith("]"))
288
+ return so(i);
289
+ const d = i.split(Ae), c = d[0] === "" && d.length > 1 ? 1 : 0;
290
+ return ht(d, c, t);
291
+ },
292
+ getConflictingClassGroupIds: (i, d) => {
293
+ if (d) {
294
+ const c = r[i], l = o[i];
295
+ return c ? l ? to(l, c) : c : l || Be;
296
+ }
297
+ return o[i] || Be;
298
+ }
299
+ };
300
+ }, ht = (e, t, o) => {
301
+ if (e.length - t === 0)
302
+ return o.classGroupId;
303
+ const n = e[t], s = o.nextPart.get(n);
304
+ if (s) {
305
+ const l = ht(e, t + 1, s);
306
+ if (l) return l;
307
+ }
308
+ const i = o.validators;
309
+ if (i === null)
310
+ return;
311
+ const d = t === 0 ? e.join(Ae) : e.slice(t).join(Ae), c = i.length;
312
+ for (let l = 0; l < c; l++) {
313
+ const f = i[l];
314
+ if (f.validator(d))
315
+ return f.classGroupId;
316
+ }
317
+ }, so = (e) => e.slice(1, -1).indexOf(":") === -1 ? void 0 : (() => {
318
+ const t = e.slice(1, -1), o = t.indexOf(":"), r = t.slice(0, o);
319
+ return r ? ro + r : void 0;
320
+ })(), ao = (e) => {
321
+ const {
322
+ theme: t,
323
+ classGroups: o
324
+ } = e;
325
+ return io(o, t);
326
+ }, io = (e, t) => {
327
+ const o = ft();
328
+ for (const r in e) {
329
+ const n = e[r];
330
+ Fe(n, o, r, t);
331
+ }
332
+ return o;
333
+ }, Fe = (e, t, o, r) => {
334
+ const n = e.length;
335
+ for (let s = 0; s < n; s++) {
336
+ const i = e[s];
337
+ lo(i, t, o, r);
338
+ }
339
+ }, lo = (e, t, o, r) => {
340
+ if (typeof e == "string") {
341
+ co(e, t, o);
342
+ return;
343
+ }
344
+ if (typeof e == "function") {
345
+ uo(e, t, o, r);
346
+ return;
347
+ }
348
+ mo(e, t, o, r);
349
+ }, co = (e, t, o) => {
350
+ const r = e === "" ? t : bt(t, e);
351
+ r.classGroupId = o;
352
+ }, uo = (e, t, o, r) => {
353
+ if (po(e)) {
354
+ Fe(e(r), t, o, r);
355
+ return;
356
+ }
357
+ t.validators === null && (t.validators = []), t.validators.push(oo(o, e));
358
+ }, mo = (e, t, o, r) => {
359
+ const n = Object.entries(e), s = n.length;
360
+ for (let i = 0; i < s; i++) {
361
+ const [d, c] = n[i];
362
+ Fe(c, bt(t, d), o, r);
363
+ }
364
+ }, bt = (e, t) => {
365
+ let o = e;
366
+ const r = t.split(Ae), n = r.length;
367
+ for (let s = 0; s < n; s++) {
368
+ const i = r[s];
369
+ let d = o.nextPart.get(i);
370
+ d || (d = ft(), o.nextPart.set(i, d)), o = d;
371
+ }
372
+ return o;
373
+ }, po = (e) => "isThemeGetter" in e && e.isThemeGetter === !0, go = (e) => {
374
+ if (e < 1)
375
+ return {
376
+ get: () => {
377
+ },
378
+ set: () => {
379
+ }
380
+ };
381
+ let t = 0, o = /* @__PURE__ */ Object.create(null), r = /* @__PURE__ */ Object.create(null);
382
+ const n = (s, i) => {
383
+ o[s] = i, t++, t > e && (t = 0, r = o, o = /* @__PURE__ */ Object.create(null));
384
+ };
385
+ return {
386
+ get(s) {
387
+ let i = o[s];
388
+ if (i !== void 0)
389
+ return i;
390
+ if ((i = r[s]) !== void 0)
391
+ return n(s, i), i;
392
+ },
393
+ set(s, i) {
394
+ s in o ? o[s] = i : n(s, i);
395
+ }
396
+ };
397
+ }, Ie = "!", We = ":", fo = [], Ke = (e, t, o, r, n) => ({
398
+ modifiers: e,
399
+ hasImportantModifier: t,
400
+ baseClassName: o,
401
+ maybePostfixModifierPosition: r,
402
+ isExternal: n
403
+ }), ho = (e) => {
404
+ const {
405
+ prefix: t,
406
+ experimentalParseClassName: o
407
+ } = e;
408
+ let r = (n) => {
409
+ const s = [];
410
+ let i = 0, d = 0, c = 0, l;
411
+ const f = n.length;
412
+ for (let v = 0; v < f; v++) {
413
+ const M = n[v];
414
+ if (i === 0 && d === 0) {
415
+ if (M === We) {
416
+ s.push(n.slice(c, v)), c = v + 1;
417
+ continue;
418
+ }
419
+ if (M === "/") {
420
+ l = v;
421
+ continue;
422
+ }
423
+ }
424
+ M === "[" ? i++ : M === "]" ? i-- : M === "(" ? d++ : M === ")" && d--;
425
+ }
426
+ const b = s.length === 0 ? n : n.slice(c);
427
+ let w = b, C = !1;
428
+ b.endsWith(Ie) ? (w = b.slice(0, -1), C = !0) : (
429
+ /**
430
+ * In Tailwind CSS v3 the important modifier was at the start of the base class name. This is still supported for legacy reasons.
431
+ * @see https://github.com/dcastil/tailwind-merge/issues/513#issuecomment-2614029864
432
+ */
433
+ b.startsWith(Ie) && (w = b.slice(1), C = !0)
434
+ );
435
+ const P = l && l > c ? l - c : void 0;
436
+ return Ke(s, C, w, P);
437
+ };
438
+ if (t) {
439
+ const n = t + We, s = r;
440
+ r = (i) => i.startsWith(n) ? s(i.slice(n.length)) : Ke(fo, !1, i, void 0, !0);
441
+ }
442
+ if (o) {
443
+ const n = r;
444
+ r = (s) => o({
445
+ className: s,
446
+ parseClassName: n
447
+ });
448
+ }
449
+ return r;
450
+ }, bo = (e) => {
451
+ const t = /* @__PURE__ */ new Map();
452
+ return e.orderSensitiveModifiers.forEach((o, r) => {
453
+ t.set(o, 1e6 + r);
454
+ }), (o) => {
455
+ const r = [];
456
+ let n = [];
457
+ for (let s = 0; s < o.length; s++) {
458
+ const i = o[s], d = i[0] === "[", c = t.has(i);
459
+ d || c ? (n.length > 0 && (n.sort(), r.push(...n), n = []), r.push(i)) : n.push(i);
460
+ }
461
+ return n.length > 0 && (n.sort(), r.push(...n)), r;
462
+ };
463
+ }, xo = (e) => ({
464
+ cache: go(e.cacheSize),
465
+ parseClassName: ho(e),
466
+ sortModifiers: bo(e),
467
+ postfixLookupClassGroupIds: yo(e),
468
+ ...no(e)
469
+ }), yo = (e) => {
470
+ const t = /* @__PURE__ */ Object.create(null), o = e.postfixLookupClassGroups;
471
+ if (o)
472
+ for (let r = 0; r < o.length; r++)
473
+ t[o[r]] = !0;
474
+ return t;
475
+ }, wo = /\s+/, ko = (e, t) => {
476
+ const {
477
+ parseClassName: o,
478
+ getClassGroupId: r,
479
+ getConflictingClassGroupIds: n,
480
+ sortModifiers: s,
481
+ postfixLookupClassGroupIds: i
482
+ } = t, d = [], c = e.trim().split(wo);
483
+ let l = "";
484
+ for (let f = c.length - 1; f >= 0; f -= 1) {
485
+ const b = c[f], {
486
+ isExternal: w,
487
+ modifiers: C,
488
+ hasImportantModifier: P,
489
+ baseClassName: v,
490
+ maybePostfixModifierPosition: M
491
+ } = o(b);
492
+ if (w) {
493
+ l = b + (l.length > 0 ? " " + l : l);
494
+ continue;
495
+ }
496
+ let z = !!M, h;
497
+ if (z) {
498
+ const A = v.substring(0, M);
499
+ h = r(A);
500
+ const p = h && i[h] ? r(v) : void 0;
501
+ p && p !== h && (h = p, z = !1);
502
+ } else
503
+ h = r(v);
504
+ if (!h) {
505
+ if (!z) {
506
+ l = b + (l.length > 0 ? " " + l : l);
507
+ continue;
508
+ }
509
+ if (h = r(v), !h) {
510
+ l = b + (l.length > 0 ? " " + l : l);
511
+ continue;
512
+ }
513
+ z = !1;
514
+ }
515
+ const T = C.length === 0 ? "" : C.length === 1 ? C[0] : s(C).join(":"), O = P ? T + Ie : T, E = O + h;
516
+ if (d.indexOf(E) > -1)
517
+ continue;
518
+ d.push(E);
519
+ const j = n(h, z);
520
+ for (let A = 0; A < j.length; ++A) {
521
+ const p = j[A];
522
+ d.push(O + p);
523
+ }
524
+ l = b + (l.length > 0 ? " " + l : l);
525
+ }
526
+ return l;
527
+ }, vo = (...e) => {
528
+ let t = 0, o, r, n = "";
529
+ for (; t < e.length; )
530
+ (o = e[t++]) && (r = xt(o)) && (n && (n += " "), n += r);
531
+ return n;
532
+ }, xt = (e) => {
533
+ if (typeof e == "string")
534
+ return e;
535
+ let t, o = "";
536
+ for (let r = 0; r < e.length; r++)
537
+ e[r] && (t = xt(e[r])) && (o && (o += " "), o += t);
538
+ return o;
539
+ }, No = (e, ...t) => {
540
+ let o, r, n, s;
541
+ const i = (c) => {
542
+ const l = t.reduce((f, b) => b(f), e());
543
+ return o = xo(l), r = o.cache.get, n = o.cache.set, s = d, d(c);
544
+ }, d = (c) => {
545
+ const l = r(c);
546
+ if (l)
547
+ return l;
548
+ const f = ko(c, o);
549
+ return n(c, f), f;
550
+ };
551
+ return s = i, (...c) => s(vo(...c));
552
+ }, Co = [], $ = (e) => {
553
+ const t = (o) => o[e] || Co;
554
+ return t.isThemeGetter = !0, t.themeKey = e, t;
555
+ }, yt = /^\[(?:(\w[\w-]*):)?(.+)\]$/i, wt = /^\((?:(\w[\w-]*):)?(.+)\)$/i, So = /^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/, Ro = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, Ao = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, _o = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix|color|light-dark)\(.+\)$/, zo = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, To = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, se = (e) => So.test(e), y = (e) => !!e && !Number.isNaN(Number(e)), X = (e) => !!e && Number.isInteger(Number(e)), Le = (e) => e.endsWith("%") && y(e.slice(0, -1)), te = (e) => Ro.test(e), kt = () => !0, Lo = (e) => (
556
+ // `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.
557
+ // For example, `hsl(0 0% 0%)` would be classified as a length without this check.
558
+ // I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
559
+ Ao.test(e) && !_o.test(e)
560
+ ), De = () => !1, Io = (e) => zo.test(e), Po = (e) => To.test(e), Mo = (e) => !u(e) && !m(e), Eo = (e) => e.startsWith("@container") && (e[10] === "/" && e[11] !== void 0 || e[11] === "s" && e[16] !== void 0 && e.startsWith("-size/", 10) || e[11] === "n" && e[18] !== void 0 && e.startsWith("-normal/", 10)), Fo = (e) => ae(e, Ct, De), u = (e) => yt.test(e), le = (e) => ae(e, St, Lo), Ye = (e) => ae(e, qo, y), Do = (e) => ae(e, At, kt), Oo = (e) => ae(e, Rt, De), Je = (e) => ae(e, vt, De), $o = (e) => ae(e, Nt, Po), ve = (e) => ae(e, _t, Io), m = (e) => wt.test(e), ye = (e) => de(e, St), Go = (e) => de(e, Rt), Ze = (e) => de(e, vt), Ho = (e) => de(e, Ct), Vo = (e) => de(e, Nt), Ne = (e) => de(e, _t, !0), jo = (e) => de(e, At, !0), ae = (e, t, o) => {
561
+ const r = yt.exec(e);
562
+ return r ? r[1] ? t(r[1]) : o(r[2]) : !1;
563
+ }, de = (e, t, o = !1) => {
564
+ const r = wt.exec(e);
565
+ return r ? r[1] ? t(r[1]) : o : !1;
566
+ }, vt = (e) => e === "position" || e === "percentage", Nt = (e) => e === "image" || e === "url", Ct = (e) => e === "length" || e === "size" || e === "bg-size", St = (e) => e === "length", qo = (e) => e === "number", Rt = (e) => e === "family-name", At = (e) => e === "number" || e === "weight", _t = (e) => e === "shadow", Uo = () => {
567
+ const e = $("color"), t = $("font"), o = $("text"), r = $("font-weight"), n = $("tracking"), s = $("leading"), i = $("breakpoint"), d = $("container"), c = $("spacing"), l = $("radius"), f = $("shadow"), b = $("inset-shadow"), w = $("text-shadow"), C = $("drop-shadow"), P = $("blur"), v = $("perspective"), M = $("aspect"), z = $("ease"), h = $("animate"), T = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], O = () => [
568
+ "center",
569
+ "top",
570
+ "bottom",
571
+ "left",
572
+ "right",
573
+ "top-left",
574
+ // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
575
+ "left-top",
576
+ "top-right",
577
+ // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
578
+ "right-top",
579
+ "bottom-right",
580
+ // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
581
+ "right-bottom",
582
+ "bottom-left",
583
+ // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
584
+ "left-bottom"
585
+ ], E = () => [...O(), m, u], j = () => ["auto", "hidden", "clip", "visible", "scroll"], A = () => ["auto", "contain", "none"], p = () => [m, u, c], L = () => [se, "full", "auto", ...p()], U = () => [X, "none", "subgrid", m, u], B = () => ["auto", {
586
+ span: ["full", X, m, u]
587
+ }, X, m, u], J = () => [X, "auto", m, u], K = () => ["auto", "min", "max", "fr", m, u], x = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"], _ = () => ["start", "end", "center", "stretch", "center-safe", "end-safe"], F = () => ["auto", ...p()], W = () => [se, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...p()], Z = () => [d, se, "screen", "full", "dvw", "lvw", "svw", "min", "max", "fit", ...p()], ue = () => [se, "screen", "full", "lh", "dvh", "lvh", "svh", "min", "max", "fit", ...p()], g = () => [e, m, u], he = () => [...O(), Ze, Je, {
588
+ position: [m, u]
589
+ }], ke = () => ["no-repeat", {
590
+ repeat: ["", "x", "y", "space", "round"]
591
+ }], k = () => ["auto", "cover", "contain", Ho, Fo, {
592
+ size: [m, u]
593
+ }], S = () => [Le, ye, le], N = () => [
594
+ // Deprecated since Tailwind CSS v4.0.0
595
+ "",
596
+ "none",
597
+ "full",
598
+ l,
599
+ m,
600
+ u
601
+ ], D = () => ["", y, ye, le], re = () => ["solid", "dashed", "dotted", "double"], be = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], I = () => [y, Le, Ze, Je], xe = () => [
602
+ // Deprecated since Tailwind CSS v4.0.0
603
+ "",
604
+ "none",
605
+ P,
606
+ m,
607
+ u
608
+ ], me = () => ["none", y, m, u], ne = () => ["none", y, m, u], pe = () => [y, m, u], ee = () => [se, "full", ...p()];
609
+ return {
610
+ cacheSize: 500,
611
+ theme: {
612
+ animate: ["spin", "ping", "pulse", "bounce"],
613
+ aspect: ["video"],
614
+ blur: [te],
615
+ breakpoint: [te],
616
+ color: [kt],
617
+ container: [te],
618
+ "drop-shadow": [te],
619
+ ease: ["in", "out", "in-out"],
620
+ font: [Mo],
621
+ "font-weight": ["thin", "extralight", "light", "normal", "medium", "semibold", "bold", "extrabold", "black"],
622
+ "inset-shadow": [te],
623
+ leading: ["none", "tight", "snug", "normal", "relaxed", "loose"],
624
+ perspective: ["dramatic", "near", "normal", "midrange", "distant", "none"],
625
+ radius: [te],
626
+ shadow: [te],
627
+ spacing: ["px", y],
628
+ text: [te],
629
+ "text-shadow": [te],
630
+ tracking: ["tighter", "tight", "normal", "wide", "wider", "widest"]
631
+ },
632
+ classGroups: {
633
+ // --------------
634
+ // --- Layout ---
635
+ // --------------
636
+ /**
637
+ * Aspect Ratio
638
+ * @see https://tailwindcss.com/docs/aspect-ratio
639
+ */
640
+ aspect: [{
641
+ aspect: ["auto", "square", se, u, m, M]
642
+ }],
643
+ /**
644
+ * Container
645
+ * @see https://tailwindcss.com/docs/container
646
+ * @deprecated since Tailwind CSS v4.0.0
647
+ */
648
+ container: ["container"],
649
+ /**
650
+ * Container Type
651
+ * @see https://tailwindcss.com/docs/responsive-design#container-queries
652
+ */
653
+ "container-type": [{
654
+ "@container": ["", "normal", "size", m, u]
655
+ }],
656
+ /**
657
+ * Container Name
658
+ * @see https://tailwindcss.com/docs/responsive-design#named-containers
659
+ */
660
+ "container-named": [Eo],
661
+ /**
662
+ * Columns
663
+ * @see https://tailwindcss.com/docs/columns
664
+ */
665
+ columns: [{
666
+ columns: [y, "auto", u, m, d]
667
+ }],
668
+ /**
669
+ * Break After
670
+ * @see https://tailwindcss.com/docs/break-after
671
+ */
672
+ "break-after": [{
673
+ "break-after": T()
674
+ }],
675
+ /**
676
+ * Break Before
677
+ * @see https://tailwindcss.com/docs/break-before
678
+ */
679
+ "break-before": [{
680
+ "break-before": T()
681
+ }],
682
+ /**
683
+ * Break Inside
684
+ * @see https://tailwindcss.com/docs/break-inside
685
+ */
686
+ "break-inside": [{
687
+ "break-inside": ["auto", "avoid", "avoid-page", "avoid-column"]
688
+ }],
689
+ /**
690
+ * Box Decoration Break
691
+ * @see https://tailwindcss.com/docs/box-decoration-break
692
+ */
693
+ "box-decoration": [{
694
+ "box-decoration": ["slice", "clone"]
695
+ }],
696
+ /**
697
+ * Box Sizing
698
+ * @see https://tailwindcss.com/docs/box-sizing
699
+ */
700
+ box: [{
701
+ box: ["border", "content"]
702
+ }],
703
+ /**
704
+ * Display
705
+ * @see https://tailwindcss.com/docs/display
706
+ */
707
+ display: ["block", "inline-block", "inline", "flex", "inline-flex", "table", "inline-table", "table-caption", "table-cell", "table-column", "table-column-group", "table-footer-group", "table-header-group", "table-row-group", "table-row", "flow-root", "grid", "inline-grid", "contents", "list-item", "hidden"],
708
+ /**
709
+ * Screen Reader Only
710
+ * @see https://tailwindcss.com/docs/display#screen-reader-only
711
+ */
712
+ sr: ["sr-only", "not-sr-only"],
713
+ /**
714
+ * Floats
715
+ * @see https://tailwindcss.com/docs/float
716
+ */
717
+ float: [{
718
+ float: ["right", "left", "none", "start", "end"]
719
+ }],
720
+ /**
721
+ * Clear
722
+ * @see https://tailwindcss.com/docs/clear
723
+ */
724
+ clear: [{
725
+ clear: ["left", "right", "both", "none", "start", "end"]
726
+ }],
727
+ /**
728
+ * Isolation
729
+ * @see https://tailwindcss.com/docs/isolation
730
+ */
731
+ isolation: ["isolate", "isolation-auto"],
732
+ /**
733
+ * Object Fit
734
+ * @see https://tailwindcss.com/docs/object-fit
735
+ */
736
+ "object-fit": [{
737
+ object: ["contain", "cover", "fill", "none", "scale-down"]
738
+ }],
739
+ /**
740
+ * Object Position
741
+ * @see https://tailwindcss.com/docs/object-position
742
+ */
743
+ "object-position": [{
744
+ object: E()
745
+ }],
746
+ /**
747
+ * Overflow
748
+ * @see https://tailwindcss.com/docs/overflow
749
+ */
750
+ overflow: [{
751
+ overflow: j()
752
+ }],
753
+ /**
754
+ * Overflow X
755
+ * @see https://tailwindcss.com/docs/overflow
756
+ */
757
+ "overflow-x": [{
758
+ "overflow-x": j()
759
+ }],
760
+ /**
761
+ * Overflow Y
762
+ * @see https://tailwindcss.com/docs/overflow
763
+ */
764
+ "overflow-y": [{
765
+ "overflow-y": j()
766
+ }],
767
+ /**
768
+ * Overscroll Behavior
769
+ * @see https://tailwindcss.com/docs/overscroll-behavior
770
+ */
771
+ overscroll: [{
772
+ overscroll: A()
773
+ }],
774
+ /**
775
+ * Overscroll Behavior X
776
+ * @see https://tailwindcss.com/docs/overscroll-behavior
777
+ */
778
+ "overscroll-x": [{
779
+ "overscroll-x": A()
780
+ }],
781
+ /**
782
+ * Overscroll Behavior Y
783
+ * @see https://tailwindcss.com/docs/overscroll-behavior
784
+ */
785
+ "overscroll-y": [{
786
+ "overscroll-y": A()
787
+ }],
788
+ /**
789
+ * Position
790
+ * @see https://tailwindcss.com/docs/position
791
+ */
792
+ position: ["static", "fixed", "absolute", "relative", "sticky"],
793
+ /**
794
+ * Inset
795
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
796
+ */
797
+ inset: [{
798
+ inset: L()
799
+ }],
800
+ /**
801
+ * Inset Inline
802
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
803
+ */
804
+ "inset-x": [{
805
+ "inset-x": L()
806
+ }],
807
+ /**
808
+ * Inset Block
809
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
810
+ */
811
+ "inset-y": [{
812
+ "inset-y": L()
813
+ }],
814
+ /**
815
+ * Inset Inline Start
816
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
817
+ * @todo class group will be renamed to `inset-s` in next major release
818
+ */
819
+ start: [{
820
+ "inset-s": L(),
821
+ /**
822
+ * @deprecated since Tailwind CSS v4.2.0 in favor of `inset-s-*` utilities.
823
+ * @see https://github.com/tailwindlabs/tailwindcss/pull/19613
824
+ */
825
+ start: L()
826
+ }],
827
+ /**
828
+ * Inset Inline End
829
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
830
+ * @todo class group will be renamed to `inset-e` in next major release
831
+ */
832
+ end: [{
833
+ "inset-e": L(),
834
+ /**
835
+ * @deprecated since Tailwind CSS v4.2.0 in favor of `inset-e-*` utilities.
836
+ * @see https://github.com/tailwindlabs/tailwindcss/pull/19613
837
+ */
838
+ end: L()
839
+ }],
840
+ /**
841
+ * Inset Block Start
842
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
843
+ */
844
+ "inset-bs": [{
845
+ "inset-bs": L()
846
+ }],
847
+ /**
848
+ * Inset Block End
849
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
850
+ */
851
+ "inset-be": [{
852
+ "inset-be": L()
853
+ }],
854
+ /**
855
+ * Top
856
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
857
+ */
858
+ top: [{
859
+ top: L()
860
+ }],
861
+ /**
862
+ * Right
863
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
864
+ */
865
+ right: [{
866
+ right: L()
867
+ }],
868
+ /**
869
+ * Bottom
870
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
871
+ */
872
+ bottom: [{
873
+ bottom: L()
874
+ }],
875
+ /**
876
+ * Left
877
+ * @see https://tailwindcss.com/docs/top-right-bottom-left
878
+ */
879
+ left: [{
880
+ left: L()
881
+ }],
882
+ /**
883
+ * Visibility
884
+ * @see https://tailwindcss.com/docs/visibility
885
+ */
886
+ visibility: ["visible", "invisible", "collapse"],
887
+ /**
888
+ * Z-Index
889
+ * @see https://tailwindcss.com/docs/z-index
890
+ */
891
+ z: [{
892
+ z: [X, "auto", m, u]
893
+ }],
894
+ // ------------------------
895
+ // --- Flexbox and Grid ---
896
+ // ------------------------
897
+ /**
898
+ * Flex Basis
899
+ * @see https://tailwindcss.com/docs/flex-basis
900
+ */
901
+ basis: [{
902
+ basis: [se, "full", "auto", d, ...p()]
903
+ }],
904
+ /**
905
+ * Flex Direction
906
+ * @see https://tailwindcss.com/docs/flex-direction
907
+ */
908
+ "flex-direction": [{
909
+ flex: ["row", "row-reverse", "col", "col-reverse"]
910
+ }],
911
+ /**
912
+ * Flex Wrap
913
+ * @see https://tailwindcss.com/docs/flex-wrap
914
+ */
915
+ "flex-wrap": [{
916
+ flex: ["nowrap", "wrap", "wrap-reverse"]
917
+ }],
918
+ /**
919
+ * Flex
920
+ * @see https://tailwindcss.com/docs/flex
921
+ */
922
+ flex: [{
923
+ flex: [y, se, "auto", "initial", "none", u]
924
+ }],
925
+ /**
926
+ * Flex Grow
927
+ * @see https://tailwindcss.com/docs/flex-grow
928
+ */
929
+ grow: [{
930
+ grow: ["", y, m, u]
931
+ }],
932
+ /**
933
+ * Flex Shrink
934
+ * @see https://tailwindcss.com/docs/flex-shrink
935
+ */
936
+ shrink: [{
937
+ shrink: ["", y, m, u]
938
+ }],
939
+ /**
940
+ * Order
941
+ * @see https://tailwindcss.com/docs/order
942
+ */
943
+ order: [{
944
+ order: [X, "first", "last", "none", m, u]
945
+ }],
946
+ /**
947
+ * Grid Template Columns
948
+ * @see https://tailwindcss.com/docs/grid-template-columns
949
+ */
950
+ "grid-cols": [{
951
+ "grid-cols": U()
952
+ }],
953
+ /**
954
+ * Grid Column Start / End
955
+ * @see https://tailwindcss.com/docs/grid-column
956
+ */
957
+ "col-start-end": [{
958
+ col: B()
959
+ }],
960
+ /**
961
+ * Grid Column Start
962
+ * @see https://tailwindcss.com/docs/grid-column
963
+ */
964
+ "col-start": [{
965
+ "col-start": J()
966
+ }],
967
+ /**
968
+ * Grid Column End
969
+ * @see https://tailwindcss.com/docs/grid-column
970
+ */
971
+ "col-end": [{
972
+ "col-end": J()
973
+ }],
974
+ /**
975
+ * Grid Template Rows
976
+ * @see https://tailwindcss.com/docs/grid-template-rows
977
+ */
978
+ "grid-rows": [{
979
+ "grid-rows": U()
980
+ }],
981
+ /**
982
+ * Grid Row Start / End
983
+ * @see https://tailwindcss.com/docs/grid-row
984
+ */
985
+ "row-start-end": [{
986
+ row: B()
987
+ }],
988
+ /**
989
+ * Grid Row Start
990
+ * @see https://tailwindcss.com/docs/grid-row
991
+ */
992
+ "row-start": [{
993
+ "row-start": J()
994
+ }],
995
+ /**
996
+ * Grid Row End
997
+ * @see https://tailwindcss.com/docs/grid-row
998
+ */
999
+ "row-end": [{
1000
+ "row-end": J()
1001
+ }],
1002
+ /**
1003
+ * Grid Auto Flow
1004
+ * @see https://tailwindcss.com/docs/grid-auto-flow
1005
+ */
1006
+ "grid-flow": [{
1007
+ "grid-flow": ["row", "col", "dense", "row-dense", "col-dense"]
1008
+ }],
1009
+ /**
1010
+ * Grid Auto Columns
1011
+ * @see https://tailwindcss.com/docs/grid-auto-columns
1012
+ */
1013
+ "auto-cols": [{
1014
+ "auto-cols": K()
1015
+ }],
1016
+ /**
1017
+ * Grid Auto Rows
1018
+ * @see https://tailwindcss.com/docs/grid-auto-rows
1019
+ */
1020
+ "auto-rows": [{
1021
+ "auto-rows": K()
1022
+ }],
1023
+ /**
1024
+ * Gap
1025
+ * @see https://tailwindcss.com/docs/gap
1026
+ */
1027
+ gap: [{
1028
+ gap: p()
1029
+ }],
1030
+ /**
1031
+ * Gap X
1032
+ * @see https://tailwindcss.com/docs/gap
1033
+ */
1034
+ "gap-x": [{
1035
+ "gap-x": p()
1036
+ }],
1037
+ /**
1038
+ * Gap Y
1039
+ * @see https://tailwindcss.com/docs/gap
1040
+ */
1041
+ "gap-y": [{
1042
+ "gap-y": p()
1043
+ }],
1044
+ /**
1045
+ * Justify Content
1046
+ * @see https://tailwindcss.com/docs/justify-content
1047
+ */
1048
+ "justify-content": [{
1049
+ justify: [...x(), "normal"]
1050
+ }],
1051
+ /**
1052
+ * Justify Items
1053
+ * @see https://tailwindcss.com/docs/justify-items
1054
+ */
1055
+ "justify-items": [{
1056
+ "justify-items": [..._(), "normal"]
1057
+ }],
1058
+ /**
1059
+ * Justify Self
1060
+ * @see https://tailwindcss.com/docs/justify-self
1061
+ */
1062
+ "justify-self": [{
1063
+ "justify-self": ["auto", ..._()]
1064
+ }],
1065
+ /**
1066
+ * Align Content
1067
+ * @see https://tailwindcss.com/docs/align-content
1068
+ */
1069
+ "align-content": [{
1070
+ content: ["normal", ...x()]
1071
+ }],
1072
+ /**
1073
+ * Align Items
1074
+ * @see https://tailwindcss.com/docs/align-items
1075
+ */
1076
+ "align-items": [{
1077
+ items: [..._(), {
1078
+ baseline: ["", "last"]
1079
+ }]
1080
+ }],
1081
+ /**
1082
+ * Align Self
1083
+ * @see https://tailwindcss.com/docs/align-self
1084
+ */
1085
+ "align-self": [{
1086
+ self: ["auto", ..._(), {
1087
+ baseline: ["", "last"]
1088
+ }]
1089
+ }],
1090
+ /**
1091
+ * Place Content
1092
+ * @see https://tailwindcss.com/docs/place-content
1093
+ */
1094
+ "place-content": [{
1095
+ "place-content": x()
1096
+ }],
1097
+ /**
1098
+ * Place Items
1099
+ * @see https://tailwindcss.com/docs/place-items
1100
+ */
1101
+ "place-items": [{
1102
+ "place-items": [..._(), "baseline"]
1103
+ }],
1104
+ /**
1105
+ * Place Self
1106
+ * @see https://tailwindcss.com/docs/place-self
1107
+ */
1108
+ "place-self": [{
1109
+ "place-self": ["auto", ..._()]
1110
+ }],
1111
+ // Spacing
1112
+ /**
1113
+ * Padding
1114
+ * @see https://tailwindcss.com/docs/padding
1115
+ */
1116
+ p: [{
1117
+ p: p()
1118
+ }],
1119
+ /**
1120
+ * Padding Inline
1121
+ * @see https://tailwindcss.com/docs/padding
1122
+ */
1123
+ px: [{
1124
+ px: p()
1125
+ }],
1126
+ /**
1127
+ * Padding Block
1128
+ * @see https://tailwindcss.com/docs/padding
1129
+ */
1130
+ py: [{
1131
+ py: p()
1132
+ }],
1133
+ /**
1134
+ * Padding Inline Start
1135
+ * @see https://tailwindcss.com/docs/padding
1136
+ */
1137
+ ps: [{
1138
+ ps: p()
1139
+ }],
1140
+ /**
1141
+ * Padding Inline End
1142
+ * @see https://tailwindcss.com/docs/padding
1143
+ */
1144
+ pe: [{
1145
+ pe: p()
1146
+ }],
1147
+ /**
1148
+ * Padding Block Start
1149
+ * @see https://tailwindcss.com/docs/padding
1150
+ */
1151
+ pbs: [{
1152
+ pbs: p()
1153
+ }],
1154
+ /**
1155
+ * Padding Block End
1156
+ * @see https://tailwindcss.com/docs/padding
1157
+ */
1158
+ pbe: [{
1159
+ pbe: p()
1160
+ }],
1161
+ /**
1162
+ * Padding Top
1163
+ * @see https://tailwindcss.com/docs/padding
1164
+ */
1165
+ pt: [{
1166
+ pt: p()
1167
+ }],
1168
+ /**
1169
+ * Padding Right
1170
+ * @see https://tailwindcss.com/docs/padding
1171
+ */
1172
+ pr: [{
1173
+ pr: p()
1174
+ }],
1175
+ /**
1176
+ * Padding Bottom
1177
+ * @see https://tailwindcss.com/docs/padding
1178
+ */
1179
+ pb: [{
1180
+ pb: p()
1181
+ }],
1182
+ /**
1183
+ * Padding Left
1184
+ * @see https://tailwindcss.com/docs/padding
1185
+ */
1186
+ pl: [{
1187
+ pl: p()
1188
+ }],
1189
+ /**
1190
+ * Margin
1191
+ * @see https://tailwindcss.com/docs/margin
1192
+ */
1193
+ m: [{
1194
+ m: F()
1195
+ }],
1196
+ /**
1197
+ * Margin Inline
1198
+ * @see https://tailwindcss.com/docs/margin
1199
+ */
1200
+ mx: [{
1201
+ mx: F()
1202
+ }],
1203
+ /**
1204
+ * Margin Block
1205
+ * @see https://tailwindcss.com/docs/margin
1206
+ */
1207
+ my: [{
1208
+ my: F()
1209
+ }],
1210
+ /**
1211
+ * Margin Inline Start
1212
+ * @see https://tailwindcss.com/docs/margin
1213
+ */
1214
+ ms: [{
1215
+ ms: F()
1216
+ }],
1217
+ /**
1218
+ * Margin Inline End
1219
+ * @see https://tailwindcss.com/docs/margin
1220
+ */
1221
+ me: [{
1222
+ me: F()
1223
+ }],
1224
+ /**
1225
+ * Margin Block Start
1226
+ * @see https://tailwindcss.com/docs/margin
1227
+ */
1228
+ mbs: [{
1229
+ mbs: F()
1230
+ }],
1231
+ /**
1232
+ * Margin Block End
1233
+ * @see https://tailwindcss.com/docs/margin
1234
+ */
1235
+ mbe: [{
1236
+ mbe: F()
1237
+ }],
1238
+ /**
1239
+ * Margin Top
1240
+ * @see https://tailwindcss.com/docs/margin
1241
+ */
1242
+ mt: [{
1243
+ mt: F()
1244
+ }],
1245
+ /**
1246
+ * Margin Right
1247
+ * @see https://tailwindcss.com/docs/margin
1248
+ */
1249
+ mr: [{
1250
+ mr: F()
1251
+ }],
1252
+ /**
1253
+ * Margin Bottom
1254
+ * @see https://tailwindcss.com/docs/margin
1255
+ */
1256
+ mb: [{
1257
+ mb: F()
1258
+ }],
1259
+ /**
1260
+ * Margin Left
1261
+ * @see https://tailwindcss.com/docs/margin
1262
+ */
1263
+ ml: [{
1264
+ ml: F()
1265
+ }],
1266
+ /**
1267
+ * Space Between X
1268
+ * @see https://tailwindcss.com/docs/margin#adding-space-between-children
1269
+ */
1270
+ "space-x": [{
1271
+ "space-x": p()
1272
+ }],
1273
+ /**
1274
+ * Space Between X Reverse
1275
+ * @see https://tailwindcss.com/docs/margin#adding-space-between-children
1276
+ */
1277
+ "space-x-reverse": ["space-x-reverse"],
1278
+ /**
1279
+ * Space Between Y
1280
+ * @see https://tailwindcss.com/docs/margin#adding-space-between-children
1281
+ */
1282
+ "space-y": [{
1283
+ "space-y": p()
1284
+ }],
1285
+ /**
1286
+ * Space Between Y Reverse
1287
+ * @see https://tailwindcss.com/docs/margin#adding-space-between-children
1288
+ */
1289
+ "space-y-reverse": ["space-y-reverse"],
1290
+ // --------------
1291
+ // --- Sizing ---
1292
+ // --------------
1293
+ /**
1294
+ * Size
1295
+ * @see https://tailwindcss.com/docs/width#setting-both-width-and-height
1296
+ */
1297
+ size: [{
1298
+ size: W()
1299
+ }],
1300
+ /**
1301
+ * Inline Size
1302
+ * @see https://tailwindcss.com/docs/inline-size
1303
+ */
1304
+ "inline-size": [{
1305
+ inline: ["auto", ...Z()]
1306
+ }],
1307
+ /**
1308
+ * Min-Inline Size
1309
+ * @see https://tailwindcss.com/docs/min-inline-size
1310
+ */
1311
+ "min-inline-size": [{
1312
+ "min-inline": ["auto", ...Z()]
1313
+ }],
1314
+ /**
1315
+ * Max-Inline Size
1316
+ * @see https://tailwindcss.com/docs/max-inline-size
1317
+ */
1318
+ "max-inline-size": [{
1319
+ "max-inline": ["none", ...Z()]
1320
+ }],
1321
+ /**
1322
+ * Block Size
1323
+ * @see https://tailwindcss.com/docs/block-size
1324
+ */
1325
+ "block-size": [{
1326
+ block: ["auto", ...ue()]
1327
+ }],
1328
+ /**
1329
+ * Min-Block Size
1330
+ * @see https://tailwindcss.com/docs/min-block-size
1331
+ */
1332
+ "min-block-size": [{
1333
+ "min-block": ["auto", ...ue()]
1334
+ }],
1335
+ /**
1336
+ * Max-Block Size
1337
+ * @see https://tailwindcss.com/docs/max-block-size
1338
+ */
1339
+ "max-block-size": [{
1340
+ "max-block": ["none", ...ue()]
1341
+ }],
1342
+ /**
1343
+ * Width
1344
+ * @see https://tailwindcss.com/docs/width
1345
+ */
1346
+ w: [{
1347
+ w: [d, "screen", ...W()]
1348
+ }],
1349
+ /**
1350
+ * Min-Width
1351
+ * @see https://tailwindcss.com/docs/min-width
1352
+ */
1353
+ "min-w": [{
1354
+ "min-w": [
1355
+ d,
1356
+ "screen",
1357
+ /** Deprecated. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
1358
+ "none",
1359
+ ...W()
1360
+ ]
1361
+ }],
1362
+ /**
1363
+ * Max-Width
1364
+ * @see https://tailwindcss.com/docs/max-width
1365
+ */
1366
+ "max-w": [{
1367
+ "max-w": [
1368
+ d,
1369
+ "screen",
1370
+ "none",
1371
+ /** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
1372
+ "prose",
1373
+ /** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
1374
+ {
1375
+ screen: [i]
1376
+ },
1377
+ ...W()
1378
+ ]
1379
+ }],
1380
+ /**
1381
+ * Height
1382
+ * @see https://tailwindcss.com/docs/height
1383
+ */
1384
+ h: [{
1385
+ h: ["screen", "lh", ...W()]
1386
+ }],
1387
+ /**
1388
+ * Min-Height
1389
+ * @see https://tailwindcss.com/docs/min-height
1390
+ */
1391
+ "min-h": [{
1392
+ "min-h": ["screen", "lh", "none", ...W()]
1393
+ }],
1394
+ /**
1395
+ * Max-Height
1396
+ * @see https://tailwindcss.com/docs/max-height
1397
+ */
1398
+ "max-h": [{
1399
+ "max-h": ["screen", "lh", "none", ...W()]
1400
+ }],
1401
+ // ------------------
1402
+ // --- Typography ---
1403
+ // ------------------
1404
+ /**
1405
+ * Font Size
1406
+ * @see https://tailwindcss.com/docs/font-size
1407
+ */
1408
+ "font-size": [{
1409
+ text: ["base", o, ye, le]
1410
+ }],
1411
+ /**
1412
+ * Font Smoothing
1413
+ * @see https://tailwindcss.com/docs/font-smoothing
1414
+ */
1415
+ "font-smoothing": ["antialiased", "subpixel-antialiased"],
1416
+ /**
1417
+ * Font Style
1418
+ * @see https://tailwindcss.com/docs/font-style
1419
+ */
1420
+ "font-style": ["italic", "not-italic"],
1421
+ /**
1422
+ * Font Weight
1423
+ * @see https://tailwindcss.com/docs/font-weight
1424
+ */
1425
+ "font-weight": [{
1426
+ font: [r, jo, Do]
1427
+ }],
1428
+ /**
1429
+ * Font Stretch
1430
+ * @see https://tailwindcss.com/docs/font-stretch
1431
+ */
1432
+ "font-stretch": [{
1433
+ "font-stretch": ["ultra-condensed", "extra-condensed", "condensed", "semi-condensed", "normal", "semi-expanded", "expanded", "extra-expanded", "ultra-expanded", Le, u]
1434
+ }],
1435
+ /**
1436
+ * Font Family
1437
+ * @see https://tailwindcss.com/docs/font-family
1438
+ */
1439
+ "font-family": [{
1440
+ font: [Go, Oo, t]
1441
+ }],
1442
+ /**
1443
+ * Font Feature Settings
1444
+ * @see https://tailwindcss.com/docs/font-feature-settings
1445
+ */
1446
+ "font-features": [{
1447
+ "font-features": [u]
1448
+ }],
1449
+ /**
1450
+ * Font Variant Numeric
1451
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1452
+ */
1453
+ "fvn-normal": ["normal-nums"],
1454
+ /**
1455
+ * Font Variant Numeric
1456
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1457
+ */
1458
+ "fvn-ordinal": ["ordinal"],
1459
+ /**
1460
+ * Font Variant Numeric
1461
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1462
+ */
1463
+ "fvn-slashed-zero": ["slashed-zero"],
1464
+ /**
1465
+ * Font Variant Numeric
1466
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1467
+ */
1468
+ "fvn-figure": ["lining-nums", "oldstyle-nums"],
1469
+ /**
1470
+ * Font Variant Numeric
1471
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1472
+ */
1473
+ "fvn-spacing": ["proportional-nums", "tabular-nums"],
1474
+ /**
1475
+ * Font Variant Numeric
1476
+ * @see https://tailwindcss.com/docs/font-variant-numeric
1477
+ */
1478
+ "fvn-fraction": ["diagonal-fractions", "stacked-fractions"],
1479
+ /**
1480
+ * Letter Spacing
1481
+ * @see https://tailwindcss.com/docs/letter-spacing
1482
+ */
1483
+ tracking: [{
1484
+ tracking: [n, m, u]
1485
+ }],
1486
+ /**
1487
+ * Line Clamp
1488
+ * @see https://tailwindcss.com/docs/line-clamp
1489
+ */
1490
+ "line-clamp": [{
1491
+ "line-clamp": [y, "none", m, Ye]
1492
+ }],
1493
+ /**
1494
+ * Line Height
1495
+ * @see https://tailwindcss.com/docs/line-height
1496
+ */
1497
+ leading: [{
1498
+ leading: [
1499
+ "none",
1500
+ /** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */
1501
+ s,
1502
+ ...p()
1503
+ ]
1504
+ }],
1505
+ /**
1506
+ * List Style Image
1507
+ * @see https://tailwindcss.com/docs/list-style-image
1508
+ */
1509
+ "list-image": [{
1510
+ "list-image": ["none", m, u]
1511
+ }],
1512
+ /**
1513
+ * List Style Position
1514
+ * @see https://tailwindcss.com/docs/list-style-position
1515
+ */
1516
+ "list-style-position": [{
1517
+ list: ["inside", "outside"]
1518
+ }],
1519
+ /**
1520
+ * List Style Type
1521
+ * @see https://tailwindcss.com/docs/list-style-type
1522
+ */
1523
+ "list-style-type": [{
1524
+ list: ["disc", "decimal", "none", m, u]
1525
+ }],
1526
+ /**
1527
+ * Text Alignment
1528
+ * @see https://tailwindcss.com/docs/text-align
1529
+ */
1530
+ "text-alignment": [{
1531
+ text: ["left", "center", "right", "justify", "start", "end"]
1532
+ }],
1533
+ /**
1534
+ * Placeholder Color
1535
+ * @deprecated since Tailwind CSS v3.0.0
1536
+ * @see https://v3.tailwindcss.com/docs/placeholder-color
1537
+ */
1538
+ "placeholder-color": [{
1539
+ placeholder: g()
1540
+ }],
1541
+ /**
1542
+ * Text Color
1543
+ * @see https://tailwindcss.com/docs/text-color
1544
+ */
1545
+ "text-color": [{
1546
+ text: g()
1547
+ }],
1548
+ /**
1549
+ * Text Decoration
1550
+ * @see https://tailwindcss.com/docs/text-decoration
1551
+ */
1552
+ "text-decoration": ["underline", "overline", "line-through", "no-underline"],
1553
+ /**
1554
+ * Text Decoration Style
1555
+ * @see https://tailwindcss.com/docs/text-decoration-style
1556
+ */
1557
+ "text-decoration-style": [{
1558
+ decoration: [...re(), "wavy"]
1559
+ }],
1560
+ /**
1561
+ * Text Decoration Thickness
1562
+ * @see https://tailwindcss.com/docs/text-decoration-thickness
1563
+ */
1564
+ "text-decoration-thickness": [{
1565
+ decoration: [y, "from-font", "auto", m, le]
1566
+ }],
1567
+ /**
1568
+ * Text Decoration Color
1569
+ * @see https://tailwindcss.com/docs/text-decoration-color
1570
+ */
1571
+ "text-decoration-color": [{
1572
+ decoration: g()
1573
+ }],
1574
+ /**
1575
+ * Text Underline Offset
1576
+ * @see https://tailwindcss.com/docs/text-underline-offset
1577
+ */
1578
+ "underline-offset": [{
1579
+ "underline-offset": [y, "auto", m, u]
1580
+ }],
1581
+ /**
1582
+ * Text Transform
1583
+ * @see https://tailwindcss.com/docs/text-transform
1584
+ */
1585
+ "text-transform": ["uppercase", "lowercase", "capitalize", "normal-case"],
1586
+ /**
1587
+ * Text Overflow
1588
+ * @see https://tailwindcss.com/docs/text-overflow
1589
+ */
1590
+ "text-overflow": ["truncate", "text-ellipsis", "text-clip"],
1591
+ /**
1592
+ * Text Wrap
1593
+ * @see https://tailwindcss.com/docs/text-wrap
1594
+ */
1595
+ "text-wrap": [{
1596
+ text: ["wrap", "nowrap", "balance", "pretty"]
1597
+ }],
1598
+ /**
1599
+ * Text Indent
1600
+ * @see https://tailwindcss.com/docs/text-indent
1601
+ */
1602
+ indent: [{
1603
+ indent: p()
1604
+ }],
1605
+ /**
1606
+ * Tab Size
1607
+ * @see https://tailwindcss.com/docs/tab-size
1608
+ */
1609
+ "tab-size": [{
1610
+ tab: [X, m, u]
1611
+ }],
1612
+ /**
1613
+ * Vertical Alignment
1614
+ * @see https://tailwindcss.com/docs/vertical-align
1615
+ */
1616
+ "vertical-align": [{
1617
+ align: ["baseline", "top", "middle", "bottom", "text-top", "text-bottom", "sub", "super", m, u]
1618
+ }],
1619
+ /**
1620
+ * Whitespace
1621
+ * @see https://tailwindcss.com/docs/whitespace
1622
+ */
1623
+ whitespace: [{
1624
+ whitespace: ["normal", "nowrap", "pre", "pre-line", "pre-wrap", "break-spaces"]
1625
+ }],
1626
+ /**
1627
+ * Word Break
1628
+ * @see https://tailwindcss.com/docs/word-break
1629
+ */
1630
+ break: [{
1631
+ break: ["normal", "words", "all", "keep"]
1632
+ }],
1633
+ /**
1634
+ * Overflow Wrap
1635
+ * @see https://tailwindcss.com/docs/overflow-wrap
1636
+ */
1637
+ wrap: [{
1638
+ wrap: ["break-word", "anywhere", "normal"]
1639
+ }],
1640
+ /**
1641
+ * Hyphens
1642
+ * @see https://tailwindcss.com/docs/hyphens
1643
+ */
1644
+ hyphens: [{
1645
+ hyphens: ["none", "manual", "auto"]
1646
+ }],
1647
+ /**
1648
+ * Content
1649
+ * @see https://tailwindcss.com/docs/content
1650
+ */
1651
+ content: [{
1652
+ content: ["none", m, u]
1653
+ }],
1654
+ // -------------------
1655
+ // --- Backgrounds ---
1656
+ // -------------------
1657
+ /**
1658
+ * Background Attachment
1659
+ * @see https://tailwindcss.com/docs/background-attachment
1660
+ */
1661
+ "bg-attachment": [{
1662
+ bg: ["fixed", "local", "scroll"]
1663
+ }],
1664
+ /**
1665
+ * Background Clip
1666
+ * @see https://tailwindcss.com/docs/background-clip
1667
+ */
1668
+ "bg-clip": [{
1669
+ "bg-clip": ["border", "padding", "content", "text"]
1670
+ }],
1671
+ /**
1672
+ * Background Origin
1673
+ * @see https://tailwindcss.com/docs/background-origin
1674
+ */
1675
+ "bg-origin": [{
1676
+ "bg-origin": ["border", "padding", "content"]
1677
+ }],
1678
+ /**
1679
+ * Background Position
1680
+ * @see https://tailwindcss.com/docs/background-position
1681
+ */
1682
+ "bg-position": [{
1683
+ bg: he()
1684
+ }],
1685
+ /**
1686
+ * Background Repeat
1687
+ * @see https://tailwindcss.com/docs/background-repeat
1688
+ */
1689
+ "bg-repeat": [{
1690
+ bg: ke()
1691
+ }],
1692
+ /**
1693
+ * Background Size
1694
+ * @see https://tailwindcss.com/docs/background-size
1695
+ */
1696
+ "bg-size": [{
1697
+ bg: k()
1698
+ }],
1699
+ /**
1700
+ * Background Image
1701
+ * @see https://tailwindcss.com/docs/background-image
1702
+ */
1703
+ "bg-image": [{
1704
+ bg: ["none", {
1705
+ linear: [{
1706
+ to: ["t", "tr", "r", "br", "b", "bl", "l", "tl"]
1707
+ }, X, m, u],
1708
+ radial: ["", m, u],
1709
+ conic: ["", X, m, u]
1710
+ }, Vo, $o]
1711
+ }],
1712
+ /**
1713
+ * Background Color
1714
+ * @see https://tailwindcss.com/docs/background-color
1715
+ */
1716
+ "bg-color": [{
1717
+ bg: g()
1718
+ }],
1719
+ /**
1720
+ * Gradient Color Stops From Position
1721
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1722
+ */
1723
+ "gradient-from-pos": [{
1724
+ from: S()
1725
+ }],
1726
+ /**
1727
+ * Gradient Color Stops Via Position
1728
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1729
+ */
1730
+ "gradient-via-pos": [{
1731
+ via: S()
1732
+ }],
1733
+ /**
1734
+ * Gradient Color Stops To Position
1735
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1736
+ */
1737
+ "gradient-to-pos": [{
1738
+ to: S()
1739
+ }],
1740
+ /**
1741
+ * Gradient Color Stops From
1742
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1743
+ */
1744
+ "gradient-from": [{
1745
+ from: g()
1746
+ }],
1747
+ /**
1748
+ * Gradient Color Stops Via
1749
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1750
+ */
1751
+ "gradient-via": [{
1752
+ via: g()
1753
+ }],
1754
+ /**
1755
+ * Gradient Color Stops To
1756
+ * @see https://tailwindcss.com/docs/gradient-color-stops
1757
+ */
1758
+ "gradient-to": [{
1759
+ to: g()
1760
+ }],
1761
+ // ---------------
1762
+ // --- Borders ---
1763
+ // ---------------
1764
+ /**
1765
+ * Border Radius
1766
+ * @see https://tailwindcss.com/docs/border-radius
1767
+ */
1768
+ rounded: [{
1769
+ rounded: N()
1770
+ }],
1771
+ /**
1772
+ * Border Radius Start
1773
+ * @see https://tailwindcss.com/docs/border-radius
1774
+ */
1775
+ "rounded-s": [{
1776
+ "rounded-s": N()
1777
+ }],
1778
+ /**
1779
+ * Border Radius End
1780
+ * @see https://tailwindcss.com/docs/border-radius
1781
+ */
1782
+ "rounded-e": [{
1783
+ "rounded-e": N()
1784
+ }],
1785
+ /**
1786
+ * Border Radius Top
1787
+ * @see https://tailwindcss.com/docs/border-radius
1788
+ */
1789
+ "rounded-t": [{
1790
+ "rounded-t": N()
1791
+ }],
1792
+ /**
1793
+ * Border Radius Right
1794
+ * @see https://tailwindcss.com/docs/border-radius
1795
+ */
1796
+ "rounded-r": [{
1797
+ "rounded-r": N()
1798
+ }],
1799
+ /**
1800
+ * Border Radius Bottom
1801
+ * @see https://tailwindcss.com/docs/border-radius
1802
+ */
1803
+ "rounded-b": [{
1804
+ "rounded-b": N()
1805
+ }],
1806
+ /**
1807
+ * Border Radius Left
1808
+ * @see https://tailwindcss.com/docs/border-radius
1809
+ */
1810
+ "rounded-l": [{
1811
+ "rounded-l": N()
1812
+ }],
1813
+ /**
1814
+ * Border Radius Start Start
1815
+ * @see https://tailwindcss.com/docs/border-radius
1816
+ */
1817
+ "rounded-ss": [{
1818
+ "rounded-ss": N()
1819
+ }],
1820
+ /**
1821
+ * Border Radius Start End
1822
+ * @see https://tailwindcss.com/docs/border-radius
1823
+ */
1824
+ "rounded-se": [{
1825
+ "rounded-se": N()
1826
+ }],
1827
+ /**
1828
+ * Border Radius End End
1829
+ * @see https://tailwindcss.com/docs/border-radius
1830
+ */
1831
+ "rounded-ee": [{
1832
+ "rounded-ee": N()
1833
+ }],
1834
+ /**
1835
+ * Border Radius End Start
1836
+ * @see https://tailwindcss.com/docs/border-radius
1837
+ */
1838
+ "rounded-es": [{
1839
+ "rounded-es": N()
1840
+ }],
1841
+ /**
1842
+ * Border Radius Top Left
1843
+ * @see https://tailwindcss.com/docs/border-radius
1844
+ */
1845
+ "rounded-tl": [{
1846
+ "rounded-tl": N()
1847
+ }],
1848
+ /**
1849
+ * Border Radius Top Right
1850
+ * @see https://tailwindcss.com/docs/border-radius
1851
+ */
1852
+ "rounded-tr": [{
1853
+ "rounded-tr": N()
1854
+ }],
1855
+ /**
1856
+ * Border Radius Bottom Right
1857
+ * @see https://tailwindcss.com/docs/border-radius
1858
+ */
1859
+ "rounded-br": [{
1860
+ "rounded-br": N()
1861
+ }],
1862
+ /**
1863
+ * Border Radius Bottom Left
1864
+ * @see https://tailwindcss.com/docs/border-radius
1865
+ */
1866
+ "rounded-bl": [{
1867
+ "rounded-bl": N()
1868
+ }],
1869
+ /**
1870
+ * Border Width
1871
+ * @see https://tailwindcss.com/docs/border-width
1872
+ */
1873
+ "border-w": [{
1874
+ border: D()
1875
+ }],
1876
+ /**
1877
+ * Border Width Inline
1878
+ * @see https://tailwindcss.com/docs/border-width
1879
+ */
1880
+ "border-w-x": [{
1881
+ "border-x": D()
1882
+ }],
1883
+ /**
1884
+ * Border Width Block
1885
+ * @see https://tailwindcss.com/docs/border-width
1886
+ */
1887
+ "border-w-y": [{
1888
+ "border-y": D()
1889
+ }],
1890
+ /**
1891
+ * Border Width Inline Start
1892
+ * @see https://tailwindcss.com/docs/border-width
1893
+ */
1894
+ "border-w-s": [{
1895
+ "border-s": D()
1896
+ }],
1897
+ /**
1898
+ * Border Width Inline End
1899
+ * @see https://tailwindcss.com/docs/border-width
1900
+ */
1901
+ "border-w-e": [{
1902
+ "border-e": D()
1903
+ }],
1904
+ /**
1905
+ * Border Width Block Start
1906
+ * @see https://tailwindcss.com/docs/border-width
1907
+ */
1908
+ "border-w-bs": [{
1909
+ "border-bs": D()
1910
+ }],
1911
+ /**
1912
+ * Border Width Block End
1913
+ * @see https://tailwindcss.com/docs/border-width
1914
+ */
1915
+ "border-w-be": [{
1916
+ "border-be": D()
1917
+ }],
1918
+ /**
1919
+ * Border Width Top
1920
+ * @see https://tailwindcss.com/docs/border-width
1921
+ */
1922
+ "border-w-t": [{
1923
+ "border-t": D()
1924
+ }],
1925
+ /**
1926
+ * Border Width Right
1927
+ * @see https://tailwindcss.com/docs/border-width
1928
+ */
1929
+ "border-w-r": [{
1930
+ "border-r": D()
1931
+ }],
1932
+ /**
1933
+ * Border Width Bottom
1934
+ * @see https://tailwindcss.com/docs/border-width
1935
+ */
1936
+ "border-w-b": [{
1937
+ "border-b": D()
1938
+ }],
1939
+ /**
1940
+ * Border Width Left
1941
+ * @see https://tailwindcss.com/docs/border-width
1942
+ */
1943
+ "border-w-l": [{
1944
+ "border-l": D()
1945
+ }],
1946
+ /**
1947
+ * Divide Width X
1948
+ * @see https://tailwindcss.com/docs/border-width#between-children
1949
+ */
1950
+ "divide-x": [{
1951
+ "divide-x": D()
1952
+ }],
1953
+ /**
1954
+ * Divide Width X Reverse
1955
+ * @see https://tailwindcss.com/docs/border-width#between-children
1956
+ */
1957
+ "divide-x-reverse": ["divide-x-reverse"],
1958
+ /**
1959
+ * Divide Width Y
1960
+ * @see https://tailwindcss.com/docs/border-width#between-children
1961
+ */
1962
+ "divide-y": [{
1963
+ "divide-y": D()
1964
+ }],
1965
+ /**
1966
+ * Divide Width Y Reverse
1967
+ * @see https://tailwindcss.com/docs/border-width#between-children
1968
+ */
1969
+ "divide-y-reverse": ["divide-y-reverse"],
1970
+ /**
1971
+ * Border Style
1972
+ * @see https://tailwindcss.com/docs/border-style
1973
+ */
1974
+ "border-style": [{
1975
+ border: [...re(), "hidden", "none"]
1976
+ }],
1977
+ /**
1978
+ * Divide Style
1979
+ * @see https://tailwindcss.com/docs/border-style#setting-the-divider-style
1980
+ */
1981
+ "divide-style": [{
1982
+ divide: [...re(), "hidden", "none"]
1983
+ }],
1984
+ /**
1985
+ * Border Color
1986
+ * @see https://tailwindcss.com/docs/border-color
1987
+ */
1988
+ "border-color": [{
1989
+ border: g()
1990
+ }],
1991
+ /**
1992
+ * Border Color Inline
1993
+ * @see https://tailwindcss.com/docs/border-color
1994
+ */
1995
+ "border-color-x": [{
1996
+ "border-x": g()
1997
+ }],
1998
+ /**
1999
+ * Border Color Block
2000
+ * @see https://tailwindcss.com/docs/border-color
2001
+ */
2002
+ "border-color-y": [{
2003
+ "border-y": g()
2004
+ }],
2005
+ /**
2006
+ * Border Color Inline Start
2007
+ * @see https://tailwindcss.com/docs/border-color
2008
+ */
2009
+ "border-color-s": [{
2010
+ "border-s": g()
2011
+ }],
2012
+ /**
2013
+ * Border Color Inline End
2014
+ * @see https://tailwindcss.com/docs/border-color
2015
+ */
2016
+ "border-color-e": [{
2017
+ "border-e": g()
2018
+ }],
2019
+ /**
2020
+ * Border Color Block Start
2021
+ * @see https://tailwindcss.com/docs/border-color
2022
+ */
2023
+ "border-color-bs": [{
2024
+ "border-bs": g()
2025
+ }],
2026
+ /**
2027
+ * Border Color Block End
2028
+ * @see https://tailwindcss.com/docs/border-color
2029
+ */
2030
+ "border-color-be": [{
2031
+ "border-be": g()
2032
+ }],
2033
+ /**
2034
+ * Border Color Top
2035
+ * @see https://tailwindcss.com/docs/border-color
2036
+ */
2037
+ "border-color-t": [{
2038
+ "border-t": g()
2039
+ }],
2040
+ /**
2041
+ * Border Color Right
2042
+ * @see https://tailwindcss.com/docs/border-color
2043
+ */
2044
+ "border-color-r": [{
2045
+ "border-r": g()
2046
+ }],
2047
+ /**
2048
+ * Border Color Bottom
2049
+ * @see https://tailwindcss.com/docs/border-color
2050
+ */
2051
+ "border-color-b": [{
2052
+ "border-b": g()
2053
+ }],
2054
+ /**
2055
+ * Border Color Left
2056
+ * @see https://tailwindcss.com/docs/border-color
2057
+ */
2058
+ "border-color-l": [{
2059
+ "border-l": g()
2060
+ }],
2061
+ /**
2062
+ * Divide Color
2063
+ * @see https://tailwindcss.com/docs/divide-color
2064
+ */
2065
+ "divide-color": [{
2066
+ divide: g()
2067
+ }],
2068
+ /**
2069
+ * Outline Style
2070
+ * @see https://tailwindcss.com/docs/outline-style
2071
+ */
2072
+ "outline-style": [{
2073
+ outline: [...re(), "none", "hidden"]
2074
+ }],
2075
+ /**
2076
+ * Outline Offset
2077
+ * @see https://tailwindcss.com/docs/outline-offset
2078
+ */
2079
+ "outline-offset": [{
2080
+ "outline-offset": [y, m, u]
2081
+ }],
2082
+ /**
2083
+ * Outline Width
2084
+ * @see https://tailwindcss.com/docs/outline-width
2085
+ */
2086
+ "outline-w": [{
2087
+ outline: ["", y, ye, le]
2088
+ }],
2089
+ /**
2090
+ * Outline Color
2091
+ * @see https://tailwindcss.com/docs/outline-color
2092
+ */
2093
+ "outline-color": [{
2094
+ outline: g()
2095
+ }],
2096
+ // ---------------
2097
+ // --- Effects ---
2098
+ // ---------------
2099
+ /**
2100
+ * Box Shadow
2101
+ * @see https://tailwindcss.com/docs/box-shadow
2102
+ */
2103
+ shadow: [{
2104
+ shadow: [
2105
+ // Deprecated since Tailwind CSS v4.0.0
2106
+ "",
2107
+ // Deprecated since Tailwind CSS v4.0.0
2108
+ "inner",
2109
+ "none",
2110
+ f,
2111
+ Ne,
2112
+ ve
2113
+ ]
2114
+ }],
2115
+ /**
2116
+ * Box Shadow Color
2117
+ * @see https://tailwindcss.com/docs/box-shadow#setting-the-shadow-color
2118
+ */
2119
+ "shadow-color": [{
2120
+ shadow: g()
2121
+ }],
2122
+ /**
2123
+ * Inset Box Shadow
2124
+ * @see https://tailwindcss.com/docs/box-shadow#adding-an-inset-shadow
2125
+ */
2126
+ "inset-shadow": [{
2127
+ "inset-shadow": ["none", b, Ne, ve]
2128
+ }],
2129
+ /**
2130
+ * Inset Box Shadow Color
2131
+ * @see https://tailwindcss.com/docs/box-shadow#setting-the-inset-shadow-color
2132
+ */
2133
+ "inset-shadow-color": [{
2134
+ "inset-shadow": g()
2135
+ }],
2136
+ /**
2137
+ * Ring Width
2138
+ * @see https://tailwindcss.com/docs/box-shadow#adding-a-ring
2139
+ */
2140
+ "ring-w": [{
2141
+ ring: D()
2142
+ }],
2143
+ /**
2144
+ * Ring Width Inset
2145
+ * @see https://v3.tailwindcss.com/docs/ring-width#inset-rings
2146
+ * @deprecated since Tailwind CSS v4.0.0
2147
+ * @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158
2148
+ */
2149
+ "ring-w-inset": ["ring-inset"],
2150
+ /**
2151
+ * Ring Color
2152
+ * @see https://tailwindcss.com/docs/box-shadow#setting-the-ring-color
2153
+ */
2154
+ "ring-color": [{
2155
+ ring: g()
2156
+ }],
2157
+ /**
2158
+ * Ring Offset Width
2159
+ * @see https://v3.tailwindcss.com/docs/ring-offset-width
2160
+ * @deprecated since Tailwind CSS v4.0.0
2161
+ * @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158
2162
+ */
2163
+ "ring-offset-w": [{
2164
+ "ring-offset": [y, le]
2165
+ }],
2166
+ /**
2167
+ * Ring Offset Color
2168
+ * @see https://v3.tailwindcss.com/docs/ring-offset-color
2169
+ * @deprecated since Tailwind CSS v4.0.0
2170
+ * @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158
2171
+ */
2172
+ "ring-offset-color": [{
2173
+ "ring-offset": g()
2174
+ }],
2175
+ /**
2176
+ * Inset Ring Width
2177
+ * @see https://tailwindcss.com/docs/box-shadow#adding-an-inset-ring
2178
+ */
2179
+ "inset-ring-w": [{
2180
+ "inset-ring": D()
2181
+ }],
2182
+ /**
2183
+ * Inset Ring Color
2184
+ * @see https://tailwindcss.com/docs/box-shadow#setting-the-inset-ring-color
2185
+ */
2186
+ "inset-ring-color": [{
2187
+ "inset-ring": g()
2188
+ }],
2189
+ /**
2190
+ * Text Shadow
2191
+ * @see https://tailwindcss.com/docs/text-shadow
2192
+ */
2193
+ "text-shadow": [{
2194
+ "text-shadow": ["none", w, Ne, ve]
2195
+ }],
2196
+ /**
2197
+ * Text Shadow Color
2198
+ * @see https://tailwindcss.com/docs/text-shadow#setting-the-shadow-color
2199
+ */
2200
+ "text-shadow-color": [{
2201
+ "text-shadow": g()
2202
+ }],
2203
+ /**
2204
+ * Opacity
2205
+ * @see https://tailwindcss.com/docs/opacity
2206
+ */
2207
+ opacity: [{
2208
+ opacity: [y, m, u]
2209
+ }],
2210
+ /**
2211
+ * Mix Blend Mode
2212
+ * @see https://tailwindcss.com/docs/mix-blend-mode
2213
+ */
2214
+ "mix-blend": [{
2215
+ "mix-blend": [...be(), "plus-darker", "plus-lighter"]
2216
+ }],
2217
+ /**
2218
+ * Background Blend Mode
2219
+ * @see https://tailwindcss.com/docs/background-blend-mode
2220
+ */
2221
+ "bg-blend": [{
2222
+ "bg-blend": be()
2223
+ }],
2224
+ /**
2225
+ * Mask Clip
2226
+ * @see https://tailwindcss.com/docs/mask-clip
2227
+ */
2228
+ "mask-clip": [{
2229
+ "mask-clip": ["border", "padding", "content", "fill", "stroke", "view"]
2230
+ }, "mask-no-clip"],
2231
+ /**
2232
+ * Mask Composite
2233
+ * @see https://tailwindcss.com/docs/mask-composite
2234
+ */
2235
+ "mask-composite": [{
2236
+ mask: ["add", "subtract", "intersect", "exclude"]
2237
+ }],
2238
+ /**
2239
+ * Mask Image
2240
+ * @see https://tailwindcss.com/docs/mask-image
2241
+ */
2242
+ "mask-image-linear-pos": [{
2243
+ "mask-linear": [y]
2244
+ }],
2245
+ "mask-image-linear-from-pos": [{
2246
+ "mask-linear-from": I()
2247
+ }],
2248
+ "mask-image-linear-to-pos": [{
2249
+ "mask-linear-to": I()
2250
+ }],
2251
+ "mask-image-linear-from-color": [{
2252
+ "mask-linear-from": g()
2253
+ }],
2254
+ "mask-image-linear-to-color": [{
2255
+ "mask-linear-to": g()
2256
+ }],
2257
+ "mask-image-t-from-pos": [{
2258
+ "mask-t-from": I()
2259
+ }],
2260
+ "mask-image-t-to-pos": [{
2261
+ "mask-t-to": I()
2262
+ }],
2263
+ "mask-image-t-from-color": [{
2264
+ "mask-t-from": g()
2265
+ }],
2266
+ "mask-image-t-to-color": [{
2267
+ "mask-t-to": g()
2268
+ }],
2269
+ "mask-image-r-from-pos": [{
2270
+ "mask-r-from": I()
2271
+ }],
2272
+ "mask-image-r-to-pos": [{
2273
+ "mask-r-to": I()
2274
+ }],
2275
+ "mask-image-r-from-color": [{
2276
+ "mask-r-from": g()
2277
+ }],
2278
+ "mask-image-r-to-color": [{
2279
+ "mask-r-to": g()
2280
+ }],
2281
+ "mask-image-b-from-pos": [{
2282
+ "mask-b-from": I()
2283
+ }],
2284
+ "mask-image-b-to-pos": [{
2285
+ "mask-b-to": I()
2286
+ }],
2287
+ "mask-image-b-from-color": [{
2288
+ "mask-b-from": g()
2289
+ }],
2290
+ "mask-image-b-to-color": [{
2291
+ "mask-b-to": g()
2292
+ }],
2293
+ "mask-image-l-from-pos": [{
2294
+ "mask-l-from": I()
2295
+ }],
2296
+ "mask-image-l-to-pos": [{
2297
+ "mask-l-to": I()
2298
+ }],
2299
+ "mask-image-l-from-color": [{
2300
+ "mask-l-from": g()
2301
+ }],
2302
+ "mask-image-l-to-color": [{
2303
+ "mask-l-to": g()
2304
+ }],
2305
+ "mask-image-x-from-pos": [{
2306
+ "mask-x-from": I()
2307
+ }],
2308
+ "mask-image-x-to-pos": [{
2309
+ "mask-x-to": I()
2310
+ }],
2311
+ "mask-image-x-from-color": [{
2312
+ "mask-x-from": g()
2313
+ }],
2314
+ "mask-image-x-to-color": [{
2315
+ "mask-x-to": g()
2316
+ }],
2317
+ "mask-image-y-from-pos": [{
2318
+ "mask-y-from": I()
2319
+ }],
2320
+ "mask-image-y-to-pos": [{
2321
+ "mask-y-to": I()
2322
+ }],
2323
+ "mask-image-y-from-color": [{
2324
+ "mask-y-from": g()
2325
+ }],
2326
+ "mask-image-y-to-color": [{
2327
+ "mask-y-to": g()
2328
+ }],
2329
+ "mask-image-radial": [{
2330
+ "mask-radial": [m, u]
2331
+ }],
2332
+ "mask-image-radial-from-pos": [{
2333
+ "mask-radial-from": I()
2334
+ }],
2335
+ "mask-image-radial-to-pos": [{
2336
+ "mask-radial-to": I()
2337
+ }],
2338
+ "mask-image-radial-from-color": [{
2339
+ "mask-radial-from": g()
2340
+ }],
2341
+ "mask-image-radial-to-color": [{
2342
+ "mask-radial-to": g()
2343
+ }],
2344
+ "mask-image-radial-shape": [{
2345
+ "mask-radial": ["circle", "ellipse"]
2346
+ }],
2347
+ "mask-image-radial-size": [{
2348
+ "mask-radial": [{
2349
+ closest: ["side", "corner"],
2350
+ farthest: ["side", "corner"]
2351
+ }]
2352
+ }],
2353
+ "mask-image-radial-pos": [{
2354
+ "mask-radial-at": O()
2355
+ }],
2356
+ "mask-image-conic-pos": [{
2357
+ "mask-conic": [y]
2358
+ }],
2359
+ "mask-image-conic-from-pos": [{
2360
+ "mask-conic-from": I()
2361
+ }],
2362
+ "mask-image-conic-to-pos": [{
2363
+ "mask-conic-to": I()
2364
+ }],
2365
+ "mask-image-conic-from-color": [{
2366
+ "mask-conic-from": g()
2367
+ }],
2368
+ "mask-image-conic-to-color": [{
2369
+ "mask-conic-to": g()
2370
+ }],
2371
+ /**
2372
+ * Mask Mode
2373
+ * @see https://tailwindcss.com/docs/mask-mode
2374
+ */
2375
+ "mask-mode": [{
2376
+ mask: ["alpha", "luminance", "match"]
2377
+ }],
2378
+ /**
2379
+ * Mask Origin
2380
+ * @see https://tailwindcss.com/docs/mask-origin
2381
+ */
2382
+ "mask-origin": [{
2383
+ "mask-origin": ["border", "padding", "content", "fill", "stroke", "view"]
2384
+ }],
2385
+ /**
2386
+ * Mask Position
2387
+ * @see https://tailwindcss.com/docs/mask-position
2388
+ */
2389
+ "mask-position": [{
2390
+ mask: he()
2391
+ }],
2392
+ /**
2393
+ * Mask Repeat
2394
+ * @see https://tailwindcss.com/docs/mask-repeat
2395
+ */
2396
+ "mask-repeat": [{
2397
+ mask: ke()
2398
+ }],
2399
+ /**
2400
+ * Mask Size
2401
+ * @see https://tailwindcss.com/docs/mask-size
2402
+ */
2403
+ "mask-size": [{
2404
+ mask: k()
2405
+ }],
2406
+ /**
2407
+ * Mask Type
2408
+ * @see https://tailwindcss.com/docs/mask-type
2409
+ */
2410
+ "mask-type": [{
2411
+ "mask-type": ["alpha", "luminance"]
2412
+ }],
2413
+ /**
2414
+ * Mask Image
2415
+ * @see https://tailwindcss.com/docs/mask-image
2416
+ */
2417
+ "mask-image": [{
2418
+ mask: ["none", m, u]
2419
+ }],
2420
+ // ---------------
2421
+ // --- Filters ---
2422
+ // ---------------
2423
+ /**
2424
+ * Filter
2425
+ * @see https://tailwindcss.com/docs/filter
2426
+ */
2427
+ filter: [{
2428
+ filter: [
2429
+ // Deprecated since Tailwind CSS v3.0.0
2430
+ "",
2431
+ "none",
2432
+ m,
2433
+ u
2434
+ ]
2435
+ }],
2436
+ /**
2437
+ * Blur
2438
+ * @see https://tailwindcss.com/docs/blur
2439
+ */
2440
+ blur: [{
2441
+ blur: xe()
2442
+ }],
2443
+ /**
2444
+ * Brightness
2445
+ * @see https://tailwindcss.com/docs/brightness
2446
+ */
2447
+ brightness: [{
2448
+ brightness: [y, m, u]
2449
+ }],
2450
+ /**
2451
+ * Contrast
2452
+ * @see https://tailwindcss.com/docs/contrast
2453
+ */
2454
+ contrast: [{
2455
+ contrast: [y, m, u]
2456
+ }],
2457
+ /**
2458
+ * Drop Shadow
2459
+ * @see https://tailwindcss.com/docs/drop-shadow
2460
+ */
2461
+ "drop-shadow": [{
2462
+ "drop-shadow": [
2463
+ // Deprecated since Tailwind CSS v4.0.0
2464
+ "",
2465
+ "none",
2466
+ C,
2467
+ Ne,
2468
+ ve
2469
+ ]
2470
+ }],
2471
+ /**
2472
+ * Drop Shadow Color
2473
+ * @see https://tailwindcss.com/docs/filter-drop-shadow#setting-the-shadow-color
2474
+ */
2475
+ "drop-shadow-color": [{
2476
+ "drop-shadow": g()
2477
+ }],
2478
+ /**
2479
+ * Grayscale
2480
+ * @see https://tailwindcss.com/docs/grayscale
2481
+ */
2482
+ grayscale: [{
2483
+ grayscale: ["", y, m, u]
2484
+ }],
2485
+ /**
2486
+ * Hue Rotate
2487
+ * @see https://tailwindcss.com/docs/hue-rotate
2488
+ */
2489
+ "hue-rotate": [{
2490
+ "hue-rotate": [y, m, u]
2491
+ }],
2492
+ /**
2493
+ * Invert
2494
+ * @see https://tailwindcss.com/docs/invert
2495
+ */
2496
+ invert: [{
2497
+ invert: ["", y, m, u]
2498
+ }],
2499
+ /**
2500
+ * Saturate
2501
+ * @see https://tailwindcss.com/docs/saturate
2502
+ */
2503
+ saturate: [{
2504
+ saturate: [y, m, u]
2505
+ }],
2506
+ /**
2507
+ * Sepia
2508
+ * @see https://tailwindcss.com/docs/sepia
2509
+ */
2510
+ sepia: [{
2511
+ sepia: ["", y, m, u]
2512
+ }],
2513
+ /**
2514
+ * Backdrop Filter
2515
+ * @see https://tailwindcss.com/docs/backdrop-filter
2516
+ */
2517
+ "backdrop-filter": [{
2518
+ "backdrop-filter": [
2519
+ // Deprecated since Tailwind CSS v3.0.0
2520
+ "",
2521
+ "none",
2522
+ m,
2523
+ u
2524
+ ]
2525
+ }],
2526
+ /**
2527
+ * Backdrop Blur
2528
+ * @see https://tailwindcss.com/docs/backdrop-blur
2529
+ */
2530
+ "backdrop-blur": [{
2531
+ "backdrop-blur": xe()
2532
+ }],
2533
+ /**
2534
+ * Backdrop Brightness
2535
+ * @see https://tailwindcss.com/docs/backdrop-brightness
2536
+ */
2537
+ "backdrop-brightness": [{
2538
+ "backdrop-brightness": [y, m, u]
2539
+ }],
2540
+ /**
2541
+ * Backdrop Contrast
2542
+ * @see https://tailwindcss.com/docs/backdrop-contrast
2543
+ */
2544
+ "backdrop-contrast": [{
2545
+ "backdrop-contrast": [y, m, u]
2546
+ }],
2547
+ /**
2548
+ * Backdrop Grayscale
2549
+ * @see https://tailwindcss.com/docs/backdrop-grayscale
2550
+ */
2551
+ "backdrop-grayscale": [{
2552
+ "backdrop-grayscale": ["", y, m, u]
2553
+ }],
2554
+ /**
2555
+ * Backdrop Hue Rotate
2556
+ * @see https://tailwindcss.com/docs/backdrop-hue-rotate
2557
+ */
2558
+ "backdrop-hue-rotate": [{
2559
+ "backdrop-hue-rotate": [y, m, u]
2560
+ }],
2561
+ /**
2562
+ * Backdrop Invert
2563
+ * @see https://tailwindcss.com/docs/backdrop-invert
2564
+ */
2565
+ "backdrop-invert": [{
2566
+ "backdrop-invert": ["", y, m, u]
2567
+ }],
2568
+ /**
2569
+ * Backdrop Opacity
2570
+ * @see https://tailwindcss.com/docs/backdrop-opacity
2571
+ */
2572
+ "backdrop-opacity": [{
2573
+ "backdrop-opacity": [y, m, u]
2574
+ }],
2575
+ /**
2576
+ * Backdrop Saturate
2577
+ * @see https://tailwindcss.com/docs/backdrop-saturate
2578
+ */
2579
+ "backdrop-saturate": [{
2580
+ "backdrop-saturate": [y, m, u]
2581
+ }],
2582
+ /**
2583
+ * Backdrop Sepia
2584
+ * @see https://tailwindcss.com/docs/backdrop-sepia
2585
+ */
2586
+ "backdrop-sepia": [{
2587
+ "backdrop-sepia": ["", y, m, u]
2588
+ }],
2589
+ // --------------
2590
+ // --- Tables ---
2591
+ // --------------
2592
+ /**
2593
+ * Border Collapse
2594
+ * @see https://tailwindcss.com/docs/border-collapse
2595
+ */
2596
+ "border-collapse": [{
2597
+ border: ["collapse", "separate"]
2598
+ }],
2599
+ /**
2600
+ * Border Spacing
2601
+ * @see https://tailwindcss.com/docs/border-spacing
2602
+ */
2603
+ "border-spacing": [{
2604
+ "border-spacing": p()
2605
+ }],
2606
+ /**
2607
+ * Border Spacing X
2608
+ * @see https://tailwindcss.com/docs/border-spacing
2609
+ */
2610
+ "border-spacing-x": [{
2611
+ "border-spacing-x": p()
2612
+ }],
2613
+ /**
2614
+ * Border Spacing Y
2615
+ * @see https://tailwindcss.com/docs/border-spacing
2616
+ */
2617
+ "border-spacing-y": [{
2618
+ "border-spacing-y": p()
2619
+ }],
2620
+ /**
2621
+ * Table Layout
2622
+ * @see https://tailwindcss.com/docs/table-layout
2623
+ */
2624
+ "table-layout": [{
2625
+ table: ["auto", "fixed"]
2626
+ }],
2627
+ /**
2628
+ * Caption Side
2629
+ * @see https://tailwindcss.com/docs/caption-side
2630
+ */
2631
+ caption: [{
2632
+ caption: ["top", "bottom"]
2633
+ }],
2634
+ // ---------------------------------
2635
+ // --- Transitions and Animation ---
2636
+ // ---------------------------------
2637
+ /**
2638
+ * Transition Property
2639
+ * @see https://tailwindcss.com/docs/transition-property
2640
+ */
2641
+ transition: [{
2642
+ transition: ["", "all", "colors", "opacity", "shadow", "transform", "none", m, u]
2643
+ }],
2644
+ /**
2645
+ * Transition Behavior
2646
+ * @see https://tailwindcss.com/docs/transition-behavior
2647
+ */
2648
+ "transition-behavior": [{
2649
+ transition: ["normal", "discrete"]
2650
+ }],
2651
+ /**
2652
+ * Transition Duration
2653
+ * @see https://tailwindcss.com/docs/transition-duration
2654
+ */
2655
+ duration: [{
2656
+ duration: [y, "initial", m, u]
2657
+ }],
2658
+ /**
2659
+ * Transition Timing Function
2660
+ * @see https://tailwindcss.com/docs/transition-timing-function
2661
+ */
2662
+ ease: [{
2663
+ ease: ["linear", "initial", z, m, u]
2664
+ }],
2665
+ /**
2666
+ * Transition Delay
2667
+ * @see https://tailwindcss.com/docs/transition-delay
2668
+ */
2669
+ delay: [{
2670
+ delay: [y, m, u]
2671
+ }],
2672
+ /**
2673
+ * Animation
2674
+ * @see https://tailwindcss.com/docs/animation
2675
+ */
2676
+ animate: [{
2677
+ animate: ["none", h, m, u]
2678
+ }],
2679
+ // ------------------
2680
+ // --- Transforms ---
2681
+ // ------------------
2682
+ /**
2683
+ * Backface Visibility
2684
+ * @see https://tailwindcss.com/docs/backface-visibility
2685
+ */
2686
+ backface: [{
2687
+ backface: ["hidden", "visible"]
2688
+ }],
2689
+ /**
2690
+ * Perspective
2691
+ * @see https://tailwindcss.com/docs/perspective
2692
+ */
2693
+ perspective: [{
2694
+ perspective: [v, m, u]
2695
+ }],
2696
+ /**
2697
+ * Perspective Origin
2698
+ * @see https://tailwindcss.com/docs/perspective-origin
2699
+ */
2700
+ "perspective-origin": [{
2701
+ "perspective-origin": E()
2702
+ }],
2703
+ /**
2704
+ * Rotate
2705
+ * @see https://tailwindcss.com/docs/rotate
2706
+ */
2707
+ rotate: [{
2708
+ rotate: me()
2709
+ }],
2710
+ /**
2711
+ * Rotate X
2712
+ * @see https://tailwindcss.com/docs/rotate
2713
+ */
2714
+ "rotate-x": [{
2715
+ "rotate-x": me()
2716
+ }],
2717
+ /**
2718
+ * Rotate Y
2719
+ * @see https://tailwindcss.com/docs/rotate
2720
+ */
2721
+ "rotate-y": [{
2722
+ "rotate-y": me()
2723
+ }],
2724
+ /**
2725
+ * Rotate Z
2726
+ * @see https://tailwindcss.com/docs/rotate
2727
+ */
2728
+ "rotate-z": [{
2729
+ "rotate-z": me()
2730
+ }],
2731
+ /**
2732
+ * Scale
2733
+ * @see https://tailwindcss.com/docs/scale
2734
+ */
2735
+ scale: [{
2736
+ scale: ne()
2737
+ }],
2738
+ /**
2739
+ * Scale X
2740
+ * @see https://tailwindcss.com/docs/scale
2741
+ */
2742
+ "scale-x": [{
2743
+ "scale-x": ne()
2744
+ }],
2745
+ /**
2746
+ * Scale Y
2747
+ * @see https://tailwindcss.com/docs/scale
2748
+ */
2749
+ "scale-y": [{
2750
+ "scale-y": ne()
2751
+ }],
2752
+ /**
2753
+ * Scale Z
2754
+ * @see https://tailwindcss.com/docs/scale
2755
+ */
2756
+ "scale-z": [{
2757
+ "scale-z": ne()
2758
+ }],
2759
+ /**
2760
+ * Scale 3D
2761
+ * @see https://tailwindcss.com/docs/scale
2762
+ */
2763
+ "scale-3d": ["scale-3d"],
2764
+ /**
2765
+ * Skew
2766
+ * @see https://tailwindcss.com/docs/skew
2767
+ */
2768
+ skew: [{
2769
+ skew: pe()
2770
+ }],
2771
+ /**
2772
+ * Skew X
2773
+ * @see https://tailwindcss.com/docs/skew
2774
+ */
2775
+ "skew-x": [{
2776
+ "skew-x": pe()
2777
+ }],
2778
+ /**
2779
+ * Skew Y
2780
+ * @see https://tailwindcss.com/docs/skew
2781
+ */
2782
+ "skew-y": [{
2783
+ "skew-y": pe()
2784
+ }],
2785
+ /**
2786
+ * Transform
2787
+ * @see https://tailwindcss.com/docs/transform
2788
+ */
2789
+ transform: [{
2790
+ transform: [m, u, "", "none", "gpu", "cpu"]
2791
+ }],
2792
+ /**
2793
+ * Transform Origin
2794
+ * @see https://tailwindcss.com/docs/transform-origin
2795
+ */
2796
+ "transform-origin": [{
2797
+ origin: E()
2798
+ }],
2799
+ /**
2800
+ * Transform Style
2801
+ * @see https://tailwindcss.com/docs/transform-style
2802
+ */
2803
+ "transform-style": [{
2804
+ transform: ["3d", "flat"]
2805
+ }],
2806
+ /**
2807
+ * Translate
2808
+ * @see https://tailwindcss.com/docs/translate
2809
+ */
2810
+ translate: [{
2811
+ translate: ee()
2812
+ }],
2813
+ /**
2814
+ * Translate X
2815
+ * @see https://tailwindcss.com/docs/translate
2816
+ */
2817
+ "translate-x": [{
2818
+ "translate-x": ee()
2819
+ }],
2820
+ /**
2821
+ * Translate Y
2822
+ * @see https://tailwindcss.com/docs/translate
2823
+ */
2824
+ "translate-y": [{
2825
+ "translate-y": ee()
2826
+ }],
2827
+ /**
2828
+ * Translate Z
2829
+ * @see https://tailwindcss.com/docs/translate
2830
+ */
2831
+ "translate-z": [{
2832
+ "translate-z": ee()
2833
+ }],
2834
+ /**
2835
+ * Translate None
2836
+ * @see https://tailwindcss.com/docs/translate
2837
+ */
2838
+ "translate-none": ["translate-none"],
2839
+ /**
2840
+ * Zoom
2841
+ * @see https://tailwindcss.com/docs/zoom
2842
+ */
2843
+ zoom: [{
2844
+ zoom: [X, m, u]
2845
+ }],
2846
+ // ---------------------
2847
+ // --- Interactivity ---
2848
+ // ---------------------
2849
+ /**
2850
+ * Accent Color
2851
+ * @see https://tailwindcss.com/docs/accent-color
2852
+ */
2853
+ accent: [{
2854
+ accent: g()
2855
+ }],
2856
+ /**
2857
+ * Appearance
2858
+ * @see https://tailwindcss.com/docs/appearance
2859
+ */
2860
+ appearance: [{
2861
+ appearance: ["none", "auto"]
2862
+ }],
2863
+ /**
2864
+ * Caret Color
2865
+ * @see https://tailwindcss.com/docs/just-in-time-mode#caret-color-utilities
2866
+ */
2867
+ "caret-color": [{
2868
+ caret: g()
2869
+ }],
2870
+ /**
2871
+ * Color Scheme
2872
+ * @see https://tailwindcss.com/docs/color-scheme
2873
+ */
2874
+ "color-scheme": [{
2875
+ scheme: ["normal", "dark", "light", "light-dark", "only-dark", "only-light"]
2876
+ }],
2877
+ /**
2878
+ * Cursor
2879
+ * @see https://tailwindcss.com/docs/cursor
2880
+ */
2881
+ cursor: [{
2882
+ cursor: ["auto", "default", "pointer", "wait", "text", "move", "help", "not-allowed", "none", "context-menu", "progress", "cell", "crosshair", "vertical-text", "alias", "copy", "no-drop", "grab", "grabbing", "all-scroll", "col-resize", "row-resize", "n-resize", "e-resize", "s-resize", "w-resize", "ne-resize", "nw-resize", "se-resize", "sw-resize", "ew-resize", "ns-resize", "nesw-resize", "nwse-resize", "zoom-in", "zoom-out", m, u]
2883
+ }],
2884
+ /**
2885
+ * Field Sizing
2886
+ * @see https://tailwindcss.com/docs/field-sizing
2887
+ */
2888
+ "field-sizing": [{
2889
+ "field-sizing": ["fixed", "content"]
2890
+ }],
2891
+ /**
2892
+ * Pointer Events
2893
+ * @see https://tailwindcss.com/docs/pointer-events
2894
+ */
2895
+ "pointer-events": [{
2896
+ "pointer-events": ["auto", "none"]
2897
+ }],
2898
+ /**
2899
+ * Resize
2900
+ * @see https://tailwindcss.com/docs/resize
2901
+ */
2902
+ resize: [{
2903
+ resize: ["none", "", "y", "x"]
2904
+ }],
2905
+ /**
2906
+ * Scroll Behavior
2907
+ * @see https://tailwindcss.com/docs/scroll-behavior
2908
+ */
2909
+ "scroll-behavior": [{
2910
+ scroll: ["auto", "smooth"]
2911
+ }],
2912
+ /**
2913
+ * Scrollbar Thumb Color
2914
+ * @see https://tailwindcss.com/docs/scrollbar-color
2915
+ */
2916
+ "scrollbar-thumb-color": [{
2917
+ "scrollbar-thumb": g()
2918
+ }],
2919
+ /**
2920
+ * Scrollbar Track Color
2921
+ * @see https://tailwindcss.com/docs/scrollbar-color
2922
+ */
2923
+ "scrollbar-track-color": [{
2924
+ "scrollbar-track": g()
2925
+ }],
2926
+ /**
2927
+ * Scrollbar Gutter
2928
+ * @see https://tailwindcss.com/docs/scrollbar-gutter
2929
+ */
2930
+ "scrollbar-gutter": [{
2931
+ "scrollbar-gutter": ["auto", "stable", "both"]
2932
+ }],
2933
+ /**
2934
+ * Scrollbar Width
2935
+ * @see https://tailwindcss.com/docs/scrollbar-width
2936
+ */
2937
+ "scrollbar-w": [{
2938
+ scrollbar: ["auto", "thin", "none"]
2939
+ }],
2940
+ /**
2941
+ * Scroll Margin
2942
+ * @see https://tailwindcss.com/docs/scroll-margin
2943
+ */
2944
+ "scroll-m": [{
2945
+ "scroll-m": p()
2946
+ }],
2947
+ /**
2948
+ * Scroll Margin Inline
2949
+ * @see https://tailwindcss.com/docs/scroll-margin
2950
+ */
2951
+ "scroll-mx": [{
2952
+ "scroll-mx": p()
2953
+ }],
2954
+ /**
2955
+ * Scroll Margin Block
2956
+ * @see https://tailwindcss.com/docs/scroll-margin
2957
+ */
2958
+ "scroll-my": [{
2959
+ "scroll-my": p()
2960
+ }],
2961
+ /**
2962
+ * Scroll Margin Inline Start
2963
+ * @see https://tailwindcss.com/docs/scroll-margin
2964
+ */
2965
+ "scroll-ms": [{
2966
+ "scroll-ms": p()
2967
+ }],
2968
+ /**
2969
+ * Scroll Margin Inline End
2970
+ * @see https://tailwindcss.com/docs/scroll-margin
2971
+ */
2972
+ "scroll-me": [{
2973
+ "scroll-me": p()
2974
+ }],
2975
+ /**
2976
+ * Scroll Margin Block Start
2977
+ * @see https://tailwindcss.com/docs/scroll-margin
2978
+ */
2979
+ "scroll-mbs": [{
2980
+ "scroll-mbs": p()
2981
+ }],
2982
+ /**
2983
+ * Scroll Margin Block End
2984
+ * @see https://tailwindcss.com/docs/scroll-margin
2985
+ */
2986
+ "scroll-mbe": [{
2987
+ "scroll-mbe": p()
2988
+ }],
2989
+ /**
2990
+ * Scroll Margin Top
2991
+ * @see https://tailwindcss.com/docs/scroll-margin
2992
+ */
2993
+ "scroll-mt": [{
2994
+ "scroll-mt": p()
2995
+ }],
2996
+ /**
2997
+ * Scroll Margin Right
2998
+ * @see https://tailwindcss.com/docs/scroll-margin
2999
+ */
3000
+ "scroll-mr": [{
3001
+ "scroll-mr": p()
3002
+ }],
3003
+ /**
3004
+ * Scroll Margin Bottom
3005
+ * @see https://tailwindcss.com/docs/scroll-margin
3006
+ */
3007
+ "scroll-mb": [{
3008
+ "scroll-mb": p()
3009
+ }],
3010
+ /**
3011
+ * Scroll Margin Left
3012
+ * @see https://tailwindcss.com/docs/scroll-margin
3013
+ */
3014
+ "scroll-ml": [{
3015
+ "scroll-ml": p()
3016
+ }],
3017
+ /**
3018
+ * Scroll Padding
3019
+ * @see https://tailwindcss.com/docs/scroll-padding
3020
+ */
3021
+ "scroll-p": [{
3022
+ "scroll-p": p()
3023
+ }],
3024
+ /**
3025
+ * Scroll Padding Inline
3026
+ * @see https://tailwindcss.com/docs/scroll-padding
3027
+ */
3028
+ "scroll-px": [{
3029
+ "scroll-px": p()
3030
+ }],
3031
+ /**
3032
+ * Scroll Padding Block
3033
+ * @see https://tailwindcss.com/docs/scroll-padding
3034
+ */
3035
+ "scroll-py": [{
3036
+ "scroll-py": p()
3037
+ }],
3038
+ /**
3039
+ * Scroll Padding Inline Start
3040
+ * @see https://tailwindcss.com/docs/scroll-padding
3041
+ */
3042
+ "scroll-ps": [{
3043
+ "scroll-ps": p()
3044
+ }],
3045
+ /**
3046
+ * Scroll Padding Inline End
3047
+ * @see https://tailwindcss.com/docs/scroll-padding
3048
+ */
3049
+ "scroll-pe": [{
3050
+ "scroll-pe": p()
3051
+ }],
3052
+ /**
3053
+ * Scroll Padding Block Start
3054
+ * @see https://tailwindcss.com/docs/scroll-padding
3055
+ */
3056
+ "scroll-pbs": [{
3057
+ "scroll-pbs": p()
3058
+ }],
3059
+ /**
3060
+ * Scroll Padding Block End
3061
+ * @see https://tailwindcss.com/docs/scroll-padding
3062
+ */
3063
+ "scroll-pbe": [{
3064
+ "scroll-pbe": p()
3065
+ }],
3066
+ /**
3067
+ * Scroll Padding Top
3068
+ * @see https://tailwindcss.com/docs/scroll-padding
3069
+ */
3070
+ "scroll-pt": [{
3071
+ "scroll-pt": p()
3072
+ }],
3073
+ /**
3074
+ * Scroll Padding Right
3075
+ * @see https://tailwindcss.com/docs/scroll-padding
3076
+ */
3077
+ "scroll-pr": [{
3078
+ "scroll-pr": p()
3079
+ }],
3080
+ /**
3081
+ * Scroll Padding Bottom
3082
+ * @see https://tailwindcss.com/docs/scroll-padding
3083
+ */
3084
+ "scroll-pb": [{
3085
+ "scroll-pb": p()
3086
+ }],
3087
+ /**
3088
+ * Scroll Padding Left
3089
+ * @see https://tailwindcss.com/docs/scroll-padding
3090
+ */
3091
+ "scroll-pl": [{
3092
+ "scroll-pl": p()
3093
+ }],
3094
+ /**
3095
+ * Scroll Snap Align
3096
+ * @see https://tailwindcss.com/docs/scroll-snap-align
3097
+ */
3098
+ "snap-align": [{
3099
+ snap: ["start", "end", "center", "align-none"]
3100
+ }],
3101
+ /**
3102
+ * Scroll Snap Stop
3103
+ * @see https://tailwindcss.com/docs/scroll-snap-stop
3104
+ */
3105
+ "snap-stop": [{
3106
+ snap: ["normal", "always"]
3107
+ }],
3108
+ /**
3109
+ * Scroll Snap Type
3110
+ * @see https://tailwindcss.com/docs/scroll-snap-type
3111
+ */
3112
+ "snap-type": [{
3113
+ snap: ["none", "x", "y", "both"]
3114
+ }],
3115
+ /**
3116
+ * Scroll Snap Type Strictness
3117
+ * @see https://tailwindcss.com/docs/scroll-snap-type
3118
+ */
3119
+ "snap-strictness": [{
3120
+ snap: ["mandatory", "proximity"]
3121
+ }],
3122
+ /**
3123
+ * Touch Action
3124
+ * @see https://tailwindcss.com/docs/touch-action
3125
+ */
3126
+ touch: [{
3127
+ touch: ["auto", "none", "manipulation"]
3128
+ }],
3129
+ /**
3130
+ * Touch Action X
3131
+ * @see https://tailwindcss.com/docs/touch-action
3132
+ */
3133
+ "touch-x": [{
3134
+ "touch-pan": ["x", "left", "right"]
3135
+ }],
3136
+ /**
3137
+ * Touch Action Y
3138
+ * @see https://tailwindcss.com/docs/touch-action
3139
+ */
3140
+ "touch-y": [{
3141
+ "touch-pan": ["y", "up", "down"]
3142
+ }],
3143
+ /**
3144
+ * Touch Action Pinch Zoom
3145
+ * @see https://tailwindcss.com/docs/touch-action
3146
+ */
3147
+ "touch-pz": ["touch-pinch-zoom"],
3148
+ /**
3149
+ * User Select
3150
+ * @see https://tailwindcss.com/docs/user-select
3151
+ */
3152
+ select: [{
3153
+ select: ["none", "text", "all", "auto"]
3154
+ }],
3155
+ /**
3156
+ * Will Change
3157
+ * @see https://tailwindcss.com/docs/will-change
3158
+ */
3159
+ "will-change": [{
3160
+ "will-change": ["auto", "scroll", "contents", "transform", m, u]
3161
+ }],
3162
+ // -----------
3163
+ // --- SVG ---
3164
+ // -----------
3165
+ /**
3166
+ * Fill
3167
+ * @see https://tailwindcss.com/docs/fill
3168
+ */
3169
+ fill: [{
3170
+ fill: ["none", ...g()]
3171
+ }],
3172
+ /**
3173
+ * Stroke Width
3174
+ * @see https://tailwindcss.com/docs/stroke-width
3175
+ */
3176
+ "stroke-w": [{
3177
+ stroke: [y, ye, le, Ye]
3178
+ }],
3179
+ /**
3180
+ * Stroke
3181
+ * @see https://tailwindcss.com/docs/stroke
3182
+ */
3183
+ stroke: [{
3184
+ stroke: ["none", ...g()]
3185
+ }],
3186
+ // ---------------------
3187
+ // --- Accessibility ---
3188
+ // ---------------------
3189
+ /**
3190
+ * Forced Color Adjust
3191
+ * @see https://tailwindcss.com/docs/forced-color-adjust
3192
+ */
3193
+ "forced-color-adjust": [{
3194
+ "forced-color-adjust": ["auto", "none"]
3195
+ }]
3196
+ },
3197
+ conflictingClassGroups: {
3198
+ "container-named": ["container-type"],
3199
+ overflow: ["overflow-x", "overflow-y"],
3200
+ overscroll: ["overscroll-x", "overscroll-y"],
3201
+ inset: ["inset-x", "inset-y", "inset-bs", "inset-be", "start", "end", "top", "right", "bottom", "left"],
3202
+ "inset-x": ["start", "end", "right", "left"],
3203
+ "inset-y": ["inset-bs", "inset-be", "top", "bottom"],
3204
+ flex: ["basis", "grow", "shrink"],
3205
+ gap: ["gap-x", "gap-y"],
3206
+ p: ["px", "py", "ps", "pe", "pbs", "pbe", "pt", "pr", "pb", "pl"],
3207
+ px: ["ps", "pe", "pr", "pl"],
3208
+ py: ["pbs", "pbe", "pt", "pb"],
3209
+ m: ["mx", "my", "ms", "me", "mbs", "mbe", "mt", "mr", "mb", "ml"],
3210
+ mx: ["ms", "me", "mr", "ml"],
3211
+ my: ["mbs", "mbe", "mt", "mb"],
3212
+ size: ["w", "h"],
3213
+ "font-size": ["leading"],
3214
+ "fvn-normal": ["fvn-ordinal", "fvn-slashed-zero", "fvn-figure", "fvn-spacing", "fvn-fraction"],
3215
+ "fvn-ordinal": ["fvn-normal"],
3216
+ "fvn-slashed-zero": ["fvn-normal"],
3217
+ "fvn-figure": ["fvn-normal"],
3218
+ "fvn-spacing": ["fvn-normal"],
3219
+ "fvn-fraction": ["fvn-normal"],
3220
+ "line-clamp": ["display", "overflow"],
3221
+ rounded: ["rounded-s", "rounded-e", "rounded-t", "rounded-r", "rounded-b", "rounded-l", "rounded-ss", "rounded-se", "rounded-ee", "rounded-es", "rounded-tl", "rounded-tr", "rounded-br", "rounded-bl"],
3222
+ "rounded-s": ["rounded-ss", "rounded-es"],
3223
+ "rounded-e": ["rounded-se", "rounded-ee"],
3224
+ "rounded-t": ["rounded-tl", "rounded-tr"],
3225
+ "rounded-r": ["rounded-tr", "rounded-br"],
3226
+ "rounded-b": ["rounded-br", "rounded-bl"],
3227
+ "rounded-l": ["rounded-tl", "rounded-bl"],
3228
+ "border-spacing": ["border-spacing-x", "border-spacing-y"],
3229
+ "border-w": ["border-w-x", "border-w-y", "border-w-s", "border-w-e", "border-w-bs", "border-w-be", "border-w-t", "border-w-r", "border-w-b", "border-w-l"],
3230
+ "border-w-x": ["border-w-s", "border-w-e", "border-w-r", "border-w-l"],
3231
+ "border-w-y": ["border-w-bs", "border-w-be", "border-w-t", "border-w-b"],
3232
+ "border-color": ["border-color-x", "border-color-y", "border-color-s", "border-color-e", "border-color-bs", "border-color-be", "border-color-t", "border-color-r", "border-color-b", "border-color-l"],
3233
+ "border-color-x": ["border-color-s", "border-color-e", "border-color-r", "border-color-l"],
3234
+ "border-color-y": ["border-color-bs", "border-color-be", "border-color-t", "border-color-b"],
3235
+ translate: ["translate-x", "translate-y", "translate-none"],
3236
+ "translate-none": ["translate", "translate-x", "translate-y", "translate-z"],
3237
+ "scroll-m": ["scroll-mx", "scroll-my", "scroll-ms", "scroll-me", "scroll-mbs", "scroll-mbe", "scroll-mt", "scroll-mr", "scroll-mb", "scroll-ml"],
3238
+ "scroll-mx": ["scroll-ms", "scroll-me", "scroll-mr", "scroll-ml"],
3239
+ "scroll-my": ["scroll-mbs", "scroll-mbe", "scroll-mt", "scroll-mb"],
3240
+ "scroll-p": ["scroll-px", "scroll-py", "scroll-ps", "scroll-pe", "scroll-pbs", "scroll-pbe", "scroll-pt", "scroll-pr", "scroll-pb", "scroll-pl"],
3241
+ "scroll-px": ["scroll-ps", "scroll-pe", "scroll-pr", "scroll-pl"],
3242
+ "scroll-py": ["scroll-pbs", "scroll-pbe", "scroll-pt", "scroll-pb"],
3243
+ touch: ["touch-x", "touch-y", "touch-pz"],
3244
+ "touch-x": ["touch"],
3245
+ "touch-y": ["touch"],
3246
+ "touch-pz": ["touch"]
3247
+ },
3248
+ conflictingClassGroupModifiers: {
3249
+ "font-size": ["leading"]
3250
+ },
3251
+ postfixLookupClassGroups: ["container-type"],
3252
+ orderSensitiveModifiers: ["*", "**", "after", "backdrop", "before", "details-content", "file", "first-letter", "first-line", "marker", "placeholder", "selection"]
3253
+ };
3254
+ }, Bo = /* @__PURE__ */ No(Uo);
3255
+ function H(...e) {
3256
+ return Bo(pt(e));
3257
+ }
3258
+ const Wo = {
3259
+ neutral: "",
3260
+ accent: "bg-accent-soft text-accent-ink",
3261
+ info: "bg-info-soft text-info",
3262
+ warn: "bg-warn-soft text-warn",
3263
+ danger: "bg-danger-soft text-danger",
3264
+ success: "bg-success-soft text-success"
3265
+ }, Ko = gt(
3266
+ "inline-flex max-w-full items-center whitespace-nowrap rounded-full bg-sunken px-2 py-0.5 font-mono text-xs text-faint",
3267
+ {
3268
+ variants: { tone: Wo },
3269
+ defaultVariants: { tone: "neutral" }
3270
+ }
3271
+ );
3272
+ function Yo({ tone: e, className: t, ...o }) {
3273
+ return /* @__PURE__ */ a("span", { ...o, className: H(Ko({ tone: e }), t) });
3274
+ }
3275
+ const Jo = {
3276
+ plain: "bg-sunken text-ink tint-hover tint-press",
3277
+ primary: "bg-accent text-surface hover:bg-accent-ink active:bg-accent-ink",
3278
+ danger: "bg-danger text-surface tint-hover tint-press",
3279
+ dangerGhost: "bg-transparent text-danger hover:bg-danger-soft",
3280
+ link: "bg-transparent p-0 text-accent underline underline-offset-2 hover:text-accent-ink",
3281
+ chip: "rounded-full bg-transparent text-muted hover:bg-hover hover:text-ink aria-pressed:bg-accent-soft aria-pressed:text-accent-ink"
3282
+ }, Zo = {
3283
+ // 默认内边距在 base:`link` / `chip` variant 可以整体覆盖。
3284
+ normal: "",
3285
+ small: "px-2.5 py-1 text-xs"
3286
+ }, Xo = gt(
3287
+ // L2 基础:形状、排版、focus、触控目标与 disabled 只在这里定义一次。
3288
+ "inline-flex items-center justify-center gap-1.5 whitespace-nowrap rounded-sm px-3 py-2 text-sm tracking-wide transition-colors duration-150 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-accent focus-visible:ring-offset-2 focus-visible:ring-offset-surface pointer-coarse:min-h-touch forced-colors:border disabled:opacity-45 disabled:cursor-not-allowed",
3289
+ {
3290
+ variants: {
3291
+ variant: Jo,
3292
+ size: Zo
3293
+ },
3294
+ defaultVariants: { variant: "plain", size: "normal" }
3295
+ }
3296
+ ), ce = fe(function({ variant: t, size: o, type: r = "button", className: n, children: s, ...i }, d) {
3297
+ return /* @__PURE__ */ a("button", { ...i, ref: d, type: r, className: H(Xo({ variant: t, size: o }), n), children: s });
3298
+ }), Oe = "w-full min-w-0 rounded-sm border-0 bg-sunken px-2.75 py-2 text-md text-ink shadow-elev-inset transition-colors placeholder:text-faint focus:outline-none focus:shadow-focus pointer-coarse:min-h-touch disabled:cursor-not-allowed disabled:opacity-45 forced-colors:border", $e = "bg-danger-soft text-danger";
3299
+ function Se({
3300
+ label: e,
3301
+ htmlFor: t,
3302
+ hint: o,
3303
+ error: r,
3304
+ required: n,
3305
+ className: s,
3306
+ children: i,
3307
+ ...d
3308
+ }) {
3309
+ return /* @__PURE__ */ R("div", { ...d, className: H("flex min-w-0 flex-col gap-1.25", s), children: [
3310
+ e != null ? /* @__PURE__ */ R(
3311
+ "label",
3312
+ {
3313
+ htmlFor: t,
3314
+ className: "font-mono text-2xs uppercase tracking-widest text-faint",
3315
+ children: [
3316
+ e,
3317
+ n ? /* @__PURE__ */ a("span", { "aria-hidden": "true", className: "text-danger", children: " *" }) : null
3318
+ ]
3319
+ }
3320
+ ) : null,
3321
+ i,
3322
+ o != null ? /* @__PURE__ */ a("span", { className: "text-xs text-faint wrap-anywhere", children: o }) : null,
3323
+ r != null ? /* @__PURE__ */ a("span", { role: "alert", className: "text-xs text-danger leading-snug", children: r }) : null
3324
+ ] });
3325
+ }
3326
+ fe(function({ invalid: t, className: o, "aria-invalid": r, ...n }, s) {
3327
+ return /* @__PURE__ */ a(
3328
+ "input",
3329
+ {
3330
+ ...n,
3331
+ ref: s,
3332
+ "aria-invalid": t ? !0 : r,
3333
+ className: H(Oe, t && $e, o)
3334
+ }
3335
+ );
3336
+ });
3337
+ function zt(e) {
3338
+ return typeof e == "string" || typeof e == "number" ? String(e) : Array.isArray(e) ? e.map(zt).join("") : "";
3339
+ }
3340
+ function Qo(e) {
3341
+ const t = [], o = (r) => {
3342
+ if (r == null || typeof r == "boolean") return;
3343
+ if (Array.isArray(r)) {
3344
+ for (const d of r) o(d);
3345
+ return;
3346
+ }
3347
+ if (!Kt(r)) return;
3348
+ if (r.type === Yt) {
3349
+ o(r.props.children);
3350
+ return;
3351
+ }
3352
+ if (r.type !== "option") return;
3353
+ const n = r.props, s = zt(n.children).trim(), i = n.value != null ? String(n.value) : s;
3354
+ t.push({
3355
+ key: `${t.length}:${typeof r.key == "string" ? r.key : i}`,
3356
+ value: i,
3357
+ label: n.children,
3358
+ text: s,
3359
+ disabled: !!n.disabled
3360
+ });
3361
+ };
3362
+ return o(e), t;
3363
+ }
3364
+ function Re(e, t, o) {
3365
+ if (e.length === 0) return -1;
3366
+ let r = t;
3367
+ for (let n = 0; n < e.length; n += 1)
3368
+ if (r = (r + o + e.length) % e.length, !e[r]?.disabled) return r;
3369
+ return -1;
3370
+ }
3371
+ function er(e, t) {
3372
+ const o = e.findIndex((r) => r.value === t);
3373
+ return o >= 0 && !e[o]?.disabled ? o : Re(e, -1, 1);
3374
+ }
3375
+ const Xe = typeof window > "u" ? Q : Wt, tr = fe(function({
3376
+ invalid: t,
3377
+ className: o,
3378
+ "aria-invalid": r,
3379
+ "aria-label": n,
3380
+ children: s,
3381
+ value: i,
3382
+ defaultValue: d,
3383
+ onChange: c,
3384
+ disabled: l,
3385
+ required: f,
3386
+ id: b,
3387
+ name: w,
3388
+ footer: C,
3389
+ popupMinWidth: P,
3390
+ prefix: v,
3391
+ ...M
3392
+ }, z) {
3393
+ const h = Qo(s), [T, O] = V(
3394
+ () => d != null ? String(d) : ""
3395
+ ), E = i !== void 0 ? String(i) : T, j = h.find((k) => k.value === E), [A, p] = V(!1), [L, U] = V(-1), [B, J] = V(null), K = q(null), x = q(null), _ = q([]), F = Ut(), W = (k) => `${F}-option-${k}`;
3396
+ Bt(z, () => K.current, []);
3397
+ const Z = Y((k) => {
3398
+ p(!1), U(-1), k && K.current?.focus();
3399
+ }, []), ue = (k) => {
3400
+ k.disabled || (i === void 0 && O(k.value), p(!1), U(-1), K.current?.focus(), k.value !== E && c?.({
3401
+ target: { value: k.value, name: w },
3402
+ currentTarget: { value: k.value, name: w }
3403
+ }));
3404
+ }, g = Y(() => {
3405
+ const k = K.current;
3406
+ if (!k) return;
3407
+ const S = k.getBoundingClientRect(), N = window.innerWidth, D = window.innerHeight, re = Math.min(Math.max(S.width, P ?? 0), N - 16), be = Math.max(8, Math.min(S.left, N - re - 8)), I = x.current, xe = I ? I.scrollHeight + (I.offsetHeight - I.clientHeight) : h.length * 34 + 8, me = Math.min(240, xe), ne = D - S.bottom - 8, pe = S.top - 8, ee = ne < me && pe > ne, Te = Math.max(96, Math.min(240, ee ? pe : ne)), qt = Math.min(xe, Te), je = ee ? Math.max(8, S.top - 4 - qt) : S.bottom + 4;
3408
+ J(
3409
+ (ie) => ie !== null && ie.top === je && ie.left === be && ie.width === re && ie.maxHeight === Te && ie.placeAbove === ee ? ie : { top: je, left: be, width: re, maxHeight: Te, placeAbove: ee }
3410
+ );
3411
+ }, [h.length, P]);
3412
+ Xe(() => {
3413
+ if (!A) {
3414
+ J(null);
3415
+ return;
3416
+ }
3417
+ return g(), window.addEventListener("scroll", g, !0), window.addEventListener("resize", g), () => {
3418
+ window.removeEventListener("scroll", g, !0), window.removeEventListener("resize", g);
3419
+ };
3420
+ }, [A, g]), Xe(() => {
3421
+ A && B !== null && x.current && g();
3422
+ }, [A, B, g]), Q(() => {
3423
+ !A || L < 0 || _.current[L]?.scrollIntoView({ block: "nearest" });
3424
+ }, [A, L]), Q(() => {
3425
+ if (!A) return;
3426
+ const k = (S) => {
3427
+ const N = S.target;
3428
+ N instanceof Node && (K.current?.contains(N) || x.current?.contains(N) || Z(!1));
3429
+ };
3430
+ return document.addEventListener("mousedown", k), () => document.removeEventListener("mousedown", k);
3431
+ }, [A, Z]);
3432
+ const he = () => {
3433
+ l || h.length === 0 || (U(er(h, E)), p(!0));
3434
+ }, ke = (k) => {
3435
+ if (l) return;
3436
+ const S = k.key;
3437
+ if (!A) {
3438
+ (S === "ArrowDown" || S === "ArrowUp") && (k.preventDefault(), he());
3439
+ return;
3440
+ }
3441
+ if (S === "Escape") {
3442
+ k.preventDefault(), k.stopPropagation(), Z(!0);
3443
+ return;
3444
+ }
3445
+ if (S === "Tab") {
3446
+ Z(!1);
3447
+ return;
3448
+ }
3449
+ if (S === "Enter" || S === " ") {
3450
+ k.preventDefault();
3451
+ const N = h[L];
3452
+ N ? ue(N) : Z(!0);
3453
+ return;
3454
+ }
3455
+ if (S === "ArrowDown" || S === "ArrowUp") {
3456
+ k.preventDefault(), U(
3457
+ (N) => Re(h, N < 0 ? -1 : N, S === "ArrowDown" ? 1 : -1)
3458
+ );
3459
+ return;
3460
+ }
3461
+ if (S === "Home") {
3462
+ k.preventDefault(), U(Re(h, -1, 1));
3463
+ return;
3464
+ }
3465
+ S === "End" && (k.preventDefault(), U(Re(h, 0, -1)));
3466
+ };
3467
+ return /* @__PURE__ */ R(Ee, { children: [
3468
+ /* @__PURE__ */ R(
3469
+ "button",
3470
+ {
3471
+ ...M,
3472
+ ref: K,
3473
+ id: b,
3474
+ type: "button",
3475
+ role: "combobox",
3476
+ "aria-haspopup": "listbox",
3477
+ "aria-expanded": A,
3478
+ "aria-controls": A ? F : void 0,
3479
+ "aria-activedescendant": A && L >= 0 ? W(L) : void 0,
3480
+ "aria-invalid": t ? !0 : r,
3481
+ "aria-required": f || void 0,
3482
+ "aria-label": n,
3483
+ disabled: l,
3484
+ className: H(
3485
+ Oe,
3486
+ "flex items-center justify-between gap-2 text-left",
3487
+ t && $e,
3488
+ o
3489
+ ),
3490
+ onClick: () => {
3491
+ A ? Z(!0) : he();
3492
+ },
3493
+ onKeyDown: ke,
3494
+ children: [
3495
+ v != null ? /* @__PURE__ */ a("span", { "aria-hidden": "true", className: "flex-none text-faint", children: v }) : null,
3496
+ /* @__PURE__ */ a("span", { className: "truncate", children: j ? j.label : null }),
3497
+ /* @__PURE__ */ a(
3498
+ "svg",
3499
+ {
3500
+ "aria-hidden": "true",
3501
+ viewBox: "0 0 12 12",
3502
+ className: H("size-3 flex-none text-faint transition-transform", A && "rotate-180"),
3503
+ fill: "none",
3504
+ stroke: "currentColor",
3505
+ strokeWidth: "1.5",
3506
+ strokeLinecap: "round",
3507
+ strokeLinejoin: "round",
3508
+ children: /* @__PURE__ */ a("path", { d: "M2.5 4.5 6 8l3.5-3.5" })
3509
+ }
3510
+ )
3511
+ ]
3512
+ }
3513
+ ),
3514
+ A && B !== null ? Jt(
3515
+ /* @__PURE__ */ R(
3516
+ "div",
3517
+ {
3518
+ ref: x,
3519
+ className: "fixed z-tooltip flex flex-col overflow-y-auto overscroll-contain rounded-md border border-line bg-raised p-1 shadow-elev-3",
3520
+ style: {
3521
+ top: B.top,
3522
+ left: B.left,
3523
+ width: B.width,
3524
+ maxHeight: B.maxHeight
3525
+ },
3526
+ children: [
3527
+ /* @__PURE__ */ a(
3528
+ "div",
3529
+ {
3530
+ id: F,
3531
+ role: "listbox",
3532
+ "aria-labelledby": b,
3533
+ "aria-label": b == null ? n : void 0,
3534
+ tabIndex: -1,
3535
+ className: "flex flex-col",
3536
+ children: h.map((k, S) => {
3537
+ const N = k.value === E;
3538
+ return (
3539
+ // biome-ignore lint/a11y/useFocusableInteractive: aria-activedescendant 模式下选项不接收焦点
3540
+ // biome-ignore lint/a11y/useKeyWithClickEvents: 键盘交互在触发器上(combobox 模式)
3541
+ /* @__PURE__ */ a(
3542
+ "div",
3543
+ {
3544
+ ref: (D) => {
3545
+ _.current[S] = D;
3546
+ },
3547
+ id: W(S),
3548
+ role: "option",
3549
+ "aria-selected": N,
3550
+ "aria-disabled": k.disabled || void 0,
3551
+ className: H(
3552
+ "flex min-h-8 cursor-pointer items-center rounded-sm px-2.5 py-1.75 text-left text-md text-ink transition-colors pointer-coarse:min-h-touch",
3553
+ S === L && "bg-hover",
3554
+ N && "bg-accent-soft text-accent-ink",
3555
+ k.disabled && "cursor-not-allowed opacity-45"
3556
+ ),
3557
+ onMouseDown: (D) => D.preventDefault(),
3558
+ onPointerEnter: () => {
3559
+ k.disabled || U(S);
3560
+ },
3561
+ onClick: () => ue(k),
3562
+ children: /* @__PURE__ */ a("span", { className: "truncate", children: k.label })
3563
+ },
3564
+ k.key
3565
+ )
3566
+ );
3567
+ })
3568
+ }
3569
+ ),
3570
+ C != null ? /* @__PURE__ */ a("div", { className: "mt-1 border-t border-line px-2.5 pt-1.5 pb-0.5 text-xs text-faint wrap-anywhere", children: C }) : null
3571
+ ]
3572
+ }
3573
+ ),
3574
+ document.body
3575
+ ) : null
3576
+ ] });
3577
+ });
3578
+ fe(function({ invalid: t, className: o, "aria-invalid": r, ...n }, s) {
3579
+ return /* @__PURE__ */ a(
3580
+ "textarea",
3581
+ {
3582
+ ...n,
3583
+ ref: s,
3584
+ "aria-invalid": t ? !0 : r,
3585
+ className: H(Oe, t && $e, o)
3586
+ }
3587
+ );
3588
+ });
3589
+ const Qe = {
3590
+ wide: "max-wide:hidden",
3591
+ compact: "max-compact:hidden"
3592
+ };
3593
+ function Ge({
3594
+ columns: e,
3595
+ rows: t,
3596
+ rowKey: o,
3597
+ activeKey: r,
3598
+ className: n,
3599
+ stickyHeader: s = !1,
3600
+ sort: i,
3601
+ onSortChange: d
3602
+ }) {
3603
+ return /* @__PURE__ */ R(
3604
+ "table",
3605
+ {
3606
+ className: H(
3607
+ "w-full rounded-md border-separate border-spacing-y-px bg-bg text-md dark:bg-deep",
3608
+ n
3609
+ ),
3610
+ children: [
3611
+ /* @__PURE__ */ a("thead", { children: /* @__PURE__ */ a("tr", { children: e.map((c) => {
3612
+ const l = c.sortable && i?.key === c.key && i.direction === "asc", f = c.sortable && i?.key === c.key && i.direction === "desc";
3613
+ return /* @__PURE__ */ a(
3614
+ "th",
3615
+ {
3616
+ scope: "col",
3617
+ "aria-sort": c.sortable ? l ? "ascending" : f ? "descending" : "none" : void 0,
3618
+ className: H(
3619
+ "h-10 bg-sunken px-2.5 py-2 text-left align-middle font-mono text-xs font-medium tracking-wide text-faint uppercase wrap-anywhere dark:bg-raised max-compact:px-1.5 first:rounded-tl-md last:rounded-tr-md",
3620
+ s && "sticky top-0 z-1",
3621
+ c.hide && Qe[c.hide]
3622
+ ),
3623
+ children: c.headerFilter ? c.headerFilter(c.header) : c.sortable ? /* @__PURE__ */ R(
3624
+ "button",
3625
+ {
3626
+ type: "button",
3627
+ onClick: () => d?.(c.key),
3628
+ className: "inline-flex cursor-pointer items-center gap-1 bg-transparent p-0 text-left font-mono text-xs font-medium tracking-wide uppercase text-inherit hover:text-ink",
3629
+ children: [
3630
+ c.header,
3631
+ /* @__PURE__ */ R("span", { "aria-hidden": "true", className: "inline-flex flex-none items-center gap-0.5", children: [
3632
+ /* @__PURE__ */ a("span", { className: l ? "text-accent" : "text-faint", children: "↑" }),
3633
+ /* @__PURE__ */ a("span", { className: f ? "text-accent" : "text-faint", children: "↓" })
3634
+ ] })
3635
+ ]
3636
+ }
3637
+ ) : c.header
3638
+ },
3639
+ c.key
3640
+ );
3641
+ }) }) }),
3642
+ /* @__PURE__ */ a("tbody", { children: t.map((c, l) => {
3643
+ const f = o(c), b = l === t.length - 1;
3644
+ return /* @__PURE__ */ a(
3645
+ "tr",
3646
+ {
3647
+ "data-active": f === r || void 0,
3648
+ className: "group data-[active=true]:text-accent-ink",
3649
+ children: e.map((w, C) => /* @__PURE__ */ a(
3650
+ "td",
3651
+ {
3652
+ className: H(
3653
+ "h-10 bg-raised px-2.5 py-2 align-middle wrap-anywhere group-hover:bg-hover group-data-[active=true]:bg-accent-soft dark:bg-sunken max-compact:px-1.5",
3654
+ C === 0 && b && "rounded-bl-md",
3655
+ C === e.length - 1 && b && "rounded-br-md",
3656
+ C === e.length - 1 && "whitespace-nowrap max-wide:whitespace-normal",
3657
+ w.hide && Qe[w.hide],
3658
+ w.cellClassName
3659
+ ),
3660
+ children: w.cell(c)
3661
+ },
3662
+ w.key
3663
+ ))
3664
+ },
3665
+ f
3666
+ );
3667
+ }) })
3668
+ ]
3669
+ }
3670
+ );
3671
+ }
3672
+ function Tt({ title: e, subtitle: t, children: o, className: r }) {
3673
+ return /* @__PURE__ */ R(
3674
+ "div",
3675
+ {
3676
+ className: H(
3677
+ "mx-auto flex w-full max-w-[var(--content-max)] flex-col p-6 pb-10 max-compact:px-3 max-compact:pt-4 max-compact:pb-7",
3678
+ r
3679
+ ),
3680
+ children: [
3681
+ /* @__PURE__ */ R("header", { className: "flex flex-col gap-2.5", children: [
3682
+ /* @__PURE__ */ a("h1", { className: "font-serif text-title font-semibold leading-tight tracking-wide text-ink", children: e }),
3683
+ t != null && t !== "" ? /* @__PURE__ */ a("p", { className: "max-w-prose text-md leading-normal text-muted", children: t }) : null
3684
+ ] }),
3685
+ /* @__PURE__ */ a("div", { className: "mt-5 flex flex-col gap-5", children: o })
3686
+ ]
3687
+ }
3688
+ );
3689
+ }
3690
+ const et = fe(function({ value: t, onChange: o, placeholder: r, ariaLabel: n, className: s }, i) {
3691
+ return /* @__PURE__ */ a(
3692
+ "input",
3693
+ {
3694
+ ref: i,
3695
+ className: H(
3696
+ "h-control w-full min-w-0 rounded-sm border-0 bg-sunken px-3 text-sm text-ink shadow-elev-inset transition-colors placeholder:text-faint focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-accent focus-visible:ring-offset-2 focus-visible:ring-offset-surface",
3697
+ s
3698
+ ),
3699
+ type: "search",
3700
+ value: t,
3701
+ onChange: (d) => o(d.target.value),
3702
+ placeholder: r,
3703
+ "aria-label": n,
3704
+ spellCheck: !1
3705
+ }
3706
+ );
3707
+ }), Lt = fe(function({ title: t, description: o, actions: r, titleAs: n = "h2", className: s, children: i, ...d }, c) {
3708
+ const l = n, f = t != null || o != null || r != null;
3709
+ return /* @__PURE__ */ R(
3710
+ "section",
3711
+ {
3712
+ ref: c,
3713
+ ...d,
3714
+ className: H(
3715
+ "rounded-md bg-raised px-4.5 py-4 shadow-elev-1 max-compact:px-4 forced-colors:border",
3716
+ s
3717
+ ),
3718
+ children: [
3719
+ f ? /* @__PURE__ */ R("div", { className: "flex flex-wrap items-center gap-2.5", children: [
3720
+ t != null || o != null ? /* @__PURE__ */ R("div", { className: "min-w-0", children: [
3721
+ t != null ? /* @__PURE__ */ a(l, { className: "text-md font-semibold text-ink", children: t }) : null,
3722
+ o != null ? /* @__PURE__ */ a("p", { className: "mt-1.5 max-w-prose text-md text-muted", children: o }) : null
3723
+ ] }) : null,
3724
+ r
3725
+ ] }) : null,
3726
+ i != null ? /* @__PURE__ */ a("div", { className: f ? "mt-2.5" : void 0, children: i }) : null
3727
+ ]
3728
+ }
3729
+ );
3730
+ });
3731
+ function or({ label: e, value: t, hint: o, className: r, ...n }) {
3732
+ return /* @__PURE__ */ R(
3733
+ "div",
3734
+ {
3735
+ ...n,
3736
+ className: H(
3737
+ "flex flex-col gap-0.5 rounded-md bg-raised px-3.5 py-3 shadow-elev-1 forced-colors:border",
3738
+ r
3739
+ ),
3740
+ children: [
3741
+ /* @__PURE__ */ a("span", { className: "font-mono text-xl tabular-nums text-ink wrap-anywhere", children: t }),
3742
+ /* @__PURE__ */ a("span", { className: "text-xs tracking-wider text-faint", children: e }),
3743
+ o != null ? /* @__PURE__ */ a("span", { className: "text-xs text-faint", children: o }) : null
3744
+ ]
3745
+ }
3746
+ );
3747
+ }
3748
+ function It({ children: e, label: t, className: o }) {
3749
+ return /* @__PURE__ */ a(
3750
+ "div",
3751
+ {
3752
+ role: "toolbar",
3753
+ "aria-label": t,
3754
+ className: H("mb-2 flex flex-wrap items-center gap-2", o),
3755
+ children: e
3756
+ }
3757
+ );
3758
+ }
3759
+ function rr({
3760
+ label: e,
3761
+ tabs: t,
3762
+ value: o,
3763
+ onChange: r,
3764
+ panelId: n,
3765
+ disabled: s = !1,
3766
+ className: i
3767
+ }) {
3768
+ const d = q(/* @__PURE__ */ new Map());
3769
+ return /* @__PURE__ */ a(
3770
+ "div",
3771
+ {
3772
+ className: H(
3773
+ "mt-3.5 inline-flex shrink-0 max-w-full gap-0.5 overflow-x-auto rounded-full bg-sunken p-1",
3774
+ s && "opacity-45",
3775
+ i
3776
+ ),
3777
+ role: "tablist",
3778
+ "aria-label": e,
3779
+ "aria-disabled": s || void 0,
3780
+ children: t.map((c) => /* @__PURE__ */ a(
3781
+ "button",
3782
+ {
3783
+ ref: (l) => {
3784
+ l ? d.current.set(c.id, l) : d.current.delete(c.id);
3785
+ },
3786
+ type: "button",
3787
+ role: "tab",
3788
+ id: n ? `${n}-tab-${c.id}` : void 0,
3789
+ "aria-controls": n,
3790
+ "aria-selected": c.id === o,
3791
+ disabled: s,
3792
+ tabIndex: s ? -1 : c.id === o ? 0 : -1,
3793
+ className: "whitespace-nowrap rounded-full bg-transparent px-3 py-1.5 text-sm text-muted transition-colors hover:bg-hover hover:text-ink aria-selected:bg-accent-soft aria-selected:text-accent-ink disabled:cursor-not-allowed disabled:hover:bg-transparent disabled:hover:text-muted pointer-coarse:min-h-touch",
3794
+ onClick: () => r(c.id),
3795
+ onKeyDown: (l) => {
3796
+ if (s) return;
3797
+ const f = t.findIndex((C) => C.id === c.id);
3798
+ if (l.key !== "ArrowRight" && l.key !== "ArrowLeft") return;
3799
+ l.preventDefault();
3800
+ const b = l.key === "ArrowRight" ? 1 : -1, w = t[(f + b + t.length) % t.length];
3801
+ w && (r(w.id), d.current.get(w.id)?.focus());
3802
+ },
3803
+ children: c.label
3804
+ },
3805
+ c.id
3806
+ ))
3807
+ }
3808
+ );
3809
+ }
3810
+ function Ce(e) {
3811
+ return e.status === "ready" || e.status === "revalidating" || e.status === "stale";
3812
+ }
3813
+ function nr(e) {
3814
+ return e instanceof Error ? e : new Error(String(e));
3815
+ }
3816
+ function sr() {
3817
+ return typeof window > "u" ? void 0 : window;
3818
+ }
3819
+ function ar() {
3820
+ return typeof document > "u" ? void 0 : document;
3821
+ }
3822
+ function Pt({
3823
+ load: e,
3824
+ queryKey: t,
3825
+ intervalMs: o,
3826
+ refreshKey: r = 0,
3827
+ pauseWhenHidden: n = !0,
3828
+ enabled: s = !0
3829
+ }) {
3830
+ const [i, d] = V({ status: "loading" }), c = q(0), l = q(!1), f = q(!0), b = q(void 0), w = q(e);
3831
+ w.current = e;
3832
+ const C = q(s);
3833
+ C.current = s;
3834
+ const P = JSON.stringify(t ?? []);
3835
+ Q(() => (f.current = !0, () => {
3836
+ f.current = !1;
3837
+ }), []);
3838
+ const v = Y(() => {
3839
+ if (!C.current || l.current) return;
3840
+ const h = ++c.current;
3841
+ l.current = !0, d(
3842
+ (T) => Ce(T) ? { status: "revalidating", data: T.data, updatedAt: T.updatedAt } : { status: "loading" }
3843
+ ), w.current().then(
3844
+ (T) => {
3845
+ !f.current || h !== c.current || (l.current = !1, d({ status: "ready", data: T, updatedAt: Date.now() }));
3846
+ },
3847
+ (T) => {
3848
+ if (!f.current || h !== c.current) return;
3849
+ l.current = !1;
3850
+ const O = nr(T);
3851
+ d(
3852
+ (E) => Ce(E) ? { status: "stale", data: E.data, updatedAt: E.updatedAt, error: O } : { status: "error", error: O }
3853
+ );
3854
+ }
3855
+ );
3856
+ }, []), M = Y(() => {
3857
+ v();
3858
+ }, [v]);
3859
+ Q(() => {
3860
+ c.current += 1, l.current = !1, d({ status: "loading" }), s && v();
3861
+ }, [s, P, v]);
3862
+ const z = q(r);
3863
+ return Q(() => {
3864
+ z.current !== r && (z.current = r, v());
3865
+ }, [r, v]), Q(() => {
3866
+ const h = sr(), T = ar();
3867
+ if (!s || o === void 0 || o <= 0 || !h?.setInterval) return;
3868
+ const O = () => {
3869
+ h.clearInterval?.(b.current), b.current = h.setInterval?.(v, o);
3870
+ }, E = () => {
3871
+ h.clearInterval?.(b.current), b.current = void 0;
3872
+ };
3873
+ if (!n || !T?.addEventListener)
3874
+ return O(), E;
3875
+ T.visibilityState !== "hidden" && O();
3876
+ const j = () => {
3877
+ E(), T.visibilityState !== "hidden" && (v(), O());
3878
+ };
3879
+ return T.addEventListener("visibilitychange", j), () => {
3880
+ T.removeEventListener?.("visibilitychange", j), E();
3881
+ };
3882
+ }, [s, o, n, v]), {
3883
+ data: Ce(i) ? i.data : void 0,
3884
+ error: i.status === "error" || i.status === "stale" ? i.error : void 0,
3885
+ isLoading: i.status === "loading",
3886
+ isRefreshing: i.status === "revalidating",
3887
+ updatedAt: Ce(i) ? i.updatedAt : void 0,
3888
+ reload: M
3889
+ };
3890
+ }
3891
+ const oe = "—";
3892
+ function G(e) {
3893
+ return typeof e == "number" && Number.isFinite(e) ? e.toLocaleString("en-US") : oe;
3894
+ }
3895
+ function tt(e) {
3896
+ if (typeof e != "number" || !Number.isFinite(e) || e < 0) return oe;
3897
+ let t = e * 100;
3898
+ return t >= 99.95 && (t = 100), `${(Math.round(t * 10) / 10).toFixed(1).replace(/\.0$/, "")}%`;
3899
+ }
3900
+ function ze(e) {
3901
+ if (typeof e != "number" || !Number.isFinite(e) || e < 0) return oe;
3902
+ if (e === 0) return "$0";
3903
+ const t = e < 0.01 ? 6 : 4;
3904
+ return `$${e.toFixed(t).replace(/0+$/, "").replace(/\.$/, "")}`;
3905
+ }
3906
+ function ir(e) {
3907
+ return typeof e != "number" || !Number.isFinite(e) || e < 0 ? oe : e < 1e3 ? `${Math.round(e)} ms` : `${(e / 1e3).toFixed(2)} s`;
3908
+ }
3909
+ function we(e) {
3910
+ return String(e).padStart(2, "0");
3911
+ }
3912
+ function lr(e) {
3913
+ if (typeof e != "number" || !Number.isFinite(e)) return oe;
3914
+ const t = new Date(e);
3915
+ if (!Number.isFinite(t.getTime())) return oe;
3916
+ const o = `${t.getUTCFullYear()}-${we(t.getUTCMonth() + 1)}-${we(t.getUTCDate())}`, r = `${we(t.getUTCHours())}:${we(t.getUTCMinutes())}:${we(t.getUTCSeconds())}`;
3917
+ return `${o} ${r}Z`;
3918
+ }
3919
+ function He(e) {
3920
+ if (typeof e != "number" || !Number.isFinite(e)) return oe;
3921
+ const t = new Date(e);
3922
+ return Number.isFinite(t.getTime()) ? t.toISOString() : oe;
3923
+ }
3924
+ function ot(e, t, o) {
3925
+ switch (e) {
3926
+ case "no-requests":
3927
+ return o("ratio.noRequests");
3928
+ case "no-cache-fields":
3929
+ return o("ratio.noCacheFields");
3930
+ case "zero-denominator":
3931
+ return o("ratio.zeroDenominator");
3932
+ case "prompt-not-inclusive":
3933
+ return o("ratio.promptNotInclusive");
3934
+ case "write-not-reported":
3935
+ return o("ratio.writeNotReported");
3936
+ default:
3937
+ return t;
3938
+ }
3939
+ }
3940
+ function cr(e, t) {
3941
+ const o = Number(e.unpriced_requests) || 0;
3942
+ return e.cost === void 0 && o > 0 ? t("usage.costNoPrice") : o > 0 ? t("usage.costPartial", { n: o }) : t("usage.costHint");
3943
+ }
3944
+ function Mt({
3945
+ source: e,
3946
+ t
3947
+ }) {
3948
+ if (e == null) return null;
3949
+ const o = e.files_truncated === void 0 && e.partial_files === void 0, r = e.files_truncated ?? (o ? e.truncated : !1), n = e.partial_files ?? 0, s = e.unreadable_sessions ?? 0, i = e.source_retired === !0;
3950
+ if (!r && n === 0 && !i && s === 0) return null;
3951
+ const d = e.files_in_window ?? e.files_total;
3952
+ return /* @__PURE__ */ R("div", { className: "flex flex-col gap-1 text-sm text-muted", children: [
3953
+ i ? /* @__PURE__ */ a("p", { children: t("source.retired") }) : null,
3954
+ s > 0 ? /* @__PURE__ */ a("p", { children: t("source.unreadable", { files: s }) }) : null,
3955
+ r ? /* @__PURE__ */ a("p", { children: t("logs.truncated.files", { files: e.files_read, total: d }) }) : null,
3956
+ n > 0 ? /* @__PURE__ */ a("p", { children: t("logs.truncated.partial", { files: n }) }) : null
3957
+ ] });
3958
+ }
3959
+ function dr(e) {
3960
+ return [
3961
+ { id: "1", label: e("range.1") },
3962
+ { id: "7", label: e("range.7") },
3963
+ { id: "30", label: e("range.30") },
3964
+ { id: "90", label: e("range.90") },
3965
+ { id: "0", label: e("range.0") }
3966
+ ];
3967
+ }
3968
+ function Et(e) {
3969
+ const t = Number(e);
3970
+ return t > 0 ? { days: t } : {};
3971
+ }
3972
+ function Ft({
3973
+ value: e,
3974
+ onChange: t,
3975
+ t: o
3976
+ }) {
3977
+ return /* @__PURE__ */ a(
3978
+ rr,
3979
+ {
3980
+ label: o("range.label"),
3981
+ tabs: dr(o),
3982
+ value: e,
3983
+ onChange: t,
3984
+ className: "mt-0"
3985
+ }
3986
+ );
3987
+ }
3988
+ function ur(e) {
3989
+ return e instanceof Error ? e : new Error(String(e));
3990
+ }
3991
+ function Dt({ label: e }) {
3992
+ return /* @__PURE__ */ a("p", { className: "py-6 text-md text-muted", "aria-live": "polite", children: e });
3993
+ }
3994
+ function Ot({ label: e }) {
3995
+ return /* @__PURE__ */ a(
3996
+ "span",
3997
+ {
3998
+ className: "ml-auto font-mono text-2xs uppercase tracking-widest text-faint",
3999
+ "aria-live": "polite",
4000
+ children: e
4001
+ }
4002
+ );
4003
+ }
4004
+ function $t({
4005
+ message: e,
4006
+ onRetry: t,
4007
+ retryLabel: o
4008
+ }) {
4009
+ return /* @__PURE__ */ R("div", { className: "flex flex-wrap items-center gap-2 text-sm text-warn", role: "status", children: [
4010
+ /* @__PURE__ */ a("span", { children: e }),
4011
+ /* @__PURE__ */ a(ce, { size: "small", onClick: t, children: o })
4012
+ ] });
4013
+ }
4014
+ function Pe({ title: e, description: t }) {
4015
+ return /* @__PURE__ */ a(Lt, { title: e, description: t });
4016
+ }
4017
+ function Ve({ children: e }) {
4018
+ return /* @__PURE__ */ a("div", { className: "overflow-hidden rounded-md", children: e });
4019
+ }
4020
+ function Me({
4021
+ error: e,
4022
+ onRetry: t,
4023
+ title: o,
4024
+ retryLabel: r
4025
+ }) {
4026
+ return /* @__PURE__ */ a(
4027
+ Lt,
4028
+ {
4029
+ title: o,
4030
+ description: e.message,
4031
+ actions: /* @__PURE__ */ a(ce, { variant: "primary", onClick: t, children: r })
4032
+ }
4033
+ );
4034
+ }
4035
+ const mr = 50, Gt = "7", rt = {
4036
+ session: "",
4037
+ model: "",
4038
+ status: "",
4039
+ range: Gt,
4040
+ custom: null
4041
+ };
4042
+ function _e(e) {
4043
+ if (e.trim() === "") return;
4044
+ const t = new Date(e).getTime();
4045
+ return Number.isFinite(t) ? t : void 0;
4046
+ }
4047
+ function pr(e, t) {
4048
+ switch (t) {
4049
+ case "1":
4050
+ return e("range.1");
4051
+ case "7":
4052
+ return e("range.7");
4053
+ case "30":
4054
+ return e("range.30");
4055
+ case "90":
4056
+ return e("range.90");
4057
+ default:
4058
+ return e("range.0");
4059
+ }
4060
+ }
4061
+ function nt(e) {
4062
+ const t = { limit: mr };
4063
+ if (e.custom !== null) {
4064
+ const n = _e(e.custom.from), s = _e(e.custom.to);
4065
+ n !== void 0 && (t.since = n), s !== void 0 && (t.until = s);
4066
+ } else
4067
+ Object.assign(t, Et(e.range));
4068
+ const o = e.session.trim(), r = e.model.trim();
4069
+ return o !== "" && (t.session_id = o), r !== "" && (t.model = r), e.status !== "" && (t.status = e.status), t;
4070
+ }
4071
+ function st(e) {
4072
+ const t = _e(e.from), o = _e(e.to);
4073
+ return t === void 0 && o === void 0 || e.from.trim() !== "" && t === void 0 || e.to.trim() !== "" && o === void 0 ? !0 : t !== void 0 && o !== void 0 && t >= o;
4074
+ }
4075
+ function gr(e) {
4076
+ return e === "ok" || e === "failed" ? e : "";
4077
+ }
4078
+ function at({
4079
+ id: e,
4080
+ label: t,
4081
+ value: o,
4082
+ onChange: r
4083
+ }) {
4084
+ return /* @__PURE__ */ a(Se, { label: t, htmlFor: e, className: "w-52", children: /* @__PURE__ */ a(
4085
+ "input",
4086
+ {
4087
+ id: e,
4088
+ type: "datetime-local",
4089
+ className: "h-control w-full min-w-0 rounded-sm border-0 bg-sunken px-3 text-sm text-ink shadow-elev-inset transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-accent focus-visible:ring-offset-2 focus-visible:ring-offset-surface",
4090
+ value: o,
4091
+ onChange: (n) => r(n.target.value),
4092
+ "aria-label": t
4093
+ }
4094
+ ) });
4095
+ }
4096
+ function fr({
4097
+ applied: e,
4098
+ loaded: t,
4099
+ cursor: o,
4100
+ t: r
4101
+ }) {
4102
+ const n = e.custom !== null ? r("logs.state.custom", {
4103
+ from: e.custom.from === "" ? "…" : e.custom.from,
4104
+ to: e.custom.to === "" ? "…" : e.custom.to
4105
+ }) : pr(r, e.range), s = [], i = e.model.trim(), d = e.session.trim();
4106
+ i !== "" && s.push(`${r("logs.model")}: ${i}`), d !== "" && s.push(`${r("logs.session")}: ${d}`), e.status !== "" && s.push(
4107
+ `${r("logs.status")}: ${e.status === "ok" ? r("logs.optionOk") : r("logs.optionFailed")}`
4108
+ );
4109
+ const c = `${r("logs.state.loaded", { n: t })} · ${r(o === null ? "logs.state.end" : "logs.state.more")}`;
4110
+ return /* @__PURE__ */ R("div", { className: "flex flex-wrap items-center gap-x-3 gap-y-1 text-sm text-muted", children: [
4111
+ /* @__PURE__ */ a("span", { children: r("logs.state.range", { range: n }) }),
4112
+ /* @__PURE__ */ a("span", { children: c }),
4113
+ s.length > 0 ? /* @__PURE__ */ a("span", { children: r("logs.state.conditions", { conditions: s.join(" · ") }) }) : null
4114
+ ] });
4115
+ }
4116
+ function hr(e) {
4117
+ return [
4118
+ {
4119
+ key: "time",
4120
+ header: e("logs.th.time"),
4121
+ cell: (t) => /* @__PURE__ */ a("span", { title: He(t.ts), children: lr(t.ts) })
4122
+ },
4123
+ {
4124
+ key: "status",
4125
+ header: e("logs.th.status"),
4126
+ cell: (t) => /* @__PURE__ */ a(Yo, { tone: t.status === "failed" ? "danger" : "success", children: t.status === "failed" ? e("common.status.failed") : e("common.status.ok") })
4127
+ },
4128
+ {
4129
+ key: "model",
4130
+ header: e("logs.th.model"),
4131
+ cell: (t) => /* @__PURE__ */ a("span", { title: t.model, children: t.model })
4132
+ },
4133
+ {
4134
+ key: "session",
4135
+ header: e("logs.th.session"),
4136
+ cell: (t) => /* @__PURE__ */ a("span", { className: "font-mono text-sm text-muted", children: t.session_id ?? oe })
4137
+ },
4138
+ { key: "prompt", header: e("logs.th.prompt"), cell: (t) => G(t.prompt_tokens) },
4139
+ {
4140
+ key: "completion",
4141
+ header: e("logs.th.completion"),
4142
+ cell: (t) => G(t.completion_tokens)
4143
+ },
4144
+ {
4145
+ key: "cache_read",
4146
+ header: e("logs.th.cacheRead"),
4147
+ cell: (t) => G(t.cache_read_input_tokens)
4148
+ },
4149
+ { key: "duration", header: e("logs.th.duration"), cell: (t) => ir(t.duration_ms) },
4150
+ { key: "cost", header: e("logs.th.cost"), cell: (t) => ze(t.cost) }
4151
+ ];
4152
+ }
4153
+ const br = 15e3;
4154
+ function xr({ client: e, refreshKey: t, t: o }) {
4155
+ const [r, n] = V(rt), [s, i] = V(rt), [d, c] = V(null), [l, f] = V(!1), [b, w] = V(null), [C, P] = V(!1), v = d !== null, M = q(t);
4156
+ v || (M.current = t);
4157
+ const z = Pt({
4158
+ load: () => e.call("logs", nt(s)),
4159
+ queryKey: [JSON.stringify(s)],
4160
+ intervalMs: v ? 0 : br,
4161
+ refreshKey: v ? M.current : t
4162
+ }), h = z.data, T = q(h);
4163
+ T.current = h, Q(() => {
4164
+ c(null), w(null);
4165
+ }, [h]);
4166
+ const O = h !== void 0 ? [...h.items, ...d?.items ?? []] : [], E = d !== null ? d.cursor : h?.next_cursor ?? null, j = h?.source ?? null, A = Y(() => {
4167
+ const x = r.custom !== null && st(r.custom);
4168
+ P(x), i({ ...r, custom: x ? s.custom : r.custom });
4169
+ }, [s.custom, r]), p = Y((x) => {
4170
+ P(!1), n((_) => ({ ..._, range: x, custom: null })), i((_) => ({ ..._, range: x, custom: null }));
4171
+ }, []), L = Y((x) => {
4172
+ P(!1), n((_) => ({ ..._, custom: { from: "", to: "", ..._.custom, ...x } }));
4173
+ }, []), U = Y(() => {
4174
+ const x = r.custom ?? { from: "", to: "" };
4175
+ if (st(x)) {
4176
+ P(!0);
4177
+ return;
4178
+ }
4179
+ P(!1);
4180
+ const _ = { ...r, custom: x };
4181
+ n(_), i(_);
4182
+ }, [r]), B = Y(() => {
4183
+ P(!1), n((x) => ({ ...x, custom: null })), i((x) => ({ ...x, custom: null }));
4184
+ }, []), J = Y(() => {
4185
+ if (h === void 0 || l) return;
4186
+ const x = d !== null ? d.cursor : h.next_cursor;
4187
+ if (x === null) return;
4188
+ f(!0), w(null);
4189
+ const _ = {
4190
+ ...nt(s),
4191
+ before_ts: x.before_ts,
4192
+ before_id: x.before_id
4193
+ };
4194
+ e.call("logs", _).then(
4195
+ (F) => {
4196
+ f(!1), T.current === h && c((W) => ({
4197
+ items: [...W?.items ?? [], ...F.items],
4198
+ cursor: F.next_cursor
4199
+ }));
4200
+ },
4201
+ (F) => {
4202
+ f(!1), T.current === h && w(ur(F));
4203
+ }
4204
+ );
4205
+ }, [s, e, d, h, l]), K = s.session.trim() !== "" || s.model.trim() !== "" || s.status !== "" || s.custom !== null || s.range !== Gt;
4206
+ return /* @__PURE__ */ R(Tt, { title: o("logs.title"), subtitle: o("logs.description"), children: [
4207
+ /* @__PURE__ */ R(It, { label: o("logs.toolbar"), className: "items-end", children: [
4208
+ r.custom === null ? /* @__PURE__ */ a(Ft, { value: r.range, onChange: p, t: o }) : /* @__PURE__ */ R("div", { className: "flex items-center gap-2", children: [
4209
+ /* @__PURE__ */ a("span", { className: "font-mono text-sm text-muted", children: o("logs.state.custom", {
4210
+ from: r.custom.from === "" ? "…" : r.custom.from,
4211
+ to: r.custom.to === "" ? "…" : r.custom.to
4212
+ }) }),
4213
+ /* @__PURE__ */ a(ce, { onClick: B, children: o("range.clear") })
4214
+ ] }),
4215
+ /* @__PURE__ */ a(Se, { label: o("logs.session"), className: "w-44", children: /* @__PURE__ */ a(
4216
+ et,
4217
+ {
4218
+ value: r.session,
4219
+ onChange: (x) => n((_) => ({ ..._, session: x })),
4220
+ placeholder: o("logs.sessionPlaceholder"),
4221
+ ariaLabel: o("logs.session")
4222
+ }
4223
+ ) }),
4224
+ /* @__PURE__ */ a(Se, { label: o("logs.model"), className: "w-44", children: /* @__PURE__ */ a(
4225
+ et,
4226
+ {
4227
+ value: r.model,
4228
+ onChange: (x) => n((_) => ({ ..._, model: x })),
4229
+ placeholder: o("logs.modelPlaceholder"),
4230
+ ariaLabel: o("logs.model")
4231
+ }
4232
+ ) }),
4233
+ /* @__PURE__ */ a(Se, { label: o("logs.status"), htmlFor: "logs-status", className: "w-36", children: /* @__PURE__ */ R(
4234
+ tr,
4235
+ {
4236
+ id: "logs-status",
4237
+ value: r.status,
4238
+ onChange: (x) => {
4239
+ const _ = gr(x.target.value);
4240
+ n((F) => ({ ...F, status: _ }));
4241
+ },
4242
+ "aria-label": o("logs.status"),
4243
+ children: [
4244
+ /* @__PURE__ */ a("option", { value: "", children: o("logs.allStatuses") }),
4245
+ /* @__PURE__ */ a("option", { value: "ok", children: o("logs.optionOk") }),
4246
+ /* @__PURE__ */ a("option", { value: "failed", children: o("logs.optionFailed") })
4247
+ ]
4248
+ }
4249
+ ) }),
4250
+ /* @__PURE__ */ a(ce, { variant: "primary", onClick: A, children: o("common.apply") }),
4251
+ /* @__PURE__ */ a(ce, { onClick: z.reload, children: o("common.refresh") }),
4252
+ z.isRefreshing ? /* @__PURE__ */ a(Ot, { label: o("common.updating") }) : null
4253
+ ] }),
4254
+ /* @__PURE__ */ R("details", { className: "flex flex-col gap-2", children: [
4255
+ /* @__PURE__ */ a("summary", { className: "cursor-pointer font-mono text-2xs uppercase tracking-widest text-faint", children: o("range.custom") }),
4256
+ /* @__PURE__ */ R("div", { className: "mt-2 flex flex-wrap items-end gap-2", children: [
4257
+ /* @__PURE__ */ a(
4258
+ at,
4259
+ {
4260
+ id: "logs-range-from",
4261
+ label: o("range.from"),
4262
+ value: r.custom?.from ?? "",
4263
+ onChange: (x) => L({ from: x })
4264
+ }
4265
+ ),
4266
+ /* @__PURE__ */ a(
4267
+ at,
4268
+ {
4269
+ id: "logs-range-to",
4270
+ label: o("range.to"),
4271
+ value: r.custom?.to ?? "",
4272
+ onChange: (x) => L({ to: x })
4273
+ }
4274
+ ),
4275
+ /* @__PURE__ */ a(ce, { variant: "primary", onClick: U, children: o("range.apply") }),
4276
+ C ? /* @__PURE__ */ a("p", { className: "text-sm text-danger", children: o("range.invalid") }) : null
4277
+ ] })
4278
+ ] }),
4279
+ /* @__PURE__ */ a(fr, { applied: s, loaded: O.length, cursor: E, t: o }),
4280
+ /* @__PURE__ */ a(Mt, { source: j, t: o }),
4281
+ z.isLoading ? /* @__PURE__ */ a(Dt, { label: o("common.loading") }) : null,
4282
+ z.error !== void 0 && h === void 0 ? /* @__PURE__ */ a(
4283
+ Me,
4284
+ {
4285
+ error: z.error,
4286
+ onRetry: z.reload,
4287
+ title: o("common.loadError"),
4288
+ retryLabel: o("common.retry")
4289
+ }
4290
+ ) : null,
4291
+ z.error !== void 0 && h !== void 0 ? /* @__PURE__ */ a(
4292
+ $t,
4293
+ {
4294
+ message: o("common.stale", { time: He(z.updatedAt) }),
4295
+ onRetry: z.reload,
4296
+ retryLabel: o("common.retry")
4297
+ }
4298
+ ) : null,
4299
+ !z.isLoading && z.error === void 0 && O.length === 0 ? /* @__PURE__ */ a(
4300
+ Pe,
4301
+ {
4302
+ title: o(K ? "logs.empty.filtered" : "logs.empty.title"),
4303
+ description: o("logs.empty.description")
4304
+ }
4305
+ ) : null,
4306
+ O.length > 0 ? /* @__PURE__ */ R(Ee, { children: [
4307
+ /* @__PURE__ */ a(Ve, { children: /* @__PURE__ */ a(Ge, { columns: hr(o), rows: O, rowKey: (x) => x.id }) }),
4308
+ b !== null ? /* @__PURE__ */ a(
4309
+ Me,
4310
+ {
4311
+ error: b,
4312
+ onRetry: J,
4313
+ title: o("common.loadMoreError"),
4314
+ retryLabel: o("common.retry")
4315
+ }
4316
+ ) : E !== null ? /* @__PURE__ */ a("div", { children: /* @__PURE__ */ a(ce, { variant: "primary", onClick: J, disabled: l, children: o(l ? "common.loading" : "common.loadMore") }) }) : null
4317
+ ] }) : null
4318
+ ] });
4319
+ }
4320
+ function it(e, t) {
4321
+ return t === "tokens" ? (e.prompt_tokens ?? 0) + (e.completion_tokens ?? 0) : e[t];
4322
+ }
4323
+ function lt(e, t) {
4324
+ return e === void 0 && t === void 0 ? 0 : e === void 0 ? 1 : t === void 0 ? -1 : typeof e == "string" || typeof t == "string" ? String(e).localeCompare(String(t)) : e - t;
4325
+ }
4326
+ function yr({ items: e, t }) {
4327
+ const [o, r] = V("tokens"), [n, s] = V("desc"), i = Y(
4328
+ (l) => {
4329
+ const f = l;
4330
+ if (f === o) {
4331
+ s((b) => b === "asc" ? "desc" : "asc");
4332
+ return;
4333
+ }
4334
+ r(f), s(f === "model" ? "asc" : "desc");
4335
+ },
4336
+ [o]
4337
+ ), d = ge(() => {
4338
+ const l = e.slice();
4339
+ return l.sort((f, b) => {
4340
+ const w = it(f, o), C = it(b, o);
4341
+ if (w === void 0 || C === void 0) return lt(w, C);
4342
+ const P = lt(w, C);
4343
+ return n === "asc" ? P : -P;
4344
+ }), l;
4345
+ }, [e, o, n]), c = ge(() => [
4346
+ {
4347
+ key: "model",
4348
+ header: t("leaderboard.th.model"),
4349
+ sortable: !0,
4350
+ cell: (l) => /* @__PURE__ */ a("span", { title: l.model, children: l.model })
4351
+ },
4352
+ {
4353
+ key: "requests",
4354
+ header: t("leaderboard.th.requests"),
4355
+ sortable: !0,
4356
+ cell: (l) => G(l.requests)
4357
+ },
4358
+ {
4359
+ key: "tokens",
4360
+ header: t("leaderboard.th.tokens"),
4361
+ sortable: !0,
4362
+ cell: (l) => G((l.prompt_tokens ?? 0) + (l.completion_tokens ?? 0))
4363
+ },
4364
+ {
4365
+ key: "cache_read_tokens",
4366
+ header: t("leaderboard.th.cacheRead"),
4367
+ sortable: !0,
4368
+ cell: (l) => G(l.cache_read_tokens)
4369
+ },
4370
+ {
4371
+ key: "cost",
4372
+ header: t("leaderboard.th.cost"),
4373
+ sortable: !0,
4374
+ cell: (l) => ze(l.cost)
4375
+ }
4376
+ ], [t]);
4377
+ return /* @__PURE__ */ a(Ve, { children: /* @__PURE__ */ a(
4378
+ Ge,
4379
+ {
4380
+ columns: c,
4381
+ rows: d,
4382
+ rowKey: (l) => l.model,
4383
+ sort: { key: o, direction: n },
4384
+ onSortChange: i
4385
+ }
4386
+ ) });
4387
+ }
4388
+ function wr(e) {
4389
+ return [
4390
+ { key: "date", header: e("usage.th.day"), cell: (t) => t.date },
4391
+ { key: "requests", header: e("usage.th.requests"), cell: (t) => G(t.requests) },
4392
+ { key: "prompt", header: e("usage.th.prompt"), cell: (t) => G(t.prompt_tokens) },
4393
+ {
4394
+ key: "completion",
4395
+ header: e("usage.th.completion"),
4396
+ cell: (t) => G(t.completion_tokens)
4397
+ },
4398
+ {
4399
+ key: "cache_read",
4400
+ header: e("usage.th.cacheRead"),
4401
+ cell: (t) => G(t.cache_read_tokens)
4402
+ },
4403
+ { key: "failed", header: e("usage.th.failed"), cell: (t) => G(t.failed_runs) },
4404
+ {
4405
+ key: "unpriced",
4406
+ header: e("usage.th.unpriced"),
4407
+ cell: (t) => G(t.unpriced_requests)
4408
+ },
4409
+ { key: "cost", header: e("usage.th.cost"), cell: (t) => ze(t.cost) }
4410
+ ];
4411
+ }
4412
+ function kr(e, t) {
4413
+ const o = e.totals;
4414
+ return [
4415
+ {
4416
+ key: "requests",
4417
+ label: t("usage.requests"),
4418
+ value: G(o.requests),
4419
+ hint: o.failed_runs > 0 ? t("usage.failedRuns", { n: G(o.failed_runs) }) : void 0
4420
+ },
4421
+ {
4422
+ key: "prompt",
4423
+ label: t("usage.promptTokens"),
4424
+ value: G(o.prompt_tokens),
4425
+ hint: t("usage.promptHint")
4426
+ },
4427
+ {
4428
+ key: "completion",
4429
+ label: t("usage.completionTokens"),
4430
+ value: G(o.completion_tokens)
4431
+ },
4432
+ {
4433
+ key: "cache_read",
4434
+ label: t("usage.cacheRead"),
4435
+ value: G(o.cache_read_tokens),
4436
+ hint: o.cache_read_tokens === void 0 ? t("usage.cacheNotReported") : t("usage.cacheHint")
4437
+ },
4438
+ {
4439
+ key: "input_share",
4440
+ label: t("usage.inputShare"),
4441
+ value: tt(e.input_share),
4442
+ hint: ot(e.input_share_unavailable, t("usage.inputShareHint"), t)
4443
+ },
4444
+ {
4445
+ key: "prefix_health",
4446
+ label: t("usage.prefixHealth"),
4447
+ value: tt(e.prefix_health),
4448
+ hint: ot(e.prefix_health_unavailable, t("usage.prefixHealthHint"), t)
4449
+ },
4450
+ {
4451
+ key: "cost",
4452
+ label: t("usage.cost"),
4453
+ value: ze(e.cost),
4454
+ hint: cr(e, t)
4455
+ }
4456
+ ];
4457
+ }
4458
+ function ct({ children: e }) {
4459
+ return /* @__PURE__ */ a("h2", { className: "font-mono text-2xs uppercase tracking-widest text-faint", children: e });
4460
+ }
4461
+ function vr({ data: e, t }) {
4462
+ const { summary: o, models: r } = e;
4463
+ return o.has_data ? /* @__PURE__ */ R(Ee, { children: [
4464
+ /* @__PURE__ */ a("div", { className: "grid grid-cols-2 gap-3 compact:grid-cols-3 wide:grid-cols-4", children: kr(o, t).map((n) => /* @__PURE__ */ a(or, { label: n.label, value: n.value, hint: n.hint }, n.key)) }),
4465
+ /* @__PURE__ */ R("div", { className: "flex flex-col gap-2", children: [
4466
+ /* @__PURE__ */ a(ct, { children: t("usage.byDay") }),
4467
+ /* @__PURE__ */ a(Ve, { children: /* @__PURE__ */ a(Ge, { columns: wr(t), rows: o.by_day, rowKey: (n) => n.date }) })
4468
+ ] }),
4469
+ /* @__PURE__ */ R("div", { className: "flex flex-col gap-2", children: [
4470
+ /* @__PURE__ */ a(ct, { children: t("usage.byModel") }),
4471
+ r.items.length === 0 ? /* @__PURE__ */ a(
4472
+ Pe,
4473
+ {
4474
+ title: t("leaderboard.empty.title"),
4475
+ description: t("leaderboard.empty.description")
4476
+ }
4477
+ ) : /* @__PURE__ */ a(yr, { items: r.items, t })
4478
+ ] })
4479
+ ] }) : o.source?.source_retired === !0 ? null : /* @__PURE__ */ a(Pe, { title: t("usage.empty.title"), description: t("usage.empty.description") });
4480
+ }
4481
+ const Nr = 15e3;
4482
+ function Cr({ client: e, refreshKey: t, t: o }) {
4483
+ const [r, n] = V("30"), s = Pt({
4484
+ load: async () => {
4485
+ const i = Et(r), [d, c] = await Promise.all([
4486
+ e.call("summary", i),
4487
+ e.call("leaderboard", i)
4488
+ ]);
4489
+ return { summary: d, models: c };
4490
+ },
4491
+ queryKey: [r],
4492
+ intervalMs: Nr,
4493
+ refreshKey: t
4494
+ });
4495
+ return /* @__PURE__ */ R(Tt, { title: o("usage.title"), subtitle: o("usage.description"), children: [
4496
+ /* @__PURE__ */ R(It, { label: o("usage.toolbar"), children: [
4497
+ /* @__PURE__ */ a(Ft, { value: r, onChange: n, t: o }),
4498
+ s.isRefreshing ? /* @__PURE__ */ a(Ot, { label: o("common.updating") }) : null
4499
+ ] }),
4500
+ s.data !== void 0 ? /* @__PURE__ */ a(Mt, { source: s.data.summary.source, t: o }) : null,
4501
+ s.isLoading ? /* @__PURE__ */ a(Dt, { label: o("common.loading") }) : null,
4502
+ s.error !== void 0 && s.data === void 0 ? /* @__PURE__ */ a(
4503
+ Me,
4504
+ {
4505
+ error: s.error,
4506
+ onRetry: s.reload,
4507
+ title: o("common.loadError"),
4508
+ retryLabel: o("common.retry")
4509
+ }
4510
+ ) : null,
4511
+ s.error !== void 0 && s.data !== void 0 ? /* @__PURE__ */ a(
4512
+ $t,
4513
+ {
4514
+ message: o("common.stale", { time: He(s.updatedAt) }),
4515
+ onRetry: s.reload,
4516
+ retryLabel: o("common.retry")
4517
+ }
4518
+ ) : null,
4519
+ s.data !== void 0 ? /* @__PURE__ */ a(vr, { data: s.data, t: o }) : null
4520
+ ] });
4521
+ }
4522
+ function Ht(e) {
4523
+ return {
4524
+ call: (t, o) => e.rpc(t, o)
4525
+ };
4526
+ }
4527
+ function Vt(e) {
4528
+ const [t, o] = V(() => e.theme.get());
4529
+ return Q(() => e.theme.subscribe(o), [e]), t;
4530
+ }
4531
+ function jt(e) {
4532
+ const [t, o] = V(0);
4533
+ return Q(() => {
4534
+ let r;
4535
+ const n = () => {
4536
+ r !== void 0 && clearTimeout(r), r = setTimeout(() => o((i) => i + 1), 250);
4537
+ }, s = [];
4538
+ for (const i of ["llm.response", "run.completed"])
4539
+ try {
4540
+ s.push(e.events.subscribe(i, n));
4541
+ } catch {
4542
+ }
4543
+ return () => {
4544
+ r !== void 0 && clearTimeout(r);
4545
+ for (const i of s) i();
4546
+ };
4547
+ }, [e]), t;
4548
+ }
4549
+ function _r({ host: e }) {
4550
+ const t = Vt(e), o = ge(() => ut(t.lang), [t.lang]), r = ge(() => Ht(e), [e]), n = jt(e);
4551
+ return /* @__PURE__ */ a(Cr, { client: r, refreshKey: n, t: o });
4552
+ }
4553
+ function zr({ host: e }) {
4554
+ const t = Vt(e), o = ge(() => ut(t.lang), [t.lang]), r = ge(() => Ht(e), [e]), n = jt(e);
4555
+ return /* @__PURE__ */ a(xr, { client: r, refreshKey: n, t: o });
4556
+ }
4557
+ export {
4558
+ zr as LogsView,
4559
+ _r as UsageView
4560
+ };