@designcrowd/library.brand-page 5.19.1-id-based-items-2 → 5.19.2
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/lib/src/{CreatedOnBrandCrowd-de-de-Ruu5Az32.js → CreatedOnBrandCrowd-de-de-Ekmn0O3s.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-en-us-DGUJtvld.js → CreatedOnBrandCrowd-en-us-BjeXlKTS.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-es-es-Dg-1uOfV.js → CreatedOnBrandCrowd-es-es-rpNINAMY.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-fr-CRKraZl8.js → CreatedOnBrandCrowd-fr-ca-BL4nSaLj.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-ca-CRKraZl8.js → CreatedOnBrandCrowd-fr-fr-BL4nSaLj.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-pt-bZ9VlEAu.js → CreatedOnBrandCrowd-pt-br-K0r4FyYq.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-br-bZ9VlEAu.js → CreatedOnBrandCrowd-pt-pt-K0r4FyYq.js} +1 -1
- package/lib/src/{CreatedOnDcom-de-de-CJYfwZx8.js → CreatedOnDcom-de-de-0XYyEKYc.js} +1 -1
- package/lib/src/{CreatedOnDcom-en-us-rzA1lVxH.js → CreatedOnDcom-en-us-E8hvwiMd.js} +1 -1
- package/lib/src/{CreatedOnDcom-es-es-CNwGPjik.js → CreatedOnDcom-es-es-pRuCd7xX.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-ca-DKw7OGIz.js → CreatedOnDcom-fr-ca-Bu4V3jpn.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-fr-WzOEaAZG.js → CreatedOnDcom-fr-fr-CCcrGNz2.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-br-DkualVhm.js → CreatedOnDcom-pt-br-1GTvaLKd.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-pt-w4Nnsdzq.js → CreatedOnDcom-pt-pt-CTIYW10X.js} +1 -1
- package/lib/src/brand-page/components/image-gallery/masonry/MasonryGallery.mixin.d.ts +1 -1
- package/lib/src/brand-page/models/index.d.ts +1 -12
- package/lib/src/brand-page/models/index.js +3 -0
- package/lib/src/brand-page/utils/personalisation.util.js +72 -14
- package/lib/src/brand-page-maker/components/action-bar/ActionBar.mixin.d.ts +1 -1
- package/lib/src/brand-page-maker/components/admin-background-settings/AdminBackgroundSettings.mixin.d.ts +6 -0
- package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.mixin.d.ts +12 -1
- package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.mixin.js +2 -0
- package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.stories.js +1 -0
- package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMakerTemplateSettings.mixin.d.ts +1 -1
- package/lib/src/brand-page-maker/components/brandpage-maker-page/BrandPageMakerPage.mixin.d.ts +1 -1
- package/lib/src/brand-page-maker/components/brandpage-settings/ReplaceImageSettingsForBrandPageSettings.mixin.d.ts +1 -1
- package/lib/src/brand-page-maker/components/seo-settings/SeoPageSettings.mixin.d.ts +1 -1
- package/lib/src/brand-page-maker/components/seo-settings/UrlSettings.mixin.d.ts +1 -1
- package/lib/src/brand-page-maker/components/social-share/SocialShare.mixin.d.ts +1 -1
- package/lib/src/brand-page-maker/components/template-preview/TemplatePreview.mixin.d.ts +2 -3
- package/lib/src/brand-page-maker/components/template-preview/TemplatePreview.mixin.js +16 -5
- package/lib/src/brand-page-maker/composables/ai-chat/useAiWebsiteBuilderChat.js +0 -5
- package/lib/src/brand-page-maker/stores/ai-checkpoint/ai-checkpoint-store.d.ts +6 -18
- package/lib/src/brand-page-maker/stores/brandpage-container/brand-page-container-store.d.ts +1 -0
- package/lib/src/brand-page-maker/stores/brandpage-container/brand-page-container-store.js +3 -0
- package/lib/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.d.ts +3 -1
- package/lib/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.js +5 -1
- package/lib/src/brand-page-maker/stores/ui/ui-store.d.ts +6 -0
- package/lib/src/brand-page-maker/stores/ui/ui-store.js +8 -0
- package/lib/src/clients/design-template-client.d.ts +3 -0
- package/lib/src/clients/models.d.ts +2 -0
- package/lib/src/css/library.brand-page-brandCrowd.min.css +19 -7
- package/lib/src/css/library.brand-page-brandPage.min.css +19 -7
- package/lib/src/css/library.brand-page-designCom.min.css +19 -7
- package/lib/src/css/library.brand-page-preview.min.css +19 -7
- package/lib/src/index.mjs +1 -1
- package/lib/src/{lib-Dy7MYyqz.js → lib-BfgUqu0B.js} +25060 -24791
- package/lib/src/metadata-builder/builders/footer-builder.js +44 -34
- package/lib/src/metadata-builder/builders/section-builders/image-gallery-builder.js +68 -57
- package/lib/src/metadata-builder/builders/section-builders/images-section-builder.js +93 -58
- package/lib/src/metadata-builder/builders/section-builders/shapes-section-builder.js +99 -66
- package/lib/src/metadata-builder/builders/section-builders/social-links-builder.js +17 -57
- package/lib/src/metadata-builder/builders/section-builders/testimonial-section-builder.js +85 -51
- package/lib/src/metadata-builder/builders/section-builders/text-section-builder.js +74 -49
- package/lib/src/metadata-builder/parsers/ai-toolcall-parser.d.ts +4 -13
- package/lib/src/metadata-builder/parsers/section-tool-arguments.d.ts +48 -66
- package/lib/src/shared/content-settings/components/content-settings/ContentSettings.mixin.d.ts +1 -1
- package/lib/src/shared/content-settings/components/content-settings/ReplaceImageSettingsForContent.mixin.d.ts +1 -1
- package/lib/src/shared/content-settings/components/content-settings-item/ContentSettingsItemField.mixin.d.ts +7 -1
- package/lib/src/shared/logo-settings/components/EditLogoSettings.mixin.d.ts +9 -0
- package/lib/src/shared/logo-settings/components/LogoSettings.mixin.d.ts +1 -1
- package/lib/src/shared/logo-versions/LogoVersions.mixin.d.ts +6 -0
- package/lib/src/shared/models.d.ts +2 -0
- package/lib/src/shared/my-designs/MyDesigns.mixin.d.ts +6 -0
- package/lib/src/shared/my-uploads/MyMedia.mixin.d.ts +6 -0
- package/lib/src/shared/my-uploads/MyUploads.mixin.d.ts +6 -0
- package/lib/src/shared/page-settings/components/page-settings/PageSettings.mixin.d.ts +7 -3
- package/lib/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.d.ts +7 -3
- package/lib/src/shared/publish-brand-page-with-state/PublishBrandPageModalWithState.mixin.d.ts +1 -1
- package/lib/src/shared/style-settings/components/StyleSettings.mixin.d.ts +7 -1
- package/lib/src/shared/template-settings/components/TemplatesSettings.mixin.d.ts +10 -439
- package/lib/src/shared/template-settings/components/TemplatesSettings.mixin.js +2 -2
- package/lib/src/shared/template-settings/models.d.ts +1 -0
- package/lib/src/shared/template-settings/store/template-settings-store.d.ts +4 -0
- package/lib/src/shared/template-settings/store/template-settings-store.js +79 -11
- package/lib/src/shared/unsplash-library/UnsplashLibrary.mixin.d.ts +6 -0
- package/lib/src/utils/minify-brand-page-metadata.d.ts +0 -2
- package/lib/src/utils/minify-brand-page-metadata.js +1 -8
- package/package.json +1 -1
- package/src/brand-page/components/image-gallery/masonry/MasonryGallery.mixin.ts +1 -2
- package/src/brand-page/models/index.ts +4 -12
- package/src/brand-page/utils/__snapshots__/migration.util.test.ts.snap +3 -0
- package/src/brand-page/utils/__snapshots__/migration2.util.test.ts.snap +1 -0
- package/src/brand-page/utils/__snapshots__/model.util.test.ts.snap +2 -0
- package/src/brand-page/utils/personalisation.util.test.ts +35 -0
- package/src/brand-page/utils/personalisation.util.ts +119 -23
- package/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.mixin.ts +4 -0
- package/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.stories.ts +1 -0
- package/src/brand-page-maker/components/template-preview/TemplatePreview.mixin.ts +22 -8
- package/src/brand-page-maker/components/template-preview/TemplatePreview.vue +5 -10
- package/src/brand-page-maker/components/template-preview/TemplatePreviewAiBadge.vue +12 -0
- package/src/brand-page-maker/composables/ai-chat/useAiWebsiteBuilderChat.ts +0 -6
- package/src/brand-page-maker/stores/brandpage-container/brand-page-container-store.ts +5 -0
- package/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.ts +10 -0
- package/src/brand-page-maker/stores/ui/ui-store.ts +16 -0
- package/src/clients/design-template-client.ts +3 -0
- package/src/clients/models.ts +2 -0
- package/src/metadata-builder/builders/footer-builder.test.ts +0 -298
- package/src/metadata-builder/builders/footer-builder.ts +65 -56
- package/src/metadata-builder/builders/section-builders/image-gallery-builder.ts +88 -62
- package/src/metadata-builder/builders/section-builders/images-section-builder.ts +129 -66
- package/src/metadata-builder/builders/section-builders/shapes-section-builder.ts +160 -105
- package/src/metadata-builder/builders/section-builders/social-links-builder.ts +20 -65
- package/src/metadata-builder/builders/section-builders/testimonial-section-builder.ts +146 -83
- package/src/metadata-builder/builders/section-builders/text-section-builder.ts +122 -70
- package/src/metadata-builder/parsers/ai-toolcall-parser.ts +4 -13
- package/src/metadata-builder/parsers/section-tool-arguments.ts +48 -66
- package/src/shared/models.ts +6 -0
- package/src/shared/template-settings/components/TemplatesSettings.mixin.ts +2 -2
- package/src/shared/template-settings/models.ts +1 -0
- package/src/shared/template-settings/store/template-settings-store.ts +105 -18
- package/src/utils/minify-brand-page-metadata.ts +2 -14
- package/lib/src/metadata-builder/builders/item-id-utils.d.ts +0 -54
- package/lib/src/metadata-builder/builders/item-id-utils.js +0 -96
- package/src/metadata-builder/builders/item-id-utils.test.ts +0 -184
- package/src/metadata-builder/builders/item-id-utils.ts +0 -117
|
@@ -25,445 +25,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
25
25
|
created: Date;
|
|
26
26
|
name: string;
|
|
27
27
|
}[]>;
|
|
28
|
-
|
|
29
|
-
contentKey: string;
|
|
30
|
-
userPersonalisation: {
|
|
31
|
-
profileSection: {
|
|
32
|
-
title?: string | undefined;
|
|
33
|
-
name?: string | undefined;
|
|
34
|
-
url?: string | undefined;
|
|
35
|
-
description?: string | undefined;
|
|
36
|
-
descriptionShort?: string | undefined;
|
|
37
|
-
ctaTitle?: string | undefined;
|
|
38
|
-
imageSearchTerms?: string[] | undefined;
|
|
39
|
-
imageUrls?: {
|
|
40
|
-
imageUrl: string;
|
|
41
|
-
trackingUrl: string;
|
|
42
|
-
}[] | undefined;
|
|
43
|
-
shapeSearchTerms?: string[] | undefined;
|
|
44
|
-
mainShapesCollection?: {
|
|
45
|
-
tall: {
|
|
46
|
-
token: string;
|
|
47
|
-
url: string;
|
|
48
|
-
categories: string[];
|
|
49
|
-
tags: string[];
|
|
50
|
-
enabled: boolean;
|
|
51
|
-
keepColor: boolean;
|
|
52
|
-
enabledToAdmin: boolean;
|
|
53
|
-
}[];
|
|
54
|
-
square: {
|
|
55
|
-
token: string;
|
|
56
|
-
url: string;
|
|
57
|
-
categories: string[];
|
|
58
|
-
tags: string[];
|
|
59
|
-
enabled: boolean;
|
|
60
|
-
keepColor: boolean;
|
|
61
|
-
enabledToAdmin: boolean;
|
|
62
|
-
}[];
|
|
63
|
-
wide: {
|
|
64
|
-
token: string;
|
|
65
|
-
url: string;
|
|
66
|
-
categories: string[];
|
|
67
|
-
tags: string[];
|
|
68
|
-
enabled: boolean;
|
|
69
|
-
keepColor: boolean;
|
|
70
|
-
enabledToAdmin: boolean;
|
|
71
|
-
}[];
|
|
72
|
-
} | undefined;
|
|
73
|
-
shapes?: {
|
|
74
|
-
id: number;
|
|
75
|
-
token: string;
|
|
76
|
-
url: string;
|
|
77
|
-
filePath: string;
|
|
78
|
-
tags: string;
|
|
79
|
-
enabled: boolean;
|
|
80
|
-
keepColor: boolean;
|
|
81
|
-
createdBy: any;
|
|
82
|
-
createdOn: string;
|
|
83
|
-
version: number;
|
|
84
|
-
shapeCategoryId: number;
|
|
85
|
-
shapeCategory: any;
|
|
86
|
-
}[] | undefined;
|
|
87
|
-
items?: {
|
|
88
|
-
itemTitle: string;
|
|
89
|
-
itemDescription: string;
|
|
90
|
-
itemDescriptionShort: string;
|
|
91
|
-
}[] | undefined;
|
|
92
|
-
};
|
|
93
|
-
aboutSection: {
|
|
94
|
-
title?: string | undefined;
|
|
95
|
-
name?: string | undefined;
|
|
96
|
-
url?: string | undefined;
|
|
97
|
-
description?: string | undefined;
|
|
98
|
-
descriptionShort?: string | undefined;
|
|
99
|
-
ctaTitle?: string | undefined;
|
|
100
|
-
imageSearchTerms?: string[] | undefined;
|
|
101
|
-
imageUrls?: {
|
|
102
|
-
imageUrl: string;
|
|
103
|
-
trackingUrl: string;
|
|
104
|
-
}[] | undefined;
|
|
105
|
-
shapeSearchTerms?: string[] | undefined;
|
|
106
|
-
mainShapesCollection?: {
|
|
107
|
-
tall: {
|
|
108
|
-
token: string;
|
|
109
|
-
url: string;
|
|
110
|
-
categories: string[];
|
|
111
|
-
tags: string[];
|
|
112
|
-
enabled: boolean;
|
|
113
|
-
keepColor: boolean;
|
|
114
|
-
enabledToAdmin: boolean;
|
|
115
|
-
}[];
|
|
116
|
-
square: {
|
|
117
|
-
token: string;
|
|
118
|
-
url: string;
|
|
119
|
-
categories: string[];
|
|
120
|
-
tags: string[];
|
|
121
|
-
enabled: boolean;
|
|
122
|
-
keepColor: boolean;
|
|
123
|
-
enabledToAdmin: boolean;
|
|
124
|
-
}[];
|
|
125
|
-
wide: {
|
|
126
|
-
token: string;
|
|
127
|
-
url: string;
|
|
128
|
-
categories: string[];
|
|
129
|
-
tags: string[];
|
|
130
|
-
enabled: boolean;
|
|
131
|
-
keepColor: boolean;
|
|
132
|
-
enabledToAdmin: boolean;
|
|
133
|
-
}[];
|
|
134
|
-
} | undefined;
|
|
135
|
-
shapes?: {
|
|
136
|
-
id: number;
|
|
137
|
-
token: string;
|
|
138
|
-
url: string;
|
|
139
|
-
filePath: string;
|
|
140
|
-
tags: string;
|
|
141
|
-
enabled: boolean;
|
|
142
|
-
keepColor: boolean;
|
|
143
|
-
createdBy: any;
|
|
144
|
-
createdOn: string;
|
|
145
|
-
version: number;
|
|
146
|
-
shapeCategoryId: number;
|
|
147
|
-
shapeCategory: any;
|
|
148
|
-
}[] | undefined;
|
|
149
|
-
items?: {
|
|
150
|
-
itemTitle: string;
|
|
151
|
-
itemDescription: string;
|
|
152
|
-
itemDescriptionShort: string;
|
|
153
|
-
}[] | undefined;
|
|
154
|
-
};
|
|
155
|
-
informationSection: {
|
|
156
|
-
title?: string | undefined;
|
|
157
|
-
name?: string | undefined;
|
|
158
|
-
url?: string | undefined;
|
|
159
|
-
description?: string | undefined;
|
|
160
|
-
descriptionShort?: string | undefined;
|
|
161
|
-
ctaTitle?: string | undefined;
|
|
162
|
-
imageSearchTerms?: string[] | undefined;
|
|
163
|
-
imageUrls?: {
|
|
164
|
-
imageUrl: string;
|
|
165
|
-
trackingUrl: string;
|
|
166
|
-
}[] | undefined;
|
|
167
|
-
shapeSearchTerms?: string[] | undefined;
|
|
168
|
-
mainShapesCollection?: {
|
|
169
|
-
tall: {
|
|
170
|
-
token: string;
|
|
171
|
-
url: string;
|
|
172
|
-
categories: string[];
|
|
173
|
-
tags: string[];
|
|
174
|
-
enabled: boolean;
|
|
175
|
-
keepColor: boolean;
|
|
176
|
-
enabledToAdmin: boolean;
|
|
177
|
-
}[];
|
|
178
|
-
square: {
|
|
179
|
-
token: string;
|
|
180
|
-
url: string;
|
|
181
|
-
categories: string[];
|
|
182
|
-
tags: string[];
|
|
183
|
-
enabled: boolean;
|
|
184
|
-
keepColor: boolean;
|
|
185
|
-
enabledToAdmin: boolean;
|
|
186
|
-
}[];
|
|
187
|
-
wide: {
|
|
188
|
-
token: string;
|
|
189
|
-
url: string;
|
|
190
|
-
categories: string[];
|
|
191
|
-
tags: string[];
|
|
192
|
-
enabled: boolean;
|
|
193
|
-
keepColor: boolean;
|
|
194
|
-
enabledToAdmin: boolean;
|
|
195
|
-
}[];
|
|
196
|
-
} | undefined;
|
|
197
|
-
shapes?: {
|
|
198
|
-
id: number;
|
|
199
|
-
token: string;
|
|
200
|
-
url: string;
|
|
201
|
-
filePath: string;
|
|
202
|
-
tags: string;
|
|
203
|
-
enabled: boolean;
|
|
204
|
-
keepColor: boolean;
|
|
205
|
-
createdBy: any;
|
|
206
|
-
createdOn: string;
|
|
207
|
-
version: number;
|
|
208
|
-
shapeCategoryId: number;
|
|
209
|
-
shapeCategory: any;
|
|
210
|
-
}[] | undefined;
|
|
211
|
-
items?: {
|
|
212
|
-
itemTitle: string;
|
|
213
|
-
itemDescription: string;
|
|
214
|
-
itemDescriptionShort: string;
|
|
215
|
-
}[] | undefined;
|
|
216
|
-
};
|
|
217
|
-
mediaSection: {
|
|
218
|
-
title?: string | undefined;
|
|
219
|
-
name?: string | undefined;
|
|
220
|
-
url?: string | undefined;
|
|
221
|
-
description?: string | undefined;
|
|
222
|
-
descriptionShort?: string | undefined;
|
|
223
|
-
ctaTitle?: string | undefined;
|
|
224
|
-
imageSearchTerms?: string[] | undefined;
|
|
225
|
-
imageUrls?: {
|
|
226
|
-
imageUrl: string;
|
|
227
|
-
trackingUrl: string;
|
|
228
|
-
}[] | undefined;
|
|
229
|
-
shapeSearchTerms?: string[] | undefined;
|
|
230
|
-
mainShapesCollection?: {
|
|
231
|
-
tall: {
|
|
232
|
-
token: string;
|
|
233
|
-
url: string;
|
|
234
|
-
categories: string[];
|
|
235
|
-
tags: string[];
|
|
236
|
-
enabled: boolean;
|
|
237
|
-
keepColor: boolean;
|
|
238
|
-
enabledToAdmin: boolean;
|
|
239
|
-
}[];
|
|
240
|
-
square: {
|
|
241
|
-
token: string;
|
|
242
|
-
url: string;
|
|
243
|
-
categories: string[];
|
|
244
|
-
tags: string[];
|
|
245
|
-
enabled: boolean;
|
|
246
|
-
keepColor: boolean;
|
|
247
|
-
enabledToAdmin: boolean;
|
|
248
|
-
}[];
|
|
249
|
-
wide: {
|
|
250
|
-
token: string;
|
|
251
|
-
url: string;
|
|
252
|
-
categories: string[];
|
|
253
|
-
tags: string[];
|
|
254
|
-
enabled: boolean;
|
|
255
|
-
keepColor: boolean;
|
|
256
|
-
enabledToAdmin: boolean;
|
|
257
|
-
}[];
|
|
258
|
-
} | undefined;
|
|
259
|
-
shapes?: {
|
|
260
|
-
id: number;
|
|
261
|
-
token: string;
|
|
262
|
-
url: string;
|
|
263
|
-
filePath: string;
|
|
264
|
-
tags: string;
|
|
265
|
-
enabled: boolean;
|
|
266
|
-
keepColor: boolean;
|
|
267
|
-
createdBy: any;
|
|
268
|
-
createdOn: string;
|
|
269
|
-
version: number;
|
|
270
|
-
shapeCategoryId: number;
|
|
271
|
-
shapeCategory: any;
|
|
272
|
-
}[] | undefined;
|
|
273
|
-
items?: {
|
|
274
|
-
itemTitle: string;
|
|
275
|
-
itemDescription: string;
|
|
276
|
-
itemDescriptionShort: string;
|
|
277
|
-
}[] | undefined;
|
|
278
|
-
};
|
|
279
|
-
emailSection: {
|
|
280
|
-
title?: string | undefined;
|
|
281
|
-
name?: string | undefined;
|
|
282
|
-
url?: string | undefined;
|
|
283
|
-
description?: string | undefined;
|
|
284
|
-
descriptionShort?: string | undefined;
|
|
285
|
-
ctaTitle?: string | undefined;
|
|
286
|
-
imageSearchTerms?: string[] | undefined;
|
|
287
|
-
imageUrls?: {
|
|
288
|
-
imageUrl: string;
|
|
289
|
-
trackingUrl: string;
|
|
290
|
-
}[] | undefined;
|
|
291
|
-
shapeSearchTerms?: string[] | undefined;
|
|
292
|
-
mainShapesCollection?: {
|
|
293
|
-
tall: {
|
|
294
|
-
token: string;
|
|
295
|
-
url: string;
|
|
296
|
-
categories: string[];
|
|
297
|
-
tags: string[];
|
|
298
|
-
enabled: boolean;
|
|
299
|
-
keepColor: boolean;
|
|
300
|
-
enabledToAdmin: boolean;
|
|
301
|
-
}[];
|
|
302
|
-
square: {
|
|
303
|
-
token: string;
|
|
304
|
-
url: string;
|
|
305
|
-
categories: string[];
|
|
306
|
-
tags: string[];
|
|
307
|
-
enabled: boolean;
|
|
308
|
-
keepColor: boolean;
|
|
309
|
-
enabledToAdmin: boolean;
|
|
310
|
-
}[];
|
|
311
|
-
wide: {
|
|
312
|
-
token: string;
|
|
313
|
-
url: string;
|
|
314
|
-
categories: string[];
|
|
315
|
-
tags: string[];
|
|
316
|
-
enabled: boolean;
|
|
317
|
-
keepColor: boolean;
|
|
318
|
-
enabledToAdmin: boolean;
|
|
319
|
-
}[];
|
|
320
|
-
} | undefined;
|
|
321
|
-
shapes?: {
|
|
322
|
-
id: number;
|
|
323
|
-
token: string;
|
|
324
|
-
url: string;
|
|
325
|
-
filePath: string;
|
|
326
|
-
tags: string;
|
|
327
|
-
enabled: boolean;
|
|
328
|
-
keepColor: boolean;
|
|
329
|
-
createdBy: any;
|
|
330
|
-
createdOn: string;
|
|
331
|
-
version: number;
|
|
332
|
-
shapeCategoryId: number;
|
|
333
|
-
shapeCategory: any;
|
|
334
|
-
}[] | undefined;
|
|
335
|
-
items?: {
|
|
336
|
-
itemTitle: string;
|
|
337
|
-
itemDescription: string;
|
|
338
|
-
itemDescriptionShort: string;
|
|
339
|
-
}[] | undefined;
|
|
340
|
-
};
|
|
341
|
-
websiteSection: {
|
|
342
|
-
title?: string | undefined;
|
|
343
|
-
name?: string | undefined;
|
|
344
|
-
url?: string | undefined;
|
|
345
|
-
description?: string | undefined;
|
|
346
|
-
descriptionShort?: string | undefined;
|
|
347
|
-
ctaTitle?: string | undefined;
|
|
348
|
-
imageSearchTerms?: string[] | undefined;
|
|
349
|
-
imageUrls?: {
|
|
350
|
-
imageUrl: string;
|
|
351
|
-
trackingUrl: string;
|
|
352
|
-
}[] | undefined;
|
|
353
|
-
shapeSearchTerms?: string[] | undefined;
|
|
354
|
-
mainShapesCollection?: {
|
|
355
|
-
tall: {
|
|
356
|
-
token: string;
|
|
357
|
-
url: string;
|
|
358
|
-
categories: string[];
|
|
359
|
-
tags: string[];
|
|
360
|
-
enabled: boolean;
|
|
361
|
-
keepColor: boolean;
|
|
362
|
-
enabledToAdmin: boolean;
|
|
363
|
-
}[];
|
|
364
|
-
square: {
|
|
365
|
-
token: string;
|
|
366
|
-
url: string;
|
|
367
|
-
categories: string[];
|
|
368
|
-
tags: string[];
|
|
369
|
-
enabled: boolean;
|
|
370
|
-
keepColor: boolean;
|
|
371
|
-
enabledToAdmin: boolean;
|
|
372
|
-
}[];
|
|
373
|
-
wide: {
|
|
374
|
-
token: string;
|
|
375
|
-
url: string;
|
|
376
|
-
categories: string[];
|
|
377
|
-
tags: string[];
|
|
378
|
-
enabled: boolean;
|
|
379
|
-
keepColor: boolean;
|
|
380
|
-
enabledToAdmin: boolean;
|
|
381
|
-
}[];
|
|
382
|
-
} | undefined;
|
|
383
|
-
shapes?: {
|
|
384
|
-
id: number;
|
|
385
|
-
token: string;
|
|
386
|
-
url: string;
|
|
387
|
-
filePath: string;
|
|
388
|
-
tags: string;
|
|
389
|
-
enabled: boolean;
|
|
390
|
-
keepColor: boolean;
|
|
391
|
-
createdBy: any;
|
|
392
|
-
createdOn: string;
|
|
393
|
-
version: number;
|
|
394
|
-
shapeCategoryId: number;
|
|
395
|
-
shapeCategory: any;
|
|
396
|
-
}[] | undefined;
|
|
397
|
-
items?: {
|
|
398
|
-
itemTitle: string;
|
|
399
|
-
itemDescription: string;
|
|
400
|
-
itemDescriptionShort: string;
|
|
401
|
-
}[] | undefined;
|
|
402
|
-
};
|
|
403
|
-
phoneSection: {
|
|
404
|
-
title?: string | undefined;
|
|
405
|
-
name?: string | undefined;
|
|
406
|
-
url?: string | undefined;
|
|
407
|
-
description?: string | undefined;
|
|
408
|
-
descriptionShort?: string | undefined;
|
|
409
|
-
ctaTitle?: string | undefined;
|
|
410
|
-
imageSearchTerms?: string[] | undefined;
|
|
411
|
-
imageUrls?: {
|
|
412
|
-
imageUrl: string;
|
|
413
|
-
trackingUrl: string;
|
|
414
|
-
}[] | undefined;
|
|
415
|
-
shapeSearchTerms?: string[] | undefined;
|
|
416
|
-
mainShapesCollection?: {
|
|
417
|
-
tall: {
|
|
418
|
-
token: string;
|
|
419
|
-
url: string;
|
|
420
|
-
categories: string[];
|
|
421
|
-
tags: string[];
|
|
422
|
-
enabled: boolean;
|
|
423
|
-
keepColor: boolean;
|
|
424
|
-
enabledToAdmin: boolean;
|
|
425
|
-
}[];
|
|
426
|
-
square: {
|
|
427
|
-
token: string;
|
|
428
|
-
url: string;
|
|
429
|
-
categories: string[];
|
|
430
|
-
tags: string[];
|
|
431
|
-
enabled: boolean;
|
|
432
|
-
keepColor: boolean;
|
|
433
|
-
enabledToAdmin: boolean;
|
|
434
|
-
}[];
|
|
435
|
-
wide: {
|
|
436
|
-
token: string;
|
|
437
|
-
url: string;
|
|
438
|
-
categories: string[];
|
|
439
|
-
tags: string[];
|
|
440
|
-
enabled: boolean;
|
|
441
|
-
keepColor: boolean;
|
|
442
|
-
enabledToAdmin: boolean;
|
|
443
|
-
}[];
|
|
444
|
-
} | undefined;
|
|
445
|
-
shapes?: {
|
|
446
|
-
id: number;
|
|
447
|
-
token: string;
|
|
448
|
-
url: string;
|
|
449
|
-
filePath: string;
|
|
450
|
-
tags: string;
|
|
451
|
-
enabled: boolean;
|
|
452
|
-
keepColor: boolean;
|
|
453
|
-
createdBy: any;
|
|
454
|
-
createdOn: string;
|
|
455
|
-
version: number;
|
|
456
|
-
shapeCategoryId: number;
|
|
457
|
-
shapeCategory: any;
|
|
458
|
-
}[] | undefined;
|
|
459
|
-
items?: {
|
|
460
|
-
itemTitle: string;
|
|
461
|
-
itemDescription: string;
|
|
462
|
-
itemDescriptionShort: string;
|
|
463
|
-
}[] | undefined;
|
|
464
|
-
};
|
|
465
|
-
};
|
|
466
|
-
}[] | undefined>;
|
|
28
|
+
showAiTemplatesTab: import("vue").ComputedRef<boolean>;
|
|
467
29
|
templateSettingsStore: import("pinia").Store<"uiTemplateSettings", import("../store").TemplatesSettingState, {
|
|
468
30
|
renderAsImage(): boolean;
|
|
469
31
|
}, {
|
|
@@ -519,6 +81,9 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
519
81
|
initialSearchTerm: string;
|
|
520
82
|
onSearchTermChanged?: import("../store").OnSearchTermChangedCallback | undefined;
|
|
521
83
|
}): void;
|
|
84
|
+
setAiTemplateKeywords(payload: {
|
|
85
|
+
aiTemplateKeywords: string;
|
|
86
|
+
}): void;
|
|
522
87
|
notifySearchTermChanged(searchTerm: string | undefined): void;
|
|
523
88
|
clearTemplates(): void;
|
|
524
89
|
getTemplateByTemplateId(id: string): TemplateSettingsTemplate | undefined;
|
|
@@ -545,6 +110,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
545
110
|
setUserPersonalisationData({ personalisationData, }: {
|
|
546
111
|
personalisationData: import("../../../brand-page").UserPersonalisationContent[];
|
|
547
112
|
}): void;
|
|
113
|
+
setUserPromptContentKey({ userPromptContentKey, }: {
|
|
114
|
+
userPromptContentKey: string | undefined;
|
|
115
|
+
}): void;
|
|
116
|
+
setShowAiTemplatesTab({ showAiTemplatesTab, }: {
|
|
117
|
+
showAiTemplatesTab: boolean;
|
|
118
|
+
}): void;
|
|
548
119
|
onBackgroundChanged(): void;
|
|
549
120
|
onContentChanged(): void;
|
|
550
121
|
onStyleChanged(): void;
|
|
@@ -34,7 +34,7 @@ export default defineComponent({
|
|
|
34
34
|
selectedCategory: computed(() => templateSettingsStore.selectedCategory),
|
|
35
35
|
selectedTemplateId: computed(() => brandpageMakerStore.selectedTemplateId),
|
|
36
36
|
templateCategories: computed(() => templateSettingsStore.templateCategories),
|
|
37
|
-
|
|
37
|
+
showAiTemplatesTab: computed(() => uiStore.showAiTemplatesTab),
|
|
38
38
|
templateSettingsStore,
|
|
39
39
|
uiStore,
|
|
40
40
|
isDesignCom: computed(() => containerStore.isDesignCom),
|
|
@@ -105,7 +105,7 @@ export default defineComponent({
|
|
|
105
105
|
: `${pointerEventsClass}`;
|
|
106
106
|
},
|
|
107
107
|
visibleTabs() {
|
|
108
|
-
return this.
|
|
108
|
+
return this.showAiTemplatesTab
|
|
109
109
|
? this.tabs
|
|
110
110
|
: [...this.tabs].splice(0, this.tabs.findIndex((t) => t === templateSettingsTr(`headerAi`)));
|
|
111
111
|
},
|
|
@@ -5,6 +5,7 @@ export interface TemplateSettingsTemplate {
|
|
|
5
5
|
personalisationContentIndex?: number;
|
|
6
6
|
brandPageModel: BrandPageModel;
|
|
7
7
|
contentKey?: string;
|
|
8
|
+
usesUserPromptContentKey?: boolean;
|
|
8
9
|
previewImageUrl?: string;
|
|
9
10
|
}
|
|
10
11
|
export type DesignTemplateType = 'Facebook cover' | 'Brand Page' | 'Brand Site' | 'Brand Contact';
|
|
@@ -22,6 +22,7 @@ export interface TemplatesSettingState {
|
|
|
22
22
|
tabsWithTranslations: SelectedTabType[];
|
|
23
23
|
logoChangeWatcherInitialized: boolean;
|
|
24
24
|
initialSearchTerm: string | undefined;
|
|
25
|
+
aiTemplateKeywords: string | undefined;
|
|
25
26
|
onSearchTermChanged: OnSearchTermChangedCallback | undefined;
|
|
26
27
|
}
|
|
27
28
|
export declare const useUiTemplateSettingsStore: import("pinia").StoreDefinition<"uiTemplateSettings", TemplatesSettingState, {
|
|
@@ -79,6 +80,9 @@ export declare const useUiTemplateSettingsStore: import("pinia").StoreDefinition
|
|
|
79
80
|
initialSearchTerm: string;
|
|
80
81
|
onSearchTermChanged?: OnSearchTermChangedCallback;
|
|
81
82
|
}): void;
|
|
83
|
+
setAiTemplateKeywords(payload: {
|
|
84
|
+
aiTemplateKeywords: string;
|
|
85
|
+
}): void;
|
|
82
86
|
notifySearchTermChanged(searchTerm: string | undefined): void;
|
|
83
87
|
clearTemplates(): void;
|
|
84
88
|
getTemplateByTemplateId(id: string): TemplateSettingsTemplate | undefined;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { TEMPLATE_TABS } from '../models';
|
|
2
2
|
import * as DesignTemplateClient from '../../../clients/design-template-client';
|
|
3
3
|
import {} from '../../../clients/models';
|
|
4
|
-
import { BP_DEFAULT_TEMPLATE_TYPE_NAME, SIDE_BAR_TAB_NAMES, } from '@brand-page-maker/constants';
|
|
4
|
+
import { BP_DEFAULT_TEMPLATE_TYPE_NAME, BP_BRAND_SITE_TEMPLATE_TYPE_NAME, SIDE_BAR_TAB_NAMES, } from '@brand-page-maker/constants';
|
|
5
5
|
import { defineStore, storeToRefs } from 'pinia';
|
|
6
6
|
import { useBrandPageContainerStore, useBrandPageMakerStore, useBrandPageMakerUserStore, useLogoStore, useUiStore, } from '@brand-page-maker/stores';
|
|
7
7
|
import { useUiSideBarStore } from '../../side-bar/store';
|
|
@@ -9,9 +9,19 @@ import { BrandPageModel } from '@brand-page/models';
|
|
|
9
9
|
import { migrateBrandPageModel } from '@brand-page/utils';
|
|
10
10
|
import { getAiContentIndexByTemplateTokenAndNumberOfVariations } from '@brand-page-maker/utils/ai-content-selection.util';
|
|
11
11
|
import { useUiEditableLogoStore, useUiLogoSettingsStore, } from '../../logo-settings/store';
|
|
12
|
+
import { useEventTracker } from '@brand-page-maker/composables/useEventTracker';
|
|
12
13
|
import { templateSettingsTr, getCurrentLocale, } from '@src/composables/useTranslate';
|
|
13
14
|
import { watch } from 'vue';
|
|
14
15
|
export const DEFAULT_PAGE_SIZE = 6;
|
|
16
|
+
const POST_PURCHASE_PAGE_SECTION_BY_TAB = {
|
|
17
|
+
[TEMPLATE_TABS.all]: 'MakerPostPurchaseSidebarTemplatesAllTab',
|
|
18
|
+
[TEMPLATE_TABS.AI]: 'MakerPostPurchaseSidebarTemplatesAiTab',
|
|
19
|
+
[TEMPLATE_TABS.categories]: 'MakerPostPurchaseSidebarTemplatesCategoryTab',
|
|
20
|
+
};
|
|
21
|
+
const PRE_PURCHASE_PAGE_SECTION_BY_TAB = {
|
|
22
|
+
[TEMPLATE_TABS.all]: 'MakerPrePurchaseSidebarTemplatesAllTab',
|
|
23
|
+
[TEMPLATE_TABS.categories]: 'MakerPrePurchaseSidebarTemplatesCategoryTab',
|
|
24
|
+
};
|
|
15
25
|
const LOAD_PAGE_RETRY_DELAY = 250;
|
|
16
26
|
export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
17
27
|
state: () => {
|
|
@@ -47,6 +57,7 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
47
57
|
cachedTemplates: {},
|
|
48
58
|
logoChangeWatcherInitialized: false,
|
|
49
59
|
initialSearchTerm: undefined,
|
|
60
|
+
aiTemplateKeywords: undefined,
|
|
50
61
|
onSearchTermChanged: undefined,
|
|
51
62
|
};
|
|
52
63
|
},
|
|
@@ -187,27 +198,65 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
187
198
|
}
|
|
188
199
|
}
|
|
189
200
|
const editableLogoVariation = editableLogoStore.editableLogoVariations[logoVariation];
|
|
190
|
-
const
|
|
201
|
+
const isPrePurchase = brandPageContainerStore.isPrePurchase;
|
|
202
|
+
const isBrandSite = this.templateType === BP_BRAND_SITE_TEMPLATE_TYPE_NAME;
|
|
203
|
+
// Pre-purchase has no logo draft for logo-based recommendation, so fall back to the seeded
|
|
204
|
+
// search term (the keyword from the URL/cookie - never the business name) so the All tab
|
|
205
|
+
// stays relevant instead of generic (bp-5454).
|
|
206
|
+
const effectiveSearchTerm = !this.searchTerm &&
|
|
207
|
+
!this.selectedCategory &&
|
|
208
|
+
isPrePurchase &&
|
|
209
|
+
isBrandSite &&
|
|
210
|
+
this.selectedTab.key === TEMPLATE_TABS.all
|
|
211
|
+
? this.initialSearchTerm
|
|
212
|
+
: this.searchTerm;
|
|
213
|
+
const pageSection = isBrandSite
|
|
214
|
+
? (isPrePurchase
|
|
215
|
+
? PRE_PURCHASE_PAGE_SECTION_BY_TAB
|
|
216
|
+
: POST_PURCHASE_PAGE_SECTION_BY_TAB)[this.selectedTab.key]
|
|
217
|
+
: undefined;
|
|
218
|
+
const pageName = isBrandSite
|
|
219
|
+
? isPrePurchase
|
|
220
|
+
? 'maker-pre-purchase'
|
|
221
|
+
: 'maker'
|
|
222
|
+
: undefined;
|
|
223
|
+
const baseParams = {
|
|
191
224
|
page: pageNo,
|
|
192
|
-
pageSize: DEFAULT_PAGE_SIZE,
|
|
193
225
|
categoryName: this.selectedCategory,
|
|
194
|
-
searchTerm:
|
|
226
|
+
searchTerm: effectiveSearchTerm,
|
|
227
|
+
keywords: this.aiTemplateKeywords,
|
|
195
228
|
logoDraftToken: logoSettingsStore.selectedLogoImage.logoDraftToken,
|
|
196
229
|
logoVariation: logoSettingsStore.selectedLogoImage.logoVariation,
|
|
197
|
-
personalisable: this.selectedTab.key === TEMPLATE_TABS.AI,
|
|
198
230
|
selectedTemplateToken: designTemplateToken,
|
|
199
231
|
locale: currentLocale,
|
|
200
232
|
logoS3Token: !isByo ? editableLogoVariation.s3Token : undefined,
|
|
201
233
|
logoTemplateToken: isByo ? logoTemplateToken : undefined,
|
|
234
|
+
useLogoForRecommendedTemplates: isBrandSite && this.selectedTab.key === TEMPLATE_TABS.all,
|
|
235
|
+
pageSection,
|
|
236
|
+
pageName,
|
|
237
|
+
};
|
|
238
|
+
// AI templates are interleaved server-side for the Brand Site All tab
|
|
239
|
+
// (bp-5306); the frontend just renders the returned order.
|
|
240
|
+
const result = await designTemplateClient.getTemplateItemsByTemplateType(this.templateType, {
|
|
241
|
+
...baseParams,
|
|
242
|
+
pageSize: DEFAULT_PAGE_SIZE,
|
|
243
|
+
personalisable: this.selectedTab.key === TEMPLATE_TABS.AI,
|
|
202
244
|
});
|
|
203
245
|
if (!result) {
|
|
204
246
|
return;
|
|
205
247
|
}
|
|
206
248
|
this._setPageCount({ pageCount: result.pageCount });
|
|
249
|
+
if (pageNo === 1 &&
|
|
250
|
+
result.abTestValuesToBePushed &&
|
|
251
|
+
Object.keys(result.abTestValuesToBePushed).length > 0) {
|
|
252
|
+
const eventTracker = useEventTracker();
|
|
253
|
+
for (const [experimentName, experimentValue] of Object.entries(result.abTestValuesToBePushed)) {
|
|
254
|
+
eventTracker.sendExperimentStartedEvent(experimentName, experimentValue);
|
|
255
|
+
}
|
|
256
|
+
}
|
|
207
257
|
const templates = await Promise.all(result.paginatedItems.map(async (item) => {
|
|
208
258
|
try {
|
|
209
259
|
if (brandPageMakerUserStore.isAdmin) {
|
|
210
|
-
// Pre-purchase: full template with brandPageModel for live rendering
|
|
211
260
|
const template = await designTemplateClient.getTemplateByTemplateToken(item.designTemplateToken);
|
|
212
261
|
return this.safeMapToTemplateSettingsTemplate(template);
|
|
213
262
|
}
|
|
@@ -217,14 +266,24 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
217
266
|
if (uiStore.personalisationData?.length) {
|
|
218
267
|
personalisationContentIndex =
|
|
219
268
|
await getAiContentIndexByTemplateTokenAndNumberOfVariations(item.designTemplateToken, uiStore.personalisationData.length);
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
269
|
+
contentKey =
|
|
270
|
+
uiStore.personalisationData[personalisationContentIndex]
|
|
271
|
+
.contentKey;
|
|
272
|
+
}
|
|
273
|
+
else if (item.isPersonalisable) {
|
|
274
|
+
// Pre-purchase has no personalisationData; personalise AI
|
|
275
|
+
// template previews with the prompt content key (bp-5742).
|
|
276
|
+
contentKey = uiStore.userPromptContentKey;
|
|
224
277
|
}
|
|
225
278
|
return {
|
|
226
279
|
id: item.designTemplateToken,
|
|
280
|
+
isPersonalisable: item.isPersonalisable,
|
|
227
281
|
contentKey,
|
|
282
|
+
// A userPromptContentKey signals this design's real AI images live
|
|
283
|
+
// in the userPrompt bucket (post- or pre-purchase). The preview must
|
|
284
|
+
// then resolve via userPromptContentKey, not the regular bucket which
|
|
285
|
+
// holds placeholders post-purchase (bp-5454).
|
|
286
|
+
usesUserPromptContentKey: !!uiStore.userPromptContentKey,
|
|
228
287
|
previewImageUrl: item.previewImageUrl,
|
|
229
288
|
};
|
|
230
289
|
}
|
|
@@ -235,7 +294,13 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
235
294
|
}));
|
|
236
295
|
// Filter out null templates before adding
|
|
237
296
|
const validTemplates = templates.filter((t) => t !== null);
|
|
238
|
-
|
|
297
|
+
// The Categories tab must never surface AI templates or the AI badge
|
|
298
|
+
// (bp-5454 scenario 5). The badge is driven purely by isPersonalisable,
|
|
299
|
+
// so clear it for category results regardless of the template's catalog flag.
|
|
300
|
+
const displayTemplates = this.selectedTab.key === TEMPLATE_TABS.categories
|
|
301
|
+
? validTemplates.map((t) => ({ ...t, isPersonalisable: false }))
|
|
302
|
+
: validTemplates;
|
|
303
|
+
this._addTemplates({ templates: displayTemplates });
|
|
239
304
|
this._setPageNoLoaded({ pageNoLoaded: pageNo });
|
|
240
305
|
}
|
|
241
306
|
finally {
|
|
@@ -339,6 +404,9 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
339
404
|
this.initialSearchTerm = payload.initialSearchTerm;
|
|
340
405
|
this.onSearchTermChanged = payload.onSearchTermChanged;
|
|
341
406
|
},
|
|
407
|
+
setAiTemplateKeywords(payload) {
|
|
408
|
+
this.aiTemplateKeywords = payload.aiTemplateKeywords;
|
|
409
|
+
},
|
|
342
410
|
notifySearchTermChanged(searchTerm) {
|
|
343
411
|
this.onSearchTermChanged?.(searchTerm);
|
|
344
412
|
},
|