import React, { useMemo } from 'react'; import HeaderCapsule from '@custom/shared/components/HeaderCapsule'; import { useParticipants } from '@custom/shared/contexts/ParticipantsProvider'; import { useUIState } from '@custom/shared/contexts/UIStateProvider'; export const Header = () => { const { participantCount } = useParticipants(); const { customCapsule } = useUIState(); return useMemo( () => (
Daily Basic call demo {`${participantCount} ${ participantCount === 1 ? 'participant' : 'participants' }`} {customCapsule && ( {customCapsule.variant === 'recording' && } {customCapsule.label} )}
), [participantCount, customCapsule] ); }; export default Header;