Docs/components v2 :wires: (#3162)
* new pages :3 * fimished intro page * fimished interaction page * remove unused shit * I think we are done lmao * I lied, fixed some small mistakes * Update docs/guides/components_v2/interaction.md Co-authored-by: Mihail Gribkov <61027276+Misha-133@users.noreply.github.com> * misha quality assurance :3 + breakings pages * Apply suggestions from code review Co-authored-by: Mihail Gribkov <61027276+Misha-133@users.noreply.github.com> * component types guide expanded * :3 * Apply suggestions from code review Co-authored-by: Mihail Gribkov <61027276+Misha-133@users.noreply.github.com> --------- Co-authored-by: Mihail Gribkov <61027276+Misha-133@users.noreply.github.com>
This commit is contained in:
15
docs/guides/components_v2/samples/recipe-servings-modal.cs
Normal file
15
docs/guides/components_v2/samples/recipe-servings-modal.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
private static ModalBuilder CreateServingsModal(short servings)
|
||||
{
|
||||
TextInputBuilder? textInput = new TextInputBuilder()
|
||||
.WithCustomId(RecipeServingsInput)
|
||||
.WithLabel("Servings")
|
||||
.WithValue(servings.ToString())
|
||||
.WithMinLength(1)
|
||||
.WithMaxLength(3)
|
||||
.WithStyle(TextInputStyle.Short);
|
||||
|
||||
return new ModalBuilder()
|
||||
.WithCustomId(RecipeServingsButton)
|
||||
.WithTitle("Set Servings")
|
||||
.AddTextInput(textInput);
|
||||
}
|
||||
Reference in New Issue
Block a user