Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions discord/ui/input_text.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ class InputText:
The style of the input text field.
custom_id: Optional[:class:`str`]
The ID of the input text field that gets received during an interaction.
label: Optional[:class:`str`]
The label for the input text field, if any.
label: :class:`str`
The label for the input text field.
Must be 45 characters or fewer.
placeholder: Optional[:class:`str`]
The placeholder text that is shown if nothing is selected, if any.
Expand All @@ -40,7 +40,7 @@ class InputText:
Pre-fills the input text field with this value.
Must be 4000 characters or fewer.
row: Optional[:class:`int`]
The relative row this button belongs to. A Discord component can only have 5
The relative row this input text field belongs to. A modal dialog can only have 5
rows. By default, items are arranged automatically into those 5 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
Expand All @@ -52,7 +52,7 @@ def __init__(
*,
style: InputTextStyle = InputTextStyle.short,
custom_id: str = MISSING,
label: Optional[str] = None,
label: str,
placeholder: Optional[str] = None,
min_length: Optional[int] = None,
max_length: Optional[int] = None,
Expand Down Expand Up @@ -114,7 +114,7 @@ def label(self) -> str:
@label.setter
def label(self, value: str):
if not isinstance(value, str):
raise TypeError(f"label should be None or str not {value.__class__}")
raise TypeError(f"label should be str not {value.__class__}")
self._underlying.label = value

@property
Expand Down