@uniformdev/canvas 20.29.2-alpha.6 → 20.30.1
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 +42 -16
- package/dist/index.d.ts +42 -16
- package/dist/index.esm.js +15 -5
- package/dist/index.js +15 -5
- package/dist/index.mjs +15 -5
- package/package.json +6 -7
package/dist/index.d.mts
CHANGED
@@ -2,7 +2,6 @@ import { ApiClient, ExceptProject, ClientOptions, ApiClientError } from '@unifor
|
|
2
2
|
export { ApiClientError } from '@uniformdev/context/api';
|
3
3
|
import { AssetGetResponseSingle, AssetParamValue, AssetParamValueItem } from '@uniformdev/assets';
|
4
4
|
export { AssetParamValue, AssetParamValueItem } from '@uniformdev/assets';
|
5
|
-
import { EndpointOut, EndpointHeadersOut, EndpointTransformationOut } from 'svix';
|
6
5
|
import { Quirks, StorageCommands, PersonalizedVariant, VariationMatchMetadata, TestVariant } from '@uniformdev/context';
|
7
6
|
import { Options as Options$1 } from 'p-retry';
|
8
7
|
import { Options } from 'p-throttle';
|
@@ -3095,7 +3094,13 @@ interface paths$h {
|
|
3095
3094
|
put: {
|
3096
3095
|
parameters: {
|
3097
3096
|
query?: never;
|
3098
|
-
header?:
|
3097
|
+
header?: {
|
3098
|
+
/** @description Optional concurrency control header. If provided, the server will check that the entry
|
3099
|
+
* has not been modified since this timestamp. If the timestamp doesn't match the current
|
3100
|
+
* modified timestamp, a 409 Conflict response will be returned.
|
3101
|
+
* */
|
3102
|
+
"X-If-Unmodified-Since"?: string;
|
3103
|
+
};
|
3099
3104
|
path?: never;
|
3100
3105
|
cookie?: never;
|
3101
3106
|
};
|
@@ -3169,6 +3174,15 @@ interface paths$h {
|
|
3169
3174
|
400: components$j["responses"]["BadRequestError"];
|
3170
3175
|
401: components$j["responses"]["UnauthorizedError"];
|
3171
3176
|
403: components$j["responses"]["ForbiddenError"];
|
3177
|
+
/** @description Conflict - Entry has been changed since being loaded */
|
3178
|
+
409: {
|
3179
|
+
headers: {
|
3180
|
+
[name: string]: unknown;
|
3181
|
+
};
|
3182
|
+
content: {
|
3183
|
+
"text/plain": string;
|
3184
|
+
};
|
3185
|
+
};
|
3172
3186
|
429: components$j["responses"]["RateLimitError"];
|
3173
3187
|
500: components$j["responses"]["InternalServerError"];
|
3174
3188
|
};
|
@@ -6285,7 +6299,13 @@ interface paths$a {
|
|
6285
6299
|
put: {
|
6286
6300
|
parameters: {
|
6287
6301
|
query?: never;
|
6288
|
-
header?:
|
6302
|
+
header?: {
|
6303
|
+
/** @description Optional concurrency control header. If provided, the server will check that the composition
|
6304
|
+
* has not been modified since this timestamp. If the timestamp doesn't match the current
|
6305
|
+
* modified timestamp, a 409 Conflict response will be returned.
|
6306
|
+
* */
|
6307
|
+
"X-If-Unmodified-Since"?: string;
|
6308
|
+
};
|
6289
6309
|
path?: never;
|
6290
6310
|
cookie?: never;
|
6291
6311
|
};
|
@@ -6375,6 +6395,15 @@ interface paths$a {
|
|
6375
6395
|
400: components$b["responses"]["BadRequestError"];
|
6376
6396
|
401: components$b["responses"]["UnauthorizedError"];
|
6377
6397
|
403: components$b["responses"]["ForbiddenError"];
|
6398
|
+
/** @description Conflict - Composition has been changed since being loaded */
|
6399
|
+
409: {
|
6400
|
+
headers: {
|
6401
|
+
[name: string]: unknown;
|
6402
|
+
};
|
6403
|
+
content: {
|
6404
|
+
"text/plain": string;
|
6405
|
+
};
|
6406
|
+
};
|
6378
6407
|
429: components$b["responses"]["RateLimitError"];
|
6379
6408
|
500: components$b["responses"]["InternalServerError"];
|
6380
6409
|
};
|
@@ -9704,14 +9733,6 @@ type CopiedComponentSubtree = {
|
|
9704
9733
|
* Defines how a component on a pattern may have its values overridden
|
9705
9734
|
*/
|
9706
9735
|
type ComponentOverridability = SharedComponents$1['ComponentOverridability'];
|
9707
|
-
/**
|
9708
|
-
* Defines the shape of serialized webhook
|
9709
|
-
*/
|
9710
|
-
type WebhookDefinition = {
|
9711
|
-
endpoint: EndpointOut;
|
9712
|
-
headers: EndpointHeadersOut | null;
|
9713
|
-
transformation: EndpointTransformationOut | null;
|
9714
|
-
};
|
9715
9736
|
/** Defines single structure to keep all canvas models (used in CLI commands and Starter content generations) */
|
9716
9737
|
type CanvasDefinitions = {
|
9717
9738
|
components?: Array<ComponentDefinition>;
|
@@ -9729,7 +9750,6 @@ type CanvasDefinitions = {
|
|
9729
9750
|
workflows?: Array<WorkflowDefinition>;
|
9730
9751
|
previewUrls?: Array<PreviewUrl>;
|
9731
9752
|
previewViewports?: Array<PreviewViewport>;
|
9732
|
-
webhooks?: Array<WebhookDefinition>;
|
9733
9753
|
};
|
9734
9754
|
/** Defines shared parameters for requests getting a single composition */
|
9735
9755
|
type CompositionGetOneSharedParameters = Pick<CompositionGetParameters, 'state' | 'skipEnhance' | 'skipPatternResolution' | 'withComponentIDs' | 'withUIStatus' | 'withWorkflowDefinition' | 'withProjectMapNodes' | 'withTotalCount' | 'skipOverridesResolution' | 'withContentSourceMap' | 'versionId' | 'locale' | 'releaseId' | 'editions'>;
|
@@ -11573,6 +11593,9 @@ type CanvasClientOptions = ClientOptions & {
|
|
11573
11593
|
edgeApiHost?: string;
|
11574
11594
|
disableSWR?: boolean;
|
11575
11595
|
};
|
11596
|
+
type UpdateCompositionOptions = {
|
11597
|
+
ifUnmodifiedSince?: string;
|
11598
|
+
};
|
11576
11599
|
declare class CanvasClient extends ApiClient<CanvasClientOptions> {
|
11577
11600
|
private edgeApiHost;
|
11578
11601
|
private edgeApiRequestInit?;
|
@@ -11614,7 +11637,7 @@ declare class CanvasClient extends ApiClient<CanvasClientOptions> {
|
|
11614
11637
|
}>;
|
11615
11638
|
private getOneComposition;
|
11616
11639
|
/** Updates or creates a Canvas component definition */
|
11617
|
-
updateComposition(body: Omit<CompositionPutParameters, 'projectId'
|
11640
|
+
updateComposition(body: Omit<CompositionPutParameters, 'projectId'>, options?: UpdateCompositionOptions): Promise<{
|
11618
11641
|
modified: string | null;
|
11619
11642
|
}>;
|
11620
11643
|
/** Deletes a Canvas component definition */
|
@@ -11647,6 +11670,9 @@ declare class UncachedCategoryClient extends CategoryClient {
|
|
11647
11670
|
constructor(options: Omit<ClientOptions, 'bypassCache'>);
|
11648
11671
|
}
|
11649
11672
|
|
11673
|
+
type UpsertEntryOptions = {
|
11674
|
+
ifUnmodifiedSince?: string;
|
11675
|
+
};
|
11650
11676
|
type ContentClientOptions = ClientOptions & {
|
11651
11677
|
edgeApiHost?: string;
|
11652
11678
|
disableSWR?: boolean;
|
@@ -11668,7 +11694,7 @@ declare class ContentClient extends ApiClient<ContentClientOptions> {
|
|
11668
11694
|
upsertContentType(body: ExceptProject<PutContentTypeBody>, opts?: {
|
11669
11695
|
autogenerateDataTypes?: boolean;
|
11670
11696
|
}): Promise<void>;
|
11671
|
-
upsertEntry(body: ExceptProject<PutEntryBody
|
11697
|
+
upsertEntry(body: ExceptProject<PutEntryBody>, options?: UpsertEntryOptions): Promise<{
|
11672
11698
|
modified: string | null;
|
11673
11699
|
}>;
|
11674
11700
|
deleteContentType(body: ExceptProject<DeleteContentTypeOptions>): Promise<void>;
|
@@ -13304,7 +13330,7 @@ declare function hasReferencedVariables(value: string | undefined): number;
|
|
13304
13330
|
*/
|
13305
13331
|
declare function parseVariableExpression(serialized: string, onToken?: (token: string, type: 'text' | 'variable') => void | false): number;
|
13306
13332
|
|
13307
|
-
declare const version = "20.
|
13333
|
+
declare const version = "20.30.1";
|
13308
13334
|
|
13309
13335
|
/** API client to enable managing workflow definitions */
|
13310
13336
|
declare class WorkflowClient extends ApiClient {
|
@@ -13321,4 +13347,4 @@ declare class WorkflowClient extends ApiClient {
|
|
13321
13347
|
|
13322
13348
|
declare const CanvasClientError: typeof ApiClientError;
|
13323
13349
|
|
13324
|
-
export { ASSETS_SOURCE_CUSTOM_URL, ASSETS_SOURCE_UNIFORM, ASSET_PARAMETER_TYPE, ATTRIBUTE_COMPONENT_ID, ATTRIBUTE_MULTILINE, ATTRIBUTE_PARAMETER_ID, ATTRIBUTE_PARAMETER_TYPE, ATTRIBUTE_PARAMETER_VALUE, ATTRIBUTE_PLACEHOLDER, type AddComponentMessage, type BatchEnhancer, BatchEntry, type BatchInvalidationPayload, type BindVariablesOptions, type BindVariablesResult, type BindVariablesToObjectOptions, BlockFormatError, type BlockLocationReference, type BlockValue, CANVAS_BLOCK_PARAM_TYPE, CANVAS_CONTEXTUAL_EDITING_PARAM, CANVAS_DRAFT_STATE, CANVAS_EDITOR_STATE, CANVAS_ENRICHMENT_TAG_PARAM, CANVAS_INTENT_TAG_PARAM, CANVAS_LOCALE_TAG_PARAM, CANVAS_LOCALIZATION_SLOT, CANVAS_LOCALIZATION_TYPE, CANVAS_PERSONALIZATION_ALGORITHM_PARAM, CANVAS_PERSONALIZATION_ALGORITHM_TYPE, CANVAS_PERSONALIZATION_EVENT_NAME_PARAM, CANVAS_PERSONALIZATION_PARAM, CANVAS_PERSONALIZATION_TAKE_PARAM, CANVAS_PERSONALIZE_SLOT, CANVAS_PERSONALIZE_TYPE, CANVAS_PUBLISHED_STATE, CANVAS_SLOT_SECTION_SLOT, CANVAS_SLOT_SECTION_TYPE, CANVAS_TEST_SLOT, CANVAS_TEST_TYPE, CANVAS_TEST_VARIANT_PARAM, CANVAS_VIZ_CONTROL_PARAM, CANVAS_VIZ_DI_RULE, CANVAS_VIZ_DYNAMIC_TOKEN_RULE, CANVAS_VIZ_LOCALE_RULE, CANVAS_VIZ_QUIRKS_RULE, CanvasClient, CanvasClientError, type CanvasDefinitions, type CategoriesDeleteParameters, type CategoriesGetParameters, type CategoriesGetResponse, type CategoriesPutParameters, type Category, CategoryClient, type Channel, type ChannelMessage, ChildEnhancerBuilder, type ComponentDefinition, type ComponentDefinitionDeleteParameters, type ComponentDefinitionGetParameters, type ComponentDefinitionGetResponse, type ComponentDefinitionParameter, type ComponentDefinitionPermission, type ComponentDefinitionPutParameters, type ComponentDefinitionSlot, type ComponentDefinitionSlugSettings, type ComponentDefinitionVariant, type ComponentEnhancer, type ComponentEnhancerFunction, type ComponentEnhancerOptions, type ComponentInstance, type ComponentInstanceContextualEditing, type ComponentInstanceHistoryEntry, type ComponentInstanceHistoryGetParameters, type ComponentInstanceHistoryGetResponse, type ComponentLocationReference, type ComponentOverridability, type ComponentOverride, type ComponentOverrides, type ComponentParameter, type ComponentParameterBlock, type ComponentParameterConditionalValue, type ComponentParameterContextualEditing, type ComponentParameterEnhancer, type ComponentParameterEnhancerFunction, type ComponentParameterEnhancerOptions, type CompositionDeleteParameters, type CompositionFilters, type CompositionGetByComponentIdParameters, type CompositionGetByIdParameters, type CompositionGetByNodeIdParameters, type CompositionGetByNodePathParameters, type CompositionGetBySlugParameters, type CompositionGetListResponse, type CompositionGetParameters, type CompositionGetResponse, type CompositionGetValidResponses, type CompositionPutParameters, type CompositionResolvedGetResponse, type CompositionResolvedListResponse, type CompositionUIStatus, ContentClient, type ContentType, type ContentTypeField, type ContentTypePreviewConfiguration, type ContextStorageUpdatedMessage, type ContextualEditingComponentReference, type ContextualEditingValue, type CopiedComponentSubtree, type DataDiagnostic, type DataElementBindingIssue, type DataElementConnectionDefinition, type DataElementConnectionFailureAction, type DataElementConnectionFailureLogLevel, type DataResolutionConfigIssue, type DataResolutionIssue, type DataResolutionOption, type DataResolutionOptionNegative, type DataResolutionOptionPositive, type DataResolutionParameters, type DataResourceDefinition, type DataResourceDefinitions, type DataResourceIssue, type DataResourceVariables, type DataSource, DataSourceClient, type DataSourceDeleteParameters, type DataSourceGetParameters, type DataSourceGetResponse, type DataSourcePutParameters, type DataSourceVariantData, type DataSourceVariantsKeys, type DataSourcesGetParameters, type DataSourcesGetResponse, type DataType, DataTypeClient, type DataTypeDeleteParameters, type DataTypeGetParameters, type DataTypeGetResponse, type DataTypePutParameters, type DataVariableDefinition, type DataWithProperties, type DeleteContentTypeOptions, type DeleteEntryOptions, type DismissPlaceholderMessage, type DynamicInputIssue, EDGE_CACHE_DISABLED, EDGE_DEFAULT_CACHE_TTL, EDGE_MAX_CACHE_TTL, EDGE_MIN_CACHE_TTL, EMPTY_COMPOSITION, type EdgehancersDiagnostics, type EdgehancersWholeResponseCacheDiagnostics, type EditorStateUpdatedMessage, EnhancerBuilder, type EnhancerContext, type EnhancerError, EntityReleasesClient, type EntityReleasesGetParameters, type EntityReleasesGetResponse, type EntriesGetParameters, type EntriesGetResponse, type EntriesHistoryGetParameters, type EntriesHistoryGetResponse, type EntriesResolvedListResponse, type Entry, type EntryData, type EntryFilters, type EntryList, type EvaluateCriteriaGroupOptions, type EvaluateNodeTreeVisibilityOptions, type EvaluateNodeVisibilityParameterOptions, type EvaluatePropertyCriteriaOptions, type EvaluateWalkTreePropertyCriteriaOptions, type Filters, type FindInNodeTreeReference, type FlattenProperty, type FlattenValues, type FlattenValuesOptions, type GetContentTypesOptions, type GetContentTypesResponse, type GetEffectivePropertyValueOptions, type GetEntriesOptions, type GetEntriesResponse, type GetParameterAttributesProps, IN_CONTEXT_EDITOR_COMPONENT_END_ROLE, IN_CONTEXT_EDITOR_COMPONENT_START_ROLE, IN_CONTEXT_EDITOR_CONFIG_CHECK_QUERY_STRING_PARAM, IN_CONTEXT_EDITOR_EMBED_SCRIPT_ID, IN_CONTEXT_EDITOR_FORCED_SETTINGS_QUERY_STRING_PARAM, IN_CONTEXT_EDITOR_PLAYGROUND_QUERY_STRING_PARAM, IN_CONTEXT_EDITOR_QUERY_STRING_PARAM, IS_RENDERED_BY_UNIFORM_ATTRIBUTE, type InvalidationPayload, LOCALE_DYNAMIC_INPUT_NAME, type LimitPolicy, type LinkParamConfiguration, type LinkParamValue, type LinkParameterType, type LinkTypeConfiguration, type Locale, LocaleClient, type LocaleDeleteParameters, type LocalePutParameters, type LocalesGetParameters, type LocalesGetResponse, type LocalizeOptions, type MaxDepthExceededIssue, type MessageHandler, type MoveComponentMessage, type MultiSelectParamConfiguration, type MultiSelectParamValue, type NodeLocationReference, type NonProjectMapLinkParamValue, type NumberParamConfig, type NumberParamValue, type OpenParameterEditorMessage, type OverrideOptions, PLACEHOLDER_ID, type PatternIssue, PreviewClient, type PreviewPanelSettings, type PreviewUrl, type PreviewUrlDeleteParameters, type PreviewUrlDeleteResponse, type PreviewUrlPutParameters, type PreviewUrlPutResponse, type PreviewUrlsGetParameters, type PreviewUrlsGetResponse, type PreviewViewport, type PreviewViewportDeleteParameters, type PreviewViewportDeleteResponse, type PreviewViewportPutParameters, type PreviewViewportPutResponse, type PreviewViewportsGetParameters, type PreviewViewportsGetResponse, type Project, ProjectClient, type ProjectDeleteParameters, type ProjectGetParameters, type ProjectGetResponse, type ProjectMapLinkParamValue, type ProjectPutParameters, type ProjectPutResponse, type Prompt, PromptClient, type PromptsDeleteParameters, type PromptsGetParameters, type PromptsGetResponse, type PromptsPutParameters, type PropertyCriteriaMatch, type PropertyValue, type PutContentTypeBody, type PutEntryBody, type ReadyMessage, RelationshipClient, type RelationshipResultInstance, type Release, ReleaseClient, type ReleaseContent, ReleaseContentsClient, type ReleaseContentsDeleteBody, type ReleaseContentsGetParameters, type ReleaseContentsGetResponse, type ReleaseDeleteParameters, type ReleasePatchParameters, type ReleasePutParameters, type ReleaseState, type ReleasesGetParameters, type ReleasesGetResponse, type ReportRenderedCompositionsMessage, type RequestComponentSuggestionMessage, type RequestPageHtmlMessage, type ResolvedRouteGetResponse, type RichTextBuiltInElement, type RichTextBuiltInFormat, type RichTextParamConfiguration, type RichTextParamValue, type RootComponentInstance, type RootEntryReference, type RootLocationReference, RouteClient, type RouteDynamicInputs, type RouteGetParameters, type RouteGetResponse, type RouteGetResponseComposition, type RouteGetResponseEdgehancedComposition, type RouteGetResponseEdgehancedNotFound, type RouteGetResponseNotFound, type RouteGetResponseRedirect, SECRET_QUERY_STRING_PARAM, type SelectComponentMessage, type SelectParamConfiguration, type SelectParamOption, type SelectParamValue, type SelectParameterMessage, type SendPageHtmlMessage, type SpecificProjectMap, type StringOperators, type SuggestComponentMessage, type TreeNodeInfoTypes, type TriggerComponentActionMessage, type TriggerCompositionActionMessage, UncachedCanvasClient, UncachedCategoryClient, UncachedContentClient, UniqueBatchEntries, type UpdateComponentParameterMessage, type UpdateComponentReferencesMessage, type UpdateCompositionInternalMessage, type UpdateCompositionMessage, type UpdateContextualEditingStateInternalMessage, type UpdateFeatureFlagsMessage, type UpdatePreviewSettingsMessage, type VisibilityCriteria, type VisibilityCriteriaEvaluationResult, type VisibilityCriteriaGroup, type VisibilityParameterValue, type VisibilityRule, type VisibilityRules, type WalkNodeTreeActions, type WalkNodeTreeOptions, type WebhookDefinition, WorkflowClient, type WorkflowDefinition, type WorkflowStage, type WorkflowStagePermission, type WorkflowStageTransition, type WorkflowStageTransitionPermission, type WorkflowsDeleteParameters, type WorkflowsGetParameters, type WorkflowsGetResponse, type WorkflowsPutParameters, bindExpressionEscapeChars, bindExpressionPrefix, bindVariables, bindVariablesToObject, compose, convertEntryToPutEntry, convertToBindExpression, createBatchEnhancer, createCanvasChannel, createDynamicInputVisibilityRule, createDynamicTokenVisibilityRule, createLimitPolicy, createLocaleVisibilityRule, createQuirksVisibilityRule, createUniformApiEnhancer, createVariableReference, enhance, escapeBindExpressionDefaultValue, evaluateNodeVisibilityParameter, evaluatePropertyCriteria, evaluateVisibilityCriteriaGroup, evaluateWalkTreeNodeVisibility, evaluateWalkTreePropertyCriteria, extractLocales, findParameterInNodeTree, flattenValues, generateComponentPlaceholderId, generateHash, getBlockValue, getComponentJsonPointer, getComponentPath, getDataSourceVariantFromRouteGetParams, getEffectivePropertyValue, getLocalizedPropertyValues, getNounForLocation, getNounForNode, getParameterAttributes, getPropertiesValue, hasReferencedVariables, isAddComponentMessage, isAllowedReferrer, isAssetParamValue, isAssetParamValueItem, isComponentActionMessage, isComponentPlaceholderId, isContextStorageUpdatedMessage, isDismissPlaceholderMessage, isEntryData, isLinkParamValue, isMovingComponentMessage, isNestedNodeType, isOpenParameterEditorMessage, isReadyMessage, isReportRenderedCompositionsMessage, isRequestComponentSuggestionMessage, isRootEntryReference, isSelectComponentMessage, isSelectParameterMessage, isSuggestComponentMessage, isSystemComponentDefinition, isTriggerCompositionActionMessage, isUpdateComponentParameterMessage, isUpdateComponentReferencesMessage, isUpdateCompositionInternalMessage, isUpdateCompositionMessage, isUpdateContextualEditingStateInternalMessage, isUpdateFeatureFlagsMessage, isUpdatePreviewSettingsMessage, localize, mapSlotToPersonalizedVariations, mapSlotToTestVariations, nullLimitPolicy, parseComponentPlaceholderId, parseVariableExpression, version, walkNodeTree, walkPropertyValues };
|
13350
|
+
export { ASSETS_SOURCE_CUSTOM_URL, ASSETS_SOURCE_UNIFORM, ASSET_PARAMETER_TYPE, ATTRIBUTE_COMPONENT_ID, ATTRIBUTE_MULTILINE, ATTRIBUTE_PARAMETER_ID, ATTRIBUTE_PARAMETER_TYPE, ATTRIBUTE_PARAMETER_VALUE, ATTRIBUTE_PLACEHOLDER, type AddComponentMessage, type BatchEnhancer, BatchEntry, type BatchInvalidationPayload, type BindVariablesOptions, type BindVariablesResult, type BindVariablesToObjectOptions, BlockFormatError, type BlockLocationReference, type BlockValue, CANVAS_BLOCK_PARAM_TYPE, CANVAS_CONTEXTUAL_EDITING_PARAM, CANVAS_DRAFT_STATE, CANVAS_EDITOR_STATE, CANVAS_ENRICHMENT_TAG_PARAM, CANVAS_INTENT_TAG_PARAM, CANVAS_LOCALE_TAG_PARAM, CANVAS_LOCALIZATION_SLOT, CANVAS_LOCALIZATION_TYPE, CANVAS_PERSONALIZATION_ALGORITHM_PARAM, CANVAS_PERSONALIZATION_ALGORITHM_TYPE, CANVAS_PERSONALIZATION_EVENT_NAME_PARAM, CANVAS_PERSONALIZATION_PARAM, CANVAS_PERSONALIZATION_TAKE_PARAM, CANVAS_PERSONALIZE_SLOT, CANVAS_PERSONALIZE_TYPE, CANVAS_PUBLISHED_STATE, CANVAS_SLOT_SECTION_SLOT, CANVAS_SLOT_SECTION_TYPE, CANVAS_TEST_SLOT, CANVAS_TEST_TYPE, CANVAS_TEST_VARIANT_PARAM, CANVAS_VIZ_CONTROL_PARAM, CANVAS_VIZ_DI_RULE, CANVAS_VIZ_DYNAMIC_TOKEN_RULE, CANVAS_VIZ_LOCALE_RULE, CANVAS_VIZ_QUIRKS_RULE, CanvasClient, CanvasClientError, type CanvasDefinitions, type CategoriesDeleteParameters, type CategoriesGetParameters, type CategoriesGetResponse, type CategoriesPutParameters, type Category, CategoryClient, type Channel, type ChannelMessage, ChildEnhancerBuilder, type ComponentDefinition, type ComponentDefinitionDeleteParameters, type ComponentDefinitionGetParameters, type ComponentDefinitionGetResponse, type ComponentDefinitionParameter, type ComponentDefinitionPermission, type ComponentDefinitionPutParameters, type ComponentDefinitionSlot, type ComponentDefinitionSlugSettings, type ComponentDefinitionVariant, type ComponentEnhancer, type ComponentEnhancerFunction, type ComponentEnhancerOptions, type ComponentInstance, type ComponentInstanceContextualEditing, type ComponentInstanceHistoryEntry, type ComponentInstanceHistoryGetParameters, type ComponentInstanceHistoryGetResponse, type ComponentLocationReference, type ComponentOverridability, type ComponentOverride, type ComponentOverrides, type ComponentParameter, type ComponentParameterBlock, type ComponentParameterConditionalValue, type ComponentParameterContextualEditing, type ComponentParameterEnhancer, type ComponentParameterEnhancerFunction, type ComponentParameterEnhancerOptions, type CompositionDeleteParameters, type CompositionFilters, type CompositionGetByComponentIdParameters, type CompositionGetByIdParameters, type CompositionGetByNodeIdParameters, type CompositionGetByNodePathParameters, type CompositionGetBySlugParameters, type CompositionGetListResponse, type CompositionGetParameters, type CompositionGetResponse, type CompositionGetValidResponses, type CompositionPutParameters, type CompositionResolvedGetResponse, type CompositionResolvedListResponse, type CompositionUIStatus, ContentClient, type ContentType, type ContentTypeField, type ContentTypePreviewConfiguration, type ContextStorageUpdatedMessage, type ContextualEditingComponentReference, type ContextualEditingValue, type CopiedComponentSubtree, type DataDiagnostic, type DataElementBindingIssue, type DataElementConnectionDefinition, type DataElementConnectionFailureAction, type DataElementConnectionFailureLogLevel, type DataResolutionConfigIssue, type DataResolutionIssue, type DataResolutionOption, type DataResolutionOptionNegative, type DataResolutionOptionPositive, type DataResolutionParameters, type DataResourceDefinition, type DataResourceDefinitions, type DataResourceIssue, type DataResourceVariables, type DataSource, DataSourceClient, type DataSourceDeleteParameters, type DataSourceGetParameters, type DataSourceGetResponse, type DataSourcePutParameters, type DataSourceVariantData, type DataSourceVariantsKeys, type DataSourcesGetParameters, type DataSourcesGetResponse, type DataType, DataTypeClient, type DataTypeDeleteParameters, type DataTypeGetParameters, type DataTypeGetResponse, type DataTypePutParameters, type DataVariableDefinition, type DataWithProperties, type DeleteContentTypeOptions, type DeleteEntryOptions, type DismissPlaceholderMessage, type DynamicInputIssue, EDGE_CACHE_DISABLED, EDGE_DEFAULT_CACHE_TTL, EDGE_MAX_CACHE_TTL, EDGE_MIN_CACHE_TTL, EMPTY_COMPOSITION, type EdgehancersDiagnostics, type EdgehancersWholeResponseCacheDiagnostics, type EditorStateUpdatedMessage, EnhancerBuilder, type EnhancerContext, type EnhancerError, EntityReleasesClient, type EntityReleasesGetParameters, type EntityReleasesGetResponse, type EntriesGetParameters, type EntriesGetResponse, type EntriesHistoryGetParameters, type EntriesHistoryGetResponse, type EntriesResolvedListResponse, type Entry, type EntryData, type EntryFilters, type EntryList, type EvaluateCriteriaGroupOptions, type EvaluateNodeTreeVisibilityOptions, type EvaluateNodeVisibilityParameterOptions, type EvaluatePropertyCriteriaOptions, type EvaluateWalkTreePropertyCriteriaOptions, type Filters, type FindInNodeTreeReference, type FlattenProperty, type FlattenValues, type FlattenValuesOptions, type GetContentTypesOptions, type GetContentTypesResponse, type GetEffectivePropertyValueOptions, type GetEntriesOptions, type GetEntriesResponse, type GetParameterAttributesProps, IN_CONTEXT_EDITOR_COMPONENT_END_ROLE, IN_CONTEXT_EDITOR_COMPONENT_START_ROLE, IN_CONTEXT_EDITOR_CONFIG_CHECK_QUERY_STRING_PARAM, IN_CONTEXT_EDITOR_EMBED_SCRIPT_ID, IN_CONTEXT_EDITOR_FORCED_SETTINGS_QUERY_STRING_PARAM, IN_CONTEXT_EDITOR_PLAYGROUND_QUERY_STRING_PARAM, IN_CONTEXT_EDITOR_QUERY_STRING_PARAM, IS_RENDERED_BY_UNIFORM_ATTRIBUTE, type InvalidationPayload, LOCALE_DYNAMIC_INPUT_NAME, type LimitPolicy, type LinkParamConfiguration, type LinkParamValue, type LinkParameterType, type LinkTypeConfiguration, type Locale, LocaleClient, type LocaleDeleteParameters, type LocalePutParameters, type LocalesGetParameters, type LocalesGetResponse, type LocalizeOptions, type MaxDepthExceededIssue, type MessageHandler, type MoveComponentMessage, type MultiSelectParamConfiguration, type MultiSelectParamValue, type NodeLocationReference, type NonProjectMapLinkParamValue, type NumberParamConfig, type NumberParamValue, type OpenParameterEditorMessage, type OverrideOptions, PLACEHOLDER_ID, type PatternIssue, PreviewClient, type PreviewPanelSettings, type PreviewUrl, type PreviewUrlDeleteParameters, type PreviewUrlDeleteResponse, type PreviewUrlPutParameters, type PreviewUrlPutResponse, type PreviewUrlsGetParameters, type PreviewUrlsGetResponse, type PreviewViewport, type PreviewViewportDeleteParameters, type PreviewViewportDeleteResponse, type PreviewViewportPutParameters, type PreviewViewportPutResponse, type PreviewViewportsGetParameters, type PreviewViewportsGetResponse, type Project, ProjectClient, type ProjectDeleteParameters, type ProjectGetParameters, type ProjectGetResponse, type ProjectMapLinkParamValue, type ProjectPutParameters, type ProjectPutResponse, type Prompt, PromptClient, type PromptsDeleteParameters, type PromptsGetParameters, type PromptsGetResponse, type PromptsPutParameters, type PropertyCriteriaMatch, type PropertyValue, type PutContentTypeBody, type PutEntryBody, type ReadyMessage, RelationshipClient, type RelationshipResultInstance, type Release, ReleaseClient, type ReleaseContent, ReleaseContentsClient, type ReleaseContentsDeleteBody, type ReleaseContentsGetParameters, type ReleaseContentsGetResponse, type ReleaseDeleteParameters, type ReleasePatchParameters, type ReleasePutParameters, type ReleaseState, type ReleasesGetParameters, type ReleasesGetResponse, type ReportRenderedCompositionsMessage, type RequestComponentSuggestionMessage, type RequestPageHtmlMessage, type ResolvedRouteGetResponse, type RichTextBuiltInElement, type RichTextBuiltInFormat, type RichTextParamConfiguration, type RichTextParamValue, type RootComponentInstance, type RootEntryReference, type RootLocationReference, RouteClient, type RouteDynamicInputs, type RouteGetParameters, type RouteGetResponse, type RouteGetResponseComposition, type RouteGetResponseEdgehancedComposition, type RouteGetResponseEdgehancedNotFound, type RouteGetResponseNotFound, type RouteGetResponseRedirect, SECRET_QUERY_STRING_PARAM, type SelectComponentMessage, type SelectParamConfiguration, type SelectParamOption, type SelectParamValue, type SelectParameterMessage, type SendPageHtmlMessage, type SpecificProjectMap, type StringOperators, type SuggestComponentMessage, type TreeNodeInfoTypes, type TriggerComponentActionMessage, type TriggerCompositionActionMessage, UncachedCanvasClient, UncachedCategoryClient, UncachedContentClient, UniqueBatchEntries, type UpdateComponentParameterMessage, type UpdateComponentReferencesMessage, type UpdateCompositionInternalMessage, type UpdateCompositionMessage, type UpdateCompositionOptions, type UpdateContextualEditingStateInternalMessage, type UpdateFeatureFlagsMessage, type UpdatePreviewSettingsMessage, type UpsertEntryOptions, type VisibilityCriteria, type VisibilityCriteriaEvaluationResult, type VisibilityCriteriaGroup, type VisibilityParameterValue, type VisibilityRule, type VisibilityRules, type WalkNodeTreeActions, type WalkNodeTreeOptions, WorkflowClient, type WorkflowDefinition, type WorkflowStage, type WorkflowStagePermission, type WorkflowStageTransition, type WorkflowStageTransitionPermission, type WorkflowsDeleteParameters, type WorkflowsGetParameters, type WorkflowsGetResponse, type WorkflowsPutParameters, bindExpressionEscapeChars, bindExpressionPrefix, bindVariables, bindVariablesToObject, compose, convertEntryToPutEntry, convertToBindExpression, createBatchEnhancer, createCanvasChannel, createDynamicInputVisibilityRule, createDynamicTokenVisibilityRule, createLimitPolicy, createLocaleVisibilityRule, createQuirksVisibilityRule, createUniformApiEnhancer, createVariableReference, enhance, escapeBindExpressionDefaultValue, evaluateNodeVisibilityParameter, evaluatePropertyCriteria, evaluateVisibilityCriteriaGroup, evaluateWalkTreeNodeVisibility, evaluateWalkTreePropertyCriteria, extractLocales, findParameterInNodeTree, flattenValues, generateComponentPlaceholderId, generateHash, getBlockValue, getComponentJsonPointer, getComponentPath, getDataSourceVariantFromRouteGetParams, getEffectivePropertyValue, getLocalizedPropertyValues, getNounForLocation, getNounForNode, getParameterAttributes, getPropertiesValue, hasReferencedVariables, isAddComponentMessage, isAllowedReferrer, isAssetParamValue, isAssetParamValueItem, isComponentActionMessage, isComponentPlaceholderId, isContextStorageUpdatedMessage, isDismissPlaceholderMessage, isEntryData, isLinkParamValue, isMovingComponentMessage, isNestedNodeType, isOpenParameterEditorMessage, isReadyMessage, isReportRenderedCompositionsMessage, isRequestComponentSuggestionMessage, isRootEntryReference, isSelectComponentMessage, isSelectParameterMessage, isSuggestComponentMessage, isSystemComponentDefinition, isTriggerCompositionActionMessage, isUpdateComponentParameterMessage, isUpdateComponentReferencesMessage, isUpdateCompositionInternalMessage, isUpdateCompositionMessage, isUpdateContextualEditingStateInternalMessage, isUpdateFeatureFlagsMessage, isUpdatePreviewSettingsMessage, localize, mapSlotToPersonalizedVariations, mapSlotToTestVariations, nullLimitPolicy, parseComponentPlaceholderId, parseVariableExpression, version, walkNodeTree, walkPropertyValues };
|
package/dist/index.d.ts
CHANGED
@@ -2,7 +2,6 @@ import { ApiClient, ExceptProject, ClientOptions, ApiClientError } from '@unifor
|
|
2
2
|
export { ApiClientError } from '@uniformdev/context/api';
|
3
3
|
import { AssetGetResponseSingle, AssetParamValue, AssetParamValueItem } from '@uniformdev/assets';
|
4
4
|
export { AssetParamValue, AssetParamValueItem } from '@uniformdev/assets';
|
5
|
-
import { EndpointOut, EndpointHeadersOut, EndpointTransformationOut } from 'svix';
|
6
5
|
import { Quirks, StorageCommands, PersonalizedVariant, VariationMatchMetadata, TestVariant } from '@uniformdev/context';
|
7
6
|
import { Options as Options$1 } from 'p-retry';
|
8
7
|
import { Options } from 'p-throttle';
|
@@ -3095,7 +3094,13 @@ interface paths$h {
|
|
3095
3094
|
put: {
|
3096
3095
|
parameters: {
|
3097
3096
|
query?: never;
|
3098
|
-
header?:
|
3097
|
+
header?: {
|
3098
|
+
/** @description Optional concurrency control header. If provided, the server will check that the entry
|
3099
|
+
* has not been modified since this timestamp. If the timestamp doesn't match the current
|
3100
|
+
* modified timestamp, a 409 Conflict response will be returned.
|
3101
|
+
* */
|
3102
|
+
"X-If-Unmodified-Since"?: string;
|
3103
|
+
};
|
3099
3104
|
path?: never;
|
3100
3105
|
cookie?: never;
|
3101
3106
|
};
|
@@ -3169,6 +3174,15 @@ interface paths$h {
|
|
3169
3174
|
400: components$j["responses"]["BadRequestError"];
|
3170
3175
|
401: components$j["responses"]["UnauthorizedError"];
|
3171
3176
|
403: components$j["responses"]["ForbiddenError"];
|
3177
|
+
/** @description Conflict - Entry has been changed since being loaded */
|
3178
|
+
409: {
|
3179
|
+
headers: {
|
3180
|
+
[name: string]: unknown;
|
3181
|
+
};
|
3182
|
+
content: {
|
3183
|
+
"text/plain": string;
|
3184
|
+
};
|
3185
|
+
};
|
3172
3186
|
429: components$j["responses"]["RateLimitError"];
|
3173
3187
|
500: components$j["responses"]["InternalServerError"];
|
3174
3188
|
};
|
@@ -6285,7 +6299,13 @@ interface paths$a {
|
|
6285
6299
|
put: {
|
6286
6300
|
parameters: {
|
6287
6301
|
query?: never;
|
6288
|
-
header?:
|
6302
|
+
header?: {
|
6303
|
+
/** @description Optional concurrency control header. If provided, the server will check that the composition
|
6304
|
+
* has not been modified since this timestamp. If the timestamp doesn't match the current
|
6305
|
+
* modified timestamp, a 409 Conflict response will be returned.
|
6306
|
+
* */
|
6307
|
+
"X-If-Unmodified-Since"?: string;
|
6308
|
+
};
|
6289
6309
|
path?: never;
|
6290
6310
|
cookie?: never;
|
6291
6311
|
};
|
@@ -6375,6 +6395,15 @@ interface paths$a {
|
|
6375
6395
|
400: components$b["responses"]["BadRequestError"];
|
6376
6396
|
401: components$b["responses"]["UnauthorizedError"];
|
6377
6397
|
403: components$b["responses"]["ForbiddenError"];
|
6398
|
+
/** @description Conflict - Composition has been changed since being loaded */
|
6399
|
+
409: {
|
6400
|
+
headers: {
|
6401
|
+
[name: string]: unknown;
|
6402
|
+
};
|
6403
|
+
content: {
|
6404
|
+
"text/plain": string;
|
6405
|
+
};
|
6406
|
+
};
|
6378
6407
|
429: components$b["responses"]["RateLimitError"];
|
6379
6408
|
500: components$b["responses"]["InternalServerError"];
|
6380
6409
|
};
|
@@ -9704,14 +9733,6 @@ type CopiedComponentSubtree = {
|
|
9704
9733
|
* Defines how a component on a pattern may have its values overridden
|
9705
9734
|
*/
|
9706
9735
|
type ComponentOverridability = SharedComponents$1['ComponentOverridability'];
|
9707
|
-
/**
|
9708
|
-
* Defines the shape of serialized webhook
|
9709
|
-
*/
|
9710
|
-
type WebhookDefinition = {
|
9711
|
-
endpoint: EndpointOut;
|
9712
|
-
headers: EndpointHeadersOut | null;
|
9713
|
-
transformation: EndpointTransformationOut | null;
|
9714
|
-
};
|
9715
9736
|
/** Defines single structure to keep all canvas models (used in CLI commands and Starter content generations) */
|
9716
9737
|
type CanvasDefinitions = {
|
9717
9738
|
components?: Array<ComponentDefinition>;
|
@@ -9729,7 +9750,6 @@ type CanvasDefinitions = {
|
|
9729
9750
|
workflows?: Array<WorkflowDefinition>;
|
9730
9751
|
previewUrls?: Array<PreviewUrl>;
|
9731
9752
|
previewViewports?: Array<PreviewViewport>;
|
9732
|
-
webhooks?: Array<WebhookDefinition>;
|
9733
9753
|
};
|
9734
9754
|
/** Defines shared parameters for requests getting a single composition */
|
9735
9755
|
type CompositionGetOneSharedParameters = Pick<CompositionGetParameters, 'state' | 'skipEnhance' | 'skipPatternResolution' | 'withComponentIDs' | 'withUIStatus' | 'withWorkflowDefinition' | 'withProjectMapNodes' | 'withTotalCount' | 'skipOverridesResolution' | 'withContentSourceMap' | 'versionId' | 'locale' | 'releaseId' | 'editions'>;
|
@@ -11573,6 +11593,9 @@ type CanvasClientOptions = ClientOptions & {
|
|
11573
11593
|
edgeApiHost?: string;
|
11574
11594
|
disableSWR?: boolean;
|
11575
11595
|
};
|
11596
|
+
type UpdateCompositionOptions = {
|
11597
|
+
ifUnmodifiedSince?: string;
|
11598
|
+
};
|
11576
11599
|
declare class CanvasClient extends ApiClient<CanvasClientOptions> {
|
11577
11600
|
private edgeApiHost;
|
11578
11601
|
private edgeApiRequestInit?;
|
@@ -11614,7 +11637,7 @@ declare class CanvasClient extends ApiClient<CanvasClientOptions> {
|
|
11614
11637
|
}>;
|
11615
11638
|
private getOneComposition;
|
11616
11639
|
/** Updates or creates a Canvas component definition */
|
11617
|
-
updateComposition(body: Omit<CompositionPutParameters, 'projectId'
|
11640
|
+
updateComposition(body: Omit<CompositionPutParameters, 'projectId'>, options?: UpdateCompositionOptions): Promise<{
|
11618
11641
|
modified: string | null;
|
11619
11642
|
}>;
|
11620
11643
|
/** Deletes a Canvas component definition */
|
@@ -11647,6 +11670,9 @@ declare class UncachedCategoryClient extends CategoryClient {
|
|
11647
11670
|
constructor(options: Omit<ClientOptions, 'bypassCache'>);
|
11648
11671
|
}
|
11649
11672
|
|
11673
|
+
type UpsertEntryOptions = {
|
11674
|
+
ifUnmodifiedSince?: string;
|
11675
|
+
};
|
11650
11676
|
type ContentClientOptions = ClientOptions & {
|
11651
11677
|
edgeApiHost?: string;
|
11652
11678
|
disableSWR?: boolean;
|
@@ -11668,7 +11694,7 @@ declare class ContentClient extends ApiClient<ContentClientOptions> {
|
|
11668
11694
|
upsertContentType(body: ExceptProject<PutContentTypeBody>, opts?: {
|
11669
11695
|
autogenerateDataTypes?: boolean;
|
11670
11696
|
}): Promise<void>;
|
11671
|
-
upsertEntry(body: ExceptProject<PutEntryBody
|
11697
|
+
upsertEntry(body: ExceptProject<PutEntryBody>, options?: UpsertEntryOptions): Promise<{
|
11672
11698
|
modified: string | null;
|
11673
11699
|
}>;
|
11674
11700
|
deleteContentType(body: ExceptProject<DeleteContentTypeOptions>): Promise<void>;
|
@@ -13304,7 +13330,7 @@ declare function hasReferencedVariables(value: string | undefined): number;
|
|
13304
13330
|
*/
|
13305
13331
|
declare function parseVariableExpression(serialized: string, onToken?: (token: string, type: 'text' | 'variable') => void | false): number;
|
13306
13332
|
|
13307
|
-
declare const version = "20.
|
13333
|
+
declare const version = "20.30.1";
|
13308
13334
|
|
13309
13335
|
/** API client to enable managing workflow definitions */
|
13310
13336
|
declare class WorkflowClient extends ApiClient {
|
@@ -13321,4 +13347,4 @@ declare class WorkflowClient extends ApiClient {
|
|
13321
13347
|
|
13322
13348
|
declare const CanvasClientError: typeof ApiClientError;
|
13323
13349
|
|
13324
|
-
export { ASSETS_SOURCE_CUSTOM_URL, ASSETS_SOURCE_UNIFORM, ASSET_PARAMETER_TYPE, ATTRIBUTE_COMPONENT_ID, ATTRIBUTE_MULTILINE, ATTRIBUTE_PARAMETER_ID, ATTRIBUTE_PARAMETER_TYPE, ATTRIBUTE_PARAMETER_VALUE, ATTRIBUTE_PLACEHOLDER, type AddComponentMessage, type BatchEnhancer, BatchEntry, type BatchInvalidationPayload, type BindVariablesOptions, type BindVariablesResult, type BindVariablesToObjectOptions, BlockFormatError, type BlockLocationReference, type BlockValue, CANVAS_BLOCK_PARAM_TYPE, CANVAS_CONTEXTUAL_EDITING_PARAM, CANVAS_DRAFT_STATE, CANVAS_EDITOR_STATE, CANVAS_ENRICHMENT_TAG_PARAM, CANVAS_INTENT_TAG_PARAM, CANVAS_LOCALE_TAG_PARAM, CANVAS_LOCALIZATION_SLOT, CANVAS_LOCALIZATION_TYPE, CANVAS_PERSONALIZATION_ALGORITHM_PARAM, CANVAS_PERSONALIZATION_ALGORITHM_TYPE, CANVAS_PERSONALIZATION_EVENT_NAME_PARAM, CANVAS_PERSONALIZATION_PARAM, CANVAS_PERSONALIZATION_TAKE_PARAM, CANVAS_PERSONALIZE_SLOT, CANVAS_PERSONALIZE_TYPE, CANVAS_PUBLISHED_STATE, CANVAS_SLOT_SECTION_SLOT, CANVAS_SLOT_SECTION_TYPE, CANVAS_TEST_SLOT, CANVAS_TEST_TYPE, CANVAS_TEST_VARIANT_PARAM, CANVAS_VIZ_CONTROL_PARAM, CANVAS_VIZ_DI_RULE, CANVAS_VIZ_DYNAMIC_TOKEN_RULE, CANVAS_VIZ_LOCALE_RULE, CANVAS_VIZ_QUIRKS_RULE, CanvasClient, CanvasClientError, type CanvasDefinitions, type CategoriesDeleteParameters, type CategoriesGetParameters, type CategoriesGetResponse, type CategoriesPutParameters, type Category, CategoryClient, type Channel, type ChannelMessage, ChildEnhancerBuilder, type ComponentDefinition, type ComponentDefinitionDeleteParameters, type ComponentDefinitionGetParameters, type ComponentDefinitionGetResponse, type ComponentDefinitionParameter, type ComponentDefinitionPermission, type ComponentDefinitionPutParameters, type ComponentDefinitionSlot, type ComponentDefinitionSlugSettings, type ComponentDefinitionVariant, type ComponentEnhancer, type ComponentEnhancerFunction, type ComponentEnhancerOptions, type ComponentInstance, type ComponentInstanceContextualEditing, type ComponentInstanceHistoryEntry, type ComponentInstanceHistoryGetParameters, type ComponentInstanceHistoryGetResponse, type ComponentLocationReference, type ComponentOverridability, type ComponentOverride, type ComponentOverrides, type ComponentParameter, type ComponentParameterBlock, type ComponentParameterConditionalValue, type ComponentParameterContextualEditing, type ComponentParameterEnhancer, type ComponentParameterEnhancerFunction, type ComponentParameterEnhancerOptions, type CompositionDeleteParameters, type CompositionFilters, type CompositionGetByComponentIdParameters, type CompositionGetByIdParameters, type CompositionGetByNodeIdParameters, type CompositionGetByNodePathParameters, type CompositionGetBySlugParameters, type CompositionGetListResponse, type CompositionGetParameters, type CompositionGetResponse, type CompositionGetValidResponses, type CompositionPutParameters, type CompositionResolvedGetResponse, type CompositionResolvedListResponse, type CompositionUIStatus, ContentClient, type ContentType, type ContentTypeField, type ContentTypePreviewConfiguration, type ContextStorageUpdatedMessage, type ContextualEditingComponentReference, type ContextualEditingValue, type CopiedComponentSubtree, type DataDiagnostic, type DataElementBindingIssue, type DataElementConnectionDefinition, type DataElementConnectionFailureAction, type DataElementConnectionFailureLogLevel, type DataResolutionConfigIssue, type DataResolutionIssue, type DataResolutionOption, type DataResolutionOptionNegative, type DataResolutionOptionPositive, type DataResolutionParameters, type DataResourceDefinition, type DataResourceDefinitions, type DataResourceIssue, type DataResourceVariables, type DataSource, DataSourceClient, type DataSourceDeleteParameters, type DataSourceGetParameters, type DataSourceGetResponse, type DataSourcePutParameters, type DataSourceVariantData, type DataSourceVariantsKeys, type DataSourcesGetParameters, type DataSourcesGetResponse, type DataType, DataTypeClient, type DataTypeDeleteParameters, type DataTypeGetParameters, type DataTypeGetResponse, type DataTypePutParameters, type DataVariableDefinition, type DataWithProperties, type DeleteContentTypeOptions, type DeleteEntryOptions, type DismissPlaceholderMessage, type DynamicInputIssue, EDGE_CACHE_DISABLED, EDGE_DEFAULT_CACHE_TTL, EDGE_MAX_CACHE_TTL, EDGE_MIN_CACHE_TTL, EMPTY_COMPOSITION, type EdgehancersDiagnostics, type EdgehancersWholeResponseCacheDiagnostics, type EditorStateUpdatedMessage, EnhancerBuilder, type EnhancerContext, type EnhancerError, EntityReleasesClient, type EntityReleasesGetParameters, type EntityReleasesGetResponse, type EntriesGetParameters, type EntriesGetResponse, type EntriesHistoryGetParameters, type EntriesHistoryGetResponse, type EntriesResolvedListResponse, type Entry, type EntryData, type EntryFilters, type EntryList, type EvaluateCriteriaGroupOptions, type EvaluateNodeTreeVisibilityOptions, type EvaluateNodeVisibilityParameterOptions, type EvaluatePropertyCriteriaOptions, type EvaluateWalkTreePropertyCriteriaOptions, type Filters, type FindInNodeTreeReference, type FlattenProperty, type FlattenValues, type FlattenValuesOptions, type GetContentTypesOptions, type GetContentTypesResponse, type GetEffectivePropertyValueOptions, type GetEntriesOptions, type GetEntriesResponse, type GetParameterAttributesProps, IN_CONTEXT_EDITOR_COMPONENT_END_ROLE, IN_CONTEXT_EDITOR_COMPONENT_START_ROLE, IN_CONTEXT_EDITOR_CONFIG_CHECK_QUERY_STRING_PARAM, IN_CONTEXT_EDITOR_EMBED_SCRIPT_ID, IN_CONTEXT_EDITOR_FORCED_SETTINGS_QUERY_STRING_PARAM, IN_CONTEXT_EDITOR_PLAYGROUND_QUERY_STRING_PARAM, IN_CONTEXT_EDITOR_QUERY_STRING_PARAM, IS_RENDERED_BY_UNIFORM_ATTRIBUTE, type InvalidationPayload, LOCALE_DYNAMIC_INPUT_NAME, type LimitPolicy, type LinkParamConfiguration, type LinkParamValue, type LinkParameterType, type LinkTypeConfiguration, type Locale, LocaleClient, type LocaleDeleteParameters, type LocalePutParameters, type LocalesGetParameters, type LocalesGetResponse, type LocalizeOptions, type MaxDepthExceededIssue, type MessageHandler, type MoveComponentMessage, type MultiSelectParamConfiguration, type MultiSelectParamValue, type NodeLocationReference, type NonProjectMapLinkParamValue, type NumberParamConfig, type NumberParamValue, type OpenParameterEditorMessage, type OverrideOptions, PLACEHOLDER_ID, type PatternIssue, PreviewClient, type PreviewPanelSettings, type PreviewUrl, type PreviewUrlDeleteParameters, type PreviewUrlDeleteResponse, type PreviewUrlPutParameters, type PreviewUrlPutResponse, type PreviewUrlsGetParameters, type PreviewUrlsGetResponse, type PreviewViewport, type PreviewViewportDeleteParameters, type PreviewViewportDeleteResponse, type PreviewViewportPutParameters, type PreviewViewportPutResponse, type PreviewViewportsGetParameters, type PreviewViewportsGetResponse, type Project, ProjectClient, type ProjectDeleteParameters, type ProjectGetParameters, type ProjectGetResponse, type ProjectMapLinkParamValue, type ProjectPutParameters, type ProjectPutResponse, type Prompt, PromptClient, type PromptsDeleteParameters, type PromptsGetParameters, type PromptsGetResponse, type PromptsPutParameters, type PropertyCriteriaMatch, type PropertyValue, type PutContentTypeBody, type PutEntryBody, type ReadyMessage, RelationshipClient, type RelationshipResultInstance, type Release, ReleaseClient, type ReleaseContent, ReleaseContentsClient, type ReleaseContentsDeleteBody, type ReleaseContentsGetParameters, type ReleaseContentsGetResponse, type ReleaseDeleteParameters, type ReleasePatchParameters, type ReleasePutParameters, type ReleaseState, type ReleasesGetParameters, type ReleasesGetResponse, type ReportRenderedCompositionsMessage, type RequestComponentSuggestionMessage, type RequestPageHtmlMessage, type ResolvedRouteGetResponse, type RichTextBuiltInElement, type RichTextBuiltInFormat, type RichTextParamConfiguration, type RichTextParamValue, type RootComponentInstance, type RootEntryReference, type RootLocationReference, RouteClient, type RouteDynamicInputs, type RouteGetParameters, type RouteGetResponse, type RouteGetResponseComposition, type RouteGetResponseEdgehancedComposition, type RouteGetResponseEdgehancedNotFound, type RouteGetResponseNotFound, type RouteGetResponseRedirect, SECRET_QUERY_STRING_PARAM, type SelectComponentMessage, type SelectParamConfiguration, type SelectParamOption, type SelectParamValue, type SelectParameterMessage, type SendPageHtmlMessage, type SpecificProjectMap, type StringOperators, type SuggestComponentMessage, type TreeNodeInfoTypes, type TriggerComponentActionMessage, type TriggerCompositionActionMessage, UncachedCanvasClient, UncachedCategoryClient, UncachedContentClient, UniqueBatchEntries, type UpdateComponentParameterMessage, type UpdateComponentReferencesMessage, type UpdateCompositionInternalMessage, type UpdateCompositionMessage, type UpdateContextualEditingStateInternalMessage, type UpdateFeatureFlagsMessage, type UpdatePreviewSettingsMessage, type VisibilityCriteria, type VisibilityCriteriaEvaluationResult, type VisibilityCriteriaGroup, type VisibilityParameterValue, type VisibilityRule, type VisibilityRules, type WalkNodeTreeActions, type WalkNodeTreeOptions, type WebhookDefinition, WorkflowClient, type WorkflowDefinition, type WorkflowStage, type WorkflowStagePermission, type WorkflowStageTransition, type WorkflowStageTransitionPermission, type WorkflowsDeleteParameters, type WorkflowsGetParameters, type WorkflowsGetResponse, type WorkflowsPutParameters, bindExpressionEscapeChars, bindExpressionPrefix, bindVariables, bindVariablesToObject, compose, convertEntryToPutEntry, convertToBindExpression, createBatchEnhancer, createCanvasChannel, createDynamicInputVisibilityRule, createDynamicTokenVisibilityRule, createLimitPolicy, createLocaleVisibilityRule, createQuirksVisibilityRule, createUniformApiEnhancer, createVariableReference, enhance, escapeBindExpressionDefaultValue, evaluateNodeVisibilityParameter, evaluatePropertyCriteria, evaluateVisibilityCriteriaGroup, evaluateWalkTreeNodeVisibility, evaluateWalkTreePropertyCriteria, extractLocales, findParameterInNodeTree, flattenValues, generateComponentPlaceholderId, generateHash, getBlockValue, getComponentJsonPointer, getComponentPath, getDataSourceVariantFromRouteGetParams, getEffectivePropertyValue, getLocalizedPropertyValues, getNounForLocation, getNounForNode, getParameterAttributes, getPropertiesValue, hasReferencedVariables, isAddComponentMessage, isAllowedReferrer, isAssetParamValue, isAssetParamValueItem, isComponentActionMessage, isComponentPlaceholderId, isContextStorageUpdatedMessage, isDismissPlaceholderMessage, isEntryData, isLinkParamValue, isMovingComponentMessage, isNestedNodeType, isOpenParameterEditorMessage, isReadyMessage, isReportRenderedCompositionsMessage, isRequestComponentSuggestionMessage, isRootEntryReference, isSelectComponentMessage, isSelectParameterMessage, isSuggestComponentMessage, isSystemComponentDefinition, isTriggerCompositionActionMessage, isUpdateComponentParameterMessage, isUpdateComponentReferencesMessage, isUpdateCompositionInternalMessage, isUpdateCompositionMessage, isUpdateContextualEditingStateInternalMessage, isUpdateFeatureFlagsMessage, isUpdatePreviewSettingsMessage, localize, mapSlotToPersonalizedVariations, mapSlotToTestVariations, nullLimitPolicy, parseComponentPlaceholderId, parseVariableExpression, version, walkNodeTree, walkPropertyValues };
|
13350
|
+
export { ASSETS_SOURCE_CUSTOM_URL, ASSETS_SOURCE_UNIFORM, ASSET_PARAMETER_TYPE, ATTRIBUTE_COMPONENT_ID, ATTRIBUTE_MULTILINE, ATTRIBUTE_PARAMETER_ID, ATTRIBUTE_PARAMETER_TYPE, ATTRIBUTE_PARAMETER_VALUE, ATTRIBUTE_PLACEHOLDER, type AddComponentMessage, type BatchEnhancer, BatchEntry, type BatchInvalidationPayload, type BindVariablesOptions, type BindVariablesResult, type BindVariablesToObjectOptions, BlockFormatError, type BlockLocationReference, type BlockValue, CANVAS_BLOCK_PARAM_TYPE, CANVAS_CONTEXTUAL_EDITING_PARAM, CANVAS_DRAFT_STATE, CANVAS_EDITOR_STATE, CANVAS_ENRICHMENT_TAG_PARAM, CANVAS_INTENT_TAG_PARAM, CANVAS_LOCALE_TAG_PARAM, CANVAS_LOCALIZATION_SLOT, CANVAS_LOCALIZATION_TYPE, CANVAS_PERSONALIZATION_ALGORITHM_PARAM, CANVAS_PERSONALIZATION_ALGORITHM_TYPE, CANVAS_PERSONALIZATION_EVENT_NAME_PARAM, CANVAS_PERSONALIZATION_PARAM, CANVAS_PERSONALIZATION_TAKE_PARAM, CANVAS_PERSONALIZE_SLOT, CANVAS_PERSONALIZE_TYPE, CANVAS_PUBLISHED_STATE, CANVAS_SLOT_SECTION_SLOT, CANVAS_SLOT_SECTION_TYPE, CANVAS_TEST_SLOT, CANVAS_TEST_TYPE, CANVAS_TEST_VARIANT_PARAM, CANVAS_VIZ_CONTROL_PARAM, CANVAS_VIZ_DI_RULE, CANVAS_VIZ_DYNAMIC_TOKEN_RULE, CANVAS_VIZ_LOCALE_RULE, CANVAS_VIZ_QUIRKS_RULE, CanvasClient, CanvasClientError, type CanvasDefinitions, type CategoriesDeleteParameters, type CategoriesGetParameters, type CategoriesGetResponse, type CategoriesPutParameters, type Category, CategoryClient, type Channel, type ChannelMessage, ChildEnhancerBuilder, type ComponentDefinition, type ComponentDefinitionDeleteParameters, type ComponentDefinitionGetParameters, type ComponentDefinitionGetResponse, type ComponentDefinitionParameter, type ComponentDefinitionPermission, type ComponentDefinitionPutParameters, type ComponentDefinitionSlot, type ComponentDefinitionSlugSettings, type ComponentDefinitionVariant, type ComponentEnhancer, type ComponentEnhancerFunction, type ComponentEnhancerOptions, type ComponentInstance, type ComponentInstanceContextualEditing, type ComponentInstanceHistoryEntry, type ComponentInstanceHistoryGetParameters, type ComponentInstanceHistoryGetResponse, type ComponentLocationReference, type ComponentOverridability, type ComponentOverride, type ComponentOverrides, type ComponentParameter, type ComponentParameterBlock, type ComponentParameterConditionalValue, type ComponentParameterContextualEditing, type ComponentParameterEnhancer, type ComponentParameterEnhancerFunction, type ComponentParameterEnhancerOptions, type CompositionDeleteParameters, type CompositionFilters, type CompositionGetByComponentIdParameters, type CompositionGetByIdParameters, type CompositionGetByNodeIdParameters, type CompositionGetByNodePathParameters, type CompositionGetBySlugParameters, type CompositionGetListResponse, type CompositionGetParameters, type CompositionGetResponse, type CompositionGetValidResponses, type CompositionPutParameters, type CompositionResolvedGetResponse, type CompositionResolvedListResponse, type CompositionUIStatus, ContentClient, type ContentType, type ContentTypeField, type ContentTypePreviewConfiguration, type ContextStorageUpdatedMessage, type ContextualEditingComponentReference, type ContextualEditingValue, type CopiedComponentSubtree, type DataDiagnostic, type DataElementBindingIssue, type DataElementConnectionDefinition, type DataElementConnectionFailureAction, type DataElementConnectionFailureLogLevel, type DataResolutionConfigIssue, type DataResolutionIssue, type DataResolutionOption, type DataResolutionOptionNegative, type DataResolutionOptionPositive, type DataResolutionParameters, type DataResourceDefinition, type DataResourceDefinitions, type DataResourceIssue, type DataResourceVariables, type DataSource, DataSourceClient, type DataSourceDeleteParameters, type DataSourceGetParameters, type DataSourceGetResponse, type DataSourcePutParameters, type DataSourceVariantData, type DataSourceVariantsKeys, type DataSourcesGetParameters, type DataSourcesGetResponse, type DataType, DataTypeClient, type DataTypeDeleteParameters, type DataTypeGetParameters, type DataTypeGetResponse, type DataTypePutParameters, type DataVariableDefinition, type DataWithProperties, type DeleteContentTypeOptions, type DeleteEntryOptions, type DismissPlaceholderMessage, type DynamicInputIssue, EDGE_CACHE_DISABLED, EDGE_DEFAULT_CACHE_TTL, EDGE_MAX_CACHE_TTL, EDGE_MIN_CACHE_TTL, EMPTY_COMPOSITION, type EdgehancersDiagnostics, type EdgehancersWholeResponseCacheDiagnostics, type EditorStateUpdatedMessage, EnhancerBuilder, type EnhancerContext, type EnhancerError, EntityReleasesClient, type EntityReleasesGetParameters, type EntityReleasesGetResponse, type EntriesGetParameters, type EntriesGetResponse, type EntriesHistoryGetParameters, type EntriesHistoryGetResponse, type EntriesResolvedListResponse, type Entry, type EntryData, type EntryFilters, type EntryList, type EvaluateCriteriaGroupOptions, type EvaluateNodeTreeVisibilityOptions, type EvaluateNodeVisibilityParameterOptions, type EvaluatePropertyCriteriaOptions, type EvaluateWalkTreePropertyCriteriaOptions, type Filters, type FindInNodeTreeReference, type FlattenProperty, type FlattenValues, type FlattenValuesOptions, type GetContentTypesOptions, type GetContentTypesResponse, type GetEffectivePropertyValueOptions, type GetEntriesOptions, type GetEntriesResponse, type GetParameterAttributesProps, IN_CONTEXT_EDITOR_COMPONENT_END_ROLE, IN_CONTEXT_EDITOR_COMPONENT_START_ROLE, IN_CONTEXT_EDITOR_CONFIG_CHECK_QUERY_STRING_PARAM, IN_CONTEXT_EDITOR_EMBED_SCRIPT_ID, IN_CONTEXT_EDITOR_FORCED_SETTINGS_QUERY_STRING_PARAM, IN_CONTEXT_EDITOR_PLAYGROUND_QUERY_STRING_PARAM, IN_CONTEXT_EDITOR_QUERY_STRING_PARAM, IS_RENDERED_BY_UNIFORM_ATTRIBUTE, type InvalidationPayload, LOCALE_DYNAMIC_INPUT_NAME, type LimitPolicy, type LinkParamConfiguration, type LinkParamValue, type LinkParameterType, type LinkTypeConfiguration, type Locale, LocaleClient, type LocaleDeleteParameters, type LocalePutParameters, type LocalesGetParameters, type LocalesGetResponse, type LocalizeOptions, type MaxDepthExceededIssue, type MessageHandler, type MoveComponentMessage, type MultiSelectParamConfiguration, type MultiSelectParamValue, type NodeLocationReference, type NonProjectMapLinkParamValue, type NumberParamConfig, type NumberParamValue, type OpenParameterEditorMessage, type OverrideOptions, PLACEHOLDER_ID, type PatternIssue, PreviewClient, type PreviewPanelSettings, type PreviewUrl, type PreviewUrlDeleteParameters, type PreviewUrlDeleteResponse, type PreviewUrlPutParameters, type PreviewUrlPutResponse, type PreviewUrlsGetParameters, type PreviewUrlsGetResponse, type PreviewViewport, type PreviewViewportDeleteParameters, type PreviewViewportDeleteResponse, type PreviewViewportPutParameters, type PreviewViewportPutResponse, type PreviewViewportsGetParameters, type PreviewViewportsGetResponse, type Project, ProjectClient, type ProjectDeleteParameters, type ProjectGetParameters, type ProjectGetResponse, type ProjectMapLinkParamValue, type ProjectPutParameters, type ProjectPutResponse, type Prompt, PromptClient, type PromptsDeleteParameters, type PromptsGetParameters, type PromptsGetResponse, type PromptsPutParameters, type PropertyCriteriaMatch, type PropertyValue, type PutContentTypeBody, type PutEntryBody, type ReadyMessage, RelationshipClient, type RelationshipResultInstance, type Release, ReleaseClient, type ReleaseContent, ReleaseContentsClient, type ReleaseContentsDeleteBody, type ReleaseContentsGetParameters, type ReleaseContentsGetResponse, type ReleaseDeleteParameters, type ReleasePatchParameters, type ReleasePutParameters, type ReleaseState, type ReleasesGetParameters, type ReleasesGetResponse, type ReportRenderedCompositionsMessage, type RequestComponentSuggestionMessage, type RequestPageHtmlMessage, type ResolvedRouteGetResponse, type RichTextBuiltInElement, type RichTextBuiltInFormat, type RichTextParamConfiguration, type RichTextParamValue, type RootComponentInstance, type RootEntryReference, type RootLocationReference, RouteClient, type RouteDynamicInputs, type RouteGetParameters, type RouteGetResponse, type RouteGetResponseComposition, type RouteGetResponseEdgehancedComposition, type RouteGetResponseEdgehancedNotFound, type RouteGetResponseNotFound, type RouteGetResponseRedirect, SECRET_QUERY_STRING_PARAM, type SelectComponentMessage, type SelectParamConfiguration, type SelectParamOption, type SelectParamValue, type SelectParameterMessage, type SendPageHtmlMessage, type SpecificProjectMap, type StringOperators, type SuggestComponentMessage, type TreeNodeInfoTypes, type TriggerComponentActionMessage, type TriggerCompositionActionMessage, UncachedCanvasClient, UncachedCategoryClient, UncachedContentClient, UniqueBatchEntries, type UpdateComponentParameterMessage, type UpdateComponentReferencesMessage, type UpdateCompositionInternalMessage, type UpdateCompositionMessage, type UpdateCompositionOptions, type UpdateContextualEditingStateInternalMessage, type UpdateFeatureFlagsMessage, type UpdatePreviewSettingsMessage, type UpsertEntryOptions, type VisibilityCriteria, type VisibilityCriteriaEvaluationResult, type VisibilityCriteriaGroup, type VisibilityParameterValue, type VisibilityRule, type VisibilityRules, type WalkNodeTreeActions, type WalkNodeTreeOptions, WorkflowClient, type WorkflowDefinition, type WorkflowStage, type WorkflowStagePermission, type WorkflowStageTransition, type WorkflowStageTransitionPermission, type WorkflowsDeleteParameters, type WorkflowsGetParameters, type WorkflowsGetResponse, type WorkflowsPutParameters, bindExpressionEscapeChars, bindExpressionPrefix, bindVariables, bindVariablesToObject, compose, convertEntryToPutEntry, convertToBindExpression, createBatchEnhancer, createCanvasChannel, createDynamicInputVisibilityRule, createDynamicTokenVisibilityRule, createLimitPolicy, createLocaleVisibilityRule, createQuirksVisibilityRule, createUniformApiEnhancer, createVariableReference, enhance, escapeBindExpressionDefaultValue, evaluateNodeVisibilityParameter, evaluatePropertyCriteria, evaluateVisibilityCriteriaGroup, evaluateWalkTreeNodeVisibility, evaluateWalkTreePropertyCriteria, extractLocales, findParameterInNodeTree, flattenValues, generateComponentPlaceholderId, generateHash, getBlockValue, getComponentJsonPointer, getComponentPath, getDataSourceVariantFromRouteGetParams, getEffectivePropertyValue, getLocalizedPropertyValues, getNounForLocation, getNounForNode, getParameterAttributes, getPropertiesValue, hasReferencedVariables, isAddComponentMessage, isAllowedReferrer, isAssetParamValue, isAssetParamValueItem, isComponentActionMessage, isComponentPlaceholderId, isContextStorageUpdatedMessage, isDismissPlaceholderMessage, isEntryData, isLinkParamValue, isMovingComponentMessage, isNestedNodeType, isOpenParameterEditorMessage, isReadyMessage, isReportRenderedCompositionsMessage, isRequestComponentSuggestionMessage, isRootEntryReference, isSelectComponentMessage, isSelectParameterMessage, isSuggestComponentMessage, isSystemComponentDefinition, isTriggerCompositionActionMessage, isUpdateComponentParameterMessage, isUpdateComponentReferencesMessage, isUpdateCompositionInternalMessage, isUpdateCompositionMessage, isUpdateContextualEditingStateInternalMessage, isUpdateFeatureFlagsMessage, isUpdatePreviewSettingsMessage, localize, mapSlotToPersonalizedVariations, mapSlotToTestVariations, nullLimitPolicy, parseComponentPlaceholderId, parseVariableExpression, version, walkNodeTree, walkPropertyValues };
|
package/dist/index.esm.js
CHANGED
@@ -671,12 +671,17 @@ var CanvasClient = class extends ApiClient {
|
|
671
671
|
return this.apiClient(edgeUrl, this.edgeApiRequestInit);
|
672
672
|
}
|
673
673
|
/** Updates or creates a Canvas component definition */
|
674
|
-
async updateComposition(body) {
|
674
|
+
async updateComposition(body, options) {
|
675
675
|
const fetchUri = this.createUrl(CANVAS_URL);
|
676
|
+
const headers = {};
|
677
|
+
if (options == null ? void 0 : options.ifUnmodifiedSince) {
|
678
|
+
headers["x-if-unmodified-since"] = options.ifUnmodifiedSince;
|
679
|
+
}
|
676
680
|
const { response } = await this.apiClientWithResponse(fetchUri, {
|
677
681
|
method: "PUT",
|
678
682
|
body: JSON.stringify({ ...body, projectId: this.options.projectId }),
|
679
|
-
expectNoContent: true
|
683
|
+
expectNoContent: true,
|
684
|
+
headers
|
680
685
|
});
|
681
686
|
return { modified: response.headers.get("x-modified-at") };
|
682
687
|
}
|
@@ -816,12 +821,17 @@ var _ContentClient = class _ContentClient extends ApiClient3 {
|
|
816
821
|
headers: opts.autogenerateDataTypes ? { "x-uniform-autogenerate-data-types": "true" } : {}
|
817
822
|
});
|
818
823
|
}
|
819
|
-
async upsertEntry(body) {
|
824
|
+
async upsertEntry(body, options) {
|
820
825
|
const fetchUri = this.createUrl(__privateGet(_ContentClient, _entriesUrl));
|
826
|
+
const headers = {};
|
827
|
+
if (options == null ? void 0 : options.ifUnmodifiedSince) {
|
828
|
+
headers["x-if-unmodified-since"] = options.ifUnmodifiedSince;
|
829
|
+
}
|
821
830
|
const { response } = await this.apiClientWithResponse(fetchUri, {
|
822
831
|
method: "PUT",
|
823
832
|
body: JSON.stringify({ ...body, projectId: this.options.projectId }),
|
824
|
-
expectNoContent: true
|
833
|
+
expectNoContent: true,
|
834
|
+
headers
|
825
835
|
});
|
826
836
|
return { modified: response.headers.get("x-modified-at") };
|
827
837
|
}
|
@@ -3407,7 +3417,7 @@ function handleRichTextNodeBinding(object, options) {
|
|
3407
3417
|
import { ApiClientError as ApiClientError2 } from "@uniformdev/context/api";
|
3408
3418
|
|
3409
3419
|
// src/.version.ts
|
3410
|
-
var version = "20.
|
3420
|
+
var version = "20.30.1";
|
3411
3421
|
|
3412
3422
|
// src/WorkflowClient.ts
|
3413
3423
|
import { ApiClient as ApiClient15 } from "@uniformdev/context/api";
|
package/dist/index.js
CHANGED
@@ -837,12 +837,17 @@ var CanvasClient = class extends import_api2.ApiClient {
|
|
837
837
|
return this.apiClient(edgeUrl, this.edgeApiRequestInit);
|
838
838
|
}
|
839
839
|
/** Updates or creates a Canvas component definition */
|
840
|
-
async updateComposition(body) {
|
840
|
+
async updateComposition(body, options) {
|
841
841
|
const fetchUri = this.createUrl(CANVAS_URL);
|
842
|
+
const headers = {};
|
843
|
+
if (options == null ? void 0 : options.ifUnmodifiedSince) {
|
844
|
+
headers["x-if-unmodified-since"] = options.ifUnmodifiedSince;
|
845
|
+
}
|
842
846
|
const { response } = await this.apiClientWithResponse(fetchUri, {
|
843
847
|
method: "PUT",
|
844
848
|
body: JSON.stringify({ ...body, projectId: this.options.projectId }),
|
845
|
-
expectNoContent: true
|
849
|
+
expectNoContent: true,
|
850
|
+
headers
|
846
851
|
});
|
847
852
|
return { modified: response.headers.get("x-modified-at") };
|
848
853
|
}
|
@@ -982,12 +987,17 @@ var _ContentClient = class _ContentClient extends import_api4.ApiClient {
|
|
982
987
|
headers: opts.autogenerateDataTypes ? { "x-uniform-autogenerate-data-types": "true" } : {}
|
983
988
|
});
|
984
989
|
}
|
985
|
-
async upsertEntry(body) {
|
990
|
+
async upsertEntry(body, options) {
|
986
991
|
const fetchUri = this.createUrl(__privateGet(_ContentClient, _entriesUrl));
|
992
|
+
const headers = {};
|
993
|
+
if (options == null ? void 0 : options.ifUnmodifiedSince) {
|
994
|
+
headers["x-if-unmodified-since"] = options.ifUnmodifiedSince;
|
995
|
+
}
|
987
996
|
const { response } = await this.apiClientWithResponse(fetchUri, {
|
988
997
|
method: "PUT",
|
989
998
|
body: JSON.stringify({ ...body, projectId: this.options.projectId }),
|
990
|
-
expectNoContent: true
|
999
|
+
expectNoContent: true,
|
1000
|
+
headers
|
991
1001
|
});
|
992
1002
|
return { modified: response.headers.get("x-modified-at") };
|
993
1003
|
}
|
@@ -3573,7 +3583,7 @@ function handleRichTextNodeBinding(object, options) {
|
|
3573
3583
|
var import_api17 = require("@uniformdev/context/api");
|
3574
3584
|
|
3575
3585
|
// src/.version.ts
|
3576
|
-
var version = "20.
|
3586
|
+
var version = "20.30.1";
|
3577
3587
|
|
3578
3588
|
// src/WorkflowClient.ts
|
3579
3589
|
var import_api16 = require("@uniformdev/context/api");
|
package/dist/index.mjs
CHANGED
@@ -671,12 +671,17 @@ var CanvasClient = class extends ApiClient {
|
|
671
671
|
return this.apiClient(edgeUrl, this.edgeApiRequestInit);
|
672
672
|
}
|
673
673
|
/** Updates or creates a Canvas component definition */
|
674
|
-
async updateComposition(body) {
|
674
|
+
async updateComposition(body, options) {
|
675
675
|
const fetchUri = this.createUrl(CANVAS_URL);
|
676
|
+
const headers = {};
|
677
|
+
if (options == null ? void 0 : options.ifUnmodifiedSince) {
|
678
|
+
headers["x-if-unmodified-since"] = options.ifUnmodifiedSince;
|
679
|
+
}
|
676
680
|
const { response } = await this.apiClientWithResponse(fetchUri, {
|
677
681
|
method: "PUT",
|
678
682
|
body: JSON.stringify({ ...body, projectId: this.options.projectId }),
|
679
|
-
expectNoContent: true
|
683
|
+
expectNoContent: true,
|
684
|
+
headers
|
680
685
|
});
|
681
686
|
return { modified: response.headers.get("x-modified-at") };
|
682
687
|
}
|
@@ -816,12 +821,17 @@ var _ContentClient = class _ContentClient extends ApiClient3 {
|
|
816
821
|
headers: opts.autogenerateDataTypes ? { "x-uniform-autogenerate-data-types": "true" } : {}
|
817
822
|
});
|
818
823
|
}
|
819
|
-
async upsertEntry(body) {
|
824
|
+
async upsertEntry(body, options) {
|
820
825
|
const fetchUri = this.createUrl(__privateGet(_ContentClient, _entriesUrl));
|
826
|
+
const headers = {};
|
827
|
+
if (options == null ? void 0 : options.ifUnmodifiedSince) {
|
828
|
+
headers["x-if-unmodified-since"] = options.ifUnmodifiedSince;
|
829
|
+
}
|
821
830
|
const { response } = await this.apiClientWithResponse(fetchUri, {
|
822
831
|
method: "PUT",
|
823
832
|
body: JSON.stringify({ ...body, projectId: this.options.projectId }),
|
824
|
-
expectNoContent: true
|
833
|
+
expectNoContent: true,
|
834
|
+
headers
|
825
835
|
});
|
826
836
|
return { modified: response.headers.get("x-modified-at") };
|
827
837
|
}
|
@@ -3407,7 +3417,7 @@ function handleRichTextNodeBinding(object, options) {
|
|
3407
3417
|
import { ApiClientError as ApiClientError2 } from "@uniformdev/context/api";
|
3408
3418
|
|
3409
3419
|
// src/.version.ts
|
3410
|
-
var version = "20.
|
3420
|
+
var version = "20.30.1";
|
3411
3421
|
|
3412
3422
|
// src/WorkflowClient.ts
|
3413
3423
|
import { ApiClient as ApiClient15 } from "@uniformdev/context/api";
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@uniformdev/canvas",
|
3
|
-
"version": "20.
|
3
|
+
"version": "20.30.1",
|
4
4
|
"description": "Common functionality and types for Uniform Canvas",
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
6
6
|
"main": "./dist/index.js",
|
@@ -37,13 +37,12 @@
|
|
37
37
|
"lexical": "0.25.0",
|
38
38
|
"p-limit": "3.1.0",
|
39
39
|
"p-retry": "5.1.2",
|
40
|
-
"p-throttle": "5.0.0"
|
41
|
-
"svix": "1.71.0"
|
40
|
+
"p-throttle": "5.0.0"
|
42
41
|
},
|
43
42
|
"dependencies": {
|
44
|
-
"@uniformdev/assets": "20.
|
45
|
-
"@uniformdev/context": "20.
|
46
|
-
"@uniformdev/richtext": "20.
|
43
|
+
"@uniformdev/assets": "20.30.1",
|
44
|
+
"@uniformdev/context": "20.30.1",
|
45
|
+
"@uniformdev/richtext": "20.30.1",
|
47
46
|
"immer": "10.1.1"
|
48
47
|
},
|
49
48
|
"files": [
|
@@ -52,5 +51,5 @@
|
|
52
51
|
"publishConfig": {
|
53
52
|
"access": "public"
|
54
53
|
},
|
55
|
-
"gitHead": "
|
54
|
+
"gitHead": "8f255b1cff89486c0aca67be6c6409c68766276c"
|
56
55
|
}
|