@burdenoff/microfe-devportal 2026.1112.2 → 2026.1113.2
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/devportal/DevportalRoot.js +65 -119
- package/dist/devportal/DevportalRoot.js.map +1 -1
- package/dist/devportal/components/AppCard.js +72 -69
- package/dist/devportal/components/AppCard.js.map +1 -1
- package/dist/devportal/components/DeveloperSettingsHub.d.ts +6 -0
- package/dist/devportal/components/DeveloperSettingsHub.js +59 -0
- package/dist/devportal/components/DeveloperSettingsHub.js.map +1 -0
- package/dist/devportal/components/ImageUploadField.js +82 -80
- package/dist/devportal/components/ImageUploadField.js.map +1 -1
- package/dist/devportal/components/SectionNav.d.ts +1 -1
- package/dist/devportal/components/SectionNav.js +60 -36
- package/dist/devportal/components/SectionNav.js.map +1 -1
- package/dist/devportal/components/StoreImage.d.ts +15 -0
- package/dist/devportal/components/StoreImage.js +30 -0
- package/dist/devportal/components/StoreImage.js.map +1 -0
- package/dist/devportal/components/index.d.ts +1 -0
- package/dist/devportal/components/index.js +17 -16
- package/dist/devportal/hooks/usePackageUpload.d.ts +46 -4
- package/dist/devportal/hooks/usePackageUpload.js +90 -36
- package/dist/devportal/hooks/usePackageUpload.js.map +1 -1
- package/dist/devportal/pages/AdminReviewPage.js +205 -202
- package/dist/devportal/pages/AdminReviewPage.js.map +1 -1
- package/dist/devportal/pages/AnalyticsDashboardPage.js +186 -179
- package/dist/devportal/pages/AnalyticsDashboardPage.js.map +1 -1
- package/dist/devportal/pages/ApiKeysPage.js +113 -111
- package/dist/devportal/pages/ApiKeysPage.js.map +1 -1
- package/dist/devportal/pages/AppLogsPage.js +80 -84
- package/dist/devportal/pages/AppLogsPage.js.map +1 -1
- package/dist/devportal/pages/ApplicationDetailPage.js +529 -504
- package/dist/devportal/pages/ApplicationDetailPage.js.map +1 -1
- package/dist/devportal/pages/ApplicationsPage.js +186 -183
- package/dist/devportal/pages/ApplicationsPage.js.map +1 -1
- package/dist/devportal/pages/CreateApiKeyPage.js +163 -166
- package/dist/devportal/pages/CreateApiKeyPage.js.map +1 -1
- package/dist/devportal/pages/CreateOAuthClientPage.js +134 -130
- package/dist/devportal/pages/CreateOAuthClientPage.js.map +1 -1
- package/dist/devportal/pages/CreatePhysicalItemPage.js +2 -2
- package/dist/devportal/pages/CreatePhysicalItemPage.js.map +1 -1
- package/dist/devportal/pages/DelegationsPage.js +11 -11
- package/dist/devportal/pages/DocumentationPage.js +100 -94
- package/dist/devportal/pages/DocumentationPage.js.map +1 -1
- package/dist/devportal/pages/EditApplicationPage.js +379 -377
- package/dist/devportal/pages/EditApplicationPage.js.map +1 -1
- package/dist/devportal/pages/EditPhysicalItemPage.js +312 -307
- package/dist/devportal/pages/EditPhysicalItemPage.js.map +1 -1
- package/dist/devportal/pages/InvitationDecisionPage.js +83 -79
- package/dist/devportal/pages/InvitationDecisionPage.js.map +1 -1
- package/dist/devportal/pages/ListingPreviewPage.js +175 -171
- package/dist/devportal/pages/ListingPreviewPage.js.map +1 -1
- package/dist/devportal/pages/OAuthClientDetailPage.js +76 -76
- package/dist/devportal/pages/OAuthClientDetailPage.js.map +1 -1
- package/dist/devportal/pages/OAuthClientsPage.js +126 -124
- package/dist/devportal/pages/OAuthClientsPage.js.map +1 -1
- package/dist/devportal/pages/OrganizationDetailPage.js +19 -19
- package/dist/devportal/pages/OrganizationMembersPage.js +223 -204
- package/dist/devportal/pages/OrganizationMembersPage.js.map +1 -1
- package/dist/devportal/pages/ResourcesPage.d.ts +6 -0
- package/dist/devportal/pages/ResourcesPage.js +171 -155
- package/dist/devportal/pages/ResourcesPage.js.map +1 -1
- package/dist/devportal/pages/SellerDashboardPage.js +117 -115
- package/dist/devportal/pages/SellerDashboardPage.js.map +1 -1
- package/dist/devportal/pages/SellerItemsPage.js +202 -199
- package/dist/devportal/pages/SellerItemsPage.js.map +1 -1
- package/dist/devportal/pages/SettingsPage.js +330 -315
- package/dist/devportal/pages/SettingsPage.js.map +1 -1
- package/dist/devportal/pages/SetupPage.js +5 -5
- package/dist/devportal/pages/StoreSubmissionPage.js +133 -131
- package/dist/devportal/pages/StoreSubmissionPage.js.map +1 -1
- package/dist/devportal/pages/WebhookDetailPage.js +6 -6
- package/dist/devportal/pages/WebhooksPage.js +39 -39
- package/dist/devportal/pages/WebhooksPage.js.map +1 -1
- package/dist/devportal/utils/appDetailTabs.d.ts +73 -0
- package/dist/devportal/utils/appDetailTabs.js +62 -0
- package/dist/devportal/utils/appDetailTabs.js.map +1 -0
- package/dist/devportal/utils/developerNav.d.ts +39 -0
- package/dist/devportal/utils/developerNav.js +304 -0
- package/dist/devportal/utils/developerNav.js.map +1 -0
- package/package.json +2 -2
|
@@ -1,62 +1,70 @@
|
|
|
1
1
|
import { Bar as e } from "../../node_modules/recharts/es6/cartesian/Bar.js";
|
|
2
2
|
import { BarChart as t } from "../../node_modules/recharts/es6/chart/BarChart.js";
|
|
3
3
|
import { CartesianGrid as n } from "../../node_modules/recharts/es6/cartesian/CartesianGrid.js";
|
|
4
|
-
import { useGetAnalyticsDashboardOptionsQuery as
|
|
5
|
-
import { getErrorMessage as
|
|
6
|
-
import { Line as
|
|
7
|
-
import { LineChart as
|
|
8
|
-
import { ResponsiveContainer as
|
|
9
|
-
import { Tooltip as
|
|
10
|
-
import { XAxis as
|
|
11
|
-
import { YAxis as
|
|
12
|
-
import { PageLayout as
|
|
13
|
-
import { DataTable as
|
|
14
|
-
import { EmptyState as
|
|
15
|
-
import { StatCard as
|
|
16
|
-
import { AppListItem as
|
|
17
|
-
import { useDevportal as
|
|
4
|
+
import { useGetAnalyticsDashboardOptionsQuery as ee, useGetApplicationAnalyticsDashboardQuery as te } from "../../generated/global-operations.js";
|
|
5
|
+
import { getErrorMessage as r } from "../hooks/useGraphQL.js";
|
|
6
|
+
import { Line as i } from "../../node_modules/recharts/es6/cartesian/Line.js";
|
|
7
|
+
import { LineChart as ne } from "../../node_modules/recharts/es6/chart/LineChart.js";
|
|
8
|
+
import { ResponsiveContainer as a } from "../../node_modules/recharts/es6/component/ResponsiveContainer.js";
|
|
9
|
+
import { Tooltip as o } from "../../node_modules/recharts/es6/component/Tooltip.js";
|
|
10
|
+
import { XAxis as s } from "../../node_modules/recharts/es6/cartesian/XAxis.js";
|
|
11
|
+
import { YAxis as c } from "../../node_modules/recharts/es6/cartesian/YAxis.js";
|
|
12
|
+
import { PageLayout as l, PageSection as u } from "../components/PageLayout.js";
|
|
13
|
+
import { DataTable as re } from "../components/DataTable.js";
|
|
14
|
+
import { EmptyState as d } from "../components/EmptyState.js";
|
|
15
|
+
import { StatCard as f, StatCardGrid as p } from "../components/StatCard.js";
|
|
16
|
+
import { AppListItem as m } from "../components/AppCard.js";
|
|
17
|
+
import { useDevportal as h, useIsFluidgridsVariant as ie } from "../providers/DevportalProvider.js";
|
|
18
18
|
import "../hooks/index.js";
|
|
19
|
-
import { useTr as
|
|
20
|
-
import { useEffect as
|
|
21
|
-
import { Activity as
|
|
22
|
-
import { useParams as
|
|
23
|
-
import { Fragment as
|
|
24
|
-
import { EmphasisPanel as
|
|
19
|
+
import { useTr as g } from "../utils/i18n.js";
|
|
20
|
+
import { useEffect as ae, useMemo as _, useState as v } from "react";
|
|
21
|
+
import { Activity as oe, AlertCircle as y, AlertTriangle as se, BarChart3 as b, Clock as x, Loader2 as S, Users as C } from "lucide-react";
|
|
22
|
+
import { useParams as w } from "react-router";
|
|
23
|
+
import { Fragment as T, jsx as E, jsxs as D } from "react/jsx-runtime";
|
|
24
|
+
import { EmphasisPanel as O, GlassCard as k, OptionalFields as A } from "@burdenoff/fe-libs/ui";
|
|
25
25
|
// src/devportal/pages/AnalyticsDashboardPage.tsx
|
|
26
26
|
var ce = {
|
|
27
27
|
"7d": 7,
|
|
28
28
|
"30d": 30,
|
|
29
29
|
"90d": 90
|
|
30
|
-
},
|
|
30
|
+
}, j = {
|
|
31
31
|
primary: "var(--color-chart-1)",
|
|
32
32
|
secondary: "var(--color-chart-2)",
|
|
33
33
|
tertiary: "var(--color-chart-4)",
|
|
34
34
|
negative: "var(--color-chart-negative)"
|
|
35
|
-
},
|
|
36
|
-
let
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
35
|
+
}, le = ({ fold: e, children: t }) => {
|
|
36
|
+
let n = g();
|
|
37
|
+
return e ? /* @__PURE__ */ E(A, {
|
|
38
|
+
storageKey: "devportal.analytics.details",
|
|
39
|
+
title: n("devportal.analytics.detailsTitle", "Trends and daily breakdown"),
|
|
40
|
+
description: n("devportal.analytics.detailsDescription", "Traffic and user charts, plus the day-by-day table."),
|
|
41
|
+
children: t
|
|
42
|
+
}) : /* @__PURE__ */ E(T, { children: t });
|
|
43
|
+
}, M = () => {
|
|
44
|
+
let A = ie(), { appId: M } = w(), { navigate: ue, basePath: de, activeOrgId: N } = h(), P = g(), [F, I] = v("30d"), [L, R] = v(M || ""), z = _(() => /* @__PURE__ */ new Date(), []), B = _(() => {
|
|
45
|
+
let e = new Date(z);
|
|
46
|
+
return e.setDate(e.getDate() - ce[F]), e.toISOString();
|
|
47
|
+
}, [z, F]), { data: V, loading: fe, error: H } = ee({
|
|
48
|
+
skip: !!M,
|
|
41
49
|
fetchPolicy: "cache-and-network"
|
|
42
|
-
}), { data: U, loading:
|
|
50
|
+
}), { data: U, loading: pe, error: W } = te({
|
|
43
51
|
variables: {
|
|
44
|
-
applicationId:
|
|
52
|
+
applicationId: L || M || "",
|
|
45
53
|
period: "daily",
|
|
46
|
-
startDate:
|
|
47
|
-
endDate:
|
|
54
|
+
startDate: B,
|
|
55
|
+
endDate: z.toISOString()
|
|
48
56
|
},
|
|
49
|
-
skip: !(
|
|
57
|
+
skip: !(L || M),
|
|
50
58
|
fetchPolicy: "cache-and-network"
|
|
51
|
-
}), G =
|
|
52
|
-
|
|
53
|
-
let e = q?.name, t =
|
|
59
|
+
}), G = V?.applications?.edges?.map((e) => e.node) ?? [], K = N ? G.filter((e) => e.developerOrganizationId === N) : G, q = U?.application;
|
|
60
|
+
ae(() => {
|
|
61
|
+
let e = q?.name, t = M || L;
|
|
54
62
|
if (!t || !e) return;
|
|
55
63
|
let n = window.__breadcrumbRegistry;
|
|
56
64
|
return n?.register(t, e), () => n?.unregister(t);
|
|
57
65
|
}, [
|
|
58
|
-
|
|
59
|
-
|
|
66
|
+
M,
|
|
67
|
+
L,
|
|
60
68
|
q?.name
|
|
61
69
|
]);
|
|
62
70
|
let J = [...U?.applicationAnalytics ?? []].sort((e, t) => new Date(e.date).getTime() - new Date(t.date).getTime()), Y = J[J.length - 1], X = J[J.length - 2], Z = J.map((e) => ({
|
|
@@ -70,175 +78,175 @@ var ce = {
|
|
|
70
78
|
newUsers: e.newUsers,
|
|
71
79
|
sessions: e.sessions,
|
|
72
80
|
avgResponseTime: e.avgResponseTime ?? 0
|
|
73
|
-
})), Q = Y && Y.apiCalls > 0 ? Y.errors / Y.apiCalls * 100 : 0,
|
|
74
|
-
|
|
81
|
+
})), Q = Y && Y.apiCalls > 0 ? Y.errors / Y.apiCalls * 100 : 0, me = X && X.apiCalls > 0 ? X.errors / X.apiCalls * 100 : 0, $ = Y?.avgResponseTime && X?.avgResponseTime ? X.avgResponseTime - Y.avgResponseTime : void 0, he = (e) => {
|
|
82
|
+
ue?.(`${de}${e}`);
|
|
75
83
|
};
|
|
76
|
-
return !
|
|
77
|
-
title:
|
|
78
|
-
description:
|
|
79
|
-
children: /* @__PURE__ */
|
|
84
|
+
return !M && fe && !V ? /* @__PURE__ */ E(l, {
|
|
85
|
+
title: P("devportal.analytics.title", "Analytics"),
|
|
86
|
+
description: P("devportal.analytics.description", "Explore live application usage and performance metrics"),
|
|
87
|
+
children: /* @__PURE__ */ E("div", {
|
|
80
88
|
className: "flex items-center justify-center py-16 text-text-secondary",
|
|
81
|
-
children: /* @__PURE__ */
|
|
89
|
+
children: /* @__PURE__ */ E(S, { className: "h-8 w-8 animate-spin" })
|
|
82
90
|
})
|
|
83
|
-
}) : !
|
|
84
|
-
title:
|
|
85
|
-
description:
|
|
86
|
-
children: /* @__PURE__ */
|
|
87
|
-
icon: /* @__PURE__ */
|
|
91
|
+
}) : !M && H ? /* @__PURE__ */ E(l, {
|
|
92
|
+
title: P("devportal.analytics.title", "Analytics"),
|
|
93
|
+
description: P("devportal.analytics.description", "Explore live application usage and performance metrics"),
|
|
94
|
+
children: /* @__PURE__ */ E(d, {
|
|
95
|
+
icon: /* @__PURE__ */ E(y, {
|
|
88
96
|
size: 32,
|
|
89
97
|
className: "text-status-error-text"
|
|
90
98
|
}),
|
|
91
|
-
title:
|
|
92
|
-
description:
|
|
99
|
+
title: P("devportal.analytics.errorLoadApps", "Unable to load applications"),
|
|
100
|
+
description: r(H)
|
|
93
101
|
})
|
|
94
|
-
}) : !
|
|
95
|
-
title:
|
|
96
|
-
description:
|
|
97
|
-
children: K.length > 0 ? /* @__PURE__ */
|
|
102
|
+
}) : !M && !L ? /* @__PURE__ */ E(l, {
|
|
103
|
+
title: P("devportal.analytics.title", "Analytics"),
|
|
104
|
+
description: P("devportal.analytics.selectAppDescription", "Select an application to review live usage metrics from the public gateway"),
|
|
105
|
+
children: K.length > 0 ? /* @__PURE__ */ E("div", {
|
|
98
106
|
className: "space-y-2",
|
|
99
|
-
children: K.map((e) => /* @__PURE__ */
|
|
107
|
+
children: K.map((e) => /* @__PURE__ */ E(m, {
|
|
100
108
|
app: e,
|
|
101
|
-
onClick: () =>
|
|
109
|
+
onClick: () => R(e.id)
|
|
102
110
|
}, e.id))
|
|
103
|
-
}) : /* @__PURE__ */
|
|
111
|
+
}) : /* @__PURE__ */ E(d, {
|
|
104
112
|
illustration: "empty-data",
|
|
105
|
-
icon: /* @__PURE__ */
|
|
106
|
-
title:
|
|
107
|
-
description:
|
|
113
|
+
icon: /* @__PURE__ */ E(b, { size: 32 }),
|
|
114
|
+
title: P("devportal.analytics.noAppsTitle", "No applications available"),
|
|
115
|
+
description: P("devportal.analytics.noAppsDescription", "Create an application before viewing analytics.")
|
|
108
116
|
})
|
|
109
|
-
}) : W ? /* @__PURE__ */
|
|
110
|
-
title:
|
|
111
|
-
description:
|
|
112
|
-
backLink:
|
|
113
|
-
backLabel:
|
|
114
|
-
children: /* @__PURE__ */
|
|
115
|
-
icon: /* @__PURE__ */
|
|
117
|
+
}) : W ? /* @__PURE__ */ E(l, {
|
|
118
|
+
title: P("devportal.analytics.title", "Analytics"),
|
|
119
|
+
description: P("devportal.analytics.description", "Explore live application usage and performance metrics"),
|
|
120
|
+
backLink: L ? `/apps/${L}` : void 0,
|
|
121
|
+
backLabel: P("devportal.analytics.backToApplication", "Back to Application"),
|
|
122
|
+
children: /* @__PURE__ */ E(d, {
|
|
123
|
+
icon: /* @__PURE__ */ E(y, {
|
|
116
124
|
size: 32,
|
|
117
125
|
className: "text-status-error-text"
|
|
118
126
|
}),
|
|
119
|
-
title:
|
|
120
|
-
description:
|
|
127
|
+
title: P("devportal.analytics.errorLoadAnalytics", "Unable to load analytics"),
|
|
128
|
+
description: r(W)
|
|
121
129
|
})
|
|
122
|
-
}) : /* @__PURE__ */
|
|
123
|
-
title:
|
|
124
|
-
description: q ? `${
|
|
125
|
-
purpose:
|
|
126
|
-
backLink:
|
|
127
|
-
backLabel:
|
|
128
|
-
actions: /* @__PURE__ */
|
|
130
|
+
}) : /* @__PURE__ */ E(l, {
|
|
131
|
+
title: M ? P("devportal.analytics.appTitle", "Application Analytics") : P("devportal.analytics.title", "Analytics"),
|
|
132
|
+
description: q ? `${P("devportal.analytics.liveUsageFor", "Live usage and performance for")} ${q.name}` : P("devportal.analytics.description", "Explore live application usage and performance metrics"),
|
|
133
|
+
purpose: P("devportal.analytics.purpose", "Analytics shows how your apps are actually used — API call volume, active installs, latency, and error rates over time — so you can spot regressions, plan capacity, and prove value to your users. Pick an app and a time range to drill in."),
|
|
134
|
+
backLink: M && q ? `/apps/${q.id}` : void 0,
|
|
135
|
+
backLabel: P("devportal.analytics.backToApplication", "Back to Application"),
|
|
136
|
+
actions: /* @__PURE__ */ D("div", {
|
|
129
137
|
className: "flex flex-wrap gap-2",
|
|
130
|
-
children: [!
|
|
131
|
-
value:
|
|
132
|
-
onChange: (e) =>
|
|
133
|
-
"aria-label":
|
|
138
|
+
children: [!M && K.length > 0 && /* @__PURE__ */ E("select", {
|
|
139
|
+
value: L,
|
|
140
|
+
onChange: (e) => R(e.target.value),
|
|
141
|
+
"aria-label": P("devportal.analytics.selectAppAria", "Select application"),
|
|
134
142
|
className: "rounded-md border bg-bg-surface px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-primary scheme-normal dark:scheme-dark [&_option]:bg-bg-surface [&_option]:text-text-primary",
|
|
135
|
-
children: K.map((e) => /* @__PURE__ */
|
|
143
|
+
children: K.map((e) => /* @__PURE__ */ E("option", {
|
|
136
144
|
value: e.id,
|
|
137
145
|
children: e.name
|
|
138
146
|
}, e.id))
|
|
139
|
-
}), /* @__PURE__ */
|
|
140
|
-
value:
|
|
141
|
-
onChange: (e) =>
|
|
142
|
-
"aria-label":
|
|
147
|
+
}), /* @__PURE__ */ D("select", {
|
|
148
|
+
value: F,
|
|
149
|
+
onChange: (e) => I(e.target.value),
|
|
150
|
+
"aria-label": P("devportal.analytics.selectRangeAria", "Select time range"),
|
|
143
151
|
className: "rounded-md border bg-bg-surface px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-primary scheme-normal dark:scheme-dark [&_option]:bg-bg-surface [&_option]:text-text-primary",
|
|
144
152
|
children: [
|
|
145
|
-
/* @__PURE__ */
|
|
153
|
+
/* @__PURE__ */ E("option", {
|
|
146
154
|
value: "7d",
|
|
147
|
-
children:
|
|
155
|
+
children: P("devportal.analytics.range.7d", "Last 7 days")
|
|
148
156
|
}),
|
|
149
|
-
/* @__PURE__ */
|
|
157
|
+
/* @__PURE__ */ E("option", {
|
|
150
158
|
value: "30d",
|
|
151
|
-
children:
|
|
159
|
+
children: P("devportal.analytics.range.30d", "Last 30 days")
|
|
152
160
|
}),
|
|
153
|
-
/* @__PURE__ */
|
|
161
|
+
/* @__PURE__ */ E("option", {
|
|
154
162
|
value: "90d",
|
|
155
|
-
children:
|
|
163
|
+
children: P("devportal.analytics.range.90d", "Last 90 days")
|
|
156
164
|
})
|
|
157
165
|
]
|
|
158
166
|
})]
|
|
159
167
|
}),
|
|
160
|
-
children:
|
|
168
|
+
children: pe && !J.length ? /* @__PURE__ */ E("div", {
|
|
161
169
|
className: "flex items-center justify-center py-16 text-text-secondary",
|
|
162
|
-
children: /* @__PURE__ */
|
|
163
|
-
}) : J.length > 0 ? /* @__PURE__ */
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
/* @__PURE__ */
|
|
170
|
+
children: /* @__PURE__ */ E(S, { className: "h-8 w-8 animate-spin" })
|
|
171
|
+
}) : J.length > 0 ? /* @__PURE__ */ D(T, { children: [/* @__PURE__ */ E(O, {
|
|
172
|
+
className: "mb-6",
|
|
173
|
+
children: /* @__PURE__ */ D(p, {
|
|
174
|
+
columns: 4,
|
|
175
|
+
children: [
|
|
176
|
+
/* @__PURE__ */ E(f, {
|
|
177
|
+
title: P("devportal.analytics.apiCalls", "API Calls"),
|
|
178
|
+
value: (Y?.apiCalls ?? 0).toLocaleString(),
|
|
179
|
+
icon: /* @__PURE__ */ E(oe, { size: 20 })
|
|
180
|
+
}),
|
|
181
|
+
/* @__PURE__ */ E(f, {
|
|
182
|
+
title: P("devportal.analytics.activeUsers", "Active Users"),
|
|
183
|
+
value: (Y?.activeUsers ?? 0).toLocaleString(),
|
|
184
|
+
icon: /* @__PURE__ */ E(C, { size: 20 })
|
|
185
|
+
}),
|
|
186
|
+
/* @__PURE__ */ E(f, {
|
|
187
|
+
title: P("devportal.analytics.errorRate", "Error Rate"),
|
|
188
|
+
value: `${Q.toFixed(2)}%`,
|
|
189
|
+
icon: /* @__PURE__ */ E(se, { size: 20 }),
|
|
190
|
+
trend: X ? {
|
|
191
|
+
value: me - Q,
|
|
192
|
+
label: P("devportal.analytics.vsPrevious", "vs previous period")
|
|
193
|
+
} : void 0
|
|
194
|
+
}),
|
|
195
|
+
/* @__PURE__ */ E(f, {
|
|
196
|
+
title: P("devportal.analytics.avgResponseTime", "Avg Response Time"),
|
|
197
|
+
value: Y?.avgResponseTime ? `${Y.avgResponseTime}ms` : P("devportal.common.na", "N/A"),
|
|
198
|
+
icon: /* @__PURE__ */ E(x, { size: 20 }),
|
|
199
|
+
trend: typeof $ == "number" ? {
|
|
200
|
+
value: $,
|
|
201
|
+
label: P("devportal.analytics.fasterThanPrevious", "faster than previous")
|
|
202
|
+
} : void 0
|
|
203
|
+
})
|
|
204
|
+
]
|
|
205
|
+
})
|
|
206
|
+
}), /* @__PURE__ */ D(le, {
|
|
207
|
+
fold: A,
|
|
208
|
+
children: [/* @__PURE__ */ D("div", {
|
|
201
209
|
className: "grid gap-6 xl:grid-cols-2",
|
|
202
|
-
children: [/* @__PURE__ */
|
|
203
|
-
title:
|
|
204
|
-
children: /* @__PURE__ */
|
|
210
|
+
children: [/* @__PURE__ */ E(u, {
|
|
211
|
+
title: P("devportal.analytics.trafficTrend", "Traffic trend"),
|
|
212
|
+
children: /* @__PURE__ */ E(k, {
|
|
205
213
|
treatment: "insight",
|
|
206
214
|
className: "p-4",
|
|
207
|
-
children: /* @__PURE__ */
|
|
215
|
+
children: /* @__PURE__ */ E(a, {
|
|
208
216
|
width: "100%",
|
|
209
217
|
height: 300,
|
|
210
|
-
children: /* @__PURE__ */
|
|
218
|
+
children: /* @__PURE__ */ D(ne, {
|
|
211
219
|
data: Z,
|
|
212
220
|
children: [
|
|
213
|
-
/* @__PURE__ */
|
|
221
|
+
/* @__PURE__ */ E(n, {
|
|
214
222
|
strokeDasharray: "3 3",
|
|
215
223
|
stroke: "var(--color-chart-grid)"
|
|
216
224
|
}),
|
|
217
|
-
/* @__PURE__ */
|
|
225
|
+
/* @__PURE__ */ E(s, {
|
|
218
226
|
dataKey: "date",
|
|
219
227
|
stroke: "var(--color-chart-axis)",
|
|
220
228
|
fontSize: 12
|
|
221
229
|
}),
|
|
222
|
-
/* @__PURE__ */
|
|
230
|
+
/* @__PURE__ */ E(c, {
|
|
223
231
|
stroke: "var(--color-chart-axis)",
|
|
224
232
|
fontSize: 12
|
|
225
233
|
}),
|
|
226
|
-
/* @__PURE__ */
|
|
234
|
+
/* @__PURE__ */ E(o, { contentStyle: {
|
|
227
235
|
backgroundColor: "var(--color-card)",
|
|
228
236
|
border: "1px solid var(--color-border-default)",
|
|
229
237
|
borderRadius: 12
|
|
230
238
|
} }),
|
|
231
|
-
/* @__PURE__ */
|
|
239
|
+
/* @__PURE__ */ E(i, {
|
|
232
240
|
type: "monotone",
|
|
233
241
|
dataKey: "apiCalls",
|
|
234
|
-
stroke:
|
|
242
|
+
stroke: j.primary,
|
|
235
243
|
strokeWidth: 2,
|
|
236
244
|
dot: !1
|
|
237
245
|
}),
|
|
238
|
-
/* @__PURE__ */
|
|
246
|
+
/* @__PURE__ */ E(i, {
|
|
239
247
|
type: "monotone",
|
|
240
248
|
dataKey: "errors",
|
|
241
|
-
stroke:
|
|
249
|
+
stroke: j.negative,
|
|
242
250
|
strokeWidth: 2,
|
|
243
251
|
dot: !1
|
|
244
252
|
})
|
|
@@ -246,38 +254,38 @@ var ce = {
|
|
|
246
254
|
})
|
|
247
255
|
})
|
|
248
256
|
})
|
|
249
|
-
}), /* @__PURE__ */
|
|
250
|
-
title:
|
|
251
|
-
children: /* @__PURE__ */
|
|
257
|
+
}), /* @__PURE__ */ E(u, {
|
|
258
|
+
title: P("devportal.analytics.userActivity", "User activity"),
|
|
259
|
+
children: /* @__PURE__ */ E(k, {
|
|
252
260
|
treatment: "insight",
|
|
253
261
|
className: "p-4",
|
|
254
|
-
children: /* @__PURE__ */
|
|
262
|
+
children: /* @__PURE__ */ E(a, {
|
|
255
263
|
width: "100%",
|
|
256
264
|
height: 300,
|
|
257
|
-
children: /* @__PURE__ */
|
|
265
|
+
children: /* @__PURE__ */ D(t, {
|
|
258
266
|
data: Z,
|
|
259
267
|
children: [
|
|
260
|
-
/* @__PURE__ */
|
|
268
|
+
/* @__PURE__ */ E(n, {
|
|
261
269
|
strokeDasharray: "3 3",
|
|
262
270
|
stroke: "var(--color-chart-grid)"
|
|
263
271
|
}),
|
|
264
|
-
/* @__PURE__ */
|
|
272
|
+
/* @__PURE__ */ E(s, {
|
|
265
273
|
dataKey: "date",
|
|
266
274
|
stroke: "var(--color-chart-axis)",
|
|
267
275
|
fontSize: 12
|
|
268
276
|
}),
|
|
269
|
-
/* @__PURE__ */
|
|
277
|
+
/* @__PURE__ */ E(c, {
|
|
270
278
|
stroke: "var(--color-chart-axis)",
|
|
271
279
|
fontSize: 12
|
|
272
280
|
}),
|
|
273
|
-
/* @__PURE__ */
|
|
281
|
+
/* @__PURE__ */ E(o, { contentStyle: {
|
|
274
282
|
backgroundColor: "var(--color-card)",
|
|
275
283
|
border: "1px solid var(--color-border-default)",
|
|
276
284
|
borderRadius: 12
|
|
277
285
|
} }),
|
|
278
|
-
/* @__PURE__ */
|
|
286
|
+
/* @__PURE__ */ E(e, {
|
|
279
287
|
dataKey: "activeUsers",
|
|
280
|
-
fill:
|
|
288
|
+
fill: j.primary,
|
|
281
289
|
radius: [
|
|
282
290
|
6,
|
|
283
291
|
6,
|
|
@@ -285,9 +293,9 @@ var ce = {
|
|
|
285
293
|
0
|
|
286
294
|
]
|
|
287
295
|
}),
|
|
288
|
-
/* @__PURE__ */
|
|
296
|
+
/* @__PURE__ */ E(e, {
|
|
289
297
|
dataKey: "newUsers",
|
|
290
|
-
fill:
|
|
298
|
+
fill: j.secondary,
|
|
291
299
|
radius: [
|
|
292
300
|
6,
|
|
293
301
|
6,
|
|
@@ -300,16 +308,15 @@ var ce = {
|
|
|
300
308
|
})
|
|
301
309
|
})
|
|
302
310
|
})]
|
|
303
|
-
}),
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
children: /* @__PURE__ */ T(m, {
|
|
311
|
+
}), /* @__PURE__ */ E(u, {
|
|
312
|
+
title: P("devportal.analytics.dailyBreakdown", "Daily breakdown"),
|
|
313
|
+
children: /* @__PURE__ */ E(re, {
|
|
307
314
|
data: J,
|
|
308
315
|
keyField: "id",
|
|
309
316
|
columns: [
|
|
310
317
|
{
|
|
311
318
|
key: "date",
|
|
312
|
-
header:
|
|
319
|
+
header: P("devportal.analytics.date", "Date"),
|
|
313
320
|
render: (e) => new Date(e.date).toLocaleDateString(void 0, {
|
|
314
321
|
month: "short",
|
|
315
322
|
day: "numeric",
|
|
@@ -318,51 +325,51 @@ var ce = {
|
|
|
318
325
|
},
|
|
319
326
|
{
|
|
320
327
|
key: "apiCalls",
|
|
321
|
-
header:
|
|
328
|
+
header: P("devportal.analytics.apiCalls", "API Calls"),
|
|
322
329
|
render: (e) => e.apiCalls.toLocaleString()
|
|
323
330
|
},
|
|
324
331
|
{
|
|
325
332
|
key: "errors",
|
|
326
|
-
header:
|
|
333
|
+
header: P("devportal.analytics.errors", "Errors"),
|
|
327
334
|
render: (e) => e.errors.toLocaleString()
|
|
328
335
|
},
|
|
329
336
|
{
|
|
330
337
|
key: "activeUsers",
|
|
331
|
-
header:
|
|
338
|
+
header: P("devportal.analytics.activeUsers", "Active Users"),
|
|
332
339
|
render: (e) => e.activeUsers.toLocaleString()
|
|
333
340
|
},
|
|
334
341
|
{
|
|
335
342
|
key: "newUsers",
|
|
336
|
-
header:
|
|
343
|
+
header: P("devportal.analytics.newUsers", "New Users"),
|
|
337
344
|
render: (e) => e.newUsers.toLocaleString()
|
|
338
345
|
},
|
|
339
346
|
{
|
|
340
347
|
key: "avgResponseTime",
|
|
341
|
-
header:
|
|
342
|
-
render: (e) => e.avgResponseTime ? `${e.avgResponseTime}ms` :
|
|
348
|
+
header: P("devportal.analytics.avgResponse", "Avg Response"),
|
|
349
|
+
render: (e) => e.avgResponseTime ? `${e.avgResponseTime}ms` : P("devportal.common.na", "N/A")
|
|
343
350
|
},
|
|
344
351
|
{
|
|
345
352
|
key: "sessions",
|
|
346
|
-
header:
|
|
353
|
+
header: P("devportal.analytics.sessions", "Sessions"),
|
|
347
354
|
render: (e) => e.sessions.toLocaleString()
|
|
348
355
|
}
|
|
349
356
|
]
|
|
350
357
|
})
|
|
351
|
-
})
|
|
352
|
-
] }) : /* @__PURE__ */
|
|
358
|
+
})]
|
|
359
|
+
})] }) : /* @__PURE__ */ E(d, {
|
|
353
360
|
illustration: "empty-data",
|
|
354
|
-
icon: /* @__PURE__ */
|
|
355
|
-
title:
|
|
356
|
-
description:
|
|
357
|
-
action:
|
|
361
|
+
icon: /* @__PURE__ */ E(b, { size: 32 }),
|
|
362
|
+
title: P("devportal.analytics.noAnalyticsTitle", "No analytics available yet"),
|
|
363
|
+
description: P("devportal.analytics.noAnalyticsDescription", "Analytics will appear after this application starts receiving traffic through the public gateway."),
|
|
364
|
+
action: M ? void 0 : /* @__PURE__ */ E("button", {
|
|
358
365
|
type: "button",
|
|
359
|
-
onClick: () =>
|
|
366
|
+
onClick: () => he("/apps"),
|
|
360
367
|
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 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-primary",
|
|
361
|
-
children:
|
|
368
|
+
children: P("devportal.analytics.viewApplications", "View applications")
|
|
362
369
|
})
|
|
363
370
|
})
|
|
364
371
|
});
|
|
365
372
|
};
|
|
366
|
-
export {
|
|
373
|
+
export { M as AnalyticsDashboardPage };
|
|
367
374
|
|
|
368
375
|
//# sourceMappingURL=AnalyticsDashboardPage.js.map
|