ngx-datatable icon indicating copy to clipboard operation
ngx-datatable copied to clipboard

footerHeight auto

Open minomikula opened this issue 5 years ago • 5 comments

I'm submitting a ... (check one with "x")

[ ] bug report => search github for a similar issue or PR before submitting
[x ] feature request
[ ] support request => Please do not submit support request here, post on Stackoverflow or Gitter

There is no way to use footer, without specifieng actual pixels in footerHeight

We were using footer, with height of footer controled by containing elements. Currently there is no way how to correctly specify headerHeight input. Typing of input is number and is now enforced while using ivy renderer. If we dont pass value, or use null/zero, footer is not renderer at all. In past we passed 'auto' as input value, not knowing that it is not intended. In fact it worked by accident, because it was passed to [style.height.px]="footerHeight" in your footerComponent.

Current behavior

There is no way to use footer, without specifieng actual pixels in input footerHeight of type number

Expected behavior

Typing of footerHeight will be number | 'auto', and 'auto' value will render footer component, but not set height style.

Reproduction of the problem

What is the motivation / use case for changing the behavior?

use correct typing

Please tell us about your environment:

  • Table version: 16.0.3

  • Angular version:

Angular CLI: 8.3.26 Node: 12.16.1 OS: win32 x64 Angular: 8.2.14

  • Browser: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ]
  • Language: [all | TypeScript X.X | ES6/7 | ES5]

minomikula avatar Apr 21 '20 13:04 minomikula

You can use the $any() function within the template to workaround this bug. This bug is present within the headerHeight parameter too and that component is accepting only number too.

92Arbiter avatar May 19 '20 09:05 92Arbiter

Yes, you can use workaround, but it should be not necessary.

BTW, fix should be really simple. I can do it myself if you accept PR.

minomikula avatar May 20 '20 09:05 minomikula

What is the status on this?

loxy avatar Jan 13 '22 20:01 loxy

No solution for this yet? 😒

marcoalesan avatar Dec 13 '22 13:12 marcoalesan

still no solution

Mersal-Mohamed2 avatar Jan 30 '23 09:01 Mersal-Mohamed2