@supernova-studio/model 0.25.0 → 0.26.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/index.d.mts +2245 -234
- package/dist/index.d.ts +2245 -234
- package/dist/index.js +101 -60
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +961 -920
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/dsm/data-sources/data-source.ts +5 -0
- package/src/dsm/elements/data/documentation-section-v2.ts +47 -0
- package/src/dsm/elements/data/index.ts +1 -0
- package/src/dsm/elements/page-block-v2.ts +1 -0
- package/src/dsm/import/support/figma-files.ts +1 -0
- package/src/dsm/import/support/import-context.ts +11 -1
- package/src/multiplayer/documentation-page-room.ts +8 -9
- package/src/workspace/npm-registry-settings.ts +2 -7
package/dist/index.mjs
CHANGED
|
@@ -320,9 +320,11 @@ var DataSourceFigmaRemote = z15.object({
|
|
|
320
320
|
ownerName: z15.string(),
|
|
321
321
|
scope: DataSourceFigmaScope,
|
|
322
322
|
state: DataSourceFigmaState,
|
|
323
|
+
requiresSync: z15.boolean().optional().transform((v) => v ?? false),
|
|
323
324
|
lastImportMetadata: DataSourceFigmaImportMetadata.optional(),
|
|
324
325
|
downloadChunkSize: z15.number().optional(),
|
|
325
|
-
figmaRenderChunkSize: z15.number().optional()
|
|
326
|
+
figmaRenderChunkSize: z15.number().optional(),
|
|
327
|
+
maxFileDepth: z15.number().optional()
|
|
326
328
|
});
|
|
327
329
|
var DataSourceTokenStudioRemote = z15.object({
|
|
328
330
|
type: z15.literal(DataSourceRemoteType.Enum.TokenStudio)
|
|
@@ -383,7 +385,7 @@ var ImportJob = Entity.extend({
|
|
|
383
385
|
});
|
|
384
386
|
|
|
385
387
|
// src/dsm/data-sources/import-summary.ts
|
|
386
|
-
import { z as
|
|
388
|
+
import { z as z88 } from "zod";
|
|
387
389
|
|
|
388
390
|
// src/dsm/elements/data/base.ts
|
|
389
391
|
import { z as z19 } from "zod";
|
|
@@ -1240,35 +1242,118 @@ var DocumentationPageElementDataV2 = z43.object({
|
|
|
1240
1242
|
valueV2: DocumentationPageDataV2.optional()
|
|
1241
1243
|
});
|
|
1242
1244
|
|
|
1243
|
-
// src/dsm/elements/data/
|
|
1245
|
+
// src/dsm/elements/data/documentation-section-v2.ts
|
|
1246
|
+
import { z as z46 } from "zod";
|
|
1247
|
+
|
|
1248
|
+
// src/dsm/elements/page-block-v2.ts
|
|
1249
|
+
import { z as z45 } from "zod";
|
|
1250
|
+
|
|
1251
|
+
// src/dsm/elements/base.ts
|
|
1244
1252
|
import { z as z44 } from "zod";
|
|
1245
|
-
var
|
|
1246
|
-
|
|
1253
|
+
var DesignElementOrigin = z44.object({
|
|
1254
|
+
id: z44.string(),
|
|
1255
|
+
sourceId: z44.string(),
|
|
1256
|
+
name: z44.string()
|
|
1257
|
+
});
|
|
1258
|
+
var DesignElementBase = z44.object({
|
|
1259
|
+
id: z44.string(),
|
|
1260
|
+
persistentId: z44.string(),
|
|
1261
|
+
meta: ObjectMeta,
|
|
1262
|
+
designSystemVersionId: z44.string(),
|
|
1263
|
+
createdAt: z44.coerce.date(),
|
|
1264
|
+
updatedAt: z44.coerce.date()
|
|
1265
|
+
});
|
|
1266
|
+
var DesignElementImportedBase = DesignElementBase.extend({
|
|
1267
|
+
origin: DesignElementOrigin
|
|
1268
|
+
});
|
|
1269
|
+
var DesignElementGroupablePart = z44.object({
|
|
1270
|
+
parentPersistentId: z44.string().optional(),
|
|
1271
|
+
sortOrder: z44.number()
|
|
1272
|
+
});
|
|
1273
|
+
var DesignElementGroupableBase = DesignElementBase.extend(DesignElementGroupablePart.shape);
|
|
1274
|
+
var DesignElementGroupableRequiredPart = DesignElementGroupablePart.extend({
|
|
1275
|
+
parentPersistentId: z44.string()
|
|
1276
|
+
});
|
|
1277
|
+
var DesignElementBrandedPart = z44.object({
|
|
1278
|
+
brandPersistentId: z44.string()
|
|
1279
|
+
});
|
|
1280
|
+
var DesignElementSlugPart = z44.object({
|
|
1281
|
+
slug: z44.string().optional(),
|
|
1282
|
+
userSlug: z44.string().optional()
|
|
1283
|
+
});
|
|
1284
|
+
|
|
1285
|
+
// src/dsm/elements/page-block-v2.ts
|
|
1286
|
+
var PageBlockV2 = DesignElementBase.extend(DesignElementGroupableRequiredPart.shape).extend({
|
|
1287
|
+
data: PageBlockDataV2
|
|
1288
|
+
});
|
|
1289
|
+
var PageBlockEditorModelV2 = z45.object({
|
|
1290
|
+
id: z45.string(),
|
|
1291
|
+
type: z45.literal("Block"),
|
|
1292
|
+
data: PageBlockDataV2
|
|
1293
|
+
});
|
|
1294
|
+
|
|
1295
|
+
// src/dsm/elements/data/documentation-section-v2.ts
|
|
1296
|
+
var PageSectionTypeV2 = z46.enum(["Tabs"]);
|
|
1297
|
+
var PageSectionColumnV2 = z46.object({
|
|
1298
|
+
id: z46.string(),
|
|
1299
|
+
blocks: z46.array(PageBlockEditorModelV2)
|
|
1300
|
+
});
|
|
1301
|
+
var PageSectionItemV2 = z46.object({
|
|
1302
|
+
id: z46.string(),
|
|
1303
|
+
title: z46.string(),
|
|
1304
|
+
columns: z46.array(PageSectionColumnV2)
|
|
1305
|
+
});
|
|
1306
|
+
var PageSectionPaddingV2 = z46.object({
|
|
1307
|
+
top: z46.number().optional(),
|
|
1308
|
+
bottom: z46.number().optional(),
|
|
1309
|
+
left: z46.number().optional(),
|
|
1310
|
+
right: z46.number().optional()
|
|
1311
|
+
});
|
|
1312
|
+
var PageSectionAppearanceV2 = z46.object({
|
|
1313
|
+
expandToEdges: z46.boolean(),
|
|
1314
|
+
contentExpandToEdges: z46.boolean(),
|
|
1315
|
+
backgroundColor: PageBlockColorV2.optional(),
|
|
1316
|
+
foregroundColor: PageBlockColorV2.optional(),
|
|
1317
|
+
padding: PageSectionPaddingV2.optional()
|
|
1318
|
+
});
|
|
1319
|
+
var PageSectionEditorModelV2 = z46.object({
|
|
1320
|
+
id: z46.string(),
|
|
1321
|
+
type: z46.literal("Section"),
|
|
1322
|
+
variantId: z46.string().optional(),
|
|
1323
|
+
sectionType: PageSectionTypeV2,
|
|
1324
|
+
appearance: PageSectionAppearanceV2,
|
|
1325
|
+
items: z46.array(PageSectionItemV2)
|
|
1326
|
+
});
|
|
1327
|
+
|
|
1328
|
+
// src/dsm/elements/data/duration.ts
|
|
1329
|
+
import { z as z47 } from "zod";
|
|
1330
|
+
var DurationUnit = z47.enum(["Ms"]);
|
|
1331
|
+
var DurationValue = z47.object({
|
|
1247
1332
|
unit: DurationUnit,
|
|
1248
|
-
measure:
|
|
1333
|
+
measure: z47.number()
|
|
1249
1334
|
});
|
|
1250
1335
|
var DurationTokenData = tokenAliasOrValue(DurationValue);
|
|
1251
1336
|
|
|
1252
1337
|
// src/dsm/elements/data/figma-file-structure.ts
|
|
1253
|
-
import { z as
|
|
1254
|
-
var FigmaFileStructureNodeType =
|
|
1255
|
-
var FigmaFileStructureNodeBase =
|
|
1256
|
-
id:
|
|
1257
|
-
name:
|
|
1338
|
+
import { z as z48 } from "zod";
|
|
1339
|
+
var FigmaFileStructureNodeType = z48.enum(["DOCUMENT", "CANVAS", "FRAME", "COMPONENT", "COMPONENT_SET"]);
|
|
1340
|
+
var FigmaFileStructureNodeBase = z48.object({
|
|
1341
|
+
id: z48.string(),
|
|
1342
|
+
name: z48.string(),
|
|
1258
1343
|
type: FigmaFileStructureNodeType,
|
|
1259
1344
|
size: SizeOrUndefined,
|
|
1260
|
-
parentComponentSetId:
|
|
1345
|
+
parentComponentSetId: z48.string().optional()
|
|
1261
1346
|
});
|
|
1262
1347
|
var FigmaFileStructureNode = FigmaFileStructureNodeBase.extend({
|
|
1263
|
-
children:
|
|
1348
|
+
children: z48.lazy(() => FigmaFileStructureNode.array())
|
|
1264
1349
|
});
|
|
1265
|
-
var FigmaFileStructureStatistics =
|
|
1266
|
-
frames:
|
|
1267
|
-
components:
|
|
1268
|
-
componentSets:
|
|
1350
|
+
var FigmaFileStructureStatistics = z48.object({
|
|
1351
|
+
frames: z48.number().nullable().optional().transform((v) => v ?? 0),
|
|
1352
|
+
components: z48.number().nullable().optional().transform((v) => v ?? 0),
|
|
1353
|
+
componentSets: z48.number().nullable().optional().transform((v) => v ?? 0)
|
|
1269
1354
|
});
|
|
1270
|
-
var FigmaFileStructureElementData =
|
|
1271
|
-
value:
|
|
1355
|
+
var FigmaFileStructureElementData = z48.object({
|
|
1356
|
+
value: z48.object({
|
|
1272
1357
|
structure: FigmaFileStructureNode,
|
|
1273
1358
|
assetsInFile: FigmaFileStructureStatistics
|
|
1274
1359
|
})
|
|
@@ -1285,172 +1370,172 @@ function recursiveFigmaFileStructureToMap(node, map) {
|
|
|
1285
1370
|
}
|
|
1286
1371
|
|
|
1287
1372
|
// src/dsm/elements/data/figma-node-reference.ts
|
|
1288
|
-
import { z as
|
|
1289
|
-
var FigmaNodeReferenceData =
|
|
1290
|
-
structureElementId:
|
|
1291
|
-
nodeId:
|
|
1292
|
-
fileId:
|
|
1293
|
-
valid:
|
|
1373
|
+
import { z as z49 } from "zod";
|
|
1374
|
+
var FigmaNodeReferenceData = z49.object({
|
|
1375
|
+
structureElementId: z49.string(),
|
|
1376
|
+
nodeId: z49.string(),
|
|
1377
|
+
fileId: z49.string().optional(),
|
|
1378
|
+
valid: z49.boolean(),
|
|
1294
1379
|
// Asset data
|
|
1295
|
-
assetId:
|
|
1296
|
-
assetScale:
|
|
1297
|
-
assetWidth:
|
|
1298
|
-
assetHeight:
|
|
1299
|
-
assetUrl:
|
|
1300
|
-
assetOriginKey:
|
|
1301
|
-
});
|
|
1302
|
-
var FigmaNodeReferenceElementData =
|
|
1380
|
+
assetId: z49.string().optional(),
|
|
1381
|
+
assetScale: z49.number().optional(),
|
|
1382
|
+
assetWidth: z49.number().optional(),
|
|
1383
|
+
assetHeight: z49.number().optional(),
|
|
1384
|
+
assetUrl: z49.string().optional(),
|
|
1385
|
+
assetOriginKey: z49.string().optional()
|
|
1386
|
+
});
|
|
1387
|
+
var FigmaNodeReferenceElementData = z49.object({
|
|
1303
1388
|
value: FigmaNodeReferenceData
|
|
1304
1389
|
});
|
|
1305
1390
|
|
|
1306
1391
|
// src/dsm/elements/data/font-family.ts
|
|
1307
|
-
import { z as
|
|
1308
|
-
var FontFamilyValue =
|
|
1392
|
+
import { z as z50 } from "zod";
|
|
1393
|
+
var FontFamilyValue = z50.string();
|
|
1309
1394
|
var FontFamilyTokenData = tokenAliasOrValue(FontFamilyValue);
|
|
1310
1395
|
|
|
1311
1396
|
// src/dsm/elements/data/font-size.ts
|
|
1312
|
-
import { z as
|
|
1313
|
-
var FontSizeUnit =
|
|
1314
|
-
var FontSizeValue =
|
|
1397
|
+
import { z as z51 } from "zod";
|
|
1398
|
+
var FontSizeUnit = z51.enum(["Pixels", "Rem", "Percent"]);
|
|
1399
|
+
var FontSizeValue = z51.object({
|
|
1315
1400
|
unit: FontSizeUnit,
|
|
1316
|
-
measure:
|
|
1401
|
+
measure: z51.number()
|
|
1317
1402
|
});
|
|
1318
1403
|
var FontSizeTokenData = tokenAliasOrValue(FontSizeValue);
|
|
1319
1404
|
|
|
1320
1405
|
// src/dsm/elements/data/font-weight.ts
|
|
1321
|
-
import { z as
|
|
1322
|
-
var FontWeightValue =
|
|
1406
|
+
import { z as z52 } from "zod";
|
|
1407
|
+
var FontWeightValue = z52.string();
|
|
1323
1408
|
var FontWeightTokenData = tokenAliasOrValue(FontWeightValue);
|
|
1324
1409
|
|
|
1325
1410
|
// src/dsm/elements/data/gradient.ts
|
|
1326
|
-
import { z as
|
|
1327
|
-
var GradientType =
|
|
1328
|
-
var GradientStop =
|
|
1329
|
-
position:
|
|
1411
|
+
import { z as z53 } from "zod";
|
|
1412
|
+
var GradientType = z53.enum(["Linear", "Radial", "Angular"]);
|
|
1413
|
+
var GradientStop = z53.object({
|
|
1414
|
+
position: z53.number(),
|
|
1330
1415
|
color: ColorTokenData
|
|
1331
1416
|
});
|
|
1332
|
-
var GradientLayerValue =
|
|
1417
|
+
var GradientLayerValue = z53.object({
|
|
1333
1418
|
from: Point2D,
|
|
1334
1419
|
to: Point2D,
|
|
1335
1420
|
type: GradientType,
|
|
1336
|
-
aspectRatio: nullishToOptional(
|
|
1421
|
+
aspectRatio: nullishToOptional(z53.number()),
|
|
1337
1422
|
// z.number(),
|
|
1338
|
-
stops:
|
|
1423
|
+
stops: z53.array(GradientStop).min(2)
|
|
1339
1424
|
});
|
|
1340
1425
|
var GradientLayerData = tokenAliasOrValue(GradientLayerValue);
|
|
1341
|
-
var GradientTokenValue =
|
|
1426
|
+
var GradientTokenValue = z53.array(GradientLayerData);
|
|
1342
1427
|
var GradientTokenData = tokenAliasOrValue(GradientTokenValue);
|
|
1343
1428
|
|
|
1344
1429
|
// src/dsm/elements/data/group.ts
|
|
1345
|
-
import { z as
|
|
1346
|
-
var DocumentationGroupBehavior =
|
|
1347
|
-
var ElementGroupDataDeprecated =
|
|
1430
|
+
import { z as z54 } from "zod";
|
|
1431
|
+
var DocumentationGroupBehavior = z54.enum(["Group", "Tabs"]);
|
|
1432
|
+
var ElementGroupDataDeprecated = z54.object({
|
|
1348
1433
|
behavior: nullishToOptional(DocumentationGroupBehavior.optional()),
|
|
1349
1434
|
configuration: nullishToOptional(DocumentationItemConfigurationV1)
|
|
1350
1435
|
});
|
|
1351
|
-
var ElementGroupDataV2 =
|
|
1436
|
+
var ElementGroupDataV2 = z54.object({
|
|
1352
1437
|
behavior: nullishToOptional(DocumentationGroupBehavior.optional()),
|
|
1353
1438
|
configuration: nullishToOptional(DocumentationItemConfigurationV2)
|
|
1354
1439
|
});
|
|
1355
|
-
var ElementGroupElementData =
|
|
1440
|
+
var ElementGroupElementData = z54.object({
|
|
1356
1441
|
value: ElementGroupDataDeprecated.optional(),
|
|
1357
1442
|
valueV2: ElementGroupDataV2.optional()
|
|
1358
1443
|
});
|
|
1359
1444
|
|
|
1360
1445
|
// src/dsm/elements/data/letter-spacing.ts
|
|
1361
|
-
import { z as
|
|
1362
|
-
var LetterSpacingUnit =
|
|
1363
|
-
var LetterSpacingValue =
|
|
1446
|
+
import { z as z55 } from "zod";
|
|
1447
|
+
var LetterSpacingUnit = z55.enum(["Pixels", "Rem", "Percent"]);
|
|
1448
|
+
var LetterSpacingValue = z55.object({
|
|
1364
1449
|
unit: LetterSpacingUnit,
|
|
1365
|
-
measure:
|
|
1450
|
+
measure: z55.number()
|
|
1366
1451
|
});
|
|
1367
1452
|
var LetterSpacingTokenData = tokenAliasOrValue(LetterSpacingValue);
|
|
1368
1453
|
|
|
1369
1454
|
// src/dsm/elements/data/line-height.ts
|
|
1370
|
-
import { z as
|
|
1371
|
-
var LineHeightUnit =
|
|
1372
|
-
var LineHeightValue =
|
|
1455
|
+
import { z as z56 } from "zod";
|
|
1456
|
+
var LineHeightUnit = z56.enum(["Pixels", "Rem", "Percent", "Raw"]);
|
|
1457
|
+
var LineHeightValue = z56.object({
|
|
1373
1458
|
unit: LineHeightUnit,
|
|
1374
|
-
measure:
|
|
1459
|
+
measure: z56.number()
|
|
1375
1460
|
});
|
|
1376
1461
|
var LineHeightTokenData = tokenAliasOrValue(LineHeightValue);
|
|
1377
1462
|
|
|
1378
1463
|
// src/dsm/elements/data/paragraph-indent.ts
|
|
1379
|
-
import { z as
|
|
1380
|
-
var ParagraphIndentUnit =
|
|
1381
|
-
var ParagraphIndentValue =
|
|
1464
|
+
import { z as z57 } from "zod";
|
|
1465
|
+
var ParagraphIndentUnit = z57.enum(["Pixels", "Rem", "Percent"]);
|
|
1466
|
+
var ParagraphIndentValue = z57.object({
|
|
1382
1467
|
unit: ParagraphIndentUnit,
|
|
1383
|
-
measure:
|
|
1468
|
+
measure: z57.number()
|
|
1384
1469
|
});
|
|
1385
1470
|
var ParagraphIndentTokenData = tokenAliasOrValue(ParagraphIndentValue);
|
|
1386
1471
|
|
|
1387
1472
|
// src/dsm/elements/data/paragraph-spacing.ts
|
|
1388
|
-
import { z as
|
|
1389
|
-
var ParagraphSpacingUnit =
|
|
1390
|
-
var ParagraphSpacingValue =
|
|
1473
|
+
import { z as z58 } from "zod";
|
|
1474
|
+
var ParagraphSpacingUnit = z58.enum(["Pixels", "Rem", "Percent"]);
|
|
1475
|
+
var ParagraphSpacingValue = z58.object({
|
|
1391
1476
|
unit: ParagraphSpacingUnit,
|
|
1392
|
-
measure:
|
|
1477
|
+
measure: z58.number()
|
|
1393
1478
|
});
|
|
1394
1479
|
var ParagraphSpacingTokenData = tokenAliasOrValue(ParagraphSpacingValue);
|
|
1395
1480
|
|
|
1396
1481
|
// src/dsm/elements/data/product-copy.ts
|
|
1397
|
-
import { z as
|
|
1398
|
-
var ProductCopyValue =
|
|
1482
|
+
import { z as z59 } from "zod";
|
|
1483
|
+
var ProductCopyValue = z59.string();
|
|
1399
1484
|
var ProductCopyTokenData = tokenAliasOrValue(ProductCopyValue);
|
|
1400
1485
|
|
|
1401
1486
|
// src/dsm/elements/data/shadow.ts
|
|
1402
|
-
import { z as
|
|
1403
|
-
var ShadowType =
|
|
1404
|
-
var ShadowLayerValue =
|
|
1487
|
+
import { z as z60 } from "zod";
|
|
1488
|
+
var ShadowType = z60.enum(["Drop", "Inner"]);
|
|
1489
|
+
var ShadowLayerValue = z60.object({
|
|
1405
1490
|
color: ColorTokenData,
|
|
1406
|
-
x:
|
|
1407
|
-
y:
|
|
1408
|
-
radius:
|
|
1409
|
-
spread:
|
|
1491
|
+
x: z60.number(),
|
|
1492
|
+
y: z60.number(),
|
|
1493
|
+
radius: z60.number(),
|
|
1494
|
+
spread: z60.number(),
|
|
1410
1495
|
opacity: OpacityTokenData,
|
|
1411
1496
|
type: ShadowType
|
|
1412
1497
|
});
|
|
1413
1498
|
var ShadowTokenDataBase = tokenAliasOrValue(ShadowLayerValue);
|
|
1414
|
-
var ShadowTokenData = tokenAliasOrValue(
|
|
1499
|
+
var ShadowTokenData = tokenAliasOrValue(z60.array(ShadowTokenDataBase));
|
|
1415
1500
|
|
|
1416
1501
|
// src/dsm/elements/data/size.ts
|
|
1417
|
-
import { z as
|
|
1418
|
-
var SizeUnit =
|
|
1419
|
-
var SizeValue =
|
|
1502
|
+
import { z as z61 } from "zod";
|
|
1503
|
+
var SizeUnit = z61.enum(["Pixels", "Rem", "Percent"]);
|
|
1504
|
+
var SizeValue = z61.object({
|
|
1420
1505
|
unit: SizeUnit,
|
|
1421
|
-
measure:
|
|
1506
|
+
measure: z61.number()
|
|
1422
1507
|
});
|
|
1423
1508
|
var SizeTokenData = tokenAliasOrValue(SizeValue);
|
|
1424
1509
|
|
|
1425
1510
|
// src/dsm/elements/data/space.ts
|
|
1426
|
-
import { z as
|
|
1427
|
-
var SpaceUnit =
|
|
1428
|
-
var SpaceValue =
|
|
1511
|
+
import { z as z62 } from "zod";
|
|
1512
|
+
var SpaceUnit = z62.enum(["Pixels", "Rem", "Percent"]);
|
|
1513
|
+
var SpaceValue = z62.object({
|
|
1429
1514
|
unit: SpaceUnit,
|
|
1430
|
-
measure:
|
|
1515
|
+
measure: z62.number()
|
|
1431
1516
|
});
|
|
1432
1517
|
var SpaceTokenData = tokenAliasOrValue(SpaceValue);
|
|
1433
1518
|
|
|
1434
1519
|
// src/dsm/elements/data/string.ts
|
|
1435
|
-
import { z as
|
|
1436
|
-
var StringValue =
|
|
1520
|
+
import { z as z63 } from "zod";
|
|
1521
|
+
var StringValue = z63.string();
|
|
1437
1522
|
var StringTokenData = tokenAliasOrValue(StringValue);
|
|
1438
1523
|
|
|
1439
1524
|
// src/dsm/elements/data/text-case.ts
|
|
1440
|
-
import { z as
|
|
1441
|
-
var TextCase =
|
|
1525
|
+
import { z as z64 } from "zod";
|
|
1526
|
+
var TextCase = z64.enum(["Original", "Upper", "Lower", "Camel", "SmallCaps"]);
|
|
1442
1527
|
var TextCaseValue = TextCase;
|
|
1443
1528
|
var TextCaseTokenData = tokenAliasOrValue(TextCaseValue);
|
|
1444
1529
|
|
|
1445
1530
|
// src/dsm/elements/data/text-decoration.ts
|
|
1446
|
-
import { z as
|
|
1447
|
-
var TextDecoration =
|
|
1531
|
+
import { z as z65 } from "zod";
|
|
1532
|
+
var TextDecoration = z65.enum(["None", "Underline", "Strikethrough"]);
|
|
1448
1533
|
var TextDecorationValue = TextDecoration;
|
|
1449
1534
|
var TextDecorationTokenData = tokenAliasOrValue(TextDecorationValue);
|
|
1450
1535
|
|
|
1451
1536
|
// src/dsm/elements/data/typography.ts
|
|
1452
|
-
import { z as
|
|
1453
|
-
var TypographyValue =
|
|
1537
|
+
import { z as z66 } from "zod";
|
|
1538
|
+
var TypographyValue = z66.object({
|
|
1454
1539
|
fontSize: FontSizeTokenData,
|
|
1455
1540
|
fontFamily: FontFamilyTokenData,
|
|
1456
1541
|
fontWeight: FontWeightTokenData,
|
|
@@ -1464,99 +1549,65 @@ var TypographyValue = z63.object({
|
|
|
1464
1549
|
var TypographyTokenData = tokenAliasOrValue(TypographyValue);
|
|
1465
1550
|
|
|
1466
1551
|
// src/dsm/elements/data/visibility.ts
|
|
1467
|
-
import { z as
|
|
1468
|
-
var Visibility =
|
|
1552
|
+
import { z as z67 } from "zod";
|
|
1553
|
+
var Visibility = z67.enum(["Hidden", "Visible"]);
|
|
1469
1554
|
var VisibilityValue = Visibility;
|
|
1470
1555
|
var VisibilityTokenData = tokenAliasOrValue(VisibilityValue);
|
|
1471
1556
|
|
|
1472
1557
|
// src/dsm/elements/data/z-index.ts
|
|
1473
|
-
import { z as
|
|
1474
|
-
var ZIndexUnit =
|
|
1475
|
-
var ZIndexValue =
|
|
1558
|
+
import { z as z68 } from "zod";
|
|
1559
|
+
var ZIndexUnit = z68.enum(["Raw"]);
|
|
1560
|
+
var ZIndexValue = z68.object({
|
|
1476
1561
|
unit: ZIndexUnit,
|
|
1477
|
-
measure:
|
|
1562
|
+
measure: z68.number()
|
|
1478
1563
|
});
|
|
1479
1564
|
var ZIndexTokenData = tokenAliasOrValue(ZIndexValue);
|
|
1480
1565
|
|
|
1481
|
-
// src/dsm/elements/base.ts
|
|
1482
|
-
import { z as z66 } from "zod";
|
|
1483
|
-
var DesignElementOrigin = z66.object({
|
|
1484
|
-
id: z66.string(),
|
|
1485
|
-
sourceId: z66.string(),
|
|
1486
|
-
name: z66.string()
|
|
1487
|
-
});
|
|
1488
|
-
var DesignElementBase = z66.object({
|
|
1489
|
-
id: z66.string(),
|
|
1490
|
-
persistentId: z66.string(),
|
|
1491
|
-
meta: ObjectMeta,
|
|
1492
|
-
designSystemVersionId: z66.string(),
|
|
1493
|
-
createdAt: z66.coerce.date(),
|
|
1494
|
-
updatedAt: z66.coerce.date()
|
|
1495
|
-
});
|
|
1496
|
-
var DesignElementImportedBase = DesignElementBase.extend({
|
|
1497
|
-
origin: DesignElementOrigin
|
|
1498
|
-
});
|
|
1499
|
-
var DesignElementGroupablePart = z66.object({
|
|
1500
|
-
parentPersistentId: z66.string().optional(),
|
|
1501
|
-
sortOrder: z66.number()
|
|
1502
|
-
});
|
|
1503
|
-
var DesignElementGroupableBase = DesignElementBase.extend(DesignElementGroupablePart.shape);
|
|
1504
|
-
var DesignElementGroupableRequiredPart = DesignElementGroupablePart.extend({
|
|
1505
|
-
parentPersistentId: z66.string()
|
|
1506
|
-
});
|
|
1507
|
-
var DesignElementBrandedPart = z66.object({
|
|
1508
|
-
brandPersistentId: z66.string()
|
|
1509
|
-
});
|
|
1510
|
-
var DesignElementSlugPart = z66.object({
|
|
1511
|
-
slug: z66.string().optional(),
|
|
1512
|
-
userSlug: z66.string().optional()
|
|
1513
|
-
});
|
|
1514
|
-
|
|
1515
1566
|
// src/dsm/elements/component.ts
|
|
1516
|
-
import { z as
|
|
1517
|
-
var ComponentOriginPart =
|
|
1518
|
-
nodeId:
|
|
1519
|
-
width:
|
|
1520
|
-
height:
|
|
1567
|
+
import { z as z69 } from "zod";
|
|
1568
|
+
var ComponentOriginPart = z69.object({
|
|
1569
|
+
nodeId: z69.string().optional(),
|
|
1570
|
+
width: z69.number().optional(),
|
|
1571
|
+
height: z69.number().optional()
|
|
1521
1572
|
});
|
|
1522
|
-
var ComponentAsset =
|
|
1523
|
-
assetId:
|
|
1524
|
-
assetPath:
|
|
1573
|
+
var ComponentAsset = z69.object({
|
|
1574
|
+
assetId: z69.string(),
|
|
1575
|
+
assetPath: z69.string()
|
|
1525
1576
|
});
|
|
1526
1577
|
var ComponentOrigin = DesignElementOrigin.extend(ComponentOriginPart.shape);
|
|
1527
1578
|
var Component = DesignElementBase.extend(DesignElementGroupableRequiredPart.shape).extend(DesignElementBrandedPart.shape).extend({
|
|
1528
1579
|
origin: ComponentOrigin.optional(),
|
|
1529
1580
|
thumbnail: ComponentAsset,
|
|
1530
1581
|
svg: ComponentAsset.optional(),
|
|
1531
|
-
isAsset:
|
|
1582
|
+
isAsset: z69.boolean()
|
|
1532
1583
|
});
|
|
1533
1584
|
function isImportedComponent(component) {
|
|
1534
1585
|
return !!component.origin;
|
|
1535
1586
|
}
|
|
1536
1587
|
|
|
1537
1588
|
// src/dsm/elements/documentation-page-v1.ts
|
|
1538
|
-
import { z as
|
|
1589
|
+
import { z as z70 } from "zod";
|
|
1539
1590
|
var DocumentationPageV1 = DesignElementBase.extend(DesignElementGroupableRequiredPart.shape).extend(DesignElementSlugPart.shape).extend({
|
|
1540
|
-
shortPersistentId:
|
|
1591
|
+
shortPersistentId: z70.string(),
|
|
1541
1592
|
data: DocumentationPageDataV1
|
|
1542
1593
|
});
|
|
1543
1594
|
|
|
1544
1595
|
// src/dsm/elements/documentation-page-v2.ts
|
|
1545
|
-
import { z as
|
|
1596
|
+
import { z as z71 } from "zod";
|
|
1546
1597
|
var DocumentationPageV2 = DesignElementBase.extend(DesignElementGroupableRequiredPart.shape).extend(DesignElementSlugPart.shape).extend({
|
|
1547
|
-
shortPersistentId:
|
|
1598
|
+
shortPersistentId: z71.string(),
|
|
1548
1599
|
data: DocumentationPageDataV2.extend({
|
|
1549
|
-
oldBlocks:
|
|
1600
|
+
oldBlocks: z71.array(PageBlockV1).optional()
|
|
1550
1601
|
})
|
|
1551
1602
|
});
|
|
1552
1603
|
|
|
1553
1604
|
// src/dsm/elements/figma-file-structures.ts
|
|
1554
|
-
import { z as
|
|
1555
|
-
var FigmaFileStructureOrigin =
|
|
1556
|
-
sourceId:
|
|
1557
|
-
fileId:
|
|
1605
|
+
import { z as z72 } from "zod";
|
|
1606
|
+
var FigmaFileStructureOrigin = z72.object({
|
|
1607
|
+
sourceId: z72.string(),
|
|
1608
|
+
fileId: z72.string().optional()
|
|
1558
1609
|
});
|
|
1559
|
-
var FigmaFileStructureData =
|
|
1610
|
+
var FigmaFileStructureData = z72.object({
|
|
1560
1611
|
rootNode: FigmaFileStructureNode,
|
|
1561
1612
|
assetsInFile: FigmaFileStructureStatistics
|
|
1562
1613
|
});
|
|
@@ -1572,9 +1623,9 @@ function traverseStructure(node, action) {
|
|
|
1572
1623
|
}
|
|
1573
1624
|
|
|
1574
1625
|
// src/dsm/elements/figma-node-reference.ts
|
|
1575
|
-
import { z as
|
|
1576
|
-
var FigmaNodeReferenceOrigin =
|
|
1577
|
-
sourceId:
|
|
1626
|
+
import { z as z73 } from "zod";
|
|
1627
|
+
var FigmaNodeReferenceOrigin = z73.object({
|
|
1628
|
+
sourceId: z73.string()
|
|
1578
1629
|
});
|
|
1579
1630
|
var FigmaNodeReference = DesignElementBase.extend({
|
|
1580
1631
|
data: FigmaNodeReferenceData,
|
|
@@ -1582,32 +1633,22 @@ var FigmaNodeReference = DesignElementBase.extend({
|
|
|
1582
1633
|
});
|
|
1583
1634
|
|
|
1584
1635
|
// src/dsm/elements/group.ts
|
|
1585
|
-
import { z as
|
|
1636
|
+
import { z as z74 } from "zod";
|
|
1586
1637
|
var ElementGroup = DesignElementBase.extend(DesignElementGroupablePart.shape).extend(DesignElementSlugPart.shape).extend(DesignElementBrandedPart.partial().shape).extend({
|
|
1587
|
-
shortPersistentId:
|
|
1638
|
+
shortPersistentId: z74.string().optional(),
|
|
1588
1639
|
childType: DesignElementType,
|
|
1589
1640
|
data: ElementGroupDataV2.optional()
|
|
1590
1641
|
});
|
|
1591
1642
|
var BrandedElementGroup = ElementGroup.extend(DesignElementBrandedPart.shape);
|
|
1592
1643
|
|
|
1593
|
-
// src/dsm/elements/page-block-v2.ts
|
|
1594
|
-
import { z as z73 } from "zod";
|
|
1595
|
-
var PageBlockV2 = DesignElementBase.extend(DesignElementGroupableRequiredPart.shape).extend({
|
|
1596
|
-
data: PageBlockDataV2
|
|
1597
|
-
});
|
|
1598
|
-
var PageBlockEditorModelV2 = z73.object({
|
|
1599
|
-
id: z73.string(),
|
|
1600
|
-
data: PageBlockDataV2
|
|
1601
|
-
});
|
|
1602
|
-
|
|
1603
1644
|
// src/dsm/elements/theme.ts
|
|
1604
|
-
import { z as
|
|
1645
|
+
import { z as z76 } from "zod";
|
|
1605
1646
|
|
|
1606
1647
|
// src/dsm/elements/tokens.ts
|
|
1607
|
-
import { z as
|
|
1608
|
-
var DesignTokenOriginPart =
|
|
1609
|
-
referenceOriginId:
|
|
1610
|
-
referencePersistentId:
|
|
1648
|
+
import { z as z75 } from "zod";
|
|
1649
|
+
var DesignTokenOriginPart = z75.object({
|
|
1650
|
+
referenceOriginId: z75.string().optional(),
|
|
1651
|
+
referencePersistentId: z75.string().optional()
|
|
1611
1652
|
});
|
|
1612
1653
|
var DesignTokenOrigin = DesignElementOrigin.extend(DesignTokenOriginPart.shape);
|
|
1613
1654
|
var DesignTokenBase = DesignElementBase.extend(DesignElementGroupableRequiredPart.shape).extend(DesignElementBrandedPart.shape).extend({
|
|
@@ -1619,111 +1660,111 @@ var UpdateDesignTokenBase = DesignTokenBase.omit({
|
|
|
1619
1660
|
brandPersistentId: true,
|
|
1620
1661
|
designSystemVersionId: true
|
|
1621
1662
|
});
|
|
1622
|
-
var BlurTokenTypedData =
|
|
1623
|
-
type:
|
|
1663
|
+
var BlurTokenTypedData = z75.object({
|
|
1664
|
+
type: z75.literal("Blur"),
|
|
1624
1665
|
data: BlurTokenData
|
|
1625
1666
|
});
|
|
1626
|
-
var ColorTokenTypedData =
|
|
1627
|
-
type:
|
|
1667
|
+
var ColorTokenTypedData = z75.object({
|
|
1668
|
+
type: z75.literal("Color"),
|
|
1628
1669
|
data: ColorTokenData
|
|
1629
1670
|
});
|
|
1630
|
-
var GradientTokenTypedData =
|
|
1631
|
-
type:
|
|
1671
|
+
var GradientTokenTypedData = z75.object({
|
|
1672
|
+
type: z75.literal("Gradient"),
|
|
1632
1673
|
data: GradientTokenData
|
|
1633
1674
|
});
|
|
1634
|
-
var OpacityTokenTypedData =
|
|
1635
|
-
type:
|
|
1675
|
+
var OpacityTokenTypedData = z75.object({
|
|
1676
|
+
type: z75.literal("Opacity"),
|
|
1636
1677
|
data: OpacityTokenData
|
|
1637
1678
|
});
|
|
1638
|
-
var ShadowTokenTypedData =
|
|
1639
|
-
type:
|
|
1679
|
+
var ShadowTokenTypedData = z75.object({
|
|
1680
|
+
type: z75.literal("Shadow"),
|
|
1640
1681
|
data: ShadowTokenData
|
|
1641
1682
|
});
|
|
1642
|
-
var TypographyTokenTypedData =
|
|
1643
|
-
type:
|
|
1683
|
+
var TypographyTokenTypedData = z75.object({
|
|
1684
|
+
type: z75.literal("Typography"),
|
|
1644
1685
|
data: TypographyTokenData
|
|
1645
1686
|
});
|
|
1646
|
-
var StringTokenTypedData =
|
|
1647
|
-
type:
|
|
1687
|
+
var StringTokenTypedData = z75.object({
|
|
1688
|
+
type: z75.literal("String"),
|
|
1648
1689
|
data: StringTokenData
|
|
1649
1690
|
});
|
|
1650
|
-
var DimensionTokenTypedData =
|
|
1651
|
-
type:
|
|
1691
|
+
var DimensionTokenTypedData = z75.object({
|
|
1692
|
+
type: z75.literal("Dimension"),
|
|
1652
1693
|
data: DimensionTokenData
|
|
1653
1694
|
});
|
|
1654
|
-
var FontSizeTokenTypedData =
|
|
1655
|
-
type:
|
|
1695
|
+
var FontSizeTokenTypedData = z75.object({
|
|
1696
|
+
type: z75.literal("FontSize"),
|
|
1656
1697
|
data: FontSizeTokenData
|
|
1657
1698
|
});
|
|
1658
|
-
var FontFamilyTokenTypedData =
|
|
1659
|
-
type:
|
|
1699
|
+
var FontFamilyTokenTypedData = z75.object({
|
|
1700
|
+
type: z75.literal("FontFamily"),
|
|
1660
1701
|
data: FontFamilyTokenData
|
|
1661
1702
|
});
|
|
1662
|
-
var FontWeightTokenTypedData =
|
|
1663
|
-
type:
|
|
1703
|
+
var FontWeightTokenTypedData = z75.object({
|
|
1704
|
+
type: z75.literal("FontWeight"),
|
|
1664
1705
|
data: FontWeightTokenData
|
|
1665
1706
|
});
|
|
1666
|
-
var LetterSpacingTokenTypedData =
|
|
1667
|
-
type:
|
|
1707
|
+
var LetterSpacingTokenTypedData = z75.object({
|
|
1708
|
+
type: z75.literal("LetterSpacing"),
|
|
1668
1709
|
data: LetterSpacingTokenData
|
|
1669
1710
|
});
|
|
1670
|
-
var LineHeightTokenTypedData =
|
|
1671
|
-
type:
|
|
1711
|
+
var LineHeightTokenTypedData = z75.object({
|
|
1712
|
+
type: z75.literal("LineHeight"),
|
|
1672
1713
|
data: LineHeightTokenData
|
|
1673
1714
|
});
|
|
1674
|
-
var ParagraphSpacingTokenTypedData =
|
|
1675
|
-
type:
|
|
1715
|
+
var ParagraphSpacingTokenTypedData = z75.object({
|
|
1716
|
+
type: z75.literal("ParagraphSpacing"),
|
|
1676
1717
|
data: ParagraphSpacingTokenData
|
|
1677
1718
|
});
|
|
1678
|
-
var TextCaseTokenTypedData =
|
|
1679
|
-
type:
|
|
1719
|
+
var TextCaseTokenTypedData = z75.object({
|
|
1720
|
+
type: z75.literal("TextCase"),
|
|
1680
1721
|
data: TextCaseTokenData
|
|
1681
1722
|
});
|
|
1682
|
-
var TextDecorationTokenTypedData =
|
|
1683
|
-
type:
|
|
1723
|
+
var TextDecorationTokenTypedData = z75.object({
|
|
1724
|
+
type: z75.literal("TextDecoration"),
|
|
1684
1725
|
data: TextDecorationTokenData
|
|
1685
1726
|
});
|
|
1686
|
-
var BorderRadiusTokenTypedData =
|
|
1687
|
-
type:
|
|
1727
|
+
var BorderRadiusTokenTypedData = z75.object({
|
|
1728
|
+
type: z75.literal("BorderRadius"),
|
|
1688
1729
|
data: BorderRadiusTokenData
|
|
1689
1730
|
});
|
|
1690
|
-
var BorderWidthTokenTypedData =
|
|
1691
|
-
type:
|
|
1731
|
+
var BorderWidthTokenTypedData = z75.object({
|
|
1732
|
+
type: z75.literal("BorderWidth"),
|
|
1692
1733
|
data: BorderWidthTokenData
|
|
1693
1734
|
});
|
|
1694
|
-
var BorderTypedData =
|
|
1695
|
-
type:
|
|
1735
|
+
var BorderTypedData = z75.object({
|
|
1736
|
+
type: z75.literal("Border"),
|
|
1696
1737
|
data: BorderTokenData
|
|
1697
1738
|
});
|
|
1698
|
-
var ProductCopyTypedData =
|
|
1699
|
-
type:
|
|
1739
|
+
var ProductCopyTypedData = z75.object({
|
|
1740
|
+
type: z75.literal("ProductCopy"),
|
|
1700
1741
|
data: ProductCopyTokenData
|
|
1701
1742
|
});
|
|
1702
|
-
var SizeTypedData =
|
|
1703
|
-
type:
|
|
1743
|
+
var SizeTypedData = z75.object({
|
|
1744
|
+
type: z75.literal("Size"),
|
|
1704
1745
|
data: SizeTokenData
|
|
1705
1746
|
});
|
|
1706
|
-
var SpaceTypedData =
|
|
1707
|
-
type:
|
|
1747
|
+
var SpaceTypedData = z75.object({
|
|
1748
|
+
type: z75.literal("Space"),
|
|
1708
1749
|
data: SpaceTokenData
|
|
1709
1750
|
});
|
|
1710
|
-
var VisibilityTypedData =
|
|
1711
|
-
type:
|
|
1751
|
+
var VisibilityTypedData = z75.object({
|
|
1752
|
+
type: z75.literal("Visibility"),
|
|
1712
1753
|
data: VisibilityTokenData
|
|
1713
1754
|
});
|
|
1714
|
-
var ZIndexTypedData =
|
|
1715
|
-
type:
|
|
1755
|
+
var ZIndexTypedData = z75.object({
|
|
1756
|
+
type: z75.literal("ZIndex"),
|
|
1716
1757
|
data: ZIndexTokenData
|
|
1717
1758
|
});
|
|
1718
|
-
var DurationTypedData =
|
|
1719
|
-
type:
|
|
1759
|
+
var DurationTypedData = z75.object({
|
|
1760
|
+
type: z75.literal("Duration"),
|
|
1720
1761
|
data: DurationTokenData
|
|
1721
1762
|
});
|
|
1722
|
-
var FontTypedData =
|
|
1723
|
-
type:
|
|
1724
|
-
data:
|
|
1763
|
+
var FontTypedData = z75.object({
|
|
1764
|
+
type: z75.literal("Font"),
|
|
1765
|
+
data: z75.record(z75.any())
|
|
1725
1766
|
});
|
|
1726
|
-
var DesignTokenTypedData =
|
|
1767
|
+
var DesignTokenTypedData = z75.discriminatedUnion("type", [
|
|
1727
1768
|
BlurTokenTypedData,
|
|
1728
1769
|
BorderRadiusTokenTypedData,
|
|
1729
1770
|
BorderWidthTokenTypedData,
|
|
@@ -1773,156 +1814,160 @@ function designTokenTypeFilter(type) {
|
|
|
1773
1814
|
var ThemeOverrideOriginPart = DesignTokenOriginPart;
|
|
1774
1815
|
var ThemeOverrideOrigin = DesignTokenOrigin;
|
|
1775
1816
|
var ThemeOverride = DesignTokenTypedData.and(
|
|
1776
|
-
|
|
1777
|
-
tokenPersistentId:
|
|
1817
|
+
z76.object({
|
|
1818
|
+
tokenPersistentId: z76.string(),
|
|
1778
1819
|
origin: ThemeOverrideOrigin.optional().nullable().transform((v) => v ?? void 0)
|
|
1779
1820
|
})
|
|
1780
1821
|
);
|
|
1781
|
-
var ThemeElementData =
|
|
1782
|
-
value:
|
|
1783
|
-
overrides:
|
|
1822
|
+
var ThemeElementData = z76.object({
|
|
1823
|
+
value: z76.object({
|
|
1824
|
+
overrides: z76.array(ThemeOverride)
|
|
1784
1825
|
})
|
|
1785
1826
|
});
|
|
1786
|
-
var ThemeOriginPart =
|
|
1787
|
-
var ThemeOriginObject =
|
|
1788
|
-
id:
|
|
1789
|
-
name:
|
|
1827
|
+
var ThemeOriginPart = z76.object({});
|
|
1828
|
+
var ThemeOriginObject = z76.object({
|
|
1829
|
+
id: z76.string(),
|
|
1830
|
+
name: z76.string()
|
|
1790
1831
|
});
|
|
1791
|
-
var ThemeOriginSource =
|
|
1792
|
-
sourceId:
|
|
1793
|
-
sourceObjects:
|
|
1832
|
+
var ThemeOriginSource = z76.object({
|
|
1833
|
+
sourceId: z76.string(),
|
|
1834
|
+
sourceObjects: z76.array(ThemeOriginObject)
|
|
1794
1835
|
});
|
|
1795
|
-
var ThemeOrigin =
|
|
1796
|
-
sources:
|
|
1836
|
+
var ThemeOrigin = z76.object({
|
|
1837
|
+
sources: z76.array(ThemeOriginSource)
|
|
1797
1838
|
});
|
|
1798
1839
|
var Theme = DesignElementBase.extend(DesignElementBrandedPart.shape).extend({
|
|
1799
1840
|
origin: ThemeOrigin.optional(),
|
|
1800
|
-
overrides:
|
|
1841
|
+
overrides: z76.array(ThemeOverride)
|
|
1801
1842
|
});
|
|
1802
1843
|
|
|
1803
1844
|
// src/dsm/import/support/figma-files.ts
|
|
1804
|
-
import { z as
|
|
1805
|
-
var FigmaFileDownloadScope =
|
|
1806
|
-
styles:
|
|
1807
|
-
components:
|
|
1808
|
-
currentVersion:
|
|
1809
|
-
publishedVersion:
|
|
1810
|
-
downloadChunkSize:
|
|
1845
|
+
import { z as z77 } from "zod";
|
|
1846
|
+
var FigmaFileDownloadScope = z77.object({
|
|
1847
|
+
styles: z77.boolean(),
|
|
1848
|
+
components: z77.boolean(),
|
|
1849
|
+
currentVersion: z77.literal("__latest__").nullable(),
|
|
1850
|
+
publishedVersion: z77.string().nullable(),
|
|
1851
|
+
downloadChunkSize: z77.number().optional(),
|
|
1852
|
+
maxFileDepth: z77.number().optional()
|
|
1811
1853
|
});
|
|
1812
|
-
var FigmaFileAccessData =
|
|
1813
|
-
accessToken:
|
|
1854
|
+
var FigmaFileAccessData = z77.object({
|
|
1855
|
+
accessToken: z77.string()
|
|
1814
1856
|
});
|
|
1815
1857
|
|
|
1816
1858
|
// src/dsm/import/support/import-context.ts
|
|
1817
|
-
import { z as
|
|
1818
|
-
var ImportFunctionInput =
|
|
1819
|
-
importJobId:
|
|
1820
|
-
importContextId:
|
|
1821
|
-
designSystemId:
|
|
1859
|
+
import { z as z78 } from "zod";
|
|
1860
|
+
var ImportFunctionInput = z78.object({
|
|
1861
|
+
importJobId: z78.string(),
|
|
1862
|
+
importContextId: z78.string(),
|
|
1863
|
+
designSystemId: z78.string().optional()
|
|
1822
1864
|
});
|
|
1823
|
-
var ImportedFigmaSourceData =
|
|
1824
|
-
sourceId:
|
|
1865
|
+
var ImportedFigmaSourceData = z78.object({
|
|
1866
|
+
sourceId: z78.string(),
|
|
1825
1867
|
figmaRemote: DataSourceFigmaRemote
|
|
1826
1868
|
});
|
|
1827
|
-
var FigmaImportBaseContext =
|
|
1828
|
-
designSystemId:
|
|
1869
|
+
var FigmaImportBaseContext = z78.object({
|
|
1870
|
+
designSystemId: z78.string(),
|
|
1829
1871
|
/**
|
|
1830
1872
|
* Data required for accessing Figma files. This should contain access data for all file ids
|
|
1831
1873
|
* mentioned in the `importedSourceDataBySourceId`
|
|
1832
1874
|
*
|
|
1833
1875
|
* fileId: file data
|
|
1834
1876
|
*/
|
|
1835
|
-
fileAccessByFileId:
|
|
1877
|
+
fileAccessByFileId: z78.record(FigmaFileAccessData),
|
|
1836
1878
|
/**
|
|
1837
1879
|
* Figma source data for which import was requested
|
|
1838
1880
|
*
|
|
1839
1881
|
* sourceId: source data
|
|
1840
1882
|
*/
|
|
1841
|
-
importedSourceDataBySourceId:
|
|
1883
|
+
importedSourceDataBySourceId: z78.record(ImportedFigmaSourceData)
|
|
1884
|
+
});
|
|
1885
|
+
var FigmaImportContextWithSourcesState = FigmaImportBaseContext.extend({
|
|
1886
|
+
sourcesWithMissingAccess: z78.array(z78.string()).default([])
|
|
1842
1887
|
});
|
|
1843
1888
|
var ChangedImportedFigmaSourceData = ImportedFigmaSourceData.extend({
|
|
1844
1889
|
importMetadata: DataSourceFigmaImportMetadata
|
|
1845
1890
|
});
|
|
1846
|
-
var FigmaImportContextWithDownloadScopes =
|
|
1891
|
+
var FigmaImportContextWithDownloadScopes = FigmaImportContextWithSourcesState.extend({
|
|
1847
1892
|
/**
|
|
1848
1893
|
* Describes what to download from each file, this should contain all file id mentioned in
|
|
1849
1894
|
* importMetadataBySourceId.
|
|
1850
1895
|
*
|
|
1851
1896
|
* File id -> file download scope
|
|
1852
1897
|
*/
|
|
1853
|
-
fileDownloadScopesByFileId:
|
|
1898
|
+
fileDownloadScopesByFileId: z78.record(FigmaFileDownloadScope),
|
|
1854
1899
|
/**
|
|
1855
1900
|
* Sources filtered down to the ones that have changed since last import and therefore need to be
|
|
1856
1901
|
* imported again.
|
|
1857
1902
|
*
|
|
1858
1903
|
* Source id -> import metadata
|
|
1859
1904
|
*/
|
|
1860
|
-
changedImportedSourceDataBySourceId:
|
|
1905
|
+
changedImportedSourceDataBySourceId: z78.record(ChangedImportedFigmaSourceData)
|
|
1861
1906
|
});
|
|
1862
1907
|
|
|
1863
1908
|
// src/dsm/import/support/import-model-collections.ts
|
|
1864
|
-
import { z as
|
|
1909
|
+
import { z as z86 } from "zod";
|
|
1865
1910
|
|
|
1866
1911
|
// src/dsm/import/image.ts
|
|
1867
|
-
import { z as
|
|
1868
|
-
var ImageImportModelType =
|
|
1869
|
-
var ImageImportModelBase =
|
|
1912
|
+
import { z as z79 } from "zod";
|
|
1913
|
+
var ImageImportModelType = z79.enum(["Url", "FigmaRender"]);
|
|
1914
|
+
var ImageImportModelBase = z79.object({
|
|
1870
1915
|
scope: AssetScope
|
|
1871
1916
|
});
|
|
1872
1917
|
var UrlImageImportModel = ImageImportModelBase.extend({
|
|
1873
|
-
type:
|
|
1874
|
-
url:
|
|
1875
|
-
originKey:
|
|
1876
|
-
extension:
|
|
1918
|
+
type: z79.literal(ImageImportModelType.enum.Url),
|
|
1919
|
+
url: z79.string(),
|
|
1920
|
+
originKey: z79.string(),
|
|
1921
|
+
extension: z79.string()
|
|
1877
1922
|
});
|
|
1878
|
-
var FigmaRenderFormat =
|
|
1923
|
+
var FigmaRenderFormat = z79.enum(["Svg", "Png"]);
|
|
1879
1924
|
var FigmaRenderBase = ImageImportModelBase.extend({
|
|
1880
|
-
type:
|
|
1881
|
-
fileId:
|
|
1882
|
-
fileVersionId:
|
|
1883
|
-
nodeId:
|
|
1884
|
-
originKey:
|
|
1925
|
+
type: z79.literal(ImageImportModelType.enum.FigmaRender),
|
|
1926
|
+
fileId: z79.string(),
|
|
1927
|
+
fileVersionId: z79.string().optional(),
|
|
1928
|
+
nodeId: z79.string(),
|
|
1929
|
+
originKey: z79.string()
|
|
1885
1930
|
});
|
|
1886
1931
|
var FigmaPngRenderImportModel = FigmaRenderBase.extend({
|
|
1887
|
-
format:
|
|
1888
|
-
scale:
|
|
1932
|
+
format: z79.literal(FigmaRenderFormat.enum.Png),
|
|
1933
|
+
scale: z79.number()
|
|
1889
1934
|
});
|
|
1890
1935
|
var FigmaSvgRenderImportModel = FigmaRenderBase.extend({
|
|
1891
|
-
format:
|
|
1936
|
+
format: z79.literal(FigmaRenderFormat.enum.Svg)
|
|
1892
1937
|
});
|
|
1893
|
-
var FigmaRenderImportModel =
|
|
1938
|
+
var FigmaRenderImportModel = z79.discriminatedUnion("format", [
|
|
1894
1939
|
FigmaPngRenderImportModel,
|
|
1895
1940
|
FigmaSvgRenderImportModel
|
|
1896
1941
|
]);
|
|
1897
|
-
var ImageImportModel =
|
|
1942
|
+
var ImageImportModel = z79.union([UrlImageImportModel, FigmaRenderImportModel]);
|
|
1898
1943
|
|
|
1899
1944
|
// src/dsm/import/component.ts
|
|
1900
|
-
import { z as
|
|
1945
|
+
import { z as z81 } from "zod";
|
|
1901
1946
|
|
|
1902
1947
|
// src/dsm/import/base.ts
|
|
1903
|
-
import { z as
|
|
1904
|
-
var ImportModelBase =
|
|
1905
|
-
id:
|
|
1948
|
+
import { z as z80 } from "zod";
|
|
1949
|
+
var ImportModelBase = z80.object({
|
|
1950
|
+
id: z80.string(),
|
|
1906
1951
|
meta: ObjectMeta,
|
|
1907
1952
|
origin: DesignElementOrigin,
|
|
1908
|
-
brandPersistentId:
|
|
1909
|
-
sortOrder:
|
|
1953
|
+
brandPersistentId: z80.string(),
|
|
1954
|
+
sortOrder: z80.number()
|
|
1910
1955
|
});
|
|
1911
1956
|
var ImportModelInputBase = ImportModelBase.omit({
|
|
1912
1957
|
brandPersistentId: true,
|
|
1913
1958
|
origin: true,
|
|
1914
1959
|
sortOrder: true
|
|
1915
1960
|
}).extend({
|
|
1916
|
-
originId:
|
|
1917
|
-
originMetadata:
|
|
1961
|
+
originId: z80.string(),
|
|
1962
|
+
originMetadata: z80.record(z80.any())
|
|
1918
1963
|
});
|
|
1919
1964
|
|
|
1920
1965
|
// src/dsm/import/component.ts
|
|
1921
|
-
var ComponentImportModelPart =
|
|
1966
|
+
var ComponentImportModelPart = z81.object({
|
|
1922
1967
|
thumbnail: ImageImportModel
|
|
1923
1968
|
});
|
|
1924
1969
|
var ComponentImportModel = ImportModelBase.extend(ComponentImportModelPart.shape).extend({
|
|
1925
|
-
isAsset:
|
|
1970
|
+
isAsset: z81.boolean(),
|
|
1926
1971
|
svg: FigmaSvgRenderImportModel.optional(),
|
|
1927
1972
|
origin: ComponentOrigin
|
|
1928
1973
|
});
|
|
@@ -1935,49 +1980,49 @@ var AssetImportModelInput = ImportModelInputBase.extend(ComponentImportModelPart
|
|
|
1935
1980
|
});
|
|
1936
1981
|
|
|
1937
1982
|
// src/dsm/import/theme.ts
|
|
1938
|
-
import { z as
|
|
1983
|
+
import { z as z82 } from "zod";
|
|
1939
1984
|
var ThemeOverrideImportModelBase = DesignTokenTypedData.and(
|
|
1940
|
-
|
|
1941
|
-
id:
|
|
1985
|
+
z82.object({
|
|
1986
|
+
id: z82.string(),
|
|
1942
1987
|
meta: ObjectMeta
|
|
1943
1988
|
})
|
|
1944
1989
|
);
|
|
1945
1990
|
var ThemeOverrideImportModel = ThemeOverrideImportModelBase.and(
|
|
1946
|
-
|
|
1991
|
+
z82.object({
|
|
1947
1992
|
origin: ThemeOverrideOrigin
|
|
1948
1993
|
})
|
|
1949
1994
|
);
|
|
1950
1995
|
var ThemeOverrideImportModelInput = ThemeOverrideImportModelBase.and(
|
|
1951
|
-
|
|
1952
|
-
originId:
|
|
1996
|
+
z82.object({
|
|
1997
|
+
originId: z82.string(),
|
|
1953
1998
|
originMetadata: ThemeOverrideOriginPart
|
|
1954
1999
|
})
|
|
1955
2000
|
);
|
|
1956
|
-
var ThemeImportModel =
|
|
2001
|
+
var ThemeImportModel = z82.object({
|
|
1957
2002
|
meta: ObjectMeta,
|
|
1958
|
-
brandPersistentId:
|
|
2003
|
+
brandPersistentId: z82.string(),
|
|
1959
2004
|
originSource: ThemeOriginSource,
|
|
1960
|
-
overrides:
|
|
1961
|
-
sortOrder:
|
|
2005
|
+
overrides: z82.array(ThemeOverrideImportModel),
|
|
2006
|
+
sortOrder: z82.number()
|
|
1962
2007
|
});
|
|
1963
|
-
var ThemeImportModelInput =
|
|
2008
|
+
var ThemeImportModelInput = z82.object({
|
|
1964
2009
|
meta: ObjectMeta,
|
|
1965
|
-
originObjects:
|
|
1966
|
-
overrides:
|
|
2010
|
+
originObjects: z82.array(ThemeOriginObject),
|
|
2011
|
+
overrides: z82.array(ThemeOverrideImportModelInput)
|
|
1967
2012
|
});
|
|
1968
|
-
var ThemeUpdateImportModel =
|
|
1969
|
-
themePersistentId:
|
|
1970
|
-
overrides:
|
|
2013
|
+
var ThemeUpdateImportModel = z82.object({
|
|
2014
|
+
themePersistentId: z82.string(),
|
|
2015
|
+
overrides: z82.array(ThemeOverrideImportModel)
|
|
1971
2016
|
});
|
|
1972
|
-
var ThemeUpdateImportModelInput =
|
|
1973
|
-
themePersistentId:
|
|
1974
|
-
overrides:
|
|
2017
|
+
var ThemeUpdateImportModelInput = z82.object({
|
|
2018
|
+
themePersistentId: z82.string(),
|
|
2019
|
+
overrides: z82.array(ThemeOverrideImportModelInput)
|
|
1975
2020
|
});
|
|
1976
2021
|
|
|
1977
2022
|
// src/dsm/import/tokens.ts
|
|
1978
|
-
import { z as
|
|
1979
|
-
var DesignTokenImportModelPart =
|
|
1980
|
-
collection:
|
|
2023
|
+
import { z as z83 } from "zod";
|
|
2024
|
+
var DesignTokenImportModelPart = z83.object({
|
|
2025
|
+
collection: z83.string().optional()
|
|
1981
2026
|
});
|
|
1982
2027
|
var DesignTokenImportModelBase = ImportModelBase.extend(DesignTokenImportModelPart.shape).extend({
|
|
1983
2028
|
origin: DesignTokenOrigin
|
|
@@ -1995,15 +2040,15 @@ function designTokenImportModelTypeFilter(type) {
|
|
|
1995
2040
|
}
|
|
1996
2041
|
|
|
1997
2042
|
// src/dsm/import/figma-frames.ts
|
|
1998
|
-
import { z as
|
|
2043
|
+
import { z as z84 } from "zod";
|
|
1999
2044
|
var FigmaFileStructureNodeImportModelBase = FigmaFileStructureNodeBase.extend({
|
|
2000
2045
|
image: FigmaPngRenderImportModel
|
|
2001
2046
|
});
|
|
2002
2047
|
var FigmaFileStructureNodeImportModel = FigmaFileStructureNodeImportModelBase.extend({
|
|
2003
|
-
children:
|
|
2048
|
+
children: z84.lazy(() => FigmaFileStructureNodeImportModel.array())
|
|
2004
2049
|
});
|
|
2005
|
-
var FigmaFileStructureImportModelPart =
|
|
2006
|
-
data:
|
|
2050
|
+
var FigmaFileStructureImportModelPart = z84.object({
|
|
2051
|
+
data: z84.object({
|
|
2007
2052
|
rootNode: FigmaFileStructureNodeImportModel,
|
|
2008
2053
|
assetsInFile: FigmaFileStructureStatistics
|
|
2009
2054
|
})
|
|
@@ -2014,7 +2059,7 @@ var FigmaFileStructureImportModel = ImportModelBase.extend(FigmaFileStructureImp
|
|
|
2014
2059
|
var FigmaFileStructureImportModelInput = ImportModelInputBase.extend(
|
|
2015
2060
|
FigmaFileStructureImportModelPart.shape
|
|
2016
2061
|
).extend({
|
|
2017
|
-
fileVersionId:
|
|
2062
|
+
fileVersionId: z84.string()
|
|
2018
2063
|
});
|
|
2019
2064
|
function figmaFileStructureImportModelToMap(root) {
|
|
2020
2065
|
const map = /* @__PURE__ */ new Map();
|
|
@@ -2028,30 +2073,30 @@ function recursiveFigmaFileStructureToMap2(node, map) {
|
|
|
2028
2073
|
}
|
|
2029
2074
|
|
|
2030
2075
|
// src/dsm/import/data-source.ts
|
|
2031
|
-
import { z as
|
|
2032
|
-
var DataSourceImportModel =
|
|
2033
|
-
id:
|
|
2034
|
-
fileName:
|
|
2035
|
-
thumbnailUrl:
|
|
2076
|
+
import { z as z85 } from "zod";
|
|
2077
|
+
var DataSourceImportModel = z85.object({
|
|
2078
|
+
id: z85.string(),
|
|
2079
|
+
fileName: z85.string().optional(),
|
|
2080
|
+
thumbnailUrl: z85.string().optional()
|
|
2036
2081
|
});
|
|
2037
2082
|
|
|
2038
2083
|
// src/dsm/import/support/import-model-collections.ts
|
|
2039
|
-
var ImportModelInputCollection =
|
|
2084
|
+
var ImportModelInputCollection = z86.object({
|
|
2040
2085
|
source: DataSourceImportModel,
|
|
2041
|
-
tokens:
|
|
2042
|
-
components:
|
|
2043
|
-
assets:
|
|
2044
|
-
themeUpdates:
|
|
2045
|
-
themes:
|
|
2086
|
+
tokens: z86.array(DesignTokenImportModelInput).default([]),
|
|
2087
|
+
components: z86.array(ComponentImportModelInput).default([]),
|
|
2088
|
+
assets: z86.array(AssetImportModelInput).default([]),
|
|
2089
|
+
themeUpdates: z86.array(ThemeUpdateImportModelInput).default([]),
|
|
2090
|
+
themes: z86.array(ThemeImportModelInput).default([]),
|
|
2046
2091
|
figmaFileStructure: FigmaFileStructureImportModelInput.optional()
|
|
2047
2092
|
});
|
|
2048
|
-
var ImportModelCollection =
|
|
2049
|
-
sources:
|
|
2050
|
-
tokens:
|
|
2051
|
-
components:
|
|
2052
|
-
themeUpdates:
|
|
2053
|
-
themes:
|
|
2054
|
-
figmaFileStructures:
|
|
2093
|
+
var ImportModelCollection = z86.object({
|
|
2094
|
+
sources: z86.array(DataSourceImportModel),
|
|
2095
|
+
tokens: z86.array(DesignTokenImportModel).default([]),
|
|
2096
|
+
components: z86.array(ComponentImportModel).default([]),
|
|
2097
|
+
themeUpdates: z86.array(ThemeUpdateImportModel).default([]),
|
|
2098
|
+
themes: z86.array(ThemeImportModel).default([]),
|
|
2099
|
+
figmaFileStructures: z86.array(FigmaFileStructureImportModel)
|
|
2055
2100
|
});
|
|
2056
2101
|
function addImportModelCollections(lhs, rhs) {
|
|
2057
2102
|
return {
|
|
@@ -2065,8 +2110,8 @@ function addImportModelCollections(lhs, rhs) {
|
|
|
2065
2110
|
}
|
|
2066
2111
|
|
|
2067
2112
|
// src/dsm/import/warning.ts
|
|
2068
|
-
import { z as
|
|
2069
|
-
var ImportWarningType =
|
|
2113
|
+
import { z as z87 } from "zod";
|
|
2114
|
+
var ImportWarningType = z87.enum([
|
|
2070
2115
|
"NoVersionFound",
|
|
2071
2116
|
"UnsupportedFill",
|
|
2072
2117
|
"UnsupportedStroke",
|
|
@@ -2080,27 +2125,27 @@ var ImportWarningType = z86.enum([
|
|
|
2080
2125
|
"DuplicateImportedStyleId",
|
|
2081
2126
|
"DuplicateImportedStylePath"
|
|
2082
2127
|
]);
|
|
2083
|
-
var ImportWarning =
|
|
2128
|
+
var ImportWarning = z87.object({
|
|
2084
2129
|
warningType: ImportWarningType,
|
|
2085
|
-
componentId:
|
|
2086
|
-
componentName:
|
|
2087
|
-
styleId:
|
|
2088
|
-
styleName:
|
|
2089
|
-
unsupportedStyleValueType:
|
|
2130
|
+
componentId: z87.string().optional(),
|
|
2131
|
+
componentName: z87.string().optional(),
|
|
2132
|
+
styleId: z87.string().optional(),
|
|
2133
|
+
styleName: z87.string().optional(),
|
|
2134
|
+
unsupportedStyleValueType: z87.string().optional()
|
|
2090
2135
|
});
|
|
2091
2136
|
|
|
2092
2137
|
// src/dsm/data-sources/import-summary.ts
|
|
2093
|
-
var FileStructureStats =
|
|
2138
|
+
var FileStructureStats = z88.object({
|
|
2094
2139
|
frames: zeroNumberByDefault2(),
|
|
2095
2140
|
components: zeroNumberByDefault2(),
|
|
2096
2141
|
componentSets: zeroNumberByDefault2()
|
|
2097
2142
|
});
|
|
2098
2143
|
var SourceImportSummaryByTokenTypeKey = DesignTokenType.or(
|
|
2099
2144
|
// Backward compatibility
|
|
2100
|
-
|
|
2145
|
+
z88.enum(["Measure", "Radius", "GenericToken", "Font", "Text"])
|
|
2101
2146
|
);
|
|
2102
|
-
var SourceImportSummaryByTokenType =
|
|
2103
|
-
var SourceImportTokenSummary =
|
|
2147
|
+
var SourceImportSummaryByTokenType = z88.record(SourceImportSummaryByTokenTypeKey, z88.number());
|
|
2148
|
+
var SourceImportTokenSummary = z88.object({
|
|
2104
2149
|
tokensCreated: zeroNumberByDefault2(),
|
|
2105
2150
|
tokensUpdated: zeroNumberByDefault2(),
|
|
2106
2151
|
tokensDeleted: zeroNumberByDefault2(),
|
|
@@ -2108,7 +2153,7 @@ var SourceImportTokenSummary = z87.object({
|
|
|
2108
2153
|
tokensUpdatedPerType: SourceImportSummaryByTokenType.nullish().transform((v) => v ?? {}),
|
|
2109
2154
|
tokensDeletedPerType: SourceImportSummaryByTokenType.nullish().transform((v) => v ?? {})
|
|
2110
2155
|
});
|
|
2111
|
-
var SourceImportComponentSummary =
|
|
2156
|
+
var SourceImportComponentSummary = z88.object({
|
|
2112
2157
|
componentsCreated: zeroNumberByDefault2(),
|
|
2113
2158
|
componentsUpdated: zeroNumberByDefault2(),
|
|
2114
2159
|
componentsDeleted: zeroNumberByDefault2(),
|
|
@@ -2116,68 +2161,68 @@ var SourceImportComponentSummary = z87.object({
|
|
|
2116
2161
|
componentAssetsUpdated: zeroNumberByDefault2(),
|
|
2117
2162
|
componentAssetsDeleted: zeroNumberByDefault2()
|
|
2118
2163
|
});
|
|
2119
|
-
var SourceImportFrameSummary =
|
|
2164
|
+
var SourceImportFrameSummary = z88.object({
|
|
2120
2165
|
assetsInFile: nullishToOptional(FileStructureStats.optional()),
|
|
2121
|
-
invalidReferencesCount: nullishToOptional(
|
|
2122
|
-
});
|
|
2123
|
-
var SourceImportSummary =
|
|
2124
|
-
sourceId: nullishToOptional(
|
|
2125
|
-
brandId: nullishToOptional(
|
|
2126
|
-
versionId: nullishToOptional(
|
|
2127
|
-
error: nullishToOptional(
|
|
2128
|
-
isFailed:
|
|
2129
|
-
warnings:
|
|
2166
|
+
invalidReferencesCount: nullishToOptional(z88.number().optional())
|
|
2167
|
+
});
|
|
2168
|
+
var SourceImportSummary = z88.object({
|
|
2169
|
+
sourceId: nullishToOptional(z88.string()),
|
|
2170
|
+
brandId: nullishToOptional(z88.string()),
|
|
2171
|
+
versionId: nullishToOptional(z88.string()),
|
|
2172
|
+
error: nullishToOptional(z88.any()),
|
|
2173
|
+
isFailed: z88.boolean(),
|
|
2174
|
+
warnings: z88.array(ImportWarning).nullish().transform((v) => v ?? []),
|
|
2130
2175
|
...SourceImportTokenSummary.shape,
|
|
2131
2176
|
...SourceImportComponentSummary.shape,
|
|
2132
2177
|
...FileStructureStats.shape
|
|
2133
2178
|
});
|
|
2134
2179
|
function zeroNumberByDefault2() {
|
|
2135
|
-
return
|
|
2180
|
+
return z88.number().nullish().transform((v) => v ?? 0);
|
|
2136
2181
|
}
|
|
2137
2182
|
|
|
2138
2183
|
// src/dsm/documentation/block-definitions/aux.ts
|
|
2139
|
-
import { z as
|
|
2140
|
-
var PageBlockDefinitionAppearance =
|
|
2141
|
-
isBordered:
|
|
2142
|
-
hasBackground:
|
|
2143
|
-
isEditorPresentationDifferent:
|
|
2184
|
+
import { z as z89 } from "zod";
|
|
2185
|
+
var PageBlockDefinitionAppearance = z89.object({
|
|
2186
|
+
isBordered: z89.boolean().optional(),
|
|
2187
|
+
hasBackground: z89.boolean().optional(),
|
|
2188
|
+
isEditorPresentationDifferent: z89.boolean().optional()
|
|
2144
2189
|
});
|
|
2145
2190
|
|
|
2146
2191
|
// src/dsm/documentation/block-definitions/definition.ts
|
|
2147
|
-
import { z as
|
|
2192
|
+
import { z as z92 } from "zod";
|
|
2148
2193
|
|
|
2149
2194
|
// src/dsm/documentation/block-definitions/item.ts
|
|
2150
|
-
import { z as
|
|
2195
|
+
import { z as z91 } from "zod";
|
|
2151
2196
|
|
|
2152
2197
|
// src/dsm/documentation/block-definitions/variant.ts
|
|
2153
|
-
import { z as
|
|
2154
|
-
var PageBlockDefinitionLayoutType =
|
|
2155
|
-
var PageBlockDefinitionLayoutGap =
|
|
2156
|
-
var PageBlockDefinitionLayoutAlign =
|
|
2157
|
-
var PageBlockDefinitionLayoutResizing =
|
|
2158
|
-
var PageBlockDefinitionLayoutBase =
|
|
2198
|
+
import { z as z90 } from "zod";
|
|
2199
|
+
var PageBlockDefinitionLayoutType = z90.enum(["Column", "Row"]);
|
|
2200
|
+
var PageBlockDefinitionLayoutGap = z90.enum(["Small", "Medium", "Large", "None"]);
|
|
2201
|
+
var PageBlockDefinitionLayoutAlign = z90.enum(["Start", "Center", "End"]);
|
|
2202
|
+
var PageBlockDefinitionLayoutResizing = z90.enum(["Fill", "Hug"]);
|
|
2203
|
+
var PageBlockDefinitionLayoutBase = z90.object({
|
|
2159
2204
|
type: PageBlockDefinitionLayoutType,
|
|
2160
2205
|
gap: PageBlockDefinitionLayoutGap.optional(),
|
|
2161
2206
|
columnAlign: PageBlockDefinitionLayoutAlign.optional(),
|
|
2162
2207
|
columnResizing: PageBlockDefinitionLayoutResizing.optional()
|
|
2163
2208
|
});
|
|
2164
2209
|
var PageBlockDefinitionLayout = PageBlockDefinitionLayoutBase.extend({
|
|
2165
|
-
children:
|
|
2166
|
-
});
|
|
2167
|
-
var PageBlockDefinitionVariant =
|
|
2168
|
-
id:
|
|
2169
|
-
name:
|
|
2170
|
-
image:
|
|
2171
|
-
description:
|
|
2172
|
-
documentationLink:
|
|
2210
|
+
children: z90.lazy(() => z90.array(PageBlockDefinitionLayout.or(z90.string())))
|
|
2211
|
+
});
|
|
2212
|
+
var PageBlockDefinitionVariant = z90.object({
|
|
2213
|
+
id: z90.string(),
|
|
2214
|
+
name: z90.string(),
|
|
2215
|
+
image: z90.string().optional(),
|
|
2216
|
+
description: z90.string().optional(),
|
|
2217
|
+
documentationLink: z90.string().optional(),
|
|
2173
2218
|
layout: PageBlockDefinitionLayout,
|
|
2174
|
-
maxColumns:
|
|
2175
|
-
defaultColumns:
|
|
2219
|
+
maxColumns: z90.number().optional(),
|
|
2220
|
+
defaultColumns: z90.number().optional(),
|
|
2176
2221
|
appearance: PageBlockDefinitionAppearance.optional()
|
|
2177
2222
|
});
|
|
2178
2223
|
|
|
2179
2224
|
// src/dsm/documentation/block-definitions/item.ts
|
|
2180
|
-
var PageBlockDefinitionPropertyType =
|
|
2225
|
+
var PageBlockDefinitionPropertyType = z91.enum([
|
|
2181
2226
|
"RichText",
|
|
2182
2227
|
"MultiRichText",
|
|
2183
2228
|
"Text",
|
|
@@ -2204,7 +2249,7 @@ var PageBlockDefinitionPropertyType = z90.enum([
|
|
|
2204
2249
|
"Storybook",
|
|
2205
2250
|
"Color"
|
|
2206
2251
|
]);
|
|
2207
|
-
var PageBlockDefinitionRichTextPropertyStyle =
|
|
2252
|
+
var PageBlockDefinitionRichTextPropertyStyle = z91.enum([
|
|
2208
2253
|
"Title1",
|
|
2209
2254
|
"Title2",
|
|
2210
2255
|
"Title3",
|
|
@@ -2214,8 +2259,8 @@ var PageBlockDefinitionRichTextPropertyStyle = z90.enum([
|
|
|
2214
2259
|
"Callout",
|
|
2215
2260
|
"Default"
|
|
2216
2261
|
]);
|
|
2217
|
-
var PageBlockDefinitionMultiRichTextPropertyStyle =
|
|
2218
|
-
var PageBlockDefinitionTextPropertyStyle =
|
|
2262
|
+
var PageBlockDefinitionMultiRichTextPropertyStyle = z91.enum(["OL", "UL", "Default"]);
|
|
2263
|
+
var PageBlockDefinitionTextPropertyStyle = z91.enum([
|
|
2219
2264
|
"Title1",
|
|
2220
2265
|
"Title2",
|
|
2221
2266
|
"Title3",
|
|
@@ -2228,79 +2273,79 @@ var PageBlockDefinitionTextPropertyStyle = z90.enum([
|
|
|
2228
2273
|
"SmallBold",
|
|
2229
2274
|
"SmallSemibold"
|
|
2230
2275
|
]);
|
|
2231
|
-
var PageBlockDefinitionTextPropertyColor =
|
|
2232
|
-
var PageBlockDefinitionBooleanPropertyStyle =
|
|
2233
|
-
var PageBlockDefinitionSingleSelectPropertyStyle =
|
|
2276
|
+
var PageBlockDefinitionTextPropertyColor = z91.enum(["Neutral", "NeutralFaded"]);
|
|
2277
|
+
var PageBlockDefinitionBooleanPropertyStyle = z91.enum(["SegmentedControl", "ToggleButton", "Checkbox"]);
|
|
2278
|
+
var PageBlockDefinitionSingleSelectPropertyStyle = z91.enum([
|
|
2234
2279
|
"SegmentedControl",
|
|
2235
2280
|
"ToggleButton",
|
|
2236
2281
|
"Select",
|
|
2237
2282
|
"Checkbox"
|
|
2238
2283
|
]);
|
|
2239
|
-
var PageBlockDefinitionMultiSelectPropertyStyle =
|
|
2240
|
-
var PageBlockDefinitionImageAspectRatio =
|
|
2241
|
-
var PageBlockDefinitionImageWidth =
|
|
2242
|
-
var PageBlockDefinitionSelectChoice =
|
|
2243
|
-
value:
|
|
2244
|
-
name:
|
|
2245
|
-
icon:
|
|
2284
|
+
var PageBlockDefinitionMultiSelectPropertyStyle = z91.enum(["SegmentedControl", "Select", "Checkbox"]);
|
|
2285
|
+
var PageBlockDefinitionImageAspectRatio = z91.enum(["Auto", "Square", "Landscape", "Portrait", "Wide"]);
|
|
2286
|
+
var PageBlockDefinitionImageWidth = z91.enum(["Full", "Icon", "Small", "Medium", "Large", "Poster"]);
|
|
2287
|
+
var PageBlockDefinitionSelectChoice = z91.object({
|
|
2288
|
+
value: z91.string(),
|
|
2289
|
+
name: z91.string(),
|
|
2290
|
+
icon: z91.string().optional()
|
|
2246
2291
|
});
|
|
2247
|
-
var PageBlockDefinitionUntypedPropertyOptions =
|
|
2248
|
-
var PageBlockDefinitionRichTextOptions =
|
|
2292
|
+
var PageBlockDefinitionUntypedPropertyOptions = z91.record(z91.any());
|
|
2293
|
+
var PageBlockDefinitionRichTextOptions = z91.object({
|
|
2249
2294
|
richTextStyle: PageBlockDefinitionRichTextPropertyStyle.optional()
|
|
2250
2295
|
});
|
|
2251
|
-
var PageBlockDefinitionMutiRichTextOptions =
|
|
2296
|
+
var PageBlockDefinitionMutiRichTextOptions = z91.object({
|
|
2252
2297
|
multiRichTextStyle: PageBlockDefinitionMultiRichTextPropertyStyle.optional()
|
|
2253
2298
|
});
|
|
2254
|
-
var PageBlockDefinitionTextOptions =
|
|
2255
|
-
placeholder:
|
|
2256
|
-
defaultValue:
|
|
2299
|
+
var PageBlockDefinitionTextOptions = z91.object({
|
|
2300
|
+
placeholder: z91.string().optional(),
|
|
2301
|
+
defaultValue: z91.string().optional(),
|
|
2257
2302
|
textStyle: PageBlockDefinitionTextPropertyStyle.optional(),
|
|
2258
2303
|
color: PageBlockDefinitionTextPropertyColor.optional()
|
|
2259
2304
|
});
|
|
2260
|
-
var PageBlockDefinitionSelectOptions =
|
|
2305
|
+
var PageBlockDefinitionSelectOptions = z91.object({
|
|
2261
2306
|
singleSelectStyle: PageBlockDefinitionSingleSelectPropertyStyle.optional(),
|
|
2262
|
-
defaultChoice:
|
|
2263
|
-
choices:
|
|
2307
|
+
defaultChoice: z91.string(),
|
|
2308
|
+
choices: z91.array(PageBlockDefinitionSelectChoice)
|
|
2264
2309
|
});
|
|
2265
|
-
var PageBlockDefinitionImageOptions =
|
|
2310
|
+
var PageBlockDefinitionImageOptions = z91.object({
|
|
2266
2311
|
width: PageBlockDefinitionImageWidth.optional(),
|
|
2267
2312
|
aspectRatio: PageBlockDefinitionImageAspectRatio.optional(),
|
|
2268
|
-
allowCaption:
|
|
2269
|
-
recommendation:
|
|
2313
|
+
allowCaption: z91.boolean().optional(),
|
|
2314
|
+
recommendation: z91.string().optional()
|
|
2270
2315
|
});
|
|
2271
|
-
var PageBlockDefinitionBooleanOptions =
|
|
2272
|
-
defaultvalue:
|
|
2316
|
+
var PageBlockDefinitionBooleanOptions = z91.object({
|
|
2317
|
+
defaultvalue: z91.boolean().optional(),
|
|
2273
2318
|
booleanStyle: PageBlockDefinitionBooleanPropertyStyle.optional()
|
|
2274
2319
|
});
|
|
2275
|
-
var PageBlockDefinitionNumberOptions =
|
|
2276
|
-
defaultValue:
|
|
2277
|
-
min:
|
|
2278
|
-
max:
|
|
2279
|
-
step:
|
|
2280
|
-
placeholder:
|
|
2320
|
+
var PageBlockDefinitionNumberOptions = z91.object({
|
|
2321
|
+
defaultValue: z91.number(),
|
|
2322
|
+
min: z91.number().optional(),
|
|
2323
|
+
max: z91.number().optional(),
|
|
2324
|
+
step: z91.number().optional(),
|
|
2325
|
+
placeholder: z91.string().optional()
|
|
2281
2326
|
});
|
|
2282
|
-
var PageBlockDefinitionComponentOptions =
|
|
2283
|
-
renderLayoutAs:
|
|
2284
|
-
allowPropertySelection:
|
|
2327
|
+
var PageBlockDefinitionComponentOptions = z91.object({
|
|
2328
|
+
renderLayoutAs: z91.enum(["List", "Table"]).optional(),
|
|
2329
|
+
allowPropertySelection: z91.boolean().optional()
|
|
2285
2330
|
});
|
|
2286
|
-
var PageBlockDefinitionProperty =
|
|
2287
|
-
id:
|
|
2288
|
-
name:
|
|
2331
|
+
var PageBlockDefinitionProperty = z91.object({
|
|
2332
|
+
id: z91.string(),
|
|
2333
|
+
name: z91.string(),
|
|
2289
2334
|
type: PageBlockDefinitionPropertyType,
|
|
2290
|
-
description:
|
|
2335
|
+
description: z91.string().optional(),
|
|
2291
2336
|
// TODO Docs
|
|
2292
2337
|
options: PageBlockDefinitionUntypedPropertyOptions.optional(),
|
|
2293
|
-
variantOptions:
|
|
2338
|
+
variantOptions: z91.record(PageBlockDefinitionUntypedPropertyOptions).optional()
|
|
2294
2339
|
});
|
|
2295
|
-
var PageBlockDefinitionItem =
|
|
2296
|
-
properties:
|
|
2340
|
+
var PageBlockDefinitionItem = z91.object({
|
|
2341
|
+
properties: z91.array(PageBlockDefinitionProperty),
|
|
2297
2342
|
appearance: PageBlockDefinitionAppearance.optional(),
|
|
2298
|
-
variants:
|
|
2299
|
-
defaultVariantKey:
|
|
2343
|
+
variants: z91.array(PageBlockDefinitionVariant),
|
|
2344
|
+
defaultVariantKey: z91.string()
|
|
2300
2345
|
});
|
|
2301
2346
|
|
|
2302
2347
|
// src/dsm/documentation/block-definitions/definition.ts
|
|
2303
|
-
var PageBlockCategory =
|
|
2348
|
+
var PageBlockCategory = z92.enum([
|
|
2304
2349
|
"Text",
|
|
2305
2350
|
"Layout",
|
|
2306
2351
|
"Media",
|
|
@@ -2314,61 +2359,44 @@ var PageBlockCategory = z91.enum([
|
|
|
2314
2359
|
"Data",
|
|
2315
2360
|
"Other"
|
|
2316
2361
|
]);
|
|
2317
|
-
var PageBlockBehaviorDataType =
|
|
2318
|
-
var PageBlockBehaviorSelectionType =
|
|
2319
|
-
var PageBlockDefinitionBehavior =
|
|
2362
|
+
var PageBlockBehaviorDataType = z92.enum(["Item", "Token", "Asset", "Component", "FigmaNode"]);
|
|
2363
|
+
var PageBlockBehaviorSelectionType = z92.enum(["Entity", "Group", "EntityAndGroup"]);
|
|
2364
|
+
var PageBlockDefinitionBehavior = z92.object({
|
|
2320
2365
|
dataType: PageBlockBehaviorDataType,
|
|
2321
|
-
items:
|
|
2322
|
-
numberOfItems:
|
|
2323
|
-
allowLinks:
|
|
2366
|
+
items: z92.object({
|
|
2367
|
+
numberOfItems: z92.number(),
|
|
2368
|
+
allowLinks: z92.boolean()
|
|
2324
2369
|
}).optional(),
|
|
2325
|
-
entities:
|
|
2370
|
+
entities: z92.object({
|
|
2326
2371
|
selectionType: PageBlockBehaviorSelectionType,
|
|
2327
|
-
maxSelected:
|
|
2372
|
+
maxSelected: z92.number()
|
|
2328
2373
|
}).optional()
|
|
2329
2374
|
});
|
|
2330
|
-
var PageBlockDefinitionOnboarding =
|
|
2331
|
-
helpText:
|
|
2332
|
-
documentationLink:
|
|
2375
|
+
var PageBlockDefinitionOnboarding = z92.object({
|
|
2376
|
+
helpText: z92.string(),
|
|
2377
|
+
documentationLink: z92.string().optional()
|
|
2333
2378
|
});
|
|
2334
|
-
var PageBlockDefinition =
|
|
2335
|
-
id:
|
|
2336
|
-
name:
|
|
2337
|
-
description:
|
|
2379
|
+
var PageBlockDefinition = z92.object({
|
|
2380
|
+
id: z92.string(),
|
|
2381
|
+
name: z92.string(),
|
|
2382
|
+
description: z92.string(),
|
|
2338
2383
|
category: PageBlockCategory,
|
|
2339
2384
|
icon: AssetValue.optional(),
|
|
2340
|
-
documentationLink:
|
|
2341
|
-
searchKeywords:
|
|
2385
|
+
documentationLink: z92.string().optional(),
|
|
2386
|
+
searchKeywords: z92.array(z92.string()).optional(),
|
|
2342
2387
|
item: PageBlockDefinitionItem,
|
|
2343
2388
|
behavior: PageBlockDefinitionBehavior,
|
|
2344
|
-
editorOptions:
|
|
2389
|
+
editorOptions: z92.object({
|
|
2345
2390
|
onboarding: PageBlockDefinitionOnboarding.optional()
|
|
2346
2391
|
}),
|
|
2347
2392
|
appearance: PageBlockDefinitionAppearance.optional()
|
|
2348
2393
|
});
|
|
2349
2394
|
|
|
2350
2395
|
// src/dsm/documentation/group.ts
|
|
2351
|
-
import { z as z92 } from "zod";
|
|
2352
|
-
var DocumentationPageGroup = z92.object({
|
|
2353
|
-
type: z92.literal("ElementGroup"),
|
|
2354
|
-
childType: z92.literal("DocumentationPage"),
|
|
2355
|
-
id: z92.string(),
|
|
2356
|
-
persistentId: z92.string(),
|
|
2357
|
-
shortPersistentId: z92.string(),
|
|
2358
|
-
designSystemVersionId: z92.string(),
|
|
2359
|
-
parentPersistentId: z92.string().nullish(),
|
|
2360
|
-
sortOrder: z92.number(),
|
|
2361
|
-
title: z92.string(),
|
|
2362
|
-
slug: z92.string(),
|
|
2363
|
-
userSlug: z92.string().nullish(),
|
|
2364
|
-
createdAt: z92.coerce.date(),
|
|
2365
|
-
updatedAt: z92.coerce.date()
|
|
2366
|
-
});
|
|
2367
|
-
|
|
2368
|
-
// src/dsm/documentation/page.ts
|
|
2369
2396
|
import { z as z93 } from "zod";
|
|
2370
|
-
var
|
|
2371
|
-
type: z93.literal("
|
|
2397
|
+
var DocumentationPageGroup = z93.object({
|
|
2398
|
+
type: z93.literal("ElementGroup"),
|
|
2399
|
+
childType: z93.literal("DocumentationPage"),
|
|
2372
2400
|
id: z93.string(),
|
|
2373
2401
|
persistentId: z93.string(),
|
|
2374
2402
|
shortPersistentId: z93.string(),
|
|
@@ -2382,126 +2410,138 @@ var DocumentationPage = z93.object({
|
|
|
2382
2410
|
updatedAt: z93.coerce.date()
|
|
2383
2411
|
});
|
|
2384
2412
|
|
|
2413
|
+
// src/dsm/documentation/page.ts
|
|
2414
|
+
import { z as z94 } from "zod";
|
|
2415
|
+
var DocumentationPage = z94.object({
|
|
2416
|
+
type: z94.literal("DocumentationPage"),
|
|
2417
|
+
id: z94.string(),
|
|
2418
|
+
persistentId: z94.string(),
|
|
2419
|
+
shortPersistentId: z94.string(),
|
|
2420
|
+
designSystemVersionId: z94.string(),
|
|
2421
|
+
parentPersistentId: z94.string().nullish(),
|
|
2422
|
+
sortOrder: z94.number(),
|
|
2423
|
+
title: z94.string(),
|
|
2424
|
+
slug: z94.string(),
|
|
2425
|
+
userSlug: z94.string().nullish(),
|
|
2426
|
+
createdAt: z94.coerce.date(),
|
|
2427
|
+
updatedAt: z94.coerce.date()
|
|
2428
|
+
});
|
|
2429
|
+
|
|
2385
2430
|
// src/dsm/design-system.ts
|
|
2386
|
-
import { z as
|
|
2431
|
+
import { z as z104 } from "zod";
|
|
2387
2432
|
|
|
2388
2433
|
// src/workspace/npm-registry-settings.ts
|
|
2389
|
-
import { z as
|
|
2390
|
-
var NpmRegistryAuthType =
|
|
2391
|
-
var
|
|
2392
|
-
var
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2397
|
-
|
|
2398
|
-
|
|
2399
|
-
|
|
2400
|
-
|
|
2401
|
-
|
|
2402
|
-
authType:
|
|
2403
|
-
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
});
|
|
2409
|
-
var
|
|
2410
|
-
registryType: NpmRegistryTypeWithoutAzure,
|
|
2411
|
-
authType: z94.literal(NpmRegistryAuthType.Enum.Custom),
|
|
2412
|
-
authHeaderName: z94.string(),
|
|
2413
|
-
authHeaderValue: z94.string()
|
|
2414
|
-
});
|
|
2415
|
-
var NpmRegistryAuthConfig = z94.discriminatedUnion("authType", [
|
|
2434
|
+
import { z as z95 } from "zod";
|
|
2435
|
+
var NpmRegistryAuthType = z95.enum(["Basic", "Bearer", "None", "Custom"]);
|
|
2436
|
+
var NpmRegistryType = z95.enum(["NPMJS", "GitHub", "AzureDevOps", "Artifactory", "Custom"]);
|
|
2437
|
+
var NpmRegistryBasicAuthConfig = z95.object({
|
|
2438
|
+
authType: z95.literal(NpmRegistryAuthType.Enum.Basic),
|
|
2439
|
+
username: z95.string(),
|
|
2440
|
+
password: z95.string()
|
|
2441
|
+
});
|
|
2442
|
+
var NpmRegistryBearerAuthConfig = z95.object({
|
|
2443
|
+
authType: z95.literal(NpmRegistryAuthType.Enum.Bearer),
|
|
2444
|
+
accessToken: z95.string()
|
|
2445
|
+
});
|
|
2446
|
+
var NpmRegistryNoAuthConfig = z95.object({
|
|
2447
|
+
authType: z95.literal(NpmRegistryAuthType.Enum.None)
|
|
2448
|
+
});
|
|
2449
|
+
var NpmRegistrCustomAuthConfig = z95.object({
|
|
2450
|
+
authType: z95.literal(NpmRegistryAuthType.Enum.Custom),
|
|
2451
|
+
authHeaderName: z95.string(),
|
|
2452
|
+
authHeaderValue: z95.string()
|
|
2453
|
+
});
|
|
2454
|
+
var NpmRegistryAuthConfig = z95.discriminatedUnion("authType", [
|
|
2416
2455
|
NpmRegistryBasicAuthConfig,
|
|
2417
2456
|
NpmRegistryBearerAuthConfig,
|
|
2418
2457
|
NpmRegistryNoAuthConfig,
|
|
2419
2458
|
NpmRegistrCustomAuthConfig
|
|
2420
2459
|
]);
|
|
2421
|
-
var NpmRegistryConfigBase =
|
|
2422
|
-
|
|
2423
|
-
|
|
2424
|
-
|
|
2425
|
-
|
|
2426
|
-
|
|
2460
|
+
var NpmRegistryConfigBase = z95.object({
|
|
2461
|
+
registryType: NpmRegistryType,
|
|
2462
|
+
enabledScopes: z95.array(z95.string()),
|
|
2463
|
+
customRegistryUrl: z95.string().optional(),
|
|
2464
|
+
bypassProxy: z95.boolean().default(false),
|
|
2465
|
+
npmProxyRegistryConfigId: z95.string().optional(),
|
|
2466
|
+
npmProxyVersion: z95.number().optional()
|
|
2427
2467
|
});
|
|
2428
2468
|
var NpmRegistryConfig = NpmRegistryConfigBase.and(NpmRegistryAuthConfig);
|
|
2429
2469
|
|
|
2430
2470
|
// src/workspace/sso-provider.ts
|
|
2431
|
-
import { z as
|
|
2432
|
-
var SsoProvider =
|
|
2433
|
-
providerId:
|
|
2434
|
-
defaultAutoInviteValue:
|
|
2435
|
-
autoInviteDomains:
|
|
2436
|
-
skipDocsSupernovaLogin:
|
|
2437
|
-
areInvitesDisabled:
|
|
2438
|
-
isTestMode:
|
|
2439
|
-
emailDomains:
|
|
2440
|
-
metadataXml:
|
|
2471
|
+
import { z as z96 } from "zod";
|
|
2472
|
+
var SsoProvider = z96.object({
|
|
2473
|
+
providerId: z96.string(),
|
|
2474
|
+
defaultAutoInviteValue: z96.boolean(),
|
|
2475
|
+
autoInviteDomains: z96.record(z96.string(), z96.boolean()),
|
|
2476
|
+
skipDocsSupernovaLogin: z96.boolean(),
|
|
2477
|
+
areInvitesDisabled: z96.boolean(),
|
|
2478
|
+
isTestMode: z96.boolean(),
|
|
2479
|
+
emailDomains: z96.array(z96.string()),
|
|
2480
|
+
metadataXml: z96.string().nullish()
|
|
2441
2481
|
});
|
|
2442
2482
|
|
|
2443
2483
|
// src/workspace/user-invite.ts
|
|
2444
|
-
import { z as
|
|
2484
|
+
import { z as z98 } from "zod";
|
|
2445
2485
|
|
|
2446
2486
|
// src/workspace/workspace-role.ts
|
|
2447
|
-
import { z as
|
|
2448
|
-
var WorkspaceRoleSchema =
|
|
2487
|
+
import { z as z97 } from "zod";
|
|
2488
|
+
var WorkspaceRoleSchema = z97.enum(["Owner", "Admin", "Creator", "Viewer", "Billing", "Guest"]);
|
|
2449
2489
|
var WorkspaceRole = WorkspaceRoleSchema.enum;
|
|
2450
2490
|
|
|
2451
2491
|
// src/workspace/user-invite.ts
|
|
2452
2492
|
var MAX_MEMBERS_COUNT = 100;
|
|
2453
|
-
var UserInvite =
|
|
2454
|
-
email:
|
|
2493
|
+
var UserInvite = z98.object({
|
|
2494
|
+
email: z98.string().email().trim().transform((value) => value.toLowerCase()),
|
|
2455
2495
|
role: WorkspaceRoleSchema
|
|
2456
2496
|
});
|
|
2457
|
-
var UserInvites =
|
|
2497
|
+
var UserInvites = z98.array(UserInvite).max(MAX_MEMBERS_COUNT);
|
|
2458
2498
|
|
|
2459
2499
|
// src/workspace/workspace-context.ts
|
|
2460
|
-
import { z as
|
|
2500
|
+
import { z as z100 } from "zod";
|
|
2461
2501
|
|
|
2462
2502
|
// src/workspace/workspace.ts
|
|
2463
|
-
import { z as
|
|
2464
|
-
var WorkspaceIpWhitelistEntry =
|
|
2465
|
-
isEnabled:
|
|
2466
|
-
name:
|
|
2467
|
-
range:
|
|
2468
|
-
});
|
|
2469
|
-
var WorkspaceIpSettings =
|
|
2470
|
-
isEnabledForCloud:
|
|
2471
|
-
isEnabledForDocs:
|
|
2472
|
-
entries:
|
|
2503
|
+
import { z as z99 } from "zod";
|
|
2504
|
+
var WorkspaceIpWhitelistEntry = z99.object({
|
|
2505
|
+
isEnabled: z99.boolean(),
|
|
2506
|
+
name: z99.string(),
|
|
2507
|
+
range: z99.string()
|
|
2508
|
+
});
|
|
2509
|
+
var WorkspaceIpSettings = z99.object({
|
|
2510
|
+
isEnabledForCloud: z99.boolean(),
|
|
2511
|
+
isEnabledForDocs: z99.boolean(),
|
|
2512
|
+
entries: z99.array(WorkspaceIpWhitelistEntry)
|
|
2473
2513
|
}).nullish();
|
|
2474
|
-
var WorkspaceProfile =
|
|
2475
|
-
name:
|
|
2476
|
-
handle:
|
|
2477
|
-
color:
|
|
2478
|
-
avatar: nullishToOptional(
|
|
2514
|
+
var WorkspaceProfile = z99.object({
|
|
2515
|
+
name: z99.string(),
|
|
2516
|
+
handle: z99.string(),
|
|
2517
|
+
color: z99.string(),
|
|
2518
|
+
avatar: nullishToOptional(z99.string()),
|
|
2479
2519
|
billingDetails: nullishToOptional(BillingDetails)
|
|
2480
2520
|
});
|
|
2481
|
-
var Workspace =
|
|
2482
|
-
id:
|
|
2521
|
+
var Workspace = z99.object({
|
|
2522
|
+
id: z99.string(),
|
|
2483
2523
|
profile: WorkspaceProfile,
|
|
2484
2524
|
subscription: Subscription,
|
|
2485
2525
|
ipWhitelist: WorkspaceIpSettings,
|
|
2486
2526
|
sso: SsoProvider.nullish(),
|
|
2487
|
-
npmRegistrySettings:
|
|
2488
|
-
designSystems:
|
|
2527
|
+
npmRegistrySettings: z99.unknown().optional(),
|
|
2528
|
+
designSystems: z99.array(DesignSystem).nullish()
|
|
2489
2529
|
});
|
|
2490
|
-
var WorkspaceWithDesignSystems =
|
|
2530
|
+
var WorkspaceWithDesignSystems = z99.object({
|
|
2491
2531
|
workspace: Workspace,
|
|
2492
|
-
designSystems:
|
|
2532
|
+
designSystems: z99.array(DesignSystem)
|
|
2493
2533
|
});
|
|
2494
2534
|
|
|
2495
2535
|
// src/workspace/workspace-context.ts
|
|
2496
|
-
var WorkspaceContext =
|
|
2497
|
-
workspaceId:
|
|
2536
|
+
var WorkspaceContext = z100.object({
|
|
2537
|
+
workspaceId: z100.string(),
|
|
2498
2538
|
product: ProductCodeSchema,
|
|
2499
2539
|
ipWhitelist: WorkspaceIpSettings,
|
|
2500
|
-
publicDesignSystem:
|
|
2540
|
+
publicDesignSystem: z100.boolean().optional()
|
|
2501
2541
|
});
|
|
2502
2542
|
|
|
2503
2543
|
// src/workspace/workspace-create.ts
|
|
2504
|
-
import { z as
|
|
2544
|
+
import { z as z101 } from "zod";
|
|
2505
2545
|
|
|
2506
2546
|
// src/utils/validation.ts
|
|
2507
2547
|
var slugRegex = /^[a-z0-9][a-z0-9-]*[a-z0-9]$/;
|
|
@@ -2511,116 +2551,116 @@ var WORKSPACE_NAME_MIN_LENGTH = 2;
|
|
|
2511
2551
|
var WORKSPACE_NAME_MAX_LENGTH = 64;
|
|
2512
2552
|
var HANDLE_MIN_LENGTH = 2;
|
|
2513
2553
|
var HANDLE_MAX_LENGTH = 64;
|
|
2514
|
-
var CreateWorkspaceInput =
|
|
2515
|
-
name:
|
|
2554
|
+
var CreateWorkspaceInput = z101.object({
|
|
2555
|
+
name: z101.string().min(WORKSPACE_NAME_MIN_LENGTH).max(WORKSPACE_NAME_MAX_LENGTH).trim(),
|
|
2516
2556
|
product: ProductCodeSchema,
|
|
2517
|
-
priceId:
|
|
2518
|
-
billingEmail:
|
|
2519
|
-
handle:
|
|
2557
|
+
priceId: z101.string(),
|
|
2558
|
+
billingEmail: z101.string().email().optional(),
|
|
2559
|
+
handle: z101.string().regex(slugRegex).min(HANDLE_MIN_LENGTH).max(HANDLE_MAX_LENGTH).refine((value) => value?.length > 0).optional(),
|
|
2520
2560
|
invites: UserInvites.optional(),
|
|
2521
|
-
promoCode:
|
|
2561
|
+
promoCode: z101.string().optional(),
|
|
2522
2562
|
status: InternalStatusSchema.optional(),
|
|
2523
2563
|
planInterval: BillingIntervalSchema.optional(),
|
|
2524
|
-
seats:
|
|
2525
|
-
seatLimit:
|
|
2564
|
+
seats: z101.number().optional(),
|
|
2565
|
+
seatLimit: z101.number().optional(),
|
|
2526
2566
|
card: CardSchema.optional()
|
|
2527
2567
|
});
|
|
2528
2568
|
|
|
2529
2569
|
// src/workspace/workspace-invitations.ts
|
|
2530
|
-
import { z as z101 } from "zod";
|
|
2531
|
-
var WorkspaceInvitation = z101.object({
|
|
2532
|
-
id: z101.string(),
|
|
2533
|
-
email: z101.string().email(),
|
|
2534
|
-
createdAt: z101.coerce.date(),
|
|
2535
|
-
resentAt: z101.coerce.date().nullish(),
|
|
2536
|
-
role: z101.nativeEnum(WorkspaceRole),
|
|
2537
|
-
workspaceId: z101.string(),
|
|
2538
|
-
invitedBy: z101.string()
|
|
2539
|
-
});
|
|
2540
|
-
|
|
2541
|
-
// src/workspace/workspace-membership.ts
|
|
2542
2570
|
import { z as z102 } from "zod";
|
|
2543
|
-
var
|
|
2571
|
+
var WorkspaceInvitation = z102.object({
|
|
2544
2572
|
id: z102.string(),
|
|
2545
|
-
|
|
2573
|
+
email: z102.string().email(),
|
|
2574
|
+
createdAt: z102.coerce.date(),
|
|
2575
|
+
resentAt: z102.coerce.date().nullish(),
|
|
2576
|
+
role: z102.nativeEnum(WorkspaceRole),
|
|
2546
2577
|
workspaceId: z102.string(),
|
|
2547
|
-
|
|
2578
|
+
invitedBy: z102.string()
|
|
2579
|
+
});
|
|
2580
|
+
|
|
2581
|
+
// src/workspace/workspace-membership.ts
|
|
2582
|
+
import { z as z103 } from "zod";
|
|
2583
|
+
var WorkspaceMembership = z103.object({
|
|
2584
|
+
id: z103.string(),
|
|
2585
|
+
userId: z103.string(),
|
|
2586
|
+
workspaceId: z103.string(),
|
|
2587
|
+
workspaceRole: z103.nativeEnum(WorkspaceRole)
|
|
2548
2588
|
});
|
|
2549
|
-
var UpdateMembershipRolesInput =
|
|
2550
|
-
members:
|
|
2551
|
-
|
|
2552
|
-
userId:
|
|
2553
|
-
role:
|
|
2589
|
+
var UpdateMembershipRolesInput = z103.object({
|
|
2590
|
+
members: z103.array(
|
|
2591
|
+
z103.object({
|
|
2592
|
+
userId: z103.string(),
|
|
2593
|
+
role: z103.nativeEnum(WorkspaceRole)
|
|
2554
2594
|
})
|
|
2555
2595
|
)
|
|
2556
2596
|
});
|
|
2557
2597
|
|
|
2558
2598
|
// src/dsm/design-system.ts
|
|
2559
|
-
var DesignSystemSwitcher =
|
|
2560
|
-
isEnabled:
|
|
2561
|
-
designSystemIds:
|
|
2599
|
+
var DesignSystemSwitcher = z104.object({
|
|
2600
|
+
isEnabled: z104.boolean(),
|
|
2601
|
+
designSystemIds: z104.array(z104.string())
|
|
2562
2602
|
});
|
|
2563
|
-
var DesignSystem =
|
|
2564
|
-
id:
|
|
2565
|
-
workspaceId:
|
|
2566
|
-
name:
|
|
2567
|
-
description:
|
|
2568
|
-
docExporterId: nullishToOptional(
|
|
2569
|
-
docSlug:
|
|
2570
|
-
docUserSlug: nullishToOptional(
|
|
2571
|
-
docSlugDeprecated:
|
|
2572
|
-
isPublic:
|
|
2573
|
-
isMultibrand:
|
|
2574
|
-
docViewUrl: nullishToOptional(
|
|
2575
|
-
basePrefixes:
|
|
2603
|
+
var DesignSystem = z104.object({
|
|
2604
|
+
id: z104.string(),
|
|
2605
|
+
workspaceId: z104.string(),
|
|
2606
|
+
name: z104.string(),
|
|
2607
|
+
description: z104.string(),
|
|
2608
|
+
docExporterId: nullishToOptional(z104.string()),
|
|
2609
|
+
docSlug: z104.string(),
|
|
2610
|
+
docUserSlug: nullishToOptional(z104.string()),
|
|
2611
|
+
docSlugDeprecated: z104.string(),
|
|
2612
|
+
isPublic: z104.boolean(),
|
|
2613
|
+
isMultibrand: z104.boolean(),
|
|
2614
|
+
docViewUrl: nullishToOptional(z104.string()),
|
|
2615
|
+
basePrefixes: z104.array(z104.string()),
|
|
2576
2616
|
designSystemSwitcher: nullishToOptional(DesignSystemSwitcher),
|
|
2577
|
-
createdAt:
|
|
2578
|
-
updatedAt:
|
|
2617
|
+
createdAt: z104.coerce.date(),
|
|
2618
|
+
updatedAt: z104.coerce.date()
|
|
2579
2619
|
});
|
|
2580
|
-
var DesignSystemWithWorkspace =
|
|
2620
|
+
var DesignSystemWithWorkspace = z104.object({
|
|
2581
2621
|
designSystem: DesignSystem,
|
|
2582
2622
|
workspace: Workspace
|
|
2583
2623
|
});
|
|
2584
2624
|
|
|
2585
2625
|
// src/dsm/desing-system-create.ts
|
|
2586
|
-
import { z as
|
|
2626
|
+
import { z as z105 } from "zod";
|
|
2587
2627
|
var DS_NAME_MIN_LENGTH = 2;
|
|
2588
2628
|
var DS_NAME_MAX_LENGTH = 64;
|
|
2589
2629
|
var DS_DESC_MIN_LENGTH = 2;
|
|
2590
2630
|
var DS_DESC_MAX_LENGTH = 64;
|
|
2591
|
-
var DesignSystemCreateInputMetadata =
|
|
2592
|
-
name:
|
|
2593
|
-
description:
|
|
2631
|
+
var DesignSystemCreateInputMetadata = z105.object({
|
|
2632
|
+
name: z105.string().min(DS_NAME_MIN_LENGTH).max(DS_NAME_MAX_LENGTH).trim(),
|
|
2633
|
+
description: z105.string().min(DS_DESC_MIN_LENGTH).max(DS_DESC_MAX_LENGTH).trim()
|
|
2594
2634
|
});
|
|
2595
|
-
var DesignSystemCreateInput =
|
|
2635
|
+
var DesignSystemCreateInput = z105.object({
|
|
2596
2636
|
meta: DesignSystemCreateInputMetadata,
|
|
2597
|
-
workspaceId:
|
|
2598
|
-
isPublic:
|
|
2599
|
-
basePrefixes:
|
|
2600
|
-
docUserSlug:
|
|
2601
|
-
source:
|
|
2637
|
+
workspaceId: z105.string(),
|
|
2638
|
+
isPublic: z105.boolean().optional(),
|
|
2639
|
+
basePrefixes: z105.array(z105.string()).optional(),
|
|
2640
|
+
docUserSlug: z105.string().nullish().optional(),
|
|
2641
|
+
source: z105.array(z105.string()).optional()
|
|
2602
2642
|
});
|
|
2603
2643
|
|
|
2604
2644
|
// src/dsm/desing-system-update.ts
|
|
2605
|
-
import { z as
|
|
2645
|
+
import { z as z106 } from "zod";
|
|
2606
2646
|
var DS_NAME_MIN_LENGTH2 = 2;
|
|
2607
2647
|
var DS_NAME_MAX_LENGTH2 = 64;
|
|
2608
2648
|
var DS_DESC_MIN_LENGTH2 = 2;
|
|
2609
2649
|
var DS_DESC_MAX_LENGTH2 = 64;
|
|
2610
|
-
var DesignSystemUpdateInputMetadata =
|
|
2611
|
-
name:
|
|
2612
|
-
description:
|
|
2650
|
+
var DesignSystemUpdateInputMetadata = z106.object({
|
|
2651
|
+
name: z106.string().min(DS_NAME_MIN_LENGTH2).max(DS_NAME_MAX_LENGTH2).trim().optional(),
|
|
2652
|
+
description: z106.string().min(DS_DESC_MIN_LENGTH2).max(DS_DESC_MAX_LENGTH2).trim().optional()
|
|
2613
2653
|
});
|
|
2614
|
-
var DesignSystemUpdateInput =
|
|
2654
|
+
var DesignSystemUpdateInput = z106.object({
|
|
2615
2655
|
meta: DesignSystemUpdateInputMetadata.optional(),
|
|
2616
|
-
workspaceId:
|
|
2617
|
-
isPublic:
|
|
2618
|
-
basePrefixes:
|
|
2619
|
-
docUserSlug:
|
|
2620
|
-
source:
|
|
2621
|
-
name:
|
|
2622
|
-
description:
|
|
2623
|
-
docExporterId:
|
|
2656
|
+
workspaceId: z106.string().optional(),
|
|
2657
|
+
isPublic: z106.boolean().optional(),
|
|
2658
|
+
basePrefixes: z106.array(z106.string()).optional(),
|
|
2659
|
+
docUserSlug: z106.string().nullish().optional(),
|
|
2660
|
+
source: z106.array(z106.string()).optional(),
|
|
2661
|
+
name: z106.string().min(DS_NAME_MIN_LENGTH2).max(DS_NAME_MAX_LENGTH2).trim().optional(),
|
|
2662
|
+
description: z106.string().min(DS_DESC_MIN_LENGTH2).max(DS_DESC_MAX_LENGTH2).trim().optional(),
|
|
2663
|
+
docExporterId: z106.string().optional()
|
|
2624
2664
|
});
|
|
2625
2665
|
|
|
2626
2666
|
// src/dsm/published-doc-page.ts
|
|
@@ -2632,54 +2672,54 @@ function tryParseShortPersistentId(url = "/") {
|
|
|
2632
2672
|
}
|
|
2633
2673
|
|
|
2634
2674
|
// src/dsm/published-doc.ts
|
|
2635
|
-
import { z as
|
|
2675
|
+
import { z as z107 } from "zod";
|
|
2636
2676
|
var publishedDocEnvironments = ["Live", "Preview"];
|
|
2637
|
-
var PublishedDocEnvironment =
|
|
2638
|
-
var PublishedDocsChecksums =
|
|
2639
|
-
var PublishedDocRoutingVersion =
|
|
2640
|
-
var PublishedDoc =
|
|
2641
|
-
id:
|
|
2642
|
-
designSystemVersionId:
|
|
2643
|
-
createdAt:
|
|
2644
|
-
updatedAt:
|
|
2645
|
-
lastPublishedAt:
|
|
2646
|
-
isDefault:
|
|
2647
|
-
isPublic:
|
|
2677
|
+
var PublishedDocEnvironment = z107.enum(publishedDocEnvironments);
|
|
2678
|
+
var PublishedDocsChecksums = z107.record(z107.string());
|
|
2679
|
+
var PublishedDocRoutingVersion = z107.enum(["1", "2"]);
|
|
2680
|
+
var PublishedDoc = z107.object({
|
|
2681
|
+
id: z107.string(),
|
|
2682
|
+
designSystemVersionId: z107.string(),
|
|
2683
|
+
createdAt: z107.coerce.date(),
|
|
2684
|
+
updatedAt: z107.coerce.date(),
|
|
2685
|
+
lastPublishedAt: z107.coerce.date(),
|
|
2686
|
+
isDefault: z107.boolean(),
|
|
2687
|
+
isPublic: z107.boolean(),
|
|
2648
2688
|
environment: PublishedDocEnvironment,
|
|
2649
2689
|
checksums: PublishedDocsChecksums,
|
|
2650
|
-
storagePath:
|
|
2651
|
-
wasMigrated:
|
|
2690
|
+
storagePath: z107.string(),
|
|
2691
|
+
wasMigrated: z107.boolean(),
|
|
2652
2692
|
routingVersion: PublishedDocRoutingVersion,
|
|
2653
|
-
usesLocalizations:
|
|
2654
|
-
wasPublishedWithLocalizations:
|
|
2693
|
+
usesLocalizations: z107.boolean(),
|
|
2694
|
+
wasPublishedWithLocalizations: z107.boolean()
|
|
2655
2695
|
});
|
|
2656
2696
|
|
|
2657
2697
|
// src/codegen/export-jobs.ts
|
|
2658
|
-
import { z as
|
|
2659
|
-
var ExporterJobDestination =
|
|
2660
|
-
var ExporterJobStatus =
|
|
2661
|
-
var ExporterJobLogEntryType =
|
|
2662
|
-
var ExporterJobLogEntry =
|
|
2663
|
-
id:
|
|
2664
|
-
time:
|
|
2698
|
+
import { z as z108 } from "zod";
|
|
2699
|
+
var ExporterJobDestination = z108.enum(["s3", "webhookUrl", "github", "documentation", "azure", "gitlab"]);
|
|
2700
|
+
var ExporterJobStatus = z108.enum(["InProgress", "Success", "Failed", "Timeout"]);
|
|
2701
|
+
var ExporterJobLogEntryType = z108.enum(["success", "info", "warning", "error", "user"]);
|
|
2702
|
+
var ExporterJobLogEntry = z108.object({
|
|
2703
|
+
id: z108.string().optional(),
|
|
2704
|
+
time: z108.coerce.date(),
|
|
2665
2705
|
type: ExporterJobLogEntryType,
|
|
2666
|
-
message:
|
|
2706
|
+
message: z108.string()
|
|
2667
2707
|
});
|
|
2668
|
-
var ExporterJobResultPullRequestDestination =
|
|
2669
|
-
pullRequestUrl:
|
|
2708
|
+
var ExporterJobResultPullRequestDestination = z108.object({
|
|
2709
|
+
pullRequestUrl: z108.string()
|
|
2670
2710
|
});
|
|
2671
|
-
var ExporterJobResultS3Destination =
|
|
2672
|
-
bucket:
|
|
2673
|
-
urlPrefix:
|
|
2674
|
-
path:
|
|
2675
|
-
files:
|
|
2711
|
+
var ExporterJobResultS3Destination = z108.object({
|
|
2712
|
+
bucket: z108.string(),
|
|
2713
|
+
urlPrefix: z108.string().optional(),
|
|
2714
|
+
path: z108.string(),
|
|
2715
|
+
files: z108.array(z108.string())
|
|
2676
2716
|
});
|
|
2677
|
-
var ExporterJobResultDocsDestination =
|
|
2678
|
-
url:
|
|
2717
|
+
var ExporterJobResultDocsDestination = z108.object({
|
|
2718
|
+
url: z108.string()
|
|
2679
2719
|
});
|
|
2680
|
-
var ExporterJobResult =
|
|
2681
|
-
error:
|
|
2682
|
-
logs:
|
|
2720
|
+
var ExporterJobResult = z108.object({
|
|
2721
|
+
error: z108.string().optional(),
|
|
2722
|
+
logs: z108.array(ExporterJobLogEntry).optional(),
|
|
2683
2723
|
s3: ExporterJobResultS3Destination.optional(),
|
|
2684
2724
|
github: ExporterJobResultPullRequestDestination.optional(),
|
|
2685
2725
|
azure: ExporterJobResultPullRequestDestination.optional(),
|
|
@@ -2687,68 +2727,68 @@ var ExporterJobResult = z107.object({
|
|
|
2687
2727
|
bitbucket: ExporterJobResultPullRequestDestination.optional(),
|
|
2688
2728
|
sndocs: ExporterJobResultDocsDestination.optional()
|
|
2689
2729
|
});
|
|
2690
|
-
var ExporterDestinationSnDocs =
|
|
2730
|
+
var ExporterDestinationSnDocs = z108.object({
|
|
2691
2731
|
environment: PublishedDocEnvironment
|
|
2692
2732
|
});
|
|
2693
|
-
var ExporterDestinationS3 =
|
|
2694
|
-
var ExporterDestinationGithub =
|
|
2695
|
-
connectionId:
|
|
2696
|
-
url:
|
|
2697
|
-
branch:
|
|
2698
|
-
relativePath:
|
|
2733
|
+
var ExporterDestinationS3 = z108.object({});
|
|
2734
|
+
var ExporterDestinationGithub = z108.object({
|
|
2735
|
+
connectionId: z108.string(),
|
|
2736
|
+
url: z108.string(),
|
|
2737
|
+
branch: z108.string(),
|
|
2738
|
+
relativePath: z108.string(),
|
|
2699
2739
|
// +
|
|
2700
|
-
userId:
|
|
2701
|
-
});
|
|
2702
|
-
var ExporterDestinationAzure =
|
|
2703
|
-
connectionId:
|
|
2704
|
-
organizationId:
|
|
2705
|
-
projectId:
|
|
2706
|
-
repositoryId:
|
|
2707
|
-
branch:
|
|
2708
|
-
relativePath:
|
|
2740
|
+
userId: z108.coerce.string()
|
|
2741
|
+
});
|
|
2742
|
+
var ExporterDestinationAzure = z108.object({
|
|
2743
|
+
connectionId: z108.string(),
|
|
2744
|
+
organizationId: z108.string(),
|
|
2745
|
+
projectId: z108.string(),
|
|
2746
|
+
repositoryId: z108.string(),
|
|
2747
|
+
branch: z108.string(),
|
|
2748
|
+
relativePath: z108.string(),
|
|
2709
2749
|
// +
|
|
2710
|
-
userId:
|
|
2711
|
-
url:
|
|
2712
|
-
});
|
|
2713
|
-
var ExporterDestinationGitlab =
|
|
2714
|
-
connectionId:
|
|
2715
|
-
projectId:
|
|
2716
|
-
branch:
|
|
2717
|
-
relativePath:
|
|
2750
|
+
userId: z108.coerce.string(),
|
|
2751
|
+
url: z108.string()
|
|
2752
|
+
});
|
|
2753
|
+
var ExporterDestinationGitlab = z108.object({
|
|
2754
|
+
connectionId: z108.string(),
|
|
2755
|
+
projectId: z108.string(),
|
|
2756
|
+
branch: z108.string(),
|
|
2757
|
+
relativePath: z108.string(),
|
|
2718
2758
|
// +
|
|
2719
|
-
userId:
|
|
2720
|
-
url:
|
|
2759
|
+
userId: z108.coerce.string(),
|
|
2760
|
+
url: z108.string()
|
|
2721
2761
|
});
|
|
2722
2762
|
var BITBUCKET_SLUG = /^[-a-zA-Z0-9~]*$/;
|
|
2723
2763
|
var BITBUCKET_MAX_LENGTH = 64;
|
|
2724
|
-
var ExporterDestinationBitbucket =
|
|
2725
|
-
connectionId:
|
|
2726
|
-
workspaceSlug:
|
|
2727
|
-
projectKey:
|
|
2728
|
-
repoSlug:
|
|
2729
|
-
branch:
|
|
2730
|
-
relativePath:
|
|
2764
|
+
var ExporterDestinationBitbucket = z108.object({
|
|
2765
|
+
connectionId: z108.string(),
|
|
2766
|
+
workspaceSlug: z108.string().max(BITBUCKET_MAX_LENGTH).regex(BITBUCKET_SLUG),
|
|
2767
|
+
projectKey: z108.string().max(BITBUCKET_MAX_LENGTH).regex(BITBUCKET_SLUG),
|
|
2768
|
+
repoSlug: z108.string().max(BITBUCKET_MAX_LENGTH).regex(BITBUCKET_SLUG),
|
|
2769
|
+
branch: z108.string(),
|
|
2770
|
+
relativePath: z108.string(),
|
|
2731
2771
|
// +
|
|
2732
|
-
userId:
|
|
2733
|
-
url:
|
|
2734
|
-
});
|
|
2735
|
-
var ExporterJob =
|
|
2736
|
-
id:
|
|
2737
|
-
createdAt:
|
|
2738
|
-
finishedAt:
|
|
2739
|
-
designSystemId:
|
|
2740
|
-
designSystemVersionId:
|
|
2741
|
-
workspaceId:
|
|
2742
|
-
scheduleId:
|
|
2743
|
-
exporterId:
|
|
2744
|
-
brandId:
|
|
2745
|
-
themeId:
|
|
2746
|
-
estimatedExecutionTime:
|
|
2772
|
+
userId: z108.coerce.string(),
|
|
2773
|
+
url: z108.string()
|
|
2774
|
+
});
|
|
2775
|
+
var ExporterJob = z108.object({
|
|
2776
|
+
id: z108.coerce.string(),
|
|
2777
|
+
createdAt: z108.coerce.date(),
|
|
2778
|
+
finishedAt: z108.coerce.date().optional(),
|
|
2779
|
+
designSystemId: z108.coerce.string(),
|
|
2780
|
+
designSystemVersionId: z108.coerce.string(),
|
|
2781
|
+
workspaceId: z108.coerce.string(),
|
|
2782
|
+
scheduleId: z108.coerce.string().nullish(),
|
|
2783
|
+
exporterId: z108.coerce.string(),
|
|
2784
|
+
brandId: z108.coerce.string().optional(),
|
|
2785
|
+
themeId: z108.coerce.string().optional(),
|
|
2786
|
+
estimatedExecutionTime: z108.number().optional(),
|
|
2747
2787
|
status: ExporterJobStatus,
|
|
2748
2788
|
result: ExporterJobResult.optional(),
|
|
2749
|
-
createdByUserId:
|
|
2789
|
+
createdByUserId: z108.string().optional(),
|
|
2750
2790
|
// CodegenDestinationsModel
|
|
2751
|
-
webhookUrl:
|
|
2791
|
+
webhookUrl: z108.string().optional(),
|
|
2752
2792
|
destinationSnDocs: ExporterDestinationSnDocs.optional(),
|
|
2753
2793
|
destinationS3: ExporterDestinationS3.optional(),
|
|
2754
2794
|
destinationGithub: ExporterDestinationGithub.optional(),
|
|
@@ -2767,28 +2807,28 @@ var ExporterJobFindByFilter = ExporterJob.pick({
|
|
|
2767
2807
|
themeId: true,
|
|
2768
2808
|
brandId: true
|
|
2769
2809
|
}).extend({
|
|
2770
|
-
destinations:
|
|
2810
|
+
destinations: z108.array(ExporterJobDestination),
|
|
2771
2811
|
docsEnvironment: PublishedDocEnvironment
|
|
2772
2812
|
}).partial();
|
|
2773
2813
|
|
|
2774
2814
|
// src/codegen/exporter-workspace-membership-role.ts
|
|
2775
|
-
import { z as
|
|
2776
|
-
var ExporterWorkspaceMembershipRole =
|
|
2815
|
+
import { z as z109 } from "zod";
|
|
2816
|
+
var ExporterWorkspaceMembershipRole = z109.enum(["Owner", "OwnerArchived", "User"]);
|
|
2777
2817
|
|
|
2778
2818
|
// src/codegen/exporter-workspace-membership.ts
|
|
2779
|
-
import { z as
|
|
2780
|
-
var ExporterWorkspaceMembership =
|
|
2781
|
-
id:
|
|
2782
|
-
workspaceId:
|
|
2783
|
-
exporterId:
|
|
2819
|
+
import { z as z110 } from "zod";
|
|
2820
|
+
var ExporterWorkspaceMembership = z110.object({
|
|
2821
|
+
id: z110.string(),
|
|
2822
|
+
workspaceId: z110.string(),
|
|
2823
|
+
exporterId: z110.string(),
|
|
2784
2824
|
role: ExporterWorkspaceMembershipRole
|
|
2785
2825
|
});
|
|
2786
2826
|
|
|
2787
2827
|
// src/codegen/exporter.ts
|
|
2788
|
-
import { z as
|
|
2828
|
+
import { z as z113 } from "zod";
|
|
2789
2829
|
|
|
2790
2830
|
// src/codegen/git-providers.ts
|
|
2791
|
-
import { z as
|
|
2831
|
+
import { z as z111 } from "zod";
|
|
2792
2832
|
var GitProviderNames = /* @__PURE__ */ ((GitProviderNames2) => {
|
|
2793
2833
|
GitProviderNames2["Azure"] = "azure";
|
|
2794
2834
|
GitProviderNames2["Github"] = "github";
|
|
@@ -2796,11 +2836,11 @@ var GitProviderNames = /* @__PURE__ */ ((GitProviderNames2) => {
|
|
|
2796
2836
|
GitProviderNames2["Bitbucket"] = "bitbucket";
|
|
2797
2837
|
return GitProviderNames2;
|
|
2798
2838
|
})(GitProviderNames || {});
|
|
2799
|
-
var GitProvider =
|
|
2839
|
+
var GitProvider = z111.nativeEnum(GitProviderNames);
|
|
2800
2840
|
|
|
2801
2841
|
// src/codegen/pulsar.ts
|
|
2802
|
-
import { z as
|
|
2803
|
-
var PulsarPropertyType =
|
|
2842
|
+
import { z as z112 } from "zod";
|
|
2843
|
+
var PulsarPropertyType = z112.enum([
|
|
2804
2844
|
"string",
|
|
2805
2845
|
"number",
|
|
2806
2846
|
"boolean",
|
|
@@ -2813,108 +2853,108 @@ var PulsarPropertyType = z111.enum([
|
|
|
2813
2853
|
"tokenProperties",
|
|
2814
2854
|
"tokenType"
|
|
2815
2855
|
]);
|
|
2816
|
-
var PulsarBaseProperty =
|
|
2817
|
-
label:
|
|
2818
|
-
key:
|
|
2819
|
-
description:
|
|
2856
|
+
var PulsarBaseProperty = z112.object({
|
|
2857
|
+
label: z112.string(),
|
|
2858
|
+
key: z112.string(),
|
|
2859
|
+
description: z112.string().nullish(),
|
|
2820
2860
|
type: PulsarPropertyType,
|
|
2821
|
-
values:
|
|
2822
|
-
default:
|
|
2861
|
+
values: z112.array(z112.string()).nullish(),
|
|
2862
|
+
default: z112.union([z112.string(), z112.boolean(), z112.number()]).nullish(),
|
|
2823
2863
|
// PulsarPropertyValueType //is optional?
|
|
2824
|
-
inputType:
|
|
2864
|
+
inputType: z112.enum(["code", "plain"]).optional(),
|
|
2825
2865
|
//is optional?
|
|
2826
|
-
isMultiline:
|
|
2866
|
+
isMultiline: z112.boolean().nullish()
|
|
2827
2867
|
});
|
|
2828
2868
|
var PulsarContributionConfigurationProperty = PulsarBaseProperty.extend({
|
|
2829
|
-
category:
|
|
2869
|
+
category: z112.string()
|
|
2830
2870
|
});
|
|
2831
|
-
var PulsarContributionVariant =
|
|
2832
|
-
key:
|
|
2833
|
-
name:
|
|
2834
|
-
isDefault:
|
|
2835
|
-
description:
|
|
2836
|
-
thumbnailURL:
|
|
2871
|
+
var PulsarContributionVariant = z112.object({
|
|
2872
|
+
key: z112.string(),
|
|
2873
|
+
name: z112.string(),
|
|
2874
|
+
isDefault: z112.boolean().nullish(),
|
|
2875
|
+
description: z112.string().nullish(),
|
|
2876
|
+
thumbnailURL: z112.string().nullish()
|
|
2837
2877
|
});
|
|
2838
|
-
var PulsarCustomBlock =
|
|
2839
|
-
title:
|
|
2840
|
-
key:
|
|
2841
|
-
category:
|
|
2842
|
-
description: nullishToOptional(
|
|
2843
|
-
iconURL:
|
|
2844
|
-
mode:
|
|
2845
|
-
properties:
|
|
2878
|
+
var PulsarCustomBlock = z112.object({
|
|
2879
|
+
title: z112.string(),
|
|
2880
|
+
key: z112.string(),
|
|
2881
|
+
category: z112.string(),
|
|
2882
|
+
description: nullishToOptional(z112.string()),
|
|
2883
|
+
iconURL: z112.string(),
|
|
2884
|
+
mode: z112.enum(["array", "block"]),
|
|
2885
|
+
properties: z112.array(PulsarBaseProperty)
|
|
2846
2886
|
});
|
|
2847
2887
|
|
|
2848
2888
|
// src/codegen/exporter.ts
|
|
2849
|
-
var ExporterType =
|
|
2850
|
-
var ExporterSource =
|
|
2851
|
-
var ExporterTag =
|
|
2852
|
-
var ExporterDetails =
|
|
2853
|
-
description:
|
|
2854
|
-
version:
|
|
2855
|
-
routingVersion: nullishToOptional(
|
|
2856
|
-
author: nullishToOptional(
|
|
2857
|
-
organization: nullishToOptional(
|
|
2858
|
-
homepage: nullishToOptional(
|
|
2859
|
-
readme: nullishToOptional(
|
|
2860
|
-
tags: nullishToOptional(
|
|
2861
|
-
packageId: nullishToOptional(
|
|
2862
|
-
iconURL: nullishToOptional(
|
|
2863
|
-
configurationProperties: nullishToOptional(
|
|
2864
|
-
customBlocks: nullishToOptional(
|
|
2865
|
-
blockVariants: nullishToOptional(
|
|
2866
|
-
usesBrands: nullishToOptional(
|
|
2867
|
-
usesThemes: nullishToOptional(
|
|
2889
|
+
var ExporterType = z113.enum(["code", "documentation"]);
|
|
2890
|
+
var ExporterSource = z113.enum(["git", "upload"]);
|
|
2891
|
+
var ExporterTag = z113.string().regex(/^[0-9a-zA-Z]+(\s[0-9a-zA-Z]+)*$/);
|
|
2892
|
+
var ExporterDetails = z113.object({
|
|
2893
|
+
description: z113.string(),
|
|
2894
|
+
version: z113.string(),
|
|
2895
|
+
routingVersion: nullishToOptional(z113.string()),
|
|
2896
|
+
author: nullishToOptional(z113.string()),
|
|
2897
|
+
organization: nullishToOptional(z113.string()),
|
|
2898
|
+
homepage: nullishToOptional(z113.string()),
|
|
2899
|
+
readme: nullishToOptional(z113.string()),
|
|
2900
|
+
tags: nullishToOptional(z113.array(ExporterTag)).default([]),
|
|
2901
|
+
packageId: nullishToOptional(z113.string().max(255)),
|
|
2902
|
+
iconURL: nullishToOptional(z113.string()),
|
|
2903
|
+
configurationProperties: nullishToOptional(z113.array(PulsarContributionConfigurationProperty)).default([]),
|
|
2904
|
+
customBlocks: nullishToOptional(z113.array(PulsarCustomBlock)).default([]),
|
|
2905
|
+
blockVariants: nullishToOptional(z113.record(z113.string(), z113.array(PulsarContributionVariant))).default({}),
|
|
2906
|
+
usesBrands: nullishToOptional(z113.boolean()).default(false),
|
|
2907
|
+
usesThemes: nullishToOptional(z113.boolean()).default(false),
|
|
2868
2908
|
source: ExporterSource,
|
|
2869
2909
|
gitProvider: nullishToOptional(GitProvider),
|
|
2870
|
-
gitUrl: nullishToOptional(
|
|
2871
|
-
gitBranch: nullishToOptional(
|
|
2872
|
-
gitDirectory: nullishToOptional(
|
|
2910
|
+
gitUrl: nullishToOptional(z113.string()),
|
|
2911
|
+
gitBranch: nullishToOptional(z113.string()),
|
|
2912
|
+
gitDirectory: nullishToOptional(z113.string())
|
|
2873
2913
|
});
|
|
2874
|
-
var Exporter =
|
|
2875
|
-
id:
|
|
2876
|
-
createdAt:
|
|
2877
|
-
name:
|
|
2878
|
-
isPrivate:
|
|
2914
|
+
var Exporter = z113.object({
|
|
2915
|
+
id: z113.string(),
|
|
2916
|
+
createdAt: z113.coerce.date(),
|
|
2917
|
+
name: z113.string(),
|
|
2918
|
+
isPrivate: z113.boolean(),
|
|
2879
2919
|
details: ExporterDetails,
|
|
2880
2920
|
exporterType: nullishToOptional(ExporterType).default("code"),
|
|
2881
|
-
storagePath: nullishToOptional(
|
|
2921
|
+
storagePath: nullishToOptional(z113.string()).default("")
|
|
2882
2922
|
});
|
|
2883
2923
|
|
|
2884
2924
|
// src/custom-domains/custom-domains.ts
|
|
2885
|
-
import { z as
|
|
2886
|
-
var CustomDomain =
|
|
2887
|
-
id:
|
|
2888
|
-
designSystemId:
|
|
2889
|
-
state:
|
|
2890
|
-
supernovaDomain:
|
|
2891
|
-
customerDomain:
|
|
2892
|
-
error:
|
|
2893
|
-
errorCode:
|
|
2925
|
+
import { z as z114 } from "zod";
|
|
2926
|
+
var CustomDomain = z114.object({
|
|
2927
|
+
id: z114.string(),
|
|
2928
|
+
designSystemId: z114.string(),
|
|
2929
|
+
state: z114.string(),
|
|
2930
|
+
supernovaDomain: z114.string(),
|
|
2931
|
+
customerDomain: z114.string().nullish(),
|
|
2932
|
+
error: z114.string().nullish(),
|
|
2933
|
+
errorCode: z114.string().nullish()
|
|
2894
2934
|
});
|
|
2895
2935
|
|
|
2896
2936
|
// src/docs-server/session.ts
|
|
2897
|
-
import { z as
|
|
2937
|
+
import { z as z119 } from "zod";
|
|
2898
2938
|
|
|
2899
2939
|
// src/users/linked-integrations.ts
|
|
2900
|
-
import { z as
|
|
2901
|
-
var IntegrationAuthType =
|
|
2902
|
-
var ExternalServiceType =
|
|
2903
|
-
|
|
2904
|
-
|
|
2905
|
-
|
|
2906
|
-
|
|
2907
|
-
|
|
2940
|
+
import { z as z115 } from "zod";
|
|
2941
|
+
var IntegrationAuthType = z115.union([z115.literal("OAuth2"), z115.literal("PAT")]);
|
|
2942
|
+
var ExternalServiceType = z115.union([
|
|
2943
|
+
z115.literal("figma"),
|
|
2944
|
+
z115.literal("github"),
|
|
2945
|
+
z115.literal("azure"),
|
|
2946
|
+
z115.literal("gitlab"),
|
|
2947
|
+
z115.literal("bitbucket")
|
|
2908
2948
|
]);
|
|
2909
|
-
var IntegrationUserInfo =
|
|
2910
|
-
id:
|
|
2911
|
-
handle:
|
|
2912
|
-
avatarUrl:
|
|
2913
|
-
email:
|
|
2949
|
+
var IntegrationUserInfo = z115.object({
|
|
2950
|
+
id: z115.string(),
|
|
2951
|
+
handle: z115.string().optional(),
|
|
2952
|
+
avatarUrl: z115.string().optional(),
|
|
2953
|
+
email: z115.string().optional(),
|
|
2914
2954
|
authType: IntegrationAuthType.optional(),
|
|
2915
|
-
customUrl:
|
|
2955
|
+
customUrl: z115.string().optional()
|
|
2916
2956
|
});
|
|
2917
|
-
var UserLinkedIntegrations =
|
|
2957
|
+
var UserLinkedIntegrations = z115.object({
|
|
2918
2958
|
figma: IntegrationUserInfo.optional(),
|
|
2919
2959
|
github: IntegrationUserInfo.array().optional(),
|
|
2920
2960
|
azure: IntegrationUserInfo.array().optional(),
|
|
@@ -2923,86 +2963,86 @@ var UserLinkedIntegrations = z114.object({
|
|
|
2923
2963
|
});
|
|
2924
2964
|
|
|
2925
2965
|
// src/users/user-identity.ts
|
|
2926
|
-
import { z as
|
|
2927
|
-
var UserIdentity =
|
|
2928
|
-
id:
|
|
2929
|
-
userId:
|
|
2966
|
+
import { z as z116 } from "zod";
|
|
2967
|
+
var UserIdentity = z116.object({
|
|
2968
|
+
id: z116.string(),
|
|
2969
|
+
userId: z116.string()
|
|
2930
2970
|
});
|
|
2931
2971
|
|
|
2932
2972
|
// src/users/user-profile.ts
|
|
2933
|
-
import { z as
|
|
2934
|
-
var UserOnboardingDepartment =
|
|
2935
|
-
var UserOnboardingJobLevel =
|
|
2936
|
-
var UserOnboarding =
|
|
2937
|
-
companyName:
|
|
2938
|
-
numberOfPeopleInOrg:
|
|
2939
|
-
numberOfPeopleInDesignTeam:
|
|
2973
|
+
import { z as z117 } from "zod";
|
|
2974
|
+
var UserOnboardingDepartment = z117.enum(["Design", "Engineering", "Brand", "Other"]);
|
|
2975
|
+
var UserOnboardingJobLevel = z117.enum(["Executive", "Manager", "IndividualContributor", "Other"]);
|
|
2976
|
+
var UserOnboarding = z117.object({
|
|
2977
|
+
companyName: z117.string().optional(),
|
|
2978
|
+
numberOfPeopleInOrg: z117.string().optional(),
|
|
2979
|
+
numberOfPeopleInDesignTeam: z117.string().optional(),
|
|
2940
2980
|
department: UserOnboardingDepartment.optional(),
|
|
2941
|
-
jobTitle:
|
|
2942
|
-
phase:
|
|
2981
|
+
jobTitle: z117.string().optional(),
|
|
2982
|
+
phase: z117.string().optional(),
|
|
2943
2983
|
jobLevel: UserOnboardingJobLevel.optional()
|
|
2944
2984
|
});
|
|
2945
|
-
var UserProfile =
|
|
2946
|
-
name:
|
|
2947
|
-
avatar:
|
|
2948
|
-
nickname:
|
|
2985
|
+
var UserProfile = z117.object({
|
|
2986
|
+
name: z117.string(),
|
|
2987
|
+
avatar: z117.string().optional(),
|
|
2988
|
+
nickname: z117.string().optional(),
|
|
2949
2989
|
onboarding: UserOnboarding.optional()
|
|
2950
2990
|
});
|
|
2951
2991
|
|
|
2952
2992
|
// src/users/user.ts
|
|
2953
|
-
import { z as
|
|
2954
|
-
var User =
|
|
2955
|
-
id:
|
|
2956
|
-
email:
|
|
2957
|
-
emailVerified:
|
|
2958
|
-
createdAt:
|
|
2959
|
-
trialExpiresAt:
|
|
2993
|
+
import { z as z118 } from "zod";
|
|
2994
|
+
var User = z118.object({
|
|
2995
|
+
id: z118.string(),
|
|
2996
|
+
email: z118.string(),
|
|
2997
|
+
emailVerified: z118.boolean(),
|
|
2998
|
+
createdAt: z118.coerce.date(),
|
|
2999
|
+
trialExpiresAt: z118.coerce.date().optional(),
|
|
2960
3000
|
profile: UserProfile,
|
|
2961
3001
|
linkedIntegrations: UserLinkedIntegrations.optional(),
|
|
2962
|
-
loggedOutAt:
|
|
2963
|
-
isProtected:
|
|
3002
|
+
loggedOutAt: z118.coerce.date().optional(),
|
|
3003
|
+
isProtected: z118.boolean()
|
|
2964
3004
|
});
|
|
2965
3005
|
|
|
2966
3006
|
// src/docs-server/session.ts
|
|
2967
|
-
var NpmProxyToken =
|
|
2968
|
-
access:
|
|
2969
|
-
expiresAt:
|
|
3007
|
+
var NpmProxyToken = z119.object({
|
|
3008
|
+
access: z119.string(),
|
|
3009
|
+
expiresAt: z119.number()
|
|
2970
3010
|
});
|
|
2971
|
-
var SessionData =
|
|
2972
|
-
returnToUrl:
|
|
3011
|
+
var SessionData = z119.object({
|
|
3012
|
+
returnToUrl: z119.string().optional(),
|
|
2973
3013
|
npmProxyToken: NpmProxyToken.optional()
|
|
2974
3014
|
});
|
|
2975
|
-
var Session =
|
|
2976
|
-
id:
|
|
2977
|
-
expiresAt:
|
|
2978
|
-
userId:
|
|
3015
|
+
var Session = z119.object({
|
|
3016
|
+
id: z119.string(),
|
|
3017
|
+
expiresAt: z119.coerce.date(),
|
|
3018
|
+
userId: z119.string().nullable(),
|
|
2979
3019
|
data: SessionData
|
|
2980
3020
|
});
|
|
2981
|
-
var AuthTokens =
|
|
2982
|
-
access:
|
|
2983
|
-
refresh:
|
|
3021
|
+
var AuthTokens = z119.object({
|
|
3022
|
+
access: z119.string(),
|
|
3023
|
+
refresh: z119.string()
|
|
2984
3024
|
});
|
|
2985
|
-
var UserSession =
|
|
3025
|
+
var UserSession = z119.object({
|
|
2986
3026
|
session: Session,
|
|
2987
3027
|
user: User.nullable()
|
|
2988
3028
|
});
|
|
2989
3029
|
|
|
2990
3030
|
// src/feature-flags/feature-flags.ts
|
|
2991
|
-
import { z as
|
|
2992
|
-
var FlaggedFeature =
|
|
2993
|
-
var FeatureFlagMap =
|
|
2994
|
-
var FeatureFlag =
|
|
2995
|
-
id:
|
|
3031
|
+
import { z as z120 } from "zod";
|
|
3032
|
+
var FlaggedFeature = z120.enum(["FigmaImporterV2"]);
|
|
3033
|
+
var FeatureFlagMap = z120.record(FlaggedFeature, z120.boolean());
|
|
3034
|
+
var FeatureFlag = z120.object({
|
|
3035
|
+
id: z120.string(),
|
|
2996
3036
|
feature: FlaggedFeature,
|
|
2997
|
-
createdAt:
|
|
2998
|
-
enabled:
|
|
3037
|
+
createdAt: z120.coerce.date(),
|
|
3038
|
+
enabled: z120.boolean()
|
|
2999
3039
|
});
|
|
3000
3040
|
|
|
3001
3041
|
// src/integrations/external-oauth-request.ts
|
|
3002
|
-
import { z as
|
|
3042
|
+
import { z as z122 } from "zod";
|
|
3003
3043
|
|
|
3004
3044
|
// src/integrations/oauth-providers.ts
|
|
3005
|
-
import { z as
|
|
3045
|
+
import { z as z121 } from "zod";
|
|
3006
3046
|
var OAuthProviderNames = /* @__PURE__ */ ((OAuthProviderNames2) => {
|
|
3007
3047
|
OAuthProviderNames2["Figma"] = "figma";
|
|
3008
3048
|
OAuthProviderNames2["Azure"] = "azure";
|
|
@@ -3011,119 +3051,115 @@ var OAuthProviderNames = /* @__PURE__ */ ((OAuthProviderNames2) => {
|
|
|
3011
3051
|
OAuthProviderNames2["Bitbucket"] = "bitbucket";
|
|
3012
3052
|
return OAuthProviderNames2;
|
|
3013
3053
|
})(OAuthProviderNames || {});
|
|
3014
|
-
var OAuthProviderSchema =
|
|
3054
|
+
var OAuthProviderSchema = z121.nativeEnum(OAuthProviderNames);
|
|
3015
3055
|
var OAuthProvider = OAuthProviderSchema.enum;
|
|
3016
3056
|
|
|
3017
3057
|
// src/integrations/external-oauth-request.ts
|
|
3018
|
-
var ExternalOAuthRequest =
|
|
3019
|
-
id:
|
|
3058
|
+
var ExternalOAuthRequest = z122.object({
|
|
3059
|
+
id: z122.string(),
|
|
3020
3060
|
provider: OAuthProviderSchema,
|
|
3021
|
-
userId:
|
|
3022
|
-
state:
|
|
3023
|
-
createdAt:
|
|
3061
|
+
userId: z122.string(),
|
|
3062
|
+
state: z122.string(),
|
|
3063
|
+
createdAt: z122.coerce.date()
|
|
3024
3064
|
});
|
|
3025
3065
|
|
|
3026
3066
|
// src/integrations/oauth-token.ts
|
|
3027
|
-
import { z as
|
|
3028
|
-
var IntegrationTokenSchema =
|
|
3029
|
-
id:
|
|
3067
|
+
import { z as z123 } from "zod";
|
|
3068
|
+
var IntegrationTokenSchema = z123.object({
|
|
3069
|
+
id: z123.string(),
|
|
3030
3070
|
provider: OAuthProviderSchema,
|
|
3031
|
-
scope:
|
|
3032
|
-
userId:
|
|
3033
|
-
accessToken:
|
|
3034
|
-
refreshToken:
|
|
3035
|
-
expiresAt:
|
|
3036
|
-
externalUserId:
|
|
3071
|
+
scope: z123.string(),
|
|
3072
|
+
userId: z123.string(),
|
|
3073
|
+
accessToken: z123.string(),
|
|
3074
|
+
refreshToken: z123.string(),
|
|
3075
|
+
expiresAt: z123.coerce.date(),
|
|
3076
|
+
externalUserId: z123.string().nullish()
|
|
3037
3077
|
});
|
|
3038
3078
|
|
|
3039
3079
|
// src/multiplayer/design-system-version-room.ts
|
|
3040
|
-
import { z as
|
|
3080
|
+
import { z as z124 } from "zod";
|
|
3041
3081
|
var DesignSystemVersionRoom = Entity.extend({
|
|
3042
|
-
designSystemVersionId:
|
|
3043
|
-
liveblocksId:
|
|
3082
|
+
designSystemVersionId: z124.string(),
|
|
3083
|
+
liveblocksId: z124.string()
|
|
3044
3084
|
});
|
|
3045
|
-
var DesignSystemVersionRoomInitialState =
|
|
3046
|
-
pages:
|
|
3047
|
-
groups:
|
|
3085
|
+
var DesignSystemVersionRoomInitialState = z124.object({
|
|
3086
|
+
pages: z124.array(DocumentationPageV2),
|
|
3087
|
+
groups: z124.array(ElementGroup)
|
|
3048
3088
|
});
|
|
3049
3089
|
var DesignSystemVersionRoomUpdate = DesignSystemVersionRoomInitialState.extend({
|
|
3050
|
-
deletedPageIds:
|
|
3051
|
-
deletedGroupIds:
|
|
3090
|
+
deletedPageIds: z124.array(z124.string()),
|
|
3091
|
+
deletedGroupIds: z124.array(z124.string())
|
|
3052
3092
|
});
|
|
3053
3093
|
|
|
3054
3094
|
// src/multiplayer/documentation-page-room.ts
|
|
3055
|
-
import { z as
|
|
3095
|
+
import { z as z125 } from "zod";
|
|
3056
3096
|
var DocumentationPageRoom = Entity.extend({
|
|
3057
|
-
designSystemVersionId:
|
|
3058
|
-
documentationPageId:
|
|
3059
|
-
liveblocksId:
|
|
3060
|
-
});
|
|
3061
|
-
var PageBlockEditorModel = z124.object({
|
|
3062
|
-
id: z124.string(),
|
|
3063
|
-
data: PageBlockDataV2
|
|
3097
|
+
designSystemVersionId: z125.string(),
|
|
3098
|
+
documentationPageId: z125.string(),
|
|
3099
|
+
liveblocksId: z125.string()
|
|
3064
3100
|
});
|
|
3065
|
-
var DocumentationPageRoomRoomUpdate =
|
|
3101
|
+
var DocumentationPageRoomRoomUpdate = z125.object({
|
|
3066
3102
|
page: DocumentationPageV2,
|
|
3067
3103
|
pageParent: ElementGroup
|
|
3068
3104
|
});
|
|
3069
3105
|
var DocumentationPageRoomInitialState = DocumentationPageRoomRoomUpdate.extend({
|
|
3070
|
-
pageBlocks:
|
|
3071
|
-
blockDefinitions:
|
|
3106
|
+
pageBlocks: z125.array(PageBlockEditorModelV2.or(PageSectionEditorModelV2)),
|
|
3107
|
+
blockDefinitions: z125.array(PageBlockDefinition)
|
|
3072
3108
|
});
|
|
3073
3109
|
|
|
3074
3110
|
// src/multiplayer/room-type.ts
|
|
3075
|
-
import { z as
|
|
3111
|
+
import { z as z126 } from "zod";
|
|
3076
3112
|
var RoomTypeEnum = /* @__PURE__ */ ((RoomTypeEnum2) => {
|
|
3077
3113
|
RoomTypeEnum2["DocumentationPage"] = "documentation-page";
|
|
3078
3114
|
RoomTypeEnum2["DesignSystemVersion"] = "design-system-version";
|
|
3079
3115
|
return RoomTypeEnum2;
|
|
3080
3116
|
})(RoomTypeEnum || {});
|
|
3081
|
-
var RoomTypeSchema =
|
|
3117
|
+
var RoomTypeSchema = z126.nativeEnum(RoomTypeEnum);
|
|
3082
3118
|
var RoomType = RoomTypeSchema.enum;
|
|
3083
3119
|
|
|
3084
3120
|
// src/npm/npm-package.ts
|
|
3085
|
-
import { z as
|
|
3086
|
-
var AnyRecord =
|
|
3121
|
+
import { z as z127 } from "zod";
|
|
3122
|
+
var AnyRecord = z127.record(z127.any());
|
|
3087
3123
|
var NpmPackageVersionDist = AnyRecord.and(
|
|
3088
|
-
|
|
3089
|
-
tarball:
|
|
3124
|
+
z127.object({
|
|
3125
|
+
tarball: z127.string()
|
|
3090
3126
|
})
|
|
3091
3127
|
);
|
|
3092
3128
|
var NpmPackageVersion = AnyRecord.and(
|
|
3093
|
-
|
|
3129
|
+
z127.object({
|
|
3094
3130
|
dist: NpmPackageVersionDist
|
|
3095
3131
|
})
|
|
3096
3132
|
);
|
|
3097
3133
|
var NpmPackage = AnyRecord.and(
|
|
3098
|
-
|
|
3099
|
-
_id:
|
|
3100
|
-
name:
|
|
3134
|
+
z127.object({
|
|
3135
|
+
_id: z127.string(),
|
|
3136
|
+
name: z127.string(),
|
|
3101
3137
|
// e.g. "latest": "1.2.3"
|
|
3102
|
-
"dist-tags":
|
|
3138
|
+
"dist-tags": z127.record(z127.string(), z127.string()),
|
|
3103
3139
|
// "1.2.3": {...}
|
|
3104
|
-
versions:
|
|
3140
|
+
versions: z127.record(NpmPackageVersion)
|
|
3105
3141
|
})
|
|
3106
3142
|
);
|
|
3107
3143
|
|
|
3108
3144
|
// src/npm/npm-proxy-token-payload.ts
|
|
3109
|
-
import { z as
|
|
3110
|
-
var NpmProxyTokenPayload =
|
|
3111
|
-
npmProxyRegistryConfigId:
|
|
3145
|
+
import { z as z128 } from "zod";
|
|
3146
|
+
var NpmProxyTokenPayload = z128.object({
|
|
3147
|
+
npmProxyRegistryConfigId: z128.string()
|
|
3112
3148
|
});
|
|
3113
3149
|
|
|
3114
3150
|
// src/tokens/personal-access-token.ts
|
|
3115
|
-
import { z as
|
|
3116
|
-
var PersonalAccessToken =
|
|
3117
|
-
id:
|
|
3118
|
-
userId:
|
|
3119
|
-
name:
|
|
3120
|
-
token:
|
|
3121
|
-
createdAt:
|
|
3122
|
-
hidden:
|
|
3123
|
-
workspaceId:
|
|
3151
|
+
import { z as z129 } from "zod";
|
|
3152
|
+
var PersonalAccessToken = z129.object({
|
|
3153
|
+
id: z129.string(),
|
|
3154
|
+
userId: z129.string(),
|
|
3155
|
+
name: z129.string(),
|
|
3156
|
+
token: z129.string(),
|
|
3157
|
+
createdAt: z129.coerce.date(),
|
|
3158
|
+
hidden: z129.boolean(),
|
|
3159
|
+
workspaceId: z129.string().optional(),
|
|
3124
3160
|
workspaceRole: WorkspaceRoleSchema.optional(),
|
|
3125
|
-
expireAt:
|
|
3126
|
-
scope:
|
|
3161
|
+
expireAt: z129.coerce.date().optional(),
|
|
3162
|
+
scope: z129.string().optional()
|
|
3127
3163
|
});
|
|
3128
3164
|
|
|
3129
3165
|
// src/utils/errors.ts
|
|
@@ -3255,26 +3291,26 @@ async function sleep(ms) {
|
|
|
3255
3291
|
}
|
|
3256
3292
|
|
|
3257
3293
|
// src/utils/content-loader-instruction.ts
|
|
3258
|
-
import { z as
|
|
3259
|
-
var ContentLoadInstruction =
|
|
3260
|
-
from:
|
|
3261
|
-
to:
|
|
3262
|
-
authorizationHeaderKvsId:
|
|
3263
|
-
timeout:
|
|
3264
|
-
});
|
|
3265
|
-
var ContentLoaderPayload =
|
|
3266
|
-
type:
|
|
3294
|
+
import { z as z130 } from "zod";
|
|
3295
|
+
var ContentLoadInstruction = z130.object({
|
|
3296
|
+
from: z130.string(),
|
|
3297
|
+
to: z130.string(),
|
|
3298
|
+
authorizationHeaderKvsId: z130.string().optional(),
|
|
3299
|
+
timeout: z130.number().optional()
|
|
3300
|
+
});
|
|
3301
|
+
var ContentLoaderPayload = z130.object({
|
|
3302
|
+
type: z130.literal("Single"),
|
|
3267
3303
|
instruction: ContentLoadInstruction
|
|
3268
3304
|
}).or(
|
|
3269
|
-
|
|
3270
|
-
type:
|
|
3271
|
-
loadingChunkSize:
|
|
3272
|
-
instructions:
|
|
3305
|
+
z130.object({
|
|
3306
|
+
type: z130.literal("Multiple"),
|
|
3307
|
+
loadingChunkSize: z130.number().optional(),
|
|
3308
|
+
instructions: z130.array(ContentLoadInstruction)
|
|
3273
3309
|
})
|
|
3274
3310
|
).or(
|
|
3275
|
-
|
|
3276
|
-
type:
|
|
3277
|
-
location:
|
|
3311
|
+
z130.object({
|
|
3312
|
+
type: z130.literal("S3"),
|
|
3313
|
+
location: z130.string()
|
|
3278
3314
|
})
|
|
3279
3315
|
);
|
|
3280
3316
|
|
|
@@ -4085,6 +4121,7 @@ export {
|
|
|
4085
4121
|
FigmaFileStructureStatistics,
|
|
4086
4122
|
FigmaImportBaseContext,
|
|
4087
4123
|
FigmaImportContextWithDownloadScopes,
|
|
4124
|
+
FigmaImportContextWithSourcesState,
|
|
4088
4125
|
FigmaNodeReference,
|
|
4089
4126
|
FigmaNodeReferenceData,
|
|
4090
4127
|
FigmaNodeReferenceElementData,
|
|
@@ -4152,7 +4189,6 @@ export {
|
|
|
4152
4189
|
NpmRegistryConfig,
|
|
4153
4190
|
NpmRegistryNoAuthConfig,
|
|
4154
4191
|
NpmRegistryType,
|
|
4155
|
-
NpmRegistryTypeWithoutAzure,
|
|
4156
4192
|
OAuthProvider,
|
|
4157
4193
|
OAuthProviderNames,
|
|
4158
4194
|
OAuthProviderSchema,
|
|
@@ -4207,7 +4243,6 @@ export {
|
|
|
4207
4243
|
PageBlockDefinitionTextPropertyStyle,
|
|
4208
4244
|
PageBlockDefinitionUntypedPropertyOptions,
|
|
4209
4245
|
PageBlockDefinitionVariant,
|
|
4210
|
-
PageBlockEditorModel,
|
|
4211
4246
|
PageBlockEditorModelV2,
|
|
4212
4247
|
PageBlockFigmaFrameProperties,
|
|
4213
4248
|
PageBlockFigmaNodeEntityMeta,
|
|
@@ -4271,6 +4306,12 @@ export {
|
|
|
4271
4306
|
PageBlockUrlPreview,
|
|
4272
4307
|
PageBlockV1,
|
|
4273
4308
|
PageBlockV2,
|
|
4309
|
+
PageSectionAppearanceV2,
|
|
4310
|
+
PageSectionColumnV2,
|
|
4311
|
+
PageSectionEditorModelV2,
|
|
4312
|
+
PageSectionItemV2,
|
|
4313
|
+
PageSectionPaddingV2,
|
|
4314
|
+
PageSectionTypeV2,
|
|
4274
4315
|
ParagraphIndentTokenData,
|
|
4275
4316
|
ParagraphIndentUnit,
|
|
4276
4317
|
ParagraphIndentValue,
|