Skip to content

feat: implement collapse/flip/rotate as buttons AND feat: add commons-demo iconset#161

Open
javier-godoy wants to merge 16 commits into
masterfrom
WIP4
Open

feat: implement collapse/flip/rotate as buttons AND feat: add commons-demo iconset#161
javier-godoy wants to merge 16 commits into
masterfrom
WIP4

Conversation

@javier-godoy

@javier-godoy javier-godoy commented Jul 1, 2026

Copy link
Copy Markdown
Member

Summary by CodeRabbit

  • New Features
    • Added source-code viewer overlay controls (show/hide, flip, rotate) across the relevant demos.
    • Introduced the commons-demo iconset and new demo icon factory.
    • Added public events/listeners for source collapse, source position, and split orientation.
    • Added SourcePosition.DEFAULT with improved inheritance/carry-over behavior.
  • Bug Fixes
    • Improved overlay/viewer synchronization during attach, scrolling, and layout/content swapping.
  • Tests
    • Added/expanded integration and UI tests covering overlay controls, splitter behavior, and event firing.
  • Chores
    • Updated snapshot version to 5.4.0-SNAPSHOT and refreshed test dependencies.

@coderabbitai

coderabbitai Bot commented Jul 1, 2026

Copy link
Copy Markdown

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

Walkthrough

Adds source-viewer overlay controls with custom icons, event-driven collapse/position/orientation handling, updated SplitLayoutDemo and TabbedDemo integration, responsive styling, behavioral tests, inherited annotations, and Maven version/dependency updates.

Changes

Source viewer overlay controls and demo integration

Layer / File(s) Summary
Overlay icons and client controls
base/.../CommonsDemoIcons.java, base/.../frontend/commons-demo-iconset.ts, base/.../frontend/source-code-viewer-buttons.ts
Adds the commons-demo icon API and frontend iconset, plus LitElement controls for show, hide, flip, and rotate actions.
Source viewer overlay wiring
base/.../SourceCodeViewer.java, base/.../MultiSourceCodeViewer.java, base/.../styles/commons-demo/shared-styles.css
Adds overlay containers, button mounting, scrollbar observation, event propagation, and responsive overlay styling.
Demo event contracts and SplitLayout API
base/.../events/*, base/.../SourcePosition.java, base/.../SplitLayoutDemo.java
Adds collapse, source-position, and orientation events, introduces DEFAULT, and replaces splitter/show-hide APIs with collapsed-state and source-position methods.
TabbedDemo state and event integration
base/.../TabbedDemo.java, base/.../DemoSource.java, base/.../DemoSources.java
Replaces footer checkbox coordination with event-driven state updates, client-origin tracking, listener registration, inherited annotations, and source-position/orientation preservation.
Validation and build wiring
base/src/test/..., base/src/test/resources/..., base/pom.xml, pom.xml, processor/pom.xml
Adds unit and browser coverage, registers the instrumented test route, and updates project versions and test dependencies.

Estimated code review effort: 4 (Complex) | ~60 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 39.56% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title accurately describes the main change: adding button-based collapse/flip/rotate controls and the commons-demo iconset.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch WIP4

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 6

🧹 Nitpick comments (4)
base/src/main/resources/META-INF/resources/frontend/styles/commons-demo/shared-styles.css (2)

132-132: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Comment formatting nit flagged by stylelint.

Missing whitespace before */.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@base/src/main/resources/META-INF/resources/frontend/styles/commons-demo/shared-styles.css`
at line 132, The CSS comment in shared-styles.css is missing the required
whitespace before the closing terminator, which is being flagged by stylelint.
Update the comment formatting so the text inside the comment has a space before
*/ and matches the project’s linted comment style, using the nearby stylesheet
comment near the icon rotation rule to locate it.

Source: Linters/SAST tools


98-101: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Declaration spacing flagged by stylelint.

declaration-empty-line-before expects a blank line before padding at line 100 per the project's stylelint config.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@base/src/main/resources/META-INF/resources/frontend/styles/commons-demo/shared-styles.css`
around lines 98 - 101, The stylelint rule on the shared-styles.css selector for
vaadin-button.source-code-viewer-button vaadin-icon is flagging declaration
spacing. Update that block so there is a blank line before the padding
declaration, keeping the existing --vaadin-icon-size and padding declarations
intact and matching the project’s declaration-empty-line-before convention.

Source: Linters/SAST tools

base/src/main/resources/META-INF/resources/frontend/commons-demo-iconset.ts (1)

111-118: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Unused home/github icons.

Neither icon is referenced by CommonsDemoIcons (only ROTATE, FLIP, HIDE_SOURCE, SHOW_SOURCE are defined). These appear to be leftovers from a copy-pasted template and add unused markup/license baggage.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@base/src/main/resources/META-INF/resources/frontend/commons-demo-iconset.ts`
around lines 111 - 118, The <g id="home"> and <g id="github"> entries in
CommonsDemoIconset are unused leftovers and should be removed from the sprite
definition. Update commons-demo-iconset.ts to keep only the icons actually
referenced by CommonsDemoIcons (ROTATE, FLIP, HIDE_SOURCE, SHOW_SOURCE) so the
generated asset matches the exported API and avoids unnecessary markup.
base/src/main/java/com/flowingcode/vaadin/addons/demo/CommonsDemoIcons.java (1)

67-69: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Stale Javadoc copied from another iconset.

{@code Brands} doesn't describe this component; looks copy-pasted from a different icon set.

✏️ Suggested fix
-  /**
-   * Server side component for {`@code` Brands}
-   */
+  /**
+   * Server side component for {`@code` CommonsDemoIcons}.
+   */
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@base/src/main/java/com/flowingcode/vaadin/addons/demo/CommonsDemoIcons.java`
around lines 67 - 69, The Javadoc on CommonsDemoIcons has stale copy-pasted text
that references Brands instead of this icon set. Update the comment for the
server-side component in CommonsDemoIcons so it describes the actual
component/name being documented, using the existing class context rather than
the copied {`@code` Brands} reference.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@base/src/main/java/com/flowingcode/vaadin/addons/demo/MultiSourceCodeViewer.java`:
- Around line 86-88: The MultiSourceCodeViewer.withButtons() path can
dereference codeViewer before it is initialized when all tabs are filtered out,
so add a guard for the empty-viewer case. Update the withButtons() method to
no-op or safely return this when codeViewer is absent, using the
MultiSourceCodeViewer constructor/empty-state setup and the codeViewer field as
the key locations to check.

In `@base/src/main/java/com/flowingcode/vaadin/addons/demo/SourceCodeViewer.java`:
- Around line 96-98: Update the Javadoc in SourceCodeViewer so it does not imply
the integrated button handling is purely client-side with no server involvement.
In the SourceCodeViewer documentation near the explanation of
source-code-viewer-buttons, clarify that while the web component dispatches DOM
events locally, TabbedDemo handles those events through Vaadin server-side
listeners. Keep the idempotent/added only once note, but remove or reword the
“no server roundtrip” statement to accurately reflect the server-side handling.

In `@base/src/main/java/com/flowingcode/vaadin/addons/demo/TabbedDemo.java`:
- Around line 368-372: In setSourcePosition(SourcePosition, boolean), the source
pane position is updated but the splitter state is not reapplied, so a collapsed
source can inherit the old percentage after swapping sides. After
currentLayout.setSourcePosition(...) and before/after
fireSourcePositionChangedEvent(...), call updateSplitterPosition() when
sourceCollapsed is true so the collapsed splitter position is restored
correctly. Use setSourcePosition and updateSplitterPosition in TabbedDemo to
locate the change.
- Around line 407-411: The `setOrientation(...)` flow in `TabbedDemo` expands
the splitter via `currentLayout.setSourceCollapsed(false)` but leaves the
`sourceCollapsed` state inconsistent, so the next `updateSplitterPosition()` can
re-collapse it and listeners miss the change. Update the orientation-handling
path in `setOrientation` (and any related `sourceCollapsed` state in
`currentLayout`) so forcing the source visible also resets the internal collapse
flag and emits the matching collapse-change event, keeping the layout state and
listeners in sync.

In
`@base/src/main/resources/META-INF/resources/frontend/styles/commons-demo/shared-styles.css`:
- Around line 132-151: The CSS in the shared-styles rules for
source-code-viewer-button uses an invalid transform function name. Update the
two source-code-viewer-rotate-button transform declarations in the
orientation-specific rules to use the standard CSS function name scaleX instead
of scalex, keeping the same rotate values and selectors.

In `@processor/pom.xml`:
- Line 8: Update the version alignment in processor/pom.xml so the processor
module and its related dependency property stay on the same release. In the POM,
bump the commons-demo.version property to match the new 5.4.0-SNAPSHOT
project/base version, and verify any dependency declarations that use that
property continue to point at the updated version. Focus on the version fields
in the POM rather than changing module structure.

---

Nitpick comments:
In `@base/src/main/java/com/flowingcode/vaadin/addons/demo/CommonsDemoIcons.java`:
- Around line 67-69: The Javadoc on CommonsDemoIcons has stale copy-pasted text
that references Brands instead of this icon set. Update the comment for the
server-side component in CommonsDemoIcons so it describes the actual
component/name being documented, using the existing class context rather than
the copied {`@code` Brands} reference.

In `@base/src/main/resources/META-INF/resources/frontend/commons-demo-iconset.ts`:
- Around line 111-118: The <g id="home"> and <g id="github"> entries in
CommonsDemoIconset are unused leftovers and should be removed from the sprite
definition. Update commons-demo-iconset.ts to keep only the icons actually
referenced by CommonsDemoIcons (ROTATE, FLIP, HIDE_SOURCE, SHOW_SOURCE) so the
generated asset matches the exported API and avoids unnecessary markup.

In
`@base/src/main/resources/META-INF/resources/frontend/styles/commons-demo/shared-styles.css`:
- Line 132: The CSS comment in shared-styles.css is missing the required
whitespace before the closing terminator, which is being flagged by stylelint.
Update the comment formatting so the text inside the comment has a space before
*/ and matches the project’s linted comment style, using the nearby stylesheet
comment near the icon rotation rule to locate it.
- Around line 98-101: The stylelint rule on the shared-styles.css selector for
vaadin-button.source-code-viewer-button vaadin-icon is flagging declaration
spacing. Update that block so there is a blank line before the padding
declaration, keeping the existing --vaadin-icon-size and padding declarations
intact and matching the project’s declaration-empty-line-before convention.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 36cdc2dd-e712-4dee-8b65-d27d3e275d4a

📥 Commits

Reviewing files that changed from the base of the PR and between fd1c9cb and 6261172.

📒 Files selected for processing (14)
  • base/pom.xml
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/CommonsDemoIcons.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/MultiSourceCodeViewer.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/SourceCodeViewer.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/SplitLayoutDemo.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/TabbedDemo.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/events/OrientationChangedEvent.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/events/SourceCollapseChangedEvent.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/events/SourcePositionChangedEvent.java
  • base/src/main/resources/META-INF/resources/frontend/commons-demo-iconset.ts
  • base/src/main/resources/META-INF/resources/frontend/source-code-viewer-buttons.ts
  • base/src/main/resources/META-INF/resources/frontend/styles/commons-demo/shared-styles.css
  • pom.xml
  • processor/pom.xml

Comment thread base/src/main/java/com/flowingcode/vaadin/addons/demo/SourceCodeViewer.java Outdated
Comment thread processor/pom.xml
@javier-godoy

Copy link
Copy Markdown
Member Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 2, 2026

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🧹 Nitpick comments (2)
base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayControlsIT.java (1)

58-60: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Clarify the intent of the unassigned findElement call.

The call to getDriver().findElement(By.id("content")); is unassigned and relies on throwing a NoSuchElementException to fail the test if the element is missing. Wrapping this in an assertion (like assertTrue) or an explicit wait clarifies the intent and can provide a better failure message.

♻️ Proposed refactor
     getCommandExecutor().waitForVaadin();
-    getDriver().findElement(By.id("content"));
+    assertTrue("Content element should be present", hasElement("`#content`"));
     waitUntil(d -> hasElement("vaadin-button.source-code-viewer-hide-button"));
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayControlsIT.java`
around lines 58 - 60, Clarify the content-element check in OverlayControlsIT by
replacing the unassigned getDriver().findElement(By.id("content")) call with an
explicit assertion or wait. Preserve the existing requirement that the test
fails when the content element is absent, while providing a clear failure
condition or message.
base/src/main/resources/META-INF/resources/frontend/commons-demo-iconset.ts (1)

122-124: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Avoid shadowing the imported Iconset class.

The parameter Iconset in the .then() callback shadows the Iconset class already imported at the top of the file (line 21). You can omit the parameter for cleaner and less confusing code.

♻️ Proposed refactor
-customElements.whenDefined('vaadin-iconset').then(Iconset=>{
+customElements.whenDefined('vaadin-iconset').then(() => {
   Iconset.register('commons-demo', 24, template);
 });
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@base/src/main/resources/META-INF/resources/frontend/commons-demo-iconset.ts`
around lines 122 - 124, Update the customElements.whenDefined callback to omit
its Iconset parameter and use the imported Iconset class directly when calling
register, avoiding shadowing while preserving the existing commons-demo
registration.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@base/src/main/resources/META-INF/resources/frontend/commons-demo-iconset.ts`:
- Around line 122-124: Update the customElements.whenDefined callback to omit
its Iconset parameter and use the imported Iconset class directly when calling
register, avoiding shadowing while preserving the existing commons-demo
registration.

In
`@base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayControlsIT.java`:
- Around line 58-60: Clarify the content-element check in OverlayControlsIT by
replacing the unassigned getDriver().findElement(By.id("content")) call with an
explicit assertion or wait. Preserve the existing requirement that the test
fails when the content element is absent, while providing a clear failure
condition or message.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 59292c4e-091f-4176-a3ef-e3f1259e8178

📥 Commits

Reviewing files that changed from the base of the PR and between 3f79b6d and a34c487.

📒 Files selected for processing (23)
  • base/pom.xml
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/CommonsDemoIcons.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/DemoSource.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/DemoSources.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/MultiSourceCodeViewer.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/SourceCodeViewer.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/SplitLayoutDemo.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/TabbedDemo.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/events/OrientationChangedEvent.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/events/SourceCollapseChangedEvent.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/events/SourcePositionChangedEvent.java
  • base/src/main/resources/META-INF/resources/frontend/commons-demo-iconset.ts
  • base/src/main/resources/META-INF/resources/frontend/source-code-viewer-buttons.ts
  • base/src/main/resources/META-INF/resources/frontend/styles/commons-demo/shared-styles.css
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayCallables.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayControlsIT.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayView.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/TabbedDemoUIUnitTest.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/ViewInitializerImpl.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/test/SplitLayoutDemoTest.java
  • base/src/test/resources/META-INF/services/com.vaadin.flow.server.VaadinServiceInitListener
  • pom.xml
  • processor/pom.xml
🚧 Files skipped from review as they are similar to previous changes (10)
  • pom.xml
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/events/OrientationChangedEvent.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/events/SourcePositionChangedEvent.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/CommonsDemoIcons.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/MultiSourceCodeViewer.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/events/SourceCollapseChangedEvent.java
  • base/src/main/resources/META-INF/resources/frontend/source-code-viewer-buttons.ts
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/SourceCodeViewer.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/SplitLayoutDemo.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/TabbedDemo.java

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🧹 Nitpick comments (1)
base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayControlsIT.java (1)

48-48: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Rename the field to match standard Java naming conventions.

The field name $server does not follow standard Java naming conventions. Consider renaming it to server or serverProxy to align with the regular expression ^[a-z][a-zA-Z0-9]*$ and resolve the SonarCloud Code Analysis warning.

♻️ Proposed fix
-  private final OverlayCallables $server = createCallableProxy(OverlayCallables.class);
+  private final OverlayCallables serverProxy = createCallableProxy(OverlayCallables.class);

(Note: Please also update all $server references in the test methods below.)

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayControlsIT.java`
at line 48, Rename the OverlayControlsIT field $server to server (or
serverProxy) to comply with Java naming conventions, and update every reference
to that field throughout the test methods while preserving the existing
callable-proxy behavior.

Source: Linters/SAST tools

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In
`@base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayControlsIT.java`:
- Line 48: Rename the OverlayControlsIT field $server to server (or serverProxy)
to comply with Java naming conventions, and update every reference to that field
throughout the test methods while preserving the existing callable-proxy
behavior.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 50a17e92-e21d-4c5e-9dd5-52496a11d5ef

📥 Commits

Reviewing files that changed from the base of the PR and between a34c487 and e15e7c0.

📒 Files selected for processing (15)
  • base/pom.xml
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/DemoSource.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/DemoSources.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/MultiSourceCodeViewer.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/SourcePosition.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/SplitLayoutDemo.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/TabbedDemo.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayCallables.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayControlsIT.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayView.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/TabbedDemoUIUnitTest.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/TabbedDemoView.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/ViewInitializerImpl.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/test/SplitLayoutDemoTest.java
  • base/src/test/resources/META-INF/services/com.vaadin.flow.server.VaadinServiceInitListener
🚧 Files skipped from review as they are similar to previous changes (11)
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayCallables.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/DemoSources.java
  • base/src/test/resources/META-INF/services/com.vaadin.flow.server.VaadinServiceInitListener
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/MultiSourceCodeViewer.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/TabbedDemoUIUnitTest.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/OverlayView.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/SplitLayoutDemo.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/it/ViewInitializerImpl.java
  • base/src/test/java/com/flowingcode/vaadin/addons/demo/test/SplitLayoutDemoTest.java
  • base/src/main/java/com/flowingcode/vaadin/addons/demo/TabbedDemo.java
  • base/pom.xml

When the source is collapsed, swapping its side did not touch the
splitter, so the collapsed pane inherited the previous side's
percentage (e.g. showing the source full and hiding the demo instead of
staying collapsed). Reapply the collapsed splitter position for the new
side.
Changing the orientation forced the source visible via
setSourceCollapsed(false) without updating sourceCollapsed or notifying
listeners, leaving the layout and its state out of sync (e.g. a
collapsed source was re-expanded on mobile). Reapply the current
collapse state instead.
@sonarqubecloud

Copy link
Copy Markdown

@javier-godoy

Copy link
Copy Markdown
Member Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 17, 2026

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@javier-godoy
javier-godoy requested review from paodb and scardanzan July 17, 2026 15:38
@javier-godoy
javier-godoy marked this pull request as ready for review July 17, 2026 15:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: To Do

Development

Successfully merging this pull request may close these issues.

1 participant