Skip to content

Commit e1b934c

Browse files
committed
Add navbar
Signed-off-by: Ettore Di Giacinto <[email protected]>
1 parent 7c37978 commit e1b934c

File tree

2 files changed

+41
-0
lines changed

2 files changed

+41
-0
lines changed

core/http/views/explorer.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,8 @@
8787
</style>
8888
<body class="bg-gray-900 text-gray-200">
8989
<div class="flex flex-col min-h-screen" x-data="networkClusters()" x-init="init()">
90+
{{template "views/partials/navbar_explorer" .}}
91+
9092
<header class="text-center py-12">
9193
<h1 class="text-5xl font-bold text-gray-100">Network Clusters</h1>
9294
<p class="mt-4 text-lg">View the clusters and workers available in each network.</p>
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
<nav class="bg-gray-800 shadow-lg">
2+
<div class="container mx-auto px-4 py-4">
3+
<div class="flex items-center justify-between">
4+
<div class="flex items-center">
5+
<!-- Logo Image: Replace 'logo_url_here' with your actual logo URL -->
6+
<a href="/" class="text-white text-xl font-bold"><img src="https://github.com/go-skynet/LocalAI/assets/2420543/0966aa2a-166e-4f99-a3e5-6c915fc997dd" alt="LocalAI Logo" class="h-10 mr-3 border-2 border-gray-300 shadow rounded"></a>
7+
<a href="/" class="text-white text-xl font-bold">LocalAI</a>
8+
</div>
9+
<!-- Menu button for small screens -->
10+
<div class="lg:hidden">
11+
<button id="menu-toggle" class="text-gray-400 hover:text-white focus:outline-none">
12+
<i class="fas fa-bars fa-lg"></i>
13+
</button>
14+
</div>
15+
<!-- Navigation links -->
16+
<div class="hidden lg:flex lg:items-center lg:justify-end lg:flex-1 lg:w-0">
17+
<a href="/" class="text-gray-400 hover:text-white px-3 py-2 rounded"><i class="fas fa-home pr-2"></i>Home</a>
18+
<a href="https://localai.io" class="text-gray-400 hover:text-white px-3 py-2 rounded" target="_blank" ><i class="fas fa-book-reader pr-2"></i> Documentation</a>
19+
<a href="https://models.localai.io/" class="text-gray-400 hover:text-white px-3 py-2 rounded"><i class="fas fa-brain pr-2"></i> Models</a>
20+
</div>
21+
</div>
22+
<!-- Collapsible menu for small screens -->
23+
<div class="hidden lg:hidden" id="mobile-menu">
24+
<div class="pt-4 pb-3 border-t border-gray-700">
25+
<a href="/" class="block text-gray-400 hover:text-white px-3 py-2 rounded mt-1"><i class="fas fa-home pr-2"></i>Home</a>
26+
<a href="https://localai.io" class="block text-gray-400 hover:text-white px-3 py-2 rounded mt-1" target="_blank" ><i class="fas fa-book-reader pr-2"></i> Documentation</a>
27+
<a href="https://models.localai.io/" class="text-gray-400 hover:text-white px-3 py-2 rounded"><i class="fas fa-brain pr-2"></i> Models</a>
28+
</div>
29+
</div>
30+
</div>
31+
</nav>
32+
33+
<script>
34+
// JavaScript to toggle the mobile menu
35+
document.getElementById('menu-toggle').addEventListener('click', function () {
36+
var mobileMenu = document.getElementById('mobile-menu');
37+
mobileMenu.classList.toggle('hidden');
38+
});
39+
</script>

0 commit comments

Comments
 (0)