@jbrowse/core 4.1.13 → 4.1.14

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.
@@ -6,6 +6,7 @@ export interface Feat {
6
6
  type?: string;
7
7
  name?: string;
8
8
  id?: string;
9
+ phase?: number;
9
10
  }
10
11
  export interface ParentFeat extends Feat {
11
12
  uniqueId: string;
@@ -33,6 +34,7 @@ export declare function revlist(list: Feat[], seqlen: number): {
33
34
  type?: string;
34
35
  name?: string;
35
36
  id?: string;
37
+ phase?: number;
36
38
  }[];
37
39
  export declare function calculateUTRs(cds: Feat[], exons: Feat[]): {
38
40
  type: string;
@@ -40,6 +42,7 @@ export declare function calculateUTRs(cds: Feat[], exons: Feat[]): {
40
42
  end: number;
41
43
  name?: string;
42
44
  id?: string;
45
+ phase?: number;
43
46
  }[];
44
47
  export declare function calculateUTRs2(cds: Feat[], parentFeat: Feat): {
45
48
  type: string;
@@ -12,6 +12,7 @@ export default class TextSearchManager {
12
12
  pluginManager: PluginManager;
13
13
  adapterCache: QuickLRU<string, BaseTextSearchAdapter>;
14
14
  constructor(pluginManager: PluginManager);
15
+ clearCache(): void;
15
16
  loadTextSearchAdapters(searchScope: SearchScope): Promise<BaseTextSearchAdapter[]>;
16
17
  relevantAdapters(searchScope: SearchScope): ({
17
18
  [x: string]: any;
@@ -9,6 +9,9 @@ export default class TextSearchManager {
9
9
  constructor(pluginManager) {
10
10
  this.pluginManager = pluginManager;
11
11
  }
12
+ clearCache() {
13
+ this.adapterCache.clear();
14
+ }
12
15
  loadTextSearchAdapters(searchScope) {
13
16
  return Promise.all(this.relevantAdapters(searchScope).map(async (conf) => {
14
17
  const adapterId = readConfObject(conf, 'textSearchAdapterId');
@@ -1,8 +1,9 @@
1
1
  import { stitch } from "../BaseFeatureWidget/util.js";
2
2
  export function convertCodingSequenceToPeptides({ cds, sequence, codonTable, }) {
3
+ const phase = cds[0]?.phase ?? 0;
3
4
  const str = stitch(cds, sequence);
4
- let protein = '';
5
- for (let i = 0; i < str.length; i += 3) {
5
+ let protein = phase > 0 ? '&' : '';
6
+ for (let i = phase; i < str.length; i += 3) {
6
7
  protein += codonTable[str.slice(i, i + 3)] || '&';
7
8
  }
8
9
  return protein;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jbrowse/core",
3
- "version": "4.1.13",
3
+ "version": "4.1.14",
4
4
  "type": "module",
5
5
  "description": "JBrowse 2 core libraries used by plugins",
6
6
  "keywords": [
@@ -476,11 +476,11 @@
476
476
  "@emotion/react": "^11.14.0",
477
477
  "@emotion/serialize": "^1.3.3",
478
478
  "@emotion/utils": "^1.4.2",
479
- "@floating-ui/react": "^0.27.18",
479
+ "@floating-ui/react": "^0.27.19",
480
480
  "@gmod/abortable-promise-cache": "^3.0.4",
481
481
  "@gmod/bgzf-filehandle": "^6.0.12",
482
482
  "@gmod/http-range-fetcher": "^5.0.7",
483
- "@jbrowse/jexl": "^3.0.1",
483
+ "@jbrowse/jexl": "^3.0.2",
484
484
  "@jbrowse/mobx-state-tree": "^5.5.0",
485
485
  "@jbrowse/quick-lru": "^7.3.5",
486
486
  "@leeoniya/ufuzzy": "^1.0.19",
@@ -488,14 +488,14 @@
488
488
  "@mui/material": "^7.3.8",
489
489
  "@mui/system": "^7.3.8",
490
490
  "@mui/types": "^7.4.11",
491
- "@mui/x-data-grid": "^8.27.1",
491
+ "@mui/x-data-grid": "^8.27.3",
492
492
  "@types/file-saver-es": "^2.0.3",
493
493
  "canvas-sequencer-ts": "^3.1.3",
494
494
  "canvas2svg": "^1.0.16",
495
495
  "copy-to-clipboard": "^3.3.3",
496
496
  "deepmerge": "^4.3.1",
497
497
  "detect-node": "^2.1.0",
498
- "dompurify": "^3.3.1",
498
+ "dompurify": "^3.3.2",
499
499
  "escape-html": "^1.0.3",
500
500
  "fast-deep-equal": "^3.1.3",
501
501
  "file-saver-es": "^2.0.5",