Closed JbSun closed 1 year ago
1.依赖仓库的版本(Dependencies versions):
2.问题描述(Bug description): 在schema中设置了description后,必填文案改变了。没取label,用的是name
3.出现问题的 schema demo(Reproduction schema demo):
const schema = { type: 'object', properties: { floorGoods: { title: '货架兜底货品', type: 'number', required: true, description: '未命中货品池货品或打分模型匹配分数失败,推荐该货品' }, }, }
4.最小复现 demo(Reproduction demo):
form-render demo https://codesandbox.io/s/unruffled-flower-jl78h table-render demo https://codesandbox.io/s/sweet-euler-bdoty fr-generator demo https://codesandbox.io/s/s13sh
是 antd 本身的问题。 因为目前 description 是加在 label 上的,这样的话, label 就变成 reactNode 了,于是就拿不到真实的 label。所以展示的就是 name。 antd 如果给 label 一个 reactNode 话,也是一样的效果。
建议自定义 rules 解决
1.依赖仓库的版本(Dependencies versions):
2.问题描述(Bug description): 在schema中设置了description后,必填文案改变了。没取label,用的是name
3.出现问题的 schema demo(Reproduction schema demo):
4.最小复现 demo(Reproduction demo):
form-render demo https://codesandbox.io/s/unruffled-flower-jl78h table-render demo https://codesandbox.io/s/sweet-euler-bdoty fr-generator demo https://codesandbox.io/s/s13sh