Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions public/images/knowhere/favicon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions public/images/knowhere/logo-mark.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/app/favicon.ico
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/app/login/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export async function LoginContent() {
<Card className="m-auto w-full max-w-md rounded-2xl border-none bg-transparent shadow-none">
<CardContent className="flex flex-col items-center p-8 text-center">
<div className="mb-6 flex size-12 items-center justify-center">
<NotebookLogoMark width={28} />
<NotebookLogoMark width={28} className="dark:invert-0" />
</div>
<h1 className="mb-8 text-2xl font-bold tracking-tight">
Knowhere Brain
Expand Down
9 changes: 5 additions & 4 deletions src/components/notebook-logo-mark.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import Image from "next/image";
import { cn } from "@/lib/utils";

const DASHBOARD_MARK = {
height: 84,
width: 92,
height: 42,
width: 37,
} as const;

type NotebookLogoMarkProps = {
Expand All @@ -15,10 +16,10 @@ export function NotebookLogoMark({ width, className }: NotebookLogoMarkProps) {

return (
<Image
src="/images/knowhere/logo-icon.png"
src="/images/knowhere/logo-mark.svg"
alt=""
aria-hidden
className={className}
className={cn("dark:invert", className)}
width={width}
height={height}
style={{ height: "auto" }}
Expand Down
6 changes: 3 additions & 3 deletions src/lib/app-icon.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { describe, expect, it } from "vitest";

import { appMetadata } from "./app-metadata";

const notebookIconPath = "/images/knowhere/logo-icon.png" as const;
const notebookIconPath = "/images/knowhere/favicon.svg" as const;
const rootDirectory: string = process.cwd();

async function hasFile(filePath: string): Promise<boolean> {
Expand All @@ -22,7 +22,7 @@ describe("notebook page icon", () => {
const serializedIcons: string = JSON.stringify(appMetadata.icons);

expect(serializedIcons).toContain(notebookIconPath);
expect(serializedIcons).toContain("image/png");
expect(serializedIcons).toContain("image/svg+xml");
});

it("keeps the configured icon asset available from public", async () => {
Expand All @@ -31,7 +31,7 @@ describe("notebook page icon", () => {
"public",
"images",
"knowhere",
"logo-icon.png",
"favicon.svg",
);

await expect(hasFile(iconFilePath)).resolves.toBe(true);
Expand Down
6 changes: 3 additions & 3 deletions src/lib/app-metadata.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ export const appMetadata: Metadata = {
icons: {
icon: [
{
url: "/images/knowhere/logo-icon.png",
type: "image/png",
sizes: "92x84",
url: "/images/knowhere/favicon.svg",
type: "image/svg+xml",
sizes: "any",
},
],
},
Expand Down
Loading