diff --git a/packages/common/models/clientModels/conversationData.md b/documentation/ConversationsFlow.md similarity index 81% rename from packages/common/models/clientModels/conversationData.md rename to documentation/ConversationsFlow.md index b51ee8c..9e90008 100644 --- a/packages/common/models/clientModels/conversationData.md +++ b/documentation/ConversationsFlow.md @@ -12,6 +12,8 @@ this conversation had something going on (new link, new room, new clip...) AND other users just subscribe to this published source // -> users - A -> last interaction date // -> audioClips - c // -> links // -> live } +- also be able to see very cleraly who the last speaker was in the conversation + # Listeners ### A - listener for all - users within conversation documents @@ -45,3 +47,14 @@ all conversations in the conversation map and place in right category /\*\* - } \*/ // + +# Dashboard + +### Data Needed + +- live conversations going on right now and which people are in them +- all inbox-like conversations such as today, last 7 days, etc + a. being able to play the last message in the conversation with a play button + b. see if there is a new update in the conversation which I have not viewed +- priority conversations + a. need to be able to play any messages from there diff --git a/packages/web/services/algoliaSearchService.ts b/packages/web/services/algoliaSearchService.ts index 47e98c8..a892fe1 100644 --- a/packages/web/services/algoliaSearchService.ts +++ b/packages/web/services/algoliaSearchService.ts @@ -1,20 +1,11 @@ import algoliaSearch, { SearchClient } from "algoliasearch"; -var searchClient: SearchClient = null; - -if ( - process.env.NEXT_PUBLIC_ALGOLIA_APP_ID && +const searchClient: SearchClient = algoliaSearch( + process.env.NEXT_PUBLIC_ALGOLIA_APP_ID, process.env.NEXT_PUBLIC_ALGOLIA_API_KEY -) { - searchClient = algoliaSearch( - process.env.NEXT_PUBLIC_ALGOLIA_APP_ID, - process.env.NEXT_PUBLIC_ALGOLIA_API_KEY - ); +); - console.log("set up algolia search successfully"); -} else { - console.error("unable to set up aloglia"); -} +console.log("set up algolia search successfully"); export const usersIndex = searchClient.initIndex( process.env.NEXT_PUBLIC_ALGOLIA_USERS_INDEX_NAME || ""