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] column.filter属性增加popup的相关配置项 #2088

Closed
wandoupeas opened this issue Nov 30, 2022 · 4 comments
Closed

[table] column.filter属性增加popup的相关配置项 #2088

wandoupeas opened this issue Nov 30, 2022 · 4 comments
Assignees
Labels
to be published to be published

Comments

@wandoupeas
Copy link

wandoupeas commented Nov 30, 2022

这个功能解决了什么问题

在dialog中使用table组件时,若数据较少,使用列筛选的时候会出现dialog内部滚动条,产生页面抖动,体验感不是很好,增加filter对应的popup的相关配置,比如attach属性,可以将相应的filter弹框绑定至body等外部dom,这样不会产生抖动
image
image

你建议的方案是什么?

类似这种:

filter: {
  component: DateRangePickerPanel,
  popupProps: {
    attach: 'body',
  },
  props: {
    firstDayOfWeek: 7,
    presets: {
      最近7天: [dayjs().subtract(6, 'day'), dayjs()],
      最近3天: [dayjs().subtract(2, 'day'), dayjs()],
      今天: [dayjs(), dayjs()],
    },
  }
};
@github-actions
Copy link
Contributor

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

@github-actions
Copy link
Contributor

github-actions bot commented Nov 30, 2022

♥️ 有劳 @realyuyanan @Louiszhai @PengYYYYY @chaishi 尽快确认问题。
确认有效后将下一步计划和可能需要的时间回复给 @wandoupeas

@chaishi
Copy link
Collaborator

chaishi commented Dec 3, 2022

可以新增一个 filter.popupProps 透传 Popup 组件属性

@chaishi
Copy link
Collaborator

chaishi commented Dec 3, 2022

resolved in resolved in #2105

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

No branches or pull requests

3 participants