@burdenoff/microfe-headshotmarketing 2026.924.1 → 2026.924.3

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 (59) hide show
  1. package/dist/generated/wspace-operations.d.ts +129 -0
  2. package/dist/generated/wspace-operations.d.ts.map +1 -1
  3. package/dist/generated/wspace-operations.js +162 -90
  4. package/dist/generated/wspace-operations.js.map +1 -1
  5. package/dist/generated/wspace-types.js +9 -7
  6. package/dist/generated/wspace-types.js.map +1 -1
  7. package/dist/headshotmarketing/HeadshotMarketingRoutes.d.ts +2 -0
  8. package/dist/headshotmarketing/HeadshotMarketingRoutes.d.ts.map +1 -1
  9. package/dist/headshotmarketing/HeadshotMarketingRoutes.js +52 -44
  10. package/dist/headshotmarketing/HeadshotMarketingRoutes.js.map +1 -1
  11. package/dist/headshotmarketing/components/InfluencerModals.d.ts +6 -0
  12. package/dist/headshotmarketing/components/InfluencerModals.d.ts.map +1 -1
  13. package/dist/headshotmarketing/components/InfluencerModals.js +431 -249
  14. package/dist/headshotmarketing/components/InfluencerModals.js.map +1 -1
  15. package/dist/headshotmarketing/components/index.d.ts +1 -1
  16. package/dist/headshotmarketing/components/index.d.ts.map +1 -1
  17. package/dist/headshotmarketing/pages/ads/AdCampaignDetailsPage.d.ts +4 -0
  18. package/dist/headshotmarketing/pages/ads/AdCampaignDetailsPage.d.ts.map +1 -0
  19. package/dist/headshotmarketing/pages/ads/AdCampaignDetailsPage.js +500 -0
  20. package/dist/headshotmarketing/pages/ads/AdCampaignDetailsPage.js.map +1 -0
  21. package/dist/headshotmarketing/pages/ads/AdCampaignsPage.d.ts.map +1 -1
  22. package/dist/headshotmarketing/pages/ads/AdCampaignsPage.js +171 -163
  23. package/dist/headshotmarketing/pages/ads/AdCampaignsPage.js.map +1 -1
  24. package/dist/headshotmarketing/pages/ads/CreateAdCampaignPage.d.ts.map +1 -1
  25. package/dist/headshotmarketing/pages/ads/CreateAdCampaignPage.js +1 -1
  26. package/dist/headshotmarketing/pages/ads/CreateAdCampaignPage.js.map +1 -1
  27. package/dist/headshotmarketing/pages/content/ContentDetailsPage.d.ts +4 -0
  28. package/dist/headshotmarketing/pages/content/ContentDetailsPage.d.ts.map +1 -0
  29. package/dist/headshotmarketing/pages/content/ContentDetailsPage.js +206 -0
  30. package/dist/headshotmarketing/pages/content/ContentDetailsPage.js.map +1 -0
  31. package/dist/headshotmarketing/pages/content/ContentLibraryCard.d.ts +2 -0
  32. package/dist/headshotmarketing/pages/content/ContentLibraryCard.d.ts.map +1 -1
  33. package/dist/headshotmarketing/pages/content/ContentLibraryCard.js +47 -34
  34. package/dist/headshotmarketing/pages/content/ContentLibraryCard.js.map +1 -1
  35. package/dist/headshotmarketing/pages/content/ContentPage.d.ts.map +1 -1
  36. package/dist/headshotmarketing/pages/content/ContentPage.js +4 -2
  37. package/dist/headshotmarketing/pages/content/ContentPage.js.map +1 -1
  38. package/dist/headshotmarketing/pages/crm/CreateDealPage.d.ts.map +1 -1
  39. package/dist/headshotmarketing/pages/crm/CreateDealPage.js +233 -195
  40. package/dist/headshotmarketing/pages/crm/CreateDealPage.js.map +1 -1
  41. package/dist/headshotmarketing/pages/crm/CreatePipelineModal.d.ts +10 -0
  42. package/dist/headshotmarketing/pages/crm/CreatePipelineModal.d.ts.map +1 -0
  43. package/dist/headshotmarketing/pages/crm/CreatePipelineModal.js +157 -0
  44. package/dist/headshotmarketing/pages/crm/CreatePipelineModal.js.map +1 -0
  45. package/dist/headshotmarketing/pages/crm/PipelinePage.d.ts.map +1 -1
  46. package/dist/headshotmarketing/pages/crm/PipelinePage.js +87 -76
  47. package/dist/headshotmarketing/pages/crm/PipelinePage.js.map +1 -1
  48. package/dist/headshotmarketing/pages/crm/createPipelineForm.d.ts +34 -0
  49. package/dist/headshotmarketing/pages/crm/createPipelineForm.d.ts.map +1 -0
  50. package/dist/headshotmarketing/pages/crm/createPipelineForm.js +49 -0
  51. package/dist/headshotmarketing/pages/crm/createPipelineForm.js.map +1 -0
  52. package/dist/headshotmarketing/pages/influencers/InfluencerDiscoveryPage.d.ts.map +1 -1
  53. package/dist/headshotmarketing/pages/influencers/InfluencerDiscoveryPage.js +150 -135
  54. package/dist/headshotmarketing/pages/influencers/InfluencerDiscoveryPage.js.map +1 -1
  55. package/dist/headshotmarketing/pages/influencers/createInfluencerForm.d.ts +53 -0
  56. package/dist/headshotmarketing/pages/influencers/createInfluencerForm.d.ts.map +1 -0
  57. package/dist/headshotmarketing/pages/influencers/createInfluencerForm.js +107 -0
  58. package/dist/headshotmarketing/pages/influencers/createInfluencerForm.js.map +1 -0
  59. package/package.json +1 -1
@@ -2,30 +2,30 @@ import { useCreateHeadshotmarketingAdCampaignMutation as e, useDeleteHeadshotmar
2
2
  import { useHeadshotMarketing as i } from "../../context/HeadshotMarketingContext.js";
3
3
  import { cn as a, formatCurrency as o, formatNumber as s, formatPercentage as c } from "../../utils/helpers.js";
4
4
  import { HeadshotmarketingAdCampaignStatus as l, HeadshotmarketingAdPlatform as u } from "../../../generated/wspace-types.js";
5
- import { toAdCampaignModel as d, toAdCampaignStatusEnum as f, toAdPlatformEnum as ee } from "../../utils/adsMapper.js";
6
- import { PageLayout as te } from "../../components/PageLayout.js";
7
- import { StatusBadge as p } from "../../components/StatusBadge.js";
8
- import { EmptyState as ne } from "../../components/EmptyState.js";
9
- import { FilterBar as re } from "../../components/FilterBar.js";
10
- import { Modal as m } from "../../components/Modal.js";
11
- import { QueryStateBoundary as ie } from "../../components/QueryStateBoundary.js";
12
- import { Pagination as h } from "../../components/Pagination.js";
5
+ import { toAdCampaignModel as d, toAdCampaignStatusEnum as f, toAdPlatformEnum as p } from "../../utils/adsMapper.js";
6
+ import { PageLayout as ee } from "../../components/PageLayout.js";
7
+ import { StatusBadge as m } from "../../components/StatusBadge.js";
8
+ import { EmptyState as te } from "../../components/EmptyState.js";
9
+ import { FilterBar as ne } from "../../components/FilterBar.js";
10
+ import { Modal as h } from "../../components/Modal.js";
11
+ import { QueryStateBoundary as re } from "../../components/QueryStateBoundary.js";
12
+ import { Pagination as ie } from "../../components/Pagination.js";
13
13
  import "../../components/index.js";
14
14
  import { useHeadshotmarketingBootstrap as ae } from "../../hooks/useHeadshotmarketingBootstrap.js";
15
15
  import { usePagination as oe } from "../../hooks/usePagination.js";
16
16
  import { useEffect as g, useMemo as _, useState as v } from "react";
17
- import { Copy as y, DollarSign as b, Eye as x, MoreHorizontal as S, MousePointerClick as C, Pause as w, Pencil as T, Play as E, Plus as D, Trash2 as O, TrendingUp as k } from "lucide-react";
18
- import { useExclusiveMenu as A } from "@burdenoff/fe-libs/shared/hooks";
19
- import { Fragment as j, jsx as M, jsxs as N } from "react/jsx-runtime";
17
+ import { Copy as y, DollarSign as b, Eye as x, MoreHorizontal as S, MousePointerClick as C, Pause as w, Pencil as T, Play as E, Plus as D, Settings2 as O, Trash2 as k, TrendingUp as A } from "lucide-react";
18
+ import { useExclusiveMenu as j } from "@burdenoff/fe-libs/shared/hooks";
19
+ import { Fragment as M, jsx as N, jsxs as P } from "react/jsx-runtime";
20
20
  import { EmphasisPanel as se, PagePurpose as ce } from "@burdenoff/fe-libs/ui";
21
21
  //#region src/headshotmarketing/pages/ads/AdCampaignsPage.tsx
22
- var P = {
22
+ var F = {
23
23
  google_ads: "Google Ads",
24
24
  facebook: "Facebook",
25
25
  instagram: "Instagram",
26
26
  linkedin: "LinkedIn",
27
27
  twitter: "Twitter"
28
- }, F = {
28
+ }, I = {
29
29
  google_ads: "bg-status-info-bg text-status-info-text",
30
30
  facebook: "bg-status-info-bg text-status-info-text",
31
31
  instagram: "bg-[var(--color-accent-soft)] text-action-primary-bg",
@@ -43,13 +43,13 @@ var P = {
43
43
  linkedin: u.LinkedinAds,
44
44
  twitter: u.TwitterAds
45
45
  };
46
- function I(e) {
46
+ function L(e) {
47
47
  if (!e) return "";
48
48
  let t = new Date(e);
49
49
  return Number.isNaN(t.getTime()) ? "" : t.toISOString().slice(0, 10);
50
50
  }
51
- var L = () => {
52
- let { navigate: a, basePath: c } = i(), u = (e) => a(c + e), { data: p, refetch: y } = ae(), [b, x] = v(""), [S, C] = v(""), [w, T] = v("all"), [E, O] = v("all"), [k, A] = v(null), [P, F] = v(null), [L, R] = v(null), [z, B] = v(null), V = oe({ initialPageSize: 10 }), { limit: fe, offset: pe, setPage: H, setTotal: U } = V;
51
+ var R = () => {
52
+ let { navigate: a, basePath: c } = i(), u = (e) => a(c + e), { data: m, refetch: y } = ae(), [b, x] = v(""), [S, C] = v(""), [w, T] = v("all"), [E, O] = v("all"), [k, A] = v(null), [j, F] = v(null), [I, R] = v(null), [z, B] = v(null), V = oe({ initialPageSize: 10 }), { limit: fe, offset: pe, setPage: H, setTotal: U } = V;
53
53
  g(() => {
54
54
  let e = setTimeout(() => C(b), 300);
55
55
  return () => clearTimeout(e);
@@ -76,14 +76,14 @@ var L = () => {
76
76
  U(q);
77
77
  }, [q, U]);
78
78
  let J = _(() => (W?.headshotmarketingAdCampaigns.items ?? []).map((e) => d(e)), [W?.headshotmarketingAdCampaigns.items]), Y = _(() => {
79
- let e = (p?.headshotmarketingAdCampaigns.items ?? []).map((e) => d(e)), t = e.filter((e) => e.status === "active").length, n = e.reduce((e, t) => e + t.metrics.spend, 0), r = e.reduce((e, t) => e + t.metrics.impressions, 0), i = e.filter((e) => e.metrics.roas > 0);
79
+ let e = (m?.headshotmarketingAdCampaigns.items ?? []).map((e) => d(e)), t = e.filter((e) => e.status === "active").length, n = e.reduce((e, t) => e + t.metrics.spend, 0), r = e.reduce((e, t) => e + t.metrics.impressions, 0), i = e.filter((e) => e.metrics.roas > 0);
80
80
  return {
81
81
  active: t,
82
82
  totalSpend: n,
83
83
  totalImpressions: r,
84
84
  avgRoas: i.length > 0 ? i.reduce((e, t) => e + t.metrics.roas, 0) / i.length : 0
85
85
  };
86
- }, [p?.headshotmarketingAdCampaigns.items]), [he] = e(), [X, { loading: Z }] = r(), [ge, { loading: Q }] = t(), $ = async () => {
86
+ }, [m?.headshotmarketingAdCampaigns.items]), [he] = e(), [X, { loading: Z }] = r(), [ge, { loading: Q }] = t(), $ = async () => {
87
87
  await Promise.all([K(), y()]);
88
88
  }, _e = async (e) => {
89
89
  A(null), B(null);
@@ -100,7 +100,7 @@ var L = () => {
100
100
  try {
101
101
  await he({ variables: { input: {
102
102
  name: `${e.name} (Copy)`,
103
- platform: ee(e.platform),
103
+ platform: p(e.platform),
104
104
  status: l.Draft,
105
105
  bidStrategy: e.bidStrategy,
106
106
  totalBudget: e.budget.total > 0 ? e.budget.total : null,
@@ -112,33 +112,33 @@ var L = () => {
112
112
  B(e instanceof Error ? e.message : "Failed to duplicate campaign.");
113
113
  }
114
114
  }, ye = async () => {
115
- if (!P) return;
116
- if (!P.name.trim()) {
115
+ if (!j) return;
116
+ if (!j.name.trim()) {
117
117
  B("Campaign name is required.");
118
118
  return;
119
119
  }
120
120
  B(null);
121
- let e = Number(P.totalBudget);
121
+ let e = Number(j.totalBudget);
122
122
  try {
123
123
  await X({ variables: {
124
- id: P.id,
124
+ id: j.id,
125
125
  input: {
126
- name: P.name.trim(),
127
- status: f(P.status),
128
- bidStrategy: P.bidStrategy || null,
129
- totalBudget: P.totalBudget && Number.isFinite(e) ? e : null,
130
- startDate: P.startDate ? new Date(P.startDate).toISOString() : null,
131
- endDate: P.endDate ? new Date(P.endDate).toISOString() : null
126
+ name: j.name.trim(),
127
+ status: f(j.status),
128
+ bidStrategy: j.bidStrategy || null,
129
+ totalBudget: j.totalBudget && Number.isFinite(e) ? e : null,
130
+ startDate: j.startDate ? new Date(j.startDate).toISOString() : null,
131
+ endDate: j.endDate ? new Date(j.endDate).toISOString() : null
132
132
  }
133
133
  } }), F(null), await $();
134
134
  } catch (e) {
135
135
  B(e instanceof Error ? e.message : "Failed to save campaign.");
136
136
  }
137
137
  }, be = async () => {
138
- if (L) {
138
+ if (I) {
139
139
  B(null);
140
140
  try {
141
- await ge({ variables: { id: L.id } }), R(null), await $();
141
+ await ge({ variables: { id: I.id } }), R(null), await $();
142
142
  } catch (e) {
143
143
  B(e instanceof Error ? e.message : "Failed to delete campaign.");
144
144
  }
@@ -150,141 +150,142 @@ var L = () => {
150
150
  status: e.status,
151
151
  totalBudget: e.budget.total > 0 ? String(e.budget.total) : "",
152
152
  bidStrategy: e.bidStrategy,
153
- startDate: I(e.startDate),
154
- endDate: I(e.endDate)
153
+ startDate: L(e.startDate),
154
+ endDate: L(e.endDate)
155
155
  });
156
156
  };
157
- return /* @__PURE__ */ N(te, {
157
+ return /* @__PURE__ */ P(ee, {
158
158
  title: "Ad Campaigns",
159
159
  description: "Create and manage your advertising campaigns",
160
- actions: /* @__PURE__ */ N("button", {
160
+ actions: /* @__PURE__ */ P("button", {
161
161
  onClick: () => u("/ads/campaigns/new"),
162
162
  className: "inline-flex items-center gap-2 rounded-md bg-foreground px-4 py-2 text-sm font-medium text-background hover:bg-foreground/90",
163
- children: [/* @__PURE__ */ M(D, { className: "h-4 w-4" }), "Create Campaign"]
163
+ children: [/* @__PURE__ */ N(D, { className: "h-4 w-4" }), "Create Campaign"]
164
164
  }),
165
165
  children: [
166
- /* @__PURE__ */ M(ce, { children: "A focused view of every ad campaign — filter by platform or status, watch budget pacing at a glance, and pause, edit or duplicate any campaign without leaving the list." }),
167
- /* @__PURE__ */ M(se, { children: /* @__PURE__ */ N("div", {
166
+ /* @__PURE__ */ N(ce, { children: "A focused view of every ad campaign — filter by platform or status, watch budget pacing at a glance, and pause, edit or duplicate any campaign without leaving the list." }),
167
+ /* @__PURE__ */ N(se, { children: /* @__PURE__ */ P("div", {
168
168
  className: "grid grid-cols-2 gap-4 sm:grid-cols-4",
169
169
  children: [
170
- /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("p", {
170
+ /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("p", {
171
171
  className: "text-xs text-text-secondary",
172
172
  children: "Active Campaigns"
173
- }), /* @__PURE__ */ M("p", {
173
+ }), /* @__PURE__ */ N("p", {
174
174
  className: "text-2xl font-semibold text-text-primary",
175
175
  children: s(Y.active)
176
176
  })] }),
177
- /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("p", {
177
+ /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("p", {
178
178
  className: "text-xs text-text-secondary",
179
179
  children: "Total Spend"
180
- }), /* @__PURE__ */ M("p", {
180
+ }), /* @__PURE__ */ N("p", {
181
181
  className: "text-2xl font-semibold text-text-primary",
182
182
  children: o(Y.totalSpend)
183
183
  })] }),
184
- /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("p", {
184
+ /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("p", {
185
185
  className: "text-xs text-text-secondary",
186
186
  children: "Impressions"
187
- }), /* @__PURE__ */ M("p", {
187
+ }), /* @__PURE__ */ N("p", {
188
188
  className: "text-2xl font-semibold text-text-primary",
189
189
  children: s(Y.totalImpressions)
190
190
  })] }),
191
- /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("p", {
191
+ /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("p", {
192
192
  className: "text-xs text-text-secondary",
193
193
  children: "Avg ROAS"
194
- }), /* @__PURE__ */ N("p", {
194
+ }), /* @__PURE__ */ P("p", {
195
195
  className: "text-2xl font-semibold text-text-primary",
196
196
  children: [Y.avgRoas.toFixed(1), "x"]
197
197
  })] })
198
198
  ]
199
199
  }) }),
200
- /* @__PURE__ */ M(re, {
200
+ /* @__PURE__ */ N(ne, {
201
201
  searchValue: b,
202
202
  onSearchChange: x,
203
203
  searchPlaceholder: "Search campaigns...",
204
- filters: /* @__PURE__ */ N(j, { children: [/* @__PURE__ */ N("select", {
204
+ filters: /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ P("select", {
205
205
  value: w,
206
206
  onChange: (e) => T(e.target.value),
207
207
  className: "rounded-md border border-border-seam bg-gloss-card shadow-pop px-3 py-2 text-sm text-text-primary",
208
208
  children: [
209
- /* @__PURE__ */ M("option", {
209
+ /* @__PURE__ */ N("option", {
210
210
  value: "all",
211
211
  children: "All Status"
212
212
  }),
213
- /* @__PURE__ */ M("option", {
213
+ /* @__PURE__ */ N("option", {
214
214
  value: "active",
215
215
  children: "Active"
216
216
  }),
217
- /* @__PURE__ */ M("option", {
217
+ /* @__PURE__ */ N("option", {
218
218
  value: "paused",
219
219
  children: "Paused"
220
220
  }),
221
- /* @__PURE__ */ M("option", {
221
+ /* @__PURE__ */ N("option", {
222
222
  value: "completed",
223
223
  children: "Completed"
224
224
  }),
225
- /* @__PURE__ */ M("option", {
225
+ /* @__PURE__ */ N("option", {
226
226
  value: "draft",
227
227
  children: "Draft"
228
228
  })
229
229
  ]
230
- }), /* @__PURE__ */ N("select", {
230
+ }), /* @__PURE__ */ P("select", {
231
231
  value: E,
232
232
  onChange: (e) => O(e.target.value),
233
233
  className: "rounded-md border border-border-seam bg-gloss-card shadow-pop px-3 py-2 text-sm text-text-primary",
234
234
  children: [
235
- /* @__PURE__ */ M("option", {
235
+ /* @__PURE__ */ N("option", {
236
236
  value: "all",
237
237
  children: "All Platforms"
238
238
  }),
239
- /* @__PURE__ */ M("option", {
239
+ /* @__PURE__ */ N("option", {
240
240
  value: "google_ads",
241
241
  children: "Google Ads"
242
242
  }),
243
- /* @__PURE__ */ M("option", {
243
+ /* @__PURE__ */ N("option", {
244
244
  value: "facebook",
245
245
  children: "Facebook"
246
246
  }),
247
- /* @__PURE__ */ M("option", {
247
+ /* @__PURE__ */ N("option", {
248
248
  value: "instagram",
249
249
  children: "Instagram"
250
250
  }),
251
- /* @__PURE__ */ M("option", {
251
+ /* @__PURE__ */ N("option", {
252
252
  value: "linkedin",
253
253
  children: "LinkedIn"
254
254
  }),
255
- /* @__PURE__ */ M("option", {
255
+ /* @__PURE__ */ N("option", {
256
256
  value: "twitter",
257
257
  children: "Twitter"
258
258
  })
259
259
  ]
260
260
  })] })
261
261
  }),
262
- z && /* @__PURE__ */ M("div", {
262
+ z && /* @__PURE__ */ N("div", {
263
263
  role: "alert",
264
264
  className: "rounded-lg border border-status-error-border/30 bg-status-error-bg/10 px-4 py-3 text-sm text-status-error-text",
265
265
  children: z
266
266
  }),
267
- /* @__PURE__ */ M(ie, {
267
+ /* @__PURE__ */ N(re, {
268
268
  loading: G,
269
269
  error: me,
270
270
  onRetry: K,
271
271
  hasData: !!W,
272
- children: J.length === 0 ? /* @__PURE__ */ M(ne, {
272
+ children: J.length === 0 ? /* @__PURE__ */ N(te, {
273
273
  illustration: q === 0 ? "empty-generic" : "empty-search",
274
274
  title: q === 0 ? "No ad campaigns yet" : "No campaigns match your filters",
275
275
  description: q === 0 ? "Create your first ad campaign to start running paid traffic." : "Try a different search term, platform or status.",
276
- action: q === 0 ? /* @__PURE__ */ N("button", {
276
+ action: q === 0 ? /* @__PURE__ */ P("button", {
277
277
  onClick: () => u("/ads/campaigns/new"),
278
278
  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",
279
- children: [/* @__PURE__ */ M(D, { className: "h-4 w-4" }), "Create Campaign"]
279
+ children: [/* @__PURE__ */ N(D, { className: "h-4 w-4" }), "Create Campaign"]
280
280
  }) : void 0
281
- }) : /* @__PURE__ */ N(j, { children: [/* @__PURE__ */ M("div", {
281
+ }) : /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ N("div", {
282
282
  className: "space-y-4",
283
- children: J.map((e) => /* @__PURE__ */ M(de, {
283
+ children: J.map((e) => /* @__PURE__ */ N(de, {
284
284
  campaign: e,
285
285
  menuOpen: k === e.id,
286
286
  onToggleMenu: () => A(k === e.id ? null : e.id),
287
287
  onCloseMenu: () => A(null),
288
+ onManage: () => u("/ads/campaigns/" + e.id),
288
289
  onEdit: () => xe(e),
289
290
  onToggleStatus: () => _e(e),
290
291
  onDuplicate: () => ve(e),
@@ -292,7 +293,7 @@ var L = () => {
292
293
  A(null), R(e);
293
294
  }
294
295
  }, e.id))
295
- }), /* @__PURE__ */ M(h, {
296
+ }), /* @__PURE__ */ N(ie, {
296
297
  page: V.page,
297
298
  pageSize: V.pageSize,
298
299
  total: V.total,
@@ -302,148 +303,148 @@ var L = () => {
302
303
  hideWhenSinglePage: !0
303
304
  })] })
304
305
  }),
305
- /* @__PURE__ */ M(m, {
306
- open: P !== null,
306
+ /* @__PURE__ */ N(h, {
307
+ open: j !== null,
307
308
  onClose: () => F(null),
308
309
  title: "Edit Campaign",
309
310
  description: "Update campaign details",
310
311
  size: "lg",
311
- footer: /* @__PURE__ */ N(j, { children: [/* @__PURE__ */ M("button", {
312
+ footer: /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ N("button", {
312
313
  onClick: () => F(null),
313
314
  className: "rounded-md border border-border-subtle px-4 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken",
314
315
  children: "Cancel"
315
- }), /* @__PURE__ */ M("button", {
316
+ }), /* @__PURE__ */ N("button", {
316
317
  onClick: ye,
317
318
  disabled: Z,
318
319
  className: "rounded-md bg-foreground px-4 py-2 text-sm font-medium text-background hover:bg-foreground/90 disabled:opacity-60",
319
320
  children: Z ? "Saving..." : "Save Changes"
320
321
  })] }),
321
- children: P && /* @__PURE__ */ N("div", {
322
+ children: j && /* @__PURE__ */ P("div", {
322
323
  className: "space-y-4",
323
324
  children: [
324
- /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("label", {
325
+ /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("label", {
325
326
  className: "mb-1.5 block text-sm font-medium text-text-primary",
326
327
  children: "Campaign Name"
327
- }), /* @__PURE__ */ M("input", {
328
+ }), /* @__PURE__ */ N("input", {
328
329
  type: "text",
329
- value: P.name,
330
+ value: j.name,
330
331
  onChange: (e) => F({
331
- ...P,
332
+ ...j,
332
333
  name: e.target.value
333
334
  }),
334
335
  className: "w-full rounded-md border border-border-subtle bg-bg-surface px-4 py-2.5 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
335
336
  })] }),
336
- /* @__PURE__ */ N("div", {
337
+ /* @__PURE__ */ P("div", {
337
338
  className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
338
- children: [/* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("label", {
339
+ children: [/* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("label", {
339
340
  className: "mb-1.5 block text-sm font-medium text-text-primary",
340
341
  children: "Status"
341
- }), /* @__PURE__ */ N("select", {
342
- value: P.status,
342
+ }), /* @__PURE__ */ P("select", {
343
+ value: j.status,
343
344
  onChange: (e) => F({
344
- ...P,
345
+ ...j,
345
346
  status: e.target.value
346
347
  }),
347
348
  className: "w-full rounded-md border border-border-subtle bg-bg-surface px-4 py-2.5 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]",
348
349
  children: [
349
- /* @__PURE__ */ M("option", {
350
+ /* @__PURE__ */ N("option", {
350
351
  value: "draft",
351
352
  children: "Draft"
352
353
  }),
353
- /* @__PURE__ */ M("option", {
354
+ /* @__PURE__ */ N("option", {
354
355
  value: "active",
355
356
  children: "Active"
356
357
  }),
357
- /* @__PURE__ */ M("option", {
358
+ /* @__PURE__ */ N("option", {
358
359
  value: "paused",
359
360
  children: "Paused"
360
361
  }),
361
- /* @__PURE__ */ M("option", {
362
+ /* @__PURE__ */ N("option", {
362
363
  value: "completed",
363
364
  children: "Completed"
364
365
  })
365
366
  ]
366
- })] }), /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("label", {
367
+ })] }), /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("label", {
367
368
  className: "mb-1.5 block text-sm font-medium text-text-primary",
368
369
  children: "Total Budget (USD)"
369
- }), /* @__PURE__ */ M("input", {
370
+ }), /* @__PURE__ */ N("input", {
370
371
  type: "number",
371
- value: P.totalBudget,
372
+ value: j.totalBudget,
372
373
  onChange: (e) => F({
373
- ...P,
374
+ ...j,
374
375
  totalBudget: e.target.value
375
376
  }),
376
377
  className: "w-full rounded-md border border-border-subtle bg-bg-surface px-4 py-2.5 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
377
378
  })] })]
378
379
  }),
379
- /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("label", {
380
+ /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("label", {
380
381
  className: "mb-1.5 block text-sm font-medium text-text-primary",
381
382
  children: "Bid Strategy"
382
- }), /* @__PURE__ */ M("input", {
383
+ }), /* @__PURE__ */ N("input", {
383
384
  type: "text",
384
- value: P.bidStrategy,
385
+ value: j.bidStrategy,
385
386
  onChange: (e) => F({
386
- ...P,
387
+ ...j,
387
388
  bidStrategy: e.target.value
388
389
  }),
389
390
  className: "w-full rounded-md border border-border-subtle bg-bg-surface px-4 py-2.5 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
390
391
  })] }),
391
- /* @__PURE__ */ N("div", {
392
+ /* @__PURE__ */ P("div", {
392
393
  className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
393
- children: [/* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("label", {
394
+ children: [/* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("label", {
394
395
  className: "mb-1.5 block text-sm font-medium text-text-primary",
395
396
  children: "Start Date"
396
- }), /* @__PURE__ */ M("input", {
397
+ }), /* @__PURE__ */ N("input", {
397
398
  type: "date",
398
- value: P.startDate,
399
+ value: j.startDate,
399
400
  onChange: (e) => F({
400
- ...P,
401
+ ...j,
401
402
  startDate: e.target.value
402
403
  }),
403
404
  className: "w-full rounded-md border border-border-subtle bg-bg-surface px-4 py-2.5 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
404
- })] }), /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("label", {
405
+ })] }), /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("label", {
405
406
  className: "mb-1.5 block text-sm font-medium text-text-primary",
406
407
  children: "End Date"
407
- }), /* @__PURE__ */ M("input", {
408
+ }), /* @__PURE__ */ N("input", {
408
409
  type: "date",
409
- value: P.endDate,
410
+ value: j.endDate,
410
411
  onChange: (e) => F({
411
- ...P,
412
+ ...j,
412
413
  endDate: e.target.value
413
414
  }),
414
415
  className: "w-full rounded-md border border-border-subtle bg-bg-surface px-4 py-2.5 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
415
416
  })] })]
416
417
  }),
417
- z && /* @__PURE__ */ M("p", {
418
+ z && /* @__PURE__ */ N("p", {
418
419
  className: "text-sm text-status-error-text",
419
420
  children: z
420
421
  })
421
422
  ]
422
423
  })
423
424
  }),
424
- /* @__PURE__ */ M(m, {
425
- open: L !== null,
425
+ /* @__PURE__ */ N(h, {
426
+ open: I !== null,
426
427
  onClose: () => R(null),
427
428
  title: "Delete Campaign",
428
429
  size: "sm",
429
- footer: /* @__PURE__ */ N(j, { children: [/* @__PURE__ */ M("button", {
430
+ footer: /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ N("button", {
430
431
  onClick: () => R(null),
431
432
  className: "rounded-md border border-border-subtle px-4 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken",
432
433
  children: "Cancel"
433
- }), /* @__PURE__ */ M("button", {
434
+ }), /* @__PURE__ */ N("button", {
434
435
  onClick: be,
435
436
  disabled: Q,
436
437
  className: "rounded-md bg-status-error-text px-4 py-2 text-sm font-medium text-background hover:opacity-90 disabled:opacity-60",
437
438
  children: Q ? "Deleting..." : "Delete"
438
439
  })] }),
439
- children: /* @__PURE__ */ N("p", {
440
+ children: /* @__PURE__ */ P("p", {
440
441
  className: "text-sm text-text-secondary",
441
442
  children: [
442
443
  "Are you sure you want to delete",
443
444
  " ",
444
- /* @__PURE__ */ M("span", {
445
+ /* @__PURE__ */ N("span", {
445
446
  className: "font-semibold text-text-primary",
446
- children: L?.name
447
+ children: I?.name
447
448
  }),
448
449
  "? This action cannot be undone."
449
450
  ]
@@ -451,30 +452,31 @@ var L = () => {
451
452
  })
452
453
  ]
453
454
  });
454
- }, de = ({ campaign: e, menuOpen: t, onToggleMenu: n, onCloseMenu: r, onEdit: i, onToggleStatus: l, onDuplicate: u, onDelete: d }) => {
455
- A(`ad-campaign-${e.id}`, t, r);
456
- let f = e.budget.total > 0 ? e.budget.spent / e.budget.total * 100 : 0;
457
- return /* @__PURE__ */ N("div", {
455
+ }, de = ({ campaign: e, menuOpen: t, onToggleMenu: n, onCloseMenu: r, onManage: i, onEdit: l, onToggleStatus: u, onDuplicate: d, onDelete: f }) => {
456
+ j(`ad-campaign-${e.id}`, t, r);
457
+ let p = e.budget.total > 0 ? e.budget.spent / e.budget.total * 100 : 0;
458
+ return /* @__PURE__ */ P("div", {
458
459
  className: "rounded-lg border border-border-seam bg-gloss-card shadow-pop p-5",
459
460
  children: [
460
- /* @__PURE__ */ N("div", {
461
+ /* @__PURE__ */ P("div", {
461
462
  className: "mb-4 flex items-start justify-between gap-3",
462
- children: [/* @__PURE__ */ N("div", {
463
+ children: [/* @__PURE__ */ P("div", {
463
464
  className: "min-w-0",
464
- children: [/* @__PURE__ */ N("div", {
465
+ children: [/* @__PURE__ */ P("div", {
465
466
  className: "mb-1 flex flex-wrap items-center gap-2",
466
467
  children: [
467
- /* @__PURE__ */ M("h3", {
468
- className: "text-sm font-semibold text-text-primary",
468
+ /* @__PURE__ */ N("button", {
469
+ onClick: i,
470
+ className: "rounded text-left text-sm font-semibold text-text-primary hover:underline focus:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]",
469
471
  children: e.name
470
472
  }),
471
- /* @__PURE__ */ M("span", {
472
- className: a("rounded-full px-2.5 py-0.5 text-xs font-medium", F[e.platform]),
473
- children: P[e.platform]
473
+ /* @__PURE__ */ N("span", {
474
+ className: a("rounded-full px-2.5 py-0.5 text-xs font-medium", I[e.platform]),
475
+ children: F[e.platform]
474
476
  }),
475
- /* @__PURE__ */ M(p, { status: e.status })
477
+ /* @__PURE__ */ N(m, { status: e.status })
476
478
  ]
477
- }), /* @__PURE__ */ N("p", {
479
+ }), /* @__PURE__ */ P("p", {
478
480
  className: "text-xs text-text-secondary",
479
481
  children: [
480
482
  e.adFormat,
@@ -487,52 +489,58 @@ var L = () => {
487
489
  e.endDate
488
490
  ]
489
491
  })]
490
- }), /* @__PURE__ */ N("div", {
492
+ }), /* @__PURE__ */ P("div", {
491
493
  className: "relative shrink-0",
492
- children: [/* @__PURE__ */ M("button", {
494
+ children: [/* @__PURE__ */ N("button", {
493
495
  onClick: n,
494
496
  "aria-haspopup": "menu",
495
497
  "aria-expanded": t,
496
498
  "aria-label": "Campaign actions",
497
499
  className: "rounded-md p-1.5 text-text-secondary hover:text-text-primary hover:bg-bg-sunken",
498
- children: /* @__PURE__ */ M(S, { className: "h-4 w-4" })
499
- }), t && /* @__PURE__ */ N("div", {
500
+ children: /* @__PURE__ */ N(S, { className: "h-4 w-4" })
501
+ }), t && /* @__PURE__ */ P("div", {
500
502
  role: "menu",
501
503
  className: "absolute right-0 top-8 z-20 w-44 rounded-md border border-border-seam bg-gloss-card py-1 shadow-lg",
502
504
  children: [
503
- /* @__PURE__ */ N("button", {
505
+ /* @__PURE__ */ P("button", {
504
506
  role: "menuitem",
505
507
  onClick: i,
506
508
  className: "flex w-full items-center gap-2 px-4 py-2 text-left text-sm text-text-primary hover:bg-bg-sunken",
507
- children: [/* @__PURE__ */ M(T, { className: "h-3.5 w-3.5" }), "Edit"]
509
+ children: [/* @__PURE__ */ N(O, { className: "h-3.5 w-3.5" }), "Manage"]
508
510
  }),
509
- /* @__PURE__ */ M("button", {
511
+ /* @__PURE__ */ P("button", {
510
512
  role: "menuitem",
511
513
  onClick: l,
512
514
  className: "flex w-full items-center gap-2 px-4 py-2 text-left text-sm text-text-primary hover:bg-bg-sunken",
513
- children: e.status === "active" ? /* @__PURE__ */ N(j, { children: [/* @__PURE__ */ M(w, { className: "h-3.5 w-3.5" }), "Pause"] }) : /* @__PURE__ */ N(j, { children: [/* @__PURE__ */ M(E, { className: "h-3.5 w-3.5" }), "Resume"] })
515
+ children: [/* @__PURE__ */ N(T, { className: "h-3.5 w-3.5" }), "Edit"]
514
516
  }),
515
517
  /* @__PURE__ */ N("button", {
516
518
  role: "menuitem",
517
519
  onClick: u,
518
520
  className: "flex w-full items-center gap-2 px-4 py-2 text-left text-sm text-text-primary hover:bg-bg-sunken",
519
- children: [/* @__PURE__ */ M(y, { className: "h-3.5 w-3.5" }), "Duplicate"]
521
+ children: e.status === "active" ? /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ N(w, { className: "h-3.5 w-3.5" }), "Pause"] }) : /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ N(E, { className: "h-3.5 w-3.5" }), "Resume"] })
520
522
  }),
521
- /* @__PURE__ */ N("button", {
523
+ /* @__PURE__ */ P("button", {
522
524
  role: "menuitem",
523
525
  onClick: d,
526
+ className: "flex w-full items-center gap-2 px-4 py-2 text-left text-sm text-text-primary hover:bg-bg-sunken",
527
+ children: [/* @__PURE__ */ N(y, { className: "h-3.5 w-3.5" }), "Duplicate"]
528
+ }),
529
+ /* @__PURE__ */ P("button", {
530
+ role: "menuitem",
531
+ onClick: f,
524
532
  className: "flex w-full items-center gap-2 px-4 py-2 text-left text-sm text-status-error-text hover:bg-bg-sunken",
525
- children: [/* @__PURE__ */ M(O, { className: "h-3.5 w-3.5" }), "Delete"]
533
+ children: [/* @__PURE__ */ N(k, { className: "h-3.5 w-3.5" }), "Delete"]
526
534
  })
527
535
  ]
528
536
  })]
529
537
  })]
530
538
  }),
531
- /* @__PURE__ */ N("div", {
539
+ /* @__PURE__ */ P("div", {
532
540
  className: "mb-4",
533
- children: [/* @__PURE__ */ N("div", {
541
+ children: [/* @__PURE__ */ P("div", {
534
542
  className: "mb-1 flex items-center justify-between text-xs",
535
- children: [/* @__PURE__ */ N("span", {
543
+ children: [/* @__PURE__ */ P("span", {
536
544
  className: "text-text-secondary",
537
545
  children: [
538
546
  "Budget: ",
@@ -541,71 +549,71 @@ var L = () => {
541
549
  " ",
542
550
  o(e.budget.total)
543
551
  ]
544
- }), /* @__PURE__ */ N("span", {
552
+ }), /* @__PURE__ */ P("span", {
545
553
  className: "text-text-secondary",
546
- children: [f.toFixed(0), "%"]
554
+ children: [p.toFixed(0), "%"]
547
555
  })]
548
- }), /* @__PURE__ */ M("div", {
556
+ }), /* @__PURE__ */ N("div", {
549
557
  className: "h-2 w-full overflow-hidden rounded-full bg-bg-sunken",
550
- children: /* @__PURE__ */ M("div", {
551
- className: a("h-full rounded-full", f > 90 ? "bg-status-error-text" : f > 70 ? "bg-status-warning-text" : "bg-status-success-text"),
552
- style: { width: `${Math.min(f, 100)}%` }
558
+ children: /* @__PURE__ */ N("div", {
559
+ className: a("h-full rounded-full", p > 90 ? "bg-status-error-text" : p > 70 ? "bg-status-warning-text" : "bg-status-success-text"),
560
+ style: { width: `${Math.min(p, 100)}%` }
553
561
  })
554
562
  })]
555
563
  }),
556
- /* @__PURE__ */ N("div", {
564
+ /* @__PURE__ */ P("div", {
557
565
  className: "grid grid-cols-2 gap-3 sm:grid-cols-4 lg:grid-cols-6",
558
566
  children: [
559
- /* @__PURE__ */ N("div", {
567
+ /* @__PURE__ */ P("div", {
560
568
  className: "flex items-center gap-2",
561
- children: [/* @__PURE__ */ M(b, { className: "h-3.5 w-3.5 text-text-secondary" }), /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("p", {
569
+ children: [/* @__PURE__ */ N(b, { className: "h-3.5 w-3.5 text-text-secondary" }), /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("p", {
562
570
  className: "text-xs text-text-secondary",
563
571
  children: "Spend"
564
- }), /* @__PURE__ */ M("p", {
572
+ }), /* @__PURE__ */ N("p", {
565
573
  className: "text-sm font-medium text-text-primary",
566
574
  children: o(e.metrics.spend)
567
575
  })] })]
568
576
  }),
569
- /* @__PURE__ */ N("div", {
577
+ /* @__PURE__ */ P("div", {
570
578
  className: "flex items-center gap-2",
571
- children: [/* @__PURE__ */ M(x, { className: "h-3.5 w-3.5 text-text-secondary" }), /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("p", {
579
+ children: [/* @__PURE__ */ N(x, { className: "h-3.5 w-3.5 text-text-secondary" }), /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("p", {
572
580
  className: "text-xs text-text-secondary",
573
581
  children: "Impressions"
574
- }), /* @__PURE__ */ M("p", {
582
+ }), /* @__PURE__ */ N("p", {
575
583
  className: "text-sm font-medium text-text-primary",
576
584
  children: s(e.metrics.impressions)
577
585
  })] })]
578
586
  }),
579
- /* @__PURE__ */ N("div", {
587
+ /* @__PURE__ */ P("div", {
580
588
  className: "flex items-center gap-2",
581
- children: [/* @__PURE__ */ M(C, { className: "h-3.5 w-3.5 text-text-secondary" }), /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("p", {
589
+ children: [/* @__PURE__ */ N(C, { className: "h-3.5 w-3.5 text-text-secondary" }), /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("p", {
582
590
  className: "text-xs text-text-secondary",
583
591
  children: "Clicks"
584
- }), /* @__PURE__ */ M("p", {
592
+ }), /* @__PURE__ */ N("p", {
585
593
  className: "text-sm font-medium text-text-primary",
586
594
  children: s(e.metrics.clicks)
587
595
  })] })]
588
596
  }),
589
- /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("p", {
597
+ /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("p", {
590
598
  className: "text-xs text-text-secondary",
591
599
  children: "CTR"
592
- }), /* @__PURE__ */ M("p", {
600
+ }), /* @__PURE__ */ N("p", {
593
601
  className: "text-sm font-medium text-text-primary",
594
602
  children: c(e.metrics.ctr)
595
603
  })] }),
596
- /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("p", {
604
+ /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("p", {
597
605
  className: "text-xs text-text-secondary",
598
606
  children: "CPC"
599
- }), /* @__PURE__ */ N("p", {
607
+ }), /* @__PURE__ */ P("p", {
600
608
  className: "text-sm font-medium text-text-primary",
601
609
  children: ["$", e.metrics.cpc.toFixed(2)]
602
610
  })] }),
603
- /* @__PURE__ */ N("div", {
611
+ /* @__PURE__ */ P("div", {
604
612
  className: "flex items-center gap-2",
605
- children: [/* @__PURE__ */ M(k, { className: "h-3.5 w-3.5 text-text-secondary" }), /* @__PURE__ */ N("div", { children: [/* @__PURE__ */ M("p", {
613
+ children: [/* @__PURE__ */ N(A, { className: "h-3.5 w-3.5 text-text-secondary" }), /* @__PURE__ */ P("div", { children: [/* @__PURE__ */ N("p", {
606
614
  className: "text-xs text-text-secondary",
607
615
  children: "ROAS"
608
- }), /* @__PURE__ */ N("p", {
616
+ }), /* @__PURE__ */ P("p", {
609
617
  className: "text-sm font-medium text-text-primary",
610
618
  children: [e.metrics.roas.toFixed(1), "x"]
611
619
  })] })]
@@ -616,6 +624,6 @@ var L = () => {
616
624
  });
617
625
  };
618
626
  //#endregion
619
- export { L as AdCampaignsPage };
627
+ export { R as AdCampaignsPage };
620
628
 
621
629
  //# sourceMappingURL=AdCampaignsPage.js.map