@doubao-apps/ai 0.0.19 → 0.0.20
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/dist/skills/doubao-apps-dev/.ai/reference/open-api.md +94 -2
- package/dist/skills/douyin-to-doubao/SKILL.md +333 -0
- package/dist/skills/douyin-to-doubao/assets/migration-checklist-template.md +144 -0
- package/dist/skills/douyin-to-doubao/references/mapping/component-mapping.md +200 -0
- package/dist/skills/douyin-to-doubao/references/mapping/core-api-mapping.md +231 -0
- package/dist/skills/douyin-to-doubao/references/mapping/event-mapping.md +196 -0
- package/dist/skills/douyin-to-doubao/references/mapping/lifecycle-mapping.md +216 -0
- package/dist/skills/douyin-to-doubao/references/mapping/style-mapping.md +195 -0
- package/dist/skills/douyin-to-doubao/references/source-framework/api-reference.md +223 -0
- package/dist/skills/douyin-to-doubao/references/source-framework/components.md +252 -0
- package/dist/skills/h5-to-doubao/SKILL.md +9 -7
- package/dist/skills/weixin-to-doubao/SKILL.md +18 -38
- package/dist/skills/weixin-to-doubao/assets/migration-checklist-template.md +11 -7
- package/dist/skills/weixin-to-doubao/references/mapping/component-mapping.md +35 -20
- package/dist/skills/weixin-to-doubao/references/source-framework/components.md +22 -12
- package/package.json +1 -1
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
|
|
37
37
|
### swiper / swiper-item
|
|
38
38
|
|
|
39
|
-
|
|
39
|
+
轮播图,当前项目可直接保留为 `<swiper>` / `<swiper-item>`,构建时由 loader 自动注入组件 import,但 API 与微信小程序不完全一致。
|
|
40
40
|
|
|
41
41
|
```wxml
|
|
42
42
|
<swiper
|
|
@@ -51,11 +51,11 @@
|
|
|
51
51
|
</swiper>
|
|
52
52
|
```
|
|
53
53
|
|
|
54
|
-
**Doubao Apps
|
|
54
|
+
**Doubao Apps**:优先保留 `<swiper>` / `<swiper-item>`,按当前 SDK 的 `data`、`itemWidth`、`autoPlay` 等 props 改写(见 component-mapping.md)
|
|
55
55
|
|
|
56
56
|
### movable-area / movable-view
|
|
57
57
|
|
|
58
|
-
|
|
58
|
+
可拖动区域,当前项目已有 `<movable-area>` / `<movable-view>`,可优先直接映射;复杂缩放和越界交互需校对 props。
|
|
59
59
|
|
|
60
60
|
---
|
|
61
61
|
|
|
@@ -110,6 +110,14 @@
|
|
|
110
110
|
|
|
111
111
|
视频,对应 Doubao Apps `<video>`,属性基本相同。
|
|
112
112
|
|
|
113
|
+
### map
|
|
114
|
+
|
|
115
|
+
地图组件,当前项目已有 `<map>` 与 `<map-marker>`,中心点、标注点、覆盖物等能力可迁移,但 props 需要按目标组件重新对齐。
|
|
116
|
+
|
|
117
|
+
### web-view
|
|
118
|
+
|
|
119
|
+
网页容器,当前项目已有 `<web-view>` 组件。迁移时可先保留标签,再结合宿主白名单与运行时限制做验证。
|
|
120
|
+
|
|
113
121
|
### camera
|
|
114
122
|
|
|
115
123
|
摄像头,Doubao Apps **无直接映射**,使用相机 API。
|
|
@@ -120,7 +128,7 @@
|
|
|
120
128
|
|
|
121
129
|
### button
|
|
122
130
|
|
|
123
|
-
|
|
131
|
+
按钮,可直接保留为小写 `<button>` 标签;构建时由 `components-loader` 自动补齐组件 import。
|
|
124
132
|
|
|
125
133
|
```wxml
|
|
126
134
|
<button
|
|
@@ -135,7 +143,7 @@
|
|
|
135
143
|
</button>
|
|
136
144
|
```
|
|
137
145
|
|
|
138
|
-
**Doubao Apps
|
|
146
|
+
**Doubao Apps**(迁移代码通常无需手写 import):
|
|
139
147
|
|
|
140
148
|
```tsx
|
|
141
149
|
<button
|
|
@@ -174,7 +182,7 @@
|
|
|
174
182
|
|
|
175
183
|
### switch
|
|
176
184
|
|
|
177
|
-
|
|
185
|
+
开关,可直接保留为小写 `<switch>` 标签。
|
|
178
186
|
|
|
179
187
|
```wxml
|
|
180
188
|
<switch checked="{{isOn}}" bindchange="handleChange" color="#007AFF" />
|
|
@@ -189,7 +197,7 @@
|
|
|
189
197
|
|
|
190
198
|
### slider
|
|
191
199
|
|
|
192
|
-
|
|
200
|
+
滑块,可直接保留为小写 `<slider>` 标签。
|
|
193
201
|
|
|
194
202
|
```wxml
|
|
195
203
|
<slider value="{{sliderVal}}" min="0" max="100" step="1" bindchange="handleSliderChange" />
|
|
@@ -204,7 +212,7 @@
|
|
|
204
212
|
|
|
205
213
|
### picker
|
|
206
214
|
|
|
207
|
-
|
|
215
|
+
选择器,优先使用现有 `<picker-view>` / `<picker-column>`,并配合 `<popup>`、`Dialog` 或业务弹层容器实现弹出式交互。
|
|
208
216
|
|
|
209
217
|
```wxml
|
|
210
218
|
<picker mode="selector" range="{{options}}" value="{{pickerIndex}}" bindchange="handlePickerChange">
|
|
@@ -212,7 +220,11 @@
|
|
|
212
220
|
</picker>
|
|
213
221
|
```
|
|
214
222
|
|
|
215
|
-
**Doubao Apps
|
|
223
|
+
**Doubao Apps 替代方案**:底部弹出层 + `<picker-view>` / `<picker-column>`,或简单场景下用 `<view>` 列表。
|
|
224
|
+
|
|
225
|
+
### picker-view
|
|
226
|
+
|
|
227
|
+
嵌入式滚动选择器,当前项目已有 `<picker-view>` / `<picker-column>`,适合日期、省市区、枚举值等多列联动场景。
|
|
216
228
|
|
|
217
229
|
### checkbox / checkbox-group
|
|
218
230
|
|
|
@@ -220,7 +232,7 @@
|
|
|
220
232
|
|
|
221
233
|
### radio / radio-group
|
|
222
234
|
|
|
223
|
-
|
|
235
|
+
单选框,当前项目已有 `<radio>` / `<radio-group>`,组内回调为 `onValueChange(value)`。
|
|
224
236
|
|
|
225
237
|
### form
|
|
226
238
|
|
|
@@ -264,8 +276,6 @@ import { navigateTo } from '@doubao-apps/framework/api';
|
|
|
264
276
|
|
|
265
277
|
| 微信小程序 | Doubao Apps | 建议 |
|
|
266
278
|
|-----------|-------------|------|
|
|
267
|
-
| `<web-view>` | 不支持 | 使用原生 WebView API |
|
|
268
|
-
| `<map>` | 不支持 | 使用原生地图 API |
|
|
269
279
|
| `<canvas>` | 有限支持 | 检查平台文档 |
|
|
270
280
|
| `<open-data>` | 不支持 | 使用平台用户信息 API |
|
|
271
281
|
| `<official-account>` | 不支持 | 移除 |
|