Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🙏希望可以兼容antd v4,仅需一点小小的改动 #2952

Closed
4 tasks
GuoMouMo opened this issue Oct 30, 2024 · 2 comments
Closed
4 tasks

🙏希望可以兼容antd v4,仅需一点小小的改动 #2952

GuoMouMo opened this issue Oct 30, 2024 · 2 comments
Assignees
Labels
🙏feature request 新需求支持 next 2.0-next 版本的问题

Comments

@GuoMouMo
Copy link

🏷 Version

Package Version
@antv/s2 2.0.0-next.29
@antv/s2-react 2.0.0-next.28

Sheet Type

  • PivotSheet
  • [✅ ] TableSheet
  • GridAnalysisSheet
  • StrategySheet
  • EditableSheet

🖋 Description

项目中使用的antd v4

从S2 v1版本升级到S2 v2时碰到了一个报错

Uncaught TypeError: Cannot read properties of null (reading 'darkAlgorithm')

经过排查是这个目录下S2-next/packages/s2-react/src/components/config-provider/index.tsx,消费了antd的theme
antd v5的theme是一个对象,但在v4版本是null值,希望可以增加可选链来做兼容。

目前已经通过webpack插件修改了这部分代码,项目可以正常使用了,但不是长久之计,希望可以修改一下这部分代码

🏞 What problem does this feature solve

这个改动可以使s2-react运行在使用了antd v4版本的环境

@GuoMouMo GuoMouMo added the 🙏feature request 新需求支持 label Oct 30, 2024
Copy link
Contributor

你好 @GuoMouMo,请编辑你的 issue 标题, 一个言简意赅的 issue 标题可以节省大家的时间, 请不要将标题当做正文, 或者为空。

Hello, @GuoMouMo, please edit your issue title. a concise issue title will save everyone time. please do not leave the title as the body or empty.

@github-actions github-actions bot added the next 2.0-next 版本的问题 label Oct 30, 2024
@GuoMouMo GuoMouMo changed the title 🙏 🙏希望可以兼容antd v4,仅需一点小小的改动 Oct 30, 2024
@lijinke666
Copy link
Member

已知问题, 下个月会发布 2.0 的正式版, s2-react 会移除 antd 的耦合

#2887

@lijinke666 lijinke666 self-assigned this Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🙏feature request 新需求支持 next 2.0-next 版本的问题
Projects
None yet
Development

No branches or pull requests

2 participants