import React, { FC, useState } from 'react'; import { Meta, Story } from '@storybook/react'; import { Wrapper } from '../../../../dist'; import { Button } from '../button/button.component'; import { Description } from '../description/description.component'; import MarkerArAnimationJson from '../lottie/resourse/world-ar.json'; import DefaultMarkerArCard from '../lottie/resourse/world-ar-images/img_5.png'; import { MediaComponentPropsType, MediaContent } from '../media/media.component'; import { Card, CardPropsType } from './card.component'; export default { component: Card, title: 'GEENEE-UI/WorldAr' } as Meta; type StoryArgsType = { [key: string]: any; } & CardPropsType & MediaComponentPropsType // eslint-disable-next-line react/function-component-definition const CardUseCase: FC = (props: StoryArgsType) => { const [ startToPlay, setStartToPlay ] = useState(false); return ( {} } loop autoplay={ false } play={ startToPlay } playFrom={ props.playFrom } url={ props.url } style={ { width: 288, height: 288 } } /> ) } onMouseEnter={ () => { setStartToPlay(true); } } onMouseLeave={ () => { setStartToPlay(false); } } > { props.title } { props.description } ); };