Commit Graph

30 Commits

Author SHA1 Message Date
Charis 3b7052b5a9 cleanup: fix import order and prefixes for studio/data (#44501) 2026-04-03 09:15:57 +02:00
Raúl Barroso 86ef5e11cc feat(mgmt-api): adds partner confirmation page (#43237)
This adds some pages that will be needed soon.

Fixes
https://linear.app/supabase/issue/API-901/ship-studio-authentication-confirmation-page

Used by https://github.com/supabase/platform/pull/29718

Here are some screenshots of the 3 possible scenarios (initiated by the
Management API):

> [!NOTE]  
> As part of this flow, a new account + and a free organization will be
created.

### Initializing the confirmation flow

<img width="2708" height="1426" alt="CleanShot 2026-02-27 at 13 44
01@2x"
src="https://github.com/user-attachments/assets/e5a90886-43a9-4202-ad81-fb42c13da036"
/>

### Confirmation page

<img width="2610" height="1640" alt="CleanShot 2026-02-27 at 13 44
20@2x"
src="https://github.com/user-attachments/assets/8491fe24-c183-4987-a1c4-3d9b26dec9c3"
/>

### In the event of going through a flow with a different signed-in
account

<img width="1982" height="1564" alt="CleanShot 2026-02-27 at 13 47
44@2x"
src="https://github.com/user-attachments/assets/8a50b4c7-3fa4-4f6a-9d6f-b8776975b676"
/>

---------

Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2026-03-04 11:38:10 +00:00
Andrew Valleteau dcc5703674 feat(branching): add-pg-delta-diff-for-branching (#42952)
Allow to use the `pg-delta` capability for merge requests diffing.
Feature flag it behind an auto opt-in flag.

Must be merged after: https://github.com/supabase/platform/pull/29776
<img width="921" height="623" alt="Screenshot 2026-02-17 at 16 50 38"
src="https://github.com/user-attachments/assets/bfe704e9-4137-45e1-b0b5-1cecce284d6e"
/>


Also updated the loading + final state of the diff view to:

1. Take all the height available

- From: <img width="1894" height="893" alt="Screenshot 2026-02-16 at 20
46 15"
src="https://github.com/user-attachments/assets/22ed8c72-2d9d-4b68-b315-6d40aefc0b3c"
/>


- To: <img width="1629" height="1396" alt="Screenshot 2026-02-16 at 20
57 26"
src="https://github.com/user-attachments/assets/6e83c8e9-607d-4077-977e-046058ce3e44"
/>

2. Show a proper loading state rather than just a plain grey skeleton

- From: <img width="2232" height="1137" alt="Screenshot 2026-02-20 at 15
02 51"
src="https://github.com/user-attachments/assets/0c924b04-d60f-49b5-a5a0-3bf1942bfdef"
/>
- To:
<img width="2231" height="1129" alt="Screenshot 2026-02-20 at 15 05 46"
src="https://github.com/user-attachments/assets/49751001-1818-4842-a0c8-b74683c2e9bc"
/>
2026-02-26 15:28:13 +01:00
Andrew Valleteau 38176b82a3 feat(studio): setup soft-delete and easy branch restore (#40353)
* wip: branch deletion grace period

* fix: allow to force delete pending

* fix: update for staging

* fix: typo

* fix: revert soft-delete by default

* chore: revert branch-delete-mutation changes

* fix: revert platform.d.ts changes

* fix: use INVALID status as distinguisher

* fix: hide unusable options

* fix: apply review suggestion

Co-authored-by: Ali Waseem <waseema393@gmail.com>

* updated formatting

* fix: lint

* fix: react v5 update

---------

Co-authored-by: Ali Waseem <waseema393@gmail.com>
2025-12-18 12:14:52 +08:00
Ivan Vasilov 8b657165b5 chore: Migrate to use custom type for ReactQuery queries and mutations (#40073)
* Add custom types for queries, mutations and infinite queries.

* Migrate all queries to use the new type.

* Migrate all infinite queries to useCustomInfiniteQueryOptions.

* Migrate all mutations to use useCustomMutationOptions.

* Add type to all imports in `types` folder.
2025-11-03 13:18:13 +01:00
Ivan Vasilov da4a40e308 chore: Migrate RQ functions to use object syntax style (#39895)
* Migrate all uses of invalidateQueries to use object syntax.

* Migrate the remainder of useInfiniteQuery.

* Migrate all setQueriesData.

* Migrate all fetchQuery uses.

* Migrate some leftover functions from RQ.

* Fix issues found by Charis.
2025-10-28 10:43:14 +01:00
Alaister Young 8855d05803 chore(studio): swap react-query to object syntax (#39842)
* chore(studio): swap react-query to object syntax

* Fix small issues found

* Fix realtime settings

* Nit

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-10-27 09:38:27 +01:00
Han Qiao 77561e8e09 chore: replace branch id with branch ref (#38735)
* chore: remove unused mutation to disable branching

* chore: use branch ref in delete mutation

* chore: use branch ref in diff query

* chore: use branch ref in push mutation

* chore: use branch ref in detail query

* chore: use branch ref in update mutation

* Update apps/studio/data/branches/branch-query.ts

Co-authored-by: Charis <26616127+charislam@users.noreply.github.com>

---------

Co-authored-by: Charis <26616127+charislam@users.noreply.github.com>
2025-09-17 10:31:01 +08:00
Andrew Valleteau 1ddfaf5a9e fix(types): update branching types for api route changes (#38548)
Co-authored-by: Kevin Grüneberg <k.grueneberg1994@gmail.com>
2025-09-09 19:47:46 +08:00
Han Qiao 1a78aecb05 fix: estimate data branch cost before creation (#38511)
* fix: estimate data branch cost before creation

* chore: comments to clarify conditionals

* Use addons endpoint to check for compute size instead

* Revert branchComputeSize changes

* Fix

* chore: update compute size only on data branch

* chore: replace slow query with disk size estimate

* Add loading and error states for disk attr, and update copy in create branch modal

* Update copy to improve transparency on billing

* Tiny fix

* Nit

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-09-09 17:00:12 +08:00
Han Qiao 55daeaf962 fix: defaults to diffing all schemas (#37923) 2025-08-19 17:26:02 +08:00
Han Qiao c32c74e34c fix: diff all schemas on branch merge (#37754)
* fix: diff all schemas on branch merge

* chore: remove branching limitation on schema and extensions

* chore: remove limitation from blog post

* chore: remove limitation from docs
2025-08-12 21:18:24 +08:00
Saxon Fletcher 4bfdbe32ac add with data field to branch (#37451)
* add with data field to branch

* Fix types

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-07-28 18:14:55 +08:00
Joshen Lim b4717e1787 Some fixes for local studio (#37147) 2025-07-15 17:22:23 +08:00
Saxon Fletcher b05457666f Add review requested at (#36877)
* allow creating branching without git

* update branching modals

* add account connections

* edit branch

* copy

* update copy

* enable branch modal changes

* add gitless branching flag

* update account connections

* merge page

* merge experiment

* update merge

* update pull requests empty state

* use diff query

* branch diffing

* diff query

* Clean up

* refinements to gitless branching

* branching merge and status

* link

* branch function diffing

* update styling

* refactor

* remove hook

* error handling

* move

* remove enable branching modal

* re-add github linker

* abstract away enable and disable

* toggle fixes

* update logic to lean on connection status

* update form logic

* sheet layout

* gitless flag

* style and workflow updates

* fix side panel size

* fix duplicate onerror

* copy changes

* refetch

* merge mutation copy

* remove import

* add cost

* allow connection details on create

* initial queries

* push button

* merge cleanup

* Fix TS issues

* Fix TS issues

* Couple of clean ups

* Revert hardcode in useFlag

* Fix TS

* layout issues and github check

* refactor

* refactor to use new field

* cleanup

* style

* failed merge

* error positioning

* refactoring merge

* workflow refactor

* hook move

* clarification with github integration

* replace branch dropdown button

* update repo picker

* updates

* remove modal

* fix small nits

* change defaults

* clean up

* disable if not gitless and no connection

* clean up

* always show workflow run id

* optimistic

* fix branch query

* fix issues

* fetch edge diff

* confirm merge

* update edge functions key

* add review requested at

* gitless check

* request review

* use requestReview

* use new review boolean

* unnecessary comment

* ready for review route

* hide removed functions for now

* type fix

* codegen

* Fix the types.

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
Co-authored-by: Kevin Grüneberg <k.grueneberg1994@gmail.com>
Co-authored-by: Alaister Young <a@alaisteryoung.com>
Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2025-07-09 20:45:28 +10:00
Saxon Fletcher ea38c6d153 Review and merge branch (#36795)
* allow creating branching without git

* update branching modals

* add account connections

* edit branch

* copy

* update copy

* enable branch modal changes

* add gitless branching flag

* update account connections

* merge page

* merge experiment

* update merge

* update pull requests empty state

* use diff query

* branch diffing

* diff query

* Clean up

* refinements to gitless branching

* branching merge and status

* link

* branch function diffing

* update styling

* refactor

* remove hook

* error handling

* move

* remove enable branching modal

* re-add github linker

* abstract away enable and disable

* toggle fixes

* update logic to lean on connection status

* update form logic

* sheet layout

* gitless flag

* style and workflow updates

* fix side panel size

* fix duplicate onerror

* copy changes

* refetch

* merge mutation copy

* remove import

* add cost

* allow connection details on create

* initial queries

* push button

* merge cleanup

* Fix TS issues

* Fix TS issues

* Couple of clean ups

* Revert hardcode in useFlag

* Fix TS

* layout issues and github check

* refactor

* refactor to use new field

* cleanup

* style

* failed merge

* error positioning

* refactoring merge

* workflow refactor

* hook move

* clarification with github integration

* replace branch dropdown button

* update repo picker

* updates

* remove modal

* fix small nits

* change defaults

* clean up

* disable if not gitless and no connection

* clean up

* always show workflow run id

* optimistic

* fix branch query

* fix issues

* fetch edge diff

* confirm merge

* update edge functions key

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
Co-authored-by: Kevin Grüneberg <k.grueneberg1994@gmail.com>
Co-authored-by: Alaister Young <a@alaisteryoung.com>
2025-07-04 14:57:59 +10:00
Saxon Fletcher 3f3ed433fc Remove enable branching modal (#36458)
* remove enable branching modal

* re-add github linker

* abstract away enable and disable

* toggle fixes

* update logic to lean on connection status

* update form logic

* sheet layout

* gitless flag

* fix side panel size

* copy changes

* remove import

* add cost

* allow connection details on create

* Fix TS issues

* Fix TS issues

* Couple of clean ups

* Revert hardcode in useFlag

* Fix TS

* layout issues and github check

* refactor

* refactor to use new field

* cleanup

* style

* clarification with github integration

* replace branch dropdown button

* update repo picker

* remove modal

* change defaults

* disable if not gitless and no connection

* fixes

* prevent editing on child branch

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
Co-authored-by: Kevin Grüneberg <k.grueneberg1994@gmail.com>
2025-07-02 21:58:45 +10:00
Saxon Fletcher daf8b3c3fd Create branch without GitHub connection (#35983)
* allow creating branching without git

* update branching modals

* add account connections

* edit branch

* copy

* update copy

* enable branch modal changes

* add gitless branching flag

* update account connections

* update pull requests empty state

* Clean up

* refinements to gitless branching

* nit

* nit

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-06-09 11:04:10 +10:00
Kevin Grüneberg 4532286e04 fix: align with API types (#34821)
* fix: align with API types

* Update new-project.constants.ts
2025-04-08 17:17:35 +08:00
Ivan Vasilov 4caed0103d fix: Fix a timing issue when deleting a branch (#30736)
* Add a timeout for invalidating the branch list queries. Add an optimistic deletion from the query cache when deleting a branch.

* Don't refetch the branches list if one of the branches is faulty. The branch will be updated via useBranchQuery.
2024-11-29 16:57:21 +01:00
Ivan Vasilov df52ea7ee0 feat: Replace all toasts with sonner (#28250)
* Update the design of the sonner toasts. Add the close button by default.

* Migrate studio and www apps to use the SonnerToaster.

* Migrate all toasts from studio.

* Migrate all leftover toasts in studio.

* Add a new toast component with progress. Use it in studio.

* Migrate the design-system app.

* Refactor the consent toast to use sonner.

* Switch docs to use the new sonner toasts.

* Remove toast examples from the design-system app.

* Remove all toast-related components and old code.

* Fix the progress bar in the toast progress component. Also make the bottom components vertically centered.

* Fix the width of the toast progress.

* Use text-foreground-lighter instead of muted for ToastProgress text

* Rename ToastProgress to SonnerProgress.

* Shorten the text in sonner progress.

* Use the correct classes for the close button. Add a const var for the default toast duration. Remove the custom width class from sonner.

* Set the position for all progress toasts to bottom right. Set the duration for all toasts to the default (when reusing a toast id from loading/progress toast, the duration is set to infinity).

* Fix the playwright tests.

* Refactor imports to use ui instead of @ui.

* Change all imports of react-hot-toast with sonner. These components were merged since the last commit to this branch.

* Remove react-hot-toast lib.

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
Co-authored-by: Jonathan Summers-Muir <MildTomato@users.noreply.github.com>
2024-08-31 07:50:51 +08:00
Joshen Lim 163263c3c5 First round of wrapping RQ errors with handleError (#26384)
* First round of wrapping RQ errors with handleError

* Remove the throw before the handleError usage.

* Make the handling of an API error more versatile. Add logging in Sentry if the error is of unknown type.

* Remove throwing of the handleError function.

* Add return type to the handleError function to be never so that we're sure it always throws.

---------

Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2024-05-17 16:30:55 +08:00
Kamil Ogórek 5c34fb3597 feat: Introduce persistent branches toggle (#22145)
* feat: Introduce persistent branches toggle

* tweak styling

* add tooltip and confirmation modal

---------

Co-authored-by: Alaister Young <a@alaisteryoung.com>
2024-04-11 18:14:47 +10:00
Alaister Young bd3807c356 feat: reset preview branches (#22210) 2024-03-28 20:44:41 +11:00
Kevin Grüneberg f9a55935f5 chore: use type imports for types/interfaces (#21738) 2024-03-04 20:48:22 +08:00
Alaister Young 74563fbeba chore(branching): GitHub integration 2.0 (#21008)
* start new github integration

* query/mutation updates

* progress

* branch management

* update codegen

* progress

* progress

* Refactor GitHub integration URLs

* Refactor GitHubIntegrationAuthorize component

* Updates

* Do not remove GitHub connection when creating new one

* Deleting a GH connection when branching is enabled for the project, will also disable branching for that project

* Add link to configure connection from org integration settings page

* Slight refactor

* Support updating CWD path

* Change cwd_path to workdir and disallow empty values

* Allow for triggering branches on supabase directory changes only

* Pass missing supabaseChangesOnly value

* Small style fix

* Add Authorization GitHub step

* Small change

* Fix supabase integrations form in project settings

* Revert URLa nd client ID

* Fix UI issues

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
Co-authored-by: Kamil Ogórek <kamil.ogorek@gmail.com>
2024-03-04 18:17:26 +11:00
Alaister Young a8ee3a212b feat: branching statuses first pass (#20631)
* feat: branching statuses first pass

* handle error

* use warning icon
2024-02-29 20:18:00 +11:00
Jonathan Summers-Muir eb5039c5e6 Feat/collapsible nav bar (#21550)
* Update IconButtons to expose all props and pass ref. Use UI lib tooltip instead.

* start making it collapsible

* Update app-state.ts

* more transition stuff

* add new icons in. add icon size control with constants

* rename component

* wordmark added

* fix up bottom options

* Update NavigationBar.tsx

* Update NavigationBar.tsx

* Update NavigationIconLink.tsx

* Update NavigationBar.tsx

* add button component

* Update NavigationBar.tsx

* Update NavigationIconButton.tsx

* Update NavigationBar.tsx

* Delete supabase-wordmark.svg

* Add key prop

* Lint classname

* Lint

* Small fixes

* Refactor some handleErrors in EQ

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2024-02-28 15:34:16 +08:00
Kevin Grüneberg d12332ea5a chore: xmas cleanup (#19938) 2024-01-04 17:27:49 +01:00
Ivan Vasilov 436bdb10ae chore: Move the studio app to apps/studio (#18915)
* Move all studio files from /studio to /apps/studio.

* Move studio specific prettier ignores.

* Fix the ui references from studio.

* Fix the css imports.

* Fix all package.json issues.

* Fix the prettier setup for the studio app.

* Add .turbo folder to prettierignore.

* Fix the github workflows.
2023-11-15 12:38:55 +01:00