The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
fix: Use the new `envVars` property in the `shadcn` blocks (#37585)
Ivan Vasilov0bd892547c26
diff --git a/apps/ui-library/.env b/apps/ui-library/.envindex 47ab9bf34ed..93da796409a 100644--- a/apps/ui-library/.env+++ b/apps/ui-library/.env@@ -1,5 +1,5 @@# Default to local supabase for local developmentNEXT_PUBLIC_SUPABASE_URL=http://localhost:54321-NEXT_PUBLIC_SUPABASE_ANON_KEY=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZS1kZW1vIiwicm9sZSI6ImFub24iLCJleHAiOjE5ODM4MTI5OTZ9.CRXP1A7WOeoJeXxjNni43kdQwgnWNReilDMblYTn_I0+NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZS1kZW1vIiwicm9sZSI6ImFub24iLCJleHAiOjE5ODM4MTI5OTZ9.CRXP1A7WOeoJeXxjNni43kdQwgnWNReilDMblYTn_I0NEXT_PUBLIC_BASE_PATH=/uiNEXT_PUBLIC_API_URL="http://localhost:8080/platform"\ No newline at end of filediff --git a/apps/ui-library/content/docs/nextjs/client.mdx b/apps/ui-library/content/docs/nextjs/client.mdxindex 6a98134b516..8d3a11ef966 100644--- a/apps/ui-library/content/docs/nextjs/client.mdx+++ b/apps/ui-library/content/docs/nextjs/client.mdx@@ -19,11 +19,11 @@ If you've already set up your Supabase client—either using the `npx create-nex### Getting started-First, add a `.env` file to your project with the following environment variables:+After installing the block, you'll have the following environment variables in your `.env.local` file:```envNEXT_PUBLIC_SUPABASE_URL=-NEXT_PUBLIC_SUPABASE_ANON_KEY=+NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_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).diff --git a/apps/ui-library/content/docs/nextjs/password-based-auth.mdx b/apps/ui-library/content/docs/nextjs/password-based-auth.mdxindex 4dfa417f6a3..3b529b6554e 100644--- a/apps/ui-library/content/docs/nextjs/password-based-auth.mdx+++ b/apps/ui-library/content/docs/nextjs/password-based-auth.mdx@@ -24,11 +24,11 @@ Once you install the block in your Next.js project, you'll get all the necessary### Getting started-First, add a `.env` file to your project with the following environment variables:+After installing the block, you'll have the following environment variables in your `.env.local` file:```envNEXT_PUBLIC_SUPABASE_URL=-NEXT_PUBLIC_SUPABASE_ANON_KEY=+NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_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).diff --git a/apps/ui-library/content/docs/nextjs/social-auth.mdx b/apps/ui-library/content/docs/nextjs/social-auth.mdxindex f4b63cdc2bf..e2290f27ab8 100644--- a/apps/ui-library/content/docs/nextjs/social-auth.mdx+++ b/apps/ui-library/content/docs/nextjs/social-auth.mdx@@ -26,11 +26,11 @@ Once you install the block in your Next.js project, you'll get all the necessary### Getting started-First, add a `.env` file to your project with the following environment variables:+After installing the block, you'll have the following environment variables in your `.env.local` file:```envNEXT_PUBLIC_SUPABASE_URL=-NEXT_PUBLIC_SUPABASE_ANON_KEY=+NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_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).diff --git a/apps/ui-library/content/docs/react-router/client.mdx b/apps/ui-library/content/docs/react-router/client.mdxindex 981860d022d..36292711683 100644--- a/apps/ui-library/content/docs/react-router/client.mdx+++ b/apps/ui-library/content/docs/react-router/client.mdx@@ -19,11 +19,11 @@ If you've already set up Supabase clients in your project, you can just continue### Getting started-First, add a `.env` file to your project with the following environment variables:+After installing the block, you'll have the following environment variables in your `.env.local` file:```envVITE_SUPABASE_URL=-VITE_SUPABASE_ANON_KEY=+VITE_SUPABASE_PUBLISHABLE_OR_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).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 bbe62934e6a..b52f35afdaf 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@@ -24,11 +24,11 @@ Once you install the block in your React Router project, you'll get all the nece### Getting started-First, add a `.env` file to your project with the following environment variables:+After installing the block, you'll have the following environment variables in your `.env.local` file:```envVITE_SUPABASE_URL=-VITE_SUPABASE_ANON_KEY=+VITE_SUPABASE_PUBLISHABLE_OR_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).diff --git a/apps/ui-library/content/docs/react-router/social-auth.mdx b/apps/ui-library/content/docs/react-router/social-auth.mdxindex b45ddcb24ac..3767e4d7e63 100644--- a/apps/ui-library/content/docs/react-router/social-auth.mdx+++ b/apps/ui-library/content/docs/react-router/social-auth.mdx@@ -29,11 +29,11 @@ Once you install the block in your React Router project, you'll get all the nece### Getting started-First, add a `.env` file to your project with the following environment variables:+After installing the block, you'll have the following environment variables in your `.env.local` file:```envVITE_SUPABASE_URL=-VITE_SUPABASE_ANON_KEY=+VITE_SUPABASE_PUBLISHABLE_OR_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).diff --git a/apps/ui-library/content/docs/react/client.mdx b/apps/ui-library/content/docs/react/client.mdxindex 53a23ed0e21..717f0282deb 100644--- a/apps/ui-library/content/docs/react/client.mdx+++ b/apps/ui-library/content/docs/react/client.mdx@@ -19,11 +19,11 @@ If you've already set up a Supabase client in your project, you can just continu### Getting started-First, add a `.env` file to your project with the following environment variables:+After installing the block, you'll have the following environment variables in your `.env.local` file:```envVITE_SUPABASE_URL=-VITE_SUPABASE_ANON_KEY=+VITE_SUPABASE_PUBLISHABLE_OR_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).diff --git a/apps/ui-library/content/docs/react/password-based-auth.mdx b/apps/ui-library/content/docs/react/password-based-auth.mdxindex d1030167403..7544dc1bebf 100644--- a/apps/ui-library/content/docs/react/password-based-auth.mdx+++ b/apps/ui-library/content/docs/react/password-based-auth.mdx@@ -24,11 +24,11 @@ Once you install the block in your React project, you'll get all the necessary p### Getting started-First, add a `.env` file to your project with the following environment variables:+After installing the block, you'll have the following environment variables in your `.env.local` file:```envVITE_SUPABASE_URL=-VITE_SUPABASE_ANON_KEY=+VITE_SUPABASE_PUBLISHABLE_OR_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).diff --git a/apps/ui-library/content/docs/react/social-auth.mdx b/apps/ui-library/content/docs/react/social-auth.mdxindex 79c596f5cd1..62d3747b839 100644--- a/apps/ui-library/content/docs/react/social-auth.mdx+++ b/apps/ui-library/content/docs/react/social-auth.mdx@@ -26,11 +26,11 @@ Once you install the block in your React project, you'll get all the necessary p### Getting started-First, add a `.env` file to your project with the following environment variables:+After installing the block, you'll have the following environment variables in your `.env.local` file:```envVITE_SUPABASE_URL=-VITE_SUPABASE_ANON_KEY=+VITE_SUPABASE_PUBLISHABLE_OR_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).diff --git a/apps/ui-library/content/docs/tanstack/client.mdx b/apps/ui-library/content/docs/tanstack/client.mdxindex db80ba69be7..69f9a96e6a7 100644--- a/apps/ui-library/content/docs/tanstack/client.mdx+++ b/apps/ui-library/content/docs/tanstack/client.mdx@@ -21,11 +21,11 @@ If you've already set up a Supabase client in your project, you can just continu### Getting started-First, add a `.env` file to your project with the following environment variables:+After installing the block, you'll have the following environment variables in your `.env.local` file:```envVITE_SUPABASE_URL=-VITE_SUPABASE_ANON_KEY=+VITE_SUPABASE_PUBLISHABLE_OR_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).diff --git a/apps/ui-library/content/docs/tanstack/password-based-auth.mdx b/apps/ui-library/content/docs/tanstack/password-based-auth.mdxindex 8410a4b5100..be01cf14ed1 100644--- a/apps/ui-library/content/docs/tanstack/password-based-auth.mdx+++ b/apps/ui-library/content/docs/tanstack/password-based-auth.mdx@@ -21,11 +21,11 @@ Once you install the block in your TanStack Start project, you'll get all the ne### Getting started-First, add a `.env` file to your project with the following environment variables:+After installing the block, you'll have the following environment variables in your `.env.local` file:```envVITE_SUPABASE_URL=-VITE_SUPABASE_ANON_KEY=+VITE_SUPABASE_PUBLISHABLE_OR_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).diff --git a/apps/ui-library/content/docs/tanstack/social-auth.mdx b/apps/ui-library/content/docs/tanstack/social-auth.mdxindex 06a584149d6..94c98d39d18 100644--- a/apps/ui-library/content/docs/tanstack/social-auth.mdx+++ b/apps/ui-library/content/docs/tanstack/social-auth.mdx@@ -26,11 +26,11 @@ Once you install the block in your Tanstack Start project, you'll get all the ne### Getting started-First, add a `.env` file to your project with the following environment variables:+After installing the block, you'll have the following environment variables in your `.env.local` file:```envVITE_SUPABASE_URL=-VITE_SUPABASE_ANON_KEY=+VITE_SUPABASE_PUBLISHABLE_OR_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).diff --git a/apps/ui-library/package.json b/apps/ui-library/package.jsonindex b47da318fa6..8886abb7a9d 100644--- a/apps/ui-library/package.json+++ b/apps/ui-library/package.json@@ -105,7 +105,7 @@"react-dropzone": "^14.3.8","react-router": "^7.5.2","rimraf": "^4.1.3",- "shadcn": "2.4.0-canary.16",+ "shadcn": "^2.10.0","shiki": "^1.1.7","tailwindcss": "^3.3.0","tsconfig": "workspace:*",diff --git a/apps/ui-library/public/r/ai-editor-rules.json b/apps/ui-library/public/r/ai-editor-rules.jsonindex 764d88974c1..d2aef7edfca 100644--- a/apps/ui-library/public/r/ai-editor-rules.json+++ b/apps/ui-library/public/r/ai-editor-rules.json@@ -33,7 +33,7 @@},{"path": "registry/default/ai-editor-rules/writing-supabase-edge-functions.mdc",- "content": "---\ndescription: Coding rules for Supabase Edge Functions\nalwaysApply: false\n---\n\n# Writing Supabase Edge Functions\n\nYou're an expert in writing TypeScript and Deno JavaScript runtime. Generate **high-quality Supabase Edge Functions** that adhere to the following best practices:\n\n## Guidelines\n\n1. Try to use Web APIs and Deno’s core APIs instead of external dependencies (eg: use fetch instead of Axios, use WebSockets API instead of node-ws)\n2. If you are reusing utility methods between Edge Functions, add them to `supabase/functions/_shared` and import using a relative path. Do NOT have cross dependencies between Edge Functions.\n3. Do NOT use bare specifiers when importing dependecnies. If you need to use an external dependency, make sure it's prefixed with either `npm:` or `jsr:`. For example, `@supabase/supabase-js` should be written as `npm:@supabase/supabase-js`.\n4. For external imports, always define a version. For example, `npm:@express` should be written as `npm:[email protected]`.\n5. For external dependencies, importing via `npm:` and `jsr:` is preferred. Minimize the use of imports from @`deno.land/x` , `esm.sh` and @`unpkg.com` . If you have a package from one of those CDNs, you can replace the CDN hostname with `npm:` specifier.\n6. You can also use Node built-in APIs. You will need to import them using `node:` specifier. For example, to import Node process: `import process from \"node:process\". Use Node APIs when you find gaps in Deno APIs.\n7. Do NOT use `import { serve } from \"https://deno.land/[email protected]/http/server.ts\"`. Instead use the built-in `Deno.serve`.\n8. Following environment variables (ie. secrets) are pre-populated in both local and hosted Supabase environments. Users don't need to manually set them:\n - SUPABASE_URL\n - SUPABASE_ANON_KEY\n - SUPABASE_SERVICE_ROLE_KEY\n - SUPABASE_DB_URL\n9. To set other environment variables (ie. secrets) users can put them in a env file and run the `supabase secrets set --env-file path/to/env-file`\n10. A single Edge Function can handle multiple routes. It is recommended to use a library like Express or Hono to handle the routes as it's easier for developer to understand and maintain. Each route must be prefixed with `/function-name` so they are routed correctly.\n11. File write operations are ONLY permitted on `/tmp` directory. You can use either Deno or Node File APIs.\n12. Use `EdgeRuntime.waitUntil(promise)` static method to run long-running tasks in the background without blocking response to a request. Do NOT assume it is available in the request / execution context.\n\n## Example Templates\n\n### Simple Hello World Function\n\n```tsx\ninterface reqPayload {\n name: string\n}\n\nconsole.info('server started')\n\nDeno.serve(async (req: Request) => {\n const { name }: reqPayload = await req.json()\n const data = {\n message: `Hello ${name} from foo!`,\n }\n\n return new Response(JSON.stringify(data), {\n headers: { 'Content-Type': 'application/json', Connection: 'keep-alive' },\n })\n})\n```\n\n### Example Function using Node built-in API\n\n```tsx\nimport { randomBytes } from 'node:crypto'\nimport { createServer } from 'node:http'\nimport process from 'node:process'\n\nconst generateRandomString = (length) => {\n const buffer = randomBytes(length)\n return buffer.toString('hex')\n}\n\nconst randomString = generateRandomString(10)\nconsole.log(randomString)\n\nconst server = createServer((req, res) => {\n const message = `Hello`\n res.end(message)\n})\n\nserver.listen(9999)\n```\n\n### Using npm packages in Functions\n\n```tsx\nimport express from 'npm:[email protected]'\n\nconst app = express()\n\napp.get(/(.*)/, (req, res) => {\n res.send('Welcome to Supabase')\n})\n\napp.listen(8000)\n```\n\n### Generate embeddings using built-in @Supabase.ai API\n\n```tsx\nconst model = new Supabase.ai.Session('gte-small')\n\nDeno.serve(async (req: Request) => {\n const params = new URL(req.url).searchParams\n const input = params.get('text')\n const output = await model.run(input, { mean_pool: true, normalize: true })\n return new Response(JSON.stringify(output), {\n headers: {\n 'Content-Type': 'application/json',\n Connection: 'keep-alive',\n },\n })\n})\n```\n",+ "content": "---\ndescription: Coding rules for Supabase Edge Functions\nalwaysApply: false\n---\n\n# Writing Supabase Edge Functions\n\nYou're an expert in writing TypeScript and Deno JavaScript runtime. Generate **high-quality Supabase Edge Functions** that adhere to the following best practices:\n\n## Guidelines\n\n1. Try to use Web APIs and Deno’s core APIs instead of external dependencies (eg: use fetch instead of Axios, use WebSockets API instead of node-ws)\n2. If you are reusing utility methods between Edge Functions, add them to `supabase/functions/_shared` and import using a relative path. Do NOT have cross dependencies between Edge Functions.\n3. Do NOT use bare specifiers when importing dependecnies. If you need to use an external dependency, make sure it's prefixed with either `npm:` or `jsr:`. For example, `@supabase/supabase-js` should be written as `npm:@supabase/supabase-js`.\n4. For external imports, always define a version. For example, `npm:@express` should be written as `npm:[email protected]`.\n5. For external dependencies, importing via `npm:` and `jsr:` is preferred. Minimize the use of imports from @`deno.land/x` , `esm.sh` and @`unpkg.com` . If you have a package from one of those CDNs, you can replace the CDN hostname with `npm:` specifier.\n6. You can also use Node built-in APIs. You will need to import them using `node:` specifier. For example, to import Node process: `import process from \"node:process\". Use Node APIs when you find gaps in Deno APIs.\n7. Do NOT use `import { serve } from \"https://deno.land/[email protected]/http/server.ts\"`. Instead use the built-in `Deno.serve`.\n8. Following environment variables (ie. secrets) are pre-populated in both local and hosted Supabase environments. Users don't need to manually set them:\n - SUPABASE_URL\n - SUPABASE_PUBLISHABLE_OR_ANON_KEY\n - SUPABASE_SERVICE_ROLE_KEY\n - SUPABASE_DB_URL\n9. To set other environment variables (ie. secrets) users can put them in a env file and run the `supabase secrets set --env-file path/to/env-file`\n10. A single Edge Function can handle multiple routes. It is recommended to use a library like Express or Hono to handle the routes as it's easier for developer to understand and maintain. Each route must be prefixed with `/function-name` so they are routed correctly.\n11. File write operations are ONLY permitted on `/tmp` directory. You can use either Deno or Node File APIs.\n12. Use `EdgeRuntime.waitUntil(promise)` static method to run long-running tasks in the background without blocking response to a request. Do NOT assume it is available in the request / execution context.\n\n## Example Templates\n\n### Simple Hello World Function\n\n```tsx\ninterface reqPayload {\n name: string\n}\n\nconsole.info('server started')\n\nDeno.serve(async (req: Request) => {\n const { name }: reqPayload = await req.json()\n const data = {\n message: `Hello ${name} from foo!`,\n }\n\n return new Response(JSON.stringify(data), {\n headers: { 'Content-Type': 'application/json', Connection: 'keep-alive' },\n })\n})\n```\n\n### Example Function using Node built-in API\n\n```tsx\nimport { randomBytes } from 'node:crypto'\nimport { createServer } from 'node:http'\nimport process from 'node:process'\n\nconst generateRandomString = (length) => {\n const buffer = randomBytes(length)\n return buffer.toString('hex')\n}\n\nconst randomString = generateRandomString(10)\nconsole.log(randomString)\n\nconst server = createServer((req, res) => {\n const message = `Hello`\n res.end(message)\n})\n\nserver.listen(9999)\n```\n\n### Using npm packages in Functions\n\n```tsx\nimport express from 'npm:[email protected]'\n\nconst app = express()\n\napp.get(/(.*)/, (req, res) => {\n res.send('Welcome to Supabase')\n})\n\napp.listen(8000)\n```\n\n### Generate embeddings using built-in @Supabase.ai API\n\n```tsx\nconst model = new Supabase.ai.Session('gte-small')\n\nDeno.serve(async (req: Request) => {\n const params = new URL(req.url).searchParams\n const input = params.get('text')\n const output = await model.run(input, { mean_pool: true, normalize: true })\n return new Response(JSON.stringify(output), {\n headers: {\n 'Content-Type': 'application/json',\n Connection: 'keep-alive',\n },\n })\n})\n```\n","type": "registry:file","target": "~/.cursor/rules/writing-supabase-edge-functions.mdc"}diff --git a/apps/ui-library/public/r/current-user-avatar-nextjs.json b/apps/ui-library/public/r/current-user-avatar-nextjs.jsonindex 56ef21e7661..f02a20e9f3f 100644--- a/apps/ui-library/public/r/current-user-avatar-nextjs.json+++ b/apps/ui-library/public/r/current-user-avatar-nextjs.json@@ -29,18 +29,23 @@},{"path": "registry/default/clients/nextjs/lib/supabase/client.ts",- "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/middleware.ts",- "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: DO NOT REMOVE auth.getClaims()\n const { data } = await supabase.auth.getClaims()\n\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n // With Fluid compute, don't put this client in a global environment\n // variable. Always create a new one on each request.\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: If you remove getClaims() and you use server-side rendering\n // with the Supabase client, your users may be randomly logged out.\n const { data } = await supabase.auth.getClaims()\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { cookies } from 'next/headers'\n\n/**\n * If using Fluid compute: Don't put this client in a global variable. Always create a new client within each\n * function when using it.\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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/current-user-avatar-react-router.json b/apps/ui-library/public/r/current-user-avatar-react-router.jsonindex b05d1eff09e..896e80355e6 100644--- a/apps/ui-library/public/r/current-user-avatar-react-router.json+++ b/apps/ui-library/public/r/current-user-avatar-react-router.json@@ -29,13 +29,18 @@},{"path": "registry/default/clients/react-router/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/react-router/lib/supabase/server.ts",- "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",+ "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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/current-user-avatar-react.json b/apps/ui-library/public/r/current-user-avatar-react.jsonindex f506572f7e4..72b36ef6e06 100644--- a/apps/ui-library/public/r/current-user-avatar-react.json+++ b/apps/ui-library/public/r/current-user-avatar-react.json@@ -28,8 +28,13 @@},{"path": "registry/default/clients/react/lib/supabase/client.ts",- "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",+ "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_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/current-user-avatar-tanstack.json b/apps/ui-library/public/r/current-user-avatar-tanstack.jsonindex 8038da79e5c..87709f96d8e 100644--- a/apps/ui-library/public/r/current-user-avatar-tanstack.json+++ b/apps/ui-library/public/r/current-user-avatar-tanstack.json@@ -29,13 +29,18 @@},{"path": "registry/default/clients/tanstack/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/tanstack/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { parseCookies, setCookie } from '@tanstack/react-start/server'\n\nexport function createClient() {\n return createServerClient(\n process.env.VITE_SUPABASE_URL!,\n process.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\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}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/dropzone-nextjs.json b/apps/ui-library/public/r/dropzone-nextjs.jsonindex fe37124b6dd..fc941070c3f 100644--- a/apps/ui-library/public/r/dropzone-nextjs.json+++ b/apps/ui-library/public/r/dropzone-nextjs.json@@ -26,18 +26,23 @@},{"path": "registry/default/clients/nextjs/lib/supabase/client.ts",- "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/middleware.ts",- "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: DO NOT REMOVE auth.getClaims()\n const { data } = await supabase.auth.getClaims()\n\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n // With Fluid compute, don't put this client in a global environment\n // variable. Always create a new one on each request.\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: If you remove getClaims() and you use server-side rendering\n // with the Supabase client, your users may be randomly logged out.\n const { data } = await supabase.auth.getClaims()\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { cookies } from 'next/headers'\n\n/**\n * If using Fluid compute: Don't put this client in a global variable. Always create a new client within each\n * function when using it.\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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/dropzone-react-router.json b/apps/ui-library/public/r/dropzone-react-router.jsonindex 5e2c55a0da7..5ae33b305e2 100644--- a/apps/ui-library/public/r/dropzone-react-router.json+++ b/apps/ui-library/public/r/dropzone-react-router.json@@ -26,13 +26,18 @@},{"path": "registry/default/clients/react-router/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/react-router/lib/supabase/server.ts",- "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",+ "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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/dropzone-react.json b/apps/ui-library/public/r/dropzone-react.jsonindex 96a316458f7..90c6882d4ae 100644--- a/apps/ui-library/public/r/dropzone-react.json+++ b/apps/ui-library/public/r/dropzone-react.json@@ -25,8 +25,13 @@},{"path": "registry/default/clients/react/lib/supabase/client.ts",- "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",+ "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_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/dropzone-tanstack.json b/apps/ui-library/public/r/dropzone-tanstack.jsonindex 077c9a4d964..42a97708f3a 100644--- a/apps/ui-library/public/r/dropzone-tanstack.json+++ b/apps/ui-library/public/r/dropzone-tanstack.json@@ -26,13 +26,18 @@},{"path": "registry/default/clients/tanstack/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/tanstack/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { parseCookies, setCookie } from '@tanstack/react-start/server'\n\nexport function createClient() {\n return createServerClient(\n process.env.VITE_SUPABASE_URL!,\n process.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\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}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/password-based-auth-nextjs.json b/apps/ui-library/public/r/password-based-auth-nextjs.jsonindex 918a6e9d4a6..f5c48585d09 100644--- a/apps/ui-library/public/r/password-based-auth-nextjs.json+++ b/apps/ui-library/public/r/password-based-auth-nextjs.json@@ -29,7 +29,7 @@},{"path": "registry/default/blocks/password-based-auth-nextjs/app/protected/page.tsx",- "content": "import { redirect } from 'next/navigation'\n\nimport { LogoutButton } from '@/registry/default/blocks/password-based-auth-nextjs/components/logout-button'\nimport { createClient } from '@/registry/default/clients/nextjs/lib/supabase/server'\n\nexport default async function ProtectedPage() {\n const supabase = await createClient()\n\n const { data, error } = await supabase.auth.getUser()\n if (error || !data?.user) {\n redirect('/auth/login')\n }\n\n return (\n <div className=\"flex h-svh w-full items-center justify-center gap-2\">\n <p>\n Hello <span>{data.user.email}</span>\n </p>\n <LogoutButton />\n </div>\n )\n}\n",+ "content": "import { redirect } from 'next/navigation'\n\nimport { LogoutButton } from '@/registry/default/blocks/password-based-auth-nextjs/components/logout-button'\nimport { createClient } from '@/registry/default/clients/nextjs/lib/supabase/server'\n\nexport default async function ProtectedPage() {\n const supabase = await createClient()\n\n const { data, error } = await supabase.auth.getClaims()\n if (error || !data?.claims) {\n redirect('/auth/login')\n }\n\n return (\n <div className=\"flex h-svh w-full items-center justify-center gap-2\">\n <p>\n Hello <span>{data.claims.email}</span>\n </p>\n <LogoutButton />\n </div>\n )\n}\n","type": "registry:page","target": "app/protected/page.tsx"},@@ -46,7 +46,7 @@},{"path": "registry/default/blocks/password-based-auth-nextjs/middleware.ts",- "content": "import { updateSession } from '@/registry/default/clients/nextjs/lib/supabase/middleware'\nimport { type NextRequest } from 'next/server'\n\nexport async function middleware(request: NextRequest) {\n return await updateSession(request)\n}\n\nexport const config = {\n matcher: [\n /*\n * Match all request paths except for the ones starting with:\n * - _next/static (static files)\n * - _next/image (image optimization files)\n * - favicon.ico (favicon file)\n * Feel free to modify this pattern to include more paths.\n */\n '/((?!_next/static|_next/image|favicon.ico|.*\\\\.(?:svg|png|jpg|jpeg|gif|webp)$).*)',\n ],\n}\n",+ "content": "import { updateSession } from '@/registry/default/clients/nextjs/lib/supabase/middleware'\nimport { type NextRequest } from 'next/server'\n\nexport async function middleware(request: NextRequest) {\n return await updateSession(request)\n}\n\nexport const config = {\n matcher: [\n /*\n * Match all request paths except:\n * - _next/static (static files)\n * - _next/image (image optimization files)\n * - favicon.ico (favicon file)\n * - images - .svg, .png, .jpg, .jpeg, .gif, .webp\n * Feel free to modify this pattern to include more paths.\n */\n '/((?!_next/static|_next/image|favicon.ico|.*\\\\.(?:svg|png|jpg|jpeg|gif|webp)$).*)',\n ],\n}\n","type": "registry:file","target": "middleware.ts"},@@ -96,18 +96,23 @@},{"path": "registry/default/clients/nextjs/lib/supabase/client.ts",- "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/middleware.ts",- "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: DO NOT REMOVE auth.getClaims()\n const { data } = await supabase.auth.getClaims()\n\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n // With Fluid compute, don't put this client in a global environment\n // variable. Always create a new one on each request.\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: If you remove getClaims() and you use server-side rendering\n // with the Supabase client, your users may be randomly logged out.\n const { data } = await supabase.auth.getClaims()\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { cookies } from 'next/headers'\n\n/**\n * If using Fluid compute: Don't put this client in a global variable. Always create a new client within each\n * function when using it.\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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/password-based-auth-react-router.json b/apps/ui-library/public/r/password-based-auth-react-router.jsonindex c79c349f388..5f24bcffc3e 100644--- a/apps/ui-library/public/r/password-based-auth-react-router.json+++ b/apps/ui-library/public/r/password-based-auth-react-router.json@@ -73,13 +73,18 @@},{"path": "registry/default/clients/react-router/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/react-router/lib/supabase/server.ts",- "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",+ "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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/password-based-auth-react.json b/apps/ui-library/public/r/password-based-auth-react.jsonindex 5158eef8207..a50604835e8 100644--- a/apps/ui-library/public/r/password-based-auth-react.json+++ b/apps/ui-library/public/r/password-based-auth-react.json@@ -36,8 +36,13 @@},{"path": "registry/default/clients/react/lib/supabase/client.ts",- "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",+ "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_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/password-based-auth-tanstack.json b/apps/ui-library/public/r/password-based-auth-tanstack.jsonindex 91223e367e7..0d84095b204 100644--- a/apps/ui-library/public/r/password-based-auth-tanstack.json+++ b/apps/ui-library/public/r/password-based-auth-tanstack.json@@ -96,13 +96,18 @@},{"path": "registry/default/clients/tanstack/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/tanstack/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { parseCookies, setCookie } from '@tanstack/react-start/server'\n\nexport function createClient() {\n return createServerClient(\n process.env.VITE_SUPABASE_URL!,\n process.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\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}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/realtime-avatar-stack-nextjs.json b/apps/ui-library/public/r/realtime-avatar-stack-nextjs.jsonindex bd218a3c416..d94f19ce758 100644--- a/apps/ui-library/public/r/realtime-avatar-stack-nextjs.json+++ b/apps/ui-library/public/r/realtime-avatar-stack-nextjs.json@@ -40,18 +40,23 @@},{"path": "registry/default/clients/nextjs/lib/supabase/client.ts",- "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/middleware.ts",- "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: DO NOT REMOVE auth.getClaims()\n const { data } = await supabase.auth.getClaims()\n\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n // With Fluid compute, don't put this client in a global environment\n // variable. Always create a new one on each request.\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: If you remove getClaims() and you use server-side rendering\n // with the Supabase client, your users may be randomly logged out.\n const { data } = await supabase.auth.getClaims()\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { cookies } from 'next/headers'\n\n/**\n * If using Fluid compute: Don't put this client in a global variable. Always create a new client within each\n * function when using it.\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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/realtime-avatar-stack-react-router.json b/apps/ui-library/public/r/realtime-avatar-stack-react-router.jsonindex aa104595204..7d6a86a2287 100644--- a/apps/ui-library/public/r/realtime-avatar-stack-react-router.json+++ b/apps/ui-library/public/r/realtime-avatar-stack-react-router.json@@ -40,13 +40,18 @@},{"path": "registry/default/clients/react-router/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/react-router/lib/supabase/server.ts",- "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",+ "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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/realtime-avatar-stack-react.json b/apps/ui-library/public/r/realtime-avatar-stack-react.jsonindex ad3a5e35cc0..f1226adc1f1 100644--- a/apps/ui-library/public/r/realtime-avatar-stack-react.json+++ b/apps/ui-library/public/r/realtime-avatar-stack-react.json@@ -39,8 +39,13 @@},{"path": "registry/default/clients/react/lib/supabase/client.ts",- "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",+ "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_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/realtime-avatar-stack-tanstack.json b/apps/ui-library/public/r/realtime-avatar-stack-tanstack.jsonindex 3b8d2fc7ecd..b3ae60f1bf9 100644--- a/apps/ui-library/public/r/realtime-avatar-stack-tanstack.json+++ b/apps/ui-library/public/r/realtime-avatar-stack-tanstack.json@@ -40,13 +40,18 @@},{"path": "registry/default/clients/tanstack/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/tanstack/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { parseCookies, setCookie } from '@tanstack/react-start/server'\n\nexport function createClient() {\n return createServerClient(\n process.env.VITE_SUPABASE_URL!,\n process.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\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}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/realtime-chat-nextjs.json b/apps/ui-library/public/r/realtime-chat-nextjs.jsonindex 0653a4ee3a9..1f2e020b5c8 100644--- a/apps/ui-library/public/r/realtime-chat-nextjs.json+++ b/apps/ui-library/public/r/realtime-chat-nextjs.json@@ -36,18 +36,23 @@},{"path": "registry/default/clients/nextjs/lib/supabase/client.ts",- "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/middleware.ts",- "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: DO NOT REMOVE auth.getClaims()\n const { data } = await supabase.auth.getClaims()\n\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n // With Fluid compute, don't put this client in a global environment\n // variable. Always create a new one on each request.\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: If you remove getClaims() and you use server-side rendering\n // with the Supabase client, your users may be randomly logged out.\n const { data } = await supabase.auth.getClaims()\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { cookies } from 'next/headers'\n\n/**\n * If using Fluid compute: Don't put this client in a global variable. Always create a new client within each\n * function when using it.\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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/realtime-chat-react-router.json b/apps/ui-library/public/r/realtime-chat-react-router.jsonindex 52d8ba92370..fd34e8cc7db 100644--- a/apps/ui-library/public/r/realtime-chat-react-router.json+++ b/apps/ui-library/public/r/realtime-chat-react-router.json@@ -36,13 +36,18 @@},{"path": "registry/default/clients/react-router/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/react-router/lib/supabase/server.ts",- "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",+ "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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/realtime-chat-react.json b/apps/ui-library/public/r/realtime-chat-react.jsonindex fea8451ae61..14651ea7dcf 100644--- a/apps/ui-library/public/r/realtime-chat-react.json+++ b/apps/ui-library/public/r/realtime-chat-react.json@@ -35,8 +35,13 @@},{"path": "registry/default/clients/react/lib/supabase/client.ts",- "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",+ "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_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/realtime-chat-tanstack.json b/apps/ui-library/public/r/realtime-chat-tanstack.jsonindex b784d6c4d71..5912fb76085 100644--- a/apps/ui-library/public/r/realtime-chat-tanstack.json+++ b/apps/ui-library/public/r/realtime-chat-tanstack.json@@ -36,13 +36,18 @@},{"path": "registry/default/clients/tanstack/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/tanstack/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { parseCookies, setCookie } from '@tanstack/react-start/server'\n\nexport function createClient() {\n return createServerClient(\n process.env.VITE_SUPABASE_URL!,\n process.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\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}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/realtime-cursor-nextjs.json b/apps/ui-library/public/r/realtime-cursor-nextjs.jsonindex 344a3bdc1c3..e2477cbeb94 100644--- a/apps/ui-library/public/r/realtime-cursor-nextjs.json+++ b/apps/ui-library/public/r/realtime-cursor-nextjs.json@@ -28,18 +28,23 @@},{"path": "registry/default/clients/nextjs/lib/supabase/client.ts",- "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/middleware.ts",- "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: DO NOT REMOVE auth.getClaims()\n const { data } = await supabase.auth.getClaims()\n\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n // With Fluid compute, don't put this client in a global environment\n // variable. Always create a new one on each request.\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: If you remove getClaims() and you use server-side rendering\n // with the Supabase client, your users may be randomly logged out.\n const { data } = await supabase.auth.getClaims()\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { cookies } from 'next/headers'\n\n/**\n * If using Fluid compute: Don't put this client in a global variable. Always create a new client within each\n * function when using it.\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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/realtime-cursor-react-router.json b/apps/ui-library/public/r/realtime-cursor-react-router.jsonindex 9f130b0fbee..cb7b916dced 100644--- a/apps/ui-library/public/r/realtime-cursor-react-router.json+++ b/apps/ui-library/public/r/realtime-cursor-react-router.json@@ -28,13 +28,18 @@},{"path": "registry/default/clients/react-router/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/react-router/lib/supabase/server.ts",- "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",+ "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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/realtime-cursor-react.json b/apps/ui-library/public/r/realtime-cursor-react.jsonindex 09fb557af73..0f338c78581 100644--- a/apps/ui-library/public/r/realtime-cursor-react.json+++ b/apps/ui-library/public/r/realtime-cursor-react.json@@ -27,8 +27,13 @@},{"path": "registry/default/clients/react/lib/supabase/client.ts",- "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",+ "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_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/realtime-cursor-tanstack.json b/apps/ui-library/public/r/realtime-cursor-tanstack.jsonindex 75bc242645b..cd72d8d7e1d 100644--- a/apps/ui-library/public/r/realtime-cursor-tanstack.json+++ b/apps/ui-library/public/r/realtime-cursor-tanstack.json@@ -28,13 +28,18 @@},{"path": "registry/default/clients/tanstack/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/tanstack/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { parseCookies, setCookie } from '@tanstack/react-start/server'\n\nexport function createClient() {\n return createServerClient(\n process.env.VITE_SUPABASE_URL!,\n process.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\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}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/social-auth-nextjs.json b/apps/ui-library/public/r/social-auth-nextjs.jsonindex bb44f71ea43..1720d82de5d 100644--- a/apps/ui-library/public/r/social-auth-nextjs.json+++ b/apps/ui-library/public/r/social-auth-nextjs.json@@ -55,18 +55,23 @@},{"path": "registry/default/clients/nextjs/lib/supabase/client.ts",- "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/middleware.ts",- "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: DO NOT REMOVE auth.getClaims()\n const { data } = await supabase.auth.getClaims()\n\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n // With Fluid compute, don't put this client in a global environment\n // variable. Always create a new one on each request.\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: If you remove getClaims() and you use server-side rendering\n // with the Supabase client, your users may be randomly logged out.\n const { data } = await supabase.auth.getClaims()\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { cookies } from 'next/headers'\n\n/**\n * If using Fluid compute: Don't put this client in a global variable. Always create a new client within each\n * function when using it.\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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/social-auth-react-router.json b/apps/ui-library/public/r/social-auth-react-router.jsonindex 38cbbc8bd39..23038bd9e1f 100644--- a/apps/ui-library/public/r/social-auth-react-router.json+++ b/apps/ui-library/public/r/social-auth-react-router.json@@ -53,13 +53,18 @@},{"path": "registry/default/clients/react-router/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/react-router/lib/supabase/server.ts",- "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",+ "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_PUBLISHABLE_OR_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"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/social-auth-react.json b/apps/ui-library/public/r/social-auth-react.jsonindex 8e9a18e5a09..890d6a6e308 100644--- a/apps/ui-library/public/r/social-auth-react.json+++ b/apps/ui-library/public/r/social-auth-react.json@@ -19,8 +19,13 @@},{"path": "registry/default/clients/react/lib/supabase/client.ts",- "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",+ "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_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/social-auth-tanstack.json b/apps/ui-library/public/r/social-auth-tanstack.jsonindex ccc42a24aae..b03c3d7251d 100644--- a/apps/ui-library/public/r/social-auth-tanstack.json+++ b/apps/ui-library/public/r/social-auth-tanstack.json@@ -55,13 +55,18 @@},{"path": "registry/default/clients/tanstack/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/tanstack/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { parseCookies, setCookie } from '@tanstack/react-start/server'\n\nexport function createClient() {\n return createServerClient(\n process.env.VITE_SUPABASE_URL!,\n process.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\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}\n","type": "registry:lib"}- ]+ ],+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/public/r/supabase-client-nextjs.json b/apps/ui-library/public/r/supabase-client-nextjs.jsonindex fab3bb20c72..79aecf0b75b 100644--- a/apps/ui-library/public/r/supabase-client-nextjs.json+++ b/apps/ui-library/public/r/supabase-client-nextjs.json@@ -12,19 +12,23 @@"files": [{"path": "registry/default/clients/nextjs/lib/supabase/client.ts",- "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "import { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/middleware.ts",- "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: DO NOT REMOVE auth.getClaims()\n const { data } = await supabase.auth.getClaims()\n\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { NextResponse, type NextRequest } from 'next/server'\n\nexport async function updateSession(request: NextRequest) {\n let supabaseResponse = NextResponse.next({\n request,\n })\n\n // With Fluid compute, don't put this client in a global environment\n // variable. Always create a new one on each request.\n const supabase = createServerClient(\n process.env.NEXT_PUBLIC_SUPABASE_URL!,\n process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\n cookies: {\n getAll() {\n return request.cookies.getAll()\n },\n setAll(cookiesToSet) {\n cookiesToSet.forEach(({ name, value }) => request.cookies.set(name, value))\n supabaseResponse = NextResponse.next({\n request,\n })\n cookiesToSet.forEach(({ name, value, options }) =>\n supabaseResponse.cookies.set(name, value, options)\n )\n },\n },\n }\n )\n\n // Do not run code between createServerClient and\n // supabase.auth.getClaims(). A simple mistake could make it very hard to debug\n // issues with users being randomly logged out.\n\n // IMPORTANT: If you remove getClaims() and you use server-side rendering\n // with the Supabase client, your users may be randomly logged out.\n const { data } = await supabase.auth.getClaims()\n const user = data?.claims\n\n if (\n !user &&\n !request.nextUrl.pathname.startsWith('/login') &&\n !request.nextUrl.pathname.startsWith('/auth')\n ) {\n // no user, potentially respond by redirecting the user to the login page\n const url = request.nextUrl.clone()\n url.pathname = '/auth/login'\n return NextResponse.redirect(url)\n }\n\n // IMPORTANT: You *must* return the supabaseResponse object as it is.\n // If you're creating a new response object with NextResponse.next() make sure to:\n // 1. Pass the request in it, like so:\n // const myNewResponse = NextResponse.next({ request })\n // 2. Copy over the cookies, like so:\n // myNewResponse.cookies.setAll(supabaseResponse.cookies.getAll())\n // 3. Change the myNewResponse object to fit your needs, but avoid changing\n // the cookies!\n // 4. Finally:\n // return myNewResponse\n // If this is not done, you may be causing the browser and server to go out\n // of sync and terminate the user's session prematurely!\n\n return supabaseResponse\n}\n","type": "registry:lib"},{"path": "registry/default/clients/nextjs/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { cookies } from 'next/headers'\n\n/**\n * If using Fluid compute: Don't put this client in a global variable. Always create a new client within each\n * function when using it.\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_PUBLISHABLE_OR_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`."+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_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 9819cc7e320..f8f716f37f6 100644--- a/apps/ui-library/public/r/supabase-client-react-router.json+++ b/apps/ui-library/public/r/supabase-client-react-router.json@@ -12,14 +12,18 @@"files": [{"path": "registry/default/clients/react-router/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/react-router/lib/supabase/server.ts",- "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",+ "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_PUBLISHABLE_OR_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`."+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_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 1878fd2215d..992f3105f73 100644--- a/apps/ui-library/public/r/supabase-client-react.json+++ b/apps/ui-library/public/r/supabase-client-react.json@@ -11,9 +11,13 @@"files": [{"path": "registry/default/clients/react/lib/supabase/client.ts",- "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",+ "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_PUBLISHABLE_OR_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`."+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_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 b89f1ee6957..f78f51a1fdb 100644--- a/apps/ui-library/public/r/supabase-client-tanstack.json+++ b/apps/ui-library/public/r/supabase-client-tanstack.json@@ -12,14 +12,18 @@"files": [{"path": "registry/default/clients/tanstack/lib/supabase/client.ts",- "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_ANON_KEY!\n )\n}\n",+ "content": "/// <reference types=\"vite/types/importMeta.d.ts\" />\nimport { createBrowserClient } from '@supabase/ssr'\n\nexport function createClient() {\n return createBrowserClient(\n import.meta.env.VITE_SUPABASE_URL!,\n import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!\n )\n}\n","type": "registry:lib"},{"path": "registry/default/clients/tanstack/lib/supabase/server.ts",- "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",+ "content": "import { createServerClient } from '@supabase/ssr'\nimport { parseCookies, setCookie } from '@tanstack/react-start/server'\n\nexport function createClient() {\n return createServerClient(\n process.env.VITE_SUPABASE_URL!,\n process.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,\n {\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}\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`."+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`."}\ No newline at end of filediff --git a/apps/ui-library/registry.json b/apps/ui-library/registry.jsonindex a7458fc4414..cd103eebb1b 100644--- a/apps/ui-library/registry.json+++ b/apps/ui-library/registry.json@@ -88,7 +88,12 @@"path": "registry/default/clients/nextjs/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"name": "password-based-auth-react",@@ -118,7 +123,12 @@"type": "registry:lib"}],- "dependencies": ["@supabase/supabase-js@latest"]+ "dependencies": ["@supabase/supabase-js@latest"],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"name": "password-based-auth-react-router",@@ -186,7 +196,12 @@"path": "registry/default/clients/react-router/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"name": "password-based-auth-tanstack",@@ -269,7 +284,12 @@"path": "registry/default/clients/tanstack/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"name": "social-auth-nextjs",@@ -324,7 +344,12 @@"path": "registry/default/clients/nextjs/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"name": "social-auth-react",@@ -342,7 +367,12 @@"type": "registry:lib"}],- "dependencies": ["@supabase/supabase-js@latest"]+ "dependencies": ["@supabase/supabase-js@latest"],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"name": "social-auth-react-router",@@ -395,7 +425,12 @@"path": "registry/default/clients/react-router/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"name": "social-auth-tanstack",@@ -446,7 +481,12 @@"path": "registry/default/clients/tanstack/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -482,7 +522,12 @@"path": "registry/default/clients/nextjs/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -505,7 +550,12 @@"path": "registry/default/clients/react/lib/supabase/client.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -537,7 +587,12 @@"path": "registry/default/clients/react-router/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -569,7 +624,12 @@"path": "registry/default/clients/tanstack/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -604,7 +664,12 @@"path": "registry/default/clients/nextjs/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -631,7 +696,12 @@"path": "registry/default/clients/react/lib/supabase/client.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -662,7 +732,12 @@"path": "registry/default/clients/react-router/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -693,7 +768,12 @@"path": "registry/default/clients/tanstack/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -728,7 +808,12 @@"path": "registry/default/clients/nextjs/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -755,7 +840,12 @@"path": "registry/default/clients/react/lib/supabase/client.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -786,7 +876,12 @@"path": "registry/default/clients/react-router/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -817,7 +912,12 @@"path": "registry/default/clients/tanstack/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -860,7 +960,12 @@"path": "registry/default/clients/nextjs/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -895,7 +1000,12 @@"path": "registry/default/clients/react/lib/supabase/client.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -934,7 +1044,12 @@"path": "registry/default/clients/react-router/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -973,7 +1088,12 @@"path": "registry/default/clients/tanstack/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -1012,7 +1132,12 @@"path": "registry/default/clients/nextjs/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -1043,7 +1168,12 @@"path": "registry/default/clients/react/lib/supabase/client.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -1078,7 +1208,12 @@"path": "registry/default/clients/react-router/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -1113,7 +1248,12 @@"path": "registry/default/clients/tanstack/lib/supabase/server.ts","type": "registry:lib"}- ]+ ],+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ }},{"$schema": "https://ui.shadcn.com/schema/registry-item.json",@@ -1138,7 +1278,11 @@"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: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_ANON_KEY`.",+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },"files": [{"path": "registry/default/clients/nextjs/lib/supabase/client.ts",@@ -1162,7 +1306,11 @@"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`.",+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },"files": [{"path": "registry/default/clients/react/lib/supabase/client.ts",@@ -1178,7 +1326,11 @@"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`.",+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },"files": [{"path": "registry/default/clients/react-router/lib/supabase/client.ts",@@ -1198,7 +1350,11 @@"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`.",+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },"files": [{"path": "registry/default/clients/tanstack/lib/supabase/client.ts",diff --git a/apps/ui-library/registry/default/ai-editor-rules/writing-supabase-edge-functions.mdc b/apps/ui-library/registry/default/ai-editor-rules/writing-supabase-edge-functions.mdcindex eb08df027c7..da32e700013 100644--- a/apps/ui-library/registry/default/ai-editor-rules/writing-supabase-edge-functions.mdc+++ b/apps/ui-library/registry/default/ai-editor-rules/writing-supabase-edge-functions.mdc@@ -18,7 +18,7 @@ You're an expert in writing TypeScript and Deno JavaScript runtime. Generate **h7. Do NOT use `import { serve } from "https://deno.land/[email protected]/http/server.ts"`. Instead use the built-in `Deno.serve`.8. Following environment variables (ie. secrets) are pre-populated in both local and hosted Supabase environments. Users don't need to manually set them:- SUPABASE_URL- - SUPABASE_ANON_KEY+ - SUPABASE_PUBLISHABLE_OR_ANON_KEY- SUPABASE_SERVICE_ROLE_KEY- SUPABASE_DB_URL9. To set other environment variables (ie. secrets) users can put them in a env file and run the `supabase secrets set --env-file path/to/env-file`diff --git a/apps/ui-library/registry/default/blocks/password-based-auth-nextjs/app/protected/page.tsx b/apps/ui-library/registry/default/blocks/password-based-auth-nextjs/app/protected/page.tsxindex 33bb0ecc8e6..f84213f2771 100644--- a/apps/ui-library/registry/default/blocks/password-based-auth-nextjs/app/protected/page.tsx+++ b/apps/ui-library/registry/default/blocks/password-based-auth-nextjs/app/protected/page.tsx@@ -6,15 +6,15 @@ import { createClient } from '@/registry/default/clients/nextjs/lib/supabase/serexport default async function ProtectedPage() {const supabase = await createClient()- const { data, error } = await supabase.auth.getUser()- if (error || !data?.user) {+ const { data, error } = await supabase.auth.getClaims()+ if (error || !data?.claims) {redirect('/auth/login')}return (<div className="flex h-svh w-full items-center justify-center gap-2"><p>- Hello <span>{data.user.email}</span>+ Hello <span>{data.claims.email}</span></p><LogoutButton /></div>diff --git a/apps/ui-library/registry/default/blocks/password-based-auth-nextjs/middleware.ts b/apps/ui-library/registry/default/blocks/password-based-auth-nextjs/middleware.tsindex c04d54bc883..71fac6460bd 100644--- a/apps/ui-library/registry/default/blocks/password-based-auth-nextjs/middleware.ts+++ b/apps/ui-library/registry/default/blocks/password-based-auth-nextjs/middleware.ts@@ -8,10 +8,11 @@ export async function middleware(request: NextRequest) {export const config = {matcher: [/*- * Match all request paths except for the ones starting with:+ * Match all request paths except:* - _next/static (static files)* - _next/image (image optimization files)* - favicon.ico (favicon file)+ * - images - .svg, .png, .jpg, .jpeg, .gif, .webp* Feel free to modify this pattern to include more paths.*/'/((?!_next/static|_next/image|favicon.ico|.*\\.(?:svg|png|jpg|jpeg|gif|webp)$).*)',diff --git a/apps/ui-library/registry/default/clients/nextjs/lib/supabase/client.ts b/apps/ui-library/registry/default/clients/nextjs/lib/supabase/client.tsindex 792b4570b2c..ccc8cf2e900 100644--- a/apps/ui-library/registry/default/clients/nextjs/lib/supabase/client.ts+++ b/apps/ui-library/registry/default/clients/nextjs/lib/supabase/client.ts@@ -3,6 +3,6 @@ import { createBrowserClient } from '@supabase/ssr'export function createClient() {return createBrowserClient(process.env.NEXT_PUBLIC_SUPABASE_URL!,- process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!+ process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!)}diff --git a/apps/ui-library/registry/default/clients/nextjs/lib/supabase/middleware.ts b/apps/ui-library/registry/default/clients/nextjs/lib/supabase/middleware.tsindex 1a9abb5f0a9..7a07f440f7c 100644--- a/apps/ui-library/registry/default/clients/nextjs/lib/supabase/middleware.ts+++ b/apps/ui-library/registry/default/clients/nextjs/lib/supabase/middleware.ts@@ -6,9 +6,11 @@ export async function updateSession(request: NextRequest) {request,})+ // With Fluid compute, don't put this client in a global environment+ // variable. Always create a new one on each request.const supabase = createServerClient(process.env.NEXT_PUBLIC_SUPABASE_URL!,- process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,+ process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,{cookies: {getAll() {@@ -31,9 +33,9 @@ export async function updateSession(request: NextRequest) {// supabase.auth.getClaims(). A simple mistake could make it very hard to debug// issues with users being randomly logged out.- // IMPORTANT: DO NOT REMOVE auth.getClaims()+ // IMPORTANT: If you remove getClaims() and you use server-side rendering+ // with the Supabase client, your users may be randomly logged out.const { data } = await supabase.auth.getClaims()-const user = data?.claimsif (diff --git a/apps/ui-library/registry/default/clients/nextjs/lib/supabase/server.ts b/apps/ui-library/registry/default/clients/nextjs/lib/supabase/server.tsindex 40633b0c5b8..3d42f5f99e2 100644--- a/apps/ui-library/registry/default/clients/nextjs/lib/supabase/server.ts+++ b/apps/ui-library/registry/default/clients/nextjs/lib/supabase/server.ts@@ -1,12 +1,16 @@import { createServerClient } from '@supabase/ssr'import { cookies } from 'next/headers'+/**+ * If using Fluid compute: Don't put this client in a global variable. Always create a new client within each+ * function when using it.+ */export async function createClient() {const cookieStore = await cookies()return createServerClient(process.env.NEXT_PUBLIC_SUPABASE_URL!,- process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,+ process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,{cookies: {getAll() {diff --git a/apps/ui-library/registry/default/clients/nextjs/registry-item.json b/apps/ui-library/registry/default/clients/nextjs/registry-item.jsonindex cd630de3f86..95d2fe595d4 100644--- a/apps/ui-library/registry/default/clients/nextjs/registry-item.json+++ b/apps/ui-library/registry/default/clients/nextjs/registry-item.json@@ -6,7 +6,11 @@"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: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_ANON_KEY`.",+ "docs": "You'll need to set the following environment variables in your project: `NEXT_PUBLIC_SUPABASE_URL` and `NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "NEXT_PUBLIC_SUPABASE_URL": "",+ "NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },"files": [{"path": "registry/default/clients/nextjs/lib/supabase/client.ts",diff --git a/apps/ui-library/registry/default/clients/react-router/lib/supabase/client.ts b/apps/ui-library/registry/default/clients/react-router/lib/supabase/client.tsindex 3c171dbcaca..2377b970a8b 100644--- a/apps/ui-library/registry/default/clients/react-router/lib/supabase/client.ts+++ b/apps/ui-library/registry/default/clients/react-router/lib/supabase/client.ts@@ -4,6 +4,6 @@ import { createBrowserClient } from '@supabase/ssr'export function createClient() {return createBrowserClient(import.meta.env.VITE_SUPABASE_URL!,- import.meta.env.VITE_SUPABASE_ANON_KEY!+ import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!)}diff --git a/apps/ui-library/registry/default/clients/react-router/lib/supabase/server.ts b/apps/ui-library/registry/default/clients/react-router/lib/supabase/server.tsindex daa676045bc..28985885f37 100644--- a/apps/ui-library/registry/default/clients/react-router/lib/supabase/server.ts+++ b/apps/ui-library/registry/default/clients/react-router/lib/supabase/server.ts@@ -5,7 +5,7 @@ export function createClient(request: Request) {const supabase = createServerClient(process.env.VITE_SUPABASE_URL!,- process.env.VITE_SUPABASE_ANON_KEY!,+ process.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,{cookies: {getAll() {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 ef46880ac1f..fdb7f8f60b9 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,7 +6,11 @@"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`.",+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },"files": [{"path": "registry/default/clients/react-router/lib/supabase/client.ts",diff --git a/apps/ui-library/registry/default/clients/react/lib/supabase/client.ts b/apps/ui-library/registry/default/clients/react/lib/supabase/client.tsindex c9001f54099..c4ea49d065b 100644--- a/apps/ui-library/registry/default/clients/react/lib/supabase/client.ts+++ b/apps/ui-library/registry/default/clients/react/lib/supabase/client.ts@@ -3,6 +3,6 @@ import { createClient as createSupabaseClient } from '@supabase/supabase-js'export function createClient() {return createSupabaseClient(import.meta.env.VITE_SUPABASE_URL!,- import.meta.env.VITE_SUPABASE_ANON_KEY!+ import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!)}diff --git a/apps/ui-library/registry/default/clients/react/registry-item.json b/apps/ui-library/registry/default/clients/react/registry-item.jsonindex b8e429862d2..0e85cea12bf 100644--- a/apps/ui-library/registry/default/clients/react/registry-item.json+++ b/apps/ui-library/registry/default/clients/react/registry-item.json@@ -6,7 +6,11 @@"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`.",+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },"files": [{"path": "registry/default/clients/react/lib/supabase/client.ts",diff --git a/apps/ui-library/registry/default/clients/tanstack/lib/supabase/client.ts b/apps/ui-library/registry/default/clients/tanstack/lib/supabase/client.tsindex 3c171dbcaca..2377b970a8b 100644--- a/apps/ui-library/registry/default/clients/tanstack/lib/supabase/client.ts+++ b/apps/ui-library/registry/default/clients/tanstack/lib/supabase/client.ts@@ -4,6 +4,6 @@ import { createBrowserClient } from '@supabase/ssr'export function createClient() {return createBrowserClient(import.meta.env.VITE_SUPABASE_URL!,- import.meta.env.VITE_SUPABASE_ANON_KEY!+ import.meta.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!)}diff --git a/apps/ui-library/registry/default/clients/tanstack/lib/supabase/server.ts b/apps/ui-library/registry/default/clients/tanstack/lib/supabase/server.tsindex 33f11832d5d..3409f227cb2 100644--- a/apps/ui-library/registry/default/clients/tanstack/lib/supabase/server.ts+++ b/apps/ui-library/registry/default/clients/tanstack/lib/supabase/server.ts@@ -2,22 +2,26 @@ import { createServerClient } from '@supabase/ssr'import { parseCookies, setCookie } from '@tanstack/react-start/server'export function createClient() {- return createServerClient(process.env.VITE_SUPABASE_URL!, process.env.VITE_SUPABASE_ANON_KEY!, {- cookies: {- getAll() {- return Object.entries(parseCookies()).map(- ([name, value]) =>- ({- name,- value,- }) as { name: string; value: string }- )+ return createServerClient(+ process.env.VITE_SUPABASE_URL!,+ process.env.VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY!,+ {+ cookies: {+ getAll() {+ return Object.entries(parseCookies()).map(+ ([name, value]) =>+ ({+ name,+ value,+ }) as { name: string; value: string }+ )+ },+ setAll(cookies) {+ cookies.forEach((cookie) => {+ setCookie(cookie.name, cookie.value)+ })+ },},- setAll(cookies) {- cookies.forEach((cookie) => {- setCookie(cookie.name, cookie.value)- })- },- },- })+ }+ )}diff --git a/apps/ui-library/registry/default/clients/tanstack/registry-item.json b/apps/ui-library/registry/default/clients/tanstack/registry-item.jsonindex 6effeca667f..c2b4cd25725 100644--- a/apps/ui-library/registry/default/clients/tanstack/registry-item.json+++ b/apps/ui-library/registry/default/clients/tanstack/registry-item.json@@ -6,7 +6,11 @@"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`.",+ "docs": "You'll need to set the following environment variables in your project: `VITE_SUPABASE_URL` and `VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY`.",+ "envVars": {+ "VITE_SUPABASE_URL": "",+ "VITE_SUPABASE_PUBLISHABLE_OR_ANON_KEY": ""+ },"files": [{"path": "registry/default/clients/tanstack/lib/supabase/client.ts",diff --git a/apps/ui-library/registry/default/fixtures/lib/supabase/client.ts b/apps/ui-library/registry/default/fixtures/lib/supabase/client.tsindex 2600d32f54f..8a07ca81a1d 100644--- a/apps/ui-library/registry/default/fixtures/lib/supabase/client.ts+++ b/apps/ui-library/registry/default/fixtures/lib/supabase/client.ts@@ -4,6 +4,6 @@ import { Database } from '../../database.types'export function createClient() {return createBrowserClient<Database>(process.env.NEXT_PUBLIC_SUPABASE_URL!,- process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!+ process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_OR_ANON_KEY!)}diff --git a/apps/ui-library/registry/utils.ts b/apps/ui-library/registry/utils.tsindex b4c0f8d6599..c5a7c171c22 100644--- a/apps/ui-library/registry/utils.ts+++ b/apps/ui-library/registry/utils.ts@@ -15,6 +15,12 @@ const registryItemAppend = (item: Registry['items'][number], items: Registry['itregistryDependencies: uniq(neededRegDependencies),dependencies: uniq(neededDependencies),files: uniqBy(neededFiles, (file) => file?.path),+ docs: (item.docs, items.flatMap((i) => i.docs)).filter(Boolean).join('\n\n'),+ // merge all environment variables+ envVars: {+ ...item.envVars,+ ...items.reduce((acc, i) => ({ ...acc, ...i.envVars }), {}),+ },}return registryBlockdiff --git a/pnpm-lock.yaml b/pnpm-lock.yamlindex 20afe3bccee..0f53cdb760d 100644--- a/pnpm-lock.yaml+++ b/pnpm-lock.yaml@@ -332,7 +332,7 @@ importers:version: 1.0.3(@types/[email protected])(@types/[email protected])([email protected]([email protected]))([email protected])'@sentry/nextjs':specifier: ^9.15.0- version: 9.15.0(@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected])([email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))([email protected])([email protected](@babel/[email protected]([email protected]))(@opentelemetry/[email protected])(@playwright/[email protected])([email protected]([email protected]))([email protected])([email protected]))([email protected])([email protected])([email protected])+ version: 9.15.0(@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected])([email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))([email protected])([email protected](@opentelemetry/[email protected])(@playwright/[email protected])([email protected]([email protected]))([email protected])([email protected]))([email protected])([email protected])([email protected])'@supabase/supabase-js':specifier: 'catalog:'version: 2.49.3@@ -452,7 +452,7 @@ importers:nuqs:specifier: ^1.19.1- version: 1.19.1([email protected](@babel/[email protected]([email protected]))(@opentelemetry/[email protected])(@playwright/[email protected])([email protected]([email protected]))([email protected])([email protected]))+ version: 1.19.1([email protected](@opentelemetry/[email protected])(@playwright/[email protected])([email protected]([email protected]))([email protected])([email protected]))openai:specifier: ^4.20.1version: 4.71.1([email protected])([email protected])@@ -534,7 +534,7 @@ importers:devDependencies:'@graphiql/toolkit':specifier: ^0.9.1- version: 0.9.1(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])+ version: 0.9.1(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])'@graphql-codegen/cli':specifier: 5.0.5version: 5.0.5(@parcel/[email protected])(@types/[email protected])([email protected])([email protected]([email protected]))([email protected])([email protected])([email protected])@@ -606,7 +606,7 @@ importers:version: 13.2.2graphiql:specifier: ^4.0.2- version: 4.0.2(@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])+ version: 4.0.2(@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])openapi-types:specifier: ^12.1.3version: 12.1.3@@ -1438,8 +1438,8 @@ importers:specifier: ^4.1.3version: 4.4.1shadcn:- specifier: 2.4.0-canary.16+ specifier: ^2.10.0shiki:specifier: ^1.1.7version: 1.6.0@@ -16388,8 +16388,8 @@ packages:resolution: {integrity: sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==}- resolution: {integrity: sha512-HajpBYMB5P1iFoHrQ+bbfjuBtHfeQ0IVQWJIOsM4NgqymhMT0BpvOkncMf6Y0ttFc/CvhoZle5OJYkgA2oNzdA==}+ resolution: {integrity: sha512-/zxjmHGbaYVFtI6bUridFVV7VFStIv3vU/w1h7xenhz7KRzc9pqHsyFvcExZprG7dlA5kW9knRgv8+Cl/H7w9w==}hasBin: true@@ -20841,9 +20841,9 @@ snapshots:'@gar/[email protected]': {}- '@graphiql/[email protected](@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])':+ '@graphiql/[email protected](@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])':dependencies:- '@graphiql/react': 0.32.0(@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])+ '@graphiql/react': 0.32.0(@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])graphql: 16.11.0react: 18.3.1@@ -20857,10 +20857,10 @@ snapshots:- '@types/react-dom'- graphql-ws- '@graphiql/[email protected](@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])':+ '@graphiql/[email protected](@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])':dependencies:- '@graphiql/react': 0.32.0(@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])- '@graphiql/toolkit': 0.11.2(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])+ '@graphiql/react': 0.32.0(@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])+ '@graphiql/toolkit': 0.11.2(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])react: 18.3.1react-compiler-runtime: 19.1.0-rc.1([email protected])react-dom: 18.3.1([email protected])@@ -20900,9 +20900,9 @@ snapshots:- '@types/react-dom'- graphql-ws- '@graphiql/[email protected](@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])':+ '@graphiql/[email protected](@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])':dependencies:- '@graphiql/toolkit': 0.11.2(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])+ '@graphiql/toolkit': 0.11.2(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])'@radix-ui/react-dialog': 1.1.11(@types/[email protected])(@types/[email protected])([email protected]([email protected]))([email protected])'@radix-ui/react-dropdown-menu': 2.1.12(@types/[email protected])(@types/[email protected])([email protected]([email protected]))([email protected])'@radix-ui/react-tooltip': 1.2.4(@types/[email protected])(@types/[email protected])([email protected]([email protected]))([email protected])@@ -20929,13 +20929,13 @@ snapshots:- '@types/react-dom'- graphql-ws- '@graphiql/[email protected](@types/[email protected])([email protected]([email protected])([email protected]))([email protected])':+ '@graphiql/[email protected](@types/[email protected])([email protected]([email protected])([email protected]))([email protected])':dependencies:'@n1ru4l/push-pull-async-iterable-iterator': 3.2.0graphql: 16.11.0meros: 1.3.0(@types/[email protected])optionalDependencies:- graphql-ws: 6.0.4([email protected])([email protected])+ graphql-ws: 6.0.4([email protected])([email protected])transitivePeerDependencies:- '@types/node'@@ -20949,13 +20949,13 @@ snapshots:transitivePeerDependencies:- '@types/node'- '@graphiql/[email protected](@types/[email protected])([email protected]([email protected])([email protected]))([email protected])':+ '@graphiql/[email protected](@types/[email protected])([email protected]([email protected])([email protected]))([email protected])':dependencies:'@n1ru4l/push-pull-async-iterable-iterator': 3.2.0graphql: 16.11.0meros: 1.3.0(@types/[email protected])optionalDependencies:- graphql-ws: 6.0.4([email protected])([email protected])+ graphql-ws: 6.0.4([email protected])([email protected])transitivePeerDependencies:- '@types/node'@@ -25661,7 +25661,7 @@ snapshots:- supports-color- webpack- '@sentry/[email protected](@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected])([email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))([email protected])([email protected](@babel/[email protected]([email protected]))(@opentelemetry/[email protected])(@playwright/[email protected])([email protected]([email protected]))([email protected])([email protected]))([email protected])([email protected])([email protected])':+ '@sentry/[email protected](@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected])([email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))([email protected])([email protected](@opentelemetry/[email protected])(@playwright/[email protected])([email protected]([email protected]))([email protected])([email protected]))([email protected])([email protected])([email protected])':dependencies:'@opentelemetry/api': 1.9.0'@opentelemetry/semantic-conventions': 1.32.0@@ -31516,11 +31516,11 @@ snapshots:- [email protected](@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected]):+ [email protected](@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected]):dependencies:- '@graphiql/plugin-doc-explorer': 0.0.1(@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])- '@graphiql/plugin-history': 0.0.2(@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])- '@graphiql/react': 0.32.0(@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])+ '@graphiql/plugin-doc-explorer': 0.0.1(@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])+ '@graphiql/plugin-history': 0.0.2(@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])+ '@graphiql/react': 0.32.0(@codemirror/[email protected])(@emotion/[email protected])(@types/[email protected])(@types/[email protected])(@types/[email protected])([email protected]([email protected])([email protected]))([email protected])([email protected]([email protected]))([email protected])graphql: 16.11.0react: 18.3.1react-compiler-runtime: 19.1.0-rc.1([email protected])@@ -31607,13 +31607,6 @@ snapshots:dependencies:graphql: 16.11.0- dependencies:- graphql: 16.11.0- optionalDependencies:- ws: 8.18.1- optional: true-dependencies:graphql: 16.11.0@@ -32065,7 +32058,7 @@ snapshots:dependencies:- agent-base: 7.1.1([email protected])+ agent-base: 7.1.3debug: 4.4.0([email protected])transitivePeerDependencies:- supports-color@@ -34922,7 +34915,7 @@ snapshots:- [email protected]([email protected](@babel/[email protected]([email protected]))(@opentelemetry/[email protected])(@playwright/[email protected])([email protected]([email protected]))([email protected])([email protected])):+ [email protected]([email protected](@opentelemetry/[email protected])(@playwright/[email protected])([email protected]([email protected]))([email protected])([email protected])):dependencies:mitt: 3.0.1next: 15.3.3(@babel/[email protected]([email protected]))(@opentelemetry/[email protected])(@playwright/[email protected])([email protected])([email protected]([email protected]))([email protected])([email protected])@@ -37257,18 +37250,19 @@ snapshots:dependencies:'@antfu/ni': 23.3.1'@babel/core': 7.26.10([email protected])- '@babel/parser': 7.26.10+ '@babel/parser': 7.27.0'@babel/plugin-transform-typescript': 7.27.0(@babel/[email protected]([email protected]))([email protected])+ '@modelcontextprotocol/sdk': 1.12.1([email protected])commander: 10.0.1cosmiconfig: 8.3.6([email protected])deepmerge: 4.3.1- diff: 5.1.0+ diff: 5.2.0execa: 7.2.0- fast-glob: 3.3.2+ fast-glob: 3.3.3fs-extra: 11.3.0https-proxy-agent: 6.2.1([email protected])kleur: 4.1.5@@ -37282,6 +37276,7 @@ snapshots:ts-morph: 18.0.0tsconfig-paths: 4.2.0zod: 3.23.8+ zod-to-json-schema: 3.24.5([email protected])transitivePeerDependencies:- '@types/node'- supports-color