mirror of
https://github.com/supabase/supabase.git
synced 2026-12-06 08:29:01 +00:00
## What kind of change does this PR introduce? New shared component + docs. ## What is the current behavior? `AdvancedConfiguration` and `InternalOnlyConfiguration` in the New Project form each contain bespoke `<Collapsible>` markup. There's no reusable collapsible section component available to other card/panel forms. ## What is the new behavior? - Extracts a shared `CollapsibleCardSection` into `packages/ui-patterns`, exported via `ui-patterns/CollapsibleCardSection` - Refactors `AdvancedConfiguration` and `InternalOnlyConfiguration` to use it - Adds design system docs with a live demo at `/docs/fragments/collapsible-card-section` This is a prereq for #45707 and #46187, which both consume this component. | Example Usage | | --- | | <img width="1464" height="500" alt="CleanShot 2026-05-22 at 15 20 38@2x" src="https://github.com/user-attachments/assets/5b88ef8d-3f9a-4454-b246-5bbaf53e027a" /> | ## To test - [ ] Check that [the Design System page](https://design-system-git-dnywh-collapsible-card-section-supabase.vercel.app/design-system/docs/fragments/collapsible-card-section) makes sense - [ ] Check that the [new project form](https://studio-staging-git-dnywh-collapsible-card-section-supabase.vercel.app/dashboard/new/) collapsible sections work as expected <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit ## Release Notes * **New Features** * Introduced CollapsibleCardSection component as a reusable UI pattern for collapsible card-based content with customizable title, description, and open state. * Refactored project configuration interfaces to use the new component for improved visual consistency. * **Documentation** * Added comprehensive documentation with interactive examples and multiple usage patterns for CollapsibleCardSection. <!-- review_stack_entry_start --> [](https://app.coderabbit.ai/change-stack/supabase/supabase/pull/46250?utm_source=github_walkthrough&utm_medium=github&utm_campaign=change_stack) <!-- review_stack_entry_end --> <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com> Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
65 lines
1.5 KiB
TypeScript
65 lines
1.5 KiB
TypeScript
import { Registry } from '@/registry/schema'
|
|
|
|
export const fragments: Registry = [
|
|
{
|
|
name: 'CollapsibleCardSection',
|
|
type: 'components:fragment',
|
|
files: ['/CollapsibleCardSection.tsx'],
|
|
optionalPath: '',
|
|
},
|
|
{
|
|
name: 'ConfirmationModal',
|
|
type: 'components:fragment',
|
|
files: ['/Dialogs/ConfirmationModal.tsx'],
|
|
optionalPath: '/Dialogs',
|
|
},
|
|
{
|
|
name: 'EmptyStatePresentational',
|
|
type: 'components:fragment',
|
|
files: ['/EmptyStatePresentational/index.tsx'],
|
|
optionalPath: '/EmptyStatePresentational',
|
|
},
|
|
{
|
|
name: 'TextConfirmModal',
|
|
type: 'components:fragment',
|
|
files: ['/Dialogs/TextConfirmModal.tsx'],
|
|
optionalPath: '/Dialogs',
|
|
},
|
|
{
|
|
name: 'PageContainer',
|
|
type: 'components:fragment',
|
|
files: ['/PageContainer/index.tsx'],
|
|
optionalPath: '/PageContainer',
|
|
},
|
|
{
|
|
name: 'PageHeader',
|
|
type: 'components:fragment',
|
|
files: ['/PageHeader/index.tsx'],
|
|
optionalPath: '/PageHeader',
|
|
},
|
|
{
|
|
name: 'PageBreadcrumbs',
|
|
type: 'components:fragment',
|
|
files: ['/PageBreadcrumbs/index.tsx'],
|
|
optionalPath: '/PageBreadcrumbs',
|
|
},
|
|
{
|
|
name: 'PageNav',
|
|
type: 'components:fragment',
|
|
files: ['/PageNav/index.tsx'],
|
|
optionalPath: '/PageNav',
|
|
},
|
|
{
|
|
name: 'PageSection',
|
|
type: 'components:fragment',
|
|
files: ['/PageSection/index.tsx'],
|
|
optionalPath: '/PageSection',
|
|
},
|
|
{
|
|
name: 'StatusCode',
|
|
type: 'components:fragment',
|
|
files: ['/StatusCode/index.tsx'],
|
|
optionalPath: '/StatusCode',
|
|
},
|
|
]
|