Fields 15 fields you can set on a textInput control. Every control also takes the shared fields (id, position, span, sync, action).
Fields Field Type Default What it does placeholder placeholdertext — The faint hint inside an empty box
Shows this text in grey inside the field until something is typed.
label labeltext — The name shown above the box
Writes this text in the header above the field.
icon icontext — A small picture at the start of the box
Shows this SF Symbol at the left inside the field.
defaultValue defaultValuetext — What is already typed when it first appears
Pre-fills the field with this text when the layout first appears.
style stylechoice one of 3 defaultWhich kind of box it is
Switches between a plain field, a search field, or a tall multi-line field.
default default a plain single-line field with a rounded background search a field with a magnifying glass and a clear button multiline a tall field that grows for several lines of text sendButton sendButtonon / off false (off) A chat-style box with a Send button
On, adds a Send button and makes Return start a new line; off, Return submits.
minLines minLinesnumber 1–20 step 1 1How tall the box starts
Sets how many text lines tall the composer is when empty, from 1 to 20.
maxLines maxLinesnumber 1–50 step 1 6How tall the box can grow
Lets the composer grow up to this many lines (1 to 50) before it scrolls inside.
autocorrect autocorrecton / off false (off) Whether the keyboard fixes your typing
On, the keyboard corrects and capitalizes words; off, it uses a plain ASCII keyboard.
autocorrectToggle autocorrectToggleon / off false (off) A tiny button to switch typing help on the fly
Shows an Aa button that turns autocorrect on or off while the keyboard is open.
keyboard keyboardchoice one of 5 — Which keys appear when you tap the box
Chooses the on-screen keyboard layout, such as email or number keys.
ascii plain letters and symbols with no suggestions default the standard iPhone keyboard url keys for web addresses with a slash and dot email keys for email with an at sign numbers a number pad clearOnSubmit clearOnSubmiton / off false (off) Whether the box empties after sending
Empties the field right after you press return to submit.
tint tintcolor #667eeaThe accent color of the box
Colors the cursor, search icon and Send button with this color.
hideBackground hideBackgroundon / off false (off) Lets the box sit directly on the page
Removes the frosted card behind the field so it floats on the page.
hideLabel hideLabelon / off false (off) Takes the name off the top
Shows a pill naming the change with an Undo button for 3 seconds after you submit.
Theme fields Restyle one control by setting these in its theme object; a layout's theme sets them for every control.
Theme fields Field Type Default What it does cornerRadius theme.cornerRadiusnumber 0–30 pt step 1 12How big the name above the box is
Sets the header label text size from 8 to 24 points.
Emits and receives What this control sends when you use it, and what it can show or follow when data arrives.
Emits Emits Sends When Type What it sends When you press Return or Send valuesubmit string the text in the field
With clear on submit the field empties right after sending
Example: Sample A
Receives Receives Takes From Type What it does value followhub, mqtt, http, store, default string the text to put in the field
the field shows that text without sending it; your next Return or Send replaces it
Example: Sample A
Sample The placeholder value the editor shows before real data arrives.
Examples 5 examples, each one a control you can paste into a layout.
Shows a pre-filled value (defaultValue), an icon and a placeholder; pressing return broadcasts the typed text through {{value}}.
JSON 10 lines Copy {
"type": "textInput",
"id": "device-name",
"position": [1, 0],
"span": [1, 2],
"placeholder": "Device name",
"defaultValue": "my-device",
"icon": "tag",
"action": { "method": "meshsocket", "mode": "broadcast", "event": "broadcast_request", "payload": { "msg_type": "device_name", "name": "{{value}}" } }
}Open in CAR-TER ↗
Rendered by the app Light Dark A growing chat-style box: Send submits, Return adds a newline, and the Aa button flips autocorrect on the live keyboard.
JSON 13 lines Copy {
"type": "textInput",
"id": "pane-input",
"position": [7, 0],
"span": [1, 4],
"placeholder": "type a command…",
"icon": "chevron.right",
"sendButton": true,
"autocorrectToggle": true,
"autocorrect": false,
"maxLines": 6,
"action": { "method": "meshsocket", "mode": "broadcast", "event": "broadcast_request", "payload": { "msg_type": "command", "text": "{{value}}" } }
}Open in CAR-TER ↗
Rendered by the app Light Dark The search look adds a magnifying glass and a clear button, and the field empties itself after each submit (clearOnSubmit).
JSON 11 lines Copy {
"type": "textInput",
"id": "search-box",
"position": [2, 0],
"span": [1, 2],
"label": "Search",
"placeholder": "Search…",
"style": "search",
"clearOnSubmit": true,
"action": { "method": "meshsocket", "mode": "broadcast", "event": "broadcast_request", "payload": { "msg_type": "search", "q": "{{value}}" } }
}Open in CAR-TER ↗
Rendered by the app Light Dark The multiline look gives a tall field for several lines of prose, with autocorrect on and the header label hidden.
JSON 11 lines Copy {
"type": "textInput",
"id": "notes",
"position": [3, 0],
"span": [2, 2],
"placeholder": "Jot a note",
"style": "multiline",
"autocorrect": true,
"hideLabel": true,
"hideBackground": true
}Open in CAR-TER ↗
Rendered by the app Light Dark The email keyboard shows the @ key, and confirm pops an Undo pill for 3 seconds after submit; tint colors the accent.
JSON 12 lines Copy {
"type": "textInput",
"id": "email-entry",
"position": [4, 0],
"span": [1, 2],
"label": "Email",
"placeholder": "[email protected] ",
"keyboard": "email",
"tint": "#34c759",
"confirm": true,
"action": { "method": "meshsocket", "mode": "broadcast", "event": "broadcast_request", "payload": { "msg_type": "email", "address": "{{value}}" } }
}Open in CAR-TER ↗
Rendered by the app Light Dark keyboard can also be url (web address keys) or numbers (number pad); ascii and default pick plain or standard keys. Use the email example above as the pattern and change only keyboard.
minLines and maxLines only matter when sendButton is on; icon shows in the default and search looks.
Try it on your phone carterkit serves a small hub on your computer and pushes one example to CAR-TER on your iPhone or iPad. Pair once with the code it prints.
Install the Python kit.
Copy pip install carterkit Show “Device name field” on your phone.
Copy carterkit demo textInput --example 'Device name field' Swap in any example name from this page, or leave --example off for the first one.
carterkit quickstart · Get CAR-TER
Styles
"default"
Standard single-line text field with rounded background.
"search"
Search-style field with magnifying glass icon and clear button.
"multiline"
Expands vertically for multi-line text entry.
Composer & keyboard
Set sendButton: true to turn the field into a growing composer : it grows from minLines
up to maxLines then scrolls inside, Return inserts a newline , and a Send button
submits. Ideal for chat or command entry.
Keyboard behaviour, tuned for command entry:
autocorrect defaults to false — autocorrect/autocapitalization off with an ASCII
keyboard, so typed commands aren't "corrected." Set true for prose. keyboard overrides
the keyboard type explicitly.
autocorrectToggle shows an inline Aa button that flips autocorrect at runtime and
reconfigures the live keyboard immediately (no refocus needed). It also appears on the
above-keyboard bar.
An above-keyboard Hide button lets you dismiss the keyboard to reach the
controls/tabs underneath it.
Behavior
Default field: the action fires when the user presses return/submit
Composer (sendButton: true): Send submits and Return inserts a newline
The {{value}} placeholder is replaced with the current text content
Generated from ControlDocs/text-input.md. Something unclear or missing? Tell me .