/* eslint react/no-array-index-key: "off" */ import { Components } from 'botframework-webchat-component'; import PropTypes from 'prop-types'; import React, { FC } from 'react'; import type { DirectLineAnimationCard } from 'botframework-webchat-core'; import CommonCard from './CommonCard'; import useStyleSet from '../../hooks/useStyleSet'; const { ImageContent, VideoContent } = Components; type AnimationCardContentProps = { actionPerformedClassName?: string; content: DirectLineAnimationCard; disabled?: boolean; }; const AnimationCardContent: FC = ({ actionPerformedClassName, content, disabled }) => { const { media = [] } = content; const [{ animationCardAttachment: animationCardAttachmentStyleSet }] = useStyleSet(); return (
); }; AnimationCardContent.defaultProps = { actionPerformedClassName: '', disabled: undefined }; AnimationCardContent.propTypes = { actionPerformedClassName: PropTypes.string, // PropTypes cannot fully capture TypeScript types. // @ts-ignore content: PropTypes.shape({ media: PropTypes.arrayOf( PropTypes.shape({ profile: PropTypes.string, url: PropTypes.string.isRequired }) ).isRequired }).isRequired, disabled: PropTypes.bool }; export default AnimationCardContent;