[WEB-4296] fix: enforce remounting of inkeep search bar#2504
[WEB-4296] fix: enforce remounting of inkeep search bar#2504kennethkalmer merged 1 commit intomainfrom
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
m-hulbert
left a comment
There was a problem hiding this comment.
Tested locally and LGTM!
kennethkalmer
left a comment
There was a problem hiding this comment.
Plenty good for the moment. I wonder if this isn't something to be reworked (later) into gatsby-browser.tsx and using the lifecycle functions available to us there...
There's a bug where the inkeep search bar dies between templates. Never used to be the case, but now it is.
The surrounding inkeep instantiation logic is called on template change, but the search bar does not reinitialise. Perhaps there is a flag stored somewhere that prevents this.
My first approach would be to, within this inkeep logic, check for if
#inkeep-searchhas child nodes and then remount from there if not, but the instantiation is async and there is no promise to latch onto, so I'm just going to remount every time. Suboptimal, but seems to do the job and there's no time for anything else.Initial thread: https://ably-real-time.slack.com/archives/C01LR5XFHFX/p1743429479133079