Update total count tracking to always consider the wrapper object

This commit is contained in:
Rapptz committed 2025-08-22 20:05:55 -04:00
1 parent 735b033701
commit 60fd97bfda
6 files changed
+28 -18

No files matched your search

+5
View File
@@ -102,6 +102,11 @@ class Section(Item[V]):
def width(self):
return 5
@property
def _total_count(self) -> int:
# Count the accessory, ourselves, and all children
return 2 + len(self._children)
@property
def accessory(self) -> Item[V]:
""":class:`Item`: The section's accessory."""