openclaw - 💡(How to fix) Fix [Bug] Feishu streaming card does not auto-grow height — content above the viewport is clipped

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

When channels.feishu.renderMode: "card" and channels.feishu.streaming: true are enabled, the agent's reply streams character-by-character (typewriter effect works), but the card height is fixed (~200–400px). As the streamed content grows, characters above the initial viewport are clipped instead of the card extending downward. The user only sees the last visible line of the reply, and earlier content appears "lost" until the card is manually resized.

Root Cause

Root cause (from source code)

Fix Action

Fix / Workaround

  • Severity: Medium-High — agent replies appear truncated/lost
  • Affected: All Feishu users with renderMode: "card" + streaming: true + any reply longer than ~5 lines
  • Workaround: Set channels.feishu.streaming: false (loses the typewriter effect, falls back to whole-message at once)

Code Example

{
     "channels": {
       "feishu": {
         "enabled": true,
         "appId": "cli_...",
         "appSecret": "...",
         "streaming": true,
         "blockStreaming": false,
         "renderMode": "card"
       }
     }
   }

---

const cardJson = {
  schema: "2.0",
  config: {
    streaming_mode: true,
    summary: { content: "[Generating...]" },
    streaming_config: {
      print_frequency_ms: { default: 50 },
      print_step: { default: 1 }
    }
  },
  body: { elements }  // ← no height / wide_screen_mode / card_size set
};
RAW_BUFFERClick to expand / collapse

[Bug] Feishu streaming card does not auto-grow height — content above the viewport is clipped

Summary

When channels.feishu.renderMode: "card" and channels.feishu.streaming: true are enabled, the agent's reply streams character-by-character (typewriter effect works), but the card height is fixed (~200–400px). As the streamed content grows, characters above the initial viewport are clipped instead of the card extending downward. The user only sees the last visible line of the reply, and earlier content appears "lost" until the card is manually resized.

Steps to reproduce

  1. Set in ~/.openclaw/openclaw.json:

    {
      "channels": {
        "feishu": {
          "enabled": true,
          "appId": "cli_...",
          "appSecret": "...",
          "streaming": true,
          "blockStreaming": false,
          "renderMode": "card"
        }
      }
    }
  2. Send any DM longer than ~5 lines to the Feishu bot.

  3. Watch the reply card while it streams.

Expected behavior

The card should auto-grow to fit the streaming content. All characters generated by the agent should remain visible in the card body. This is the standard behavior of non-streaming Feishu cards (markdown elements auto-fit their content).

Actual behavior

  • Typewriter streaming works ✅
  • Card height is fixed to ~200–400px ❌
  • Content above the initial viewport is clipped (not just scrolled — there is no scrollbar)
  • The user only sees the last line(s) of the reply
  • Feels like content is "disappearing" — confusing UX

Root cause (from source code)

In dist/monitor.account-DZGcKei2.js (Feishu plugin, build of OpenClaw 2026.5.26), the streaming card is built like this:

const cardJson = {
  schema: "2.0",
  config: {
    streaming_mode: true,
    summary: { content: "[Generating...]" },
    streaming_config: {
      print_frequency_ms: { default: 50 },
      print_step: { default: 1 }
    }
  },
  body: { elements }  // ← no height / wide_screen_mode / card_size set
};

There is no height, no wide_screen_mode, no card_size, no max-height override on the body or the markdown element. The Feishu client therefore falls back to a small fixed card height when streaming_mode: true is active, and there is no scrollbar to recover the clipped content.

Impact

  • Severity: Medium-High — agent replies appear truncated/lost
  • Affected: All Feishu users with renderMode: "card" + streaming: true + any reply longer than ~5 lines
  • Workaround: Set channels.feishu.streaming: false (loses the typewriter effect, falls back to whole-message at once)

Environment

  • OpenClaw version: 2026.5.26
  • Feishu channel: default account (no accounts.* overrides)
  • Feishu client: macOS desktop 7.20+
  • macOS 25.5.0 (arm64)

Suggested fix

  1. In monitor.account-DZGcKei2.js, when building the streaming cardJson, either:
    • Add wide_screen_mode: true to body (gives the card more horizontal room, may help)
    • Or add a padding / direction: "vertical" hint to the body
    • Or wrap the markdown element in a scrollable container (e.g., <view><markdown ... /></view> with the view having min_height: "200px" and a scroll indicator)
  2. Verify with a reply of 20+ lines that the card extends to show all streamed content.

Related issues

  • #82417 — CardKit streaming card appends full accumulated text on each update (duplicate append, different bug)
  • #9447 — streaming messages truncated when response contains multiple blocks (different code path)
  • #33751 — streaming card content shows duplicate/appending text (different bug)
  • #33883 — blockStreaming causes 30+ duplicate message display (mobile)

Notes

  • Typewriter streaming itself works correctly (print_step: 1 in this build — good).
  • The bug is purely a layout/sizing issue: the content is being delivered fine, the card is just too short to show it.
  • I confirmed the root cause by reading the bundled dist file directly; the height fields are simply not set.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

The card should auto-grow to fit the streaming content. All characters generated by the agent should remain visible in the card body. This is the standard behavior of non-streaming Feishu cards (markdown elements auto-fit their content).

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING