Commit Graph

50 Commits

Author SHA1 Message Date
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
Terry Sutton
4d15119c29 opt in tags (#36885)
* Validate the aiOptInLevel on the server

* Fix another issue when the project and mismatched org.

* Fix a type error.

---------

Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2025-07-04 14:17:42 -02:30
angelico
84b8695de7 chore: transition from AWS_NEW to AWS_K8S (#36625)
* chore: transition from AWS_NEW to AWS_K8S

* chore: transition from useIsAwsNew to useIsAwsK8s
2025-06-25 11:35:07 +08:00
Kamil Ogórek
07a0d279ea ref: Use organization_slug instead of org_id for project creation (#36629) 2025-06-24 17:27:23 +08:00
Ivan Vasilov
4add928dae chore: Update API types (#35879)
* Regenerate all types from develop branch.

* Fix all types in studio.

* Remove extra type.
2025-05-26 15:43:14 +02:00
Andrew Valleteau
31aad403de fix(studio): early fail query when x-connection-encrypted is invalid (#35331)
* fix(studio): early fail query when x-connection-encrypted is invalid

* fix(studio): uniformize readDatabase and projectDetails connString handling

* chore: update api types

* chore: add connectionString null option

* fix: only enforce x-connection-encrypted on platform

* chore: refactor connString check in a single point

* chore: fix guard logic

* chore: fix pgMetaGuard

* chore: fix types
2025-05-08 12:11:03 +02:00
Kevin Grüneberg
12ba4da4a5 feat: groundwork for larger instance sizes (#35373) 2025-05-02 15:45:03 +07:00
Kamil Ogórek
c3a352331a ref: Fix all API types after Zod migration (#34903) 2025-04-11 10:28:08 +08: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
Jonathan Summers-Muir
aefb34fd9c Feat: Adds Oauth client management (#34591)
* adds Oauth client update

* moar

* Update OAuthSecrets.tsx

* Fix TS issues

* moar

* Minor refactors

* Minor refactors

* Tidy up

* Clean up

* Clean up

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-04-07 17:43:46 +08:00
Kevin Grüneberg
2ab40e48fd chore: increase stale times for a few common queries (#34643) 2025-04-02 13:57:36 +08:00
Kamil Ogórek
cb49692654 fix: Update type checks for few api endpoints (#34440) 2025-03-27 13:48:48 +01:00
Kamil Ogórek
861fe9ec88 fix: Update TS checks according to latest API changes (#34372) 2025-03-25 14:24:52 +01:00
Alaister Young
3273b5de50 fix(studio): whitelist duplicate name error on project creation (#33983) 2025-03-04 21:45:32 +08:00
angelico
9b34521bed chore: add AWS_NEW provider (#33697)
* feat: add AWS_NEW provider

* fix selecting aws region

* chore: add valid instance sizes

---------

Co-authored-by: Alaister Young <a@alaisteryoung.com>
2025-02-26 17:48:36 +08:00
Kevin Grüneberg
a283da6ddb chore: only include platform/v1 routes in api types (#33753) 2025-02-21 20:04:57 +08:00
Joshen Lim
98a5f06070 Chore/next round of refactoring rqs to use data fetchers (#33556)
* Update several files to use data fetcher methods

* Remove unused files from lib/common/fetch

* Revert "Remove unused files from lib/common/fetch"

This reverts commit b314b05f06.

* Fix GraphQL

* Fix types

* Add IS_PLATFORM check in useOrgUsageQuery

* Fix type issues
2025-02-17 15:23:38 +08:00
Joshen Lim
e539b892a6 Chore/more refactoring of data fetchers methods (#33553)
* Update postgres-service-status-query, password-strength, and free-project-limit-check-query

* Update exit-survey-send

* Update project-postgrest-config-query

* Update project-disk-resize-mutation

* Update project-update-mutation

* Update project-postgrest-config-update-mutation

* Update organization-audit-logs-query

* Fix types

* Update bucket-object-download-mutation

* Update organization-member-delete-invitation

* remove console log

* Add integer validation for disk size (enforced on the API, but lacking client side validation)

* Fix audit logs
2025-02-13 13:34:12 +08:00
Alaister Young
9d534c9f5a fix: response error codes (#30581)
* fix: response error codes

* upgrade docs

* remove request url modification middleware

* move api routes for self-hosted to platform folder

* remove some lib/common/fetch usage

* docs: use middleware for openapi-fetch (#30600)

Get rid of the unauthedAllowedPost function (I don't think there's any harm in letting any requests that require authentication to just 403, they should be disabled at the React Query level and if not they will fail gracefully enough...)

* fix local count query

* add default values for clone mutation

* fix ts and codegen

* add missing lodash dep to playwright tests

* Fix the playwright tests to match the new folder structure for selfhosted variant.

* remove unused import

* Remove unused state

* remove unused sql debug mutation

* remove unused export

* fix notifications query

* fix jwt updating status

* fix typescript

* save sql snippet after renaming

* update codegen & fix ts error

* override array querySerializer

---------

Co-authored-by: Charis <26616127+charislam@users.noreply.github.com>
Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2025-01-20 11:27:38 +08:00
Joshen Lim
e420a48826 Check for profile in projects, organizations and permissions query (#32759)
* Check for profile in projects, organizations and permissions query

* Remove unused telemetry function
2025-01-15 12:21:13 +08:00
Jordi Enric
0e930cf940 r2np: new cost (#32632)
* add new cost estimate

* fix api types

* update api types

* restore api.d.ts

* fix types

* fix utils

* clean utils getComputeHourlyPrice

---------

Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2025-01-10 13:21:53 +01:00
Joshen Lim
a4243f438f Add restrictions for orioledb technical preview (#30410)
* Add restrictions for orioledb technical preview

* Add callouts to pgvector and postgis if orioledb

* Restrict restore to new project for orioledb

* Scaffold client side validation for preventing org upgrade if org has oriole db present

* Hook up proper logic for oriole

* Fix

* Remove console log

* Fix type

* Disable version selector if only one version is available

* chore: oriole badges

* UI updates based on requests

* Update copy

* Fix

* Dont open assistant if opt is selected

* Fix

* Fix

* Update badge

* Add feature flag for orioleDB

* Feature flag oriole check in plan update

---------

Co-authored-by: Paul Cioanca <paul.cioanca@supabase.io>
2024-11-30 17:36:15 +08:00
Jordi Enric
37f77ae482 Add new ui for restore to new project (#30325)
* add new ui for restore to new project

* rm false

* fix typeerr badly

* add form with name and new project pass

* fix flash in loading > results state change

* restore api types

* update api types, add pitr picker

* add additional monthly spend section

* fix loading state jump

* update copy

* update api types

* update to new clone status api res

* fix mutation missing vars

* dont render logical backups in list

* fix state issue on submit

* better pitr empty state

* Update apps/studio/pages/project/[ref]/database/backups/restore-to-new-project.tsx

Co-authored-by: Wen Bo Xie <5532241+w3b6x9@users.noreply.github.com>

* Update apps/studio/pages/project/[ref]/database/backups/restore-to-new-project.tsx

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>

* Apply suggestions from code review

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
Co-authored-by: Wen Bo Xie <5532241+w3b6x9@users.noreply.github.com>

* update api types to accept recoveryTimeTarget for PITR restores

* simplify pitr code a bit cleanup state bugs

* cleanup

* add PITR submit

* dont show restore btn unless status is complete

* update api types

* fix backups nav

* markdown descs and fix type err in nav

* check if project is cloned

* fix: make source project data optional

* fix datepicker highlighted day style

* fix tz picker

* check if its same or before/after in isWithinRange

* update api types fix issue with clones

* unsus

* fix markdown rendering issues

* add badge

* Update database roles and permissions description

* Update restore message text in PITR form component

* Update key attribute to item.id in DatabaseBackupsNav component

* Add conditional rendering for multiple available dates

* Refactor dialog section styles in restore-to-new-project.tsx

* Update null to undefined in conditional text assignment

* reuse component in pitr backups

* Update apps/studio/pages/project/[ref]/database/backups/restore-to-new-project.tsx

Co-authored-by: Wen Bo Xie <5532241+w3b6x9@users.noreply.github.com>

* Update link to original project in RestoreToNewProject

* fix prettier

---------

Co-authored-by: Wen Bo Xie <5532241+w3b6x9@users.noreply.github.com>
Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
Co-authored-by: Crispy1975 <12525875+Crispy1975@users.noreply.github.com>
2024-11-21 17:52:10 +01:00
Alaister Young
12cc4e5fbc chore: use service versions endpoint (#30352)
* chore: use service versions endpoint

* update types

* fix types

* fallback postgres version for unknown images
2024-11-08 11:17:16 +08:00
Alaister Young
c59be649a3 chore: prefetch project homepage (#30317) 2024-11-07 16:29:07 +08:00
Kevin Grüneberg
b64999e287 feat: new disk size usage section (#29862) 2024-10-14 14:48:45 +08:00
Paul Cioanca
7559291549 feat: support for multiple pg versions (#29473)
* feat: support multiple pg versions

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2024-10-11 14:26:47 +03:00
Joshen Lim
9aabe4a40f Add number of database connections charts in database reports (#29637)
* Add number of database connections charts in database reports

* Fix type issue

* Fix more type issues

* Remove UI for requires_manual_intervention

* Update apps/studio/data/projects/project-upgrade-mutation.ts

Co-authored-by: Alaister Young <alaister@users.noreply.github.com>

---------

Co-authored-by: Alaister Young <alaister@users.noreply.github.com>
2024-10-04 16:55:01 +08:00
Terry Sutton
6015e53041 Chore/download types schemas (#29480)
Read which schemas to download types for
2024-09-24 14:34:44 -02:30
Joshen Lim
d0cbb045d9 Add check for saveNodePositions (#29471)
* Add check for saveNodePositions

* Fix https://supabase.sentry.io/issues/5389802889/?project=5459134&query=is%3Aunresolved&referrer=issue-stream&sort=freq&statsPeriod=14d&stream_index=10

* Update whitelist for https://supabase.sentry.io/issues/5856752960/?project=5459134&query=is%3Aunresolved&referrer=issue-stream&sort=freq&statsPeriod=14d&stream_index=5

* Update whitelist for https://supabase.sentry.io/issues/5759316461/?project=5459134&query=is%3Aunresolved&referrer=issue-stream&sort=date&statsPeriod=7d&stream_index=21

* Update whitelist for https://supabase.sentry.io/issues/5588800911/?project=5459134&query=is%3Aunresolved&referrer=issue-stream&sort=date&statsPeriod=7d&stream_index=11
2024-09-24 20:19:04 +08: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
22e263602e Whitelist overdue invoices FE alert (#28440) 2024-08-07 18:12:18 +08:00
Joshen Lim
5d0d63284b Support using API schema in create project (#27918)
* Support using API schema in create project

* Fixes
2024-07-12 10:25:34 +08:00
Kamil Ogórek
d249d5d94d ref: Cleanup vercel_configuration_id metadata (#27857) 2024-07-11 17:00:44 +08:00
Jonathan Summers-Muir
eb55650d76 [Dashboard] add data api option to new project form (#26809)
* init layouts in project settings

* Update general.tsx

* update gap

* Update Scaffold.tsx

* Update PostgrestConfig.tsx

* Update PostgrestConfig.tsx

* spacing issues

* now added a enabled switch

* Revert "now added a enabled switch"

This reverts commit f22050302a.

* Update PostgrestConfig.tsx

* Update PostgrestConfig.tsx

* revert

* Update project-postgrest-config-update-mutation.ts

* add bottom padding

* init changes

* Update PostgrestConfig.tsx

* Update [slug].tsx

* add radio group

* add types

* Update PostgrestConfig.tsx

* fix

* Update PostgrestConfig.tsx

* Update project-create-mutation.ts

* update API types

* Update PostgrestConfig.tsx

* Update PostgrestConfig.tsx

* Update api.d.ts

* Update API codegen typings

* fix: issue with booleans in radios

* add warning box

* Update [slug].tsx

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2024-06-25 15:47:24 +08:00
Alaister Young
c918aea9ee chore: new project statuses (#27213)
* chore: new project statuses

* add restarting layout

* add restore failed state

* update project cards

* update wording

* fix ts errors

* address feedback

* add pause failed state
2024-06-24 16:06:58 +08:00
Joshen Lim
a6b2b93f92 Disable restores if project paused for longer than 90 days (#27053)
* Disable restores if project paused for longer than 30 days

* Update to 90 days

* Update copy

* PRetty

* Update based on API changfes

* Prettier

* Update

* Minor copy fix

* simplify wording

---------

Co-authored-by: Alaister Young <a@alaisteryoung.com>
2024-06-11 18:02:56 +07:00
Joshen Lim
72fd5f5121 More whitelisting non critical errors (#27057)
* More whitelisting non critical errors

* 2 more whitelist errors
2024-06-07 13:51:20 +07:00
Joshen Lim
3a9e99f30e Add sentry alerts for critical points of failures (#27029)
* Add sentry alerts for critical points of failures

* Prettier
2024-06-06 11:07:34 +07:00
Joshen Lim
bb6349f34f Second round of wrapping RQ errors with handleError (#26428)
* 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.

* Second round of wrapping RQ errors with handleError

* Temp fix in delete credential mutation, and fix loading state

---------

Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2024-05-21 15:51:11 +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
Joshen Lim
99635fbb5e Support restarting replicas (#26240)
* Support restarting replicas

* Support restarting replica through map view

* Lint

* Lint
2024-05-14 15:47:27 +08:00
Kevin Grüneberg
f9a55935f5 chore: use type imports for types/interfaces (#21738) 2024-03-04 20:48:22 +08: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
Ivan Vasilov
d07a820440 feat: Pro+ users can choose compute size during project creation (#21292) 2024-02-20 16:19:26 +08:00
Alaister Young
a4f86bce8f chore: increase react-query stale time (#19465)
* chore: increase react-query stale time

* keep staleTime: 0 for table rows

* use staleTime: 0 for all user sql queries

* use staleTime: 0 for all pg-meta queries

* Some fixes

* fix updating tables

* fix bug while editing column names

* Fix deleting column in database/tables column list not revalidating UI

* Fix updating column in database/tables column list throwing ane rror

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2024-02-06 13:47:05 +08:00
Alaister Young
3230747a58 fix: refetch project detail on unknown status (#21035) 2024-02-06 02:23:08 +00:00
Alaister Young
026d7ee2f3 fix: refetch project detail while project is coming up (#20819)
* fix: refetch project detail while project is not healthy

* switch to only refetching while coming up
2024-01-29 09:56:52 +00:00
Joshen Lim
da792ba0ba Chore/show rr UI only if project is enabled (#19642)
* Only show RR UI if project is enabled

* Only show RR UI if project has read replicas enabled, shift DatabaseSelector state to valtio, add Database Selector to API URl

* Update usage of Project interface from types to Project from project-details-query

* Fix ts errors

* Another one

* Another one...

* God one more

* Fingers crossed

* jesus

* Add deprecate mark on ProjectBase

* Resolve conflicts

* Rename ProjectState from valtio to DatabaseSelectorState

* Rename file

* fix imports

* tiny code changes

* Fixes

---------

Co-authored-by: Alaister Young <a@alaisteryoung.com>
2023-12-20 16:49:53 +07: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