The Microphone component for Retool Apps
A button to record audio.
Recordings are Base64-encoded in WebM format, and audio playback displays a progress bar and elapsed time.
Settings
Microphone includes the following configurable options when building apps in the IDE.
DisabledEvent handlersSuffix iconPrefix iconShow on desktopShow on mobileLabelMaintain space when hiddenMarginAlways show in edit modeStylesVariant |
Properties
All properties for Microphone with supported data types or values. You can write JavaScript almost anywhere in Retool to manipulate or read property values.
audioFile
Details of the recorded audio.
Properties
audioURL
The base64-encoded URL of the audio.
global
Whether the object is globally scoped for use in all app pages.
Whether the component is visible.
iconBefore
The prefix icon to display.
Values
id
The unique identifier.
isHiddenOnDesktop
Whether the component is visible in the desktop layout.
isHiddenOnMobile
Whether the component is visible in the mobile layout.
maintainSpaceWhenHidden
Whether the component takes up space on the canvas if hidden
is true
.
pluginType
The plugin type.
recording
Whether the audio is recording.
showInEditor
Whether to remain visible in the editor if hidden
is true
.
stopLabel
The label for the Stop button.
styleVariant
The button variant to use.
Values
Methods
JavaScript API methods for interacting with Microphone. You can write JavaScript almost anywhere in Retool and use methods to manipulate data and property values.
reset
Reset all child inputs to default values or clears them if no default values are set.
microphone.reset()
scrollIntoView
Scrolls the canvas or parent container so that the selected component appears in the visible area.
microphone.scrollIntoView(scrollIntoViewOptions)
Parameters
Events
Events are triggered by user interactions, such as clicking a button or entering a value. Use event handlers to trigger queries or other actions in response to events.
change
The value is changed.