appclean 2.0.0 → 2.0.3

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 (57) hide show
  1. package/.github/workflows/npm-publish.yml +104 -0
  2. package/DEVELOPMENT.md +84 -0
  3. package/RELEASE_GUIDE.md +257 -0
  4. package/RELEASE_QUICK_START.md +176 -0
  5. package/assets/logo.svg +48 -32
  6. package/dist/index.js +1 -1
  7. package/dist/ui/client/api/client.d.ts.map +1 -1
  8. package/dist/ui/client/api/client.js +5 -1
  9. package/dist/ui/client/api/client.js.map +1 -1
  10. package/dist/ui/client/app.d.ts +1 -1
  11. package/dist/ui/client/app.d.ts.map +1 -1
  12. package/dist/ui/client/app.js +10 -6
  13. package/dist/ui/client/app.js.map +1 -1
  14. package/dist/ui/client/index.html +103 -46
  15. package/dist/ui/client/pages/appSearch.js +12 -1
  16. package/dist/ui/client/pages/appSearch.js.map +1 -1
  17. package/dist/ui/client/pages/dashboard.d.ts.map +1 -1
  18. package/dist/ui/client/pages/dashboard.js +26 -5
  19. package/dist/ui/client/pages/dashboard.js.map +1 -1
  20. package/dist/ui/client/state/appStore.d.ts.map +1 -1
  21. package/dist/ui/client/state/appStore.js +21 -12
  22. package/dist/ui/client/state/appStore.js.map +1 -1
  23. package/dist/ui/client/state/dashboardStore.d.ts.map +1 -1
  24. package/dist/ui/client/state/dashboardStore.js +9 -3
  25. package/dist/ui/client/state/dashboardStore.js.map +1 -1
  26. package/dist/ui/client/styles/animations.css +384 -2
  27. package/dist/ui/client/styles/base.css +347 -73
  28. package/dist/ui/client/styles/components.css +566 -189
  29. package/dist/ui/client/styles/layout.css +618 -1
  30. package/dist/ui/client/styles/responsive.css +388 -0
  31. package/dist/ui/client/styles/variables.css +163 -69
  32. package/dist/ui/guiServer.d.ts +3 -0
  33. package/dist/ui/guiServer.d.ts.map +1 -1
  34. package/dist/ui/guiServer.js +48 -1
  35. package/dist/ui/guiServer.js.map +1 -1
  36. package/dist/utils/upgrade.d.ts +2 -1
  37. package/dist/utils/upgrade.d.ts.map +1 -1
  38. package/dist/utils/upgrade.js +14 -1
  39. package/dist/utils/upgrade.js.map +1 -1
  40. package/package.json +1 -1
  41. package/scripts/publish-npm.sh +64 -0
  42. package/src/index.ts +1 -1
  43. package/src/ui/client/api/client.ts +6 -1
  44. package/src/ui/client/app.ts +15 -11
  45. package/src/ui/client/index.html +103 -46
  46. package/src/ui/client/pages/appSearch.ts +14 -1
  47. package/src/ui/client/pages/dashboard.ts +27 -5
  48. package/src/ui/client/state/appStore.ts +24 -12
  49. package/src/ui/client/state/dashboardStore.ts +13 -3
  50. package/src/ui/client/styles/animations.css +384 -2
  51. package/src/ui/client/styles/base.css +347 -73
  52. package/src/ui/client/styles/components.css +566 -189
  53. package/src/ui/client/styles/layout.css +618 -1
  54. package/src/ui/client/styles/responsive.css +388 -0
  55. package/src/ui/client/styles/variables.css +163 -69
  56. package/src/ui/guiServer.ts +67 -1
  57. package/src/utils/upgrade.ts +18 -1
@@ -57,16 +57,20 @@ export class AppStore extends Store<AppStoreState> {
57
57
  const response = await fetch('/api/apps/list');
58
58
  if (!response.ok) throw new Error('Failed to load apps');
59
59
 
60
- const data = await response.json();
60
+ const json = await response.json();
61
+ const data = json.data || json; // Handle wrapped { success, data } format
62
+
61
63
  this.setState({
62
- apps: data.apps,
63
- total: data.total,
64
- page: data.page,
64
+ apps: data.apps || [],
65
+ total: data.total || 0,
66
+ page: data.page || 1,
65
67
  isLoading: false,
66
68
  });
67
69
  } catch (error) {
70
+ const errorMsg = error instanceof Error ? error.message : 'Unknown error';
71
+ console.error('Failed to load apps:', errorMsg);
68
72
  this.setState({
69
- error: (error as Error).message,
73
+ error: errorMsg,
70
74
  isLoading: false,
71
75
  });
72
76
  }
@@ -88,15 +92,19 @@ export class AppStore extends Store<AppStoreState> {
88
92
  const response = await fetch(`/api/apps/search?${params}`);
89
93
  if (!response.ok) throw new Error('Failed to search apps');
90
94
 
91
- const data = await response.json();
95
+ const json = await response.json();
96
+ const data = json.data || json; // Handle wrapped { success, data } format
97
+
92
98
  this.setState({
93
- apps: data.apps,
94
- total: data.count,
99
+ apps: data.apps || [],
100
+ total: data.count || 0,
95
101
  isLoading: false,
96
102
  });
97
103
  } catch (error) {
104
+ const errorMsg = error instanceof Error ? error.message : 'Unknown error';
105
+ console.error('Failed to search apps:', errorMsg);
98
106
  this.setState({
99
- error: (error as Error).message,
107
+ error: errorMsg,
100
108
  isLoading: false,
101
109
  });
102
110
  }
@@ -145,15 +153,19 @@ export class AppStore extends Store<AppStoreState> {
145
153
  const response = await fetch(`/api/apps/search?${params}`);
146
154
  if (!response.ok) throw new Error('Failed to load more apps');
147
155
 
148
- const data = await response.json();
156
+ const json = await response.json();
157
+ const data = json.data || json; // Handle wrapped { success, data } format
158
+
149
159
  this.setState({
150
- apps: [...this.state.apps, ...data.apps],
160
+ apps: [...this.state.apps, ...(data.apps || [])],
151
161
  page: nextPage,
152
162
  isLoading: false,
153
163
  });
154
164
  } catch (error) {
165
+ const errorMsg = error instanceof Error ? error.message : 'Unknown error';
166
+ console.error('Failed to load next page:', errorMsg);
155
167
  this.setState({
156
- error: (error as Error).message,
168
+ error: errorMsg,
157
169
  isLoading: false,
158
170
  });
159
171
  }
@@ -44,17 +44,27 @@ export class DashboardStore extends Store<DashboardStoreState> {
44
44
  this.setState({ isLoading: true, error: null });
45
45
  try {
46
46
  const response = await fetch('/api/dashboard/stats');
47
- if (!response.ok) throw new Error('Failed to load dashboard stats');
47
+ if (!response.ok) throw new Error(`Failed to load dashboard stats: ${response.status}`);
48
+
49
+ const data = await response.json();
50
+
51
+ // Extract stats from API response format { success: true, data: {...} }
52
+ const stats = data.data || data;
53
+
54
+ if (!stats) {
55
+ throw new Error('Invalid response format from server');
56
+ }
48
57
 
49
- const stats = await response.json();
50
58
  this.setState({
51
59
  stats,
52
60
  isLoading: false,
53
61
  lastUpdated: Date.now(),
54
62
  });
55
63
  } catch (error) {
64
+ const errorMsg = error instanceof Error ? error.message : 'Unknown error';
65
+ console.error('Failed to load dashboard stats:', errorMsg);
56
66
  this.setState({
57
- error: (error as Error).message,
67
+ error: errorMsg,
58
68
  isLoading: false,
59
69
  });
60
70
  }
@@ -1,6 +1,11 @@
1
- /* Animations - Keyframes and Transition Effects */
1
+ /* ============================================================================
2
+ Animations - Modern Keyframes and Transition Effects
3
+ ============================================================================ */
4
+
5
+ /* ============================================================================
6
+ Fade Animations
7
+ ============================================================================ */
2
8
 
3
- /* Fade Animations */
4
9
  @keyframes fadeIn {
5
10
  from {
6
11
  opacity: 0;
@@ -19,6 +24,361 @@
19
24
  }
20
25
  }
21
26
 
27
+ @keyframes fadeInScale {
28
+ from {
29
+ opacity: 0;
30
+ transform: scale(0.95);
31
+ }
32
+ to {
33
+ opacity: 1;
34
+ transform: scale(1);
35
+ }
36
+ }
37
+
38
+ /* ============================================================================
39
+ Slide Animations
40
+ ============================================================================ */
41
+
42
+ @keyframes slideUp {
43
+ from {
44
+ opacity: 0;
45
+ transform: translateY(1rem);
46
+ }
47
+ to {
48
+ opacity: 1;
49
+ transform: translateY(0);
50
+ }
51
+ }
52
+
53
+ @keyframes slideDown {
54
+ from {
55
+ opacity: 0;
56
+ transform: translateY(-1rem);
57
+ }
58
+ to {
59
+ opacity: 1;
60
+ transform: translateY(0);
61
+ }
62
+ }
63
+
64
+ @keyframes slideLeft {
65
+ from {
66
+ opacity: 0;
67
+ transform: translateX(-1rem);
68
+ }
69
+ to {
70
+ opacity: 1;
71
+ transform: translateX(0);
72
+ }
73
+ }
74
+
75
+ @keyframes slideRight {
76
+ from {
77
+ opacity: 0;
78
+ transform: translateX(1rem);
79
+ }
80
+ to {
81
+ opacity: 1;
82
+ transform: translateX(0);
83
+ }
84
+ }
85
+
86
+ @keyframes slideInRight {
87
+ from {
88
+ opacity: 0;
89
+ transform: translateX(1.5rem);
90
+ }
91
+ to {
92
+ opacity: 1;
93
+ transform: translateX(0);
94
+ }
95
+ }
96
+
97
+ /* ============================================================================
98
+ Zoom Animations
99
+ ============================================================================ */
100
+
101
+ @keyframes zoomIn {
102
+ from {
103
+ opacity: 0;
104
+ transform: scale(0.9);
105
+ }
106
+ to {
107
+ opacity: 1;
108
+ transform: scale(1);
109
+ }
110
+ }
111
+
112
+ @keyframes zoomOut {
113
+ from {
114
+ opacity: 1;
115
+ transform: scale(1);
116
+ }
117
+ to {
118
+ opacity: 0;
119
+ transform: scale(0.9);
120
+ }
121
+ }
122
+
123
+ /* ============================================================================
124
+ Bounce Animations
125
+ ============================================================================ */
126
+
127
+ @keyframes bounce {
128
+ 0%, 100% {
129
+ transform: translateY(0);
130
+ }
131
+ 50% {
132
+ transform: translateY(-0.5rem);
133
+ }
134
+ }
135
+
136
+ @keyframes bounceIn {
137
+ from {
138
+ opacity: 0;
139
+ transform: scale(0.3);
140
+ }
141
+ 50% {
142
+ opacity: 1;
143
+ transform: scale(1.05);
144
+ }
145
+ to {
146
+ transform: scale(1);
147
+ }
148
+ }
149
+
150
+ /* ============================================================================
151
+ Pulse Animations
152
+ ============================================================================ */
153
+
154
+ @keyframes pulse {
155
+ 0%, 100% {
156
+ opacity: 1;
157
+ }
158
+ 50% {
159
+ opacity: 0.5;
160
+ }
161
+ }
162
+
163
+ @keyframes pulseShadow {
164
+ 0%, 100% {
165
+ box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.7);
166
+ }
167
+ 70% {
168
+ box-shadow: 0 0 0 10px rgba(59, 130, 246, 0);
169
+ }
170
+ }
171
+
172
+ /* ============================================================================
173
+ Shake Animations
174
+ ============================================================================ */
175
+
176
+ @keyframes shake {
177
+ 0%, 100% {
178
+ transform: translateX(0);
179
+ }
180
+ 10%, 30%, 50%, 70%, 90% {
181
+ transform: translateX(-2px);
182
+ }
183
+ 20%, 40%, 60%, 80% {
184
+ transform: translateX(2px);
185
+ }
186
+ }
187
+
188
+ /* ============================================================================
189
+ Rotate Animations
190
+ ============================================================================ */
191
+
192
+ @keyframes spin {
193
+ from {
194
+ transform: rotate(0deg);
195
+ }
196
+ to {
197
+ transform: rotate(360deg);
198
+ }
199
+ }
200
+
201
+ @keyframes spinReverse {
202
+ from {
203
+ transform: rotate(360deg);
204
+ }
205
+ to {
206
+ transform: rotate(0deg);
207
+ }
208
+ }
209
+
210
+ /* ============================================================================
211
+ Loading Animations
212
+ ============================================================================ */
213
+
214
+ @keyframes loading {
215
+ 0% {
216
+ background-position: 200% 0;
217
+ }
218
+ 100% {
219
+ background-position: -200% 0;
220
+ }
221
+ }
222
+
223
+ @keyframes skeletonLoading {
224
+ 0% {
225
+ background-position: -1000px 0;
226
+ }
227
+ 100% {
228
+ background-position: 1000px 0;
229
+ }
230
+ }
231
+
232
+ /* ============================================================================
233
+ Text Animations
234
+ ============================================================================ */
235
+
236
+ @keyframes typewriter {
237
+ from {
238
+ width: 0;
239
+ }
240
+ to {
241
+ width: 100%;
242
+ }
243
+ }
244
+
245
+ @keyframes blink {
246
+ 0%, 49%, 100% {
247
+ opacity: 1;
248
+ }
249
+ 50%, 99% {
250
+ opacity: 0;
251
+ }
252
+ }
253
+
254
+ /* ============================================================================
255
+ Glow Animations
256
+ ============================================================================ */
257
+
258
+ @keyframes glow {
259
+ 0%, 100% {
260
+ box-shadow: 0 0 5px rgba(59, 130, 246, 0.5);
261
+ }
262
+ 50% {
263
+ box-shadow: 0 0 20px rgba(59, 130, 246, 0.8);
264
+ }
265
+ }
266
+
267
+ /* ============================================================================
268
+ Float Animation
269
+ ============================================================================ */
270
+
271
+ @keyframes float {
272
+ 0%, 100% {
273
+ transform: translateY(0);
274
+ }
275
+ 50% {
276
+ transform: translateY(-10px);
277
+ }
278
+ }
279
+
280
+ /* ============================================================================
281
+ Flip Animations
282
+ ============================================================================ */
283
+
284
+ @keyframes flipIn {
285
+ from {
286
+ opacity: 0;
287
+ transform: perspective(400px) rotateY(90deg);
288
+ }
289
+ to {
290
+ opacity: 1;
291
+ transform: perspective(400px) rotateY(0deg);
292
+ }
293
+ }
294
+
295
+ @keyframes flipOut {
296
+ from {
297
+ opacity: 1;
298
+ transform: perspective(400px) rotateY(0deg);
299
+ }
300
+ to {
301
+ opacity: 0;
302
+ transform: perspective(400px) rotateY(90deg);
303
+ }
304
+ }
305
+
306
+ /* ============================================================================
307
+ Wave Animation
308
+ ============================================================================ */
309
+
310
+ @keyframes wave {
311
+ 0%, 100% {
312
+ transform: rotate(0deg);
313
+ }
314
+ 25% {
315
+ transform: rotate(20deg);
316
+ }
317
+ 75% {
318
+ transform: rotate(-20deg);
319
+ }
320
+ }
321
+
322
+ /* ============================================================================
323
+ Utility Animation Classes
324
+ ============================================================================ */
325
+
326
+ .animate-fade-in {
327
+ animation: fadeIn var(--transition-normal);
328
+ }
329
+
330
+ .animate-fade-out {
331
+ animation: fadeOut var(--transition-normal);
332
+ }
333
+
334
+ .animate-slide-up {
335
+ animation: slideUp var(--transition-normal);
336
+ }
337
+
338
+ .animate-slide-down {
339
+ animation: slideDown var(--transition-normal);
340
+ }
341
+
342
+ .animate-slide-left {
343
+ animation: slideLeft var(--transition-normal);
344
+ }
345
+
346
+ .animate-slide-right {
347
+ animation: slideRight var(--transition-normal);
348
+ }
349
+
350
+ .animate-zoom-in {
351
+ animation: zoomIn var(--transition-normal);
352
+ }
353
+
354
+ .animate-zoom-out {
355
+ animation: zoomOut var(--transition-normal);
356
+ }
357
+
358
+ .animate-bounce {
359
+ animation: bounce var(--transition-slow);
360
+ }
361
+
362
+ .animate-pulse {
363
+ animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
364
+ }
365
+
366
+ .animate-spin {
367
+ animation: spin 1s linear infinite;
368
+ }
369
+
370
+ .animate-shake {
371
+ animation: shake 0.5s ease-in-out;
372
+ }
373
+
374
+ .animate-float {
375
+ animation: float 3s ease-in-out infinite;
376
+ }
377
+
378
+ .animate-wave {
379
+ animation: wave 0.5s ease-in-out;
380
+ }
381
+
22
382
  .fade-in {
23
383
  animation: fadeIn var(--transition-normal) ease-out forwards;
24
384
  }
@@ -39,6 +399,28 @@
39
399
  }
40
400
  }
41
401
 
402
+ @keyframes slideUp {
403
+ from {
404
+ opacity: 0;
405
+ transform: translateY(20px);
406
+ }
407
+ to {
408
+ opacity: 1;
409
+ transform: translateY(0);
410
+ }
411
+ }
412
+
413
+ @keyframes slideIn {
414
+ from {
415
+ opacity: 0;
416
+ transform: translateX(-10px);
417
+ }
418
+ to {
419
+ opacity: 1;
420
+ transform: translateX(0);
421
+ }
422
+ }
423
+
42
424
  @keyframes slideOutDown {
43
425
  from {
44
426
  opacity: 1;