@designcrowd/library.brand-page 5.15.12-links-5 → 5.15.12
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-DazZ4Qgr.js → CreatedOnBrandCrowd-de-de-DFKc_so0.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-en-us-CF0GJ71c.js → CreatedOnBrandCrowd-en-us-40QRcYUX.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-es-es-DO_Cew4_.js → CreatedOnBrandCrowd-es-es-DMfH3fRr.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-fr-Cs0MdJwA.js → CreatedOnBrandCrowd-fr-ca-DbNQrijo.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-ca-Cs0MdJwA.js → CreatedOnBrandCrowd-fr-fr-DbNQrijo.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-pt-BIAeBwCX.js → CreatedOnBrandCrowd-pt-br-V3Xcyi3r.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-br-BIAeBwCX.js → CreatedOnBrandCrowd-pt-pt-V3Xcyi3r.js} +1 -1
- package/lib/src/{CreatedOnDcom-de-de-D8C8HnAw.js → CreatedOnDcom-de-de-DpegN5_e.js} +1 -1
- package/lib/src/{CreatedOnDcom-en-us-CoPlypSH.js → CreatedOnDcom-en-us-ByiQFMkC.js} +1 -1
- package/lib/src/{CreatedOnDcom-es-es-Bm7AR2BF.js → CreatedOnDcom-es-es-5eBXXPKs.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-ca-dkWSvU96.js → CreatedOnDcom-fr-ca-DRMV4ACI.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-fr-BL5BtwPM.js → CreatedOnDcom-fr-fr-CQrrHapF.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-br-DT3geYs7.js → CreatedOnDcom-pt-br-8bqzVFM8.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-pt-CEfbtvO_.js → CreatedOnDcom-pt-pt-Dgv_C7cs.js} +1 -1
- package/lib/src/brand-page/components/icon/Icon.mixin.d.ts +0 -4
- package/lib/src/brand-page/components/icon/Icon.mixin.js +0 -8
- package/lib/src/brand-page/components/social-links/SocialLinksItems.mixin.d.ts +70 -0
- package/lib/src/brand-page/components/social-links/SocialLinksItems.mixin.js +45 -0
- package/lib/src/brand-page/models/index.d.ts +0 -1
- package/lib/src/brand-page/models/index.js +0 -2
- package/lib/src/brand-page/utils/logo.util.d.ts +0 -19
- package/lib/src/brand-page/utils/logo.util.js +1 -79
- package/lib/src/brand-page/utils/migration/migration-07.js +17 -7
- package/lib/src/brand-page/utils/migration.util.js +0 -6
- package/lib/src/brand-page/utils/view-model.util.js +0 -1
- package/lib/src/brand-page/view-models.d.ts +0 -1
- package/lib/src/brand-page-maker/components/action-bar/ActionBar.mixin.d.ts +0 -6
- package/lib/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.mixin.d.ts +2 -6
- 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 +0 -6
- package/lib/src/brand-page-maker/components/brand-page-maker/__fixtures__/brand-page-examples.js +0 -4
- package/lib/src/brand-page-maker/components/brandpage-maker-page/BrandPageMakerPage.mixin.d.ts +2 -6
- package/lib/src/brand-page-maker/components/brandpage-settings/ReplaceImageSettingsForBrandPageSettings.mixin.d.ts +0 -6
- package/lib/src/brand-page-maker/components/google-analytics/GoogleAnalytics.mixin.d.ts +158 -0
- package/lib/src/brand-page-maker/components/google-analytics/GoogleAnalytics.mixin.js +92 -0
- package/lib/src/brand-page-maker/components/quick-link-bar/QuickLinkBar.mixin.d.ts +2 -0
- package/lib/src/brand-page-maker/components/seo-settings/SeoPageSettings.mixin.d.ts +3 -7
- package/lib/src/brand-page-maker/components/seo-settings/UrlSettings.mixin.d.ts +2 -6
- package/lib/src/brand-page-maker/components/seo-settings/UseExistingDomainModal.mixin.d.ts +2 -0
- package/lib/src/brand-page-maker/components/social-share/SocialShare.mixin.d.ts +0 -6
- package/lib/src/brand-page-maker/components/template-preview/TemplatePreview.mixin.d.ts +0 -6
- package/lib/src/brand-page-maker/components/upgrade-to-premium-button/UpgradeToPremiumButton.mixin.d.ts +2 -0
- package/lib/src/brand-page-maker/composables/useEventTracker.d.ts +0 -1
- package/lib/src/brand-page-maker/composables/useEventTracker.js +0 -1
- package/lib/src/brand-page-maker/stores/brandpage-container/brand-page-container-store.d.ts +3 -0
- package/lib/src/brand-page-maker/stores/brandpage-container/brand-page-container-store.js +2 -0
- package/lib/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.d.ts +0 -7
- package/lib/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.js +2 -19
- package/lib/src/brand-page-maker/stores/user/user-store.js +0 -2
- package/lib/src/bundled-translations-Gwpp-xB6.js +161 -0
- package/lib/src/bundled-translations.de-DE-CB4KkNf3.js +161 -0
- package/lib/src/bundled-translations.es-ES-27tfJoU5.js +161 -0
- package/lib/src/bundled-translations.fr-CA-SDhUJ5C0.js +161 -0
- package/lib/src/bundled-translations.fr-FR-_THRUXSu.js +161 -0
- package/lib/src/bundled-translations.pt-BR-Cet1bnj3.js +161 -0
- package/lib/src/bundled-translations.pt-PT-BWuPalqF.js +161 -0
- package/lib/src/bundles/bundled-translations.de-DE.json +3 -13
- package/lib/src/bundles/bundled-translations.es-ES.json +3 -13
- package/lib/src/bundles/bundled-translations.fr-CA.json +3 -13
- package/lib/src/bundles/bundled-translations.fr-FR.json +3 -13
- package/lib/src/bundles/bundled-translations.json +3 -13
- package/lib/src/bundles/bundled-translations.pt-BR.json +4 -14
- package/lib/src/bundles/bundled-translations.pt-PT.json +3 -13
- package/lib/src/clients/fabric-render-client.js +1 -1
- package/lib/src/constants/ui.d.ts +0 -2
- package/lib/src/css/library.brand-page-brandCrowd.min.css +11 -23
- package/lib/src/css/library.brand-page-brandPage.min.css +11 -23
- package/lib/src/css/library.brand-page-designCom.min.css +11 -23
- package/lib/src/css/library.brand-page-preview.min.css +11 -23
- package/lib/src/index.d.ts +1 -1
- package/lib/src/index.mjs +52 -53
- package/lib/src/{lib-DLM93SjQ.js → lib-CF7FYBeS.js} +23686 -23909
- package/lib/src/lib.js +1 -1
- package/lib/src/shared/content-settings/components/content-settings/ContentSettings.mixin.d.ts +0 -6
- package/lib/src/shared/content-settings/components/content-settings/ContentSettings.stories.js +0 -2
- package/lib/src/shared/content-settings/components/content-settings/ReplaceImageSettingsForContent.mixin.d.ts +0 -6
- package/lib/src/shared/content-settings/components/content-settings-item/ContentSettingsItemField.mixin.d.ts +0 -6
- package/lib/src/shared/content-settings/components/draggable-item-list/DraggableItemList.mixin.d.ts +0 -4
- package/lib/src/shared/content-settings/components/draggable-item-list/DraggableItemList.mixin.js +6 -31
- package/lib/src/shared/content-settings/components/payment-config-field/PaymentConfigField.mixin.d.ts +2 -0
- package/lib/src/shared/logo-settings/components/LogoSettings.mixin.d.ts +2 -6
- package/lib/src/shared/page-settings/components/page-settings/PageSettings.mixin.d.ts +2 -8
- package/lib/src/shared/page-settings/components/page-settings-section-styles/PageSettingsSectionStyles.mixin.d.ts +2 -6
- package/lib/src/shared/publish-brand-page-with-state/PublishBrandPageModalWithState.mixin.d.ts +2 -6
- package/lib/src/shared/side-bar/components/SideBar.mixin.d.ts +2 -0
- package/lib/src/shared/style-settings/components/StyleSettings.mixin.d.ts +2 -6
- package/package.json +1 -1
- package/src/brand-page/components/icon/Icon.mixin.ts +0 -8
- package/src/brand-page/components/icon/Icon.vue +0 -4
- package/src/brand-page/components/logo/LogoRender.vue +1 -2
- package/src/brand-page/components/social-links/SocialLinksItems.mixin.ts +48 -0
- package/src/brand-page/components/social-links/SocialLinksItems.vue +7 -42
- package/src/brand-page/models/index.ts +0 -4
- package/src/brand-page/utils/__snapshots__/migration.util.test.ts.snap +3 -6
- package/src/brand-page/utils/__snapshots__/migration2.util.test.ts.snap +0 -1
- package/src/brand-page/utils/__snapshots__/model.util.test.ts.snap +0 -2
- package/src/brand-page/utils/logo.util.ts +1 -130
- package/src/brand-page/utils/migration/migration-07.test.ts +0 -2
- package/src/brand-page/utils/migration/migration-07.ts +25 -8
- package/src/brand-page/utils/migration.util.ts +0 -6
- package/src/brand-page/utils/view-model.util.ts +0 -1
- package/src/brand-page/view-models.ts +0 -1
- package/src/brand-page-maker/components/brand-page-maker/BrandPageMaker.stories.ts +1 -0
- package/src/brand-page-maker/components/brand-page-maker/__fixtures__/brand-page-examples.ts +0 -4
- package/src/brand-page-maker/components/brandpage-settings/BrandPageSettings.vue +2 -14
- package/src/brand-page-maker/components/brandpage-settings/i18n/brand-page-settings.de-DE.json +1 -2
- package/src/brand-page-maker/components/brandpage-settings/i18n/brand-page-settings.es-ES.json +1 -2
- package/src/brand-page-maker/components/brandpage-settings/i18n/brand-page-settings.fr-CA.json +1 -2
- package/src/brand-page-maker/components/brandpage-settings/i18n/brand-page-settings.fr-FR.json +1 -2
- package/src/brand-page-maker/components/brandpage-settings/i18n/brand-page-settings.json +1 -2
- package/src/brand-page-maker/components/brandpage-settings/i18n/brand-page-settings.pt-BR.json +1 -2
- package/src/brand-page-maker/components/brandpage-settings/i18n/brand-page-settings.pt-PT.json +1 -2
- package/src/brand-page-maker/components/google-analytics/GoogleAnalytics.mixin.ts +96 -0
- package/src/brand-page-maker/components/google-analytics/GoogleAnalytics.vue +80 -292
- package/src/brand-page-maker/components/google-analytics/i18n/google-analytics.de-DE.json +2 -9
- package/src/brand-page-maker/components/google-analytics/i18n/google-analytics.es-ES.json +2 -9
- package/src/brand-page-maker/components/google-analytics/i18n/google-analytics.fr-CA.json +2 -9
- package/src/brand-page-maker/components/google-analytics/i18n/google-analytics.fr-FR.json +2 -9
- package/src/brand-page-maker/components/google-analytics/i18n/google-analytics.json +2 -9
- package/src/brand-page-maker/components/google-analytics/i18n/google-analytics.pt-BR.json +2 -9
- package/src/brand-page-maker/components/google-analytics/i18n/google-analytics.pt-PT.json +2 -9
- package/src/brand-page-maker/composables/useEventTracker.ts +0 -1
- package/src/brand-page-maker/stores/brandpage-container/brand-page-container-store.ts +3 -0
- package/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.ts +2 -31
- package/src/brand-page-maker/stores/user/user-store.ts +0 -2
- package/src/bundles/bundled-translations.de-DE.json +3 -13
- package/src/bundles/bundled-translations.es-ES.json +3 -13
- package/src/bundles/bundled-translations.fr-CA.json +3 -13
- package/src/bundles/bundled-translations.fr-FR.json +3 -13
- package/src/bundles/bundled-translations.json +3 -13
- package/src/bundles/bundled-translations.pt-BR.json +4 -14
- package/src/bundles/bundled-translations.pt-PT.json +3 -13
- package/src/clients/fabric-render-client.ts +1 -1
- package/src/constants/ui.ts +0 -2
- package/src/lib.ts +1 -4
- package/src/shared/common/i18n/common.de-DE.json +0 -1
- package/src/shared/common/i18n/common.es-ES.json +0 -1
- package/src/shared/common/i18n/common.fr-CA.json +0 -1
- package/src/shared/common/i18n/common.fr-FR.json +0 -1
- package/src/shared/common/i18n/common.json +0 -1
- package/src/shared/common/i18n/common.pt-BR.json +1 -2
- package/src/shared/common/i18n/common.pt-PT.json +0 -1
- package/src/shared/common/i18n/error.de-DE.json +0 -1
- package/src/shared/common/i18n/error.es-ES.json +0 -1
- package/src/shared/common/i18n/error.fr-CA.json +0 -1
- package/src/shared/common/i18n/error.fr-FR.json +0 -1
- package/src/shared/common/i18n/error.json +0 -1
- package/src/shared/common/i18n/error.pt-BR.json +0 -1
- package/src/shared/common/i18n/error.pt-PT.json +0 -1
- package/src/shared/content-settings/components/content-settings/ContentSettings.stories.ts +0 -2
- package/src/shared/content-settings/components/draggable-item-list/DraggableItemList.mixin.ts +7 -42
- package/src/shared/content-settings/components/draggable-item-list/DraggableItemList.vue +17 -32
- package/src/shared/content-settings/components/links-field/i18n/links-field.de-DE.json +1 -1
- package/src/shared/content-settings/components/links-field/i18n/links-field.es-ES.json +1 -1
- package/src/shared/content-settings/components/links-field/i18n/links-field.fr-CA.json +1 -1
- package/src/shared/content-settings/components/links-field/i18n/links-field.fr-FR.json +1 -1
- package/src/shared/content-settings/components/links-field/i18n/links-field.json +1 -1
- package/src/shared/content-settings/components/links-field/i18n/links-field.pt-BR.json +1 -1
- package/src/shared/content-settings/components/links-field/i18n/links-field.pt-PT.json +1 -1
- package/lib/src/brand-page/utils/migration/migration-08.d.ts +0 -5
- package/lib/src/brand-page/utils/migration/migration-08.js +0 -71
- package/lib/src/bundled-translations-GvfzVUdP.js +0 -161
- package/lib/src/bundled-translations.de-DE-FQmyDyq1.js +0 -161
- package/lib/src/bundled-translations.es-ES-nP95fALh.js +0 -161
- package/lib/src/bundled-translations.fr-CA-CUA6V4II.js +0 -161
- package/lib/src/bundled-translations.fr-FR-BP-C-2e4.js +0 -161
- package/lib/src/bundled-translations.pt-BR-iejnJnbi.js +0 -161
- package/lib/src/bundled-translations.pt-PT-D3V8A3WJ.js +0 -161
- package/src/brand-page/components/icon/icons/EmailAt.vue +0 -6
- package/src/brand-page/components/icon/icons/GoogleAdsense.vue +0 -14
- package/src/brand-page/components/icon/icons/GoogleAnalytics.vue +0 -17
- package/src/brand-page/components/icon/icons/Numeric.vue +0 -6
- package/src/brand-page/utils/migration/migration-08.test.ts +0 -398
- package/src/brand-page/utils/migration/migration-08.ts +0 -118
|
@@ -57,8 +57,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
57
57
|
size: string;
|
|
58
58
|
viewBox: string;
|
|
59
59
|
}, {}, {
|
|
60
|
-
IconEmailAt: import("vue").DefineComponent<{}, {}, any>;
|
|
61
|
-
IconNumeric: import("vue").DefineComponent<{}, {}, any>;
|
|
62
60
|
IconAmazon: import("vue").DefineComponent<{}, {}, any>;
|
|
63
61
|
IconAppstore: import("vue").DefineComponent<{}, {}, any>;
|
|
64
62
|
IconBehance: import("vue").DefineComponent<{}, {}, any>;
|
|
@@ -130,7 +128,5 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
130
128
|
IconPatreon: import("vue").DefineComponent<{}, {}, any>;
|
|
131
129
|
IconMessenger: import("vue").DefineComponent<{}, {}, any>;
|
|
132
130
|
IconAppleMusic: import("vue").DefineComponent<{}, {}, any>;
|
|
133
|
-
IconGoogleAdsense: import("vue").DefineComponent<{}, {}, any>;
|
|
134
|
-
IconGoogleAnalytics: import("vue").DefineComponent<{}, {}, any>;
|
|
135
131
|
}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
136
132
|
export default _default;
|
|
@@ -70,15 +70,9 @@ import IconVideo from './icons/Video.vue';
|
|
|
70
70
|
import IconWhatsapp from './icons/Whatsapp.vue';
|
|
71
71
|
import IconWineGlass from './icons/WineGlass.vue';
|
|
72
72
|
import IconYoutube from './icons/Youtube.vue';
|
|
73
|
-
import IconEmailAt from './icons/EmailAt.vue';
|
|
74
|
-
import IconNumeric from './icons/Numeric.vue';
|
|
75
|
-
import IconGoogleAdsense from './icons/GoogleAdsense.vue';
|
|
76
|
-
import IconGoogleAnalytics from './icons/GoogleAnalytics.vue';
|
|
77
73
|
import ComponentCommonMixin from '../mixins/component-common.mixin';
|
|
78
74
|
export default defineComponent({
|
|
79
75
|
components: {
|
|
80
|
-
IconEmailAt,
|
|
81
|
-
IconNumeric,
|
|
82
76
|
IconAmazon,
|
|
83
77
|
IconAppstore,
|
|
84
78
|
IconBehance,
|
|
@@ -150,8 +144,6 @@ export default defineComponent({
|
|
|
150
144
|
IconPatreon,
|
|
151
145
|
IconMessenger,
|
|
152
146
|
IconAppleMusic,
|
|
153
|
-
IconGoogleAdsense,
|
|
154
|
-
IconGoogleAnalytics,
|
|
155
147
|
},
|
|
156
148
|
mixins: [ComponentCommonMixin],
|
|
157
149
|
props: {
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import type { PropType } from 'vue';
|
|
2
|
+
import type { BrandPageContext, LinksItem } from '../../models';
|
|
3
|
+
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
|
+
id: {
|
|
5
|
+
type: StringConstructor;
|
|
6
|
+
required: true;
|
|
7
|
+
};
|
|
8
|
+
containerStyle: {
|
|
9
|
+
type: PropType<BrandPageCssStyle>;
|
|
10
|
+
required: true;
|
|
11
|
+
};
|
|
12
|
+
iconStyle: {
|
|
13
|
+
type: PropType<BrandPageCssStyle>;
|
|
14
|
+
required: true;
|
|
15
|
+
};
|
|
16
|
+
isPreview: {
|
|
17
|
+
type: BooleanConstructor;
|
|
18
|
+
required: true;
|
|
19
|
+
};
|
|
20
|
+
links: {
|
|
21
|
+
type: PropType<LinksItem[]>;
|
|
22
|
+
required: true;
|
|
23
|
+
};
|
|
24
|
+
context: {
|
|
25
|
+
type: PropType<BrandPageContext>;
|
|
26
|
+
required: true;
|
|
27
|
+
};
|
|
28
|
+
contentIndex: {
|
|
29
|
+
type: NumberConstructor;
|
|
30
|
+
required: false;
|
|
31
|
+
default: undefined;
|
|
32
|
+
};
|
|
33
|
+
}>, {}, {}, {
|
|
34
|
+
isUrl(): (url: string | undefined) => boolean;
|
|
35
|
+
}, {
|
|
36
|
+
getValidUrl(url: any): string | undefined;
|
|
37
|
+
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
38
|
+
id: {
|
|
39
|
+
type: StringConstructor;
|
|
40
|
+
required: true;
|
|
41
|
+
};
|
|
42
|
+
containerStyle: {
|
|
43
|
+
type: PropType<BrandPageCssStyle>;
|
|
44
|
+
required: true;
|
|
45
|
+
};
|
|
46
|
+
iconStyle: {
|
|
47
|
+
type: PropType<BrandPageCssStyle>;
|
|
48
|
+
required: true;
|
|
49
|
+
};
|
|
50
|
+
isPreview: {
|
|
51
|
+
type: BooleanConstructor;
|
|
52
|
+
required: true;
|
|
53
|
+
};
|
|
54
|
+
links: {
|
|
55
|
+
type: PropType<LinksItem[]>;
|
|
56
|
+
required: true;
|
|
57
|
+
};
|
|
58
|
+
context: {
|
|
59
|
+
type: PropType<BrandPageContext>;
|
|
60
|
+
required: true;
|
|
61
|
+
};
|
|
62
|
+
contentIndex: {
|
|
63
|
+
type: NumberConstructor;
|
|
64
|
+
required: false;
|
|
65
|
+
default: undefined;
|
|
66
|
+
};
|
|
67
|
+
}>> & Readonly<{}>, {
|
|
68
|
+
contentIndex: number;
|
|
69
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
70
|
+
export default _default;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { defineComponent } from 'vue';
|
|
2
|
+
import { isURL } from '../../../utils/validator.util';
|
|
3
|
+
export default defineComponent({
|
|
4
|
+
props: {
|
|
5
|
+
id: {
|
|
6
|
+
type: String,
|
|
7
|
+
required: true,
|
|
8
|
+
},
|
|
9
|
+
containerStyle: {
|
|
10
|
+
type: Object,
|
|
11
|
+
required: true,
|
|
12
|
+
},
|
|
13
|
+
iconStyle: {
|
|
14
|
+
type: Object,
|
|
15
|
+
required: true,
|
|
16
|
+
},
|
|
17
|
+
isPreview: {
|
|
18
|
+
type: Boolean,
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
links: {
|
|
22
|
+
type: Array,
|
|
23
|
+
required: true,
|
|
24
|
+
},
|
|
25
|
+
context: {
|
|
26
|
+
type: Object,
|
|
27
|
+
required: true,
|
|
28
|
+
},
|
|
29
|
+
contentIndex: {
|
|
30
|
+
type: Number,
|
|
31
|
+
required: false,
|
|
32
|
+
default: undefined,
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
computed: {
|
|
36
|
+
isUrl() {
|
|
37
|
+
return (url) => (url ? isURL(url) : false);
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
methods: {
|
|
41
|
+
getValidUrl(url) {
|
|
42
|
+
return isURL(url) && !this.isPreview ? url : undefined;
|
|
43
|
+
},
|
|
44
|
+
},
|
|
45
|
+
});
|
|
@@ -389,7 +389,6 @@ export class BrandPageModel {
|
|
|
389
389
|
faviconUrl;
|
|
390
390
|
ogImageUrl;
|
|
391
391
|
measurementID;
|
|
392
|
-
adsenseID;
|
|
393
392
|
ogTitle;
|
|
394
393
|
ogDescription;
|
|
395
394
|
cookieOptions;
|
|
@@ -450,7 +449,6 @@ export class BrandPageModel {
|
|
|
450
449
|
this.faviconUrl = options.faviconUrl;
|
|
451
450
|
this.ogImageUrl = options.ogImageUrl;
|
|
452
451
|
this.measurementID = options.measurementID;
|
|
453
|
-
this.adsenseID = options.adsenseID;
|
|
454
452
|
this.ogTitle = options.ogTitle;
|
|
455
453
|
this.ogDescription = options.ogDescription;
|
|
456
454
|
this.cookieOptions = options.cookieOptions;
|
|
@@ -13,22 +13,3 @@ export declare const applyLogoTemplateImageToBrandPageTemplateModel: (model: Bra
|
|
|
13
13
|
export declare const getLogoVariationUrlByLogoImage: (logoImage: LogoImageModel) => string | undefined;
|
|
14
14
|
export declare const getLogoTemplateUrlByLogoTemplateImage: (logoTemplateImage: LogoTemplateImageModel) => string;
|
|
15
15
|
export declare const getOptimalLogoSize: (width: number, height: number, currentSize: string) => string;
|
|
16
|
-
export declare const calculateLogoDimensions: (logoData: {
|
|
17
|
-
width: number;
|
|
18
|
-
height: number;
|
|
19
|
-
}, maxWidth: string, maxHeight: string) => {
|
|
20
|
-
width: string;
|
|
21
|
-
height: string;
|
|
22
|
-
};
|
|
23
|
-
export declare const calculateOptimizedLogoDimensions: (logoData: {
|
|
24
|
-
width: number;
|
|
25
|
-
height: number;
|
|
26
|
-
} | null, currentWidth: string, currentHeight: string) => {
|
|
27
|
-
width: string;
|
|
28
|
-
height: string;
|
|
29
|
-
};
|
|
30
|
-
export declare const recalculateLogoContentDimensions: (pageData: any, editableLogoVariations?: {
|
|
31
|
-
variationId: number;
|
|
32
|
-
width: number;
|
|
33
|
-
height: number;
|
|
34
|
-
}[]) => Promise<void>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DEFAULT_LOGO_VARIATION, LOGO_VARIATION
|
|
1
|
+
import { DEFAULT_LOGO_VARIATION, LOGO_VARIATION } from '../constants';
|
|
2
2
|
import { BRAND_PAGE_TYPES, } from '../models';
|
|
3
3
|
import { FabricRenderClient, LogoVariationDefinitions, } from '../../clients/fabric-render-client';
|
|
4
4
|
import { isLogoContent } from './model.util';
|
|
@@ -183,81 +183,3 @@ export const getOptimalLogoSize = (width, height, currentSize) => {
|
|
|
183
183
|
return `${Math.round(newSize)}rem`;
|
|
184
184
|
}
|
|
185
185
|
};
|
|
186
|
-
export const calculateLogoDimensions = (logoData, maxWidth, maxHeight) => {
|
|
187
|
-
const maxWidthRem = parseFloat(maxWidth);
|
|
188
|
-
const maxHeightRem = parseFloat(maxHeight);
|
|
189
|
-
const logoAspectRatio = logoData.width / logoData.height;
|
|
190
|
-
let actualHeight;
|
|
191
|
-
if (logoAspectRatio >= 1) {
|
|
192
|
-
actualHeight = maxWidthRem / logoAspectRatio;
|
|
193
|
-
}
|
|
194
|
-
else {
|
|
195
|
-
actualHeight = maxHeightRem;
|
|
196
|
-
}
|
|
197
|
-
const actualHeightRem = `${Math.ceil(actualHeight)}rem`;
|
|
198
|
-
return { width: actualHeightRem, height: actualHeightRem };
|
|
199
|
-
};
|
|
200
|
-
export const calculateOptimizedLogoDimensions = (logoData, currentWidth, currentHeight) => {
|
|
201
|
-
const currentHeightRem = parseFloat(currentHeight);
|
|
202
|
-
if (logoData && logoData.width && logoData.height) {
|
|
203
|
-
const logoAspectRatio = logoData.width / logoData.height;
|
|
204
|
-
let newsize = currentHeightRem;
|
|
205
|
-
// Width-dominant logo (wider than tall)
|
|
206
|
-
if (logoAspectRatio >= 1.75 && logoAspectRatio <= 2) {
|
|
207
|
-
const ratioDiff = 2 - logoAspectRatio;
|
|
208
|
-
newsize = currentHeightRem - Math.round(ratioDiff * 10);
|
|
209
|
-
return {
|
|
210
|
-
width: `${newsize}rem`,
|
|
211
|
-
height: `${newsize}rem`,
|
|
212
|
-
};
|
|
213
|
-
}
|
|
214
|
-
else if (logoAspectRatio > 2) {
|
|
215
|
-
return {
|
|
216
|
-
width: `4rem`,
|
|
217
|
-
height: `4rem`,
|
|
218
|
-
};
|
|
219
|
-
}
|
|
220
|
-
}
|
|
221
|
-
return { width: currentWidth, height: currentHeight };
|
|
222
|
-
};
|
|
223
|
-
export const recalculateLogoContentDimensions = async (pageData, editableLogoVariations) => {
|
|
224
|
-
try {
|
|
225
|
-
const logoContents = [];
|
|
226
|
-
pageData.pages.forEach((page, pageIndex) => {
|
|
227
|
-
page.contents.forEach((contentItem, contentIndex) => {
|
|
228
|
-
const content = contentItem.settings.content;
|
|
229
|
-
if (isLogoContent(content)) {
|
|
230
|
-
logoContents.push({ content, pageIndex, contentIndex });
|
|
231
|
-
}
|
|
232
|
-
});
|
|
233
|
-
});
|
|
234
|
-
if (logoContents.length === 0) {
|
|
235
|
-
return;
|
|
236
|
-
}
|
|
237
|
-
logoContents.forEach(({ content }) => {
|
|
238
|
-
let logoData = null;
|
|
239
|
-
// First priority: Use editableLogoVariations if available
|
|
240
|
-
if (editableLogoVariations &&
|
|
241
|
-
content.logoImage?.logoVariation !== undefined) {
|
|
242
|
-
const matchingVariation = editableLogoVariations.find((variation) => variation.variationId === content.logoImage.logoVariation);
|
|
243
|
-
if (matchingVariation) {
|
|
244
|
-
logoData = {
|
|
245
|
-
width: matchingVariation.width,
|
|
246
|
-
height: matchingVariation.height,
|
|
247
|
-
};
|
|
248
|
-
}
|
|
249
|
-
}
|
|
250
|
-
// Apply dimensions or fallback logic
|
|
251
|
-
if (logoData && logoData.width && logoData.height) {
|
|
252
|
-
const currentMaxWidth = content.logoImageWidth || DEFAULT_LOGO_WIDTH;
|
|
253
|
-
const currentMaxHeight = content.logoImageHeight || DEFAULT_LOGO_HEIGHT;
|
|
254
|
-
const dimensions = calculateOptimizedLogoDimensions(logoData, currentMaxWidth, currentMaxHeight);
|
|
255
|
-
content.logoImageHeight = dimensions.height;
|
|
256
|
-
content.logoImageWidth = dimensions.width;
|
|
257
|
-
}
|
|
258
|
-
});
|
|
259
|
-
}
|
|
260
|
-
catch (error) {
|
|
261
|
-
console.warn('Failed to recalculate prepurchase logo dimensions:', error);
|
|
262
|
-
}
|
|
263
|
-
};
|
|
@@ -1,11 +1,21 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { DEFAULT_LOGO_HEIGHT, DEFAULT_LOGO_WIDTH, PageFooterDesktop, PageFooterMobile, PageHeaderDesktop, PageHeaderMobile, } from '../..';
|
|
2
2
|
import { FabricRenderClient } from '../../../clients/fabric-render-client';
|
|
3
|
-
|
|
3
|
+
const calculateConstrainedDimensions = (logoData, maxWidth, maxHeight) => {
|
|
4
|
+
const maxWidthRem = parseFloat(maxWidth);
|
|
5
|
+
const maxHeightRem = parseFloat(maxHeight);
|
|
6
|
+
const logoAspectRatio = logoData.width / logoData.height;
|
|
7
|
+
let actualHeight;
|
|
8
|
+
if (logoAspectRatio >= 1) {
|
|
9
|
+
actualHeight = maxWidthRem / logoAspectRatio;
|
|
10
|
+
}
|
|
11
|
+
else {
|
|
12
|
+
actualHeight = maxHeightRem;
|
|
13
|
+
}
|
|
14
|
+
const actualHeightRem = `${Math.ceil(actualHeight)}rem`;
|
|
15
|
+
return { width: actualHeightRem, height: actualHeightRem };
|
|
16
|
+
};
|
|
4
17
|
export const migration07 = async (migrationResult, options) => {
|
|
5
18
|
const { brandPageModel } = migrationResult;
|
|
6
|
-
if (brandPageModel.brandPageType !== BRAND_PAGE_TYPES.brandSite) {
|
|
7
|
-
return migrationResult;
|
|
8
|
-
}
|
|
9
19
|
if (options.isServerRender !== undefined && options.isServerRender) {
|
|
10
20
|
migrationResult.useOldLogoRenderSize = true;
|
|
11
21
|
return migrationResult;
|
|
@@ -36,7 +46,7 @@ export const migration07 = async (migrationResult, options) => {
|
|
|
36
46
|
if (logoData && logoData.width && logoData.height && config) {
|
|
37
47
|
const currentMaxWidth = config.logoImageWidth || DEFAULT_LOGO_WIDTH;
|
|
38
48
|
const currentMaxHeight = config.logoImageHeight || DEFAULT_LOGO_HEIGHT;
|
|
39
|
-
const dimensions =
|
|
49
|
+
const dimensions = calculateConstrainedDimensions(logoData, currentMaxWidth, currentMaxHeight);
|
|
40
50
|
config.logoImageHeight = dimensions.height;
|
|
41
51
|
config.logoImageWidth = dimensions.width;
|
|
42
52
|
}
|
|
@@ -54,7 +64,7 @@ export const migration07 = async (migrationResult, options) => {
|
|
|
54
64
|
});
|
|
55
65
|
}
|
|
56
66
|
catch (error) {
|
|
57
|
-
console.warn('Migration
|
|
67
|
+
console.warn('Migration 06: Failed to fetch logo dimensions:', error);
|
|
58
68
|
migrationResult.useOldLogoRenderSize = true;
|
|
59
69
|
return migrationResult;
|
|
60
70
|
}
|
|
@@ -10,7 +10,6 @@ import { migration06 } from './migration/migration-06';
|
|
|
10
10
|
import { migration05_1 } from './migration/migration-05_1';
|
|
11
11
|
import { migration05_2 } from './migration/migration-05_2';
|
|
12
12
|
import { migration07 } from './migration/migration-07';
|
|
13
|
-
import { migration08 } from './migration/migration-08';
|
|
14
13
|
const MIGRATION_TABLE = [
|
|
15
14
|
{
|
|
16
15
|
version: 1,
|
|
@@ -63,11 +62,6 @@ const MIGRATION_TABLE = [
|
|
|
63
62
|
migrateFn: migration07,
|
|
64
63
|
description: 'Migrating logo render sizes for logo content, header and footer sections',
|
|
65
64
|
},
|
|
66
|
-
{
|
|
67
|
-
version: 8,
|
|
68
|
-
migrateFn: migration08,
|
|
69
|
-
description: 'Migrating logo content sizes for brandPage and brandContact',
|
|
70
|
-
},
|
|
71
65
|
];
|
|
72
66
|
export const GetLatestModelVersion = () => Math.max(...MIGRATION_TABLE.map((x) => x.version));
|
|
73
67
|
export const migrateBrandPageModel = async (brandPageModel, options) => {
|
|
@@ -734,7 +734,6 @@ export const getBrandPageViewModelFromBrandPageModel = (model, brandPageToken, s
|
|
|
734
734
|
faviconUrl: model.faviconUrl,
|
|
735
735
|
ogImageUrl: model.ogImageUrl,
|
|
736
736
|
measurementID: model.measurementID,
|
|
737
|
-
adsenseID: model.adsenseID,
|
|
738
737
|
ogTitle: model.ogTitle,
|
|
739
738
|
ogDescription: model.ogDescription,
|
|
740
739
|
cookieOptions: {
|
|
@@ -45,9 +45,6 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
45
45
|
setMeasurementID(payload: {
|
|
46
46
|
measurementID: string | undefined;
|
|
47
47
|
}): void;
|
|
48
|
-
setAdsenseID(payload: {
|
|
49
|
-
adsenseID: string | undefined;
|
|
50
|
-
}): void;
|
|
51
48
|
setOgTitle(payload: {
|
|
52
49
|
ogTitle: string | undefined;
|
|
53
50
|
}): void;
|
|
@@ -125,9 +122,6 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
125
122
|
updateAndSaveMeasurementID(payload: {
|
|
126
123
|
measurementID: string | undefined;
|
|
127
124
|
}): Promise<void>;
|
|
128
|
-
updateAndSaveAdsenseID(payload: {
|
|
129
|
-
adsenseID: string | undefined;
|
|
130
|
-
}): Promise<void>;
|
|
131
125
|
validateContentItems(): Promise<void>;
|
|
132
126
|
validateBrandPageData(): Promise<void>;
|
|
133
127
|
setViewport(payload: {
|
|
@@ -87,9 +87,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
87
87
|
setMeasurementID(payload: {
|
|
88
88
|
measurementID: string | undefined;
|
|
89
89
|
}): void;
|
|
90
|
-
setAdsenseID(payload: {
|
|
91
|
-
adsenseID: string | undefined;
|
|
92
|
-
}): void;
|
|
93
90
|
setOgTitle(payload: {
|
|
94
91
|
ogTitle: string | undefined;
|
|
95
92
|
}): void;
|
|
@@ -167,9 +164,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
167
164
|
updateAndSaveMeasurementID(payload: {
|
|
168
165
|
measurementID: string | undefined;
|
|
169
166
|
}): Promise<void>;
|
|
170
|
-
updateAndSaveAdsenseID(payload: {
|
|
171
|
-
adsenseID: string | undefined;
|
|
172
|
-
}): Promise<void>;
|
|
173
167
|
validateContentItems(): Promise<void>;
|
|
174
168
|
validateBrandPageData(): Promise<void>;
|
|
175
169
|
setViewport(payload: {
|
|
@@ -246,6 +240,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
246
240
|
slug: string;
|
|
247
241
|
standalone: boolean;
|
|
248
242
|
triggerSaveSuccessMessage: boolean;
|
|
243
|
+
measurementID: string | undefined;
|
|
249
244
|
isDesignCom: boolean;
|
|
250
245
|
isPrePurchase: boolean;
|
|
251
246
|
makerFonts: any[];
|
|
@@ -305,6 +300,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
305
300
|
slug: string;
|
|
306
301
|
standalone: boolean;
|
|
307
302
|
triggerSaveSuccessMessage: boolean;
|
|
303
|
+
measurementID: string | undefined;
|
|
308
304
|
isDesignCom: boolean;
|
|
309
305
|
isPrePurchase: boolean;
|
|
310
306
|
makerFonts: any[];
|
|
@@ -35,9 +35,6 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
35
35
|
setMeasurementID(payload: {
|
|
36
36
|
measurementID: string | undefined;
|
|
37
37
|
}): void;
|
|
38
|
-
setAdsenseID(payload: {
|
|
39
|
-
adsenseID: string | undefined;
|
|
40
|
-
}): void;
|
|
41
38
|
setOgTitle(payload: {
|
|
42
39
|
ogTitle: string | undefined;
|
|
43
40
|
}): void;
|
|
@@ -115,9 +112,6 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
115
112
|
updateAndSaveMeasurementID(payload: {
|
|
116
113
|
measurementID: string | undefined;
|
|
117
114
|
}): Promise<void>;
|
|
118
|
-
updateAndSaveAdsenseID(payload: {
|
|
119
|
-
adsenseID: string | undefined;
|
|
120
|
-
}): Promise<void>;
|
|
121
115
|
validateContentItems(): Promise<void>;
|
|
122
116
|
validateBrandPageData(): Promise<void>;
|
|
123
117
|
setViewport(payload: {
|
package/lib/src/brand-page-maker/components/brand-page-maker/__fixtures__/brand-page-examples.js
CHANGED
|
@@ -51,8 +51,6 @@ export const userFeatures = {
|
|
|
51
51
|
canUsePremiumFontFamily: true,
|
|
52
52
|
maxNumOfPages: DEFAULT_MAX_NUM_OF_PAGES,
|
|
53
53
|
canUseGettyVideos: false,
|
|
54
|
-
canUseGoogleAdsense: false,
|
|
55
|
-
googleAdsenseEnabled: false,
|
|
56
54
|
};
|
|
57
55
|
export const BRAND_PAGE = {
|
|
58
56
|
styles: {
|
|
@@ -2027,8 +2025,6 @@ export const INITIALISE_PAYLOAD = Object.freeze({
|
|
|
2027
2025
|
canUsePremiumFontFamily: true,
|
|
2028
2026
|
maxNumOfPages: UNLIMITED_MAX_NUM_OF_PAGES,
|
|
2029
2027
|
canUseGettyVideos: true,
|
|
2030
|
-
canUseGoogleAdsense: false,
|
|
2031
|
-
googleAdsenseEnabled: true,
|
|
2032
2028
|
},
|
|
2033
2029
|
logoDraftDesignAttributes: simpleLogoDesignAttributes,
|
|
2034
2030
|
backUrl: '',
|
package/lib/src/brand-page-maker/components/brandpage-maker-page/BrandPageMakerPage.mixin.d.ts
CHANGED
|
@@ -540,9 +540,6 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
540
540
|
setMeasurementID(payload: {
|
|
541
541
|
measurementID: string | undefined;
|
|
542
542
|
}): void;
|
|
543
|
-
setAdsenseID(payload: {
|
|
544
|
-
adsenseID: string | undefined;
|
|
545
|
-
}): void;
|
|
546
543
|
setOgTitle(payload: {
|
|
547
544
|
ogTitle: string | undefined;
|
|
548
545
|
}): void;
|
|
@@ -620,9 +617,6 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
620
617
|
updateAndSaveMeasurementID(payload: {
|
|
621
618
|
measurementID: string | undefined;
|
|
622
619
|
}): Promise<void>;
|
|
623
|
-
updateAndSaveAdsenseID(payload: {
|
|
624
|
-
adsenseID: string | undefined;
|
|
625
|
-
}): Promise<void>;
|
|
626
620
|
validateContentItems(): Promise<void>;
|
|
627
621
|
validateBrandPageData(): Promise<void>;
|
|
628
622
|
setViewport(payload: {
|
|
@@ -684,6 +678,7 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
684
678
|
slug: string;
|
|
685
679
|
standalone: boolean;
|
|
686
680
|
triggerSaveSuccessMessage: boolean;
|
|
681
|
+
measurementID: string | undefined;
|
|
687
682
|
isDesignCom: boolean;
|
|
688
683
|
isPrePurchase: boolean;
|
|
689
684
|
makerFonts: any[];
|
|
@@ -743,6 +738,7 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
743
738
|
slug: string;
|
|
744
739
|
standalone: boolean;
|
|
745
740
|
triggerSaveSuccessMessage: boolean;
|
|
741
|
+
measurementID: string | undefined;
|
|
746
742
|
isDesignCom: boolean;
|
|
747
743
|
isPrePurchase: boolean;
|
|
748
744
|
makerFonts: any[];
|
|
@@ -42,9 +42,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
42
42
|
setMeasurementID(payload: {
|
|
43
43
|
measurementID: string | undefined;
|
|
44
44
|
}): void;
|
|
45
|
-
setAdsenseID(payload: {
|
|
46
|
-
adsenseID: string | undefined;
|
|
47
|
-
}): void;
|
|
48
45
|
setOgTitle(payload: {
|
|
49
46
|
ogTitle: string | undefined;
|
|
50
47
|
}): void;
|
|
@@ -122,9 +119,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
122
119
|
updateAndSaveMeasurementID(payload: {
|
|
123
120
|
measurementID: string | undefined;
|
|
124
121
|
}): Promise<void>;
|
|
125
|
-
updateAndSaveAdsenseID(payload: {
|
|
126
|
-
adsenseID: string | undefined;
|
|
127
|
-
}): Promise<void>;
|
|
128
122
|
validateContentItems(): Promise<void>;
|
|
129
123
|
validateBrandPageData(): Promise<void>;
|
|
130
124
|
setViewport(payload: {
|