Skip to content

feat(slides): add slides chart demo reference#1769

Merged
ethan-zhx merged 2 commits into
mainfrom
feat/slides_chart_demo
Jul 9, 2026
Merged

feat(slides): add slides chart demo reference#1769
ethan-zhx merged 2 commits into
mainfrom
feat/slides_chart_demo

Conversation

@ethan-zhx

@ethan-zhx ethan-zhx commented Jul 6, 2026

Copy link
Copy Markdown
Collaborator

Summary

Add a lark-slides chart demo reference and point the XML format guide to it so agents have a concrete chart XML example to follow.

Changes

  • Add slides_chart_demo.xml covering native chart examples and SVG-backed whiteboard chart examples.
  • Update xml-format-guide.md with a link to the full demo and a compact column chart snippet.

Test Plan

  • Unit tests pass
  • Manual local verification confirms the lark-cli <domain> <command> flow works as expected

Not run. This is a documentation/reference-only change, and no build or test command was requested for this turn.

Related Issues

  • None

Summary by CodeRabbit

  • Documentation
    • Added a comprehensive slide chart demo reference showcasing a full range of native chart types and advanced variants (including combo/radar and special “others” visuals) for style comparison.
    • Expanded the XML format guide with a complete combo chart example and clarified guidance wording.
    • Refined whiteboard guidance to more precisely separate when to use native charts vs non-native diagrams, including tighter SVG visual-quality and coordinate advice.
    • Updated schema, quick reference, and asset/planning contracts (including a new optional chart_contract field and stricter native <chart> fallback rules).

@github-actions github-actions Bot added the size/M Single-domain feat or fix with limited business impact label Jul 6, 2026
@coderabbitai

coderabbitai Bot commented Jul 6, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

This PR adds a chart demo slide deck and updates planning and reference docs to route supported standard charts to native <chart> output, with corresponding changes to whiteboard, Mermaid, and SVG guidance.

Changes

Chart demo and rendering guidance

Layer / File(s) Summary
Chart demo deck and combo example
skills/lark-slides/references/slides_chart_demo.xml, skills/lark-slides/references/xml-format-guide.md
Creates a slide deck XML covering multiple chart families and adds a full combo chart XML example to the format guide.
Chart contract planning
skills/lark-slides/references/planning-layer.md
Adds chart_contract planning fields and rules for native <chart> generation and chart data sources.
Asset planning fallback rules
skills/lark-slides/references/asset-planning.md
Updates fallback planning so supported standard charts use native <chart> rendering and unsupported chart types use other XML-native visuals.
Whiteboard routing and schema notes
skills/lark-slides/references/lark-slides-whiteboard.md, skills/lark-slides/references/slides_xml_schema_definition.xml, skills/lark-slides/references/xml-schema-quick-ref.md
Refines chart-versus-whiteboard guidance and updates Mermaid/SVG notes in schema and quick reference docs.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Possibly related PRs

  • larksuite/cli#1029: Updates the same slide-generation guidance for <whiteboard> vs native <chart> and related planning docs.
  • larksuite/cli#1097: Also adjusts whiteboard rendering selection and SVG/Mermaid guidance for slide content.

Suggested labels: size/L

Suggested reviewers: fangshuyu-768

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title is concise and accurately describes the main change: adding a slides chart demo reference.
Description check ✅ Passed The description follows the template and includes summary, changes, test plan, and related issues.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/slides_chart_demo

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai 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.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@skills/lark-slides/references/slides_chart_demo.xml`:
- Line 1: The whiteboard demo slots are empty self-closing placeholders, so the
scatter, bubble, funnel, pareto, waterfall, and combo examples render as blank
cards. Update the `<whiteboard>` instances in slides_chart_demo.xml to include
the actual SVG/Mermaid payloads for those charts, using the existing whiteboard
elements as the locators. For the combo example, either populate it with a real
whiteboard payload or replace it with a native `<chart>` example, since combo is
already supported by the chart contract.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 7c8517b1-c16a-4601-a4ef-2b86c5b67dbb

📥 Commits

Reviewing files that changed from the base of the PR and between 91d785f and 1b7f01f.

📒 Files selected for processing (2)
  • skills/lark-slides/references/slides_chart_demo.xml
  • skills/lark-slides/references/xml-format-guide.md

Comment thread skills/lark-slides/references/slides_chart_demo.xml Outdated
@github-actions

github-actions Bot commented Jul 6, 2026

Copy link
Copy Markdown

🚀 PR Preview Install Guide

🧰 CLI update

npm i -g https://pkg.pr.new/larksuite/cli/@larksuite/cli@9158d8820b0b8a7759d5e71d637086b02a069b20

🧩 Skill update

npx skills add larksuite/cli#feat/slides_chart_demo -y -g

@codecov

codecov Bot commented Jul 6, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 74.44%. Comparing base (74d8458) to head (9158d88).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1769   +/-   ##
=======================================
  Coverage   74.44%   74.44%           
=======================================
  Files         860      860           
  Lines       89859    89859           
=======================================
  Hits        66897    66897           
  Misses      17778    17778           
  Partials     5184     5184           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@ethan-zhx
ethan-zhx force-pushed the feat/slides_chart_demo branch from 1b7f01f to c5eb6e7 Compare July 7, 2026 09:43

@coderabbitai coderabbitai 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.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
skills/lark-slides/references/slides_chart_demo.xml (1)

2-2: 🎯 Functional Correctness | 🔴 Critical | ⚡ Quick win

Remove the stray trailing 2.
A literal 2 after </presentation> makes the XML malformed and will break parsing/loading.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@skills/lark-slides/references/slides_chart_demo.xml` at line 2, Remove the
stray trailing literal after the closing presentation tag in the
slides_chart_demo XML so the document remains well-formed and parsable. Update
the presentation markup to end cleanly at the closing tag, and verify there are
no extra characters appended after the root element.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@skills/lark-slides/references/lark-slides-whiteboard.md`:
- Around line 64-71: The model-path table in the whiteboard reference is too
broad: scatter and funnel visuals must stay on the SVG route and should not be
redirected to Mermaid for any model. Update the guidance around the third step
and the model mapping so that scatter/funnel remain explicitly included in the
SVG path, while only truly Mermaid-friendly decorative/diagram cases use Mermaid
for lower-capability models. Keep the fix anchored in the
“第三步:非原生图表与装饰元素按模型身份选路径” section and the model identity table.

---

Outside diff comments:
In `@skills/lark-slides/references/slides_chart_demo.xml`:
- Line 2: Remove the stray trailing literal after the closing presentation tag
in the slides_chart_demo XML so the document remains well-formed and parsable.
Update the presentation markup to end cleanly at the closing tag, and verify
there are no extra characters appended after the root element.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 93d6ba1c-98c1-4e82-9fc9-0d39ed3ac2eb

📥 Commits

Reviewing files that changed from the base of the PR and between 1b7f01f and c5eb6e7.

📒 Files selected for processing (5)
  • skills/lark-slides/references/lark-slides-whiteboard.md
  • skills/lark-slides/references/slides_chart_demo.xml
  • skills/lark-slides/references/slides_xml_schema_definition.xml
  • skills/lark-slides/references/xml-format-guide.md
  • skills/lark-slides/references/xml-schema-quick-ref.md
✅ Files skipped from review due to trivial changes (3)
  • skills/lark-slides/references/xml-schema-quick-ref.md
  • skills/lark-slides/references/slides_xml_schema_definition.xml
  • skills/lark-slides/references/xml-format-guide.md

Comment thread skills/lark-slides/references/lark-slides-whiteboard.md
@ethan-zhx
ethan-zhx force-pushed the feat/slides_chart_demo branch from c5eb6e7 to 9158d88 Compare July 9, 2026 07:38

@coderabbitai coderabbitai 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.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@skills/lark-slides/references/planning-layer.md`:
- Around line 124-148: The chart contract definition is incomplete because it
only requires chartData, but native chart generation also needs chartPlotArea.
Update the planning-layer guidance around chart_contract so the required shape
explicitly includes chartPlotArea, or clearly state in the chart_contract
instructions that XML generation always synthesizes chartPlotArea for native
charts. Reference the chart_contract section and the chart generation rules that
mandate a <chart> element when required.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 1014a062-6da3-4b44-9fb0-02a36cd323ce

📥 Commits

Reviewing files that changed from the base of the PR and between c5eb6e7 and 9158d88.

📒 Files selected for processing (7)
  • skills/lark-slides/references/asset-planning.md
  • skills/lark-slides/references/lark-slides-whiteboard.md
  • skills/lark-slides/references/planning-layer.md
  • skills/lark-slides/references/slides_chart_demo.xml
  • skills/lark-slides/references/slides_xml_schema_definition.xml
  • skills/lark-slides/references/xml-format-guide.md
  • skills/lark-slides/references/xml-schema-quick-ref.md
✅ Files skipped from review due to trivial changes (3)
  • skills/lark-slides/references/xml-schema-quick-ref.md
  • skills/lark-slides/references/slides_xml_schema_definition.xml
  • skills/lark-slides/references/xml-format-guide.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • skills/lark-slides/references/slides_chart_demo.xml

Comment thread skills/lark-slides/references/planning-layer.md
@ethan-zhx
ethan-zhx merged commit d87d9b4 into main Jul 9, 2026
40 checks passed
@ethan-zhx
ethan-zhx deleted the feat/slides_chart_demo branch July 9, 2026 08:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/M Single-domain feat or fix with limited business impact

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants