fix intro closed intro position
This commit is contained in:
@@ -33,6 +33,7 @@ define(
|
||||
{
|
||||
button.classList.add( 'is-active' );
|
||||
element.classList.add( 'is-active' );
|
||||
element.style.top = '0';
|
||||
is_open = true;
|
||||
}
|
||||
|
||||
@@ -40,9 +41,15 @@ define(
|
||||
{
|
||||
button.classList.remove( 'is-active' );
|
||||
element.classList.remove( 'is-active' );
|
||||
element.style.top = -getHeight() + 'px';
|
||||
is_open = false;
|
||||
}
|
||||
|
||||
function getHeight()
|
||||
{
|
||||
return element.clientHeight;
|
||||
}
|
||||
|
||||
return { init: init };
|
||||
}
|
||||
);
|
||||
Reference in New Issue
Block a user