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

[table] table组件中如果内容是0且设置了ellipsis,当前内容就显示不了 #2472

Closed
cllee1214 opened this issue Jun 16, 2023 · 8 comments
Labels
invalid This doesn't seem right

Comments

@cllee1214
Copy link

tdesign 版本

1.1.10

重现链接

No response

重现步骤

1.table中某个cell值为0
2.设置ellipsis = true

期望结果

No response

实际结果

No response

框架版本

No response

浏览器版本

No response

系统版本

No response

Node版本

No response

补充说明

No response

@cllee1214
Copy link
Author

1686909765052
初步排查 是因为这个地方的0被转换为false了。导致了cellNode为undefined。

@xiaosansiji
Copy link
Collaborator

React 版本的么?最好补充下复现链接

@xiaosansiji xiaosansiji added the need more info 需要更多信息理解 issue 的问题 label Jul 14, 2023
@cllee1214
Copy link
Author

React 版本的么?最好补充下复现链接

不方便贴连接,就2楼的源码图可以看看。应该还是弱类型转换引发的问题

@uyarn uyarn transferred this issue from Tencent/tdesign Aug 28, 2023
@github-actions
Copy link
Contributor

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

@github-actions
Copy link
Contributor

♥️ 有劳 @yunfeic @tengcaifeng @Yacent @basecss 尽快确认问题。
确认有效后将下一步计划和可能需要的时间回复给 @cllee1214

1 similar comment
@github-actions
Copy link
Contributor

♥️ 有劳 @yunfeic @tengcaifeng @Yacent @basecss 尽快确认问题。
确认有效后将下一步计划和可能需要的时间回复给 @cllee1214

@chaishi
Copy link
Collaborator

chaishi commented Aug 28, 2023

应该是判空的原因,我抽空看下。
你看看能不能先转换成字符串 ‘0’ 临时解决这个问题

@chaishi chaishi added invalid This doesn't seem right and removed need more info 需要更多信息理解 issue 的问题 labels Sep 16, 2023
@chaishi
Copy link
Collaborator

chaishi commented Sep 16, 2023

https://stackblitz.com/edit/react-xcv3ob?file=src%2Fdemo.jsx
看了下最新版本,已经没有这个问题了

image

@chaishi chaishi closed this as completed Sep 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
invalid This doesn't seem right
Projects
None yet
Development

No branches or pull requests

3 participants