antvis / antvis/G6

[Feat]: 导出图片增加设置图片的padding

Open
#7,265 2 comments 0 reactions 0 assignees View on GitHub
feature 💡 OSCP
Dominant language
TypeScript
Stars
12.3k
Forks
1.6k
PR merge metrics
No merged PRs in 30d

Description

### Describe the feature / 功能描述

1、graph.toDataUrl方法不支持指定padding
2、尝试图初始化时配置padding,导出图片也没有边距
3、导出图片前,改变画布大小,让元素居中,导出图片也没有边距

### Are you willing to contribute? / 是否愿意参与贡献?

✅ Yes / 是

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at the graph.toDataUrl API and trace how export dimensions and canvas bounds are determined. Reproduce the three reported padding configurations, then verify that the requested padding appears around the exported graph without changing the graph layout.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
data-visualization
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.