@supernova-studio/client 0.52.2 → 0.52.3
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.mts +208 -122
- package/dist/index.d.ts +208 -122
- package/dist/index.js +29 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +465 -438
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/api/dto/documentation/approvals.ts +11 -1
- package/src/api/dto/elements/documentation/group-v2.ts +4 -0
- package/src/yjs/version-room/frontend.ts +20 -0
package/dist/index.mjs
CHANGED
|
@@ -5313,74 +5313,81 @@ var DTOGetDocumentationPageAnchorsResponse = z189.object({
|
|
|
5313
5313
|
});
|
|
5314
5314
|
|
|
5315
5315
|
// src/api/dto/documentation/approvals.ts
|
|
5316
|
+
import { z as z190 } from "zod";
|
|
5316
5317
|
var DTODocumentationPageApprovalState = DocumentationPageApproval;
|
|
5318
|
+
var DTODocumentationGroupApprovalState = z190.object({
|
|
5319
|
+
persistentId: z190.string(),
|
|
5320
|
+
groupId: z190.string(),
|
|
5321
|
+
designSystemVersionId: z190.string(),
|
|
5322
|
+
approvalState: DocumentationPageApprovalState
|
|
5323
|
+
});
|
|
5317
5324
|
|
|
5318
5325
|
// src/api/dto/documentation/block.ts
|
|
5319
5326
|
var DTOPageBlockItemV2 = PageBlockItemV2;
|
|
5320
5327
|
|
|
5321
5328
|
// src/api/dto/documentation/documentation-page-snapshot.ts
|
|
5322
|
-
import { z as
|
|
5329
|
+
import { z as z195 } from "zod";
|
|
5323
5330
|
|
|
5324
5331
|
// src/api/dto/elements/documentation/page-v2.ts
|
|
5325
|
-
import { z as
|
|
5332
|
+
import { z as z194 } from "zod";
|
|
5326
5333
|
|
|
5327
5334
|
// src/api/dto/elements/documentation/draft-state.ts
|
|
5328
|
-
import { z as
|
|
5335
|
+
import { z as z192 } from "zod";
|
|
5329
5336
|
|
|
5330
5337
|
// src/api/dto/elements/documentation/item-configuration-v2.ts
|
|
5331
|
-
import { z as
|
|
5338
|
+
import { z as z191 } from "zod";
|
|
5332
5339
|
var DTODocumentationItemHeaderV2 = DocumentationItemHeaderV2;
|
|
5333
|
-
var DTODocumentationItemConfigurationV2 =
|
|
5334
|
-
showSidebar:
|
|
5335
|
-
isPrivate:
|
|
5336
|
-
isHidden:
|
|
5340
|
+
var DTODocumentationItemConfigurationV2 = z191.object({
|
|
5341
|
+
showSidebar: z191.boolean(),
|
|
5342
|
+
isPrivate: z191.boolean(),
|
|
5343
|
+
isHidden: z191.boolean(),
|
|
5337
5344
|
header: DTODocumentationItemHeaderV2
|
|
5338
5345
|
});
|
|
5339
5346
|
|
|
5340
5347
|
// src/api/dto/elements/documentation/draft-state.ts
|
|
5341
|
-
var DTODocumentationDraftChangeType =
|
|
5342
|
-
var DTODocumentationDraftStateCreated =
|
|
5343
|
-
changeType:
|
|
5344
|
-
});
|
|
5345
|
-
var DTODocumentationDraftStateUpdated =
|
|
5346
|
-
changeType:
|
|
5347
|
-
changes:
|
|
5348
|
-
previousTitle:
|
|
5348
|
+
var DTODocumentationDraftChangeType = z192.enum(["Created", "Updated", "Deleted"]);
|
|
5349
|
+
var DTODocumentationDraftStateCreated = z192.object({
|
|
5350
|
+
changeType: z192.literal(DTODocumentationDraftChangeType.enum.Created)
|
|
5351
|
+
});
|
|
5352
|
+
var DTODocumentationDraftStateUpdated = z192.object({
|
|
5353
|
+
changeType: z192.literal(DTODocumentationDraftChangeType.enum.Updated),
|
|
5354
|
+
changes: z192.object({
|
|
5355
|
+
previousTitle: z192.string().optional(),
|
|
5349
5356
|
previousConfiguration: DTODocumentationItemConfigurationV2.optional(),
|
|
5350
|
-
previousContentHash:
|
|
5357
|
+
previousContentHash: z192.string().optional()
|
|
5351
5358
|
})
|
|
5352
5359
|
});
|
|
5353
|
-
var DTODocumentationDraftStateDeleted =
|
|
5354
|
-
changeType:
|
|
5355
|
-
deletedAt:
|
|
5356
|
-
deletedByUserId:
|
|
5360
|
+
var DTODocumentationDraftStateDeleted = z192.object({
|
|
5361
|
+
changeType: z192.literal(DTODocumentationDraftChangeType.enum.Deleted),
|
|
5362
|
+
deletedAt: z192.coerce.date(),
|
|
5363
|
+
deletedByUserId: z192.string()
|
|
5357
5364
|
});
|
|
5358
|
-
var DTODocumentationDraftState =
|
|
5365
|
+
var DTODocumentationDraftState = z192.discriminatedUnion("changeType", [
|
|
5359
5366
|
DTODocumentationDraftStateCreated,
|
|
5360
5367
|
DTODocumentationDraftStateUpdated,
|
|
5361
5368
|
DTODocumentationDraftStateDeleted
|
|
5362
5369
|
]);
|
|
5363
5370
|
|
|
5364
5371
|
// src/api/dto/elements/documentation/metadata.ts
|
|
5365
|
-
import { z as
|
|
5366
|
-
var DTODocumentationPublishMetadata =
|
|
5367
|
-
lastPublishedByUserId:
|
|
5368
|
-
lastPublishedAt:
|
|
5372
|
+
import { z as z193 } from "zod";
|
|
5373
|
+
var DTODocumentationPublishMetadata = z193.object({
|
|
5374
|
+
lastPublishedByUserId: z193.string(),
|
|
5375
|
+
lastPublishedAt: z193.coerce.date()
|
|
5369
5376
|
});
|
|
5370
5377
|
|
|
5371
5378
|
// src/api/dto/elements/documentation/page-v2.ts
|
|
5372
|
-
var DTODocumentationPageV2 =
|
|
5373
|
-
id:
|
|
5374
|
-
persistentId:
|
|
5375
|
-
designSystemVersionId:
|
|
5376
|
-
title:
|
|
5379
|
+
var DTODocumentationPageV2 = z194.object({
|
|
5380
|
+
id: z194.string(),
|
|
5381
|
+
persistentId: z194.string(),
|
|
5382
|
+
designSystemVersionId: z194.string(),
|
|
5383
|
+
title: z194.string(),
|
|
5377
5384
|
configuration: DTODocumentationItemConfigurationV2,
|
|
5378
|
-
shortPersistentId:
|
|
5379
|
-
slug:
|
|
5380
|
-
userSlug:
|
|
5381
|
-
createdAt:
|
|
5382
|
-
updatedAt:
|
|
5383
|
-
path:
|
|
5385
|
+
shortPersistentId: z194.string(),
|
|
5386
|
+
slug: z194.string().optional(),
|
|
5387
|
+
userSlug: z194.string().optional(),
|
|
5388
|
+
createdAt: z194.coerce.date(),
|
|
5389
|
+
updatedAt: z194.coerce.date(),
|
|
5390
|
+
path: z194.string(),
|
|
5384
5391
|
/** Defined when a page has changed since last publish and can be included into a partial publish */
|
|
5385
5392
|
draftState: DTODocumentationDraftState.optional(),
|
|
5386
5393
|
/** Defined if a page was published at least once and contains metadata about last publish */
|
|
@@ -5388,195 +5395,195 @@ var DTODocumentationPageV2 = z193.object({
|
|
|
5388
5395
|
/** Defines the approval state of the documentation page */
|
|
5389
5396
|
approvalState: DTODocumentationPageApprovalState.optional(),
|
|
5390
5397
|
// Backward compatibility
|
|
5391
|
-
type:
|
|
5398
|
+
type: z194.literal("Page")
|
|
5392
5399
|
});
|
|
5393
|
-
var DTOCreateDocumentationPageInputV2 =
|
|
5400
|
+
var DTOCreateDocumentationPageInputV2 = z194.object({
|
|
5394
5401
|
// Identifier
|
|
5395
|
-
persistentId:
|
|
5402
|
+
persistentId: z194.string().uuid(),
|
|
5396
5403
|
// Page properties
|
|
5397
|
-
title:
|
|
5404
|
+
title: z194.string(),
|
|
5398
5405
|
configuration: DTODocumentationItemConfigurationV2.partial().optional(),
|
|
5399
5406
|
// Page placement properties
|
|
5400
|
-
parentPersistentId:
|
|
5401
|
-
afterPersistentId:
|
|
5407
|
+
parentPersistentId: z194.string().uuid(),
|
|
5408
|
+
afterPersistentId: z194.string().uuid().nullish()
|
|
5402
5409
|
});
|
|
5403
|
-
var DTOUpdateDocumentationPageInputV2 =
|
|
5410
|
+
var DTOUpdateDocumentationPageInputV2 = z194.object({
|
|
5404
5411
|
// Identifier of the group to update
|
|
5405
|
-
id:
|
|
5412
|
+
id: z194.string(),
|
|
5406
5413
|
// Page properties
|
|
5407
|
-
title:
|
|
5414
|
+
title: z194.string().optional(),
|
|
5408
5415
|
configuration: DTODocumentationItemConfigurationV2.partial().optional()
|
|
5409
5416
|
});
|
|
5410
|
-
var DTOMoveDocumentationPageInputV2 =
|
|
5417
|
+
var DTOMoveDocumentationPageInputV2 = z194.object({
|
|
5411
5418
|
// Identifier of the group to update
|
|
5412
|
-
id:
|
|
5419
|
+
id: z194.string(),
|
|
5413
5420
|
// Page placement properties
|
|
5414
|
-
parentPersistentId:
|
|
5415
|
-
afterPersistentId:
|
|
5421
|
+
parentPersistentId: z194.string().uuid(),
|
|
5422
|
+
afterPersistentId: z194.string().uuid().nullish()
|
|
5416
5423
|
});
|
|
5417
|
-
var DTODuplicateDocumentationPageInputV2 =
|
|
5424
|
+
var DTODuplicateDocumentationPageInputV2 = z194.object({
|
|
5418
5425
|
// Identifier of the page to duplicate from
|
|
5419
|
-
id:
|
|
5426
|
+
id: z194.string(),
|
|
5420
5427
|
// New page persistent id
|
|
5421
|
-
persistentId:
|
|
5428
|
+
persistentId: z194.string().uuid(),
|
|
5422
5429
|
// Page placement properties
|
|
5423
|
-
parentPersistentId:
|
|
5424
|
-
afterPersistentId:
|
|
5430
|
+
parentPersistentId: z194.string().uuid(),
|
|
5431
|
+
afterPersistentId: z194.string().uuid().nullish()
|
|
5425
5432
|
});
|
|
5426
|
-
var DTODeleteDocumentationPageInputV2 =
|
|
5433
|
+
var DTODeleteDocumentationPageInputV2 = z194.object({
|
|
5427
5434
|
// Identifier
|
|
5428
|
-
id:
|
|
5435
|
+
id: z194.string()
|
|
5429
5436
|
});
|
|
5430
|
-
var DTORestoreDocumentationPageInput =
|
|
5431
|
-
persistentId:
|
|
5432
|
-
snapshotId:
|
|
5437
|
+
var DTORestoreDocumentationPageInput = z194.object({
|
|
5438
|
+
persistentId: z194.string(),
|
|
5439
|
+
snapshotId: z194.string().optional()
|
|
5433
5440
|
});
|
|
5434
|
-
var DTORestoreDocumentationGroupInput =
|
|
5435
|
-
persistentId:
|
|
5436
|
-
snapshotId:
|
|
5441
|
+
var DTORestoreDocumentationGroupInput = z194.object({
|
|
5442
|
+
persistentId: z194.string(),
|
|
5443
|
+
snapshotId: z194.string().optional()
|
|
5437
5444
|
});
|
|
5438
|
-
var DTODocumentationPageApprovalStateChangeInput =
|
|
5439
|
-
persistentId:
|
|
5445
|
+
var DTODocumentationPageApprovalStateChangeInput = z194.object({
|
|
5446
|
+
persistentId: z194.string(),
|
|
5440
5447
|
approvalState: DocumentationPageApprovalState.optional()
|
|
5441
5448
|
});
|
|
5442
5449
|
|
|
5443
5450
|
// src/api/dto/documentation/documentation-page-snapshot.ts
|
|
5444
|
-
var DTODocumentationPageSnapshot =
|
|
5445
|
-
id:
|
|
5446
|
-
designSystemVersionId:
|
|
5447
|
-
createdAt:
|
|
5448
|
-
updatedAt:
|
|
5451
|
+
var DTODocumentationPageSnapshot = z195.object({
|
|
5452
|
+
id: z195.string(),
|
|
5453
|
+
designSystemVersionId: z195.string(),
|
|
5454
|
+
createdAt: z195.string(),
|
|
5455
|
+
updatedAt: z195.string(),
|
|
5449
5456
|
documentationPage: DTODocumentationPageV2,
|
|
5450
|
-
pageContentHash:
|
|
5457
|
+
pageContentHash: z195.string(),
|
|
5451
5458
|
reason: DesignElementSnapshotReason
|
|
5452
5459
|
});
|
|
5453
5460
|
|
|
5454
5461
|
// src/api/dto/documentation/link-preview.ts
|
|
5455
|
-
import { z as
|
|
5456
|
-
var DTODocumentationLinkPreviewResponse =
|
|
5462
|
+
import { z as z196 } from "zod";
|
|
5463
|
+
var DTODocumentationLinkPreviewResponse = z196.object({
|
|
5457
5464
|
linkPreview: DocumentationLinkPreview
|
|
5458
5465
|
});
|
|
5459
|
-
var DTODocumentationLinkPreviewRequest =
|
|
5460
|
-
url:
|
|
5461
|
-
documentationItemPersistentId:
|
|
5466
|
+
var DTODocumentationLinkPreviewRequest = z196.object({
|
|
5467
|
+
url: z196.string().optional(),
|
|
5468
|
+
documentationItemPersistentId: z196.string().optional()
|
|
5462
5469
|
});
|
|
5463
5470
|
|
|
5464
5471
|
// src/api/dto/documentation/publish.ts
|
|
5465
|
-
import { z as
|
|
5472
|
+
import { z as z200 } from "zod";
|
|
5466
5473
|
|
|
5467
5474
|
// src/api/dto/export/exporter.ts
|
|
5468
|
-
import { z as
|
|
5469
|
-
var DTOExporterType =
|
|
5470
|
-
var DTOExporterSource =
|
|
5471
|
-
var DTOExporterMembershipRole =
|
|
5472
|
-
var DTOExporter =
|
|
5473
|
-
id:
|
|
5474
|
-
name:
|
|
5475
|
-
isPrivate:
|
|
5475
|
+
import { z as z197 } from "zod";
|
|
5476
|
+
var DTOExporterType = z197.enum(["documentation", "code"]);
|
|
5477
|
+
var DTOExporterSource = z197.enum(["git", "upload"]);
|
|
5478
|
+
var DTOExporterMembershipRole = z197.enum(["Owner", "OwnerArchived", "User"]);
|
|
5479
|
+
var DTOExporter = z197.object({
|
|
5480
|
+
id: z197.string(),
|
|
5481
|
+
name: z197.string(),
|
|
5482
|
+
isPrivate: z197.boolean(),
|
|
5476
5483
|
exporterType: DTOExporterType,
|
|
5477
|
-
isDefaultDocumentationExporter:
|
|
5478
|
-
iconURL:
|
|
5484
|
+
isDefaultDocumentationExporter: z197.boolean(),
|
|
5485
|
+
iconURL: z197.string().optional(),
|
|
5479
5486
|
configurationProperties: PulsarContributionConfigurationProperty.array(),
|
|
5480
5487
|
customBlocks: PulsarCustomBlock.array(),
|
|
5481
|
-
blockVariants:
|
|
5482
|
-
usesBrands:
|
|
5483
|
-
usesThemes:
|
|
5488
|
+
blockVariants: z197.record(z197.string(), PulsarContributionVariant.array()),
|
|
5489
|
+
usesBrands: z197.boolean(),
|
|
5490
|
+
usesThemes: z197.boolean(),
|
|
5484
5491
|
source: DTOExporterSource,
|
|
5485
|
-
gitUrl:
|
|
5486
|
-
gitBranch:
|
|
5487
|
-
gitDirectory:
|
|
5492
|
+
gitUrl: z197.string().optional(),
|
|
5493
|
+
gitBranch: z197.string().optional(),
|
|
5494
|
+
gitDirectory: z197.string().optional()
|
|
5488
5495
|
});
|
|
5489
|
-
var DTOExporterMembership =
|
|
5490
|
-
workspaceId:
|
|
5491
|
-
exporterId:
|
|
5496
|
+
var DTOExporterMembership = z197.object({
|
|
5497
|
+
workspaceId: z197.string(),
|
|
5498
|
+
exporterId: z197.string(),
|
|
5492
5499
|
role: DTOExporterMembershipRole
|
|
5493
5500
|
});
|
|
5494
|
-
var DTOExporterCreateOutput =
|
|
5501
|
+
var DTOExporterCreateOutput = z197.object({
|
|
5495
5502
|
exporter: DTOExporter,
|
|
5496
5503
|
membership: DTOExporterMembership
|
|
5497
5504
|
});
|
|
5498
|
-
var DTOExporterGitProviderEnum =
|
|
5499
|
-
var DTOExporterCreateInput =
|
|
5500
|
-
url:
|
|
5505
|
+
var DTOExporterGitProviderEnum = z197.enum(["github", "gitlab", "bitbucket", "azure"]);
|
|
5506
|
+
var DTOExporterCreateInput = z197.object({
|
|
5507
|
+
url: z197.string(),
|
|
5501
5508
|
provider: DTOExporterGitProviderEnum
|
|
5502
5509
|
});
|
|
5503
|
-
var DTOExporterUpdateInput =
|
|
5504
|
-
url:
|
|
5510
|
+
var DTOExporterUpdateInput = z197.object({
|
|
5511
|
+
url: z197.string().optional()
|
|
5505
5512
|
});
|
|
5506
5513
|
|
|
5507
5514
|
// src/api/dto/export/filter.ts
|
|
5508
5515
|
var DTOExportJobsListFilter = ExportJobFindByFilter;
|
|
5509
5516
|
|
|
5510
5517
|
// src/api/dto/export/job.ts
|
|
5511
|
-
import { z as
|
|
5512
|
-
var DTOExportJobCreatedBy =
|
|
5513
|
-
userId:
|
|
5514
|
-
userName:
|
|
5518
|
+
import { z as z198 } from "zod";
|
|
5519
|
+
var DTOExportJobCreatedBy = z198.object({
|
|
5520
|
+
userId: z198.string(),
|
|
5521
|
+
userName: z198.string()
|
|
5515
5522
|
});
|
|
5516
|
-
var DTOExportJobDesignSystemPreview =
|
|
5517
|
-
id:
|
|
5523
|
+
var DTOExportJobDesignSystemPreview = z198.object({
|
|
5524
|
+
id: z198.string(),
|
|
5518
5525
|
meta: ObjectMeta
|
|
5519
5526
|
});
|
|
5520
|
-
var DTOExportJobDesignSystemVersionPreview =
|
|
5521
|
-
id:
|
|
5527
|
+
var DTOExportJobDesignSystemVersionPreview = z198.object({
|
|
5528
|
+
id: z198.string(),
|
|
5522
5529
|
meta: ObjectMeta,
|
|
5523
|
-
version:
|
|
5524
|
-
isReadonly:
|
|
5530
|
+
version: z198.string(),
|
|
5531
|
+
isReadonly: z198.boolean()
|
|
5525
5532
|
});
|
|
5526
|
-
var DTOExportJobDestinations =
|
|
5533
|
+
var DTOExportJobDestinations = z198.object({
|
|
5527
5534
|
s3: ExporterDestinationS3.optional(),
|
|
5528
5535
|
azure: ExporterDestinationAzure.optional(),
|
|
5529
5536
|
bitbucket: ExporterDestinationBitbucket.optional(),
|
|
5530
5537
|
github: ExporterDestinationGithub.optional(),
|
|
5531
5538
|
gitlab: ExporterDestinationGitlab.optional(),
|
|
5532
5539
|
documentation: ExporterDestinationDocs.optional(),
|
|
5533
|
-
webhookUrl:
|
|
5540
|
+
webhookUrl: z198.string().optional()
|
|
5534
5541
|
});
|
|
5535
5542
|
var DTOExportJobResult = ExportJobResult.omit({
|
|
5536
5543
|
sndocs: true
|
|
5537
5544
|
}).extend({
|
|
5538
5545
|
documentation: ExportJobDocsDestinationResult.optional()
|
|
5539
5546
|
});
|
|
5540
|
-
var DTOExportJob =
|
|
5541
|
-
id:
|
|
5542
|
-
createdAt:
|
|
5543
|
-
finishedAt:
|
|
5544
|
-
index:
|
|
5547
|
+
var DTOExportJob = z198.object({
|
|
5548
|
+
id: z198.string(),
|
|
5549
|
+
createdAt: z198.coerce.date(),
|
|
5550
|
+
finishedAt: z198.coerce.date().optional(),
|
|
5551
|
+
index: z198.number().optional(),
|
|
5545
5552
|
status: ExportJobStatus,
|
|
5546
|
-
estimatedExecutionTime:
|
|
5553
|
+
estimatedExecutionTime: z198.number().optional(),
|
|
5547
5554
|
createdBy: DTOExportJobCreatedBy.optional(),
|
|
5548
5555
|
designSystem: DTOExportJobDesignSystemPreview,
|
|
5549
5556
|
designSystemVersion: DTOExportJobDesignSystemVersionPreview,
|
|
5550
5557
|
destinations: DTOExportJobDestinations,
|
|
5551
|
-
exporterId:
|
|
5552
|
-
scheduleId:
|
|
5558
|
+
exporterId: z198.string(),
|
|
5559
|
+
scheduleId: z198.string().optional(),
|
|
5553
5560
|
result: DTOExportJobResult.optional(),
|
|
5554
|
-
brandPersistentId:
|
|
5555
|
-
themePersistentId:
|
|
5561
|
+
brandPersistentId: z198.string().optional(),
|
|
5562
|
+
themePersistentId: z198.string().optional()
|
|
5556
5563
|
});
|
|
5557
|
-
var DTOExportJobResponse =
|
|
5564
|
+
var DTOExportJobResponse = z198.object({
|
|
5558
5565
|
job: DTOExportJob
|
|
5559
5566
|
});
|
|
5560
5567
|
|
|
5561
5568
|
// src/api/dto/export/pipeline.ts
|
|
5562
|
-
import { z as
|
|
5563
|
-
var DTOPipeline =
|
|
5564
|
-
id:
|
|
5565
|
-
name:
|
|
5569
|
+
import { z as z199 } from "zod";
|
|
5570
|
+
var DTOPipeline = z199.object({
|
|
5571
|
+
id: z199.string(),
|
|
5572
|
+
name: z199.string(),
|
|
5566
5573
|
eventType: PipelineEventType,
|
|
5567
|
-
isEnabled:
|
|
5568
|
-
workspaceId:
|
|
5569
|
-
designSystemId:
|
|
5570
|
-
exporterId:
|
|
5571
|
-
brandPersistentId:
|
|
5572
|
-
themePersistentId:
|
|
5574
|
+
isEnabled: z199.boolean(),
|
|
5575
|
+
workspaceId: z199.string(),
|
|
5576
|
+
designSystemId: z199.string(),
|
|
5577
|
+
exporterId: z199.string(),
|
|
5578
|
+
brandPersistentId: z199.string().optional(),
|
|
5579
|
+
themePersistentId: z199.string().optional(),
|
|
5573
5580
|
...ExportDestinationsMap.shape,
|
|
5574
5581
|
latestJobs: DTOExportJob.array()
|
|
5575
5582
|
});
|
|
5576
5583
|
|
|
5577
5584
|
// src/api/dto/documentation/publish.ts
|
|
5578
5585
|
var DTOPublishDocumentationChanges = ExportJobDocumentationChanges;
|
|
5579
|
-
var DTOPublishDocumentationRequest =
|
|
5586
|
+
var DTOPublishDocumentationRequest = z200.object({
|
|
5580
5587
|
environment: PublishedDocEnvironment,
|
|
5581
5588
|
/**
|
|
5582
5589
|
* If defined, this allows narrowing down what is published to a set of specific pages and groups
|
|
@@ -5584,15 +5591,15 @@ var DTOPublishDocumentationRequest = z199.object({
|
|
|
5584
5591
|
*/
|
|
5585
5592
|
changes: DTOPublishDocumentationChanges.optional()
|
|
5586
5593
|
});
|
|
5587
|
-
var DTOPublishDocumentationResponse =
|
|
5594
|
+
var DTOPublishDocumentationResponse = z200.object({
|
|
5588
5595
|
job: DTOExportJob
|
|
5589
5596
|
});
|
|
5590
5597
|
|
|
5591
5598
|
// src/api/dto/elements/documentation/group-action.ts
|
|
5592
|
-
import { z as
|
|
5599
|
+
import { z as z202 } from "zod";
|
|
5593
5600
|
|
|
5594
5601
|
// src/api/dto/elements/documentation/group-v2.ts
|
|
5595
|
-
import { z as
|
|
5602
|
+
import { z as z201 } from "zod";
|
|
5596
5603
|
var DTODocumentationGroupV2 = ElementGroup.omit({
|
|
5597
5604
|
sortOrder: true,
|
|
5598
5605
|
parentPersistentId: true,
|
|
@@ -5602,139 +5609,141 @@ var DTODocumentationGroupV2 = ElementGroup.omit({
|
|
|
5602
5609
|
data: true,
|
|
5603
5610
|
shortPersistentId: true
|
|
5604
5611
|
}).extend({
|
|
5605
|
-
title:
|
|
5606
|
-
isRoot:
|
|
5607
|
-
childrenIds:
|
|
5612
|
+
title: z201.string(),
|
|
5613
|
+
isRoot: z201.boolean(),
|
|
5614
|
+
childrenIds: z201.array(z201.string()),
|
|
5608
5615
|
groupBehavior: DocumentationGroupBehavior,
|
|
5609
|
-
shortPersistentId:
|
|
5616
|
+
shortPersistentId: z201.string(),
|
|
5610
5617
|
configuration: DTODocumentationItemConfigurationV2,
|
|
5611
|
-
type:
|
|
5618
|
+
type: z201.literal("Group"),
|
|
5612
5619
|
/** Defined when a group has changed since last publish and can be included into a partial publish */
|
|
5613
5620
|
draftState: DTODocumentationDraftState.optional(),
|
|
5614
5621
|
/** Defined if a group was published at least once and contains metadata about last publish */
|
|
5615
|
-
publishMetadata: DTODocumentationPublishMetadata.optional()
|
|
5622
|
+
publishMetadata: DTODocumentationPublishMetadata.optional(),
|
|
5623
|
+
//** An approval state for frontend to utilize. */
|
|
5624
|
+
approvalState: DTODocumentationGroupApprovalState.optional()
|
|
5616
5625
|
});
|
|
5617
|
-
var DTOCreateDocumentationGroupInput =
|
|
5626
|
+
var DTOCreateDocumentationGroupInput = z201.object({
|
|
5618
5627
|
// Identifier
|
|
5619
|
-
persistentId:
|
|
5628
|
+
persistentId: z201.string().uuid(),
|
|
5620
5629
|
// Group properties
|
|
5621
|
-
title:
|
|
5630
|
+
title: z201.string(),
|
|
5622
5631
|
configuration: DTODocumentationItemConfigurationV2.partial().optional(),
|
|
5623
5632
|
// Group placement properties
|
|
5624
|
-
afterPersistentId:
|
|
5625
|
-
parentPersistentId:
|
|
5633
|
+
afterPersistentId: z201.string().uuid().nullish(),
|
|
5634
|
+
parentPersistentId: z201.string().uuid()
|
|
5626
5635
|
});
|
|
5627
|
-
var DTOUpdateDocumentationGroupInput =
|
|
5636
|
+
var DTOUpdateDocumentationGroupInput = z201.object({
|
|
5628
5637
|
// Identifier of the group to update
|
|
5629
|
-
id:
|
|
5638
|
+
id: z201.string(),
|
|
5630
5639
|
// Group properties
|
|
5631
|
-
title:
|
|
5640
|
+
title: z201.string().optional(),
|
|
5632
5641
|
configuration: DTODocumentationItemConfigurationV2.partial().optional()
|
|
5633
5642
|
});
|
|
5634
|
-
var DTOMoveDocumentationGroupInput =
|
|
5643
|
+
var DTOMoveDocumentationGroupInput = z201.object({
|
|
5635
5644
|
// Identifier of the group to update
|
|
5636
|
-
id:
|
|
5645
|
+
id: z201.string(),
|
|
5637
5646
|
// Group placement properties
|
|
5638
|
-
parentPersistentId:
|
|
5639
|
-
afterPersistentId:
|
|
5647
|
+
parentPersistentId: z201.string().uuid(),
|
|
5648
|
+
afterPersistentId: z201.string().uuid().nullish()
|
|
5640
5649
|
});
|
|
5641
|
-
var DTODuplicateDocumentationGroupInput =
|
|
5650
|
+
var DTODuplicateDocumentationGroupInput = z201.object({
|
|
5642
5651
|
// Identifier of the group to duplicate from
|
|
5643
|
-
id:
|
|
5652
|
+
id: z201.string(),
|
|
5644
5653
|
// New group persistent id
|
|
5645
|
-
persistentId:
|
|
5654
|
+
persistentId: z201.string().uuid(),
|
|
5646
5655
|
// Group placement properties
|
|
5647
|
-
afterPersistentId:
|
|
5648
|
-
parentPersistentId:
|
|
5656
|
+
afterPersistentId: z201.string().uuid().nullish(),
|
|
5657
|
+
parentPersistentId: z201.string().uuid()
|
|
5649
5658
|
});
|
|
5650
|
-
var DTOCreateDocumentationTabInput =
|
|
5659
|
+
var DTOCreateDocumentationTabInput = z201.object({
|
|
5651
5660
|
// New group persistent id
|
|
5652
|
-
persistentId:
|
|
5661
|
+
persistentId: z201.string().uuid(),
|
|
5653
5662
|
// If this is page, we will attempt to convert it to tab
|
|
5654
5663
|
// If this is tab group, we will add a new tab to it
|
|
5655
|
-
fromItemPersistentId:
|
|
5656
|
-
tabName:
|
|
5664
|
+
fromItemPersistentId: z201.string(),
|
|
5665
|
+
tabName: z201.string()
|
|
5657
5666
|
});
|
|
5658
|
-
var DTODeleteDocumentationTabGroupInput =
|
|
5667
|
+
var DTODeleteDocumentationTabGroupInput = z201.object({
|
|
5659
5668
|
// Deleted group id
|
|
5660
|
-
id:
|
|
5669
|
+
id: z201.string()
|
|
5661
5670
|
});
|
|
5662
|
-
var DTODeleteDocumentationGroupInput =
|
|
5671
|
+
var DTODeleteDocumentationGroupInput = z201.object({
|
|
5663
5672
|
// Identifier
|
|
5664
|
-
id:
|
|
5673
|
+
id: z201.string(),
|
|
5665
5674
|
// Deletion options
|
|
5666
|
-
deleteSubtree:
|
|
5675
|
+
deleteSubtree: z201.boolean().default(false)
|
|
5667
5676
|
});
|
|
5668
5677
|
|
|
5669
5678
|
// src/api/dto/elements/documentation/group-action.ts
|
|
5670
|
-
var SuccessPayload =
|
|
5671
|
-
success:
|
|
5679
|
+
var SuccessPayload = z202.object({
|
|
5680
|
+
success: z202.literal(true)
|
|
5672
5681
|
});
|
|
5673
|
-
var DTODocumentationGroupCreateActionOutputV2 =
|
|
5674
|
-
type:
|
|
5682
|
+
var DTODocumentationGroupCreateActionOutputV2 = z202.object({
|
|
5683
|
+
type: z202.literal("DocumentationGroupCreate"),
|
|
5675
5684
|
output: SuccessPayload
|
|
5676
5685
|
});
|
|
5677
|
-
var DTODocumentationTabCreateActionOutputV2 =
|
|
5678
|
-
type:
|
|
5686
|
+
var DTODocumentationTabCreateActionOutputV2 = z202.object({
|
|
5687
|
+
type: z202.literal("DocumentationTabCreate"),
|
|
5679
5688
|
output: SuccessPayload
|
|
5680
5689
|
});
|
|
5681
|
-
var DTODocumentationGroupUpdateActionOutputV2 =
|
|
5682
|
-
type:
|
|
5690
|
+
var DTODocumentationGroupUpdateActionOutputV2 = z202.object({
|
|
5691
|
+
type: z202.literal("DocumentationGroupUpdate"),
|
|
5683
5692
|
output: SuccessPayload
|
|
5684
5693
|
});
|
|
5685
|
-
var DTODocumentationGroupMoveActionOutputV2 =
|
|
5686
|
-
type:
|
|
5694
|
+
var DTODocumentationGroupMoveActionOutputV2 = z202.object({
|
|
5695
|
+
type: z202.literal("DocumentationGroupMove"),
|
|
5687
5696
|
output: SuccessPayload
|
|
5688
5697
|
});
|
|
5689
|
-
var DTODocumentationGroupDuplicateActionOutputV2 =
|
|
5690
|
-
type:
|
|
5698
|
+
var DTODocumentationGroupDuplicateActionOutputV2 = z202.object({
|
|
5699
|
+
type: z202.literal("DocumentationGroupDuplicate"),
|
|
5691
5700
|
output: SuccessPayload
|
|
5692
5701
|
});
|
|
5693
|
-
var DTODocumentationGroupDeleteActionOutputV2 =
|
|
5694
|
-
type:
|
|
5702
|
+
var DTODocumentationGroupDeleteActionOutputV2 = z202.object({
|
|
5703
|
+
type: z202.literal("DocumentationGroupDelete"),
|
|
5695
5704
|
output: SuccessPayload
|
|
5696
5705
|
});
|
|
5697
|
-
var DTODocumentationTabGroupDeleteActionOutputV2 =
|
|
5698
|
-
type:
|
|
5706
|
+
var DTODocumentationTabGroupDeleteActionOutputV2 = z202.object({
|
|
5707
|
+
type: z202.literal("DocumentationTabGroupDelete"),
|
|
5699
5708
|
output: SuccessPayload
|
|
5700
5709
|
});
|
|
5701
|
-
var DTODocumentationGroupCreateActionInputV2 =
|
|
5702
|
-
type:
|
|
5710
|
+
var DTODocumentationGroupCreateActionInputV2 = z202.object({
|
|
5711
|
+
type: z202.literal("DocumentationGroupCreate"),
|
|
5703
5712
|
input: DTOCreateDocumentationGroupInput
|
|
5704
5713
|
});
|
|
5705
|
-
var DTODocumentationTabCreateActionInputV2 =
|
|
5706
|
-
type:
|
|
5714
|
+
var DTODocumentationTabCreateActionInputV2 = z202.object({
|
|
5715
|
+
type: z202.literal("DocumentationTabCreate"),
|
|
5707
5716
|
input: DTOCreateDocumentationTabInput
|
|
5708
5717
|
});
|
|
5709
|
-
var DTODocumentationGroupUpdateActionInputV2 =
|
|
5710
|
-
type:
|
|
5718
|
+
var DTODocumentationGroupUpdateActionInputV2 = z202.object({
|
|
5719
|
+
type: z202.literal("DocumentationGroupUpdate"),
|
|
5711
5720
|
input: DTOUpdateDocumentationGroupInput
|
|
5712
5721
|
});
|
|
5713
|
-
var DTODocumentationGroupMoveActionInputV2 =
|
|
5714
|
-
type:
|
|
5722
|
+
var DTODocumentationGroupMoveActionInputV2 = z202.object({
|
|
5723
|
+
type: z202.literal("DocumentationGroupMove"),
|
|
5715
5724
|
input: DTOMoveDocumentationGroupInput
|
|
5716
5725
|
});
|
|
5717
|
-
var DTODocumentationGroupDuplicateActionInputV2 =
|
|
5718
|
-
type:
|
|
5726
|
+
var DTODocumentationGroupDuplicateActionInputV2 = z202.object({
|
|
5727
|
+
type: z202.literal("DocumentationGroupDuplicate"),
|
|
5719
5728
|
input: DTODuplicateDocumentationGroupInput
|
|
5720
5729
|
});
|
|
5721
|
-
var DTODocumentationGroupDeleteActionInputV2 =
|
|
5722
|
-
type:
|
|
5730
|
+
var DTODocumentationGroupDeleteActionInputV2 = z202.object({
|
|
5731
|
+
type: z202.literal("DocumentationGroupDelete"),
|
|
5723
5732
|
input: DTODeleteDocumentationGroupInput
|
|
5724
5733
|
});
|
|
5725
|
-
var DTODocumentationTabGroupDeleteActionInputV2 =
|
|
5726
|
-
type:
|
|
5734
|
+
var DTODocumentationTabGroupDeleteActionInputV2 = z202.object({
|
|
5735
|
+
type: z202.literal("DocumentationTabGroupDelete"),
|
|
5727
5736
|
input: DTODeleteDocumentationTabGroupInput
|
|
5728
5737
|
});
|
|
5729
5738
|
|
|
5730
5739
|
// src/api/dto/elements/documentation/group-v1.ts
|
|
5731
|
-
import { z as
|
|
5740
|
+
import { z as z204 } from "zod";
|
|
5732
5741
|
|
|
5733
5742
|
// src/api/dto/elements/documentation/item-configuration-v1.ts
|
|
5734
|
-
import { z as
|
|
5735
|
-
var DocumentationColorV1 =
|
|
5736
|
-
aliasTo:
|
|
5737
|
-
value:
|
|
5743
|
+
import { z as z203 } from "zod";
|
|
5744
|
+
var DocumentationColorV1 = z203.object({
|
|
5745
|
+
aliasTo: z203.string().optional(),
|
|
5746
|
+
value: z203.string().optional()
|
|
5738
5747
|
});
|
|
5739
5748
|
var DTODocumentationItemHeaderV1 = DocumentationItemHeaderV1.omit({
|
|
5740
5749
|
foregroundColor: true,
|
|
@@ -5743,10 +5752,10 @@ var DTODocumentationItemHeaderV1 = DocumentationItemHeaderV1.omit({
|
|
|
5743
5752
|
foregroundColor: DocumentationColorV1.optional(),
|
|
5744
5753
|
backgroundColor: DocumentationColorV1.optional()
|
|
5745
5754
|
});
|
|
5746
|
-
var DTODocumentationItemConfigurationV1 =
|
|
5747
|
-
showSidebar:
|
|
5748
|
-
isPrivate:
|
|
5749
|
-
isHidden:
|
|
5755
|
+
var DTODocumentationItemConfigurationV1 = z203.object({
|
|
5756
|
+
showSidebar: z203.boolean(),
|
|
5757
|
+
isPrivate: z203.boolean(),
|
|
5758
|
+
isHidden: z203.boolean(),
|
|
5750
5759
|
header: DTODocumentationItemHeaderV1
|
|
5751
5760
|
});
|
|
5752
5761
|
|
|
@@ -5760,27 +5769,27 @@ var DTODocumentationGroupStructureV1 = ElementGroup.omit({
|
|
|
5760
5769
|
data: true,
|
|
5761
5770
|
shortPersistentId: true
|
|
5762
5771
|
}).extend({
|
|
5763
|
-
title:
|
|
5764
|
-
isRoot:
|
|
5765
|
-
childrenIds:
|
|
5772
|
+
title: z204.string(),
|
|
5773
|
+
isRoot: z204.boolean(),
|
|
5774
|
+
childrenIds: z204.array(z204.string()),
|
|
5766
5775
|
groupBehavior: DocumentationGroupBehavior,
|
|
5767
|
-
shortPersistentId:
|
|
5768
|
-
type:
|
|
5776
|
+
shortPersistentId: z204.string(),
|
|
5777
|
+
type: z204.literal("Group")
|
|
5769
5778
|
});
|
|
5770
5779
|
var DTODocumentationGroupV1 = DTODocumentationGroupStructureV1.extend({
|
|
5771
5780
|
configuration: DTODocumentationItemConfigurationV1
|
|
5772
5781
|
});
|
|
5773
5782
|
|
|
5774
5783
|
// src/api/dto/elements/documentation/hierarchy.ts
|
|
5775
|
-
import { z as
|
|
5776
|
-
var DTODocumentationHierarchyV2 =
|
|
5777
|
-
pages:
|
|
5784
|
+
import { z as z205 } from "zod";
|
|
5785
|
+
var DTODocumentationHierarchyV2 = z205.object({
|
|
5786
|
+
pages: z205.array(
|
|
5778
5787
|
DTODocumentationPageV2.extend({
|
|
5779
5788
|
/** Defined when a page has changed since last publish and can be included into a partial publish */
|
|
5780
5789
|
draftState: DTODocumentationDraftState.optional()
|
|
5781
5790
|
})
|
|
5782
5791
|
),
|
|
5783
|
-
groups:
|
|
5792
|
+
groups: z205.array(
|
|
5784
5793
|
DTODocumentationGroupV2.extend({
|
|
5785
5794
|
/** Defined when a page has changed since last publish and can be included into a partial publish */
|
|
5786
5795
|
draftState: DTODocumentationDraftState.optional()
|
|
@@ -5789,84 +5798,84 @@ var DTODocumentationHierarchyV2 = z204.object({
|
|
|
5789
5798
|
});
|
|
5790
5799
|
|
|
5791
5800
|
// src/api/dto/elements/documentation/page-actions-v2.ts
|
|
5792
|
-
import { z as
|
|
5793
|
-
var SuccessPayload2 =
|
|
5794
|
-
success:
|
|
5801
|
+
import { z as z206 } from "zod";
|
|
5802
|
+
var SuccessPayload2 = z206.object({
|
|
5803
|
+
success: z206.literal(true)
|
|
5795
5804
|
});
|
|
5796
|
-
var DTODocumentationPageCreateActionOutputV2 =
|
|
5797
|
-
type:
|
|
5805
|
+
var DTODocumentationPageCreateActionOutputV2 = z206.object({
|
|
5806
|
+
type: z206.literal("DocumentationPageCreate"),
|
|
5798
5807
|
output: SuccessPayload2
|
|
5799
5808
|
});
|
|
5800
|
-
var DTODocumentationPageUpdateActionOutputV2 =
|
|
5801
|
-
type:
|
|
5809
|
+
var DTODocumentationPageUpdateActionOutputV2 = z206.object({
|
|
5810
|
+
type: z206.literal("DocumentationPageUpdate"),
|
|
5802
5811
|
output: SuccessPayload2
|
|
5803
5812
|
});
|
|
5804
|
-
var DTODocumentationPageMoveActionOutputV2 =
|
|
5805
|
-
type:
|
|
5813
|
+
var DTODocumentationPageMoveActionOutputV2 = z206.object({
|
|
5814
|
+
type: z206.literal("DocumentationPageMove"),
|
|
5806
5815
|
output: SuccessPayload2
|
|
5807
5816
|
});
|
|
5808
|
-
var DTODocumentationPageDuplicateActionOutputV2 =
|
|
5809
|
-
type:
|
|
5817
|
+
var DTODocumentationPageDuplicateActionOutputV2 = z206.object({
|
|
5818
|
+
type: z206.literal("DocumentationPageDuplicate"),
|
|
5810
5819
|
output: SuccessPayload2
|
|
5811
5820
|
});
|
|
5812
|
-
var DTODocumentationPageDeleteActionOutputV2 =
|
|
5813
|
-
type:
|
|
5821
|
+
var DTODocumentationPageDeleteActionOutputV2 = z206.object({
|
|
5822
|
+
type: z206.literal("DocumentationPageDelete"),
|
|
5814
5823
|
output: SuccessPayload2
|
|
5815
5824
|
});
|
|
5816
|
-
var DTODocumentationPageRestoreActionOutput =
|
|
5817
|
-
type:
|
|
5825
|
+
var DTODocumentationPageRestoreActionOutput = z206.object({
|
|
5826
|
+
type: z206.literal("DocumentationPageRestore"),
|
|
5818
5827
|
output: SuccessPayload2
|
|
5819
5828
|
});
|
|
5820
|
-
var DTODocumentationGroupRestoreActionOutput =
|
|
5821
|
-
type:
|
|
5829
|
+
var DTODocumentationGroupRestoreActionOutput = z206.object({
|
|
5830
|
+
type: z206.literal("DocumentationGroupRestore"),
|
|
5822
5831
|
output: SuccessPayload2
|
|
5823
5832
|
});
|
|
5824
|
-
var DTODocumentationPageApprovalStateChangeActionOutput =
|
|
5825
|
-
type:
|
|
5833
|
+
var DTODocumentationPageApprovalStateChangeActionOutput = z206.object({
|
|
5834
|
+
type: z206.literal("DocumentationPageApprovalStateChange"),
|
|
5826
5835
|
output: SuccessPayload2
|
|
5827
5836
|
});
|
|
5828
|
-
var DTODocumentationPageCreateActionInputV2 =
|
|
5829
|
-
type:
|
|
5837
|
+
var DTODocumentationPageCreateActionInputV2 = z206.object({
|
|
5838
|
+
type: z206.literal("DocumentationPageCreate"),
|
|
5830
5839
|
input: DTOCreateDocumentationPageInputV2
|
|
5831
5840
|
});
|
|
5832
|
-
var DTODocumentationPageUpdateActionInputV2 =
|
|
5833
|
-
type:
|
|
5841
|
+
var DTODocumentationPageUpdateActionInputV2 = z206.object({
|
|
5842
|
+
type: z206.literal("DocumentationPageUpdate"),
|
|
5834
5843
|
input: DTOUpdateDocumentationPageInputV2
|
|
5835
5844
|
});
|
|
5836
|
-
var DTODocumentationPageMoveActionInputV2 =
|
|
5837
|
-
type:
|
|
5845
|
+
var DTODocumentationPageMoveActionInputV2 = z206.object({
|
|
5846
|
+
type: z206.literal("DocumentationPageMove"),
|
|
5838
5847
|
input: DTOMoveDocumentationPageInputV2
|
|
5839
5848
|
});
|
|
5840
|
-
var DTODocumentationPageDuplicateActionInputV2 =
|
|
5841
|
-
type:
|
|
5849
|
+
var DTODocumentationPageDuplicateActionInputV2 = z206.object({
|
|
5850
|
+
type: z206.literal("DocumentationPageDuplicate"),
|
|
5842
5851
|
input: DTODuplicateDocumentationPageInputV2
|
|
5843
5852
|
});
|
|
5844
|
-
var DTODocumentationPageDeleteActionInputV2 =
|
|
5845
|
-
type:
|
|
5853
|
+
var DTODocumentationPageDeleteActionInputV2 = z206.object({
|
|
5854
|
+
type: z206.literal("DocumentationPageDelete"),
|
|
5846
5855
|
input: DTODeleteDocumentationPageInputV2
|
|
5847
5856
|
});
|
|
5848
|
-
var DTODocumentationPageRestoreActionInput =
|
|
5849
|
-
type:
|
|
5857
|
+
var DTODocumentationPageRestoreActionInput = z206.object({
|
|
5858
|
+
type: z206.literal("DocumentationPageRestore"),
|
|
5850
5859
|
input: DTORestoreDocumentationPageInput
|
|
5851
5860
|
});
|
|
5852
|
-
var DTODocumentationGroupRestoreActionInput =
|
|
5853
|
-
type:
|
|
5861
|
+
var DTODocumentationGroupRestoreActionInput = z206.object({
|
|
5862
|
+
type: z206.literal("DocumentationGroupRestore"),
|
|
5854
5863
|
input: DTORestoreDocumentationGroupInput
|
|
5855
5864
|
});
|
|
5856
|
-
var DTODocumentationPageApprovalStateChangeActionInput =
|
|
5857
|
-
type:
|
|
5865
|
+
var DTODocumentationPageApprovalStateChangeActionInput = z206.object({
|
|
5866
|
+
type: z206.literal("DocumentationPageApprovalStateChange"),
|
|
5858
5867
|
input: DTODocumentationPageApprovalStateChangeInput
|
|
5859
5868
|
});
|
|
5860
5869
|
|
|
5861
5870
|
// src/api/dto/elements/documentation/page-content.ts
|
|
5862
|
-
import { z as
|
|
5871
|
+
import { z as z207 } from "zod";
|
|
5863
5872
|
var DTODocumentationPageContent = DocumentationPageContent;
|
|
5864
|
-
var DTODocumentationPageContentGetResponse =
|
|
5873
|
+
var DTODocumentationPageContentGetResponse = z207.object({
|
|
5865
5874
|
pageContent: DTODocumentationPageContent
|
|
5866
5875
|
});
|
|
5867
5876
|
|
|
5868
5877
|
// src/api/dto/elements/documentation/page-v1.ts
|
|
5869
|
-
import { z as
|
|
5878
|
+
import { z as z208 } from "zod";
|
|
5870
5879
|
var DocumentationPageV1DTO = DocumentationPageV1.omit({
|
|
5871
5880
|
data: true,
|
|
5872
5881
|
meta: true,
|
|
@@ -5874,30 +5883,30 @@ var DocumentationPageV1DTO = DocumentationPageV1.omit({
|
|
|
5874
5883
|
sortOrder: true
|
|
5875
5884
|
}).extend({
|
|
5876
5885
|
configuration: DTODocumentationItemConfigurationV1,
|
|
5877
|
-
blocks:
|
|
5878
|
-
title:
|
|
5879
|
-
path:
|
|
5886
|
+
blocks: z208.array(PageBlockV1),
|
|
5887
|
+
title: z208.string(),
|
|
5888
|
+
path: z208.string()
|
|
5880
5889
|
});
|
|
5881
5890
|
|
|
5882
5891
|
// src/api/dto/elements/figma-nodes/figma-node.ts
|
|
5883
|
-
import { z as
|
|
5884
|
-
var DTOFigmaNodeOrigin =
|
|
5885
|
-
sourceId:
|
|
5886
|
-
fileId:
|
|
5887
|
-
parentName:
|
|
5892
|
+
import { z as z209 } from "zod";
|
|
5893
|
+
var DTOFigmaNodeOrigin = z209.object({
|
|
5894
|
+
sourceId: z209.string(),
|
|
5895
|
+
fileId: z209.string().optional(),
|
|
5896
|
+
parentName: z209.string().optional()
|
|
5888
5897
|
});
|
|
5889
|
-
var DTOFigmaNodeData =
|
|
5898
|
+
var DTOFigmaNodeData = z209.object({
|
|
5890
5899
|
// Id of the node in the Figma file
|
|
5891
|
-
figmaNodeId:
|
|
5900
|
+
figmaNodeId: z209.string(),
|
|
5892
5901
|
// Validity
|
|
5893
|
-
isValid:
|
|
5902
|
+
isValid: z209.boolean(),
|
|
5894
5903
|
// Asset data
|
|
5895
|
-
assetId:
|
|
5896
|
-
assetUrl:
|
|
5904
|
+
assetId: z209.string(),
|
|
5905
|
+
assetUrl: z209.string(),
|
|
5897
5906
|
// Asset metadata
|
|
5898
|
-
assetScale:
|
|
5899
|
-
assetWidth:
|
|
5900
|
-
assetHeight:
|
|
5907
|
+
assetScale: z209.number(),
|
|
5908
|
+
assetWidth: z209.number().optional(),
|
|
5909
|
+
assetHeight: z209.number().optional()
|
|
5901
5910
|
});
|
|
5902
5911
|
var DTOFigmaNode = FigmaFileStructure.omit({
|
|
5903
5912
|
data: true,
|
|
@@ -5906,105 +5915,105 @@ var DTOFigmaNode = FigmaFileStructure.omit({
|
|
|
5906
5915
|
data: DTOFigmaNodeData,
|
|
5907
5916
|
origin: DTOFigmaNodeOrigin
|
|
5908
5917
|
});
|
|
5909
|
-
var DTOFigmaNodeRenderInput =
|
|
5918
|
+
var DTOFigmaNodeRenderInput = z209.object({
|
|
5910
5919
|
// Id of a design system's data source representing a linked Figma file
|
|
5911
|
-
sourceId:
|
|
5920
|
+
sourceId: z209.string(),
|
|
5912
5921
|
// Id of a node within the Figma file
|
|
5913
|
-
figmaFileNodeId:
|
|
5922
|
+
figmaFileNodeId: z209.string()
|
|
5914
5923
|
});
|
|
5915
5924
|
|
|
5916
5925
|
// src/api/dto/elements/figma-nodes/node-actions-v2.ts
|
|
5917
|
-
import { z as
|
|
5918
|
-
var DTOFigmaNodeRenderActionOutput =
|
|
5919
|
-
type:
|
|
5920
|
-
figmaNodes:
|
|
5926
|
+
import { z as z210 } from "zod";
|
|
5927
|
+
var DTOFigmaNodeRenderActionOutput = z210.object({
|
|
5928
|
+
type: z210.literal("FigmaNodeRender"),
|
|
5929
|
+
figmaNodes: z210.array(DTOFigmaNode)
|
|
5921
5930
|
});
|
|
5922
|
-
var DTOFigmaNodeRenderActionInput =
|
|
5923
|
-
type:
|
|
5931
|
+
var DTOFigmaNodeRenderActionInput = z210.object({
|
|
5932
|
+
type: z210.literal("FigmaNodeRender"),
|
|
5924
5933
|
input: DTOFigmaNodeRenderInput.array()
|
|
5925
5934
|
});
|
|
5926
5935
|
|
|
5927
5936
|
// src/api/dto/elements/properties/property-definitions-actions-v2.ts
|
|
5928
|
-
import { z as
|
|
5937
|
+
import { z as z212 } from "zod";
|
|
5929
5938
|
|
|
5930
5939
|
// src/api/dto/elements/properties/property-definitions.ts
|
|
5931
|
-
import { z as
|
|
5940
|
+
import { z as z211 } from "zod";
|
|
5932
5941
|
var CODE_NAME_REGEX2 = /^[a-zA-Z_$][a-zA-Z_$0-9]{1,99}$/;
|
|
5933
|
-
var DTOElementPropertyDefinition =
|
|
5934
|
-
id:
|
|
5935
|
-
designSystemVersionId:
|
|
5942
|
+
var DTOElementPropertyDefinition = z211.object({
|
|
5943
|
+
id: z211.string(),
|
|
5944
|
+
designSystemVersionId: z211.string(),
|
|
5936
5945
|
meta: ObjectMeta,
|
|
5937
|
-
persistentId:
|
|
5946
|
+
persistentId: z211.string(),
|
|
5938
5947
|
type: ElementPropertyTypeSchema,
|
|
5939
5948
|
targetElementType: ElementPropertyTargetType,
|
|
5940
|
-
codeName:
|
|
5941
|
-
options:
|
|
5949
|
+
codeName: z211.string().regex(CODE_NAME_REGEX2),
|
|
5950
|
+
options: z211.array(ElementPropertyDefinitionOption).optional(),
|
|
5942
5951
|
linkElementType: ElementPropertyLinkType.optional()
|
|
5943
5952
|
});
|
|
5944
|
-
var DTOElementPropertyDefinitionsGetResponse =
|
|
5945
|
-
definitions:
|
|
5953
|
+
var DTOElementPropertyDefinitionsGetResponse = z211.object({
|
|
5954
|
+
definitions: z211.array(DTOElementPropertyDefinition)
|
|
5946
5955
|
});
|
|
5947
5956
|
var DTOCreateElementPropertyDefinitionInputV2 = DTOElementPropertyDefinition.omit({
|
|
5948
5957
|
id: true,
|
|
5949
5958
|
designSystemVersionId: true
|
|
5950
5959
|
});
|
|
5951
|
-
var DTOUpdateElementPropertyDefinitionInputV2 =
|
|
5952
|
-
id:
|
|
5953
|
-
name:
|
|
5954
|
-
description:
|
|
5955
|
-
codeName:
|
|
5956
|
-
options:
|
|
5960
|
+
var DTOUpdateElementPropertyDefinitionInputV2 = z211.object({
|
|
5961
|
+
id: z211.string(),
|
|
5962
|
+
name: z211.string().optional(),
|
|
5963
|
+
description: z211.string().optional(),
|
|
5964
|
+
codeName: z211.string().regex(CODE_NAME_REGEX2).optional(),
|
|
5965
|
+
options: z211.array(ElementPropertyDefinitionOption).optional()
|
|
5957
5966
|
});
|
|
5958
|
-
var DTODeleteElementPropertyDefinitionInputV2 =
|
|
5959
|
-
id:
|
|
5967
|
+
var DTODeleteElementPropertyDefinitionInputV2 = z211.object({
|
|
5968
|
+
id: z211.string()
|
|
5960
5969
|
});
|
|
5961
5970
|
|
|
5962
5971
|
// src/api/dto/elements/properties/property-definitions-actions-v2.ts
|
|
5963
|
-
var SuccessPayload3 =
|
|
5964
|
-
success:
|
|
5972
|
+
var SuccessPayload3 = z212.object({
|
|
5973
|
+
success: z212.literal(true)
|
|
5965
5974
|
});
|
|
5966
|
-
var DTOPropertyDefinitionCreateActionOutputV2 =
|
|
5967
|
-
type:
|
|
5975
|
+
var DTOPropertyDefinitionCreateActionOutputV2 = z212.object({
|
|
5976
|
+
type: z212.literal("PropertyDefinitionCreate"),
|
|
5968
5977
|
definition: DTOElementPropertyDefinition
|
|
5969
5978
|
});
|
|
5970
|
-
var DTOPropertyDefinitionUpdateActionOutputV2 =
|
|
5971
|
-
type:
|
|
5979
|
+
var DTOPropertyDefinitionUpdateActionOutputV2 = z212.object({
|
|
5980
|
+
type: z212.literal("PropertyDefinitionUpdate"),
|
|
5972
5981
|
definition: DTOElementPropertyDefinition
|
|
5973
5982
|
});
|
|
5974
|
-
var DTOPropertyDefinitionDeleteActionOutputV2 =
|
|
5975
|
-
type:
|
|
5983
|
+
var DTOPropertyDefinitionDeleteActionOutputV2 = z212.object({
|
|
5984
|
+
type: z212.literal("PropertyDefinitionDelete"),
|
|
5976
5985
|
output: SuccessPayload3
|
|
5977
5986
|
});
|
|
5978
|
-
var DTOPropertyDefinitionCreateActionInputV2 =
|
|
5979
|
-
type:
|
|
5987
|
+
var DTOPropertyDefinitionCreateActionInputV2 = z212.object({
|
|
5988
|
+
type: z212.literal("PropertyDefinitionCreate"),
|
|
5980
5989
|
input: DTOCreateElementPropertyDefinitionInputV2
|
|
5981
5990
|
});
|
|
5982
|
-
var DTOPropertyDefinitionUpdateActionInputV2 =
|
|
5983
|
-
type:
|
|
5991
|
+
var DTOPropertyDefinitionUpdateActionInputV2 = z212.object({
|
|
5992
|
+
type: z212.literal("PropertyDefinitionUpdate"),
|
|
5984
5993
|
input: DTOUpdateElementPropertyDefinitionInputV2
|
|
5985
5994
|
});
|
|
5986
|
-
var DTOPropertyDefinitionDeleteActionInputV2 =
|
|
5987
|
-
type:
|
|
5995
|
+
var DTOPropertyDefinitionDeleteActionInputV2 = z212.object({
|
|
5996
|
+
type: z212.literal("PropertyDefinitionDelete"),
|
|
5988
5997
|
input: DTODeleteElementPropertyDefinitionInputV2
|
|
5989
5998
|
});
|
|
5990
5999
|
|
|
5991
6000
|
// src/api/dto/elements/properties/property-values.ts
|
|
5992
|
-
import { z as
|
|
5993
|
-
var DTOElementPropertyValue =
|
|
5994
|
-
id:
|
|
5995
|
-
designSystemVersionId:
|
|
5996
|
-
definitionId:
|
|
5997
|
-
targetElementId:
|
|
5998
|
-
value:
|
|
5999
|
-
valuePreview:
|
|
6001
|
+
import { z as z213 } from "zod";
|
|
6002
|
+
var DTOElementPropertyValue = z213.object({
|
|
6003
|
+
id: z213.string(),
|
|
6004
|
+
designSystemVersionId: z213.string(),
|
|
6005
|
+
definitionId: z213.string(),
|
|
6006
|
+
targetElementId: z213.string(),
|
|
6007
|
+
value: z213.union([z213.string(), z213.number(), z213.boolean()]).optional(),
|
|
6008
|
+
valuePreview: z213.string().optional()
|
|
6000
6009
|
});
|
|
6001
|
-
var DTOElementPropertyValuesGetResponse =
|
|
6002
|
-
values:
|
|
6010
|
+
var DTOElementPropertyValuesGetResponse = z213.object({
|
|
6011
|
+
values: z213.array(DTOElementPropertyValue)
|
|
6003
6012
|
});
|
|
6004
6013
|
|
|
6005
6014
|
// src/api/dto/elements/elements-action-v2.ts
|
|
6006
|
-
import { z as
|
|
6007
|
-
var DTOElementActionOutput =
|
|
6015
|
+
import { z as z214 } from "zod";
|
|
6016
|
+
var DTOElementActionOutput = z214.discriminatedUnion("type", [
|
|
6008
6017
|
// Documentation pages
|
|
6009
6018
|
DTODocumentationPageCreateActionOutputV2,
|
|
6010
6019
|
DTODocumentationPageUpdateActionOutputV2,
|
|
@@ -6031,7 +6040,7 @@ var DTOElementActionOutput = z213.discriminatedUnion("type", [
|
|
|
6031
6040
|
// Approvals
|
|
6032
6041
|
DTODocumentationPageApprovalStateChangeActionOutput
|
|
6033
6042
|
]);
|
|
6034
|
-
var DTOElementActionInput =
|
|
6043
|
+
var DTOElementActionInput = z214.discriminatedUnion("type", [
|
|
6035
6044
|
// Documentation pages
|
|
6036
6045
|
DTODocumentationPageCreateActionInputV2,
|
|
6037
6046
|
DTODocumentationPageUpdateActionInputV2,
|
|
@@ -6060,141 +6069,141 @@ var DTOElementActionInput = z213.discriminatedUnion("type", [
|
|
|
6060
6069
|
]);
|
|
6061
6070
|
|
|
6062
6071
|
// src/api/dto/elements/get-elements-v2.ts
|
|
6063
|
-
import { z as
|
|
6064
|
-
var DTOElementsGetTypeFilter =
|
|
6065
|
-
var DTOElementsGetQuerySchema =
|
|
6066
|
-
types:
|
|
6072
|
+
import { z as z215 } from "zod";
|
|
6073
|
+
var DTOElementsGetTypeFilter = z215.enum(["FigmaNode"]);
|
|
6074
|
+
var DTOElementsGetQuerySchema = z215.object({
|
|
6075
|
+
types: z215.string().transform((val) => val.split(",").map((v) => DTOElementsGetTypeFilter.parse(v)))
|
|
6067
6076
|
});
|
|
6068
|
-
var DTOElementsGetOutput =
|
|
6069
|
-
figmaNodes:
|
|
6077
|
+
var DTOElementsGetOutput = z215.object({
|
|
6078
|
+
figmaNodes: z215.array(DTOFigmaNode).optional()
|
|
6070
6079
|
});
|
|
6071
6080
|
|
|
6072
6081
|
// src/api/dto/figma-components/assets/download.ts
|
|
6073
|
-
import { z as
|
|
6074
|
-
var DTOAssetRenderConfiguration =
|
|
6075
|
-
prefix:
|
|
6076
|
-
suffix:
|
|
6077
|
-
scale:
|
|
6078
|
-
format:
|
|
6079
|
-
});
|
|
6080
|
-
var DTORenderedAssetFile =
|
|
6081
|
-
assetId:
|
|
6082
|
-
fileName:
|
|
6083
|
-
sourceUrl:
|
|
6082
|
+
import { z as z216 } from "zod";
|
|
6083
|
+
var DTOAssetRenderConfiguration = z216.object({
|
|
6084
|
+
prefix: z216.string().optional(),
|
|
6085
|
+
suffix: z216.string().optional(),
|
|
6086
|
+
scale: z216.enum(["x1", "x2", "x3", "x4"]),
|
|
6087
|
+
format: z216.enum(["png", "pdf", "svg"])
|
|
6088
|
+
});
|
|
6089
|
+
var DTORenderedAssetFile = z216.object({
|
|
6090
|
+
assetId: z216.string(),
|
|
6091
|
+
fileName: z216.string(),
|
|
6092
|
+
sourceUrl: z216.string(),
|
|
6084
6093
|
settings: DTOAssetRenderConfiguration,
|
|
6085
|
-
originalName:
|
|
6094
|
+
originalName: z216.string()
|
|
6086
6095
|
});
|
|
6087
|
-
var DTODownloadAssetsRequest =
|
|
6088
|
-
persistentIds:
|
|
6096
|
+
var DTODownloadAssetsRequest = z216.object({
|
|
6097
|
+
persistentIds: z216.array(z216.string().uuid()).optional(),
|
|
6089
6098
|
settings: DTOAssetRenderConfiguration.array()
|
|
6090
6099
|
});
|
|
6091
|
-
var DTODownloadAssetsResponse =
|
|
6100
|
+
var DTODownloadAssetsResponse = z216.object({
|
|
6092
6101
|
items: DTORenderedAssetFile.array()
|
|
6093
6102
|
});
|
|
6094
6103
|
|
|
6095
6104
|
// src/api/dto/liveblocks/auth-response.ts
|
|
6096
|
-
import { z as
|
|
6097
|
-
var DTOLiveblocksAuthResponse =
|
|
6098
|
-
token:
|
|
6105
|
+
import { z as z217 } from "zod";
|
|
6106
|
+
var DTOLiveblocksAuthResponse = z217.object({
|
|
6107
|
+
token: z217.string()
|
|
6099
6108
|
});
|
|
6100
6109
|
|
|
6101
6110
|
// src/api/dto/users/profile/update.ts
|
|
6102
|
-
import { z as
|
|
6103
|
-
var DTOUserProfileUpdateResponse =
|
|
6111
|
+
import { z as z218 } from "zod";
|
|
6112
|
+
var DTOUserProfileUpdateResponse = z218.object({
|
|
6104
6113
|
user: User
|
|
6105
6114
|
});
|
|
6106
6115
|
|
|
6107
6116
|
// src/api/dto/workspaces/git.ts
|
|
6108
|
-
import { z as
|
|
6109
|
-
var DTOGitOrganization =
|
|
6110
|
-
id:
|
|
6111
|
-
name:
|
|
6112
|
-
url:
|
|
6113
|
-
slug:
|
|
6114
|
-
});
|
|
6115
|
-
var DTOGitProject =
|
|
6116
|
-
id:
|
|
6117
|
-
name:
|
|
6118
|
-
url:
|
|
6119
|
-
slug:
|
|
6120
|
-
});
|
|
6121
|
-
var DTOGitRepository =
|
|
6122
|
-
id:
|
|
6123
|
-
name:
|
|
6124
|
-
url:
|
|
6125
|
-
slug:
|
|
6126
|
-
defaultBranch:
|
|
6127
|
-
});
|
|
6128
|
-
var DTOGitBranch =
|
|
6129
|
-
name:
|
|
6130
|
-
lastCommitId:
|
|
6117
|
+
import { z as z219 } from "zod";
|
|
6118
|
+
var DTOGitOrganization = z219.object({
|
|
6119
|
+
id: z219.string(),
|
|
6120
|
+
name: z219.string(),
|
|
6121
|
+
url: z219.string(),
|
|
6122
|
+
slug: z219.string()
|
|
6123
|
+
});
|
|
6124
|
+
var DTOGitProject = z219.object({
|
|
6125
|
+
id: z219.string(),
|
|
6126
|
+
name: z219.string(),
|
|
6127
|
+
url: z219.string(),
|
|
6128
|
+
slug: z219.string()
|
|
6129
|
+
});
|
|
6130
|
+
var DTOGitRepository = z219.object({
|
|
6131
|
+
id: z219.string(),
|
|
6132
|
+
name: z219.string(),
|
|
6133
|
+
url: z219.string(),
|
|
6134
|
+
slug: z219.string(),
|
|
6135
|
+
defaultBranch: z219.string().optional()
|
|
6136
|
+
});
|
|
6137
|
+
var DTOGitBranch = z219.object({
|
|
6138
|
+
name: z219.string(),
|
|
6139
|
+
lastCommitId: z219.string()
|
|
6131
6140
|
});
|
|
6132
6141
|
|
|
6133
6142
|
// src/api/dto/workspaces/integrations.ts
|
|
6134
|
-
import { z as
|
|
6143
|
+
import { z as z220 } from "zod";
|
|
6135
6144
|
var DTOIntegrationCredentials = IntegrationCredentials.omit({
|
|
6136
6145
|
accessToken: true,
|
|
6137
6146
|
refreshToken: true
|
|
6138
6147
|
});
|
|
6139
|
-
var DTOIntegration =
|
|
6140
|
-
id:
|
|
6141
|
-
workspaceId:
|
|
6148
|
+
var DTOIntegration = z220.object({
|
|
6149
|
+
id: z220.string(),
|
|
6150
|
+
workspaceId: z220.string(),
|
|
6142
6151
|
type: ExtendedIntegrationType,
|
|
6143
|
-
createdAt:
|
|
6144
|
-
integrationCredentials:
|
|
6145
|
-
integrationDesignSystems:
|
|
6152
|
+
createdAt: z220.coerce.date(),
|
|
6153
|
+
integrationCredentials: z220.array(DTOIntegrationCredentials).optional(),
|
|
6154
|
+
integrationDesignSystems: z220.array(IntegrationDesignSystem).optional()
|
|
6146
6155
|
});
|
|
6147
|
-
var DTOIntegrationOAuthGetResponse =
|
|
6148
|
-
url:
|
|
6156
|
+
var DTOIntegrationOAuthGetResponse = z220.object({
|
|
6157
|
+
url: z220.string()
|
|
6149
6158
|
});
|
|
6150
|
-
var DTOIntegrationPostResponse =
|
|
6159
|
+
var DTOIntegrationPostResponse = z220.object({
|
|
6151
6160
|
integration: DTOIntegration
|
|
6152
6161
|
});
|
|
6153
|
-
var DTOIntegrationsGetListResponse =
|
|
6162
|
+
var DTOIntegrationsGetListResponse = z220.object({
|
|
6154
6163
|
integrations: DTOIntegration.array()
|
|
6155
6164
|
});
|
|
6156
6165
|
|
|
6157
6166
|
// src/api/dto/workspaces/membership.ts
|
|
6158
|
-
import { z as
|
|
6167
|
+
import { z as z223 } from "zod";
|
|
6159
6168
|
|
|
6160
6169
|
// src/api/dto/workspaces/workspace.ts
|
|
6161
|
-
import { z as
|
|
6170
|
+
import { z as z222 } from "zod";
|
|
6162
6171
|
|
|
6163
6172
|
// src/api/dto/workspaces/npm-registry.ts
|
|
6164
|
-
import { z as
|
|
6173
|
+
import { z as z221 } from "zod";
|
|
6165
6174
|
var DTONpmRegistryConfigConstants = {
|
|
6166
6175
|
passwordPlaceholder: "redacted"
|
|
6167
6176
|
};
|
|
6168
|
-
var DTONpmRegistryConfig =
|
|
6177
|
+
var DTONpmRegistryConfig = z221.object({
|
|
6169
6178
|
// Registry basic configuration
|
|
6170
6179
|
registryType: NpmRegistryType,
|
|
6171
|
-
registryUrl:
|
|
6172
|
-
customRegistryUrl:
|
|
6180
|
+
registryUrl: z221.string(),
|
|
6181
|
+
customRegistryUrl: z221.string().optional(),
|
|
6173
6182
|
// URL of Supernova NPM packages proxy
|
|
6174
|
-
proxyUrl:
|
|
6183
|
+
proxyUrl: z221.string(),
|
|
6175
6184
|
// Auth configuration
|
|
6176
6185
|
authType: NpmRegistryAuthType,
|
|
6177
|
-
accessToken:
|
|
6178
|
-
username:
|
|
6179
|
-
password:
|
|
6186
|
+
accessToken: z221.literal(DTONpmRegistryConfigConstants.passwordPlaceholder).optional(),
|
|
6187
|
+
username: z221.string().optional(),
|
|
6188
|
+
password: z221.literal(DTONpmRegistryConfigConstants.passwordPlaceholder).optional(),
|
|
6180
6189
|
// NPM package scopes for whih the proxy should be enabled
|
|
6181
|
-
enabledScopes:
|
|
6190
|
+
enabledScopes: z221.array(z221.string()),
|
|
6182
6191
|
// True if client should bypass Supernova proxy and connect directly to the registry
|
|
6183
6192
|
// (e.g. when the NPM registry is behind a VPN or firewall which prevents Supernova from accessing it)
|
|
6184
|
-
bypassProxy:
|
|
6193
|
+
bypassProxy: z221.boolean()
|
|
6185
6194
|
});
|
|
6186
6195
|
|
|
6187
6196
|
// src/api/dto/workspaces/workspace.ts
|
|
6188
|
-
var DTOWorkspace =
|
|
6189
|
-
id:
|
|
6197
|
+
var DTOWorkspace = z222.object({
|
|
6198
|
+
id: z222.string(),
|
|
6190
6199
|
profile: WorkspaceProfile,
|
|
6191
6200
|
subscription: Subscription,
|
|
6192
6201
|
npmRegistry: DTONpmRegistryConfig.optional()
|
|
6193
6202
|
});
|
|
6194
6203
|
|
|
6195
6204
|
// src/api/dto/workspaces/membership.ts
|
|
6196
|
-
var DTOWorkspaceRole =
|
|
6197
|
-
var DTOUserWorkspaceMembership =
|
|
6205
|
+
var DTOWorkspaceRole = z223.enum(["Owner", "Admin", "Creator", "Viewer", "Billing"]);
|
|
6206
|
+
var DTOUserWorkspaceMembership = z223.object({
|
|
6198
6207
|
// Workspace the user is a member of
|
|
6199
6208
|
workspace: DTOWorkspace,
|
|
6200
6209
|
// Assigned role the user has in the workspace
|
|
@@ -6204,8 +6213,8 @@ var DTOUserWorkspaceMembership = z222.object({
|
|
|
6204
6213
|
// when a workspace's subscription is downgraded to free tier
|
|
6205
6214
|
effectiveRole: DTOWorkspaceRole
|
|
6206
6215
|
});
|
|
6207
|
-
var DTOUserWorkspaceMembershipsResponse =
|
|
6208
|
-
membership:
|
|
6216
|
+
var DTOUserWorkspaceMembershipsResponse = z223.object({
|
|
6217
|
+
membership: z223.array(DTOUserWorkspaceMembership)
|
|
6209
6218
|
});
|
|
6210
6219
|
|
|
6211
6220
|
// src/utils/hash.ts
|
|
@@ -6267,7 +6276,7 @@ function generateHash(input, debug = false) {
|
|
|
6267
6276
|
}
|
|
6268
6277
|
|
|
6269
6278
|
// src/yjs/design-system-content/documentation-hierarchy.ts
|
|
6270
|
-
import { z as
|
|
6279
|
+
import { z as z224 } from "zod";
|
|
6271
6280
|
|
|
6272
6281
|
// src/yjs/version-room/base.ts
|
|
6273
6282
|
var VersionRoomBaseYDoc = class {
|
|
@@ -6538,11 +6547,14 @@ var FrontendVersionRoomYDoc = class {
|
|
|
6538
6547
|
const groupDraftStates = this.buildGroupDraftCreatedAndUpdatedStates(groups, groupSnapshots);
|
|
6539
6548
|
const groupDraftDeletedStates = this.buildGroupDraftDeletedStates(groups, groupSnapshots);
|
|
6540
6549
|
const groupPublishedMetadata = this.buildGroupPublishedMetadata(groups, groupSnapshots);
|
|
6550
|
+
const groupApprovalStates = this.buildGroupApprovalStates(groups, groupSnapshots);
|
|
6541
6551
|
groupDTOs.forEach((g) => {
|
|
6542
6552
|
const draftState = groupDraftDeletedStates.get(g.id) ?? groupDraftStates.get(g.id);
|
|
6543
6553
|
draftState && (g.draftState = draftState);
|
|
6544
6554
|
const publishMetadata = groupPublishedMetadata.get(g.id);
|
|
6545
6555
|
publishMetadata && (g.publishMetadata = publishMetadata);
|
|
6556
|
+
const approvalState = groupApprovalStates.get(g.id);
|
|
6557
|
+
approvalState && (g.approvalState = approvalState);
|
|
6546
6558
|
});
|
|
6547
6559
|
return {
|
|
6548
6560
|
pages: pageDTOs,
|
|
@@ -6729,6 +6741,20 @@ var FrontendVersionRoomYDoc = class {
|
|
|
6729
6741
|
}
|
|
6730
6742
|
return void 0;
|
|
6731
6743
|
}
|
|
6744
|
+
buildGroupApprovalStates(groups, groupSnapshots) {
|
|
6745
|
+
const result = /* @__PURE__ */ new Map();
|
|
6746
|
+
const allGroups = [...groups, ...groupSnapshots];
|
|
6747
|
+
for (const g of allGroups) {
|
|
6748
|
+
const approvalState = {
|
|
6749
|
+
approvalState: "Approved",
|
|
6750
|
+
designSystemVersionId: g.designSystemVersionId,
|
|
6751
|
+
persistentId: g.persistentId,
|
|
6752
|
+
groupId: g.id
|
|
6753
|
+
};
|
|
6754
|
+
result.set(g.persistentId, approvalState);
|
|
6755
|
+
}
|
|
6756
|
+
return result;
|
|
6757
|
+
}
|
|
6732
6758
|
//
|
|
6733
6759
|
// Update page content hash
|
|
6734
6760
|
//
|
|
@@ -6779,24 +6805,24 @@ var FrontendVersionRoomYDoc = class {
|
|
|
6779
6805
|
};
|
|
6780
6806
|
|
|
6781
6807
|
// src/yjs/design-system-content/documentation-hierarchy.ts
|
|
6782
|
-
var DocumentationHierarchySettings =
|
|
6783
|
-
routingVersion:
|
|
6784
|
-
isDraftFeatureAdopted:
|
|
6785
|
-
isApprovalFeatureEnabled:
|
|
6786
|
-
approvalRequiredForPublishing:
|
|
6808
|
+
var DocumentationHierarchySettings = z224.object({
|
|
6809
|
+
routingVersion: z224.string(),
|
|
6810
|
+
isDraftFeatureAdopted: z224.boolean(),
|
|
6811
|
+
isApprovalFeatureEnabled: z224.boolean(),
|
|
6812
|
+
approvalRequiredForPublishing: z224.boolean()
|
|
6787
6813
|
});
|
|
6788
6814
|
function yjsToDocumentationHierarchy(doc) {
|
|
6789
6815
|
return new FrontendVersionRoomYDoc(doc).getDocumentationHierarchy();
|
|
6790
6816
|
}
|
|
6791
6817
|
|
|
6792
6818
|
// src/yjs/design-system-content/item-configuration.ts
|
|
6793
|
-
import { z as
|
|
6794
|
-
var DTODocumentationPageRoomHeaderData =
|
|
6795
|
-
title:
|
|
6819
|
+
import { z as z225 } from "zod";
|
|
6820
|
+
var DTODocumentationPageRoomHeaderData = z225.object({
|
|
6821
|
+
title: z225.string(),
|
|
6796
6822
|
configuration: DTODocumentationItemConfigurationV2
|
|
6797
6823
|
});
|
|
6798
|
-
var DTODocumentationPageRoomHeaderDataUpdate =
|
|
6799
|
-
title:
|
|
6824
|
+
var DTODocumentationPageRoomHeaderDataUpdate = z225.object({
|
|
6825
|
+
title: z225.string().optional(),
|
|
6800
6826
|
configuration: DTODocumentationItemConfigurationV2.omit({ header: true }).extend({ header: DocumentationItemHeaderV2.partial() }).optional()
|
|
6801
6827
|
});
|
|
6802
6828
|
function itemConfigurationToYjs(yDoc, item) {
|
|
@@ -6847,7 +6873,7 @@ function yjsToItemConfiguration(yDoc) {
|
|
|
6847
6873
|
header: rawHeader
|
|
6848
6874
|
};
|
|
6849
6875
|
return {
|
|
6850
|
-
title:
|
|
6876
|
+
title: z225.string().parse(title),
|
|
6851
6877
|
configuration: DTODocumentationItemConfigurationV2.parse(rawConfig)
|
|
6852
6878
|
};
|
|
6853
6879
|
}
|
|
@@ -6857,9 +6883,9 @@ var PageBlockEditorModel = PageBlockEditorModelV2;
|
|
|
6857
6883
|
var PageSectionEditorModel = PageSectionEditorModelV2;
|
|
6858
6884
|
|
|
6859
6885
|
// src/yjs/docs-editor/model/page.ts
|
|
6860
|
-
import { z as
|
|
6861
|
-
var DocumentationPageEditorModel =
|
|
6862
|
-
blocks:
|
|
6886
|
+
import { z as z226 } from "zod";
|
|
6887
|
+
var DocumentationPageEditorModel = z226.object({
|
|
6888
|
+
blocks: z226.array(DocumentationPageContentItem)
|
|
6863
6889
|
});
|
|
6864
6890
|
|
|
6865
6891
|
// src/yjs/docs-editor/prosemirror/schema.ts
|
|
@@ -10537,7 +10563,7 @@ var blocks = [
|
|
|
10537
10563
|
|
|
10538
10564
|
// src/yjs/docs-editor/prosemirror-to-blocks.ts
|
|
10539
10565
|
import { yXmlFragmentToProsemirrorJSON } from "y-prosemirror";
|
|
10540
|
-
import { z as
|
|
10566
|
+
import { z as z227 } from "zod";
|
|
10541
10567
|
function yDocToPage(yDoc, definitions) {
|
|
10542
10568
|
return yXmlFragmentToPage(yDoc.getXmlFragment("default"), definitions);
|
|
10543
10569
|
}
|
|
@@ -10580,7 +10606,7 @@ function prosemirrorNodeToSectionItem(prosemirrorNode, definitionsMap) {
|
|
|
10580
10606
|
return null;
|
|
10581
10607
|
return {
|
|
10582
10608
|
id,
|
|
10583
|
-
title: getProsemirrorAttribute(prosemirrorNode, "title",
|
|
10609
|
+
title: getProsemirrorAttribute(prosemirrorNode, "title", z227.string()) ?? "",
|
|
10584
10610
|
columns: (prosemirrorNode.content ?? []).filter((c) => c.type === "sectionItemColumn").map((c) => prosemirrorNodeToSectionColumns(c, definitionsMap)).filter(nonNullFilter)
|
|
10585
10611
|
};
|
|
10586
10612
|
}
|
|
@@ -10615,7 +10641,7 @@ function internalProsemirrorNodesToBlocks(prosemirrorNodes, definitionsMap, dept
|
|
|
10615
10641
|
});
|
|
10616
10642
|
}
|
|
10617
10643
|
function internalProsemirrorNodeToBlock(prosemirrorNode, definitionsMap, depth) {
|
|
10618
|
-
const definitionId = getProsemirrorAttribute(prosemirrorNode, "definitionId",
|
|
10644
|
+
const definitionId = getProsemirrorAttribute(prosemirrorNode, "definitionId", z227.string());
|
|
10619
10645
|
if (!definitionId) {
|
|
10620
10646
|
console.warn(`definitionId on ${prosemirrorNode.type} is required to be interpreted as a block, skipping node`);
|
|
10621
10647
|
return [];
|
|
@@ -10657,7 +10683,7 @@ function parseAsRichText(prosemirrorNode, definition, property) {
|
|
|
10657
10683
|
if (!id)
|
|
10658
10684
|
return null;
|
|
10659
10685
|
const variantId = getProsemirrorBlockVariantId(prosemirrorNode);
|
|
10660
|
-
const calloutType = parseCalloutType(getProsemirrorAttribute(prosemirrorNode, "type",
|
|
10686
|
+
const calloutType = parseCalloutType(getProsemirrorAttribute(prosemirrorNode, "type", z227.string().optional()));
|
|
10661
10687
|
return {
|
|
10662
10688
|
id,
|
|
10663
10689
|
type: "Block",
|
|
@@ -10785,10 +10811,10 @@ function parseRichTextAttribute(mark) {
|
|
|
10785
10811
|
return null;
|
|
10786
10812
|
}
|
|
10787
10813
|
function parseProsemirrorLink(mark) {
|
|
10788
|
-
const href = getProsemirrorAttribute(mark, "href",
|
|
10814
|
+
const href = getProsemirrorAttribute(mark, "href", z227.string().optional());
|
|
10789
10815
|
if (!href)
|
|
10790
10816
|
return null;
|
|
10791
|
-
const target = getProsemirrorAttribute(mark, "target",
|
|
10817
|
+
const target = getProsemirrorAttribute(mark, "target", z227.string().optional());
|
|
10792
10818
|
const openInNewTab = target === "_blank";
|
|
10793
10819
|
if (href.startsWith("@")) {
|
|
10794
10820
|
return {
|
|
@@ -10807,10 +10833,10 @@ function parseProsemirrorLink(mark) {
|
|
|
10807
10833
|
}
|
|
10808
10834
|
}
|
|
10809
10835
|
function parseProsemirrorCommentHighlight(mark) {
|
|
10810
|
-
const highlightId = getProsemirrorAttribute(mark, "highlightId",
|
|
10836
|
+
const highlightId = getProsemirrorAttribute(mark, "highlightId", z227.string().optional());
|
|
10811
10837
|
if (!highlightId)
|
|
10812
10838
|
return null;
|
|
10813
|
-
const isResolved = getProsemirrorAttribute(mark, "resolved",
|
|
10839
|
+
const isResolved = getProsemirrorAttribute(mark, "resolved", z227.boolean().optional()) ?? false;
|
|
10814
10840
|
return {
|
|
10815
10841
|
type: "Comment",
|
|
10816
10842
|
commentHighlightId: highlightId,
|
|
@@ -10822,7 +10848,7 @@ function parseAsTable(prosemirrorNode, definition, property) {
|
|
|
10822
10848
|
if (!id)
|
|
10823
10849
|
return null;
|
|
10824
10850
|
const variantId = getProsemirrorBlockVariantId(prosemirrorNode);
|
|
10825
|
-
const hasBorder = getProsemirrorAttribute(prosemirrorNode, "hasBorder",
|
|
10851
|
+
const hasBorder = getProsemirrorAttribute(prosemirrorNode, "hasBorder", z227.boolean().optional()) !== false;
|
|
10826
10852
|
const tableChild = prosemirrorNode.content?.find((c) => c.type === "table");
|
|
10827
10853
|
if (!tableChild) {
|
|
10828
10854
|
return emptyTable(id, variantId, 0);
|
|
@@ -10869,9 +10895,9 @@ function parseAsTableCell(prosemirrorNode) {
|
|
|
10869
10895
|
const id = getProsemirrorBlockId(prosemirrorNode);
|
|
10870
10896
|
if (!id)
|
|
10871
10897
|
return null;
|
|
10872
|
-
const textAlign = getProsemirrorAttribute(prosemirrorNode, "textAlign",
|
|
10898
|
+
const textAlign = getProsemirrorAttribute(prosemirrorNode, "textAlign", z227.string().optional());
|
|
10873
10899
|
let columnWidth;
|
|
10874
|
-
const columnWidthArray = getProsemirrorAttribute(prosemirrorNode, "colwidth",
|
|
10900
|
+
const columnWidthArray = getProsemirrorAttribute(prosemirrorNode, "colwidth", z227.array(z227.number()).optional());
|
|
10875
10901
|
if (columnWidthArray) {
|
|
10876
10902
|
columnWidth = roundDimension(columnWidthArray[0]);
|
|
10877
10903
|
}
|
|
@@ -10909,7 +10935,7 @@ function parseAsTableNode(prosemirrorNode) {
|
|
|
10909
10935
|
value: parseRichText(prosemirrorNode.content ?? [])
|
|
10910
10936
|
};
|
|
10911
10937
|
case "image":
|
|
10912
|
-
const items = getProsemirrorAttribute(prosemirrorNode, "items",
|
|
10938
|
+
const items = getProsemirrorAttribute(prosemirrorNode, "items", z227.string());
|
|
10913
10939
|
if (!items)
|
|
10914
10940
|
return null;
|
|
10915
10941
|
const parsedItems = PageBlockItemV2.array().safeParse(JSON.parse(items));
|
|
@@ -11026,7 +11052,7 @@ function definitionExpectsPlaceholderItem(definition) {
|
|
|
11026
11052
|
);
|
|
11027
11053
|
}
|
|
11028
11054
|
function parseBlockItems(prosemirrorNode, definition) {
|
|
11029
|
-
const itemsString = getProsemirrorAttribute(prosemirrorNode, "items",
|
|
11055
|
+
const itemsString = getProsemirrorAttribute(prosemirrorNode, "items", z227.string());
|
|
11030
11056
|
if (!itemsString)
|
|
11031
11057
|
return null;
|
|
11032
11058
|
const itemsJson = JSON.parse(itemsString);
|
|
@@ -11038,18 +11064,18 @@ function parseBlockItems(prosemirrorNode, definition) {
|
|
|
11038
11064
|
}
|
|
11039
11065
|
function parseAppearance(prosemirrorNode) {
|
|
11040
11066
|
let appearance = {};
|
|
11041
|
-
const rawAppearanceString = getProsemirrorAttribute(prosemirrorNode, "appearance",
|
|
11067
|
+
const rawAppearanceString = getProsemirrorAttribute(prosemirrorNode, "appearance", z227.string().optional());
|
|
11042
11068
|
if (rawAppearanceString) {
|
|
11043
11069
|
const parsedAppearance = PageBlockAppearanceV2.safeParse(JSON.parse(rawAppearanceString));
|
|
11044
11070
|
if (parsedAppearance.success) {
|
|
11045
11071
|
appearance = parsedAppearance.data;
|
|
11046
11072
|
}
|
|
11047
11073
|
}
|
|
11048
|
-
const columns = getProsemirrorAttribute(prosemirrorNode, "columns",
|
|
11074
|
+
const columns = getProsemirrorAttribute(prosemirrorNode, "columns", z227.number().optional());
|
|
11049
11075
|
if (columns) {
|
|
11050
11076
|
appearance.numberOfColumns = columns;
|
|
11051
11077
|
}
|
|
11052
|
-
const backgroundColor = getProsemirrorAttribute(prosemirrorNode, "backgroundColor",
|
|
11078
|
+
const backgroundColor = getProsemirrorAttribute(prosemirrorNode, "backgroundColor", z227.string().optional());
|
|
11053
11079
|
if (backgroundColor) {
|
|
11054
11080
|
const parsedColor = PageBlockColorV2.safeParse(JSON.parse(backgroundColor));
|
|
11055
11081
|
if (parsedColor.success) {
|
|
@@ -11142,13 +11168,13 @@ function valueSchemaForPropertyType(type) {
|
|
|
11142
11168
|
}
|
|
11143
11169
|
}
|
|
11144
11170
|
function getProsemirrorBlockId(prosemirrorNode) {
|
|
11145
|
-
const id = getProsemirrorAttribute(prosemirrorNode, "id",
|
|
11171
|
+
const id = getProsemirrorAttribute(prosemirrorNode, "id", z227.string());
|
|
11146
11172
|
if (!id)
|
|
11147
11173
|
console.warn(`Prosemirror attribute "id" on ${prosemirrorNode.type} is required`);
|
|
11148
11174
|
return id;
|
|
11149
11175
|
}
|
|
11150
11176
|
function getProsemirrorBlockVariantId(prosemirrorNode) {
|
|
11151
|
-
return getProsemirrorAttribute(prosemirrorNode, "variantId", nullishToOptional(
|
|
11177
|
+
return getProsemirrorAttribute(prosemirrorNode, "variantId", nullishToOptional(z227.string()));
|
|
11152
11178
|
}
|
|
11153
11179
|
function getProsemirrorAttribute(prosemirrorNode, attributeName, validationSchema) {
|
|
11154
11180
|
const parsedAttr = validationSchema.safeParse(prosemirrorNode.attrs?.[attributeName]);
|
|
@@ -11239,6 +11265,7 @@ export {
|
|
|
11239
11265
|
DTODocumentationDraftStateCreated,
|
|
11240
11266
|
DTODocumentationDraftStateDeleted,
|
|
11241
11267
|
DTODocumentationDraftStateUpdated,
|
|
11268
|
+
DTODocumentationGroupApprovalState,
|
|
11242
11269
|
DTODocumentationGroupCreateActionInputV2,
|
|
11243
11270
|
DTODocumentationGroupCreateActionOutputV2,
|
|
11244
11271
|
DTODocumentationGroupDeleteActionInputV2,
|