@supernova-studio/client 0.21.0 → 0.22.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 +521 -27
- package/dist/index.d.ts +521 -27
- package/dist/index.js +80 -13
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +927 -860
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/api/dto/elements/documentation/group.ts +1 -1
- package/src/api/dto/elements/documentation/page-v2.ts +1 -1
- package/src/api/dto/elements/elements-action-v2.ts +7 -8
- package/src/api/dto/elements/figma-nodes/figma-node.ts +46 -0
- package/src/api/dto/elements/figma-nodes/index.ts +2 -0
- package/src/api/dto/elements/figma-nodes/node-actions-v2.ts +24 -0
- package/src/api/dto/elements/index.ts +1 -0
package/dist/index.mjs
CHANGED
|
@@ -16,7 +16,7 @@ import { z as z14 } from "zod";
|
|
|
16
16
|
import { z as z17 } from "zod";
|
|
17
17
|
import { z as z15 } from "zod";
|
|
18
18
|
import { z as z16 } from "zod";
|
|
19
|
-
import { z as
|
|
19
|
+
import { z as z87 } from "zod";
|
|
20
20
|
import { z as z18 } from "zod";
|
|
21
21
|
import { z as z20 } from "zod";
|
|
22
22
|
import { z as z19 } from "zod";
|
|
@@ -74,54 +74,54 @@ import { z as z69 } from "zod";
|
|
|
74
74
|
import { z as z70 } from "zod";
|
|
75
75
|
import { z as z71 } from "zod";
|
|
76
76
|
import { z as z72 } from "zod";
|
|
77
|
-
import { z as z74 } from "zod";
|
|
78
77
|
import { z as z73 } from "zod";
|
|
79
78
|
import { z as z75 } from "zod";
|
|
79
|
+
import { z as z74 } from "zod";
|
|
80
80
|
import { z as z76 } from "zod";
|
|
81
|
-
import { z as z84 } from "zod";
|
|
82
81
|
import { z as z77 } from "zod";
|
|
83
|
-
import { z as
|
|
82
|
+
import { z as z85 } from "zod";
|
|
84
83
|
import { z as z78 } from "zod";
|
|
85
84
|
import { z as z80 } from "zod";
|
|
85
|
+
import { z as z79 } from "zod";
|
|
86
86
|
import { z as z81 } from "zod";
|
|
87
87
|
import { z as z82 } from "zod";
|
|
88
88
|
import { z as z83 } from "zod";
|
|
89
|
-
import { z as
|
|
90
|
-
import { z as
|
|
91
|
-
import { z as z90 } from "zod";
|
|
92
|
-
import { z as z89 } from "zod";
|
|
89
|
+
import { z as z84 } from "zod";
|
|
90
|
+
import { z as z86 } from "zod";
|
|
93
91
|
import { z as z88 } from "zod";
|
|
94
92
|
import { z as z91 } from "zod";
|
|
93
|
+
import { z as z90 } from "zod";
|
|
94
|
+
import { z as z89 } from "zod";
|
|
95
95
|
import { z as z92 } from "zod";
|
|
96
|
-
import { z as z102 } from "zod";
|
|
97
96
|
import { z as z93 } from "zod";
|
|
97
|
+
import { z as z103 } from "zod";
|
|
98
98
|
import { z as z94 } from "zod";
|
|
99
|
-
import { z as z96 } from "zod";
|
|
100
99
|
import { z as z95 } from "zod";
|
|
101
|
-
import { z as z98 } from "zod";
|
|
102
100
|
import { z as z97 } from "zod";
|
|
101
|
+
import { z as z96 } from "zod";
|
|
103
102
|
import { z as z99 } from "zod";
|
|
103
|
+
import { z as z98 } from "zod";
|
|
104
104
|
import { z as z100 } from "zod";
|
|
105
105
|
import { z as z101 } from "zod";
|
|
106
|
-
import { z as
|
|
106
|
+
import { z as z102 } from "zod";
|
|
107
107
|
import { z as z104 } from "zod";
|
|
108
108
|
import { z as z105 } from "zod";
|
|
109
109
|
import { z as z106 } from "zod";
|
|
110
110
|
import { z as z107 } from "zod";
|
|
111
111
|
import { z as z108 } from "zod";
|
|
112
|
-
import { z as z111 } from "zod";
|
|
113
112
|
import { z as z109 } from "zod";
|
|
114
|
-
import { z as z110 } from "zod";
|
|
115
113
|
import { z as z112 } from "zod";
|
|
116
|
-
import { z as
|
|
114
|
+
import { z as z110 } from "zod";
|
|
115
|
+
import { z as z111 } from "zod";
|
|
117
116
|
import { z as z113 } from "zod";
|
|
117
|
+
import { z as z118 } from "zod";
|
|
118
118
|
import { z as z114 } from "zod";
|
|
119
119
|
import { z as z115 } from "zod";
|
|
120
120
|
import { z as z116 } from "zod";
|
|
121
|
-
import { z as
|
|
122
|
-
import { z as z120 } from "zod";
|
|
121
|
+
import { z as z117 } from "zod";
|
|
123
122
|
import { z as z119 } from "zod";
|
|
124
123
|
import { z as z121 } from "zod";
|
|
124
|
+
import { z as z120 } from "zod";
|
|
125
125
|
import { z as z122 } from "zod";
|
|
126
126
|
import { z as z123 } from "zod";
|
|
127
127
|
import { z as z124 } from "zod";
|
|
@@ -129,6 +129,7 @@ import { z as z125 } from "zod";
|
|
|
129
129
|
import { z as z126 } from "zod";
|
|
130
130
|
import { z as z127 } from "zod";
|
|
131
131
|
import { z as z128 } from "zod";
|
|
132
|
+
import { z as z129 } from "zod";
|
|
132
133
|
import slugifyImplementation from "@sindresorhus/slugify";
|
|
133
134
|
var PluginOAuthRequestSchema = z.object({
|
|
134
135
|
id: z.string(),
|
|
@@ -341,7 +342,8 @@ var Asset = z13.object({
|
|
|
341
342
|
filePath: z13.string(),
|
|
342
343
|
scope: AssetScope,
|
|
343
344
|
properties: AssetProperties.nullish(),
|
|
344
|
-
origin: AssetOrigin.
|
|
345
|
+
origin: AssetOrigin.optional(),
|
|
346
|
+
originKey: z13.string().optional()
|
|
345
347
|
});
|
|
346
348
|
var DataSourceRemoteType = z14.enum(["Figma", "TokenStudio", "FigmaVariablesPlugin"]);
|
|
347
349
|
var DataSourceUploadRemoteSource = z14.enum(["TokenStudio", "FigmaVariablesPlugin", "Custom"]);
|
|
@@ -427,7 +429,8 @@ var ImportJob = Entity.extend({
|
|
|
427
429
|
createdByUserId: z17.string().optional(),
|
|
428
430
|
importContextId: z17.string(),
|
|
429
431
|
error: z17.string().optional(),
|
|
430
|
-
sourceType: DataSourceRemoteType
|
|
432
|
+
sourceType: DataSourceRemoteType,
|
|
433
|
+
importContextCleanedUp: z17.boolean()
|
|
431
434
|
});
|
|
432
435
|
var TokenDataAliasSchema = z18.object({
|
|
433
436
|
aliasTo: z18.string().optional().nullable().transform((v) => v ?? void 0)
|
|
@@ -561,7 +564,8 @@ var ShallowDesignElement = z27.object({
|
|
|
561
564
|
parentPersistentId: z27.string().optional(),
|
|
562
565
|
shortPersistentId: z27.string().optional(),
|
|
563
566
|
childType: DesignElementType.optional(),
|
|
564
|
-
sortOrder: z27.number()
|
|
567
|
+
sortOrder: z27.number(),
|
|
568
|
+
origin: z27.record(z27.any()).optional()
|
|
565
569
|
});
|
|
566
570
|
var DesignElement = ShallowDesignElement.extend({
|
|
567
571
|
meta: ObjectMeta,
|
|
@@ -1215,11 +1219,13 @@ var FigmaNodeReferenceData = z46.object({
|
|
|
1215
1219
|
nodeId: z46.string(),
|
|
1216
1220
|
fileId: z46.string().optional(),
|
|
1217
1221
|
valid: z46.boolean(),
|
|
1222
|
+
// Asset data
|
|
1218
1223
|
assetId: z46.string().optional(),
|
|
1219
1224
|
assetScale: z46.number().optional(),
|
|
1220
1225
|
assetWidth: z46.number().optional(),
|
|
1221
1226
|
assetHeight: z46.number().optional(),
|
|
1222
|
-
assetUrl: z46.string().optional()
|
|
1227
|
+
assetUrl: z46.string().optional(),
|
|
1228
|
+
assetOriginKey: z46.string().optional()
|
|
1223
1229
|
});
|
|
1224
1230
|
var FigmaNodeReferenceElementData = z46.object({
|
|
1225
1231
|
value: FigmaNodeReferenceData
|
|
@@ -1411,11 +1417,15 @@ var FigmaFileStructure = DesignElementBase.extend({
|
|
|
1411
1417
|
origin: FigmaFileStructureOrigin,
|
|
1412
1418
|
data: FigmaFileStructureData
|
|
1413
1419
|
});
|
|
1420
|
+
var FigmaNodeReferenceOrigin = z71.object({
|
|
1421
|
+
sourceId: z71.string()
|
|
1422
|
+
});
|
|
1414
1423
|
var FigmaNodeReference = DesignElementBase.extend({
|
|
1415
|
-
data: FigmaNodeReferenceData
|
|
1424
|
+
data: FigmaNodeReferenceData,
|
|
1425
|
+
origin: FigmaNodeReferenceOrigin
|
|
1416
1426
|
});
|
|
1417
1427
|
var ElementGroup = DesignElementBase.extend(DesignElementGroupablePart.shape).extend(DesignElementSlugPart.shape).extend(DesignElementBrandedPart.partial().shape).extend({
|
|
1418
|
-
shortPersistentId:
|
|
1428
|
+
shortPersistentId: z72.string().optional(),
|
|
1419
1429
|
childType: DesignElementType,
|
|
1420
1430
|
data: ElementGroupDataV2.optional()
|
|
1421
1431
|
});
|
|
@@ -1423,13 +1433,13 @@ var BrandedElementGroup = ElementGroup.extend(DesignElementBrandedPart.shape);
|
|
|
1423
1433
|
var PageBlockV2 = DesignElementBase.extend(DesignElementGroupableRequiredPart.shape).extend({
|
|
1424
1434
|
data: PageBlockDataV2
|
|
1425
1435
|
});
|
|
1426
|
-
var PageBlockEditorModelV2 =
|
|
1427
|
-
id:
|
|
1436
|
+
var PageBlockEditorModelV2 = z73.object({
|
|
1437
|
+
id: z73.string(),
|
|
1428
1438
|
data: PageBlockDataV2
|
|
1429
1439
|
});
|
|
1430
|
-
var DesignTokenOriginPart =
|
|
1431
|
-
referenceOriginId:
|
|
1432
|
-
referencePersistentId:
|
|
1440
|
+
var DesignTokenOriginPart = z74.object({
|
|
1441
|
+
referenceOriginId: z74.string().optional(),
|
|
1442
|
+
referencePersistentId: z74.string().optional()
|
|
1433
1443
|
});
|
|
1434
1444
|
var DesignTokenOrigin = DesignElementOrigin.extend(DesignTokenOriginPart.shape);
|
|
1435
1445
|
var DesignTokenBase = DesignElementBase.extend(DesignElementGroupableRequiredPart.shape).extend(DesignElementBrandedPart.shape).extend({
|
|
@@ -1441,111 +1451,111 @@ var UpdateDesignTokenBase = DesignTokenBase.omit({
|
|
|
1441
1451
|
brandPersistentId: true,
|
|
1442
1452
|
designSystemVersionId: true
|
|
1443
1453
|
});
|
|
1444
|
-
var BlurTokenTypedData =
|
|
1445
|
-
type:
|
|
1454
|
+
var BlurTokenTypedData = z74.object({
|
|
1455
|
+
type: z74.literal("Blur"),
|
|
1446
1456
|
data: BlurTokenData
|
|
1447
1457
|
});
|
|
1448
|
-
var ColorTokenTypedData =
|
|
1449
|
-
type:
|
|
1458
|
+
var ColorTokenTypedData = z74.object({
|
|
1459
|
+
type: z74.literal("Color"),
|
|
1450
1460
|
data: ColorTokenData
|
|
1451
1461
|
});
|
|
1452
|
-
var GradientTokenTypedData =
|
|
1453
|
-
type:
|
|
1462
|
+
var GradientTokenTypedData = z74.object({
|
|
1463
|
+
type: z74.literal("Gradient"),
|
|
1454
1464
|
data: GradientTokenData
|
|
1455
1465
|
});
|
|
1456
|
-
var OpacityTokenTypedData =
|
|
1457
|
-
type:
|
|
1466
|
+
var OpacityTokenTypedData = z74.object({
|
|
1467
|
+
type: z74.literal("Opacity"),
|
|
1458
1468
|
data: OpacityTokenData
|
|
1459
1469
|
});
|
|
1460
|
-
var ShadowTokenTypedData =
|
|
1461
|
-
type:
|
|
1470
|
+
var ShadowTokenTypedData = z74.object({
|
|
1471
|
+
type: z74.literal("Shadow"),
|
|
1462
1472
|
data: ShadowTokenData
|
|
1463
1473
|
});
|
|
1464
|
-
var TypographyTokenTypedData =
|
|
1465
|
-
type:
|
|
1474
|
+
var TypographyTokenTypedData = z74.object({
|
|
1475
|
+
type: z74.literal("Typography"),
|
|
1466
1476
|
data: TypographyTokenData
|
|
1467
1477
|
});
|
|
1468
|
-
var StringTokenTypedData =
|
|
1469
|
-
type:
|
|
1478
|
+
var StringTokenTypedData = z74.object({
|
|
1479
|
+
type: z74.literal("String"),
|
|
1470
1480
|
data: StringTokenData
|
|
1471
1481
|
});
|
|
1472
|
-
var DimensionTokenTypedData =
|
|
1473
|
-
type:
|
|
1482
|
+
var DimensionTokenTypedData = z74.object({
|
|
1483
|
+
type: z74.literal("Dimension"),
|
|
1474
1484
|
data: DimensionTokenData
|
|
1475
1485
|
});
|
|
1476
|
-
var FontSizeTokenTypedData =
|
|
1477
|
-
type:
|
|
1486
|
+
var FontSizeTokenTypedData = z74.object({
|
|
1487
|
+
type: z74.literal("FontSize"),
|
|
1478
1488
|
data: FontSizeTokenData
|
|
1479
1489
|
});
|
|
1480
|
-
var FontFamilyTokenTypedData =
|
|
1481
|
-
type:
|
|
1490
|
+
var FontFamilyTokenTypedData = z74.object({
|
|
1491
|
+
type: z74.literal("FontFamily"),
|
|
1482
1492
|
data: FontFamilyTokenData
|
|
1483
1493
|
});
|
|
1484
|
-
var FontWeightTokenTypedData =
|
|
1485
|
-
type:
|
|
1494
|
+
var FontWeightTokenTypedData = z74.object({
|
|
1495
|
+
type: z74.literal("FontWeight"),
|
|
1486
1496
|
data: FontWeightTokenData
|
|
1487
1497
|
});
|
|
1488
|
-
var LetterSpacingTokenTypedData =
|
|
1489
|
-
type:
|
|
1498
|
+
var LetterSpacingTokenTypedData = z74.object({
|
|
1499
|
+
type: z74.literal("LetterSpacing"),
|
|
1490
1500
|
data: LetterSpacingTokenData
|
|
1491
1501
|
});
|
|
1492
|
-
var LineHeightTokenTypedData =
|
|
1493
|
-
type:
|
|
1502
|
+
var LineHeightTokenTypedData = z74.object({
|
|
1503
|
+
type: z74.literal("LineHeight"),
|
|
1494
1504
|
data: LineHeightTokenData
|
|
1495
1505
|
});
|
|
1496
|
-
var ParagraphSpacingTokenTypedData =
|
|
1497
|
-
type:
|
|
1506
|
+
var ParagraphSpacingTokenTypedData = z74.object({
|
|
1507
|
+
type: z74.literal("ParagraphSpacing"),
|
|
1498
1508
|
data: ParagraphSpacingTokenData
|
|
1499
1509
|
});
|
|
1500
|
-
var TextCaseTokenTypedData =
|
|
1501
|
-
type:
|
|
1510
|
+
var TextCaseTokenTypedData = z74.object({
|
|
1511
|
+
type: z74.literal("TextCase"),
|
|
1502
1512
|
data: TextCaseTokenData
|
|
1503
1513
|
});
|
|
1504
|
-
var TextDecorationTokenTypedData =
|
|
1505
|
-
type:
|
|
1514
|
+
var TextDecorationTokenTypedData = z74.object({
|
|
1515
|
+
type: z74.literal("TextDecoration"),
|
|
1506
1516
|
data: TextDecorationTokenData
|
|
1507
1517
|
});
|
|
1508
|
-
var BorderRadiusTokenTypedData =
|
|
1509
|
-
type:
|
|
1518
|
+
var BorderRadiusTokenTypedData = z74.object({
|
|
1519
|
+
type: z74.literal("BorderRadius"),
|
|
1510
1520
|
data: BorderRadiusTokenData
|
|
1511
1521
|
});
|
|
1512
|
-
var BorderWidthTokenTypedData =
|
|
1513
|
-
type:
|
|
1522
|
+
var BorderWidthTokenTypedData = z74.object({
|
|
1523
|
+
type: z74.literal("BorderWidth"),
|
|
1514
1524
|
data: BorderWidthTokenData
|
|
1515
1525
|
});
|
|
1516
|
-
var BorderTypedData =
|
|
1517
|
-
type:
|
|
1526
|
+
var BorderTypedData = z74.object({
|
|
1527
|
+
type: z74.literal("Border"),
|
|
1518
1528
|
data: BorderTokenData
|
|
1519
1529
|
});
|
|
1520
|
-
var ProductCopyTypedData =
|
|
1521
|
-
type:
|
|
1530
|
+
var ProductCopyTypedData = z74.object({
|
|
1531
|
+
type: z74.literal("ProductCopy"),
|
|
1522
1532
|
data: ProductCopyTokenData
|
|
1523
1533
|
});
|
|
1524
|
-
var SizeTypedData =
|
|
1525
|
-
type:
|
|
1534
|
+
var SizeTypedData = z74.object({
|
|
1535
|
+
type: z74.literal("Size"),
|
|
1526
1536
|
data: SizeTokenData
|
|
1527
1537
|
});
|
|
1528
|
-
var SpaceTypedData =
|
|
1529
|
-
type:
|
|
1538
|
+
var SpaceTypedData = z74.object({
|
|
1539
|
+
type: z74.literal("Space"),
|
|
1530
1540
|
data: SpaceTokenData
|
|
1531
1541
|
});
|
|
1532
|
-
var VisibilityTypedData =
|
|
1533
|
-
type:
|
|
1542
|
+
var VisibilityTypedData = z74.object({
|
|
1543
|
+
type: z74.literal("Visibility"),
|
|
1534
1544
|
data: VisibilityTokenData
|
|
1535
1545
|
});
|
|
1536
|
-
var ZIndexTypedData =
|
|
1537
|
-
type:
|
|
1546
|
+
var ZIndexTypedData = z74.object({
|
|
1547
|
+
type: z74.literal("ZIndex"),
|
|
1538
1548
|
data: ZIndexTokenData
|
|
1539
1549
|
});
|
|
1540
|
-
var DurationTypedData =
|
|
1541
|
-
type:
|
|
1550
|
+
var DurationTypedData = z74.object({
|
|
1551
|
+
type: z74.literal("Duration"),
|
|
1542
1552
|
data: DurationTokenData
|
|
1543
1553
|
});
|
|
1544
|
-
var FontTypedData =
|
|
1545
|
-
type:
|
|
1546
|
-
data:
|
|
1554
|
+
var FontTypedData = z74.object({
|
|
1555
|
+
type: z74.literal("Font"),
|
|
1556
|
+
data: z74.record(z74.any())
|
|
1547
1557
|
});
|
|
1548
|
-
var DesignTokenTypedData =
|
|
1558
|
+
var DesignTokenTypedData = z74.discriminatedUnion("type", [
|
|
1549
1559
|
BlurTokenTypedData,
|
|
1550
1560
|
BorderRadiusTokenTypedData,
|
|
1551
1561
|
BorderWidthTokenTypedData,
|
|
@@ -1578,66 +1588,66 @@ var CreateDesignToken = DesignTokenTypedData.and(CreateDesignTokenBase);
|
|
|
1578
1588
|
var ThemeOverrideOriginPart = DesignTokenOriginPart;
|
|
1579
1589
|
var ThemeOverrideOrigin = DesignTokenOrigin;
|
|
1580
1590
|
var ThemeOverride = DesignTokenTypedData.and(
|
|
1581
|
-
|
|
1582
|
-
tokenPersistentId:
|
|
1591
|
+
z75.object({
|
|
1592
|
+
tokenPersistentId: z75.string(),
|
|
1583
1593
|
origin: ThemeOverrideOrigin.optional().nullable().transform((v) => v ?? void 0)
|
|
1584
1594
|
})
|
|
1585
1595
|
);
|
|
1586
|
-
var ThemeElementData =
|
|
1587
|
-
value:
|
|
1588
|
-
overrides:
|
|
1596
|
+
var ThemeElementData = z75.object({
|
|
1597
|
+
value: z75.object({
|
|
1598
|
+
overrides: z75.array(ThemeOverride)
|
|
1589
1599
|
})
|
|
1590
1600
|
});
|
|
1591
|
-
var ThemeOriginPart =
|
|
1592
|
-
var ThemeOriginObject =
|
|
1593
|
-
id:
|
|
1594
|
-
name:
|
|
1601
|
+
var ThemeOriginPart = z75.object({});
|
|
1602
|
+
var ThemeOriginObject = z75.object({
|
|
1603
|
+
id: z75.string(),
|
|
1604
|
+
name: z75.string()
|
|
1595
1605
|
});
|
|
1596
|
-
var ThemeOriginSource =
|
|
1597
|
-
sourceId:
|
|
1598
|
-
sourceObjects:
|
|
1606
|
+
var ThemeOriginSource = z75.object({
|
|
1607
|
+
sourceId: z75.string(),
|
|
1608
|
+
sourceObjects: z75.array(ThemeOriginObject)
|
|
1599
1609
|
});
|
|
1600
|
-
var ThemeOrigin =
|
|
1601
|
-
sources:
|
|
1610
|
+
var ThemeOrigin = z75.object({
|
|
1611
|
+
sources: z75.array(ThemeOriginSource)
|
|
1602
1612
|
});
|
|
1603
1613
|
var Theme = DesignElementBase.extend(DesignElementBrandedPart.shape).extend({
|
|
1604
1614
|
origin: ThemeOrigin.optional(),
|
|
1605
|
-
overrides:
|
|
1615
|
+
overrides: z75.array(ThemeOverride)
|
|
1606
1616
|
});
|
|
1607
|
-
var FigmaFileDownloadScope =
|
|
1608
|
-
styles:
|
|
1609
|
-
components:
|
|
1610
|
-
currentVersion:
|
|
1611
|
-
publishedVersion:
|
|
1612
|
-
downloadChunkSize:
|
|
1617
|
+
var FigmaFileDownloadScope = z76.object({
|
|
1618
|
+
styles: z76.boolean(),
|
|
1619
|
+
components: z76.boolean(),
|
|
1620
|
+
currentVersion: z76.literal("__latest__").nullable(),
|
|
1621
|
+
publishedVersion: z76.string().nullable(),
|
|
1622
|
+
downloadChunkSize: z76.number().optional()
|
|
1613
1623
|
});
|
|
1614
|
-
var FigmaFileAccessData =
|
|
1615
|
-
accessToken:
|
|
1624
|
+
var FigmaFileAccessData = z76.object({
|
|
1625
|
+
accessToken: z76.string()
|
|
1616
1626
|
});
|
|
1617
|
-
var ImportFunctionInput =
|
|
1618
|
-
importJobId:
|
|
1619
|
-
importContextId:
|
|
1620
|
-
designSystemId:
|
|
1627
|
+
var ImportFunctionInput = z77.object({
|
|
1628
|
+
importJobId: z77.string(),
|
|
1629
|
+
importContextId: z77.string(),
|
|
1630
|
+
designSystemId: z77.string().optional()
|
|
1621
1631
|
});
|
|
1622
|
-
var ImportedFigmaSourceData =
|
|
1623
|
-
sourceId:
|
|
1632
|
+
var ImportedFigmaSourceData = z77.object({
|
|
1633
|
+
sourceId: z77.string(),
|
|
1624
1634
|
figmaRemote: DataSourceFigmaRemote
|
|
1625
1635
|
});
|
|
1626
|
-
var FigmaImportBaseContext =
|
|
1627
|
-
designSystemId:
|
|
1636
|
+
var FigmaImportBaseContext = z77.object({
|
|
1637
|
+
designSystemId: z77.string(),
|
|
1628
1638
|
/**
|
|
1629
1639
|
* Data required for accessing Figma files. This should contain access data for all file ids
|
|
1630
1640
|
* mentioned in the `importedSourceDataBySourceId`
|
|
1631
1641
|
*
|
|
1632
1642
|
* fileId: file data
|
|
1633
1643
|
*/
|
|
1634
|
-
fileAccessByFileId:
|
|
1644
|
+
fileAccessByFileId: z77.record(FigmaFileAccessData),
|
|
1635
1645
|
/**
|
|
1636
1646
|
* Figma source data for which import was requested
|
|
1637
1647
|
*
|
|
1638
1648
|
* sourceId: source data
|
|
1639
1649
|
*/
|
|
1640
|
-
importedSourceDataBySourceId:
|
|
1650
|
+
importedSourceDataBySourceId: z77.record(ImportedFigmaSourceData)
|
|
1641
1651
|
});
|
|
1642
1652
|
var ChangedImportedFigmaSourceData = ImportedFigmaSourceData.extend({
|
|
1643
1653
|
importMetadata: DataSourceFigmaImportMetadata
|
|
@@ -1649,65 +1659,65 @@ var FigmaImportContextWithDownloadScopes = FigmaImportBaseContext.extend({
|
|
|
1649
1659
|
*
|
|
1650
1660
|
* File id -> file download scope
|
|
1651
1661
|
*/
|
|
1652
|
-
fileDownloadScopesByFileId:
|
|
1662
|
+
fileDownloadScopesByFileId: z77.record(FigmaFileDownloadScope),
|
|
1653
1663
|
/**
|
|
1654
1664
|
* Sources filtered down to the ones that have changed since last import and therefore need to be
|
|
1655
1665
|
* imported again.
|
|
1656
1666
|
*
|
|
1657
1667
|
* Source id -> import metadata
|
|
1658
1668
|
*/
|
|
1659
|
-
changedImportedSourceDataBySourceId:
|
|
1669
|
+
changedImportedSourceDataBySourceId: z77.record(ChangedImportedFigmaSourceData)
|
|
1660
1670
|
});
|
|
1661
|
-
var ImageImportModelType =
|
|
1662
|
-
var ImageImportModelBase =
|
|
1671
|
+
var ImageImportModelType = z78.enum(["Url", "FigmaRender"]);
|
|
1672
|
+
var ImageImportModelBase = z78.object({
|
|
1663
1673
|
scope: AssetScope
|
|
1664
1674
|
});
|
|
1665
1675
|
var UrlImageImportModel = ImageImportModelBase.extend({
|
|
1666
|
-
type:
|
|
1667
|
-
url:
|
|
1668
|
-
originKey:
|
|
1669
|
-
extension:
|
|
1676
|
+
type: z78.literal(ImageImportModelType.enum.Url),
|
|
1677
|
+
url: z78.string(),
|
|
1678
|
+
originKey: z78.string(),
|
|
1679
|
+
extension: z78.string()
|
|
1670
1680
|
});
|
|
1671
|
-
var FigmaRenderFormat =
|
|
1681
|
+
var FigmaRenderFormat = z78.enum(["Svg", "Png"]);
|
|
1672
1682
|
var FigmaRenderBase = ImageImportModelBase.extend({
|
|
1673
|
-
type:
|
|
1674
|
-
fileId:
|
|
1675
|
-
fileVersionId:
|
|
1676
|
-
nodeId:
|
|
1677
|
-
originKey:
|
|
1683
|
+
type: z78.literal(ImageImportModelType.enum.FigmaRender),
|
|
1684
|
+
fileId: z78.string(),
|
|
1685
|
+
fileVersionId: z78.string().optional(),
|
|
1686
|
+
nodeId: z78.string(),
|
|
1687
|
+
originKey: z78.string()
|
|
1678
1688
|
});
|
|
1679
1689
|
var FigmaPngRenderImportModel = FigmaRenderBase.extend({
|
|
1680
|
-
format:
|
|
1681
|
-
scale:
|
|
1690
|
+
format: z78.literal(FigmaRenderFormat.enum.Png),
|
|
1691
|
+
scale: z78.number()
|
|
1682
1692
|
});
|
|
1683
1693
|
var FigmaSvgRenderImportModel = FigmaRenderBase.extend({
|
|
1684
|
-
format:
|
|
1694
|
+
format: z78.literal(FigmaRenderFormat.enum.Svg)
|
|
1685
1695
|
});
|
|
1686
|
-
var FigmaRenderImportModel =
|
|
1696
|
+
var FigmaRenderImportModel = z78.discriminatedUnion("format", [
|
|
1687
1697
|
FigmaPngRenderImportModel,
|
|
1688
1698
|
FigmaSvgRenderImportModel
|
|
1689
1699
|
]);
|
|
1690
|
-
var ImageImportModel =
|
|
1691
|
-
var ImportModelBase =
|
|
1692
|
-
id:
|
|
1700
|
+
var ImageImportModel = z78.union([UrlImageImportModel, FigmaRenderImportModel]);
|
|
1701
|
+
var ImportModelBase = z79.object({
|
|
1702
|
+
id: z79.string(),
|
|
1693
1703
|
meta: ObjectMeta,
|
|
1694
1704
|
origin: DesignElementOrigin,
|
|
1695
|
-
brandPersistentId:
|
|
1696
|
-
sortOrder:
|
|
1705
|
+
brandPersistentId: z79.string(),
|
|
1706
|
+
sortOrder: z79.number()
|
|
1697
1707
|
});
|
|
1698
1708
|
var ImportModelInputBase = ImportModelBase.omit({
|
|
1699
1709
|
brandPersistentId: true,
|
|
1700
1710
|
origin: true,
|
|
1701
1711
|
sortOrder: true
|
|
1702
1712
|
}).extend({
|
|
1703
|
-
originId:
|
|
1704
|
-
originMetadata:
|
|
1713
|
+
originId: z79.string(),
|
|
1714
|
+
originMetadata: z79.record(z79.any())
|
|
1705
1715
|
});
|
|
1706
|
-
var ComponentImportModelPart =
|
|
1716
|
+
var ComponentImportModelPart = z80.object({
|
|
1707
1717
|
thumbnail: ImageImportModel
|
|
1708
1718
|
});
|
|
1709
1719
|
var ComponentImportModel = ImportModelBase.extend(ComponentImportModelPart.shape).extend({
|
|
1710
|
-
isAsset:
|
|
1720
|
+
isAsset: z80.boolean(),
|
|
1711
1721
|
svg: FigmaSvgRenderImportModel.optional(),
|
|
1712
1722
|
origin: ComponentOrigin
|
|
1713
1723
|
});
|
|
@@ -1719,44 +1729,44 @@ var AssetImportModelInput = ImportModelInputBase.extend(ComponentImportModelPart
|
|
|
1719
1729
|
originMetadata: ComponentOriginPart
|
|
1720
1730
|
});
|
|
1721
1731
|
var ThemeOverrideImportModelBase = DesignTokenTypedData.and(
|
|
1722
|
-
|
|
1723
|
-
id:
|
|
1732
|
+
z81.object({
|
|
1733
|
+
id: z81.string(),
|
|
1724
1734
|
meta: ObjectMeta
|
|
1725
1735
|
})
|
|
1726
1736
|
);
|
|
1727
1737
|
var ThemeOverrideImportModel = ThemeOverrideImportModelBase.and(
|
|
1728
|
-
|
|
1738
|
+
z81.object({
|
|
1729
1739
|
origin: ThemeOverrideOrigin
|
|
1730
1740
|
})
|
|
1731
1741
|
);
|
|
1732
1742
|
var ThemeOverrideImportModelInput = ThemeOverrideImportModelBase.and(
|
|
1733
|
-
|
|
1734
|
-
originId:
|
|
1743
|
+
z81.object({
|
|
1744
|
+
originId: z81.string(),
|
|
1735
1745
|
originMetadata: ThemeOverrideOriginPart
|
|
1736
1746
|
})
|
|
1737
1747
|
);
|
|
1738
|
-
var ThemeImportModel =
|
|
1748
|
+
var ThemeImportModel = z81.object({
|
|
1739
1749
|
meta: ObjectMeta,
|
|
1740
|
-
brandPersistentId:
|
|
1750
|
+
brandPersistentId: z81.string(),
|
|
1741
1751
|
originSource: ThemeOriginSource,
|
|
1742
|
-
overrides:
|
|
1743
|
-
sortOrder:
|
|
1752
|
+
overrides: z81.array(ThemeOverrideImportModel),
|
|
1753
|
+
sortOrder: z81.number()
|
|
1744
1754
|
});
|
|
1745
|
-
var ThemeImportModelInput =
|
|
1755
|
+
var ThemeImportModelInput = z81.object({
|
|
1746
1756
|
meta: ObjectMeta,
|
|
1747
|
-
originObjects:
|
|
1748
|
-
overrides:
|
|
1757
|
+
originObjects: z81.array(ThemeOriginObject),
|
|
1758
|
+
overrides: z81.array(ThemeOverrideImportModelInput)
|
|
1749
1759
|
});
|
|
1750
|
-
var ThemeUpdateImportModel =
|
|
1751
|
-
themePersistentId:
|
|
1752
|
-
overrides:
|
|
1760
|
+
var ThemeUpdateImportModel = z81.object({
|
|
1761
|
+
themePersistentId: z81.string(),
|
|
1762
|
+
overrides: z81.array(ThemeOverrideImportModel)
|
|
1753
1763
|
});
|
|
1754
|
-
var ThemeUpdateImportModelInput =
|
|
1755
|
-
themePersistentId:
|
|
1756
|
-
overrides:
|
|
1764
|
+
var ThemeUpdateImportModelInput = z81.object({
|
|
1765
|
+
themePersistentId: z81.string(),
|
|
1766
|
+
overrides: z81.array(ThemeOverrideImportModelInput)
|
|
1757
1767
|
});
|
|
1758
|
-
var DesignTokenImportModelPart =
|
|
1759
|
-
collection:
|
|
1768
|
+
var DesignTokenImportModelPart = z82.object({
|
|
1769
|
+
collection: z82.string().optional()
|
|
1760
1770
|
});
|
|
1761
1771
|
var DesignTokenImportModelBase = ImportModelBase.extend(DesignTokenImportModelPart.shape).extend({
|
|
1762
1772
|
origin: DesignTokenOrigin
|
|
@@ -1770,10 +1780,10 @@ var FigmaFileStructureNodeImportModelBase = FigmaFileStructureNodeBase.extend({
|
|
|
1770
1780
|
image: FigmaPngRenderImportModel
|
|
1771
1781
|
});
|
|
1772
1782
|
var FigmaFileStructureNodeImportModel = FigmaFileStructureNodeImportModelBase.extend({
|
|
1773
|
-
children:
|
|
1783
|
+
children: z83.lazy(() => FigmaFileStructureNodeImportModel.array())
|
|
1774
1784
|
});
|
|
1775
|
-
var FigmaFileStructureImportModelPart =
|
|
1776
|
-
data:
|
|
1785
|
+
var FigmaFileStructureImportModelPart = z83.object({
|
|
1786
|
+
data: z83.object({
|
|
1777
1787
|
rootNode: FigmaFileStructureNodeImportModel,
|
|
1778
1788
|
assetsInFile: FigmaFileStructureStatistics
|
|
1779
1789
|
})
|
|
@@ -1784,31 +1794,31 @@ var FigmaFileStructureImportModel = ImportModelBase.extend(FigmaFileStructureImp
|
|
|
1784
1794
|
var FigmaFileStructureImportModelInput = ImportModelInputBase.extend(
|
|
1785
1795
|
FigmaFileStructureImportModelPart.shape
|
|
1786
1796
|
).extend({
|
|
1787
|
-
fileVersionId:
|
|
1797
|
+
fileVersionId: z83.string()
|
|
1788
1798
|
});
|
|
1789
|
-
var DataSourceImportModel =
|
|
1790
|
-
id:
|
|
1791
|
-
fileName:
|
|
1792
|
-
thumbnailUrl:
|
|
1799
|
+
var DataSourceImportModel = z84.object({
|
|
1800
|
+
id: z84.string(),
|
|
1801
|
+
fileName: z84.string().optional(),
|
|
1802
|
+
thumbnailUrl: z84.string().optional()
|
|
1793
1803
|
});
|
|
1794
|
-
var ImportModelInputCollection =
|
|
1804
|
+
var ImportModelInputCollection = z85.object({
|
|
1795
1805
|
source: DataSourceImportModel,
|
|
1796
|
-
tokens:
|
|
1797
|
-
components:
|
|
1798
|
-
assets:
|
|
1799
|
-
themeUpdates:
|
|
1800
|
-
themes:
|
|
1806
|
+
tokens: z85.array(DesignTokenImportModelInput).default([]),
|
|
1807
|
+
components: z85.array(ComponentImportModelInput).default([]),
|
|
1808
|
+
assets: z85.array(AssetImportModelInput).default([]),
|
|
1809
|
+
themeUpdates: z85.array(ThemeUpdateImportModelInput).default([]),
|
|
1810
|
+
themes: z85.array(ThemeImportModelInput).default([]),
|
|
1801
1811
|
figmaFileStructure: FigmaFileStructureImportModelInput.optional()
|
|
1802
1812
|
});
|
|
1803
|
-
var ImportModelCollection =
|
|
1804
|
-
sources:
|
|
1805
|
-
tokens:
|
|
1806
|
-
components:
|
|
1807
|
-
themeUpdates:
|
|
1808
|
-
themes:
|
|
1809
|
-
figmaFileStructures:
|
|
1813
|
+
var ImportModelCollection = z85.object({
|
|
1814
|
+
sources: z85.array(DataSourceImportModel),
|
|
1815
|
+
tokens: z85.array(DesignTokenImportModel).default([]),
|
|
1816
|
+
components: z85.array(ComponentImportModel).default([]),
|
|
1817
|
+
themeUpdates: z85.array(ThemeUpdateImportModel).default([]),
|
|
1818
|
+
themes: z85.array(ThemeImportModel).default([]),
|
|
1819
|
+
figmaFileStructures: z85.array(FigmaFileStructureImportModel)
|
|
1810
1820
|
});
|
|
1811
|
-
var ImportWarningType =
|
|
1821
|
+
var ImportWarningType = z86.enum([
|
|
1812
1822
|
"NoVersionFound",
|
|
1813
1823
|
"UnsupportedFill",
|
|
1814
1824
|
"UnsupportedStroke",
|
|
@@ -1822,25 +1832,25 @@ var ImportWarningType = z85.enum([
|
|
|
1822
1832
|
"DuplicateImportedStyleId",
|
|
1823
1833
|
"DuplicateImportedStylePath"
|
|
1824
1834
|
]);
|
|
1825
|
-
var ImportWarning =
|
|
1835
|
+
var ImportWarning = z86.object({
|
|
1826
1836
|
warningType: ImportWarningType,
|
|
1827
|
-
componentId:
|
|
1828
|
-
componentName:
|
|
1829
|
-
styleId:
|
|
1830
|
-
styleName:
|
|
1831
|
-
unsupportedStyleValueType:
|
|
1837
|
+
componentId: z86.string().optional(),
|
|
1838
|
+
componentName: z86.string().optional(),
|
|
1839
|
+
styleId: z86.string().optional(),
|
|
1840
|
+
styleName: z86.string().optional(),
|
|
1841
|
+
unsupportedStyleValueType: z86.string().optional()
|
|
1832
1842
|
});
|
|
1833
|
-
var FileStructureStats =
|
|
1843
|
+
var FileStructureStats = z87.object({
|
|
1834
1844
|
frames: zeroNumberByDefault2(),
|
|
1835
1845
|
components: zeroNumberByDefault2(),
|
|
1836
1846
|
componentSets: zeroNumberByDefault2()
|
|
1837
1847
|
});
|
|
1838
1848
|
var SourceImportSummaryByTokenTypeKey = DesignTokenType.or(
|
|
1839
1849
|
// Backward compatibility
|
|
1840
|
-
|
|
1850
|
+
z87.enum(["Measure", "Radius", "GenericToken", "Font", "Text"])
|
|
1841
1851
|
);
|
|
1842
|
-
var SourceImportSummaryByTokenType =
|
|
1843
|
-
var SourceImportTokenSummary =
|
|
1852
|
+
var SourceImportSummaryByTokenType = z87.record(SourceImportSummaryByTokenTypeKey, z87.number());
|
|
1853
|
+
var SourceImportTokenSummary = z87.object({
|
|
1844
1854
|
tokensCreated: zeroNumberByDefault2(),
|
|
1845
1855
|
tokensUpdated: zeroNumberByDefault2(),
|
|
1846
1856
|
tokensDeleted: zeroNumberByDefault2(),
|
|
@@ -1848,7 +1858,7 @@ var SourceImportTokenSummary = z86.object({
|
|
|
1848
1858
|
tokensUpdatedPerType: SourceImportSummaryByTokenType.nullish().transform((v) => v ?? {}),
|
|
1849
1859
|
tokensDeletedPerType: SourceImportSummaryByTokenType.nullish().transform((v) => v ?? {})
|
|
1850
1860
|
});
|
|
1851
|
-
var SourceImportComponentSummary =
|
|
1861
|
+
var SourceImportComponentSummary = z87.object({
|
|
1852
1862
|
componentsCreated: zeroNumberByDefault2(),
|
|
1853
1863
|
componentsUpdated: zeroNumberByDefault2(),
|
|
1854
1864
|
componentsDeleted: zeroNumberByDefault2(),
|
|
@@ -1856,54 +1866,54 @@ var SourceImportComponentSummary = z86.object({
|
|
|
1856
1866
|
componentAssetsUpdated: zeroNumberByDefault2(),
|
|
1857
1867
|
componentAssetsDeleted: zeroNumberByDefault2()
|
|
1858
1868
|
});
|
|
1859
|
-
var SourceImportFrameSummary =
|
|
1869
|
+
var SourceImportFrameSummary = z87.object({
|
|
1860
1870
|
assetsInFile: nullishToOptional(FileStructureStats.optional()),
|
|
1861
|
-
invalidReferencesCount: nullishToOptional(
|
|
1862
|
-
});
|
|
1863
|
-
var SourceImportSummary =
|
|
1864
|
-
sourceId: nullishToOptional(
|
|
1865
|
-
brandId: nullishToOptional(
|
|
1866
|
-
versionId: nullishToOptional(
|
|
1867
|
-
error: nullishToOptional(
|
|
1868
|
-
isFailed:
|
|
1869
|
-
warnings:
|
|
1871
|
+
invalidReferencesCount: nullishToOptional(z87.number().optional())
|
|
1872
|
+
});
|
|
1873
|
+
var SourceImportSummary = z87.object({
|
|
1874
|
+
sourceId: nullishToOptional(z87.string()),
|
|
1875
|
+
brandId: nullishToOptional(z87.string()),
|
|
1876
|
+
versionId: nullishToOptional(z87.string()),
|
|
1877
|
+
error: nullishToOptional(z87.any()),
|
|
1878
|
+
isFailed: z87.boolean(),
|
|
1879
|
+
warnings: z87.array(ImportWarning).nullish().transform((v) => v ?? []),
|
|
1870
1880
|
...SourceImportTokenSummary.shape,
|
|
1871
1881
|
...SourceImportComponentSummary.shape,
|
|
1872
1882
|
...FileStructureStats.shape
|
|
1873
1883
|
});
|
|
1874
1884
|
function zeroNumberByDefault2() {
|
|
1875
|
-
return
|
|
1885
|
+
return z87.number().nullish().transform((v) => v ?? 0);
|
|
1876
1886
|
}
|
|
1877
|
-
var PageBlockDefinitionAppearance =
|
|
1878
|
-
isBordered:
|
|
1879
|
-
hasBackground:
|
|
1880
|
-
isEditorPresentationDifferent:
|
|
1881
|
-
});
|
|
1882
|
-
var PageBlockDefinitionLayoutType =
|
|
1883
|
-
var PageBlockDefinitionLayoutGap =
|
|
1884
|
-
var PageBlockDefinitionLayoutAlign =
|
|
1885
|
-
var PageBlockDefinitionLayoutResizing =
|
|
1886
|
-
var PageBlockDefinitionLayoutBase =
|
|
1887
|
+
var PageBlockDefinitionAppearance = z88.object({
|
|
1888
|
+
isBordered: z88.boolean().optional(),
|
|
1889
|
+
hasBackground: z88.boolean().optional(),
|
|
1890
|
+
isEditorPresentationDifferent: z88.boolean().optional()
|
|
1891
|
+
});
|
|
1892
|
+
var PageBlockDefinitionLayoutType = z89.enum(["Column", "Row"]);
|
|
1893
|
+
var PageBlockDefinitionLayoutGap = z89.enum(["Small", "Medium", "Large", "None"]);
|
|
1894
|
+
var PageBlockDefinitionLayoutAlign = z89.enum(["Start", "Center", "End"]);
|
|
1895
|
+
var PageBlockDefinitionLayoutResizing = z89.enum(["Fill", "Hug"]);
|
|
1896
|
+
var PageBlockDefinitionLayoutBase = z89.object({
|
|
1887
1897
|
type: PageBlockDefinitionLayoutType,
|
|
1888
1898
|
gap: PageBlockDefinitionLayoutGap.optional(),
|
|
1889
1899
|
columnAlign: PageBlockDefinitionLayoutAlign.optional(),
|
|
1890
1900
|
columnResizing: PageBlockDefinitionLayoutResizing.optional()
|
|
1891
1901
|
});
|
|
1892
1902
|
var PageBlockDefinitionLayout = PageBlockDefinitionLayoutBase.extend({
|
|
1893
|
-
children:
|
|
1894
|
-
});
|
|
1895
|
-
var PageBlockDefinitionVariant =
|
|
1896
|
-
id:
|
|
1897
|
-
name:
|
|
1898
|
-
image:
|
|
1899
|
-
description:
|
|
1900
|
-
documentationLink:
|
|
1903
|
+
children: z89.lazy(() => z89.array(PageBlockDefinitionLayout.or(z89.string())))
|
|
1904
|
+
});
|
|
1905
|
+
var PageBlockDefinitionVariant = z89.object({
|
|
1906
|
+
id: z89.string(),
|
|
1907
|
+
name: z89.string(),
|
|
1908
|
+
image: z89.string().optional(),
|
|
1909
|
+
description: z89.string().optional(),
|
|
1910
|
+
documentationLink: z89.string().optional(),
|
|
1901
1911
|
layout: PageBlockDefinitionLayout,
|
|
1902
|
-
maxColumns:
|
|
1903
|
-
defaultColumns:
|
|
1912
|
+
maxColumns: z89.number().optional(),
|
|
1913
|
+
defaultColumns: z89.number().optional(),
|
|
1904
1914
|
appearance: PageBlockDefinitionAppearance.optional()
|
|
1905
1915
|
});
|
|
1906
|
-
var PageBlockDefinitionPropertyType =
|
|
1916
|
+
var PageBlockDefinitionPropertyType = z90.enum([
|
|
1907
1917
|
"RichText",
|
|
1908
1918
|
"MultiRichText",
|
|
1909
1919
|
"Text",
|
|
@@ -1930,7 +1940,7 @@ var PageBlockDefinitionPropertyType = z89.enum([
|
|
|
1930
1940
|
"Storybook",
|
|
1931
1941
|
"Color"
|
|
1932
1942
|
]);
|
|
1933
|
-
var PageBlockDefinitionRichTextPropertyStyle =
|
|
1943
|
+
var PageBlockDefinitionRichTextPropertyStyle = z90.enum([
|
|
1934
1944
|
"Title1",
|
|
1935
1945
|
"Title2",
|
|
1936
1946
|
"Title3",
|
|
@@ -1940,8 +1950,8 @@ var PageBlockDefinitionRichTextPropertyStyle = z89.enum([
|
|
|
1940
1950
|
"Callout",
|
|
1941
1951
|
"Default"
|
|
1942
1952
|
]);
|
|
1943
|
-
var PageBlockDefinitionMultiRichTextPropertyStyle =
|
|
1944
|
-
var PageBlockDefinitionTextPropertyStyle =
|
|
1953
|
+
var PageBlockDefinitionMultiRichTextPropertyStyle = z90.enum(["OL", "UL", "Default"]);
|
|
1954
|
+
var PageBlockDefinitionTextPropertyStyle = z90.enum([
|
|
1945
1955
|
"Title1",
|
|
1946
1956
|
"Title2",
|
|
1947
1957
|
"Title3",
|
|
@@ -1954,77 +1964,77 @@ var PageBlockDefinitionTextPropertyStyle = z89.enum([
|
|
|
1954
1964
|
"SmallBold",
|
|
1955
1965
|
"SmallSemibold"
|
|
1956
1966
|
]);
|
|
1957
|
-
var PageBlockDefinitionTextPropertyColor =
|
|
1958
|
-
var PageBlockDefinitionBooleanPropertyStyle =
|
|
1959
|
-
var PageBlockDefinitionSingleSelectPropertyStyle =
|
|
1967
|
+
var PageBlockDefinitionTextPropertyColor = z90.enum(["Neutral", "NeutralFaded"]);
|
|
1968
|
+
var PageBlockDefinitionBooleanPropertyStyle = z90.enum(["SegmentedControl", "ToggleButton", "Checkbox"]);
|
|
1969
|
+
var PageBlockDefinitionSingleSelectPropertyStyle = z90.enum([
|
|
1960
1970
|
"SegmentedControl",
|
|
1961
1971
|
"ToggleButton",
|
|
1962
1972
|
"Select",
|
|
1963
1973
|
"Checkbox"
|
|
1964
1974
|
]);
|
|
1965
|
-
var PageBlockDefinitionMultiSelectPropertyStyle =
|
|
1966
|
-
var PageBlockDefinitionImageAspectRatio =
|
|
1967
|
-
var PageBlockDefinitionImageWidth =
|
|
1968
|
-
var PageBlockDefinitionSelectChoice =
|
|
1969
|
-
value:
|
|
1970
|
-
name:
|
|
1971
|
-
icon:
|
|
1975
|
+
var PageBlockDefinitionMultiSelectPropertyStyle = z90.enum(["SegmentedControl", "Select", "Checkbox"]);
|
|
1976
|
+
var PageBlockDefinitionImageAspectRatio = z90.enum(["Auto", "Square", "Landscape", "Portrait", "Wide"]);
|
|
1977
|
+
var PageBlockDefinitionImageWidth = z90.enum(["Full", "Icon", "Small", "Medium", "Large", "Poster"]);
|
|
1978
|
+
var PageBlockDefinitionSelectChoice = z90.object({
|
|
1979
|
+
value: z90.string(),
|
|
1980
|
+
name: z90.string(),
|
|
1981
|
+
icon: z90.string().optional()
|
|
1972
1982
|
});
|
|
1973
|
-
var PageBlockDefinitionUntypedPropertyOptions =
|
|
1974
|
-
var PageBlockDefinitionRichTextOptions =
|
|
1983
|
+
var PageBlockDefinitionUntypedPropertyOptions = z90.record(z90.any());
|
|
1984
|
+
var PageBlockDefinitionRichTextOptions = z90.object({
|
|
1975
1985
|
richTextStyle: PageBlockDefinitionRichTextPropertyStyle.optional()
|
|
1976
1986
|
});
|
|
1977
|
-
var PageBlockDefinitionMutiRichTextOptions =
|
|
1987
|
+
var PageBlockDefinitionMutiRichTextOptions = z90.object({
|
|
1978
1988
|
multiRichTextStyle: PageBlockDefinitionMultiRichTextPropertyStyle.optional()
|
|
1979
1989
|
});
|
|
1980
|
-
var PageBlockDefinitionTextOptions =
|
|
1981
|
-
placeholder:
|
|
1982
|
-
defaultValue:
|
|
1990
|
+
var PageBlockDefinitionTextOptions = z90.object({
|
|
1991
|
+
placeholder: z90.string().optional(),
|
|
1992
|
+
defaultValue: z90.string().optional(),
|
|
1983
1993
|
textStyle: PageBlockDefinitionTextPropertyStyle.optional(),
|
|
1984
1994
|
color: PageBlockDefinitionTextPropertyColor.optional()
|
|
1985
1995
|
});
|
|
1986
|
-
var PageBlockDefinitionSelectOptions =
|
|
1996
|
+
var PageBlockDefinitionSelectOptions = z90.object({
|
|
1987
1997
|
singleSelectStyle: PageBlockDefinitionSingleSelectPropertyStyle.optional(),
|
|
1988
|
-
defaultChoice:
|
|
1989
|
-
choices:
|
|
1998
|
+
defaultChoice: z90.string(),
|
|
1999
|
+
choices: z90.array(PageBlockDefinitionSelectChoice)
|
|
1990
2000
|
});
|
|
1991
|
-
var PageBlockDefinitionImageOptions =
|
|
2001
|
+
var PageBlockDefinitionImageOptions = z90.object({
|
|
1992
2002
|
width: PageBlockDefinitionImageWidth.optional(),
|
|
1993
2003
|
aspectRatio: PageBlockDefinitionImageAspectRatio.optional(),
|
|
1994
|
-
allowCaption:
|
|
1995
|
-
recommendation:
|
|
2004
|
+
allowCaption: z90.boolean().optional(),
|
|
2005
|
+
recommendation: z90.string().optional()
|
|
1996
2006
|
});
|
|
1997
|
-
var PageBlockDefinitionBooleanOptions =
|
|
1998
|
-
defaultvalue:
|
|
2007
|
+
var PageBlockDefinitionBooleanOptions = z90.object({
|
|
2008
|
+
defaultvalue: z90.boolean().optional(),
|
|
1999
2009
|
booleanStyle: PageBlockDefinitionBooleanPropertyStyle.optional()
|
|
2000
2010
|
});
|
|
2001
|
-
var PageBlockDefinitionNumberOptions =
|
|
2002
|
-
defaultValue:
|
|
2003
|
-
min:
|
|
2004
|
-
max:
|
|
2005
|
-
step:
|
|
2006
|
-
placeholder:
|
|
2011
|
+
var PageBlockDefinitionNumberOptions = z90.object({
|
|
2012
|
+
defaultValue: z90.number(),
|
|
2013
|
+
min: z90.number().optional(),
|
|
2014
|
+
max: z90.number().optional(),
|
|
2015
|
+
step: z90.number().optional(),
|
|
2016
|
+
placeholder: z90.string().optional()
|
|
2007
2017
|
});
|
|
2008
|
-
var PageBlockDefinitionComponentOptions =
|
|
2009
|
-
renderLayoutAs:
|
|
2010
|
-
allowPropertySelection:
|
|
2018
|
+
var PageBlockDefinitionComponentOptions = z90.object({
|
|
2019
|
+
renderLayoutAs: z90.enum(["List", "Table"]).optional(),
|
|
2020
|
+
allowPropertySelection: z90.boolean().optional()
|
|
2011
2021
|
});
|
|
2012
|
-
var PageBlockDefinitionProperty =
|
|
2013
|
-
id:
|
|
2014
|
-
name:
|
|
2022
|
+
var PageBlockDefinitionProperty = z90.object({
|
|
2023
|
+
id: z90.string(),
|
|
2024
|
+
name: z90.string(),
|
|
2015
2025
|
type: PageBlockDefinitionPropertyType,
|
|
2016
|
-
description:
|
|
2026
|
+
description: z90.string().optional(),
|
|
2017
2027
|
// TODO Docs
|
|
2018
2028
|
options: PageBlockDefinitionUntypedPropertyOptions.optional(),
|
|
2019
|
-
variantOptions:
|
|
2029
|
+
variantOptions: z90.record(PageBlockDefinitionUntypedPropertyOptions).optional()
|
|
2020
2030
|
});
|
|
2021
|
-
var PageBlockDefinitionItem =
|
|
2022
|
-
properties:
|
|
2031
|
+
var PageBlockDefinitionItem = z90.object({
|
|
2032
|
+
properties: z90.array(PageBlockDefinitionProperty),
|
|
2023
2033
|
appearance: PageBlockDefinitionAppearance.optional(),
|
|
2024
|
-
variants:
|
|
2025
|
-
defaultVariantKey:
|
|
2034
|
+
variants: z90.array(PageBlockDefinitionVariant),
|
|
2035
|
+
defaultVariantKey: z90.string()
|
|
2026
2036
|
});
|
|
2027
|
-
var PageBlockCategory =
|
|
2037
|
+
var PageBlockCategory = z91.enum([
|
|
2028
2038
|
"Text",
|
|
2029
2039
|
"Layout",
|
|
2030
2040
|
"Media",
|
|
@@ -2038,55 +2048,41 @@ var PageBlockCategory = z90.enum([
|
|
|
2038
2048
|
"Data",
|
|
2039
2049
|
"Other"
|
|
2040
2050
|
]);
|
|
2041
|
-
var PageBlockBehaviorDataType =
|
|
2042
|
-
var PageBlockBehaviorSelectionType =
|
|
2043
|
-
var PageBlockDefinitionBehavior =
|
|
2051
|
+
var PageBlockBehaviorDataType = z91.enum(["Item", "Token", "Asset", "Component", "FigmaNode"]);
|
|
2052
|
+
var PageBlockBehaviorSelectionType = z91.enum(["Entity", "Group", "EntityAndGroup"]);
|
|
2053
|
+
var PageBlockDefinitionBehavior = z91.object({
|
|
2044
2054
|
dataType: PageBlockBehaviorDataType,
|
|
2045
|
-
items:
|
|
2046
|
-
numberOfItems:
|
|
2047
|
-
allowLinks:
|
|
2055
|
+
items: z91.object({
|
|
2056
|
+
numberOfItems: z91.number(),
|
|
2057
|
+
allowLinks: z91.boolean()
|
|
2048
2058
|
}).optional(),
|
|
2049
|
-
entities:
|
|
2059
|
+
entities: z91.object({
|
|
2050
2060
|
selectionType: PageBlockBehaviorSelectionType,
|
|
2051
|
-
maxSelected:
|
|
2061
|
+
maxSelected: z91.number()
|
|
2052
2062
|
}).optional()
|
|
2053
2063
|
});
|
|
2054
|
-
var PageBlockDefinitionOnboarding =
|
|
2055
|
-
helpText:
|
|
2056
|
-
documentationLink:
|
|
2064
|
+
var PageBlockDefinitionOnboarding = z91.object({
|
|
2065
|
+
helpText: z91.string(),
|
|
2066
|
+
documentationLink: z91.string().optional()
|
|
2057
2067
|
});
|
|
2058
|
-
var PageBlockDefinition =
|
|
2059
|
-
id:
|
|
2060
|
-
name:
|
|
2061
|
-
description:
|
|
2068
|
+
var PageBlockDefinition = z91.object({
|
|
2069
|
+
id: z91.string(),
|
|
2070
|
+
name: z91.string(),
|
|
2071
|
+
description: z91.string(),
|
|
2062
2072
|
category: PageBlockCategory,
|
|
2063
2073
|
icon: AssetValue.optional(),
|
|
2064
|
-
documentationLink:
|
|
2065
|
-
searchKeywords:
|
|
2074
|
+
documentationLink: z91.string().optional(),
|
|
2075
|
+
searchKeywords: z91.array(z91.string()).optional(),
|
|
2066
2076
|
item: PageBlockDefinitionItem,
|
|
2067
2077
|
behavior: PageBlockDefinitionBehavior,
|
|
2068
|
-
editorOptions:
|
|
2078
|
+
editorOptions: z91.object({
|
|
2069
2079
|
onboarding: PageBlockDefinitionOnboarding.optional()
|
|
2070
2080
|
}),
|
|
2071
2081
|
appearance: PageBlockDefinitionAppearance.optional()
|
|
2072
2082
|
});
|
|
2073
|
-
var DocumentationPageGroup =
|
|
2074
|
-
type:
|
|
2075
|
-
childType:
|
|
2076
|
-
id: z91.string(),
|
|
2077
|
-
persistentId: z91.string(),
|
|
2078
|
-
shortPersistentId: z91.string(),
|
|
2079
|
-
designSystemVersionId: z91.string(),
|
|
2080
|
-
parentPersistentId: z91.string().nullish(),
|
|
2081
|
-
sortOrder: z91.number(),
|
|
2082
|
-
title: z91.string(),
|
|
2083
|
-
slug: z91.string(),
|
|
2084
|
-
userSlug: z91.string().nullish(),
|
|
2085
|
-
createdAt: z91.coerce.date(),
|
|
2086
|
-
updatedAt: z91.coerce.date()
|
|
2087
|
-
});
|
|
2088
|
-
var DocumentationPage = z92.object({
|
|
2089
|
-
type: z92.literal("DocumentationPage"),
|
|
2083
|
+
var DocumentationPageGroup = z92.object({
|
|
2084
|
+
type: z92.literal("ElementGroup"),
|
|
2085
|
+
childType: z92.literal("DocumentationPage"),
|
|
2090
2086
|
id: z92.string(),
|
|
2091
2087
|
persistentId: z92.string(),
|
|
2092
2088
|
shortPersistentId: z92.string(),
|
|
@@ -2099,158 +2095,177 @@ var DocumentationPage = z92.object({
|
|
|
2099
2095
|
createdAt: z92.coerce.date(),
|
|
2100
2096
|
updatedAt: z92.coerce.date()
|
|
2101
2097
|
});
|
|
2102
|
-
var
|
|
2098
|
+
var DocumentationPage = z93.object({
|
|
2099
|
+
type: z93.literal("DocumentationPage"),
|
|
2100
|
+
id: z93.string(),
|
|
2101
|
+
persistentId: z93.string(),
|
|
2102
|
+
shortPersistentId: z93.string(),
|
|
2103
|
+
designSystemVersionId: z93.string(),
|
|
2104
|
+
parentPersistentId: z93.string().nullish(),
|
|
2105
|
+
sortOrder: z93.number(),
|
|
2106
|
+
title: z93.string(),
|
|
2107
|
+
slug: z93.string(),
|
|
2108
|
+
userSlug: z93.string().nullish(),
|
|
2109
|
+
createdAt: z93.coerce.date(),
|
|
2110
|
+
updatedAt: z93.coerce.date()
|
|
2111
|
+
});
|
|
2112
|
+
var NpmRegistryAuthType = z94.enum(["Basic", "Bearer", "None", "Custom"]);
|
|
2103
2113
|
var registryTypesWithoutAzure = ["NPMJS", "GitHub", "Artifactory", "Custom"];
|
|
2104
|
-
var NpmRegistryType =
|
|
2105
|
-
var NpmRegistryTypeWithoutAzure =
|
|
2106
|
-
var NpmRegistryBasicAuthConfig =
|
|
2114
|
+
var NpmRegistryType = z94.enum([...registryTypesWithoutAzure, "AzureDevOps"]);
|
|
2115
|
+
var NpmRegistryTypeWithoutAzure = z94.enum(registryTypesWithoutAzure);
|
|
2116
|
+
var NpmRegistryBasicAuthConfig = z94.object({
|
|
2107
2117
|
registryType: NpmRegistryType,
|
|
2108
|
-
authType:
|
|
2109
|
-
username:
|
|
2110
|
-
password:
|
|
2118
|
+
authType: z94.literal(NpmRegistryAuthType.Enum.Basic),
|
|
2119
|
+
username: z94.string(),
|
|
2120
|
+
password: z94.string()
|
|
2111
2121
|
});
|
|
2112
|
-
var NpmRegistryBearerAuthConfig =
|
|
2122
|
+
var NpmRegistryBearerAuthConfig = z94.object({
|
|
2113
2123
|
registryType: NpmRegistryTypeWithoutAzure,
|
|
2114
|
-
authType:
|
|
2115
|
-
accessToken:
|
|
2124
|
+
authType: z94.literal(NpmRegistryAuthType.Enum.Bearer),
|
|
2125
|
+
accessToken: z94.string()
|
|
2116
2126
|
});
|
|
2117
|
-
var NpmRegistryNoAuthConfig =
|
|
2127
|
+
var NpmRegistryNoAuthConfig = z94.object({
|
|
2118
2128
|
registryType: NpmRegistryTypeWithoutAzure,
|
|
2119
|
-
authType:
|
|
2129
|
+
authType: z94.literal(NpmRegistryAuthType.Enum.None)
|
|
2120
2130
|
});
|
|
2121
|
-
var NpmRegistrCustomAuthConfig =
|
|
2131
|
+
var NpmRegistrCustomAuthConfig = z94.object({
|
|
2122
2132
|
registryType: NpmRegistryTypeWithoutAzure,
|
|
2123
|
-
authType:
|
|
2124
|
-
authHeaderName:
|
|
2125
|
-
authHeaderValue:
|
|
2133
|
+
authType: z94.literal(NpmRegistryAuthType.Enum.Custom),
|
|
2134
|
+
authHeaderName: z94.string(),
|
|
2135
|
+
authHeaderValue: z94.string()
|
|
2126
2136
|
});
|
|
2127
|
-
var NpmRegistryAuthConfig =
|
|
2137
|
+
var NpmRegistryAuthConfig = z94.discriminatedUnion("authType", [
|
|
2128
2138
|
NpmRegistryBasicAuthConfig,
|
|
2129
2139
|
NpmRegistryBearerAuthConfig,
|
|
2130
2140
|
NpmRegistryNoAuthConfig,
|
|
2131
2141
|
NpmRegistrCustomAuthConfig
|
|
2132
2142
|
]);
|
|
2133
|
-
var NpmRegistryConfigBase =
|
|
2134
|
-
enabledScopes:
|
|
2135
|
-
customRegistryUrl:
|
|
2136
|
-
bypassProxy:
|
|
2137
|
-
npmProxyRegistryConfigId:
|
|
2138
|
-
npmProxyVersion:
|
|
2143
|
+
var NpmRegistryConfigBase = z94.object({
|
|
2144
|
+
enabledScopes: z94.array(z94.string()),
|
|
2145
|
+
customRegistryUrl: z94.string().optional(),
|
|
2146
|
+
bypassProxy: z94.boolean().default(false),
|
|
2147
|
+
npmProxyRegistryConfigId: z94.string().optional(),
|
|
2148
|
+
npmProxyVersion: z94.number().optional()
|
|
2139
2149
|
});
|
|
2140
2150
|
var NpmRegistryConfig = NpmRegistryConfigBase.and(NpmRegistryAuthConfig);
|
|
2141
|
-
var SsoProvider =
|
|
2142
|
-
providerId:
|
|
2143
|
-
defaultAutoInviteValue:
|
|
2144
|
-
autoInviteDomains:
|
|
2145
|
-
skipDocsSupernovaLogin:
|
|
2146
|
-
areInvitesDisabled:
|
|
2147
|
-
isTestMode:
|
|
2148
|
-
emailDomains:
|
|
2149
|
-
metadataXml:
|
|
2150
|
-
});
|
|
2151
|
-
var WorkspaceRoleSchema =
|
|
2151
|
+
var SsoProvider = z95.object({
|
|
2152
|
+
providerId: z95.string(),
|
|
2153
|
+
defaultAutoInviteValue: z95.boolean(),
|
|
2154
|
+
autoInviteDomains: z95.record(z95.string(), z95.boolean()),
|
|
2155
|
+
skipDocsSupernovaLogin: z95.boolean(),
|
|
2156
|
+
areInvitesDisabled: z95.boolean(),
|
|
2157
|
+
isTestMode: z95.boolean(),
|
|
2158
|
+
emailDomains: z95.array(z95.string()),
|
|
2159
|
+
metadataXml: z95.string().nullish()
|
|
2160
|
+
});
|
|
2161
|
+
var WorkspaceRoleSchema = z96.enum(["Owner", "Admin", "Creator", "Viewer", "Billing", "Guest"]);
|
|
2152
2162
|
var WorkspaceRole = WorkspaceRoleSchema.enum;
|
|
2153
2163
|
var MAX_MEMBERS_COUNT = 100;
|
|
2154
|
-
var UserInvite =
|
|
2155
|
-
email:
|
|
2164
|
+
var UserInvite = z97.object({
|
|
2165
|
+
email: z97.string().email().trim().transform((value) => value.toLowerCase()),
|
|
2156
2166
|
role: WorkspaceRoleSchema
|
|
2157
2167
|
});
|
|
2158
|
-
var UserInvites =
|
|
2159
|
-
var WorkspaceIpWhitelistEntry =
|
|
2160
|
-
isEnabled:
|
|
2161
|
-
name:
|
|
2162
|
-
range:
|
|
2168
|
+
var UserInvites = z97.array(UserInvite).max(MAX_MEMBERS_COUNT);
|
|
2169
|
+
var WorkspaceIpWhitelistEntry = z98.object({
|
|
2170
|
+
isEnabled: z98.boolean(),
|
|
2171
|
+
name: z98.string(),
|
|
2172
|
+
range: z98.string()
|
|
2163
2173
|
});
|
|
2164
|
-
var WorkspaceIpSettings =
|
|
2165
|
-
isEnabledForCloud:
|
|
2166
|
-
isEnabledForDocs:
|
|
2167
|
-
entries:
|
|
2174
|
+
var WorkspaceIpSettings = z98.object({
|
|
2175
|
+
isEnabledForCloud: z98.boolean(),
|
|
2176
|
+
isEnabledForDocs: z98.boolean(),
|
|
2177
|
+
entries: z98.array(WorkspaceIpWhitelistEntry)
|
|
2168
2178
|
}).nullish();
|
|
2169
|
-
var WorkspaceProfile =
|
|
2170
|
-
name:
|
|
2171
|
-
handle:
|
|
2172
|
-
color:
|
|
2173
|
-
avatar:
|
|
2179
|
+
var WorkspaceProfile = z98.object({
|
|
2180
|
+
name: z98.string(),
|
|
2181
|
+
handle: z98.string(),
|
|
2182
|
+
color: z98.string(),
|
|
2183
|
+
avatar: z98.string().optional(),
|
|
2174
2184
|
billingDetails: BillingDetails.optional()
|
|
2175
2185
|
});
|
|
2176
|
-
var Workspace =
|
|
2177
|
-
id:
|
|
2186
|
+
var Workspace = z98.object({
|
|
2187
|
+
id: z98.string(),
|
|
2178
2188
|
profile: WorkspaceProfile,
|
|
2179
2189
|
subscription: Subscription,
|
|
2180
2190
|
ipWhitelist: WorkspaceIpSettings,
|
|
2181
2191
|
sso: SsoProvider.nullish(),
|
|
2182
|
-
npmRegistrySettings:
|
|
2183
|
-
designSystems:
|
|
2192
|
+
npmRegistrySettings: z98.unknown().optional(),
|
|
2193
|
+
designSystems: z98.array(DesignSystem).nullish()
|
|
2184
2194
|
});
|
|
2185
|
-
var WorkspaceWithDesignSystems =
|
|
2195
|
+
var WorkspaceWithDesignSystems = z98.object({
|
|
2186
2196
|
workspace: Workspace,
|
|
2187
|
-
designSystems:
|
|
2197
|
+
designSystems: z98.array(DesignSystem)
|
|
2188
2198
|
});
|
|
2189
|
-
var WorkspaceContext =
|
|
2190
|
-
workspaceId:
|
|
2199
|
+
var WorkspaceContext = z99.object({
|
|
2200
|
+
workspaceId: z99.string(),
|
|
2191
2201
|
product: ProductCodeSchema,
|
|
2192
2202
|
ipWhitelist: WorkspaceIpSettings,
|
|
2193
|
-
publicDesignSystem:
|
|
2203
|
+
publicDesignSystem: z99.boolean().optional()
|
|
2194
2204
|
});
|
|
2195
2205
|
var slugRegex = /^[a-z0-9][a-z0-9-]*[a-z0-9]$/;
|
|
2196
2206
|
var WORKSPACE_NAME_MIN_LENGTH = 2;
|
|
2197
2207
|
var WORKSPACE_NAME_MAX_LENGTH = 64;
|
|
2198
2208
|
var HANDLE_MIN_LENGTH = 2;
|
|
2199
2209
|
var HANDLE_MAX_LENGTH = 64;
|
|
2200
|
-
var CreateWorkspaceInput =
|
|
2201
|
-
name:
|
|
2210
|
+
var CreateWorkspaceInput = z100.object({
|
|
2211
|
+
name: z100.string().min(WORKSPACE_NAME_MIN_LENGTH).max(WORKSPACE_NAME_MAX_LENGTH).trim(),
|
|
2202
2212
|
product: ProductCodeSchema,
|
|
2203
|
-
priceId:
|
|
2204
|
-
billingEmail:
|
|
2205
|
-
handle:
|
|
2213
|
+
priceId: z100.string(),
|
|
2214
|
+
billingEmail: z100.string().email().optional(),
|
|
2215
|
+
handle: z100.string().regex(slugRegex).min(HANDLE_MIN_LENGTH).max(HANDLE_MAX_LENGTH).refine((value) => value?.length > 0).optional(),
|
|
2206
2216
|
invites: UserInvites.optional(),
|
|
2207
|
-
promoCode:
|
|
2208
|
-
|
|
2209
|
-
|
|
2210
|
-
|
|
2211
|
-
|
|
2212
|
-
|
|
2213
|
-
|
|
2214
|
-
|
|
2215
|
-
workspaceId: z100.string(),
|
|
2216
|
-
invitedBy: z100.string()
|
|
2217
|
-
});
|
|
2218
|
-
var WorkspaceMembership = z101.object({
|
|
2217
|
+
promoCode: z100.string().optional(),
|
|
2218
|
+
status: InternalStatusSchema.optional(),
|
|
2219
|
+
planInterval: BillingIntervalSchema.optional(),
|
|
2220
|
+
seats: z100.number().optional(),
|
|
2221
|
+
seatLimit: z100.number().optional(),
|
|
2222
|
+
card: CardSchema.optional()
|
|
2223
|
+
});
|
|
2224
|
+
var WorkspaceInvitation = z101.object({
|
|
2219
2225
|
id: z101.string(),
|
|
2220
|
-
|
|
2226
|
+
email: z101.string().email(),
|
|
2227
|
+
createdAt: z101.coerce.date(),
|
|
2228
|
+
resentAt: z101.coerce.date().nullish(),
|
|
2229
|
+
role: z101.nativeEnum(WorkspaceRole),
|
|
2221
2230
|
workspaceId: z101.string(),
|
|
2222
|
-
|
|
2231
|
+
invitedBy: z101.string()
|
|
2223
2232
|
});
|
|
2224
|
-
var
|
|
2225
|
-
|
|
2226
|
-
|
|
2227
|
-
|
|
2228
|
-
|
|
2233
|
+
var WorkspaceMembership = z102.object({
|
|
2234
|
+
id: z102.string(),
|
|
2235
|
+
userId: z102.string(),
|
|
2236
|
+
workspaceId: z102.string(),
|
|
2237
|
+
workspaceRole: z102.nativeEnum(WorkspaceRole)
|
|
2238
|
+
});
|
|
2239
|
+
var UpdateMembershipRolesInput = z102.object({
|
|
2240
|
+
members: z102.array(
|
|
2241
|
+
z102.object({
|
|
2242
|
+
userId: z102.string(),
|
|
2243
|
+
role: z102.nativeEnum(WorkspaceRole)
|
|
2229
2244
|
})
|
|
2230
2245
|
)
|
|
2231
2246
|
});
|
|
2232
|
-
var DesignSystemSwitcher =
|
|
2233
|
-
isEnabled:
|
|
2234
|
-
designSystemIds:
|
|
2247
|
+
var DesignSystemSwitcher = z103.object({
|
|
2248
|
+
isEnabled: z103.boolean(),
|
|
2249
|
+
designSystemIds: z103.array(z103.string())
|
|
2235
2250
|
});
|
|
2236
|
-
var DesignSystem =
|
|
2237
|
-
id:
|
|
2238
|
-
workspaceId:
|
|
2239
|
-
name:
|
|
2240
|
-
description:
|
|
2241
|
-
docExporterId: nullishToOptional(
|
|
2242
|
-
docSlug:
|
|
2243
|
-
docUserSlug: nullishToOptional(
|
|
2244
|
-
docSlugDeprecated:
|
|
2245
|
-
isPublic:
|
|
2246
|
-
isMultibrand:
|
|
2247
|
-
docViewUrl: nullishToOptional(
|
|
2248
|
-
basePrefixes:
|
|
2251
|
+
var DesignSystem = z103.object({
|
|
2252
|
+
id: z103.string(),
|
|
2253
|
+
workspaceId: z103.string(),
|
|
2254
|
+
name: z103.string(),
|
|
2255
|
+
description: z103.string(),
|
|
2256
|
+
docExporterId: nullishToOptional(z103.string()),
|
|
2257
|
+
docSlug: z103.string(),
|
|
2258
|
+
docUserSlug: nullishToOptional(z103.string()),
|
|
2259
|
+
docSlugDeprecated: z103.string(),
|
|
2260
|
+
isPublic: z103.boolean(),
|
|
2261
|
+
isMultibrand: z103.boolean(),
|
|
2262
|
+
docViewUrl: nullishToOptional(z103.string()),
|
|
2263
|
+
basePrefixes: z103.array(z103.string()),
|
|
2249
2264
|
designSystemSwitcher: nullishToOptional(DesignSystemSwitcher),
|
|
2250
|
-
createdAt:
|
|
2251
|
-
updatedAt:
|
|
2265
|
+
createdAt: z103.coerce.date(),
|
|
2266
|
+
updatedAt: z103.coerce.date()
|
|
2252
2267
|
});
|
|
2253
|
-
var DesignSystemWithWorkspace =
|
|
2268
|
+
var DesignSystemWithWorkspace = z103.object({
|
|
2254
2269
|
designSystem: DesignSystem,
|
|
2255
2270
|
workspace: Workspace
|
|
2256
2271
|
});
|
|
@@ -2258,81 +2273,81 @@ var DS_NAME_MIN_LENGTH = 2;
|
|
|
2258
2273
|
var DS_NAME_MAX_LENGTH = 64;
|
|
2259
2274
|
var DS_DESC_MIN_LENGTH = 2;
|
|
2260
2275
|
var DS_DESC_MAX_LENGTH = 64;
|
|
2261
|
-
var DesignSystemCreateInputMetadata =
|
|
2262
|
-
name:
|
|
2263
|
-
description:
|
|
2276
|
+
var DesignSystemCreateInputMetadata = z104.object({
|
|
2277
|
+
name: z104.string().min(DS_NAME_MIN_LENGTH).max(DS_NAME_MAX_LENGTH).trim(),
|
|
2278
|
+
description: z104.string().min(DS_DESC_MIN_LENGTH).max(DS_DESC_MAX_LENGTH).trim()
|
|
2264
2279
|
});
|
|
2265
|
-
var DesignSystemCreateInput =
|
|
2280
|
+
var DesignSystemCreateInput = z104.object({
|
|
2266
2281
|
meta: DesignSystemCreateInputMetadata,
|
|
2267
|
-
workspaceId:
|
|
2268
|
-
isPublic:
|
|
2269
|
-
basePrefixes:
|
|
2270
|
-
docUserSlug:
|
|
2271
|
-
source:
|
|
2282
|
+
workspaceId: z104.string(),
|
|
2283
|
+
isPublic: z104.boolean().optional(),
|
|
2284
|
+
basePrefixes: z104.array(z104.string()).optional(),
|
|
2285
|
+
docUserSlug: z104.string().nullish().optional(),
|
|
2286
|
+
source: z104.array(z104.string()).optional()
|
|
2272
2287
|
});
|
|
2273
2288
|
var DS_NAME_MIN_LENGTH2 = 2;
|
|
2274
2289
|
var DS_NAME_MAX_LENGTH2 = 64;
|
|
2275
2290
|
var DS_DESC_MIN_LENGTH2 = 2;
|
|
2276
2291
|
var DS_DESC_MAX_LENGTH2 = 64;
|
|
2277
|
-
var DesignSystemUpdateInputMetadata =
|
|
2278
|
-
name:
|
|
2279
|
-
description:
|
|
2292
|
+
var DesignSystemUpdateInputMetadata = z105.object({
|
|
2293
|
+
name: z105.string().min(DS_NAME_MIN_LENGTH2).max(DS_NAME_MAX_LENGTH2).trim().optional(),
|
|
2294
|
+
description: z105.string().min(DS_DESC_MIN_LENGTH2).max(DS_DESC_MAX_LENGTH2).trim().optional()
|
|
2280
2295
|
});
|
|
2281
|
-
var DesignSystemUpdateInput =
|
|
2296
|
+
var DesignSystemUpdateInput = z105.object({
|
|
2282
2297
|
meta: DesignSystemUpdateInputMetadata.optional(),
|
|
2283
|
-
workspaceId:
|
|
2284
|
-
isPublic:
|
|
2285
|
-
basePrefixes:
|
|
2286
|
-
docUserSlug:
|
|
2287
|
-
source:
|
|
2288
|
-
name:
|
|
2289
|
-
description:
|
|
2290
|
-
docExporterId:
|
|
2298
|
+
workspaceId: z105.string().optional(),
|
|
2299
|
+
isPublic: z105.boolean().optional(),
|
|
2300
|
+
basePrefixes: z105.array(z105.string()).optional(),
|
|
2301
|
+
docUserSlug: z105.string().nullish().optional(),
|
|
2302
|
+
source: z105.array(z105.string()).optional(),
|
|
2303
|
+
name: z105.string().min(DS_NAME_MIN_LENGTH2).max(DS_NAME_MAX_LENGTH2).trim().optional(),
|
|
2304
|
+
description: z105.string().min(DS_DESC_MIN_LENGTH2).max(DS_DESC_MAX_LENGTH2).trim().optional(),
|
|
2305
|
+
docExporterId: z105.string().optional()
|
|
2291
2306
|
});
|
|
2292
2307
|
var publishedDocEnvironments = ["Live", "Preview"];
|
|
2293
|
-
var PublishedDocEnvironment =
|
|
2294
|
-
var PublishedDocsChecksums =
|
|
2295
|
-
var PublishedDocRoutingVersion =
|
|
2296
|
-
var PublishedDoc =
|
|
2297
|
-
id:
|
|
2298
|
-
designSystemVersionId:
|
|
2299
|
-
createdAt:
|
|
2300
|
-
updatedAt:
|
|
2301
|
-
lastPublishedAt:
|
|
2302
|
-
isDefault:
|
|
2303
|
-
isPublic:
|
|
2308
|
+
var PublishedDocEnvironment = z106.enum(publishedDocEnvironments);
|
|
2309
|
+
var PublishedDocsChecksums = z106.record(z106.string());
|
|
2310
|
+
var PublishedDocRoutingVersion = z106.enum(["1", "2"]);
|
|
2311
|
+
var PublishedDoc = z106.object({
|
|
2312
|
+
id: z106.string(),
|
|
2313
|
+
designSystemVersionId: z106.string(),
|
|
2314
|
+
createdAt: z106.coerce.date(),
|
|
2315
|
+
updatedAt: z106.coerce.date(),
|
|
2316
|
+
lastPublishedAt: z106.coerce.date(),
|
|
2317
|
+
isDefault: z106.boolean(),
|
|
2318
|
+
isPublic: z106.boolean(),
|
|
2304
2319
|
environment: PublishedDocEnvironment,
|
|
2305
2320
|
checksums: PublishedDocsChecksums,
|
|
2306
|
-
storagePath:
|
|
2307
|
-
wasMigrated:
|
|
2321
|
+
storagePath: z106.string(),
|
|
2322
|
+
wasMigrated: z106.boolean(),
|
|
2308
2323
|
routingVersion: PublishedDocRoutingVersion,
|
|
2309
|
-
usesLocalizations:
|
|
2310
|
-
wasPublishedWithLocalizations:
|
|
2311
|
-
});
|
|
2312
|
-
var ExporterJobDestination =
|
|
2313
|
-
var ExporterJobStatus =
|
|
2314
|
-
var ExporterJobLogEntryType =
|
|
2315
|
-
var ExporterJobLogEntry =
|
|
2316
|
-
id:
|
|
2317
|
-
time:
|
|
2324
|
+
usesLocalizations: z106.boolean(),
|
|
2325
|
+
wasPublishedWithLocalizations: z106.boolean()
|
|
2326
|
+
});
|
|
2327
|
+
var ExporterJobDestination = z107.enum(["s3", "webhookUrl", "github", "documentation", "azure", "gitlab"]);
|
|
2328
|
+
var ExporterJobStatus = z107.enum(["InProgress", "Success", "Failed", "Timeout"]);
|
|
2329
|
+
var ExporterJobLogEntryType = z107.enum(["success", "info", "warning", "error", "user"]);
|
|
2330
|
+
var ExporterJobLogEntry = z107.object({
|
|
2331
|
+
id: z107.string().optional(),
|
|
2332
|
+
time: z107.coerce.date(),
|
|
2318
2333
|
type: ExporterJobLogEntryType,
|
|
2319
|
-
message:
|
|
2334
|
+
message: z107.string()
|
|
2320
2335
|
});
|
|
2321
|
-
var ExporterJobResultPullRequestDestination =
|
|
2322
|
-
pullRequestUrl:
|
|
2336
|
+
var ExporterJobResultPullRequestDestination = z107.object({
|
|
2337
|
+
pullRequestUrl: z107.string()
|
|
2323
2338
|
});
|
|
2324
|
-
var ExporterJobResultS3Destination =
|
|
2325
|
-
bucket:
|
|
2326
|
-
urlPrefix:
|
|
2327
|
-
path:
|
|
2328
|
-
files:
|
|
2339
|
+
var ExporterJobResultS3Destination = z107.object({
|
|
2340
|
+
bucket: z107.string(),
|
|
2341
|
+
urlPrefix: z107.string().optional(),
|
|
2342
|
+
path: z107.string(),
|
|
2343
|
+
files: z107.array(z107.string())
|
|
2329
2344
|
});
|
|
2330
|
-
var ExporterJobResultDocsDestination =
|
|
2331
|
-
url:
|
|
2345
|
+
var ExporterJobResultDocsDestination = z107.object({
|
|
2346
|
+
url: z107.string()
|
|
2332
2347
|
});
|
|
2333
|
-
var ExporterJobResult =
|
|
2334
|
-
error:
|
|
2335
|
-
logs:
|
|
2348
|
+
var ExporterJobResult = z107.object({
|
|
2349
|
+
error: z107.string().optional(),
|
|
2350
|
+
logs: z107.array(ExporterJobLogEntry).optional(),
|
|
2336
2351
|
s3: ExporterJobResultS3Destination.optional(),
|
|
2337
2352
|
github: ExporterJobResultPullRequestDestination.optional(),
|
|
2338
2353
|
azure: ExporterJobResultPullRequestDestination.optional(),
|
|
@@ -2340,68 +2355,68 @@ var ExporterJobResult = z106.object({
|
|
|
2340
2355
|
bitbucket: ExporterJobResultPullRequestDestination.optional(),
|
|
2341
2356
|
sndocs: ExporterJobResultDocsDestination.optional()
|
|
2342
2357
|
});
|
|
2343
|
-
var ExporterDestinationSnDocs =
|
|
2358
|
+
var ExporterDestinationSnDocs = z107.object({
|
|
2344
2359
|
environment: PublishedDocEnvironment
|
|
2345
2360
|
});
|
|
2346
|
-
var ExporterDestinationS3 =
|
|
2347
|
-
var ExporterDestinationGithub =
|
|
2348
|
-
connectionId:
|
|
2349
|
-
url:
|
|
2350
|
-
branch:
|
|
2351
|
-
relativePath:
|
|
2361
|
+
var ExporterDestinationS3 = z107.object({});
|
|
2362
|
+
var ExporterDestinationGithub = z107.object({
|
|
2363
|
+
connectionId: z107.string(),
|
|
2364
|
+
url: z107.string(),
|
|
2365
|
+
branch: z107.string(),
|
|
2366
|
+
relativePath: z107.string(),
|
|
2352
2367
|
// +
|
|
2353
|
-
userId:
|
|
2354
|
-
});
|
|
2355
|
-
var ExporterDestinationAzure =
|
|
2356
|
-
connectionId:
|
|
2357
|
-
organizationId:
|
|
2358
|
-
projectId:
|
|
2359
|
-
repositoryId:
|
|
2360
|
-
branch:
|
|
2361
|
-
relativePath:
|
|
2368
|
+
userId: z107.coerce.string()
|
|
2369
|
+
});
|
|
2370
|
+
var ExporterDestinationAzure = z107.object({
|
|
2371
|
+
connectionId: z107.string(),
|
|
2372
|
+
organizationId: z107.string(),
|
|
2373
|
+
projectId: z107.string(),
|
|
2374
|
+
repositoryId: z107.string(),
|
|
2375
|
+
branch: z107.string(),
|
|
2376
|
+
relativePath: z107.string(),
|
|
2362
2377
|
// +
|
|
2363
|
-
userId:
|
|
2364
|
-
url:
|
|
2365
|
-
});
|
|
2366
|
-
var ExporterDestinationGitlab =
|
|
2367
|
-
connectionId:
|
|
2368
|
-
projectId:
|
|
2369
|
-
branch:
|
|
2370
|
-
relativePath:
|
|
2378
|
+
userId: z107.coerce.string(),
|
|
2379
|
+
url: z107.string()
|
|
2380
|
+
});
|
|
2381
|
+
var ExporterDestinationGitlab = z107.object({
|
|
2382
|
+
connectionId: z107.string(),
|
|
2383
|
+
projectId: z107.string(),
|
|
2384
|
+
branch: z107.string(),
|
|
2385
|
+
relativePath: z107.string(),
|
|
2371
2386
|
// +
|
|
2372
|
-
userId:
|
|
2373
|
-
url:
|
|
2387
|
+
userId: z107.coerce.string(),
|
|
2388
|
+
url: z107.string()
|
|
2374
2389
|
});
|
|
2375
2390
|
var BITBUCKET_SLUG = /^[-a-zA-Z0-9~]*$/;
|
|
2376
2391
|
var BITBUCKET_MAX_LENGTH = 64;
|
|
2377
|
-
var ExporterDestinationBitbucket =
|
|
2378
|
-
connectionId:
|
|
2379
|
-
workspaceSlug:
|
|
2380
|
-
projectKey:
|
|
2381
|
-
repoSlug:
|
|
2382
|
-
branch:
|
|
2383
|
-
relativePath:
|
|
2392
|
+
var ExporterDestinationBitbucket = z107.object({
|
|
2393
|
+
connectionId: z107.string(),
|
|
2394
|
+
workspaceSlug: z107.string().max(BITBUCKET_MAX_LENGTH).regex(BITBUCKET_SLUG),
|
|
2395
|
+
projectKey: z107.string().max(BITBUCKET_MAX_LENGTH).regex(BITBUCKET_SLUG),
|
|
2396
|
+
repoSlug: z107.string().max(BITBUCKET_MAX_LENGTH).regex(BITBUCKET_SLUG),
|
|
2397
|
+
branch: z107.string(),
|
|
2398
|
+
relativePath: z107.string(),
|
|
2384
2399
|
// +
|
|
2385
|
-
userId:
|
|
2386
|
-
url:
|
|
2387
|
-
});
|
|
2388
|
-
var ExporterJob =
|
|
2389
|
-
id:
|
|
2390
|
-
createdAt:
|
|
2391
|
-
finishedAt:
|
|
2392
|
-
designSystemId:
|
|
2393
|
-
designSystemVersionId:
|
|
2394
|
-
workspaceId:
|
|
2395
|
-
scheduleId:
|
|
2396
|
-
exporterId:
|
|
2397
|
-
brandId:
|
|
2398
|
-
themeId:
|
|
2399
|
-
estimatedExecutionTime:
|
|
2400
|
+
userId: z107.coerce.string(),
|
|
2401
|
+
url: z107.string()
|
|
2402
|
+
});
|
|
2403
|
+
var ExporterJob = z107.object({
|
|
2404
|
+
id: z107.coerce.string(),
|
|
2405
|
+
createdAt: z107.coerce.date(),
|
|
2406
|
+
finishedAt: z107.coerce.date().optional(),
|
|
2407
|
+
designSystemId: z107.coerce.string(),
|
|
2408
|
+
designSystemVersionId: z107.coerce.string(),
|
|
2409
|
+
workspaceId: z107.coerce.string(),
|
|
2410
|
+
scheduleId: z107.coerce.string().nullish(),
|
|
2411
|
+
exporterId: z107.coerce.string(),
|
|
2412
|
+
brandId: z107.coerce.string().optional(),
|
|
2413
|
+
themeId: z107.coerce.string().optional(),
|
|
2414
|
+
estimatedExecutionTime: z107.number().optional(),
|
|
2400
2415
|
status: ExporterJobStatus,
|
|
2401
2416
|
result: ExporterJobResult.optional(),
|
|
2402
|
-
createdByUserId:
|
|
2417
|
+
createdByUserId: z107.string().optional(),
|
|
2403
2418
|
// CodegenDestinationsModel
|
|
2404
|
-
webhookUrl:
|
|
2419
|
+
webhookUrl: z107.string().optional(),
|
|
2405
2420
|
destinationSnDocs: ExporterDestinationSnDocs.optional(),
|
|
2406
2421
|
destinationS3: ExporterDestinationS3.optional(),
|
|
2407
2422
|
destinationGithub: ExporterDestinationGithub.optional(),
|
|
@@ -2420,14 +2435,14 @@ var ExporterJobFindByFilter = ExporterJob.pick({
|
|
|
2420
2435
|
themeId: true,
|
|
2421
2436
|
brandId: true
|
|
2422
2437
|
}).extend({
|
|
2423
|
-
destinations:
|
|
2438
|
+
destinations: z107.array(ExporterJobDestination),
|
|
2424
2439
|
docsEnvironment: PublishedDocEnvironment
|
|
2425
2440
|
}).partial();
|
|
2426
|
-
var ExporterWorkspaceMembershipRole =
|
|
2427
|
-
var ExporterWorkspaceMembership =
|
|
2428
|
-
id:
|
|
2429
|
-
workspaceId:
|
|
2430
|
-
exporterId:
|
|
2441
|
+
var ExporterWorkspaceMembershipRole = z108.enum(["Owner", "OwnerArchived", "User"]);
|
|
2442
|
+
var ExporterWorkspaceMembership = z109.object({
|
|
2443
|
+
id: z109.string(),
|
|
2444
|
+
workspaceId: z109.string(),
|
|
2445
|
+
exporterId: z109.string(),
|
|
2431
2446
|
role: ExporterWorkspaceMembershipRole
|
|
2432
2447
|
});
|
|
2433
2448
|
var GitProviderNames = /* @__PURE__ */ ((GitProviderNames2) => {
|
|
@@ -2437,8 +2452,8 @@ var GitProviderNames = /* @__PURE__ */ ((GitProviderNames2) => {
|
|
|
2437
2452
|
GitProviderNames2["Bitbucket"] = "bitbucket";
|
|
2438
2453
|
return GitProviderNames2;
|
|
2439
2454
|
})(GitProviderNames || {});
|
|
2440
|
-
var GitProvider =
|
|
2441
|
-
var PulsarPropertyType =
|
|
2455
|
+
var GitProvider = z110.nativeEnum(GitProviderNames);
|
|
2456
|
+
var PulsarPropertyType = z111.enum([
|
|
2442
2457
|
"string",
|
|
2443
2458
|
"number",
|
|
2444
2459
|
"boolean",
|
|
@@ -2451,164 +2466,164 @@ var PulsarPropertyType = z110.enum([
|
|
|
2451
2466
|
"tokenProperties",
|
|
2452
2467
|
"tokenType"
|
|
2453
2468
|
]);
|
|
2454
|
-
var PulsarBaseProperty =
|
|
2455
|
-
label:
|
|
2456
|
-
key:
|
|
2457
|
-
description:
|
|
2469
|
+
var PulsarBaseProperty = z111.object({
|
|
2470
|
+
label: z111.string(),
|
|
2471
|
+
key: z111.string(),
|
|
2472
|
+
description: z111.string().nullish(),
|
|
2458
2473
|
type: PulsarPropertyType,
|
|
2459
|
-
values:
|
|
2460
|
-
default:
|
|
2474
|
+
values: z111.array(z111.string()).nullish(),
|
|
2475
|
+
default: z111.union([z111.string(), z111.boolean(), z111.number()]).nullish(),
|
|
2461
2476
|
// PulsarPropertyValueType //is optional?
|
|
2462
|
-
inputType:
|
|
2477
|
+
inputType: z111.enum(["code", "plain"]).optional(),
|
|
2463
2478
|
//is optional?
|
|
2464
|
-
isMultiline:
|
|
2479
|
+
isMultiline: z111.boolean().nullish()
|
|
2465
2480
|
});
|
|
2466
2481
|
var PulsarContributionConfigurationProperty = PulsarBaseProperty.extend({
|
|
2467
|
-
category:
|
|
2468
|
-
});
|
|
2469
|
-
var PulsarContributionVariant =
|
|
2470
|
-
key:
|
|
2471
|
-
name:
|
|
2472
|
-
isDefault:
|
|
2473
|
-
description:
|
|
2474
|
-
thumbnailURL:
|
|
2475
|
-
});
|
|
2476
|
-
var PulsarCustomBlock =
|
|
2477
|
-
title:
|
|
2478
|
-
key:
|
|
2479
|
-
category:
|
|
2480
|
-
description: nullishToOptional(
|
|
2481
|
-
iconURL:
|
|
2482
|
-
mode:
|
|
2483
|
-
properties:
|
|
2484
|
-
});
|
|
2485
|
-
var ExporterType =
|
|
2486
|
-
var ExporterSource =
|
|
2487
|
-
var ExporterTag =
|
|
2488
|
-
var ExporterDetails =
|
|
2489
|
-
description:
|
|
2490
|
-
version:
|
|
2491
|
-
routingVersion: nullishToOptional(
|
|
2492
|
-
author: nullishToOptional(
|
|
2493
|
-
organization: nullishToOptional(
|
|
2494
|
-
homepage: nullishToOptional(
|
|
2495
|
-
readme: nullishToOptional(
|
|
2496
|
-
tags: nullishToOptional(
|
|
2497
|
-
packageId: nullishToOptional(
|
|
2498
|
-
iconURL: nullishToOptional(
|
|
2499
|
-
configurationProperties: nullishToOptional(
|
|
2500
|
-
customBlocks: nullishToOptional(
|
|
2501
|
-
blockVariants: nullishToOptional(
|
|
2502
|
-
usesBrands: nullishToOptional(
|
|
2503
|
-
usesThemes: nullishToOptional(
|
|
2482
|
+
category: z111.string()
|
|
2483
|
+
});
|
|
2484
|
+
var PulsarContributionVariant = z111.object({
|
|
2485
|
+
key: z111.string(),
|
|
2486
|
+
name: z111.string(),
|
|
2487
|
+
isDefault: z111.boolean().nullish(),
|
|
2488
|
+
description: z111.string().nullish(),
|
|
2489
|
+
thumbnailURL: z111.string().nullish()
|
|
2490
|
+
});
|
|
2491
|
+
var PulsarCustomBlock = z111.object({
|
|
2492
|
+
title: z111.string(),
|
|
2493
|
+
key: z111.string(),
|
|
2494
|
+
category: z111.string(),
|
|
2495
|
+
description: nullishToOptional(z111.string()),
|
|
2496
|
+
iconURL: z111.string(),
|
|
2497
|
+
mode: z111.enum(["array", "block"]),
|
|
2498
|
+
properties: z111.array(PulsarBaseProperty)
|
|
2499
|
+
});
|
|
2500
|
+
var ExporterType = z112.enum(["code", "documentation"]);
|
|
2501
|
+
var ExporterSource = z112.enum(["git", "upload"]);
|
|
2502
|
+
var ExporterTag = z112.string().regex(/^[0-9a-zA-Z]+(\s[0-9a-zA-Z]+)*$/);
|
|
2503
|
+
var ExporterDetails = z112.object({
|
|
2504
|
+
description: z112.string(),
|
|
2505
|
+
version: z112.string(),
|
|
2506
|
+
routingVersion: nullishToOptional(z112.string()),
|
|
2507
|
+
author: nullishToOptional(z112.string()),
|
|
2508
|
+
organization: nullishToOptional(z112.string()),
|
|
2509
|
+
homepage: nullishToOptional(z112.string()),
|
|
2510
|
+
readme: nullishToOptional(z112.string()),
|
|
2511
|
+
tags: nullishToOptional(z112.array(ExporterTag)).default([]),
|
|
2512
|
+
packageId: nullishToOptional(z112.string().max(255)),
|
|
2513
|
+
iconURL: nullishToOptional(z112.string()),
|
|
2514
|
+
configurationProperties: nullishToOptional(z112.array(PulsarContributionConfigurationProperty)).default([]),
|
|
2515
|
+
customBlocks: nullishToOptional(z112.array(PulsarCustomBlock)).default([]),
|
|
2516
|
+
blockVariants: nullishToOptional(z112.record(z112.string(), z112.array(PulsarContributionVariant))).default({}),
|
|
2517
|
+
usesBrands: nullishToOptional(z112.boolean()).default(false),
|
|
2518
|
+
usesThemes: nullishToOptional(z112.boolean()).default(false),
|
|
2504
2519
|
source: ExporterSource,
|
|
2505
2520
|
gitProvider: nullishToOptional(GitProvider),
|
|
2506
|
-
gitUrl: nullishToOptional(
|
|
2507
|
-
gitBranch: nullishToOptional(
|
|
2508
|
-
gitDirectory: nullishToOptional(
|
|
2521
|
+
gitUrl: nullishToOptional(z112.string()),
|
|
2522
|
+
gitBranch: nullishToOptional(z112.string()),
|
|
2523
|
+
gitDirectory: nullishToOptional(z112.string())
|
|
2509
2524
|
});
|
|
2510
|
-
var Exporter =
|
|
2511
|
-
id:
|
|
2512
|
-
createdAt:
|
|
2513
|
-
name:
|
|
2514
|
-
isPrivate:
|
|
2525
|
+
var Exporter = z112.object({
|
|
2526
|
+
id: z112.string(),
|
|
2527
|
+
createdAt: z112.coerce.date(),
|
|
2528
|
+
name: z112.string(),
|
|
2529
|
+
isPrivate: z112.boolean(),
|
|
2515
2530
|
details: ExporterDetails,
|
|
2516
2531
|
exporterType: nullishToOptional(ExporterType).default("code"),
|
|
2517
|
-
storagePath: nullishToOptional(
|
|
2532
|
+
storagePath: nullishToOptional(z112.string()).default("")
|
|
2518
2533
|
});
|
|
2519
|
-
var CustomDomain =
|
|
2520
|
-
id: z112.string(),
|
|
2521
|
-
designSystemId: z112.string(),
|
|
2522
|
-
state: z112.string(),
|
|
2523
|
-
supernovaDomain: z112.string(),
|
|
2524
|
-
customerDomain: z112.string().nullish(),
|
|
2525
|
-
error: z112.string().nullish(),
|
|
2526
|
-
errorCode: z112.string().nullish()
|
|
2527
|
-
});
|
|
2528
|
-
var IntegrationAuthType = z113.union([z113.literal("OAuth2"), z113.literal("PAT")]);
|
|
2529
|
-
var ExternalServiceType = z113.union([
|
|
2530
|
-
z113.literal("figma"),
|
|
2531
|
-
z113.literal("github"),
|
|
2532
|
-
z113.literal("azure"),
|
|
2533
|
-
z113.literal("gitlab"),
|
|
2534
|
-
z113.literal("bitbucket")
|
|
2535
|
-
]);
|
|
2536
|
-
var IntegrationUserInfo = z113.object({
|
|
2534
|
+
var CustomDomain = z113.object({
|
|
2537
2535
|
id: z113.string(),
|
|
2538
|
-
|
|
2539
|
-
|
|
2540
|
-
|
|
2536
|
+
designSystemId: z113.string(),
|
|
2537
|
+
state: z113.string(),
|
|
2538
|
+
supernovaDomain: z113.string(),
|
|
2539
|
+
customerDomain: z113.string().nullish(),
|
|
2540
|
+
error: z113.string().nullish(),
|
|
2541
|
+
errorCode: z113.string().nullish()
|
|
2542
|
+
});
|
|
2543
|
+
var IntegrationAuthType = z114.union([z114.literal("OAuth2"), z114.literal("PAT")]);
|
|
2544
|
+
var ExternalServiceType = z114.union([
|
|
2545
|
+
z114.literal("figma"),
|
|
2546
|
+
z114.literal("github"),
|
|
2547
|
+
z114.literal("azure"),
|
|
2548
|
+
z114.literal("gitlab"),
|
|
2549
|
+
z114.literal("bitbucket")
|
|
2550
|
+
]);
|
|
2551
|
+
var IntegrationUserInfo = z114.object({
|
|
2552
|
+
id: z114.string(),
|
|
2553
|
+
handle: z114.string().optional(),
|
|
2554
|
+
avatarUrl: z114.string().optional(),
|
|
2555
|
+
email: z114.string().optional(),
|
|
2541
2556
|
authType: IntegrationAuthType.optional(),
|
|
2542
|
-
customUrl:
|
|
2557
|
+
customUrl: z114.string().optional()
|
|
2543
2558
|
});
|
|
2544
|
-
var UserLinkedIntegrations =
|
|
2559
|
+
var UserLinkedIntegrations = z114.object({
|
|
2545
2560
|
figma: IntegrationUserInfo.optional(),
|
|
2546
2561
|
github: IntegrationUserInfo.array().optional(),
|
|
2547
2562
|
azure: IntegrationUserInfo.array().optional(),
|
|
2548
2563
|
gitlab: IntegrationUserInfo.array().optional(),
|
|
2549
2564
|
bitbucket: IntegrationUserInfo.array().optional()
|
|
2550
2565
|
});
|
|
2551
|
-
var UserIdentity =
|
|
2552
|
-
id:
|
|
2553
|
-
userId:
|
|
2554
|
-
});
|
|
2555
|
-
var UserOnboardingDepartment =
|
|
2556
|
-
var UserOnboardingJobLevel =
|
|
2557
|
-
var UserOnboarding =
|
|
2558
|
-
companyName:
|
|
2559
|
-
numberOfPeopleInOrg:
|
|
2560
|
-
numberOfPeopleInDesignTeam:
|
|
2566
|
+
var UserIdentity = z115.object({
|
|
2567
|
+
id: z115.string(),
|
|
2568
|
+
userId: z115.string()
|
|
2569
|
+
});
|
|
2570
|
+
var UserOnboardingDepartment = z116.enum(["Design", "Engineering", "Brand", "Other"]);
|
|
2571
|
+
var UserOnboardingJobLevel = z116.enum(["Executive", "Manager", "IndividualContributor", "Other"]);
|
|
2572
|
+
var UserOnboarding = z116.object({
|
|
2573
|
+
companyName: z116.string().optional(),
|
|
2574
|
+
numberOfPeopleInOrg: z116.string().optional(),
|
|
2575
|
+
numberOfPeopleInDesignTeam: z116.string().optional(),
|
|
2561
2576
|
department: UserOnboardingDepartment.optional(),
|
|
2562
|
-
jobTitle:
|
|
2563
|
-
phase:
|
|
2577
|
+
jobTitle: z116.string().optional(),
|
|
2578
|
+
phase: z116.string().optional(),
|
|
2564
2579
|
jobLevel: UserOnboardingJobLevel.optional()
|
|
2565
2580
|
});
|
|
2566
|
-
var UserProfile =
|
|
2567
|
-
name:
|
|
2568
|
-
avatar:
|
|
2569
|
-
nickname:
|
|
2581
|
+
var UserProfile = z116.object({
|
|
2582
|
+
name: z116.string(),
|
|
2583
|
+
avatar: z116.string().optional(),
|
|
2584
|
+
nickname: z116.string().optional(),
|
|
2570
2585
|
onboarding: UserOnboarding.optional()
|
|
2571
2586
|
});
|
|
2572
|
-
var User =
|
|
2573
|
-
id:
|
|
2574
|
-
email:
|
|
2575
|
-
emailVerified:
|
|
2576
|
-
createdAt:
|
|
2577
|
-
trialExpiresAt:
|
|
2587
|
+
var User = z117.object({
|
|
2588
|
+
id: z117.string(),
|
|
2589
|
+
email: z117.string(),
|
|
2590
|
+
emailVerified: z117.boolean(),
|
|
2591
|
+
createdAt: z117.coerce.date(),
|
|
2592
|
+
trialExpiresAt: z117.coerce.date().optional(),
|
|
2578
2593
|
profile: UserProfile,
|
|
2579
2594
|
linkedIntegrations: UserLinkedIntegrations.optional(),
|
|
2580
|
-
loggedOutAt:
|
|
2581
|
-
isProtected:
|
|
2595
|
+
loggedOutAt: z117.coerce.date().optional(),
|
|
2596
|
+
isProtected: z117.boolean()
|
|
2582
2597
|
});
|
|
2583
|
-
var NpmProxyToken =
|
|
2584
|
-
access:
|
|
2585
|
-
expiresAt:
|
|
2598
|
+
var NpmProxyToken = z118.object({
|
|
2599
|
+
access: z118.string(),
|
|
2600
|
+
expiresAt: z118.number()
|
|
2586
2601
|
});
|
|
2587
|
-
var SessionData =
|
|
2588
|
-
returnToUrl:
|
|
2602
|
+
var SessionData = z118.object({
|
|
2603
|
+
returnToUrl: z118.string().optional(),
|
|
2589
2604
|
npmProxyToken: NpmProxyToken.optional()
|
|
2590
2605
|
});
|
|
2591
|
-
var Session =
|
|
2592
|
-
id:
|
|
2593
|
-
expiresAt:
|
|
2594
|
-
userId:
|
|
2606
|
+
var Session = z118.object({
|
|
2607
|
+
id: z118.string(),
|
|
2608
|
+
expiresAt: z118.coerce.date(),
|
|
2609
|
+
userId: z118.string().nullable(),
|
|
2595
2610
|
data: SessionData
|
|
2596
2611
|
});
|
|
2597
|
-
var AuthTokens =
|
|
2598
|
-
access:
|
|
2599
|
-
refresh:
|
|
2612
|
+
var AuthTokens = z118.object({
|
|
2613
|
+
access: z118.string(),
|
|
2614
|
+
refresh: z118.string()
|
|
2600
2615
|
});
|
|
2601
|
-
var UserSession =
|
|
2616
|
+
var UserSession = z118.object({
|
|
2602
2617
|
session: Session,
|
|
2603
2618
|
user: User.nullable()
|
|
2604
2619
|
});
|
|
2605
|
-
var FlaggedFeature =
|
|
2606
|
-
var FeatureFlagMap =
|
|
2607
|
-
var FeatureFlag =
|
|
2608
|
-
id:
|
|
2620
|
+
var FlaggedFeature = z119.enum(["FigmaImporterV2"]);
|
|
2621
|
+
var FeatureFlagMap = z119.record(FlaggedFeature, z119.boolean());
|
|
2622
|
+
var FeatureFlag = z119.object({
|
|
2623
|
+
id: z119.string(),
|
|
2609
2624
|
feature: FlaggedFeature,
|
|
2610
|
-
createdAt:
|
|
2611
|
-
enabled:
|
|
2625
|
+
createdAt: z119.coerce.date(),
|
|
2626
|
+
enabled: z119.boolean()
|
|
2612
2627
|
});
|
|
2613
2628
|
var OAuthProviderNames = /* @__PURE__ */ ((OAuthProviderNames2) => {
|
|
2614
2629
|
OAuthProviderNames2["Figma"] = "figma";
|
|
@@ -2618,96 +2633,96 @@ var OAuthProviderNames = /* @__PURE__ */ ((OAuthProviderNames2) => {
|
|
|
2618
2633
|
OAuthProviderNames2["Bitbucket"] = "bitbucket";
|
|
2619
2634
|
return OAuthProviderNames2;
|
|
2620
2635
|
})(OAuthProviderNames || {});
|
|
2621
|
-
var OAuthProviderSchema =
|
|
2636
|
+
var OAuthProviderSchema = z120.nativeEnum(OAuthProviderNames);
|
|
2622
2637
|
var OAuthProvider = OAuthProviderSchema.enum;
|
|
2623
|
-
var ExternalOAuthRequest =
|
|
2624
|
-
id: z120.string(),
|
|
2625
|
-
provider: OAuthProviderSchema,
|
|
2626
|
-
userId: z120.string(),
|
|
2627
|
-
state: z120.string(),
|
|
2628
|
-
createdAt: z120.coerce.date()
|
|
2629
|
-
});
|
|
2630
|
-
var IntegrationTokenSchema = z121.object({
|
|
2638
|
+
var ExternalOAuthRequest = z121.object({
|
|
2631
2639
|
id: z121.string(),
|
|
2632
2640
|
provider: OAuthProviderSchema,
|
|
2633
|
-
scope: z121.string(),
|
|
2634
2641
|
userId: z121.string(),
|
|
2635
|
-
|
|
2636
|
-
|
|
2637
|
-
|
|
2638
|
-
|
|
2642
|
+
state: z121.string(),
|
|
2643
|
+
createdAt: z121.coerce.date()
|
|
2644
|
+
});
|
|
2645
|
+
var IntegrationTokenSchema = z122.object({
|
|
2646
|
+
id: z122.string(),
|
|
2647
|
+
provider: OAuthProviderSchema,
|
|
2648
|
+
scope: z122.string(),
|
|
2649
|
+
userId: z122.string(),
|
|
2650
|
+
accessToken: z122.string(),
|
|
2651
|
+
refreshToken: z122.string(),
|
|
2652
|
+
expiresAt: z122.coerce.date(),
|
|
2653
|
+
externalUserId: z122.string().nullish()
|
|
2639
2654
|
});
|
|
2640
2655
|
var DesignSystemVersionRoom = Entity.extend({
|
|
2641
|
-
designSystemVersionId:
|
|
2642
|
-
liveblocksId:
|
|
2656
|
+
designSystemVersionId: z123.string(),
|
|
2657
|
+
liveblocksId: z123.string()
|
|
2643
2658
|
});
|
|
2644
|
-
var DesignSystemVersionRoomInitialState =
|
|
2645
|
-
pages:
|
|
2646
|
-
groups:
|
|
2659
|
+
var DesignSystemVersionRoomInitialState = z123.object({
|
|
2660
|
+
pages: z123.array(DocumentationPageV2),
|
|
2661
|
+
groups: z123.array(ElementGroup)
|
|
2647
2662
|
});
|
|
2648
2663
|
var DesignSystemVersionRoomUpdate = DesignSystemVersionRoomInitialState.extend({
|
|
2649
|
-
deletedPageIds:
|
|
2650
|
-
deletedGroupIds:
|
|
2664
|
+
deletedPageIds: z123.array(z123.string()),
|
|
2665
|
+
deletedGroupIds: z123.array(z123.string())
|
|
2651
2666
|
});
|
|
2652
2667
|
var DocumentationPageRoom = Entity.extend({
|
|
2653
|
-
designSystemVersionId:
|
|
2654
|
-
documentationPageId:
|
|
2655
|
-
liveblocksId:
|
|
2668
|
+
designSystemVersionId: z124.string(),
|
|
2669
|
+
documentationPageId: z124.string(),
|
|
2670
|
+
liveblocksId: z124.string()
|
|
2656
2671
|
});
|
|
2657
|
-
var PageBlockEditorModel =
|
|
2658
|
-
id:
|
|
2672
|
+
var PageBlockEditorModel = z124.object({
|
|
2673
|
+
id: z124.string(),
|
|
2659
2674
|
data: PageBlockDataV2
|
|
2660
2675
|
});
|
|
2661
|
-
var DocumentationPageRoomRoomUpdate =
|
|
2676
|
+
var DocumentationPageRoomRoomUpdate = z124.object({
|
|
2662
2677
|
page: DocumentationPageV2,
|
|
2663
2678
|
pageParent: ElementGroup
|
|
2664
2679
|
});
|
|
2665
2680
|
var DocumentationPageRoomInitialState = DocumentationPageRoomRoomUpdate.extend({
|
|
2666
|
-
pageBlocks:
|
|
2667
|
-
blockDefinitions:
|
|
2681
|
+
pageBlocks: z124.array(PageBlockEditorModel),
|
|
2682
|
+
blockDefinitions: z124.array(PageBlockDefinition)
|
|
2668
2683
|
});
|
|
2669
2684
|
var RoomTypeEnum = /* @__PURE__ */ ((RoomTypeEnum2) => {
|
|
2670
2685
|
RoomTypeEnum2["DocumentationPage"] = "documentation-page";
|
|
2671
2686
|
RoomTypeEnum2["DesignSystemVersion"] = "design-system-version";
|
|
2672
2687
|
return RoomTypeEnum2;
|
|
2673
2688
|
})(RoomTypeEnum || {});
|
|
2674
|
-
var RoomTypeSchema =
|
|
2689
|
+
var RoomTypeSchema = z125.nativeEnum(RoomTypeEnum);
|
|
2675
2690
|
var RoomType = RoomTypeSchema.enum;
|
|
2676
|
-
var AnyRecord =
|
|
2691
|
+
var AnyRecord = z126.record(z126.any());
|
|
2677
2692
|
var NpmPackageVersionDist = AnyRecord.and(
|
|
2678
|
-
|
|
2679
|
-
tarball:
|
|
2693
|
+
z126.object({
|
|
2694
|
+
tarball: z126.string()
|
|
2680
2695
|
})
|
|
2681
2696
|
);
|
|
2682
2697
|
var NpmPackageVersion = AnyRecord.and(
|
|
2683
|
-
|
|
2698
|
+
z126.object({
|
|
2684
2699
|
dist: NpmPackageVersionDist
|
|
2685
2700
|
})
|
|
2686
2701
|
);
|
|
2687
2702
|
var NpmPackage = AnyRecord.and(
|
|
2688
|
-
|
|
2689
|
-
_id:
|
|
2690
|
-
name:
|
|
2703
|
+
z126.object({
|
|
2704
|
+
_id: z126.string(),
|
|
2705
|
+
name: z126.string(),
|
|
2691
2706
|
// e.g. "latest": "1.2.3"
|
|
2692
|
-
"dist-tags":
|
|
2707
|
+
"dist-tags": z126.record(z126.string(), z126.string()),
|
|
2693
2708
|
// "1.2.3": {...}
|
|
2694
|
-
versions:
|
|
2709
|
+
versions: z126.record(NpmPackageVersion)
|
|
2695
2710
|
})
|
|
2696
2711
|
);
|
|
2697
|
-
var NpmProxyTokenPayload =
|
|
2698
|
-
npmProxyRegistryConfigId:
|
|
2699
|
-
});
|
|
2700
|
-
var PersonalAccessToken =
|
|
2701
|
-
id:
|
|
2702
|
-
userId:
|
|
2703
|
-
name:
|
|
2704
|
-
token:
|
|
2705
|
-
createdAt:
|
|
2706
|
-
hidden:
|
|
2707
|
-
workspaceId:
|
|
2712
|
+
var NpmProxyTokenPayload = z127.object({
|
|
2713
|
+
npmProxyRegistryConfigId: z127.string()
|
|
2714
|
+
});
|
|
2715
|
+
var PersonalAccessToken = z128.object({
|
|
2716
|
+
id: z128.string(),
|
|
2717
|
+
userId: z128.string(),
|
|
2718
|
+
name: z128.string(),
|
|
2719
|
+
token: z128.string(),
|
|
2720
|
+
createdAt: z128.coerce.date(),
|
|
2721
|
+
hidden: z128.boolean(),
|
|
2722
|
+
workspaceId: z128.string().optional(),
|
|
2708
2723
|
workspaceRole: WorkspaceRoleSchema.optional(),
|
|
2709
|
-
expireAt:
|
|
2710
|
-
scope:
|
|
2724
|
+
expireAt: z128.coerce.date().optional(),
|
|
2725
|
+
scope: z128.string().optional()
|
|
2711
2726
|
});
|
|
2712
2727
|
var SupernovaException = class _SupernovaException extends Error {
|
|
2713
2728
|
//
|
|
@@ -2723,6 +2738,9 @@ var SupernovaException = class _SupernovaException extends Error {
|
|
|
2723
2738
|
static accessDenied(message) {
|
|
2724
2739
|
return new _SupernovaException("AccessDenied", message);
|
|
2725
2740
|
}
|
|
2741
|
+
static tooMuchWork(message) {
|
|
2742
|
+
return new _SupernovaException("TooMuchWork", message);
|
|
2743
|
+
}
|
|
2726
2744
|
static notFound(message) {
|
|
2727
2745
|
return new _SupernovaException("ResourceNotFound", message);
|
|
2728
2746
|
}
|
|
@@ -2789,25 +2807,25 @@ function groupBy(items, keyFn) {
|
|
|
2789
2807
|
}
|
|
2790
2808
|
return result;
|
|
2791
2809
|
}
|
|
2792
|
-
var ContentLoadInstruction =
|
|
2793
|
-
from:
|
|
2794
|
-
to:
|
|
2795
|
-
authorizationHeaderKvsId:
|
|
2796
|
-
timeout:
|
|
2797
|
-
});
|
|
2798
|
-
var ContentLoaderPayload =
|
|
2799
|
-
type:
|
|
2810
|
+
var ContentLoadInstruction = z129.object({
|
|
2811
|
+
from: z129.string(),
|
|
2812
|
+
to: z129.string(),
|
|
2813
|
+
authorizationHeaderKvsId: z129.string().optional(),
|
|
2814
|
+
timeout: z129.number().optional()
|
|
2815
|
+
});
|
|
2816
|
+
var ContentLoaderPayload = z129.object({
|
|
2817
|
+
type: z129.literal("Single"),
|
|
2800
2818
|
instruction: ContentLoadInstruction
|
|
2801
2819
|
}).or(
|
|
2802
|
-
|
|
2803
|
-
type:
|
|
2804
|
-
loadingChunkSize:
|
|
2805
|
-
instructions:
|
|
2820
|
+
z129.object({
|
|
2821
|
+
type: z129.literal("Multiple"),
|
|
2822
|
+
loadingChunkSize: z129.number().optional(),
|
|
2823
|
+
instructions: z129.array(ContentLoadInstruction)
|
|
2806
2824
|
})
|
|
2807
2825
|
).or(
|
|
2808
|
-
|
|
2809
|
-
type:
|
|
2810
|
-
location:
|
|
2826
|
+
z129.object({
|
|
2827
|
+
type: z129.literal("S3"),
|
|
2828
|
+
location: z129.string()
|
|
2811
2829
|
})
|
|
2812
2830
|
);
|
|
2813
2831
|
function slugify(str, options) {
|
|
@@ -3604,10 +3622,10 @@ var DTODesignSystem = DesignSystem.omit({
|
|
|
3604
3622
|
});
|
|
3605
3623
|
|
|
3606
3624
|
// src/api/dto/elements/documentation/group-action.ts
|
|
3607
|
-
import { z as
|
|
3625
|
+
import { z as z131 } from "zod";
|
|
3608
3626
|
|
|
3609
3627
|
// src/api/dto/elements/documentation/group.ts
|
|
3610
|
-
import { z as
|
|
3628
|
+
import { z as z130 } from "zod";
|
|
3611
3629
|
var DTODocumentationGroupStructureV2 = ElementGroup.omit({
|
|
3612
3630
|
sortOrder: true,
|
|
3613
3631
|
parentPersistentId: true,
|
|
@@ -3617,248 +3635,288 @@ var DTODocumentationGroupStructureV2 = ElementGroup.omit({
|
|
|
3617
3635
|
data: true,
|
|
3618
3636
|
shortPersistentId: true
|
|
3619
3637
|
}).extend({
|
|
3620
|
-
title:
|
|
3621
|
-
isRoot:
|
|
3622
|
-
childrenIds:
|
|
3638
|
+
title: z130.string(),
|
|
3639
|
+
isRoot: z130.boolean(),
|
|
3640
|
+
childrenIds: z130.array(z130.string()),
|
|
3623
3641
|
groupBehavior: DocumentationGroupBehavior,
|
|
3624
|
-
shortPersistentId:
|
|
3625
|
-
type:
|
|
3642
|
+
shortPersistentId: z130.string(),
|
|
3643
|
+
type: z130.literal("Group")
|
|
3626
3644
|
});
|
|
3627
3645
|
var DTODocumentationGroupV2 = DTODocumentationGroupStructureV2.extend({
|
|
3628
3646
|
configuration: DocumentationItemConfigurationV2
|
|
3629
3647
|
});
|
|
3630
|
-
var DTOCreateDocumentationGroupInput =
|
|
3648
|
+
var DTOCreateDocumentationGroupInput = z130.object({
|
|
3631
3649
|
// Identifier
|
|
3632
|
-
persistentId:
|
|
3650
|
+
persistentId: z130.string().uuid(),
|
|
3633
3651
|
// Group properties
|
|
3634
|
-
title:
|
|
3652
|
+
title: z130.string(),
|
|
3635
3653
|
configuration: DocumentationItemConfigurationV2.optional(),
|
|
3636
3654
|
// Group placement properties
|
|
3637
|
-
afterPersistentId:
|
|
3638
|
-
parentPersistentId:
|
|
3655
|
+
afterPersistentId: z130.string().uuid().optional(),
|
|
3656
|
+
parentPersistentId: z130.string().uuid()
|
|
3639
3657
|
});
|
|
3640
|
-
var DTOUpdateDocumentationGroupInput =
|
|
3658
|
+
var DTOUpdateDocumentationGroupInput = z130.object({
|
|
3641
3659
|
// Identifier of the group to update
|
|
3642
|
-
id:
|
|
3660
|
+
id: z130.string().uuid(),
|
|
3643
3661
|
// Group properties
|
|
3644
|
-
title:
|
|
3662
|
+
title: z130.string().optional(),
|
|
3645
3663
|
configuration: DocumentationItemConfigurationV2.optional()
|
|
3646
3664
|
});
|
|
3647
|
-
var DTOMoveDocumentationGroupInput =
|
|
3665
|
+
var DTOMoveDocumentationGroupInput = z130.object({
|
|
3648
3666
|
// Identifier of the group to update
|
|
3649
|
-
id:
|
|
3667
|
+
id: z130.string().uuid(),
|
|
3650
3668
|
// Group placement properties
|
|
3651
|
-
|
|
3652
|
-
|
|
3669
|
+
parentPersistentId: z130.string().uuid(),
|
|
3670
|
+
afterPersistentId: z130.string().uuid().optional()
|
|
3653
3671
|
});
|
|
3654
|
-
var DTODuplicateDocumentationGroupInput =
|
|
3672
|
+
var DTODuplicateDocumentationGroupInput = z130.object({
|
|
3655
3673
|
// Identifier of the group to duplicate from
|
|
3656
|
-
id:
|
|
3674
|
+
id: z130.string(),
|
|
3657
3675
|
// New group persistent id
|
|
3658
|
-
persistentId:
|
|
3676
|
+
persistentId: z130.string().uuid(),
|
|
3659
3677
|
// Group placement properties
|
|
3660
|
-
afterPersistentId:
|
|
3661
|
-
parentPersistentId:
|
|
3678
|
+
afterPersistentId: z130.string().uuid().optional(),
|
|
3679
|
+
parentPersistentId: z130.string().uuid()
|
|
3662
3680
|
});
|
|
3663
|
-
var DTOCreateDocumentationTabGroupInput =
|
|
3681
|
+
var DTOCreateDocumentationTabGroupInput = z130.object({
|
|
3664
3682
|
// New group persistent id
|
|
3665
|
-
persistentId:
|
|
3683
|
+
persistentId: z130.string().uuid(),
|
|
3666
3684
|
// Page that will become first tab of the tab group
|
|
3667
|
-
fromPageId:
|
|
3668
|
-
tabName:
|
|
3685
|
+
fromPageId: z130.string(),
|
|
3686
|
+
tabName: z130.string()
|
|
3669
3687
|
});
|
|
3670
|
-
var DTODeleteDocumentationTabGroupInput =
|
|
3688
|
+
var DTODeleteDocumentationTabGroupInput = z130.object({
|
|
3671
3689
|
// Deleted group id
|
|
3672
|
-
id:
|
|
3690
|
+
id: z130.string()
|
|
3673
3691
|
});
|
|
3674
|
-
var DTODeleteDocumentationGroupInput =
|
|
3692
|
+
var DTODeleteDocumentationGroupInput = z130.object({
|
|
3675
3693
|
// Identifier
|
|
3676
|
-
id:
|
|
3694
|
+
id: z130.string(),
|
|
3677
3695
|
// Deletion options
|
|
3678
|
-
deleteSubtree:
|
|
3696
|
+
deleteSubtree: z130.boolean().default(false)
|
|
3679
3697
|
});
|
|
3680
3698
|
|
|
3681
3699
|
// src/api/dto/elements/documentation/group-action.ts
|
|
3682
|
-
var SuccessPayload =
|
|
3683
|
-
success:
|
|
3700
|
+
var SuccessPayload = z131.object({
|
|
3701
|
+
success: z131.literal(true)
|
|
3684
3702
|
});
|
|
3685
|
-
var DTODocumentationGroupCreateActionOutputV2 =
|
|
3686
|
-
type:
|
|
3703
|
+
var DTODocumentationGroupCreateActionOutputV2 = z131.object({
|
|
3704
|
+
type: z131.literal("DocumentationGroupCreate"),
|
|
3687
3705
|
output: SuccessPayload
|
|
3688
3706
|
});
|
|
3689
|
-
var DTODocumentationTabGroupCreateActionOutputV2 =
|
|
3690
|
-
type:
|
|
3707
|
+
var DTODocumentationTabGroupCreateActionOutputV2 = z131.object({
|
|
3708
|
+
type: z131.literal("DocumentationTabGroupCreate"),
|
|
3691
3709
|
output: SuccessPayload
|
|
3692
3710
|
});
|
|
3693
|
-
var DTODocumentationGroupUpdateActionOutputV2 =
|
|
3694
|
-
type:
|
|
3711
|
+
var DTODocumentationGroupUpdateActionOutputV2 = z131.object({
|
|
3712
|
+
type: z131.literal("DocumentationGroupUpdate"),
|
|
3695
3713
|
output: SuccessPayload
|
|
3696
3714
|
});
|
|
3697
|
-
var DTODocumentationGroupMoveActionOutputV2 =
|
|
3698
|
-
type:
|
|
3715
|
+
var DTODocumentationGroupMoveActionOutputV2 = z131.object({
|
|
3716
|
+
type: z131.literal("DocumentationGroupMove"),
|
|
3699
3717
|
output: SuccessPayload
|
|
3700
3718
|
});
|
|
3701
|
-
var DTODocumentationGroupDuplicateActionOutputV2 =
|
|
3702
|
-
type:
|
|
3719
|
+
var DTODocumentationGroupDuplicateActionOutputV2 = z131.object({
|
|
3720
|
+
type: z131.literal("DocumentationGroupDuplicate"),
|
|
3703
3721
|
output: SuccessPayload
|
|
3704
3722
|
});
|
|
3705
|
-
var DTODocumentationGroupDeleteActionOutputV2 =
|
|
3706
|
-
type:
|
|
3723
|
+
var DTODocumentationGroupDeleteActionOutputV2 = z131.object({
|
|
3724
|
+
type: z131.literal("DocumentationGroupDelete"),
|
|
3707
3725
|
output: SuccessPayload
|
|
3708
3726
|
});
|
|
3709
|
-
var DTODocumentationTabGroupDeleteActionOutputV2 =
|
|
3710
|
-
type:
|
|
3727
|
+
var DTODocumentationTabGroupDeleteActionOutputV2 = z131.object({
|
|
3728
|
+
type: z131.literal("DocumentationTabGroupDelete"),
|
|
3711
3729
|
output: SuccessPayload
|
|
3712
3730
|
});
|
|
3713
|
-
var DTODocumentationGroupCreateActionInputV2 =
|
|
3714
|
-
type:
|
|
3731
|
+
var DTODocumentationGroupCreateActionInputV2 = z131.object({
|
|
3732
|
+
type: z131.literal("DocumentationGroupCreate"),
|
|
3715
3733
|
input: DTOCreateDocumentationGroupInput
|
|
3716
3734
|
});
|
|
3717
|
-
var DTODocumentationTabGroupCreateActionInputV2 =
|
|
3718
|
-
type:
|
|
3735
|
+
var DTODocumentationTabGroupCreateActionInputV2 = z131.object({
|
|
3736
|
+
type: z131.literal("DocumentationTabGroupCreate"),
|
|
3719
3737
|
input: DTOCreateDocumentationTabGroupInput
|
|
3720
3738
|
});
|
|
3721
|
-
var DTODocumentationGroupUpdateActionInputV2 =
|
|
3722
|
-
type:
|
|
3739
|
+
var DTODocumentationGroupUpdateActionInputV2 = z131.object({
|
|
3740
|
+
type: z131.literal("DocumentationGroupUpdate"),
|
|
3723
3741
|
input: DTOUpdateDocumentationGroupInput
|
|
3724
3742
|
});
|
|
3725
|
-
var DTODocumentationGroupMoveActionInputV2 =
|
|
3726
|
-
type:
|
|
3743
|
+
var DTODocumentationGroupMoveActionInputV2 = z131.object({
|
|
3744
|
+
type: z131.literal("DocumentationGroupMove"),
|
|
3727
3745
|
input: DTOMoveDocumentationGroupInput
|
|
3728
3746
|
});
|
|
3729
|
-
var DTODocumentationGroupDuplicateActionInputV2 =
|
|
3730
|
-
type:
|
|
3747
|
+
var DTODocumentationGroupDuplicateActionInputV2 = z131.object({
|
|
3748
|
+
type: z131.literal("DocumentationGroupDuplicate"),
|
|
3731
3749
|
input: DTODuplicateDocumentationGroupInput
|
|
3732
3750
|
});
|
|
3733
|
-
var DTODocumentationGroupDeleteActionInputV2 =
|
|
3734
|
-
type:
|
|
3751
|
+
var DTODocumentationGroupDeleteActionInputV2 = z131.object({
|
|
3752
|
+
type: z131.literal("DocumentationGroupDelete"),
|
|
3735
3753
|
input: DTODeleteDocumentationGroupInput
|
|
3736
3754
|
});
|
|
3737
|
-
var DTODocumentationTabGroupDeleteActionInputV2 =
|
|
3738
|
-
type:
|
|
3755
|
+
var DTODocumentationTabGroupDeleteActionInputV2 = z131.object({
|
|
3756
|
+
type: z131.literal("DocumentationTabGroupDelete"),
|
|
3739
3757
|
input: DTODeleteDocumentationTabGroupInput
|
|
3740
3758
|
});
|
|
3741
3759
|
|
|
3742
3760
|
// src/api/dto/elements/documentation/page-actions-v2.ts
|
|
3743
|
-
import { z as
|
|
3761
|
+
import { z as z133 } from "zod";
|
|
3744
3762
|
|
|
3745
3763
|
// src/api/dto/elements/documentation/page-v2.ts
|
|
3746
|
-
import { z as
|
|
3764
|
+
import { z as z132 } from "zod";
|
|
3747
3765
|
var DTODocumentationPageStructureV2 = DocumentationPageV2.omit({
|
|
3748
3766
|
data: true,
|
|
3749
3767
|
meta: true,
|
|
3750
3768
|
parentPersistentId: true,
|
|
3751
3769
|
sortOrder: true
|
|
3752
3770
|
}).extend({
|
|
3753
|
-
title:
|
|
3754
|
-
path:
|
|
3755
|
-
type:
|
|
3771
|
+
title: z132.string(),
|
|
3772
|
+
path: z132.string(),
|
|
3773
|
+
type: z132.literal("Page")
|
|
3756
3774
|
});
|
|
3757
3775
|
var DTODocumentationPageV2 = DTODocumentationPageStructureV2.extend({
|
|
3758
3776
|
configuration: DocumentationItemConfigurationV2
|
|
3759
3777
|
});
|
|
3760
|
-
var DTODocumentationHierarchyV2 =
|
|
3761
|
-
pages:
|
|
3762
|
-
groups:
|
|
3778
|
+
var DTODocumentationHierarchyV2 = z132.object({
|
|
3779
|
+
pages: z132.array(DTODocumentationPageStructureV2),
|
|
3780
|
+
groups: z132.array(DTODocumentationGroupStructureV2)
|
|
3763
3781
|
});
|
|
3764
|
-
var DTOCreateDocumentationPageInputV2 =
|
|
3782
|
+
var DTOCreateDocumentationPageInputV2 = z132.object({
|
|
3765
3783
|
// Identifier
|
|
3766
|
-
persistentId:
|
|
3784
|
+
persistentId: z132.string().uuid(),
|
|
3767
3785
|
// Page properties
|
|
3768
|
-
title:
|
|
3786
|
+
title: z132.string(),
|
|
3769
3787
|
configuration: DocumentationItemConfigurationV2.optional(),
|
|
3770
3788
|
// Page placement properties
|
|
3771
|
-
parentPersistentId:
|
|
3772
|
-
afterPersistentId:
|
|
3789
|
+
parentPersistentId: z132.string().uuid(),
|
|
3790
|
+
afterPersistentId: z132.string().uuid().optional()
|
|
3773
3791
|
});
|
|
3774
|
-
var DTOUpdateDocumentationPageInputV2 =
|
|
3792
|
+
var DTOUpdateDocumentationPageInputV2 = z132.object({
|
|
3775
3793
|
// Identifier of the group to update
|
|
3776
|
-
id:
|
|
3794
|
+
id: z132.string(),
|
|
3777
3795
|
// Page properties
|
|
3778
|
-
title:
|
|
3796
|
+
title: z132.string().optional(),
|
|
3779
3797
|
configuration: DocumentationItemConfigurationV2.optional()
|
|
3780
3798
|
});
|
|
3781
|
-
var DTOMoveDocumentationPageInputV2 =
|
|
3799
|
+
var DTOMoveDocumentationPageInputV2 = z132.object({
|
|
3782
3800
|
// Identifier of the group to update
|
|
3783
|
-
id:
|
|
3801
|
+
id: z132.string(),
|
|
3784
3802
|
// Page placement properties
|
|
3785
|
-
parentPersistentId:
|
|
3786
|
-
afterPersistentId:
|
|
3803
|
+
parentPersistentId: z132.string().uuid(),
|
|
3804
|
+
afterPersistentId: z132.string().uuid().optional()
|
|
3787
3805
|
});
|
|
3788
|
-
var DTODuplicateDocumentationPageInputV2 =
|
|
3806
|
+
var DTODuplicateDocumentationPageInputV2 = z132.object({
|
|
3789
3807
|
// Identifier of the page to duplicate from
|
|
3790
|
-
id:
|
|
3808
|
+
id: z132.string(),
|
|
3791
3809
|
// New page persistent id
|
|
3792
|
-
persistentId:
|
|
3810
|
+
persistentId: z132.string().uuid(),
|
|
3793
3811
|
// Page placement properties
|
|
3794
|
-
parentPersistentId:
|
|
3795
|
-
afterPersistentId:
|
|
3812
|
+
parentPersistentId: z132.string().uuid(),
|
|
3813
|
+
afterPersistentId: z132.string().uuid().optional()
|
|
3796
3814
|
});
|
|
3797
|
-
var DTODeleteDocumentationPageInputV2 =
|
|
3815
|
+
var DTODeleteDocumentationPageInputV2 = z132.object({
|
|
3798
3816
|
// Identifier
|
|
3799
|
-
id:
|
|
3817
|
+
id: z132.string()
|
|
3800
3818
|
});
|
|
3801
3819
|
|
|
3802
3820
|
// src/api/dto/elements/documentation/page-actions-v2.ts
|
|
3803
|
-
var SuccessPayload2 =
|
|
3804
|
-
success:
|
|
3821
|
+
var SuccessPayload2 = z133.object({
|
|
3822
|
+
success: z133.literal(true)
|
|
3805
3823
|
});
|
|
3806
|
-
var DTODocumentationPageCreateActionOutputV2 =
|
|
3807
|
-
type:
|
|
3824
|
+
var DTODocumentationPageCreateActionOutputV2 = z133.object({
|
|
3825
|
+
type: z133.literal("DocumentationPageCreate"),
|
|
3808
3826
|
output: SuccessPayload2
|
|
3809
3827
|
});
|
|
3810
|
-
var DTODocumentationPageUpdateActionOutputV2 =
|
|
3811
|
-
type:
|
|
3828
|
+
var DTODocumentationPageUpdateActionOutputV2 = z133.object({
|
|
3829
|
+
type: z133.literal("DocumentationPageUpdate"),
|
|
3812
3830
|
output: SuccessPayload2
|
|
3813
3831
|
});
|
|
3814
|
-
var DTODocumentationPageMoveActionOutputV2 =
|
|
3815
|
-
type:
|
|
3832
|
+
var DTODocumentationPageMoveActionOutputV2 = z133.object({
|
|
3833
|
+
type: z133.literal("DocumentationPageMove"),
|
|
3816
3834
|
output: SuccessPayload2
|
|
3817
3835
|
});
|
|
3818
|
-
var DTODocumentationPageDuplicateActionOutputV2 =
|
|
3819
|
-
type:
|
|
3836
|
+
var DTODocumentationPageDuplicateActionOutputV2 = z133.object({
|
|
3837
|
+
type: z133.literal("DocumentationPageDuplicate"),
|
|
3820
3838
|
output: SuccessPayload2
|
|
3821
3839
|
});
|
|
3822
|
-
var DTODocumentationPageDeleteActionOutputV2 =
|
|
3823
|
-
type:
|
|
3840
|
+
var DTODocumentationPageDeleteActionOutputV2 = z133.object({
|
|
3841
|
+
type: z133.literal("DocumentationPageDelete"),
|
|
3824
3842
|
output: SuccessPayload2
|
|
3825
3843
|
});
|
|
3826
|
-
var DTODocumentationPageCreateActionInputV2 =
|
|
3827
|
-
type:
|
|
3844
|
+
var DTODocumentationPageCreateActionInputV2 = z133.object({
|
|
3845
|
+
type: z133.literal("DocumentationPageCreate"),
|
|
3828
3846
|
input: DTOCreateDocumentationPageInputV2
|
|
3829
3847
|
});
|
|
3830
|
-
var DTODocumentationPageUpdateActionInputV2 =
|
|
3831
|
-
type:
|
|
3848
|
+
var DTODocumentationPageUpdateActionInputV2 = z133.object({
|
|
3849
|
+
type: z133.literal("DocumentationPageUpdate"),
|
|
3832
3850
|
input: DTOUpdateDocumentationPageInputV2
|
|
3833
3851
|
});
|
|
3834
|
-
var DTODocumentationPageMoveActionInputV2 =
|
|
3835
|
-
type:
|
|
3852
|
+
var DTODocumentationPageMoveActionInputV2 = z133.object({
|
|
3853
|
+
type: z133.literal("DocumentationPageMove"),
|
|
3836
3854
|
input: DTOMoveDocumentationPageInputV2
|
|
3837
3855
|
});
|
|
3838
|
-
var DTODocumentationPageDuplicateActionInputV2 =
|
|
3839
|
-
type:
|
|
3856
|
+
var DTODocumentationPageDuplicateActionInputV2 = z133.object({
|
|
3857
|
+
type: z133.literal("DocumentationPageDuplicate"),
|
|
3840
3858
|
input: DTODuplicateDocumentationPageInputV2
|
|
3841
3859
|
});
|
|
3842
|
-
var DTODocumentationPageDeleteActionInputV2 =
|
|
3843
|
-
type:
|
|
3860
|
+
var DTODocumentationPageDeleteActionInputV2 = z133.object({
|
|
3861
|
+
type: z133.literal("DocumentationPageDelete"),
|
|
3844
3862
|
input: DTODeleteDocumentationPageInputV2
|
|
3845
3863
|
});
|
|
3846
3864
|
|
|
3847
3865
|
// src/api/dto/elements/documentation/page-v1.ts
|
|
3848
|
-
import { z as
|
|
3866
|
+
import { z as z134 } from "zod";
|
|
3849
3867
|
var DocumentationPageV1DTO = DocumentationPageV1.omit({
|
|
3850
3868
|
data: true,
|
|
3851
3869
|
meta: true,
|
|
3852
3870
|
parentPersistentId: true,
|
|
3853
3871
|
sortOrder: true
|
|
3854
3872
|
}).extend(DocumentationPageV1.shape.data.shape).extend({
|
|
3855
|
-
title:
|
|
3856
|
-
path:
|
|
3873
|
+
title: z134.string(),
|
|
3874
|
+
path: z134.string()
|
|
3875
|
+
});
|
|
3876
|
+
|
|
3877
|
+
// src/api/dto/elements/figma-nodes/node-actions-v2.ts
|
|
3878
|
+
import { z as z136 } from "zod";
|
|
3879
|
+
|
|
3880
|
+
// src/api/dto/elements/figma-nodes/figma-node.ts
|
|
3881
|
+
import { z as z135 } from "zod";
|
|
3882
|
+
var DTOFigmaNodeData = z135.object({
|
|
3883
|
+
// Id of the node in the Figma file
|
|
3884
|
+
figmaNodeId: z135.string(),
|
|
3885
|
+
// Validity
|
|
3886
|
+
isValid: z135.boolean(),
|
|
3887
|
+
// Asset data
|
|
3888
|
+
assetId: z135.string(),
|
|
3889
|
+
assetUrl: z135.string(),
|
|
3890
|
+
// Asset metadata
|
|
3891
|
+
assetScale: z135.number(),
|
|
3892
|
+
assetWidth: z135.number().optional(),
|
|
3893
|
+
assetHeight: z135.number().optional()
|
|
3894
|
+
});
|
|
3895
|
+
var DTOFigmaNode = FigmaFileStructure.omit({
|
|
3896
|
+
data: true
|
|
3897
|
+
}).extend({
|
|
3898
|
+
data: DTOFigmaNodeData
|
|
3899
|
+
});
|
|
3900
|
+
var DTOFigmaNodeCreateInput = z135.object({
|
|
3901
|
+
// Id of a design system's data source representing a linked Figma file
|
|
3902
|
+
sourceId: z135.string(),
|
|
3903
|
+
// Id of a node within the Figma file
|
|
3904
|
+
figmaFileNodeId: z135.string()
|
|
3905
|
+
});
|
|
3906
|
+
|
|
3907
|
+
// src/api/dto/elements/figma-nodes/node-actions-v2.ts
|
|
3908
|
+
var DTOFigmaNodeActionOutput = z136.object({
|
|
3909
|
+
type: z136.literal("FigmaNodeRender"),
|
|
3910
|
+
figmaNodes: z136.array(DTOFigmaNode)
|
|
3911
|
+
});
|
|
3912
|
+
var DTOFigmaNodeActionInput = z136.object({
|
|
3913
|
+
type: z136.literal("FigmaNodeRender"),
|
|
3914
|
+
input: DTOFigmaNodeCreateInput.array()
|
|
3857
3915
|
});
|
|
3858
3916
|
|
|
3859
3917
|
// src/api/dto/elements/elements-action-v2.ts
|
|
3860
|
-
import { z as
|
|
3861
|
-
var DTOElementActionOutput =
|
|
3918
|
+
import { z as z137 } from "zod";
|
|
3919
|
+
var DTOElementActionOutput = z137.discriminatedUnion("type", [
|
|
3862
3920
|
// Documentation pages
|
|
3863
3921
|
DTODocumentationPageCreateActionOutputV2,
|
|
3864
3922
|
DTODocumentationPageUpdateActionOutputV2,
|
|
@@ -3872,9 +3930,11 @@ var DTOElementActionOutput = z134.discriminatedUnion("type", [
|
|
|
3872
3930
|
DTODocumentationGroupMoveActionOutputV2,
|
|
3873
3931
|
DTODocumentationGroupDuplicateActionOutputV2,
|
|
3874
3932
|
DTODocumentationGroupDeleteActionOutputV2,
|
|
3875
|
-
DTODocumentationTabGroupDeleteActionOutputV2
|
|
3933
|
+
DTODocumentationTabGroupDeleteActionOutputV2,
|
|
3934
|
+
// // Figma frames
|
|
3935
|
+
DTOFigmaNodeActionOutput
|
|
3876
3936
|
]);
|
|
3877
|
-
var DTOElementActionInput =
|
|
3937
|
+
var DTOElementActionInput = z137.discriminatedUnion("type", [
|
|
3878
3938
|
// Documentation pages
|
|
3879
3939
|
DTODocumentationPageCreateActionInputV2,
|
|
3880
3940
|
DTODocumentationPageUpdateActionInputV2,
|
|
@@ -3888,19 +3948,21 @@ var DTOElementActionInput = z134.discriminatedUnion("type", [
|
|
|
3888
3948
|
DTODocumentationGroupMoveActionInputV2,
|
|
3889
3949
|
DTODocumentationGroupDuplicateActionInputV2,
|
|
3890
3950
|
DTODocumentationGroupDeleteActionInputV2,
|
|
3891
|
-
DTODocumentationTabGroupDeleteActionInputV2
|
|
3951
|
+
DTODocumentationTabGroupDeleteActionInputV2,
|
|
3952
|
+
// Figma frames
|
|
3953
|
+
DTOFigmaNodeActionInput
|
|
3892
3954
|
]);
|
|
3893
3955
|
|
|
3894
3956
|
// src/api/payloads/documentation/block-definitions.ts
|
|
3895
|
-
import { z as
|
|
3896
|
-
var DTOGetBlockDefinitionsOutput =
|
|
3897
|
-
definitions:
|
|
3957
|
+
import { z as z138 } from "zod";
|
|
3958
|
+
var DTOGetBlockDefinitionsOutput = z138.object({
|
|
3959
|
+
definitions: z138.array(PageBlockDefinition)
|
|
3898
3960
|
});
|
|
3899
3961
|
|
|
3900
3962
|
// src/api/payloads/liveblocks/auth.ts
|
|
3901
|
-
import { z as
|
|
3902
|
-
var DTOLiveblocksAuthRequest =
|
|
3903
|
-
room:
|
|
3963
|
+
import { z as z139 } from "zod";
|
|
3964
|
+
var DTOLiveblocksAuthRequest = z139.object({
|
|
3965
|
+
room: z139.string()
|
|
3904
3966
|
});
|
|
3905
3967
|
|
|
3906
3968
|
// src/yjs/design-system-content/documentation-hierarchy.ts
|
|
@@ -3953,13 +4015,13 @@ function getGroupsYMap(doc) {
|
|
|
3953
4015
|
}
|
|
3954
4016
|
|
|
3955
4017
|
// src/yjs/design-system-content/item-configuration.ts
|
|
3956
|
-
import { z as
|
|
3957
|
-
var DTODocumentationPageRoomHeaderData =
|
|
3958
|
-
title:
|
|
4018
|
+
import { z as z140 } from "zod";
|
|
4019
|
+
var DTODocumentationPageRoomHeaderData = z140.object({
|
|
4020
|
+
title: z140.string(),
|
|
3959
4021
|
configuration: DocumentationItemConfigurationV2
|
|
3960
4022
|
});
|
|
3961
|
-
var DTODocumentationPageRoomHeaderDataUpdate =
|
|
3962
|
-
title:
|
|
4023
|
+
var DTODocumentationPageRoomHeaderDataUpdate = z140.object({
|
|
4024
|
+
title: z140.string().optional(),
|
|
3963
4025
|
configuration: DocumentationItemConfigurationV2.omit({ header: true }).extend({ header: DocumentationItemHeaderV2.partial() }).optional()
|
|
3964
4026
|
});
|
|
3965
4027
|
function itemConfigurationToYjs(yDoc, item) {
|
|
@@ -4008,7 +4070,7 @@ function yjsToItemConfiguration(yDoc) {
|
|
|
4008
4070
|
header: rawHeader
|
|
4009
4071
|
};
|
|
4010
4072
|
return {
|
|
4011
|
-
title:
|
|
4073
|
+
title: z140.string().parse(title),
|
|
4012
4074
|
configuration: DocumentationItemConfigurationV2.parse(rawConfig)
|
|
4013
4075
|
};
|
|
4014
4076
|
}
|
|
@@ -4017,9 +4079,9 @@ function yjsToItemConfiguration(yDoc) {
|
|
|
4017
4079
|
var PageBlockEditorModel2 = PageBlockEditorModel;
|
|
4018
4080
|
|
|
4019
4081
|
// src/yjs/docs-editor/model/page.ts
|
|
4020
|
-
import { z as
|
|
4021
|
-
var DocumentationPageEditorModel =
|
|
4022
|
-
blocks:
|
|
4082
|
+
import { z as z141 } from "zod";
|
|
4083
|
+
var DocumentationPageEditorModel = z141.object({
|
|
4084
|
+
blocks: z141.array(PageBlockEditorModel2)
|
|
4023
4085
|
});
|
|
4024
4086
|
|
|
4025
4087
|
// src/yjs/docs-editor/prosemirror/schema.ts
|
|
@@ -7652,7 +7714,7 @@ var blocks = [
|
|
|
7652
7714
|
|
|
7653
7715
|
// src/yjs/docs-editor/prosemirror-to-blocks.ts
|
|
7654
7716
|
import { yXmlFragmentToProsemirrorJSON } from "y-prosemirror";
|
|
7655
|
-
import { z as
|
|
7717
|
+
import { z as z142 } from "zod";
|
|
7656
7718
|
function yDocToPage(yDoc, definitions) {
|
|
7657
7719
|
return yXmlFragmentToPage(yDoc.getXmlFragment("default"), definitions);
|
|
7658
7720
|
}
|
|
@@ -7664,7 +7726,7 @@ function prosemirrorDocToPage(prosemirrorDoc, definitions) {
|
|
|
7664
7726
|
const definitionsById = mapByUnique2(definitions, (d) => d.id);
|
|
7665
7727
|
return {
|
|
7666
7728
|
blocks: (prosemirrorDoc.content ?? []).map((prosemirrorNode) => {
|
|
7667
|
-
const definitionId = getProsemirrorAttribute(prosemirrorNode, "definitionId",
|
|
7729
|
+
const definitionId = getProsemirrorAttribute(prosemirrorNode, "definitionId", z142.string());
|
|
7668
7730
|
if (!definitionId) {
|
|
7669
7731
|
console.warn(
|
|
7670
7732
|
`definitionId on ${prosemirrorNode.type} is required to be interpreted as a block, skipping node`
|
|
@@ -7706,7 +7768,7 @@ function parseAsRichText(prosemirrorNode, definition, property) {
|
|
|
7706
7768
|
if (!id)
|
|
7707
7769
|
return null;
|
|
7708
7770
|
const variantId = getProsemirrorBlockVariantId(prosemirrorNode);
|
|
7709
|
-
const calloutType = parseCalloutType(getProsemirrorAttribute(prosemirrorNode, "type",
|
|
7771
|
+
const calloutType = parseCalloutType(getProsemirrorAttribute(prosemirrorNode, "type", z142.string().optional()));
|
|
7710
7772
|
return {
|
|
7711
7773
|
// TODO Artem: indent
|
|
7712
7774
|
id,
|
|
@@ -7806,8 +7868,8 @@ function parseRichTextAttribute(mark) {
|
|
|
7806
7868
|
case "code":
|
|
7807
7869
|
return { type: "Code" };
|
|
7808
7870
|
case "link":
|
|
7809
|
-
const itemId = getProsemirrorAttribute(mark, "itemId",
|
|
7810
|
-
const href = getProsemirrorAttribute(mark, "href",
|
|
7871
|
+
const itemId = getProsemirrorAttribute(mark, "itemId", z142.string().optional());
|
|
7872
|
+
const href = getProsemirrorAttribute(mark, "href", z142.string().optional());
|
|
7811
7873
|
return {
|
|
7812
7874
|
type: "Link",
|
|
7813
7875
|
openInNewWindow: mark.attrs?.target !== "_self",
|
|
@@ -7822,7 +7884,7 @@ function parseAsTable(prosemirrorNode, definition, property) {
|
|
|
7822
7884
|
if (!id)
|
|
7823
7885
|
return null;
|
|
7824
7886
|
const variantId = getProsemirrorBlockVariantId(prosemirrorNode);
|
|
7825
|
-
const hasBorder = getProsemirrorAttribute(prosemirrorNode, "hasBorder",
|
|
7887
|
+
const hasBorder = getProsemirrorAttribute(prosemirrorNode, "hasBorder", z142.boolean().optional()) !== false;
|
|
7826
7888
|
const tableChild = prosemirrorNode.content?.find((c) => c.type === "table");
|
|
7827
7889
|
if (!tableChild) {
|
|
7828
7890
|
return emptyTable(id, variantId, 0);
|
|
@@ -7868,9 +7930,9 @@ function parseAsTableCell(prosemirrorNode) {
|
|
|
7868
7930
|
const id = getProsemirrorBlockId(prosemirrorNode);
|
|
7869
7931
|
if (!id)
|
|
7870
7932
|
return null;
|
|
7871
|
-
const textAlign = getProsemirrorAttribute(prosemirrorNode, "textAlign",
|
|
7933
|
+
const textAlign = getProsemirrorAttribute(prosemirrorNode, "textAlign", z142.string().optional());
|
|
7872
7934
|
let columnWidth;
|
|
7873
|
-
const columnWidthArray = getProsemirrorAttribute(prosemirrorNode, "colwidth",
|
|
7935
|
+
const columnWidthArray = getProsemirrorAttribute(prosemirrorNode, "colwidth", z142.array(z142.number()).optional());
|
|
7874
7936
|
if (columnWidthArray) {
|
|
7875
7937
|
columnWidth = columnWidthArray[0];
|
|
7876
7938
|
}
|
|
@@ -7904,7 +7966,7 @@ function parseAsTableNode(prosemirrorNode) {
|
|
|
7904
7966
|
value: parseRichText(prosemirrorNode.content ?? [])
|
|
7905
7967
|
};
|
|
7906
7968
|
case "image":
|
|
7907
|
-
const url = getProsemirrorAttribute(prosemirrorNode, "src",
|
|
7969
|
+
const url = getProsemirrorAttribute(prosemirrorNode, "src", z142.string().optional());
|
|
7908
7970
|
if (!url)
|
|
7909
7971
|
return null;
|
|
7910
7972
|
return {
|
|
@@ -8001,7 +8063,7 @@ function parseAsCustomBlock(prosemirrorNode, definition) {
|
|
|
8001
8063
|
};
|
|
8002
8064
|
}
|
|
8003
8065
|
function parseBlockItems(prosemirrorNode, definition) {
|
|
8004
|
-
const itemsString = getProsemirrorAttribute(prosemirrorNode, "items",
|
|
8066
|
+
const itemsString = getProsemirrorAttribute(prosemirrorNode, "items", z142.string());
|
|
8005
8067
|
if (!itemsString)
|
|
8006
8068
|
return null;
|
|
8007
8069
|
const itemsJson = JSON.parse(itemsString);
|
|
@@ -8013,11 +8075,11 @@ function parseBlockItems(prosemirrorNode, definition) {
|
|
|
8013
8075
|
}
|
|
8014
8076
|
function parseAppearance(prosemirrorNode) {
|
|
8015
8077
|
const appearance = {};
|
|
8016
|
-
const columns = getProsemirrorAttribute(prosemirrorNode, "columns",
|
|
8078
|
+
const columns = getProsemirrorAttribute(prosemirrorNode, "columns", z142.number().optional());
|
|
8017
8079
|
if (columns) {
|
|
8018
8080
|
appearance.numberOfColumns = columns;
|
|
8019
8081
|
}
|
|
8020
|
-
const backgroundColor = getProsemirrorAttribute(prosemirrorNode, "backgroundColor",
|
|
8082
|
+
const backgroundColor = getProsemirrorAttribute(prosemirrorNode, "backgroundColor", z142.string().optional());
|
|
8021
8083
|
if (backgroundColor) {
|
|
8022
8084
|
const parsedColor = PageBlockColorV2.safeParse(JSON.parse(backgroundColor));
|
|
8023
8085
|
if (parsedColor.success) {
|
|
@@ -8108,13 +8170,13 @@ function valueSchemaForPropertyType(type) {
|
|
|
8108
8170
|
}
|
|
8109
8171
|
}
|
|
8110
8172
|
function getProsemirrorBlockId(prosemirrorNode) {
|
|
8111
|
-
const id = getProsemirrorAttribute(prosemirrorNode, "id",
|
|
8173
|
+
const id = getProsemirrorAttribute(prosemirrorNode, "id", z142.string());
|
|
8112
8174
|
if (!id)
|
|
8113
8175
|
console.warn(`Prosemirror attribute "id" on ${prosemirrorNode.type} is required`);
|
|
8114
8176
|
return id;
|
|
8115
8177
|
}
|
|
8116
8178
|
function getProsemirrorBlockVariantId(prosemirrorNode) {
|
|
8117
|
-
return getProsemirrorAttribute(prosemirrorNode, "variantId", nullishToOptional(
|
|
8179
|
+
return getProsemirrorAttribute(prosemirrorNode, "variantId", nullishToOptional(z142.string()));
|
|
8118
8180
|
}
|
|
8119
8181
|
function getProsemirrorAttribute(prosemirrorNode, attributeName, validationSchema) {
|
|
8120
8182
|
const parsedAttr = validationSchema.safeParse(prosemirrorNode.attrs?.[attributeName]);
|
|
@@ -8181,6 +8243,11 @@ export {
|
|
|
8181
8243
|
DTODuplicateDocumentationPageInputV2,
|
|
8182
8244
|
DTOElementActionInput,
|
|
8183
8245
|
DTOElementActionOutput,
|
|
8246
|
+
DTOFigmaNode,
|
|
8247
|
+
DTOFigmaNodeActionInput,
|
|
8248
|
+
DTOFigmaNodeActionOutput,
|
|
8249
|
+
DTOFigmaNodeCreateInput,
|
|
8250
|
+
DTOFigmaNodeData,
|
|
8184
8251
|
DTOGetBlockDefinitionsOutput,
|
|
8185
8252
|
DTOLiveblocksAuthRequest,
|
|
8186
8253
|
DTOMoveDocumentationGroupInput,
|