File size: 18,115 Bytes
6a0e573
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
<!DOCTYPE html>
<html lang="en" class="dark">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Dashboard | CodeForge-AI</title>
    <link rel="icon" type="image/x-icon" href="/static/favicon.ico">
    <script src="https://cdn.tailwindcss.com"></script>
    <script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
    <script src="https://unpkg.com/feather-icons"></script>
    <script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
</head>
<body class="bg-gray-900 text-white">
    <!-- Navigation -->
    <nav class="bg-gray-800 border-b border-red-500/20 sticky top-0 z-50">
        <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
            <div class="flex justify-between items-center h-16">
                <div class="flex items-center space-x-4">
                    <div class="flex items-center space-x-2">
                        <div class="w-8 h-8 bg-red-500 rounded-lg flex items-center justify-center">
                            <i data-feather="code" class="w-4 h-4"></i>
                        </div>
                        <span class="text-xl font-bold text-white">CodeForge-AI</span>
                    </div>
                </div>
                <div class="flex items-center space-x-4">
                    <div class="text-sm text-gray-300">
                        Welcome back, <span class="text-red-400 font-semibold">Developer</span>
                    </div>
                    <button class="text-gray-300 hover:text-white transition-colors">
                        <i data-feather="user" class="w-5 h-5"></i>
                    </button>
                </div>
            </div>
        </div>
    </nav>

    <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-8">
        <!-- Header Stats -->
        <div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6 mb-8">
            <div class="bg-gray-800 rounded-2xl p-6 border border-red-500/20">
                <div class="flex items-center justify-between">
                    <div>
                        <p class="text-gray-400 text-sm">Active Workspaces</p>
                        <p class="text-2xl font-bold text-white">3</p>
                    </div>
                    <div class="w-12 h-12 bg-red-500/20 rounded-xl flex items-center justify-center">
                        <i data-feather="cpu" class="w-6 h-6 text-red-400"></i>
                    </div>
                </div>
            </div>

            <div class="bg-gray-800 rounded-2xl p-6 border border-red-500/20">
                <div class="flex items-center justify-between">
                    <div>
                        <p class="text-gray-400 text-sm">AI Requests Used</p>
                        <p class="text-2xl font-bold text-white">87/100</p>
                    </div>
                    <div class="w-12 h-12 bg-red-500/20 rounded-xl flex items-center justify-center">
                        <i data-feather="zap" class="w-6 h-6 text-red-400"></i>
                    </div>
                </div>
            </div>

            <div class="bg-gray-800 rounded-2xl p-6 border border-red-500/20">
                <div class="flex items-center justify-between">
                    <div>
                        <p class="text-gray-400 text-sm">Deployments</p>
                        <p class="text-2xl font-bold text-white">2</p>
                    </div>
                    <div class="w-12 h-12 bg-red-500/20 rounded-xl flex items-center justify-center">
                        <i data-feather="cloud" class="w-6 h-6 text-red-400"></i>
                    </div>
                </div>
            </div>

            <div class="bg-gray-800 rounded-2xl p-6 border border-red-500/20">
                <div class="flex items-center justify-between">
                    <div>
                        <p class="text-gray-400 text-sm">Storage Used</p>
                        <p class="text-2xl font-bold text-white">1.2/5 GB</p>
                    </div>
                    <div class="w-12 h-12 bg-red-500/20 rounded-xl flex items-center justify-center">
                        <i data-feather="hard-drive" class="w-6 h-6 text-red-400"></i>
                    </div>
                </div>
            </div>
        </div>

        <div class="grid grid-cols-1 lg:grid-cols-3 gap-8">
            <!-- Recent Projects -->
            <div class="lg:col-span-2">
                <div class="bg-gray-800 rounded-2xl p-6 border border-red-500/20">
                    <div class="flex justify-between items-center mb-6">
                        <h2 class="text-xl font-bold text-white">Recent Projects</h2>
                        <button class="bg-red-500 hover:bg-red-600 px-4 py-2 rounded-lg text-white text-sm font-medium transition-colors">
                            <i data-feather="plus" class="w-4 h-4 inline mr-2"></i>
                            New Project
                        </button>
                    </div>

                    <div class="space-y-4">
                        <!-- Project 1 -->
                        <div class="bg-gray-700 rounded-xl p-4 hover:bg-gray-600 transition-colors cursor-pointer">
                            <div class="flex justify-between items-start mb-3">
                                <div>
                                    <h3 class="font-semibold text-white">Web API Server</h3>
                                    <p class="text-gray-400 text-sm">FastAPI backend with PostgreSQL</p>
                                </div>
                                <span class="bg-green-500/20 text-green-400 text-xs px-2 py-1 rounded-full">Running</span>
                            </div>
                            <div class="flex items-center justify-between text-sm text-gray-300">
                                <div class="flex items-center space-x-4">
                                    <span><i data-feather="clock" class="w-4 h-4 inline mr-1"></i> 2h ago</span>
                                    <span><i data-feather="cpu" class="w-4 h-4 inline mr-1"></i> Python</span>
                                </div>
                                <div class="flex space-x-2">
                                    <button class="text-gray-400 hover:text-red-400 transition-colors">
                                        <i data-feather="play" class="w-4 h-4"></i>
                                    </button>
                                    <button class="text-gray-400 hover:text-red-400 transition-colors">
                                        <i data-feather="settings" class="w-4 h-4"></i>
                                    </button>
                                </div>
                            </div>
                        </div>

                        <!-- Project 2 -->
                        <div class="bg-gray-700 rounded-xl p-4 hover:bg-gray-600 transition-colors cursor-pointer">
                            <div class="flex justify-between items-start mb-3">
                                <div>
                                    <h3 class="font-semibold text-white">React Dashboard</h3>
                                    <p class="text-gray-400 text-sm">Admin dashboard with analytics</p>
                                </div>
                                <span class="bg-yellow-500/20 text-yellow-400 text-xs px-2 py-1 rounded-full">Stopped</span>
                            </div>
                            <div class="flex items-center justify-between text-sm text-gray-300">
                                <div class="flex items-center space-x-4">
                                    <span><i data-feather="clock" class="w-4 h-4 inline mr-1"></i> 1d ago</span>
                                    <span><i data-feather="cpu" class="w-4 h-4 inline mr-1"></i> JavaScript</span>
                                </div>
                                <div class="flex space-x-2">
                                    <button class="text-gray-400 hover:text-red-400 transition-colors">
                                        <i data-feather="play" class="w-4 h-4"></i>
                                    </button>
                                    <button class="text-gray-400 hover:text-red-400 transition-colors">
                                        <i data-feather="settings" class="w-4 h-4"></i>
                                    </button>
                                </div>
                            </div>
                        </div>

                        <!-- Project 3 -->
                        <div class="bg-gray-700 rounded-xl p-4 hover:bg-gray-600 transition-colors cursor-pointer">
                            <div class="flex justify-between items-start mb-3">
                                <div>
                                    <h3 class="font-semibold text-white">Data Analysis</h3>
                                    <p class="text-gray-400 text-sm">Machine learning pipeline</p>
                                </div>
                                <span class="bg-red-500/20 text-red-400 text-xs px-2 py-1 rounded-full">Error</span>
                            </div>
                            <div class="flex items-center justify-between text-sm text-gray-300">
                                <div class="flex items-center space-x-4">
                                    <span><i data-feather="clock" class="w-4 h-4 inline mr-1"></i> 3d ago</span>
                                    <span><i data-feather="cpu" class="w-4 h-4 inline mr-1"></i> Python</span>
                                </div>
                                <div class="flex space-x-2">
                                    <button class="text-gray-400 hover:text-red-400 transition-colors">
                                        <i data-feather="play" class="w-4 h-4"></i>
                                    </button>
                                    <button class="text-gray-400 hover:text-red-400 transition-colors">
                                        <i data-feather="settings" class="w-4 h-4"></i>
                                    </button>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>

                <!-- Resource Usage Chart -->
                <div class="bg-gray-800 rounded-2xl p-6 border border-red-500/20 mt-8">
                    <h2 class="text-xl font-bold text-white mb-6">Resource Usage</h2>
                    <div class="h-64">
                        <canvas id="resourceChart"></canvas>
                    </div>
                </div>
            </div>

            <!-- Right Sidebar -->
            <div class="space-y-8">
                <!-- Quick Actions -->
                <div class="bg-gray-800 rounded-2xl p-6 border border-red-500/20">
                    <h2 class="text-xl font-bold text-white mb-4">Quick Actions</h2>
                    <div class="space-y-3">
                        <button class="w-full bg-red-500 hover:bg-red-600 text-white py-3 rounded-xl font-semibold transition-colors flex items-center justify-center">
                            <i data-feather="plus" class="w-5 h-5 mr-2"></i>
                            New Workspace
                        </button>
                        <button class="w-full bg-gray-700 hover:bg-gray-600 text-white py-3 rounded-xl font-semibold transition-colors flex items-center justify-center">
                            <i data-feather="download" class="w-5 h-5 mr-2"></i>
                            Import Project
                        </button>
                        <button class="w-full bg-gray-700 hover:bg-gray-600 text-white py-3 rounded-xl font-semibold transition-colors flex items-center justify-center">
                            <i data-feather="settings" class="w-5 h-5 mr-2"></i>
                            Settings
                        </button>
                    </div>
                </div>

                <!-- AI Assistance -->
                <div class="bg-gray-800 rounded-2xl p-6 border border-red-500/20">
                    <h2 class="text-xl font-bold text-white mb-4">Agent3 AI</h2>
                    <div class="space-y-4">
                        <div class="bg-gray-700 rounded-xl p-4">
                            <div class="flex items-center space-x-3 mb-3">
                                <div class="w-8 h-8 bg-red-500 rounded-full flex items-center justify-center">
                                    <i data-feather="zap" class="w-4 h-4"></i>
                                </div>
                                <div>
                                    <p class="font-semibold text-white">Code Suggestions</p>
                                    <p class="text-gray-400 text-sm">Ready to help</p>
                                </div>
                            </div>
                            <div class="text-sm text-gray-300">
                                Agent3 AI can help you with code generation, debugging, and optimization.
                            </div>
                        </div>
                        
                        <div class="space-y-2">
                            <div class="flex justify-between text-sm">
                                <span class="text-gray-400">AI Credits Used</span>
                                <span class="text-red-400">87/100</span>
                            </div>
                            <div class="w-full bg-gray-700 rounded-full h-2">
                                <div class="bg-red-500 h-2 rounded-full" style="width: 87%"></div>
                            </div>
                        </div>
                        
                        <button class="w-full border border-red-500 text-red-400 hover:bg-red-500/10 py-2 rounded-xl font-semibold transition-colors">
                            Upgrade Plan
                        </button>
                    </div>
                </div>

                <!-- Recent Activity -->
                <div class="bg-gray-800 rounded-2xl p-6 border border-red-500/20">
                    <h2 class="text-xl font-bold text-white mb-4">Recent Activity</h2>
                    <div class="space-y-4">
                        <div class="flex items-start space-x-3">
                            <div class="w-8 h-8 bg-green-500/20 rounded-full flex items-center justify-center">
                                <i data-feather="play" class="w-4 h-4 text-green-400"></i>
                            </div>
                            <div>
                                <p class="text-white text-sm">Started workspace "Web API Server"</p>
                                <p class="text-gray-400 text-xs">2 hours ago</p>
                            </div>
                        </div>
                        <div class="flex items-start space-x-3">
                            <div class="w-8 h-8 bg-blue-500/20 rounded-full flex items-center justify-center">
                                <i data-feather="code" class="w-4 h-4 text-blue-400"></i>
                            </div>
                            <div>
                                <p class="text-white text-sm">Used AI assistance for bug fix</p>
                                <p class="text-gray-400 text-xs">4 hours ago</p>
                            </div>
                        </div>
                        <div class="flex items-start space-x-3">
                            <div class="w-8 h-8 bg-purple-500/20 rounded-full flex items-center justify-center">
                                <i data-feather="cloud" class="w-4 h-4 text-purple-400"></i>
                            </div>
                            <div>
                                <p class="text-white text-sm">Deployed to production</p>
                                <p class="text-gray-400 text-xs">1 day ago</p>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <script>
        // Initialize Feather Icons
        feather.replace();

        // Initialize Chart.js
        const ctx = document.getElementById('resourceChart').getContext('2d');
        new Chart(ctx, {
            type: 'line',
            data: {
                labels: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],
                datasets: [{
                    label: 'CPU Usage (%)',
                    data: [25, 30, 45, 35, 60, 40, 55],
                    borderColor: '#ef4444',
                    backgroundColor: 'rgba(239, 68, 68, 0.1)',
                    tension: 0.4,
                    fill: true
                }, {
                    label: 'Memory Usage (GB)',
                    data: [1.2, 1.5, 1.8, 1.3, 2.1, 1.7, 1.9],
                    borderColor: '#3b82f6',
                    backgroundColor: 'rgba(59, 130, 246, 0.1)',
                    tension: 0.4,
                    fill: true
                }]
            },
            options: {
                responsive: true,
                maintainAspectRatio: false,
                plugins: {
                    legend: {
                        labels: {
                            color: '#9ca3af'
                        }
                    }
                },
                scales: {
                    x: {
                        grid: {
                            color: '#374151'
                        },
                        ticks: {
                            color: '#9ca3af'
                        }
                    },
                    y: {
                        grid: {
                            color: '#374151'
                        },
                        ticks: {
                            color: '#9ca3af'
                        }
                    }
                }
            }
        });
    </script>
</body>
</html>