@burdenoff/microfe-headshotmarketing 2026.1205.1 → 2026.1206.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.
Files changed (144) hide show
  1. package/dist/generated/global-types.d.ts +3589 -380
  2. package/dist/generated/wspace-operations.d.ts +101 -3
  3. package/dist/generated/wspace-operations.js.map +1 -1
  4. package/dist/generated/wspace-types.d.ts +61782 -2332
  5. package/dist/generated/wspace-types.js.map +1 -1
  6. package/dist/headshotmarketing/components/EntityTagPicker.js +29 -28
  7. package/dist/headshotmarketing/components/EntityTagPicker.js.map +1 -1
  8. package/dist/headshotmarketing/components/InfluencerModals.js +264 -263
  9. package/dist/headshotmarketing/components/InfluencerModals.js.map +1 -1
  10. package/dist/headshotmarketing/components/QueryStateBoundary.js +31 -22
  11. package/dist/headshotmarketing/components/QueryStateBoundary.js.map +1 -1
  12. package/dist/headshotmarketing/components/StatusBadge.js +1 -1
  13. package/dist/headshotmarketing/components/StatusBadge.js.map +1 -1
  14. package/dist/headshotmarketing/components/Toast.js +3 -3
  15. package/dist/headshotmarketing/components/Toast.js.map +1 -1
  16. package/dist/headshotmarketing/components/TrackedLinksPanel.js +97 -96
  17. package/dist/headshotmarketing/components/TrackedLinksPanel.js.map +1 -1
  18. package/dist/headshotmarketing/hooks/useAssetUpload.js +41 -40
  19. package/dist/headshotmarketing/hooks/useAssetUpload.js.map +1 -1
  20. package/dist/headshotmarketing/pages/HomePage.js +6 -6
  21. package/dist/headshotmarketing/pages/HomePage.js.map +1 -1
  22. package/dist/headshotmarketing/pages/ads/AdBudgetAiPanel.js +47 -46
  23. package/dist/headshotmarketing/pages/ads/AdBudgetAiPanel.js.map +1 -1
  24. package/dist/headshotmarketing/pages/ads/AdCampaignDetailsPage.js +66 -65
  25. package/dist/headshotmarketing/pages/ads/AdCampaignDetailsPage.js.map +1 -1
  26. package/dist/headshotmarketing/pages/ads/AdCampaignsPage.js +273 -272
  27. package/dist/headshotmarketing/pages/ads/AdCampaignsPage.js.map +1 -1
  28. package/dist/headshotmarketing/pages/ads/AdCreativeTestsSection.js +3 -3
  29. package/dist/headshotmarketing/pages/ads/AdCreativeTestsSection.js.map +1 -1
  30. package/dist/headshotmarketing/pages/ads/AdCreativesPage.js +125 -124
  31. package/dist/headshotmarketing/pages/ads/AdCreativesPage.js.map +1 -1
  32. package/dist/headshotmarketing/pages/ads/AdPlatformConnectionsSection.js +33 -32
  33. package/dist/headshotmarketing/pages/ads/AdPlatformConnectionsSection.js.map +1 -1
  34. package/dist/headshotmarketing/pages/ads/AdPlatformSyncPanel.js +108 -107
  35. package/dist/headshotmarketing/pages/ads/AdPlatformSyncPanel.js.map +1 -1
  36. package/dist/headshotmarketing/pages/ads/AdReachEstimatePanel.js +65 -60
  37. package/dist/headshotmarketing/pages/ads/AdReachEstimatePanel.js.map +1 -1
  38. package/dist/headshotmarketing/pages/ads/AdsPage.js +4 -4
  39. package/dist/headshotmarketing/pages/ads/AdsPage.js.map +1 -1
  40. package/dist/headshotmarketing/pages/ads/AudiencesPage.js +287 -286
  41. package/dist/headshotmarketing/pages/ads/AudiencesPage.js.map +1 -1
  42. package/dist/headshotmarketing/pages/ads/CreateAdCampaignPage.js +59 -54
  43. package/dist/headshotmarketing/pages/ads/CreateAdCampaignPage.js.map +1 -1
  44. package/dist/headshotmarketing/pages/ads/CreateAudiencePage.js +96 -95
  45. package/dist/headshotmarketing/pages/ads/CreateAudiencePage.js.map +1 -1
  46. package/dist/headshotmarketing/pages/ai/AiDecisionCard.js +5 -5
  47. package/dist/headshotmarketing/pages/ai/AiDecisionCard.js.map +1 -1
  48. package/dist/headshotmarketing/pages/ai/AiOperationsPage.js +179 -178
  49. package/dist/headshotmarketing/pages/ai/AiOperationsPage.js.map +1 -1
  50. package/dist/headshotmarketing/pages/analytics/ReportScheduleDialog.js +156 -151
  51. package/dist/headshotmarketing/pages/analytics/ReportScheduleDialog.js.map +1 -1
  52. package/dist/headshotmarketing/pages/analytics/ReportsPage.js +222 -217
  53. package/dist/headshotmarketing/pages/analytics/ReportsPage.js.map +1 -1
  54. package/dist/headshotmarketing/pages/analytics/TouchpointLedgerCard.js +59 -58
  55. package/dist/headshotmarketing/pages/analytics/TouchpointLedgerCard.js.map +1 -1
  56. package/dist/headshotmarketing/pages/analytics/analyticsWidgets.js +152 -151
  57. package/dist/headshotmarketing/pages/analytics/analyticsWidgets.js.map +1 -1
  58. package/dist/headshotmarketing/pages/automation/AutomationPage.js +34 -33
  59. package/dist/headshotmarketing/pages/automation/AutomationPage.js.map +1 -1
  60. package/dist/headshotmarketing/pages/automation/TriggersPage.js +6 -6
  61. package/dist/headshotmarketing/pages/automation/TriggersPage.js.map +1 -1
  62. package/dist/headshotmarketing/pages/automation/WorkflowActions.js +1 -1
  63. package/dist/headshotmarketing/pages/automation/WorkflowActions.js.map +1 -1
  64. package/dist/headshotmarketing/pages/automation/WorkflowBuilderPage.js +235 -234
  65. package/dist/headshotmarketing/pages/automation/WorkflowBuilderPage.js.map +1 -1
  66. package/dist/headshotmarketing/pages/automation/WorkflowRunsPanel.js +24 -23
  67. package/dist/headshotmarketing/pages/automation/WorkflowRunsPanel.js.map +1 -1
  68. package/dist/headshotmarketing/pages/automation/WorkflowsPage.js +1 -1
  69. package/dist/headshotmarketing/pages/automation/WorkflowsPage.js.map +1 -1
  70. package/dist/headshotmarketing/pages/automation/workflowBuilderModel.js +4 -4
  71. package/dist/headshotmarketing/pages/automation/workflowBuilderModel.js.map +1 -1
  72. package/dist/headshotmarketing/pages/builder/LandingPageBuilderPage.js +339 -338
  73. package/dist/headshotmarketing/pages/builder/LandingPageBuilderPage.js.map +1 -1
  74. package/dist/headshotmarketing/pages/campaigns/CampaignAiPanel.js +95 -94
  75. package/dist/headshotmarketing/pages/campaigns/CampaignAiPanel.js.map +1 -1
  76. package/dist/headshotmarketing/pages/campaigns/CampaignDetailsPage.js +82 -81
  77. package/dist/headshotmarketing/pages/campaigns/CampaignDetailsPage.js.map +1 -1
  78. package/dist/headshotmarketing/pages/campaigns/CampaignTemplatesPage.js +107 -106
  79. package/dist/headshotmarketing/pages/campaigns/CampaignTemplatesPage.js.map +1 -1
  80. package/dist/headshotmarketing/pages/campaigns/CampaignsPage.js +104 -103
  81. package/dist/headshotmarketing/pages/campaigns/CampaignsPage.js.map +1 -1
  82. package/dist/headshotmarketing/pages/campaigns/CreateCampaignPage.js +262 -261
  83. package/dist/headshotmarketing/pages/campaigns/CreateCampaignPage.js.map +1 -1
  84. package/dist/headshotmarketing/pages/campaigns/CreateTemplateModal.js +68 -67
  85. package/dist/headshotmarketing/pages/campaigns/CreateTemplateModal.js.map +1 -1
  86. package/dist/headshotmarketing/pages/content/AIToolsPage.js +204 -203
  87. package/dist/headshotmarketing/pages/content/AIToolsPage.js.map +1 -1
  88. package/dist/headshotmarketing/pages/content/AssetLibraryPage.js +177 -176
  89. package/dist/headshotmarketing/pages/content/AssetLibraryPage.js.map +1 -1
  90. package/dist/headshotmarketing/pages/content/ContentCreationPage.js +373 -372
  91. package/dist/headshotmarketing/pages/content/ContentCreationPage.js.map +1 -1
  92. package/dist/headshotmarketing/pages/content/ContentDetailsPage.js +1 -1
  93. package/dist/headshotmarketing/pages/content/ContentDetailsPage.js.map +1 -1
  94. package/dist/headshotmarketing/pages/content/ContentLibraryCard.js +4 -4
  95. package/dist/headshotmarketing/pages/content/ContentLibraryCard.js.map +1 -1
  96. package/dist/headshotmarketing/pages/crm/ConvertLeadButton.js +51 -50
  97. package/dist/headshotmarketing/pages/crm/ConvertLeadButton.js.map +1 -1
  98. package/dist/headshotmarketing/pages/crm/CreateContactPage.js +100 -99
  99. package/dist/headshotmarketing/pages/crm/CreateContactPage.js.map +1 -1
  100. package/dist/headshotmarketing/pages/crm/CreateDealPage.js +134 -133
  101. package/dist/headshotmarketing/pages/crm/CreateDealPage.js.map +1 -1
  102. package/dist/headshotmarketing/pages/crm/CreatePipelineModal.js +66 -65
  103. package/dist/headshotmarketing/pages/crm/CreatePipelineModal.js.map +1 -1
  104. package/dist/headshotmarketing/pages/crm/CrmActions.js +229 -228
  105. package/dist/headshotmarketing/pages/crm/CrmActions.js.map +1 -1
  106. package/dist/headshotmarketing/pages/crm/DealNextActionPanel.js +62 -61
  107. package/dist/headshotmarketing/pages/crm/DealNextActionPanel.js.map +1 -1
  108. package/dist/headshotmarketing/pages/crm/LeadAiDecisionPanel.js +126 -125
  109. package/dist/headshotmarketing/pages/crm/LeadAiDecisionPanel.js.map +1 -1
  110. package/dist/headshotmarketing/pages/crm/LeadCreateModal.js +93 -92
  111. package/dist/headshotmarketing/pages/crm/LeadCreateModal.js.map +1 -1
  112. package/dist/headshotmarketing/pages/crm/PipelinePage.js +5 -5
  113. package/dist/headshotmarketing/pages/crm/PipelinePage.js.map +1 -1
  114. package/dist/headshotmarketing/pages/events/CreateEventPage.js +127 -126
  115. package/dist/headshotmarketing/pages/events/CreateEventPage.js.map +1 -1
  116. package/dist/headshotmarketing/pages/events/EventDetailsPage.js +76 -75
  117. package/dist/headshotmarketing/pages/events/EventDetailsPage.js.map +1 -1
  118. package/dist/headshotmarketing/pages/influencers/InfluencerDiscoveryPage.js +8 -8
  119. package/dist/headshotmarketing/pages/influencers/InfluencerDiscoveryPage.js.map +1 -1
  120. package/dist/headshotmarketing/pages/influencers/InfluencersPage.js +4 -4
  121. package/dist/headshotmarketing/pages/influencers/InfluencersPage.js.map +1 -1
  122. package/dist/headshotmarketing/pages/influencers/RelationshipsPage.js +4 -4
  123. package/dist/headshotmarketing/pages/influencers/RelationshipsPage.js.map +1 -1
  124. package/dist/headshotmarketing/pages/seo/SeoScorePanel.js +1 -1
  125. package/dist/headshotmarketing/pages/seo/SeoScorePanel.js.map +1 -1
  126. package/dist/headshotmarketing/pages/seo/SeoToolsPage.js +104 -103
  127. package/dist/headshotmarketing/pages/seo/SeoToolsPage.js.map +1 -1
  128. package/dist/headshotmarketing/pages/social-media/AccountsPage.js +102 -101
  129. package/dist/headshotmarketing/pages/social-media/AccountsPage.js.map +1 -1
  130. package/dist/headshotmarketing/pages/social-media/CreateAccountPage.js +59 -58
  131. package/dist/headshotmarketing/pages/social-media/CreateAccountPage.js.map +1 -1
  132. package/dist/headshotmarketing/pages/social-media/MediaDropZone.js +1 -1
  133. package/dist/headshotmarketing/pages/social-media/MediaDropZone.js.map +1 -1
  134. package/dist/headshotmarketing/pages/social-media/PostsPage.js +103 -102
  135. package/dist/headshotmarketing/pages/social-media/PostsPage.js.map +1 -1
  136. package/dist/headshotmarketing/pages/social-media/SocialMediaComposePage.js +123 -122
  137. package/dist/headshotmarketing/pages/social-media/SocialMediaComposePage.js.map +1 -1
  138. package/dist/headshotmarketing/pages/social-media/SocialMediaPage.js +4 -4
  139. package/dist/headshotmarketing/pages/social-media/SocialMediaPage.js.map +1 -1
  140. package/dist/headshotmarketing/utils/index.d.ts +1 -0
  141. package/dist/headshotmarketing/utils/readableError.d.ts +16 -0
  142. package/dist/headshotmarketing/utils/readableError.js +12 -0
  143. package/dist/headshotmarketing/utils/readableError.js.map +1 -0
  144. package/package.json +5 -3
@@ -4,28 +4,29 @@ import { HeadshotmarketingReportRecipientIdentitiesDocument as t, Headshotmarket
4
4
  import { Modal as i } from "../../components/Modal.js";
5
5
  import { HeadshotmarketingReportScheduleCadence as a } from "../../../generated/wspace-types.js";
6
6
  import { WEEKDAYS as o, deliveryStatusLabel as s, deliveryStatusTone as c, describeSchedule as l, formatHour as u, formatInstant as d, ordinal as f, timezoneOptions as p, toggleRecipient as m } from "./reportSchedule.js";
7
- import { useEffect as h, useMemo as g, useState as _ } from "react";
8
- import { Send as v, Trash2 as y } from "lucide-react";
9
- import { useApolloClient as b } from "@apollo/client/react";
10
- import { Fragment as x, jsx as S, jsxs as C } from "react/jsx-runtime";
11
- import { ThemedSelect as w } from "@burdenoff/fe-libs/ui";
7
+ import { readableError as h, readableErrorOrNull as g } from "../../utils/readableError.js";
8
+ import { useEffect as _, useMemo as v, useState as y } from "react";
9
+ import { Send as b, Trash2 as x } from "lucide-react";
10
+ import { useApolloClient as S } from "@apollo/client/react";
11
+ import { Fragment as C, jsx as w, jsxs as T } from "react/jsx-runtime";
12
+ import { ThemedSelect as E } from "@burdenoff/fe-libs/ui";
12
13
  // src/headshotmarketing/pages/analytics/ReportScheduleDialog.tsx
13
- var T = "inline-flex min-h-[40px] items-center gap-2 rounded-md border border-border-seam bg-bg-surface px-3 py-2 text-sm font-medium text-text-primary transition-colors hover:bg-bg-sunken disabled:cursor-not-allowed disabled:opacity-60", E = "min-h-[44px] w-full rounded-md border bg-bg-surface px-3 py-2 text-sm text-text-primary", D = 100, O = 10;
14
- function k(e, r) {
15
- let i = b(), [a, o] = _([]), [s, c] = _(!1), [l, u] = _(null);
16
- return h(() => {
14
+ var D = "inline-flex min-h-[40px] items-center gap-2 rounded-md border border-border-seam bg-bg-surface px-3 py-2 text-sm font-medium text-text-primary transition-colors hover:bg-bg-sunken disabled:cursor-not-allowed disabled:opacity-60", O = "min-h-[44px] w-full rounded-md border bg-bg-surface px-3 py-2 text-sm text-text-primary", k = 100, A = 10;
15
+ function j(e, r) {
16
+ let i = S(), [a, o] = y([]), [s, c] = y(!1), [l, u] = y(null);
17
+ return _(() => {
17
18
  if (!r || !e) return;
18
19
  let a = !1;
19
20
  return (async () => {
20
21
  c(!0), u(null);
21
22
  try {
22
23
  let r = [];
23
- for (let t = 0; t < O; t += 1) {
24
+ for (let t = 0; t < A; t += 1) {
24
25
  let a = (await i.query({
25
26
  query: n,
26
27
  variables: {
27
28
  workspaceId: e,
28
- offset: t * D
29
+ offset: t * k
29
30
  },
30
31
  fetchPolicy: "network-only"
31
32
  })).data?.workspaceMembers;
@@ -34,8 +35,8 @@ function k(e, r) {
34
35
  if (!a.hasMore) break;
35
36
  }
36
37
  let s = [...new Set(r)], c = [];
37
- for (let n = 0; n < s.length; n += D) {
38
- let r = s.slice(n, n + D), a = await i.query({
38
+ for (let n = 0; n < s.length; n += k) {
39
+ let r = s.slice(n, n + k), a = await i.query({
39
40
  query: t,
40
41
  variables: {
41
42
  workspaceId: e,
@@ -51,7 +52,7 @@ function k(e, r) {
51
52
  }
52
53
  c.sort((e, t) => e.name.localeCompare(t.name)), a || o(c);
53
54
  } catch (e) {
54
- a || u(e instanceof Error ? e.message : "Members could not be loaded.");
55
+ a || u(h(e, "Members could not be loaded."));
55
56
  } finally {
56
57
  a || c(!1);
57
58
  }
@@ -68,256 +69,256 @@ function k(e, r) {
68
69
  error: l
69
70
  };
70
71
  }
71
- var A = {
72
+ var M = {
72
73
  success: "text-status-success-text",
73
74
  warning: "text-status-warning-text",
74
75
  error: "text-status-error-text",
75
76
  neutral: "text-text-secondary"
76
- }, j = ({ open: t, reportId: n, reportName: h, workspaceId: _, schedule: b, draft: D, onChange: O, errors: j, serverError: M, busy: N, onClose: P, onSave: F, onRemove: I, onSendNow: L }) => {
77
- let R = k(_, t), z = g(() => p(D.timezone), [D.timezone]), B = r({
77
+ }, N = ({ open: t, reportId: n, reportName: h, workspaceId: _, schedule: y, draft: S, onChange: k, errors: A, serverError: N, busy: P, onClose: F, onSave: I, onRemove: L, onSendNow: R }) => {
78
+ let z = j(_, t), B = v(() => p(S.timezone), [S.timezone]), V = r({
78
79
  variables: { reportId: n },
79
- skip: !t || !b,
80
+ skip: !t || !y,
80
81
  fetchPolicy: "cache-and-network"
81
- }), V = B.data?.headshotmarketingSavedReportDeliveryRuns.items ?? [], H = new Set(R.members.map((e) => e.userId)), U = D.recipientUserIds.filter((e) => !H.has(e)), W = D.cadence === a.Weekly, G = N !== null;
82
- return /* @__PURE__ */ S(i, {
82
+ }), H = V.data?.headshotmarketingSavedReportDeliveryRuns.items ?? [], U = new Set(z.members.map((e) => e.userId)), W = S.recipientUserIds.filter((e) => !U.has(e)), G = S.cadence === a.Weekly, K = P !== null;
83
+ return /* @__PURE__ */ w(i, {
83
84
  open: t,
84
- onClose: P,
85
- title: b ? "Delivery schedule" : "Schedule report",
85
+ onClose: F,
86
+ title: y ? "Delivery schedule" : "Schedule report",
86
87
  description: `Email "${h}" to workspace members on a regular schedule. Each email covers the report's period at the time it is sent.`,
87
88
  size: "lg",
88
- footer: /* @__PURE__ */ C(x, { children: [
89
- b && /* @__PURE__ */ C("button", {
89
+ footer: /* @__PURE__ */ T(C, { children: [
90
+ y && /* @__PURE__ */ T("button", {
90
91
  type: "button",
91
- onClick: I,
92
- disabled: G,
93
- className: e(T, "me-auto text-status-error-text"),
94
- children: [/* @__PURE__ */ S(y, { className: "h-4 w-4" }), N === "remove" ? "Removing…" : "Remove schedule"]
92
+ onClick: L,
93
+ disabled: K,
94
+ className: e(D, "me-auto text-status-error-text"),
95
+ children: [/* @__PURE__ */ w(x, { className: "h-4 w-4" }), P === "remove" ? "Removing…" : "Remove schedule"]
95
96
  }),
96
- /* @__PURE__ */ S("button", {
97
+ /* @__PURE__ */ w("button", {
97
98
  type: "button",
98
- onClick: P,
99
- disabled: G,
100
- className: T,
99
+ onClick: F,
100
+ disabled: K,
101
+ className: D,
101
102
  children: "Cancel"
102
103
  }),
103
- /* @__PURE__ */ S("button", {
104
+ /* @__PURE__ */ w("button", {
104
105
  type: "button",
105
- onClick: F,
106
- disabled: G,
106
+ onClick: I,
107
+ disabled: K,
107
108
  className: "inline-flex min-h-[40px] items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text transition-colors hover:bg-action-primary-bg/90 disabled:cursor-not-allowed disabled:opacity-60",
108
- children: N === "save" ? "Saving…" : b ? "Save schedule" : "Create schedule"
109
+ children: P === "save" ? "Saving…" : y ? "Save schedule" : "Create schedule"
109
110
  })
110
111
  ] }),
111
- children: /* @__PURE__ */ C("div", {
112
+ children: /* @__PURE__ */ T("div", {
112
113
  className: "space-y-5",
113
114
  children: [
114
- b && /* @__PURE__ */ C("div", {
115
+ y && /* @__PURE__ */ T("div", {
115
116
  className: "flex flex-col gap-3 rounded-lg border border-border-seam bg-bg-sunken/30 px-4 py-3 text-sm sm:flex-row sm:items-center sm:justify-between",
116
- children: [/* @__PURE__ */ C("div", {
117
+ children: [/* @__PURE__ */ T("div", {
117
118
  className: "min-w-0",
118
- children: [/* @__PURE__ */ S("p", {
119
+ children: [/* @__PURE__ */ w("p", {
119
120
  className: "font-medium text-text-primary",
120
- children: l(b)
121
- }), /* @__PURE__ */ C("p", {
121
+ children: l(y)
122
+ }), /* @__PURE__ */ T("p", {
122
123
  className: "mt-0.5 text-xs text-text-secondary",
123
- children: [b.enabled ? `Next delivery ${d(b.nextRunAt)}` : "Paused", b.lastRunStatus && /* @__PURE__ */ C(x, { children: [
124
+ children: [y.enabled ? `Next delivery ${d(y.nextRunAt)}` : "Paused", y.lastRunStatus && /* @__PURE__ */ T(C, { children: [
124
125
  " · Last: ",
125
- /* @__PURE__ */ S("span", {
126
- className: A[c(b.lastRunStatus)],
127
- children: s(b.lastRunStatus)
126
+ /* @__PURE__ */ w("span", {
127
+ className: M[c(y.lastRunStatus)],
128
+ children: s(y.lastRunStatus)
128
129
  }),
129
130
  " ",
130
- d(b.lastRunAt)
131
+ d(y.lastRunAt)
131
132
  ] })]
132
133
  })]
133
- }), /* @__PURE__ */ C("button", {
134
+ }), /* @__PURE__ */ T("button", {
134
135
  type: "button",
135
- onClick: L,
136
- disabled: G,
137
- className: e(T, "shrink-0"),
136
+ onClick: R,
137
+ disabled: K,
138
+ className: e(D, "shrink-0"),
138
139
  title: "Email the report to the saved recipients now. The next scheduled delivery does not move.",
139
- children: [/* @__PURE__ */ S(v, { className: "h-4 w-4" }), N === "send" ? "Sending…" : "Send now"]
140
+ children: [/* @__PURE__ */ w(b, { className: "h-4 w-4" }), P === "send" ? "Sending…" : "Send now"]
140
141
  })]
141
142
  }),
142
- /* @__PURE__ */ C("fieldset", { children: [/* @__PURE__ */ S("legend", {
143
+ /* @__PURE__ */ T("fieldset", { children: [/* @__PURE__ */ w("legend", {
143
144
  className: "mb-2 text-sm font-medium text-text-primary",
144
145
  children: "Frequency"
145
- }), /* @__PURE__ */ S("div", {
146
+ }), /* @__PURE__ */ w("div", {
146
147
  role: "radiogroup",
147
148
  "aria-label": "Frequency",
148
149
  className: "inline-flex rounded-md border border-border-seam p-0.5",
149
- children: [a.Weekly, a.Monthly].map((t) => /* @__PURE__ */ S("button", {
150
+ children: [a.Weekly, a.Monthly].map((t) => /* @__PURE__ */ w("button", {
150
151
  type: "button",
151
152
  role: "radio",
152
- "aria-checked": D.cadence === t,
153
- onClick: () => O({
154
- ...D,
153
+ "aria-checked": S.cadence === t,
154
+ onClick: () => k({
155
+ ...S,
155
156
  cadence: t
156
157
  }),
157
- className: e("min-h-[36px] rounded px-4 text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]", D.cadence === t ? "bg-action-primary-bg text-action-primary-text" : "text-text-secondary hover:bg-bg-sunken"),
158
+ className: e("min-h-[36px] rounded px-4 text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]", S.cadence === t ? "bg-action-primary-bg text-action-primary-text" : "text-text-secondary hover:bg-bg-sunken"),
158
159
  children: t === a.Weekly ? "Weekly" : "Monthly"
159
160
  }, t))
160
161
  })] }),
161
- /* @__PURE__ */ C("div", {
162
+ /* @__PURE__ */ T("div", {
162
163
  className: "grid grid-cols-1 gap-4 sm:grid-cols-3",
163
164
  children: [
164
- W ? /* @__PURE__ */ C("div", { children: [
165
- /* @__PURE__ */ S("label", {
165
+ G ? /* @__PURE__ */ T("div", { children: [
166
+ /* @__PURE__ */ w("label", {
166
167
  htmlFor: "hm-schedule-weekday",
167
168
  className: "mb-1 block text-sm font-medium text-text-primary",
168
169
  children: "Day"
169
170
  }),
170
- /* @__PURE__ */ S(w, {
171
+ /* @__PURE__ */ w(E, {
171
172
  id: "hm-schedule-weekday",
172
- value: D.dayOfWeek,
173
- onChange: (e) => O({
174
- ...D,
173
+ value: S.dayOfWeek,
174
+ onChange: (e) => k({
175
+ ...S,
175
176
  dayOfWeek: Number(e.target.value)
176
177
  }),
177
- "aria-invalid": !!j.dayOfWeek,
178
- className: e(E, j.dayOfWeek ? "border-status-error-border" : "border-border-seam"),
179
- children: o.map((e, t) => /* @__PURE__ */ S("option", {
178
+ "aria-invalid": !!A.dayOfWeek,
179
+ className: e(O, A.dayOfWeek ? "border-status-error-border" : "border-border-seam"),
180
+ children: o.map((e, t) => /* @__PURE__ */ w("option", {
180
181
  value: t,
181
182
  children: e
182
183
  }, e))
183
184
  }),
184
- j.dayOfWeek && /* @__PURE__ */ S("p", {
185
+ A.dayOfWeek && /* @__PURE__ */ w("p", {
185
186
  className: "mt-1 text-xs text-status-error-text",
186
- children: j.dayOfWeek
187
+ children: A.dayOfWeek
187
188
  })
188
- ] }) : /* @__PURE__ */ C("div", { children: [
189
- /* @__PURE__ */ S("label", {
189
+ ] }) : /* @__PURE__ */ T("div", { children: [
190
+ /* @__PURE__ */ w("label", {
190
191
  htmlFor: "hm-schedule-monthday",
191
192
  className: "mb-1 block text-sm font-medium text-text-primary",
192
193
  children: "Day of month"
193
194
  }),
194
- /* @__PURE__ */ S(w, {
195
+ /* @__PURE__ */ w(E, {
195
196
  id: "hm-schedule-monthday",
196
- value: D.dayOfMonth,
197
- onChange: (e) => O({
198
- ...D,
197
+ value: S.dayOfMonth,
198
+ onChange: (e) => k({
199
+ ...S,
199
200
  dayOfMonth: Number(e.target.value)
200
201
  }),
201
- "aria-invalid": !!j.dayOfMonth,
202
- className: e(E, j.dayOfMonth ? "border-status-error-border" : "border-border-seam"),
203
- children: Array.from({ length: 28 }, (e, t) => t + 1).map((e) => /* @__PURE__ */ S("option", {
202
+ "aria-invalid": !!A.dayOfMonth,
203
+ className: e(O, A.dayOfMonth ? "border-status-error-border" : "border-border-seam"),
204
+ children: Array.from({ length: 28 }, (e, t) => t + 1).map((e) => /* @__PURE__ */ w("option", {
204
205
  value: e,
205
206
  children: f(e)
206
207
  }, e))
207
208
  }),
208
- j.dayOfMonth && /* @__PURE__ */ S("p", {
209
+ A.dayOfMonth && /* @__PURE__ */ w("p", {
209
210
  className: "mt-1 text-xs text-status-error-text",
210
- children: j.dayOfMonth
211
+ children: A.dayOfMonth
211
212
  })
212
213
  ] }),
213
- /* @__PURE__ */ C("div", { children: [
214
- /* @__PURE__ */ S("label", {
214
+ /* @__PURE__ */ T("div", { children: [
215
+ /* @__PURE__ */ w("label", {
215
216
  htmlFor: "hm-schedule-hour",
216
217
  className: "mb-1 block text-sm font-medium text-text-primary",
217
218
  children: "Time"
218
219
  }),
219
- /* @__PURE__ */ S(w, {
220
+ /* @__PURE__ */ w(E, {
220
221
  id: "hm-schedule-hour",
221
- value: D.hour,
222
- onChange: (e) => O({
223
- ...D,
222
+ value: S.hour,
223
+ onChange: (e) => k({
224
+ ...S,
224
225
  hour: Number(e.target.value)
225
226
  }),
226
- "aria-invalid": !!j.hour,
227
- className: e(E, j.hour ? "border-status-error-border" : "border-border-seam"),
228
- children: Array.from({ length: 24 }, (e, t) => /* @__PURE__ */ S("option", {
227
+ "aria-invalid": !!A.hour,
228
+ className: e(O, A.hour ? "border-status-error-border" : "border-border-seam"),
229
+ children: Array.from({ length: 24 }, (e, t) => /* @__PURE__ */ w("option", {
229
230
  value: t,
230
231
  children: u(t)
231
232
  }, t))
232
233
  }),
233
- j.hour && /* @__PURE__ */ S("p", {
234
+ A.hour && /* @__PURE__ */ w("p", {
234
235
  className: "mt-1 text-xs text-status-error-text",
235
- children: j.hour
236
+ children: A.hour
236
237
  })
237
238
  ] }),
238
- /* @__PURE__ */ C("div", { children: [
239
- /* @__PURE__ */ S("label", {
239
+ /* @__PURE__ */ T("div", { children: [
240
+ /* @__PURE__ */ w("label", {
240
241
  htmlFor: "hm-schedule-timezone",
241
242
  className: "mb-1 block text-sm font-medium text-text-primary",
242
243
  children: "Timezone"
243
244
  }),
244
- /* @__PURE__ */ S(w, {
245
+ /* @__PURE__ */ w(E, {
245
246
  id: "hm-schedule-timezone",
246
- value: D.timezone,
247
- onChange: (e) => O({
248
- ...D,
247
+ value: S.timezone,
248
+ onChange: (e) => k({
249
+ ...S,
249
250
  timezone: e.target.value
250
251
  }),
251
- "aria-invalid": !!j.timezone,
252
- className: e(E, j.timezone ? "border-status-error-border" : "border-border-seam"),
253
- children: z.map((e) => /* @__PURE__ */ S("option", {
252
+ "aria-invalid": !!A.timezone,
253
+ className: e(O, A.timezone ? "border-status-error-border" : "border-border-seam"),
254
+ children: B.map((e) => /* @__PURE__ */ w("option", {
254
255
  value: e,
255
256
  children: e
256
257
  }, e))
257
258
  }),
258
- j.timezone && /* @__PURE__ */ S("p", {
259
+ A.timezone && /* @__PURE__ */ w("p", {
259
260
  className: "mt-1 text-xs text-status-error-text",
260
- children: j.timezone
261
+ children: A.timezone
261
262
  })
262
263
  ] })
263
264
  ]
264
265
  }),
265
- /* @__PURE__ */ C("fieldset", { children: [
266
- /* @__PURE__ */ S("legend", {
266
+ /* @__PURE__ */ T("fieldset", { children: [
267
+ /* @__PURE__ */ w("legend", {
267
268
  className: "mb-1 text-sm font-medium text-text-primary",
268
269
  children: "Recipients"
269
270
  }),
270
- /* @__PURE__ */ S("p", {
271
+ /* @__PURE__ */ w("p", {
271
272
  className: "mb-2 text-xs text-text-secondary",
272
273
  children: "Workspace members only. Each recipient gets the email at the address on their account."
273
274
  }),
274
- /* @__PURE__ */ C("div", {
275
- className: e("max-h-56 space-y-1 overflow-y-auto rounded-lg border p-2", j.recipients ? "border-status-error-border" : "border-border-seam"),
275
+ /* @__PURE__ */ T("div", {
276
+ className: e("max-h-56 space-y-1 overflow-y-auto rounded-lg border p-2", A.recipients ? "border-status-error-border" : "border-border-seam"),
276
277
  children: [
277
- R.loading && /* @__PURE__ */ S("p", {
278
+ z.loading && /* @__PURE__ */ w("p", {
278
279
  className: "px-2 py-1.5 text-sm text-text-secondary",
279
280
  children: "Loading members…"
280
281
  }),
281
- R.error && /* @__PURE__ */ C("p", {
282
+ z.error && /* @__PURE__ */ T("p", {
282
283
  className: "px-2 py-1.5 text-sm text-status-error-text",
283
- children: ["Members could not be loaded: ", R.error]
284
+ children: ["Members could not be loaded: ", z.error]
284
285
  }),
285
- R.members.map((t) => {
286
- let n = D.recipientUserIds.includes(t.userId), r = !t.email;
287
- return /* @__PURE__ */ C("label", {
286
+ z.members.map((t) => {
287
+ let n = S.recipientUserIds.includes(t.userId), r = !t.email;
288
+ return /* @__PURE__ */ T("label", {
288
289
  className: e("flex items-center gap-3 rounded-md px-2 py-1.5", r ? "cursor-not-allowed opacity-60" : "cursor-pointer hover:bg-bg-sunken/40"),
289
- children: [/* @__PURE__ */ S("input", {
290
+ children: [/* @__PURE__ */ w("input", {
290
291
  type: "checkbox",
291
292
  checked: n,
292
293
  disabled: r && !n,
293
- onChange: () => O({
294
- ...D,
295
- recipientUserIds: m(D.recipientUserIds, t.userId)
294
+ onChange: () => k({
295
+ ...S,
296
+ recipientUserIds: m(S.recipientUserIds, t.userId)
296
297
  }),
297
298
  className: "h-4 w-4"
298
- }), /* @__PURE__ */ C("span", {
299
+ }), /* @__PURE__ */ T("span", {
299
300
  className: "min-w-0",
300
- children: [/* @__PURE__ */ S("span", {
301
+ children: [/* @__PURE__ */ w("span", {
301
302
  className: "block truncate text-sm text-text-primary",
302
303
  children: t.name
303
- }), /* @__PURE__ */ S("span", {
304
+ }), /* @__PURE__ */ w("span", {
304
305
  className: "block truncate text-xs text-text-secondary",
305
306
  children: t.email ?? "No email address"
306
307
  })]
307
308
  })]
308
309
  }, t.userId);
309
310
  }),
310
- U.map((e) => /* @__PURE__ */ C("label", {
311
+ W.map((e) => /* @__PURE__ */ T("label", {
311
312
  className: "flex cursor-pointer items-center gap-3 rounded-md px-2 py-1.5 hover:bg-bg-sunken/40",
312
- children: [/* @__PURE__ */ S("input", {
313
+ children: [/* @__PURE__ */ w("input", {
313
314
  type: "checkbox",
314
315
  checked: !0,
315
- onChange: () => O({
316
- ...D,
317
- recipientUserIds: m(D.recipientUserIds, e)
316
+ onChange: () => k({
317
+ ...S,
318
+ recipientUserIds: m(S.recipientUserIds, e)
318
319
  }),
319
320
  className: "h-4 w-4"
320
- }), /* @__PURE__ */ C("span", {
321
+ }), /* @__PURE__ */ T("span", {
321
322
  className: "text-sm text-text-secondary",
322
323
  children: [
323
324
  "Former or unknown member (",
@@ -326,47 +327,51 @@ var A = {
326
327
  ]
327
328
  })]
328
329
  }, e)),
329
- !R.loading && !R.error && R.members.length === 0 && U.length === 0 && /* @__PURE__ */ S("p", {
330
+ !z.loading && !z.error && z.members.length === 0 && W.length === 0 && /* @__PURE__ */ w("p", {
330
331
  className: "px-2 py-1.5 text-sm text-text-secondary",
331
332
  children: "No workspace members found."
332
333
  })
333
334
  ]
334
335
  }),
335
- j.recipients && /* @__PURE__ */ S("p", {
336
+ A.recipients && /* @__PURE__ */ w("p", {
336
337
  className: "mt-1 text-xs text-status-error-text",
337
- children: j.recipients
338
+ children: A.recipients
338
339
  })
339
340
  ] }),
340
- /* @__PURE__ */ C("label", {
341
+ /* @__PURE__ */ T("label", {
341
342
  className: "flex cursor-pointer items-center gap-3 text-sm text-text-primary",
342
- children: [/* @__PURE__ */ S("input", {
343
+ children: [/* @__PURE__ */ w("input", {
343
344
  type: "checkbox",
344
- checked: !D.enabled,
345
- onChange: () => O({
346
- ...D,
347
- enabled: !D.enabled
345
+ checked: !S.enabled,
346
+ onChange: () => k({
347
+ ...S,
348
+ enabled: !S.enabled
348
349
  }),
349
350
  className: "h-4 w-4"
350
351
  }), "Pause deliveries (keep the schedule but send nothing)"]
351
352
  }),
352
- b && /* @__PURE__ */ C("div", { children: [
353
- /* @__PURE__ */ S("h3", {
353
+ y && /* @__PURE__ */ T("div", { children: [
354
+ /* @__PURE__ */ w("h3", {
354
355
  className: "mb-2 text-sm font-medium text-text-primary",
355
356
  children: "Recent deliveries"
356
357
  }),
357
- B.error && /* @__PURE__ */ C("p", {
358
+ V.error && /* @__PURE__ */ T("p", {
358
359
  className: "text-xs text-status-error-text",
359
- children: ["Deliveries could not be loaded: ", B.error.message]
360
+ children: [
361
+ "Deliveries could not be loaded:",
362
+ " ",
363
+ g(V.error)
364
+ ]
360
365
  }),
361
- !B.error && V.length === 0 && /* @__PURE__ */ S("p", {
366
+ !V.error && H.length === 0 && /* @__PURE__ */ w("p", {
362
367
  className: "text-xs text-text-secondary",
363
- children: B.loading ? "Loading…" : "Nothing has been sent yet."
368
+ children: V.loading ? "Loading…" : "Nothing has been sent yet."
364
369
  }),
365
- V.length > 0 && /* @__PURE__ */ S("ul", {
370
+ H.length > 0 && /* @__PURE__ */ w("ul", {
366
371
  className: "divide-y divide-border-seam rounded-lg border border-border-seam text-sm",
367
- children: V.map((e) => /* @__PURE__ */ C("li", {
372
+ children: H.map((e) => /* @__PURE__ */ T("li", {
368
373
  className: "flex flex-wrap items-center justify-between gap-2 px-3 py-2",
369
- children: [/* @__PURE__ */ C("span", {
374
+ children: [/* @__PURE__ */ T("span", {
370
375
  className: "text-text-secondary",
371
376
  children: [
372
377
  d(e.startedAt),
@@ -374,8 +379,8 @@ var A = {
374
379
  " ",
375
380
  e.trigger === "MANUAL" ? "Send now" : "Scheduled"
376
381
  ]
377
- }), /* @__PURE__ */ C("span", {
378
- className: A[c(e.status)],
382
+ }), /* @__PURE__ */ T("span", {
383
+ className: M[c(e.status)],
379
384
  title: e.error ?? void 0,
380
385
  children: [
381
386
  s(e.status),
@@ -388,15 +393,15 @@ var A = {
388
393
  }, e.id))
389
394
  })
390
395
  ] }),
391
- M && /* @__PURE__ */ S("p", {
396
+ N && /* @__PURE__ */ w("p", {
392
397
  role: "alert",
393
398
  className: "rounded-lg border border-status-error-border px-4 py-3 text-sm text-status-error-text",
394
- children: M
399
+ children: N
395
400
  })
396
401
  ]
397
402
  })
398
403
  });
399
404
  };
400
- export { j as ReportScheduleDialog };
405
+ export { N as ReportScheduleDialog };
401
406
 
402
407
  //# sourceMappingURL=ReportScheduleDialog.js.map