@burdenoff/microfe-technospam 2026.1024.1 → 2026.1030.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.
Files changed (54) hide show
  1. package/dist/node_modules/recharts/es6/cartesian/Brush.js.map +1 -1
  2. package/dist/node_modules/recharts/es6/cartesian/ErrorBar.js.map +1 -1
  3. package/dist/node_modules/recharts/es6/cartesian/ReferenceArea.js.map +1 -1
  4. package/dist/node_modules/recharts/es6/cartesian/ReferenceDot.js.map +1 -1
  5. package/dist/node_modules/recharts/es6/cartesian/ReferenceLine.js.map +1 -1
  6. package/dist/node_modules/recharts/es6/cartesian/XAxis.js.map +1 -1
  7. package/dist/node_modules/recharts/es6/cartesian/YAxis.js.map +1 -1
  8. package/dist/node_modules/recharts/es6/component/ResponsiveContainer.js.map +1 -1
  9. package/dist/node_modules/sonner/dist/index.js.map +1 -1
  10. package/dist/technospam/api/technospamApi.d.ts +28 -0
  11. package/dist/technospam/api/technospamApi.d.ts.map +1 -1
  12. package/dist/technospam/api/technospamApi.js +193 -153
  13. package/dist/technospam/api/technospamApi.js.map +1 -1
  14. package/dist/technospam/components/SubmissionReviewPanel.d.ts +15 -0
  15. package/dist/technospam/components/SubmissionReviewPanel.d.ts.map +1 -0
  16. package/dist/technospam/components/SubmissionReviewPanel.js +85 -0
  17. package/dist/technospam/components/SubmissionReviewPanel.js.map +1 -0
  18. package/dist/technospam/components/index.d.ts +1 -0
  19. package/dist/technospam/components/index.d.ts.map +1 -1
  20. package/dist/technospam/components/index.js +1 -0
  21. package/dist/technospam/hooks/useFocusedRecordParam.d.ts +41 -0
  22. package/dist/technospam/hooks/useFocusedRecordParam.d.ts.map +1 -0
  23. package/dist/technospam/hooks/useFocusedRecordParam.js +41 -0
  24. package/dist/technospam/hooks/useFocusedRecordParam.js.map +1 -0
  25. package/dist/technospam/pages/AdminAdminDashboardPagePage.js +1 -1
  26. package/dist/technospam/pages/AnalyticsAnalyticsPagePage.js +1 -1
  27. package/dist/technospam/pages/ApplicationsPortfolioPagePage.js +1 -1
  28. package/dist/technospam/pages/ApplicationsProblemDetailsPagePage.d.ts.map +1 -1
  29. package/dist/technospam/pages/ApplicationsProblemDetailsPagePage.js +190 -165
  30. package/dist/technospam/pages/ApplicationsProblemDetailsPagePage.js.map +1 -1
  31. package/dist/technospam/pages/ApplicationsProblemsPagePage.js +1 -1
  32. package/dist/technospam/pages/CoursesCourseDetailsPagePage.d.ts.map +1 -1
  33. package/dist/technospam/pages/CoursesCourseDetailsPagePage.js +92 -88
  34. package/dist/technospam/pages/CoursesCourseDetailsPagePage.js.map +1 -1
  35. package/dist/technospam/pages/CoursesCoursesPagePage.js +1 -1
  36. package/dist/technospam/pages/CoursesMyLearningPagePage.d.ts.map +1 -1
  37. package/dist/technospam/pages/CoursesMyLearningPagePage.js +90 -80
  38. package/dist/technospam/pages/CoursesMyLearningPagePage.js.map +1 -1
  39. package/dist/technospam/pages/DashboardDashboardPagePage.js +1 -1
  40. package/dist/technospam/pages/HackathonsHackathonDetailsPagePage.d.ts.map +1 -1
  41. package/dist/technospam/pages/HackathonsHackathonDetailsPagePage.js +155 -147
  42. package/dist/technospam/pages/HackathonsHackathonDetailsPagePage.js.map +1 -1
  43. package/dist/technospam/pages/HackathonsHackathonsPagePage.js +1 -1
  44. package/dist/technospam/pages/MentorshipMentorProfilePagePage.js +1 -1
  45. package/dist/technospam/pages/MentorshipMentorsPagePage.js +1 -1
  46. package/dist/technospam/pages/MentorshipSessionsPagePage.d.ts.map +1 -1
  47. package/dist/technospam/pages/MentorshipSessionsPagePage.js +186 -167
  48. package/dist/technospam/pages/MentorshipSessionsPagePage.js.map +1 -1
  49. package/dist/technospam/pages/StudyPlannerStudyPlannerPagePage.js +1 -1
  50. package/dist/technospam/utils/pageContext.d.ts +54 -5
  51. package/dist/technospam/utils/pageContext.d.ts.map +1 -1
  52. package/dist/technospam/utils/pageContext.js +99 -35
  53. package/dist/technospam/utils/pageContext.js.map +1 -1
  54. package/package.json +1 -1
@@ -1,66 +1,78 @@
1
- import { useTechnoSpam as e } from "../providers/TechnoSpamProvider.js";
2
- import { useTechnoSpamAnalytics as t } from "../hooks/useTechnoSpamAnalytics.js";
3
- import { PageLayout as n } from "../components/PageLayout.js";
4
- import { StatCard as r } from "../components/StatCard.js";
5
- import { formatDateTime as i, humanizeEnum as a } from "../utils/format.js";
6
- import { StatusBadge as o } from "../components/StatusBadge.js";
7
- import { EmptyView as s, ErrorView as c, LoadingRows as ee } from "../components/StateViews.js";
1
+ import { useTechnoSpam as e, useTechnoSpamNavigate as t } from "../providers/TechnoSpamProvider.js";
2
+ import { useTechnoSpamAnalytics as n } from "../hooks/useTechnoSpamAnalytics.js";
3
+ import { cn as r } from "../utils/cn.js";
4
+ import { PageLayout as i } from "../components/PageLayout.js";
5
+ import { StatCard as a } from "../components/StatCard.js";
6
+ import { formatDateTime as o, humanizeEnum as s } from "../utils/format.js";
7
+ import { StatusBadge as c } from "../components/StatusBadge.js";
8
+ import { EmptyView as l, ErrorView as u, LoadingRows as ee } from "../components/StateViews.js";
8
9
  import { TagStrip as te } from "../components/TagStrip.js";
9
- import { PremiumBadge as ne, UpgradeGate as l } from "../components/UpgradeGate.js";
10
- import { CodePanel as re, IoBlock as u, TestResultsPanel as ie } from "../components/SubmissionViews.js";
11
- import "../components/index.js";
12
- import { notify as d } from "../lib/toast.js";
10
+ import { PremiumBadge as ne, UpgradeGate as d } from "../components/UpgradeGate.js";
11
+ import { CodePanel as re, IoBlock as f, TestResultsPanel as ie } from "../components/SubmissionViews.js";
12
+ import { notify as p } from "../lib/toast.js";
13
13
  import { useProblemQuery as ae, useRegradeSubmission as oe, useSubmissionsQuery as se, useSubmitSolution as ce } from "../api/technospamApi.js";
14
- import { useEffect as f, useMemo as p, useRef as m, useState as h } from "react";
15
- import { Clock as g, Code2 as _, FileText as v, FlaskConical as le, Layers as y, RefreshCw as b, Send as ue, Trophy as x } from "lucide-react";
16
- import { useSearchParams as S } from "react-router";
17
- import { jsx as C, jsxs as w } from "react/jsx-runtime";
18
- import { Badge as de, Button as T, GlassCard as E, Select as fe, SelectContent as pe, SelectItem as me, SelectTrigger as he, SelectValue as ge, Skeleton as D, Textarea as _e } from "@burdenoff/fe-libs/ui";
14
+ import { SubmissionReviewPanel as le } from "../components/SubmissionReviewPanel.js";
15
+ import "../components/index.js";
16
+ import { FOCUS_PARAMS as ue } from "../utils/pageContext.js";
17
+ import { focusableCardProps as m, useFocusedRecordParam as de } from "../hooks/useFocusedRecordParam.js";
18
+ import { useEffect as h, useMemo as fe, useRef as g, useState as _ } from "react";
19
+ import { Clock as v, Code2 as y, FileText as b, FlaskConical as pe, Layers as x, RefreshCw as S, Send as me, Sparkles as he, Trophy as C } from "lucide-react";
20
+ import { useSearchParams as ge } from "react-router";
21
+ import { Fragment as _e, jsx as w, jsxs as T } from "react/jsx-runtime";
22
+ import { Badge as ve, Button as E, GlassCard as D, Select as ye, SelectContent as be, SelectItem as xe, SelectTrigger as Se, SelectValue as Ce, Skeleton as O, Textarea as we } from "@burdenoff/fe-libs/ui";
19
23
  //#region src/technospam/pages/ApplicationsProblemDetailsPagePage.tsx
20
- var O = [
24
+ var k = [
21
25
  "javascript",
22
26
  "python",
23
27
  "typescript"
24
- ], ve = 3e3, ye = 3 * 6e4;
25
- function be({ s: e }) {
26
- return /* @__PURE__ */ w("div", {
27
- className: "rounded-lg border border-transparent px-2 py-3 transition-colors hover:border-border-seam hover:bg-bg-sunken",
28
- children: [/* @__PURE__ */ w("div", {
28
+ ], Te = 3e3, Ee = 3 * 6e4;
29
+ function De({ s: e, focused: t, onToggle: n }) {
30
+ return /* @__PURE__ */ T("div", {
31
+ className: r("cursor-pointer rounded-lg border border-transparent px-2 py-3 transition-colors hover:border-border-seam hover:bg-bg-sunken", t && "ring-2 ring-accent-primary"),
32
+ ...m(t, n),
33
+ children: [/* @__PURE__ */ T("div", {
29
34
  className: "flex flex-wrap items-center gap-x-4 gap-y-1",
30
35
  children: [
31
- /* @__PURE__ */ C(o, { status: e.verdict }),
32
- /* @__PURE__ */ w("span", {
36
+ /* @__PURE__ */ w("button", {
37
+ type: "button",
38
+ "aria-pressed": t,
39
+ "aria-label": `Focus submission from ${o(e.createdAt)}`,
40
+ onClick: n,
41
+ className: "rounded-full",
42
+ children: /* @__PURE__ */ w(c, { status: e.verdict })
43
+ }),
44
+ /* @__PURE__ */ T("span", {
33
45
  className: "inline-flex items-center gap-1 text-sm font-medium text-text-primary",
34
46
  children: [
35
- /* @__PURE__ */ C(_, { size: 13 }),
47
+ /* @__PURE__ */ w(y, { size: 13 }),
36
48
  " ",
37
- a(e.language)
49
+ s(e.language)
38
50
  ]
39
51
  }),
40
- /* @__PURE__ */ w("span", {
52
+ /* @__PURE__ */ T("span", {
41
53
  className: "inline-flex items-center gap-1 text-xs text-text-muted",
42
54
  children: [
43
- /* @__PURE__ */ C(g, { size: 12 }),
55
+ /* @__PURE__ */ w(v, { size: 12 }),
44
56
  " ",
45
57
  e.runtimeMs,
46
58
  " ms"
47
59
  ]
48
60
  }),
49
- /* @__PURE__ */ w("span", {
61
+ /* @__PURE__ */ T("span", {
50
62
  className: "inline-flex items-center gap-1 text-xs text-text-muted",
51
63
  children: [
52
- /* @__PURE__ */ C(x, { size: 12 }),
64
+ /* @__PURE__ */ w(C, { size: 12 }),
53
65
  " ",
54
66
  e.pointsAwarded,
55
67
  " pts"
56
68
  ]
57
69
  }),
58
- /* @__PURE__ */ C("span", {
70
+ /* @__PURE__ */ w("span", {
59
71
  className: "ml-auto text-xs text-text-muted",
60
- children: i(e.createdAt)
72
+ children: o(e.createdAt)
61
73
  })
62
74
  ]
63
- }), e.totalCount > 0 ? /* @__PURE__ */ w("p", {
75
+ }), e.totalCount > 0 ? /* @__PURE__ */ T("p", {
64
76
  className: "mt-1 px-0.5 text-xs text-text-muted",
65
77
  children: [
66
78
  "Passed ",
@@ -72,78 +84,78 @@ function be({ s: e }) {
72
84
  }) : null]
73
85
  });
74
86
  }
75
- function k() {
76
- let [i] = S(), k = i.get("id") ?? "", { currentUser: xe, workspaceId: A } = e(), j = xe?.id, { emit: M } = t(), { data: Se, loading: N, error: P, refetch: F } = ae(k);
77
- f(() => {
78
- k && M("technospam.problem.viewed", {
79
- workspaceId: A,
80
- entityId: k,
87
+ function A() {
88
+ let [r] = ge(), o = r.get("id") ?? "", [m, A] = de(ue.submission), { currentUser: Oe, workspaceId: j } = e(), ke = t(), M = Oe?.id, { emit: N } = n(), { data: Ae, loading: je, error: P, refetch: F } = ae(o);
89
+ h(() => {
90
+ o && N("technospam.problem.viewed", {
91
+ workspaceId: j,
92
+ entityId: o,
81
93
  entityType: "TEC_PROBLEM"
82
94
  });
83
95
  }, [
84
- k,
85
- A,
86
- M
96
+ o,
97
+ j,
98
+ N
87
99
  ]);
88
- let { data: I, loading: Ce, error: L, refetch: R } = se({
89
- ...j ? { learnerId: j } : {},
90
- problemId: k
91
- }), [we, { loading: z }] = ce(), [Te, { loading: B }] = oe(), V = Se?.tecProblem ?? null, H = p(() => V?.languages?.length ? V.languages : O, [V]), [U, W] = h(""), [G, K] = h(""), q = m(!1);
92
- f(() => {
93
- V && !q.current && (W(V.languages[0] ?? O[0]), K(V.starterCode ?? ""), q.current = !0);
100
+ let { data: I, loading: Me, error: L, refetch: R } = se({
101
+ ...M ? { learnerId: M } : {},
102
+ problemId: o
103
+ }), [Ne, { loading: z }] = ce(), [Pe, { loading: B }] = oe(), V = Ae?.tecProblem ?? null, H = fe(() => V?.languages?.length ? V.languages : k, [V]), [U, W] = _(""), [G, K] = _(""), q = g(!1);
104
+ h(() => {
105
+ V && !q.current && (W(V.languages[0] ?? k[0]), K(V.starterCode ?? ""), q.current = !0);
94
106
  }, [V]);
95
- let J = p(() => [...I?.tecListSubmissions?.items ?? []].sort((e, t) => new Date(t.createdAt).getTime() - new Date(e.createdAt).getTime()), [I]), Ee = async () => {
96
- if (!k) return;
107
+ let J = fe(() => [...I?.tecListSubmissions?.items ?? []].sort((e, t) => new Date(t.createdAt).getTime() - new Date(e.createdAt).getTime()), [I]), Fe = async () => {
108
+ if (!o) return;
97
109
  if (!U) {
98
- d.error("Pick a language", "Choose a language before submitting.");
110
+ p.error("Pick a language", "Choose a language before submitting.");
99
111
  return;
100
112
  }
101
113
  if (!G.trim()) {
102
- d.error("Add your solution", "Write some code before submitting.");
114
+ p.error("Add your solution", "Write some code before submitting.");
103
115
  return;
104
116
  }
105
- M("technospam.problem.submit_clicked", {
106
- workspaceId: A,
107
- entityId: k,
117
+ N("technospam.problem.submit_clicked", {
118
+ workspaceId: j,
119
+ entityId: o,
108
120
  entityType: "TEC_PROBLEM",
109
121
  language: U
110
122
  });
111
- let e = await we({ variables: { input: {
112
- problemId: k,
123
+ let e = await Ne({ variables: { input: {
124
+ problemId: o,
113
125
  language: U,
114
126
  code: G
115
127
  } } });
116
128
  if (e.data?.tecSubmitSolution) {
117
- M("technospam.problem.submitted", {
118
- workspaceId: A,
119
- entityId: k,
129
+ N("technospam.problem.submitted", {
130
+ workspaceId: j,
131
+ entityId: o,
120
132
  entityType: "TEC_PROBLEM",
121
133
  submissionId: e.data.tecSubmitSolution.id
122
134
  });
123
135
  let t = e.data.tecSubmitSolution;
124
- t.verdict === "PENDING" ? d.info("Solution submitted", "Grading has started — your verdict will appear here in a moment.") : t.verdict === "ACCEPTED" ? d.success("Accepted", `Passed all ${t.totalCount} test cases.`) : d.error(a(t.verdict), `Passed ${t.passedCount} of ${t.totalCount} test cases.`), await Promise.all([F(), R()]);
136
+ t.verdict === "PENDING" ? p.info("Solution submitted", "Grading has started — your verdict will appear here in a moment.") : t.verdict === "ACCEPTED" ? p.success("Accepted", `Passed all ${t.totalCount} test cases.`) : p.error(s(t.verdict), `Passed ${t.passedCount} of ${t.totalCount} test cases.`), await Promise.all([F(), R()]);
125
137
  }
126
- }, De = async (e) => {
127
- let t = (await Te({ variables: { id: e } })).data?.tecRegradeSubmission;
128
- t && (t.verdict === "PENDING" ? d.error("Still pending", "The grader is not available yet. Please try again shortly.") : d.success("Grading complete", `Verdict: ${a(t.verdict)}.`), await Promise.all([F(), R()]));
129
- }, Y = J.find((e) => (e.testResults?.length ?? 0) > 0) ?? null, X = J[0] ?? null, Z = X?.verdict === "PENDING" ? X.id : null, [Q, Oe] = h(null), ke = Z !== null && Q !== Z;
130
- f(() => {
138
+ }, Ie = async (e) => {
139
+ let t = (await Pe({ variables: { id: e } })).data?.tecRegradeSubmission;
140
+ t && (t.verdict === "PENDING" ? p.error("Still pending", "The grader is not available yet. Please try again shortly.") : p.success("Grading complete", `Verdict: ${s(t.verdict)}.`), await Promise.all([F(), R()]));
141
+ }, Y = J.find((e) => (e.testResults?.length ?? 0) > 0) ?? null, X = J[0] ?? null, Z = X?.verdict === "PENDING" ? X.id : null, [Q, Le] = _(null), Re = Z !== null && Q !== Z;
142
+ h(() => {
131
143
  if (!Z || Q === Z) return;
132
144
  let e = Date.now(), t = window.setInterval(() => {
133
- if (Date.now() - e > ye) {
134
- window.clearInterval(t), Oe(Z);
145
+ if (Date.now() - e > Ee) {
146
+ window.clearInterval(t), Le(Z);
135
147
  return;
136
148
  }
137
149
  R();
138
- }, ve);
150
+ }, Te);
139
151
  return () => window.clearInterval(t);
140
152
  }, [
141
153
  Z,
142
154
  Q,
143
155
  R
144
156
  ]);
145
- let $ = m(null);
146
- return f(() => {
157
+ let $ = g(null);
158
+ return h(() => {
147
159
  if (Z) {
148
160
  $.current = Z;
149
161
  return;
@@ -151,159 +163,159 @@ function k() {
151
163
  let e = $.current;
152
164
  if (!e) return;
153
165
  let t = J.find((t) => t.id === e);
154
- !t || t.verdict === "PENDING" || ($.current = null, t.verdict === "ACCEPTED" ? d.success("Accepted", `Passed all ${t.totalCount} test cases.`) : d.error(a(t.verdict), `Passed ${t.passedCount} of ${t.totalCount} test cases.`), F());
166
+ !t || t.verdict === "PENDING" || ($.current = null, t.verdict === "ACCEPTED" ? p.success("Accepted", `Passed all ${t.totalCount} test cases.`) : p.error(s(t.verdict), `Passed ${t.passedCount} of ${t.totalCount} test cases.`), F());
155
167
  }, [
156
168
  Z,
157
169
  J,
158
170
  F
159
- ]), N && !V ? /* @__PURE__ */ w(n, {
171
+ ]), je && !V ? /* @__PURE__ */ T(i, {
160
172
  title: "Problem",
161
173
  backPath: "/applications/problems-page",
162
- children: [/* @__PURE__ */ C(D, { className: "mb-4 h-28 w-full rounded-xl" }), /* @__PURE__ */ C(D, { className: "h-72 w-full rounded-xl" })]
163
- }) : P || !V ? /* @__PURE__ */ C(n, {
174
+ children: [/* @__PURE__ */ w(O, { className: "mb-4 h-28 w-full rounded-xl" }), /* @__PURE__ */ w(O, { className: "h-72 w-full rounded-xl" })]
175
+ }) : P || !V ? /* @__PURE__ */ w(i, {
164
176
  title: "Problem",
165
177
  backPath: "/applications/problems-page",
166
- children: P ? /* @__PURE__ */ C(c, {
178
+ children: P ? /* @__PURE__ */ w(u, {
167
179
  title: "Couldn't load problem",
168
180
  error: P
169
- }) : /* @__PURE__ */ C(s, {
181
+ }) : /* @__PURE__ */ w(l, {
170
182
  title: "Problem not found",
171
183
  description: "This problem may have been unpublished."
172
184
  })
173
- }) : /* @__PURE__ */ w(n, {
185
+ }) : /* @__PURE__ */ T(i, {
174
186
  hero: !0,
175
187
  backPath: "/applications/problems-page",
176
188
  title: V.title,
177
189
  description: V.topic ?? void 0,
178
190
  children: [
179
- /* @__PURE__ */ w("div", {
191
+ /* @__PURE__ */ T("div", {
180
192
  className: "mb-5 flex flex-wrap items-center gap-2",
181
193
  children: [
182
- /* @__PURE__ */ C(o, {
194
+ /* @__PURE__ */ w(c, {
183
195
  status: V.difficulty,
184
196
  kind: "level"
185
197
  }),
186
- /* @__PURE__ */ C(o, { status: V.status }),
187
- V.topic ? /* @__PURE__ */ w(de, {
198
+ /* @__PURE__ */ w(c, { status: V.status }),
199
+ V.topic ? /* @__PURE__ */ T(ve, {
188
200
  variant: "outline",
189
201
  className: "gap-1",
190
202
  children: [
191
- /* @__PURE__ */ C(y, { size: 12 }),
203
+ /* @__PURE__ */ w(x, { size: 12 }),
192
204
  " ",
193
205
  V.topic
194
206
  ]
195
207
  }) : null,
196
- V.isPremiumOnly ? /* @__PURE__ */ C(ne, { locked: V.isLocked }) : null,
197
- /* @__PURE__ */ C(te, { tags: V.tags })
208
+ V.isPremiumOnly ? /* @__PURE__ */ w(ne, { locked: V.isLocked }) : null,
209
+ /* @__PURE__ */ w(te, { tags: V.tags })
198
210
  ]
199
211
  }),
200
- /* @__PURE__ */ w("div", {
212
+ /* @__PURE__ */ T("div", {
201
213
  className: "mb-6 grid grid-cols-2 gap-3 sm:grid-cols-4",
202
214
  children: [
203
- /* @__PURE__ */ C(r, {
215
+ /* @__PURE__ */ w(a, {
204
216
  label: "Points",
205
217
  value: V.points,
206
- icon: x,
218
+ icon: C,
207
219
  tone: "amber"
208
220
  }),
209
- /* @__PURE__ */ C(r, {
221
+ /* @__PURE__ */ w(a, {
210
222
  label: "Languages",
211
223
  value: H.length,
212
- icon: _,
224
+ icon: y,
213
225
  tone: "blue"
214
226
  }),
215
- /* @__PURE__ */ C(r, {
227
+ /* @__PURE__ */ w(a, {
216
228
  label: "Difficulty",
217
- value: a(V.difficulty),
218
- icon: y,
229
+ value: s(V.difficulty),
230
+ icon: x,
219
231
  tone: "purple"
220
232
  }),
221
- /* @__PURE__ */ C(r, {
233
+ /* @__PURE__ */ w(a, {
222
234
  label: "My submissions",
223
235
  value: J.length,
224
- icon: v,
236
+ icon: b,
225
237
  tone: "teal"
226
238
  })
227
239
  ]
228
240
  }),
229
- /* @__PURE__ */ w("div", {
241
+ /* @__PURE__ */ T("div", {
230
242
  className: "grid grid-cols-1 gap-5 lg:grid-cols-3",
231
- children: [/* @__PURE__ */ w("div", {
243
+ children: [/* @__PURE__ */ T("div", {
232
244
  className: "space-y-5 lg:col-span-2",
233
245
  children: [
234
- /* @__PURE__ */ w(E, {
246
+ /* @__PURE__ */ T(D, {
235
247
  className: "p-5",
236
- children: [/* @__PURE__ */ C("h2", {
248
+ children: [/* @__PURE__ */ w("h2", {
237
249
  className: "mb-2 text-base font-semibold text-text-primary",
238
250
  children: "Problem statement"
239
- }), V.isLocked ? /* @__PURE__ */ C(l, { description: "This problem's statement is part of a paid TechnoSpam plan. Ask a workspace admin to upgrade to unlock it." }) : V.statement ? /* @__PURE__ */ C("p", {
251
+ }), V.isLocked ? /* @__PURE__ */ w(d, { description: "This problem's statement is part of a paid TechnoSpam plan. Ask a workspace admin to upgrade to unlock it." }) : V.statement ? /* @__PURE__ */ w("p", {
240
252
  className: "whitespace-pre-wrap text-sm leading-relaxed text-text-secondary",
241
253
  children: V.statement
242
- }) : /* @__PURE__ */ C("p", {
254
+ }) : /* @__PURE__ */ w("p", {
243
255
  className: "py-4 text-center text-sm text-text-muted",
244
256
  children: "The statement for this problem is being prepared."
245
257
  })]
246
258
  }),
247
- V.isLocked ? /* @__PURE__ */ C(l, {
259
+ V.isLocked ? /* @__PURE__ */ w(d, {
248
260
  compact: !0,
249
261
  description: "Starter code and sample test cases unlock with a paid TechnoSpam plan."
250
- }) : V.starterCode ? /* @__PURE__ */ w(E, {
262
+ }) : V.starterCode ? /* @__PURE__ */ T(D, {
251
263
  className: "p-5",
252
- children: [/* @__PURE__ */ C("h2", {
264
+ children: [/* @__PURE__ */ w("h2", {
253
265
  className: "mb-3 text-base font-semibold text-text-primary",
254
266
  children: "Starter code"
255
- }), /* @__PURE__ */ C(re, {
256
- label: a(H[0] ?? "code"),
267
+ }), /* @__PURE__ */ w(re, {
268
+ label: s(H[0] ?? "code"),
257
269
  bodyClassName: "max-h-72",
258
270
  children: V.starterCode
259
271
  })]
260
272
  }) : null,
261
- /* @__PURE__ */ w(E, {
273
+ /* @__PURE__ */ T(D, {
262
274
  className: "p-5",
263
275
  children: [
264
- /* @__PURE__ */ w("div", {
276
+ /* @__PURE__ */ T("div", {
265
277
  className: "mb-3 flex flex-col gap-2 sm:flex-row sm:items-center sm:justify-between",
266
- children: [/* @__PURE__ */ C("h2", {
278
+ children: [/* @__PURE__ */ w("h2", {
267
279
  className: "text-base font-semibold text-text-primary",
268
280
  children: "Submit a solution"
269
- }), /* @__PURE__ */ w("div", {
281
+ }), /* @__PURE__ */ T("div", {
270
282
  className: "flex items-center gap-2",
271
- children: [/* @__PURE__ */ C("span", {
283
+ children: [/* @__PURE__ */ w("span", {
272
284
  className: "text-sm text-text-secondary",
273
285
  children: "Language"
274
- }), /* @__PURE__ */ w(fe, {
286
+ }), /* @__PURE__ */ T(ye, {
275
287
  value: U,
276
288
  onValueChange: W,
277
- children: [/* @__PURE__ */ C(he, {
289
+ children: [/* @__PURE__ */ w(Se, {
278
290
  className: "w-full sm:w-48",
279
- children: /* @__PURE__ */ C(ge, { placeholder: "Choose a language" })
280
- }), /* @__PURE__ */ C(pe, { children: H.map((e) => /* @__PURE__ */ C(me, {
291
+ children: /* @__PURE__ */ w(Ce, { placeholder: "Choose a language" })
292
+ }), /* @__PURE__ */ w(be, { children: H.map((e) => /* @__PURE__ */ w(xe, {
281
293
  value: e,
282
- children: a(e)
294
+ children: s(e)
283
295
  }, e)) })]
284
296
  })]
285
297
  })]
286
298
  }),
287
- /* @__PURE__ */ w("div", {
299
+ /* @__PURE__ */ T("div", {
288
300
  className: "overflow-hidden rounded-xl border border-border-strong bg-bg-sunken shadow-sm",
289
- children: [/* @__PURE__ */ w("div", {
301
+ children: [/* @__PURE__ */ T("div", {
290
302
  className: "flex items-center justify-between gap-2 border-b border-border-seam bg-bg-canvas/40 px-4 py-2",
291
- children: [/* @__PURE__ */ w("div", {
303
+ children: [/* @__PURE__ */ T("div", {
292
304
  className: "flex items-center gap-1.5",
293
305
  children: [
294
- /* @__PURE__ */ C("span", { className: "h-2.5 w-2.5 rounded-full bg-status-error-border" }),
295
- /* @__PURE__ */ C("span", { className: "h-2.5 w-2.5 rounded-full bg-status-warning-border" }),
296
- /* @__PURE__ */ C("span", { className: "h-2.5 w-2.5 rounded-full bg-status-success-border" })
306
+ /* @__PURE__ */ w("span", { className: "h-2.5 w-2.5 rounded-full bg-status-error-border" }),
307
+ /* @__PURE__ */ w("span", { className: "h-2.5 w-2.5 rounded-full bg-status-warning-border" }),
308
+ /* @__PURE__ */ w("span", { className: "h-2.5 w-2.5 rounded-full bg-status-success-border" })
297
309
  ]
298
- }), /* @__PURE__ */ w("span", {
310
+ }), /* @__PURE__ */ T("span", {
299
311
  className: "inline-flex items-center gap-1.5 font-mono text-xs text-text-muted",
300
312
  children: [
301
- /* @__PURE__ */ C(_, { size: 13 }),
313
+ /* @__PURE__ */ w(y, { size: 13 }),
302
314
  " ",
303
- U ? a(U) : "solution"
315
+ U ? s(U) : "solution"
304
316
  ]
305
317
  })]
306
- }), /* @__PURE__ */ C(_e, {
318
+ }), /* @__PURE__ */ w(we, {
307
319
  value: G,
308
320
  onChange: (e) => K(e.target.value),
309
321
  placeholder: "Write your solution…",
@@ -311,57 +323,57 @@ function k() {
311
323
  spellCheck: !1
312
324
  })]
313
325
  }),
314
- /* @__PURE__ */ w(T, {
326
+ /* @__PURE__ */ T(E, {
315
327
  className: "mt-4 w-full",
316
- onClick: Ee,
328
+ onClick: Fe,
317
329
  disabled: z || !G.trim(),
318
330
  children: [
319
- /* @__PURE__ */ C(ue, { size: 16 }),
331
+ /* @__PURE__ */ w(me, { size: 16 }),
320
332
  " ",
321
333
  z ? "Running test cases…" : "Run & submit"
322
334
  ]
323
335
  }),
324
- /* @__PURE__ */ C("p", {
336
+ /* @__PURE__ */ w("p", {
325
337
  className: "mt-2 text-center text-xs text-text-muted",
326
338
  children: "Your code runs against this problem's test cases in an isolated sandbox."
327
339
  })
328
340
  ]
329
341
  }),
330
- V.publicTestCases?.length ? /* @__PURE__ */ w(E, {
342
+ V.publicTestCases?.length ? /* @__PURE__ */ T(D, {
331
343
  className: "p-5",
332
344
  children: [
333
- /* @__PURE__ */ w("h2", {
345
+ /* @__PURE__ */ T("h2", {
334
346
  className: "mb-1 flex items-center gap-2 text-base font-semibold text-text-primary",
335
- children: [/* @__PURE__ */ C(le, { size: 16 }), " Sample test cases"]
347
+ children: [/* @__PURE__ */ w(pe, { size: 16 }), " Sample test cases"]
336
348
  }),
337
- /* @__PURE__ */ C("p", {
349
+ /* @__PURE__ */ w("p", {
338
350
  className: "mb-3 text-sm text-text-secondary",
339
351
  children: "Your solution reads each input from stdin and must print the expected output. Hidden test cases are also run when you submit."
340
352
  }),
341
- /* @__PURE__ */ C("div", {
353
+ /* @__PURE__ */ w("div", {
342
354
  className: "space-y-3",
343
- children: V.publicTestCases.map((e) => /* @__PURE__ */ w("div", {
355
+ children: V.publicTestCases.map((e) => /* @__PURE__ */ T("div", {
344
356
  className: "rounded-xl border border-border-seam p-3",
345
- children: [/* @__PURE__ */ w("div", {
357
+ children: [/* @__PURE__ */ T("div", {
346
358
  className: "mb-2 flex flex-wrap items-center gap-x-3 gap-y-1",
347
- children: [/* @__PURE__ */ C("span", {
359
+ children: [/* @__PURE__ */ w("span", {
348
360
  className: "text-sm font-medium text-text-primary",
349
361
  children: e.name
350
- }), /* @__PURE__ */ w("span", {
362
+ }), /* @__PURE__ */ T("span", {
351
363
  className: "inline-flex items-center gap-1 text-xs text-text-muted",
352
364
  children: [
353
- /* @__PURE__ */ C(g, { size: 12 }),
365
+ /* @__PURE__ */ w(v, { size: 12 }),
354
366
  " ",
355
367
  e.timeLimitMs,
356
368
  " ms limit"
357
369
  ]
358
370
  })]
359
- }), /* @__PURE__ */ w("div", {
371
+ }), /* @__PURE__ */ T("div", {
360
372
  className: "grid grid-cols-1 gap-2 sm:grid-cols-2",
361
- children: [/* @__PURE__ */ C(u, {
373
+ children: [/* @__PURE__ */ w(f, {
362
374
  label: "Input",
363
375
  value: e.input
364
- }), /* @__PURE__ */ C(u, {
376
+ }), /* @__PURE__ */ w(f, {
365
377
  label: "Expected output",
366
378
  value: e.expectedOutput
367
379
  })]
@@ -370,62 +382,75 @@ function k() {
370
382
  })
371
383
  ]
372
384
  }) : null,
373
- Z ? /* @__PURE__ */ w(E, {
385
+ Z ? /* @__PURE__ */ T(D, {
374
386
  className: "p-5",
375
387
  children: [
376
- /* @__PURE__ */ C("h2", {
388
+ /* @__PURE__ */ w("h2", {
377
389
  className: "mb-2 text-base font-semibold text-text-primary",
378
390
  children: "Latest run"
379
391
  }),
380
- ke ? /* @__PURE__ */ w("p", {
392
+ Re ? /* @__PURE__ */ T("p", {
381
393
  className: "mb-3 inline-flex items-center gap-2 text-sm text-text-secondary",
382
- children: [/* @__PURE__ */ C(b, {
394
+ children: [/* @__PURE__ */ w(S, {
383
395
  size: 14,
384
396
  className: "animate-spin"
385
397
  }), "Grading your submission — the grader is starting up. Your verdict will appear here automatically."]
386
- }) : /* @__PURE__ */ C("p", {
398
+ }) : /* @__PURE__ */ w("p", {
387
399
  className: "mb-3 text-sm text-text-secondary",
388
400
  children: "Your most recent submission has not been graded yet — the grader was unavailable. You can re-run it without resubmitting your code."
389
401
  }),
390
- /* @__PURE__ */ w(T, {
402
+ /* @__PURE__ */ T(E, {
391
403
  variant: "outline",
392
- onClick: () => void De(Z),
404
+ onClick: () => void Ie(Z),
393
405
  disabled: B,
394
406
  children: [
395
- /* @__PURE__ */ C(b, { size: 16 }),
407
+ /* @__PURE__ */ w(S, { size: 16 }),
396
408
  " ",
397
409
  B ? "Re-running…" : "Re-run grader"
398
410
  ]
399
411
  })
400
412
  ]
401
- }) : Y ? /* @__PURE__ */ w(E, {
413
+ }) : Y ? /* @__PURE__ */ T(_e, { children: [/* @__PURE__ */ T(D, {
402
414
  className: "p-5",
403
- children: [/* @__PURE__ */ C("h2", {
415
+ children: [/* @__PURE__ */ w("h2", {
404
416
  className: "mb-3 text-base font-semibold text-text-primary",
405
417
  children: "Latest run"
406
- }), /* @__PURE__ */ C(ie, { submission: Y })]
407
- }) : null
418
+ }), /* @__PURE__ */ w(ie, { submission: Y })]
419
+ }), /* @__PURE__ */ T(D, {
420
+ className: "p-5",
421
+ children: [/* @__PURE__ */ T("h2", {
422
+ className: "mb-3 flex items-center gap-2 text-base font-semibold text-text-primary",
423
+ children: [/* @__PURE__ */ w(he, { size: 16 }), " TechnoSage review"]
424
+ }), /* @__PURE__ */ w(le, {
425
+ submission: Y,
426
+ onOpenProblem: (e) => ke(`/applications/problem-details-page?id=${e}`)
427
+ })]
428
+ })] }) : null
408
429
  ]
409
- }), /* @__PURE__ */ C("div", {
430
+ }), /* @__PURE__ */ w("div", {
410
431
  className: "lg:col-span-1",
411
- children: /* @__PURE__ */ w(E, {
432
+ children: /* @__PURE__ */ T(D, {
412
433
  className: "p-5",
413
- children: [/* @__PURE__ */ C("h2", {
434
+ children: [/* @__PURE__ */ w("h2", {
414
435
  className: "mb-3 text-base font-semibold text-text-primary",
415
436
  children: "My submissions"
416
- }), Ce && !J.length ? /* @__PURE__ */ C(ee, {
437
+ }), Me && !J.length ? /* @__PURE__ */ w(ee, {
417
438
  count: 3,
418
439
  height: "h-12"
419
- }) : L ? /* @__PURE__ */ C(c, {
440
+ }) : L ? /* @__PURE__ */ w(u, {
420
441
  title: "Couldn't load submissions",
421
442
  error: L
422
- }) : J.length === 0 ? /* @__PURE__ */ C(s, {
423
- icon: /* @__PURE__ */ C(v, { size: 24 }),
443
+ }) : J.length === 0 ? /* @__PURE__ */ w(l, {
444
+ icon: /* @__PURE__ */ w(b, { size: 24 }),
424
445
  title: "No submissions yet",
425
446
  description: "Submit a solution above to see your verdicts and points here."
426
- }) : /* @__PURE__ */ C("div", {
447
+ }) : /* @__PURE__ */ w("div", {
427
448
  className: "space-y-1",
428
- children: J.map((e) => /* @__PURE__ */ C(be, { s: e }, e.id))
449
+ children: J.map((e) => /* @__PURE__ */ w(De, {
450
+ s: e,
451
+ focused: m === e.id,
452
+ onToggle: () => A(m === e.id ? null : e.id)
453
+ }, e.id))
429
454
  })]
430
455
  })
431
456
  })]
@@ -434,6 +459,6 @@ function k() {
434
459
  });
435
460
  }
436
461
  //#endregion
437
- export { k as ApplicationsProblemDetailsPagePage };
462
+ export { A as ApplicationsProblemDetailsPagePage };
438
463
 
439
464
  //# sourceMappingURL=ApplicationsProblemDetailsPagePage.js.map