/*! * jQuery Smooth Scroll - v2.2.0 - 2017-05-05 * https://github.com/kswedberg/jquery-smooth-scroll * Copyright (c) 2017 Karl Swedberg * Licensed MIT */ !function(a){"function"==typeof define&&define.amd?define(["jquery"],a):a("object"==typeof module&&module.exports?require("jquery"):jQuery)}(function(a){var b={},c={exclude:[],excludeWithin:[],offset:0,direction:"top",delegateSelector:null,scrollElement:null,scrollTarget:null,autoFocus:!1,beforeScroll:function(){},afterScroll:function(){},easing:"swing",speed:400,autoCoefficient:2,preventDefault:!0},d=function(b){var c=[],d=!1,e=b.dir&&"left"===b.dir?"scrollLeft":"scrollTop";return this.each(function(){var b=a(this);if(this!==document&&this!==window)return!document.scrollingElement||this!==document.documentElement&&this!==document.body?void(b[e]()>0?c.push(this):(b[e](1),d=b[e]()>0,d&&c.push(this),b[e](0))):(c.push(document.scrollingElement),!1)}),c.length||this.each(function(){this===document.documentElement&&"smooth"===a(this).css("scrollBehavior")&&(c=[this]),c.length||"BODY"!==this.nodeName||(c=[this])}),"first"===b.el&&c.length>1&&(c=[c[0]]),c},e=/^([\-\+]=)(\d+)/;a.fn.extend({scrollable:function(a){var b=d.call(this,{dir:a});return this.pushStack(b)},firstScrollable:function(a){var b=d.call(this,{el:"first",dir:a});return this.pushStack(b)},smoothScroll:function(b,c){if("options"===(b=b||{}))return c?this.each(function(){var b=a(this),d=a.extend(b.data("ssOpts")||{},c);a(this).data("ssOpts",d)}):this.first().data("ssOpts");var d=a.extend({},a.fn.smoothScroll.defaults,b),e=function(b){var c=function(a){return a.replace(/(:|\.|\/)/g,"\\$1")},e=this,f=a(this),g=a.extend({},d,f.data("ssOpts")||{}),h=d.exclude,i=g.excludeWithin,j=0,k=0,l=!0,m={},n=a.smoothScroll.filterPath(location.pathname),o=a.smoothScroll.filterPath(e.pathname),p=location.hostname===e.hostname||!e.hostname,q=g.scrollTarget||o===n,r=c(e.hash);if(r&&!a(r).length&&(l=!1),g.scrollTarget||p&&q&&r){for(;l&&j"); if (figure.find(".scss").length) { ul.append("
  • SCSS
  • "); } if (figure.find(".sass").length) { ul.append("
  • Sass
  • "); } var hasCssTab = figure.find(".css").length; if (hasCssTab) { ul.append( $("
  • ") .prepend("CSS")); } figure.prepend(ul).tabs({ active: 0, beforeActivate: function(event, ui) { // If multiple panels are visible, the CSS tab shouldn't be clickable. if (ui.newPanel.hasClass('css') && allPanels.filter(":visible").length > 1) { return false; } }, activate: function(event, ui) { if (ui.newPanel.hasClass('css')) { figure.addClass('ui-tabs-panel-css-is-active'); } else { figure.removeClass('ui-tabs-panel-css-is-active'); } allPanels.removeClass('ui-tabs-panel-previously-active'); ui.oldPanel.addClass('ui-tabs-panel-inactive').addClass('ui-tabs-panel-previously-active'); ui.newPanel.removeClass('ui-tabs-panel-inactive'); allPanels.css('display', ''); } }); var allPanels = figure.find(".ui-tabs-panel"); allPanels.slice(1).addClass('ui-tabs-panel-inactive'); allPanels.css('display', ''); }); // Switch ALL the tabs (Sass/SCSS) together var noRecursion = false, jqA = $( "a.ui-tabs-anchor" ), jqASass = jqA.filter( ":contains('Sass')" ).click(function() { if ( !noRecursion ) { noRecursion = true; jqASass.not( this ).click(); noRecursion = false; } }), jqASCSS = jqA.filter( ":contains('SCSS')" ).click(function() { if ( !noRecursion ) { noRecursion = true; jqASCSS.not( this ).click(); noRecursion = false; } }) ; }); $(function() { $(".impl-status").each(function() { var statusBar = $(this); var expandLink = $(this).find("a"); if (expandLink == null) return; var details = $(this).next(); if (!details.hasClass("sl-c-callout")) return; details.hide(); expandLink.click(function() { details.toggle(); expandLink.toggleClass("expanded"); }); }); }); $(function() { $(".sl-c-list-navigation-wrapper--collapsible li > ul") .parent().children("a").each(function() { var overview = $('
  • Overview
  • \n'); var link = overview.children().first().attr("href", $(this).attr("href")); if ($(this).hasClass("selected") && link[0].pathname == window.location.pathname) { link.addClass("selected"); } $(this).parent().children("ul").prepend(overview); $(this).removeAttr("href"); }).click(function() { $(this).toggleClass("open"); }); });