feat: phone login, position badge, logout in profile, global search, admin chats

- Login: by phone number instead of username
- Position field: shown as badge next to name in members list, search, admin panel
- Logout: moved from sidebar to profile modal settings
- Sidebar search: global — shows matching users with one-click private chat
- Admin panel: new Чаты tab showing all chats with delete, position/phone in user form
- Backend: /api/admin/chats endpoint, position column migration, phone login support

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Ai
2026-05-22 12:17:46 +03:00
parent 8993a9f6ce
commit 8e5c4cd67d
11 changed files with 215 additions and 62 deletions

View File

@@ -6,6 +6,7 @@ export interface User {
avatar?: string | null;
bio?: string;
phone?: string;
position?: string | null;
isAdmin: boolean;
lastSeen?: string;
online?: boolean;
@@ -17,6 +18,7 @@ export interface ChatMember {
displayName: string;
avatarColor: string;
avatar?: string | null;
position?: string | null;
role: 'owner' | 'admin' | 'member';
online: boolean;
lastSeen: string;