<template>
  <div class="vm-card-head">
    <div v-if="$slots.media" class="vm-card-head__media">
      <slot name="media" />
    </div>
    <div v-if="$slots.tags" class="vm-card-head__tags">
      <slot name="tags" />
    </div>
    <div v-if="$slots.actions" class="vm-card-head__actions">
      <slot name="actions" />
    </div>
  </div>
</template>

<script setup lang="ts">
defineOptions({ name: 'vm-card-head' })
</script>

<style lang="scss" scoped>
.vm-card-head {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 8px;
}

.vm-card-head__media {
  flex-shrink: 0;
}

.vm-card-head__tags {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-wrap: wrap;
  gap: 4px;
  padding-top: 2px;
}

.vm-card-head__actions {
  display: flex;
  flex-shrink: 0;
  gap: 2px;
}
</style>
