Skip to content

fix(max): constrain chat composer height - #32

Open
lordspline wants to merge 2 commits into
masterfrom
capy/constrain-chat-composer-height
Open

fix(max): constrain chat composer height#32
lordspline wants to merge 2 commits into
masterfrom
capy/constrain-chat-composer-height

Conversation

@lordspline

@lordspline lordspline commented Aug 17, 2026

Copy link
Copy Markdown

Problem

People who paste long prompts into PostHog AI can lose the send controls below the viewport on compact screens.

Closes PostHog#62461

Changes

  • The textarea now caps its height responsively and scrolls long prompt content internally.
  • The composer stays within the viewport while queued messages scroll before displacing the input controls.
  • Short prompts retain their existing auto-growth behavior.
Viewport Textarea bottom Send control bottom Result
390 × 500 before 497 px 529 px Send control clipped
390 × 500 after 440 px 472 px Both controls visible
390 × 844 after 570 px 602 px Both controls visible
1366 × 768 after 527 px 559 px Both controls visible
1440 × 900 after 593 px 625 px Both controls visible
1440 × 900 panel after 657 px 689 px Both controls visible

Screenshots and a short demo are attached to the Capy handoff. This contributor account cannot publish to PostHog/pr-assets.

How did you test this code?

  • Focused Jest coverage catches composer overflow, Enter and Shift+Enter behavior, and disabled states.
  • Browser QA covered the main scene, sidebar panel, laptop, narrow, and compact narrow viewports.
  • Browser QA covered paste, internal scrolling, submission, autocomplete positioning, loading controls, and hands-free controls.
  • The frontend type check and hogli ci:preflight --fix pass locally.

Automatic notifications

  • Publish to changelog?

Docs update

None. This fixes existing composer layout behavior.

🤖 Agent context

Autonomy: Human-driven (agent-assisted)

Capy implemented and browser-tested this change. It used /writing-ui-components, /writing-tests, /qa-frontend, /running-ci-preflight, and /writing-pr-descriptions.

The test prompt and visual evidence use invented local data.


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.

@capy-ai
capy-ai Bot marked this pull request as ready for review August 17, 2026 23:33
@github-actions

github-actions Bot commented Aug 17, 2026

Copy link
Copy Markdown

🦔 Hogbox preview · ❌ build failed

The preview didn't come up for commit f04a372. See the build log for the failing step. It'll retry on the next push.

Previews are optional and never block merging. A failure here is often a hogland or tailnet hiccup rather than anything in your PR, so the check stays green and this comment is the status.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

AI chat input box blocks access to send button on long messages

1 participant