Tweak styles to match new Panino

This commit is contained in:
Garen Torikian 2012-08-31 16:13:38 -07:00
commit d576d21154
24 changed files with 411 additions and 401 deletions

View file

@ -1,6 +1,20 @@
$(function () {
'use strict';
var pagePath = document.location.pathname.substring(document.location.pathname.lastIndexOf("/") + 1);
// select current page in sidenav and set up prev/next links if they exist
var $selNavLink = $('#sidebar').find('a[href="' + pagePath + '"]');
if ($selNavLink.length) {
//$selListItem = $selNavLink.closest('li');
$selNavLink.addClass('currentItem');
}
// init prettyprint
$('pre > code').addClass('prettyprint');
prettyPrint();
var baseTitle = document.title,
// base (general) part of title
pathName = window.location.pathname,
@ -25,25 +39,12 @@ $(function () {
};
}
var fileNameRE = new RegExp("^" + fileName, "i");
$('a.menuLink').each(function (index) {
if ($(this).attr("href").match(fileNameRE)) {
$(this).addClass("currentItem");
return false;
}
});
// init search
$('#search')
// prevent from form submit
.on('submit', function () {
return false;
}).find('input');
// init prettyprint
$('pre > code').addClass('prettyprint');
prettyPrint();
});
$(document).ready(function () {
@ -83,7 +84,7 @@ $(document).ready(function () {
$(this).scrollspy({
min: $classContent.position().top - 35,
max: $classContent.position().top + $classContent.height(),
max: $classContent.position().top + $classContent.height() - 35,
onEnter: function (element, position) {
var $pagination = $(element);
var $paginationContent = $('.membersContent pos' + i);