@uniformdev/canvas 20.86.1-alpha.3.sha-954b5d18f0 → 20.87.1-alpha.16.sha-e5d136cbc1
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 +756 -890
- package/dist/index.d.ts +756 -890
- package/dist/index.esm.js +2 -239
- package/dist/index.js +3 -248
- package/dist/index.mjs +2 -239
- package/package.json +7 -6
package/dist/index.esm.js
CHANGED
|
@@ -225,7 +225,6 @@ var CANVAS_PERSONALIZE_TYPE = "$personalization";
|
|
|
225
225
|
var CANVAS_TEST_TYPE = "$test";
|
|
226
226
|
var CANVAS_LOCALIZATION_TYPE = "$localization";
|
|
227
227
|
var CANVAS_SLOT_SECTION_TYPE = "$slotSection";
|
|
228
|
-
var CANVAS_LOOP_TYPE = "$loop";
|
|
229
228
|
var CANVAS_INTENT_TAG_PARAM = "intentTag";
|
|
230
229
|
var CANVAS_LOCALE_TAG_PARAM = "locale";
|
|
231
230
|
var CANVAS_BLOCK_PARAM_TYPE = "$block";
|
|
@@ -233,9 +232,6 @@ var CANVAS_PERSONALIZE_SLOT = "pz";
|
|
|
233
232
|
var CANVAS_TEST_SLOT = "test";
|
|
234
233
|
var CANVAS_LOCALIZATION_SLOT = "localized";
|
|
235
234
|
var CANVAS_SLOT_SECTION_SLOT = "$slotSectionItems";
|
|
236
|
-
var CANVAS_LOOP_SLOT = "body";
|
|
237
|
-
var CANVAS_LOOP_DATA_TYPE = "sys-reserved-loop";
|
|
238
|
-
var CANVAS_ALIAS_DATA_TYPE = "sys-reserved-alias";
|
|
239
235
|
var CANVAS_SLOT_SECTION_NAME_PARAM = "name";
|
|
240
236
|
var CANVAS_SLOT_SECTION_MIN_PARAM = "min";
|
|
241
237
|
var CANVAS_SLOT_SECTION_MAX_PARAM = "max";
|
|
@@ -4063,236 +4059,11 @@ function handleRichTextNodeBinding(object, options) {
|
|
|
4063
4059
|
return void 0;
|
|
4064
4060
|
}
|
|
4065
4061
|
|
|
4066
|
-
// src/utils/wellKnownSystemComponentParameters.ts
|
|
4067
|
-
var wellKnownSystemComponentParameters = [
|
|
4068
|
-
{
|
|
4069
|
-
id: CANVAS_COMPONENT_DISPLAY_NAME_PARAM,
|
|
4070
|
-
name: "Display Name",
|
|
4071
|
-
type: "text"
|
|
4072
|
-
},
|
|
4073
|
-
{
|
|
4074
|
-
id: CANVAS_INTENT_TAG_PARAM,
|
|
4075
|
-
name: "Intent Tag",
|
|
4076
|
-
type: "intentTag"
|
|
4077
|
-
},
|
|
4078
|
-
{
|
|
4079
|
-
id: CANVAS_LOCALE_TAG_PARAM,
|
|
4080
|
-
name: "Locale Visibility",
|
|
4081
|
-
type: "localeSelect"
|
|
4082
|
-
},
|
|
4083
|
-
{
|
|
4084
|
-
id: CANVAS_PERSONALIZATION_PARAM,
|
|
4085
|
-
name: "Personalization Criteria",
|
|
4086
|
-
type: CANVAS_PERSONALIZATION_PARAM
|
|
4087
|
-
},
|
|
4088
|
-
{
|
|
4089
|
-
id: CANVAS_ENRICHMENT_TAG_PARAM,
|
|
4090
|
-
name: "Enrichment Tags",
|
|
4091
|
-
type: CANVAS_ENRICHMENT_TAG_PARAM,
|
|
4092
|
-
helpText: "Seeing this component will increase a visitor's score in these enrichments."
|
|
4093
|
-
},
|
|
4094
|
-
{
|
|
4095
|
-
id: CANVAS_TEST_VARIANT_PARAM,
|
|
4096
|
-
name: "A/B Test",
|
|
4097
|
-
type: "testVariant"
|
|
4098
|
-
},
|
|
4099
|
-
{
|
|
4100
|
-
id: CANVAS_VIZ_CONTROL_PARAM,
|
|
4101
|
-
name: "Visibility Control",
|
|
4102
|
-
type: CANVAS_VIZ_CONTROL_PARAM
|
|
4103
|
-
}
|
|
4104
|
-
];
|
|
4105
|
-
|
|
4106
|
-
// src/utils/wellKnownSystemComponents.ts
|
|
4107
|
-
var wellKnownSystemComponents = [
|
|
4108
|
-
{
|
|
4109
|
-
id: CANVAS_PERSONALIZE_TYPE,
|
|
4110
|
-
name: "Personalization",
|
|
4111
|
-
icon: "track",
|
|
4112
|
-
titleParameter: CANVAS_PERSONALIZATION_EVENT_NAME_PARAM,
|
|
4113
|
-
description: "Contains components that will be shown to visitors based on configurable personalization criteria.",
|
|
4114
|
-
slots: [
|
|
4115
|
-
{
|
|
4116
|
-
id: CANVAS_PERSONALIZE_SLOT,
|
|
4117
|
-
inheritAllowedComponents: true,
|
|
4118
|
-
name: "Personalized Variations",
|
|
4119
|
-
allowedComponents: []
|
|
4120
|
-
}
|
|
4121
|
-
],
|
|
4122
|
-
parameters: [
|
|
4123
|
-
{
|
|
4124
|
-
id: CANVAS_PERSONALIZATION_EVENT_NAME_PARAM,
|
|
4125
|
-
name: "Analytics tracking name",
|
|
4126
|
-
type: "text",
|
|
4127
|
-
typeConfig: {
|
|
4128
|
-
required: true,
|
|
4129
|
-
caption: "Will be sent to your analytics tool. We recommend not changing this once the composition is published."
|
|
4130
|
-
}
|
|
4131
|
-
},
|
|
4132
|
-
{
|
|
4133
|
-
id: CANVAS_PERSONALIZATION_ALGORITHM_PARAM,
|
|
4134
|
-
name: "Selection method",
|
|
4135
|
-
type: CANVAS_PERSONALIZATION_ALGORITHM_TYPE,
|
|
4136
|
-
typeConfig: {
|
|
4137
|
-
required: true
|
|
4138
|
-
}
|
|
4139
|
-
},
|
|
4140
|
-
{
|
|
4141
|
-
id: CANVAS_PERSONALIZATION_TAKE_PARAM,
|
|
4142
|
-
name: "Number of variations to select",
|
|
4143
|
-
type: "number",
|
|
4144
|
-
typeConfig: {
|
|
4145
|
-
regex: "^[0-9]+$",
|
|
4146
|
-
regexMessage: "Please enter a whole number",
|
|
4147
|
-
placeholder: "1"
|
|
4148
|
-
}
|
|
4149
|
-
},
|
|
4150
|
-
{
|
|
4151
|
-
id: CANVAS_HYPOTHESIS_PARAM,
|
|
4152
|
-
name: "Hypothesis",
|
|
4153
|
-
type: "richText",
|
|
4154
|
-
typeConfig: {
|
|
4155
|
-
formatting: {
|
|
4156
|
-
builtIn: ["bold", "italic", "underline"]
|
|
4157
|
-
},
|
|
4158
|
-
elements: {
|
|
4159
|
-
builtIn: ["unorderedList", "orderedList"]
|
|
4160
|
-
}
|
|
4161
|
-
},
|
|
4162
|
-
helpText: "Document the hypothesis or reasoning behind this personalization strategy.",
|
|
4163
|
-
guidance: "Document the hypothesis or reasoning behind this personalization strategy. Not localizable; do not pass a locale when editing."
|
|
4164
|
-
}
|
|
4165
|
-
]
|
|
4166
|
-
},
|
|
4167
|
-
{
|
|
4168
|
-
id: CANVAS_TEST_TYPE,
|
|
4169
|
-
name: "A/B Test",
|
|
4170
|
-
icon: "style",
|
|
4171
|
-
titleParameter: "test",
|
|
4172
|
-
description: "Contains components that will be shown to visitors randomly based on a configurable traffic split.",
|
|
4173
|
-
slots: [
|
|
4174
|
-
{
|
|
4175
|
-
id: CANVAS_TEST_SLOT,
|
|
4176
|
-
inheritAllowedComponents: true,
|
|
4177
|
-
name: "Test Variations",
|
|
4178
|
-
allowedComponents: []
|
|
4179
|
-
}
|
|
4180
|
-
],
|
|
4181
|
-
parameters: [
|
|
4182
|
-
{
|
|
4183
|
-
id: "test",
|
|
4184
|
-
name: "Test name",
|
|
4185
|
-
type: "testSelect"
|
|
4186
|
-
},
|
|
4187
|
-
{
|
|
4188
|
-
id: CANVAS_HYPOTHESIS_PARAM,
|
|
4189
|
-
name: "Hypothesis",
|
|
4190
|
-
type: "richText",
|
|
4191
|
-
typeConfig: {
|
|
4192
|
-
formatting: {
|
|
4193
|
-
builtIn: ["bold", "italic", "underline"]
|
|
4194
|
-
},
|
|
4195
|
-
elements: {
|
|
4196
|
-
builtIn: ["unorderedList", "orderedList"]
|
|
4197
|
-
}
|
|
4198
|
-
},
|
|
4199
|
-
helpText: "Document the hypothesis or expected outcome of this A/B test.",
|
|
4200
|
-
guidance: "Document the hypothesis or expected outcome of this A/B test. Not localizable; do not pass a locale when editing."
|
|
4201
|
-
}
|
|
4202
|
-
]
|
|
4203
|
-
},
|
|
4204
|
-
{
|
|
4205
|
-
id: CANVAS_LOCALIZATION_TYPE,
|
|
4206
|
-
name: "Localization",
|
|
4207
|
-
icon: "globe-alt",
|
|
4208
|
-
description: "Contains components that will be shown based on visitor locale.",
|
|
4209
|
-
slots: [
|
|
4210
|
-
{
|
|
4211
|
-
id: CANVAS_LOCALIZATION_SLOT,
|
|
4212
|
-
inheritAllowedComponents: true,
|
|
4213
|
-
name: "Localized Variations",
|
|
4214
|
-
allowedComponents: []
|
|
4215
|
-
}
|
|
4216
|
-
]
|
|
4217
|
-
},
|
|
4218
|
-
{
|
|
4219
|
-
id: CANVAS_LOOP_TYPE,
|
|
4220
|
-
name: "Loop",
|
|
4221
|
-
icon: "repeat",
|
|
4222
|
-
description: "Contains components that will be repeated for each item in a list (array) selected from a data resource.",
|
|
4223
|
-
slots: [
|
|
4224
|
-
{
|
|
4225
|
-
id: CANVAS_LOOP_SLOT,
|
|
4226
|
-
inheritAllowedComponents: true,
|
|
4227
|
-
name: "Body",
|
|
4228
|
-
minComponents: 1,
|
|
4229
|
-
allowedComponents: []
|
|
4230
|
-
}
|
|
4231
|
-
]
|
|
4232
|
-
},
|
|
4233
|
-
{
|
|
4234
|
-
id: CANVAS_SLOT_SECTION_TYPE,
|
|
4235
|
-
name: "Slot Section",
|
|
4236
|
-
icon: "copy-all",
|
|
4237
|
-
titleParameter: CANVAS_SLOT_SECTION_NAME_PARAM,
|
|
4238
|
-
description: "When using this pattern, new components may be added at the location where this component is inserted.",
|
|
4239
|
-
slots: [
|
|
4240
|
-
{
|
|
4241
|
-
id: CANVAS_SLOT_SECTION_SLOT,
|
|
4242
|
-
inheritAllowedComponents: true,
|
|
4243
|
-
name: "Items",
|
|
4244
|
-
allowedComponents: []
|
|
4245
|
-
}
|
|
4246
|
-
],
|
|
4247
|
-
parameters: [
|
|
4248
|
-
{
|
|
4249
|
-
id: CANVAS_SLOT_SECTION_NAME_PARAM,
|
|
4250
|
-
name: "Name",
|
|
4251
|
-
type: "text"
|
|
4252
|
-
},
|
|
4253
|
-
{
|
|
4254
|
-
id: CANVAS_SLOT_SECTION_MIN_PARAM,
|
|
4255
|
-
name: "Minimum",
|
|
4256
|
-
type: "text"
|
|
4257
|
-
},
|
|
4258
|
-
{
|
|
4259
|
-
id: CANVAS_SLOT_SECTION_MAX_PARAM,
|
|
4260
|
-
name: "Maximum",
|
|
4261
|
-
type: "text"
|
|
4262
|
-
},
|
|
4263
|
-
{
|
|
4264
|
-
id: CANVAS_SLOT_SECTION_GROUP_TYPE_PARAM,
|
|
4265
|
-
name: "Group Type",
|
|
4266
|
-
type: "text"
|
|
4267
|
-
},
|
|
4268
|
-
{
|
|
4269
|
-
id: CANVAS_SLOT_SECTION_SPECIFIC_PARAM,
|
|
4270
|
-
name: "Specific",
|
|
4271
|
-
type: "array"
|
|
4272
|
-
}
|
|
4273
|
-
]
|
|
4274
|
-
}
|
|
4275
|
-
];
|
|
4276
|
-
var systemComponentsMetadata = {
|
|
4277
|
-
$personalization: void 0,
|
|
4278
|
-
$test: void 0,
|
|
4279
|
-
$localization: void 0,
|
|
4280
|
-
$loop: void 0,
|
|
4281
|
-
$slotSection: {
|
|
4282
|
-
isAutoAllowed: true,
|
|
4283
|
-
isOnlyAllowedInPatternEditor: true
|
|
4284
|
-
}
|
|
4285
|
-
};
|
|
4286
|
-
var getComponentMetadata = (type) => {
|
|
4287
|
-
const metadata = systemComponentsMetadata[type];
|
|
4288
|
-
return metadata;
|
|
4289
|
-
};
|
|
4290
|
-
|
|
4291
4062
|
// src/index.ts
|
|
4292
4063
|
import { ApiClientError as ApiClientError5 } from "@uniformdev/context/api";
|
|
4293
4064
|
|
|
4294
4065
|
// src/.version.ts
|
|
4295
|
-
var version = "20.
|
|
4066
|
+
var version = "20.87.0";
|
|
4296
4067
|
|
|
4297
4068
|
// src/WorkflowClient.ts
|
|
4298
4069
|
import { ApiClient as ApiClient18 } from "@uniformdev/context/api";
|
|
@@ -4350,7 +4121,6 @@ export {
|
|
|
4350
4121
|
ApiClientError5 as ApiClientError,
|
|
4351
4122
|
BatchEntry,
|
|
4352
4123
|
BlockFormatError,
|
|
4353
|
-
CANVAS_ALIAS_DATA_TYPE,
|
|
4354
4124
|
CANVAS_BLOCK_PARAM_TYPE,
|
|
4355
4125
|
CANVAS_COMPONENT_DISPLAY_NAME_PARAM,
|
|
4356
4126
|
CANVAS_CONTEXTUAL_EDITING_PARAM,
|
|
@@ -4363,9 +4133,6 @@ export {
|
|
|
4363
4133
|
CANVAS_LOCALE_TAG_PARAM,
|
|
4364
4134
|
CANVAS_LOCALIZATION_SLOT,
|
|
4365
4135
|
CANVAS_LOCALIZATION_TYPE,
|
|
4366
|
-
CANVAS_LOOP_DATA_TYPE,
|
|
4367
|
-
CANVAS_LOOP_SLOT,
|
|
4368
|
-
CANVAS_LOOP_TYPE,
|
|
4369
4136
|
CANVAS_PERSONALIZATION_ALGORITHM_PARAM,
|
|
4370
4137
|
CANVAS_PERSONALIZATION_ALGORITHM_TYPE,
|
|
4371
4138
|
CANVAS_PERSONALIZATION_EVENT_NAME_PARAM,
|
|
@@ -4469,7 +4236,6 @@ export {
|
|
|
4469
4236
|
generateHash,
|
|
4470
4237
|
getBlockValue,
|
|
4471
4238
|
getComponentJsonPointer,
|
|
4472
|
-
getComponentMetadata,
|
|
4473
4239
|
getComponentPath,
|
|
4474
4240
|
getDataSourceVariantFromRouteGetParams,
|
|
4475
4241
|
getEffectivePropertyValue,
|
|
@@ -4521,10 +4287,7 @@ export {
|
|
|
4521
4287
|
parseVariableExpression,
|
|
4522
4288
|
projectionToQuery,
|
|
4523
4289
|
queryToProjection,
|
|
4524
|
-
systemComponentsMetadata,
|
|
4525
4290
|
version,
|
|
4526
4291
|
walkNodeTree,
|
|
4527
|
-
walkPropertyValues
|
|
4528
|
-
wellKnownSystemComponentParameters,
|
|
4529
|
-
wellKnownSystemComponents
|
|
4292
|
+
walkPropertyValues
|
|
4530
4293
|
};
|
package/dist/index.js
CHANGED
|
@@ -48,7 +48,6 @@ __export(index_exports, {
|
|
|
48
48
|
ApiClientError: () => import_api27.ApiClientError,
|
|
49
49
|
BatchEntry: () => BatchEntry,
|
|
50
50
|
BlockFormatError: () => BlockFormatError,
|
|
51
|
-
CANVAS_ALIAS_DATA_TYPE: () => CANVAS_ALIAS_DATA_TYPE,
|
|
52
51
|
CANVAS_BLOCK_PARAM_TYPE: () => CANVAS_BLOCK_PARAM_TYPE,
|
|
53
52
|
CANVAS_COMPONENT_DISPLAY_NAME_PARAM: () => CANVAS_COMPONENT_DISPLAY_NAME_PARAM,
|
|
54
53
|
CANVAS_CONTEXTUAL_EDITING_PARAM: () => CANVAS_CONTEXTUAL_EDITING_PARAM,
|
|
@@ -61,9 +60,6 @@ __export(index_exports, {
|
|
|
61
60
|
CANVAS_LOCALE_TAG_PARAM: () => CANVAS_LOCALE_TAG_PARAM,
|
|
62
61
|
CANVAS_LOCALIZATION_SLOT: () => CANVAS_LOCALIZATION_SLOT,
|
|
63
62
|
CANVAS_LOCALIZATION_TYPE: () => CANVAS_LOCALIZATION_TYPE,
|
|
64
|
-
CANVAS_LOOP_DATA_TYPE: () => CANVAS_LOOP_DATA_TYPE,
|
|
65
|
-
CANVAS_LOOP_SLOT: () => CANVAS_LOOP_SLOT,
|
|
66
|
-
CANVAS_LOOP_TYPE: () => CANVAS_LOOP_TYPE,
|
|
67
63
|
CANVAS_PERSONALIZATION_ALGORITHM_PARAM: () => CANVAS_PERSONALIZATION_ALGORITHM_PARAM,
|
|
68
64
|
CANVAS_PERSONALIZATION_ALGORITHM_TYPE: () => CANVAS_PERSONALIZATION_ALGORITHM_TYPE,
|
|
69
65
|
CANVAS_PERSONALIZATION_EVENT_NAME_PARAM: () => CANVAS_PERSONALIZATION_EVENT_NAME_PARAM,
|
|
@@ -167,7 +163,6 @@ __export(index_exports, {
|
|
|
167
163
|
generateHash: () => generateHash,
|
|
168
164
|
getBlockValue: () => getBlockValue,
|
|
169
165
|
getComponentJsonPointer: () => getComponentJsonPointer,
|
|
170
|
-
getComponentMetadata: () => getComponentMetadata,
|
|
171
166
|
getComponentPath: () => getComponentPath,
|
|
172
167
|
getDataSourceVariantFromRouteGetParams: () => getDataSourceVariantFromRouteGetParams,
|
|
173
168
|
getEffectivePropertyValue: () => getEffectivePropertyValue,
|
|
@@ -219,12 +214,9 @@ __export(index_exports, {
|
|
|
219
214
|
parseVariableExpression: () => parseVariableExpression,
|
|
220
215
|
projectionToQuery: () => projectionToQuery,
|
|
221
216
|
queryToProjection: () => queryToProjection,
|
|
222
|
-
systemComponentsMetadata: () => systemComponentsMetadata,
|
|
223
217
|
version: () => version,
|
|
224
218
|
walkNodeTree: () => walkNodeTree,
|
|
225
|
-
walkPropertyValues: () => walkPropertyValues
|
|
226
|
-
wellKnownSystemComponentParameters: () => wellKnownSystemComponentParameters,
|
|
227
|
-
wellKnownSystemComponents: () => wellKnownSystemComponents
|
|
219
|
+
walkPropertyValues: () => walkPropertyValues
|
|
228
220
|
});
|
|
229
221
|
module.exports = __toCommonJS(index_exports);
|
|
230
222
|
|
|
@@ -448,7 +440,6 @@ var CANVAS_PERSONALIZE_TYPE = "$personalization";
|
|
|
448
440
|
var CANVAS_TEST_TYPE = "$test";
|
|
449
441
|
var CANVAS_LOCALIZATION_TYPE = "$localization";
|
|
450
442
|
var CANVAS_SLOT_SECTION_TYPE = "$slotSection";
|
|
451
|
-
var CANVAS_LOOP_TYPE = "$loop";
|
|
452
443
|
var CANVAS_INTENT_TAG_PARAM = "intentTag";
|
|
453
444
|
var CANVAS_LOCALE_TAG_PARAM = "locale";
|
|
454
445
|
var CANVAS_BLOCK_PARAM_TYPE = "$block";
|
|
@@ -456,9 +447,6 @@ var CANVAS_PERSONALIZE_SLOT = "pz";
|
|
|
456
447
|
var CANVAS_TEST_SLOT = "test";
|
|
457
448
|
var CANVAS_LOCALIZATION_SLOT = "localized";
|
|
458
449
|
var CANVAS_SLOT_SECTION_SLOT = "$slotSectionItems";
|
|
459
|
-
var CANVAS_LOOP_SLOT = "body";
|
|
460
|
-
var CANVAS_LOOP_DATA_TYPE = "sys-reserved-loop";
|
|
461
|
-
var CANVAS_ALIAS_DATA_TYPE = "sys-reserved-alias";
|
|
462
450
|
var CANVAS_SLOT_SECTION_NAME_PARAM = "name";
|
|
463
451
|
var CANVAS_SLOT_SECTION_MIN_PARAM = "min";
|
|
464
452
|
var CANVAS_SLOT_SECTION_MAX_PARAM = "max";
|
|
@@ -4286,236 +4274,11 @@ function handleRichTextNodeBinding(object, options) {
|
|
|
4286
4274
|
return void 0;
|
|
4287
4275
|
}
|
|
4288
4276
|
|
|
4289
|
-
// src/utils/wellKnownSystemComponentParameters.ts
|
|
4290
|
-
var wellKnownSystemComponentParameters = [
|
|
4291
|
-
{
|
|
4292
|
-
id: CANVAS_COMPONENT_DISPLAY_NAME_PARAM,
|
|
4293
|
-
name: "Display Name",
|
|
4294
|
-
type: "text"
|
|
4295
|
-
},
|
|
4296
|
-
{
|
|
4297
|
-
id: CANVAS_INTENT_TAG_PARAM,
|
|
4298
|
-
name: "Intent Tag",
|
|
4299
|
-
type: "intentTag"
|
|
4300
|
-
},
|
|
4301
|
-
{
|
|
4302
|
-
id: CANVAS_LOCALE_TAG_PARAM,
|
|
4303
|
-
name: "Locale Visibility",
|
|
4304
|
-
type: "localeSelect"
|
|
4305
|
-
},
|
|
4306
|
-
{
|
|
4307
|
-
id: CANVAS_PERSONALIZATION_PARAM,
|
|
4308
|
-
name: "Personalization Criteria",
|
|
4309
|
-
type: CANVAS_PERSONALIZATION_PARAM
|
|
4310
|
-
},
|
|
4311
|
-
{
|
|
4312
|
-
id: CANVAS_ENRICHMENT_TAG_PARAM,
|
|
4313
|
-
name: "Enrichment Tags",
|
|
4314
|
-
type: CANVAS_ENRICHMENT_TAG_PARAM,
|
|
4315
|
-
helpText: "Seeing this component will increase a visitor's score in these enrichments."
|
|
4316
|
-
},
|
|
4317
|
-
{
|
|
4318
|
-
id: CANVAS_TEST_VARIANT_PARAM,
|
|
4319
|
-
name: "A/B Test",
|
|
4320
|
-
type: "testVariant"
|
|
4321
|
-
},
|
|
4322
|
-
{
|
|
4323
|
-
id: CANVAS_VIZ_CONTROL_PARAM,
|
|
4324
|
-
name: "Visibility Control",
|
|
4325
|
-
type: CANVAS_VIZ_CONTROL_PARAM
|
|
4326
|
-
}
|
|
4327
|
-
];
|
|
4328
|
-
|
|
4329
|
-
// src/utils/wellKnownSystemComponents.ts
|
|
4330
|
-
var wellKnownSystemComponents = [
|
|
4331
|
-
{
|
|
4332
|
-
id: CANVAS_PERSONALIZE_TYPE,
|
|
4333
|
-
name: "Personalization",
|
|
4334
|
-
icon: "track",
|
|
4335
|
-
titleParameter: CANVAS_PERSONALIZATION_EVENT_NAME_PARAM,
|
|
4336
|
-
description: "Contains components that will be shown to visitors based on configurable personalization criteria.",
|
|
4337
|
-
slots: [
|
|
4338
|
-
{
|
|
4339
|
-
id: CANVAS_PERSONALIZE_SLOT,
|
|
4340
|
-
inheritAllowedComponents: true,
|
|
4341
|
-
name: "Personalized Variations",
|
|
4342
|
-
allowedComponents: []
|
|
4343
|
-
}
|
|
4344
|
-
],
|
|
4345
|
-
parameters: [
|
|
4346
|
-
{
|
|
4347
|
-
id: CANVAS_PERSONALIZATION_EVENT_NAME_PARAM,
|
|
4348
|
-
name: "Analytics tracking name",
|
|
4349
|
-
type: "text",
|
|
4350
|
-
typeConfig: {
|
|
4351
|
-
required: true,
|
|
4352
|
-
caption: "Will be sent to your analytics tool. We recommend not changing this once the composition is published."
|
|
4353
|
-
}
|
|
4354
|
-
},
|
|
4355
|
-
{
|
|
4356
|
-
id: CANVAS_PERSONALIZATION_ALGORITHM_PARAM,
|
|
4357
|
-
name: "Selection method",
|
|
4358
|
-
type: CANVAS_PERSONALIZATION_ALGORITHM_TYPE,
|
|
4359
|
-
typeConfig: {
|
|
4360
|
-
required: true
|
|
4361
|
-
}
|
|
4362
|
-
},
|
|
4363
|
-
{
|
|
4364
|
-
id: CANVAS_PERSONALIZATION_TAKE_PARAM,
|
|
4365
|
-
name: "Number of variations to select",
|
|
4366
|
-
type: "number",
|
|
4367
|
-
typeConfig: {
|
|
4368
|
-
regex: "^[0-9]+$",
|
|
4369
|
-
regexMessage: "Please enter a whole number",
|
|
4370
|
-
placeholder: "1"
|
|
4371
|
-
}
|
|
4372
|
-
},
|
|
4373
|
-
{
|
|
4374
|
-
id: CANVAS_HYPOTHESIS_PARAM,
|
|
4375
|
-
name: "Hypothesis",
|
|
4376
|
-
type: "richText",
|
|
4377
|
-
typeConfig: {
|
|
4378
|
-
formatting: {
|
|
4379
|
-
builtIn: ["bold", "italic", "underline"]
|
|
4380
|
-
},
|
|
4381
|
-
elements: {
|
|
4382
|
-
builtIn: ["unorderedList", "orderedList"]
|
|
4383
|
-
}
|
|
4384
|
-
},
|
|
4385
|
-
helpText: "Document the hypothesis or reasoning behind this personalization strategy.",
|
|
4386
|
-
guidance: "Document the hypothesis or reasoning behind this personalization strategy. Not localizable; do not pass a locale when editing."
|
|
4387
|
-
}
|
|
4388
|
-
]
|
|
4389
|
-
},
|
|
4390
|
-
{
|
|
4391
|
-
id: CANVAS_TEST_TYPE,
|
|
4392
|
-
name: "A/B Test",
|
|
4393
|
-
icon: "style",
|
|
4394
|
-
titleParameter: "test",
|
|
4395
|
-
description: "Contains components that will be shown to visitors randomly based on a configurable traffic split.",
|
|
4396
|
-
slots: [
|
|
4397
|
-
{
|
|
4398
|
-
id: CANVAS_TEST_SLOT,
|
|
4399
|
-
inheritAllowedComponents: true,
|
|
4400
|
-
name: "Test Variations",
|
|
4401
|
-
allowedComponents: []
|
|
4402
|
-
}
|
|
4403
|
-
],
|
|
4404
|
-
parameters: [
|
|
4405
|
-
{
|
|
4406
|
-
id: "test",
|
|
4407
|
-
name: "Test name",
|
|
4408
|
-
type: "testSelect"
|
|
4409
|
-
},
|
|
4410
|
-
{
|
|
4411
|
-
id: CANVAS_HYPOTHESIS_PARAM,
|
|
4412
|
-
name: "Hypothesis",
|
|
4413
|
-
type: "richText",
|
|
4414
|
-
typeConfig: {
|
|
4415
|
-
formatting: {
|
|
4416
|
-
builtIn: ["bold", "italic", "underline"]
|
|
4417
|
-
},
|
|
4418
|
-
elements: {
|
|
4419
|
-
builtIn: ["unorderedList", "orderedList"]
|
|
4420
|
-
}
|
|
4421
|
-
},
|
|
4422
|
-
helpText: "Document the hypothesis or expected outcome of this A/B test.",
|
|
4423
|
-
guidance: "Document the hypothesis or expected outcome of this A/B test. Not localizable; do not pass a locale when editing."
|
|
4424
|
-
}
|
|
4425
|
-
]
|
|
4426
|
-
},
|
|
4427
|
-
{
|
|
4428
|
-
id: CANVAS_LOCALIZATION_TYPE,
|
|
4429
|
-
name: "Localization",
|
|
4430
|
-
icon: "globe-alt",
|
|
4431
|
-
description: "Contains components that will be shown based on visitor locale.",
|
|
4432
|
-
slots: [
|
|
4433
|
-
{
|
|
4434
|
-
id: CANVAS_LOCALIZATION_SLOT,
|
|
4435
|
-
inheritAllowedComponents: true,
|
|
4436
|
-
name: "Localized Variations",
|
|
4437
|
-
allowedComponents: []
|
|
4438
|
-
}
|
|
4439
|
-
]
|
|
4440
|
-
},
|
|
4441
|
-
{
|
|
4442
|
-
id: CANVAS_LOOP_TYPE,
|
|
4443
|
-
name: "Loop",
|
|
4444
|
-
icon: "repeat",
|
|
4445
|
-
description: "Contains components that will be repeated for each item in a list (array) selected from a data resource.",
|
|
4446
|
-
slots: [
|
|
4447
|
-
{
|
|
4448
|
-
id: CANVAS_LOOP_SLOT,
|
|
4449
|
-
inheritAllowedComponents: true,
|
|
4450
|
-
name: "Body",
|
|
4451
|
-
minComponents: 1,
|
|
4452
|
-
allowedComponents: []
|
|
4453
|
-
}
|
|
4454
|
-
]
|
|
4455
|
-
},
|
|
4456
|
-
{
|
|
4457
|
-
id: CANVAS_SLOT_SECTION_TYPE,
|
|
4458
|
-
name: "Slot Section",
|
|
4459
|
-
icon: "copy-all",
|
|
4460
|
-
titleParameter: CANVAS_SLOT_SECTION_NAME_PARAM,
|
|
4461
|
-
description: "When using this pattern, new components may be added at the location where this component is inserted.",
|
|
4462
|
-
slots: [
|
|
4463
|
-
{
|
|
4464
|
-
id: CANVAS_SLOT_SECTION_SLOT,
|
|
4465
|
-
inheritAllowedComponents: true,
|
|
4466
|
-
name: "Items",
|
|
4467
|
-
allowedComponents: []
|
|
4468
|
-
}
|
|
4469
|
-
],
|
|
4470
|
-
parameters: [
|
|
4471
|
-
{
|
|
4472
|
-
id: CANVAS_SLOT_SECTION_NAME_PARAM,
|
|
4473
|
-
name: "Name",
|
|
4474
|
-
type: "text"
|
|
4475
|
-
},
|
|
4476
|
-
{
|
|
4477
|
-
id: CANVAS_SLOT_SECTION_MIN_PARAM,
|
|
4478
|
-
name: "Minimum",
|
|
4479
|
-
type: "text"
|
|
4480
|
-
},
|
|
4481
|
-
{
|
|
4482
|
-
id: CANVAS_SLOT_SECTION_MAX_PARAM,
|
|
4483
|
-
name: "Maximum",
|
|
4484
|
-
type: "text"
|
|
4485
|
-
},
|
|
4486
|
-
{
|
|
4487
|
-
id: CANVAS_SLOT_SECTION_GROUP_TYPE_PARAM,
|
|
4488
|
-
name: "Group Type",
|
|
4489
|
-
type: "text"
|
|
4490
|
-
},
|
|
4491
|
-
{
|
|
4492
|
-
id: CANVAS_SLOT_SECTION_SPECIFIC_PARAM,
|
|
4493
|
-
name: "Specific",
|
|
4494
|
-
type: "array"
|
|
4495
|
-
}
|
|
4496
|
-
]
|
|
4497
|
-
}
|
|
4498
|
-
];
|
|
4499
|
-
var systemComponentsMetadata = {
|
|
4500
|
-
$personalization: void 0,
|
|
4501
|
-
$test: void 0,
|
|
4502
|
-
$localization: void 0,
|
|
4503
|
-
$loop: void 0,
|
|
4504
|
-
$slotSection: {
|
|
4505
|
-
isAutoAllowed: true,
|
|
4506
|
-
isOnlyAllowedInPatternEditor: true
|
|
4507
|
-
}
|
|
4508
|
-
};
|
|
4509
|
-
var getComponentMetadata = (type) => {
|
|
4510
|
-
const metadata = systemComponentsMetadata[type];
|
|
4511
|
-
return metadata;
|
|
4512
|
-
};
|
|
4513
|
-
|
|
4514
4277
|
// src/index.ts
|
|
4515
4278
|
var import_api27 = require("@uniformdev/context/api");
|
|
4516
4279
|
|
|
4517
4280
|
// src/.version.ts
|
|
4518
|
-
var version = "20.
|
|
4281
|
+
var version = "20.87.0";
|
|
4519
4282
|
|
|
4520
4283
|
// src/WorkflowClient.ts
|
|
4521
4284
|
var import_api26 = require("@uniformdev/context/api");
|
|
@@ -4574,7 +4337,6 @@ var CanvasClientError = import_api27.ApiClientError;
|
|
|
4574
4337
|
ApiClientError,
|
|
4575
4338
|
BatchEntry,
|
|
4576
4339
|
BlockFormatError,
|
|
4577
|
-
CANVAS_ALIAS_DATA_TYPE,
|
|
4578
4340
|
CANVAS_BLOCK_PARAM_TYPE,
|
|
4579
4341
|
CANVAS_COMPONENT_DISPLAY_NAME_PARAM,
|
|
4580
4342
|
CANVAS_CONTEXTUAL_EDITING_PARAM,
|
|
@@ -4587,9 +4349,6 @@ var CanvasClientError = import_api27.ApiClientError;
|
|
|
4587
4349
|
CANVAS_LOCALE_TAG_PARAM,
|
|
4588
4350
|
CANVAS_LOCALIZATION_SLOT,
|
|
4589
4351
|
CANVAS_LOCALIZATION_TYPE,
|
|
4590
|
-
CANVAS_LOOP_DATA_TYPE,
|
|
4591
|
-
CANVAS_LOOP_SLOT,
|
|
4592
|
-
CANVAS_LOOP_TYPE,
|
|
4593
4352
|
CANVAS_PERSONALIZATION_ALGORITHM_PARAM,
|
|
4594
4353
|
CANVAS_PERSONALIZATION_ALGORITHM_TYPE,
|
|
4595
4354
|
CANVAS_PERSONALIZATION_EVENT_NAME_PARAM,
|
|
@@ -4693,7 +4452,6 @@ var CanvasClientError = import_api27.ApiClientError;
|
|
|
4693
4452
|
generateHash,
|
|
4694
4453
|
getBlockValue,
|
|
4695
4454
|
getComponentJsonPointer,
|
|
4696
|
-
getComponentMetadata,
|
|
4697
4455
|
getComponentPath,
|
|
4698
4456
|
getDataSourceVariantFromRouteGetParams,
|
|
4699
4457
|
getEffectivePropertyValue,
|
|
@@ -4745,10 +4503,7 @@ var CanvasClientError = import_api27.ApiClientError;
|
|
|
4745
4503
|
parseVariableExpression,
|
|
4746
4504
|
projectionToQuery,
|
|
4747
4505
|
queryToProjection,
|
|
4748
|
-
systemComponentsMetadata,
|
|
4749
4506
|
version,
|
|
4750
4507
|
walkNodeTree,
|
|
4751
|
-
walkPropertyValues
|
|
4752
|
-
wellKnownSystemComponentParameters,
|
|
4753
|
-
wellKnownSystemComponents
|
|
4508
|
+
walkPropertyValues
|
|
4754
4509
|
});
|