hs-admin-ui 15.7.2 → 15.7.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (720) hide show
  1. package/dist/bcIcon-D87eJ-Yx.js +1 -0
  2. package/dist/bcIcon-wecvhPTY.mjs +4 -0
  3. package/dist/index-DKuNUnol.js +349 -0
  4. package/dist/index-nZnB2jTn.mjs +144186 -0
  5. package/dist/index.css +1 -0
  6. package/dist/index.js +1 -1
  7. package/dist/index.mjs +135 -169
  8. package/dist/types/element-plus.d.ts +557 -0
  9. package/dist/types/index.d.ts +32 -1
  10. package/dist/types/src/components/base/Affix/index.d.ts +1 -0
  11. package/dist/types/src/components/base/Affix/src/Affix.vue.d.ts +3 -0
  12. package/dist/types/src/components/base/Alert/index.d.ts +1 -0
  13. package/dist/types/src/components/base/Alert/src/Alert.vue.d.ts +3 -0
  14. package/dist/types/src/components/base/Aside/index.d.ts +1 -0
  15. package/dist/types/src/components/base/Aside/src/Aside.vue.d.ts +3 -0
  16. package/dist/types/src/components/base/Autocomplete/index.d.ts +1 -0
  17. package/dist/types/src/components/base/Autocomplete/src/Autocomplete.vue.d.ts +3 -0
  18. package/dist/types/src/components/base/Backtop/index.d.ts +1 -0
  19. package/dist/types/src/components/base/Backtop/src/Backtop.vue.d.ts +3 -0
  20. package/dist/types/src/components/base/Badge/index.d.ts +1 -0
  21. package/dist/types/src/components/base/Badge/src/Badge.vue.d.ts +3 -0
  22. package/dist/types/src/components/base/Button/index.d.ts +2 -0
  23. package/dist/types/src/components/base/Button/src/Button.vue.d.ts +3 -0
  24. package/dist/types/src/components/base/Button/src/ButtonGroup.vue.d.ts +3 -0
  25. package/dist/types/src/components/base/Calendar/index.d.ts +1 -0
  26. package/dist/types/src/components/base/Calendar/src/Calendar.vue.d.ts +3 -0
  27. package/dist/types/src/components/base/Card/index.d.ts +1 -0
  28. package/dist/types/src/components/base/Card/src/Card.vue.d.ts +3 -0
  29. package/dist/types/src/components/base/Carousel/index.d.ts +2 -0
  30. package/dist/types/src/components/base/Carousel/src/Carousel.vue.d.ts +3 -0
  31. package/dist/types/src/components/base/Carousel/src/CarouselItem.vue.d.ts +3 -0
  32. package/dist/types/src/components/base/Cascader/index.d.ts +2 -0
  33. package/dist/types/src/components/base/Cascader/src/Cascader.vue.d.ts +3 -0
  34. package/dist/types/src/components/base/Cascader/src/CascaderPanel.vue.d.ts +3 -0
  35. package/dist/types/src/components/base/Checkbox/index.d.ts +3 -0
  36. package/dist/types/src/components/base/Checkbox/src/Checkbox.vue.d.ts +3 -0
  37. package/dist/types/src/components/base/Checkbox/src/CheckboxButton.vue.d.ts +3 -0
  38. package/dist/types/src/components/base/Checkbox/src/CheckboxGroup.vue.d.ts +3 -0
  39. package/dist/types/src/components/base/Col/index.d.ts +1 -0
  40. package/dist/types/src/components/base/Col/src/Col.vue.d.ts +3 -0
  41. package/dist/types/src/components/base/Collapse/index.d.ts +2 -0
  42. package/dist/types/src/components/base/Collapse/src/Collapse.vue.d.ts +3 -0
  43. package/dist/types/src/components/base/Collapse/src/CollapseItem.vue.d.ts +3 -0
  44. package/dist/types/src/components/base/ColorPicker/index.d.ts +1 -0
  45. package/dist/types/src/components/base/ColorPicker/src/ColorPicker.vue.d.ts +3 -0
  46. package/dist/types/src/components/base/Container/index.d.ts +1 -0
  47. package/dist/types/src/components/base/Container/src/Container.vue.d.ts +3 -0
  48. package/dist/types/src/components/base/DatePicker/index.d.ts +1 -0
  49. package/dist/types/src/components/base/DatePicker/src/DatePicker.vue.d.ts +3 -0
  50. package/dist/types/src/components/base/Descriptions/index.d.ts +2 -0
  51. package/dist/types/src/components/base/Descriptions/src/Descriptions.vue.d.ts +3 -0
  52. package/dist/types/src/components/base/Descriptions/src/DescriptionsItem.vue.d.ts +3 -0
  53. package/dist/types/src/components/base/Dialog/index.d.ts +1 -0
  54. package/dist/types/src/components/base/Dialog/src/Dialog.vue.d.ts +3 -0
  55. package/dist/types/src/components/base/Divider/index.d.ts +1 -0
  56. package/dist/types/src/components/base/Divider/src/Divider.vue.d.ts +3 -0
  57. package/dist/types/src/components/base/Drawer/index.d.ts +1 -0
  58. package/dist/types/src/components/base/Drawer/src/Drawer.vue.d.ts +3 -0
  59. package/dist/types/src/components/base/Dropdown/index.d.ts +3 -0
  60. package/dist/types/src/components/base/Dropdown/src/Dropdown.vue.d.ts +3 -0
  61. package/dist/types/src/components/base/Dropdown/src/DropdownItem.vue.d.ts +3 -0
  62. package/dist/types/src/components/base/Dropdown/src/DropdownMenu.vue.d.ts +3 -0
  63. package/dist/types/src/components/base/Empty/index.d.ts +1 -0
  64. package/dist/types/src/components/base/Empty/src/Empty.vue.d.ts +3 -0
  65. package/dist/types/src/components/base/Footer/index.d.ts +1 -0
  66. package/dist/types/src/components/base/Footer/src/Footer.vue.d.ts +3 -0
  67. package/dist/types/src/components/base/Form/index.d.ts +2 -0
  68. package/dist/types/src/components/base/Form/src/Form.vue.d.ts +3 -0
  69. package/dist/types/src/components/base/Form/src/FormItem.vue.d.ts +3 -0
  70. package/dist/types/src/components/base/Header/index.d.ts +1 -0
  71. package/dist/types/src/components/base/Header/src/Header.vue.d.ts +3 -0
  72. package/dist/types/src/components/base/Icon/index.d.ts +1 -0
  73. package/dist/types/src/components/base/Icon/src/Icon.vue.d.ts +3 -0
  74. package/dist/types/src/components/base/Image/index.d.ts +1 -0
  75. package/dist/types/src/components/base/Image/src/Image.vue.d.ts +3 -0
  76. package/dist/types/src/components/base/ImageViewer/index.d.ts +1 -0
  77. package/dist/types/src/components/base/ImageViewer/src/ImageViewer.vue.d.ts +3 -0
  78. package/dist/types/src/components/base/Input/index.d.ts +1 -0
  79. package/dist/types/src/components/base/Input/src/Input.vue.d.ts +30 -0
  80. package/dist/types/src/components/base/InputNumber/index.d.ts +1 -0
  81. package/dist/types/src/components/base/InputNumber/src/InputNumber.vue.d.ts +3 -0
  82. package/dist/types/src/components/base/Main/index.d.ts +1 -0
  83. package/dist/types/src/components/base/Main/src/Main.vue.d.ts +3 -0
  84. package/dist/types/src/components/base/Menu/index.d.ts +3 -0
  85. package/dist/types/src/components/base/Menu/src/Menu.vue.d.ts +3 -0
  86. package/dist/types/src/components/base/Menu/src/MenuItem.vue.d.ts +3 -0
  87. package/dist/types/src/components/base/Menu/src/SubMenu.vue.d.ts +3 -0
  88. package/dist/types/src/components/base/Pagination/index.d.ts +1 -0
  89. package/dist/types/src/components/base/Pagination/src/Pagination.vue.d.ts +3 -0
  90. package/dist/types/src/components/base/Popconfirm/index.d.ts +1 -0
  91. package/dist/types/src/components/base/Popconfirm/src/Popconfirm.vue.d.ts +3 -0
  92. package/dist/types/src/components/base/Popover/index.d.ts +1 -0
  93. package/dist/types/src/components/base/Popover/src/Popover.vue.d.ts +3 -0
  94. package/dist/types/src/components/base/Progress/index.d.ts +1 -0
  95. package/dist/types/src/components/base/Progress/src/Progress.vue.d.ts +3 -0
  96. package/dist/types/src/components/base/Qr/index.d.ts +1 -0
  97. package/dist/types/src/components/base/Qr/src/Qr.vue.d.ts +3 -0
  98. package/dist/types/src/components/base/Radio/index.d.ts +3 -0
  99. package/dist/types/src/components/base/Radio/src/Radio.vue.d.ts +3 -0
  100. package/dist/types/src/components/base/Radio/src/RadioButton.vue.d.ts +3 -0
  101. package/dist/types/src/components/base/Radio/src/RadioGroup.vue.d.ts +3 -0
  102. package/dist/types/src/components/base/Rate/index.d.ts +1 -0
  103. package/dist/types/src/components/base/Rate/src/Rate.vue.d.ts +3 -0
  104. package/dist/types/src/components/base/Result/index.d.ts +1 -0
  105. package/dist/types/src/components/base/Result/src/Result.vue.d.ts +3 -0
  106. package/dist/types/src/components/base/Row/index.d.ts +1 -0
  107. package/dist/types/src/components/base/Row/src/Row.vue.d.ts +3 -0
  108. package/dist/types/src/components/base/Scrollbar/index.d.ts +1 -0
  109. package/dist/types/src/components/base/Scrollbar/src/Scrollbar.vue.d.ts +3 -0
  110. package/dist/types/src/components/base/Select/index.d.ts +3 -0
  111. package/dist/types/src/components/base/Select/src/Option.vue.d.ts +3 -0
  112. package/dist/types/src/components/base/Select/src/OptionGroup.vue.d.ts +3 -0
  113. package/dist/types/src/components/base/Select/src/Select.vue.d.ts +37 -0
  114. package/dist/types/src/components/base/SelectV2/index.d.ts +1 -0
  115. package/dist/types/src/components/base/SelectV2/src/SelectV2.vue.d.ts +3 -0
  116. package/dist/types/src/components/base/Slider/index.d.ts +1 -0
  117. package/dist/types/src/components/base/Slider/src/Slider.vue.d.ts +3 -0
  118. package/dist/types/src/components/base/Steps/index.d.ts +1 -0
  119. package/dist/types/src/components/base/Steps/src/Step.vue.d.ts +3 -0
  120. package/dist/types/src/components/base/Steps/src/Steps.vue.d.ts +3 -0
  121. package/dist/types/src/components/base/Switch/index.d.ts +1 -0
  122. package/dist/types/src/components/base/Switch/src/Switch.vue.d.ts +3 -0
  123. package/dist/types/src/components/base/Table/index.d.ts +2 -0
  124. package/dist/types/src/components/base/Table/src/Table.vue.d.ts +3 -0
  125. package/dist/types/src/components/base/Table/src/TableColumn.vue.d.ts +3 -0
  126. package/dist/types/src/components/base/Tabs/index.d.ts +2 -0
  127. package/dist/types/src/components/base/Tabs/src/TabPane.vue.d.ts +3 -0
  128. package/dist/types/src/components/base/Tabs/src/Tabs.vue.d.ts +3 -0
  129. package/dist/types/src/components/base/Tag/index.d.ts +2 -0
  130. package/dist/types/src/components/base/Tag/src/CheckTag.vue.d.ts +3 -0
  131. package/dist/types/src/components/base/Tag/src/Tag.vue.d.ts +3 -0
  132. package/dist/types/src/components/base/Text/index.d.ts +1 -0
  133. package/dist/types/src/components/base/Text/src/Text.vue.d.ts +3 -0
  134. package/dist/types/src/components/base/TimePicker/index.d.ts +1 -0
  135. package/dist/types/src/components/base/TimePicker/src/TimePicker.vue.d.ts +3 -0
  136. package/dist/types/src/components/base/TimeSelect/index.d.ts +1 -0
  137. package/dist/types/src/components/base/TimeSelect/src/TimeSelect.vue.d.ts +3 -0
  138. package/dist/types/src/components/base/Tooltip/index.d.ts +1 -0
  139. package/dist/types/src/components/base/Tooltip/src/Tooltip.vue.d.ts +3 -0
  140. package/dist/types/src/components/base/Tour/index.d.ts +2 -0
  141. package/dist/types/src/components/base/Tour/src/Tour.vue.d.ts +3 -0
  142. package/dist/types/src/components/base/Tour/src/TourStep.vue.d.ts +3 -0
  143. package/dist/types/src/components/base/Transfer/index.d.ts +1 -0
  144. package/dist/types/src/components/base/Transfer/src/Transfer.vue.d.ts +3 -0
  145. package/dist/types/src/components/base/Tree/index.d.ts +1 -0
  146. package/dist/types/src/components/base/Tree/src/Tree.vue.d.ts +3 -0
  147. package/dist/types/src/components/base/TreeSelect/index.d.ts +1 -0
  148. package/dist/types/src/components/base/TreeSelect/src/TreeSelect.vue.d.ts +3 -0
  149. package/dist/types/src/components/base/TreeV2/index.d.ts +1 -0
  150. package/dist/types/src/components/base/TreeV2/src/TreeV2.vue.d.ts +3 -0
  151. package/dist/types/src/components/base/Upload/index.d.ts +1 -0
  152. package/dist/types/src/components/base/Upload/src/Upload.vue.d.ts +3 -0
  153. package/dist/types/src/components/base/Watermark/index.d.ts +1 -0
  154. package/dist/types/src/components/base/Watermark/src/Watermark.vue.d.ts +3 -0
  155. package/dist/types/src/components/base/components.d.ts +60 -0
  156. package/dist/types/src/components/base/index.d.ts +174 -0
  157. package/dist/types/src/components/business/bcBox/bcBox.vue.d.ts +48 -0
  158. package/dist/types/{components → src/components}/business/bcBox/utils.d.ts +10 -11
  159. package/dist/types/src/components/business/bcBreadcrumb/bcBreadcrumb.vue.d.ts +14 -0
  160. package/dist/types/{components → src/components}/business/bcBreadcrumb/index.d.ts +1 -2
  161. package/dist/types/src/components/business/bcButton/bcButton.vue.d.ts +38 -0
  162. package/dist/types/src/components/business/bcCheckbox/bcCheckbox.vue.d.ts +23 -0
  163. package/dist/types/src/components/business/bcContextBox/bcContextBox.vue.d.ts +40 -0
  164. package/dist/types/src/components/business/bcContextBox/useContextMenu.d.ts +34 -0
  165. package/dist/types/src/components/business/bcDivider/bcDivider.vue.d.ts +38 -0
  166. package/dist/types/src/components/business/bcFace/bcFace.vue.d.ts +24 -0
  167. package/dist/types/src/components/business/bcForm/baseForm.vue.d.ts +275 -0
  168. package/dist/types/src/components/business/bcForm/bcForm.vue.d.ts +33 -0
  169. package/dist/types/{components → src/components}/business/bcForm/type.d.ts +6 -7
  170. package/dist/types/src/components/business/bcForm/useGuide.d.ts +559 -0
  171. package/dist/types/src/components/business/bcGroup/bcGroup.vue.d.ts +36 -0
  172. package/dist/types/src/components/business/bcIcon/bcIcon.vue.d.ts +27 -0
  173. package/dist/types/src/components/business/bcInputGroup/bcInputGroup.vue.d.ts +20 -0
  174. package/dist/types/src/components/business/bcRadio/bcRadio.vue.d.ts +18 -0
  175. package/dist/types/src/components/business/bcSelect/bcSelect.vue.d.ts +33 -0
  176. package/dist/types/src/components/business/bcSignature/index.vue.d.ts +19 -0
  177. package/dist/types/src/components/business/bcSystemAuth/components/data.vue.d.ts +3 -0
  178. package/dist/types/src/components/business/bcSystemAuth/components/dict.vue.d.ts +3 -0
  179. package/dist/types/src/components/business/bcSystemAuth/components/fastSet/popup.vue.d.ts +17 -0
  180. package/dist/types/src/components/business/bcSystemAuth/components/field.vue.d.ts +3 -0
  181. package/dist/types/src/components/business/bcSystemAuth/components/form.vue.d.ts +11 -0
  182. package/dist/types/{components → src/components}/business/bcSystemAuth/components/selectAll/index.d.ts +2 -3
  183. package/dist/types/src/components/business/bcSystemAuth/components/selectAll/index.vue.d.ts +5 -0
  184. package/dist/types/src/components/business/bcSystemAuth/components/table.vue.d.ts +11 -0
  185. package/dist/types/src/components/business/bcSystemAuth/components/widget/btns.vue.d.ts +11 -0
  186. package/dist/types/src/components/business/bcSystemAuth/components/widget/form.vue.d.ts +11 -0
  187. package/dist/types/src/components/business/bcSystemAuth/components/widget/tab.vue.d.ts +17 -0
  188. package/dist/types/src/components/business/bcSystemAuth/components/widget/tables.vue.d.ts +11 -0
  189. package/dist/types/src/components/business/bcSystemAuth/components/widget/tablesWraper.vue.d.ts +11 -0
  190. package/dist/types/{components → src/components}/business/bcSystemAuth/fastStore.d.ts +48 -49
  191. package/dist/types/{components → src/components}/business/bcSystemAuth/fastUtils.d.ts +28 -30
  192. package/dist/types/src/components/business/bcSystemAuth/index.d.ts +2 -0
  193. package/dist/types/src/components/business/bcSystemAuth/index.vue.d.ts +17 -0
  194. package/dist/types/{components → src/components}/business/bcSystemAuth/store.d.ts +48 -49
  195. package/dist/types/src/components/business/bcSystemAuth/type.d.ts +342 -0
  196. package/dist/types/src/components/business/bcSystemAuth/useAuth.d.ts +26 -0
  197. package/dist/types/{components → src/components}/business/bcSystemAuth/utils.d.ts +28 -30
  198. package/dist/types/src/components/business/bcSystemField/components/field.vue.d.ts +3 -0
  199. package/dist/types/src/components/business/bcSystemField/components/form.vue.d.ts +11 -0
  200. package/dist/types/{components → src/components}/business/bcSystemField/components/selectAll/index.d.ts +4 -5
  201. package/dist/types/src/components/business/bcSystemField/components/selectAll/index.vue.d.ts +5 -0
  202. package/dist/types/src/components/business/bcSystemField/components/table.vue.d.ts +11 -0
  203. package/dist/types/src/components/business/bcSystemField/components/widget/form.vue.d.ts +11 -0
  204. package/dist/types/src/components/business/bcSystemField/components/widget/tab.vue.d.ts +17 -0
  205. package/dist/types/src/components/business/bcSystemField/components/widget/tables.vue.d.ts +11 -0
  206. package/dist/types/src/components/business/bcSystemField/components/widget/tablesWraper.vue.d.ts +11 -0
  207. package/dist/types/src/components/business/bcSystemField/index.d.ts +2 -0
  208. package/dist/types/src/components/business/bcSystemField/index.vue.d.ts +7 -0
  209. package/dist/types/{components → src/components}/business/bcSystemField/store.d.ts +39 -40
  210. package/dist/types/src/components/business/bcSystemField/useAuth.d.ts +14 -0
  211. package/dist/types/{components → src/components}/business/bcSystemField/utils.d.ts +20 -21
  212. package/dist/types/src/components/business/bcTable/bcFormTable.vue.d.ts +143 -0
  213. package/dist/types/src/components/business/bcTable/bcTable.vue.d.ts +32 -0
  214. package/dist/types/src/components/business/bcTable/components/btn/btn.vue.d.ts +58 -0
  215. package/dist/types/src/components/business/bcTable/components/popup/index.d.ts +2 -0
  216. package/dist/types/src/components/business/bcTable/components/popup/popup.vue.d.ts +49 -0
  217. package/dist/types/src/components/business/bcTable/components/query/components/sortForm/sortForm.vue.d.ts +14 -0
  218. package/dist/types/src/components/business/bcTable/components/query/drag.vue.d.ts +222 -0
  219. package/dist/types/src/components/business/bcTable/components/query/query.vue.d.ts +226 -0
  220. package/dist/types/{components → src/components}/business/bcTable/components/query/useQuickSearch.d.ts +2 -3
  221. package/dist/types/src/components/business/bcTable/components/table/colgroup.vue.d.ts +25 -0
  222. package/dist/types/src/components/business/bcTable/components/table/column.vue.d.ts +49 -0
  223. package/dist/types/src/components/business/bcTable/components/table/components/sortColumn/sortColumn.vue.d.ts +16 -0
  224. package/dist/types/{components → src/components}/business/bcTable/components/table/components/sortColumn/types.d.ts +1 -2
  225. package/dist/types/src/components/business/bcTable/components/table/table.vue.d.ts +64 -0
  226. package/dist/types/{components → src/components}/business/bcTable/components/table/useTable.d.ts +5 -5
  227. package/dist/types/src/components/business/bcTable/components/table/useTableHeight.d.ts +23 -0
  228. package/dist/types/{components → src/components}/business/bcTable/methods/cellDetailMethod.d.ts +0 -1
  229. package/dist/types/{components → src/components}/business/bcTable/methods/filterAgeMethod.d.ts +0 -1
  230. package/dist/types/{components → src/components}/business/bcTable/methods/footerMethod.d.ts +1 -2
  231. package/dist/types/{components → src/components}/business/bcTable/methods/formBtnMethod.d.ts +1 -2
  232. package/dist/types/{components → src/components}/business/bcTable/methods/index.d.ts +1 -2
  233. package/dist/types/{components → src/components}/business/bcTable/utils/authField.d.ts +1 -2
  234. package/dist/types/{components → src/components}/business/bcTable/utils/onFormKey.d.ts +4 -5
  235. package/dist/types/{components → src/components}/business/bcTable/utils/onTableKey.d.ts +5 -6
  236. package/dist/types/{components → src/components}/business/bcTable/utils/parseTable.d.ts +20 -21
  237. package/dist/types/{components → src/components}/business/bcTable/utils/type.d.ts +11 -12
  238. package/dist/types/{components → src/components}/business/bcTable/utils/useBcTable.d.ts +7075 -7085
  239. package/dist/types/{components → src/components}/business/bcTable/utils/useButon.d.ts +5 -6
  240. package/dist/types/src/components/business/bcTable/utils/useFormTableHeight.d.ts +18 -0
  241. package/dist/types/{components → src/components}/business/bcTable/utils/useKeydownEvent.d.ts +17 -18
  242. package/dist/types/src/components/business/bcTabs/bcTabs.vue.d.ts +61 -0
  243. package/dist/types/src/components/business/bcTabs/components/BetterScroll/index.d.ts +2 -0
  244. package/dist/types/src/components/business/bcTabs/components/BetterScroll/index.vue.d.ts +33 -0
  245. package/dist/types/src/components/business/bcTreeSearch/bcTreeSearch.vue.d.ts +55 -0
  246. package/dist/types/src/components/business/bcTreeSelect/bcTreeSelect.vue.d.ts +28 -0
  247. package/dist/types/src/components/business/bcTrtc/bcTrtc.vue.d.ts +104 -0
  248. package/dist/types/src/components/business/bcTrtc/hooks/useOperateLog.d.ts +8 -0
  249. package/dist/types/src/components/business/bcTrtc/hooks/useTrtcRoomEvent.d.ts +50 -0
  250. package/dist/types/src/components/business/bcTrtc/type.d.ts +124 -0
  251. package/dist/types/src/components/business/bcTrtc/useTrtc.d.ts +39 -0
  252. package/dist/types/src/components/business/bcTrtc/util/generateTestUserSig.d.ts +64 -0
  253. package/dist/types/src/components/business/bcTrtc/util/lib-generate-test-usersig-es.min.d.ts +20 -0
  254. package/dist/types/src/components/business/bcTrtc/util/utils.d.ts +4 -0
  255. package/dist/types/src/components/business/bcUpload/bcUpload.vue.d.ts +13 -0
  256. package/dist/types/src/components/business/bcUpload/component/highSpeedCamera.vue.d.ts +19 -0
  257. package/dist/types/src/components/business/bcUpload/component/qwebchannel.d.ts +15 -0
  258. package/dist/types/src/components/business/bcUpload/component/type.d.ts +44 -0
  259. package/dist/types/src/components/business/bcUpload/type.d.ts +83 -0
  260. package/dist/types/src/components/business/bcUpload/upload.vue.d.ts +272 -0
  261. package/dist/types/src/components/business/bcUpload/useUpload.d.ts +21 -0
  262. package/dist/types/{components → src/components}/business/bcVisual/bcVisual.vue.d.ts +9 -8
  263. package/dist/types/{components → src/components}/business/bcVisual/components/setting/dragItem.vue.d.ts +16 -9
  264. package/dist/types/src/components/business/bcVisual/components/setting/extendItem.vue.d.ts +13 -0
  265. package/dist/types/src/components/business/bcVisual/components/setting/setting.vue.d.ts +3 -0
  266. package/dist/types/{components → src/components}/business/bcVisual/components/setting/useDrag.d.ts +2 -4
  267. package/dist/types/src/components/business/bcVisual/components/table/table.vue.d.ts +6 -0
  268. package/dist/types/src/components/business/bcVisual/components/updateName/popup.vue.d.ts +17 -0
  269. package/dist/types/src/components/business/bcVisual/components/updateSql/addCondition.vue.d.ts +23 -0
  270. package/dist/types/{components → src/components}/business/bcVisual/components/updateSql/index.d.ts +1 -2
  271. package/dist/types/{components → src/components}/business/bcVisual/components/updateSql/nodeTree/index.d.ts +1 -2
  272. package/dist/types/src/components/business/bcVisual/components/updateSql/nodeTree/index.vue.d.ts +21 -0
  273. package/dist/types/src/components/business/bcVisual/components/updateSql/nodeTree/nodeTree.vue.d.ts +27 -0
  274. package/dist/types/src/components/business/bcVisual/components/updateSql/popup.vue.d.ts +17 -0
  275. package/dist/types/{components → src/components}/business/bcVisual/useTableFormat.d.ts +28 -29
  276. package/dist/types/{components → src/components}/business/bcVisual/utils.d.ts +1 -3
  277. package/dist/types/src/components/business/index.d.ts +52 -0
  278. package/dist/types/src/hooks/index.d.ts +3 -0
  279. package/dist/types/src/hooks/onKeyStroke.d.ts +13 -0
  280. package/dist/types/src/hooks/useExpose.d.ts +23 -0
  281. package/dist/types/src/hooks/useKeyStroke.d.ts +22 -0
  282. package/dist/types/{types → src/types}/auth.d.ts +1 -2
  283. package/dist/types/{types → src/types}/components.d.ts +1 -2
  284. package/dist/types/{types → src/types}/customData.d.ts +16 -19
  285. package/dist/types/{types → src/types}/form.d.ts +1 -2
  286. package/dist/types/{types → src/types}/formItem/autocomplete.d.ts +1 -2
  287. package/dist/types/{types → src/types}/formItem/checkbox.d.ts +1 -2
  288. package/dist/types/{types → src/types}/formItem/input.d.ts +1 -2
  289. package/dist/types/{types → src/types}/formItem/inputGroup.d.ts +1 -2
  290. package/dist/types/{types → src/types}/formItem/inputNumber.d.ts +1 -2
  291. package/dist/types/{types → src/types}/formItem/radio.d.ts +1 -2
  292. package/dist/types/{types → src/types}/formItem/selelct.d.ts +1 -2
  293. package/dist/types/{types → src/types}/formItem/treeSelect.d.ts +1 -2
  294. package/dist/types/{utils → src/utils}/arrayOperation.d.ts +1 -1
  295. package/dist/types/{utils → src/utils}/common.d.ts +3 -4
  296. package/dist/types/src/utils/commonFunction.d.ts +14 -0
  297. package/dist/types/{utils → src/utils}/download.d.ts +4 -4
  298. package/dist/types/{utils → src/utils}/getDataType.d.ts +2 -3
  299. package/dist/types/src/utils/index.d.ts +26 -0
  300. package/dist/types/{utils/loading.d.ts → src/utils/loading/index.d.ts} +1 -1
  301. package/dist/types/src/utils/lodash.d.ts +2 -0
  302. package/dist/types/{utils → src/utils}/mitt.d.ts +2 -3
  303. package/dist/types/{utils → src/utils}/number.d.ts +2 -14
  304. package/dist/types/{utils → src/utils}/other.d.ts +11 -12
  305. package/dist/types/src/utils/request/index.d.ts +6 -0
  306. package/dist/types/{utils → src/utils}/request/interceptors/request/authorization.interceptor.d.ts +1 -2
  307. package/dist/types/{utils → src/utils}/request/interceptors/request/result.type.interceptor.d.ts +6 -2
  308. package/dist/types/{utils → src/utils}/request/interceptors/request/undefined-params-handler.interceptor.d.ts +13 -2
  309. package/dist/types/{utils → src/utils}/request/interceptors/response/error-handler.interceptor.d.ts +1 -2
  310. package/dist/types/{utils → src/utils}/request/repeatRequest.d.ts +1 -2
  311. package/dist/types/src/utils/request/request.d.ts +6 -0
  312. package/dist/types/src/utils/showMessage.d.ts +3 -0
  313. package/dist/types/src/utils/showMessageBox.d.ts +3 -0
  314. package/dist/types/src/utils/showNotification.d.ts +3 -0
  315. package/dist/types/{utils → src/utils}/showPopup/index.d.ts +5 -6
  316. package/dist/types/src/utils/showPopup/showPopup.vue.d.ts +56 -0
  317. package/dist/types/{utils → src/utils}/storage.d.ts +12 -14
  318. package/dist/types/{utils → src/utils}/tree.d.ts +3 -4
  319. package/dist/types/{utils → src/utils}/url.d.ts +2 -3
  320. package/dist/types/vxe-table.d.ts +3 -0
  321. package/package.json +16 -39
  322. package/LICENSE +0 -21
  323. package/dist/401-AUOYjSJU.mjs +0 -56
  324. package/dist/401-Dx_ldIeG.js +0 -1
  325. package/dist/404-B05H_jCa.mjs +0 -61
  326. package/dist/404-B05H_jCa.mjs.gz +0 -0
  327. package/dist/404-DkKlhDfs.js +0 -1
  328. package/dist/404-DkKlhDfs.js.gz +0 -0
  329. package/dist/account-BHYG232h.js +0 -1
  330. package/dist/account-yggw2mbI.mjs +0 -215
  331. package/dist/aside-BojWyGQq.mjs +0 -164
  332. package/dist/aside-IM1nd79w.js +0 -1
  333. package/dist/baseBtnConfig-C6KLedE5.mjs +0 -273
  334. package/dist/baseBtnConfig-DRxjBT8Z.js +0 -1
  335. package/dist/baseFormConfig-0aAt8oYn.mjs +0 -504
  336. package/dist/baseFormConfig-0aAt8oYn.mjs.gz +0 -0
  337. package/dist/baseFormConfig-BaFbaMWd.mjs +0 -722
  338. package/dist/baseFormConfig-BaFbaMWd.mjs.gz +0 -0
  339. package/dist/baseFormConfig-D5Q35Bo3.js +0 -1
  340. package/dist/baseFormConfig-ZNK--4Oe.js +0 -1
  341. package/dist/baseTableConfig-DHWjKxmf.js +0 -1
  342. package/dist/baseTableConfig-DHWjKxmf.js.gz +0 -0
  343. package/dist/baseTableConfig-YG6eGkRt.mjs +0 -2624
  344. package/dist/baseTableConfig-YG6eGkRt.mjs.gz +0 -0
  345. package/dist/bcFormConfig-BMrGl9cm.js +0 -1
  346. package/dist/bcFormConfig-CO-MWQ_m.mjs +0 -234
  347. package/dist/bcPageTreeBySystem.vue_vue_type_script_setup_true_lang-DKsh2Yf4.js +0 -1
  348. package/dist/bcPageTreeBySystem.vue_vue_type_script_setup_true_lang-Q23Yc4iS.mjs +0 -131
  349. package/dist/bcSwitchSystems.vue_vue_type_script_setup_true_lang-C5TEB_AO.mjs +0 -101
  350. package/dist/bcSwitchSystems.vue_vue_type_script_setup_true_lang-CWp-82fW.js +0 -1
  351. package/dist/btnIndex-Djj2CZ9j.js +0 -1
  352. package/dist/btnIndex-HGBAQo05.mjs +0 -287
  353. package/dist/btnIndex-HGBAQo05.mjs.gz +0 -0
  354. package/dist/classic-CvIqhQyg.js +0 -1
  355. package/dist/classic-DXgLIKOA.mjs +0 -81
  356. package/dist/cloneConfigDialog-B9mCSU49.js +0 -1
  357. package/dist/cloneConfigDialog-B9mCSU49.js.gz +0 -0
  358. package/dist/cloneConfigDialog-CKTvFSS6.mjs +0 -817
  359. package/dist/cloneConfigDialog-CKTvFSS6.mjs.gz +0 -0
  360. package/dist/columns-D5tXNIBk.js +0 -1
  361. package/dist/columns-DpoO5Zsj.mjs +0 -87
  362. package/dist/columnsAside-7U1fFgNM.js +0 -1
  363. package/dist/columnsAside-Decj2--4.mjs +0 -220
  364. package/dist/contextmenu-CboZcHAM.js +0 -1
  365. package/dist/contextmenu-DXF5oP5y.mjs +0 -125
  366. package/dist/contextmenu-G8dHbC6a.mjs +0 -125
  367. package/dist/contextmenu-dn3Ukic5.js +0 -1
  368. package/dist/copyMenuConfig-D4UkBIM8.js +0 -1
  369. package/dist/copyMenuConfig-xDGZfU8V.mjs +0 -4
  370. package/dist/copyMenuConfig.vue_vue_type_script_setup_true_lang-FLv8yK2X.mjs +0 -85
  371. package/dist/copyMenuConfig.vue_vue_type_script_setup_true_lang-V8-WSJik.js +0 -1
  372. package/dist/copySystem-BF-xIg-_.mjs +0 -4
  373. package/dist/copySystem-xq7dH1YB.js +0 -1
  374. package/dist/copySystem.vue_vue_type_script_setup_true_lang-GaIRgmVX.mjs +0 -78
  375. package/dist/copySystem.vue_vue_type_script_setup_true_lang-SoZ__LDi.js +0 -1
  376. package/dist/defaults-B4P_y7Bf.js +0 -1
  377. package/dist/defaults-DJz8qQkT.mjs +0 -86
  378. package/dist/dialog-37QHD09D.mjs +0 -10
  379. package/dist/dialog-BpY5TPcI.mjs +0 -365
  380. package/dist/dialog-BpY5TPcI.mjs.gz +0 -0
  381. package/dist/dialog-CaHgL7Un.js +0 -1
  382. package/dist/dialog-CwvjHdQG.mjs +0 -4
  383. package/dist/dialog-D2L8YrGi.mjs +0 -4
  384. package/dist/dialog-DQP53khI.mjs +0 -359
  385. package/dist/dialog-DQP53khI.mjs.gz +0 -0
  386. package/dist/dialog-DmI_6sfg.js +0 -1
  387. package/dist/dialog-DxBOYlwo.js +0 -1
  388. package/dist/dialog-TFJ52Qpk.js +0 -1
  389. package/dist/dialog-tEGpWR17.js +0 -1
  390. package/dist/dialog.vue_vue_type_script_setup_true_name_dataAuthDialog_lang-B34-zi76.mjs +0 -220
  391. package/dist/dialog.vue_vue_type_script_setup_true_name_dataAuthDialog_lang-lxzOpAYW.js +0 -1
  392. package/dist/dialog.vue_vue_type_script_setup_true_name_systemMenuDialog_lang-B0bvaMOH.mjs +0 -694
  393. package/dist/dialog.vue_vue_type_script_setup_true_name_systemMenuDialog_lang-B0bvaMOH.mjs.gz +0 -0
  394. package/dist/dialog.vue_vue_type_script_setup_true_name_systemMenuDialog_lang-BQD9kbev.js +0 -1
  395. package/dist/dialog.vue_vue_type_script_setup_true_name_systemMenuDialog_lang-BQD9kbev.js.gz +0 -0
  396. package/dist/dictDialog-3cu_MIw2.mjs +0 -4
  397. package/dist/dictDialog-B8qvjYMR.js +0 -1
  398. package/dist/dictDialog.vue_vue_type_script_setup_true_name_dictDialog_lang-B_TRW06X.mjs +0 -154
  399. package/dist/dictDialog.vue_vue_type_script_setup_true_name_dictDialog_lang-CFgSsWwx.js +0 -1
  400. package/dist/dictItemDialog-C814-nYt.mjs +0 -4
  401. package/dist/dictItemDialog-CbQHgU4j.js +0 -1
  402. package/dist/dictItemDialog.vue_vue_type_script_setup_true_lang-D3F7S3JJ.mjs +0 -231
  403. package/dist/dictItemDialog.vue_vue_type_script_setup_true_lang-TQlHxUM-.js +0 -1
  404. package/dist/favicon.ico +0 -0
  405. package/dist/formConfig-BrQO-6ag.js +0 -1
  406. package/dist/formConfig-BrQO-6ag.js.gz +0 -0
  407. package/dist/formConfig-Da6lJvqs.mjs +0 -592
  408. package/dist/formConfig-Da6lJvqs.mjs.gz +0 -0
  409. package/dist/header-BUGTGlM9.js +0 -1
  410. package/dist/header-CFJ4tqWS.mjs +0 -28
  411. package/dist/horizontal-CLwlN8o9.js +0 -1
  412. package/dist/horizontal-Dzn2yYYS.mjs +0 -151
  413. package/dist/hsAttrBtn-CaLLjqar.mjs +0 -4
  414. package/dist/hsAttrBtn-D10_Vo1Y.js +0 -1
  415. package/dist/hsAttrBtn.vue_vue_type_script_setup_true_lang-Cs9czCiW.js +0 -1
  416. package/dist/hsAttrBtn.vue_vue_type_script_setup_true_lang-D1A8kxol.mjs +0 -128
  417. package/dist/hsAttrForm-CdfSj5gE.js +0 -1
  418. package/dist/hsAttrForm-DlqsWDq4.mjs +0 -4
  419. package/dist/hsAttrForm.vue_vue_type_script_setup_true_lang-C6HgKEYX.mjs +0 -439
  420. package/dist/hsAttrForm.vue_vue_type_script_setup_true_lang-C6HgKEYX.mjs.gz +0 -0
  421. package/dist/hsAttrForm.vue_vue_type_script_setup_true_lang-JuStRpaX.js +0 -1
  422. package/dist/hsBtnConfigList-CDwPquFa.js +0 -1
  423. package/dist/hsBtnConfigList-Dq-UMlm2.mjs +0 -117
  424. package/dist/hsBtnItemConfig-CfftPcSD.mjs +0 -4
  425. package/dist/hsBtnItemConfig-CtQqNBlK.js +0 -1
  426. package/dist/hsBtnItemConfig.vue_vue_type_script_setup_true_lang-BnotrC93.mjs +0 -147
  427. package/dist/hsBtnItemConfig.vue_vue_type_script_setup_true_lang-DnaWvq-b.js +0 -1
  428. package/dist/hsBtnPanel-BkxSKDwq.mjs +0 -4
  429. package/dist/hsBtnPanel-CcMkdorr.js +0 -1
  430. package/dist/hsBtnPanel.vue_vue_type_script_setup_true_name_formPanel_lang-DcgVBDqw.js +0 -1
  431. package/dist/hsBtnPanel.vue_vue_type_script_setup_true_name_formPanel_lang-DjuZNPz0.mjs +0 -67
  432. package/dist/hsCheckbox-BKa_El3s.js +0 -1
  433. package/dist/hsCheckbox-CalDndlZ.mjs +0 -4
  434. package/dist/hsCheckbox.vue_vue_type_script_setup_true_lang-Dh-lqGjq.js +0 -1
  435. package/dist/hsCheckbox.vue_vue_type_script_setup_true_lang-XCUyHi8X.mjs +0 -28
  436. package/dist/hsExpand-CQVFjccm.js +0 -1
  437. package/dist/hsExpand-DzturGzS.mjs +0 -4
  438. package/dist/hsExpand.vue_vue_type_script_setup_true_lang-2PgtnOyZ.js +0 -1
  439. package/dist/hsExpand.vue_vue_type_script_setup_true_lang-ByI3lkrY.mjs +0 -285
  440. package/dist/hsFormConfig-B-0-7IG-.js +0 -1
  441. package/dist/hsFormConfig-CiC1xqCS.mjs +0 -207
  442. package/dist/hsFormConfigList-D-zBHhco.mjs +0 -414
  443. package/dist/hsFormConfigList-D-zBHhco.mjs.gz +0 -0
  444. package/dist/hsFormConfigList-IppfulsQ.js +0 -1
  445. package/dist/hsFormPanel-DOSHi6SL.js +0 -1
  446. package/dist/hsFormPanel-DrMHz5BG.mjs +0 -238
  447. package/dist/hsFormPanel-DrMHz5BG.mjs.gz +0 -0
  448. package/dist/hsFormParse--MpZBB1o.js +0 -1
  449. package/dist/hsFormParse-Dzmv1LRL.mjs +0 -4
  450. package/dist/hsFormParse.vue_vue_type_script_setup_true_lang-C3QZXAnq.mjs +0 -242
  451. package/dist/hsFormParse.vue_vue_type_script_setup_true_lang-DNdAJZ-0.js +0 -1
  452. package/dist/hsPanelItem-Cr_zx3zB.mjs +0 -4
  453. package/dist/hsPanelItem-L0cRzdZ9.js +0 -1
  454. package/dist/hsPanelItem.vue_vue_type_script_setup_true_name_panelItem_lang-B8S5p2OU.mjs +0 -86
  455. package/dist/hsPanelItem.vue_vue_type_script_setup_true_name_panelItem_lang-CHRnArdb.js +0 -1
  456. package/dist/iframes-CWdXFiYU.mjs +0 -122
  457. package/dist/iframes-DnAW1ZV2.js +0 -1
  458. package/dist/index copy-C9pm4wwS.mjs +0 -134
  459. package/dist/index copy-CltelxDj.js +0 -1
  460. package/dist/index copy-NI5bkeov.mjs +0 -69
  461. package/dist/index copy-YVeg4Qpy.js +0 -1
  462. package/dist/index--90UOcEE.js +0 -1
  463. package/dist/index-4ncpQ4eO.js +0 -1
  464. package/dist/index-5_S5X2B8.mjs +0 -73
  465. package/dist/index-7U-cYtGo.js +0 -1
  466. package/dist/index-86EBVGGo.js +0 -1
  467. package/dist/index-B0-7gN8V.mjs +0 -131
  468. package/dist/index-B3h4_c_0.js +0 -1
  469. package/dist/index-B4RbAHHA.js +0 -1
  470. package/dist/index-B5B5bCFQ.js +0 -1
  471. package/dist/index-B8Zlivb4.mjs +0 -152
  472. package/dist/index-BIgnSPCb.js +0 -1
  473. package/dist/index-BIj1BEfS.mjs +0 -89
  474. package/dist/index-BNdkz6Oj.mjs +0 -65
  475. package/dist/index-BTBnzpJl.mjs +0 -331
  476. package/dist/index-BTBnzpJl.mjs.gz +0 -0
  477. package/dist/index-BTrzbnh7.mjs +0 -10
  478. package/dist/index-BX1VwR6q.mjs +0 -254
  479. package/dist/index-B_aWJfJG.mjs +0 -50
  480. package/dist/index-Be14owUC.js +0 -110
  481. package/dist/index-Be14owUC.js.gz +0 -0
  482. package/dist/index-BhMp70XH.mjs +0 -94
  483. package/dist/index-BiFq1jSn.mjs +0 -4
  484. package/dist/index-BiXUzbUN.js +0 -1
  485. package/dist/index-BiXUzbUN.js.gz +0 -0
  486. package/dist/index-BoxE6g4D.mjs +0 -22
  487. package/dist/index-BsmMkmmb.mjs +0 -30
  488. package/dist/index-BvRPdQjQ.js +0 -1
  489. package/dist/index-Bw3xRnWj.js +0 -1
  490. package/dist/index-By4ZqBp1.mjs +0 -262
  491. package/dist/index-BziqiZMe.js +0 -1
  492. package/dist/index-BziqiZMe.js.gz +0 -0
  493. package/dist/index-C1yO8AeN.js +0 -1
  494. package/dist/index-C4QLSPnE.js +0 -1
  495. package/dist/index-C4QLSPnE.js.gz +0 -0
  496. package/dist/index-C4jaoMOL.js +0 -1
  497. package/dist/index-CBtvQ2Qa.js +0 -1
  498. package/dist/index-CDFo3k6H.mjs +0 -47
  499. package/dist/index-CEWu6Vth.js +0 -1
  500. package/dist/index-CH6aNW1H.js +0 -1
  501. package/dist/index-CNqCyebM.mjs +0 -67
  502. package/dist/index-COoEtFch.js +0 -1
  503. package/dist/index-CSFKdCgt.js +0 -1
  504. package/dist/index-CSohO9Sf.js +0 -1
  505. package/dist/index-CUE6cOFE.mjs +0 -76
  506. package/dist/index-CVr6ThwO.mjs +0 -14
  507. package/dist/index-CYwUku7v.js +0 -1
  508. package/dist/index-C_Jh3o-z.mjs +0 -2208
  509. package/dist/index-C_Jh3o-z.mjs.gz +0 -0
  510. package/dist/index-CaroRQE3.mjs +0 -258272
  511. package/dist/index-CaroRQE3.mjs.gz +0 -0
  512. package/dist/index-CbCppT2z.js +0 -1
  513. package/dist/index-CbgKih92.js +0 -1
  514. package/dist/index-Cevc_s57.js +0 -1
  515. package/dist/index-CpHkFJpe.mjs +0 -4
  516. package/dist/index-CpeyiMej.js +0 -1
  517. package/dist/index-CtQOzn7W.mjs +0 -285
  518. package/dist/index-CvaGWWCb.mjs +0 -172
  519. package/dist/index-D-ZR2ZQw.js +0 -1
  520. package/dist/index-D-rui3Hs.mjs +0 -133
  521. package/dist/index-D6stlvgD.mjs +0 -10
  522. package/dist/index-D858MrDM.mjs +0 -173
  523. package/dist/index-DCgZAOFA.js +0 -1
  524. package/dist/index-DEykAVeO.js +0 -1
  525. package/dist/index-DHHcO6BG.js +0 -1
  526. package/dist/index-DHxDaTXn.js +0 -1
  527. package/dist/index-DIMVIQkh.mjs +0 -4
  528. package/dist/index-DT3c6iM1.mjs +0 -49
  529. package/dist/index-DUmz-a1e.js +0 -1
  530. package/dist/index-DXyhVGaL.mjs +0 -95
  531. package/dist/index-DZ_UFJE2.mjs +0 -43
  532. package/dist/index-Db2jthwJ.js +0 -1
  533. package/dist/index-DhDED1vM.mjs +0 -73
  534. package/dist/index-Dkkn5hYp.mjs +0 -213
  535. package/dist/index-Dqazj9UX.js +0 -1
  536. package/dist/index-DqikGsbw.mjs +0 -1009
  537. package/dist/index-DqikGsbw.mjs.gz +0 -0
  538. package/dist/index-DrCxI2-S.js +0 -1
  539. package/dist/index-DrpmyDit.js +0 -1
  540. package/dist/index-Du7wnh89.js +0 -1
  541. package/dist/index-DuMZar1l.mjs +0 -51
  542. package/dist/index-DvVF79rV.mjs +0 -65
  543. package/dist/index-Dymo6jYe.mjs +0 -119
  544. package/dist/index-EKgsCiWF.js +0 -1
  545. package/dist/index-GyR4BRDa.mjs +0 -4
  546. package/dist/index-I4czMgZi.js +0 -1
  547. package/dist/index-JwYvAnQ3.js +0 -1
  548. package/dist/index-PCI3lWru.mjs +0 -38
  549. package/dist/index-Pkhj9M-e.mjs +0 -403
  550. package/dist/index-Pkhj9M-e.mjs.gz +0 -0
  551. package/dist/index-Qnu0cq8V.mjs +0 -23
  552. package/dist/index-Z83-84L3.js +0 -1
  553. package/dist/index-feq0FF6W.mjs +0 -23
  554. package/dist/index-g_BDa62N.mjs +0 -19
  555. package/dist/index-iXgZKYFt.mjs +0 -200
  556. package/dist/index-iyQdB62I.js +0 -1
  557. package/dist/index-jJSGIw6e.mjs +0 -4
  558. package/dist/index-lnqZa96W.js +0 -1
  559. package/dist/index-nfmpb6Xb.js +0 -1
  560. package/dist/index-qaA0ntg_.mjs +0 -5403
  561. package/dist/index-qaA0ntg_.mjs.gz +0 -0
  562. package/dist/index.vue_vue_type_script_setup_true_lang-Bo-cWJ2h.mjs +0 -103
  563. package/dist/index.vue_vue_type_script_setup_true_lang-C6kBeVt9.js +0 -1
  564. package/dist/index.vue_vue_type_script_setup_true_lang-CN3R-WyE.mjs +0 -194
  565. package/dist/index.vue_vue_type_script_setup_true_lang-CV51d0Z-.mjs +0 -97
  566. package/dist/index.vue_vue_type_script_setup_true_lang-CzxOI00n.mjs +0 -267
  567. package/dist/index.vue_vue_type_script_setup_true_lang-CzxOI00n.mjs.gz +0 -0
  568. package/dist/index.vue_vue_type_script_setup_true_lang-DF41VMpg.js +0 -1
  569. package/dist/index.vue_vue_type_script_setup_true_lang-ZElmGMCs.js +0 -1
  570. package/dist/index.vue_vue_type_script_setup_true_lang-s332W7ju.js +0 -1
  571. package/dist/index.vue_vue_type_script_setup_true_name_iconSelector_lang-BdxXuNuU.js +0 -1
  572. package/dist/index.vue_vue_type_script_setup_true_name_iconSelector_lang-iB7n4gFb.mjs +0 -288
  573. package/dist/index.vue_vue_type_script_setup_true_name_iconSelector_lang-iB7n4gFb.mjs.gz +0 -0
  574. package/dist/lib-generate-test-usersig.min.js +0 -2
  575. package/dist/lib-generate-test-usersig.min.js.gz +0 -0
  576. package/dist/link-CgTDXGDS.mjs +0 -63
  577. package/dist/link-D2FDMeja.js +0 -1
  578. package/dist/list-5DKapoIg.mjs +0 -85
  579. package/dist/list-BvqQwxfl.js +0 -1
  580. package/dist/logo-mini-BQ9BrQ1U.mjs +0 -4
  581. package/dist/logo-mini-DwRdfcE7.js +0 -1
  582. package/dist/main-CTH2j1nH.js +0 -1
  583. package/dist/main-DYH0PjBf.mjs +0 -72
  584. package/dist/mobile-ByMcRIck.mjs +0 -115
  585. package/dist/mobile-Ct2wYxBA.js +0 -1
  586. package/dist/parent-DuAzBa1S.mjs +0 -131
  587. package/dist/parent-nV16iTuQ.js +0 -1
  588. package/dist/popup-DoFnyyCj.mjs +0 -4
  589. package/dist/popup-V67deXeJ.js +0 -1
  590. package/dist/popup.vue_vue_type_script_setup_true_name_replaceRules_lang-DQDiTEgt.mjs +0 -89
  591. package/dist/popup.vue_vue_type_script_setup_true_name_replaceRules_lang-E-ChMCSs.js +0 -1
  592. package/dist/roleItem-BlcLJSJN.js +0 -1
  593. package/dist/roleItem-CbNpIWj7.mjs +0 -103
  594. package/dist/saveForm-BzO1nXB7.js +0 -1
  595. package/dist/saveForm-CPBMTFy6.mjs +0 -160
  596. package/dist/scan-BcgmKsTD.js +0 -1
  597. package/dist/scan-BcgmKsTD.js.gz +0 -0
  598. package/dist/scan-DTqXY1TN.mjs +0 -945
  599. package/dist/scan-DTqXY1TN.mjs.gz +0 -0
  600. package/dist/search-B-EDB-Tc.mjs +0 -114
  601. package/dist/search-B9FiliR8.js +0 -1
  602. package/dist/selectConfig-C_ir8n8r.js +0 -1
  603. package/dist/selectConfig-DAkXAD_Y.mjs +0 -546
  604. package/dist/selectConfig-DAkXAD_Y.mjs.gz +0 -0
  605. package/dist/shortcutList-BXBGQdNn.mjs +0 -76
  606. package/dist/shortcutList-WSi4lUlm.js +0 -1
  607. package/dist/style.css +0 -1
  608. package/dist/style.css.gz +0 -0
  609. package/dist/subItem-CZYXr8hi.mjs +0 -77
  610. package/dist/subItem-D2t5Fs0x.js +0 -1
  611. package/dist/tagsView-BQQMtEO2.mjs +0 -2695
  612. package/dist/tagsView-BQQMtEO2.mjs.gz +0 -0
  613. package/dist/tagsView-D7WaG5Ak.js +0 -8
  614. package/dist/tagsView-D7WaG5Ak.js.gz +0 -0
  615. package/dist/transverse-BQN-Si9F.mjs +0 -65
  616. package/dist/transverse-C_saqvLc.js +0 -1
  617. package/dist/types/components/business/bcBox/bcBox.vue.d.ts +0 -66
  618. package/dist/types/components/business/bcBreadcrumb/bcBreadcrumb.vue.d.ts +0 -23
  619. package/dist/types/components/business/bcForm/baseForm.vue.d.ts +0 -273
  620. package/dist/types/components/business/bcForm/bcForm.vue.d.ts +0 -42
  621. package/dist/types/components/business/bcForm/useGuide.d.ts +0 -564
  622. package/dist/types/components/business/bcSystemAuth/components/data.vue.d.ts +0 -3
  623. package/dist/types/components/business/bcSystemAuth/components/dict.vue.d.ts +0 -3
  624. package/dist/types/components/business/bcSystemAuth/components/fastSet/popup.vue.d.ts +0 -17
  625. package/dist/types/components/business/bcSystemAuth/components/field.vue.d.ts +0 -3
  626. package/dist/types/components/business/bcSystemAuth/components/form.vue.d.ts +0 -13
  627. package/dist/types/components/business/bcSystemAuth/components/selectAll/index.vue.d.ts +0 -5
  628. package/dist/types/components/business/bcSystemAuth/components/table.vue.d.ts +0 -13
  629. package/dist/types/components/business/bcSystemAuth/components/widget/btns.vue.d.ts +0 -15
  630. package/dist/types/components/business/bcSystemAuth/components/widget/form.vue.d.ts +0 -15
  631. package/dist/types/components/business/bcSystemAuth/components/widget/tab.vue.d.ts +0 -45
  632. package/dist/types/components/business/bcSystemAuth/components/widget/tables.vue.d.ts +0 -15
  633. package/dist/types/components/business/bcSystemAuth/components/widget/tablesWraper.vue.d.ts +0 -15
  634. package/dist/types/components/business/bcSystemAuth/index.d.ts +0 -3
  635. package/dist/types/components/business/bcSystemAuth/index.vue.d.ts +0 -26
  636. package/dist/types/components/business/bcSystemAuth/type.d.ts +0 -42
  637. package/dist/types/components/business/bcSystemAuth/useAuth.d.ts +0 -28
  638. package/dist/types/components/business/bcSystemField/components/field.vue.d.ts +0 -3
  639. package/dist/types/components/business/bcSystemField/components/form.vue.d.ts +0 -13
  640. package/dist/types/components/business/bcSystemField/components/selectAll/index.vue.d.ts +0 -5
  641. package/dist/types/components/business/bcSystemField/components/table.vue.d.ts +0 -13
  642. package/dist/types/components/business/bcSystemField/components/widget/form.vue.d.ts +0 -15
  643. package/dist/types/components/business/bcSystemField/components/widget/tab.vue.d.ts +0 -45
  644. package/dist/types/components/business/bcSystemField/components/widget/tables.vue.d.ts +0 -15
  645. package/dist/types/components/business/bcSystemField/components/widget/tablesWraper.vue.d.ts +0 -15
  646. package/dist/types/components/business/bcSystemField/index.d.ts +0 -3
  647. package/dist/types/components/business/bcSystemField/index.vue.d.ts +0 -16
  648. package/dist/types/components/business/bcSystemField/useAuth.d.ts +0 -16
  649. package/dist/types/components/business/bcTable/bcFormTable.vue.d.ts +0 -142
  650. package/dist/types/components/business/bcTable/bcTable.vue.d.ts +0 -51
  651. package/dist/types/components/business/bcTable/components/btn/btn.vue.d.ts +0 -77
  652. package/dist/types/components/business/bcTable/components/popup/index.d.ts +0 -3
  653. package/dist/types/components/business/bcTable/components/query/components/sortForm/sortForm.vue.d.ts +0 -23
  654. package/dist/types/components/business/bcTable/components/query/drag.vue.d.ts +0 -244
  655. package/dist/types/components/business/bcTable/components/query/query.vue.d.ts +0 -249
  656. package/dist/types/components/business/bcTable/components/table/colgroup.vue.d.ts +0 -28
  657. package/dist/types/components/business/bcTable/components/table/column.vue.d.ts +0 -35
  658. package/dist/types/components/business/bcTable/components/table/components/sortColumn/sortColumn.vue.d.ts +0 -25
  659. package/dist/types/components/business/bcTable/components/table/table.vue.d.ts +0 -67
  660. package/dist/types/components/business/bcTable/components/table/useTableHeight.d.ts +0 -25
  661. package/dist/types/components/business/bcTable/utils/useFormTableHeight.d.ts +0 -20
  662. package/dist/types/components/business/bcVisual/components/setting/extendItem.vue.d.ts +0 -13
  663. package/dist/types/components/business/bcVisual/components/setting/setting.vue.d.ts +0 -3
  664. package/dist/types/components/business/bcVisual/components/table/table.vue.d.ts +0 -6
  665. package/dist/types/components/business/bcVisual/components/updateName/popup.vue.d.ts +0 -17
  666. package/dist/types/components/business/bcVisual/components/updateSql/addCondition.vue.d.ts +0 -23
  667. package/dist/types/components/business/bcVisual/components/updateSql/nodeTree/index.vue.d.ts +0 -21
  668. package/dist/types/components/business/bcVisual/components/updateSql/nodeTree/nodeTree.vue.d.ts +0 -19
  669. package/dist/types/components/business/bcVisual/components/updateSql/popup.vue.d.ts +0 -17
  670. package/dist/types/plugins/index.d.ts +0 -33
  671. package/dist/types/types/system.d.ts +0 -14
  672. package/dist/types/utils/authFunction.d.ts +0 -18
  673. package/dist/types/utils/build.d.ts +0 -11
  674. package/dist/types/utils/commonFunction.d.ts +0 -29
  675. package/dist/types/utils/file.d.ts +0 -6
  676. package/dist/types/utils/getStyleSheets.d.ts +0 -11
  677. package/dist/types/utils/index.d.ts +0 -29
  678. package/dist/types/utils/lodash.d.ts +0 -3
  679. package/dist/types/utils/request/index.d.ts +0 -6
  680. package/dist/types/utils/request/request.d.ts +0 -7
  681. package/dist/types/utils/setIconfont.d.ts +0 -11
  682. package/dist/types/utils/showMessage.d.ts +0 -6
  683. package/dist/types/utils/showMessageBox.d.ts +0 -6
  684. package/dist/types/utils/showNotification.d.ts +0 -6
  685. package/dist/useConfigInfo-2zEYLSSs.js +0 -1
  686. package/dist/useConfigInfo-PTkkdx-l.mjs +0 -19
  687. package/dist/user-4AkMtJNx.mjs +0 -246
  688. package/dist/user-Dv0yBcpt.js +0 -1
  689. package/dist/userNews-Bkj38E0W.js +0 -1
  690. package/dist/userNews-Kzyqi5O2.mjs +0 -72
  691. package/dist/userSelect-C40-eSjE.mjs +0 -4
  692. package/dist/userSelect-QMToHb6f.js +0 -1
  693. package/dist/userSelect.vue_vue_type_script_setup_true_lang-DAOTR3MQ.js +0 -1
  694. package/dist/userSelect.vue_vue_type_script_setup_true_lang-_aKlFytR.mjs +0 -100
  695. package/dist/vertical-B9_KiZof.js +0 -1
  696. package/dist/vertical-CU-DZItF.mjs +0 -133
  697. /package/dist/types/{components → src/components}/business/bcSystemAuth/components/fastSet/index.d.ts +0 -0
  698. /package/dist/types/{components → src/components}/business/bcSystemAuth/components/index.d.ts +0 -0
  699. /package/dist/types/{components → src/components}/business/bcSystemAuth/components/widget/index.d.ts +0 -0
  700. /package/dist/types/{components → src/components}/business/bcSystemField/components/index.d.ts +0 -0
  701. /package/dist/types/{components → src/components}/business/bcSystemField/components/widget/index.d.ts +0 -0
  702. /package/dist/types/{components → src/components}/business/bcTable/components/index.d.ts +0 -0
  703. /package/dist/types/{components → src/components}/business/bcTable/components/query/components/sortForm/index.d.ts +0 -0
  704. /package/dist/types/{components → src/components}/business/bcTable/components/table/components/sortColumn/index.d.ts +0 -0
  705. /package/dist/types/{components → src/components}/business/bcVisual/components/updateName/index.d.ts +0 -0
  706. /package/dist/types/{components → src/components}/business/bcVisual/type.d.ts +0 -0
  707. /package/dist/types/{types → src/types}/formItem/button.d.ts +0 -0
  708. /package/dist/types/{types → src/types}/formItem/index.d.ts +0 -0
  709. /package/dist/types/{types → src/types}/index.d.ts +0 -0
  710. /package/dist/types/{utils → src/utils}/cfprint.d.ts +0 -0
  711. /package/dist/types/{utils → src/utils}/crypto.d.ts +0 -0
  712. /package/dist/types/{utils → src/utils}/device_info.d.ts +0 -0
  713. /package/dist/types/{utils → src/utils}/formatTime.d.ts +0 -0
  714. /package/dist/types/{utils → src/utils}/request/interceptors/request/index.d.ts +0 -0
  715. /package/dist/types/{utils → src/utils}/request/interceptors/response/index.d.ts +0 -0
  716. /package/dist/types/{utils → src/utils}/shortcutList.d.ts +0 -0
  717. /package/dist/types/{utils → src/utils}/theme.d.ts +0 -0
  718. /package/dist/types/{utils → src/utils}/toolsValidate.d.ts +0 -0
  719. /package/dist/types/{utils → src/utils}/update.d.ts +0 -0
  720. /package/dist/types/{utils → src/utils}/watermark.d.ts +0 -0
@@ -1,2208 +0,0 @@
1
- import { createElementBlock, openBlock, createCommentVNode, createElementVNode, withDirectives, normalizeStyle, vShow, normalizeClass, toDisplayString, defineComponent, ref, onMounted, toRefs, reactive, resolveComponent, createVNode, withCtx, unref, createTextVNode } from "vue";
2
- import { _ as _export_sfc, T as systemStore, b as ElMessage, U as useFileController } from "./index-CaroRQE3.mjs";
3
- const Exif = {};
4
- Exif.getData = (img) => new Promise((reslove, reject) => {
5
- let obj = {};
6
- getImageData(img).then((data) => {
7
- obj.arrayBuffer = data;
8
- try {
9
- obj.orientation = getOrientation(data);
10
- } catch {
11
- obj.orientation = -1;
12
- }
13
- reslove(obj);
14
- }).catch((error2) => {
15
- reject(error2);
16
- });
17
- });
18
- function getImageData(img) {
19
- let data = null;
20
- return new Promise((reslove, reject) => {
21
- if (img.src) {
22
- if (/^data\:/i.test(img.src)) {
23
- data = base64ToArrayBuffer(img.src);
24
- reslove(data);
25
- } else if (/^blob\:/i.test(img.src)) {
26
- var fileReader = new FileReader();
27
- fileReader.onload = function(e) {
28
- data = e.target.result;
29
- reslove(data);
30
- };
31
- objectURLToBlob(img.src, function(blob) {
32
- fileReader.readAsArrayBuffer(blob);
33
- });
34
- } else {
35
- var http = new XMLHttpRequest();
36
- http.onload = function() {
37
- if (this.status == 200 || this.status === 0) {
38
- data = http.response;
39
- reslove(data);
40
- } else {
41
- throw "Could not load image";
42
- }
43
- http = null;
44
- };
45
- http.open("GET", img.src, true);
46
- http.responseType = "arraybuffer";
47
- http.send(null);
48
- }
49
- } else {
50
- reject("img error");
51
- }
52
- });
53
- }
54
- function objectURLToBlob(url, callback) {
55
- var http = new XMLHttpRequest();
56
- http.open("GET", url, true);
57
- http.responseType = "blob";
58
- http.onload = function(e) {
59
- if (this.status == 200 || this.status === 0) {
60
- callback(this.response);
61
- }
62
- };
63
- http.send();
64
- }
65
- function base64ToArrayBuffer(base64, contentType) {
66
- contentType = contentType || base64.match(/^data\:([^\;]+)\;base64,/mi)[1] || "";
67
- base64 = base64.replace(/^data\:([^\;]+)\;base64,/gmi, "");
68
- var binary = atob(base64);
69
- var len = binary.length % 2 == 0 ? binary.length : binary.length + 1;
70
- var buffer = new ArrayBuffer(len);
71
- var view = new Uint16Array(buffer);
72
- for (var i = 0; i < len; i++) {
73
- view[i] = binary.charCodeAt(i);
74
- }
75
- return buffer;
76
- }
77
- function getStringFromCharCode(dataView, start, length) {
78
- var str = "";
79
- var i;
80
- for (i = start, length += start; i < length; i++) {
81
- str += String.fromCharCode(dataView.getUint8(i));
82
- }
83
- return str;
84
- }
85
- function getOrientation(arrayBuffer) {
86
- var dataView = new DataView(arrayBuffer);
87
- var length = dataView.byteLength;
88
- var orientation;
89
- var exifIDCode;
90
- var tiffOffset;
91
- var firstIFDOffset;
92
- var littleEndian;
93
- var endianness;
94
- var app1Start;
95
- var ifdStart;
96
- var offset;
97
- var i;
98
- if (dataView.getUint8(0) === 255 && dataView.getUint8(1) === 216) {
99
- offset = 2;
100
- while (offset < length) {
101
- if (dataView.getUint8(offset) === 255 && dataView.getUint8(offset + 1) === 225) {
102
- app1Start = offset;
103
- break;
104
- }
105
- offset++;
106
- }
107
- }
108
- if (app1Start) {
109
- exifIDCode = app1Start + 4;
110
- tiffOffset = app1Start + 10;
111
- if (getStringFromCharCode(dataView, exifIDCode, 4) === "Exif") {
112
- endianness = dataView.getUint16(tiffOffset);
113
- littleEndian = endianness === 18761;
114
- if (littleEndian || endianness === 19789) {
115
- if (dataView.getUint16(tiffOffset + 2, littleEndian) === 42) {
116
- firstIFDOffset = dataView.getUint32(tiffOffset + 4, littleEndian);
117
- if (firstIFDOffset >= 8) {
118
- ifdStart = tiffOffset + firstIFDOffset;
119
- }
120
- }
121
- }
122
- }
123
- }
124
- if (ifdStart) {
125
- length = dataView.getUint16(ifdStart, littleEndian);
126
- for (i = 0; i < length; i++) {
127
- offset = ifdStart + i * 12 + 2;
128
- if (dataView.getUint16(offset, littleEndian) === 274) {
129
- offset += 8;
130
- orientation = dataView.getUint16(offset, littleEndian);
131
- break;
132
- }
133
- }
134
- }
135
- return orientation;
136
- }
137
- const _sfc_main$1 = {
138
- data: function() {
139
- return {
140
- // 容器高宽
141
- w: 0,
142
- h: 0,
143
- // 图片缩放比例
144
- scale: 1,
145
- // 图片偏移x轴
146
- x: 0,
147
- // 图片偏移y轴
148
- y: 0,
149
- // 图片加载
150
- loading: true,
151
- // 图片真实宽度
152
- trueWidth: 0,
153
- // 图片真实高度
154
- trueHeight: 0,
155
- move: true,
156
- // 移动的x
157
- moveX: 0,
158
- // 移动的y
159
- moveY: 0,
160
- // 开启截图
161
- crop: false,
162
- // 正在截图
163
- cropping: false,
164
- // 裁剪框大小
165
- cropW: 0,
166
- cropH: 0,
167
- cropOldW: 0,
168
- cropOldH: 0,
169
- // 判断是否能够改变
170
- canChangeX: false,
171
- canChangeY: false,
172
- // 改变的基准点
173
- changeCropTypeX: 1,
174
- changeCropTypeY: 1,
175
- // 裁剪框的坐标轴
176
- cropX: 0,
177
- cropY: 0,
178
- cropChangeX: 0,
179
- cropChangeY: 0,
180
- cropOffsertX: 0,
181
- cropOffsertY: 0,
182
- // 支持的滚动事件
183
- support: "",
184
- // 移动端手指缩放
185
- touches: [],
186
- touchNow: false,
187
- // 图片旋转
188
- rotate: 0,
189
- isIos: false,
190
- orientation: 0,
191
- imgs: "",
192
- // 图片缩放系数
193
- coe: 0.2,
194
- // 是否正在多次缩放
195
- scaling: false,
196
- scalingSet: "",
197
- coeStatus: "",
198
- // 控制emit触发频率
199
- isCanShow: true,
200
- // 图片是否等于截图大小
201
- imgIsQqualCrop: false
202
- };
203
- },
204
- props: {
205
- img: {
206
- type: [String, Blob, null, File],
207
- default: ""
208
- },
209
- // 输出图片压缩比
210
- outputSize: {
211
- type: Number,
212
- default: 1
213
- },
214
- outputType: {
215
- type: String,
216
- default: "jpeg"
217
- },
218
- info: {
219
- type: Boolean,
220
- default: true
221
- },
222
- // 是否开启滚轮放大缩小
223
- canScale: {
224
- type: Boolean,
225
- default: true
226
- },
227
- // 是否自成截图框
228
- autoCrop: {
229
- type: Boolean,
230
- default: false
231
- },
232
- autoCropWidth: {
233
- type: [Number, String],
234
- default: 0
235
- },
236
- autoCropHeight: {
237
- type: [Number, String],
238
- default: 0
239
- },
240
- // 是否开启固定宽高比
241
- fixed: {
242
- type: Boolean,
243
- default: false
244
- },
245
- // 宽高比 w/h
246
- fixedNumber: {
247
- type: Array,
248
- default: () => {
249
- return [1, 1];
250
- }
251
- },
252
- // 固定大小 禁止改变截图框大小
253
- fixedBox: {
254
- type: Boolean,
255
- default: false
256
- },
257
- // 输出截图是否缩放
258
- full: {
259
- type: Boolean,
260
- default: false
261
- },
262
- // 是否可以拖动图片
263
- canMove: {
264
- type: Boolean,
265
- default: true
266
- },
267
- // 是否可以拖动截图框
268
- canMoveBox: {
269
- type: Boolean,
270
- default: true
271
- },
272
- // 上传图片按照原始比例显示
273
- original: {
274
- type: Boolean,
275
- default: false
276
- },
277
- // 截图框能否超过图片
278
- centerBox: {
279
- type: Boolean,
280
- default: false
281
- },
282
- // 是否根据dpr输出高清图片
283
- high: {
284
- type: Boolean,
285
- default: true
286
- },
287
- // 截图框展示宽高类型
288
- infoTrue: {
289
- type: Boolean,
290
- default: false
291
- },
292
- // 可以压缩图片宽高 默认不超过200
293
- maxImgSize: {
294
- type: [Number, String],
295
- default: 2e3
296
- },
297
- // 倍数 可渲染当前截图框的n倍 0 - 1000;
298
- enlarge: {
299
- type: [Number, String],
300
- default: 1
301
- },
302
- // 自动预览的固定宽度
303
- preW: {
304
- type: [Number, String],
305
- default: 0
306
- },
307
- /*
308
- 图片布局方式 mode 实现和css背景一样的效果
309
- contain 居中布局 默认不会缩放 保证图片在容器里面 mode: 'contain'
310
- cover 拉伸布局 填充整个容器 mode: 'cover'
311
- 如果仅有一个数值被给定,这个数值将作为宽度值大小,高度值将被设定为auto。 mode: '50px'
312
- 如果有两个数值被给定,第一个将作为宽度值大小,第二个作为高度值大小。 mode: '50px 60px'
313
- */
314
- mode: {
315
- type: String,
316
- default: "contain"
317
- },
318
- //限制最小区域,可传1以上的数字和字符串,限制长宽都是这么大
319
- // 也可以传数组[90,90]
320
- limitMinSize: {
321
- type: [Number, Array, String],
322
- default: () => {
323
- return 10;
324
- },
325
- validator: function(value) {
326
- if (Array.isArray(value)) {
327
- return Number(value[0]) >= 0 && Number(value[1]) >= 0;
328
- } else {
329
- return Number(value) >= 0;
330
- }
331
- }
332
- },
333
- // 导出时,填充背景颜色
334
- fillColor: {
335
- type: String,
336
- default: ""
337
- }
338
- },
339
- computed: {
340
- cropInfo() {
341
- let obj = {};
342
- obj.top = this.cropOffsertY > 21 ? "-21px" : "0px";
343
- obj.width = this.cropW > 0 ? this.cropW : 0;
344
- obj.height = this.cropH > 0 ? this.cropH : 0;
345
- if (this.infoTrue) {
346
- let dpr = 1;
347
- if (this.high && !this.full) {
348
- dpr = window.devicePixelRatio;
349
- }
350
- if (this.enlarge !== 1 & !this.full) {
351
- dpr = Math.abs(Number(this.enlarge));
352
- }
353
- obj.width = obj.width * dpr;
354
- obj.height = obj.height * dpr;
355
- if (this.full) {
356
- obj.width = obj.width / this.scale;
357
- obj.height = obj.height / this.scale;
358
- }
359
- }
360
- obj.width = obj.width.toFixed(0);
361
- obj.height = obj.height.toFixed(0);
362
- return obj;
363
- },
364
- isIE() {
365
- const isIE = !!window.ActiveXObject || "ActiveXObject" in window;
366
- return isIE;
367
- },
368
- passive() {
369
- return this.isIE ? null : {
370
- passive: false
371
- };
372
- }
373
- },
374
- watch: {
375
- // 如果图片改变, 重新布局
376
- img() {
377
- this.checkedImg();
378
- },
379
- imgs(val) {
380
- if (val === "") {
381
- return;
382
- }
383
- this.reload();
384
- },
385
- cropW() {
386
- this.showPreview();
387
- },
388
- cropH() {
389
- this.showPreview();
390
- },
391
- cropOffsertX() {
392
- this.showPreview();
393
- },
394
- cropOffsertY() {
395
- this.showPreview();
396
- },
397
- scale(val, oldVal) {
398
- this.showPreview();
399
- },
400
- x() {
401
- this.showPreview();
402
- },
403
- y() {
404
- this.showPreview();
405
- },
406
- autoCrop(val) {
407
- if (val) {
408
- this.goAutoCrop();
409
- }
410
- },
411
- // 修改了自动截图框
412
- autoCropWidth() {
413
- if (this.autoCrop) {
414
- this.goAutoCrop();
415
- }
416
- },
417
- autoCropHeight() {
418
- if (this.autoCrop) {
419
- this.goAutoCrop();
420
- }
421
- },
422
- mode() {
423
- this.checkedImg();
424
- },
425
- rotate() {
426
- this.showPreview();
427
- if (this.autoCrop) {
428
- this.goAutoCrop(this.cropW, this.cropH);
429
- } else {
430
- if (this.cropW > 0 || this.cropH > 0) {
431
- this.goAutoCrop(this.cropW, this.cropH);
432
- }
433
- }
434
- }
435
- },
436
- methods: {
437
- getVersion(name) {
438
- var arr = navigator.userAgent.split(" ");
439
- var chromeVersion = "";
440
- let result = 0;
441
- const reg = new RegExp(name, "i");
442
- for (var i = 0; i < arr.length; i++) {
443
- if (reg.test(arr[i]))
444
- chromeVersion = arr[i];
445
- }
446
- if (chromeVersion) {
447
- result = chromeVersion.split("/")[1].split(".");
448
- } else {
449
- result = ["0", "0", "0"];
450
- }
451
- return result;
452
- },
453
- checkOrientationImage(img, orientation, width, height) {
454
- if (this.getVersion("chrome")[0] >= 81) {
455
- orientation = -1;
456
- } else {
457
- if (this.getVersion("safari")[0] >= 605) {
458
- const safariVersion = this.getVersion("version");
459
- if (safariVersion[0] > 13 && safariVersion[1] > 1) {
460
- orientation = -1;
461
- }
462
- } else {
463
- const isIos = navigator.userAgent.toLowerCase().match(/cpu iphone os (.*?) like mac os/);
464
- if (isIos) {
465
- let version = isIos[1];
466
- version = version.split("_");
467
- if (version[0] > 13 || version[0] >= 13 && version[1] >= 4) {
468
- orientation = -1;
469
- }
470
- }
471
- }
472
- }
473
- let canvas = document.createElement("canvas");
474
- let ctx = canvas.getContext("2d");
475
- ctx.save();
476
- switch (orientation) {
477
- case 2:
478
- canvas.width = width;
479
- canvas.height = height;
480
- ctx.translate(width, 0);
481
- ctx.scale(-1, 1);
482
- break;
483
- case 3:
484
- canvas.width = width;
485
- canvas.height = height;
486
- ctx.translate(width / 2, height / 2);
487
- ctx.rotate(180 * Math.PI / 180);
488
- ctx.translate(-width / 2, -height / 2);
489
- break;
490
- case 4:
491
- canvas.width = width;
492
- canvas.height = height;
493
- ctx.translate(0, height);
494
- ctx.scale(1, -1);
495
- break;
496
- case 5:
497
- canvas.height = width;
498
- canvas.width = height;
499
- ctx.rotate(0.5 * Math.PI);
500
- ctx.scale(1, -1);
501
- break;
502
- case 6:
503
- canvas.width = height;
504
- canvas.height = width;
505
- ctx.translate(height / 2, width / 2);
506
- ctx.rotate(90 * Math.PI / 180);
507
- ctx.translate(-width / 2, -height / 2);
508
- break;
509
- case 7:
510
- canvas.height = width;
511
- canvas.width = height;
512
- ctx.rotate(0.5 * Math.PI);
513
- ctx.translate(width, -height);
514
- ctx.scale(-1, 1);
515
- break;
516
- case 8:
517
- canvas.height = width;
518
- canvas.width = height;
519
- ctx.translate(height / 2, width / 2);
520
- ctx.rotate(-90 * Math.PI / 180);
521
- ctx.translate(-width / 2, -height / 2);
522
- break;
523
- default:
524
- canvas.width = width;
525
- canvas.height = height;
526
- }
527
- ctx.drawImage(img, 0, 0, width, height);
528
- ctx.restore();
529
- canvas.toBlob(
530
- (blob) => {
531
- let data = URL.createObjectURL(blob);
532
- URL.revokeObjectURL(this.imgs);
533
- this.imgs = data;
534
- },
535
- "image/" + this.outputType,
536
- 1
537
- );
538
- },
539
- // checkout img
540
- checkedImg() {
541
- if (this.img === null || this.img === "") {
542
- this.imgs = "";
543
- this.clearCrop();
544
- return;
545
- }
546
- this.loading = true;
547
- this.scale = 1;
548
- this.rotate = 0;
549
- this.clearCrop();
550
- let img = new Image();
551
- img.onload = () => {
552
- if (this.img === "") {
553
- this.$emit("imgLoad", "error");
554
- this.$emit("img-load", "error");
555
- this.$emit("img-load", new Error("图片不能为空"));
556
- return false;
557
- }
558
- let width = img.width;
559
- let height = img.height;
560
- Exif.getData(img).then((data) => {
561
- this.orientation = data.orientation || 1;
562
- let max = Number(this.maxImgSize);
563
- if (!this.orientation && width < max & height < max) {
564
- this.imgs = this.img;
565
- return;
566
- }
567
- if (width > max) {
568
- height = height / width * max;
569
- width = max;
570
- }
571
- if (height > max) {
572
- width = width / height * max;
573
- height = max;
574
- }
575
- this.checkOrientationImage(img, this.orientation, width, height);
576
- }).catch((error2) => {
577
- this.$emit("img-load", "error");
578
- this.$emit("img-load-error", error2);
579
- });
580
- };
581
- img.onerror = () => {
582
- this.$emit("imgLoad", "error");
583
- this.$emit("img-load", "error");
584
- this.$emit("img-load-error", error);
585
- };
586
- if (this.img.substr(0, 4) !== "data") {
587
- img.crossOrigin = "";
588
- }
589
- if (this.isIE) {
590
- var xhr = new XMLHttpRequest();
591
- xhr.onload = function() {
592
- var url = URL.createObjectURL(this.response);
593
- img.src = url;
594
- };
595
- xhr.open("GET", this.img, true);
596
- xhr.responseType = "blob";
597
- xhr.send();
598
- } else {
599
- img.src = this.img;
600
- }
601
- },
602
- // 当按下鼠标键
603
- startMove(e) {
604
- e.preventDefault();
605
- if (this.move && !this.crop) {
606
- if (!this.canMove) {
607
- return false;
608
- }
609
- this.moveX = ("clientX" in e ? e.clientX : e.touches[0].clientX) - this.x;
610
- this.moveY = ("clientY" in e ? e.clientY : e.touches[0].clientY) - this.y;
611
- if (e.touches) {
612
- window.addEventListener("touchmove", this.moveImg);
613
- window.addEventListener("touchend", this.leaveImg);
614
- if (e.touches.length == 2) {
615
- this.touches = e.touches;
616
- window.addEventListener("touchmove", this.touchScale);
617
- window.addEventListener("touchend", this.cancelTouchScale);
618
- }
619
- } else {
620
- window.addEventListener("mousemove", this.moveImg);
621
- window.addEventListener("mouseup", this.leaveImg);
622
- }
623
- this.$emit("imgMoving", {
624
- moving: true,
625
- axis: this.getImgAxis()
626
- });
627
- this.$emit("img-moving", {
628
- moving: true,
629
- axis: this.getImgAxis()
630
- });
631
- } else {
632
- this.cropping = true;
633
- window.addEventListener("mousemove", this.createCrop);
634
- window.addEventListener("mouseup", this.endCrop);
635
- window.addEventListener("touchmove", this.createCrop);
636
- window.addEventListener("touchend", this.endCrop);
637
- this.cropOffsertX = e.offsetX ? e.offsetX : e.touches[0].pageX - this.$refs.cropper.offsetLeft;
638
- this.cropOffsertY = e.offsetY ? e.offsetY : e.touches[0].pageY - this.$refs.cropper.offsetTop;
639
- this.cropX = "clientX" in e ? e.clientX : e.touches[0].clientX;
640
- this.cropY = "clientY" in e ? e.clientY : e.touches[0].clientY;
641
- this.cropChangeX = this.cropOffsertX;
642
- this.cropChangeY = this.cropOffsertY;
643
- this.cropW = 0;
644
- this.cropH = 0;
645
- }
646
- },
647
- // 移动端缩放
648
- touchScale(e) {
649
- e.preventDefault();
650
- let scale = this.scale;
651
- var oldTouch1 = {
652
- x: this.touches[0].clientX,
653
- y: this.touches[0].clientY
654
- };
655
- var newTouch1 = {
656
- x: e.touches[0].clientX,
657
- y: e.touches[0].clientY
658
- };
659
- var oldTouch2 = {
660
- x: this.touches[1].clientX,
661
- y: this.touches[1].clientY
662
- };
663
- var newTouch2 = {
664
- x: e.touches[1].clientX,
665
- y: e.touches[1].clientY
666
- };
667
- var oldL = Math.sqrt(
668
- Math.pow(oldTouch1.x - oldTouch2.x, 2) + Math.pow(oldTouch1.y - oldTouch2.y, 2)
669
- );
670
- var newL = Math.sqrt(
671
- Math.pow(newTouch1.x - newTouch2.x, 2) + Math.pow(newTouch1.y - newTouch2.y, 2)
672
- );
673
- var cha = newL - oldL;
674
- var coe = 1;
675
- coe = coe / this.trueWidth > coe / this.trueHeight ? coe / this.trueHeight : coe / this.trueWidth;
676
- coe = coe > 0.1 ? 0.1 : coe;
677
- var num = coe * cha;
678
- if (!this.touchNow) {
679
- this.touchNow = true;
680
- if (cha > 0) {
681
- scale += Math.abs(num);
682
- } else if (cha < 0) {
683
- scale > Math.abs(num) ? scale -= Math.abs(num) : scale;
684
- }
685
- this.touches = e.touches;
686
- setTimeout(() => {
687
- this.touchNow = false;
688
- }, 8);
689
- if (!this.checkoutImgAxis(this.x, this.y, scale)) {
690
- return false;
691
- }
692
- this.scale = scale;
693
- }
694
- },
695
- cancelTouchScale(e) {
696
- window.removeEventListener("touchmove", this.touchScale);
697
- },
698
- // 移动图片
699
- moveImg(e) {
700
- e.preventDefault();
701
- if (e.touches && e.touches.length === 2) {
702
- this.touches = e.touches;
703
- window.addEventListener("touchmove", this.touchScale);
704
- window.addEventListener("touchend", this.cancelTouchScale);
705
- window.removeEventListener("touchmove", this.moveImg);
706
- return false;
707
- }
708
- let nowX = "clientX" in e ? e.clientX : e.touches[0].clientX;
709
- let nowY = "clientY" in e ? e.clientY : e.touches[0].clientY;
710
- let changeX, changeY;
711
- changeX = nowX - this.moveX;
712
- changeY = nowY - this.moveY;
713
- this.$nextTick(() => {
714
- if (this.centerBox) {
715
- let axis = this.getImgAxis(changeX, changeY, this.scale);
716
- let cropAxis = this.getCropAxis();
717
- let imgW = this.trueHeight * this.scale;
718
- let imgH = this.trueWidth * this.scale;
719
- let maxLeft, maxTop, maxRight, maxBottom;
720
- switch (this.rotate) {
721
- case 1:
722
- case -1:
723
- case 3:
724
- case -3:
725
- maxLeft = this.cropOffsertX - this.trueWidth * (1 - this.scale) / 2 + (imgW - imgH) / 2;
726
- maxTop = this.cropOffsertY - this.trueHeight * (1 - this.scale) / 2 + (imgH - imgW) / 2;
727
- maxRight = maxLeft - imgW + this.cropW;
728
- maxBottom = maxTop - imgH + this.cropH;
729
- break;
730
- default:
731
- maxLeft = this.cropOffsertX - this.trueWidth * (1 - this.scale) / 2;
732
- maxTop = this.cropOffsertY - this.trueHeight * (1 - this.scale) / 2;
733
- maxRight = maxLeft - imgH + this.cropW;
734
- maxBottom = maxTop - imgW + this.cropH;
735
- break;
736
- }
737
- if (axis.x1 >= cropAxis.x1) {
738
- changeX = maxLeft;
739
- }
740
- if (axis.y1 >= cropAxis.y1) {
741
- changeY = maxTop;
742
- }
743
- if (axis.x2 <= cropAxis.x2) {
744
- changeX = maxRight;
745
- }
746
- if (axis.y2 <= cropAxis.y2) {
747
- changeY = maxBottom;
748
- }
749
- }
750
- this.x = changeX;
751
- this.y = changeY;
752
- this.$emit("imgMoving", {
753
- moving: true,
754
- axis: this.getImgAxis()
755
- });
756
- this.$emit("img-moving", {
757
- moving: true,
758
- axis: this.getImgAxis()
759
- });
760
- });
761
- },
762
- // 移动图片结束
763
- leaveImg(e) {
764
- window.removeEventListener("mousemove", this.moveImg);
765
- window.removeEventListener("touchmove", this.moveImg);
766
- window.removeEventListener("mouseup", this.leaveImg);
767
- window.removeEventListener("touchend", this.leaveImg);
768
- this.$emit("imgMoving", {
769
- moving: false,
770
- axis: this.getImgAxis()
771
- });
772
- this.$emit("img-moving", {
773
- moving: false,
774
- axis: this.getImgAxis()
775
- });
776
- },
777
- // 缩放图片
778
- scaleImg() {
779
- if (this.canScale) {
780
- window.addEventListener(this.support, this.changeSize, this.passive);
781
- }
782
- },
783
- // 移出框
784
- cancelScale() {
785
- if (this.canScale) {
786
- window.removeEventListener(this.support, this.changeSize);
787
- }
788
- },
789
- // 改变大小函数
790
- changeSize(e) {
791
- e.preventDefault();
792
- let scale = this.scale;
793
- var change = e.deltaY || e.wheelDelta;
794
- var isFirefox = navigator.userAgent.indexOf("Firefox");
795
- change = isFirefox > 0 ? change * 30 : change;
796
- if (this.isIE) {
797
- change = -change;
798
- }
799
- var coe = this.coe;
800
- coe = coe / this.trueWidth > coe / this.trueHeight ? coe / this.trueHeight : coe / this.trueWidth;
801
- var num = coe * change;
802
- num < 0 ? scale += Math.abs(num) : scale > Math.abs(num) ? scale -= Math.abs(num) : scale;
803
- let status = num < 0 ? "add" : "reduce";
804
- if (status !== this.coeStatus) {
805
- this.coeStatus = status;
806
- this.coe = 0.2;
807
- }
808
- if (!this.scaling) {
809
- this.scalingSet = setTimeout(() => {
810
- this.scaling = false;
811
- this.coe = this.coe += 0.01;
812
- }, 50);
813
- }
814
- this.scaling = true;
815
- if (!this.checkoutImgAxis(this.x, this.y, scale)) {
816
- return false;
817
- }
818
- this.scale = scale;
819
- },
820
- // 修改图片大小函数
821
- changeScale(num) {
822
- let scale = this.scale;
823
- num = num || 1;
824
- var coe = 20;
825
- coe = coe / this.trueWidth > coe / this.trueHeight ? coe / this.trueHeight : coe / this.trueWidth;
826
- num = num * coe;
827
- num > 0 ? scale += Math.abs(num) : scale > Math.abs(num) ? scale -= Math.abs(num) : scale;
828
- if (!this.checkoutImgAxis(this.x, this.y, scale)) {
829
- return false;
830
- }
831
- this.scale = scale;
832
- },
833
- // 创建截图框
834
- createCrop(e) {
835
- e.preventDefault();
836
- var nowX = "clientX" in e ? e.clientX : e.touches ? e.touches[0].clientX : 0;
837
- var nowY = "clientY" in e ? e.clientY : e.touches ? e.touches[0].clientY : 0;
838
- this.$nextTick(() => {
839
- var fw = nowX - this.cropX;
840
- var fh = nowY - this.cropY;
841
- if (fw > 0) {
842
- this.cropW = fw + this.cropChangeX > this.w ? this.w - this.cropChangeX : fw;
843
- this.cropOffsertX = this.cropChangeX;
844
- } else {
845
- this.cropW = this.w - this.cropChangeX + Math.abs(fw) > this.w ? this.cropChangeX : Math.abs(fw);
846
- this.cropOffsertX = this.cropChangeX + fw > 0 ? this.cropChangeX + fw : 0;
847
- }
848
- if (!this.fixed) {
849
- if (fh > 0) {
850
- this.cropH = fh + this.cropChangeY > this.h ? this.h - this.cropChangeY : fh;
851
- this.cropOffsertY = this.cropChangeY;
852
- } else {
853
- this.cropH = this.h - this.cropChangeY + Math.abs(fh) > this.h ? this.cropChangeY : Math.abs(fh);
854
- this.cropOffsertY = this.cropChangeY + fh > 0 ? this.cropChangeY + fh : 0;
855
- }
856
- } else {
857
- var fixedHeight = this.cropW / this.fixedNumber[0] * this.fixedNumber[1];
858
- if (fixedHeight + this.cropOffsertY > this.h) {
859
- this.cropH = this.h - this.cropOffsertY;
860
- this.cropW = this.cropH / this.fixedNumber[1] * this.fixedNumber[0];
861
- if (fw > 0) {
862
- this.cropOffsertX = this.cropChangeX;
863
- } else {
864
- this.cropOffsertX = this.cropChangeX - this.cropW;
865
- }
866
- } else {
867
- this.cropH = fixedHeight;
868
- }
869
- this.cropOffsertY = this.cropOffsertY;
870
- }
871
- });
872
- },
873
- // 改变截图框大小
874
- changeCropSize(e, w, h, typeW, typeH) {
875
- e.preventDefault();
876
- window.addEventListener("mousemove", this.changeCropNow);
877
- window.addEventListener("mouseup", this.changeCropEnd);
878
- window.addEventListener("touchmove", this.changeCropNow);
879
- window.addEventListener("touchend", this.changeCropEnd);
880
- this.canChangeX = w;
881
- this.canChangeY = h;
882
- this.changeCropTypeX = typeW;
883
- this.changeCropTypeY = typeH;
884
- this.cropX = "clientX" in e ? e.clientX : e.touches[0].clientX;
885
- this.cropY = "clientY" in e ? e.clientY : e.touches[0].clientY;
886
- this.cropOldW = this.cropW;
887
- this.cropOldH = this.cropH;
888
- this.cropChangeX = this.cropOffsertX;
889
- this.cropChangeY = this.cropOffsertY;
890
- if (this.fixed) {
891
- if (this.canChangeX && this.canChangeY) {
892
- this.canChangeY = 0;
893
- }
894
- }
895
- this.$emit("changeCropSize", {
896
- width: this.cropW,
897
- height: this.cropH
898
- });
899
- this.$emit("change-crop-size", {
900
- width: this.cropW,
901
- height: this.cropH
902
- });
903
- },
904
- // 正在改变
905
- changeCropNow(e) {
906
- e.preventDefault();
907
- var nowX = "clientX" in e ? e.clientX : e.touches ? e.touches[0].clientX : 0;
908
- var nowY = "clientY" in e ? e.clientY : e.touches ? e.touches[0].clientY : 0;
909
- let wrapperW = this.w;
910
- let wrapperH = this.h;
911
- let minX = 0;
912
- let minY = 0;
913
- if (this.centerBox) {
914
- let axis = this.getImgAxis();
915
- let imgW = axis.x2;
916
- let imgH = axis.y2;
917
- minX = axis.x1 > 0 ? axis.x1 : 0;
918
- minY = axis.y1 > 0 ? axis.y1 : 0;
919
- if (wrapperW > imgW) {
920
- wrapperW = imgW;
921
- }
922
- if (wrapperH > imgH) {
923
- wrapperH = imgH;
924
- }
925
- }
926
- const [minCropW, minCropH] = this.checkCropLimitSize();
927
- this.$nextTick(() => {
928
- var fw = nowX - this.cropX;
929
- var fh = nowY - this.cropY;
930
- if (this.canChangeX) {
931
- if (this.changeCropTypeX === 1) {
932
- if (this.cropOldW - fw < minCropW) {
933
- this.cropW = minCropW;
934
- this.cropOffsertX = this.cropOldW + this.cropChangeX - minX - minCropW;
935
- } else if (this.cropOldW - fw > 0) {
936
- this.cropW = wrapperW - this.cropChangeX - fw <= wrapperW - minX ? this.cropOldW - fw : this.cropOldW + this.cropChangeX - minX;
937
- this.cropOffsertX = wrapperW - this.cropChangeX - fw <= wrapperW - minX ? this.cropChangeX + fw : minX;
938
- } else {
939
- this.cropW = Math.abs(fw) + this.cropChangeX <= wrapperW ? Math.abs(fw) - this.cropOldW : wrapperW - this.cropOldW - this.cropChangeX;
940
- this.cropOffsertX = this.cropChangeX + this.cropOldW;
941
- }
942
- } else if (this.changeCropTypeX === 2) {
943
- if (this.cropOldW + fw < minCropW) {
944
- this.cropW = minCropW;
945
- } else if (this.cropOldW + fw > 0) {
946
- this.cropW = this.cropOldW + fw + this.cropOffsertX <= wrapperW ? this.cropOldW + fw : wrapperW - this.cropOffsertX;
947
- this.cropOffsertX = this.cropChangeX;
948
- } else {
949
- this.cropW = wrapperW - this.cropChangeX + Math.abs(fw + this.cropOldW) <= wrapperW - minX ? Math.abs(fw + this.cropOldW) : this.cropChangeX - minX;
950
- this.cropOffsertX = wrapperW - this.cropChangeX + Math.abs(fw + this.cropOldW) <= wrapperW - minX ? this.cropChangeX - Math.abs(fw + this.cropOldW) : minX;
951
- }
952
- }
953
- }
954
- if (this.canChangeY) {
955
- if (this.changeCropTypeY === 1) {
956
- if (this.cropOldH - fh < minCropH) {
957
- this.cropH = minCropH;
958
- this.cropOffsertY = this.cropOldH + this.cropChangeY - minY - minCropH;
959
- } else if (this.cropOldH - fh > 0) {
960
- this.cropH = wrapperH - this.cropChangeY - fh <= wrapperH - minY ? this.cropOldH - fh : this.cropOldH + this.cropChangeY - minY;
961
- this.cropOffsertY = wrapperH - this.cropChangeY - fh <= wrapperH - minY ? this.cropChangeY + fh : minY;
962
- } else {
963
- this.cropH = Math.abs(fh) + this.cropChangeY <= wrapperH ? Math.abs(fh) - this.cropOldH : wrapperH - this.cropOldH - this.cropChangeY;
964
- this.cropOffsertY = this.cropChangeY + this.cropOldH;
965
- }
966
- } else if (this.changeCropTypeY === 2) {
967
- if (this.cropOldH + fh < minCropH) {
968
- this.cropH = minCropH;
969
- } else if (this.cropOldH + fh > 0) {
970
- this.cropH = this.cropOldH + fh + this.cropOffsertY <= wrapperH ? this.cropOldH + fh : wrapperH - this.cropOffsertY;
971
- this.cropOffsertY = this.cropChangeY;
972
- } else {
973
- this.cropH = wrapperH - this.cropChangeY + Math.abs(fh + this.cropOldH) <= wrapperH - minY ? Math.abs(fh + this.cropOldH) : this.cropChangeY - minY;
974
- this.cropOffsertY = wrapperH - this.cropChangeY + Math.abs(fh + this.cropOldH) <= wrapperH - minY ? this.cropChangeY - Math.abs(fh + this.cropOldH) : minY;
975
- }
976
- }
977
- }
978
- if (this.canChangeX && this.fixed) {
979
- var fixedHeight = this.cropW / this.fixedNumber[0] * this.fixedNumber[1];
980
- if (fixedHeight < minCropH) {
981
- this.cropH = minCropH;
982
- this.cropW = this.fixedNumber[0] * minCropH / this.fixedNumber[1];
983
- if (this.changeCropTypeX === 1) {
984
- this.cropOffsertX = this.cropChangeX + (this.cropOldW - this.cropW);
985
- }
986
- } else if (fixedHeight + this.cropOffsertY > wrapperH) {
987
- this.cropH = wrapperH - this.cropOffsertY;
988
- this.cropW = this.cropH / this.fixedNumber[1] * this.fixedNumber[0];
989
- if (this.changeCropTypeX === 1) {
990
- this.cropOffsertX = this.cropChangeX + (this.cropOldW - this.cropW);
991
- }
992
- } else {
993
- this.cropH = fixedHeight;
994
- }
995
- }
996
- if (this.canChangeY && this.fixed) {
997
- var fixedWidth = this.cropH / this.fixedNumber[1] * this.fixedNumber[0];
998
- if (fixedWidth < minCropW) {
999
- this.cropW = minCropW;
1000
- this.cropH = this.fixedNumber[1] * minCropW / this.fixedNumber[0];
1001
- } else if (fixedWidth + this.cropOffsertX > wrapperW) {
1002
- this.cropW = wrapperW - this.cropOffsertX;
1003
- this.cropH = this.cropW / this.fixedNumber[0] * this.fixedNumber[1];
1004
- } else {
1005
- this.cropW = fixedWidth;
1006
- }
1007
- }
1008
- this.$emit("cropSizing", { cropW: this.cropW, cropH: this.cropH });
1009
- this.$emit("crop-sizing", { cropW: this.cropW, cropH: this.cropH });
1010
- });
1011
- },
1012
- checkCropLimitSize() {
1013
- let { cropW, cropH, limitMinSize } = this;
1014
- let limitMinNum = new Array();
1015
- if (!Array.isArray(limitMinSize)) {
1016
- limitMinNum = [limitMinSize, limitMinSize];
1017
- } else {
1018
- limitMinNum = limitMinSize;
1019
- }
1020
- cropW = parseFloat(limitMinNum[0]);
1021
- cropH = parseFloat(limitMinNum[1]);
1022
- return [cropW, cropH];
1023
- },
1024
- // 结束改变
1025
- changeCropEnd(e) {
1026
- window.removeEventListener("mousemove", this.changeCropNow);
1027
- window.removeEventListener("mouseup", this.changeCropEnd);
1028
- window.removeEventListener("touchmove", this.changeCropNow);
1029
- window.removeEventListener("touchend", this.changeCropEnd);
1030
- },
1031
- // 根据比例x/y,最小宽度,最小高度,现有宽度,现有高度,得到应该有的宽度和高度
1032
- calculateSize(x, y, minX, minY, w, h) {
1033
- const ratio = x / y;
1034
- let width = w;
1035
- let height = h;
1036
- if (width < minX) {
1037
- width = minX;
1038
- height = Math.ceil(width / ratio);
1039
- }
1040
- if (height < minY) {
1041
- height = minY;
1042
- width = Math.ceil(height * ratio);
1043
- if (width < minX) {
1044
- width = minX;
1045
- height = Math.ceil(width / ratio);
1046
- }
1047
- }
1048
- if (width < w) {
1049
- width = w;
1050
- height = Math.ceil(width / ratio);
1051
- }
1052
- if (height < h) {
1053
- height = h;
1054
- width = Math.ceil(height * ratio);
1055
- }
1056
- return { width, height };
1057
- },
1058
- // 创建完成
1059
- endCrop() {
1060
- if (this.cropW === 0 && this.cropH === 0) {
1061
- this.cropping = false;
1062
- }
1063
- let [minCropW, minCropH] = this.checkCropLimitSize();
1064
- const { width, height } = this.fixed ? this.calculateSize(
1065
- this.fixedNumber[0],
1066
- this.fixedNumber[1],
1067
- minCropW,
1068
- minCropH,
1069
- this.cropW,
1070
- this.cropH
1071
- ) : { width: minCropW, height: minCropH };
1072
- if (width > this.cropW) {
1073
- this.cropW = width;
1074
- if (this.cropOffsertX + width > this.w) {
1075
- this.cropOffsertX = this.w - width;
1076
- }
1077
- }
1078
- if (height > this.cropH) {
1079
- this.cropH = height;
1080
- if (this.cropOffsertY + height > this.h) {
1081
- this.cropOffsertY = this.h - height;
1082
- }
1083
- }
1084
- window.removeEventListener("mousemove", this.createCrop);
1085
- window.removeEventListener("mouseup", this.endCrop);
1086
- window.removeEventListener("touchmove", this.createCrop);
1087
- window.removeEventListener("touchend", this.endCrop);
1088
- },
1089
- // 开始截图
1090
- startCrop() {
1091
- this.crop = true;
1092
- },
1093
- // 停止截图
1094
- stopCrop() {
1095
- this.crop = false;
1096
- },
1097
- // 清除截图
1098
- clearCrop() {
1099
- this.cropping = false;
1100
- this.cropW = 0;
1101
- this.cropH = 0;
1102
- },
1103
- // 截图移动
1104
- cropMove(e) {
1105
- e.preventDefault();
1106
- if (!this.canMoveBox) {
1107
- this.crop = false;
1108
- this.startMove(e);
1109
- return false;
1110
- }
1111
- if (e.touches && e.touches.length === 2) {
1112
- this.crop = false;
1113
- this.startMove(e);
1114
- this.leaveCrop();
1115
- return false;
1116
- }
1117
- window.addEventListener("mousemove", this.moveCrop);
1118
- window.addEventListener("mouseup", this.leaveCrop);
1119
- window.addEventListener("touchmove", this.moveCrop);
1120
- window.addEventListener("touchend", this.leaveCrop);
1121
- let x = "clientX" in e ? e.clientX : e.touches[0].clientX;
1122
- let y = "clientY" in e ? e.clientY : e.touches[0].clientY;
1123
- let newX, newY;
1124
- newX = x - this.cropOffsertX;
1125
- newY = y - this.cropOffsertY;
1126
- this.cropX = newX;
1127
- this.cropY = newY;
1128
- this.$emit("cropMoving", {
1129
- moving: true,
1130
- axis: this.getCropAxis()
1131
- });
1132
- this.$emit("crop-moving", {
1133
- moving: true,
1134
- axis: this.getCropAxis()
1135
- });
1136
- },
1137
- moveCrop(e, isMove) {
1138
- let nowX = 0;
1139
- let nowY = 0;
1140
- if (e) {
1141
- e.preventDefault();
1142
- nowX = "clientX" in e ? e.clientX : e.touches[0].clientX;
1143
- nowY = "clientY" in e ? e.clientY : e.touches[0].clientY;
1144
- }
1145
- this.$nextTick(() => {
1146
- let cx, cy;
1147
- let fw = nowX - this.cropX;
1148
- let fh = nowY - this.cropY;
1149
- if (isMove) {
1150
- fw = this.cropOffsertX;
1151
- fh = this.cropOffsertY;
1152
- }
1153
- if (fw <= 0) {
1154
- cx = 0;
1155
- } else if (fw + this.cropW > this.w) {
1156
- cx = this.w - this.cropW;
1157
- } else {
1158
- cx = fw;
1159
- }
1160
- if (fh <= 0) {
1161
- cy = 0;
1162
- } else if (fh + this.cropH > this.h) {
1163
- cy = this.h - this.cropH;
1164
- } else {
1165
- cy = fh;
1166
- }
1167
- if (this.centerBox) {
1168
- let axis = this.getImgAxis();
1169
- if (cx <= axis.x1) {
1170
- cx = axis.x1;
1171
- }
1172
- if (cx + this.cropW > axis.x2) {
1173
- cx = axis.x2 - this.cropW;
1174
- }
1175
- if (cy <= axis.y1) {
1176
- cy = axis.y1;
1177
- }
1178
- if (cy + this.cropH > axis.y2) {
1179
- cy = axis.y2 - this.cropH;
1180
- }
1181
- }
1182
- this.cropOffsertX = cx;
1183
- this.cropOffsertY = cy;
1184
- this.$emit("cropMoving", {
1185
- moving: true,
1186
- axis: this.getCropAxis()
1187
- });
1188
- this.$emit("crop-moving", {
1189
- moving: true,
1190
- axis: this.getCropAxis()
1191
- });
1192
- });
1193
- },
1194
- // 算出不同场景下面 图片相对于外层容器的坐标轴
1195
- getImgAxis(x, y, scale) {
1196
- x = x || this.x;
1197
- y = y || this.y;
1198
- scale = scale || this.scale;
1199
- let obj = {
1200
- x1: 0,
1201
- x2: 0,
1202
- y1: 0,
1203
- y2: 0
1204
- };
1205
- let imgW = this.trueWidth * scale;
1206
- let imgH = this.trueHeight * scale;
1207
- switch (this.rotate) {
1208
- case 0:
1209
- obj.x1 = x + this.trueWidth * (1 - scale) / 2;
1210
- obj.x2 = obj.x1 + this.trueWidth * scale;
1211
- obj.y1 = y + this.trueHeight * (1 - scale) / 2;
1212
- obj.y2 = obj.y1 + this.trueHeight * scale;
1213
- break;
1214
- case 1:
1215
- case -1:
1216
- case 3:
1217
- case -3:
1218
- obj.x1 = x + this.trueWidth * (1 - scale) / 2 + (imgW - imgH) / 2;
1219
- obj.x2 = obj.x1 + this.trueHeight * scale;
1220
- obj.y1 = y + this.trueHeight * (1 - scale) / 2 + (imgH - imgW) / 2;
1221
- obj.y2 = obj.y1 + this.trueWidth * scale;
1222
- break;
1223
- default:
1224
- obj.x1 = x + this.trueWidth * (1 - scale) / 2;
1225
- obj.x2 = obj.x1 + this.trueWidth * scale;
1226
- obj.y1 = y + this.trueHeight * (1 - scale) / 2;
1227
- obj.y2 = obj.y1 + this.trueHeight * scale;
1228
- break;
1229
- }
1230
- return obj;
1231
- },
1232
- // 获取截图框的坐标轴
1233
- getCropAxis() {
1234
- let obj = {
1235
- x1: 0,
1236
- x2: 0,
1237
- y1: 0,
1238
- y2: 0
1239
- };
1240
- obj.x1 = this.cropOffsertX;
1241
- obj.x2 = obj.x1 + this.cropW;
1242
- obj.y1 = this.cropOffsertY;
1243
- obj.y2 = obj.y1 + this.cropH;
1244
- return obj;
1245
- },
1246
- leaveCrop(e) {
1247
- window.removeEventListener("mousemove", this.moveCrop);
1248
- window.removeEventListener("mouseup", this.leaveCrop);
1249
- window.removeEventListener("touchmove", this.moveCrop);
1250
- window.removeEventListener("touchend", this.leaveCrop);
1251
- this.$emit("cropMoving", {
1252
- moving: false,
1253
- axis: this.getCropAxis()
1254
- });
1255
- this.$emit("crop-moving", {
1256
- moving: false,
1257
- axis: this.getCropAxis()
1258
- });
1259
- },
1260
- getCropChecked(cb) {
1261
- let canvas = document.createElement("canvas");
1262
- let ctx = canvas.getContext("2d");
1263
- let img = new Image();
1264
- let rotate = this.rotate;
1265
- let trueWidth = this.trueWidth;
1266
- let trueHeight = this.trueHeight;
1267
- let cropOffsertX = this.cropOffsertX;
1268
- let cropOffsertY = this.cropOffsertY;
1269
- img.onload = () => {
1270
- if (this.cropW !== 0) {
1271
- let dpr = 1;
1272
- if (this.high & !this.full) {
1273
- dpr = window.devicePixelRatio;
1274
- }
1275
- if (this.enlarge !== 1 & !this.full) {
1276
- dpr = Math.abs(Number(this.enlarge));
1277
- }
1278
- let width = this.cropW * dpr;
1279
- let height = this.cropH * dpr;
1280
- let imgW = trueWidth * this.scale * dpr;
1281
- let imgH = trueHeight * this.scale * dpr;
1282
- let dx = (this.x - cropOffsertX + this.trueWidth * (1 - this.scale) / 2) * dpr;
1283
- let dy = (this.y - cropOffsertY + this.trueHeight * (1 - this.scale) / 2) * dpr;
1284
- setCanvasSize(width, height);
1285
- ctx.save();
1286
- switch (rotate) {
1287
- case 0:
1288
- if (!this.full) {
1289
- ctx.drawImage(img, dx, dy, imgW, imgH);
1290
- } else {
1291
- setCanvasSize(width / this.scale, height / this.scale);
1292
- ctx.drawImage(
1293
- img,
1294
- dx / this.scale,
1295
- dy / this.scale,
1296
- imgW / this.scale,
1297
- imgH / this.scale
1298
- );
1299
- }
1300
- break;
1301
- case 1:
1302
- case -3:
1303
- if (!this.full) {
1304
- dx = dx + (imgW - imgH) / 2;
1305
- dy = dy + (imgH - imgW) / 2;
1306
- ctx.rotate(rotate * 90 * Math.PI / 180);
1307
- ctx.drawImage(img, dy, -dx - imgH, imgW, imgH);
1308
- } else {
1309
- setCanvasSize(width / this.scale, height / this.scale);
1310
- dx = dx / this.scale + (imgW / this.scale - imgH / this.scale) / 2;
1311
- dy = dy / this.scale + (imgH / this.scale - imgW / this.scale) / 2;
1312
- ctx.rotate(rotate * 90 * Math.PI / 180);
1313
- ctx.drawImage(
1314
- img,
1315
- dy,
1316
- -dx - imgH / this.scale,
1317
- imgW / this.scale,
1318
- imgH / this.scale
1319
- );
1320
- }
1321
- break;
1322
- case 2:
1323
- case -2:
1324
- if (!this.full) {
1325
- ctx.rotate(rotate * 90 * Math.PI / 180);
1326
- ctx.drawImage(img, -dx - imgW, -dy - imgH, imgW, imgH);
1327
- } else {
1328
- setCanvasSize(width / this.scale, height / this.scale);
1329
- ctx.rotate(rotate * 90 * Math.PI / 180);
1330
- dx = dx / this.scale;
1331
- dy = dy / this.scale;
1332
- ctx.drawImage(
1333
- img,
1334
- -dx - imgW / this.scale,
1335
- -dy - imgH / this.scale,
1336
- imgW / this.scale,
1337
- imgH / this.scale
1338
- );
1339
- }
1340
- break;
1341
- case 3:
1342
- case -1:
1343
- if (!this.full) {
1344
- dx = dx + (imgW - imgH) / 2;
1345
- dy = dy + (imgH - imgW) / 2;
1346
- ctx.rotate(rotate * 90 * Math.PI / 180);
1347
- ctx.drawImage(img, -dy - imgW, dx, imgW, imgH);
1348
- } else {
1349
- setCanvasSize(width / this.scale, height / this.scale);
1350
- dx = dx / this.scale + (imgW / this.scale - imgH / this.scale) / 2;
1351
- dy = dy / this.scale + (imgH / this.scale - imgW / this.scale) / 2;
1352
- ctx.rotate(rotate * 90 * Math.PI / 180);
1353
- ctx.drawImage(
1354
- img,
1355
- -dy - imgW / this.scale,
1356
- dx,
1357
- imgW / this.scale,
1358
- imgH / this.scale
1359
- );
1360
- }
1361
- break;
1362
- default:
1363
- if (!this.full) {
1364
- ctx.drawImage(img, dx, dy, imgW, imgH);
1365
- } else {
1366
- setCanvasSize(width / this.scale, height / this.scale);
1367
- ctx.drawImage(
1368
- img,
1369
- dx / this.scale,
1370
- dy / this.scale,
1371
- imgW / this.scale,
1372
- imgH / this.scale
1373
- );
1374
- }
1375
- }
1376
- ctx.restore();
1377
- } else {
1378
- let width = trueWidth * this.scale;
1379
- let height = trueHeight * this.scale;
1380
- ctx.save();
1381
- switch (rotate) {
1382
- case 0:
1383
- setCanvasSize(width, height);
1384
- ctx.drawImage(img, 0, 0, width, height);
1385
- break;
1386
- case 1:
1387
- case -3:
1388
- setCanvasSize(height, width);
1389
- ctx.rotate(rotate * 90 * Math.PI / 180);
1390
- ctx.drawImage(img, 0, -height, width, height);
1391
- break;
1392
- case 2:
1393
- case -2:
1394
- setCanvasSize(width, height);
1395
- ctx.rotate(rotate * 90 * Math.PI / 180);
1396
- ctx.drawImage(img, -width, -height, width, height);
1397
- break;
1398
- case 3:
1399
- case -1:
1400
- setCanvasSize(height, width);
1401
- ctx.rotate(rotate * 90 * Math.PI / 180);
1402
- ctx.drawImage(img, -width, 0, width, height);
1403
- break;
1404
- default:
1405
- setCanvasSize(width, height);
1406
- ctx.drawImage(img, 0, 0, width, height);
1407
- }
1408
- ctx.restore();
1409
- }
1410
- cb(canvas);
1411
- };
1412
- var s = this.img.substr(0, 4);
1413
- if (s !== "data") {
1414
- img.crossOrigin = "Anonymous";
1415
- }
1416
- img.src = this.imgs;
1417
- const fillColor = this.fillColor;
1418
- function setCanvasSize(width, height) {
1419
- canvas.width = Math.round(width);
1420
- canvas.height = Math.round(height);
1421
- if (fillColor) {
1422
- ctx.fillStyle = fillColor;
1423
- ctx.fillRect(0, 0, canvas.width, canvas.height);
1424
- }
1425
- }
1426
- },
1427
- // 获取转换成base64 的图片信息
1428
- getCropData(cb) {
1429
- this.getCropChecked((data) => {
1430
- cb(data.toDataURL("image/" + this.outputType, this.outputSize));
1431
- });
1432
- },
1433
- //canvas获取为blob对象
1434
- getCropBlob(cb) {
1435
- this.getCropChecked((data) => {
1436
- data.toBlob(
1437
- (blob) => cb(blob),
1438
- "image/" + this.outputType,
1439
- this.outputSize
1440
- );
1441
- });
1442
- },
1443
- // 自动预览函数
1444
- showPreview() {
1445
- if (this.isCanShow) {
1446
- this.isCanShow = false;
1447
- setTimeout(() => {
1448
- this.isCanShow = true;
1449
- }, 16);
1450
- } else {
1451
- return false;
1452
- }
1453
- let w = this.cropW;
1454
- let h = this.cropH;
1455
- let scale = this.scale;
1456
- var obj = {};
1457
- obj.div = {
1458
- width: `${w}px`,
1459
- height: `${h}px`
1460
- };
1461
- let transformX = (this.x - this.cropOffsertX) / scale;
1462
- let transformY = (this.y - this.cropOffsertY) / scale;
1463
- let transformZ = 0;
1464
- obj.w = w;
1465
- obj.h = h;
1466
- obj.url = this.imgs;
1467
- obj.img = {
1468
- width: `${this.trueWidth}px`,
1469
- height: `${this.trueHeight}px`,
1470
- transform: `scale(${scale})translate3d(${transformX}px, ${transformY}px, ${transformZ}px)rotateZ(${this.rotate * 90}deg)`
1471
- };
1472
- obj.html = `
1473
- <div class="show-preview" style="width: ${obj.w}px; height: ${obj.h}px; overflow: hidden">
1474
- <div style="width: ${w}px; height: ${h}px">
1475
- <img src=${obj.url} style="width: ${this.trueWidth}px; height: ${this.trueHeight}px; transform:
1476
- scale(${scale})translate3d(${transformX}px, ${transformY}px, ${transformZ}px)rotateZ(${this.rotate * 90}deg)">
1477
- </div>
1478
- </div>`;
1479
- this.$emit("realTime", obj);
1480
- this.$emit("real-time", obj);
1481
- },
1482
- // reload 图片布局函数
1483
- reload() {
1484
- let img = new Image();
1485
- img.onload = () => {
1486
- this.w = parseFloat(window.getComputedStyle(this.$refs.cropper).width);
1487
- this.h = parseFloat(window.getComputedStyle(this.$refs.cropper).height);
1488
- this.trueWidth = img.width;
1489
- this.trueHeight = img.height;
1490
- if (!this.original) {
1491
- this.scale = this.checkedMode();
1492
- } else {
1493
- this.scale = 1;
1494
- }
1495
- this.$nextTick(() => {
1496
- this.x = -(this.trueWidth - this.trueWidth * this.scale) / 2 + (this.w - this.trueWidth * this.scale) / 2;
1497
- this.y = -(this.trueHeight - this.trueHeight * this.scale) / 2 + (this.h - this.trueHeight * this.scale) / 2;
1498
- this.loading = false;
1499
- if (this.autoCrop) {
1500
- this.goAutoCrop();
1501
- }
1502
- this.$emit("img-load", "success");
1503
- this.$emit("imgLoad", "success");
1504
- setTimeout(() => {
1505
- this.showPreview();
1506
- }, 20);
1507
- });
1508
- };
1509
- img.onerror = () => {
1510
- this.$emit("imgLoad", "error");
1511
- this.$emit("img-load", "error");
1512
- };
1513
- img.src = this.imgs;
1514
- },
1515
- // 背景布局的函数
1516
- checkedMode() {
1517
- let scale = 1;
1518
- let imgW = this.trueWidth;
1519
- let imgH = this.trueHeight;
1520
- const arr = this.mode.split(" ");
1521
- switch (arr[0]) {
1522
- case "contain":
1523
- if (this.trueWidth > this.w) {
1524
- scale = this.w / this.trueWidth;
1525
- }
1526
- if (this.trueHeight * scale > this.h) {
1527
- scale = this.h / this.trueHeight;
1528
- }
1529
- break;
1530
- case "cover":
1531
- imgW = this.w;
1532
- scale = imgW / this.trueWidth;
1533
- imgH = imgH * scale;
1534
- if (imgH < this.h) {
1535
- imgH = this.h;
1536
- scale = imgH / this.trueHeight;
1537
- }
1538
- break;
1539
- default:
1540
- try {
1541
- let str = arr[0];
1542
- if (str.search("px") !== -1) {
1543
- str = str.replace("px", "");
1544
- imgW = parseFloat(str);
1545
- const scaleX = imgW / this.trueWidth;
1546
- let scaleY = 1;
1547
- let strH = arr[1];
1548
- if (strH.search("px") !== -1) {
1549
- strH = strH.replace("px", "");
1550
- imgH = parseFloat(strH);
1551
- scaleY = imgH / this.trueHeight;
1552
- }
1553
- scale = Math.min(scaleX, scaleY);
1554
- }
1555
- if (str.search("%") !== -1) {
1556
- str = str.replace("%", "");
1557
- imgW = parseFloat(str) / 100 * this.w;
1558
- scale = imgW / this.trueWidth;
1559
- }
1560
- if (arr.length === 2 && str === "auto") {
1561
- let str2 = arr[1];
1562
- if (str2.search("px") !== -1) {
1563
- str2 = str2.replace("px", "");
1564
- imgH = parseFloat(str2);
1565
- scale = imgH / this.trueHeight;
1566
- }
1567
- if (str2.search("%") !== -1) {
1568
- str2 = str2.replace("%", "");
1569
- imgH = parseFloat(str2) / 100 * this.h;
1570
- scale = imgH / this.trueHeight;
1571
- }
1572
- }
1573
- } catch (error2) {
1574
- scale = 1;
1575
- }
1576
- }
1577
- return scale;
1578
- },
1579
- // 自动截图函数
1580
- goAutoCrop(cw, ch) {
1581
- if (this.imgs === "" || this.imgs === null) return;
1582
- this.clearCrop();
1583
- this.cropping = true;
1584
- let maxWidth = this.w;
1585
- let maxHeight = this.h;
1586
- if (this.centerBox) {
1587
- const switchWH = Math.abs(this.rotate) % 2 > 0;
1588
- let imgW = (switchWH ? this.trueHeight : this.trueWidth) * this.scale;
1589
- let imgH = (switchWH ? this.trueWidth : this.trueHeight) * this.scale;
1590
- maxWidth = imgW < maxWidth ? imgW : maxWidth;
1591
- maxHeight = imgH < maxHeight ? imgH : maxHeight;
1592
- }
1593
- var w = cw ? cw : parseFloat(this.autoCropWidth);
1594
- var h = ch ? ch : parseFloat(this.autoCropHeight);
1595
- if (w === 0 || h === 0) {
1596
- w = maxWidth * 0.8;
1597
- h = maxHeight * 0.8;
1598
- }
1599
- w = w > maxWidth ? maxWidth : w;
1600
- h = h > maxHeight ? maxHeight : h;
1601
- if (this.fixed) {
1602
- h = w / this.fixedNumber[0] * this.fixedNumber[1];
1603
- }
1604
- if (h > this.h) {
1605
- h = this.h;
1606
- w = h / this.fixedNumber[1] * this.fixedNumber[0];
1607
- }
1608
- this.changeCrop(w, h);
1609
- },
1610
- // 手动改变截图框大小函数
1611
- changeCrop(w, h) {
1612
- if (this.centerBox) {
1613
- let axis = this.getImgAxis();
1614
- if (w > axis.x2 - axis.x1) {
1615
- w = axis.x2 - axis.x1;
1616
- h = w / this.fixedNumber[0] * this.fixedNumber[1];
1617
- }
1618
- if (h > axis.y2 - axis.y1) {
1619
- h = axis.y2 - axis.y1;
1620
- w = h / this.fixedNumber[1] * this.fixedNumber[0];
1621
- }
1622
- }
1623
- this.cropW = w;
1624
- this.cropH = h;
1625
- this.checkCropLimitSize();
1626
- this.$nextTick(() => {
1627
- this.cropOffsertX = (this.w - this.cropW) / 2;
1628
- this.cropOffsertY = (this.h - this.cropH) / 2;
1629
- if (this.centerBox) {
1630
- this.moveCrop(null, true);
1631
- }
1632
- });
1633
- },
1634
- // 重置函数, 恢复组件置初始状态
1635
- refresh() {
1636
- this.img;
1637
- this.imgs = "";
1638
- this.scale = 1;
1639
- this.crop = false;
1640
- this.rotate = 0;
1641
- this.w = 0;
1642
- this.h = 0;
1643
- this.trueWidth = 0;
1644
- this.trueHeight = 0;
1645
- this.clearCrop();
1646
- this.$nextTick(() => {
1647
- this.checkedImg();
1648
- });
1649
- },
1650
- // 向左边旋转
1651
- rotateLeft() {
1652
- this.rotate = this.rotate <= -3 ? 0 : this.rotate - 1;
1653
- },
1654
- // 向右边旋转
1655
- rotateRight() {
1656
- this.rotate = this.rotate >= 3 ? 0 : this.rotate + 1;
1657
- },
1658
- // 清除旋转
1659
- rotateClear() {
1660
- this.rotate = 0;
1661
- },
1662
- // 图片坐标点校验
1663
- checkoutImgAxis(x, y, scale) {
1664
- x = x || this.x;
1665
- y = y || this.y;
1666
- scale = scale || this.scale;
1667
- let canGo = true;
1668
- if (this.centerBox) {
1669
- let axis = this.getImgAxis(x, y, scale);
1670
- let cropAxis = this.getCropAxis();
1671
- if (axis.x1 >= cropAxis.x1) {
1672
- canGo = false;
1673
- }
1674
- if (axis.x2 <= cropAxis.x2) {
1675
- canGo = false;
1676
- }
1677
- if (axis.y1 >= cropAxis.y1) {
1678
- canGo = false;
1679
- }
1680
- if (axis.y2 <= cropAxis.y2) {
1681
- canGo = false;
1682
- }
1683
- if (!canGo) {
1684
- this.changeImgScale(axis, cropAxis, scale);
1685
- }
1686
- }
1687
- return canGo;
1688
- },
1689
- // 缩放图片,将图片坐标适配截图框坐标
1690
- changeImgScale(axis, cropAxis, scale) {
1691
- let trueWidth = this.trueWidth;
1692
- let trueHeight = this.trueHeight;
1693
- let imgW = trueWidth * scale;
1694
- let imgH = trueHeight * scale;
1695
- if (imgW >= this.cropW && imgH >= this.cropH) {
1696
- this.scale = scale;
1697
- } else {
1698
- const cropWScale = this.cropW / trueWidth;
1699
- const cropHScale = this.cropH / trueHeight;
1700
- const cropScale = this.cropH <= trueHeight * cropWScale ? cropWScale : cropHScale;
1701
- this.scale = cropScale;
1702
- imgW = trueWidth * cropScale;
1703
- imgH = trueHeight * cropScale;
1704
- }
1705
- if (!this.imgIsQqualCrop) {
1706
- if (axis.x1 >= cropAxis.x1) {
1707
- if (this.isRotateRightOrLeft) {
1708
- this.x = cropAxis.x1 - (trueWidth - imgW) / 2 - (imgW - imgH) / 2;
1709
- } else {
1710
- this.x = cropAxis.x1 - (trueWidth - imgW) / 2;
1711
- }
1712
- }
1713
- if (axis.x2 <= cropAxis.x2) {
1714
- if (this.isRotateRightOrLeft) {
1715
- this.x = cropAxis.x1 - (trueWidth - imgW) / 2 - (imgW - imgH) / 2 - imgH + this.cropW;
1716
- } else {
1717
- this.x = cropAxis.x2 - (trueWidth - imgW) / 2 - imgW;
1718
- }
1719
- }
1720
- if (axis.y1 >= cropAxis.y1) {
1721
- if (this.isRotateRightOrLeft) {
1722
- this.y = cropAxis.y1 - (trueHeight - imgH) / 2 - (imgH - imgW) / 2;
1723
- } else {
1724
- this.y = cropAxis.y1 - (trueHeight - imgH) / 2;
1725
- }
1726
- }
1727
- if (axis.y2 <= cropAxis.y2) {
1728
- if (this.isRotateRightOrLeft) {
1729
- this.y = cropAxis.y2 - (trueHeight - imgH) / 2 - (imgH - imgW) / 2 - imgW;
1730
- } else {
1731
- this.y = cropAxis.y2 - (trueHeight - imgH) / 2 - imgH;
1732
- }
1733
- }
1734
- }
1735
- if (imgW < this.cropW || imgH < this.cropH) {
1736
- this.imgIsQqualCrop = true;
1737
- }
1738
- }
1739
- },
1740
- mounted() {
1741
- this.support = "onwheel" in document.createElement("div") ? "wheel" : document.onmousewheel !== void 0 ? "mousewheel" : "DOMMouseScroll";
1742
- let that = this;
1743
- var u = navigator.userAgent;
1744
- this.isIOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/);
1745
- if (!HTMLCanvasElement.prototype.toBlob) {
1746
- Object.defineProperty(HTMLCanvasElement.prototype, "toBlob", {
1747
- value: function(callback, type, quality) {
1748
- var binStr = atob(this.toDataURL(type, quality).split(",")[1]), len = binStr.length, arr = new Uint8Array(len);
1749
- for (var i = 0; i < len; i++) {
1750
- arr[i] = binStr.charCodeAt(i);
1751
- }
1752
- callback(new Blob([arr], { type: that.type || "image/png" }));
1753
- }
1754
- });
1755
- }
1756
- this.showPreview();
1757
- this.checkedImg();
1758
- },
1759
- destroyed() {
1760
- window.removeEventListener("mousemove", this.moveCrop);
1761
- window.removeEventListener("mouseup", this.leaveCrop);
1762
- window.removeEventListener("touchmove", this.moveCrop);
1763
- window.removeEventListener("touchend", this.leaveCrop);
1764
- this.cancelScale();
1765
- }
1766
- };
1767
- const _hoisted_1$1 = {
1768
- key: 0,
1769
- class: "cropper-box"
1770
- };
1771
- const _hoisted_2$1 = ["src"];
1772
- const _hoisted_3$1 = { class: "cropper-view-box" };
1773
- const _hoisted_4 = ["src"];
1774
- const _hoisted_5 = { key: 1 };
1775
- function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
1776
- return openBlock(), createElementBlock("div", {
1777
- class: "vue-cropper",
1778
- ref: "cropper",
1779
- onMouseover: _cache[28] || (_cache[28] = (...args) => $options.scaleImg && $options.scaleImg(...args)),
1780
- onMouseout: _cache[29] || (_cache[29] = (...args) => $options.cancelScale && $options.cancelScale(...args))
1781
- }, [
1782
- _ctx.imgs ? (openBlock(), createElementBlock("div", _hoisted_1$1, [
1783
- withDirectives(createElementVNode("div", {
1784
- class: "cropper-box-canvas",
1785
- style: normalizeStyle({
1786
- "width": _ctx.trueWidth + "px",
1787
- "height": _ctx.trueHeight + "px",
1788
- "transform": "scale(" + _ctx.scale + "," + _ctx.scale + ") translate3d(" + _ctx.x / _ctx.scale + "px," + _ctx.y / _ctx.scale + "px,0)rotateZ(" + _ctx.rotate * 90 + "deg)"
1789
- })
1790
- }, [
1791
- createElementVNode("img", {
1792
- src: _ctx.imgs,
1793
- alt: "cropper-img",
1794
- ref: "cropperImg"
1795
- }, null, 8, _hoisted_2$1)
1796
- ], 4), [
1797
- [vShow, !_ctx.loading]
1798
- ])
1799
- ])) : createCommentVNode("", true),
1800
- createElementVNode("div", {
1801
- class: normalizeClass(["cropper-drag-box", { "cropper-move": _ctx.move && !_ctx.crop, "cropper-crop": _ctx.crop, "cropper-modal": _ctx.cropping }]),
1802
- onMousedown: _cache[0] || (_cache[0] = (...args) => $options.startMove && $options.startMove(...args)),
1803
- onTouchstart: _cache[1] || (_cache[1] = (...args) => $options.startMove && $options.startMove(...args))
1804
- }, null, 34),
1805
- withDirectives(createElementVNode("div", {
1806
- class: "cropper-crop-box",
1807
- style: normalizeStyle({
1808
- "width": _ctx.cropW + "px",
1809
- "height": _ctx.cropH + "px",
1810
- "transform": "translate3d(" + _ctx.cropOffsertX + "px," + _ctx.cropOffsertY + "px,0)"
1811
- })
1812
- }, [
1813
- createElementVNode("span", _hoisted_3$1, [
1814
- createElementVNode("img", {
1815
- style: normalizeStyle({
1816
- "width": _ctx.trueWidth + "px",
1817
- "height": _ctx.trueHeight + "px",
1818
- "transform": "scale(" + _ctx.scale + "," + _ctx.scale + ") translate3d(" + (_ctx.x - _ctx.cropOffsertX) / _ctx.scale + "px," + (_ctx.y - _ctx.cropOffsertY) / _ctx.scale + "px,0)rotateZ(" + _ctx.rotate * 90 + "deg)"
1819
- }),
1820
- src: _ctx.imgs,
1821
- alt: "cropper-img"
1822
- }, null, 12, _hoisted_4)
1823
- ]),
1824
- createElementVNode("span", {
1825
- class: "cropper-face cropper-move",
1826
- onMousedown: _cache[2] || (_cache[2] = (...args) => $options.cropMove && $options.cropMove(...args)),
1827
- onTouchstart: _cache[3] || (_cache[3] = (...args) => $options.cropMove && $options.cropMove(...args))
1828
- }, null, 32),
1829
- $props.info ? (openBlock(), createElementBlock("span", {
1830
- key: 0,
1831
- class: "crop-info",
1832
- style: normalizeStyle({ "top": $options.cropInfo.top })
1833
- }, toDisplayString($options.cropInfo.width) + " × " + toDisplayString($options.cropInfo.height), 5)) : createCommentVNode("", true),
1834
- !$props.fixedBox ? (openBlock(), createElementBlock("span", _hoisted_5, [
1835
- createElementVNode("span", {
1836
- class: "crop-line line-w",
1837
- onMousedown: _cache[4] || (_cache[4] = ($event) => $options.changeCropSize($event, false, true, 0, 1)),
1838
- onTouchstart: _cache[5] || (_cache[5] = ($event) => $options.changeCropSize($event, false, true, 0, 1))
1839
- }, null, 32),
1840
- createElementVNode("span", {
1841
- class: "crop-line line-a",
1842
- onMousedown: _cache[6] || (_cache[6] = ($event) => $options.changeCropSize($event, true, false, 1, 0)),
1843
- onTouchstart: _cache[7] || (_cache[7] = ($event) => $options.changeCropSize($event, true, false, 1, 0))
1844
- }, null, 32),
1845
- createElementVNode("span", {
1846
- class: "crop-line line-s",
1847
- onMousedown: _cache[8] || (_cache[8] = ($event) => $options.changeCropSize($event, false, true, 0, 2)),
1848
- onTouchstart: _cache[9] || (_cache[9] = ($event) => $options.changeCropSize($event, false, true, 0, 2))
1849
- }, null, 32),
1850
- createElementVNode("span", {
1851
- class: "crop-line line-d",
1852
- onMousedown: _cache[10] || (_cache[10] = ($event) => $options.changeCropSize($event, true, false, 2, 0)),
1853
- onTouchstart: _cache[11] || (_cache[11] = ($event) => $options.changeCropSize($event, true, false, 2, 0))
1854
- }, null, 32),
1855
- createElementVNode("span", {
1856
- class: "crop-point point1",
1857
- onMousedown: _cache[12] || (_cache[12] = ($event) => $options.changeCropSize($event, true, true, 1, 1)),
1858
- onTouchstart: _cache[13] || (_cache[13] = ($event) => $options.changeCropSize($event, true, true, 1, 1))
1859
- }, null, 32),
1860
- createElementVNode("span", {
1861
- class: "crop-point point2",
1862
- onMousedown: _cache[14] || (_cache[14] = ($event) => $options.changeCropSize($event, false, true, 0, 1)),
1863
- onTouchstart: _cache[15] || (_cache[15] = ($event) => $options.changeCropSize($event, false, true, 0, 1))
1864
- }, null, 32),
1865
- createElementVNode("span", {
1866
- class: "crop-point point3",
1867
- onMousedown: _cache[16] || (_cache[16] = ($event) => $options.changeCropSize($event, true, true, 2, 1)),
1868
- onTouchstart: _cache[17] || (_cache[17] = ($event) => $options.changeCropSize($event, true, true, 2, 1))
1869
- }, null, 32),
1870
- createElementVNode("span", {
1871
- class: "crop-point point4",
1872
- onMousedown: _cache[18] || (_cache[18] = ($event) => $options.changeCropSize($event, true, false, 1, 0)),
1873
- onTouchstart: _cache[19] || (_cache[19] = ($event) => $options.changeCropSize($event, true, false, 1, 0))
1874
- }, null, 32),
1875
- createElementVNode("span", {
1876
- class: "crop-point point5",
1877
- onMousedown: _cache[20] || (_cache[20] = ($event) => $options.changeCropSize($event, true, false, 2, 0)),
1878
- onTouchstart: _cache[21] || (_cache[21] = ($event) => $options.changeCropSize($event, true, false, 2, 0))
1879
- }, null, 32),
1880
- createElementVNode("span", {
1881
- class: "crop-point point6",
1882
- onMousedown: _cache[22] || (_cache[22] = ($event) => $options.changeCropSize($event, true, true, 1, 2)),
1883
- onTouchstart: _cache[23] || (_cache[23] = ($event) => $options.changeCropSize($event, true, true, 1, 2))
1884
- }, null, 32),
1885
- createElementVNode("span", {
1886
- class: "crop-point point7",
1887
- onMousedown: _cache[24] || (_cache[24] = ($event) => $options.changeCropSize($event, false, true, 0, 2)),
1888
- onTouchstart: _cache[25] || (_cache[25] = ($event) => $options.changeCropSize($event, false, true, 0, 2))
1889
- }, null, 32),
1890
- createElementVNode("span", {
1891
- class: "crop-point point8",
1892
- onMousedown: _cache[26] || (_cache[26] = ($event) => $options.changeCropSize($event, true, true, 2, 2)),
1893
- onTouchstart: _cache[27] || (_cache[27] = ($event) => $options.changeCropSize($event, true, true, 2, 2))
1894
- }, null, 32)
1895
- ])) : createCommentVNode("", true)
1896
- ], 4), [
1897
- [vShow, _ctx.cropping]
1898
- ])
1899
- ], 544);
1900
- }
1901
- const VueCropper = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render], ["__scopeId", "data-v-8e42ffcf"]]);
1902
- const _hoisted_1 = { class: "h-full" };
1903
- const _hoisted_2 = { class: "avatar-upload-preview" };
1904
- const _hoisted_3 = ["src"];
1905
- const __default__ = defineComponent({
1906
- name: "cropper"
1907
- });
1908
- const _sfc_main = /* @__PURE__ */ defineComponent({
1909
- ...__default__,
1910
- props: {
1911
- avatar: { default: "" },
1912
- close: { type: Function, default: close },
1913
- proxyId: { default: "" }
1914
- },
1915
- setup(__props) {
1916
- const { postSinglefile, postUpdateFile } = useFileController();
1917
- const props = __props;
1918
- let userInfos = ref({});
1919
- onMounted(async () => {
1920
- userInfos.value = await systemStore.get(
1921
- "userInfo"
1922
- );
1923
- });
1924
- let { avatar } = toRefs(props);
1925
- const options = reactive({
1926
- img: "",
1927
- // 需要剪裁的图片
1928
- autoCrop: true,
1929
- // 是否默认生成截图框
1930
- autoCropWidth: 200,
1931
- // 默认生成截图框的宽度
1932
- autoCropHeight: 200,
1933
- // 默认生成截图框的长度
1934
- fixedBox: false,
1935
- // 是否固定截图框的大小 不允许改变
1936
- // info: true, // 裁剪框的大小信息
1937
- outputSize: 0.5,
1938
- // 裁剪生成图片的质量 [1至0.1]
1939
- outputType: "jpeg",
1940
- // 裁剪生成图片的格式
1941
- canScale: false,
1942
- // 图片是否允许滚轮缩放
1943
- fixed: false,
1944
- // 是否开启截图框宽高固定比例
1945
- fixedNumber: [1, 1],
1946
- // 截图框的宽高比例 需要配合centerBox一起使用才能生效
1947
- full: true,
1948
- // 是否输出原图比例的截图
1949
- canMoveBox: false,
1950
- // 截图框能否拖动
1951
- original: false,
1952
- // 上传图片按照原始比例渲染
1953
- centerBox: false,
1954
- // 截图框是否被限制在图片里面
1955
- infoTrue: true,
1956
- // true 为展示真实输出图片宽高 false 展示看到的截图框宽高
1957
- filename: ""
1958
- // 文件名
1959
- });
1960
- const previews = ref({});
1961
- const cropperRef = ref({});
1962
- ref(false);
1963
- let rotateClick = (type) => {
1964
- if (type == "left") {
1965
- cropperRef.value.rotateLeft();
1966
- }
1967
- if (type == "right") {
1968
- cropperRef.value.rotateRight();
1969
- }
1970
- };
1971
- let changeScale = (num) => {
1972
- const scale = num || 1;
1973
- cropperRef.value.changeScale(scale);
1974
- };
1975
- let refreshCrop = () => {
1976
- cropperRef.value.refresh();
1977
- };
1978
- const realTime = (data) => {
1979
- previews.value = data;
1980
- };
1981
- let requestUpload = () => {
1982
- };
1983
- let beforeUpload = (file) => {
1984
- let img = [
1985
- "image/png",
1986
- "image/jpg",
1987
- "image/jpeg",
1988
- "image/PNG",
1989
- "image/JPG",
1990
- "image/JPEG",
1991
- "image/gif"
1992
- ];
1993
- if (!img.includes(file.type)) {
1994
- ElMessage.error("图片格式有误,请重新上传");
1995
- return false;
1996
- } else {
1997
- const reader = new FileReader();
1998
- reader.readAsDataURL(file);
1999
- reader.onload = () => {
2000
- options.img = reader.result;
2001
- options.filename = file.name;
2002
- };
2003
- }
2004
- };
2005
- let uploadImg = () => {
2006
- if (!options.img) {
2007
- ElMessage.warning("请先选择图片");
2008
- }
2009
- cropperRef.value.getCropBlob(async (data) => {
2010
- const photoRes = await postSinglefile({
2011
- data: { file: data },
2012
- proxy: props.proxyId
2013
- });
2014
- const res = await postUpdateFile({
2015
- data: {
2016
- id: userInfos.value.id,
2017
- attchIdArrStr: photoRes.data.id,
2018
- attachType: 2
2019
- },
2020
- proxy: props.proxyId
2021
- });
2022
- props.close(res);
2023
- });
2024
- };
2025
- onMounted(() => {
2026
- setTimeout(() => {
2027
- options.img = avatar.value;
2028
- }, 100);
2029
- });
2030
- return (_ctx, _cache) => {
2031
- const _component_el_col = resolveComponent("el-col");
2032
- const _component_el_row = resolveComponent("el-row");
2033
- const _component_bc_icon = resolveComponent("bc-icon");
2034
- const _component_el_button = resolveComponent("el-button");
2035
- const _component_hs_upload = resolveComponent("hs-upload");
2036
- return openBlock(), createElementBlock("div", _hoisted_1, [
2037
- createVNode(_component_el_row, null, {
2038
- default: withCtx(() => [
2039
- createVNode(_component_el_col, {
2040
- xs: 24,
2041
- md: 13,
2042
- style: { height: "350px" }
2043
- }, {
2044
- default: withCtx(() => [
2045
- createVNode(VueCropper, {
2046
- ref_key: "cropperRef",
2047
- ref: cropperRef,
2048
- img: options.img,
2049
- info: true,
2050
- infoTrue: options.infoTrue,
2051
- "auto-crop": options.autoCrop,
2052
- "fixed-box": options.fixedBox,
2053
- fixedNumber: options.fixedNumber,
2054
- fixed: options.fixed,
2055
- centerBox: options.centerBox,
2056
- outputType: "png",
2057
- onRealTime: realTime
2058
- }, null, 8, ["img", "infoTrue", "auto-crop", "fixed-box", "fixedNumber", "fixed", "centerBox"])
2059
- ]),
2060
- _: 1
2061
- }),
2062
- createVNode(_component_el_col, {
2063
- xs: 24,
2064
- md: 11,
2065
- style: { height: "350px" }
2066
- }, {
2067
- default: withCtx(() => [
2068
- createElementVNode("div", _hoisted_2, [
2069
- createElementVNode("img", {
2070
- src: previews.value.url,
2071
- style: normalizeStyle(previews.value.img)
2072
- }, null, 12, _hoisted_3)
2073
- ])
2074
- ]),
2075
- _: 1
2076
- })
2077
- ]),
2078
- _: 1
2079
- }),
2080
- createVNode(_component_el_row, { class: "ptb2 py-3" }, {
2081
- default: withCtx(() => [
2082
- createVNode(_component_el_col, {
2083
- lg: 2,
2084
- md: 2
2085
- }, {
2086
- default: withCtx(() => [
2087
- createVNode(_component_hs_upload, {
2088
- action: "#",
2089
- "http-request": unref(requestUpload),
2090
- "show-file-list": false,
2091
- "before-upload": unref(beforeUpload),
2092
- accept: "image/*"
2093
- }, {
2094
- default: withCtx(() => [
2095
- createVNode(_component_el_button, { size: "default" }, {
2096
- default: withCtx(() => [
2097
- _cache[6] || (_cache[6] = createTextVNode(" 选择 ")),
2098
- createVNode(_component_bc_icon, { name: "ele-UploadFilled" })
2099
- ]),
2100
- _: 1,
2101
- __: [6]
2102
- })
2103
- ]),
2104
- _: 1
2105
- }, 8, ["http-request", "before-upload"])
2106
- ]),
2107
- _: 1
2108
- }),
2109
- createVNode(_component_el_col, {
2110
- lg: { span: 1, offset: 1 },
2111
- md: 2
2112
- }, {
2113
- default: withCtx(() => [
2114
- createVNode(_component_el_button, {
2115
- size: "default",
2116
- icon: "ele-Plus",
2117
- onClick: _cache[0] || (_cache[0] = ($event) => unref(changeScale)(1))
2118
- })
2119
- ]),
2120
- _: 1
2121
- }),
2122
- createVNode(_component_el_col, {
2123
- lg: { span: 1, offset: 1 },
2124
- md: 2
2125
- }, {
2126
- default: withCtx(() => [
2127
- createVNode(_component_el_button, {
2128
- size: "default",
2129
- icon: "ele-Minus",
2130
- onClick: _cache[1] || (_cache[1] = ($event) => unref(changeScale)(-1))
2131
- })
2132
- ]),
2133
- _: 1
2134
- }),
2135
- createVNode(_component_el_col, {
2136
- lg: { span: 1, offset: 1 },
2137
- md: 2
2138
- }, {
2139
- default: withCtx(() => [
2140
- createVNode(_component_el_button, {
2141
- size: "default",
2142
- icon: "ele-RefreshLeft",
2143
- onClick: _cache[2] || (_cache[2] = ($event) => unref(rotateClick)("left"))
2144
- })
2145
- ]),
2146
- _: 1
2147
- }),
2148
- createVNode(_component_el_col, {
2149
- lg: { span: 1, offset: 1 },
2150
- md: 2
2151
- }, {
2152
- default: withCtx(() => [
2153
- createVNode(_component_el_button, {
2154
- size: "default",
2155
- icon: "ele-RefreshRight",
2156
- onClick: _cache[3] || (_cache[3] = ($event) => unref(rotateClick)("right"))
2157
- })
2158
- ]),
2159
- _: 1
2160
- }),
2161
- createVNode(_component_el_col, {
2162
- lg: { span: 1, offset: 1 },
2163
- md: 2
2164
- }, {
2165
- default: withCtx(() => [
2166
- createVNode(_component_el_button, {
2167
- size: "default",
2168
- onClick: _cache[4] || (_cache[4] = ($event) => unref(refreshCrop)())
2169
- }, {
2170
- default: withCtx(() => _cache[7] || (_cache[7] = [
2171
- createTextVNode("重 置")
2172
- ])),
2173
- _: 1,
2174
- __: [7]
2175
- })
2176
- ]),
2177
- _: 1
2178
- }),
2179
- createVNode(_component_el_col, {
2180
- lg: { span: 1, offset: 7 },
2181
- md: 2
2182
- }, {
2183
- default: withCtx(() => [
2184
- createVNode(_component_el_button, {
2185
- size: "default",
2186
- type: "primary",
2187
- onClick: _cache[5] || (_cache[5] = ($event) => unref(uploadImg)())
2188
- }, {
2189
- default: withCtx(() => _cache[8] || (_cache[8] = [
2190
- createTextVNode("提 交")
2191
- ])),
2192
- _: 1,
2193
- __: [8]
2194
- })
2195
- ]),
2196
- _: 1
2197
- })
2198
- ]),
2199
- _: 1
2200
- })
2201
- ]);
2202
- };
2203
- }
2204
- });
2205
- const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-730d1d41"]]);
2206
- export {
2207
- index as default
2208
- };