@spacefast/setup-ui 0.2.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.
- package/dist/agent-icons.d.ts +3 -0
- package/dist/agent-icons.d.ts.map +1 -0
- package/dist/agent-icons.js +38 -0
- package/dist/agent-icons.js.map +1 -0
- package/dist/assets/README.md +15 -0
- package/dist/assets/amp.svg +34 -0
- package/dist/assets/claude.svg +3 -0
- package/dist/assets/cline.svg +16 -0
- package/dist/assets/codex.svg +1 -0
- package/dist/assets/continue.svg +4 -0
- package/dist/assets/cursor.svg +1 -0
- package/dist/assets/devin.svg +3 -0
- package/dist/assets/factory-droid.svg +8 -0
- package/dist/assets/github-copilot.svg +1 -0
- package/dist/assets/googlegemini.svg +1 -0
- package/dist/assets/hermes.svg +1 -0
- package/dist/assets/indent.svg +1 -0
- package/dist/assets/openai.svg +1 -0
- package/dist/assets/openclaw.svg +1 -0
- package/dist/assets/opencode.svg +7 -0
- package/dist/assets/pi.svg +1 -0
- package/dist/assets/poke.svg +1 -0
- package/dist/assets/raycast.svg +1 -0
- package/dist/assets/vscode.svg +1 -0
- package/dist/assets/warp.svg +1 -0
- package/dist/assets/zedindustries.svg +1 -0
- package/dist/index.d.ts +194 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +228 -0
- package/dist/index.js.map +1 -0
- package/package.json +53 -0
- package/src/styles.css +827 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
import { type ReactNode } from "react";
|
|
2
|
+
export { SETUP_AGENT_ICON_KEYS, setupAgentIconUrl } from "./agent-icons.js";
|
|
3
|
+
export type AgentListingStatus = "live" | "submitted" | "planned";
|
|
4
|
+
export type AgentSetupMethod = Readonly<{
|
|
5
|
+
id: string;
|
|
6
|
+
kind: "plugin" | "deeplink" | "command" | "config" | "prompt" | "download" | "skill";
|
|
7
|
+
label: string;
|
|
8
|
+
summary: string;
|
|
9
|
+
listingStatus?: AgentListingStatus;
|
|
10
|
+
action: {
|
|
11
|
+
kind: "copy";
|
|
12
|
+
value: string;
|
|
13
|
+
label?: string;
|
|
14
|
+
} | {
|
|
15
|
+
kind: "link";
|
|
16
|
+
href: string;
|
|
17
|
+
label?: string;
|
|
18
|
+
} | {
|
|
19
|
+
kind: "disabled";
|
|
20
|
+
label?: string;
|
|
21
|
+
};
|
|
22
|
+
docsHref?: string;
|
|
23
|
+
/** The vendor's own doc for this exact method, linked beside the summary. */
|
|
24
|
+
vendorDocs?: Readonly<{
|
|
25
|
+
href: string;
|
|
26
|
+
label: string;
|
|
27
|
+
}>;
|
|
28
|
+
}>;
|
|
29
|
+
export type AgentSetupView = Readonly<{
|
|
30
|
+
id: string;
|
|
31
|
+
name: string;
|
|
32
|
+
vendor: string;
|
|
33
|
+
description: string;
|
|
34
|
+
/** Page headline. Defaults to “Connect {name}”. */
|
|
35
|
+
title?: string;
|
|
36
|
+
iconSrc?: string;
|
|
37
|
+
monogram?: string;
|
|
38
|
+
tier: "featured" | "listed";
|
|
39
|
+
primary: AgentSetupMethod;
|
|
40
|
+
alternates?: readonly AgentSetupMethod[];
|
|
41
|
+
terminalAlternates?: readonly AgentSetupMethod[];
|
|
42
|
+
}>;
|
|
43
|
+
export type AgentPickerItem = Readonly<{
|
|
44
|
+
id: string;
|
|
45
|
+
name: string;
|
|
46
|
+
vendor: string;
|
|
47
|
+
description?: string;
|
|
48
|
+
iconSrc?: string;
|
|
49
|
+
monogram?: string;
|
|
50
|
+
/** Optional section label; items sharing a group render under one heading. */
|
|
51
|
+
group?: string;
|
|
52
|
+
}>;
|
|
53
|
+
export type SourceLane = Readonly<{
|
|
54
|
+
id: string;
|
|
55
|
+
label: string;
|
|
56
|
+
description: string;
|
|
57
|
+
href: string;
|
|
58
|
+
}>;
|
|
59
|
+
export type AgentSetupDockMode = "redeemable" | "personalized" | "public";
|
|
60
|
+
export type AgentSetupDockState = "loading" | "ready" | "error" | "expired" | "consumed" | "revoked";
|
|
61
|
+
export type SetupFailureKind = keyof typeof FAILURE_COPY;
|
|
62
|
+
export type SetupCopyHandler = (method: AgentSetupMethod) => void | Promise<void>;
|
|
63
|
+
export type SetupOpenHandler = (method: AgentSetupMethod) => void;
|
|
64
|
+
declare const FAILURE_COPY: {
|
|
65
|
+
readonly expired: {
|
|
66
|
+
readonly title: "Link expired.";
|
|
67
|
+
readonly description: "Handoff links last 15 minutes and one use. Copy creates a fresh one.";
|
|
68
|
+
};
|
|
69
|
+
readonly consumed: {
|
|
70
|
+
readonly title: "Link already used.";
|
|
71
|
+
readonly description: "This one-time link was redeemed. Copy a fresh prompt to continue.";
|
|
72
|
+
};
|
|
73
|
+
readonly revoked: {
|
|
74
|
+
readonly title: "Link revoked.";
|
|
75
|
+
readonly description: "This link no longer grants access. Copy a fresh prompt to continue.";
|
|
76
|
+
};
|
|
77
|
+
readonly "install-failed": {
|
|
78
|
+
readonly title: "Install failed.";
|
|
79
|
+
readonly description: "Use the tested fallback below, then retry the primary path when you are ready.";
|
|
80
|
+
};
|
|
81
|
+
readonly "deeplink-missing": {
|
|
82
|
+
readonly title: "Nothing happened?";
|
|
83
|
+
readonly description: "The app may not be installed or its link handler is unavailable. Use the command instead.";
|
|
84
|
+
};
|
|
85
|
+
readonly "config-blocked": {
|
|
86
|
+
readonly title: "Config write blocked.";
|
|
87
|
+
readonly description: "That file has changes Spacefast will not overwrite. Apply the config manually instead.";
|
|
88
|
+
};
|
|
89
|
+
readonly "oauth-denied": {
|
|
90
|
+
readonly title: "Connection denied.";
|
|
91
|
+
readonly description: "No access was granted. Start the sign-in flow again when you are ready.";
|
|
92
|
+
};
|
|
93
|
+
readonly "rate-limited": {
|
|
94
|
+
readonly title: "Too many attempts.";
|
|
95
|
+
readonly description: "Wait before trying again. Repeated denied confirmations are rate limited.";
|
|
96
|
+
};
|
|
97
|
+
};
|
|
98
|
+
export declare function AgentMark({ item, className, }: {
|
|
99
|
+
item: {
|
|
100
|
+
name: string;
|
|
101
|
+
iconSrc?: string;
|
|
102
|
+
monogram?: string;
|
|
103
|
+
};
|
|
104
|
+
className?: string | undefined;
|
|
105
|
+
}): import("react").JSX.Element;
|
|
106
|
+
export declare function AgentAvatarGroup({ items, max, className, }: {
|
|
107
|
+
items: readonly {
|
|
108
|
+
name: string;
|
|
109
|
+
iconSrc?: string;
|
|
110
|
+
monogram?: string;
|
|
111
|
+
}[];
|
|
112
|
+
max?: number;
|
|
113
|
+
className?: string | undefined;
|
|
114
|
+
}): import("react").JSX.Element;
|
|
115
|
+
export declare function SourceLaneCards({ lanes, compact, onOpen, className, }: {
|
|
116
|
+
lanes: readonly SourceLane[];
|
|
117
|
+
compact?: boolean;
|
|
118
|
+
onOpen?: ((lane: SourceLane) => void) | undefined;
|
|
119
|
+
className?: string | undefined;
|
|
120
|
+
}): import("react").JSX.Element;
|
|
121
|
+
export declare function SetupMethodCard({ method, primary, copied, onCopy, onOpen, }: {
|
|
122
|
+
method: AgentSetupMethod;
|
|
123
|
+
primary?: boolean | undefined;
|
|
124
|
+
copied?: boolean | undefined;
|
|
125
|
+
onCopy?: SetupCopyHandler | undefined;
|
|
126
|
+
onOpen?: SetupOpenHandler | undefined;
|
|
127
|
+
}): import("react").JSX.Element;
|
|
128
|
+
export declare function SetupFailureFrame({ kind, fallback, onCopy, onRetry, }: {
|
|
129
|
+
kind: SetupFailureKind;
|
|
130
|
+
fallback?: AgentSetupMethod | undefined;
|
|
131
|
+
onCopy?: SetupCopyHandler | undefined;
|
|
132
|
+
onRetry?: (() => void) | undefined;
|
|
133
|
+
}): import("react").JSX.Element;
|
|
134
|
+
export declare function TerminalAlternates({ methods, onCopy, }: {
|
|
135
|
+
methods: readonly AgentSetupMethod[];
|
|
136
|
+
onCopy?: SetupCopyHandler | undefined;
|
|
137
|
+
}): import("react").JSX.Element | null;
|
|
138
|
+
export declare function GenericMcpLane({ endpoint, config, docsLinks, onCopy, }: {
|
|
139
|
+
endpoint: string;
|
|
140
|
+
config: string;
|
|
141
|
+
docsLinks?: readonly {
|
|
142
|
+
label: string;
|
|
143
|
+
href: string;
|
|
144
|
+
}[] | undefined;
|
|
145
|
+
onCopy?: SetupCopyHandler | undefined;
|
|
146
|
+
}): import("react").JSX.Element;
|
|
147
|
+
export declare function AgentPicker({ agents, onSelect, endpoint, config, docsLinks, onCopy, }: {
|
|
148
|
+
agents: readonly AgentPickerItem[];
|
|
149
|
+
onSelect: (agent: AgentPickerItem) => void;
|
|
150
|
+
endpoint: string;
|
|
151
|
+
config: string;
|
|
152
|
+
docsLinks?: readonly {
|
|
153
|
+
label: string;
|
|
154
|
+
href: string;
|
|
155
|
+
}[] | undefined;
|
|
156
|
+
onCopy?: SetupCopyHandler | undefined;
|
|
157
|
+
}): import("react").JSX.Element;
|
|
158
|
+
export declare function DetectionConfirmation({ agent, onConfirm, onPickAnother, }: {
|
|
159
|
+
agent: AgentPickerItem;
|
|
160
|
+
onConfirm: () => void;
|
|
161
|
+
onPickAnother: () => void;
|
|
162
|
+
}): import("react").JSX.Element;
|
|
163
|
+
export declare function AgentSetupPage({ agent, sourceLanes, onCopy, onOpen, onBack, failure, }: {
|
|
164
|
+
agent: AgentSetupView;
|
|
165
|
+
sourceLanes: readonly SourceLane[];
|
|
166
|
+
onCopy?: SetupCopyHandler | undefined;
|
|
167
|
+
onOpen?: SetupOpenHandler | undefined;
|
|
168
|
+
onBack?: (() => void) | undefined;
|
|
169
|
+
failure?: {
|
|
170
|
+
kind: SetupFailureKind;
|
|
171
|
+
fallback?: AgentSetupMethod | undefined;
|
|
172
|
+
onRetry?: (() => void) | undefined;
|
|
173
|
+
} | undefined;
|
|
174
|
+
}): import("react").JSX.Element;
|
|
175
|
+
export declare function AgentSetupDock({ mode, state, status, copied, onCopy, onRetry, }: {
|
|
176
|
+
mode: AgentSetupDockMode;
|
|
177
|
+
state: AgentSetupDockState;
|
|
178
|
+
status?: string | null | undefined;
|
|
179
|
+
copied?: boolean | undefined;
|
|
180
|
+
onCopy: () => void;
|
|
181
|
+
onRetry?: (() => void) | undefined;
|
|
182
|
+
}): import("react").JSX.Element;
|
|
183
|
+
export declare function LetAgentChooseOption({ onChoose, copied, hotkey, }: {
|
|
184
|
+
onChoose: () => void;
|
|
185
|
+
copied?: boolean | undefined;
|
|
186
|
+
hotkey?: string | undefined;
|
|
187
|
+
}): import("react").JSX.Element;
|
|
188
|
+
export declare function AgentPageState({ kind, title, description, action, }: {
|
|
189
|
+
kind: "loading" | "error" | "blocked" | "expired" | "post-claim";
|
|
190
|
+
title: string;
|
|
191
|
+
description: string;
|
|
192
|
+
action?: ReactNode | undefined;
|
|
193
|
+
}): import("react").JSX.Element;
|
|
194
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.tsx"],"names":[],"mappings":"AAcA,OAAO,EAAoC,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAEzE,OAAO,EAAE,qBAAqB,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAE5E,MAAM,MAAM,kBAAkB,GAAG,MAAM,GAAG,WAAW,GAAG,SAAS,CAAC;AAElE,MAAM,MAAM,gBAAgB,GAAG,QAAQ,CAAC;IACtC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,QAAQ,GAAG,UAAU,GAAG,SAAS,GAAG,QAAQ,GAAG,QAAQ,GAAG,UAAU,GAAG,OAAO,CAAC;IACrF,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,aAAa,CAAC,EAAE,kBAAkB,CAAC;IACnC,MAAM,EACF;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAA;KAAE,GAC/C;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAA;KAAE,GAC9C;QAAE,IAAI,EAA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;AAED,wBAAgB,cAAc,CAAC,EAC7B,IAAI,EACJ,KAAK,EACL,MAAM,EACN,MAAc,EACd,MAAM,EACN,OAAO,GACR,EAAE;IACD,IAAI,EAAE,kBAAkB,CAAC;IACzB,KAAK,EAAE,mBAAmB,CAAC;IAC3B,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IACnC,MAAM,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAC7B,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,OAAO,CAAC,EAAE,CAAC,MAAM,IAAI,CAAC,GAAG,SAAS,CAAC;CACpC,+BAwCA;AAED,wBAAgB,oBAAoB,CAAC,EACnC,QAAQ,EACR,MAAc,EACd,MAAM,GACP,EAAE;IACD,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,MAAM,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAC7B,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CAC7B,+BAeA;AAED,wBAAgB,cAAc,CAAC,EAC7B,IAAI,EACJ,KAAK,EACL,WAAW,EACX,MAAM,GACP,EAAE;IACD,IAAI,EAAE,SAAS,GAAG,OAAO,GAAG,SAAS,GAAG,SAAS,GAAG,YAAY,CAAC;IACjE,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,SAAS,GAAG,SAAS,CAAC;CAChC,+BAcA"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,228 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { ArrowRightIcon, ArrowSquareOutIcon, BracketsCurlyIcon, CheckIcon, CopyIcon, GitBranchIcon, GithubLogoIcon, MagnifyingGlassIcon, RobotIcon, TerminalIcon, TerminalWindowIcon, UploadSimpleIcon, } from "@phosphor-icons/react";
|
|
3
|
+
import { useId, useMemo, useRef, useState } from "react";
|
|
4
|
+
export { SETUP_AGENT_ICON_KEYS, setupAgentIconUrl } from "./agent-icons.js";
|
|
5
|
+
const DOCK_EFFECT = {
|
|
6
|
+
redeemable: "Creates a one-time link your agent redeems — expires in 15 minutes.",
|
|
7
|
+
personalized: "Copies a prompt with your space details — no credentials.",
|
|
8
|
+
public: "Copies a prompt that tells your agent where to start.",
|
|
9
|
+
};
|
|
10
|
+
const NO_DOC_LINKS = [];
|
|
11
|
+
const FAILURE_COPY = {
|
|
12
|
+
expired: {
|
|
13
|
+
title: "Link expired.",
|
|
14
|
+
description: "Handoff links last 15 minutes and one use. Copy creates a fresh one.",
|
|
15
|
+
},
|
|
16
|
+
consumed: {
|
|
17
|
+
title: "Link already used.",
|
|
18
|
+
description: "This one-time link was redeemed. Copy a fresh prompt to continue.",
|
|
19
|
+
},
|
|
20
|
+
revoked: {
|
|
21
|
+
title: "Link revoked.",
|
|
22
|
+
description: "This link no longer grants access. Copy a fresh prompt to continue.",
|
|
23
|
+
},
|
|
24
|
+
"install-failed": {
|
|
25
|
+
title: "Install failed.",
|
|
26
|
+
description: "Use the tested fallback below, then retry the primary path when you are ready.",
|
|
27
|
+
},
|
|
28
|
+
"deeplink-missing": {
|
|
29
|
+
title: "Nothing happened?",
|
|
30
|
+
description: "The app may not be installed or its link handler is unavailable. Use the command instead.",
|
|
31
|
+
},
|
|
32
|
+
"config-blocked": {
|
|
33
|
+
title: "Config write blocked.",
|
|
34
|
+
description: "That file has changes Spacefast will not overwrite. Apply the config manually instead.",
|
|
35
|
+
},
|
|
36
|
+
"oauth-denied": {
|
|
37
|
+
title: "Connection denied.",
|
|
38
|
+
description: "No access was granted. Start the sign-in flow again when you are ready.",
|
|
39
|
+
},
|
|
40
|
+
"rate-limited": {
|
|
41
|
+
title: "Too many attempts.",
|
|
42
|
+
description: "Wait before trying again. Repeated denied confirmations are rate limited.",
|
|
43
|
+
},
|
|
44
|
+
};
|
|
45
|
+
function classes(...values) {
|
|
46
|
+
return values.filter(Boolean).join(" ");
|
|
47
|
+
}
|
|
48
|
+
function initials(item) {
|
|
49
|
+
if (item.monogram)
|
|
50
|
+
return item.monogram;
|
|
51
|
+
return item.name
|
|
52
|
+
.split(/\s+/)
|
|
53
|
+
.slice(0, 2)
|
|
54
|
+
.map((part) => part[0])
|
|
55
|
+
.join("");
|
|
56
|
+
}
|
|
57
|
+
function SetupButton({ children, href, disabled, quiet, onClick, }) {
|
|
58
|
+
const className = classes("sf-setup-button", quiet && "sf-setup-button--quiet");
|
|
59
|
+
return href ? (_jsx("a", { className: className, href: href, onClick: onClick, children: children })) : (_jsx("button", { className: className, type: "button", disabled: disabled, onClick: onClick, children: children }));
|
|
60
|
+
}
|
|
61
|
+
export function AgentMark({ item, className, }) {
|
|
62
|
+
return item.iconSrc ? (_jsx("img", { src: item.iconSrc, alt: "", className: classes("sf-setup-mark", className) })) : (_jsx("span", { "aria-hidden": "true", className: classes("sf-setup-mark", className), "data-icon-fallback": "true", children: initials(item) }));
|
|
63
|
+
}
|
|
64
|
+
export function AgentAvatarGroup({ items, max = 5, className, }) {
|
|
65
|
+
const shown = items.slice(0, max);
|
|
66
|
+
const rest = items.length - shown.length;
|
|
67
|
+
return (_jsxs("span", { "aria-hidden": "true", className: classes("sf-setup-avatar-group", className), children: [shown.map((item) => (_jsx(AgentMark, { item: item }, item.name))), rest > 0 ? _jsxs("span", { className: "sf-setup-avatar-group__more", children: ["+", rest] }) : null] }));
|
|
68
|
+
}
|
|
69
|
+
function SourceLaneIcon({ id }) {
|
|
70
|
+
const Icon = id === "drop"
|
|
71
|
+
? UploadSimpleIcon
|
|
72
|
+
: id === "push"
|
|
73
|
+
? GitBranchIcon
|
|
74
|
+
: id === "github"
|
|
75
|
+
? GithubLogoIcon
|
|
76
|
+
: id === "terminal"
|
|
77
|
+
? TerminalWindowIcon
|
|
78
|
+
: id === "api"
|
|
79
|
+
? BracketsCurlyIcon
|
|
80
|
+
: ArrowRightIcon;
|
|
81
|
+
return _jsx(Icon, { "aria-hidden": true });
|
|
82
|
+
}
|
|
83
|
+
export function SourceLaneCards({ lanes, compact = false, onOpen, className, }) {
|
|
84
|
+
const headingId = useId();
|
|
85
|
+
return (_jsxs("section", { className: classes("sf-setup-source-lanes", compact && "sf-setup-source-lanes--compact", className), "aria-labelledby": headingId, children: [_jsx("h2", { id: headingId, className: "sf-setup-eyebrow", children: "Other ways to publish" }), _jsx("div", { className: "sf-setup-source-grid", children: lanes.map((lane) => (_jsxs("a", { href: lane.href, onClick: () => onOpen?.(lane), children: [_jsx(SourceLaneIcon, { id: lane.id }), _jsxs("span", { children: [_jsx("strong", { children: lane.label }), !compact ? _jsx("small", { children: lane.description }) : null] })] }, lane.id))) })] }));
|
|
86
|
+
}
|
|
87
|
+
export function SetupMethodCard({ method, primary = false, copied = false, onCopy, onOpen, }) {
|
|
88
|
+
const unavailable = method.listingStatus === "planned" || method.listingStatus === "submitted";
|
|
89
|
+
const action = unavailable ? { kind: "disabled", label: "Soon" } : method.action;
|
|
90
|
+
// A copy control always says what it does; method names live in the heading,
|
|
91
|
+
// never on the button. Links keep their destination label (“Add to Cursor”).
|
|
92
|
+
const label = action.kind === "copy"
|
|
93
|
+
? copied
|
|
94
|
+
? "Copied"
|
|
95
|
+
: "Copy"
|
|
96
|
+
: (action.label ?? (action.kind === "link" ? "Open" : "Soon"));
|
|
97
|
+
return (_jsxs("article", { className: classes("sf-setup-method", primary && "sf-setup-method--primary"), "data-listing-status": method.listingStatus, children: [_jsxs("div", { className: "sf-setup-method__head", children: [_jsxs("div", { children: [primary ? _jsx("p", { className: "sf-setup-eyebrow", children: "Recommended" }) : null, _jsx("h3", { children: method.label }), _jsx("p", { children: method.summary })] }), action.kind === "link" ? (_jsxs(SetupButton, { href: action.href, quiet: !primary, onClick: () => onOpen?.(method), children: [label, _jsx(ArrowSquareOutIcon, { "aria-hidden": true })] })) : action.kind === "copy" ? (_jsxs(SetupButton, { quiet: !primary, disabled: !onCopy, onClick: () => void onCopy?.(method), children: [copied ? _jsx(CheckIcon, { "aria-hidden": true }) : _jsx(CopyIcon, { "aria-hidden": true }), label] })) : (_jsx(SetupButton, { quiet: true, disabled: true, children: label }))] }), method.action.kind === "copy" ? (_jsxs("button", { type: "button", className: "sf-setup-method__payload", "aria-label": `Copy: ${method.label}`, disabled: !onCopy, onClick: () => void onCopy?.(method), children: [_jsx("code", { children: method.action.value }), _jsx(CopyIcon, { "aria-hidden": true })] })) : null, unavailable ? (_jsx("p", { className: "sf-setup-warning", children: method.listingStatus === "submitted"
|
|
98
|
+
? "Submitted for review — available soon."
|
|
99
|
+
: "Planned — available soon." })) : null, method.docsHref ? (_jsx("a", { className: "sf-setup-link", href: method.docsHref, children: "Docs" })) : null] }));
|
|
100
|
+
}
|
|
101
|
+
export function SetupFailureFrame({ kind, fallback, onCopy, onRetry, }) {
|
|
102
|
+
const copy = FAILURE_COPY[kind];
|
|
103
|
+
return (_jsxs("section", { role: "alert", className: "sf-setup-failure", children: [_jsxs("div", { children: [_jsx("h2", { children: copy.title }), _jsx("p", { children: copy.description })] }), fallback ? _jsx(SetupMethodCard, { method: fallback, onCopy: onCopy }) : null, onRetry ? (_jsx(SetupButton, { quiet: true, onClick: onRetry, children: "Try again" })) : null] }));
|
|
104
|
+
}
|
|
105
|
+
function TerminalRow({ method, onCopy, }) {
|
|
106
|
+
// Open but quiet: the command is the row. One line of context, the command
|
|
107
|
+
// (or the link, for downloads), a small affordance, and its own docs link —
|
|
108
|
+
// never a second card.
|
|
109
|
+
return (_jsxs("div", { className: "sf-setup-terminal-row", children: [_jsx("p", { children: method.summary }), _jsxs("div", { children: [method.action.kind === "copy" ? (_jsxs("button", { type: "button", className: "sf-setup-terminal-row__copy", "aria-label": `Copy: ${method.label}`, disabled: !onCopy, onClick: () => void onCopy?.(method), children: [_jsx("code", { children: method.action.value }), _jsx(CopyIcon, { "aria-hidden": true })] })) : null, _jsxs("span", { className: "sf-setup-terminal-row__tools", children: [method.action.kind === "link" ? (_jsxs("a", { className: "sf-setup-link", href: method.action.href, children: [method.action.label ?? (method.kind === "download" ? "Download" : "Open"), _jsx(ArrowSquareOutIcon, { "aria-hidden": true })] })) : null, method.docsHref ? (_jsx("a", { className: "sf-setup-link", href: method.docsHref, children: "docs" })) : null] })] })] }));
|
|
110
|
+
}
|
|
111
|
+
export function TerminalAlternates({ methods, onCopy, }) {
|
|
112
|
+
if (!methods.length)
|
|
113
|
+
return null;
|
|
114
|
+
const contents = methods.map((method) => (_jsx(TerminalRow, { method: method, onCopy: onCopy }, method.id)));
|
|
115
|
+
const heading = (_jsxs(_Fragment, { children: [_jsx(TerminalIcon, { "aria-hidden": true }), " Prefer the terminal?"] }));
|
|
116
|
+
return (_jsx("section", { className: "sf-setup-terminal", children: _jsxs("div", { className: "sf-setup-terminal__content", children: [_jsx("h2", { className: "sf-setup-eyebrow", children: heading }), contents] }) }));
|
|
117
|
+
}
|
|
118
|
+
export function GenericMcpLane({ endpoint, config, docsLinks = NO_DOC_LINKS, onCopy, }) {
|
|
119
|
+
const methods = [
|
|
120
|
+
{
|
|
121
|
+
id: "generic-mcp-endpoint",
|
|
122
|
+
kind: "config",
|
|
123
|
+
label: "Hosted MCP endpoint",
|
|
124
|
+
summary: "Any MCP client can connect here. OAuth completes in the browser.",
|
|
125
|
+
action: { kind: "copy", value: endpoint },
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
id: "generic-mcp-config",
|
|
129
|
+
kind: "config",
|
|
130
|
+
label: "Generic MCP config",
|
|
131
|
+
summary: "Paste this into a client that accepts an mcpServers configuration.",
|
|
132
|
+
action: { kind: "copy", value: config },
|
|
133
|
+
},
|
|
134
|
+
];
|
|
135
|
+
return (_jsxs("section", { className: "sf-setup-generic", children: [_jsxs("div", { children: [_jsx("p", { className: "sf-setup-eyebrow", children: "Generic MCP lane" }), _jsx("h2", { children: "Not listed? You do not need to be." }), _jsx("p", { children: "Any MCP client works with the hosted endpoint. Picking a logo only gives you client-specific shortcuts." })] }), methods.map((method) => (_jsx(SetupMethodCard, { method: method, onCopy: onCopy }, method.id))), docsLinks.length ? (_jsx("nav", { "aria-label": "Generic MCP help", children: docsLinks.map((link) => (_jsx("a", { className: "sf-setup-link", href: link.href, children: link.label }, link.href))) })) : null] }));
|
|
136
|
+
}
|
|
137
|
+
export function AgentPicker({ agents, onSelect, endpoint, config, docsLinks, onCopy, }) {
|
|
138
|
+
const inputId = useId();
|
|
139
|
+
const [query, setQuery] = useState("");
|
|
140
|
+
const [activeIndex, setActiveIndex] = useState(0);
|
|
141
|
+
const refs = useRef([]);
|
|
142
|
+
const visible = useMemo(() => {
|
|
143
|
+
const needle = query.trim().toLocaleLowerCase();
|
|
144
|
+
return needle
|
|
145
|
+
? agents.filter((agent) => `${agent.name} ${agent.vendor}`.toLocaleLowerCase().includes(needle))
|
|
146
|
+
: [...agents];
|
|
147
|
+
}, [agents, query]);
|
|
148
|
+
const move = (direction) => {
|
|
149
|
+
if (!visible.length)
|
|
150
|
+
return;
|
|
151
|
+
const next = (activeIndex + direction + visible.length) % visible.length;
|
|
152
|
+
setActiveIndex(next);
|
|
153
|
+
refs.current[next]?.focus();
|
|
154
|
+
};
|
|
155
|
+
return (_jsxs("div", { className: "sf-setup-picker", children: [_jsxs("section", { "aria-labelledby": "agent-picker-title", children: [_jsxs("header", { children: [_jsx("h1", { id: "agent-picker-title", children: "Pick your agent" }), _jsx("p", { children: "Type to filter. Use arrow keys to move and Enter to open." })] }), _jsxs("label", { className: "sf-setup-search", htmlFor: inputId, children: [_jsx(MagnifyingGlassIcon, { "aria-hidden": true }), _jsx("input", { id: inputId, name: "agent-search", value: query, onChange: (event) => {
|
|
156
|
+
setQuery(event.currentTarget.value);
|
|
157
|
+
setActiveIndex(0);
|
|
158
|
+
}, placeholder: "Search agents" })] }), visible.length ? (_jsx("div", { role: "listbox", "aria-label": "Agents", className: "sf-setup-picker-groups", children: [...new Set(visible.map((agent) => agent.group))].map((group) => {
|
|
159
|
+
const members = visible.filter((agent) => agent.group === group);
|
|
160
|
+
return (_jsxs("div", { className: "sf-setup-picker-group", children: [group ? _jsx("h2", { className: "sf-setup-eyebrow", children: group }) : null, _jsx("div", { className: "sf-setup-picker-grid", children: members.map((agent) => {
|
|
161
|
+
const index = visible.indexOf(agent);
|
|
162
|
+
return (_jsxs("button", { ref: (node) => {
|
|
163
|
+
refs.current[index] = node;
|
|
164
|
+
}, type: "button", role: "option", "aria-selected": index === activeIndex, onFocus: () => setActiveIndex(index), onKeyDown: (event) => {
|
|
165
|
+
if (event.key === "ArrowDown" || event.key === "ArrowRight") {
|
|
166
|
+
event.preventDefault();
|
|
167
|
+
move(1);
|
|
168
|
+
}
|
|
169
|
+
else if (event.key === "ArrowUp" || event.key === "ArrowLeft") {
|
|
170
|
+
event.preventDefault();
|
|
171
|
+
move(-1);
|
|
172
|
+
}
|
|
173
|
+
}, onClick: () => onSelect(agent), children: [_jsx(AgentMark, { item: agent, className: "sf-setup-mark--picker" }), _jsxs("span", { children: [_jsx("strong", { children: agent.name }), agent.description ? _jsx("small", { children: agent.description }) : null] }), _jsx(ArrowRightIcon, { className: "sf-setup-picker-go", "aria-hidden": true })] }, agent.id));
|
|
174
|
+
}) })] }, group ?? "all"));
|
|
175
|
+
}) })) : (_jsx("p", { role: "status", children: "No matching agent. The generic MCP lane below still works." }))] }), _jsx(GenericMcpLane, { endpoint: endpoint, config: config, docsLinks: docsLinks, onCopy: onCopy })] }));
|
|
176
|
+
}
|
|
177
|
+
export function DetectionConfirmation({ agent, onConfirm, onPickAnother, }) {
|
|
178
|
+
return (_jsxs("section", { className: "sf-setup-detection", "aria-labelledby": "detected-agent-title", children: [_jsx(AgentMark, { item: agent, className: "sf-setup-mark--large" }), _jsxs("div", { children: [_jsx("p", { className: "sf-setup-eyebrow", children: "Detected" }), _jsxs("h1", { id: "detected-agent-title", children: ["Looks like you are in ", agent.name, " \u2014 right?"] }), _jsx("p", { children: "We use this only to pick the shortest setup path. You can choose another agent instead." })] }), _jsxs("div", { className: "sf-setup-actions", children: [_jsx(SetupButton, { onClick: onConfirm, children: "Yes, continue" }), _jsx(SetupButton, { quiet: true, onClick: onPickAnother, children: "Pick another" })] })] }));
|
|
179
|
+
}
|
|
180
|
+
export function AgentSetupPage({ agent, sourceLanes, onCopy, onOpen, onBack, failure, }) {
|
|
181
|
+
const alternativesId = useId();
|
|
182
|
+
// The dock is the one-paste setup.md affordance. A prompt-primary registry
|
|
183
|
+
// entry selects that dock as the recommendation; rendering it again as a
|
|
184
|
+
// method card would offer the same action twice under two labels.
|
|
185
|
+
const primaryLivesInDock = agent.primary.kind === "prompt";
|
|
186
|
+
// The dock owns the prompt affordance; a prompt method card would repeat it.
|
|
187
|
+
const alternates = (agent.alternates ?? []).filter((method) => method.kind !== "prompt");
|
|
188
|
+
// When every method points at the same page, one page-level link beats a
|
|
189
|
+
// “Docs” tail on each card.
|
|
190
|
+
const docsHrefs = new Set([agent.primary, ...alternates, ...(agent.terminalAlternates ?? [])]
|
|
191
|
+
.map((method) => method.docsHref)
|
|
192
|
+
.filter((href) => Boolean(href)));
|
|
193
|
+
const sharedDocsHref = docsHrefs.size === 1 ? [...docsHrefs][0] : undefined;
|
|
194
|
+
const stripDocs = (method) => {
|
|
195
|
+
if (!sharedDocsHref)
|
|
196
|
+
return method;
|
|
197
|
+
const { docsHref: _shared, ...rest } = method;
|
|
198
|
+
return rest;
|
|
199
|
+
};
|
|
200
|
+
return (_jsxs("div", { className: "sf-setup-page", children: [onBack ? (_jsxs("button", { type: "button", className: "sf-setup-back", onClick: onBack, children: [_jsx(ArrowRightIcon, { "aria-hidden": true, "data-direction": "back" }), "Back to setup"] })) : null, _jsxs("header", { className: "sf-setup-page__head", children: [_jsx(AgentMark, { item: agent, className: "sf-setup-mark--large" }), _jsxs("div", { children: [_jsx("h1", { children: agent.title ?? `Connect ${agent.name}` }), _jsx("p", { children: agent.description }), sharedDocsHref ? (_jsxs("a", { className: "sf-setup-link sf-setup-page__docs", href: sharedDocsHref, children: [agent.name, " setup guide"] })) : null] })] }), failure ? (_jsx(SetupFailureFrame, { kind: failure.kind, fallback: failure.fallback, onCopy: onCopy, onRetry: failure.onRetry })) : (_jsxs("div", { className: "sf-setup-methods", children: [primaryLivesInDock ? null : (_jsx(SetupMethodCard, { method: stripDocs(agent.primary), primary: true, onCopy: onCopy, onOpen: onOpen })), alternates.length ? (_jsxs("section", { className: "sf-setup-alternatives", "aria-labelledby": alternativesId, children: [_jsxs("div", { className: "sf-setup-section-head", children: [_jsx("h2", { id: alternativesId, children: "Other ways to connect" }), _jsx("p", { children: "The recommended path above covers most setups. These are the narrower routes." })] }), _jsx("div", { className: "sf-setup-alternatives__list", children: alternates.map((method) => (_jsx(SetupMethodCard, { method: stripDocs(method), onCopy: onCopy, onOpen: onOpen }, method.id))) })] })) : null] })), _jsx(TerminalAlternates, { methods: (agent.terminalAlternates ?? []).map(stripDocs), onCopy: onCopy }), _jsx(SourceLaneCards, { lanes: sourceLanes, compact: true })] }));
|
|
201
|
+
}
|
|
202
|
+
export function AgentSetupDock({ mode, state, status, copied = false, onCopy, onRetry, }) {
|
|
203
|
+
const isFailure = state === "error";
|
|
204
|
+
const needsFresh = state === "expired" || state === "consumed" || state === "revoked";
|
|
205
|
+
const consequence = needsFresh
|
|
206
|
+
? FAILURE_COPY[state].description
|
|
207
|
+
: status === undefined
|
|
208
|
+
? DOCK_EFFECT[mode]
|
|
209
|
+
: status;
|
|
210
|
+
// After a successful copy the job is done — the dock steps back to a slim
|
|
211
|
+
// confirmation instead of keeping a full pitch on screen.
|
|
212
|
+
return (_jsx("aside", { "aria-label": "Let my agent deal with it", className: "sf-setup-dock", "data-copied": copied || undefined, children: _jsxs("div", { children: [_jsxs("div", { children: [_jsx("h2", { children: copied ? "Copied — paste it into your agent." : "Let my agent deal with it." }), copied ? null : _jsx("p", { children: consequence })] }), isFailure ? (_jsx(SetupButton, { onClick: onRetry, disabled: !onRetry, children: "Try again" })) : (_jsxs(SetupButton, { onClick: onCopy, disabled: state === "loading", children: [copied ? _jsx(CheckIcon, { "aria-hidden": true }) : _jsx(CopyIcon, { "aria-hidden": true }), state === "loading"
|
|
213
|
+
? "Preparing…"
|
|
214
|
+
: copied
|
|
215
|
+
? "Copied"
|
|
216
|
+
: needsFresh
|
|
217
|
+
? "Copy fresh prompt"
|
|
218
|
+
: "Copy prompt"] }))] }) }));
|
|
219
|
+
}
|
|
220
|
+
export function LetAgentChooseOption({ onChoose, copied = false, hotkey, }) {
|
|
221
|
+
return (_jsxs("button", { type: "button", className: "sf-setup-let-agent", onClick: onChoose, "data-copied": copied, children: [hotkey ? _jsx("kbd", { "aria-hidden": true, children: hotkey }) : _jsx(RobotIcon, { "aria-hidden": true }), _jsxs("span", { children: [_jsx("strong", { children: "Let my agent deal with it" }), _jsx("small", { children: copied
|
|
222
|
+
? "Copied — paste it into your agent and it sets itself up."
|
|
223
|
+
: "Copies one prompt. Your agent picks the path and sets itself up." })] }), copied ? _jsx(CheckIcon, { "aria-hidden": true }) : _jsx(CopyIcon, { "aria-hidden": true })] }));
|
|
224
|
+
}
|
|
225
|
+
export function AgentPageState({ kind, title, description, action, }) {
|
|
226
|
+
return (_jsxs("section", { role: kind === "loading" ? "status" : kind === "error" ? "alert" : undefined, "data-state": kind, className: "sf-setup-state", children: [_jsxs("div", { children: [_jsx("h2", { children: title }), _jsx("p", { children: description })] }), action] }));
|
|
227
|
+
}
|
|
228
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.tsx"],"names":[],"mappings":";AAAA,OAAO,EACL,cAAc,EACd,kBAAkB,EAClB,iBAAiB,EACjB,SAAS,EACT,QAAQ,EACR,aAAa,EACb,cAAc,EACd,mBAAmB,EACnB,SAAS,EACT,YAAY,EACZ,kBAAkB,EAClB,gBAAgB,GACjB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAkB,MAAM,OAAO,CAAC;AAEzE,OAAO,EAAE,q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4BACL,CAAC,CAAC,0DAA0D;4BAC5D,CAAC,CAAC,kEAAkE,GAChE,IACH,EACN,MAAM,CAAC,CAAC,CAAC,KAAC,SAAS,0BAAe,CAAC,CAAC,CAAC,KAAC,QAAQ,0BAAe,IACvD,CACV,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,cAAc,CAAC,EAC7B,IAAI,EACJ,KAAK,EACL,WAAW,EACX,MAAM,GAMP;IACC,OAAO,CACL,mBACE,IAAI,EAAE,IAAI,KAAK,SAAS,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAI,KAAK,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,SAAS,gBAChE,IAAI,EAChB,SAAS,EAAC,gBAAgB,aAE1B,0BACE,uBAAK,KAAK,GAAM,EAChB,sBAAI,WAAW,GAAK,IAChB,EACL,MAAM,IACC,CACX,CAAC;AACJ,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@spacefast/setup-ui",
|
|
3
|
+
"version": "0.2.1",
|
|
4
|
+
"license": "MIT",
|
|
5
|
+
"description": "Pure registry-driven setup UI for Spacefast agents",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "git+https://github.com/spacefast/monorepo.git",
|
|
9
|
+
"directory": "packages/setup-ui"
|
|
10
|
+
},
|
|
11
|
+
"type": "module",
|
|
12
|
+
"publishConfig": {
|
|
13
|
+
"access": "public"
|
|
14
|
+
},
|
|
15
|
+
"engines": {
|
|
16
|
+
"node": ">=20"
|
|
17
|
+
},
|
|
18
|
+
"files": [
|
|
19
|
+
"dist",
|
|
20
|
+
"src/styles.css"
|
|
21
|
+
],
|
|
22
|
+
"scripts": {
|
|
23
|
+
"build": "node scripts/clean-dist.mjs && tsc --project tsconfig.build.json && node scripts/copy-assets.mjs",
|
|
24
|
+
"prepack": "bun run build",
|
|
25
|
+
"test": "bun test ./src && bun run test:package",
|
|
26
|
+
"test:package": "bun run build && node scripts/smoke-import.mjs",
|
|
27
|
+
"typecheck": "tsc --project tsconfig.json --noEmit"
|
|
28
|
+
},
|
|
29
|
+
"exports": {
|
|
30
|
+
".": {
|
|
31
|
+
"types": "./dist/index.d.ts",
|
|
32
|
+
"import": "./dist/index.js",
|
|
33
|
+
"default": "./dist/index.js"
|
|
34
|
+
},
|
|
35
|
+
"./styles.css": "./src/styles.css"
|
|
36
|
+
},
|
|
37
|
+
"dependencies": {
|
|
38
|
+
"@phosphor-icons/react": "^2.1.10"
|
|
39
|
+
},
|
|
40
|
+
"devDependencies": {
|
|
41
|
+
"@happy-dom/global-registrator": "^20.11.1",
|
|
42
|
+
"@types/react": "^19.2.17",
|
|
43
|
+
"@types/react-dom": "^19.2.3",
|
|
44
|
+
"bun-types": "^1.3.14",
|
|
45
|
+
"react": "^19.2.8",
|
|
46
|
+
"react-dom": "^19.2.8",
|
|
47
|
+
"typescript": "^6.0.3"
|
|
48
|
+
},
|
|
49
|
+
"peerDependencies": {
|
|
50
|
+
"react": "^19.2.0",
|
|
51
|
+
"react-dom": "^19.2.0"
|
|
52
|
+
}
|
|
53
|
+
}
|