create-skybridge 0.0.0-dev.cb507f1 → 0.0.0-dev.cb51733
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/index.js +315 -214
- package/package.json +5 -5
- package/templates/blank/.dockerignore +4 -0
- package/templates/blank/Dockerfile +53 -0
- package/templates/blank/README.md +92 -0
- package/{template → templates/blank}/_gitignore +4 -1
- package/templates/blank/package.json +28 -0
- package/templates/blank/src/server.ts +21 -0
- package/templates/blank/src/vite-manifest.d.ts +4 -0
- package/templates/blank/tsconfig.json +5 -0
- package/templates/blank/vite.config.ts +6 -0
- package/templates/demo/.dockerignore +4 -0
- package/templates/demo/AGENTS.md +1 -0
- package/templates/demo/Dockerfile +53 -0
- package/{template → templates/demo}/README.md +16 -15
- package/templates/demo/_gitignore +9 -0
- package/templates/demo/alpic.json +3 -0
- package/templates/demo/node_modules/.bin/alpic +21 -0
- package/templates/demo/node_modules/.bin/sb +21 -0
- package/templates/demo/node_modules/.bin/skybridge +21 -0
- package/templates/demo/node_modules/.bin/tsc +21 -0
- package/templates/demo/node_modules/.bin/tsserver +21 -0
- package/templates/demo/node_modules/.bin/vite +21 -0
- package/{template → templates/demo}/package.json +8 -2
- package/templates/demo/src/helpers.ts +4 -0
- package/templates/demo/src/index.css +59 -0
- package/templates/demo/src/server.ts +99 -0
- package/templates/demo/src/views/components/doc-link.tsx +22 -0
- package/templates/demo/src/views/components/doc.tsx +21 -0
- package/templates/demo/src/views/components/nav.tsx +31 -0
- package/templates/demo/src/views/components/progress.tsx +35 -0
- package/templates/demo/src/views/components/steps/outro.tsx +68 -0
- package/templates/demo/src/views/components/steps/state.tsx +47 -0
- package/templates/demo/src/views/components/steps/tool-call.tsx +53 -0
- package/templates/demo/src/views/components/steps/tool-output.tsx +40 -0
- package/templates/demo/src/views/images/mascot/beret.png +0 -0
- package/templates/demo/src/views/images/mascot/chapka.png +0 -0
- package/templates/demo/src/views/images/mascot/cowboy-hat.png +0 -0
- package/templates/demo/src/views/images/mascot/fez.png +0 -0
- package/templates/demo/src/views/images/mascot/jester-hat.png +0 -0
- package/templates/demo/src/views/images/mascot/mitre.png +0 -0
- package/templates/demo/src/views/images/mascot/non-la.png +0 -0
- package/templates/demo/src/views/images/mascot/original.png +0 -0
- package/templates/demo/src/views/images/mascot/propeller-beanie.png +0 -0
- package/templates/demo/src/views/images/mascot/ski-mask.png +0 -0
- package/templates/demo/src/views/images/mascot/sombrero.png +0 -0
- package/templates/demo/src/views/images/mascot/top-hat.png +0 -0
- package/templates/demo/src/views/images/mascot/viking-helmet.png +0 -0
- package/templates/demo/src/views/onboarding.tsx +63 -0
- package/templates/demo/src/views/use-mascot.ts +60 -0
- package/templates/demo/src/vite-manifest.d.ts +4 -0
- package/{template → templates/demo}/vite.config.ts +3 -2
- package/dist/index.test.d.ts +0 -1
- package/dist/index.test.js +0 -33
- package/template/src/components/ball.tsx +0 -22
- package/template/src/index.css +0 -152
- package/template/src/server.ts +0 -61
- package/template/src/views/magic-8-ball.tsx +0 -10
- /package/{template → templates/blank}/AGENTS.md +0 -0
- /package/{template → templates/blank}/alpic.json +0 -0
- /package/{template → templates/blank}/node_modules/.bin/alpic +0 -0
- /package/{template → templates/blank}/node_modules/.bin/sb +0 -0
- /package/{template → templates/blank}/node_modules/.bin/skybridge +0 -0
- /package/{template → templates/blank}/node_modules/.bin/tsc +0 -0
- /package/{template → templates/blank}/node_modules/.bin/tsserver +0 -0
- /package/{template → templates/blank}/node_modules/.bin/vite +0 -0
- /package/{template → templates/blank}/src/helpers.ts +0 -0
- /package/{template → templates/demo}/node_modules/.bin/tsx +0 -0
- /package/{template → templates/demo}/tsconfig.json +0 -0
package/template/src/index.css
DELETED
|
@@ -1,152 +0,0 @@
|
|
|
1
|
-
@import url("https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@1,600&display=swap");
|
|
2
|
-
|
|
3
|
-
.container {
|
|
4
|
-
display: flex;
|
|
5
|
-
justify-content: center;
|
|
6
|
-
align-items: center;
|
|
7
|
-
min-height: 100%;
|
|
8
|
-
padding: 1rem;
|
|
9
|
-
box-sizing: border-box;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.ball {
|
|
13
|
-
background: radial-gradient(
|
|
14
|
-
circle at 30% 30%,
|
|
15
|
-
#454565 0%,
|
|
16
|
-
#1c1c30 40%,
|
|
17
|
-
#0a0a10 100%
|
|
18
|
-
);
|
|
19
|
-
border-radius: 50%;
|
|
20
|
-
width: 12rem;
|
|
21
|
-
height: 12rem;
|
|
22
|
-
display: flex;
|
|
23
|
-
flex-direction: column;
|
|
24
|
-
align-items: center;
|
|
25
|
-
justify-content: center;
|
|
26
|
-
font-family: monospace;
|
|
27
|
-
text-align: center;
|
|
28
|
-
position: relative;
|
|
29
|
-
box-shadow:
|
|
30
|
-
0 10px 30px rgba(0, 0, 0, 0.5),
|
|
31
|
-
0 5px 15px rgba(0, 0, 0, 0.3),
|
|
32
|
-
inset 0 -20px 40px rgba(0, 0, 0, 0.6);
|
|
33
|
-
animation:
|
|
34
|
-
float 3s ease-in-out infinite,
|
|
35
|
-
colorShift 15s ease-in-out infinite;
|
|
36
|
-
transition: transform 0.3s ease;
|
|
37
|
-
cursor: pointer;
|
|
38
|
-
border: 1px solid rgba(30, 30, 50, 0.6);
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
.ball:hover {
|
|
42
|
-
transform: scale(1.05) translateY(-8px);
|
|
43
|
-
animation: colorShift 15s ease-in-out infinite;
|
|
44
|
-
box-shadow:
|
|
45
|
-
0 20px 50px rgba(0, 0, 0, 0.6),
|
|
46
|
-
0 10px 25px rgba(0, 0, 0, 0.4),
|
|
47
|
-
inset 0 -20px 40px rgba(0, 0, 0, 0.6);
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
@keyframes float {
|
|
51
|
-
0%,
|
|
52
|
-
100% {
|
|
53
|
-
transform: translateY(0);
|
|
54
|
-
}
|
|
55
|
-
50% {
|
|
56
|
-
transform: translateY(-8px);
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
@keyframes colorShift {
|
|
61
|
-
0%,
|
|
62
|
-
100% {
|
|
63
|
-
background: radial-gradient(
|
|
64
|
-
circle at 30% 30%,
|
|
65
|
-
#454565 0%,
|
|
66
|
-
#1c1c30 40%,
|
|
67
|
-
#0a0a10 100%
|
|
68
|
-
);
|
|
69
|
-
}
|
|
70
|
-
25% {
|
|
71
|
-
background: radial-gradient(
|
|
72
|
-
circle at 30% 30%,
|
|
73
|
-
#3f4a65 0%,
|
|
74
|
-
#181e30 40%,
|
|
75
|
-
#090a10 100%
|
|
76
|
-
);
|
|
77
|
-
}
|
|
78
|
-
50% {
|
|
79
|
-
background: radial-gradient(
|
|
80
|
-
circle at 30% 30%,
|
|
81
|
-
#3a5065 0%,
|
|
82
|
-
#152230 40%,
|
|
83
|
-
#080a10 100%
|
|
84
|
-
);
|
|
85
|
-
}
|
|
86
|
-
75% {
|
|
87
|
-
background: radial-gradient(
|
|
88
|
-
circle at 30% 30%,
|
|
89
|
-
#3f4a65 0%,
|
|
90
|
-
#181e30 40%,
|
|
91
|
-
#090a10 100%
|
|
92
|
-
);
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
.ball::before {
|
|
97
|
-
content: "";
|
|
98
|
-
position: absolute;
|
|
99
|
-
top: 8%;
|
|
100
|
-
left: 20%;
|
|
101
|
-
width: 30%;
|
|
102
|
-
height: 20%;
|
|
103
|
-
background: radial-gradient(
|
|
104
|
-
ellipse,
|
|
105
|
-
rgba(255, 255, 255, 0.3) 0%,
|
|
106
|
-
transparent 70%
|
|
107
|
-
);
|
|
108
|
-
border-radius: 50%;
|
|
109
|
-
pointer-events: none;
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
.ball::after {
|
|
113
|
-
content: "";
|
|
114
|
-
position: absolute;
|
|
115
|
-
bottom: 8%;
|
|
116
|
-
right: 25%;
|
|
117
|
-
width: 25%;
|
|
118
|
-
height: 10%;
|
|
119
|
-
background: radial-gradient(
|
|
120
|
-
ellipse,
|
|
121
|
-
rgba(255, 255, 255, 0.1) 0%,
|
|
122
|
-
transparent 70%
|
|
123
|
-
);
|
|
124
|
-
border-radius: 50%;
|
|
125
|
-
pointer-events: none;
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
.question {
|
|
129
|
-
font-size: clamp(0.5rem, 2vw, 0.75rem);
|
|
130
|
-
color: lightgrey;
|
|
131
|
-
max-width: 90%;
|
|
132
|
-
word-wrap: break-word;
|
|
133
|
-
overflow-wrap: break-word;
|
|
134
|
-
text-align: center;
|
|
135
|
-
line-height: 1.3;
|
|
136
|
-
font-style: italic;
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
.answer {
|
|
140
|
-
font-family: "Playfair Display", serif;
|
|
141
|
-
font-style: italic;
|
|
142
|
-
font-size: 1.25rem;
|
|
143
|
-
font-weight: 600;
|
|
144
|
-
margin-top: 0.5rem;
|
|
145
|
-
color: #7dd3fc;
|
|
146
|
-
text-shadow: 0 0 10px rgba(125, 211, 252, 0.5);
|
|
147
|
-
max-width: 90%;
|
|
148
|
-
word-wrap: break-word;
|
|
149
|
-
overflow-wrap: break-word;
|
|
150
|
-
text-align: center;
|
|
151
|
-
line-height: 1.3;
|
|
152
|
-
}
|
package/template/src/server.ts
DELETED
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
import { McpServer } from "skybridge/server";
|
|
2
|
-
import { z } from "zod";
|
|
3
|
-
|
|
4
|
-
const Answers = [
|
|
5
|
-
"As I see it, yes",
|
|
6
|
-
"Don't count on it",
|
|
7
|
-
"It is certain",
|
|
8
|
-
"It is decidedly so",
|
|
9
|
-
"Most likely",
|
|
10
|
-
"My reply is no",
|
|
11
|
-
"My sources say no",
|
|
12
|
-
"Outlook good",
|
|
13
|
-
"Outlook not so good",
|
|
14
|
-
"Signs point to yes",
|
|
15
|
-
"Very doubtful",
|
|
16
|
-
"Without a doubt",
|
|
17
|
-
"Yes definitely",
|
|
18
|
-
"Yes",
|
|
19
|
-
"You may rely on it",
|
|
20
|
-
];
|
|
21
|
-
|
|
22
|
-
const server = new McpServer(
|
|
23
|
-
{
|
|
24
|
-
name: "alpic-openai-app",
|
|
25
|
-
version: "0.0.1",
|
|
26
|
-
},
|
|
27
|
-
{ capabilities: {} },
|
|
28
|
-
).registerTool(
|
|
29
|
-
{
|
|
30
|
-
name: "magic-8-ball",
|
|
31
|
-
description: "For fortune-telling or seeking advice.",
|
|
32
|
-
inputSchema: {
|
|
33
|
-
question: z.string().describe("The user question."),
|
|
34
|
-
},
|
|
35
|
-
view: {
|
|
36
|
-
component: "magic-8-ball",
|
|
37
|
-
description: "Magic 8 Ball",
|
|
38
|
-
},
|
|
39
|
-
},
|
|
40
|
-
async ({ question }) => {
|
|
41
|
-
try {
|
|
42
|
-
const hash = question
|
|
43
|
-
.split("")
|
|
44
|
-
.reduce((acc, char) => acc + char.charCodeAt(0), 0);
|
|
45
|
-
const answer = Answers[hash % Answers.length];
|
|
46
|
-
return {
|
|
47
|
-
structuredContent: { answer },
|
|
48
|
-
isError: false,
|
|
49
|
-
};
|
|
50
|
-
} catch (error) {
|
|
51
|
-
return {
|
|
52
|
-
content: [{ type: "text", text: `Error: ${error}` }],
|
|
53
|
-
isError: true,
|
|
54
|
-
};
|
|
55
|
-
}
|
|
56
|
-
},
|
|
57
|
-
);
|
|
58
|
-
|
|
59
|
-
server.run();
|
|
60
|
-
|
|
61
|
-
export type AppType = typeof server;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import "@/index.css";
|
|
2
|
-
|
|
3
|
-
import { Ball } from "../components/ball.js";
|
|
4
|
-
import { useToolInfo } from "../helpers.js";
|
|
5
|
-
|
|
6
|
-
export default function Magic8Ball() {
|
|
7
|
-
const { input, output } = useToolInfo<"magic-8-ball">();
|
|
8
|
-
|
|
9
|
-
return <Ball question={input?.question} answer={output?.answer} />;
|
|
10
|
-
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|