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

[Bug Report] [@formily/antd v4]及官方示例中,FormItem tooltip有问题 #4202

Open
lk0606 opened this issue Aug 13, 2024 · 3 comments
Open

Comments

@lk0606
Copy link

lk0606 commented Aug 13, 2024

Reproduction link

Edit on CodeSandbox
image

Steps to reproduce

What is expected?

期望tooltip正常展示

What is actually happening?

tooltip无法显示内容

Package

@formily/[email protected]


@liuhuisheng
Copy link

在我项目中以前配置的正常的tooltip也出现异常的情况,只有气泡,没有内容

@Chen-Weidong
Copy link

我也遇到了一样的问题,什么时候可以修复呢?
应该是BaseItem组件有问题(import { BaseItem } from '@formily/antd/esm/form-item/index'; )

我尝试打印了下,如下图,Tooltip的props参数有问题,应该是{ tooltip: 'xxx' }的,结果不知道为什么,这个字符串被解析为了对象,导致tooltip的内容是空的。
image
image

@ctocto
Copy link

ctocto commented Oct 23, 2024

'x-decorator-props': {
        labelCol: 5,
        wrapperCol: 19,
        tooltip: React.createElement('span', null, '这里是提示信息'),
 },

这样写可以解决问题。

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

No branches or pull requests

4 participants