Automattic / Automattic/jetpack

AI Assistant: autoscroll won't stop on block follow-up completions

Open
#36,886 1 comment 2 reactions 0 assignees View on GitHub
[Block] AI Assistant [Plugin] Jetpack [Pri] Normal [Status] Stale Bug Triaged
Dominant language
PHP
Stars
1.8k
Forks
898
Avg merge
1d 18h
Merged PRs (30d)
774

Description

The autoscroll is not working well when the request being completed is a follow-up to a previous one.

Steps to reproduce:

- add an AI Assistant block and ask for a long completion (longer than the height available, for example: "10 paragraphs about the history of France")
- when the completion is done, perform a follow-up request; for example, change the tone to "Passionate"

Expected behavior:

- the autoscroll keep scrolling to show the last parts of the completion
- any scroll event from the user disables the autoscroll

Observed behavior:

- the last 2 or 3 lines of the completion are hidden behind the AI Assistant input bar
- user scrolls don't stop the autoscroll
- video:

https://github.com/Automattic/jetpack/assets/6760046/ff62a937-41c1-4554-869e-f73ec8913d73

Contributor guide

Open the contributing guide

Research direction

Reproduce the issue in the AI Assistant block using a long completion followed by a tone-changing follow-up. Start by tracing the block's completion autoscroll and user-scroll handling; done means the final lines remain visible and any user scroll disables autoscroll during follow-up completions.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, react
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.