@burdenoff/microfe-atheletebridge 2026.1110.1 → 2026.1110.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/atheletebridge/AthleteBridgeRoutes.js +22 -6
- package/dist/atheletebridge/AthleteBridgeRoutes.js.map +1 -1
- package/dist/atheletebridge/components/StatusBadge.js +8 -0
- package/dist/atheletebridge/components/StatusBadge.js.map +1 -1
- package/dist/atheletebridge/hooks/useAuditApi.d.ts +14 -0
- package/dist/atheletebridge/hooks/useAuditApi.js +38 -0
- package/dist/atheletebridge/hooks/useAuditApi.js.map +1 -0
- package/dist/atheletebridge/hooks/useRegistrationApi.d.ts +15 -0
- package/dist/atheletebridge/hooks/useRegistrationApi.js +38 -19
- package/dist/atheletebridge/hooks/useRegistrationApi.js.map +1 -1
- package/dist/atheletebridge/pages/audit/AuditLogPage.d.ts +11 -0
- package/dist/atheletebridge/pages/audit/AuditLogPage.js +277 -0
- package/dist/atheletebridge/pages/audit/AuditLogPage.js.map +1 -0
- package/dist/atheletebridge/pages/control/ClubControlPage.d.ts +11 -0
- package/dist/atheletebridge/pages/control/ClubControlPage.js +208 -0
- package/dist/atheletebridge/pages/control/ClubControlPage.js.map +1 -0
- package/dist/atheletebridge/pages/fixtures/FixtureDetailPage.js +126 -65
- package/dist/atheletebridge/pages/fixtures/FixtureDetailPage.js.map +1 -1
- package/dist/atheletebridge/pages/registrations/RegistrationFormBuilderPage.js +243 -217
- package/dist/atheletebridge/pages/registrations/RegistrationFormBuilderPage.js.map +1 -1
- package/dist/atheletebridge/pages/registrations/RegistrationFormDetailPage.js +136 -83
- package/dist/atheletebridge/pages/registrations/RegistrationFormDetailPage.js.map +1 -1
- package/dist/atheletebridge/pages/registrations/RegistrationSubmissionPage.js +173 -146
- package/dist/atheletebridge/pages/registrations/RegistrationSubmissionPage.js.map +1 -1
- package/dist/atheletebridge/types/audit.d.ts +47 -0
- package/dist/atheletebridge/types/registration.d.ts +22 -1
- package/package.json +1 -1
|
@@ -7,15 +7,15 @@ import { Loader2 as o } from "lucide-react";
|
|
|
7
7
|
import { Navigate as s, Route as c, Routes as l, useLocation as u } from "react-router";
|
|
8
8
|
import { jsx as d, jsxs as f } from "react/jsx-runtime";
|
|
9
9
|
// src/atheletebridge/AthleteBridgeRoutes.tsx
|
|
10
|
-
var p = i(() => import("./pages/onboarding/OnboardingPage.js").then((e) => ({ default: e.OnboardingPage }))), m = i(() => import("./pages/teams/TeamsListPage.js").then((e) => ({ default: e.TeamsListPage }))), h = i(() => import("./pages/teams/TeamDetailPage.js").then((e) => ({ default: e.TeamDetailPage }))), g = i(() => import("./pages/teams/TeamFormPage.js").then((e) => ({ default: e.TeamFormPage }))), _ = i(() => import("./pages/fixtures/FixturesListPage.js").then((e) => ({ default: e.FixturesListPage }))), v = i(() => import("./pages/fixtures/FixtureDetailPage.js").then((e) => ({ default: e.FixtureDetailPage }))), y = i(() => import("./pages/fixtures/FixtureFormPage.js").then((e) => ({ default: e.FixtureFormPage }))), b = i(() => import("./pages/StandingsPage.js").then((e) => ({ default: e.StandingsPage }))), x = i(() => import("./pages/programs/ProgramsListPage.js").then((e) => ({ default: e.ProgramsListPage }))), S = i(() => import("./pages/programs/ProgramDetailPage.js").then((e) => ({ default: e.ProgramDetailPage }))), C = i(() => import("./pages/programs/ProgramFormPage.js").then((e) => ({ default: e.ProgramFormPage }))), w = i(() => import("./pages/sessions/SessionsListPage.js").then((e) => ({ default: e.SessionsListPage }))), T = i(() => import("./pages/sessions/SessionsCalendarPage.js").then((e) => ({ default: e.SessionsCalendarPage }))), E = i(() => import("./pages/sessions/SessionDetailPage.js").then((e) => ({ default: e.SessionDetailPage }))), D = i(() => import("./pages/sessions/SessionFormPage.js").then((e) => ({ default: e.SessionFormPage }))), O = i(() => import("./pages/performance/PerformancePage.js").then((e) => ({ default: e.PerformancePage }))), k = i(() => import("./pages/athletes/AthleteProfilePage.js").then((e) => ({ default: e.AthleteProfilePage }))), A = i(() => import("./pages/analytics/CoachAnalyticsPage.js").then((e) => ({ default: e.CoachAnalyticsPage }))), j = i(() => import("./pages/ai/AiOperationsPage.js").then((e) => ({ default: e.AiOperationsPage }))), M = i(() => import("./pages/tournaments/TournamentBracketPage.js").then((e) => ({ default: e.TournamentBracketPage }))), N = i(() => import("./pages/registrations/RegistrationFormsListPage.js").then((e) => ({ default: e.RegistrationFormsListPage }))), P = i(() => import("./pages/registrations/RegistrationFormBuilderPage.js").then((e) => ({ default: e.RegistrationFormBuilderPage }))), F = i(() => import("./pages/registrations/RegistrationFormDetailPage.js").then((e) => ({ default: e.RegistrationFormDetailPage }))), I = i(() => import("./pages/registrations/RegistrationSubmissionPage.js").then((e) => ({ default: e.RegistrationSubmissionPage }))), L = i(() => import("./pages/registrations/RecordRegistrationPage.js").then((e) => ({ default: e.RecordRegistrationPage }))), R = i(() => import("./pages/registrations/RegisterPage.js").then((e) => ({ default: e.RegisterPage }))), z = i(() => import("./pages/registrations/MyRegistrationsPage.js").then((e) => ({ default: e.MyRegistrationsPage }))), B = () => /* @__PURE__ */ d("div", {
|
|
10
|
+
var p = i(() => import("./pages/onboarding/OnboardingPage.js").then((e) => ({ default: e.OnboardingPage }))), m = i(() => import("./pages/teams/TeamsListPage.js").then((e) => ({ default: e.TeamsListPage }))), h = i(() => import("./pages/teams/TeamDetailPage.js").then((e) => ({ default: e.TeamDetailPage }))), g = i(() => import("./pages/teams/TeamFormPage.js").then((e) => ({ default: e.TeamFormPage }))), _ = i(() => import("./pages/fixtures/FixturesListPage.js").then((e) => ({ default: e.FixturesListPage }))), v = i(() => import("./pages/fixtures/FixtureDetailPage.js").then((e) => ({ default: e.FixtureDetailPage }))), y = i(() => import("./pages/fixtures/FixtureFormPage.js").then((e) => ({ default: e.FixtureFormPage }))), b = i(() => import("./pages/StandingsPage.js").then((e) => ({ default: e.StandingsPage }))), x = i(() => import("./pages/programs/ProgramsListPage.js").then((e) => ({ default: e.ProgramsListPage }))), S = i(() => import("./pages/programs/ProgramDetailPage.js").then((e) => ({ default: e.ProgramDetailPage }))), C = i(() => import("./pages/programs/ProgramFormPage.js").then((e) => ({ default: e.ProgramFormPage }))), w = i(() => import("./pages/sessions/SessionsListPage.js").then((e) => ({ default: e.SessionsListPage }))), T = i(() => import("./pages/sessions/SessionsCalendarPage.js").then((e) => ({ default: e.SessionsCalendarPage }))), E = i(() => import("./pages/sessions/SessionDetailPage.js").then((e) => ({ default: e.SessionDetailPage }))), D = i(() => import("./pages/sessions/SessionFormPage.js").then((e) => ({ default: e.SessionFormPage }))), O = i(() => import("./pages/performance/PerformancePage.js").then((e) => ({ default: e.PerformancePage }))), k = i(() => import("./pages/athletes/AthleteProfilePage.js").then((e) => ({ default: e.AthleteProfilePage }))), A = i(() => import("./pages/analytics/CoachAnalyticsPage.js").then((e) => ({ default: e.CoachAnalyticsPage }))), j = i(() => import("./pages/ai/AiOperationsPage.js").then((e) => ({ default: e.AiOperationsPage }))), M = i(() => import("./pages/tournaments/TournamentBracketPage.js").then((e) => ({ default: e.TournamentBracketPage }))), N = i(() => import("./pages/registrations/RegistrationFormsListPage.js").then((e) => ({ default: e.RegistrationFormsListPage }))), P = i(() => import("./pages/registrations/RegistrationFormBuilderPage.js").then((e) => ({ default: e.RegistrationFormBuilderPage }))), F = i(() => import("./pages/registrations/RegistrationFormDetailPage.js").then((e) => ({ default: e.RegistrationFormDetailPage }))), I = i(() => import("./pages/registrations/RegistrationSubmissionPage.js").then((e) => ({ default: e.RegistrationSubmissionPage }))), L = i(() => import("./pages/registrations/RecordRegistrationPage.js").then((e) => ({ default: e.RecordRegistrationPage }))), R = i(() => import("./pages/registrations/RegisterPage.js").then((e) => ({ default: e.RegisterPage }))), z = i(() => import("./pages/registrations/MyRegistrationsPage.js").then((e) => ({ default: e.MyRegistrationsPage }))), B = i(() => import("./pages/control/ClubControlPage.js").then((e) => ({ default: e.ClubControlPage }))), V = i(() => import("./pages/audit/AuditLogPage.js").then((e) => ({ default: e.AuditLogPage }))), H = () => /* @__PURE__ */ d("div", {
|
|
11
11
|
className: "flex min-h-[400px] items-center justify-center",
|
|
12
12
|
children: /* @__PURE__ */ d(o, { className: "h-8 w-8 animate-spin text-text-secondary" })
|
|
13
|
-
}),
|
|
14
|
-
let { basePath: i, isStandalone: o } = e(),
|
|
15
|
-
return
|
|
13
|
+
}), U = () => {
|
|
14
|
+
let { basePath: i, isStandalone: o } = e(), U = u(), W = i === "/" ? "" : (i ?? "").replace(/\/$/, "");
|
|
15
|
+
return W && !o && !(U.pathname === W || U.pathname.startsWith(W + "/")) ? null : /* @__PURE__ */ d("div", {
|
|
16
16
|
className: "flex min-h-full flex-col",
|
|
17
17
|
children: /* @__PURE__ */ f(r, {
|
|
18
|
-
fallback: /* @__PURE__ */ d(
|
|
18
|
+
fallback: /* @__PURE__ */ d(H, {}),
|
|
19
19
|
children: [/* @__PURE__ */ d(t, {}), /* @__PURE__ */ f(l, { children: [
|
|
20
20
|
/* @__PURE__ */ d(c, {
|
|
21
21
|
index: !0,
|
|
@@ -145,6 +145,22 @@ var p = i(() => import("./pages/onboarding/OnboardingPage.js").then((e) => ({ de
|
|
|
145
145
|
path: "my-registrations",
|
|
146
146
|
element: /* @__PURE__ */ d(z, {})
|
|
147
147
|
}),
|
|
148
|
+
/* @__PURE__ */ d(c, {
|
|
149
|
+
path: "control-room",
|
|
150
|
+
element: /* @__PURE__ */ d(a, {
|
|
151
|
+
flag: "atheletebridge.control-room.enabled",
|
|
152
|
+
defaultValue: !0,
|
|
153
|
+
children: /* @__PURE__ */ d(B, {})
|
|
154
|
+
})
|
|
155
|
+
}),
|
|
156
|
+
/* @__PURE__ */ d(c, {
|
|
157
|
+
path: "audit",
|
|
158
|
+
element: /* @__PURE__ */ d(a, {
|
|
159
|
+
flag: "atheletebridge.audit.enabled",
|
|
160
|
+
defaultValue: !0,
|
|
161
|
+
children: /* @__PURE__ */ d(V, {})
|
|
162
|
+
})
|
|
163
|
+
}),
|
|
148
164
|
/* @__PURE__ */ d(c, {
|
|
149
165
|
path: "standings",
|
|
150
166
|
element: /* @__PURE__ */ d(a, {
|
|
@@ -260,6 +276,6 @@ var p = i(() => import("./pages/onboarding/OnboardingPage.js").then((e) => ({ de
|
|
|
260
276
|
})
|
|
261
277
|
});
|
|
262
278
|
};
|
|
263
|
-
export {
|
|
279
|
+
export { U as AthleteBridgeRoutes };
|
|
264
280
|
|
|
265
281
|
//# sourceMappingURL=AthleteBridgeRoutes.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AthleteBridgeRoutes.js","names":["OnboardingPage","lazy","m","TeamsListPage","TeamDetailPage","TeamFormPage","FixturesListPage","FixtureDetailPage","FixtureFormPage","StandingsPage","ProgramsListPage","ProgramDetailPage","ProgramFormPage","SessionsListPage","SessionsCalendarPage","SessionDetailPage","SessionFormPage","PerformancePage","AthleteProfilePage","CoachAnalyticsPage","AiOperationsPage","TournamentBracketPage","RegistrationFormsListPage","RegistrationFormBuilderPage","RegistrationFormDetailPage","RegistrationSubmissionPage","RecordRegistrationPage","RegisterPage","MyRegistrationsPage","PageLoader","Loader2","AthleteBridgeRoutes","useAthleteBridge","location","useLocation","normalizedBasePath","basePath","isStandalone","Suspense","RouteAnalytics","Routes","Route","DashboardPage","FeatureGate","Navigate"],"sources":["../../src/atheletebridge/AthleteBridgeRoutes.tsx"],"sourcesContent":["/**\n * AthleteBridge Routes\n * @module atheletebridge\n *\n * Real sports-domain routes wired to the deployed `wspace-atheletebridge-svc`\n * GraphQL contract. Dashboard is eager; entity pages are lazy.\n */\n\nimport { type FC, lazy, Suspense } from 'react';\nimport { Routes, Route, Navigate, useLocation } from 'react-router';\nimport { Loader2 } from 'lucide-react';\nimport { FeatureGate } from '@burdenoff/fe-libs/shared/feature-flags';\nimport { useAthleteBridge } from './context/AthleteBridgeContext';\nimport { RouteAnalytics } from './components/RouteAnalytics';\n\n// Eager — primary landing\nimport { DashboardPage } from './pages/DashboardPage';\n\n// Onboarding (first-run wizard: sport → team → role)\nconst OnboardingPage = lazy(() =>\n import('./pages/onboarding/OnboardingPage').then((m) => ({ default: m.OnboardingPage }))\n);\n\n// Teams\nconst TeamsListPage = lazy(() =>\n import('./pages/teams/TeamsListPage').then((m) => ({ default: m.TeamsListPage }))\n);\nconst TeamDetailPage = lazy(() =>\n import('./pages/teams/TeamDetailPage').then((m) => ({ default: m.TeamDetailPage }))\n);\nconst TeamFormPage = lazy(() =>\n import('./pages/teams/TeamFormPage').then((m) => ({ default: m.TeamFormPage }))\n);\n\n// Fixtures\nconst FixturesListPage = lazy(() =>\n import('./pages/fixtures/FixturesListPage').then((m) => ({ default: m.FixturesListPage }))\n);\nconst FixtureDetailPage = lazy(() =>\n import('./pages/fixtures/FixtureDetailPage').then((m) => ({ default: m.FixtureDetailPage }))\n);\nconst FixtureFormPage = lazy(() =>\n import('./pages/fixtures/FixtureFormPage').then((m) => ({ default: m.FixtureFormPage }))\n);\n\n// Standings\nconst StandingsPage = lazy(() =>\n import('./pages/StandingsPage').then((m) => ({ default: m.StandingsPage }))\n);\n\n// Programs\nconst ProgramsListPage = lazy(() =>\n import('./pages/programs/ProgramsListPage').then((m) => ({ default: m.ProgramsListPage }))\n);\nconst ProgramDetailPage = lazy(() =>\n import('./pages/programs/ProgramDetailPage').then((m) => ({ default: m.ProgramDetailPage }))\n);\nconst ProgramFormPage = lazy(() =>\n import('./pages/programs/ProgramFormPage').then((m) => ({ default: m.ProgramFormPage }))\n);\n\n// Sessions\nconst SessionsListPage = lazy(() =>\n import('./pages/sessions/SessionsListPage').then((m) => ({ default: m.SessionsListPage }))\n);\nconst SessionsCalendarPage = lazy(() =>\n import('./pages/sessions/SessionsCalendarPage').then((m) => ({ default: m.SessionsCalendarPage }))\n);\nconst SessionDetailPage = lazy(() =>\n import('./pages/sessions/SessionDetailPage').then((m) => ({ default: m.SessionDetailPage }))\n);\nconst SessionFormPage = lazy(() =>\n import('./pages/sessions/SessionFormPage').then((m) => ({ default: m.SessionFormPage }))\n);\n\n// Performance\nconst PerformancePage = lazy(() =>\n import('./pages/performance/PerformancePage').then((m) => ({ default: m.PerformancePage }))\n);\n\n// Athlete profile\nconst AthleteProfilePage = lazy(() =>\n import('./pages/athletes/AthleteProfilePage').then((m) => ({ default: m.AthleteProfilePage }))\n);\n\n// Coach analytics\nconst CoachAnalyticsPage = lazy(() =>\n import('./pages/analytics/CoachAnalyticsPage').then((m) => ({ default: m.CoachAnalyticsPage }))\n);\n\n// AI operations (model picker, decision ledger, decision cards)\nconst AiOperationsPage = lazy(() =>\n import('./pages/ai/AiOperationsPage').then((m) => ({ default: m.AiOperationsPage }))\n);\n\n// Tournaments (esports bracket)\nconst TournamentBracketPage = lazy(() =>\n import('./pages/tournaments/TournamentBracketPage').then((m) => ({\n default: m.TournamentBracketPage,\n }))\n);\n\n// Club registration & payments (BOFF-4135)\nconst RegistrationFormsListPage = lazy(() =>\n import('./pages/registrations/RegistrationFormsListPage').then((m) => ({\n default: m.RegistrationFormsListPage,\n }))\n);\nconst RegistrationFormBuilderPage = lazy(() =>\n import('./pages/registrations/RegistrationFormBuilderPage').then((m) => ({\n default: m.RegistrationFormBuilderPage,\n }))\n);\nconst RegistrationFormDetailPage = lazy(() =>\n import('./pages/registrations/RegistrationFormDetailPage').then((m) => ({\n default: m.RegistrationFormDetailPage,\n }))\n);\nconst RegistrationSubmissionPage = lazy(() =>\n import('./pages/registrations/RegistrationSubmissionPage').then((m) => ({\n default: m.RegistrationSubmissionPage,\n }))\n);\nconst RecordRegistrationPage = lazy(() =>\n import('./pages/registrations/RecordRegistrationPage').then((m) => ({\n default: m.RecordRegistrationPage,\n }))\n);\nconst RegisterPage = lazy(() =>\n import('./pages/registrations/RegisterPage').then((m) => ({ default: m.RegisterPage }))\n);\nconst MyRegistrationsPage = lazy(() =>\n import('./pages/registrations/MyRegistrationsPage').then((m) => ({\n default: m.MyRegistrationsPage,\n }))\n);\n\nconst PageLoader: FC = () => (\n <div className=\"flex min-h-[400px] items-center justify-center\">\n <Loader2 className=\"h-8 w-8 animate-spin text-text-secondary\" />\n </div>\n);\n\nexport const AthleteBridgeRoutes: FC = () => {\n const { basePath, isStandalone } = useAthleteBridge();\n const location = useLocation();\n\n const normalizedBasePath = basePath === '/' ? '' : (basePath ?? '').replace(/\\/$/, '');\n\n // Guard: only render when the path matches basePath (integrated mode).\n if (normalizedBasePath && !isStandalone) {\n const pathMatches =\n location.pathname === normalizedBasePath ||\n location.pathname.startsWith(normalizedBasePath + '/');\n if (!pathMatches) {\n return null;\n }\n }\n\n return (\n <div className=\"flex min-h-full flex-col\">\n <Suspense fallback={<PageLoader />}>\n <RouteAnalytics />\n <Routes>\n {/* Dashboard */}\n <Route index element={<DashboardPage />} />\n\n {/*\n Onboarding — the first-run wizard. Intentionally NOT behind a\n FeatureGate: it only collects sport/team/role and writes through the\n same `athCreateTeam` / `athAddMember` the gated Teams pages use, so a\n flag here would gate nothing that `atheletebridge.teams.enabled` does\n not already gate at the destination.\n */}\n <Route path=\"onboarding\" element={<OnboardingPage />} />\n\n {/* Teams */}\n <Route\n path=\"teams\"\n element={\n <FeatureGate flag=\"atheletebridge.teams.enabled\" defaultValue={true}>\n <TeamsListPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"teams/new\"\n element={\n <FeatureGate flag=\"atheletebridge.teams.enabled\" defaultValue={true}>\n <TeamFormPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"teams/:id\"\n element={\n <FeatureGate flag=\"atheletebridge.teams.enabled\" defaultValue={true}>\n <TeamDetailPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"teams/:id/edit\"\n element={\n <FeatureGate flag=\"atheletebridge.teams.enabled\" defaultValue={true}>\n <TeamFormPage />\n </FeatureGate>\n }\n />\n\n {/* Athlete profile (reached from a team roster) */}\n <Route\n path=\"teams/:teamId/athletes/:memberId\"\n element={\n <FeatureGate flag=\"atheletebridge.teams.enabled\" defaultValue={true}>\n <AthleteProfilePage />\n </FeatureGate>\n }\n />\n\n {/* Fixtures */}\n <Route\n path=\"fixtures\"\n element={\n <FeatureGate flag=\"atheletebridge.fixtures.enabled\" defaultValue={true}>\n <FixturesListPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"fixtures/new\"\n element={\n <FeatureGate flag=\"atheletebridge.fixtures.enabled\" defaultValue={true}>\n <FixtureFormPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"fixtures/:id\"\n element={\n <FeatureGate flag=\"atheletebridge.fixtures.enabled\" defaultValue={true}>\n <FixtureDetailPage />\n </FeatureGate>\n }\n />\n\n {/* Club registration & payments (BOFF-4135) */}\n <Route\n path=\"registrations\"\n element={\n <FeatureGate flag=\"atheletebridge.registrations.enabled\" defaultValue={true}>\n <RegistrationFormsListPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"registrations/new\"\n element={\n <FeatureGate flag=\"atheletebridge.registrations.enabled\" defaultValue={true}>\n <RegistrationFormBuilderPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"registrations/:id\"\n element={\n <FeatureGate flag=\"atheletebridge.registrations.enabled\" defaultValue={true}>\n <RegistrationFormDetailPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"registrations/:id/edit\"\n element={\n <FeatureGate flag=\"atheletebridge.registrations.enabled\" defaultValue={true}>\n <RegistrationFormBuilderPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"registrations/:id/record\"\n element={\n <FeatureGate flag=\"atheletebridge.registrations.enabled\" defaultValue={true}>\n <RecordRegistrationPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"registrations/:id/submissions/:submissionId\"\n element={\n <FeatureGate flag=\"atheletebridge.registrations.enabled\" defaultValue={true}>\n <RegistrationSubmissionPage />\n </FeatureGate>\n }\n />\n {/*\n Family-facing share link + \"my registrations\": self-scoped at the\n gateway (any signed-in user), so deliberately not behind the staff\n feature flag — a club's published link must keep working.\n */}\n <Route path=\"register/:slug\" element={<RegisterPage />} />\n <Route path=\"my-registrations\" element={<MyRegistrationsPage />} />\n\n {/* Standings */}\n <Route\n path=\"standings\"\n element={\n <FeatureGate flag=\"atheletebridge.standings.enabled\" defaultValue={true}>\n <StandingsPage />\n </FeatureGate>\n }\n />\n\n {/* Programs */}\n <Route\n path=\"programs\"\n element={\n <FeatureGate flag=\"atheletebridge.programs.enabled\" defaultValue={true}>\n <ProgramsListPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"programs/new\"\n element={\n <FeatureGate flag=\"atheletebridge.programs.enabled\" defaultValue={true}>\n <ProgramFormPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"programs/:id\"\n element={\n <FeatureGate flag=\"atheletebridge.programs.enabled\" defaultValue={true}>\n <ProgramDetailPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"programs/:id/edit\"\n element={\n <FeatureGate flag=\"atheletebridge.programs.enabled\" defaultValue={true}>\n <ProgramFormPage />\n </FeatureGate>\n }\n />\n\n {/* Sessions */}\n <Route\n path=\"sessions\"\n element={\n <FeatureGate flag=\"atheletebridge.sessions.enabled\" defaultValue={true}>\n <SessionsListPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"sessions/calendar\"\n element={\n <FeatureGate flag=\"atheletebridge.sessions.enabled\" defaultValue={true}>\n <SessionsCalendarPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"sessions/new\"\n element={\n <FeatureGate flag=\"atheletebridge.sessions.enabled\" defaultValue={true}>\n <SessionFormPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"sessions/:id\"\n element={\n <FeatureGate flag=\"atheletebridge.sessions.enabled\" defaultValue={true}>\n <SessionDetailPage />\n </FeatureGate>\n }\n />\n\n {/* Performance */}\n <Route\n path=\"performance\"\n element={\n <FeatureGate flag=\"atheletebridge.performance.enabled\" defaultValue={true}>\n <PerformancePage />\n </FeatureGate>\n }\n />\n\n {/* Analytics */}\n <Route\n path=\"analytics\"\n element={\n <FeatureGate flag=\"atheletebridge.analytics.enabled\" defaultValue={true}>\n <CoachAnalyticsPage />\n </FeatureGate>\n }\n />\n\n {/* AI operations */}\n <Route\n path=\"ai\"\n element={\n <FeatureGate flag=\"atheletebridge.ai.enabled\" defaultValue={true}>\n <AiOperationsPage />\n </FeatureGate>\n }\n />\n\n {/* Tournaments (esports bracket) */}\n <Route\n path=\"tournaments\"\n element={\n <FeatureGate flag=\"atheletebridge.tournaments.enabled\" defaultValue={true}>\n <TournamentBracketPage />\n </FeatureGate>\n }\n />\n\n {/* Fallback */}\n <Route path=\"*\" element={<Navigate to=\".\" replace />} />\n </Routes>\n </Suspense>\n </div>\n );\n};\n"],"mappings":";;;;;;;;;AAmBA,IAAMA,IAAiBC,QACrB,OAAO,uCAAoC,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,eAAe,EAAE,CACzF,GAGMC,IAAgBF,QACpB,OAAO,iCAA8B,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,cAAc,EAAE,CAClF,GACME,IAAiBH,QACrB,OAAO,kCAA+B,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,eAAe,EAAE,CACpF,GACMG,IAAeJ,QACnB,OAAO,gCAA6B,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,aAAa,EAAE,CAChF,GAGMI,IAAmBL,QACvB,OAAO,uCAAoC,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,iBAAiB,EAAE,CAC3F,GACMK,IAAoBN,QACxB,OAAO,wCAAqC,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,kBAAkB,EAAE,CAC7F,GACMM,IAAkBP,QACtB,OAAO,sCAAmC,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,gBAAgB,EAAE,CACzF,GAGMO,IAAgBR,QACpB,OAAO,2BAAwB,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,cAAc,EAAE,CAC5E,GAGMQ,IAAmBT,QACvB,OAAO,uCAAoC,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,iBAAiB,EAAE,CAC3F,GACMS,IAAoBV,QACxB,OAAO,wCAAqC,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,kBAAkB,EAAE,C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,CAAA;IAEhB,CAAA;IAGD,kBAACqB,GAAD;KACE,MAAK;KACL,SACE,kBAACE,GAAD;MAAa,MAAK;MAAqC,cAAc;MACnE,UAAA,kBAACtB,GAAD,CAAwB,CAAA;KACb,CAAA;IAEhB,CAAA;IAGD,kBAACoB,GAAD;KAAO,MAAK;KAAI,SAAS,kBAACG,GAAD;MAAU,IAAG;MAAI,SAAA;KAAS,CAAA;IAAI,CAAA;GACjD,EAAA,CAAA,CACA;;CACP,CAAA;AAET"}
|
|
1
|
+
{"version":3,"file":"AthleteBridgeRoutes.js","names":["OnboardingPage","lazy","m","TeamsListPage","TeamDetailPage","TeamFormPage","FixturesListPage","FixtureDetailPage","FixtureFormPage","StandingsPage","ProgramsListPage","ProgramDetailPage","ProgramFormPage","SessionsListPage","SessionsCalendarPage","SessionDetailPage","SessionFormPage","PerformancePage","AthleteProfilePage","CoachAnalyticsPage","AiOperationsPage","TournamentBracketPage","RegistrationFormsListPage","RegistrationFormBuilderPage","RegistrationFormDetailPage","RegistrationSubmissionPage","RecordRegistrationPage","RegisterPage","MyRegistrationsPage","ClubControlPage","AuditLogPage","PageLoader","Loader2","AthleteBridgeRoutes","useAthleteBridge","location","useLocation","normalizedBasePath","basePath","isStandalone","Suspense","RouteAnalytics","Routes","Route","DashboardPage","FeatureGate","Navigate"],"sources":["../../src/atheletebridge/AthleteBridgeRoutes.tsx"],"sourcesContent":["/**\n * AthleteBridge Routes\n * @module atheletebridge\n *\n * Real sports-domain routes wired to the deployed `wspace-atheletebridge-svc`\n * GraphQL contract. Dashboard is eager; entity pages are lazy.\n */\n\nimport { type FC, lazy, Suspense } from 'react';\nimport { Routes, Route, Navigate, useLocation } from 'react-router';\nimport { Loader2 } from 'lucide-react';\nimport { FeatureGate } from '@burdenoff/fe-libs/shared/feature-flags';\nimport { useAthleteBridge } from './context/AthleteBridgeContext';\nimport { RouteAnalytics } from './components/RouteAnalytics';\n\n// Eager — primary landing\nimport { DashboardPage } from './pages/DashboardPage';\n\n// Onboarding (first-run wizard: sport → team → role)\nconst OnboardingPage = lazy(() =>\n import('./pages/onboarding/OnboardingPage').then((m) => ({ default: m.OnboardingPage }))\n);\n\n// Teams\nconst TeamsListPage = lazy(() =>\n import('./pages/teams/TeamsListPage').then((m) => ({ default: m.TeamsListPage }))\n);\nconst TeamDetailPage = lazy(() =>\n import('./pages/teams/TeamDetailPage').then((m) => ({ default: m.TeamDetailPage }))\n);\nconst TeamFormPage = lazy(() =>\n import('./pages/teams/TeamFormPage').then((m) => ({ default: m.TeamFormPage }))\n);\n\n// Fixtures\nconst FixturesListPage = lazy(() =>\n import('./pages/fixtures/FixturesListPage').then((m) => ({ default: m.FixturesListPage }))\n);\nconst FixtureDetailPage = lazy(() =>\n import('./pages/fixtures/FixtureDetailPage').then((m) => ({ default: m.FixtureDetailPage }))\n);\nconst FixtureFormPage = lazy(() =>\n import('./pages/fixtures/FixtureFormPage').then((m) => ({ default: m.FixtureFormPage }))\n);\n\n// Standings\nconst StandingsPage = lazy(() =>\n import('./pages/StandingsPage').then((m) => ({ default: m.StandingsPage }))\n);\n\n// Programs\nconst ProgramsListPage = lazy(() =>\n import('./pages/programs/ProgramsListPage').then((m) => ({ default: m.ProgramsListPage }))\n);\nconst ProgramDetailPage = lazy(() =>\n import('./pages/programs/ProgramDetailPage').then((m) => ({ default: m.ProgramDetailPage }))\n);\nconst ProgramFormPage = lazy(() =>\n import('./pages/programs/ProgramFormPage').then((m) => ({ default: m.ProgramFormPage }))\n);\n\n// Sessions\nconst SessionsListPage = lazy(() =>\n import('./pages/sessions/SessionsListPage').then((m) => ({ default: m.SessionsListPage }))\n);\nconst SessionsCalendarPage = lazy(() =>\n import('./pages/sessions/SessionsCalendarPage').then((m) => ({ default: m.SessionsCalendarPage }))\n);\nconst SessionDetailPage = lazy(() =>\n import('./pages/sessions/SessionDetailPage').then((m) => ({ default: m.SessionDetailPage }))\n);\nconst SessionFormPage = lazy(() =>\n import('./pages/sessions/SessionFormPage').then((m) => ({ default: m.SessionFormPage }))\n);\n\n// Performance\nconst PerformancePage = lazy(() =>\n import('./pages/performance/PerformancePage').then((m) => ({ default: m.PerformancePage }))\n);\n\n// Athlete profile\nconst AthleteProfilePage = lazy(() =>\n import('./pages/athletes/AthleteProfilePage').then((m) => ({ default: m.AthleteProfilePage }))\n);\n\n// Coach analytics\nconst CoachAnalyticsPage = lazy(() =>\n import('./pages/analytics/CoachAnalyticsPage').then((m) => ({ default: m.CoachAnalyticsPage }))\n);\n\n// AI operations (model picker, decision ledger, decision cards)\nconst AiOperationsPage = lazy(() =>\n import('./pages/ai/AiOperationsPage').then((m) => ({ default: m.AiOperationsPage }))\n);\n\n// Tournaments (esports bracket)\nconst TournamentBracketPage = lazy(() =>\n import('./pages/tournaments/TournamentBracketPage').then((m) => ({\n default: m.TournamentBracketPage,\n }))\n);\n\n// Club registration & payments (BOFF-4135)\nconst RegistrationFormsListPage = lazy(() =>\n import('./pages/registrations/RegistrationFormsListPage').then((m) => ({\n default: m.RegistrationFormsListPage,\n }))\n);\nconst RegistrationFormBuilderPage = lazy(() =>\n import('./pages/registrations/RegistrationFormBuilderPage').then((m) => ({\n default: m.RegistrationFormBuilderPage,\n }))\n);\nconst RegistrationFormDetailPage = lazy(() =>\n import('./pages/registrations/RegistrationFormDetailPage').then((m) => ({\n default: m.RegistrationFormDetailPage,\n }))\n);\nconst RegistrationSubmissionPage = lazy(() =>\n import('./pages/registrations/RegistrationSubmissionPage').then((m) => ({\n default: m.RegistrationSubmissionPage,\n }))\n);\nconst RecordRegistrationPage = lazy(() =>\n import('./pages/registrations/RecordRegistrationPage').then((m) => ({\n default: m.RecordRegistrationPage,\n }))\n);\nconst RegisterPage = lazy(() =>\n import('./pages/registrations/RegisterPage').then((m) => ({ default: m.RegisterPage }))\n);\nconst MyRegistrationsPage = lazy(() =>\n import('./pages/registrations/MyRegistrationsPage').then((m) => ({\n default: m.MyRegistrationsPage,\n }))\n);\n\n// Club control room — multi-squad oversight analytics (BOFF-5863)\nconst ClubControlPage = lazy(() =>\n import('./pages/control/ClubControlPage').then((m) => ({ default: m.ClubControlPage }))\n);\n\n// Audit log — canonical, exportable activity trail (BOFF-5863)\nconst AuditLogPage = lazy(() =>\n import('./pages/audit/AuditLogPage').then((m) => ({ default: m.AuditLogPage }))\n);\n\nconst PageLoader: FC = () => (\n <div className=\"flex min-h-[400px] items-center justify-center\">\n <Loader2 className=\"h-8 w-8 animate-spin text-text-secondary\" />\n </div>\n);\n\nexport const AthleteBridgeRoutes: FC = () => {\n const { basePath, isStandalone } = useAthleteBridge();\n const location = useLocation();\n\n const normalizedBasePath = basePath === '/' ? '' : (basePath ?? '').replace(/\\/$/, '');\n\n // Guard: only render when the path matches basePath (integrated mode).\n if (normalizedBasePath && !isStandalone) {\n const pathMatches =\n location.pathname === normalizedBasePath ||\n location.pathname.startsWith(normalizedBasePath + '/');\n if (!pathMatches) {\n return null;\n }\n }\n\n return (\n <div className=\"flex min-h-full flex-col\">\n <Suspense fallback={<PageLoader />}>\n <RouteAnalytics />\n <Routes>\n {/* Dashboard */}\n <Route index element={<DashboardPage />} />\n\n {/*\n Onboarding — the first-run wizard. Intentionally NOT behind a\n FeatureGate: it only collects sport/team/role and writes through the\n same `athCreateTeam` / `athAddMember` the gated Teams pages use, so a\n flag here would gate nothing that `atheletebridge.teams.enabled` does\n not already gate at the destination.\n */}\n <Route path=\"onboarding\" element={<OnboardingPage />} />\n\n {/* Teams */}\n <Route\n path=\"teams\"\n element={\n <FeatureGate flag=\"atheletebridge.teams.enabled\" defaultValue={true}>\n <TeamsListPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"teams/new\"\n element={\n <FeatureGate flag=\"atheletebridge.teams.enabled\" defaultValue={true}>\n <TeamFormPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"teams/:id\"\n element={\n <FeatureGate flag=\"atheletebridge.teams.enabled\" defaultValue={true}>\n <TeamDetailPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"teams/:id/edit\"\n element={\n <FeatureGate flag=\"atheletebridge.teams.enabled\" defaultValue={true}>\n <TeamFormPage />\n </FeatureGate>\n }\n />\n\n {/* Athlete profile (reached from a team roster) */}\n <Route\n path=\"teams/:teamId/athletes/:memberId\"\n element={\n <FeatureGate flag=\"atheletebridge.teams.enabled\" defaultValue={true}>\n <AthleteProfilePage />\n </FeatureGate>\n }\n />\n\n {/* Fixtures */}\n <Route\n path=\"fixtures\"\n element={\n <FeatureGate flag=\"atheletebridge.fixtures.enabled\" defaultValue={true}>\n <FixturesListPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"fixtures/new\"\n element={\n <FeatureGate flag=\"atheletebridge.fixtures.enabled\" defaultValue={true}>\n <FixtureFormPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"fixtures/:id\"\n element={\n <FeatureGate flag=\"atheletebridge.fixtures.enabled\" defaultValue={true}>\n <FixtureDetailPage />\n </FeatureGate>\n }\n />\n\n {/* Club registration & payments (BOFF-4135) */}\n <Route\n path=\"registrations\"\n element={\n <FeatureGate flag=\"atheletebridge.registrations.enabled\" defaultValue={true}>\n <RegistrationFormsListPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"registrations/new\"\n element={\n <FeatureGate flag=\"atheletebridge.registrations.enabled\" defaultValue={true}>\n <RegistrationFormBuilderPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"registrations/:id\"\n element={\n <FeatureGate flag=\"atheletebridge.registrations.enabled\" defaultValue={true}>\n <RegistrationFormDetailPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"registrations/:id/edit\"\n element={\n <FeatureGate flag=\"atheletebridge.registrations.enabled\" defaultValue={true}>\n <RegistrationFormBuilderPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"registrations/:id/record\"\n element={\n <FeatureGate flag=\"atheletebridge.registrations.enabled\" defaultValue={true}>\n <RecordRegistrationPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"registrations/:id/submissions/:submissionId\"\n element={\n <FeatureGate flag=\"atheletebridge.registrations.enabled\" defaultValue={true}>\n <RegistrationSubmissionPage />\n </FeatureGate>\n }\n />\n {/*\n Family-facing share link + \"my registrations\": self-scoped at the\n gateway (any signed-in user), so deliberately not behind the staff\n feature flag — a club's published link must keep working.\n */}\n <Route path=\"register/:slug\" element={<RegisterPage />} />\n <Route path=\"my-registrations\" element={<MyRegistrationsPage />} />\n\n {/* Club control room (BOFF-5863) */}\n <Route\n path=\"control-room\"\n element={\n <FeatureGate flag=\"atheletebridge.control-room.enabled\" defaultValue={true}>\n <ClubControlPage />\n </FeatureGate>\n }\n />\n\n {/* Audit log (BOFF-5863) */}\n <Route\n path=\"audit\"\n element={\n <FeatureGate flag=\"atheletebridge.audit.enabled\" defaultValue={true}>\n <AuditLogPage />\n </FeatureGate>\n }\n />\n\n {/* Standings */}\n <Route\n path=\"standings\"\n element={\n <FeatureGate flag=\"atheletebridge.standings.enabled\" defaultValue={true}>\n <StandingsPage />\n </FeatureGate>\n }\n />\n\n {/* Programs */}\n <Route\n path=\"programs\"\n element={\n <FeatureGate flag=\"atheletebridge.programs.enabled\" defaultValue={true}>\n <ProgramsListPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"programs/new\"\n element={\n <FeatureGate flag=\"atheletebridge.programs.enabled\" defaultValue={true}>\n <ProgramFormPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"programs/:id\"\n element={\n <FeatureGate flag=\"atheletebridge.programs.enabled\" defaultValue={true}>\n <ProgramDetailPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"programs/:id/edit\"\n element={\n <FeatureGate flag=\"atheletebridge.programs.enabled\" defaultValue={true}>\n <ProgramFormPage />\n </FeatureGate>\n }\n />\n\n {/* Sessions */}\n <Route\n path=\"sessions\"\n element={\n <FeatureGate flag=\"atheletebridge.sessions.enabled\" defaultValue={true}>\n <SessionsListPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"sessions/calendar\"\n element={\n <FeatureGate flag=\"atheletebridge.sessions.enabled\" defaultValue={true}>\n <SessionsCalendarPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"sessions/new\"\n element={\n <FeatureGate flag=\"atheletebridge.sessions.enabled\" defaultValue={true}>\n <SessionFormPage />\n </FeatureGate>\n }\n />\n <Route\n path=\"sessions/:id\"\n element={\n <FeatureGate flag=\"atheletebridge.sessions.enabled\" defaultValue={true}>\n <SessionDetailPage />\n </FeatureGate>\n }\n />\n\n {/* Performance */}\n <Route\n path=\"performance\"\n element={\n <FeatureGate flag=\"atheletebridge.performance.enabled\" defaultValue={true}>\n <PerformancePage />\n </FeatureGate>\n }\n />\n\n {/* Analytics */}\n <Route\n path=\"analytics\"\n element={\n <FeatureGate flag=\"atheletebridge.analytics.enabled\" defaultValue={true}>\n <CoachAnalyticsPage />\n </FeatureGate>\n }\n />\n\n {/* AI operations */}\n <Route\n path=\"ai\"\n element={\n <FeatureGate flag=\"atheletebridge.ai.enabled\" defaultValue={true}>\n <AiOperationsPage />\n </FeatureGate>\n }\n />\n\n {/* Tournaments (esports bracket) */}\n <Route\n path=\"tournaments\"\n element={\n <FeatureGate flag=\"atheletebridge.tournaments.enabled\" defaultValue={true}>\n <TournamentBracketPage />\n </FeatureGate>\n }\n />\n\n {/* Fallback */}\n <Route path=\"*\" element={<Navigate to=\".\" replace />} />\n </Routes>\n </Suspense>\n </div>\n );\n};\n"],"mappings":";;;;;;;;;AAmBA,IAAMA,IAAiBC,QACrB,OAAO,uCAAoC,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,eAAe,EAAE,CACzF,GAGMC,IAAgBF,QACpB,OAAO,iCAA8B,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,cAAc,EAAE,CAClF,GACME,IAAiBH,QACrB,OAAO,kCAA+B,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,eAAe,EAAE,CACpF,GACMG,IAAeJ,QACnB,OAAO,gCAA6B,CAAC,MAAM,OAAO,EAAE,SAASC,EAAE,aAAa,EAAE,CAChF,GAGMI,IAAmBL,QACvB,OAAO,uCAAoC,CA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A;KAAS,CAAA;IAAI,CAAA;GACjD,EAAA,CAAA,CACA;;CACP,CAAA;AAET"}
|
|
@@ -14,6 +14,14 @@ var r = {
|
|
|
14
14
|
"confirmed",
|
|
15
15
|
"in_progress"
|
|
16
16
|
]), a = {
|
|
17
|
+
create: "info",
|
|
18
|
+
update: "secondary",
|
|
19
|
+
delete: "destructive",
|
|
20
|
+
execute: "info",
|
|
21
|
+
export: "info",
|
|
22
|
+
check_in: "success",
|
|
23
|
+
check_out: "warning",
|
|
24
|
+
restore: "success",
|
|
17
25
|
forming: "warning",
|
|
18
26
|
active: "success",
|
|
19
27
|
inactive: "secondary",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StatusBadge.js","names":["variantStyles","liveStatuses","statusVariantMap","formatStatusLabel","status","char","StatusBadge","variantOverride","key","variant","isLive","cn","className"],"sources":["../../../src/atheletebridge/components/StatusBadge.tsx"],"sourcesContent":["/**\n * Status Badge Component\n * @module atheletebridge/components\n *\n * A colored badge based on a domain status value, with semantic-token color\n * mapping for the AthleteBridge lifecycle states (teams, members, fixtures,\n * programs, sessions, workouts). Uses semantic tokens only — never raw colors.\n */\n\nimport type { FC } from 'react';\nimport { cn } from '../utils/cn';\n\ntype BadgeVariant = 'success' | 'warning' | 'destructive' | 'secondary' | 'info' | 'outline';\n\ninterface StatusBadgeProps {\n status: string;\n /**\n * Force a specific variant, overriding the auto status→color mapping. Useful\n * where the same status string reads differently by context (e.g. a cancelled\n * coaching session shown grey rather than the default destructive red).\n */\n variant?: BadgeVariant;\n className?: string;\n}\n\nconst variantStyles: Record<BadgeVariant, string> = {\n success: 'bg-status-success-bg-subtle text-status-success-text',\n warning: 'bg-status-warning-bg-subtle text-status-warning-text',\n destructive: 'bg-status-error-bg-subtle text-status-error-text',\n secondary: 'bg-bg-sunken text-text-secondary',\n info: 'bg-[var(--color-accent-soft)] text-text-primary',\n outline: 'border border-border-seam text-text-primary',\n};\n\n// Statuses that represent a \"live\" / in-progress condition get a subtle,\n// opacity-only glow pulse (reduced-motion safe via motion-safe:).\nconst liveStatuses = new Set(['live', 'active', 'confirmed', 'in_progress']);\n\nconst statusVariantMap: Record<string, BadgeVariant> = {\n // Team status\n forming: 'warning',\n active: 'success',\n inactive: 'secondary',\n archived: 'secondary',\n\n // Member status\n trial: 'info',\n injured: 'warning',\n suspended: 'destructive',\n released: 'secondary',\n\n // Fixture status\n scheduled: 'info',\n live: 'success',\n completed: 'success',\n postponed: 'warning',\n cancelled: 'destructive',\n\n // Program status\n draft: 'secondary',\n published: 'success',\n\n // Session status\n requested: 'warning',\n confirmed: 'info',\n no_show: 'destructive',\n\n // Workout status\n planned: 'info',\n skipped: 'secondary',\n\n // AI agent-run status (AthAgentRunStatus). A failed run must never read as a\n // neutral grey chip — an invisible failure is how the last outage stayed\n // unnoticed for months.\n succeeded: 'success',\n failed: 'destructive',\n\n // Registration forms / submissions / payments (BOFF-4135). `draft`,\n // `published` and `archived` are shared with the program lifecycle above.\n closed: 'secondary',\n submitted: 'info',\n accepted: 'success',\n declined: 'destructive',\n withdrawn: 'secondary',\n not_required: 'secondary',\n unpaid: 'warning',\n partially_paid: 'warning',\n paid: 'success',\n refunded: 'secondary',\n recorded: 'success',\n voided: 'secondary',\n};\n\nfunction formatStatusLabel(status: string): string {\n return status\n .replace(/_/g, ' ')\n .toLowerCase()\n .replace(/\\b\\w/g, (char) => char.toUpperCase());\n}\n\nexport const StatusBadge: FC<StatusBadgeProps> = ({\n status,\n variant: variantOverride,\n className,\n}) => {\n const key = status.toLowerCase();\n const variant = variantOverride ?? statusVariantMap[key] ?? 'secondary';\n const isLive = liveStatuses.has(key);\n\n return (\n <span\n className={cn(\n 'inline-flex items-center gap-1.5 rounded-full px-2.5 py-0.5 text-xs font-medium',\n variantStyles[variant],\n className\n )}\n >\n {isLive && (\n <span\n aria-hidden=\"true\"\n className=\"size-1.5 rounded-full bg-current motion-safe:animate-vc-glow-pulse\"\n />\n )}\n {formatStatusLabel(status)}\n </span>\n );\n};\n"],"mappings":";;;AAyBA,IAAMA,IAA8C;CAClD,SAAS;CACT,SAAS;CACT,aAAa;CACb,WAAW;CACX,MAAM;CACN,SAAS;AACX,GAIMC,oBAAe,IAAI,IAAI;CAAC;CAAQ;CAAU;CAAa;AAAa,CAAC,GAErEC,IAAiD;CAErD,SAAS;CACT,QAAQ;CACR,UAAU;CACV,UAAU;CAGV,OAAO;CACP,SAAS;CACT,WAAW;CACX,UAAU;CAGV,WAAW;CACX,MAAM;CACN,WAAW;CACX,WAAW;CACX,WAAW;CAGX,OAAO;CACP,WAAW;CAGX,WAAW;CACX,WAAW;CACX,SAAS;CAGT,SAAS;CACT,SAAS;CAKT,WAAW;CACX,QAAQ;CAIR,QAAQ;CACR,WAAW;CACX,UAAU;CACV,UAAU;CACV,WAAW;CACX,cAAc;CACd,QAAQ;CACR,gBAAgB;CAChB,MAAM;CACN,UAAU;CACV,UAAU;CACV,QAAQ;AACV;AAEA,SAASC,EAAkB,GAAwB;CACjD,OAAOC,EACJ,QAAQ,MAAM,GAAG,CAAC,CAClB,YAAY,CAAC,CACb,QAAQ,UAAU,MAASC,EAAK,YAAY,CAAC;AAClD;AAEA,IAAaC,KAAqC,EAChD,WACA,SAASC,GACT,mBACI;CACJ,IAAMC,IAAMJ,EAAO,YAAY,GACzBK,IAAUF,KAAmBL,EAAiBM,MAAQ,aACtDE,IAAST,EAAa,IAAIO,CAAG;CAEnC,OACE,kBAAC,QAAD;EACE,WAAWG,EACT,mFACAX,EAAcS,IACdG,CACF;EALF,UAAA,CAOGF,KACC,kBAAC,QAAD;GACE,eAAY;GACZ,WAAU;EACX,CAAA,GAEFP,EAAkBC,CAAM,CACrB;;AAEV"}
|
|
1
|
+
{"version":3,"file":"StatusBadge.js","names":["variantStyles","liveStatuses","statusVariantMap","formatStatusLabel","status","char","StatusBadge","variantOverride","key","variant","isLive","cn","className"],"sources":["../../../src/atheletebridge/components/StatusBadge.tsx"],"sourcesContent":["/**\n * Status Badge Component\n * @module atheletebridge/components\n *\n * A colored badge based on a domain status value, with semantic-token color\n * mapping for the AthleteBridge lifecycle states (teams, members, fixtures,\n * programs, sessions, workouts). Uses semantic tokens only — never raw colors.\n */\n\nimport type { FC } from 'react';\nimport { cn } from '../utils/cn';\n\ntype BadgeVariant = 'success' | 'warning' | 'destructive' | 'secondary' | 'info' | 'outline';\n\ninterface StatusBadgeProps {\n status: string;\n /**\n * Force a specific variant, overriding the auto status→color mapping. Useful\n * where the same status string reads differently by context (e.g. a cancelled\n * coaching session shown grey rather than the default destructive red).\n */\n variant?: BadgeVariant;\n className?: string;\n}\n\nconst variantStyles: Record<BadgeVariant, string> = {\n success: 'bg-status-success-bg-subtle text-status-success-text',\n warning: 'bg-status-warning-bg-subtle text-status-warning-text',\n destructive: 'bg-status-error-bg-subtle text-status-error-text',\n secondary: 'bg-bg-sunken text-text-secondary',\n info: 'bg-[var(--color-accent-soft)] text-text-primary',\n outline: 'border border-border-seam text-text-primary',\n};\n\n// Statuses that represent a \"live\" / in-progress condition get a subtle,\n// opacity-only glow pulse (reduced-motion safe via motion-safe:).\nconst liveStatuses = new Set(['live', 'active', 'confirmed', 'in_progress']);\n\nconst statusVariantMap: Record<string, BadgeVariant> = {\n // Audit actions (BOFF-5863)\n create: 'info',\n update: 'secondary',\n delete: 'destructive',\n execute: 'info',\n export: 'info',\n check_in: 'success',\n check_out: 'warning',\n restore: 'success',\n\n // Team status\n forming: 'warning',\n active: 'success',\n inactive: 'secondary',\n archived: 'secondary',\n\n // Member status\n trial: 'info',\n injured: 'warning',\n suspended: 'destructive',\n released: 'secondary',\n\n // Fixture status\n scheduled: 'info',\n live: 'success',\n completed: 'success',\n postponed: 'warning',\n cancelled: 'destructive',\n\n // Program status\n draft: 'secondary',\n published: 'success',\n\n // Session status\n requested: 'warning',\n confirmed: 'info',\n no_show: 'destructive',\n\n // Workout status\n planned: 'info',\n skipped: 'secondary',\n\n // AI agent-run status (AthAgentRunStatus). A failed run must never read as a\n // neutral grey chip — an invisible failure is how the last outage stayed\n // unnoticed for months.\n succeeded: 'success',\n failed: 'destructive',\n\n // Registration forms / submissions / payments (BOFF-4135). `draft`,\n // `published` and `archived` are shared with the program lifecycle above.\n closed: 'secondary',\n submitted: 'info',\n accepted: 'success',\n declined: 'destructive',\n withdrawn: 'secondary',\n not_required: 'secondary',\n unpaid: 'warning',\n partially_paid: 'warning',\n paid: 'success',\n refunded: 'secondary',\n recorded: 'success',\n voided: 'secondary',\n};\n\nfunction formatStatusLabel(status: string): string {\n return status\n .replace(/_/g, ' ')\n .toLowerCase()\n .replace(/\\b\\w/g, (char) => char.toUpperCase());\n}\n\nexport const StatusBadge: FC<StatusBadgeProps> = ({\n status,\n variant: variantOverride,\n className,\n}) => {\n const key = status.toLowerCase();\n const variant = variantOverride ?? statusVariantMap[key] ?? 'secondary';\n const isLive = liveStatuses.has(key);\n\n return (\n <span\n className={cn(\n 'inline-flex items-center gap-1.5 rounded-full px-2.5 py-0.5 text-xs font-medium',\n variantStyles[variant],\n className\n )}\n >\n {isLive && (\n <span\n aria-hidden=\"true\"\n className=\"size-1.5 rounded-full bg-current motion-safe:animate-vc-glow-pulse\"\n />\n )}\n {formatStatusLabel(status)}\n </span>\n );\n};\n"],"mappings":";;;AAyBA,IAAMA,IAA8C;CAClD,SAAS;CACT,SAAS;CACT,aAAa;CACb,WAAW;CACX,MAAM;CACN,SAAS;AACX,GAIMC,oBAAe,IAAI,IAAI;CAAC;CAAQ;CAAU;CAAa;AAAa,CAAC,GAErEC,IAAiD;CAErD,QAAQ;CACR,QAAQ;CACR,QAAQ;CACR,SAAS;CACT,QAAQ;CACR,UAAU;CACV,WAAW;CACX,SAAS;CAGT,SAAS;CACT,QAAQ;CACR,UAAU;CACV,UAAU;CAGV,OAAO;CACP,SAAS;CACT,WAAW;CACX,UAAU;CAGV,WAAW;CACX,MAAM;CACN,WAAW;CACX,WAAW;CACX,WAAW;CAGX,OAAO;CACP,WAAW;CAGX,WAAW;CACX,WAAW;CACX,SAAS;CAGT,SAAS;CACT,SAAS;CAKT,WAAW;CACX,QAAQ;CAIR,QAAQ;CACR,WAAW;CACX,UAAU;CACV,UAAU;CACV,WAAW;CACX,cAAc;CACd,QAAQ;CACR,gBAAgB;CAChB,MAAM;CACN,UAAU;CACV,UAAU;CACV,QAAQ;AACV;AAEA,SAASC,EAAkB,GAAwB;CACjD,OAAOC,EACJ,QAAQ,MAAM,GAAG,CAAC,CAClB,YAAY,CAAC,CACb,QAAQ,UAAU,MAASC,EAAK,YAAY,CAAC;AAClD;AAEA,IAAaC,KAAqC,EAChD,WACA,SAASC,GACT,mBACI;CACJ,IAAMC,IAAMJ,EAAO,YAAY,GACzBK,IAAUF,KAAmBL,EAAiBM,MAAQ,aACtDE,IAAST,EAAa,IAAIO,CAAG;CAEnC,OACE,kBAAC,QAAD;EACE,WAAWG,EACT,mFACAX,EAAcS,IACdG,CACF;EALF,UAAA,CAOGF,KACC,kBAAC,QAAD;GACE,eAAY;GACZ,WAAU;EACX,CAAA,GAEFP,EAAkBC,CAAM,CACrB;;AAEV"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { PaginationInput } from '../types';
|
|
2
|
+
import { AthAuditLogConnection, AthAuditLogExport, AthAuditLogFilter, AthAuditExportFormat } from '../types/audit';
|
|
3
|
+
export declare const useAuditLogs: (filter?: AthAuditLogFilter, pagination?: PaginationInput) => import('@tanstack/react-query').UseQueryResult<AthAuditLogConnection, Error>;
|
|
4
|
+
/**
|
|
5
|
+
* Export the rows matching `filter` as CSV or JSON. Returns the payload the
|
|
6
|
+
* service produced; the page turns it into a download. The export itself is
|
|
7
|
+
* written into the trail by the service.
|
|
8
|
+
*/
|
|
9
|
+
export declare const useExportAuditLogs: () => import('@tanstack/react-query').UseMutationResult<AthAuditLogExport, Error, {
|
|
10
|
+
filter?: AthAuditLogFilter;
|
|
11
|
+
format: AthAuditExportFormat;
|
|
12
|
+
}, unknown>;
|
|
13
|
+
/** Turn an export payload into a client download (no server-side storage). */
|
|
14
|
+
export declare const downloadAuditExport: (payload: AthAuditLogExport) => void;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { useAthleteBridge as e } from "../context/AthleteBridgeContext.js";
|
|
2
|
+
import "../context/index.js";
|
|
3
|
+
import { athQuery as t } from "./useAthleteBridgeApi.js";
|
|
4
|
+
import { useMutation as n, useQuery as r } from "@tanstack/react-query";
|
|
5
|
+
// src/atheletebridge/hooks/useAuditApi.ts
|
|
6
|
+
var i = "\n id workspaceId action resourceType resourceId resourceName description\n status actorId actorType createdAt\n", a = ["atheletebridge", "audit"], o = (n = {}, o) => {
|
|
7
|
+
let { apiGatewayUrl: s, workspaceId: c } = e();
|
|
8
|
+
return r({
|
|
9
|
+
queryKey: [
|
|
10
|
+
...a,
|
|
11
|
+
c ?? null,
|
|
12
|
+
"logs",
|
|
13
|
+
n,
|
|
14
|
+
o ?? null
|
|
15
|
+
],
|
|
16
|
+
queryFn: async () => (await t(`query AthAuditLogs($filter: AthAuditLogFilterInput, $pagination: PaginationInput) {
|
|
17
|
+
athAuditLogs(filter: $filter, pagination: $pagination) {
|
|
18
|
+
items { ${i} }
|
|
19
|
+
pageInfo { cursor hasMore }
|
|
20
|
+
}
|
|
21
|
+
}`, {
|
|
22
|
+
filter: n,
|
|
23
|
+
pagination: o
|
|
24
|
+
}, s)).athAuditLogs
|
|
25
|
+
});
|
|
26
|
+
}, s = () => {
|
|
27
|
+
let { apiGatewayUrl: r } = e();
|
|
28
|
+
return n({ mutationFn: async ({ filter: e, format: n }) => (await t("mutation AthExportAuditLogs($input: AthAuditExportInput!) {\n athExportAuditLogs(input: $input) { data format count generatedAt }\n }", { input: {
|
|
29
|
+
filter: e,
|
|
30
|
+
format: n
|
|
31
|
+
} }, r)).athExportAuditLogs });
|
|
32
|
+
}, c = (e) => {
|
|
33
|
+
let t = e.format === "JSON" ? "application/json" : "text/csv", n = new Blob([e.data], { type: `${t};charset=utf-8` }), r = URL.createObjectURL(n), i = document.createElement("a");
|
|
34
|
+
i.href = r, i.download = `atheletebridge-audit-${e.generatedAt.slice(0, 10)}.${e.format === "JSON" ? "json" : "csv"}`, i.click(), URL.revokeObjectURL(r);
|
|
35
|
+
};
|
|
36
|
+
export { c as downloadAuditExport, o as useAuditLogs, s as useExportAuditLogs };
|
|
37
|
+
|
|
38
|
+
//# sourceMappingURL=useAuditApi.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useAuditApi.js","names":["AUDIT_LOG_FIELDS","ROOT","useAuditLogs","useAthleteBridge","useQuery","workspaceId","filter","pagination","athQuery","apiGatewayUrl","useExportAuditLogs","useMutation","downloadAuditExport","mime","payload","blob","url","anchor"],"sources":["../../../src/atheletebridge/hooks/useAuditApi.ts"],"sourcesContent":["/**\n * Audit trail API hooks (BOFF-5863).\n *\n * react-query wrappers over the `wspace-atheletebridge-svc` audit module.\n * Both hooks are gated by `atheletebridge-audit` at the gateway: reading the\n * trail is staff-level, exporting it is admin-only.\n *\n * @module atheletebridge/hooks/audit\n */\n\nimport { useMutation, useQuery } from '@tanstack/react-query';\n\nimport { useAthleteBridge } from '../context';\nimport type { PaginationInput } from '../types';\nimport type {\n AthAuditLogConnection,\n AthAuditLogExport,\n AthAuditLogFilter,\n AthAuditExportFormat,\n} from '../types/audit';\nimport { athQuery } from './useAthleteBridgeApi';\n\nconst AUDIT_LOG_FIELDS = `\n id workspaceId action resourceType resourceId resourceName description\n status actorId actorType createdAt\n`;\n\nconst ROOT = ['atheletebridge', 'audit'] as const;\n\nexport const useAuditLogs = (filter: AthAuditLogFilter = {}, pagination?: PaginationInput) => {\n const { apiGatewayUrl, workspaceId } = useAthleteBridge();\n return useQuery({\n queryKey: [...ROOT, workspaceId ?? null, 'logs', filter, pagination ?? null],\n queryFn: async () => {\n const result = await athQuery<{ athAuditLogs: AthAuditLogConnection }>(\n `query AthAuditLogs($filter: AthAuditLogFilterInput, $pagination: PaginationInput) {\n athAuditLogs(filter: $filter, pagination: $pagination) {\n items { ${AUDIT_LOG_FIELDS} }\n pageInfo { cursor hasMore }\n }\n }`,\n { filter, pagination },\n apiGatewayUrl\n );\n return result.athAuditLogs;\n },\n });\n};\n\n/**\n * Export the rows matching `filter` as CSV or JSON. Returns the payload the\n * service produced; the page turns it into a download. The export itself is\n * written into the trail by the service.\n */\nexport const useExportAuditLogs = () => {\n const { apiGatewayUrl } = useAthleteBridge();\n return useMutation({\n mutationFn: async ({\n filter,\n format,\n }: {\n filter?: AthAuditLogFilter;\n format: AthAuditExportFormat;\n }) => {\n const result = await athQuery<{ athExportAuditLogs: AthAuditLogExport }>(\n `mutation AthExportAuditLogs($input: AthAuditExportInput!) {\n athExportAuditLogs(input: $input) { data format count generatedAt }\n }`,\n { input: { filter, format } },\n apiGatewayUrl\n );\n return result.athExportAuditLogs;\n },\n });\n};\n\n/** Turn an export payload into a client download (no server-side storage). */\nexport const downloadAuditExport = (payload: AthAuditLogExport): void => {\n const mime = payload.format === 'JSON' ? 'application/json' : 'text/csv';\n const blob = new Blob([payload.data], { type: `${mime};charset=utf-8` });\n const url = URL.createObjectURL(blob);\n const anchor = document.createElement('a');\n anchor.href = url;\n anchor.download = `atheletebridge-audit-${payload.generatedAt.slice(0, 10)}.${payload.format === 'JSON' ? 'json' : 'csv'}`;\n anchor.click();\n URL.revokeObjectURL(url);\n};\n"],"mappings":";;;;;AAsBA,IAAMA,IAAmB,sHAKnBC,IAAO,CAAC,kBAAkB,OAAO,GAE1BC,KAAgB,IAA4B,CAAC,GAAG,MAAiC;CAC5F,IAAM,EAAE,kBAAe,mBAAgBC,EAAiB;CACxD,OAAOC,EAAS;EACd,UAAU;GAAC,GAAGH;GAAMI,KAAe;GAAM;GAAQC;GAAQC,KAAc;EAAI;EAC3E,SAAS,aAWA,MAVcC,EACnB;;sBAEcR,EAAiB;;;YAI/B;GAAE;GAAQ;EAAW,GACrBS,CACF,EAAA,CACc;CAElB,CAAC;AACH,GAOaC,UAA2B;CACtC,IAAM,EAAE,qBAAkBP,EAAiB;CAC3C,OAAOQ,EAAY,EACjB,YAAY,OAAO,EACjB,WACA,iBAYO,MAPcH,EACnB,yJAGA,EAAE,OAAO;EAAE;EAAQ;CAAO,EAAE,GAC5BC,CACF,EAAA,CACc,mBAElB,CAAC;AACH,GAGaG,KAAuB,MAAqC;CACvE,IAAMC,IAAOC,EAAQ,WAAW,SAAS,qBAAqB,YACxDC,IAAO,IAAI,KAAK,CAACD,EAAQ,IAAI,GAAG,EAAE,MAAM,GAAGD,EAAK,gBAAgB,CAAC,GACjEG,IAAM,IAAI,gBAAgBD,CAAI,GAC9BE,IAAS,SAAS,cAAc,GAAG;CAIzC,AAHA,EAAO,OAAOD,GACd,EAAO,WAAW,wBAAwBF,EAAQ,YAAY,MAAM,GAAG,EAAE,EAAE,GAAGA,EAAQ,WAAW,SAAS,SAAS,SACnHG,EAAO,MAAM,GACb,IAAI,gBAAgBD,CAAG;AACzB"}
|
|
@@ -3,6 +3,8 @@ import { AthCreateRegistrationFormInput, AthMyRegistration, AthMyRegistrationCon
|
|
|
3
3
|
export interface RegistrationFormFilters {
|
|
4
4
|
status?: AthRegistrationFormStatus;
|
|
5
5
|
season?: string;
|
|
6
|
+
/** Only forms taking sign-ups for this fixture (BOFF-5863). */
|
|
7
|
+
fixtureId?: string;
|
|
6
8
|
pagination?: PaginationInput;
|
|
7
9
|
}
|
|
8
10
|
export declare const useRegistrationForms: (filters?: RegistrationFormFilters) => import('@tanstack/react-query').UseQueryResult<AthRegistrationFormConnection, Error>;
|
|
@@ -21,6 +23,10 @@ export interface RegistrationSubmissionFilters {
|
|
|
21
23
|
formId?: string;
|
|
22
24
|
status?: AthRegistrationSubmissionStatus;
|
|
23
25
|
paymentStatus?: AthRegistrationPaymentStatus;
|
|
26
|
+
/** Only sign-ups for forms targeting this fixture (BOFF-5863). */
|
|
27
|
+
fixtureId?: string;
|
|
28
|
+
/** Filter by tournament check-in state (BOFF-5863). */
|
|
29
|
+
checkedIn?: boolean;
|
|
24
30
|
pagination?: PaginationInput;
|
|
25
31
|
}
|
|
26
32
|
export declare const useRegistrationSubmissions: (filters: RegistrationSubmissionFilters, enabled?: boolean) => import('@tanstack/react-query').UseQueryResult<AthRegistrationSubmissionConnection, Error>;
|
|
@@ -31,6 +37,15 @@ export declare const useReviewRegistration: () => import('@tanstack/react-query'
|
|
|
31
37
|
decision: AthRegistrationDecision;
|
|
32
38
|
notes?: string;
|
|
33
39
|
}, unknown>;
|
|
40
|
+
/**
|
|
41
|
+
* Check an accepted sign-up in at the fixture, or undo a check-in. Both
|
|
42
|
+
* mutations return the refreshed submission; `checkedIn` picks which one runs.
|
|
43
|
+
* The service is idempotent, so a double-tap is a re-read, never a duplicate.
|
|
44
|
+
*/
|
|
45
|
+
export declare const useRegistrationCheckIn: () => import('@tanstack/react-query').UseMutationResult<AthRegistrationSubmission, Error, {
|
|
46
|
+
id: string;
|
|
47
|
+
checkedIn: boolean;
|
|
48
|
+
}, unknown>;
|
|
34
49
|
export declare const useRegistrationPayments: (submissionId: string | undefined) => import('@tanstack/react-query').UseQueryResult<AthRegistrationPayment[], Error>;
|
|
35
50
|
export declare const useRegistrationPaymentSummary: (formId?: string) => import('@tanstack/react-query').UseQueryResult<AthRegistrationPaymentSummary, Error>;
|
|
36
51
|
export declare const useRecordRegistrationPayment: () => import('@tanstack/react-query').UseMutationResult<AthRegistrationPayment, Error, AthRecordRegistrationPaymentInput, unknown>;
|
|
@@ -4,12 +4,13 @@ import { athQuery as t } from "./useAthleteBridgeApi.js";
|
|
|
4
4
|
import { useMutation as n, useQuery as r, useQueryClient as i } from "@tanstack/react-query";
|
|
5
5
|
// src/atheletebridge/hooks/useRegistrationApi.ts
|
|
6
6
|
var a = ["atheletebridge", "registration"], o = "id key label fieldType required options helpText position", s = "id name description amount feeType position", c = `
|
|
7
|
-
id workspaceId title description season teamId programId slug status currency
|
|
7
|
+
id workspaceId title description season teamId programId fixtureId slug status currency
|
|
8
8
|
opensAt closesAt maxSubmissions waiverText publishedAt closedAt isOpen
|
|
9
9
|
submissionCount createdAt updatedAt
|
|
10
|
+
fixture { id competition type status scheduledAt venue }
|
|
10
11
|
fields { ${o} }
|
|
11
12
|
fees { ${s} }
|
|
12
|
-
`, l = "\n id workspaceId formId formTitle source submittedByUserId participantName\n participantUserId contactName contactEmail contactPhone answers selectedFeeIds\n status paymentStatus amountDue amountPaid amountOutstanding currency\n waiverAcceptedAt reviewNotes reviewedAt submittedAt createdAt updatedAt\n participantIsRegistrant rosterOutcome rosterMemberId rosterTeamId rosterTeamName\n", u = "\n id submissionId amount refundedAmount netAmount currency method processor status\n reference note receivedAt voidedAt voidReason refundedAt refundReason\n createdBy createdAt\n", d = "\n formId submissionCount acceptedCount notRequiredCount unpaidCount\n partiallyPaidCount paidCount refundedCount\n totals { currency amountDue amountCollected amountRefunded amountOutstanding }\n", f = `
|
|
13
|
+
`, l = "\n id workspaceId formId formTitle source submittedByUserId participantName\n participantUserId contactName contactEmail contactPhone answers selectedFeeIds\n status paymentStatus amountDue amountPaid amountOutstanding currency\n waiverAcceptedAt reviewNotes reviewedAt submittedAt createdAt updatedAt\n participantIsRegistrant rosterOutcome rosterMemberId rosterTeamId rosterTeamName\n checkInStatus checkedInAt checkedInBy\n", u = "\n id submissionId amount refundedAmount netAmount currency method processor status\n reference note receivedAt voidedAt voidReason refundedAt refundReason\n createdBy createdAt\n", d = "\n formId submissionCount acceptedCount notRequiredCount unpaidCount\n partiallyPaidCount paidCount refundedCount\n totals { currency amountDue amountCollected amountRefunded amountOutstanding }\n", f = `
|
|
13
14
|
id slug title description season currency opensAt closesAt waiverText isOpen
|
|
14
15
|
spotsRemaining
|
|
15
16
|
fields { ${o} }
|
|
@@ -26,8 +27,13 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
26
27
|
"forms",
|
|
27
28
|
n
|
|
28
29
|
],
|
|
29
|
-
queryFn: async () => (await t(`query AthListRegistrationForms(
|
|
30
|
-
|
|
30
|
+
queryFn: async () => (await t(`query AthListRegistrationForms(
|
|
31
|
+
$status: AthRegistrationFormStatus
|
|
32
|
+
$season: String
|
|
33
|
+
$fixtureId: ID
|
|
34
|
+
$pagination: PaginationInput
|
|
35
|
+
) {
|
|
36
|
+
athListRegistrationForms(status: $status, season: $season, fixtureId: $fixtureId, pagination: $pagination) {
|
|
31
37
|
items { ${c} }
|
|
32
38
|
pageInfo { cursor hasMore }
|
|
33
39
|
}
|
|
@@ -99,12 +105,16 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
99
105
|
$formId: ID
|
|
100
106
|
$status: AthRegistrationSubmissionStatus
|
|
101
107
|
$paymentStatus: AthRegistrationPaymentStatus
|
|
108
|
+
$fixtureId: ID
|
|
109
|
+
$checkedIn: Boolean
|
|
102
110
|
$pagination: PaginationInput
|
|
103
111
|
) {
|
|
104
112
|
athListRegistrationSubmissions(
|
|
105
113
|
formId: $formId
|
|
106
114
|
status: $status
|
|
107
115
|
paymentStatus: $paymentStatus
|
|
116
|
+
fixtureId: $fixtureId
|
|
117
|
+
checkedIn: $checkedIn
|
|
108
118
|
pagination: $pagination
|
|
109
119
|
) {
|
|
110
120
|
items { ${l} }
|
|
@@ -149,7 +159,16 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
149
159
|
}, r)).athReviewRegistrationSubmission,
|
|
150
160
|
onSuccess: () => void i()
|
|
151
161
|
});
|
|
152
|
-
}, E = (
|
|
162
|
+
}, E = () => {
|
|
163
|
+
let { apiGatewayUrl: r } = e(), i = h();
|
|
164
|
+
return n({
|
|
165
|
+
mutationFn: async ({ id: e, checkedIn: n }) => {
|
|
166
|
+
let i = n ? "athCheckInRegistration" : "athUndoRegistrationCheckIn";
|
|
167
|
+
return (await t(`mutation AthRegistrationCheckIn($id: ID!) { ${i}(id: $id) { ${l} } }`, { id: e }, r))[i];
|
|
168
|
+
},
|
|
169
|
+
onSuccess: () => void i()
|
|
170
|
+
});
|
|
171
|
+
}, D = (n) => {
|
|
153
172
|
let { apiGatewayUrl: i, workspaceId: o } = e();
|
|
154
173
|
return r({
|
|
155
174
|
queryKey: [
|
|
@@ -164,7 +183,7 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
164
183
|
enabled: !!n,
|
|
165
184
|
retry: !1
|
|
166
185
|
});
|
|
167
|
-
},
|
|
186
|
+
}, O = (n) => {
|
|
168
187
|
let { apiGatewayUrl: i, workspaceId: o } = e();
|
|
169
188
|
return r({
|
|
170
189
|
queryKey: [
|
|
@@ -178,7 +197,7 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
178
197
|
}`, { formId: n ?? null }, i)).athRegistrationPaymentSummary,
|
|
179
198
|
retry: !1
|
|
180
199
|
});
|
|
181
|
-
},
|
|
200
|
+
}, k = () => {
|
|
182
201
|
let { apiGatewayUrl: r } = e(), i = h();
|
|
183
202
|
return n({
|
|
184
203
|
mutationFn: async (e) => (await t(`mutation AthRecordRegistrationPayment($input: AthRecordRegistrationPaymentInput!) {
|
|
@@ -186,7 +205,7 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
186
205
|
}`, { input: e }, r)).athRecordRegistrationPayment,
|
|
187
206
|
onSuccess: () => void i()
|
|
188
207
|
});
|
|
189
|
-
},
|
|
208
|
+
}, A = () => {
|
|
190
209
|
let { apiGatewayUrl: r } = e(), i = h();
|
|
191
210
|
return n({
|
|
192
211
|
mutationFn: async ({ id: e, reason: n }) => (await t(`mutation AthVoidRegistrationPayment($id: ID!, $reason: String!) {
|
|
@@ -197,7 +216,7 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
197
216
|
}, r)).athVoidRegistrationPayment,
|
|
198
217
|
onSuccess: () => void i()
|
|
199
218
|
});
|
|
200
|
-
},
|
|
219
|
+
}, j = () => {
|
|
201
220
|
let { apiGatewayUrl: r } = e(), i = h();
|
|
202
221
|
return n({
|
|
203
222
|
mutationFn: async ({ id: e, amount: n, reason: i }) => (await t(`mutation AthRefundRegistrationPayment($id: ID!, $input: AthRefundRegistrationPaymentInput!) {
|
|
@@ -211,7 +230,7 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
211
230
|
}, r)).athRefundRegistrationPayment,
|
|
212
231
|
onSuccess: () => void i()
|
|
213
232
|
});
|
|
214
|
-
},
|
|
233
|
+
}, M = () => {
|
|
215
234
|
let { apiGatewayUrl: n, workspaceId: i } = e();
|
|
216
235
|
return r({
|
|
217
236
|
queryKey: [
|
|
@@ -227,7 +246,7 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
227
246
|
}`, {}, n)).athOnlinePaymentsStatus,
|
|
228
247
|
retry: !1
|
|
229
248
|
});
|
|
230
|
-
},
|
|
249
|
+
}, N = () => {
|
|
231
250
|
let { apiGatewayUrl: r } = e();
|
|
232
251
|
return n({ mutationFn: async (e) => (await t(`mutation AthConnectPaymentAccount($input: AthConnectPaymentAccountInput!) {
|
|
233
252
|
athConnectPaymentAccount(input: $input) {
|
|
@@ -235,7 +254,7 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
235
254
|
account { ${m} }
|
|
236
255
|
}
|
|
237
256
|
}`, { input: e }, r)).athConnectPaymentAccount });
|
|
238
|
-
},
|
|
257
|
+
}, P = () => {
|
|
239
258
|
let { apiGatewayUrl: r } = e(), i = h();
|
|
240
259
|
return n({
|
|
241
260
|
mutationFn: async () => (await t(`mutation AthRefreshPaymentAccount {
|
|
@@ -243,7 +262,7 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
243
262
|
}`, {}, r)).athRefreshPaymentAccount,
|
|
244
263
|
onSuccess: () => void i()
|
|
245
264
|
});
|
|
246
|
-
},
|
|
265
|
+
}, F = (n) => {
|
|
247
266
|
let { apiGatewayUrl: i } = e();
|
|
248
267
|
return r({
|
|
249
268
|
queryKey: [
|
|
@@ -256,7 +275,7 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
256
275
|
}`, { slug: n }, i)).athRegistrationFormBySlug,
|
|
257
276
|
enabled: !!n
|
|
258
277
|
});
|
|
259
|
-
},
|
|
278
|
+
}, I = () => {
|
|
260
279
|
let { apiGatewayUrl: r } = e(), i = h();
|
|
261
280
|
return n({
|
|
262
281
|
mutationFn: async ({ slug: e, input: n }) => (await t(`mutation AthSubmitRegistration($slug: String!, $input: AthSubmitRegistrationInput!) {
|
|
@@ -267,7 +286,7 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
267
286
|
}, r)).athSubmitRegistration,
|
|
268
287
|
onSuccess: () => void i()
|
|
269
288
|
});
|
|
270
|
-
},
|
|
289
|
+
}, L = (n) => {
|
|
271
290
|
let { apiGatewayUrl: i } = e();
|
|
272
291
|
return r({
|
|
273
292
|
queryKey: [
|
|
@@ -282,7 +301,7 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
282
301
|
}
|
|
283
302
|
}`, { pagination: n ?? null }, i)).athMyRegistrations
|
|
284
303
|
});
|
|
285
|
-
},
|
|
304
|
+
}, R = () => {
|
|
286
305
|
let { apiGatewayUrl: r } = e(), i = h();
|
|
287
306
|
return n({
|
|
288
307
|
mutationFn: async (e) => (await t(`mutation AthWithdrawMyRegistration($id: ID!) {
|
|
@@ -290,10 +309,10 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
290
309
|
}`, { id: e }, r)).athWithdrawMyRegistration,
|
|
291
310
|
onSuccess: () => void i()
|
|
292
311
|
});
|
|
293
|
-
},
|
|
312
|
+
}, z = () => {
|
|
294
313
|
let { apiGatewayUrl: r } = e();
|
|
295
314
|
return n({ mutationFn: async (e) => (await t("mutation AthStartRegistrationCheckout($input: AthStartRegistrationCheckoutInput!) {\n athStartRegistrationCheckout(input: $input) { checkoutId url amount currency expiresAt }\n }", { input: e }, r)).athStartRegistrationCheckout });
|
|
296
|
-
},
|
|
315
|
+
}, B = () => {
|
|
297
316
|
let { apiGatewayUrl: r } = e(), i = h();
|
|
298
317
|
return n({
|
|
299
318
|
mutationFn: async (e) => (await t(`mutation AthConfirmRegistrationCheckout($checkoutId: ID!) {
|
|
@@ -302,6 +321,6 @@ var a = ["atheletebridge", "registration"], o = "id key label fieldType required
|
|
|
302
321
|
onSuccess: () => void i()
|
|
303
322
|
});
|
|
304
323
|
};
|
|
305
|
-
export {
|
|
324
|
+
export { B as useConfirmRegistrationCheckout, N as useConnectPaymentAccount, v as useCreateRegistrationForm, L as useMyRegistrations, M as useOnlinePaymentsStatus, F as usePublicRegistrationForm, w as useRecordRegistration, k as useRecordRegistrationPayment, P as useRefreshPaymentAccount, j as useRefundRegistrationPayment, E as useRegistrationCheckIn, _ as useRegistrationForm, x as useRegistrationFormLifecycle, g as useRegistrationForms, O as useRegistrationPaymentSummary, D as useRegistrationPayments, C as useRegistrationSubmission, S as useRegistrationSubmissions, T as useReviewRegistration, z as useStartRegistrationCheckout, I as useSubmitRegistration, y as useUpdateRegistrationForm, A as useVoidRegistrationPayment, R as useWithdrawMyRegistration };
|
|
306
325
|
|
|
307
326
|
//# sourceMappingURL=useRegistrationApi.js.map
|