Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

chore: add lw7 links to blog post

Francesco Sansalvadore09a16a44e424
diff --git a/apps/www/_blog/2023-04-04-infinite-scroll-with-nextjs-framer-motion.mdx b/apps/www/_blog/2023-04-04-infinite-scroll-with-nextjs-framer-motion.mdx
index 406cc058b93..a670abe9610 100644
--- a/apps/www/_blog/2023-04-04-infinite-scroll-with-nextjs-framer-motion.mdx
+++ b/apps/www/_blog/2023-04-04-infinite-scroll-with-nextjs-framer-motion.mdx
@@ -4,6 +4,7 @@ description: Lazy load and paginate data on scroll with Next.js and a sprinkle o
author: fsansalvadore
image: infinite-scroll-thumb.jpg
thumb: infinite-scroll-thumb.jpg
+launchweek: 7
tags:
- tutorial
- launch-week
diff --git a/apps/www/components/LaunchWeek/7/BlogLinks.tsx b/apps/www/components/LaunchWeek/7/BlogLinks.tsx
new file mode 100644
index 00000000000..e67b8ceb072
--- /dev/null
+++ b/apps/www/components/LaunchWeek/7/BlogLinks.tsx
@@ -0,0 +1,139 @@
+import Image from 'next/image'
+import React from 'react'
+import days from '~/components/LaunchWeek/lw7_days'
+
+const BlogLinks = () => {
+ const SectionButtons = ({
+ blog,
+ docs,
+ youtube_id,
+ }: {
+ blog?: string
+ docs?: string
+ youtube_id?: string
+ }) => {
+ return (
+ <div className="flex gap-2 z-10">
+ <a href={blog} target="_blank" rel="noopener">
+ <div className="flex items-center border border-slate-400 bg-gradient-to-r to-[#fcfcfc] from-[#f2f2f2] hover:from-[#d5d5d5] text-black dark:text-white dark:to-[#191919] dark:from-[#464444] dark:hover:from-[#4e4e4e] rounded-full text-xs py-1 pl-3 pr-1">
+ Blog post
+ <div className="bg-[#eeeeee] dark:bg-[#313131] rounded-full inline-block p-1 ml-2">
+ <PencilSvg />
+ </div>
+ </div>
+ </a>
+ {!!docs?.length && (
+ <a href={docs} target="_blank" rel="noopener">
+ <div className="flex items-center border border-slate-400 bg-gradient-to-r from-[#fcfcfc] to-[#f2f2f2] hover:to-[#d5d5d5] text-black dark:text-white dark:from-[#191919] dark:to-[#464444] dark:hover:to-[#4e4e4e] rounded-full text-sm py-2 pl-3 pr-2">
+ Docs
+ <div className="bg-[#eeeeee] dark:bg-[#313131] rounded-full inline-block p-1 ml-2">
+ <DocsSvg />
+ </div>
+ </div>
+ </a>
+ )}
+ {!!youtube_id?.length && (
+ <a
+ href={`https://www.youtube.com/watch?v=${youtube_id}&ab_channel=Supabase`}
+ target="_blank"
+ rel="noopener"
+ >
+ <div className="flex items-center border border-slate-400 bg-gradient-to-r from-[#fcfcfc] to-[#f2f2f2] hover:to-[#d5d5d5] text-black dark:text-white dark:from-[#191919] dark:to-[#464444] dark:hover:to-[#4e4e4e] rounded-full text-sm py-2 pl-3 pr-2">
+ Video
+ <div className="bg-[#eeeeee] dark:bg-[#313131] rounded-full inline-block p-1 ml-2">
+ <PlaySvg />
+ </div>
+ </div>
+ </a>
+ )}
+ </div>
+ )
+ }
+
+ const activeDays = days.filter((day) => Date.parse(day.publishedAt) <= Date.now())
+
+ if (!activeDays.length) return null
+
+ return (
+ <div className="flex flex-col gap-3 lg:gap-4 border-t border-scale-400 py-4 lg:py-8 mt-4 lg:mt-8">
+ <h3 className="text-white text-xl mb-4">More Launch Week 7</h3>
+ {activeDays.map((day) => (
+ <div className={`h-auto w-full flex flex-col lg:flex-row relative overflow-hidden`}>
+ <div
+ className={`
+ flex flex-col flex-1 gap-3 items-start justify-center border rounded-xl h-full relative overflow-hidden
+ p-6 lg:p-10 text-2xl
+ before:absolute before:w-full before:h-full before:top-52 before:right-0 before:bottom-0 before:left-0
+ before:border-[#1f3536] before:-z-10
+ `}
+ >
+ <div className="flex items-center text-lg flex-col-reverse lg:flex-row lg:justify-start gap-2 text-black dark:text-white">
+ <div className="text-transparent bg-clip-text bg-gradient-to-r from-[#F4FFFA] to-[#B7B2C9]">
+ {day.title}
+ </div>
+ </div>
+ <SectionButtons
+ // docs={day.steps[0].docs}
+ blog={day.steps[0].blog}
+ // youtube_id={day.steps[0].youtube_id}
+ />
+ </div>
+ {day.steps[0].thumb && (
+ <Image
+ src={day.steps[0].thumb}
+ className={`
+ absolute opacity-90
+ w-full h-full -z-10 transition-all duration-300
+ `}
+ layout="fill"
+ objectPosition="100% 50%"
+ objectFit="cover"
+ />
+ )}
+ <div
+ className={`absolute opacity-10 w-full h-full -z-10 transition-all duration-300`}
+ style={{
+ background: `radial-gradient(650px 150px at 50% 100%, #4635A730, transparent)`,
+ }}
+ />
+ </div>
+ ))}
+ </div>
+ )
+}
+
+const PencilSvg = () => (
+ <svg width="16" height="17" viewBox="0 0 16 17" fill="none" xmlns="http://www.w3.org/2000/svg">
+ <path
+ d="M3.21792 11.2469L11.8015 2.66333L14.0953 4.95709L5.51167 13.5407M3.21792 11.2469L2.34219 14.4164L5.51167 13.5407M3.21792 11.2469L5.51167 13.5407"
+ // stroke="#6453C5"
+ stroke="#A69DC9"
+ strokeMiterlimit="10"
+ strokeLinejoin="bevel"
+ />
+ </svg>
+)
+const DocsSvg = () => (
+ <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
+ <path
+ d="M4.96289 9.48618H10.9629M4.96289 7.48618H10.9629M4.96289 11.4862H8.96289M3 2.00034V13.9998H12.9996V5.60113L9.38156 2.00034H3ZM12.9644 5.58432L9.38004 2L9.38004 5.58432L12.9644 5.58432Z"
+ // stroke="#6453C5"
+ stroke="#A69DC9"
+ strokeMiterlimit="10"
+ stroke-linejoin="bevel"
+ />
+ </svg>
+)
+const PlaySvg = () => (
+ <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
+ <path
+ d="M13.4287 8L8.74762 10.7026L4.06653 13.4053L4.06653 8L4.06653 2.59474L8.74762 5.29737L13.4287 8Z"
+ // stroke="#6453C5"
+ stroke="#A69DC9"
+ strokeMiterlimit="10"
+ strokeLinejoin="bevel"
+ />
+ </svg>
+)
+
+export default BlogLinks
diff --git a/apps/www/components/LaunchWeek/lw7_days.ts b/apps/www/components/LaunchWeek/lw7_days.ts
index deabcb1de1f..be5892739d2 100644
--- a/apps/www/components/LaunchWeek/lw7_days.ts
+++ b/apps/www/components/LaunchWeek/lw7_days.ts
@@ -30,7 +30,7 @@ const days: WeekDayProps[] = [
title: 'AI generated OG images',
shipped: true,
date: '',
- publishedAt: '2023-04-05T07:00:00.000-07:00',
+ publishedAt: '2023-04-07T07:00:00.000-07:00',
description: 'AI generated OG images',
d: 0,
dd: 'Pre-release',
diff --git a/apps/www/pages/blog/[slug].tsx b/apps/www/pages/blog/[slug].tsx
index 88b1d87898f..779b9426272 100644
--- a/apps/www/pages/blog/[slug].tsx
+++ b/apps/www/pages/blog/[slug].tsx
@@ -9,6 +9,7 @@ import { useRouter } from 'next/router'
import ReactMarkdown from 'react-markdown'
import CTABanner from '~/components/CTABanner'
import DefaultLayout from '~/components/Layouts/Default'
+import BlogLinks from '~/components/LaunchWeek/7/BlogLinks'
import { generateReadingTime } from '~/lib/helpers'
import mdxComponents from '~/lib/mdx/mdxComponents'
import { mdxSerialize } from '~/lib/mdx/mdxSerialize'
@@ -64,6 +65,7 @@ export async function getStaticProps({ params }: any) {
function BlogPostPage(props: any) {
const content = props.blog.content
const authorArray = props.blog.author.split(',')
+ const isLaunchWeek7 = props.blog.launchweek === 7
const author = []
for (let i = 0; i < authorArray.length; i++) {
@@ -264,6 +266,7 @@ function BlogPostPage(props: any) {
<MDXRemote {...content} components={mdxComponents()} />
</div>
</article>
+ {isLaunchWeek7 && <BlogLinks />}
<div className="py-16">
<div className="text-scale-900 dark:text-scale-1000 text-sm">
Share this article
diff --git a/apps/www/public/rss.xml b/apps/www/public/rss.xml
index fd0d82bb06a..d005b1915b9 100644
--- a/apps/www/public/rss.xml
+++ b/apps/www/public/rss.xml
@@ -5,14 +5,14 @@
<link>https://supabase.com</link>
<description>Latest news from Supabase</description>
<language>en</language>
- <lastBuildDate>Thu, 06 Apr 2023 22:10:00 +0000</lastBuildDate>
+ <lastBuildDate>Mon, 03 Apr 2023 22:10:00 +0000</lastBuildDate>
<atom:link href="https://supabase.com/rss.xml" rel="self" type="application/rss+xml"/>
<item>
- <guid>https://supabase.com/blog/infinite-scroll-with-supabase</guid>
- <title>Infinite scroll with NextJs, Supabase and Framer Motion</title>
- <link>https://supabase.com/blog/infinite-scroll-with-supabase</link>
- <description>Lazy load and paginate data on scroll with supabase-js and a sprinkle of Framer Motion magic ✨</description>
- <pubDate>Thu, 06 Apr 2023 22:10:00 +0000</pubDate>
+ <guid>https://supabase.com/blog/infinite-scroll-with-nextjs-framer-motion</guid>
+ <title>Infinite scroll with Next.js, Framer Motion, and Supabase</title>
+ <link>https://supabase.com/blog/infinite-scroll-with-nextjs-framer-motion</link>
+ <description>Lazy load and paginate data on scroll with Next.js and a sprinkle of Framer Motion magic ✨</description>
+ <pubDate>Mon, 03 Apr 2023 22:10:00 +0000</pubDate>
</item>
<item>
<guid>https://supabase.com/blog/supaclub</guid>