@maaxyz/maa-node 5.0.0-beta.1 → 5.0.0-beta.2
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/pipeline.d.ts +37 -0
- package/package.json +7 -7
package/dist/pipeline.d.ts
CHANGED
|
@@ -177,12 +177,14 @@ declare global {
|
|
|
177
177
|
type ActionClick = {
|
|
178
178
|
target?: true | NodeName | FlatRect
|
|
179
179
|
target_offset?: FlatRect
|
|
180
|
+
contact?: number
|
|
180
181
|
}
|
|
181
182
|
|
|
182
183
|
type ActionLongPress = {
|
|
183
184
|
target?: true | NodeName | FlatRect
|
|
184
185
|
target_offset?: FlatRect
|
|
185
186
|
duration?: number
|
|
187
|
+
contact?: number
|
|
186
188
|
}
|
|
187
189
|
|
|
188
190
|
type ActionSwipe = {
|
|
@@ -191,6 +193,7 @@ declare global {
|
|
|
191
193
|
end?: true | NodeName | FlatRect
|
|
192
194
|
end_offset?: FlatRect
|
|
193
195
|
duration?: number
|
|
196
|
+
contact?: number
|
|
194
197
|
}
|
|
195
198
|
|
|
196
199
|
type ActionMultiSwipe<Mode> = RequiredIfStrict<
|
|
@@ -202,12 +205,32 @@ declare global {
|
|
|
202
205
|
end?: true | NodeName | FlatRect
|
|
203
206
|
end_offset?: FlatRect
|
|
204
207
|
duration?: number
|
|
208
|
+
contact?: number
|
|
205
209
|
}[]
|
|
206
210
|
},
|
|
207
211
|
'swipes',
|
|
208
212
|
Mode
|
|
209
213
|
>
|
|
210
214
|
|
|
215
|
+
type ActionTouch<Mode> = RequiredIfStrict<
|
|
216
|
+
{
|
|
217
|
+
contact?: number
|
|
218
|
+
target?: true | NodeName | FlatRect
|
|
219
|
+
target_offset?: FlatRect
|
|
220
|
+
pressure?: number
|
|
221
|
+
},
|
|
222
|
+
never,
|
|
223
|
+
Mode
|
|
224
|
+
>
|
|
225
|
+
|
|
226
|
+
type ActionTouchUp<Mode> = RequiredIfStrict<
|
|
227
|
+
{
|
|
228
|
+
contact?: number
|
|
229
|
+
},
|
|
230
|
+
never,
|
|
231
|
+
Mode
|
|
232
|
+
>
|
|
233
|
+
|
|
211
234
|
type ActionClickKey<Mode> = RequiredIfStrict<
|
|
212
235
|
{
|
|
213
236
|
key?: MaybeArray<number, Mode>
|
|
@@ -225,6 +248,14 @@ declare global {
|
|
|
225
248
|
Mode
|
|
226
249
|
>
|
|
227
250
|
|
|
251
|
+
type ActionSingleKey<Mode> = RequiredIfStrict<
|
|
252
|
+
{
|
|
253
|
+
key?: number
|
|
254
|
+
},
|
|
255
|
+
'key',
|
|
256
|
+
Mode
|
|
257
|
+
>
|
|
258
|
+
|
|
228
259
|
type ActionInputText<Mode> = RequiredIfStrict<
|
|
229
260
|
{
|
|
230
261
|
input_text?: string
|
|
@@ -301,9 +332,14 @@ declare global {
|
|
|
301
332
|
| MixAct<'LongPress', ActionLongPress, Mode>
|
|
302
333
|
| MixAct<'Swipe', ActionSwipe, Mode>
|
|
303
334
|
| MixAct<'MultiSwipe', ActionMultiSwipe<Mode>, Mode>
|
|
335
|
+
| MixAct<'TouchDown', ActionTouch<Mode>, Mode>
|
|
336
|
+
| MixAct<'TouchMove', ActionTouch<Mode>, Mode>
|
|
337
|
+
| MixAct<'TouchUp', ActionTouchUp<Mode>, Mode>
|
|
304
338
|
| MixAct<'Key', ActionClickKey<Mode>, Mode>
|
|
305
339
|
| MixAct<'ClickKey', ActionClickKey<Mode>, Mode>
|
|
306
340
|
| MixAct<'LongPressKey', ActionLongPressKey<Mode>, Mode>
|
|
341
|
+
| MixAct<'KeyDown', ActionSingleKey<Mode>, Mode>
|
|
342
|
+
| MixAct<'KeyUp', ActionSingleKey<Mode>, Mode>
|
|
307
343
|
| MixAct<'InputText', ActionInputText<Mode>, Mode>
|
|
308
344
|
| MixAct<'StartApp', ActionStartApp<Mode>, Mode>
|
|
309
345
|
| MixAct<'StopApp', ActionStopApp<Mode>, Mode>
|
|
@@ -335,6 +371,7 @@ declare global {
|
|
|
335
371
|
pre_wait_freezes?: RemoveIfDump<number, Mode> | WaitFreeze
|
|
336
372
|
post_wait_freezes?: RemoveIfDump<number, Mode> | WaitFreeze
|
|
337
373
|
focus?: unknown
|
|
374
|
+
attach?: Record<string, unknown> // 附加 JSON 对象
|
|
338
375
|
}
|
|
339
376
|
|
|
340
377
|
type Task = Recognition<ModeFragment> & Action<ModeFragment> & General<ModeFragment>
|
package/package.json
CHANGED
|
@@ -28,13 +28,13 @@
|
|
|
28
28
|
"prettier": "^3.5.2",
|
|
29
29
|
"typescript": "^5.8.2"
|
|
30
30
|
},
|
|
31
|
-
"version": "5.0.0-beta.
|
|
31
|
+
"version": "5.0.0-beta.2",
|
|
32
32
|
"optionalDependencies": {
|
|
33
|
-
"@maaxyz/maa-node-darwin-arm64": "5.0.0-beta.
|
|
34
|
-
"@maaxyz/maa-node-darwin-x64": "5.0.0-beta.
|
|
35
|
-
"@maaxyz/maa-node-linux-arm64": "5.0.0-beta.
|
|
36
|
-
"@maaxyz/maa-node-linux-x64": "5.0.0-beta.
|
|
37
|
-
"@maaxyz/maa-node-win32-arm64": "5.0.0-beta.
|
|
38
|
-
"@maaxyz/maa-node-win32-x64": "5.0.0-beta.
|
|
33
|
+
"@maaxyz/maa-node-darwin-arm64": "5.0.0-beta.2",
|
|
34
|
+
"@maaxyz/maa-node-darwin-x64": "5.0.0-beta.2",
|
|
35
|
+
"@maaxyz/maa-node-linux-arm64": "5.0.0-beta.2",
|
|
36
|
+
"@maaxyz/maa-node-linux-x64": "5.0.0-beta.2",
|
|
37
|
+
"@maaxyz/maa-node-win32-arm64": "5.0.0-beta.2",
|
|
38
|
+
"@maaxyz/maa-node-win32-x64": "5.0.0-beta.2"
|
|
39
39
|
}
|
|
40
40
|
}
|