frappe / datatable

The Missing Javascript Datatable for the Web
https://frappe.io/datatable
MIT License
1.02k stars 164 forks source link

There is no way to define height ? #5

Open rmehta opened 6 years ago

rmehta commented 6 years ago

could be from parent container, or autoheight ?

DavidMenting commented 10 months ago

Diving a bit into this it seems the height of the .dt-scrollable element is fixed to 40vw in style.css, so 40% of vertical window. It doesn't make any sense to base the height of an element on the viewport width.

My solution for for example the General Ledger in ERPnext is to set

.dt-scrollable {
    height: calc(100vh - 450px);

This is still not ideal as the 450px might not be the same for every situation but at least for my General Ledger in ERPnext this works.