fix: player/audio route not able to interact with audioPlayer

This commit is contained in:
Prayag Prajapati committed 2024-11-17 11:50:16 +05:30
1 parent 60895ceecf
commit b0e08ce4bd
10 files changed
+338 -120

No files matched your search

+21 -11
View File
@@ -11,6 +11,25 @@ import Typography from "@mui/material/Typography";
import "./cardScroller.scss";
//@ts-ignore - I don't know the prop type for react-multi-carousel's customRightArrow and customLeftArrow
function RightButton(props) {
const { carouselState, children, rtl, ...restProps } = props;
return (
<IconButton className="card-scroller-button right" {...restProps}>
<div className="material-symbols-rounded">chevron_right</div>
</IconButton>
);
}
//@ts-ignore - I don't know the prop type for react-multi-carousel's customRightArrow and customLeftArrow
function LeftButton(props) {
const { carouselState, children, rtl, ...restProps } = props;
return (
<IconButton className="card-scroller-button left" {...restProps}>
<div className="material-symbols-rounded">chevron_left</div>
</IconButton>
);
}
export const CardScroller = ({
children,
displayCards,
@@ -77,20 +96,11 @@ export const CardScroller = ({
draggable
responsive={responsive}
arrows
rtl={false}
className="card-scroller"
customTransition="all .6s"
transitionDuration={600}
customRightArrow={
<IconButton className="card-scroller-button right">
<div className="material-symbols-rounded">chevron_right</div>
</IconButton>
}
customLeftArrow={
<IconButton className="card-scroller-button left">
<div className="material-symbols-rounded">chevron_left</div>
</IconButton>
}
customRightArrow={<RightButton />}
customLeftArrow={<LeftButton />}
>
{children}
</Carousel>