diff --git a/packages/web/components/MainTabsOrPages/ViewConvo.tsx b/packages/web/components/MainTabsOrPages/ViewConvo.tsx index 4a0c8dc..b719698 100644 --- a/packages/web/components/MainTabsOrPages/ViewConvo.tsx +++ b/packages/web/components/MainTabsOrPages/ViewConvo.tsx @@ -1,7 +1,20 @@ import { LinkType } from "@nirvana/common/models/link"; +import { UserStatus } from "@nirvana/common/models/user"; import { Tooltip } from "antd"; -import { FaExternalLinkAlt, FaGithub, FaImages } from "react-icons/fa"; +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; @@ -30,6 +43,44 @@ const testDrawerItems: { }, ]; +const testAudioClips: { + senderName: string; + relativeSentTime: string; + duration: number; + alreadyPlayed: boolean; +}[] = [ + { + senderName: "John", + relativeSentTime: "yesterday", + duration: 150, + alreadyPlayed: 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, + }, +]; + export default function ViewConvo(props: { conversationId: string }) { // auth if do not have this conversation in react cache, then we are not authorized @@ -40,7 +91,7 @@ export default function ViewConvo(props: { conversationId: string }) { <>
{/* drawer items */} -
+
Shared @@ -59,7 +110,7 @@ export default function ViewConvo(props: { conversationId: string }) { /> - {link.linkName} + {link.linkName} {link.relativeSentTime} @@ -81,12 +132,107 @@ export default function ViewConvo(props: { conversationId: string }) {
{/* main timeline view with action buttons on top */} -
- - Timeline +
+ {/* header */} + + + + + Engineering + + + + + + + + 25 members + + + + + + + + + + + + {/* have one row, but just translate it along y downward to put it in it's own place */} + + {testAudioClips.map((audClip, index) => ( + + + + + + {audClip.senderName} + + + {audClip.relativeSentTime} + + + + ))} + + + {/* stuff for recording and playing action */} + + + + + + + + + + + +
diff --git a/packages/web/services/firebaseService.js b/packages/web/services/firebaseService.js index 616dbc4..540f6a4 100644 --- a/packages/web/services/firebaseService.js +++ b/packages/web/services/firebaseService.js @@ -39,8 +39,6 @@ console.log("initialized firebase"); // const analytics = getAnalytics(app); -setPersistence(getAuth(), browserSessionPersistence); - // Initialize firestore persistence for data caching const db = getFirestore(app); enableIndexedDbPersistence(db).catch((err) => { @@ -54,3 +52,5 @@ enableIndexedDbPersistence(db).catch((err) => { // ... } }); + +setPersistence(getAuth(), browserSessionPersistence);