@supernova-studio/supernova-sdk-beta 1.6.10 → 1.6.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/sdk-typescript/src/browser-bundle.d.ts +1 -1
- package/build/sdk-typescript/src/core/SDKSupernova.d.ts +45 -39
- package/build/sdk-typescript/src/core/areas/SDKAreaAssets.d.ts +35 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaBrands.d.ts +18 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaBulkOperations.d.ts +31 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaComponents.d.ts +43 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaDataSources.d.ts +18 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaDesignSystems.d.ts +17 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaDocumentation.d.ts +50 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaIntegrations.d.ts +26 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaMe.d.ts +22 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaPipelines.d.ts +36 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaTokenValues.d.ts +140 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaTokens.d.ts +217 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaUsers.d.ts +6 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaVersions.d.ts +14 -0
- package/build/sdk-typescript/src/core/areas/SDKAreaWorkspaces.d.ts +114 -0
- package/build/sdk-typescript/src/core/areas/SDKRemoteIdentifiers.d.ts +25 -0
- package/build/sdk-typescript/src/core/data/SDKDataBridge.d.ts +16 -17
- package/build/sdk-typescript/src/core/data/SDKDataCore.d.ts +209 -134
- package/build/sdk-typescript/src/core/data/requests/SDKDataCoreReadRequests.d.ts +124 -0
- package/build/sdk-typescript/src/core/data/requests/SDKDataCoreRenderRequests.d.ts +18 -0
- package/build/sdk-typescript/src/core/data/requests/SDKDataCoreWriteRequests.d.ts +73 -0
- package/build/sdk-typescript/src/core/errors/SDKSupernovaError.d.ts +41 -20
- package/build/sdk-typescript/src/core/resolvers/SDKAssetGroupResolver.d.ts +1 -1
- package/build/sdk-typescript/src/core/resolvers/SDKComponentGroupResolver.d.ts +13 -0
- package/build/sdk-typescript/src/core/resolvers/SDKComponentResolver.d.ts +5 -6
- package/build/sdk-typescript/src/core/resolvers/SDKDesignComponentGroupResolver.d.ts +1 -4
- package/build/sdk-typescript/src/core/resolvers/SDKDocumentationItemResolver.d.ts +6 -8
- package/build/sdk-typescript/src/core/resolvers/SDKTokenGroupResolver.d.ts +1 -2
- package/build/sdk-typescript/src/core/resolvers/SDKTokenResolver.d.ts +73 -45
- package/build/sdk-typescript/src/exports.d.ts +143 -117
- package/build/sdk-typescript/src/index.d.ts +1 -1
- package/build/sdk-typescript/src/model/acl/SDKAcl.d.ts +51 -0
- package/build/sdk-typescript/src/model/assets/SDKRenderedAsset.d.ts +5 -5
- package/build/sdk-typescript/src/model/base/SDKBrand.d.ts +30 -0
- package/build/sdk-typescript/src/model/base/SDKDesignSystem.d.ts +56 -0
- package/build/sdk-typescript/src/model/base/SDKDesignSystemVersion.d.ts +40 -0
- package/build/sdk-typescript/src/model/base/SDKDocumentation.d.ts +10 -0
- package/build/sdk-typescript/src/model/components/SDKComponent.d.ts +4 -4
- package/build/sdk-typescript/src/model/components/SDKDesignComponent.d.ts +4 -4
- package/build/sdk-typescript/src/model/documentation/SDKDocumentationConfiguration.d.ts +5 -5
- package/build/sdk-typescript/src/model/documentation/SDKDocumentationGroup.d.ts +2 -2
- package/build/sdk-typescript/src/model/documentation/SDKDocumentationItem.d.ts +2 -2
- package/build/sdk-typescript/src/model/documentation/SDKDocumentationPage.d.ts +4 -4
- package/build/sdk-typescript/src/model/documentation/SDKDocumentationPageAsset.d.ts +4 -4
- package/build/sdk-typescript/src/model/documentation/SDKDocumentationPageBlock.d.ts +4 -6
- package/build/sdk-typescript/src/model/documentation/SDKDocumentationRichText.d.ts +3 -3
- package/build/sdk-typescript/src/model/documentation/SDKDocumentationRichTextSpan.d.ts +3 -3
- package/build/sdk-typescript/src/model/documentation/SDKDocumentationRichTextSpanAttribute.d.ts +2 -2
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockAsset.d.ts +3 -3
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockAssets.d.ts +6 -8
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockCallout.d.ts +5 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockCode.d.ts +5 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockColumn.d.ts +2 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockColumnItem.d.ts +7 -9
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockCustom.d.ts +5 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockDivider.d.ts +2 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockEmbedFigma.d.ts +2 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockEmbedGeneric.d.ts +5 -7
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockEmbedLink.d.ts +5 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockEmbedStorybook.d.ts +2 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockEmbedYoutube.d.ts +1 -5
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockFrame.d.ts +3 -3
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockFrames.d.ts +6 -8
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockHeading.d.ts +5 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockImage.d.ts +5 -7
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockOrderedList.d.ts +2 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockQuote.d.ts +2 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockRenderCode.d.ts +3 -4
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockShortcut.d.ts +3 -3
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockShortcuts.d.ts +5 -7
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockTab.d.ts +2 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockTabItem.d.ts +4 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockTable.d.ts +4 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockTableCell.d.ts +4 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockTableColumn.d.ts +5 -5
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockTableRow.d.ts +2 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockText.d.ts +5 -7
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockToken.d.ts +4 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockTokenGroup.d.ts +4 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockTokenList.d.ts +4 -6
- package/build/sdk-typescript/src/model/documentation/blocks/SDKDocumentationPageBlockUnorderedList.d.ts +2 -6
- package/build/sdk-typescript/src/model/documentation/builder/SDKDocumentationBlockBuilder.d.ts +1 -1
- package/build/sdk-typescript/src/model/documentation/configuration/SDKDocumentationItemConfiguration.d.ts +2 -2
- package/build/sdk-typescript/src/model/documentation/configuration/SDKDocumentationItemHeader.d.ts +6 -6
- package/build/sdk-typescript/src/model/elements/SDKElementDataView.d.ts +4 -4
- package/build/sdk-typescript/src/model/elements/SDKElementDataViewColumn.d.ts +2 -2
- package/build/sdk-typescript/src/model/elements/SDKElementProperty.d.ts +23 -6
- package/build/sdk-typescript/src/model/elements/SDKElementPropertyOption.d.ts +6 -2
- package/build/sdk-typescript/src/model/elements/values/SDKElementPropertyValue.d.ts +2 -2
- package/build/sdk-typescript/src/model/enums/SDKBorderStyle.d.ts +6 -0
- package/build/sdk-typescript/src/model/enums/SDKIntegrationService.d.ts +7 -0
- package/build/sdk-typescript/src/model/enums/SDKTextCase.d.ts +2 -1
- package/build/sdk-typescript/src/model/enums/SDKTokenType.d.ts +42 -6
- package/build/sdk-typescript/src/model/enums/SDKUnit.d.ts +13 -2
- package/build/sdk-typescript/src/model/enums/SDKUserRole.d.ts +7 -0
- package/build/sdk-typescript/src/model/enums/SDKVisibilityType.d.ts +4 -0
- package/build/sdk-typescript/src/model/enums/SDKWorkspaceNPMRegistryAuthType.d.ts +6 -0
- package/build/sdk-typescript/src/model/enums/SDKWorkspaceNPMRegistryType.d.ts +12 -0
- package/build/sdk-typescript/src/model/enums/SDKWorkspaceSubscriptionPlanInterval.d.ts +6 -0
- package/build/sdk-typescript/src/model/enums/SDKWorkspaceSubscriptionProduct.d.ts +12 -0
- package/build/sdk-typescript/src/model/enums/SDKWorkspaceSubscriptionStatus.d.ts +18 -0
- package/build/sdk-typescript/src/model/enums/SDKWorkspaceSubscriptionStatusInternal.d.ts +8 -0
- package/build/sdk-typescript/src/model/exporters/SDKExporter.d.ts +3 -3
- package/build/sdk-typescript/src/model/exporters/custom_blocks/SDKExporterCustomBlock.d.ts +2 -2
- package/build/sdk-typescript/src/model/exporters/custom_blocks/SDKExporterCustomBlockProperty.d.ts +2 -2
- package/build/sdk-typescript/src/model/exporters/custom_blocks/SDKExporterCustomBlockVariant.d.ts +2 -2
- package/build/sdk-typescript/src/model/exporters/custom_properties/SDKExporterConfigurationProperty.d.ts +5 -5
- package/build/sdk-typescript/src/model/groups/SDKAssetGroup.d.ts +5 -5
- package/build/sdk-typescript/src/model/groups/SDKComponentGroup.d.ts +39 -0
- package/build/sdk-typescript/src/model/groups/SDKDesignComponentGroup.d.ts +7 -7
- package/build/sdk-typescript/src/model/groups/SDKTokenGroup.d.ts +12 -11
- package/build/sdk-typescript/src/model/membership/SDKMembership.d.ts +16 -0
- package/build/sdk-typescript/src/model/support/SDKDesignComponentOrigin.d.ts +4 -4
- package/build/sdk-typescript/src/model/support/SDKFrameOrigin.d.ts +2 -2
- package/build/sdk-typescript/src/model/support/SDKSize.d.ts +2 -2
- package/build/sdk-typescript/src/model/support/SDKSource.d.ts +19 -9
- package/build/sdk-typescript/src/model/support/SDKTokenOrigin.d.ts +2 -2
- package/build/sdk-typescript/src/model/themes/SDKThemeUtilities.d.ts +8 -3
- package/build/sdk-typescript/src/model/themes/SDKTokenTheme.d.ts +16 -24
- package/build/sdk-typescript/src/model/themes/SDKTokenThemeOverride.d.ts +13 -21
- package/build/sdk-typescript/src/model/tokens/SDKBlurToken.d.ts +12 -8
- package/build/sdk-typescript/src/model/tokens/SDKBorderToken.d.ts +15 -10
- package/build/sdk-typescript/src/model/tokens/SDKColorToken.d.ts +19 -11
- package/build/sdk-typescript/src/model/tokens/SDKDimensionToken.d.ts +70 -0
- package/build/sdk-typescript/src/model/tokens/SDKGradientToken.d.ts +18 -10
- package/build/sdk-typescript/src/model/tokens/SDKShadowToken.d.ts +17 -13
- package/build/sdk-typescript/src/model/tokens/SDKStringToken.d.ts +36 -0
- package/build/sdk-typescript/src/model/tokens/SDKTextCaseToken.d.ts +23 -0
- package/build/sdk-typescript/src/model/tokens/SDKTextDecorationToken.d.ts +26 -0
- package/build/sdk-typescript/src/model/tokens/SDKToken.d.ts +13 -12
- package/build/sdk-typescript/src/model/tokens/SDKTokenCompator.d.ts +10 -10
- package/build/sdk-typescript/src/model/tokens/SDKTokenValue.d.ts +149 -63
- package/build/sdk-typescript/src/model/tokens/SDKTypographyToken.d.ts +12 -11
- package/build/sdk-typescript/src/model/tokens/SDKVisibilityToken.d.ts +18 -0
- package/build/sdk-typescript/src/model/tokens/remote/SDKRemoteTokenData.d.ts +74 -14
- package/build/sdk-typescript/src/model/tokens/remote/SDKRemoteTokenModel.d.ts +18 -16
- package/build/sdk-typescript/src/model/tokens/remote/SDKRemoteTokenValue.d.ts +73 -34
- package/build/sdk-typescript/src/model/users/SDKUser.d.ts +20 -11
- package/build/sdk-typescript/src/model/users/SDKUserProfile.d.ts +49 -0
- package/build/sdk-typescript/src/model/workspaces/SDKWorkspace.d.ts +27 -0
- package/build/sdk-typescript/src/model/workspaces/SDKWorkspaceIPWhitelistSettings.d.ts +26 -0
- package/build/sdk-typescript/src/model/workspaces/SDKWorkspaceNPMRegistrySettings.d.ts +34 -0
- package/build/sdk-typescript/src/model/workspaces/SDKWorkspaceOnboarding.d.ts +30 -0
- package/build/sdk-typescript/src/model/workspaces/SDKWorkspaceProductFeatures.d.ts +30 -0
- package/build/sdk-typescript/src/model/workspaces/SDKWorkspaceProfile.d.ts +68 -0
- package/build/sdk-typescript/src/model/workspaces/SDKWorkspaceSSOSettings.d.ts +17 -0
- package/build/sdk-typescript/src/model/workspaces/SDKWorkspaceSubscription.d.ts +82 -0
- package/build/sdk-typescript/src/tests/Areas/AreaTokenValues.d.ts +0 -0
- package/build/sdk-typescript/src/tests/FigmaTokensDataLoader.d.ts +20 -0
- package/build/sdk-typescript/src/tests/Serialization/WorkspaceNPMRegistrySettings.spec.d.ts +1 -0
- package/build/sdk-typescript/src/tests/Serialization/WorkspaceOnboarding.spec.d.ts +1 -0
- package/build/sdk-typescript/src/tests/Serialization/WorkspaceSSOSettings.spec.d.ts +1 -0
- package/build/sdk-typescript/src/tests/Tooling/PluginFigmaTokens.spec.d.ts +1 -17
- package/build/sdk-typescript/src/tests/Tooling/ReadTokens.spec.d.ts +1 -0
- package/build/sdk-typescript/src/tests/Tooling/TokensModel.spec.d.ts +1 -0
- package/build/sdk-typescript/src/tests/helpers.d.ts +6 -1
- package/build/sdk-typescript/src/tests/validators.d.ts +83 -0
- package/build/sdk-typescript/src/tools/design-tokens/SDKToolsDesignTokensPlugin.d.ts +15 -13
- package/build/sdk-typescript/src/tools/design-tokens/utilities/SDKDTJSONConverter.d.ts +15 -12
- package/build/sdk-typescript/src/tools/design-tokens/utilities/SDKDTJSONGroupBuilder.d.ts +8 -6
- package/build/sdk-typescript/src/tools/design-tokens/utilities/SDKDTJSONLoader.d.ts +2 -1
- package/build/sdk-typescript/src/tools/design-tokens/utilities/SDKDTJSONParser.d.ts +5 -3
- package/build/sdk-typescript/src/tools/design-tokens/utilities/SDKDTMapLoader.d.ts +4 -4
- package/build/sdk-typescript/src/tools/design-tokens/utilities/SDKDTMapResolver.d.ts +2 -5
- package/build/sdk-typescript/src/tools/design-tokens/utilities/SDKDTThemeMerger.d.ts +7 -7
- package/build/sdk-typescript/src/tools/design-tokens/utilities/SDKDTTokenGroupTreeMerger.d.ts +6 -6
- package/build/sdk-typescript/src/tools/design-tokens/utilities/SDKDTTokenMerger.d.ts +6 -6
- package/build/sdk-typescript/src/tools/design-tokens/utilities/SDKDTTokenReferenceResolver.d.ts +5 -6
- package/build/sdk-typescript/src/tools/design-tokens/utilities/SDKDTTokenSetResolver.d.ts +1 -2
- package/build/sdk-typescript/src/tools/design-tokens/utilities/tree/SDKDTGroupTree.d.ts +4 -2
- package/build/sdk-typescript/src/tools/design-tokens/utilities/tree/SDKDTGroupTreeNode.d.ts +1 -4
- package/build/sdk-typescript/src/tools/design-tokens/utilities/tree/SDKDTParentChildMapping.d.ts +1 -1
- package/build/sdk-typescript/src/tools/json-builder/SDKToolsJSONBuilder.d.ts +6 -5
- package/build/sdk-typescript/src/tools/json-builder/elements-transformers/SDKToolsJSONElementFigmaTokensTransformer.d.ts +17 -20
- package/build/sdk-typescript/src/tools/json-builder/elements-transformers/SDKToolsJSONElementStyleDictionaryTransformer.d.ts +11 -14
- package/build/sdk-typescript/src/tools/json-builder/elements-transformers/SDKToolsJSONElementTransformer.d.ts +27 -36
- package/build/sdk-typescript/src/tools/markdown-transform/SDKToolsMarkdownTransform.d.ts +5 -6
- package/build/sdk-typescript/src/tools/markdown-transform/SDKToolsMarkdownTransformBlock.d.ts +39 -39
- package/build/sdk-typescript/src/tools/markdown-transform/SDKToolsMarkdownTransformUtil.d.ts +4 -8
- package/build/sdk-typescript/src/tools/search-index/SDKToolsDocSearch.d.ts +1 -1
- package/build/sdk-typescript/src/tools/token-preview/TokenUtilPreviewGenerator.d.ts +17 -0
- package/build/sdk-typescript/src/tools/token-preview/TokenUtilPreviewMetadataGenerator.d.ts +8 -0
- package/build/sdk-typescript/src/tools/token-preview/TokenUtilPreviewReferenceInfoGenerator.d.ts +10 -0
- package/build/sdk-typescript/src/tools/token-preview/TokenUtilPreviewSegmentGenerator.d.ts +5 -0
- package/build/sdk-typescript/src/tools/token-preview/TokenUtilPreviewStyleGenerator.d.ts +5 -0
- package/build/sdk-typescript/src/tools/token-preview/TokenUtilPreviewTypes.d.ts +68 -0
- package/build/sdk-typescript/src/tools/token-transform/SDKToolsTokenTransform.d.ts +8 -12
- package/build/sdk-typescript/src/utils/TokenUtils.d.ts +113 -0
- package/build/sdk-typescript/src/utils/UnreachableCaseError.d.ts +3 -0
- package/build/supernova-sdk-typescript.js +1 -1
- package/build/supernova-sdk-typescript.js.map +1 -1
- package/package.json +9 -6
- package/build/sdk-typescript/src/core/SDKBrand.d.ts +0 -80
- package/build/sdk-typescript/src/core/SDKBrandWriter.d.ts +0 -29
- package/build/sdk-typescript/src/core/SDKDesignSystem.d.ts +0 -62
- package/build/sdk-typescript/src/core/SDKDesignSystemVersion.d.ts +0 -99
- package/build/sdk-typescript/src/core/SDKDocumentation.d.ts +0 -55
- package/build/sdk-typescript/src/core/SDKWorkspace.d.ts +0 -26
- package/build/sdk-typescript/src/model/support/SDKWorkspaceNPMRegistry.d.ts +0 -13
- package/build/sdk-typescript/src/model/tokens/SDKFontToken.d.ts +0 -16
- package/build/sdk-typescript/src/model/tokens/SDKGenericToken.d.ts +0 -18
- package/build/sdk-typescript/src/model/tokens/SDKMeasureToken.d.ts +0 -26
- package/build/sdk-typescript/src/model/tokens/SDKRadiusToken.d.ts +0 -18
- package/build/sdk-typescript/src/model/tokens/SDKTextToken.d.ts +0 -16
- /package/build/sdk-typescript/src/tests/{Accessors/Brand.spec.d.ts → Areas/AreaBatchUpdates.spec.d.ts} +0 -0
- /package/build/sdk-typescript/src/tests/{Accessors/Components.spec.d.ts → Areas/AreaBrands.spec.d.ts} +0 -0
- /package/build/sdk-typescript/src/tests/{Accessors/DesignSystem.spec.d.ts → Areas/AreaMe.spec.d.ts} +0 -0
- /package/build/sdk-typescript/src/tests/{Accessors/DesignSystemVersion.spec.d.ts → Areas/AreaTokens.spec.d.ts} +0 -0
- /package/build/sdk-typescript/src/tests/{Accessors/Documentation.spec.d.ts → Areas/AreaWorkspace.spec.d.ts} +0 -0
- /package/build/sdk-typescript/src/tests/{Accessors/Supernova.spec.d.ts → Serialization/User.spec.d.ts} +0 -0
- /package/build/sdk-typescript/src/tests/{Accessors → Serialization}/Workspace.spec.d.ts +0 -0
- /package/build/sdk-typescript/src/tests/{Accessors/Theme.spec.d.ts → Serialization/WorkspaceIPWhitelistSettings.spec.d.ts} +0 -0
|
@@ -0,0 +1,217 @@
|
|
|
1
|
+
import { AnyToken } from "../../exports";
|
|
2
|
+
import { ElementDataView } from "../../model/elements/SDKElementDataView";
|
|
3
|
+
import { ElementDataViewColumn } from "../../model/elements/SDKElementDataViewColumn";
|
|
4
|
+
import { ElementProperty, ElementPropertyCreationModel, ElementPropertyUpdateModel } from "../../model/elements/SDKElementProperty";
|
|
5
|
+
import { ElementPropertyValue } from "../../model/elements/values/SDKElementPropertyValue";
|
|
6
|
+
import { TokenType } from "../../model/enums/SDKTokenType";
|
|
7
|
+
import { TokenGroup } from "../../model/groups/SDKTokenGroup";
|
|
8
|
+
import { TokenTheme } from "../../model/themes/SDKTokenTheme";
|
|
9
|
+
import { Token } from "../../model/tokens/SDKToken";
|
|
10
|
+
import { TokenTypeMapToken } from "../../utils/TokenUtils";
|
|
11
|
+
import { DataCore } from "../data/SDKDataCore";
|
|
12
|
+
import { AreaTokenValues } from "./SDKAreaTokenValues";
|
|
13
|
+
import { RemoteBrandIdentifier, RemoteVersionIdentifier } from "./SDKRemoteIdentifiers";
|
|
14
|
+
export declare class AreaTokens {
|
|
15
|
+
/** Internal: Engine */
|
|
16
|
+
private dataCore;
|
|
17
|
+
/** Update helpers for everything token related */
|
|
18
|
+
values: AreaTokenValues;
|
|
19
|
+
constructor(dataCore: DataCore);
|
|
20
|
+
/** Fetches all remote tokens in the version
|
|
21
|
+
* @param from - Remote version to fetch from
|
|
22
|
+
* @param filter - Optional filter to apply. Multiple filters can be used at once
|
|
23
|
+
* @param filter.type - When provided, only tokens of the specified type will be returned
|
|
24
|
+
* @param filter.brandId - When provided, only tokens of the specified brand will be returned
|
|
25
|
+
* @returns Tokens in the specified version with filter applied
|
|
26
|
+
*/
|
|
27
|
+
getTokens(from: RemoteVersionIdentifier, filter?: {
|
|
28
|
+
type?: TokenType;
|
|
29
|
+
brandId?: string;
|
|
30
|
+
}): Promise<Array<Token>>;
|
|
31
|
+
/** Retrieves all occurances of the specified token in the version - its usages in other tokens, components and documentation pages
|
|
32
|
+
* @param from - Remote version to fetch from
|
|
33
|
+
* @param idInVersion - Token to check for references
|
|
34
|
+
* @returns Persistent identifiers of tokens, components, documentation pages that contain the specified token
|
|
35
|
+
*/
|
|
36
|
+
getTokenUsage(from: RemoteVersionIdentifier, idInVersion: string): Promise<{
|
|
37
|
+
tokens: Array<string>;
|
|
38
|
+
components: Array<string>;
|
|
39
|
+
documentationPages: Array<string>;
|
|
40
|
+
}>;
|
|
41
|
+
/** Fetches all remote token groups in this version
|
|
42
|
+
* @param from - Remote version to fetch from
|
|
43
|
+
* @param filter - Optional filter to apply. Multiple filters can be used at once
|
|
44
|
+
* @param filter.type - When provided, only token groups of the specified type will be returned
|
|
45
|
+
* @param filter.brandId - When provided, only token groups of the specified brand will be returned
|
|
46
|
+
* @returns Token groups in the specified version with filter applied
|
|
47
|
+
*/
|
|
48
|
+
getTokenGroups(from: RemoteVersionIdentifier, filter?: {
|
|
49
|
+
type?: TokenType;
|
|
50
|
+
brandId?: string;
|
|
51
|
+
}): Promise<Array<TokenGroup>>;
|
|
52
|
+
/** Fetches all remote themes in the version
|
|
53
|
+
* @param from - Remote version to fetch from
|
|
54
|
+
* @returns All themes in the specified version
|
|
55
|
+
*/
|
|
56
|
+
getTokenThemes(from: RemoteVersionIdentifier): Promise<Array<TokenTheme>>;
|
|
57
|
+
/** Retrieves all remote property definitions for tokens
|
|
58
|
+
* @param from - Remote version to fetch from
|
|
59
|
+
* @returns All property definitions in the specified version
|
|
60
|
+
*/
|
|
61
|
+
getTokenProperties(from: RemoteVersionIdentifier): Promise<Array<ElementProperty>>;
|
|
62
|
+
/** Retrieves all remote property definitions for tokens
|
|
63
|
+
* @param from - Remote version to fetch from
|
|
64
|
+
* @returns All property definitions in the specified version
|
|
65
|
+
*/
|
|
66
|
+
getTokenPropertyValues(from: RemoteVersionIdentifier): Promise<Array<ElementPropertyValue>>;
|
|
67
|
+
/** Retrieves all remote property views for tokens
|
|
68
|
+
* @param from - Remote version to fetch from
|
|
69
|
+
* @returns All property views in the specified version
|
|
70
|
+
*/
|
|
71
|
+
getTokenDataViews(from: RemoteVersionIdentifier): Promise<Array<ElementDataView>>;
|
|
72
|
+
/** Creates remote token. This method can only be used once per token and will assign persistent id to the token. Calling this version on token that already has id assigned will result in error
|
|
73
|
+
* @param to - Remote version to write to
|
|
74
|
+
* @param token - Token to create
|
|
75
|
+
* @param parentId - Id of the group to add the token to. This is id of the group, not the versioned id
|
|
76
|
+
* @returns New remote token ids
|
|
77
|
+
*/
|
|
78
|
+
createToken(to: RemoteVersionIdentifier, token: Token, parentId: string): Promise<{
|
|
79
|
+
id: string;
|
|
80
|
+
idInVersion: string;
|
|
81
|
+
}>;
|
|
82
|
+
/** Creates local token. This token doesn't have id associated with it on remote, and must be created once with `createToken` to be stored in design system
|
|
83
|
+
* @param tokenType - Type of token to create
|
|
84
|
+
* @returns New token of the specified type, filled with default values
|
|
85
|
+
*/
|
|
86
|
+
createLocalToken<T extends TokenType>(tokenType: T, versionId: string, brandId: string, properties: Array<ElementProperty>): TokenTypeMapToken[T];
|
|
87
|
+
/** Creates local token override. This theme override doesn't have id associated with it on remote, and must be created once with `createThemeOverride` to be stored in design system
|
|
88
|
+
* @param tokenType - Type of token to create
|
|
89
|
+
* @returns New token of the specified type, filled with default values
|
|
90
|
+
*/
|
|
91
|
+
createLocalThemeOverride<T extends AnyToken>(theme: TokenTheme, baseToken: T): T;
|
|
92
|
+
/** Creates remote token group. This method can only be used once per group and will assign persistent id to the group. Calling this version on group that already has id assigned will result in error
|
|
93
|
+
* @param to - Remote version to write to
|
|
94
|
+
* @param group - Group to create
|
|
95
|
+
* @param parentId - Id of the group to add the group to. This is id of the group, not the versioned id
|
|
96
|
+
* @returns New remote token group ids
|
|
97
|
+
*/
|
|
98
|
+
createTokenGroup(to: RemoteVersionIdentifier, group: TokenGroup, parentId: string): Promise<{
|
|
99
|
+
id: string;
|
|
100
|
+
idInVersion: string;
|
|
101
|
+
}>;
|
|
102
|
+
/** Creates local token group. This group doesn't have id associated with it on remote, and must be created once with `createTokenGroup` to be stored in design system
|
|
103
|
+
* @param tokenType - Type of token to create the group for
|
|
104
|
+
* @param versionId - Id of the version to create the group in
|
|
105
|
+
* @param brandId - Id of the brand to create the group in
|
|
106
|
+
* @returns New group with id assigned
|
|
107
|
+
*/
|
|
108
|
+
createLocalTokenGroup(tokenType: TokenType, versionId: string, brandId: string): TokenGroup;
|
|
109
|
+
/** Updates remote token. This method can only be used on tokens that already exist in the version
|
|
110
|
+
* @param to - Remote version to write to
|
|
111
|
+
* @param token - Token to update
|
|
112
|
+
* @returns Nothing
|
|
113
|
+
*/
|
|
114
|
+
updateToken(to: RemoteVersionIdentifier, token: Token): Promise<void>;
|
|
115
|
+
/** Updates remote token groups. This method can only be used on token groups that already exist in the version
|
|
116
|
+
* @param to - Remote version to write to
|
|
117
|
+
* @param token - Token group to update
|
|
118
|
+
* @returns Nothing
|
|
119
|
+
*/
|
|
120
|
+
updateTokenGroup(to: RemoteVersionIdentifier, group: TokenGroup): Promise<void>;
|
|
121
|
+
/** Updates remote token property value. This also creates the property value if it doesn't exist
|
|
122
|
+
* @param to - Remote version to write to
|
|
123
|
+
* @param newValue - Value to set - this can be multiple things, from ID to raw string value to others
|
|
124
|
+
* @param forToken - Token to assign the value to
|
|
125
|
+
* @param forProperty - Property to assign the value to
|
|
126
|
+
*/
|
|
127
|
+
updateTokenPropertyValue(to: RemoteVersionIdentifier, newValue: string, forToken: Token, forProperty: ElementProperty): Promise<void>;
|
|
128
|
+
/** Deletes remote token property value
|
|
129
|
+
* @param to - Remote version to write to
|
|
130
|
+
* @param valueId - Value identifier
|
|
131
|
+
*/
|
|
132
|
+
deleteTokenPropertyValue(to: RemoteVersionIdentifier, valueId: string): Promise<void>;
|
|
133
|
+
/** Create token property
|
|
134
|
+
* @param to - Remote version to write to
|
|
135
|
+
* @param model - Property creation model to create the property from
|
|
136
|
+
*/
|
|
137
|
+
createTokenProperty(to: RemoteVersionIdentifier, model: ElementPropertyCreationModel): Promise<{
|
|
138
|
+
id: string;
|
|
139
|
+
idInVersion: string;
|
|
140
|
+
}>;
|
|
141
|
+
/** Update token property
|
|
142
|
+
* @param to - Remote version to write to
|
|
143
|
+
* @param propertyIdInVersion - Remote element property to update
|
|
144
|
+
* @param model - Property update model to apply to property
|
|
145
|
+
*/
|
|
146
|
+
updateTokenProperty(to: RemoteVersionIdentifier, propertyIdInVersion: string, model: ElementPropertyUpdateModel): Promise<void>;
|
|
147
|
+
/** Delete token property. This will remove all values associated with the property
|
|
148
|
+
* @param to - Remote version to write to
|
|
149
|
+
* @param propertyIdInVersion - Id of the property to delete
|
|
150
|
+
*/
|
|
151
|
+
deleteTokenProperty(to: RemoteVersionIdentifier, propertyIdInVersion: string): Promise<void>;
|
|
152
|
+
/** Resize specific token column
|
|
153
|
+
* @param to - Remote version to write to
|
|
154
|
+
* @param columnIdInVersion - Id of the column to update
|
|
155
|
+
* @param newWidth - New width of the column
|
|
156
|
+
*/
|
|
157
|
+
updateResizeTokenColumn(to: RemoteVersionIdentifier, view: ElementDataView, column: ElementDataViewColumn, newWidth: number): Promise<void>;
|
|
158
|
+
/** Move column to a new index and reorder all other columns around it
|
|
159
|
+
* @param to - Remote version to write to
|
|
160
|
+
* @param colum - Column object to move
|
|
161
|
+
* @param newIndex - New index to move the token to
|
|
162
|
+
*/
|
|
163
|
+
updateReorderTokenColumn(to: RemoteVersionIdentifier, view: ElementDataView, column: ElementDataViewColumn, newIndex: number): Promise<void>;
|
|
164
|
+
/** Creates local token theme. This group doesn't have id associated with it on remote, and must be created once with `createTokenTheme` to be stored in design system
|
|
165
|
+
* @param versionId - Id of the version to create the theme in
|
|
166
|
+
* @param brandId - Id of the brand to create the theme in
|
|
167
|
+
* @returns New group with id assigned
|
|
168
|
+
*/
|
|
169
|
+
createLocalTokenTheme(versionId: string, brandId: string): TokenTheme;
|
|
170
|
+
/** Creates remote token theme. This method can only be used once per theme and will assign persistent id to the theme. Calling this version on theme that already has id assigned will result in error
|
|
171
|
+
* @param to - Remote version to write to
|
|
172
|
+
* @param theme - Theme to create
|
|
173
|
+
* @returns New remote theme ids
|
|
174
|
+
*/
|
|
175
|
+
createTokenTheme(to: RemoteVersionIdentifier, theme: TokenTheme): Promise<{
|
|
176
|
+
id: string;
|
|
177
|
+
idInVersion: string;
|
|
178
|
+
}>;
|
|
179
|
+
/** Updates token theme. This method can only be used on themes that already exist in the version
|
|
180
|
+
* @param to - Remote version to write to
|
|
181
|
+
* @param theme - Token theme to update
|
|
182
|
+
* @returns Nothing
|
|
183
|
+
*/
|
|
184
|
+
updateTokenTheme(to: RemoteVersionIdentifier, theme: TokenTheme): Promise<void>;
|
|
185
|
+
/** Deletes remote token. Calling this method on token that doesn't exist in the version will result in error
|
|
186
|
+
* @param to - Remote version to write to
|
|
187
|
+
* @param tokenIdInVersion - Token idInVersion to delete
|
|
188
|
+
* @returns Nothing
|
|
189
|
+
*/
|
|
190
|
+
deleteToken(to: RemoteVersionIdentifier, tokenIdInVersion: string): Promise<void>;
|
|
191
|
+
/** Deletes remote token group. This method will also fix the token group tree by moving any subgroups to parent. Calling this method on group that doesn't exist in the version will result in error
|
|
192
|
+
* @param to - Remote version to write to
|
|
193
|
+
* @param tokenGroupIdInVersion - Token group idInVersion to delete
|
|
194
|
+
* @returns Nothing
|
|
195
|
+
*/
|
|
196
|
+
deleteTokenGroup(to: RemoteVersionIdentifier, tokenGroupIdInVersion: string): Promise<void>;
|
|
197
|
+
/** Deletes remote token theme. This method will also remove all theme overrides and disconnect theme from assigned column, all of which will be updated
|
|
198
|
+
* @param to - Remote version to write to
|
|
199
|
+
* @param idInVersion - Theme idInVersion to delete
|
|
200
|
+
* @returns Nothing
|
|
201
|
+
*/
|
|
202
|
+
deleteTokenTheme(to: RemoteVersionIdentifier, idInVersion: string): Promise<void>;
|
|
203
|
+
/** Warning: INTERNAL, DO NOT USE YET, NOT STABLE INTERFACE. Write tokens in bulk */
|
|
204
|
+
writeTokens(to: RemoteVersionIdentifier, tokens: Array<Token>, groups: Array<TokenGroup>, deleteTokens: Array<Token>): Promise<void>;
|
|
205
|
+
/** Warning: INTERNAL, DO NOT USE YET, NOT STABLE INTERFACE. Write theme in bulk */
|
|
206
|
+
writeTheme(to: RemoteVersionIdentifier, theme: TokenTheme): Promise<void>;
|
|
207
|
+
/** Resolves tokens by applying themes to them and retrieves new token set where values correctly correspond to that theme */
|
|
208
|
+
computeTokensByApplyingThemes(tokens: Array<Token>, themes: Array<TokenTheme>): Promise<Array<Token>>;
|
|
209
|
+
/** Separates groups by types */
|
|
210
|
+
computeGroupTrees(groups: Array<TokenGroup>): Promise<Map<TokenType, Array<TokenGroup>>>;
|
|
211
|
+
/** Get determistic mocked token data. Must be used with mocked token groups */
|
|
212
|
+
getMockedTokens(from: RemoteBrandIdentifier): Promise<Array<Token>>;
|
|
213
|
+
/** Get determistic mocked token group data. Must be used with mocked tokens */
|
|
214
|
+
getMockedTokenGroups(from: RemoteBrandIdentifier): Promise<Array<TokenGroup>>;
|
|
215
|
+
/** Get determistic mocked token data views. Must be used with mocked tokens */
|
|
216
|
+
getMockedTokenDataViews(from: RemoteVersionIdentifier): Promise<Array<ElementDataView>>;
|
|
217
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { DesignSystemVersion } from "../../model/base/SDKDesignSystemVersion";
|
|
2
|
+
import { DataCore } from "../data/SDKDataCore";
|
|
3
|
+
import { RemoteVersionIdentifier } from "./SDKRemoteIdentifiers";
|
|
4
|
+
export declare class AreaVersions {
|
|
5
|
+
/** Internal: Engine */
|
|
6
|
+
private dataCore;
|
|
7
|
+
constructor(dataCore: DataCore);
|
|
8
|
+
/** Fetches active design system version - the one to which all changes are being written currently. There is always one active version available for any provided design system. */
|
|
9
|
+
getActiveVersion(designSystemId: string): Promise<DesignSystemVersion | null>;
|
|
10
|
+
/** Fetches all design system versions of provided design system */
|
|
11
|
+
getVersions(designSystemId: string): Promise<Array<DesignSystemVersion>>;
|
|
12
|
+
/** Fetches design system version by id */
|
|
13
|
+
getVersion(from: RemoteVersionIdentifier): Promise<DesignSystemVersion>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
import { Acl } from "../../model/acl/SDKAcl";
|
|
2
|
+
import { Membership } from "../../model/membership/SDKMembership";
|
|
3
|
+
import { Workspace } from "../../model/workspaces/SDKWorkspace";
|
|
4
|
+
import { WorkspaceIPWhitelistSettings, WorkspaceIPWhitelistSettingsUpdateModel } from "../../model/workspaces/SDKWorkspaceIPWhitelistSettings";
|
|
5
|
+
import { WorkspaceNPMRegistrySettings, WorkspaceNPMRegistrySettingsUpdateModel } from "../../model/workspaces/SDKWorkspaceNPMRegistrySettings";
|
|
6
|
+
import { WorkspaceOnboarding, WorkspaceOnboardingUpdateModel } from "../../model/workspaces/SDKWorkspaceOnboarding";
|
|
7
|
+
import { SubscriptionProductFeatures } from "../../model/workspaces/SDKWorkspaceProductFeatures";
|
|
8
|
+
import { WorkspaceProfileUpdateModel } from "../../model/workspaces/SDKWorkspaceProfile";
|
|
9
|
+
import { WorkspaceSSOSettingsUpdateModel } from "../../model/workspaces/SDKWorkspaceSSOSettings";
|
|
10
|
+
import { DataCore } from "../data/SDKDataCore";
|
|
11
|
+
export declare class AreaWorkspaces {
|
|
12
|
+
/** Internal: Engine */
|
|
13
|
+
private dataCore;
|
|
14
|
+
constructor(dataCore: DataCore);
|
|
15
|
+
/** Fetches one specific workspace by provided id
|
|
16
|
+
* @param workspaceId - ID of the workspace
|
|
17
|
+
* @returns Full workspace object
|
|
18
|
+
*/
|
|
19
|
+
workspace(workspaceId: string): Promise<Workspace>;
|
|
20
|
+
/** Fetches all workspaces user has access to. Use `memberships` instead if you want to also know which role the current user has in which workspace
|
|
21
|
+
* @param userId - ID of the user
|
|
22
|
+
* @returns All workspaces user is part of
|
|
23
|
+
*/
|
|
24
|
+
workspaces(userId: string): Promise<Array<Workspace>>;
|
|
25
|
+
/** Fetches all memberships user is part of. Each memberships contains workspace and user role.
|
|
26
|
+
* @param userId - ID of the user
|
|
27
|
+
* @returns All workspaces user is part of
|
|
28
|
+
*/
|
|
29
|
+
memberships(userId: string): Promise<Array<Membership>>;
|
|
30
|
+
subscriptionProductFeatures(): Promise<SubscriptionProductFeatures>;
|
|
31
|
+
acls(): Promise<Acl>;
|
|
32
|
+
/** Validates if the handle is available for use
|
|
33
|
+
* @param handle - Handle to validate
|
|
34
|
+
* @returns True if the handle is available (not occupied by any other workspace), false otherwise
|
|
35
|
+
*/
|
|
36
|
+
validateIsWorkspaceHandleAvailable(handle: string): Promise<boolean>;
|
|
37
|
+
/** Fetches workspace onboarding status
|
|
38
|
+
* @param workspaceId - ID of the workspace
|
|
39
|
+
* @returns Workspace onboarding status
|
|
40
|
+
*/
|
|
41
|
+
workspaceOnboarding(workspaceId: string): Promise<WorkspaceOnboarding>;
|
|
42
|
+
/** Fetches workspace IP whitelist settings
|
|
43
|
+
* @param workspaceId - ID of the workspace
|
|
44
|
+
* @returns Workspace IP whitelist settings or null if the workspace is not using IP whitelist
|
|
45
|
+
*/
|
|
46
|
+
workspaceIPWhitelistSettings(workspaceId: string): Promise<WorkspaceIPWhitelistSettings | null>;
|
|
47
|
+
/** Fetches workspace NPM registry settings
|
|
48
|
+
* @param workspaceId - ID of the workspace
|
|
49
|
+
* @returns Workspace NPM registry settings or null if the workspace is not using NPM registry
|
|
50
|
+
*/
|
|
51
|
+
workspaceNPMRegistrySettings(workspaceId: string): Promise<WorkspaceNPMRegistrySettings | null>;
|
|
52
|
+
/** Fetches workspace SSO settings
|
|
53
|
+
* @param workspaceId - ID of the workspace
|
|
54
|
+
* @returns Workspace SSO settings or null if the workspace is not using SSO
|
|
55
|
+
*/
|
|
56
|
+
workspaceSSOSettings(workspaceId: string): Promise<WorkspaceSSOSettingsUpdateModel | null>;
|
|
57
|
+
/** Creates new workspace and retrieves the newly created workspace object. The user who creates the workspace becomes its owner
|
|
58
|
+
* @param name - Name of the workspace
|
|
59
|
+
* @param handle - Handle of the workspace to create. Use `validateIsWorkspaceHandleAvailable` to check if the handle is available
|
|
60
|
+
* @returns Newly created workspace object
|
|
61
|
+
*/
|
|
62
|
+
createWorkspace(name: string, handle: string): Promise<Workspace>;
|
|
63
|
+
/** Updates workspace profile for a specific workspace
|
|
64
|
+
* @param workspaceId - ID of the workspace
|
|
65
|
+
* @param update - New profile data
|
|
66
|
+
* @returns Nothing
|
|
67
|
+
*/
|
|
68
|
+
updateWorkspaceProfile(workspaceId: string, update: WorkspaceProfileUpdateModel): Promise<void>;
|
|
69
|
+
/** Updates workspace onboarding state for a specific workspace
|
|
70
|
+
* @param workspaceId - ID of the workspace
|
|
71
|
+
* @param update - New onboarding state
|
|
72
|
+
* @returns Nothing
|
|
73
|
+
*/
|
|
74
|
+
updateWorkspaceOnboarding(workspaceId: string, update: WorkspaceOnboardingUpdateModel): Promise<void>;
|
|
75
|
+
/** Updates workspace avatar for a specific workspace
|
|
76
|
+
* @param workspaceId - ID of the workspace
|
|
77
|
+
* @param avatar - New avatar
|
|
78
|
+
* @returns Nothing
|
|
79
|
+
*/
|
|
80
|
+
updateWorkspaceAvatar(workspaceId: string, avatar: File): Promise<void>;
|
|
81
|
+
/** Updates workspace SSO settings for a specific workspace
|
|
82
|
+
* @param workspaceId - ID of the workspace
|
|
83
|
+
* @param profile - New SSO configuration
|
|
84
|
+
* @returns Nothing
|
|
85
|
+
*/
|
|
86
|
+
updateWorkspaceSSOSettings(workspaceId: string, update: WorkspaceSSOSettingsUpdateModel): Promise<void>;
|
|
87
|
+
/** Updates workspace IP whitelist settings for a specific workspace
|
|
88
|
+
* @param workspaceId - ID of the workspace
|
|
89
|
+
* @param profile - New IP whitelist configuration
|
|
90
|
+
* @returns Nothing
|
|
91
|
+
*/
|
|
92
|
+
updateWorkspaceIPWhitelistSettings(workspaceId: string, ipWhitelistSettings: WorkspaceIPWhitelistSettingsUpdateModel): Promise<void>;
|
|
93
|
+
/** Updates workspace NPM registry settings for a specific workspace
|
|
94
|
+
* @param workspaceId - ID of the workspace
|
|
95
|
+
* @param profile - New NPM registry configuration
|
|
96
|
+
* @returns Nothing
|
|
97
|
+
*/
|
|
98
|
+
updateWorkspaceNPMRegistrySettings(workspaceId: string, npmRegistrySettings: WorkspaceNPMRegistrySettingsUpdateModel): Promise<void>;
|
|
99
|
+
/** Deletes a single workspace. This action is irreversible, all data will be lost, and can only be performed by the workspace owner
|
|
100
|
+
* @param workspaceId - ID of the workspace
|
|
101
|
+
* @returns Nothing
|
|
102
|
+
*/
|
|
103
|
+
deleteWorkspace(workspaceId: string): Promise<void>;
|
|
104
|
+
/** Deletes workspace avatar. This action is irreversible
|
|
105
|
+
* @param workspaceId - ID of the workspace
|
|
106
|
+
* @returns Nothing
|
|
107
|
+
*/
|
|
108
|
+
deleteWorkspaceAvatar(workspaceId: string): Promise<void>;
|
|
109
|
+
/** Deletes a workspace registry settings for a specific workspace
|
|
110
|
+
* @param workspaceId - ID of the workspace
|
|
111
|
+
* @returns Nothing
|
|
112
|
+
*/
|
|
113
|
+
deleteWorkspaceNPMRegistrySettings(workspaceId: string): Promise<void>;
|
|
114
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/** Unique, full identification of a single Supernova version including the workspace */
|
|
2
|
+
export type RemoteWorkspaceVersionIdentifier = {
|
|
3
|
+
/** Workspace ID */
|
|
4
|
+
workspaceId: string;
|
|
5
|
+
/** Design system ID */
|
|
6
|
+
designSystemId: string;
|
|
7
|
+
/** Version ID */
|
|
8
|
+
versionId: string;
|
|
9
|
+
};
|
|
10
|
+
/** Unique, full identification of a single Supernova version */
|
|
11
|
+
export type RemoteVersionIdentifier = {
|
|
12
|
+
/** Design system ID */
|
|
13
|
+
designSystemId: string;
|
|
14
|
+
/** Version ID */
|
|
15
|
+
versionId: string;
|
|
16
|
+
};
|
|
17
|
+
/** Unique, full identification of a single Supernova brand */
|
|
18
|
+
export type RemoteBrandIdentifier = {
|
|
19
|
+
/** Design system ID */
|
|
20
|
+
designSystemId: string;
|
|
21
|
+
/** Version ID */
|
|
22
|
+
versionId: string;
|
|
23
|
+
/** Brand ID */
|
|
24
|
+
brandId: string;
|
|
25
|
+
};
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { DataCore } from './SDKDataCore';
|
|
2
1
|
type DataBridgeRequestHookResult = {
|
|
3
2
|
skipDefaultAuth?: boolean;
|
|
4
3
|
};
|
|
@@ -13,20 +12,17 @@ export type DebugRequestObserver = (info: {
|
|
|
13
12
|
requestUrl: string;
|
|
14
13
|
requestMethod: string;
|
|
15
14
|
}) => void;
|
|
16
|
-
export
|
|
15
|
+
export type DataBridgeConfiguration = {
|
|
17
16
|
apiUrl: string;
|
|
18
17
|
apiVersion: string;
|
|
19
18
|
accessToken: string;
|
|
20
19
|
target: string | null;
|
|
21
|
-
cache: boolean;
|
|
22
20
|
requestHook: DataBridgeRequestHook | null;
|
|
23
21
|
debugRequestObserver?: DebugRequestObserver | null;
|
|
24
22
|
debugResponseObserver?: DebugResponseObserver | null;
|
|
25
|
-
}
|
|
23
|
+
};
|
|
26
24
|
export declare class DataBridge {
|
|
27
25
|
authToken: string;
|
|
28
|
-
cache: boolean;
|
|
29
|
-
dataCore: DataCore;
|
|
30
26
|
apiUrl: string;
|
|
31
27
|
apiVersion: string;
|
|
32
28
|
target: string | null;
|
|
@@ -34,17 +30,20 @@ export declare class DataBridge {
|
|
|
34
30
|
debugRequestObserver: DebugRequestObserver | null;
|
|
35
31
|
debugResponseObserver: DebugResponseObserver | null;
|
|
36
32
|
constructor(conf: DataBridgeConfiguration);
|
|
37
|
-
|
|
38
|
-
|
|
33
|
+
delete(endpoint: string): Promise<any>;
|
|
34
|
+
get(endpoint: string): Promise<any>;
|
|
35
|
+
put(endpoint: string, payload: any | null): Promise<any>;
|
|
36
|
+
post(endpoint: string, payload: any | null): Promise<any>;
|
|
37
|
+
upload(endpoint: string, fileKey: string, file: File): Promise<any>;
|
|
38
|
+
private request;
|
|
39
|
+
private handleResponse;
|
|
39
40
|
private buildRequestConfig;
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
dsMetadataRequestURL(dsId: string): string;
|
|
48
|
-
dsVersionRequestURL(dsId: string): string;
|
|
41
|
+
getBaseEndpoint(fragment: string | null): string;
|
|
42
|
+
getPublicEndpoint(fragment: string): string;
|
|
43
|
+
getAclEndpoint(resource?: string): string;
|
|
44
|
+
getUserEndpoint(userId: string, fragment: string | null): string;
|
|
45
|
+
getWorkspaceEndpoint(wsId: string, fragment: string | null): string;
|
|
46
|
+
getDesignSystemEndpoint(dsId: string, fragment: string | null): string;
|
|
47
|
+
getVersionEndpoint(dsId: string, dsVersionId: string, fragment: string | null): string;
|
|
49
48
|
}
|
|
50
49
|
export {};
|