@deck.gl/arcgis 8.9.20 → 8.9.21
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/dist.min.js +4 -3
- package/package.json +3 -2
package/dist.min.js
CHANGED
|
@@ -4,8 +4,9 @@
|
|
|
4
4
|
else if (typeof define === 'function' && define.amd) define([], factory);
|
|
5
5
|
else if (typeof exports === 'object') exports['deck'] = factory();
|
|
6
6
|
else root['deck'] = factory();})(globalThis, function () {
|
|
7
|
-
"use strict";var __exports__=(()=>{var er=Object.create;var X=Object.defineProperty;var rr=Object.getOwnPropertyDescriptor;var tr=Object.getOwnPropertyNames;var nr=Object.getPrototypeOf,ir=Object.prototype.hasOwnProperty;var E=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),ar=(e,t)=>{for(var r in t)X(e,r,{get:t[r],enumerable:!0})},K=(e,t,r,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let u of tr(t))!ir.call(e,u)&&u!==r&&X(e,u,{get:()=>t[u],enumerable:!(i=rr(t,u))||i.enumerable});return e},j=(e,t,r)=>(K(e,t,"default"),r&&K(r,t,"default")),L=(e,t,r)=>(r=e!=null?er(nr(e)):{},K(t||!e||!e.__esModule?X(r,"default",{value:e,enumerable:!0}):r,e)),or=e=>K(X({},"__esModule",{value:!0}),e);var Q=E((Lr,de)=>{de.exports=globalThis.deck});var ie=E((Pr,pe)=>{function ur(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}pe.exports=ur});var ye=E((Er,me)=>{function sr(e){if(Array.isArray(e))return e}me.exports=sr});var ge=E((Ar,we)=>{function cr(e,t){if(Symbol.iterator in Object(e)||Object.prototype.toString.call(e)==="[object Arguments]"){var r=[],i=!0,u=!1,f=void 0;try{for(var l=e[Symbol.iterator](),v;!(i=(v=l.next()).done)&&(r.push(v.value),!(t&&r.length===t));i=!0);}catch(p){u=!0,f=p}finally{try{!i&&l.return!=null&&l.return()}finally{if(u)throw f}}return r}}we.exports=cr});var ke=E((Ir,be)=>{function fr(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}be.exports=fr});var Z=E((Or,_e)=>{var lr=ye(),hr=ge(),dr=ke();function vr(e,t){return lr(e)||hr(e,t)||dr()}_e.exports=vr});var Pe=E((Dr,Se)=>{function Le(e,t,r,i,u,f,l){try{var v=e[f](l),p=v.value}catch(g){r(g);return}v.done?t(p):Promise.resolve(p).then(i,u)}function pr(e){return function(){var t=this,r=arguments;return new Promise(function(i,u){var f=e.apply(t,r);function l(p){Le(f,i,u,l,v,"next",p)}function v(p){Le(f,i,u,l,v,"throw",p)}l(void 0)})}}Se.exports=pr});var Ae=E((Tr,ae)=>{var Ee=function(e){"use strict";var t=Object.prototype,r=t.hasOwnProperty,i,u=typeof Symbol=="function"?Symbol:{},f=u.iterator||"@@iterator",l=u.asyncIterator||"@@asyncIterator",v=u.toStringTag||"@@toStringTag";function p(a,n,o,d){var c=n&&n.prototype instanceof N?n:N,w=Object.create(c.prototype),_=new k(d||[]);return w._invoke=h(a,o,_),w}e.wrap=p;function g(a,n,o){try{return{type:"normal",arg:a.call(n,o)}}catch(d){return{type:"throw",arg:d}}}var F="suspendedStart",B="suspendedYield",U="executing",M="completed",S={};function N(){}function V(){}function R(){}var x={};x[f]=function(){return this};var C=Object.getPrototypeOf,q=C&&C(C(P([])));q&&q!==t&&r.call(q,f)&&(x=q);var G=R.prototype=N.prototype=Object.create(x);V.prototype=G.constructor=R,R.constructor=V,R[v]=V.displayName="GeneratorFunction";function Y(a){["next","throw","return"].forEach(function(n){a[n]=function(o){return this._invoke(n,o)}})}e.isGeneratorFunction=function(a){var n=typeof a=="function"&&a.constructor;return n?n===V||(n.displayName||n.name)==="GeneratorFunction":!1},e.mark=function(a){return Object.setPrototypeOf?Object.setPrototypeOf(a,R):(a.__proto__=R,v in a||(a[v]="GeneratorFunction")),a.prototype=Object.create(G),a},e.awrap=function(a){return{__await:a}};function s(a){function n(c,w,_,A){var O=g(a[c],a,w);if(O.type==="throw")A(O.arg);else{var I=O.arg,H=I.value;return H&&typeof H=="object"&&r.call(H,"__await")?Promise.resolve(H.__await).then(function(z){n("next",z,_,A)},function(z){n("throw",z,_,A)}):Promise.resolve(H).then(function(z){I.value=z,_(I)},function(z){return n("throw",z,_,A)})}}var o;function d(c,w){function _(){return new Promise(function(A,O){n(c,w,A,O)})}return o=o?o.then(_,_):_()}this._invoke=d}Y(s.prototype),s.prototype[l]=function(){return this},e.AsyncIterator=s,e.async=function(a,n,o,d){var c=new s(p(a,n,o,d));return e.isGeneratorFunction(n)?c:c.next().then(function(w){return w.done?w.value:c.next()})};function h(a,n,o){var d=F;return function(w,_){if(d===U)throw new Error("Generator is already running");if(d===M){if(w==="throw")throw _;return J()}for(o.method=w,o.arg=_;;){var A=o.delegate;if(A){var O=m(A,o);if(O){if(O===S)continue;return O}}if(o.method==="next")o.sent=o._sent=o.arg;else if(o.method==="throw"){if(d===F)throw d=M,o.arg;o.dispatchException(o.arg)}else o.method==="return"&&o.abrupt("return",o.arg);d=U;var I=g(a,n,o);if(I.type==="normal"){if(d=o.done?M:B,I.arg===S)continue;return{value:I.arg,done:o.done}}else I.type==="throw"&&(d=M,o.method="throw",o.arg=I.arg)}}}function m(a,n){var o=a.iterator[n.method];if(o===i){if(n.delegate=null,n.method==="throw"){if(a.iterator.return&&(n.method="return",n.arg=i,m(a,n),n.method==="throw"))return S;n.method="throw",n.arg=new TypeError("The iterator does not provide a 'throw' method")}return S}var d=g(o,a.iterator,n.arg);if(d.type==="throw")return n.method="throw",n.arg=d.arg,n.delegate=null,S;var c=d.arg;if(!c)return n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,S;if(c.done)n[a.resultName]=c.value,n.next=a.nextLoc,n.method!=="return"&&(n.method="next",n.arg=i);else return c;return n.delegate=null,S}Y(G),G[v]="Generator",G[f]=function(){return this},G.toString=function(){return"[object Generator]"};function y(a){var n={tryLoc:a[0]};1 in a&&(n.catchLoc=a[1]),2 in a&&(n.finallyLoc=a[2],n.afterLoc=a[3]),this.tryEntries.push(n)}function b(a){var n=a.completion||{};n.type="normal",delete n.arg,a.completion=n}function k(a){this.tryEntries=[{tryLoc:"root"}],a.forEach(y,this),this.reset(!0)}e.keys=function(a){var n=[];for(var o in a)n.push(o);return n.reverse(),function d(){for(;n.length;){var c=n.pop();if(c in a)return d.value=c,d.done=!1,d}return d.done=!0,d}};function P(a){if(a){var n=a[f];if(n)return n.call(a);if(typeof a.next=="function")return a;if(!isNaN(a.length)){var o=-1,d=function c(){for(;++o<a.length;)if(r.call(a,o))return c.value=a[o],c.done=!1,c;return c.value=i,c.done=!0,c};return d.next=d}}return{next:J}}e.values=P;function J(){return{value:i,done:!0}}return k.prototype={constructor:k,reset:function(a){if(this.prev=0,this.next=0,this.sent=this._sent=i,this.done=!1,this.delegate=null,this.method="next",this.arg=i,this.tryEntries.forEach(b),!a)for(var n in this)n.charAt(0)==="t"&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=i)},stop:function(){this.done=!0;var a=this.tryEntries[0],n=a.completion;if(n.type==="throw")throw n.arg;return this.rval},dispatchException:function(a){if(this.done)throw a;var n=this;function o(O,I){return w.type="throw",w.arg=a,n.next=O,I&&(n.method="next",n.arg=i),!!I}for(var d=this.tryEntries.length-1;d>=0;--d){var c=this.tryEntries[d],w=c.completion;if(c.tryLoc==="root")return o("end");if(c.tryLoc<=this.prev){var _=r.call(c,"catchLoc"),A=r.call(c,"finallyLoc");if(_&&A){if(this.prev<c.catchLoc)return o(c.catchLoc,!0);if(this.prev<c.finallyLoc)return o(c.finallyLoc)}else if(_){if(this.prev<c.catchLoc)return o(c.catchLoc,!0)}else if(A){if(this.prev<c.finallyLoc)return o(c.finallyLoc)}else throw new Error("try statement without catch or finally")}}},abrupt:function(a,n){for(var o=this.tryEntries.length-1;o>=0;--o){var d=this.tryEntries[o];if(d.tryLoc<=this.prev&&r.call(d,"finallyLoc")&&this.prev<d.finallyLoc){var c=d;break}}c&&(a==="break"||a==="continue")&&c.tryLoc<=n&&n<=c.finallyLoc&&(c=null);var w=c?c.completion:{};return w.type=a,w.arg=n,c?(this.method="next",this.next=c.finallyLoc,S):this.complete(w)},complete:function(a,n){if(a.type==="throw")throw a.arg;return a.type==="break"||a.type==="continue"?this.next=a.arg:a.type==="return"?(this.rval=this.arg=a.arg,this.method="return",this.next="end"):a.type==="normal"&&n&&(this.next=n),S},finish:function(a){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.finallyLoc===a)return this.complete(o.completion,o.afterLoc),b(o),S}},catch:function(a){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc===a){var d=o.completion;if(d.type==="throw"){var c=d.arg;b(o)}return c}}throw new Error("illegal catch attempt")},delegateYield:function(a,n,o){return this.delegate={iterator:P(a),resultName:n,nextLoc:o},this.method==="next"&&(this.arg=i),S}},e}(typeof ae=="object"?ae.exports:{});try{regeneratorRuntime=Ee}catch{Function("r","regeneratorRuntime = r")(Ee)}});var Oe=E((Gr,Ie)=>{Ie.exports=Ae()});var je=E((jr,Ce)=>{Ce.exports=globalThis.luma});var ze=E((zr,qe)=>{function yr(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}qe.exports=yr});var Ve=E((Fr,Ne)=>{function Fe(e,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function wr(e,t,r){return t&&Fe(e.prototype,t),r&&Fe(e,r),e}Ne.exports=wr});var He=E((ne,Je)=>{(function(e,t){typeof ne=="object"&&typeof Je<"u"?t(ne):typeof define=="function"&&define.amd?define(["exports"],t):t(e.esriLoader=e.esriLoader||{})})(ne,function(e){"use strict";var t=typeof window<"u",r={Promise:t?window.Promise:void 0},i="4.21",u="next";function f(s){if(s.toLowerCase()===u)return u;var h=s&&s.match(/^(\d)\.(\d+)/);return h&&{major:parseInt(h[1],10),minor:parseInt(h[2],10)}}function l(s){return s===void 0&&(s=i),"https://js.arcgis.com/"+s+"/"}function v(s){s===void 0&&(s=i);var h=l(s),m=f(s);if(m!==u&&m.major===3){var y=m.minor<=10?"js/":"";return""+h+y+"esri/css/esri.css"}else return h+"esri/themes/light/main.css"}function p(s){var h=document.createElement("link");return h.rel="stylesheet",h.href=s,h}function g(s,h){if(h){var m=document.querySelector(h);m.parentNode.insertBefore(s,m)}else document.head.appendChild(s)}function F(s){return document.querySelector('link[href*="'+s+'"]')}function B(s){return!s||f(s)?v(s):s}function U(s,h){var m=B(s),y=F(m);return y||(y=p(m),g(y,h)),y}var M={};function S(s){var h=document.createElement("script");return h.type="text/javascript",h.src=s,h.setAttribute("data-esri-loader","loading"),h}function N(s,h,m){var y;m&&(y=V(s,m));var b=function(){h(s),s.removeEventListener("load",b,!1),y&&s.removeEventListener("error",y,!1)};s.addEventListener("load",b,!1)}function V(s,h){var m=function(y){h(y.error||new Error("There was an error attempting to load "+s.src)),s.removeEventListener("error",m,!1)};return s.addEventListener("error",m,!1),m}function R(s){s===void 0&&(s={}),M=s}function x(){return document.querySelector("script[data-esri-loader]")}function C(){var s=window.require;return s&&s.on}function q(s){s===void 0&&(s={});var h={};[M,s].forEach(function(b){for(var k in b)Object.prototype.hasOwnProperty.call(b,k)&&(h[k]=b[k])});var m=h.version,y=h.url||l(m);return new r.Promise(function(b,k){var P=x();if(P){var J=P.getAttribute("src");J!==y?k(new Error("The ArcGIS API for JavaScript is already loaded ("+J+").")):C()?b(P):N(P,b,k)}else if(C())k(new Error("The ArcGIS API for JavaScript is already loaded."));else{var a=h.css;if(a){var n=a===!0;U(n?m:a,h.insertCssBefore)}P=S(y),N(P,function(){P.setAttribute("data-esri-loader","loaded"),b(P)},k),document.body.appendChild(P)}})}function G(s){return new r.Promise(function(h,m){var y=window.require.on("error",m);window.require(s,function(){for(var b=[],k=0;k<arguments.length;k++)b[k]=arguments[k];y.remove(),h(b)})})}function Y(s,h){if(h===void 0&&(h={}),C())return G(s);var m=x(),y=m&&m.getAttribute("src");return!h.url&&y&&(h.url=y),q(h).then(function(){return G(s)})}e.utils=r,e.loadModules=Y,e.getScript=x,e.isLoaded=C,e.loadScript=q,e.setDefaultOptions=R,e.loadCss=U,Object.defineProperty(e,"__esModule",{value:!0})})});var W={};ar(W,{loadArcGISModules:()=>br});var D={},ve=L(Q());j(D,L(Q()));if(!ve.Layer)throw new Error("@deck.gl/core is not found");j(W,D);var Xe=L(ie()),Qe=L(Z()),Ze=L(Pe()),fe=L(Oe());var Re=L(ie());function De(e,t){var r=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=mr(e))||t&&e&&typeof e.length=="number"){r&&(e=r);var i=0,u=function(){};return{s:u,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(g){throw g},f:u}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
8
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}
|
|
7
|
+
"use strict";var __exports__=(()=>{var $e=Object.create;var ee=Object.defineProperty;var Ve=Object.getOwnPropertyDescriptor;var Ue=Object.getOwnPropertyNames;var Be=Object.getPrototypeOf,Je=Object.prototype.hasOwnProperty;var Y=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),He=(e,t)=>{for(var r in t)ee(e,r,{get:t[r],enumerable:!0})},Z=(e,t,r,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let u of Ue(t))!Je.call(e,u)&&u!==r&&ee(e,u,{get:()=>t[u],enumerable:!(i=Ve(t,u))||i.enumerable});return e},G=(e,t,r)=>(Z(e,t,"default"),r&&Z(r,t,"default")),U=(e,t,r)=>(r=e!=null?$e(Be(e)):{},Z(t||!e||!e.__esModule?ee(r,"default",{value:e,enumerable:!0}):r,e)),We=e=>Z(ee({},"__esModule",{value:!0}),e);var re=Y((er,Se)=>{Se.exports=globalThis.deck});var Oe=Y((pr,ve)=>{var he=function(e){"use strict";var t=Object.prototype,r=t.hasOwnProperty,i,u=typeof Symbol=="function"?Symbol:{},f=u.iterator||"@@iterator",d=u.asyncIterator||"@@asyncIterator",p=u.toStringTag||"@@toStringTag";function v(a,n,o){return Object.defineProperty(a,n,{value:o,enumerable:!0,configurable:!0,writable:!0}),a[n]}try{v({},"")}catch{v=function(n,o,l){return n[o]=l}}function g(a,n,o,l){var c=n&&n.prototype instanceof H?n:H,w=Object.create(c.prototype),L=new E(l||[]);return w._invoke=m(a,o,L),w}e.wrap=g;function C(a,n,o){try{return{type:"normal",arg:a.call(n,o)}}catch(l){return{type:"throw",arg:l}}}var z="suspendedStart",Q="suspendedYield",J="executing",F="completed",_={};function H(){}function q(){}function I(){}var T={};v(T,f,function(){return this});var N=Object.getPrototypeOf,j=N&&N(N($([])));j&&j!==t&&r.call(j,f)&&(T=j);var R=I.prototype=H.prototype=Object.create(T);q.prototype=I,v(R,"constructor",I),v(I,"constructor",q),q.displayName=v(I,p,"GeneratorFunction");function s(a){["next","throw","return"].forEach(function(n){v(a,n,function(o){return this._invoke(n,o)})})}e.isGeneratorFunction=function(a){var n=typeof a=="function"&&a.constructor;return n?n===q||(n.displayName||n.name)==="GeneratorFunction":!1},e.mark=function(a){return Object.setPrototypeOf?Object.setPrototypeOf(a,I):(a.__proto__=I,v(a,p,"GeneratorFunction")),a.prototype=Object.create(R),a},e.awrap=function(a){return{__await:a}};function h(a,n){function o(w,L,S,O){var A=C(a[w],a,L);if(A.type==="throw")O(A.arg);else{var ue=A.arg,W=ue.value;return W&&typeof W=="object"&&r.call(W,"__await")?n.resolve(W.__await).then(function(M){o("next",M,S,O)},function(M){o("throw",M,S,O)}):n.resolve(W).then(function(M){ue.value=M,S(ue)},function(M){return o("throw",M,S,O)})}}var l;function c(w,L){function S(){return new n(function(O,A){o(w,L,O,A)})}return l=l?l.then(S,S):S()}this._invoke=c}s(h.prototype),v(h.prototype,d,function(){return this}),e.AsyncIterator=h,e.async=function(a,n,o,l,c){c===void 0&&(c=Promise);var w=new h(g(a,n,o,l),c);return e.isGeneratorFunction(n)?w:w.next().then(function(L){return L.done?L.value:w.next()})};function m(a,n,o){var l=z;return function(w,L){if(l===J)throw new Error("Generator is already running");if(l===F){if(w==="throw")throw L;return V()}for(o.method=w,o.arg=L;;){var S=o.delegate;if(S){var O=y(S,o);if(O){if(O===_)continue;return O}}if(o.method==="next")o.sent=o._sent=o.arg;else if(o.method==="throw"){if(l===z)throw l=F,o.arg;o.dispatchException(o.arg)}else o.method==="return"&&o.abrupt("return",o.arg);l=J;var A=C(a,n,o);if(A.type==="normal"){if(l=o.done?F:Q,A.arg===_)continue;return{value:A.arg,done:o.done}}else A.type==="throw"&&(l=F,o.method="throw",o.arg=A.arg)}}}function y(a,n){var o=a.iterator[n.method];if(o===i){if(n.delegate=null,n.method==="throw"){if(a.iterator.return&&(n.method="return",n.arg=i,y(a,n),n.method==="throw"))return _;n.method="throw",n.arg=new TypeError("The iterator does not provide a 'throw' method")}return _}var l=C(o,a.iterator,n.arg);if(l.type==="throw")return n.method="throw",n.arg=l.arg,n.delegate=null,_;var c=l.arg;if(!c)return n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,_;if(c.done)n[a.resultName]=c.value,n.next=a.nextLoc,n.method!=="return"&&(n.method="next",n.arg=i);else return c;return n.delegate=null,_}s(R),v(R,p,"Generator"),v(R,f,function(){return this}),v(R,"toString",function(){return"[object Generator]"});function k(a){var n={tryLoc:a[0]};1 in a&&(n.catchLoc=a[1]),2 in a&&(n.finallyLoc=a[2],n.afterLoc=a[3]),this.tryEntries.push(n)}function b(a){var n=a.completion||{};n.type="normal",delete n.arg,a.completion=n}function E(a){this.tryEntries=[{tryLoc:"root"}],a.forEach(k,this),this.reset(!0)}e.keys=function(a){var n=[];for(var o in a)n.push(o);return n.reverse(),function l(){for(;n.length;){var c=n.pop();if(c in a)return l.value=c,l.done=!1,l}return l.done=!0,l}};function $(a){if(a){var n=a[f];if(n)return n.call(a);if(typeof a.next=="function")return a;if(!isNaN(a.length)){var o=-1,l=function c(){for(;++o<a.length;)if(r.call(a,o))return c.value=a[o],c.done=!1,c;return c.value=i,c.done=!0,c};return l.next=l}}return{next:V}}e.values=$;function V(){return{value:i,done:!0}}return E.prototype={constructor:E,reset:function(a){if(this.prev=0,this.next=0,this.sent=this._sent=i,this.done=!1,this.delegate=null,this.method="next",this.arg=i,this.tryEntries.forEach(b),!a)for(var n in this)n.charAt(0)==="t"&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=i)},stop:function(){this.done=!0;var a=this.tryEntries[0],n=a.completion;if(n.type==="throw")throw n.arg;return this.rval},dispatchException:function(a){if(this.done)throw a;var n=this;function o(O,A){return w.type="throw",w.arg=a,n.next=O,A&&(n.method="next",n.arg=i),!!A}for(var l=this.tryEntries.length-1;l>=0;--l){var c=this.tryEntries[l],w=c.completion;if(c.tryLoc==="root")return o("end");if(c.tryLoc<=this.prev){var L=r.call(c,"catchLoc"),S=r.call(c,"finallyLoc");if(L&&S){if(this.prev<c.catchLoc)return o(c.catchLoc,!0);if(this.prev<c.finallyLoc)return o(c.finallyLoc)}else if(L){if(this.prev<c.catchLoc)return o(c.catchLoc,!0)}else if(S){if(this.prev<c.finallyLoc)return o(c.finallyLoc)}else throw new Error("try statement without catch or finally")}}},abrupt:function(a,n){for(var o=this.tryEntries.length-1;o>=0;--o){var l=this.tryEntries[o];if(l.tryLoc<=this.prev&&r.call(l,"finallyLoc")&&this.prev<l.finallyLoc){var c=l;break}}c&&(a==="break"||a==="continue")&&c.tryLoc<=n&&n<=c.finallyLoc&&(c=null);var w=c?c.completion:{};return w.type=a,w.arg=n,c?(this.method="next",this.next=c.finallyLoc,_):this.complete(w)},complete:function(a,n){if(a.type==="throw")throw a.arg;return a.type==="break"||a.type==="continue"?this.next=a.arg:a.type==="return"?(this.rval=this.arg=a.arg,this.method="return",this.next="end"):a.type==="normal"&&n&&(this.next=n),_},finish:function(a){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.finallyLoc===a)return this.complete(o.completion,o.afterLoc),b(o),_}},catch:function(a){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc===a){var l=o.completion;if(l.type==="throw"){var c=l.arg;b(o)}return c}}throw new Error("illegal catch attempt")},delegateYield:function(a,n,o){return this.delegate={iterator:$(a),resultName:n,nextLoc:o},this.method==="next"&&(this.arg=i),_}},e}(typeof ve=="object"?ve.exports:{});try{regeneratorRuntime=he}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=he:Function("r","regeneratorRuntime = r")(he)}});var Pe=Y((mr,Ie)=>{Ie.exports=Oe()});var Ce=Y((br,Ge)=>{Ge.exports=globalThis.luma});var ze=Y((oe,xe)=>{(function(e,t){typeof oe=="object"&&typeof xe<"u"?t(oe):typeof define=="function"&&define.amd?define(["exports"],t):t(e.esriLoader=e.esriLoader||{})})(oe,function(e){"use strict";var t=typeof window<"u",r={Promise:t?window.Promise:void 0},i="4.21",u="next";function f(s){if(s.toLowerCase()===u)return u;var h=s&&s.match(/^(\d)\.(\d+)/);return h&&{major:parseInt(h[1],10),minor:parseInt(h[2],10)}}function d(s){return s===void 0&&(s=i),"https://js.arcgis.com/"+s+"/"}function p(s){s===void 0&&(s=i);var h=d(s),m=f(s);if(m!==u&&m.major===3){var y=m.minor<=10?"js/":"";return""+h+y+"esri/css/esri.css"}else return h+"esri/themes/light/main.css"}function v(s){var h=document.createElement("link");return h.rel="stylesheet",h.href=s,h}function g(s,h){if(h){var m=document.querySelector(h);m.parentNode.insertBefore(s,m)}else document.head.appendChild(s)}function C(s){return document.querySelector('link[href*="'+s+'"]')}function z(s){return!s||f(s)?p(s):s}function Q(s,h){var m=z(s),y=C(m);return y||(y=v(m),g(y,h)),y}var J={};function F(s){var h=document.createElement("script");return h.type="text/javascript",h.src=s,h.setAttribute("data-esri-loader","loading"),h}function _(s,h,m){var y;m&&(y=H(s,m));var k=function(){h(s),s.removeEventListener("load",k,!1),y&&s.removeEventListener("error",y,!1)};s.addEventListener("load",k,!1)}function H(s,h){var m=function(y){h(y.error||new Error("There was an error attempting to load "+s.src)),s.removeEventListener("error",m,!1)};return s.addEventListener("error",m,!1),m}function q(s){s===void 0&&(s={}),J=s}function I(){return document.querySelector("script[data-esri-loader]")}function T(){var s=window.require;return s&&s.on}function N(s){s===void 0&&(s={});var h={};[J,s].forEach(function(k){for(var b in k)Object.prototype.hasOwnProperty.call(k,b)&&(h[b]=k[b])});var m=h.version,y=h.url||d(m);return new r.Promise(function(k,b){var E=I();if(E){var $=E.getAttribute("src");$!==y?b(new Error("The ArcGIS API for JavaScript is already loaded ("+$+").")):T()?k(E):_(E,k,b)}else if(T())b(new Error("The ArcGIS API for JavaScript is already loaded."));else{var V=h.css;if(V){var a=V===!0;Q(a?m:V,h.insertCssBefore)}E=F(y),_(E,function(){E.setAttribute("data-esri-loader","loaded"),k(E)},b),document.body.appendChild(E)}})}function j(s){return new r.Promise(function(h,m){var y=window.require.on("error",m);window.require(s,function(){for(var k=[],b=0;b<arguments.length;b++)k[b]=arguments[b];y.remove(),h(k)})})}function R(s,h){if(h===void 0&&(h={}),T())return j(s);var m=I(),y=m&&m.getAttribute("src");return!h.url&&y&&(h.url=y),N(h).then(function(){return j(s)})}e.utils=r,e.loadModules=R,e.getScript=I,e.isLoaded=T,e.loadScript=N,e.setDefaultOptions=q,e.loadCss=Q,Object.defineProperty(e,"__esModule",{value:!0})})});var X={};He(X,{loadArcGISModules:()=>Xe});var P={},Ae=U(re());G(P,U(re()));if(!Ae.Layer)throw new Error("@deck.gl/core is not found");G(X,P);function K(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function se(e){if(Array.isArray(e))return e}function ce(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var i=[],u=!0,f=!1,d,p;try{for(r=r.call(e);!(u=(d=r.next()).done)&&(i.push(d.value),!(t&&i.length===t));u=!0);}catch(v){f=!0,p=v}finally{try{!u&&r.return!=null&&r.return()}finally{if(f)throw p}}return i}}function te(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,i=new Array(t);r<t;r++)i[r]=e[r];return i}function fe(e,t){if(e){if(typeof e=="string")return te(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return te(e,t)}}function le(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
8
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function x(e,t){return se(e)||ce(e,t)||fe(e,t)||le()}function Ee(e,t,r,i,u,f,d){try{var p=e[f](d),v=p.value}catch(g){r(g);return}p.done?t(v):Promise.resolve(v).then(i,u)}function de(e){return function(){var t=this,r=arguments;return new Promise(function(i,u){var f=e.apply(t,r);function d(v){Ee(f,i,u,d,p,"next",v)}function p(v){Ee(f,i,u,d,p,"throw",v)}d(void 0)})}}var ke=U(Pe());function De(e,t){var r=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=Ye(e))||t&&e&&typeof e.length=="number"){r&&(e=r);var i=0,u=function(){};return{s:u,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(g){throw g},f:u}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
9
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var f=!0,d=!1,p;return{s:function(){r=r.call(e)},n:function(){var g=r.next();return f=g.done,g},e:function(g){d=!0,p=g},f:function(){try{!f&&r.return!=null&&r.return()}finally{if(d)throw p}}}}function Ye(e,t){if(e){if(typeof e=="string")return Te(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Te(e,t)}}function Te(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,i=new Array(t);r<t;r++)i[r]=e[r];return i}var Re={layers:{},layerFilter:{},parameters:{},effects:{},pickingRadius:{},onBeforeRender:{},onAfterRender:{},onClick:{},onHover:{},onDragStart:{},onDrag:{},onDragEnd:{},onError:{},debug:{},drawPickingColors:{},getCursor:{},getTooltip:{}};function pe(e){var t=e.createSubclass({properties:Re,constructor:function(){var i=this;this._callbacks={},this.watch(Object.keys(Re),function(u,f,d){i.emit("change",K({},d,u))})},on:function(i,u){this._callbacks[i]=this._callbacks[i]||[],this._callbacks[i].push(u)},emit:function(i,u){var f=this._callbacks[i];if(f){var d=De(f),p;try{for(d.s();!(p=d.n()).done;){var v=p.value;v(u)}}catch(g){d.e(g)}finally{d.f()}}},toJSON:function(){var i={},u=De(this.keys()),f;try{for(u.s();!(f=u.n()).done;){var d=f.value;this[d]!==void 0&&(i[d]=this[d])}}catch(p){u.e(p)}finally{u.f()}return i}});return t}function me(e,t,r){return t.createSubclass({properties:{deck:{},blendMode:{},effect:{}},constructor:function(){this.deck=new e},createLayerView:function(u){return u.type==="2d"?new r({view:u,layer:this}):(console.error("DeckLayer does not support SceneView at the moment. Use DeckRenderer instead."),null)}})}var je=U(re()),D=U(Ce());function ne(e){var t=this;(0,D.instrumentGLContext)(e),this.buffer=new D.Buffer(e,new Int8Array([-1,-1,1,-1,-1,1,1,1])),this.model=new D.Model(e,{vs:`
|
|
9
10
|
attribute vec2 a_pos;
|
|
10
11
|
varying vec2 v_texcoord;
|
|
11
12
|
void main(void) {
|
|
@@ -21,6 +22,6 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
21
22
|
rgba.rgb *= rgba.a;
|
|
22
23
|
gl_FragColor = rgba;
|
|
23
24
|
}
|
|
24
|
-
`,attributes:{a_pos:this.buffer},vertexCount:4,drawMode:5}),this.deckFbo=new
|
|
25
|
+
`,attributes:{a_pos:this.buffer},vertexCount:4,drawMode:5}),this.deckFbo=new D.Framebuffer(e,{width:1,height:1}),this.deckInstance=new je.Deck({viewState:{},controller:!1,gl:e,parameters:{depthTest:!0},_framebuffer:this.deckFbo,width:null,height:null,_customRender:function(i){i==="arcgis"?t.deckInstance._drawLayers(i):t.redraw()}})}function ie(e){var t=this,r=e.gl,i=e.width,u=e.height,f=e.viewState,d=r.getParameter(36006),p=window.devicePixelRatio;i=Math.round(i*p),u=Math.round(u*p),this.deckFbo.resize({width:i,height:u}),this.deckInstance.setProps({viewState:f}),this.deckInstance.redraw("arcgis"),(0,D.withParameters)(r,{blend:!0,blendFunc:[1,771],framebuffer:d,viewport:[0,0,i,u]},function(){t.model.setUniforms({u_texture:t.deckFbo}).draw()})}function ae(){var e,t,r,i;(e=this.deckInstance)===null||e===void 0||e.finalize(),this.deckInstance=null,(t=this.model)===null||t===void 0||t.delete(),(r=this.buffer)===null||r===void 0||r.delete(),(i=this.deckFbo)===null||i===void 0||i.delete()}function ye(e){return e.createSubclass({properties:{deckgl:{},deckFbo:{},model:{},buffer:{}},attach:function(){var r=this,i=this.context;ne.call(this,i),this.layer.deck.on("change",function(u){return r.deckInstance.setProps(u)}),this.deckInstance.setProps(this.layer.deck.toJSON())},redraw:function(){this.requestRender()},detach:function(){ae.call(this)},render:function(r){var i=x(this.view.state.size,2),u=i[0],f=i[1],d=r.state;ie.call(this,{gl:r.context,width:u,height:f,viewState:{latitude:this.view.center.latitude,longitude:this.view.center.longitude,zoom:this.view.featuresTilingScheme.scaleToLevel(d.scale),bearing:-d.rotation,pitch:0}})}})}function we(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Me(e,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function ge(e,t,r){return t&&Me(e.prototype,t),r&&Me(e,r),e}function Ke(e,t){var r=Math.sqrt(1+Math.pow(t,2)),i=e/2/180*Math.PI;return r/2/Math.tan(i)}function be(e,t){var r=function(){function i(u,f){we(this,i),this.view=u,this.deck=new e(f)}return ge(i,[{key:"setup",value:function(f){var d=this,p=f.gl;ne.call(this,p),this.deck.on("change",function(v){return d.deckInstance.setProps(v)}),this.deckInstance.setProps(this.deck.toJSON())}},{key:"dispose",value:function(){ae.call(this)}},{key:"redraw",value:function(){t.requestRender(this.view)}},{key:"render",value:function(f){var d=x(this.view.size,2),p=d[0],v=d[1];ie.call(this,{gl:f.gl,width:p,height:v,viewState:{latitude:this.view.center.latitude,longitude:this.view.center.longitude,altitude:Ke(this.view.camera.fov,p/v),zoom:this.view.zoom,bearing:this.view.camera.heading,pitch:this.view.camera.tilt}})}}]),i}();return r}var Le=U(ze());function Fe(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(u){return Object.getOwnPropertyDescriptor(e,u).enumerable})),r.push.apply(r,i)}return r}function qe(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Fe(Object(r),!0).forEach(function(i){K(e,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Fe(Object(r)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(r,i))})}return e}var B=null;function Xe(e,t){return _e.apply(this,arguments)}function _e(){return _e=de(ke.default.mark(function e(t,r){var i;return ke.default.wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return i=Array.isArray(t)?null:t,f.next=3,Qe(i,r);case 3:if(!Array.isArray(t)){f.next=5;break}return f.abrupt("return",(0,Le.loadModules)(t,r).then(function(d){return qe(qe({},B),{},{modules:d})}));case 5:return f.abrupt("return",B);case 6:case"end":return f.stop()}},e)})),_e.apply(this,arguments)}function Qe(e,t){if(B)return B;if(e){var r=e.layers.Layer,i=e.core.Accessor,u=e.views["2d"].layers.BaseLayerViewGL2D,f=e.views["3d"].externalRenderers;return Ne(r,i,u,f)}return(0,Le.loadModules)(["esri/layers/Layer","esri/core/Accessor","esri/views/2d/layers/BaseLayerViewGL2D","esri/views/3d/externalRenderers"],t).then(function(d){var p=x(d,4),v=p[0],g=p[1],C=p[2],z=p[3];return Ne(v,g,C,z)})}function Ne(e,t,r,i){var u=pe(t),f=ye(r),d=me(u,e,f),p=be(u,i);return B={DeckLayer:d,DeckRenderer:p},B}return We(X);})();
|
|
25
26
|
return __exports__;
|
|
26
27
|
});
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@deck.gl/arcgis",
|
|
3
3
|
"description": "Use deck.gl as a custom ArcGIS API for JavaScript layer",
|
|
4
4
|
"license": "MIT",
|
|
5
|
-
"version": "8.9.
|
|
5
|
+
"version": "8.9.21",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
8
8
|
},
|
|
@@ -35,7 +35,8 @@
|
|
|
35
35
|
"@luma.gl/core": "^8.0.0"
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
|
+
"@babel/runtime": "^7.0.0",
|
|
38
39
|
"esri-loader": "^3.3.0"
|
|
39
40
|
},
|
|
40
|
-
"gitHead": "
|
|
41
|
+
"gitHead": "d5dca2e143dd9cf4e204a4473d67de14e4e7f2ee"
|
|
41
42
|
}
|