@supernova-studio/supernova-sdk-beta 2.4.6 → 2.4.11
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/build/supernova-sdk-typescript.js +1 -1
- package/build/supernova-sdk-typescript.js.map +1 -1
- package/build/types/core/SDKSupernova.d.ts +9 -0
- package/build/types/core/areas/SDKAreaActivityEvents.d.ts +7 -0
- package/build/types/core/areas/SDKAreaAgentChats.d.ts +12 -0
- package/build/types/core/areas/SDKAreaBulkOperations.d.ts +76 -74
- package/build/types/core/areas/SDKAreaDataSources.d.ts +1 -1
- package/build/types/core/areas/SDKAreaDesignSystems.d.ts +13 -13
- package/build/types/core/areas/SDKAreaDocumentation.d.ts +304 -289
- package/build/types/core/areas/SDKAreaImport.d.ts +35 -0
- package/build/types/core/areas/SDKAreaMCP.d.ts +26 -1
- package/build/types/core/areas/SDKAreaProjects.d.ts +1084 -1100
- package/build/types/core/areas/SDKAreaRawData.d.ts +1040 -1039
- package/build/types/core/areas/SDKAreaResources.d.ts +90 -90
- package/build/types/core/areas/SDKAreaSanboxes.d.ts +9 -9
- package/build/types/core/areas/SDKAreaThreads.d.ts +67 -67
- package/build/types/core/areas/SDKAreaTokens.d.ts +17 -12
- package/build/types/core/areas/SDKAreaWorkspaces.d.ts +1 -1
- package/build/types/core/data/SDKDataCore.d.ts +1771 -1746
- package/build/types/core/data/SDKDataCoreCached.d.ts +2 -2
- package/build/types/core/data/requests/SDKDataCoreReadRequests.d.ts +647 -593
- package/build/types/core/data/requests/SDKDataCoreWriteRequests.d.ts +2515 -2489
- package/build/types/core/resolvers/SDKDocsEntityItemResolver.d.ts +121 -121
- package/build/types/core/resolvers/SDKSnapshotTokenBuilder.d.ts +28 -0
- package/build/types/core/resolvers/SDKTokenResolver.d.ts +11 -9
- package/build/types/exports.d.ts +19 -11
- package/build/types/model/activity-events/SDKActivityEvent.d.ts +49 -0
- package/build/types/model/agent-chats/SDKAgentChat.d.ts +31 -0
- package/build/types/model/base/SDKDesignSystem.d.ts +3 -1
- package/build/types/model/datasets/SDKDataset.d.ts +15 -5
- package/build/types/model/docs/blocks/definition/SDKDocsBlockBehavior.d.ts +4 -1
- package/build/types/model/docs/blocks/definition/actual/context-mcp/SDKDocsBlockActualContextMcp.d.ts +2 -0
- package/build/types/model/docs/blocks/properties/SDKDocsBlockAssetProperty.d.ts +7 -24
- package/build/types/model/docs/blocks/properties/SDKDocsBlockAssetPropertyProperty.d.ts +3 -2
- package/build/types/model/docs/blocks/properties/SDKDocsBlockBooleanProperty.d.ts +3 -2
- package/build/types/model/docs/blocks/properties/SDKDocsBlockCodeProperty.d.ts +3 -6
- package/build/types/model/docs/blocks/properties/SDKDocsBlockCodeSandboxProperty.d.ts +3 -8
- package/build/types/model/docs/blocks/properties/SDKDocsBlockColorProperty.d.ts +3 -3
- package/build/types/model/docs/blocks/properties/SDKDocsBlockComponentProperty.d.ts +7 -10
- package/build/types/model/docs/blocks/properties/SDKDocsBlockComponentPropertyProperty.d.ts +3 -2
- package/build/types/model/docs/blocks/properties/SDKDocsBlockContextProperty.d.ts +16 -0
- package/build/types/model/docs/blocks/properties/SDKDocsBlockDividerProperty.d.ts +3 -2
- package/build/types/model/docs/blocks/properties/SDKDocsBlockEmbedUrlProperty.d.ts +3 -6
- package/build/types/model/docs/blocks/properties/SDKDocsBlockFigmaComponentProperty.d.ts +7 -26
- package/build/types/model/docs/blocks/properties/SDKDocsBlockFigmaNodeProperty.d.ts +7 -22
- package/build/types/model/docs/blocks/properties/SDKDocsBlockFileProperty.d.ts +4 -9
- package/build/types/model/docs/blocks/properties/SDKDocsBlockImageProperty.d.ts +3 -10
- package/build/types/model/docs/blocks/properties/SDKDocsBlockMarkdownProperty.d.ts +3 -2
- package/build/types/model/docs/blocks/properties/SDKDocsBlockMultiRichTextProperty.d.ts +3 -3
- package/build/types/model/docs/blocks/properties/SDKDocsBlockMultiSelectProperty.d.ts +3 -2
- package/build/types/model/docs/blocks/properties/SDKDocsBlockNumberProperty.d.ts +3 -2
- package/build/types/model/docs/blocks/properties/SDKDocsBlockProperty.d.ts +3 -3
- package/build/types/model/docs/blocks/properties/SDKDocsBlockRichTextEditorProperty.d.ts +3 -3
- package/build/types/model/docs/blocks/properties/SDKDocsBlockRichTextProperty.d.ts +3 -7
- package/build/types/model/docs/blocks/properties/SDKDocsBlockSingleSelectProperty.d.ts +3 -2
- package/build/types/model/docs/blocks/properties/SDKDocsBlockStorybookProperty.d.ts +4 -22
- package/build/types/model/docs/blocks/properties/SDKDocsBlockTableProperty.d.ts +12 -28
- package/build/types/model/docs/blocks/properties/SDKDocsBlockTextProperty.d.ts +3 -2
- package/build/types/model/docs/blocks/properties/SDKDocsBlockTokenProperty.d.ts +7 -31
- package/build/types/model/docs/blocks/properties/SDKDocsBlockTokenPropertyProperty.d.ts +3 -2
- package/build/types/model/docs/blocks/properties/SDKDocsBlockTokenTypeProperty.d.ts +3 -3
- package/build/types/model/docs/blocks/properties/SDKDocsBlockUrlProperty.d.ts +3 -2
- package/build/types/model/docs/sections/SDKDocsSection.d.ts +0 -31
- package/build/types/model/documentation/SDKPageHistoryVersion.d.ts +20 -0
- package/build/types/model/documentation/blocks/SDKDocumentationLegacyPageBlockContextMcp.d.ts +11 -0
- package/build/types/model/elements/SDKElementPropertyOption.d.ts +1 -2
- package/build/types/model/enums/SDKCodeLanguage.d.ts +1 -1
- package/build/types/model/enums/SDKDesignSystemRole.d.ts +1 -2
- package/build/types/model/enums/SDKDocsBlockBehaviorSelectionType.d.ts +4 -2
- package/build/types/model/enums/SDKDocsBlockContainerSize.d.ts +6 -4
- package/build/types/model/enums/SDKDocsBlockItemPropertyType.d.ts +3 -1
- package/build/types/model/enums/SDKDocumentationLegacyPageBlockType.d.ts +1 -0
- package/build/types/model/enums/SDKTokenType.d.ts +2 -0
- package/build/types/model/enums/SDKWorkspaceSeatType.d.ts +14 -3
- package/build/types/model/exporters/SDKExporter.d.ts +2 -2
- package/build/types/model/exporters/SDKPipeline.d.ts +1 -1
- package/build/types/model/membership/SDKMembership.d.ts +1 -1
- package/build/types/model/support/SDKSource.d.ts +4 -3
- package/build/types/model/themes/SDKTokenThemeOverride.d.ts +1 -0
- package/build/types/model/tokens/remote/SDKRemoteTokenModel.d.ts +34 -1
- package/build/types/model/tokens/remote/SDKRemoteTokenValue.d.ts +1 -1
- package/build/types/model/workspaces/SDKWorkspaceProductPrice.d.ts +6 -3
- package/build/types/model/workspaces/SDKWorkspaceSubscription.d.ts +2 -6
- package/build/types/tools/design-tokens/SDKToolsDesignTokensPlugin.d.ts +6 -3
- package/build/types/tools/design-tokens/utilities/SDKDTJSONConverter.d.ts +29 -3
- package/build/types/tools/design-tokens/utilities/SDKDTJSONLoader.d.ts +2 -0
- package/build/types/tools/design-tokens/utilities/SDKDTMapLoader.d.ts +31 -0
- package/build/types/tools/design-tokens/utilities/SDKDTTokenReferenceResolver.d.ts +2 -0
- package/build/types/tools/design-tokens/utilities/unresolvable-modes/index.d.ts +4 -0
- package/build/types/tools/design-tokens/utilities/unresolvable-modes/lenient-resolve.d.ts +2 -0
- package/build/types/tools/design-tokens/utilities/unresolvable-modes/placeholder.d.ts +2 -0
- package/build/types/tools/design-tokens/utilities/unresolvable-modes/preserve.d.ts +2 -0
- package/build/types/tools/design-tokens/utilities/unresolvable-modes/strict.d.ts +2 -0
- package/build/types/tools/design-tokens/utilities/unresolvable-modes/types.d.ts +33 -0
- package/build/types/tools/docs-block-builder/SDKDocsBlockBuilder.d.ts +9 -0
- package/build/types/tools/json-builder/elements-transformers/SDKToolsJSONElementTransformer.d.ts +1 -1
- package/build/types/utils/TokenUtils.d.ts +1 -1
- package/package.json +17 -21
- package/build/types/model/enums/SDKDocsBlockTokenNameFormat.d.ts +0 -10
|
@@ -61,139 +61,139 @@ export declare class AreaResources {
|
|
|
61
61
|
/** Uploads new font resources */
|
|
62
62
|
uploadFontResources(from: RemoteVersionIdentifier, fonts: FileList): Promise<ResourceFont[]>;
|
|
63
63
|
initializeFileUpload(from: RemoteVersionIdentifier, fileUploadItems: DTOFileUploadPayload["files"]): Promise<{
|
|
64
|
-
files
|
|
65
|
-
|
|
64
|
+
files: {
|
|
65
|
+
fileId: string;
|
|
66
|
+
referencePersistentId: string;
|
|
67
|
+
name: string;
|
|
68
|
+
checksum: string;
|
|
69
|
+
url: string;
|
|
70
|
+
size: number;
|
|
66
71
|
pendingUpload?: boolean;
|
|
67
|
-
url?: string;
|
|
68
|
-
size?: number;
|
|
69
|
-
fileId?: string;
|
|
70
|
-
referencePersistentId?: string;
|
|
71
|
-
checksum?: string;
|
|
72
72
|
}[];
|
|
73
|
-
uploadUrls
|
|
74
|
-
fileId
|
|
75
|
-
uploadUrl
|
|
73
|
+
uploadUrls: {
|
|
74
|
+
fileId: string;
|
|
75
|
+
uploadUrl: string;
|
|
76
76
|
}[];
|
|
77
77
|
}>;
|
|
78
78
|
initializeProjectFileUpload(workspaceId: string, projectId: string, fileUploadItems: DTOForgeProjectFileUploadPayload["files"]): Promise<{
|
|
79
|
-
files
|
|
80
|
-
id
|
|
81
|
-
name
|
|
79
|
+
files: {
|
|
80
|
+
id: string;
|
|
81
|
+
name: string;
|
|
82
|
+
checksum: string;
|
|
83
|
+
url: string;
|
|
84
|
+
size: number;
|
|
82
85
|
pendingUpload?: boolean;
|
|
83
|
-
url?: string;
|
|
84
|
-
size?: number;
|
|
85
|
-
checksum?: string;
|
|
86
86
|
}[];
|
|
87
|
-
uploadUrls
|
|
88
|
-
fileId
|
|
89
|
-
uploadUrl
|
|
87
|
+
uploadUrls: {
|
|
88
|
+
fileId: string;
|
|
89
|
+
uploadUrl: string;
|
|
90
90
|
}[];
|
|
91
91
|
}>;
|
|
92
92
|
initializeBulkFileUpload(input: DTOFileUploadBulkPayload): Promise<{
|
|
93
|
-
files
|
|
94
|
-
id
|
|
95
|
-
name
|
|
93
|
+
files: {
|
|
94
|
+
id: string;
|
|
95
|
+
name: string;
|
|
96
|
+
deduplicationKey: string;
|
|
97
|
+
storagePath: string;
|
|
98
|
+
url: string;
|
|
99
|
+
size: number;
|
|
100
|
+
pendingUpload?: boolean;
|
|
96
101
|
source?: {
|
|
97
|
-
type
|
|
98
|
-
userId
|
|
102
|
+
type: "UserUpload";
|
|
103
|
+
userId: string;
|
|
99
104
|
} | {
|
|
100
|
-
type
|
|
101
|
-
renderMode
|
|
105
|
+
type: "Figma";
|
|
106
|
+
renderMode: "Image" | "HTML" | "JSON";
|
|
102
107
|
};
|
|
103
|
-
deduplicationKey?: string;
|
|
104
|
-
pendingUpload?: boolean;
|
|
105
|
-
storagePath?: string;
|
|
106
|
-
url?: string;
|
|
107
|
-
size?: number;
|
|
108
108
|
}[];
|
|
109
|
-
uploadUrls
|
|
110
|
-
fileId
|
|
111
|
-
uploadUrl
|
|
109
|
+
uploadUrls: {
|
|
110
|
+
fileId: string;
|
|
111
|
+
uploadUrl: string;
|
|
112
112
|
}[];
|
|
113
113
|
}>;
|
|
114
114
|
finalizeFileUpload(from: RemoteVersionIdentifier, fileIds: Array<string>): Promise<{
|
|
115
|
-
ok
|
|
115
|
+
ok: true;
|
|
116
116
|
}>;
|
|
117
117
|
finalizeProjectFileUpload(workspaceId: string, projectId: string, fileIds: Array<string>): Promise<{
|
|
118
|
-
ok
|
|
118
|
+
ok: true;
|
|
119
119
|
}>;
|
|
120
120
|
finalizeBulkFileUpload(input: DTOFileFinalizeBulkPayload): Promise<{
|
|
121
|
-
files
|
|
122
|
-
id
|
|
123
|
-
name
|
|
121
|
+
files: {
|
|
122
|
+
id: string;
|
|
123
|
+
name: string;
|
|
124
|
+
deduplicationKey: string;
|
|
125
|
+
storagePath: string;
|
|
126
|
+
url: string;
|
|
127
|
+
size: number;
|
|
128
|
+
pendingUpload?: boolean;
|
|
124
129
|
source?: {
|
|
125
|
-
type
|
|
126
|
-
userId
|
|
130
|
+
type: "UserUpload";
|
|
131
|
+
userId: string;
|
|
127
132
|
} | {
|
|
128
|
-
type
|
|
129
|
-
renderMode
|
|
133
|
+
type: "Figma";
|
|
134
|
+
renderMode: "Image" | "HTML" | "JSON";
|
|
130
135
|
};
|
|
131
|
-
deduplicationKey?: string;
|
|
132
|
-
pendingUpload?: boolean;
|
|
133
|
-
storagePath?: string;
|
|
134
|
-
url?: string;
|
|
135
|
-
size?: number;
|
|
136
136
|
}[];
|
|
137
137
|
}>;
|
|
138
138
|
validateFigmaNodeAccess(input: DTOForgeFigmaNodeCreateRequest): Promise<boolean>;
|
|
139
139
|
exportFigmaNode(input: DTOForgeFigmaNodeCreateRequest): Promise<{
|
|
140
|
-
figmaNode
|
|
141
|
-
id
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
140
|
+
figmaNode: {
|
|
141
|
+
id: string;
|
|
142
|
+
state: "Success" | "Failed" | "Optimizing";
|
|
143
|
+
origin: {
|
|
144
|
+
fileId: string;
|
|
145
|
+
fileName: string;
|
|
146
|
+
fileLastEditedAt: string;
|
|
147
|
+
nodeId: string;
|
|
148
|
+
nodeName: string;
|
|
149
|
+
};
|
|
150
|
+
thumbnail: {
|
|
151
|
+
id: string;
|
|
152
|
+
url: string;
|
|
145
153
|
source?: {
|
|
146
|
-
type
|
|
147
|
-
userId
|
|
154
|
+
type: "UserUpload";
|
|
155
|
+
userId: string;
|
|
148
156
|
} | {
|
|
149
|
-
type
|
|
150
|
-
renderMode
|
|
157
|
+
type: "Figma";
|
|
158
|
+
renderMode: "Image" | "HTML" | "JSON";
|
|
151
159
|
};
|
|
152
|
-
url?: string;
|
|
153
|
-
};
|
|
154
|
-
state?: "Success" | "Failed" | "Optimizing";
|
|
155
|
-
origin?: {
|
|
156
|
-
nodeId?: string;
|
|
157
|
-
fileId?: string;
|
|
158
|
-
fileName?: string;
|
|
159
|
-
fileLastEditedAt?: string;
|
|
160
|
-
nodeName?: string;
|
|
161
|
-
};
|
|
162
|
-
thumbnail?: {
|
|
163
|
-
id?: string;
|
|
164
160
|
name?: string;
|
|
161
|
+
};
|
|
162
|
+
json: {
|
|
163
|
+
id: string;
|
|
164
|
+
url: string;
|
|
165
165
|
source?: {
|
|
166
|
-
type
|
|
167
|
-
userId
|
|
166
|
+
type: "UserUpload";
|
|
167
|
+
userId: string;
|
|
168
168
|
} | {
|
|
169
|
-
type
|
|
170
|
-
renderMode
|
|
169
|
+
type: "Figma";
|
|
170
|
+
renderMode: "Image" | "HTML" | "JSON";
|
|
171
171
|
};
|
|
172
|
-
url?: string;
|
|
173
|
-
};
|
|
174
|
-
json?: {
|
|
175
|
-
id?: string;
|
|
176
172
|
name?: string;
|
|
173
|
+
};
|
|
174
|
+
html: {
|
|
175
|
+
id: string;
|
|
176
|
+
url: string;
|
|
177
177
|
source?: {
|
|
178
|
-
type
|
|
179
|
-
userId
|
|
178
|
+
type: "UserUpload";
|
|
179
|
+
userId: string;
|
|
180
180
|
} | {
|
|
181
|
-
type
|
|
182
|
-
renderMode
|
|
181
|
+
type: "Figma";
|
|
182
|
+
renderMode: "Image" | "HTML" | "JSON";
|
|
183
183
|
};
|
|
184
|
-
url?: string;
|
|
185
|
-
};
|
|
186
|
-
html?: {
|
|
187
|
-
id?: string;
|
|
188
184
|
name?: string;
|
|
185
|
+
};
|
|
186
|
+
code?: {
|
|
187
|
+
id: string;
|
|
188
|
+
url: string;
|
|
189
189
|
source?: {
|
|
190
|
-
type
|
|
191
|
-
userId
|
|
190
|
+
type: "UserUpload";
|
|
191
|
+
userId: string;
|
|
192
192
|
} | {
|
|
193
|
-
type
|
|
194
|
-
renderMode
|
|
193
|
+
type: "Figma";
|
|
194
|
+
renderMode: "Image" | "HTML" | "JSON";
|
|
195
195
|
};
|
|
196
|
-
|
|
196
|
+
name?: string;
|
|
197
197
|
};
|
|
198
198
|
};
|
|
199
199
|
}>;
|
|
@@ -8,18 +8,18 @@ export declare class AreaSandboxes {
|
|
|
8
8
|
designSystemId?: string;
|
|
9
9
|
}): Promise<SandboxTemplate[]>;
|
|
10
10
|
sandboxKeepAlive(workspaceId: string, projectId: string, featureId: string, sandboxId: string): Promise<{
|
|
11
|
-
id
|
|
12
|
-
url
|
|
11
|
+
id: string;
|
|
12
|
+
url: string;
|
|
13
|
+
currentIterationId: string;
|
|
14
|
+
featureId: string;
|
|
15
|
+
expiresAt: string;
|
|
16
|
+
parentMessageId?: string;
|
|
13
17
|
error?: {
|
|
14
|
-
stage
|
|
15
|
-
errorDescription
|
|
18
|
+
stage: "PackageInstall" | "HealthCheck" | "Build" | "Unknown";
|
|
19
|
+
errorDescription: string;
|
|
16
20
|
};
|
|
17
|
-
parentMessageId?: string;
|
|
18
|
-
currentIterationId?: string;
|
|
19
|
-
featureId?: string;
|
|
20
|
-
expiresAt?: string;
|
|
21
21
|
}>;
|
|
22
22
|
provisionSandbox(workspaceId: string, projectId: string, featureId: string, parentMessageId?: string): Promise<{
|
|
23
|
-
ok
|
|
23
|
+
ok: boolean;
|
|
24
24
|
}>;
|
|
25
25
|
}
|
|
@@ -45,111 +45,111 @@ export declare class AreaThreads {
|
|
|
45
45
|
* @returns Finalize input
|
|
46
46
|
*/
|
|
47
47
|
finalizeMessage(threadId: string, input: DTOThreadMessageFinalizeInput): Promise<{
|
|
48
|
-
message
|
|
49
|
-
id
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
threadId?: string;
|
|
48
|
+
message: {
|
|
49
|
+
id: string;
|
|
50
|
+
threadId: string;
|
|
51
|
+
body: string;
|
|
52
|
+
createdAt: string;
|
|
54
53
|
sender?: {
|
|
55
|
-
type
|
|
56
|
-
userId
|
|
54
|
+
type: "User";
|
|
55
|
+
userId: string;
|
|
57
56
|
} | {
|
|
58
|
-
type
|
|
59
|
-
agentType
|
|
57
|
+
type: "Agent";
|
|
58
|
+
agentType: "Ask" | "Document" | "Prototype" | "ReleaseNotes";
|
|
60
59
|
} | {
|
|
61
|
-
type
|
|
62
|
-
onBehalfOfUserId
|
|
60
|
+
type: "System";
|
|
61
|
+
onBehalfOfUserId: string;
|
|
63
62
|
};
|
|
64
|
-
body?: string;
|
|
65
63
|
isPrompt?: boolean;
|
|
66
64
|
isRetry?: boolean;
|
|
67
65
|
startsNewThread?: boolean;
|
|
66
|
+
parentMessageId?: string;
|
|
68
67
|
agentResponseTrackerId?: string;
|
|
69
68
|
attachments?: {
|
|
69
|
+
iterationId?: string;
|
|
70
70
|
files?: {
|
|
71
|
-
id
|
|
72
|
-
|
|
71
|
+
id: string;
|
|
72
|
+
url: string;
|
|
73
73
|
source?: {
|
|
74
|
-
type
|
|
75
|
-
userId
|
|
74
|
+
type: "UserUpload";
|
|
75
|
+
userId: string;
|
|
76
76
|
} | {
|
|
77
|
-
type
|
|
78
|
-
renderMode
|
|
77
|
+
type: "Figma";
|
|
78
|
+
renderMode: "Image" | "HTML" | "JSON";
|
|
79
79
|
};
|
|
80
|
-
|
|
80
|
+
name?: string;
|
|
81
81
|
}[];
|
|
82
|
+
templateId?: string;
|
|
82
83
|
figmaNodes?: {
|
|
83
|
-
id
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
84
|
+
id: string;
|
|
85
|
+
state: "Success" | "Failed" | "Optimizing";
|
|
86
|
+
origin: {
|
|
87
|
+
fileId: string;
|
|
88
|
+
fileName: string;
|
|
89
|
+
fileLastEditedAt: string;
|
|
90
|
+
nodeId: string;
|
|
91
|
+
nodeName: string;
|
|
92
|
+
};
|
|
93
|
+
thumbnail: {
|
|
94
|
+
id: string;
|
|
95
|
+
url: string;
|
|
87
96
|
source?: {
|
|
88
|
-
type
|
|
89
|
-
userId
|
|
97
|
+
type: "UserUpload";
|
|
98
|
+
userId: string;
|
|
90
99
|
} | {
|
|
91
|
-
type
|
|
92
|
-
renderMode
|
|
100
|
+
type: "Figma";
|
|
101
|
+
renderMode: "Image" | "HTML" | "JSON";
|
|
93
102
|
};
|
|
94
|
-
url?: string;
|
|
95
|
-
};
|
|
96
|
-
state?: "Success" | "Failed" | "Optimizing";
|
|
97
|
-
origin?: {
|
|
98
|
-
nodeId?: string;
|
|
99
|
-
fileId?: string;
|
|
100
|
-
fileName?: string;
|
|
101
|
-
fileLastEditedAt?: string;
|
|
102
|
-
nodeName?: string;
|
|
103
|
-
};
|
|
104
|
-
thumbnail?: {
|
|
105
|
-
id?: string;
|
|
106
103
|
name?: string;
|
|
104
|
+
};
|
|
105
|
+
json: {
|
|
106
|
+
id: string;
|
|
107
|
+
url: string;
|
|
107
108
|
source?: {
|
|
108
|
-
type
|
|
109
|
-
userId
|
|
109
|
+
type: "UserUpload";
|
|
110
|
+
userId: string;
|
|
110
111
|
} | {
|
|
111
|
-
type
|
|
112
|
-
renderMode
|
|
112
|
+
type: "Figma";
|
|
113
|
+
renderMode: "Image" | "HTML" | "JSON";
|
|
113
114
|
};
|
|
114
|
-
url?: string;
|
|
115
|
-
};
|
|
116
|
-
json?: {
|
|
117
|
-
id?: string;
|
|
118
115
|
name?: string;
|
|
116
|
+
};
|
|
117
|
+
html: {
|
|
118
|
+
id: string;
|
|
119
|
+
url: string;
|
|
119
120
|
source?: {
|
|
120
|
-
type
|
|
121
|
-
userId
|
|
121
|
+
type: "UserUpload";
|
|
122
|
+
userId: string;
|
|
122
123
|
} | {
|
|
123
|
-
type
|
|
124
|
-
renderMode
|
|
124
|
+
type: "Figma";
|
|
125
|
+
renderMode: "Image" | "HTML" | "JSON";
|
|
125
126
|
};
|
|
126
|
-
url?: string;
|
|
127
|
-
};
|
|
128
|
-
html?: {
|
|
129
|
-
id?: string;
|
|
130
127
|
name?: string;
|
|
128
|
+
};
|
|
129
|
+
code?: {
|
|
130
|
+
id: string;
|
|
131
|
+
url: string;
|
|
131
132
|
source?: {
|
|
132
|
-
type
|
|
133
|
-
userId
|
|
133
|
+
type: "UserUpload";
|
|
134
|
+
userId: string;
|
|
134
135
|
} | {
|
|
135
|
-
type
|
|
136
|
-
renderMode
|
|
136
|
+
type: "Figma";
|
|
137
|
+
renderMode: "Image" | "HTML" | "JSON";
|
|
137
138
|
};
|
|
138
|
-
|
|
139
|
+
name?: string;
|
|
139
140
|
};
|
|
140
141
|
}[];
|
|
141
|
-
iterationId?: string;
|
|
142
|
-
templateId?: string;
|
|
143
142
|
};
|
|
144
143
|
annotations?: {
|
|
145
|
-
prompt
|
|
146
|
-
elements
|
|
147
|
-
xpath
|
|
148
|
-
line
|
|
144
|
+
prompt: string;
|
|
145
|
+
elements: {
|
|
146
|
+
xpath: string;
|
|
147
|
+
line: string;
|
|
149
148
|
}[];
|
|
150
149
|
}[];
|
|
151
150
|
replyToMessageId?: string;
|
|
152
151
|
promptMetadata?: Record<string, any>;
|
|
152
|
+
updatedAt?: string;
|
|
153
153
|
};
|
|
154
154
|
}>;
|
|
155
155
|
}
|
|
@@ -4,6 +4,7 @@ import { ElementDataView } from "../../model/elements/SDKElementDataView";
|
|
|
4
4
|
import { ElementDataViewColumn } from "../../model/elements/SDKElementDataViewColumn";
|
|
5
5
|
import { ElementProperty, ElementPropertyCreationModel, ElementPropertyUpdateModel } from "../../model/elements/SDKElementProperty";
|
|
6
6
|
import { ElementPropertyValue } from "../../model/elements/values/SDKElementPropertyValue";
|
|
7
|
+
import { ActivityEventOptions } from "../data/requests/SDKDataCoreWriteRequests";
|
|
7
8
|
import { TokenType } from "../../model/enums/SDKTokenType";
|
|
8
9
|
import { TokenGroup } from "../../model/groups/SDKTokenGroup";
|
|
9
10
|
import { TokenTheme } from "../../model/themes/SDKTokenTheme";
|
|
@@ -28,7 +29,7 @@ export declare class AreaTokens {
|
|
|
28
29
|
getTokens(from: RemoteVersionIdentifier, filter?: {
|
|
29
30
|
type?: TokenType;
|
|
30
31
|
brandId?: string;
|
|
31
|
-
}): Promise<Array<
|
|
32
|
+
}): Promise<Array<AnyToken>>;
|
|
32
33
|
/** Retrieves all occurances of the specified token in the version - its usages in other tokens, components and documentation pages
|
|
33
34
|
* @param from - Remote version to fetch from
|
|
34
35
|
* @param idInVersion - Token to check for references
|
|
@@ -77,7 +78,11 @@ export declare class AreaTokens {
|
|
|
77
78
|
* @returns All token collections in the specified version
|
|
78
79
|
*/
|
|
79
80
|
getTokenCollections(from: RemoteVersionIdentifier): Promise<Array<DesignSystemCollection>>;
|
|
80
|
-
/** Creates remote token.
|
|
81
|
+
/** Creates remote token. The token's own persistent id is sent to the server, so this method can only be used once per token. Calling it for a token that already exists remotely will result in error
|
|
82
|
+
*
|
|
83
|
+
* Both `id` and `idInVersion` are written back onto the passed token from the server response.
|
|
84
|
+
*
|
|
85
|
+
* Only the token itself is written. To create it together with theme overrides or property values, use `bulkOperations.updateTokenData` with `tokenMode: "create"`.
|
|
81
86
|
* @param to - Remote version to write to
|
|
82
87
|
* @param token - Token to create
|
|
83
88
|
* @param parentId - Id of the group to add the token to. This is id of the group, not the versioned id
|
|
@@ -92,7 +97,7 @@ export declare class AreaTokens {
|
|
|
92
97
|
* @returns New token of the specified type, filled with default values
|
|
93
98
|
*/
|
|
94
99
|
createLocalToken<T extends TokenType>(tokenType: T, versionId: string, brandId: string, properties: Array<ElementProperty>): TokenTypeMapToken[T];
|
|
95
|
-
/** Creates local token override. This theme override doesn't have id associated with it on remote
|
|
100
|
+
/** Creates local token override. This theme override doesn't have id associated with it on remote — convert it with `TokenTheme.toWriteOverrideObject` and pass the result to `bulkOperations.updateTokenData` as a theme value to store it in design system
|
|
96
101
|
* @param tokenType - Type of token to create
|
|
97
102
|
* @returns New token of the specified type, filled with default values
|
|
98
103
|
*/
|
|
@@ -217,20 +222,20 @@ export declare class AreaTokens {
|
|
|
217
222
|
*/
|
|
218
223
|
deleteTokenTheme(to: RemoteVersionIdentifier, idInVersion: string): Promise<void>;
|
|
219
224
|
/** Warning: INTERNAL, DO NOT USE YET, NOT STABLE INTERFACE. Write tokens in bulk */
|
|
220
|
-
writeTokens(to: RemoteVersionIdentifier, tokens: Array<Token>, groups: Array<TokenGroup>, deleteTokens: Array<Token>, deleteTokenGroups: Array<TokenGroup
|
|
225
|
+
writeTokens(to: RemoteVersionIdentifier, tokens: Array<Token>, groups: Array<TokenGroup>, deleteTokens: Array<Token>, deleteTokenGroups: Array<TokenGroup>, activityEventOptions?: ActivityEventOptions): Promise<void>;
|
|
221
226
|
/** Warning: INTERNAL, DO NOT USE YET, NOT STABLE INTERFACE. Write theme in bulk */
|
|
222
|
-
writeTheme(to: RemoteVersionIdentifier, theme: TokenTheme): Promise<void>;
|
|
227
|
+
writeTheme(to: RemoteVersionIdentifier, theme: TokenTheme, activityEventOptions?: ActivityEventOptions): Promise<void>;
|
|
223
228
|
/** Resolves tokens by applying themes to them and retrieves new token set where values correctly correspond to that theme */
|
|
224
|
-
computeTokensByApplyingThemes(allTokens: Array<Token>, tokens: Array<Token>, themes: Array<TokenTheme>): Array<
|
|
225
|
-
computeInnerReferencesByApplyingThemesEfficient(tokensIndex: Map<string, Token>, themeOverridesIndex: Record<string, Map<string, Token>>, tokens: Array<Token>, themes: Array<TokenTheme>): Array<
|
|
229
|
+
computeTokensByApplyingThemes(allTokens: Array<Token>, tokens: Array<Token>, themes: Array<TokenTheme>): Array<AnyToken>;
|
|
230
|
+
computeInnerReferencesByApplyingThemesEfficient(tokensIndex: Map<string, Token>, themeOverridesIndex: Record<string, Map<string, Token>>, tokens: Array<Token>, themes: Array<TokenTheme>): Array<AnyToken>;
|
|
226
231
|
private computeSingleTokenValueFromReferenceByApplyingThemes;
|
|
227
|
-
computeTokensByApplyingThemesEfficient(tokensIndex: Map<string, Token>, themeOverridesIndex: Record<string, Map<string, Token>>, tokens: Array<Token>, themes: Array<TokenTheme>): Array<
|
|
232
|
+
computeTokensByApplyingThemesEfficient(tokensIndex: Map<string, Token>, themeOverridesIndex: Record<string, Map<string, Token>>, tokens: Array<Token>, themes: Array<TokenTheme>): Array<AnyToken>;
|
|
228
233
|
/** Separates groups by types */
|
|
229
|
-
computeGroupTrees(groups: Array<TokenGroup>):
|
|
234
|
+
computeGroupTrees(groups: Array<TokenGroup>): Map<TokenType, Array<TokenGroup>>;
|
|
230
235
|
/** Get determistic mocked token data. Must be used with mocked token groups */
|
|
231
|
-
getMockedTokens(from: RemoteBrandIdentifier):
|
|
236
|
+
getMockedTokens(from: RemoteBrandIdentifier): Array<AnyToken>;
|
|
232
237
|
/** Get determistic mocked token group data. Must be used with mocked tokens */
|
|
233
|
-
getMockedTokenGroups(from: RemoteBrandIdentifier):
|
|
238
|
+
getMockedTokenGroups(from: RemoteBrandIdentifier): Array<TokenGroup>;
|
|
234
239
|
/** Get determistic mocked token data views. Must be used with mocked tokens */
|
|
235
|
-
getMockedTokenDataViews(
|
|
240
|
+
getMockedTokenDataViews(_from: RemoteVersionIdentifier): Array<ElementDataView>;
|
|
236
241
|
}
|
|
@@ -132,7 +132,7 @@ export declare class AreaWorkspaces {
|
|
|
132
132
|
* @returns boolean - true if the workspace has available credits, false otherwise
|
|
133
133
|
*/
|
|
134
134
|
getWorkspaceCreditsAvailability(workspaceId: string): Promise<{
|
|
135
|
-
canSpendCredits
|
|
135
|
+
canSpendCredits: boolean;
|
|
136
136
|
}>;
|
|
137
137
|
/** Creates new workspace and retrieves the newly created workspace object. The user who creates the workspace becomes its owner
|
|
138
138
|
* @param name - Name of the workspace
|