mirror of
https://github.com/supabase/supabase.git
synced 2026-10-05 17:35:10 +03:00
clean up
This commit is contained in:
1 parent
f479be9edb
commit
32b6915b1f
3 files changed
+4
-30
No files matched your search
@@ -6,8 +6,8 @@ import { useParams } from 'common'
|
||||
import { ENV_VAR_RAW_KEYS } from 'components/interfaces/Integrations/Integrations-Vercel.constants'
|
||||
import ProjectLinker, { ForeignProject } from 'components/interfaces/Integrations/ProjectLinker'
|
||||
import { Markdown } from 'components/interfaces/Markdown'
|
||||
import { VercelIntegrationLayout } from 'components/layouts'
|
||||
import { ScaffoldColumn, ScaffoldContainer, ScaffoldDivider } from 'components/layouts/Scaffold'
|
||||
import VercelIntegrationWindowLayout from 'components/layouts/IntegrationsLayout/VercelIntegrationWindowLayout'
|
||||
import { ScaffoldColumn, ScaffoldContainer } from 'components/layouts/Scaffold'
|
||||
import { vercelIcon } from 'components/to-be-cleaned/ListIcons'
|
||||
import { useOrgIntegrationsQuery } from 'data/integrations/integrations-query-org-only'
|
||||
import { useIntegrationsVercelConnectionSyncEnvsMutation } from 'data/integrations/integrations-vercel-connection-sync-envs-mutation'
|
||||
@@ -17,10 +17,8 @@ import { useOrganizationsQuery } from 'data/organizations/organizations-query'
|
||||
import { useProjectsQuery } from 'data/projects/projects-query'
|
||||
import { BASE_PATH, PROJECT_STATUS } from 'lib/constants'
|
||||
import { EMPTY_ARR } from 'lib/void'
|
||||
import { NextPageWithLayout, Organization } from 'types'
|
||||
import { IconBook, IconLifeBuoy, LoadingLine } from 'ui'
|
||||
import VercelIntegrationWindowLayout from 'components/layouts/IntegrationsLayout/VercelIntegrationWindowLayout'
|
||||
import { useIntegrationInstallationSnapshot } from 'state/integration-installation'
|
||||
import { NextPageWithLayout, Organization } from 'types'
|
||||
|
||||
const VERCEL_ICON = (
|
||||
<img src={`${BASE_PATH}/img/icons/vercel-icon.svg`} alt="Vercel Icon" className="w-4" />
|
||||
|
||||
@@ -39,7 +39,6 @@ const VercelIntegration: NextPageWithLayout = () => {
|
||||
const { ui } = useStore()
|
||||
const { code, configurationId, teamId, source, externalId } = useParams()
|
||||
const [selectedOrg, setSelectedOrg] = useState<Organization | null>(null)
|
||||
const [organizationIntegrationId, setOrganizationIntegrationId] = useState<string | null>(null)
|
||||
|
||||
const snapshot = useIntegrationInstallationSnapshot()
|
||||
|
||||
@@ -112,8 +111,7 @@ const VercelIntegration: NextPageWithLayout = () => {
|
||||
onMutate() {
|
||||
snapshot.setLoading(true)
|
||||
},
|
||||
onSuccess({ id }) {
|
||||
setOrganizationIntegrationId(id)
|
||||
onSuccess() {
|
||||
handleRouteChange()
|
||||
snapshot.setLoading(false)
|
||||
},
|
||||
|
||||
@@ -1,30 +1,8 @@
|
||||
import types from 'pages/api/pg-meta/[ref]/types'
|
||||
import { proxy, snapshot, useSnapshot } from 'valtio'
|
||||
|
||||
export type SidePanelTypeProps = 'VERCEL_CONNECTIONS' | 'GITHUB_CONNECTIONS'
|
||||
|
||||
// export type OpenProps =
|
||||
// | { type: 'VERCEL_CONNECTIONS'; integrationId: string }
|
||||
// | { type: 'GITHUB_CONNECTIONS'; integrationId: string }
|
||||
|
||||
export const sidePanelsState = proxy({
|
||||
// setOpen: (type: SidePanelTypeProps, integrationId: string) => {
|
||||
// sidePanelsState.integrationConnections = type
|
||||
// switch (type) {
|
||||
// case 'VERCEL_CONNECTIONS':
|
||||
// sidePanelsState.vercelConnectionsIntegrationId = integrationId
|
||||
// break
|
||||
// case 'GITHUB_CONNECTIONS':
|
||||
// sidePanelsState.githubConnectionsIntegrationId = integrationId
|
||||
// break
|
||||
// }
|
||||
// },
|
||||
// setClosed: () => {
|
||||
// sidePanelsState.integrationConnections = false
|
||||
// },
|
||||
|
||||
// integrationConnections: false as SidePanelTypeProps | false,
|
||||
|
||||
/**
|
||||
* Vercel connections
|
||||
*/
|
||||
|
||||
Reference in new issue
Block a user