@designcrowd/library.brand-page 5.13.2-jj1 → 5.13.2-jj3
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-BKGkOvyZ.js → CreatedOnBrandCrowd-de-de-CeEHfqaI.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-en-us-C2NclCLk.js → CreatedOnBrandCrowd-en-us-CE7ZxGyI.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-es-es-BjgIo0qO.js → CreatedOnBrandCrowd-es-es-CrSMpcLT.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-fr-CY76mxeL.js → CreatedOnBrandCrowd-fr-fr-CUj3WxaT.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-pt-D9IHklTY.js → CreatedOnBrandCrowd-pt-pt-Dt_J16X6.js} +1 -1
- package/lib/src/{CreatedOnDcom-de-de-YyALNsha.js → CreatedOnDcom-de-de-Cw8IRb5V.js} +1 -1
- package/lib/src/{CreatedOnDcom-en-us-DSL2fgC6.js → CreatedOnDcom-en-us-CrrzoBU7.js} +1 -1
- package/lib/src/{CreatedOnDcom-es-es-DH392fCn.js → CreatedOnDcom-es-es-C9JUdGHw.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-fr-NPk8aqjH.js → CreatedOnDcom-fr-fr-CyFR7MQl.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-pt-DULHuIiy.js → CreatedOnDcom-pt-pt-DLebp2Wn.js} +1 -1
- package/lib/src/brand-page/utils/migration/migration-01.d.ts +1 -2
- package/lib/src/brand-page/utils/migration/migration-01.js +0 -2
- package/lib/src/brand-page/utils/migration/migration-01_1.d.ts +4 -0
- package/lib/src/brand-page/utils/migration/migration-01_1.js +5 -0
- package/lib/src/brand-page/utils/migration/{migration-051.d.ts → migration-05_1.d.ts} +1 -1
- package/lib/src/brand-page/utils/migration/{migration-051.js → migration-05_1.js} +1 -1
- package/lib/src/brand-page/utils/migration.util.js +10 -3
- package/lib/src/brand-page-maker/constants/index.d.ts +4 -4
- package/lib/src/brand-page-maker/constants/index.js +4 -4
- package/lib/src/clients/media-client.js +2 -2
- package/lib/src/index.mjs +1 -1
- package/lib/src/{lib-TCOUpkVv.js → lib-29h6IPue.js} +4260 -4254
- package/package.json +1 -1
- package/src/brand-page/utils/migration/migration-01.ts +0 -4
- package/src/brand-page/utils/migration/migration-01_1.ts +14 -0
- package/src/brand-page/utils/migration/{migration-051.ts → migration-05_1.ts} +1 -1
- package/src/brand-page/utils/migration.util.ts +11 -3
- package/src/brand-page-maker/constants/index.ts +4 -4
- package/src/clients/media-client.js +2 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { BrandPageModel
|
|
1
|
+
import type { BrandPageModel } 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,6 +18,5 @@ 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;
|
|
22
21
|
isUserDraft: boolean;
|
|
23
22
|
}) => BrandPageModel;
|
|
@@ -3,7 +3,6 @@ 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';
|
|
7
6
|
export const applyTextContentTextToTextItemsMigration = (brandPageModel) => {
|
|
8
7
|
const textContents = brandPageModel.pages.reduce((acc, cur) => {
|
|
9
8
|
return [...acc, ...cur.contents.filter(isTextContent)];
|
|
@@ -889,6 +888,5 @@ export const migration01 = (brandPageModel, options) => {
|
|
|
889
888
|
migrateGlobalTextStylesToHaveMissingStyles(brandPageModel);
|
|
890
889
|
migrateConvertLineHeightOnNavigationStyles(brandPageModel);
|
|
891
890
|
migrateConvertLineHeightOnFooterStyles(brandPageModel);
|
|
892
|
-
migrateLogoImage(brandPageModel, options.logoImage);
|
|
893
891
|
return brandPageModel;
|
|
894
892
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import {} from '../..';
|
|
2
|
-
export const
|
|
2
|
+
export const migration05_1 = (brandPageModel, options) => {
|
|
3
3
|
if (!options.isUserDraft) {
|
|
4
4
|
brandPageModel.pageFooterDesktop?.socialLinks?.forEach((link) => {
|
|
5
5
|
if (link.imageUrl === 'twitter') {
|
|
@@ -1,16 +1,23 @@
|
|
|
1
1
|
import {} from '../models';
|
|
2
2
|
import { migration01 } from './migration/migration-01';
|
|
3
|
+
import { migration01_1 } from './migration/migration-01_1';
|
|
3
4
|
import { migration02 } from './migration/migration-02';
|
|
4
5
|
import { migration03 } from './migration/migration-03';
|
|
5
6
|
import { migration04 } from './migration/migration-04';
|
|
6
7
|
import { migration05 } from './migration/migration-05';
|
|
7
|
-
import {
|
|
8
|
+
import { migration05_1 } from './migration/migration-05_1';
|
|
8
9
|
const MIGRATION_TABLE = [
|
|
9
10
|
{
|
|
10
11
|
version: 1,
|
|
11
12
|
migrateFn: migration01,
|
|
12
13
|
description: 'Legacy migration',
|
|
13
14
|
},
|
|
15
|
+
{
|
|
16
|
+
version: 1.1,
|
|
17
|
+
migrateFn: migration01_1,
|
|
18
|
+
description: 'When loading template assign logo to the metadata',
|
|
19
|
+
runAlways: true,
|
|
20
|
+
},
|
|
14
21
|
{
|
|
15
22
|
version: 2,
|
|
16
23
|
migrateFn: migration02,
|
|
@@ -33,7 +40,7 @@ const MIGRATION_TABLE = [
|
|
|
33
40
|
},
|
|
34
41
|
{
|
|
35
42
|
version: 5.1,
|
|
36
|
-
migrateFn:
|
|
43
|
+
migrateFn: migration05_1,
|
|
37
44
|
description: 'Migrating twitter icon and url to x icon and x.com',
|
|
38
45
|
},
|
|
39
46
|
];
|
|
@@ -44,7 +51,7 @@ export const migrateBrandPageModel = (brandPageModel, options) => {
|
|
|
44
51
|
modelVersion = 0;
|
|
45
52
|
}
|
|
46
53
|
MIGRATION_TABLE.forEach((x) => {
|
|
47
|
-
if (modelVersion < x.version) {
|
|
54
|
+
if (x.runAlways || modelVersion < x.version) {
|
|
48
55
|
brandPageModel = x.migrateFn(brandPageModel, options);
|
|
49
56
|
}
|
|
50
57
|
});
|
|
@@ -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/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";
|
|
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";
|
|
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/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';
|
|
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';
|
|
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`;
|
|
@@ -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/media/GetPaginatedAdminMedia?skip=${skip}&take=${take}&videoOnly=${videoOnly}`;
|
|
27
|
-
uploadAdminMediaEndpoint = () => `${this.options.mediaBaseUrl}/maker/media/upload`;
|
|
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`;
|
|
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-
|
|
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";
|
|
2
2
|
import { createPinia as UE, setActivePinia as cE } from "pinia";
|
|
3
3
|
export {
|
|
4
4
|
E as ABOUT_SECTION_SETTINGS_CONFIG,
|