import LookMsg from '@/pages/weComTask/components/previewMsg/lookMsg';
import { Popover } from 'antd';
import React from 'react';

interface Props {
    data: any[]
    name?: React.ReactNode
}
const WelcomeShowTable: React.FC<Props> = ({ name, data }) => {

    return <Popover
        placement="left"
        content={<LookMsg data={data} />}
        styles={{body: { width: 300, overflow: 'hidden', overflowY: 'auto', maxHeight: 480 }}}
    >
        <div
            style={{
                backgroundColor: 'rgba(0,0,0,0.1)',
                padding: '4px 8px',
                borderRadius: 8,
                overflow: 'hidden',
                cursor: 'help'
            }}
        >{name || '欢迎语内容'}</div>
    </Popover>
};

export default WelcomeShowTable;