@werxt/livekit-components-react 2.9.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +201 -0
- package/README.md +36 -0
- package/dist/assets/icons/CameraDisabledIcon.d.ts +11 -0
- package/dist/assets/icons/CameraDisabledIcon.d.ts.map +1 -0
- package/dist/assets/icons/CameraIcon.d.ts +11 -0
- package/dist/assets/icons/CameraIcon.d.ts.map +1 -0
- package/dist/assets/icons/ChatCloseIcon.d.ts +11 -0
- package/dist/assets/icons/ChatCloseIcon.d.ts.map +1 -0
- package/dist/assets/icons/ChatIcon.d.ts +11 -0
- package/dist/assets/icons/ChatIcon.d.ts.map +1 -0
- package/dist/assets/icons/Chevron.d.ts +11 -0
- package/dist/assets/icons/Chevron.d.ts.map +1 -0
- package/dist/assets/icons/FocusToggleIcon.d.ts +11 -0
- package/dist/assets/icons/FocusToggleIcon.d.ts.map +1 -0
- package/dist/assets/icons/GearIcon.d.ts +11 -0
- package/dist/assets/icons/GearIcon.d.ts.map +1 -0
- package/dist/assets/icons/LeaveIcon.d.ts +11 -0
- package/dist/assets/icons/LeaveIcon.d.ts.map +1 -0
- package/dist/assets/icons/LockLockedIcon.d.ts +11 -0
- package/dist/assets/icons/LockLockedIcon.d.ts.map +1 -0
- package/dist/assets/icons/MicDisabledIcon.d.ts +11 -0
- package/dist/assets/icons/MicDisabledIcon.d.ts.map +1 -0
- package/dist/assets/icons/MicIcon.d.ts +11 -0
- package/dist/assets/icons/MicIcon.d.ts.map +1 -0
- package/dist/assets/icons/QualityExcellentIcon.d.ts +11 -0
- package/dist/assets/icons/QualityExcellentIcon.d.ts.map +1 -0
- package/dist/assets/icons/QualityGoodIcon.d.ts +11 -0
- package/dist/assets/icons/QualityGoodIcon.d.ts.map +1 -0
- package/dist/assets/icons/QualityPoorIcon.d.ts +11 -0
- package/dist/assets/icons/QualityPoorIcon.d.ts.map +1 -0
- package/dist/assets/icons/QualityUnknownIcon.d.ts +11 -0
- package/dist/assets/icons/QualityUnknownIcon.d.ts.map +1 -0
- package/dist/assets/icons/ScreenShareIcon.d.ts +11 -0
- package/dist/assets/icons/ScreenShareIcon.d.ts.map +1 -0
- package/dist/assets/icons/ScreenShareStopIcon.d.ts +11 -0
- package/dist/assets/icons/ScreenShareStopIcon.d.ts.map +1 -0
- package/dist/assets/icons/SpinnerIcon.d.ts +11 -0
- package/dist/assets/icons/SpinnerIcon.d.ts.map +1 -0
- package/dist/assets/icons/UnfocusToggleIcon.d.ts +11 -0
- package/dist/assets/icons/UnfocusToggleIcon.d.ts.map +1 -0
- package/dist/assets/icons/index.d.ts +20 -0
- package/dist/assets/icons/index.d.ts.map +1 -0
- package/dist/assets/icons/util.d.ts +11 -0
- package/dist/assets/icons/util.d.ts.map +1 -0
- package/dist/assets/images/ParticipantPlaceholder.d.ts +11 -0
- package/dist/assets/images/ParticipantPlaceholder.d.ts.map +1 -0
- package/dist/assets/images/index.d.ts +2 -0
- package/dist/assets/images/index.d.ts.map +1 -0
- package/dist/components/ChatEntry.d.ts +35 -0
- package/dist/components/ChatEntry.d.ts.map +1 -0
- package/dist/components/ConnectionState.d.ts +23 -0
- package/dist/components/ConnectionState.d.ts.map +1 -0
- package/dist/components/ConnectionStateToast.d.ts +13 -0
- package/dist/components/ConnectionStateToast.d.ts.map +1 -0
- package/dist/components/LiveKitRoom.d.ts +92 -0
- package/dist/components/LiveKitRoom.d.ts.map +1 -0
- package/dist/components/ParticipantLoop.d.ts +28 -0
- package/dist/components/ParticipantLoop.d.ts.map +1 -0
- package/dist/components/RoomAudioRenderer.d.ts +29 -0
- package/dist/components/RoomAudioRenderer.d.ts.map +1 -0
- package/dist/components/RoomName.d.ts +20 -0
- package/dist/components/RoomName.d.ts.map +1 -0
- package/dist/components/SessionProvider.d.ts +13 -0
- package/dist/components/SessionProvider.d.ts.map +1 -0
- package/dist/components/Toast.d.ts +14 -0
- package/dist/components/Toast.d.ts.map +1 -0
- package/dist/components/TrackLoop.d.ts +26 -0
- package/dist/components/TrackLoop.d.ts.map +1 -0
- package/dist/components/controls/ChatToggle.d.ts +19 -0
- package/dist/components/controls/ChatToggle.d.ts.map +1 -0
- package/dist/components/controls/ClearPinButton.d.ts +20 -0
- package/dist/components/controls/ClearPinButton.d.ts.map +1 -0
- package/dist/components/controls/DisconnectButton.d.ts +19 -0
- package/dist/components/controls/DisconnectButton.d.ts.map +1 -0
- package/dist/components/controls/FocusToggle.d.ts +21 -0
- package/dist/components/controls/FocusToggle.d.ts.map +1 -0
- package/dist/components/controls/MediaDeviceSelect.d.ts +40 -0
- package/dist/components/controls/MediaDeviceSelect.d.ts.map +1 -0
- package/dist/components/controls/PaginationControl.d.ts +9 -0
- package/dist/components/controls/PaginationControl.d.ts.map +1 -0
- package/dist/components/controls/PaginationIndicator.d.ts +7 -0
- package/dist/components/controls/PaginationIndicator.d.ts.map +1 -0
- package/dist/components/controls/SettingsMenuToggle.d.ts +13 -0
- package/dist/components/controls/SettingsMenuToggle.d.ts.map +1 -0
- package/dist/components/controls/StartAudio.d.ts +24 -0
- package/dist/components/controls/StartAudio.d.ts.map +1 -0
- package/dist/components/controls/StartMediaButton.d.ts +22 -0
- package/dist/components/controls/StartMediaButton.d.ts.map +1 -0
- package/dist/components/controls/TrackToggle.d.ts +32 -0
- package/dist/components/controls/TrackToggle.d.ts.map +1 -0
- package/dist/components/index.d.ts +30 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/layout/CarouselLayout.d.ts +27 -0
- package/dist/components/layout/CarouselLayout.d.ts.map +1 -0
- package/dist/components/layout/FocusLayout.d.ts +25 -0
- package/dist/components/layout/FocusLayout.d.ts.map +1 -0
- package/dist/components/layout/GridLayout.d.ts +26 -0
- package/dist/components/layout/GridLayout.d.ts.map +1 -0
- package/dist/components/layout/LayoutContextProvider.d.ts +12 -0
- package/dist/components/layout/LayoutContextProvider.d.ts.map +1 -0
- package/dist/components/layout/index.d.ts +4 -0
- package/dist/components/layout/index.d.ts.map +1 -0
- package/dist/components/participant/AudioTrack.d.ts +33 -0
- package/dist/components/participant/AudioTrack.d.ts.map +1 -0
- package/dist/components/participant/AudioVisualizer.d.ts +22 -0
- package/dist/components/participant/AudioVisualizer.d.ts.map +1 -0
- package/dist/components/participant/BarVisualizer.d.ts +77 -0
- package/dist/components/participant/BarVisualizer.d.ts.map +1 -0
- package/dist/components/participant/ConnectionQualityIndicator.d.ts +16 -0
- package/dist/components/participant/ConnectionQualityIndicator.d.ts.map +1 -0
- package/dist/components/participant/ParticipantAudioTile.d.ts +14 -0
- package/dist/components/participant/ParticipantAudioTile.d.ts.map +1 -0
- package/dist/components/participant/ParticipantName.d.ts +17 -0
- package/dist/components/participant/ParticipantName.d.ts.map +1 -0
- package/dist/components/participant/ParticipantTile.d.ts +49 -0
- package/dist/components/participant/ParticipantTile.d.ts.map +1 -0
- package/dist/components/participant/TrackMutedIndicator.d.ts +19 -0
- package/dist/components/participant/TrackMutedIndicator.d.ts.map +1 -0
- package/dist/components/participant/VideoTrack.d.ts +23 -0
- package/dist/components/participant/VideoTrack.d.ts.map +1 -0
- package/dist/components/participant/animationSequences/connectingSequence.d.ts +2 -0
- package/dist/components/participant/animationSequences/connectingSequence.d.ts.map +1 -0
- package/dist/components/participant/animationSequences/listeningSequence.d.ts +2 -0
- package/dist/components/participant/animationSequences/listeningSequence.d.ts.map +1 -0
- package/dist/components/participant/animationSequences/thinkingSequence.d.ts +2 -0
- package/dist/components/participant/animationSequences/thinkingSequence.d.ts.map +1 -0
- package/dist/components/participant/animators/useBarAnimator.d.ts +3 -0
- package/dist/components/participant/animators/useBarAnimator.d.ts.map +1 -0
- package/dist/components-lNrIMTWQ.mjs +1051 -0
- package/dist/components-lNrIMTWQ.mjs.map +1 -0
- package/dist/context/chat-context.d.ts +23 -0
- package/dist/context/chat-context.d.ts.map +1 -0
- package/dist/context/feature-context.d.ts +14 -0
- package/dist/context/feature-context.d.ts.map +1 -0
- package/dist/context/index.d.ts +10 -0
- package/dist/context/index.d.ts.map +1 -0
- package/dist/context/layout-context.d.ts +32 -0
- package/dist/context/layout-context.d.ts.map +1 -0
- package/dist/context/participant-context.d.ts +22 -0
- package/dist/context/participant-context.d.ts.map +1 -0
- package/dist/context/pin-context.d.ts +17 -0
- package/dist/context/pin-context.d.ts.map +1 -0
- package/dist/context/room-context.d.ts +22 -0
- package/dist/context/room-context.d.ts.map +1 -0
- package/dist/context/session-context.d.ts +22 -0
- package/dist/context/session-context.d.ts.map +1 -0
- package/dist/context/track-reference-context.d.ts +25 -0
- package/dist/context/track-reference-context.d.ts.map +1 -0
- package/dist/contexts-D4V9wQRc.mjs +4026 -0
- package/dist/contexts-D4V9wQRc.mjs.map +1 -0
- package/dist/hooks/cloud/krisp/useKrispNoiseFilter.d.ts +42 -0
- package/dist/hooks/cloud/krisp/useKrispNoiseFilter.d.ts.map +1 -0
- package/dist/hooks/index.d.ts +54 -0
- package/dist/hooks/index.d.ts.map +1 -0
- package/dist/hooks/internal/index.d.ts +10 -0
- package/dist/hooks/internal/index.d.ts.map +1 -0
- package/dist/hooks/internal/useMediaQuery.d.ts +7 -0
- package/dist/hooks/internal/useMediaQuery.d.ts.map +1 -0
- package/dist/hooks/internal/useObservableState.d.ts +6 -0
- package/dist/hooks/internal/useObservableState.d.ts.map +1 -0
- package/dist/hooks/internal/useResizeObserver.d.ts +14 -0
- package/dist/hooks/internal/useResizeObserver.d.ts.map +1 -0
- package/dist/hooks/useAgent.d.ts +219 -0
- package/dist/hooks/useAgent.d.ts.map +1 -0
- package/dist/hooks/useAudioPlayback.d.ts +15 -0
- package/dist/hooks/useAudioPlayback.d.ts.map +1 -0
- package/dist/hooks/useChat.d.ts +43 -0
- package/dist/hooks/useChat.d.ts.map +1 -0
- package/dist/hooks/useChatToggle.d.ts +21 -0
- package/dist/hooks/useChatToggle.d.ts.map +1 -0
- package/dist/hooks/useClearPinButton.d.ts +15 -0
- package/dist/hooks/useClearPinButton.d.ts.map +1 -0
- package/dist/hooks/useConnectionQualityIndicator.d.ts +20 -0
- package/dist/hooks/useConnectionQualityIndicator.d.ts.map +1 -0
- package/dist/hooks/useConnectionStatus.d.ts +12 -0
- package/dist/hooks/useConnectionStatus.d.ts.map +1 -0
- package/dist/hooks/useDataChannel.d.ts +38 -0
- package/dist/hooks/useDataChannel.d.ts.map +1 -0
- package/dist/hooks/useDisconnectButton.d.ts +21 -0
- package/dist/hooks/useDisconnectButton.d.ts.map +1 -0
- package/dist/hooks/useEvents.d.ts +9 -0
- package/dist/hooks/useEvents.d.ts.map +1 -0
- package/dist/hooks/useFacingMode.d.ts +10 -0
- package/dist/hooks/useFacingMode.d.ts.map +1 -0
- package/dist/hooks/useFocusToggle.d.ts +26 -0
- package/dist/hooks/useFocusToggle.d.ts.map +1 -0
- package/dist/hooks/useGridLayout.d.ts +27 -0
- package/dist/hooks/useGridLayout.d.ts.map +1 -0
- package/dist/hooks/useIsEncrypted.d.ts +12 -0
- package/dist/hooks/useIsEncrypted.d.ts.map +1 -0
- package/dist/hooks/useIsMuted.d.ts +22 -0
- package/dist/hooks/useIsMuted.d.ts.map +1 -0
- package/dist/hooks/useIsRecording.d.ts +11 -0
- package/dist/hooks/useIsRecording.d.ts.map +1 -0
- package/dist/hooks/useIsSpeaking.d.ts +11 -0
- package/dist/hooks/useIsSpeaking.d.ts.map +1 -0
- package/dist/hooks/useLiveKitRoom.d.ts +19 -0
- package/dist/hooks/useLiveKitRoom.d.ts.map +1 -0
- package/dist/hooks/useLocalParticipant.d.ts +29 -0
- package/dist/hooks/useLocalParticipant.d.ts.map +1 -0
- package/dist/hooks/useLocalParticipantPermissions.d.ts +12 -0
- package/dist/hooks/useLocalParticipantPermissions.d.ts.map +1 -0
- package/dist/hooks/useMediaDeviceSelect.d.ts +41 -0
- package/dist/hooks/useMediaDeviceSelect.d.ts.map +1 -0
- package/dist/hooks/useMediaDevices.d.ts +15 -0
- package/dist/hooks/useMediaDevices.d.ts.map +1 -0
- package/dist/hooks/useMediaTrackBySourceOrName.d.ts +18 -0
- package/dist/hooks/useMediaTrackBySourceOrName.d.ts.map +1 -0
- package/dist/hooks/usePagination.d.ts +24 -0
- package/dist/hooks/usePagination.d.ts.map +1 -0
- package/dist/hooks/useParticipantAttributes.d.ts +30 -0
- package/dist/hooks/useParticipantAttributes.d.ts.map +1 -0
- package/dist/hooks/useParticipantInfo.d.ts +21 -0
- package/dist/hooks/useParticipantInfo.d.ts.map +1 -0
- package/dist/hooks/useParticipantPermissions.d.ts +17 -0
- package/dist/hooks/useParticipantPermissions.d.ts.map +1 -0
- package/dist/hooks/useParticipantTile.d.ts +22 -0
- package/dist/hooks/useParticipantTile.d.ts.map +1 -0
- package/dist/hooks/useParticipantTracks.d.ts +14 -0
- package/dist/hooks/useParticipantTracks.d.ts.map +1 -0
- package/dist/hooks/useParticipants.d.ts +30 -0
- package/dist/hooks/useParticipants.d.ts.map +1 -0
- package/dist/hooks/usePersistentUserChoices.d.ts +35 -0
- package/dist/hooks/usePersistentUserChoices.d.ts.map +1 -0
- package/dist/hooks/usePinnedTracks.d.ts +14 -0
- package/dist/hooks/usePinnedTracks.d.ts.map +1 -0
- package/dist/hooks/useRemoteParticipant.d.ts +35 -0
- package/dist/hooks/useRemoteParticipant.d.ts.map +1 -0
- package/dist/hooks/useRemoteParticipants.d.ts +30 -0
- package/dist/hooks/useRemoteParticipants.d.ts.map +1 -0
- package/dist/hooks/useRoomInfo.d.ts +21 -0
- package/dist/hooks/useRoomInfo.d.ts.map +1 -0
- package/dist/hooks/useSequentialRoomConnectDisconnect.d.ts +27 -0
- package/dist/hooks/useSequentialRoomConnectDisconnect.d.ts.map +1 -0
- package/dist/hooks/useSession.d.ts +130 -0
- package/dist/hooks/useSession.d.ts.map +1 -0
- package/dist/hooks/useSessionMessages.d.ts +29 -0
- package/dist/hooks/useSessionMessages.d.ts.map +1 -0
- package/dist/hooks/useSettingsToggle.d.ts +20 -0
- package/dist/hooks/useSettingsToggle.d.ts.map +1 -0
- package/dist/hooks/useSortedParticipants.d.ts +7 -0
- package/dist/hooks/useSortedParticipants.d.ts.map +1 -0
- package/dist/hooks/useSpeakingParticipants.d.ts +16 -0
- package/dist/hooks/useSpeakingParticipants.d.ts.map +1 -0
- package/dist/hooks/useStartAudio.d.ts +27 -0
- package/dist/hooks/useStartAudio.d.ts.map +1 -0
- package/dist/hooks/useStartVideo.d.ts +26 -0
- package/dist/hooks/useStartVideo.d.ts.map +1 -0
- package/dist/hooks/useSwipe.d.ts +24 -0
- package/dist/hooks/useSwipe.d.ts.map +1 -0
- package/dist/hooks/useTextStream.d.ts +20 -0
- package/dist/hooks/useTextStream.d.ts.map +1 -0
- package/dist/hooks/useToken.d.ts +20 -0
- package/dist/hooks/useToken.d.ts.map +1 -0
- package/dist/hooks/useTrack.d.ts +4 -0
- package/dist/hooks/useTrack.d.ts.map +1 -0
- package/dist/hooks/useTrackByName.d.ts +10 -0
- package/dist/hooks/useTrackByName.d.ts.map +1 -0
- package/dist/hooks/useTrackMutedIndicator.d.ts +18 -0
- package/dist/hooks/useTrackMutedIndicator.d.ts.map +1 -0
- package/dist/hooks/useTrackRefBySourceOrName.d.ts +7 -0
- package/dist/hooks/useTrackRefBySourceOrName.d.ts.map +1 -0
- package/dist/hooks/useTrackSyncTime.d.ts +10 -0
- package/dist/hooks/useTrackSyncTime.d.ts.map +1 -0
- package/dist/hooks/useTrackToggle.d.ts +27 -0
- package/dist/hooks/useTrackToggle.d.ts.map +1 -0
- package/dist/hooks/useTrackTranscription.d.ts +26 -0
- package/dist/hooks/useTrackTranscription.d.ts.map +1 -0
- package/dist/hooks/useTrackVolume.d.ts +49 -0
- package/dist/hooks/useTrackVolume.d.ts.map +1 -0
- package/dist/hooks/useTracks.d.ts +29 -0
- package/dist/hooks/useTracks.d.ts.map +1 -0
- package/dist/hooks/useTranscriptions.d.ts +21 -0
- package/dist/hooks/useTranscriptions.d.ts.map +1 -0
- package/dist/hooks/useVisualStableUpdate.d.ts +27 -0
- package/dist/hooks/useVisualStableUpdate.d.ts.map +1 -0
- package/dist/hooks/useVoiceAssistant.d.ts +43 -0
- package/dist/hooks/useVoiceAssistant.d.ts.map +1 -0
- package/dist/hooks/useWarnAboutMissingStyles.d.ts +5 -0
- package/dist/hooks/useWarnAboutMissingStyles.d.ts.map +1 -0
- package/dist/hooks-hQJmeINB.mjs +1992 -0
- package/dist/hooks-hQJmeINB.mjs.map +1 -0
- package/dist/hooks.d.ts +2 -0
- package/dist/hooks.js +2 -0
- package/dist/hooks.js.map +1 -0
- package/dist/hooks.mjs +64 -0
- package/dist/hooks.mjs.map +1 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.docs.d.ts +6 -0
- package/dist/index.docs.d.ts.map +1 -0
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +157 -0
- package/dist/index.mjs.map +1 -0
- package/dist/krisp.d.ts +2 -0
- package/dist/krisp.js +2 -0
- package/dist/krisp.js.map +1 -0
- package/dist/krisp.mjs +45 -0
- package/dist/krisp.mjs.map +1 -0
- package/dist/mergeProps.d.ts +25 -0
- package/dist/mergeProps.d.ts.map +1 -0
- package/dist/prefabs/AudioConference.d.ts +22 -0
- package/dist/prefabs/AudioConference.d.ts.map +1 -0
- package/dist/prefabs/Chat.d.ts +35 -0
- package/dist/prefabs/Chat.d.ts.map +1 -0
- package/dist/prefabs/ControlBar.d.ts +45 -0
- package/dist/prefabs/ControlBar.d.ts.map +1 -0
- package/dist/prefabs/MediaDeviceMenu.d.ts +36 -0
- package/dist/prefabs/MediaDeviceMenu.d.ts.map +1 -0
- package/dist/prefabs/PreJoin.d.ts +59 -0
- package/dist/prefabs/PreJoin.d.ts.map +1 -0
- package/dist/prefabs/VideoConference.d.ts +35 -0
- package/dist/prefabs/VideoConference.d.ts.map +1 -0
- package/dist/prefabs/VoiceAssistantControlBar.d.ts +32 -0
- package/dist/prefabs/VoiceAssistantControlBar.d.ts.map +1 -0
- package/dist/prefabs/index.d.ts +8 -0
- package/dist/prefabs/index.d.ts.map +1 -0
- package/dist/prefabs.d.ts +2 -0
- package/dist/prefabs.js +2 -0
- package/dist/prefabs.js.map +1 -0
- package/dist/prefabs.mjs +579 -0
- package/dist/prefabs.mjs.map +1 -0
- package/dist/room-BP3SCCCd.mjs +191 -0
- package/dist/room-BP3SCCCd.mjs.map +1 -0
- package/dist/shared-88J2fzv7.js +2 -0
- package/dist/shared-88J2fzv7.js.map +1 -0
- package/dist/shared-BDr0qLg4.js +4 -0
- package/dist/shared-BDr0qLg4.js.map +1 -0
- package/dist/shared-CjI_UuOX.js +2 -0
- package/dist/shared-CjI_UuOX.js.map +1 -0
- package/dist/shared-DTHOl3uJ.js +2 -0
- package/dist/shared-DTHOl3uJ.js.map +1 -0
- package/dist/utils.d.ts +19 -0
- package/dist/utils.d.ts.map +1 -0
- package/package.json +104 -0
- package/src/assets/icons/CameraDisabledIcon.tsx +15 -0
- package/src/assets/icons/CameraIcon.tsx +14 -0
- package/src/assets/icons/ChatCloseIcon.tsx +17 -0
- package/src/assets/icons/ChatIcon.tsx +25 -0
- package/src/assets/icons/Chevron.tsx +19 -0
- package/src/assets/icons/FocusToggleIcon.tsx +16 -0
- package/src/assets/icons/GearIcon.tsx +19 -0
- package/src/assets/icons/LeaveIcon.tsx +25 -0
- package/src/assets/icons/LockLockedIcon.tsx +19 -0
- package/src/assets/icons/MicDisabledIcon.tsx +15 -0
- package/src/assets/icons/MicIcon.tsx +19 -0
- package/src/assets/icons/QualityExcellentIcon.tsx +15 -0
- package/src/assets/icons/QualityGoodIcon.tsx +19 -0
- package/src/assets/icons/QualityPoorIcon.tsx +20 -0
- package/src/assets/icons/QualityUnknownIcon.tsx +17 -0
- package/src/assets/icons/ScreenShareIcon.tsx +25 -0
- package/src/assets/icons/ScreenShareStopIcon.tsx +21 -0
- package/src/assets/icons/SpinnerIcon.tsx +93 -0
- package/src/assets/icons/UnfocusToggleIcon.tsx +16 -0
- package/src/assets/icons/index.ts +19 -0
- package/src/assets/icons/util.tsx +47 -0
- package/src/assets/images/ParticipantPlaceholder.tsx +31 -0
- package/src/assets/images/index.ts +1 -0
- package/src/assets/template.js +21 -0
- package/src/components/ChatEntry.tsx +112 -0
- package/src/components/ConnectionState.tsx +36 -0
- package/src/components/ConnectionStateToast.tsx +47 -0
- package/src/components/LiveKitRoom.tsx +122 -0
- package/src/components/ParticipantLoop.tsx +41 -0
- package/src/components/RoomAudioRenderer.tsx +57 -0
- package/src/components/RoomName.tsx +36 -0
- package/src/components/SessionProvider.tsx +22 -0
- package/src/components/Toast.tsx +18 -0
- package/src/components/TrackLoop.tsx +45 -0
- package/src/components/controls/ChatToggle.tsx +32 -0
- package/src/components/controls/ClearPinButton.tsx +32 -0
- package/src/components/controls/DisconnectButton.tsx +32 -0
- package/src/components/controls/FocusToggle.tsx +54 -0
- package/src/components/controls/MediaDeviceSelect.tsx +144 -0
- package/src/components/controls/PaginationControl.tsx +51 -0
- package/src/components/controls/PaginationIndicator.tsx +26 -0
- package/src/components/controls/SettingsMenuToggle.tsx +26 -0
- package/src/components/controls/StartAudio.tsx +40 -0
- package/src/components/controls/StartMediaButton.tsx +41 -0
- package/src/components/controls/TrackToggle.tsx +54 -0
- package/src/components/index.ts +34 -0
- package/src/components/layout/CarouselLayout.tsx +80 -0
- package/src/components/layout/FocusLayout.tsx +37 -0
- package/src/components/layout/GridLayout.tsx +63 -0
- package/src/components/layout/LayoutContextProvider.tsx +36 -0
- package/src/components/layout/index.ts +3 -0
- package/src/components/participant/AudioTrack.tsx +89 -0
- package/src/components/participant/AudioVisualizer.tsx +67 -0
- package/src/components/participant/BarVisualizer.tsx +164 -0
- package/src/components/participant/ConnectionQualityIndicator.tsx +36 -0
- package/src/components/participant/ParticipantAudioTile.tsx +67 -0
- package/src/components/participant/ParticipantName.tsx +50 -0
- package/src/components/participant/ParticipantTile.tsx +192 -0
- package/src/components/participant/TrackMutedIndicator.tsx +53 -0
- package/src/components/participant/VideoTrack.tsx +92 -0
- package/src/components/participant/animationSequences/connectingSequence.ts +9 -0
- package/src/components/participant/animationSequences/listeningSequence.ts +6 -0
- package/src/components/participant/animationSequences/thinkingSequence.ts +12 -0
- package/src/components/participant/animators/useBarAnimator.ts +55 -0
- package/src/context/chat-context.ts +37 -0
- package/src/context/feature-context.ts +28 -0
- package/src/context/index.ts +27 -0
- package/src/context/layout-context.ts +72 -0
- package/src/context/participant-context.ts +44 -0
- package/src/context/pin-context.ts +27 -0
- package/src/context/room-context.ts +42 -0
- package/src/context/session-context.ts +43 -0
- package/src/context/track-reference-context.ts +47 -0
- package/src/hooks/cloud/krisp/useKrispNoiseFilter.ts +110 -0
- package/src/hooks/index.ts +72 -0
- package/src/hooks/internal/index.ts +10 -0
- package/src/hooks/internal/useMediaQuery.ts +46 -0
- package/src/hooks/internal/useObservableState.ts +24 -0
- package/src/hooks/internal/useResizeObserver.ts +124 -0
- package/src/hooks/useAgent.ts +945 -0
- package/src/hooks/useAudioPlayback.ts +34 -0
- package/src/hooks/useChat.ts +57 -0
- package/src/hooks/useChatToggle.ts +38 -0
- package/src/hooks/useClearPinButton.ts +29 -0
- package/src/hooks/useConnectionQualityIndicator.ts +33 -0
- package/src/hooks/useConnectionStatus.ts +22 -0
- package/src/hooks/useDataChannel.ts +73 -0
- package/src/hooks/useDisconnectButton.ts +36 -0
- package/src/hooks/useEvents.ts +39 -0
- package/src/hooks/useFacingMode.ts +22 -0
- package/src/hooks/useFocusToggle.ts +59 -0
- package/src/hooks/useGridLayout.ts +44 -0
- package/src/hooks/useIsEncrypted.ts +29 -0
- package/src/hooks/useIsMuted.ts +51 -0
- package/src/hooks/useIsRecording.ts +23 -0
- package/src/hooks/useIsSpeaking.ts +21 -0
- package/src/hooks/useLiveKitRoom.ts +186 -0
- package/src/hooks/useLocalParticipant.ts +73 -0
- package/src/hooks/useLocalParticipantPermissions.ts +24 -0
- package/src/hooks/useMediaDeviceSelect.ts +81 -0
- package/src/hooks/useMediaDevices.ts +28 -0
- package/src/hooks/useMediaTrackBySourceOrName.ts +97 -0
- package/src/hooks/usePagination.test.ts +77 -0
- package/src/hooks/usePagination.ts +67 -0
- package/src/hooks/useParticipantAttributes.ts +69 -0
- package/src/hooks/useParticipantInfo.ts +35 -0
- package/src/hooks/useParticipantPermissions.ts +29 -0
- package/src/hooks/useParticipantTile.ts +81 -0
- package/src/hooks/useParticipantTracks.ts +54 -0
- package/src/hooks/useParticipants.ts +42 -0
- package/src/hooks/usePersistentUserChoices.ts +64 -0
- package/src/hooks/usePinnedTracks.ts +24 -0
- package/src/hooks/useRemoteParticipant.ts +79 -0
- package/src/hooks/useRemoteParticipants.ts +45 -0
- package/src/hooks/useRoomInfo.ts +32 -0
- package/src/hooks/useSequentialRoomConnectDisconnect.ts +171 -0
- package/src/hooks/useSession.ts +642 -0
- package/src/hooks/useSessionMessages.ts +158 -0
- package/src/hooks/useSettingsToggle.ts +32 -0
- package/src/hooks/useSortedParticipants.ts +20 -0
- package/src/hooks/useSpeakingParticipants.ts +27 -0
- package/src/hooks/useStartAudio.ts +50 -0
- package/src/hooks/useStartVideo.ts +49 -0
- package/src/hooks/useSwipe.ts +68 -0
- package/src/hooks/useTextStream.ts +35 -0
- package/src/hooks/useToken.ts +54 -0
- package/src/hooks/useTrack.ts +11 -0
- package/src/hooks/useTrackByName.ts +15 -0
- package/src/hooks/useTrackMutedIndicator.ts +44 -0
- package/src/hooks/useTrackRefBySourceOrName.ts +30 -0
- package/src/hooks/useTrackSyncTime.ts +18 -0
- package/src/hooks/useTrackToggle.ts +93 -0
- package/src/hooks/useTrackTranscription.ts +75 -0
- package/src/hooks/useTrackVolume.ts +283 -0
- package/src/hooks/useTracks.test.ts +60 -0
- package/src/hooks/useTracks.ts +154 -0
- package/src/hooks/useTranscriptions.ts +48 -0
- package/src/hooks/useVisualStableUpdate.ts +63 -0
- package/src/hooks/useVoiceAssistant.ts +109 -0
- package/src/hooks/useWarnAboutMissingStyles.ts +11 -0
- package/src/index.docs.ts +12 -0
- package/src/index.ts +32 -0
- package/src/mergeProps.ts +87 -0
- package/src/prefabs/AudioConference.tsx +57 -0
- package/src/prefabs/Chat.tsx +153 -0
- package/src/prefabs/ControlBar.tsx +227 -0
- package/src/prefabs/MediaDeviceMenu.tsx +159 -0
- package/src/prefabs/PreJoin.tsx +439 -0
- package/src/prefabs/VideoConference.tsx +184 -0
- package/src/prefabs/VoiceAssistantControlBar.tsx +109 -0
- package/src/prefabs/index.ts +11 -0
- package/src/utils.ts +78 -0
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { TrackReferenceOrPlaceholder } from '@livekit/components-core';
|
|
2
|
+
/**
|
|
3
|
+
* Try to determine the `facingMode` of a local participant video track.
|
|
4
|
+
* @remarks
|
|
5
|
+
* Works only on local video tracks.
|
|
6
|
+
* @see {@link https://developer.mozilla.org/en-US/docs/Web/API/MediaTrackConstraints/facingMode | MDN docs on facingMode}
|
|
7
|
+
* @alpha
|
|
8
|
+
*/
|
|
9
|
+
export declare function useFacingMode(trackReference: TrackReferenceOrPlaceholder): 'user' | 'environment' | 'left' | 'right' | 'undefined';
|
|
10
|
+
//# sourceMappingURL=useFacingMode.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useFacingMode.d.ts","sourceRoot":"","sources":["../../src/hooks/useFacingMode.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,0BAA0B,CAAC;AAG5E;;;;;;GAMG;AACH,wBAAgB,aAAa,CAC3B,cAAc,EAAE,2BAA2B,GAC1C,MAAM,GAAG,aAAa,GAAG,MAAM,GAAG,OAAO,GAAG,WAAW,CASzD"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { TrackReferenceOrPlaceholder } from '@livekit/components-core';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
/** @public */
|
|
4
|
+
export interface UseFocusToggleProps {
|
|
5
|
+
trackRef?: TrackReferenceOrPlaceholder;
|
|
6
|
+
props: React.ButtonHTMLAttributes<HTMLButtonElement>;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* The `useFocusToggle` hook is used to implement the `FocusToggle` or your custom implementation of it.
|
|
10
|
+
* The `TrackReferenceOrPlaceholder` is used to register a onClick handler and to identify the track to focus on.
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* ```tsx
|
|
14
|
+
* const { mergedProps, inFocus } = useFocusToggle({ trackRef, props: yourButtonProps });
|
|
15
|
+
* return <button {...mergedProps}>{inFocus ? 'Unfocus' : 'Focus'}</button>;
|
|
16
|
+
* ```
|
|
17
|
+
* @public
|
|
18
|
+
*/
|
|
19
|
+
export declare function useFocusToggle({ trackRef, props }: UseFocusToggleProps): {
|
|
20
|
+
mergedProps: React.ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
21
|
+
className: string;
|
|
22
|
+
onClick: (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => void;
|
|
23
|
+
};
|
|
24
|
+
inFocus: boolean;
|
|
25
|
+
};
|
|
26
|
+
//# sourceMappingURL=useFocusToggle.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useFocusToggle.d.ts","sourceRoot":"","sources":["../../src/hooks/useFocusToggle.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,0BAA0B,CAAC;AAI5E,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,cAAc;AACd,MAAM,WAAW,mBAAmB;IAClC,QAAQ,CAAC,EAAE,2BAA2B,CAAC;IACvC,KAAK,EAAE,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,CAAC;CACtD;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,cAAc,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,EAAE,mBAAmB;;;yBAc9C,KAAK,CAAC,UAAU,CAAC,iBAAiB,EAAE,UAAU,CAAC;;;EAqBvE"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { GridLayoutDefinition, GridLayoutInfo } from '@livekit/components-core';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
/**
|
|
4
|
+
* The `useGridLayout` hook tries to select the best layout to fit all tiles.
|
|
5
|
+
* If the available screen space is not enough, it will reduce the number of maximum visible
|
|
6
|
+
* tiles and select a layout that still works visually within the given limitations.
|
|
7
|
+
* As the order of tiles changes over time, the hook tries to keep visual updates to a minimum
|
|
8
|
+
* while trying to display important tiles such as speaking participants or screen shares.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```tsx
|
|
12
|
+
* const { layout } = useGridLayout(gridElement, trackCount);
|
|
13
|
+
* ```
|
|
14
|
+
* @public
|
|
15
|
+
*/
|
|
16
|
+
export declare function useGridLayout(
|
|
17
|
+
/** HTML element that contains the grid. */
|
|
18
|
+
gridElement: React.RefObject<HTMLDivElement>,
|
|
19
|
+
/** Count of tracks that should get layed out */
|
|
20
|
+
trackCount: number, options?: {
|
|
21
|
+
gridLayouts?: GridLayoutDefinition[];
|
|
22
|
+
}): {
|
|
23
|
+
layout: GridLayoutInfo;
|
|
24
|
+
containerWidth: number;
|
|
25
|
+
containerHeight: number;
|
|
26
|
+
};
|
|
27
|
+
//# sourceMappingURL=useGridLayout.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useGridLayout.d.ts","sourceRoot":"","sources":["../../src/hooks/useGridLayout.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,oBAAoB,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AACrF,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B;;;;;;;;;;;;GAYG;AACH,wBAAgB,aAAa;AAC3B,2CAA2C;AAC3C,WAAW,EAAE,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC;AAC5C,gDAAgD;AAChD,UAAU,EAAE,MAAM,EAClB,OAAO,GAAE;IACP,WAAW,CAAC,EAAE,oBAAoB,EAAE,CAAC;CACjC,GACL;IAAE,MAAM,EAAE,cAAc,CAAC;IAAC,cAAc,EAAE,MAAM,CAAC;IAAC,eAAe,EAAE,MAAM,CAAA;CAAE,CAiB7E"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Participant, Room } from 'livekit-client';
|
|
2
|
+
/**
|
|
3
|
+
* @alpha
|
|
4
|
+
*/
|
|
5
|
+
export interface UseIsEncryptedOptions {
|
|
6
|
+
room?: Room;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* @alpha
|
|
10
|
+
*/
|
|
11
|
+
export declare function useIsEncrypted(participant?: Participant, options?: UseIsEncryptedOptions): boolean;
|
|
12
|
+
//# sourceMappingURL=useIsEncrypted.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useIsEncrypted.d.ts","sourceRoot":"","sources":["../../src/hooks/useIsEncrypted.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;AAKxD;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC,IAAI,CAAC,EAAE,IAAI,CAAC;CACb;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,WAAW,CAAC,EAAE,WAAW,EAAE,OAAO,GAAE,qBAA0B,WAW5F"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { TrackReferenceOrPlaceholder } from '@livekit/components-core';
|
|
2
|
+
import { Participant } from 'livekit-client';
|
|
3
|
+
/** @public */
|
|
4
|
+
export interface UseIsMutedOptions {
|
|
5
|
+
participant?: Participant;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* The `useIsMuted` hook is used to implement the `TrackMutedIndicator` or your custom implementation of it.
|
|
9
|
+
* It returns a `boolean` that indicates if the track is muted or not.
|
|
10
|
+
*
|
|
11
|
+
* @example With a track reference
|
|
12
|
+
* ```tsx
|
|
13
|
+
* const isMuted = useIsMuted(track);
|
|
14
|
+
* ```
|
|
15
|
+
*
|
|
16
|
+
* @param trackRef - A `TrackReference` indicating the track to monitor.
|
|
17
|
+
* @returns boolean indicating if the track is muted
|
|
18
|
+
*
|
|
19
|
+
* @public
|
|
20
|
+
*/
|
|
21
|
+
export declare function useIsMuted(trackRef: TrackReferenceOrPlaceholder): boolean;
|
|
22
|
+
//# sourceMappingURL=useIsMuted.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useIsMuted.d.ts","sourceRoot":"","sources":["../../src/hooks/useIsMuted.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,2BAA2B,EAGjC,MAAM,0BAA0B,CAAC;AAClC,OAAO,KAAK,EAAE,WAAW,EAAS,MAAM,gBAAgB,CAAC;AAIzD,cAAc;AACd,MAAM,WAAW,iBAAiB;IAChC,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,UAAU,CAAC,QAAQ,EAAE,2BAA2B,GAAG,OAAO,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Room } from 'livekit-client';
|
|
2
|
+
/**
|
|
3
|
+
* The `useIsRecording` hook returns a `boolean` that indicates if the room is currently being recorded.
|
|
4
|
+
* @example
|
|
5
|
+
* ```tsx
|
|
6
|
+
* const isRecording = useIsRecording();
|
|
7
|
+
* ```
|
|
8
|
+
* @public
|
|
9
|
+
*/
|
|
10
|
+
export declare function useIsRecording(room?: Room): boolean;
|
|
11
|
+
//# sourceMappingURL=useIsRecording.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useIsRecording.d.ts","sourceRoot":"","sources":["../../src/hooks/useIsRecording.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;AAE3C;;;;;;;GAOG;AACH,wBAAgB,cAAc,CAAC,IAAI,CAAC,EAAE,IAAI,WAOzC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Participant } from 'livekit-client';
|
|
2
|
+
/**
|
|
3
|
+
* The `useIsSpeaking` hook returns a `boolean` that indicates if the participant is speaking or not.
|
|
4
|
+
* @example
|
|
5
|
+
* ```tsx
|
|
6
|
+
* const isSpeaking = useIsSpeaking(participant);
|
|
7
|
+
* ```
|
|
8
|
+
* @public
|
|
9
|
+
*/
|
|
10
|
+
export declare function useIsSpeaking(participant?: Participant): boolean;
|
|
11
|
+
//# sourceMappingURL=useIsSpeaking.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useIsSpeaking.d.ts","sourceRoot":"","sources":["../../src/hooks/useIsSpeaking.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAKlD;;;;;;;GAOG;AACH,wBAAgB,aAAa,CAAC,WAAW,CAAC,EAAE,WAAW,WAMtD"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Room } from 'livekit-client';
|
|
2
|
+
import { HTMLAttributes } from 'react';
|
|
3
|
+
import { LiveKitRoomProps } from '../components';
|
|
4
|
+
/**
|
|
5
|
+
* The `useLiveKitRoom` hook is used to implement the `LiveKitRoom` or your custom implementation of it.
|
|
6
|
+
* It returns a `Room` instance and HTML props that should be applied to the root element of the component.
|
|
7
|
+
*
|
|
8
|
+
* @example
|
|
9
|
+
* ```tsx
|
|
10
|
+
* const { room, htmlProps } = useLiveKitRoom();
|
|
11
|
+
* return <div {...htmlProps}>...</div>;
|
|
12
|
+
* ```
|
|
13
|
+
* @public
|
|
14
|
+
*/
|
|
15
|
+
export declare function useLiveKitRoom<T extends HTMLElement>(props: LiveKitRoomProps): {
|
|
16
|
+
room: Room | undefined;
|
|
17
|
+
htmlProps: HTMLAttributes<T>;
|
|
18
|
+
};
|
|
19
|
+
//# sourceMappingURL=useLiveKitRoom.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useLiveKitRoom.d.ts","sourceRoot":"","sources":["../../src/hooks/useLiveKitRoom.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,IAAI,EAAiC,MAAM,gBAAgB,CAAC;AAErE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAE5C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAUtD;;;;;;;;;;GAUG;AACH,wBAAgB,cAAc,CAAC,CAAC,SAAS,WAAW,EAClD,KAAK,EAAE,gBAAgB,GACtB;IACD,IAAI,EAAE,IAAI,GAAG,SAAS,CAAC;IACvB,SAAS,EAAE,cAAc,CAAC,CAAC,CAAC,CAAC;CAC9B,CAyJA"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { TrackPublication, LocalParticipant, Room } from 'livekit-client';
|
|
2
|
+
/** @public */
|
|
3
|
+
export interface UseLocalParticipantOptions {
|
|
4
|
+
/**
|
|
5
|
+
* The room to use. If not provided, the hook will use the room from the context.
|
|
6
|
+
*/
|
|
7
|
+
room?: Room;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* The `useLocalParticipant` hook returns the local participant and the associated state
|
|
11
|
+
* around the participant.
|
|
12
|
+
*
|
|
13
|
+
* @example
|
|
14
|
+
* ```tsx
|
|
15
|
+
* const { localParticipant } = useLocalParticipant();
|
|
16
|
+
* ```
|
|
17
|
+
* @public
|
|
18
|
+
*/
|
|
19
|
+
export declare function useLocalParticipant(options?: UseLocalParticipantOptions): {
|
|
20
|
+
isMicrophoneEnabled: boolean;
|
|
21
|
+
isScreenShareEnabled: boolean;
|
|
22
|
+
isCameraEnabled: boolean;
|
|
23
|
+
microphoneTrack: TrackPublication | undefined;
|
|
24
|
+
cameraTrack: TrackPublication | undefined;
|
|
25
|
+
lastMicrophoneError: Error | undefined;
|
|
26
|
+
lastCameraError: Error | undefined;
|
|
27
|
+
localParticipant: LocalParticipant;
|
|
28
|
+
};
|
|
29
|
+
//# sourceMappingURL=useLocalParticipant.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useLocalParticipant.d.ts","sourceRoot":"","sources":["../../src/hooks/useLocalParticipant.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;AAI/E,cAAc;AACd,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,IAAI,CAAC,EAAE,IAAI,CAAC;CACb;AAED;;;;;;;;;GASG;AACH,wBAAgB,mBAAmB,CAAC,OAAO,GAAE,0BAA+B;;;;;;;;;EAgD3E"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ParticipantPermission } from '@livekit/protocol';
|
|
2
|
+
/**
|
|
3
|
+
* The `useLocalParticipantPermissions` hook returns the local participant's permissions.
|
|
4
|
+
*
|
|
5
|
+
* @example
|
|
6
|
+
* ```tsx
|
|
7
|
+
* const { canPublish, canPublishData } = useLocalParticipantPermissions();
|
|
8
|
+
* ```
|
|
9
|
+
* @public
|
|
10
|
+
*/
|
|
11
|
+
export declare function useLocalParticipantPermissions(): ParticipantPermission | undefined;
|
|
12
|
+
//# sourceMappingURL=useLocalParticipantPermissions.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useLocalParticipantPermissions.d.ts","sourceRoot":"","sources":["../../src/hooks/useLocalParticipantPermissions.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,mBAAmB,CAAC;AAK/D;;;;;;;;GAQG;AACH,wBAAgB,8BAA8B,IAAI,qBAAqB,GAAG,SAAS,CAQlF"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { Room, LocalAudioTrack, LocalVideoTrack } from 'livekit-client';
|
|
2
|
+
/** @public */
|
|
3
|
+
export interface UseMediaDeviceSelectProps {
|
|
4
|
+
kind: MediaDeviceKind;
|
|
5
|
+
room?: Room;
|
|
6
|
+
track?: LocalAudioTrack | LocalVideoTrack;
|
|
7
|
+
/**
|
|
8
|
+
* this will call getUserMedia if the permissions are not yet given to enumerate the devices with device labels.
|
|
9
|
+
* in some browsers multiple calls to getUserMedia result in multiple permission prompts.
|
|
10
|
+
* It's generally advised only flip this to true, once a (preview) track has been acquired successfully with the
|
|
11
|
+
* appropriate permissions.
|
|
12
|
+
*
|
|
13
|
+
* @see {@link MediaDeviceMenu}
|
|
14
|
+
* @see {@link https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices/enumerateDevices | MDN enumerateDevices}
|
|
15
|
+
*/
|
|
16
|
+
requestPermissions?: boolean;
|
|
17
|
+
/**
|
|
18
|
+
* this callback gets called if an error is thrown when failing to select a device and also if a user
|
|
19
|
+
* denied permissions, eventhough the `requestPermissions` option is set to `true`.
|
|
20
|
+
* Most commonly this will emit a MediaDeviceError
|
|
21
|
+
*/
|
|
22
|
+
onError?: (e: Error) => void;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* The `useMediaDeviceSelect` hook is used to implement the `MediaDeviceSelect` component and
|
|
26
|
+
* returns o.a. the list of devices of a given kind (audioinput or videoinput), the currently active device
|
|
27
|
+
* and a function to set the the active device.
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* ```tsx
|
|
31
|
+
* const { devices, activeDeviceId, setActiveMediaDevice } = useMediaDeviceSelect({kind: 'audioinput'});
|
|
32
|
+
* ```
|
|
33
|
+
* @public
|
|
34
|
+
*/
|
|
35
|
+
export declare function useMediaDeviceSelect({ kind, room, track, requestPermissions, onError, }: UseMediaDeviceSelectProps): {
|
|
36
|
+
devices: MediaDeviceInfo[];
|
|
37
|
+
className: string;
|
|
38
|
+
activeDeviceId: string;
|
|
39
|
+
setActiveMediaDevice: (id: string, options?: import('@livekit/components-core').SetMediaDeviceOptions) => Promise<void>;
|
|
40
|
+
};
|
|
41
|
+
//# sourceMappingURL=useMediaDeviceSelect.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useMediaDeviceSelect.d.ts","sourceRoot":"","sources":["../../src/hooks/useMediaDeviceSelect.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,KAAK,eAAe,EAAE,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAKlF,cAAc;AACd,MAAM,WAAW,yBAAyB;IACxC,IAAI,EAAE,eAAe,CAAC;IACtB,IAAI,CAAC,EAAE,IAAI,CAAC;IACZ,KAAK,CAAC,EAAE,eAAe,GAAG,eAAe,CAAC;IAC1C;;;;;;;;OAQG;IACH,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B;;;;OAIG;IACH,OAAO,CAAC,EAAE,CAAC,CAAC,EAAE,KAAK,KAAK,IAAI,CAAC;CAC9B;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,oBAAoB,CAAC,EACnC,IAAI,EACJ,IAAI,EACJ,KAAK,EACL,kBAAkB,EAClB,OAAO,GACR,EAAE,yBAAyB;;;;;EAkC3B"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The `useMediaDevices` hook returns the list of media devices of a given kind.
|
|
3
|
+
*
|
|
4
|
+
* @example
|
|
5
|
+
* ```tsx
|
|
6
|
+
* const videoDevices = useMediaDevices({ kind: 'videoinput' });
|
|
7
|
+
* const audioDevices = useMediaDevices({ kind: 'audioinput' });
|
|
8
|
+
* ```
|
|
9
|
+
* @public
|
|
10
|
+
*/
|
|
11
|
+
export declare function useMediaDevices({ kind, onError, }: {
|
|
12
|
+
kind: MediaDeviceKind;
|
|
13
|
+
onError?: (e: Error) => void;
|
|
14
|
+
}): MediaDeviceInfo[];
|
|
15
|
+
//# sourceMappingURL=useMediaDevices.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useMediaDevices.d.ts","sourceRoot":"","sources":["../../src/hooks/useMediaDevices.ts"],"names":[],"mappings":"AAIA;;;;;;;;;GASG;AACH,wBAAgB,eAAe,CAAC,EAC9B,IAAI,EACJ,OAAO,GACR,EAAE;IACD,IAAI,EAAE,eAAe,CAAC;IACtB,OAAO,CAAC,EAAE,CAAC,CAAC,EAAE,KAAK,KAAK,IAAI,CAAC;CAC9B,qBAOA"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { TrackIdentifier } from '@livekit/components-core';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
/** @public */
|
|
4
|
+
export interface UseMediaTrackOptions {
|
|
5
|
+
element?: React.RefObject<HTMLMediaElement> | null;
|
|
6
|
+
props?: React.HTMLAttributes<HTMLVideoElement | HTMLAudioElement>;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* @internal
|
|
10
|
+
*/
|
|
11
|
+
export declare function useMediaTrackBySourceOrName(observerOptions: TrackIdentifier, options?: UseMediaTrackOptions): {
|
|
12
|
+
publication: import('livekit-client').TrackPublication | undefined;
|
|
13
|
+
isMuted: boolean | undefined;
|
|
14
|
+
isSubscribed: boolean | undefined;
|
|
15
|
+
track: import('livekit-client').Track<import("livekit-client").Track.Kind> | undefined;
|
|
16
|
+
elementProps: React.HTMLAttributes<HTMLElement>;
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=useMediaTrackBySourceOrName.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useMediaTrackBySourceOrName.d.ts","sourceRoot":"","sources":["../../src/hooks/useMediaTrackBySourceOrName.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAOhE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,cAAc;AACd,MAAM,WAAW,oBAAoB;IACnC,OAAO,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC,gBAAgB,CAAC,GAAG,IAAI,CAAC;IACnD,KAAK,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,gBAAgB,GAAG,gBAAgB,CAAC,CAAC;CACnE;AAED;;GAEG;AACH,wBAAgB,2BAA2B,CACzC,eAAe,EAAE,eAAe,EAChC,OAAO,GAAE,oBAAyB;;;;;;EA2EnC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { TrackReferenceOrPlaceholder } from '@livekit/components-core';
|
|
2
|
+
/**
|
|
3
|
+
* The `usePagination` hook implements simple pagination logic for use with arrays.
|
|
4
|
+
* @example
|
|
5
|
+
* ```tsx
|
|
6
|
+
* const tracks = useTracks();
|
|
7
|
+
* const pagination = usePagination(4, tracks);
|
|
8
|
+
*
|
|
9
|
+
* <TrackLoop tracks={pagination.tracks} />
|
|
10
|
+
* ```
|
|
11
|
+
* @alpha
|
|
12
|
+
*/
|
|
13
|
+
export declare function usePagination(itemPerPage: number, trackReferences: TrackReferenceOrPlaceholder[]): {
|
|
14
|
+
totalPageCount: number;
|
|
15
|
+
nextPage: () => void;
|
|
16
|
+
prevPage: () => void;
|
|
17
|
+
setPage: (num: number) => void;
|
|
18
|
+
firstItemIndex: number;
|
|
19
|
+
lastItemIndex: number;
|
|
20
|
+
tracks: TrackReferenceOrPlaceholder[];
|
|
21
|
+
currentPage: number;
|
|
22
|
+
};
|
|
23
|
+
export default usePagination;
|
|
24
|
+
//# sourceMappingURL=usePagination.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"usePagination.d.ts","sourceRoot":"","sources":["../../src/hooks/usePagination.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,0BAA0B,CAAC;AAI5E;;;;;;;;;;GAUG;AACH,wBAAgB,aAAa,CAAC,WAAW,EAAE,MAAM,EAAE,eAAe,EAAE,2BAA2B,EAAE;;;;mBAyBxE,MAAM;;;;;EAwB9B;AAED,eAAe,aAAa,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { Participant } from 'livekit-client';
|
|
2
|
+
/**
|
|
3
|
+
* The `useParticipantAttributes` hook returns the attributes of a given participant and allows to set them.
|
|
4
|
+
* It requires a `Participant` object passed as property or via the `ParticipantContext`.
|
|
5
|
+
*
|
|
6
|
+
* @example
|
|
7
|
+
* ```tsx
|
|
8
|
+
* const { attributes } = useParticipantAttributes({ participant });
|
|
9
|
+
* ```
|
|
10
|
+
* @public
|
|
11
|
+
*/
|
|
12
|
+
export interface UseParticipantAttributesOptions {
|
|
13
|
+
participant?: Participant;
|
|
14
|
+
}
|
|
15
|
+
/** @public */
|
|
16
|
+
export declare function useParticipantAttributes(props?: UseParticipantAttributesOptions): {
|
|
17
|
+
attributes: Readonly<Record<string, string>> | undefined;
|
|
18
|
+
};
|
|
19
|
+
/**
|
|
20
|
+
* The `useParticipantAttribute` hook returns the latest value of a given attribute key of a participant.
|
|
21
|
+
* It requires a `Participant` object passed as property in the `UseParticipantAttributesOptions` or via the `ParticipantContext`.
|
|
22
|
+
*
|
|
23
|
+
* @example
|
|
24
|
+
* ```tsx
|
|
25
|
+
* const myAttributeValue = useParticipantAttribute('targetAttributeName');
|
|
26
|
+
* ```
|
|
27
|
+
* @public
|
|
28
|
+
*/
|
|
29
|
+
export declare function useParticipantAttribute(attributeKey: string, options?: UseParticipantAttributesOptions): string;
|
|
30
|
+
//# sourceMappingURL=useParticipantAttributes.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useParticipantAttributes.d.ts","sourceRoot":"","sources":["../../src/hooks/useParticipantAttributes.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAKlD;;;;;;;;;GASG;AACH,MAAM,WAAW,+BAA+B;IAC9C,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AAED,cAAc;AACd,wBAAgB,wBAAwB,CAAC,KAAK,GAAE,+BAAoC;;EAanF;AAED;;;;;;;;;GASG;AACH,wBAAgB,uBAAuB,CACrC,YAAY,EAAE,MAAM,EACpB,OAAO,GAAE,+BAAoC,UAoB9C"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Participant } from 'livekit-client';
|
|
2
|
+
/**
|
|
3
|
+
* The `useParticipantInfo` hook returns the identity, name, and metadata of a given participant.
|
|
4
|
+
* It requires a `Participant` object passed as property or via the `ParticipantContext`.
|
|
5
|
+
*
|
|
6
|
+
* @example
|
|
7
|
+
* ```tsx
|
|
8
|
+
* const { identity, name, metadata } = useParticipantInfo({ participant });
|
|
9
|
+
* ```
|
|
10
|
+
* @public
|
|
11
|
+
*/
|
|
12
|
+
export interface UseParticipantInfoOptions {
|
|
13
|
+
participant?: Participant;
|
|
14
|
+
}
|
|
15
|
+
/** @public */
|
|
16
|
+
export declare function useParticipantInfo(props?: UseParticipantInfoOptions): {
|
|
17
|
+
identity: string | undefined;
|
|
18
|
+
name: string | undefined;
|
|
19
|
+
metadata: string | undefined;
|
|
20
|
+
};
|
|
21
|
+
//# sourceMappingURL=useParticipantInfo.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useParticipantInfo.d.ts","sourceRoot":"","sources":["../../src/hooks/useParticipantInfo.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAKlD;;;;;;;;;GASG;AACH,MAAM,WAAW,yBAAyB;IACxC,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AAED,cAAc;AACd,wBAAgB,kBAAkB,CAAC,KAAK,GAAE,yBAA8B;;;;EAavE"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ParticipantPermission } from '@livekit/protocol';
|
|
2
|
+
import { Participant } from 'livekit-client';
|
|
3
|
+
/**
|
|
4
|
+
* The `useParticipantPermissions` hook returns the permissions of a given participant.
|
|
5
|
+
*
|
|
6
|
+
* @example
|
|
7
|
+
* ```tsx
|
|
8
|
+
* const permissions = useParticipantPermissions({ participant });
|
|
9
|
+
* ```
|
|
10
|
+
* @public
|
|
11
|
+
*/
|
|
12
|
+
export interface UseParticipantPermissionsOptions {
|
|
13
|
+
participant?: Participant;
|
|
14
|
+
}
|
|
15
|
+
/** @public */
|
|
16
|
+
export declare function useParticipantPermissions(options?: UseParticipantPermissionsOptions): ParticipantPermission | undefined;
|
|
17
|
+
//# sourceMappingURL=useParticipantPermissions.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useParticipantPermissions.d.ts","sourceRoot":"","sources":["../../src/hooks/useParticipantPermissions.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,mBAAmB,CAAC;AAC/D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAKlD;;;;;;;;GAQG;AACH,MAAM,WAAW,gCAAgC;IAC/C,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AAED,cAAc;AACd,wBAAgB,yBAAyB,CACvC,OAAO,GAAE,gCAAqC,GAC7C,qBAAqB,GAAG,SAAS,CAKnC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { ParticipantClickEvent, TrackReferenceOrPlaceholder } from '@livekit/components-core';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
/** @public */
|
|
4
|
+
export interface UseParticipantTileProps<T extends HTMLElement> extends React.HTMLAttributes<T> {
|
|
5
|
+
/** The track reference to display. */
|
|
6
|
+
trackRef?: TrackReferenceOrPlaceholder;
|
|
7
|
+
disableSpeakingIndicator?: boolean;
|
|
8
|
+
onParticipantClick?: (event: ParticipantClickEvent) => void;
|
|
9
|
+
htmlProps: React.HTMLAttributes<T>;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* The `useParticipantTile` hook is used to implement the `ParticipantTile` and returns the props needed to render the tile.
|
|
13
|
+
* @remarks
|
|
14
|
+
* The returned props include many data attributes that are useful for CSS styling purposes because they
|
|
15
|
+
* indicate the state of the participant and the track.
|
|
16
|
+
* For example: `data-lk-audio-muted`, `data-lk-video-muted`, `data-lk-speaking`, `data-lk-local-participant`, `data-lk-source`, `data-lk-facing-mode`.
|
|
17
|
+
* @public
|
|
18
|
+
*/
|
|
19
|
+
export declare function useParticipantTile<T extends HTMLElement>({ trackRef, onParticipantClick, disableSpeakingIndicator, htmlProps, }: UseParticipantTileProps<T>): {
|
|
20
|
+
elementProps: React.HTMLAttributes<T>;
|
|
21
|
+
};
|
|
22
|
+
//# sourceMappingURL=useParticipantTile.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useParticipantTile.d.ts","sourceRoot":"","sources":["../../src/hooks/useParticipantTile.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,2BAA2B,EAAE,MAAM,0BAA0B,CAAC;AAEnG,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAQ/B,cAAc;AACd,MAAM,WAAW,uBAAuB,CAAC,CAAC,SAAS,WAAW,CAAE,SAAQ,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC;IAC7F,sCAAsC;IACtC,QAAQ,CAAC,EAAE,2BAA2B,CAAC;IACvC,wBAAwB,CAAC,EAAE,OAAO,CAAC;IACnC,kBAAkB,CAAC,EAAE,CAAC,KAAK,EAAE,qBAAqB,KAAK,IAAI,CAAC;IAC5D,SAAS,EAAE,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC;CACpC;AAED;;;;;;;GAOG;AACH,wBAAgB,kBAAkB,CAAC,CAAC,SAAS,WAAW,EAAE,EACxD,QAAQ,EACR,kBAAkB,EAClB,wBAAwB,EACxB,SAAS,GACV,EAAE,uBAAuB,CAAC,CAAC,CAAC;kBA8CpB,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC;EAE/B"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { TrackReference } from '@livekit/components-core';
|
|
2
|
+
import { Room, Track } from 'livekit-client';
|
|
3
|
+
type UseParticipantTracksOptions = {
|
|
4
|
+
participantIdentity?: string;
|
|
5
|
+
room?: Room;
|
|
6
|
+
};
|
|
7
|
+
/**
|
|
8
|
+
* `useParticipantTracks` is a custom React that allows you to get tracks of a specific participant only, by specifiying the participant's identity.
|
|
9
|
+
* If the participant identity is not passed the hook will try to get the participant from a participant context.
|
|
10
|
+
* @public
|
|
11
|
+
*/
|
|
12
|
+
export declare function useParticipantTracks<TrackSource extends Track.Source>(sources: Array<TrackSource>, optionsOrParticipantIdentity?: UseParticipantTracksOptions | UseParticipantTracksOptions['participantIdentity']): Array<TrackReference>;
|
|
13
|
+
export {};
|
|
14
|
+
//# sourceMappingURL=useParticipantTracks.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useParticipantTracks.d.ts","sourceRoot":"","sources":["../../src/hooks/useParticipantTracks.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAG/D,OAAO,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAIlD,KAAK,2BAA2B,GAAG;IACjC,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,IAAI,CAAC,EAAE,IAAI,CAAC;CACb,CAAC;AAEF;;;;GAIG;AACH,wBAAgB,oBAAoB,CAAC,WAAW,SAAS,KAAK,CAAC,MAAM,EACnE,OAAO,EAAE,KAAK,CAAC,WAAW,CAAC,EAC3B,4BAA4B,GACxB,2BAA2B,GAC3B,2BAA2B,CAAC,qBAAqB,CAAM,GAC1D,KAAK,CAAC,cAAc,CAAC,CA8BvB"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { Room, RoomEvent } from 'livekit-client';
|
|
2
|
+
/** @public */
|
|
3
|
+
export interface UseParticipantsOptions {
|
|
4
|
+
/**
|
|
5
|
+
* To optimize performance, you can use the `updateOnlyOn` property to decide on what RoomEvents the hook updates.
|
|
6
|
+
* By default it updates on all relevant RoomEvents to keep the returned participants array up to date.
|
|
7
|
+
* The minimal set of non-overwriteable `RoomEvents` is: `[RoomEvent.ParticipantConnected, RoomEvent.ParticipantDisconnected, RoomEvent.ConnectionStateChanged]`
|
|
8
|
+
*/
|
|
9
|
+
updateOnlyOn?: RoomEvent[];
|
|
10
|
+
/**
|
|
11
|
+
* The room to use. If not provided, the hook will use the room from the context.
|
|
12
|
+
*/
|
|
13
|
+
room?: Room;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* The `useParticipants` hook returns all participants (local and remote) of the current room.
|
|
17
|
+
* @remarks
|
|
18
|
+
* To optimize performance, you can use the `updateOnlyOn` property to decide on what `RoomEvents` the hook updates.
|
|
19
|
+
*
|
|
20
|
+
* @example
|
|
21
|
+
* ```tsx
|
|
22
|
+
* const participants = useParticipants();
|
|
23
|
+
* <ParticipantLoop participants={participants}>
|
|
24
|
+
* <ParticipantName />
|
|
25
|
+
* </ParticipantLoop>
|
|
26
|
+
* ```
|
|
27
|
+
* @public
|
|
28
|
+
*/
|
|
29
|
+
export declare function useParticipants(options?: UseParticipantsOptions): (import('livekit-client').RemoteParticipant | import('livekit-client').LocalParticipant)[];
|
|
30
|
+
//# sourceMappingURL=useParticipants.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useParticipants.d.ts","sourceRoot":"","sources":["../../src/hooks/useParticipants.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAKtD,cAAc;AACd,MAAM,WAAW,sBAAsB;IACrC;;;;OAIG;IACH,YAAY,CAAC,EAAE,SAAS,EAAE,CAAC;IAC3B;;OAEG;IACH,IAAI,CAAC,EAAE,IAAI,CAAC;CACb;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,eAAe,CAAC,OAAO,GAAE,sBAA2B,8FAQnE"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { LocalUserChoices } from '@livekit/components-core';
|
|
2
|
+
/**
|
|
3
|
+
* Options for the `usePersistentDeviceSettings` hook.
|
|
4
|
+
* @alpha
|
|
5
|
+
*/
|
|
6
|
+
export interface UsePersistentUserChoicesOptions {
|
|
7
|
+
/**
|
|
8
|
+
* The default value to use if reading from local storage returns no results or fails.
|
|
9
|
+
*/
|
|
10
|
+
defaults?: Partial<LocalUserChoices>;
|
|
11
|
+
/**
|
|
12
|
+
* Whether to prevent saving to persistent storage.
|
|
13
|
+
* @defaultValue false
|
|
14
|
+
*/
|
|
15
|
+
preventSave?: boolean;
|
|
16
|
+
/**
|
|
17
|
+
* Whether to prevent loading user choices from persistent storage and use `defaults` instead.
|
|
18
|
+
* @defaultValue false
|
|
19
|
+
*/
|
|
20
|
+
preventLoad?: boolean;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* A hook that provides access to user choices stored in local storage, such as
|
|
24
|
+
* selected media devices and their current state (on or off), as well as the user name.
|
|
25
|
+
* @alpha
|
|
26
|
+
*/
|
|
27
|
+
export declare function usePersistentUserChoices(options?: UsePersistentUserChoicesOptions): {
|
|
28
|
+
userChoices: LocalUserChoices;
|
|
29
|
+
saveAudioInputEnabled: (isEnabled: boolean) => void;
|
|
30
|
+
saveVideoInputEnabled: (isEnabled: boolean) => void;
|
|
31
|
+
saveAudioInputDeviceId: (deviceId: string) => void;
|
|
32
|
+
saveVideoInputDeviceId: (deviceId: string) => void;
|
|
33
|
+
saveUsername: (username: string) => void;
|
|
34
|
+
};
|
|
35
|
+
//# sourceMappingURL=usePersistentUserChoices.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"usePersistentUserChoices.d.ts","sourceRoot":"","sources":["../../src/hooks/usePersistentUserChoices.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAIjE;;;GAGG;AACH,MAAM,WAAW,+BAA+B;IAC9C;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC,gBAAgB,CAAC,CAAC;IACrC;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAED;;;;GAIG;AACH,wBAAgB,wBAAwB,CAAC,OAAO,GAAE,+BAAoC;;uCAKxB,OAAO;uCAGP,OAAO;uCAGP,MAAM;uCAGN,MAAM;6BAGhB,MAAM;EAgBzD"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { TrackReferenceOrPlaceholder } from '@livekit/components-core';
|
|
2
|
+
import { LayoutContextType } from '../context';
|
|
3
|
+
/**
|
|
4
|
+
* The `usePinnedTracks` hook returns a array of the pinned tracks of the current room.
|
|
5
|
+
* @remarks
|
|
6
|
+
* To function properly, this hook must be called within a `LayoutContext`.
|
|
7
|
+
* @example
|
|
8
|
+
* ```tsx
|
|
9
|
+
* const pinnedTracks = usePinnedTracks();
|
|
10
|
+
* ```
|
|
11
|
+
* @public
|
|
12
|
+
*/
|
|
13
|
+
export declare function usePinnedTracks(layoutContext?: LayoutContextType): TrackReferenceOrPlaceholder[];
|
|
14
|
+
//# sourceMappingURL=usePinnedTracks.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"usePinnedTracks.d.ts","sourceRoot":"","sources":["../../src/hooks/usePinnedTracks.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,0BAA0B,CAAC;AAE5E,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAGpD;;;;;;;;;GASG;AACH,wBAAgB,eAAe,CAAC,aAAa,CAAC,EAAE,iBAAiB,GAAG,2BAA2B,EAAE,CAQhG"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { ParticipantIdentifier } from '@livekit/components-core';
|
|
2
|
+
import { ParticipantEvent, RemoteParticipant } from 'livekit-client';
|
|
3
|
+
/** @public */
|
|
4
|
+
export interface UseRemoteParticipantOptions {
|
|
5
|
+
/**
|
|
6
|
+
* To optimize performance, you can use the `updateOnlyOn` property to decide on what `ParticipantEvents` the hook updates.
|
|
7
|
+
* By default it updates on all relevant ParticipantEvents to keep the returned participant up to date.
|
|
8
|
+
*/
|
|
9
|
+
updateOnlyOn?: ParticipantEvent[];
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* The `useRemoteParticipant` hook returns the first RemoteParticipant by either identity and/or based on the participant kind.
|
|
13
|
+
* @remarks
|
|
14
|
+
* To optimize performance, you can use the `updateOnlyOn` property to decide on what `ParticipantEvents` the hook updates.
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* ```tsx
|
|
18
|
+
* const participant = useRemoteParticipant({kind: ParticipantKind.Agent, identity: 'myAgent'});
|
|
19
|
+
* ```
|
|
20
|
+
* @public
|
|
21
|
+
*/
|
|
22
|
+
export declare function useRemoteParticipant(identifier: ParticipantIdentifier, options?: UseRemoteParticipantOptions): RemoteParticipant | undefined;
|
|
23
|
+
/**
|
|
24
|
+
* The `useRemoteParticipant` hook returns the first RemoteParticipant by either identity or based on the participant kind.
|
|
25
|
+
* @remarks
|
|
26
|
+
* To optimize performance, you can use the `updateOnlyOn` property to decide on what `ParticipantEvents` the hook updates.
|
|
27
|
+
*
|
|
28
|
+
* @example
|
|
29
|
+
* ```tsx
|
|
30
|
+
* const participant = useRemoteParticipant('Russ');
|
|
31
|
+
* ```
|
|
32
|
+
* @public
|
|
33
|
+
*/
|
|
34
|
+
export declare function useRemoteParticipant(identity: string, options?: UseRemoteParticipantOptions): RemoteParticipant | undefined;
|
|
35
|
+
//# sourceMappingURL=useRemoteParticipant.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useRemoteParticipant.d.ts","sourceRoot":"","sources":["../../src/hooks/useRemoteParticipant.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,qBAAqB,EAG3B,MAAM,0BAA0B,CAAC;AAClC,OAAO,KAAK,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAI1E,cAAc;AACd,MAAM,WAAW,2BAA2B;IAC1C;;;OAGG;IACH,YAAY,CAAC,EAAE,gBAAgB,EAAE,CAAC;CACnC;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,oBAAoB,CAClC,UAAU,EAAE,qBAAqB,EACjC,OAAO,CAAC,EAAE,2BAA2B,GACpC,iBAAiB,GAAG,SAAS,CAAC;AACjC;;;;;;;;;;GAUG;AACH,wBAAgB,oBAAoB,CAClC,QAAQ,EAAE,MAAM,EAChB,OAAO,CAAC,EAAE,2BAA2B,GACpC,iBAAiB,GAAG,SAAS,CAAC"}
|