Input Menu Usage
Types
Input Types
- text
- number
- select
- radio
- checkbox
- slider
Choice
| Field | Type | Required |
|---|---|---|
| label | string | true |
| value | any | false |
Row Data
| Field | Type | Required |
|---|---|---|
| type | Input Types | false |
| label | string | false |
| placeholder | string | false |
| leftIcon | string | false |
| rightIcon | string | false |
| value | any | false |
| choices | Choice[] | false |
Input Menu Data
| Field | Type | Required |
|---|---|---|
| header | string | false |
| leftIcon | string | false |
| rightIcon | string | false |
| rows | Row Data | true |
Examples
Creating Input Menu
local inputMenuData = {
leftIcon = "envelope",
header = "Mail",
rows = {
{
label = "To",
placeholder = "5XX-XXXX",
type = "text"
},
{
label = "Content"
}
}
}
local inputMenu = exports["no-contextmenu"]:CreateInputMenu(inputMenuData)
-- menu closed
if not inputMenu then return end
local to, content = table.unpack(inputMenu)