This repository has been archived on 2024-03-16. You can view files and clone it, but cannot push or open issues or pull requests.
orbit-4-1/app/assets/javascripts/orbit-bar-search.js

26 lines
628 B
JavaScript

$(document).ready(function(){
$('.search').tooltip({
placement: "bottom"
});
});
$(document).on('click', '.orbit-bar-search', function (){
if ($(this).parents('.search').hasClass('visible')){
$(this).parents('.search').stop().animate({
'width':'28px',
});
$(this).parents('.search').css({
'background-color': 'transparent',
});
$(this).parents('.search').removeClass('visible');
}
else{
$(this).parents('.search').stop().animate({
'width':'265px',
});
$(this).parents('.search').css({
'background-color': 'rgba(0, 0, 0, 0.5)',
});
$(this).parents('.search').addClass('visible');
}
});