You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/docs/reference/templates/functions.md
+9-5Lines changed: 9 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -781,11 +781,12 @@ object](/docs/reference/templates/syntax-and-data#message). Is also valid for ep
781
781
782
782
## Component V2
783
783
784
-
Components V2 introduces a new way to create interactive and visually appealing message layouts in Discord applications, allowing for greater control over message formatting and user interaction.
784
+
Components V2 provides a new way to create interactive and visually appealing message layouts in Discord applications,
785
+
making it easier to control message formatting and user interaction while maintaining line length under 120 characters.
785
786
786
787
### componentBuilder
787
788
788
-
`componentBuilder`is a helper for building Discord's new Components V2 (sections, buttons, menus, galleries, etc.) in YAGPDB custom commands.
789
+
`componentBuilder`simplifies building Discord's ComponentsV2, including buttons, menus, etc, in YAGPDB custom commands.
@@ -813,8 +814,9 @@ All keys are optional, but the Discord API will reject completey empty messages,
813
814
-`separator`: Adds spacing between components with the following keys:
814
815
-`true`: large separator
815
816
-`false` or `nil`: small separator
816
-
-`container`: top-level layout component. containers offer the ability to visually encapsulate a collection of components and have an optional customizable accent color bar. with the following keys:
817
-
-`components`: [componentbuilder](#componentbuilder) or list of [componentbuilder](#componentbuilder).
817
+
-`container`: Top-level layout. Containers offer the ability to visually encapsulate a collection of components,
818
+
and have an optional customizable accent color bar. Contains the following keys:
819
+
-`components`: [componentBuilder](#componentbuilder) or list of [componentBuilder](#componentbuilder).
818
820
-`color`: hex accent color (optional).
819
821
-`spoiler`: hides content until revealed (optional).
820
822
-`buttons`: Interactive buttons users can click. Can be single or multiple. see [cbutton](#cbutton).
@@ -833,7 +835,9 @@ All keys are optional, but the Discord API will reject completey empty messages,
833
835
834
836
### Component Builder Functions
835
837
836
-
The `ComponentBuilder` object provides methods to construct, manipulate, and export Discord V2 message components programmatically. These methods allow you to build complex layouts incrementally and retrieve them in a format that Discord understands.
838
+
The `ComponentBuilder` simplifies building Discord's V2 components, allowing complex layouts to be built incrementally.
839
+
It provides methods for constructing, manipulating, and exporting components in a format Discord understands,
840
+
ensuring line length doesn't exceed 120 characters.
0 commit comments