igv 3.8.3 → 3.8.4
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/README.md +10 -10
- package/dist/igv.esm.js +36 -4
- package/dist/igv.esm.min.js +9 -9
- package/dist/igv.esm.min.js.map +1 -1
- package/dist/igv.js +36 -4
- package/dist/igv.min.js +9 -9
- package/dist/igv.min.js.map +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -18,19 +18,19 @@ Below are examples and a quickstart guide. See the [developer documentation](ht
|
|
|
18
18
|
|
|
19
19
|
# Examples
|
|
20
20
|
|
|
21
|
-
***[Alignments](https://igv.org/web/release/3.8.
|
|
21
|
+
***[Alignments](https://igv.org/web/release/3.8.4/examples/cram-vcf.html)***
|
|
22
22
|
|
|
23
|
-
***[Interactions](https://igv.org/web/release/3.8.
|
|
23
|
+
***[Interactions](https://igv.org/web/release/3.8.4/examples/interact.html)***
|
|
24
24
|
|
|
25
|
-
***[Copy number](https://igv.org/web/release/3.8.
|
|
25
|
+
***[Copy number](https://igv.org/web/release/3.8.4/examples/copyNumber.html)***
|
|
26
26
|
|
|
27
|
-
***[Multiple regions](https://igv.org/web/release/3.8.
|
|
27
|
+
***[Multiple regions](https://igv.org/web/release/3.8.4/examples/multi-locus.html)***
|
|
28
28
|
|
|
29
|
-
***[Mutation Annotation Format (MAF)](https://igv.org/web/release/3.8.
|
|
29
|
+
***[Mutation Annotation Format (MAF)](https://igv.org/web/release/3.8.4/examples/maf-tcga.html)***
|
|
30
30
|
|
|
31
|
-
***[Variant color options](https://igv.org/web/release/3.8.
|
|
31
|
+
***[Variant color options](https://igv.org/web/release/3.8.4/examples/variant-colors.html)***
|
|
32
32
|
|
|
33
|
-
***[More](https://igv.org/web/release/3.8.
|
|
33
|
+
***[More](https://igv.org/web/release/3.8.4/examples/)***
|
|
34
34
|
|
|
35
35
|
|
|
36
36
|
# Quickstart
|
|
@@ -39,18 +39,18 @@ Below are examples and a quickstart guide. See the [developer documentation](ht
|
|
|
39
39
|
igv.js consists of a single javascript file with no external dependencies.
|
|
40
40
|
|
|
41
41
|
Pre-built files for script include, AMD, or CJS module systems (igv.min.js) and an ES6 module (igv.esm.min.js)
|
|
42
|
-
can be downloaded from [https://cdn.jsdelivr.net/npm/igv@3.8.
|
|
42
|
+
can be downloaded from [https://cdn.jsdelivr.net/npm/igv@3.8.4/dist/](https://cdn.jsdelivr.net/npm/igv@3.8.4/dist/).
|
|
43
43
|
|
|
44
44
|
To import igv as an ES6 module
|
|
45
45
|
|
|
46
46
|
```javascript
|
|
47
|
-
import igv from "https://cdn.jsdelivr.net/npm/igv@3.8.
|
|
47
|
+
import igv from "https://cdn.jsdelivr.net/npm/igv@3.8.4/dist/igv.esm.min.js"
|
|
48
48
|
```
|
|
49
49
|
|
|
50
50
|
Or as a script include (defines the "igv" global)
|
|
51
51
|
|
|
52
52
|
```html
|
|
53
|
-
<script src="https://cdn.jsdelivr.net/npm/igv@3.8.
|
|
53
|
+
<script src="https://cdn.jsdelivr.net/npm/igv@3.8.4/dist/igv.min.js"></script>
|
|
54
54
|
```
|
|
55
55
|
|
|
56
56
|
Alternatively you can install with npm
|
package/dist/igv.esm.js
CHANGED
|
@@ -8820,6 +8820,8 @@ class IGVXhr {
|
|
|
8820
8820
|
if (isFile(url)) {
|
|
8821
8821
|
return this._loadFileSlice(url, options)
|
|
8822
8822
|
} else if (isString$3(url)) {
|
|
8823
|
+
// Convert "virtual" URLs (keys that don't exist) to real URLs before any other action
|
|
8824
|
+
url = await convert(url);
|
|
8823
8825
|
if (url.startsWith("data:")) {
|
|
8824
8826
|
const buffer = decodeDataURI$1(url).buffer;
|
|
8825
8827
|
if (options.range) {
|
|
@@ -9326,6 +9328,34 @@ function getGlobalObject() {
|
|
|
9326
9328
|
}
|
|
9327
9329
|
}
|
|
9328
9330
|
|
|
9331
|
+
let mappings;
|
|
9332
|
+
|
|
9333
|
+
const mappingURL = "https://raw.githubusercontent.com/igvteam/igv-data/refs/heads/main/data/url_mappings.tsv";
|
|
9334
|
+
|
|
9335
|
+
async function convert(url) {
|
|
9336
|
+
|
|
9337
|
+
if (!mappings) {
|
|
9338
|
+
mappings = new Map();
|
|
9339
|
+
|
|
9340
|
+
try {
|
|
9341
|
+
const data = await igvxhr.loadString(mappingURL);
|
|
9342
|
+
const lines = data.split("\n");
|
|
9343
|
+
for (const line of lines) {
|
|
9344
|
+
if (line.startsWith("#")) continue
|
|
9345
|
+
|
|
9346
|
+
const tokens = line.split('\t');
|
|
9347
|
+
if (tokens.length === 2) {
|
|
9348
|
+
mappings.set(tokens[0], tokens[1]);
|
|
9349
|
+
}
|
|
9350
|
+
}
|
|
9351
|
+
} catch (e) {
|
|
9352
|
+
console.error(`Error loading url mappings`, e);
|
|
9353
|
+
}
|
|
9354
|
+
}
|
|
9355
|
+
|
|
9356
|
+
return mappings.has(url) ? mappings.get(url) : url
|
|
9357
|
+
}
|
|
9358
|
+
|
|
9329
9359
|
|
|
9330
9360
|
const igvxhr = new IGVXhr();
|
|
9331
9361
|
|
|
@@ -51144,7 +51174,9 @@ class BamAlignment {
|
|
|
51144
51174
|
nameValues.push('<hr/>');
|
|
51145
51175
|
nameValues.push({name: 'Genomic Location: ', value: numberFormatter$1(1 + genomicLocation)});
|
|
51146
51176
|
nameValues.push({name: 'Read Base:', value: readBase});
|
|
51147
|
-
|
|
51177
|
+
|
|
51178
|
+
let quality = this.readBaseQualityAt(genomicLocation);
|
|
51179
|
+
nameValues.push({name: 'Base Quality:', value: 255 === quality ? "unknown" : quality});
|
|
51148
51180
|
|
|
51149
51181
|
const bmSets = this.getBaseModificationSets();
|
|
51150
51182
|
if (bmSets) {
|
|
@@ -51195,13 +51227,13 @@ class BamAlignment {
|
|
|
51195
51227
|
const block = this.blockAtGenomicLocation(genomicLocation);
|
|
51196
51228
|
if (block) {
|
|
51197
51229
|
if ("*" === this.qual) {
|
|
51198
|
-
return
|
|
51230
|
+
return undefined
|
|
51199
51231
|
} else {
|
|
51200
51232
|
const idx = block.seqIndexAt(genomicLocation);
|
|
51201
51233
|
if (idx >= 0 && this.qual && idx < this.qual.length) {
|
|
51202
51234
|
return this.qual[idx]
|
|
51203
51235
|
} else {
|
|
51204
|
-
return
|
|
51236
|
+
return undefined
|
|
51205
51237
|
}
|
|
51206
51238
|
}
|
|
51207
51239
|
} else {
|
|
@@ -77566,7 +77598,7 @@ function createReferenceFrameList(loci, genome, browserFlanking, minimumBases, v
|
|
|
77566
77598
|
})
|
|
77567
77599
|
}
|
|
77568
77600
|
|
|
77569
|
-
const _version = "3.8.
|
|
77601
|
+
const _version = "3.8.4";
|
|
77570
77602
|
function version() {
|
|
77571
77603
|
return _version
|
|
77572
77604
|
}
|