@fjyueke/bify-mcp 1.0.6 → 1.0.8

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/README.md +46 -2
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -14,7 +14,7 @@ Bify MCP 是一项独立的 MCP(模型上下文协议)服务,旨在将 Bif
14
14
  - 直接使用 npx 运行
15
15
  - 无需外部依赖,只需要 Node 环境
16
16
  - 支持 68+ 个组件文档查询
17
- - 支持 Arco Mobile 代码转换
17
+ - 支持 Arco Mobile 代码转换(40+ 组件映射)
18
18
 
19
19
  ## 配置方式
20
20
 
@@ -51,7 +51,7 @@ Bify MCP 是一项独立的 MCP(模型上下文协议)服务,旨在将 Bif
51
51
  | `get-component-docs` | 获取指定组件的详细文档 |
52
52
  | `get-component-props` | 获取指定组件的属性和 API 文档 |
53
53
  | `list-component-example` | 获取指定组件的所有示例代码 |
54
- | `convert-arco-to-bify` | 将 Arco Mobile React 代码转换为 Bify 代码 |
54
+ | `convert-arco-to-bify` | 将 Arco Mobile React 代码转换为 Bify 代码(含详细报告) |
55
55
  | `get-arco-conversion-help` | 获取 Arco Mobile → Bify 转换帮助信息 |
56
56
 
57
57
  ## 使用示例
@@ -82,10 +82,54 @@ get-arco-conversion-help
82
82
  convert-arco-to-bify "<Cell label='标题' desc='描述' showArrow>内容</Cell>"
83
83
  ```
84
84
 
85
+ ### 转换示例
86
+
87
+ **Arco Mobile 代码**:
88
+ ```tsx
89
+ import { Cell, CellGroup, Button, Tag, Badge } from '@arco-design/mobile-react';
90
+
91
+ <CellGroup>
92
+ <Cell label="标题" desc="描述" showArrow>内容</Cell>
93
+ </CellGroup>
94
+ <Button type="primary" ghost size="huge" block>按钮</Button>
95
+ <Tag type="success" closable>标签</Tag>
96
+ <Badge count={99} maxCount={99}>图标</Badge>
97
+ ```
98
+
99
+ **转换后 Bify 代码**:
100
+ ```tsx
101
+ import { Cell, CellGroup, Button, Tag, Badge } from '@fjyueke/bify-core';
102
+
103
+ <CellGroup>
104
+ <Cell title="标题" brief="描述" clickable="true">内容</Cell>
105
+ </CellGroup>
106
+ <Button color="primary" variant="outlined" size="large" block>按钮</Button>
107
+ <Tag color="success" closeable>标签</Tag>
108
+ <Badge content={99} max={99}>图标</Badge>
109
+ ```
110
+
111
+ ## 属性映射示例
112
+
113
+ | Arco 属性 | Bify 属性 | 说明 |
114
+ |-----------|-----------|------|
115
+ | `label` | `title` | 单元格标题 |
116
+ | `desc` | `brief` | 单元格描述 |
117
+ | `showArrow` | `clickable` | 是否显示箭头 |
118
+ | `visible` | `open` | 弹窗显示状态 |
119
+ | `value` | `modelValue` | 表单值绑定 |
120
+ | `type` (Button) | `color` | 按钮颜色 |
121
+ | `ghost` | `variant="outlined"` | 镂空按钮样式 |
122
+ | `type` (Tag) | `color` | 标签颜色 |
123
+ | `count` | `content` | Badge 内容 |
124
+ | `maxCount` | `max` | Badge 最大值 |
125
+
85
126
  ## 版本历史
86
127
 
87
128
  | 版本 | 日期 | 说明 |
88
129
  |------|------|------|
130
+ | 1.0.6 | 2026-07-13 | 根据实际组件定义更新属性映射(Button 使用 color/variant,Tag 使用 color) |
131
+ | 1.0.5 | 2026-07-13 | 优化转换工具,增加详细报告(警告、建议、映射列表) |
132
+ | 1.0.4 | 2026-07-13 | 修复构建配置 |
89
133
  | 1.0.3 | 2026-07-13 | 优化代码转换工具,增加 40+ 组件映射、值映射、布尔属性转换 |
90
134
  | 1.0.2 | 2026-07-13 | 添加 Arco Mobile → Bify 代码转换功能 |
91
135
  | 1.0.1 | 2026-07-13 | 更正包名为 bify-mcp |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fjyueke/bify-mcp",
3
- "version": "1.0.6",
3
+ "version": "1.0.8",
4
4
  "type": "module",
5
5
  "description": "MCP UI builder by Bify",
6
6
  "license": "MIT",