The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
add new pages for Phone and social 0auth
Jonathan Summers-Muir3eb16054ae92
diff --git a/apps/docs/components/Navigation/NavigationMenu/NavigationMenu.constants.ts b/apps/docs/components/Navigation/NavigationMenu/NavigationMenu.constants.tsindex b6c61adcf19..95888005aab 100644--- a/apps/docs/components/Navigation/NavigationMenu/NavigationMenu.constants.ts+++ b/apps/docs/components/Navigation/NavigationMenu/NavigationMenu.constants.ts@@ -148,6 +148,126 @@ export const cli = {],}+export const SocialLoginItems = [+ {+ name: 'Apple login',+ icon: '/docs/img/icons/apple-icon',+ url: '/guides/auth/auth-apple',+ items: [],+ },+ {+ name: 'Azure login',+ icon: '/docs/img/icons/azure-icon',+ url: '/guides/auth/auth-azure',+ items: [],+ },+ {+ name: 'Bitbucket login',+ icon: '/docs/img/icons/bitbucket-icon',+ url: '/guides/auth/auth-bitbucket',+ items: [],+ },+ {+ name: 'Discord login',+ icon: '/docs/img/icons/discord-icon',+ url: '/guides/auth/auth-discord',+ items: [],+ },+ {+ name: 'Facebook login',+ icon: '/docs/img/icons/facebook-icon',+ url: '/guides/auth/auth-facebook',+ items: [],+ },+ {+ name: 'Github login',+ icon: '/docs/img/icons/github-icon',+ url: '/guides/auth/auth-github',+ items: [],+ },+ {+ name: 'Gitlab login',+ icon: '/docs/img/icons/gitlab-icon',+ url: '/guides/auth/auth-gitlab',+ items: [],+ },+ {+ name: 'Google login',+ icon: '/docs/img/icons/google-icon',+ url: '/guides/auth/auth-google',+ items: [],+ },+ {+ name: 'Keycloak login',+ icon: '/docs/img/icons/keycloak-icon',+ url: '/guides/auth/auth-keycloak',+ items: [],+ },+ {+ name: 'LinkedIn login',+ icon: '/docs/img/icons/linkedin-icon',+ url: '/guides/auth/auth-linkedin',+ items: [],+ },+ {+ name: 'Notion login',+ icon: '/docs/img/icons/notion-icon',+ url: '/guides/auth/auth-notion',+ items: [],+ },+ {+ name: 'Slack login',+ icon: '/docs/img/icons/slack-icon',+ url: '/guides/auth/auth-slack',+ items: [],+ },+ {+ name: 'Spotify login',+ icon: '/docs/img/icons/spotify-icon',+ url: '/guides/auth/auth-spotify',+ items: [],+ },+ {+ name: 'Twitch login',+ icon: '/docs/img/icons/twitch-icon',+ url: '/guides/auth/auth-twitch',+ items: [],+ },+ {+ name: 'Twitter login',+ icon: '/docs/img/icons/twitter-icon',+ url: '/guides/auth/auth-twitter',+ items: [],+ },+ {+ name: 'WorkOS login',+ icon: '/docs/img/icons/workos-icon',+ url: '/guides/auth/auth-workos',+ items: [],+ },+]++export const PhoneLogins = [+ {+ name: 'Twilio login',+ icon: '/docs/img/icons/twilio-icon',+ url: '/guides/auth/auth-twilio',+ items: [],+ },+ {+ name: 'Vonage login',+ icon: '/docs/img/icons/vonage-icon',+ url: '/guides/auth/auth-vonage',+ items: [],+ },+ {+ name: 'MessageBird login',+ icon: '/docs/img/icons/messagebird-icon',+ url: '/guides/auth/auth-messagebird',+ items: [],+ },+]+export const auth = {icon: '/img/icons/menu/auth.svg',label: 'Auth',@@ -160,31 +280,14 @@ export const auth = {name: 'Authentication',url: undefined,items: [- { name: 'Login with Email', url: '/guides/auth/auth-email', items: [] },- { name: 'Login with Magic Link', url: '/guides/auth/auth-magic-link', items: [] },- { name: 'Login with Apple', url: '/guides/auth/auth-apple', items: [] },- { name: 'Login with Azure', url: '/guides/auth/auth-azure', items: [] },- { name: 'Login with Bitbucket', url: '/guides/auth/auth-bitbucket', items: [] },- { name: 'Login with Discord', url: '/guides/auth/auth-discord', items: [] },- { name: 'Login with Facebook', url: '/guides/auth/auth-facebook', items: [] },- { name: 'Login with Github', url: '/guides/auth/auth-github', items: [] },- { name: 'Login with Gitlab', url: '/guides/auth/auth-gitlab', items: [] },- { name: 'Login with Google', url: '/guides/auth/auth-google', items: [] },- { name: 'Login with Keycloak', url: '/guides/auth/auth-keycloak', items: [] },- { name: 'Login with LinkedIn', url: '/guides/auth/auth-linkedin', items: [] },- { name: 'Login with Notion', url: '/guides/auth/auth-notion', items: [] },- { name: 'Login with Slack', url: '/guides/auth/auth-slack', items: [] },- { name: 'Login with Spotify', url: '/guides/auth/auth-spotify', items: [] },- { name: 'Login with Twitch', url: '/guides/auth/auth-twitch', items: [] },- { name: 'Login with Twitter', url: '/guides/auth/auth-twitter', items: [] },- { name: 'Login with WorkOS', url: '/guides/auth/auth-workos', items: [] },- { name: 'Phone Auth with Twilio', url: '/guides/auth/auth-twilio', items: [] },- { name: 'Phone Auth with Vonage', url: '/guides/auth/auth-vonage', items: [] },+ { name: 'Email login', url: '/guides/auth/auth-email', items: [] },+ { name: 'Magic Link login', url: '/guides/auth/auth-magic-link', items: [] },{- name: 'Phone Auth with MessageBird',- url: '/guides/auth/auth-messagebird',- items: [],+ name: '0Auth Login',+ url: '/guides/auth/0auth-login',+ items: [...SocialLoginItems],},+ { name: 'Phone Login', url: '/guides/auth/phone-login', items: [] },],},{diff --git a/apps/docs/pages/guides/auth/0auth-login.mdx b/apps/docs/pages/guides/auth/0auth-login.mdxnew file mode 100644index 00000000000..d67271d7813--- /dev/null+++ b/apps/docs/pages/guides/auth/0auth-login.mdx@@ -0,0 +1,40 @@+import Layout from '~/layouts/DefaultGuideLayout'+import { IconPanel } from 'ui'+import Link from 'next/link'+import { SocialLoginItems } from '~/components/Navigation/NavigationMenu/NavigationMenu.constants'++export const meta = {+ title: 'Login with social',+ description: 'Logging in with social accounts',+}++hello world++asdsa++dasd++## adsd++adsdsddsadasd sdasdsdsadasdasdasdasdasd adsdsddsadasd sdasdsdsadasdasdasdasdasd adsdsddsadasd sdasdsdsadasdasdasdasdasd adsdsddsadasd sdasdsdsadasdasdasdasdasd++<div className="grid grid-cols-12 gap-10 not-prose py-16">+ {SocialLoginItems.map((item) => (+ <Link href={`/${item.url}`} key={item.name} passHref>+ <a className="col-span-4">+ <IconPanel+ title={item.name}+ span="col-span-6"+ icon={item.icon}+ >+ {item.description}+ </IconPanel>+ </a>+ </Link>+))}++</div>++export const Page = ({ children }) => <Layout meta={meta} children={children} />++export default Pagediff --git a/apps/docs/pages/guides/auth/phone-login.mdx b/apps/docs/pages/guides/auth/phone-login.mdxnew file mode 100644index 00000000000..51d5b225bfe--- /dev/null+++ b/apps/docs/pages/guides/auth/phone-login.mdx@@ -0,0 +1,40 @@+import Layout from '~/layouts/DefaultGuideLayout'+import { IconPanel } from 'ui'+import Link from 'next/link'+import { PhoneLogins } from '~/components/Navigation/NavigationMenu/NavigationMenu.constants'++export const meta = {+ title: 'Login with social',+ description: 'Logging in with social accounts',+}++hello world++asdsa++dasd++## adsd++adsdsddsadasd sdasdsdsadasdasdasdasdasd adsdsddsadasd sdasdsdsadasdasdasdasdasd adsdsddsadasd sdasdsdsadasdasdasdasdasd adsdsddsadasd sdasdsdsadasdasdasdasdasd++<div className="grid grid-cols-12 gap-10 not-prose py-16">+ {PhoneLogins.map((item) => (+ <Link href={`/${item.url}`} key={item.name} passHref>+ <a className="col-span-4">+ <IconPanel+ title={item.name}+ span="col-span-6"+ icon={item.icon}+ >+ {item.description}+ </IconPanel>+ </a>+ </Link>+))}++</div>++export const Page = ({ children }) => <Layout meta={meta} children={children} />++export default Pagediff --git a/apps/docs/pages/guides/integrations.mdx b/apps/docs/pages/guides/integrations.mdxindex 465770b0ac5..f4f2273c0e2 100644--- a/apps/docs/pages/guides/integrations.mdx+++ b/apps/docs/pages/guides/integrations.mdx@@ -1,7 +1,6 @@import Layout from '~/layouts/DefaultLayout'import Link from 'next/link'import { GlassPanel } from 'ui'-import { integrations } from '~/components/Navigation/NavigationMenu/NavigationMenu.constants'export const meta = {@@ -13,30 +12,30 @@ export const meta = {### Popular Guides<div>-{integrations.items.map((item) => (--<div>- <h2>{item.name}</h2>- <div className="grid grid-cols-12 gap-6 not-prose">- {item.items.map((integration) => (- <Link href={`/${integration.href}`} key={integration.title} passHref>- <a className={integration.span ?? 'col-span-4'}>- <GlassPanel- title={integration.name}- span="col-span-6"- background={true}- icon={<img className="w-10 h-10 rounded" src={`/docs/img/integrations/logos/${integration.name.toLowerCase()}_logo.png`}/>}- >- {integration.description}-- </GlassPanel>- </a>- </Link>- ))}+ {integrations.items.map((item) => (+ <div>+ <h2>{item.name}</h2>+ <div className="grid grid-cols-12 gap-6 not-prose">+ {item.items.map((integration) => (+ <Link href={`/${integration.href}`} key={integration.title} passHref>+ <a className={integration.span ?? 'col-span-4'}>+ <GlassPanel+ title={integration.name}+ span="col-span-6"+ background={true}+ icon={<img className="w-10 h-10 rounded" src={`/docs/img/integrations/logos/${integration.name.toLowerCase()}_logo.png`}/>}+ >+ {integration.description}++ </GlassPanel>+ </a>+ </Link>+ ))}++ </div></div>-</div>-))}+ ))}</div>export const Page = ({ children }) => <Layout meta={meta} children={children} />diff --git a/apps/docs/pages/new/index.mdx b/apps/docs/pages/new/index.mdxindex dca758857f3..3441df9a769 100644--- a/apps/docs/pages/new/index.mdx+++ b/apps/docs/pages/new/index.mdx@@ -93,7 +93,7 @@ hello worldexport const products = [{title: 'Database',- icon: 'database',+ icon: '/docs/img/icons/menu/database',hasLightIcon: true,href: '/guides/database',description: 'Social Login allows the user to sign into a third party website instead of.',@@ -101,7 +101,7 @@ export const products = [},{title: 'Auth',- icon: 'auth',+ icon: '/docs/img/icons/menu/auth',hasLightIcon: true,href: '/guides/auth',description: `@@ -111,7 +111,7 @@ Social Login allows the user to sign into a third party website instead of creat},{title: 'Storage',- icon: 'storage',+ icon: '/docs/img/icons/menu/storage',hasLightIcon: true,href: '/guides/storage',description: `@@ -120,7 +120,7 @@ Social Login allows the user to sign into a third party website instead of creat},{title: 'Realtime',- icon: 'realtime',+ icon: '/docs/img/icons/menu/realtime',hasLightIcon: true,href: '/guides/realtime',description: `@@ -129,7 +129,7 @@ Social Login allows the user to sign into a third party website instead of creat},{title: 'Edge Functions',- icon: 'functions',+ icon: '/docs/img/icons/menu/functions',hasLightIcon: true,href: '/guides/functions',description: `@@ -141,7 +141,7 @@ Social Login allows the user to sign into a third party website instead of createxport const apis = [{title: 'Severless APIs',- icon: 'reference',+ icon: '/docs/img/icons/menu/reference',hasLightIcon: true,href: 'database',description: `@@ -150,7 +150,7 @@ Social Login allows the user to sign into a third party website instead of creat},{title: 'Managment API',- icon: 'reference',+ icon: '/docs/img/icons/menu/reference',hasLightIcon: true,href: 'auth',description: `@@ -159,7 +159,7 @@ Social Login allows the user to sign into a third party website instead of creat},{title: 'Client libraries',- icon: 'reference',+ icon: '/docs/img/icons/menu/reference',hasLightIcon: true,href: 'storage',description: `@@ -172,7 +172,7 @@ export const platform = [{header: '/docs/img/cards/sample-card-header-3.svg',title: 'Dashboard guides',- icon: 'reference',+ icon: '/docs/img/icons/menu/reference',hasLightIcon: true,href: 'database',description: `@@ -183,7 +183,7 @@ Social Login allows the user to sign into a third party website instead of creat{header: '/docs/img/cards/sample-card-header-2.svg',title: 'Integrations',- icon: 'integrations',+ icon: '/docs/img/icons/menu/integrations',hasLightIcon: true,href: 'auth',description: `@@ -194,7 +194,7 @@ Social Login allows the user to sign into a third party website instead of creat{header: '/docs/img/cards/sample-card-header-4.svg',title: 'Glossary',- icon: 'reference',+ icon: '/docs/img/icons/menu/reference',hasLightIcon: true,href: 'storage',description: `diff --git a/apps/docs/public/sitemap.xml b/apps/docs/public/sitemap.xmlindex 24bc227bd35..8a19abf3ae0 100644--- a/apps/docs/public/sitemap.xml+++ b/apps/docs/public/sitemap.xml@@ -283,49 +283,43 @@</url><url>- <loc>https://supabase.com/docs/learn/auth-deep-dive/auth-deep-dive-jwts</loc>- <changefreq>weekly</changefreq>- <changefreq>0.5</changefreq>- </url>-- <url>- <loc>https://supabase.com/docs/learn/auth-deep-dive/auth-google-oauth</loc>+ <loc>https://supabase.com/docs/guides/api/generating-types</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/learn/auth-deep-dive/auth-gotrue</loc>+ <loc>https://supabase.com/docs/guides/cli/local-development</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/learn/auth-deep-dive/auth-policies</loc>+ <loc>https://supabase.com/docs/guides/cli/managing-environments</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/learn/auth-deep-dive/auth-row-level-security</loc>+ <loc>https://supabase.com/docs/guides/functions/auth</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/api/generating-types</loc>+ <loc>https://supabase.com/docs/guides/functions/best-practices</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/cli/local-development</loc>+ <loc>https://supabase.com/docs/guides/functions/cicd-workflow</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/cli/managing-environments</loc>+ <loc>https://supabase.com/docs/guides/functions/quickstart</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url>@@ -589,43 +583,25 @@</url><url>- <loc>https://supabase.com/docs/guides/functions/auth</loc>- <changefreq>weekly</changefreq>- <changefreq>0.5</changefreq>- </url>-- <url>- <loc>https://supabase.com/docs/guides/functions/best-practices</loc>- <changefreq>weekly</changefreq>- <changefreq>0.5</changefreq>- </url>-- <url>- <loc>https://supabase.com/docs/guides/functions/cicd-workflow</loc>- <changefreq>weekly</changefreq>- <changefreq>0.5</changefreq>- </url>-- <url>- <loc>https://supabase.com/docs/guides/functions/quickstart</loc>+ <loc>https://supabase.com/docs/guides/migrations/firebase-auth</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/hosting/docker</loc>+ <loc>https://supabase.com/docs/guides/migrations/firebase-storage</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/hosting/overview</loc>+ <loc>https://supabase.com/docs/guides/migrations/firestore-data</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/hosting/platform</loc>+ <loc>https://supabase.com/docs/guides/migrations/heroku</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url>@@ -769,25 +745,43 @@</url><url>- <loc>https://supabase.com/docs/guides/migrations/firebase-auth</loc>+ <loc>https://supabase.com/docs/guides/hosting/docker</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/migrations/firebase-storage</loc>+ <loc>https://supabase.com/docs/guides/hosting/overview</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/migrations/firestore-data</loc>+ <loc>https://supabase.com/docs/guides/hosting/platform</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/migrations/heroku</loc>+ <loc>https://supabase.com/docs/guides/realtime/postgres-cdc</loc>+ <changefreq>weekly</changefreq>+ <changefreq>0.5</changefreq>+ </url>++ <url>+ <loc>https://supabase.com/docs/guides/realtime/quickstart</loc>+ <changefreq>weekly</changefreq>+ <changefreq>0.5</changefreq>+ </url>++ <url>+ <loc>https://supabase.com/docs/guides/realtime/rate-limits</loc>+ <changefreq>weekly</changefreq>+ <changefreq>0.5</changefreq>+ </url>++ <url>+ <loc>https://supabase.com/docs/guides/storage/storage-sample</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url>@@ -847,25 +841,31 @@</url><url>- <loc>https://supabase.com/docs/guides/realtime/postgres-cdc</loc>+ <loc>https://supabase.com/docs/learn/auth-deep-dive/auth-deep-dive-jwts</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/realtime/quickstart</loc>+ <loc>https://supabase.com/docs/learn/auth-deep-dive/auth-google-oauth</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/realtime/rate-limits</loc>+ <loc>https://supabase.com/docs/learn/auth-deep-dive/auth-gotrue</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/storage/storage-sample</loc>+ <loc>https://supabase.com/docs/learn/auth-deep-dive/auth-policies</loc>+ <changefreq>weekly</changefreq>+ <changefreq>0.5</changefreq>+ </url>++ <url>+ <loc>https://supabase.com/docs/learn/auth-deep-dive/auth-row-level-security</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url>@@ -967,49 +967,49 @@</url><url>- <loc>https://supabase.com/docs/guides/database/extensions/http</loc>+ <loc>https://supabase.com/docs/guides/functions/examples/index</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/database/extensions/pgcron</loc>+ <loc>https://supabase.com/docs/guides/functions/examples/og-image</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/database/extensions/pgnet</loc>+ <loc>https://supabase.com/docs/guides/database/extensions/http</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/database/extensions/pgtap</loc>+ <loc>https://supabase.com/docs/guides/database/extensions/pgcron</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/database/extensions/plv8</loc>+ <loc>https://supabase.com/docs/guides/database/extensions/pgnet</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/database/extensions/uuid-ossp</loc>+ <loc>https://supabase.com/docs/guides/database/extensions/pgtap</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/functions/examples/index</loc>+ <loc>https://supabase.com/docs/guides/database/extensions/plv8</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url><url>- <loc>https://supabase.com/docs/guides/functions/examples/og-image</loc>+ <loc>https://supabase.com/docs/guides/database/extensions/uuid-ossp</loc><changefreq>weekly</changefreq><changefreq>0.5</changefreq></url>diff --git a/packages/ui/index.tsx b/packages/ui/index.tsxindex cc297cf34b9..772f434d345 100644--- a/packages/ui/index.tsx+++ b/packages/ui/index.tsx@@ -10,6 +10,7 @@ export * from './src/components/Button'export * from './src/components/Icon'export * from './src/components/Icon/IconContext'export * from './src/components/GlassPanel'+export * from './src/components/IconPanel'// export * from './src/components/Image'// DISPLAYSdiff --git a/packages/ui/src/components/GlassPanel/GlassPanel.tsx b/packages/ui/src/components/GlassPanel/GlassPanel.tsxindex eadd5b48991..9b17b708798 100644--- a/packages/ui/src/components/GlassPanel/GlassPanel.tsx+++ b/packages/ui/src/components/GlassPanel/GlassPanel.tsx@@ -1,6 +1,5 @@-import React from 'react'-import { Item } from '../Accordion/Accordion'import { useTheme } from 'common/Providers'+import * as React from 'react'interface Props {title: string@@ -11,6 +10,10 @@ interface Props {background?: booleanimg?: stringhasLightIcon?: boolean++ showLink?: boolean++ showIconBg?: boolean}const GlassPanel = ({@@ -22,6 +25,8 @@ const GlassPanel = ({background = true,img,hasLightIcon,+ showLink = false,+ showIconBg = false,}: Props) => {const { isDarkMode } = useTheme()@@ -65,14 +70,19 @@ const GlassPanel = ({><div className="flex items-center gap-3">{typeof icon === 'string' ? (- <div className="bg-green-600 w-8 h-8 flex items-center justify-center rounded">+ showIconBg ? (+ <div className="bg-green-600 w-8 h-8 flex items-center justify-center rounded">+ <img+ className="w-5"+ src={`${icon}${hasLightIcon && !isDarkMode ? '-light' : ''}.svg`}+ />+ </div>+ ) : (<img- className="bg-green-600 w-5"- src={`/docs/img/icons/menu/${icon}${- hasLightIcon && !isDarkMode ? '-light' : ''- }.svg`}+ className="w-5"+ src={`${icon}${hasLightIcon && !isDarkMode ? '-light' : ''}.svg`}/>- </div>+ )) : (icon)}@@ -80,7 +90,7 @@ const GlassPanel = ({</div>{children && <span className="text-sm text-scale-1100">{children}</span>}- <span className="text-brand-900 justify-end text-sm">Learn more</span>+ {showLink && <span className="text-brand-900 justify-end text-sm">Learn more</span>}</div></div>)diff --git a/packages/ui/src/components/IconPanel/IconPanel.tsx b/packages/ui/src/components/IconPanel/IconPanel.tsxnew file mode 100644index 00000000000..58280b02071--- /dev/null+++ b/packages/ui/src/components/IconPanel/IconPanel.tsx@@ -0,0 +1,87 @@+import { useTheme } from 'common/Providers'+import * as React from 'react'+import { ChevronRight } from 'react-feather'++interface Props {+ title: string+ span?: string+ icon?: string | React.ReactNode+ children?: React.ReactNode+ header?: string+ background?: boolean+ img?: string+ hasLightIcon?: boolean++ showLink?: boolean++ showIconBg?: boolean+}++const IconPanel = ({+ title,+ span,+ icon,+ children,+ header,+ background = true,+ img,+ hasLightIcon,+ showLink = false,+ showIconBg = false,+}: Props) => {+ const { isDarkMode } = useTheme()++ return (+ <div className={['relative', 'group'].join(' ')}>+ <div className={['peer relative', 'flex flex-col', icon ? 'gap-6' : 'gap-2'].join(' ')}>+ <div className="flex items-center gap-3">+ {typeof icon === 'string' ? (+ <div+ className={[+ 'relative',+ 'flex items-center justify-center',+ 'h-10 w-10 rounded-lg',+ 'group',+ 'cursor-pointer',+ 'overflow-hidden',+ 'border rounded-full',+ background+ ? 'border-scale-500 hover:border-scale-700 bg-white dark:bg-scale-300'+ : 'border-scale-400 hover:border-scale-500 bg-transparent',+ 'transition',+ ].join(' ')}+ >+ <img+ className="w-5"+ src={`${icon}${hasLightIcon && !isDarkMode ? '-light' : ''}.svg`}+ />+ </div>+ ) : (+ icon+ )}+ <h5 className="text-base text-scale-1200">{title}</h5>+ <div+ className="+ transition-all ease-out -ml-1 opacity-0+ text-scale-800+ group-hover:opacity-100+ group-hover:ml-0"+ >+ <ChevronRight strokeWidth={2} size={14} />+ </div>+ </div>++ {children && <span className="text-sm text-scale-1100">{children}</span>}+ {showLink && <span className="text-brand-900 justify-end text-sm">Learn more</span>}+ </div>+ <div+ className="+ absolute transition-all ease-in+ -z-10 -inset-3 rounded-2xl+ bg-scale-200 dark:bg-whiteA-300 opacity-0 peer-hover:opacity-100"+ ></div>+ </div>+ )+}++export default IconPaneldiff --git a/packages/ui/src/components/IconPanel/index.tsx b/packages/ui/src/components/IconPanel/index.tsxnew file mode 100644index 00000000000..d0ad46b1e51--- /dev/null+++ b/packages/ui/src/components/IconPanel/index.tsx@@ -0,0 +1 @@+export { default as IconPanel } from './IconPanel'