@uniformdev/canvas 20.35.0 → 20.35.1-alpha.210
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 +1232 -779
- package/dist/index.d.ts +1232 -779
- package/dist/index.esm.js +167 -21
- package/dist/index.js +182 -24
- package/dist/index.mjs +167 -21
- package/package.json +8 -8
package/dist/index.js
CHANGED
|
@@ -397,15 +397,18 @@ __export(src_exports, {
|
|
|
397
397
|
ATTRIBUTE_PARAMETER_TYPE: () => ATTRIBUTE_PARAMETER_TYPE,
|
|
398
398
|
ATTRIBUTE_PARAMETER_VALUE: () => ATTRIBUTE_PARAMETER_VALUE,
|
|
399
399
|
ATTRIBUTE_PLACEHOLDER: () => ATTRIBUTE_PLACEHOLDER,
|
|
400
|
-
ApiClientError: () =>
|
|
400
|
+
ApiClientError: () => import_api18.ApiClientError,
|
|
401
401
|
BatchEntry: () => BatchEntry,
|
|
402
402
|
BlockFormatError: () => BlockFormatError,
|
|
403
403
|
CANVAS_BLOCK_PARAM_TYPE: () => CANVAS_BLOCK_PARAM_TYPE,
|
|
404
|
+
CANVAS_COMPONENT_DISPLAY_NAME_PARAM: () => CANVAS_COMPONENT_DISPLAY_NAME_PARAM,
|
|
404
405
|
CANVAS_CONTEXTUAL_EDITING_PARAM: () => CANVAS_CONTEXTUAL_EDITING_PARAM,
|
|
405
406
|
CANVAS_DRAFT_STATE: () => CANVAS_DRAFT_STATE,
|
|
406
407
|
CANVAS_EDITOR_STATE: () => CANVAS_EDITOR_STATE,
|
|
407
408
|
CANVAS_ENRICHMENT_TAG_PARAM: () => CANVAS_ENRICHMENT_TAG_PARAM,
|
|
409
|
+
CANVAS_HYPOTHESIS_PARAM: () => CANVAS_HYPOTHESIS_PARAM,
|
|
408
410
|
CANVAS_INTENT_TAG_PARAM: () => CANVAS_INTENT_TAG_PARAM,
|
|
411
|
+
CANVAS_INTERNAL_PARAM_PREFIX: () => CANVAS_INTERNAL_PARAM_PREFIX,
|
|
409
412
|
CANVAS_LOCALE_TAG_PARAM: () => CANVAS_LOCALE_TAG_PARAM,
|
|
410
413
|
CANVAS_LOCALIZATION_SLOT: () => CANVAS_LOCALIZATION_SLOT,
|
|
411
414
|
CANVAS_LOCALIZATION_TYPE: () => CANVAS_LOCALIZATION_TYPE,
|
|
@@ -417,7 +420,12 @@ __export(src_exports, {
|
|
|
417
420
|
CANVAS_PERSONALIZE_SLOT: () => CANVAS_PERSONALIZE_SLOT,
|
|
418
421
|
CANVAS_PERSONALIZE_TYPE: () => CANVAS_PERSONALIZE_TYPE,
|
|
419
422
|
CANVAS_PUBLISHED_STATE: () => CANVAS_PUBLISHED_STATE,
|
|
423
|
+
CANVAS_SLOT_SECTION_GROUP_TYPE_PARAM: () => CANVAS_SLOT_SECTION_GROUP_TYPE_PARAM,
|
|
424
|
+
CANVAS_SLOT_SECTION_MAX_PARAM: () => CANVAS_SLOT_SECTION_MAX_PARAM,
|
|
425
|
+
CANVAS_SLOT_SECTION_MIN_PARAM: () => CANVAS_SLOT_SECTION_MIN_PARAM,
|
|
426
|
+
CANVAS_SLOT_SECTION_NAME_PARAM: () => CANVAS_SLOT_SECTION_NAME_PARAM,
|
|
420
427
|
CANVAS_SLOT_SECTION_SLOT: () => CANVAS_SLOT_SECTION_SLOT,
|
|
428
|
+
CANVAS_SLOT_SECTION_SPECIFIC_PARAM: () => CANVAS_SLOT_SECTION_SPECIFIC_PARAM,
|
|
421
429
|
CANVAS_SLOT_SECTION_TYPE: () => CANVAS_SLOT_SECTION_TYPE,
|
|
422
430
|
CANVAS_TEST_SLOT: () => CANVAS_TEST_SLOT,
|
|
423
431
|
CANVAS_TEST_TYPE: () => CANVAS_TEST_TYPE,
|
|
@@ -449,6 +457,7 @@ __export(src_exports, {
|
|
|
449
457
|
IN_CONTEXT_EDITOR_PLAYGROUND_QUERY_STRING_PARAM: () => IN_CONTEXT_EDITOR_PLAYGROUND_QUERY_STRING_PARAM,
|
|
450
458
|
IN_CONTEXT_EDITOR_QUERY_STRING_PARAM: () => IN_CONTEXT_EDITOR_QUERY_STRING_PARAM,
|
|
451
459
|
IS_RENDERED_BY_UNIFORM_ATTRIBUTE: () => IS_RENDERED_BY_UNIFORM_ATTRIBUTE,
|
|
460
|
+
IntegrationPropertyEditorsClient: () => IntegrationPropertyEditorsClient,
|
|
452
461
|
LOCALE_DYNAMIC_INPUT_NAME: () => LOCALE_DYNAMIC_INPUT_NAME,
|
|
453
462
|
LocaleClient: () => LocaleClient,
|
|
454
463
|
PLACEHOLDER_ID: () => PLACEHOLDER_ID,
|
|
@@ -465,6 +474,7 @@ __export(src_exports, {
|
|
|
465
474
|
UncachedContentClient: () => UncachedContentClient,
|
|
466
475
|
UniqueBatchEntries: () => UniqueBatchEntries,
|
|
467
476
|
WorkflowClient: () => WorkflowClient,
|
|
477
|
+
autoFixParameterGroups: () => autoFixParameterGroups,
|
|
468
478
|
bindExpressionEscapeChars: () => bindExpressionEscapeChars,
|
|
469
479
|
bindExpressionPrefix: () => bindExpressionPrefix,
|
|
470
480
|
bindVariables: () => bindVariables,
|
|
@@ -526,6 +536,7 @@ __export(src_exports, {
|
|
|
526
536
|
isSuggestComponentMessage: () => isSuggestComponentMessage,
|
|
527
537
|
isSystemComponentDefinition: () => isSystemComponentDefinition,
|
|
528
538
|
isTriggerCompositionActionMessage: () => isTriggerCompositionActionMessage,
|
|
539
|
+
isUpdateAiActionsMessage: () => isUpdateAiActionsMessage,
|
|
529
540
|
isUpdateComponentParameterMessage: () => isUpdateComponentParameterMessage,
|
|
530
541
|
isUpdateComponentReferencesMessage: () => isUpdateComponentReferencesMessage,
|
|
531
542
|
isUpdateCompositionInternalMessage: () => isUpdateCompositionInternalMessage,
|
|
@@ -536,6 +547,7 @@ __export(src_exports, {
|
|
|
536
547
|
localize: () => localize,
|
|
537
548
|
mapSlotToPersonalizedVariations: () => mapSlotToPersonalizedVariations,
|
|
538
549
|
mapSlotToTestVariations: () => mapSlotToTestVariations,
|
|
550
|
+
mergeAssetConfigWithDefaults: () => mergeAssetConfigWithDefaults,
|
|
539
551
|
nullLimitPolicy: () => nullLimitPolicy,
|
|
540
552
|
parseComponentPlaceholderId: () => parseComponentPlaceholderId,
|
|
541
553
|
parseVariableExpression: () => parseVariableExpression,
|
|
@@ -1247,6 +1259,11 @@ var CANVAS_PERSONALIZE_SLOT = "pz";
|
|
|
1247
1259
|
var CANVAS_TEST_SLOT = "test";
|
|
1248
1260
|
var CANVAS_LOCALIZATION_SLOT = "localized";
|
|
1249
1261
|
var CANVAS_SLOT_SECTION_SLOT = "$slotSectionItems";
|
|
1262
|
+
var CANVAS_SLOT_SECTION_NAME_PARAM = "name";
|
|
1263
|
+
var CANVAS_SLOT_SECTION_MIN_PARAM = "min";
|
|
1264
|
+
var CANVAS_SLOT_SECTION_MAX_PARAM = "max";
|
|
1265
|
+
var CANVAS_SLOT_SECTION_GROUP_TYPE_PARAM = "groupType";
|
|
1266
|
+
var CANVAS_SLOT_SECTION_SPECIFIC_PARAM = "specific";
|
|
1250
1267
|
var CANVAS_DRAFT_STATE = 0;
|
|
1251
1268
|
var CANVAS_PUBLISHED_STATE = 64;
|
|
1252
1269
|
var CANVAS_EDITOR_STATE = 63;
|
|
@@ -1257,6 +1274,9 @@ var CANVAS_PERSONALIZATION_ALGORITHM_TYPE = "pzAlgorithm";
|
|
|
1257
1274
|
var CANVAS_PERSONALIZATION_TAKE_PARAM = "count";
|
|
1258
1275
|
var CANVAS_TEST_VARIANT_PARAM = "$tstVrnt";
|
|
1259
1276
|
var CANVAS_ENRICHMENT_TAG_PARAM = "$enr";
|
|
1277
|
+
var CANVAS_INTERNAL_PARAM_PREFIX = "$internal_";
|
|
1278
|
+
var CANVAS_COMPONENT_DISPLAY_NAME_PARAM = `${CANVAS_INTERNAL_PARAM_PREFIX}displayName`;
|
|
1279
|
+
var CANVAS_HYPOTHESIS_PARAM = `${CANVAS_INTERNAL_PARAM_PREFIX}hypothesis`;
|
|
1260
1280
|
var CANVAS_CONTEXTUAL_EDITING_PARAM = "$contextualEditing";
|
|
1261
1281
|
var SECRET_QUERY_STRING_PARAM = "secret";
|
|
1262
1282
|
var IN_CONTEXT_EDITOR_QUERY_STRING_PARAM = "is_incontext_editing_mode";
|
|
@@ -2679,10 +2699,55 @@ var EntityReleasesClient = class extends import_api7.ApiClient {
|
|
|
2679
2699
|
}
|
|
2680
2700
|
};
|
|
2681
2701
|
|
|
2682
|
-
// src/
|
|
2702
|
+
// src/IntegrationPropertyEditorsClient.ts
|
|
2683
2703
|
var import_api8 = require("@uniformdev/context/api");
|
|
2704
|
+
var _baseUrl;
|
|
2705
|
+
var _IntegrationPropertyEditorsClient = class _IntegrationPropertyEditorsClient extends import_api8.ApiClient {
|
|
2706
|
+
constructor(options) {
|
|
2707
|
+
super(options);
|
|
2708
|
+
this.teamId = options.teamId;
|
|
2709
|
+
}
|
|
2710
|
+
/**
|
|
2711
|
+
* Gets a list of property type and hook names for the current team, including public integrations' hooks.
|
|
2712
|
+
*/
|
|
2713
|
+
get(options) {
|
|
2714
|
+
const fetchUri = this.createUrl(__privateGet(_IntegrationPropertyEditorsClient, _baseUrl), {
|
|
2715
|
+
...options,
|
|
2716
|
+
teamId: this.teamId
|
|
2717
|
+
});
|
|
2718
|
+
return this.apiClient(fetchUri);
|
|
2719
|
+
}
|
|
2720
|
+
/**
|
|
2721
|
+
* Creates or updates a custom AI property editor on a Mesh app.
|
|
2722
|
+
*/
|
|
2723
|
+
async deploy(body) {
|
|
2724
|
+
const fetchUri = this.createUrl(__privateGet(_IntegrationPropertyEditorsClient, _baseUrl));
|
|
2725
|
+
await this.apiClient(fetchUri, {
|
|
2726
|
+
method: "PUT",
|
|
2727
|
+
body: JSON.stringify({ ...body, teamId: this.teamId }),
|
|
2728
|
+
expectNoContent: true
|
|
2729
|
+
});
|
|
2730
|
+
}
|
|
2731
|
+
/**
|
|
2732
|
+
* Removes a custom AI property editor from a Mesh app.
|
|
2733
|
+
*/
|
|
2734
|
+
async delete(body) {
|
|
2735
|
+
const fetchUri = this.createUrl(__privateGet(_IntegrationPropertyEditorsClient, _baseUrl));
|
|
2736
|
+
await this.apiClient(fetchUri, {
|
|
2737
|
+
method: "DELETE",
|
|
2738
|
+
body: JSON.stringify({ ...body, teamId: this.teamId }),
|
|
2739
|
+
expectNoContent: true
|
|
2740
|
+
});
|
|
2741
|
+
}
|
|
2742
|
+
};
|
|
2743
|
+
_baseUrl = new WeakMap();
|
|
2744
|
+
__privateAdd(_IntegrationPropertyEditorsClient, _baseUrl, "/api/v1/integration-property-editors");
|
|
2745
|
+
var IntegrationPropertyEditorsClient = _IntegrationPropertyEditorsClient;
|
|
2746
|
+
|
|
2747
|
+
// src/LocaleClient.ts
|
|
2748
|
+
var import_api9 = require("@uniformdev/context/api");
|
|
2684
2749
|
var localesUrl = "/api/v1/locales";
|
|
2685
|
-
var LocaleClient = class extends
|
|
2750
|
+
var LocaleClient = class extends import_api9.ApiClient {
|
|
2686
2751
|
constructor(options) {
|
|
2687
2752
|
super(options);
|
|
2688
2753
|
}
|
|
@@ -2767,6 +2832,9 @@ var isUpdatePreviewSettingsMessage = (message) => {
|
|
|
2767
2832
|
var isUpdateFeatureFlagsMessage = (message) => {
|
|
2768
2833
|
return message.type === "update-feature-flags";
|
|
2769
2834
|
};
|
|
2835
|
+
var isUpdateAiActionsMessage = (message) => {
|
|
2836
|
+
return message.type === "update-ai-actions";
|
|
2837
|
+
};
|
|
2770
2838
|
var isUpdateContextualEditingStateInternalMessage = (message) => {
|
|
2771
2839
|
return message.type === "update-contextual-editing-state-internal";
|
|
2772
2840
|
};
|
|
@@ -2798,7 +2866,15 @@ var createCanvasChannel = ({
|
|
|
2798
2866
|
let handlerCounter = 0;
|
|
2799
2867
|
const handlers = {};
|
|
2800
2868
|
const broadcastToItems = [...broadcastTo];
|
|
2869
|
+
const addBroadcastTarget = (window2) => {
|
|
2870
|
+
if (!broadcastToItems.includes(window2)) {
|
|
2871
|
+
broadcastToItems.push(window2);
|
|
2872
|
+
}
|
|
2873
|
+
};
|
|
2801
2874
|
const postMessage = (message) => {
|
|
2875
|
+
if (message.type !== "report-rendered-compositions") {
|
|
2876
|
+
console.log("[temp-debug-channel-SEND]", message.type, message);
|
|
2877
|
+
}
|
|
2802
2878
|
broadcastToItems.forEach((item) => item == null ? void 0 : item.postMessage(JSON.stringify(message), "*"));
|
|
2803
2879
|
for (const handlerId in handlers) {
|
|
2804
2880
|
const handler = handlers[handlerId];
|
|
@@ -2987,6 +3063,13 @@ var createCanvasChannel = ({
|
|
|
2987
3063
|
};
|
|
2988
3064
|
postMessage(message);
|
|
2989
3065
|
};
|
|
3066
|
+
const updateAiActions = (options) => {
|
|
3067
|
+
const message = {
|
|
3068
|
+
...options,
|
|
3069
|
+
type: "update-ai-actions"
|
|
3070
|
+
};
|
|
3071
|
+
postMessage(message);
|
|
3072
|
+
};
|
|
2990
3073
|
const contextStorageUpdated = (options) => {
|
|
2991
3074
|
const message = {
|
|
2992
3075
|
...options,
|
|
@@ -3009,6 +3092,9 @@ var createCanvasChannel = ({
|
|
|
3009
3092
|
if (!message) {
|
|
3010
3093
|
return;
|
|
3011
3094
|
}
|
|
3095
|
+
if (message.type !== "report-rendered-compositions") {
|
|
3096
|
+
console.log("[temp-debug-channel] RECV:", message.type, message);
|
|
3097
|
+
}
|
|
3012
3098
|
for (const handlerId in handlers) {
|
|
3013
3099
|
const handler = handlers[handlerId];
|
|
3014
3100
|
if (handler.types.includes(message.type)) {
|
|
@@ -3021,9 +3107,10 @@ var createCanvasChannel = ({
|
|
|
3021
3107
|
listenTo.forEach((item) => item.removeEventListener("message", messageEventListener));
|
|
3022
3108
|
};
|
|
3023
3109
|
return {
|
|
3024
|
-
broadcastTo,
|
|
3110
|
+
broadcastTo: broadcastToItems,
|
|
3025
3111
|
ready,
|
|
3026
3112
|
destroy,
|
|
3113
|
+
addBroadcastTarget,
|
|
3027
3114
|
triggerComponentAction,
|
|
3028
3115
|
selectComponent,
|
|
3029
3116
|
updateComposition,
|
|
@@ -3036,6 +3123,7 @@ var createCanvasChannel = ({
|
|
|
3036
3123
|
triggerCompositionAction,
|
|
3037
3124
|
updatePreviewSettings,
|
|
3038
3125
|
updateFeatureFlags,
|
|
3126
|
+
updateAiActions,
|
|
3039
3127
|
updateContextualEditingStateInternal,
|
|
3040
3128
|
selectParameter,
|
|
3041
3129
|
openParameterEditor,
|
|
@@ -3051,10 +3139,10 @@ var createCanvasChannel = ({
|
|
|
3051
3139
|
};
|
|
3052
3140
|
|
|
3053
3141
|
// src/PreviewClient.ts
|
|
3054
|
-
var
|
|
3142
|
+
var import_api10 = require("@uniformdev/context/api");
|
|
3055
3143
|
var previewUrlsUrl = "/api/v1/preview-urls";
|
|
3056
3144
|
var previewViewportsUrl = "/api/v1/preview-viewports";
|
|
3057
|
-
var PreviewClient = class extends
|
|
3145
|
+
var PreviewClient = class extends import_api10.ApiClient {
|
|
3058
3146
|
constructor(options) {
|
|
3059
3147
|
super(options);
|
|
3060
3148
|
}
|
|
@@ -3117,9 +3205,9 @@ var PreviewClient = class extends import_api9.ApiClient {
|
|
|
3117
3205
|
};
|
|
3118
3206
|
|
|
3119
3207
|
// src/ProjectClient.ts
|
|
3120
|
-
var
|
|
3208
|
+
var import_api11 = require("@uniformdev/context/api");
|
|
3121
3209
|
var _url2;
|
|
3122
|
-
var _ProjectClient = class _ProjectClient extends
|
|
3210
|
+
var _ProjectClient = class _ProjectClient extends import_api11.ApiClient {
|
|
3123
3211
|
constructor(options) {
|
|
3124
3212
|
super({ ...options, bypassCache: true });
|
|
3125
3213
|
}
|
|
@@ -3151,9 +3239,9 @@ __privateAdd(_ProjectClient, _url2, "/api/v1/project");
|
|
|
3151
3239
|
var ProjectClient = _ProjectClient;
|
|
3152
3240
|
|
|
3153
3241
|
// src/PromptClient.ts
|
|
3154
|
-
var
|
|
3242
|
+
var import_api12 = require("@uniformdev/context/api");
|
|
3155
3243
|
var PromptsUrl = "/api/v1/prompts";
|
|
3156
|
-
var PromptClient = class extends
|
|
3244
|
+
var PromptClient = class extends import_api12.ApiClient {
|
|
3157
3245
|
constructor(options) {
|
|
3158
3246
|
super(options);
|
|
3159
3247
|
}
|
|
@@ -3184,9 +3272,9 @@ var PromptClient = class extends import_api11.ApiClient {
|
|
|
3184
3272
|
};
|
|
3185
3273
|
|
|
3186
3274
|
// src/RelationshipClient.ts
|
|
3187
|
-
var
|
|
3275
|
+
var import_api13 = require("@uniformdev/context/api");
|
|
3188
3276
|
var RELATIONSHIPS_URL = "/api/v1/relationships";
|
|
3189
|
-
var RelationshipClient = class extends
|
|
3277
|
+
var RelationshipClient = class extends import_api13.ApiClient {
|
|
3190
3278
|
constructor(options) {
|
|
3191
3279
|
super(options);
|
|
3192
3280
|
this.get = async (options) => {
|
|
@@ -3198,9 +3286,9 @@ var RelationshipClient = class extends import_api12.ApiClient {
|
|
|
3198
3286
|
};
|
|
3199
3287
|
|
|
3200
3288
|
// src/ReleaseClient.ts
|
|
3201
|
-
var
|
|
3289
|
+
var import_api14 = require("@uniformdev/context/api");
|
|
3202
3290
|
var releasesUrl = "/api/v1/releases";
|
|
3203
|
-
var ReleaseClient = class extends
|
|
3291
|
+
var ReleaseClient = class extends import_api14.ApiClient {
|
|
3204
3292
|
constructor(options) {
|
|
3205
3293
|
super(options);
|
|
3206
3294
|
}
|
|
@@ -3240,9 +3328,9 @@ var ReleaseClient = class extends import_api13.ApiClient {
|
|
|
3240
3328
|
};
|
|
3241
3329
|
|
|
3242
3330
|
// src/ReleaseContentsClient.ts
|
|
3243
|
-
var
|
|
3331
|
+
var import_api15 = require("@uniformdev/context/api");
|
|
3244
3332
|
var releaseContentsUrl2 = "/api/v1/release-contents";
|
|
3245
|
-
var ReleaseContentsClient = class extends
|
|
3333
|
+
var ReleaseContentsClient = class extends import_api15.ApiClient {
|
|
3246
3334
|
constructor(options) {
|
|
3247
3335
|
super(options);
|
|
3248
3336
|
}
|
|
@@ -3264,9 +3352,9 @@ var ReleaseContentsClient = class extends import_api14.ApiClient {
|
|
|
3264
3352
|
};
|
|
3265
3353
|
|
|
3266
3354
|
// src/RouteClient.ts
|
|
3267
|
-
var
|
|
3355
|
+
var import_api16 = require("@uniformdev/context/api");
|
|
3268
3356
|
var ROUTE_URL = "/api/v1/route";
|
|
3269
|
-
var RouteClient = class extends
|
|
3357
|
+
var RouteClient = class extends import_api16.ApiClient {
|
|
3270
3358
|
constructor(options) {
|
|
3271
3359
|
var _a;
|
|
3272
3360
|
if (!options.limitPolicy) {
|
|
@@ -3289,6 +3377,63 @@ var RouteClient = class extends import_api15.ApiClient {
|
|
|
3289
3377
|
// src/types/locales.ts
|
|
3290
3378
|
var LOCALE_DYNAMIC_INPUT_NAME = "locale";
|
|
3291
3379
|
|
|
3380
|
+
// src/utils/assetConfig.ts
|
|
3381
|
+
var mergeAssetConfigWithDefaults = (config) => {
|
|
3382
|
+
var _a;
|
|
3383
|
+
return {
|
|
3384
|
+
...config,
|
|
3385
|
+
// For backwards compatibility reasons undefined represents restriction to
|
|
3386
|
+
// image types
|
|
3387
|
+
allowedTypes: (_a = config.allowedTypes) != null ? _a : ["image"]
|
|
3388
|
+
};
|
|
3389
|
+
};
|
|
3390
|
+
|
|
3391
|
+
// src/utils/autoFixParameterGroups.ts
|
|
3392
|
+
function autoFixParameterGroups(properties) {
|
|
3393
|
+
var _a;
|
|
3394
|
+
const remainingGroups = (_a = properties.filter((param) => param.type === "group")) != null ? _a : [];
|
|
3395
|
+
if (remainingGroups.length === 0) {
|
|
3396
|
+
return false;
|
|
3397
|
+
}
|
|
3398
|
+
let result = false;
|
|
3399
|
+
while (remainingGroups.length > 0) {
|
|
3400
|
+
const group = remainingGroups.shift();
|
|
3401
|
+
const groupParamsConfig = group.typeConfig && typeof group.typeConfig === "object" && "childrenParams" in group.typeConfig && Array.isArray(group.typeConfig.childrenParams) ? group.typeConfig.childrenParams : [];
|
|
3402
|
+
const expectedParamsToFindFollowingGroup = new Set(groupParamsConfig);
|
|
3403
|
+
const groupStartIndex = properties.findIndex((param) => param.id === group.id);
|
|
3404
|
+
const groupItemsCount = expectedParamsToFindFollowingGroup.size;
|
|
3405
|
+
for (let i = groupStartIndex + 1; i <= groupStartIndex + groupItemsCount; i++) {
|
|
3406
|
+
const param = properties[i];
|
|
3407
|
+
if (!param) {
|
|
3408
|
+
continue;
|
|
3409
|
+
}
|
|
3410
|
+
if (expectedParamsToFindFollowingGroup.has(param.id)) {
|
|
3411
|
+
expectedParamsToFindFollowingGroup.delete(param.id);
|
|
3412
|
+
} else {
|
|
3413
|
+
break;
|
|
3414
|
+
}
|
|
3415
|
+
}
|
|
3416
|
+
if (expectedParamsToFindFollowingGroup.size > 0) {
|
|
3417
|
+
const paramsToMove = Array.from(expectedParamsToFindFollowingGroup);
|
|
3418
|
+
let leadingGroupIndex = groupStartIndex + groupItemsCount - expectedParamsToFindFollowingGroup.size;
|
|
3419
|
+
for (const paramId of paramsToMove) {
|
|
3420
|
+
const paramIndex = properties.findIndex((param) => param.id === paramId);
|
|
3421
|
+
if (paramIndex !== -1) {
|
|
3422
|
+
const [param] = properties.splice(paramIndex, 1);
|
|
3423
|
+
if (paramIndex > leadingGroupIndex) {
|
|
3424
|
+
leadingGroupIndex++;
|
|
3425
|
+
}
|
|
3426
|
+
properties.splice(leadingGroupIndex, 0, param);
|
|
3427
|
+
} else {
|
|
3428
|
+
groupParamsConfig.splice(groupParamsConfig.indexOf(paramId), 1);
|
|
3429
|
+
}
|
|
3430
|
+
}
|
|
3431
|
+
result = true;
|
|
3432
|
+
}
|
|
3433
|
+
}
|
|
3434
|
+
return result;
|
|
3435
|
+
}
|
|
3436
|
+
|
|
3292
3437
|
// src/utils/createApiEnhancer.ts
|
|
3293
3438
|
var createUniformApiEnhancer = ({ apiUrl }) => {
|
|
3294
3439
|
return async (message) => {
|
|
@@ -3418,7 +3563,8 @@ function mapSlotToTestVariations(slot) {
|
|
|
3418
3563
|
return {
|
|
3419
3564
|
...v,
|
|
3420
3565
|
id,
|
|
3421
|
-
testDistribution: contextTag == null ? void 0 : contextTag.testDistribution
|
|
3566
|
+
testDistribution: contextTag == null ? void 0 : contextTag.testDistribution,
|
|
3567
|
+
control: contextTag == null ? void 0 : contextTag.control
|
|
3422
3568
|
};
|
|
3423
3569
|
});
|
|
3424
3570
|
}
|
|
@@ -3580,15 +3726,15 @@ function handleRichTextNodeBinding(object, options) {
|
|
|
3580
3726
|
}
|
|
3581
3727
|
|
|
3582
3728
|
// src/index.ts
|
|
3583
|
-
var
|
|
3729
|
+
var import_api18 = require("@uniformdev/context/api");
|
|
3584
3730
|
|
|
3585
3731
|
// src/.version.ts
|
|
3586
|
-
var version = "20.
|
|
3732
|
+
var version = "20.44.0";
|
|
3587
3733
|
|
|
3588
3734
|
// src/WorkflowClient.ts
|
|
3589
|
-
var
|
|
3735
|
+
var import_api17 = require("@uniformdev/context/api");
|
|
3590
3736
|
var workflowsUrl = "/api/v1/workflows";
|
|
3591
|
-
var WorkflowClient = class extends
|
|
3737
|
+
var WorkflowClient = class extends import_api17.ApiClient {
|
|
3592
3738
|
constructor(options) {
|
|
3593
3739
|
super(options);
|
|
3594
3740
|
}
|
|
@@ -3619,7 +3765,7 @@ var WorkflowClient = class extends import_api16.ApiClient {
|
|
|
3619
3765
|
};
|
|
3620
3766
|
|
|
3621
3767
|
// src/index.ts
|
|
3622
|
-
var CanvasClientError =
|
|
3768
|
+
var CanvasClientError = import_api18.ApiClientError;
|
|
3623
3769
|
// Annotate the CommonJS export names for ESM import in node:
|
|
3624
3770
|
0 && (module.exports = {
|
|
3625
3771
|
ASSETS_SOURCE_CUSTOM_URL,
|
|
@@ -3635,11 +3781,14 @@ var CanvasClientError = import_api17.ApiClientError;
|
|
|
3635
3781
|
BatchEntry,
|
|
3636
3782
|
BlockFormatError,
|
|
3637
3783
|
CANVAS_BLOCK_PARAM_TYPE,
|
|
3784
|
+
CANVAS_COMPONENT_DISPLAY_NAME_PARAM,
|
|
3638
3785
|
CANVAS_CONTEXTUAL_EDITING_PARAM,
|
|
3639
3786
|
CANVAS_DRAFT_STATE,
|
|
3640
3787
|
CANVAS_EDITOR_STATE,
|
|
3641
3788
|
CANVAS_ENRICHMENT_TAG_PARAM,
|
|
3789
|
+
CANVAS_HYPOTHESIS_PARAM,
|
|
3642
3790
|
CANVAS_INTENT_TAG_PARAM,
|
|
3791
|
+
CANVAS_INTERNAL_PARAM_PREFIX,
|
|
3643
3792
|
CANVAS_LOCALE_TAG_PARAM,
|
|
3644
3793
|
CANVAS_LOCALIZATION_SLOT,
|
|
3645
3794
|
CANVAS_LOCALIZATION_TYPE,
|
|
@@ -3651,7 +3800,12 @@ var CanvasClientError = import_api17.ApiClientError;
|
|
|
3651
3800
|
CANVAS_PERSONALIZE_SLOT,
|
|
3652
3801
|
CANVAS_PERSONALIZE_TYPE,
|
|
3653
3802
|
CANVAS_PUBLISHED_STATE,
|
|
3803
|
+
CANVAS_SLOT_SECTION_GROUP_TYPE_PARAM,
|
|
3804
|
+
CANVAS_SLOT_SECTION_MAX_PARAM,
|
|
3805
|
+
CANVAS_SLOT_SECTION_MIN_PARAM,
|
|
3806
|
+
CANVAS_SLOT_SECTION_NAME_PARAM,
|
|
3654
3807
|
CANVAS_SLOT_SECTION_SLOT,
|
|
3808
|
+
CANVAS_SLOT_SECTION_SPECIFIC_PARAM,
|
|
3655
3809
|
CANVAS_SLOT_SECTION_TYPE,
|
|
3656
3810
|
CANVAS_TEST_SLOT,
|
|
3657
3811
|
CANVAS_TEST_TYPE,
|
|
@@ -3683,6 +3837,7 @@ var CanvasClientError = import_api17.ApiClientError;
|
|
|
3683
3837
|
IN_CONTEXT_EDITOR_PLAYGROUND_QUERY_STRING_PARAM,
|
|
3684
3838
|
IN_CONTEXT_EDITOR_QUERY_STRING_PARAM,
|
|
3685
3839
|
IS_RENDERED_BY_UNIFORM_ATTRIBUTE,
|
|
3840
|
+
IntegrationPropertyEditorsClient,
|
|
3686
3841
|
LOCALE_DYNAMIC_INPUT_NAME,
|
|
3687
3842
|
LocaleClient,
|
|
3688
3843
|
PLACEHOLDER_ID,
|
|
@@ -3699,6 +3854,7 @@ var CanvasClientError = import_api17.ApiClientError;
|
|
|
3699
3854
|
UncachedContentClient,
|
|
3700
3855
|
UniqueBatchEntries,
|
|
3701
3856
|
WorkflowClient,
|
|
3857
|
+
autoFixParameterGroups,
|
|
3702
3858
|
bindExpressionEscapeChars,
|
|
3703
3859
|
bindExpressionPrefix,
|
|
3704
3860
|
bindVariables,
|
|
@@ -3760,6 +3916,7 @@ var CanvasClientError = import_api17.ApiClientError;
|
|
|
3760
3916
|
isSuggestComponentMessage,
|
|
3761
3917
|
isSystemComponentDefinition,
|
|
3762
3918
|
isTriggerCompositionActionMessage,
|
|
3919
|
+
isUpdateAiActionsMessage,
|
|
3763
3920
|
isUpdateComponentParameterMessage,
|
|
3764
3921
|
isUpdateComponentReferencesMessage,
|
|
3765
3922
|
isUpdateCompositionInternalMessage,
|
|
@@ -3770,6 +3927,7 @@ var CanvasClientError = import_api17.ApiClientError;
|
|
|
3770
3927
|
localize,
|
|
3771
3928
|
mapSlotToPersonalizedVariations,
|
|
3772
3929
|
mapSlotToTestVariations,
|
|
3930
|
+
mergeAssetConfigWithDefaults,
|
|
3773
3931
|
nullLimitPolicy,
|
|
3774
3932
|
parseComponentPlaceholderId,
|
|
3775
3933
|
parseVariableExpression,
|