-
-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Components V2 #10166
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
+4,214
−298
Merged
Components V2 #10166
Changes from 238 commits
Commits
Show all changes
286 commits
Select commit
Hold shift + click to select a range
6c02a7d
chore: docs
DA-344 67bfa57
chore: run black
DA-344 0b23f10
chore: fix discord.ui.View
DA-344 eae0895
chore: fix linting
DA-344 c63ad95
chore: more linting things and docs
DA-344 7338da2
fix linting yet again
DA-344 c5ffc6a
chore: fix LayoutView.to_components
DA-344 59991e9
chore: fix Container.to_components returning NotImplemented
DA-344 502051a
chore: update ActionRow and View
DA-344 f1f6ef8
chore: remove unused imports
DA-344 9e18c5a
chore: typing stuff
DA-344 e660010
chore: more typing stuff
DA-344 c48c512
chore: some fixes of bugs reported on the bikeshedding post
DA-344 8cb80bf
chore: improve check on container.__init_subclass__
DA-344 7601533
chore: add id attr to components and black item.py
DA-344 9891f85
chore: add id to every item
DA-344 c93ee07
fix: Container._colour raising ValueError
DA-344 09fceae
fix: Container.is_dispatchable making buttons not work
DA-344 8399677
fix: Container children not being added to view store
DA-344 9700606
chore: Update Container._update_store_data
DA-344 0f7d72b
chore: Update Container.is_dispatchable
DA-344 cf4db91
chore: Remove unused imports
DA-344 6d50c88
chore: Metadata for Section
DA-344 9655749
fix: Section.accessory not being dispatched
DA-344 5120b0d
chore: Update ViewStore to handle Section.accessory properly
DA-344 4c668ba
template
DA-344 84ad47f
chore: Remove unneccessary # type: ignore
DA-344 7433ad0
chore: Fix Section.accessory raising an error when clicked
DA-344 810fe57
chore: Update container to also take in account section accessories
DA-344 52f9b6a
chore: Some changes on how Section.accessory is handled in Container
DA-344 8561953
chore: Add container add/remove/clear_item(s)
DA-344 8926f28
fix: Section.accessory._view being None when in a container
DA-344 b1e8aef
fix: Containers not dispatching ActionRow items correctly
DA-344 4c662a9
chore: Some changes, fixes, and typo corrections
DA-344 dddf502
Merge branch 'feat/components-v2' of https://github.com/DA-344/d.py i…
DA-344 a93a639
Merge branch 'master' of https://github.com/rapptz/discord.py into fe…
DA-344 4ef1e46
chore: Add ActionRow to docs
DA-344 86dd8d8
chore: Add get_item_by_id to remaining items
DA-344 cd9f776
some fixes and typings
DA-344 5dddf65
run black
DA-344 a1216e7
fix error when using Message.components
DA-344 cba602d
chore: Add more params to MessageFlags.components_v2 docstring
DA-344 e9d942b
chore: typings
DA-344 ec186ab
chore: update docstrings
DA-344 b0bab6d
fix: `children` parameter being ignored on Container
DA-344 412caa6
update ActionRow.select docstring
DA-344 9026bcb
add note about Item.custom_id
DA-344 cf949c6
chore: some bunch fixes and make interaction_check's work on every item
DA-344 fb8e85d
fix: typings
DA-344 fe7d7f2
chore: Update view param docstring on send methods
DA-344 195b9e7
chore: Allow ints on accent_colo(u)r on Container's
DA-344 7028911
fix: Item.view not being correctly set when using 'add_item' methods
DA-344 86ec834
chore: Update BaseView.__repr__
DA-344 8376dbf
chore: Add Thumbnail.description char limit to docs
DA-344 9f3f8f1
chore: Add MediaGalleryItem.description char limit to docs
DA-344 e0c0753
chore: Update interactions docs
DA-344 2248df0
chore: Add char limit to TextDisplay
DA-344 22e4738
chore: Fix interaction_check not being called correctly
DA-344 92cb557
chore: Remove leftover code
DA-344 876397e
chore: Improve Items documentation
DA-344 4cb3b41
chore: more docs things ig
DA-344 f5ec966
chore: typings and docs and idk what more
DA-344 0dbd465
fix: g
DA-344 af952d3
chore: add LayoutView example
DA-344 f5415f5
chore: remove deprecation warning
DA-344 952a623
remove unused import
DA-344 c5d7450
fix: strange error: https://discord.com/channels/336642139381301249/1…
DA-344 01d3bb2
Merge branch 'feat/components-v2' of https://github.com/DA-344/d.py i…
DA-344 dbd8cd6
chore: update container and things
DA-344 7ed69ec
chore: children, * -> *children
DA-344 95a22ce
.
DA-344 776d5e1
unpack
DA-344 038ca4a
more unpack
DA-344 ab49798
chore: Update examples and things
DA-344 5a1afb6
chore: Update message.component doc types
DA-344 de4d8c4
fix: LayoutView’s duplicating items
DA-344 5162d17
fix typings and errors
DA-344 a8285e1
more typings
DA-344 aa41094
fix: Non-dispatchable items breaking persistent views
DA-344 7741166
chore: Add (View|Container|ActionRow|Section).walk_children methods
DA-344 0621b38
chore: Update overloads typings
DA-344 2da3a14
chore: Raise LayoutView component limit to 40 and remove component li…
DA-344 d41d711
list -> tuple
DA-344 50c40a2
fix: Change send type to None in Section.walk_children return type
DA-344 b0b332a
fix: Add/Modify View/Container.walk_children return types
DA-344 9c745bb
chore: run black
DA-344 4044b2c
chore: add *children param and validation for children
DA-344 145af2f
chore: update docstrings
DA-344 27db09a
chore: overloads
DA-344 0396417
rows
DA-344 7012cec
fix: LayoutView.__total_children being incorrectly set when adding/re…
DA-344 e29c10d
fix: Webhook.send overloads missing ephemeral kwarg
DA-344 6122b32
fix: Sorting LayoutView children defaulting to 0 instead of sys.maxsize
DA-344 7b5f247
chore: Add call to super().__init_subclass__()
DA-344 cf08c0e
chore: Remove ValueError on Container.add_item
DA-344 4ca483e
chore: fix is_persistent and default to sys.maxsize instead of 0 on s…
DA-344 4103a97
things
DA-344 176d0a4
fix attr error things
DA-344 8f39bf5
fix: rows being set weirdly because of sorted
DA-344 8fc329d
fix: missing applied_tags param on overloads
DA-344 0b25cf7
chore: dynamic items
DA-344 1281a2e
chore: black
DA-344 736fbfc
fix: typings on examples of dynamic
DA-344 a19055b
__dispatchable having children that were removed from the Container
DA-344 eb38195
fix: Container.__dispatchable not having new dispatchable nested item…
DA-344 091705c
chore: remove _ViewWeights leftover code
DA-344 eb2996d
Make Container._init_children more similar to BaseView._init_children
DA-344 98b6322
if
DA-344 4005399
chore: remove setting default row
DA-344 2f029c3
fix: Container rows
DA-344 acd17d8
chore: Update LayoutView.to_components()
DA-344 1b676df
chore: Improve documentation on MediaGallery(Item) and ui.File
DA-344 6e302a3
fix: is_persistent returning wrong values
DA-344 8e03c3a
fix: is_persistent in container.py
DA-344 e329422
feat: Add (Layout)View.from_dict methods
DA-344 f63f9f6
chore: Consistency on types
DA-344 b221fd2
Merge branch 'feat/components-v2' of https://github.com/DA-344/d.py i…
DA-344 22daf24
fix: View.from_dict raising unexpected errors
DA-344 b4b7a74
yet more fixes
DA-344 5489806
fix: row not being respected when being 0
DA-344 c9e0f35
fix: linting
DA-344 03af02b
chore: Run black and fix linting errors
DA-344 3d37331
chore:
DA-344 fe3b596
fix: unexpected behaviour on accent_colours
DA-344 cf21c5b
chore: revert double quotes to single quotes
DA-344 0a8d9cb
chore: check types on Container.accent_colour setter
DA-344 f0c0e40
fix: Colo(u)r being on TYPE_CHECKING block
DA-344 d65437b
chore: QoL changes on BaseView.from_message and BaseView.from_dict an…
DA-344 3bba5b4
Merge branch 'feat/components-v2' of https://github.com/DA-344/d.py i…
DA-344 42bd21a
chore(breaking): Rename SeparatorSize to SeparatorSpacing
DA-344 3dfc609
fix: SpacingSpace not being found on docs
DA-344 d4e738a
qol things and changes
DA-344 ff55d37
changes to every item, mostly on repr
DA-344 12abc1a
chore: fix DynamicItem errors
DA-344 5bde2f0
chore: rename Section.get_item_by_id to Section.get_item
DA-344 d124702
itertools.groupby bye
DA-344 78ed233
shuold
DA-344 49125e8
chore: update ViewStore.dispatch_view
DA-344 8f03384
fix on the previous commit lol
DA-344 b843272
Revert "chore: update ViewStore.dispatch_view"
DA-344 59321d3
revert " fix on the previous commit\
DA-344 e1d8a84
chore: change get_item behaviour
DA-344 ca62512
fix: description key always present when being None
DA-344 ad36136
chore: update types
DA-344 4f20405
chore: Add Container.type property
DA-344 f1c397d
typing
DA-344 0d86c55
chore: use a truthy check instead of a is not None
DA-344 d9f0be7
add attachment_id and name & size
DA-344 3582bf6
fix: dynamic item calls failing
DA-344 04d1ca0
fix: dynamic items strange cases
DA-344 7e071ff
chore: remove unused imports & run black
DA-344 4bd97e1
chore: fix messy code on ViewStore.schedule_dynamic_item_call
DA-344 8c807e1
chore: update some things for storing items
DA-344 7345812
fix: typings
DA-344 14bf8c1
fix: Section not having all attributes due to cls.__new__(cls)
DA-344 c4225ec
chore: remove unused functions and attributes
DA-344 3040529
chore: remove unused imports and typings
DA-344 3465426
chore: revert removing comments
DA-344 8a79252
typo
DA-344 3697a9b
chore: prevent storing non-interactable views and various fixes
DA-344 9fc0d3f
fix: ActionRow missing id
DA-344 5d5f4b6
fix: total_children not being updated when using add_item
DA-344 c03afaa
fix: views saying that arent dispatchable when they are
DA-344 d5d3348
merge master
DA-344 0342bec
update container.accent_colour to not raise errors on None
DA-344 06f4052
chore: Add notes on LayoutView behaviour when editing messages
DA-344 afedd77
Merge branch 'feat/components-v2' of https://github.com/DA-344/d.py i…
DA-344 67d67d3
chore: Clarify note on message edit related methods
DA-344 b699e7e
versionadded's and reorders
DA-344 0f9b605
add LayoutView to Item.view docstring
DA-344 c2bc491
code qol changes and docs
DA-344 3cf9589
merge master to feat/components-v2
DA-344 6a75fd9
Update discord/ui/view.py
DA-344 d601adf
Update discord/ui/action_row.py
DA-344 a8c66dc
Update discord/ui/action_row.py
DA-344 099bd48
use view._is_v2() instead of __discord_ui_layout_view__
DA-344 3cf3e1a
remove _can_be_dynamic
DA-344 482a1cd
remove _can_be_dynamic
DA-344 97932c7
Update discord/ui/media_gallery.py
DA-344 0a05483
rename ._is_v2() to ._is_layout()
DA-344 61162c6
remove outdated width property
DA-344 db71172
rename SectionComponent.components to SectionComponent.children
DA-344 5a137e8
typings and remove View.from_dict
DA-344 455df63
Merge branch 'feat/components-v2' of https://github.com/DA-344/d.py i…
DA-344 ad86240
fix docs
DA-344 5a5d270
typing
DA-344 fc6283a
Update discord/ui/container.py
DA-344 9f13513
Update discord/ui/section.py
DA-344 a1ba2f2
update ActionRow
DA-344 53d67e1
Merge branch 'feat/components-v2' of https://github.com/DA-344/d.py i…
DA-344 f1c11f1
update Section.from_component
DA-344 e75b1d5
remove row from v2 components, and add notes on button and select
DA-344 bd5e163
add note on missing places
DA-344 8041a08
remove MISSING check
DA-344 c81fa35
Merge branch 'master' of https://github.com/Rapptz/discord.py into fe…
DA-344 7a13bb0
run black
DA-344 f8ed5cb
remove unused imports
DA-344 12d8acb
# type: ignore
DA-344 5f227bf
replace \_\_discord_ui_update_view_\_ with methods
DA-344 ef43ef6
remove old comment
DA-344 5361ff1
add Item.parent property
DA-344 3025e3d
fix attribute errors
DA-344 89a2930
Update discord/ui/action_row.py
DA-344 478e629
typos
DA-344 f4a68f2
Update discord/ui/item.py
DA-344 917b37c
Update discord/ui/thumbnail.py
DA-344 eb4fe85
Update discord/ui/media_gallery.py
DA-344 23cfe7b
docstring
DA-344 79223e5
consistency
DA-344 f2bddc0
do actual weight checking
DA-344 5cb171e
changes
DA-344 a494bf4
Merge branch 'feat/components-v2' of https://github.com/DA-344/d.py i…
DA-344 291bcb2
run black
DA-344 8bf48e1
fix typings on interaction
DA-344 ce5a4be
add item._has_children
DA-344 d981703
remove versionchanged note on send/edit methods
DA-344 fc1634c
add missing id params on ActionRow.button and ActionRow.select decora…
DA-344 64668e7
add Section in TextDisplay docstring
DA-344 9ff8d82
remove unused import
DA-344 e1e12fe
i broke docs lol
DA-344 40aced5
add Separator to docstring
DA-344 e6d3f32
replace RuntimeError with ValueError
DA-344 6beab8e
replace RuntimeError with ValueError
DA-344 a55186d
not set rendered row in row.setter
DA-344 9a6b779
fix MediaGallery.id not updating the corresponding payload
DA-344 791331c
fix Button & Select .id not updating the corresponding payload
DA-344 01014f1
update ActionRow.select example
DA-344 0e9d25a
move custom_id stuff of Section.accessory to Section.__init__
DA-344 d9c4fe2
custom ids
DA-344 ec31af9
add Item.copy
DA-344 678367e
Update discord/ui/action_row.py
DA-344 fdbc06e
Update discord/ui/action_row.py
DA-344 20bf99a
Update discord/ui/action_row.py
DA-344 ba38075
Update discord/ui/action_row.py
DA-344 1452312
Update discord/ui/action_row.py
DA-344 90fd44e
Update discord/ui/action_row.py
DA-344 18850d9
Update discord/ui/action_row.py
DA-344 923a006
Update discord/ui/action_row.py
DA-344 ff80605
Update discord/ui/container.py
DA-344 d499c73
Update discord/ui/section.py
DA-344 3b8d527
Update discord/ui/section.py
DA-344 72e79ff
it\'s -> its
DA-344 5564017
Merge branch 'master' to feat/components-v2
DA-344 895a750
remove accessory handling in schedule_dynamic_item_call
DA-344 5677b3a
dont use cls, use View or LayoutView
DA-344 81a8884
typing
DA-344 9424f91
run black
DA-344 93ceddd
use new types instead of replacing with Any
DA-344 fb49079
oops
DA-344 5a2ad02
hmm
DA-344 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.