Skip to content

Commit

Permalink
fix: types
Browse files Browse the repository at this point in the history
  • Loading branch information
KaustubhKumar05 committed Jan 3, 2024
1 parent e90f5a9 commit d62606d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, { useEffect, useRef, useState } from 'react';
import { HMSVirtualBackgroundTypes } from '@100mslive/hms-virtual-background';
import { VirtualBackground, VirtualBackgroundMedia } from '@100mslive/types-prebuilt/elements/virtual_background';
import { VirtualBackgroundMedia } from '@100mslive/types-prebuilt/elements/virtual_background';
import {
HMSRoomState,
selectIsLargeRoom,
Expand Down Expand Up @@ -28,7 +28,7 @@ import { defaultMedia, vbPlugin } from './constants';
const iconDims = { height: '40px', width: '40px' };
const MAX_RETRIES = 2;

export const VBPicker = ({ background_media: backgroundMedia = [] }: VirtualBackground = {}) => {
export const VBPicker = ({ backgroundMedia = [] }: { backgroundMedia: VirtualBackgroundMedia[] }) => {
const toggleVB = useSidepaneToggle(SIDE_PANE_OPTIONS.VB);
const hmsActions = useHMSActions();
const role = useHMSStore(selectLocalPeerRole);
Expand Down
2 changes: 1 addition & 1 deletion packages/roomkit-react/src/Prebuilt/layouts/SidePane.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ const SidePane = ({
ViewComponent = <SidePaneTabs hideControls={hideControls} active={sidepane} />;
}
if (sidepane === SIDE_PANE_OPTIONS.VB) {
ViewComponent = <VBPicker background_media={preview_elements?.virtual_background?.background_media || []} />;
ViewComponent = <VBPicker backgroundMedia={preview_elements?.virtual_background?.background_media || []} />;
}

useEffect(() => {
Expand Down

0 comments on commit d62606d

Please sign in to comment.