* feat: Derive the Chat Pane's Heading, Footers, Project and Read-Only State in @librechat/chat
* refactor: Lay Out the Chat View Through the Package ChatScreen
* feat: Add a Hint Variant to Button
* refactor: Move the Ask Question Popover Into the Chat Package
* fix: Keep the Ask Hint's Hover Ink
* fix: Return Focus to the Draft When the Ask Chevron Moves the Question
* test: Exercise the Real Composer Overlay Hook in the Ask Popover Spec
* refactor: Move the Prompts Popover Into the Chat Package
* test: Check Dialog Focus Without Querying the Hidden Composer
* fix: Keep the Search Typed After the Slash When the Prompts Popover Opens
* refactor: Move the Subagent Transcript Into @librechat/chat Behind a Subagents Host
SubagentActivity, its scroll surface, content, status and guidance history
move into @librechat/chat/components, and ScrollToBottom moves into the
package with them. A new SubagentsHost carries what still lives in the app:
the content-parts and steer renderers, the animated jump-to-latest control,
and the read of a shortened guidance receipt, which stays an app query. The
prompt preview reuses renderMarkdown with a new codeExecution flag, and the
task content scope becomes a plain package context.
* refactor: Draw Content Parts Through the Message Parts Host
renderContentParts moves from SubagentsHost onto MessagePartsHost as the one
content slot, typed as ContentPartsSlotProps: the transcript fields plus the
optional row fields message rows pass. The app fills it through a registered
renderer, so the host module does not import the content stack, and omitted
row fields keep an assistant reply's defaults.
* refactor: Let the Content Parts Slot Carry Sparse Content
Main message rows keep holes at streaming and parallel indexes, and part indexes depend on those positions, so the slot's content keeps undefined entries as ContentParts already accepts them.
* test: Exercise the Real App Renderers in the Host Registration Spec
The transcript host test now renders the app's ContentParts and SteerPart under the providers they read, so the registered content renderer and steer slot are proven against the real components; only the receipt request stays mocked.
The chat surface context, the durable task panel hook and the event subagent
activity group move into the package. The surface context and read hooks live
apart from the provider that binds the panel atoms, so the components entry
loads no module-scope atom. Share state and the inline agent avatar reach the
package through two new MessagePartsHost members, useShare and
renderAgentAvatar, which the app fills from ShareContext and renderAgentAvatar
with the same options as before.
* refactor: Move Subagent Authors Into @librechat/chat Behind a Message Icon Slot
* fix: Register the Message Parts Host From the App Entry
* test: Give the Consumer Spec's Messages Host the Icon Slot
* refactor: Move Ask State, Approval and File Previews, and Diff View Into the Chat Package
* fix: Point the HITL Edits Spec at the Moved Approval Preview
* refactor: Add a Command Popover with a Host Windowed List Slot
* refactor: Move the Mention Popover Into the Chat Package
* test: Cover the Mention Popover Combobox in the Mock Harness
* style: Draw the Mention Popover Like the Prompts and Skills Popovers
* test: Walk to the Endpoint Row Before Drilling Into Its Models
* test: Drill Into a Plain Custom Endpoint in the Mention Scenario
* refactor: Share the Command Character Helper From the Chat Core
* refactor: Move the MessagesView Root Into @librechat/chat
* fix: Read Submitting State From the Chat Contract and Complete the Test Hosts
* test: Tell the Scroll Control Apart From the Rail's End Marker
* feat: Add a ChatPane Layout to @librechat/chat
* refactor: Lay Out the Chat View Through the Package ChatPane
* fix: Keep the Welcome Layout While a New Session Loads
* style: Sort the Chat View Imports
* refactor: Move the Fork and Feedback Actions into @librechat/chat
Fork reads the viewer's fork defaults and starts the fork through two new
MessagesHost members, keeping its toasts and rate-limit copy in the package; the
app supplies them from its settings atoms and the fork mutation, whose own
callbacks open the copy so a row that unmounts mid-request still lands there.
Feedback moves as is. @ariakit/react becomes a peer dependency of the package.
* test: Cover Fork and Feedback in the Mock Harness
* chore: Sort MessageRow Spec Imports
* fix: Resolve Fork Labels Per Call and Pin the Fork Toast Locator
* test: Give the Consumer Spec Messages Host the Fork Members
* fix: End an Answer's Claim Only When Its Generation Ends or a Newer Pause Replaces It
* fix: Match a Stop to the Answered Generation by Its Record When No Timestamp Names It
* fix: Date an Undated Answer by the Pause a Later Source Reports
* refactor: Move Composer Input Controls and Shortcut Helpers Into @librechat/chat
* test: Cover Interrupt Now on a Queued Composer Row
* test: Read the Moved Escalate Button in the Composer Color Guardrail
* refactor: Reuse the Core Draft Check for the Send Button
* fix: Point the Acceptance Harness at the Moved Composer Shortcuts
* refactor: Move resume-on-load and the stream steer state into the chat package
* refactor: Drop the useSessionEffects bridge now that resume on load lives in the chat package
splitMarkdown and editableParts move to packages/chat/src/core/parts and are
exported from the package root, so hasEditablePart is available to package
components. The micromark and mdast packages the splitter parses with become
peer and dev dependencies of @librechat/chat at the client's ranges, kept
external by the build, and the package jest config transforms them like the
client's does.
* feat: Retire Expired and Older Pauses and Reconcile the Held Pause With Sync Snapshots
* fix: Let an Expired Pause Retire the Held One It Ties
* fix: Hold a Pause the Sync Frame Buffers and Follow an Answer Whose Pause a Snapshot Released
* fix: Keep a Stale Buffered Pause Out of the Host Reducer
* fix: Retire a Released Pause When Its Generation Ends
* fix: Let Only the Pause a Sync Frame Stands for Reach the Host Reducer
* feat: Answer, Restore and Stop a Paused Generation From the Chat Core
* fix: Retire a Pause the Server Refused Once Its Probe Owns the Chat
* fix: Keep a Pause the Server Refused Over for Later Reads and Replays
* feat: Reattach to a Running Generation and Keep a Dropped One Stoppable
* fix: Keep a Continued Generation's Endpoint When the Host Selection Changes
* fix: End What a Dropped Generation Leaves When a Retry, a Stop or a Status Read Settles It
* test: Cover a Reattachment That Yields to a Turn the Host Starts While It Selects the Endpoint
* fix: Settle What a Reconnect Answers for and Let It Go Before a Store Is Told
* fix: Return a Failed Chat to Ready as One Write
* refactor: Move Subagent Progress State and Content Folding Into @librechat/chat
* refactor: Attach the Subagent Activity Feed Through the Chat Transport
* test: Tag the Subagent Activity Panel E2E Specs With Scenarios
* test: Pin Replay, Ready and Live Steer Ordering Across an Activity Reconnect
* fix: Stop the Subagent Activity Feed on Refusals and Bound Idle Reconnects
* fix: Keep Attaching the Subagent Feed While the Child Thread Is Still Reserved
* test: Read Steer Order the Same While the Child Turn Streams and Once It Settles
* refactor: Move Composer Attachment Components Into @librechat/chat
* test: Cover the Pasted Text Editor From Paste to Saved Edit
* test: Keep the Real Data Provider Enums in the ChatView Subagent Spec
* refactor: Build the Source Badge Styles at Render Time
* test: Reopen the Pasted Text Correction From Its Replacement Chip
* chore: Re-record the Attachment Design Suppressions on Dev
* test: Merge the SteerPart Package Mocks Into One Factory
* feat: Stop the Turn in Flight From the Chat Core
* fix: Adopt the Conversation a Late Stream's Stop Names and Record a Replacement Before Its Rollback Notifies
* refactor: Move Tool Disclosure State and Leaf Part Components Into @librechat/chat
Disclosure contexts and atoms, tool intent labels, useRowHandoff and
useFollowScroll move to packages/chat/src/react/parts (exported from
@librechat/chat/react); CancelledIcon, InProgressCall, AuthorHeader, Stdout,
BareStatus and the row class constants move to
packages/chat/src/components/parts (exported from @librechat/chat/components).
Disclosure reads the package host, and ToolContentQuery is declared from
data-provider and react-query types. The AuthorHeader and useFollowScroll specs
move with their modules.
* test: Cover the Author Header That Resumes After a Steer
* test: Keep the Package Entry Intact When Mocking AuthorHeader
* refactor: Move Pure Part Helpers Into @librechat/chat
Tool output parsers (JSON fields, background handles, wakeups, background
tasks, command results) and the small routing, params and rerun helpers move
from client Content/ into packages/chat/src/core/parts, exported from the
package root. Client importers read them from @librechat/chat; parseJsonField
becomes a named export so the root barrel can carry it.
* test: Cover Wake-Up Turns Rendering as Task Cards
* fix: Point the API Background Spec at the Moved Parsers
* feat: Add a Minimal Consumer Example for @librechat/chat
A Vite React page under packages/chat/example renders a themed chat from the package's public entries and the @librechat/client theme, with an in-memory transport standing in for the server. Its jsdom smoke test runs in the package's jest suite, the package typecheck covers it, and ESLint keeps it to public imports and semantic theme roles.
* fix: Let Enter Confirm an IME Composition in the Example Composer
* fix: Report a Failed Turn in the Example and Restore Its Text
* fix: Localize the Example Copy and Guard the Safari IME Enter
* fix: Drop a Rejected Turn, Load the Component CSS, and Keep the i18n Instance in the Example Build
* refactor: Replace the Example App With a Public-Entry Consumer Spec
The owner does not want an example app in the repository. packages/chat/test/consumer.spec.tsx keeps what it proved: a chat built only from @librechat/chat, /react, /components and @librechat/client, over an in-memory transport, streams a reply into the message list under the ClickHouse theme. It sits outside src because chat/boundary rejects self-imports there; jest maps the entry names to the sources and the package typecheck covers it. The example app, its Vite, Tailwind and PostCSS config, its lint block, script and dependency lines are removed.
* chore: Declare the Consumer Spec's i18next Dev Dependencies
* chore: Retest Against Current Dev
* feat: Reject Module-Load Use of Other Packages in the Chat Package
App specs mock whole packages (@librechat/client, librechat-data-provider), so a package module that calls into one or reads a member of one while it loads throws before any test runs. chat/boundary now reports a call, new, tagged template or member read through an external import at module scope in packages/chat/src outside specs; React and Jotai are exempt through a loadSafe option.
* fix: Count Immediately Invoked Functions and Computed Field Keys as Module Load
* fix: See Through Erased TypeScript Wrappers in the Module-Load Check
* fix: Count Destructuring, Spreads and Wrapped IIFEs as Module-Load Reads
* refactor: Judge Every Load-Time Reference to an External Import
The check now walks each external import's references once and reports any that runs on load outside an inert position, instead of listing the node types that read an import. Class heritage, in, instanceof and iteration are reported with no new visitor.
* fix: Follow Branches to Their Consumer and Skip Erased Heritage Types
* fix: Count Constructed Classes and Destructuring Assignments as Module Load
* fix: Count Constructors of Constructed Classes and Branch-Fed IIFEs as Module Load
* fix: Follow Const Aliases of External Imports in the Module-Load Check
* fix: Find Aliases Behind Wrappers and Branches
* fix: Track require Bindings, Skip Writes and Defer Generator Bodies in the Module-Load Check
* fix: Follow Assignment Aliases of External Imports
* fix: Collect require Bindings From Exported Declarations
* refactor: Cover Module-Load Failures With a Mocked-Dependency Load Spec
A packages/chat spec now loads the index, react and components entries with every package the sources import (React and Jotai aside) mocked to a module whose exports are missing, the way an app spec's factory mock leaves it, and asserts nothing throws. That covers aliases, require, invoked functions and the rest at runtime, so chat/boundary keeps only the plain case: a call, new, tagged template or member read through a direct import binding at module scope.
* chore: Retest Against Current Dev
* fix: Exempt Spec Support Files and Node Built-ins From the Module-Load Check
* refactor: Move Message Row and Timestamp into @librechat/chat
Add a MessagesHost the message list reads the viewer's clock format and row
slots from, registered by the app at load, and move MessageRow,
MessageTimestamp, the row width helper, the timestamp formatters and the
minute ticker into the package with their specs. The user attachments a row
shows reach it through the host's files slot until they move.
* test: Cover Message Rows on Chat and Shared Routes
* chore: Prepare the Chat Package for Message Components
Give packages/chat a lint-only Tailwind entry so the design rules resolve the
library's theme utilities, allow the app status selectors its components carry,
expose the active language from @librechat/client, and let the locale check
accept keys that resolve through plural forms.
* refactor: Move Message Row Leaves into @librechat/chat
Move the hover style helpers, SubRow, SiblingSwitch, the elapsed timer with its
duration labels, HeaderLabel and the system event header into
packages/chat/src/components/messages, export them from
@librechat/chat/components, and point the client at the package.
* test: Cover Message Row Leaves in the Mock Harness
* chore: Drop the Chat Lint Entry in Favor of components.json
* test: Run the Elapsed Spec Against the Package
* test: Pin the Chat Lifecycle as a State and Event Table
* feat: Count Chat Changes and Let a Host Replace the Message List
* fix: Run No Message Updater Once the Chat Is Disposed
* test: Keep a Host Write Through the Rollback of a Replaced Start
* feat: Bind the Core Chat to React With useCoreChat
* fix: Keep Untouched Rows and the Learned Conversation in useCoreChat Writes
setMessages kept every stored row only by value, recreating the ones its views left as they were, so the rollback of a replaced start treated the turn's own rows as host edits and kept them. A view that is still the one the stored row produced now keeps that row as is. New rows were also filed under chat.id, which stays 'new' after the server creates the conversation; Chat now exposes the conversation it runs under and setMessages uses it.
* fix: Keep the Turn Rows Above an Edited Turn Row When a Replaced Start Rolls Back
Rolling back a replaced start kept a turn row someone else had edited but removed the turn rows above it, so the kept response lost its parent and the message tree filed it as a second root. Undo now keeps every row the turn added on the path from a kept turn row to the rows before the turn.
* fix: Keep the Turn Rows Above Any Row a Replaced Start's Rollback Keeps
A row another writer appended under the turn's response survived the rollback of a replaced start while the turn rows above it went, leaving it without a parent. Undo now keeps the rows the write added on the path above every row it keeps, whoever wrote that row. Test fixtures that gave a pre-existing row the turn's user message as its parent now chain to each other.
* fix: Stop a Stream Event Once a Listener Disposed the Chat on Its Streaming Status
The first content frame or pause moves the chat to streaming and tells its listeners, and one that disposed the chat there still had the event delivered to the host's onEvent. The event now stops when that notification released the chat.
* fix: Publish a Turn's Terminal State as One Write
A store that reports each status or connection write let a listener start the next turn as the connection went idle, and the status and error written after it then overwrote that turn's submitted state. The terminal fields are now written together with the store's own reports held back, and listeners are told once they are all set.
* fix: Leave the Next Turn's State Alone When a Store Subscriber Starts It Mid-Publish
A store subscriber told the connection went idle can start the next turn while the finished one is still publishing, and the finished turn then wrote its ready or error status and error over the new turn's submitted state. Publishing stops writing those fields once another turn holds the chat.
* fix: Advance the Snapshot Version When a Host Store Moved Unheard
A version read taken by another consumer after a host store write, but before any subscription heard it, moved the counted baseline to the new list without moving the version, so the consumer that rendered the old list was never told. A host store list that differs from the counted one now counts as a change the version moves past.
* fix: Count a Cache Write No Subscription Heard by Its Write Time
With every listener unsubscribed, a reset followed by a write of the same array restored the counted write count, so the version stayed put while the content changed. The cache's write time moves on every write, so a changed one now counts as a change too.
* refactor: Add the Core Chat Class With a Serial Job Executor and React Query State
* fix: Report an Attachment's HTTP Failure as a Disconnect and the Turn's Conversation on Finish
* fix: Report a Stream That Fails While It Is Read as a Disconnect
* fix: Keep an Attachment Failure a Disconnect When the Host Reducer Throws on It
* fix: Treat a Resumed Start as an Attachment and Drop a Replaced Start's Optimistic Rows
* fix: Undo the Whole Optimistic Write of a Start the Server Replaced
* fix: Give Each Optimistic Write One Rollback Record and Stop a Disposed Chat Writing State
A turn keeps its optimistic write on the active request, so a disposal before the start was sent undoes those rows as a replaced start already did, and a removed row is restored next to its surviving neighbors instead of at its old index. A disposed chat no longer moves the shared status or connection, so a listener that disposes on a rollback notice cannot leave the state reconnecting. A start that fails with ERR_INTERNET_DISCONNECTED is a disconnect like ERR_NETWORK, and the React Query state rechecks a host store that changed between a version read and its subscription.
* fix: Roll Back the Rows a Store Committed, Not the Rows the Chat Handed It
A React Query cache with structural sharing commits a changed row as a copy, so a replaced start compared its rollback record against objects the cache never held and kept the optimistic edit. The record now takes the list as the state reads it back after the write.
* fix: Record the Optimistic Rows a Store Committed Before Telling Subscribers
A listener that writes the shared state when the chat announces its optimistic write no longer lands in that write's rollback record, so a replaced start keeps the listener's rows. The record is taken before anyone is notified, and a store's report of the chat's own write waits for the chat's announcement instead of running inside the write.
* fix: Stop a Stream Event Once a Listener Disposed the Chat on Its Write
A listener that disposes the chat while an event's write is announced no longer lets that event move the shared status to streaming or reach onEvent after teardown.
* fix: Scope Optimistic Rollback to the Rows the Write Itself Changed
The rollback record kept the whole list the store committed, so a row a store subscriber appended while the write was committed was undone with the turn, and a subscriber that disposed the chat inside the write left the turn's rows behind because no record existed yet. The record now holds, by message id, only the rows the write added, replaced or removed, each under the identity the store committed it with; undo restores or drops those and leaves every other row. A dispose inside the write is undone once the record exists.
* fix: Leave a Turn Row a Store Subscriber Edited Inside the Write Out of Its Rollback
A store that notifies its subscribers synchronously can hand back one of the turn's rows already edited by a subscriber, and the rollback of a replaced start then deleted or overwrote that edit. The record now claims a committed row only when it is the written row or a structural copy of it.