1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-05 00:07:44 +02:00

[ticket/11957] Enhance responsive nav with JS

PHPBB3-11957
This commit is contained in:
Vjacheslav Trushkin
2013-10-25 19:59:45 +03:00
parent 8567adf5db
commit 43b9314390
2 changed files with 43 additions and 7 deletions

View File

@@ -2,6 +2,26 @@
* phpBB3 ACP functions
*/
/**
* Parse document block
*/
function parse_document(container)
{
var test = document.createElement('div'),
oldBrowser = (typeof test.style.borderRadius == 'undefined');
delete test;
/**
* Navigation
*/
container.find('#menu .menu-block > a.header').click(function() {
$(this).parent().toggleClass('active');
});
container.find('#activemenu').parents('.menu-block').addClass('active');
}
/**
* Run onload functions
*/
@@ -14,5 +34,7 @@
$('form[data-focus]:first').each(function() {
$('#' + this.getAttribute('data-focus')).focus();
});
parse_document($('body'));
});
})(jQuery);