Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: update Rooch website SEO settings #1652

Merged
merged 1 commit into from
May 6, 2024
Merged
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
81 changes: 44 additions & 37 deletions docs/website/theme.config.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,50 +48,57 @@ const theme: DocsThemeConfig = {
const { title, frontMatter } = useConfig()
const { asPath } = useRouter()
const router = useRouter()
const socialCard = '/logo/rooch-banner.png'
// const socialCard = '/logo/rooch-banner.png'
const currentLang = router.locale
const pageDescription = frontMatter.description
? frontMatter.description
: currentLang === 'en-US'
? 'Unlocking infinite utility for the Bitcoin Economy'
? 'Unlocking infinite utility for the Bitcoin Economy'
: '开启比特币经济的无限可能'
return (
<>
<meta name="msapplication-TileColor" content="#ffffff" />
<meta name="theme-color" content="#ffffff" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="alternate" href={'https://rooch.network' + asPath} hrefLang="x-default" />
<link rel="alternate" href={'https://rooch.network' + asPath} hrefLang="en-us" />
<link rel="alternate" href={'https://rooch.network' + asPath} hrefLang="en" />
<link rel="alternate" href={'https://rooch.network/zh-CN' + asPath} hrefLang="zh-cn" />
<link rel="alternate" href={'https://rooch.network/zh-CN' + asPath} hrefLang="zh" />
<meta name="description" content={pageDescription} />
<meta name="og:description" content={pageDescription} />
<meta name="twitter:card" content="summary_large_image" />
<meta name="twitter:image" content={socialCard} />
<meta name="twitter:site:domain" content="rooch.network" />
<meta name="twitter:url" content="https://rooch.network" />
<meta name="og:image" content={socialCard} />
<meta name="apple-mobile-web-app-title" content="Rooch Network" />
<link rel="icon" href="/logo/rooch_black_logo.svg" type="image/svg+xml" />
<link rel="icon" href="/logo/rooch_black_logo.png" type="image/png" />
<link
rel="icon"
href="/logo/rooch_white_logo.svg"
type="image/svg+xml"
media="(prefers-color-scheme: dark)"
/>
<link
rel="icon"
href="/logo/rooch_white_logo.png"
type="image/png"
media="(prefers-color-scheme: dark)"
/>
</>
<>
<meta name="msapplication-TileColor" content="#ffffff"/>
<meta name="theme-color" content="#ffffff"/>
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
{/* MULTI-LANGUAGES */}
<link rel="alternate" href={'https://rooch.network' + asPath} hrefLang="x-default"/>
<link rel="alternate" href={'https://rooch.network' + asPath} hrefLang="en-us"/>
<link rel="alternate" href={'https://rooch.network' + asPath} hrefLang="en"/>
<link rel="alternate" href={'https://rooch.network/zh-CN' + asPath} hrefLang="zh-cn"/>
<link rel="alternate" href={'https://rooch.network/zh-CN' + asPath} hrefLang="zh"/>
{/* WEBSITE */}
<meta name="description" content={pageDescription}/>
<meta property="og:description" content={pageDescription}/>
<meta property="og:image" content="https://rooch.network/logo/rooch-banner.png"/>
<meta name="apple-mobile-web-app-title" content="Rooch Network"/>
{/* TWITTER */}
<meta name="twitter:card" content="summary_large_image"/>
<meta name="twitter:site" content="https://rooch.network"/>
<meta name="twitter:creator" content="https://rooch.network"/>
<meta name="twitter:title" content="Rooch Network | Unlocking Infinite Utility for the Bitcoin Economy"/>
<meta name="twitter:description" content={pageDescription}/>
<meta name="twitter:image" content="https://rooch.network/logo/rooch-banner.png"/>
<meta name="twitter:image:alt" content="Rooch Network"/>
{/* FAVICON */}
<link rel="icon" href="/logo/rooch_black_logo.svg" type="image/svg+xml"/>
<link rel="icon" href="/logo/rooch_black_logo.png" type="image/png"/>
<link
rel="icon"
href="/logo/rooch_white_logo.svg"
type="image/svg+xml"
media="(prefers-color-scheme: dark)"
/>
<link
rel="icon"
href="/logo/rooch_white_logo.png"
type="image/png"
media="(prefers-color-scheme: dark)"
/>
</>
)
},
project: {
link: 'https://github.com/rooch-network',
project: {
link: 'https://github.com/rooch-network',
},
chat: {
link: 'https://discord.gg/rooch',
Expand All @@ -104,7 +111,7 @@ const theme: DocsThemeConfig = {
component: Footer,
},
sidebar: {
defaultMenuCollapseLevel: 0,
defaultMenuCollapseLevel: 1,
},
}

Expand Down
Loading