@jbrowse/plugin-bed 2.10.0 → 2.10.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/dist/util.js +12 -1
- package/esm/util.js +12 -1
- package/package.json +2 -2
package/dist/util.js
CHANGED
|
@@ -7,6 +7,7 @@ function ucscProcessedTranscript(feature) {
|
|
|
7
7
|
// split the blocks into UTR, CDS, and exons
|
|
8
8
|
const thickStart = feature.get('thickStart');
|
|
9
9
|
const thickEnd = feature.get('thickEnd');
|
|
10
|
+
const refName = feature.get('refName');
|
|
10
11
|
if (!thickStart && !thickEnd) {
|
|
11
12
|
return feature;
|
|
12
13
|
}
|
|
@@ -15,7 +16,6 @@ function ucscProcessedTranscript(feature) {
|
|
|
15
16
|
.filter(child => child.get('type') === 'block')
|
|
16
17
|
.sort((a, b) => a.get('start') - b.get('start'))
|
|
17
18
|
: [];
|
|
18
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
19
19
|
const newChildren = [];
|
|
20
20
|
blocks.forEach(block => {
|
|
21
21
|
const start = block.get('start');
|
|
@@ -27,6 +27,7 @@ function ucscProcessedTranscript(feature) {
|
|
|
27
27
|
type: `${prime}_prime_UTR`,
|
|
28
28
|
start,
|
|
29
29
|
end,
|
|
30
|
+
refName,
|
|
30
31
|
});
|
|
31
32
|
}
|
|
32
33
|
else if (thickStart > start && thickStart < end && thickEnd >= end) {
|
|
@@ -36,10 +37,12 @@ function ucscProcessedTranscript(feature) {
|
|
|
36
37
|
type: `${prime}_prime_UTR`,
|
|
37
38
|
start,
|
|
38
39
|
end: thickStart,
|
|
40
|
+
refName,
|
|
39
41
|
}, {
|
|
40
42
|
type: 'CDS',
|
|
41
43
|
start: thickStart,
|
|
42
44
|
end,
|
|
45
|
+
refName,
|
|
43
46
|
});
|
|
44
47
|
}
|
|
45
48
|
else if (thickStart <= start && thickEnd >= end) {
|
|
@@ -48,6 +51,7 @@ function ucscProcessedTranscript(feature) {
|
|
|
48
51
|
type: 'CDS',
|
|
49
52
|
start,
|
|
50
53
|
end,
|
|
54
|
+
refName,
|
|
51
55
|
});
|
|
52
56
|
}
|
|
53
57
|
else if (thickStart > start && thickStart < end && thickEnd < end) {
|
|
@@ -58,14 +62,17 @@ function ucscProcessedTranscript(feature) {
|
|
|
58
62
|
type: `${leftPrime}_prime_UTR`,
|
|
59
63
|
start,
|
|
60
64
|
end: thickStart,
|
|
65
|
+
refName,
|
|
61
66
|
}, {
|
|
62
67
|
type: `CDS`,
|
|
63
68
|
start: thickStart,
|
|
64
69
|
end: thickEnd,
|
|
70
|
+
refName,
|
|
65
71
|
}, {
|
|
66
72
|
type: `${rightPrime}_prime_UTR`,
|
|
67
73
|
start: thickEnd,
|
|
68
74
|
end,
|
|
75
|
+
refName,
|
|
69
76
|
});
|
|
70
77
|
}
|
|
71
78
|
else if (thickStart <= start && thickEnd > start && thickEnd < end) {
|
|
@@ -75,10 +82,12 @@ function ucscProcessedTranscript(feature) {
|
|
|
75
82
|
type: `CDS`,
|
|
76
83
|
start,
|
|
77
84
|
end: thickEnd,
|
|
85
|
+
refName,
|
|
78
86
|
}, {
|
|
79
87
|
type: `${prime}_prime_UTR`,
|
|
80
88
|
start: thickEnd,
|
|
81
89
|
end,
|
|
90
|
+
refName,
|
|
82
91
|
});
|
|
83
92
|
}
|
|
84
93
|
else if (thickEnd <= start) {
|
|
@@ -88,6 +97,7 @@ function ucscProcessedTranscript(feature) {
|
|
|
88
97
|
type: `${prime}_prime_UTR`,
|
|
89
98
|
start,
|
|
90
99
|
end,
|
|
100
|
+
refName,
|
|
91
101
|
});
|
|
92
102
|
}
|
|
93
103
|
});
|
|
@@ -135,6 +145,7 @@ function featureData(line, colRef, colStart, colEnd, scoreColumn, parser, unique
|
|
|
135
145
|
uniqueId: `${uniqueId}-${b}`,
|
|
136
146
|
start: bmin,
|
|
137
147
|
end: bmax,
|
|
148
|
+
refName,
|
|
138
149
|
type: 'block',
|
|
139
150
|
});
|
|
140
151
|
}
|
package/esm/util.js
CHANGED
|
@@ -4,6 +4,7 @@ export function ucscProcessedTranscript(feature) {
|
|
|
4
4
|
// split the blocks into UTR, CDS, and exons
|
|
5
5
|
const thickStart = feature.get('thickStart');
|
|
6
6
|
const thickEnd = feature.get('thickEnd');
|
|
7
|
+
const refName = feature.get('refName');
|
|
7
8
|
if (!thickStart && !thickEnd) {
|
|
8
9
|
return feature;
|
|
9
10
|
}
|
|
@@ -12,7 +13,6 @@ export function ucscProcessedTranscript(feature) {
|
|
|
12
13
|
.filter(child => child.get('type') === 'block')
|
|
13
14
|
.sort((a, b) => a.get('start') - b.get('start'))
|
|
14
15
|
: [];
|
|
15
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
16
16
|
const newChildren = [];
|
|
17
17
|
blocks.forEach(block => {
|
|
18
18
|
const start = block.get('start');
|
|
@@ -24,6 +24,7 @@ export function ucscProcessedTranscript(feature) {
|
|
|
24
24
|
type: `${prime}_prime_UTR`,
|
|
25
25
|
start,
|
|
26
26
|
end,
|
|
27
|
+
refName,
|
|
27
28
|
});
|
|
28
29
|
}
|
|
29
30
|
else if (thickStart > start && thickStart < end && thickEnd >= end) {
|
|
@@ -33,10 +34,12 @@ export function ucscProcessedTranscript(feature) {
|
|
|
33
34
|
type: `${prime}_prime_UTR`,
|
|
34
35
|
start,
|
|
35
36
|
end: thickStart,
|
|
37
|
+
refName,
|
|
36
38
|
}, {
|
|
37
39
|
type: 'CDS',
|
|
38
40
|
start: thickStart,
|
|
39
41
|
end,
|
|
42
|
+
refName,
|
|
40
43
|
});
|
|
41
44
|
}
|
|
42
45
|
else if (thickStart <= start && thickEnd >= end) {
|
|
@@ -45,6 +48,7 @@ export function ucscProcessedTranscript(feature) {
|
|
|
45
48
|
type: 'CDS',
|
|
46
49
|
start,
|
|
47
50
|
end,
|
|
51
|
+
refName,
|
|
48
52
|
});
|
|
49
53
|
}
|
|
50
54
|
else if (thickStart > start && thickStart < end && thickEnd < end) {
|
|
@@ -55,14 +59,17 @@ export function ucscProcessedTranscript(feature) {
|
|
|
55
59
|
type: `${leftPrime}_prime_UTR`,
|
|
56
60
|
start,
|
|
57
61
|
end: thickStart,
|
|
62
|
+
refName,
|
|
58
63
|
}, {
|
|
59
64
|
type: `CDS`,
|
|
60
65
|
start: thickStart,
|
|
61
66
|
end: thickEnd,
|
|
67
|
+
refName,
|
|
62
68
|
}, {
|
|
63
69
|
type: `${rightPrime}_prime_UTR`,
|
|
64
70
|
start: thickEnd,
|
|
65
71
|
end,
|
|
72
|
+
refName,
|
|
66
73
|
});
|
|
67
74
|
}
|
|
68
75
|
else if (thickStart <= start && thickEnd > start && thickEnd < end) {
|
|
@@ -72,10 +79,12 @@ export function ucscProcessedTranscript(feature) {
|
|
|
72
79
|
type: `CDS`,
|
|
73
80
|
start,
|
|
74
81
|
end: thickEnd,
|
|
82
|
+
refName,
|
|
75
83
|
}, {
|
|
76
84
|
type: `${prime}_prime_UTR`,
|
|
77
85
|
start: thickEnd,
|
|
78
86
|
end,
|
|
87
|
+
refName,
|
|
79
88
|
});
|
|
80
89
|
}
|
|
81
90
|
else if (thickEnd <= start) {
|
|
@@ -85,6 +94,7 @@ export function ucscProcessedTranscript(feature) {
|
|
|
85
94
|
type: `${prime}_prime_UTR`,
|
|
86
95
|
start,
|
|
87
96
|
end,
|
|
97
|
+
refName,
|
|
88
98
|
});
|
|
89
99
|
}
|
|
90
100
|
});
|
|
@@ -131,6 +141,7 @@ export function featureData(line, colRef, colStart, colEnd, scoreColumn, parser,
|
|
|
131
141
|
uniqueId: `${uniqueId}-${b}`,
|
|
132
142
|
start: bmin,
|
|
133
143
|
end: bmax,
|
|
144
|
+
refName,
|
|
134
145
|
type: 'block',
|
|
135
146
|
});
|
|
136
147
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jbrowse/plugin-bed",
|
|
3
|
-
"version": "2.10.
|
|
3
|
+
"version": "2.10.2",
|
|
4
4
|
"description": "JBrowse 2 bed adapters, tracks, etc.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"jbrowse",
|
|
@@ -55,5 +55,5 @@
|
|
|
55
55
|
"distModule": "esm/index.js",
|
|
56
56
|
"srcModule": "src/index.ts",
|
|
57
57
|
"module": "esm/index.js",
|
|
58
|
-
"gitHead": "
|
|
58
|
+
"gitHead": "7ca3b7db337ebd88853e2d96cdab940ed550c4fb"
|
|
59
59
|
}
|