@designcrowd/library.brand-page 5.17.25-undo-21 → 5.17.25
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-Bze5WUip.js → CreatedOnBrandCrowd-de-de-9YvB5ocm.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-en-us-Dw5uSnX8.js → CreatedOnBrandCrowd-en-us-B8OpZpMP.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-es-es-Cz-oPdjt.js → CreatedOnBrandCrowd-es-es-D_d6SwvE.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-fr-zldLXw3G.js → CreatedOnBrandCrowd-fr-ca-CPqNeevd.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-ca-zldLXw3G.js → CreatedOnBrandCrowd-fr-fr-CPqNeevd.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-pt-64QJpEaD.js → CreatedOnBrandCrowd-pt-br-D0DpxtjY.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-br-64QJpEaD.js → CreatedOnBrandCrowd-pt-pt-D0DpxtjY.js} +1 -1
- package/lib/src/{CreatedOnDcom-de-de-8SXOvjEH.js → CreatedOnDcom-de-de-BLKiD1pl.js} +1 -1
- package/lib/src/{CreatedOnDcom-en-us-ClZBYY_t.js → CreatedOnDcom-en-us-DGNjFV5B.js} +1 -1
- package/lib/src/{CreatedOnDcom-es-es-xg4ZwvEb.js → CreatedOnDcom-es-es-C2IDMZZe.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-ca-4zo2gxc1.js → CreatedOnDcom-fr-ca-ZRxz3QKj.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-fr-Dw9Fuy7U.js → CreatedOnDcom-fr-fr-5bE7oSdF.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-br-Dbl0EWcU.js → CreatedOnDcom-pt-br-WCumEx63.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-pt-Bps73oQE.js → CreatedOnDcom-pt-pt-C8Hinnmg.js} +1 -1
- package/lib/src/brand-page-maker/components/action-bar/ActionBar.mixin.d.ts +2 -7
- package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.mixin.d.ts +2 -7
- package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.mixin.js +0 -10
- package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMakerTemplateSettings.mixin.d.ts +2 -7
- package/lib/src/brand-page-maker/components/brand-page-maker/__fixtures__/brand-page-examples.js +0 -1
- package/lib/src/brand-page-maker/components/brandpage-maker-page/BrandPageMakerPage.mixin.d.ts +2 -23
- package/lib/src/brand-page-maker/components/brandpage-settings/ReplaceImageSettingsForBrandPageSettings.mixin.d.ts +2 -7
- package/lib/src/brand-page-maker/components/quick-link-bar/QuickLinkBar.mixin.d.ts +0 -3
- package/lib/src/brand-page-maker/components/quick-link-bar/QuickLinkBar.mixin.js +0 -11
- package/lib/src/brand-page-maker/components/seo-settings/SeoPageSettings.mixin.d.ts +2 -7
- package/lib/src/brand-page-maker/components/seo-settings/UrlSettings.mixin.d.ts +2 -7
- package/lib/src/brand-page-maker/components/social-share/SocialShare.mixin.d.ts +2 -7
- package/lib/src/brand-page-maker/components/template-preview/TemplatePreview.mixin.d.ts +2 -7
- package/lib/src/brand-page-maker/composables/ai-chat/useAiWebsiteBuilderChat.js +0 -9
- package/lib/src/brand-page-maker/composables/rich-text-editor/useRichTextEditor.js +1 -17
- package/lib/src/brand-page-maker/composables/useEventTracker.d.ts +0 -20
- package/lib/src/brand-page-maker/composables/useEventTracker.js +0 -17
- package/lib/src/brand-page-maker/stores/ai-thread/ai-website-builder-thread-store.d.ts +1 -1
- package/lib/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.d.ts +2 -41
- package/lib/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.js +5 -247
- package/lib/src/brand-page-maker/stores/logo-store/logo-store.d.ts +0 -1
- package/lib/src/brand-page-maker/stores/user/user-store.js +0 -1
- package/lib/src/bundled-translations-Bu_5FO26.js +173 -0
- package/lib/src/bundles/bundled-translations.json +1 -3
- package/lib/src/constants/ui.d.ts +0 -1
- package/lib/src/css/library.brand-page-brandCrowd.min.css +17 -22
- package/lib/src/css/library.brand-page-brandPage.min.css +18 -22
- package/lib/src/css/library.brand-page-designCom.min.css +17 -22
- package/lib/src/css/library.brand-page-preview.min.css +17 -22
- package/lib/src/index.mjs +1 -1
- package/lib/src/{lib-BgvZxeSl.js → lib-BF9ONIgx.js} +23292 -23913
- package/lib/src/shared/content-settings/components/GenericTextInput.mixin.d.ts +1 -1
- package/lib/src/shared/content-settings/components/content-settings/ContentSettings.mixin.d.ts +2 -23
- package/lib/src/shared/content-settings/components/content-settings/ContentSettings.stories.js +0 -1
- package/lib/src/shared/content-settings/components/content-settings/ReplaceImageSettingsForContent.mixin.d.ts +2 -23
- package/lib/src/shared/content-settings/components/content-settings-item/ContentSettingsItem.mixin.d.ts +0 -16
- package/lib/src/shared/content-settings/components/content-settings-item/ContentSettingsItemField.mixin.d.ts +2 -7
- package/lib/src/shared/content-settings/components/draggable-item-list/DraggableItemList.mixin.d.ts +0 -3
- package/lib/src/shared/content-settings/components/draggable-item-list/DraggableItemList.mixin.js +2 -19
- package/lib/src/shared/content-settings/components/email-field/EmailField.mixin.d.ts +1 -1
- package/lib/src/shared/content-settings/components/form-fields-field/FormFieldsField.mixin.js +8 -18
- package/lib/src/shared/content-settings/components/radio-field/RadioField.mixin.d.ts +1 -1
- package/lib/src/shared/content-settings/components/tel-field/TelField.mixin.d.ts +1 -1
- package/lib/src/shared/content-settings/components/text-field/TextField.mixin.d.ts +1 -1
- package/lib/src/shared/content-settings/components/textarea-field/TextareaField.mixin.d.ts +1 -1
- package/lib/src/shared/content-settings/components/url-field/UrlField.mixin.d.ts +1 -1
- package/lib/src/shared/content-settings/components/youtube-video-field/YoutubeVideoField.mixin.d.ts +1 -1
- package/lib/src/shared/logo-settings/components/EditLogoSettings.mixin.d.ts +0 -18
- package/lib/src/shared/logo-settings/components/EditLogoSettings.mixin.js +0 -11
- package/lib/src/shared/logo-settings/components/LogoSettings.mixin.d.ts +2 -9
- package/lib/src/shared/logo-settings/store/editable-logo-store.d.ts +1 -9
- package/lib/src/shared/logo-settings/store/editable-logo-store.js +0 -33
- package/lib/src/shared/page-settings/components/page-settings/PageSettings.mixin.d.ts +2 -24
- package/lib/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.d.ts +2 -9
- package/lib/src/shared/publish-brand-page-with-state/PublishBrandPageModalWithState.mixin.d.ts +2 -23
- package/lib/src/shared/side-bar/components/SideBarTabButton.mixin.d.ts +0 -16
- package/lib/src/shared/style-settings/components/StyleSettings.mixin.d.ts +2 -23
- package/lib/src/shared/template-settings/components/TemplatesSettings.mixin.d.ts +0 -16
- package/package.json +1 -1
- package/src/brand-page/components/video/Video.vue +0 -2
- package/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.mixin.ts +0 -11
- package/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.vue +3 -2
- package/src/brand-page-maker/components/brand-page-maker/__fixtures__/brand-page-examples.ts +0 -1
- package/src/brand-page-maker/components/cookie-collection/CookieSettings.vue +17 -18
- package/src/brand-page-maker/components/quick-link-bar/QuickLinkBar.mixin.ts +0 -13
- package/src/brand-page-maker/components/quick-link-bar/QuickLinkBar.vue +4 -14
- package/src/brand-page-maker/components/quick-link-bar/i18n/quick-link-bar.json +1 -3
- package/src/brand-page-maker/components/save-contact/SaveContact.vue +19 -12
- package/src/brand-page-maker/composables/ai-chat/useAiWebsiteBuilderChat.ts +0 -10
- package/src/brand-page-maker/composables/rich-text-editor/useRichTextEditor.ts +1 -20
- package/src/brand-page-maker/composables/useEventTracker.ts +0 -29
- package/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.test.ts +0 -166
- package/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.ts +4 -287
- package/src/brand-page-maker/stores/logo-store/logo-store.ts +0 -5
- package/src/brand-page-maker/stores/user/user-store.ts +0 -1
- package/src/bundles/bundled-translations.json +1 -3
- package/src/constants/ui.ts +0 -1
- package/src/shared/content-settings/components/content-settings/ContentSettings.stories.ts +0 -1
- package/src/shared/content-settings/components/draggable-item-list/DraggableItemList.mixin.ts +2 -19
- package/src/shared/content-settings/components/draggable-item-list/DraggableItemList.vue +1 -1
- package/src/shared/content-settings/components/form-fields-field/FormFieldsField.mixin.ts +10 -26
- package/src/shared/content-settings/components/logo-selection-field/LogoSelection.vue +48 -63
- package/src/shared/content-settings/components/text-field/TextField.vue +0 -1
- package/src/shared/content-settings/components/text-image-field/TextImageField.vue +4 -33
- package/src/shared/logo-settings/components/EditLogoSettings.mixin.ts +0 -11
- package/src/shared/logo-settings/store/editable-logo-store.ts +1 -45
- package/lib/src/brand-page-maker/composables/useUndoRedoFlag.d.ts +0 -16
- package/lib/src/brand-page-maker/composables/useUndoRedoFlag.js +0 -22
- package/lib/src/brand-page-maker/stores/history/history-store.d.ts +0 -104
- package/lib/src/brand-page-maker/stores/history/history-store.js +0 -836
- package/lib/src/bundled-translations-CWHKs3in.js +0 -173
- package/lib/src/metadata-builder/builders/reorder-pages-builder.d.ts +0 -13
- package/lib/src/metadata-builder/builders/reorder-pages-builder.js +0 -49
- package/src/brand-page-maker/components/quick-link-bar/RedoButton.test.ts +0 -166
- package/src/brand-page-maker/components/quick-link-bar/RedoButton.vue +0 -66
- package/src/brand-page-maker/components/quick-link-bar/UndoButton.test.ts +0 -166
- package/src/brand-page-maker/components/quick-link-bar/UndoButton.vue +0 -66
- package/src/brand-page-maker/composables/useUndoRedoFlag.ts +0 -26
- package/src/brand-page-maker/stores/history/history-store.test.ts +0 -1246
- package/src/brand-page-maker/stores/history/history-store.ts +0 -1041
- package/src/metadata-builder/builders/reorder-pages-builder.ts +0 -80
package/lib/src/shared/publish-brand-page-with-state/PublishBrandPageModalWithState.mixin.d.ts
CHANGED
|
@@ -187,21 +187,16 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
187
187
|
hideChangeTemplateConfirmModal(): void;
|
|
188
188
|
onBackgroundChanged(): void;
|
|
189
189
|
onChangeTemplateConfirmModalCancel(): void;
|
|
190
|
-
onChangeTemplateConfirmModalConfirm():
|
|
190
|
+
onChangeTemplateConfirmModalConfirm(): void;
|
|
191
191
|
onContentChanged(): void;
|
|
192
192
|
onStyleChanged(): void;
|
|
193
|
-
onTemplateSelected(payload: import("@brand-page-maker/stores").OnTemplateSelectedPayload):
|
|
193
|
+
onTemplateSelected(payload: import("@brand-page-maker/stores").OnTemplateSelectedPayload): void;
|
|
194
194
|
setSelectedTabName(payload: any): void;
|
|
195
195
|
showNextNotificationMessage(): Promise<void>;
|
|
196
196
|
updateContent<TContent extends import("@brand-page/models").Content, P extends {
|
|
197
197
|
id: string;
|
|
198
198
|
content: TContent;
|
|
199
199
|
}>(payload: P): Promise<void>;
|
|
200
|
-
_captureTemplateSwitchIfEnabled(): void;
|
|
201
|
-
applyHistorySnapshot(snapshot: import("@brand-page/models").BrandPageModel, activePageId?: string | undefined): Promise<void>;
|
|
202
|
-
_syncLogoSettingsFromSnapshot(snapshot: import("@brand-page/models").BrandPageModel): void;
|
|
203
|
-
_navigateToActivePage(activePageId?: string | undefined): void;
|
|
204
|
-
_fallbackSidebarIfSelectedContentMissing(snapshot: import("@brand-page/models").BrandPageModel): void;
|
|
205
200
|
export(): import("@brand-page/models").BrandPageModel;
|
|
206
201
|
setBrandPageType({ brandPageType }: {
|
|
207
202
|
brandPageType: "default" | "brandSite" | "brandContact";
|
|
@@ -526,22 +521,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
526
521
|
}>;
|
|
527
522
|
eventTracker: {
|
|
528
523
|
sendShippingToggleEvent: (isEnabled: boolean) => void;
|
|
529
|
-
sendUndoEvent: (props: {
|
|
530
|
-
entries_count: number;
|
|
531
|
-
actor: string | undefined;
|
|
532
|
-
}) => void;
|
|
533
|
-
sendRedoEvent: (props: {
|
|
534
|
-
entries_count: number;
|
|
535
|
-
actor: string | undefined;
|
|
536
|
-
}) => void;
|
|
537
|
-
sendHistoryCappedEvent: (props: {
|
|
538
|
-
entries_count: number;
|
|
539
|
-
size_bytes: number;
|
|
540
|
-
}) => void;
|
|
541
|
-
sendHistoryOversizedEvent: (props: {
|
|
542
|
-
attempted_bytes: number;
|
|
543
|
-
source: string;
|
|
544
|
-
}) => void;
|
|
545
524
|
sendSaveContactEvent: () => void;
|
|
546
525
|
sendStartForFreeEvent: () => void;
|
|
547
526
|
sendFooterLinkClickEvent: (linkType: "watermark_logo" | "create_your_website") => void;
|
|
@@ -19,22 +19,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
19
19
|
isDesignCom: import("vue").ComputedRef<boolean>;
|
|
20
20
|
eventTracker: {
|
|
21
21
|
sendShippingToggleEvent: (isEnabled: boolean) => void;
|
|
22
|
-
sendUndoEvent: (props: {
|
|
23
|
-
entries_count: number;
|
|
24
|
-
actor: string | undefined;
|
|
25
|
-
}) => void;
|
|
26
|
-
sendRedoEvent: (props: {
|
|
27
|
-
entries_count: number;
|
|
28
|
-
actor: string | undefined;
|
|
29
|
-
}) => void;
|
|
30
|
-
sendHistoryCappedEvent: (props: {
|
|
31
|
-
entries_count: number;
|
|
32
|
-
size_bytes: number;
|
|
33
|
-
}) => void;
|
|
34
|
-
sendHistoryOversizedEvent: (props: {
|
|
35
|
-
attempted_bytes: number;
|
|
36
|
-
source: string;
|
|
37
|
-
}) => void;
|
|
38
22
|
sendSaveContactEvent: () => void;
|
|
39
23
|
sendStartForFreeEvent: () => void;
|
|
40
24
|
sendFooterLinkClickEvent: (linkType: "watermark_logo" | "create_your_website") => void;
|
|
@@ -565,21 +565,16 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
565
565
|
hideChangeTemplateConfirmModal(): void;
|
|
566
566
|
onBackgroundChanged(): void;
|
|
567
567
|
onChangeTemplateConfirmModalCancel(): void;
|
|
568
|
-
onChangeTemplateConfirmModalConfirm():
|
|
568
|
+
onChangeTemplateConfirmModalConfirm(): void;
|
|
569
569
|
onContentChanged(): void;
|
|
570
570
|
onStyleChanged(): void;
|
|
571
|
-
onTemplateSelected(payload: import("@brand-page-maker/stores").OnTemplateSelectedPayload):
|
|
571
|
+
onTemplateSelected(payload: import("@brand-page-maker/stores").OnTemplateSelectedPayload): void;
|
|
572
572
|
setSelectedTabName(payload: any): void;
|
|
573
573
|
showNextNotificationMessage(): Promise<void>;
|
|
574
574
|
updateContent<TContent extends import("@brand-page").Content, P extends {
|
|
575
575
|
id: string;
|
|
576
576
|
content: TContent;
|
|
577
577
|
}>(payload: P): Promise<void>;
|
|
578
|
-
_captureTemplateSwitchIfEnabled(): void;
|
|
579
|
-
applyHistorySnapshot(snapshot: import("@brand-page").BrandPageModel, activePageId?: string | undefined): Promise<void>;
|
|
580
|
-
_syncLogoSettingsFromSnapshot(snapshot: import("@brand-page").BrandPageModel): void;
|
|
581
|
-
_navigateToActivePage(activePageId?: string | undefined): void;
|
|
582
|
-
_fallbackSidebarIfSelectedContentMissing(snapshot: import("@brand-page").BrandPageModel): void;
|
|
583
578
|
export(): import("@brand-page").BrandPageModel;
|
|
584
579
|
setBrandPageType({ brandPageType }: {
|
|
585
580
|
brandPageType: "default" | "brandSite" | "brandContact";
|
|
@@ -942,22 +937,6 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
942
937
|
}>;
|
|
943
938
|
eventTracker: {
|
|
944
939
|
sendShippingToggleEvent: (isEnabled: boolean) => void;
|
|
945
|
-
sendUndoEvent: (props: {
|
|
946
|
-
entries_count: number;
|
|
947
|
-
actor: string | undefined;
|
|
948
|
-
}) => void;
|
|
949
|
-
sendRedoEvent: (props: {
|
|
950
|
-
entries_count: number;
|
|
951
|
-
actor: string | undefined;
|
|
952
|
-
}) => void;
|
|
953
|
-
sendHistoryCappedEvent: (props: {
|
|
954
|
-
entries_count: number;
|
|
955
|
-
size_bytes: number;
|
|
956
|
-
}) => void;
|
|
957
|
-
sendHistoryOversizedEvent: (props: {
|
|
958
|
-
attempted_bytes: number;
|
|
959
|
-
source: string;
|
|
960
|
-
}) => void;
|
|
961
940
|
sendSaveContactEvent: () => void;
|
|
962
941
|
sendStartForFreeEvent: () => void;
|
|
963
942
|
sendFooterLinkClickEvent: (linkType: "watermark_logo" | "create_your_website") => void;
|
|
@@ -565,22 +565,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
565
565
|
isDesignCom: import("vue").ComputedRef<boolean>;
|
|
566
566
|
eventTracker: {
|
|
567
567
|
sendShippingToggleEvent: (isEnabled: boolean) => void;
|
|
568
|
-
sendUndoEvent: (props: {
|
|
569
|
-
entries_count: number;
|
|
570
|
-
actor: string | undefined;
|
|
571
|
-
}) => void;
|
|
572
|
-
sendRedoEvent: (props: {
|
|
573
|
-
entries_count: number;
|
|
574
|
-
actor: string | undefined;
|
|
575
|
-
}) => void;
|
|
576
|
-
sendHistoryCappedEvent: (props: {
|
|
577
|
-
entries_count: number;
|
|
578
|
-
size_bytes: number;
|
|
579
|
-
}) => void;
|
|
580
|
-
sendHistoryOversizedEvent: (props: {
|
|
581
|
-
attempted_bytes: number;
|
|
582
|
-
source: string;
|
|
583
|
-
}) => void;
|
|
584
568
|
sendSaveContactEvent: () => void;
|
|
585
569
|
sendStartForFreeEvent: () => void;
|
|
586
570
|
sendFooterLinkClickEvent: (linkType: "watermark_logo" | "create_your_website") => void;
|
package/package.json
CHANGED
|
@@ -30,7 +30,6 @@
|
|
|
30
30
|
type="text/html"
|
|
31
31
|
:src="videoUrl"
|
|
32
32
|
frameborder="0"
|
|
33
|
-
referrerpolicy="strict-origin-when-cross-origin"
|
|
34
33
|
/>
|
|
35
34
|
</div>
|
|
36
35
|
<!-- -->
|
|
@@ -42,7 +41,6 @@
|
|
|
42
41
|
type="text/html"
|
|
43
42
|
:src="videoUrl"
|
|
44
43
|
frameborder="0"
|
|
45
|
-
referrerpolicy="strict-origin-when-cross-origin"
|
|
46
44
|
/>
|
|
47
45
|
</div>
|
|
48
46
|
<Placeholder
|
|
@@ -35,8 +35,6 @@ import {
|
|
|
35
35
|
useSnapshotStore,
|
|
36
36
|
useVideoStore,
|
|
37
37
|
} from '@brand-page-maker/stores';
|
|
38
|
-
import { useHistoryStore } from '@brand-page-maker/stores/history/history-store';
|
|
39
|
-
import { useUndoRedoFlag } from '@brand-page-maker/composables/useUndoRedoFlag';
|
|
40
38
|
import type { AdminPreviewLogoTemplateModel } from '@brand-page-maker/stores/admin-logo-settings';
|
|
41
39
|
import { useUiContentSettingsStore } from '@shared/content-settings/store';
|
|
42
40
|
import { useUiTemplateSettingsStore } from '@shared/template-settings/store';
|
|
@@ -285,15 +283,6 @@ export default defineComponent({
|
|
|
285
283
|
// Mark brand page as fully loaded
|
|
286
284
|
this.brandPageMakerStore.setIsBrandPageLoaded(true);
|
|
287
285
|
|
|
288
|
-
// Capture baseline for undo/redo when the feature is active for this
|
|
289
|
-
// session. `useUndoRedoFlag` requires both the LaunchDarkly feature
|
|
290
|
-
// (`userStore.features.canUseUndoRedo`) AND the maker being a brand-site
|
|
291
|
-
// — V1 scope is brand-site only; brand-page and brand-contact don't get
|
|
292
|
-
// undo/redo. See useUndoRedoFlag.ts for the rationale.
|
|
293
|
-
if (useUndoRedoFlag().value) {
|
|
294
|
-
useHistoryStore().captureBaseline();
|
|
295
|
-
}
|
|
296
|
-
|
|
297
286
|
this.$emit(EVENTS.Initialised);
|
|
298
287
|
},
|
|
299
288
|
mounted() {
|
|
@@ -23,6 +23,7 @@
|
|
|
23
23
|
>
|
|
24
24
|
<div class="tw-flex tw-flex-col tw-w-full tw-h-full">
|
|
25
25
|
<QuickLinkBar
|
|
26
|
+
v-if="isPublished && !isAdmin"
|
|
26
27
|
class="c-quick-link-bar"
|
|
27
28
|
:brand-page-base-url="brandPageBaseUrl"
|
|
28
29
|
:slug="brandPageSlug"
|
|
@@ -89,8 +90,8 @@
|
|
|
89
90
|
v-if="isBrandPageLoaded"
|
|
90
91
|
:is-mobile-device="isMobileDevice"
|
|
91
92
|
:is-design-com="isDesignCom"
|
|
92
|
-
:container="previewContainer"
|
|
93
93
|
:has-quick-links="isPublished"
|
|
94
|
+
:container="previewContainer"
|
|
94
95
|
>
|
|
95
96
|
<div ref="previewContent" class="tw-h-full">
|
|
96
97
|
<PreviewWithState :device-mode="deviceMode" />
|
|
@@ -125,9 +126,9 @@
|
|
|
125
126
|
</div>
|
|
126
127
|
|
|
127
128
|
<SideBar
|
|
129
|
+
:has-quick-links="isPublished"
|
|
128
130
|
:mobile-tab-name="SideBarTabNames.PREVIEW"
|
|
129
131
|
:is-mobile-screen-size="isMobileScreenSize"
|
|
130
|
-
:has-quick-links="isPublished"
|
|
131
132
|
>
|
|
132
133
|
<template #tab>
|
|
133
134
|
<component
|
|
@@ -20,14 +20,14 @@
|
|
|
20
20
|
</div>
|
|
21
21
|
<Toggle
|
|
22
22
|
id="show-cookie-banner"
|
|
23
|
-
:model-value="isToggled"
|
|
23
|
+
:model-value="data.isToggled"
|
|
24
24
|
class="tw-pointer-events-none tw-touch-none"
|
|
25
25
|
color="primary"
|
|
26
26
|
@update:model-value="onShowCookieBanner()"
|
|
27
27
|
/>
|
|
28
28
|
</div>
|
|
29
29
|
</div>
|
|
30
|
-
<div v-if="isToggled" class="tw-flex-none tw-mt-4">
|
|
30
|
+
<div v-if="data.isToggled" class="tw-flex-none tw-mt-4">
|
|
31
31
|
<div
|
|
32
32
|
class="tw-flex tw-items-center tw-justify-between tw-cursor-pointer"
|
|
33
33
|
@click="onShowPreviewCookieBanner"
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
</div>
|
|
42
42
|
<Toggle
|
|
43
43
|
id="show-preview-cookie-banner"
|
|
44
|
-
:model-value="isPreviewToggled"
|
|
44
|
+
:model-value="data.isPreviewToggled"
|
|
45
45
|
class="tw-pointer-events-none tw-touch-none"
|
|
46
46
|
color="primary"
|
|
47
47
|
@update:model-value="onShowPreviewCookieBanner()"
|
|
@@ -55,10 +55,10 @@
|
|
|
55
55
|
import { Toggle } from '@designcrowd/fe-shared-lib';
|
|
56
56
|
import { cookieSettingTr } from '@src/composables/useTranslate';
|
|
57
57
|
import type { CookieOptions } from '@brand-page/models';
|
|
58
|
-
import {
|
|
58
|
+
import { reactive, type PropType } from 'vue';
|
|
59
59
|
import { useBrandPageMakerStore } from '@brand-page-maker/stores';
|
|
60
60
|
|
|
61
|
-
defineProps({
|
|
61
|
+
const props = defineProps({
|
|
62
62
|
viewModel: {
|
|
63
63
|
type: Object as PropType<CookieOptions>,
|
|
64
64
|
required: true,
|
|
@@ -67,26 +67,25 @@ defineProps({
|
|
|
67
67
|
|
|
68
68
|
const brandPageMakerStore = useBrandPageMakerStore();
|
|
69
69
|
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
);
|
|
75
|
-
const isPreviewToggled = computed(
|
|
76
|
-
() => brandPageMakerStore.cookieOptions.isCookiePreviewEnabled,
|
|
77
|
-
);
|
|
70
|
+
const data = reactive({
|
|
71
|
+
isToggled: props.viewModel.isCookieEnabled,
|
|
72
|
+
isPreviewToggled: props.viewModel.isCookiePreviewEnabled,
|
|
73
|
+
});
|
|
78
74
|
|
|
79
75
|
const onShowCookieBanner = () => {
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
76
|
+
data.isToggled = !data.isToggled;
|
|
77
|
+
brandPageMakerStore.setCookieEnabled({
|
|
78
|
+
isCookieEnabled: data.isToggled,
|
|
79
|
+
});
|
|
80
|
+
data.isPreviewToggled = data.isToggled;
|
|
83
81
|
brandPageMakerStore.setCookiePreviewEnabled({
|
|
84
|
-
isCookiePreviewEnabled:
|
|
82
|
+
isCookiePreviewEnabled: data.isPreviewToggled,
|
|
85
83
|
});
|
|
86
84
|
};
|
|
87
85
|
const onShowPreviewCookieBanner = () => {
|
|
86
|
+
data.isPreviewToggled = !data.isPreviewToggled;
|
|
88
87
|
brandPageMakerStore.setCookiePreviewEnabled({
|
|
89
|
-
isCookiePreviewEnabled:
|
|
88
|
+
isCookiePreviewEnabled: data.isPreviewToggled,
|
|
90
89
|
});
|
|
91
90
|
};
|
|
92
91
|
</script>
|
|
@@ -4,7 +4,6 @@ import {
|
|
|
4
4
|
useBrandPageContainerStore,
|
|
5
5
|
useEventManagerStore,
|
|
6
6
|
} from '@brand-page-maker/stores';
|
|
7
|
-
import { useUndoRedoFlag } from '@brand-page-maker/composables/useUndoRedoFlag';
|
|
8
7
|
import { quickLinkBarTr } from '@src/composables/useTranslate';
|
|
9
8
|
|
|
10
9
|
export default defineComponent({
|
|
@@ -22,7 +21,6 @@ export default defineComponent({
|
|
|
22
21
|
return {
|
|
23
22
|
brandPageContainerStore: useBrandPageContainerStore(),
|
|
24
23
|
eventManagerStore: useEventManagerStore(),
|
|
25
|
-
undoRedoEnabled: useUndoRedoFlag(),
|
|
26
24
|
};
|
|
27
25
|
},
|
|
28
26
|
data() {
|
|
@@ -31,17 +29,6 @@ export default defineComponent({
|
|
|
31
29
|
};
|
|
32
30
|
},
|
|
33
31
|
computed: {
|
|
34
|
-
isPublished(): boolean {
|
|
35
|
-
return this.brandPageContainerStore.isPublished;
|
|
36
|
-
},
|
|
37
|
-
|
|
38
|
-
// Only render the bar when at least one inner cluster has something to
|
|
39
|
-
// show. Otherwise we'd render an empty white strip — e.g. on an
|
|
40
|
-
// unpublished page with the undo flag off.
|
|
41
|
-
shouldShowBar(): boolean {
|
|
42
|
-
return Boolean(this.undoRedoEnabled) || this.isPublished;
|
|
43
|
-
},
|
|
44
|
-
|
|
45
32
|
brandPageUrl(): string {
|
|
46
33
|
if (
|
|
47
34
|
this.brandPageContainerStore.isCustomDomainEnabled &&
|
|
@@ -1,17 +1,11 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div
|
|
3
|
-
v-if="shouldShowBar"
|
|
4
3
|
data-component="quick-link-bar"
|
|
5
4
|
class="c-quick-links tw-w-full tw-flex-none tw-bg-white md:tw-h-12 tw-border-b tw-border-grayscale-500 tw-px-2 lg:tw-px-4 tw-box-border tw-flex tw-items-center tw-text-grayscale-800 tw-fixed lg:tw-static"
|
|
6
5
|
>
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
<RedoButton />
|
|
11
|
-
</div>
|
|
12
|
-
|
|
13
|
-
<!-- Right cluster: URL label, link, copy button -->
|
|
14
|
-
<div v-if="isPublished" class="tw-flex tw-items-center tw-gap-2 tw-ml-auto">
|
|
6
|
+
<p
|
|
7
|
+
class="tw-flex tw-items-center tw-justify-between lg:tw-justify-center tw-w-full"
|
|
8
|
+
>
|
|
15
9
|
<strong class="tw-font-semibold tw-hidden xl:tw-inline-block">
|
|
16
10
|
{{ quickLinkBarTr('myWebPageLabel') }}
|
|
17
11
|
</strong>
|
|
@@ -33,7 +27,7 @@
|
|
|
33
27
|
}"
|
|
34
28
|
@on-click.stop="onCopyClick"
|
|
35
29
|
/>
|
|
36
|
-
</
|
|
30
|
+
</p>
|
|
37
31
|
<textarea ref="textarea" :value="brandPageUrl" class="tw-sr-only" />
|
|
38
32
|
</div>
|
|
39
33
|
</template>
|
|
@@ -41,14 +35,10 @@
|
|
|
41
35
|
import QuickLinkBarMixin from './QuickLinkBar.mixin.ts';
|
|
42
36
|
import { Button } from '@designcrowd/fe-shared-lib';
|
|
43
37
|
import { quickLinkBarTr } from '@src/composables/useTranslate';
|
|
44
|
-
import UndoButton from './UndoButton.vue';
|
|
45
|
-
import RedoButton from './RedoButton.vue';
|
|
46
38
|
|
|
47
39
|
export default {
|
|
48
40
|
components: {
|
|
49
41
|
Button,
|
|
50
|
-
UndoButton,
|
|
51
|
-
RedoButton,
|
|
52
42
|
},
|
|
53
43
|
mixins: [QuickLinkBarMixin],
|
|
54
44
|
setup(props, context) {
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
</div>
|
|
20
20
|
<Toggle
|
|
21
21
|
id="save-contact-enabled"
|
|
22
|
-
:model-value="
|
|
22
|
+
:model-value="data.isToggled"
|
|
23
23
|
color="primary"
|
|
24
24
|
@update:model-value="onSavingEnabled()"
|
|
25
25
|
/>
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
</div>
|
|
28
28
|
<div class="tw-flex-none tw-mt-4">
|
|
29
29
|
<div
|
|
30
|
-
v-if="!isAdmin && !isPrePurchase &&
|
|
30
|
+
v-if="!isAdmin && !isPrePurchase && data.isToggled"
|
|
31
31
|
class="tw-flex tw-items-center tw-justify-between tw-cursor-pointer tw-gap-1"
|
|
32
32
|
@click="onHideBranding"
|
|
33
33
|
>
|
|
@@ -62,7 +62,7 @@
|
|
|
62
62
|
</div>
|
|
63
63
|
<Toggle
|
|
64
64
|
id="show-preview-cookie-banner"
|
|
65
|
-
:model-value="hideBranding"
|
|
65
|
+
:model-value="data.hideBranding"
|
|
66
66
|
color="primary"
|
|
67
67
|
@update:model-value="onHideBranding()"
|
|
68
68
|
/>
|
|
@@ -78,7 +78,7 @@ import {
|
|
|
78
78
|
useBrandPageContainerStore,
|
|
79
79
|
} from '@brand-page-maker/stores';
|
|
80
80
|
import { saveContactSettingsTr } from '@src/composables/useTranslate';
|
|
81
|
-
import { computed } from 'vue';
|
|
81
|
+
import { computed, reactive } from 'vue';
|
|
82
82
|
import {
|
|
83
83
|
EVENTS,
|
|
84
84
|
useEventTracker,
|
|
@@ -107,6 +107,11 @@ const showBrandCrowdLogo = computed(
|
|
|
107
107
|
() => brandPageMakerStore.showBrandCrowdLogo,
|
|
108
108
|
);
|
|
109
109
|
|
|
110
|
+
const data = reactive({
|
|
111
|
+
isToggled: isSavingEnabled.value,
|
|
112
|
+
hideBranding: hideBranding.value,
|
|
113
|
+
});
|
|
114
|
+
|
|
110
115
|
const siteName = computed((): string => {
|
|
111
116
|
return props.isDesignCom ? 'Design.com' : 'BrandCrowd';
|
|
112
117
|
});
|
|
@@ -122,28 +127,30 @@ const hideBrandingTooltip = computed((): string => {
|
|
|
122
127
|
});
|
|
123
128
|
|
|
124
129
|
const onSavingEnabled = () => {
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
130
|
+
data.isToggled = !data.isToggled;
|
|
131
|
+
brandPageMakerStore.setSavingEnabled({
|
|
132
|
+
isSavingEnabled: data.isToggled,
|
|
133
|
+
});
|
|
128
134
|
eventTracker.sendWebsiteEvent({
|
|
129
135
|
eventName: EVENTS.WEBSITE_MAKER_DIGITAL_BUSINESS_CARDS_SAVE_CONTACT_TOGGLE,
|
|
130
136
|
eventProps: {
|
|
131
137
|
cta_location: UPGRADE_CTA_LOCATIONS.SAVE_CONTACT_SETTINGS,
|
|
132
|
-
toggle_value:
|
|
138
|
+
toggle_value: data.isToggled ? 'enabled' : 'disabled',
|
|
133
139
|
},
|
|
134
140
|
});
|
|
135
141
|
};
|
|
136
142
|
|
|
137
143
|
const onHideBranding = async () => {
|
|
138
144
|
if (!showBrandCrowdLogo.value) {
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
145
|
+
data.hideBranding = !data.hideBranding;
|
|
146
|
+
brandPageMakerStore.setHideBranding({
|
|
147
|
+
hideBranding: data.hideBranding,
|
|
148
|
+
});
|
|
142
149
|
eventTracker.sendWebsiteEvent({
|
|
143
150
|
eventName: EVENTS.WEBSITE_MAKER_DIGITAL_BUSINESS_CARDS_HIDE_POPUP,
|
|
144
151
|
eventProps: {
|
|
145
152
|
cta_location: UPGRADE_CTA_LOCATIONS.SAVE_CONTACT_SETTINGS,
|
|
146
|
-
toggle_value:
|
|
153
|
+
toggle_value: data.hideBranding ? 'enabled' : 'disabled',
|
|
147
154
|
},
|
|
148
155
|
});
|
|
149
156
|
} else {
|
|
@@ -14,8 +14,6 @@ import {
|
|
|
14
14
|
import { minifyBrandPageMetadata } from '../../../utils/minify-brand-page-metadata';
|
|
15
15
|
import { useSnapshotStore, useAiWebsiteBuilderThreadStore } from '../../stores';
|
|
16
16
|
import { useBrandPageMakerStore } from '../../stores';
|
|
17
|
-
import { useHistoryStore } from '../../stores/history/history-store';
|
|
18
|
-
import { useUndoRedoFlag } from '../useUndoRedoFlag';
|
|
19
17
|
import { useAiMetadataBuilder } from './useAiMetadataBuilder';
|
|
20
18
|
import { Logger } from '../../../metadata-builder/logger';
|
|
21
19
|
import type {
|
|
@@ -35,8 +33,6 @@ export function useAiWebsiteBuilderChat(): UseAiChatResult {
|
|
|
35
33
|
const aiThreadStore = useAiWebsiteBuilderThreadStore();
|
|
36
34
|
const snapshotStore = useSnapshotStore();
|
|
37
35
|
const brandPageMakerStore = useBrandPageMakerStore();
|
|
38
|
-
const historyStore = useHistoryStore();
|
|
39
|
-
const undoRedoEnabled = useUndoRedoFlag();
|
|
40
36
|
const aiMetadataBuilder = useAiMetadataBuilder(aiLogger);
|
|
41
37
|
|
|
42
38
|
const hasStoredMessages = aiThreadStore.messages.length > 0;
|
|
@@ -155,12 +151,6 @@ export function useAiWebsiteBuilderChat(): UseAiChatResult {
|
|
|
155
151
|
|
|
156
152
|
await nextTick();
|
|
157
153
|
|
|
158
|
-
// One history entry per AI prompt (US-E1). `captureAiChangeset` cancels
|
|
159
|
-
// the auto-watcher's pending flush so the apply doesn't double-capture.
|
|
160
|
-
if (undoRedoEnabled.value) {
|
|
161
|
-
historyStore.captureAiChangeset();
|
|
162
|
-
}
|
|
163
|
-
|
|
164
154
|
// Re-capture snapshot so subsequent messages reflect the updated page
|
|
165
155
|
await snapshotStore.refreshSnapshotAsync();
|
|
166
156
|
|
|
@@ -47,7 +47,6 @@ import {
|
|
|
47
47
|
backgroundColorConvertor,
|
|
48
48
|
} from '@brand-page-maker/convertors';
|
|
49
49
|
import { useUiContentSettingsStore } from '@shared/content-settings/store';
|
|
50
|
-
import { useHistoryStore } from '@brand-page-maker/stores/history/history-store';
|
|
51
50
|
import { AllSelection } from 'prosemirror-state';
|
|
52
51
|
import { MaxLength } from './extensions/MaxLength';
|
|
53
52
|
import { AutoLink } from './extensions/AutoLink';
|
|
@@ -457,16 +456,7 @@ export const useRichTextEditor = (
|
|
|
457
456
|
watch(
|
|
458
457
|
() => model.value,
|
|
459
458
|
(newValue) => {
|
|
460
|
-
|
|
461
|
-
// (history undo/redo, template switch, reorder). `!editor.isFocused`
|
|
462
|
-
// distinguishes "external mutation" from "user is typing in me" — the
|
|
463
|
-
// latter would wipe the user's cursor if we called setContent.
|
|
464
|
-
// `updateRichTextEditor.value` is retained as an explicit override for
|
|
465
|
-
// callers (reorder) that need to force a re-seed while focused.
|
|
466
|
-
const isExternalMutation =
|
|
467
|
-
updateRichTextEditor.value || !editor.isFocused;
|
|
468
|
-
|
|
469
|
-
if (isExternalMutation && editor.getHTML() !== newValue) {
|
|
459
|
+
if (updateRichTextEditor.value && editor.getHTML() !== newValue) {
|
|
470
460
|
editor.commands.setContent(newValue, false);
|
|
471
461
|
updateRichTextEditor.value = false;
|
|
472
462
|
//text style type is not switching when reordering
|
|
@@ -496,16 +486,7 @@ export const useRichTextEditor = (
|
|
|
496
486
|
emit('update:modelValue', sanitizedData.sanitizedHtml);
|
|
497
487
|
});
|
|
498
488
|
|
|
499
|
-
const historyStore = useHistoryStore();
|
|
500
|
-
|
|
501
489
|
editor.on('selectionUpdate', () => {
|
|
502
|
-
// Skip while a history snapshot is being applied — `setContent` fires
|
|
503
|
-
// selectionUpdate before the editor has fully rehydrated, which causes
|
|
504
|
-
// toolbar buttons (alignment, letter-spacing) to flash through bogus
|
|
505
|
-
// active states before settling. The editor emits a final selectionUpdate
|
|
506
|
-
// after apply completes, which lands the correct values (BP-5506).
|
|
507
|
-
if (historyStore.isApplyingSnapshot) return;
|
|
508
|
-
|
|
509
490
|
const textStyleAttributes = editor.getAttributes('textStyle');
|
|
510
491
|
const highlightAttributes = editor.getAttributes('highlight');
|
|
511
492
|
const focusedAlignment = editor.getAttributes(
|
|
@@ -73,10 +73,6 @@ export const EVENTS = {
|
|
|
73
73
|
'website_maker_digital_business_cards_hide_popup',
|
|
74
74
|
WEBSITE_MAKER_GETTY_VIDEO: 'website_maker_getty_video',
|
|
75
75
|
WEBSITE_MAKER_SHIPPING_TOGGLE: 'website_maker_shipping_toggle',
|
|
76
|
-
WEBSITE_MAKER_UNDO: 'website_maker_undo',
|
|
77
|
-
WEBSITE_MAKER_REDO: 'website_maker_redo',
|
|
78
|
-
WEBSITE_MAKER_HISTORY_CAPPED: 'website_maker_history_capped',
|
|
79
|
-
WEBSITE_MAKER_HISTORY_OVERSIZED: 'website_maker_history_oversized',
|
|
80
76
|
};
|
|
81
77
|
|
|
82
78
|
export const SELECT_LOCATIONS = {
|
|
@@ -420,31 +416,6 @@ const useEventTracker = () => {
|
|
|
420
416
|
is_enabled: isEnabled,
|
|
421
417
|
});
|
|
422
418
|
},
|
|
423
|
-
// Undo / Redo (BP-5506)
|
|
424
|
-
sendUndoEvent: (props: {
|
|
425
|
-
entries_count: number;
|
|
426
|
-
actor: string | undefined;
|
|
427
|
-
}) => {
|
|
428
|
-
_publishEvent(EVENTS.WEBSITE_MAKER_UNDO, props);
|
|
429
|
-
},
|
|
430
|
-
sendRedoEvent: (props: {
|
|
431
|
-
entries_count: number;
|
|
432
|
-
actor: string | undefined;
|
|
433
|
-
}) => {
|
|
434
|
-
_publishEvent(EVENTS.WEBSITE_MAKER_REDO, props);
|
|
435
|
-
},
|
|
436
|
-
sendHistoryCappedEvent: (props: {
|
|
437
|
-
entries_count: number;
|
|
438
|
-
size_bytes: number;
|
|
439
|
-
}) => {
|
|
440
|
-
_publishEvent(EVENTS.WEBSITE_MAKER_HISTORY_CAPPED, props);
|
|
441
|
-
},
|
|
442
|
-
sendHistoryOversizedEvent: (props: {
|
|
443
|
-
attempted_bytes: number;
|
|
444
|
-
source: string;
|
|
445
|
-
}) => {
|
|
446
|
-
_publishEvent(EVENTS.WEBSITE_MAKER_HISTORY_OVERSIZED, props);
|
|
447
|
-
},
|
|
448
419
|
};
|
|
449
420
|
};
|
|
450
421
|
|