Skip to content
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

Distraction free mode triggered when viewing styles, if no other theme variations #52085

Closed
richtabor opened this issue Jun 28, 2023 · 3 comments · Fixed by #52090
Closed

Distraction free mode triggered when viewing styles, if no other theme variations #52085

richtabor opened this issue Jun 28, 2023 · 3 comments · Fixed by #52090
Labels
[Feature] Distraction Free A preference in the Post and Site Editor that limits distractions to focus the editing experience [Type] Bug An existing feature does not function as intended

Comments

@richtabor
Copy link
Member

Uncovered a bug where Distraction Free is enabled when clicking "Styles" from the Site Editor, if a theme only has one style variation. cc @draganescu

To reproduce, enable a theme without any alternative variations (like Stacks), then view the Site Editor > Styles panel.

CleanShot.2023-06-28.at.13.15.31.mp4
@richtabor richtabor added [Type] Bug An existing feature does not function as intended [Feature] Distraction Free A preference in the Post and Site Editor that limits distractions to focus the editing experience labels Jun 28, 2023
@draganescu
Copy link
Contributor

I can't reproduce this on trunk with Stacks. This

should turn DFM off when that styles button is clicked.

@draganescu draganescu added [Status] Needs More Info Follow-up required in order to be actionable. [Status] Blocked Used to indicate that a current effort isn't able to move forward labels Jun 28, 2023
@richtabor
Copy link
Member Author

I can consistently reproduce it, with the same conditions. 😅

I get the snackbar too (and DFM wasn't turned off). Looks like it's doing the opposite of the intent.

CleanShot 2023-06-28 at 15 21 58

@draganescu
Copy link
Contributor

Yes, it's a bug in the exact line I mentioned 🤦🏻

gutenberg/packages/edit-site/src/components/sidebar-navigation-screen-global-styles/index.js

the feature is toggled ON when its OFF.

@draganescu draganescu added [Status] In Progress Tracking issues with work in progress and removed [Status] Needs More Info Follow-up required in order to be actionable. [Status] Blocked Used to indicate that a current effort isn't able to move forward labels Jun 28, 2023
@priethor priethor removed the [Status] In Progress Tracking issues with work in progress label Jul 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Distraction Free A preference in the Post and Site Editor that limits distractions to focus the editing experience [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants