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
[:button#primary_btn.primary"Primary Button with a custom_id"]
[:button.primary {:id"primary_btn"} "Primary Button with a custom_id"]
[:button.secondary {:disabledtrue} "Secondary Button"]
[:button.secondary.disabled"Secondary Button"]
[:button.success"Happy Button"]
[:button.danger"Sad Button"]
[:button.link {:href"https://www.google.com"} "Go to Google"]
Text Input
{
"type": 4,
"custom_id": "required_id",
"style": 1,
"label": "What is your favorite color?",
"min_length": 0,
"max_length": 4000,
"required": false,
"value": "Prefilled text",
"placeholder": "Kinda prefilled text, but not really"
}
[:input#required_id.short {:min-length0:max-length4000:requiredfalse:value"Prefilled text":placeholder"Fill me in!"}
"What is your favorite color?"]
[:input#big_textbox.short"What is your favorite color?"]
[:input#big_textbox.short.optional"What is your favorite color?"]
[:input#big_textbox.paragraph"What is your favorite color?"]
[:input#big_textbox.paragraph.optional"What is your favorite color?"]
Select Menu for picking from defined text options
{
"type": 3,
"custom_id": "required_id",
"placeholder": "This is just temporary and optional",
"min_values": 0,
"max_values": 25,
"disabled": true,
"options": [
{
"label": "First Choice",
"value": "1",
"description": "I am an optional description",
"default": false
},
{
"label": "Second Choice",
"value": "2",
"description": "I am an optional description",
"default": true
}
]
}
[:select#required_id
{:placeholder"This is just temporary and optional":min-values0:max-values25:disabledtrue}
[:option {:description"I am an optional description":value"1"}
"First Choice"]
[:option {:description"I am an optional description":value"2":selectedtrue}
"Second Choice"]]
[:select {:id"some_id":options [{:value"big":label"Big"}
{:value"smol":label"Smol"}]}]
[:select {:id"some_id":type3}
[:option {:value"big"} "Big"]
[:option {:value"smol"} "Smol"]]
[:select {:id"some_id":type3}
[:option {:value"big"} "Big"]
[:option {:value"smol"} "Smol"]]
[:select#some_id.text
[:option {:value"big"} "Big"]
[:option {:value"smol"} "Smol"]]
[:select#some_id
[:option {:value"big":selectedtrue} "Big"]
[:option {:value"smol"} "Smol"]]
[:select#some_id.disabled
[:option.selected {:value"big"} "Big"]
[:option {:value"smol"} "Smol"]]