@designcrowd/library.brand-page 5.13.2-jj3 → 5.13.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.
Files changed (31) hide show
  1. package/lib/src/{CreatedOnBrandCrowd-de-de-CeEHfqaI.js → CreatedOnBrandCrowd-de-de-CfG0-858.js} +1 -1
  2. package/lib/src/{CreatedOnBrandCrowd-en-us-CE7ZxGyI.js → CreatedOnBrandCrowd-en-us-CcJ-jWWD.js} +1 -1
  3. package/lib/src/{CreatedOnBrandCrowd-es-es-CrSMpcLT.js → CreatedOnBrandCrowd-es-es-CfiRcdwQ.js} +1 -1
  4. package/lib/src/{CreatedOnBrandCrowd-fr-fr-CUj3WxaT.js → CreatedOnBrandCrowd-fr-fr-BsplcwEN.js} +1 -1
  5. package/lib/src/{CreatedOnBrandCrowd-pt-pt-Dt_J16X6.js → CreatedOnBrandCrowd-pt-pt-C9vHZlGJ.js} +1 -1
  6. package/lib/src/{CreatedOnDcom-de-de-Cw8IRb5V.js → CreatedOnDcom-de-de-HOhAr9ML.js} +1 -1
  7. package/lib/src/{CreatedOnDcom-en-us-CrrzoBU7.js → CreatedOnDcom-en-us-BxHSRmK8.js} +1 -1
  8. package/lib/src/{CreatedOnDcom-es-es-C9JUdGHw.js → CreatedOnDcom-es-es-rUrC1JPi.js} +1 -1
  9. package/lib/src/{CreatedOnDcom-fr-fr-CyFR7MQl.js → CreatedOnDcom-fr-fr-B3kh5Mj2.js} +1 -1
  10. package/lib/src/{CreatedOnDcom-pt-pt-DLebp2Wn.js → CreatedOnDcom-pt-pt-DGzCGnWH.js} +1 -1
  11. package/lib/src/brand-page/utils/migration/migration-01.d.ts +2 -1
  12. package/lib/src/brand-page/utils/migration/migration-01.js +2 -0
  13. package/lib/src/brand-page/utils/migration/{migration-05_1.d.ts → migration-051.d.ts} +1 -1
  14. package/lib/src/brand-page/utils/migration/{migration-05_1.js → migration-051.js} +1 -1
  15. package/lib/src/brand-page/utils/migration.util.js +3 -16
  16. package/lib/src/brand-page-maker/constants/index.d.ts +4 -4
  17. package/lib/src/brand-page-maker/constants/index.js +4 -4
  18. package/lib/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.js +0 -1
  19. package/lib/src/clients/media-client.js +2 -2
  20. package/lib/src/index.mjs +1 -1
  21. package/lib/src/{lib-29h6IPue.js → lib-na3Nl6DE.js} +12312 -12325
  22. package/package.json +1 -1
  23. package/src/brand-page/utils/migration/migration-01.ts +4 -0
  24. package/src/brand-page/utils/migration/{migration-05_1.ts → migration-051.ts} +1 -1
  25. package/src/brand-page/utils/migration.util.ts +3 -19
  26. package/src/brand-page-maker/constants/index.ts +4 -4
  27. package/src/brand-page-maker/stores/brandpage-maker/brandpage-maker-store.ts +0 -1
  28. package/src/clients/media-client.js +2 -2
  29. package/lib/src/brand-page/utils/migration/migration-01_1.d.ts +0 -4
  30. package/lib/src/brand-page/utils/migration/migration-01_1.js +0 -5
  31. package/src/brand-page/utils/migration/migration-01_1.ts +0 -14
@@ -1,5 +1,5 @@
1
1
  import { createElementBlock as e, openBlock as l, createStaticVNode as a } from "vue";
2
- import { _ as t } from "./lib-29h6IPue.js";
2
+ import { _ as t } from "./lib-na3Nl6DE.js";
3
3
  const i = {}, h = {
4
4
  width: "275",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { createElementBlock as e, openBlock as l, createStaticVNode as a } from "vue";
2
- import { _ as t } from "./lib-29h6IPue.js";
2
+ import { _ as t } from "./lib-na3Nl6DE.js";
3
3
  const i = {}, h = {
4
4
  width: "251",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { createElementBlock as e, openBlock as l, createStaticVNode as a } from "vue";
2
- import { _ as t } from "./lib-29h6IPue.js";
2
+ import { _ as t } from "./lib-na3Nl6DE.js";
3
3
  const i = {}, h = {
4
4
  width: "250",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { createElementBlock as e, openBlock as l, createStaticVNode as a } from "vue";
2
- import { _ as t } from "./lib-29h6IPue.js";
2
+ import { _ as t } from "./lib-na3Nl6DE.js";
3
3
  const i = {}, h = {
4
4
  width: "237",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { createElementBlock as e, openBlock as l, createStaticVNode as a } from "vue";
2
- import { _ as t } from "./lib-29h6IPue.js";
2
+ import { _ as t } from "./lib-na3Nl6DE.js";
3
3
  const i = {}, h = {
4
4
  width: "263",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { createElementBlock as H, openBlock as V, createStaticVNode as t } from "vue";
2
- import { _ as e } from "./lib-29h6IPue.js";
2
+ import { _ as e } from "./lib-na3Nl6DE.js";
3
3
  const M = {}, Z = {
4
4
  width: "242",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { createElementBlock as H, openBlock as V, createStaticVNode as t } from "vue";
2
- import { _ as e } from "./lib-29h6IPue.js";
2
+ import { _ as e } from "./lib-na3Nl6DE.js";
3
3
  const i = {}, M = {
4
4
  width: "231",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { createElementBlock as H, openBlock as V, createStaticVNode as t } from "vue";
2
- import { _ as e } from "./lib-29h6IPue.js";
2
+ import { _ as e } from "./lib-na3Nl6DE.js";
3
3
  const M = {}, Z = {
4
4
  width: "230",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { createElementBlock as H, openBlock as V, createStaticVNode as t } from "vue";
2
- import { _ as e } from "./lib-29h6IPue.js";
2
+ import { _ as e } from "./lib-na3Nl6DE.js";
3
3
  const i = {}, l = {
4
4
  width: "216",
5
5
  height: "36",
@@ -1,5 +1,5 @@
1
1
  import { createElementBlock as H, openBlock as V, createStaticVNode as t } from "vue";
2
- import { _ as M } from "./lib-29h6IPue.js";
2
+ import { _ as M } from "./lib-na3Nl6DE.js";
3
3
  const Z = {}, e = {
4
4
  width: "232",
5
5
  height: "36",
@@ -1,4 +1,4 @@
1
- import type { BrandPageModel } from '../../';
1
+ import type { BrandPageModel, LogoImageModel } from '../../';
2
2
  export declare const applyTextContentTextToTextItemsMigration: (brandPageModel: BrandPageModel) => void;
3
3
  export declare const migrateProfileContentToHaveTextStyles: (brandPageModel: BrandPageModel) => void;
4
4
  export declare const migrateMailingListContentToHaveTextStyles: (brandPageModel: BrandPageModel) => void;
@@ -18,5 +18,6 @@ export declare const migrateGlobalTextStylesToHaveMissingStyles: (brandPageModel
18
18
  export declare const migrateConvertLineHeightOnNavigationStyles: (brandPageModel: BrandPageModel) => void;
19
19
  export declare const migrateConvertLineHeightOnFooterStyles: (brandPageModel: BrandPageModel) => void;
20
20
  export declare const migration01: (brandPageModel: BrandPageModel, options: {
21
+ logoImage?: LogoImageModel;
21
22
  isUserDraft: boolean;
22
23
  }) => BrandPageModel;
@@ -3,6 +3,7 @@ import { DEFAULT_LETTER_SPACING, FOOTER_DISPLAY, NavigationDesktop, NavigationMo
3
3
  import { ALIGN_CARD_CENTER_IMAGE, ALIGN_CARD_LEFT_IMAGE, ALIGN_CENTERED, ALIGN_LEFT_BIG_IMAGE, BIG_IMAGE, BRAND_PAGE_TYPES, DEFAULT_FONT_FAMILY_KEY, DEFAULT_LOGO_HEIGHT, DEFAULT_LOGO_WIDTH, DEFAULT_TEXT_ALIGN, FONT_FAMILY_CONFIGS, HEADER_DISPLAY, NAVIGATION_DISPLAY, LINE_HEIGHT_BODY, LINE_HEIGHT_HEADINGS, LINE_HEIGHT_TITLE, PAYMENT_OPTION_DISPLAY_TYPES, } from '../../';
4
4
  import { isAboutContent, isBannerContent, isButtonContent, isContact, isImagesContent, isLogoContent, isMailingListContent, isPayment, isProfileContent, isShapesContent, isSocialLinks, isSupportMeContent, isTestimonialContent, isTextContent, } from '../../utils';
5
5
  import { createInitialLogoContent } from '../../../brand-page-maker/models';
6
+ import { migrateLogoImage } from './logo/logo.migration.util';
6
7
  export const applyTextContentTextToTextItemsMigration = (brandPageModel) => {
7
8
  const textContents = brandPageModel.pages.reduce((acc, cur) => {
8
9
  return [...acc, ...cur.contents.filter(isTextContent)];
@@ -888,5 +889,6 @@ export const migration01 = (brandPageModel, options) => {
888
889
  migrateGlobalTextStylesToHaveMissingStyles(brandPageModel);
889
890
  migrateConvertLineHeightOnNavigationStyles(brandPageModel);
890
891
  migrateConvertLineHeightOnFooterStyles(brandPageModel);
892
+ migrateLogoImage(brandPageModel, options.logoImage);
891
893
  return brandPageModel;
892
894
  };
@@ -1,4 +1,4 @@
1
1
  import { type BrandPageModel } from '../..';
2
- export declare const migration05_1: (brandPageModel: BrandPageModel, options: {
2
+ export declare const migration051: (brandPageModel: BrandPageModel, options: {
3
3
  isUserDraft: boolean;
4
4
  }) => BrandPageModel;
@@ -1,5 +1,5 @@
1
1
  import {} from '../..';
2
- export const migration05_1 = (brandPageModel, options) => {
2
+ export const migration051 = (brandPageModel, options) => {
3
3
  if (!options.isUserDraft) {
4
4
  brandPageModel.pageFooterDesktop?.socialLinks?.forEach((link) => {
5
5
  if (link.imageUrl === 'twitter') {
@@ -1,47 +1,34 @@
1
1
  import {} from '../models';
2
2
  import { migration01 } from './migration/migration-01';
3
- import { migration01_1 } from './migration/migration-01_1';
4
3
  import { migration02 } from './migration/migration-02';
5
4
  import { migration03 } from './migration/migration-03';
6
5
  import { migration04 } from './migration/migration-04';
7
6
  import { migration05 } from './migration/migration-05';
8
- import { migration05_1 } from './migration/migration-05_1';
7
+ import { migration051 } from './migration/migration-051';
9
8
  const MIGRATION_TABLE = [
10
9
  {
11
10
  version: 1,
12
11
  migrateFn: migration01,
13
- description: 'Legacy migration',
14
- },
15
- {
16
- version: 1.1,
17
- migrateFn: migration01_1,
18
- description: 'When loading template assign logo to the metadata',
19
- runAlways: true,
20
12
  },
21
13
  {
22
14
  version: 2,
23
15
  migrateFn: migration02,
24
- description: 'Migrating letterspacing unit from rem to em',
25
16
  },
26
17
  {
27
18
  version: 3,
28
19
  migrateFn: migration03,
29
- description: 'Migrating font size unit from rem to em to support fluid text',
30
20
  },
31
21
  {
32
22
  version: 4,
33
23
  migrateFn: migration04,
34
- description: 'Migrating user uploaded image URLs to remove extensions',
35
24
  },
36
25
  {
37
26
  version: 5,
38
27
  migrateFn: migration05,
39
- description: 'Migrating text item text styles to apply auto scale',
40
28
  },
41
29
  {
42
30
  version: 5.1,
43
- migrateFn: migration05_1,
44
- description: 'Migrating twitter icon and url to x icon and x.com',
31
+ migrateFn: migration051,
45
32
  },
46
33
  ];
47
34
  export const GetLatestModelVersion = () => Math.max(...MIGRATION_TABLE.map((x) => x.version));
@@ -51,7 +38,7 @@ export const migrateBrandPageModel = (brandPageModel, options) => {
51
38
  modelVersion = 0;
52
39
  }
53
40
  MIGRATION_TABLE.forEach((x) => {
54
- if (x.runAlways || modelVersion < x.version) {
41
+ if (modelVersion < x.version) {
55
42
  brandPageModel = x.migrateFn(brandPageModel, options);
56
43
  }
57
44
  });
@@ -10,10 +10,10 @@ export declare const USER_POLICY_DATA_ENDPOINT = "/maker/api/users/policy-data";
10
10
  export declare const GET_ALL_USER_MEDIA_ENDPOINT = "/maker/api/users/media";
11
11
  export declare const CREATE_USER_MEDIA_ENDPOINT = "/maker/api/users/media";
12
12
  export declare const DELETE_USER_MEDIA_ENDPOINT = "/maker/api/users/media";
13
- export declare const ADMIN_POLICY_DATA_ENDPOINT = "/maker/api/media/upload/request";
14
- export declare const GET_ALL_ADMIN_MEDIA_ENDPOINT = "/maker/api/media/GetPaginatedAdminMedia";
15
- export declare const CREATE_ADMIN_MEDIA_ENDPOINT = "/maker/api/media/upload";
16
- export declare const DELETE_ADMIN_MEDIA_ENDPOINT = "/maker/api/media";
13
+ export declare const ADMIN_POLICY_DATA_ENDPOINT = "/maker/media/upload/request";
14
+ export declare const GET_ALL_ADMIN_MEDIA_ENDPOINT = "/maker/media/GetPaginatedAdminMedia";
15
+ export declare const CREATE_ADMIN_MEDIA_ENDPOINT = "/maker/media/upload";
16
+ export declare const DELETE_ADMIN_MEDIA_ENDPOINT = "/maker/media";
17
17
  export declare const MY_DESIGN_ASSETS_ENDPOINTS = "/maker/api/asset/all";
18
18
  export declare const BYO_DETAILS_ENDPOINT = "/maker/api/user-logos/logo-image";
19
19
  export declare const BYO_UPLOAD_ENDPOINT = "/maker/api/user-logos";
@@ -10,10 +10,10 @@ export const USER_POLICY_DATA_ENDPOINT = `/maker/api/users/policy-data`;
10
10
  export const GET_ALL_USER_MEDIA_ENDPOINT = `/maker/api/users/media`;
11
11
  export const CREATE_USER_MEDIA_ENDPOINT = '/maker/api/users/media';
12
12
  export const DELETE_USER_MEDIA_ENDPOINT = '/maker/api/users/media';
13
- export const ADMIN_POLICY_DATA_ENDPOINT = `/maker/api/media/upload/request`;
14
- export const GET_ALL_ADMIN_MEDIA_ENDPOINT = `/maker/api/media/GetPaginatedAdminMedia`;
15
- export const CREATE_ADMIN_MEDIA_ENDPOINT = '/maker/api/media/upload';
16
- export const DELETE_ADMIN_MEDIA_ENDPOINT = '/maker/api/media';
13
+ export const ADMIN_POLICY_DATA_ENDPOINT = `/maker/media/upload/request`;
14
+ export const GET_ALL_ADMIN_MEDIA_ENDPOINT = `/maker/media/GetPaginatedAdminMedia`;
15
+ export const CREATE_ADMIN_MEDIA_ENDPOINT = '/maker/media/upload';
16
+ export const DELETE_ADMIN_MEDIA_ENDPOINT = '/maker/media';
17
17
  export const MY_DESIGN_ASSETS_ENDPOINTS = `/maker/api/asset/all`;
18
18
  export const BYO_DETAILS_ENDPOINT = `/maker/api/user-logos/logo-image`;
19
19
  export const BYO_UPLOAD_ENDPOINT = `/maker/api/user-logos`;
@@ -815,7 +815,6 @@ export const useBrandPageMakerStore = defineStore('brandPageMaker', {
815
815
  const galleryStyles = styleSettingsStore.galleryStyles;
816
816
  const navigation = navigationStyleSettingsStore.navigation;
817
817
  return {
818
- v: GetLatestModelVersion(),
819
818
  styles: {
820
819
  logoStyles,
821
820
  buttonStyles,
@@ -23,8 +23,8 @@ import Axios from 'axios';
23
23
  import { v4 as uuidV4 } from 'uuid';
24
24
  import { getUserMediaTokensFromLocalStorage, addUserMediaTokenToLocalStorage, removeUserMediaTokenFromLocalStorage, } from '../utils/localStorageUtils';
25
25
  export default class MediaClient {
26
- findPaginatedAdminMediaEndpoint = (skip, take, videoOnly) => `${this.options.mediaBaseUrl}/maker/api/media/GetPaginatedAdminMedia?skip=${skip}&take=${take}&videoOnly=${videoOnly}`;
27
- uploadAdminMediaEndpoint = () => `${this.options.mediaBaseUrl}/maker/api/media/upload`;
26
+ findPaginatedAdminMediaEndpoint = (skip, take, videoOnly) => `${this.options.mediaBaseUrl}/maker/media/GetPaginatedAdminMedia?skip=${skip}&take=${take}&videoOnly=${videoOnly}`;
27
+ uploadAdminMediaEndpoint = () => `${this.options.mediaBaseUrl}/maker/media/upload`;
28
28
  userPolicyDataEndpoint = () => `${this.options.mediaBaseUrl}/maker/api/users/policy-data`;
29
29
  getAllUserMediaEndpoint = () => `${this.options.mediaBaseUrl}/maker/api/users/media`;
30
30
  getUserMediaEndpoint = (mediaToken) => `${this.options.mediaBaseUrl}/maker/api/users/media/${mediaToken}`;
package/lib/src/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { by as E, an as T, aP as I, a3 as N, ag as S, ad as s, bo as A, bF as O, c6 as e, c5 as G, c4 as C, b_ as D, aZ as P, aY as R, bK as t, bL as L, bS as M, bH as o, bJ as b, bI as r, bM as F, bN as n, bZ as B, bX as g, am as l, bY as i, a6 as Y, aU as U, aW as c, aV as d, e as H, f as u, B as y, Y as K, d as p, Z as k, j as V, aj as X, X as m, bn as v, bG as h, at as W, aR as x, aN as f, bV as Z, bU as w, C as z, b0 as Q, D as j, b as q, a as J, bQ as $, a$ as aa, aS as _a, aO as Ea, c2 as Ta, c3 as Ia, bT as Na, bC as Sa, ab as sa, bW as Aa, b$ as Oa, b5 as ea, aF as Ga, bb as Ca, F as Da, a5 as Pa, a4 as Ra, h as ta, $ as La, b2 as Ma, aQ as oa, aM as ba, a1 as ra, G as Fa, I as na, H as Ba, a7 as ga, bz as la, b6 as ia, b7 as Ya, bx as Ua, bd as ca, bf as da, b1 as Ha, L as ua, aE as ya, bk as Ka, aK as pa, bj as ka, ao as Va, a9 as Xa, bR as ma, c0 as va, c1 as ha, aT as Wa, N as xa, aw as fa, av as Za, ax as wa, ar as za, as as Qa, au as ja, b9 as qa, bg as Ja, b3 as $a, n as a_, ah as __, ai as E_, ae as T_, af as I_, ac as N_, a2 as S_, l as s_, bl as A_, al as O_, bD as e_, bE as G_, bP as C_, aa as D_, bB as P_, bm as R_, m as t_, S as L_, P as M_, aD as o_, bA as b_, ba as r_, bs as F_, br as n_, bu as B_, bp as g_, bv as l_, bw as i_, bq as Y_, bt as U_, ay as c_, az as d_, bi as H_, bh as u_, aB as y_, aC as K_, aH as p_, aX as k_, aG as V_, aI as X_, U as m_, a8 as v_, aL as h_, k as W_, b8 as x_, ak as f_, b4 as Z_, bc as w_, be as z_, a_ as Q_, M as j_, a0 as q_, g as J_, bO as $_, q as aE, J as _E, W as EE, aA as TE, aJ as IE, ap as NE, o as SE, T as sE, r as AE, u as OE, i as eE, aq as GE, c as CE, p as DE, t as PE, R as RE, K as tE, s as LE, V as ME, y as oE, v as bE, w as rE, Q as FE, z as nE, O as BE, A as gE, E as lE, x as iE } from "./lib-29h6IPue.js";
1
+ import { by as E, an as T, aP as I, a3 as N, ag as S, ad as s, bo as A, bF as O, c6 as e, c5 as G, c4 as C, b_ as D, aZ as P, aY as R, bK as t, bL as L, bS as M, bH as o, bJ as b, bI as r, bM as F, bN as n, bZ as B, bX as g, am as l, bY as i, a6 as Y, aU as U, aW as c, aV as d, e as H, f as u, B as y, Y as K, d as p, Z as k, j as V, aj as X, X as m, bn as v, bG as h, at as W, aR as x, aN as f, bV as Z, bU as w, C as z, b0 as Q, D as j, b as q, a as J, bQ as $, a$ as aa, aS as _a, aO as Ea, c2 as Ta, c3 as Ia, bT as Na, bC as Sa, ab as sa, bW as Aa, b$ as Oa, b5 as ea, aF as Ga, bb as Ca, F as Da, a5 as Pa, a4 as Ra, h as ta, $ as La, b2 as Ma, aQ as oa, aM as ba, a1 as ra, G as Fa, I as na, H as Ba, a7 as ga, bz as la, b6 as ia, b7 as Ya, bx as Ua, bd as ca, bf as da, b1 as Ha, L as ua, aE as ya, bk as Ka, aK as pa, bj as ka, ao as Va, a9 as Xa, bR as ma, c0 as va, c1 as ha, aT as Wa, N as xa, aw as fa, av as Za, ax as wa, ar as za, as as Qa, au as ja, b9 as qa, bg as Ja, b3 as $a, n as a_, ah as __, ai as E_, ae as T_, af as I_, ac as N_, a2 as S_, l as s_, bl as A_, al as O_, bD as e_, bE as G_, bP as C_, aa as D_, bB as P_, bm as R_, m as t_, S as L_, P as M_, aD as o_, bA as b_, ba as r_, bs as F_, br as n_, bu as B_, bp as g_, bv as l_, bw as i_, bq as Y_, bt as U_, ay as c_, az as d_, bi as H_, bh as u_, aB as y_, aC as K_, aH as p_, aX as k_, aG as V_, aI as X_, U as m_, a8 as v_, aL as h_, k as W_, b8 as x_, ak as f_, b4 as Z_, bc as w_, be as z_, a_ as Q_, M as j_, a0 as q_, g as J_, bO as $_, q as aE, J as _E, W as EE, aA as TE, aJ as IE, ap as NE, o as SE, T as sE, r as AE, u as OE, i as eE, aq as GE, c as CE, p as DE, t as PE, R as RE, K as tE, s as LE, V as ME, y as oE, v as bE, w as rE, Q as FE, z as nE, O as BE, A as gE, E as lE, x as iE } from "./lib-na3Nl6DE.js";
2
2
  import { createPinia as UE, setActivePinia as cE } from "pinia";
3
3
  export {
4
4
  E as ABOUT_SECTION_SETTINGS_CONFIG,