-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
86a55f9
commit 55f0098
Showing
5 changed files
with
78 additions
and
97 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
import { type Metadata, type Viewport } from "next"; | ||
|
||
export const config = { | ||
title: "Library | Seemore", | ||
shortTitle: "Seemore", | ||
siteName: "Seemore Library", | ||
description: "Access thousands of Islamic texts in seconds.", | ||
themeColor: "#AA4A44", | ||
locale: "en_US", | ||
image: { | ||
url: "/cover.png", | ||
width: 1500, | ||
height: 600, | ||
alt: "Seemore Library Cover", | ||
}, | ||
url: "https://library.digitalseem.org", | ||
}; | ||
|
||
export const getMetadata = ({ | ||
title: baseTitle, | ||
description = config.description, | ||
}: { | ||
title?: string; | ||
description?: string; | ||
} = {}): Metadata => { | ||
const images = [config.image]; | ||
const title = baseTitle | ||
? `${baseTitle} | ${config.shortTitle}` | ||
: config.title; | ||
|
||
return { | ||
title, | ||
description, | ||
metadataBase: new URL(config.url), | ||
icons: [{ rel: "icon", url: "/favicon.ico" }], | ||
openGraph: { | ||
type: "website", | ||
siteName: config.siteName, | ||
locale: config.locale, | ||
url: "/", | ||
title, | ||
description, | ||
images, | ||
}, | ||
alternates: { | ||
canonical: "/", | ||
}, | ||
robots: { | ||
index: true, | ||
follow: true, | ||
googleBot: { | ||
index: true, | ||
follow: true, | ||
"max-video-preview": -1, | ||
"max-image-preview": "large", | ||
"max-snippet": -1, | ||
}, | ||
}, | ||
twitter: { | ||
card: "summary_large_image", | ||
title, | ||
description, | ||
images, | ||
}, | ||
}; | ||
}; | ||
|
||
export const getViewport = (): Viewport => { | ||
return { | ||
width: "device-width", | ||
initialScale: 1, | ||
viewportFit: "cover", | ||
themeColor: config.themeColor, | ||
}; | ||
}; |