Skip to content

Releases: Textualize/textual

The hidden Tabs release

22 Aug 12:06
bc1af58
Compare
Choose a tag to compare

[0.34.0] - 2023-08-22

Added

  • Methods TabbedContent.disable_tab and TabbedContent.enable_tab #3112
  • Methods Tabs.disable and Tabs.enable #3112
  • Messages Tab.Disabled, Tab.Enabled, Tabs.TabDisabled and Tabs.Enabled #3112
  • Methods TabbedContent.hide_tab and TabbedContent.show_tab #3112
  • Methods Tabs.hide and Tabs.show #3112
  • Messages Tabs.TabHidden and Tabs.TabShown #3112
  • Added ListView.extend method to append multiple items #3012

Changed

  • grid-columns and grid-rows now accept an auto token to detect the optimal size #3107
  • LoadingIndicator now has a minimum height of 1 line.

Fixed

  • Fixed auto height container with default grid-rows #1597
  • Fixed page_up and page_down bug in DataTable when show_header = False #3093

Digits Widget

15 Aug 16:07
4e87a0f
Compare
Choose a tag to compare

Some fixes, and a new Digits widget

Screen.Recording.2023-08-15.at.17.12.11.mov

[0.33.0] - 2023-08-15

Fixed

  • Fixed unintuitive sizing behaviour of TabbedContent #2411
  • Fixed relative units not always expanding auto containers #3059
  • Fixed background refresh #3055
  • Fixed SelectionList.clear_options #3075
  • MouseMove events bubble up from widgets. App and Screen receive MouseMove events even if there's no Widget under the cursor. #2905

Added

  • Added an interface for replacing prompt of an individual option in an OptionList #2603
  • Added DirectoryTree.reload_node method #2757
  • Added widgets.Digit #3073
  • Added BORDER_TITLE and BORDER_SUBTITLE classvars to Widget #3097

Changed

  • DescendantBlur and DescendantFocus can now be used with @on decorator

The Log release

03 Aug 09:15
879c985
Compare
Choose a tag to compare

New Log widget, and TextLog has been renamed to RichLog (breaking change)

Screen.Recording.2023-08-02.at.14.40.33.mov

[0.32.0] - 2023-08-03

Added

  • Added widgets.Log
  • Added Widget.is_vertical_scroll_end, Widget.is_horizontal_scroll_end, Widget.is_vertical_scrollbar_grabbed, Widget.is_horizontal_scrollbar_grabbed

Changed

  • Breaking change: Renamed TextLog to RichLog

Worker update and more

01 Aug 10:10
Compare
Choose a tag to compare

Fixes and updates. Also a few breaking changes, see below for details...

[0.31.0] - 2023-08-01

Added

  • Added App.begin_capture_print, App.end_capture_print, Widget.begin_capture_print, Widget.end_capture_print #2952
  • Added the ability to run async methods as thread workers #2938
  • Added App.stop_animation #2786
  • Added Widget.stop_animation #2786

Changed

  • Breaking change: Creating a thread worker now requires that a thread=True keyword argument is passed #2938
  • Breaking change: Markdown.load no longer captures all errors and returns a bool, errors now propagate #2956
  • Breaking change: the default style of a DataTable now has max-height: 100% #2959

Fixed

  • Fixed a crash when a SelectionList had a prompt wider than itself #2900
  • Fixed a bug where Click events were bubbling up from Switch widgets #2366
  • Fixed a crash when using empty CSS variables #1849
  • Fixed issue with tabs in TextLog #3007
  • Fixed a bug with DataTable hover highlighting #2909

The Notification Release

17 Jul 13:12
ec58b91
Compare
Choose a tag to compare

https://textual.textualize.io/blog/2023/07/17/textual-0300-adds-desktop-style-notifications/

[0.30.0] - 2023-07-17

Added

  • Added DataTable.remove_column method #2899
  • Added notifications #2866
  • Added on_complete callback to scroll methods #2903

Fixed

  • Fixed CancelledError issue with timer #2854
  • Fixed Toggle Buttons issue with not being clickable/hoverable #2930

Refactored dev tools

03 Jul 14:45
65e81c5
Compare
Choose a tag to compare

https://textual.textualize.io/blog/2023/07/03/textual-0290-refactors-dev-tools/

[0.29.0] - 2023-07-03

Changed

  • Factored dev tools (textual command) in to external lib (textual-dev).

Added

  • Added can-focus pseudo-class to target widgets that may receive focus
  • Make Markdown.update optionally awaitable #2838
  • Added default parameter to DataTable.add_column for populating existing rows #2836
  • Added can-focus pseudo-class to target widgets that may receive focus

Fixed

  • Fixed crash when columns were added to populated DataTable #2836
  • Fixed issues with opacity on Screens #2616
  • Fixed style problem with selected selections in a non-focused selection list #2768

Markdown fixes

20 Jun 08:28
14aeb31
Compare
Choose a tag to compare

Mostly fixes for Markdown issues.

[0.28.1] - 2023-06-20

Fixed

  • Fixed indented code blocks not showing up in Markdown #2781
  • Fixed inline code blocks in lists showing out of order in Markdown #2676
  • Fixed list items in a Markdown being added to the focus chain #2380
  • Fixed Tabs posting unnecessary messages when removing non-active tabs #2807
  • call_after_refresh will preserve the sender within the callback #2806

Added

  • Added a method of allowing third party code to handle unhandled tokens in Markdown #2803
  • Added MarkdownBlock as an exported symbol in textual.widgets.markdown #2803

Changed

  • Tooltips are now inherited, so will work with compound widgets

Who remembers Tab Clear ?

19 Jun 09:28
82411ad
Compare
Choose a tag to compare

[0.28.0] - 2023-06-19

Added

  • The devtools console now confirms when CSS files have been successfully loaded after a previous error #2716
  • Class variable CSS to screens #2137
  • Class variable CSS_PATH to screens #2137
  • Added cursor_foreground_priority and cursor_background_priority to DataTable #2736
  • Added Region.center
  • Added center parameter to Widget.scroll_to_region
  • Added origin_visible parameter to Widget.scroll_to_region
  • Added origin_visible parameter to Widget.scroll_to_center
  • Added TabbedContent.tab_count #2751
  • Added TabbedContent.add_pane #2751
  • Added TabbedContent.remove_pane #2751
  • Added TabbedContent.clear_panes #2751
  • Added TabbedContent.Cleared #2751

Fixed

  • Fixed setting TreeNode.label on an existing Tree node not immediately refreshing #2713
  • Correctly implement __eq__ protocol in DataTable #2705
  • Fixed exceptions in Pilot tests being silently ignored #2754
  • Fixed issue where internal data of OptionList could be invalid for short window after clear_options #2754
  • Fixed Tooltip causing a query_one on a lone Static to fail #2723
  • Nested widgets wouldn't lose focus when parent is disabled #2772
  • Fixed the Tabs Underline highlight getting "lost" in some extreme situations #2751

Changed

  • Breaking change: The @on decorator will now match a message class and any child classes #2746
  • Breaking change: Styles update to checkbox, radiobutton, OptionList, Select, SelectionList, Switch #2777
  • Tabs.add_tab is now optionally awaitable #2778
  • Tabs.add_tab now takes before and after arguments to position a new tab #2778
  • Tabs.remove_tab is now optionally awaitable #2778
  • Breaking change: Tabs.clear has been changed from returning self to being optionally awaitable #2778

The sparkly release

01 Jun 10:37
58a9cb1
Compare
Choose a tag to compare

https://textual.textualize.io/blog/2023/06/01/textual-adds-sparklines-selection-list-input-validation-and-tool-tips/

[0.27.0] - 2023-06-01

Fixed

  • Fixed zero division error #2673
  • Fix scroll_to_center when there were nested layers out of view (Compositor full_map not populated fully) #2684
  • Fix crash when Select widget value attribute was set in compose #2690
  • Issue with computing progress in workers #2686
  • Issues with switch_screen not updating the results callback appropriately #2650
  • Fixed incorrect mount order #2702

Added

  • work decorator accepts description parameter to add debug string #2597
  • Added SelectionList widget #2652
  • App.AUTO_FOCUS to set auto focus on all screens #2594
  • Option to scroll_to_center to ensure we don't scroll such that the top left corner of the widget is not visible #2682
  • Added Widget.tooltip property #2670
  • Added Region.inflect #2670
  • Suggester API to compose with widgets for automatic suggestions #2330
  • SuggestFromList class to let widgets get completions from a fixed set of options #2604
  • Input has a new component class input--suggestion #2604
  • Added Widget.remove_children #2657
  • Added Validator framework and validation for Input #2600
  • Added message_hook to App.run_test #2702

Changed

  • Placeholder now sets its color cycle per app #2590
  • Footer now clears key highlight regardless of whether it's in the active screen or not #2606
  • The default Widget repr no longer displays classes and pseudo-classes (to reduce noise in logs). Add them to your __rich_repr__ method if needed. #2623
  • Setting Screen.AUTO_FOCUS to None will inherit AUTO_FOCUS from the app instead of disabling it #2594
  • Setting Screen.AUTO_FOCUS to "" will disable it on the screen #2594
  • Messages now have a handler_name class var which contains the name of the default handler method.
  • Message.control is now a property instead of a class variable. #2528
  • Tree and DirectoryTree Messages no longer accept a tree parameter, using self.node.tree instead. #2529
  • Keybinding right in Input is also used to accept a suggestion if the cursor is at the end of the input #2604
  • Input.__init__ now accepts a suggester attribute for completion suggestions #2604
  • Using switch_screen to switch to the currently active screen is now a no-op #2692

Removed

  • Placeholder.reset_color_cycle
  • Removed Widget.reset_focus (now called Widget.blur) #2642

The Trogon release

20 May 10:33
7d0d1ac
Compare
Choose a tag to compare

New behaviour related to focus. If a newly focused widget is not in view, then it will scroll to center. This more closely matches how browsers behave.

[0.26.0] - 2023-05-20

Added

  • Added Widget.can_view

Changed

  • Textual will now scroll focused widgets to center if not in view