Repository navigation
fix(apollo-react): give each chat service its own internal event bus - #1295
BenGSchulz wants to merge 1 commit into
Conversation
Dependency License Review
License distribution
Excluded packages
|
📊 Coverage + size by packagePer-package coverage and bundle size on this PR. New-line coverage = of the source lines this PR adds or changes, the % hit by tests.
"Coverage" is each package's own |
AutopilotChatInternalService was a page-wide singleton, so two chat instances saw each other's theme, locale, toggle and local-history events. Each AutopilotChatService now creates its own; the static Instantiate/Instance accessors stay for compatibility, deprecated. Adds AutopilotChatService.publish and uses it in place of the six `(chatService as any)._eventBus` casts, renames attachements-provider to attachments-provider, and adds tests for ChatService, EventBus and ContentPartBuilder. MST-16175 Co-Authored-By: Claude Opus 5.5 <[email protected]>
ae358c8 to
813b641
Compare
|
Apollo Coded App preview deployments are ready.
|
Summary
Isolates chat service instances and removes the
_eventBuscasts (story MST-16175).AutopilotChatInternalServicewas a page-wide singleton, so twoAutopilotChatServiceinstances saw each other's theme, locale, history/settings toggle and local-history events. Each service now creates its own. The staticInstantiate()/Instancestay for compatibility, marked deprecated (nothing in the repo used them).chatService.publish(event, data): a public method that replaces all six(chatService as any)._eventBuscasts (attachments, scroll load-more, custom header action, message actions, history load-more and search).attachements-provider→attachments-provider.AutopilotChatService(instantiate caching, instance isolation,publish,intercept),EventBus(subscribe, intercept, hijack, clear) andContentPartBuilder(none existed).Notes for reviewers
LocalHistoryServicesubscribes to each service's internal events, so one instance enablinguseLocalHistoryused to enable it for every instance on the page.theme-provideralready exposed onlythemeandisDark; no change.Verification
tscand lint cleanStack
Merge in order; each PR is based on the previous one.
Plan: https://uipath.atlassian.net/wiki/spaces/CLD/pages/91226013878
🤖 Generated with Claude Code