IntroBlock.vue 617 B

1234567891011121314151617181920212223242526272829303132
  1. <template>
  2. <div class="info-list mb-2">
  3. <div
  4. v-for="(it, k) in descItems"
  5. :key="k"
  6. :class="['entry',Boolean(it.value)?'':'hidden']"
  7. >
  8. <div class="label">{{ it.label }}</div>
  9. <div class="value">{{ it.value }}</div>
  10. </div>
  11. <slot />
  12. </div>
  13. </template>
  14. <script setup lang="ts">
  15. import type { PropType } from 'vue';
  16. const props = defineProps({
  17. title: {
  18. type: String,
  19. default: ''
  20. },
  21. address: {
  22. type: String,
  23. default: ''
  24. },
  25. descItems: {
  26. type: Array as PropType<Array<{ label: string, value: any }>>,
  27. default: () => []
  28. },
  29. })
  30. </script>