pixifact-cli 0.3.0 → 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.
package/README.md CHANGED
@@ -29,7 +29,21 @@ pixifact scene validate --all
29
29
 
30
30
  默认使用当前工作目录作为项目根目录;不在项目根目录运行时再加 `--project-root <path>`。
31
31
 
32
- 其他命令是辅助入口:`scene create` 用于新建 Scene,`node inspect` 用于已知 locator 的节点详情,`live ...` 只在 Editor 运行时读取上下文。不要使用 `scene get`,file mode 只保留 `scene inspect`。
32
+ 其他命令是辅助入口:`scene create` 用于新建 Scene,`node inspect` 用于已知 locator 的节点详情,`editor context` 用于 Editor 运行时读取当前 Scene 和 selection。不要使用 `scene get`,file mode 只保留 `scene inspect`。旧 `live ...` 命令已经删除。
33
+
34
+ ## 浏览器 Editor
35
+
36
+ 在目标项目根目录运行:
37
+
38
+ ```bash
39
+ pixifact editor
40
+ ```
41
+
42
+ CLI 会启动只绑定 `127.0.0.1` 的本地 Bun 服务并打开系统浏览器。Editor 从项目内现有 `.scene` 建立层级、Pixi 预览和 Inspector;属性输入实时更新预览,失焦或 Enter 后自动保存,Undo / Redo 也会写回文件。Scene 写入携带当前文件版本,版本不一致时返回冲突而不是覆盖外部 Agent 的修改。
43
+
44
+ 同一项目重复运行 `pixifact editor` 会复用现有 Host;一个 Host 同时只接受一个浏览器 Editor 页面。Editor 已同步时可运行 `pixifact editor context` 获取只读上下文。
45
+
46
+ 图片必须由用户或外部 Agent 放入项目;Editor 只索引现有图片,不提供导入、移动、重命名或删除源资源。
33
47
 
34
48
  ## Agent 工作流
35
49
 
@@ -43,6 +57,23 @@ bun run build
43
57
 
44
58
  不要编辑 `.pixifact/generated/**` 下的生成文件。
45
59
 
60
+ ## 微信小游戏 target
61
+
62
+ 项目在 `pixifact.project.json` 声明 `targets.wechat` 后,可运行:
63
+
64
+ ```bash
65
+ pixifact validate --target wechat
66
+ pixifact build --target wechat
67
+ pixifact build --target wechat --mode development
68
+ pixifact dev --target wechat
69
+ ```
70
+
71
+ `build` 默认使用 production mode,压缩 `game.js`;development mode 额外输出 source map。`dev` 固定使用 development mode,并在 Scene、脚本、平台配置或资源变化时重建。
72
+
73
+ 输出目录由 `targets.wechat.outDir` 决定,可直接导入微信开发者工具。CLI 负责 target 校验、Scene 编译、主包资源 hash、资源分包 / HTTPS 远程资源映射、原生配置复制和 4 MiB 主包 / 20 MiB 总包检查,不负责上传、体验版、审核或发布。
74
+
75
+ 完整配置和支持矩阵见 [微信小游戏构建](https://github.com/hxg2050/pixifact/blob/main/docs/zh/wechat-minigame.md),可运行示例见 [wechat-minigame-demo](https://github.com/hxg2050/pixifact/tree/main/sample-projects/wechat-minigame-demo)。
76
+
46
77
  ## 环境要求
47
78
 
48
79
  - Bun
@@ -0,0 +1 @@
1
+ import{a as e,c as t,i as n,l as r,o as i,s as a,u as o}from"./index-CAe9Mkmr.js";import"./init-C32NAhsC.js";o.add(t),o.mixin(r,a),o.add(i),o.add(e),o.mixin(r,n);