main
Barış Soner Uşaklı 6 years ago
parent 5deb4eee8a
commit 9a5c49d3fa

@ -0,0 +1,3 @@
{
"mobile-menu-side": "Switch which side each mobile menu is on"
}

@ -0,0 +1,3 @@
{
"mobile-menu-side": "Switch which side each mobile menu is on"
}

@ -268,7 +268,9 @@ $(document).ready(function() {
function setupSetting() { function setupSetting() {
if (ajaxify.data.template['account/settings'] && !document.getElementById('persona:menus:legacy-layout')) { if (ajaxify.data.template['account/settings'] && !document.getElementById('persona:menus:legacy-layout')) {
$('<div class="well checkbox"><label><input type="checkbox" id="persona:menus:legacy-layout"/><strong>Switch which side each mobile menu is on</strong></label></div>') require(['translator'], function (translator) {
translator.translate('[[persona:mobile-menu-side]]', function (translated) {
$('<div class="well checkbox"><label><input type="checkbox" id="persona:menus:legacy-layout"/><strong>' + translated + '</strong></label></div>')
.appendTo('#content .account > .row > div:first-child') .appendTo('#content .account > .row > div:first-child')
.find('input') .find('input')
.prop('checked', Storage.getItem('persona:menus:legacy-layout', 'true')) .prop('checked', Storage.getItem('persona:menus:legacy-layout', 'true'))
@ -279,6 +281,8 @@ $(document).ready(function() {
Storage.removeItem('persona:menus:legacy-layout'); Storage.removeItem('persona:menus:legacy-layout');
} }
}); });
});
})
} }
} }

@ -21,5 +21,6 @@
}, },
"acpScripts": [ "acpScripts": [
"lib/admin.js" "lib/admin.js"
] ],
"languages": "languages"
} }
Loading…
Cancel
Save