mirror of
https://github.com/supabase/supabase.git
synced 2026-12-04 15:39:13 +00:00
create-pull-request/patch
22196
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
a27ef81d2e |
feat(studio): enable advanced V3 deployment for allowlisted organizations (#53158)
## Problem Currently, in production, the Supabase UI doesn't allow for a set of advanced deployment options, that we need to properly test new clusters before getting those into production. ## Solution Allow production dashboard requests to specify an AWS_K8S cluster when the organization is included in the comma-separated `orgsAllowedToUseV3AdvancedDeployment` setting. Limited the exception to cluster placement fields. Preserve existing permissions and cluster validation, require force for cordoned clusters, and keep system requests supported. Default the allowlist to empty. Updated the API descriptions and document ConfigCat setup. ## Review instructions - ## Checklist Check all before review: - [X] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [X] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
431a55435a |
fix(studio): keep the function overview range in logs FE-4973 (#53867)
## Problem An Edge Function’s Overview can show an invocation from two hours ago. Selecting **Open logs** or pressing **O** then **L** opens the function’s Logs page with its default one-hour window, which hides that invocation. ## Fix Both actions now pass the start and end of the selected Overview window to the function’s Logs page. ## How to test 1. Open an Edge Function with invocations in the last three hours and select the three-hour interval on Overview. 2. Select **Open logs**. Check that Logs opens for the same function and the date range spans exactly three hours. If an invocation is older than one hour, confirm it appears in that range. 3. Return to Overview, select three hours again, and press **O** then **L**. Check the same function and time range. Related to [FE-4973](https://linear.app/supabase/issue/FE-4973). ## Verification On the Studio staging preview, both **Open logs** and **O** then **L** opened the same function with the exact Overview timestamps, 13:03:16.960 through 16:03:16.960 UTC. The results included a successful invocation more than one hour before the window ended. All 72 focused Overview and Logs navigation tests passed. Removing the date range from either entry point independently failed its regression assertion. |
||
|
|
b6c391a058 |
[FE-5114] (part 1) – refactor(studio): add native API helpers & routes (#54028)
## Problem Studio's `routes/api/**` server routes still run legacy Next Pages Router handlers through the `toWebHandler` shim in `compat/next/api.ts`. Part 1 of 7 for [FE-5114](https://linear.app/supabase/issue/FE-5114/rewrite-api-routes-as-native-tanstack-start-handlers-and-remove-the) adds native TanStack Start (`Request` → `Response`) helpers and migrates the top-level utility routes so we can remove the adapter at the end of the stack. ## Solution **Added:** - `createApiHandlers` in `lib/api/apiWrapper.ts`: wraps native TanStack Start route handlers with optional platform JWT auth, JSON `400` (`{ error: { message: 'Invalid JSON' } }`) on `InvalidJsonError`, Sentry capture + generic `500` on unexpected throws, and an `ANY` handler that returns `405` with an `Allow` header derived from the registered methods. Exports `ApiHandler` / `ApiHandlerContext` (`params` is `Record<string, string>`) - `authenticateRequest` in `lib/api/apiAuthenticate.ts` (Web `Request` counterpart of `apiAuthenticate`, same error messages) - `InvalidJsonError` and `parseJsonBody` in `lib/api/apiHelpers.ts` - `callRoute(route, request, params)` test helper in `tests/lib/server-route.ts` - Unit tests for `createApiHandlers` (exercising real `authenticateRequest` through MSW in `lib/api/createApiHandlers.test.ts`), `authenticateRequest`, `parseJsonBody`, `/api/generate-attachment-url`, and `/api/integrations/stripe-sync` **Changed:** - Updated `getRouteHandler` in `tests/lib/server-route.ts` to mirror TanStack Start's `HEAD` → `GET` → `ANY` dispatch order - Migrated 11 top-level API routes (`check-cname`, `cli-release-version`, `content/graphql`, `edge-functions/test`, `enabled-features-overrides`, `generate-attachment-url`, `get-deployment-commit`, `get-ip-address`, `get-s3-keys`, `get-utc-time`, `integrations/stripe-sync`) to native handlers - Added `withAuth: true` to `check-cname`, `content/graphql`, and `integrations/stripe-sync`, and updated `check-cname-mutation.ts` and `data/graphql/execute.ts` to attach `constructHeaders()` - Reused `withAuth` `claims` in `generate-attachment-url` to avoid a duplicate GoTrue lookup in platform mode - Converted `tests/routes/api/get-deployment-commit.test.ts` to `callRoute` **Removed:** - Removed 2 unused routes (`routes/api/connect/index.ts` and `routes/api/parse-query.ts`), dropped `/parse-query` from `lib/hosted-api-allowlist.ts`, removed Nitro's `traceDeps: ['libpg-query*']` in `vite.config.ts` (no server runtime route imports `libpg-query` anymore), and regenerated `routeTree.gen.ts` **Behavior changes vs master:** - Methods a route doesn't register now get a JSON `405` with an `Allow` header (previously they fell through to the SSR app). `HEAD` requests that TanStack Start dispatches to a `GET` handler also get `405`, matching master's method switches - `InvalidJsonError` returns JSON `{ error: { message: 'Invalid JSON' } }` (`400`) instead of plain text - `check-cname`, `content/graphql`, and `integrations/stripe-sync` now verify the platform JWT via `withAuth: true` - Unexpected throws return a generic `500` with `{ error: { message: 'Internal Server Error' } }` - Unused `/api/connect` and `/api/parse-query` routes have been removed ## Review instructions 1. Run `pnpm --filter studio exec vitest run lib/api/apiAuthenticate.test.ts lib/api/apiHelpers.test.ts lib/api/apiWrappers.test.ts lib/api/createApiHandlers.test.ts tests/routes/api/ scripts/__tests__/server-source-maps.test.ts`. 2. Smoke-test `/api/get-deployment-commit`, `/api/check-cname`, `/api/content/graphql`, `/api/generate-attachment-url`, and `/api/edge-functions/test` in Studio and confirm unsupported HTTP methods return `405` with an `Allow` header. ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
cebd7a5eba |
docs(ref): add Kotlin v4 alpha reference (#54384)
## This PR - Adds a v4 alpha reference for Kotlin at `/reference/kotlin/v4`, using the prerelease flag from #53896. - v3 stays the default at `/reference/kotlin`. v4 shows the alpha notice and is listed under "Prereleases" in the version menu. - `spec/supabase_kt_v4.yml` is the v3 spec with links updated to `supabase/supabase-kt`. The API is the same in v4. - New `introduction`, `installing` (with `io.supabase` coordinates) and `upgrade-guide` pages under `docs/ref/kotlin/v4/`. ## Why - supabase-kt `4.0.0-alpha-1` is on Maven Central. It's the first official release of the Kotlin SDK and moves it to the `io.supabase` Maven group and package. The current reference only shows the v3 coordinates. ## Note - Guides, quickstarts and the existing v3 pages are unchanged. They switch to `io.supabase` with the stable 4.0.0 release. - Search doesn't index prerelease versions yet, same as Swift v3. - I didn't run the docs build locally. Please check `/docs/reference/kotlin/v4` and `/docs/reference/kotlin/v4/upgrade-guide` on the preview. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Safa <4990386+safaorhan@users.noreply.github.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
e58fa85e6c |
docs: correct py and kt deleteFactor claim that it signs the user out (#54361)
The Python and Kotlin `deleteFactor` reference notes said deleting a verified factor logs the user out of all active sessions, but the server only downgrades sessions that reached `aal2` with that factor to `aal1`. This updates the notes to describe what actually happens, matching the JS reference fix in supabase/supabase-js#2939. |
||
|
|
37d4f444b4 |
chore: update prod api types (#54394)
Updated API types and addressed any type issues. Had to update shared-types alongside. |
||
|
|
31f68587f6 |
feat(studio): track remaining usage on project home (#54143)
## Problem Project home tracked most interactions, but not which credential people copy from the "Copy" popover, or how often they use the custom report and notebooks beyond adding blocks. Opening the Connect sheet from the popover's "Get Connected" button also reported a stale `connect_sheet_opened` source, because the popover never set one. ## Solution Project home gets three new events: `home_project_credential_copied` (with a `credentialType` enum), `home_custom_report_refresh_clicked`, and `home_notebook_action_clicked` (`action: 'create' | 'analyze'`). "Get Connected" in the popover now sets a new `home_popover` Connect sheet source. The compute and GitHub stats now send `home_activity_stat_clicked` as well, with two new `stat_type` values. Every event fires from its click handler with a typed `track()` call, and none sends the copied value or any user-defined name. This follows the telemetry standards, so no `data-attr` attributes are added. ## How to verify 1. On a project's home page, open the "Copy" popover and copy each item. Each copy sends one `home_project_credential_copied` event, with `credentialType` set to `project_url`, `publishable_key`, `direct_connection_string`, or `cli_setup`. No event contains the copied value. 2. In the same popover, click "Get Connected". The Connect sheet opens and sends `connect_sheet_opened` with `source: 'home_popover'`. Opening it from the header button afterwards still sends `source: 'header_button'`. 3. Click the "Compute size" stat. It sends `home_activity_stat_clicked` with `stat_type: 'compute'` and no `stat_value`. 4. Click the "GitHub" stat. It sends `home_activity_stat_clicked` with `stat_type: 'github'`, and `stat_value` is 1 when a repository is connected and 0 when none is. 5. With the custom report section shown, click "Refresh report". It sends one `home_custom_report_refresh_clicked` event. 6. With the Notebooks section shown, click "New notebook" (or "Create your first notebook" when there are none). It sends `home_notebook_action_clicked` with `action: 'create'`. Click "Analyze" on a notebook with cells: it sends `action: 'analyze'`. ## Checks Ran `tsc --noEmit` in `apps/studio` and `packages/common`, `eslint` and the type-aware `eslint.type-checks.config.cjs` lint on the changed Studio files, `oxfmt --check` on every changed file, and `vitest run` for `ProjectConnectionPopover.platform.test.tsx` and `ActivityStats.test.tsx`. ## Checklist - [x] I have read the [Contributing Guidelines](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] I have checked that the change works in the preview deployment ## Feedback for Tedd To ask Tedd for a change to this PR, reply in Tedd's session on [FE-5026](https://linear.app/supabase/issue/FE-5026/track-usage-on-project-home-gaps-only). Tedd doesn't read comments on this PR. --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com> |
||
|
|
3e4ee05bfd |
docs(kotlin): add passkey, oauth server api, realtime filter docs (#49897)
## I have read the [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) file. YES ## What kind of change does this PR introduce? Docs update **Authentication and Authorization Enhancements:** * Added documentation and examples for passkey-based authentication and registration, including manual flows for starting and verifying authentication and registration using the underlying API methods. * Introduced detailed documentation for OAuth 2.1 server features, including methods for retrieving authorization details, approving/denying authorizations, listing grants, and revoking grants. **Query and Data Filtering Improvements:** * Added a new `dryRun()` (limit) function, allowing users to limit query results by count, with support for specifying a referenced table. * Updated `selectAsFlow` and `postgresListDataFlow` examples to demonstrate the use of inline filter lambdas, making it easier to filter results (e.g., by `id`). * Enhanced `postgresChangeFlow` example to show how to apply optional filters using a lambda. **Realtime and System Events:** * Added an example for listening to system updates via `systemFlow()` on a channel, including configuration for broadcasting system messages (e.g., replication readiness). --------- Co-authored-by: Safa Orhan <safaorhan@users.noreply.github.com> |
||
|
|
f4a929907b |
chore(studio): promote jsx-a11y/heading-has-content to error (#54320)
## Problem `jsx-a11y/heading-has-content` is tracked by the Studio ESLint ratchet with a baseline of 0 violations. The ratchet stops new violations from adding up, but the rule is still only a warning, so the editor and `lint` don't flag a new empty heading as an error. ## Solution Promote the rule to `error` in the Studio ESLint config, and remove its ratchet bookkeeping from `.github/eslint-rule-baselines.json` and `scripts/ratchet-rules.json`. No source file breaks the rule, so no code changes are needed. ## How to verify 1. `pnpm --filter studio run lint:ratchet` reports no regressions. 2. `pnpm --filter studio run lint` reports 0 errors. 3. `pnpm exec eslint --print-config <any studio file>` from `apps/studio` shows `jsx-a11y/heading-has-content` at severity 2 (error). ## Checks Ran `pnpm --filter studio run lint:ratchet` (no regressions), `eslint .` in `apps/studio` (0 errors, no `heading-has-content` findings), `eslint --print-config` (rule resolves to error), and `oxfmt --check` on the changed files. Skipped the typecheck because no TypeScript file changed. ## Checklist - [x] I have read the [Contributing Guidelines](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] I have checked that the change works in the preview deployment ## Feedback for Tedd To ask Tedd for a change to this PR, reply in Tedd's session on [FE-5253](https://linear.app/supabase/issue/FE-5253/weekly-eslint-ratchet-review-for-supabasesupabase-appsstudio). Tedd doesn't read comments on this PR. Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> |
||
|
|
e395e057cf |
[FE-5108] (part 6) chore(studio): remove next/link shim and Vite alias (#54309)
Part 6 (final) of a 6-PR stack migrating all `next/link` imports in `apps/studio` onto TanStack Router's `Link` (or plain `<a>` for known external URLs) and removing `compat/next/link.tsx`. | Part | PR | Scope | | --- | --- | --- | | 1 | #54304 | `data/prefetchers/PrefetchableLink.tsx` and `components/ui/**` | | 2 | #54305 | `components/layouts/**` and top-level shell components | | 3 | #54306 | Database, TableGridEditor, Storage, SQLEditor, BranchManagement, Branching, Functions, Realtime | | 4 | #54307 | Integrations, Settings, Observability, LogDrains, Issues, Linter, Reports, QueryPerformance, QuerySources, ConfigDrift, DiskManagement, Compute | | 5 | #54308 | Remaining `components/interfaces/**` (Org, Billing, Auth, Support, Home, SignIn, ConnectSheet, etc.) | | **6** | **#54309 ← this PR** | **Remove `compat/next/link.tsx` shim, Vite alias, and update basePath tests/docs** | Now that no files in `apps/studio` import `next/link`, deletes `compat/next/link.tsx` and removes its Vite alias so any future `next/link` import fails the build. **Removed:** - `apps/studio/compat/next/link.tsx` - `'next/link'` entry from `nextShims` in `apps/studio/vite.config.ts` **Changed:** - Moved `apps/studio/compat/next/link-basepath-navigation.test.tsx` to `apps/studio/lib/navigation-basepath.test.tsx` to keep basePath navigation coverage for `DynamicLink` and `navigateToUrl` - Updated `nextCompat()` error text in `apps/studio/vite.config.ts` and routing docs in `apps/studio/AGENTS.md` to reflect that only `next/script` remains shimmed - Cleaned up stale `next/link` / `Link shim` comments in `apps/studio/lib/internal-url.ts`, `apps/studio/lib/router-url-shape.test.tsx`, and `knip.jsonc` Addresses [FE-5108](https://linear.app/supabase/issue/FE-5108/replace-the-nextlink-shim-with-tanstack-link) ## To test - [ ] Confirm `git grep -E 'next/link|compat/next/link' apps/studio knip.jsonc` returns zero matches - [ ] Confirm Studio typecheck, ESLint ratchet, Knip, production Vite build, and Vitest suite pass - [ ] Spot-check `apps/studio/lib/navigation-basepath.test.tsx` and `apps/studio/lib/router-url-shape.test.tsx` Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
6bd006dc08 |
feat(docs): layout toggle (#53688)
## Problem - docs layout v2 (variant `option-1` of the `docs-ia-mvp-v1` flag) is about to roll out and a reader in the rollout has no way back to the classic layout ## Solution - adds a toggle button bottom of the guide right column so user in the rollout can switch back - adds a dialog that asks for an optional reason when a reader switches back to classic, and stores the reason in `feedback_comments` with `metadata.source = 'docs_layout_switch'` so we relying on existing - adds the `docs_layout_updated` event and stops new experiment exposures for readers who picked a layout | toggle | survey | | -------|------| | <img width="654" height="312" alt="image" src="https://github.com/user-attachments/assets/69bcd4b8-7dd2-4fd3-9045-e3246625ccf9" /> | <img width="654" height="312" alt="image" src="https://github.com/user-attachments/assets/4b18eb76-b9f1-4d96-be25-14a960b11475" /> | <!-- ## Preview links If relevant, include links to changed pages for easy review access. Copy the preview base URL from the Vercel bot comment on this PR. Use the following table as an example template. | Site | Live | Preview | Search for | | -------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ | ----------------------------- | | WWW | [/blog/your-post](https://supabase.com/blog/your-post) | [/blog/your-post](https://zone-www-dot-com-git-branch-name-supabase.vercel.app/blog/your-post) | unique phrase from the change | | Docs | [/docs/guides/your-page](https://supabase.com/docs/guides/your-page) | [/docs/guides/your-page](https://docs-git-branch-name-supabase.vercel.app/docs/guides/your-page) | unique phrase from the change | | Studio | [/dashboard](https://supabase.com/dashboard) | [/dashboard](https://studio-git-branch-name-supabase.vercel.app/dashboard) | unique phrase from the change | | Design system | [/design-system](https://supabase.com/design-system) | [/design-system](https://design-system-git-branch-name-supabase.vercel.app/design-system) | unique phrase from the change | | UI library | [/library](https://supabase.com/library) | [/library](https://ui-library-git-branch-name-supabase.vercel.app/library) | unique phrase from the change | | Knowledge base | [/kb/guides/your-page](https://supabase.com/kb/guides/your-page) | [/kb/guides/your-page](https://kb-git-branch-name-supabase.vercel.app/kb/guides/your-page) | unique phrase from the change | --> <!-- ## Additional context Optionally add any other context or screenshots. --> ## Review instructions 1. open [/docs/guides/database/prisma?docs-ia-mvp-v1=option-1](https://docs-git-antlio-feat-docs-layout-switch-v2-supabase.vercel.app/docs/guides/database/prisma?docs-ia-mvp-v1=option-1) 2. click "Switch to classic layout" in the notice and make sure that a dialog asks "What made you switch back?" ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
680633ee4f |
[FE-5108] (part 5) refactor(studio): migrate remaining interfaces off next/link (#54308)
Part 5 of a 6-PR stack migrating all `next/link` imports in `apps/studio` onto TanStack Router's `Link` (or plain `<a>` for known external URLs) and removing `compat/next/link.tsx`. | Part | PR | Scope | | --- | --- | --- | | 1 | #54304 | `data/prefetchers/PrefetchableLink.tsx` and `components/ui/**` | | 2 | #54305 | `components/layouts/**` and top-level shell components | | 3 | #54306 | Database, TableGridEditor, Storage, SQLEditor, BranchManagement, Branching, Functions, Realtime | | 4 | #54307 | Integrations, Settings, Observability, LogDrains, Issues, Linter, Reports, QueryPerformance, QuerySources, ConfigDrift, DiskManagement, Compute | | **5** | **#54308 ← this PR** | **Remaining `components/interfaces/**` (Org, Billing, Auth, Support, Home, SignIn, ConnectSheet, etc.)** | | 6 | #54309 | Remove `compat/next/link.tsx` shim, Vite alias, and update basePath tests/docs | Migrates the remaining `components/interfaces/**` directories off `next/link`, leaving zero `next/link` component imports in `apps/studio`. **Changed:** - Replaced `next/link` across all 73 remaining interface files (`Organization`, `OrganizationInvite`, `Billing`, `Auth`, `Support`, `ProjectHome`, `Home`, `Project`, `ProjectCreation`, `ProjectAPIDocs`, `ApiAuthorization`, `App`, `ConnectSheet`, `SignIn`, `APIKeys`, `Account`, `CliLogin`, `Docs`, `JwtSecrets`, `Platform`) - Converted the sole remaining `UrlObject` link (`<Link href={{ pathname: '/sign-in-sso', query }}>`) in `SignInSSOForm.tsx` to `<Link to="/sign-in-sso" search={query}>` - Migrated `SupportLink.tsx` onto `DynamicLink` (`createSupportFormUrl(...)`) - Standardized external `target="_blank"` anchors with `rel="noreferrer noopener"`, switched `OverviewMetrics.tsx` observability link to typed `<Link to="/project/$ref/observability/auth">`, and adopted `InlineLink` / `InlineLinkClassName` on inline paragraph links per review feedback Addresses [FE-5108](https://linear.app/supabase/issue/FE-5108/replace-the-nextlink-shim-with-tanstack-link) ## To test - [ ] Check Organization (billing, usage, team, documents, AWS Marketplace), Auth (providers, templates, rate limits, users, OAuth apps), Support form/links, Project Home, Connect sheet, and Sign-In/SSO links - [ ] Verify `SignInWithSSOButton` preserves query params when navigating to `/sign-in-sso` - [ ] Verify `SupportLink` pre-populates support form query parameters cleanly --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
7a6c6f7df8 |
fix(studio): fix Publish OAuth app button tooltips (#54359)
## Problem Users who don't have the required permissions to publish an oauth app may see two tooltips when hovering the _Publish OAuth app_ button. <img width="620" height="208" alt="image" src="https://github.com/user-attachments/assets/fedf7150-35e6-4429-b0c0-2fbc4cd2aa5e" /> ## Solution Hide the shortcut tooltip when users don't have the required permissions to publish an oauth app |
||
|
|
df798783e1 |
[FE-5108] (part 4) refactor(studio): migrate integrations, settings & observability off next/link (#54307)
Part 4 of a 6-PR stack migrating all `next/link` imports in `apps/studio` onto TanStack Router's `Link` (or plain `<a>` for known external URLs) and removing `compat/next/link.tsx`. | Part | PR | Scope | | --- | --- | --- | | 1 | #54304 | `data/prefetchers/PrefetchableLink.tsx` and `components/ui/**` | | 2 | #54305 | `components/layouts/**` and top-level shell components | | 3 | #54306 | Database, TableGridEditor, Storage, SQLEditor, BranchManagement, Branching, Functions, Realtime | | **4** | **#54307 ← this PR** | **Integrations, Settings, Observability, LogDrains, Issues, Linter, Reports, QueryPerformance, QuerySources, ConfigDrift, DiskManagement, Compute** | | 5 | #54308 | Remaining `components/interfaces/**` (Org, Billing, Auth, Support, Home, SignIn, ConnectSheet, etc.) | | 6 | #54309 | Remove `compat/next/link.tsx` shim, Vite alias, and update basePath tests/docs | Migrates `components/interfaces/{Integrations,Settings,Observability,LogDrains,Issues,Linter,Reports,QueryPerformance,QuerySources,ConfigDrift,DiskManagement,Compute}/` off `next/link`. **Changed:** - Replaced `next/link` across all 72 files in Integrations, Settings, Observability, LogDrains, Issues, Linter, Reports, QueryPerformance, QuerySources, ConfigDrift, DiskManagement, and Compute interfaces - Updated legacy permanent-redirect hrefs (`/settings/database` → `/database/settings`, `/settings/vault/secrets` → `/integrations/vault/secrets`, `/reports/database#database-size-report` → `/observability/database#database-size-report`) to canonical routes - Flattened legacy nested `<Link><a>...</a></Link>` markup in `DatabaseReadOnlyAlert.tsx` and dropped `passHref` in `Integrations/Queues/QueueTab.tsx` - Standardized external `target="_blank"` anchors with `rel="noreferrer noopener"`, switched `ObservabilityOverviewFooter.tsx` to `InlineLink` + `DOCS_URL`, and applied `InlineLinkClassName` to the typed billing links in `DatabaseReadOnlyAlert.tsx` per review feedback - Removed `vi.mock('next/link', ...)` from `Settings/General/Project.test.tsx` and `MobileIssuesNavigation.platform.test.tsx` Addresses [FE-5108](https://linear.app/supabase/issue/FE-5108/replace-the-nextlink-shim-with-tanstack-link) ## To test - [ ] Navigate across Integrations (marketplace, cron, queues, wrappers, Vercel/GitHub), Settings (database, infrastructure, read replicas, logs), Observability, Issues, and Compute pages - [ ] Verify Logs Preview → Logs Explorer links preserve multi-line SQL queries in search params - [ ] Verify billing and database-size links preserve query parameters and hash fragments --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
5be070974d | Add Data Processing Addendum v2 (effective December 1, 2026) (#54301) | ||
|
|
e0635f2f38 |
[FE-5108] (part 3) refactor(studio): migrate database, editors & storage off next/link (#54306)
Part 3 of a 6-PR stack migrating all `next/link` imports in `apps/studio` onto TanStack Router's `Link` (or plain `<a>` for known external URLs) and removing `compat/next/link.tsx`. | Part | PR | Scope | | --- | --- | --- | | 1 | #54304 | `data/prefetchers/PrefetchableLink.tsx` and `components/ui/**` | | 2 | #54305 | `components/layouts/**` and top-level shell components | | **3** | **#54306 ← this PR** | **Database, TableGridEditor, Storage, SQLEditor, BranchManagement, Branching, Functions, Realtime** | | 4 | #54307 | Integrations, Settings, Observability, LogDrains, Issues, Linter, Reports, QueryPerformance, QuerySources, ConfigDrift, DiskManagement, Compute | | 5 | #54308 | Remaining `components/interfaces/**` (Org, Billing, Auth, Support, Home, SignIn, ConnectSheet, etc.) | | 6 | #54309 | Remove `compat/next/link.tsx` shim, Vite alias, and update basePath tests/docs | Migrates `components/interfaces/{Database,TableGridEditor,Storage,SQLEditor,BranchManagement,Branching,Functions,Realtime}/` off `next/link`. **Changed:** - Replaced `next/link` across all 60 importing files in Database, TableGridEditor, Storage, SQLEditor, BranchManagement, Branching, Functions, and Realtime interfaces - Updated legacy permanent-redirect hrefs (`/reports` → `/observability`, `/database/schema` → `/database/schemas`) to their canonical TanStack routes - Dropped legacy `passHref` in `GridHeaderActions.tsx`, removed duplicate `RouterLink` alias in `ChooseFunctionForm.tsx`, and removed `vi.mock('next/link', ...)` in `ReplicationPipelineLayout.test.tsx` Addresses [FE-5108](https://linear.app/supabase/issue/FE-5108/replace-the-nextlink-shim-with-tanstack-link) ## To test - [ ] Check Table Editor, SQL Editor, Database (tables, policies, functions, triggers, replication, backups), Storage (files/analytics/vector buckets), Edge Functions, Branching, and Realtime links - [ ] Verify SQL Editor and Table Editor links with query parameters (`schema`, `content`, `search`) do not double-encode values --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
6dd7062496 |
[FE-5108] (part 2) refactor(studio): migrate layouts & shell off next/link (#54305)
Part 2 of a 6-PR stack migrating all `next/link` imports in `apps/studio` onto TanStack Router's `Link` (or plain `<a>` for known external URLs) and removing `compat/next/link.tsx`. | Part | PR | Scope | | --- | --- | --- | | 1 | #54304 | `data/prefetchers/PrefetchableLink.tsx` and `components/ui/**` | | **2** | **#54305 ← this PR** | **`components/layouts/**` and top-level shell components** | | 3 | #54306 | Database, TableGridEditor, Storage, SQLEditor, BranchManagement, Branching, Functions, Realtime | | 4 | #54307 | Integrations, Settings, Observability, LogDrains, Issues, Linter, Reports, QueryPerformance, QuerySources, ConfigDrift, DiskManagement, Compute | | 5 | #54308 | Remaining `components/interfaces/**` (Org, Billing, Auth, Support, Home, SignIn, ConnectSheet, etc.) | | 6 | #54309 | Remove `compat/next/link.tsx` shim, Vite alias, and update basePath tests/docs | Migrates all `apps/studio/components/layouts/**` files and top-level navigation shell components off `next/link`. **Changed:** - Replaced `next/link` across `components/layouts/**` (`AccountLayout`, `AppLayout`, `AuthLayout`, `BranchLayout`, `DatabaseLayout`, `EdgeFunctionsLayout`, `ExplorerLayout`, `IssuesLayout`, `LogsLayout`, `Navigation`, `ObservabilityLayout`, `ProjectLayout`, `ProjectNeedsSecuring`, `SQLEditorLayout`, `SignInLayout`, `TableEditorLayout`, `Tabs`) and top-level shell components (`Sidebar.tsx`, `UserDropdown.tsx`, `LocalDropdown.tsx`, `HomePageActions.tsx`) - Removed `vi.mock('next/link', ...)` from `LocalDropdown.test.tsx` and `ProjectNeedsSecuring.test.tsx` - Added accessible labels where external icon/logo links switched from `<Link>` to plain `<a>` (`AdminStudioButton.tsx`, `ForgotPasswordLayout.tsx`) Addresses [FE-5108](https://linear.app/supabase/issue/FE-5108/replace-the-nextlink-shim-with-tanstack-link) ## To test - [ ] Navigate across top header, left sidebar, user/local dropdown, and project/org/branch switchers - [ ] Verify mobile navigation menu items and recent-tab links navigate with expected query params - [ ] Verify sign-in and forgot-password layout links work cleanly --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
0a4cec0464 |
[FE-5108] (part 1) refactor(studio): migrate core UI & prefetchers off next/link (#54304)
Part 1 of a 6-PR stack migrating all `next/link` imports in `apps/studio` onto TanStack Router's `Link` (or plain `<a>` for known external URLs) and removing `compat/next/link.tsx`. | Part | PR | Scope | | --- | --- | --- | | **1** | **#54304 ← this PR** | **`data/prefetchers/PrefetchableLink.tsx` and `components/ui/**`** | | 2 | #54305 | `components/layouts/**` and top-level shell components | | 3 | #54306 | Database, TableGridEditor, Storage, SQLEditor, BranchManagement, Branching, Functions, Realtime | | 4 | #54307 | Integrations, Settings, Observability, LogDrains, Issues, Linter, Reports, QueryPerformance, QuerySources, ConfigDrift, DiskManagement, Compute | | 5 | #54308 | Remaining `components/interfaces/**` (Org, Billing, Auth, Support, Home, SignIn, ConnectSheet, etc.) | | 6 | #54309 | Remove `compat/next/link.tsx` shim, Vite alias, and update basePath tests/docs | Migrates `data/prefetchers/PrefetchableLink.tsx` and all shared `components/ui/**` components off `next/link`. **Added:** - `apps/studio/components/ui/DynamicLink.tsx` (with unit tests) — shared `forwardRef` link wrapper for dynamic URL strings that runs `splitInternalUrl` and renders a plain `<a>` for external URLs (or same-origin URLs outside the app's `basePath`) vs TanStack `<Link>` for internal paths **Changed:** - Replaced `next/link` in `apps/studio/data/prefetchers/PrefetchableLink.tsx` and all 30 importing components under `apps/studio/components/ui/**` (`InlineLink`, `CardButton`, `CommandItemLink`, `ObservabilityLink`, `ProductMenuItem`, `ResourceItem`, `UpgradePlanButton`, `ToggleSpendCapButton`, banners, AI assistant panel links, etc.) - Used typed `<Link to="..." params={...} search={...} hash="..." />` for known internal routes, `<DynamicLink href={...} />` for dynamic/untyped URL strings (whether internal with query/hash or external), and plain `<a>` for known external links - Updated `apps/studio/routes/index.tsx` `validateSearch` return type to `{ next?: string }` so `<Link to="/">` compiles without requiring `search={{ next: undefined }}` - Updated `hooks/misc/__tests__/useTableEditorFiltersSort.navigation.test.tsx`, `PolicyTableRow.utils.test.ts`, `SupportAssistantSuccessCard.test.tsx`, and `useOrganizationRestrictions.test.tsx` to render inside a TanStack Router context (`customRender` / `RouterContextProvider`) Addresses [FE-5108](https://linear.app/supabase/issue/FE-5108/replace-the-nextlink-shim-with-tanstack-link) ## To test - [ ] Click internal and external `InlineLink`, `CardButton`, `ProductMenuItem`, and `PrefetchableLink` targets and verify client-side navigation vs external anchors - [ ] Verify banner links (upgrade, resource exhaustion, queue operations) preserve query params and hashes - [ ] Confirm Studio typecheck, lint, and unit tests pass --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
477e2c136f |
[FE-5109] (part 6) chore(studio): remove next/router shims, aliases, and test mocks (#54058)
Part 6 (final) of a 6-PR stack migrating all `next/router` and `next/compat/router` imports in `apps/studio` onto TanStack Router hooks and removing the router shims. | Part | PR | Scope | | --- | --- | --- | | 1 | #54053 | Core navigation helpers, `hooks/**`, `lib/**`, `data/prefetchers/**` | | 2 | #54054 | `components/ui/**` | | 3 | #54055 | `components/layouts/**` and `state/tabs.tsx` | | 4 | #54056 | Database, Branching, Compute, Edge Functions, Explorer, SQL Editor, Storage, Table Editor | | 5 | #54057 | Remaining `components/interfaces/**` and `QueryInsightsTable` router events | | **6** | **#54058 ← this PR** | **Remove `next/router` & `next/compat/router` shims, `_router-events.ts`, Vite aliases, and test mocks** | Now that no files in `apps/studio` (or `packages/**`) import `next/router` or `next/compat/router`, deletes the router shims, `_router-events.ts`, their Vite aliases, and the obsolete router test mocks. `RouteValidationWrapper` is intentionally left for FE-3107. **Removed:** - `apps/studio/compat/next/router.ts`, `apps/studio/compat/next/compat/router.ts`, and `apps/studio/compat/next/_router-events.ts` - `'next/router'` and `'next/compat/router'` entries from `nextShims` in `apps/studio/vite.config.ts` - Global `vi.mock('next/router', ...)` and `vi.mock('next/compat/router', ...)` in `apps/studio/tests/vitestSetup.ts`, `mockNextRouter` in `apps/studio/tests/lib/route-aware-hooks.ts`, and the unused `vi.mock('next/router')` in `tests/features/logs/LogTable.test.tsx` - Obsolete shim tests and test helpers: `compat/next/router.test.ts`, `compat/next/router-navigation.test.tsx`, `tests/config/router.tsx`, and `tests/config/router.test.tsx` **Changed:** - Simplified `createNavigationHandler` in `apps/studio/lib/navigation.ts` (and `navigation.test.ts`) to accept TanStack's `UseNavigateResult<string>` only, dropping the `NextRouter` union branch - Updated `compat/next/link-basepath-navigation.test.tsx` (renamed from `router-basepath-navigation.test.tsx`), `lib/router-url-shape.test.tsx`, and `tests/lib/route-render.test.tsx` to exercise TanStack Router hooks directly instead of the removed router shim - Cleaned up stale `next/router` comments in `compat/next/link.tsx`, `lib/internal-url.ts`, `router.tsx`, and `tests/lib/route-mock.ts` **Simplified:** - Removed `routerMock` setup from about 19 tests that no longer read it. `next-router-mock` stays for now, because the test `FrameworkProvider` still feeds `useParams` from it. - `AGENTS.md` and the `vite.config.ts` error text now say only `next/link` and `next/script` are shimmed - Renamed `compat/next/router-basepath-navigation.test.tsx` to `link-basepath-navigation.test.tsx`, and removed stale router-shim references from comments Addresses [FE-5109](https://linear.app/supabase/issue/FE-5109/replace-the-nextrouter-shims-with-tanstack-router-hooks) ## To test - [ ] Confirm `git grep -E "next/(compat/)?router|_router-events" apps/studio` returns no code or config imports (only the prose guideline in `apps/studio/AGENTS.md`) - [ ] Confirm `pnpm --filter studio run typecheck`, `pnpm --filter studio run lint`, `pnpm --filter studio run build`, Knip, and the full Studio Vitest suite pass - [ ] Spot-check basePath navigation (`next/link` + `navigateToUrl`) and multi-line query param URLs in Studio --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
0f14ef4d67 |
[FE-5109] (part 5) refactor(studio): migrate remaining interfaces and router events off next/router (#54057)
Part 5 of a 6-PR stack migrating all `next/router` and `next/compat/router` imports in `apps/studio` onto TanStack Router hooks and removing the router shims. | Part | PR | Scope | | --- | --- | --- | | 1 | #54053 | Core navigation helpers, `hooks/**`, `lib/**`, `data/prefetchers/**` | | 2 | #54054 | `components/ui/**` | | 3 | #54055 | `components/layouts/**` and `state/tabs.tsx` | | 4 | #54056 | Database, Branching, Compute, Edge Functions, Explorer, SQL Editor, Storage, Table Editor | | **5** | **#54057 ← this PR** | **Remaining `components/interfaces/**` and `QueryInsightsTable` router events** | | 6 | #54058 | Remove `next/router` & `next/compat/router` shims, `_router-events.ts`, Vite aliases, and test mocks | Migrates all remaining `apps/studio/components/interfaces/**` directories off `next/router`, including the last production `router.events` consumer (`QueryInsightsTable`) and the only default `next/router` import (`DiscordCTACard`). After this PR, zero files under `apps/studio/components/**` import `next/router` or `next/compat/router`. **Added:** - `apps/studio/components/interfaces/QueryInsights/QueryInsightsTable/QueryInsightsTable.test.tsx`: verifies that pathname changes clear selected query state without mutating destination or history search params, while same-pathname search updates preserve selection **Changed:** - Replaced the sole production `router.events.on('routeChangeStart', ...)` consumer in `QueryInsightsTable.tsx` with a `pathname` effect that clears `onCurrentSelectQuery` on pathname changes, and derived `searchQuery` directly from `nuqs` (`urlSearch`) instead of mirroring it in local state. Drops the legacy `setQueryStates({ search: null })` call on leave, which ran after `history.push` on TanStack Router (targeting the destination URL rather than the previous history entry, while browser Back is expected to restore previous search params). - Removed the `router: NextRouter` prop from `ReportWidgetRendererProps` in `Reports/ReportWidget.tsx` and updated its callers (`ChartBlock`, `ReportHeader`, `CreateReportModal`) - Updated `LOG_ROUTES_WITH_REPLICA_SUPPORT` in `Settings/Logs/Logs.constants.ts` from `[ref]` to `$ref` for TanStack route patterns - Replaced the default `import router from 'next/router'` in `Support/DiscordCTACard.tsx` with `useNavigate` - Replaced `useRouter` across `Account`, `Advisors`, `App`, `Auth`, `ErrorHandling`, `Home`, `HomePageActions`, `Integrations`, `Linter`, `LocalDropdown`, `Observability`, `Organization`, `OrganizationInvite`, `Platform/Webhooks`, `Project`, `ProjectCreation`, `ProjectHome`, `QueryPerformance`, `RedeemCredits`, `Settings`, `Sidebar`, `SignIn`, `Support`, `UnifiedLogs`, and `UserDropdown` - Updated affected tests (`Auth/Users/UserPanel`, `Home/ProjectList`, `LocalDropdown`, `Organization/*`, `OrganizationInvite`, `RedeemCredits`, `Settings/General/*`, `SignIn/SignInRecoveryCodeForm`, `UnifiedLogs/*`) **Simplified:** - `LocalDropdown`, `UserDropdown` and `RedeemCredits` build the current route from `location.href`, so the hash keeps its leading `#` - `NewOrgForm` navigates to the `returnTo` path instead of an absolute URL, which was being treated as external. It also uses a typed `/new/$slug` navigate. - Read search params from `useParams()` instead of `location.search` casts (`CronJobPage`, `QueuePage`, `LogsPreviewer`, `LinkSupportTicketPage`, `MarketplaceSidebar`, `PlanCards`, `SignUpForm`) - Dropped the dead `isReady`/`isRouterReady` constants and the `navigate<AnyRouter, string>` casts where typed routes work (`ForgotPasswordWizard`, `SignInPartner`, `ReportWidget`, `ProjectUpgradeAlert`) - Linter, `ReportHeader` and `LogsPreviewer` use `to: '.'` instead of a separate pathname subscription. `CreateReportModal` builds the preserved query params in `onSuccess` instead of a `useMemo`. - Tests use the shared `createTestRouter` and `customRender` router. `LocalDropdown` now tests that the hash is kept. Addresses [FE-5109](https://linear.app/supabase/issue/FE-5109/replace-the-nextrouter-shims-with-tanstack-router-hooks) ## To test - [x] Query Insights: select a query and confirm search/filter updates keep selection while switching projects/routes clears it; navigating to Logs keeps Logs' query params intact and pressing Back restores Query Insights' `?search=` param cleanly - [x] Auth / Sign-in flows: sign in, sign up, MFA, recovery code, forgot/reset password, and partner sign-in preserve `returnTo` and redirect as expected - [x] Organization & Project flows: creating an org/project, accepting an org invite, claiming a project, redeeming credits, and deleting/pausing/restarting a project or branch navigate cleanly - [ ] Logs & Reports: replica selector appears on supported log routes (`LOG_ROUTES_WITH_REPLICA_SUPPORT`), saved log queries open, and custom reports create/navigate properly - [ ] Sidebar, LocalDropdown, UserDropdown, Integrations (Cron/Queues/Marketplace), Advisors/Linter, and Unified Logs navigate cleanly --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
d8568215ad |
[FE-5109] (part 4) refactor(studio): migrate database, editor, storage, and functions interfaces off next/router (#54056)
Part 4 of a 6-PR stack migrating all `next/router` and `next/compat/router` imports in `apps/studio` onto TanStack Router hooks and removing the router shims. | Part | PR | Scope | | --- | --- | --- | | 1 | #54053 | Core navigation helpers, `hooks/**`, `lib/**`, `data/prefetchers/**` | | 2 | #54054 | `components/ui/**` | | 3 | #54055 | `components/layouts/**` and `state/tabs.tsx` | | **4** | **#54056 ← this PR** | **Database, Branching, Compute, Edge Functions, Explorer, SQL Editor, Storage, Table Editor** | | 5 | #54057 | Remaining `components/interfaces/**` and `QueryInsightsTable` router events | | 6 | #54058 | Remove `next/router` & `next/compat/router` shims, `_router-events.ts`, Vite aliases, and test mocks | Migrates the database, branching, compute, functions, explorer, SQL editor, storage, and table editor interfaces off `next/router` and `next/compat/router`. **Changed:** - Migrated the sole `next/compat/router` consumer (`components/interfaces/Database/Replication/Destinations.tsx`) to `useNavigate` - Replaced `useRouter` across `BranchManagement`, `Branching`, `Compute`, `Database` (`Backups`, `Functions`, `Replication`, `Schemas`, `Tables`, `Triggers`), `EdgeFunctions`, `Explorer`, `Functions`, `SQLEditor`, `Storage` (`AnalyticsBuckets`, `FilesBuckets`, `VectorBuckets`, `StorageMenuV2`, `Storage.utils`), and `TableGridEditor` with TanStack Router hooks (`useNavigate`, `useLocation`, `useRoutePattern`) and `useParams` from `common` - Updated unit and component tests across `Database/Replication`, `Explorer`, `Functions`, and `Storage/FilesBuckets/DeleteBucketModal.test.tsx` to use TanStack Router **Simplified:** - `useSnippetEditor` and `useRedirectLegacyReadReplicaDestination` read search values from `useParams` instead of casting `location.search` - `resolveSourceSwitch` returns `replace: boolean` instead of a `push`/`replace` method name - `ExplorerQueryTab` and `EdgeFunctionDetails` guard on a defined ref instead of navigating with `ref ?? ''` - `useFunctionsDetailShortcuts` and `StorageMenuV2` use a local `goTo` helper for their navigation shortcuts - Tests use the shared `createTestRouter` and `customRender` router, use `toMatchObject` for search assertions, and drop duplicate assertions Addresses [FE-5109](https://linear.app/supabase/issue/FE-5109/replace-the-nextrouter-shims-with-tanstack-router-hooks) ## To test - [ ] SQL Editor: creating, renaming, moving, opening templates/examples, and keyboard shortcuts navigate between snippets cleanly - [ ] Table Editor & Database: opening tables, schema table nodes, triggers, functions, backups/PITR, and replication destination flows navigate as expected - [ ] Storage: switching between Files, Analytics, and Vector buckets and deleting a bucket navigates cleanly - [ ] Edge Functions & Explorer: opening function details/logs, explorer chat/query tabs, and branch management actions navigate properly --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
57d40e4705 |
[FE-5109] (part 3) refactor(studio): migrate layout components off next/router (#54055)
Part 3 of a 6-PR stack migrating all `next/router` and `next/compat/router` imports in `apps/studio` onto TanStack Router hooks and removing the router shims. | Part | PR | Scope | | --- | --- | --- | | 1 | #54053 | Core navigation helpers, `hooks/**`, `lib/**`, `data/prefetchers/**` | | 2 | #54054 | `components/ui/**` | | **3** | **#54055 ← this PR** | **`components/layouts/**` and `state/tabs.tsx`** | | 4 | #54056 | Database, Branching, Compute, Edge Functions, Explorer, SQL Editor, Storage, Table Editor | | 5 | #54057 | Remaining `components/interfaces/**` and `QueryInsightsTable` router events | | 6 | #54058 | Remove `next/router` & `next/compat/router` shims, `_router-events.ts`, Vite aliases, and test mocks | Migrates all `apps/studio/components/layouts/**` files and the studio tab router integration off `next/router`. **Added:** - `useTabRouter()` in `apps/studio/state/tabs.tsx` so tab state actions navigate via TanStack's `useNavigate` + `navigateToUrl` instead of taking a `NextRouter` instance **Changed:** - Replaced `useRouter` across all layout directories (`AccountLayout`, `AdvisorsLayout`, `AppLayout`, `AuthLayout`, `BranchLayout`, `ComputeLayout`, `DatabaseLayout`, `DefaultLayout`, `EdgeFunctionsLayout`, `ExplorerLayout`, `LogsLayout`, `Navigation/*`, `ObservabilityLayout`, `OrganizationLayout`, `ProjectLayout`, `ProjectNeedsSecuring`, `ProjectSettingsLayout`, `RealtimeLayout`, `SQLEditorLayout`, `SignInLayout`, and `Tabs`) with TanStack Router hooks (`useNavigate`, `useLocation`, `useRoutePattern`) and `useParams` from `common` - Updated `ProjectDropdown.utils.ts` and `ProjectDropdown.test.ts` to work with TanStack `$param` route templates - Updated layout component tests (`AccountLayout.selfhosted.test.tsx`, `AdvisorsNavigationShortcuts.test.tsx`, `BranchLink.test.tsx`, `ExplorerLayout.test.tsx`, `ExplorerNavChats.test.tsx`, `ObservabilityMenu.utils.test.tsx`, `MobileIssuesNavigation.platform.test.tsx`, `ProjectLayout/index.test.tsx`, `ProjectNeedsSecuring.test.tsx`, `ProjectDropdown.test.tsx`) **Simplified:** - `OrganizationLayout` and `SettingsLayout` match against `useRoutePattern()` instead of the real pathname. An org slug ending in a settings segment (e.g. `acmeapps`) no longer gets the settings title. - `ProjectSettings.Commands` opens the Connect sheet through nuqs, the same way `Connect.Commands` does - `OrgMenuContent`, `OrganizationSettingsMenu` and `useTabRouter` read `orgSlug`/`schema` from `useParams` instead of casting `location.search` - Removed the dead `getPathnameWithoutQuery` helpers and their tests - `usePreservedQueryParams` builds its string in the `useLocation` selector (no `useMemo`), and `UnhealthyState` only navigates when `ref` is set - Moved `MobileIssuesNavigation.platform.test.tsx` onto a TanStack test router. It now covers the active-route logic again. - Tests use the shared `createTestRouter` and `customRender` router Addresses [FE-5109](https://linear.app/supabase/issue/FE-5109/replace-the-nextrouter-shims-with-tanstack-router-hooks) ## To test - [ ] Switching projects, organizations, and branches from the top header dropdowns preserves the current sub-route where supported - [ ] Opening, switching, and closing Table Editor / SQL Editor tabs updates the URL and active tab cleanly - [ ] Active sidebar item highlighting works across Database, Auth, Edge Functions, Observability, Logs, Realtime, Explorer, and Project Settings layouts - [ ] Mobile navigation menu and floating toolbar sheets open and navigate properly --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
bd4912cbdc |
feat(studio): track SQL editor sidebar, snippet and editor tab usage (#54170)
## Context Adds seven PostHog events through `useTrack` for the SQL Editor to better identify usage patterns there, each fired from its click or submit handler: - `sql_editor_new_item_clicked` (`itemType`) for the "+" menu. <img width="229" height="150" alt="image" src="https://github.com/user-attachments/assets/f6281bdb-d70e-4e7c-adf3-edce0ec2116c" /> - `sql_editor_snippet_search_submitted`: once per search session, on the first keystroke into an empty search box. <img width="285" height="214" alt="image" src="https://github.com/user-attachments/assets/4c482385-cab1-49d3-9aaa-e2be1aafb1af" /> - `sql_editor_snippet_sort_updated` (`sortBy`) when the sort order changes. <img width="226" height="121" alt="image" src="https://github.com/user-attachments/assets/0e7268ee-bf4a-46d4-ba8d-f07a6e9b0675" /> - `sql_editor_snippet_action_clicked` (`action`, `isBulk`) for snippet and folder context-menu actions. <img width="254" height="275" alt="image" src="https://github.com/user-attachments/assets/7338df06-47df-47be-b44d-6fc2dd49c586" /> - `sql_editor_snippet_share_submitted` when the share modal is confirmed. <img width="531" height="309" alt="image" src="https://github.com/user-attachments/assets/997e7567-9fdb-400e-af1a-147a5dcbb7a7" /> - `sql_editor_snippet_moved` (`snippetCount`, `toNewFolder`) after a move succeeds. <img width="539" height="247" alt="image" src="https://github.com/user-attachments/assets/f0da9544-d29e-402f-a0d3-9b7f5e3fa3c6" /> - `editor_tab_closed` (`closeType`, `editor`) in the tab bar that the SQL, Table and Explorer editors share. It fires when the tabs actually close, after any unsaved-changes confirmation. <img width="147" height="64" alt="image" src="https://github.com/user-attachments/assets/96073c69-acf1-4829-8532-beb283b7f373" /> No property carries names, SQL or search text, and every event is sent with an explicit `track()` call. ## How to verify On the PR's Studio preview, with analytics consent accepted, watch the network requests to the telemetry endpoint: 1. In the SQL editor, open the "+" menu and pick a new snippet, a new folder and (when available) a new logs query. Each one sends `sql_editor_new_item_clicked` with the matching `itemType`. 2. Type into the snippet search box. One `sql_editor_snippet_search_submitted` goes out on the first character, and none on later ones. Clear the box and type again: one more goes out. 3. Change the sort to Alphabetical, then to Created At. Each change sends `sql_editor_snippet_sort_updated` with `sortBy` `name` or `inserted_at`. Picking the current sort again sends nothing. 4. Right-click a snippet and pick each action (open in new tab, rename, move, share, unshare, duplicate, add to or remove from favorites, export, delete). Each sends `sql_editor_snippet_action_clicked` with that `action` and `isBulk: false`. Shift-click several snippets and pick move or delete: `isBulk: true`. 5. Right-click a folder and pick create snippet, rename or delete: `action` is `folder_create_snippet`, `folder_rename` or `folder_delete`. 6. Confirm the share modal: `sql_editor_snippet_share_submitted` goes out. Move a snippet into a new folder: after it succeeds, `sql_editor_snippet_moved` goes out with `snippetCount: 1, toNewFolder: true`. 7. In the SQL editor and the Table editor tab bars, use Close, Close Others, Close to the Right and Close All, and the tab's X button. Each sends `editor_tab_closed` with the matching `closeType` and `editor`. If you cancel an unsaved-changes prompt, nothing is sent. --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> Co-authored-by: Joshen Lim <joshenlimek@gmail.com> |
||
|
|
c76cbaaeed |
chore: micro upgrade copy (#54348)
We are trying to move away from the "Free" copy - it is free as in no additional costs, but not FREE |
||
|
|
3dcb524f9e |
fix(studio): make OAuth access levels single-select (#54109)
## Problem The OAuth app editor has separate Read and Write checkboxes. The menu closes after each click, so choosing both scopes takes two trips through the menu. ## Solution Use Studio’s single-select control to set the full access level in one step. The current scopes determine the label on the trigger. The choices are **No access**, **Read only**, **Write**, and **Read and write**. Each choice updates the scopes for that row and preserves other rows. This is the base for #54006. The scoped personal access token editor has a companion update in #54164. | Before | After | | --- | --- | | <img width="651" height="297" alt="CleanShot 2026-11-26 at 15 33 36" src="https://github.com/user-attachments/assets/dd74666a-9a5a-42fa-97f3-d866e5394d93" /> | <img width="649" height="307" alt="CleanShot 2026-11-27 at 11 30 25" src="https://github.com/user-attachments/assets/48395dd5-032e-49eb-9663-709eeac40fc3" /> | ## Review instructions 1. Open the [OAuth Apps preview](https://studio-staging-git-dnywh-oauth-permission-acces-6a3679-supabase.vercel.app/dashboard/org/_/apps) and select **Publish OAuth app**. 2. Under **Application permissions**, try each access level on a row. Check that one selection closes the menu and updates the trigger. 3. Select **No access** and check that both scopes are cleared for that row. Check that another row’s selection stays in place. |
||
|
|
1eef82327a |
Add TZP Group case study (#54347)
## Problem The TZP Group case study is ready to publish. Tracked in [MARKET-2535](https://linear.app/supabase/issue/MARKET-2535/case-study-tzp-group). ## Solution - Adds `apps/www/_customers/tzp-group.mdx` and the TZP Group logos (`on-light` and `on-dark` PNGs). - Moves "Key results" to the end of the TZP Group case study. - Moves "Key results" to the end of the Assignar case study too, so the two match. This changes a page that is already live. ## Preview links | Site | Live | Preview | Search for | | ---- | ---- | ------- | ---------- | | WWW | /customers/tzp-group | Vercel bot comment | One platform to rule them all | 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Wendie Cheung <wendie.cheung@supabase.io> Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com> |
||
|
|
fb37145641 |
docs(skills): the docs review gives each new sentence a verdict and checks each claim (#54082)
## Problem [#53996](https://github.com/supabase/supabase/pull/53996) passed an author review, two agent readers, and a full agent review, and still needed [#54013](https://github.com/supabase/supabase/pull/54013) to fix it. The new section repeated three sections of the same page, described worker-pool internals that a reader can't configure, and left the Functions architecture guide saying the opposite. `review-the-docs` and the style guide already named repeated facts. The rule didn't hold, for these reasons: - The Content review listed problems as examples ("they aren't the full list"), and its checklist asked only that "each problem is reported". A light review and a full one produced the same report. - No rule gave content problems a severity, and core rule 6 called style notes suggestions. - No rule covered internals the reader can't act on, or a statement on another page that says the opposite. - The review had no claim check of its own. `write-the-docs` has an accuracy pass, but a review runs on its own and can't count on the author having used that skill. `test-the-docs` runs only snippets. Tedd's own review skills filled these gaps with stricter copies of the rules, so people, Tedd, and CodeRabbit reviewed against different rules. Closes [DOCS-1806](https://linear.app/supabase/issue/DOCS-1806/the-docs-review-checks-each-claim-and-gives-each-new-sentence-a) ## Solution **The Content review in `review-the-docs` asks for a verdict on each item.** Each new and changed sentence gets a verdict, and so does the sentence right after each change. Each of these problems is a blocker: - A repeated fact - A disagreement with the docs, searched for in `apps/docs/content/` and `apps/kb/src/content/` by the behavior's terms. The published page can be the wrong one, so the Fact check decides which sentence is true, and the change fixes the wrong one - Mechanism the reader can't act on - Detail that only fits one reporter's case. The fix for one error, or an answer that depends on the reader's stack, belongs in `/kb`, per the `/docs` and `/kb` split in `write-the-docs` - An unanswered follow-up question A change longer than the ask needs is a note, because no style guide rule covers it. The review also gives a verdict on each new section's place, each new example's pattern, and each new link. The style pass counts the words of each long sentence with a script, gives a verdict on each style guide rule that applies to the changed lines, and checks the page's template and WORD_LIST. The done criterion lists each verdict, so a skipped item shows. **A new Fact check gives each claim a verdict.** Each claim gets one verdict: ran (a row in a `test-the-docs` verification report), traced to the source at the version the page uses, or unverified. When a change has more than 20 claims, or a claim needs a repo that the reviewer can't read, the review asks the user before it continues. Each path an instruction names is its own claim. A wrong claim is a blocker, and an unverified claim is a note to the author. Code runs only through `test-the-docs`, so the tutorial and example reviews ask to build example apps there, not in the reviewer's checkout. Before a wrong claim is made more exact, the review checks whether the reader needs it at all. **The `write-the-docs` accuracy pass checks that the reader needs a claim.** Its old step 3 said to add an exception the code has, or narrow the sentence, which pushed #53996 toward more internals. A new step 2 cuts a claim about mechanism the reader can't use, instead of making it more exact. An exception goes in only when it changes what the reader sees or does. The skill stays self-contained: it runs whether or not a review follows. **The style guide holds the rules the review applies.** New rules: "Document what the reader can use", "Answer the reader's next question", "Name what a command changes", "Model an example on the page's other examples", and "Put text under the heading for its topic". "Cut repeated points" now says to link to a fact that another section or page states. Required text, such as the standard SQL snippet, doesn't count as a repeat, and neither does a one-sentence term explanation or a warning that the task needs. "Link selectively" now covers two sections that send the reader to each other. The review links to each rule instead of restating it. **CodeRabbit reviews docs content against the style guide.** `.coderabbit.yaml` applies each top-level file in `apps/docs/style-guide/`, but not the templates, to `apps/docs/content/**/*.mdx` as code guidelines, so a new rule file is picked up without a config change. **Stale references.** `ask-the-docs`'s `app-map.md` and `write-the-docs` no longer point at `content/troubleshooting/`, which #52339 removed. ## Review instructions 1. Read the Content review and Fact check in `review-the-docs/SKILL.md`. 2. Check that each blocker links to a rule in `apps/docs/style-guide/`. A fresh agent ran an earlier version of the Content review and Fact check on #53996's merge commit, without seeing #54013. It requested changes and reported the problems that #54013 fixed: - The CPU cap and rotation across workers, as mechanism the reader can't act on - The same reuse fact stated four times in the section, and "runs once per worker" repeated from a later section - `guides/functions/architecture.mdx` saying "A new V8 isolate is spun up for each invocation" and "each run is stateless" It also traced each claim to `supabase/edge-runtime@v1.79.2`, and found a repeated link, a 26-word sentence, and two unverified claims. Its internals finding has a caveat: the new style guide example comes from this same case. After the review suggestions, a second fresh agent ran the current Content review and Fact check on the same commit. It found the same three problems, as blockers. It listed 17 claims, under the 20 at which the Fact check asks before it continues, so it checked each one. It reported the repeats inside the section as notes, not blockers. ## Checklist - [ ] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: Nik Richers <nik@validmind.ai> Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Co-authored-by: Nik Richers <nrichers@gmail.com> |
||
|
|
556faeab51 |
feat(studio): clarify authorized app grant details (#54284)
## Problem The grants dialog makes project coverage and each member’s permissions hard to inspect. ## Solution - Replace the dialog with a grant-details sheet. - Separate organisation and member access, with project references and permissions grouped by access level. - Move app IDs into Details and add a revoke action for authorised admins. - Build on #54285 using the existing grants API. | Before | After | | --- | --- | | <img width="1280" height="1323" alt="OAuth Apps Organization Settings Basket Supabase" src="https://github.com/user-attachments/assets/b6bb0082-9cee-48b4-adb4-058f14f10f9f" /> | <img width="1280" height="1323" alt="OAuth Apps Organization Settings Basket Supabase" src="https://github.com/user-attachments/assets/b32a7723-9fa0-452d-95f5-1762fd364163" /> | | <img width="1280" height="1185" alt="OAuth Apps Organization Settings Basket Supabase" src="https://github.com/user-attachments/assets/9a7982ba-aebe-42f4-9ac6-9308136150f7" /> | <img width="1280" height="1221" alt="OAuth Apps Organization Settings Basket Supabase" src="https://github.com/user-attachments/assets/1965f7e4-8554-4fa9-86ef-7e53af1d0038" /> | ## Review instructions 1. Sign in to staging and use an authorised app, or [authorise the test app](https://api.supabase.green/v1/oauth/authorize?client_id=75e64165-b74e-432f-bb70-80d6ae432f06&response_type=code&redirect_uri=http%3A%2F%2Flocalhost%3A54321%2Fcallback&state=grant-sheet-review). The localhost callback may fail after the grant is saved. 2. Open the [preview](https://studio-staging-git-dnywh-oauth-grant-details-supabase.vercel.app/dashboard/org/_/apps#authorized-apps), select the same organisation and choose **Manage app → View access**. 3. Check the grant sections, project references and permission groups. Test narrow widths, closing the sheet and cancelling **Revoke access**. ### Mixed-grant overrides In **DevTools → Network**, override only the GET ending in `/oauth/approvals/<app-id>/grants` with this response. Save, reload and reopen the sheet. Remove any parent `/approvals` override to avoid Chrome’s file/folder clash. <details> <summary>grants.json</summary> ```json { "data": [ { "id": "22222222-2222-4222-8222-000000000001", "type": "oauth_grant", "attributes": { "approved_at": "2026-11-30T00:00:00Z", "approved_scopes": [ "database:read", "database:write", "projects:read" ], "kind": "organization_bound", "projects": null, "user": null } }, { "id": "22222222-2222-4222-8222-000000000002", "type": "oauth_grant", "attributes": { "approved_at": "2026-11-30T00:00:00Z", "approved_scopes": [ "projects:read" ], "kind": "member_bound", "projects": [ { "name": "Example storefront", "ref": "example-storefront" } ], "user": { "username": "alex", "email": "alex@example.com", "gotrue_id": "33333333-3333-4333-8333-000000000001" } } }, { "id": "22222222-2222-4222-8222-000000000003", "type": "oauth_grant", "attributes": { "approved_at": "2026-11-30T00:00:00Z", "approved_scopes": [], "kind": "member_bound", "projects": [], "user": { "username": "sam", "email": "sam@example.com", "gotrue_id": "33333333-3333-4333-8333-000000000002" } } } ], "links": { "next": null, "prev": null } } ``` </details> Check that organisation access covers all projects, Alex has only read access to Example storefront, and Sam has no projects or permissions. Disable overrides when finished. Requires `enableScopedOAuthManage` for the organisation. |
||
|
|
99a665b8d7 |
feat(studio): polish authorized app access actions (#54285)
## Problem Authorized Apps hides access details behind a menu and uses a lengthy revoke confirmation. Opening and closing these views should work consistently with a mouse and keyboard. ## Solution - Open access details from the app row, app name or **View access** menu action. - Remove the menu tooltip, use consistent labels and hide unavailable-action separators. - Use a compact **Revoke access** confirmation with focus returned to the initiating control. - Keep the existing grants dialog and table IDs; the sheet follows in #54284. | Before | After | | --- | --- | | <img width="1274" height="687" alt="CleanShot 2026-11-30 at 17 40 25" src="https://github.com/user-attachments/assets/e7eb9411-cc2e-4bf2-8599-979f06069791" /> | <img width="1273" height="679" alt="CleanShot 2026-11-30 at 17 40 05" src="https://github.com/user-attachments/assets/d6b38690-7ba2-4c8c-adfc-0e0e356f7687" /> | | <img width="576" height="284" alt="CleanShot 2026-11-30 at 17 44 18" src="https://github.com/user-attachments/assets/e2b7f015-c214-4034-b6ab-a4afc050510d" /> | <img width="424" height="207" alt="CleanShot 2026-11-30 at 17 44 36" src="https://github.com/user-attachments/assets/77df776d-bc93-4cdb-b333-2c6c54ed6554" /> | ## Review instructions 1. Use a staging test organisation with an authorised app. If needed, [authorise the existing test app](https://api.supabase.green/v1/oauth/authorize?client_id=75e64165-b74e-432f-bb70-80d6ae432f06&response_type=code&redirect_uri=http%3A%2F%2Flocalhost%3A54321%2Fcallback&state=grant-sheet-review). The localhost callback may fail to load after the grant is saved. 2. In the [Studio staging preview](https://studio-staging-git-dnywh-oauth-access-list-polish-supabase.vercel.app/dashboard/org/_/apps#authorized-apps), open **OAuth Apps → Authorized Apps** at `/dashboard/org/_/apps#authorized-apps`. Click an app row or name, then use **Manage app → View access**. Each opens the existing grant-details dialog. 3. Focus the app name and press Enter or Space. Close the dialog and check focus returns to the app name. Opening from the row or menu should return focus to **Manage app**. 4. As an admin, select **Manage app → Revoke access**. Check the compact confirmation names the app and explains the organisation and member impact. Cancel it and check that grant details do not open accidentally and focus returns to the app menu. Revoke only a disposable test grant when checking submission. 5. As a user without revoke permission, check the menu has no revoke action or stray separator. Repeat the controls and confirmation at a narrow width. --------- Co-authored-by: Gildas Garcia <1122076+djhi@users.noreply.github.com> |
||
|
|
9623f958be |
feat: Produce sitemap and full markdown files for docs (#54069)
## Problem Agents have no single index of the docs markdown exports, unlike the KB's `sitemap.md`. www's `/llms.txt` and `/llms-full.txt` also read docs files from disk, which forces www's build to wait on the docs build. ## Solution **docs** - Add `build:markdown-sitemap`, which writes `public/markdown/sitemap.md`. It scans `public/markdown/**/*.md` and lists each file as `[title](url.md)`. Guide URLs are `/docs/guides/<page>.md` and the rest are `/docs/markdown/<page>.md`, built with the existing `internal-links` helpers. - Add `build:markdown-full`, which writes `public/markdown/full.md`. It concatenates the same files. - Both scripts share one file-list helper (`internals/markdown-files.ts`), so they always cover the same files and exclude `sitemap.md` and `full.md`. - Both tasks depend on `build:markdown` and are wired into `build` in turbo. - Search v2 ingestion and the `docs.tar.gz` archive now ignore both files. **www** - `/llms.txt` and `/llms-full.txt` now fetch `sitemap.md` and `full.md` from `NEXT_PUBLIC_DOCS_URL`, replacing only their docs parts. Pricing, product overviews, agent resources, the KB link and the customer stories link are unchanged. If docs is unreachable, the docs section is left out instead of returning a 404. - Remove the on-disk docs reads, the `outputFileTracingIncludes` entries, and the `docs#build:guides-markdown` dependency and docs input globs from www's turbo config. These routes were the only link between www and the docs build. `turbo-build.test.ts` is updated to match. - Add a `/docs.md` → `/docs/markdown/sitemap.md` redirect, next to the existing `/kb.md` one. Routes without a markdown export are not patched, they are simply absent from the sitemap. ## Review instructions From the Docs preview link: 1. Open /docs/markdown/sitemap.md it should show a file with all links to the docs pages available in markdown 1. Open /docs/markdown/full.md it should show a file with all the content from all the pages Sadly, only after deployed... 1. www project should return the content of both files when: a. supabase.com/llms.txt is queried should return docs sitemap.md content b. supabase.com/llms-full.txt is queried should return docs full.md content 1. supabase.com/docs.md should return sitemap.md file ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
9b3435010c |
fix(studio): show client ID and app ID on OAuth apps page (#54324)
## Problem On the OAuth apps page in Studio, the table showed only the Client ID, and the edit panel showed the app ID as unlabeled `ID: ...` text under the app name. It was hard to tell the two IDs apart, or to copy the right one. That contributed to the wrong ID type being handed to the team that manages the Stripe pipeline allowlist (incident, Nov 20–23). ## Solution - **Table:** add an **App ID** column next to **Client ID**. Both are shown shortened (`65****9a71`) with a copy button. Hover an ID to show the whole value. The copy button always copies the whole value. - **Edit panel:** show **Client ID** and **App ID** as separate labeled, copiable fields (full value, not shortened), each with one line of helper text: - Client ID: "Used to identify your app when it makes OAuth requests to Supabase." - App ID: "Used to manage your app on Supabase, such as updating or deleting it." - Remove the old `ID: ...` description under the app name. - Add one small shared component, `OAuthAppId`, used by the table and the edit panel. The helper text follows the discussion in Slack: `client_id` is what the deployed app sends in OAuth requests to the Management API, and `app_id` is the primary key the app's author uses in platform APIs (for example to update or delete the app). Not in this PR: the Authorized apps table already shows its App ID with a copy button, so it is unchanged. No API or data changes. ## Please check - **Helper text wording.** Is it accurate for both IDs? - **Shortened IDs.** The first 2 and last 4 characters, with `****` between, only for IDs longer than 20 characters. ## Review instructions 1. Open **Organization → OAuth Apps** (`/org/<slug>/apps`) and create an app if there is none. 2. In **Publishable apps**, check that **Client ID** and **App ID** both show as shortened values, and that each copy button copies the full value. 3. Hover a shortened ID. It should show a tooltip with the full value. 4. Open the app's edit panel. Check that Client ID and App ID are labeled, show the full value, and copy correctly, and that the old `ID: ...` text under the app name is gone. Checked locally against the full platform stack (format, lint, type-check, and by eye). No tests added: the change is layout and display only. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: John Stokvis <345546350+stokvis-at-supabase@users.noreply.github.com> Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com> Co-authored-by: kemal <hello@kemal.earth> |
||
|
|
02e61b9cda |
fix(docs): layout v2 reference fixtures (#54233)
## Problem - after #53761 the option-1 sidebar reference list has no row for server, middleware and tanstack db - list marks no row as current on a library page, for example on `/reference/javascript/select` - management api intro shows its endpoint list in the right rail and its toc in an extra column inside the content ## Solution - adds the server, middleware and tanstack db rows with the new and experimental badges of the current nav - fixes the reference list so it marks the library of the current page - changes the management api to open as its own sidebar level with the endpoint list on the left - moves the toc, the links and the feedback of the management api intro into the right rail + removes the rail on endpoint pages - adds the "on this page" menu to the management api intro below `lg` - adds the reference library column to the option-1 nav size allowlist because it is a list of peer libraries | before | after | | -------|------| | <img width="2880" height="1800" alt="image" src="https://github.com/user-attachments/assets/3a216c0b-31c1-4629-82a1-0590c7e639ae" /> | <img width="2880" height="1800" alt="image" src="https://github.com/user-attachments/assets/c53afc0e-8d15-45d7-9dc8-320443761ed2" /> | | before | after | | -------|------| | <img width="2880" height="1800" alt="image" src="https://github.com/user-attachments/assets/5dc79bb9-b160-44e6-a3c5-39182fb71d4f" /> | <img width="2880" height="1800" alt="image" src="https://github.com/user-attachments/assets/9e0dff3c-5261-4c70-b1f1-f74314231a08" /> | <!-- ## Preview links If relevant, include links to changed pages for easy review access. Copy the preview base URL from the Vercel bot comment on this PR. Use the following table as an example template. | Site | Live | Preview | Search for | | -------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ | ----------------------------- | | WWW | [/blog/your-post](https://supabase.com/blog/your-post) | [/blog/your-post](https://zone-www-dot-com-git-branch-name-supabase.vercel.app/blog/your-post) | unique phrase from the change | | Docs | [/docs/guides/your-page](https://supabase.com/docs/guides/your-page) | [/docs/guides/your-page](https://docs-git-branch-name-supabase.vercel.app/docs/guides/your-page) | unique phrase from the change | | Studio | [/dashboard](https://supabase.com/dashboard) | [/dashboard](https://studio-git-branch-name-supabase.vercel.app/dashboard) | unique phrase from the change | | Design system | [/design-system](https://supabase.com/design-system) | [/design-system](https://design-system-git-branch-name-supabase.vercel.app/design-system) | unique phrase from the change | | UI library | [/library](https://supabase.com/library) | [/library](https://ui-library-git-branch-name-supabase.vercel.app/library) | unique phrase from the change | | Knowledge base | [/kb/guides/your-page](https://supabase.com/kb/guides/your-page) | [/kb/guides/your-page](https://kb-git-branch-name-supabase.vercel.app/kb/guides/your-page) | unique phrase from the change | --> <!-- ## Additional context Optionally add any other context or screenshots. --> ## Review instructions 1. open [/docs/reference?docs-ia-mvp-v1=option-1](https://docs-ivb0vb1qq-supabase.vercel.app/docs/reference?docs-ia-mvp-v1=option-1) and do all steps in the same tab because the flag override lasts only for the tab 2. make sure that the reference list shows server and middleware 3. open [/docs/reference/javascript/select](https://docs-ivb0vb1qq-supabase.vercel.app/docs/reference/javascript/select) and make sure that the sidebar marks only the javascript row 4. click `Management API` in the sidebar and make sure that the sidebar shows `< Management API` with the endpoint list 5. make sure that the right rail shows the toc, the additional links and the feedback buttons 6. open [/docs/guides/database/overview](https://docs-ivb0vb1qq-supabase.vercel.app/docs/guides/database/overview) and make sure that the sidebar and the right rail did not change ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
25ceafcb3f |
fix(kb): guide tabs (#54046)
## Problem - on kb topic pages the guide row text is misaligned vs tab title - community guide row shows the favicon and the author before the title leading to inconsistence when among other list items - kb guide list and the docs code tabs each keep a copy of the folder tab indicator ## Solution - extracts the folder tab indicator to `ui` + the curve variables to the shared tailwind config - changes the tab corner to follow the active tab because chrome does not update a `:has()` rule on the tabs root - fixes the square corner + the background flash on the active kb tab before hydration - changes the kb guide rows to align with the tab labels + adds padding to the tabs and the row hover - moves the community favicon and author after the title | before | after | | -------|------| | <img width="2304" height="1533" alt="image" src="https://github.com/user-attachments/assets/585a1b1c-0314-4708-818c-69b324028d18" /> | <img width="2304" height="1517" alt="image" src="https://github.com/user-attachments/assets/5eb9614f-1873-42ed-86f4-1f7c8fa5e4f6" /> | <!-- ## Preview links If relevant, include links to changed pages for easy review access. Copy the preview base URL from the Vercel bot comment on this PR. Use the following table as an example template. | Site | Live | Preview | Search for | | -------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ | ----------------------------- | | WWW | [/blog/your-post](https://supabase.com/blog/your-post) | [/blog/your-post](https://zone-www-dot-com-git-branch-name-supabase.vercel.app/blog/your-post) | unique phrase from the change | | Docs | [/docs/guides/your-page](https://supabase.com/docs/guides/your-page) | [/docs/guides/your-page](https://docs-git-branch-name-supabase.vercel.app/docs/guides/your-page) | unique phrase from the change | | Studio | [/dashboard](https://supabase.com/dashboard) | [/dashboard](https://studio-git-branch-name-supabase.vercel.app/dashboard) | unique phrase from the change | | Design system | [/design-system](https://supabase.com/design-system) | [/design-system](https://design-system-git-branch-name-supabase.vercel.app/design-system) | unique phrase from the change | | UI library | [/library](https://supabase.com/library) | [/library](https://ui-library-git-branch-name-supabase.vercel.app/library) | unique phrase from the change | | Knowledge base | [/kb/guides/your-page](https://supabase.com/kb/guides/your-page) | [/kb/guides/your-page](https://kb-git-branch-name-supabase.vercel.app/kb/guides/your-page) | unique phrase from the change | --> <!-- ## Additional context Optionally add any other context or screenshots. --> ## Review instructions 1. open the live and preview [/kb/topics/database](https://kb-git-antlio-kb-guide-tabs-supabase.vercel.app/kb/topics/database) 2. make sure that the row titles start at the same position as the "All" tab label ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: alexisintech <98043211+alexisintech@users.noreply.github.com> |
||
|
|
77a62ffab4 |
fix(docs): sidebar section (#54251)
## Problem - layout v2 nav (`?docs-ia-mvp-v1=option-1`) sidebar picks its section from the url prefix and not from the tree that lists the page - tree lists `/guides/platform/read-replicas` under database, but the sidebar opens "projects, organizations and compute" and the page is not in that list - nine pages have this problem and on load or back the sidebar stays at the top while the active link of a deep page is out of view ## Solution - changes the sidebar to open the section whose tree lists the page + uses the url prefix only for a page that no tree lists - changes the header breadcrumbs to come from the same tree - adds a scroll of the active link into view on load, reload and back or forward, with no scroll when the link is already visible - changes a closed sidebar group to open when the user goes to a page inside it - changes the default nav for one page: `/guides/database/postgres/testing-row-level-security` now opens in local development, the tree that lists it - adds a test that resolves every option-1 guide page and checks that its sidebar lists it `read replicas` | before | after | | --------------------------------------------------------------------------- | -------------------------------------------------------------------------- | | <img width="2880" height="1800" alt="image" src="https://github.com/user-attachments/assets/7ac6eae2-9141-4f0b-9046-dbcf3c1fb5df" /> | <img width="2880" height="1800" alt="image" src="https://github.com/user-attachments/assets/98fbfffa-4141-416d-9c65-98dc3f1a8584" /> | `hypopg` | before | after | | --------------------------------------------------------------------------- | -------------------------------------------------------------------------- | | <img width="2880" height="1800" alt="image" src="https://github.com/user-attachments/assets/690b6b41-db7d-49af-99e2-126ee5ee9324" /> | <img width="2880" height="1800" alt="image" src="https://github.com/user-attachments/assets/52e15ad8-484a-4e37-860d-024da58dfe50" /> | <!-- ## Preview links If relevant, include links to changed pages for easy review access. Copy the preview base URL from the Vercel bot comment on this PR. Use the following table as an example template. | Site | Live | Preview | Search for | | -------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ | ----------------------------- | | WWW | [/blog/your-post](https://supabase.com/blog/your-post) | [/blog/your-post](https://zone-www-dot-com-git-branch-name-supabase.vercel.app/blog/your-post) | unique phrase from the change | | Docs | [/docs/guides/your-page](https://supabase.com/docs/guides/your-page) | [/docs/guides/your-page](https://docs-git-branch-name-supabase.vercel.app/docs/guides/your-page) | unique phrase from the change | | Studio | [/dashboard](https://supabase.com/dashboard) | [/dashboard](https://studio-git-branch-name-supabase.vercel.app/dashboard) | unique phrase from the change | | Design system | [/design-system](https://supabase.com/design-system) | [/design-system](https://design-system-git-branch-name-supabase.vercel.app/design-system) | unique phrase from the change | | UI library | [/library](https://supabase.com/library) | [/library](https://ui-library-git-branch-name-supabase.vercel.app/library) | unique phrase from the change | | Knowledge base | [/kb/guides/your-page](https://supabase.com/kb/guides/your-page) | [/kb/guides/your-page](https://kb-git-branch-name-supabase.vercel.app/kb/guides/your-page) | unique phrase from the change | --> <!-- ## Additional context Optionally add any other context or screenshots. --> ## Review instructions 1. visit [read replicas](https://docs-ka3i13eje-supabase.vercel.app/docs/guides/platform/read-replicas?docs-ia-mvp-v1=option-1) and make sure that the sidebar shows "database" and highlights "overview" under "read replicas" 2. make sure that the header breadcrumbs show "database replication", "read replicas" and "about read replicas" 3. visit [hypopg](https://docs-ka3i13eje-supabase.vercel.app/docs/guides/database/extensions/hypopg?docs-ia-mvp-v1=option-1) and make sure that the sidebar scrolls to "hypopg: hypothetical indexes" under "performance and monitoring" 4. reload the page and make sure that the active link stays in view ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
5578904100 |
fix(docs): sidebar v2 nav polish (#54267)
## Problem - layout v2 docs sidebar current page has only brighter text and users in the friction log could not find their place - section headings have the same gray as the rows under them and users found the sections hard to tell apart - in the light theme most provider icons on the auth pages do not load because the sidebar lacks of a light version ## Solution - fixes the provider icons in the light theme - changes the current row in the page tree to a filled row with a heavier weight - changes the rows in the page tree to one step brighter so the section headings read as labels - fixes the overview row at the top of each product tree, which looked like a second current row | before | after | | -------|------| | <img width="560" height="1280" alt="image" src="https://github.com/user-attachments/assets/d09afb9b-8d27-46f6-9e14-65b749d9ed5b" /> | <img width="560" height="1280" alt="image" src="https://github.com/user-attachments/assets/45a8cd1b-f2e9-4ac3-847c-97adc857cf72" /> | <!-- ## Preview links If relevant, include links to changed pages for easy review access. Copy the preview base URL from the Vercel bot comment on this PR. Use the following table as an example template. | Site | Live | Preview | Search for | | -------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ | ----------------------------- | | WWW | [/blog/your-post](https://supabase.com/blog/your-post) | [/blog/your-post](https://zone-www-dot-com-git-branch-name-supabase.vercel.app/blog/your-post) | unique phrase from the change | | Docs | [/docs/guides/your-page](https://supabase.com/docs/guides/your-page) | [/docs/guides/your-page](https://docs-git-branch-name-supabase.vercel.app/docs/guides/your-page) | unique phrase from the change | | Studio | [/dashboard](https://supabase.com/dashboard) | [/dashboard](https://studio-git-branch-name-supabase.vercel.app/dashboard) | unique phrase from the change | | Design system | [/design-system](https://supabase.com/design-system) | [/design-system](https://design-system-git-branch-name-supabase.vercel.app/design-system) | unique phrase from the change | | UI library | [/library](https://supabase.com/library) | [/library](https://ui-library-git-branch-name-supabase.vercel.app/library) | unique phrase from the change | | Knowledge base | [/kb/guides/your-page](https://supabase.com/kb/guides/your-page) | [/kb/guides/your-page](https://kb-git-branch-name-supabase.vercel.app/kb/guides/your-page) | unique phrase from the change | --> <!-- ## Additional context Optionally add any other context or screenshots. --> ## Review instructions 1. visit [/docs/guides/auth/users?docs-ia-mvp-v1=option-1](https://docs-git-antlio-fix-docs-sidebar-nav-polish-supabase.vercel.app/docs/guides/auth/users?docs-ia-mvp-v1=option-1) 2. make sure that the `Users` row has a filled background and that `Getting Started` has the same gray as the other rows 3. open [/docs/guides/auth/sessions/pkce-flow?docs-ia-mvp-v1=option-1](https://docs-git-antlio-fix-docs-sidebar-nav-polish-supabase.vercel.app/docs/guides/auth/sessions/pkce-flow?docs-ia-mvp-v1=option-1) and make sure that `PKCE flow` keeps the green line and has no fill 4. open [/docs/guides/auth/social-sign-in/auth-google?docs-ia-mvp-v1=option-1](https://docs-git-antlio-fix-docs-sidebar-nav-polish-supabase.vercel.app/docs/guides/auth/social-sign-in/auth-google?docs-ia-mvp-v1=option-1) in the light theme and make sure that each provider under `Social Sign-in (OAuth)` shows an icon ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
e3684c034c |
feat(studio): track usage on Project Settings: General (#54081)
## Problem Project Settings → General has almost no usage tracking. We can't tell how often users restart, pause, resume, or transfer projects from here. We also can't tell how often they copy the project ID or region, use the custom domain flow, or toggle high compliance mode. ## Solution Adds six PostHog events to `packages/common/telemetry-constants.ts`: `project_name_updated`, `project_settings_value_copied`, `project_lifecycle_action_submitted`, `project_compliance_mode_updated`, `custom_domain_step_submitted`, and `custom_domain_dns_record_copied`. Each event fires from the user's submit, confirm, copy, or toggle handler, never on render. Properties are only enums and booleans. No project names, domains, DNS record contents, or other typed values are sent. `ResumeProjectButton` is shared between settings and the paused-project home state, so it now takes a required `source` prop. The two call sites pass `settings_general` and `project_home`. Restart fires from the confirmation modal, with `restart_project` or `restart_database` depending on the chosen restart type. `DNSRecord` now types its `type` prop as `'CNAME' | 'TXT'`, so the copy event sends the record type as an enum. No `data-attr` attributes are added, because PostHog autocapture is off and they would not be collected. ## How to verify 1. On Project Settings → General, save a new project name. One `project_name_updated` event fires. 2. Copy the project ID, then the region. Each copy fires one `project_settings_value_copied` event, with `field` set to `projectRef` and then `region`. 3. Open the restart modal, then cancel it. No event fires. Confirm a restart (project or fast database reboot). One `project_lifecycle_action_submitted` fires with `action: restart_project` or `restart_database` and `source: settings_general`. 4. Confirm a pause, a resume, and a transfer. Each fires `project_lifecycle_action_submitted` with the matching `action`. A resume from settings sends `source: settings_general`; a resume from the paused project home page sends `source: project_home`. 5. Toggle high compliance mode. One `project_compliance_mode_updated` fires, with `isSensitive` set to the new value. 6. In the custom domain flow, Add, Verify, confirm Activate, and confirm Delete each fire `custom_domain_step_submitted` with `step` set to `configure`, `verify`, `activate`, and `remove`. 7. In the custom domain verification step, copy a DNS record's name, then its value. Each copy fires one `custom_domain_dns_record_copied` event, with `recordType` set to `CNAME` or `TXT` and `field` set to `name` and then `value`. ## Checks Ran `tsc --noEmit` in `apps/studio` and `packages/common`. Ran `eslint` (default config and `eslint.type-checks.config.cjs`) on the changed Studio files: no errors, only warnings that were already there. Ran `oxfmt --check` on all changed files. Ran `vitest run` on `General.test.tsx`, `Project.test.tsx`, `PauseProjectButton.test.tsx`, and `RestartServerButton.test.tsx`: all pass. ## Checklist - [x] I have read the [Contributing Guidelines](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] I have checked that the change works in the preview deployment ## Feedback for Tedd To ask Tedd for a change to this PR, reply in Tedd's session on [FE-5029](https://linear.app/supabase/issue/FE-5029/track-usage-on-project-settings-general). Tedd doesn't read comments on this PR. --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com> |
||
|
|
450939ce86 |
docs: fix the pages the Option 1 nav friction logs got stuck on (#53881)
Part of DOCS-1739 ## Problem People who tried the Option 1 navigation got stuck on these pages: - **Slow queries:** readers looked for a way to debug a slow query and didn't find the guide in the nav. Its title, "Log slow and failing queries", names the mechanism, not the task. - **JWT:** The Supabase way to build says Auth "issues a signed JWT" without saying what a JWT is. - **Docker self-hosting:** the guide opens with its own contents list, which repeats the table of contents beside it. - **Launch readiness:** readers who opened Deploy to production to ask "am I ready to launch?" found a page about branching and environments. Neither checklist is linked from it. ## Solution - **Slow-query title.** The title becomes "Find slow and failing queries", and the nav label in both navigations becomes "Find slow queries". The description still says "log slow queries", so search keeps matching. Five inbound links now use the new title. - **JWT link.** The first mention reads "JSON Web Token (JWT)" and links to the JWT guide. - **Launch intro.** Two sentences near the top of Deploy to production link the production checklist and the production security checklist. - **Docker contents list.** The in-page list is gone. Nothing linked to its anchor. ## Manual testing 1. Open [the slow-query guide on the preview](https://docs-git-docs-nav-friction-content-supabase.vercel.app/docs/guides/observability/log-slow-queries). The title reads "Find slow and failing queries", and the sidebar entry reads "Find slow queries". 2. Open [The Supabase way to build](https://docs-git-docs-nav-friction-content-supabase.vercel.app/docs/guides/getting-started/the-supabase-way-to-build). Under Auth, "JSON Web Token (JWT)" links to the JWT guide. 3. Open [Deployment and branching](https://docs-git-docs-nav-friction-content-supabase.vercel.app/docs/guides/deployment). The third paragraph links both production checklists. 4. Open [Self-hosting with Docker](https://docs-git-docs-nav-friction-content-supabase.vercel.app/docs/guides/self-hosting/docker). The page goes from the intro straight to Before you begin, with no Contents list. |
||
|
|
64051f3977 |
docs: move the Option 1 nav pages readers couldn't find (#53882)
Part of DOCS-1738 ## Problem People who tried the Option 1 navigation couldn't find some pages in the nav: - **Preview branches on Vercel:** five of eight readers struggled. The item sat two rows below Vercel Marketplace and started with "Preview", so a scan for "Vercel" stopped too early. - **Rotate a leaked API key:** readers looked under Security and compliance. The nav listed it under Start, inside API keys. - **Pause a paid-plan project:** the page sat inside organization transfers. - **Start:** API keys came before the quickstarts and tutorials that new readers come to Start for. - **Realtime:** readers expected it next to Database, Auth and Storage, in the home page's order. The nav put it inside "REST, GraphQL and Realtime". - **Auth sign-in providers:** about 20 OAuth providers filled the Auth sidebar, above the other sign-in methods. - **Observability:** Logs and monitoring kept the layout from before the Observability regroup in #50074. It also left out the Observability overview and Logs in the CLI. ## Solution - **Vercel.** The item becomes "Vercel preview branches" and sits next to Vercel Marketplace. The Marketplace page and Deploy to production link to it. Those two page edits ship to all readers, not only Option 1. - **Rotate a leaked API key.** The item moves to Security and compliance. The API keys page already links to it. - **Paid-plan pausing.** The item moves next to Free project pausing. - **Start order.** Quickstarts and tutorials come first. API keys and the legacy-key migration follow. - **Realtime.** Realtime gets its own sidebar and sits after Storage in Products. The APIs sidebar becomes "REST and GraphQL APIs". Products now has 8 items, one over the proposal's 7-item rule, by decision. - **Observability groups.** Logs and monitoring uses today's task groups: Read project data, Detect and diagnose, Agent prompts, and Configure and export. It lists the overview and Logs in the CLI again. The label stays "Logs and monitoring". Metrics API and Platform webhooks keep their own groups. - **Auth SDK entries.** "Server SDK" and "Middleware SDK" become "Server SDK reference" and "Middleware SDK reference", so readers know the link leaves the guides. The Self-hosting reference entries already use that pattern. - **Sign-in options.** "Social sign-in (OAuth)" and "Other sign-in methods" merge into one "Sign-in options" group. The providers sit in a collapsible "Social sign-in (OAuth)" group inside it. The level-size allowlist follows the new path. ## Manual testing 1. Open [Broadcast with Option 1 on the preview](https://docs-git-docs-nav-page-moves-supabase.vercel.app/docs/guides/realtime/broadcast?docs-ia-mvp-v1=option-1). The sidebar header reads "Realtime", with a button back to Products. 2. Open [Vercel Marketplace with Option 1](https://docs-git-docs-nav-page-moves-supabase.vercel.app/docs/guides/integrations/vercel-marketplace?docs-ia-mvp-v1=option-1). The sidebar lists "Vercel preview branches" under Vercel Marketplace, and the page links to Preview branches on Vercel. 3. Open [Logs in the CLI with Option 1](https://docs-git-docs-nav-page-moves-supabase.vercel.app/docs/guides/observability/cli-logs?docs-ia-mvp-v1=option-1). The sidebar lists it under Logs and monitoring > Read project data. 4. Run `pnpm run -F docs test:local:unwatch features/IaNav components/Navigation`. Expect all tests to pass. 5. Open [Vercel Marketplace without the flag](https://docs-git-docs-nav-page-moves-supabase.vercel.app/docs/guides/integrations/vercel-marketplace). The page links to Preview branches on Vercel. |
||
|
|
0c5d4d1bc1 |
fix(studio): reset selected orgs when switching scoped token resource access (#54323)
Switching resource access on the scoped access token form now clears the selected organizations as well as the selected projects, so a selection made in one mode doesn't carry over to the other. Adds a test covering the Project → Organization switch. |
||
|
|
7636e18f8d |
docs: shorten and sentence-case the Option 1 sidebar labels (#53880)
Part of DOCS-1737 ## Problem People who tried the Option 1 navigation reported labels that wrap onto two lines, such as "Architecture, limits and pricing". The old 35-character limit let that label through at 32 characters. They also reported labels that aren't in sentence case, such as "Framework Quickstarts" and "ORM Quickstarts". The docs style guide asks for sentence case. ## Solution - **28-character limit, enforced.** A new test in `option1.test.ts` fails on any Option 1 sidebar label over 28 characters. 97 labels were over the limit. They're shortened. - **Sentence case.** About 120 more labels are recased. Proper nouns and product feature names keep their capitals, such as Edge Functions, Row Level Security and Auth Hooks. "Self-Hosting" becomes "Self-hosting" in the top nav and the sidebar title. - **Parallel Start labels.** "Web app demos" becomes "Web app tutorials", to match "Mobile tutorials". - **Build becomes Products.** The tree test ran each candidate label against the shipped Option 1 tree, with 93 tasks and 3 runs each. Products raised direct success from 51% to 59%, and first clicks on the right section from 78% to 88%. - **Test fixtures.** `DocsSidebarNav.test.tsx` and the level-size allowlist reference labels by name, so they change too. ## Manual testing 1. Open [Getting started with Option 1 on the preview](https://docs-git-docs-nav-label-casing-supabase.vercel.app/docs/guides/getting-started?docs-ia-mvp-v1=option-1). The sidebar shows "Framework quickstarts" and "Web app tutorials". 2. Run `pnpm run -F docs test:local:unwatch features/IaNav components/Navigation`. Expect all tests to pass. |
||
|
|
11943b34fe |
chore(studio): test setup polyfills (#54039)
## Problem - `apps/studio/tests/setup/radix.js` holds the jsdom stubs for `ResizeObserver` and `scrollIntoView` but nothing in it is specific to radix - studio already keeps its jsdom stubs in `tests/setup/polyfills.ts` ## Solution - moves the `ResizeObserver` and `scrollIntoView` stubs into `tests/setup/polyfills.ts` + removes `radix.js` from the vitest setup files - changes the studio-testing skill to name the one dom setup file that remains <!-- ## Preview links If relevant, include links to changed pages for easy review access. Copy the preview base URL from the Vercel bot comment on this PR. Use the following table as an example template. | Site | Live | Preview | Search for | | -------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ | ----------------------------- | | WWW | [/blog/your-post](https://supabase.com/blog/your-post) | [/blog/your-post](https://zone-www-dot-com-git-branch-name-supabase.vercel.app/blog/your-post) | unique phrase from the change | | Docs | [/docs/guides/your-page](https://supabase.com/docs/guides/your-page) | [/docs/guides/your-page](https://docs-git-branch-name-supabase.vercel.app/docs/guides/your-page) | unique phrase from the change | | Studio | [/dashboard](https://supabase.com/dashboard) | [/dashboard](https://studio-git-branch-name-supabase.vercel.app/dashboard) | unique phrase from the change | | Design system | [/design-system](https://supabase.com/design-system) | [/design-system](https://design-system-git-branch-name-supabase.vercel.app/design-system) | unique phrase from the change | | UI library | [/library](https://supabase.com/library) | [/library](https://ui-library-git-branch-name-supabase.vercel.app/library) | unique phrase from the change | | Knowledge base | [/kb/guides/your-page](https://supabase.com/kb/guides/your-page) | [/kb/guides/your-page](https://kb-git-branch-name-supabase.vercel.app/kb/guides/your-page) | unique phrase from the change | --> <!-- ## Additional context Optionally add any other context or screenshots. --> ## Review instructions 1. run `pnpm test:studio` and make sure that the run reports no unhandled errors 2. make sure that the failures are the same as on `master` ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
a098c3be32 |
chore(studio): improve versioning onboarding comms (#54059)
## Problem We're going to release versioning in Public Alpha instead of Private, so we need to be more clear and loud about the new feature being introduced. ## Solution This PR makes a few changes mostly around communications and messaging: - Update `Private Alpha` badges to `Public Alpha` - Add admonitions in the feature preview modal - Prompt confirmation before enabling versioning on a bucket - Dedicated announcement banner in Storage layout - shown only to users with `storage.capabilities.object_versioning` enabled - Popover card when hovering over the Public Alpha badge See [update](https://linear.app/supabase/project/storage-object-versioning-and-lifecycle-policies-b5e5809a718e/activity#project-update-e9a50e15) for more context. ## Review instructions Functionality changes are minor so mostly check the above mentioned messaging and ui changes. |
||
|
|
132f6b6d08 |
test: Add minimal tests for redirects on apps/docs (#54071)
## Problem We were lacking on redirect rules on apps/docs ## Solution Added basic unit test for: - Infinite redirects - Redirect chains - Missing redirects - Invalid sources or destinations <!-- ## Preview links If relevant, include links to changed pages for easy review access. Copy the preview base URL from the Vercel bot comment on this PR. Use the following table as an example template. | Site | Live | Preview | Search for | | -------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ | ----------------------------- | | WWW | [/blog/your-post](https://supabase.com/blog/your-post) | [/blog/your-post](https://zone-www-dot-com-git-branch-name-supabase.vercel.app/blog/your-post) | unique phrase from the change | | Docs | [/docs/guides/your-page](https://supabase.com/docs/guides/your-page) | [/docs/guides/your-page](https://docs-git-branch-name-supabase.vercel.app/docs/guides/your-page) | unique phrase from the change | | Studio | [/dashboard](https://supabase.com/dashboard) | [/dashboard](https://studio-git-branch-name-supabase.vercel.app/dashboard) | unique phrase from the change | | Design system | [/design-system](https://supabase.com/design-system) | [/design-system](https://design-system-git-branch-name-supabase.vercel.app/design-system) | unique phrase from the change | | UI library | [/library](https://supabase.com/library) | [/library](https://ui-library-git-branch-name-supabase.vercel.app/library) | unique phrase from the change | | Knowledge base | [/kb/guides/your-page](https://supabase.com/kb/guides/your-page) | [/kb/guides/your-page](https://kb-git-branch-name-supabase.vercel.app/kb/guides/your-page) | unique phrase from the change | --> <!-- ## Additional context Optionally add any other context or screenshots. --> ## Review instructions _Unit tests for redirects should run as part of our CI in PRs, including this one._ ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
a934f2b8f5 |
feat(www): show paused notice on SupaSquad page instead of apply CTA (#53976)
Replaces the "Apply to Join SupaSquad" button on /open-source/contributing/supasquad with an "Applications are currently paused" callout linking to Discord, upcoming events, and GitHub. - `CtaSection` gains an optional `notice` prop; buttons are now optional. - To reopen applications, remove `notice` and restore `primaryCta` in `data/open-source/contributing/supasquad.tsx`. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com> |
||
|
|
418d251abe |
fix(studio): ensure we allow partial grants on all projects (#54311)
## Problem When users try to authorize all current and future projects with unsufficient permissions for an app that allows partial grants, the consent screen does not display the correct message and block them from authorizing the app. ## Solution Fix the conditions to display the proper message about missing features and allow authorization with partial grants. ## Review instructions - Configure an app that allows partial grants (must be member bound) - Configure a user without enough permissions (Read-only for instance) - Use the oauth example app to authorize the app with this user - Check that you are warned about missing features but that you can still authorize the app |
||
|
|
b1fe45c103 |
docs(kb): add egress quota and cost FAQs (#54221)
I added two knowledge base FAQs: one on what happens when an organization goes over its egress quota, and one on what egress costs. Both follow the existing FAQ shape, with the answer in the first sentence, short prose, and links to the docs for detail. **Changed:** - **Going over the quota**: explains the email and grace period on the Free plan and on Pro with the spend cap on, the 402 responses that follow if usage stays over the quota, and how to lift a restriction. - **Egress cost**: states the included quota per plan, the overage rates, how cached egress differs, and that Pro pays for overage only with the spend cap off. ## To test Tested on the PR preview: - [x] Open `/kb/faqs/platform/exceed-egress-quota`, expect the page to render with the question as its title and four paragraphs of answer - [x] Open `/kb/faqs/platform/egress-cost`, expect the page to render with the question as its title and five paragraphs of answer - [x] On each page, follow the link to the other FAQ, expect it to open the other page with no 404 ## Linear - fixes GROWTH-1557 |
||
|
|
fe8e912993 |
refactor(www): split redirects into static and dynamic files and add redirect checks (#54194)
## Problem `apps/www/lib/redirects.js` was a single file with static and dynamic rules mixed together, and the redirects had no automated checks. `/docs` redirects already moved to `apps/docs/lib/redirects/`, so www was the odd one out. ## Solution I applied the docs layout to www without changing how redirects are served: - `apps/www/lib/redirects/static-redirects.json`: 220 one-to-one entries, including fixed redirects to external `https://` URLs. - `apps/www/lib/redirects/dynamic-redirects.js`: 14 entries with params, splats, regex, escapes, or `has`. - `apps/www/lib/redirects/index.js`: combines both (static first) for `next.config.mjs` and `scripts/generateMdContent.mjs`. - `apps/www/lib/redirects/redirects.test.ts`: checks for loops, chains, duplicate sources, invalid sources and destinations (anchors, missing `/` or `https://`), dynamic entries in the static file, and internal destinations that do not exist. - README for the folder, plus updates to `apps/www/README.md`, `DEVELOPERS.md`, `CODEOWNERS`, and the `www-tests` path filter and sparse checkout. Bulk redirects are not part of this PR: www has 234 redirects, well under the route limit, so they stay in `next.config.mjs`. ### Missing-destination check Internal destinations are checked against the same sources the site serves from: - `app/` and `pages/` routes, and `public/` files. - Blog, customer, event, and alternative slugs, derived the way `lib/posts.tsx` derives them. Events with `disable_page_build` do not count. - Feature and `/go` page slugs. - `.md` destinations must be a page that `generateMdContent.mjs` publishes. An existing HTML page is not enough. - `/docs/guides` destinations, against the docs content and guide routes. Other zones and build-generated files are not checked. A destination with params is probed with one sample value, so value-specific loops or chains are not caught. The README lists these limits. ### Behavior notes - The rule set matches `master`, with one exception: `/blog/2021/07/30/1-the-supabase-hackathon` now points at the canonical slug `/blog/1-the-supabase-hackathon`. The old destination `/blog/the-supabase-hackathon` also resolves today, because the blog route matches posts by filename suffix. The check requires canonical slugs. - First-match results on `supabase.com` are identical on 241 probe paths. - Static entries now precede dynamic ones. On the `supabase.design` host, 25 static sources that used to sit after its catch-all rule now come before it. Those paths now take two hops to reach the design system instead of one. - Comments on static entries were dropped, because JSON has no comments. ## To test 1. Open the www preview and visit `/about`. It redirects to `/company`. 2. Visit `/buildersday`. It redirects to `/builderday`. 3. Visit `/sign-in`. It redirects to the dashboard sign-in page. 4. Visit `/blog/2021/07/30/1-the-supabase-hackathon`. It lands on the hackathon post. ## Linear - fixes GROWTH-1571 |
||
|
|
c2edb29076 |
fix(studio): explain Supavisor session pool limits DEBUG-43 (#53930)
## Problem When Supavisor rejects a session because its connection pool is full, Studio shows the error without explaining how to recover. ## Fix Show a troubleshooting step for the session-mode limit that explains how pool size limits concurrent clients and links to the configuration guide. ## Screenshot The Table Editor’s troubleshooting step, rendered locally with a sample session-pool error. <img width="660" alt="Expanded Supavisor session pool limit guidance in the Table Editor" src="https://github.com/user-attachments/assets/6072eec4-e243-4d53-a40f-30fb14d21d05" /> ## How to test - Display a classified MaxClientsInSessionMode error in Studio and expand its troubleshooting step. The link should open the pool size section of the database connection management guide. - Display a generic transaction-mode connection limit error. It should keep its usual fallback. - The pattern, classification and ErrorMatcher suites exercise these paths (144 tests passed locally). Fixes [DEBUG-43](https://linear.app/supabase/issue/DEBUG-43). |
||
|
|
d65dacdb74 | chore(self-hosted): update 2026-11-30 - 0.8.6 (#54296) | ||
|
|
5d6b070942 |
feat(studio): add Permission issue option to the support form (FE-5101) (#54079)
## Problem The support form's "What issue are you having?" dropdown has no option for permission problems. Users who are blocked by a permission error can't tell us that's what they're hitting, so the backend can't treat those submissions differently. Linear: https://linear.app/supabase/issue/FE-5101 ## Solution Adds a `Permission issue` option to the category dropdown. It is sent to `POST /platform/feedback/send` as `category: 'Permission_issue'`, the same way the other categories are. - `@supabase/shared-types` is an external package, so I followed the existing `Plan_upgrade` and `Others` approach and added the value to the local `ExtendedSupportCategories` type instead of the shared enum. - Added the new value to the assistant handoff zod schema so a handoff carrying this category passes validation. - Added a component test that selects the option and checks the submitted payload. This PR is frontend only. No backend behavior changes here. ## Review instructions 1. Open the support form (`/support/new`). 2. Open the "What issue are you having?" dropdown and check that `Permission issue` is listed after "Issues with logging in", with the description "Issues accessing an organization or project you should have access to". 3. Select it, fill in the summary and message, and submit. In the browser network tab, check the `POST /platform/feedback/send` request body contains "category": "Permission_issue"`. |