aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/adm/style/admin.js
diff options
context:
space:
mode:
authorVjacheslav Trushkin <cyberalien@gmail.com>2013-10-25 19:59:45 +0300
committerVjacheslav Trushkin <cyberalien@gmail.com>2013-10-26 22:00:23 +0300
commit43b9314390db962aaef2411e22642f86730a6eb6 (patch)
tree8805caea9234e5bbc8ca22e25b08f75fbea9e9de /phpBB/adm/style/admin.js
parent8567adf5dbfc1d6363deb78b6ebf25a76857c9ac (diff)
downloadforums-43b9314390db962aaef2411e22642f86730a6eb6.tar
forums-43b9314390db962aaef2411e22642f86730a6eb6.tar.gz
forums-43b9314390db962aaef2411e22642f86730a6eb6.tar.bz2
forums-43b9314390db962aaef2411e22642f86730a6eb6.tar.xz
forums-43b9314390db962aaef2411e22642f86730a6eb6.zip
[ticket/11957] Enhance responsive nav with JS
PHPBB3-11957
Diffstat (limited to 'phpBB/adm/style/admin.js')
-rw-r--r--phpBB/adm/style/admin.js22
1 files changed, 22 insertions, 0 deletions
diff --git a/phpBB/adm/style/admin.js b/phpBB/adm/style/admin.js
index 9b2c9313ac..208afedce8 100644
--- a/phpBB/adm/style/admin.js
+++ b/phpBB/adm/style/admin.js
@@ -3,6 +3,26 @@
*/
/**
+* 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
*/
(function($) {
@@ -14,5 +34,7 @@
$('form[data-focus]:first').each(function() {
$('#' + this.getAttribute('data-focus')).focus();
});
+
+ parse_document($('body'));
});
})(jQuery);