icn3d 3.25.16 → 3.25.18
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 +32 -9
- package/icn3d.min.js +1 -1
- package/icn3d.module.js +32 -9
- package/package.json +1 -1
package/icn3d.module.js
CHANGED
|
@@ -33156,7 +33156,8 @@ class Alternate {
|
|
|
33156
33156
|
ic.drawCls.draw();
|
|
33157
33157
|
|
|
33158
33158
|
ic.bShowHighlight = true;
|
|
33159
|
-
ic.opts['rotationcenter'] = 'molecule center';
|
|
33159
|
+
//ic.opts['rotationcenter'] = 'molecule center';
|
|
33160
|
+
ic.opts['rotationcenter'] = 'highlight center';
|
|
33160
33161
|
}
|
|
33161
33162
|
|
|
33162
33163
|
alternateWrapper() { let ic = this.icn3d; ic.icn3dui;
|
|
@@ -43081,12 +43082,10 @@ class ShowSeq {
|
|
|
43081
43082
|
prevStrand = currStrand;
|
|
43082
43083
|
}
|
|
43083
43084
|
|
|
43084
|
-
// 2. remove strands with less than 3 residues
|
|
43085
|
+
// 2. remove strands with less than 3 residues except G strand
|
|
43085
43086
|
for(let il = strandArray.length, i = il - 1; i >= 0; --i) {
|
|
43086
|
-
if(strandArray[i].endRefnum - strandArray[i].startRefnum + 1 < 3) { // remove the strand
|
|
43087
|
+
if(strandArray[i].strand.substr(0, 1) != 'G' && strandArray[i].endRefnum - strandArray[i].startRefnum + 1 < 3) { // remove the strand
|
|
43087
43088
|
if(i != il - 1) { // modify
|
|
43088
|
-
// strandArray[i + 1].loopResCnt += strandArray[i].loopResCnt + strandArray[i].endRefnum - strandArray[i].startRefnum + 1;
|
|
43089
|
-
|
|
43090
43089
|
strandArray[i + 1].loopResCnt += strandArray[i].loopResCnt + parseInt(strandArray[i].endResi) - parseInt(strandArray[i].startResi) + 1;
|
|
43091
43090
|
}
|
|
43092
43091
|
|
|
@@ -43113,6 +43112,8 @@ class ShowSeq {
|
|
|
43113
43112
|
refnumStr = ic.refnumCls.rmStrandFromRefnumlabel(refnumLabel);
|
|
43114
43113
|
currRefnum = parseInt(refnumStr);
|
|
43115
43114
|
refnumLabelNoPostfix = currStrand + currRefnum;
|
|
43115
|
+
|
|
43116
|
+
currStrand = refnumLabel.replace(new RegExp(refnumStr,'g'), '');
|
|
43116
43117
|
|
|
43117
43118
|
let firstChar = refnumLabel.substr(0,1);
|
|
43118
43119
|
if(!bStart && (firstChar == ' ' || firstChar == 'A' || firstChar == 'B')) { // start of a new IG domain
|
|
@@ -43129,7 +43130,26 @@ class ShowSeq {
|
|
|
43129
43130
|
refnumLabel = undefined;
|
|
43130
43131
|
}
|
|
43131
43132
|
else {
|
|
43132
|
-
|
|
43133
|
+
let bBefore = false, bInRange= false, bAfter = false;
|
|
43134
|
+
// 100, 100A
|
|
43135
|
+
if(parseInt(currResi) == parseInt(strandArray[strandCnt].startResi) && currResi != strandArray[strandCnt].startResi) {
|
|
43136
|
+
bBefore = currResi < strandArray[strandCnt].startResi;
|
|
43137
|
+
}
|
|
43138
|
+
else {
|
|
43139
|
+
bBefore = parseInt(currResi) < parseInt(strandArray[strandCnt].startResi);
|
|
43140
|
+
}
|
|
43141
|
+
|
|
43142
|
+
// 100, 100A
|
|
43143
|
+
if(parseInt(currResi) == parseInt(strandArray[strandCnt].endResi) && currResi != strandArray[strandCnt].endResi) {
|
|
43144
|
+
bAfter = currResi > strandArray[strandCnt].endResi;
|
|
43145
|
+
}
|
|
43146
|
+
else {
|
|
43147
|
+
bAfter = parseInt(currResi) > parseInt(strandArray[strandCnt].endResi);
|
|
43148
|
+
}
|
|
43149
|
+
|
|
43150
|
+
bInRange = (!bBefore && !bAfter) ? true : false;
|
|
43151
|
+
|
|
43152
|
+
if(bBefore) {
|
|
43133
43153
|
ic.residIgLoop[residueid] = 1;
|
|
43134
43154
|
|
|
43135
43155
|
if(bBeforeAstrand) { // make it continuous to the 1st strand
|
|
@@ -43190,7 +43210,7 @@ class ShowSeq {
|
|
|
43190
43210
|
}
|
|
43191
43211
|
}
|
|
43192
43212
|
}
|
|
43193
|
-
else if(
|
|
43213
|
+
else if(bInRange) {
|
|
43194
43214
|
// not in loop any more if you assign ref numbers multiple times
|
|
43195
43215
|
//delete ic.residIgLoop[residueid];
|
|
43196
43216
|
|
|
@@ -43218,7 +43238,7 @@ class ShowSeq {
|
|
|
43218
43238
|
}
|
|
43219
43239
|
}
|
|
43220
43240
|
}
|
|
43221
|
-
else if(
|
|
43241
|
+
else if(bAfter) {
|
|
43222
43242
|
ic.residIgLoop[residueid] = 1;
|
|
43223
43243
|
|
|
43224
43244
|
if(!bAfterGstrand) {
|
|
@@ -54824,7 +54844,10 @@ class SetSeqAlign {
|
|
|
54824
54844
|
*/
|
|
54825
54845
|
|
|
54826
54846
|
let resid = chainid + '_' + resi;
|
|
54827
|
-
|
|
54847
|
+
let resn = ic.residueId2Name[resid];
|
|
54848
|
+
if(!resn) resn = '?';
|
|
54849
|
+
|
|
54850
|
+
return resn;
|
|
54828
54851
|
}
|
|
54829
54852
|
|
|
54830
54853
|
getResiAferAlign(chainid, bRealign, pos) { let ic = this.icn3d, me = ic.icn3dui;
|