feat: make render window configurable via tui.renderWindow - #858
Merged
Conversation
Remove the MAX_RENDER_MESSAGES constant and data-layer message cap. The data layer now stores all messages without restriction. The render layer uses a local renderWindow variable (100) to keep the React tree bounded — only the last N messages are rendered as bubbles. Pub/sub topics for messages outside the render window are pruned to keep memory in check. Breaking: removed exported MAX_RENDER_MESSAGES constant from messageList.js. The render window is now a local implementation detail.
Add tui.renderWindow config option (default 100) that controls how
many messages are rendered as bubbles in the conversation panel.
The data layer stores all messages unrestricted; the render window
is a virtual view layer optimization.
Config flow: config.yaml → TuiSchema → app.js → ConversationPanel → MessageList
Users can now tune the render window size without touching code:
tui:
renderWindow: 200
The renderWindow value flows through the full config chain: config.yaml → TuiSchema → app.js → ConversationPanel → MessageList. The destructuring default was redundant and misleading.
The renderWindow value flows through the full config chain: config.yaml → TuiSchema → app.js → ConversationPanel → MessageList. The destructuring default was redundant and misleading.
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.
Description
Makes the message render window configurable via
tui.renderWindowin config.yaml (default: 100). Removes the hardcodedMAX_RENDER_MESSAGESconstant fromsrc/tui/messageList.jsand threads therenderWindowprop throughApp→ConversationPanel→MessageList. The data layer stores all messages without a cap; the render window keeps the React tree bounded while the ScrollView handles full conversation history scrolling.Type of Change
Testing
tests/unit/tui.test.js,tests/unit/messageListApi.test.js)Coverage
Checklist
npm run lintpassesCloses #856