Persisting header CSS classes while reordering grid columns

1 Answer 91 Views
Grid
Mykhailo
Top achievements
Rank 1
Mykhailo asked on 12 Oct 2021, 01:23 PM
Hi,
Is it possible to persist Grid column header CSS classes (text alignment) while reordering/drag-n-dropping columns?
I've looked into Grid API but couldn't find there any clue...
Thanks in advance! 

1 Answer, 1 is accepted

Sort by
0
Stoyan
Telerik team
answered on 15 Oct 2021, 07:50 AM

Hi Mykhailo,

Thanks for the provided information and snapshots.

It is possible to persist the CSS classes of the Grid column headers by modifying the .k-header.k-drag-clue CSS class chain which is responsible for the styles of the draggable box.

I've prepared a short StackBlitz demo that demonstrates the wanted behavior:

https://stackblitz.com/edit/angular-u2gu9z?file=app/app.component.ts

I hope this helps.

Regards,
Stoyan
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
Grid
Asked by
Mykhailo
Top achievements
Rank 1
Answers by
Stoyan
Telerik team
Share this question
or