Commit a70f7129 authored by Martin Wortschack's avatar Martin Wortschack Committed by Phil Hughes

Replace breakpoints with GlBreakpointInstance in sidebar_context.js

parent f4e621e7
import $ from 'jquery';
import Cookies from 'js-cookie';
import bp from '~/breakpoints';
import { GlBreakpointInstance as bp } from '@gitlab/ui/dist/utils';
export default class SidebarContext {
constructor() {
......@@ -32,7 +32,7 @@ export default class SidebarContext {
window.addEventListener('beforeunload', () => {
// collapsed_gutter cookie hides the sidebar
const bpBreakpoint = bp.getBreakpointSize();
if (bpBreakpoint === 'xs' || bpBreakpoint === 'sm') {
if (bpBreakpoint === 'xs' || bpBreakpoint === 'sm' || bpBreakpoint === 'md') {
Cookies.set('collapsed_gutter', true);
}
});
......
Markdown is supported
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