diff options
author | filip <filip.komar@gmail.com> | 2020-10-24 20:50:08 +0200 |
---|---|---|
committer | filip <filip.komar@gmail.com> | 2020-10-24 20:50:08 +0200 |
commit | f1de6a90e16de4b0756e890b9dc4b119d97d6778 (patch) | |
tree | 318fc4950dac0a8fd7c136b88d428344bc5a88d1 /lib.php | |
parent | 0a858d2e4153328faa5b6cd8830914d55fedd449 (diff) | |
download | nav-f1de6a90e16de4b0756e890b9dc4b119d97d6778.tar nav-f1de6a90e16de4b0756e890b9dc4b119d97d6778.tar.gz nav-f1de6a90e16de4b0756e890b9dc4b119d97d6778.tar.bz2 nav-f1de6a90e16de4b0756e890b9dc4b119d97d6778.tar.xz nav-f1de6a90e16de4b0756e890b9dc4b119d97d6778.zip |
nav RTL collapse fix
Diffstat (limited to 'lib.php')
-rw-r--r-- | lib.php | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -340,6 +340,7 @@ function _mgnav_html($wrap = false, $lang = 'en', $inject = null, $vhost = 'www. $s = implode($s); $links_direction = is_locale_rtl($lang) ? ' dir="rtl"' : ''; $links_position = is_locale_rtl($lang) ? 'ml-auto' : 'mr-auto'; + $navbar_collapse_position = is_locale_rtl($lang) ? 'style="text-align: right;"' : 'style="text-align: left;"'; $h = sprintf('<!--googleoff: all--> <div' . $links_direction . ' class="mganav"> <nav id="mgnav" class="container navbar navbar-expand-lg navbar-light"> @@ -347,7 +348,7 @@ function _mgnav_html($wrap = false, $lang = 'en', $inject = null, $vhost = 'www. <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation"> <span class="navbar-toggler-icon"></span> </button> - <div class="collapse navbar-collapse" id="navbarNav"> + <div class="collapse navbar-collapse" ' . $navbar_collapse_position . ' id="navbarNav"> <ul class="navbar-nav ' . $links_position . '">%s</ul> </div> </nav> |