Files
gitea-pages/_layouts/default.html
George Hartzell 8dc46885e1 Use ready function from the default layouts
You don't actually need to include the document ready function in the
page.

The commit updates the document ready function in the default template
to specify the features discussed in the prose and deletes the one that
is embedded in the page itself.
2017-02-14 11:22:13 -08:00

82 lines
2.1 KiB
HTML

<!DOCTYPE html>
<head>
{% include head.html %}
<script>
$(document).ready(function() {
// Initialize navgoco with default options
$("#mysidebar").navgoco({
caretHtml: '',
accordion: true,
openClass: 'active', // open
save: false, // leave false or nav highlighting doesn't work right
cookie: {
name: 'navgoco',
expires: false,
path: '/'
},
slide: {
duration: 400,
easing: 'swing'
}
});
$("#collapseAll").click(function(e) {
e.preventDefault();
$("#mysidebar").navgoco('toggle', false);
});
$("#expandAll").click(function(e) {
e.preventDefault();
$("#mysidebar").navgoco('toggle', true);
});
});
</script>
<script>
$(function () {
$('[data-toggle="tooltip"]').tooltip()
})
</script>
{% if page.datatable == true %}
<link rel="stylesheet" type="text/css" href="//cdn.datatables.net/1.10.13/css/jquery.dataTables.css">
<script type="text/javascript" charset="utf8" src="//cdn.datatables.net/1.10.13/js/jquery.dataTables.js"></script>
<script>
$(document).ready(function(){
$('table.display').DataTable( {
paging: true,
stateSave: true,
searching: true
}
);
});
</script>
{% endif %}
</head>
<body>
{% include topnav.html %}
<!-- Page Content -->
<div class="container">
<div class="col-lg-12">&nbsp;</div>
<!-- Content Row -->
<div class="row">
<!-- Sidebar Column -->
<div class="col-md-3">
{% include sidebar.html %}
<!-- Content Column -->
<div class="col-md-9">
{{content}}
</div>
<!-- /.row -->
</div>
<!-- /.container -->
</div>
</body>
{% if site.google_analytics %}
{% include google_analytics.html %}
{% endif %}
</html>