Skip to content

Conversation

Sereza7
Copy link
Contributor

@Sereza7 Sereza7 commented Sep 11, 2025

Jira URL

https://jira.xwiki.org/browse/XWIKI-11250

Changes

Description

  • Removed the special Preferences regarding panels in the colortheme section
  • Added a few lines to disable the panels specifically when there's the preview in edit mode.

Clarifications

  • The body class is updated via javascript because the velocity variable is used on that body element before reaching the place where we update it depending on the viewmode in the content. For

Screenshots & Video

Here are what the colortheme pages look like after applying the changes:
Screenshot from 2025-09-11 16-28-04
Screenshot from 2025-09-11 16-27-52
Screenshot from 2025-09-11 16-27-21

Executed Tests

Built the changes with mvn clean install -f xwiki-platform-core/xwiki-platform-flamingo/xwiki-platform-flamingo-theme/xwiki-platform-flamingo-theme-ui -Pquality and then tested them with mvn clean install -f xwiki-platform-core/xwiki-platform-flamingo/xwiki-platform-flamingo-theme/xwiki-platform-flamingo-theme-test/xwiki-platform-flamingo-theme-test-docker

Tested the changes locally.

Expected merging strategy

  • Prefers squash: Yes
  • Backport on branches:
    • None

* Removed the special Preferences regarding panels in the colortheme section
* Added a few lines to disable the panels specifically when there's the preview in edit mode.
## Always hide both side panel columns
#set($showLeftPanels = "0")
#set($showRightPanels = "0")
<script>document.getElementById("body").classList.add("hidelefthideright");</script>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't like the inline script. If the problem is that $showLeftPanels and $showRightPanels are set too late, then maybe we can set them in a UI extension that is executed before they are used (checking before that we are in edit mode and inside the FlamingoThemesCode space, of course).

@Sereza7 Sereza7 marked this pull request as draft October 7, 2025 07:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants