Fix pixel persistence, improve mobile

This commit is contained in:
martin 2025-08-22 20:14:48 +02:00
commit e1107ccfd4
14 changed files with 172 additions and 82 deletions

View file

@ -44,15 +44,16 @@ export function UsernameModal({
/>
{/* Modal */}
<motion.div
className="fixed top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2 z-50"
initial={{ opacity: 0, scale: 0.7, y: 30 }}
animate={{ opacity: 1, scale: 1, y: 0 }}
exit={{ opacity: 0, scale: 0.7, y: 30 }}
transition={{ type: "spring", stiffness: 300, damping: 25 }}
>
<form onSubmit={handleSubmit}>
<div className="bg-white/5 backdrop-blur-2xl rounded-2xl sm:rounded-3xl p-4 sm:p-6 lg:p-8 border border-white/20 w-[95vw] max-w-[320px] sm:max-w-[350px] shadow-2xl ring-1 ring-white/10">
<div className="fixed inset-0 z-50 flex items-center justify-center p-4 sm:p-6">
<motion.div
className="w-full max-w-[320px] sm:max-w-[350px]"
initial={{ opacity: 0, scale: 0.7, y: 30 }}
animate={{ opacity: 1, scale: 1, y: 0 }}
exit={{ opacity: 0, scale: 0.7, y: 30 }}
transition={{ type: "spring", stiffness: 300, damping: 25 }}
>
<form onSubmit={handleSubmit}>
<div className="bg-white/5 backdrop-blur-2xl rounded-2xl sm:rounded-3xl p-4 sm:p-6 lg:p-8 border border-white/20 shadow-2xl ring-1 ring-white/10 mx-auto">
<div className="text-center">
<motion.h3
className="text-white text-lg sm:text-xl font-bold mb-2"
@ -118,9 +119,10 @@ export function UsernameModal({
</motion.button>
</motion.div>
</div>
</div>
</form>
</motion.div>
</div>
</form>
</motion.div>
</div>
</>
)}
</AnimatePresence>