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

浮动列高度不一致问题,能不能更加动态设置row-height? #91

Open
surewinT opened this issue Aug 13, 2020 · 4 comments

Comments

@surewinT
Copy link

download
如图:左边浮动列高度小了,设置 :row-height="50",可以解决。
但是现在封装一个通用的表格业务组件,表格的cell里面可能容下其他组件(如button、tag等),这时候row-height不能写固定的高度,应该如何解决呢?

@parlay96
Copy link
Owner

多简单的

  1. pl-table不在更新维护,有问题请关于umy-ui
  2. 对于你的问题,请保持行高一致,你不能说你放button是50px 放tag就是30px。如果你需要这样做 ,那么你需要刷新表格 进行重绘
  3. 请关注下http://129.211.13.167/#/wel/component/virtualScrolling
  4. row-height | use-virtual未开启的情况可以不需要,行高(必须要设置行高,如css给td给了80高度,那么你就给row-height给80,不要乱给高度,以td tr高度为准,否则会导致表格计算不正确)
    -- | --

@parlay96
Copy link
Owner

你的这个情况属于你固定部分的操作区域高度 大于了你给的row-height属性,

@parlay96
Copy link
Owner

那么 你要么把row-height设置正确。 要么把操作部分的按钮高度减少,你属于操作部分的单元格超出row-height的高度

@surewinT
Copy link
Author

已解决:解决思路是将row-height设置成动态,在页面首次更新的时候,获取到行高。传入button、tag等都可以高度对齐,有遇到类似问题的朋友,可以借鉴一下
Lark20200813-184517

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

2 participants