fix unable to change index in item page

This commit is contained in:
Prayag Prajapati committed 2023-12-03 15:47:09 +05:30
1 parent 50921dbc5f
commit 3add9d9f89
1 file changed
+5 -4
+5 -4
View File
@@ -106,7 +106,7 @@ const Hero = ({
setCurrentAudioIndex(audioTracks[0]?.Index); setCurrentAudioIndex(audioTracks[0]?.Index);
setCurrentSubtitleIndex(subtitleTracks[0]?.Index); setCurrentSubtitleIndex(subtitleTracks[0]?.Index);
} }
}, [videoTracks, audioTracks, subtitleTracks]); }, []);
const qualityLabel = () => { const qualityLabel = () => {
if ( if (
@@ -657,11 +657,12 @@ const Hero = ({
size="small" size="small"
value={currentSubtitleIndex} value={currentSubtitleIndex}
select select
onChange={(e) => onChange={(e) => {
console.log(e.target.value);
setCurrentSubtitleIndex( setCurrentSubtitleIndex(
e.target.value, e.target.value,
) );
} }}
SelectProps={{ SelectProps={{
MenuProps: { MenuProps: {
disableScrollLock: true, disableScrollLock: true,