feat: add GIF Mood Board workshop
All checks were successful
Deploy with Docker Compose / deploy (push) Successful in 4m5s
All checks were successful
Deploy with Docker Compose / deploy (push) Successful in 4m5s
- New workshop where each team member shares up to 5 GIFs with notes to express their weekly mood - Per-user week rating (1-5 stars) visible next to each member's section - Masonry-style grid with adjustable column count (3/4/5) toggle - Handwriting font (Caveat) for GIF notes - Full real-time collaboration via SSE - Clean migration (add_gif_mood_workshop) safe for production deploy - DB backup via cp before each migration in docker-entrypoint Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
62
src/components/gif-mood/GifMoodLiveWrapper.tsx
Normal file
62
src/components/gif-mood/GifMoodLiveWrapper.tsx
Normal file
@@ -0,0 +1,62 @@
|
||||
'use client';
|
||||
|
||||
import { BaseSessionLiveWrapper } from '@/components/collaboration/BaseSessionLiveWrapper';
|
||||
import {
|
||||
shareGifMoodSession,
|
||||
shareGifMoodSessionToTeam,
|
||||
removeGifMoodShare,
|
||||
} from '@/actions/gif-mood';
|
||||
import type { TeamWithMembers, Share } from '@/lib/share-utils';
|
||||
|
||||
interface GifMoodLiveWrapperProps {
|
||||
sessionId: string;
|
||||
sessionTitle: string;
|
||||
currentUserId: string;
|
||||
shares: Share[];
|
||||
isOwner: boolean;
|
||||
canEdit: boolean;
|
||||
userTeams?: TeamWithMembers[];
|
||||
children: React.ReactNode;
|
||||
}
|
||||
|
||||
export function GifMoodLiveWrapper({
|
||||
sessionId,
|
||||
sessionTitle,
|
||||
currentUserId,
|
||||
shares,
|
||||
isOwner,
|
||||
canEdit,
|
||||
userTeams = [],
|
||||
children,
|
||||
}: GifMoodLiveWrapperProps) {
|
||||
return (
|
||||
<BaseSessionLiveWrapper
|
||||
sessionId={sessionId}
|
||||
sessionTitle={sessionTitle}
|
||||
currentUserId={currentUserId}
|
||||
shares={shares}
|
||||
isOwner={isOwner}
|
||||
canEdit={canEdit}
|
||||
userTeams={userTeams}
|
||||
config={{
|
||||
apiPath: 'gif-mood',
|
||||
shareModal: {
|
||||
title: 'Partager le GIF Mood Board',
|
||||
sessionSubtitle: 'GIF Mood Board',
|
||||
helpText: (
|
||||
<>
|
||||
<strong>Éditeur</strong> : peut ajouter ses GIFs et voir ceux des autres
|
||||
<br />
|
||||
<strong>Lecteur</strong> : peut uniquement consulter
|
||||
</>
|
||||
),
|
||||
},
|
||||
onShareWithEmail: (email, role) => shareGifMoodSession(sessionId, email, role),
|
||||
onShareWithTeam: (teamId, role) => shareGifMoodSessionToTeam(sessionId, teamId, role),
|
||||
onRemoveShare: (userId) => removeGifMoodShare(sessionId, userId),
|
||||
}}
|
||||
>
|
||||
{children}
|
||||
</BaseSessionLiveWrapper>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user