Минимальная адаптация под мобилку
This commit is contained in:
@@ -900,13 +900,13 @@ export default function ChatView({ onStartCall, onStartGroupCall }: { onStartCal
|
||||
openSearch();
|
||||
}
|
||||
}}
|
||||
className="p-2 rounded-xl hover:bg-surface-container-highest/40 transition-all duration-300 text-on-surface-variant hover:text-primary slide-on-ice"
|
||||
className="hidden lg:flex p-2 rounded-xl hover:bg-surface-container-highest/40 transition-all duration-300 text-on-surface-variant hover:text-primary slide-on-ice"
|
||||
>
|
||||
{showSearch ? <span className="material-symbols-outlined">close</span> : <span className="material-symbols-outlined">search</span>}
|
||||
</button>
|
||||
|
||||
{!isFavorites && config?.webRtc?.enabled && (
|
||||
<>
|
||||
<div className="hidden lg:flex items-center gap-1.5">
|
||||
<button
|
||||
onClick={() => {
|
||||
if (chat.type === 'personal' && otherMember) {
|
||||
@@ -931,7 +931,7 @@ export default function ChatView({ onStartCall, onStartGroupCall }: { onStartCal
|
||||
<span className="material-symbols-outlined">videocam</span>
|
||||
</button>
|
||||
)}
|
||||
</>
|
||||
</div>
|
||||
)}
|
||||
|
||||
<div className="relative" ref={topMenuRef}>
|
||||
@@ -957,6 +957,40 @@ export default function ChatView({ onStartCall, onStartGroupCall }: { onStartCal
|
||||
<Search size={16} />
|
||||
{t('searchMessages')}
|
||||
</button>
|
||||
{!isFavorites && config?.webRtc?.enabled && (
|
||||
<>
|
||||
<button
|
||||
onClick={() => {
|
||||
setShowTopMenu(false);
|
||||
if (chat.type === 'personal' && otherMember) {
|
||||
onStartCall?.(otherMember.user, 'voice');
|
||||
} else if (chat.type === 'group') {
|
||||
onStartGroupCall?.(chat.id, chat.name || 'Group', 'voice');
|
||||
}
|
||||
}}
|
||||
className="lg:hidden flex items-center gap-3 w-full px-4 py-2.5 text-sm text-zinc-300 hover:bg-surface-hover hover:text-white transition-colors"
|
||||
>
|
||||
<Phone size={16} />
|
||||
{t('call')}
|
||||
</button>
|
||||
{config?.webRtc?.enableVideoCalls && (
|
||||
<button
|
||||
onClick={() => {
|
||||
setShowTopMenu(false);
|
||||
if (chat.type === 'personal' && otherMember) {
|
||||
onStartCall?.(otherMember.user, 'video');
|
||||
} else if (chat.type === 'group') {
|
||||
onStartGroupCall?.(chat.id, chat.name || 'Group', 'video');
|
||||
}
|
||||
}}
|
||||
className="lg:hidden flex items-center gap-3 w-full px-4 py-2.5 text-sm text-zinc-300 hover:bg-surface-hover hover:text-white transition-colors"
|
||||
>
|
||||
<Video size={16} />
|
||||
{t('videoCall')}
|
||||
</button>
|
||||
)}
|
||||
</>
|
||||
)}
|
||||
{!isFavorites && chat.type === 'personal' && otherMember && (
|
||||
<button
|
||||
onClick={() => {
|
||||
@@ -1337,7 +1371,7 @@ export default function ChatView({ onStartCall, onStartGroupCall }: { onStartCal
|
||||
</AnimatePresence>
|
||||
</div>
|
||||
|
||||
<footer className="flex-shrink-0 bg-surface-container-lowest/40 backdrop-blur-xl border-t border-white/5 pb-safe relative z-50">
|
||||
<footer className="flex-shrink-0 bg-surface-container-lowest/40 backdrop-blur-xl border-t border-white/5 safe-area-bottom relative z-50">
|
||||
<MessageInput chatId={activeChat} />
|
||||
</footer>
|
||||
</>
|
||||
|
||||
Reference in New Issue
Block a user