many changes for modules widgets and colors and styling
This commit is contained in:
@@ -30,19 +30,19 @@ interface RecentActivityWidgetProps {
|
||||
loading?: boolean;
|
||||
}
|
||||
|
||||
const activityConfig: Record<string, { icon: typeof GroupIcon; color: string; bgColor: string }> = {
|
||||
clustering: { icon: GroupIcon, color: 'text-purple-600 dark:text-purple-400', bgColor: 'bg-purple-100 dark:bg-purple-900/40' },
|
||||
ideas: { icon: BoltIcon, color: 'text-warning-600 dark:text-warning-400', bgColor: 'bg-warning-100 dark:bg-warning-900/40' },
|
||||
content: { icon: FileTextIcon, color: 'text-success-600 dark:text-success-400', bgColor: 'bg-success-100 dark:bg-success-900/40' },
|
||||
images: { icon: FileIcon, color: 'text-purple-600 dark:text-purple-400', bgColor: 'bg-purple-100 dark:bg-purple-900/40' },
|
||||
published: { icon: PaperPlaneIcon, color: 'text-purple-600 dark:text-purple-400', bgColor: 'bg-purple-100 dark:bg-purple-900/40' },
|
||||
keywords: { icon: ListIcon, color: 'text-brand-600 dark:text-brand-400', bgColor: 'bg-brand-100 dark:bg-brand-900/40' },
|
||||
error: { icon: AlertIcon, color: 'text-error-600 dark:text-error-400', bgColor: 'bg-error-100 dark:bg-error-900/40' },
|
||||
sync: { icon: CheckCircleIcon, color: 'text-purple-600 dark:text-purple-400', bgColor: 'bg-purple-100 dark:bg-purple-900/40' },
|
||||
const activityConfig: Record<string, { icon: typeof GroupIcon; gradient: string }> = {
|
||||
clustering: { icon: GroupIcon, gradient: 'from-purple-500 to-purple-600' },
|
||||
ideas: { icon: BoltIcon, gradient: 'from-warning-500 to-warning-600' },
|
||||
content: { icon: FileTextIcon, gradient: 'from-success-500 to-success-600' },
|
||||
images: { icon: FileIcon, gradient: 'from-purple-500 to-purple-600' },
|
||||
published: { icon: PaperPlaneIcon, gradient: 'from-success-500 to-success-600' },
|
||||
keywords: { icon: ListIcon, gradient: 'from-brand-500 to-brand-600' },
|
||||
error: { icon: AlertIcon, gradient: 'from-error-500 to-error-600' },
|
||||
sync: { icon: CheckCircleIcon, gradient: 'from-success-500 to-success-600' },
|
||||
};
|
||||
|
||||
// Default config for unknown activity types
|
||||
const defaultActivityConfig = { icon: BoltIcon, color: 'text-gray-600 dark:text-gray-400', bgColor: 'bg-gray-100 dark:bg-gray-900/40' };
|
||||
const defaultActivityConfig = { icon: BoltIcon, gradient: 'from-gray-500 to-gray-600' };
|
||||
|
||||
function formatRelativeTime(date: Date): string {
|
||||
const now = new Date();
|
||||
@@ -95,8 +95,8 @@ export default function RecentActivityWidget({ activities, loading }: RecentActi
|
||||
|
||||
const content = (
|
||||
<div className="flex items-start gap-3">
|
||||
<div className={`w-9 h-9 rounded-lg ${config.bgColor} flex items-center justify-center flex-shrink-0`}>
|
||||
<Icon className={`w-5 h-5 ${config.color}`} />
|
||||
<div className={`w-9 h-9 rounded-lg bg-gradient-to-br ${config.gradient} flex items-center justify-center flex-shrink-0 shadow-md`}>
|
||||
<Icon className="w-5 h-5 text-white" />
|
||||
</div>
|
||||
<div className="flex-1 min-w-0">
|
||||
<p className="text-base text-gray-800 dark:text-gray-200 line-clamp-1">
|
||||
|
||||
Reference in New Issue
Block a user