@ciderpress/ui 1.0.0-rc.1

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 (428) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +23 -0
  3. package/dist/0~142.js +2 -0
  4. package/dist/0~164.js +2 -0
  5. package/dist/0~2.js +2 -0
  6. package/dist/0~225.js +2 -0
  7. package/dist/0~288.js +2 -0
  8. package/dist/0~299.js +2 -0
  9. package/dist/0~3.js +2 -0
  10. package/dist/0~301.js +2 -0
  11. package/dist/0~311.js +2 -0
  12. package/dist/0~326.js +2 -0
  13. package/dist/0~40.js +2 -0
  14. package/dist/0~43.js +2 -0
  15. package/dist/0~433.js +2 -0
  16. package/dist/0~453.js +2 -0
  17. package/dist/0~457.js +2 -0
  18. package/dist/0~497.js +2 -0
  19. package/dist/0~511.js +2 -0
  20. package/dist/0~603.js +2 -0
  21. package/dist/0~616.js +2 -0
  22. package/dist/0~659.js +2 -0
  23. package/dist/0~670.js +2 -0
  24. package/dist/0~687.js +2 -0
  25. package/dist/0~706.js +2 -0
  26. package/dist/0~729.js +2 -0
  27. package/dist/0~768.js +2 -0
  28. package/dist/0~819.js +2 -0
  29. package/dist/0~830.js +2 -0
  30. package/dist/0~854.js +2 -0
  31. package/dist/0~863.js +2 -0
  32. package/dist/0~879.js +2 -0
  33. package/dist/0~96.js +2 -0
  34. package/dist/0~97.js +2 -0
  35. package/dist/components/FileTree/FileTree.css +90 -0
  36. package/dist/components/FileTree/FileTree.d.ts +7 -0
  37. package/dist/components/FileTree/FileTree.js +531 -0
  38. package/dist/components/FileTree/FileTreeItem.d.ts +8 -0
  39. package/dist/components/FileTree/RemoteSvgIcon.d.ts +11 -0
  40. package/dist/components/FileTree/index.d.ts +4 -0
  41. package/dist/components/folder-icons.d.ts +32 -0
  42. package/dist/components/languages.d.ts +7 -0
  43. package/dist/components/tree-parser/tree-parser.d.ts +12 -0
  44. package/dist/components/tree-parser/types.d.ts +11 -0
  45. package/dist/head/css/loader-apple.css +1 -0
  46. package/dist/head/css/loader-backdrop.css +1 -0
  47. package/dist/head/css/loader-dots.css +1 -0
  48. package/dist/head/css/themes/amber.css +1 -0
  49. package/dist/head/css/themes/arcade.css +1 -0
  50. package/dist/head/css/themes/grannysmith.css +1 -0
  51. package/dist/head/css/themes/honeycrisp.css +1 -0
  52. package/dist/head/css/themes/midnight.css +1 -0
  53. package/dist/head/css/themes/mulled.css +1 -0
  54. package/dist/head/js/loader-dots.js +1 -0
  55. package/dist/head/js/vscode-nav.js +1 -0
  56. package/dist/index.d.ts +43 -0
  57. package/dist/index.mjs +40 -0
  58. package/dist/node.d.ts +81 -0
  59. package/dist/node.mjs +17762 -0
  60. package/dist/plugins/mermaid/MermaidRenderer.tsx +480 -0
  61. package/dist/plugins/mermaid/mermaid.css +199 -0
  62. package/dist/theme/components/announcement/announcement-bar.css +103 -0
  63. package/dist/theme/components/announcement/announcement-bar.tsx +173 -0
  64. package/dist/theme/components/ask-ai/ask-ai-button.css +52 -0
  65. package/dist/theme/components/ask-ai/ask-ai-button.tsx +56 -0
  66. package/dist/theme/components/content-footer/content-footer-portal.tsx +70 -0
  67. package/dist/theme/components/content-footer/feedback.css +47 -0
  68. package/dist/theme/components/content-footer/feedback.tsx +96 -0
  69. package/dist/theme/components/content-footer/meta-actions.css +25 -0
  70. package/dist/theme/components/content-footer/meta-actions.tsx +57 -0
  71. package/dist/theme/components/content-footer/page-pager.css +61 -0
  72. package/dist/theme/components/content-footer/page-pager.tsx +110 -0
  73. package/dist/theme/components/edit-source-button.tsx +97 -0
  74. package/dist/theme/components/footer/site-footer.css +179 -0
  75. package/dist/theme/components/footer/site-footer.tsx +115 -0
  76. package/dist/theme/components/home/cta.css +67 -0
  77. package/dist/theme/components/home/cta.tsx +77 -0
  78. package/dist/theme/components/home/feature-card.css +52 -0
  79. package/dist/theme/components/home/feature-card.tsx +131 -0
  80. package/dist/theme/components/home/feature.tsx +79 -0
  81. package/dist/theme/components/home/hero-demo.css +66 -0
  82. package/dist/theme/components/home/hero-demo.tsx +46 -0
  83. package/dist/theme/components/home/hero.css +96 -0
  84. package/dist/theme/components/home/hero.tsx +111 -0
  85. package/dist/theme/components/home/layout.tsx +183 -0
  86. package/dist/theme/components/home/page-rail.css +21 -0
  87. package/dist/theme/components/home/page-rail.tsx +19 -0
  88. package/dist/theme/components/home/split.css +148 -0
  89. package/dist/theme/components/home/split.tsx +120 -0
  90. package/dist/theme/components/home/trust-strip.css +33 -0
  91. package/dist/theme/components/home/trust-strip.tsx +43 -0
  92. package/dist/theme/components/home/workspaces.tsx +71 -0
  93. package/dist/theme/components/nav/branch-tag.css +54 -0
  94. package/dist/theme/components/nav/branch-tag.tsx +101 -0
  95. package/dist/theme/components/nav/ciderpress-doc-layout.tsx +247 -0
  96. package/dist/theme/components/nav/ciderpress-docs-bar.css +505 -0
  97. package/dist/theme/components/nav/ciderpress-docs-bar.tsx +426 -0
  98. package/dist/theme/components/nav/ciderpress-header.css +172 -0
  99. package/dist/theme/components/nav/ciderpress-header.tsx +113 -0
  100. package/dist/theme/components/nav/ciderpress-layout-context.tsx +49 -0
  101. package/dist/theme/components/nav/ciderpress-nav-hamburger.css +193 -0
  102. package/dist/theme/components/nav/ciderpress-nav-hamburger.tsx +112 -0
  103. package/dist/theme/components/nav/ciderpress-nav-menu.css +130 -0
  104. package/dist/theme/components/nav/ciderpress-nav-menu.tsx +372 -0
  105. package/dist/theme/components/nav/ciderpress-nav-search.css +73 -0
  106. package/dist/theme/components/nav/ciderpress-nav-search.tsx +55 -0
  107. package/dist/theme/components/nav/ciderpress-nav-social-links.css +35 -0
  108. package/dist/theme/components/nav/ciderpress-nav-social-links.tsx +87 -0
  109. package/dist/theme/components/nav/floating-branch-indicator.css +106 -0
  110. package/dist/theme/components/nav/floating-branch-indicator.tsx +109 -0
  111. package/dist/theme/components/nav/layout.tsx +268 -0
  112. package/dist/theme/components/nav/mobile-nav-cta.tsx +79 -0
  113. package/dist/theme/components/nav/nav-divider.css +15 -0
  114. package/dist/theme/components/nav/nav-divider.tsx +19 -0
  115. package/dist/theme/components/nav/nav-logo.css +42 -0
  116. package/dist/theme/components/nav/nav-logo.tsx +262 -0
  117. package/dist/theme/components/nav/theme-switcher.css +92 -0
  118. package/dist/theme/components/nav/theme-switcher.tsx +298 -0
  119. package/dist/theme/components/nav/topbar-cta.css +45 -0
  120. package/dist/theme/components/nav/topbar-cta.tsx +39 -0
  121. package/dist/theme/components/nav/variant-toggle.css +70 -0
  122. package/dist/theme/components/nav/variant-toggle.tsx +83 -0
  123. package/dist/theme/components/nav/version-chip.css +31 -0
  124. package/dist/theme/components/nav/version-chip.tsx +45 -0
  125. package/dist/theme/components/nav/vscode-tag.css +32 -0
  126. package/dist/theme/components/nav/vscode-tag.tsx +20 -0
  127. package/dist/theme/components/openapi/code-sample.tsx +341 -0
  128. package/dist/theme/components/openapi/copy-markdown-button.tsx +41 -0
  129. package/dist/theme/components/openapi/icons.tsx +45 -0
  130. package/dist/theme/components/openapi/index.ts +6 -0
  131. package/dist/theme/components/openapi/method-badge.tsx +24 -0
  132. package/dist/theme/components/openapi/openapi.css +665 -0
  133. package/dist/theme/components/openapi/operation.tsx +200 -0
  134. package/dist/theme/components/openapi/overview.tsx +207 -0
  135. package/dist/theme/components/openapi/parameters-table.tsx +149 -0
  136. package/dist/theme/components/openapi/request-body.tsx +90 -0
  137. package/dist/theme/components/openapi/response-list.tsx +112 -0
  138. package/dist/theme/components/openapi/schema-viewer.tsx +277 -0
  139. package/dist/theme/components/openapi/security-badges.tsx +63 -0
  140. package/dist/theme/components/openapi/spec-utils.ts +122 -0
  141. package/dist/theme/components/shared/accordion.css +118 -0
  142. package/dist/theme/components/shared/accordion.stories.tsx +96 -0
  143. package/dist/theme/components/shared/accordion.tsx +191 -0
  144. package/dist/theme/components/shared/brand-logo.stories.tsx +49 -0
  145. package/dist/theme/components/shared/brand-mark.stories.tsx +53 -0
  146. package/dist/theme/components/shared/browser-window.css +1 -0
  147. package/dist/theme/components/shared/browser-window.stories.tsx +100 -0
  148. package/dist/theme/components/shared/browser-window.tsx +2 -0
  149. package/dist/theme/components/shared/card.stories.tsx +50 -0
  150. package/dist/theme/components/shared/card.tsx +35 -0
  151. package/dist/theme/components/shared/ciderpress-logo.tsx +93 -0
  152. package/dist/theme/components/shared/ciderpress-mark.tsx +77 -0
  153. package/dist/theme/components/shared/color.css +56 -0
  154. package/dist/theme/components/shared/color.stories.tsx +47 -0
  155. package/dist/theme/components/shared/color.tsx +69 -0
  156. package/dist/theme/components/shared/columns.css +37 -0
  157. package/dist/theme/components/shared/columns.stories.tsx +91 -0
  158. package/dist/theme/components/shared/columns.tsx +50 -0
  159. package/dist/theme/components/shared/desktop-window.css +339 -0
  160. package/dist/theme/components/shared/desktop-window.tsx +535 -0
  161. package/dist/theme/components/shared/field.css +158 -0
  162. package/dist/theme/components/shared/field.stories.tsx +100 -0
  163. package/dist/theme/components/shared/field.tsx +186 -0
  164. package/dist/theme/components/shared/frame.css +39 -0
  165. package/dist/theme/components/shared/frame.stories.tsx +49 -0
  166. package/dist/theme/components/shared/frame.tsx +76 -0
  167. package/dist/theme/components/shared/icon.stories.tsx +90 -0
  168. package/dist/theme/components/shared/icon.tsx +41 -0
  169. package/dist/theme/components/shared/prompt.css +178 -0
  170. package/dist/theme/components/shared/prompt.stories.tsx +57 -0
  171. package/dist/theme/components/shared/prompt.tsx +369 -0
  172. package/dist/theme/components/shared/resolve-card-icon.ts +28 -0
  173. package/dist/theme/components/shared/section-card.stories.tsx +51 -0
  174. package/dist/theme/components/shared/section-card.tsx +44 -0
  175. package/dist/theme/components/shared/section-grid.stories.tsx +46 -0
  176. package/dist/theme/components/shared/section-grid.tsx +15 -0
  177. package/dist/theme/components/shared/status-badge.css +37 -0
  178. package/dist/theme/components/shared/status-badge.stories.tsx +61 -0
  179. package/dist/theme/components/shared/status-badge.tsx +74 -0
  180. package/dist/theme/components/shared/steps.css +88 -0
  181. package/dist/theme/components/shared/steps.stories.tsx +68 -0
  182. package/dist/theme/components/shared/steps.tsx +100 -0
  183. package/dist/theme/components/shared/tech-icon-table.stories.tsx +29 -0
  184. package/dist/theme/components/shared/tech-icon-table.tsx +71 -0
  185. package/dist/theme/components/shared/tech-tag.stories.tsx +40 -0
  186. package/dist/theme/components/shared/tech-tag.tsx +31 -0
  187. package/dist/theme/components/shared/theme-color-palette.css +80 -0
  188. package/dist/theme/components/shared/theme-color-palette.stories.tsx +52 -0
  189. package/dist/theme/components/shared/theme-color-palette.tsx +275 -0
  190. package/dist/theme/components/shared/tooltip.css +69 -0
  191. package/dist/theme/components/shared/tooltip.stories.tsx +72 -0
  192. package/dist/theme/components/shared/tooltip.tsx +77 -0
  193. package/dist/theme/components/sidebar/framework-picker.css +77 -0
  194. package/dist/theme/components/sidebar/framework-picker.tsx +78 -0
  195. package/dist/theme/components/sidebar/sidebar-filter.test.ts +140 -0
  196. package/dist/theme/components/sidebar/sidebar-filter.ts +79 -0
  197. package/dist/theme/components/sidebar/sidebar-links.css +102 -0
  198. package/dist/theme/components/sidebar/sidebar-links.tsx +122 -0
  199. package/dist/theme/components/sidebar/sidebar-promo.css +42 -0
  200. package/dist/theme/components/sidebar/sidebar-promo.tsx +52 -0
  201. package/dist/theme/components/sidebar/sidebar-scope.tsx +151 -0
  202. package/dist/theme/components/sidebar/sidebar-toggle.css +181 -0
  203. package/dist/theme/components/sidebar/sidebar-toggle.tsx +127 -0
  204. package/dist/theme/components/theme-provider.tsx +637 -0
  205. package/dist/theme/components/workspaces/card.css +151 -0
  206. package/dist/theme/components/workspaces/card.tsx +166 -0
  207. package/dist/theme/components/workspaces/grid.tsx +62 -0
  208. package/dist/theme/css.d.ts +1 -0
  209. package/dist/theme/env.d.ts +12 -0
  210. package/dist/theme/fonts/GeistMono-Variable.woff2 +0 -0
  211. package/dist/theme/fonts/GeistPixel-Square.woff2 +0 -0
  212. package/dist/theme/fonts/GeistSans-Variable.woff2 +0 -0
  213. package/dist/theme/hooks/use-ciderpress.ts +61 -0
  214. package/dist/theme/hooks/use-nav-items.ts +76 -0
  215. package/dist/theme/icons/index.ts +2 -0
  216. package/dist/theme/icons/tech-map.ts +228 -0
  217. package/dist/theme/index.tsx +180 -0
  218. package/dist/theme/lib/read-social-links.ts +27 -0
  219. package/dist/theme/lib/route-link.tsx +126 -0
  220. package/dist/theme/lib/safe-url.test.ts +0 -0
  221. package/dist/theme/lib/safe-url.ts +68 -0
  222. package/dist/theme/lib/theme-favicon.ts +125 -0
  223. package/dist/theme/lib/user-config-stub.ts +12 -0
  224. package/dist/theme/styles/layers.css +32 -0
  225. package/dist/theme/styles/overrides/badge.css +26 -0
  226. package/dist/theme/styles/overrides/content-footer.css +80 -0
  227. package/dist/theme/styles/overrides/details.css +61 -0
  228. package/dist/theme/styles/overrides/fonts.css +32 -0
  229. package/dist/theme/styles/overrides/home-card.css +133 -0
  230. package/dist/theme/styles/overrides/home.css +243 -0
  231. package/dist/theme/styles/overrides/rail.css +337 -0
  232. package/dist/theme/styles/overrides/rspress.css +62 -0
  233. package/dist/theme/styles/overrides/scrollbar.css +25 -0
  234. package/dist/theme/styles/overrides/section-card.css +114 -0
  235. package/dist/theme/styles/overrides/sidebar.css +144 -0
  236. package/dist/theme/styles/overrides/tokens.css +288 -0
  237. package/dist/theme/styles/overrides/vscode.css +88 -0
  238. package/dist/theme/styles/themes/amber.css +545 -0
  239. package/dist/theme/styles/themes/arcade-fx.css +366 -0
  240. package/dist/theme/styles/themes/arcade.css +273 -0
  241. package/dist/theme/styles/themes/grannysmith.css +545 -0
  242. package/dist/theme/styles/themes/honeycrisp.css +545 -0
  243. package/dist/theme/styles/themes/midnight.css +273 -0
  244. package/dist/theme/styles/themes/mulled.css +817 -0
  245. package/package.json +103 -0
  246. package/src/theme/components/announcement/announcement-bar.css +103 -0
  247. package/src/theme/components/announcement/announcement-bar.tsx +173 -0
  248. package/src/theme/components/ask-ai/ask-ai-button.css +52 -0
  249. package/src/theme/components/ask-ai/ask-ai-button.tsx +56 -0
  250. package/src/theme/components/content-footer/content-footer-portal.tsx +70 -0
  251. package/src/theme/components/content-footer/feedback.css +47 -0
  252. package/src/theme/components/content-footer/feedback.tsx +96 -0
  253. package/src/theme/components/content-footer/meta-actions.css +25 -0
  254. package/src/theme/components/content-footer/meta-actions.tsx +57 -0
  255. package/src/theme/components/content-footer/page-pager.css +61 -0
  256. package/src/theme/components/content-footer/page-pager.tsx +110 -0
  257. package/src/theme/components/edit-source-button.tsx +97 -0
  258. package/src/theme/components/footer/site-footer.css +179 -0
  259. package/src/theme/components/footer/site-footer.tsx +115 -0
  260. package/src/theme/components/home/cta.css +67 -0
  261. package/src/theme/components/home/cta.tsx +77 -0
  262. package/src/theme/components/home/feature-card.css +52 -0
  263. package/src/theme/components/home/feature-card.tsx +131 -0
  264. package/src/theme/components/home/feature.tsx +79 -0
  265. package/src/theme/components/home/hero-demo.css +66 -0
  266. package/src/theme/components/home/hero-demo.tsx +46 -0
  267. package/src/theme/components/home/hero.css +96 -0
  268. package/src/theme/components/home/hero.tsx +111 -0
  269. package/src/theme/components/home/layout.tsx +183 -0
  270. package/src/theme/components/home/page-rail.css +21 -0
  271. package/src/theme/components/home/page-rail.tsx +19 -0
  272. package/src/theme/components/home/split.css +148 -0
  273. package/src/theme/components/home/split.tsx +120 -0
  274. package/src/theme/components/home/trust-strip.css +33 -0
  275. package/src/theme/components/home/trust-strip.tsx +43 -0
  276. package/src/theme/components/home/workspaces.tsx +71 -0
  277. package/src/theme/components/nav/branch-tag.css +54 -0
  278. package/src/theme/components/nav/branch-tag.tsx +101 -0
  279. package/src/theme/components/nav/ciderpress-doc-layout.tsx +247 -0
  280. package/src/theme/components/nav/ciderpress-docs-bar.css +505 -0
  281. package/src/theme/components/nav/ciderpress-docs-bar.tsx +426 -0
  282. package/src/theme/components/nav/ciderpress-header.css +172 -0
  283. package/src/theme/components/nav/ciderpress-header.tsx +113 -0
  284. package/src/theme/components/nav/ciderpress-layout-context.tsx +49 -0
  285. package/src/theme/components/nav/ciderpress-nav-hamburger.css +193 -0
  286. package/src/theme/components/nav/ciderpress-nav-hamburger.tsx +112 -0
  287. package/src/theme/components/nav/ciderpress-nav-menu.css +130 -0
  288. package/src/theme/components/nav/ciderpress-nav-menu.tsx +372 -0
  289. package/src/theme/components/nav/ciderpress-nav-search.css +73 -0
  290. package/src/theme/components/nav/ciderpress-nav-search.tsx +55 -0
  291. package/src/theme/components/nav/ciderpress-nav-social-links.css +35 -0
  292. package/src/theme/components/nav/ciderpress-nav-social-links.tsx +87 -0
  293. package/src/theme/components/nav/floating-branch-indicator.css +106 -0
  294. package/src/theme/components/nav/floating-branch-indicator.tsx +109 -0
  295. package/src/theme/components/nav/layout.tsx +268 -0
  296. package/src/theme/components/nav/mobile-nav-cta.tsx +79 -0
  297. package/src/theme/components/nav/nav-divider.css +15 -0
  298. package/src/theme/components/nav/nav-divider.tsx +19 -0
  299. package/src/theme/components/nav/nav-logo.css +42 -0
  300. package/src/theme/components/nav/nav-logo.tsx +262 -0
  301. package/src/theme/components/nav/theme-switcher.css +92 -0
  302. package/src/theme/components/nav/theme-switcher.tsx +298 -0
  303. package/src/theme/components/nav/topbar-cta.css +45 -0
  304. package/src/theme/components/nav/topbar-cta.tsx +39 -0
  305. package/src/theme/components/nav/variant-toggle.css +70 -0
  306. package/src/theme/components/nav/variant-toggle.tsx +83 -0
  307. package/src/theme/components/nav/version-chip.css +31 -0
  308. package/src/theme/components/nav/version-chip.tsx +45 -0
  309. package/src/theme/components/nav/vscode-tag.css +32 -0
  310. package/src/theme/components/nav/vscode-tag.tsx +20 -0
  311. package/src/theme/components/openapi/code-sample.tsx +341 -0
  312. package/src/theme/components/openapi/copy-markdown-button.tsx +41 -0
  313. package/src/theme/components/openapi/icons.tsx +45 -0
  314. package/src/theme/components/openapi/index.ts +6 -0
  315. package/src/theme/components/openapi/method-badge.tsx +24 -0
  316. package/src/theme/components/openapi/openapi.css +665 -0
  317. package/src/theme/components/openapi/operation.tsx +200 -0
  318. package/src/theme/components/openapi/overview.tsx +207 -0
  319. package/src/theme/components/openapi/parameters-table.tsx +149 -0
  320. package/src/theme/components/openapi/request-body.tsx +90 -0
  321. package/src/theme/components/openapi/response-list.tsx +112 -0
  322. package/src/theme/components/openapi/schema-viewer.tsx +277 -0
  323. package/src/theme/components/openapi/security-badges.tsx +63 -0
  324. package/src/theme/components/openapi/spec-utils.ts +122 -0
  325. package/src/theme/components/shared/accordion.css +118 -0
  326. package/src/theme/components/shared/accordion.stories.tsx +96 -0
  327. package/src/theme/components/shared/accordion.tsx +191 -0
  328. package/src/theme/components/shared/brand-logo.stories.tsx +49 -0
  329. package/src/theme/components/shared/brand-mark.stories.tsx +53 -0
  330. package/src/theme/components/shared/browser-window.css +1 -0
  331. package/src/theme/components/shared/browser-window.stories.tsx +100 -0
  332. package/src/theme/components/shared/browser-window.tsx +2 -0
  333. package/src/theme/components/shared/card.stories.tsx +50 -0
  334. package/src/theme/components/shared/card.tsx +35 -0
  335. package/src/theme/components/shared/ciderpress-logo.tsx +93 -0
  336. package/src/theme/components/shared/ciderpress-mark.tsx +77 -0
  337. package/src/theme/components/shared/color.css +56 -0
  338. package/src/theme/components/shared/color.stories.tsx +47 -0
  339. package/src/theme/components/shared/color.tsx +69 -0
  340. package/src/theme/components/shared/columns.css +37 -0
  341. package/src/theme/components/shared/columns.stories.tsx +91 -0
  342. package/src/theme/components/shared/columns.tsx +50 -0
  343. package/src/theme/components/shared/desktop-window.css +339 -0
  344. package/src/theme/components/shared/desktop-window.tsx +535 -0
  345. package/src/theme/components/shared/field.css +158 -0
  346. package/src/theme/components/shared/field.stories.tsx +100 -0
  347. package/src/theme/components/shared/field.tsx +186 -0
  348. package/src/theme/components/shared/frame.css +39 -0
  349. package/src/theme/components/shared/frame.stories.tsx +49 -0
  350. package/src/theme/components/shared/frame.tsx +76 -0
  351. package/src/theme/components/shared/icon.stories.tsx +90 -0
  352. package/src/theme/components/shared/icon.tsx +41 -0
  353. package/src/theme/components/shared/prompt.css +178 -0
  354. package/src/theme/components/shared/prompt.stories.tsx +57 -0
  355. package/src/theme/components/shared/prompt.tsx +369 -0
  356. package/src/theme/components/shared/resolve-card-icon.ts +28 -0
  357. package/src/theme/components/shared/section-card.stories.tsx +51 -0
  358. package/src/theme/components/shared/section-card.tsx +44 -0
  359. package/src/theme/components/shared/section-grid.stories.tsx +46 -0
  360. package/src/theme/components/shared/section-grid.tsx +15 -0
  361. package/src/theme/components/shared/status-badge.css +37 -0
  362. package/src/theme/components/shared/status-badge.stories.tsx +61 -0
  363. package/src/theme/components/shared/status-badge.tsx +74 -0
  364. package/src/theme/components/shared/steps.css +88 -0
  365. package/src/theme/components/shared/steps.stories.tsx +68 -0
  366. package/src/theme/components/shared/steps.tsx +100 -0
  367. package/src/theme/components/shared/tech-icon-table.stories.tsx +29 -0
  368. package/src/theme/components/shared/tech-icon-table.tsx +71 -0
  369. package/src/theme/components/shared/tech-tag.stories.tsx +40 -0
  370. package/src/theme/components/shared/tech-tag.tsx +31 -0
  371. package/src/theme/components/shared/theme-color-palette.css +80 -0
  372. package/src/theme/components/shared/theme-color-palette.stories.tsx +52 -0
  373. package/src/theme/components/shared/theme-color-palette.tsx +275 -0
  374. package/src/theme/components/shared/tooltip.css +69 -0
  375. package/src/theme/components/shared/tooltip.stories.tsx +72 -0
  376. package/src/theme/components/shared/tooltip.tsx +77 -0
  377. package/src/theme/components/sidebar/framework-picker.css +77 -0
  378. package/src/theme/components/sidebar/framework-picker.tsx +78 -0
  379. package/src/theme/components/sidebar/sidebar-filter.test.ts +140 -0
  380. package/src/theme/components/sidebar/sidebar-filter.ts +79 -0
  381. package/src/theme/components/sidebar/sidebar-links.css +102 -0
  382. package/src/theme/components/sidebar/sidebar-links.tsx +122 -0
  383. package/src/theme/components/sidebar/sidebar-promo.css +42 -0
  384. package/src/theme/components/sidebar/sidebar-promo.tsx +52 -0
  385. package/src/theme/components/sidebar/sidebar-scope.tsx +151 -0
  386. package/src/theme/components/sidebar/sidebar-toggle.css +181 -0
  387. package/src/theme/components/sidebar/sidebar-toggle.tsx +127 -0
  388. package/src/theme/components/theme-provider.tsx +637 -0
  389. package/src/theme/components/workspaces/card.css +151 -0
  390. package/src/theme/components/workspaces/card.tsx +166 -0
  391. package/src/theme/components/workspaces/grid.tsx +62 -0
  392. package/src/theme/css.d.ts +1 -0
  393. package/src/theme/env.d.ts +12 -0
  394. package/src/theme/fonts/GeistMono-Variable.woff2 +0 -0
  395. package/src/theme/fonts/GeistPixel-Square.woff2 +0 -0
  396. package/src/theme/fonts/GeistSans-Variable.woff2 +0 -0
  397. package/src/theme/hooks/use-ciderpress.ts +61 -0
  398. package/src/theme/hooks/use-nav-items.ts +76 -0
  399. package/src/theme/icons/index.ts +2 -0
  400. package/src/theme/icons/tech-map.ts +228 -0
  401. package/src/theme/index.tsx +180 -0
  402. package/src/theme/lib/read-social-links.ts +27 -0
  403. package/src/theme/lib/route-link.tsx +126 -0
  404. package/src/theme/lib/safe-url.test.ts +0 -0
  405. package/src/theme/lib/safe-url.ts +68 -0
  406. package/src/theme/lib/theme-favicon.ts +125 -0
  407. package/src/theme/lib/user-config-stub.ts +12 -0
  408. package/src/theme/styles/layers.css +32 -0
  409. package/src/theme/styles/overrides/badge.css +26 -0
  410. package/src/theme/styles/overrides/content-footer.css +80 -0
  411. package/src/theme/styles/overrides/details.css +61 -0
  412. package/src/theme/styles/overrides/fonts.css +32 -0
  413. package/src/theme/styles/overrides/home-card.css +133 -0
  414. package/src/theme/styles/overrides/home.css +243 -0
  415. package/src/theme/styles/overrides/rail.css +337 -0
  416. package/src/theme/styles/overrides/rspress.css +62 -0
  417. package/src/theme/styles/overrides/scrollbar.css +25 -0
  418. package/src/theme/styles/overrides/section-card.css +114 -0
  419. package/src/theme/styles/overrides/sidebar.css +144 -0
  420. package/src/theme/styles/overrides/tokens.css +288 -0
  421. package/src/theme/styles/overrides/vscode.css +88 -0
  422. package/src/theme/styles/themes/amber.css +545 -0
  423. package/src/theme/styles/themes/arcade-fx.css +366 -0
  424. package/src/theme/styles/themes/arcade.css +273 -0
  425. package/src/theme/styles/themes/grannysmith.css +545 -0
  426. package/src/theme/styles/themes/honeycrisp.css +545 -0
  427. package/src/theme/styles/themes/midnight.css +273 -0
  428. package/src/theme/styles/themes/mulled.css +817 -0
@@ -0,0 +1,535 @@
1
+ import { CodeBlockRuntime } from '@rspress/core/theme'
2
+ import { match, P } from 'massaman/match'
3
+ import type React from 'react'
4
+
5
+ import './desktop-window.css'
6
+
7
+ export interface WindowTab {
8
+ /**
9
+ * Tab label text.
10
+ */
11
+ readonly name: string
12
+ /**
13
+ * Whether this tab is the active/selected tab.
14
+ */
15
+ readonly active?: boolean
16
+ }
17
+
18
+ export interface DesktopWindowProps {
19
+ /**
20
+ * Optional title text displayed in the title bar (12px mono, muted by default).
21
+ */
22
+ readonly title?: string
23
+ /**
24
+ * Optional tabs rendered in the title bar after the dots.
25
+ */
26
+ readonly tabs?: readonly WindowTab[]
27
+ /**
28
+ * Optional CSS class name for the window variant (e.g. `cp-window--browser`).
29
+ */
30
+ readonly variant?: string
31
+ /**
32
+ * Content rendered inside the window body.
33
+ */
34
+ readonly children: React.ReactNode
35
+ }
36
+
37
+ /**
38
+ * Base macOS-style window chrome with traffic-light dots.
39
+ * All other window components (BrowserWindow, IDEWindow, TerminalWindow)
40
+ * compose this component.
41
+ *
42
+ * @param props - Window configuration
43
+ * @returns React element with desktop window chrome
44
+ */
45
+ export function DesktopWindow({
46
+ title,
47
+ tabs,
48
+ variant,
49
+ children,
50
+ }: DesktopWindowProps): React.ReactElement | null {
51
+ if (import.meta.env.SSG_MD) {
52
+ return null
53
+ }
54
+
55
+ const className = match(variant)
56
+ .with(P.nonNullable, (v) => `cp-window ${v}`)
57
+ .otherwise(() => 'cp-window')
58
+
59
+ const titlebarCenter = match(tabs)
60
+ .with(P.nonNullable, (t) => (
61
+ <div className="cp-window__tabs">
62
+ {t.map((tab) => {
63
+ const tabClass = match(tab.active)
64
+ .with(true, () => 'cp-window__tab cp-window__tab--active')
65
+ .otherwise(() => 'cp-window__tab')
66
+
67
+ return (
68
+ <span key={tab.name} className={tabClass}>
69
+ <span className="cp-window__tab-dot" />
70
+ {tab.name}
71
+ </span>
72
+ )
73
+ })}
74
+ </div>
75
+ ))
76
+ .otherwise(() =>
77
+ match(title)
78
+ .with(P.nonNullable, (t) => <span className="cp-window__title">{t}</span>)
79
+ .otherwise(() => null)
80
+ )
81
+
82
+ return (
83
+ <div className={className}>
84
+ <div className="cp-window__titlebar">
85
+ <div className="cp-window__dots">
86
+ <span className="cp-window__dot cp-window__dot--close" />
87
+ <span className="cp-window__dot cp-window__dot--minimize" />
88
+ <span className="cp-window__dot cp-window__dot--maximize" />
89
+ </div>
90
+ {titlebarCenter}
91
+ </div>
92
+ <div className="cp-window__content">{children}</div>
93
+ </div>
94
+ )
95
+ }
96
+
97
+ export interface BrowserTab {
98
+ /**
99
+ * Tab label text.
100
+ */
101
+ readonly title: string
102
+ /**
103
+ * Optional icon rendered before the title.
104
+ */
105
+ readonly icon?: React.ReactNode
106
+ }
107
+
108
+ export interface BrowserWindowProps {
109
+ /**
110
+ * URL displayed in the address bar.
111
+ */
112
+ readonly url?: string
113
+ /**
114
+ * Optional tab rendered in the title bar with icon + title.
115
+ */
116
+ readonly tab?: BrowserTab
117
+ /**
118
+ * Optional tabs rendered in the title bar (passed through to DesktopWindow).
119
+ */
120
+ readonly tabs?: readonly WindowTab[]
121
+ /**
122
+ * Image source rendered as content when no children are provided.
123
+ */
124
+ readonly image?: string
125
+ /**
126
+ * Content rendered inside the window body. Takes priority over `image`.
127
+ */
128
+ readonly children?: React.ReactNode
129
+ }
130
+
131
+ /**
132
+ * Browser-style window with traffic-light dots, a configurable tab,
133
+ * and a Chrome-style URL bar with navigation controls.
134
+ *
135
+ * When `children` are provided they are rendered as the body content.
136
+ * Otherwise, if `image` is provided it is rendered as a full-width image.
137
+ *
138
+ * @param props - Props with optional URL, tab, tabs, image, and children
139
+ * @returns React element with browser window chrome
140
+ */
141
+ export function BrowserWindow({
142
+ url,
143
+ tab,
144
+ tabs,
145
+ image,
146
+ children,
147
+ }: BrowserWindowProps): React.ReactElement | null {
148
+ if (import.meta.env.SSG_MD) {
149
+ const title = match(tab)
150
+ .with(P.nonNullable, (t) => t.title)
151
+ .otherwise(() => 'Browser')
152
+ const urlLine = match(url)
153
+ .with(P.nonNullable, (u) => `\n\n${u}`)
154
+ .otherwise(() => '')
155
+ const header = `**${title}**${urlLine}`
156
+ return match(children)
157
+ .with(P.nonNullable, (c) => (
158
+ <>
159
+ {header}
160
+ {c}
161
+ </>
162
+ ))
163
+ .otherwise(() => <>{header}</>)
164
+ }
165
+
166
+ const body = match({ children, image })
167
+ .with({ children: P.nonNullable }, ({ children: c }) => (
168
+ <div className="cp-window__content">{c}</div>
169
+ ))
170
+ .with({ image: P.nonNullable }, ({ image: src }) => (
171
+ <div className="cp-window__content">
172
+ <img
173
+ src={src}
174
+ alt={match(tab)
175
+ .with(P.nonNullable, (t) => t.title)
176
+ .otherwise(() => '')}
177
+ />
178
+ </div>
179
+ ))
180
+ .otherwise(() => null)
181
+
182
+ const titlebarTabs = match(tabs)
183
+ .with(P.nonNullable, (t) => (
184
+ <div className="cp-window__tabs">
185
+ {t.map((windowTab) => {
186
+ const tabClass = match(windowTab.active)
187
+ .with(true, () => 'cp-window__tab cp-window__tab--active')
188
+ .otherwise(() => 'cp-window__tab')
189
+
190
+ return (
191
+ <span key={windowTab.name} className={tabClass}>
192
+ <span className="cp-window__tab-dot" />
193
+ {windowTab.name}
194
+ </span>
195
+ )
196
+ })}
197
+ </div>
198
+ ))
199
+ .otherwise(() => null)
200
+
201
+ return (
202
+ <div className="cp-window cp-window--browser">
203
+ <div className="cp-window__titlebar">
204
+ <div className="cp-window__dots">
205
+ <span className="cp-window__dot cp-window__dot--close" />
206
+ <span className="cp-window__dot cp-window__dot--minimize" />
207
+ <span className="cp-window__dot cp-window__dot--maximize" />
208
+ </div>
209
+ {match(tab)
210
+ .with(P.nonNullable, (t) => (
211
+ <div className="cp-browser__tab">
212
+ {match(t.icon)
213
+ .with(P.nonNullable, (icon) => <span className="cp-browser__tab-icon">{icon}</span>)
214
+ .otherwise(() => null)}
215
+ <span className="cp-browser__tab-title">{t.title}</span>
216
+ </div>
217
+ ))
218
+ .otherwise(() => null)}
219
+ {titlebarTabs}
220
+ </div>
221
+ {match(url)
222
+ .with(P.nonNullable, (u) => (
223
+ <div className="cp-browser__url-bar">
224
+ <BrowserNavButtons />
225
+ <span className="cp-browser__url">{u}</span>
226
+ <BrowserMenuButton />
227
+ </div>
228
+ ))
229
+ .otherwise(() => null)}
230
+ {body}
231
+ </div>
232
+ )
233
+ }
234
+
235
+ /**
236
+ * Back, forward, and refresh navigation buttons for the browser URL bar.
237
+ *
238
+ * @private
239
+ * @returns SVG icon group
240
+ */
241
+ function BrowserNavButtons(): React.ReactElement {
242
+ return (
243
+ <div className="cp-browser__nav">
244
+ <svg className="cp-browser__nav-icon" viewBox="0 0 16 16" fill="currentColor">
245
+ <path
246
+ d="M10.5 3L5.5 8l5 5"
247
+ stroke="currentColor"
248
+ strokeWidth="1.5"
249
+ fill="none"
250
+ strokeLinecap="round"
251
+ strokeLinejoin="round"
252
+ />
253
+ </svg>
254
+ <svg className="cp-browser__nav-icon" viewBox="0 0 16 16" fill="currentColor">
255
+ <path
256
+ d="M5.5 3L10.5 8l-5 5"
257
+ stroke="currentColor"
258
+ strokeWidth="1.5"
259
+ fill="none"
260
+ strokeLinecap="round"
261
+ strokeLinejoin="round"
262
+ />
263
+ </svg>
264
+ <svg className="cp-browser__nav-icon" viewBox="0 0 16 16" fill="currentColor">
265
+ <path
266
+ d="M13 8A5 5 0 113 8a5 5 0 0110 0z"
267
+ stroke="currentColor"
268
+ strokeWidth="1.5"
269
+ fill="none"
270
+ />
271
+ <path
272
+ d="M8 3v2"
273
+ stroke="currentColor"
274
+ strokeWidth="1.5"
275
+ strokeLinecap="round"
276
+ fill="none"
277
+ />
278
+ </svg>
279
+ </div>
280
+ )
281
+ }
282
+
283
+ /**
284
+ * Vertical three-dot menu button for the browser URL bar.
285
+ *
286
+ * @private
287
+ * @returns SVG icon
288
+ */
289
+ function BrowserMenuButton(): React.ReactElement {
290
+ return (
291
+ <svg className="cp-browser__menu-icon" viewBox="0 0 16 16" fill="currentColor">
292
+ <circle cx="8" cy="3" r="1.2" />
293
+ <circle cx="8" cy="8" r="1.2" />
294
+ <circle cx="8" cy="13" r="1.2" />
295
+ </svg>
296
+ )
297
+ }
298
+
299
+ export interface IDEFileTab {
300
+ /**
301
+ * Filename displayed in the tab.
302
+ */
303
+ readonly name: string
304
+ /**
305
+ * Whether this tab is the active/selected tab.
306
+ */
307
+ readonly active?: boolean
308
+ }
309
+
310
+ export interface IDEWindowProps {
311
+ /**
312
+ * File tabs displayed in the title bar. At least one should be `active`.
313
+ */
314
+ readonly files: readonly IDEFileTab[]
315
+ /**
316
+ * Raw code string to display. Define as an `export const` in MDX to preserve indentation.
317
+ */
318
+ readonly code?: string
319
+ /**
320
+ * Language identifier for the code block (e.g. `'ts'`, `'json'`). Only used with `code`.
321
+ */
322
+ readonly lang?: string
323
+ /**
324
+ * Content rendered inside the window body. Ignored when `code` is provided.
325
+ */
326
+ readonly children?: React.ReactNode
327
+ }
328
+
329
+ /**
330
+ * IDE-style window with file tabs in the title bar.
331
+ * When using `code`, define it as an `export const` in MDX — inline template
332
+ * literals in JSX attributes are dedented by the MDX compiler.
333
+ *
334
+ * @param props - Props with file tabs and code or children
335
+ * @returns React element with IDE window chrome
336
+ */
337
+ export function IDEWindow({
338
+ files,
339
+ code,
340
+ lang,
341
+ children,
342
+ }: IDEWindowProps): React.ReactElement | null {
343
+ if (import.meta.env.SSG_MD) {
344
+ const activeFile = files.find((f) => f.active)
345
+ const filename = match(activeFile)
346
+ .with(P.nonNullable, (f) => f.name)
347
+ .otherwise(() =>
348
+ match(files[0])
349
+ .with(P.nonNullable, (f) => f.name)
350
+ .otherwise(() => '')
351
+ )
352
+ const langId = lang ?? 'text'
353
+ const header = `**${filename}**\n\n`
354
+ const codeBlock = match(code)
355
+ .with(P.nonNullable, (c) => `${header}\`\`\`${langId}\n${c}\n\`\`\``)
356
+ .otherwise(() =>
357
+ match(children)
358
+ .with(P.nonNullable, () => header)
359
+ .otherwise(() => null)
360
+ )
361
+ return match(codeBlock)
362
+ .with(P.nonNullable, (md) => <>{md}</>)
363
+ .otherwise(() => null)
364
+ }
365
+
366
+ const tabs = files.map((file) => ({ name: file.name, active: file.active }))
367
+
368
+ const body = match(code)
369
+ .with(P.nonNullable, (c) => (
370
+ <div className="cp-window__code">
371
+ <CodeBlockRuntime
372
+ lang={match(lang)
373
+ .with(P.nonNullable, (l) => l)
374
+ .otherwise(() => 'text')}
375
+ code={c}
376
+ />
377
+ </div>
378
+ ))
379
+ .otherwise(() => children)
380
+
381
+ return (
382
+ <DesktopWindow variant="cp-window--ide" tabs={tabs}>
383
+ {body}
384
+ </DesktopWindow>
385
+ )
386
+ }
387
+
388
+ export type TerminalColor =
389
+ | 'red'
390
+ | 'green'
391
+ | 'blue'
392
+ | 'yellow'
393
+ | 'cyan'
394
+ | 'magenta'
395
+ | 'white'
396
+ | 'gray'
397
+ | 'success'
398
+ | 'error'
399
+ | 'warn'
400
+ | 'info'
401
+ | 'muted'
402
+ | 'bar'
403
+ | 'step'
404
+
405
+ export interface TerminalLineConfig {
406
+ /**
407
+ * The text content of this line.
408
+ */
409
+ readonly text: string
410
+ /**
411
+ * Whether this is a command (prefixed with `$`) or output. Defaults to `'output'`.
412
+ */
413
+ readonly type?: 'command' | 'output'
414
+ }
415
+
416
+ export interface TerminalWindowProps {
417
+ /**
418
+ * Optional title displayed in the center of the title bar (e.g. `"zsh"`, `"bash"`).
419
+ */
420
+ readonly title?: string
421
+ /**
422
+ * Lines to render in the terminal.
423
+ */
424
+ readonly children: React.ReactNode
425
+ }
426
+
427
+ /**
428
+ * Terminal-style window with dark background and monospace text.
429
+ * Use `<Command>` and `<Output>` children to compose the terminal content,
430
+ * or use `<Line>` for colored inline text.
431
+ *
432
+ * @param props - Props with optional title and children
433
+ * @returns React element with terminal window chrome
434
+ */
435
+ export function TerminalWindow({ title, children }: TerminalWindowProps): React.ReactElement {
436
+ if (import.meta.env.SSG_MD) {
437
+ return <>{children}</>
438
+ }
439
+
440
+ return (
441
+ <DesktopWindow variant="cp-window--terminal" title={title ?? 'Terminal'}>
442
+ {children}
443
+ </DesktopWindow>
444
+ )
445
+ }
446
+
447
+ export interface CommandProps {
448
+ /**
449
+ * The command text (rendered after a `$` prompt).
450
+ */
451
+ readonly children: React.ReactNode
452
+ }
453
+
454
+ /**
455
+ * A terminal command line prefixed with `$`.
456
+ *
457
+ * @param props - Props with command text
458
+ * @returns React element for a terminal command line
459
+ */
460
+ export function Command({ children }: CommandProps): React.ReactElement {
461
+ if (import.meta.env.SSG_MD) {
462
+ return <>{`$ ${String(children)}\n`}</>
463
+ }
464
+
465
+ return <span className="cp-term-line cp-term-line--command">{children}</span>
466
+ }
467
+
468
+ export interface OutputProps {
469
+ /**
470
+ * The output text.
471
+ */
472
+ readonly children: React.ReactNode
473
+ }
474
+
475
+ /**
476
+ * Terminal output text (no prompt prefix).
477
+ *
478
+ * @param props - Props with output text
479
+ * @returns React element for terminal output
480
+ */
481
+ export function Output({ children }: OutputProps): React.ReactElement {
482
+ if (import.meta.env.SSG_MD) {
483
+ return <>{`${String(children)}\n`}</>
484
+ }
485
+
486
+ return <span className="cp-term-line cp-term-line--output">{children}</span>
487
+ }
488
+
489
+ export interface LineProps {
490
+ /**
491
+ * Text color. Accepts terminal colors or semantic colors.
492
+ */
493
+ readonly color?: TerminalColor
494
+ /**
495
+ * Whether the text is bold.
496
+ */
497
+ readonly bold?: boolean
498
+ /**
499
+ * Whether the text is dimmed.
500
+ */
501
+ readonly dim?: boolean
502
+ /**
503
+ * The text content.
504
+ */
505
+ readonly children: React.ReactNode
506
+ }
507
+
508
+ /**
509
+ * Inline colored text for terminal output formatting.
510
+ * Combine multiple `<Line>` elements within `<Output>` for rich formatting.
511
+ *
512
+ * @param props - Props with color, bold, dim, and text content
513
+ * @returns React element with colored terminal text
514
+ */
515
+ export function Line({ color, bold, dim, children }: LineProps): React.ReactElement {
516
+ if (import.meta.env.SSG_MD) {
517
+ return <>{String(children)}</>
518
+ }
519
+
520
+ const classes = [
521
+ match(color)
522
+ .with(P.nonNullable, (c) => `cp-term-text--${c}`)
523
+ .otherwise(() => ''),
524
+ match(bold)
525
+ .with(true, () => 'cp-term-text--bold')
526
+ .otherwise(() => ''),
527
+ match(dim)
528
+ .with(true, () => 'cp-term-text--dim')
529
+ .otherwise(() => ''),
530
+ ]
531
+ .filter(Boolean)
532
+ .join(' ')
533
+
534
+ return <span className={classes}>{children}</span>
535
+ }
@@ -0,0 +1,158 @@
1
+ /* ── Field ── */
2
+
3
+ .cp-field {
4
+ padding: var(--cp-s-12) var(--cp-s-16);
5
+ border-bottom: 1px solid var(--cp-c-border);
6
+ }
7
+
8
+ .cp-field:last-child {
9
+ border-bottom: none;
10
+ }
11
+
12
+ .cp-field__header {
13
+ display: flex;
14
+ flex-direction: row;
15
+ align-items: center;
16
+ gap: var(--cp-s-8);
17
+ flex-wrap: wrap;
18
+ margin-bottom: var(--cp-s-4);
19
+ }
20
+
21
+ .cp-field__name {
22
+ font-family: var(--cp-font-family-mono);
23
+ font-weight: 600;
24
+ font-size: var(--cp-fs-field-name);
25
+ color: var(--cp-c-text-1);
26
+ }
27
+
28
+ .cp-field__name--deprecated {
29
+ text-decoration: line-through;
30
+ opacity: var(--cp-opacity-deprecated);
31
+ }
32
+
33
+ .cp-field__type {
34
+ display: inline-block;
35
+ padding: var(--cp-s-1) var(--cp-s-8);
36
+ border-radius: var(--cp-radius-pill);
37
+ font-family: var(--cp-font-family-mono);
38
+ font-size: var(--cp-fs-field-type);
39
+ color: var(--cp-c-text-2);
40
+ background: var(--cp-c-bg-soft);
41
+ }
42
+
43
+ .cp-field__badge {
44
+ font-size: var(--cp-fs-field-badge);
45
+ font-weight: 600;
46
+ text-transform: uppercase;
47
+ letter-spacing: var(--cp-letter-wide);
48
+ }
49
+
50
+ .cp-field__badge--required {
51
+ color: var(--cp-c-tint-red-fg);
52
+ }
53
+
54
+ .cp-field__badge--optional {
55
+ color: var(--cp-c-text-3);
56
+ }
57
+
58
+ .cp-field__badge--deprecated {
59
+ padding: var(--cp-s-1) var(--cp-s-8);
60
+ border-radius: var(--cp-radius-pill);
61
+ background: var(--cp-c-tint-amber-bg);
62
+ color: var(--cp-c-tint-amber-fg);
63
+ }
64
+
65
+ .cp-field__default {
66
+ font-size: var(--cp-fs-field-default);
67
+ color: var(--cp-c-text-3);
68
+ margin-bottom: var(--cp-s-2);
69
+ }
70
+
71
+ .cp-field__default code {
72
+ font-family: var(--cp-font-family-mono);
73
+ font-size: var(--cp-fs-field-default-code);
74
+ padding: var(--cp-s-1) var(--cp-s-4);
75
+ border-radius: var(--cp-radius-sm);
76
+ background: var(--cp-c-bg-soft);
77
+ color: var(--cp-c-text-2);
78
+ }
79
+
80
+ .cp-field__body {
81
+ font-size: var(--cp-fs-field-body);
82
+ color: var(--cp-c-text-2);
83
+ line-height: var(--cp-lh-relaxed);
84
+ }
85
+
86
+ .cp-field__body > p {
87
+ margin: 0;
88
+ }
89
+
90
+ /* ── FieldGroup (top-level) ── */
91
+
92
+ .cp-field-group {
93
+ margin: var(--cp-s-16) 0;
94
+ }
95
+
96
+ .cp-field-group__title {
97
+ font-size: var(--cp-fs-field-group-title);
98
+ font-weight: 600;
99
+ color: var(--cp-c-text-1);
100
+ margin-bottom: var(--cp-s-12);
101
+ padding-bottom: var(--cp-s-8);
102
+ border-bottom: 1px solid var(--cp-c-border);
103
+ }
104
+
105
+ /* ── FieldGroup (expandable) ── */
106
+
107
+ .cp-field-group--expandable {
108
+ margin: var(--cp-s-8) 0 0;
109
+ border: 1px solid var(--cp-c-border);
110
+ border-radius: var(--cp-radius-md-sm);
111
+ overflow: hidden;
112
+ }
113
+
114
+ .cp-field-group__trigger {
115
+ display: flex;
116
+ flex-direction: row;
117
+ align-items: center;
118
+ gap: var(--cp-s-6);
119
+ width: 100%;
120
+ padding: var(--cp-s-8) var(--cp-s-12);
121
+ border: none;
122
+ background: var(--cp-c-bg-soft);
123
+ color: var(--cp-c-text-2);
124
+ font-size: var(--cp-fs-field-trigger);
125
+ font-weight: 500;
126
+ cursor: pointer;
127
+ }
128
+
129
+ .cp-field-group__trigger:hover {
130
+ color: var(--cp-c-text-1);
131
+ }
132
+
133
+ .cp-field-group__chevron {
134
+ display: flex;
135
+ align-items: center;
136
+ justify-content: center;
137
+ width: var(--cp-size-chevron);
138
+ height: var(--cp-size-chevron);
139
+ color: var(--cp-c-text-3);
140
+ transition: transform var(--cp-duration-base);
141
+ }
142
+
143
+ .cp-field-group--expandable[data-open] .cp-field-group__chevron {
144
+ transform: rotate(90deg);
145
+ }
146
+
147
+ .cp-field-group__panel {
148
+ display: none;
149
+ padding: var(--cp-s-4) 0;
150
+ }
151
+
152
+ .cp-field-group--expandable[data-open] .cp-field-group__panel {
153
+ display: block;
154
+ }
155
+
156
+ .cp-field-group--expandable .cp-field {
157
+ padding-left: var(--cp-s-24);
158
+ }