Repository navigation
Expand file tree
/
Copy pathdashboard.html
More file actions
121 lines (117 loc) · 5.1 KB
/
Copy pathdashboard.html
File metadata and controls
121 lines (117 loc) · 5.1 KB
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Cursor Usage Dashboard</title>
<link rel="stylesheet" href="dashboard.css">
</head>
<body>
<div class="container">
<header>
<h1>Cursor Usage Dashboard</h1>
<div class="header-actions">
<section id="cache-management" class="cache-section-inline" style="display: none;">
<button id="clearCurrentMonth" class="cache-btn cache-btn-small">Clear Current Month's Cache</button>
<button id="clearAllCache" class="cache-btn cache-btn-small">Clear All Cache</button>
</section>
</div>
</header>
<div id="loading" class="loading">
<div class="loading-text">Loading usage data...</div>
<div id="progress" class="progress-info" style="display: none;">
<div class="progress-bar">
<div id="progress-fill" class="progress-fill"></div>
</div>
<div id="progress-text" class="progress-text">Fetching events...</div>
</div>
</div>
<div id="error" class="error" style="display: none;"></div>
<section id="summary" class="summary-section" style="display: none;">
<h2>Summary</h2>
<div class="table-wrapper">
<table class="summary-table">
<thead>
<tr>
<th>Metric</th>
<th>Last 4 Hours</th>
<th>Last 24 Hours</th>
<th>Last 48 Hours</th>
<th>Last 7 Days</th>
<th id="billing-header">Billing</th>
<th id="calendar-header">Calendar</th>
</tr>
</thead>
<tbody id="summaryBody">
<tr>
<td><strong>Requests Costs</strong></td>
<td id="requests-4h">-</td>
<td id="requests-24h">-</td>
<td id="requests-48h">-</td>
<td id="requests-7d">-</td>
<td id="requests-billing">-</td>
<td id="requests-calendar">-</td>
</tr>
<tr>
<td><strong>Total Costs (USD)</strong></td>
<td id="total-4h">-</td>
<td id="total-24h">-</td>
<td id="total-48h">-</td>
<td id="total-7d">-</td>
<td id="total-billing">-</td>
<td id="total-calendar">-</td>
</tr>
<tr>
<td><strong>Usage Based Costs</strong></td>
<td id="usage-4h">-</td>
<td id="usage-24h">-</td>
<td id="usage-48h">-</td>
<td id="usage-7d">-</td>
<td id="usage-billing">-</td>
<td id="usage-calendar">-</td>
</tr>
</tbody>
</table>
</div>
</section>
<section id="details" class="details-section" style="display: none;">
<h2>Usage Events Detail</h2>
<div class="details-controls">
<div id="detailsPageTop" class="details-paging"></div>
<label for="detailsPageSize">Page size:</label>
<select id="detailsPageSize">
<option value="10" selected>10</option>
<option value="50">50</option>
<option value="200">200</option>
<option value="500">500</option>
</select>
</div>
<div class="table-wrapper">
<table class="details-table">
<thead>
<tr>
<th style="min-width: 60px;">#</th>
<th>TIMESTAMP</th>
<th>MODEL</th>
<th>KIND</th>
<th>REQUESTS COSTS</th>
<th>TOTAL CENTS</th>
<th>USAGE BASED COSTS</th>
<th>TOKEN BASED</th>
<th>MAX MODE</th>
<th>INPUT TOKENS</th>
<th>OUTPUT TOKENS</th>
<th>CACHE WRITE</th>
<th>CACHE READ</th>
<th>OWNING USER</th>
</tr>
</thead>
<tbody id="detailsBody">
</tbody>
</table>
</div>
</section>
</div>
<script src="dashboard.js"></script>
</body>
</html>