sunpeak 0.16.3 → 0.16.4
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/README.md +3 -1
- package/bin/commands/build.mjs +1 -0
- package/bin/commands/dev.mjs +2 -0
- package/dist/chatgpt/globals.css +0 -8
- package/dist/mcp/index.cjs +9 -18
- package/dist/mcp/index.cjs.map +1 -1
- package/dist/mcp/index.js +9 -18
- package/dist/mcp/index.js.map +1 -1
- package/dist/style.css +0 -8
- package/package.json +1 -1
- package/template/package.json +0 -3
- package/template/src/components/avatar.tsx +1 -1
- package/template/src/resources/albums/components/album-card.tsx +2 -2
- package/template/src/resources/albums/components/album-carousel.tsx +3 -3
- package/template/src/resources/albums/components/film-strip.tsx +2 -2
- package/template/src/resources/albums/components/fullscreen-viewer.tsx +1 -1
- package/template/src/resources/carousel/components/card.tsx +2 -2
- package/template/src/resources/carousel/components/carousel.tsx +3 -3
- package/template/src/resources/map/components/map-view.tsx +1 -1
- package/template/src/resources/map/components/map.tsx +3 -3
- package/template/src/resources/map/components/place-card.tsx +2 -2
- package/template/src/resources/map/components/place-carousel.tsx +1 -1
- package/template/src/resources/map/components/place-inspector.tsx +4 -4
- package/template/src/resources/map/components/place-list.tsx +2 -2
- package/template/src/resources/review/review.tsx +59 -29
- package/template/src/tools/review-diff.ts +3 -1
- package/template/src/tools/review-post.ts +3 -1
- package/template/src/tools/review-purchase.ts +3 -1
- package/template/src/tools/show-albums.ts +3 -1
- package/template/src/tools/show-carousel.ts +3 -1
- package/template/src/tools/show-map.ts +3 -1
- package/template/tsconfig.json +7 -2
- package/template/vitest.config.ts +1 -0
- package/template/node_modules/.bin/nodemon +0 -21
- package/template/node_modules/.bin/tsx +0 -21
package/README.md
CHANGED
|
@@ -141,7 +141,9 @@ export const schema = {
|
|
|
141
141
|
title: z.string().describe('Title describing the changes'),
|
|
142
142
|
};
|
|
143
143
|
|
|
144
|
-
|
|
144
|
+
type Args = z.infer<z.ZodObject<typeof schema>>;
|
|
145
|
+
|
|
146
|
+
export default async function (args: Args, extra: ToolHandlerExtra) {
|
|
145
147
|
return { structuredContent: { title: args.title, sections: [] } };
|
|
146
148
|
}
|
|
147
149
|
```
|
package/bin/commands/build.mjs
CHANGED
|
@@ -241,6 +241,7 @@ export async function build(projectRoot = process.cwd()) {
|
|
|
241
241
|
resolve: {
|
|
242
242
|
conditions: ['style', 'import', 'module', 'browser', 'default'],
|
|
243
243
|
alias: {
|
|
244
|
+
'@': path.resolve(projectRoot, 'src'),
|
|
244
245
|
// In workspace dev mode, use local sunpeak source
|
|
245
246
|
...(isTemplate && {
|
|
246
247
|
sunpeak: parentSrc,
|
package/bin/commands/dev.mjs
CHANGED
|
@@ -201,6 +201,7 @@ export async function dev(projectRoot = process.cwd(), args = []) {
|
|
|
201
201
|
plugins: [react(), tailwindcss(), sunpeakFaviconPlugin()],
|
|
202
202
|
resolve: {
|
|
203
203
|
alias: {
|
|
204
|
+
'@': path.resolve(projectRoot, 'src'),
|
|
204
205
|
// In workspace dev mode, use local sunpeak source
|
|
205
206
|
...(isTemplate && {
|
|
206
207
|
sunpeak: parentSrc,
|
|
@@ -354,6 +355,7 @@ if (import.meta.hot) {
|
|
|
354
355
|
plugins: [react(), tailwindcss(), sunpeakEntryPlugin()],
|
|
355
356
|
resolve: {
|
|
356
357
|
alias: {
|
|
358
|
+
'@': path.resolve(projectRoot, 'src'),
|
|
357
359
|
...(isTemplate && {
|
|
358
360
|
sunpeak: parentSrc,
|
|
359
361
|
}),
|
package/dist/chatgpt/globals.css
CHANGED
|
@@ -1368,10 +1368,6 @@
|
|
|
1368
1368
|
background-color: #0000;
|
|
1369
1369
|
}
|
|
1370
1370
|
|
|
1371
|
-
.bg-white {
|
|
1372
|
-
background-color: var(--color-white);
|
|
1373
|
-
}
|
|
1374
|
-
|
|
1375
1371
|
.bg-gradient-to-l {
|
|
1376
1372
|
--tw-gradient-position: to left in oklab;
|
|
1377
1373
|
background-image: linear-gradient(var(--tw-gradient-stops));
|
|
@@ -1672,10 +1668,6 @@
|
|
|
1672
1668
|
white-space: pre-wrap;
|
|
1673
1669
|
}
|
|
1674
1670
|
|
|
1675
|
-
.text-\[\#000000\] {
|
|
1676
|
-
color: #000;
|
|
1677
|
-
}
|
|
1678
|
-
|
|
1679
1671
|
.text-\[var\(--color-text-danger\)\] {
|
|
1680
1672
|
color: var(--color-text-danger);
|
|
1681
1673
|
}
|
package/dist/mcp/index.cjs
CHANGED
|
@@ -15626,10 +15626,8 @@ const cleanupInterval = setInterval(() => {
|
|
|
15626
15626
|
const now = Date.now();
|
|
15627
15627
|
for (const [id2, session] of sessions) {
|
|
15628
15628
|
if (now - session.lastActivity > SESSION_IDLE_TIMEOUT_MS$1) {
|
|
15629
|
-
|
|
15630
|
-
session.
|
|
15631
|
-
session.server.close();
|
|
15632
|
-
console.log(`[MCP] Session expired: ${id2.substring(0, 8)}... (${sessions.size} active)`);
|
|
15629
|
+
console.log(`[MCP] Session expired: ${id2.substring(0, 8)}...`);
|
|
15630
|
+
void session.server.close();
|
|
15633
15631
|
}
|
|
15634
15632
|
}
|
|
15635
15633
|
}, 6e4);
|
|
@@ -15695,13 +15693,12 @@ async function handleMcpRequest(req, res, config, simulations, viteMode) {
|
|
|
15695
15693
|
const id2 = transport.sessionId;
|
|
15696
15694
|
console.error(`[MCP] Transport error${id2 ? ` (${id2.substring(0, 8)}...)` : ""}:`, error);
|
|
15697
15695
|
};
|
|
15698
|
-
transport.onclose =
|
|
15696
|
+
transport.onclose = () => {
|
|
15699
15697
|
const id2 = transport.sessionId;
|
|
15700
15698
|
if (id2 && sessions.has(id2)) {
|
|
15701
15699
|
sessions.delete(id2);
|
|
15702
15700
|
console.log(`[MCP] Session closed: ${id2.substring(0, 8)}... (${sessions.size} active)`);
|
|
15703
15701
|
}
|
|
15704
|
-
await server.close();
|
|
15705
15702
|
};
|
|
15706
15703
|
await server.connect(transport);
|
|
15707
15704
|
await transport.handleRequest(req, res, parsedBody);
|
|
@@ -15916,10 +15913,8 @@ function createMcpHandler(config) {
|
|
|
15916
15913
|
const now = Date.now();
|
|
15917
15914
|
for (const [id2, session] of sessions2) {
|
|
15918
15915
|
if (now - session.lastActivity > SESSION_IDLE_TIMEOUT_MS) {
|
|
15919
|
-
|
|
15920
|
-
session.
|
|
15921
|
-
session.server.close();
|
|
15922
|
-
console.log(`[MCP] Session expired: ${id2.substring(0, 8)}... (${sessions2.size} active)`);
|
|
15916
|
+
console.log(`[MCP] Session expired: ${id2.substring(0, 8)}...`);
|
|
15917
|
+
void session.server.close();
|
|
15923
15918
|
}
|
|
15924
15919
|
}
|
|
15925
15920
|
}, 6e4);
|
|
@@ -15997,13 +15992,12 @@ function createMcpHandler(config) {
|
|
|
15997
15992
|
const id2 = transport.sessionId;
|
|
15998
15993
|
console.error(`[MCP] Transport error${id2 ? ` (${id2.substring(0, 8)}...)` : ""}:`, error);
|
|
15999
15994
|
};
|
|
16000
|
-
transport.onclose =
|
|
15995
|
+
transport.onclose = () => {
|
|
16001
15996
|
const id2 = transport.sessionId;
|
|
16002
15997
|
if (id2 && sessions2.has(id2)) {
|
|
16003
15998
|
sessions2.delete(id2);
|
|
16004
15999
|
console.log(`[MCP] Session closed: ${id2.substring(0, 8)}... (${sessions2.size} active)`);
|
|
16005
16000
|
}
|
|
16006
|
-
await server.close();
|
|
16007
16001
|
};
|
|
16008
16002
|
await server.connect(transport);
|
|
16009
16003
|
await transport.handleRequest(req, res, parsedBody);
|
|
@@ -16019,10 +16013,8 @@ function createHandler(config) {
|
|
|
16019
16013
|
const now = Date.now();
|
|
16020
16014
|
for (const [id2, session] of sessions2) {
|
|
16021
16015
|
if (now - session.lastActivity > SESSION_IDLE_TIMEOUT_MS) {
|
|
16022
|
-
|
|
16023
|
-
session.
|
|
16024
|
-
session.server.close();
|
|
16025
|
-
console.log(`[MCP] Session expired: ${id2.substring(0, 8)}... (${sessions2.size} active)`);
|
|
16016
|
+
console.log(`[MCP] Session expired: ${id2.substring(0, 8)}...`);
|
|
16017
|
+
void session.server.close();
|
|
16026
16018
|
}
|
|
16027
16019
|
}
|
|
16028
16020
|
}, 6e4);
|
|
@@ -16077,12 +16069,11 @@ function createHandler(config) {
|
|
|
16077
16069
|
transport.onerror = (error) => {
|
|
16078
16070
|
console.error("[MCP] Transport error:", error);
|
|
16079
16071
|
};
|
|
16080
|
-
transport.onclose =
|
|
16072
|
+
transport.onclose = () => {
|
|
16081
16073
|
const id2 = transport.sessionId;
|
|
16082
16074
|
if (id2 && sessions2.has(id2)) {
|
|
16083
16075
|
sessions2.delete(id2);
|
|
16084
16076
|
}
|
|
16085
|
-
await server.close();
|
|
16086
16077
|
};
|
|
16087
16078
|
await server.connect(transport);
|
|
16088
16079
|
const response = await transport.handleRequest(req, { parsedBody, authInfo });
|