<template>
  <!-- Generator: Adobe Illustrator 24.2.1, SVG Export Plug-In . SVG Version: 6.00 Build 0)  -->
  <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1024 1024" :width="`${size}`" :height="`${size}`" :fill="color"
    :style="isLinear ? 'fill:url(#lgid)' : ''">
    <defs v-if="isLinear">
      <linearGradient id="lgid" :x1="gradientPosition[0]" :y1="gradientPosition[1]" :x2="gradientPosition[2]"
        :y2="gradientPosition[3]">
        <stop v-for="(it, i) in linearGradient" :key="i" :offset="it[0]" :style="`stop-color:${it[1]};`" />
      </linearGradient>
    </defs>
    <path class="st1"
      d="M939.6,379.6c-5.3-17-22.8-28.5-40.7-28.5c-45,0-81.6-36.6-81.6-81.6c0-12.6,2.8-24.8,8.4-36.1
		c7.9-16.2,4.3-35.6-8.8-47.9c-52.6-48.9-116.7-84.8-185.6-103.9c-18.7-5.1-38.4,3.5-47.2,20.8c-14,27.5-41.9,44.6-72.8,44.6
		s-58.7-17.1-72.8-44.6c-8.8-17.3-28.7-25.9-47.2-20.8c-68.9,19.1-133.1,55-185.6,103.9c-13.2,12.3-16.8,31.8-8.8,47.9
		c5.5,11.2,8.3,23.3,8.3,36c0,45-36.6,81.6-80.4,81.7c-18.6-1.4-36.2,10.4-41.8,28.5C69.2,423,62.3,468.3,62.3,514.3
		c0,30.3,3.1,60.7,9.1,90.4c4.2,20.5,23,34.3,44,32.4c2.6-0.3,5.3-0.4,8.1-0.4c45,0,81.6,36.6,81.6,81.6c0,19.3-6.8,37.9-19.2,52.6
		c-13.5,16-12.7,39.6,1.8,54.6c53.8,55.9,121.4,97.1,195.2,119c21.6,6.2,43.8-5.6,50.5-26.7c10.9-33.9,42.1-56.7,77.8-56.7
		s66.9,22.8,77.8,56.7c5.5,17.3,21.6,28.4,38.9,28.4c3.8,0,7.8-0.6,11.6-1.7c73.9-22,141.4-63.1,195.2-119
		c14.5-15.1,15.3-38.6,1.8-54.6c-12.4-14.7-19.2-33.4-19.2-52.6c0-45,36.6-81.6,81.6-81.6c2.7,0,5.4,0.1,8.1,0.4
		c21.2,1.9,39.8-11.9,44-32.4c6.1-29.5,9.1-59.9,9.1-90.4C960.2,468.3,953.3,423,939.6,379.6z M876.1,556.7
		c-79.2,11.1-140.4,79.4-140.4,161.7c0,25.3,5.9,50.2,17.1,72.7c-30.9,27-66,48.6-103.8,63.9c-29.4-46.2-80.7-75.3-137.7-75.3
		c-56.9,0-108.2,29.1-137.7,75.3c-37.8-15.3-73-36.9-103.9-63.9c11.1-22.4,17.1-47.3,17.1-72.7c0-82.3-61.2-150.5-140.4-161.7
		c-1.6-14.1-2.4-28.3-2.4-42.4c0-28.6,3.3-56.9,9.7-84.4c75.7-14.2,133.1-80.7,133.1-160.5c0-14.3-1.8-28.2-5.3-41.7
		c31.2-25,66.4-44.8,103.7-58.5c30.6,37.3,76.4,59.4,126.1,59.4s95.5-22.1,126.1-59.4c37.4,13.7,72.6,33.6,103.7,58.6
		c-3.5,13.5-5.3,27.4-5.3,41.6c0,79.7,57.4,146.3,133.1,160.5c6.5,27.5,9.7,55.8,9.7,84.4C878.6,528.5,877.8,542.7,876.1,556.7z" />
    <path class="st1"
      d="M511.3,330.7c-101.3,0-183.7,82.4-183.7,183.7S410,698,511.3,698S695,615.6,695,514.3S612.5,330.7,511.3,330.7
		z M511.3,616.3c-56.3,0-102-45.8-102-102c0-56.3,45.8-102,102-102s102,45.8,102,102C613.3,570.6,567.5,616.3,511.3,616.3z" />
  </svg>
</template>

<script>
import { defaultSize } from "../config"

export default {
  props: {
    size: { type: [String, Number], default: defaultSize },
    color: { type: String, default: '#000' },
    gradientPosition: { type: Array, default: () => ([]) },
    linearGradient: { type: Array, default: () => ([]) },
  },
  computed: {
    isLinear() {
      return (!!this.gradientPosition.length) && (!!this.linearGradient.length)
    }
  }
}
</script>
