<template>
  <div class="color-bar">
    <div class="color-item" v-for="(color, index) in colors" :key="index" :style="`width: ${(1/colors.length)*100}%;background-color: ${color};`"></div>
  </div>
</template>

<script>
export default {
  props: {
    colors: {
      type: Array,
      default: () => []
    }
  }
}
</script>