<template>
  <div class="legend__container">
    <div class="legend___item">
      <div
        class="legend--color"
        :style="{background:colors.start.background,border:`1px solid ${colors.start.border}`}"
      />
      <span>已办节点</span>
    </div>

    <div class="legend___item">
      <div
        class="legend--color"
        :style="{background:colors.process.background,border:`1px solid ${colors.process.border}`}"
      />
      <span>进行中节点</span>
    </div>

    <div class="legend___item">
      <div class="legend--color" :style="{background:'#fff',border:`1px solid #ccc`}" />
      <span>未开始</span>
    </div>
  </div>
</template>

<script>
import { colors } from './config'
export default {
  data() {
    return { colors }
  }
}
</script>

<style scoped>
.legend__container {
  width: 150px;
  position: absolute;
  left: 10px;
  top: 10px;
  padding: 10px;
  box-sizing: border-box;
  background: #fff;
}

.legend__container > .legend___item {
  display: flex;
  align-items: center;
}

.legend--color {
  width: 15px;
  height: 15px;
  margin-right: 20px;
  border-radius: 2px;
}
</style>
