-
Notifications
You must be signed in to change notification settings - Fork 4.1k
feat: show message counter in history page #9524
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Learn moreAll Green is an AI agent that automatically: ✅ Addresses code review comments ✅ Fixes failing CI checks ✅ Resolves merge conflicts |
1 similar comment
Learn moreAll Green is an AI agent that automatically: ✅ Addresses code review comments ✅ Fixes failing CI checks ✅ Resolves merge conflicts |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1 issue found across 3 files
Prompt for AI agents (all issues)
Check if these issues are valid — if so, understand the root cause of each and fix them.
<file name="gui/src/components/History/HistoryTableRow.tsx">
<violation number="1" location="gui/src/components/History/HistoryTableRow.tsx:155">
P2: Message counter is placed at the right edge (`ml-auto`) but the hover action bar is absolutely positioned at the same right edge and stacks above it, causing the counter/tooltip to be obscured when hovering the row.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
| sessionMetadata.messageCount === 1 ? " is" : "s are" | ||
| } present in this session`} | ||
| > | ||
| <span className="bg-vsc-background text-secondary-foreground ml-auto inline-flex items-center rounded-full px-2 py-1 text-xs font-medium"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
P2: Message counter is placed at the right edge (ml-auto) but the hover action bar is absolutely positioned at the same right edge and stacks above it, causing the counter/tooltip to be obscured when hovering the row.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At gui/src/components/History/HistoryTableRow.tsx, line 155:
<comment>Message counter is placed at the right edge (`ml-auto`) but the hover action bar is absolutely positioned at the same right edge and stacks above it, causing the counter/tooltip to be obscured when hovering the row.</comment>
<file context>
@@ -144,6 +145,18 @@ export function HistoryTableRow({
+ sessionMetadata.messageCount === 1 ? " is" : "s are"
+ } present in this session`}
+ >
+ <span className="bg-vsc-background text-secondary-foreground ml-auto inline-flex items-center rounded-full px-2 py-1 text-xs font-medium">
+ {sessionMetadata.messageCount}
+ </span>
</file context>
RomneyDa
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@uinstinct this is a nice addition! See comment about counting. I think cubic's feedback is also valid, the positioning isn't too bad but maybe we could try some other places to put the number, and maybe add a little message icon or something
|
|
||
| let found = false; | ||
| const messageCount = session.history.filter( | ||
| (item) => item.message.role === "user", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(item) => item.message.role === "user",
I think for longer agent conversations this will show a number much lower than it should e.g. 1 user message, 20 assistant/tool messages will show 1
Maybe we could count conversational turns or just simple chatHistory.length excluding system message?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
actually when trying out chatHistory.length, it show around 15 counter for a single message conversation which would include tool calls and assistant messages. I think the user will want to know how many followups he did.
@RomneyDa what do you think about replacing the message counter with dots or bars? something like | | | indicating 3 messages or • • • or ● ● ●. when there are more than 7-8 messages (depending on the sidebar width), it will show the counter.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's currently counting by filtering for user messages, am I reading that wrong?
Personally I prefer a little number with message icon or similar to dots or bars but I don't have super strong opinions about the design!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes only user messages.
How about putting dots for the initial design? If they do not look good, it can be changed

Description
Show the number of messages (sent by the user) as a counter in the extension's history page.
AI Code Review
@continue-reviewChecklist
Screen recording or screenshot
feat.mp4
Tests
[ What tests were added or updated to ensure the changes work as expected? ]
Continue Tasks
Powered by Continue
Summary by cubic
Add a message counter to the history page that shows how many user messages each session contains. This makes it easier to scan session size at a glance.
Written for commit 3952a60. Summary will update on new commits.