Skip to content

fix: hide the header or footer of a section when its content is hidden - #1370

Merged
mstijak merged 1 commit into
masterfrom
fix/component-visibility
Nov 24, 2026
Merged

mstijak merged 1 commit into
masterfrom
fix/component-visibility

Conversation

@mstijak

@mstijak mstijak commented Nov 24, 2026

Copy link
Copy Markdown
Member

When a child with putInto="header" or putInto="footer" of a Section became invisible, the header or footer stayed on the screen until something else rendered the section again. Widgets now render again when one of their components, such as the header and footer of a Section, is shown or hidden.

Cause

Containers render again when the list of their visible children changes (Container.exploreItems caches instance.children), but Widget.explore did not track its components: a component that became invisible was left out of instance.components, but the widget was not marked for rendering, so its previous output stayed. Widget.explore now caches the names of the visible components and marks the widget for rendering when they change.

This applies to all widgets with components; the only effect is an additional render when a component is shown or hidden.

Tests

  • New ui/Widget.browser.spec.tsx: "are removed from the rendering when they are hidden", with the footer of a Section that is hidden and shown again. It fails without the fix.

When a child with putInto="header" or putInto="footer" of a Section became invisible, the header or footer stayed on the screen until something else rendered the section again. Widgets now render again when one of their components, such as the header and footer of a Section, is shown or hidden.
@mstijak
mstijak merged commit 374acf7 into master Nov 24, 2026
2 checks passed
@mstijak
mstijak deleted the fix/component-visibility branch November 24, 2026 19:17
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.

1 participant