String Inspector Type

String Inspector Type

Inspector Type

The string inspector type allows entering a single line of a text and represented with a simple input text field. The editor doesn't have any specific parameters. The optional default parameter for the editor should contain a string.

public function defineProperties()
{
    return [
        'firstName' => [
            'title' => 'First Name',
            'type' => 'string',
            'default' => 'John'
        ]
    ];
}

The generated output is a string value corresponding to the selected option, for example:

"firstName": "Sam"

The following configuration values are commonly used.

PropertyDescription
titletitle for the property.
descriptiona brief description of the property, optional.
defaultspecifies a default string value, optional.
showExternalParamspecifies visibility of the external parameter editor for the property in the Inspector. Default: true.
On This Page