Skip to content
This repository was archived by the owner on Jul 22, 2025. It is now read-only.

Commit bdb7484

Browse files
author
rngus2344
committed
DEV: Add appEvents trigger when Ai search results toggled
1 parent b6cefd1 commit bdb7484

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

assets/javascripts/discourse/components/ai-full-page-search.gjs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,8 +124,10 @@ export default class AiFullPageSearch extends Component {
124124
@action
125125
toggleAiResults() {
126126
if (this.showingAiResults) {
127+
this.appEvents.trigger("full-page-search:ai-results-toggled", {toggled: false});
127128
this.args.addSearchResults([], "topic_id");
128129
} else {
130+
this.appEvents.trigger("full-page-search:ai-results-toggled", {toggled: true});
129131
this.args.addSearchResults(this.AiResults, "topic_id");
130132
}
131133
this.showingAiResults = !this.showingAiResults;

0 commit comments

Comments
 (0)