Skip to content

Commit 2733f88

Browse files
authored
πŸŒ–πŸ™…πŸΌβ€β™‚οΈ ↝ Merge pull request #92 from Signal-K/FCDB-23
πŸ‘’πŸŒ– ↝ Hotfix for #91
2 parents 7468f69 + fdb813c commit 2733f88

File tree

3 files changed

+15
-167
lines changed

3 files changed

+15
-167
lines changed

β€Žcomponents/Section/Layout.tsx

+8-8
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,10 @@ const Layout: React.FC<DashboardLayoutProps> = ({ children }) => {
2626

2727
return (
2828
<>
29-
<div className="hidden md:flex relative items-start">
30-
<DesktopSidebar />
31-
<main className="h-max pb-10 grow ml-64 pt-6">
32-
{/* <Navbar /> */}
29+
<main className="h-max pb-10 grow pt-6">
30+
<Navbar />
3331
{children}
3432
</main>
35-
</div>
3633
{isMobile && (
3734
<div className="md:hidden overflow-y-auto h-screen p-4">
3835
<main className="h-max pb-10 grow">{children}</main>
@@ -45,7 +42,7 @@ const Layout: React.FC<DashboardLayoutProps> = ({ children }) => {
4542

4643
export default Layout;
4744

48-
export const GardenLayout: React.FC<DashboardLayoutProps> = ({ children }) => {
45+
export const LayoutWithSidebar: React.FC<DashboardLayoutProps> = ({ children }) => {
4946
const [isMobile, setIsMobile] = useState(false);
5047

5148
useEffect(() => {
@@ -64,10 +61,13 @@ export const GardenLayout: React.FC<DashboardLayoutProps> = ({ children }) => {
6461

6562
return (
6663
<>
67-
<main className="grow pt-6">
68-
{/* <DesktopSidebar /> */}
64+
<div className="hidden md:flex relative items-start">
65+
<DesktopSidebar />
66+
<main className="h-max pb-10 grow ml-64 pt-6">
67+
{/* <Navbar /> */}
6968
{children}
7069
</main>
70+
</div>
7171
{isMobile && (
7272
<div className="md:hidden overflow-y-auto h-screen p-4">
7373
<main className="h-max pb-10 grow">{children}</main>

β€Žcomponents/Section/Sidebar.tsx

+1-156
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ export default Sidebar;
143143

144144
export function DesktopSidebar () {
145145
return (
146-
<div className="min-h-screen flex flex-col flex-auto flex-shrink-0 antialiased text-gray-800">
146+
<div className="min-h-screen flex flex-col flex-auto flex-shrink-0 antialiased bg-gray-50 text-gray-800">
147147
<div className="fixed flex flex-col top-0 left-0 w-64 bg-white h-full border-r">
148148
<div className="flex items-center justify-center h-14 border-b">
149149
<div>Star Sailors Alpha 0.2.1</div>
@@ -265,161 +265,6 @@ export function DesktopSidebar () {
265265
<span className="ml-2 text-sm tracking-wide truncate">Pick your planet</span>
266266
</a>
267267
</li>
268-
<li>
269-
<a href="https://vercel.com/gizmotronn/starprotocol/zyGjejQDyy6cwctvEgrdhAxCx7sF" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6"> {/* Add as iframe page later */}
270-
<span className="inline-flex justify-center items-center ml-4">
271-
<svg className="w-5 h-5" fill="none" stroke="gold" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M12 4.354a4 4 0 110 5.292M15 21H3v-1a6 6 0 0112 0v1zm0 0h6v-1a6 6 0 00-9-5.197M13 7a4 4 0 11-8 0 4 4 0 018 0z"></path></svg>
272-
</span>
273-
<span className="ml-2 text-sm tracking-wide truncate">Star Sailors Alpha 1.0</span>
274-
</a>
275-
</li>
276-
</ul>
277-
</div>
278-
</div>
279-
</div>
280-
);
281-
};
282-
283-
export function GardenSidebar () {
284-
return (
285-
<div className="min-h-screen flex flex-col flex-auto flex-shrink-0 antialiased text-gray-800">
286-
<div className="fixed flex flex-col top-0 left-0 w-64 bg-white h-full border-r">
287-
<div className="flex items-center justify-center h-14 border-b">
288-
<div>Star Sailors Alpha 0.2.1</div>
289-
</div>
290-
<div className="overflow-y-auto overflow-x-hidden flex-grow">
291-
<ul className="flex flex-col py-4 space-y-1">
292-
<li className="px-5">
293-
<div className="flex flex-row items-center h-8">
294-
<div className="text-sm font-light tracking-wide text-gray-500">Dashboard</div>
295-
</div>
296-
</li>
297-
<li>
298-
<a href="/feed" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
299-
<span className="inline-flex justify-center items-center ml-4">
300-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M3 12l2-2m0 0l7-7 7 7M5 10v10a1 1 0 001 1h3m10-11l2 2m-2-2v10a1 1 0 01-1 1h-3m-6 0a1 1 0 001-1v-4a1 1 0 011-1h2a1 1 0 011 1v4a1 1 0 001 1m-6 0h6"></path></svg>
301-
</span>
302-
<span className="ml-2 text-sm tracking-wide truncate">Feed</span>
303-
</a>
304-
</li>
305-
<li>
306-
<a href="/tests/placeholder" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
307-
<span className="inline-flex justify-center items-center ml-4">
308-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M20 13V6a2 2 0 00-2-2H6a2 2 0 00-2 2v7m16 0v5a2 2 0 01-2 2H6a2 2 0 01-2-2v-5m16 0h-2.586a1 1 0 00-.707.293l-2.414 2.414a1 1 0 01-.707.293h-3.172a1 1 0 01-.707-.293l-2.414-2.414A1 1 0 006.586 13H4"></path></svg>
309-
</span>
310-
<span className="ml-2 text-sm tracking-wide truncate">Inbox</span>
311-
<span className="px-2 py-0.5 ml-auto text-xs font-medium tracking-wide text-indigo-500 bg-indigo-50 rounded-full">New</span>
312-
</a>
313-
</li>
314-
<li>
315-
<a href="#" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
316-
<span className="inline-flex justify-center items-center ml-4">
317-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M7 8h10M7 12h4m1 8l-4-4H5a2 2 0 01-2-2V6a2 2 0 012-2h14a2 2 0 012 2v8a2 2 0 01-2 2h-3l-4 4z"></path></svg>
318-
</span>
319-
<span className="ml-2 text-sm tracking-wide truncate">Messages</span>
320-
</a>
321-
</li>
322-
<li>
323-
<a href="#" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
324-
<span className="inline-flex justify-center items-center ml-4">
325-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M15 17h5l-1.405-1.405A2.032 2.032 0 0118 14.158V11a6.002 6.002 0 00-4-5.659V5a2 2 0 10-4 0v.341C7.67 6.165 6 8.388 6 11v3.159c0 .538-.214 1.055-.595 1.436L4 17h5m6 0v1a3 3 0 11-6 0v-1m6 0H9"></path></svg>
326-
</span>
327-
<span className="ml-2 text-sm tracking-wide truncate">Notifications</span>
328-
<span className="px-2 py-0.5 ml-auto text-xs font-medium tracking-wide text-red-500 bg-red-50 rounded-full">1.2k</span>
329-
</a>
330-
</li>
331-
<li className="px-5">
332-
<div className="flex flex-row items-center h-8">
333-
<div className="text-sm font-light tracking-wide text-gray-500">Your Garden</div>
334-
</div>
335-
</li>
336-
<li>
337-
<a href="/garden" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
338-
<span className="inline-flex justify-center items-center ml-4">
339-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-3 7h3m-3 4h3m-6-4h.01M9 16h.01"></path></svg>
340-
</span>
341-
<span className="ml-2 text-sm tracking-wide truncate">Garden</span>
342-
</a>
343-
</li>
344-
<li>
345-
<a href="/archive/planetGarden" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
346-
<span className="inline-flex justify-center items-center ml-4">
347-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-3 7h3m-3 4h3m-6-4h.01M9 16h.01"></path></svg>
348-
</span>
349-
<span className="ml-2 text-sm tracking-wide truncate">Archived Garden</span>
350-
</a>
351-
</li>
352-
<li>
353-
<a href="/garden" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
354-
<span className="inline-flex justify-center items-center ml-4">
355-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M12 4.354a4 4 0 110 5.292M15 21H3v-1a6 6 0 0112 0v1zm0 0h6v-1a6 6 0 00-9-5.197M13 7a4 4 0 11-8 0 4 4 0 018 0z"></path></svg>
356-
</span>
357-
<span className="ml-2 text-sm tracking-wide truncate">Planets</span>
358-
<span className="px-2 py-0.5 ml-auto text-xs font-medium tracking-wide text-green-500 bg-green-50 rounded-full">3</span>
359-
</a>
360-
</li>
361-
<li>
362-
<a href="/planets/1" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
363-
<span className="inline-flex justify-center items-center ml-4">
364-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M12 4.354a4 4 0 110 5.292M15 21H3v-1a6 6 0 0112 0v1zm0 0h6v-1a6 6 0 00-9-5.197M13 7a4 4 0 11-8 0 4 4 0 018 0z"></path></svg>
365-
</span>
366-
<span className="ml-2 text-sm tracking-wide truncate">Water/Checkup</span>
367-
<span className="px-2 py-0.5 ml-auto text-xs font-medium tracking-wide text-green-500 bg-green-50 rounded-full">5</span>
368-
</a>
369-
</li>
370-
<li className="px-5">
371-
<div className="flex flex-row items-center h-8">
372-
<div className="text-sm font-light tracking-wide text-gray-500">Missions</div>
373-
</div>
374-
</li>
375-
<li>
376-
<a href="#" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
377-
<span className="inline-flex justify-center items-center ml-4">
378-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z"></path></svg>
379-
</span>
380-
<span className="ml-2 text-sm tracking-wide truncate">Profile</span>
381-
</a>
382-
</li>
383-
<li>
384-
<a href="#" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
385-
<span className="inline-flex justify-center items-center ml-4">
386-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z"></path></svg>
387-
</span>
388-
<span className="ml-2 text-sm tracking-wide truncate">Tasks</span>
389-
</a>
390-
</li>
391-
<li>
392-
<a href="#" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
393-
<span className="inline-flex justify-center items-center ml-4">
394-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z"></path></svg>
395-
</span>
396-
<span className="ml-2 text-sm tracking-wide truncate">Inventory</span>
397-
</a>
398-
</li>
399-
<li>
400-
<a href="#" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
401-
<span className="inline-flex justify-center items-center ml-4">
402-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z"></path></svg>
403-
</span>
404-
<span className="ml-2 text-sm tracking-wide truncate">Gather</span>
405-
</a>
406-
</li>
407-
<li>
408-
<a href="/onboarding/select" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6">
409-
<span className="inline-flex justify-center items-center ml-4">
410-
<svg className="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M12 4.354a4 4 0 110 5.292M15 21H3v-1a6 6 0 0112 0v1zm0 0h6v-1a6 6 0 00-9-5.197M13 7a4 4 0 11-8 0 4 4 0 018 0z"></path></svg>
411-
</span>
412-
<span className="ml-2 text-sm tracking-wide truncate">Pick your planet</span>
413-
</a>
414-
</li>
415-
<li>
416-
<a href="https://vercel.com/gizmotronn/starprotocol/zyGjejQDyy6cwctvEgrdhAxCx7sF" className="relative flex flex-row items-center h-11 focus:outline-none hover:bg-gray-50 text-gray-600 hover:text-gray-800 border-l-4 border-transparent hover:border-indigo-500 pr-6"> {/* Add as iframe page later */}
417-
<span className="inline-flex justify-center items-center ml-4">
418-
<svg className="w-5 h-5" fill="none" stroke="gold" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M12 4.354a4 4 0 110 5.292M15 21H3v-1a6 6 0 0112 0v1zm0 0h6v-1a6 6 0 00-9-5.197M13 7a4 4 0 11-8 0 4 4 0 018 0z"></path></svg>
419-
</span>
420-
<span className="ml-2 text-sm tracking-wide truncate">Star Sailors Alpha 1.0</span>
421-
</a>
422-
</li>
423268
</ul>
424269
</div>
425270
</div>

β€Žpages/garden.tsx

+6-3
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,14 @@
11
import React from "react";
22
// import Garden from "../components/Gameplay/Garden";
33
import { Garden } from "../components/Content/Planets/GalleryList";
4-
import Layout, { GardenLayout, LayoutNoNav } from "../components/Section/Layout";
5-
import Sidebar from "../components/Section/Sidebar";
4+
import Layout, { LayoutNoNav } from "../components/Section/Layout";
5+
import Navbar from "../components/Section/Navbar";
66

77
export default function GardenPage() {
88
return (
9-
<Garden />
9+
<LayoutNoNav>
10+
<Navbar />
11+
<Garden />
12+
</LayoutNoNav>
1013
)
1114
}

0 commit comments

Comments
Β (0)