antvis / S2

⚡️ A practical visualization library for tabular analysis.
https://s2.antv.antgroup.com
MIT License
1.49k stars 196 forks source link

🤔基础类不能设置高宽? #2962

Closed 4color closed 2 weeks ago

4color commented 2 weeks ago

🏷 Version

Package Version
@antv/s2 2.0.0-next.30
@antv/s2-react
@antv/s2-vue 2.0.0-next.15

Sheet Type

🖋 Description

我直接用基础类来展示表格,但高宽不管怎么调都是默认值 600,400

const s2 = new PivotSheet(container, s2DataConfig, s2Options); 要如何改才可以修改高宽

🔗 Reproduce Link

😊 Expected Behavior

😅 Current Behavior

lijinke666 commented 2 weeks ago

不管怎么调

怎么个调法? 代码怎么写的? 初始化还是动态更新? 什么有用信息都没有, 也没有最小复现链接, 没人能回答你

  1. 初始化

const s2Options = {
  width: 300,
  height: 200
}

const s2 = new PivotSheet(container, s2DataConfig, s2Options);

await s2.render()
  1. 更新
s2.changeSheetSize(300, 200)
await s2.render(false)

https://s2.antv.antgroup.com/manual/faq#%E6%89%8B%E5%8A%A8%E6%9B%B4%E6%96%B0%E8%A1%A8%E6%A0%BC%E5%AE%BD%E9%AB%98%E5%90%8E%E4%B8%BA%E4%BB%80%E4%B9%88%E6%BB%9A%E5%8A%A8%E6%9D%A1%E4%B8%8D%E6%98%BE%E7%A4%BA%E4%BA%86

github-actions[bot] commented 2 weeks ago

你好 @4color,你所提供的信息不足于我们排查问题, 请按照 issue 模板填写相关信息, 提供 gif, 截图, 代码片段, 配置信息, 版本号, 可复现链接等方式, 详细说明复现步骤, 感谢配合, 谢谢! 15 天内未回复issue自动关闭。

Hello, @4color, the information you provided is not enough for us to troubleshoot the problem. Please complete the issue description, provide gifs, screenshots, config, version. And explain the reproduction steps in detail. Thanks so much for your cooperation! The issue will be closed without any replay within 15 days.