sunpeak 0.16.28 → 0.17.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 (141) hide show
  1. package/bin/commands/dev.mjs +169 -342
  2. package/bin/commands/inspect.mjs +763 -0
  3. package/bin/commands/new.mjs +2 -2
  4. package/bin/lib/inspect/inspect-config.d.mts +20 -0
  5. package/bin/lib/inspect/inspect-config.mjs +76 -0
  6. package/bin/lib/live/global-setup.mjs +6 -1
  7. package/bin/sunpeak.js +11 -1
  8. package/dist/chatgpt/globals.css +35 -18
  9. package/dist/chatgpt/index.cjs +3 -11
  10. package/dist/chatgpt/index.cjs.map +1 -1
  11. package/dist/chatgpt/index.d.ts +2 -2
  12. package/dist/chatgpt/index.js +4 -8
  13. package/dist/chatgpt/index.js.map +1 -1
  14. package/dist/claude/index.cjs +1 -1
  15. package/dist/claude/index.js +1 -1
  16. package/dist/discovery-Cgoegt62.js +114 -0
  17. package/dist/discovery-Cgoegt62.js.map +1 -0
  18. package/dist/discovery-Clu4uHp1.cjs +161 -0
  19. package/dist/discovery-Clu4uHp1.cjs.map +1 -0
  20. package/dist/index.cjs +1 -4
  21. package/dist/index.cjs.map +1 -1
  22. package/dist/index.js +2 -3
  23. package/dist/index.js.map +1 -1
  24. package/dist/lib/discovery-cli.cjs +1 -1
  25. package/dist/lib/discovery-cli.js +1 -1
  26. package/dist/lib/discovery.d.ts +7 -67
  27. package/dist/lib/index.d.ts +0 -1
  28. package/dist/mcp/index.cjs +34 -23
  29. package/dist/mcp/index.cjs.map +1 -1
  30. package/dist/mcp/index.js +34 -23
  31. package/dist/mcp/index.js.map +1 -1
  32. package/dist/mcp/types.d.ts +5 -0
  33. package/dist/simulator/index.cjs +5 -11
  34. package/dist/simulator/index.cjs.map +1 -1
  35. package/dist/simulator/index.d.ts +4 -2
  36. package/dist/simulator/index.js +5 -8
  37. package/dist/simulator/index.js.map +1 -1
  38. package/dist/simulator/simple-sidebar.d.ts +7 -4
  39. package/dist/simulator/simulator-url.d.ts +8 -0
  40. package/dist/simulator/simulator.d.ts +15 -2
  41. package/dist/simulator/use-mcp-connection.d.ts +19 -0
  42. package/dist/{simulator-BYIH-xqQ.cjs → simulator-CH9hs0N6.cjs} +159 -52
  43. package/dist/simulator-CH9hs0N6.cjs.map +1 -0
  44. package/dist/{simulator-CmgNnWBO.js → simulator-Dl8B-Ljb.js} +154 -53
  45. package/dist/simulator-Dl8B-Ljb.js.map +1 -0
  46. package/dist/{simulator-url-BDGD4vZD.cjs → simulator-url-CozKF1jf.cjs} +3 -1
  47. package/dist/simulator-url-CozKF1jf.cjs.map +1 -0
  48. package/dist/{simulator-url-Bkxj43yT.js → simulator-url-KoS_ToP6.js} +3 -1
  49. package/dist/simulator-url-KoS_ToP6.js.map +1 -0
  50. package/dist/style.css +35 -18
  51. package/package.json +9 -1
  52. package/template/dist/albums/albums.html +105 -0
  53. package/template/dist/albums/albums.json +16 -0
  54. package/template/dist/carousel/carousel.html +105 -0
  55. package/template/dist/carousel/carousel.json +16 -0
  56. package/template/dist/map/map.html +3060 -0
  57. package/template/dist/map/map.json +22 -0
  58. package/template/dist/review/review.html +105 -0
  59. package/template/dist/review/review.json +16 -0
  60. package/template/dist/server.js +15 -0
  61. package/template/dist/tools/review-diff.js +50 -0
  62. package/template/dist/tools/review-post.js +50 -0
  63. package/template/dist/tools/review-purchase.js +61 -0
  64. package/template/dist/tools/review.js +31 -0
  65. package/template/dist/tools/show-albums.js +56 -0
  66. package/template/dist/tools/show-carousel.js +41 -0
  67. package/template/dist/tools/show-map.js +47 -0
  68. package/template/node_modules/.vite/deps/_metadata.json +8 -0
  69. package/template/node_modules/.vite/deps/package.json +3 -0
  70. package/template/node_modules/.vite-mcp/deps/@modelcontextprotocol_ext-apps.js +500 -0
  71. package/template/node_modules/.vite-mcp/deps/@modelcontextprotocol_ext-apps.js.map +1 -0
  72. package/template/node_modules/.vite-mcp/deps/@modelcontextprotocol_ext-apps_app-bridge.js +563 -0
  73. package/template/node_modules/.vite-mcp/deps/@modelcontextprotocol_ext-apps_app-bridge.js.map +1 -0
  74. package/template/node_modules/.vite-mcp/deps/@modelcontextprotocol_ext-apps_react.js +575 -0
  75. package/template/node_modules/.vite-mcp/deps/@modelcontextprotocol_ext-apps_react.js.map +1 -0
  76. package/template/node_modules/.vite-mcp/deps/@testing-library_react.js +11363 -0
  77. package/template/node_modules/.vite-mcp/deps/@testing-library_react.js.map +1 -0
  78. package/template/node_modules/.vite-mcp/deps/_metadata.json +130 -0
  79. package/template/node_modules/.vite-mcp/deps/chunk-BoAXSpZd.js +33 -0
  80. package/template/node_modules/.vite-mcp/deps/client-CU1wWud4.js +14385 -0
  81. package/template/node_modules/.vite-mcp/deps/client-CU1wWud4.js.map +1 -0
  82. package/template/node_modules/.vite-mcp/deps/clsx.js +18 -0
  83. package/template/node_modules/.vite-mcp/deps/clsx.js.map +1 -0
  84. package/template/node_modules/.vite-mcp/deps/dist-uWX8WbjY.js +505 -0
  85. package/template/node_modules/.vite-mcp/deps/dist-uWX8WbjY.js.map +1 -0
  86. package/template/node_modules/.vite-mcp/deps/embla-carousel-react.js +1461 -0
  87. package/template/node_modules/.vite-mcp/deps/embla-carousel-react.js.map +1 -0
  88. package/template/node_modules/.vite-mcp/deps/embla-carousel-wheel-gestures.js +536 -0
  89. package/template/node_modules/.vite-mcp/deps/embla-carousel-wheel-gestures.js.map +1 -0
  90. package/template/node_modules/.vite-mcp/deps/magic-string.es-Cklsmr-5.js +1013 -0
  91. package/template/node_modules/.vite-mcp/deps/magic-string.es-Cklsmr-5.js.map +1 -0
  92. package/template/node_modules/.vite-mcp/deps/mapbox-gl.js +46311 -0
  93. package/template/node_modules/.vite-mcp/deps/mapbox-gl.js.map +1 -0
  94. package/template/node_modules/.vite-mcp/deps/package.json +3 -0
  95. package/template/node_modules/.vite-mcp/deps/protocol-CTflwIfG.js +2090 -0
  96. package/template/node_modules/.vite-mcp/deps/protocol-CTflwIfG.js.map +1 -0
  97. package/template/node_modules/.vite-mcp/deps/react-dom.js +186 -0
  98. package/template/node_modules/.vite-mcp/deps/react-dom.js.map +1 -0
  99. package/template/node_modules/.vite-mcp/deps/react-dom_client.js +2 -0
  100. package/template/node_modules/.vite-mcp/deps/react.js +769 -0
  101. package/template/node_modules/.vite-mcp/deps/react.js.map +1 -0
  102. package/template/node_modules/.vite-mcp/deps/react_jsx-dev-runtime.js +205 -0
  103. package/template/node_modules/.vite-mcp/deps/react_jsx-dev-runtime.js.map +1 -0
  104. package/template/node_modules/.vite-mcp/deps/react_jsx-runtime.js +209 -0
  105. package/template/node_modules/.vite-mcp/deps/react_jsx-runtime.js.map +1 -0
  106. package/template/node_modules/.vite-mcp/deps/schemas-NsgmY9QV.js +12157 -0
  107. package/template/node_modules/.vite-mcp/deps/schemas-NsgmY9QV.js.map +1 -0
  108. package/template/node_modules/.vite-mcp/deps/tailwind-merge.js +2025 -0
  109. package/template/node_modules/.vite-mcp/deps/tailwind-merge.js.map +1 -0
  110. package/template/node_modules/.vite-mcp/deps/vitest.js +14021 -0
  111. package/template/node_modules/.vite-mcp/deps/vitest.js.map +1 -0
  112. package/template/node_modules/.vite-mcp/deps/zod.js +624 -0
  113. package/template/node_modules/.vite-mcp/deps/zod.js.map +1 -0
  114. package/template/src/tools/review-diff.test.ts +5 -1
  115. package/template/src/tools/review-diff.ts +1 -1
  116. package/template/src/tools/review-post.test.ts +5 -1
  117. package/template/src/tools/review-post.ts +1 -1
  118. package/template/src/tools/review-purchase.test.ts +5 -1
  119. package/template/src/tools/review-purchase.ts +1 -1
  120. package/template/src/tools/review.test.ts +5 -1
  121. package/template/src/tools/review.ts +1 -1
  122. package/template/src/tools/show-albums.test.ts +5 -1
  123. package/template/src/tools/show-albums.ts +1 -1
  124. package/template/src/tools/show-carousel.test.ts +5 -1
  125. package/template/src/tools/show-carousel.ts +1 -1
  126. package/template/src/tools/show-map.test.ts +5 -1
  127. package/template/src/tools/show-map.ts +1 -1
  128. package/template/tests/e2e/map.spec.ts +4 -2
  129. package/dist/discovery-BxKCIgG5.cjs +0 -332
  130. package/dist/discovery-BxKCIgG5.cjs.map +0 -1
  131. package/dist/discovery-Du4LHrih.js +0 -261
  132. package/dist/discovery-Du4LHrih.js.map +0 -1
  133. package/dist/simulator-BYIH-xqQ.cjs.map +0 -1
  134. package/dist/simulator-CmgNnWBO.js.map +0 -1
  135. package/dist/simulator-url-BDGD4vZD.cjs.map +0 -1
  136. package/dist/simulator-url-Bkxj43yT.js.map +0 -1
  137. package/template/.sunpeak/dev.tsx +0 -79
  138. package/template/.sunpeak/resource-loader.html +0 -20
  139. package/template/.sunpeak/resource-loader.tsx +0 -57
  140. package/template/index.html +0 -14
  141. package/template/src/resources/index.ts +0 -17
@@ -55,6 +55,8 @@ function createSimulatorUrl(params, basePath = "/") {
55
55
  if (params.safeAreaRight !== void 0) searchParams.set("safeAreaRight", String(params.safeAreaRight));
56
56
  if (params.prodTools !== void 0) searchParams.set("prodTools", String(params.prodTools));
57
57
  if (params.prodResources !== void 0) searchParams.set("prodResources", String(params.prodResources));
58
+ if (params.serverUrl !== void 0) searchParams.set("serverUrl", params.serverUrl);
59
+ if (params.tool !== void 0) searchParams.set("tool", params.tool);
58
60
  const queryString = searchParams.toString();
59
61
  return queryString ? `${basePath}?${queryString}` : basePath;
60
62
  }
@@ -66,4 +68,4 @@ Object.defineProperty(exports, "createSimulatorUrl", {
66
68
  }
67
69
  });
68
70
 
69
- //# sourceMappingURL=simulator-url-BDGD4vZD.cjs.map
71
+ //# sourceMappingURL=simulator-url-CozKF1jf.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"simulator-url-CozKF1jf.cjs","names":[],"sources":["../src/simulator/simulator-url.ts"],"sourcesContent":["import type { Theme, DisplayMode, DeviceType } from '../types/runtime';\n\n/**\n * Strongly-typed URL parameters for the Simulator.\n *\n * Use with `createSimulatorUrl()` to generate type-safe URL paths for e2e tests.\n *\n * @example\n * ```ts\n * import { createSimulatorUrl } from 'sunpeak/chatgpt';\n *\n * // In e2e tests:\n * await page.goto(createSimulatorUrl({\n * simulation: 'show-albums',\n * theme: 'dark',\n * displayMode: 'fullscreen',\n * host: 'claude',\n * }));\n * ```\n */\nexport interface SimulatorUrlParams {\n /**\n * The simulation name to load (e.g., 'show-albums', 'review-diff').\n * Corresponds to the simulation JSON filename without the `.json` extension.\n */\n simulation?: string;\n\n /**\n * The host shell to use (e.g., 'chatgpt', 'claude').\n * Switches conversation chrome, theming, and reported host info/capabilities.\n * @default 'chatgpt'\n */\n host?: string;\n\n /**\n * The color theme for the simulator.\n * @default 'dark'\n */\n theme?: Theme;\n\n /**\n * The display mode for the widget.\n * - 'inline': Embedded in the conversation\n * - 'pip': Picture-in-picture mode with max height\n * - 'fullscreen': Full screen overlay\n * @default 'inline'\n */\n displayMode?: DisplayMode;\n\n /**\n * The locale for the simulator (e.g., 'en-US', 'ja-JP').\n * @default 'en-US'\n */\n locale?: string;\n\n /**\n * Maximum height in pixels for PiP mode.\n * Only applicable when displayMode is 'pip'.\n */\n maxHeight?: number;\n\n /**\n * The device type to simulate.\n * Affects default hover/touch capabilities.\n */\n deviceType?: DeviceType;\n\n /**\n * Whether the device supports hover interactions.\n * @default true for desktop, false for mobile/tablet\n */\n hover?: boolean;\n\n /**\n * Whether the device supports touch interactions.\n * @default false for desktop, true for mobile/tablet\n */\n touch?: boolean;\n\n /**\n * Safe area inset from the top of the screen (in pixels).\n * Used for devices with notches or status bars.\n */\n safeAreaTop?: number;\n\n /**\n * Safe area inset from the bottom of the screen (in pixels).\n * Used for devices with home indicators.\n */\n safeAreaBottom?: number;\n\n /**\n * Safe area inset from the left of the screen (in pixels).\n */\n safeAreaLeft?: number;\n\n /**\n * Safe area inset from the right of the screen (in pixels).\n */\n safeAreaRight?: number;\n\n /**\n * Enable Prod Tools mode (real tool handlers instead of simulation mocks).\n */\n prodTools?: boolean;\n\n /**\n * Enable Prod Resources mode (production dist/ bundles instead of HMR).\n */\n prodResources?: boolean;\n\n /**\n * MCP server URL for inspect mode. Encoded into the URL for informational purposes.\n */\n serverUrl?: string;\n\n /**\n * Pre-select a tool by name (alternative to the `simulation` param).\n */\n tool?: string;\n}\n\n/**\n * Creates a URL path with query parameters for the ChatGPT Simulator.\n *\n * @param params - The simulator parameters to encode\n * @param basePath - The base path for the URL (default: '/')\n * @returns A URL path string with encoded query parameters\n *\n * @example\n * ```ts\n * // Basic usage\n * createSimulatorUrl({ simulation: 'show-albums', theme: 'light' })\n * // Returns: '/?simulation=show-albums&theme=light'\n *\n * // With display mode\n * createSimulatorUrl({\n * simulation: 'review-diff',\n * theme: 'dark',\n * displayMode: 'fullscreen',\n * })\n * // Returns: '/?simulation=review-diff&theme=dark&displayMode=fullscreen'\n *\n * // With device simulation\n * createSimulatorUrl({\n * simulation: 'show-map',\n * deviceType: 'mobile',\n * touch: true,\n * hover: false,\n * })\n * // Returns: '/?simulation=show-map&deviceType=mobile&touch=true&hover=false'\n *\n * // With safe area insets (for notch simulation)\n * createSimulatorUrl({\n * simulation: 'show-carousel',\n * safeAreaTop: 44,\n * safeAreaBottom: 34,\n * })\n * // Returns: '/?simulation=show-carousel&safeAreaTop=44&safeAreaBottom=34'\n * ```\n */\nexport function createSimulatorUrl(params: SimulatorUrlParams, basePath = '/'): string {\n const searchParams = new URLSearchParams();\n\n // Add each defined parameter\n if (params.simulation !== undefined) {\n searchParams.set('simulation', params.simulation);\n }\n if (params.host !== undefined) {\n searchParams.set('host', params.host);\n }\n if (params.theme !== undefined) {\n searchParams.set('theme', params.theme);\n }\n if (params.displayMode !== undefined) {\n searchParams.set('displayMode', params.displayMode);\n }\n if (params.locale !== undefined) {\n searchParams.set('locale', params.locale);\n }\n if (params.maxHeight !== undefined) {\n searchParams.set('maxHeight', String(params.maxHeight));\n }\n if (params.deviceType !== undefined) {\n searchParams.set('deviceType', params.deviceType);\n }\n if (params.hover !== undefined) {\n searchParams.set('hover', String(params.hover));\n }\n if (params.touch !== undefined) {\n searchParams.set('touch', String(params.touch));\n }\n if (params.safeAreaTop !== undefined) {\n searchParams.set('safeAreaTop', String(params.safeAreaTop));\n }\n if (params.safeAreaBottom !== undefined) {\n searchParams.set('safeAreaBottom', String(params.safeAreaBottom));\n }\n if (params.safeAreaLeft !== undefined) {\n searchParams.set('safeAreaLeft', String(params.safeAreaLeft));\n }\n if (params.safeAreaRight !== undefined) {\n searchParams.set('safeAreaRight', String(params.safeAreaRight));\n }\n if (params.prodTools !== undefined) {\n searchParams.set('prodTools', String(params.prodTools));\n }\n if (params.prodResources !== undefined) {\n searchParams.set('prodResources', String(params.prodResources));\n }\n if (params.serverUrl !== undefined) {\n searchParams.set('serverUrl', params.serverUrl);\n }\n if (params.tool !== undefined) {\n searchParams.set('tool', params.tool);\n }\n const queryString = searchParams.toString();\n return queryString ? `${basePath}?${queryString}` : basePath;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiKA,SAAgB,mBAAmB,QAA4B,WAAW,KAAa;CACrF,MAAM,eAAe,IAAI,iBAAiB;AAG1C,KAAI,OAAO,eAAe,KAAA,EACxB,cAAa,IAAI,cAAc,OAAO,WAAW;AAEnD,KAAI,OAAO,SAAS,KAAA,EAClB,cAAa,IAAI,QAAQ,OAAO,KAAK;AAEvC,KAAI,OAAO,UAAU,KAAA,EACnB,cAAa,IAAI,SAAS,OAAO,MAAM;AAEzC,KAAI,OAAO,gBAAgB,KAAA,EACzB,cAAa,IAAI,eAAe,OAAO,YAAY;AAErD,KAAI,OAAO,WAAW,KAAA,EACpB,cAAa,IAAI,UAAU,OAAO,OAAO;AAE3C,KAAI,OAAO,cAAc,KAAA,EACvB,cAAa,IAAI,aAAa,OAAO,OAAO,UAAU,CAAC;AAEzD,KAAI,OAAO,eAAe,KAAA,EACxB,cAAa,IAAI,cAAc,OAAO,WAAW;AAEnD,KAAI,OAAO,UAAU,KAAA,EACnB,cAAa,IAAI,SAAS,OAAO,OAAO,MAAM,CAAC;AAEjD,KAAI,OAAO,UAAU,KAAA,EACnB,cAAa,IAAI,SAAS,OAAO,OAAO,MAAM,CAAC;AAEjD,KAAI,OAAO,gBAAgB,KAAA,EACzB,cAAa,IAAI,eAAe,OAAO,OAAO,YAAY,CAAC;AAE7D,KAAI,OAAO,mBAAmB,KAAA,EAC5B,cAAa,IAAI,kBAAkB,OAAO,OAAO,eAAe,CAAC;AAEnE,KAAI,OAAO,iBAAiB,KAAA,EAC1B,cAAa,IAAI,gBAAgB,OAAO,OAAO,aAAa,CAAC;AAE/D,KAAI,OAAO,kBAAkB,KAAA,EAC3B,cAAa,IAAI,iBAAiB,OAAO,OAAO,cAAc,CAAC;AAEjE,KAAI,OAAO,cAAc,KAAA,EACvB,cAAa,IAAI,aAAa,OAAO,OAAO,UAAU,CAAC;AAEzD,KAAI,OAAO,kBAAkB,KAAA,EAC3B,cAAa,IAAI,iBAAiB,OAAO,OAAO,cAAc,CAAC;AAEjE,KAAI,OAAO,cAAc,KAAA,EACvB,cAAa,IAAI,aAAa,OAAO,UAAU;AAEjD,KAAI,OAAO,SAAS,KAAA,EAClB,cAAa,IAAI,QAAQ,OAAO,KAAK;CAEvC,MAAM,cAAc,aAAa,UAAU;AAC3C,QAAO,cAAc,GAAG,SAAS,GAAG,gBAAgB"}
@@ -55,10 +55,12 @@ function createSimulatorUrl(params, basePath = "/") {
55
55
  if (params.safeAreaRight !== void 0) searchParams.set("safeAreaRight", String(params.safeAreaRight));
56
56
  if (params.prodTools !== void 0) searchParams.set("prodTools", String(params.prodTools));
57
57
  if (params.prodResources !== void 0) searchParams.set("prodResources", String(params.prodResources));
58
+ if (params.serverUrl !== void 0) searchParams.set("serverUrl", params.serverUrl);
59
+ if (params.tool !== void 0) searchParams.set("tool", params.tool);
58
60
  const queryString = searchParams.toString();
59
61
  return queryString ? `${basePath}?${queryString}` : basePath;
60
62
  }
61
63
  //#endregion
62
64
  export { createSimulatorUrl as t };
63
65
 
64
- //# sourceMappingURL=simulator-url-Bkxj43yT.js.map
66
+ //# sourceMappingURL=simulator-url-KoS_ToP6.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"simulator-url-KoS_ToP6.js","names":[],"sources":["../src/simulator/simulator-url.ts"],"sourcesContent":["import type { Theme, DisplayMode, DeviceType } from '../types/runtime';\n\n/**\n * Strongly-typed URL parameters for the Simulator.\n *\n * Use with `createSimulatorUrl()` to generate type-safe URL paths for e2e tests.\n *\n * @example\n * ```ts\n * import { createSimulatorUrl } from 'sunpeak/chatgpt';\n *\n * // In e2e tests:\n * await page.goto(createSimulatorUrl({\n * simulation: 'show-albums',\n * theme: 'dark',\n * displayMode: 'fullscreen',\n * host: 'claude',\n * }));\n * ```\n */\nexport interface SimulatorUrlParams {\n /**\n * The simulation name to load (e.g., 'show-albums', 'review-diff').\n * Corresponds to the simulation JSON filename without the `.json` extension.\n */\n simulation?: string;\n\n /**\n * The host shell to use (e.g., 'chatgpt', 'claude').\n * Switches conversation chrome, theming, and reported host info/capabilities.\n * @default 'chatgpt'\n */\n host?: string;\n\n /**\n * The color theme for the simulator.\n * @default 'dark'\n */\n theme?: Theme;\n\n /**\n * The display mode for the widget.\n * - 'inline': Embedded in the conversation\n * - 'pip': Picture-in-picture mode with max height\n * - 'fullscreen': Full screen overlay\n * @default 'inline'\n */\n displayMode?: DisplayMode;\n\n /**\n * The locale for the simulator (e.g., 'en-US', 'ja-JP').\n * @default 'en-US'\n */\n locale?: string;\n\n /**\n * Maximum height in pixels for PiP mode.\n * Only applicable when displayMode is 'pip'.\n */\n maxHeight?: number;\n\n /**\n * The device type to simulate.\n * Affects default hover/touch capabilities.\n */\n deviceType?: DeviceType;\n\n /**\n * Whether the device supports hover interactions.\n * @default true for desktop, false for mobile/tablet\n */\n hover?: boolean;\n\n /**\n * Whether the device supports touch interactions.\n * @default false for desktop, true for mobile/tablet\n */\n touch?: boolean;\n\n /**\n * Safe area inset from the top of the screen (in pixels).\n * Used for devices with notches or status bars.\n */\n safeAreaTop?: number;\n\n /**\n * Safe area inset from the bottom of the screen (in pixels).\n * Used for devices with home indicators.\n */\n safeAreaBottom?: number;\n\n /**\n * Safe area inset from the left of the screen (in pixels).\n */\n safeAreaLeft?: number;\n\n /**\n * Safe area inset from the right of the screen (in pixels).\n */\n safeAreaRight?: number;\n\n /**\n * Enable Prod Tools mode (real tool handlers instead of simulation mocks).\n */\n prodTools?: boolean;\n\n /**\n * Enable Prod Resources mode (production dist/ bundles instead of HMR).\n */\n prodResources?: boolean;\n\n /**\n * MCP server URL for inspect mode. Encoded into the URL for informational purposes.\n */\n serverUrl?: string;\n\n /**\n * Pre-select a tool by name (alternative to the `simulation` param).\n */\n tool?: string;\n}\n\n/**\n * Creates a URL path with query parameters for the ChatGPT Simulator.\n *\n * @param params - The simulator parameters to encode\n * @param basePath - The base path for the URL (default: '/')\n * @returns A URL path string with encoded query parameters\n *\n * @example\n * ```ts\n * // Basic usage\n * createSimulatorUrl({ simulation: 'show-albums', theme: 'light' })\n * // Returns: '/?simulation=show-albums&theme=light'\n *\n * // With display mode\n * createSimulatorUrl({\n * simulation: 'review-diff',\n * theme: 'dark',\n * displayMode: 'fullscreen',\n * })\n * // Returns: '/?simulation=review-diff&theme=dark&displayMode=fullscreen'\n *\n * // With device simulation\n * createSimulatorUrl({\n * simulation: 'show-map',\n * deviceType: 'mobile',\n * touch: true,\n * hover: false,\n * })\n * // Returns: '/?simulation=show-map&deviceType=mobile&touch=true&hover=false'\n *\n * // With safe area insets (for notch simulation)\n * createSimulatorUrl({\n * simulation: 'show-carousel',\n * safeAreaTop: 44,\n * safeAreaBottom: 34,\n * })\n * // Returns: '/?simulation=show-carousel&safeAreaTop=44&safeAreaBottom=34'\n * ```\n */\nexport function createSimulatorUrl(params: SimulatorUrlParams, basePath = '/'): string {\n const searchParams = new URLSearchParams();\n\n // Add each defined parameter\n if (params.simulation !== undefined) {\n searchParams.set('simulation', params.simulation);\n }\n if (params.host !== undefined) {\n searchParams.set('host', params.host);\n }\n if (params.theme !== undefined) {\n searchParams.set('theme', params.theme);\n }\n if (params.displayMode !== undefined) {\n searchParams.set('displayMode', params.displayMode);\n }\n if (params.locale !== undefined) {\n searchParams.set('locale', params.locale);\n }\n if (params.maxHeight !== undefined) {\n searchParams.set('maxHeight', String(params.maxHeight));\n }\n if (params.deviceType !== undefined) {\n searchParams.set('deviceType', params.deviceType);\n }\n if (params.hover !== undefined) {\n searchParams.set('hover', String(params.hover));\n }\n if (params.touch !== undefined) {\n searchParams.set('touch', String(params.touch));\n }\n if (params.safeAreaTop !== undefined) {\n searchParams.set('safeAreaTop', String(params.safeAreaTop));\n }\n if (params.safeAreaBottom !== undefined) {\n searchParams.set('safeAreaBottom', String(params.safeAreaBottom));\n }\n if (params.safeAreaLeft !== undefined) {\n searchParams.set('safeAreaLeft', String(params.safeAreaLeft));\n }\n if (params.safeAreaRight !== undefined) {\n searchParams.set('safeAreaRight', String(params.safeAreaRight));\n }\n if (params.prodTools !== undefined) {\n searchParams.set('prodTools', String(params.prodTools));\n }\n if (params.prodResources !== undefined) {\n searchParams.set('prodResources', String(params.prodResources));\n }\n if (params.serverUrl !== undefined) {\n searchParams.set('serverUrl', params.serverUrl);\n }\n if (params.tool !== undefined) {\n searchParams.set('tool', params.tool);\n }\n const queryString = searchParams.toString();\n return queryString ? `${basePath}?${queryString}` : basePath;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiKA,SAAgB,mBAAmB,QAA4B,WAAW,KAAa;CACrF,MAAM,eAAe,IAAI,iBAAiB;AAG1C,KAAI,OAAO,eAAe,KAAA,EACxB,cAAa,IAAI,cAAc,OAAO,WAAW;AAEnD,KAAI,OAAO,SAAS,KAAA,EAClB,cAAa,IAAI,QAAQ,OAAO,KAAK;AAEvC,KAAI,OAAO,UAAU,KAAA,EACnB,cAAa,IAAI,SAAS,OAAO,MAAM;AAEzC,KAAI,OAAO,gBAAgB,KAAA,EACzB,cAAa,IAAI,eAAe,OAAO,YAAY;AAErD,KAAI,OAAO,WAAW,KAAA,EACpB,cAAa,IAAI,UAAU,OAAO,OAAO;AAE3C,KAAI,OAAO,cAAc,KAAA,EACvB,cAAa,IAAI,aAAa,OAAO,OAAO,UAAU,CAAC;AAEzD,KAAI,OAAO,eAAe,KAAA,EACxB,cAAa,IAAI,cAAc,OAAO,WAAW;AAEnD,KAAI,OAAO,UAAU,KAAA,EACnB,cAAa,IAAI,SAAS,OAAO,OAAO,MAAM,CAAC;AAEjD,KAAI,OAAO,UAAU,KAAA,EACnB,cAAa,IAAI,SAAS,OAAO,OAAO,MAAM,CAAC;AAEjD,KAAI,OAAO,gBAAgB,KAAA,EACzB,cAAa,IAAI,eAAe,OAAO,OAAO,YAAY,CAAC;AAE7D,KAAI,OAAO,mBAAmB,KAAA,EAC5B,cAAa,IAAI,kBAAkB,OAAO,OAAO,eAAe,CAAC;AAEnE,KAAI,OAAO,iBAAiB,KAAA,EAC1B,cAAa,IAAI,gBAAgB,OAAO,OAAO,aAAa,CAAC;AAE/D,KAAI,OAAO,kBAAkB,KAAA,EAC3B,cAAa,IAAI,iBAAiB,OAAO,OAAO,cAAc,CAAC;AAEjE,KAAI,OAAO,cAAc,KAAA,EACvB,cAAa,IAAI,aAAa,OAAO,OAAO,UAAU,CAAC;AAEzD,KAAI,OAAO,kBAAkB,KAAA,EAC3B,cAAa,IAAI,iBAAiB,OAAO,OAAO,cAAc,CAAC;AAEjE,KAAI,OAAO,cAAc,KAAA,EACvB,cAAa,IAAI,aAAa,OAAO,UAAU;AAEjD,KAAI,OAAO,SAAS,KAAA,EAClB,cAAa,IAAI,QAAQ,OAAO,KAAK;CAEvC,MAAM,cAAc,aAAa,UAAU;AAC3C,QAAO,cAAc,GAAG,SAAS,GAAG,gBAAgB"}
package/dist/style.css CHANGED
@@ -721,6 +721,10 @@
721
721
  height: calc(var(--spacing) * 6);
722
722
  }
723
723
 
724
+ .h-2 {
725
+ height: calc(var(--spacing) * 2);
726
+ }
727
+
724
728
  .h-3 {
725
729
  height: calc(var(--spacing) * 3);
726
730
  }
@@ -813,6 +817,10 @@
813
817
  width: calc(var(--spacing) * 1);
814
818
  }
815
819
 
820
+ .w-2 {
821
+ width: calc(var(--spacing) * 2);
822
+ }
823
+
816
824
  .w-3 {
817
825
  width: calc(var(--spacing) * 3);
818
826
  }
@@ -853,10 +861,6 @@
853
861
  width: calc(var(--spacing) * 40);
854
862
  }
855
863
 
856
- .w-56 {
857
- width: calc(var(--spacing) * 56);
858
- }
859
-
860
864
  .w-\[18px\] {
861
865
  width: 18px;
862
866
  }
@@ -971,10 +975,6 @@
971
975
  grid-template-columns: repeat(7, minmax(0, 1fr));
972
976
  }
973
977
 
974
- .grid-cols-\[1fr_auto_1fr\] {
975
- grid-template-columns: 1fr auto 1fr;
976
- }
977
-
978
978
  .grid-cols-\[2fr_1fr\] {
979
979
  grid-template-columns: 2fr 1fr;
980
980
  }
@@ -1015,10 +1015,6 @@
1015
1015
  justify-content: flex-end;
1016
1016
  }
1017
1017
 
1018
- .justify-start {
1019
- justify-content: flex-start;
1020
- }
1021
-
1022
1018
  .gap-0\.5 {
1023
1019
  gap: calc(var(--spacing) * .5);
1024
1020
  }
@@ -1139,8 +1135,12 @@
1139
1135
  border-radius: 10px;
1140
1136
  }
1141
1137
 
1142
- .rounded-\[18px\] {
1143
- border-radius: 18px;
1138
+ .rounded-\[22px\] {
1139
+ border-radius: 22px;
1140
+ }
1141
+
1142
+ .rounded-\[28px\] {
1143
+ border-radius: 28px;
1144
1144
  }
1145
1145
 
1146
1146
  .rounded-full {
@@ -1385,10 +1385,18 @@
1385
1385
  padding: calc(var(--spacing) * 1.5);
1386
1386
  }
1387
1387
 
1388
+ .p-1\.25 {
1389
+ padding: calc(var(--spacing) * 1.25);
1390
+ }
1391
+
1388
1392
  .p-2 {
1389
1393
  padding: calc(var(--spacing) * 2);
1390
1394
  }
1391
1395
 
1396
+ .p-2\.5 {
1397
+ padding: calc(var(--spacing) * 2.5);
1398
+ }
1399
+
1392
1400
  .p-3 {
1393
1401
  padding: calc(var(--spacing) * 3);
1394
1402
  }
@@ -1555,6 +1563,11 @@
1555
1563
  font-size: 11px;
1556
1564
  }
1557
1565
 
1566
+ .leading-6 {
1567
+ --tw-leading: calc(var(--spacing) * 6);
1568
+ line-height: calc(var(--spacing) * 6);
1569
+ }
1570
+
1558
1571
  .leading-none {
1559
1572
  --tw-leading: 1;
1560
1573
  line-height: 1;
@@ -1665,13 +1678,13 @@
1665
1678
  box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);
1666
1679
  }
1667
1680
 
1668
- .shadow-\[0px_0px_0px_1px_\#fff3\,0px_4px_12px_rgba\(0\,0\,0\,0\.12\)\] {
1669
- --tw-shadow: 0px 0px 0px 1px var(--tw-shadow-color, #fff3), 0px 4px 12px var(--tw-shadow-color, #0000001f);
1681
+ .shadow-\[0px_0px_0px_1px_var\(--color-border-primary\)\,0px_4px_12px_rgba\(0\,0\,0\,0\.12\)\] {
1682
+ --tw-shadow: 0px 0px 0px 1px var(--tw-shadow-color, var(--color-border-primary)), 0px 4px 12px var(--tw-shadow-color, #0000001f);
1670
1683
  box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);
1671
1684
  }
1672
1685
 
1673
- .shadow-\[0px_0px_0px_1px_\#fff3\,0px_6px_20px_rgba\(0\,0\,0\,0\.1\)\] {
1674
- --tw-shadow: 0px 0px 0px 1px var(--tw-shadow-color, #fff3), 0px 6px 20px var(--tw-shadow-color, #0000001a);
1686
+ .shadow-\[0px_0px_0px_1px_var\(--color-border-primary\)\,0px_6px_20px_rgba\(0\,0\,0\,0\.1\)\] {
1687
+ --tw-shadow: 0px 0px 0px 1px var(--tw-shadow-color, var(--color-border-primary)), 0px 6px 20px var(--tw-shadow-color, #0000001a);
1675
1688
  box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);
1676
1689
  }
1677
1690
 
@@ -2004,6 +2017,10 @@
2004
2017
  }
2005
2018
 
2006
2019
  @media (min-width: 48rem) {
2020
+ .md\:-start-6 {
2021
+ inset-inline-start: calc(var(--spacing) * -6);
2022
+ }
2023
+
2007
2024
  .md\:z-20 {
2008
2025
  z-index: 20;
2009
2026
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sunpeak",
3
- "version": "0.16.28",
3
+ "version": "0.17.1",
4
4
  "description": "Local-first MCP Apps framework. Quickstart, build, test, and ship your Claude Connector or ChatGPT App!",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",
@@ -91,6 +91,12 @@
91
91
  "default": "./bin/lib/live/chatgpt-config.mjs"
92
92
  }
93
93
  },
94
+ "./test/inspect/config": {
95
+ "import": {
96
+ "types": "./bin/lib/inspect/inspect-config.d.mts",
97
+ "default": "./bin/lib/inspect/inspect-config.mjs"
98
+ }
99
+ },
94
100
  "./package.json": "./package.json"
95
101
  },
96
102
  "bin": {
@@ -162,6 +168,7 @@
162
168
  "typescript": "^5.9.3",
163
169
  "vite": "^8.0.1",
164
170
  "vite-plugin-dts": "^4.5.4",
171
+ "@playwright/test": "^1.52.0",
165
172
  "vitest": "^4.1.0"
166
173
  },
167
174
  "repository": {
@@ -179,6 +186,7 @@
179
186
  "lint": "eslint . --ext .ts,.tsx --fix",
180
187
  "typecheck": "tsc --noEmit",
181
188
  "test": "vitest run",
189
+ "test:e2e": "pnpm exec playwright test",
182
190
  "generate-examples": "node scripts/generate-examples.mjs",
183
191
  "validate": "node scripts/validate.mjs"
184
192
  }