fr-icon-honey.vue 2.7 KB

1234567891011121314151617181920212223242526272829303132333435
  1. <template>
  2. <fr-svg @click="onClick" :uuid="`fr-icon-honey-${size}${strokeWidth}${theme}${fill}${strokeLinecap}${strokeLinejoin}`" :width="size" :height="size" :isCache="true" :src="iconSvg" />
  3. </template>
  4. <script>
  5. // #ifdef UNI-APP-X
  6. import icons from "../../mixins/icons.uts";
  7. // #endif
  8. // #ifndef UNI-APP-X
  9. import icons from "../../mixins/icons.js";
  10. // #endif
  11. /**
  12. * @description 《蜂蜜》图标
  13. * @tutorial https://www.flowerui.com/documents/flower-icons/icons.html
  14. * @property {Number} size 图标大小
  15. * @property {Number} strokeWidth 线段粗细
  16. * @property {String} theme 图标大小
  17. * @property {Array} fill 图标颜色,["外部描边颜色","外部填充颜色","内部描边颜色","内部填充颜色"]
  18. * @property {String} strokeLinecap 图标大小
  19. * @property {String} strokeLinejoin 图标大小
  20. * @event {Function} click 图标点击事件
  21. */
  22. export default {
  23. mixins: [icons],
  24. computed: {
  25. // #ifdef UNI-APP-X
  26. iconSvg(): string {
  27. // #endif
  28. // #ifndef UNI-APP-X
  29. iconSvg() {
  30. // #endif
  31. return `<?xml version="1.0" encoding="UTF-8"?><svg width="${this.size}" height="${this.size}" viewBox="0 0 48 48" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M14.6126 4.84251L9.92332 9.53175C8.62842 10.8266 8.62842 12.9261 9.92332 14.221C11.2182 15.5159 13.3177 15.5159 14.6126 14.221L19.3018 9.53175C20.5967 8.23685 20.5967 6.13741 19.3018 4.84251C18.0069 3.54761 15.9074 3.54762 14.6126 4.84251Z" fill="${this.colors(1)}" stroke="${this.colors(0)}" stroke-width="${this.strokeWidth}"/><path d="M24.7734 13.4397L18.521 19.692C17.2261 20.9869 17.2261 23.0863 18.521 24.3812C19.8159 25.6761 21.9154 25.6761 23.2103 24.3812L29.4626 18.1289C30.7575 16.834 30.7575 14.7346 29.4626 13.4397C28.1677 12.1448 26.0683 12.1448 24.7734 13.4397Z" fill="${this.colors(1)}" stroke="${this.colors(0)}" stroke-width="${this.strokeWidth}"/><path d="M28.6804 18.9104L42.4504 32.6803C43.4781 33.708 43.2615 35.5909 41.9666 36.8857C40.6717 38.1806 38.7888 38.3973 37.7611 37.3696L23.9912 23.5996" stroke="${this.colors(0)}" stroke-width="${this.strokeWidth}"/><path d="M22.4284 6.40575L11.4868 17.3473C10.1919 18.6422 10.1919 20.7416 11.4868 22.0365C12.7817 23.3314 14.8812 23.3314 16.1761 22.0365L27.1176 11.0949C28.4125 9.80009 28.4125 7.70065 27.1176 6.40575C25.8227 5.11085 23.7233 5.11085 22.4284 6.40575Z" fill="${this.colors(1)}" stroke="${this.colors(0)}" stroke-width="${this.strokeWidth}"/><path d="M13.8542 23.1421C15.2778 27.5788 15.0407 30.8568 13.1431 32.976C10.2966 36.1547 10.7393 44.1421 17.1702 44.1421C23.6011 44.1421 25.4901 36.1547 20.0423 33.3527" stroke="${this.colors(0)}" stroke-width="${this.strokeWidth}" stroke-linecap="${this.strokeLinecap}"/></svg>`
  32. }
  33. }
  34. }
  35. </script>