#3568246: fix late chatbot opening on page load

Persist chatbot open state in backend instead of localStorage to ensure it’s applied during initial render and prevent layout shift.

localStorage + JS only runs after the page has loaded, so it will always cause a shift.

Testing Instructions

  1. Create an Assistant at /admin/config/ai/ai-assistant
  2. Place the AI DeepChat Chatbot block at /admin/structure/block/list/gin
  3. Make sure the Placement field under Styling settings is set to Toolbar
  4. Open the chatbot using the Chatbot opener button on the top left
  5. Once opened, refresh the page -> check that the chatbot does not re-open but the page is rather rendered with the appropriate spacing already reserved
Edited by Bruno Bruno

Merge request reports

Loading