Hi,
How can we control the size of the filter popup in the pivot table. We find it a bit small.
Hi Thierry,
You can customize the filter popup size using CSS property. Please refer to the code example below.
Code sample:
|
<style> // here you can modify the width and height of the filter popup #PivotView .e-member-editor-dialog { height: 400px !important; max-height: 400px !important; width: 350px !important; }
// here you can modify the height of the treeview element in filter popup #PivotView .e-member-editor-container-outer-div { height:205 important; } </style> |
Meanwhile, we have prepared a sample for your reference below.
Sample: https://stackblitz.com/edit/lmfggj?file=index.html,index.ts
Please let us know if any concern occurs.
Regards,
Sastha Prathap S.
Thanks you, but is there a way to do this dynamically via Javascript?
We might want to have different sizes for different screen resolutions.
Hi Thierry,
Please refer the below code example to meet your requirements through JavaScript.
Code Example:
index.ts
|
memberEditorOpen: function () { // here you can modify the members editor dialog size based upon the display resolution. if (document.getElementById('PivotView').offsetWidth > 960) { if (document.getElementById('PivotView_EditorTreeView')) { document .getElementById('PivotView_EditorTreeView') .classList.remove('e-member-editor-dialog'); document .getElementById('PivotView_EditorTreeView') .classList.add('e-member-editor-resize'); } } else { if (document.getElementById('PivotView_EditorTreeView')) { document .getElementById('PivotView_EditorTreeView') .classList.remove('e-member-editor-resize'); document .getElementById('PivotView_EditorTreeView') .classList.add('e-member-editor-dialog'); } } } |
index.html
|
.e-member-editor-resize{ max-height: 700px !important; border-radius: 6px; max-width: 600px !important; width: 500px !important; height: 700px !important; } |
Meanwhile, we have prepared a sample for your reference.
Sample: https://stackblitz.com/edit/nupvah-vnetvs?file=index.js,index.html
Please let us know if you have any concerns.
Regards,
Angelin Faith Sheeba.