-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: update refs for DiscordLuau/discord-luau@6510ce2
- Loading branch information
1 parent
8689606
commit 14c9aa3
Showing
15 changed files
with
670 additions
and
1 deletion.
There are no files selected for viewing
Submodule discord-luau
updated
92 files
This file contains 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 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
--- | ||
title: OnboardingBuilder | ||
description: DiscordLuau docs for OnboardingBuilder. | ||
--- | ||
[//]: # (This file was automatically compiled through the Generator luau code under this repository) | ||
[//]: # (if you want to edit the documentation of discord-luau, please write changes) | ||
[//]: # (to the discord-luau repository itself, we extract the comments from discord-luau and translate) | ||
[//]: # (them into markdown files that Nextra can interpret!) | ||
|
||
[//]: # (----- DOCUMENT IMPORTS ----- ) | ||
|
||
import LuaDeclaration from '$/components/LuaDeclaration.astro'; | ||
import LuaProperty from '$/components/LuaProperty.astro'; | ||
|
||
[//]: # (----- DOCUMENT DESCRIPTION ----- ) | ||
|
||
OnboardingBuilder allows you to build onboarding for discord guilds. | ||
|
||
Usage: | ||
```lua | ||
local DiscordLuau = require("../Submodules/DiscordLuau") | ||
|
||
local OnboardingBuilder = DiscordLuau.OnboardingBuilder.new() | ||
:setMode(DiscordLuau.OnboardingBuilder.Mode.Default) | ||
:setEnabled(true) | ||
:addChannelId("1048686561685946489") | ||
``` | ||
|
||
[//]: # (----- DOCUMENT PROPERTIES ----- ) | ||
|
||
## Properties | ||
|
||
### Mode | ||
|
||
<LuaProperty name="OnboardingBuilder.Mode" type="table" /> | ||
--- | ||
An enumeration of onboarding modes | ||
|
||
- Default: 0 | ||
- Advanced: 1 | ||
|
||
[//]: # (----- DOCUMENT METHODS ----- ) | ||
|
||
## Methods | ||
|
||
### toPayloadObject | ||
|
||
> <LuaDeclaration name="toPayloadObject" className="OnboardingBuilder" args={[ ]} returnType="Network.Resolvable" isMethod /> | ||
Converts the message to a JSON object that can be sent to the Discord API. | ||
### setMode | ||
|
||
> <LuaDeclaration name="setMode" className="OnboardingBuilder" args={[ { name: "mode", type: "number" } ]} returnType="Builders.OnboardingBuilder" isMethod /> | ||
Sets the mode of the Guild onbaording object | ||
### setEnabled | ||
|
||
> <LuaDeclaration name="setEnabled" className="OnboardingBuilder" args={[ { name: "isEnabled", type: "boolean" } ]} returnType="Builders.OnboardingBuilder" isMethod /> | ||
Sets if the guild onboarding is enabled or not | ||
### addChannelId | ||
|
||
> <LuaDeclaration name="addChannelId" className="OnboardingBuilder" args={[ { name: "channelId", type: "string" } ]} returnType="Builders.OnboardingBuilder" isMethod /> | ||
Channel IDs that members get opted into automatically | ||
### addOnboardingPrompt | ||
|
||
> <LuaDeclaration name="addOnboardingPrompt" className="OnboardingBuilder" args={[ { name: "prompt", type: "Objects.OnboardingPromptBuilder" } ]} returnType="Builders.OnboardingBuilder" isMethod /> | ||
Channel IDs that members get opted into automatically | ||
### toPayloadObject | ||
|
||
> <LuaDeclaration name="toPayloadObject" className="OnboardingBuilder" args={[ ]} returnType="Network.Resolvable" isMethod /> | ||
Converts the message to a JSON object that can be sent to the Discord API. | ||
|
||
[//]: # (----- DOCUMENT FUNCTIONS ----- ) | ||
|
||
## Functions | ||
|
||
### new | ||
|
||
> <LuaDeclaration name="new" className="OnboardingBuilder" args={[ ]} /> | ||
Creates a new instance of OnboardingBuilder. | ||
|
86 changes: 86 additions & 0 deletions
86
src/content/docs/classes/Builders/OnboardingPromptBuilder.mdx
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
--- | ||
title: OnboardingPromptBuilder | ||
description: DiscordLuau docs for OnboardingPromptBuilder. | ||
--- | ||
[//]: # (This file was automatically compiled through the Generator luau code under this repository) | ||
[//]: # (if you want to edit the documentation of discord-luau, please write changes) | ||
[//]: # (to the discord-luau repository itself, we extract the comments from discord-luau and translate) | ||
[//]: # (them into markdown files that Nextra can interpret!) | ||
|
||
[//]: # (----- DOCUMENT IMPORTS ----- ) | ||
|
||
import LuaDeclaration from '$/components/LuaDeclaration.astro'; | ||
import LuaProperty from '$/components/LuaProperty.astro'; | ||
|
||
[//]: # (----- DOCUMENT DESCRIPTION ----- ) | ||
|
||
OnboardingPromptBuilder allows you to build onboarding for discord guilds. | ||
|
||
Usage: | ||
```lua | ||
local DiscordLuau = require("../Submodules/DiscordLuau") | ||
|
||
local OnboardingPromptBuilder = DiscordLuau.OnboardingPromptBuilder.new() | ||
:setType(DiscordLuau.OnboardingPromptBuilder.Type.Dropdown) | ||
:addOption( | ||
DiscordLuau.OnboardingPromptOptionBuilder.new() | ||
:setTitle("option-name") | ||
:setDescription("Option Description!") | ||
) | ||
``` | ||
|
||
[//]: # (----- DOCUMENT PROPERTIES ----- ) | ||
|
||
## Properties | ||
|
||
### Type | ||
|
||
<LuaProperty name="OnboardingPromptBuilder.Type" type="table" /> | ||
--- | ||
An enumeration of prompt types | ||
|
||
- MultipleChoice: 0 | ||
- Dropdown: 1 | ||
|
||
[//]: # (----- DOCUMENT METHODS ----- ) | ||
|
||
## Methods | ||
|
||
### setType | ||
|
||
> <LuaDeclaration name="setType" className="OnboardingPromptBuilder" args={[ { name: "type", type: "number" } ]} returnType="Builders.OnboardingPromptBuilder" isMethod /> | ||
Set the type of the Onboarding Prompt builder | ||
### addOption | ||
|
||
> <LuaDeclaration name="addOption" className="OnboardingPromptBuilder" args={[ { name: "option", type: "Builders.OnboardingPromptOptionBuilder" } ]} returnType="Builders.OnboardingPromptBuilder" isMethod /> | ||
Adds an option to the Onboarding prompt builder. | ||
### setTitle | ||
|
||
> <LuaDeclaration name="setTitle" className="OnboardingPromptBuilder" args={[ { name: "title", type: "string" } ]} returnType="Builders.OnboardingPromptBuilder" isMethod /> | ||
Sets the title of the onboarding prompt builder | ||
### setSingleSelection | ||
|
||
> <LuaDeclaration name="setSingleSelection" className="OnboardingPromptBuilder" args={[ { name: "isSingleSelection", type: "boolean" } ]} returnType="Builders.OnboardingPromptBuilder" isMethod /> | ||
Indicates whether users are limited to selecting one option for the prompt | ||
### setRequired | ||
|
||
> <LuaDeclaration name="setRequired" className="OnboardingPromptBuilder" args={[ { name: "isRequired", type: "boolean" } ]} returnType="Builders.OnboardingPromptBuilder" isMethod /> | ||
Indicates whether the prompt is required before a user completes the onboarding flow | ||
### setIsOnboarding | ||
|
||
> <LuaDeclaration name="setIsOnboarding" className="OnboardingPromptBuilder" args={[ { name: "isInOnboarding", type: "boolean" } ]} returnType="Builders.OnboardingPromptBuilder" isMethod /> | ||
Indicates whether the prompt is present in the onboarding flow. If false, the prompt will only appear in the Channels & Roles tab | ||
### toPayloadObject | ||
|
||
> <LuaDeclaration name="toPayloadObject" className="OnboardingPromptBuilder" args={[ ]} returnType="Network.Resolvable" isMethod /> | ||
Converts the message to a JSON object that can be sent to the Discord API. | ||
|
||
[//]: # (----- DOCUMENT FUNCTIONS ----- ) | ||
|
||
## Functions | ||
|
||
### new | ||
|
||
> <LuaDeclaration name="new" className="OnboardingPromptBuilder" args={[ ]} /> | ||
Creates a new instance of OnboardingPromptBuilder. | ||
|
67 changes: 67 additions & 0 deletions
67
src/content/docs/classes/Builders/OnboardingPromptOptionBuilder.mdx
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
--- | ||
title: OnboardingPromptOptionBuilder | ||
description: DiscordLuau docs for OnboardingPromptOptionBuilder. | ||
--- | ||
[//]: # (This file was automatically compiled through the Generator luau code under this repository) | ||
[//]: # (if you want to edit the documentation of discord-luau, please write changes) | ||
[//]: # (to the discord-luau repository itself, we extract the comments from discord-luau and translate) | ||
[//]: # (them into markdown files that Nextra can interpret!) | ||
|
||
[//]: # (----- DOCUMENT IMPORTS ----- ) | ||
|
||
import LuaDeclaration from '$/components/LuaDeclaration.astro'; | ||
import LuaProperty from '$/components/LuaProperty.astro'; | ||
|
||
[//]: # (----- DOCUMENT DESCRIPTION ----- ) | ||
|
||
OnboardingPromptOptionBuilder allows you to build onboarding for discord guilds. | ||
|
||
Usage: | ||
```lua | ||
local DiscordLuau = require("../Submodules/DiscordLuau") | ||
|
||
local OnboardingPromptOptionBuilder = DiscordLuau.OnboardingPromptOptionBuilder.new() | ||
:setTitle("option-name") | ||
:setDescription("Option Description!") | ||
``` | ||
|
||
[//]: # (----- DOCUMENT PROPERTIES ----- ) | ||
|
||
## Properties | ||
|
||
The OnboardingPromptOptionBuilder instance has no set properties! | ||
|
||
[//]: # (----- DOCUMENT METHODS ----- ) | ||
|
||
## Methods | ||
|
||
### setTitle | ||
|
||
> <LuaDeclaration name="setTitle" className="OnboardingPromptOptionBuilder" args={[ { name: "title", type: "string" } ]} returnType="Builders.OnboardingPromptOptionBuilder" isMethod /> | ||
Sets the title of the Prompt Option builder | ||
### setDescription | ||
|
||
> <LuaDeclaration name="setDescription" className="OnboardingPromptOptionBuilder" args={[ { name: "description", type: "string" } ]} returnType="Builders.OnboardingPromptOptionBuilder" isMethod /> | ||
Sets the description of the Prompt Option builder | ||
### addChannelId | ||
|
||
> <LuaDeclaration name="addChannelId" className="OnboardingPromptOptionBuilder" args={[ { name: "channelId", type: "string" } ]} returnType="Builders.OnboardingPromptOptionBuilder" isMethod /> | ||
Add a channel id to the prompt option builder | ||
### addRoleId | ||
|
||
> <LuaDeclaration name="addRoleId" className="OnboardingPromptOptionBuilder" args={[ { name: "roleId", type: "string" } ]} returnType="Builders.OnboardingPromptOptionBuilder" isMethod /> | ||
Add a role id to the prompt option builder | ||
### setEmoji | ||
|
||
> <LuaDeclaration name="setEmoji" className="OnboardingPromptOptionBuilder" args={[ { name: "emojiId", type: "string" }, { name: "emojiName", type: "string" }, { name: "emojiAnimated", type: "boolean?" } ]} returnType="Builders.OnboardingPromptOptionBuilder" isMethod /> | ||
Sets the emoji of the Onboarding Prompt Option Builder | ||
|
||
[//]: # (----- DOCUMENT FUNCTIONS ----- ) | ||
|
||
## Functions | ||
|
||
### new | ||
|
||
> <LuaDeclaration name="new" className="OnboardingPromptOptionBuilder" args={[ { name: "intentList", type: "{ string }" } ]} /> | ||
Creates a new instance of OnboardingPromptOptionBuilder with the specified intents. | ||
|
59 changes: 59 additions & 0 deletions
59
src/content/docs/classes/Builders/WelcomeScreenBuilder.mdx
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
--- | ||
title: WelcomeScreenBuilder | ||
description: DiscordLuau docs for WelcomeScreenBuilder. | ||
--- | ||
[//]: # (This file was automatically compiled through the Generator luau code under this repository) | ||
[//]: # (if you want to edit the documentation of discord-luau, please write changes) | ||
[//]: # (to the discord-luau repository itself, we extract the comments from discord-luau and translate) | ||
[//]: # (them into markdown files that Nextra can interpret!) | ||
|
||
[//]: # (----- DOCUMENT IMPORTS ----- ) | ||
|
||
import LuaDeclaration from '$/components/LuaDeclaration.astro'; | ||
import LuaProperty from '$/components/LuaProperty.astro'; | ||
|
||
[//]: # (----- DOCUMENT DESCRIPTION ----- ) | ||
|
||
WelcomeScreenBuilder allows you to build welcome screens for discord guilds. | ||
|
||
Usage: | ||
```lua | ||
local DiscordLuau = require("../Submodules/DiscordLuau") | ||
|
||
local WelcomeScreenBuilder = DiscordLuau.WelcomeScreenBuilder.new() | ||
:addChannel("1048686561685946489", "Super cool discord channel") | ||
:setDescription("Yeah, a super awesome dsicord channel!") | ||
``` | ||
|
||
[//]: # (----- DOCUMENT PROPERTIES ----- ) | ||
|
||
## Properties | ||
|
||
The WelcomeScreenBuilder instance has no set properties! | ||
|
||
[//]: # (----- DOCUMENT METHODS ----- ) | ||
|
||
## Methods | ||
|
||
### addChannel | ||
|
||
> <LuaDeclaration name="addChannel" className="WelcomeScreenBuilder" args={[ { name: "channelId", type: "string" }, { name: "description", type: "string" }, { name: "emojiId", type: "string" }, { name: "emojiName", type: "string" } ]} returnType="Builders.WelcomeScreenBuilder" isMethod /> | ||
Adds a channel object to the guilds Welcome Screen | ||
### setDescription | ||
|
||
> <LuaDeclaration name="setDescription" className="WelcomeScreenBuilder" args={[ { name: "description", type: "string" } ]} returnType="Builders.WelcomeScreenBuilder" isMethod /> | ||
Adds a channel object to the guilds Welcome Screen | ||
### toPayloadObject | ||
|
||
> <LuaDeclaration name="toPayloadObject" className="WelcomeScreenBuilder" args={[ ]} returnType="Network.Resolvable" isMethod /> | ||
Converts the message to a JSON object that can be sent to the Discord API. | ||
|
||
[//]: # (----- DOCUMENT FUNCTIONS ----- ) | ||
|
||
## Functions | ||
|
||
### new | ||
|
||
> <LuaDeclaration name="new" className="WelcomeScreenBuilder" args={[ ]} /> | ||
Creates a new instance of WelcomeScreenBuilder. | ||
|
This file contains 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.