@lark-project/js-sdk 2.0.0-alpha.3 → 2.0.1-alpha.0

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 CHANGED
@@ -244,9 +244,9 @@ _a11 = IMPL_KEY;
244
244
  */
245
245
  Modal[_a11] = "modal";
246
246
 
247
- // src/biz/Utils.ts
247
+ // src/biz/RichTextEditor.ts
248
248
  var _a12;
249
- var Utils = class extends BaseModel {
249
+ var RichTextEditor = class extends BaseModel {
250
250
  /**
251
251
  * @internal
252
252
  */
@@ -258,7 +258,23 @@ _a12 = IMPL_KEY;
258
258
  /**
259
259
  * @internal
260
260
  */
261
- Utils[_a12] = "utils";
261
+ RichTextEditor[_a12] = "richTextEditor";
262
+
263
+ // src/biz/Utils.ts
264
+ var _a13;
265
+ var Utils = class extends BaseModel {
266
+ /**
267
+ * @internal
268
+ */
269
+ static load() {
270
+ throw new Error("not implemented");
271
+ }
272
+ };
273
+ _a13 = IMPL_KEY;
274
+ /**
275
+ * @internal
276
+ */
277
+ Utils[_a13] = "utils";
262
278
 
263
279
  // src/client.ts
264
280
  function getImplClass(decl, impls) {
@@ -366,7 +382,7 @@ var SDKClient = _SDKClient;
366
382
  /**
367
383
  * SDK 版本号
368
384
  */
369
- SDKClient.version = "2.0.0-alpha.3";
385
+ SDKClient.version = "2.0.1-alpha.0";
370
386
 
371
387
  // src/types/biz.ts
372
388
  var AttributeType = /* @__PURE__ */ ((AttributeType2) => {
@@ -522,6 +538,7 @@ export {
522
538
  NodeStatus,
523
539
  NotFoundError,
524
540
  OutOfLimitError,
541
+ RichTextEditor,
525
542
  SDKClient,
526
543
  Space,
527
544
  Storage,
package/dist/lib/index.js CHANGED
@@ -67,6 +67,7 @@ __export(src_exports, {
67
67
  NodeStatus: () => NodeStatus,
68
68
  NotFoundError: () => NotFoundError,
69
69
  OutOfLimitError: () => OutOfLimitError,
70
+ RichTextEditor: () => RichTextEditor,
70
71
  SDKClient: () => SDKClient,
71
72
  Space: () => Space,
72
73
  Storage: () => Storage,
@@ -294,9 +295,9 @@ _a11 = IMPL_KEY;
294
295
  */
295
296
  Modal[_a11] = "modal";
296
297
 
297
- // src/biz/Utils.ts
298
+ // src/biz/RichTextEditor.ts
298
299
  var _a12;
299
- var Utils = class extends BaseModel {
300
+ var RichTextEditor = class extends BaseModel {
300
301
  /**
301
302
  * @internal
302
303
  */
@@ -308,7 +309,23 @@ _a12 = IMPL_KEY;
308
309
  /**
309
310
  * @internal
310
311
  */
311
- Utils[_a12] = "utils";
312
+ RichTextEditor[_a12] = "richTextEditor";
313
+
314
+ // src/biz/Utils.ts
315
+ var _a13;
316
+ var Utils = class extends BaseModel {
317
+ /**
318
+ * @internal
319
+ */
320
+ static load() {
321
+ throw new Error("not implemented");
322
+ }
323
+ };
324
+ _a13 = IMPL_KEY;
325
+ /**
326
+ * @internal
327
+ */
328
+ Utils[_a13] = "utils";
312
329
 
313
330
  // src/client.ts
314
331
  function getImplClass(decl, impls) {
@@ -416,7 +433,7 @@ var SDKClient = _SDKClient;
416
433
  /**
417
434
  * SDK 版本号
418
435
  */
419
- SDKClient.version = "2.0.0-alpha.3";
436
+ SDKClient.version = "2.0.1-alpha.0";
420
437
 
421
438
  // src/types/biz.ts
422
439
  var AttributeType = /* @__PURE__ */ ((AttributeType2) => {
@@ -573,6 +590,7 @@ var src_default = SDKClient;
573
590
  NodeStatus,
574
591
  NotFoundError,
575
592
  OutOfLimitError,
593
+ RichTextEditor,
576
594
  SDKClient,
577
595
  Space,
578
596
  Storage,
@@ -1006,7 +1006,7 @@ declare abstract class Modal extends BaseModel {
1006
1006
  * @param options
1007
1007
  * @param callback
1008
1008
  * confirmed 点击了确认
1009
- * conceled 点击了取消
1009
+ * canceled 点击了取消
1010
1010
  */
1011
1011
  abstract show(options: string | ModalOptions, callback: (result: {
1012
1012
  confirmed: boolean;
@@ -1014,6 +1014,55 @@ declare abstract class Modal extends BaseModel {
1014
1014
  }) => void): Promise<void>;
1015
1015
  }
1016
1016
 
1017
+ /**
1018
+ * RichTextEditor 配置
1019
+ */
1020
+ interface RichTextEditorOptions {
1021
+ /**
1022
+ * 编辑器标题,仅用于展示
1023
+ */
1024
+ title?: string;
1025
+ /**
1026
+ * 富文本内容
1027
+ */
1028
+ defaultValue?: string;
1029
+ /**
1030
+ * 编辑器空占位符
1031
+ */
1032
+ placeholder?: string;
1033
+ /**
1034
+ * 是否可编辑,默认 true
1035
+ */
1036
+ editable?: boolean;
1037
+ }
1038
+ /**
1039
+ * @public
1040
+ * RichTextEditor 用于富文本的编辑
1041
+ */
1042
+ declare abstract class RichTextEditor extends BaseModel {
1043
+ /**
1044
+ * @internal
1045
+ */
1046
+ protected static [IMPL_KEY]: string;
1047
+ /**
1048
+ * @internal
1049
+ */
1050
+ private static load;
1051
+ /**
1052
+ * 打开富文本编辑器
1053
+ * @param options
1054
+ * @param callback
1055
+ * confirmed 点击了确认
1056
+ * canceled 点击了取消
1057
+ * nextValue 当点击确认时,返回编辑器内最新的内容,否则为 undefined
1058
+ */
1059
+ abstract show(options: RichTextEditorOptions, callback: (result: {
1060
+ confirmed: boolean;
1061
+ canceled: boolean;
1062
+ nextValue?: string;
1063
+ }) => void): Promise<void>;
1064
+ }
1065
+
1017
1066
  /**
1018
1067
  * @mobile
1019
1068
  * @public
@@ -1194,4 +1243,4 @@ declare class InvalidParamsError extends CustomError {
1194
1243
  * @packageDocumentation
1195
1244
  */
1196
1245
 
1197
- export { ActionSheet, ActionSheetOptions, AttributeType, BizLine, BriefField, BriefNode, BriefSpace, BriefTemplate, BriefView, BriefWorkItem, BriefWorkObject, ButtonFeatureContext, ButtonScene, Clipboard, ColorScheme, Context, ControlFeatureContext, Field, FieldType, FlowMode, IMPL_KEY, IPluginCustomBuildConfig, IntegrationFeatureContext, InterceptionEvent, InterceptionFeatureContext, InternalError, InvalidParamsError, Language, MEEGO_BIZ_HUB, Modal, ModalOptions, Navigation, NoAuthError, NodeStatus, NotFoundError, OutOfLimitError, PageFeatureContext, Role, RoleOwners, SDKClient, SDKClientOptions, Space, Storage, TabFeatureContext, Toast, ToastOptions, User, Utils, ViewFeatureContext, WorkItem, WorkItemCreateFormPreset, WorkObject, SDKClient as default, unwatch };
1246
+ export { ActionSheet, ActionSheetOptions, AttributeType, BizLine, BriefField, BriefNode, BriefSpace, BriefTemplate, BriefView, BriefWorkItem, BriefWorkObject, ButtonFeatureContext, ButtonScene, Clipboard, ColorScheme, Context, ControlFeatureContext, Field, FieldType, FlowMode, IMPL_KEY, IPluginCustomBuildConfig, IntegrationFeatureContext, InterceptionEvent, InterceptionFeatureContext, InternalError, InvalidParamsError, Language, MEEGO_BIZ_HUB, Modal, ModalOptions, Navigation, NoAuthError, NodeStatus, NotFoundError, OutOfLimitError, PageFeatureContext, RichTextEditor, RichTextEditorOptions, Role, RoleOwners, SDKClient, SDKClientOptions, Space, Storage, TabFeatureContext, Toast, ToastOptions, User, Utils, ViewFeatureContext, WorkItem, WorkItemCreateFormPreset, WorkObject, SDKClient as default, unwatch };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lark-project/js-sdk",
3
- "version": "2.0.0-alpha.3",
3
+ "version": "2.0.1-alpha.0",
4
4
  "runtimeMinVersions": {
5
5
  "web": "2.1.0",
6
6
  "mobile": "1.1.0"