Commit ef25d51f authored by Damyon Wiese's avatar Damyon Wiese
Browse files

MDL-56795 boost: Close drawer after navigating on mobile

parent cd4a6b8b
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
......@@ -63,6 +63,10 @@ define(['jquery', 'core/custom_interaction_events', 'core/log'],
}.bind(this));
this.registerEventListeners();
var small = $(document).width() < 768;
if (small) {
this.closeAll();
}
};
Drawer.prototype.closeAll = function() {
......@@ -99,7 +103,7 @@ define(['jquery', 'core/custom_interaction_events', 'core/log'],
body.addClass('drawer-ease');
var open = trigger.attr('aria-expanded') == 'true';
if (!open) {
var small = $(document).width() < 512;
var small = $(document).width() < 768;
if (small) {
this.closeAll();
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment