uni-canvas-image 1.1.1 → 1.1.2

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "uni-canvas-image",
3
- "version": "1.1.1",
3
+ "version": "1.1.2",
4
4
  "description": "租房项目使用uniapp canvas合并图片",
5
5
  "main": "src/index.js",
6
6
  "type": "module",
@@ -1,6 +1,11 @@
1
1
  import { getImageInfo, drawImageToCanvas } from '../common/index'
2
2
 
3
- export async function attractImage(params) {
3
+ /**
4
+ *
5
+ * @param {Object Array} data 房源数据数组
6
+ * @returns {String} 处理后的图片URL
7
+ */
8
+ async function attractImage(params) {
4
9
  return new Promise(async (resolve, reject) => {
5
10
  const { data, canvasId, api } = params
6
11
  const staticInfo = [
@@ -32,3 +37,5 @@ export async function attractImage(params) {
32
37
  resolve(url)
33
38
  })
34
39
  }
40
+
41
+ export default attractImage