@designcrowd/library.brand-page 5.16.29-pre-temp-13 → 5.16.29
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-C5cvDYY0.js → CreatedOnBrandCrowd-de-de-BqxcoXxz.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-en-us-D0KCSK_6.js → CreatedOnBrandCrowd-en-us-SshxcaVK.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-es-es-BtlaguF9.js → CreatedOnBrandCrowd-es-es-CLtIWvg0.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-fr-RGdnURaa.js → CreatedOnBrandCrowd-fr-ca-CWYkoCNp.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-ca-RGdnURaa.js → CreatedOnBrandCrowd-fr-fr-CWYkoCNp.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-pt-BJwt5ATI.js → CreatedOnBrandCrowd-pt-br-CZRm-IwJ.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-br-BJwt5ATI.js → CreatedOnBrandCrowd-pt-pt-CZRm-IwJ.js} +1 -1
- package/lib/src/{CreatedOnDcom-de-de-LUA5Wvy5.js → CreatedOnDcom-de-de-sLxgILeR.js} +1 -1
- package/lib/src/{CreatedOnDcom-en-us-Dd1UPBVq.js → CreatedOnDcom-en-us-BxRGkmts.js} +1 -1
- package/lib/src/{CreatedOnDcom-es-es-CD923NVo.js → CreatedOnDcom-es-es-oXrblCQa.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-ca-C6Mc--2a.js → CreatedOnDcom-fr-ca-HlHhzmQV.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-fr-Ffrd6Erx.js → CreatedOnDcom-fr-fr-DzlyiYfW.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-br-BfoY5gWJ.js → CreatedOnDcom-pt-br-Bi2slHcB.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-pt-f0ywi387.js → CreatedOnDcom-pt-pt-CYatu2I5.js} +1 -1
- package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMakerTemplateSettings.mixin.js +5 -2
- package/lib/src/brand-page-maker/components/template-preview/TemplatePreview.mixin.js +4 -4
- package/lib/src/brand-page-maker/constants/template-constants.d.ts +2 -1
- package/lib/src/brand-page-maker/constants/template-constants.js +2 -1
- package/lib/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.js +0 -21
- package/lib/src/clients/design-template-client.d.ts +0 -2
- package/lib/src/clients/fabric-render-client.d.ts +0 -3
- package/lib/src/index.d.ts +1 -1
- package/lib/src/index.mjs +92 -92
- package/lib/src/{lib-BcLmSEKI.js → lib-COUy2gkw.js} +13475 -13552
- package/lib/src/lib.js +1 -1
- package/lib/src/shared/logo-settings/components/EditLogoSettings.mixin.d.ts +0 -10
- package/lib/src/shared/logo-settings/components/LogoSettings.mixin.d.ts +0 -10
- package/lib/src/shared/logo-settings/store/editable-logo-store.d.ts +0 -14
- package/lib/src/shared/logo-settings/store/editable-logo-store.js +0 -46
- package/lib/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.d.ts +0 -10
- package/lib/src/shared/template-settings/components/TemplatesSettings.mixin.d.ts +0 -1
- package/lib/src/shared/template-settings/components/TemplatesSettings.mixin.js +0 -33
- package/lib/src/shared/template-settings/store/template-settings-store.js +9 -57
- package/package.json +2 -2
- package/src/brand-page-maker/components/brand-page-maker/BrandPageMakerTemplateSettings.mixin.ts +6 -1
- package/src/brand-page-maker/components/template-preview/TemplatePreview.mixin.ts +4 -4
- package/src/brand-page-maker/constants/template-constants.ts +2 -1
- package/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.ts +0 -24
- package/src/clients/design-template-client.ts +0 -2
- package/src/clients/fabric-render-client.ts +0 -3
- package/src/lib.ts +0 -1
- package/src/shared/logo-settings/store/editable-logo-store.ts +0 -67
- package/src/shared/template-settings/components/TemplatesSettings.mixin.ts +0 -46
- package/src/shared/template-settings/store/template-settings-store.ts +10 -78
|
@@ -13,7 +13,6 @@ import {
|
|
|
13
13
|
VIEWPORTS,
|
|
14
14
|
type LogoContent,
|
|
15
15
|
LOGO_VARIATION,
|
|
16
|
-
type FabricLogoTheme,
|
|
17
16
|
} from '../../../brand-page';
|
|
18
17
|
import { PAGE_SECTIONS } from '../../../shared/page-settings/models';
|
|
19
18
|
|
|
@@ -102,9 +101,6 @@ export interface EditableLogoVariation {
|
|
|
102
101
|
variationType: string | undefined;
|
|
103
102
|
width: number;
|
|
104
103
|
height: number;
|
|
105
|
-
expiryDate?: string;
|
|
106
|
-
s3Token?: string;
|
|
107
|
-
logoTheme?: FabricLogoTheme;
|
|
108
104
|
}
|
|
109
105
|
|
|
110
106
|
export interface EditableLogoState {
|
|
@@ -137,9 +133,6 @@ export const useUiEditableLogoStore = defineStore('uiEditableLogo', {
|
|
|
137
133
|
variationType: undefined,
|
|
138
134
|
width: 0,
|
|
139
135
|
height: 0,
|
|
140
|
-
expiryDate: undefined,
|
|
141
|
-
s3Token: undefined,
|
|
142
|
-
logoTheme: undefined,
|
|
143
136
|
},
|
|
144
137
|
{
|
|
145
138
|
variationId: LOGO_VARIATION.LOGO_WITH_BACKGROUND,
|
|
@@ -148,9 +141,6 @@ export const useUiEditableLogoStore = defineStore('uiEditableLogo', {
|
|
|
148
141
|
variationType: undefined,
|
|
149
142
|
width: 0,
|
|
150
143
|
height: 0,
|
|
151
|
-
expiryDate: undefined,
|
|
152
|
-
s3Token: undefined,
|
|
153
|
-
logoTheme: undefined,
|
|
154
144
|
},
|
|
155
145
|
{
|
|
156
146
|
variationId: LOGO_VARIATION.LOGO_ONLY_WITH_TRANSPARENT_BACKGROUND,
|
|
@@ -159,9 +149,6 @@ export const useUiEditableLogoStore = defineStore('uiEditableLogo', {
|
|
|
159
149
|
variationType: LOGO_VARIATION_TYPES.ICON_TRANSPARENT_BACKGROUND_ONLY,
|
|
160
150
|
width: 0,
|
|
161
151
|
height: 0,
|
|
162
|
-
expiryDate: undefined,
|
|
163
|
-
s3Token: undefined,
|
|
164
|
-
logoTheme: undefined,
|
|
165
152
|
},
|
|
166
153
|
{
|
|
167
154
|
variationId: LOGO_VARIATION.TEXT_ONLY_WITH_TRANSPARENT_BACKGROUND,
|
|
@@ -170,9 +157,6 @@ export const useUiEditableLogoStore = defineStore('uiEditableLogo', {
|
|
|
170
157
|
variationType: LOGO_VARIATION_TYPES.TEXT_TRANSPARENT_BACKGROUND_ONLY,
|
|
171
158
|
width: 0,
|
|
172
159
|
height: 0,
|
|
173
|
-
expiryDate: undefined,
|
|
174
|
-
s3Token: undefined,
|
|
175
|
-
logoTheme: undefined,
|
|
176
160
|
},
|
|
177
161
|
],
|
|
178
162
|
logoEdits: {
|
|
@@ -467,9 +451,6 @@ export const useUiEditableLogoStore = defineStore('uiEditableLogo', {
|
|
|
467
451
|
editableLogoVariation.base64 = result.base64;
|
|
468
452
|
editableLogoVariation.width = result.width;
|
|
469
453
|
editableLogoVariation.height = result.height;
|
|
470
|
-
editableLogoVariation.expiryDate = result.expiryDate;
|
|
471
|
-
editableLogoVariation.s3Token = result.s3Token;
|
|
472
|
-
editableLogoVariation.logoTheme = result.logoTheme;
|
|
473
454
|
|
|
474
455
|
return result;
|
|
475
456
|
},
|
|
@@ -501,53 +482,6 @@ export const useUiEditableLogoStore = defineStore('uiEditableLogo', {
|
|
|
501
482
|
}
|
|
502
483
|
},
|
|
503
484
|
|
|
504
|
-
isS3TokenExpired(expiryDate: string | undefined): boolean {
|
|
505
|
-
if (!expiryDate) {
|
|
506
|
-
return true;
|
|
507
|
-
}
|
|
508
|
-
|
|
509
|
-
const expiryTime = new Date(expiryDate).getTime();
|
|
510
|
-
const currentTime = Date.now();
|
|
511
|
-
|
|
512
|
-
// Add a 5-minute buffer to refresh before actual expiry
|
|
513
|
-
const bufferMs = 5 * 60 * 1000;
|
|
514
|
-
|
|
515
|
-
return currentTime >= expiryTime - bufferMs;
|
|
516
|
-
},
|
|
517
|
-
|
|
518
|
-
async refreshS3TokenIfExpiredAsync(
|
|
519
|
-
logoVariation: number,
|
|
520
|
-
): Promise<boolean> {
|
|
521
|
-
const editableLogoVariation = this.editableLogoVariations[logoVariation];
|
|
522
|
-
|
|
523
|
-
if (!editableLogoVariation) {
|
|
524
|
-
return false;
|
|
525
|
-
}
|
|
526
|
-
|
|
527
|
-
const isExpired = this.isS3TokenExpired(editableLogoVariation.expiryDate);
|
|
528
|
-
|
|
529
|
-
if (isExpired) {
|
|
530
|
-
const logoStore = useLogoStore();
|
|
531
|
-
|
|
532
|
-
// Only refresh if logo template asset is available
|
|
533
|
-
if (!logoStore.logoTemplateAsset?.token) {
|
|
534
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
535
|
-
console.warn(
|
|
536
|
-
'Cannot refresh expired S3 token: logo template asset not available',
|
|
537
|
-
);
|
|
538
|
-
}
|
|
539
|
-
|
|
540
|
-
return false;
|
|
541
|
-
}
|
|
542
|
-
|
|
543
|
-
await this.updateEditableLogoImageUrlAsync();
|
|
544
|
-
|
|
545
|
-
return true;
|
|
546
|
-
}
|
|
547
|
-
|
|
548
|
-
return false;
|
|
549
|
-
},
|
|
550
|
-
|
|
551
485
|
async postEditableLogoRequestAsync(payload: {
|
|
552
486
|
returnJson: boolean;
|
|
553
487
|
dimensionType: string;
|
|
@@ -558,7 +492,6 @@ export const useUiEditableLogoStore = defineStore('uiEditableLogo', {
|
|
|
558
492
|
|
|
559
493
|
const body: ModifyLogoDataRequest = {
|
|
560
494
|
returnJson: payload?.returnJson || false,
|
|
561
|
-
generateS3Url: true,
|
|
562
495
|
dimensionsType: payload?.dimensionType,
|
|
563
496
|
variation: payload?.variationType,
|
|
564
497
|
primaryText: payload?.defaultPrimaryText,
|
|
@@ -19,11 +19,6 @@ import {
|
|
|
19
19
|
import { templateSettingsTr } from '../../../composables/useTranslate';
|
|
20
20
|
|
|
21
21
|
import { useEventTracker } from '../../../brand-page-maker/composables/useEventTracker';
|
|
22
|
-
import {
|
|
23
|
-
useUiEditableLogoStore,
|
|
24
|
-
useUiLogoSettingsStore,
|
|
25
|
-
} from '../../logo-settings/store';
|
|
26
|
-
import { useLogoStore } from '../../../brand-page-maker/stores/logo-store';
|
|
27
22
|
|
|
28
23
|
export default defineComponent({
|
|
29
24
|
props: {
|
|
@@ -160,9 +155,6 @@ export default defineComponent({
|
|
|
160
155
|
},
|
|
161
156
|
},
|
|
162
157
|
async mounted() {
|
|
163
|
-
// Check and refresh S3 token if expired before loading templates
|
|
164
|
-
await this.checkAndRefreshS3TokenIfExpired();
|
|
165
|
-
|
|
166
158
|
// load templates on mounted if it is not initialised
|
|
167
159
|
if (!this.pageCount) {
|
|
168
160
|
await this.templateSettingsStore.loadPageNo({
|
|
@@ -174,44 +166,6 @@ export default defineComponent({
|
|
|
174
166
|
this.debounceOnSearch = debounce(this.setSearchText, 500);
|
|
175
167
|
},
|
|
176
168
|
methods: {
|
|
177
|
-
async checkAndRefreshS3TokenIfExpired() {
|
|
178
|
-
const brandPageMakerContainerStore = useBrandPageContainerStore();
|
|
179
|
-
const editableLogoStore = useUiEditableLogoStore();
|
|
180
|
-
const logoStore = useLogoStore();
|
|
181
|
-
const logoSettingsStore = useUiLogoSettingsStore();
|
|
182
|
-
|
|
183
|
-
// Only check for non-admin (pre-purchase) and non-BYO logos
|
|
184
|
-
if (brandPageMakerContainerStore.isAdmin) {
|
|
185
|
-
return;
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
const isByo = logoStore.logoTemplateAsset?.isByo ?? false;
|
|
189
|
-
|
|
190
|
-
if (isByo) {
|
|
191
|
-
return;
|
|
192
|
-
}
|
|
193
|
-
|
|
194
|
-
const logoVariation = logoSettingsStore.selectedLogoImage.logoVariation;
|
|
195
|
-
|
|
196
|
-
if (logoVariation === undefined) {
|
|
197
|
-
return;
|
|
198
|
-
}
|
|
199
|
-
|
|
200
|
-
try {
|
|
201
|
-
const wasRefreshed =
|
|
202
|
-
await editableLogoStore.refreshS3TokenIfExpiredAsync(logoVariation);
|
|
203
|
-
|
|
204
|
-
if (wasRefreshed && process.env.NODE_ENV !== 'production') {
|
|
205
|
-
console.log(
|
|
206
|
-
'S3 token was expired in TemplatesSettings and has been refreshed',
|
|
207
|
-
);
|
|
208
|
-
}
|
|
209
|
-
} catch (error) {
|
|
210
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
211
|
-
console.error('Error checking/refreshing S3 token:', error);
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
|
-
},
|
|
215
169
|
async onNextClicked() {
|
|
216
170
|
if (!this.isLoadMoreBtnEnabled) {
|
|
217
171
|
return;
|
|
@@ -21,17 +21,13 @@ import {
|
|
|
21
21
|
useBrandPageContainerStore,
|
|
22
22
|
useBrandPageMakerStore,
|
|
23
23
|
useBrandPageMakerUserStore,
|
|
24
|
-
useLogoStore,
|
|
25
24
|
useUiStore,
|
|
26
25
|
} from '../../../brand-page-maker/stores';
|
|
27
26
|
import { useUiSideBarStore } from '../../side-bar/store';
|
|
28
27
|
import { BrandPageModel } from '../../../brand-page/models';
|
|
29
28
|
import { migrateBrandPageModel } from '../../../brand-page/utils';
|
|
30
29
|
import { getAiContentIndexByTemplateTokenAndNumberOfVariations } from '../../../brand-page-maker/utils/ai-content-selection.util';
|
|
31
|
-
import {
|
|
32
|
-
useUiEditableLogoStore,
|
|
33
|
-
useUiLogoSettingsStore,
|
|
34
|
-
} from '../../logo-settings/store';
|
|
30
|
+
import { useUiLogoSettingsStore } from '../../logo-settings/store';
|
|
35
31
|
import {
|
|
36
32
|
templateSettingsTr,
|
|
37
33
|
getCurrentLocale,
|
|
@@ -70,7 +66,9 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
70
66
|
const brandPageMakerUserStore = useBrandPageMakerUserStore();
|
|
71
67
|
|
|
72
68
|
// Set renderAsImage to true if not admin AND not pre-purchase
|
|
73
|
-
const renderAsImage =
|
|
69
|
+
const renderAsImage =
|
|
70
|
+
!brandPageMakerUserStore.isAdmin &&
|
|
71
|
+
!brandPageContainerStore.isPrePurchase;
|
|
74
72
|
|
|
75
73
|
return {
|
|
76
74
|
isBusy: false,
|
|
@@ -235,8 +233,6 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
235
233
|
const brandPageContainerStore = useBrandPageContainerStore();
|
|
236
234
|
const brandPageMakerUserStore = useBrandPageMakerUserStore();
|
|
237
235
|
const logoSettingsStore = useUiLogoSettingsStore();
|
|
238
|
-
const logoStore = useLogoStore();
|
|
239
|
-
const editableLogoStore = useUiEditableLogoStore();
|
|
240
236
|
const designTemplateToken = brandPageContainerStore.designTemplateToken;
|
|
241
237
|
|
|
242
238
|
if (brandPageMakerStore.isInitialising) {
|
|
@@ -272,28 +268,6 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
272
268
|
|
|
273
269
|
const currentLocale = getCurrentLocale();
|
|
274
270
|
|
|
275
|
-
const isByo = logoStore.logoTemplateAsset?.isByo ?? false;
|
|
276
|
-
const logoTemplateToken =
|
|
277
|
-
logoStore.logoTemplateAsset?.token ?? undefined;
|
|
278
|
-
const logoVariation = logoSettingsStore.selectedLogoImage.logoVariation;
|
|
279
|
-
|
|
280
|
-
// Check if S3 token is expired and refresh if needed
|
|
281
|
-
if (!isByo) {
|
|
282
|
-
const wasRefreshed =
|
|
283
|
-
await editableLogoStore.refreshS3TokenIfExpiredAsync(logoVariation);
|
|
284
|
-
|
|
285
|
-
if (wasRefreshed) {
|
|
286
|
-
setTimeout(() => {
|
|
287
|
-
this.loadPageNo({ pageNo });
|
|
288
|
-
}, LOAD_PAGE_RETRY_DELAY);
|
|
289
|
-
|
|
290
|
-
return;
|
|
291
|
-
}
|
|
292
|
-
}
|
|
293
|
-
|
|
294
|
-
const editableLogoVariation =
|
|
295
|
-
editableLogoStore.editableLogoVariations[logoVariation];
|
|
296
|
-
|
|
297
271
|
const result =
|
|
298
272
|
await designTemplateClient.getTemplateItemsByTemplateType(
|
|
299
273
|
this.templateType,
|
|
@@ -308,8 +282,6 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
308
282
|
personalisable: this.selectedTab.key === TEMPLATE_TABS.AI,
|
|
309
283
|
selectedTemplateToken: designTemplateToken,
|
|
310
284
|
locale: currentLocale,
|
|
311
|
-
logoS3Token: !isByo ? editableLogoVariation.s3Token : undefined,
|
|
312
|
-
logoTemplateToken: isByo ? logoTemplateToken : undefined,
|
|
313
285
|
},
|
|
314
286
|
);
|
|
315
287
|
|
|
@@ -322,7 +294,10 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
322
294
|
const templates = await Promise.all(
|
|
323
295
|
result.paginatedItems.map(async (item) => {
|
|
324
296
|
try {
|
|
325
|
-
if (
|
|
297
|
+
if (
|
|
298
|
+
brandPageContainerStore.isPrePurchase ||
|
|
299
|
+
brandPageMakerUserStore.isAdmin
|
|
300
|
+
) {
|
|
326
301
|
// Pre-purchase: full template with brandPageModel for live rendering
|
|
327
302
|
const template =
|
|
328
303
|
await designTemplateClient.getTemplateByTemplateToken(
|
|
@@ -401,14 +376,6 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
401
376
|
templateId: payload.templateId,
|
|
402
377
|
forceApply: payload.forceApply,
|
|
403
378
|
});
|
|
404
|
-
|
|
405
|
-
if (payload.forceApply) {
|
|
406
|
-
await this._setTemplates({
|
|
407
|
-
templates: [],
|
|
408
|
-
});
|
|
409
|
-
await this._setPageNoLoaded({ pageNoLoaded: 0 });
|
|
410
|
-
await this.loadPageNo({ pageNo: 1 });
|
|
411
|
-
}
|
|
412
379
|
},
|
|
413
380
|
async onCategorySelected(payload: OnCategorySelectedPayload) {
|
|
414
381
|
await this._setTemplates({
|
|
@@ -492,12 +459,9 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
492
459
|
*/
|
|
493
460
|
setupLogoChangeWatcher() {
|
|
494
461
|
const logoSettingsStore = useUiLogoSettingsStore();
|
|
495
|
-
const
|
|
462
|
+
const brandPageContainerStore = useBrandPageContainerStore();
|
|
496
463
|
const brandPageMakerUserStore = useBrandPageMakerUserStore();
|
|
497
464
|
const { selectedLogoImage } = storeToRefs(logoSettingsStore);
|
|
498
|
-
const { editableLogoVariations } = storeToRefs(editableLogoStore);
|
|
499
|
-
|
|
500
|
-
let s3TokenDebounceTimer: ReturnType<typeof setTimeout> | null = null;
|
|
501
465
|
|
|
502
466
|
// Watch for changes to logoImage (token or variation changes)
|
|
503
467
|
watch(
|
|
@@ -514,6 +478,7 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
514
478
|
newLogoImage.logoVariation !== oldLogoImage.logoVariation;
|
|
515
479
|
|
|
516
480
|
if (
|
|
481
|
+
!brandPageContainerStore.isPrePurchase &&
|
|
517
482
|
!brandPageMakerUserStore.isAdmin &&
|
|
518
483
|
newLogoImage.logoDraftToken &&
|
|
519
484
|
hasLogoChanged
|
|
@@ -528,39 +493,6 @@ export const useUiTemplateSettingsStore = defineStore('uiTemplateSettings', {
|
|
|
528
493
|
},
|
|
529
494
|
{ deep: true },
|
|
530
495
|
);
|
|
531
|
-
|
|
532
|
-
// Watch for S3 token changes (when user edits logo colors, text, etc.)
|
|
533
|
-
// Debounced to avoid excessive reloads during rapid edits
|
|
534
|
-
watch(
|
|
535
|
-
() =>
|
|
536
|
-
editableLogoVariations.value[selectedLogoImage.value.logoVariation]
|
|
537
|
-
?.s3Token,
|
|
538
|
-
async (newS3Token, oldS3Token) => {
|
|
539
|
-
if (s3TokenDebounceTimer) {
|
|
540
|
-
clearTimeout(s3TokenDebounceTimer);
|
|
541
|
-
}
|
|
542
|
-
|
|
543
|
-
if (!oldS3Token) {
|
|
544
|
-
return;
|
|
545
|
-
}
|
|
546
|
-
|
|
547
|
-
if (newS3Token === oldS3Token) {
|
|
548
|
-
return;
|
|
549
|
-
}
|
|
550
|
-
|
|
551
|
-
if (brandPageMakerUserStore.isAdmin) {
|
|
552
|
-
return;
|
|
553
|
-
}
|
|
554
|
-
|
|
555
|
-
// Debounce the reload by 500ms to avoid rapid successive reloads
|
|
556
|
-
s3TokenDebounceTimer = setTimeout(async () => {
|
|
557
|
-
await this._setTemplates({ templates: [] });
|
|
558
|
-
await this._setPageNoLoaded({ pageNoLoaded: 0 });
|
|
559
|
-
await this._setPageNo({ pageNo: 1 });
|
|
560
|
-
await this.loadPageNo({ pageNo: 1 });
|
|
561
|
-
}, 500);
|
|
562
|
-
},
|
|
563
|
-
);
|
|
564
496
|
},
|
|
565
497
|
},
|
|
566
498
|
});
|