Closed thalesmiguel closed 7 years ago
Happen to me too. Is there a solution?
try update gem with latest release
In my case, I was using div instead of li for each item, inside the ul. Using li solves the problem for me.
the js shoudln't throw errors because of the html. To fix the tabs.js you have to add a control in tabs.js line 42 and 49 if(undefined === el.position()) {return;}
var calcRightPos = function(el) {
if(undefined === el.position()) {return;}
return Math.ceil($tabs_width - el.position().left - el.outerWidth() - $this.scrollLeft());
};
var calcLeftPos = function(el) {
if(undefined === el.position()) {return;}
return Math.floor(el.position().left + $this.scrollLeft());
};
Change ul -> ol
Hello. I've just updated this awesome gem on my project and I'm getting an error when initializing my tabs. When using
$(ul.tabs).tabs();
I get aUncaught TypeError: Cannot read property 'left' of undefined
.Anyone else getting this message?
Thanks in advance.