1.2 TSI(63 kW ; 05/2010 - 11/2012) 1.2 TSI(77 kW ; 11/2008 - 11/2012) 1.4(59 kW ; 10/2008 - 11/2012) 1.4 TSI(90 kW ; 10/2008 - 11/2012) 1.4 TSI(118 kW ; 10/2008 - 11/2012) 1.6(75 kW ; 10/2008 - 11/2012) 1.6 BiFuel(75 kW ; 03/2009 - 11/2012) 1.6 MultiFuel(75 kW ; 10/2008 - 11/2012) 1.8 TSI(118 kW ; 06/2009 - 01/2011) 2.0 GTi(155 kW ; 04/2009 - 11/2012) 2.0 GTi(173 kW ; 05/2011 - 11/2012) 1.6 TDI(66 kW ; 02/2009 - 11/2012) 1.6 TDI(77 kW ; 02/2009 - 11/2012)
//= tabOperator.threshold;
//Activate tabs or accordion
if (previousAboveThreshold)
{
//If above threshold - activate tabs
tabOperator.initTabs();
}
else
{
//If below threshold - activate accordion
tabOperator.initAccordion(tabOperator.initialAccIndex);
}
//On tab click
tabOperator.hookToAccordionOnClick();
//On window resize
$(window).on('themeResize', function (e, resizeEvent) {
if ($(window).width() < tabOperator.threshold)
{
if (previousAboveThreshold)
{
//Now below threshold, previously above, so switch to accordion
var api = tabOperator.$tabsContainer.data("tabs");
var index = api.getIndex();
api.destroy();
tabOperator.initAccordion(index);
}
previousAboveThreshold = false;
}
else
{
if (!previousAboveThreshold)
{
//Now above threshold, previously below, so switch to tabs
var api = tabOperator.$panelsContainer.data("tabs");
var index = api.getIndex();
api.destroy();
tabOperator.$rootContainer.removeClass("accor");
tabOperator.initTabs(index);
}
previousAboveThreshold = true;
}
});
}
else if (tabOperator.mode === 2)
{
tabOperator.initAccordion(tabOperator.initialAccIndex);
//On tab click
tabOperator.hookToAccordionOnClick();
}
else
{
tabOperator.initTabs();
}
} //end: init
, initTabs : function(index)
{
//If no param, set it to 0
if (typeof index === "undefined")
{
index = 0;
}
tabOperator.$tabsContainer.tabs(".tabs-panels .panel", {effect: tabOperator.tabEffect, initialIndex: index});
}
, initAccordion : function(index)
{
//If no param, set it to 0
if (typeof index === "undefined")
{
index = 0;
}
tabOperator.$rootContainer.addClass("accor");
tabOperator.$panelsContainer.tabs(".tabs-panels .panel", {tabs: '.acctab', effect: tabOperator.accEffect, initialIndex: index});
}
, hookToAccordionOnClick : function()
{
//Attach a handler to an event after a tab is clicked
tabOperator.$panelsContainer.bind("onClick", function(event, index) {
//Note: "this" is a reference to the DOM element of tabs
//var theTabs = this;
var target = event.target || event.srcElement || event.originalTarget;
//If viewport is lower than the item, scroll to that item
var itemOffsetTop = $(target).offset().top;
var viewportOffsetTop = jQuery(window).scrollTop();
if (itemOffsetTop < viewportOffsetTop)
{
$("html, body").delay(150).animate({scrollTop: (itemOffsetTop-50)}, 600, 'easeOutCubic');
}
}); //end: bind onClick
}
, openTab : function()
{
if (tabOperator.$rootContainer.hasClass("accor"))
{
var $panels = tabOperator.$panelsContainer;
var indexOfTab = $panels.children(".acctab").index($("#acctab-tabreviews"));
$panels.data("tabs").click(indexOfTab);
}
else
{
var $tabs = tabOperator.$tabsContainer;
var indexOfTab = $tabs.children("#tab-tabreviews").index();
$tabs.data("tabs").click(indexOfTab);
}
}
, slideTo : function(target, offset)
{
//Slide to tab (minus height of sticky menu)
var itemOffsetTop = $(target).offset().top - offset;
$("html, body").animate({scrollTop: itemOffsetTop}, 600, 'easeOutCubic');
}
};
//Initialize tabs
tabOperator.init('#product-tabs');
$("#goto-reviews").click(function() {
tabOperator.openTab();
tabOperator.slideTo('#product-tabs', 50);
}); //end: on click
$("#goto-reviews-form").click(function() {
tabOperator.openTab();
tabOperator.slideTo('#review-form', 90);
}); //end: on click
});
//]]>
Diese Website benötigt Cookies, um alle Funktionen bereitzustellen. Weitere Informationen darüber, welche Daten in den Cookies enthalten sind, finden Sie auf unserer Datenschutzrichtlinie. Um Cookies von dieser Seite zu akzeptieren, klicken Sie bitte unten auf die Schaltfläche Zulassen.