The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
fix: More fixes for UI Library (#34552)
Ivan Vasilov429aa9d08482
diff --git a/apps/ui-library/app/(app)/page.tsx b/apps/ui-library/app/(app)/page.tsxindex 56838ee9d9d..bc5852aa173 100644--- a/apps/ui-library/app/(app)/page.tsx+++ b/apps/ui-library/app/(app)/page.tsx@@ -39,7 +39,7 @@ export default function Home() {UI Blocks for Supabase Projects</h1><h2 className="text-lg text-foreground-light mb-4">- A collection of components and blocks built on the Shadcn UI library that+ A collection of components and blocks built on the shadcn/ui library thatconnect your front-end to your Supabase back-end via a single command.</h2><Button_Shadcn_ variant="secondary" size="lg" className="mt-4">@@ -80,8 +80,8 @@ export default function Home() {className="col-start-2 col-span-10 md:col-start-3 md:col-span-8 relative"><div className="-mt-4 flex rounded-lg overflow-hidden">- <BlockPreview name="realtime-cursor" isPair />- <BlockPreview name="realtime-cursor" isPair />+ <BlockPreview name="realtime-cursor-demo" isPair />+ <BlockPreview name="realtime-cursor-demo" isPair /></div></div><HorizontalGridLine />@@ -139,6 +139,7 @@ export default function Home() {</div></div><HorizontalGridLine />+{/* Realtime Chat */}<divdata-grid-itemdiff --git a/apps/ui-library/content/docs/nextjs/client.mdx b/apps/ui-library/content/docs/nextjs/client.mdxindex 43e464a1801..6a98134b516 100644--- a/apps/ui-library/content/docs/nextjs/client.mdx+++ b/apps/ui-library/content/docs/nextjs/client.mdx@@ -35,3 +35,7 @@ NEXT_PUBLIC_SUPABASE_ANON_KEY=This Supabase client is built for SSR with the Next.js App Router. If you're building a React SPA,use the [React SPA client](/ui/docs/react-router/client) instead.{' '}</Callout>++## Further reading++- [Generating TypeScript types for your client](https://supabase.com/docs/guides/api/rest/generating-types)diff --git a/apps/ui-library/content/docs/nextjs/current-user-avatar.mdx b/apps/ui-library/content/docs/nextjs/current-user-avatar.mdxindex 9f0bffd3414..d5889476c53 100644--- a/apps/ui-library/content/docs/nextjs/current-user-avatar.mdx+++ b/apps/ui-library/content/docs/nextjs/current-user-avatar.mdx@@ -45,3 +45,7 @@ export default CurrentUserAvatarDemo## PropsThis component doesn't accept any props. If you wish to change the fallback, you can do so by changing the `CurrentUserAvatar` component directly.++## Further reading++- [Auth users](https://supabase.com/docs/guides/auth/users)diff --git a/apps/ui-library/content/docs/nextjs/dropzone.mdx b/apps/ui-library/content/docs/nextjs/dropzone.mdxindex ec292d2a742..e3e2511c435 100644--- a/apps/ui-library/content/docs/nextjs/dropzone.mdx+++ b/apps/ui-library/content/docs/nextjs/dropzone.mdx@@ -81,3 +81,9 @@ export FileUploadDemo| `allowedMimeTypes` | `string[]` | `[]` | The MIME types to allow for upload || `maxFiles` | `number` | `1` | Maximum number of files to upload || `maxFileSize` | `number` | `1000` | Maximum file size in bytes |++## Further reading++- [Creating buckets](https://supabase.com/docs/guides/storage/buckets/creating-buckets)+- [Access control](https://supabase.com/docs/guides/storage/security/access-control)+- [Standard uploads](https://supabase.com/docs/guides/storage/uploads/standard-uploads)diff --git a/apps/ui-library/content/docs/nextjs/password-based-auth.mdx b/apps/ui-library/content/docs/nextjs/password-based-auth.mdxindex 9b21a5e020c..53bae89695a 100644--- a/apps/ui-library/content/docs/nextjs/password-based-auth.mdx+++ b/apps/ui-library/content/docs/nextjs/password-based-auth.mdx@@ -79,3 +79,11 @@ NEXT_PUBLIC_SUPABASE_ANON_KEY=You can use this block with the Pages router by simply moving the routes from the `app` folder into the `pages` folder and renaming them. Example instead of `app/sign-up/page.tsx`, you'd create a `pages/sign-up.tsx` file.</Callout>++## Further reading++- [Password-based authentication (PKCE flow)](https://supabase.com/docs/guides/auth/passwords?queryGroups=flow&flow=pkce)+- [Authentication error codes](https://supabase.com/docs/guides/auth/debugging/error-codes)+- [Email templates](https://supabase.com/docs/guides/auth/auth-email-templates)+- [Email templates for local development](https://supabase.com/docs/guides/local-development/customizing-email-templates)+- [Custom SMTP](https://supabase.com/docs/guides/auth/auth-smtp)diff --git a/apps/ui-library/content/docs/nextjs/realtime-avatar-stack.mdx b/apps/ui-library/content/docs/nextjs/realtime-avatar-stack.mdxindex 22b6b894035..44a10b47d68 100644--- a/apps/ui-library/content/docs/nextjs/realtime-avatar-stack.mdx+++ b/apps/ui-library/content/docs/nextjs/realtime-avatar-stack.mdx@@ -38,3 +38,8 @@ export default function Page() {| Prop | Type | Default | Description || ---------- | -------- | ------- | ---------------------------------------------------- || `roomName` | `string` | `null` | The name of the Supabase Realtime room to connect to |++## Further reading++- [Realtime Presence](https://supabase.com/docs/guides/realtime/presence)+- [Realtime authorization](https://supabase.com/docs/guides/realtime/authorization)diff --git a/apps/ui-library/content/docs/nextjs/realtime-chat.mdx b/apps/ui-library/content/docs/nextjs/realtime-chat.mdxindex be6171a1489..a5c60359df2 100644--- a/apps/ui-library/content/docs/nextjs/realtime-chat.mdx+++ b/apps/ui-library/content/docs/nextjs/realtime-chat.mdx@@ -96,3 +96,8 @@ interface ChatMessage {createdAt: string}```++## Further reading++- [Realtime Broadcast](https://supabase.com/docs/guides/realtime/broadcast)+- [Realtime authorization](https://supabase.com/docs/guides/realtime/authorization)diff --git a/apps/ui-library/content/docs/nextjs/realtime-cursor.mdx b/apps/ui-library/content/docs/nextjs/realtime-cursor.mdxindex 3e0fe1938ab..a1e49c8dbf4 100644--- a/apps/ui-library/content/docs/nextjs/realtime-cursor.mdx+++ b/apps/ui-library/content/docs/nextjs/realtime-cursor.mdx@@ -54,3 +54,8 @@ export default function Page() {| ---------- | -------- | ---------------------------------------------------------- || `roomName` | `string` | Unique identifier for the shared room or session. || `username` | `string` | Name of the current user; used to track and label cursors. |++## Further reading++- [Realtime Broadcast](https://supabase.com/docs/guides/realtime/broadcast)+- [Realtime authorization](https://supabase.com/docs/guides/realtime/authorization)diff --git a/apps/ui-library/content/docs/react-router/client.mdx b/apps/ui-library/content/docs/react-router/client.mdxindex c125797a3cd..981860d022d 100644--- a/apps/ui-library/content/docs/react-router/client.mdx+++ b/apps/ui-library/content/docs/react-router/client.mdx@@ -29,3 +29,7 @@ VITE_SUPABASE_ANON_KEY=- If you're using supabase.com, you can find these values in the [Connect modal](https://supabase.com/dashboard/project/_?showConnect=true) under App Frameworks or in your project's [API settings](https://supabase.com/dashboard/project/_/settings/api).- If you're using a local instance of Supabase, you can find these values by running `supabase start` or `supabase status` (if you already have it running).++## Further reading++- [Generating TypeScript types for your client](https://supabase.com/docs/guides/api/rest/generating-types)diff --git a/apps/ui-library/content/docs/react-router/current-user-avatar.mdx b/apps/ui-library/content/docs/react-router/current-user-avatar.mdxindex ed58e790ddd..4fb69c9299f 100644--- a/apps/ui-library/content/docs/react-router/current-user-avatar.mdx+++ b/apps/ui-library/content/docs/react-router/current-user-avatar.mdx@@ -43,3 +43,7 @@ export default CurrentUserAvatarDemo## PropsThis component doesn't accept any props. If you wish to change the fallback, you can do so by changing the `CurrentUserAvatar` component directly.++## Further reading++- [Auth users](https://supabase.com/docs/guides/auth/users)diff --git a/apps/ui-library/content/docs/react-router/dropzone.mdx b/apps/ui-library/content/docs/react-router/dropzone.mdxindex 390a4b87bd0..d8e6acc67c6 100644--- a/apps/ui-library/content/docs/react-router/dropzone.mdx+++ b/apps/ui-library/content/docs/react-router/dropzone.mdx@@ -79,3 +79,9 @@ export FileUploadDemo| `allowedMimeTypes` | `string[]` | `[]` | The MIME types to allow for upload || `maxFiles` | `number` | `1` | Maximum number of files to upload || `maxFileSize` | `number` | `1000` | Maximum file size in bytes |++## Further reading++- [Creating buckets](https://supabase.com/docs/guides/storage/buckets/creating-buckets)+- [Access control](https://supabase.com/docs/guides/storage/security/access-control)+- [Standard uploads](https://supabase.com/docs/guides/storage/uploads/standard-uploads)diff --git a/apps/ui-library/content/docs/react-router/password-based-auth.mdx b/apps/ui-library/content/docs/react-router/password-based-auth.mdxindex adcef492313..01d33b10441 100644--- a/apps/ui-library/content/docs/react-router/password-based-auth.mdx+++ b/apps/ui-library/content/docs/react-router/password-based-auth.mdx@@ -8,7 +8,7 @@ description: Password-based authentication block for React Router## Installation<BlockItem- name="password-based-auth-nextjs"+ name="password-based-auth-react-router"description="All needed components for the password based auth flow"/>@@ -73,3 +73,11 @@ VITE_SUPABASE_ANON_KEY=1. Set up the route users will visit to reset or update their password. Go to the [URL Configuration](https://supabase.com/dashboard/project/_/auth/url-configuration) settings and add the `forgot-password` route to the list of Redirect URLs. It should look something like: `http://example.com/auth/forgot-password`.1. Update the redirect paths in the `login.tsx` and `update-password.tsx` components to point to the logged-in routes in your app.++## Further reading++- [Password-based authentication (PKCE flow)](https://supabase.com/docs/guides/auth/passwords?queryGroups=flow&flow=pkce)+- [Authentication error codes](https://supabase.com/docs/guides/auth/debugging/error-codes)+- [Email templates](https://supabase.com/docs/guides/auth/auth-email-templates)+- [Email templates for local development](https://supabase.com/docs/guides/local-development/customizing-email-templates)+- [Custom SMTP](https://supabase.com/docs/guides/auth/auth-smtp)diff --git a/apps/ui-library/content/docs/react-router/realtime-avatar-stack.mdx b/apps/ui-library/content/docs/react-router/realtime-avatar-stack.mdxindex c7585f55b39..edb20a5b5e8 100644--- a/apps/ui-library/content/docs/react-router/realtime-avatar-stack.mdx+++ b/apps/ui-library/content/docs/react-router/realtime-avatar-stack.mdx@@ -38,3 +38,8 @@ export default function Page() {| Prop | Type | Default | Description || ---------- | -------- | ------- | ---------------------------------------------------- || `roomName` | `string` | `null` | The name of the Supabase Realtime room to connect to |++## Further reading++- [Realtime Presence](https://supabase.com/docs/guides/realtime/presence)+- [Realtime authorization](https://supabase.com/docs/guides/realtime/authorization)diff --git a/apps/ui-library/content/docs/react-router/realtime-chat.mdx b/apps/ui-library/content/docs/react-router/realtime-chat.mdxindex 97f2db14086..6f1ad6b734d 100644--- a/apps/ui-library/content/docs/react-router/realtime-chat.mdx+++ b/apps/ui-library/content/docs/react-router/realtime-chat.mdx@@ -96,3 +96,8 @@ interface ChatMessage {createdAt: string}```++## Further reading++- [Realtime Broadcast](https://supabase.com/docs/guides/realtime/broadcast)+- [Realtime authorization](https://supabase.com/docs/guides/realtime/authorization)diff --git a/apps/ui-library/content/docs/react-router/realtime-cursor.mdx b/apps/ui-library/content/docs/react-router/realtime-cursor.mdxindex b1593c8ef27..57a241eb2f0 100644--- a/apps/ui-library/content/docs/react-router/realtime-cursor.mdx+++ b/apps/ui-library/content/docs/react-router/realtime-cursor.mdx@@ -53,3 +53,8 @@ export default function Page() {| ---------- | -------- | ---------------------------------------------------------- || `roomName` | `string` | Unique identifier for the shared room or session. || `username` | `string` | Name of the current user; used to track and label cursors. |++## Further reading++- [Realtime Broadcast](https://supabase.com/docs/guides/realtime/broadcast)+- [Realtime authorization](https://supabase.com/docs/guides/realtime/authorization)diff --git a/apps/ui-library/content/docs/react/client.mdx b/apps/ui-library/content/docs/react/client.mdxindex 0fb6d21e667..53a23ed0e21 100644--- a/apps/ui-library/content/docs/react/client.mdx+++ b/apps/ui-library/content/docs/react/client.mdx@@ -29,3 +29,7 @@ VITE_SUPABASE_ANON_KEY=- If you're using supabase.com, you can find these values in the [Connect modal](https://supabase.com/dashboard/project/_?showConnect=true) under App Frameworks or in your project's [API settings](https://supabase.com/dashboard/project/_/settings/api).- If you're using a local instance of Supabase, you can find these values by running `supabase start` or `supabase status` (if you already have it running).++## Further reading++- [Generating TypeScript types for your client](https://supabase.com/docs/guides/api/rest/generating-types)diff --git a/apps/ui-library/content/docs/react/current-user-avatar.mdx b/apps/ui-library/content/docs/react/current-user-avatar.mdxindex ce3e0cd241a..41c59e42776 100644--- a/apps/ui-library/content/docs/react/current-user-avatar.mdx+++ b/apps/ui-library/content/docs/react/current-user-avatar.mdx@@ -40,3 +40,7 @@ export default CurrentUserAvatarDemo## PropsThis component doesn't accept any props. If you wish to change the fallback, you can do so by changing the `CurrentUserAvatar` component directly.++## Further reading++- [Auth users](https://supabase.com/docs/guides/auth/users)diff --git a/apps/ui-library/content/docs/react/dropzone.mdx b/apps/ui-library/content/docs/react/dropzone.mdxindex 42dd37cb265..8072795254b 100644--- a/apps/ui-library/content/docs/react/dropzone.mdx+++ b/apps/ui-library/content/docs/react/dropzone.mdx@@ -79,3 +79,9 @@ export FileUploadDemo| `allowedMimeTypes` | `string[]` | `[]` | The MIME types to allow for upload || `maxFiles` | `number` | `1` | Maximum number of files to upload || `maxFileSize` | `number` | `1000` | Maximum file size in bytes |++## Further reading++- [Creating buckets](https://supabase.com/docs/guides/storage/buckets/creating-buckets)+- [Access control](https://supabase.com/docs/guides/storage/security/access-control)+- [Standard uploads](https://supabase.com/docs/guides/storage/uploads/standard-uploads)diff --git a/apps/ui-library/content/docs/react/password-based-auth.mdx b/apps/ui-library/content/docs/react/password-based-auth.mdxindex 9c7f025a738..49e860a43e0 100644--- a/apps/ui-library/content/docs/react/password-based-auth.mdx+++ b/apps/ui-library/content/docs/react/password-based-auth.mdx@@ -33,38 +33,6 @@ VITE_SUPABASE_ANON_KEY=- If you're using a local instance of Supabase, you can find these values by running `supabase start` or `supabase status` (if you already have it running).-### Adding email templates--1. Add an [email template for sign-up](https://supabase.com/dashboard/project/_/auth/templates) to the Supabase project. Your signup email template should contain at least the following HTML:-- ```html- <h2>Confirm your signup</h2>-- <p>Follow this link to confirm your user:</p>- <p>- <a- href="{{ .SiteURL }}/auth/confirm?token_hash={{ .TokenHash }}&type=email&next={{ .RedirectTo }}"- >Confirm your email</a- >- </p>- ```-- For detailed instructions on how to configure your email templates, including the use of variables like `{{ .SiteURL }}`,`{{ .TokenHash }}`, and `{{ .RedirectTo }}`, refer to our [Email Templates guide](https://supabase.com/docs/email-templates).--1. Add an [email template for reset password](https://supabase.com/dashboard/project/_/auth/templates) to the Supabase project. Your reset password email template should contain at least the following HTML:-- ```html- <h2>Reset Password</h2>-- <p>Follow this link to reset the password for your user:</p>- <p>- <a- href="{{ .SiteURL }}/auth/confirm?token_hash={{ .TokenHash }}&type=recovery&next={{ .RedirectTo }}"- >Reset Password</a- >- </p>- ```-### Setting up routes and redirect URLs1. Set the site URL in the [URL Configuration](https://supabase.com/dashboard/project/_/auth/url-configuration) settings in the Supabase Dashboard.@@ -73,10 +41,6 @@ VITE_SUPABASE_ANON_KEY=1. Add the following code in the authenticated route to redirect to login if the user is unauthenticated.-## Examples--### Redirect to `/login` page if the user is unauthenticated-```tsimport { useEffect } from "react"import { createClient } from "@supabase/supabase-js"@@ -98,23 +62,10 @@ export default function AuthenticatedRoute() {}```-### Redirect to `/profile` page if the user is authenticated--```ts-import { useEffect } from "react";-import { createClient } from "@supabase/supabase-js"--export default function AuthenticatedRoute() {- useEffect(() => {- const checkAuth = async () => {- const client = createClient()- const { user } = await client.auth.getUser()-- user ? location.href = "/profile" : location.href = "/login"- }- checkAuth()- }, [])+## Further reading- return <div>Profile page</div>-}-```+- [Password-based authentication (implicit flow)](https://supabase.com/docs/guides/auth/passwords?queryGroups=flow&flow=implicit)+- [Authentication error codes](https://supabase.com/docs/guides/auth/debugging/error-codes)+- [Email templates](https://supabase.com/docs/guides/auth/auth-email-templates)+- [Email templates for local development](https://supabase.com/docs/guides/local-development/customizing-email-templates)+- [Custom SMTP](https://supabase.com/docs/guides/auth/auth-smtp)diff --git a/apps/ui-library/content/docs/react/realtime-avatar-stack.mdx b/apps/ui-library/content/docs/react/realtime-avatar-stack.mdxindex 6ba200fde57..b934c99d313 100644--- a/apps/ui-library/content/docs/react/realtime-avatar-stack.mdx+++ b/apps/ui-library/content/docs/react/realtime-avatar-stack.mdx@@ -38,3 +38,8 @@ export default function Page() {| Prop | Type | Default | Description || ---------- | -------- | ------- | ---------------------------------------------------- || `roomName` | `string` | `null` | The name of the Supabase Realtime room to connect to |++## Further reading++- [Realtime Presence](https://supabase.com/docs/guides/realtime/presence)+- [Realtime authorization](https://supabase.com/docs/guides/realtime/authorization)diff --git a/apps/ui-library/content/docs/react/realtime-chat.mdx b/apps/ui-library/content/docs/react/realtime-chat.mdxindex 795c0a5cc7e..b97eab4cfef 100644--- a/apps/ui-library/content/docs/react/realtime-chat.mdx+++ b/apps/ui-library/content/docs/react/realtime-chat.mdx@@ -96,3 +96,8 @@ interface ChatMessage {createdAt: string}```++## Further reading++- [Realtime Broadcast](https://supabase.com/docs/guides/realtime/broadcast)+- [Realtime authorization](https://supabase.com/docs/guides/realtime/authorization)diff --git a/apps/ui-library/content/docs/react/realtime-cursor.mdx b/apps/ui-library/content/docs/react/realtime-cursor.mdxindex e368ada52e7..43acb4cf05e 100644--- a/apps/ui-library/content/docs/react/realtime-cursor.mdx+++ b/apps/ui-library/content/docs/react/realtime-cursor.mdx@@ -53,3 +53,8 @@ export default function Page() {| ---------- | -------- | ---------------------------------------------------------- || `roomName` | `string` | Unique identifier for the shared room or session. || `username` | `string` | Name of the current user; used to track and label cursors. |++## Further reading++- [Realtime Broadcast](https://supabase.com/docs/guides/realtime/broadcast)+- [Realtime authorization](https://supabase.com/docs/guides/realtime/authorization)diff --git a/apps/ui-library/content/docs/tanstack/client.mdx b/apps/ui-library/content/docs/tanstack/client.mdxindex e713ebd6616..dc9477629f8 100644--- a/apps/ui-library/content/docs/tanstack/client.mdx+++ b/apps/ui-library/content/docs/tanstack/client.mdx@@ -29,3 +29,7 @@ VITE_SUPABASE_ANON_KEY=- If you're using supabase.com, you can find these values in the [Connect modal](https://supabase.com/dashboard/project/_?showConnect=true) under App Frameworks or in your project's [API settings](https://supabase.com/dashboard/project/_/settings/api).- If you're using a local instance of Supabase, you can find these values by running `supabase start` or `supabase status` (if you already have it running).++## Further reading++- [Generating TypeScript types for your client](https://supabase.com/docs/guides/api/rest/generating-types)diff --git a/apps/ui-library/content/docs/tanstack/current-user-avatar.mdx b/apps/ui-library/content/docs/tanstack/current-user-avatar.mdxindex 59f7b55c52e..5beca8bca7a 100644--- a/apps/ui-library/content/docs/tanstack/current-user-avatar.mdx+++ b/apps/ui-library/content/docs/tanstack/current-user-avatar.mdx@@ -43,3 +43,7 @@ export default CurrentUserAvatarDemo## PropsThis component doesn't accept any props. If you wish to change the fallback, you can do so by changing the `CurrentUserAvatar` component directly.++## Further reading++- [Auth users](https://supabase.com/docs/guides/auth/users)diff --git a/apps/ui-library/content/docs/tanstack/dropzone.mdx b/apps/ui-library/content/docs/tanstack/dropzone.mdxindex cddb750a053..90e1a47e714 100644--- a/apps/ui-library/content/docs/tanstack/dropzone.mdx+++ b/apps/ui-library/content/docs/tanstack/dropzone.mdx@@ -79,3 +79,9 @@ export FileUploadDemo| `allowedMimeTypes` | `string[]` | `[]` | The MIME types to allow for upload || `maxFiles` | `number` | `1` | Maximum number of files to upload || `maxFileSize` | `number` | `1000` | Maximum file size in bytes |++## Further reading++- [Creating buckets](https://supabase.com/docs/guides/storage/buckets/creating-buckets)+- [Access control](https://supabase.com/docs/guides/storage/security/access-control)+- [Standard uploads](https://supabase.com/docs/guides/storage/uploads/standard-uploads)diff --git a/apps/ui-library/content/docs/tanstack/password-based-auth.mdx b/apps/ui-library/content/docs/tanstack/password-based-auth.mdxindex 42a5d01a301..ae09e0c101f 100644--- a/apps/ui-library/content/docs/tanstack/password-based-auth.mdx+++ b/apps/ui-library/content/docs/tanstack/password-based-auth.mdx@@ -68,3 +68,11 @@ VITE_SUPABASE_ANON_KEY=1. Set up the route users will visit to reset or update their password. Go to the [URL Configuration](https://supabase.com/dashboard/project/_/auth/url-configuration) settings and add the `forgot-password` route to the list of Redirect URLs. It should look something like: `http://example.com/auth/forgot-password`.1. Update the redirect paths in the `login.tsx` and `update-password.tsx` components to point to the logged-in routes in your app.++## Further reading++- [Password-based authentication (PKCE flow)](https://supabase.com/docs/guides/auth/passwords?queryGroups=flow&flow=pkce)+- [Authentication error codes](https://supabase.com/docs/guides/auth/debugging/error-codes)+- [Email templates](https://supabase.com/docs/guides/auth/auth-email-templates)+- [Email templates for local development](https://supabase.com/docs/guides/local-development/customizing-email-templates)+- [Custom SMTP](https://supabase.com/docs/guides/auth/auth-smtp)diff --git a/apps/ui-library/content/docs/tanstack/realtime-avatar-stack.mdx b/apps/ui-library/content/docs/tanstack/realtime-avatar-stack.mdxindex 26dd223b0aa..dc133162d95 100644--- a/apps/ui-library/content/docs/tanstack/realtime-avatar-stack.mdx+++ b/apps/ui-library/content/docs/tanstack/realtime-avatar-stack.mdx@@ -38,3 +38,8 @@ export default function Page() {| Prop | Type | Default | Description || ---------- | -------- | ------- | ---------------------------------------------------- || `roomName` | `string` | `null` | The name of the Supabase Realtime room to connect to |++## Further reading++- [Realtime Presence](https://supabase.com/docs/guides/realtime/presence)+- [Realtime authorization](https://supabase.com/docs/guides/realtime/authorization)diff --git a/apps/ui-library/content/docs/tanstack/realtime-chat.mdx b/apps/ui-library/content/docs/tanstack/realtime-chat.mdxindex aebddc45a08..f77241ce200 100644--- a/apps/ui-library/content/docs/tanstack/realtime-chat.mdx+++ b/apps/ui-library/content/docs/tanstack/realtime-chat.mdx@@ -96,3 +96,8 @@ interface ChatMessage {createdAt: string}```++## Further reading++- [Realtime Broadcast](https://supabase.com/docs/guides/realtime/broadcast)+- [Realtime authorization](https://supabase.com/docs/guides/realtime/authorization)diff --git a/apps/ui-library/content/docs/tanstack/realtime-cursor.mdx b/apps/ui-library/content/docs/tanstack/realtime-cursor.mdxindex 5dbc26a91f8..8ef0cebddd5 100644--- a/apps/ui-library/content/docs/tanstack/realtime-cursor.mdx+++ b/apps/ui-library/content/docs/tanstack/realtime-cursor.mdx@@ -53,3 +53,8 @@ export default function Page() {| ---------- | -------- | ---------------------------------------------------------- || `roomName` | `string` | Unique identifier for the shared room or session. || `username` | `string` | Name of the current user; used to track and label cursors. |++## Further reading++- [Realtime Broadcast](https://supabase.com/docs/guides/realtime/broadcast)+- [Realtime authorization](https://supabase.com/docs/guides/realtime/authorization)diff --git a/apps/ui-library/public/r/current-user-avatar-nextjs.json b/apps/ui-library/public/r/current-user-avatar-nextjs.jsonindex 405dfa29dd7..fdad8a7e547 100644--- a/apps/ui-library/public/r/current-user-avatar-nextjs.json+++ b/apps/ui-library/public/r/current-user-avatar-nextjs.json@@ -5,7 +5,8 @@"title": "Current User Avatar","description": "Component which renders the current user's avatar.","dependencies": [- "@supabase/ssr@latest"+ "@supabase/ssr@latest",+ "@supabase/supabase-js@latest"],"registryDependencies": ["avatar"diff --git a/apps/ui-library/public/r/dropzone-nextjs.json b/apps/ui-library/public/r/dropzone-nextjs.jsonindex 2b5cae2d2a4..90a24b844be 100644--- a/apps/ui-library/public/r/dropzone-nextjs.json+++ b/apps/ui-library/public/r/dropzone-nextjs.json@@ -7,7 +7,8 @@"dependencies": ["react-dropzone","lucide-react",- "@supabase/ssr@latest"+ "@supabase/ssr@latest",+ "@supabase/supabase-js@latest"],"registryDependencies": ["button"diff --git a/apps/ui-library/public/r/realtime-avatar-stack-nextjs.json b/apps/ui-library/public/r/realtime-avatar-stack-nextjs.jsonindex b852d452642..266c4bd64af 100644--- a/apps/ui-library/public/r/realtime-avatar-stack-nextjs.json+++ b/apps/ui-library/public/r/realtime-avatar-stack-nextjs.json@@ -5,7 +5,8 @@"title": "Avatar Stack with Realtime Presence","description": "Component which stack of avatars, tracked by realtime presence.","dependencies": [- "@supabase/ssr@latest"+ "@supabase/ssr@latest",+ "@supabase/supabase-js@latest"],"registryDependencies": ["avatar",diff --git a/apps/ui-library/public/r/realtime-chat-nextjs.json b/apps/ui-library/public/r/realtime-chat-nextjs.jsonindex 01116d924ff..bd6e5845d37 100644--- a/apps/ui-library/public/r/realtime-chat-nextjs.json+++ b/apps/ui-library/public/r/realtime-chat-nextjs.json@@ -6,7 +6,8 @@"description": "Component which renders realtime chat messages from other users in a room.","dependencies": ["lucide-react",- "@supabase/ssr@latest"+ "@supabase/ssr@latest",+ "@supabase/supabase-js@latest"],"registryDependencies": ["input",@@ -15,7 +16,7 @@"files": [{"path": "registry/default/blocks/realtime-chat/components/chat-message.tsx",- "content": "import { cn } from '@/lib/utils'\nimport type { ChatMessage } from '@/registry/default/blocks/realtime-chat/hooks/use-realtime-chat'\n\ninterface ChatMessageItemProps {\n message: ChatMessage\n isOwnMessage: boolean\n showHeader: boolean\n}\n\nexport const ChatMessageItem = ({ message, isOwnMessage, showHeader }: ChatMessageItemProps) => {\n return (\n <div className={`flex mt-2 ${isOwnMessage ? 'justify-end' : 'justify-start'}`}>\n <div\n className={cn('max-w-[70%] w-fit flex flex-col gap-1', {\n 'items-end': isOwnMessage,\n })}\n >\n {showHeader && (\n <div className=\"flex items-center gap-2 text-xs\">\n <span className={'font-medium'}>{message.user.name}</span>\n <span className=\"text-foreground/50 text-xs\">\n {new Date(message.createdAt).toLocaleTimeString([], {\n hour: '2-digit',\n minute: '2-digit',\n })}\n </span>\n </div>\n )}\n <div\n className={cn(\n 'py-1 px-2 rounded-xl text-sm w-fit',\n isOwnMessage ? 'bg-accent-foreground text-background' : 'bg-secondary text-foreground'\n )}\n >\n {message.content}\n </div>\n </div>\n </div>\n )\n}\n",+ "content": "import { cn } from '@/lib/utils'\nimport type { ChatMessage } from '@/registry/default/blocks/realtime-chat/hooks/use-realtime-chat'\n\ninterface ChatMessageItemProps {\n message: ChatMessage\n isOwnMessage: boolean\n showHeader: boolean\n}\n\nexport const ChatMessageItem = ({ message, isOwnMessage, showHeader }: ChatMessageItemProps) => {\n return (\n <div className={`flex mt-2 ${isOwnMessage ? 'justify-end' : 'justify-start'}`}>\n <div\n className={cn('max-w-[70%] w-fit flex flex-col gap-1', {\n 'items-end': isOwnMessage,\n })}\n >\n {showHeader && (\n <div className=\"flex items-center gap-2 text-xs\">\n <span className={'font-medium'}>{message.user.name}</span>\n <span className=\"text-foreground/50 text-xs\">\n {new Date(message.createdAt).toLocaleTimeString('en-US', {\n hour: '2-digit',\n minute: '2-digit',\n hour12: true,\n })}\n </span>\n </div>\n )}\n <div\n className={cn(\n 'py-1 px-2 rounded-xl text-sm w-fit',\n isOwnMessage ? 'bg-accent-foreground text-background' : 'bg-secondary text-foreground'\n )}\n >\n {message.content}\n </div>\n </div>\n </div>\n )\n}\n","type": "registry:component"},{diff --git a/apps/ui-library/public/r/realtime-chat-react-router.json b/apps/ui-library/public/r/realtime-chat-react-router.jsonindex bf378f01d66..e3ecb1887e9 100644--- a/apps/ui-library/public/r/realtime-chat-react-router.json+++ b/apps/ui-library/public/r/realtime-chat-react-router.json@@ -16,7 +16,7 @@"files": [{"path": "registry/default/blocks/realtime-chat/components/chat-message.tsx",- "content": "import { cn } from '@/lib/utils'\nimport type { ChatMessage } from '@/registry/default/blocks/realtime-chat/hooks/use-realtime-chat'\n\ninterface ChatMessageItemProps {\n message: ChatMessage\n isOwnMessage: boolean\n showHeader: boolean\n}\n\nexport const ChatMessageItem = ({ message, isOwnMessage, showHeader }: ChatMessageItemProps) => {\n return (\n <div className={`flex mt-2 ${isOwnMessage ? 'justify-end' : 'justify-start'}`}>\n <div\n className={cn('max-w-[70%] w-fit flex flex-col gap-1', {\n 'items-end': isOwnMessage,\n })}\n >\n {showHeader && (\n <div className=\"flex items-center gap-2 text-xs\">\n <span className={'font-medium'}>{message.user.name}</span>\n <span className=\"text-foreground/50 text-xs\">\n {new Date(message.createdAt).toLocaleTimeString([], {\n hour: '2-digit',\n minute: '2-digit',\n })}\n </span>\n </div>\n )}\n <div\n className={cn(\n 'py-1 px-2 rounded-xl text-sm w-fit',\n isOwnMessage ? 'bg-accent-foreground text-background' : 'bg-secondary text-foreground'\n )}\n >\n {message.content}\n </div>\n </div>\n </div>\n )\n}\n",+ "content": "import { cn } from '@/lib/utils'\nimport type { ChatMessage } from '@/registry/default/blocks/realtime-chat/hooks/use-realtime-chat'\n\ninterface ChatMessageItemProps {\n message: ChatMessage\n isOwnMessage: boolean\n showHeader: boolean\n}\n\nexport const ChatMessageItem = ({ message, isOwnMessage, showHeader }: ChatMessageItemProps) => {\n return (\n <div className={`flex mt-2 ${isOwnMessage ? 'justify-end' : 'justify-start'}`}>\n <div\n className={cn('max-w-[70%] w-fit flex flex-col gap-1', {\n 'items-end': isOwnMessage,\n })}\n >\n {showHeader && (\n <div className=\"flex items-center gap-2 text-xs\">\n <span className={'font-medium'}>{message.user.name}</span>\n <span className=\"text-foreground/50 text-xs\">\n {new Date(message.createdAt).toLocaleTimeString('en-US', {\n hour: '2-digit',\n minute: '2-digit',\n hour12: true,\n })}\n </span>\n </div>\n )}\n <div\n className={cn(\n 'py-1 px-2 rounded-xl text-sm w-fit',\n isOwnMessage ? 'bg-accent-foreground text-background' : 'bg-secondary text-foreground'\n )}\n >\n {message.content}\n </div>\n </div>\n </div>\n )\n}\n","type": "registry:component"},{diff --git a/apps/ui-library/public/r/realtime-chat-react.json b/apps/ui-library/public/r/realtime-chat-react.jsonindex f3095406be0..14a1336fe7f 100644--- a/apps/ui-library/public/r/realtime-chat-react.json+++ b/apps/ui-library/public/r/realtime-chat-react.json@@ -15,7 +15,7 @@"files": [{"path": "registry/default/blocks/realtime-chat/components/chat-message.tsx",- "content": "import { cn } from '@/lib/utils'\nimport type { ChatMessage } from '@/registry/default/blocks/realtime-chat/hooks/use-realtime-chat'\n\ninterface ChatMessageItemProps {\n message: ChatMessage\n isOwnMessage: boolean\n showHeader: boolean\n}\n\nexport const ChatMessageItem = ({ message, isOwnMessage, showHeader }: ChatMessageItemProps) => {\n return (\n <div className={`flex mt-2 ${isOwnMessage ? 'justify-end' : 'justify-start'}`}>\n <div\n className={cn('max-w-[70%] w-fit flex flex-col gap-1', {\n 'items-end': isOwnMessage,\n })}\n >\n {showHeader && (\n <div className=\"flex items-center gap-2 text-xs\">\n <span className={'font-medium'}>{message.user.name}</span>\n <span className=\"text-foreground/50 text-xs\">\n {new Date(message.createdAt).toLocaleTimeString([], {\n hour: '2-digit',\n minute: '2-digit',\n })}\n </span>\n </div>\n )}\n <div\n className={cn(\n 'py-1 px-2 rounded-xl text-sm w-fit',\n isOwnMessage ? 'bg-accent-foreground text-background' : 'bg-secondary text-foreground'\n )}\n >\n {message.content}\n </div>\n </div>\n </div>\n )\n}\n",+ "content": "import { cn } from '@/lib/utils'\nimport type { ChatMessage } from '@/registry/default/blocks/realtime-chat/hooks/use-realtime-chat'\n\ninterface ChatMessageItemProps {\n message: ChatMessage\n isOwnMessage: boolean\n showHeader: boolean\n}\n\nexport const ChatMessageItem = ({ message, isOwnMessage, showHeader }: ChatMessageItemProps) => {\n return (\n <div className={`flex mt-2 ${isOwnMessage ? 'justify-end' : 'justify-start'}`}>\n <div\n className={cn('max-w-[70%] w-fit flex flex-col gap-1', {\n 'items-end': isOwnMessage,\n })}\n >\n {showHeader && (\n <div className=\"flex items-center gap-2 text-xs\">\n <span className={'font-medium'}>{message.user.name}</span>\n <span className=\"text-foreground/50 text-xs\">\n {new Date(message.createdAt).toLocaleTimeString('en-US', {\n hour: '2-digit',\n minute: '2-digit',\n hour12: true,\n })}\n </span>\n </div>\n )}\n <div\n className={cn(\n 'py-1 px-2 rounded-xl text-sm w-fit',\n isOwnMessage ? 'bg-accent-foreground text-background' : 'bg-secondary text-foreground'\n )}\n >\n {message.content}\n </div>\n </div>\n </div>\n )\n}\n","type": "registry:component"},{diff --git a/apps/ui-library/public/r/realtime-chat-tanstack.json b/apps/ui-library/public/r/realtime-chat-tanstack.jsonindex 269745ca283..f881126818b 100644--- a/apps/ui-library/public/r/realtime-chat-tanstack.json+++ b/apps/ui-library/public/r/realtime-chat-tanstack.json@@ -16,7 +16,7 @@"files": [{"path": "registry/default/blocks/realtime-chat/components/chat-message.tsx",- "content": "import { cn } from '@/lib/utils'\nimport type { ChatMessage } from '@/registry/default/blocks/realtime-chat/hooks/use-realtime-chat'\n\ninterface ChatMessageItemProps {\n message: ChatMessage\n isOwnMessage: boolean\n showHeader: boolean\n}\n\nexport const ChatMessageItem = ({ message, isOwnMessage, showHeader }: ChatMessageItemProps) => {\n return (\n <div className={`flex mt-2 ${isOwnMessage ? 'justify-end' : 'justify-start'}`}>\n <div\n className={cn('max-w-[70%] w-fit flex flex-col gap-1', {\n 'items-end': isOwnMessage,\n })}\n >\n {showHeader && (\n <div className=\"flex items-center gap-2 text-xs\">\n <span className={'font-medium'}>{message.user.name}</span>\n <span className=\"text-foreground/50 text-xs\">\n {new Date(message.createdAt).toLocaleTimeString([], {\n hour: '2-digit',\n minute: '2-digit',\n })}\n </span>\n </div>\n )}\n <div\n className={cn(\n 'py-1 px-2 rounded-xl text-sm w-fit',\n isOwnMessage ? 'bg-accent-foreground text-background' : 'bg-secondary text-foreground'\n )}\n >\n {message.content}\n </div>\n </div>\n </div>\n )\n}\n",+ "content": "import { cn } from '@/lib/utils'\nimport type { ChatMessage } from '@/registry/default/blocks/realtime-chat/hooks/use-realtime-chat'\n\ninterface ChatMessageItemProps {\n message: ChatMessage\n isOwnMessage: boolean\n showHeader: boolean\n}\n\nexport const ChatMessageItem = ({ message, isOwnMessage, showHeader }: ChatMessageItemProps) => {\n return (\n <div className={`flex mt-2 ${isOwnMessage ? 'justify-end' : 'justify-start'}`}>\n <div\n className={cn('max-w-[70%] w-fit flex flex-col gap-1', {\n 'items-end': isOwnMessage,\n })}\n >\n {showHeader && (\n <div className=\"flex items-center gap-2 text-xs\">\n <span className={'font-medium'}>{message.user.name}</span>\n <span className=\"text-foreground/50 text-xs\">\n {new Date(message.createdAt).toLocaleTimeString('en-US', {\n hour: '2-digit',\n minute: '2-digit',\n hour12: true,\n })}\n </span>\n </div>\n )}\n <div\n className={cn(\n 'py-1 px-2 rounded-xl text-sm w-fit',\n isOwnMessage ? 'bg-accent-foreground text-background' : 'bg-secondary text-foreground'\n )}\n >\n {message.content}\n </div>\n </div>\n </div>\n )\n}\n","type": "registry:component"},{diff --git a/apps/ui-library/public/r/realtime-cursor-nextjs.json b/apps/ui-library/public/r/realtime-cursor-nextjs.jsonindex 12155a4af05..d1b40c3eda4 100644--- a/apps/ui-library/public/r/realtime-cursor-nextjs.json+++ b/apps/ui-library/public/r/realtime-cursor-nextjs.json@@ -6,7 +6,8 @@"description": "Component which renders realtime cursors from other users in a room.","dependencies": ["lucide-react",- "@supabase/ssr@latest"+ "@supabase/ssr@latest",+ "@supabase/supabase-js@latest"],"registryDependencies": [],"files": [diff --git a/apps/ui-library/public/r/supabase-client-nextjs.json b/apps/ui-library/public/r/supabase-client-nextjs.jsonindex e22f4552654..8d90fc90cd1 100644--- a/apps/ui-library/public/r/supabase-client-nextjs.json+++ b/apps/ui-library/public/r/supabase-client-nextjs.json@@ -5,7 +5,8 @@"title": "Supabase Client for Next.js","description": "","dependencies": [- "@supabase/ssr@latest"+ "@supabase/ssr@latest",+ "@supabase/supabase-js@latest"],"registryDependencies": [],"files": [@@ -24,5 +25,6 @@"content": "import { createServerClient } from '@supabase/ssr'\nimport { cookies } from 'next/headers'\n\nexport async function createClient() {\n const cookieStore = await cookies()\n\n return createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return cookieStore.getAll()\n },\n setAll(cookiesToSet) {\n try {\n cookiesToSet.forEach(({ name, value, options }) =>\n cookieStore.set(name, value, options)\n )\n } catch {\n // The `setAll` method was called from a Server Component.\n // This can be ignored if you have middleware refreshing\n // user sessions.\n }\n },\n },\n }\n )\n}\n","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to add a `.env` file with the following environment variables to your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/supabase-client-react-router.json b/apps/ui-library/public/r/supabase-client-react-router.jsonindex 11764c21df5..9819cc7e320 100644--- a/apps/ui-library/public/r/supabase-client-react-router.json+++ b/apps/ui-library/public/r/supabase-client-react-router.json@@ -20,5 +20,6 @@"content": "import { createServerClient, parseCookieHeader, serializeCookieHeader } from '@supabase/ssr'\n\nexport function createClient(request: Request) {\n const headers = new Headers()\n\n const supabase = createServerClient(\n process.env.VITE_SUPABASE_URL!,\n process.env.VITE_SUPABASE_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return parseCookieHeader(request.headers.get('Cookie') ?? '') as {\n name: string\n value: string\n }[]\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value, options }) =>\n headers.append('Set-Cookie', serializeCookieHeader(name, value, options))\n )\n },\n },\n }\n )\n\n return { supabase, headers }\n}\n","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to add a `.env` file with the following environment variables to your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/supabase-client-react.json b/apps/ui-library/public/r/supabase-client-react.jsonindex d1eaa30d2c2..1878fd2215d 100644--- a/apps/ui-library/public/r/supabase-client-react.json+++ b/apps/ui-library/public/r/supabase-client-react.json@@ -14,5 +14,6 @@"content": "import { createClient as createSupabaseClient } from '@supabase/supabase-js'\n\nexport function createClient() {\n return createSupabaseClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to add a `.env` file with the following environment variables to your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/supabase-client-tanstack.json b/apps/ui-library/public/r/supabase-client-tanstack.jsonindex 26047e045e9..b89f1ee6957 100644--- a/apps/ui-library/public/r/supabase-client-tanstack.json+++ b/apps/ui-library/public/r/supabase-client-tanstack.json@@ -20,5 +20,6 @@"content": "import { createServerClient } from '@supabase/ssr'\nimport { parseCookies, setCookie } from '@tanstack/react-start/server'\n\nexport function createClient() {\n return createServerClient(process.env.VITE_SUPABASE_URL!, process.env.VITE_SUPABASE_ANON_KEY!, {\n cookies: {\n getAll() {\n return Object.entries(parseCookies()).map(\n ([name, value]) =>\n ({\n name,\n value,\n }) as { name: string; value: string }\n )\n },\n setAll(cookies) {\n cookies.forEach((cookie) => {\n setCookie(cookie.name, cookie.value)\n })\n },\n },\n })\n}\n","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to add a `.env` file with the following environment variables to your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/registry.json b/apps/ui-library/registry.jsonindex 93347e46a9d..626e08c679b 100644--- a/apps/ui-library/registry.json+++ b/apps/ui-library/registry.json@@ -278,7 +278,12 @@"title": "Dropzone (File Upload)","description": "Displays a control for easier uploading of files directly to Supabase Storage.","registryDependencies": ["button"],- "dependencies": ["react-dropzone", "lucide-react", "@supabase/ssr@latest"],+ "dependencies": [+ "react-dropzone",+ "lucide-react",+ "@supabase/ssr@latest",+ "@supabase/supabase-js@latest"+ ],"files": [{"path": "registry/default/blocks/dropzone/components/dropzone.tsx",@@ -396,7 +401,7 @@"title": "Realtime Cursor","description": "Component which renders realtime cursors from other users in a room.","registryDependencies": [],- "dependencies": ["lucide-react", "@supabase/ssr@latest"],+ "dependencies": ["lucide-react", "@supabase/ssr@latest", "@supabase/supabase-js@latest"],"files": [{"path": "registry/default/blocks/realtime-cursor/components/cursor.tsx",@@ -520,7 +525,7 @@"title": "Current User Avatar","description": "Component which renders the current user's avatar.","registryDependencies": ["avatar"],- "dependencies": ["@supabase/ssr@latest"],+ "dependencies": ["@supabase/ssr@latest", "@supabase/supabase-js@latest"],"files": [{"path": "registry/default/blocks/current-user-avatar/components/current-user-avatar.tsx",@@ -644,7 +649,7 @@"title": "Avatar Stack with Realtime Presence","description": "Component which stack of avatars, tracked by realtime presence.","registryDependencies": ["avatar", "tooltip"],- "dependencies": ["@supabase/ssr@latest"],+ "dependencies": ["@supabase/ssr@latest", "@supabase/supabase-js@latest"],"files": [{"path": "registry/default/blocks/realtime-avatar-stack/components/avatar-stack.tsx",@@ -800,7 +805,7 @@"title": "Realtime Chat","description": "Component which renders realtime chat messages from other users in a room.","registryDependencies": ["input", "button"],- "dependencies": ["lucide-react", "@supabase/ssr@latest"],+ "dependencies": ["lucide-react", "@supabase/ssr@latest", "@supabase/supabase-js@latest"],"files": [{"path": "registry/default/blocks/realtime-chat/components/chat-message.tsx",@@ -940,7 +945,8 @@"title": "Supabase Client for Next.js","description": "","registryDependencies": [],- "dependencies": ["@supabase/ssr@latest"],+ "dependencies": ["@supabase/ssr@latest", "@supabase/supabase-js@latest"],+ "docs": "You'll need to add a `.env` file with the following environment variables to your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_ANON_KEY`.","files": [{"path": "registry/default/clients/nextjs/lib/supabase/client.ts",@@ -964,6 +970,7 @@"description": "","registryDependencies": [],"dependencies": ["@supabase/supabase-js@latest"],+ "docs": "You'll need to add a `.env` file with the following environment variables to your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_ANON_KEY`.","files": [{"path": "registry/default/clients/react/lib/supabase/client.ts",@@ -979,6 +986,7 @@"description": "","registryDependencies": [],"dependencies": ["@supabase/ssr@latest", "@supabase/supabase-js@latest"],+ "docs": "You'll need to add a `.env` file with the following environment variables to your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_ANON_KEY`.","files": [{"path": "registry/default/clients/react-router/lib/supabase/client.ts",@@ -998,6 +1006,7 @@"description": "","registryDependencies": [],"dependencies": ["@supabase/ssr@latest", "@supabase/supabase-js@latest"],+ "docs": "You'll need to add a `.env` file with the following environment variables to your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_ANON_KEY`.","files": [{"path": "registry/default/clients/tanstack/lib/supabase/client.ts",diff --git a/apps/ui-library/registry/default/clients/nextjs/registry-item.json b/apps/ui-library/registry/default/clients/nextjs/registry-item.jsonindex 0c0c3247dfc..cd630de3f86 100644--- a/apps/ui-library/registry/default/clients/nextjs/registry-item.json+++ b/apps/ui-library/registry/default/clients/nextjs/registry-item.json@@ -5,7 +5,8 @@"title": "Supabase Client for Next.js","description": "","registryDependencies": [],- "dependencies": ["@supabase/ssr@latest"],+ "dependencies": ["@supabase/ssr@latest", "@supabase/supabase-js@latest"],+ "docs": "You'll need to add a `.env` file with the following environment variables to your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_ANON_KEY`.","files": [{"path": "registry/default/clients/nextjs/lib/supabase/client.ts",diff --git a/apps/ui-library/registry/default/clients/react-router/registry-item.json b/apps/ui-library/registry/default/clients/react-router/registry-item.jsonindex 100d0864634..ef46880ac1f 100644--- a/apps/ui-library/registry/default/clients/react-router/registry-item.json+++ b/apps/ui-library/registry/default/clients/react-router/registry-item.json@@ -6,6 +6,7 @@"description": "","registryDependencies": [],"dependencies": ["@supabase/ssr@latest", "@supabase/supabase-js@latest"],+ "docs": "You'll need to add a `.env` file with the following environment variables to your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_ANON_KEY`.","files": [{"path": "registry/default/clients/react-router/lib/supabase/client.ts",diff --git a/apps/ui-library/registry/default/clients/react/registry-item.json b/apps/ui-library/registry/default/clients/react/registry-item.jsonindex 64e69750305..b8e429862d2 100644--- a/apps/ui-library/registry/default/clients/react/registry-item.json+++ b/apps/ui-library/registry/default/clients/react/registry-item.json@@ -6,6 +6,7 @@"description": "","registryDependencies": [],"dependencies": ["@supabase/supabase-js@latest"],+ "docs": "You'll need to add a `.env` file with the following environment variables to your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_ANON_KEY`.","files": [{"path": "registry/default/clients/react/lib/supabase/client.ts",diff --git a/apps/ui-library/registry/default/clients/tanstack/registry-item.json b/apps/ui-library/registry/default/clients/tanstack/registry-item.jsonindex 7aeaf49dba9..6effeca667f 100644--- a/apps/ui-library/registry/default/clients/tanstack/registry-item.json+++ b/apps/ui-library/registry/default/clients/tanstack/registry-item.json@@ -6,6 +6,7 @@"description": "","registryDependencies": [],"dependencies": ["@supabase/ssr@latest", "@supabase/supabase-js@latest"],+ "docs": "You'll need to add a `.env` file with the following environment variables to your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_ANON_KEY`.","files": [{"path": "registry/default/clients/tanstack/lib/supabase/client.ts",diff --git a/apps/ui-library/registry/default/examples/realtime-cursor-demo.tsx b/apps/ui-library/registry/default/examples/realtime-cursor-demo.tsxindex 9e4d6c148dd..0232fd53bb6 100644--- a/apps/ui-library/registry/default/examples/realtime-cursor-demo.tsx+++ b/apps/ui-library/registry/default/examples/realtime-cursor-demo.tsx@@ -3,6 +3,8 @@import { RealtimeCursors } from '@/registry/default/blocks/realtime-cursor/components/realtime-cursors'import { Input } from '@/registry/default/components/ui/input'import { Label } from '@/registry/default/components/ui/label'+import { Button } from '@ui/components/shadcn/ui/button'+import { RefreshCcw } from 'lucide-react'import { useEffect, useState } from 'react'import { generateFullName } from './utils'@@ -14,9 +16,20 @@ const RealtimeCursorDemo = () => {}, [])return (- <div className="flex flex-col w-40">+ <div className="flex flex-col w-44"><Label>Username</Label>- <Input value={username} onChange={(e) => setUsername(e.target.value)} />+ <div className="flex items-center gap-2">+ <Input value={username} onChange={(e) => setUsername(e.target.value)} disabled />+ <Button+ variant="secondary"+ size="icon"+ onClick={() => setUsername(generateFullName())}+ className="px-2"+ >+ <RefreshCcw size={18} />+ </Button>+ </div>+<RealtimeCursors roomName="realtime-cursor-example" username={username} /></div>)