@mpxjs/api-proxy 2.10.17-beta.4 → 2.10.17-beta.6

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": "@mpxjs/api-proxy",
3
- "version": "2.10.17-beta.4",
3
+ "version": "2.10.17-beta.6",
4
4
  "description": "convert miniprogram API at each end",
5
5
  "module": "src/index.js",
6
6
  "types": "@types/index.d.ts",
@@ -37,7 +37,7 @@
37
37
  },
38
38
  "homepage": "https://github.com/didi/mpx#readme",
39
39
  "dependencies": {
40
- "@mpxjs/utils": "^2.10.17",
40
+ "@mpxjs/utils": "^2.10.17-beta.0",
41
41
  "axios": "^1.7.3"
42
42
  },
43
43
  "peerDependencies": {
@@ -22,13 +22,18 @@ const getImageInfo = function (options = {}) {
22
22
  failHandle(result, fail, complete)
23
23
  return
24
24
  }
25
+ let path = ''
26
+ if (src.toLowerCase().startsWith('http')) {
27
+ path = src
28
+ }
25
29
  Image.getSize(src, (width, height) => {
26
30
  const result = {
27
31
  errMsg: 'getImageInfo:ok',
28
32
  width,
29
- height
33
+ height,
34
+ path
30
35
  }
31
- defineUnsupportedProps(result, ['path', 'orientation', 'type'])
36
+ defineUnsupportedProps(result, ['orientation', 'type'])
32
37
  successHandle(result, success, complete)
33
38
  }, (err) => {
34
39
  const result = {