@burdenoff/microfe-headshotmarketing 2026.704.4 → 2026.704.5
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/dist/generated/wspace-operations.js +118 -111
- package/dist/generated/wspace-operations.js.map +1 -1
- package/dist/generated/wspace-types.js +27 -19
- package/dist/generated/wspace-types.js.map +1 -1
- package/dist/headshotmarketing/components/Toast.js +56 -2
- package/dist/headshotmarketing/components/Toast.js.map +1 -0
- package/dist/headshotmarketing/pages/HomeFunnel.js +54 -0
- package/dist/headshotmarketing/pages/HomeFunnel.js.map +1 -0
- package/dist/headshotmarketing/pages/HomePage.js +423 -259
- package/dist/headshotmarketing/pages/HomePage.js.map +1 -1
- package/dist/headshotmarketing/pages/HomeStatCard.js +79 -0
- package/dist/headshotmarketing/pages/HomeStatCard.js.map +1 -0
- package/dist/headshotmarketing/pages/ads/AdPlatformChips.js +93 -0
- package/dist/headshotmarketing/pages/ads/AdPlatformChips.js.map +1 -0
- package/dist/headshotmarketing/pages/ads/CreateAdCampaignPage.js +452 -390
- package/dist/headshotmarketing/pages/ads/CreateAdCampaignPage.js.map +1 -1
- package/dist/headshotmarketing/pages/analytics/ReportsPage.js +405 -115
- package/dist/headshotmarketing/pages/analytics/ReportsPage.js.map +1 -1
- package/dist/headshotmarketing/pages/automation/WorkflowBuilderPage.js +565 -345
- package/dist/headshotmarketing/pages/automation/WorkflowBuilderPage.js.map +1 -1
- package/dist/headshotmarketing/pages/automation/WorkflowCanvasNode.js +107 -0
- package/dist/headshotmarketing/pages/automation/WorkflowCanvasNode.js.map +1 -0
- package/dist/headshotmarketing/pages/automation/WorkflowNodeConfigPanel.js +213 -0
- package/dist/headshotmarketing/pages/automation/WorkflowNodeConfigPanel.js.map +1 -0
- package/dist/headshotmarketing/pages/automation/workflowBuilderModel.js +150 -0
- package/dist/headshotmarketing/pages/automation/workflowBuilderModel.js.map +1 -0
- package/dist/headshotmarketing/pages/builder/LandingPageBuilderPage.js +380 -371
- package/dist/headshotmarketing/pages/builder/LandingPageBuilderPage.js.map +1 -1
- package/dist/headshotmarketing/pages/builder/SectionCanvasBlock.js +92 -0
- package/dist/headshotmarketing/pages/builder/SectionCanvasBlock.js.map +1 -0
- package/dist/headshotmarketing/pages/builder/SectionContent.js +346 -0
- package/dist/headshotmarketing/pages/builder/SectionContent.js.map +1 -0
- package/dist/headshotmarketing/pages/builder/SectionInspector.js +358 -0
- package/dist/headshotmarketing/pages/builder/SectionInspector.js.map +1 -0
- package/dist/headshotmarketing/pages/builder/builderCatalog.js +274 -0
- package/dist/headshotmarketing/pages/builder/builderCatalog.js.map +1 -0
- package/dist/headshotmarketing/pages/content/AIToolsPage.js +479 -193
- package/dist/headshotmarketing/pages/content/AIToolsPage.js.map +1 -1
- package/dist/headshotmarketing/pages/content/AssetLibraryPage.js +492 -197
- package/dist/headshotmarketing/pages/content/AssetLibraryPage.js.map +1 -1
- package/dist/headshotmarketing/pages/content/AssetThumbnail.js +37 -0
- package/dist/headshotmarketing/pages/content/AssetThumbnail.js.map +1 -0
- package/dist/headshotmarketing/pages/content/ContentCreationPage.js +672 -219
- package/dist/headshotmarketing/pages/content/ContentCreationPage.js.map +1 -1
- package/dist/headshotmarketing/pages/content/ContentLibraryCard.js +200 -0
- package/dist/headshotmarketing/pages/content/ContentLibraryCard.js.map +1 -0
- package/dist/headshotmarketing/pages/content/ContentPage.js +224 -204
- package/dist/headshotmarketing/pages/content/ContentPage.js.map +1 -1
- package/dist/headshotmarketing/pages/content/ContentSubNav.js +51 -0
- package/dist/headshotmarketing/pages/content/ContentSubNav.js.map +1 -0
- package/dist/headshotmarketing/pages/crm/LeadsPage.js +250 -131
- package/dist/headshotmarketing/pages/crm/LeadsPage.js.map +1 -1
- package/dist/headshotmarketing/pages/crm/LeadsWidgets.js +179 -0
- package/dist/headshotmarketing/pages/crm/LeadsWidgets.js.map +1 -0
- package/dist/headshotmarketing/pages/events/CreateEventPage.js +631 -379
- package/dist/headshotmarketing/pages/events/CreateEventPage.js.map +1 -1
- package/dist/headshotmarketing/pages/events/EventImageUpload.js +123 -0
- package/dist/headshotmarketing/pages/events/EventImageUpload.js.map +1 -0
- package/dist/headshotmarketing/pages/events/EventPagePreview.js +99 -0
- package/dist/headshotmarketing/pages/events/EventPagePreview.js.map +1 -0
- package/dist/headshotmarketing/pages/events/EventsPage.js +267 -228
- package/dist/headshotmarketing/pages/events/EventsPage.js.map +1 -1
- package/dist/headshotmarketing/pages/seo/SeoScoreGauge.js +50 -0
- package/dist/headshotmarketing/pages/seo/SeoScoreGauge.js.map +1 -0
- package/dist/headshotmarketing/pages/seo/SeoScorePanel.js +147 -0
- package/dist/headshotmarketing/pages/seo/SeoScorePanel.js.map +1 -0
- package/dist/headshotmarketing/pages/seo/SeoToolsPage.js +562 -419
- package/dist/headshotmarketing/pages/seo/SeoToolsPage.js.map +1 -1
- package/dist/headshotmarketing/pages/social-media/MediaDropZone.js +108 -0
- package/dist/headshotmarketing/pages/social-media/MediaDropZone.js.map +1 -0
- package/dist/headshotmarketing/pages/social-media/SocialComposerPreview.js +100 -0
- package/dist/headshotmarketing/pages/social-media/SocialComposerPreview.js.map +1 -0
- package/dist/headshotmarketing/pages/social-media/SocialMediaComposePage.js +315 -250
- package/dist/headshotmarketing/pages/social-media/SocialMediaComposePage.js.map +1 -1
- package/dist/headshotmarketing/pages/social-media/socialComposerMeta.js +60 -0
- package/dist/headshotmarketing/pages/social-media/socialComposerMeta.js.map +1 -0
- package/dist/headshotmarketing/utils/automationMapper.js +1 -1
- package/dist/headshotmarketing/utils/automationMapper.js.map +1 -1
- package/dist/headshotmarketing/utils/contentMapper.js +4 -24
- package/dist/headshotmarketing/utils/contentMapper.js.map +1 -1
- package/dist/headshotmarketing/utils/eventsMapper.js +9 -9
- package/dist/headshotmarketing/utils/eventsMapper.js.map +1 -1
- package/dist/headshotmarketing/utils/helpers.js +7 -4
- package/dist/headshotmarketing/utils/helpers.js.map +1 -1
- package/dist/headshotmarketing/utils/influencerMapper.js +1 -1
- package/dist/headshotmarketing/utils/influencerMapper.js.map +1 -1
- package/dist/node_modules/lodash/_arrayEach.js +14 -0
- package/dist/node_modules/lodash/_arrayEach.js.map +1 -0
- package/dist/node_modules/lodash/_assignValue.js +17 -0
- package/dist/node_modules/lodash/_assignValue.js.map +1 -0
- package/dist/node_modules/lodash/_baseAssign.js +16 -0
- package/dist/node_modules/lodash/_baseAssign.js.map +1 -0
- package/dist/node_modules/lodash/_baseAssignIn.js +16 -0
- package/dist/node_modules/lodash/_baseAssignIn.js.map +1 -0
- package/dist/node_modules/lodash/_baseClone.js +64 -0
- package/dist/node_modules/lodash/_baseClone.js.map +1 -0
- package/dist/node_modules/lodash/_baseCreate.js +21 -0
- package/dist/node_modules/lodash/_baseCreate.js.map +1 -0
- package/dist/node_modules/lodash/_baseIsMap.js +16 -0
- package/dist/node_modules/lodash/_baseIsMap.js.map +1 -0
- package/dist/node_modules/lodash/_baseIsSet.js +16 -0
- package/dist/node_modules/lodash/_baseIsSet.js.map +1 -0
- package/dist/node_modules/lodash/_baseKeysIn.js +20 -0
- package/dist/node_modules/lodash/_baseKeysIn.js.map +1 -0
- package/dist/node_modules/lodash/_baseUnset.js +26 -0
- package/dist/node_modules/lodash/_baseUnset.js.map +1 -0
- package/dist/node_modules/lodash/_cloneArrayBuffer.js +16 -0
- package/dist/node_modules/lodash/_cloneArrayBuffer.js.map +1 -0
- package/dist/node_modules/lodash/_cloneBuffer.js +17 -0
- package/dist/node_modules/lodash/_cloneBuffer.js.map +1 -0
- package/dist/node_modules/lodash/_cloneDataView.js +16 -0
- package/dist/node_modules/lodash/_cloneDataView.js.map +1 -0
- package/dist/node_modules/lodash/_cloneRegExp.js +15 -0
- package/dist/node_modules/lodash/_cloneRegExp.js.map +1 -0
- package/dist/node_modules/lodash/_cloneSymbol.js +15 -0
- package/dist/node_modules/lodash/_cloneSymbol.js.map +1 -0
- package/dist/node_modules/lodash/_cloneTypedArray.js +16 -0
- package/dist/node_modules/lodash/_cloneTypedArray.js.map +1 -0
- package/dist/node_modules/lodash/_copyArray.js +15 -0
- package/dist/node_modules/lodash/_copyArray.js.map +1 -0
- package/dist/node_modules/lodash/_copyObject.js +22 -0
- package/dist/node_modules/lodash/_copyObject.js.map +1 -0
- package/dist/node_modules/lodash/_copySymbols.js +16 -0
- package/dist/node_modules/lodash/_copySymbols.js.map +1 -0
- package/dist/node_modules/lodash/_copySymbolsIn.js +16 -0
- package/dist/node_modules/lodash/_copySymbolsIn.js.map +1 -0
- package/dist/node_modules/lodash/_customOmitClone.js +15 -0
- package/dist/node_modules/lodash/_customOmitClone.js.map +1 -0
- package/dist/node_modules/lodash/_flatRest.js +17 -0
- package/dist/node_modules/lodash/_flatRest.js.map +1 -0
- package/dist/node_modules/lodash/_getAllKeysIn.js +17 -0
- package/dist/node_modules/lodash/_getAllKeysIn.js.map +1 -0
- package/dist/node_modules/lodash/_getSymbolsIn.js +18 -0
- package/dist/node_modules/lodash/_getSymbolsIn.js.map +1 -0
- package/dist/node_modules/lodash/_initCloneArray.js +15 -0
- package/dist/node_modules/lodash/_initCloneArray.js.map +1 -0
- package/dist/node_modules/lodash/_initCloneByTag.js +40 -0
- package/dist/node_modules/lodash/_initCloneByTag.js.map +1 -0
- package/dist/node_modules/lodash/_initCloneObject.js +17 -0
- package/dist/node_modules/lodash/_initCloneObject.js.map +1 -0
- package/dist/node_modules/lodash/_nativeKeysIn.js +15 -0
- package/dist/node_modules/lodash/_nativeKeysIn.js.map +1 -0
- package/dist/node_modules/lodash/_parent.js +16 -0
- package/dist/node_modules/lodash/_parent.js.map +1 -0
- package/dist/node_modules/lodash/flatten.js +15 -0
- package/dist/node_modules/lodash/flatten.js.map +1 -0
- package/dist/node_modules/lodash/isMap.js +14 -0
- package/dist/node_modules/lodash/isMap.js.map +1 -0
- package/dist/node_modules/lodash/isSet.js +14 -0
- package/dist/node_modules/lodash/isSet.js.map +1 -0
- package/dist/node_modules/lodash/keysIn.js +17 -0
- package/dist/node_modules/lodash/keysIn.js.map +1 -0
- package/dist/node_modules/lodash/omit.js +28 -0
- package/dist/node_modules/lodash/omit.js.map +1 -0
- package/dist/node_modules/recharts/es6/chart/FunnelChart.js +15 -0
- package/dist/node_modules/recharts/es6/chart/FunnelChart.js.map +1 -0
- package/dist/node_modules/recharts/es6/numberAxis/Funnel.js +370 -0
- package/dist/node_modules/recharts/es6/numberAxis/Funnel.js.map +1 -0
- package/dist/node_modules/recharts/es6/util/ActiveShapeUtils.js +1 -1
- package/dist/node_modules/recharts/es6/util/FunnelUtils.js +81 -0
- package/dist/node_modules/recharts/es6/util/FunnelUtils.js.map +1 -0
- package/package.json +1 -1
|
@@ -5,77 +5,81 @@ import { PageLayout as a } from "../../components/PageLayout.js";
|
|
|
5
5
|
import { Modal as ee } from "../../components/Modal.js";
|
|
6
6
|
import { QueryStateBoundary as te } from "../../components/QueryStateBoundary.js";
|
|
7
7
|
import "../../components/index.js";
|
|
8
|
-
import { useHeadshotmarketingBootstrap as
|
|
8
|
+
import { useHeadshotmarketingBootstrap as ne } from "../../hooks/useHeadshotmarketingBootstrap.js";
|
|
9
9
|
import "../../hooks/index.js";
|
|
10
|
-
import { toBuilderSectionsFromLandingPage as
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
10
|
+
import { toBuilderSectionsFromLandingPage as re, toBuilderTemplateModel as ie } from "../../utils/builderMapper.js";
|
|
11
|
+
import { SECTION_CATALOG as ae, SectionThumbnail as oe, defaultConfig as o, sectionLabelFor as s } from "./builderCatalog.js";
|
|
12
|
+
import { SectionContent as se } from "./SectionContent.js";
|
|
13
|
+
import { SectionCanvasBlock as ce } from "./SectionCanvasBlock.js";
|
|
14
|
+
import { SectionInspector as le } from "./SectionInspector.js";
|
|
15
|
+
import { useEffect as ue, useMemo as c, useState as l } from "react";
|
|
16
|
+
import { ArrowLeft as de, Edit3 as fe, ExternalLink as u, Eye as pe, Globe as me, Layers as he, LayoutTemplate as ge, Monitor as _e, MousePointerClick as ve, Plus as d, Save as ye, Smartphone as be, Tablet as xe } from "lucide-react";
|
|
17
|
+
import { Fragment as Se, jsx as f, jsxs as p } from "react/jsx-runtime";
|
|
18
|
+
import { PagePurpose as Ce } from "@burdenoff/fe-libs/ui";
|
|
15
19
|
//#region src/headshotmarketing/pages/builder/LandingPageBuilderPage.tsx
|
|
16
|
-
var x =
|
|
17
|
-
header: m,
|
|
18
|
-
hero: p,
|
|
19
|
-
features: u,
|
|
20
|
-
testimonials: g,
|
|
21
|
-
cta: h,
|
|
22
|
-
footer: m,
|
|
23
|
-
pricing: _,
|
|
24
|
-
faq: _,
|
|
25
|
-
gallery: p,
|
|
26
|
-
contact: _
|
|
27
|
-
}, ve = [
|
|
20
|
+
var m = "application/x-hm-palette", h = "application/x-hm-reorder", we = [
|
|
28
21
|
"header",
|
|
29
22
|
"hero",
|
|
30
23
|
"features",
|
|
31
24
|
"testimonials",
|
|
32
25
|
"cta",
|
|
33
26
|
"footer"
|
|
34
|
-
];
|
|
35
|
-
function
|
|
27
|
+
], g = 0;
|
|
28
|
+
function _() {
|
|
29
|
+
return g += 1, `sec-${Date.now().toString(36)}-${g}`;
|
|
30
|
+
}
|
|
31
|
+
function v(e) {
|
|
32
|
+
return {
|
|
33
|
+
id: _(),
|
|
34
|
+
type: e,
|
|
35
|
+
label: s(e),
|
|
36
|
+
config: o()
|
|
37
|
+
};
|
|
38
|
+
}
|
|
39
|
+
function y(e) {
|
|
36
40
|
return e.trim().toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-+|-+$/g, "") || "landing-page";
|
|
37
41
|
}
|
|
38
|
-
function
|
|
42
|
+
function b(e) {
|
|
39
43
|
return Array.isArray(e) && e.every((e) => typeof e == "object" && !!e && typeof e.type == "string");
|
|
40
44
|
}
|
|
41
|
-
function
|
|
45
|
+
function x(e) {
|
|
42
46
|
let t = e?.builderLayout;
|
|
43
|
-
return !
|
|
47
|
+
return !b(t) || t.length === 0 ? null : t.map((e, t) => ({
|
|
44
48
|
id: typeof e.id == "string" ? e.id : `sec-${t}`,
|
|
45
49
|
type: e.type,
|
|
46
|
-
label: typeof e.label == "string" ? e.label :
|
|
50
|
+
label: typeof e.label == "string" ? e.label : s(e.type),
|
|
47
51
|
config: typeof e.config == "object" && e.config !== null ? e.config : {}
|
|
48
52
|
}));
|
|
49
53
|
}
|
|
50
|
-
var
|
|
51
|
-
let { navigate:
|
|
52
|
-
let e =
|
|
54
|
+
var S = () => {
|
|
55
|
+
let { navigate: o, basePath: s } = r(), { data: g, loading: b, error: S, refetch: C } = ne(), w = (g?.headshotmarketingLandingPages.items ?? [])[0], [Te, { loading: Ee }] = e(), [De, { loading: Oe }] = n(), [ke, { loading: T }] = t(), [E, D] = l(w?.id ?? null), [O, k] = l(w?.status ?? "DRAFT"), [A, j] = l(w?.publishedUrl ?? null), [M, N] = l(w?.title ?? "Landing Page"), [Ae, P] = l(w?.slug ?? ""), [F, I] = l(w?.templateId ?? null), [L, je] = l("desktop"), [R, z] = l(null), [Me, B] = l(!1), [V, H] = l(null), [Ne, U] = l(null), [Pe, W] = l(null), [Fe, G] = l(null), [K, Ie] = l(null), Le = Pe !== null || Fe !== null, [q, J] = l(c(() => {
|
|
56
|
+
let e = x(w?.metadata);
|
|
53
57
|
if (e) return e;
|
|
54
|
-
let t =
|
|
58
|
+
let t = re(w);
|
|
55
59
|
return t.length > 0 ? t.map((e) => ({ ...e })) : [{
|
|
56
60
|
id: "default-hero",
|
|
57
61
|
type: "hero",
|
|
58
62
|
label: "Hero",
|
|
59
63
|
config: {}
|
|
60
64
|
}];
|
|
61
|
-
}, [
|
|
62
|
-
|
|
63
|
-
if (!
|
|
64
|
-
|
|
65
|
-
let e =
|
|
65
|
+
}, [w])), Re = (g?.headshotmarketingCampaignTemplates.items ?? []).map((e) => ie(e));
|
|
66
|
+
ue(() => {
|
|
67
|
+
if (!w) return;
|
|
68
|
+
D(w.id), k(w.status), j(w.publishedUrl ?? null), N(w.title), P(w.slug), I(w.templateId ?? null);
|
|
69
|
+
let e = x(w.metadata);
|
|
66
70
|
if (e) {
|
|
67
|
-
|
|
71
|
+
J(e);
|
|
68
72
|
return;
|
|
69
73
|
}
|
|
70
|
-
let t =
|
|
71
|
-
t.length > 0 &&
|
|
72
|
-
}, [
|
|
73
|
-
let
|
|
74
|
+
let t = re(w);
|
|
75
|
+
t.length > 0 && J(t.map((e) => ({ ...e })));
|
|
76
|
+
}, [w]);
|
|
77
|
+
let ze = {
|
|
74
78
|
desktop: "w-full",
|
|
75
79
|
tablet: "max-w-[768px]",
|
|
76
|
-
mobile: "max-w-[
|
|
77
|
-
},
|
|
78
|
-
|
|
80
|
+
mobile: "max-w-[390px]"
|
|
81
|
+
}, Y = c(() => q.find((e) => e.id === R) ?? null, [q, R]), Be = (e, t) => {
|
|
82
|
+
J((n) => {
|
|
79
83
|
let r = n.findIndex((t) => t.id === e);
|
|
80
84
|
if (r === -1) return n;
|
|
81
85
|
let i = t === "up" ? r - 1 : r + 1;
|
|
@@ -83,412 +87,417 @@ var w = () => {
|
|
|
83
87
|
let a = [...n];
|
|
84
88
|
return [a[r], a[i]] = [a[i], a[r]], a;
|
|
85
89
|
});
|
|
86
|
-
},
|
|
87
|
-
|
|
88
|
-
},
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
},
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
90
|
+
}, Ve = (e) => {
|
|
91
|
+
J((t) => t.filter((t) => t.id !== e)), R === e && z(null);
|
|
92
|
+
}, He = (e) => {
|
|
93
|
+
J((t) => {
|
|
94
|
+
let n = t.findIndex((t) => t.id === e);
|
|
95
|
+
if (n === -1) return t;
|
|
96
|
+
let r = {
|
|
97
|
+
...t[n],
|
|
98
|
+
id: _(),
|
|
99
|
+
label: `${t[n].label} copy`,
|
|
100
|
+
config: { ...t[n].config }
|
|
101
|
+
}, i = [...t];
|
|
102
|
+
return i.splice(n + 1, 0, r), z(r.id), i;
|
|
103
|
+
});
|
|
104
|
+
}, Ue = (e) => {
|
|
105
|
+
let t = v(e);
|
|
106
|
+
J((e) => [...e, t]), z(t.id);
|
|
107
|
+
}, We = (e, t) => {
|
|
108
|
+
let n = v(e);
|
|
109
|
+
J((e) => {
|
|
110
|
+
let r = [...e];
|
|
111
|
+
return r.splice(Math.min(Math.max(t, 0), r.length), 0, n), r;
|
|
112
|
+
}), z(n.id);
|
|
113
|
+
}, Ge = (e, t) => {
|
|
114
|
+
J((n) => {
|
|
115
|
+
let r = n.findIndex((t) => t.id === e);
|
|
116
|
+
if (r === -1) return n;
|
|
117
|
+
let i = [...n], [a] = i.splice(r, 1), ee = r < t ? t - 1 : t;
|
|
118
|
+
return i.splice(Math.min(Math.max(ee, 0), i.length), 0, a), i;
|
|
119
|
+
});
|
|
120
|
+
}, Ke = (e, t) => {
|
|
121
|
+
J((n) => n.map((n) => n.id === e ? {
|
|
122
|
+
...n,
|
|
123
|
+
config: {
|
|
124
|
+
...n.config,
|
|
125
|
+
...t
|
|
126
|
+
}
|
|
127
|
+
} : n));
|
|
128
|
+
}, qe = (e, t) => {
|
|
129
|
+
J((n) => n.map((n) => n.id === e ? {
|
|
130
|
+
...n,
|
|
131
|
+
label: t
|
|
132
|
+
} : n));
|
|
133
|
+
}, Je = (e) => (t) => {
|
|
134
|
+
t.dataTransfer.effectAllowed = "copy", t.dataTransfer.setData(m, e), G(e), W(null);
|
|
135
|
+
}, Ye = (e) => (t) => {
|
|
136
|
+
t.dataTransfer.effectAllowed = "move", t.dataTransfer.setData(h, e), W(e), G(null);
|
|
137
|
+
}, X = () => {
|
|
138
|
+
W(null), G(null), Ie(null);
|
|
139
|
+
}, Z = (e) => (t) => {
|
|
140
|
+
let n = t.dataTransfer.types, r = n.includes(h), i = n.includes(m);
|
|
141
|
+
!r && !i || (t.preventDefault(), t.dataTransfer.dropEffect = r ? "move" : "copy", Ie(e));
|
|
142
|
+
}, Q = (e) => (t) => {
|
|
143
|
+
t.preventDefault();
|
|
144
|
+
let n = t.dataTransfer.getData(m), r = t.dataTransfer.getData(h);
|
|
145
|
+
n ? We(n, e) : r && Ge(r, e), X();
|
|
146
|
+
}, Xe = (e) => {
|
|
147
|
+
N(e.name), I(e.id), J(we.map((e) => v(e))), z(null), U(`Applied "${e.name}" template — Save to keep it.`);
|
|
148
|
+
}, Ze = () => ({
|
|
149
|
+
...w?.metadata ?? {},
|
|
150
|
+
builderLayout: q
|
|
151
|
+
}), Qe = async () => {
|
|
152
|
+
if (!M.trim()) return H("Page name is required."), null;
|
|
119
153
|
H(null);
|
|
120
154
|
try {
|
|
121
|
-
if (
|
|
122
|
-
let e = (await
|
|
123
|
-
id:
|
|
155
|
+
if (E) {
|
|
156
|
+
let e = (await De({ variables: {
|
|
157
|
+
id: E,
|
|
124
158
|
input: {
|
|
125
|
-
title:
|
|
159
|
+
title: M.trim(),
|
|
126
160
|
templateId: F ?? void 0,
|
|
127
|
-
metadata:
|
|
161
|
+
metadata: Ze()
|
|
128
162
|
}
|
|
129
163
|
} })).data?.headshotmarketingUpdateLandingPage;
|
|
130
|
-
return e && (
|
|
164
|
+
return e && (k(e.status), j(e.publishedUrl ?? null)), E;
|
|
131
165
|
}
|
|
132
|
-
let e = (await
|
|
133
|
-
title:
|
|
134
|
-
slug: `${
|
|
166
|
+
let e = (await Te({ variables: { input: {
|
|
167
|
+
title: M.trim(),
|
|
168
|
+
slug: `${y(M)}-${Date.now().toString(36)}`,
|
|
135
169
|
templateId: F ?? void 0,
|
|
136
|
-
metadata:
|
|
170
|
+
metadata: Ze()
|
|
137
171
|
} } })).data?.headshotmarketingCreateLandingPage;
|
|
138
|
-
return e ? (
|
|
172
|
+
return e ? (D(e.id), k(e.status), j(e.publishedUrl ?? null), P(e.slug), e.id) : (H("Failed to create landing page."), null);
|
|
139
173
|
} catch (e) {
|
|
140
174
|
return H(e instanceof Error ? e.message : "Failed to save landing page."), null;
|
|
141
175
|
}
|
|
142
|
-
},
|
|
143
|
-
await
|
|
144
|
-
},
|
|
145
|
-
let e = await
|
|
176
|
+
}, $e = async () => {
|
|
177
|
+
await Qe() && (U("Landing page saved."), C());
|
|
178
|
+
}, et = async () => {
|
|
179
|
+
let e = await Qe();
|
|
146
180
|
if (e) try {
|
|
147
|
-
let t = (await
|
|
148
|
-
t && (
|
|
181
|
+
let t = (await ke({ variables: { id: e } })).data?.headshotmarketingPublishLandingPage;
|
|
182
|
+
t && (k(t.status), j(t.publishedUrl ?? null), U("Landing page published."), t.publishedUrl && window.open(t.publishedUrl, "_blank", "noopener,noreferrer")), C();
|
|
149
183
|
} catch (e) {
|
|
150
184
|
H(e instanceof Error ? e.message : "Failed to publish landing page.");
|
|
151
185
|
}
|
|
152
|
-
},
|
|
153
|
-
|
|
154
|
-
children: [
|
|
155
|
-
/* @__PURE__ */ v("p", {
|
|
156
|
-
className: "text-lg font-bold text-text-primary",
|
|
157
|
-
children: e.config.headline || "Your Headline Here"
|
|
158
|
-
}),
|
|
159
|
-
/* @__PURE__ */ v("p", {
|
|
160
|
-
className: "text-xs text-text-secondary mt-1",
|
|
161
|
-
children: e.config.subheadline || "Subheadline text"
|
|
162
|
-
}),
|
|
163
|
-
/* @__PURE__ */ v("div", {
|
|
164
|
-
className: "mt-2",
|
|
165
|
-
children: /* @__PURE__ */ v("span", {
|
|
166
|
-
className: "inline-block bg-action-primary-bg text-action-primary-text text-xs px-3 py-1 rounded-md",
|
|
167
|
-
children: e.config.cta || "Call to Action"
|
|
168
|
-
})
|
|
169
|
-
})
|
|
170
|
-
]
|
|
171
|
-
}) : e.type === "features" ? /* @__PURE__ */ v("div", {
|
|
172
|
-
className: "grid grid-cols-3 gap-2",
|
|
173
|
-
children: (e.config.items || [
|
|
174
|
-
"Feature 1",
|
|
175
|
-
"Feature 2",
|
|
176
|
-
"Feature 3"
|
|
177
|
-
]).map((e, t) => /* @__PURE__ */ v("div", {
|
|
178
|
-
className: "rounded-md bg-bg-sunken/50 p-2 text-center text-xs text-text-secondary",
|
|
179
|
-
children: e
|
|
180
|
-
}, t))
|
|
181
|
-
}) : e.type === "header" ? /* @__PURE__ */ y("div", {
|
|
182
|
-
className: "flex items-center justify-between rounded-md bg-bg-sunken/50 p-2",
|
|
183
|
-
children: [
|
|
184
|
-
/* @__PURE__ */ v("span", {
|
|
185
|
-
className: "text-xs font-medium text-text-secondary",
|
|
186
|
-
children: "Logo"
|
|
187
|
-
}),
|
|
188
|
-
/* @__PURE__ */ y("div", {
|
|
189
|
-
className: "flex gap-2 text-xs text-text-secondary",
|
|
190
|
-
children: [
|
|
191
|
-
/* @__PURE__ */ v("span", { children: "Nav 1" }),
|
|
192
|
-
/* @__PURE__ */ v("span", { children: "Nav 2" }),
|
|
193
|
-
/* @__PURE__ */ v("span", { children: "Nav 3" })
|
|
194
|
-
]
|
|
195
|
-
}),
|
|
196
|
-
/* @__PURE__ */ v("span", {
|
|
197
|
-
className: "text-xs bg-action-primary-bg/20 text-primary px-2 py-0.5 rounded-md",
|
|
198
|
-
children: e.config.cta || "CTA"
|
|
199
|
-
})
|
|
200
|
-
]
|
|
201
|
-
}) : e.type === "testimonials" ? /* @__PURE__ */ v("div", {
|
|
202
|
-
className: "flex gap-2",
|
|
203
|
-
children: Array.from({ length: e.config.count || 3 }).map((e, t) => /* @__PURE__ */ y("div", {
|
|
204
|
-
className: "flex-1 rounded-md bg-bg-sunken/50 p-2 text-center",
|
|
205
|
-
children: [/* @__PURE__ */ v("div", {
|
|
206
|
-
className: "flex justify-center gap-0.5 mb-1",
|
|
207
|
-
children: [
|
|
208
|
-
1,
|
|
209
|
-
2,
|
|
210
|
-
3,
|
|
211
|
-
4,
|
|
212
|
-
5
|
|
213
|
-
].map((e) => /* @__PURE__ */ v(g, { className: "h-3 w-3 text-status-warning-text fill-[var(--color-status-warning)]" }, e))
|
|
214
|
-
}), /* @__PURE__ */ y("p", {
|
|
215
|
-
className: "text-[10px] text-text-secondary",
|
|
216
|
-
children: ["Testimonial ", t + 1]
|
|
217
|
-
})]
|
|
218
|
-
}, t))
|
|
219
|
-
}) : e.type === "cta" ? /* @__PURE__ */ y("div", {
|
|
220
|
-
className: "rounded-md bg-action-primary-bg/10 p-3 text-center",
|
|
221
|
-
children: [/* @__PURE__ */ v("p", {
|
|
222
|
-
className: "text-sm font-semibold text-text-primary",
|
|
223
|
-
children: e.config.headline || "Call to Action"
|
|
224
|
-
}), /* @__PURE__ */ v("span", {
|
|
225
|
-
className: "inline-block mt-1 bg-action-primary-bg text-action-primary-text text-xs px-3 py-1 rounded-md",
|
|
226
|
-
children: e.config.buttonText || "Get Started"
|
|
227
|
-
})]
|
|
228
|
-
}) : e.type === "footer" ? /* @__PURE__ */ y("div", {
|
|
229
|
-
className: "rounded-md bg-bg-sunken/50 p-2 text-center text-xs text-text-secondary",
|
|
230
|
-
children: [
|
|
231
|
-
"Footer with ",
|
|
232
|
-
e.config.columns || 4,
|
|
233
|
-
" columns"
|
|
234
|
-
]
|
|
235
|
-
}) : /* @__PURE__ */ y("div", {
|
|
236
|
-
className: "rounded-md bg-bg-sunken/50 p-3 text-center text-xs text-text-secondary capitalize",
|
|
237
|
-
children: [e.type, " section"]
|
|
238
|
-
});
|
|
239
|
-
return /* @__PURE__ */ y(a, {
|
|
186
|
+
}, $ = Ee || Oe, tt = `/p/${Ae || y(M)}`;
|
|
187
|
+
return /* @__PURE__ */ p(a, {
|
|
240
188
|
title: "Landing Page Builder",
|
|
241
|
-
actions: /* @__PURE__ */
|
|
189
|
+
actions: /* @__PURE__ */ p("div", {
|
|
242
190
|
className: "flex flex-wrap items-center gap-2",
|
|
243
191
|
children: [
|
|
244
|
-
/* @__PURE__ */
|
|
245
|
-
onClick: () =>
|
|
192
|
+
/* @__PURE__ */ p("button", {
|
|
193
|
+
onClick: () => o(s),
|
|
246
194
|
className: "inline-flex items-center gap-2 rounded-md border border-border-subtle px-3 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken",
|
|
247
|
-
children: [/* @__PURE__ */
|
|
195
|
+
children: [/* @__PURE__ */ f(de, { className: "h-4 w-4" }), "Back"]
|
|
248
196
|
}),
|
|
249
|
-
/* @__PURE__ */
|
|
197
|
+
/* @__PURE__ */ p("button", {
|
|
250
198
|
onClick: () => B(!0),
|
|
251
199
|
className: "inline-flex items-center gap-2 rounded-md border border-border-subtle px-3 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken",
|
|
252
|
-
children: [/* @__PURE__ */
|
|
200
|
+
children: [/* @__PURE__ */ f(pe, { className: "h-4 w-4" }), "Preview"]
|
|
253
201
|
}),
|
|
254
|
-
/* @__PURE__ */
|
|
255
|
-
onClick: () => void
|
|
256
|
-
disabled:
|
|
202
|
+
/* @__PURE__ */ p("button", {
|
|
203
|
+
onClick: () => void $e(),
|
|
204
|
+
disabled: $,
|
|
257
205
|
className: "inline-flex items-center gap-2 rounded-md border border-border-subtle px-3 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken disabled:opacity-60",
|
|
258
|
-
children: [/* @__PURE__ */
|
|
206
|
+
children: [/* @__PURE__ */ f(ye, { className: "h-4 w-4" }), $ ? "Saving…" : "Save"]
|
|
259
207
|
}),
|
|
260
|
-
/* @__PURE__ */
|
|
261
|
-
onClick: () => void
|
|
262
|
-
disabled:
|
|
263
|
-
className: "inline-flex items-center gap-2 rounded-md bg-
|
|
264
|
-
children: [/* @__PURE__ */
|
|
208
|
+
/* @__PURE__ */ p("button", {
|
|
209
|
+
onClick: () => void et(),
|
|
210
|
+
disabled: $ || T,
|
|
211
|
+
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-3 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 disabled:opacity-60",
|
|
212
|
+
children: [/* @__PURE__ */ f(me, { className: "h-4 w-4" }), T ? "Publishing…" : "Publish"]
|
|
265
213
|
})
|
|
266
214
|
]
|
|
267
215
|
}),
|
|
268
216
|
children: [
|
|
269
|
-
/* @__PURE__ */
|
|
270
|
-
V && /* @__PURE__ */
|
|
217
|
+
/* @__PURE__ */ f(Ce, { children: "Build a campaign landing page without code. Start from a template, drag in sections (hero, features, testimonials, forms), edit the copy and style live, preview how it looks on desktop and mobile, then publish it to capture leads for the campaign you're promoting." }),
|
|
218
|
+
V && /* @__PURE__ */ f("div", {
|
|
271
219
|
className: "rounded-lg border border-status-error-border/30 bg-status-error-bg/10 px-4 py-3 text-sm text-status-error-text",
|
|
272
220
|
children: V
|
|
273
221
|
}),
|
|
274
|
-
|
|
222
|
+
Ne && !V && /* @__PURE__ */ p("div", {
|
|
275
223
|
className: "flex items-center justify-between gap-3 rounded-lg border border-status-success-border/30 bg-status-success-bg/10 px-4 py-3 text-sm text-status-success-text",
|
|
276
|
-
children: [/* @__PURE__ */
|
|
277
|
-
href:
|
|
224
|
+
children: [/* @__PURE__ */ f("span", { children: Ne }), A && O === "PUBLISHED" && /* @__PURE__ */ p("a", {
|
|
225
|
+
href: A,
|
|
278
226
|
target: "_blank",
|
|
279
227
|
rel: "noreferrer",
|
|
280
228
|
className: "inline-flex items-center gap-1 font-medium underline",
|
|
281
|
-
children: ["View live ", /* @__PURE__ */
|
|
229
|
+
children: ["View live ", /* @__PURE__ */ f(u, { className: "h-3 w-3" })]
|
|
282
230
|
})]
|
|
283
231
|
}),
|
|
284
|
-
/* @__PURE__ */
|
|
232
|
+
/* @__PURE__ */ f("div", {
|
|
285
233
|
className: "rounded-lg border border-border-seam bg-gloss-card shadow-pop p-4",
|
|
286
|
-
children: /* @__PURE__ */
|
|
234
|
+
children: /* @__PURE__ */ p("div", {
|
|
287
235
|
className: "flex flex-wrap items-center gap-3",
|
|
288
236
|
children: [
|
|
289
|
-
/* @__PURE__ */
|
|
290
|
-
/* @__PURE__ */
|
|
237
|
+
/* @__PURE__ */ f(fe, { className: "h-4 w-4 text-text-secondary" }),
|
|
238
|
+
/* @__PURE__ */ f("input", {
|
|
291
239
|
type: "text",
|
|
292
|
-
value:
|
|
293
|
-
onChange: (e) =>
|
|
240
|
+
value: M,
|
|
241
|
+
onChange: (e) => N(e.target.value),
|
|
294
242
|
className: "text-lg font-semibold text-text-primary bg-transparent border-none outline-none flex-1 min-w-[12rem] placeholder:text-text-secondary",
|
|
295
243
|
placeholder: "Page name"
|
|
296
244
|
}),
|
|
297
|
-
/* @__PURE__ */
|
|
298
|
-
className:
|
|
299
|
-
children:
|
|
245
|
+
/* @__PURE__ */ p("span", {
|
|
246
|
+
className: "hidden items-center gap-1.5 text-xs text-text-secondary sm:inline-flex",
|
|
247
|
+
children: [
|
|
248
|
+
/* @__PURE__ */ f(he, { className: "h-3.5 w-3.5" }),
|
|
249
|
+
q.length,
|
|
250
|
+
" ",
|
|
251
|
+
q.length === 1 ? "section" : "sections"
|
|
252
|
+
]
|
|
253
|
+
}),
|
|
254
|
+
/* @__PURE__ */ f("span", {
|
|
255
|
+
className: i("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-medium capitalize", O === "PUBLISHED" ? "border-status-success-border bg-status-success-bg text-status-success-text" : "border-border-subtle bg-bg-sunken text-text-secondary"),
|
|
256
|
+
children: O.toLowerCase()
|
|
300
257
|
})
|
|
301
258
|
]
|
|
302
259
|
})
|
|
303
260
|
}),
|
|
304
|
-
/* @__PURE__ */
|
|
305
|
-
loading:
|
|
261
|
+
/* @__PURE__ */ f(te, {
|
|
262
|
+
loading: b,
|
|
306
263
|
error: S,
|
|
307
|
-
onRetry:
|
|
308
|
-
hasData: !!
|
|
309
|
-
children: /* @__PURE__ */
|
|
310
|
-
className: "grid grid-cols-1 lg:grid-cols-
|
|
311
|
-
children: [
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
264
|
+
onRetry: C,
|
|
265
|
+
hasData: !!g,
|
|
266
|
+
children: /* @__PURE__ */ p("div", {
|
|
267
|
+
className: "grid grid-cols-1 gap-4 lg:grid-cols-12",
|
|
268
|
+
children: [
|
|
269
|
+
/* @__PURE__ */ p("aside", {
|
|
270
|
+
className: "space-y-4 lg:col-span-3 lg:sticky lg:top-4 lg:self-start",
|
|
271
|
+
children: [/* @__PURE__ */ p("div", {
|
|
272
|
+
className: "rounded-card border border-border-seam bg-gloss-card shadow-pop p-4",
|
|
273
|
+
children: [
|
|
274
|
+
/* @__PURE__ */ p("h4", {
|
|
275
|
+
className: "mb-1 flex items-center gap-2 text-sm font-semibold text-text-primary",
|
|
276
|
+
children: [/* @__PURE__ */ f(he, { className: "h-4 w-4 text-text-secondary" }), "Section blocks"]
|
|
277
|
+
}),
|
|
278
|
+
/* @__PURE__ */ f("p", {
|
|
279
|
+
className: "mb-3 text-[11px] text-text-secondary",
|
|
280
|
+
children: "Click to append, or drag onto the canvas."
|
|
281
|
+
}),
|
|
282
|
+
/* @__PURE__ */ f("div", {
|
|
283
|
+
className: "grid grid-cols-2 gap-2",
|
|
284
|
+
children: ae.map((e) => {
|
|
285
|
+
let t = e.icon;
|
|
286
|
+
return /* @__PURE__ */ p("button", {
|
|
287
|
+
type: "button",
|
|
288
|
+
draggable: !0,
|
|
289
|
+
onDragStart: Je(e.type),
|
|
290
|
+
onDragEnd: X,
|
|
291
|
+
onClick: () => Ue(e.type),
|
|
292
|
+
title: e.description,
|
|
293
|
+
className: "group flex cursor-grab flex-col gap-2 rounded-lg border border-border-subtle bg-bg-surface p-2 text-left transition-all hover:border-border-strong hover:shadow-pop active:cursor-grabbing",
|
|
294
|
+
children: [/* @__PURE__ */ f("div", {
|
|
295
|
+
className: "h-12 overflow-hidden rounded-md border border-border-subtle/60 bg-bg-sunken/50 p-1.5",
|
|
296
|
+
children: /* @__PURE__ */ f(oe, { type: e.type })
|
|
297
|
+
}), /* @__PURE__ */ p("div", {
|
|
298
|
+
className: "flex items-center gap-1.5",
|
|
299
|
+
children: [/* @__PURE__ */ f(t, { className: "h-3.5 w-3.5 text-text-secondary group-hover:text-primary" }), /* @__PURE__ */ f("span", {
|
|
300
|
+
className: "text-xs font-medium text-text-primary",
|
|
301
|
+
children: e.label
|
|
302
|
+
})]
|
|
303
|
+
})]
|
|
304
|
+
}, e.type);
|
|
305
|
+
})
|
|
306
|
+
})
|
|
307
|
+
]
|
|
308
|
+
}), /* @__PURE__ */ p("div", {
|
|
309
|
+
className: "rounded-card border border-border-seam bg-gloss-card shadow-pop p-4",
|
|
310
|
+
children: [/* @__PURE__ */ p("h4", {
|
|
311
|
+
className: "mb-3 flex items-center gap-2 text-sm font-semibold text-text-primary",
|
|
312
|
+
children: [/* @__PURE__ */ f(ge, { className: "h-4 w-4 text-text-secondary" }), "Templates"]
|
|
313
|
+
}), /* @__PURE__ */ p("div", {
|
|
314
|
+
className: "space-y-2",
|
|
315
|
+
children: [Re.length === 0 && /* @__PURE__ */ f("p", {
|
|
316
|
+
className: "text-xs text-text-secondary",
|
|
317
|
+
children: "No templates yet. Create a campaign template to reuse it here."
|
|
318
|
+
}), Re.map((e) => /* @__PURE__ */ p("button", {
|
|
319
|
+
type: "button",
|
|
320
|
+
onClick: () => Xe(e),
|
|
321
|
+
className: i("flex w-full flex-col items-start rounded-md border px-3 py-2.5 text-left transition-colors", F === e.id ? "border-primary bg-action-primary-bg/5" : "border-border-subtle hover:bg-bg-sunken"),
|
|
322
|
+
children: [
|
|
323
|
+
/* @__PURE__ */ f("span", {
|
|
324
|
+
className: "text-sm font-medium text-text-primary",
|
|
325
|
+
children: e.name
|
|
326
|
+
}),
|
|
327
|
+
e.description && /* @__PURE__ */ f("span", {
|
|
328
|
+
className: "mt-0.5 text-[10px] text-text-secondary",
|
|
329
|
+
children: e.description
|
|
330
|
+
}),
|
|
331
|
+
/* @__PURE__ */ f("span", {
|
|
332
|
+
className: "mt-1 rounded-full bg-bg-sunken px-2 py-0.5 text-[10px] capitalize text-text-secondary",
|
|
333
|
+
children: e.category
|
|
334
|
+
})
|
|
335
|
+
]
|
|
336
|
+
}, e.id))]
|
|
337
|
+
})]
|
|
338
|
+
})]
|
|
339
|
+
}),
|
|
340
|
+
/* @__PURE__ */ p("div", {
|
|
341
|
+
className: "min-w-0 lg:col-span-6",
|
|
342
|
+
children: [/* @__PURE__ */ f("div", {
|
|
343
|
+
className: "mb-4 flex justify-center",
|
|
344
|
+
children: /* @__PURE__ */ f("div", {
|
|
345
|
+
className: "inline-flex items-center gap-0.5 rounded-lg border border-border-subtle bg-bg-surface p-0.5",
|
|
346
|
+
children: [
|
|
347
|
+
{
|
|
348
|
+
key: "desktop",
|
|
349
|
+
icon: _e,
|
|
350
|
+
label: "Desktop"
|
|
351
|
+
},
|
|
352
|
+
{
|
|
353
|
+
key: "tablet",
|
|
354
|
+
icon: xe,
|
|
355
|
+
label: "Tablet"
|
|
356
|
+
},
|
|
357
|
+
{
|
|
358
|
+
key: "mobile",
|
|
359
|
+
icon: be,
|
|
360
|
+
label: "Mobile"
|
|
361
|
+
}
|
|
362
|
+
].map((e) => {
|
|
363
|
+
let t = e.icon, n = L === e.key;
|
|
364
|
+
return /* @__PURE__ */ p("button", {
|
|
365
|
+
onClick: () => je(e.key),
|
|
366
|
+
title: e.label,
|
|
367
|
+
"aria-label": e.label,
|
|
368
|
+
"aria-pressed": n,
|
|
369
|
+
className: i("inline-flex items-center gap-1.5 rounded-md px-3 py-1.5 text-sm font-medium transition-colors", n ? "bg-action-primary-bg text-action-primary-text" : "text-text-secondary hover:text-text-primary"),
|
|
370
|
+
children: [/* @__PURE__ */ f(t, { className: "h-4 w-4" }), /* @__PURE__ */ f("span", {
|
|
371
|
+
className: "hidden sm:inline",
|
|
372
|
+
children: e.label
|
|
373
|
+
})]
|
|
374
|
+
}, e.key);
|
|
375
|
+
})
|
|
376
|
+
})
|
|
377
|
+
}), /* @__PURE__ */ p("div", {
|
|
378
|
+
className: i("mx-auto overflow-hidden rounded-card border border-border-seam bg-bg-canvas shadow-pop transition-all", ze[L]),
|
|
379
|
+
children: [/* @__PURE__ */ p("div", {
|
|
380
|
+
className: "flex items-center gap-2 border-b border-border-subtle bg-bg-sunken/60 px-4 py-2.5",
|
|
381
|
+
children: [/* @__PURE__ */ p("div", {
|
|
382
|
+
className: "flex gap-1.5",
|
|
383
|
+
children: [
|
|
384
|
+
/* @__PURE__ */ f("span", { className: "h-2.5 w-2.5 rounded-full bg-status-error-bg" }),
|
|
385
|
+
/* @__PURE__ */ f("span", { className: "h-2.5 w-2.5 rounded-full bg-status-warning-bg" }),
|
|
386
|
+
/* @__PURE__ */ f("span", { className: "h-2.5 w-2.5 rounded-full bg-status-success-bg" })
|
|
387
|
+
]
|
|
388
|
+
}), /* @__PURE__ */ p("div", {
|
|
389
|
+
className: "mx-auto flex max-w-[70%] items-center gap-1.5 truncate rounded-md bg-bg-surface px-3 py-1 text-[11px] text-text-secondary",
|
|
390
|
+
children: [/* @__PURE__ */ f(me, { className: "h-3 w-3 shrink-0" }), /* @__PURE__ */ f("span", {
|
|
391
|
+
className: "truncate",
|
|
392
|
+
children: tt
|
|
393
|
+
})]
|
|
394
|
+
})]
|
|
395
|
+
}), q.length === 0 ? /* @__PURE__ */ p("div", {
|
|
396
|
+
onDragOver: Z(0),
|
|
397
|
+
onDrop: Q(0),
|
|
398
|
+
className: i("m-4 flex flex-col items-center justify-center gap-2 rounded-lg border-2 border-dashed p-12 text-center transition-colors", Le ? "border-primary bg-action-primary-bg/5" : "border-border-subtle"),
|
|
327
399
|
children: [
|
|
328
|
-
/* @__PURE__ */
|
|
400
|
+
/* @__PURE__ */ f(d, { className: "h-6 w-6 text-text-secondary" }),
|
|
401
|
+
/* @__PURE__ */ f("p", {
|
|
329
402
|
className: "text-sm font-medium text-text-primary",
|
|
330
|
-
children:
|
|
331
|
-
}),
|
|
332
|
-
/* @__PURE__ */ v("span", {
|
|
333
|
-
className: "text-[10px] text-text-secondary mt-0.5",
|
|
334
|
-
children: e.description
|
|
403
|
+
children: "Start building your page"
|
|
335
404
|
}),
|
|
336
|
-
/* @__PURE__ */
|
|
337
|
-
className: "
|
|
338
|
-
children:
|
|
405
|
+
/* @__PURE__ */ f("p", {
|
|
406
|
+
className: "max-w-xs text-xs text-text-secondary",
|
|
407
|
+
children: "Drag a block from the left, or click one to add it here."
|
|
339
408
|
})
|
|
340
409
|
]
|
|
341
|
-
}, e
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
410
|
+
}) : /* @__PURE__ */ p("div", { children: [q.map((e, t) => /* @__PURE__ */ f(ce, {
|
|
411
|
+
section: e,
|
|
412
|
+
index: t,
|
|
413
|
+
total: q.length,
|
|
414
|
+
selected: R === e.id,
|
|
415
|
+
dropBefore: K === t,
|
|
416
|
+
onSelect: () => z(e.id),
|
|
417
|
+
onMoveUp: () => Be(e.id, "up"),
|
|
418
|
+
onMoveDown: () => Be(e.id, "down"),
|
|
419
|
+
onDuplicate: () => He(e.id),
|
|
420
|
+
onRemove: () => Ve(e.id),
|
|
421
|
+
onHandleDragStart: Ye(e.id),
|
|
422
|
+
onDragEnd: X,
|
|
423
|
+
onBlockDragOver: Z(t),
|
|
424
|
+
onBlockDrop: Q(t)
|
|
425
|
+
}, e.id)), /* @__PURE__ */ p("div", {
|
|
426
|
+
onDragOver: Z(q.length),
|
|
427
|
+
onDrop: Q(q.length),
|
|
428
|
+
className: i("relative border-t border-dashed transition-colors", K === q.length ? "border-primary bg-action-primary-bg/5" : "border-border-subtle"),
|
|
429
|
+
children: [K === q.length && /* @__PURE__ */ f("div", { className: "pointer-events-none absolute inset-x-0 -top-px h-0.5 bg-action-primary-bg" }), /* @__PURE__ */ p("button", {
|
|
430
|
+
type: "button",
|
|
431
|
+
onClick: () => Ue("features"),
|
|
432
|
+
className: "flex w-full items-center justify-center gap-2 p-4 text-sm text-text-secondary transition-colors hover:bg-action-primary-bg/5 hover:text-primary",
|
|
433
|
+
children: [/* @__PURE__ */ f(d, { className: "h-4 w-4" }), "Add section"]
|
|
434
|
+
})]
|
|
435
|
+
})] })]
|
|
355
436
|
})]
|
|
356
|
-
})
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
}, e.key);
|
|
384
|
-
})
|
|
385
|
-
}), /* @__PURE__ */ v("div", {
|
|
386
|
-
className: i("mx-auto transition-all", De[L]),
|
|
387
|
-
children: /* @__PURE__ */ y(_e, {
|
|
388
|
-
className: "overflow-hidden p-0",
|
|
389
|
-
children: [/* @__PURE__ */ v("div", {
|
|
390
|
-
className: "divide-y divide-border",
|
|
391
|
-
children: G.map((e, t) => {
|
|
392
|
-
let n = x[e.type] || m;
|
|
393
|
-
return /* @__PURE__ */ y("div", {
|
|
394
|
-
onClick: () => z(e.id),
|
|
395
|
-
className: i("p-4 cursor-pointer transition-all group", R === e.id ? "bg-action-primary-bg/5 ring-2 ring-inset ring-primary" : "hover:bg-bg-sunken/50"),
|
|
396
|
-
children: [/* @__PURE__ */ y("div", {
|
|
397
|
-
className: "flex items-center justify-between",
|
|
398
|
-
children: [/* @__PURE__ */ y("div", {
|
|
399
|
-
className: "flex items-center gap-3",
|
|
400
|
-
children: [
|
|
401
|
-
/* @__PURE__ */ v(le, { className: "h-4 w-4 text-text-secondary opacity-0 group-hover:opacity-100 transition-opacity cursor-grab" }),
|
|
402
|
-
/* @__PURE__ */ v("div", {
|
|
403
|
-
className: "p-2 rounded-md bg-bg-sunken",
|
|
404
|
-
children: /* @__PURE__ */ v(n, { className: "h-4 w-4 text-text-secondary" })
|
|
405
|
-
}),
|
|
406
|
-
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("p", {
|
|
407
|
-
className: "text-sm font-medium text-text-primary",
|
|
408
|
-
children: e.label
|
|
409
|
-
}), /* @__PURE__ */ y("p", {
|
|
410
|
-
className: "text-xs text-text-secondary capitalize",
|
|
411
|
-
children: [e.type, " section"]
|
|
412
|
-
})] })
|
|
413
|
-
]
|
|
414
|
-
}), /* @__PURE__ */ y("div", {
|
|
415
|
-
className: "flex items-center gap-1 opacity-0 group-hover:opacity-100 transition-opacity",
|
|
416
|
-
children: [
|
|
417
|
-
/* @__PURE__ */ v("button", {
|
|
418
|
-
onClick: (t) => {
|
|
419
|
-
t.stopPropagation(), J(e.id, "up");
|
|
420
|
-
},
|
|
421
|
-
disabled: t === 0,
|
|
422
|
-
className: i("p-1 rounded-md hover:bg-bg-sunken", t === 0 && "opacity-30 cursor-not-allowed"),
|
|
423
|
-
children: /* @__PURE__ */ v(l, { className: "h-4 w-4 text-text-secondary" })
|
|
424
|
-
}),
|
|
425
|
-
/* @__PURE__ */ v("button", {
|
|
426
|
-
onClick: (t) => {
|
|
427
|
-
t.stopPropagation(), J(e.id, "down");
|
|
428
|
-
},
|
|
429
|
-
disabled: t === G.length - 1,
|
|
430
|
-
className: i("p-1 rounded-md hover:bg-bg-sunken", t === G.length - 1 && "opacity-30 cursor-not-allowed"),
|
|
431
|
-
children: /* @__PURE__ */ v(oe, { className: "h-4 w-4 text-text-secondary" })
|
|
432
|
-
}),
|
|
433
|
-
/* @__PURE__ */ v("button", {
|
|
434
|
-
onClick: (t) => {
|
|
435
|
-
t.stopPropagation(), z(e.id);
|
|
436
|
-
},
|
|
437
|
-
className: "p-1 rounded-md hover:bg-bg-sunken",
|
|
438
|
-
children: /* @__PURE__ */ v(d, { className: "h-4 w-4 text-text-secondary" })
|
|
439
|
-
}),
|
|
440
|
-
/* @__PURE__ */ v("button", {
|
|
441
|
-
onClick: (t) => {
|
|
442
|
-
t.stopPropagation(), Oe(e.id);
|
|
443
|
-
},
|
|
444
|
-
className: "p-1 rounded-md hover:bg-bg-sunken text-text-secondary hover:text-status-error-text",
|
|
445
|
-
children: /* @__PURE__ */ v(he, { className: "h-4 w-4" })
|
|
446
|
-
})
|
|
447
|
-
]
|
|
448
|
-
})]
|
|
449
|
-
}), /* @__PURE__ */ v("div", {
|
|
450
|
-
className: "mt-3 ml-11",
|
|
451
|
-
children: $(e)
|
|
452
|
-
})]
|
|
453
|
-
}, e.id);
|
|
437
|
+
}),
|
|
438
|
+
/* @__PURE__ */ f("aside", {
|
|
439
|
+
className: "lg:col-span-3 lg:sticky lg:top-4 lg:self-start",
|
|
440
|
+
children: Y ? /* @__PURE__ */ f("div", {
|
|
441
|
+
className: "lg:max-h-[calc(100vh-2rem)]",
|
|
442
|
+
children: /* @__PURE__ */ f(le, {
|
|
443
|
+
section: Y,
|
|
444
|
+
onChangeConfig: (e) => Ke(Y.id, e),
|
|
445
|
+
onChangeLabel: (e) => qe(Y.id, e),
|
|
446
|
+
onClose: () => z(null),
|
|
447
|
+
onDuplicate: () => He(Y.id),
|
|
448
|
+
onRemove: () => Ve(Y.id)
|
|
449
|
+
})
|
|
450
|
+
}) : /* @__PURE__ */ p("div", {
|
|
451
|
+
className: "flex flex-col items-center justify-center gap-3 rounded-card border border-dashed border-border-subtle bg-bg-surface p-6 text-center",
|
|
452
|
+
children: [
|
|
453
|
+
/* @__PURE__ */ f("span", {
|
|
454
|
+
className: "flex h-11 w-11 items-center justify-center rounded-full bg-action-primary-bg/10 text-primary",
|
|
455
|
+
children: /* @__PURE__ */ f(ve, { className: "h-5 w-5" })
|
|
456
|
+
}),
|
|
457
|
+
/* @__PURE__ */ f("p", {
|
|
458
|
+
className: "text-sm font-semibold text-text-primary",
|
|
459
|
+
children: "No block selected"
|
|
460
|
+
}),
|
|
461
|
+
/* @__PURE__ */ f("p", {
|
|
462
|
+
className: "text-xs text-text-secondary",
|
|
463
|
+
children: "Select a block on the canvas to edit its text, colors, spacing and alignment."
|
|
454
464
|
})
|
|
455
|
-
|
|
456
|
-
onClick: () => Y("features"),
|
|
457
|
-
className: "w-full p-4 border-t border-dashed border-border-subtle text-sm text-text-secondary hover:text-primary hover:bg-action-primary-bg/5 transition-colors flex items-center justify-center gap-2",
|
|
458
|
-
children: [/* @__PURE__ */ v(de, { className: "h-4 w-4" }), "Add Section"]
|
|
459
|
-
})]
|
|
465
|
+
]
|
|
460
466
|
})
|
|
461
|
-
})
|
|
462
|
-
|
|
467
|
+
})
|
|
468
|
+
]
|
|
463
469
|
})
|
|
464
470
|
}),
|
|
465
|
-
/* @__PURE__ */
|
|
466
|
-
open:
|
|
471
|
+
/* @__PURE__ */ f(ee, {
|
|
472
|
+
open: Me,
|
|
467
473
|
onClose: () => B(!1),
|
|
468
|
-
title:
|
|
469
|
-
description: "Preview of your landing page
|
|
474
|
+
title: M || "Landing Page",
|
|
475
|
+
description: "Preview of your landing page.",
|
|
470
476
|
size: "xl",
|
|
471
|
-
footer: /* @__PURE__ */
|
|
472
|
-
href:
|
|
477
|
+
footer: /* @__PURE__ */ p(Se, { children: [A && O === "PUBLISHED" && /* @__PURE__ */ p("a", {
|
|
478
|
+
href: A,
|
|
473
479
|
target: "_blank",
|
|
474
480
|
rel: "noreferrer",
|
|
475
481
|
className: "inline-flex items-center gap-2 rounded-md border border-border-subtle px-4 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken",
|
|
476
|
-
children: [/* @__PURE__ */
|
|
477
|
-
}), /* @__PURE__ */
|
|
482
|
+
children: [/* @__PURE__ */ f(u, { className: "h-4 w-4" }), "Open live page"]
|
|
483
|
+
}), /* @__PURE__ */ f("button", {
|
|
478
484
|
type: "button",
|
|
479
485
|
onClick: () => B(!1),
|
|
480
486
|
className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
|
|
481
487
|
children: "Close"
|
|
482
488
|
})] }),
|
|
483
|
-
children: /* @__PURE__ */
|
|
484
|
-
className: "
|
|
485
|
-
children:
|
|
489
|
+
children: /* @__PURE__ */ f("div", {
|
|
490
|
+
className: "overflow-hidden rounded-lg border border-border-subtle bg-bg-canvas",
|
|
491
|
+
children: q.length === 0 ? /* @__PURE__ */ f("p", {
|
|
492
|
+
className: "p-8 text-center text-sm text-text-secondary",
|
|
493
|
+
children: "This page has no sections yet."
|
|
494
|
+
}) : q.map((e) => /* @__PURE__ */ f(se, { section: e }, e.id))
|
|
486
495
|
})
|
|
487
496
|
})
|
|
488
497
|
]
|
|
489
498
|
});
|
|
490
499
|
};
|
|
491
500
|
//#endregion
|
|
492
|
-
export {
|
|
501
|
+
export { S as LandingPageBuilderPage };
|
|
493
502
|
|
|
494
503
|
//# sourceMappingURL=LandingPageBuilderPage.js.map
|