Supabase integration experiment setting (off by default)

This commit is contained in:
Will Chen
2025-04-22 17:12:51 -07:00
parent 2a08f72378
commit bf70c1bb00
6 changed files with 108 additions and 12 deletions

View File

@@ -29,6 +29,7 @@ import {
} from "@/components/ui/dialog";
import { GitHubConnector } from "@/components/GitHubConnector";
import { SupabaseConnector } from "@/components/SupabaseConnector";
import { useSettings } from "@/hooks/useSettings";
export default function AppDetailsPage() {
const navigate = useNavigate();
@@ -48,7 +49,7 @@ export default function AppDetailsPage() {
const [newFolderName, setNewFolderName] = useState("");
const [isRenamingFolder, setIsRenamingFolder] = useState(false);
const appBasePath = useAtomValue(appBasePathAtom);
const { settings } = useSettings();
// Get the appId from search params and find the corresponding app
const appId = search.appId ? Number(search.appId) : null;
const selectedApp = appId ? appsList.find((app) => app.id === appId) : null;
@@ -241,7 +242,9 @@ export default function AppDetailsPage() {
<MessageCircle className="h-5 w-5" />
</Button>
<GitHubConnector appId={appId} folderName={selectedApp.path} />
{appId && <SupabaseConnector appId={appId} />}
{appId && settings?.experiments?.enableSupabaseIntegration && (
<SupabaseConnector appId={appId} />
)}
</div>
{/* Rename Dialog */}