icn3d 3.45.5 → 3.45.7
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/LICENSE +0 -0
- package/README.md +0 -0
- package/icn3d.js +44 -32
- package/icn3d.min.js +3 -3
- package/icn3d.module.js +44 -32
- package/package.json +1 -1
package/LICENSE
CHANGED
|
File without changes
|
package/README.md
CHANGED
|
File without changes
|
package/icn3d.js
CHANGED
|
@@ -58415,11 +58415,13 @@ class ClickMenu {
|
|
|
58415
58415
|
});
|
|
58416
58416
|
|
|
58417
58417
|
me.myEventCls.onIds("#" + me.pre + "mn6_cameraPers", "click", function(e) { let ic = me.icn3d; //e.preventDefault();
|
|
58418
|
+
ic.bChangeCamera = true;
|
|
58418
58419
|
ic.setOptionCls.setOption('camera', 'perspective');
|
|
58419
58420
|
thisClass.setLogCmd('set camera perspective', true);
|
|
58420
58421
|
});
|
|
58421
58422
|
|
|
58422
58423
|
me.myEventCls.onIds("#" + me.pre + "mn6_cameraOrth", "click", function(e) { let ic = me.icn3d; //e.preventDefault();
|
|
58424
|
+
ic.bChangeCamera = true;
|
|
58423
58425
|
ic.setOptionCls.setOption('camera', 'orthographic');
|
|
58424
58426
|
thisClass.setLogCmd('set camera orthographic', true);
|
|
58425
58427
|
});
|
|
@@ -63779,7 +63781,7 @@ class Events {
|
|
|
63779
63781
|
me.myEventCls.onIds(["#" + me.pre + "show_2ddgm", "#" + me.pre + "mn2_2ddgm"], "click", async function(e) { let ic = me.icn3d;
|
|
63780
63782
|
me.htmlCls.dialogCls.openDlg('dl_2ddgm', '2D Diagram');
|
|
63781
63783
|
await ic.viewInterPairsCls.retrieveInteractionData();
|
|
63782
|
-
thisClass.setLogCmd("view
|
|
63784
|
+
thisClass.setLogCmd("view 2d diagram", true);
|
|
63783
63785
|
});
|
|
63784
63786
|
|
|
63785
63787
|
me.myEventCls.onIds("#" + me.pre + "mn2_2ddepiction", "click", async function(e) { let ic = me.icn3d;
|
|
@@ -74153,11 +74155,13 @@ class Scene {
|
|
|
74153
74155
|
|
|
74154
74156
|
ic.fogCls.setFog();
|
|
74155
74157
|
|
|
74156
|
-
ic.
|
|
74157
|
-
|
|
74158
|
-
|
|
74159
|
-
ic.container.whratio
|
|
74160
|
-
|
|
74158
|
+
if(!ic.cam || ic.bChangeCamera) {
|
|
74159
|
+
ic.cameraCls.setCamera();
|
|
74160
|
+
// set the ratio for view point, which was set in ic.transformCls.resetOrientation_base
|
|
74161
|
+
if(!ic.container.whratio) {
|
|
74162
|
+
ic.container.whratio = me.htmlCls.WIDTH / me.htmlCls.HEIGHT;
|
|
74163
|
+
ic.cam.aspect = ic.container.whratio;
|
|
74164
|
+
}
|
|
74161
74165
|
}
|
|
74162
74166
|
|
|
74163
74167
|
if(ic.opts['slab'] === 'yes') ic.cameraCls.setSlab();
|
|
@@ -74341,13 +74345,17 @@ class Scene {
|
|
|
74341
74345
|
}
|
|
74342
74346
|
}
|
|
74343
74347
|
|
|
74344
|
-
ic.perspectiveCamera
|
|
74345
|
-
|
|
74346
|
-
|
|
74348
|
+
if(!ic.perspectiveCamera) {
|
|
74349
|
+
ic.perspectiveCamera = new PerspectiveCamera$1(20, ic.container.whratio, 0.1, 10000);
|
|
74350
|
+
ic.perspectiveCamera.position.set(0, 0, ic.cam_z);
|
|
74351
|
+
ic.perspectiveCamera.lookAt(new Vector3$1(0, 0, 0));
|
|
74352
|
+
}
|
|
74347
74353
|
|
|
74348
|
-
ic.orthographicCamera
|
|
74349
|
-
|
|
74350
|
-
|
|
74354
|
+
if(!ic.orthographicCamera) {
|
|
74355
|
+
ic.orthographicCamera = new OrthographicCamera$1();
|
|
74356
|
+
ic.orthographicCamera.position.set(0, 0, ic.cam_z);
|
|
74357
|
+
ic.orthographicCamera.lookAt(new Vector3$1(0, 0, 0));
|
|
74358
|
+
}
|
|
74351
74359
|
|
|
74352
74360
|
ic.cams = {
|
|
74353
74361
|
perspective: ic.perspectiveCamera,
|
|
@@ -86361,7 +86369,7 @@ class Alternate {
|
|
|
86361
86369
|
}
|
|
86362
86370
|
|
|
86363
86371
|
ic.bShowHighlight = false;
|
|
86364
|
-
|
|
86372
|
+
ic.opts['rotationcenter'] = 'highlight center';
|
|
86365
86373
|
}
|
|
86366
86374
|
|
|
86367
86375
|
// also alternating the surfaces
|
|
@@ -104163,7 +104171,7 @@ class ChainalignParser {
|
|
|
104163
104171
|
targetOrQuery = 'query';
|
|
104164
104172
|
bAppend = true;
|
|
104165
104173
|
}
|
|
104166
|
-
|
|
104174
|
+
console.log("### i " + i + " structArray[i] " + structArray[i]);
|
|
104167
104175
|
//if(structArray[i].length > 4) {
|
|
104168
104176
|
if(isNaN(structArray[i]) && structArray[i].length > 5) { // PDB ID plus postfix could be 5
|
|
104169
104177
|
//let bNoDssp = true;
|
|
@@ -104181,8 +104189,8 @@ class ChainalignParser {
|
|
|
104181
104189
|
// hAtoms = me.hashUtilsCls.unionHash(hAtoms, hAtomsTmp);
|
|
104182
104190
|
}
|
|
104183
104191
|
|
|
104184
|
-
let structArrayAll = Object.keys(ic.structures);
|
|
104185
|
-
|
|
104192
|
+
let structArrayAll = structArray; //Object.keys(ic.structures);
|
|
104193
|
+
console.log("### ic.chains: " + JSON.stringify(ic.chains) + " ic.structures " + JSON.stringify(ic.structures));
|
|
104186
104194
|
ic.opts['color'] = (structArrayAll.length > 1) ? 'structure' : ((structArrayAll[0].length > 5) ? 'confidence' : 'chain');
|
|
104187
104195
|
|
|
104188
104196
|
// add color for all structures
|
|
@@ -116047,7 +116055,7 @@ class ApplyCommand {
|
|
|
116047
116055
|
ic.selectionCls.selectAll();
|
|
116048
116056
|
//ic.hlObjectsCls.addHlObjects();
|
|
116049
116057
|
}
|
|
116050
|
-
else if(command == 'show all') {
|
|
116058
|
+
else if(command == 'show all' || command == 'view all') {
|
|
116051
116059
|
ic.selectionCls.showAll();
|
|
116052
116060
|
}
|
|
116053
116061
|
else if(command == 'select complement') {
|
|
@@ -116427,7 +116435,7 @@ class ApplyCommand {
|
|
|
116427
116435
|
ic.applyCenterCls.centerSelection();
|
|
116428
116436
|
ic.drawCls.draw();
|
|
116429
116437
|
}
|
|
116430
|
-
else if(command == 'show selection') {
|
|
116438
|
+
else if(command == 'show selection' || command == 'view selection') {
|
|
116431
116439
|
ic.selectionCls.showSelection();
|
|
116432
116440
|
}
|
|
116433
116441
|
else if(command == 'hide selection') {
|
|
@@ -116470,12 +116478,12 @@ class ApplyCommand {
|
|
|
116470
116478
|
else if(command == 'delete selected sets') {
|
|
116471
116479
|
ic.definedSetsCls.deleteSelectedSets();
|
|
116472
116480
|
}
|
|
116473
|
-
else if(command == 'view interactions') {
|
|
116481
|
+
else if(command == 'view interactions' || command == 'view 2d diagram') {
|
|
116474
116482
|
if(me.cfg.mmdbid !== undefined || me.cfg.gi !== undefined) {
|
|
116475
116483
|
ic.ParserUtilsCls.set2DDiagrams(ic.inputid);
|
|
116476
116484
|
}
|
|
116477
116485
|
}
|
|
116478
|
-
else if(command == 'show annotations all chains') {
|
|
116486
|
+
else if(command == 'show annotations all chains' || command == 'view annotations all chains') {
|
|
116479
116487
|
ic.annotationCls.showAnnoAllChains();
|
|
116480
116488
|
}
|
|
116481
116489
|
|
|
@@ -116537,7 +116545,7 @@ class ApplyCommand {
|
|
|
116537
116545
|
else if(command == 'clear symd symmetry') {
|
|
116538
116546
|
ic.symdArray = [];
|
|
116539
116547
|
}
|
|
116540
|
-
else if(command == 'show axis') {
|
|
116548
|
+
else if(command == 'show axis' || command == 'view axis') {
|
|
116541
116549
|
ic.bAxisOnly = true;
|
|
116542
116550
|
}
|
|
116543
116551
|
|
|
@@ -116985,7 +116993,7 @@ class ApplyCommand {
|
|
|
116985
116993
|
}
|
|
116986
116994
|
}
|
|
116987
116995
|
else if(commandOri.indexOf('display interaction 3d') == 0
|
|
116988
|
-
|| commandOri.indexOf('view interaction pairs') == 0
|
|
116996
|
+
|| commandOri.indexOf('view interaction pairs') == 0 || commandOri.indexOf('show interaction pairs') == 0
|
|
116989
116997
|
|| commandOri.indexOf('save1 interaction pairs') == 0
|
|
116990
116998
|
|| commandOri.indexOf('save2 interaction pairs') == 0
|
|
116991
116999
|
|| commandOri.indexOf('line graph interaction pairs') == 0
|
|
@@ -117036,7 +117044,7 @@ class ApplyCommand {
|
|
|
117036
117044
|
if(commandOri.indexOf('display interaction 3d') == 0) {
|
|
117037
117045
|
type = '3d';
|
|
117038
117046
|
}
|
|
117039
|
-
else if(commandOri.indexOf('view interaction pairs') == 0) {
|
|
117047
|
+
else if(commandOri.indexOf('view interaction pairs') == 0 || commandOri.indexOf('show interaction pairs') == 0) {
|
|
117040
117048
|
type = 'view';
|
|
117041
117049
|
}
|
|
117042
117050
|
else if(commandOri.indexOf('save1 interaction pairs') == 0) {
|
|
@@ -117396,7 +117404,7 @@ class ApplyCommand {
|
|
|
117396
117404
|
let dataStr = paraArray[1].replace(/\\n/g, '\n');
|
|
117397
117405
|
await ic.refnumCls.parseCustomRefFile(dataStr);
|
|
117398
117406
|
}
|
|
117399
|
-
else if(command.indexOf('show ref number') == 0) {
|
|
117407
|
+
else if(command.indexOf('show ref number') == 0 || command.indexOf('view ref number') == 0) {
|
|
117400
117408
|
ic.bShownRefnum = true;
|
|
117401
117409
|
}
|
|
117402
117410
|
else if(command.indexOf('hide ref number') == 0) {
|
|
@@ -117652,7 +117660,7 @@ class ApplyCommand {
|
|
|
117652
117660
|
else if(cmd.indexOf('set annotation clinvar') == 0) return seqAnnoStr + ': "ClinVar" checkbox';
|
|
117653
117661
|
else if(cmd.indexOf('set annotation snp') == 0) return seqAnnoStr + ': "SNP" checkbox';
|
|
117654
117662
|
else if(cmd.indexOf('set annotation 3ddomain') == 0) return seqAnnoStr + ': "3D Domains" checkbox';
|
|
117655
|
-
else if(cmd.indexOf('view interactions') == 0) return 'Windows > View 2D Diagram';
|
|
117663
|
+
else if(cmd.indexOf('view interactions') == 0 || cmd.indexOf('view 2d diagram') == 0) return 'Windows > View 2D Diagram';
|
|
117656
117664
|
else if(cmd.indexOf('symmetry') == 0) return 'Analysis > Symmetry';
|
|
117657
117665
|
else if(cmd.indexOf('realign on seq align') == 0) return 'File > Realign Selection > on Sequence Alignment';
|
|
117658
117666
|
else if(cmd.indexOf('realign') == 0) return 'File > Realign Selection > Residue by Residue';
|
|
@@ -117744,7 +117752,7 @@ class ApplyCommand {
|
|
|
117744
117752
|
else if(cmd == 'clear all') return 'Select > Clear Selection';
|
|
117745
117753
|
else if(cmd == 'defined sets') return 'Windows > Defined Sets';
|
|
117746
117754
|
else if(cmd == 'delete selected sets') return 'Windows > Defined Sets: "Delete Selected Sets" button';
|
|
117747
|
-
else if(cmd == 'view interactions') return 'Windows > View Interactions';
|
|
117755
|
+
else if(cmd == 'view interactions' || cmd == 'view 2d diagram') return 'Windows > View Interactions';
|
|
117748
117756
|
else if(cmd == 'show annotations all chains') return seqAnnoStr + ': "Show All Chains" button';
|
|
117749
117757
|
else if(cmd == 'save color') return 'Color > Save Color';
|
|
117750
117758
|
else if(cmd == 'apply saved color') return 'Color > Apply Saved Color';
|
|
@@ -119015,7 +119023,7 @@ class LoadScript {
|
|
|
119015
119023
|
|
|
119016
119024
|
await ic.annotationCls.setAnnoTabAll();
|
|
119017
119025
|
}
|
|
119018
|
-
else if(command.indexOf('view interactions') == 0 && me.cfg.align !== undefined) { // the command may have "|||{"factor"...
|
|
119026
|
+
else if((command.indexOf('view interactions') == 0 || command.indexOf('view 2d diagram') == 0) && me.cfg.align !== undefined) { // the command may have "|||{"factor"...
|
|
119019
119027
|
await thisClass.applyCommandViewinteraction(strArray[0].trim());
|
|
119020
119028
|
}
|
|
119021
119029
|
else if(command.indexOf('view 2d depiction') == 0) { // the command may have "|||{"factor"...
|
|
@@ -119226,7 +119234,7 @@ class LoadScript {
|
|
|
119226
119234
|
thisClass.applyCommand3ddomain(lastCommand);
|
|
119227
119235
|
await ic.annotationCls.setAnnoTabAll();
|
|
119228
119236
|
}
|
|
119229
|
-
else if(lastCommand.indexOf('view interactions') == 0 && me.cfg.align !== undefined) {
|
|
119237
|
+
else if((lastCommand.indexOf('view interactions') == 0 || lastCommand.indexOf('view 2d diagram') == 0) && me.cfg.align !== undefined) {
|
|
119230
119238
|
await thisClass.applyCommandViewinteraction(lastCommand);
|
|
119231
119239
|
}
|
|
119232
119240
|
else if(lastCommand.indexOf('view 2d depiction') == 0) {
|
|
@@ -119687,7 +119695,7 @@ class LoadScript {
|
|
|
119687
119695
|
|
|
119688
119696
|
if(commandTransformation.length == 2 && commandTransformation[1].substr(0,1) == '{') ic.bTransformation = true;
|
|
119689
119697
|
|
|
119690
|
-
ic.transformCls.resetOrientation_base(commandTransformation);
|
|
119698
|
+
// ic.transformCls.resetOrientation_base(commandTransformation);
|
|
119691
119699
|
|
|
119692
119700
|
ic.selectionCls.oneStructurePerWindow();
|
|
119693
119701
|
|
|
@@ -119753,8 +119761,12 @@ class LoadScript {
|
|
|
119753
119761
|
$("#ncbi_logo").hide();
|
|
119754
119762
|
}
|
|
119755
119763
|
|
|
119764
|
+
ic.transformCls.resetOrientation_base(commandTransformation);
|
|
119765
|
+
|
|
119756
119766
|
// an extra render to remove artifacts in transparent surface
|
|
119757
|
-
if(ic.bTransparentSurface && ic.bRender) ic.drawCls.render();
|
|
119767
|
+
// if(ic.bTransparentSurface && ic.bRender) ic.drawCls.render();
|
|
119768
|
+
ic.drawCls.applyTransformation(ic._zoomFactor, ic.mouseChange, ic.quaternion);
|
|
119769
|
+
ic.drawCls.render();
|
|
119758
119770
|
|
|
119759
119771
|
if(me.cfg.imageonly) ic.saveFileCls.saveFile(undefined, 'png', undefined, true);
|
|
119760
119772
|
|
|
@@ -132253,7 +132265,7 @@ class iCn3D {
|
|
|
132253
132265
|
|
|
132254
132266
|
this.transparentRenderOrder = false; // false: regular transparency; true: expensive renderOrder for each face
|
|
132255
132267
|
|
|
132256
|
-
this.AFUniprotVersion = '
|
|
132268
|
+
this.AFUniprotVersion = 'v6';
|
|
132257
132269
|
this.defaultPdbId = 'stru';
|
|
132258
132270
|
|
|
132259
132271
|
if(!this.icn3dui.bNode) {
|
|
@@ -132842,7 +132854,7 @@ class iCn3DUI {
|
|
|
132842
132854
|
//even when multiple iCn3D viewers are shown together.
|
|
132843
132855
|
this.pre = this.cfg.divid + "_";
|
|
132844
132856
|
|
|
132845
|
-
this.REVISION = '3.45.
|
|
132857
|
+
this.REVISION = '3.45.4';
|
|
132846
132858
|
|
|
132847
132859
|
// In nodejs, iCn3D defines "window = {navigator: {}}", and added window = {navigator: {}, "__THREE__":"177"}
|
|
132848
132860
|
this.bNode = (Object.keys(window).length < 3) ? true : false;
|