Skip to content

RtkControlbarButton

A reusable button for the control bar with icon, label, loading state, and warning indicator support.

Properties

PropertyTypeRequiredDefaultDescription
labelstring' 'Button label text
iconstring-SVG icon string
iconPackIconPackdefaultIconPackCustom icon pack
isLoadingbooleanfalseShow loading spinner instead of icon
disabledbooleanfalseWhether the button is disabled
onClick() => void-Press handler callback
showWarningbooleanfalseShow warning indicator
variant'button' | 'horizontal''button'Layout variant
size'lg' | 'md' | 'sm' | 'xl''sm'Icon size

Usage Examples

Basic Usage

import { RtkControlbarButton } from "@cloudflare/realtimekit-react-native-ui";
function MyComponent() {
return <RtkControlbarButton label="Mute" icon={muteIcon} />;
}

With Properties

import { RtkControlbarButton } from "@cloudflare/realtimekit-react-native-ui";
function MyComponent() {
return (
<RtkControlbarButton
label="Mute"
icon={muteIcon}
variant="horizontal"
size="md"
onClick={() => console.log("pressed")}
/>
);
}