@contractspec/example.learning-journey-ui-shared 0.0.0-canary-20260113170453

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 (60) hide show
  1. package/.turbo/turbo-build$colon$bundle.log +48 -0
  2. package/.turbo/turbo-build.log +49 -0
  3. package/CHANGELOG.md +379 -0
  4. package/LICENSE +21 -0
  5. package/README.md +42 -0
  6. package/dist/components/BadgeDisplay.d.ts +12 -0
  7. package/dist/components/BadgeDisplay.d.ts.map +1 -0
  8. package/dist/components/BadgeDisplay.js +45 -0
  9. package/dist/components/BadgeDisplay.js.map +1 -0
  10. package/dist/components/StreakCounter.d.ts +12 -0
  11. package/dist/components/StreakCounter.d.ts.map +1 -0
  12. package/dist/components/StreakCounter.js +46 -0
  13. package/dist/components/StreakCounter.js.map +1 -0
  14. package/dist/components/ViewTabs.d.ts +12 -0
  15. package/dist/components/ViewTabs.d.ts.map +1 -0
  16. package/dist/components/ViewTabs.js +49 -0
  17. package/dist/components/ViewTabs.js.map +1 -0
  18. package/dist/components/XpBar.d.ts +14 -0
  19. package/dist/components/XpBar.d.ts.map +1 -0
  20. package/dist/components/XpBar.js +47 -0
  21. package/dist/components/XpBar.js.map +1 -0
  22. package/dist/components/index.d.ts +5 -0
  23. package/dist/components/index.js +6 -0
  24. package/dist/docs/index.d.ts +1 -0
  25. package/dist/docs/index.js +1 -0
  26. package/dist/docs/learning-journey-ui-shared.docblock.d.ts +1 -0
  27. package/dist/docs/learning-journey-ui-shared.docblock.js +20 -0
  28. package/dist/docs/learning-journey-ui-shared.docblock.js.map +1 -0
  29. package/dist/example.d.ts +7 -0
  30. package/dist/example.d.ts.map +1 -0
  31. package/dist/example.js +42 -0
  32. package/dist/example.js.map +1 -0
  33. package/dist/hooks/index.d.ts +2 -0
  34. package/dist/hooks/index.js +3 -0
  35. package/dist/hooks/useLearningProgress.d.ts +22 -0
  36. package/dist/hooks/useLearningProgress.d.ts.map +1 -0
  37. package/dist/hooks/useLearningProgress.js +74 -0
  38. package/dist/hooks/useLearningProgress.js.map +1 -0
  39. package/dist/index.d.ts +9 -0
  40. package/dist/index.js +11 -0
  41. package/dist/types.d.ts +58 -0
  42. package/dist/types.d.ts.map +1 -0
  43. package/dist/types.js +0 -0
  44. package/example.ts +1 -0
  45. package/package.json +72 -0
  46. package/src/components/BadgeDisplay.tsx +65 -0
  47. package/src/components/StreakCounter.tsx +49 -0
  48. package/src/components/ViewTabs.tsx +46 -0
  49. package/src/components/XpBar.tsx +54 -0
  50. package/src/components/index.ts +4 -0
  51. package/src/docs/index.ts +1 -0
  52. package/src/docs/learning-journey-ui-shared.docblock.ts +17 -0
  53. package/src/example.ts +31 -0
  54. package/src/hooks/index.ts +1 -0
  55. package/src/hooks/useLearningProgress.ts +101 -0
  56. package/src/index.ts +20 -0
  57. package/src/types.ts +61 -0
  58. package/tsconfig.json +9 -0
  59. package/tsconfig.tsbuildinfo +1 -0
  60. package/tsdown.config.js +17 -0
@@ -0,0 +1,48 @@
1
+ $ tsdown
2
+ ℹ tsdown v0.19.0 powered by rolldown v1.0.0-beta.59
3
+ ℹ config file: /home/runner/work/contractspec/contractspec/packages/examples/learning-journey-ui-shared/tsdown.config.js
4
+ ℹ entry: src/example.ts, src/index.ts, src/types.ts, src/components/BadgeDisplay.tsx, src/components/StreakCounter.tsx, src/components/ViewTabs.tsx, src/components/XpBar.tsx, src/components/index.ts, src/docs/index.ts, src/docs/learning-journey-ui-shared.docblock.ts, src/hooks/index.ts, src/hooks/useLearningProgress.ts
5
+ ℹ target: esnext
6
+ ℹ tsconfig: tsconfig.json
7
+ ℹ Build start
8
+ ℹ Cleaning 41 files
9
+ ℹ dist/hooks/useLearningProgress.js 2.54 kB │ gzip: 0.90 kB
10
+ ℹ dist/components/BadgeDisplay.js 1.51 kB │ gzip: 0.78 kB
11
+ ℹ dist/components/XpBar.js 1.31 kB │ gzip: 0.63 kB
12
+ ℹ dist/components/StreakCounter.js 1.11 kB │ gzip: 0.59 kB
13
+ ℹ dist/components/ViewTabs.js 1.10 kB │ gzip: 0.59 kB
14
+ ℹ dist/example.js 0.94 kB │ gzip: 0.51 kB
15
+ ℹ dist/docs/learning-journey-ui-shared.docblock.js 0.77 kB │ gzip: 0.45 kB
16
+ ℹ dist/index.js 0.53 kB │ gzip: 0.21 kB
17
+ ℹ dist/components/index.js 0.24 kB │ gzip: 0.12 kB
18
+ ℹ dist/hooks/index.js 0.10 kB │ gzip: 0.07 kB
19
+ ℹ dist/docs/index.js 0.05 kB │ gzip: 0.07 kB
20
+ ℹ dist/types.js 0.00 kB │ gzip: 0.02 kB
21
+ ℹ dist/hooks/useLearningProgress.js.map 4.65 kB │ gzip: 1.63 kB
22
+ ℹ dist/components/BadgeDisplay.js.map 2.37 kB │ gzip: 1.14 kB
23
+ ℹ dist/components/XpBar.js.map 1.92 kB │ gzip: 0.90 kB
24
+ ℹ dist/components/ViewTabs.js.map 1.82 kB │ gzip: 0.87 kB
25
+ ℹ dist/components/StreakCounter.js.map 1.64 kB │ gzip: 0.79 kB
26
+ ℹ dist/example.js.map 1.37 kB │ gzip: 0.70 kB
27
+ ℹ dist/docs/learning-journey-ui-shared.docblock.js.map 1.09 kB │ gzip: 0.60 kB
28
+ ℹ dist/types.d.ts.map 0.65 kB │ gzip: 0.33 kB
29
+ ℹ dist/hooks/useLearningProgress.d.ts.map 0.19 kB │ gzip: 0.16 kB
30
+ ℹ dist/components/StreakCounter.d.ts.map 0.19 kB │ gzip: 0.16 kB
31
+ ℹ dist/components/BadgeDisplay.d.ts.map 0.19 kB │ gzip: 0.16 kB
32
+ ℹ dist/components/ViewTabs.d.ts.map 0.18 kB │ gzip: 0.16 kB
33
+ ℹ dist/components/XpBar.d.ts.map 0.17 kB │ gzip: 0.15 kB
34
+ ℹ dist/example.d.ts.map 0.14 kB │ gzip: 0.13 kB
35
+ ℹ dist/types.d.ts 1.70 kB │ gzip: 0.61 kB
36
+ ℹ dist/index.d.ts 0.81 kB │ gzip: 0.25 kB
37
+ ℹ dist/hooks/useLearningProgress.d.ts 0.72 kB │ gzip: 0.35 kB
38
+ ℹ dist/components/StreakCounter.d.ts 0.35 kB │ gzip: 0.23 kB
39
+ ℹ dist/components/BadgeDisplay.d.ts 0.35 kB │ gzip: 0.23 kB
40
+ ℹ dist/components/ViewTabs.d.ts 0.34 kB │ gzip: 0.23 kB
41
+ ℹ dist/components/XpBar.d.ts 0.32 kB │ gzip: 0.23 kB
42
+ ℹ dist/example.d.ts 0.25 kB │ gzip: 0.17 kB
43
+ ℹ dist/components/index.d.ts 0.24 kB │ gzip: 0.12 kB
44
+ ℹ dist/hooks/index.d.ts 0.10 kB │ gzip: 0.07 kB
45
+ ℹ dist/docs/index.d.ts 0.01 kB │ gzip: 0.03 kB
46
+ ℹ dist/docs/learning-journey-ui-shared.docblock.d.ts 0.01 kB │ gzip: 0.03 kB
47
+ ℹ 38 files, total: 31.97 kB
48
+ ✔ Build complete in 22227ms
@@ -0,0 +1,49 @@
1
+ $ bun build:types && bun build:bundle
2
+ $ tsc --noEmit
3
+ $ tsdown
4
+ ℹ tsdown v0.19.0 powered by rolldown v1.0.0-beta.59
5
+ ℹ config file: /home/runner/work/contractspec/contractspec/packages/examples/learning-journey-ui-shared/tsdown.config.js
6
+ ℹ entry: src/example.ts, src/index.ts, src/types.ts, src/components/BadgeDisplay.tsx, src/components/StreakCounter.tsx, src/components/ViewTabs.tsx, src/components/XpBar.tsx, src/components/index.ts, src/docs/index.ts, src/docs/learning-journey-ui-shared.docblock.ts, src/hooks/index.ts, src/hooks/useLearningProgress.ts
7
+ ℹ target: esnext
8
+ ℹ tsconfig: tsconfig.json
9
+ ℹ Build start
10
+ ℹ dist/hooks/useLearningProgress.js 2.54 kB │ gzip: 0.90 kB
11
+ ℹ dist/components/BadgeDisplay.js 1.51 kB │ gzip: 0.78 kB
12
+ ℹ dist/components/XpBar.js 1.31 kB │ gzip: 0.63 kB
13
+ ℹ dist/components/StreakCounter.js 1.11 kB │ gzip: 0.59 kB
14
+ ℹ dist/components/ViewTabs.js 1.10 kB │ gzip: 0.59 kB
15
+ ℹ dist/example.js 0.94 kB │ gzip: 0.51 kB
16
+ ℹ dist/docs/learning-journey-ui-shared.docblock.js 0.77 kB │ gzip: 0.45 kB
17
+ ℹ dist/index.js 0.53 kB │ gzip: 0.21 kB
18
+ ℹ dist/components/index.js 0.24 kB │ gzip: 0.12 kB
19
+ ℹ dist/hooks/index.js 0.10 kB │ gzip: 0.07 kB
20
+ ℹ dist/docs/index.js 0.05 kB │ gzip: 0.07 kB
21
+ ℹ dist/types.js 0.00 kB │ gzip: 0.02 kB
22
+ ℹ dist/hooks/useLearningProgress.js.map 4.65 kB │ gzip: 1.63 kB
23
+ ℹ dist/components/BadgeDisplay.js.map 2.37 kB │ gzip: 1.14 kB
24
+ ℹ dist/components/XpBar.js.map 1.92 kB │ gzip: 0.90 kB
25
+ ℹ dist/components/ViewTabs.js.map 1.82 kB │ gzip: 0.87 kB
26
+ ℹ dist/components/StreakCounter.js.map 1.64 kB │ gzip: 0.79 kB
27
+ ℹ dist/example.js.map 1.37 kB │ gzip: 0.70 kB
28
+ ℹ dist/docs/learning-journey-ui-shared.docblock.js.map 1.09 kB │ gzip: 0.60 kB
29
+ ℹ dist/types.d.ts.map 0.65 kB │ gzip: 0.33 kB
30
+ ℹ dist/hooks/useLearningProgress.d.ts.map 0.19 kB │ gzip: 0.16 kB
31
+ ℹ dist/components/StreakCounter.d.ts.map 0.19 kB │ gzip: 0.16 kB
32
+ ℹ dist/components/BadgeDisplay.d.ts.map 0.19 kB │ gzip: 0.16 kB
33
+ ℹ dist/components/ViewTabs.d.ts.map 0.18 kB │ gzip: 0.16 kB
34
+ ℹ dist/components/XpBar.d.ts.map 0.17 kB │ gzip: 0.15 kB
35
+ ℹ dist/example.d.ts.map 0.14 kB │ gzip: 0.13 kB
36
+ ℹ dist/types.d.ts 1.70 kB │ gzip: 0.61 kB
37
+ ℹ dist/index.d.ts 0.81 kB │ gzip: 0.25 kB
38
+ ℹ dist/hooks/useLearningProgress.d.ts 0.72 kB │ gzip: 0.35 kB
39
+ ℹ dist/components/StreakCounter.d.ts 0.35 kB │ gzip: 0.23 kB
40
+ ℹ dist/components/BadgeDisplay.d.ts 0.35 kB │ gzip: 0.23 kB
41
+ ℹ dist/components/ViewTabs.d.ts 0.34 kB │ gzip: 0.23 kB
42
+ ℹ dist/components/XpBar.d.ts 0.32 kB │ gzip: 0.23 kB
43
+ ℹ dist/example.d.ts 0.25 kB │ gzip: 0.17 kB
44
+ ℹ dist/components/index.d.ts 0.24 kB │ gzip: 0.12 kB
45
+ ℹ dist/hooks/index.d.ts 0.10 kB │ gzip: 0.07 kB
46
+ ℹ dist/docs/index.d.ts 0.01 kB │ gzip: 0.03 kB
47
+ ℹ dist/docs/learning-journey-ui-shared.docblock.d.ts 0.01 kB │ gzip: 0.03 kB
48
+ ℹ 38 files, total: 31.97 kB
49
+ ✔ Build complete in 22306ms
package/CHANGELOG.md ADDED
@@ -0,0 +1,379 @@
1
+ # @contractspec/example.learning-journey-ui-shared
2
+
3
+ ## 0.0.0-canary-20260113170453
4
+
5
+ ### Minor Changes
6
+
7
+ - caf8701: feat: add cli vibe command to run workflow
8
+ - c69b849: feat: add api web services (mcp & website)
9
+ - 42b8d78: feat: add cli `contractspec vibe` workflow to simplify usage
10
+ - fd38e85: feat: auto-fix contractspec issues
11
+
12
+ ### Patch Changes
13
+
14
+ - e7ded36: feat: improve stability (adding ts-morph)
15
+ - c231a8b: test: improve workspace stability
16
+ - Updated dependencies [e7ded36]
17
+ - Updated dependencies [caf8701]
18
+ - Updated dependencies [c69b849]
19
+ - Updated dependencies [c231a8b]
20
+ - Updated dependencies [42b8d78]
21
+ - Updated dependencies [fd38e85]
22
+ - @contractspec/module.learning-journey@0.0.0-canary-20260113170453
23
+ - @contractspec/lib.design-system@0.0.0-canary-20260113170453
24
+ - @contractspec/lib.ui-kit-web@0.0.0-canary-20260113170453
25
+ - @contractspec/lib.contracts@0.0.0-canary-20260113170453
26
+
27
+ ## 1.46.2
28
+
29
+ ### Patch Changes
30
+
31
+ - 7e21625: feat: library services (landing page & api)
32
+ - Updated dependencies [7e21625]
33
+ - @contractspec/module.learning-journey@1.46.2
34
+ - @contractspec/lib.design-system@1.46.2
35
+ - @contractspec/lib.ui-kit-web@1.46.2
36
+ - @contractspec/lib.contracts@1.46.2
37
+
38
+ ## 1.46.1
39
+
40
+ ### Patch Changes
41
+
42
+ - 2d8a72b: fix: mcp for presentation
43
+ - Updated dependencies [2d8a72b]
44
+ - @contractspec/module.learning-journey@1.46.1
45
+ - @contractspec/lib.design-system@1.46.1
46
+ - @contractspec/lib.ui-kit-web@1.46.1
47
+ - @contractspec/lib.contracts@1.46.1
48
+
49
+ ## 1.46.0
50
+
51
+ ### Minor Changes
52
+
53
+ - 07cb19b: feat: feat: cleaude code & opencode integrations
54
+
55
+ ### Patch Changes
56
+
57
+ - Updated dependencies [07cb19b]
58
+ - @contractspec/module.learning-journey@1.46.0
59
+ - @contractspec/lib.design-system@1.46.0
60
+ - @contractspec/lib.ui-kit-web@1.46.0
61
+ - @contractspec/lib.contracts@1.46.0
62
+
63
+ ## 1.45.6
64
+
65
+ ### Patch Changes
66
+
67
+ - a913074: feat: improve ai agents rules management"
68
+ - Updated dependencies [a913074]
69
+ - @contractspec/module.learning-journey@1.45.6
70
+ - @contractspec/lib.design-system@1.45.6
71
+ - @contractspec/lib.ui-kit-web@1.45.6
72
+ - @contractspec/lib.contracts@1.45.6
73
+
74
+ ## 1.45.5
75
+
76
+ ### Patch Changes
77
+
78
+ - 9ddd7fa: feat: improve versioning
79
+ - Updated dependencies [9ddd7fa]
80
+ - @contractspec/module.learning-journey@1.45.5
81
+ - @contractspec/lib.design-system@1.45.5
82
+ - @contractspec/lib.ui-kit-web@1.45.5
83
+ - @contractspec/lib.contracts@1.45.5
84
+
85
+ ## 1.45.4
86
+
87
+ ### Patch Changes
88
+
89
+ - fix: github action
90
+ - Updated dependencies
91
+ - @contractspec/module.learning-journey@1.45.4
92
+ - @contractspec/lib.design-system@1.45.4
93
+ - @contractspec/lib.ui-kit-web@1.45.4
94
+ - @contractspec/lib.contracts@1.45.4
95
+
96
+ ## 1.45.3
97
+
98
+ ### Patch Changes
99
+
100
+ - e74ea9e: feat: version management
101
+ - Updated dependencies [e74ea9e]
102
+ - @contractspec/module.learning-journey@1.45.3
103
+ - @contractspec/lib.design-system@1.45.3
104
+ - @contractspec/lib.ui-kit-web@1.45.3
105
+ - @contractspec/lib.contracts@1.45.3
106
+
107
+ ## 1.45.2
108
+
109
+ ### Patch Changes
110
+
111
+ - 39ca241: code cleaning
112
+ - Updated dependencies [39ca241]
113
+ - @contractspec/module.learning-journey@1.45.2
114
+ - @contractspec/lib.design-system@1.45.2
115
+ - @contractspec/lib.ui-kit-web@1.45.2
116
+ - @contractspec/lib.contracts@1.45.2
117
+
118
+ ## 1.45.1
119
+
120
+ ### Patch Changes
121
+
122
+ - feat: improve app config and examples contracts
123
+ - Updated dependencies
124
+ - @contractspec/module.learning-journey@1.45.1
125
+ - @contractspec/lib.design-system@1.45.1
126
+ - @contractspec/lib.ui-kit-web@1.45.1
127
+ - @contractspec/lib.contracts@1.45.1
128
+ - @contractspec/lib.schema@1.45.1
129
+
130
+ ## 1.45.0
131
+
132
+ ### Minor Changes
133
+
134
+ - e73ca1d: feat: improve app config and examples contracts
135
+ feat: Contract layers support (features, examples, app-configs)
136
+
137
+ ### New CLI Commands
138
+ - `contractspec list layers` - List all contract layers with filtering
139
+
140
+ ### Enhanced Commands
141
+ - `contractspec ci` - New `layers` check category validates features/examples/config
142
+ - `contractspec doctor` - New `layers` health checks
143
+ - `contractspec integrity` - Now shows layer statistics
144
+
145
+ ### New APIs
146
+ - `discoverLayers()` - Scan workspace for all layer files
147
+ - `scanExampleSource()` - Parse ExampleSpec from source code
148
+ - `isExampleFile()` - Check if file is an example spec
149
+
150
+ ### Patch Changes
151
+
152
+ - Updated dependencies [e73ca1d]
153
+ - @contractspec/module.learning-journey@1.45.0
154
+ - @contractspec/lib.design-system@1.45.0
155
+ - @contractspec/lib.ui-kit-web@1.45.0
156
+ - @contractspec/lib.contracts@1.45.0
157
+ - @contractspec/lib.schema@1.45.0
158
+
159
+ ## 1.44.1
160
+
161
+ ### Patch Changes
162
+
163
+ - 3c594fb: fix
164
+ - Updated dependencies [3c594fb]
165
+ - @contractspec/module.learning-journey@1.44.1
166
+ - @contractspec/lib.design-system@1.44.1
167
+ - @contractspec/lib.ui-kit-web@1.44.1
168
+ - @contractspec/lib.contracts@1.44.1
169
+ - @contractspec/lib.schema@1.44.1
170
+
171
+ ## 1.44.0
172
+
173
+ ### Minor Changes
174
+
175
+ - 5f3a868: chore: isolate branding to contractspec.io
176
+
177
+ ### Patch Changes
178
+
179
+ - Updated dependencies [5f3a868]
180
+ - @contractspec/module.learning-journey@1.44.0
181
+ - @contractspec/lib.design-system@1.44.0
182
+ - @contractspec/lib.ui-kit-web@1.44.0
183
+ - @contractspec/lib.contracts@1.44.0
184
+ - @contractspec/lib.schema@1.44.0
185
+
186
+ ## 1.43.4
187
+
188
+ ### Patch Changes
189
+
190
+ - 9216062: fix: cross-platform compatibility
191
+ - Updated dependencies [9216062]
192
+ - @contractspec/module.learning-journey@1.43.4
193
+ - @contractspec/lib.design-system@1.43.4
194
+ - @contractspec/lib.ui-kit-web@1.43.3
195
+ - @contractspec/lib.contracts@1.43.4
196
+ - @contractspec/lib.schema@1.43.3
197
+
198
+ ## 1.43.3
199
+
200
+ ### Patch Changes
201
+
202
+ - 24d9759: improve documentation
203
+ - Updated dependencies [24d9759]
204
+ - @contractspec/module.learning-journey@1.43.3
205
+ - @contractspec/lib.design-system@1.43.3
206
+ - @contractspec/lib.ui-kit-web@1.43.2
207
+ - @contractspec/lib.contracts@1.43.3
208
+ - @contractspec/lib.schema@1.43.2
209
+
210
+ ## 1.43.2
211
+
212
+ ### Patch Changes
213
+
214
+ - e147271: fix: improve stability
215
+ - Updated dependencies [e147271]
216
+ - @contractspec/module.learning-journey@1.43.2
217
+ - @contractspec/lib.design-system@1.43.2
218
+ - @contractspec/lib.contracts@1.43.2
219
+ - @contractspec/lib.schema@1.43.1
220
+ - @contractspec/lib.ui-kit-web@1.43.1
221
+
222
+ ## 1.43.1
223
+
224
+ ### Patch Changes
225
+
226
+ - Updated dependencies [f28fdad]
227
+ - @contractspec/lib.contracts@1.43.1
228
+ - @contractspec/lib.design-system@1.43.1
229
+ - @contractspec/module.learning-journey@1.43.1
230
+
231
+ ## 1.43.0
232
+
233
+ ### Minor Changes
234
+
235
+ - 042d072: feat: schema declaration using json schema, including zod
236
+
237
+ ### Patch Changes
238
+
239
+ - Updated dependencies [042d072]
240
+ - @contractspec/module.learning-journey@1.43.0
241
+ - @contractspec/lib.design-system@1.43.0
242
+ - @contractspec/lib.ui-kit-web@1.43.0
243
+ - @contractspec/lib.contracts@1.43.0
244
+ - @contractspec/lib.schema@1.43.0
245
+
246
+ ## 1.42.10
247
+
248
+ ### Patch Changes
249
+
250
+ - 1e6a0f1: fix: mcp server
251
+ - Updated dependencies [1e6a0f1]
252
+ - @contractspec/module.learning-journey@1.42.10
253
+ - @contractspec/lib.design-system@1.42.10
254
+ - @contractspec/lib.ui-kit-web@1.42.10
255
+ - @contractspec/lib.contracts@1.42.10
256
+ - @contractspec/lib.schema@1.42.10
257
+
258
+ ## 1.42.9
259
+
260
+ ### Patch Changes
261
+
262
+ - 9281db7: fix ModelRegistry
263
+ - Updated dependencies [9281db7]
264
+ - @contractspec/module.learning-journey@1.42.9
265
+ - @contractspec/lib.design-system@1.42.9
266
+ - @contractspec/lib.ui-kit-web@1.42.9
267
+ - @contractspec/lib.contracts@1.42.9
268
+ - @contractspec/lib.schema@1.42.9
269
+
270
+ ## 1.42.8
271
+
272
+ ### Patch Changes
273
+
274
+ - e07b5ac: fix
275
+ - Updated dependencies [e07b5ac]
276
+ - @contractspec/module.learning-journey@1.42.8
277
+ - @contractspec/lib.design-system@1.42.8
278
+ - @contractspec/lib.ui-kit-web@1.42.8
279
+ - @contractspec/lib.contracts@1.42.8
280
+ - @contractspec/lib.schema@1.42.8
281
+
282
+ ## 1.42.7
283
+
284
+ ### Patch Changes
285
+
286
+ - e9b575d: fix release
287
+ - Updated dependencies [e9b575d]
288
+ - @contractspec/module.learning-journey@1.42.7
289
+ - @contractspec/lib.design-system@1.42.7
290
+ - @contractspec/lib.ui-kit-web@1.42.7
291
+ - @contractspec/lib.contracts@1.42.7
292
+ - @contractspec/lib.schema@1.42.7
293
+
294
+ ## 1.42.6
295
+
296
+ ### Patch Changes
297
+
298
+ - 1500242: fix tooling
299
+ - Updated dependencies [1500242]
300
+ - @contractspec/module.learning-journey@1.42.6
301
+ - @contractspec/lib.design-system@1.42.6
302
+ - @contractspec/lib.ui-kit-web@1.42.6
303
+ - @contractspec/lib.contracts@1.42.6
304
+ - @contractspec/lib.schema@1.42.6
305
+
306
+ ## 1.42.5
307
+
308
+ ### Patch Changes
309
+
310
+ - 1299719: fix vscode
311
+ - Updated dependencies [1299719]
312
+ - @contractspec/module.learning-journey@1.42.5
313
+ - @contractspec/lib.design-system@1.42.5
314
+ - @contractspec/lib.ui-kit-web@1.42.5
315
+ - @contractspec/lib.contracts@1.42.5
316
+ - @contractspec/lib.schema@1.42.5
317
+
318
+ ## 1.42.4
319
+
320
+ ### Patch Changes
321
+
322
+ - ac28b99: fix: generate from openapi
323
+ - Updated dependencies [ac28b99]
324
+ - @contractspec/module.learning-journey@1.42.4
325
+ - @contractspec/lib.design-system@1.42.4
326
+ - @contractspec/lib.ui-kit-web@1.42.4
327
+ - @contractspec/lib.contracts@1.42.4
328
+ - @contractspec/lib.schema@1.42.4
329
+
330
+ ## 1.42.3
331
+
332
+ ### Patch Changes
333
+
334
+ - 3f5d015: fix(tooling): cicd
335
+ - Updated dependencies [3f5d015]
336
+ - @contractspec/lib.contracts@1.42.3
337
+ - @contractspec/lib.design-system@1.42.3
338
+ - @contractspec/lib.schema@1.42.3
339
+ - @contractspec/lib.ui-kit-web@1.42.3
340
+ - @contractspec/module.learning-journey@1.42.3
341
+
342
+ ## 1.42.2
343
+
344
+ ### Patch Changes
345
+
346
+ - 1f9ac4c: fix
347
+ - Updated dependencies [1f9ac4c]
348
+ - @contractspec/lib.contracts@1.42.2
349
+ - @contractspec/lib.design-system@1.42.2
350
+ - @contractspec/lib.schema@1.42.2
351
+ - @contractspec/lib.ui-kit-web@1.42.2
352
+ - @contractspec/module.learning-journey@1.42.2
353
+
354
+ ## 1.42.1
355
+
356
+ ### Patch Changes
357
+
358
+ - f043995: Fix release
359
+ - Updated dependencies [f043995]
360
+ - @contractspec/module.learning-journey@1.42.1
361
+ - @contractspec/lib.design-system@1.42.1
362
+ - @contractspec/lib.ui-kit-web@1.42.1
363
+ - @contractspec/lib.contracts@1.42.1
364
+ - @contractspec/lib.schema@1.42.1
365
+
366
+ ## 1.42.0
367
+
368
+ ### Minor Changes
369
+
370
+ - 8eefd9c: initial release
371
+
372
+ ### Patch Changes
373
+
374
+ - Updated dependencies [8eefd9c]
375
+ - @contractspec/lib.contracts@1.42.0
376
+ - @contractspec/lib.design-system@1.42.0
377
+ - @contractspec/lib.schema@1.42.0
378
+ - @contractspec/lib.ui-kit-web@1.42.0
379
+ - @contractspec/module.learning-journey@1.42.0
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 Chaman Ventures, SASU
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,42 @@
1
+ # @contractspec/example.learning-journey-ui-shared
2
+
3
+ Website: https://contractspec.io/
4
+
5
+
6
+ Shared UI components and hooks for learning journey mini-apps.
7
+
8
+ ## Components
9
+
10
+ - **XpBar** - Progress bar showing XP earned vs total
11
+ - **StreakCounter** - Display streak days with fire icon
12
+ - **BadgeDisplay** - Grid of earned badges
13
+ - **ViewTabs** - Tab navigation between views
14
+
15
+ ## Hooks
16
+
17
+ - **useLearningProgress** - Manage learning progress state for a track
18
+
19
+ ## Usage
20
+
21
+ ```tsx
22
+ import {
23
+ XpBar,
24
+ StreakCounter,
25
+ BadgeDisplay,
26
+ ViewTabs,
27
+ useLearningProgress,
28
+ } from '@contractspec/example.learning-journey-ui-shared';
29
+
30
+ function MyLearningApp({ track }) {
31
+ const { progress, stats, completeStep } = useLearningProgress(track);
32
+
33
+ return (
34
+ <div>
35
+ <XpBar current={progress.xpEarned} max={stats.totalXp} />
36
+ <StreakCounter days={progress.streakDays} />
37
+ <BadgeDisplay badges={progress.badges} />
38
+ </div>
39
+ );
40
+ }
41
+ ```
42
+
@@ -0,0 +1,12 @@
1
+ import { BadgeDisplayProps } from "../types.js";
2
+ import * as react_jsx_runtime0 from "react/jsx-runtime";
3
+
4
+ //#region src/components/BadgeDisplay.d.ts
5
+ declare function BadgeDisplay({
6
+ badges,
7
+ maxVisible,
8
+ size
9
+ }: BadgeDisplayProps): react_jsx_runtime0.JSX.Element;
10
+ //#endregion
11
+ export { BadgeDisplay };
12
+ //# sourceMappingURL=BadgeDisplay.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BadgeDisplay.d.ts","names":[],"sources":["../../src/components/BadgeDisplay.tsx"],"sourcesContent":[],"mappings":";;;;iBAuBgB,YAAA;;;;GAIb,oBAAiB,kBAAA,CAAA,GAAA,CAAA"}
@@ -0,0 +1,45 @@
1
+ 'use client';
2
+
3
+ import { cn } from "@contractspec/lib.ui-kit-web/ui/utils";
4
+ import { jsx, jsxs } from "react/jsx-runtime";
5
+
6
+ //#region src/components/BadgeDisplay.tsx
7
+ const BADGE_ICONS = {
8
+ studio_first_30m: "🎯",
9
+ platform_tour: "🗺️",
10
+ crm_first_win: "🏆",
11
+ drill_master: "🧠",
12
+ coach_listener: "👂",
13
+ quest_complete: "⭐",
14
+ streak_7: "🔥",
15
+ streak_30: "💎",
16
+ default: "🏅"
17
+ };
18
+ const sizeStyles = {
19
+ sm: "h-6 w-6 text-sm",
20
+ md: "h-8 w-8 text-base",
21
+ lg: "h-10 w-10 text-lg"
22
+ };
23
+ function BadgeDisplay({ badges, maxVisible = 5, size = "md" }) {
24
+ const visibleBadges = badges.slice(0, maxVisible);
25
+ const hiddenCount = badges.length - maxVisible;
26
+ if (badges.length === 0) return /* @__PURE__ */ jsx("div", {
27
+ className: "text-muted-foreground text-sm",
28
+ children: "No badges earned yet"
29
+ });
30
+ return /* @__PURE__ */ jsxs("div", {
31
+ className: "flex items-center gap-1",
32
+ children: [visibleBadges.map((badge) => /* @__PURE__ */ jsx("div", {
33
+ className: cn("flex items-center justify-center rounded-full bg-gradient-to-br from-amber-400/20 to-amber-600/20", sizeStyles[size]),
34
+ title: badge.replace(/_/g, " "),
35
+ children: BADGE_ICONS[badge] ?? BADGE_ICONS.default
36
+ }, badge)), hiddenCount > 0 && /* @__PURE__ */ jsxs("div", {
37
+ className: cn("text-muted-foreground bg-muted flex items-center justify-center rounded-full", sizeStyles[size], "text-xs font-medium"),
38
+ children: ["+", hiddenCount]
39
+ })]
40
+ });
41
+ }
42
+
43
+ //#endregion
44
+ export { BadgeDisplay };
45
+ //# sourceMappingURL=BadgeDisplay.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BadgeDisplay.js","names":[],"sources":["../../src/components/BadgeDisplay.tsx"],"sourcesContent":["'use client';\n\nimport { cn } from '@contractspec/lib.ui-kit-web/ui/utils';\nimport type { BadgeDisplayProps } from '../types';\n\nconst BADGE_ICONS: Record<string, string> = {\n studio_first_30m: '🎯',\n platform_tour: '🗺️',\n crm_first_win: '🏆',\n drill_master: '🧠',\n coach_listener: '👂',\n quest_complete: '⭐',\n streak_7: '🔥',\n streak_30: '💎',\n default: '🏅',\n};\n\nconst sizeStyles = {\n sm: 'h-6 w-6 text-sm',\n md: 'h-8 w-8 text-base',\n lg: 'h-10 w-10 text-lg',\n};\n\nexport function BadgeDisplay({\n badges,\n maxVisible = 5,\n size = 'md',\n}: BadgeDisplayProps) {\n const visibleBadges = badges.slice(0, maxVisible);\n const hiddenCount = badges.length - maxVisible;\n\n if (badges.length === 0) {\n return (\n <div className=\"text-muted-foreground text-sm\">No badges earned yet</div>\n );\n }\n\n return (\n <div className=\"flex items-center gap-1\">\n {visibleBadges.map((badge) => (\n <div\n key={badge}\n className={cn(\n 'flex items-center justify-center rounded-full bg-gradient-to-br from-amber-400/20 to-amber-600/20',\n sizeStyles[size]\n )}\n title={badge.replace(/_/g, ' ')}\n >\n {BADGE_ICONS[badge] ?? BADGE_ICONS.default}\n </div>\n ))}\n {hiddenCount > 0 && (\n <div\n className={cn(\n 'text-muted-foreground bg-muted flex items-center justify-center rounded-full',\n sizeStyles[size],\n 'text-xs font-medium'\n )}\n >\n +{hiddenCount}\n </div>\n )}\n </div>\n );\n}\n"],"mappings":";;;;;;AAKA,MAAM,cAAsC;CAC1C,kBAAkB;CAClB,eAAe;CACf,eAAe;CACf,cAAc;CACd,gBAAgB;CAChB,gBAAgB;CAChB,UAAU;CACV,WAAW;CACX,SAAS;CACV;AAED,MAAM,aAAa;CACjB,IAAI;CACJ,IAAI;CACJ,IAAI;CACL;AAED,SAAgB,aAAa,EAC3B,QACA,aAAa,GACb,OAAO,QACa;CACpB,MAAM,gBAAgB,OAAO,MAAM,GAAG,WAAW;CACjD,MAAM,cAAc,OAAO,SAAS;AAEpC,KAAI,OAAO,WAAW,EACpB,QACE,oBAAC;EAAI,WAAU;YAAgC;GAA0B;AAI7E,QACE,qBAAC;EAAI,WAAU;aACZ,cAAc,KAAK,UAClB,oBAAC;GAEC,WAAW,GACT,qGACA,WAAW,MACZ;GACD,OAAO,MAAM,QAAQ,MAAM,IAAI;aAE9B,YAAY,UAAU,YAAY;KAP9B,MAQD,CACN,EACD,cAAc,KACb,qBAAC;GACC,WAAW,GACT,gFACA,WAAW,OACX,sBACD;cACF,KACG;IACE;GAEJ"}
@@ -0,0 +1,12 @@
1
+ import { StreakCounterProps } from "../types.js";
2
+ import * as react_jsx_runtime0 from "react/jsx-runtime";
3
+
4
+ //#region src/components/StreakCounter.d.ts
5
+ declare function StreakCounter({
6
+ days,
7
+ isActive,
8
+ size
9
+ }: StreakCounterProps): react_jsx_runtime0.JSX.Element;
10
+ //#endregion
11
+ export { StreakCounter };
12
+ //# sourceMappingURL=StreakCounter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"StreakCounter.d.ts","names":[],"sources":["../../src/components/StreakCounter.tsx"],"sourcesContent":[],"mappings":";;;;iBAuBgB,aAAA;;;;GAIb,qBAAkB,kBAAA,CAAA,GAAA,CAAA"}
@@ -0,0 +1,46 @@
1
+ 'use client';
2
+
3
+ import { cn } from "@contractspec/lib.ui-kit-web/ui/utils";
4
+ import { jsx, jsxs } from "react/jsx-runtime";
5
+
6
+ //#region src/components/StreakCounter.tsx
7
+ const sizeStyles = {
8
+ sm: {
9
+ container: "gap-1 px-2 py-1",
10
+ icon: "text-base",
11
+ text: "text-xs"
12
+ },
13
+ md: {
14
+ container: "gap-1.5 px-3 py-1.5",
15
+ icon: "text-lg",
16
+ text: "text-sm"
17
+ },
18
+ lg: {
19
+ container: "gap-2 px-4 py-2",
20
+ icon: "text-xl",
21
+ text: "text-base"
22
+ }
23
+ };
24
+ function StreakCounter({ days, isActive = true, size = "md" }) {
25
+ const styles = sizeStyles[size];
26
+ return /* @__PURE__ */ jsxs("div", {
27
+ className: cn("inline-flex items-center rounded-full font-semibold", styles.container, isActive ? "bg-orange-500/10 text-orange-500" : "bg-muted text-muted-foreground"),
28
+ children: [/* @__PURE__ */ jsx("span", {
29
+ className: styles.icon,
30
+ role: "img",
31
+ "aria-label": "streak",
32
+ children: "🔥"
33
+ }), /* @__PURE__ */ jsxs("span", {
34
+ className: styles.text,
35
+ children: [
36
+ days,
37
+ " ",
38
+ days === 1 ? "day" : "days"
39
+ ]
40
+ })]
41
+ });
42
+ }
43
+
44
+ //#endregion
45
+ export { StreakCounter };
46
+ //# sourceMappingURL=StreakCounter.js.map