How to remove title in SlickGrid?

I know that there is no API to remove the title bar, but I'm sure it can be done by changing CSS. Any ideas?

For example, here: http://mleibman.github.com/SlickGrid/examples/example4-model.html

CSS experts! I need your help with this. I am interested in changing the CSS code of a package that removes the title bar. Preferred is CSS code that can be loaded on top of the package. Source code here: http://github.com/mleibman/SlickGrid (Click "Download Source")

+3
source share
5 answers

The short answer is that this is not supported in SlickGrid, at least for now. The CSS workaround does not work, as SlickGrid uses the DOM elements in the header to calculate the size of the viewport. If set display:none, SlickGrid considers the grid to be 0 pixels wide.

You can get around this by completing $(".slick-header-columns").css("height","0px")and then calling grid.resizeCanvas()to get rid of the remaining spaces at the bottom of the grid.

+6
source

Just add the following grid options:

headerHeight: 0

and then in your css type something like:

#myGridID .slick-header-columns {
  display: none;
}
+3
source

, :

$(element).find('.slick-header').css('display', 'none');
+2

, , :

.slick-header-columns { display: none; }
+1

- slick.grid.js

function createColumnHeaders() { ; }

if you add a return to the first line inside createColumnHeaders, it seems like they are removing the headers.

+1
source

Source: https://habr.com/ru/post/1743144/


All Articles