@bevel-software/platform-core-frontend 0.13.6 → 0.15.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (102) hide show
  1. package/package.json +2 -2
  2. package/src/core/CoreAppShell.tsx +18 -17
  3. package/src/core/__tests__/bootstrap.test.ts +33 -1
  4. package/src/core/bootstrap.ts +30 -1
  5. package/src/lib/__tests__/api.test.ts +38 -0
  6. package/src/lib/__tests__/utils.test.ts +43 -0
  7. package/src/lib/api.ts +19 -2
  8. package/src/lib/utils.ts +17 -7
  9. package/src/modules/access/__tests__/ManageAccessDialog.test.tsx +111 -1
  10. package/src/modules/access/__tests__/plugin-token.test.ts +21 -0
  11. package/src/modules/access/api.ts +52 -4
  12. package/src/modules/access/components/ManageAccessDialog.tsx +112 -83
  13. package/src/modules/git/__tests__/GitSyncFailedBanner.test.tsx +65 -1
  14. package/src/modules/git/components/GitSyncFailedBanner.tsx +68 -5
  15. package/src/modules/layout/components/SidebarFrame.tsx +1 -1
  16. package/src/modules/library/__tests__/LibraryRoutes.test.tsx +2 -1
  17. package/src/modules/library/__tests__/LibrarySidebarMenu.test.tsx +1 -1
  18. package/src/modules/library/__tests__/LinkSkillPanel.test.tsx +121 -0
  19. package/src/modules/library/__tests__/LockedPluginView.test.tsx +6 -0
  20. package/src/modules/library/__tests__/McpServerSection.test.tsx +7 -1
  21. package/src/modules/library/__tests__/NewPluginDialog.test.tsx +5 -4
  22. package/src/modules/library/__tests__/PluginExtras.test.tsx +15 -0
  23. package/src/modules/library/__tests__/PluginPage.test.tsx +195 -1
  24. package/src/modules/library/__tests__/PluginsSidebar.contextmenu.test.tsx +1 -1
  25. package/src/modules/library/__tests__/PluginsSidebar.locked.test.tsx +1 -1
  26. package/src/modules/library/__tests__/PluginsSidebar.test.tsx +64 -3
  27. package/src/modules/library/__tests__/SkillPage.test.tsx +9 -2
  28. package/src/modules/library/__tests__/SkillsTree.test.tsx +172 -0
  29. package/src/modules/library/__tests__/ToolConnectionSection.test.tsx +216 -8
  30. package/src/modules/library/__tests__/ToolPage.test.tsx +23 -3
  31. package/src/modules/library/__tests__/ToolVarRow.test.tsx +7 -7
  32. package/src/modules/library/__tests__/WorkspaceItemRoute.test.tsx +115 -4
  33. package/src/modules/library/__tests__/library-data.stale.test.tsx +90 -0
  34. package/src/modules/library/__tests__/library-paths.test.ts +32 -0
  35. package/src/modules/library/__tests__/link-membership.test.ts +120 -0
  36. package/src/modules/library/__tests__/plugin-summary.test.ts +32 -0
  37. package/src/modules/library/__tests__/status.test.ts +84 -0
  38. package/src/modules/library/__tests__/useJoinRequests.test.tsx +46 -0
  39. package/src/modules/library/components/AddToPluginDialog.tsx +33 -0
  40. package/src/modules/library/components/LibraryCard.tsx +21 -1
  41. package/src/modules/library/components/LibraryLayout.tsx +24 -14
  42. package/src/modules/library/components/LinkSkillPanel.tsx +171 -0
  43. package/src/modules/library/components/LockedPluginView.tsx +2 -2
  44. package/src/modules/library/components/NewPluginDialog.tsx +4 -4
  45. package/src/modules/library/components/PageActions.tsx +21 -1
  46. package/src/modules/library/components/PersonalPluginPage.tsx +2 -1
  47. package/src/modules/library/components/PluginExtras.tsx +3 -1
  48. package/src/modules/library/components/PluginPage.tsx +92 -12
  49. package/src/modules/library/components/PluginsIndexPage.tsx +11 -6
  50. package/src/modules/library/components/PluginsSidebar.tsx +110 -53
  51. package/src/modules/library/components/RenamePluginDialog.tsx +136 -0
  52. package/src/modules/library/components/SkillsTree.tsx +91 -0
  53. package/src/modules/library/components/StatusDot.tsx +1 -0
  54. package/src/modules/library/components/plugin-page-parts.tsx +32 -9
  55. package/src/modules/library/components/skill-page/SharedViaPlugins.tsx +218 -0
  56. package/src/modules/library/components/skill-page/SkillPage.tsx +75 -7
  57. package/src/modules/library/components/tool-page/McpServerSection.tsx +9 -1
  58. package/src/modules/library/components/tool-page/ToolConnectionSection.tsx +223 -8
  59. package/src/modules/library/components/tool-page/ToolPage.tsx +30 -2
  60. package/src/modules/library/components/tool-page/ToolVarRow.tsx +30 -8
  61. package/src/modules/library/hooks/useJoinRequests.ts +48 -18
  62. package/src/modules/library/hooks/useToolPage.ts +28 -11
  63. package/src/modules/library/routes/WorkspaceItemRoute.tsx +180 -83
  64. package/src/modules/library/routes/library-paths.ts +21 -8
  65. package/src/modules/library/services/library.api.ts +55 -1
  66. package/src/modules/library/services/plugins.api.ts +94 -3
  67. package/src/modules/library/state/library-data.tsx +115 -22
  68. package/src/modules/library/utils/plugin-summary.ts +36 -0
  69. package/src/modules/library/utils/status.ts +173 -17
  70. package/src/modules/onboarding/__tests__/creator-welcome.test.tsx +3 -2
  71. package/src/modules/secrets-vault/components/ConnectToolsPage.tsx +29 -14
  72. package/src/modules/secrets-vault/components/SecretsPage.tsx +4 -1
  73. package/src/modules/secrets-vault/components/ToolSecretsPanel.tsx +4 -1
  74. package/src/modules/secrets-vault/services/tool-secrets.api.ts +36 -0
  75. package/src/modules/settings/components/ClaudeConnectionCard.tsx +169 -0
  76. package/src/modules/settings/components/DeploymentPage.tsx +15 -1
  77. package/src/modules/settings/components/__tests__/ClaudeConnectionCard.test.tsx +63 -0
  78. package/src/modules/settings/components/__tests__/DeploymentPage.test.tsx +10 -0
  79. package/src/modules/settings/services/github-facade.api.ts +43 -0
  80. package/src/modules/setup/__tests__/setup.test.tsx +118 -0
  81. package/src/modules/setup/components/SetupGate.tsx +1 -1
  82. package/src/modules/setup/components/SetupScreen.tsx +195 -2
  83. package/src/modules/setup/services/setup.api.ts +78 -0
  84. package/src/modules/toolbar/components/ExternalAgentAccessPage.tsx +301 -93
  85. package/src/modules/toolbar/components/__tests__/ExternalAgentAccessPage.test.tsx +129 -6
  86. package/src/modules/toolbar/services/external-api-keys.api.ts +2 -0
  87. package/src/modules/workspace/__tests__/testFixtures.ts +1 -0
  88. package/src/modules/workspace/components/FileExplorer.tsx +292 -236
  89. package/src/modules/workspace/components/FileRoute.tsx +37 -0
  90. package/src/modules/workspace/components/__tests__/FileRoute.test.tsx +39 -0
  91. package/src/modules/workspace/components/__tests__/FileViewer.test.tsx +1 -0
  92. package/src/modules/workspace/hooks/useMergedWorkspaceTree.ts +70 -0
  93. package/src/modules/workspace/hooks/useWorkspaceState.ts +17 -3
  94. package/src/modules/workspace/routing/kb-routes.ts +1 -1
  95. package/src/modules/workspace/state/workspace.context.ts +8 -0
  96. package/src/modules/workspace/utils/__tests__/fileTree.test.ts +15 -0
  97. package/src/modules/workspace/utils/fileTree.ts +14 -16
  98. package/src/shared/__tests__/marketplace-url.test.ts +54 -0
  99. package/src/shared/components/Badge.tsx +3 -1
  100. package/src/shared/components/Banner.tsx +5 -1
  101. package/src/shared/marketplace-url.ts +90 -0
  102. package/src/shared/theme/tokens.css +9 -0
@@ -4,6 +4,7 @@ import { Check, Copy, Wrench, ExternalLink } from 'lucide-react';
4
4
  import { Dialog } from '../../../shared/components/Dialog';
5
5
  import { PageShell } from '../../../shared/components/PageShell';
6
6
  import { buttonClasses } from '../../../shared/components';
7
+ import { formatRelativeTime } from '../../../lib/utils';
7
8
  import {
8
9
  ConnectionInstructions,
9
10
  CopyBlock,
@@ -16,6 +17,8 @@ import {
16
17
  useCopyFeedback,
17
18
  workspaceBaseUrl,
18
19
  } from '../../../shared/mcp';
20
+ import { GITHUB_LINK_KIND, marketplaceCommands, marketplaceGitUrl } from '../../../shared/marketplace-url';
21
+ import { useAdmin } from '../../admin/state/admin.context';
19
22
  import {
20
23
  type ExternalApiKeySummary,
21
24
  type MintedExternalApiKey,
@@ -27,27 +30,27 @@ import {
27
30
 
28
31
  const MAX_LABEL_LEN = 200;
29
32
 
33
+ /**
34
+ * The shared formatter, plus the one word it deliberately leaves to the caller:
35
+ * a key that has never been used has no instant to describe.
36
+ */
30
37
  function formatRelative(ts: number | null): string {
31
- if (ts === null) return 'never';
32
- const diff = Date.now() - ts;
33
- const minutes = Math.round(diff / 60_000);
34
- if (minutes < 1) return 'just now';
35
- if (minutes < 60) return `${minutes} min ago`;
36
- const hours = Math.round(minutes / 60);
37
- if (hours < 24) return `${hours} hr ago`;
38
- const days = Math.round(hours / 24);
39
- if (days < 30) return `${days} day${days === 1 ? '' : 's'} ago`;
40
- return new Date(ts).toLocaleDateString();
38
+ return formatRelativeTime(ts) || 'never';
41
39
  }
42
40
 
43
41
  /**
44
42
  * The External agent access page, routed standalone at
45
- * `/external-agent-access` (below the persistent toolbar), in two tabs:
43
+ * `/external-agent-access` (below the persistent toolbar), in three tabs:
46
44
  *
47
45
  * - "Your agent" (default) — connecting the user's own interactive agent
48
46
  * (Claude Code, Claude Desktop, Cursor…). No key: the agent gets only the
49
47
  * server URL, and on first connect the browser opens our authorization
50
48
  * flow (sign in + choose tools on /connect). Copy-paste configs only.
49
+ * - "Marketplaces" — skills as native plugins rather than through the MCP
50
+ * server: the git remote Claude Code and Codex install from (with a key
51
+ * from the autonomous tab), and the Cowork / claude.ai route, where the
52
+ * person connects their Claude account and gets the marketplace compiled
53
+ * for what they may read. Their Claude links are listed here.
51
54
  * - "Autonomous agents" — the external-API-key surface for pipelines/CI
52
55
  * that can't open a browser: lists existing keys, mints new ones,
53
56
  * disconnects revoked ones, permanently deletes disconnected ones. The
@@ -77,7 +80,8 @@ export function ExternalAgentAccessPage() {
77
80
  */
78
81
  const workspaceUrl = workspaceBaseUrl();
79
82
 
80
- const [tab, setTab] = useState<'agent' | 'autonomous'>('agent');
83
+ const [tab, setTab] = useState<'agent' | 'marketplace' | 'autonomous'>('agent');
84
+ const { isAdmin } = useAdmin();
81
85
  const [keys, setKeys] = useState<ExternalApiKeySummary[]>([]);
82
86
  const [loading, setLoading] = useState(false);
83
87
  const [loadError, setLoadError] = useState<string | null>(null);
@@ -164,7 +168,14 @@ export function ExternalAgentAccessPage() {
164
168
  // top, never-used ones last among the active), with disconnected keys sunk
165
169
  // to the bottom. Non-destructive — nothing is hidden or deleted, just ordered
166
170
  // so a long list of stale/test keys doesn't bury the ones in use.
167
- const sortedKeys = [...keys].sort((a, b) => {
171
+ // ONE list from the server, two views of it: live Claude links belong to
172
+ // the Marketplaces tab (they were minted by a connection, not created
173
+ // here), everything else — hand-made keys, and Claude links once
174
+ // disconnected, so they can be deleted — to the autonomous tab. Told
175
+ // apart by the stored kind, never the label.
176
+ const isClaudeLink = (k: ExternalApiKeySummary) => k.kind === GITHUB_LINK_KIND;
177
+ const claudeLinks = keys.filter((k) => isClaudeLink(k) && k.revokedAt === null);
178
+ const sortedKeys = keys.filter((k) => !isClaudeLink(k) || k.revokedAt !== null).sort((a, b) => {
168
179
  const aRevoked = a.revokedAt !== null;
169
180
  const bRevoked = b.revokedAt !== null;
170
181
  if (aRevoked !== bRevoked) return aRevoked ? 1 : -1;
@@ -178,6 +189,7 @@ export function ExternalAgentAccessPage() {
178
189
  {(
179
190
  [
180
191
  ['agent', 'Your agent'],
192
+ ['marketplace', 'Marketplaces'],
181
193
  ['autonomous', 'Autonomous agents'],
182
194
  ] as const
183
195
  ).map(([id, name]) => (
@@ -284,6 +296,19 @@ export function ExternalAgentAccessPage() {
284
296
  </div>
285
297
  </details>
286
298
 
299
+ <p className="text-meta text-ink-muted leading-snug">
300
+ Prefer your skills installed as native plugins rather than read through the MCP
301
+ server? The{' '}
302
+ <button
303
+ type="button"
304
+ onClick={() => setTab('marketplace')}
305
+ className="underline text-ink-muted hover:text-ink"
306
+ >
307
+ Marketplaces
308
+ </button>{' '}
309
+ tab has the git remote for Claude Code and Codex, and the Cowork route.
310
+ </p>
311
+
287
312
  <p className="text-[11px] text-ink-muted leading-snug">
288
313
  Running an unattended pipeline or CI agent that can't open a browser? Use the{' '}
289
314
  <button
@@ -298,6 +323,134 @@ export function ExternalAgentAccessPage() {
298
323
  </div>
299
324
  )}
300
325
 
326
+ {tab === 'marketplace' && (
327
+ <div className="px-4 py-3 space-y-4">
328
+ <p className="text-xs text-ink-muted leading-snug">
329
+ Every skill you may read, compiled into a plugin marketplace. One address serves
330
+ every Claude surface: Claude Code and Codex clone it as a git remote, Cowork and
331
+ claude.ai fetch it as a repository once your account is connected.
332
+ </p>
333
+
334
+ <details className="border border-line rounded" data-testid="cowork-section">
335
+ <summary className="cursor-pointer px-3 py-2 text-xs font-medium text-ink">
336
+ Cowork and claude.ai
337
+ </summary>
338
+ <div className="px-3 pb-3 space-y-3">
339
+ <p className="text-meta text-ink-muted leading-snug">
340
+ Cowork and claude.ai take marketplaces only from GitHub, or from a GitHub
341
+ Enterprise Server your Claude organization registered. This deployment answers as
342
+ one: an Owner of your Claude organization registers it once
343
+ {isAdmin ? (
344
+ <>
345
+ {' '}
346
+ (the fields are on the{' '}
347
+ <Link to="/deployment" className="underline text-ink-muted hover:text-ink">
348
+ Deployment
349
+ </Link>{' '}
350
+ page)
351
+ </>
352
+ ) : (
353
+ <> (an admin here has the fields)</>
354
+ )}
355
+ , then every person connects their own account:
356
+ </p>
357
+ <ol className="text-meta text-ink-muted leading-snug list-decimal pl-4 space-y-0.5">
358
+ <li>In Cowork (or claude.ai), open Plugins → Add marketplace and paste the URL below.</li>
359
+ <li>
360
+ When it asks you to connect your GitHub Enterprise account, you land on this
361
+ deployment's sign-in: approve, and you are back in Claude.
362
+ </li>
363
+ <li>Install the plugins you want. Update in Claude pulls what changed.</li>
364
+ </ol>
365
+ <CopyBlock label="Marketplace URL" value={marketplaceGitUrl()} rows={2} />
366
+ <div className="space-y-1">
367
+ <div className="text-xs font-medium text-ink">Your Claude connections</div>
368
+ {loadError && (
369
+ <div className="text-xs text-red-600 bg-red-50 border border-red-200 rounded px-2 py-1.5">
370
+ {loadError}
371
+ </div>
372
+ )}
373
+ {loading ? (
374
+ <div className="text-meta text-ink-muted">Loading…</div>
375
+ ) : loadError ? null : claudeLinks.length === 0 ? (
376
+ <div className="text-meta text-ink-muted">
377
+ None yet. One appears here after you connect from Cowork or claude.ai.
378
+ </div>
379
+ ) : (
380
+ <ul className="divide-y divide-line border border-line rounded">
381
+ {claudeLinks.map((k) => (
382
+ <li key={k.id} className="flex items-center gap-3 px-3 py-2 text-sm">
383
+ <div className="flex-1 min-w-0">
384
+ <div className="font-medium truncate">{k.label}</div>
385
+ <div className="text-meta text-ink-muted">
386
+ Connected {formatRelative(k.createdAt)} · Last used {formatRelative(k.lastUsedAt)}
387
+ </div>
388
+ </div>
389
+ <button
390
+ onClick={() => handleDisconnect(k.id)}
391
+ className="text-xs px-2 py-1 rounded text-ink hover:bg-hover border border-line"
392
+ title="Disconnect this Claude account. Its marketplace stops updating; connect again from Claude to resume."
393
+ >
394
+ Disconnect
395
+ </button>
396
+ </li>
397
+ ))}
398
+ </ul>
399
+ )}
400
+ </div>
401
+ </div>
402
+ </details>
403
+
404
+ <details className="border border-line rounded" data-testid="marketplace-section">
405
+ <summary className="cursor-pointer px-3 py-2 text-xs font-medium text-ink">
406
+ Claude Code, Codex and the skills CLI
407
+ </summary>
408
+ <div className="px-3 pb-3 space-y-3">
409
+ <p className="text-meta text-ink-muted leading-snug">
410
+ These clone the marketplace as a git remote. The URL carries an external API
411
+ key from the{' '}
412
+ <button
413
+ type="button"
414
+ onClick={() => setTab('autonomous')}
415
+ className="underline text-ink-muted hover:text-ink"
416
+ >
417
+ Autonomous agents
418
+ </button>{' '}
419
+ tab — the key dialog there shows these commands filled in.
420
+ </p>
421
+ <CopyBlock label="Marketplace git remote" value={marketplaceGitUrl()} rows={2} />
422
+ <CopyBlock
423
+ label="Claude Code (one install, everything you may read)"
424
+ value={marketplaceCommands('<external-api-key>').claude}
425
+ rows={2}
426
+ />
427
+ <CopyBlock
428
+ label="Codex"
429
+ value={marketplaceCommands('<external-api-key>').codex}
430
+ rows={2}
431
+ />
432
+ <CopyBlock
433
+ label="Any other agent, via the skills CLI"
434
+ value={marketplaceCommands('<external-api-key>').skills}
435
+ rows={2}
436
+ />
437
+ <p className="text-meta text-ink-muted leading-snug">
438
+ The key stays in the URL: Claude Code refreshes marketplaces in the background
439
+ without credential helpers. Revoke the key to cut the agent off. In Claude Code
440
+ add it through the CLI or the Claude Code section of the Desktop app's
441
+ Customize screen; the Chat and Cowork screens use the route above instead.
442
+ </p>
443
+ <p className="text-meta text-ink-muted leading-snug">
444
+ Add it through Claude Code: the CLI, or the Claude Code section of the
445
+ Desktop app's Customize screen. The Chat and Cowork plugin screens accept
446
+ only GitHub, GitLab and Bitbucket remotes and refuse this one as an
447
+ unsupported host.
448
+ </p>
449
+ </div>
450
+ </details>
451
+ </div>
452
+ )}
453
+
301
454
  {tab === 'autonomous' && (
302
455
  <div className="px-4 py-3 space-y-4">
303
456
  <p className="text-xs text-ink-muted leading-snug">
@@ -347,8 +500,11 @@ export function ExternalAgentAccessPage() {
347
500
  )}
348
501
  {loading ? (
349
502
  <div className="text-xs text-ink-muted">Loading…</div>
350
- ) : keys.length === 0 ? (
351
- <div className="text-xs text-ink-muted">No external API keys yet.</div>
503
+ ) : sortedKeys.length === 0 ? (
504
+ <div className="text-xs text-ink-muted">
505
+ No external API keys yet.
506
+ {claudeLinks.length > 0 && ' Your Claude connections are on the Marketplaces tab.'}
507
+ </div>
352
508
  ) : (
353
509
  <ul className="divide-y divide-line border border-line rounded">
354
510
  {sortedKeys.map((k) => {
@@ -485,89 +641,141 @@ export function ExternalAgentAccessPage() {
485
641
  {copied ? <Check size={14} /> : <Copy size={14} />}
486
642
  </button>
487
643
  </div>
488
- <div>
489
- <div className="text-xs font-medium text-ink mb-1">
644
+ {/* The SAME three drawers as the interactive tab — local server,
645
+ hosted endpoint, marketplace — in the same order and CLOSED,
646
+ with the key filled in. The key is the news here; which
647
+ config the reader needs is their call, and five config walls
648
+ in a row buried the one thing the dialog exists to hand over.
649
+ Same summaries as the tab too, so a person who read the tab
650
+ first finds the drawer they already picked. */}
651
+ <details className="border border-line rounded">
652
+ <summary className="cursor-pointer px-3 py-2 text-xs font-medium text-ink">
490
653
  Desktop agents — the local server (recommended)
654
+ </summary>
655
+ <div className="px-3 pb-3 space-y-2">
656
+ <p className="text-meta text-ink-muted leading-snug">
657
+ For agents that run on your machine: Claude Code, Claude Desktop, Cursor,
658
+ Windsurf, Cline and similar. Runs this workspace as a local MCP server (needs
659
+ Node): the agent gets everything the hosted endpoint serves, plus your
660
+ plugins' local-only tools. In Claude Code:
661
+ </p>
662
+ <textarea
663
+ readOnly
664
+ value={hexisMcpClaudeCommand(workspaceUrl, reveal.plaintext)}
665
+ rows={3}
666
+ className="w-full font-mono text-meta bg-sunken border border-line rounded px-2 py-1.5 resize-none"
667
+ onFocus={(e) => e.currentTarget.select()}
668
+ />
669
+ <p className="text-meta text-ink-muted leading-snug">
670
+ On Windows, prefer the JSON config below — this one-liner assumes a POSIX
671
+ shell (macOS, Linux, WSL or Git Bash).
672
+ </p>
673
+ <p className="text-meta text-ink-muted leading-snug">
674
+ Or as a JSON config, for Claude Desktop, Cursor, Windsurf, Cline and
675
+ similar:
676
+ </p>
677
+ <textarea
678
+ readOnly
679
+ value={hexisMcpJsonSnippet(workspaceUrl, reveal.plaintext)}
680
+ rows={13}
681
+ className="w-full font-mono text-meta bg-sunken border border-line rounded px-2 py-1.5 resize-none"
682
+ onFocus={(e) => e.currentTarget.select()}
683
+ />
491
684
  </div>
492
- <p className="text-meta text-ink-muted mb-1 leading-snug">
493
- For agents that run on your machine: Claude Code, Claude Desktop, Cursor,
494
- Windsurf, Cline and similar. Runs this workspace as a local MCP server (needs
495
- Node): the agent gets everything the hosted endpoint serves, plus your
496
- plugins' local-only tools. In Claude Code:
497
- </p>
498
- <textarea
499
- readOnly
500
- value={hexisMcpClaudeCommand(workspaceUrl, reveal.plaintext)}
501
- rows={3}
502
- className="w-full font-mono text-meta bg-sunken border border-line rounded px-2 py-1.5 resize-none"
503
- onFocus={(e) => e.currentTarget.select()}
504
- />
505
- <p className="text-meta text-ink-muted mt-1 leading-snug">
506
- On Windows, prefer the JSON config below — this one-liner assumes a POSIX
507
- shell (macOS, Linux, WSL or Git Bash).
508
- </p>
509
- <p className="text-meta text-ink-muted mt-2 mb-1 leading-snug">
510
- Or as a JSON config, for Claude Desktop, Cursor, Windsurf, Cline and
511
- similar:
512
- </p>
513
- <textarea
514
- readOnly
515
- value={hexisMcpJsonSnippet(workspaceUrl, reveal.plaintext)}
516
- rows={13}
517
- className="w-full font-mono text-meta bg-sunken border border-line rounded px-2 py-1.5 resize-none"
518
- onFocus={(e) => e.currentTarget.select()}
519
- />
520
- </div>
521
- <div>
522
- <div className="text-xs font-medium text-ink mb-1">
685
+ </details>
686
+
687
+ <details className="border border-line rounded">
688
+ <summary className="cursor-pointer px-3 py-2 text-xs font-medium text-ink">
523
689
  Web agents and pipelines — the hosted endpoint
690
+ </summary>
691
+ <div className="px-3 pb-3 space-y-3">
692
+ <div>
693
+ <p className="text-meta text-ink-muted mb-1 leading-snug">
694
+ For agents that can't run a process on your machine, and for CI where
695
+ installing Node is unwanted. Claude Code, via the hosted endpoint:
696
+ </p>
697
+ <textarea
698
+ readOnly
699
+ value={claudeCodeCommand(mcpUrl, reveal.plaintext)}
700
+ rows={3}
701
+ className="w-full font-mono text-meta bg-sunken border border-line rounded px-2 py-1.5 resize-none"
702
+ onFocus={(e) => e.currentTarget.select()}
703
+ />
704
+ </div>
705
+ <div>
706
+ <div className="text-xs font-medium text-ink mb-1">Connect Langdock</div>
707
+ <ol className="text-meta text-ink-muted mb-1 leading-snug list-decimal pl-4 space-y-0.5">
708
+ <li>In Langdock, open your workspace settings and go to MCP servers → Add server.</li>
709
+ <li>Choose <span className="font-medium">HTTP</span> (Streamable HTTP) as the transport.</li>
710
+ <li>Give it a name (e.g. <span className="font-medium">Bevel</span>), paste the URL below into the server URL field, and add the Authorization header under custom headers.</li>
711
+ <li>Save, then enable the server in any assistant you want it available in.</li>
712
+ </ol>
713
+ <textarea
714
+ readOnly
715
+ value={langdockSnippet(mcpUrl, reveal.plaintext)}
716
+ rows={3}
717
+ className="w-full font-mono text-meta bg-sunken border border-line rounded px-2 py-1.5 resize-none"
718
+ onFocus={(e) => e.currentTarget.select()}
719
+ />
720
+ </div>
721
+ <div>
722
+ <div className="text-xs font-medium text-ink mb-1">Other agents (JSON config)</div>
723
+ <p className="text-meta text-ink-muted mb-1 leading-snug">
724
+ The hosted endpoint for most clients that load servers from a JSON config —
725
+ when the local server above isn't wanted.
726
+ </p>
727
+ <textarea
728
+ readOnly
729
+ value={jsonConfigSnippet(mcpUrl, reveal.plaintext)}
730
+ rows={11}
731
+ className="w-full font-mono text-meta bg-sunken border border-line rounded px-2 py-1.5 resize-none"
732
+ onFocus={(e) => e.currentTarget.select()}
733
+ />
734
+ </div>
524
735
  </div>
525
- <p className="text-meta text-ink-muted mb-1 leading-snug">
526
- For agents that can't run a process on your machine, and for CI where
527
- installing Node is unwanted. Claude Code, via the hosted endpoint:
528
- </p>
529
- <textarea
530
- readOnly
531
- value={claudeCodeCommand(mcpUrl, reveal.plaintext)}
532
- rows={3}
533
- className="w-full font-mono text-[11px] bg-sunken border border-line rounded px-2 py-1.5 resize-none"
534
- onFocus={(e) => e.currentTarget.select()}
535
- />
536
- </div>
537
- <div>
538
- <div className="text-xs font-medium text-ink mb-1">
539
- Connect Langdock
540
- </div>
541
- <ol className="text-[11px] text-ink-muted mb-1 leading-snug list-decimal pl-4 space-y-0.5">
542
- <li>In Langdock, open your workspace settings and go to MCP servers → Add server.</li>
543
- <li>Choose <span className="font-medium">HTTP</span> (Streamable HTTP) as the transport.</li>
544
- <li>Give it a name (e.g. <span className="font-medium">Bevel</span>), paste the URL below into the server URL field, and add the Authorization header under custom headers.</li>
545
- <li>Save, then enable the server in any assistant you want it available in.</li>
546
- </ol>
547
- <textarea
548
- readOnly
549
- value={langdockSnippet(mcpUrl, reveal.plaintext)}
550
- rows={3}
551
- className="w-full font-mono text-[11px] bg-sunken border border-line rounded px-2 py-1.5 resize-none"
552
- onFocus={(e) => e.currentTarget.select()}
553
- />
554
- </div>
555
- <div>
556
- <div className="text-xs font-medium text-ink mb-1">
557
- Other agents (JSON config)
736
+ </details>
737
+
738
+ <details className="border border-line rounded">
739
+ <summary className="cursor-pointer px-3 py-2 text-xs font-medium text-ink">
740
+ Skills as native plugins — the marketplace
741
+ </summary>
742
+ <div className="px-3 pb-3 space-y-2">
743
+ <p className="text-meta text-ink-muted leading-snug">
744
+ Every skill you may read, compiled into a plugin marketplace served as a git
745
+ remote. One install brings all of it; a later update fetches what changed.
746
+ The key stays in the URL because Claude Code refreshes marketplaces without
747
+ credential helpers. Add it through Claude Code (the CLI, or the Claude
748
+ Code section of the Desktop app's Customize screen): the Chat and Cowork
749
+ plugin screens accept only GitHub, GitLab and Bitbucket remotes.
750
+ </p>
751
+ <textarea
752
+ readOnly
753
+ aria-label="Claude Code marketplace command"
754
+ value={marketplaceCommands(reveal.plaintext).claude}
755
+ rows={2}
756
+ className="w-full font-mono text-meta bg-sunken border border-line rounded px-2 py-1.5 resize-none"
757
+ onFocus={(e) => e.currentTarget.select()}
758
+ />
759
+ <p className="text-meta text-ink-muted leading-snug">Codex installs every plugin on add:</p>
760
+ <textarea
761
+ readOnly
762
+ aria-label="Codex marketplace command"
763
+ value={marketplaceCommands(reveal.plaintext).codex}
764
+ rows={2}
765
+ className="w-full font-mono text-meta bg-sunken border border-line rounded px-2 py-1.5 resize-none"
766
+ onFocus={(e) => e.currentTarget.select()}
767
+ />
768
+ <p className="text-meta text-ink-muted leading-snug">Any other agent, through the skills CLI:</p>
769
+ <textarea
770
+ readOnly
771
+ aria-label="skills CLI command"
772
+ value={marketplaceCommands(reveal.plaintext).skills}
773
+ rows={2}
774
+ className="w-full font-mono text-meta bg-sunken border border-line rounded px-2 py-1.5 resize-none"
775
+ onFocus={(e) => e.currentTarget.select()}
776
+ />
558
777
  </div>
559
- <p className="text-[11px] text-ink-muted mb-1 leading-snug">
560
- The hosted endpoint for most clients that load servers from a JSON config —
561
- when the local server above isn't wanted.
562
- </p>
563
- <textarea
564
- readOnly
565
- value={jsonConfigSnippet(mcpUrl, reveal.plaintext)}
566
- rows={11}
567
- className="w-full font-mono text-[11px] bg-sunken border border-line rounded px-2 py-1.5 resize-none"
568
- onFocus={(e) => e.currentTarget.select()}
569
- />
570
- </div>
778
+ </details>
571
779
  </div>
572
780
  <div className="flex justify-end px-4 py-3 border-t border-line">
573
781
  <button