import React, { useEffect } from 'react'; import { audioSrc } from '../audio/kds_audio'; import { CardContainerProps } from '../utils/types'; import KDSCard from '../CardContent'; import '../../globalStyles.css'; export const KDSComponent = (props: CardContainerProps): JSX.Element => { const audio = new Audio(audioSrc); useEffect(() => { audio.play(); }, []); const { order, venueConfig, callOrderApi, authProvider, kdsDeviceConfigs = {}, viewMode, } = props; const { buckets, payments, lastChanged, id, orderType, due, extra, deliveryAddress = {}, comments = [], users = [], verifiedTime, } = order; return ( buckets && buckets.map( (bucket: any, index: number) => bucket.lines.length > 0 && ( ) ) ); };