"use strict";(self.webpackChunk_jbrowse_web=self.webpackChunk_jbrowse_web||[]).push([[6548],{86548:function(e,t,r){r.r(t),r.d(t,{default:function(){return w}});var n=r(41361),a=r(33028),u=r(32723),c=r(34795),s=r(9249),o=r(87371),i=r(45754),f=r(13820),p=r(56798),l=r(24201),d=r(16979),v=r(90872),h=r(26138),w=function(e){(0,i.Z)(r,e);var t=(0,f.Z)(r);function r(){var e;(0,s.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))).gcMode="content",e}return(0,o.Z)(r,[{key:"configure",value:function(){var e=(0,c.Z)((0,u.Z)().mark((function e(){var t,r;return(0,u.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,c.Z)((0,u.Z)().mark((function e(){var t;return(0,u.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,d.ObservableCreate)(function(){var s=(0,c.Z)((0,u.Z)().mark((function c(s){var o,i,f,p,d,w,g,b,Z,k,x,y,m,C,A,_,q,F,M,S,N;return(0,u.Z)().wrap((function(u){for(;;)switch(u.prev=u.next){case 0:return u.next=2,r.configure();case 2:if(i=u.sent,f=r.getConf("windowSize"),p=r.getConf("windowDelta"),d=1===f?1:f/2,w=1===f,g=e.start,b=e.end,g=Math.max(0,g-d),!((b+=d)<0||g>b)){u.next=13;break}return s.complete(),u.abrupt("return");case 13:return Z=i.getFeatures((0,a.Z)((0,a.Z)({},e),{},{start:g,end:b}),t),u.next=16,(0,l.z)(Z.pipe((0,h.q)()));case 16:for(k=u.sent,x=(null===(o=k[0])||void 0===o?void 0:o.get("seq"))||"",y=d;y<x.length-d;y+=p){m=w?x[y]:x.slice(y-d,y+d),C=0,A=0,_=0,q=(0,n.Z)(m);try{for(q.s();!(F=q.n()).done;)"c"===(M=F.value)||"C"===M?C++:"g"!==M&&"G"!==M||A++,"N"!==M&&_++}catch(c){q.e(c)}finally{q.f()}S=g,N=void 0,"content"===r.gcMode?N=(A+C)/(_||1):"skew"===r.gcMode&&(N=(A-C)/(A+C||1)),s.next(new v.SimpleFeature({uniqueId:"".concat(r.id,"_").concat(S+y),start:S+y,end:S+y+p,score:N}))}s.complete();case 20:case"end":return u.stop()}}),c)})));return function(e){return s.apply(this,arguments)}}())}},{key:"freeResources",value:function(){}}]),r}(p.BaseFeatureDataAdapter);w.capabilities=["hasLocalStats"]}}]);
//# sourceMappingURL=6548.fac0e99a.chunk.js.map