@luminocity/lemonate-gateway 8.2.26 → 8.2.28
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/index.d.ts +75 -50
- package/dist/lemonate-gateway.cjs.js +4 -4
- package/dist/lemonate-gateway.cjs.js.map +1 -1
- package/dist/lemonate-gateway.esm.js +4 -4
- package/dist/lemonate-gateway.esm.js.map +1 -1
- package/dist/lemonate-gateway.umd.js +4 -4
- package/dist/lemonate-gateway.umd.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -3,16 +3,10 @@ import * as axios from 'axios';
|
|
|
3
3
|
import { AxiosInstance, ResponseType } from 'axios';
|
|
4
4
|
import WebSocket from 'isomorphic-ws';
|
|
5
5
|
import FormData from 'form-data';
|
|
6
|
-
import { CustomField as CustomField$1, CustomFieldDefinition as CustomFieldDefinition$1 } from '@/repo/CustomField';
|
|
7
6
|
import { WebsocketProvider } from 'y-websocket';
|
|
8
7
|
import * as awarenessProtocol from 'y-protocols/awareness';
|
|
9
|
-
import
|
|
10
|
-
import { ItemCopier } from '@/ItemCopier';
|
|
11
|
-
import { ExecutableExporter } from '@/ExecutableExporter';
|
|
8
|
+
import * as Y from 'yjs';
|
|
12
9
|
import { Buffer as Buffer$1 } from 'buffer';
|
|
13
|
-
import { ScriptItem as ScriptItem$1, Script as Script$1 } from '@/repo/Script';
|
|
14
|
-
import { ScriptField as ScriptField$1 } from '@/repo/ScriptField';
|
|
15
|
-
import { TemplateEntry as TemplateEntry$1 } from '@/repo/TemplateEntry';
|
|
16
10
|
|
|
17
11
|
declare class Snapshot {
|
|
18
12
|
id: string;
|
|
@@ -681,7 +675,7 @@ declare class JobManager {
|
|
|
681
675
|
jobs: Map<string, JobEntry>;
|
|
682
676
|
constructor(apiClient: any);
|
|
683
677
|
getJobs(): JobEntry[];
|
|
684
|
-
execute(type: string, elements: any[], parameters: any[], progressCallback
|
|
678
|
+
execute(type: string, elements: any[], parameters: any[], progressCallback?: Function | undefined, requiredParameters?: any): Promise<JobState>;
|
|
685
679
|
}
|
|
686
680
|
|
|
687
681
|
type PublishedVersion = {
|
|
@@ -955,6 +949,34 @@ declare class Field extends Snapshotable {
|
|
|
955
949
|
rollbackFromSnapshot(snapshot: Snapshot): void;
|
|
956
950
|
}
|
|
957
951
|
|
|
952
|
+
type CustomFieldDefinition = {
|
|
953
|
+
name: string;
|
|
954
|
+
defaultValue: any;
|
|
955
|
+
type: string;
|
|
956
|
+
};
|
|
957
|
+
declare class CustomField extends Snapshotable {
|
|
958
|
+
id: string;
|
|
959
|
+
name: string | undefined;
|
|
960
|
+
displayName: string | undefined;
|
|
961
|
+
value: any;
|
|
962
|
+
type: string | undefined;
|
|
963
|
+
datatype: string | undefined;
|
|
964
|
+
linkableTypes: string[];
|
|
965
|
+
order: number;
|
|
966
|
+
constructor(name?: string | undefined, value?: any | undefined, item?: PreparedItem | undefined);
|
|
967
|
+
getId(): string;
|
|
968
|
+
setName(name: string | undefined): void;
|
|
969
|
+
setType(name: string): void;
|
|
970
|
+
setOrder(order: number): void;
|
|
971
|
+
clone(fieldOverrides?: Map<string, string>): CustomField;
|
|
972
|
+
clearDefinition(): void;
|
|
973
|
+
setDefinition(def: any): void;
|
|
974
|
+
_toBoolean(value: any): any;
|
|
975
|
+
_updateDisplayName(): void;
|
|
976
|
+
createSnapshot(): Snapshot;
|
|
977
|
+
rollbackFromSnapshot(snapshot: Snapshot): void;
|
|
978
|
+
}
|
|
979
|
+
|
|
958
980
|
declare class PreparedItem extends AggregatedItem {
|
|
959
981
|
links?: {
|
|
960
982
|
to: string;
|
|
@@ -966,7 +988,7 @@ declare class PreparedItem extends AggregatedItem {
|
|
|
966
988
|
isDirty: boolean;
|
|
967
989
|
fieldInstances: Field[];
|
|
968
990
|
userFieldInstances: Field[];
|
|
969
|
-
customFieldInstances: CustomField
|
|
991
|
+
customFieldInstances: CustomField[];
|
|
970
992
|
packageContent?: PreparedItem;
|
|
971
993
|
packageType?: string;
|
|
972
994
|
public: boolean;
|
|
@@ -978,8 +1000,8 @@ declare class PreparedItem extends AggregatedItem {
|
|
|
978
1000
|
resultingAcl?: Acl;
|
|
979
1001
|
userData: any;
|
|
980
1002
|
constructor(data: any);
|
|
981
|
-
createCustomFieldInstances(definitions: CustomFieldDefinition
|
|
982
|
-
addCustomField(customField: CustomField
|
|
1003
|
+
createCustomFieldInstances(definitions: CustomFieldDefinition[]): void;
|
|
1004
|
+
addCustomField(customField: CustomField): void;
|
|
983
1005
|
markDirty(): void;
|
|
984
1006
|
makeIdsUnique(): void;
|
|
985
1007
|
clone(makeIdsUnique?: boolean): PreparedItem;
|
|
@@ -1273,6 +1295,9 @@ declare global {
|
|
|
1273
1295
|
}
|
|
1274
1296
|
}
|
|
1275
1297
|
|
|
1298
|
+
declare class CollabDocument extends Y.Doc {
|
|
1299
|
+
}
|
|
1300
|
+
|
|
1276
1301
|
type CollabUser = {
|
|
1277
1302
|
id: string;
|
|
1278
1303
|
key: number;
|
|
@@ -1305,6 +1330,33 @@ declare class Collab {
|
|
|
1305
1330
|
endCollaboration(): void;
|
|
1306
1331
|
}
|
|
1307
1332
|
|
|
1333
|
+
type CopyElement = {
|
|
1334
|
+
_id: string;
|
|
1335
|
+
isFolder: boolean;
|
|
1336
|
+
};
|
|
1337
|
+
type CopyElementTestResult = {
|
|
1338
|
+
_id: string;
|
|
1339
|
+
name: string | undefined;
|
|
1340
|
+
isFolder: boolean;
|
|
1341
|
+
conflicted: boolean;
|
|
1342
|
+
conflictedItemId: string | undefined;
|
|
1343
|
+
data: any;
|
|
1344
|
+
};
|
|
1345
|
+
declare class ItemCopier {
|
|
1346
|
+
apiClient: ApiClient;
|
|
1347
|
+
constructor(apiClient: ApiClient);
|
|
1348
|
+
testCopyItems(elements: CopyElement[], targetFolderId: string): Promise<CopyElementTestResult[]>;
|
|
1349
|
+
copyItems(elements: CopyElementTestResult[], targetFolderId: string, deepCopy?: boolean, overwrite?: boolean): Promise<ItemCopyResult[]>;
|
|
1350
|
+
}
|
|
1351
|
+
|
|
1352
|
+
type Platform = "windows" | "linux" | "macos";
|
|
1353
|
+
declare class ExecutableExporter {
|
|
1354
|
+
apiClient: ApiClient;
|
|
1355
|
+
jobManager: JobManager;
|
|
1356
|
+
constructor(apiClient: ApiClient);
|
|
1357
|
+
executeExport(packageId: string, platform: Platform, destinationFolderId: string, engineVersion: string): Promise<void>;
|
|
1358
|
+
}
|
|
1359
|
+
|
|
1308
1360
|
/**
|
|
1309
1361
|
* @fileoverview ApiClient class for handling API interactions with the Lumino cloud service.
|
|
1310
1362
|
* @module ApiClient
|
|
@@ -1333,6 +1385,7 @@ type ApiClientOptions = {
|
|
|
1333
1385
|
storageSizeMib: number;
|
|
1334
1386
|
requestClientId: string | null;
|
|
1335
1387
|
debug: boolean;
|
|
1388
|
+
withCollaboration: boolean;
|
|
1336
1389
|
};
|
|
1337
1390
|
type ItemCopyResult = {
|
|
1338
1391
|
original: string;
|
|
@@ -1373,7 +1426,7 @@ declare class ApiClient extends EventEmitter {
|
|
|
1373
1426
|
attachmentCache: AttachmentCache;
|
|
1374
1427
|
jobManager: JobManager;
|
|
1375
1428
|
serializer: Serializer;
|
|
1376
|
-
collab
|
|
1429
|
+
collab?: Collab;
|
|
1377
1430
|
itemCopier: ItemCopier;
|
|
1378
1431
|
executableExporter: ExecutableExporter;
|
|
1379
1432
|
eventBus: typeof eventBus;
|
|
@@ -1421,7 +1474,7 @@ declare class ApiClient extends EventEmitter {
|
|
|
1421
1474
|
websocketSend(data: string): void;
|
|
1422
1475
|
getItemCopier(): ItemCopier;
|
|
1423
1476
|
getExecutableExporter(): ExecutableExporter;
|
|
1424
|
-
getCollab(): Collab;
|
|
1477
|
+
getCollab(): Collab | undefined;
|
|
1425
1478
|
getCollabUrl(): string;
|
|
1426
1479
|
/**
|
|
1427
1480
|
* Get a new Publisher instance.
|
|
@@ -3980,7 +4033,7 @@ declare class ItemPreparator {
|
|
|
3980
4033
|
setItemFetcher(itemFetcher: Function): void;
|
|
3981
4034
|
setFieldsFromDatatypes(item: PreparedItem): void;
|
|
3982
4035
|
prepare(item: any): Promise<PreparedItem>;
|
|
3983
|
-
createCustomFieldInstances(item: PreparedItem, attributes: Record<string, unknown>, prefix?: string): Promise<CustomField
|
|
4036
|
+
createCustomFieldInstances(item: PreparedItem, attributes: Record<string, unknown>, prefix?: string): Promise<CustomField[]>;
|
|
3984
4037
|
createFieldInstances(item: PreparedItem, fields: any[], attributes: Record<string, unknown>, path: string, attributeSrc: string, doNotFillValues?: boolean): Promise<Field[]>;
|
|
3985
4038
|
getFieldSet(item: PreparedItem, name: string): {
|
|
3986
4039
|
name: string;
|
|
@@ -4342,11 +4395,11 @@ declare class Proxifier {
|
|
|
4342
4395
|
proxyItemField(field: Field, item: any): any;
|
|
4343
4396
|
proxyGraphBlockField(field: Field, block: Block, item: PreparedItem): any;
|
|
4344
4397
|
proxyBlockField(field: Field, block: Block, item: PreparedItem): any;
|
|
4345
|
-
proxyScriptItem(scriptItem: ScriptItem
|
|
4346
|
-
proxyScriptFieldsArray(fields: ScriptField
|
|
4347
|
-
proxyScriptField(field: ScriptField
|
|
4348
|
-
proxyCustomFieldsArray(fields: CustomField
|
|
4349
|
-
proxyCustomField(field: CustomField
|
|
4398
|
+
proxyScriptItem(scriptItem: ScriptItem, script: Script, item: PreparedItem): any;
|
|
4399
|
+
proxyScriptFieldsArray(fields: ScriptField[], script: Script, item: PreparedItem): any[];
|
|
4400
|
+
proxyScriptField(field: ScriptField, script: Script, item: PreparedItem): any;
|
|
4401
|
+
proxyCustomFieldsArray(fields: CustomField[], item: PreparedItem): any[];
|
|
4402
|
+
proxyCustomField(field: CustomField, item: PreparedItem): any;
|
|
4350
4403
|
}
|
|
4351
4404
|
|
|
4352
4405
|
declare const _default: {
|
|
@@ -12254,9 +12307,9 @@ declare class TemplateFactory {
|
|
|
12254
12307
|
private static _instance;
|
|
12255
12308
|
static get instance(): TemplateFactory;
|
|
12256
12309
|
private _existsTemplate;
|
|
12257
|
-
addTemplates(itemType: string, fieldName: string, templates: TemplateEntry
|
|
12258
|
-
getTemplate(itemType: string, fieldName: string, templateName: string): TemplateEntry
|
|
12259
|
-
getTemplates(itemType: string, fieldName: string): TemplateEntry
|
|
12310
|
+
addTemplates(itemType: string, fieldName: string, templates: TemplateEntry[]): void;
|
|
12311
|
+
getTemplate(itemType: string, fieldName: string, templateName: string): TemplateEntry | undefined;
|
|
12312
|
+
getTemplates(itemType: string, fieldName: string): TemplateEntry[];
|
|
12260
12313
|
}
|
|
12261
12314
|
|
|
12262
12315
|
declare class LinkableItemsCache {
|
|
@@ -12270,33 +12323,5 @@ declare class LinkableItemsCache {
|
|
|
12270
12323
|
loadLinkableItems(item: any, field: Field): Promise<any[] | undefined>;
|
|
12271
12324
|
}
|
|
12272
12325
|
|
|
12273
|
-
type CustomFieldDefinition = {
|
|
12274
|
-
name: string;
|
|
12275
|
-
defaultValue: any;
|
|
12276
|
-
type: string;
|
|
12277
|
-
};
|
|
12278
|
-
declare class CustomField extends Snapshotable {
|
|
12279
|
-
id: string;
|
|
12280
|
-
name: string | undefined;
|
|
12281
|
-
displayName: string | undefined;
|
|
12282
|
-
value: any;
|
|
12283
|
-
type: string | undefined;
|
|
12284
|
-
datatype: string | undefined;
|
|
12285
|
-
linkableTypes: string[];
|
|
12286
|
-
order: number;
|
|
12287
|
-
constructor(name?: string | undefined, value?: any | undefined, item?: PreparedItem | undefined);
|
|
12288
|
-
getId(): string;
|
|
12289
|
-
setName(name: string | undefined): void;
|
|
12290
|
-
setType(name: string): void;
|
|
12291
|
-
setOrder(order: number): void;
|
|
12292
|
-
clone(fieldOverrides?: Map<string, string>): CustomField;
|
|
12293
|
-
clearDefinition(): void;
|
|
12294
|
-
setDefinition(def: any): void;
|
|
12295
|
-
_toBoolean(value: any): any;
|
|
12296
|
-
_updateDisplayName(): void;
|
|
12297
|
-
createSnapshot(): Snapshot;
|
|
12298
|
-
rollbackFromSnapshot(snapshot: Snapshot): void;
|
|
12299
|
-
}
|
|
12300
|
-
|
|
12301
12326
|
export { AccessDeniedException, AggregatedItem, ApiClient, ApiGateway, Block, CustomField, EventEmitter, Field, InvalidArgumentException, InvalidStateException, Item, ItemCache$1 as ItemCache, ItemRepo, ItemVisibility, LinkableItemsCache, LoaderException, Package as PackageTools, PreparedItem, Profiler, Proxifier, ProxyEvent, QuotaExceededException, Script, ScriptField, Snapshot, Storage, Template, TemplateFactory, ThumbCache, UndoManager, eventBus, getDatatypeByName, getDatatypes, hasPermission, profileAsyncBlock, profileBlock, _default as tools, verifyAcl };
|
|
12302
12327
|
export type { Acl, Attachments, BaseBlogArticle, ConversationEntry, CustomFieldDefinition, FolderListingOptions, FolderListingWithOptions, ItemOptions, ItemQueryOptions, ItemQueryWithOptions, ItemWithOptions, JobState, Me, ProgressCallback$1 as ProgressCallback, UserInfo };
|