if (re.exec(classList) == null) {
var options = {
trigger: "hover",
container: "body",
placement: "right auto",
html: !0,
viewport: {
selector: "body",
padding: 2
},
template: '<div class="popover"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'
};
$(this).popover(options);
console.log(this);
console.log(options);
}
var options = {
trigger: "hover",
container: "body",
placement: ok[1],
html: !0,
viewport: {
selector: "body",
padding: 2
},
template: '<div class="popover"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'
};
var width = $(window).width();
var prefix = width < 768 ? 'xs' : width < 992 ? 'sm' : width < '1200' ? 'md' : width < '1600' ? 'lg' : 'xlg';
var re = new RegExp('(?:^|\s)'+prefix+'-(bottom|top|left|right)(?:$|\s)');
$('[data-toggle="popover"]').each(function() {
var classList = $(this).attr('class');
var ok = re.exec(classList);
if (ok !== null) {
var options = {
trigger: "hover",
container: "body",
placement: ok[1],
html: !0,
viewport: {
selector: "body",
padding: 2
},
template: '<div class="popover"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'
};
if ($(this).hasClass('ppm'))
options.delay = { show: 500, hide: 10};
$(this).popover(options);
console.log(options);
}
console.log(this);
});
if(width<768){
if ($(this).hasClass("xs-bottom")){ $(this).popover(bottom);}
else if ($(this).hasClass("xs-top")){ $(this).popover(top);}
else if ($(this).hasClass("xs-left")){ $(this).popover(left);}
else if($(this).hasClass("xs-right")){ $(this).popover(right);}
}else if(width>=768 && width<992){
if ($(this).hasClass("sm-bottom")){ $(this).popover(bottom);}
else if ($(this).hasClass("sm-top")){ $(this).popover(top);}
else if ($(this).hasClass("sm-left")){ $(this).popover(left);}
else if($(this).hasClass("sm-right")){ $(this).popover(right);}
}else if(width>=992 && width<1200){
if ($(this).hasClass("md-bottom")){ $(this).popover(bottom);}
else if ($(this).hasClass("md-top")){ $(this).popover(top);}
else if ($(this).hasClass("md-left")){ $(this).popover(left);}
else if($(this).hasClass("md-right")){ $(this).popover(right);}
}else if(width>=1200 && width<1600){
if ($(this).hasClass("lg-bottom")){ $(this).popover(bottom);}
else if ($(this).hasClass("lg-top")){ $(this).popover(top);}
else if ($(this).hasClass("lg-left")){ $(this).popover(left);}
else if($(this).hasClass("lg-right")){ $(this).popover(right);}
}else if(width>=1600){
if ($(this).hasClass("xlg-bottom")){ $(this).popover(bottom);}
else if ($(this).hasClass("xlg-top")){ $(this).popover(top);}
else if ($(this).hasClass("xlg-left")){ $(this).popover(left);}
else if($(this).hasClass("xlg-right")){ $(this).popover(right);}
}
delay: {
show: 500,
hide: 10
},
забыл фото