@teselagen/ove 0.7.24 → 0.7.25

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.
@@ -273,7 +273,7 @@ export namespace commandDefs {
273
273
  export { hotkey_9 as hotkey };
274
274
  }
275
275
  namespace createNewFromSubsequence {
276
- let name_10: string;
276
+ export function name_10(props: any): "Create New AA Sequence From Selection" | "Create New Oligo From Selection" | "Create New DNA Sequence From Selection";
277
277
  export { name_10 as name };
278
278
  export function isDisabled_8(props: any): boolean;
279
279
  export { isDisabled_8 as isDisabled };
package/index.cjs.js CHANGED
@@ -123051,7 +123051,7 @@ function showFileDialog({ multiple = false, onSelect }) {
123051
123051
  }
123052
123052
  __name(showFileDialog, "showFileDialog");
123053
123053
  const name = "@teselagen/ove";
123054
- const version = "0.7.23";
123054
+ const version = "0.7.24";
123055
123055
  const main = "./src/index.js";
123056
123056
  const type = "module";
123057
123057
  const exports$1 = {
@@ -123965,7 +123965,7 @@ const fileCommandDefs = __spreadValues(__spreadProps(__spreadValues({
123965
123965
  handler: /* @__PURE__ */ __name((props) => props.exportSequenceToFile(isProtein(props) ? "genpept" : "genbank"), "handler")
123966
123966
  },
123967
123967
  exportDNASequenceAsFasta: {
123968
- name: /* @__PURE__ */ __name((props) => `Download ${props.sequenceData.isProtein ? "DNA " : ""}FASTA File`, "name"),
123968
+ name: /* @__PURE__ */ __name((props) => `Download ${isProtein(props) ? "DNA " : ""}FASTA File`, "name"),
123969
123969
  isHidden: /* @__PURE__ */ __name((props) => !props.sequenceData.sequence, "isHidden"),
123970
123970
  handler: /* @__PURE__ */ __name((props) => props.exportSequenceToFile("fasta", {
123971
123971
  sequence: props.sequenceData.sequence,
@@ -124096,7 +124096,7 @@ const editCommandDefs = __spreadValues(__spreadProps(__spreadValues({
124096
124096
  hotkey: "mod+x"
124097
124097
  },
124098
124098
  createNewFromSubsequence: {
124099
- name: "New Sequence From Selected Range",
124099
+ name: /* @__PURE__ */ __name((props) => isProtein(props) ? "Create New AA Sequence From Selection" : isOligo(props) ? "Create New Oligo From Selection" : "Create New DNA Sequence From Selection", "name"),
124100
124100
  isDisabled: /* @__PURE__ */ __name((props) => props.sequenceLength === 0 || props.selectionLayer.start === -1, "isDisabled"),
124101
124101
  isHidden: /* @__PURE__ */ __name((props) => !props.onCreateNewFromSubsequence, "isHidden"),
124102
124102
  handler: /* @__PURE__ */ __name((props) => {
@@ -124732,11 +124732,6 @@ const annotationToggleCommandDefs = {};
124732
124732
  return !props.annotationVisibility.features && "Features must be visible to view their translations" || !props.annotationVisibility.translations && "Translations must be visible to view CDS feature translations";
124733
124733
  }, "isDisabled")
124734
124734
  },
124735
- // {
124736
- // type: "aminoAcidNumbers",
124737
- // isHidden: (p, c) =>
124738
- // (c.isDnaMenu && p.isProtein) || (!c.isDnaMenu && !p.isProtein)
124739
- // },
124740
124735
  { type: "aminoAcidNumbers" },
124741
124736
  "axisNumbers",
124742
124737
  {
@@ -124811,7 +124806,7 @@ const additionalAnnotationCommandsDefs = {
124811
124806
  showAll: {
124812
124807
  handler: /* @__PURE__ */ __name((props) => {
124813
124808
  annotationTypes.forEach((type2) => {
124814
- if (props.isProtein) {
124809
+ if (isProtein(props)) {
124815
124810
  if (type2 === "translations" || type2 === "cutsites")
124816
124811
  return props.annotationVisibilityHide(type2);
124817
124812
  }
@@ -155283,6 +155278,7 @@ exports.actions = actions;
155283
155278
  exports.addAlignment = addAlignment;
155284
155279
  exports.connectToEditor = connectToEditor;
155285
155280
  exports.createVectorEditor = createVectorEditor;
155281
+ exports.divideBy3 = divideBy3;
155286
155282
  exports.getOveHotkeyDefs = getOveHotkeyDefs;
155287
155283
  exports.getRangeAnglesSpecial = getRangeAnglesSpecial;
155288
155284
  exports.getStructuredBases = getStructuredBases;
package/index.d.ts CHANGED
@@ -17,6 +17,7 @@ export { default as EnzymeViewer } from './EnzymeViewer';
17
17
  export { default as AlignmentView } from './AlignmentView';
18
18
  export { default as getOveHotkeyDefs } from './commands/getOveHotkeyDefs';
19
19
  export { getStructuredBases } from './RowItem/StackedAnnotations/getStructuredBases';
20
+ export { divideBy3 } from './utils/proteinUtils';
20
21
  export { default as withEditorProps, connectToEditor } from './withEditorProps';
21
22
  export { default as Editor, Editor as EditorUnconnected } from './Editor';
22
23
  export { default as CutsiteFilter, CutsiteFilter as CutsiteFilterUnconnected } from './CutsiteFilter';
package/index.es.js CHANGED
@@ -123033,7 +123033,7 @@ function showFileDialog({ multiple = false, onSelect }) {
123033
123033
  }
123034
123034
  __name(showFileDialog, "showFileDialog");
123035
123035
  const name = "@teselagen/ove";
123036
- const version = "0.7.23";
123036
+ const version = "0.7.24";
123037
123037
  const main = "./src/index.js";
123038
123038
  const type = "module";
123039
123039
  const exports$1 = {
@@ -123947,7 +123947,7 @@ const fileCommandDefs = __spreadValues(__spreadProps(__spreadValues({
123947
123947
  handler: /* @__PURE__ */ __name((props) => props.exportSequenceToFile(isProtein(props) ? "genpept" : "genbank"), "handler")
123948
123948
  },
123949
123949
  exportDNASequenceAsFasta: {
123950
- name: /* @__PURE__ */ __name((props) => `Download ${props.sequenceData.isProtein ? "DNA " : ""}FASTA File`, "name"),
123950
+ name: /* @__PURE__ */ __name((props) => `Download ${isProtein(props) ? "DNA " : ""}FASTA File`, "name"),
123951
123951
  isHidden: /* @__PURE__ */ __name((props) => !props.sequenceData.sequence, "isHidden"),
123952
123952
  handler: /* @__PURE__ */ __name((props) => props.exportSequenceToFile("fasta", {
123953
123953
  sequence: props.sequenceData.sequence,
@@ -124078,7 +124078,7 @@ const editCommandDefs = __spreadValues(__spreadProps(__spreadValues({
124078
124078
  hotkey: "mod+x"
124079
124079
  },
124080
124080
  createNewFromSubsequence: {
124081
- name: "New Sequence From Selected Range",
124081
+ name: /* @__PURE__ */ __name((props) => isProtein(props) ? "Create New AA Sequence From Selection" : isOligo(props) ? "Create New Oligo From Selection" : "Create New DNA Sequence From Selection", "name"),
124082
124082
  isDisabled: /* @__PURE__ */ __name((props) => props.sequenceLength === 0 || props.selectionLayer.start === -1, "isDisabled"),
124083
124083
  isHidden: /* @__PURE__ */ __name((props) => !props.onCreateNewFromSubsequence, "isHidden"),
124084
124084
  handler: /* @__PURE__ */ __name((props) => {
@@ -124714,11 +124714,6 @@ const annotationToggleCommandDefs = {};
124714
124714
  return !props.annotationVisibility.features && "Features must be visible to view their translations" || !props.annotationVisibility.translations && "Translations must be visible to view CDS feature translations";
124715
124715
  }, "isDisabled")
124716
124716
  },
124717
- // {
124718
- // type: "aminoAcidNumbers",
124719
- // isHidden: (p, c) =>
124720
- // (c.isDnaMenu && p.isProtein) || (!c.isDnaMenu && !p.isProtein)
124721
- // },
124722
124717
  { type: "aminoAcidNumbers" },
124723
124718
  "axisNumbers",
124724
124719
  {
@@ -124793,7 +124788,7 @@ const additionalAnnotationCommandsDefs = {
124793
124788
  showAll: {
124794
124789
  handler: /* @__PURE__ */ __name((props) => {
124795
124790
  annotationTypes.forEach((type2) => {
124796
- if (props.isProtein) {
124791
+ if (isProtein(props)) {
124797
124792
  if (type2 === "translations" || type2 === "cutsites")
124798
124793
  return props.annotationVisibilityHide(type2);
124799
124794
  }
@@ -155266,6 +155261,7 @@ export {
155266
155261
  addAlignment,
155267
155262
  connectToEditor,
155268
155263
  createVectorEditor,
155264
+ divideBy3,
155269
155265
  getGaps,
155270
155266
  getOveHotkeyDefs,
155271
155267
  getRangeAnglesSpecial,
package/index.umd.js CHANGED
@@ -150928,7 +150928,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
150928
150928
  }
150929
150929
  __name(showFileDialog, "showFileDialog");
150930
150930
  const name = "@teselagen/ove";
150931
- const version = "0.7.23";
150931
+ const version = "0.7.24";
150932
150932
  const main = "./src/index.js";
150933
150933
  const type = "module";
150934
150934
  const exports$1 = {
@@ -151842,7 +151842,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
151842
151842
  handler: /* @__PURE__ */ __name((props) => props.exportSequenceToFile(isProtein(props) ? "genpept" : "genbank"), "handler")
151843
151843
  },
151844
151844
  exportDNASequenceAsFasta: {
151845
- name: /* @__PURE__ */ __name((props) => `Download ${props.sequenceData.isProtein ? "DNA " : ""}FASTA File`, "name"),
151845
+ name: /* @__PURE__ */ __name((props) => `Download ${isProtein(props) ? "DNA " : ""}FASTA File`, "name"),
151846
151846
  isHidden: /* @__PURE__ */ __name((props) => !props.sequenceData.sequence, "isHidden"),
151847
151847
  handler: /* @__PURE__ */ __name((props) => props.exportSequenceToFile("fasta", {
151848
151848
  sequence: props.sequenceData.sequence,
@@ -151973,7 +151973,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
151973
151973
  hotkey: "mod+x"
151974
151974
  },
151975
151975
  createNewFromSubsequence: {
151976
- name: "New Sequence From Selected Range",
151976
+ name: /* @__PURE__ */ __name((props) => isProtein(props) ? "Create New AA Sequence From Selection" : isOligo(props) ? "Create New Oligo From Selection" : "Create New DNA Sequence From Selection", "name"),
151977
151977
  isDisabled: /* @__PURE__ */ __name((props) => props.sequenceLength === 0 || props.selectionLayer.start === -1, "isDisabled"),
151978
151978
  isHidden: /* @__PURE__ */ __name((props) => !props.onCreateNewFromSubsequence, "isHidden"),
151979
151979
  handler: /* @__PURE__ */ __name((props) => {
@@ -152609,11 +152609,6 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
152609
152609
  return !props.annotationVisibility.features && "Features must be visible to view their translations" || !props.annotationVisibility.translations && "Translations must be visible to view CDS feature translations";
152610
152610
  }, "isDisabled")
152611
152611
  },
152612
- // {
152613
- // type: "aminoAcidNumbers",
152614
- // isHidden: (p, c) =>
152615
- // (c.isDnaMenu && p.isProtein) || (!c.isDnaMenu && !p.isProtein)
152616
- // },
152617
152612
  { type: "aminoAcidNumbers" },
152618
152613
  "axisNumbers",
152619
152614
  {
@@ -152688,7 +152683,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
152688
152683
  showAll: {
152689
152684
  handler: /* @__PURE__ */ __name((props) => {
152690
152685
  annotationTypes.forEach((type2) => {
152691
- if (props.isProtein) {
152686
+ if (isProtein(props)) {
152692
152687
  if (type2 === "translations" || type2 === "cutsites")
152693
152688
  return props.annotationVisibilityHide(type2);
152694
152689
  }
@@ -189405,6 +189400,7 @@ ${seqDataToCopy}\r
189405
189400
  exports2.addAlignment = addAlignment;
189406
189401
  exports2.connectToEditor = connectToEditor;
189407
189402
  exports2.createVectorEditor = createVectorEditor;
189403
+ exports2.divideBy3 = divideBy3;
189408
189404
  exports2.getOveHotkeyDefs = getOveHotkeyDefs;
189409
189405
  exports2.getRangeAnglesSpecial = getRangeAnglesSpecial;
189410
189406
  exports2.getStructuredBases = getStructuredBases;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@teselagen/ove",
3
- "version": "0.7.24",
3
+ "version": "0.7.25",
4
4
  "main": "./src/index.js",
5
5
  "type": "module",
6
6
  "exports": {
@@ -265,8 +265,7 @@ const fileCommandDefs = {
265
265
  props.exportSequenceToFile(isProtein(props) ? "genpept" : "genbank")
266
266
  },
267
267
  exportDNASequenceAsFasta: {
268
- name: props =>
269
- `Download ${props.sequenceData.isProtein ? "DNA " : ""}FASTA File`,
268
+ name: props => `Download ${isProtein(props) ? "DNA " : ""}FASTA File`,
270
269
  isHidden: props => !props.sequenceData.sequence,
271
270
  handler: props =>
272
271
  props.exportSequenceToFile("fasta", {
@@ -418,7 +417,12 @@ const editCommandDefs = {
418
417
  hotkey: "mod+x"
419
418
  },
420
419
  createNewFromSubsequence: {
421
- name: "New Sequence From Selected Range",
420
+ name: props =>
421
+ isProtein(props)
422
+ ? "Create New AA Sequence From Selection"
423
+ : isOligo(props)
424
+ ? "Create New Oligo From Selection"
425
+ : "Create New DNA Sequence From Selection",
422
426
  isDisabled: props =>
423
427
  props.sequenceLength === 0 || props.selectionLayer.start === -1,
424
428
  isHidden: props => !props.onCreateNewFromSubsequence,
@@ -1190,11 +1194,6 @@ const annotationToggleCommandDefs = {};
1190
1194
  );
1191
1195
  }
1192
1196
  },
1193
- // {
1194
- // type: "aminoAcidNumbers",
1195
- // isHidden: (p, c) =>
1196
- // (c.isDnaMenu && p.isProtein) || (!c.isDnaMenu && !p.isProtein)
1197
- // },
1198
1197
  { type: "aminoAcidNumbers" },
1199
1198
  "axisNumbers",
1200
1199
  {
@@ -1288,7 +1287,7 @@ const additionalAnnotationCommandsDefs = {
1288
1287
  showAll: {
1289
1288
  handler: props => {
1290
1289
  annotationTypes.forEach(type => {
1291
- if (props.isProtein) {
1290
+ if (isProtein(props)) {
1292
1291
  if (type === "translations" || type === "cutsites")
1293
1292
  return props.annotationVisibilityHide(type);
1294
1293
  }
@@ -1306,10 +1305,6 @@ const additionalAnnotationCommandsDefs = {
1306
1305
  showAllLabels: {
1307
1306
  handler: props => {
1308
1307
  annotationTypes.forEach(type => {
1309
- // if (props.isProtein) {
1310
- // if (type === "translations" || type === "cutsites")
1311
- // return props.annotationVisibilityHide(type);
1312
- // }
1313
1308
  props.annotationLabelVisibilityShow(type);
1314
1309
  });
1315
1310
  }
package/src/index.js CHANGED
@@ -52,3 +52,4 @@ export { default as EnzymeViewer } from "./EnzymeViewer";
52
52
  export { default as AlignmentView } from "./AlignmentView";
53
53
  export { default as getOveHotkeyDefs } from "./commands/getOveHotkeyDefs";
54
54
  export { getStructuredBases } from "./RowItem/StackedAnnotations/getStructuredBases";
55
+ export { divideBy3 } from "./utils/proteinUtils";