Enhance audience management features with new components and API integrations

- Added `AssignCoursesModal`, `AudienceMemberRow`, `AudienceTable`, and related components for improved audience management UI.
- Implemented audience invite actions including resend and revoke functionality.
- Updated audience API to support importing members and assigning courses.
- Refactored audience data handling to include status and invite management.
- Improved overall user experience with pagination and selection features in the audience table.
This commit is contained in:
Rotimi Best
2026-03-22 18:42:23 +01:00
parent e9c4082f89
commit 3919ff6c2f
157 changed files with 13183 additions and 872 deletions
@@ -17,6 +17,7 @@
import type { CourseMembers, CourseMember } from '$features/course/utils/types';
import { courseApi } from '$features/course/api';
import { t } from '$lib/utils/functions/translations';
import UserIcon from '@lucide/svelte/icons/user';
import { shortenName } from '$lib/utils/functions/string';
import * as Select from '@cio/ui/base/select';
import { IconButton } from '@cio/ui/custom/icon-button';
@@ -138,11 +139,15 @@
{#if person.profile}
<div class="flex items-start lg:items-center">
<Avatar.Root class="mr-3">
<Avatar.Image
src={person.profile.avatar_url ? person.profile.avatar_url : '/logo-192.png'}
alt={person.profile.fullname ? person.profile.fullname : 'User'}
/>
<Avatar.Fallback>{shortenName(person.profile.fullname) || 'U'}</Avatar.Fallback>
{#if person.profile.avatar_url}
<Avatar.Image
src={person.profile.avatar_url}
alt={person.profile.fullname ? person.profile.fullname : 'User'}
/>
{/if}
<Avatar.Fallback>
<UserIcon class="ui:size-4 ui:text-muted-foreground" />
</Avatar.Fallback>
</Avatar.Root>
<div class="flex flex-col items-start lg:flex-row lg:items-center">
<div class="mr-2">