modula-ui 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +36 -0
- package/bin/run.js +86 -0
- package/package.json +71 -0
- package/public/avatars/avatar1.png +0 -0
- package/public/avatars/avatar2.png +0 -0
- package/public/avatars/avatar3.png +0 -0
- package/public/avatars/avatar4.png +0 -0
- package/public/avatars/sources.md +34 -0
- package/public/file.svg +1 -0
- package/public/globe.svg +1 -0
- package/public/next.svg +1 -0
- package/public/vercel.svg +1 -0
- package/public/window.svg +1 -0
- package/registry.json +12 -0
- package/src/app/favicon.ico +0 -0
- package/src/app/globals.css +126 -0
- package/src/app/layout.js +29 -0
- package/src/app/page.js +50 -0
- package/src/app/patterns/page.js +50 -0
- package/src/components/CodeCard.jsx +16 -0
- package/src/components/CopyButton.jsx +31 -0
- package/src/components/Header.jsx +24 -0
- package/src/components/Logo.jsx +64 -0
- package/src/components/MobileOverlay.jsx +10 -0
- package/src/components/PreviewCard.jsx +98 -0
- package/src/components/Sidebar.jsx +47 -0
- package/src/components/ui/avatar.jsx +47 -0
- package/src/components/ui/badge.jsx +44 -0
- package/src/components/ui/button.jsx +56 -0
- package/src/components/ui/calendar.jsx +178 -0
- package/src/components/ui/card.jsx +101 -0
- package/src/components/ui/chart.jsx +314 -0
- package/src/components/ui/checkbox.jsx +30 -0
- package/src/components/ui/dropdown-menu.jsx +223 -0
- package/src/components/ui/input.jsx +24 -0
- package/src/components/ui/navigation-menu.jsx +152 -0
- package/src/components/ui/popover.jsx +47 -0
- package/src/components/ui/progress.jsx +29 -0
- package/src/components/ui/scroll-area.jsx +51 -0
- package/src/components/ui/select.jsx +168 -0
- package/src/components/ui/separator.jsx +27 -0
- package/src/components/ui/sheet.jsx +140 -0
- package/src/components/ui/sidebar.jsx +682 -0
- package/src/components/ui/skeleton.jsx +15 -0
- package/src/components/ui/slider.jsx +56 -0
- package/src/components/ui/tooltip.jsx +55 -0
- package/src/data/componentData.js +12 -0
- package/src/hooks/use-mobile.js +19 -0
- package/src/lib/utils.js +6 -0
- package/src/library/components/Alert.jsx +27 -0
- package/src/library/components/Badge.jsx +19 -0
- package/src/library/components/Button.jsx +31 -0
- package/src/library/components/Card.jsx +25 -0
- package/src/library/components/Input.jsx +35 -0
- package/src/library/components/Modal.jsx +26 -0
- package/src/library/components/Textarea.jsx +15 -0
- package/src/library/components/Toggle.jsx +16 -0
- package/src/library/pages/FitnessPage/FitnessPage.jsx +519 -0
- package/src/library/pages/FitnessPage/index.jsx +12 -0
- package/src/library/pages/GroupChat/GroupChat.jsx +275 -0
- package/src/library/pages/GroupChat/data.js +203 -0
- package/src/library/pages/GroupChat/index.jsx +12 -0
- package/src/library/pages/ReservationsOverview/ReservationsOverviewPage.jsx +225 -0
- package/src/library/pages/ReservationsOverview/index.jsx +12 -0
- package/src/library/pages/VideoConference/VideoConferencePage.jsx +334 -0
- package/src/library/pages/VideoConference/index.jsx +12 -0
|
@@ -0,0 +1,275 @@
|
|
|
1
|
+
"use client"
|
|
2
|
+
|
|
3
|
+
import { Sidebar, SidebarContent, SidebarMenu, SidebarMenuButton, SidebarMenuItem, SidebarProvider } from '@/components/ui/sidebar'
|
|
4
|
+
import React, { useState, useRef, useEffect } from 'react'
|
|
5
|
+
import { data } from './data'
|
|
6
|
+
import { Avatar, AvatarFallback, AvatarImage } from "@/components/ui/avatar"
|
|
7
|
+
import { Badge } from "@/components/ui/badge"
|
|
8
|
+
import { ScrollArea } from "@/components/ui/scroll-area"
|
|
9
|
+
import { NavigationMenu, NavigationMenuContent, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger } from '@/components/ui/navigation-menu'
|
|
10
|
+
import { Input } from "@/components/ui/input"
|
|
11
|
+
import { Button } from "@/components/ui/button"
|
|
12
|
+
import { Send, MoreVertical, Phone, Video } from 'lucide-react'
|
|
13
|
+
|
|
14
|
+
const GroupChatCode = () => {
|
|
15
|
+
const [activeNav, setActiveNav] = useState('All Chats')
|
|
16
|
+
const [selectedChat, setSelectedChat] = useState(null)
|
|
17
|
+
const messagesEndRef = useRef(null)
|
|
18
|
+
|
|
19
|
+
const scrollToBottom = () => {
|
|
20
|
+
messagesEndRef.current?.scrollIntoView({ behavior: 'smooth' })
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
useEffect(() => {
|
|
24
|
+
// scrollToBottom()
|
|
25
|
+
}, [selectedChat])
|
|
26
|
+
|
|
27
|
+
const getInitials = (name) => {
|
|
28
|
+
return name
|
|
29
|
+
.split(' ')
|
|
30
|
+
.map(n => n[0])
|
|
31
|
+
.join('')
|
|
32
|
+
.toUpperCase()
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
// Parse timestamp strings into sortable values (lower = more recent)
|
|
36
|
+
const parseTimestamp = (timestamp) => {
|
|
37
|
+
if (timestamp.includes('m ago')) {
|
|
38
|
+
return parseInt(timestamp) // minutes
|
|
39
|
+
} else if (timestamp.includes('h ago')) {
|
|
40
|
+
return parseInt(timestamp) * 60 // hours to minutes
|
|
41
|
+
} else if (timestamp === 'Yesterday') {
|
|
42
|
+
return 24 * 60 // 1 day in minutes
|
|
43
|
+
} else if (timestamp.includes('days ago')) {
|
|
44
|
+
return parseInt(timestamp) * 24 * 60 // days to minutes
|
|
45
|
+
}
|
|
46
|
+
return 999999 // fallback for unknown formats
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
// Combine and sort all chats for "All Chats" view
|
|
50
|
+
const getAllChatsSorted = () => {
|
|
51
|
+
const directMessages = data.chatList.map(chat => ({ ...chat, isGroup: false }))
|
|
52
|
+
const groups = data.groupChats.map(chat => ({ ...chat, isGroup: true }))
|
|
53
|
+
return [...directMessages, ...groups].sort((a, b) => parseTimestamp(a.timestamp) - parseTimestamp(b.timestamp))
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
const handleChatClick = (chat, isGroup = false) => {
|
|
57
|
+
setSelectedChat({ ...chat, isGroup })
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
const ChatItem = ({ chat, isGroup = false, onClick }) => (
|
|
61
|
+
<div
|
|
62
|
+
className={`flex gap-3 items-center p-3 hover:bg-gray-50 cursor-pointer rounded-lg transition-colors ${selectedChat?.id === chat.id && selectedChat?.isGroup === isGroup ? 'bg-blue-50' : ''}`}
|
|
63
|
+
onClick={() => onClick(chat, isGroup)}
|
|
64
|
+
>
|
|
65
|
+
<div className='relative'>
|
|
66
|
+
<Avatar className='bg-gray-800 rounded-sm'>
|
|
67
|
+
<AvatarImage src={chat.avatar} alt={chat.name} />
|
|
68
|
+
<AvatarFallback className='bg-gray-800 text-white'>{getInitials(chat.name)}</AvatarFallback>
|
|
69
|
+
</Avatar>
|
|
70
|
+
{!isGroup && chat.isOnline && (
|
|
71
|
+
<div className='absolute bottom-0 right-0 w-3 h-3 bg-green-500 rounded-full border-2 border-white' />
|
|
72
|
+
)}
|
|
73
|
+
</div>
|
|
74
|
+
<div className='flex-1 min-w-0'>
|
|
75
|
+
<div className='flex items-center justify-between mb-1'>
|
|
76
|
+
<p className='font-semibold text-sm truncate'>{chat.name}</p>
|
|
77
|
+
<span className='text-xs text-gray-500 ml-2 flex-shrink-0'>{chat.timestamp}</span>
|
|
78
|
+
</div>
|
|
79
|
+
<div className='flex items-center justify-between'>
|
|
80
|
+
<p className='text-xs text-gray-600 truncate flex-1'>{chat.lastMessage}</p>
|
|
81
|
+
{chat.unreadCount > 0 && (
|
|
82
|
+
<Badge className='ml-2 bg-blue-500 hover:bg-blue-600 text-white rounded-full h-5 min-w-5 flex items-center justify-center text-xs px-1.5'>
|
|
83
|
+
{chat.unreadCount}
|
|
84
|
+
</Badge>
|
|
85
|
+
)}
|
|
86
|
+
</div>
|
|
87
|
+
{isGroup && (
|
|
88
|
+
<p className='text-xs text-gray-400 mt-1'>{chat.memberCount} members</p>
|
|
89
|
+
)}
|
|
90
|
+
</div>
|
|
91
|
+
</div>
|
|
92
|
+
)
|
|
93
|
+
|
|
94
|
+
const MessageBubble = ({ message }) => (
|
|
95
|
+
<div className={`flex gap-3 mb-4 ${message.isCurrentUser ? 'flex-row-reverse' : ''}`}>
|
|
96
|
+
{!message.isCurrentUser && (
|
|
97
|
+
<Avatar className='w-8 h-8 bg-gray-800'>
|
|
98
|
+
<AvatarImage src={message.avatar} alt={message.sender} />
|
|
99
|
+
<AvatarFallback className='bg-gray-800 text-white'>{getInitials(message.sender)}</AvatarFallback>
|
|
100
|
+
</Avatar>
|
|
101
|
+
)}
|
|
102
|
+
<div className={`max-w-[70%] ${message.isCurrentUser ? 'text-right' : ''}`}>
|
|
103
|
+
{!message.isCurrentUser && (
|
|
104
|
+
<p className='text-xs font-medium text-gray-700 mb-1'>{message.sender}</p>
|
|
105
|
+
)}
|
|
106
|
+
<div className={`rounded-2xl px-4 py-2 inline-block ${message.isCurrentUser ? 'bg-blue-500 text-white' : 'bg-gray-100 text-gray-800'}`}>
|
|
107
|
+
<p className='text-sm'>{message.content}</p>
|
|
108
|
+
</div>
|
|
109
|
+
<p className='text-xs text-gray-400 mt-1'>{message.timestamp}</p>
|
|
110
|
+
</div>
|
|
111
|
+
</div>
|
|
112
|
+
)
|
|
113
|
+
|
|
114
|
+
return (
|
|
115
|
+
<div className='lexend flex flex-col w-full bg-white h-screen overflow-hidden'>
|
|
116
|
+
<NavigationMenu>
|
|
117
|
+
<NavigationMenuList>
|
|
118
|
+
{data.navItems.map((item) => (
|
|
119
|
+
<NavigationMenuItem key={item.title}>
|
|
120
|
+
<NavigationMenuLink
|
|
121
|
+
onClick={() => setActiveNav(item.title)}
|
|
122
|
+
isActive={activeNav === item.title}
|
|
123
|
+
className='w-full'
|
|
124
|
+
>
|
|
125
|
+
<item.icon className='w-10 h-10' />
|
|
126
|
+
<span>{item.title}</span>
|
|
127
|
+
</NavigationMenuLink>
|
|
128
|
+
</NavigationMenuItem>
|
|
129
|
+
))}
|
|
130
|
+
</NavigationMenuList>
|
|
131
|
+
</NavigationMenu>
|
|
132
|
+
<div className='flex'>
|
|
133
|
+
<div className='flex-shrink-0 w-fit h-full flex flex-col'>
|
|
134
|
+
|
|
135
|
+
<SidebarProvider className="w-fit flex-1 overflow-hidden">
|
|
136
|
+
<Sidebar className='border-r h-full w-fit'>
|
|
137
|
+
<SidebarContent className='h-full'>
|
|
138
|
+
{/* Chat Lists */}
|
|
139
|
+
<ScrollArea className='h-full'>
|
|
140
|
+
{activeNav === 'All Chats' && (
|
|
141
|
+
<div className='p-2'>
|
|
142
|
+
<h3 className='text-xs font-semibold text-gray-500 uppercase px-3 py-2'>
|
|
143
|
+
All Messages
|
|
144
|
+
</h3>
|
|
145
|
+
{getAllChatsSorted().map((chat) => (
|
|
146
|
+
<ChatItem key={`${chat.isGroup ? 'group' : 'dm'}-${chat.id}`} chat={chat} isGroup={chat.isGroup} onClick={handleChatClick} />
|
|
147
|
+
))}
|
|
148
|
+
</div>
|
|
149
|
+
)}
|
|
150
|
+
|
|
151
|
+
{activeNav === 'Direct Messages' && (
|
|
152
|
+
<div className='p-2'>
|
|
153
|
+
<h3 className='text-xs font-semibold text-gray-500 uppercase px-3 py-2'>
|
|
154
|
+
Direct Messages
|
|
155
|
+
</h3>
|
|
156
|
+
{data.chatList.map((chat) => (
|
|
157
|
+
<ChatItem key={chat.id} chat={chat} onClick={handleChatClick} />
|
|
158
|
+
))}
|
|
159
|
+
</div>
|
|
160
|
+
)}
|
|
161
|
+
|
|
162
|
+
{activeNav === 'Groups' && (
|
|
163
|
+
<div className='p-2'>
|
|
164
|
+
<h3 className='text-xs font-semibold text-gray-500 uppercase px-3 py-2'>
|
|
165
|
+
Groups
|
|
166
|
+
</h3>
|
|
167
|
+
{data.groupChats.map((chat) => (
|
|
168
|
+
<ChatItem key={chat.id} chat={chat} isGroup={true} onClick={handleChatClick} />
|
|
169
|
+
))}
|
|
170
|
+
</div>
|
|
171
|
+
)}
|
|
172
|
+
|
|
173
|
+
{activeNav === 'Starred' && (
|
|
174
|
+
<div className='p-2'>
|
|
175
|
+
<h3 className='text-xs font-semibold text-gray-500 uppercase px-3 py-2'>
|
|
176
|
+
Starred Chats
|
|
177
|
+
</h3>
|
|
178
|
+
{data.chatList
|
|
179
|
+
.filter(chat => chat.isStarred)
|
|
180
|
+
.map((chat) => (
|
|
181
|
+
<ChatItem key={chat.id} chat={chat} onClick={handleChatClick} />
|
|
182
|
+
))}
|
|
183
|
+
{data.groupChats
|
|
184
|
+
.filter(chat => chat.isStarred)
|
|
185
|
+
.map((chat) => (
|
|
186
|
+
<ChatItem key={chat.id} chat={chat} isGroup={true} onClick={handleChatClick} />
|
|
187
|
+
))}
|
|
188
|
+
</div>
|
|
189
|
+
)}
|
|
190
|
+
|
|
191
|
+
{activeNav === 'Settings' && (
|
|
192
|
+
<div className='p-4'>
|
|
193
|
+
<h3 className='text-sm font-semibold mb-4'>Settings</h3>
|
|
194
|
+
<p className='text-xs text-gray-500'>Settings panel coming soon...</p>
|
|
195
|
+
</div>
|
|
196
|
+
)}
|
|
197
|
+
</ScrollArea>
|
|
198
|
+
</SidebarContent>
|
|
199
|
+
</Sidebar>
|
|
200
|
+
</SidebarProvider>
|
|
201
|
+
</div>
|
|
202
|
+
|
|
203
|
+
{/* Main Chat Area */}
|
|
204
|
+
<div className='flex-1 flex flex-col bg-gray-50 h-full overflow-hidden'>
|
|
205
|
+
{selectedChat ? (
|
|
206
|
+
<div className='flex flex-col h-full'>
|
|
207
|
+
{/* Chat Header */}
|
|
208
|
+
<div className='flex-shrink-0 flex items-center justify-between p-4 bg-white border-b'>
|
|
209
|
+
<div className='flex items-center gap-3'>
|
|
210
|
+
<Avatar className='bg-gray-800'>
|
|
211
|
+
<AvatarImage src={selectedChat.avatar} alt={selectedChat.name} />
|
|
212
|
+
<AvatarFallback className='bg-gray-800 text-white'>{getInitials(selectedChat.name)}</AvatarFallback>
|
|
213
|
+
</Avatar>
|
|
214
|
+
<div>
|
|
215
|
+
<p className='font-semibold'>{selectedChat.name}</p>
|
|
216
|
+
{selectedChat.isGroup ? (
|
|
217
|
+
<p className='text-xs text-gray-500'>{selectedChat.memberCount} members</p>
|
|
218
|
+
) : (
|
|
219
|
+
<p className='text-xs text-green-500'>{selectedChat.isOnline ? 'Online' : 'Offline'}</p>
|
|
220
|
+
)}
|
|
221
|
+
</div>
|
|
222
|
+
</div>
|
|
223
|
+
<div className='flex items-center gap-2'>
|
|
224
|
+
<Button variant='ghost' size='icon'><Phone className='w-5 h-5' /></Button>
|
|
225
|
+
<Button variant='ghost' size='icon'><Video className='w-5 h-5' /></Button>
|
|
226
|
+
<Button variant='ghost' size='icon'><MoreVertical className='w-5 h-5' /></Button>
|
|
227
|
+
</div>
|
|
228
|
+
</div>
|
|
229
|
+
|
|
230
|
+
{/* Messages Area */}
|
|
231
|
+
<div className='flex-1 min-h-0 overflow-hidden'>
|
|
232
|
+
<ScrollArea className='h-full p-4'>
|
|
233
|
+
{selectedChat.messages && selectedChat.messages.length > 0 ? (
|
|
234
|
+
<>
|
|
235
|
+
{selectedChat.messages.map((message) => (
|
|
236
|
+
<MessageBubble key={message.id} message={message} />
|
|
237
|
+
))}
|
|
238
|
+
<div ref={messagesEndRef} />
|
|
239
|
+
</>
|
|
240
|
+
) : (
|
|
241
|
+
<div className='flex items-center justify-center h-full text-gray-400'>
|
|
242
|
+
<p>No messages yet. Start the conversation!</p>
|
|
243
|
+
</div>
|
|
244
|
+
)}
|
|
245
|
+
</ScrollArea>
|
|
246
|
+
</div>
|
|
247
|
+
|
|
248
|
+
{/* Message Input */}
|
|
249
|
+
<div className='flex-shrink-0 p-4 bg-white border-t'>
|
|
250
|
+
<div className='flex gap-2'>
|
|
251
|
+
<Input
|
|
252
|
+
placeholder='Type a message...'
|
|
253
|
+
className='flex-1'
|
|
254
|
+
/>
|
|
255
|
+
<Button size='icon'>
|
|
256
|
+
<Send className='w-4 h-4' />
|
|
257
|
+
</Button>
|
|
258
|
+
</div>
|
|
259
|
+
</div>
|
|
260
|
+
</div>
|
|
261
|
+
) : (
|
|
262
|
+
<div className='flex-1 flex items-center justify-center'>
|
|
263
|
+
<div className='text-center text-gray-400'>
|
|
264
|
+
<p className='text-lg font-medium'>Select a chat to start messaging</p>
|
|
265
|
+
<p className='text-sm mt-2'>Choose a conversation from the sidebar</p>
|
|
266
|
+
</div>
|
|
267
|
+
</div>
|
|
268
|
+
)}
|
|
269
|
+
</div>
|
|
270
|
+
</div>
|
|
271
|
+
</div>
|
|
272
|
+
)
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
export default GroupChatCode
|
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
import {
|
|
2
|
+
MessageSquare,
|
|
3
|
+
MessageCircle,
|
|
4
|
+
Users,
|
|
5
|
+
Star,
|
|
6
|
+
Settings
|
|
7
|
+
} from 'lucide-react';
|
|
8
|
+
|
|
9
|
+
export const data = {
|
|
10
|
+
navItems: [
|
|
11
|
+
{
|
|
12
|
+
title: 'All Chats',
|
|
13
|
+
url: '#',
|
|
14
|
+
icon: MessageSquare,
|
|
15
|
+
isActive: true,
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
title: 'Direct Messages',
|
|
19
|
+
url: '#',
|
|
20
|
+
icon: MessageCircle,
|
|
21
|
+
isActive: false,
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
title: 'Groups',
|
|
25
|
+
url: '#',
|
|
26
|
+
icon: Users,
|
|
27
|
+
isActive: false,
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
title: 'Starred',
|
|
31
|
+
url: '#',
|
|
32
|
+
icon: Star,
|
|
33
|
+
isActive: false,
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
title: 'Settings',
|
|
37
|
+
url: '#',
|
|
38
|
+
icon: Settings,
|
|
39
|
+
isActive: false,
|
|
40
|
+
}
|
|
41
|
+
],
|
|
42
|
+
chatList: [
|
|
43
|
+
{
|
|
44
|
+
id: 1,
|
|
45
|
+
name: 'Sarah Johnson',
|
|
46
|
+
avatar: '/avatars/avatar1.png',
|
|
47
|
+
lastMessage: 'Hey! Did you see the new design mockups?',
|
|
48
|
+
timestamp: '2m ago',
|
|
49
|
+
unreadCount: 3,
|
|
50
|
+
isOnline: true,
|
|
51
|
+
isStarred: false,
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
id: 2,
|
|
55
|
+
name: 'Mike Chen',
|
|
56
|
+
avatar: '/avatars/avatar2.png',
|
|
57
|
+
lastMessage: 'Thanks for the help earlier!',
|
|
58
|
+
timestamp: '15m ago',
|
|
59
|
+
unreadCount: 0,
|
|
60
|
+
isOnline: true,
|
|
61
|
+
isStarred: true,
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
id: 3,
|
|
65
|
+
name: 'Emily Rodriguez',
|
|
66
|
+
avatar: '/avatars/avatar3.png',
|
|
67
|
+
lastMessage: 'Can we schedule a meeting for tomorrow?',
|
|
68
|
+
timestamp: '1h ago',
|
|
69
|
+
unreadCount: 1,
|
|
70
|
+
isOnline: false,
|
|
71
|
+
isStarred: false,
|
|
72
|
+
},
|
|
73
|
+
// {
|
|
74
|
+
// id: 4,
|
|
75
|
+
// name: 'David Kim',
|
|
76
|
+
// avatar: '/avatars/avatar4.png',
|
|
77
|
+
// lastMessage: 'The project looks great! 🎉',
|
|
78
|
+
// timestamp: '2h ago',
|
|
79
|
+
// unreadCount: 0,
|
|
80
|
+
// isOnline: false,
|
|
81
|
+
// isStarred: true,
|
|
82
|
+
// },
|
|
83
|
+
// {
|
|
84
|
+
// id: 5,
|
|
85
|
+
// name: 'Lisa Anderson',
|
|
86
|
+
// avatar: '/avatars/avatar1.png',
|
|
87
|
+
// lastMessage: 'I\'ll send you the files in a bit',
|
|
88
|
+
// timestamp: '3h ago',
|
|
89
|
+
// unreadCount: 0,
|
|
90
|
+
// isOnline: true,
|
|
91
|
+
// isStarred: false,
|
|
92
|
+
// },
|
|
93
|
+
// {
|
|
94
|
+
// id: 6,
|
|
95
|
+
// name: 'James Wilson',
|
|
96
|
+
// avatar: '/avatars/avatar2.png',
|
|
97
|
+
// lastMessage: 'Let me know when you\'re free',
|
|
98
|
+
// timestamp: 'Yesterday',
|
|
99
|
+
// unreadCount: 2,
|
|
100
|
+
// isOnline: false,
|
|
101
|
+
// isStarred: false,
|
|
102
|
+
// },
|
|
103
|
+
// {
|
|
104
|
+
// id: 7,
|
|
105
|
+
// name: 'Anna Martinez',
|
|
106
|
+
// avatar: '/avatars/avatar3.png',
|
|
107
|
+
// lastMessage: 'Perfect, see you then!',
|
|
108
|
+
// timestamp: 'Yesterday',
|
|
109
|
+
// unreadCount: 0,
|
|
110
|
+
// isOnline: true,
|
|
111
|
+
// isStarred: false,
|
|
112
|
+
// },
|
|
113
|
+
{
|
|
114
|
+
id: 8,
|
|
115
|
+
name: 'Tom Brown',
|
|
116
|
+
avatar: '/avatars/avatar4.png',
|
|
117
|
+
lastMessage: 'Got it, thanks!',
|
|
118
|
+
timestamp: '2 days ago',
|
|
119
|
+
unreadCount: 0,
|
|
120
|
+
isOnline: false,
|
|
121
|
+
isStarred: false,
|
|
122
|
+
}
|
|
123
|
+
],
|
|
124
|
+
groupChats: [
|
|
125
|
+
{
|
|
126
|
+
id: 1,
|
|
127
|
+
name: 'Design Team',
|
|
128
|
+
avatar: 'https://api.dicebear.com/7.x/shapes/svg?seed=DesignTeam',
|
|
129
|
+
lastMessage: 'Sarah: The new color palette is ready',
|
|
130
|
+
timestamp: '5m ago',
|
|
131
|
+
unreadCount: 5,
|
|
132
|
+
memberCount: 8,
|
|
133
|
+
isStarred: true,
|
|
134
|
+
members: ['Sarah Johnson', 'Mike Chen', 'Emily Rodriguez', 'David Kim', 'Lisa Anderson', 'James Wilson', 'Anna Martinez', 'Tom Brown'],
|
|
135
|
+
messages: [
|
|
136
|
+
{ id: 1, sender: 'Sarah Johnson', avatar: '/avatars/avatar1.png', content: 'Hey team! I\'ve been working on the new color palette for the dashboard.', timestamp: '10:30 AM', isCurrentUser: false },
|
|
137
|
+
{ id: 2, sender: 'Mike Chen', avatar: '/avatars/avatar2.png', content: 'Awesome! Can\'t wait to see it. What direction did you go with?', timestamp: '10:32 AM', isCurrentUser: false },
|
|
138
|
+
// { id: 3, sender: 'Sarah Johnson', avatar: '/avatars/avatar1.png', content: 'I went with a more vibrant set of colors. Think modern and energetic!', timestamp: '10:33 AM', isCurrentUser: false },
|
|
139
|
+
{ id: 4, sender: 'You', avatar: '/avatars/avatar4.png', content: 'That sounds great! I was hoping we\'d move away from the muted tones.', timestamp: '10:35 AM', isCurrentUser: true },
|
|
140
|
+
// { id: 5, sender: 'Emily Rodriguez', avatar: '/avatars/avatar3.png', content: 'I agree! The current palette feels too corporate. Fresh colors would be nice.', timestamp: '10:37 AM', isCurrentUser: false },
|
|
141
|
+
// { id: 6, sender: 'David Kim', avatar: '/avatars/avatar4.png', content: 'Just make sure we maintain accessibility standards for contrast ratios 👍', timestamp: '10:40 AM', isCurrentUser: false },
|
|
142
|
+
// { id: 7, sender: 'Sarah Johnson', avatar: '/avatars/avatar1.png', content: 'Definitely! I\'ve run all the combinations through the WCAG checker.', timestamp: '10:42 AM', isCurrentUser: false },
|
|
143
|
+
// { id: 8, sender: 'You', avatar: '/avatars/avatar4.png', content: 'Perfect! When can we see the final designs?', timestamp: '10:45 AM', isCurrentUser: true },
|
|
144
|
+
// { id: 9, sender: 'Sarah Johnson', avatar: '/avatars/avatar1.png', content: 'The new color palette is ready', timestamp: '10:48 AM', isCurrentUser: false }
|
|
145
|
+
]
|
|
146
|
+
},
|
|
147
|
+
{
|
|
148
|
+
id: 2,
|
|
149
|
+
name: 'Project Alpha',
|
|
150
|
+
avatar: 'https://api.dicebear.com/7.x/shapes/svg?seed=ProjectAlpha',
|
|
151
|
+
lastMessage: 'Mike: Meeting at 3 PM today',
|
|
152
|
+
timestamp: '30m ago',
|
|
153
|
+
unreadCount: 2,
|
|
154
|
+
memberCount: 5,
|
|
155
|
+
isStarred: false,
|
|
156
|
+
members: ['Mike Chen', 'Emily Rodriguez', 'David Kim', 'Lisa Anderson', 'Tom Brown']
|
|
157
|
+
},
|
|
158
|
+
// {
|
|
159
|
+
// id: 3,
|
|
160
|
+
// name: 'Marketing Squad',
|
|
161
|
+
// avatar: 'https://api.dicebear.com/7.x/shapes/svg?seed=Marketing',
|
|
162
|
+
// lastMessage: 'Emily: Campaign results look promising!',
|
|
163
|
+
// timestamp: '1h ago',
|
|
164
|
+
// unreadCount: 0,
|
|
165
|
+
// memberCount: 6,
|
|
166
|
+
// isStarred: true,
|
|
167
|
+
// members: ['Emily Rodriguez', 'Sarah Johnson', 'Anna Martinez', 'James Wilson', 'Lisa Anderson', 'David Kim']
|
|
168
|
+
// },
|
|
169
|
+
// {
|
|
170
|
+
// id: 4,
|
|
171
|
+
// name: 'Dev Team',
|
|
172
|
+
// avatar: 'https://api.dicebear.com/7.x/shapes/svg?seed=DevTeam',
|
|
173
|
+
// lastMessage: 'David: Deployed to staging',
|
|
174
|
+
// timestamp: '2h ago',
|
|
175
|
+
// unreadCount: 1,
|
|
176
|
+
// memberCount: 10,
|
|
177
|
+
// isStarred: false,
|
|
178
|
+
// members: ['David Kim', 'Mike Chen', 'Tom Brown', 'James Wilson', 'Sarah Johnson', 'Emily Rodriguez', 'Lisa Anderson', 'Anna Martinez']
|
|
179
|
+
// },
|
|
180
|
+
// {
|
|
181
|
+
// id: 5,
|
|
182
|
+
// name: 'Weekend Plans',
|
|
183
|
+
// avatar: 'https://api.dicebear.com/7.x/shapes/svg?seed=Weekend',
|
|
184
|
+
// lastMessage: 'Lisa: Who\'s up for hiking?',
|
|
185
|
+
// timestamp: '4h ago',
|
|
186
|
+
// unreadCount: 0,
|
|
187
|
+
// memberCount: 4,
|
|
188
|
+
// isStarred: false,
|
|
189
|
+
// members: ['Lisa Anderson', 'Anna Martinez', 'Sarah Johnson', 'Mike Chen']
|
|
190
|
+
// },
|
|
191
|
+
// {
|
|
192
|
+
// id: 6,
|
|
193
|
+
// name: 'Book Club',
|
|
194
|
+
// avatar: 'https://api.dicebear.com/7.x/shapes/svg?seed=BookClub',
|
|
195
|
+
// lastMessage: 'Anna: Next meeting is on Friday',
|
|
196
|
+
// timestamp: 'Yesterday',
|
|
197
|
+
// unreadCount: 0,
|
|
198
|
+
// memberCount: 7,
|
|
199
|
+
// isStarred: false,
|
|
200
|
+
// members: ['Anna Martinez', 'Emily Rodriguez', 'Lisa Anderson', 'Sarah Johnson', 'Tom Brown', 'James Wilson', 'David Kim']
|
|
201
|
+
// }
|
|
202
|
+
]
|
|
203
|
+
};
|