Weave.InputBox

Displays a UI text input field for user interaction.

Syntax

Weave.InputBox(title, defaultText, maxLength, callback, placeholder)

Parameters

titlestring

Input title

defaultTextstring

Default text

maxLengthnumber

Maximum length

callbackfunction

Function that receives the result

placeholderstring

Placeholder text

Example

-- Create an input box
Weave.InputBox(
    "Enter your name",
    "",
    50,
    function(result)
        if result then
            print("You entered: " .. result)
        else
            print("Input cancelled")
        end
    end,
    "Your name here..."
)