mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-01-25 00:34:21 +03:00
Remove unused base.js script
This commit is contained in:
parent
7e76cd8695
commit
be0e196e65
|
@ -1,42 +0,0 @@
|
||||||
function getSearchTerm()
|
|
||||||
{
|
|
||||||
var sPageURL = window.location.search.substring(1);
|
|
||||||
var sURLVariables = sPageURL.split('&');
|
|
||||||
for (var i = 0; i < sURLVariables.length; i++)
|
|
||||||
{
|
|
||||||
var sParameterName = sURLVariables[i].split('=');
|
|
||||||
if (sParameterName[0] == 'q')
|
|
||||||
{
|
|
||||||
return sParameterName[1];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
$(document).ready(function() {
|
|
||||||
|
|
||||||
var search_term = getSearchTerm(),
|
|
||||||
$search_modal = $('#mkdocs_search_modal');
|
|
||||||
|
|
||||||
if(search_term){
|
|
||||||
$search_modal.modal();
|
|
||||||
}
|
|
||||||
|
|
||||||
// make sure search input gets autofocus everytime modal opens.
|
|
||||||
$search_modal.on('shown.bs.modal', function () {
|
|
||||||
$search_modal.find('#mkdocs-search-query').focus();
|
|
||||||
});
|
|
||||||
|
|
||||||
// Highlight.js
|
|
||||||
hljs.initHighlightingOnLoad();
|
|
||||||
$('table').addClass('table table-striped table-hover');
|
|
||||||
});
|
|
||||||
|
|
||||||
|
|
||||||
$('body').scrollspy({
|
|
||||||
target: '.bs-sidebar',
|
|
||||||
});
|
|
||||||
|
|
||||||
/* Prevent disabled links from causing a page reload */
|
|
||||||
$("li.disabled a").click(function() {
|
|
||||||
event.preventDefault();
|
|
||||||
});
|
|
Loading…
Reference in New Issue
Block a user