<template>
  <div>
    <div class="card" :class="{'is-active': active}">
      {{text}}
      <optio :text="item" v-for="(item, index) in list" :key="index"></optio>
    </div>
  </div>
</template>

<script>
import optio from '@/components/option-item'
export default {
  components: {
    optio
  },
  props: ['text', 'list'],
  data() {
    return {
      active: true
    }
  },
  methods: {
    handleTap (index) {
      console.log('card.vue', index)
    }
  }
}
</script>

<style>
.card {
  padding: 10px;
}
</style>
