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

Separate width and minWidth for nz table #8675

Open
mp-d62aa8b8 opened this issue Aug 2, 2024 · 0 comments
Open

Separate width and minWidth for nz table #8675

mp-d62aa8b8 opened this issue Aug 2, 2024 · 0 comments
Assignees

Comments

@mp-d62aa8b8
Copy link

mp-d62aa8b8 commented Aug 2, 2024

What problem does this feature solve?

I have a lot of barely fitting in main screen resolution tables, in which there are a lot of fixed small columns and one column that should be able to grow, but don't shrink to 0 when a resolution is lower. it'd be convenient if we had an api for setting min-width and width separately and didn't need to use viewChild with querySelector on native element to change min-width on col element.

What does the proposed API look like?

API usage:

<nz-table [listOfColWidth]="['100%', '100%', '100%']" [listOfColMinWidth]="[null, null, '300px']"></nz-table>

API implementation

add
@Input() listOfColMinWidth: ReadonlyArray<string | null> = []; to NzTableContentComponent and change setting minWidth in <col element in template to [style.minWidth]="listOfColMinWidth[$index] ?? width"

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

No branches or pull requests

2 participants