<template>
  <div class="section-card">
    <div v-if="title || $slots.title || $slots.extra" class="section-card__header">
      <span class="section-card__bar" />
      <span class="section-card__title">
        <slot name="title">{{ title }}</slot>
      </span>
      <span class="section-card__extra">
        <slot name="extra" />
      </span>
    </div>
    <div class="section-card__body">
      <slot />
    </div>
  </div>
</template>

<script>
export default {
  name: 'SectionCard',
  props: {
    title: {
      type: String,
      default: ''
    }
  }
}
</script>
