@tinywork/glass 1.0.35 → 1.0.36
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/index.d.ts +21 -15
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -412,7 +412,7 @@ declare global {
|
|
|
412
412
|
|
|
413
413
|
/** 获取cookie */
|
|
414
414
|
getCookie(
|
|
415
|
-
params: Omit<Cookie, "value"
|
|
415
|
+
params: Omit<Cookie, "value">,
|
|
416
416
|
): IGlassExtensionInvokeResponse<string>;
|
|
417
417
|
|
|
418
418
|
/** 保存文档组 */
|
|
@@ -432,7 +432,7 @@ declare global {
|
|
|
432
432
|
pathname: string;
|
|
433
433
|
params: { key: string; value?: string }[];
|
|
434
434
|
}>;
|
|
435
|
-
}
|
|
435
|
+
},
|
|
436
436
|
): IGlassExtensionInvokeResponse<{
|
|
437
437
|
apiId: string;
|
|
438
438
|
ruleId?: string;
|
|
@@ -440,35 +440,41 @@ declare global {
|
|
|
440
440
|
|
|
441
441
|
getDoc(id: string): IGlassExtensionInvokeResponse<DocSchema>;
|
|
442
442
|
getGroup(
|
|
443
|
-
id: string
|
|
443
|
+
id: string,
|
|
444
444
|
): IGlassExtensionInvokeResponse<GroupSchema & { docs?: DocSchema[] }>;
|
|
445
445
|
|
|
446
446
|
agentConfirm<T extends SyncDataParams>(
|
|
447
447
|
params: T & {
|
|
448
448
|
conversationId: string;
|
|
449
|
-
}
|
|
449
|
+
},
|
|
450
450
|
): IGlassExtensionInvokeResponse<T["data"]>;
|
|
451
451
|
|
|
452
|
+
sendAgentMessage(params: {
|
|
453
|
+
conversationId: string;
|
|
454
|
+
message?: string;
|
|
455
|
+
isFinish: boolean;
|
|
456
|
+
}): IGlassExtensionInvokeResponse<void>;
|
|
457
|
+
|
|
452
458
|
getRule(
|
|
453
|
-
params: { apiId: string } | { ruleId: string }
|
|
459
|
+
params: { apiId: string } | { ruleId: string },
|
|
454
460
|
): IGlassExtensionInvokeResponse<RuleSchema>;
|
|
455
461
|
transformDocToRule(
|
|
456
|
-
apiId: string
|
|
462
|
+
apiId: string,
|
|
457
463
|
): IGlassExtensionInvokeResponse<RuleSchema>;
|
|
458
464
|
saveRule(rule: RuleSchema): IGlassExtensionInvokeResponse<void>;
|
|
459
465
|
getCurrentVersion(): IGlassExtensionInvokeResponse<Version>;
|
|
460
466
|
getVersionDocs(
|
|
461
|
-
versionId: string
|
|
467
|
+
versionId: string,
|
|
462
468
|
): IGlassExtensionInvokeResponse<DocSchema[]>;
|
|
463
469
|
saveVersionDocs(
|
|
464
470
|
versionId: string,
|
|
465
|
-
apiIds: string[]
|
|
471
|
+
apiIds: string[],
|
|
466
472
|
): IGlassExtensionInvokeResponse<void>;
|
|
467
473
|
|
|
468
474
|
getVersionCases(versionId: string): IGlassExtensionInvokeResponse<Case[]>;
|
|
469
475
|
saveVersionCases(
|
|
470
476
|
versionId: string,
|
|
471
|
-
cases: Case[]
|
|
477
|
+
cases: Case[],
|
|
472
478
|
): IGlassExtensionInvokeResponse<void>;
|
|
473
479
|
execVersionCases(versionId: string): IGlassExtensionInvokeResponse<void>;
|
|
474
480
|
|
|
@@ -484,7 +490,7 @@ declare global {
|
|
|
484
490
|
apiId: string;
|
|
485
491
|
params?: { key: string; value?: string }[] | null;
|
|
486
492
|
}[];
|
|
487
|
-
}
|
|
493
|
+
},
|
|
488
494
|
): IGlassExtensionInvokeResponse<void>;
|
|
489
495
|
/** 批量更新rule的本地数据 */
|
|
490
496
|
saveExamples(
|
|
@@ -496,12 +502,12 @@ declare global {
|
|
|
496
502
|
name?: string;
|
|
497
503
|
statusCode?: number;
|
|
498
504
|
status?: boolean;
|
|
499
|
-
}[]
|
|
505
|
+
}[],
|
|
500
506
|
): IGlassExtensionInvokeResponse<void>;
|
|
501
507
|
/** 注册菜单项 */
|
|
502
508
|
registerMenu(
|
|
503
509
|
id: string,
|
|
504
|
-
options: MenuItem
|
|
510
|
+
options: MenuItem,
|
|
505
511
|
): IGlassExtensionInvokeResponse<void>;
|
|
506
512
|
/** 移除菜单 */
|
|
507
513
|
unregisterMenu(id: string): IGlassExtensionInvokeResponse<void>;
|
|
@@ -523,14 +529,14 @@ declare global {
|
|
|
523
529
|
closeProgress(): IGlassExtensionInvokeResponse<void>;
|
|
524
530
|
|
|
525
531
|
transformDocToJsonSchema(
|
|
526
|
-
doc: DocFullSchema
|
|
532
|
+
doc: DocFullSchema,
|
|
527
533
|
): IGlassExtensionInvokeResponse<JSONSchema>;
|
|
528
534
|
genDataFromDocSchema(
|
|
529
|
-
doc: DocFullSchema
|
|
535
|
+
doc: DocFullSchema,
|
|
530
536
|
): IGlassExtensionInvokeResponse<Record<string, any>>;
|
|
531
537
|
|
|
532
538
|
postMessage(
|
|
533
|
-
message: Partial<NetLog
|
|
539
|
+
message: Partial<NetLog>,
|
|
534
540
|
): IGlassExtensionInvokeResponse<void>;
|
|
535
541
|
openBrowserWindow(browserWindowOptions: {
|
|
536
542
|
width?: number;
|