Skip to content

Commit 0c5d52d

Browse files
authored
Merge pull request #18 from houdaslassi/feature/icon-refresh
Dashboard Enhancements: Icons + Performance Card Layout
2 parents e836b07 + d4d439f commit 0c5d52d

File tree

11 files changed

+278
-203
lines changed

11 files changed

+278
-203
lines changed

resources/vantage-views/dashboard.blade.php

Lines changed: 105 additions & 39 deletions
Large diffs are not rendered by default.

resources/vantage-views/failed.blade.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,9 @@ class="text-indigo-600 hover:text-indigo-900">
5858
@empty
5959
<tr>
6060
<td colspan="7" class="px-6 py-12 text-center">
61-
<div class="text-6xl mb-4">🎉</div>
61+
<div class="text-6xl mb-4 flex justify-center">
62+
<i data-lucide="star" class="w-14 h-14 text-amber-500" aria-hidden="true"></i>
63+
</div>
6264
<p class="text-gray-500 text-lg">No failed jobs!</p>
6365
<p class="text-gray-400 text-sm mt-2">All your queue jobs are running smoothly.</p>
6466
</td>

resources/vantage-views/jobs.blade.php

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@
3636
<label class="block text-sm font-semibold text-gray-700 mb-2">Status</label>
3737
<select name="status" class="block w-full px-3 py-2 border border-gray-300 rounded-lg shadow-sm focus:outline-none focus:ring-2 focus:ring-indigo-500 focus:border-indigo-500 text-sm">
3838
<option value="">All Statuses</option>
39-
<option value="processed" {{ request('status') === 'processed' ? 'selected' : '' }}>Processed</option>
40-
<option value="failed" {{ request('status') === 'failed' ? 'selected' : '' }}>Failed</option>
41-
<option value="processing" {{ request('status') === 'processing' ? 'selected' : '' }}>Processing</option>
39+
<option value="processed" {{ request('status') === 'processed' ? 'selected' : '' }}>Processed</option>
40+
<option value="failed" {{ request('status') === 'failed' ? 'selected' : '' }}>Failed</option>
41+
<option value="processing" {{ request('status') === 'processing' ? 'selected' : '' }}>Processing</option>
4242
</select>
4343
</div>
4444

@@ -166,6 +166,8 @@ class="block w-full px-3 py-2 border border-gray-300 rounded-lg shadow-sm focus:
166166
$currentTags = request('tags', '');
167167
$tagsArray = !empty($currentTags) ? array_map('trim', explode(',', $currentTags)) : [];
168168
$isActive = in_array($tagValue, array_map('strtolower', $tagsArray));
169+
$tagIcon = $tagData['failed'] > 0 ? 'x-circle' : ($tagData['processed'] > 0 ? 'check-circle' : 'tag');
170+
$tagIconColor = $tagData['failed'] > 0 ? 'text-red-600' : ($tagData['processed'] > 0 ? 'text-green-600' : 'text-blue-600');
169171
@endphp
170172
<button type="button"
171173
data-tag="{{ $tagValue }}"
@@ -175,15 +177,7 @@ class="tag-filter-button group inline-flex items-center px-3 py-2 rounded-lg tex
175177
{{ $tagData['failed'] > 0 ? 'bg-red-50 text-red-700 border border-red-200 hover:bg-red-100' :
176178
($tagData['processed'] > 0 ? 'bg-green-50 text-green-700 border border-green-200 hover:bg-green-100' :
177179
'bg-blue-50 text-blue-700 border border-blue-200 hover:bg-blue-100') }}">
178-
<span class="mr-2">
179-
@if($tagData['failed'] > 0)
180-
181-
@elseif($tagData['processed'] > 0)
182-
183-
@else
184-
🏷️
185-
@endif
186-
</span>
180+
<i data-lucide="{{ $tagIcon }}" class="w-4 h-4 mr-2 {{ $tagIconColor }}" aria-hidden="true"></i>
187181
<span>{{ $tagData['tag'] }}</span>
188182
<span class="ml-2 px-2 py-0.5 rounded-full text-xs font-semibold {{ $tagData['failed'] > 0 ? 'bg-red-100 text-red-800' : ($tagData['processed'] > 0 ? 'bg-green-100 text-green-800' : 'bg-blue-100 text-blue-800') }}">
189183
{{ $tagData['total'] }}

resources/vantage-views/layout.blade.php

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,9 @@
1616
<div class="flex justify-between h-16">
1717
<div class="flex">
1818
<div class="flex-shrink-0 flex items-center">
19-
<a href="{{ route('vantage.dashboard') }}" class="text-xl font-bold text-gray-900 hover:text-indigo-600 transition-colors">
20-
🎯 Vantage
19+
<a href="{{ route('vantage.dashboard') }}" class="text-xl font-bold text-gray-900 hover:text-indigo-600 transition-colors inline-flex items-center gap-2">
20+
<i data-lucide="target" class="w-6 h-6 text-indigo-600" aria-hidden="true"></i>
21+
Vantage
2122
</a>
2223
</div>
2324
<div class="hidden sm:ml-6 sm:flex sm:space-x-8">
@@ -59,6 +60,14 @@ class="@if(request()->routeIs('vantage.tags')) border-indigo-500 text-gray-900 @
5960

6061
@yield('content')
6162
</main>
63+
<script src="https://unpkg.com/lucide@latest"></script>
64+
<script>
65+
document.addEventListener('DOMContentLoaded', () => {
66+
if (window.lucide) {
67+
lucide.createIcons();
68+
}
69+
});
70+
</script>
6271
</body>
6372
</html>
6473

0 commit comments

Comments
 (0)