Skip to content

The empty inside release

Choose a tag to compare

@willmcgugan willmcgugan released this 31 Jul 09:00
· 342 commits to main since this release
c1c94cc

This release adds an :empty pseudo-class which matches widgets with no children. You could use this to hide a container that doesn't have any children, for example:

.container:empty {
    display: none;
}

Also in this release, support for scrolling left and right via the trackpad or a mouse that supports it. This was a contribution from @fancidev

Full changes below:

[5.1.0] - 2025-07-31

Added

  • Added empty pseudo class, which applies when a widget has no displayed children #5999
  • Added Screen.action_focus #5999
  • Added support for left and right mouse scroll for terminals and input devices which support it #5995

Changed

  • last-child, last-of-type, first-child, and first-of-type apply to displayed children only #5999
  • textual.compose is now public #5999