vislite 1.8.0-alpha.1 → 1.8.0

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 (56) hide show
  1. package/CHANGELOG +7 -6
  2. package/lib/BarLayout/index.es.js +113 -105
  3. package/lib/BarLayout/index.es.min.js +3 -3
  4. package/lib/Buffer/index.es.js +1 -1
  5. package/lib/Buffer/index.es.min.js +1 -1
  6. package/lib/Canvas/index.es.js +1 -1
  7. package/lib/Canvas/index.es.min.js +1 -1
  8. package/lib/Cardinal/index.es.js +1 -1
  9. package/lib/Cardinal/index.es.min.js +1 -1
  10. package/lib/Eoap/index.es.js +1 -1
  11. package/lib/Eoap/index.es.min.js +1 -1
  12. package/lib/Hermite/index.es.js +1 -1
  13. package/lib/Hermite/index.es.min.js +1 -1
  14. package/lib/MapCoordinate/index.es.js +1 -1
  15. package/lib/MapCoordinate/index.es.min.js +1 -1
  16. package/lib/Matrix4/index.es.js +1 -1
  17. package/lib/Matrix4/index.es.min.js +1 -1
  18. package/lib/Mercator/index.es.js +1 -1
  19. package/lib/Mercator/index.es.min.js +1 -1
  20. package/lib/PieLayout/index.es.js +113 -105
  21. package/lib/PieLayout/index.es.min.js +4 -4
  22. package/lib/RawCanvas/index.es.js +1 -1
  23. package/lib/RawCanvas/index.es.min.js +1 -1
  24. package/lib/SVG/index.es.js +1 -1
  25. package/lib/SVG/index.es.min.js +1 -1
  26. package/lib/Shader/index.es.js +1 -1
  27. package/lib/Shader/index.es.min.js +1 -1
  28. package/lib/Texture/index.es.js +1 -1
  29. package/lib/Texture/index.es.min.js +1 -1
  30. package/lib/TreeLayout/index.es.js +113 -105
  31. package/lib/TreeLayout/index.es.min.js +4 -4
  32. package/lib/animation/index.es.js +113 -105
  33. package/lib/animation/index.es.min.js +3 -3
  34. package/lib/assemble/index.es.js +1 -1
  35. package/lib/assemble/index.es.min.js +1 -1
  36. package/lib/getLoopColors/index.es.js +1 -1
  37. package/lib/getLoopColors/index.es.min.js +1 -1
  38. package/lib/getWebGLContext/index.es.js +1 -1
  39. package/lib/getWebGLContext/index.es.min.js +1 -1
  40. package/lib/index.umd.js +163 -155
  41. package/lib/index.umd.min.js +6 -6
  42. package/lib/initOption/index.es.js +1 -1
  43. package/lib/initOption/index.es.min.js +1 -1
  44. package/lib/mergeOption/index.es.js +1 -1
  45. package/lib/mergeOption/index.es.min.js +1 -1
  46. package/lib/move/index.es.js +1 -1
  47. package/lib/move/index.es.min.js +1 -1
  48. package/lib/rotate/index.es.js +1 -1
  49. package/lib/rotate/index.es.min.js +1 -1
  50. package/lib/ruler/index.es.js +1 -1
  51. package/lib/ruler/index.es.min.js +1 -1
  52. package/lib/scale/index.es.js +1 -1
  53. package/lib/scale/index.es.min.js +1 -1
  54. package/lib/throttle/index.es.js +51 -51
  55. package/lib/throttle/index.es.min.js +2 -2
  56. package/package.json +2 -2
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * initOption of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * initOption of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  function initOption(setOption, defaultOption) {
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * initOption of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * initOption of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  function r(r,n){for(var t in r)n[t]=r[t];return n}export{r as default};
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * mergeOption of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * mergeOption of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  var toString = Object.prototype.toString;
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * mergeOption of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * mergeOption of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  var t=Object.prototype.toString;function e(e){if(null===e||"object"!=typeof e||"[object Object]"!=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":t.call(e)}(e))return!1;if(null===Object.getPrototypeOf(e))return!0;for(var o=e;null!==Object.getPrototypeOf(o);)o=Object.getPrototypeOf(o);return Object.getPrototypeOf(e)===o}function o(t,o){!function t(o,r){for(var n in r){var c=r[n];e(c)?(o[n]||(o[n]={}),t(o[n],r[n])):o[n]=c}}(t,o)}export{o as default};
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * move of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * move of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  function move (ax, ay, d, x, y) {
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * move of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * move of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  function t(t,r,a,e,n){var u=Math.sqrt(t*t+r*r);return[t*a/u+e,r*a/u+n]}export{t as default};
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * rotate of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * rotate of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  function rotate (cx, cy, deg, x, y) {
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * rotate of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * rotate of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  function t(t,a,n,r,e){var o=Math.cos(n),s=Math.sin(n);return[(r-t)*o-(e-a)*s+t,(r-t)*s+(e-a)*o+a]}export{t as default};
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * ruler of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * ruler of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  function ruler (maxValue, minValue, num, option) {
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * ruler of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * ruler of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  function n(n,r,t,e){if(n<r){var i=r;r=n,n=i}else if(n==r)return[n];var a=function(n){for(var r=n<100&&n>-100?10:.1,t=-1,e=n;10==r?e>=-100&&e<=100:e<=-100||e>=100;)t+=1,e*=r;if(10==r)return Math.pow(10,t);for(var i="0.",a=1;a<t;a++)i+="0";return+(i+"1")}(n-r),u=Math.ceil((n-r)*a/t),f=function(t){var e=({3:2,4:5,6:5,7:5,8:10,9:10,11:10,12:10,13:15,14:15,16:15,17:15,18:20,19:20,21:20,22:20,23:25,24:25,26:25,27:25}[u+t]||u+t)/a,i=Math.floor(r/e)*e,f=[];f.push(i);for(var l=1;f[f.length-1]<n;l++)f.push(i+e*l);return f},l=f(0),o=function(){for(var n=[],t=l[l.length-1]-(null==e?void 0:e.max),i=0;i<l.length;i++)i+1<l.length&&l[i+1]-t<r||n.push(l[i]-t);return n},h=function(){for(var r=[],t=l[0]-(null==e?void 0:e.min),i=0;i<l.length&&(r[i]=l[i]-t,!(n<=r[i]));i++);return r};if(e){if("max"in e&&"min"in e&&e.max>=n&&e.min<=r){var m=function(){if(l[0]>=e.min&&l[l.length-1]<=e.max)return!0;var n=o();if(n[0]>=e.min&&n[n.length-1]<=e.max)return l=n,!0;var r=h();return r[0]>=e.min&&r[n.length-1]<=e.max?(l=r,!0):void 0};if(m())return l;for(var v=1;v<100;v++){if(l=f(v),m())return l;if(l=f(-v),m())return l}}"max"in e&&e.max>=n?e.max<l[l.length-1]&&(l=o()):"min"in e&&e.min<=r&&e.min>l[0]&&(l=h())}for(var g=0;g<l.length;g++){var s=l[g]+"";/\./.test(s)&&(/9{7,}$/.test(s)?(s=s.replace(/9{7,}$/,""),l[g]=+(s.substring(0,s.length-1)+(+s[s.length-1]+1))):/0{7,}\d$/.test(s)&&(l[g]=+s.replace(/0{7,}\d$/,"")))}return l}export{n as default};
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * scale of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * scale of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  function scale (cx, cy, times, x, y) {
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * scale of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * scale of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  function t(t,e,n,r,u){return[n*(r-t)+t,n*(u-e)+e]}export{t as default};
@@ -1,61 +1,61 @@
1
1
  /*!
2
- * throttle of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * throttle of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  /*!
6
- * throttle of OIPage v1.5.0
6
+ * throttle of OIPage v1.7.0-alpha.3
7
7
  * git+https://github.com/oi-contrib/OIPage.git
8
8
  */
9
9
 
10
- function throttle(callback, _option) {
11
-
12
- // 缺省值
13
- var option = {
14
- time: 200,
15
- keep: false,
16
- opportunity: "end"
17
- };
18
-
19
- // 校对
20
- if (_option) {
21
- for (var key in _option) {
22
- option[key] = _option[key];
23
- }
24
- }
25
-
26
- var hadInterval = false, hadClick = false, oneClick = false, arg;
27
- return function () {
28
- const _this = this;
29
- arg = arguments;
30
-
31
- // 如果前置任务都完成了
32
- if (!hadInterval) {
33
- if (option.opportunity != 'end') {
34
- callback.apply(_this, arg);
35
- }
36
- hadInterval = true;
37
-
38
- var interval = setInterval(() => {
39
- if (hadClick) {
40
- if (!option.keep) {
41
- callback.apply(_this, arg);
42
- }
43
- } else {
44
- if (option.opportunity != 'begin') {
45
- if (oneClick || option.opportunity == 'end') callback.apply(_this, arg);
46
- }
47
- hadInterval = false;
48
- oneClick = false;
49
- clearInterval(interval);
50
- }
51
- hadClick = false;
52
- }, option.time);
53
- } else {
54
- hadClick = true;
55
- oneClick = true;
56
- }
57
-
58
- };
10
+ function throttle(callback, _option) {
11
+
12
+ // 缺省值
13
+ var option = {
14
+ time: 200,
15
+ keep: false,
16
+ opportunity: "end"
17
+ };
18
+
19
+ // 校对
20
+ if (_option) {
21
+ for (var key in _option) {
22
+ option[key] = _option[key];
23
+ }
24
+ }
25
+
26
+ var hadInterval = false, hadClick = false, oneClick = false, arg;
27
+ return function () {
28
+ const _this = this;
29
+ arg = arguments;
30
+
31
+ // 如果前置任务都完成了
32
+ if (!hadInterval) {
33
+ if (option.opportunity != 'end') {
34
+ callback.apply(_this, arg);
35
+ }
36
+ hadInterval = true;
37
+
38
+ var interval = setInterval(() => {
39
+ if (hadClick) {
40
+ if (!option.keep) {
41
+ callback.apply(_this, arg);
42
+ }
43
+ } else {
44
+ if (option.opportunity != 'begin') {
45
+ if (oneClick || option.opportunity == 'end') callback.apply(_this, arg);
46
+ }
47
+ hadInterval = false;
48
+ oneClick = false;
49
+ clearInterval(interval);
50
+ }
51
+ hadClick = false;
52
+ }, option.time);
53
+ } else {
54
+ hadClick = true;
55
+ oneClick = true;
56
+ }
57
+
58
+ };
59
59
  }
60
60
 
61
61
  export { throttle as default };
@@ -1,9 +1,9 @@
1
1
  /*!
2
- * throttle of VISLite JavaScript Library v1.8.0-alpha.1
2
+ * throttle of VISLite JavaScript Library v1.8.0
3
3
  * git+https://github.com/oi-contrib/VISLite.git
4
4
  */
5
5
  /*!
6
- * throttle of OIPage v1.5.0
6
+ * throttle of OIPage v1.7.0-alpha.3
7
7
  * git+https://github.com/oi-contrib/OIPage.git
8
8
  */
9
9
  function t(t,e){var n={time:200,keep:!1,opportunity:"end"};if(e)for(var p in e)n[p]=e[p];var r,i=!1,o=!1,a=!1;return function(){const e=this;if(r=arguments,i)o=!0,a=!0;else{"end"!=n.opportunity&&t.apply(e,r),i=!0;var p=setInterval((()=>{o?n.keep||t.apply(e,r):("begin"!=n.opportunity&&(a||"end"==n.opportunity)&&t.apply(e,r),i=!1,a=!1,clearInterval(p)),o=!1}),n.time)}}}export{t as default};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vislite",
3
- "version": "1.8.0-alpha.1",
3
+ "version": "1.8.0",
4
4
  "description": "灵活、快速、简单的数据可视化交互式跨端前端库",
5
5
  "main": "./lib/index.umd.min.js",
6
6
  "typings": "./types/index.d.ts",
@@ -70,6 +70,6 @@
70
70
  "webpack-dev-server": "^4.7.4"
71
71
  },
72
72
  "dependencies": {
73
- "oipage": "^1.5.0"
73
+ "oipage": "^1.7.0-alpha.3"
74
74
  }
75
75
  }