@contractspec/bundle.library 3.4.2 → 3.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (479) hide show
  1. package/.turbo/turbo-build.log +494 -488
  2. package/CHANGELOG.md +61 -0
  3. package/dist/application/index.js +8 -8
  4. package/dist/application/mcp/cliMcp.js +8 -8
  5. package/dist/application/mcp/contractsMcp.js +8 -8
  6. package/dist/application/mcp/docsMcp.js +8 -8
  7. package/dist/application/mcp/index.js +8 -8
  8. package/dist/application/mcp/internalMcp.js +8 -8
  9. package/dist/application/mcp/providerRankingMcp.js +8 -8
  10. package/dist/bundles/LibraryBundle.d.ts +126 -0
  11. package/dist/bundles/LibraryBundle.js +139 -0
  12. package/dist/bundles/index.d.ts +1 -0
  13. package/dist/bundles/index.js +139 -0
  14. package/dist/components/docs/DocsIndexPage.js +91 -91
  15. package/dist/components/docs/advanced/AdvancedMCPPage.js +125 -125
  16. package/dist/components/docs/advanced/AdvancedOverlayEditorPage.js +49 -49
  17. package/dist/components/docs/advanced/AdvancedRenderersPage.js +51 -51
  18. package/dist/components/docs/advanced/AdvancedSpecExperimentsPage.js +35 -35
  19. package/dist/components/docs/advanced/AdvancedTelemetryPage.js +177 -177
  20. package/dist/components/docs/advanced/AdvancedWorkflowMonitoringPage.js +45 -45
  21. package/dist/components/docs/advanced/index.js +482 -482
  22. package/dist/components/docs/architecture/ArchitectureAppConfigPage.js +107 -107
  23. package/dist/components/docs/architecture/ArchitectureControlPlanePage.js +73 -73
  24. package/dist/components/docs/architecture/ArchitectureIntegrationBindingPage.js +117 -117
  25. package/dist/components/docs/architecture/ArchitectureKnowledgeBindingPage.js +175 -175
  26. package/dist/components/docs/architecture/ArchitectureMultiTenancyPage.js +71 -71
  27. package/dist/components/docs/architecture/ArchitectureOverviewPage.js +205 -205
  28. package/dist/components/docs/architecture/index.js +748 -748
  29. package/dist/components/docs/comparison/ComparisonAutomationPlatformsPage.js +117 -117
  30. package/dist/components/docs/comparison/ComparisonEnterprisePlatformsPage.js +111 -111
  31. package/dist/components/docs/comparison/ComparisonInternalToolBuildersPage.js +117 -117
  32. package/dist/components/docs/comparison/ComparisonOverviewPage.js +97 -97
  33. package/dist/components/docs/comparison/ComparisonWindmillPage.js +125 -125
  34. package/dist/components/docs/comparison/ComparisonWorkflowEnginesPage.js +171 -171
  35. package/dist/components/docs/comparison/index.js +738 -738
  36. package/dist/components/docs/ecosystem/IntegrationsPage.js +45 -45
  37. package/dist/components/docs/ecosystem/PluginsPage.js +73 -73
  38. package/dist/components/docs/ecosystem/RegistryPage.js +37 -37
  39. package/dist/components/docs/ecosystem/TemplatesPage.js +56 -56
  40. package/dist/components/docs/ecosystem/index.js +211 -211
  41. package/dist/components/docs/examples/DocsExamplesPage.js +21 -21
  42. package/dist/components/docs/examples/index.js +21 -21
  43. package/dist/components/docs/getting-started/CLIPage.js +95 -95
  44. package/dist/components/docs/getting-started/CompatibilityPage.js +81 -81
  45. package/dist/components/docs/getting-started/DataViewTutorialPage.js +57 -57
  46. package/dist/components/docs/getting-started/DeveloperToolsPage.js +61 -61
  47. package/dist/components/docs/getting-started/HelloWorldPage.js +77 -77
  48. package/dist/components/docs/getting-started/InstallationPage.js +65 -65
  49. package/dist/components/docs/getting-started/StartHerePage.js +51 -51
  50. package/dist/components/docs/getting-started/TroubleshootingPage.js +73 -73
  51. package/dist/components/docs/getting-started/VSCodeExtensionPage.js +171 -171
  52. package/dist/components/docs/getting-started/index.js +731 -731
  53. package/dist/components/docs/guides/GuideCIDiffGatingPage.js +80 -80
  54. package/dist/components/docs/guides/GuideContractTypesPage.js +232 -232
  55. package/dist/components/docs/guides/GuideDocsPipelinePage.js +82 -82
  56. package/dist/components/docs/guides/GuideGenerateDocsClientsSchemasPage.js +84 -84
  57. package/dist/components/docs/guides/GuideImportExistingCodebasesPage.js +324 -324
  58. package/dist/components/docs/guides/GuideNextjsOneEndpointPage.js +106 -106
  59. package/dist/components/docs/guides/GuideSpecValidationTypingPage.js +78 -78
  60. package/dist/components/docs/guides/GuidesIndexPage.js +43 -43
  61. package/dist/components/docs/guides/index.js +975 -975
  62. package/dist/components/docs/index.js +10791 -10791
  63. package/dist/components/docs/integrations/IntegrationsCircuitBreakersPage.js +17 -17
  64. package/dist/components/docs/integrations/IntegrationsElevenLabsPage.js +47 -47
  65. package/dist/components/docs/integrations/IntegrationsGithubPage.js +61 -61
  66. package/dist/components/docs/integrations/IntegrationsGmailPage.js +49 -49
  67. package/dist/components/docs/integrations/IntegrationsGoogleCalendarPage.js +33 -33
  68. package/dist/components/docs/integrations/IntegrationsHealthRoutingPage.js +65 -65
  69. package/dist/components/docs/integrations/IntegrationsMistralPage.js +69 -69
  70. package/dist/components/docs/integrations/IntegrationsOpenAIPage.js +65 -65
  71. package/dist/components/docs/integrations/IntegrationsOverviewPage.js +313 -313
  72. package/dist/components/docs/integrations/IntegrationsPostmarkPage.js +101 -101
  73. package/dist/components/docs/integrations/IntegrationsPowensPage.js +121 -121
  74. package/dist/components/docs/integrations/IntegrationsQdrantPage.js +49 -49
  75. package/dist/components/docs/integrations/IntegrationsResendPage.js +45 -45
  76. package/dist/components/docs/integrations/IntegrationsS3Page.js +57 -57
  77. package/dist/components/docs/integrations/IntegrationsSlackPage.js +63 -63
  78. package/dist/components/docs/integrations/IntegrationsSpecModelPage.js +139 -139
  79. package/dist/components/docs/integrations/IntegrationsStripePage.js +159 -159
  80. package/dist/components/docs/integrations/IntegrationsTwilioPage.js +61 -61
  81. package/dist/components/docs/integrations/IntegrationsWhatsappMetaPage.js +63 -63
  82. package/dist/components/docs/integrations/IntegrationsWhatsappTwilioPage.js +65 -65
  83. package/dist/components/docs/integrations/index.js +1642 -1642
  84. package/dist/components/docs/intent/ContractFirstApiPage.js +51 -51
  85. package/dist/components/docs/intent/DeterministicCodegenPage.js +59 -59
  86. package/dist/components/docs/intent/GenerateClientFromSchemaPage.js +85 -85
  87. package/dist/components/docs/intent/OpenapiAlternativePage.js +91 -91
  88. package/dist/components/docs/intent/SchemaValidationTypescriptPage.js +59 -59
  89. package/dist/components/docs/intent/SpecDrivenDevelopmentPage.js +51 -51
  90. package/dist/components/docs/intent/index.js +396 -396
  91. package/dist/components/docs/knowledge/KnowledgeCategoriesPage.js +371 -371
  92. package/dist/components/docs/knowledge/KnowledgeExamplesPage.js +79 -79
  93. package/dist/components/docs/knowledge/KnowledgeOverviewPage.js +185 -185
  94. package/dist/components/docs/knowledge/KnowledgeSourcesPage.js +187 -187
  95. package/dist/components/docs/knowledge/KnowledgeSpacesPage.js +141 -141
  96. package/dist/components/docs/knowledge/index.js +963 -963
  97. package/dist/components/docs/libraries/LibrariesAccessibilityPage.js +85 -85
  98. package/dist/components/docs/libraries/LibrariesAiAgentPage.js +63 -63
  99. package/dist/components/docs/libraries/LibrariesAnalyticsPage.js +33 -33
  100. package/dist/components/docs/libraries/LibrariesContentGenPage.js +43 -43
  101. package/dist/components/docs/libraries/LibrariesContractsPage.js +125 -125
  102. package/dist/components/docs/libraries/LibrariesCostTrackingPage.js +45 -45
  103. package/dist/components/docs/libraries/LibrariesDataBackendPage.js +69 -69
  104. package/dist/components/docs/libraries/LibrariesDataViewsPage.js +79 -79
  105. package/dist/components/docs/libraries/LibrariesDesignSystemPage.js +129 -129
  106. package/dist/components/docs/libraries/LibrariesEvolutionPage.js +49 -49
  107. package/dist/components/docs/libraries/LibrariesGraphQLPage.js +73 -73
  108. package/dist/components/docs/libraries/LibrariesGrowthPage.js +35 -35
  109. package/dist/components/docs/libraries/LibrariesMultiTenancyPage.js +43 -43
  110. package/dist/components/docs/libraries/LibrariesObservabilityPage.js +53 -53
  111. package/dist/components/docs/libraries/LibrariesOverlayEnginePage.js +45 -45
  112. package/dist/components/docs/libraries/LibrariesOverviewPage.js +191 -191
  113. package/dist/components/docs/libraries/LibrariesPersonalizationPage.js +47 -47
  114. package/dist/components/docs/libraries/LibrariesProgressiveDeliveryPage.js +53 -53
  115. package/dist/components/docs/libraries/LibrariesResiliencePage.js +49 -49
  116. package/dist/components/docs/libraries/LibrariesRuntimePage.js +87 -87
  117. package/dist/components/docs/libraries/LibrariesSLOPage.js +47 -47
  118. package/dist/components/docs/libraries/LibrariesSchemaPage.js +139 -139
  119. package/dist/components/docs/libraries/LibrariesSupportBotPage.js +57 -57
  120. package/dist/components/docs/libraries/LibrariesTestingPage.js +49 -49
  121. package/dist/components/docs/libraries/LibrariesUIKitPage.js +107 -107
  122. package/dist/components/docs/libraries/LibrariesWorkflowComposerPage.js +35 -35
  123. package/dist/components/docs/libraries/LibrariesWorkflowsPage.js +89 -89
  124. package/dist/components/docs/libraries/index.js +1919 -1919
  125. package/dist/components/docs/manifesto/ManifestoPage.js +79 -79
  126. package/dist/components/docs/ops/AutoEvolutionOpsPage.js +59 -59
  127. package/dist/components/docs/ops/DistributedTracingOpsPage.js +33 -33
  128. package/dist/components/docs/ops/index.js +92 -92
  129. package/dist/components/docs/reference/DocsMarkdownContent.js +27 -27
  130. package/dist/components/docs/reference/DocsReferenceContent.js +34 -34
  131. package/dist/components/docs/reference/DocsReferenceIndexClient.js +23 -23
  132. package/dist/components/docs/reference/DocsReferenceIndexPage.js +26 -26
  133. package/dist/components/docs/reference/DocsReferencePage.js +37 -37
  134. package/dist/components/docs/reference/index.js +63 -63
  135. package/dist/components/docs/safety/SafetyAuditingPage.js +161 -161
  136. package/dist/components/docs/safety/SafetyMigrationsPage.js +169 -169
  137. package/dist/components/docs/safety/SafetyOverviewPage.js +99 -99
  138. package/dist/components/docs/safety/SafetyPDPPage.js +137 -137
  139. package/dist/components/docs/safety/SafetySecurityTrustPage.js +95 -95
  140. package/dist/components/docs/safety/SafetySigningPage.js +39 -39
  141. package/dist/components/docs/safety/SafetyTenantIsolationPage.js +33 -33
  142. package/dist/components/docs/safety/index.js +733 -733
  143. package/dist/components/docs/shared/StudioPrompt.js +9 -9
  144. package/dist/components/docs/specs/SpecsCapabilitiesPage.js +61 -61
  145. package/dist/components/docs/specs/SpecsDataViewsPage.js +119 -119
  146. package/dist/components/docs/specs/SpecsOverlaysPage.js +171 -171
  147. package/dist/components/docs/specs/SpecsOverviewPage.js +167 -167
  148. package/dist/components/docs/specs/SpecsPolicyPage.js +179 -179
  149. package/dist/components/docs/specs/SpecsWorkflowsPage.js +141 -141
  150. package/dist/components/docs/specs/index.js +838 -838
  151. package/dist/components/docs/studio/StudioBYOKPage.js +9 -9
  152. package/dist/components/docs/studio/StudioDeploymentsPage.js +9 -9
  153. package/dist/components/docs/studio/StudioGettingStartedPage.js +9 -9
  154. package/dist/components/docs/studio/StudioIntegrationsPage.js +9 -9
  155. package/dist/components/docs/studio/StudioOverviewPage.js +33 -33
  156. package/dist/components/docs/studio/StudioVisualBuilderPage.js +9 -9
  157. package/dist/components/docs/studio/index.js +78 -78
  158. package/dist/components/integrations/index.js +209 -209
  159. package/dist/components/integrations/molecules/IntegrationCard.js +33 -33
  160. package/dist/components/integrations/organisms/IntegrationMarketplace.js +71 -71
  161. package/dist/components/integrations/organisms/IntegrationSettings.js +98 -98
  162. package/dist/components/integrations/organisms/KnowledgeSourceList.js +40 -40
  163. package/dist/components/legal/PrivacyTemplate.js +477 -477
  164. package/dist/components/legal/TermsTemplate.js +421 -421
  165. package/dist/components/legal/index.js +898 -898
  166. package/dist/components/shared/FeatureGateNotice.js +13 -13
  167. package/dist/components/shared/index.js +13 -13
  168. package/dist/components/shell/WorkspaceHeader.js +37 -37
  169. package/dist/components/shell/WorkspaceProjectShellLayout.js +77 -77
  170. package/dist/components/shell/WorkspaceShellRenderer.d.ts +17 -0
  171. package/dist/components/shell/WorkspaceShellRenderer.js +229 -0
  172. package/dist/components/shell/WorkspaceSidebar.js +27 -27
  173. package/dist/components/shell/index.d.ts +1 -0
  174. package/dist/components/shell/index.js +140 -77
  175. package/dist/components/templates/index.js +272 -272
  176. package/dist/components/templates/messaging/ConversationList.js +27 -27
  177. package/dist/components/templates/messaging/MessageComposer.js +27 -27
  178. package/dist/components/templates/messaging/MessageThread.js +18 -18
  179. package/dist/components/templates/messaging/MessagingWorkspace.js +65 -65
  180. package/dist/components/templates/messaging/index.js +65 -65
  181. package/dist/components/templates/recipes/LanguageSwitcher.js +5 -5
  182. package/dist/components/templates/recipes/RecipeCard.js +26 -26
  183. package/dist/components/templates/recipes/RecipeDetail.js +33 -33
  184. package/dist/components/templates/recipes/RecipeList.js +80 -80
  185. package/dist/components/templates/recipes/index.js +80 -80
  186. package/dist/components/templates/todos/FilterBar.js +39 -39
  187. package/dist/components/templates/todos/TaskForm.js +43 -43
  188. package/dist/components/templates/todos/TaskItem.js +30 -30
  189. package/dist/components/templates/todos/TaskList.js +127 -127
  190. package/dist/components/templates/todos/index.js +127 -127
  191. package/dist/index.js +12323 -12260
  192. package/dist/infrastructure/elysia/index.js +8 -8
  193. package/dist/infrastructure/elysia/logger.js +8 -8
  194. package/dist/infrastructure/index.js +8 -8
  195. package/dist/libs/posthog/client.js +2 -2
  196. package/dist/node/application/index.js +8 -8
  197. package/dist/node/application/mcp/cliMcp.js +8 -8
  198. package/dist/node/application/mcp/contractsMcp.js +8 -8
  199. package/dist/node/application/mcp/docsMcp.js +8 -8
  200. package/dist/node/application/mcp/index.js +8 -8
  201. package/dist/node/application/mcp/internalMcp.js +8 -8
  202. package/dist/node/application/mcp/providerRankingMcp.js +8 -8
  203. package/dist/node/bundles/LibraryBundle.js +138 -0
  204. package/dist/node/bundles/index.js +138 -0
  205. package/dist/node/components/docs/DocsIndexPage.js +91 -91
  206. package/dist/node/components/docs/advanced/AdvancedMCPPage.js +125 -125
  207. package/dist/node/components/docs/advanced/AdvancedOverlayEditorPage.js +49 -49
  208. package/dist/node/components/docs/advanced/AdvancedRenderersPage.js +51 -51
  209. package/dist/node/components/docs/advanced/AdvancedSpecExperimentsPage.js +35 -35
  210. package/dist/node/components/docs/advanced/AdvancedTelemetryPage.js +177 -177
  211. package/dist/node/components/docs/advanced/AdvancedWorkflowMonitoringPage.js +45 -45
  212. package/dist/node/components/docs/advanced/index.js +482 -482
  213. package/dist/node/components/docs/architecture/ArchitectureAppConfigPage.js +107 -107
  214. package/dist/node/components/docs/architecture/ArchitectureControlPlanePage.js +73 -73
  215. package/dist/node/components/docs/architecture/ArchitectureIntegrationBindingPage.js +117 -117
  216. package/dist/node/components/docs/architecture/ArchitectureKnowledgeBindingPage.js +175 -175
  217. package/dist/node/components/docs/architecture/ArchitectureMultiTenancyPage.js +71 -71
  218. package/dist/node/components/docs/architecture/ArchitectureOverviewPage.js +205 -205
  219. package/dist/node/components/docs/architecture/index.js +748 -748
  220. package/dist/node/components/docs/comparison/ComparisonAutomationPlatformsPage.js +117 -117
  221. package/dist/node/components/docs/comparison/ComparisonEnterprisePlatformsPage.js +111 -111
  222. package/dist/node/components/docs/comparison/ComparisonInternalToolBuildersPage.js +117 -117
  223. package/dist/node/components/docs/comparison/ComparisonOverviewPage.js +97 -97
  224. package/dist/node/components/docs/comparison/ComparisonWindmillPage.js +125 -125
  225. package/dist/node/components/docs/comparison/ComparisonWorkflowEnginesPage.js +171 -171
  226. package/dist/node/components/docs/comparison/index.js +738 -738
  227. package/dist/node/components/docs/ecosystem/IntegrationsPage.js +45 -45
  228. package/dist/node/components/docs/ecosystem/PluginsPage.js +73 -73
  229. package/dist/node/components/docs/ecosystem/RegistryPage.js +37 -37
  230. package/dist/node/components/docs/ecosystem/TemplatesPage.js +56 -56
  231. package/dist/node/components/docs/ecosystem/index.js +211 -211
  232. package/dist/node/components/docs/examples/DocsExamplesPage.js +21 -21
  233. package/dist/node/components/docs/examples/index.js +21 -21
  234. package/dist/node/components/docs/getting-started/CLIPage.js +95 -95
  235. package/dist/node/components/docs/getting-started/CompatibilityPage.js +81 -81
  236. package/dist/node/components/docs/getting-started/DataViewTutorialPage.js +57 -57
  237. package/dist/node/components/docs/getting-started/DeveloperToolsPage.js +61 -61
  238. package/dist/node/components/docs/getting-started/HelloWorldPage.js +77 -77
  239. package/dist/node/components/docs/getting-started/InstallationPage.js +65 -65
  240. package/dist/node/components/docs/getting-started/StartHerePage.js +51 -51
  241. package/dist/node/components/docs/getting-started/TroubleshootingPage.js +73 -73
  242. package/dist/node/components/docs/getting-started/VSCodeExtensionPage.js +171 -171
  243. package/dist/node/components/docs/getting-started/index.js +731 -731
  244. package/dist/node/components/docs/guides/GuideCIDiffGatingPage.js +80 -80
  245. package/dist/node/components/docs/guides/GuideContractTypesPage.js +232 -232
  246. package/dist/node/components/docs/guides/GuideDocsPipelinePage.js +82 -82
  247. package/dist/node/components/docs/guides/GuideGenerateDocsClientsSchemasPage.js +84 -84
  248. package/dist/node/components/docs/guides/GuideImportExistingCodebasesPage.js +324 -324
  249. package/dist/node/components/docs/guides/GuideNextjsOneEndpointPage.js +106 -106
  250. package/dist/node/components/docs/guides/GuideSpecValidationTypingPage.js +78 -78
  251. package/dist/node/components/docs/guides/GuidesIndexPage.js +43 -43
  252. package/dist/node/components/docs/guides/index.js +975 -975
  253. package/dist/node/components/docs/index.js +10791 -10791
  254. package/dist/node/components/docs/integrations/IntegrationsCircuitBreakersPage.js +17 -17
  255. package/dist/node/components/docs/integrations/IntegrationsElevenLabsPage.js +47 -47
  256. package/dist/node/components/docs/integrations/IntegrationsGithubPage.js +61 -61
  257. package/dist/node/components/docs/integrations/IntegrationsGmailPage.js +49 -49
  258. package/dist/node/components/docs/integrations/IntegrationsGoogleCalendarPage.js +33 -33
  259. package/dist/node/components/docs/integrations/IntegrationsHealthRoutingPage.js +65 -65
  260. package/dist/node/components/docs/integrations/IntegrationsMistralPage.js +69 -69
  261. package/dist/node/components/docs/integrations/IntegrationsOpenAIPage.js +65 -65
  262. package/dist/node/components/docs/integrations/IntegrationsOverviewPage.js +313 -313
  263. package/dist/node/components/docs/integrations/IntegrationsPostmarkPage.js +101 -101
  264. package/dist/node/components/docs/integrations/IntegrationsPowensPage.js +121 -121
  265. package/dist/node/components/docs/integrations/IntegrationsQdrantPage.js +49 -49
  266. package/dist/node/components/docs/integrations/IntegrationsResendPage.js +45 -45
  267. package/dist/node/components/docs/integrations/IntegrationsS3Page.js +57 -57
  268. package/dist/node/components/docs/integrations/IntegrationsSlackPage.js +63 -63
  269. package/dist/node/components/docs/integrations/IntegrationsSpecModelPage.js +139 -139
  270. package/dist/node/components/docs/integrations/IntegrationsStripePage.js +159 -159
  271. package/dist/node/components/docs/integrations/IntegrationsTwilioPage.js +61 -61
  272. package/dist/node/components/docs/integrations/IntegrationsWhatsappMetaPage.js +63 -63
  273. package/dist/node/components/docs/integrations/IntegrationsWhatsappTwilioPage.js +65 -65
  274. package/dist/node/components/docs/integrations/index.js +1642 -1642
  275. package/dist/node/components/docs/intent/ContractFirstApiPage.js +51 -51
  276. package/dist/node/components/docs/intent/DeterministicCodegenPage.js +59 -59
  277. package/dist/node/components/docs/intent/GenerateClientFromSchemaPage.js +85 -85
  278. package/dist/node/components/docs/intent/OpenapiAlternativePage.js +91 -91
  279. package/dist/node/components/docs/intent/SchemaValidationTypescriptPage.js +59 -59
  280. package/dist/node/components/docs/intent/SpecDrivenDevelopmentPage.js +51 -51
  281. package/dist/node/components/docs/intent/index.js +396 -396
  282. package/dist/node/components/docs/knowledge/KnowledgeCategoriesPage.js +371 -371
  283. package/dist/node/components/docs/knowledge/KnowledgeExamplesPage.js +79 -79
  284. package/dist/node/components/docs/knowledge/KnowledgeOverviewPage.js +185 -185
  285. package/dist/node/components/docs/knowledge/KnowledgeSourcesPage.js +187 -187
  286. package/dist/node/components/docs/knowledge/KnowledgeSpacesPage.js +141 -141
  287. package/dist/node/components/docs/knowledge/index.js +963 -963
  288. package/dist/node/components/docs/libraries/LibrariesAccessibilityPage.js +85 -85
  289. package/dist/node/components/docs/libraries/LibrariesAiAgentPage.js +63 -63
  290. package/dist/node/components/docs/libraries/LibrariesAnalyticsPage.js +33 -33
  291. package/dist/node/components/docs/libraries/LibrariesContentGenPage.js +43 -43
  292. package/dist/node/components/docs/libraries/LibrariesContractsPage.js +125 -125
  293. package/dist/node/components/docs/libraries/LibrariesCostTrackingPage.js +45 -45
  294. package/dist/node/components/docs/libraries/LibrariesDataBackendPage.js +69 -69
  295. package/dist/node/components/docs/libraries/LibrariesDataViewsPage.js +79 -79
  296. package/dist/node/components/docs/libraries/LibrariesDesignSystemPage.js +129 -129
  297. package/dist/node/components/docs/libraries/LibrariesEvolutionPage.js +49 -49
  298. package/dist/node/components/docs/libraries/LibrariesGraphQLPage.js +73 -73
  299. package/dist/node/components/docs/libraries/LibrariesGrowthPage.js +35 -35
  300. package/dist/node/components/docs/libraries/LibrariesMultiTenancyPage.js +43 -43
  301. package/dist/node/components/docs/libraries/LibrariesObservabilityPage.js +53 -53
  302. package/dist/node/components/docs/libraries/LibrariesOverlayEnginePage.js +45 -45
  303. package/dist/node/components/docs/libraries/LibrariesOverviewPage.js +191 -191
  304. package/dist/node/components/docs/libraries/LibrariesPersonalizationPage.js +47 -47
  305. package/dist/node/components/docs/libraries/LibrariesProgressiveDeliveryPage.js +53 -53
  306. package/dist/node/components/docs/libraries/LibrariesResiliencePage.js +49 -49
  307. package/dist/node/components/docs/libraries/LibrariesRuntimePage.js +87 -87
  308. package/dist/node/components/docs/libraries/LibrariesSLOPage.js +47 -47
  309. package/dist/node/components/docs/libraries/LibrariesSchemaPage.js +139 -139
  310. package/dist/node/components/docs/libraries/LibrariesSupportBotPage.js +57 -57
  311. package/dist/node/components/docs/libraries/LibrariesTestingPage.js +49 -49
  312. package/dist/node/components/docs/libraries/LibrariesUIKitPage.js +107 -107
  313. package/dist/node/components/docs/libraries/LibrariesWorkflowComposerPage.js +35 -35
  314. package/dist/node/components/docs/libraries/LibrariesWorkflowsPage.js +89 -89
  315. package/dist/node/components/docs/libraries/index.js +1919 -1919
  316. package/dist/node/components/docs/manifesto/ManifestoPage.js +79 -79
  317. package/dist/node/components/docs/ops/AutoEvolutionOpsPage.js +59 -59
  318. package/dist/node/components/docs/ops/DistributedTracingOpsPage.js +33 -33
  319. package/dist/node/components/docs/ops/index.js +92 -92
  320. package/dist/node/components/docs/reference/DocsMarkdownContent.js +27 -27
  321. package/dist/node/components/docs/reference/DocsReferenceContent.js +34 -34
  322. package/dist/node/components/docs/reference/DocsReferenceIndexClient.js +23 -23
  323. package/dist/node/components/docs/reference/DocsReferenceIndexPage.js +26 -26
  324. package/dist/node/components/docs/reference/DocsReferencePage.js +37 -37
  325. package/dist/node/components/docs/reference/index.js +63 -63
  326. package/dist/node/components/docs/safety/SafetyAuditingPage.js +161 -161
  327. package/dist/node/components/docs/safety/SafetyMigrationsPage.js +169 -169
  328. package/dist/node/components/docs/safety/SafetyOverviewPage.js +99 -99
  329. package/dist/node/components/docs/safety/SafetyPDPPage.js +137 -137
  330. package/dist/node/components/docs/safety/SafetySecurityTrustPage.js +95 -95
  331. package/dist/node/components/docs/safety/SafetySigningPage.js +39 -39
  332. package/dist/node/components/docs/safety/SafetyTenantIsolationPage.js +33 -33
  333. package/dist/node/components/docs/safety/index.js +733 -733
  334. package/dist/node/components/docs/shared/StudioPrompt.js +9 -9
  335. package/dist/node/components/docs/specs/SpecsCapabilitiesPage.js +61 -61
  336. package/dist/node/components/docs/specs/SpecsDataViewsPage.js +119 -119
  337. package/dist/node/components/docs/specs/SpecsOverlaysPage.js +171 -171
  338. package/dist/node/components/docs/specs/SpecsOverviewPage.js +167 -167
  339. package/dist/node/components/docs/specs/SpecsPolicyPage.js +179 -179
  340. package/dist/node/components/docs/specs/SpecsWorkflowsPage.js +141 -141
  341. package/dist/node/components/docs/specs/index.js +838 -838
  342. package/dist/node/components/docs/studio/StudioBYOKPage.js +9 -9
  343. package/dist/node/components/docs/studio/StudioDeploymentsPage.js +9 -9
  344. package/dist/node/components/docs/studio/StudioGettingStartedPage.js +9 -9
  345. package/dist/node/components/docs/studio/StudioIntegrationsPage.js +9 -9
  346. package/dist/node/components/docs/studio/StudioOverviewPage.js +33 -33
  347. package/dist/node/components/docs/studio/StudioVisualBuilderPage.js +9 -9
  348. package/dist/node/components/docs/studio/index.js +78 -78
  349. package/dist/node/components/integrations/index.js +209 -209
  350. package/dist/node/components/integrations/molecules/IntegrationCard.js +33 -33
  351. package/dist/node/components/integrations/organisms/IntegrationMarketplace.js +71 -71
  352. package/dist/node/components/integrations/organisms/IntegrationSettings.js +98 -98
  353. package/dist/node/components/integrations/organisms/KnowledgeSourceList.js +40 -40
  354. package/dist/node/components/legal/PrivacyTemplate.js +477 -477
  355. package/dist/node/components/legal/TermsTemplate.js +421 -421
  356. package/dist/node/components/legal/index.js +898 -898
  357. package/dist/node/components/shared/FeatureGateNotice.js +13 -13
  358. package/dist/node/components/shared/index.js +13 -13
  359. package/dist/node/components/shell/WorkspaceHeader.js +37 -37
  360. package/dist/node/components/shell/WorkspaceProjectShellLayout.js +77 -77
  361. package/dist/node/components/shell/WorkspaceShellRenderer.js +228 -0
  362. package/dist/node/components/shell/WorkspaceSidebar.js +27 -27
  363. package/dist/node/components/shell/index.js +140 -77
  364. package/dist/node/components/templates/index.js +272 -272
  365. package/dist/node/components/templates/messaging/ConversationList.js +27 -27
  366. package/dist/node/components/templates/messaging/MessageComposer.js +27 -27
  367. package/dist/node/components/templates/messaging/MessageThread.js +18 -18
  368. package/dist/node/components/templates/messaging/MessagingWorkspace.js +65 -65
  369. package/dist/node/components/templates/messaging/index.js +65 -65
  370. package/dist/node/components/templates/recipes/LanguageSwitcher.js +5 -5
  371. package/dist/node/components/templates/recipes/RecipeCard.js +26 -26
  372. package/dist/node/components/templates/recipes/RecipeDetail.js +33 -33
  373. package/dist/node/components/templates/recipes/RecipeList.js +80 -80
  374. package/dist/node/components/templates/recipes/index.js +80 -80
  375. package/dist/node/components/templates/todos/FilterBar.js +39 -39
  376. package/dist/node/components/templates/todos/TaskForm.js +43 -43
  377. package/dist/node/components/templates/todos/TaskItem.js +30 -30
  378. package/dist/node/components/templates/todos/TaskList.js +127 -127
  379. package/dist/node/components/templates/todos/index.js +127 -127
  380. package/dist/node/index.js +12323 -12260
  381. package/dist/node/infrastructure/elysia/index.js +8 -8
  382. package/dist/node/infrastructure/elysia/logger.js +8 -8
  383. package/dist/node/infrastructure/index.js +8 -8
  384. package/dist/node/libs/posthog/client.js +2 -2
  385. package/dist/node/presentation/features/atoms/FeatureIcon/FeatureIcon.js +3 -3
  386. package/dist/node/presentation/features/atoms/FeatureIcon/index.js +3 -3
  387. package/dist/node/presentation/features/atoms/index.js +3 -3
  388. package/dist/node/presentation/features/index.js +915 -915
  389. package/dist/node/presentation/features/molecules/FeatureCard/FeatureCard.js +101 -101
  390. package/dist/node/presentation/features/molecules/FeatureCard/index.js +101 -101
  391. package/dist/node/presentation/features/molecules/FeatureCategoryHeader/FeatureCategoryHeader.js +15 -15
  392. package/dist/node/presentation/features/molecules/FeatureCategoryHeader/index.js +15 -15
  393. package/dist/node/presentation/features/molecules/FeatureFilters/FeatureFilters.js +23 -23
  394. package/dist/node/presentation/features/molecules/FeatureFilters/index.js +23 -23
  395. package/dist/node/presentation/features/molecules/FeatureHoverPreview/FeatureHoverPreview.js +67 -67
  396. package/dist/node/presentation/features/molecules/FeatureHoverPreview/index.js +67 -67
  397. package/dist/node/presentation/features/molecules/index.js +139 -139
  398. package/dist/node/presentation/features/organisms/FeatureDataViewsList.js +7 -7
  399. package/dist/node/presentation/features/organisms/FeatureDetail/FeatureDetail.js +57 -57
  400. package/dist/node/presentation/features/organisms/FeatureDetail/index.js +57 -57
  401. package/dist/node/presentation/features/organisms/FeatureDiscovery/FeatureDiscovery.js +183 -183
  402. package/dist/node/presentation/features/organisms/FeatureDiscovery/index.js +183 -183
  403. package/dist/node/presentation/features/organisms/FeatureEventsList.js +7 -7
  404. package/dist/node/presentation/features/organisms/FeatureFormsList.js +7 -7
  405. package/dist/node/presentation/features/organisms/FeatureOperationsList.js +7 -7
  406. package/dist/node/presentation/features/organisms/FeaturePresentationsList.js +7 -7
  407. package/dist/node/presentation/features/organisms/index.js +275 -275
  408. package/dist/node/presentation/features/templates/FeatureDataViewDetailTemplate/FeatureDataViewDetailTemplate.js +126 -126
  409. package/dist/node/presentation/features/templates/FeatureDataViewDetailTemplate/index.js +126 -126
  410. package/dist/node/presentation/features/templates/FeatureDataViewsTemplate/FeatureDataViewsTemplate.js +16 -16
  411. package/dist/node/presentation/features/templates/FeatureDataViewsTemplate/index.js +16 -16
  412. package/dist/node/presentation/features/templates/FeatureEventDetailTemplate/FeatureEventDetailTemplate.js +112 -112
  413. package/dist/node/presentation/features/templates/FeatureEventDetailTemplate/index.js +112 -112
  414. package/dist/node/presentation/features/templates/FeatureEventsTemplate/FeatureEventsTemplate.js +16 -16
  415. package/dist/node/presentation/features/templates/FeatureEventsTemplate/index.js +16 -16
  416. package/dist/node/presentation/features/templates/FeatureFormDetailTemplate/FeatureFormDetailTemplate.js +126 -126
  417. package/dist/node/presentation/features/templates/FeatureFormDetailTemplate/index.js +126 -126
  418. package/dist/node/presentation/features/templates/FeatureFormsTemplate/FeatureFormsTemplate.js +16 -16
  419. package/dist/node/presentation/features/templates/FeatureFormsTemplate/index.js +16 -16
  420. package/dist/node/presentation/features/templates/FeatureOperationDetailTemplate/FeatureOperationDetailTemplate.js +110 -110
  421. package/dist/node/presentation/features/templates/FeatureOperationDetailTemplate/index.js +110 -110
  422. package/dist/node/presentation/features/templates/FeatureOperationsTemplate/FeatureOperationsTemplate.js +16 -16
  423. package/dist/node/presentation/features/templates/FeatureOperationsTemplate/index.js +16 -16
  424. package/dist/node/presentation/features/templates/FeatureOverviewTemplate/FeatureOverviewTemplate.js +66 -66
  425. package/dist/node/presentation/features/templates/FeatureOverviewTemplate/index.js +66 -66
  426. package/dist/node/presentation/features/templates/FeaturePresentationDetailTemplate/FeaturePresentationDetailTemplate.js +112 -112
  427. package/dist/node/presentation/features/templates/FeaturePresentationDetailTemplate/index.js +112 -112
  428. package/dist/node/presentation/features/templates/FeaturePresentationsTemplate/FeaturePresentationsTemplate.js +16 -16
  429. package/dist/node/presentation/features/templates/FeaturePresentationsTemplate/index.js +16 -16
  430. package/dist/presentation/features/atoms/FeatureIcon/FeatureIcon.js +3 -3
  431. package/dist/presentation/features/atoms/FeatureIcon/index.js +3 -3
  432. package/dist/presentation/features/atoms/index.js +3 -3
  433. package/dist/presentation/features/index.js +915 -915
  434. package/dist/presentation/features/molecules/FeatureCard/FeatureCard.js +101 -101
  435. package/dist/presentation/features/molecules/FeatureCard/index.js +101 -101
  436. package/dist/presentation/features/molecules/FeatureCategoryHeader/FeatureCategoryHeader.js +15 -15
  437. package/dist/presentation/features/molecules/FeatureCategoryHeader/index.js +15 -15
  438. package/dist/presentation/features/molecules/FeatureFilters/FeatureFilters.js +23 -23
  439. package/dist/presentation/features/molecules/FeatureFilters/index.js +23 -23
  440. package/dist/presentation/features/molecules/FeatureHoverPreview/FeatureHoverPreview.js +67 -67
  441. package/dist/presentation/features/molecules/FeatureHoverPreview/index.js +67 -67
  442. package/dist/presentation/features/molecules/index.js +139 -139
  443. package/dist/presentation/features/organisms/FeatureDataViewsList.js +7 -7
  444. package/dist/presentation/features/organisms/FeatureDetail/FeatureDetail.js +57 -57
  445. package/dist/presentation/features/organisms/FeatureDetail/index.js +57 -57
  446. package/dist/presentation/features/organisms/FeatureDiscovery/FeatureDiscovery.js +183 -183
  447. package/dist/presentation/features/organisms/FeatureDiscovery/index.js +183 -183
  448. package/dist/presentation/features/organisms/FeatureEventsList.js +7 -7
  449. package/dist/presentation/features/organisms/FeatureFormsList.js +7 -7
  450. package/dist/presentation/features/organisms/FeatureOperationsList.js +7 -7
  451. package/dist/presentation/features/organisms/FeaturePresentationsList.js +7 -7
  452. package/dist/presentation/features/organisms/index.js +275 -275
  453. package/dist/presentation/features/templates/FeatureDataViewDetailTemplate/FeatureDataViewDetailTemplate.js +126 -126
  454. package/dist/presentation/features/templates/FeatureDataViewDetailTemplate/index.js +126 -126
  455. package/dist/presentation/features/templates/FeatureDataViewsTemplate/FeatureDataViewsTemplate.js +16 -16
  456. package/dist/presentation/features/templates/FeatureDataViewsTemplate/index.js +16 -16
  457. package/dist/presentation/features/templates/FeatureEventDetailTemplate/FeatureEventDetailTemplate.js +112 -112
  458. package/dist/presentation/features/templates/FeatureEventDetailTemplate/index.js +112 -112
  459. package/dist/presentation/features/templates/FeatureEventsTemplate/FeatureEventsTemplate.js +16 -16
  460. package/dist/presentation/features/templates/FeatureEventsTemplate/index.js +16 -16
  461. package/dist/presentation/features/templates/FeatureFormDetailTemplate/FeatureFormDetailTemplate.js +126 -126
  462. package/dist/presentation/features/templates/FeatureFormDetailTemplate/index.js +126 -126
  463. package/dist/presentation/features/templates/FeatureFormsTemplate/FeatureFormsTemplate.js +16 -16
  464. package/dist/presentation/features/templates/FeatureFormsTemplate/index.js +16 -16
  465. package/dist/presentation/features/templates/FeatureOperationDetailTemplate/FeatureOperationDetailTemplate.js +110 -110
  466. package/dist/presentation/features/templates/FeatureOperationDetailTemplate/index.js +110 -110
  467. package/dist/presentation/features/templates/FeatureOperationsTemplate/FeatureOperationsTemplate.js +16 -16
  468. package/dist/presentation/features/templates/FeatureOperationsTemplate/index.js +16 -16
  469. package/dist/presentation/features/templates/FeatureOverviewTemplate/FeatureOverviewTemplate.js +66 -66
  470. package/dist/presentation/features/templates/FeatureOverviewTemplate/index.js +66 -66
  471. package/dist/presentation/features/templates/FeaturePresentationDetailTemplate/FeaturePresentationDetailTemplate.js +112 -112
  472. package/dist/presentation/features/templates/FeaturePresentationDetailTemplate/index.js +112 -112
  473. package/dist/presentation/features/templates/FeaturePresentationsTemplate/FeaturePresentationsTemplate.js +16 -16
  474. package/dist/presentation/features/templates/FeaturePresentationsTemplate/index.js +16 -16
  475. package/package.json +71 -22
  476. package/src/bundles/LibraryBundle.ts +152 -0
  477. package/src/bundles/index.ts +1 -0
  478. package/src/components/shell/WorkspaceShellRenderer.tsx +90 -0
  479. package/src/components/shell/index.ts +1 -0
@@ -2,396 +2,396 @@
2
2
  // src/components/docs/specs/SpecsOverviewPage.tsx
3
3
  import Link from "@contractspec/lib.ui-link";
4
4
  import { ChevronRight } from "lucide-react";
5
- import { jsxDEV } from "react/jsx-dev-runtime";
5
+ import { jsx, jsxs } from "react/jsx-runtime";
6
6
  function SpecsOverviewPage() {
7
- return /* @__PURE__ */ jsxDEV("div", {
7
+ return /* @__PURE__ */ jsxs("div", {
8
8
  className: "space-y-8",
9
9
  children: [
10
- /* @__PURE__ */ jsxDEV("div", {
10
+ /* @__PURE__ */ jsxs("div", {
11
11
  className: "space-y-4",
12
12
  children: [
13
- /* @__PURE__ */ jsxDEV("h1", {
13
+ /* @__PURE__ */ jsx("h1", {
14
14
  className: "text-4xl font-bold",
15
15
  children: "Specifications Overview"
16
- }, undefined, false, undefined, this),
17
- /* @__PURE__ */ jsxDEV("p", {
16
+ }),
17
+ /* @__PURE__ */ jsxs("p", {
18
18
  className: "text-muted-foreground",
19
19
  children: [
20
20
  "ContractSpec is built on a ",
21
- /* @__PURE__ */ jsxDEV("strong", {
21
+ /* @__PURE__ */ jsx("strong", {
22
22
  children: "spec-first"
23
- }, undefined, false, undefined, this),
23
+ }),
24
24
  " philosophy. You define declarative TypeScript specifications that describe what your application can do. Runtime adapters automatically serve these specs as type-safe API endpoints (REST, GraphQL, MCP), enforce policies, and validate inputs/outputs\u2014no code generation required."
25
25
  ]
26
- }, undefined, true, undefined, this)
26
+ })
27
27
  ]
28
- }, undefined, true, undefined, this),
29
- /* @__PURE__ */ jsxDEV("div", {
28
+ }),
29
+ /* @__PURE__ */ jsxs("div", {
30
30
  className: "space-y-4",
31
31
  children: [
32
- /* @__PURE__ */ jsxDEV("h2", {
32
+ /* @__PURE__ */ jsx("h2", {
33
33
  className: "text-2xl font-bold",
34
34
  children: "Why spec-first matters"
35
- }, undefined, false, undefined, this),
36
- /* @__PURE__ */ jsxDEV("p", {
35
+ }),
36
+ /* @__PURE__ */ jsx("p", {
37
37
  className: "text-muted-foreground",
38
38
  children: "Traditional development requires writing and maintaining separate code for APIs, databases, UI components, validation logic, and access control. This approach leads to:"
39
- }, undefined, false, undefined, this),
40
- /* @__PURE__ */ jsxDEV("ul", {
39
+ }),
40
+ /* @__PURE__ */ jsxs("ul", {
41
41
  className: "text-muted-foreground list-inside list-disc space-y-2",
42
42
  children: [
43
- /* @__PURE__ */ jsxDEV("li", {
43
+ /* @__PURE__ */ jsx("li", {
44
44
  children: "Duplication across front-end and back-end"
45
- }, undefined, false, undefined, this),
46
- /* @__PURE__ */ jsxDEV("li", {
45
+ }),
46
+ /* @__PURE__ */ jsx("li", {
47
47
  children: "Type mismatches and runtime errors"
48
- }, undefined, false, undefined, this),
49
- /* @__PURE__ */ jsxDEV("li", {
48
+ }),
49
+ /* @__PURE__ */ jsx("li", {
50
50
  children: "Security vulnerabilities from inconsistent policy enforcement"
51
- }, undefined, false, undefined, this),
52
- /* @__PURE__ */ jsxDEV("li", {
51
+ }),
52
+ /* @__PURE__ */ jsx("li", {
53
53
  children: "High maintenance burden when requirements change"
54
- }, undefined, false, undefined, this)
54
+ })
55
55
  ]
56
- }, undefined, true, undefined, this),
57
- /* @__PURE__ */ jsxDEV("p", {
56
+ }),
57
+ /* @__PURE__ */ jsxs("p", {
58
58
  className: "text-muted-foreground",
59
59
  children: [
60
60
  "With ContractSpec, you define your application's operations (Commands/Queries), workflows, and policies in pure TypeScript. Runtime adapters ensure consistency, type safety, and policy enforcement across your entire stack\u2014the spec ",
61
- /* @__PURE__ */ jsxDEV("em", {
61
+ /* @__PURE__ */ jsx("em", {
62
62
  children: "is"
63
- }, undefined, false, undefined, this),
63
+ }),
64
64
  " the implementation."
65
65
  ]
66
- }, undefined, true, undefined, this)
66
+ })
67
67
  ]
68
- }, undefined, true, undefined, this),
69
- /* @__PURE__ */ jsxDEV("div", {
68
+ }),
69
+ /* @__PURE__ */ jsxs("div", {
70
70
  className: "space-y-4",
71
71
  children: [
72
- /* @__PURE__ */ jsxDEV("h2", {
72
+ /* @__PURE__ */ jsx("h2", {
73
73
  className: "text-2xl font-bold",
74
74
  children: "Specification types"
75
- }, undefined, false, undefined, this),
76
- /* @__PURE__ */ jsxDEV("div", {
75
+ }),
76
+ /* @__PURE__ */ jsx("div", {
77
77
  className: "border-border/50 overflow-x-auto rounded-lg border",
78
- children: /* @__PURE__ */ jsxDEV("table", {
78
+ children: /* @__PURE__ */ jsxs("table", {
79
79
  className: "w-full text-left text-sm",
80
80
  children: [
81
- /* @__PURE__ */ jsxDEV("thead", {
81
+ /* @__PURE__ */ jsx("thead", {
82
82
  className: "bg-card/50",
83
- children: /* @__PURE__ */ jsxDEV("tr", {
83
+ children: /* @__PURE__ */ jsxs("tr", {
84
84
  className: "border-border/50 border-b",
85
85
  children: [
86
- /* @__PURE__ */ jsxDEV("th", {
86
+ /* @__PURE__ */ jsx("th", {
87
87
  className: "px-4 py-3 font-semibold",
88
88
  children: "Spec Type"
89
- }, undefined, false, undefined, this),
90
- /* @__PURE__ */ jsxDEV("th", {
89
+ }),
90
+ /* @__PURE__ */ jsx("th", {
91
91
  className: "px-4 py-3 font-semibold",
92
92
  children: "Purpose"
93
- }, undefined, false, undefined, this),
94
- /* @__PURE__ */ jsxDEV("th", {
93
+ }),
94
+ /* @__PURE__ */ jsx("th", {
95
95
  className: "px-4 py-3 font-semibold",
96
96
  children: "Generates"
97
- }, undefined, false, undefined, this)
97
+ })
98
98
  ]
99
- }, undefined, true, undefined, this)
100
- }, undefined, false, undefined, this),
101
- /* @__PURE__ */ jsxDEV("tbody", {
99
+ })
100
+ }),
101
+ /* @__PURE__ */ jsxs("tbody", {
102
102
  className: "divide-border/50 divide-y",
103
103
  children: [
104
- /* @__PURE__ */ jsxDEV("tr", {
104
+ /* @__PURE__ */ jsxs("tr", {
105
105
  children: [
106
- /* @__PURE__ */ jsxDEV("td", {
106
+ /* @__PURE__ */ jsx("td", {
107
107
  className: "px-4 py-3 align-top",
108
- children: /* @__PURE__ */ jsxDEV(Link, {
108
+ children: /* @__PURE__ */ jsx(Link, {
109
109
  href: "/docs/specs/capabilities",
110
110
  className: "text-violet-400 hover:text-violet-300",
111
- children: /* @__PURE__ */ jsxDEV("strong", {
111
+ children: /* @__PURE__ */ jsx("strong", {
112
112
  children: "CapabilitySpec"
113
- }, undefined, false, undefined, this)
114
- }, undefined, false, undefined, this)
115
- }, undefined, false, undefined, this),
116
- /* @__PURE__ */ jsxDEV("td", {
113
+ })
114
+ })
115
+ }),
116
+ /* @__PURE__ */ jsx("td", {
117
117
  className: "px-4 py-3 align-top",
118
118
  children: "Defines what your application can do: operations (Commands/Queries), their inputs, outputs, policies, and side effects."
119
- }, undefined, false, undefined, this),
120
- /* @__PURE__ */ jsxDEV("td", {
119
+ }),
120
+ /* @__PURE__ */ jsx("td", {
121
121
  className: "px-4 py-3 align-top",
122
122
  children: "Runtime-served REST/GraphQL/MCP endpoints, Zod validation, policy enforcement"
123
- }, undefined, false, undefined, this)
123
+ })
124
124
  ]
125
- }, undefined, true, undefined, this),
126
- /* @__PURE__ */ jsxDEV("tr", {
125
+ }),
126
+ /* @__PURE__ */ jsxs("tr", {
127
127
  children: [
128
- /* @__PURE__ */ jsxDEV("td", {
128
+ /* @__PURE__ */ jsx("td", {
129
129
  className: "px-4 py-3 align-top",
130
- children: /* @__PURE__ */ jsxDEV("strong", {
130
+ children: /* @__PURE__ */ jsx("strong", {
131
131
  children: "DataViewSpec"
132
- }, undefined, false, undefined, this)
133
- }, undefined, false, undefined, this),
134
- /* @__PURE__ */ jsxDEV("td", {
132
+ })
133
+ }),
134
+ /* @__PURE__ */ jsx("td", {
135
135
  className: "px-4 py-3 align-top",
136
136
  children: "Describes how data should be queried, filtered, sorted, and presented to users."
137
- }, undefined, false, undefined, this),
138
- /* @__PURE__ */ jsxDEV("td", {
137
+ }),
138
+ /* @__PURE__ */ jsx("td", {
139
139
  className: "px-4 py-3 align-top",
140
140
  children: "Database queries, list/detail views, search interfaces"
141
- }, undefined, false, undefined, this)
141
+ })
142
142
  ]
143
- }, undefined, true, undefined, this),
144
- /* @__PURE__ */ jsxDEV("tr", {
143
+ }),
144
+ /* @__PURE__ */ jsxs("tr", {
145
145
  children: [
146
- /* @__PURE__ */ jsxDEV("td", {
146
+ /* @__PURE__ */ jsx("td", {
147
147
  className: "px-4 py-3 align-top",
148
- children: /* @__PURE__ */ jsxDEV(Link, {
148
+ children: /* @__PURE__ */ jsx(Link, {
149
149
  href: "/docs/specs/workflows",
150
150
  className: "text-violet-400 hover:text-violet-300",
151
- children: /* @__PURE__ */ jsxDEV("strong", {
151
+ children: /* @__PURE__ */ jsx("strong", {
152
152
  children: "WorkflowSpec"
153
- }, undefined, false, undefined, this)
154
- }, undefined, false, undefined, this)
155
- }, undefined, false, undefined, this),
156
- /* @__PURE__ */ jsxDEV("td", {
153
+ })
154
+ })
155
+ }),
156
+ /* @__PURE__ */ jsx("td", {
157
157
  className: "px-4 py-3 align-top",
158
158
  children: "Orchestrates multi-step processes with retries, compensation, and monitoring."
159
- }, undefined, false, undefined, this),
160
- /* @__PURE__ */ jsxDEV("td", {
159
+ }),
160
+ /* @__PURE__ */ jsx("td", {
161
161
  className: "px-4 py-3 align-top",
162
162
  children: "Workflow engine, state machines, retry logic, observability hooks"
163
- }, undefined, false, undefined, this)
163
+ })
164
164
  ]
165
- }, undefined, true, undefined, this),
166
- /* @__PURE__ */ jsxDEV("tr", {
165
+ }),
166
+ /* @__PURE__ */ jsxs("tr", {
167
167
  children: [
168
- /* @__PURE__ */ jsxDEV("td", {
168
+ /* @__PURE__ */ jsx("td", {
169
169
  className: "px-4 py-3 align-top",
170
- children: /* @__PURE__ */ jsxDEV("strong", {
170
+ children: /* @__PURE__ */ jsx("strong", {
171
171
  children: "PolicySpec"
172
- }, undefined, false, undefined, this)
173
- }, undefined, false, undefined, this),
174
- /* @__PURE__ */ jsxDEV("td", {
172
+ })
173
+ }),
174
+ /* @__PURE__ */ jsx("td", {
175
175
  className: "px-4 py-3 align-top",
176
176
  children: "Defines who can do what, when, and under what conditions. Supports ABAC and PII rules."
177
- }, undefined, false, undefined, this),
178
- /* @__PURE__ */ jsxDEV("td", {
177
+ }),
178
+ /* @__PURE__ */ jsx("td", {
179
179
  className: "px-4 py-3 align-top",
180
180
  children: "Policy decision points, access control middleware, audit logs"
181
- }, undefined, false, undefined, this)
181
+ })
182
182
  ]
183
- }, undefined, true, undefined, this),
184
- /* @__PURE__ */ jsxDEV("tr", {
183
+ }),
184
+ /* @__PURE__ */ jsxs("tr", {
185
185
  children: [
186
- /* @__PURE__ */ jsxDEV("td", {
186
+ /* @__PURE__ */ jsx("td", {
187
187
  className: "px-4 py-3 align-top",
188
- children: /* @__PURE__ */ jsxDEV("strong", {
188
+ children: /* @__PURE__ */ jsx("strong", {
189
189
  children: "OverlaySpec"
190
- }, undefined, false, undefined, this)
191
- }, undefined, false, undefined, this),
192
- /* @__PURE__ */ jsxDEV("td", {
190
+ })
191
+ }),
192
+ /* @__PURE__ */ jsx("td", {
193
193
  className: "px-4 py-3 align-top",
194
194
  children: "Allows safe, signed customization of UI layouts and field visibility by tenants or users."
195
- }, undefined, false, undefined, this),
196
- /* @__PURE__ */ jsxDEV("td", {
195
+ }),
196
+ /* @__PURE__ */ jsx("td", {
197
197
  className: "px-4 py-3 align-top",
198
198
  children: "Personalized UI components, layout variations, conditional rendering"
199
- }, undefined, false, undefined, this)
199
+ })
200
200
  ]
201
- }, undefined, true, undefined, this),
202
- /* @__PURE__ */ jsxDEV("tr", {
201
+ }),
202
+ /* @__PURE__ */ jsxs("tr", {
203
203
  children: [
204
- /* @__PURE__ */ jsxDEV("td", {
204
+ /* @__PURE__ */ jsx("td", {
205
205
  className: "px-4 py-3 align-top",
206
- children: /* @__PURE__ */ jsxDEV("strong", {
206
+ children: /* @__PURE__ */ jsx("strong", {
207
207
  children: "TelemetrySpec"
208
- }, undefined, false, undefined, this)
209
- }, undefined, false, undefined, this),
210
- /* @__PURE__ */ jsxDEV("td", {
208
+ })
209
+ }),
210
+ /* @__PURE__ */ jsx("td", {
211
211
  className: "px-4 py-3 align-top",
212
212
  children: "Specifies what metrics, logs, and traces to collect for observability."
213
- }, undefined, false, undefined, this),
214
- /* @__PURE__ */ jsxDEV("td", {
213
+ }),
214
+ /* @__PURE__ */ jsx("td", {
215
215
  className: "px-4 py-3 align-top",
216
216
  children: "Instrumentation code, dashboards, alerting rules"
217
- }, undefined, false, undefined, this)
217
+ })
218
218
  ]
219
- }, undefined, true, undefined, this),
220
- /* @__PURE__ */ jsxDEV("tr", {
219
+ }),
220
+ /* @__PURE__ */ jsxs("tr", {
221
221
  children: [
222
- /* @__PURE__ */ jsxDEV("td", {
222
+ /* @__PURE__ */ jsx("td", {
223
223
  className: "px-4 py-3 align-top",
224
- children: /* @__PURE__ */ jsxDEV(Link, {
224
+ children: /* @__PURE__ */ jsx(Link, {
225
225
  href: "/docs/safety/migrations",
226
226
  className: "text-violet-400 hover:text-violet-300",
227
- children: /* @__PURE__ */ jsxDEV("strong", {
227
+ children: /* @__PURE__ */ jsx("strong", {
228
228
  children: "MigrationSpec"
229
- }, undefined, false, undefined, this)
230
- }, undefined, false, undefined, this)
231
- }, undefined, false, undefined, this),
232
- /* @__PURE__ */ jsxDEV("td", {
229
+ })
230
+ })
231
+ }),
232
+ /* @__PURE__ */ jsx("td", {
233
233
  className: "px-4 py-3 align-top",
234
234
  children: "Manages incremental, reversible schema and data migrations."
235
- }, undefined, false, undefined, this),
236
- /* @__PURE__ */ jsxDEV("td", {
235
+ }),
236
+ /* @__PURE__ */ jsx("td", {
237
237
  className: "px-4 py-3 align-top",
238
238
  children: "Migration scripts, rollback procedures, version tracking"
239
- }, undefined, false, undefined, this)
239
+ })
240
240
  ]
241
- }, undefined, true, undefined, this)
241
+ })
242
242
  ]
243
- }, undefined, true, undefined, this)
243
+ })
244
244
  ]
245
- }, undefined, true, undefined, this)
246
- }, undefined, false, undefined, this)
245
+ })
246
+ })
247
247
  ]
248
- }, undefined, true, undefined, this),
249
- /* @__PURE__ */ jsxDEV("div", {
248
+ }),
249
+ /* @__PURE__ */ jsxs("div", {
250
250
  className: "space-y-4",
251
251
  children: [
252
- /* @__PURE__ */ jsxDEV("h2", {
252
+ /* @__PURE__ */ jsx("h2", {
253
253
  className: "text-2xl font-bold",
254
254
  children: "How specs work together"
255
- }, undefined, false, undefined, this),
256
- /* @__PURE__ */ jsxDEV("p", {
255
+ }),
256
+ /* @__PURE__ */ jsxs("p", {
257
257
  className: "text-muted-foreground",
258
258
  children: [
259
259
  "Specs compose naturally. A ",
260
- /* @__PURE__ */ jsxDEV("strong", {
260
+ /* @__PURE__ */ jsx("strong", {
261
261
  children: "WorkflowSpec"
262
- }, undefined, false, undefined, this),
262
+ }),
263
263
  " can invoke multiple ",
264
- /* @__PURE__ */ jsxDEV("strong", {
264
+ /* @__PURE__ */ jsx("strong", {
265
265
  children: "CapabilitySpecs"
266
- }, undefined, false, undefined, this),
266
+ }),
267
267
  ". A",
268
268
  " ",
269
- /* @__PURE__ */ jsxDEV("strong", {
269
+ /* @__PURE__ */ jsx("strong", {
270
270
  children: "DataViewSpec"
271
- }, undefined, false, undefined, this),
271
+ }),
272
272
  " respects ",
273
- /* @__PURE__ */ jsxDEV("strong", {
273
+ /* @__PURE__ */ jsx("strong", {
274
274
  children: "PolicySpecs"
275
- }, undefined, false, undefined, this),
275
+ }),
276
276
  " to filter sensitive fields. An ",
277
- /* @__PURE__ */ jsxDEV("strong", {
277
+ /* @__PURE__ */ jsx("strong", {
278
278
  children: "OverlaySpec"
279
- }, undefined, false, undefined, this),
279
+ }),
280
280
  " can hide or rearrange UI elements generated from a ",
281
- /* @__PURE__ */ jsxDEV("strong", {
281
+ /* @__PURE__ */ jsx("strong", {
282
282
  children: "CapabilitySpec"
283
- }, undefined, false, undefined, this),
283
+ }),
284
284
  ", but only within the bounds allowed by the underlying policy."
285
285
  ]
286
- }, undefined, true, undefined, this),
287
- /* @__PURE__ */ jsxDEV("p", {
286
+ }),
287
+ /* @__PURE__ */ jsx("p", {
288
288
  className: "text-muted-foreground",
289
289
  children: "This composability means you can build complex applications from simple, reusable building blocks\u2014all while maintaining type safety and policy enforcement."
290
- }, undefined, false, undefined, this)
290
+ })
291
291
  ]
292
- }, undefined, true, undefined, this),
293
- /* @__PURE__ */ jsxDEV("div", {
292
+ }),
293
+ /* @__PURE__ */ jsxs("div", {
294
294
  className: "space-y-4",
295
295
  children: [
296
- /* @__PURE__ */ jsxDEV("h2", {
296
+ /* @__PURE__ */ jsx("h2", {
297
297
  className: "text-2xl font-bold",
298
298
  children: "Next steps"
299
- }, undefined, false, undefined, this),
300
- /* @__PURE__ */ jsxDEV("p", {
299
+ }),
300
+ /* @__PURE__ */ jsx("p", {
301
301
  className: "text-muted-foreground",
302
302
  children: "Explore each specification type in detail using the links in the table above, or continue with the core concepts:"
303
- }, undefined, false, undefined, this),
304
- /* @__PURE__ */ jsxDEV("div", {
303
+ }),
304
+ /* @__PURE__ */ jsxs("div", {
305
305
  className: "flex flex-wrap gap-4 pt-4",
306
306
  children: [
307
- /* @__PURE__ */ jsxDEV(Link, {
307
+ /* @__PURE__ */ jsxs(Link, {
308
308
  href: "/docs/specs/capabilities",
309
309
  className: "btn-primary",
310
310
  children: [
311
311
  "Capabilities ",
312
- /* @__PURE__ */ jsxDEV(ChevronRight, {
312
+ /* @__PURE__ */ jsx(ChevronRight, {
313
313
  size: 16,
314
314
  className: "inline"
315
- }, undefined, false, undefined, this)
315
+ })
316
316
  ]
317
- }, undefined, true, undefined, this),
318
- /* @__PURE__ */ jsxDEV(Link, {
317
+ }),
318
+ /* @__PURE__ */ jsxs(Link, {
319
319
  href: "/docs/specs/workflows",
320
320
  className: "btn-ghost",
321
321
  children: [
322
322
  "Workflows ",
323
- /* @__PURE__ */ jsxDEV(ChevronRight, {
323
+ /* @__PURE__ */ jsx(ChevronRight, {
324
324
  size: 16,
325
325
  className: "inline"
326
- }, undefined, false, undefined, this)
326
+ })
327
327
  ]
328
- }, undefined, true, undefined, this),
329
- /* @__PURE__ */ jsxDEV(Link, {
328
+ }),
329
+ /* @__PURE__ */ jsxs(Link, {
330
330
  href: "/docs/safety",
331
331
  className: "btn-ghost",
332
332
  children: [
333
333
  "Safety Features ",
334
- /* @__PURE__ */ jsxDEV(ChevronRight, {
334
+ /* @__PURE__ */ jsx(ChevronRight, {
335
335
  size: 16,
336
336
  className: "inline"
337
- }, undefined, false, undefined, this)
337
+ })
338
338
  ]
339
- }, undefined, true, undefined, this)
339
+ })
340
340
  ]
341
- }, undefined, true, undefined, this)
341
+ })
342
342
  ]
343
- }, undefined, true, undefined, this)
343
+ })
344
344
  ]
345
- }, undefined, true, undefined, this);
345
+ });
346
346
  }
347
347
 
348
348
  // src/components/docs/specs/SpecsCapabilitiesPage.tsx
349
349
  import Link2 from "@contractspec/lib.ui-link";
350
350
  import { ChevronRight as ChevronRight2 } from "lucide-react";
351
- import { jsxDEV as jsxDEV2 } from "react/jsx-dev-runtime";
351
+ import { jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
352
352
  function SpecsCapabilitiesPage() {
353
- return /* @__PURE__ */ jsxDEV2("div", {
353
+ return /* @__PURE__ */ jsxs2("div", {
354
354
  className: "space-y-8",
355
355
  children: [
356
- /* @__PURE__ */ jsxDEV2("div", {
356
+ /* @__PURE__ */ jsxs2("div", {
357
357
  className: "space-y-2",
358
358
  children: [
359
- /* @__PURE__ */ jsxDEV2("h1", {
359
+ /* @__PURE__ */ jsx2("h1", {
360
360
  className: "text-4xl font-bold",
361
361
  children: "Capabilities"
362
- }, undefined, false, undefined, this),
363
- /* @__PURE__ */ jsxDEV2("p", {
362
+ }),
363
+ /* @__PURE__ */ jsx2("p", {
364
364
  className: "text-muted-foreground text-lg",
365
365
  children: "Capabilities are the core building block of ContractSpec. They define what your app can do."
366
- }, undefined, false, undefined, this)
366
+ })
367
367
  ]
368
- }, undefined, true, undefined, this),
369
- /* @__PURE__ */ jsxDEV2("div", {
368
+ }),
369
+ /* @__PURE__ */ jsxs2("div", {
370
370
  className: "space-y-6",
371
371
  children: [
372
- /* @__PURE__ */ jsxDEV2("div", {
372
+ /* @__PURE__ */ jsxs2("div", {
373
373
  className: "space-y-3",
374
374
  children: [
375
- /* @__PURE__ */ jsxDEV2("h2", {
375
+ /* @__PURE__ */ jsx2("h2", {
376
376
  className: "text-2xl font-bold",
377
377
  children: "Overview"
378
- }, undefined, false, undefined, this),
379
- /* @__PURE__ */ jsxDEV2("p", {
378
+ }),
379
+ /* @__PURE__ */ jsx2("p", {
380
380
  className: "text-muted-foreground",
381
381
  children: "A ContractSpec (or Capability) is a typed, declarative description of an operation. It defines the operation's name, version, inputs, outputs, policies, and side effects. Runtime adapters automatically serve these as REST/GraphQL/MCP endpoints with full validation and policy enforcement."
382
- }, undefined, false, undefined, this)
382
+ })
383
383
  ]
384
- }, undefined, true, undefined, this),
385
- /* @__PURE__ */ jsxDEV2("div", {
384
+ }),
385
+ /* @__PURE__ */ jsxs2("div", {
386
386
  className: "space-y-3",
387
387
  children: [
388
- /* @__PURE__ */ jsxDEV2("h2", {
388
+ /* @__PURE__ */ jsx2("h2", {
389
389
  className: "text-2xl font-bold",
390
390
  children: "Defining a Command (Write)"
391
- }, undefined, false, undefined, this),
392
- /* @__PURE__ */ jsxDEV2("div", {
391
+ }),
392
+ /* @__PURE__ */ jsx2("div", {
393
393
  className: "bg-background/50 border-border text-muted-foreground overflow-x-auto rounded-lg border p-4 font-mono text-sm",
394
- children: /* @__PURE__ */ jsxDEV2("pre", {
394
+ children: /* @__PURE__ */ jsx2("pre", {
395
395
  children: `import { defineCommand } from '@contractspec/lib.contracts-spec';
396
396
  import { SchemaModel, ScalarTypeEnum } from '@contractspec/lib.schema';
397
397
 
@@ -431,228 +431,228 @@ export const TransferFunds = defineCommand({
431
431
  flags: ['payments_enabled'],
432
432
  },
433
433
  });`
434
- }, undefined, false, undefined, this)
435
- }, undefined, false, undefined, this)
434
+ })
435
+ })
436
436
  ]
437
- }, undefined, true, undefined, this),
438
- /* @__PURE__ */ jsxDEV2("div", {
437
+ }),
438
+ /* @__PURE__ */ jsxs2("div", {
439
439
  className: "space-y-3",
440
440
  children: [
441
- /* @__PURE__ */ jsxDEV2("h2", {
441
+ /* @__PURE__ */ jsx2("h2", {
442
442
  className: "text-2xl font-bold",
443
443
  children: "Schema Types"
444
- }, undefined, false, undefined, this),
445
- /* @__PURE__ */ jsxDEV2("p", {
444
+ }),
445
+ /* @__PURE__ */ jsxs2("p", {
446
446
  className: "text-muted-foreground",
447
447
  children: [
448
448
  "ContractSpec uses ",
449
- /* @__PURE__ */ jsxDEV2("code", {
449
+ /* @__PURE__ */ jsx2("code", {
450
450
  children: "@contractspec/lib.schema"
451
- }, undefined, false, undefined, this),
451
+ }),
452
452
  " for I/O definitions. This provides Zod validation, GraphQL types, and JSON Schema from a single source."
453
453
  ]
454
- }, undefined, true, undefined, this),
455
- /* @__PURE__ */ jsxDEV2("ul", {
454
+ }),
455
+ /* @__PURE__ */ jsxs2("ul", {
456
456
  className: "text-muted-foreground space-y-2",
457
457
  children: [
458
- /* @__PURE__ */ jsxDEV2("li", {
458
+ /* @__PURE__ */ jsxs2("li", {
459
459
  children: [
460
460
  "\u2022",
461
461
  " ",
462
- /* @__PURE__ */ jsxDEV2("code", {
462
+ /* @__PURE__ */ jsx2("code", {
463
463
  className: "bg-background/50 rounded px-2 py-1",
464
464
  children: "ScalarTypeEnum.NonEmptyString()"
465
- }, undefined, false, undefined, this),
465
+ }),
466
466
  " ",
467
467
  "- Non-empty text"
468
468
  ]
469
- }, undefined, true, undefined, this),
470
- /* @__PURE__ */ jsxDEV2("li", {
469
+ }),
470
+ /* @__PURE__ */ jsxs2("li", {
471
471
  children: [
472
472
  "\u2022",
473
473
  " ",
474
- /* @__PURE__ */ jsxDEV2("code", {
474
+ /* @__PURE__ */ jsx2("code", {
475
475
  className: "bg-background/50 rounded px-2 py-1",
476
476
  children: "ScalarTypeEnum.PositiveNumber()"
477
- }, undefined, false, undefined, this),
477
+ }),
478
478
  " ",
479
479
  "- Positive numbers"
480
480
  ]
481
- }, undefined, true, undefined, this),
482
- /* @__PURE__ */ jsxDEV2("li", {
481
+ }),
482
+ /* @__PURE__ */ jsxs2("li", {
483
483
  children: [
484
484
  "\u2022",
485
485
  " ",
486
- /* @__PURE__ */ jsxDEV2("code", {
486
+ /* @__PURE__ */ jsx2("code", {
487
487
  className: "bg-background/50 rounded px-2 py-1",
488
488
  children: "ScalarTypeEnum.DateTime()"
489
- }, undefined, false, undefined, this),
489
+ }),
490
490
  " ",
491
491
  "- ISO 8601 timestamps"
492
492
  ]
493
- }, undefined, true, undefined, this),
494
- /* @__PURE__ */ jsxDEV2("li", {
493
+ }),
494
+ /* @__PURE__ */ jsxs2("li", {
495
495
  children: [
496
496
  "\u2022",
497
497
  " ",
498
- /* @__PURE__ */ jsxDEV2("code", {
498
+ /* @__PURE__ */ jsx2("code", {
499
499
  className: "bg-background/50 rounded px-2 py-1",
500
500
  children: "ScalarTypeEnum.Email()"
501
- }, undefined, false, undefined, this),
501
+ }),
502
502
  " ",
503
503
  "- Valid email addresses"
504
504
  ]
505
- }, undefined, true, undefined, this),
506
- /* @__PURE__ */ jsxDEV2("li", {
505
+ }),
506
+ /* @__PURE__ */ jsxs2("li", {
507
507
  children: [
508
508
  "\u2022",
509
509
  " ",
510
- /* @__PURE__ */ jsxDEV2("code", {
510
+ /* @__PURE__ */ jsx2("code", {
511
511
  className: "bg-background/50 rounded px-2 py-1",
512
512
  children: "defineEnum(...)"
513
- }, undefined, false, undefined, this),
513
+ }),
514
514
  " ",
515
515
  "- Type-safe enums"
516
516
  ]
517
- }, undefined, true, undefined, this)
517
+ })
518
518
  ]
519
- }, undefined, true, undefined, this)
519
+ })
520
520
  ]
521
- }, undefined, true, undefined, this),
522
- /* @__PURE__ */ jsxDEV2("div", {
521
+ }),
522
+ /* @__PURE__ */ jsx2("div", {
523
523
  className: "flex items-center gap-4 pt-4",
524
- children: /* @__PURE__ */ jsxDEV2(Link2, {
524
+ children: /* @__PURE__ */ jsxs2(Link2, {
525
525
  href: "/docs/specs/dataviews",
526
526
  className: "btn-primary",
527
527
  children: [
528
528
  "Next: DataViews ",
529
- /* @__PURE__ */ jsxDEV2(ChevronRight2, {
529
+ /* @__PURE__ */ jsx2(ChevronRight2, {
530
530
  size: 16
531
- }, undefined, false, undefined, this)
531
+ })
532
532
  ]
533
- }, undefined, true, undefined, this)
534
- }, undefined, false, undefined, this)
533
+ })
534
+ })
535
535
  ]
536
- }, undefined, true, undefined, this)
536
+ })
537
537
  ]
538
- }, undefined, true, undefined, this);
538
+ });
539
539
  }
540
540
 
541
541
  // src/components/docs/specs/SpecsDataViewsPage.tsx
542
542
  import Link3 from "@contractspec/lib.ui-link";
543
543
  import { ChevronRight as ChevronRight3 } from "lucide-react";
544
- import { jsxDEV as jsxDEV3 } from "react/jsx-dev-runtime";
544
+ import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
545
545
  function SpecsDataViewsPage() {
546
- return /* @__PURE__ */ jsxDEV3("div", {
546
+ return /* @__PURE__ */ jsxs3("div", {
547
547
  className: "space-y-8",
548
548
  children: [
549
- /* @__PURE__ */ jsxDEV3("div", {
549
+ /* @__PURE__ */ jsxs3("div", {
550
550
  className: "space-y-4",
551
551
  children: [
552
- /* @__PURE__ */ jsxDEV3("h1", {
552
+ /* @__PURE__ */ jsx3("h1", {
553
553
  className: "text-4xl font-bold",
554
554
  children: "DataViews"
555
- }, undefined, false, undefined, this),
556
- /* @__PURE__ */ jsxDEV3("p", {
555
+ }),
556
+ /* @__PURE__ */ jsxs3("p", {
557
557
  className: "text-muted-foreground",
558
558
  children: [
559
559
  "A ",
560
- /* @__PURE__ */ jsxDEV3("strong", {
560
+ /* @__PURE__ */ jsx3("strong", {
561
561
  children: "DataViewSpec"
562
- }, undefined, false, undefined, this),
562
+ }),
563
563
  " describes how data should be queried, filtered, sorted, and presented to users. Runtime adapters execute optimized database queries and serve list views, detail views, and search interfaces while respecting policy constraints."
564
564
  ]
565
- }, undefined, true, undefined, this)
565
+ })
566
566
  ]
567
- }, undefined, true, undefined, this),
568
- /* @__PURE__ */ jsxDEV3("div", {
567
+ }),
568
+ /* @__PURE__ */ jsxs3("div", {
569
569
  className: "space-y-4",
570
570
  children: [
571
- /* @__PURE__ */ jsxDEV3("h2", {
571
+ /* @__PURE__ */ jsx3("h2", {
572
572
  className: "text-2xl font-bold",
573
573
  children: "Core concepts"
574
- }, undefined, false, undefined, this),
575
- /* @__PURE__ */ jsxDEV3("div", {
574
+ }),
575
+ /* @__PURE__ */ jsxs3("div", {
576
576
  className: "space-y-3",
577
577
  children: [
578
- /* @__PURE__ */ jsxDEV3("div", {
578
+ /* @__PURE__ */ jsxs3("div", {
579
579
  children: [
580
- /* @__PURE__ */ jsxDEV3("h3", {
580
+ /* @__PURE__ */ jsx3("h3", {
581
581
  className: "text-lg font-semibold",
582
582
  children: "Data sources"
583
- }, undefined, false, undefined, this),
584
- /* @__PURE__ */ jsxDEV3("p", {
583
+ }),
584
+ /* @__PURE__ */ jsx3("p", {
585
585
  className: "text-muted-foreground",
586
586
  children: "A DataView connects to one or more data sources\u2014databases, APIs, or other capabilities. You specify the source and the fields you want to expose."
587
- }, undefined, false, undefined, this)
587
+ })
588
588
  ]
589
- }, undefined, true, undefined, this),
590
- /* @__PURE__ */ jsxDEV3("div", {
589
+ }),
590
+ /* @__PURE__ */ jsxs3("div", {
591
591
  children: [
592
- /* @__PURE__ */ jsxDEV3("h3", {
592
+ /* @__PURE__ */ jsx3("h3", {
593
593
  className: "text-lg font-semibold",
594
594
  children: "Filtering"
595
- }, undefined, false, undefined, this),
596
- /* @__PURE__ */ jsxDEV3("p", {
595
+ }),
596
+ /* @__PURE__ */ jsx3("p", {
597
597
  className: "text-muted-foreground",
598
598
  children: `Define filters that users can apply to narrow down results. Filters can be simple (e.g., "status equals 'active'") or complex (e.g., "created within the last 30 days AND assigned to current user").`
599
- }, undefined, false, undefined, this)
599
+ })
600
600
  ]
601
- }, undefined, true, undefined, this),
602
- /* @__PURE__ */ jsxDEV3("div", {
601
+ }),
602
+ /* @__PURE__ */ jsxs3("div", {
603
603
  children: [
604
- /* @__PURE__ */ jsxDEV3("h3", {
604
+ /* @__PURE__ */ jsx3("h3", {
605
605
  className: "text-lg font-semibold",
606
606
  children: "Sorting"
607
- }, undefined, false, undefined, this),
608
- /* @__PURE__ */ jsxDEV3("p", {
607
+ }),
608
+ /* @__PURE__ */ jsx3("p", {
609
609
  className: "text-muted-foreground",
610
610
  children: "Specify which fields can be sorted and the default sort order. ContractSpec generates efficient database queries with proper indexes."
611
- }, undefined, false, undefined, this)
611
+ })
612
612
  ]
613
- }, undefined, true, undefined, this),
614
- /* @__PURE__ */ jsxDEV3("div", {
613
+ }),
614
+ /* @__PURE__ */ jsxs3("div", {
615
615
  children: [
616
- /* @__PURE__ */ jsxDEV3("h3", {
616
+ /* @__PURE__ */ jsx3("h3", {
617
617
  className: "text-lg font-semibold",
618
618
  children: "Pagination"
619
- }, undefined, false, undefined, this),
620
- /* @__PURE__ */ jsxDEV3("p", {
619
+ }),
620
+ /* @__PURE__ */ jsx3("p", {
621
621
  className: "text-muted-foreground",
622
622
  children: "DataViews automatically support pagination to handle large datasets. You can configure page size limits and cursor-based or offset-based pagination."
623
- }, undefined, false, undefined, this)
623
+ })
624
624
  ]
625
- }, undefined, true, undefined, this),
626
- /* @__PURE__ */ jsxDEV3("div", {
625
+ }),
626
+ /* @__PURE__ */ jsxs3("div", {
627
627
  children: [
628
- /* @__PURE__ */ jsxDEV3("h3", {
628
+ /* @__PURE__ */ jsx3("h3", {
629
629
  className: "text-lg font-semibold",
630
630
  children: "Aggregations"
631
- }, undefined, false, undefined, this),
632
- /* @__PURE__ */ jsxDEV3("p", {
631
+ }),
632
+ /* @__PURE__ */ jsx3("p", {
633
633
  className: "text-muted-foreground",
634
634
  children: "Compute aggregates like counts, sums, averages, and group-by operations. These are useful for dashboards and summary views."
635
- }, undefined, false, undefined, this)
635
+ })
636
636
  ]
637
- }, undefined, true, undefined, this)
637
+ })
638
638
  ]
639
- }, undefined, true, undefined, this)
639
+ })
640
640
  ]
641
- }, undefined, true, undefined, this),
642
- /* @__PURE__ */ jsxDEV3("div", {
641
+ }),
642
+ /* @__PURE__ */ jsxs3("div", {
643
643
  className: "space-y-4",
644
644
  children: [
645
- /* @__PURE__ */ jsxDEV3("h2", {
645
+ /* @__PURE__ */ jsx3("h2", {
646
646
  className: "text-2xl font-bold",
647
647
  children: "Example DataViewSpec"
648
- }, undefined, false, undefined, this),
649
- /* @__PURE__ */ jsxDEV3("p", {
648
+ }),
649
+ /* @__PURE__ */ jsx3("p", {
650
650
  className: "text-muted-foreground",
651
651
  children: "Here's a DataView for listing orders in TypeScript:"
652
- }, undefined, false, undefined, this),
653
- /* @__PURE__ */ jsxDEV3("div", {
652
+ }),
653
+ /* @__PURE__ */ jsx3("div", {
654
654
  className: "bg-background/50 border-border text-muted-foreground overflow-x-auto rounded-lg border p-4 font-mono text-sm",
655
- children: /* @__PURE__ */ jsxDEV3("pre", {
655
+ children: /* @__PURE__ */ jsx3("pre", {
656
656
  children: `import { defineDataView } from '@contractspec/lib.contracts-spec';
657
657
  import { SchemaModel, ScalarTypeEnum } from '@contractspec/lib.schema';
658
658
 
@@ -694,314 +694,314 @@ export const OrderList = defineDataView({
694
694
  maxPageSize: 200,
695
695
  },
696
696
  });`
697
- }, undefined, false, undefined, this)
698
- }, undefined, false, undefined, this)
697
+ })
698
+ })
699
699
  ]
700
- }, undefined, true, undefined, this),
701
- /* @__PURE__ */ jsxDEV3("div", {
700
+ }),
701
+ /* @__PURE__ */ jsxs3("div", {
702
702
  className: "space-y-4",
703
703
  children: [
704
- /* @__PURE__ */ jsxDEV3("h2", {
704
+ /* @__PURE__ */ jsx3("h2", {
705
705
  className: "text-2xl font-bold",
706
706
  children: "Policy integration"
707
- }, undefined, false, undefined, this),
708
- /* @__PURE__ */ jsxDEV3("p", {
707
+ }),
708
+ /* @__PURE__ */ jsxs3("p", {
709
709
  className: "text-muted-foreground",
710
710
  children: [
711
711
  "DataViews automatically enforce",
712
712
  " ",
713
- /* @__PURE__ */ jsxDEV3(Link3, {
713
+ /* @__PURE__ */ jsx3(Link3, {
714
714
  href: "/docs/specs/policy",
715
715
  className: "text-violet-400 hover:text-violet-300",
716
716
  children: "PolicySpecs"
717
- }, undefined, false, undefined, this),
717
+ }),
718
718
  ". If a user doesn't have permission to see certain fields, those fields are automatically filtered out or redacted. If a user can only see their own data, the query is automatically scoped."
719
719
  ]
720
- }, undefined, true, undefined, this),
721
- /* @__PURE__ */ jsxDEV3("p", {
720
+ }),
721
+ /* @__PURE__ */ jsx3("p", {
722
722
  className: "text-muted-foreground",
723
723
  children: "This means you define the data view once, and it works correctly for all users based on their permissions\u2014no need to write separate queries for different roles."
724
- }, undefined, false, undefined, this)
724
+ })
725
725
  ]
726
- }, undefined, true, undefined, this),
727
- /* @__PURE__ */ jsxDEV3("div", {
726
+ }),
727
+ /* @__PURE__ */ jsxs3("div", {
728
728
  className: "space-y-4",
729
729
  children: [
730
- /* @__PURE__ */ jsxDEV3("h2", {
730
+ /* @__PURE__ */ jsx3("h2", {
731
731
  className: "text-2xl font-bold",
732
732
  children: "Served outputs"
733
- }, undefined, false, undefined, this),
734
- /* @__PURE__ */ jsxDEV3("p", {
733
+ }),
734
+ /* @__PURE__ */ jsx3("p", {
735
735
  className: "text-muted-foreground",
736
736
  children: "From a DataViewSpec, ContractSpec serves:"
737
- }, undefined, false, undefined, this),
738
- /* @__PURE__ */ jsxDEV3("ul", {
737
+ }),
738
+ /* @__PURE__ */ jsxs3("ul", {
739
739
  className: "text-muted-foreground list-inside list-disc space-y-2",
740
740
  children: [
741
- /* @__PURE__ */ jsxDEV3("li", {
741
+ /* @__PURE__ */ jsxs3("li", {
742
742
  children: [
743
- /* @__PURE__ */ jsxDEV3("strong", {
743
+ /* @__PURE__ */ jsx3("strong", {
744
744
  children: "Database queries"
745
- }, undefined, false, undefined, this),
745
+ }),
746
746
  " \u2013 Optimized SQL or NoSQL queries executed at runtime"
747
747
  ]
748
- }, undefined, true, undefined, this),
749
- /* @__PURE__ */ jsxDEV3("li", {
748
+ }),
749
+ /* @__PURE__ */ jsxs3("li", {
750
750
  children: [
751
- /* @__PURE__ */ jsxDEV3("strong", {
751
+ /* @__PURE__ */ jsx3("strong", {
752
752
  children: "API endpoints"
753
- }, undefined, false, undefined, this),
753
+ }),
754
754
  " \u2013 RESTful or GraphQL endpoints for fetching data"
755
755
  ]
756
- }, undefined, true, undefined, this),
757
- /* @__PURE__ */ jsxDEV3("li", {
756
+ }),
757
+ /* @__PURE__ */ jsxs3("li", {
758
758
  children: [
759
- /* @__PURE__ */ jsxDEV3("strong", {
759
+ /* @__PURE__ */ jsx3("strong", {
760
760
  children: "UI components"
761
- }, undefined, false, undefined, this),
761
+ }),
762
762
  " \u2013 List views, tables, cards, and detail views"
763
763
  ]
764
- }, undefined, true, undefined, this),
765
- /* @__PURE__ */ jsxDEV3("li", {
764
+ }),
765
+ /* @__PURE__ */ jsxs3("li", {
766
766
  children: [
767
- /* @__PURE__ */ jsxDEV3("strong", {
767
+ /* @__PURE__ */ jsx3("strong", {
768
768
  children: "Search interfaces"
769
- }, undefined, false, undefined, this),
769
+ }),
770
770
  " \u2013 Full-text search with autocomplete"
771
771
  ]
772
- }, undefined, true, undefined, this),
773
- /* @__PURE__ */ jsxDEV3("li", {
772
+ }),
773
+ /* @__PURE__ */ jsxs3("li", {
774
774
  children: [
775
- /* @__PURE__ */ jsxDEV3("strong", {
775
+ /* @__PURE__ */ jsx3("strong", {
776
776
  children: "Export functions"
777
- }, undefined, false, undefined, this),
777
+ }),
778
778
  " \u2013 CSV, JSON, or Excel exports"
779
779
  ]
780
- }, undefined, true, undefined, this)
780
+ })
781
781
  ]
782
- }, undefined, true, undefined, this)
782
+ })
783
783
  ]
784
- }, undefined, true, undefined, this),
785
- /* @__PURE__ */ jsxDEV3("div", {
784
+ }),
785
+ /* @__PURE__ */ jsxs3("div", {
786
786
  className: "space-y-4",
787
787
  children: [
788
- /* @__PURE__ */ jsxDEV3("h2", {
788
+ /* @__PURE__ */ jsx3("h2", {
789
789
  className: "text-2xl font-bold",
790
790
  children: "Best practices"
791
- }, undefined, false, undefined, this),
792
- /* @__PURE__ */ jsxDEV3("ul", {
791
+ }),
792
+ /* @__PURE__ */ jsxs3("ul", {
793
793
  className: "text-muted-foreground list-inside list-disc space-y-2",
794
794
  children: [
795
- /* @__PURE__ */ jsxDEV3("li", {
795
+ /* @__PURE__ */ jsx3("li", {
796
796
  children: "Only expose fields that users actually need\u2014this improves performance and security."
797
- }, undefined, false, undefined, this),
798
- /* @__PURE__ */ jsxDEV3("li", {
797
+ }),
798
+ /* @__PURE__ */ jsx3("li", {
799
799
  children: "Use appropriate indexes for sortable and filterable fields."
800
- }, undefined, false, undefined, this),
801
- /* @__PURE__ */ jsxDEV3("li", {
800
+ }),
801
+ /* @__PURE__ */ jsx3("li", {
802
802
  children: "Set reasonable pagination limits to prevent performance issues."
803
- }, undefined, false, undefined, this),
804
- /* @__PURE__ */ jsxDEV3("li", {
803
+ }),
804
+ /* @__PURE__ */ jsx3("li", {
805
805
  children: "Use aggregations sparingly\u2014they can be expensive on large datasets."
806
- }, undefined, false, undefined, this),
807
- /* @__PURE__ */ jsxDEV3("li", {
806
+ }),
807
+ /* @__PURE__ */ jsx3("li", {
808
808
  children: "Test DataViews with realistic data volumes to ensure they perform well."
809
- }, undefined, false, undefined, this)
809
+ })
810
810
  ]
811
- }, undefined, true, undefined, this)
811
+ })
812
812
  ]
813
- }, undefined, true, undefined, this),
814
- /* @__PURE__ */ jsxDEV3("div", {
813
+ }),
814
+ /* @__PURE__ */ jsxs3("div", {
815
815
  className: "flex items-center gap-4 pt-4",
816
816
  children: [
817
- /* @__PURE__ */ jsxDEV3(Link3, {
817
+ /* @__PURE__ */ jsx3(Link3, {
818
818
  href: "/docs/specs/capabilities",
819
819
  className: "btn-ghost",
820
820
  children: "Previous: Capabilities"
821
- }, undefined, false, undefined, this),
822
- /* @__PURE__ */ jsxDEV3(Link3, {
821
+ }),
822
+ /* @__PURE__ */ jsxs3(Link3, {
823
823
  href: "/docs/specs/workflows",
824
824
  className: "btn-primary",
825
825
  children: [
826
826
  "Next: Workflows ",
827
- /* @__PURE__ */ jsxDEV3(ChevronRight3, {
827
+ /* @__PURE__ */ jsx3(ChevronRight3, {
828
828
  size: 16
829
- }, undefined, false, undefined, this)
829
+ })
830
830
  ]
831
- }, undefined, true, undefined, this)
831
+ })
832
832
  ]
833
- }, undefined, true, undefined, this)
833
+ })
834
834
  ]
835
- }, undefined, true, undefined, this);
835
+ });
836
836
  }
837
837
 
838
838
  // src/components/docs/specs/SpecsWorkflowsPage.tsx
839
839
  import Link4 from "@contractspec/lib.ui-link";
840
840
  import { ChevronRight as ChevronRight4 } from "lucide-react";
841
- import { jsxDEV as jsxDEV4 } from "react/jsx-dev-runtime";
841
+ import { jsx as jsx4, jsxs as jsxs4 } from "react/jsx-runtime";
842
842
  function SpecsWorkflowsPage() {
843
- return /* @__PURE__ */ jsxDEV4("div", {
843
+ return /* @__PURE__ */ jsxs4("div", {
844
844
  className: "space-y-8",
845
845
  children: [
846
- /* @__PURE__ */ jsxDEV4("div", {
846
+ /* @__PURE__ */ jsxs4("div", {
847
847
  className: "space-y-4",
848
848
  children: [
849
- /* @__PURE__ */ jsxDEV4("h1", {
849
+ /* @__PURE__ */ jsx4("h1", {
850
850
  className: "text-4xl font-bold",
851
851
  children: "Workflows"
852
- }, undefined, false, undefined, this),
853
- /* @__PURE__ */ jsxDEV4("p", {
852
+ }),
853
+ /* @__PURE__ */ jsxs4("p", {
854
854
  className: "text-muted-foreground",
855
855
  children: [
856
856
  "A ",
857
- /* @__PURE__ */ jsxDEV4("strong", {
857
+ /* @__PURE__ */ jsx4("strong", {
858
858
  children: "WorkflowSpec"
859
- }, undefined, false, undefined, this),
859
+ }),
860
860
  " orchestrates multi-step processes. It defines the sequence of operations, handles failures with retries and compensation, and provides observability into long-running tasks."
861
861
  ]
862
- }, undefined, true, undefined, this)
862
+ })
863
863
  ]
864
- }, undefined, true, undefined, this),
865
- /* @__PURE__ */ jsxDEV4("div", {
864
+ }),
865
+ /* @__PURE__ */ jsxs4("div", {
866
866
  className: "space-y-4",
867
867
  children: [
868
- /* @__PURE__ */ jsxDEV4("h2", {
868
+ /* @__PURE__ */ jsx4("h2", {
869
869
  className: "text-2xl font-bold",
870
870
  children: "Core concepts"
871
- }, undefined, false, undefined, this),
872
- /* @__PURE__ */ jsxDEV4("div", {
871
+ }),
872
+ /* @__PURE__ */ jsxs4("div", {
873
873
  className: "space-y-3",
874
874
  children: [
875
- /* @__PURE__ */ jsxDEV4("div", {
875
+ /* @__PURE__ */ jsxs4("div", {
876
876
  children: [
877
- /* @__PURE__ */ jsxDEV4("h3", {
877
+ /* @__PURE__ */ jsx4("h3", {
878
878
  className: "text-lg font-semibold",
879
879
  children: "Identifiers"
880
- }, undefined, false, undefined, this),
881
- /* @__PURE__ */ jsxDEV4("p", {
880
+ }),
881
+ /* @__PURE__ */ jsxs4("p", {
882
882
  className: "text-muted-foreground",
883
883
  children: [
884
884
  "Each workflow has a unique",
885
885
  " ",
886
- /* @__PURE__ */ jsxDEV4("code", {
886
+ /* @__PURE__ */ jsx4("code", {
887
887
  className: "bg-background/50 rounded px-2 py-1",
888
888
  children: "workflowId"
889
- }, undefined, false, undefined, this),
889
+ }),
890
890
  " ",
891
891
  "and a",
892
892
  " ",
893
- /* @__PURE__ */ jsxDEV4("code", {
893
+ /* @__PURE__ */ jsx4("code", {
894
894
  className: "bg-background/50 rounded px-2 py-1",
895
895
  children: "version"
896
- }, undefined, false, undefined, this),
896
+ }),
897
897
  ". This allows you to run multiple versions of the same workflow simultaneously during migrations or A/B tests."
898
898
  ]
899
- }, undefined, true, undefined, this)
899
+ })
900
900
  ]
901
- }, undefined, true, undefined, this),
902
- /* @__PURE__ */ jsxDEV4("div", {
901
+ }),
902
+ /* @__PURE__ */ jsxs4("div", {
903
903
  children: [
904
- /* @__PURE__ */ jsxDEV4("h3", {
904
+ /* @__PURE__ */ jsx4("h3", {
905
905
  className: "text-lg font-semibold",
906
906
  children: "Steps"
907
- }, undefined, false, undefined, this),
908
- /* @__PURE__ */ jsxDEV4("p", {
907
+ }),
908
+ /* @__PURE__ */ jsxs4("p", {
909
909
  className: "text-muted-foreground",
910
910
  children: [
911
911
  "A workflow is composed of ",
912
- /* @__PURE__ */ jsxDEV4("strong", {
912
+ /* @__PURE__ */ jsx4("strong", {
913
913
  children: "steps"
914
- }, undefined, false, undefined, this),
914
+ }),
915
915
  ". Each step invokes a",
916
916
  " ",
917
- /* @__PURE__ */ jsxDEV4(Link4, {
917
+ /* @__PURE__ */ jsx4(Link4, {
918
918
  href: "/docs/specs/capabilities",
919
919
  className: "text-violet-400 hover:text-violet-300",
920
920
  children: "CapabilitySpec"
921
- }, undefined, false, undefined, this),
921
+ }),
922
922
  ", passes inputs, and receives outputs. Steps can run sequentially or in parallel."
923
923
  ]
924
- }, undefined, true, undefined, this)
924
+ })
925
925
  ]
926
- }, undefined, true, undefined, this),
927
- /* @__PURE__ */ jsxDEV4("div", {
926
+ }),
927
+ /* @__PURE__ */ jsxs4("div", {
928
928
  children: [
929
- /* @__PURE__ */ jsxDEV4("h3", {
929
+ /* @__PURE__ */ jsx4("h3", {
930
930
  className: "text-lg font-semibold",
931
931
  children: "Transitions"
932
- }, undefined, false, undefined, this),
933
- /* @__PURE__ */ jsxDEV4("p", {
932
+ }),
933
+ /* @__PURE__ */ jsxs4("p", {
934
934
  className: "text-muted-foreground",
935
935
  children: [
936
- /* @__PURE__ */ jsxDEV4("strong", {
936
+ /* @__PURE__ */ jsx4("strong", {
937
937
  children: "Transitions"
938
- }, undefined, false, undefined, this),
938
+ }),
939
939
  ' define the flow between steps. They can be conditional (e.g., "if payment succeeds, go to step 3; otherwise, go to step 5") or unconditional.'
940
940
  ]
941
- }, undefined, true, undefined, this)
941
+ })
942
942
  ]
943
- }, undefined, true, undefined, this),
944
- /* @__PURE__ */ jsxDEV4("div", {
943
+ }),
944
+ /* @__PURE__ */ jsxs4("div", {
945
945
  children: [
946
- /* @__PURE__ */ jsxDEV4("h3", {
946
+ /* @__PURE__ */ jsx4("h3", {
947
947
  className: "text-lg font-semibold",
948
948
  children: "Retries"
949
- }, undefined, false, undefined, this),
950
- /* @__PURE__ */ jsxDEV4("p", {
949
+ }),
950
+ /* @__PURE__ */ jsx4("p", {
951
951
  className: "text-muted-foreground",
952
952
  children: "If a step fails, the workflow can retry it with exponential backoff. You specify the maximum number of retries and the backoff strategy in the spec."
953
- }, undefined, false, undefined, this)
953
+ })
954
954
  ]
955
- }, undefined, true, undefined, this),
956
- /* @__PURE__ */ jsxDEV4("div", {
955
+ }),
956
+ /* @__PURE__ */ jsxs4("div", {
957
957
  children: [
958
- /* @__PURE__ */ jsxDEV4("h3", {
958
+ /* @__PURE__ */ jsx4("h3", {
959
959
  className: "text-lg font-semibold",
960
960
  children: "Compensation"
961
- }, undefined, false, undefined, this),
962
- /* @__PURE__ */ jsxDEV4("p", {
961
+ }),
962
+ /* @__PURE__ */ jsxs4("p", {
963
963
  className: "text-muted-foreground",
964
964
  children: [
965
965
  "When a workflow fails partway through,",
966
966
  " ",
967
- /* @__PURE__ */ jsxDEV4("strong", {
967
+ /* @__PURE__ */ jsx4("strong", {
968
968
  children: "compensation"
969
- }, undefined, false, undefined, this),
969
+ }),
970
970
  " steps undo the effects of completed steps (e.g., refunding a payment, releasing a reservation). This ensures consistency even in failure scenarios."
971
971
  ]
972
- }, undefined, true, undefined, this)
972
+ })
973
973
  ]
974
- }, undefined, true, undefined, this),
975
- /* @__PURE__ */ jsxDEV4("div", {
974
+ }),
975
+ /* @__PURE__ */ jsxs4("div", {
976
976
  children: [
977
- /* @__PURE__ */ jsxDEV4("h3", {
977
+ /* @__PURE__ */ jsx4("h3", {
978
978
  className: "text-lg font-semibold",
979
979
  children: "SLAs"
980
- }, undefined, false, undefined, this),
981
- /* @__PURE__ */ jsxDEV4("p", {
980
+ }),
981
+ /* @__PURE__ */ jsx4("p", {
982
982
  className: "text-muted-foreground",
983
983
  children: "You can define Service Level Agreements (SLAs) for each step or the entire workflow. If a step exceeds its SLA, the system can trigger alerts or escalations."
984
- }, undefined, false, undefined, this)
984
+ })
985
985
  ]
986
- }, undefined, true, undefined, this)
986
+ })
987
987
  ]
988
- }, undefined, true, undefined, this)
988
+ })
989
989
  ]
990
- }, undefined, true, undefined, this),
991
- /* @__PURE__ */ jsxDEV4("div", {
990
+ }),
991
+ /* @__PURE__ */ jsxs4("div", {
992
992
  className: "space-y-4",
993
993
  children: [
994
- /* @__PURE__ */ jsxDEV4("h2", {
994
+ /* @__PURE__ */ jsx4("h2", {
995
995
  className: "text-2xl font-bold",
996
996
  children: "Example WorkflowSpec (TypeScript)"
997
- }, undefined, false, undefined, this),
998
- /* @__PURE__ */ jsxDEV4("p", {
997
+ }),
998
+ /* @__PURE__ */ jsx4("p", {
999
999
  className: "text-muted-foreground",
1000
1000
  children: "Here's a simplified example of a payment workflow in TypeScript:"
1001
- }, undefined, false, undefined, this),
1002
- /* @__PURE__ */ jsxDEV4("div", {
1001
+ }),
1002
+ /* @__PURE__ */ jsx4("div", {
1003
1003
  className: "bg-background/50 border-border text-muted-foreground overflow-x-auto rounded-lg border p-4 font-mono text-sm",
1004
- children: /* @__PURE__ */ jsxDEV4("pre", {
1004
+ children: /* @__PURE__ */ jsx4("pre", {
1005
1005
  children: `import { defineWorkflow } from '@contractspec/lib.contracts-spec/workflow';
1006
1006
  import { ValidatePaymentMethod, ChargePayment, SendEmail } from './specs';
1007
1007
 
@@ -1055,265 +1055,265 @@ export const PaymentFlow = defineWorkflow({
1055
1055
  alertOnBreach: true,
1056
1056
  },
1057
1057
  });`
1058
- }, undefined, false, undefined, this)
1059
- }, undefined, false, undefined, this)
1058
+ })
1059
+ })
1060
1060
  ]
1061
- }, undefined, true, undefined, this),
1062
- /* @__PURE__ */ jsxDEV4("div", {
1061
+ }),
1062
+ /* @__PURE__ */ jsxs4("div", {
1063
1063
  className: "space-y-4",
1064
1064
  children: [
1065
- /* @__PURE__ */ jsxDEV4("h2", {
1065
+ /* @__PURE__ */ jsx4("h2", {
1066
1066
  className: "text-2xl font-bold",
1067
1067
  children: "Triggers"
1068
- }, undefined, false, undefined, this),
1069
- /* @__PURE__ */ jsxDEV4("p", {
1068
+ }),
1069
+ /* @__PURE__ */ jsx4("p", {
1070
1070
  className: "text-muted-foreground",
1071
1071
  children: "Workflows can be triggered in several ways:"
1072
- }, undefined, false, undefined, this),
1073
- /* @__PURE__ */ jsxDEV4("ul", {
1072
+ }),
1073
+ /* @__PURE__ */ jsxs4("ul", {
1074
1074
  className: "text-muted-foreground list-inside list-disc space-y-2",
1075
1075
  children: [
1076
- /* @__PURE__ */ jsxDEV4("li", {
1076
+ /* @__PURE__ */ jsxs4("li", {
1077
1077
  children: [
1078
- /* @__PURE__ */ jsxDEV4("strong", {
1078
+ /* @__PURE__ */ jsx4("strong", {
1079
1079
  children: "Manual invocation"
1080
- }, undefined, false, undefined, this),
1080
+ }),
1081
1081
  " \u2013 A user or system calls the workflow via an API endpoint."
1082
1082
  ]
1083
- }, undefined, true, undefined, this),
1084
- /* @__PURE__ */ jsxDEV4("li", {
1083
+ }),
1084
+ /* @__PURE__ */ jsxs4("li", {
1085
1085
  children: [
1086
- /* @__PURE__ */ jsxDEV4("strong", {
1086
+ /* @__PURE__ */ jsx4("strong", {
1087
1087
  children: "Event-driven"
1088
- }, undefined, false, undefined, this),
1088
+ }),
1089
1089
  " \u2013 The workflow starts automatically when a specific event occurs (e.g., a new order is created)."
1090
1090
  ]
1091
- }, undefined, true, undefined, this),
1092
- /* @__PURE__ */ jsxDEV4("li", {
1091
+ }),
1092
+ /* @__PURE__ */ jsxs4("li", {
1093
1093
  children: [
1094
- /* @__PURE__ */ jsxDEV4("strong", {
1094
+ /* @__PURE__ */ jsx4("strong", {
1095
1095
  children: "Scheduled"
1096
- }, undefined, false, undefined, this),
1096
+ }),
1097
1097
  " \u2013 The workflow runs on a cron schedule (e.g., nightly batch processing)."
1098
1098
  ]
1099
- }, undefined, true, undefined, this),
1100
- /* @__PURE__ */ jsxDEV4("li", {
1099
+ }),
1100
+ /* @__PURE__ */ jsxs4("li", {
1101
1101
  children: [
1102
- /* @__PURE__ */ jsxDEV4("strong", {
1102
+ /* @__PURE__ */ jsx4("strong", {
1103
1103
  children: "Chained"
1104
- }, undefined, false, undefined, this),
1104
+ }),
1105
1105
  " \u2013 One workflow can invoke another as a step."
1106
1106
  ]
1107
- }, undefined, true, undefined, this)
1107
+ })
1108
1108
  ]
1109
- }, undefined, true, undefined, this)
1109
+ })
1110
1110
  ]
1111
- }, undefined, true, undefined, this),
1112
- /* @__PURE__ */ jsxDEV4("div", {
1111
+ }),
1112
+ /* @__PURE__ */ jsxs4("div", {
1113
1113
  className: "space-y-4",
1114
1114
  children: [
1115
- /* @__PURE__ */ jsxDEV4("h2", {
1115
+ /* @__PURE__ */ jsx4("h2", {
1116
1116
  className: "text-2xl font-bold",
1117
1117
  children: "Monitoring and versioning"
1118
- }, undefined, false, undefined, this),
1119
- /* @__PURE__ */ jsxDEV4("p", {
1118
+ }),
1119
+ /* @__PURE__ */ jsx4("p", {
1120
1120
  className: "text-muted-foreground",
1121
1121
  children: "ContractSpec automatically instruments workflows with telemetry. You can view:"
1122
- }, undefined, false, undefined, this),
1123
- /* @__PURE__ */ jsxDEV4("ul", {
1122
+ }),
1123
+ /* @__PURE__ */ jsxs4("ul", {
1124
1124
  className: "text-muted-foreground list-inside list-disc space-y-2",
1125
1125
  children: [
1126
- /* @__PURE__ */ jsxDEV4("li", {
1126
+ /* @__PURE__ */ jsx4("li", {
1127
1127
  children: "Real-time execution status for each step"
1128
- }, undefined, false, undefined, this),
1129
- /* @__PURE__ */ jsxDEV4("li", {
1128
+ }),
1129
+ /* @__PURE__ */ jsx4("li", {
1130
1130
  children: "Historical run data and success/failure rates"
1131
- }, undefined, false, undefined, this),
1132
- /* @__PURE__ */ jsxDEV4("li", {
1131
+ }),
1132
+ /* @__PURE__ */ jsx4("li", {
1133
1133
  children: "Latency distributions and SLA compliance"
1134
- }, undefined, false, undefined, this),
1135
- /* @__PURE__ */ jsxDEV4("li", {
1134
+ }),
1135
+ /* @__PURE__ */ jsx4("li", {
1136
1136
  children: "Compensation events and retry attempts"
1137
- }, undefined, false, undefined, this)
1137
+ })
1138
1138
  ]
1139
- }, undefined, true, undefined, this),
1140
- /* @__PURE__ */ jsxDEV4("p", {
1139
+ }),
1140
+ /* @__PURE__ */ jsx4("p", {
1141
1141
  className: "text-muted-foreground",
1142
1142
  children: "When you update a workflow, you increment its version. Running workflows continue on their original version, while new invocations use the latest version. This allows safe, zero-downtime deployments."
1143
- }, undefined, false, undefined, this)
1143
+ })
1144
1144
  ]
1145
- }, undefined, true, undefined, this),
1146
- /* @__PURE__ */ jsxDEV4("div", {
1145
+ }),
1146
+ /* @__PURE__ */ jsxs4("div", {
1147
1147
  className: "space-y-4",
1148
1148
  children: [
1149
- /* @__PURE__ */ jsxDEV4("h2", {
1149
+ /* @__PURE__ */ jsx4("h2", {
1150
1150
  className: "text-2xl font-bold",
1151
1151
  children: "Best practices"
1152
- }, undefined, false, undefined, this),
1153
- /* @__PURE__ */ jsxDEV4("ul", {
1152
+ }),
1153
+ /* @__PURE__ */ jsxs4("ul", {
1154
1154
  className: "text-muted-foreground list-inside list-disc space-y-2",
1155
1155
  children: [
1156
- /* @__PURE__ */ jsxDEV4("li", {
1156
+ /* @__PURE__ */ jsx4("li", {
1157
1157
  children: "Keep steps idempotent \u2013 they should be safe to retry without side effects."
1158
- }, undefined, false, undefined, this),
1159
- /* @__PURE__ */ jsxDEV4("li", {
1158
+ }),
1159
+ /* @__PURE__ */ jsx4("li", {
1160
1160
  children: "Define compensation for any step that modifies external state."
1161
- }, undefined, false, undefined, this),
1162
- /* @__PURE__ */ jsxDEV4("li", {
1161
+ }),
1162
+ /* @__PURE__ */ jsx4("li", {
1163
1163
  children: "Use meaningful step IDs that describe the operation."
1164
- }, undefined, false, undefined, this),
1165
- /* @__PURE__ */ jsxDEV4("li", {
1164
+ }),
1165
+ /* @__PURE__ */ jsx4("li", {
1166
1166
  children: "Set realistic SLAs and monitor them in production."
1167
- }, undefined, false, undefined, this),
1168
- /* @__PURE__ */ jsxDEV4("li", {
1167
+ }),
1168
+ /* @__PURE__ */ jsx4("li", {
1169
1169
  children: "Test failure scenarios locally before deploying."
1170
- }, undefined, false, undefined, this)
1170
+ })
1171
1171
  ]
1172
- }, undefined, true, undefined, this)
1172
+ })
1173
1173
  ]
1174
- }, undefined, true, undefined, this),
1175
- /* @__PURE__ */ jsxDEV4("div", {
1174
+ }),
1175
+ /* @__PURE__ */ jsxs4("div", {
1176
1176
  className: "flex items-center gap-4 pt-4",
1177
1177
  children: [
1178
- /* @__PURE__ */ jsxDEV4(Link4, {
1178
+ /* @__PURE__ */ jsx4(Link4, {
1179
1179
  href: "/docs/specs/capabilities",
1180
1180
  className: "btn-ghost",
1181
1181
  children: "Previous: Capabilities"
1182
- }, undefined, false, undefined, this),
1183
- /* @__PURE__ */ jsxDEV4(Link4, {
1182
+ }),
1183
+ /* @__PURE__ */ jsxs4(Link4, {
1184
1184
  href: "/docs/safety",
1185
1185
  className: "btn-primary",
1186
1186
  children: [
1187
1187
  "Next: Safety Features ",
1188
- /* @__PURE__ */ jsxDEV4(ChevronRight4, {
1188
+ /* @__PURE__ */ jsx4(ChevronRight4, {
1189
1189
  size: 16
1190
- }, undefined, false, undefined, this)
1190
+ })
1191
1191
  ]
1192
- }, undefined, true, undefined, this)
1192
+ })
1193
1193
  ]
1194
- }, undefined, true, undefined, this)
1194
+ })
1195
1195
  ]
1196
- }, undefined, true, undefined, this);
1196
+ });
1197
1197
  }
1198
1198
 
1199
1199
  // src/components/docs/specs/SpecsPolicyPage.tsx
1200
1200
  import Link5 from "@contractspec/lib.ui-link";
1201
1201
  import { ChevronRight as ChevronRight5 } from "lucide-react";
1202
- import { jsxDEV as jsxDEV5 } from "react/jsx-dev-runtime";
1202
+ import { jsx as jsx5, jsxs as jsxs5 } from "react/jsx-runtime";
1203
1203
  function SpecsPolicyPage() {
1204
- return /* @__PURE__ */ jsxDEV5("div", {
1204
+ return /* @__PURE__ */ jsxs5("div", {
1205
1205
  className: "space-y-8",
1206
1206
  children: [
1207
- /* @__PURE__ */ jsxDEV5("div", {
1207
+ /* @__PURE__ */ jsxs5("div", {
1208
1208
  className: "space-y-4",
1209
1209
  children: [
1210
- /* @__PURE__ */ jsxDEV5("h1", {
1210
+ /* @__PURE__ */ jsx5("h1", {
1211
1211
  className: "text-4xl font-bold",
1212
1212
  children: "Policy"
1213
- }, undefined, false, undefined, this),
1214
- /* @__PURE__ */ jsxDEV5("p", {
1213
+ }),
1214
+ /* @__PURE__ */ jsxs5("p", {
1215
1215
  className: "text-muted-foreground",
1216
1216
  children: [
1217
1217
  "A ",
1218
- /* @__PURE__ */ jsxDEV5("strong", {
1218
+ /* @__PURE__ */ jsx5("strong", {
1219
1219
  children: "PolicySpec"
1220
- }, undefined, false, undefined, this),
1220
+ }),
1221
1221
  " defines who can do what, when, and under what conditions. ContractSpec uses attribute-based access control (ABAC) to enforce policies across your entire application\u2014from API endpoints to UI components."
1222
1222
  ]
1223
- }, undefined, true, undefined, this)
1223
+ })
1224
1224
  ]
1225
- }, undefined, true, undefined, this),
1226
- /* @__PURE__ */ jsxDEV5("div", {
1225
+ }),
1226
+ /* @__PURE__ */ jsxs5("div", {
1227
1227
  className: "space-y-4",
1228
1228
  children: [
1229
- /* @__PURE__ */ jsxDEV5("h2", {
1229
+ /* @__PURE__ */ jsx5("h2", {
1230
1230
  className: "text-2xl font-bold",
1231
1231
  children: "Why policies matter"
1232
- }, undefined, false, undefined, this),
1233
- /* @__PURE__ */ jsxDEV5("p", {
1232
+ }),
1233
+ /* @__PURE__ */ jsx5("p", {
1234
1234
  className: "text-muted-foreground",
1235
1235
  children: "Traditional access control relies on roles (RBAC), which can become unwieldy as applications grow. ABAC is more flexible\u2014it evaluates policies based on attributes of the user, resource, action, and context."
1236
- }, undefined, false, undefined, this),
1237
- /* @__PURE__ */ jsxDEV5("p", {
1236
+ }),
1237
+ /* @__PURE__ */ jsxs5("p", {
1238
1238
  className: "text-muted-foreground",
1239
1239
  children: [
1240
1240
  "ContractSpec's policy engine ensures that access control is consistent across all surfaces. You don't have to remember to add authorization checks in every API endpoint or UI component\u2014the",
1241
1241
  " ",
1242
- /* @__PURE__ */ jsxDEV5(Link5, {
1242
+ /* @__PURE__ */ jsx5(Link5, {
1243
1243
  href: "/docs/safety/pdp",
1244
1244
  className: "text-violet-400 hover:text-violet-300",
1245
1245
  children: "Policy Decision Point"
1246
- }, undefined, false, undefined, this),
1246
+ }),
1247
1247
  " ",
1248
1248
  "enforces policies automatically."
1249
1249
  ]
1250
- }, undefined, true, undefined, this)
1250
+ })
1251
1251
  ]
1252
- }, undefined, true, undefined, this),
1253
- /* @__PURE__ */ jsxDEV5("div", {
1252
+ }),
1253
+ /* @__PURE__ */ jsxs5("div", {
1254
1254
  className: "space-y-4",
1255
1255
  children: [
1256
- /* @__PURE__ */ jsxDEV5("h2", {
1256
+ /* @__PURE__ */ jsx5("h2", {
1257
1257
  className: "text-2xl font-bold",
1258
1258
  children: "Policy structure"
1259
- }, undefined, false, undefined, this),
1260
- /* @__PURE__ */ jsxDEV5("p", {
1259
+ }),
1260
+ /* @__PURE__ */ jsx5("p", {
1261
1261
  className: "text-muted-foreground",
1262
1262
  children: "A PolicySpec contains one or more rules. Each rule has:"
1263
- }, undefined, false, undefined, this),
1264
- /* @__PURE__ */ jsxDEV5("ul", {
1263
+ }),
1264
+ /* @__PURE__ */ jsxs5("ul", {
1265
1265
  className: "text-muted-foreground list-inside list-disc space-y-2",
1266
1266
  children: [
1267
- /* @__PURE__ */ jsxDEV5("li", {
1267
+ /* @__PURE__ */ jsxs5("li", {
1268
1268
  children: [
1269
- /* @__PURE__ */ jsxDEV5("strong", {
1269
+ /* @__PURE__ */ jsx5("strong", {
1270
1270
  children: "Effect"
1271
- }, undefined, false, undefined, this),
1271
+ }),
1272
1272
  " \u2013 PERMIT, DENY, or REDACT"
1273
1273
  ]
1274
- }, undefined, true, undefined, this),
1275
- /* @__PURE__ */ jsxDEV5("li", {
1274
+ }),
1275
+ /* @__PURE__ */ jsxs5("li", {
1276
1276
  children: [
1277
- /* @__PURE__ */ jsxDEV5("strong", {
1277
+ /* @__PURE__ */ jsx5("strong", {
1278
1278
  children: "Condition"
1279
- }, undefined, false, undefined, this),
1279
+ }),
1280
1280
  " \u2013 A boolean expression that determines when the rule applies"
1281
1281
  ]
1282
- }, undefined, true, undefined, this),
1283
- /* @__PURE__ */ jsxDEV5("li", {
1282
+ }),
1283
+ /* @__PURE__ */ jsxs5("li", {
1284
1284
  children: [
1285
- /* @__PURE__ */ jsxDEV5("strong", {
1285
+ /* @__PURE__ */ jsx5("strong", {
1286
1286
  children: "Scope"
1287
- }, undefined, false, undefined, this),
1287
+ }),
1288
1288
  " \u2013 Which resources, actions, or fields the rule applies to"
1289
1289
  ]
1290
- }, undefined, true, undefined, this),
1291
- /* @__PURE__ */ jsxDEV5("li", {
1290
+ }),
1291
+ /* @__PURE__ */ jsxs5("li", {
1292
1292
  children: [
1293
- /* @__PURE__ */ jsxDEV5("strong", {
1293
+ /* @__PURE__ */ jsx5("strong", {
1294
1294
  children: "Priority"
1295
- }, undefined, false, undefined, this),
1295
+ }),
1296
1296
  " \u2013 Rules are evaluated in priority order; the first matching rule wins"
1297
1297
  ]
1298
- }, undefined, true, undefined, this)
1298
+ })
1299
1299
  ]
1300
- }, undefined, true, undefined, this)
1300
+ })
1301
1301
  ]
1302
- }, undefined, true, undefined, this),
1303
- /* @__PURE__ */ jsxDEV5("div", {
1302
+ }),
1303
+ /* @__PURE__ */ jsxs5("div", {
1304
1304
  className: "space-y-4",
1305
1305
  children: [
1306
- /* @__PURE__ */ jsxDEV5("h2", {
1306
+ /* @__PURE__ */ jsx5("h2", {
1307
1307
  className: "text-2xl font-bold",
1308
1308
  children: "Example PolicySpec"
1309
- }, undefined, false, undefined, this),
1310
- /* @__PURE__ */ jsxDEV5("p", {
1309
+ }),
1310
+ /* @__PURE__ */ jsx5("p", {
1311
1311
  className: "text-muted-foreground",
1312
1312
  children: "Here's a policy that controls access to customer data in TypeScript:"
1313
- }, undefined, false, undefined, this),
1314
- /* @__PURE__ */ jsxDEV5("div", {
1313
+ }),
1314
+ /* @__PURE__ */ jsx5("div", {
1315
1315
  className: "bg-background/50 border-border text-muted-foreground overflow-x-auto rounded-lg border p-4 font-mono text-sm",
1316
- children: /* @__PURE__ */ jsxDEV5("pre", {
1316
+ children: /* @__PURE__ */ jsx5("pre", {
1317
1317
  children: `import { definePolicy } from '@contractspec/lib.contracts-spec';
1318
1318
 
1319
1319
  export const CustomerDataAccess = definePolicy({
@@ -1357,179 +1357,179 @@ export const CustomerDataAccess = definePolicy({
1357
1357
  },
1358
1358
  ],
1359
1359
  });`
1360
- }, undefined, false, undefined, this)
1361
- }, undefined, false, undefined, this)
1360
+ })
1361
+ })
1362
1362
  ]
1363
- }, undefined, true, undefined, this),
1364
- /* @__PURE__ */ jsxDEV5("div", {
1363
+ }),
1364
+ /* @__PURE__ */ jsxs5("div", {
1365
1365
  className: "space-y-4",
1366
1366
  children: [
1367
- /* @__PURE__ */ jsxDEV5("h2", {
1367
+ /* @__PURE__ */ jsx5("h2", {
1368
1368
  className: "text-2xl font-bold",
1369
1369
  children: "Attributes"
1370
- }, undefined, false, undefined, this),
1371
- /* @__PURE__ */ jsxDEV5("p", {
1370
+ }),
1371
+ /* @__PURE__ */ jsx5("p", {
1372
1372
  className: "text-muted-foreground",
1373
1373
  children: "Policy conditions can reference attributes from four categories:"
1374
- }, undefined, false, undefined, this),
1375
- /* @__PURE__ */ jsxDEV5("div", {
1374
+ }),
1375
+ /* @__PURE__ */ jsxs5("div", {
1376
1376
  className: "space-y-3",
1377
1377
  children: [
1378
- /* @__PURE__ */ jsxDEV5("div", {
1378
+ /* @__PURE__ */ jsxs5("div", {
1379
1379
  children: [
1380
- /* @__PURE__ */ jsxDEV5("h3", {
1380
+ /* @__PURE__ */ jsx5("h3", {
1381
1381
  className: "text-lg font-semibold",
1382
1382
  children: "User attributes"
1383
- }, undefined, false, undefined, this),
1384
- /* @__PURE__ */ jsxDEV5("p", {
1383
+ }),
1384
+ /* @__PURE__ */ jsxs5("p", {
1385
1385
  className: "text-muted-foreground",
1386
1386
  children: [
1387
- /* @__PURE__ */ jsxDEV5("code", {
1387
+ /* @__PURE__ */ jsx5("code", {
1388
1388
  className: "bg-background/50 rounded px-2 py-1",
1389
1389
  children: "user.id"
1390
- }, undefined, false, undefined, this),
1390
+ }),
1391
1391
  ",",
1392
1392
  " ",
1393
- /* @__PURE__ */ jsxDEV5("code", {
1393
+ /* @__PURE__ */ jsx5("code", {
1394
1394
  className: "bg-background/50 rounded px-2 py-1",
1395
1395
  children: "user.role"
1396
- }, undefined, false, undefined, this),
1396
+ }),
1397
1397
  ",",
1398
1398
  " ",
1399
- /* @__PURE__ */ jsxDEV5("code", {
1399
+ /* @__PURE__ */ jsx5("code", {
1400
1400
  className: "bg-background/50 rounded px-2 py-1",
1401
1401
  children: "user.groups"
1402
- }, undefined, false, undefined, this),
1402
+ }),
1403
1403
  ",",
1404
1404
  " ",
1405
- /* @__PURE__ */ jsxDEV5("code", {
1405
+ /* @__PURE__ */ jsx5("code", {
1406
1406
  className: "bg-background/50 rounded px-2 py-1",
1407
1407
  children: "user.department"
1408
- }, undefined, false, undefined, this),
1408
+ }),
1409
1409
  ", custom attributes"
1410
1410
  ]
1411
- }, undefined, true, undefined, this)
1411
+ })
1412
1412
  ]
1413
- }, undefined, true, undefined, this),
1414
- /* @__PURE__ */ jsxDEV5("div", {
1413
+ }),
1414
+ /* @__PURE__ */ jsxs5("div", {
1415
1415
  children: [
1416
- /* @__PURE__ */ jsxDEV5("h3", {
1416
+ /* @__PURE__ */ jsx5("h3", {
1417
1417
  className: "text-lg font-semibold",
1418
1418
  children: "Resource attributes"
1419
- }, undefined, false, undefined, this),
1420
- /* @__PURE__ */ jsxDEV5("p", {
1419
+ }),
1420
+ /* @__PURE__ */ jsxs5("p", {
1421
1421
  className: "text-muted-foreground",
1422
1422
  children: [
1423
- /* @__PURE__ */ jsxDEV5("code", {
1423
+ /* @__PURE__ */ jsx5("code", {
1424
1424
  className: "bg-background/50 rounded px-2 py-1",
1425
1425
  children: "resource.type"
1426
- }, undefined, false, undefined, this),
1426
+ }),
1427
1427
  ",",
1428
1428
  " ",
1429
- /* @__PURE__ */ jsxDEV5("code", {
1429
+ /* @__PURE__ */ jsx5("code", {
1430
1430
  className: "bg-background/50 rounded px-2 py-1",
1431
1431
  children: "resource.owner"
1432
- }, undefined, false, undefined, this),
1432
+ }),
1433
1433
  ",",
1434
1434
  " ",
1435
- /* @__PURE__ */ jsxDEV5("code", {
1435
+ /* @__PURE__ */ jsx5("code", {
1436
1436
  className: "bg-background/50 rounded px-2 py-1",
1437
1437
  children: "resource.sensitivity"
1438
- }, undefined, false, undefined, this),
1438
+ }),
1439
1439
  ", custom attributes"
1440
1440
  ]
1441
- }, undefined, true, undefined, this)
1441
+ })
1442
1442
  ]
1443
- }, undefined, true, undefined, this),
1444
- /* @__PURE__ */ jsxDEV5("div", {
1443
+ }),
1444
+ /* @__PURE__ */ jsxs5("div", {
1445
1445
  children: [
1446
- /* @__PURE__ */ jsxDEV5("h3", {
1446
+ /* @__PURE__ */ jsx5("h3", {
1447
1447
  className: "text-lg font-semibold",
1448
1448
  children: "Action attributes"
1449
- }, undefined, false, undefined, this),
1450
- /* @__PURE__ */ jsxDEV5("p", {
1449
+ }),
1450
+ /* @__PURE__ */ jsxs5("p", {
1451
1451
  className: "text-muted-foreground",
1452
1452
  children: [
1453
- /* @__PURE__ */ jsxDEV5("code", {
1453
+ /* @__PURE__ */ jsx5("code", {
1454
1454
  className: "bg-background/50 rounded px-2 py-1",
1455
1455
  children: "action"
1456
- }, undefined, false, undefined, this),
1456
+ }),
1457
1457
  " ",
1458
1458
  "(read, write, delete, execute, export, etc.)"
1459
1459
  ]
1460
- }, undefined, true, undefined, this)
1460
+ })
1461
1461
  ]
1462
- }, undefined, true, undefined, this),
1463
- /* @__PURE__ */ jsxDEV5("div", {
1462
+ }),
1463
+ /* @__PURE__ */ jsxs5("div", {
1464
1464
  children: [
1465
- /* @__PURE__ */ jsxDEV5("h3", {
1465
+ /* @__PURE__ */ jsx5("h3", {
1466
1466
  className: "text-lg font-semibold",
1467
1467
  children: "Context attributes"
1468
- }, undefined, false, undefined, this),
1469
- /* @__PURE__ */ jsxDEV5("p", {
1468
+ }),
1469
+ /* @__PURE__ */ jsxs5("p", {
1470
1470
  className: "text-muted-foreground",
1471
1471
  children: [
1472
- /* @__PURE__ */ jsxDEV5("code", {
1472
+ /* @__PURE__ */ jsx5("code", {
1473
1473
  className: "bg-background/50 rounded px-2 py-1",
1474
1474
  children: "time.hour"
1475
- }, undefined, false, undefined, this),
1475
+ }),
1476
1476
  ",",
1477
1477
  " ",
1478
- /* @__PURE__ */ jsxDEV5("code", {
1478
+ /* @__PURE__ */ jsx5("code", {
1479
1479
  className: "bg-background/50 rounded px-2 py-1",
1480
1480
  children: "time.dayOfWeek"
1481
- }, undefined, false, undefined, this),
1481
+ }),
1482
1482
  ",",
1483
1483
  " ",
1484
- /* @__PURE__ */ jsxDEV5("code", {
1484
+ /* @__PURE__ */ jsx5("code", {
1485
1485
  className: "bg-background/50 rounded px-2 py-1",
1486
1486
  children: "request.ipAddress"
1487
- }, undefined, false, undefined, this),
1487
+ }),
1488
1488
  ",",
1489
1489
  " ",
1490
- /* @__PURE__ */ jsxDEV5("code", {
1490
+ /* @__PURE__ */ jsx5("code", {
1491
1491
  className: "bg-background/50 rounded px-2 py-1",
1492
1492
  children: "request.userAgent"
1493
- }, undefined, false, undefined, this)
1493
+ })
1494
1494
  ]
1495
- }, undefined, true, undefined, this)
1495
+ })
1496
1496
  ]
1497
- }, undefined, true, undefined, this)
1497
+ })
1498
1498
  ]
1499
- }, undefined, true, undefined, this)
1499
+ })
1500
1500
  ]
1501
- }, undefined, true, undefined, this),
1502
- /* @__PURE__ */ jsxDEV5("div", {
1501
+ }),
1502
+ /* @__PURE__ */ jsxs5("div", {
1503
1503
  className: "space-y-4",
1504
1504
  children: [
1505
- /* @__PURE__ */ jsxDEV5("h2", {
1505
+ /* @__PURE__ */ jsx5("h2", {
1506
1506
  className: "text-2xl font-bold",
1507
1507
  children: "Data classification"
1508
- }, undefined, false, undefined, this),
1509
- /* @__PURE__ */ jsxDEV5("p", {
1508
+ }),
1509
+ /* @__PURE__ */ jsxs5("p", {
1510
1510
  className: "text-muted-foreground",
1511
1511
  children: [
1512
1512
  "You can tag fields with sensitivity levels in your",
1513
1513
  " ",
1514
- /* @__PURE__ */ jsxDEV5(Link5, {
1514
+ /* @__PURE__ */ jsx5(Link5, {
1515
1515
  href: "/docs/specs/capabilities",
1516
1516
  className: "text-violet-400 hover:text-violet-300",
1517
1517
  children: "CapabilitySpecs"
1518
- }, undefined, false, undefined, this),
1518
+ }),
1519
1519
  " ",
1520
1520
  "and",
1521
1521
  " ",
1522
- /* @__PURE__ */ jsxDEV5(Link5, {
1522
+ /* @__PURE__ */ jsx5(Link5, {
1523
1523
  href: "/docs/specs/dataviews",
1524
1524
  className: "text-violet-400 hover:text-violet-300",
1525
1525
  children: "DataViewSpecs"
1526
- }, undefined, false, undefined, this),
1526
+ }),
1527
1527
  ":"
1528
1528
  ]
1529
- }, undefined, true, undefined, this),
1530
- /* @__PURE__ */ jsxDEV5("div", {
1529
+ }),
1530
+ /* @__PURE__ */ jsx5("div", {
1531
1531
  className: "bg-background/50 border-border text-muted-foreground overflow-x-auto rounded-lg border p-4 font-mono text-sm",
1532
- children: /* @__PURE__ */ jsxDEV5("pre", {
1532
+ children: /* @__PURE__ */ jsx5("pre", {
1533
1533
  children: `fields:
1534
1534
  - name: email
1535
1535
  type: string
@@ -1544,257 +1544,257 @@ export const CustomerDataAccess = definePolicy({
1544
1544
  - name: salary
1545
1545
  type: number
1546
1546
  sensitivity: confidential`
1547
- }, undefined, false, undefined, this)
1548
- }, undefined, false, undefined, this),
1549
- /* @__PURE__ */ jsxDEV5("p", {
1547
+ })
1548
+ }),
1549
+ /* @__PURE__ */ jsx5("p", {
1550
1550
  className: "text-muted-foreground",
1551
1551
  children: 'Policies can then reference these tags to enforce blanket rules like "support staff cannot see PII" or "PHI can only be accessed from approved IP addresses."'
1552
- }, undefined, false, undefined, this)
1552
+ })
1553
1553
  ]
1554
- }, undefined, true, undefined, this),
1555
- /* @__PURE__ */ jsxDEV5("div", {
1554
+ }),
1555
+ /* @__PURE__ */ jsxs5("div", {
1556
1556
  className: "space-y-4",
1557
1557
  children: [
1558
- /* @__PURE__ */ jsxDEV5("h2", {
1558
+ /* @__PURE__ */ jsx5("h2", {
1559
1559
  className: "text-2xl font-bold",
1560
1560
  children: "Testing policies"
1561
- }, undefined, false, undefined, this),
1562
- /* @__PURE__ */ jsxDEV5("p", {
1561
+ }),
1562
+ /* @__PURE__ */ jsx5("p", {
1563
1563
  className: "text-muted-foreground",
1564
1564
  children: "ContractSpec provides tools for testing policies before deployment:"
1565
- }, undefined, false, undefined, this),
1566
- /* @__PURE__ */ jsxDEV5("ul", {
1565
+ }),
1566
+ /* @__PURE__ */ jsxs5("ul", {
1567
1567
  className: "text-muted-foreground list-inside list-disc space-y-2",
1568
1568
  children: [
1569
- /* @__PURE__ */ jsxDEV5("li", {
1569
+ /* @__PURE__ */ jsxs5("li", {
1570
1570
  children: [
1571
- /* @__PURE__ */ jsxDEV5("strong", {
1571
+ /* @__PURE__ */ jsx5("strong", {
1572
1572
  children: "Policy simulator"
1573
- }, undefined, false, undefined, this),
1573
+ }),
1574
1574
  " \u2013 Test how policies evaluate for different users and scenarios"
1575
1575
  ]
1576
- }, undefined, true, undefined, this),
1577
- /* @__PURE__ */ jsxDEV5("li", {
1576
+ }),
1577
+ /* @__PURE__ */ jsxs5("li", {
1578
1578
  children: [
1579
- /* @__PURE__ */ jsxDEV5("strong", {
1579
+ /* @__PURE__ */ jsx5("strong", {
1580
1580
  children: "Coverage analysis"
1581
- }, undefined, false, undefined, this),
1581
+ }),
1582
1582
  " \u2013 Identify resources or actions that aren't covered by any policy"
1583
1583
  ]
1584
- }, undefined, true, undefined, this),
1585
- /* @__PURE__ */ jsxDEV5("li", {
1584
+ }),
1585
+ /* @__PURE__ */ jsxs5("li", {
1586
1586
  children: [
1587
- /* @__PURE__ */ jsxDEV5("strong", {
1587
+ /* @__PURE__ */ jsx5("strong", {
1588
1588
  children: "Conflict detection"
1589
- }, undefined, false, undefined, this),
1589
+ }),
1590
1590
  " \u2013 Find rules that might conflict or produce unexpected results"
1591
1591
  ]
1592
- }, undefined, true, undefined, this),
1593
- /* @__PURE__ */ jsxDEV5("li", {
1592
+ }),
1593
+ /* @__PURE__ */ jsxs5("li", {
1594
1594
  children: [
1595
- /* @__PURE__ */ jsxDEV5("strong", {
1595
+ /* @__PURE__ */ jsx5("strong", {
1596
1596
  children: "Audit mode"
1597
- }, undefined, false, undefined, this),
1597
+ }),
1598
1598
  " \u2013 Run policies in audit-only mode to see what would be blocked without actually blocking it"
1599
1599
  ]
1600
- }, undefined, true, undefined, this)
1600
+ })
1601
1601
  ]
1602
- }, undefined, true, undefined, this)
1602
+ })
1603
1603
  ]
1604
- }, undefined, true, undefined, this),
1605
- /* @__PURE__ */ jsxDEV5("div", {
1604
+ }),
1605
+ /* @__PURE__ */ jsxs5("div", {
1606
1606
  className: "space-y-4",
1607
1607
  children: [
1608
- /* @__PURE__ */ jsxDEV5("h2", {
1608
+ /* @__PURE__ */ jsx5("h2", {
1609
1609
  className: "text-2xl font-bold",
1610
1610
  children: "Best practices"
1611
- }, undefined, false, undefined, this),
1612
- /* @__PURE__ */ jsxDEV5("ul", {
1611
+ }),
1612
+ /* @__PURE__ */ jsxs5("ul", {
1613
1613
  className: "text-muted-foreground list-inside list-disc space-y-2",
1614
1614
  children: [
1615
- /* @__PURE__ */ jsxDEV5("li", {
1615
+ /* @__PURE__ */ jsx5("li", {
1616
1616
  children: "Start with a deny-by-default policy\u2014explicitly permit what should be allowed."
1617
- }, undefined, false, undefined, this),
1618
- /* @__PURE__ */ jsxDEV5("li", {
1617
+ }),
1618
+ /* @__PURE__ */ jsx5("li", {
1619
1619
  children: "Use clear, descriptive rule IDs that explain what the rule does."
1620
- }, undefined, false, undefined, this),
1621
- /* @__PURE__ */ jsxDEV5("li", {
1620
+ }),
1621
+ /* @__PURE__ */ jsx5("li", {
1622
1622
  children: "Set priorities carefully to ensure rules are evaluated in the right order."
1623
- }, undefined, false, undefined, this),
1624
- /* @__PURE__ */ jsxDEV5("li", {
1623
+ }),
1624
+ /* @__PURE__ */ jsx5("li", {
1625
1625
  children: "Test policies thoroughly with realistic user scenarios before deploying."
1626
- }, undefined, false, undefined, this),
1627
- /* @__PURE__ */ jsxDEV5("li", {
1626
+ }),
1627
+ /* @__PURE__ */ jsxs5("li", {
1628
1628
  children: [
1629
1629
  "Monitor policy decisions in production using",
1630
1630
  " ",
1631
- /* @__PURE__ */ jsxDEV5(Link5, {
1631
+ /* @__PURE__ */ jsx5(Link5, {
1632
1632
  href: "/docs/safety/auditing",
1633
1633
  className: "text-violet-400 hover:text-violet-300",
1634
1634
  children: "audit logs"
1635
- }, undefined, false, undefined, this),
1635
+ }),
1636
1636
  "."
1637
1637
  ]
1638
- }, undefined, true, undefined, this),
1639
- /* @__PURE__ */ jsxDEV5("li", {
1638
+ }),
1639
+ /* @__PURE__ */ jsx5("li", {
1640
1640
  children: "Review and update policies regularly as your application and requirements evolve."
1641
- }, undefined, false, undefined, this)
1641
+ })
1642
1642
  ]
1643
- }, undefined, true, undefined, this)
1643
+ })
1644
1644
  ]
1645
- }, undefined, true, undefined, this),
1646
- /* @__PURE__ */ jsxDEV5("div", {
1645
+ }),
1646
+ /* @__PURE__ */ jsxs5("div", {
1647
1647
  className: "flex items-center gap-4 pt-4",
1648
1648
  children: [
1649
- /* @__PURE__ */ jsxDEV5(Link5, {
1649
+ /* @__PURE__ */ jsx5(Link5, {
1650
1650
  href: "/docs/specs/workflows",
1651
1651
  className: "btn-ghost",
1652
1652
  children: "Previous: Workflows"
1653
- }, undefined, false, undefined, this),
1654
- /* @__PURE__ */ jsxDEV5(Link5, {
1653
+ }),
1654
+ /* @__PURE__ */ jsxs5(Link5, {
1655
1655
  href: "/docs/specs/overlays",
1656
1656
  className: "btn-primary",
1657
1657
  children: [
1658
1658
  "Next: Overlays ",
1659
- /* @__PURE__ */ jsxDEV5(ChevronRight5, {
1659
+ /* @__PURE__ */ jsx5(ChevronRight5, {
1660
1660
  size: 16
1661
- }, undefined, false, undefined, this)
1661
+ })
1662
1662
  ]
1663
- }, undefined, true, undefined, this)
1663
+ })
1664
1664
  ]
1665
- }, undefined, true, undefined, this)
1665
+ })
1666
1666
  ]
1667
- }, undefined, true, undefined, this);
1667
+ });
1668
1668
  }
1669
1669
 
1670
1670
  // src/components/docs/specs/SpecsOverlaysPage.tsx
1671
1671
  import Link6 from "@contractspec/lib.ui-link";
1672
1672
  import { ChevronRight as ChevronRight6 } from "lucide-react";
1673
- import { jsxDEV as jsxDEV6 } from "react/jsx-dev-runtime";
1673
+ import { jsx as jsx6, jsxs as jsxs6 } from "react/jsx-runtime";
1674
1674
  function SpecsOverlaysPage() {
1675
- return /* @__PURE__ */ jsxDEV6("div", {
1675
+ return /* @__PURE__ */ jsxs6("div", {
1676
1676
  className: "space-y-8",
1677
1677
  children: [
1678
- /* @__PURE__ */ jsxDEV6("div", {
1678
+ /* @__PURE__ */ jsxs6("div", {
1679
1679
  className: "space-y-4",
1680
1680
  children: [
1681
- /* @__PURE__ */ jsxDEV6("h1", {
1681
+ /* @__PURE__ */ jsx6("h1", {
1682
1682
  className: "text-4xl font-bold",
1683
1683
  children: "Overlays"
1684
- }, undefined, false, undefined, this),
1685
- /* @__PURE__ */ jsxDEV6("p", {
1684
+ }),
1685
+ /* @__PURE__ */ jsxs6("p", {
1686
1686
  className: "text-muted-foreground",
1687
1687
  children: [
1688
1688
  "An ",
1689
- /* @__PURE__ */ jsxDEV6("strong", {
1689
+ /* @__PURE__ */ jsx6("strong", {
1690
1690
  children: "OverlaySpec"
1691
- }, undefined, false, undefined, this),
1691
+ }),
1692
1692
  " allows tenants or users to customize UI layouts and field visibility without modifying the underlying application code. Overlays are cryptographically signed to ensure they respect policy boundaries and cannot introduce security vulnerabilities."
1693
1693
  ]
1694
- }, undefined, true, undefined, this)
1694
+ })
1695
1695
  ]
1696
- }, undefined, true, undefined, this),
1697
- /* @__PURE__ */ jsxDEV6("div", {
1696
+ }),
1697
+ /* @__PURE__ */ jsxs6("div", {
1698
1698
  className: "space-y-4",
1699
1699
  children: [
1700
- /* @__PURE__ */ jsxDEV6("h2", {
1700
+ /* @__PURE__ */ jsx6("h2", {
1701
1701
  className: "text-2xl font-bold",
1702
1702
  children: "Why overlays matter"
1703
- }, undefined, false, undefined, this),
1704
- /* @__PURE__ */ jsxDEV6("p", {
1703
+ }),
1704
+ /* @__PURE__ */ jsx6("p", {
1705
1705
  className: "text-muted-foreground",
1706
1706
  children: "Different users have different needs. A power user might want to see all available fields and actions, while a casual user prefers a simplified interface. A tenant in a multi-tenant application might want to brand the UI or hide features they don't use."
1707
- }, undefined, false, undefined, this),
1708
- /* @__PURE__ */ jsxDEV6("p", {
1707
+ }),
1708
+ /* @__PURE__ */ jsx6("p", {
1709
1709
  className: "text-muted-foreground",
1710
1710
  children: "Traditional approaches require either building multiple UIs or adding complex configuration logic throughout the codebase. OverlaySpecs provide a safer, more maintainable solution: users can customize their experience, but only within the bounds allowed by the underlying specs and policies."
1711
- }, undefined, false, undefined, this)
1711
+ })
1712
1712
  ]
1713
- }, undefined, true, undefined, this),
1714
- /* @__PURE__ */ jsxDEV6("div", {
1713
+ }),
1714
+ /* @__PURE__ */ jsxs6("div", {
1715
1715
  className: "space-y-4",
1716
1716
  children: [
1717
- /* @__PURE__ */ jsxDEV6("h2", {
1717
+ /* @__PURE__ */ jsx6("h2", {
1718
1718
  className: "text-2xl font-bold",
1719
1719
  children: "What overlays can do"
1720
- }, undefined, false, undefined, this),
1721
- /* @__PURE__ */ jsxDEV6("ul", {
1720
+ }),
1721
+ /* @__PURE__ */ jsxs6("ul", {
1722
1722
  className: "text-muted-foreground list-inside list-disc space-y-2",
1723
1723
  children: [
1724
- /* @__PURE__ */ jsxDEV6("li", {
1724
+ /* @__PURE__ */ jsxs6("li", {
1725
1725
  children: [
1726
- /* @__PURE__ */ jsxDEV6("strong", {
1726
+ /* @__PURE__ */ jsx6("strong", {
1727
1727
  children: "Hide or show fields"
1728
- }, undefined, false, undefined, this),
1728
+ }),
1729
1729
  " \u2013 Remove fields from forms or detail views (but only if the user has permission to see them in the first place)"
1730
1730
  ]
1731
- }, undefined, true, undefined, this),
1732
- /* @__PURE__ */ jsxDEV6("li", {
1731
+ }),
1732
+ /* @__PURE__ */ jsxs6("li", {
1733
1733
  children: [
1734
- /* @__PURE__ */ jsxDEV6("strong", {
1734
+ /* @__PURE__ */ jsx6("strong", {
1735
1735
  children: "Reorder fields"
1736
- }, undefined, false, undefined, this),
1736
+ }),
1737
1737
  " \u2013 Change the order in which fields appear"
1738
1738
  ]
1739
- }, undefined, true, undefined, this),
1740
- /* @__PURE__ */ jsxDEV6("li", {
1739
+ }),
1740
+ /* @__PURE__ */ jsxs6("li", {
1741
1741
  children: [
1742
- /* @__PURE__ */ jsxDEV6("strong", {
1742
+ /* @__PURE__ */ jsx6("strong", {
1743
1743
  children: "Rename labels"
1744
- }, undefined, false, undefined, this),
1744
+ }),
1745
1745
  " \u2013 Use different terminology that's more familiar to the user"
1746
1746
  ]
1747
- }, undefined, true, undefined, this),
1748
- /* @__PURE__ */ jsxDEV6("li", {
1747
+ }),
1748
+ /* @__PURE__ */ jsxs6("li", {
1749
1749
  children: [
1750
- /* @__PURE__ */ jsxDEV6("strong", {
1750
+ /* @__PURE__ */ jsx6("strong", {
1751
1751
  children: "Change layouts"
1752
- }, undefined, false, undefined, this),
1752
+ }),
1753
1753
  " \u2013 Switch between list, grid, or card views"
1754
1754
  ]
1755
- }, undefined, true, undefined, this),
1756
- /* @__PURE__ */ jsxDEV6("li", {
1755
+ }),
1756
+ /* @__PURE__ */ jsxs6("li", {
1757
1757
  children: [
1758
- /* @__PURE__ */ jsxDEV6("strong", {
1758
+ /* @__PURE__ */ jsx6("strong", {
1759
1759
  children: "Add help text"
1760
- }, undefined, false, undefined, this),
1760
+ }),
1761
1761
  " \u2013 Provide context-specific guidance"
1762
1762
  ]
1763
- }, undefined, true, undefined, this),
1764
- /* @__PURE__ */ jsxDEV6("li", {
1763
+ }),
1764
+ /* @__PURE__ */ jsxs6("li", {
1765
1765
  children: [
1766
- /* @__PURE__ */ jsxDEV6("strong", {
1766
+ /* @__PURE__ */ jsx6("strong", {
1767
1767
  children: "Set default values"
1768
- }, undefined, false, undefined, this),
1768
+ }),
1769
1769
  " \u2013 Pre-fill forms with tenant-specific defaults"
1770
1770
  ]
1771
- }, undefined, true, undefined, this),
1772
- /* @__PURE__ */ jsxDEV6("li", {
1771
+ }),
1772
+ /* @__PURE__ */ jsxs6("li", {
1773
1773
  children: [
1774
- /* @__PURE__ */ jsxDEV6("strong", {
1774
+ /* @__PURE__ */ jsx6("strong", {
1775
1775
  children: "Apply branding"
1776
- }, undefined, false, undefined, this),
1776
+ }),
1777
1777
  " \u2013 Customize colors, logos, and styling (within approved themes)"
1778
1778
  ]
1779
- }, undefined, true, undefined, this)
1779
+ })
1780
1780
  ]
1781
- }, undefined, true, undefined, this)
1781
+ })
1782
1782
  ]
1783
- }, undefined, true, undefined, this),
1784
- /* @__PURE__ */ jsxDEV6("div", {
1783
+ }),
1784
+ /* @__PURE__ */ jsxs6("div", {
1785
1785
  className: "space-y-4",
1786
1786
  children: [
1787
- /* @__PURE__ */ jsxDEV6("h2", {
1787
+ /* @__PURE__ */ jsx6("h2", {
1788
1788
  className: "text-2xl font-bold",
1789
1789
  children: "Example OverlaySpec"
1790
- }, undefined, false, undefined, this),
1791
- /* @__PURE__ */ jsxDEV6("p", {
1790
+ }),
1791
+ /* @__PURE__ */ jsx6("p", {
1792
1792
  className: "text-muted-foreground",
1793
1793
  children: "Here's an overlay that customizes an order form:"
1794
- }, undefined, false, undefined, this),
1795
- /* @__PURE__ */ jsxDEV6("div", {
1794
+ }),
1795
+ /* @__PURE__ */ jsx6("div", {
1796
1796
  className: "bg-background/50 border-border text-muted-foreground overflow-x-auto rounded-lg border p-4 font-mono text-sm",
1797
- children: /* @__PURE__ */ jsxDEV6("pre", {
1797
+ children: /* @__PURE__ */ jsx6("pre", {
1798
1798
  children: `overlayId: acme-order-form
1799
1799
  version: '1.0.0'.0.0
1800
1800
  appliesTo:
@@ -1833,244 +1833,244 @@ signature:
1833
1833
  algorithm: EdDSA
1834
1834
  publicKey: "acme-corp-overlay-key"
1835
1835
  signature: "base64-encoded-signature"`
1836
- }, undefined, false, undefined, this)
1837
- }, undefined, false, undefined, this)
1836
+ })
1837
+ })
1838
1838
  ]
1839
- }, undefined, true, undefined, this),
1840
- /* @__PURE__ */ jsxDEV6("div", {
1839
+ }),
1840
+ /* @__PURE__ */ jsxs6("div", {
1841
1841
  className: "space-y-4",
1842
1842
  children: [
1843
- /* @__PURE__ */ jsxDEV6("h2", {
1843
+ /* @__PURE__ */ jsx6("h2", {
1844
1844
  className: "text-2xl font-bold",
1845
1845
  children: "Safety guarantees"
1846
- }, undefined, false, undefined, this),
1847
- /* @__PURE__ */ jsxDEV6("p", {
1846
+ }),
1847
+ /* @__PURE__ */ jsx6("p", {
1848
1848
  className: "text-muted-foreground",
1849
1849
  children: "Overlays are powerful, but they must not compromise security or data integrity. ContractSpec enforces several guarantees:"
1850
- }, undefined, false, undefined, this),
1851
- /* @__PURE__ */ jsxDEV6("ul", {
1850
+ }),
1851
+ /* @__PURE__ */ jsxs6("ul", {
1852
1852
  className: "text-muted-foreground list-inside list-disc space-y-2",
1853
1853
  children: [
1854
- /* @__PURE__ */ jsxDEV6("li", {
1854
+ /* @__PURE__ */ jsxs6("li", {
1855
1855
  children: [
1856
- /* @__PURE__ */ jsxDEV6("strong", {
1856
+ /* @__PURE__ */ jsx6("strong", {
1857
1857
  children: "Overlays cannot grant new permissions"
1858
- }, undefined, false, undefined, this),
1858
+ }),
1859
1859
  " \u2013 They can only hide or rearrange what the user is already allowed to see"
1860
1860
  ]
1861
- }, undefined, true, undefined, this),
1862
- /* @__PURE__ */ jsxDEV6("li", {
1861
+ }),
1862
+ /* @__PURE__ */ jsxs6("li", {
1863
1863
  children: [
1864
- /* @__PURE__ */ jsxDEV6("strong", {
1864
+ /* @__PURE__ */ jsx6("strong", {
1865
1865
  children: "Overlays cannot bypass validation"
1866
- }, undefined, false, undefined, this),
1866
+ }),
1867
1867
  " \u2013 Field types, constraints, and business rules from the underlying spec still apply"
1868
1868
  ]
1869
- }, undefined, true, undefined, this),
1870
- /* @__PURE__ */ jsxDEV6("li", {
1869
+ }),
1870
+ /* @__PURE__ */ jsxs6("li", {
1871
1871
  children: [
1872
- /* @__PURE__ */ jsxDEV6("strong", {
1872
+ /* @__PURE__ */ jsx6("strong", {
1873
1873
  children: "Overlays must be signed"
1874
- }, undefined, false, undefined, this),
1874
+ }),
1875
1875
  " \u2013 Only authorized parties (typically tenant admins) can create overlays"
1876
1876
  ]
1877
- }, undefined, true, undefined, this),
1878
- /* @__PURE__ */ jsxDEV6("li", {
1877
+ }),
1878
+ /* @__PURE__ */ jsxs6("li", {
1879
1879
  children: [
1880
- /* @__PURE__ */ jsxDEV6("strong", {
1880
+ /* @__PURE__ */ jsx6("strong", {
1881
1881
  children: "Overlays are versioned"
1882
- }, undefined, false, undefined, this),
1882
+ }),
1883
1883
  " \u2013 Changes to overlays are tracked and can be rolled back"
1884
1884
  ]
1885
- }, undefined, true, undefined, this),
1886
- /* @__PURE__ */ jsxDEV6("li", {
1885
+ }),
1886
+ /* @__PURE__ */ jsxs6("li", {
1887
1887
  children: [
1888
- /* @__PURE__ */ jsxDEV6("strong", {
1888
+ /* @__PURE__ */ jsx6("strong", {
1889
1889
  children: "Overlays are audited"
1890
- }, undefined, false, undefined, this),
1890
+ }),
1891
1891
  " \u2013 Every overlay application is logged"
1892
1892
  ]
1893
- }, undefined, true, undefined, this)
1893
+ })
1894
1894
  ]
1895
- }, undefined, true, undefined, this)
1895
+ })
1896
1896
  ]
1897
- }, undefined, true, undefined, this),
1898
- /* @__PURE__ */ jsxDEV6("div", {
1897
+ }),
1898
+ /* @__PURE__ */ jsxs6("div", {
1899
1899
  className: "space-y-4",
1900
1900
  children: [
1901
- /* @__PURE__ */ jsxDEV6("h2", {
1901
+ /* @__PURE__ */ jsx6("h2", {
1902
1902
  className: "text-2xl font-bold",
1903
1903
  children: "Creating overlays"
1904
- }, undefined, false, undefined, this),
1905
- /* @__PURE__ */ jsxDEV6("p", {
1904
+ }),
1905
+ /* @__PURE__ */ jsx6("p", {
1906
1906
  className: "text-muted-foreground",
1907
1907
  children: "Overlays can be created through:"
1908
- }, undefined, false, undefined, this),
1909
- /* @__PURE__ */ jsxDEV6("ul", {
1908
+ }),
1909
+ /* @__PURE__ */ jsxs6("ul", {
1910
1910
  className: "text-muted-foreground list-inside list-disc space-y-2",
1911
1911
  children: [
1912
- /* @__PURE__ */ jsxDEV6("li", {
1912
+ /* @__PURE__ */ jsxs6("li", {
1913
1913
  children: [
1914
- /* @__PURE__ */ jsxDEV6("strong", {
1914
+ /* @__PURE__ */ jsx6("strong", {
1915
1915
  children: "Visual editor"
1916
- }, undefined, false, undefined, this),
1916
+ }),
1917
1917
  " \u2013 A drag-and-drop interface for non-technical users"
1918
1918
  ]
1919
- }, undefined, true, undefined, this),
1920
- /* @__PURE__ */ jsxDEV6("li", {
1919
+ }),
1920
+ /* @__PURE__ */ jsxs6("li", {
1921
1921
  children: [
1922
- /* @__PURE__ */ jsxDEV6("strong", {
1922
+ /* @__PURE__ */ jsx6("strong", {
1923
1923
  children: "TypeScript/JSON"
1924
- }, undefined, false, undefined, this),
1924
+ }),
1925
1925
  " \u2013 For developers who prefer code"
1926
1926
  ]
1927
- }, undefined, true, undefined, this),
1928
- /* @__PURE__ */ jsxDEV6("li", {
1927
+ }),
1928
+ /* @__PURE__ */ jsxs6("li", {
1929
1929
  children: [
1930
- /* @__PURE__ */ jsxDEV6("strong", {
1930
+ /* @__PURE__ */ jsx6("strong", {
1931
1931
  children: "API"
1932
- }, undefined, false, undefined, this),
1932
+ }),
1933
1933
  " \u2013 Programmatically create overlays for automation"
1934
1934
  ]
1935
- }, undefined, true, undefined, this)
1935
+ })
1936
1936
  ]
1937
- }, undefined, true, undefined, this),
1938
- /* @__PURE__ */ jsxDEV6("p", {
1937
+ }),
1938
+ /* @__PURE__ */ jsx6("p", {
1939
1939
  className: "text-muted-foreground",
1940
1940
  children: "Once created, overlays must be signed using a private key. The corresponding public key is registered with ContractSpec, which verifies the signature before applying the overlay."
1941
- }, undefined, false, undefined, this),
1942
- /* @__PURE__ */ jsxDEV6("p", {
1941
+ }),
1942
+ /* @__PURE__ */ jsxs6("p", {
1943
1943
  className: "text-muted-foreground",
1944
1944
  children: [
1945
1945
  "See",
1946
1946
  " ",
1947
- /* @__PURE__ */ jsxDEV6(Link6, {
1947
+ /* @__PURE__ */ jsx6(Link6, {
1948
1948
  href: "/docs/libraries/overlay-engine",
1949
1949
  className: "text-violet-400 underline",
1950
1950
  children: "Overlay Engine docs"
1951
- }, undefined, false, undefined, this),
1951
+ }),
1952
1952
  " ",
1953
1953
  "and the",
1954
1954
  " ",
1955
- /* @__PURE__ */ jsxDEV6(Link6, {
1955
+ /* @__PURE__ */ jsx6(Link6, {
1956
1956
  href: "/docs/advanced/overlay-editor",
1957
1957
  className: "text-violet-400 underline",
1958
1958
  children: "Overlay Editor guide"
1959
- }, undefined, false, undefined, this),
1959
+ }),
1960
1960
  " ",
1961
1961
  "for end-to-end workflows."
1962
1962
  ]
1963
- }, undefined, true, undefined, this)
1963
+ })
1964
1964
  ]
1965
- }, undefined, true, undefined, this),
1966
- /* @__PURE__ */ jsxDEV6("div", {
1965
+ }),
1966
+ /* @__PURE__ */ jsxs6("div", {
1967
1967
  className: "space-y-4",
1968
1968
  children: [
1969
- /* @__PURE__ */ jsxDEV6("h2", {
1969
+ /* @__PURE__ */ jsx6("h2", {
1970
1970
  className: "text-2xl font-bold",
1971
1971
  children: "Overlay scope"
1972
- }, undefined, false, undefined, this),
1973
- /* @__PURE__ */ jsxDEV6("p", {
1972
+ }),
1973
+ /* @__PURE__ */ jsx6("p", {
1974
1974
  className: "text-muted-foreground",
1975
1975
  children: "Overlays can be scoped to:"
1976
- }, undefined, false, undefined, this),
1977
- /* @__PURE__ */ jsxDEV6("ul", {
1976
+ }),
1977
+ /* @__PURE__ */ jsxs6("ul", {
1978
1978
  className: "text-muted-foreground list-inside list-disc space-y-2",
1979
1979
  children: [
1980
- /* @__PURE__ */ jsxDEV6("li", {
1980
+ /* @__PURE__ */ jsxs6("li", {
1981
1981
  children: [
1982
- /* @__PURE__ */ jsxDEV6("strong", {
1982
+ /* @__PURE__ */ jsx6("strong", {
1983
1983
  children: "Tenant"
1984
- }, undefined, false, undefined, this),
1984
+ }),
1985
1985
  " \u2013 All users in a tenant see the same overlay"
1986
1986
  ]
1987
- }, undefined, true, undefined, this),
1988
- /* @__PURE__ */ jsxDEV6("li", {
1987
+ }),
1988
+ /* @__PURE__ */ jsxs6("li", {
1989
1989
  children: [
1990
- /* @__PURE__ */ jsxDEV6("strong", {
1990
+ /* @__PURE__ */ jsx6("strong", {
1991
1991
  children: "User"
1992
- }, undefined, false, undefined, this),
1992
+ }),
1993
1993
  " \u2013 Individual users can have personal overlays"
1994
1994
  ]
1995
- }, undefined, true, undefined, this),
1996
- /* @__PURE__ */ jsxDEV6("li", {
1995
+ }),
1996
+ /* @__PURE__ */ jsxs6("li", {
1997
1997
  children: [
1998
- /* @__PURE__ */ jsxDEV6("strong", {
1998
+ /* @__PURE__ */ jsx6("strong", {
1999
1999
  children: "Role"
2000
- }, undefined, false, undefined, this),
2000
+ }),
2001
2001
  " \u2013 All users with a specific role see the overlay"
2002
2002
  ]
2003
- }, undefined, true, undefined, this),
2004
- /* @__PURE__ */ jsxDEV6("li", {
2003
+ }),
2004
+ /* @__PURE__ */ jsxs6("li", {
2005
2005
  children: [
2006
- /* @__PURE__ */ jsxDEV6("strong", {
2006
+ /* @__PURE__ */ jsx6("strong", {
2007
2007
  children: "Device"
2008
- }, undefined, false, undefined, this),
2008
+ }),
2009
2009
  " \u2013 Different overlays for mobile vs desktop"
2010
2010
  ]
2011
- }, undefined, true, undefined, this)
2011
+ })
2012
2012
  ]
2013
- }, undefined, true, undefined, this),
2014
- /* @__PURE__ */ jsxDEV6("p", {
2013
+ }),
2014
+ /* @__PURE__ */ jsx6("p", {
2015
2015
  className: "text-muted-foreground",
2016
2016
  children: "If multiple overlays apply to the same user, they are merged in order of specificity (user overlays override role overlays, which override tenant overlays)."
2017
- }, undefined, false, undefined, this)
2017
+ })
2018
2018
  ]
2019
- }, undefined, true, undefined, this),
2020
- /* @__PURE__ */ jsxDEV6("div", {
2019
+ }),
2020
+ /* @__PURE__ */ jsxs6("div", {
2021
2021
  className: "space-y-4",
2022
2022
  children: [
2023
- /* @__PURE__ */ jsxDEV6("h2", {
2023
+ /* @__PURE__ */ jsx6("h2", {
2024
2024
  className: "text-2xl font-bold",
2025
2025
  children: "Best practices"
2026
- }, undefined, false, undefined, this),
2027
- /* @__PURE__ */ jsxDEV6("ul", {
2026
+ }),
2027
+ /* @__PURE__ */ jsxs6("ul", {
2028
2028
  className: "text-muted-foreground list-inside list-disc space-y-2",
2029
2029
  children: [
2030
- /* @__PURE__ */ jsxDEV6("li", {
2030
+ /* @__PURE__ */ jsx6("li", {
2031
2031
  children: "Start with the default UI and only create overlays when users request specific changes."
2032
- }, undefined, false, undefined, this),
2033
- /* @__PURE__ */ jsxDEV6("li", {
2032
+ }),
2033
+ /* @__PURE__ */ jsx6("li", {
2034
2034
  children: "Document why each overlay modification was made\u2014this helps when reviewing or updating overlays."
2035
- }, undefined, false, undefined, this),
2036
- /* @__PURE__ */ jsxDEV6("li", {
2035
+ }),
2036
+ /* @__PURE__ */ jsx6("li", {
2037
2037
  children: "Test overlays thoroughly to ensure they don't break workflows or confuse users."
2038
- }, undefined, false, undefined, this),
2039
- /* @__PURE__ */ jsxDEV6("li", {
2038
+ }),
2039
+ /* @__PURE__ */ jsx6("li", {
2040
2040
  children: "Use tenant-level overlays for organizational customizations and user-level overlays for personal preferences."
2041
- }, undefined, false, undefined, this),
2042
- /* @__PURE__ */ jsxDEV6("li", {
2041
+ }),
2042
+ /* @__PURE__ */ jsx6("li", {
2043
2043
  children: "Regularly review overlays to remove ones that are no longer needed."
2044
- }, undefined, false, undefined, this),
2045
- /* @__PURE__ */ jsxDEV6("li", {
2044
+ }),
2045
+ /* @__PURE__ */ jsx6("li", {
2046
2046
  children: "Protect overlay signing keys carefully\u2014they control what customizations are allowed."
2047
- }, undefined, false, undefined, this)
2047
+ })
2048
2048
  ]
2049
- }, undefined, true, undefined, this)
2049
+ })
2050
2050
  ]
2051
- }, undefined, true, undefined, this),
2052
- /* @__PURE__ */ jsxDEV6("div", {
2051
+ }),
2052
+ /* @__PURE__ */ jsxs6("div", {
2053
2053
  className: "flex items-center gap-4 pt-4",
2054
2054
  children: [
2055
- /* @__PURE__ */ jsxDEV6(Link6, {
2055
+ /* @__PURE__ */ jsx6(Link6, {
2056
2056
  href: "/docs/specs/policy",
2057
2057
  className: "btn-ghost",
2058
2058
  children: "Previous: Policy"
2059
- }, undefined, false, undefined, this),
2060
- /* @__PURE__ */ jsxDEV6(Link6, {
2059
+ }),
2060
+ /* @__PURE__ */ jsxs6(Link6, {
2061
2061
  href: "/docs/safety",
2062
2062
  className: "btn-primary",
2063
2063
  children: [
2064
2064
  "Next: Safety ",
2065
- /* @__PURE__ */ jsxDEV6(ChevronRight6, {
2065
+ /* @__PURE__ */ jsx6(ChevronRight6, {
2066
2066
  size: 16
2067
- }, undefined, false, undefined, this)
2067
+ })
2068
2068
  ]
2069
- }, undefined, true, undefined, this)
2069
+ })
2070
2070
  ]
2071
- }, undefined, true, undefined, this)
2071
+ })
2072
2072
  ]
2073
- }, undefined, true, undefined, this);
2073
+ });
2074
2074
  }
2075
2075
  export {
2076
2076
  SpecsWorkflowsPage,