import { smallLoader } from '@/common/utils'
import styles from './style.module.css'
import Image from 'next/image'
import PromptTag from '../PromptTag'

interface card {
    fashionModelImage?: string
    tagNames?: string[]
    locationName?: string
}
interface Iprops {
    item: card
}
const ShowTemplate = ({ item }: Iprops) => {
    return (
        <div className={styles.wrap}>
            {item.fashionModelImage ? (
                <Image
                    src={item.fashionModelImage || ''}
                    width={20}
                    height={20}
                    alt="prompt-icon"
                    className={styles.icon}
                    loader={smallLoader}
                ></Image>
            ) : null}

            {item?.tagNames?.length ? (
                <PromptTag name={item?.tagNames?.join('、')}></PromptTag>
            ) : null}
            {item?.locationName ? <PromptTag name={item?.locationName}></PromptTag> : null}
        </div>
    )
}

export default ShowTemplate
