Skip to content

Conversation

@NeloBlivion
Copy link
Member

@NeloBlivion NeloBlivion commented Jan 21, 2026

Summary

Implements radio groups, checkbox groups, and checkboxes in modals
image
Alpha server only right now

Information

  • This PR fixes an issue.
  • This PR adds something new (e.g. new method or parameters).
  • This PR is a breaking change (e.g. methods or parameters removed/renamed).
  • This PR is not a code change (e.g. documentation, README, typehinting,
    examples, ...).

Checklist

  • I have searched the open pull requests for duplicates.
  • If code changes were made then they have been tested.
    • I have updated the documentation to reflect the changes.
  • If type: ignore comments were used, a comment is also left explaining why.
  • I have updated the changelog to include these changes.

@pycord-app
Copy link

pycord-app bot commented Jan 21, 2026

Thanks for opening this pull request!
Please make sure you have read the Contributing Guidelines and Code of Conduct.

This pull request can be checked-out with:

git fetch origin pull/3073/head:pr-3073
git checkout pr-3073

This pull request can be installed with:

pip install git+https://github.com/Pycord-Development/pycord@refs/pull/3073/head

Copy link
Member

@Lulalaby Lulalaby left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SMH blindly copying

Signed-off-by: Lala Sabathil <aiko@aitsys.dev>
Signed-off-by: Lala Sabathil <aiko@aitsys.dev>

- Added `.extension` attribute to emojis to get their file extension.
([#3055](https://github.com/Pycord-Development/pycord/pull/3055))
- Added `RadioGroup`, `CheckboxGroup`, & `Checkbox` for modals.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Added `RadioGroup`, `CheckboxGroup`, & `Checkbox` for modals.
- Added `RadioGroup`, `CheckboxGroup`, and `Checkbox` for modals.

max_values: Optional[:class:`int`]
The maximum number of options that can be selected.
required: Optional[:class:`bool`]
Whether the checkbox group requires a selection or not. Defaults to `True`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Whether the checkbox group requires a selection or not. Defaults to `True`.
Whether the checkbox group requires a selection or not. Defaults to ``True``.

options: List[:class:`RadioGroupOption`]
A list of options that can be selected in this group.
required: Optional[:class:`bool`]
Whether the radio group requires a selection or not. Defaults to `True`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Whether the radio group requires a selection or not. Defaults to `True`.
Whether the radio group requires a selection or not. Defaults to ``True``.

@NeloBlivion NeloBlivion marked this pull request as ready for review January 21, 2026 05:50
Copy link
Member

@plun1331 plun1331 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah that probably looks okay or something and i might have read all the code im not sure

goodnight

@Paillat-dev
Copy link
Member

U mean I going to sleep now I woke upe 30 mins ago lol

self.type = ComponentType.radio_group
self.id: int | None = data.get("id")
self.custom_id = data.get("custom_id")
self.options: list[RadioGroupOption] = [
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not really relevant to now specifically, but while going through this I wondered if there's a reason why we don't use list(.map()) instead of a comprehension

@@ -0,0 +1,115 @@
from __future__ import annotations
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copyrights

Comment on lines +26 to +27
Parameters
----------
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Parameters
----------
Attributes
----------

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants