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

[Empty] 默认图片受 TailwindCSS 重置样式影响无法居中,需要加一个强一点的居中约束 #3062

Closed
KwokKwok opened this issue Aug 23, 2024 · 4 comments

Comments

@KwokKwok
Copy link

KwokKwok commented Aug 23, 2024

tdesign-react 版本

1.8.0

重现链接

No response

重现步骤

在一个安装 tailwind css 的项目中,使用 Empty 组件
因为 svg 会被默认重置为块级元素,导致组件的占位图不居中

期望结果

考虑 tailwind 的体量,应该在 Empty 组件的图片容器上加一个更有效的居中样式

实际结果

未居中

框架版本

No response

浏览器版本

No response

系统版本

No response

Node版本

No response

补充说明

No response

Copy link
Contributor

👋 @KwokKwok,感谢给 TDesign 提出了 issue。
请根据 issue 模版确保背景信息的完善,我们将调查并尽快回复你。

@KwokKwok
Copy link
Author

可以通过给 .t-empty__image 加上 display: flex; justify-content: center 来更好的约束

@HaixingOoO
Copy link
Collaborator

是的,欢迎PR!!!

@KwokKwok
Copy link
Author

ok, 我下午处理一下

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants