jbrowse-plugin-mafviewer 1.4.0 → 1.4.1
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/dist/LinearMafRenderer/components/LinearMafRendering.js +3 -2
- package/dist/LinearMafRenderer/components/LinearMafRendering.js.map +1 -1
- package/dist/LinearMafRenderer/rendering/features.js +4 -6
- package/dist/LinearMafRenderer/rendering/features.js.map +1 -1
- package/dist/LinearMafRenderer/rendering/insertions.d.ts +1 -1
- package/dist/LinearMafRenderer/rendering/insertions.js +1 -1
- package/dist/LinearMafRenderer/rendering/insertions.js.map +1 -1
- package/dist/LinearMafRenderer/rendering/matches.d.ts +1 -1
- package/dist/LinearMafRenderer/rendering/matches.js +1 -1
- package/dist/LinearMafRenderer/rendering/matches.js.map +1 -1
- package/dist/LinearMafRenderer/rendering/mismatches.d.ts +1 -1
- package/dist/LinearMafRenderer/rendering/mismatches.js +2 -2
- package/dist/LinearMafRenderer/rendering/mismatches.js.map +1 -1
- package/dist/LinearMafRenderer/rendering/text.d.ts +1 -1
- package/dist/LinearMafRenderer/rendering/text.js +1 -1
- package/dist/LinearMafRenderer/rendering/text.js.map +1 -1
- package/dist/jbrowse-plugin-mafviewer.umd.production.min.js +5 -5
- package/dist/jbrowse-plugin-mafviewer.umd.production.min.js.map +3 -3
- package/dist/out.js +10 -16
- package/dist/out.js.map +2 -2
- package/package.json +1 -1
- package/src/LinearMafRenderer/components/LinearMafRendering.tsx +3 -2
- package/src/LinearMafRenderer/rendering/features.ts +0 -10
- package/src/LinearMafRenderer/rendering/insertions.ts +0 -1
- package/src/LinearMafRenderer/rendering/matches.ts +0 -1
- package/src/LinearMafRenderer/rendering/mismatches.ts +1 -2
- package/src/LinearMafRenderer/rendering/text.ts +0 -2
package/dist/out.js
CHANGED
|
@@ -28526,7 +28526,7 @@ var JBrowsePluginMafViewer = (() => {
|
|
|
28526
28526
|
var import_Plugin = __toESM(require_Plugin());
|
|
28527
28527
|
|
|
28528
28528
|
// package.json
|
|
28529
|
-
var version = "1.4.
|
|
28529
|
+
var version = "1.4.1";
|
|
28530
28530
|
|
|
28531
28531
|
// src/BigMafAdapter/index.ts
|
|
28532
28532
|
var import_pluggableElementTypes = __toESM(require_pluggableElementTypes());
|
|
@@ -31055,7 +31055,7 @@ ${r}`).join("\n");
|
|
|
31055
31055
|
}
|
|
31056
31056
|
|
|
31057
31057
|
// src/LinearMafRenderer/rendering/matches.ts
|
|
31058
|
-
function renderMatches(context2, alignment, seq, leftPx, rowTop, sampleId,
|
|
31058
|
+
function renderMatches(context2, alignment, seq, leftPx, rowTop, sampleId, alignmentStart, chr) {
|
|
31059
31059
|
if (context2.showAllLetters) {
|
|
31060
31060
|
return;
|
|
31061
31061
|
}
|
|
@@ -31089,7 +31089,7 @@ ${r}`).join("\n");
|
|
|
31089
31089
|
}
|
|
31090
31090
|
|
|
31091
31091
|
// src/LinearMafRenderer/rendering/mismatches.ts
|
|
31092
|
-
function renderMismatches(context2, alignment, seq, leftPx, rowTop, sampleId,
|
|
31092
|
+
function renderMismatches(context2, alignment, seq, leftPx, rowTop, sampleId, alignmentStart, chr) {
|
|
31093
31093
|
const {
|
|
31094
31094
|
ctx,
|
|
31095
31095
|
scale,
|
|
@@ -31125,7 +31125,7 @@ ${r}`).join("\n");
|
|
|
31125
31125
|
pos: genomicOffset + alignmentStart,
|
|
31126
31126
|
chr,
|
|
31127
31127
|
base: currentChar,
|
|
31128
|
-
sampleId
|
|
31128
|
+
sampleId
|
|
31129
31129
|
}
|
|
31130
31130
|
);
|
|
31131
31131
|
}
|
|
@@ -31165,7 +31165,7 @@ ${r}`).join("\n");
|
|
|
31165
31165
|
function getLetter(a, showAsUpperCase) {
|
|
31166
31166
|
return showAsUpperCase ? a.toUpperCase() : a;
|
|
31167
31167
|
}
|
|
31168
|
-
function renderText(context2, alignment, origAlignment, seq, leftPx, rowTop
|
|
31168
|
+
function renderText(context2, alignment, origAlignment, seq, leftPx, rowTop) {
|
|
31169
31169
|
const {
|
|
31170
31170
|
ctx,
|
|
31171
31171
|
scale,
|
|
@@ -31201,7 +31201,7 @@ ${r}`).join("\n");
|
|
|
31201
31201
|
|
|
31202
31202
|
// src/LinearMafRenderer/rendering/insertions.ts
|
|
31203
31203
|
var import_util18 = __toESM(require_util());
|
|
31204
|
-
function renderInsertions(context2, alignment, seq, leftPx, rowTop, bpPerPx, sampleId,
|
|
31204
|
+
function renderInsertions(context2, alignment, seq, leftPx, rowTop, bpPerPx, sampleId, alignmentStart, chr) {
|
|
31205
31205
|
const { ctx, scale, h, canvasWidth, rowHeight } = context2;
|
|
31206
31206
|
const { charHeight } = getCharWidthHeight();
|
|
31207
31207
|
for (let i = 0, genomicOffset = 0, seqLength = alignment.length; i < seqLength; i++) {
|
|
@@ -31312,7 +31312,6 @@ ${r}`).join("\n");
|
|
|
31312
31312
|
const [leftPx] = (0, import_util20.featureSpanPx)(feature, region, bpPerPx);
|
|
31313
31313
|
const alignments2 = feature.get("alignments");
|
|
31314
31314
|
const referenceSeq = feature.get("seq").toLowerCase();
|
|
31315
|
-
const featureId = feature.id() || `feature_${feature.get("start")}_${feature.get("end")}`;
|
|
31316
31315
|
for (const [sampleId, alignmentData] of Object.entries(alignments2)) {
|
|
31317
31316
|
const row = sampleToRowMap.get(sampleId);
|
|
31318
31317
|
if (row === void 0) {
|
|
@@ -31329,7 +31328,6 @@ ${r}`).join("\n");
|
|
|
31329
31328
|
leftPx,
|
|
31330
31329
|
rowTop,
|
|
31331
31330
|
row,
|
|
31332
|
-
featureId,
|
|
31333
31331
|
alignmentData.start,
|
|
31334
31332
|
alignmentData.chr
|
|
31335
31333
|
);
|
|
@@ -31340,7 +31338,6 @@ ${r}`).join("\n");
|
|
|
31340
31338
|
leftPx,
|
|
31341
31339
|
rowTop,
|
|
31342
31340
|
row,
|
|
31343
|
-
featureId,
|
|
31344
31341
|
alignmentData.start,
|
|
31345
31342
|
alignmentData.chr
|
|
31346
31343
|
);
|
|
@@ -31350,9 +31347,7 @@ ${r}`).join("\n");
|
|
|
31350
31347
|
originalAlignment,
|
|
31351
31348
|
referenceSeq,
|
|
31352
31349
|
leftPx,
|
|
31353
|
-
rowTop
|
|
31354
|
-
sampleId,
|
|
31355
|
-
featureId
|
|
31350
|
+
rowTop
|
|
31356
31351
|
);
|
|
31357
31352
|
}
|
|
31358
31353
|
}
|
|
@@ -31360,7 +31355,6 @@ ${r}`).join("\n");
|
|
|
31360
31355
|
const [leftPx] = (0, import_util20.featureSpanPx)(feature, region, bpPerPx);
|
|
31361
31356
|
const alignments2 = feature.get("alignments");
|
|
31362
31357
|
const referenceSeq = feature.get("seq").toLowerCase();
|
|
31363
|
-
const featureId = feature.id() || `feature_${feature.get("start")}_${feature.get("end")}`;
|
|
31364
31358
|
for (const [sampleId, alignmentData] of Object.entries(alignments2)) {
|
|
31365
31359
|
const row = sampleToRowMap.get(sampleId);
|
|
31366
31360
|
if (row === void 0) {
|
|
@@ -31376,7 +31370,6 @@ ${r}`).join("\n");
|
|
|
31376
31370
|
rowTop,
|
|
31377
31371
|
bpPerPx,
|
|
31378
31372
|
row,
|
|
31379
|
-
featureId,
|
|
31380
31373
|
alignmentData.start,
|
|
31381
31374
|
alignmentData.chr
|
|
31382
31375
|
);
|
|
@@ -31537,8 +31530,9 @@ ${r}`).join("\n");
|
|
|
31537
31530
|
}
|
|
31538
31531
|
const x = rbush2.search(offsetX, offsetY, offsetX + 1, offsetY + 1);
|
|
31539
31532
|
if (x.length) {
|
|
31540
|
-
const elt = x.
|
|
31541
|
-
const r = elt !==
|
|
31533
|
+
const elt = x.find((idx) => items[idx]?.isInsertion);
|
|
31534
|
+
const r = elt !== void 0 ? items[elt] : items[x[0]];
|
|
31535
|
+
console.log({ x, r });
|
|
31542
31536
|
const s = samples[r.sampleId];
|
|
31543
31537
|
return {
|
|
31544
31538
|
...r,
|