Skip to content

Commit

Permalink
feat: hide evaluations from history
Browse files Browse the repository at this point in the history
  • Loading branch information
JoeSlain committed Dec 18, 2024
1 parent f9f7923 commit a56d763
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 12 deletions.
3 changes: 1 addition & 2 deletions src/pages/Evaluations.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -186,8 +186,7 @@ function QuestionRow({
{operator}
</span>
<span
className={`fr-tag `}
style={{ backgroundColor: difficultyLevelsToColor(complexity) }}
className={`fr-tag fr-text-action-high--blue-france fr-background-action-low--blue-france`}
>
{complexity}
</span>
Expand Down
23 changes: 13 additions & 10 deletions src/pages/History.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,21 +59,24 @@ function ChatList() {
themes?: string[]
updatedDate: string | null
id: number
type: string
}

return (
<div className={'fr-mt-2w fr-grid-row w-full'}>
<div className="fr-col-6 overflow-y-auto h-[66vh]">
{chats.map((chat: TestChatType, index) => (
<div key={index}>
<ChatListRow
selectedChatId={selectedChatId}
setSelectedChatId={setSelectedChatId}
{...chat}
/>
<Separator />
</div>
))}
{chats
.filter((chat: TestChatType) => chat.type !== 'evaluations') // Filter out evaluations
.map((chat: TestChatType, index) => (
<div key={index}>
<ChatListRow
selectedChatId={selectedChatId}
setSelectedChatId={setSelectedChatId}
{...chat}
/>
<Separator />
</div>
))}
<div ref={ref} style={{ height: 1 }} />
{isFetchingNextPage && <LoadingSpinner />}
</div>
Expand Down

0 comments on commit a56d763

Please sign in to comment.