feat(slides):update xsd - #2067
Conversation
📝 WalkthroughWalkthroughThe slides XML schema updates typography, list semantics, inline formulas and fields, image cropping, table documentation, and chart styling. Chart definitions add gradients and separate global configuration from series-level line and area configuration. ChangesSlides XML schema updates
Estimated code review effort: 4 (Complex) | ~45 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🧹 Nitpick comments (1)
skills/lark-slides/references/slides_xml_schema_definition.xml (1)
2691-2717: 🗄️ Data Integrity & Integration | 🔵 Trivial | ⚡ Quick winConstrain
gradientMethodand document the geometry defaults.
gradientMethodis a free-formxs:stringin a schema that enumerates every other style option, so nothing prevents unsupported values reaching renderers. Likewisex0/y0/x1/y1(linear) andr0/r1(radial) are all optional with no documented default or coordinate space, and XSD 1.0 can't express the conditional requirement — spell out the omitted-value behavior in the documentation so authors and renderers agree.🤖 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_xml_schema_definition.xml` around lines 2691 - 2717, Update ChartGradientType by replacing the free-form gradientMethod xs:string with the schema’s existing constrained type for supported gradient interpolation methods, if available. Expand its xs:documentation to define the coordinate space and defaults for omitted x0/y0/x1/y1 and r0/r1 values, while noting which geometry attributes apply to linear versus radial gradients.
🤖 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_xml_schema_definition.xml`:
- Around line 907-911: Escape the four crop example elements within the
surrounding xs:documentation block so they are preserved as literal
documentation text rather than parsed child nodes. Update only the examples
beginning with the default crop usage and the top, left, and rect/presetHandlers
variants, keeping their displayed Chinese descriptions unchanged.
- Around line 1732-1743: Update the field complexType content model to accept
the same inline children as the other updated inline containers, including br,
formula, and field, while preserving its required type attribute. Ensure the p
documentation’s self-nesting statement matches the resulting field support,
either by enabling field self-nesting through the schema or excluding field from
that statement.
---
Nitpick comments:
In `@skills/lark-slides/references/slides_xml_schema_definition.xml`:
- Around line 2691-2717: Update ChartGradientType by replacing the free-form
gradientMethod xs:string with the schema’s existing constrained type for
supported gradient interpolation methods, if available. Expand its
xs:documentation to define the coordinate space and defaults for omitted
x0/y0/x1/y1 and r0/r1 values, while noting which geometry attributes apply to
linear versus radial gradients.
🪄 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 Plus
Run ID: cbb7a803-f9df-406b-8ba7-ccf31948b3f0
📒 Files selected for processing (1)
skills/lark-slides/references/slides_xml_schema_definition.xml
🚀 PR Preview Install Guide🧰 CLI updatenpm i -g https://pkg.pr.new/larksuite/cli/@larksuite/cli@6503eb428a35cd2018db31e99b00eb48bb7e22ec🧩 Skill updatenpx skills add larksuite/cli#feat/update_xsd -y -g |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #2067 +/- ##
==========================================
+ Coverage 75.14% 75.16% +0.01%
==========================================
Files 911 912 +1
Lines 96322 96451 +129
==========================================
+ Hits 72385 72495 +110
- Misses 18370 18380 +10
- Partials 5567 5576 +9 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
fangshuyu-768
left a comment
There was a problem hiding this comment.
I validated the updated XSD with positive and negative instances. The schema is well-formed and compiles, but the inline contract issues below are still reproducible on the current head.
Summary
Updates the Slides XML Schema Definition (XSD).
Changes
skills/lark-slides/references/slides_xml_schema_definition.xmlTest Plan
Related Issues
Summary by CodeRabbit