Commit Graph

13 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
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
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
Andrew Valleteau 4bd28eecb8 fix(api): set x-pg-application-name for dashboard (#37048)
chore(api): set x-pg-application-name for dashboard
2025-07-21 10:39:46 +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
Alaister Young 6c592dec99 chore: remove useExecuteSqlQuery() part 2 (#30467)
* foreign-key-constraints

* update entity-types stale time

* schemas query

* deprecate useExecuteSqlQuery

* users count query

* database size query

* indexes query

* keywords query

* migrations query

* table columns

* database functions

* database roles query

* fdws query

* replication lag query

* ongoing queries query

* vault secrets query

* remove unneeded staleTime: 0

* max connections query

* fix entity types key in tests

* Some fixes

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2024-11-18 05:15:37 +00:00
Alaister Young 3a27070dc2 chore(perf): table editor query optimisation (#30184)
* chore: table editor query optimisation

* removed unused queries and fix invalidations

* address feedback

* fix filtering for foreign tables

* Update

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2024-10-31 15:20:40 +08:00
Alaister Young 5781937739 chore: aggressive prefetching (#29987)
* chore: aggressive prefetching

* use abort signals in prefetchers

* move encrypted columns to react-query

* prefetching for filter and sort applied

* prefetch remaining entity types

* prefetch tables in more places

* prefetch editor page on project panel

* add feature flag

* fix typescript

* nit

* Nit

* fix imports

* remove views check on encrypted schemas

* use fetchQuery instead of prefetchQuery

* fix useEncryptedColumnsQuery ts error

* filter by schema on encrypted columns

* don't use pg_get_tabledef for foreign tables

* Remove unnecesary import

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2024-10-24 20:59:35 +08:00
Joshen Lim 54320ddb73 Chore/support showing all entities in database tables page (#27749)
* Support showing views in database tables page

* Support showing materialized views in database tables page

* Support showing foreign tables in database tables page

* Prevent deleting non table entities in database/tables, consistent with table editor

* Fix invalidation logic when deleting tables in database/tables
2024-07-03 14:40:45 +08:00
Kevin Grüneberg f9a55935f5 chore: use type imports for types/interfaces (#21738) 2024-03-04 20:48:22 +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
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