import { LinkType } from "@nirvana/common/models/link"; import { UserStatus } from "@nirvana/common/models/user"; import { Tooltip } from "antd"; import { duration } from "moment"; import { FaCheck, FaEdit, FaExternalLinkAlt, FaGithub, FaImages, FaMicrophone, FaPlay, FaRegClock, FaRocket, } from "react-icons/fa"; import LinkIcon from "../Drawer/LinkIcon"; import UserAvatar, { UserAvatarSizes } from "../UserDetails/UserAvatar"; const testDrawerItems: { linkType: LinkType; linkName: string; relativeSentTime: string; }[] = [ { linkType: LinkType.googleMeet, linkName: "Gmeet - Meeting", relativeSentTime: "5 seconds ago", }, { linkType: LinkType.atlassian, linkName: "Jira Ticket - Ecommerce Plugin", relativeSentTime: "20 minutes ago", }, { linkType: LinkType.github, linkName: "React library for hotkeys", relativeSentTime: "2 hours ago", }, { linkType: LinkType.googleDrive, linkName: "Engineering - Team Drive Folder", relativeSentTime: "last week", }, ]; const testAudioClips: { senderName: string; relativeSentTime: string; duration: number; alreadyPlayed: boolean; isGap?: boolean; }[] = [ { senderName: "John", relativeSentTime: "yesterday", duration: 150, alreadyPlayed: true, }, { senderName: "Moha", relativeSentTime: "5 minutes ago", duration: 600, alreadyPlayed: false, isGap: true, }, { senderName: "Alex", relativeSentTime: "7 hours ago", duration: 10, alreadyPlayed: false, }, { senderName: "Ben", relativeSentTime: "2 hours ago", duration: 300, alreadyPlayed: false, }, { senderName: "Alex", relativeSentTime: "30 minutes ago", duration: 200, alreadyPlayed: false, }, { senderName: "Moha", relativeSentTime: "5 minutes ago", duration: 600, alreadyPlayed: false, }, ]; const gridRows = 4; const gridItems = 4 * 100; export default function ViewConvo(props: { conversationId: string }) { // auth if do not have this conversation in react cache, then we are not authorized // if somehow it's still cached but we were removed, // then authenticate by checking if we are in the array of users for the conversation return ( <>
{/* main timeline view with action buttons on top */}
{/* header */} Engineering 25 members {/* grid */}
{[...Array(gridItems)].map((e, i) => (
))} {/* have one row, but just translate it along y downward to put it in it's own place */} {testAudioClips.map((audClip, index) => { if (audClip.isGap) { return ( ); } return ( {audClip.senderName} {audClip.relativeSentTime} ); })}
{/* stuff for recording and playing action */}
{/* drawer items */}
Shared {/* row of cards drawer items */} {testDrawerItems.map((link) => ( {/* */} {link.linkName} {link.relativeSentTime} ))}
); }