Skip to content

Commit

Permalink
add back social preview image
Browse files Browse the repository at this point in the history
  • Loading branch information
kearfy committed Sep 17, 2024
1 parent 15f2510 commit d6a2e4b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Binary file added src/assets/img/social-preview.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 6 additions & 6 deletions src/components/layout/BaseLayout.astro
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
import Icon from '@img/icon/icon.svg';
// import PreviewImage from '@assets/img/preview/main.jpg';
import PreviewImage from '@assets/img/social-preview.jpg';
import Footer from '@src/components/layout/Footer/Footer.astro';
import Navbar from '@src/components/layout/Navbar/Navbar.astro';
import '@src/styles/colors.scss';
Expand Down Expand Up @@ -29,8 +29,8 @@ const description =
Astro.props.description ??
"SurrealDB is the ultimate database for tomorrow's serverless, jamstack, single-page, and traditional applications.";
const type = Astro.props.type ?? 'website';
// const image = Astro.props.image ?? PreviewImage.src;
// const banner = 'banner' in Astro.props ? Astro.props.banner : defaultBanner;
const image = Astro.props.image ?? PreviewImage.src;
const banner = 'banner' in Astro.props ? Astro.props.banner : defaultBanner;
const { rssFeedName, navShadowBackground, navDarkDefault, footerBgMonochrome } =
Astro.props;
Expand Down Expand Up @@ -76,7 +76,7 @@ const url = new URL(
<meta name="og:description" property="og:description" content={description} />
<meta name="og:site_name" property="og:site_name" content="SurrealDB" />
<meta name="og:type" property="og:type" content={type} />
<!-- <meta name="og:image" property="og:image" content={image} /> -->
<meta name="og:image" property="og:image" content={image} />

{/* Social Network meta tags */}

Expand All @@ -85,8 +85,8 @@ const url = new URL(
<meta name="twitter:domain" property="twitter:domain" content="surrealdb.com" />
<meta name="twitter:title" property="twitter:title" content={title} />
<meta name="twitter:description" property="twitter:description" content={description} />
<!-- <meta name="twitter:image" property="twitter:image" content={image} /> -->
<!-- <meta name="twitter:image:src" property="twitter:image:src" content={image} /> -->
<meta name="twitter:image" property="twitter:image" content={image} />
<meta name="twitter:image:src" property="twitter:image:src" content={image} />
<meta name="twitter:image:alt" property="twitter:image:alt" content={description} />

</head>
Expand Down

0 comments on commit d6a2e4b

Please sign in to comment.