L
L
L1nw0od2019-09-19 13:09:02
css
L1nw0od, 2019-09-19 13:09:02

How to fix crooked display when switching bootstrap tabs?

There is a block of contacts (made by bootstrap tabs), in these tabs I use the SLICK carousel.
When the site loads, everything is displayed as it should, but when switching between tabs occurs (the content is displayed incorrectly - (it seems that the block sizes are not set), but as soon as we press the carousel scroll button, everything becomes as it should be.
Link to the demo

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dmitry Khristoev, 2019-09-19
@L1nw0od

.tab-content > .tab-pane,
.pill-content > .pill-pane {
    display: block;    /* undo display:none          */
    height: 0;         /* height:0 is also invisible */
    overflow: hidden;  /* no-overflow                */
}
.tab-content > .active,
.pill-content > .active {
    height: auto;      /* let the content decide it  */
}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question