@burdenoff/microfe-headshotmarketing 2026.801.2 → 2026.827.1
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.d.ts +44 -0
- package/dist/generated/wspace-operations.d.ts.map +1 -1
- package/dist/generated/wspace-operations.js +30 -4
- package/dist/generated/wspace-operations.js.map +1 -1
- package/dist/headshotmarketing/components/InfluencerModals.d.ts.map +1 -1
- package/dist/headshotmarketing/components/InfluencerModals.js +201 -214
- package/dist/headshotmarketing/components/InfluencerModals.js.map +1 -1
- package/dist/headshotmarketing/components/StatusBadge.d.ts.map +1 -1
- package/dist/headshotmarketing/components/StatusBadge.js +2 -0
- package/dist/headshotmarketing/components/StatusBadge.js.map +1 -1
- package/dist/headshotmarketing/pages/ads/AdCreativesPage.js +59 -29
- package/dist/headshotmarketing/pages/ads/AdCreativesPage.js.map +1 -1
- package/dist/headshotmarketing/pages/analytics/AnalyticsPage.d.ts.map +1 -1
- package/dist/headshotmarketing/pages/analytics/AnalyticsPage.js +389 -215
- package/dist/headshotmarketing/pages/analytics/AnalyticsPage.js.map +1 -1
- package/dist/headshotmarketing/pages/content/AIExecutionLedger.d.ts +26 -0
- package/dist/headshotmarketing/pages/content/AIExecutionLedger.d.ts.map +1 -0
- package/dist/headshotmarketing/pages/content/AIExecutionLedger.js +215 -0
- package/dist/headshotmarketing/pages/content/AIExecutionLedger.js.map +1 -0
- package/dist/headshotmarketing/pages/content/AIToolsPage.d.ts.map +1 -1
- package/dist/headshotmarketing/pages/content/AIToolsPage.js +396 -379
- package/dist/headshotmarketing/pages/content/AIToolsPage.js.map +1 -1
- package/dist/headshotmarketing/pages/content/AssetLibraryPage.d.ts.map +1 -1
- package/dist/headshotmarketing/pages/content/AssetLibraryPage.js +436 -343
- package/dist/headshotmarketing/pages/content/AssetLibraryPage.js.map +1 -1
- package/dist/headshotmarketing/pages/content/ContentAnalyticsPage.d.ts.map +1 -1
- package/dist/headshotmarketing/pages/content/ContentAnalyticsPage.js +233 -223
- package/dist/headshotmarketing/pages/content/ContentAnalyticsPage.js.map +1 -1
- package/dist/headshotmarketing/pages/content/ContentPage.js +4 -4
- package/dist/headshotmarketing/pages/crm/ContactsPage.d.ts.map +1 -1
- package/dist/headshotmarketing/pages/crm/ContactsPage.js +339 -278
- package/dist/headshotmarketing/pages/crm/ContactsPage.js.map +1 -1
- package/dist/headshotmarketing/pages/crm/CrmPage.d.ts.map +1 -1
- package/dist/headshotmarketing/pages/crm/CrmPage.js +118 -112
- package/dist/headshotmarketing/pages/crm/CrmPage.js.map +1 -1
- package/dist/headshotmarketing/pages/crm/CrmSubNav.d.ts +14 -0
- package/dist/headshotmarketing/pages/crm/CrmSubNav.d.ts.map +1 -0
- package/dist/headshotmarketing/pages/crm/CrmSubNav.js +51 -0
- package/dist/headshotmarketing/pages/crm/CrmSubNav.js.map +1 -0
- package/dist/headshotmarketing/pages/crm/LeadsPage.d.ts.map +1 -1
- package/dist/headshotmarketing/pages/crm/LeadsPage.js +122 -116
- package/dist/headshotmarketing/pages/crm/LeadsPage.js.map +1 -1
- package/dist/headshotmarketing/pages/crm/PipelinePage.d.ts.map +1 -1
- package/dist/headshotmarketing/pages/crm/PipelinePage.js +192 -183
- package/dist/headshotmarketing/pages/crm/PipelinePage.js.map +1 -1
- package/dist/headshotmarketing/pages/influencers/InfluencerDiscoveryPage.d.ts.map +1 -1
- package/dist/headshotmarketing/pages/influencers/InfluencerDiscoveryPage.js +184 -162
- package/dist/headshotmarketing/pages/influencers/InfluencerDiscoveryPage.js.map +1 -1
- package/dist/headshotmarketing/pages/influencers/InfluencersPage.d.ts.map +1 -1
- package/dist/headshotmarketing/pages/influencers/InfluencersPage.js +8 -14
- package/dist/headshotmarketing/pages/influencers/InfluencersPage.js.map +1 -1
- package/dist/headshotmarketing/types/index.d.ts +9 -4
- package/dist/headshotmarketing/types/index.d.ts.map +1 -1
- package/dist/headshotmarketing/utils/contentMapper.js +1 -1
- package/dist/headshotmarketing/utils/contentMapper.js.map +1 -1
- package/dist/headshotmarketing/utils/influencerMapper.d.ts +16 -2
- package/dist/headshotmarketing/utils/influencerMapper.d.ts.map +1 -1
- package/dist/headshotmarketing/utils/influencerMapper.js +56 -40
- package/dist/headshotmarketing/utils/influencerMapper.js.map +1 -1
- package/package.json +2 -2
|
@@ -1,97 +1,97 @@
|
|
|
1
1
|
import { useCreateHeadshotmarketingInfluencerCampaignMutation as e, useCreateHeadshotmarketingInfluencerRelationshipMutation as t, useUpdateHeadshotmarketingInfluencerRelationshipMutation as n } from "../../generated/wspace-operations.js";
|
|
2
|
-
import { cn as r,
|
|
3
|
-
import { HeadshotmarketingInfluencerCampaignStatus as
|
|
4
|
-
import { Modal as
|
|
5
|
-
import { useEffect as
|
|
6
|
-
import { Loader2 as
|
|
7
|
-
import { Fragment as
|
|
2
|
+
import { cn as r, formatNumber as i, formatPercentage as a } from "../utils/helpers.js";
|
|
3
|
+
import { HeadshotmarketingInfluencerCampaignStatus as o, HeadshotmarketingInfluencerRelationshipStatus as s } from "../../generated/wspace-types.js";
|
|
4
|
+
import { Modal as c } from "./Modal.js";
|
|
5
|
+
import { useEffect as l, useMemo as u, useState as d } from "react";
|
|
6
|
+
import { Loader2 as f, Save as p, Star as m } from "lucide-react";
|
|
7
|
+
import { Fragment as h, jsx as g, jsxs as _ } from "react/jsx-runtime";
|
|
8
8
|
//#region src/headshotmarketing/components/InfluencerModals.tsx
|
|
9
|
-
var
|
|
9
|
+
var v = "w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]", y = "block text-sm font-medium text-text-primary mb-1", b = [
|
|
10
10
|
{
|
|
11
|
-
value:
|
|
11
|
+
value: s.Prospect,
|
|
12
12
|
label: "Prospect"
|
|
13
13
|
},
|
|
14
14
|
{
|
|
15
|
-
value:
|
|
15
|
+
value: s.Outreach,
|
|
16
16
|
label: "Outreach"
|
|
17
17
|
},
|
|
18
18
|
{
|
|
19
|
-
value:
|
|
19
|
+
value: s.Negotiating,
|
|
20
20
|
label: "Negotiating"
|
|
21
21
|
},
|
|
22
22
|
{
|
|
23
|
-
value:
|
|
23
|
+
value: s.Active,
|
|
24
24
|
label: "Active"
|
|
25
25
|
},
|
|
26
26
|
{
|
|
27
|
-
value:
|
|
27
|
+
value: s.Paused,
|
|
28
28
|
label: "Paused"
|
|
29
29
|
},
|
|
30
30
|
{
|
|
31
|
-
value:
|
|
31
|
+
value: s.Ended,
|
|
32
32
|
label: "Ended"
|
|
33
33
|
}
|
|
34
|
-
],
|
|
34
|
+
], x = [
|
|
35
35
|
{
|
|
36
|
-
value:
|
|
36
|
+
value: o.Proposed,
|
|
37
37
|
label: "Proposed"
|
|
38
38
|
},
|
|
39
39
|
{
|
|
40
|
-
value:
|
|
40
|
+
value: o.Negotiating,
|
|
41
41
|
label: "Negotiating"
|
|
42
42
|
},
|
|
43
43
|
{
|
|
44
|
-
value:
|
|
44
|
+
value: o.InProgress,
|
|
45
45
|
label: "In Progress"
|
|
46
46
|
},
|
|
47
47
|
{
|
|
48
|
-
value:
|
|
48
|
+
value: o.Completed,
|
|
49
49
|
label: "Completed"
|
|
50
50
|
},
|
|
51
51
|
{
|
|
52
|
-
value:
|
|
52
|
+
value: o.Cancelled,
|
|
53
53
|
label: "Cancelled"
|
|
54
54
|
}
|
|
55
55
|
];
|
|
56
|
-
function
|
|
56
|
+
function S(e) {
|
|
57
57
|
if (!e) return null;
|
|
58
58
|
let t = new Date(e);
|
|
59
59
|
return Number.isNaN(t.getTime()) ? null : t.toISOString();
|
|
60
60
|
}
|
|
61
|
-
var
|
|
61
|
+
var C = ({ onCancel: e, onSubmit: t, submitLabel: n, loading: r, disabled: i }) => /* @__PURE__ */ _(h, { children: [/* @__PURE__ */ g("button", {
|
|
62
62
|
type: "button",
|
|
63
63
|
onClick: e,
|
|
64
64
|
className: "rounded-md border border-border-subtle px-4 py-2 text-sm font-medium text-text-primary hover:bg-bg-sunken",
|
|
65
65
|
children: "Cancel"
|
|
66
|
-
}), /* @__PURE__ */
|
|
66
|
+
}), /* @__PURE__ */ _("button", {
|
|
67
67
|
type: "button",
|
|
68
68
|
onClick: t,
|
|
69
69
|
disabled: r || i,
|
|
70
70
|
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 disabled:opacity-60",
|
|
71
|
-
children: [r ? /* @__PURE__ */
|
|
71
|
+
children: [r ? /* @__PURE__ */ g(f, { className: "h-4 w-4 animate-spin" }) : /* @__PURE__ */ g(p, { className: "h-4 w-4" }), n]
|
|
72
72
|
})] });
|
|
73
|
-
function
|
|
74
|
-
return e ? /* @__PURE__ */
|
|
73
|
+
function w({ message: e }) {
|
|
74
|
+
return e ? /* @__PURE__ */ g("div", {
|
|
75
75
|
className: "rounded-lg border border-status-error-border/30 bg-status-error-bg/10 px-4 py-3 text-sm text-status-error-text",
|
|
76
76
|
children: e
|
|
77
77
|
}) : null;
|
|
78
78
|
}
|
|
79
|
-
var
|
|
80
|
-
let [
|
|
79
|
+
var T = ({ open: t, onClose: n, influencers: i, defaultInfluencerId: a, onCompleted: s }) => {
|
|
80
|
+
let [u, { loading: f }] = e(), [p, m] = d(null), [h, b] = d({
|
|
81
81
|
influencerId: "",
|
|
82
82
|
name: "",
|
|
83
83
|
description: "",
|
|
84
|
-
status:
|
|
84
|
+
status: o.Proposed,
|
|
85
85
|
compensation: "",
|
|
86
86
|
startDate: "",
|
|
87
87
|
endDate: ""
|
|
88
88
|
});
|
|
89
|
-
|
|
90
|
-
t && (m(null),
|
|
89
|
+
l(() => {
|
|
90
|
+
t && (m(null), b({
|
|
91
91
|
influencerId: a ?? i[0]?.id ?? "",
|
|
92
92
|
name: "",
|
|
93
93
|
description: "",
|
|
94
|
-
status:
|
|
94
|
+
status: o.Proposed,
|
|
95
95
|
compensation: "",
|
|
96
96
|
startDate: "",
|
|
97
97
|
endDate: ""
|
|
@@ -101,7 +101,7 @@ var E = ({ open: t, onClose: n, influencers: i, defaultInfluencerId: a, onComple
|
|
|
101
101
|
a,
|
|
102
102
|
i
|
|
103
103
|
]);
|
|
104
|
-
let
|
|
104
|
+
let T = async () => {
|
|
105
105
|
if (!h.influencerId) {
|
|
106
106
|
m("Select an influencer for this campaign.");
|
|
107
107
|
return;
|
|
@@ -112,170 +112,170 @@ var E = ({ open: t, onClose: n, influencers: i, defaultInfluencerId: a, onComple
|
|
|
112
112
|
}
|
|
113
113
|
m(null);
|
|
114
114
|
try {
|
|
115
|
-
await
|
|
115
|
+
await u({ variables: { input: {
|
|
116
116
|
influencerId: h.influencerId,
|
|
117
117
|
name: h.name.trim(),
|
|
118
118
|
description: h.description.trim() || null,
|
|
119
119
|
status: h.status,
|
|
120
120
|
compensation: h.compensation ? Number(h.compensation) : null,
|
|
121
121
|
compensationType: h.compensation ? "flat" : null,
|
|
122
|
-
startDate:
|
|
123
|
-
endDate:
|
|
124
|
-
} } }), await
|
|
122
|
+
startDate: S(h.startDate),
|
|
123
|
+
endDate: S(h.endDate)
|
|
124
|
+
} } }), await s?.(), n();
|
|
125
125
|
} catch (e) {
|
|
126
126
|
m(e instanceof Error ? e.message : "Failed to create campaign.");
|
|
127
127
|
}
|
|
128
128
|
};
|
|
129
|
-
return /* @__PURE__ */
|
|
129
|
+
return /* @__PURE__ */ g(c, {
|
|
130
130
|
open: t,
|
|
131
131
|
onClose: n,
|
|
132
132
|
title: "Create Influencer Campaign",
|
|
133
133
|
description: "Brief a creator and start tracking deliverables.",
|
|
134
134
|
size: "lg",
|
|
135
|
-
footer: /* @__PURE__ */
|
|
135
|
+
footer: /* @__PURE__ */ g(C, {
|
|
136
136
|
onCancel: n,
|
|
137
|
-
onSubmit: () => void
|
|
138
|
-
submitLabel:
|
|
139
|
-
loading:
|
|
137
|
+
onSubmit: () => void T(),
|
|
138
|
+
submitLabel: f ? "Creating..." : "Create Campaign",
|
|
139
|
+
loading: f
|
|
140
140
|
}),
|
|
141
|
-
children: /* @__PURE__ */
|
|
141
|
+
children: /* @__PURE__ */ _("div", {
|
|
142
142
|
className: "space-y-4",
|
|
143
143
|
children: [
|
|
144
|
-
/* @__PURE__ */
|
|
145
|
-
className:
|
|
144
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
145
|
+
className: y,
|
|
146
146
|
children: "Influencer"
|
|
147
|
-
}), /* @__PURE__ */
|
|
147
|
+
}), /* @__PURE__ */ _("select", {
|
|
148
148
|
value: h.influencerId,
|
|
149
|
-
onChange: (e) =>
|
|
149
|
+
onChange: (e) => b((t) => ({
|
|
150
150
|
...t,
|
|
151
151
|
influencerId: e.target.value
|
|
152
152
|
})),
|
|
153
|
-
className:
|
|
154
|
-
children: [/* @__PURE__ */
|
|
153
|
+
className: v,
|
|
154
|
+
children: [/* @__PURE__ */ g("option", {
|
|
155
155
|
value: "",
|
|
156
156
|
children: "Select an influencer…"
|
|
157
|
-
}), i.map((e) => /* @__PURE__ */
|
|
157
|
+
}), i.map((e) => /* @__PURE__ */ g("option", {
|
|
158
158
|
value: e.id,
|
|
159
159
|
children: e.name
|
|
160
160
|
}, e.id))]
|
|
161
161
|
})] }),
|
|
162
|
-
/* @__PURE__ */
|
|
163
|
-
className:
|
|
162
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
163
|
+
className: y,
|
|
164
164
|
children: "Campaign Name"
|
|
165
|
-
}), /* @__PURE__ */
|
|
165
|
+
}), /* @__PURE__ */ g("input", {
|
|
166
166
|
type: "text",
|
|
167
167
|
value: h.name,
|
|
168
|
-
onChange: (e) =>
|
|
168
|
+
onChange: (e) => b((t) => ({
|
|
169
169
|
...t,
|
|
170
170
|
name: e.target.value
|
|
171
171
|
})),
|
|
172
172
|
placeholder: "Spring product launch",
|
|
173
|
-
className:
|
|
173
|
+
className: v
|
|
174
174
|
})] }),
|
|
175
|
-
/* @__PURE__ */
|
|
176
|
-
className:
|
|
175
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
176
|
+
className: y,
|
|
177
177
|
children: "Brief / Guidelines"
|
|
178
|
-
}), /* @__PURE__ */
|
|
178
|
+
}), /* @__PURE__ */ g("textarea", {
|
|
179
179
|
value: h.description,
|
|
180
|
-
onChange: (e) =>
|
|
180
|
+
onChange: (e) => b((t) => ({
|
|
181
181
|
...t,
|
|
182
182
|
description: e.target.value
|
|
183
183
|
})),
|
|
184
184
|
rows: 3,
|
|
185
185
|
placeholder: "What should the creator produce?",
|
|
186
|
-
className: r(
|
|
186
|
+
className: r(v, "resize-none")
|
|
187
187
|
})] }),
|
|
188
|
-
/* @__PURE__ */
|
|
188
|
+
/* @__PURE__ */ _("div", {
|
|
189
189
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
|
|
190
|
-
children: [/* @__PURE__ */
|
|
191
|
-
className:
|
|
190
|
+
children: [/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
191
|
+
className: y,
|
|
192
192
|
children: "Compensation ($)"
|
|
193
|
-
}), /* @__PURE__ */
|
|
193
|
+
}), /* @__PURE__ */ g("input", {
|
|
194
194
|
type: "number",
|
|
195
195
|
min: 0,
|
|
196
196
|
value: h.compensation,
|
|
197
|
-
onChange: (e) =>
|
|
197
|
+
onChange: (e) => b((t) => ({
|
|
198
198
|
...t,
|
|
199
199
|
compensation: e.target.value
|
|
200
200
|
})),
|
|
201
201
|
placeholder: "2500",
|
|
202
|
-
className:
|
|
203
|
-
})] }), /* @__PURE__ */
|
|
204
|
-
className:
|
|
202
|
+
className: v
|
|
203
|
+
})] }), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
204
|
+
className: y,
|
|
205
205
|
children: "Status"
|
|
206
|
-
}), /* @__PURE__ */
|
|
206
|
+
}), /* @__PURE__ */ g("select", {
|
|
207
207
|
value: h.status,
|
|
208
|
-
onChange: (e) =>
|
|
208
|
+
onChange: (e) => b((t) => ({
|
|
209
209
|
...t,
|
|
210
210
|
status: e.target.value
|
|
211
211
|
})),
|
|
212
|
-
className:
|
|
213
|
-
children:
|
|
212
|
+
className: v,
|
|
213
|
+
children: x.map((e) => /* @__PURE__ */ g("option", {
|
|
214
214
|
value: e.value,
|
|
215
215
|
children: e.label
|
|
216
216
|
}, e.value))
|
|
217
217
|
})] })]
|
|
218
218
|
}),
|
|
219
|
-
/* @__PURE__ */
|
|
219
|
+
/* @__PURE__ */ _("div", {
|
|
220
220
|
className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
|
|
221
|
-
children: [/* @__PURE__ */
|
|
222
|
-
className:
|
|
221
|
+
children: [/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
222
|
+
className: y,
|
|
223
223
|
children: "Start Date"
|
|
224
|
-
}), /* @__PURE__ */
|
|
224
|
+
}), /* @__PURE__ */ g("input", {
|
|
225
225
|
type: "date",
|
|
226
226
|
value: h.startDate,
|
|
227
|
-
onChange: (e) =>
|
|
227
|
+
onChange: (e) => b((t) => ({
|
|
228
228
|
...t,
|
|
229
229
|
startDate: e.target.value
|
|
230
230
|
})),
|
|
231
|
-
className:
|
|
232
|
-
})] }), /* @__PURE__ */
|
|
233
|
-
className:
|
|
231
|
+
className: v
|
|
232
|
+
})] }), /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
233
|
+
className: y,
|
|
234
234
|
children: "End Date"
|
|
235
|
-
}), /* @__PURE__ */
|
|
235
|
+
}), /* @__PURE__ */ g("input", {
|
|
236
236
|
type: "date",
|
|
237
237
|
value: h.endDate,
|
|
238
|
-
onChange: (e) =>
|
|
238
|
+
onChange: (e) => b((t) => ({
|
|
239
239
|
...t,
|
|
240
240
|
endDate: e.target.value
|
|
241
241
|
})),
|
|
242
|
-
className:
|
|
242
|
+
className: v
|
|
243
243
|
})] })]
|
|
244
244
|
}),
|
|
245
|
-
/* @__PURE__ */
|
|
245
|
+
/* @__PURE__ */ g(w, { message: p })
|
|
246
246
|
]
|
|
247
247
|
})
|
|
248
248
|
});
|
|
249
|
-
},
|
|
250
|
-
let [m, { loading:
|
|
249
|
+
}, E = ({ open: e, onClose: n, influencers: i, existingInfluencerIds: a, defaultInfluencerId: o, defaultStatus: f = s.Outreach, onCompleted: p }) => {
|
|
250
|
+
let [m, { loading: x }] = t(), [S, T] = d(null), [E, D] = d({
|
|
251
251
|
influencerId: "",
|
|
252
|
-
status:
|
|
252
|
+
status: f,
|
|
253
253
|
rating: "",
|
|
254
254
|
notes: ""
|
|
255
|
-
}), O =
|
|
255
|
+
}), O = u(() => new Set(a), [a]), k = u(() => i.filter((e) => e.id === o || !O.has(e.id)), [
|
|
256
256
|
i,
|
|
257
257
|
O,
|
|
258
258
|
o
|
|
259
259
|
]);
|
|
260
|
-
|
|
261
|
-
e && (
|
|
260
|
+
l(() => {
|
|
261
|
+
e && (T(null), D({
|
|
262
262
|
influencerId: o ?? k[0]?.id ?? "",
|
|
263
|
-
status:
|
|
263
|
+
status: f,
|
|
264
264
|
rating: "",
|
|
265
265
|
notes: ""
|
|
266
266
|
}));
|
|
267
267
|
}, [
|
|
268
268
|
e,
|
|
269
269
|
o,
|
|
270
|
-
|
|
270
|
+
f,
|
|
271
271
|
k
|
|
272
272
|
]);
|
|
273
273
|
let A = async () => {
|
|
274
274
|
if (!E.influencerId) {
|
|
275
|
-
|
|
275
|
+
T("Select an influencer to add.");
|
|
276
276
|
return;
|
|
277
277
|
}
|
|
278
|
-
|
|
278
|
+
T(null);
|
|
279
279
|
try {
|
|
280
280
|
await m({ variables: { input: {
|
|
281
281
|
influencerId: E.influencerId,
|
|
@@ -285,72 +285,72 @@ var E = ({ open: t, onClose: n, influencers: i, defaultInfluencerId: a, onComple
|
|
|
285
285
|
firstContactDate: (/* @__PURE__ */ new Date()).toISOString()
|
|
286
286
|
} } }), await p?.(), n();
|
|
287
287
|
} catch (e) {
|
|
288
|
-
|
|
288
|
+
T(e instanceof Error ? e.message : "Failed to add relationship.");
|
|
289
289
|
}
|
|
290
290
|
};
|
|
291
|
-
return /* @__PURE__ */
|
|
291
|
+
return /* @__PURE__ */ g(c, {
|
|
292
292
|
open: e,
|
|
293
293
|
onClose: n,
|
|
294
294
|
title: "Add Influencer Relationship",
|
|
295
295
|
description: "Track a creator partnership in your roster.",
|
|
296
296
|
size: "md",
|
|
297
|
-
footer: /* @__PURE__ */
|
|
297
|
+
footer: /* @__PURE__ */ g(C, {
|
|
298
298
|
onCancel: n,
|
|
299
299
|
onSubmit: () => void A(),
|
|
300
|
-
submitLabel:
|
|
301
|
-
loading:
|
|
300
|
+
submitLabel: x ? "Adding..." : "Add Relationship",
|
|
301
|
+
loading: x,
|
|
302
302
|
disabled: k.length === 0
|
|
303
303
|
}),
|
|
304
|
-
children: /* @__PURE__ */
|
|
304
|
+
children: /* @__PURE__ */ _("div", {
|
|
305
305
|
className: "space-y-4",
|
|
306
|
-
children: [k.length === 0 ? /* @__PURE__ */
|
|
306
|
+
children: [k.length === 0 ? /* @__PURE__ */ g("p", {
|
|
307
307
|
className: "text-sm text-text-secondary",
|
|
308
308
|
children: "Every influencer already has a relationship. Add influencers from Discovery first."
|
|
309
|
-
}) : /* @__PURE__ */
|
|
310
|
-
/* @__PURE__ */
|
|
311
|
-
className:
|
|
309
|
+
}) : /* @__PURE__ */ _(h, { children: [
|
|
310
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
311
|
+
className: y,
|
|
312
312
|
children: "Influencer"
|
|
313
|
-
}), /* @__PURE__ */
|
|
313
|
+
}), /* @__PURE__ */ _("select", {
|
|
314
314
|
value: E.influencerId,
|
|
315
315
|
onChange: (e) => D((t) => ({
|
|
316
316
|
...t,
|
|
317
317
|
influencerId: e.target.value
|
|
318
318
|
})),
|
|
319
|
-
className:
|
|
320
|
-
children: [/* @__PURE__ */
|
|
319
|
+
className: v,
|
|
320
|
+
children: [/* @__PURE__ */ g("option", {
|
|
321
321
|
value: "",
|
|
322
322
|
children: "Select an influencer…"
|
|
323
|
-
}), k.map((e) => /* @__PURE__ */
|
|
323
|
+
}), k.map((e) => /* @__PURE__ */ g("option", {
|
|
324
324
|
value: e.id,
|
|
325
325
|
children: e.name
|
|
326
326
|
}, e.id))]
|
|
327
327
|
})] }),
|
|
328
|
-
/* @__PURE__ */
|
|
329
|
-
className:
|
|
328
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
329
|
+
className: y,
|
|
330
330
|
children: "Status"
|
|
331
|
-
}), /* @__PURE__ */
|
|
331
|
+
}), /* @__PURE__ */ g("select", {
|
|
332
332
|
value: E.status,
|
|
333
333
|
onChange: (e) => D((t) => ({
|
|
334
334
|
...t,
|
|
335
335
|
status: e.target.value
|
|
336
336
|
})),
|
|
337
|
-
className:
|
|
338
|
-
children:
|
|
337
|
+
className: v,
|
|
338
|
+
children: b.map((e) => /* @__PURE__ */ g("option", {
|
|
339
339
|
value: e.value,
|
|
340
340
|
children: e.label
|
|
341
341
|
}, e.value))
|
|
342
342
|
})] }),
|
|
343
|
-
/* @__PURE__ */
|
|
344
|
-
className:
|
|
343
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
344
|
+
className: y,
|
|
345
345
|
children: "Rating (1-5)"
|
|
346
|
-
}), /* @__PURE__ */
|
|
346
|
+
}), /* @__PURE__ */ _("select", {
|
|
347
347
|
value: E.rating,
|
|
348
348
|
onChange: (e) => D((t) => ({
|
|
349
349
|
...t,
|
|
350
350
|
rating: e.target.value
|
|
351
351
|
})),
|
|
352
|
-
className:
|
|
353
|
-
children: [/* @__PURE__ */
|
|
352
|
+
className: v,
|
|
353
|
+
children: [/* @__PURE__ */ g("option", {
|
|
354
354
|
value: "",
|
|
355
355
|
children: "Not rated"
|
|
356
356
|
}), [
|
|
@@ -359,15 +359,15 @@ var E = ({ open: t, onClose: n, influencers: i, defaultInfluencerId: a, onComple
|
|
|
359
359
|
3,
|
|
360
360
|
4,
|
|
361
361
|
5
|
|
362
|
-
].map((e) => /* @__PURE__ */
|
|
362
|
+
].map((e) => /* @__PURE__ */ g("option", {
|
|
363
363
|
value: e,
|
|
364
364
|
children: e
|
|
365
365
|
}, e))]
|
|
366
366
|
})] }),
|
|
367
|
-
/* @__PURE__ */
|
|
368
|
-
className:
|
|
367
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
368
|
+
className: y,
|
|
369
369
|
children: "Notes"
|
|
370
|
-
}), /* @__PURE__ */
|
|
370
|
+
}), /* @__PURE__ */ g("textarea", {
|
|
371
371
|
value: E.notes,
|
|
372
372
|
onChange: (e) => D((t) => ({
|
|
373
373
|
...t,
|
|
@@ -375,30 +375,30 @@ var E = ({ open: t, onClose: n, influencers: i, defaultInfluencerId: a, onComple
|
|
|
375
375
|
})),
|
|
376
376
|
rows: 3,
|
|
377
377
|
placeholder: "Context on this partnership…",
|
|
378
|
-
className: r(
|
|
378
|
+
className: r(v, "resize-none")
|
|
379
379
|
})] })
|
|
380
|
-
] }), /* @__PURE__ */
|
|
380
|
+
] }), /* @__PURE__ */ g(w, { message: S })]
|
|
381
381
|
})
|
|
382
382
|
});
|
|
383
|
-
},
|
|
384
|
-
active:
|
|
385
|
-
pending:
|
|
386
|
-
inactive:
|
|
387
|
-
blocked:
|
|
388
|
-
},
|
|
389
|
-
let [o, { loading:
|
|
390
|
-
status:
|
|
383
|
+
}, D = {
|
|
384
|
+
active: s.Active,
|
|
385
|
+
pending: s.Outreach,
|
|
386
|
+
inactive: s.Paused,
|
|
387
|
+
blocked: s.Ended
|
|
388
|
+
}, O = ({ open: e, onClose: t, relationship: i, onCompleted: a }) => {
|
|
389
|
+
let [o, { loading: u }] = n(), [f, p] = d(null), [m, h] = d({
|
|
390
|
+
status: s.Active,
|
|
391
391
|
rating: "",
|
|
392
392
|
notes: ""
|
|
393
393
|
});
|
|
394
|
-
|
|
394
|
+
l(() => {
|
|
395
395
|
!e || !i || (p(null), h({
|
|
396
|
-
status:
|
|
396
|
+
status: D[i.status],
|
|
397
397
|
rating: i.averageROI ? String(i.averageROI) : "",
|
|
398
398
|
notes: i.notes ?? ""
|
|
399
399
|
}));
|
|
400
400
|
}, [e, i]);
|
|
401
|
-
let
|
|
401
|
+
let x = async () => {
|
|
402
402
|
if (i) {
|
|
403
403
|
p(null);
|
|
404
404
|
try {
|
|
@@ -416,47 +416,47 @@ var E = ({ open: t, onClose: n, influencers: i, defaultInfluencerId: a, onComple
|
|
|
416
416
|
}
|
|
417
417
|
}
|
|
418
418
|
};
|
|
419
|
-
return /* @__PURE__ */
|
|
419
|
+
return /* @__PURE__ */ g(c, {
|
|
420
420
|
open: e,
|
|
421
421
|
onClose: t,
|
|
422
422
|
title: "Edit Relationship",
|
|
423
423
|
description: i?.influencerName,
|
|
424
424
|
size: "md",
|
|
425
|
-
footer: /* @__PURE__ */
|
|
425
|
+
footer: /* @__PURE__ */ g(C, {
|
|
426
426
|
onCancel: t,
|
|
427
|
-
onSubmit: () => void
|
|
428
|
-
submitLabel:
|
|
429
|
-
loading:
|
|
427
|
+
onSubmit: () => void x(),
|
|
428
|
+
submitLabel: u ? "Saving..." : "Save Changes",
|
|
429
|
+
loading: u
|
|
430
430
|
}),
|
|
431
|
-
children: /* @__PURE__ */
|
|
431
|
+
children: /* @__PURE__ */ _("div", {
|
|
432
432
|
className: "space-y-4",
|
|
433
433
|
children: [
|
|
434
|
-
/* @__PURE__ */
|
|
435
|
-
className:
|
|
434
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
435
|
+
className: y,
|
|
436
436
|
children: "Status"
|
|
437
|
-
}), /* @__PURE__ */
|
|
437
|
+
}), /* @__PURE__ */ g("select", {
|
|
438
438
|
value: m.status,
|
|
439
439
|
onChange: (e) => h((t) => ({
|
|
440
440
|
...t,
|
|
441
441
|
status: e.target.value
|
|
442
442
|
})),
|
|
443
|
-
className:
|
|
444
|
-
children:
|
|
443
|
+
className: v,
|
|
444
|
+
children: b.map((e) => /* @__PURE__ */ g("option", {
|
|
445
445
|
value: e.value,
|
|
446
446
|
children: e.label
|
|
447
447
|
}, e.value))
|
|
448
448
|
})] }),
|
|
449
|
-
/* @__PURE__ */
|
|
450
|
-
className:
|
|
449
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
450
|
+
className: y,
|
|
451
451
|
children: "Rating (1-5)"
|
|
452
|
-
}), /* @__PURE__ */
|
|
452
|
+
}), /* @__PURE__ */ _("select", {
|
|
453
453
|
value: m.rating,
|
|
454
454
|
onChange: (e) => h((t) => ({
|
|
455
455
|
...t,
|
|
456
456
|
rating: e.target.value
|
|
457
457
|
})),
|
|
458
|
-
className:
|
|
459
|
-
children: [/* @__PURE__ */
|
|
458
|
+
className: v,
|
|
459
|
+
children: [/* @__PURE__ */ g("option", {
|
|
460
460
|
value: "",
|
|
461
461
|
children: "Not rated"
|
|
462
462
|
}), [
|
|
@@ -465,15 +465,15 @@ var E = ({ open: t, onClose: n, influencers: i, defaultInfluencerId: a, onComple
|
|
|
465
465
|
3,
|
|
466
466
|
4,
|
|
467
467
|
5
|
|
468
|
-
].map((e) => /* @__PURE__ */
|
|
468
|
+
].map((e) => /* @__PURE__ */ g("option", {
|
|
469
469
|
value: e,
|
|
470
470
|
children: e
|
|
471
471
|
}, e))]
|
|
472
472
|
})] }),
|
|
473
|
-
/* @__PURE__ */
|
|
474
|
-
className:
|
|
473
|
+
/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
|
|
474
|
+
className: y,
|
|
475
475
|
children: "Notes"
|
|
476
|
-
}), /* @__PURE__ */
|
|
476
|
+
}), /* @__PURE__ */ g("textarea", {
|
|
477
477
|
value: m.notes,
|
|
478
478
|
onChange: (e) => h((t) => ({
|
|
479
479
|
...t,
|
|
@@ -481,116 +481,103 @@ var E = ({ open: t, onClose: n, influencers: i, defaultInfluencerId: a, onComple
|
|
|
481
481
|
})),
|
|
482
482
|
rows: 4,
|
|
483
483
|
placeholder: "Relationship notes…",
|
|
484
|
-
className: r(
|
|
484
|
+
className: r(v, "resize-none")
|
|
485
485
|
})] }),
|
|
486
|
-
/* @__PURE__ */
|
|
486
|
+
/* @__PURE__ */ g(w, { message: f })
|
|
487
487
|
]
|
|
488
488
|
})
|
|
489
489
|
});
|
|
490
|
-
},
|
|
490
|
+
}, k = ({ open: e, onClose: t, influencer: n }) => n ? /* @__PURE__ */ g(c, {
|
|
491
491
|
open: e,
|
|
492
492
|
onClose: t,
|
|
493
493
|
title: n.name,
|
|
494
494
|
description: n.handle,
|
|
495
495
|
size: "md",
|
|
496
|
-
children: /* @__PURE__ */
|
|
496
|
+
children: /* @__PURE__ */ _("div", {
|
|
497
497
|
className: "space-y-4",
|
|
498
498
|
children: [
|
|
499
|
-
/* @__PURE__ */
|
|
499
|
+
/* @__PURE__ */ _("div", {
|
|
500
500
|
className: "flex flex-wrap items-center gap-2",
|
|
501
501
|
children: [
|
|
502
|
-
/* @__PURE__ */
|
|
502
|
+
/* @__PURE__ */ g("span", {
|
|
503
503
|
className: "rounded-full bg-bg-sunken px-2.5 py-0.5 text-xs font-medium capitalize text-text-primary",
|
|
504
504
|
children: n.tier
|
|
505
505
|
}),
|
|
506
|
-
/* @__PURE__ */
|
|
506
|
+
n.platforms.map((e) => /* @__PURE__ */ g("span", {
|
|
507
507
|
className: "rounded-full bg-bg-sunken px-2.5 py-0.5 text-xs font-medium capitalize text-text-primary",
|
|
508
|
-
children:
|
|
509
|
-
}),
|
|
510
|
-
/* @__PURE__ */
|
|
508
|
+
children: e
|
|
509
|
+
}, e)),
|
|
510
|
+
n.rating > 0 && /* @__PURE__ */ _("span", {
|
|
511
511
|
className: "inline-flex items-center gap-1 text-xs font-medium text-text-primary",
|
|
512
|
-
children: [/* @__PURE__ */
|
|
512
|
+
children: [/* @__PURE__ */ g(m, { className: "h-3 w-3 text-status-warning-text fill-[var(--color-status-warning)]" }), n.rating.toFixed(1)]
|
|
513
513
|
})
|
|
514
514
|
]
|
|
515
515
|
}),
|
|
516
|
-
n.bio && /* @__PURE__ */
|
|
516
|
+
n.bio && /* @__PURE__ */ g("p", {
|
|
517
517
|
className: "text-sm text-text-secondary",
|
|
518
518
|
children: n.bio
|
|
519
519
|
}),
|
|
520
|
-
/* @__PURE__ */
|
|
521
|
-
className: "grid grid-cols-
|
|
522
|
-
children: [
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
/* @__PURE__ */
|
|
534
|
-
className: "
|
|
535
|
-
children:
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
})]
|
|
542
|
-
}),
|
|
543
|
-
/* @__PURE__ */ v("div", {
|
|
544
|
-
className: "rounded-md bg-bg-sunken/50 py-3",
|
|
545
|
-
children: [/* @__PURE__ */ _("p", {
|
|
546
|
-
className: "text-sm font-bold text-text-primary",
|
|
547
|
-
children: i(n.ratePerPost)
|
|
548
|
-
}), /* @__PURE__ */ _("p", {
|
|
549
|
-
className: "text-[10px] text-text-secondary",
|
|
550
|
-
children: "Per Post"
|
|
551
|
-
})]
|
|
552
|
-
})
|
|
553
|
-
]
|
|
520
|
+
/* @__PURE__ */ _("div", {
|
|
521
|
+
className: "grid grid-cols-2 gap-3 text-center",
|
|
522
|
+
children: [/* @__PURE__ */ _("div", {
|
|
523
|
+
className: "rounded-md bg-bg-sunken/50 py-3",
|
|
524
|
+
children: [/* @__PURE__ */ g("p", {
|
|
525
|
+
className: "text-sm font-bold text-text-primary",
|
|
526
|
+
children: i(n.followers)
|
|
527
|
+
}), /* @__PURE__ */ g("p", {
|
|
528
|
+
className: "text-[10px] text-text-secondary",
|
|
529
|
+
children: "Followers"
|
|
530
|
+
})]
|
|
531
|
+
}), /* @__PURE__ */ _("div", {
|
|
532
|
+
className: "rounded-md bg-bg-sunken/50 py-3",
|
|
533
|
+
children: [/* @__PURE__ */ g("p", {
|
|
534
|
+
className: "text-sm font-bold text-text-primary",
|
|
535
|
+
children: a(n.engagementRate)
|
|
536
|
+
}), /* @__PURE__ */ g("p", {
|
|
537
|
+
className: "text-[10px] text-text-secondary",
|
|
538
|
+
children: "Engagement rate"
|
|
539
|
+
})]
|
|
540
|
+
})]
|
|
554
541
|
}),
|
|
555
|
-
/* @__PURE__ */
|
|
542
|
+
/* @__PURE__ */ _("dl", {
|
|
556
543
|
className: "space-y-2 text-sm",
|
|
557
544
|
children: [
|
|
558
|
-
/* @__PURE__ */
|
|
545
|
+
/* @__PURE__ */ _("div", {
|
|
559
546
|
className: "flex justify-between gap-4",
|
|
560
|
-
children: [/* @__PURE__ */
|
|
547
|
+
children: [/* @__PURE__ */ g("dt", {
|
|
561
548
|
className: "text-text-secondary",
|
|
562
549
|
children: "Location"
|
|
563
|
-
}), /* @__PURE__ */
|
|
550
|
+
}), /* @__PURE__ */ g("dd", {
|
|
564
551
|
className: "text-text-primary",
|
|
565
552
|
children: n.location
|
|
566
553
|
})]
|
|
567
554
|
}),
|
|
568
|
-
n.email && /* @__PURE__ */
|
|
555
|
+
n.email && /* @__PURE__ */ _("div", {
|
|
569
556
|
className: "flex justify-between gap-4",
|
|
570
|
-
children: [/* @__PURE__ */
|
|
557
|
+
children: [/* @__PURE__ */ g("dt", {
|
|
571
558
|
className: "text-text-secondary",
|
|
572
559
|
children: "Email"
|
|
573
|
-
}), /* @__PURE__ */
|
|
560
|
+
}), /* @__PURE__ */ g("dd", {
|
|
574
561
|
className: "truncate text-text-primary",
|
|
575
562
|
children: n.email
|
|
576
563
|
})]
|
|
577
564
|
}),
|
|
578
|
-
n.phone && /* @__PURE__ */
|
|
565
|
+
n.phone && /* @__PURE__ */ _("div", {
|
|
579
566
|
className: "flex justify-between gap-4",
|
|
580
|
-
children: [/* @__PURE__ */
|
|
567
|
+
children: [/* @__PURE__ */ g("dt", {
|
|
581
568
|
className: "text-text-secondary",
|
|
582
569
|
children: "Phone"
|
|
583
|
-
}), /* @__PURE__ */
|
|
570
|
+
}), /* @__PURE__ */ g("dd", {
|
|
584
571
|
className: "truncate text-text-primary",
|
|
585
572
|
children: n.phone
|
|
586
573
|
})]
|
|
587
574
|
}),
|
|
588
|
-
n.niche.length > 0 && /* @__PURE__ */
|
|
575
|
+
n.niche.length > 0 && /* @__PURE__ */ _("div", {
|
|
589
576
|
className: "flex justify-between gap-4",
|
|
590
|
-
children: [/* @__PURE__ */
|
|
577
|
+
children: [/* @__PURE__ */ g("dt", {
|
|
591
578
|
className: "text-text-secondary",
|
|
592
579
|
children: "Niches"
|
|
593
|
-
}), /* @__PURE__ */
|
|
580
|
+
}), /* @__PURE__ */ g("dd", {
|
|
594
581
|
className: "text-right text-text-primary",
|
|
595
582
|
children: n.niche.join(", ")
|
|
596
583
|
})]
|
|
@@ -601,6 +588,6 @@ var E = ({ open: t, onClose: n, influencers: i, defaultInfluencerId: a, onComple
|
|
|
601
588
|
})
|
|
602
589
|
}) : null;
|
|
603
590
|
//#endregion
|
|
604
|
-
export {
|
|
591
|
+
export { E as AddInfluencerRelationshipModal, T as CreateInfluencerCampaignModal, O as EditInfluencerRelationshipModal, k as InfluencerDetailsModal };
|
|
605
592
|
|
|
606
593
|
//# sourceMappingURL=InfluencerModals.js.map
|