feat(ust-cubuk): telefonda Ara üst çubukta sabit; menü hapları WAAPI ile (→ 2.0.3)

- Arama menüden çıktı, lg altında sıralama hapının yanında koyu "Ara" hapı
- 432 px altında yazı logosu kesilmek yerine gizlenir (mark + Beta kalır)
- Menü haplarının pop'u scale kısaltması yerine transform dizgisi: ana iş
  parçacığından bağımsız koşar
- Kullanılmayan ARAMA_AC_OLAYI kaldırıldı; DESIGN.md §4.36 güncellendi

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
bilalgursen
2026-10-12 07:15:52 +03:00
parent 56acce54fb
commit cde96a45de
5 changed files with 32 additions and 44 deletions

View File

@@ -1,7 +1,7 @@
"use client";
// Telefon menüsü (DESIGN.md §4.36): üst çubuk tek satır kalsın diye sıralama
// dışındaki her şey bu baloncuğun içinde. Açılınca tam ekran perde gelir,
// ve arama dışındaki her şey bu baloncuğun içinde. Açılınca tam ekran perde gelir,
// iri haplar sırayla "pop" eder; kapanış hızlı ve sekmesiz.
//
// Esin: React Bits "Bubble Menu" (reactbits.dev, MIT + Commons Clause). Kod
@@ -22,7 +22,6 @@ import {
Coins,
GraduationCap,
ListChecks,
Search,
type LucideIcon,
} from "lucide-react";
import { AnimasyonluMark } from "@/components/animasyonlu-mark";
@@ -37,9 +36,6 @@ import { preloadListeCekmecesi } from "@/features/liste/components/liste-cekmece
import { EGRI, SURE, YAY } from "@/lib/hareket";
import { cn } from "@/lib/utils";
/** Arama penceresini açtıran olay; `katalog-arama.tsx` dinler. */
export const ARAMA_AC_OLAYI = "kt-arama-ac";
const HAP_ADIMI = 0.035;
const GEZINME: { href: string; etiket: string; ikon: LucideIcon }[] = [
@@ -88,15 +84,17 @@ export function MobilMenu({
exit: { opacity: 0, transition: { duration: SURE.anlik } },
}
: {
initial: { opacity: 0, scale: 0.6 },
// `scale` kısaltması değil tam `transform` dizgisi: Motion bunu
// WAAPI'ye verir, pencere kurulurken / sayfa değişirken takılmaz.
initial: { opacity: 0, transform: "scale(0.6)" },
animate: {
opacity: 1,
scale: 1,
transform: "scale(1)",
transition: { ...YAY.birakma, delay: 0.06 + i * HAP_ADIMI },
},
exit: {
opacity: 0,
scale: 0.92,
transform: "scale(0.92)",
transition: { duration: SURE.cikis, ease: EGRI.standart },
},
};
@@ -179,23 +177,6 @@ export function MobilMenu({
className="mx-auto flex min-h-full max-w-md flex-col gap-3 px-4 pb-10"
style={{ paddingTop: ust + 72 }}
>
<motion.div {...hap(sira++)}>
<button
type="button"
className={IRI_HAP}
onClick={() => {
setAcik(false);
window.dispatchEvent(new Event(ARAMA_AC_OLAYI));
}}
>
<Search className="size-5 shrink-0 text-primary" aria-hidden />
Ara
<span className="ml-auto text-sm font-medium font-sans text-slate-500">
bölüm, üniversite, rehber
</span>
</button>
</motion.div>
<motion.div {...hap(sira++)}>
<button
type="button"