icn3d 3.28.0 → 3.28.2

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/icn3d.js CHANGED
@@ -40790,7 +40790,7 @@ class AddTrack {
40790
40790
 
40791
40791
  async showMsaTracks(chainid, seqFirst, trackTitleArray, trackSeqArray, startpos, type, acc2exons) { let ic = this.icn3d; ic.icn3dui;
40792
40792
  //ic.startposGiSeq = undefined;
40793
- for(let i = 0, il = ic.giSeq[chainid].length; i < il; ++i) {
40793
+ for(let i = 0, il = ic.chainsSeq[chainid].length; i < il; ++i) {
40794
40794
  //let pos =(i >= ic.matchedPos[chainid] && i - ic.matchedPos[chainid] < ic.chainsSeq, [chainid].length) ? ic.chainsSeq[chainid][i - ic.matchedPos[chainid]].resi : ic.baseResi[chainid] + 1 + i;
40795
40795
  let pos = ic.ParserUtilsCls.getResi(chainid, i);
40796
40796
 
@@ -40925,11 +40925,11 @@ class AddTrack {
40925
40925
  let exonArray = (acc2exons) ? acc2exons[trackTitleArray[j]] : undefined;
40926
40926
  this.showNewTrack(chainid, title, text, undefined, undefined, type, undefined, bMsa, fromArray, toArray, seqStartLen, exonArray);
40927
40927
  }
40928
-
40928
+ /*
40929
40929
  // set color for the master seq
40930
40930
  if(trackSeqArray.length > 0) {
40931
- if(ic.queryresi2score === undefined) ic.queryresi2score = {};
40932
- if(ic.queryresi2score[chainid] === undefined) ic.queryresi2score[chainid] = {};
40931
+ if(ic.queryresi2score === undefined) ic.queryresi2score = {}
40932
+ if(ic.queryresi2score[chainid] === undefined) ic.queryresi2score[chainid] = {}
40933
40933
 
40934
40934
  let nSeq = trackSeqArray.length;
40935
40935
  for(let resi in resi2cntSameRes) {
@@ -40960,6 +40960,7 @@ class AddTrack {
40960
40960
 
40961
40961
  //me.htmlCls.clickMenuCls.setLogCmd('color align custom | ' + chainid + ' | range ' + start + '_' + end + ' | ' + resiScoreStr, true);
40962
40962
  }
40963
+ */
40963
40964
  }
40964
40965
 
40965
40966
  processAccList(acclist) { let ic = this.icn3d; ic.icn3dui;
@@ -40994,6 +40995,8 @@ class AddTrack {
40994
40995
  }
40995
40996
 
40996
40997
  async addExonTracks(chainid, geneid, startpos, type) { let ic = this.icn3d, me = ic.icn3dui;
40998
+ let thisClass = this;
40999
+
40997
41000
  let seqFirst, trackTitleArray = [], trackSeqArray = [];
40998
41001
 
40999
41002
  // get acclist from geneid
@@ -41102,12 +41105,14 @@ class AddTrack {
41102
41105
  ++j;
41103
41106
  }
41104
41107
 
41105
- await this.showMsaTracks(chainid, seqFirst, trackTitleArray, trackSeqArray, startpos, type, acc2exons);
41108
+ await thisClass.showMsaTracks(chainid, seqFirst, trackTitleArray, trackSeqArray, startpos, type, acc2exons);
41106
41109
 
41107
41110
  me.htmlCls.clickMenuCls.setLogCmd("add exon track | chainid " + chainid + " | geneid " + geneid + " | startpos " + startpos + " | type " + type, true);
41108
41111
  }
41109
41112
 
41110
41113
  async addMsaTracks(chainid, startpos, type, fastaList) { let ic = this.icn3d, me = ic.icn3dui;
41114
+ let thisClass = this;
41115
+
41111
41116
  let seqFirst, trackTitleArray = [], trackSeqArray = [];
41112
41117
 
41113
41118
  let fastaArray = fastaList.split('>');
@@ -41132,8 +41137,8 @@ class AddTrack {
41132
41137
  trackSeqArray.push(seq);
41133
41138
  }
41134
41139
 
41135
- await this.showMsaTracks(chainid, seqFirst, trackTitleArray, trackSeqArray, startpos, type);
41136
-
41140
+ await thisClass.showMsaTracks(chainid, seqFirst, trackTitleArray, trackSeqArray, startpos, type);
41141
+
41137
41142
  me.htmlCls.clickMenuCls.setLogCmd("add msa track | chainid " + chainid + " | startpos " + startpos + " | type " + type + " | fastaList " + fastaList , true);
41138
41143
  }
41139
41144
  }
@@ -41982,8 +41987,8 @@ class ShowAnno {
41982
41987
  // get Gene info from uniprot
41983
41988
  url = "https://rest.uniprot.org/uniprotkb/search?format=json&fields=xref_geneid,gene_names&query=" + structure;
41984
41989
  let geneData = await me.getAjaxPromise(url, 'json');
41985
- let geneId = (geneData.results[0] && geneData.results[0].uniProtKBCrossReferences[0]) ? geneData.results[0].uniProtKBCrossReferences[0].id : undefined;
41986
- let geneSymbol = (geneData.results[0] && geneData.results[0].genes[0] && geneData.results[0].genes[0].geneName) ? geneData.results[0].genes[0].geneName.value : undefined;
41990
+ let geneId = (geneData.results[0] && geneData.results[0].uniProtKBCrossReferences && geneData.results[0].uniProtKBCrossReferences[0]) ? geneData.results[0].uniProtKBCrossReferences[0].id : undefined;
41991
+ let geneSymbol = (geneData.results[0] && geneData.results[0].genes && geneData.results[0].genes[0] && geneData.results[0].genes[0].geneName) ? geneData.results[0].genes[0].geneName.value : undefined;
41987
41992
  ic.chainsGene[chnid] = {geneId: geneId, geneSymbol: geneSymbol};
41988
41993
  }
41989
41994
  }