@idmwx/idmui-gl4 2.9.6 → 2.9.7

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.
@@ -1,6 +1,6 @@
1
- import { m as h } from "./chunk-T4JIPPZO-d17cc72e.js";
2
- import "./chunk-3VYIPD3A-7c601d45.js";
3
- import "./index-3e93876c.js";
1
+ import { d as l } from "./chunk-ANSXOGKI-7a84edd4.js";
2
+ import "./chunk-3VYIPD3A-02984ebb.js";
3
+ import "./index-7aaf33ab.js";
4
4
  import "axios";
5
5
  import "vuetify";
6
6
  import "vue";
@@ -13,7 +13,9 @@ import "@turf/turf";
13
13
  import "@idm-plugin/tag2";
14
14
  import "@mapbox/sphericalmercator";
15
15
  import "@idm-plugin/tag";
16
+ import "shpjs";
17
+ import "gif.js";
16
18
  import "@idm-plugin/aliclient";
17
19
  export {
18
- h as toBlob
20
+ l as rasterize
19
21
  };
@@ -1,6 +1,6 @@
1
- import { d as j } from "./chunk-ANSXOGKI-7cac2c97.js";
2
- import "./chunk-3VYIPD3A-7c601d45.js";
3
- import "./index-3e93876c.js";
1
+ import { m as k } from "./chunk-T4JIPPZO-3571eaa0.js";
2
+ import "./chunk-3VYIPD3A-02984ebb.js";
3
+ import "./index-7aaf33ab.js";
4
4
  import "axios";
5
5
  import "vuetify";
6
6
  import "vue";
@@ -13,7 +13,9 @@ import "@turf/turf";
13
13
  import "@idm-plugin/tag2";
14
14
  import "@mapbox/sphericalmercator";
15
15
  import "@idm-plugin/tag";
16
+ import "shpjs";
17
+ import "gif.js";
16
18
  import "@idm-plugin/aliclient";
17
19
  export {
18
- j as rasterize
20
+ k as toBlob
19
21
  };
@@ -1,5 +1,5 @@
1
- import { W as c } from "./chunk-3VYIPD3A-7c601d45.js";
2
- import "./index-3e93876c.js";
1
+ import { W as g } from "./chunk-3VYIPD3A-02984ebb.js";
2
+ import "./index-7aaf33ab.js";
3
3
  import "axios";
4
4
  import "vuetify";
5
5
  import "vue";
@@ -12,7 +12,9 @@ import "@turf/turf";
12
12
  import "@idm-plugin/tag2";
13
13
  import "@mapbox/sphericalmercator";
14
14
  import "@idm-plugin/tag";
15
+ import "shpjs";
16
+ import "gif.js";
15
17
  import "@idm-plugin/aliclient";
16
18
  export {
17
- c as toCanvas
19
+ g as toCanvas
18
20
  };
@@ -1,6 +1,6 @@
1
- import { d as u } from "./chunk-ANSXOGKI-7cac2c97.js";
2
- import { l as g } from "./index-3e93876c.js";
3
- import "./chunk-3VYIPD3A-7c601d45.js";
1
+ import { d as u } from "./chunk-ANSXOGKI-7a84edd4.js";
2
+ import { l as g } from "./index-7aaf33ab.js";
3
+ import "./chunk-3VYIPD3A-02984ebb.js";
4
4
  import "axios";
5
5
  import "vuetify";
6
6
  import "vue";
@@ -13,20 +13,22 @@ import "@turf/turf";
13
13
  import "@idm-plugin/tag2";
14
14
  import "@mapbox/sphericalmercator";
15
15
  import "@idm-plugin/tag";
16
+ import "shpjs";
17
+ import "gif.js";
16
18
  import "@idm-plugin/aliclient";
17
- async function U(i, l) {
18
- let { scale: m = 1, width: o, height: s, meta: e = {} } = l, n = Number.isFinite(o), p = Number.isFinite(s), d = Number.isFinite(m) && m !== 1 || n || p;
19
+ async function S(i, l) {
20
+ let { scale: m = 1, width: o, height: p, meta: e = {} } = l, s = Number.isFinite(o), n = Number.isFinite(p), d = Number.isFinite(m) && m !== 1 || s || n;
19
21
  if (g() && d)
20
22
  return await u(i, { ...l, format: "png", quality: 1, meta: e });
21
23
  let t = new Image();
22
- if (t.decoding = "sync", t.loading = "eager", t.src = i, await t.decode(), n && p)
23
- t.style.width = `${o}px`, t.style.height = `${s}px`;
24
- else if (n) {
24
+ if (t.decoding = "sync", t.loading = "eager", t.src = i, await t.decode(), s && n)
25
+ t.style.width = `${o}px`, t.style.height = `${p}px`;
26
+ else if (s) {
25
27
  let r = Number.isFinite(e.w0) ? e.w0 : t.naturalWidth, a = Number.isFinite(e.h0) ? e.h0 : t.naturalHeight, h = o / Math.max(1, r);
26
28
  t.style.width = `${o}px`, t.style.height = `${Math.round(a * h)}px`;
27
- } else if (p) {
28
- let r = Number.isFinite(e.w0) ? e.w0 : t.naturalWidth, a = Number.isFinite(e.h0) ? e.h0 : t.naturalHeight, h = s / Math.max(1, a);
29
- t.style.height = `${s}px`, t.style.width = `${Math.round(r * h)}px`;
29
+ } else if (n) {
30
+ let r = Number.isFinite(e.w0) ? e.w0 : t.naturalWidth, a = Number.isFinite(e.h0) ? e.h0 : t.naturalHeight, h = p / Math.max(1, a);
31
+ t.style.height = `${p}px`, t.style.width = `${Math.round(r * h)}px`;
30
32
  } else {
31
33
  let r = Math.round(t.naturalWidth * m), a = Math.round(t.naturalHeight * m);
32
34
  if (t.style.width = `${r}px`, t.style.height = `${a}px`, typeof i == "string" && i.startsWith("data:image/svg+xml"))
@@ -39,6 +41,6 @@ async function U(i, l) {
39
41
  return t;
40
42
  }
41
43
  export {
42
- U as toImg,
43
- U as toSvg
44
+ S as toImg,
45
+ S as toSvg
44
46
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@idmwx/idmui-gl4",
3
3
  "private": false,
4
- "version": "2.9.6",
4
+ "version": "2.9.7",
5
5
  "description": "idm webgl4",
6
6
  "type": "module",
7
7
  "keywords": [
@@ -31,10 +31,7 @@
31
31
  "@idm-plugin/aliclient": "^0.0.7",
32
32
  "@mapbox/sphericalmercator": "^1.2.0",
33
33
  "@zumer/snapdom": "^2.0.1",
34
- "gif.js": "^0.2.0",
35
34
  "js-md5": "^0.7.3",
36
- "jszip": "^3.10.1",
37
- "shpjs": "^6.2.0",
38
35
  "vue": "^3.2.36"
39
36
  },
40
37
  "peerDependencies": {
@@ -46,8 +43,11 @@
46
43
  "@turf/turf": "^6.5.0",
47
44
  "axios": "^1.3.5",
48
45
  "echarts": "^6.0.0",
46
+ "gif.js": "^0.2.0",
47
+ "jszip": "^3.10.1",
49
48
  "mapbox-gl": "^2.15.0",
50
49
  "moment": "^2.29.4",
50
+ "shpjs": "^6.2.0",
51
51
  "vue-i18n": "^11.1.11",
52
52
  "vuetify": "^3.0.0"
53
53
  },
@@ -70,11 +70,14 @@
70
70
  "eslint-define-config": "^1.15.0",
71
71
  "eslint-plugin-prettier": "^4.2.1",
72
72
  "eslint-plugin-vue": "^9.9.0",
73
+ "gif.js": "^0.2.0",
74
+ "jszip": "^3.10.1",
73
75
  "lint-staged": "^13.1.2",
74
76
  "mapbox-gl": "2.15.0",
75
77
  "moment": "^2.29.4",
76
78
  "prettier": "^2.8.4",
77
79
  "sass": "^1.58.3",
80
+ "shpjs": "^6.2.0",
78
81
  "simple-git-hooks": "^2.8.1",
79
82
  "stylelint": "^15.2.0",
80
83
  "typescript": "^4.9.3",
@@ -1,29 +0,0 @@
1
- import { m as d } from "./chunk-T4JIPPZO-d17cc72e.js";
2
- import { W as f } from "./chunk-3VYIPD3A-7c601d45.js";
3
- import "./index-3e93876c.js";
4
- import "axios";
5
- import "vuetify";
6
- import "vue";
7
- import "mapbox-gl";
8
- import "moment";
9
- import "@idm-plugin/geo";
10
- import "@idm-plugin/meteo";
11
- import "echarts";
12
- import "@turf/turf";
13
- import "@idm-plugin/tag2";
14
- import "@mapbox/sphericalmercator";
15
- import "@idm-plugin/tag";
16
- import "@idm-plugin/aliclient";
17
- async function q(p, o) {
18
- let a = ((o == null ? void 0 : o.format) || (o == null ? void 0 : o.type) || "").toLowerCase(), e = a === "jpg" ? "jpeg" : a || "png", t = (o == null ? void 0 : o.filename) || `snapdom.${e}`, r = { ...o || {}, format: e, type: e };
19
- if (r.dpr = 1, e === "svg") {
20
- let l = await d(p, { ...r, type: "svg" }), n = URL.createObjectURL(l), i = document.createElement("a");
21
- i.href = n, i.download = t, i.click(), URL.revokeObjectURL(n);
22
- return;
23
- }
24
- let c = await f(p, r), m = document.createElement("a");
25
- m.href = c.toDataURL(`image/${e}`, o == null ? void 0 : o.quality), m.download = t, m.click();
26
- }
27
- export {
28
- q as download
29
- };