Explorar o código

fix: 修改图例需求,导入需求

bill hai 2 meses
pai
achega
60fa2a6905
Modificáronse 67 ficheiros con 517 adicións e 136 borrados
  1. 7 1
      public/icons/BalconyChair.svg
  2. 9 1
      public/icons/Bathtub.svg
  3. 10 1
      public/icons/BedsideCupboard.svg
  4. 15 1
      public/icons/Carpet.svg
  5. 4 1
      public/icons/Chair.svg
  6. 6 1
      public/icons/Closestool.svg
  7. 14 1
      public/icons/CombinationSofa.svg
  8. 9 1
      public/icons/Cupboard.svg
  9. 10 1
      public/icons/Desk.svg
  10. 11 1
      public/icons/DiningTable.svg
  11. 7 1
      public/icons/DoubleBed.svg
  12. 5 1
      public/icons/Dresser.svg
  13. 8 1
      public/icons/Elevator.svg
  14. 18 1
      public/icons/GasStove.svg
  15. 4 1
      public/icons/Pillow.svg
  16. 14 1
      public/icons/Plant.svg
  17. 6 1
      public/icons/SingleBed.svg
  18. 6 1
      public/icons/SingleSofa.svg
  19. 5 1
      public/icons/TV.svg
  20. 11 1
      public/icons/TeaTable.svg
  21. 8 1
      public/icons/ThreeSofa.svg
  22. 10 1
      public/icons/Wardrobe.svg
  23. 8 1
      public/icons/Washstand.svg
  24. 3 1
      public/icons/buqiang_o.svg
  25. 6 1
      public/icons/chelunhenji_o.svg
  26. 3 0
      public/icons/chuang.svg
  27. 4 1
      public/icons/danke_o.svg
  28. 5 1
      public/icons/dantou_o.svg
  29. 3 0
      public/icons/indicate1.svg
  30. 3 0
      public/icons/indicate2.svg
  31. 3 0
      public/icons/indicate3.svg
  32. 3 0
      public/icons/loudao.svg
  33. 15 0
      public/icons/luodichuang.svg
  34. 3 0
      public/icons/men.svg
  35. 4 0
      public/icons/piaochuang.svg
  36. 15 0
      public/icons/road_c.svg
  37. 3 0
      public/icons/road_t.svg
  38. 3 1
      public/icons/shitib_o.svg
  39. 8 1
      public/icons/shitifuhao_o.svg
  40. 3 7
      public/icons/shitiz_o.svg
  41. 3 1
      public/icons/shouqiang_o.svg
  42. 3 0
      public/icons/shuangkaimen.svg
  43. 4 1
      public/icons/xieyin_o.svg
  44. 7 7
      public/icons/xueji_o.svg
  45. 1 1
      public/icons/xuepo_o.svg
  46. 11 0
      public/icons/yakou.svg
  47. 4 0
      public/icons/yandao.svg
  48. 3 0
      public/icons/yimen.svg
  49. 8 1
      public/icons/youzuji_o.svg
  50. 7 1
      public/icons/zhiwen_o.svg
  51. 3 0
      public/icons/zhuzi.svg
  52. 8 1
      public/icons/zuozuji_o.svg
  53. 12 7
      public/static/kankan.html
  54. 10 4
      src/core/components/index.ts
  55. 4 0
      src/core/hook/use-draw.ts
  56. 1 1
      src/core/hook/use-event.ts
  57. 20 38
      src/core/hook/use-global-vars.ts
  58. 1 0
      src/core/hook/use-interactive.ts
  59. 1 0
      src/core/html-mount/propertys/index.ts
  60. 1 0
      src/example/components/slide/actions.ts
  61. 30 2
      src/example/fuse/views/tabulation/defStyle.ts
  62. 19 1
      src/example/fuse/views/overview/index.vue
  63. 9 3
      src/example/fuse/views/overview/slide-icons.vue
  64. 2 2
      src/example/fuse/views/tabulation/index.vue
  65. 47 26
      src/example/platform/platform-draw.ts
  66. 5 2
      src/example/platform/platform-resource.ts
  67. 1 1
      src/utils/event.ts

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 7 - 1
public/icons/BalconyChair.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 9 - 1
public/icons/Bathtub.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 10 - 1
public/icons/BedsideCupboard.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 15 - 1
public/icons/Carpet.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 4 - 1
public/icons/Chair.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 6 - 1
public/icons/Closestool.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 14 - 1
public/icons/CombinationSofa.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 9 - 1
public/icons/Cupboard.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 10 - 1
public/icons/Desk.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 11 - 1
public/icons/DiningTable.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 7 - 1
public/icons/DoubleBed.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 5 - 1
public/icons/Dresser.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 8 - 1
public/icons/Elevator.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 18 - 1
public/icons/GasStove.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 4 - 1
public/icons/Pillow.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 14 - 1
public/icons/Plant.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 6 - 1
public/icons/SingleBed.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 6 - 1
public/icons/SingleSofa.svg


+ 5 - 1
public/icons/TV.svg

@@ -1 +1,5 @@
-<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg class="icon" width="64px" height="64.00px" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path d="M713.888 512H800v96H224v-96h86.08l32-64H681.92l32 64z m-35.776 0l-16-32h-300.224l-16 32h332.224zM256 544v32h512v-32H256zM0 384h1024v288H0v-288z m32 32v224h960v-224H32z" /></svg>
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M0.5 11.5H31.5V20.5H0.5V11.5Z" stroke="black"/>
+<path d="M7.5 15.5H24.5V17.5H7.5V15.5Z" stroke="black"/>
+<path d="M22 15.5L21 13.5H11L10 15.5" stroke="black"/>
+</svg>

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 11 - 1
public/icons/TeaTable.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 8 - 1
public/icons/ThreeSofa.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 10 - 1
public/icons/Wardrobe.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 8 - 1
public/icons/Washstand.svg


+ 3 - 1
public/icons/buqiang_o.svg

@@ -1 +1,3 @@
-<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg class="icon" width="64px" height="64.00px" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path d="M754.592 368l253.408 84.48v215.52L748.8 560h-260.8V480H16v-112h738.592zM48 400V448h472v80h235.2l220.8 92V475.52l-226.592-75.52H48z" /></svg>
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M31 14.5L23.5 12H1V14.5H15.75V17H23.5L31 20.125V14.5Z" stroke="black"/>
+</svg>

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 6 - 1
public/icons/chelunhenji_o.svg


+ 3 - 0
public/icons/chuang.svg

@@ -0,0 +1,3 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M6 14H26V13H32V19H0V13H6V14ZM6 17V18H26V17H6ZM6 16H26V15H6V16Z" fill="black"/>
+</svg>

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 4 - 1
public/icons/danke_o.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 5 - 1
public/icons/dantou_o.svg


+ 3 - 0
public/icons/indicate1.svg

@@ -0,0 +1,3 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M22.4142 6.41401C21.1543 5.15408 19 6.04642 19 7.82823V10.9998H3C1.89543 10.9998 1 11.8952 1 12.9998V18.9998C1 20.1044 1.89543 20.9998 3 20.9998H19V24.1714C19 25.9532 21.1543 26.8455 22.4142 25.5856L30.5858 17.414C31.3668 16.633 31.3668 15.3666 30.5858 14.5856L22.4142 6.41401Z" stroke="black"/>
+</svg>

+ 3 - 0
public/icons/indicate2.svg

@@ -0,0 +1,3 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M1 7H24L31 16L24 25H1V7Z" stroke="black"/>
+</svg>

+ 3 - 0
public/icons/indicate3.svg

@@ -0,0 +1,3 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M4.36788 4.15817C3.09055 2.96067 1 3.86636 1 5.61724V26.3844C1 28.1352 3.09055 29.0409 4.36788 27.8434L15.4437 17.4599C15.7192 17.2016 15.9046 17.8848 16 17.5477V26.3844C16 28.1352 18.0906 29.0409 19.3679 27.8434L30.4437 17.4599C31.2865 16.6698 31.2865 15.3319 30.4437 14.5418L19.3679 4.15817C18.0906 2.96067 16 3.86636 16 5.61724V14.4539C15.9046 14.1169 15.7192 14.8 15.4437 14.5418L4.36788 4.15817Z" stroke="black" stroke-linejoin="round"/>
+</svg>

+ 3 - 0
public/icons/loudao.svg

@@ -0,0 +1,3 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M30 30H2V2H30V30ZM3 29H14V27H3V29ZM15 29H17V3H15V29ZM18 24V29H29V24H18ZM3 26H14V24H3V26ZM18 21V23H29V21H18ZM3 23H14V21H3V23ZM18 18V20H29V18H18ZM3 20H14V18H3V20ZM18 15V17H29V15H18ZM3 17H14V15H3V17ZM18 12V14H29V12H18ZM3 14H14V12H3V14ZM18 9V11H29V9H18ZM3 11H14V9H3V11ZM18 6V8H29V6H18ZM3 8H14V3H3V8ZM18 5H29V3H18V5Z" fill="black"/>
+</svg>

+ 15 - 0
public/icons/luodichuang.svg

@@ -0,0 +1,15 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M6 14H7V15H6V16H26V13H32V19H26V17H6V18H7V19H0V13H6V14Z" fill="black"/>
+<path d="M10 19H8V18H10V19Z" fill="black"/>
+<path d="M13 19H11V18H13V19Z" fill="black"/>
+<path d="M16 19H14V18H16V19Z" fill="black"/>
+<path d="M19 19H17V18H19V19Z" fill="black"/>
+<path d="M22 19H20V18H22V19Z" fill="black"/>
+<path d="M25 19H23V18H25V19Z" fill="black"/>
+<path d="M10 15H8V14H10V15Z" fill="black"/>
+<path d="M13 15H11V14H13V15Z" fill="black"/>
+<path d="M16 15H14V14H16V15Z" fill="black"/>
+<path d="M19 15H17V14H19V15Z" fill="black"/>
+<path d="M22 15H20V14H22V15Z" fill="black"/>
+<path d="M25 15H23V14H25V15Z" fill="black"/>
+</svg>

+ 3 - 0
public/icons/men.svg

@@ -0,0 +1,3 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M11.6934 9.10552C14.7979 6.69092 19.2421 5.66348 25.0107 6.00005H27V19H32V25H26V21H24V6.95513C18.9215 6.79206 15.0279 7.77807 12.3066 9.89458C9.40522 12.1513 7.3048 15.2111 6 19.085V25H0V19H5.00195C5.00196 18.9477 5.00791 18.8943 5.02539 18.8418C6.38912 14.7506 8.61318 11.5012 11.6934 9.10552ZM25 20H26V7.00005H25V20Z" fill="black"/>
+</svg>

+ 4 - 0
public/icons/piaochuang.svg

@@ -0,0 +1,4 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M28 18H31V24H1V18H4V8H28V18ZM7 23H25V11H7V23ZM5 18H6V10H26V18H27V9H5V18Z" fill="black"/>
+<path d="M28 18H31V24H1V18H4V8H28V18ZM7 23H25V11H7V23ZM5 18H6V10H26V18H27V9H5V18Z" stroke="black"/>
+</svg>

+ 15 - 0
public/icons/road_c.svg

@@ -0,0 +1,15 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<g clip-path="url(#clip0_171304_610716)">
+<mask id="mask0_171304_610716" style="mask-type:luminance" maskUnits="userSpaceOnUse" x="0" y="0" width="32" height="32">
+<path d="M32 0H0V32H32V0Z" fill="white"/>
+</mask>
+<g mask="url(#mask0_171304_610716)">
+<path d="M16.0003 1.33203L21.3337 6.66537L18.6673 6.66536V12.0285C18.6832 12.7511 19.2739 13.332 20.0003 13.332H25.3337V10.6654L30.667 15.9987L25.3337 21.332V18.6654H19.9981C19.2727 18.6666 18.6832 19.2471 18.6673 19.9689V25.332H21.3337L16.0003 30.6654L10.667 25.332H13.3337V19.9987C13.3337 19.2631 12.7379 18.6666 12.0026 18.6654H6.66731V21.332L1.33398 15.9987L6.66731 10.6654V13.332H12.0003C12.7367 13.332 13.3337 12.7351 13.3337 11.9987V6.66536L10.667 6.66537L16.0003 1.33203Z" stroke="black"/>
+</g>
+</g>
+<defs>
+<clipPath id="clip0_171304_610716">
+<rect width="32" height="32" fill="white"/>
+</clipPath>
+</defs>
+</svg>

+ 3 - 0
public/icons/road_t.svg

@@ -0,0 +1,3 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M21.3337 25.3346L16.0003 30.668L10.667 25.3346H13.3338V12.0013C13.3338 11.2657 12.7381 10.6692 12.0028 10.668H6.66731V13.3346L1.33398 8.0013L6.66731 2.66797V5.33463H25.3337V2.66797L30.667 8.0013L25.3337 13.3346V10.668H19.9973C19.2694 10.6697 18.6785 11.2547 18.6673 11.9803V25.3346H21.3337Z" stroke="black"/>
+</svg>

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 3 - 1
public/icons/shitib_o.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 8 - 1
public/icons/shitifuhao_o.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 3 - 7
public/icons/shitiz_o.svg


+ 3 - 1
public/icons/shouqiang_o.svg

@@ -1 +1,3 @@
-<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg class="icon" width="64px" height="64.00px" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path d="M16 208h992v599.264h-206.528V589.12h-261.824v-218.176H16V208z m32 32v98.88h523.648v218.24h261.792v218.144H976V240h-928z" /></svg>
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M1 7H31V24.7273H25.5455V17.9091H17.3636V11.0909H1V7Z" stroke="black"/>
+</svg>

+ 3 - 0
public/icons/shuangkaimen.svg

@@ -0,0 +1,3 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M27 6V19H32V25H26V21H24V7C20.6219 7 17.5683 10.7476 16.4881 15.6085C16.3721 16.1305 15.6279 16.1305 15.5119 15.6085C14.4317 10.7476 11.3781 7 8 7V21H6V25H0V19H5V6H8C11.4106 6 14.3809 9.06895 15.8843 13.2894L16 13.626L16.0132 13.5857C17.4486 9.31052 20.3762 6.14339 23.768 6.00474L24 6H27ZM26 20V7H25V20H26ZM7.001 7H6.001V20H7.001V7Z" fill="black"/>
+</svg>

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 4 - 1
public/icons/xieyin_o.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 7 - 7
public/icons/xueji_o.svg


+ 1 - 1
public/icons/xuepo_o.svg

@@ -1,3 +1,3 @@
 <svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
-<path d="M9.52067 26.33C10.2622 27.9999 16.5037 27.9828 18.015 27.9999C19.5262 28.017 25.3405 26.1618 25.2053 24.0573C25.0701 21.9527 22.6707 22.7406 23.0026 20.1697C23.3345 17.5987 30.6682 15.2873 30.6668 12.126C30.6634 4.33552 12.6674 1.91403 8.56535 5.87532C4.46333 9.83662 10.1992 9.06194 10.0483 10.4208C9.68151 13.7253 0.705159 13.4716 1.36851 17.0596C2.03187 20.6477 11.4254 19.8944 12.6674 22.2219C13.6467 24.0573 8.77918 24.6601 9.52067 26.33Z" fill="#FA3D47"/>
+<path d="M9.52019 26.33C10.2617 27.9999 16.5032 27.9828 18.0145 27.9999C19.5257 28.017 25.34 26.1618 25.2048 24.0573C25.0696 21.9527 22.6702 22.7406 23.0021 20.1697C23.334 17.5987 30.6677 15.2873 30.6663 12.126C30.6629 4.33552 12.6669 1.91403 8.56487 5.87532C4.46285 9.83662 10.1987 9.06194 10.0478 10.4208C9.68103 13.7253 0.704675 13.4716 1.36803 17.0596C2.03139 20.6477 11.4249 19.8944 12.6669 22.2219C13.6462 24.0573 8.7787 24.6601 9.52019 26.33Z" fill="#DD2C2C"/>
 </svg>

+ 11 - 0
public/icons/yakou.svg

@@ -0,0 +1,11 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M10.9971 18H8.99707V17H10.9971V18Z" fill="black"/>
+<path d="M14.9971 18H12.9971V17H14.9971V18Z" fill="black"/>
+<path d="M18.9971 18H16.9971V17H18.9971V18Z" fill="black"/>
+<path d="M22.9971 18H20.9971V17H22.9971V18Z" fill="black"/>
+<path d="M10.9971 15H8.99707V14H10.9971V15Z" fill="black"/>
+<path d="M14.9971 15H12.9971V14H14.9971V15Z" fill="black"/>
+<path d="M18.9971 15H16.9971V14H18.9971V15Z" fill="black"/>
+<path d="M22.9971 15H20.9971V14H22.9971V15Z" fill="black"/>
+<path d="M28 13H32V19H28V21H4V19H0V13H4V11H28V13ZM5 13H7V19H5V20H27V19H25V13H27V12H5V13Z" fill="black"/>
+</svg>

+ 4 - 0
public/icons/yandao.svg

@@ -0,0 +1,4 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M28 28H4V4H28V28ZM5 27H26.4844L22.1865 9.81152L5 5.51465V27ZM23.0127 8.9873L27 24.9365V5H7.0625L23.0127 8.9873Z" fill="black"/>
+<path d="M30 30H2V2H30V30ZM3 29H29V3H3V29Z" fill="black"/>
+</svg>

+ 3 - 0
public/icons/yimen.svg

@@ -0,0 +1,3 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M32 19H13V16H6V19H0V13H19V16H26V13H32V19ZM14 18H26V17H14V18ZM6 15H18V14H6V15Z" fill="black"/>
+</svg>

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 8 - 1
public/icons/youzuji_o.svg


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 7 - 1
public/icons/zhiwen_o.svg


+ 3 - 0
public/icons/zhuzi.svg

@@ -0,0 +1,3 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M30 30H2V2H30V30ZM3.70703 29H28.293L16 16.707L3.70703 29ZM16.707 16L29 28.293V3.70703L16.707 16ZM3 28.293L15.293 16L3 3.70703V28.293ZM16 15.293L28.293 3H3.70703L16 15.293Z" fill="black"/>
+</svg>

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 8 - 1
public/icons/zuozuji_o.svg


+ 12 - 7
public/static/kankan.html

@@ -53,19 +53,24 @@
 
     const init = async () => {
       if (loadPackCount < 2) return;
-      await setTimeout(() => {}, 1000)
+      await setTimeout(() => { }, 1000)
       var kankan = new KanKan({
         dom: '#scene',
         num: params.get('m'),
         server: host,
         resource: host + '/oss/'
       })
-      // kankan.Scene.on('loaded', () => {
-      //   const player = kankan.core.get('Player')
-      //   player.viewLinkManager.addEventListener('loaded', () => {
-      //     player.viewLinkManager.hideAllViews()
-      //   })
-      // })
+      kankan.Scene.on('loaded', () => {
+        const player = kankan.core.get('Player')
+        player.viewLinkManager.addEventListener('loaded', () => {
+          player.viewLinkManager.hideAllViews()
+        })
+      })
+      kankan.Scene.on('ready', async () => {
+        let metadata = await kankan.store.get('metadata')
+        metadata.surveillances = 0
+        
+      })
       kankan.render()
     }
   </script>

+ 10 - 4
src/core/components/index.ts

@@ -61,11 +61,17 @@ type CompAttach<key extends ShapeType> = {
   getPredefine?: (attrKey: keyof DrawItem<key>) => any;
 };
 type _Components = {
-  [key in keyof typeof _components]: (typeof _components)[key]
-}
+  [key in keyof typeof _components]: (typeof _components)[key];
+};
 export type Components = {
-  [key in keyof _Components]: Omit<_Components[key], keyof CompAttach<key>> & CompAttach<key>
-} 
+  [key in keyof _Components]: {
+    [a in
+      | keyof _Components[key]
+      | keyof CompAttach<key>]: a extends keyof CompAttach<key>
+      ? CompAttach<key>[a]
+      : a extends keyof _Components[key] ? _Components[key][a] : never;
+  };
+};
 export type ComponentValue<
   T extends ShapeType,
   K extends keyof Components[T]

+ 4 - 0
src/core/hook/use-draw.ts

@@ -242,6 +242,7 @@ const useInteractiveDrawTemp = <T extends ShapeType>({
   const clear = () => {
     beforeHandler.clear();
     beforeHandler.clearRef();
+    
   };
 
   const ia = useIA({
@@ -253,6 +254,7 @@ const useInteractiveDrawTemp = <T extends ShapeType>({
       quitDrawShape();
       clear();
       quit && quit();
+      console.error('quitDrawShape')
     },
     enter,
     beforeHandler: (p) => {
@@ -288,6 +290,7 @@ const useInteractiveDrawTemp = <T extends ShapeType>({
     item = reactive(item);
 
     const storeAddItem = (cItem: any) => {
+      console.error('storeAddItem')
       const items = store.getTypeItems(type);
       if (items.some((item) => item.id === cItem.id)) {
         store.setItem(type, { id: cItem.id, value: cItem });
@@ -313,6 +316,7 @@ const useInteractiveDrawTemp = <T extends ShapeType>({
       watch(
         cur,
         () => {
+          console.log('emm')
           obj.interactiveFixData({
             info: {
               cur,

+ 1 - 1
src/core/hook/use-event.ts

@@ -203,10 +203,10 @@ export const useGlobalOnlyRightClickShape = installGlobalVar(() => {
       let clickShape: any
       let ndx = -1
       if (ev.button === 2) {
+        console.log(clickShape)
         const pos = stage.value?.getNode().pointerPos;
         if (!pos) return false;
         clickShape = stage.value?.getNode().getIntersection(pos);
-        console.log(clickShape)
         do {
           ndx = checkShapes.indexOf(clickShape!);
           if (~ndx) {

+ 20 - 38
src/core/hook/use-global-vars.ts

@@ -380,9 +380,8 @@ export const useTempStatus = installGlobalVar(() => {
   return { tempStatus: temp, enterTemp }
 });
 
-
-export const useMountMenusFilter = installGlobalVar(() => {
-  type Val = (d: PropertyDescribes) => PropertyDescribes
+const getFilters = <T>() => {
+  type Val = (d: T) => T
   const globalFilter = ref<{[key in ShapeType]?: Val}>({})
   const shapeFilter = ref<Record<string, Val>>({})
   const setShapeFilter = (id: string, descs?: Val) => {
@@ -398,14 +397,13 @@ export const useMountMenusFilter = installGlobalVar(() => {
     } else {
       globalFilter.value[type] = descs
     }
-    
   }
 
   return {
-    setMenusFilter: setFilter,
-    setShapeMenusFilter: setShapeFilter,
+    setFilter,
+    setShapeFilter,
     getFilter(type: ShapeType, id: string) {
-      return (menus: PropertyDescribes) => {
+      return (menus: T) => {
         if (globalFilter.value[type]) {
           menus = globalFilter.value[type](menus)
         }
@@ -416,42 +414,26 @@ export const useMountMenusFilter = installGlobalVar(() => {
       }
     }
   }
+}
+
+
+export const useMountMenusFilter = installGlobalVar(() => {
+  const menusFilter = getFilters<PropertyDescribes>()
+  return {
+    setMenusFilter: menusFilter.setFilter,
+    setShapeMenusFilter: menusFilter.setShapeFilter,
+    getFilter: menusFilter.getFilter
+  }
 })
 
 
+
 export const useMouseMenusFilter = installGlobalVar(() => {
   type Menu = { icon?: any; label?: string; handler: () => void }
-  const globalFilter = ref<{[key in ShapeType]?: (menus: Menu[]) => Menu[]}>({})
-  const shapeFilter = ref<Record<string, (menus: Menu[]) => Menu[]>>({})
-  const setShapeFilter = (id: string, filter?: (menus: Menu[]) => Menu[]) => {
-    if (!filter) {
-      delete shapeFilter.value[id]
-    } else {
-      shapeFilter.value[id] = filter
-    }
-  }
-  const setFilter = (type: ShapeType, filter?: (menus: Menu[]) => Menu[]) => {
-    if (!filter) {
-      delete globalFilter.value[type]
-    } else {
-      globalFilter.value[type] = filter
-    }
-    
-  }
-
+  const propsFilter = getFilters<Menu[]>()
   return {
-    setMenusFilter: setFilter,
-    setShapeMenusFilter: setShapeFilter,
-    getFilter(type: ShapeType, id: string) {
-      return (menus: Menu[]) => {
-        if (globalFilter.value[type]) {
-          menus = globalFilter.value[type](menus)
-        }
-        if (shapeFilter.value[id]) {
-          menus = shapeFilter.value[id](menus)
-        }
-        return menus
-      }
-    }
+    setMenusFilter: propsFilter.setFilter,
+    setShapeMenusFilter: propsFilter.setShapeFilter,
+    getFilter: propsFilter.getFilter
   }
 })

+ 1 - 0
src/core/hook/use-interactive.ts

@@ -140,6 +140,7 @@ export const useInteractiveAreas = ({
     enter && enter();
 
     const upHandler = (ev: MouseEvent) => {
+      console.log('upHandler')
       if (downed) {
         mode.del(Mode.draging);
       }

+ 1 - 0
src/core/html-mount/propertys/index.ts

@@ -18,6 +18,7 @@ export const proportionType = "proportion";
 export const fixProportionType = "fixProportion"
 export const textType = 'text'
 export const inputNumType = 'inputNum'
+export { originDescribes }
 
 export const propertyComponents = {
   [colorType]: Color,

+ 1 - 0
src/example/components/slide/actions.ts

@@ -53,6 +53,7 @@ export const text: MenuItem = {
 
 export const table: MenuItem = {
   icon: "table",
+  single: true,
   ...genDrawItem("table", {}),
 };
 

+ 30 - 2
src/example/fuse/views/tabulation/defStyle.ts

@@ -5,8 +5,10 @@ import { defaultStyle as triangleDefStyle } from '@/core/components/triangle'
 import { defaultStyle as arrowDefStyle } from '@/core/components/arrow'
 import { PaperKey } from '@/example/components/slide/actions'
 import { mergeFuns } from '@/utils/shared'
-import { getRealPixel } from './gen-tab'
+import { getRealPixel } from './tabulation/gen-tab'
 import { defaultTableStyle } from '@/core/components/serial'
+import { originDescribes } from '@/core/html-mount/propertys'
+import { Draw } from '@/example/components/container/use-draw'
 
 const setDefStyle = <T extends {}>(sys: T, custom: Partial<T>) => {
   const backs: (() => void)[] = []
@@ -19,8 +21,18 @@ const setDefStyle = <T extends {}>(sys: T, custom: Partial<T>) => {
   return mergeFuns(backs)
 }
 
-export const tabCustomStyle = (p: PaperKey) => {
+export const tabCustomStyle = (p: PaperKey, draw: Draw) => {
+  draw.mountFilter.setMenusFilter('icon', (data) => {
+    data.strokeWidth.props = {
+      ...data.strokeWidth.props,
+      proportion: true
+    }
+    return data
+  })
   const backs = [
+    () => {
+      draw.mountFilter.setMenusFilter('icon')
+    },
     setDefStyle(iconDefStyle, {
       width: getRealPixel(2, p),
       height: getRealPixel(2, p),
@@ -40,4 +52,20 @@ export const tabCustomStyle = (p: PaperKey) => {
   console.log(iconDefStyle)
 
   return mergeFuns(backs)
+}
+
+export const overviewCustomStyle = (draw: Draw) => {
+  draw.mountFilter.setMenusFilter('icon', (data) => {
+    data.strokeWidth.props = {
+      ...data.strokeWidth.props,
+      proportion: true
+    }
+    return data
+  })
+  const backs = [
+    () => {
+      draw.mountFilter.setMenusFilter('icon')
+    }
+  ]
+  return mergeFuns(backs)
 }

+ 19 - 1
src/example/fuse/views/overview/index.vue

@@ -32,6 +32,7 @@ import { Draw } from "../../../components/container/use-draw";
 import { Scene } from "../../../platform/platform-resource";
 import Dialog from "../../../dialog/dialog.vue";
 import { refreshOverviewData, overviewData } from "../../store";
+import { overviewCustomStyle } from "../defStyle";
 
 const uploadResourse = window.platform.uploadResourse;
 const full = ref(false);
@@ -49,9 +50,26 @@ const init = async (draw: Draw) => {
   // setMap(draw);
   draw.store.setStore(overviewData.value.store);
   overviewData.value.viewport && draw.viewer.setViewMat(overviewData.value.viewport);
+  return overviewCustomStyle(draw);
 };
 
-watch(draw, (draw) => draw && init(draw));
+watch(draw, (draw, _, onCleanup) => {
+  if (draw) {
+    let des = false;
+    let unInit: () => void;
+    init(draw).then((_unInit) => {
+      if (!des) {
+        unInit = _unInit;
+      } else {
+        _unInit();
+      }
+    });
+    onCleanup(() => {
+      unInit && unInit();
+      des = true;
+    });
+  }
+});
 const title = computed(() => overviewData.value?.title || "绘图");
 watchEffect(() => {
   document.title = title.value;

+ 9 - 3
src/example/fuse/views/overview/slide-icons.vue

@@ -38,8 +38,6 @@ const emit = defineEmits<{ (e: "exit"): void }>();
 
 const drawIcon = async (url: string, name: string, item: any) => {
   const svgContent = parseSvgContent(await getSvgContent(url));
-  console.log(item);
-
   const maxSize = 100;
   const addHeight = (maxSize / svgContent.width) * svgContent.height;
   const size = {
@@ -51,13 +49,21 @@ const drawIcon = async (url: string, name: string, item: any) => {
     size.width = (maxSize / svgContent.height) * svgContent.width;
   }
 
+  const color = {
+    fill: svgContent.paths[0]?.fill,
+    stroke: svgContent.paths[0]?.stroke,
+  };
+  if (!color.fill && !color.stroke) {
+    color.stroke = "#000000";
+  }
+
   props.draw.enterDrawShape(
     "icon",
     {
       url,
       ...size,
       name,
-      fill: "#000000",
+      ...color,
       ...(item.parse || {}),
     },
     true

+ 2 - 2
src/example/fuse/views/tabulation/index.vue

@@ -47,7 +47,7 @@ import { round } from "@/utils/shared";
 import { PaperKey } from "@/example/components/slide/actions";
 import { StoreData } from "@/core/store/store";
 import { getImageSize } from "@/utils/shape";
-import { tabCustomStyle } from "./defStyle";
+import { tabCustomStyle } from "../defStyle";
 import { defaultLayer } from "@/constant";
 
 const uploadResourse = window.platform.uploadResourse;
@@ -103,7 +103,7 @@ const init = async (draw: Draw) => {
     },
   });
   inited.value = true;
-  return tabCustomStyle(p);
+  return tabCustomStyle(p, draw);
 };
 watch(draw, (draw, _, onCleanup) => {
   if (draw) {

+ 47 - 26
src/example/platform/platform-draw.ts

@@ -6,12 +6,14 @@ import { getBaseItem } from "@/core/components/util";
 import { LineData, defaultStyle } from "@/core/components/line";
 import { getInitCtx, normalLineData } from "@/core/components/line/use-draw";
 import { defaultStyle as iconDefaultStyle } from "@/core/components/icon";
+import { defaultStyle as textDefaultStyle } from "@/core/components/text";
 import { Transform } from "konva/lib/Util";
 import { ElMessage } from "element-plus";
 import { ImageData } from "@/core/components/image";
 import { Size } from "@/utils/math";
 import { watchEffect } from "vue";
 import { getSvgContent, parseSvgContent } from "@/utils/resource";
+import { TextData } from "@/core/components/text";
 
 const scaleResource = (info: AIExposeData, scale: number) => {
   const floors = info.floors.map((item) => ({
@@ -165,6 +167,7 @@ const drawLayerResource = async (
 ) => {
   const bound = genBound();
   const images: any[] = [];
+  const texts: TextData[] = [];
   const createTime = Date.now();
 
   let geo: LineData = {
@@ -286,40 +289,58 @@ const drawLayerResource = async (
     if (item.rotate) {
       tf.rotate(item.rotate);
     }
-    let svgAttach: any = {}
-    if (item.url.includes(".svg")) {
-      svgAttach = {
-        ...iconDefaultStyle,
-        stroke: "#000000" ,
-        fill: null
+    if (item.isText) {
+      texts.push({
+        ...getBaseItem(),
+        ...textDefaultStyle,
+        content: item.url,
+        mat: tf.m,
+      });
+    } else {
+      let svgAttach: any = {};
+      if (item.url.includes(".svg")) {
+        svgAttach = {
+          ...iconDefaultStyle,
+          stroke: "#000000",
+          fill: null,
+          width: item.size ? item.size.width : 100,
+          height: item.size ? item.size.height : 100,
+        };
+        try {
+          const svg = parseSvgContent(await getSvgContent(item.url));
+          if (svg.paths.length) {
+            svgAttach.fill = svg.paths[0].fill || null;
+            svgAttach.stroke = svg.paths[0].stroke || null;
+            if (!svgAttach.fill && !svgAttach.stroke) {
+              svgAttach.stroke = "#000000";
+            }
+            if (svg.width && svg.height) {
+              if (svg.width > svg.height) {
+                svgAttach.height = (svg.height / svg.width) * svgAttach.width;
+              }
+            }
+          }
+        } catch {}
       }
-      try {
-        const svg = parseSvgContent(await getSvgContent(item.url))
-        if (svg.paths.length) {
-          svgAttach.fill = svg.paths[0].fill || null
-          svgAttach.stroke = svg.paths[0].stroke || null
-        }
-      } catch {}
-    }
 
-    images.push({
-      ...getBaseItem(),
-      ...svgAttach,
-      name: item.name,
-      createTime: createTime + layerResource.geos.length + ndx,
-      url: item.url,
-      lock: import.meta.env.DEV ? false : true,
-      mat: tf.m,
-      width: item.size ? item.size.width : 100,
-      height: item.size ? item.size.height : 100,
-      cornerRadius: 0,
-    });
+      images.push({
+        ...getBaseItem(),
+        name: item.name,
+        createTime: createTime + layerResource.geos.length + ndx,
+        url: item.url,
+        lock: import.meta.env.DEV ? false : true,
+        mat: tf.m,
+        cornerRadius: 0,
+        ...svgAttach,
+      });
+    }
   }
 
   draw.store.addItems(
     "icon",
     images.filter((item) => item.url.includes(".svg"))
   );
+  draw.store.addItems("text", texts);
 
   draw.store.addItems(
     "image",

+ 5 - 2
src/example/platform/platform-resource.ts

@@ -45,6 +45,7 @@ export type Taging = {
   rotate?: number;
   name?: string;
   pixel?: boolean;
+  isText?: boolean
   subgroup?: string;
 };
 
@@ -283,10 +284,12 @@ export const taggingGets = {
                 }
               }
             }
-            if (name) {
+            const isTag = icon === 'Tag'
+            if (name || isTag) {
               tags.push({
+                isText: isTag,
                 position: pos,
-                url: `./icons/${icon ? icon : "circle"}.svg`,
+                url: isTag ? shape.name : `./icons/${icon ? icon : "circle"}.svg`,
                 name,
                 pixel: true,
                 size,

+ 1 - 1
src/utils/event.ts

@@ -78,7 +78,7 @@ export const dragListener = (dom: HTMLElement, props: DragProps | DragProps['mov
 		moveHandler = (ev: PointerEvent) => {
 			props.notPrevent || ev.preventDefault();
       if (ev.buttons <= 0) {
-        endHandler(ev)
+        endHandler && endHandler(ev)
         return;
       }
 			const end = attrib === 'offset' ? getOffset(ev, dom) : { x: ev.pageX, y: ev.pageY }