Skip to content

Bug: <callout> emoji and background-color/border-color attributes silently ignored #80

@charosen

Description

@charosen

Bug Description

When using docs +create with a <callout> block containing emoji, background-color, or border-color attributes, these attributes are silently ignored in the resulting Feishu document.

Expected behavior: Callout blocks should render with the specified emoji and colors.
Actual behavior: All attributes are ignored; callout renders with default 🎁 emoji and no background/border color.


Steps to Reproduce

  1. Run: lark-cli docs +create --title 'test' --markdown '<callout emoji="✅" background-color="light-green" border-color="green">test</callout>'
  2. Open the created document
  3. Observe that the callout has no color and shows 🎁 instead of ✅

Root Cause Analysis

Querying the document blocks via API after creation:

{
  "block_type": 19,
  "callout": {
    "emoji_id": "gift"  // ← should be the original emoji or a valid emoji_id
  },
  // background_color: MISSING
  // border_color: MISSING
}

Two issues identified:

  1. Emoji handling: The MCP markdown converter converts emoji characters (e.g. ✅) to their emoji name ("gift"), but Feishu API expects an emoji_id string like "24689_favorite" or the raw emoji character should be passed through.
  2. Color attributes: background-color and border-color attributes in <callout> tags are completely ignored and never sent to the Feishu API.

Test Document

A test document demonstrating the issue: https://www.feishu.cn/docx/HSwjdil66omz7PxgD6hcbpMtnUg


Environment

  • lark-cli version: 1.0.0
  • Platform: macOS (darwin/arm64)
  • Node.js version: v23.11.0
  • Shell: zsh

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions