How do I initialize slick slider in fancybox?

When you open the modal window the slider is not correctly displayed until then, until you begin to click on slides or resize the window.

And not properly displayed when re-launching of modelki.

beforeShow, beforeLoad does not help.

What could be the reason you don't understand?

EXAMPLE ON CODEPEN
July 2nd 19 at 14:09
1 answer
July 2nd 19 at 14:11
Solution
slick slider refreshed differently:
afterShow : function() {
$('.h__slider-win').slick('setPosition');
$('.h__slider-control').slick('setPosition');


codepen.io/anon/pen/aBwrzb

Find more questions by tags HTMLCSSjQueryLayout