"use strict";(self.webpackChunk_jbrowse_web=self.webpackChunk_jbrowse_web||[]).push([[1658],{81658:function(e,t,r){r.r(t),r.d(t,{default:function(){return h}});var n=r(33028),a=r(32723),u=r(34795),c=r(9249),i=r(87371),s=r(45754),o=r(13820),f=r(2646),p=r(56218),l=r(93824),d=r(27664),w=r(66043),h=function(e){(0,s.Z)(r,e);var t=(0,o.Z)(r);function r(){var e;(0,c.Z)(this,r);for(var n=arguments.length,a=new Array(n),u=0;u<n;u++)a[u]=arguments[u];return(e=t.call.apply(t,[this].concat(a))).windowSize=1e3,e.windowDelta=1e3,e.gcMode="content",e}return(0,i.Z)(r,[{key:"configure",value:function(){var e=(0,u.Z)((0,a.Z)().mark((function e(){var t,r;return(0,a.Z)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,null===(t=this.getSubAdapter)||void 0===t?void 0:t.call(this,this.getConf("sequenceAdapter"));case 2:if(r=e.sent){e.next=5;break}throw new Error("Error getting subadapter");case 5:return e.abrupt("return",r.dataAdapter);case 6:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"getRefNames",value:function(){var e=(0,u.Z)((0,a.Z)().mark((function e(){var t;return(0,a.Z)().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.configure();case 2:return t=e.sent,e.abrupt("return",t.getRefNames());case 4:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"getFeatures",value:function(e,t){var r=this;return(0,l.ObservableCreate)(function(){var c=(0,u.Z)((0,a.Z)().mark((function u(c){var i,s,o,f,l,h,v,g,b,Z,k,x,m,y,S,z,A;return(0,a.Z)().wrap((function(a){for(;;)switch(a.prev=a.next){case 0:return a.next=2,r.configure();case 2:if(s=a.sent,o=1===r.windowSize?1:r.windowSize/2,f=1===r.windowSize,l=e.start,h=e.end,l=Math.max(0,l-o),!((h+=o)<0||l>h)){a.next=11;break}return c.complete(),a.abrupt("return");case 11:return v=s.getFeatures((0,n.Z)((0,n.Z)({},e),{},{start:l,end:h}),t),a.next=14,(0,p.z)(v.pipe((0,w.q)()));case 14:for(g=a.sent,b=(null===(i=g[0])||void 0===i?void 0:i.get("seq"))||"",Z=o;Z<b.length-o;Z+=r.windowDelta){for(k=f?b[Z]:b.slice(Z-o,Z+o),x=0,m=0,y=0,S=0;S<k.length;S++)"c"===k[S]||"C"===k[S]?x++:"g"!==k[S]&&"G"!==k[S]||m++,"N"!==k[S]&&y++;z=l,A=void 0,"content"===r.gcMode?A=(m+x)/(y||1):"skew"===r.gcMode&&(A=(m-x)/(m+x||1)),c.next(new d.SimpleFeature({uniqueId:"".concat(r.id,"_").concat(z+Z),start:z+Z,end:z+Z+r.windowDelta,score:A}))}c.complete();case 18:case"end":return a.stop()}}),u)})));return function(e){return c.apply(this,arguments)}}())}},{key:"freeResources",value:function(){}}]),r}(f.BaseFeatureDataAdapter);h.capabilities=["hasLocalStats"]}}]);
//# sourceMappingURL=1658.695f9594.chunk.js.map