@hy-bricks/core 0.4.2 → 0.5.0

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 (2) hide show
  1. package/CHANGELOG.md +17 -10
  2. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @hy-bricks/core
2
2
 
3
+ ## [0.5.0] - 2026-06-03
4
+
5
+ 随 @hy-bricks fixed 组(canvas `free-split` 发版)同步升 0.5.0;`@hy-bricks/core` **无功能改动**。
6
+
7
+ ## 0.4.3
8
+
3
9
  ## [0.4.2] - 2026-05-28 · devtools 强化(配套升级)
4
10
 
5
11
  跟 `@hy-bricks/devtools` 0.4.2 同步。core 本次新增 SDK 内部 hook 给 devtools 消费,
@@ -50,29 +56,29 @@ pnpm up @hy-bricks/core@0.4.2
50
56
 
51
57
  每个组件实例可读 3 个 SDK 注入 prop:
52
58
 
53
- | Prop | 含义 |
54
- |---|---|
55
- | `this.hcInstanceId` | 实例 ID |
56
- | `this.hcCanvasId` | 所属画布 ID |
57
- | `this.hcComponentId` | 组件源 ID |
59
+ | Prop | 含义 |
60
+ | -------------------- | ----------- |
61
+ | `this.hcInstanceId` | 实例 ID |
62
+ | `this.hcCanvasId` | 所属画布 ID |
63
+ | `this.hcComponentId` | 组件源 ID |
58
64
 
59
65
  ```js
60
66
  // 组件源码 component.js
61
67
  export default {
62
68
  mounted() {
63
- console.log('我是谁', this.hcInstanceId, this.hcCanvasId)
69
+ console.log("我是谁", this.hcInstanceId, this.hcCanvasId);
64
70
 
65
71
  // ✅ 立即订阅,不再要等
66
- __HYPERCARD__.runtime.on(this.hcInstanceId, 'click', (payload) => {
72
+ __HYPERCARD__.runtime.on(this.hcInstanceId, "click", (payload) => {
67
73
  // ...
68
- })
74
+ });
69
75
 
70
76
  // ✅ 立即拿到 handle
71
77
  const handle = __HYPERCARD__.canvases
72
78
  .get(this.hcCanvasId)
73
- ?.getInstance(this.hcInstanceId)
79
+ ?.getInstance(this.hcInstanceId);
74
80
  },
75
- }
81
+ };
76
82
  ```
77
83
 
78
84
  ### ⚠ BREAKING — host 升级前 audit
@@ -102,6 +108,7 @@ grep -rn "instance:ready\|onInstanceLifecycle\|getInstanceReady" src/
102
108
  ```
103
109
 
104
110
  每处看回调内是否访问 `vm.$el` / DOM。
111
+
105
112
  - 没访问 → `npm install @hy-bricks/{core,canvas,editor,devtools}@^0.4.0` 透明升
106
113
  - 访问了 → 改 `nextTick`
107
114
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hy-bricks/core",
3
- "version": "0.4.2",
3
+ "version": "0.5.0",
4
4
  "description": "HyperCard 运行时核心 — 编译用户源码 / CSS scope / 实例注册表 / 跨实例 SDK / JS 静态解析",
5
5
  "keywords": [
6
6
  "hypercard",