@heybox/hb-sdk 0.9.3-alpha.5 → 0.9.3-alpha.6

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 (31) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/dist/cli-chunks/{build-Pn4ywWZY.cjs → build-B1YssPNl.cjs} +5 -5
  3. package/dist/cli-chunks/{context-BkqQrXwr.cjs → context-Deob2IZ5.cjs} +2 -2
  4. package/dist/cli-chunks/{create-D9TJ0rH0.cjs → create-BWzY1CVT.cjs} +1 -1
  5. package/dist/cli-chunks/{deploy-lock-CZljn-8b.cjs → deploy-lock-ClcPcaSW.cjs} +1 -1
  6. package/dist/cli-chunks/{dev-B0OQJx4y.cjs → dev-wVCyeUOb.cjs} +8 -8
  7. package/dist/cli-chunks/{doctor-BjeCwL0b.cjs → doctor-DHd5eYBr.cjs} +1 -1
  8. package/dist/cli-chunks/{games-BrhVCrnm.cjs → games-DNhP1Om4.cjs} +2 -2
  9. package/dist/cli-chunks/{index-BvM5AsMO.cjs → index-BOd8ouDY.cjs} +1 -1
  10. package/dist/cli-chunks/{index-D-8IXO0n.cjs → index-DfYr8g3I.cjs} +17 -17
  11. package/dist/cli-chunks/{index.esm-B4XiZERF.cjs → index.esm-PlHUr780.cjs} +6 -6
  12. package/dist/cli-chunks/{login-Cl3VO6xC.cjs → login-D-iG6Um2.cjs} +1 -1
  13. package/dist/cli-chunks/{project-vite-CPDYMw5b.cjs → project-vite-DyKHpc6h.cjs} +1 -1
  14. package/dist/cli-chunks/{remote-BWQezxnR.cjs → remote-CyynHOcj.cjs} +7 -7
  15. package/dist/cli-chunks/{runtime-gate-CNLagNgF.cjs → runtime-gate-DPXnKdQ4.cjs} +2 -2
  16. package/dist/cli-chunks/{runtime-permission-env-CJR-o3w0.cjs → runtime-permission-env-BjO2KzGl.cjs} +2 -2
  17. package/dist/cli-chunks/{skill-B8qbj4Tc.cjs → skill-BOLOEDrj.cjs} +2 -2
  18. package/dist/cli-chunks/{version-Bpd890Nm.cjs → version-DX2glIk7.cjs} +1 -1
  19. package/dist/cli.cjs +1 -1
  20. package/dist/devtools/browser-dev-host/assets/{browser-dev-host-OpkCfneE.js → browser-dev-host-CD6Ado2B.js} +1 -1
  21. package/dist/devtools/browser-dev-host/assets/{desktop-app-launch-lns4avol.js → desktop-app-launch-CFl6m8k-.js} +1 -1
  22. package/dist/devtools/browser-dev-host/assets/{index-_0y5rm2x.js → index-Br7UpHGt.js} +3 -3
  23. package/dist/devtools/browser-dev-host/index.html +2 -2
  24. package/dist/index.cjs.js +1 -1
  25. package/dist/index.esm.js +1 -1
  26. package/dist/vite.cjs.js +1 -1
  27. package/dist/vite.esm.js +1 -1
  28. package/package.json +5 -5
  29. package/skill/SKILL.md +6 -0
  30. package/skill/skill.json +5 -5
  31. package/types/index.d.ts +7 -0
@@ -5,8 +5,8 @@
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
6
  <meta name="theme-color" content="#f4f5f7" />
7
7
  <title>小程序工坊调试台</title>
8
- <script type="module" crossorigin src="/assets/index-_0y5rm2x.js"></script>
9
- <link rel="modulepreload" crossorigin href="/assets/desktop-app-launch-lns4avol.js">
8
+ <script type="module" crossorigin src="/assets/index-Br7UpHGt.js"></script>
9
+ <link rel="modulepreload" crossorigin href="/assets/desktop-app-launch-CFl6m8k-.js">
10
10
  <link rel="stylesheet" crossorigin href="/assets/index-7Cq8iNcD.css">
11
11
  </head>
12
12
  <body>
package/dist/index.cjs.js CHANGED
@@ -7299,7 +7299,7 @@ function createMessageId() {
7299
7299
  /** 构建时替换为当前发布包的实际版本。 */
7300
7300
  const HB_SDK_VERSION = typeof undefined === 'string'
7301
7301
  ? undefined
7302
- : '0.9.3-alpha.5';
7302
+ : '0.9.3-alpha.6';
7303
7303
 
7304
7304
  const RUNTIME_MODES = new Set(['production', 'preview', 'development', 'unknown']);
7305
7305
  const OPERATING_SYSTEM_NAMES = new Set(['android', 'ios', 'ohos', 'windows', 'macos', 'linux', 'unknown']);
package/dist/index.esm.js CHANGED
@@ -7295,7 +7295,7 @@ function createMessageId() {
7295
7295
  /** 构建时替换为当前发布包的实际版本。 */
7296
7296
  const HB_SDK_VERSION = typeof undefined === 'string'
7297
7297
  ? undefined
7298
- : '0.9.3-alpha.5';
7298
+ : '0.9.3-alpha.6';
7299
7299
 
7300
7300
  const RUNTIME_MODES = new Set(['production', 'preview', 'development', 'unknown']);
7301
7301
  const OPERATING_SYSTEM_NAMES = new Set(['android', 'ios', 'ohos', 'windows', 'macos', 'linux', 'unknown']);
package/dist/vite.cjs.js CHANGED
@@ -10304,7 +10304,7 @@ async function ensureBasicInfoDirectory(rootPath, relative) {
10304
10304
  /** 构建时替换为当前发布包的实际版本。 */
10305
10305
  const HB_SDK_VERSION = typeof undefined === 'string'
10306
10306
  ? undefined
10307
- : '0.9.3-alpha.5';
10307
+ : '0.9.3-alpha.6';
10308
10308
 
10309
10309
  /**
10310
10310
  * iframe 与调试台页面的开发期 console 捕获转发。
package/dist/vite.esm.js CHANGED
@@ -10301,7 +10301,7 @@ async function ensureBasicInfoDirectory(rootPath, relative) {
10301
10301
  /** 构建时替换为当前发布包的实际版本。 */
10302
10302
  const HB_SDK_VERSION = typeof undefined === 'string'
10303
10303
  ? undefined
10304
- : '0.9.3-alpha.5';
10304
+ : '0.9.3-alpha.6';
10305
10305
 
10306
10306
  /**
10307
10307
  * iframe 与调试台页面的开发期 console 捕获转发。
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@heybox/hb-sdk",
3
- "version": "0.9.3-alpha.5",
3
+ "version": "0.9.3-alpha.6",
4
4
  "sideEffects": [
5
5
  "./src/index.ts",
6
6
  "./src/core/singleton.ts",
@@ -76,7 +76,7 @@
76
76
  "undici": "^7.28.0",
77
77
  "ws": "^8.18.0",
78
78
  "sharp": "^0.34.5",
79
- "@heybox/hb-sdk-protocol": "0.9.3-alpha.5"
79
+ "@heybox/hb-sdk-protocol": "0.9.3-alpha.6"
80
80
  },
81
81
  "peerDependencies": {
82
82
  "vite": ">=5"
@@ -128,12 +128,12 @@
128
128
  "vitest": "^3.2.4",
129
129
  "@ai-desktop/view-contract": "file:../hb-sdk-protocol/vendor/view-contract-2.2.2-6ac49bbf6410.tgz",
130
130
  "rollup-plugin-dts": "6.4.0",
131
- "@heybox-domain/heybox-theme": "~0.1.0",
132
- "@heybox/hb-api": "~1.28.17",
133
- "@heybox/hb-sdk-runtime": "~0.9.3-alpha.5",
131
+ "@heybox/hb-sdk-runtime": "~0.9.3-alpha.6",
134
132
  "@heybox-domain/heybox-vue3-ui": "~0.1.0",
133
+ "@heybox-domain/heybox-theme": "~0.1.0",
135
134
  "@heybox/runtime": "~0.2.1",
136
135
  "@heybox/runtime-policy": "~0.2.1",
136
+ "@heybox/hb-api": "~1.28.17",
137
137
  "@heybox/runtime-transport-fetch": "~0.2.1"
138
138
  },
139
139
  "publishConfig": {
package/skill/SKILL.md CHANGED
@@ -17,6 +17,12 @@ Before implementing screenshot flows or upgrading the SDK, use the canonical doc
17
17
 
18
18
  Before upgrading, verify both the page layout and the captured image. Do not only update the dependency or invocation without explaining screenshot behavior changes. Read exact version cutoffs, dimensions, parameters, and Host support from the canonical documentation fetched for this task; never substitute an older installed Skill snapshot.
19
19
 
20
+ ## 展示 API 迁移:升级前必查
21
+
22
+ 实现 `viewport.setDisplay` 调用流程或升级 SDK 前,先通过 canonical 文档索引读取该方法的 Reference 与迁移预告。主动向开发者说明已公布的返回值迁移安排,包括目标版本、是否已生效,以及需要准备的兼容和错误处理。
23
+
24
+ 核对项目已安装的 SDK 与公告中的版本门槛。当前和计划契约均以本次读取的 canonical 文档为准,不提前套用未来契约,不把不支持结果当作设置成功,也不依赖旧 Skill 快照。建议升级前验证支持和不支持两种 Host。
25
+
20
26
  ## Canonical Documentation
21
27
 
22
28
  The only maintained hb-sdk guidance source is:
package/skill/skill.json CHANGED
@@ -1,16 +1,16 @@
1
1
  {
2
2
  "name": "hb-sdk",
3
- "skillVersion": "0.9.3-alpha.5+skill.4d7b063940c3",
3
+ "skillVersion": "0.9.3-alpha.6+skill.d0d502673711",
4
4
  "sdk": {
5
5
  "package": "@heybox/hb-sdk",
6
- "version": "0.9.3-alpha.5",
7
- "compatibility": "0.9.3-alpha.5"
6
+ "version": "0.9.3-alpha.6",
7
+ "compatibility": "0.9.3-alpha.6"
8
8
  },
9
9
  "distribution": {
10
10
  "type": "npm",
11
11
  "package": "@heybox/hb-sdk",
12
- "version": "0.9.3-alpha.5",
12
+ "version": "0.9.3-alpha.6",
13
13
  "path": "skill"
14
14
  },
15
- "integrity": "sha256-4d7b063940c341502cf34c481b656be96ac27f1a252055b2b1af445c6392264c"
15
+ "integrity": "sha256-d0d502673711f5d077ee62e657749125788e396d5203894b7077dfe866fd2990"
16
16
  }
package/types/index.d.ts CHANGED
@@ -3685,6 +3685,13 @@ interface MiniProgramViewportModule {
3685
3685
  /**
3686
3686
  * 设置当前小程序的窗口方向和全屏状态。
3687
3687
  *
3688
+ * SDK `1.0.0` 计划将本方法调整为 `Promise<void>`:设置完成时正常返回,不支持时抛出明确错误;
3689
+ * 切换失败、超时或取消仍抛出对应错误。当前仍返回 `{ supported: boolean }`,现有行为保持不变。
3690
+ *
3691
+ * 请提前补齐 `try/catch`,过渡期保留 `supported: false` 判断,并先检查返回值是否存在再读取该字段;
3692
+ * 避免直接解构返回值或将未来的空返回值当作失败。仅在确认设置成功后继续依赖该设置的操作。
3693
+ * 不支持时的错误码与适配期限会在 `1.0.0` 正式发布前公告,并提供预发布版本验证。
3694
+ *
3688
3695
  * @param options - 方向与全屏目标,至少提供一个字段;省略的字段保持当前目标值。
3689
3696
  * @returns Host 完成原生方向与胶囊设置、布局稳定后返回 `{ supported: true }`;能力缺失或
3690
3697
  * 请求不受支持时返回 `{ supported: false }`,调用方仍应按实际窗口与安全区布局。