Browse Source

Update documentation on select limits

pull/7479/head
Rapptz 4 years ago
parent
commit
3382d2e9e8
  1. 4
      discord/components.py
  2. 4
      discord/ui/select.py

4
discord/components.py

@ -277,14 +277,14 @@ class SelectOption:
----------- -----------
label: :class:`str` label: :class:`str`
The label of the option. This is displayed to users. The label of the option. This is displayed to users.
Can only be up to 25 characters. Can only be up to 100 characters.
value: :class:`str` value: :class:`str`
The value of the option. This is not displayed to users. The value of the option. This is not displayed to users.
If not provided when constructed then it defaults to the If not provided when constructed then it defaults to the
label. Can only be up to 100 characters. label. Can only be up to 100 characters.
description: Optional[:class:`str`] description: Optional[:class:`str`]
An additional description of the option, if any. An additional description of the option, if any.
Can only be up to 50 characters. Can only be up to 100 characters.
emoji: Optional[Union[:class:`str`, :class:`Emoji`, :class:`PartialEmoji`]] emoji: Optional[Union[:class:`str`, :class:`Emoji`, :class:`PartialEmoji`]]
The emoji of the option, if available. The emoji of the option, if available.
default: :class:`bool` default: :class:`bool`

4
discord/ui/select.py

@ -197,13 +197,13 @@ class Select(Item[V]):
----------- -----------
label: :class:`str` label: :class:`str`
The label of the option. This is displayed to users. The label of the option. This is displayed to users.
Can only be up to 25 characters. Can only be up to 100 characters.
value: :class:`str` value: :class:`str`
The value of the option. This is not displayed to users. The value of the option. This is not displayed to users.
If not given, defaults to the label. Can only be up to 100 characters. If not given, defaults to the label. Can only be up to 100 characters.
description: Optional[:class:`str`] description: Optional[:class:`str`]
An additional description of the option, if any. An additional description of the option, if any.
Can only be up to 50 characters. Can only be up to 100 characters.
emoji: Optional[Union[:class:`str`, :class:`.Emoji`, :class:`.PartialEmoji`]] emoji: Optional[Union[:class:`str`, :class:`.Emoji`, :class:`.PartialEmoji`]]
The emoji of the option, if available. This can either be a string representing The emoji of the option, if available. This can either be a string representing
the custom or unicode emoji or an instance of :class:`.PartialEmoji` or :class:`.Emoji`. the custom or unicode emoji or an instance of :class:`.PartialEmoji` or :class:`.Emoji`.

Loading…
Cancel
Save