Spaces:
Running
Running
axeronis commited on
Commit ·
8bf69ca
1
Parent(s): 9a5b4ec
fix: mobile chat sticky header, drawer back btn, hide Enter hint, appointments modal pb-20
Browse files
frontend/app/appointments/page.tsx
CHANGED
|
@@ -115,11 +115,14 @@ export default function AppointmentsPage() {
|
|
| 115 |
className="absolute bottom-0 left-0 right-0 max-h-[80vh] overflow-y-auto rounded-t-3xl"
|
| 116 |
onClick={(e) => e.stopPropagation()}
|
| 117 |
>
|
| 118 |
-
{/* Close handle */}
|
| 119 |
-
<div className="sticky top-0 bg-[#1E1F2E] pt-3 pb-2 flex
|
| 120 |
-
<
|
|
|
|
|
|
|
|
|
|
| 121 |
</div>
|
| 122 |
-
<div className="bg-[#1E1F2E] pb-
|
| 123 |
<AppointmentDetails
|
| 124 |
appointment={selectedAppointment}
|
| 125 |
onClose={handleCloseDetails}
|
|
|
|
| 115 |
className="absolute bottom-0 left-0 right-0 max-h-[80vh] overflow-y-auto rounded-t-3xl"
|
| 116 |
onClick={(e) => e.stopPropagation()}
|
| 117 |
>
|
| 118 |
+
{/* Close handle + Back button */}
|
| 119 |
+
<div className="sticky top-0 bg-[#1E1F2E] pt-3 pb-2 px-4 flex items-center gap-3 z-10 border-b border-white/5">
|
| 120 |
+
<button onClick={handleCloseDetails} className="p-2 hover:bg-white/10 rounded-lg">
|
| 121 |
+
<X className="w-5 h-5 text-slate-400" />
|
| 122 |
+
</button>
|
| 123 |
+
<span className="font-semibold text-white">Детали записи</span>
|
| 124 |
</div>
|
| 125 |
+
<div className="bg-[#1E1F2E] pb-20">
|
| 126 |
<AppointmentDetails
|
| 127 |
appointment={selectedAppointment}
|
| 128 |
onClose={handleCloseDetails}
|
frontend/components/ChatWindow.tsx
CHANGED
|
@@ -2,7 +2,7 @@
|
|
| 2 |
|
| 3 |
import { useState, useRef, useEffect } from 'react'
|
| 4 |
import { Message, Lead, leadsApi } from '@/lib/api'
|
| 5 |
-
import { Bot, Loader2, X } from 'lucide-react'
|
| 6 |
import { AnimatePresence } from 'framer-motion'
|
| 7 |
|
| 8 |
import { ClientCard } from './ClientCard'
|
|
@@ -311,11 +311,11 @@ export function ChatWindow({
|
|
| 311 |
<div className="fixed inset-0 z-50 md:hidden">
|
| 312 |
<div className="absolute inset-0 bg-black/60 backdrop-blur-sm" onClick={() => setIsMobileDrawerOpen(false)} />
|
| 313 |
<div className="absolute right-0 top-0 bottom-0 w-[85%] bg-surface-elevated shadow-2xl animate-in slide-in-from-right duration-300">
|
| 314 |
-
<div className="p-
|
| 315 |
-
<
|
| 316 |
-
|
| 317 |
-
<X className="w-5 h-5 text-slate-400" />
|
| 318 |
</button>
|
|
|
|
| 319 |
</div>
|
| 320 |
<div className="h-full overflow-y-auto pb-20">
|
| 321 |
{lead && (
|
|
|
|
| 2 |
|
| 3 |
import { useState, useRef, useEffect } from 'react'
|
| 4 |
import { Message, Lead, leadsApi } from '@/lib/api'
|
| 5 |
+
import { Bot, Loader2, X, ArrowLeft } from 'lucide-react'
|
| 6 |
import { AnimatePresence } from 'framer-motion'
|
| 7 |
|
| 8 |
import { ClientCard } from './ClientCard'
|
|
|
|
| 311 |
<div className="fixed inset-0 z-50 md:hidden">
|
| 312 |
<div className="absolute inset-0 bg-black/60 backdrop-blur-sm" onClick={() => setIsMobileDrawerOpen(false)} />
|
| 313 |
<div className="absolute right-0 top-0 bottom-0 w-[85%] bg-surface-elevated shadow-2xl animate-in slide-in-from-right duration-300">
|
| 314 |
+
<div className="p-3 border-b border-white/10 flex items-center gap-3">
|
| 315 |
+
<button onClick={() => setIsMobileDrawerOpen(false)} className="p-2 hover:bg-white/10 rounded-lg">
|
| 316 |
+
<ArrowLeft className="w-5 h-5 text-slate-400" />
|
|
|
|
| 317 |
</button>
|
| 318 |
+
<h3 className="font-bold text-white">Инфо о лиде</h3>
|
| 319 |
</div>
|
| 320 |
<div className="h-full overflow-y-auto pb-20">
|
| 321 |
{lead && (
|
frontend/components/ChatWindow/ChatHeader.tsx
CHANGED
|
@@ -30,7 +30,7 @@ export function ChatHeader({
|
|
| 30 |
onOpenBookingModal,
|
| 31 |
}: ChatHeaderProps) {
|
| 32 |
return (
|
| 33 |
-
<div className="bg-surface-elevated border-b border-white/10 px-6 py-3 flex items-center justify-between z-
|
| 34 |
<div className="flex items-center gap-4">
|
| 35 |
{/* Desktop Toggle */}
|
| 36 |
<button
|
|
|
|
| 30 |
onOpenBookingModal,
|
| 31 |
}: ChatHeaderProps) {
|
| 32 |
return (
|
| 33 |
+
<div className="bg-surface-elevated border-b border-white/10 px-4 md:px-6 py-3 flex items-center justify-between z-20 flex-shrink-0 sticky top-0">
|
| 34 |
<div className="flex items-center gap-4">
|
| 35 |
{/* Desktop Toggle */}
|
| 36 |
<button
|
frontend/components/ChatWindow/MessageInput.tsx
CHANGED
|
@@ -176,7 +176,7 @@ export function MessageInput({
|
|
| 176 |
)}
|
| 177 |
</button>
|
| 178 |
</form>
|
| 179 |
-
<div className="text-center mt-2">
|
| 180 |
<p className="text-[10px] text-slate-400 font-medium">
|
| 181 |
Enter для отправки • Shift + Enter для переноса
|
| 182 |
</p>
|
|
|
|
| 176 |
)}
|
| 177 |
</button>
|
| 178 |
</form>
|
| 179 |
+
<div className="hidden md:block text-center mt-2">
|
| 180 |
<p className="text-[10px] text-slate-400 font-medium">
|
| 181 |
Enter для отправки • Shift + Enter для переноса
|
| 182 |
</p>
|