* add assistant chats
* refactoring
* refactor
* refactor to use onfinish
* fix ts
* dependencies removal
* Update useAssistant.ts
* ts
* refactor useAssistant hook to valtio store
* Minor tweaks
* Add name param to newChat, and add names to each call of newChat
---------
Co-authored-by: Alaister Young <a@alaisteryoung.com>
Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
* improve some studio mobile layouts
* improve some studio mobile layouts
* improve settings
* assistant mobile
* assistant mobile
* assistant mobile
* responsive formlayout and new project layout
* improve dashboard pages headers
* improve dashboard auth pages
* mobile org settings
* mobile billing fixes
* adjust paused project container height
* remove comments
* triggers
* leftovers
* ai assistant
* fix errors
* remove 16px input size
* fix test
* merge access tokens settings page conflicsts
* smol integrations here and there
* Add settings for queues: toggle expose through postgrest + permissions via table privileges
* Ensure appropriate grants are granted when toggling, and revoked when disabling
* Update to use queues_public schema
* Update queue schema to pgmq_public and add/remove from data api when enabling/disabling
* Fix query for retrieving toggle state
* Add schema invalidation
* Remove hard code
* Use QueuesSettings from Queues folder, remove from NewQueues
* Update SQL for toggling exposure + support RLS enabling
* Support toggling RLS for a queue
* Update admonition copy in queues for enabling/disable postgrest exposure
* Add custom RLS policy for queue
* Minor style fixes
* Fix
* Remove hard code
* Update RLS to add message regarding relevancy only if exposure to PostgREST is enabled
* Update message in exposing queues to postgREST
* Address feedback
* Address feedback
* Don't revoke postgres role stuff
* Remove hard code
* Update copy
* Update
* Address Oli's feedback, ensure that queues ALL have RLS enabled prior to allowing exposure to PostgREST
* Address remaining feedback
* Remove hardcode
* Update
* Address feedback
* start
* added panels
* remove stuff
* fixes and refinements
* clean up
* remove old assistant panel
* resizable assistant kinda
* use icon
* Add missing package
* remove canvas
* add suggestions
* updated empty state if no tables exist
* fix table condition
* Implement diffing if using assistant in sql editor
* Reinstate old assistant in SQL editor if feature preview is off
* pane size adjustment
* assistant button corners
* Add SQL snippet content to assistant if opening assistant in sql editor
* Add the necessary checks for opt in and hipaa
* revert adding snippet to assistant when opening assistant in sql editor
* Add cmd i shortcut
* Add admonitions for when disablePrompt is toggled on, and if no api key is set. Add footer note RE rate limitation
* Bump ai package in packages
* some fixes for backwards compability depending on feature preview toggled
* Rename feature preview property for new assistant
* Smol fix
* Prevent SQL snippet from running until message is finished
* only loading last message
* fix z-index
* save chat state to global state
* add debug to failed ai queries
* Add basic contextual invalidation
* Add explain code action to SQL editor
* Add link to abort ongoing queries from SqlSnippet
* Update feature preview content
* Fix
* Fix
* Fix
* Te4st
* Fix tests
* ONly show ai button within a project
* Fix PH tracking
* Beef up a bit more event tracking
* Rough fix to padding when assistant is open
* A bit more telemetry stuff
* Update prompts
* fix rls editing via assistant
* Update generate-v3.ts
prompt to get auth schema too
* Add policy satement to assistant when editing
* Address all comments
* fixc
* Fix SqlSnippet not taking full width on larger viewports
* Adjust max width
---------
Co-authored-by: Saxon Fletcher <saxonafletcher@gmail.com>
* Hook up RLS to new assistant if feature flag is enabled
* Reset conversation if opening a different entity
* Add prompt to use alter policy if policy definition is provided
* Remove console log
* Add alpha notice
* Close assistant via cmd i if not focused on monaco
* Add edit with assistant CTA for database functions
* Attach existing function definition when editing a function to prompt
* Leave comments
* Small refactor
* Init AiAssistantPanel
* Temp
* Temp
* iterating on assistant ux
* More spiking
* Tweaking...
* Moar tweaking..
* Even more tweaking
* Tweek
* More tweaks
* Final tweaking...
* TWEAK
* Spelling
* Fix
* Assistant error handling and small bug fix in context for message
* Add feature flag
* Fix
* Address all feedback
* Minor
* 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>
* Add nuqs package.
* Add useSchemaQueryState hook.
* Use the new hook in all places where there's is a schema selector.
* Make the useQueryState work with SSR in playwright.
* Fix the saving to local storage to happen as a side effect without any additional rerenders.
* Fix highlighted state in nav bar for V1 auto docs when selecting a store procedure
* Fix RPC parameters in V2 auto docs
* Replace database functions create function button cta with ButtonTooltip
* Refactor the functions page to keep its state in the URL.
* Derive the filter options from currently active lints.
* Update the lint query sql.
* Update the urls to the docs.
* Fix the paddings on the filterPopover.
* Add handling for the other types of lints.
* Comment out the ignore lint functionality.
* Fix a misspell.
* unbest
* Bring back the CTA button.
* Update the SQL code from the splinter repo.
* Add handling for the duplicate index lint rule.
---------
Co-authored-by: Terry Sutton <saltcod@gmail.com>
* Refactor and remove the CreateFunctionStore.
* Fix a duplicate key in the functions table.
* More fixes for the create-function form.
* Add excluded schemas to schema selector.
* Cleanup the createFunction code after the merge.
* Remove unneeded wrapper fragments.
* Minor fixes for the FormItemLayout stories.
* Refactor the CreateFunction panel using the new FormItemLayout.
* Revert the migration to use FormItemLayout. Will revisit later.
* Add a CSS class for popover content width to match its trigger width. Use it on the schema selector.
* Replace all listboxes with selects.
* Fix the comments.
* Switch to FormItemLayout wherever possible.
* Move the createFunction file to its own folder.
* Refactor the panel to use shadcn components: Sheet, SheetContent and SheetHeader.
* Add showClose prop to the Sheet component.
* Add function editor and a feature to maximize/minimize the code editor.
* Some fixes
* Add sameWidthAsTrigger to the popover component.
* Fix the icon size.
---------
Co-authored-by: Jonathan Summers-Muir <MildTomato@users.noreply.github.com>
Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
* Refactor and remove the CreateFunctionStore.
* Fix a duplicate key in the functions table.
* More fixes for the create-function form.
* Add excluded schemas to schema selector.
* Cleanup the createFunction code after the merge.
* Remove unneeded wrapper fragments.
* Minor fixes for the FormItemLayout stories.
* Refactor the CreateFunction panel using the new FormItemLayout.
* Revert the migration to use FormItemLayout. Will revisit later.
* Add a CSS class for popover content width to match its trigger width. Use it on the schema selector.
* Replace all listboxes with selects.
* Fix the comments.
* Switch to FormItemLayout wherever possible.
* Some fixes
* minor lint
* One more lint
---------
Co-authored-by: Jonathan Summers-Muir <MildTomato@users.noreply.github.com>
Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
* Fix small issues with the tables and keys.
* Refactor the TimezoneSelection with shadcn components.
* Dont pass active to the NavMenuItem.
* Fix the double hash in the _ page.
* Fix an error where an input received an undefined as value.
* Fix increase retention period in PITR disabled incorrectly
---------
Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
* Alpha sort db functions, triggers and indexes tables
* Use lowercased names when sorting.
---------
Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
* Shift all usage of database functions from pg meta store to RQ
* Remove functions store from pg meta mobx store
* fix
* Fix
* Fixes
* fix
* Address comments
* set up multiple themes in studio
* set up multiple themes in studio
* set up multiple themes in docs and www
* update all resolvedTheme to also include deep-dark
* update all resolvedTheme checks to also include deep-dark
* update tailwind.config.js tokens
* update tailwind.config.js tokens
* update leftover scale12 token
* update if resolvedTheme _doesn't_ include 'dark'
* update more styling tokens
* add dynamic themes to CmdK
* fix nav and footer for multi theme
* add data-theme selector output to transformTokens.js
* update code-hike.css to target data-theme css
* update tailwindcss to ^3.3.5
* ThemeImage with light and dark src for www and docs
* add brand-button styling token
* update old dark theme boolean
* update old dark theme boolean
* make homepage product visuals themeable
* update product page themed images
* update badge green with brand
* fix roles list appearance
* fix auth widget in auth page
* update more dark logic
* update more dark logic
* add button default bg and border
* update pricing page theme styling
* clean up Themeimage
* remove forceDark in homepage
* update dark:border-dark occurrences
* update dark:border-dark occurrences
* fix dark mode base colors
* remove foreground-strong
* fix notification badge bg
* remove some dark: selectors
* update dark: selectors
* update code-hike deep dark bg color
* fix comment typo
* update border-button-hover token
* fix customer story logo
* remove some more dark: selectors
* restore forceDark in www homepage
* fix auth react icon
* fix homepage product visuals
* remove theme
* add brand-link token
* fix checkbox bg
* npm install
* more visible EntityListItem active bg
* fix --background-alternative-default css vars
---------
Co-authored-by: Jonathan Summers-Muir <MildTomato@users.noreply.github.com>
* 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.