Site Yönetimi,Kullanıcı Girişi,Karanlık mod özellikleri db bağlantıları.

This commit is contained in:
2026-01-08 23:56:28 +03:00
parent 6e02336827
commit ddf28e1892
40 changed files with 2545 additions and 96 deletions

8
lib/site-settings.ts Normal file
View File

@@ -0,0 +1,8 @@
import { createClient } from "@/lib/supabase-server"
import { cache } from "react"
export const getSiteSettings = cache(async () => {
const supabase = createClient()
const { data } = await supabase.from('site_settings').select('*').single()
return data
})

8
lib/supabase-browser.ts Normal file
View File

@@ -0,0 +1,8 @@
import { createBrowserClient } from '@supabase/ssr'
export function createClient() {
return createBrowserClient(
process.env.NEXT_PUBLIC_SUPABASE_URL!,
process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!
)
}