27 lines
691 B
JavaScript
Raw Normal View History

2017-04-26 11:08:23 +02:00
$(document).ready(function() {
$('.open-panel').click(function(e) {
e.preventDefault();
target = $(this).attr('href');
$(target).addClass('open');
});
$('.panel .overlay').click(function(e) {
e.preventDefault();
$(this).parent().removeClass('open');
});
$('.panel .icon-close').click(function(e) {
e.preventDefault();
$(this).parent().parent().removeClass('open');
});
2017-05-10 09:48:13 +02:00
$('#privatesales_block ul .extra_info .small_title').each(function() {
if(window.matchMedia("(max-width:1199px)").matches) {
var nameProduct = $(this).text();
2017-05-17 16:36:35 +02:00
if(nameProduct.length > 20) {
2017-05-17 16:39:22 +02:00
nameProduct = nameProduct.substring(0,17)+"...";
2017-05-10 09:48:13 +02:00
$(this).text(nameProduct);
}
}
});
});