<template>
  <ImageBlock2
    :src="image"
    :title="title"
    :desc="desc"
    :width="340"
    :imageWidth="340"
    :imageRadius="15"
    backgroundColor="transparent"
  >
    <template #footer> 
      <FlexRow justify="space-between" align="center" :padding="[10,0]" :margin="[10,0,0,0]">
        <FlexRow align="center" :gap="10">
          <Avatar :url="image" :size="40" />
          <Text :text="userName" :fontSize="24" color="gray" />
        </FlexRow>
        <FlexRow align="center" :gap="10">
          <Icon icon="favorite" :color="isLike ? 'primary' : 'gray'" :size="30" />
          <Text :text="likes" :fontSize="30" :color="isLike ? 'primary' : 'gray'" />
        </FlexRow>
      </FlexRow>
    </template>
  </ImageBlock2>
</template>

<script setup lang="ts">
import Text from '@/components/basic/Text.vue';
import FlexRow from '@/components/layout/FlexRow.vue';
import Avatar from '@/components/display/Avatar.vue';
import Icon from '@/components/basic/Icon.vue';
import ImageBlock2 from '@/components/display/block/ImageBlock2.vue';

const props = defineProps<{
  image?: string;
  title?: string;
  desc?: string;
  userName?: string;
  likes?: number;
  isLike?: boolean;
}>()

</script>