← 返回 Skills 市场
14
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install canvas-poster
功能描述
服务端海报生成引擎。基于 @napi-rs/canvas,声明式生成数据看板、战报、对比图等长图海报。 支持 KPI 卡片、柱状图、饼图、表格、建议卡片等 Section 类型。 当用户提到"生成海报"、"做看板"、"长图"、"数据可视化图"、"生成图表"时使用。 也供其他 Skill 作为依赖调用。
使用说明 (SKILL.md)
canvas-poster
服务端长图海报生成引擎,基于 @napi-rs/canvas。
快速开始
cd skills/canvas-poster && npm install
node examples/demo.js /tmp/my-poster.png
核心用法:Section DSL
const { buildPoster } = require('./lib/builder');
buildPoster({
width: 800,
header: {
bg: '#1e40af',
title: '📊 数据看板',
subtitle: '2026年3月',
},
sections: [
{
type: 'kpi-cards',
title: '📊 概览',
cards: [
{ label: '总费用', value: '¥92.2万', color: 'red' },
{ label: '人数', value: '745人' },
{ label: '人均', value: '¥1,238' },
{ label: '达成率', value: '87.2%', color: 'green' },
],
},
{
type: 'bar-chart',
title: '💼 费用结构',
bars: [
{ name: '住宿费', value: 380700, color: '#3b82f6' },
{ name: '交通费', value: 290000, color: '#22c55e' },
],
},
{
type: 'pie-chart',
title: '🗺️ 路线分布',
slices: [
{ name: '北京→武汉', value: 180000 },
{ name: '北京→上海', value: 120000 },
],
},
{
type: 'table',
title: '⚠️ 异常分析',
headers: ['部门', '异常金额', '占比'],
rows: [
['AI应用中心', '¥64,121', '7.0%'],
],
},
{
type: 'tips',
title: '💡 管理建议',
items: ['建议1', '建议2', '建议3'],
},
],
footer: '🦞 自动生成',
output: '/tmp/poster.png',
});
Section 类型
| 类型 | 说明 | 数据字段 |
|---|---|---|
kpi-cards |
KPI 卡片组(2×N 网格) | cards: [{label, value, color?, sub?}] |
bar-chart |
横向柱状图 | bars: [{name, value, color?, pct?}] |
pie-chart |
饼图/环图 + 图例 | slices: [{name, value, pct?}], donut?: boolean|number, center?: string |
line-chart |
折线图(多线+图例) | lines: [{name, data: number[], color?}], xLabels?: string[], showDots?: boolean, showLegend?: boolean |
area-chart |
面积图 | areas: [{name, data: number[], color?}], xLabels?: string[], opacity?: number, showDots?: boolean, showLegend?: boolean |
scatter-chart |
散点图 | points: [{x, y, color?}], dotRadius?: number |
table |
表格 | headers: string[], rows: string[][] |
tips |
建议卡片(绿色框) | items: string[] |
divider |
分隔线 | 无需数据 |
核心模块
lib/core.js— 通用绘制工具(圆角矩形、饼图、柱状图、格式化)lib/builder.js— Section DSL → Canvas 构建器
发图到飞书
IM 图片上传有 ECONNRESET 问题,推荐方案:
- 生成 PNG → 上传飞书云盘 → 开权限 → 发链接
- 或嵌入飞书文档直接预览
node examples/demo.js /tmp/poster.png
安全使用建议
This skill looks appropriate for generating dashboard/poster PNGs. Before installing, be comfortable with npm downloading the canvas dependency, choose safe output paths, and only upload or share generated images to Feishu after confirming the intended recipients and permissions.
功能分析
Type: OpenClaw Skill
Name: canvas-poster
Version: 1.0.0
The skill is a legitimate server-side poster and dashboard generation engine based on the @napi-rs/canvas library. The code in lib/builder.js and lib/core.js implements a declarative DSL for rendering charts, tables, and KPI cards into PNG images without any evidence of malicious intent, data exfiltration, or unauthorized network activity. File system operations are restricted to reading configuration data and writing the final image output as expected for this type of utility.
能力评估
Purpose & Capability
The documentation and code consistently describe generating PNG posters and dashboards from a declarative section DSL; no credential use, hidden network exfiltration, or unrelated account access is evidenced.
Instruction Scope
The skill includes a Feishu sharing workflow, but only as documented guidance and not implemented automatic behavior; users should confirm sharing scope before uploading generated business data.
Install Mechanism
Although registry metadata says there is no install spec, SKILL.md and package files show an npm-based setup with a native canvas dependency. This is expected for the purpose but should be treated as normal package-install trust review.
Credentials
The skill writes generated PNG files to a configured output path, which is appropriate for an image generator but users should choose safe paths to avoid accidental overwrites.
Persistence & Privilege
No persistence, background workers, credential storage, privileged configuration changes, or autonomous long-running behavior are shown in the provided artifacts.
如何使用
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install canvas-poster - 安装完成后,直接呼叫该 Skill 的名称或使用
/canvas-poster触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
🚀 Initial Release: Introduced the canvas-poster skill.
💼 Built for Professional Scenarios: Highly optimized for generating long-form data posters, making it the ideal tool for financial analysis, business analysis, and investment analysis reports.
🛠 Core Engine: Provides a robust server-side rendering engine powered by @napi-rs/canvas.
📊 Declarative UI: Supports declarative creation of complex dashboards, analytical reports, and comparison charts.
🧩 Rich Components: Includes multiple built-in section types such as KPI cards, bar charts, pie charts, data tables, and tip cards.
📐 Flexible Composition: Features a dedicated Section DSL to easily arrange and layout content for long-form infographics.
🔌 Highly Extensible: Designed to be used standalone or seamlessly integrated as a core dependency for other skills.
元数据
常见问题
Canvas Poster 是什么?
服务端海报生成引擎。基于 @napi-rs/canvas,声明式生成数据看板、战报、对比图等长图海报。 支持 KPI 卡片、柱状图、饼图、表格、建议卡片等 Section 类型。 当用户提到"生成海报"、"做看板"、"长图"、"数据可视化图"、"生成图表"时使用。 也供其他 Skill 作为依赖调用。 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 14 次。
如何安装 Canvas Poster?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install canvas-poster」即可一键安装,无需额外配置。
Canvas Poster 是免费的吗?
是的,Canvas Poster 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。
Canvas Poster 支持哪些平台?
Canvas Poster 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 Canvas Poster?
由 zz(@zhaoweismydd-cloud)开发并维护,当前版本 v1.0.0。
推荐 Skills