Skip to content

fix: Correct regression introduced in #7920 (structure board breakpoint) #7928

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
4 changes: 2 additions & 2 deletions cms/static/cms/js/modules/cms.structureboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -175,13 +175,13 @@ class StructureBoard {

_events() {
this.ui.window.on('resize.cms.structureboard', () => {
if (!this._loadedContent) {
if (!this._loadedContent || CMS.config.mode !== 'draft') {
return;
}
const width = this.ui.window[0].innerWidth;
const BREAKPOINT = 1024;

if (width > BREAKPOINT && !this.condensed && CMS.settings.mode === 'edit') {
if (width > BREAKPOINT && !this.condensed) {
this._makeCondensed();
}

Expand Down