MeetingProgressTimer - Elapsed meeting time display badge

MeetingProgressTimer is a React Native component that displays the elapsed time of a meeting in a colored badge positioned at one of four screen corners. The timer updates automatically as the meeting progresses and is commonly overlaid on video grids.

Key Features:

  • Real-time elapsed meeting time display
  • Four corner positioning options
  • Customizable badge background color
  • Customizable text styling
  • Show/hide toggle
  • Compact badge design
  • Absolute positioning for overlay

UI Customization: This component's styling can be customized via the provided props. For complete replacement, the parent grid component can be overridden via uiOverrides.

// Basic usage with default green badge
import React, { useState, useEffect } from 'react';
import { MeetingProgressTimer } from 'mediasfu-reactnative-expo';

const [elapsedTime, setElapsedTime] = useState('00:00');

useEffect(() => {
const interval = setInterval(() => {
// Update elapsed time logic
setElapsedTime(calculateElapsed());
}, 1000);
return () => clearInterval(interval);
}, []);

return (
<MeetingProgressTimer
meetingProgressTime={elapsedTime}
position="topLeft"
/>
);
// With custom styling and positioning
return (
<MeetingProgressTimer
meetingProgressTime="15:30"
initialBackgroundColor="#e74c3c"
position="bottomRight"
textStyle={{ color: 'white', fontSize: 16, fontWeight: 'bold' }}
showTimer={true}
/>
);
// Conditional display based on meeting state
const [showTimer, setShowTimer] = useState(false);

return (
<MeetingProgressTimer
meetingProgressTime={meetingTime}
position="topRight"
showTimer={meetingStarted && showTimer}
initialBackgroundColor="#27ae60"
/>
);

Properties

propTypes?: WeakValidationMap<MeetingProgressTimerOptions>

Used to declare the types of the props accepted by the component. These types will be checked during rendering and in development only.

We recommend using TypeScript instead of checking prop types at runtime.

contextTypes?: ValidationMap<any>

Lets you specify which legacy context is consumed by this component.

defaultProps?: Partial<MeetingProgressTimerOptions>

Used to define default values for the props accepted by the component.

type Props = { name?: string }

const MyComponent: FC<Props> = (props) => {
return <div>{props.name}</div>
}

MyComponent.defaultProps = {
name: 'John Doe'
}
displayName?: string

Used in debugging messages. You might want to set it explicitly if you want to display a different name for debugging purposes.


const MyComponent: FC = () => {
return <div>Hello!</div>
}

MyComponent.displayName = 'MyAwesomeComponent'