@burdenoff/microfe-devportal 2026.717.1 → 2026.720.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 (42) hide show
  1. package/dist/devportal/components/PermissionGuard.d.ts +14 -1
  2. package/dist/devportal/components/PermissionGuard.d.ts.map +1 -1
  3. package/dist/devportal/components/PermissionGuard.js +16 -13
  4. package/dist/devportal/components/PermissionGuard.js.map +1 -1
  5. package/dist/devportal/pages/AdminReviewPage.js +9 -9
  6. package/dist/devportal/pages/ApiKeysPage.js +180 -181
  7. package/dist/devportal/pages/ApiKeysPage.js.map +1 -1
  8. package/dist/devportal/pages/ApplicationDetailPage.js +3 -3
  9. package/dist/devportal/pages/ApplicationVersionsPage.js +4 -4
  10. package/dist/devportal/pages/ApplicationVersionsPage.js.map +1 -1
  11. package/dist/devportal/pages/ApplicationsPage.js +4 -4
  12. package/dist/devportal/pages/ApplicationsPage.js.map +1 -1
  13. package/dist/devportal/pages/CreateApiKeyPage.js +1 -1
  14. package/dist/devportal/pages/CreateOAuthClientPage.js +1 -1
  15. package/dist/devportal/pages/CreateOrganizationPage.js +1 -1
  16. package/dist/devportal/pages/CreateWebhookPage.js +25 -25
  17. package/dist/devportal/pages/DashboardPage.d.ts.map +1 -1
  18. package/dist/devportal/pages/DashboardPage.js +110 -111
  19. package/dist/devportal/pages/DashboardPage.js.map +1 -1
  20. package/dist/devportal/pages/DelegationsPage.js +1 -1
  21. package/dist/devportal/pages/EditApplicationPage.js +4 -4
  22. package/dist/devportal/pages/ListingPreviewPage.d.ts.map +1 -1
  23. package/dist/devportal/pages/ListingPreviewPage.js +160 -161
  24. package/dist/devportal/pages/ListingPreviewPage.js.map +1 -1
  25. package/dist/devportal/pages/OAuthClientDetailPage.d.ts.map +1 -1
  26. package/dist/devportal/pages/OAuthClientDetailPage.js +166 -167
  27. package/dist/devportal/pages/OAuthClientDetailPage.js.map +1 -1
  28. package/dist/devportal/pages/OAuthClientsPage.d.ts.map +1 -1
  29. package/dist/devportal/pages/OAuthClientsPage.js +121 -122
  30. package/dist/devportal/pages/OAuthClientsPage.js.map +1 -1
  31. package/dist/devportal/pages/OrganizationDetailPage.js +3 -3
  32. package/dist/devportal/pages/OrganizationMembersPage.js +4 -4
  33. package/dist/devportal/pages/OrganizationsPage.js +1 -1
  34. package/dist/devportal/pages/PublishPage.js +246 -246
  35. package/dist/devportal/pages/PublishPage.js.map +1 -1
  36. package/dist/devportal/pages/PublisherProfilePage.js +4 -4
  37. package/dist/devportal/pages/PublisherProfilePage.js.map +1 -1
  38. package/dist/devportal/pages/StoreSubmissionPage.js +3 -3
  39. package/dist/devportal/pages/WebhookDetailPage.js +3 -3
  40. package/dist/devportal/pages/WebhooksPage.js +129 -129
  41. package/dist/devportal/pages/WebhooksPage.js.map +1 -1
  42. package/package.json +1 -1
@@ -6,20 +6,20 @@ import { getErrorMessage as o } from "../hooks/useGraphQL.js";
6
6
  import { PageLayout as s } from "../components/PageLayout.js";
7
7
  import { StatusBadge as c } from "../components/StatusBadge.js";
8
8
  import { AppListItem as l } from "../components/AppCard.js";
9
- import { DataTable as ee } from "../components/DataTable.js";
10
- import { PermissionGuard as u } from "../components/PermissionGuard.js";
9
+ import { DataTable as u } from "../components/DataTable.js";
10
+ import { PermissionGuard as d } from "../components/PermissionGuard.js";
11
11
  import "../components/index.js";
12
- import { DEVPORTAL_PERMISSIONS as d } from "../constants/permissions.js";
13
- import { useDevportalPermission as f } from "../hooks/usePermission.js";
12
+ import { useDevportalPermission as ee } from "../hooks/usePermission.js";
14
13
  import "../hooks/index.js";
15
- import { useEffect as p, useState as m } from "react";
16
- import { useI18n as h } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
17
- import { AlertCircle as g, AlertTriangle as _, AppWindow as v, CheckCircle as y, Loader2 as b, PauseCircle as x, Plus as S, Search as C, Webhook as w, XCircle as T } from "lucide-react";
18
- import { useParams as E } from "react-router-dom";
19
- import { jsx as D, jsxs as O } from "react/jsx-runtime";
20
- import { EmphasisPanel as k, GlassCard as A } from "@burdenoff/fe-libs/ui";
14
+ import { DEVPORTAL_PERMISSIONS as te } from "../constants/permissions.js";
15
+ import { useEffect as f, useState as p } from "react";
16
+ import { useI18n as m } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
17
+ import { AlertCircle as h, AlertTriangle as g, AppWindow as _, CheckCircle as v, Loader2 as y, PauseCircle as b, Plus as x, Search as S, Webhook as C, XCircle as w } from "lucide-react";
18
+ import { useParams as T } from "react-router-dom";
19
+ import { jsx as E, jsxs as D } from "react/jsx-runtime";
20
+ import { EmphasisPanel as O, GlassCard as k } from "@burdenoff/fe-libs/ui";
21
21
  //#region src/devportal/pages/WebhooksPage.tsx
22
- function j(e) {
22
+ function A(e) {
23
23
  return {
24
24
  id: e.id,
25
25
  applicationId: e.applicationId,
@@ -43,49 +43,49 @@ function j(e) {
43
43
  updatedAt: e.updatedAt
44
44
  };
45
45
  }
46
- var M = () => {
47
- let { appId: M } = E(), { navigate: ne, basePath: re, activeOrgId: N } = e(), { t: ie } = h(), P = (e, t) => {
48
- let n = ie(e);
46
+ var j = () => {
47
+ let { appId: j } = T(), { navigate: re, basePath: ie, activeOrgId: M } = e(), { t: N } = m(), P = (e, t) => {
48
+ let n = N(e);
49
49
  return n === e ? t : n;
50
- }, F = f(d.WEBHOOK_CREATE), [I, L] = m(""), [R, z] = m(""), { data: B } = r({
51
- variables: { id: M ?? "" },
52
- skip: !M,
50
+ }, F = ee(te.WEBHOOK_CREATE), [I, L] = p(""), [R, z] = p(""), { data: B } = r({
51
+ variables: { id: j ?? "" },
52
+ skip: !j,
53
53
  fetchPolicy: "cache-first"
54
54
  });
55
- p(() => {
55
+ f(() => {
56
56
  let e = B?.application?.name;
57
- if (!M || !e) return;
57
+ if (!j || !e) return;
58
58
  let t = window.__breadcrumbRegistry;
59
- return t?.register(M, e), () => t?.unregister(M);
60
- }, [M, B?.application?.name]);
59
+ return t?.register(j, e), () => t?.unregister(j);
60
+ }, [j, B?.application?.name]);
61
61
  let { data: V, loading: H, error: U, refetch: W } = i({
62
62
  variables: { limit: 100 },
63
- skip: !!M,
63
+ skip: !!j,
64
64
  fetchPolicy: "cache-and-network"
65
65
  }), { data: G, loading: K, error: q, refetch: J } = a({
66
- variables: { applicationId: M || "" },
67
- skip: !M,
66
+ variables: { applicationId: j || "" },
67
+ skip: !j,
68
68
  fetchPolicy: "cache-and-network"
69
- }), Y = G?.webhooks?.map(j) ?? [], X = V?.applications?.edges?.map((e) => e.node) ?? [], ae = N ? X.filter((e) => e.developerOrganizationId === N) : X, Z = (e) => {
70
- ne?.(`${re}${e}`);
69
+ }), Y = G?.webhooks?.map(A) ?? [], X = V?.applications?.edges?.map((e) => e.node) ?? [], ae = M ? X.filter((e) => e.developerOrganizationId === M) : X, Z = (e) => {
70
+ re?.(`${ie}${e}`);
71
71
  }, Q = Y.filter((e) => {
72
72
  let t = !I || e.name.toLowerCase().includes(I.toLowerCase()) || e.url.toLowerCase().includes(I.toLowerCase()), n = !R || e.status === R;
73
73
  return t && n;
74
74
  }), oe = (e) => {
75
75
  switch (e) {
76
- case "ACTIVE": return /* @__PURE__ */ D(y, {
76
+ case "ACTIVE": return /* @__PURE__ */ E(v, {
77
77
  size: 16,
78
78
  className: "text-status-success-text"
79
79
  });
80
- case "PAUSED": return /* @__PURE__ */ D(x, {
80
+ case "PAUSED": return /* @__PURE__ */ E(b, {
81
81
  size: 16,
82
82
  className: "text-status-warning-text"
83
83
  });
84
- case "FAILED": return /* @__PURE__ */ D(T, {
84
+ case "FAILED": return /* @__PURE__ */ E(w, {
85
85
  size: 16,
86
86
  className: "text-status-error-text"
87
87
  });
88
- case "DISABLED": return /* @__PURE__ */ D(_, {
88
+ case "DISABLED": return /* @__PURE__ */ E(g, {
89
89
  size: 16,
90
90
  className: "text-text-tertiary"
91
91
  });
@@ -95,33 +95,33 @@ var M = () => {
95
95
  let t = e.successCount + e.failureCount;
96
96
  return t === 0 ? 100 : Math.round(e.successCount / t * 100);
97
97
  };
98
- if (!M) {
98
+ if (!j) {
99
99
  let e = ae.filter((e) => {
100
100
  if (!I) return !0;
101
101
  let t = I.toLowerCase();
102
102
  return e.name.toLowerCase().includes(t) || (e.slug ?? "").toLowerCase().includes(t);
103
103
  });
104
- return /* @__PURE__ */ D(u, {
105
- permission: d.WEBHOOK_READ,
106
- children: /* @__PURE__ */ D(s, {
104
+ return /* @__PURE__ */ E(d, {
105
+ authOnly: !0,
106
+ children: /* @__PURE__ */ E(s, {
107
107
  title: P("devportal.webhooks", "Webhooks"),
108
108
  description: P("devportal.manageWebhooksApps", "Manage webhooks for your applications"),
109
109
  purpose: P("devportal.webhooksPickerPurpose", "Webhooks push real-time events (installs, payments, app updates) to a URL you host, so your backend can react without polling. Pick an application to view, add, or test the webhook endpoints it delivers to."),
110
- children: /* @__PURE__ */ O("div", {
110
+ children: /* @__PURE__ */ D("div", {
111
111
  className: "space-y-4",
112
112
  children: [
113
- /* @__PURE__ */ D("p", {
113
+ /* @__PURE__ */ E("p", {
114
114
  className: "text-sm text-text-secondary",
115
115
  children: P("devportal.webhooksSelectAppHint", "Select an application below to view and manage its webhooks.")
116
116
  }),
117
- /* @__PURE__ */ D("div", {
117
+ /* @__PURE__ */ E("div", {
118
118
  className: "max-w-md",
119
- children: /* @__PURE__ */ O("div", {
119
+ children: /* @__PURE__ */ D("div", {
120
120
  className: "relative",
121
- children: [/* @__PURE__ */ D(C, {
121
+ children: [/* @__PURE__ */ E(S, {
122
122
  size: 16,
123
123
  className: "absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"
124
- }), /* @__PURE__ */ D("input", {
124
+ }), /* @__PURE__ */ E("input", {
125
125
  type: "text",
126
126
  placeholder: "Search applications...",
127
127
  value: I,
@@ -130,42 +130,42 @@ var M = () => {
130
130
  })]
131
131
  })
132
132
  }),
133
- H ? /* @__PURE__ */ D("div", {
133
+ H ? /* @__PURE__ */ E("div", {
134
134
  className: "flex items-center justify-center py-12 text-text-secondary",
135
- children: /* @__PURE__ */ D(b, { className: "h-8 w-8 animate-spin" })
136
- }) : U ? /* @__PURE__ */ O("div", {
135
+ children: /* @__PURE__ */ E(y, { className: "h-8 w-8 animate-spin" })
136
+ }) : U ? /* @__PURE__ */ D("div", {
137
137
  className: "rounded-lg border border-status-error-border/50 bg-status-error-bg/10 p-6 text-center",
138
138
  children: [
139
- /* @__PURE__ */ D(g, { className: "mx-auto h-8 w-8 text-status-error-text" }),
140
- /* @__PURE__ */ D("h3", {
139
+ /* @__PURE__ */ E(h, { className: "mx-auto h-8 w-8 text-status-error-text" }),
140
+ /* @__PURE__ */ E("h3", {
141
141
  className: "mt-2 font-medium text-status-error-text",
142
142
  children: "Failed to load applications"
143
143
  }),
144
- /* @__PURE__ */ D("p", {
144
+ /* @__PURE__ */ E("p", {
145
145
  className: "mt-1 text-sm text-text-secondary",
146
146
  children: o(U)
147
147
  }),
148
- /* @__PURE__ */ D("button", {
148
+ /* @__PURE__ */ E("button", {
149
149
  onClick: () => W(),
150
150
  className: "mt-4 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
151
151
  children: "Try Again"
152
152
  })
153
153
  ]
154
- }) : e.length > 0 ? /* @__PURE__ */ D("div", {
154
+ }) : e.length > 0 ? /* @__PURE__ */ E("div", {
155
155
  className: "space-y-2",
156
- children: e.map((e) => /* @__PURE__ */ D(l, {
156
+ children: e.map((e) => /* @__PURE__ */ E(l, {
157
157
  app: e,
158
158
  onClick: () => Z(`/apps/${e.id}/webhooks`)
159
159
  }, e.id))
160
- }) : /* @__PURE__ */ D(n, {
160
+ }) : /* @__PURE__ */ E(n, {
161
161
  illustration: I ? "empty-search" : "empty-data",
162
- icon: /* @__PURE__ */ D(v, { size: 32 }),
162
+ icon: /* @__PURE__ */ E(_, { size: 32 }),
163
163
  title: "No applications available",
164
164
  description: I ? "No applications matched your search." : "Create an application before configuring webhooks.",
165
- action: /* @__PURE__ */ O("button", {
165
+ action: /* @__PURE__ */ D("button", {
166
166
  onClick: () => Z("/apps/new"),
167
167
  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",
168
- children: [/* @__PURE__ */ D(S, { size: 16 }), "Create Application"]
168
+ children: [/* @__PURE__ */ E(x, { size: 16 }), "Create Application"]
169
169
  })
170
170
  })
171
171
  ]
@@ -173,37 +173,37 @@ var M = () => {
173
173
  })
174
174
  });
175
175
  }
176
- if (K && !G) return /* @__PURE__ */ D(s, {
176
+ if (K && !G) return /* @__PURE__ */ E(s, {
177
177
  title: P("devportal.webhooks", "Webhooks"),
178
178
  description: P("devportal.manageWebhooksApp", "Manage webhooks for this application"),
179
- backLink: `/apps/${M}`,
179
+ backLink: `/apps/${j}`,
180
180
  backLabel: P("devportal.backToApplication", "Back to Application"),
181
- children: /* @__PURE__ */ O("div", {
181
+ children: /* @__PURE__ */ D("div", {
182
182
  className: "flex items-center justify-center py-12",
183
- children: [/* @__PURE__ */ D(b, { className: "h-8 w-8 animate-spin text-text-secondary" }), /* @__PURE__ */ D("span", {
183
+ children: [/* @__PURE__ */ E(y, { className: "h-8 w-8 animate-spin text-text-secondary" }), /* @__PURE__ */ E("span", {
184
184
  className: "ml-2 text-text-secondary",
185
185
  children: P("devportal.loadingWebhooks", "Loading webhooks...")
186
186
  })]
187
187
  })
188
188
  });
189
- if (q) return /* @__PURE__ */ D(s, {
189
+ if (q) return /* @__PURE__ */ E(s, {
190
190
  title: P("devportal.webhooks", "Webhooks"),
191
191
  description: P("devportal.manageWebhooksApp", "Manage webhooks for this application"),
192
- backLink: `/apps/${M}`,
192
+ backLink: `/apps/${j}`,
193
193
  backLabel: P("devportal.backToApplication", "Back to Application"),
194
- children: /* @__PURE__ */ O("div", {
194
+ children: /* @__PURE__ */ D("div", {
195
195
  className: "rounded-lg border border-status-error-border/50 bg-status-error-bg/10 p-6 text-center",
196
196
  children: [
197
- /* @__PURE__ */ D(g, { className: "mx-auto h-8 w-8 text-status-error-text" }),
198
- /* @__PURE__ */ D("h3", {
197
+ /* @__PURE__ */ E(h, { className: "mx-auto h-8 w-8 text-status-error-text" }),
198
+ /* @__PURE__ */ E("h3", {
199
199
  className: "mt-2 font-medium text-status-error-text",
200
200
  children: P("devportal.failedToLoadWebhooks", "Failed to load webhooks")
201
201
  }),
202
- /* @__PURE__ */ D("p", {
202
+ /* @__PURE__ */ E("p", {
203
203
  className: "mt-1 text-sm text-text-secondary",
204
204
  children: o(q)
205
205
  }),
206
- /* @__PURE__ */ D("button", {
206
+ /* @__PURE__ */ E("button", {
207
207
  onClick: () => J(),
208
208
  className: "mt-4 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
209
209
  children: P("devportal.tryAgain", "Try Again")
@@ -215,15 +215,15 @@ var M = () => {
215
215
  {
216
216
  key: "name",
217
217
  header: "Webhook",
218
- render: (e) => /* @__PURE__ */ O("div", {
218
+ render: (e) => /* @__PURE__ */ D("div", {
219
219
  className: "flex items-center gap-3",
220
- children: [/* @__PURE__ */ D("div", {
220
+ children: [/* @__PURE__ */ E("div", {
221
221
  className: t("flex h-10 w-10 items-center justify-center rounded-lg", e.status === "ACTIVE" ? "bg-status-success-bg-subtle text-status-success-text" : e.status === "FAILED" ? "bg-status-error-bg-subtle text-status-error-text" : e.status === "PAUSED" ? "bg-status-warning-bg-subtle text-status-warning-text" : "bg-bg-sunken text-text-tertiary"),
222
- children: /* @__PURE__ */ D(w, { size: 20 })
223
- }), /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
222
+ children: /* @__PURE__ */ E(C, { size: 20 })
223
+ }), /* @__PURE__ */ D("div", { children: [/* @__PURE__ */ E("p", {
224
224
  className: "font-medium",
225
225
  children: e.name
226
- }), /* @__PURE__ */ D("p", {
226
+ }), /* @__PURE__ */ E("p", {
227
227
  className: "text-xs text-text-secondary truncate max-w-xs",
228
228
  children: e.url
229
229
  })] })]
@@ -232,12 +232,12 @@ var M = () => {
232
232
  {
233
233
  key: "events",
234
234
  header: "Events",
235
- render: (e) => /* @__PURE__ */ O("div", {
235
+ render: (e) => /* @__PURE__ */ D("div", {
236
236
  className: "flex flex-wrap gap-1",
237
- children: [e.events.slice(0, 2).map((e) => /* @__PURE__ */ D("span", {
237
+ children: [e.events.slice(0, 2).map((e) => /* @__PURE__ */ E("span", {
238
238
  className: "inline-flex rounded bg-bg-sunken px-1.5 py-0.5 text-xs",
239
239
  children: e.split(".")[0]
240
- }, e)), e.events.length > 2 && /* @__PURE__ */ O("span", {
240
+ }, e)), e.events.length > 2 && /* @__PURE__ */ D("span", {
241
241
  className: "text-xs text-text-secondary",
242
242
  children: [
243
243
  "+",
@@ -250,9 +250,9 @@ var M = () => {
250
250
  {
251
251
  key: "status",
252
252
  header: "Status",
253
- render: (e) => /* @__PURE__ */ O("div", {
253
+ render: (e) => /* @__PURE__ */ D("div", {
254
254
  className: "flex items-center gap-2",
255
- children: [oe(e.status), /* @__PURE__ */ D(c, {
255
+ children: [oe(e.status), /* @__PURE__ */ E(c, {
256
256
  status: e.status,
257
257
  type: "webhook"
258
258
  })]
@@ -263,17 +263,17 @@ var M = () => {
263
263
  header: "Success Rate",
264
264
  render: (e) => {
265
265
  let n = se(e);
266
- return /* @__PURE__ */ O("div", {
266
+ return /* @__PURE__ */ D("div", {
267
267
  className: "w-24",
268
- children: [/* @__PURE__ */ D("div", {
268
+ children: [/* @__PURE__ */ E("div", {
269
269
  className: "flex items-center justify-between text-xs mb-1",
270
- children: /* @__PURE__ */ O("span", {
270
+ children: /* @__PURE__ */ D("span", {
271
271
  className: t(n >= 95 ? "text-status-success-text" : n >= 80 ? "text-status-warning-text" : "text-status-error-text"),
272
272
  children: [n, "%"]
273
273
  })
274
- }), /* @__PURE__ */ D("div", {
274
+ }), /* @__PURE__ */ E("div", {
275
275
  className: "h-1.5 rounded-full bg-bg-sunken",
276
- children: /* @__PURE__ */ D("div", {
276
+ children: /* @__PURE__ */ E("div", {
277
277
  className: t("h-full rounded-full transition-all", n >= 95 ? "bg-status-success-bg-subtle" : n >= 80 ? "bg-status-warning-bg-subtle" : "bg-status-error-bg-subtle"),
278
278
  style: { width: `${n}%` }
279
279
  })
@@ -284,18 +284,18 @@ var M = () => {
284
284
  {
285
285
  key: "deliveries",
286
286
  header: "Deliveries",
287
- render: (e) => /* @__PURE__ */ O("div", {
287
+ render: (e) => /* @__PURE__ */ D("div", {
288
288
  className: "text-sm",
289
289
  children: [
290
- /* @__PURE__ */ D("span", {
290
+ /* @__PURE__ */ E("span", {
291
291
  className: "text-status-success-text",
292
292
  children: e.successCount.toLocaleString()
293
293
  }),
294
- /* @__PURE__ */ D("span", {
294
+ /* @__PURE__ */ E("span", {
295
295
  className: "text-text-secondary",
296
296
  children: " / "
297
297
  }),
298
- /* @__PURE__ */ D("span", {
298
+ /* @__PURE__ */ E("span", {
299
299
  className: "text-status-error-text",
300
300
  children: e.failureCount.toLocaleString()
301
301
  })
@@ -305,9 +305,9 @@ var M = () => {
305
305
  {
306
306
  key: "lastTriggered",
307
307
  header: "Last Triggered",
308
- render: (e) => /* @__PURE__ */ D("span", {
308
+ render: (e) => /* @__PURE__ */ E("span", {
309
309
  className: "text-sm text-text-secondary",
310
- children: e.lastTriggeredAt ? te(e.lastTriggeredAt) : "Never"
310
+ children: e.lastTriggeredAt ? ne(e.lastTriggeredAt) : "Never"
311
311
  })
312
312
  }
313
313
  ], $ = {
@@ -316,64 +316,64 @@ var M = () => {
316
316
  failed: Y.filter((e) => e.status === "FAILED").length,
317
317
  paused: Y.filter((e) => e.status === "PAUSED").length
318
318
  };
319
- return /* @__PURE__ */ D(u, {
320
- permission: d.WEBHOOK_READ,
321
- children: /* @__PURE__ */ O(s, {
319
+ return /* @__PURE__ */ E(d, {
320
+ authOnly: !0,
321
+ children: /* @__PURE__ */ D(s, {
322
322
  title: P("devportal.webhooks", "Webhooks"),
323
323
  description: P("devportal.manageWebhooksApp", "Manage webhooks for this application"),
324
324
  purpose: P("devportal.webhooksAppPurpose", "These webhooks deliver this application's events to your endpoints. Add a URL, choose which events to subscribe to, and send a test delivery to confirm your server receives and verifies the signed payload."),
325
- backLink: `/apps/${M}`,
325
+ backLink: `/apps/${j}`,
326
326
  backLabel: P("devportal.backToApplication", "Back to Application"),
327
- actions: /* @__PURE__ */ O("button", {
328
- onClick: () => Z(`/apps/${M}/webhooks/new`),
327
+ actions: /* @__PURE__ */ D("button", {
328
+ onClick: () => Z(`/apps/${j}/webhooks/new`),
329
329
  disabled: !F.allowed,
330
330
  "aria-disabled": !F.allowed,
331
331
  title: F.allowed ? void 0 : P("devportal.common.noPermission", "You do not have permission to perform this action"),
332
332
  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 transition-colors disabled:opacity-50 disabled:cursor-not-allowed focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-primary",
333
- children: [/* @__PURE__ */ D(S, {
333
+ children: [/* @__PURE__ */ E(x, {
334
334
  size: 16,
335
335
  "aria-hidden": "true"
336
336
  }), P("devportal.createWebhook", "Create Webhook")]
337
337
  }),
338
338
  children: [
339
- /* @__PURE__ */ D("div", {
339
+ /* @__PURE__ */ E("div", {
340
340
  className: "flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-between",
341
- children: /* @__PURE__ */ O("div", {
341
+ children: /* @__PURE__ */ D("div", {
342
342
  className: "flex flex-1 items-center gap-4",
343
- children: [/* @__PURE__ */ O("div", {
343
+ children: [/* @__PURE__ */ D("div", {
344
344
  className: "relative flex-1 max-w-md",
345
- children: [/* @__PURE__ */ D(C, {
345
+ children: [/* @__PURE__ */ E(S, {
346
346
  size: 16,
347
347
  className: "absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"
348
- }), /* @__PURE__ */ D("input", {
348
+ }), /* @__PURE__ */ E("input", {
349
349
  type: "text",
350
350
  placeholder: "Search by name or URL...",
351
351
  value: I,
352
352
  onChange: (e) => L(e.target.value),
353
353
  className: "w-full rounded-md border bg-bg-surface pl-9 pr-4 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-primary"
354
354
  })]
355
- }), /* @__PURE__ */ O("select", {
355
+ }), /* @__PURE__ */ D("select", {
356
356
  value: R,
357
357
  onChange: (e) => z(e.target.value),
358
358
  className: "rounded-md border bg-bg-surface px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-primary",
359
359
  children: [
360
- /* @__PURE__ */ D("option", {
360
+ /* @__PURE__ */ E("option", {
361
361
  value: "",
362
362
  children: "All Status"
363
363
  }),
364
- /* @__PURE__ */ D("option", {
364
+ /* @__PURE__ */ E("option", {
365
365
  value: "ACTIVE",
366
366
  children: "Active"
367
367
  }),
368
- /* @__PURE__ */ D("option", {
368
+ /* @__PURE__ */ E("option", {
369
369
  value: "PAUSED",
370
370
  children: "Paused"
371
371
  }),
372
- /* @__PURE__ */ D("option", {
372
+ /* @__PURE__ */ E("option", {
373
373
  value: "FAILED",
374
374
  children: "Failed"
375
375
  }),
376
- /* @__PURE__ */ D("option", {
376
+ /* @__PURE__ */ E("option", {
377
377
  value: "DISABLED",
378
378
  children: "Disabled"
379
379
  })
@@ -381,68 +381,68 @@ var M = () => {
381
381
  })]
382
382
  })
383
383
  }),
384
- /* @__PURE__ */ D(k, { children: /* @__PURE__ */ O("div", {
384
+ /* @__PURE__ */ E(O, { children: /* @__PURE__ */ D("div", {
385
385
  className: "grid grid-cols-2 gap-4 sm:grid-cols-4",
386
386
  children: [
387
- /* @__PURE__ */ O(A, {
387
+ /* @__PURE__ */ D(k, {
388
388
  treatment: "metric",
389
389
  className: "p-4",
390
- children: [/* @__PURE__ */ O("div", {
390
+ children: [/* @__PURE__ */ D("div", {
391
391
  className: "flex items-center gap-2 text-text-secondary",
392
- children: [/* @__PURE__ */ D(w, { size: 16 }), /* @__PURE__ */ D("span", {
392
+ children: [/* @__PURE__ */ E(C, { size: 16 }), /* @__PURE__ */ E("span", {
393
393
  className: "text-sm",
394
394
  children: "Total Webhooks"
395
395
  })]
396
- }), /* @__PURE__ */ D("p", {
396
+ }), /* @__PURE__ */ E("p", {
397
397
  className: "mt-1 text-2xl font-semibold tabular-nums",
398
398
  children: $.total
399
399
  })]
400
400
  }),
401
- /* @__PURE__ */ O(A, {
401
+ /* @__PURE__ */ D(k, {
402
402
  treatment: "metric",
403
403
  className: "p-4",
404
- children: [/* @__PURE__ */ O("div", {
404
+ children: [/* @__PURE__ */ D("div", {
405
405
  className: "flex items-center gap-2 text-status-success-text",
406
- children: [/* @__PURE__ */ D(y, { size: 16 }), /* @__PURE__ */ D("span", {
406
+ children: [/* @__PURE__ */ E(v, { size: 16 }), /* @__PURE__ */ E("span", {
407
407
  className: "text-sm",
408
408
  children: "Active"
409
409
  })]
410
- }), /* @__PURE__ */ D("p", {
410
+ }), /* @__PURE__ */ E("p", {
411
411
  className: "mt-1 text-2xl font-semibold tabular-nums",
412
412
  children: $.active
413
413
  })]
414
414
  }),
415
- /* @__PURE__ */ O(A, {
415
+ /* @__PURE__ */ D(k, {
416
416
  treatment: "metric",
417
417
  className: "p-4",
418
- children: [/* @__PURE__ */ O("div", {
418
+ children: [/* @__PURE__ */ D("div", {
419
419
  className: "flex items-center gap-2 text-status-warning-text",
420
- children: [/* @__PURE__ */ D(x, { size: 16 }), /* @__PURE__ */ D("span", {
420
+ children: [/* @__PURE__ */ E(b, { size: 16 }), /* @__PURE__ */ E("span", {
421
421
  className: "text-sm",
422
422
  children: "Paused"
423
423
  })]
424
- }), /* @__PURE__ */ D("p", {
424
+ }), /* @__PURE__ */ E("p", {
425
425
  className: "mt-1 text-2xl font-semibold tabular-nums",
426
426
  children: $.paused
427
427
  })]
428
428
  }),
429
- /* @__PURE__ */ O(A, {
429
+ /* @__PURE__ */ D(k, {
430
430
  treatment: "metric",
431
431
  className: "p-4",
432
- children: [/* @__PURE__ */ O("div", {
432
+ children: [/* @__PURE__ */ D("div", {
433
433
  className: "flex items-center gap-2 text-status-error-text",
434
- children: [/* @__PURE__ */ D(T, { size: 16 }), /* @__PURE__ */ D("span", {
434
+ children: [/* @__PURE__ */ E(w, { size: 16 }), /* @__PURE__ */ E("span", {
435
435
  className: "text-sm",
436
436
  children: "Failed"
437
437
  })]
438
- }), /* @__PURE__ */ D("p", {
438
+ }), /* @__PURE__ */ E("p", {
439
439
  className: "mt-1 text-2xl font-semibold tabular-nums",
440
440
  children: $.failed
441
441
  })]
442
442
  })
443
443
  ]
444
444
  }) }),
445
- /* @__PURE__ */ O("p", {
445
+ /* @__PURE__ */ D("p", {
446
446
  className: "text-sm text-text-secondary",
447
447
  children: [
448
448
  Q.length,
@@ -451,30 +451,30 @@ var M = () => {
451
451
  " found"
452
452
  ]
453
453
  }),
454
- Q.length > 0 ? /* @__PURE__ */ D(ee, {
454
+ Q.length > 0 ? /* @__PURE__ */ E(u, {
455
455
  data: Q,
456
456
  columns: ce,
457
457
  keyField: "id",
458
- onRowClick: (e) => Z(`/apps/${M}/webhooks/${e.id}`)
459
- }) : /* @__PURE__ */ D(n, {
458
+ onRowClick: (e) => Z(`/apps/${j}/webhooks/${e.id}`)
459
+ }) : /* @__PURE__ */ E(n, {
460
460
  illustration: "empty-notifications",
461
461
  title: P("devportal.noWebhooksFound", "No webhooks found"),
462
462
  description: I || R ? P("devportal.tryAdjustingFilters", "Try adjusting your filters") : P("devportal.createFirstWebhook", "Create your first webhook to receive real-time event notifications"),
463
- action: !I && !R ? /* @__PURE__ */ O("button", {
464
- onClick: () => Z(`/apps/${M}/webhooks/new`),
463
+ action: !I && !R ? /* @__PURE__ */ D("button", {
464
+ onClick: () => Z(`/apps/${j}/webhooks/new`),
465
465
  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",
466
- children: [/* @__PURE__ */ D(S, { size: 16 }), P("devportal.createWebhook", "Create Webhook")]
466
+ children: [/* @__PURE__ */ E(x, { size: 16 }), P("devportal.createWebhook", "Create Webhook")]
467
467
  }) : void 0
468
468
  })
469
469
  ]
470
470
  })
471
471
  });
472
472
  };
473
- function te(e) {
473
+ function ne(e) {
474
474
  let t = new Date(e), n = (/* @__PURE__ */ new Date()).getTime() - t.getTime(), r = Math.floor(n / 6e4), i = Math.floor(r / 60), a = Math.floor(i / 24);
475
475
  return r < 1 ? "Just now" : r < 60 ? `${r}m ago` : i < 24 ? `${i}h ago` : a < 7 ? `${a}d ago` : t.toLocaleDateString();
476
476
  }
477
477
  //#endregion
478
- export { M as WebhooksPage };
478
+ export { j as WebhooksPage };
479
479
 
480
480
  //# sourceMappingURL=WebhooksPage.js.map