Spaces:
Running
Running
File size: 567 Bytes
1c2515f |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
import { dbInternalGetAllMessageByDate } from '@/lib/db/functions';
import MessageGrid from '@/components/internal/MessageGrid';
import { MessageFilterParams } from '@/lib/types';
export interface MessageGridServerProps {
messageFilter: MessageFilterParams;
}
export default async function MessageGridServer({
messageFilter,
}: MessageGridServerProps) {
const messages = await dbInternalGetAllMessageByDate(messageFilter);
if (!messages.length) {
return <p className="text-sm italic">No messages</p>;
}
return <MessageGrid messages={messages} />;
}
|