Skip to content

Commit 408ecea

Browse files
v2035: Add template attribution and share compact logo assets (samebase/samebase#1598)
Samebase-Source-Repository: samebase/samebase Samebase-Source-Commit: 5bbeddbfbbee85c93572fcd787d1599c320e203a Samebase-Source-Path: templates/base
1 parent 65cdb20 commit 408ecea

3 files changed

Lines changed: 44 additions & 3 deletions

File tree

‎public/favicon.svg‎

Lines changed: 4 additions & 1 deletion
Loading
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
export function SamebaseAttribution() {
2+
return (
3+
<a
4+
href="https://samebase.com"
5+
target="_blank"
6+
rel="noopener noreferrer"
7+
className="group inline-flex min-h-11 items-center text-xs focus-visible:outline-current"
8+
>
9+
<span className="flex items-center gap-1 border-b border-transparent group-hover:border-current">
10+
Managed with{" "}
11+
<svg
12+
xmlns="http://www.w3.org/2000/svg"
13+
viewBox="0 0 60 60"
14+
width={15}
15+
height={15}
16+
shapeRendering="crispEdges"
17+
className="dark:invert"
18+
aria-hidden="true"
19+
>
20+
<rect width="60" height="60" fill="#ffffff" />
21+
<path d="M6 6h48v48H6z M22 22h16v16H22z" fill="#394447" fillRule="evenodd" />
22+
</svg>
23+
<b>Samebase</b>
24+
</span>
25+
</a>
26+
);
27+
}

‎src/routes/__root.tsx‎

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { HeadContent, Link, Outlet, Scripts, createRootRoute } from "@tanstack/react-router";
22
import type { ReactNode } from "react";
33
import appCss from "../style.css?url";
4+
import { SamebaseAttribution } from "#components/SamebaseAttribution";
45
import { Button } from "#components/ui/button";
56

67
export const Route = createRootRoute({
@@ -18,6 +19,11 @@ export const Route = createRootRoute({
1819
},
1920
],
2021
links: [
22+
{
23+
rel: "icon",
24+
type: "image/svg+xml",
25+
href: "/favicon.svg",
26+
},
2127
{
2228
rel: "stylesheet",
2329
href: appCss,
@@ -40,7 +46,12 @@ function RootComponent() {
4046
<Link to="/about">About</Link>
4147
</Button>
4248
</nav>
43-
<Outlet />
49+
<div className="flex-1">
50+
<Outlet />
51+
</div>
52+
<footer className="px-4 py-3 text-center">
53+
<SamebaseAttribution />
54+
</footer>
4455
</RootDocument>
4556
);
4657
}
@@ -51,7 +62,7 @@ function RootDocument({ children }: Readonly<{ children: ReactNode }>) {
5162
<head>
5263
<HeadContent />
5364
</head>
54-
<body>
65+
<body className="flex min-h-dvh flex-col">
5566
{children}
5667
<Scripts />
5768
</body>

0 commit comments

Comments
 (0)