|
@ -128,6 +128,13 @@ class ActionRow(Item[V]): |
|
|
---------- |
|
|
---------- |
|
|
*children: :class:`Item` |
|
|
*children: :class:`Item` |
|
|
The initial children of this action row. |
|
|
The initial children of this action row. |
|
|
|
|
|
row: Optional[:class:`int`] |
|
|
|
|
|
The relative row this action row belongs to. By default |
|
|
|
|
|
items are arranged automatically into those rows. If you'd |
|
|
|
|
|
like to control the relative positioning of the row then |
|
|
|
|
|
passing an index is advised. For example, row=1 will show |
|
|
|
|
|
up before row=2. Defaults to ``None``, which is automatic |
|
|
|
|
|
ordering. The row number must be between 0 and 39 (i.e. zero indexed) |
|
|
id: Optional[:class:`int`] |
|
|
id: Optional[:class:`int`] |
|
|
The ID of this component. This must be unique across the view. |
|
|
The ID of this component. This must be unique across the view. |
|
|
""" |
|
|
""" |
|
@ -139,6 +146,7 @@ class ActionRow(Item[V]): |
|
|
def __init__( |
|
|
def __init__( |
|
|
self, |
|
|
self, |
|
|
*children: Item[V], |
|
|
*children: Item[V], |
|
|
|
|
|
row: Optional[int] = None, |
|
|
id: Optional[int] = None, |
|
|
id: Optional[int] = None, |
|
|
) -> None: |
|
|
) -> None: |
|
|
super().__init__() |
|
|
super().__init__() |
|
@ -151,6 +159,7 @@ class ActionRow(Item[V]): |
|
|
raise ValueError('maximum number of children exceeded') |
|
|
raise ValueError('maximum number of children exceeded') |
|
|
|
|
|
|
|
|
self.id = id |
|
|
self.id = id |
|
|
|
|
|
self.row = row |
|
|
|
|
|
|
|
|
def __init_subclass__(cls) -> None: |
|
|
def __init_subclass__(cls) -> None: |
|
|
super().__init_subclass__() |
|
|
super().__init_subclass__() |
|
|