Marketing Hub: RBAC, i18n (AR/EN), tasks overhaul, team/user merge, tutorial
Features: - Full RBAC with 3 roles (superadmin/manager/contributor) - Ownership tracking on posts, tasks, campaigns, projects - Task system: assign to anyone, filter combobox, visibility scoping - Team members merged into users table (single source of truth) - Post thumbnails on kanban cards from attachments - Publication link validation before publishing - Interactive onboarding tutorial with Settings restart - Full Arabic/English i18n with RTL layout support - Language toggle in sidebar, IBM Plex Sans Arabic font - Brand-based visibility filtering for non-superadmins - Manager can only create contributors - Profile completion flow for new users - Cookie-based sessions (express-session + SQLite)
This commit is contained in:
30
client/src/components/PlatformIcon.jsx
Normal file
30
client/src/components/PlatformIcon.jsx
Normal file
@@ -0,0 +1,30 @@
|
||||
import { PLATFORMS } from '../utils/api'
|
||||
|
||||
export default function PlatformIcon({ platform, size = 16, showLabel = false, className = '' }) {
|
||||
const p = PLATFORMS[platform]
|
||||
if (!p) return <span className="text-[10px] text-text-tertiary capitalize">{platform}</span>
|
||||
|
||||
return (
|
||||
<span className={`inline-flex items-center gap-1 ${className}`} title={p.label}>
|
||||
<svg
|
||||
width={size}
|
||||
height={size}
|
||||
viewBox="0 0 24 24"
|
||||
fill={p.color}
|
||||
className="shrink-0"
|
||||
>
|
||||
<path d={p.icon} />
|
||||
</svg>
|
||||
{showLabel && <span className="text-xs text-text-secondary">{p.label}</span>}
|
||||
</span>
|
||||
)
|
||||
}
|
||||
|
||||
export function PlatformIcons({ platforms = [], size = 14, gap = 'gap-1', className = '' }) {
|
||||
if (!platforms || platforms.length === 0) return null
|
||||
return (
|
||||
<span className={`inline-flex items-center ${gap} ${className}`}>
|
||||
{platforms.map(p => <PlatformIcon key={p} platform={p} size={size} />)}
|
||||
</span>
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user