Update total count tracking to always consider the wrapper object

This commit is contained in:
Rapptz
2025-08-21 22:20:12 -04:00
parent 0309aac335
commit 9bda89b0d6
6 changed files with 28 additions and 18 deletions

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."""