feat(core): update

This commit is contained in:
2026-06-21 20:20:20 +03:30
parent 4d995a61af
commit 58b027813d
15 changed files with 232 additions and 113 deletions

View File

@@ -1,4 +1,5 @@
import Crown from '@/components/Crown'
import { getPublicContent } from '@/lib/content'
export function RMGPSVG (){
return (
@@ -21,19 +22,8 @@ export function RMGPSVG (){
)
}
async function getData(id) {
const res = await fetch(`${process.env.NEXT_PUBLIC_API_BASE_URL}/api/public/content/index/${id}`)
if (!res.ok) {
throw new Error('Failed to fetch data')
}
return res.json()
}
export default async function Footer({ lang }){
const data = await getData(lang === 'fa' ? 1 : 2);
const data = await getPublicContent(lang);
// Add safety checks for data structure
if (!data || typeof data !== 'object') {