Fix opengraph embed (#2265)

The opengraph embed requires the image to be accessible at the linked
location. As you can see by clicking on this link,
https://photonvision.org/images/PhotonVision-Icon-BG_2.png, it is not
accessible. This is because we need to configure a public directory when
we publish with vite, as the subfolders will not inherently be
published.

This PR adds a public directory and moves all our images there. I also
moved the video to a video directory rather than it being in images.
This commit is contained in:
Sam Freund
2026-01-02 20:42:59 -06:00
committed by GitHub
parent 70fed3535e
commit 940c3430b8
6 changed files with 7 additions and 6 deletions

View File

@@ -31,7 +31,7 @@
/>
<meta
property="og:image"
content="https://photonvision.org/images/PhotonVision-Icon-BG_2.png"
content="https://photonvision.org/images/PhotonVision-Icon-BG.png"
/>
</head>
<body class="home bg-zinc-900 font-light text-white w-screen">

View File

Before

Width:  |  Height:  |  Size: 21 KiB

After

Width:  |  Height:  |  Size: 21 KiB

View File

Before

Width:  |  Height:  |  Size: 1.7 MiB

After

Width:  |  Height:  |  Size: 1.7 MiB

View File

@@ -103,7 +103,7 @@ const socialLinks = [
>
<a href="#" class="flex items-center gap-3 py-2 group">
<img
src="/images/PhotonVision-Icon-BG.png"
src="/public/images/PhotonVision-Icon-BG.png"
alt="PhotonVision"
class="w-10 h-10 group-hover:scale-110 transition-transform duration-300"
/>
@@ -177,7 +177,7 @@ const socialLinks = [
>
<span class="self-center md:self-initial mb-8 md:mb-0 md:me-12 shrink">
<img
src="/images/PhotonVision-Icon-BG.png"
src="/public/images/PhotonVision-Icon-BG.png"
alt="PhotonVision Logo"
class="max-w-20 md:max-w-80 drop-shadow-2xl md:p-0 transition-transform duration-500"
/>
@@ -225,7 +225,7 @@ const socialLinks = [
class="absolute -inset-4 bg-gradient-to-r from-primary via-brand-blue to-brand-yellow rounded-2xl blur-xl opacity-30"
></div>
<img
src="/images/demo.png"
src="/public/images/demo.png"
alt="Demo of PhotonVision UI"
loading="lazy"
class="relative rounded-xl shadow-2xl border border-zinc-700/50"
@@ -255,7 +255,7 @@ const socialLinks = [
<section id="video" class="relative">
<div class="relative">
<video
src="/images/in-action.mp4"
src="/public/videos/in-action.mp4"
playsinline
autoplay
loop
@@ -338,7 +338,7 @@ const socialLinks = [
>
<div class="flex items-center gap-4">
<img
src="/images/PhotonVision-Icon-BG.png"
src="/public/images/PhotonVision-Icon-BG.png"
class="w-12 h-12 hover:scale-110 transition-transform duration-300"
alt="PhotonVision logo"
/>

View File

@@ -3,5 +3,6 @@ import tailwindcss from "@tailwindcss/vite";
import vue from "@vitejs/plugin-vue";
export default defineConfig({
publicDir: "public",
plugins: [vue(), tailwindcss()],
});