Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

fix: Remove always-open Accordion behavior (#47638)

Jeremias Menichelli689b6991f064
diff --git a/apps/docs/app/contributing/content.mdx b/apps/docs/app/contributing/content.mdx
index be59011c43b..12d02b26a59 100644
--- a/apps/docs/app/contributing/content.mdx
+++ b/apps/docs/app/contributing/content.mdx
@@ -20,7 +20,6 @@ For content that requires progressive disclosure:
```mdx
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
@@ -49,7 +48,6 @@ For content that requires progressive disclosure:
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
@@ -501,7 +499,6 @@ We incorporate content reuse in the docs to avoid duplication. If you find yours
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/_partials/metrics_access.mdx b/apps/docs/content/_partials/metrics_access.mdx
index 2aa32d58aee..94a3389207c 100644
--- a/apps/docs/content/_partials/metrics_access.mdx
+++ b/apps/docs/content/_partials/metrics_access.mdx
@@ -1,6 +1,5 @@
<Accordion
type="default"
-openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/_partials/quickstart_db_setup.mdx b/apps/docs/content/_partials/quickstart_db_setup.mdx
index 399ba639086..49dc1e2431a 100644
--- a/apps/docs/content/_partials/quickstart_db_setup.mdx
+++ b/apps/docs/content/_partials/quickstart_db_setup.mdx
@@ -94,7 +94,6 @@ You can click this button to prefill all the SQL needed in [the SQL editor of yo
<Accordion
type="default"
- openBehaviour="single"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/guides/auth/auth-mfa.mdx b/apps/docs/content/guides/auth/auth-mfa.mdx
index 0c55ea6265e..8b68ced9293 100644
--- a/apps/docs/content/guides/auth/auth-mfa.mdx
+++ b/apps/docs/content/guides/auth/auth-mfa.mdx
@@ -300,7 +300,6 @@ If your application uses the Supabase Database, Storage or Edge Functions, Row L
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/guides/cron/quickstart.mdx b/apps/docs/content/guides/cron/quickstart.mdx
index 38cb3cd7cd6..6c6b369c8e3 100644
--- a/apps/docs/content/guides/cron/quickstart.mdx
+++ b/apps/docs/content/guides/cron/quickstart.mdx
@@ -40,7 +40,6 @@ select cron.schedule('permanent-cron-job-name', '30 seconds', 'CALL do_something
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/guides/platform/backups.mdx b/apps/docs/content/guides/platform/backups.mdx
index 620117f4e2c..9be4bdb6459 100644
--- a/apps/docs/content/guides/platform/backups.mdx
+++ b/apps/docs/content/guides/platform/backups.mdx
@@ -91,7 +91,6 @@ Projects that want to use PITR must also use at least a Small compute add-on to
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/guides/platform/migrating-to-supabase/auth0.mdx b/apps/docs/content/guides/platform/migrating-to-supabase/auth0.mdx
index c8f9825d7ef..82f8d91462b 100644
--- a/apps/docs/content/guides/platform/migrating-to-supabase/auth0.mdx
+++ b/apps/docs/content/guides/platform/migrating-to-supabase/auth0.mdx
@@ -198,7 +198,6 @@ create table private.user_metadata (
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/guides/platform/migrating-within-supabase/backup-restore.mdx b/apps/docs/content/guides/platform/migrating-within-supabase/backup-restore.mdx
index 744d61ee7c5..cd989bbccc6 100644
--- a/apps/docs/content/guides/platform/migrating-within-supabase/backup-restore.mdx
+++ b/apps/docs/content/guides/platform/migrating-within-supabase/backup-restore.mdx
@@ -78,7 +78,6 @@ breadcrumb: 'Migrations'
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/guides/platform/migrating-within-supabase/dashboard-restore.mdx b/apps/docs/content/guides/platform/migrating-within-supabase/dashboard-restore.mdx
index f403e599b68..0da67357ab3 100644
--- a/apps/docs/content/guides/platform/migrating-within-supabase/dashboard-restore.mdx
+++ b/apps/docs/content/guides/platform/migrating-within-supabase/dashboard-restore.mdx
@@ -14,7 +14,6 @@ Dashboard backups are only available for older projects that still use logical b
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/guides/platform/read-replicas.mdx b/apps/docs/content/guides/platform/read-replicas.mdx
index c70ecea0044..b709c7281d9 100644
--- a/apps/docs/content/guides/platform/read-replicas.mdx
+++ b/apps/docs/content/guides/platform/read-replicas.mdx
@@ -32,7 +32,6 @@ You can only read data from a Read Replica. This is in contrast to a Primary dat
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="large"
diff --git a/apps/docs/content/guides/telemetry/log-drains.mdx b/apps/docs/content/guides/telemetry/log-drains.mdx
index 8ed1b50dabc..f1f5f8d54e7 100644
--- a/apps/docs/content/guides/telemetry/log-drains.mdx
+++ b/apps/docs/content/guides/telemetry/log-drains.mdx
@@ -38,7 +38,6 @@ Unsigned requests to HTTP endpoints are temporary and all requests will signed i
<Accordion
type="default"
- openBehaviour="multiple"
>
<AccordionItem
header="Edge Function Walkthrough (Uncompressed)"
@@ -148,7 +147,6 @@ To setup Datadog log drain, generate a Datadog API key [here](https://app.datado
<Accordion
type="default"
- openBehaviour="multiple"
>
<AccordionItem
header="Walkthrough"
@@ -280,7 +278,6 @@ Ensure your OTLP endpoint is configured to accept logs at the `/v1/logs` path wi
<Accordion
type="default"
- openBehaviour="multiple"
>
<AccordionItem
header="OpenTelemetry Collector Example"
diff --git a/apps/docs/content/troubleshooting/cant-access-supabase-project-lovable-cloud.mdx b/apps/docs/content/troubleshooting/cant-access-supabase-project-lovable-cloud.mdx
index b090af0c2ab..1fc223b9c90 100644
--- a/apps/docs/content/troubleshooting/cant-access-supabase-project-lovable-cloud.mdx
+++ b/apps/docs/content/troubleshooting/cant-access-supabase-project-lovable-cloud.mdx
@@ -54,7 +54,6 @@ For more information, read [the Lovable Cloud FAQ](https://docs.lovable.dev/feat
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/troubleshooting/edge-function-401-error-response.mdx b/apps/docs/content/troubleshooting/edge-function-401-error-response.mdx
index b6e3ffc3eee..3a074478749 100644
--- a/apps/docs/content/troubleshooting/edge-function-401-error-response.mdx
+++ b/apps/docs/content/troubleshooting/edge-function-401-error-response.mdx
@@ -137,7 +137,6 @@ Your project uses the [new asymmetric keys](/blog/jwt-signing-keys) for authenti
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/troubleshooting/edge-function-546-error-response.mdx b/apps/docs/content/troubleshooting/edge-function-546-error-response.mdx
index 9f4b12e25d0..942e4c6e31f 100644
--- a/apps/docs/content/troubleshooting/edge-function-546-error-response.mdx
+++ b/apps/docs/content/troubleshooting/edge-function-546-error-response.mdx
@@ -135,7 +135,6 @@ There are a few other queries that may be useful for identifying patterns around
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/troubleshooting/identify-lovable-cloud-or-supabase-backend.mdx b/apps/docs/content/troubleshooting/identify-lovable-cloud-or-supabase-backend.mdx
index ad7d7d68cc0..084a2bdf19a 100644
--- a/apps/docs/content/troubleshooting/identify-lovable-cloud-or-supabase-backend.mdx
+++ b/apps/docs/content/troubleshooting/identify-lovable-cloud-or-supabase-backend.mdx
@@ -54,7 +54,6 @@ If the page displays the Supabase icon, your Supabase project name, and some lin
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
@@ -95,7 +94,6 @@ If the page displays the Supabase icon, your Supabase project name, and some lin
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/content/troubleshooting/restore-project-after-90-days-pause.mdx b/apps/docs/content/troubleshooting/restore-project-after-90-days-pause.mdx
index 3c91adbfe70..6e7a7b47a8e 100644
--- a/apps/docs/content/troubleshooting/restore-project-after-90-days-pause.mdx
+++ b/apps/docs/content/troubleshooting/restore-project-after-90-days-pause.mdx
@@ -75,7 +75,6 @@ chmod +x sync_supabase_config.sh
<Accordion
type="default"
- openBehaviour="multiple"
chevronAlign="right"
justified
size="medium"
diff --git a/apps/docs/features/ui/Accordion.tsx b/apps/docs/features/ui/Accordion.tsx
index 05e39f7616c..2efc6ed9bd4 100644
--- a/apps/docs/features/ui/Accordion.tsx
+++ b/apps/docs/features/ui/Accordion.tsx
@@ -1,6 +1,6 @@
'use client'
-import React, { ComponentProps, useState } from 'react'
+import React, { useState } from 'react'
import {
AccordionContent,
AccordionTrigger,
@@ -12,16 +12,13 @@ import {
type Type = 'default' | 'bordered'
type Align = 'left' | 'right'
-type BaseAccordionProps = ComponentProps<typeof Accordion>
-
export interface AccordionProps {
children?: React.ReactNode
className?: string
defaultActiveId?: (string | number)[]
onChange?: (item: string | string[]) => void
- openBehaviour: 'single' | 'multiple'
type?: Type
- defaultValue?: string | string[] | undefined
+ defaultValue?: string[] | undefined
justified?: Boolean
chevronAlign?: Align
}
@@ -30,17 +27,15 @@ export function Accordion({
children,
className,
onChange,
- openBehaviour = 'multiple',
defaultValue = undefined,
// All props below are ignored but kept to avoid impacting all docs pages
- type = 'default',
- justified = false,
- chevronAlign = 'right',
+ // type = 'default',
+ // justified = false,
+ // chevronAlign = 'right',
}: AccordionProps) {
return (
- // @ts-expect-error: This is because the Radix component has 2 interfaces discriminated by its type prop. Safe to ignore
<BaseAccordion
- type={openBehaviour}
+ type="multiple"
onValueChange={onChange}
defaultValue={defaultValue}
className={className}