Is there any way to align the header in a slick grid to center and the text in the columns to left? any css files need modification or something else?
Please guide.
var columns = [
{ id: "colEmpId", name: 'Number', field: "EmpId", "unselectable": false },
{ id: "colLastName", name: 'Last Name', field: "LastName", "unselectable": false },
{ id: "colFirstName", name: 'First Name', field: "FirstName", "unselectable": false }
];
This is column definition
You can style the headings using the built-in classes in the css sheet.: .slick-header
.slick-header-column
.slick-header-columns
.slick-headerrow-column
.slick-headerrow-columns
For text in the columns you can assign a custom css class in the column definition and add this to your style sheet.
e.g.
var columns = [ { id: "colEmpId", name: 'Number', cssClass: "column-empid" }, ...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With