Commit Graph
7 Commits
Author SHA1 Message Date
Joshen Lim 66691ad9ce Joshen/fe 3384 prevent ai assistant chat panel from closing after query (#47951)
## Context

2 problems that this PR addresses - but these are in general due to the
mobile UI behaviour
- Sidebars (e.g Help Panel, Advisor Panel, etc) closes whenever there's
a route change
- This is happening because of `StudioMobileSheetNav`'s
`handleOpenChange` interfering with the sidebar visible state
- Am opting to not render `StudioMobileSheetNav` at all unless on mobile
- On mobile, if you're on the Advisor Panel, clicking the "Menu" button
closes the mobile sheet
- Clicking on the Menu button seems to be triggering `MobileSheetNav`'s
`onOpenChange`
- My suspicion is because of state asymmetry between two independent
stores (MobileSheetContext and SidebarManagerState - these 2 are a bit
too complex imo)
- Am opting to skip calling `onOpenChange` in `StudioMobileSheetNav` if
the click target is within the Floating toolbar

## To test
- [x] Desktop: Have the assistant panel open and change routes, panel
should stay open
- [x] Mobile: Open the assistant panel, then switch to the menu, panel
should stay open

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Improved mobile navigation interactions so the navigation sheet
remains open while toolbar actions are being selected.
* Mobile navigation now displays only on smaller screens, preventing it
from appearing at medium and larger breakpoints.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-07-15 17:19:02 +08:00
Saxon Fletcher 75bb899f01 Fix mobile toolbar behaviour (#47800)
**Before**

<img width="340" height="104" alt="image"
src="https://github.com/user-attachments/assets/48a434de-21c2-4e3f-8cad-3c6408f7348d"
/>

**After**

<img width="508" height="317" alt="image"
src="https://github.com/user-attachments/assets/e52c6ba6-c173-4bb8-a466-1697585286c7"
/>


Fixes 
- Rendering issue of the menu toggle on mobile when menu is open
- You can now switch between panels when open (e.g. from help to
advisor). There was previously a bug that would just close the drawer
rather than switch.

**To test**
- Reduce screen size in a project view
- Click top right menu item
- Notice menu item is active in light mode
- Click "Assistant" and notice it switches vs closes the drawer
- Click close or outside the toolbar to close the drawer

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Bug Fixes**
* Improved the mobile menu button’s visual state by updating the menu
icon color when the menu is open.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-07-10 12:14:34 +08:00
Gildas GarciaandIvan Vasilov 96d43099bb chore: refactor Button API so that it can be used a standard button (#46880)
## Problem

Our `<Button>` component breaks the default `button` contract by
redefining the `type` prop to set its variant (`primary`, `default`,
etc) instead of the button type (`submit`, `button`, etc).
This is confusing and forces to write more code when using it with
shadcn components that expect/inject the standard button props.

## Solution

- rename the `type` prop to `variant`
- rename the `htmlType` prop to `type`
- propagate the changes where necessary
- format code

## How to test

As this is just prop renaming, if it builds it's ok

---------

Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2026-06-16 23:59:58 +02:00
Ivan VasilovandJordi Enric 56de26fe22 chore: Migrate the monorepo to use Tailwind v4 (#45318)
This PR migrates the whole monorepo to use Tailwind v4:
- Removed `@tailwindcss/container-queries` plugin since it's included by
default in v4,
- Bump all instances of Tailwind to v4. Made minimal changes to the
shared config to remove non-supported features (`alpha` mentions),
- Migrate all apps to be compatible with v4 configs,
- Fix the `typography.css` import in 3 apps,
- Add missing rules which were included by default in v3,
- Run `pnpm dlx @tailwindcss/upgrade` on all apps, which renames a lot
of classes
- Rename all misnamed classes according to
https://tailwindcss.com/docs/upgrade-guide#renamed-utilities in all
apps.

---------

Co-authored-by: Jordi Enric <jordi.err@gmail.com>
2026-04-30 10:53:24 +00:00
4a0bb36ca8 style: require sorted imports in studio/components (#44408)
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2026-04-01 10:22:37 +02:00
Raminder SinghandJoshen Lim 65237597e4 feat: upgrade flow and other improvements (#43289)
This PR:

* Adds an upgrade flow to the stripe sync engine, allowing users to
upgrade to the latest version when it becomes available.
* When a new version of sync engine becomes available, users will see an
upgrade button instead of install button.
* Bumps `supabase-management-js` to version 2.0.2 and
`stripe-experiment-sync` to version 1.0.27.
* Uses `parseSchemaComment` and related logic from the
`stripe-experiment-sync` package in order to avoid writing duplicate
code in supabase ui.
* Allows installation/uninstallation to timeout after 5 minutes to avoid
these operations from getting stuck in case an error occurs in their
processing. This allows users to retry the operation, as opposed to the
older behaviour where the users always see a spinner on the
install/uninstall button and couldn't do anything.
* Remove the SSL enforcement admonition as it is no longer required.
Sync engine can now be installed with or without SSL enforcement
enabled.

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2026-03-18 08:29:03 +00:00
Francesco Sansalvadore 156f904018 feat: floating mobile toolbar (#43444)
- move navigation components to `apps/studio/components/layouts/Navigation`
- add [FloatingMobileToolbar](https://github.com/supabase/supabase/pull/43444/changes#diff-3dffe47fd51ca851d612d8728e03b2dc344ec213d4f3a46a824d3fa32a7cc851) as quick access to tools such as search, assistant, inline editor, etc - behind feature flag and feature preview (true by default as it's a bit
annoying to have to enable it all the time as previews are stored in
local-storage)
- fix sidebar panels closing on viewport resizing (regression from previous pr)

https://github.com/user-attachments/assets/d6881e3b-5128-4306-bb82-3ca39c755dba

<img width="986" height="697" alt="Screenshot 2026-03-12 at 12 40 11"
src="https://github.com/user-attachments/assets/da8511e2-7d01-4237-b814-596031c747c5"
/>
2026-03-13 12:13:07 +00:00