feat: replace token counter with memory indicator widget - #375
Open
NakataCode wants to merge 1 commit into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces the static token-counter pill in the input footer with a
MemoryIndicatorcomponent — a circular arc gauge with a percentagelabel that opens a popover on click. The popover shows a progress bar,
token detail, a brief explainer, and a "Start Fresh" button wired to
clearHistory.Adds
MemoryIndicator.jsandMemoryIndicator.less(new component)Removes
.input-footer/.token-counterstyles; introduces.memory-indicator-host,.memory-indicator-btn,.memory-popoverAIChatnow owns a_memoryIndicatorinstance;_updateTokenCounterbecomes
_updateMemoryIndicator, delegating all rendering to the widgetAdds
_reenableInput()helper so quota-exhausted disable is alwayspaired with a clean re-enable path (clear, null usage, or sub-100%)
Updates warning copy to reference "conversation memory" instead of
"token limit"
Extends
AIChat.spec.jsand addsMemoryIndicator.spec.js/ integrationsuite covering hide/show gating, quota exhaustion, destroy-race guard,
and null-usage re-enable
JIRA: BGSOFUIPIRIN-7101