The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
Bring changes from master and reesolve conflicts
Joshen Lim15de9ff68f20
diff --cc studio/components/interfaces/Settings/General/CustomDomainConfig/CustomDomainsConfigureHostname.tsxindex f15ec11768c,e128f37290d..45d294679bf--- a/studio/components/interfaces/Settings/General/CustomDomainConfig/CustomDomainsConfigureHostname.tsx+++ b/studio/components/interfaces/Settings/General/CustomDomainConfig/CustomDomainsConfigureHostname.tsx@@@ -1,10 -1,11 +1,11 @@@-import Link from 'next/link'-import * as yup from 'yup'+import { PermissionAction } from '@supabase/shared-types/out/constants'+import { useParams } from 'common'import { observer } from 'mobx-react-lite'+import Link from 'next/link'import { Button, Form, IconExternalLink, Input } from 'ui'-import { PermissionAction } from '@supabase/shared-types/out/constants'+import * as yup from 'yup'-import { useCheckPermissions, useStore } from 'hooks'-import { useParams } from 'common/hooks'++import { useProjectContext } from 'components/layouts/ProjectLayout/ProjectContext'import {FormActions,FormPanel,@@@ -24,13 -24,27 +25,19 @@@ const schema = yup.object(const CustomDomainsConfigureHostname = () => {const { ui } = useStore()const { ref } = useParams()++ const { project } = useProjectContext()++const { mutate: createCustomDomain, isLoading: isCreating } = useCustomDomainCreateMutation()const { data: settings } = useProjectApiQuery({ projectRef: ref })- const { project } = useProjectContext()const FORM_ID = 'custom-domains-form'const endpoint = settings?.autoApiService.endpoint- const canConfigureCustomDomain = useCheckPermissions(PermissionAction.UPDATE, 'projects')+ const canConfigureCustomDomain = useCheckPermissions(PermissionAction.UPDATE, 'projects', {+ resource: {+ project_id: project?.id,+ },+ })- const verifyCNAME = async (domain: string): Promise<boolean> => {- const res = await fetch(`https://1.1.1.1/dns-query?name=${domain}`, {- method: 'GET',- headers: { accept: 'application/dns-json' },- })- const verification = await res.json()- return verification.Status === 0- }-const onCreateCustomDomain = async (values: yup.InferType<typeof schema>) => {if (!ref) return console.error('Project ref is required')