@lark-project/js-sdk 2.0.1-alpha.4 → 2.0.1-alpha.6
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/es/index.js +25 -25
- package/dist/lib/index.js +27 -27
- package/dist/types/index.d.ts +9 -9
- package/package.json +1 -1
package/dist/es/index.js
CHANGED
|
@@ -276,9 +276,9 @@ _a13 = IMPL_KEY;
|
|
|
276
276
|
*/
|
|
277
277
|
Utils[_a13] = "utils";
|
|
278
278
|
|
|
279
|
-
// src/features/
|
|
279
|
+
// src/features/Intercept.ts
|
|
280
280
|
var _a14;
|
|
281
|
-
var
|
|
281
|
+
var Intercept = class extends BaseModel {
|
|
282
282
|
/**
|
|
283
283
|
* 加载数据
|
|
284
284
|
*/
|
|
@@ -290,7 +290,7 @@ _a14 = IMPL_KEY;
|
|
|
290
290
|
/**
|
|
291
291
|
* @internal
|
|
292
292
|
*/
|
|
293
|
-
|
|
293
|
+
Intercept[_a14] = "Intercept";
|
|
294
294
|
|
|
295
295
|
// src/features/ContainerModal.ts
|
|
296
296
|
var _a15;
|
|
@@ -325,8 +325,8 @@ var _SDKClient = class {
|
|
|
325
325
|
/**
|
|
326
326
|
* 拦截事件点位容器特有能力
|
|
327
327
|
*/
|
|
328
|
-
get
|
|
329
|
-
return getImplValue(
|
|
328
|
+
get intercept() {
|
|
329
|
+
return getImplValue(Intercept, this._meegoBizHub);
|
|
330
330
|
}
|
|
331
331
|
/**
|
|
332
332
|
* 应用导航
|
|
@@ -432,7 +432,7 @@ var SDKClient = _SDKClient;
|
|
|
432
432
|
/**
|
|
433
433
|
* SDK 版本号
|
|
434
434
|
*/
|
|
435
|
-
SDKClient.version = "2.0.1-alpha.
|
|
435
|
+
SDKClient.version = "2.0.1-alpha.6";
|
|
436
436
|
|
|
437
437
|
// src/types/biz.ts
|
|
438
438
|
var AttributeType = /* @__PURE__ */ ((AttributeType2) => {
|
|
@@ -485,23 +485,23 @@ var ButtonScene = /* @__PURE__ */ ((ButtonScene2) => {
|
|
|
485
485
|
ButtonScene2[ButtonScene2["workItemNode"] = 4] = "workItemNode";
|
|
486
486
|
return ButtonScene2;
|
|
487
487
|
})(ButtonScene || {});
|
|
488
|
-
var
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
return
|
|
504
|
-
})(
|
|
488
|
+
var InterceptEvent = /* @__PURE__ */ ((InterceptEvent2) => {
|
|
489
|
+
InterceptEvent2[InterceptEvent2["CreateWorkItem"] = 1001] = "CreateWorkItem";
|
|
490
|
+
InterceptEvent2[InterceptEvent2["DeleteWorkItem"] = 1002] = "DeleteWorkItem";
|
|
491
|
+
InterceptEvent2[InterceptEvent2["BatchDeleteWorkItem"] = 1003] = "BatchDeleteWorkItem";
|
|
492
|
+
InterceptEvent2[InterceptEvent2["RecoveryWorkItem"] = 1004] = "RecoveryWorkItem";
|
|
493
|
+
InterceptEvent2[InterceptEvent2["AbortWorkItem"] = 1005] = "AbortWorkItem";
|
|
494
|
+
InterceptEvent2[InterceptEvent2["UpgradeTemplate"] = 1006] = "UpgradeTemplate";
|
|
495
|
+
InterceptEvent2[InterceptEvent2["BatchUpgradeTemplate"] = 1007] = "BatchUpgradeTemplate";
|
|
496
|
+
InterceptEvent2[InterceptEvent2["ExportWorkItem"] = 1008] = "ExportWorkItem";
|
|
497
|
+
InterceptEvent2[InterceptEvent2["FinishNode"] = 2001] = "FinishNode";
|
|
498
|
+
InterceptEvent2[InterceptEvent2["DeleteNode"] = 2002] = "DeleteNode";
|
|
499
|
+
InterceptEvent2[InterceptEvent2["RecoveryNode"] = 2003] = "RecoveryNode";
|
|
500
|
+
InterceptEvent2[InterceptEvent2["RollBackNode"] = 2004] = "RollBackNode";
|
|
501
|
+
InterceptEvent2[InterceptEvent2["EditSchedule"] = 2005] = "EditSchedule";
|
|
502
|
+
InterceptEvent2[InterceptEvent2["UpdateState"] = 3001] = "UpdateState";
|
|
503
|
+
return InterceptEvent2;
|
|
504
|
+
})(InterceptEvent || {});
|
|
505
505
|
|
|
506
506
|
// src/errors/CustomError.ts
|
|
507
507
|
var CustomError = class extends Error {
|
|
@@ -579,8 +579,8 @@ export {
|
|
|
579
579
|
FieldType,
|
|
580
580
|
FlowMode,
|
|
581
581
|
IMPL_KEY,
|
|
582
|
-
|
|
583
|
-
|
|
582
|
+
Intercept,
|
|
583
|
+
InterceptEvent,
|
|
584
584
|
InternalError,
|
|
585
585
|
InvalidParamsError,
|
|
586
586
|
MEEGO_BIZ_HUB,
|
package/dist/lib/index.js
CHANGED
|
@@ -58,8 +58,8 @@ __export(src_exports, {
|
|
|
58
58
|
FieldType: () => FieldType,
|
|
59
59
|
FlowMode: () => FlowMode,
|
|
60
60
|
IMPL_KEY: () => IMPL_KEY,
|
|
61
|
-
|
|
62
|
-
|
|
61
|
+
Intercept: () => Intercept,
|
|
62
|
+
InterceptEvent: () => InterceptEvent,
|
|
63
63
|
InternalError: () => InternalError,
|
|
64
64
|
InvalidParamsError: () => InvalidParamsError,
|
|
65
65
|
MEEGO_BIZ_HUB: () => MEEGO_BIZ_HUB,
|
|
@@ -329,9 +329,9 @@ _a13 = IMPL_KEY;
|
|
|
329
329
|
*/
|
|
330
330
|
Utils[_a13] = "utils";
|
|
331
331
|
|
|
332
|
-
// src/features/
|
|
332
|
+
// src/features/Intercept.ts
|
|
333
333
|
var _a14;
|
|
334
|
-
var
|
|
334
|
+
var Intercept = class extends BaseModel {
|
|
335
335
|
/**
|
|
336
336
|
* 加载数据
|
|
337
337
|
*/
|
|
@@ -343,7 +343,7 @@ _a14 = IMPL_KEY;
|
|
|
343
343
|
/**
|
|
344
344
|
* @internal
|
|
345
345
|
*/
|
|
346
|
-
|
|
346
|
+
Intercept[_a14] = "Intercept";
|
|
347
347
|
|
|
348
348
|
// src/features/ContainerModal.ts
|
|
349
349
|
var _a15;
|
|
@@ -378,8 +378,8 @@ var _SDKClient = class {
|
|
|
378
378
|
/**
|
|
379
379
|
* 拦截事件点位容器特有能力
|
|
380
380
|
*/
|
|
381
|
-
get
|
|
382
|
-
return getImplValue(
|
|
381
|
+
get intercept() {
|
|
382
|
+
return getImplValue(Intercept, this._meegoBizHub);
|
|
383
383
|
}
|
|
384
384
|
/**
|
|
385
385
|
* 应用导航
|
|
@@ -485,7 +485,7 @@ var SDKClient = _SDKClient;
|
|
|
485
485
|
/**
|
|
486
486
|
* SDK 版本号
|
|
487
487
|
*/
|
|
488
|
-
SDKClient.version = "2.0.1-alpha.
|
|
488
|
+
SDKClient.version = "2.0.1-alpha.6";
|
|
489
489
|
|
|
490
490
|
// src/types/biz.ts
|
|
491
491
|
var AttributeType = /* @__PURE__ */ ((AttributeType2) => {
|
|
@@ -538,23 +538,23 @@ var ButtonScene = /* @__PURE__ */ ((ButtonScene2) => {
|
|
|
538
538
|
ButtonScene2[ButtonScene2["workItemNode"] = 4] = "workItemNode";
|
|
539
539
|
return ButtonScene2;
|
|
540
540
|
})(ButtonScene || {});
|
|
541
|
-
var
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
return
|
|
557
|
-
})(
|
|
541
|
+
var InterceptEvent = /* @__PURE__ */ ((InterceptEvent2) => {
|
|
542
|
+
InterceptEvent2[InterceptEvent2["CreateWorkItem"] = 1001] = "CreateWorkItem";
|
|
543
|
+
InterceptEvent2[InterceptEvent2["DeleteWorkItem"] = 1002] = "DeleteWorkItem";
|
|
544
|
+
InterceptEvent2[InterceptEvent2["BatchDeleteWorkItem"] = 1003] = "BatchDeleteWorkItem";
|
|
545
|
+
InterceptEvent2[InterceptEvent2["RecoveryWorkItem"] = 1004] = "RecoveryWorkItem";
|
|
546
|
+
InterceptEvent2[InterceptEvent2["AbortWorkItem"] = 1005] = "AbortWorkItem";
|
|
547
|
+
InterceptEvent2[InterceptEvent2["UpgradeTemplate"] = 1006] = "UpgradeTemplate";
|
|
548
|
+
InterceptEvent2[InterceptEvent2["BatchUpgradeTemplate"] = 1007] = "BatchUpgradeTemplate";
|
|
549
|
+
InterceptEvent2[InterceptEvent2["ExportWorkItem"] = 1008] = "ExportWorkItem";
|
|
550
|
+
InterceptEvent2[InterceptEvent2["FinishNode"] = 2001] = "FinishNode";
|
|
551
|
+
InterceptEvent2[InterceptEvent2["DeleteNode"] = 2002] = "DeleteNode";
|
|
552
|
+
InterceptEvent2[InterceptEvent2["RecoveryNode"] = 2003] = "RecoveryNode";
|
|
553
|
+
InterceptEvent2[InterceptEvent2["RollBackNode"] = 2004] = "RollBackNode";
|
|
554
|
+
InterceptEvent2[InterceptEvent2["EditSchedule"] = 2005] = "EditSchedule";
|
|
555
|
+
InterceptEvent2[InterceptEvent2["UpdateState"] = 3001] = "UpdateState";
|
|
556
|
+
return InterceptEvent2;
|
|
557
|
+
})(InterceptEvent || {});
|
|
558
558
|
|
|
559
559
|
// src/errors/CustomError.ts
|
|
560
560
|
var CustomError = class extends Error {
|
|
@@ -633,8 +633,8 @@ var src_default = SDKClient;
|
|
|
633
633
|
FieldType,
|
|
634
634
|
FlowMode,
|
|
635
635
|
IMPL_KEY,
|
|
636
|
-
|
|
637
|
-
|
|
636
|
+
Intercept,
|
|
637
|
+
InterceptEvent,
|
|
638
638
|
InternalError,
|
|
639
639
|
InvalidParamsError,
|
|
640
640
|
MEEGO_BIZ_HUB,
|
package/dist/types/index.d.ts
CHANGED
|
@@ -405,7 +405,7 @@ interface ControlFeatureContext {
|
|
|
405
405
|
/**
|
|
406
406
|
* 拦截事件类型
|
|
407
407
|
*/
|
|
408
|
-
declare enum
|
|
408
|
+
declare enum InterceptEvent {
|
|
409
409
|
/** 创建工作项 */
|
|
410
410
|
CreateWorkItem = 1001,
|
|
411
411
|
/** 删除工作项 */
|
|
@@ -439,9 +439,9 @@ declare enum InterceptionEvent {
|
|
|
439
439
|
* 拦截构成
|
|
440
440
|
* 用于拦截用户行为,包括拦截位置、触发规则和提示等相关配置
|
|
441
441
|
*/
|
|
442
|
-
interface
|
|
442
|
+
interface InterceptFeatureContext<T> {
|
|
443
443
|
message: string;
|
|
444
|
-
eventType:
|
|
444
|
+
eventType: InterceptEvent;
|
|
445
445
|
workItems: Array<BriefWorkItem>;
|
|
446
446
|
customData: T;
|
|
447
447
|
}
|
|
@@ -1125,7 +1125,7 @@ declare abstract class Utils extends BaseModel {
|
|
|
1125
1125
|
* @public
|
|
1126
1126
|
* 拦截事件模态框
|
|
1127
1127
|
*/
|
|
1128
|
-
declare abstract class
|
|
1128
|
+
declare abstract class Intercept extends BaseModel {
|
|
1129
1129
|
/**
|
|
1130
1130
|
* @internal
|
|
1131
1131
|
*/
|
|
@@ -1133,11 +1133,11 @@ declare abstract class Interception extends BaseModel {
|
|
|
1133
1133
|
/**
|
|
1134
1134
|
* 加载数据
|
|
1135
1135
|
*/
|
|
1136
|
-
static load(): Promise<
|
|
1136
|
+
static load(): Promise<Intercept>;
|
|
1137
1137
|
/**
|
|
1138
1138
|
* 获取当前触发的拦截事件上下文
|
|
1139
1139
|
*/
|
|
1140
|
-
abstract
|
|
1140
|
+
abstract getEventCtx<T = any>(): Promise<InterceptFeatureContext<T>>;
|
|
1141
1141
|
}
|
|
1142
1142
|
|
|
1143
1143
|
/**
|
|
@@ -1156,7 +1156,7 @@ declare abstract class ContainerModal extends BaseModel {
|
|
|
1156
1156
|
/**
|
|
1157
1157
|
* 关闭插件当前激活的容器模态框
|
|
1158
1158
|
*/
|
|
1159
|
-
abstract
|
|
1159
|
+
abstract closeModal: Promise<void>;
|
|
1160
1160
|
}
|
|
1161
1161
|
|
|
1162
1162
|
/**
|
|
@@ -1183,7 +1183,7 @@ declare class SDKClient {
|
|
|
1183
1183
|
/**
|
|
1184
1184
|
* 拦截事件点位容器特有能力
|
|
1185
1185
|
*/
|
|
1186
|
-
get
|
|
1186
|
+
get intercept(): Intercept;
|
|
1187
1187
|
/**
|
|
1188
1188
|
* 应用导航
|
|
1189
1189
|
*/
|
|
@@ -1318,4 +1318,4 @@ declare class InvalidParamsError extends CustomError {
|
|
|
1318
1318
|
* @packageDocumentation
|
|
1319
1319
|
*/
|
|
1320
1320
|
|
|
1321
|
-
export { ActionSheet, ActionSheetOptions, AttributeType, BizLine, BriefField, BriefNode, BriefSpace, BriefTemplate, BriefView, BriefWorkItem, BriefWorkObject, ButtonFeatureContext, ButtonScene, Clipboard, ColorScheme, ContainerModal, Context, ControlFeatureContext, Field, FieldType, FlowMode, IMPL_KEY, IPluginCustomBuildConfig, IntegrationFeatureContext,
|
|
1321
|
+
export { ActionSheet, ActionSheetOptions, AttributeType, BizLine, BriefField, BriefNode, BriefSpace, BriefTemplate, BriefView, BriefWorkItem, BriefWorkObject, ButtonFeatureContext, ButtonScene, Clipboard, ColorScheme, ContainerModal, Context, ControlFeatureContext, Field, FieldType, FlowMode, IMPL_KEY, IPluginCustomBuildConfig, IntegrationFeatureContext, Intercept, InterceptEvent, InterceptFeatureContext, InternalError, InvalidParamsError, Language, MEEGO_BIZ_HUB, Modal, ModalOptions, Navigation, NoAuthError, NodeStatus, NotFoundError, OutOfLimitError, PageFeatureContext, RichTextEditor, RichTextEditorContent, RichTextEditorOptions, Role, RoleOwners, SDKClient, SDKClientOptions, Space, Storage, TabFeatureContext, Toast, ToastOptions, User, Utils, ViewFeatureContext, WorkItem, WorkItemCreateFormPreset, WorkObject, SDKClient as default, unwatch };
|