fix: update callback handling and user profile management in list components
All checks were successful
Deploy / deploy (push) Successful in 7m23s

Enhanced the handling of user profiles and callback URLs in various components. Updated the `GirisKarti` to support multiple callback scenarios, ensuring seamless user experience. Improved the `ListeUretici` and `ListemIcerik` components to manage profile data more effectively, including handling cases where the profile is stored in cookies. Additionally, refined the logic for redirecting users based on their profile status, ensuring they are directed to the appropriate pages without losing context. Updated the database file to reflect these changes.
This commit is contained in:
bilalgursen
2026-08-09 04:15:53 +03:00
parent 696dc69763
commit 437e2bc96a
13 changed files with 603 additions and 70 deletions

View File

@@ -0,0 +1,31 @@
"use client";
// Liste üretiminin bekleme metinleri tek kaynakta: ilk kurulum (ListeUretici)
// ve tercih değişikliği sonrası yeniden kurulum (TercihDegistiUyarisi) aynı
// dili ve ritmi paylaşsın diye.
import { useEffect, useState } from "react";
export const URETIM_MESAJLARI = [
"Sıralamana uygun programlar taranıyor…",
"Gerçek YÖK Atlas verisiyle dengeli liste kuruluyor…",
"Her tercih için risk ve trend analizi yazılıyor…",
"Son rötuşlar yapılıyor, neredeyse hazır…",
] as const;
const ARALIK_MS = 7000;
/** Sırayla ilerleyen, sonuncuda duran bekleme metni. Yalnızca üretim
* sürerken monte edilir — sayaç mount ile başlar. */
export function useUretimMesaji(): string {
const [idx, setIdx] = useState(0);
useEffect(() => {
const zamanlayici = setInterval(() => {
setIdx((i) => Math.min(i + 1, URETIM_MESAJLARI.length - 1));
}, ARALIK_MS);
return () => clearInterval(zamanlayici);
}, []);
return URETIM_MESAJLARI[idx];
}