fix: move `build directory to resources/shop`
This commit is contained in:
11
resources/shop/js/include/url_on_tab.js
Normal file
11
resources/shop/js/include/url_on_tab.js
Normal file
@@ -0,0 +1,11 @@
|
||||
// Javascript to enable link to tab
|
||||
var url = document.location.toString();
|
||||
if (url.match('#')) {
|
||||
$('.nav-tabs a[href="#' + url.split('#')[1] + '"]').tab('show');
|
||||
}
|
||||
|
||||
// Change hash for page-reload
|
||||
$('.nav-tabs a').on('shown.bs.tab', function (e) {
|
||||
window.location.hash = e.target.hash;
|
||||
$(window).scrollTop(0);
|
||||
})
|
||||
Reference in New Issue
Block a user