Skip to content

Commit bfb277b

Browse files
Set global OG image to og-maia
1 parent 8cf595e commit bfb277b

4 files changed

Lines changed: 27 additions & 22 deletions

File tree

public/assets/og-maia.png

1.16 MB
Loading

src/pages/_app.tsx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ import {
3535
import { browserPostHogConfig } from 'src/lib/posthog-browser-config'
3636

3737
const openSansClassName = 'font-sans'
38+
const OG_IMAGE_URL = 'https://www.maiachess.com/assets/og-maia.png'
3839

3940
function MaiaPlatform({ Component, pageProps }: AppProps) {
4041
const router = useRouter()
@@ -100,7 +101,9 @@ function MaiaPlatform({ Component, pageProps }: AppProps) {
100101
<link rel="apple-touch-icon" href="/maia-ios-icon.png" />
101102

102103
{/* Open Graph meta tags for social media embeds */}
103-
<meta property="og:image" content="/embed.png" />
104+
<meta property="og:image" content={OG_IMAGE_URL} />
105+
<meta property="og:image:url" content={OG_IMAGE_URL} />
106+
<meta property="og:image:secure_url" content={OG_IMAGE_URL} />
104107
<meta property="og:image:alt" content="Maia Chess" />
105108
<meta property="og:image:type" content="image/png" />
106109
<meta property="og:image:width" content="1200" />
@@ -109,7 +112,8 @@ function MaiaPlatform({ Component, pageProps }: AppProps) {
109112

110113
{/* Twitter Card meta tags */}
111114
<meta name="twitter:card" content="summary_large_image" />
112-
<meta name="twitter:image" content="/embed.png" />
115+
<meta name="twitter:image" content={OG_IMAGE_URL} />
116+
<meta name="twitter:image:src" content={OG_IMAGE_URL} />
113117
<meta name="twitter:image:alt" content="Maia Chess" />
114118
</Head>
115119

src/pages/blog/[id].tsx

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ import { Post } from 'src/types'
77
import { Markdown } from 'src/components'
88
import { getSortedPostsData, getPostData } from 'src/lib/blog/posts'
99

10+
const OG_IMAGE_URL = 'https://www.maiachess.com/assets/og-maia.png'
11+
1012
interface BlogPostProps {
1113
post: Post
1214
}
@@ -30,22 +32,19 @@ const BlogPost = ({ post }: BlogPostProps) => {
3032
<meta property="og:type" content="article" />
3133
<meta
3234
property="og:url"
33-
content={`https://maiachess.com/blog/${post.id}`}
34-
/>
35-
<meta
36-
property="og:image"
37-
content={`https://maiachess.com${post.image}`}
35+
content={`https://www.maiachess.com/blog/${post.id}`}
3836
/>
37+
<meta property="og:image" content={OG_IMAGE_URL} />
38+
<meta property="og:image:url" content={OG_IMAGE_URL} />
39+
<meta property="og:image:secure_url" content={OG_IMAGE_URL} />
3940
<meta property="og:site_name" content="Maia Chess" />
4041

4142
{/* Twitter Card */}
4243
<meta name="twitter:card" content="summary_large_image" />
4344
<meta name="twitter:title" content={post.title} />
4445
<meta name="twitter:description" content={post.excerpt} />
45-
<meta
46-
name="twitter:image"
47-
content={`https://maiachess.com${post.image}`}
48-
/>
46+
<meta name="twitter:image" content={OG_IMAGE_URL} />
47+
<meta name="twitter:image:src" content={OG_IMAGE_URL} />
4948

5049
{/* Article specific */}
5150
<meta property="article:published_time" content={post.date} />
@@ -57,7 +56,10 @@ const BlogPost = ({ post }: BlogPostProps) => {
5756
{/* Additional SEO */}
5857
<meta name="author" content="Maia Chess Team" />
5958
<meta name="robots" content="index, follow" />
60-
<link rel="canonical" href={`https://maiachess.com/blog/${post.id}`} />
59+
<link
60+
rel="canonical"
61+
href={`https://www.maiachess.com/blog/${post.id}`}
62+
/>
6163
</Head>
6264
<div className="relative flex h-full flex-col items-center justify-center gap-5 py-[10%] md:py-[2%]">
6365
<div className="flex max-w-[90%] flex-col items-center justify-center overflow-x-hidden md:max-w-[80ch]">

src/pages/blog/index.tsx

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ import Link from 'next/link'
33
import { Post } from 'src/types'
44
import { getSortedPostsData } from 'src/lib/blog/posts'
55

6+
const OG_IMAGE_URL = 'https://www.maiachess.com/assets/og-maia.png'
7+
68
export default function Blog({ posts }: { posts: Post[] }) {
79
return (
810
<>
@@ -20,11 +22,10 @@ export default function Blog({ posts }: { posts: Post[] }) {
2022
content="Read the latest insights from the Maia Chess team about human-like chess AI, research updates, and platform developments."
2123
/>
2224
<meta property="og:type" content="website" />
23-
<meta property="og:url" content="https://maiachess.com/blog" />
24-
<meta
25-
property="og:image"
26-
content="https://maiachess.com/maia-og-image.png"
27-
/>
25+
<meta property="og:url" content="https://www.maiachess.com/blog" />
26+
<meta property="og:image" content={OG_IMAGE_URL} />
27+
<meta property="og:image:url" content={OG_IMAGE_URL} />
28+
<meta property="og:image:secure_url" content={OG_IMAGE_URL} />
2829
<meta property="og:site_name" content="Maia Chess" />
2930

3031
{/* Twitter Card */}
@@ -34,15 +35,13 @@ export default function Blog({ posts }: { posts: Post[] }) {
3435
name="twitter:description"
3536
content="Read the latest insights from the Maia Chess team about human-like chess AI, research updates, and platform developments."
3637
/>
37-
<meta
38-
name="twitter:image"
39-
content="https://maiachess.com/maia-og-image.png"
40-
/>
38+
<meta name="twitter:image" content={OG_IMAGE_URL} />
39+
<meta name="twitter:image:src" content={OG_IMAGE_URL} />
4140

4241
{/* Additional SEO */}
4342
<meta name="author" content="Maia Chess Team" />
4443
<meta name="robots" content="index, follow" />
45-
<link rel="canonical" href="https://maiachess.com/blog" />
44+
<link rel="canonical" href="https://www.maiachess.com/blog" />
4645
</Head>
4746
<div className="relative mx-auto flex h-full w-[90%] flex-col items-start justify-center gap-5 py-[10%] md:py-[2%]">
4847
<h1 className="text-4xl font-bold">Blog</h1>

0 commit comments

Comments
 (0)