Skip to content

fix(kimi-web): keep tool components from jumping on expand or collapse - #1433

Merged
liruifengv merged 5 commits into
mainfrom
fix-web-jump
Jul 6, 2026
Merged

fix(kimi-web): keep tool components from jumping on expand or collapse#1433
liruifengv merged 5 commits into
mainfrom
fix-web-jump

Conversation

@liruifengv

Copy link
Copy Markdown
Collaborator

Related Issue

No related issue.

Problem

In the web chat, expanding or collapsing tool components (tool-call groups and individual tool rows) made the conversation jump. The scroll-to-bottom button also only appeared when new messages arrived, so scrolling up through history offered no way back to the latest message, and tools without a dedicated glyph (such as media reads) rendered with a blank where the icon should be.

What changed

  • Collapsible tool bodies now animate with a grid-template-rows: minmax(0, 0fr) to minmax(0, 1fr) transition instead of height: auto, so the expand/collapse is smooth across browsers rather than snapping where interpolate-size is unsupported.
  • Auto-follow no longer snaps to the tail on a pure expand/collapse resize, and a short scroll-anchoring pass pins the toggled row in place during the transition, so the row stays put while its body opens downward or collapses upward.
  • The scroll-to-bottom button now appears whenever the conversation is scrolled up, not only on new content.
  • Added a generic fallback tool icon so tools without a dedicated glyph no longer render blank.

Checklist

  • I have read the CONTRIBUTING document.
  • I have linked a related issue, or explained the problem above.
  • I have added tests that prove my feature works. (The web app has no component test harness; verified manually in the browser.)
  • Ran gen-changesets skill, or this PR needs no changeset.
  • Ran gen-docs skill, or this PR needs no doc update.

Also show the scroll-to-bottom button whenever scrolled up, and render a
fallback icon for tools without a dedicated glyph.
@changeset-bot

changeset-bot Bot commented Jul 6, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: af1b5c3

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@moonshot-ai/kimi-code Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pkg-pr-new

pkg-pr-new Bot commented Jul 6, 2026

Copy link
Copy Markdown
pnpm dlx https://pkg.pr.new/@moonshot-ai/kimi-code@af1b5c3
npx https://pkg.pr.new/@moonshot-ai/kimi-code@af1b5c3

commit: af1b5c3

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9592739e51

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread apps/kimi-web/src/components/chat/ConversationPane.vue Outdated
Late-loading media can grow after scrollKey has run; keep chasing the
bottom on content growth, and only suppress follow during the pinned
expand/collapse window.
@liruifengv

Copy link
Copy Markdown
Collaborator Author

@codex

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ac915b6da3

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread apps/kimi-web/src/components/chat/ConversationPane.vue
@liruifengv
liruifengv merged commit ac5b5e4 into main Jul 6, 2026
10 checks passed
@liruifengv
liruifengv deleted the fix-web-jump branch July 6, 2026 14:19
This was referenced Jul 6, 2026
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.

1 participant