@lssm/example.learning-journey-registry 0.0.0-canary-20251217062139 → 0.0.0-canary-20251217072406
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/.turbo/turbo-build$colon$bundle.log +409 -410
- package/.turbo/turbo-build.log +410 -55
- package/CHANGELOG.md +14 -12
- package/dist/api.js +170 -1
- package/dist/docs/index.js +1 -1
- package/dist/docs/learning-journey-registry.docblock.js +38 -1
- package/dist/example.js +34 -1
- package/dist/examples/learning-journey-ambient-coach/src/track.js +41 -1
- package/dist/examples/learning-journey-crm-onboarding/dist/track.js +98 -1
- package/dist/examples/learning-journey-duo-drills/src/track.js +65 -1
- package/dist/examples/learning-journey-platform-tour/dist/track.js +105 -1
- package/dist/examples/learning-journey-quest-challenges/src/track.js +35 -1
- package/dist/examples/learning-journey-studio-onboarding/dist/track.js +90 -1
- package/dist/examples/learning-journey-ui-coaching/src/CoachingMiniApp.js +64 -1
- package/dist/examples/learning-journey-ui-coaching/src/components/EngagementMeter.js +107 -1
- package/dist/examples/learning-journey-ui-coaching/src/components/TipCard.js +75 -1
- package/dist/examples/learning-journey-ui-coaching/src/components/TipFeed.js +65 -1
- package/dist/examples/learning-journey-ui-coaching/src/components/index.js +3 -1
- package/dist/examples/learning-journey-ui-coaching/src/docs/index.js +1 -1
- package/dist/examples/learning-journey-ui-coaching/src/docs/learning-journey-ui-coaching.docblock.js +19 -7
- package/dist/examples/learning-journey-ui-coaching/src/index.js +11 -1
- package/dist/examples/learning-journey-ui-coaching/src/views/Overview.js +152 -1
- package/dist/examples/learning-journey-ui-coaching/src/views/Progress.js +117 -1
- package/dist/examples/learning-journey-ui-coaching/src/views/Steps.js +68 -1
- package/dist/examples/learning-journey-ui-coaching/src/views/Timeline.js +112 -1
- package/dist/examples/learning-journey-ui-coaching/src/views/index.js +4 -1
- package/dist/examples/learning-journey-ui-gamified/src/GamifiedMiniApp.js +64 -1
- package/dist/examples/learning-journey-ui-gamified/src/components/DayCalendar.js +32 -1
- package/dist/examples/learning-journey-ui-gamified/src/components/FlashCard.js +79 -1
- package/dist/examples/learning-journey-ui-gamified/src/components/MasteryRing.js +81 -1
- package/dist/examples/learning-journey-ui-gamified/src/components/index.js +3 -1
- package/dist/examples/learning-journey-ui-gamified/src/docs/index.js +1 -1
- package/dist/examples/learning-journey-ui-gamified/src/docs/learning-journey-ui-gamified.docblock.js +19 -7
- package/dist/examples/learning-journey-ui-gamified/src/index.js +11 -1
- package/dist/examples/learning-journey-ui-gamified/src/views/Overview.js +163 -1
- package/dist/examples/learning-journey-ui-gamified/src/views/Progress.js +144 -1
- package/dist/examples/learning-journey-ui-gamified/src/views/Steps.js +55 -1
- package/dist/examples/learning-journey-ui-gamified/src/views/Timeline.js +132 -1
- package/dist/examples/learning-journey-ui-gamified/src/views/index.js +4 -1
- package/dist/examples/learning-journey-ui-onboarding/src/OnboardingMiniApp.js +64 -1
- package/dist/examples/learning-journey-ui-onboarding/src/components/CodeSnippet.js +4 -1
- package/dist/examples/learning-journey-ui-onboarding/src/components/JourneyMap.js +48 -1
- package/dist/examples/learning-journey-ui-onboarding/src/components/StepChecklist.js +79 -1
- package/dist/examples/learning-journey-ui-onboarding/src/components/index.js +3 -1
- package/dist/examples/learning-journey-ui-onboarding/src/docs/index.js +1 -1
- package/dist/examples/learning-journey-ui-onboarding/src/docs/learning-journey-ui-onboarding.docblock.js +19 -7
- package/dist/examples/learning-journey-ui-onboarding/src/index.js +10 -1
- package/dist/examples/learning-journey-ui-onboarding/src/views/Overview.js +180 -1
- package/dist/examples/learning-journey-ui-onboarding/src/views/Progress.js +162 -1
- package/dist/examples/learning-journey-ui-onboarding/src/views/Steps.js +91 -1
- package/dist/examples/learning-journey-ui-onboarding/src/views/Timeline.js +97 -1
- package/dist/examples/learning-journey-ui-onboarding/src/views/index.js +4 -1
- package/dist/examples/learning-journey-ui-shared/src/components/BadgeDisplay.js +44 -1
- package/dist/examples/learning-journey-ui-shared/src/components/StreakCounter.js +45 -1
- package/dist/examples/learning-journey-ui-shared/src/components/ViewTabs.js +48 -1
- package/dist/examples/learning-journey-ui-shared/src/components/XpBar.js +46 -1
- package/dist/examples/learning-journey-ui-shared/src/components/index.js +4 -1
- package/dist/examples/learning-journey-ui-shared/src/docs/index.js +1 -1
- package/dist/examples/learning-journey-ui-shared/src/docs/learning-journey-ui-shared.docblock.js +19 -6
- package/dist/examples/learning-journey-ui-shared/src/hooks/index.js +1 -1
- package/dist/examples/learning-journey-ui-shared/src/hooks/useLearningProgress.js +73 -1
- package/dist/examples/learning-journey-ui-shared/src/index.js +8 -1
- package/dist/index.js +13 -1
- package/dist/learning-journey-registry.feature.js +66 -1
- package/dist/libs/contracts/dist/docs/PUBLISHING.docblock.js +16 -76
- package/dist/libs/contracts/dist/docs/accessibility_wcag_compliance_specs.docblock.js +16 -350
- package/dist/libs/contracts/dist/docs/index.js +29 -1
- package/dist/libs/contracts/dist/docs/presentations.js +71 -1
- package/dist/libs/contracts/dist/docs/registry.js +44 -1
- package/dist/libs/contracts/dist/docs/tech/PHASE_1_QUICKSTART.docblock.js +16 -383
- package/dist/libs/contracts/dist/docs/tech/PHASE_2_AI_NATIVE_OPERATIONS.docblock.js +16 -68
- package/dist/libs/contracts/dist/docs/tech/PHASE_3_AUTO_EVOLUTION.docblock.js +16 -140
- package/dist/libs/contracts/dist/docs/tech/PHASE_4_PERSONALIZATION_ENGINE.docblock.js +16 -86
- package/dist/libs/contracts/dist/docs/tech/PHASE_5_ZERO_TOUCH_OPERATIONS.docblock.js +16 -1
- package/dist/libs/contracts/dist/docs/tech/auth/better-auth-nextjs.docblock.js +24 -2
- package/dist/libs/contracts/dist/docs/tech/contracts/openapi-export.docblock.js +21 -2
- package/dist/libs/contracts/dist/docs/tech/lifecycle-stage-system.docblock.js +16 -213
- package/dist/libs/contracts/dist/docs/tech/llm/llm-integration.docblock.js +73 -5
- package/dist/libs/contracts/dist/docs/tech/mcp-endpoints.docblock.js +37 -1
- package/dist/libs/contracts/dist/docs/tech/presentation-runtime.docblock.js +16 -1
- package/dist/libs/contracts/dist/docs/tech/schema/README.docblock.js +20 -262
- package/dist/libs/contracts/dist/docs/tech/studio/learning-events.docblock.js +48 -1
- package/dist/libs/contracts/dist/docs/tech/studio/learning-journeys.docblock.js +24 -2
- package/dist/libs/contracts/dist/docs/tech/studio/platform-admin-panel.docblock.js +23 -2
- package/dist/libs/contracts/dist/docs/tech/studio/project-access-teams.docblock.js +25 -16
- package/dist/libs/contracts/dist/docs/tech/studio/project-routing.docblock.js +67 -1
- package/dist/libs/contracts/dist/docs/tech/studio/sandbox-unlogged.docblock.js +22 -2
- package/dist/libs/contracts/dist/docs/tech/studio/team-invitations.docblock.js +40 -36
- package/dist/libs/contracts/dist/docs/tech/studio/workspace-ops.docblock.js +47 -1
- package/dist/libs/contracts/dist/docs/tech/studio/workspaces.docblock.js +23 -2
- package/dist/libs/contracts/dist/docs/tech/telemetry-ingest.docblock.js +36 -3
- package/dist/libs/contracts/dist/docs/tech/templates/runtime.docblock.js +20 -1
- package/dist/libs/contracts/dist/docs/tech/vscode-extension.docblock.js +36 -3
- package/dist/libs/contracts/dist/docs/tech/workflows/overview.docblock.js +20 -1
- package/dist/libs/design-system/dist/_virtual/rolldown_runtime.js +5 -1
- package/dist/libs/design-system/dist/components/atoms/Button.js +33 -1
- package/dist/libs/design-system/dist/ui-kit-web/dist/ui/button.js +55 -1
- package/dist/libs/design-system/dist/ui-kit-web/dist/ui-kit-core/dist/utils.js +13 -1
- package/dist/libs/ui-kit-core/dist/utils.js +10 -1
- package/dist/libs/ui-kit-web/dist/ui/card.js +36 -1
- package/dist/libs/ui-kit-web/dist/ui/progress.js +23 -1
- package/dist/libs/ui-kit-web/dist/ui/utils.js +10 -1
- package/dist/libs/ui-kit-web/dist/ui-kit-core/dist/utils.js +10 -1
- package/dist/presentations/index.js +64 -1
- package/dist/progress-store.js +30 -1
- package/dist/tracks.js +47 -1
- package/dist/ui/LearningMiniApp.js +82 -1
- package/dist/ui/index.js +3 -1
- package/package.json +16 -14
- package/tsconfig.tsbuildinfo +1 -1
|
@@ -1 +1,163 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { Card, CardContent, CardHeader, CardTitle } from "../../../../libs/ui-kit-web/dist/ui/card.js";
|
|
4
|
+
import { XpBar } from "../../../learning-journey-ui-shared/src/components/XpBar.js";
|
|
5
|
+
import { StreakCounter } from "../../../learning-journey-ui-shared/src/components/StreakCounter.js";
|
|
6
|
+
import { BadgeDisplay } from "../../../learning-journey-ui-shared/src/components/BadgeDisplay.js";
|
|
7
|
+
import { Button$1 } from "../../../../libs/design-system/dist/components/atoms/Button.js";
|
|
8
|
+
import "../../../learning-journey-ui-shared/src/index.js";
|
|
9
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
10
|
+
|
|
11
|
+
//#region ../learning-journey-ui-gamified/src/views/Overview.tsx
|
|
12
|
+
function Overview({ track, progress, onStart }) {
|
|
13
|
+
const totalXp = track.totalXp ?? track.steps.reduce((sum, s) => sum + (s.xpReward ?? 0), 0) + (track.completionRewards?.xpBonus ?? 0);
|
|
14
|
+
const completedSteps = progress.completedStepIds.length;
|
|
15
|
+
const totalSteps = track.steps.length;
|
|
16
|
+
const isComplete = completedSteps === totalSteps;
|
|
17
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
18
|
+
className: "space-y-6",
|
|
19
|
+
children: [
|
|
20
|
+
/* @__PURE__ */ jsx(Card, {
|
|
21
|
+
className: "overflow-hidden bg-gradient-to-br from-violet-500/10 via-purple-500/10 to-fuchsia-500/10",
|
|
22
|
+
children: /* @__PURE__ */ jsx(CardContent, {
|
|
23
|
+
className: "p-6",
|
|
24
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
25
|
+
className: "flex flex-col items-center gap-4 text-center md:flex-row md:text-left",
|
|
26
|
+
children: [
|
|
27
|
+
/* @__PURE__ */ jsx("div", {
|
|
28
|
+
className: "flex h-20 w-20 items-center justify-center rounded-2xl bg-gradient-to-br from-violet-500 to-purple-600 text-4xl shadow-lg",
|
|
29
|
+
children: isComplete ? "🏆" : "🎯"
|
|
30
|
+
}),
|
|
31
|
+
/* @__PURE__ */ jsxs("div", {
|
|
32
|
+
className: "flex-1",
|
|
33
|
+
children: [/* @__PURE__ */ jsx("h1", {
|
|
34
|
+
className: "text-2xl font-bold",
|
|
35
|
+
children: track.name
|
|
36
|
+
}), /* @__PURE__ */ jsx("p", {
|
|
37
|
+
className: "text-muted-foreground mt-1",
|
|
38
|
+
children: track.description
|
|
39
|
+
})]
|
|
40
|
+
}),
|
|
41
|
+
/* @__PURE__ */ jsx("div", {
|
|
42
|
+
className: "flex items-center gap-3",
|
|
43
|
+
children: /* @__PURE__ */ jsx(StreakCounter, {
|
|
44
|
+
days: progress.streakDays,
|
|
45
|
+
size: "lg"
|
|
46
|
+
})
|
|
47
|
+
})
|
|
48
|
+
]
|
|
49
|
+
})
|
|
50
|
+
})
|
|
51
|
+
}),
|
|
52
|
+
/* @__PURE__ */ jsxs("div", {
|
|
53
|
+
className: "grid gap-4 md:grid-cols-3",
|
|
54
|
+
children: [
|
|
55
|
+
/* @__PURE__ */ jsxs(Card, { children: [/* @__PURE__ */ jsx(CardHeader, {
|
|
56
|
+
className: "pb-2",
|
|
57
|
+
children: /* @__PURE__ */ jsx(CardTitle, {
|
|
58
|
+
className: "text-muted-foreground text-sm font-medium",
|
|
59
|
+
children: "XP Progress"
|
|
60
|
+
})
|
|
61
|
+
}), /* @__PURE__ */ jsxs(CardContent, { children: [/* @__PURE__ */ jsx("div", {
|
|
62
|
+
className: "text-3xl font-bold text-violet-500",
|
|
63
|
+
children: progress.xpEarned.toLocaleString()
|
|
64
|
+
}), /* @__PURE__ */ jsx(XpBar, {
|
|
65
|
+
current: progress.xpEarned,
|
|
66
|
+
max: totalXp,
|
|
67
|
+
showLabel: false,
|
|
68
|
+
size: "sm"
|
|
69
|
+
})] })] }),
|
|
70
|
+
/* @__PURE__ */ jsxs(Card, { children: [/* @__PURE__ */ jsx(CardHeader, {
|
|
71
|
+
className: "pb-2",
|
|
72
|
+
children: /* @__PURE__ */ jsx(CardTitle, {
|
|
73
|
+
className: "text-muted-foreground text-sm font-medium",
|
|
74
|
+
children: "Steps Completed"
|
|
75
|
+
})
|
|
76
|
+
}), /* @__PURE__ */ jsxs(CardContent, { children: [/* @__PURE__ */ jsxs("div", {
|
|
77
|
+
className: "text-3xl font-bold",
|
|
78
|
+
children: [
|
|
79
|
+
completedSteps,
|
|
80
|
+
" ",
|
|
81
|
+
/* @__PURE__ */ jsxs("span", {
|
|
82
|
+
className: "text-muted-foreground text-lg",
|
|
83
|
+
children: ["/ ", totalSteps]
|
|
84
|
+
})
|
|
85
|
+
]
|
|
86
|
+
}), /* @__PURE__ */ jsx("div", {
|
|
87
|
+
className: "bg-muted mt-2 h-2 w-full overflow-hidden rounded-full",
|
|
88
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
89
|
+
className: "h-full bg-green-500 transition-all duration-500",
|
|
90
|
+
style: { width: `${completedSteps / totalSteps * 100}%` }
|
|
91
|
+
})
|
|
92
|
+
})] })] }),
|
|
93
|
+
/* @__PURE__ */ jsxs(Card, { children: [/* @__PURE__ */ jsx(CardHeader, {
|
|
94
|
+
className: "pb-2",
|
|
95
|
+
children: /* @__PURE__ */ jsx(CardTitle, {
|
|
96
|
+
className: "text-muted-foreground text-sm font-medium",
|
|
97
|
+
children: "Badges Earned"
|
|
98
|
+
})
|
|
99
|
+
}), /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsx(BadgeDisplay, {
|
|
100
|
+
badges: progress.badges,
|
|
101
|
+
size: "lg"
|
|
102
|
+
}) })] })
|
|
103
|
+
]
|
|
104
|
+
}),
|
|
105
|
+
!isComplete && /* @__PURE__ */ jsxs(Card, { children: [/* @__PURE__ */ jsx(CardHeader, { children: /* @__PURE__ */ jsxs(CardTitle, {
|
|
106
|
+
className: "flex items-center gap-2",
|
|
107
|
+
children: [/* @__PURE__ */ jsx("span", { children: "🎯" }), /* @__PURE__ */ jsx("span", { children: "Next Challenge" })]
|
|
108
|
+
}) }), /* @__PURE__ */ jsx(CardContent, { children: (() => {
|
|
109
|
+
const nextStep = track.steps.find((s) => !progress.completedStepIds.includes(s.id));
|
|
110
|
+
if (!nextStep) return null;
|
|
111
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
112
|
+
className: "flex items-center justify-between gap-4",
|
|
113
|
+
children: [/* @__PURE__ */ jsxs("div", { children: [/* @__PURE__ */ jsx("h3", {
|
|
114
|
+
className: "font-semibold",
|
|
115
|
+
children: nextStep.title
|
|
116
|
+
}), /* @__PURE__ */ jsx("p", {
|
|
117
|
+
className: "text-muted-foreground text-sm",
|
|
118
|
+
children: nextStep.description
|
|
119
|
+
})] }), /* @__PURE__ */ jsxs("div", {
|
|
120
|
+
className: "flex items-center gap-3",
|
|
121
|
+
children: [nextStep.xpReward && /* @__PURE__ */ jsxs("span", {
|
|
122
|
+
className: "rounded-full bg-green-500/10 px-3 py-1 text-sm font-semibold text-green-500",
|
|
123
|
+
children: [
|
|
124
|
+
"+",
|
|
125
|
+
nextStep.xpReward,
|
|
126
|
+
" XP"
|
|
127
|
+
]
|
|
128
|
+
}), /* @__PURE__ */ jsx(Button$1, {
|
|
129
|
+
onClick: onStart,
|
|
130
|
+
children: "Start"
|
|
131
|
+
})]
|
|
132
|
+
})]
|
|
133
|
+
});
|
|
134
|
+
})() })] }),
|
|
135
|
+
isComplete && /* @__PURE__ */ jsx(Card, {
|
|
136
|
+
className: "border-green-500/50 bg-green-500/5",
|
|
137
|
+
children: /* @__PURE__ */ jsxs(CardContent, {
|
|
138
|
+
className: "flex items-center gap-4 p-6",
|
|
139
|
+
children: [/* @__PURE__ */ jsx("div", {
|
|
140
|
+
className: "text-4xl",
|
|
141
|
+
children: "🎉"
|
|
142
|
+
}), /* @__PURE__ */ jsxs("div", { children: [/* @__PURE__ */ jsx("h3", {
|
|
143
|
+
className: "text-lg font-semibold text-green-500",
|
|
144
|
+
children: "Track Complete!"
|
|
145
|
+
}), /* @__PURE__ */ jsxs("p", {
|
|
146
|
+
className: "text-muted-foreground",
|
|
147
|
+
children: [
|
|
148
|
+
"You've mastered all ",
|
|
149
|
+
totalSteps,
|
|
150
|
+
" challenges and earned",
|
|
151
|
+
" ",
|
|
152
|
+
progress.xpEarned,
|
|
153
|
+
" XP."
|
|
154
|
+
]
|
|
155
|
+
})] })]
|
|
156
|
+
})
|
|
157
|
+
})
|
|
158
|
+
]
|
|
159
|
+
});
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
//#endregion
|
|
163
|
+
export { Overview };
|
|
@@ -1 +1,144 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { Card, CardContent, CardHeader, CardTitle } from "../../../../libs/ui-kit-web/dist/ui/card.js";
|
|
4
|
+
import { XpBar } from "../../../learning-journey-ui-shared/src/components/XpBar.js";
|
|
5
|
+
import { BadgeDisplay } from "../../../learning-journey-ui-shared/src/components/BadgeDisplay.js";
|
|
6
|
+
import "../../../learning-journey-ui-shared/src/index.js";
|
|
7
|
+
import { MasteryRing } from "../components/MasteryRing.js";
|
|
8
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
9
|
+
|
|
10
|
+
//#region ../learning-journey-ui-gamified/src/views/Progress.tsx
|
|
11
|
+
function Progress({ track, progress }) {
|
|
12
|
+
const totalXp = track.totalXp ?? track.steps.reduce((sum, s) => sum + (s.xpReward ?? 0), 0) + (track.completionRewards?.xpBonus ?? 0);
|
|
13
|
+
const completedSteps = progress.completedStepIds.length;
|
|
14
|
+
const totalSteps = track.steps.length;
|
|
15
|
+
const percentComplete = totalSteps > 0 ? completedSteps / totalSteps * 100 : 0;
|
|
16
|
+
const surfaces = /* @__PURE__ */ new Map();
|
|
17
|
+
track.steps.forEach((step) => {
|
|
18
|
+
const surface = step.metadata?.surface ?? "general";
|
|
19
|
+
const current = surfaces.get(surface) ?? {
|
|
20
|
+
total: 0,
|
|
21
|
+
completed: 0
|
|
22
|
+
};
|
|
23
|
+
surfaces.set(surface, {
|
|
24
|
+
total: current.total + 1,
|
|
25
|
+
completed: current.completed + (progress.completedStepIds.includes(step.id) ? 1 : 0)
|
|
26
|
+
});
|
|
27
|
+
});
|
|
28
|
+
const surfaceColors = [
|
|
29
|
+
"green",
|
|
30
|
+
"blue",
|
|
31
|
+
"violet",
|
|
32
|
+
"orange"
|
|
33
|
+
];
|
|
34
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
35
|
+
className: "space-y-6",
|
|
36
|
+
children: [
|
|
37
|
+
/* @__PURE__ */ jsxs(Card, { children: [/* @__PURE__ */ jsx(CardHeader, { children: /* @__PURE__ */ jsxs(CardTitle, {
|
|
38
|
+
className: "flex items-center gap-2",
|
|
39
|
+
children: [/* @__PURE__ */ jsx("span", { children: "⚡" }), /* @__PURE__ */ jsx("span", { children: "Experience Points" })]
|
|
40
|
+
}) }), /* @__PURE__ */ jsxs(CardContent, {
|
|
41
|
+
className: "space-y-4",
|
|
42
|
+
children: [
|
|
43
|
+
/* @__PURE__ */ jsxs("div", {
|
|
44
|
+
className: "flex items-baseline gap-2",
|
|
45
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
46
|
+
className: "text-4xl font-bold text-violet-500",
|
|
47
|
+
children: progress.xpEarned.toLocaleString()
|
|
48
|
+
}), /* @__PURE__ */ jsxs("span", {
|
|
49
|
+
className: "text-muted-foreground",
|
|
50
|
+
children: [
|
|
51
|
+
"/ ",
|
|
52
|
+
totalXp.toLocaleString(),
|
|
53
|
+
" XP"
|
|
54
|
+
]
|
|
55
|
+
})]
|
|
56
|
+
}),
|
|
57
|
+
/* @__PURE__ */ jsx(XpBar, {
|
|
58
|
+
current: progress.xpEarned,
|
|
59
|
+
max: totalXp,
|
|
60
|
+
showLabel: false,
|
|
61
|
+
size: "lg"
|
|
62
|
+
}),
|
|
63
|
+
track.completionRewards?.xpBonus && percentComplete < 100 && /* @__PURE__ */ jsxs("p", {
|
|
64
|
+
className: "text-muted-foreground text-sm",
|
|
65
|
+
children: [
|
|
66
|
+
"🎁 Complete all steps for a",
|
|
67
|
+
" ",
|
|
68
|
+
/* @__PURE__ */ jsxs("span", {
|
|
69
|
+
className: "font-semibold text-green-500",
|
|
70
|
+
children: [
|
|
71
|
+
"+",
|
|
72
|
+
track.completionRewards.xpBonus,
|
|
73
|
+
" XP"
|
|
74
|
+
]
|
|
75
|
+
}),
|
|
76
|
+
" ",
|
|
77
|
+
"bonus!"
|
|
78
|
+
]
|
|
79
|
+
})
|
|
80
|
+
]
|
|
81
|
+
})] }),
|
|
82
|
+
/* @__PURE__ */ jsxs(Card, { children: [/* @__PURE__ */ jsx(CardHeader, { children: /* @__PURE__ */ jsxs(CardTitle, {
|
|
83
|
+
className: "flex items-center gap-2",
|
|
84
|
+
children: [/* @__PURE__ */ jsx("span", { children: "🎯" }), /* @__PURE__ */ jsx("span", { children: "Skill Mastery" })]
|
|
85
|
+
}) }), /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsxs("div", {
|
|
86
|
+
className: "flex flex-wrap justify-center gap-6",
|
|
87
|
+
children: [Array.from(surfaces.entries()).map(([surface, data], index) => /* @__PURE__ */ jsx(MasteryRing, {
|
|
88
|
+
label: surface.charAt(0).toUpperCase() + surface.slice(1),
|
|
89
|
+
percentage: data.completed / data.total * 100,
|
|
90
|
+
color: surfaceColors[index % surfaceColors.length],
|
|
91
|
+
size: "lg"
|
|
92
|
+
}, surface)), /* @__PURE__ */ jsx(MasteryRing, {
|
|
93
|
+
label: "Overall",
|
|
94
|
+
percentage: percentComplete,
|
|
95
|
+
color: "violet",
|
|
96
|
+
size: "lg"
|
|
97
|
+
})]
|
|
98
|
+
}) })] }),
|
|
99
|
+
/* @__PURE__ */ jsxs(Card, { children: [/* @__PURE__ */ jsx(CardHeader, { children: /* @__PURE__ */ jsxs(CardTitle, {
|
|
100
|
+
className: "flex items-center gap-2",
|
|
101
|
+
children: [/* @__PURE__ */ jsx("span", { children: "🏅" }), /* @__PURE__ */ jsx("span", { children: "Badges Earned" })]
|
|
102
|
+
}) }), /* @__PURE__ */ jsxs(CardContent, { children: [/* @__PURE__ */ jsx(BadgeDisplay, {
|
|
103
|
+
badges: progress.badges,
|
|
104
|
+
size: "lg",
|
|
105
|
+
maxVisible: 10
|
|
106
|
+
}), progress.badges.length === 0 && /* @__PURE__ */ jsx("p", {
|
|
107
|
+
className: "text-muted-foreground text-sm",
|
|
108
|
+
children: "Complete the track to earn your first badge!"
|
|
109
|
+
})] })] }),
|
|
110
|
+
/* @__PURE__ */ jsxs(Card, { children: [/* @__PURE__ */ jsx(CardHeader, { children: /* @__PURE__ */ jsxs(CardTitle, {
|
|
111
|
+
className: "flex items-center gap-2",
|
|
112
|
+
children: [/* @__PURE__ */ jsx("span", { children: "📊" }), /* @__PURE__ */ jsx("span", { children: "Step Breakdown" })]
|
|
113
|
+
}) }), /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsx("div", {
|
|
114
|
+
className: "space-y-2",
|
|
115
|
+
children: track.steps.map((step) => {
|
|
116
|
+
const isCompleted = progress.completedStepIds.includes(step.id);
|
|
117
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
118
|
+
className: "flex items-center justify-between rounded-lg border p-3",
|
|
119
|
+
children: [/* @__PURE__ */ jsxs("div", {
|
|
120
|
+
className: "flex items-center gap-3",
|
|
121
|
+
children: [/* @__PURE__ */ jsx("span", {
|
|
122
|
+
className: isCompleted ? "text-green-500" : "text-muted-foreground",
|
|
123
|
+
children: isCompleted ? "✓" : "○"
|
|
124
|
+
}), /* @__PURE__ */ jsx("span", {
|
|
125
|
+
className: isCompleted ? "text-foreground" : "text-muted-foreground",
|
|
126
|
+
children: step.title
|
|
127
|
+
})]
|
|
128
|
+
}), step.xpReward && /* @__PURE__ */ jsxs("span", {
|
|
129
|
+
className: `text-sm font-medium ${isCompleted ? "text-green-500" : "text-muted-foreground"}`,
|
|
130
|
+
children: [
|
|
131
|
+
isCompleted ? "+" : "",
|
|
132
|
+
step.xpReward,
|
|
133
|
+
" XP"
|
|
134
|
+
]
|
|
135
|
+
})]
|
|
136
|
+
}, step.id);
|
|
137
|
+
})
|
|
138
|
+
}) })] })
|
|
139
|
+
]
|
|
140
|
+
});
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
//#endregion
|
|
144
|
+
export { Progress };
|
|
@@ -1 +1,55 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { FlashCard } from "../components/FlashCard.js";
|
|
4
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
|
+
|
|
6
|
+
//#region ../learning-journey-ui-gamified/src/views/Steps.tsx
|
|
7
|
+
function Steps({ track, progress, onStepComplete }) {
|
|
8
|
+
const currentStepIndex = track.steps.findIndex((s) => !progress.completedStepIds.includes(s.id));
|
|
9
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
10
|
+
className: "space-y-6",
|
|
11
|
+
children: [
|
|
12
|
+
/* @__PURE__ */ jsxs("div", {
|
|
13
|
+
className: "text-center",
|
|
14
|
+
children: [/* @__PURE__ */ jsx("h2", {
|
|
15
|
+
className: "text-xl font-bold",
|
|
16
|
+
children: "Complete Your Challenges"
|
|
17
|
+
}), /* @__PURE__ */ jsx("p", {
|
|
18
|
+
className: "text-muted-foreground",
|
|
19
|
+
children: "Tap each card to reveal the action, then mark as complete"
|
|
20
|
+
})]
|
|
21
|
+
}),
|
|
22
|
+
/* @__PURE__ */ jsx("div", {
|
|
23
|
+
className: "grid gap-4 md:grid-cols-2",
|
|
24
|
+
children: track.steps.map((step, index) => {
|
|
25
|
+
return /* @__PURE__ */ jsx(FlashCard, {
|
|
26
|
+
step,
|
|
27
|
+
isCompleted: progress.completedStepIds.includes(step.id),
|
|
28
|
+
isCurrent: index === currentStepIndex,
|
|
29
|
+
onComplete: () => onStepComplete?.(step.id)
|
|
30
|
+
}, step.id);
|
|
31
|
+
})
|
|
32
|
+
}),
|
|
33
|
+
/* @__PURE__ */ jsxs("div", {
|
|
34
|
+
className: "text-muted-foreground text-center text-sm",
|
|
35
|
+
children: [
|
|
36
|
+
progress.completedStepIds.length,
|
|
37
|
+
" of ",
|
|
38
|
+
track.steps.length,
|
|
39
|
+
" completed",
|
|
40
|
+
track.completionRewards?.xpBonus && /* @__PURE__ */ jsxs("span", {
|
|
41
|
+
className: "ml-2 text-green-500",
|
|
42
|
+
children: [
|
|
43
|
+
"(+",
|
|
44
|
+
track.completionRewards.xpBonus,
|
|
45
|
+
" XP bonus on completion)"
|
|
46
|
+
]
|
|
47
|
+
})
|
|
48
|
+
]
|
|
49
|
+
})
|
|
50
|
+
]
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
//#endregion
|
|
55
|
+
export { Steps };
|
|
@@ -1 +1,132 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { Card, CardContent, CardHeader, CardTitle } from "../../../../libs/ui-kit-web/dist/ui/card.js";
|
|
4
|
+
import { DayCalendar } from "../components/DayCalendar.js";
|
|
5
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
6
|
+
|
|
7
|
+
//#region ../learning-journey-ui-gamified/src/views/Timeline.tsx
|
|
8
|
+
function Timeline({ track, progress }) {
|
|
9
|
+
if (track.steps.some((s) => s.availability?.unlockOnDay !== void 0)) {
|
|
10
|
+
const totalDays = Math.max(...track.steps.map((s) => s.availability?.unlockOnDay ?? 1), 7);
|
|
11
|
+
const completedDays = track.steps.filter((s) => progress.completedStepIds.includes(s.id)).map((s) => s.availability?.unlockOnDay ?? 1);
|
|
12
|
+
const currentDay = track.steps.find((s) => !progress.completedStepIds.includes(s.id))?.availability?.unlockOnDay ?? 1;
|
|
13
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
14
|
+
className: "space-y-6",
|
|
15
|
+
children: [
|
|
16
|
+
/* @__PURE__ */ jsxs("div", {
|
|
17
|
+
className: "text-center",
|
|
18
|
+
children: [/* @__PURE__ */ jsx("h2", {
|
|
19
|
+
className: "text-xl font-bold",
|
|
20
|
+
children: track.name
|
|
21
|
+
}), /* @__PURE__ */ jsx("p", {
|
|
22
|
+
className: "text-muted-foreground",
|
|
23
|
+
children: "Complete each day's challenge to progress"
|
|
24
|
+
})]
|
|
25
|
+
}),
|
|
26
|
+
/* @__PURE__ */ jsxs(Card, { children: [/* @__PURE__ */ jsx(CardHeader, { children: /* @__PURE__ */ jsxs(CardTitle, {
|
|
27
|
+
className: "flex items-center gap-2",
|
|
28
|
+
children: [/* @__PURE__ */ jsx("span", { children: "📅" }), /* @__PURE__ */ jsx("span", { children: "Your Journey" })]
|
|
29
|
+
}) }), /* @__PURE__ */ jsx(CardContent, {
|
|
30
|
+
className: "flex justify-center",
|
|
31
|
+
children: /* @__PURE__ */ jsx(DayCalendar, {
|
|
32
|
+
totalDays,
|
|
33
|
+
currentDay,
|
|
34
|
+
completedDays
|
|
35
|
+
})
|
|
36
|
+
})] }),
|
|
37
|
+
/* @__PURE__ */ jsxs(Card, { children: [/* @__PURE__ */ jsx(CardHeader, { children: /* @__PURE__ */ jsxs(CardTitle, {
|
|
38
|
+
className: "flex items-center gap-2",
|
|
39
|
+
children: [/* @__PURE__ */ jsx("span", { children: "📝" }), /* @__PURE__ */ jsx("span", { children: "Daily Challenges" })]
|
|
40
|
+
}) }), /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsx("div", {
|
|
41
|
+
className: "space-y-3",
|
|
42
|
+
children: track.steps.map((step) => {
|
|
43
|
+
const day = step.availability?.unlockOnDay ?? 1;
|
|
44
|
+
const isCompleted = progress.completedStepIds.includes(step.id);
|
|
45
|
+
const isLocked = day > currentDay;
|
|
46
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
47
|
+
className: `flex items-start gap-4 rounded-lg border p-4 ${isLocked ? "opacity-50" : ""}`,
|
|
48
|
+
children: [
|
|
49
|
+
/* @__PURE__ */ jsx("div", {
|
|
50
|
+
className: "bg-muted flex h-10 w-10 shrink-0 items-center justify-center rounded-lg font-semibold",
|
|
51
|
+
children: isCompleted ? "✓" : isLocked ? "🔒" : day
|
|
52
|
+
}),
|
|
53
|
+
/* @__PURE__ */ jsxs("div", {
|
|
54
|
+
className: "flex-1",
|
|
55
|
+
children: [/* @__PURE__ */ jsx("h4", {
|
|
56
|
+
className: "font-semibold",
|
|
57
|
+
children: step.title
|
|
58
|
+
}), /* @__PURE__ */ jsx("p", {
|
|
59
|
+
className: "text-muted-foreground text-sm",
|
|
60
|
+
children: step.description
|
|
61
|
+
})]
|
|
62
|
+
}),
|
|
63
|
+
step.xpReward && /* @__PURE__ */ jsxs("span", {
|
|
64
|
+
className: `text-sm font-medium ${isCompleted ? "text-green-500" : "text-muted-foreground"}`,
|
|
65
|
+
children: [
|
|
66
|
+
"+",
|
|
67
|
+
step.xpReward,
|
|
68
|
+
" XP"
|
|
69
|
+
]
|
|
70
|
+
})
|
|
71
|
+
]
|
|
72
|
+
}, step.id);
|
|
73
|
+
})
|
|
74
|
+
}) })] })
|
|
75
|
+
]
|
|
76
|
+
});
|
|
77
|
+
}
|
|
78
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
79
|
+
className: "space-y-6",
|
|
80
|
+
children: [/* @__PURE__ */ jsxs("div", {
|
|
81
|
+
className: "text-center",
|
|
82
|
+
children: [/* @__PURE__ */ jsx("h2", {
|
|
83
|
+
className: "text-xl font-bold",
|
|
84
|
+
children: "Learning Path"
|
|
85
|
+
}), /* @__PURE__ */ jsx("p", {
|
|
86
|
+
className: "text-muted-foreground",
|
|
87
|
+
children: "Follow the steps to master this skill"
|
|
88
|
+
})]
|
|
89
|
+
}), /* @__PURE__ */ jsx(Card, { children: /* @__PURE__ */ jsx(CardContent, {
|
|
90
|
+
className: "p-6",
|
|
91
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
92
|
+
className: "relative",
|
|
93
|
+
children: [/* @__PURE__ */ jsx("div", { className: "bg-border absolute top-0 left-5 h-full w-0.5" }), /* @__PURE__ */ jsx("div", {
|
|
94
|
+
className: "space-y-6",
|
|
95
|
+
children: track.steps.map((step, index) => {
|
|
96
|
+
const isCompleted = progress.completedStepIds.includes(step.id);
|
|
97
|
+
const isCurrent = !isCompleted && track.steps.slice(0, index).every((s) => progress.completedStepIds.includes(s.id));
|
|
98
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
99
|
+
className: "relative flex gap-4 pl-2",
|
|
100
|
+
children: [/* @__PURE__ */ jsx("div", {
|
|
101
|
+
className: `relative z-10 flex h-8 w-8 shrink-0 items-center justify-center rounded-full border-2 ${isCompleted ? "border-green-500 bg-green-500 text-white" : isCurrent ? "border-violet-500 bg-violet-500 text-white" : "border-border bg-background"}`,
|
|
102
|
+
children: isCompleted ? "✓" : index + 1
|
|
103
|
+
}), /* @__PURE__ */ jsx("div", {
|
|
104
|
+
className: "flex-1 pb-4",
|
|
105
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
106
|
+
className: "flex items-start justify-between gap-2",
|
|
107
|
+
children: [/* @__PURE__ */ jsxs("div", { children: [/* @__PURE__ */ jsx("h4", {
|
|
108
|
+
className: `font-semibold ${isCompleted ? "text-foreground" : isCurrent ? "text-violet-500" : "text-muted-foreground"}`,
|
|
109
|
+
children: step.title
|
|
110
|
+
}), /* @__PURE__ */ jsx("p", {
|
|
111
|
+
className: "text-muted-foreground mt-1 text-sm",
|
|
112
|
+
children: step.description
|
|
113
|
+
})] }), step.xpReward && /* @__PURE__ */ jsxs("span", {
|
|
114
|
+
className: `shrink-0 rounded-full px-2 py-1 text-xs font-semibold ${isCompleted ? "bg-green-500/10 text-green-500" : "bg-muted text-muted-foreground"}`,
|
|
115
|
+
children: [
|
|
116
|
+
"+",
|
|
117
|
+
step.xpReward,
|
|
118
|
+
" XP"
|
|
119
|
+
]
|
|
120
|
+
})]
|
|
121
|
+
})
|
|
122
|
+
})]
|
|
123
|
+
}, step.id);
|
|
124
|
+
})
|
|
125
|
+
})]
|
|
126
|
+
})
|
|
127
|
+
}) })]
|
|
128
|
+
});
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
//#endregion
|
|
132
|
+
export { Timeline };
|
|
@@ -1 +1,4 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import { Overview } from "./Overview.js";
|
|
2
|
+
import { Steps } from "./Steps.js";
|
|
3
|
+
import { Progress } from "./Progress.js";
|
|
4
|
+
import { Timeline } from "./Timeline.js";
|
|
@@ -1 +1,64 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { Card, CardContent } from "../../../libs/ui-kit-web/dist/ui/card.js";
|
|
4
|
+
import { useLearningProgress } from "../../learning-journey-ui-shared/src/hooks/useLearningProgress.js";
|
|
5
|
+
import { ViewTabs } from "../../learning-journey-ui-shared/src/components/ViewTabs.js";
|
|
6
|
+
import "../../learning-journey-ui-shared/src/index.js";
|
|
7
|
+
import { Overview } from "./views/Overview.js";
|
|
8
|
+
import { Steps } from "./views/Steps.js";
|
|
9
|
+
import { ProgressView } from "./views/Progress.js";
|
|
10
|
+
import { Timeline } from "./views/Timeline.js";
|
|
11
|
+
import { useCallback, useState } from "react";
|
|
12
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
13
|
+
|
|
14
|
+
//#region ../learning-journey-ui-onboarding/src/OnboardingMiniApp.tsx
|
|
15
|
+
function OnboardingMiniApp({ track, progress: externalProgress, onStepComplete: externalOnStepComplete, onViewChange, initialView = "overview" }) {
|
|
16
|
+
const [currentView, setCurrentView] = useState(initialView);
|
|
17
|
+
const { progress: internalProgress, completeStep: internalCompleteStep } = useLearningProgress(track);
|
|
18
|
+
const progress = externalProgress ?? internalProgress;
|
|
19
|
+
const handleViewChange = useCallback((view) => {
|
|
20
|
+
setCurrentView(view);
|
|
21
|
+
onViewChange?.(view);
|
|
22
|
+
}, [onViewChange]);
|
|
23
|
+
const handleStepComplete = useCallback((stepId) => {
|
|
24
|
+
if (externalOnStepComplete) externalOnStepComplete(stepId);
|
|
25
|
+
else internalCompleteStep(stepId);
|
|
26
|
+
}, [externalOnStepComplete, internalCompleteStep]);
|
|
27
|
+
const handleStartFromOverview = useCallback(() => {
|
|
28
|
+
setCurrentView("steps");
|
|
29
|
+
onViewChange?.("steps");
|
|
30
|
+
}, [onViewChange]);
|
|
31
|
+
const renderView = () => {
|
|
32
|
+
const viewProps = {
|
|
33
|
+
track,
|
|
34
|
+
progress,
|
|
35
|
+
onStepComplete: handleStepComplete
|
|
36
|
+
};
|
|
37
|
+
switch (currentView) {
|
|
38
|
+
case "overview": return /* @__PURE__ */ jsx(Overview, {
|
|
39
|
+
...viewProps,
|
|
40
|
+
onStart: handleStartFromOverview
|
|
41
|
+
});
|
|
42
|
+
case "steps": return /* @__PURE__ */ jsx(Steps, { ...viewProps });
|
|
43
|
+
case "progress": return /* @__PURE__ */ jsx(ProgressView, { ...viewProps });
|
|
44
|
+
case "timeline": return /* @__PURE__ */ jsx(Timeline, { ...viewProps });
|
|
45
|
+
default: return /* @__PURE__ */ jsx(Overview, {
|
|
46
|
+
...viewProps,
|
|
47
|
+
onStart: handleStartFromOverview
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
};
|
|
51
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
52
|
+
className: "space-y-6",
|
|
53
|
+
children: [/* @__PURE__ */ jsx(Card, { children: /* @__PURE__ */ jsx(CardContent, {
|
|
54
|
+
className: "p-4",
|
|
55
|
+
children: /* @__PURE__ */ jsx(ViewTabs, {
|
|
56
|
+
currentView,
|
|
57
|
+
onViewChange: handleViewChange
|
|
58
|
+
})
|
|
59
|
+
}) }), renderView()]
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
//#endregion
|
|
64
|
+
export { OnboardingMiniApp };
|
|
@@ -1 +1,48 @@
|
|
|
1
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
|
|
3
|
+
import { cn } from "../../../../libs/ui-kit-web/dist/ui/utils.js";
|
|
4
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
|
+
|
|
6
|
+
//#region ../learning-journey-ui-onboarding/src/components/JourneyMap.tsx
|
|
7
|
+
const SURFACE_ICONS = {
|
|
8
|
+
templates: "📋",
|
|
9
|
+
"spec-editor": "✏️",
|
|
10
|
+
regenerator: "🔄",
|
|
11
|
+
playground: "🎮",
|
|
12
|
+
evolution: "🤖",
|
|
13
|
+
dashboard: "📊",
|
|
14
|
+
settings: "⚙️",
|
|
15
|
+
default: "📍"
|
|
16
|
+
};
|
|
17
|
+
function JourneyMap({ steps, completedStepIds, currentStepId }) {
|
|
18
|
+
return /* @__PURE__ */ jsx("div", {
|
|
19
|
+
className: "relative overflow-x-auto pb-4",
|
|
20
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
21
|
+
className: "flex min-w-max items-center gap-2",
|
|
22
|
+
children: steps.map((step, index) => {
|
|
23
|
+
const isCompleted = completedStepIds.includes(step.id);
|
|
24
|
+
const isCurrent = step.id === currentStepId;
|
|
25
|
+
const icon = SURFACE_ICONS[step.metadata?.surface ?? "default"] ?? SURFACE_ICONS.default;
|
|
26
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
27
|
+
className: "flex items-center",
|
|
28
|
+
children: [/* @__PURE__ */ jsxs("div", {
|
|
29
|
+
className: "flex flex-col items-center gap-2",
|
|
30
|
+
children: [/* @__PURE__ */ jsx("div", {
|
|
31
|
+
className: cn("flex h-14 w-14 items-center justify-center rounded-2xl border-2 text-2xl transition-all", isCompleted && "border-green-500 bg-green-500/10", isCurrent && !isCompleted && "border-violet-500 bg-violet-500/10 ring-4 ring-violet-500/20", !isCompleted && !isCurrent && "border-muted bg-muted/50"),
|
|
32
|
+
children: isCompleted ? "✓" : icon
|
|
33
|
+
}), /* @__PURE__ */ jsx("div", {
|
|
34
|
+
className: "text-center",
|
|
35
|
+
children: /* @__PURE__ */ jsx("p", {
|
|
36
|
+
className: cn("max-w-[100px] truncate text-xs font-medium", isCompleted && "text-green-500", isCurrent && !isCompleted && "text-violet-500", !isCompleted && !isCurrent && "text-muted-foreground"),
|
|
37
|
+
children: step.title
|
|
38
|
+
})
|
|
39
|
+
})]
|
|
40
|
+
}), index < steps.length - 1 && /* @__PURE__ */ jsx("div", { className: cn("mx-2 h-1 w-8 rounded-full transition-colors", completedStepIds.includes(steps[index + 1]?.id ?? "") ? "bg-green-500" : isCompleted ? "bg-green-500/50" : "bg-muted") })]
|
|
41
|
+
}, step.id);
|
|
42
|
+
})
|
|
43
|
+
})
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
//#endregion
|
|
48
|
+
export { JourneyMap };
|