@teselagen/ove 0.5.31-beta.1 → 0.5.31-beta.3

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/index.umd.js CHANGED
@@ -9854,16 +9854,25 @@ var __async = (__this, __arguments, generator) => {
9854
9854
  return value;
9855
9855
  }, "GetIntrinsic");
9856
9856
  var callBind$3 = { exports: {} };
9857
- var GetIntrinsic$4 = getIntrinsic;
9858
- var $defineProperty$2 = GetIntrinsic$4("%Object.defineProperty%", true) || false;
9859
- if ($defineProperty$2) {
9860
- try {
9861
- $defineProperty$2({}, "a", { value: 1 });
9862
- } catch (e2) {
9863
- $defineProperty$2 = false;
9857
+ var esDefineProperty;
9858
+ var hasRequiredEsDefineProperty;
9859
+ function requireEsDefineProperty() {
9860
+ if (hasRequiredEsDefineProperty)
9861
+ return esDefineProperty;
9862
+ hasRequiredEsDefineProperty = 1;
9863
+ var GetIntrinsic2 = getIntrinsic;
9864
+ var $defineProperty2 = GetIntrinsic2("%Object.defineProperty%", true) || false;
9865
+ if ($defineProperty2) {
9866
+ try {
9867
+ $defineProperty2({}, "a", { value: 1 });
9868
+ } catch (e2) {
9869
+ $defineProperty2 = false;
9870
+ }
9864
9871
  }
9872
+ esDefineProperty = $defineProperty2;
9873
+ return esDefineProperty;
9865
9874
  }
9866
- var esDefineProperty = $defineProperty$2;
9875
+ __name(requireEsDefineProperty, "requireEsDefineProperty");
9867
9876
  var GetIntrinsic$3 = getIntrinsic;
9868
9877
  var $gOPD$1 = GetIntrinsic$3("%Object.getOwnPropertyDescriptor%", true);
9869
9878
  if ($gOPD$1) {
@@ -9874,7 +9883,7 @@ var __async = (__this, __arguments, generator) => {
9874
9883
  }
9875
9884
  }
9876
9885
  var gopd$1 = $gOPD$1;
9877
- var $defineProperty$1 = esDefineProperty;
9886
+ var $defineProperty$1 = requireEsDefineProperty();
9878
9887
  var $SyntaxError = syntax;
9879
9888
  var $TypeError$4 = type$1;
9880
9889
  var gopd = gopd$1;
@@ -9915,7 +9924,7 @@ var __async = (__this, __arguments, generator) => {
9915
9924
  throw new $SyntaxError("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");
9916
9925
  }
9917
9926
  }, "defineDataProperty");
9918
- var $defineProperty = esDefineProperty;
9927
+ var $defineProperty = requireEsDefineProperty();
9919
9928
  var hasPropertyDescriptors = /* @__PURE__ */ __name(function hasPropertyDescriptors2() {
9920
9929
  return !!$defineProperty;
9921
9930
  }, "hasPropertyDescriptors");
@@ -9984,7 +9993,7 @@ var __async = (__this, __arguments, generator) => {
9984
9993
  var $apply = GetIntrinsic2("%Function.prototype.apply%");
9985
9994
  var $call = GetIntrinsic2("%Function.prototype.call%");
9986
9995
  var $reflectApply = GetIntrinsic2("%Reflect.apply%", true) || bind2.call($call, $apply);
9987
- var $defineProperty2 = esDefineProperty;
9996
+ var $defineProperty2 = requireEsDefineProperty();
9988
9997
  var $max = GetIntrinsic2("%Math.max%");
9989
9998
  module2.exports = /* @__PURE__ */ __name(function callBind2(originalFunction) {
9990
9999
  if (typeof originalFunction !== "function") {
@@ -63537,18 +63546,14 @@ ${latestSubscriptionCallbackError.current.stack}
63537
63546
  return /* @__PURE__ */ React$2.createElement(Icon, { className: "dt-eyeIcon", icon: "eye-open" });
63538
63547
  }
63539
63548
  };
63540
- const openColumn = __spreadProps(__spreadValues({}, viewColumn), {
63541
- render: (val2, record, rowInfo, props) => {
63549
+ const openColumn = /* @__PURE__ */ __name(({ onDoubleClick, history }) => __spreadProps(__spreadValues({}, viewColumn), {
63550
+ render: (val2, record, rowInfo) => {
63542
63551
  return /* @__PURE__ */ React$2.createElement(Tooltip, { content: "Open" }, /* @__PURE__ */ React$2.createElement(
63543
63552
  Button,
63544
63553
  {
63545
63554
  onClick: (e2) => {
63546
63555
  e2.stopPropagation();
63547
- props.onDoubleClick && props.onDoubleClick(
63548
- rowInfo.original,
63549
- rowInfo.index,
63550
- props.history
63551
- );
63556
+ onDoubleClick && onDoubleClick(rowInfo.original, rowInfo.index, history);
63552
63557
  },
63553
63558
  minimal: true,
63554
63559
  small: true,
@@ -63557,7 +63562,7 @@ ${latestSubscriptionCallbackError.current.stack}
63557
63562
  }
63558
63563
  ));
63559
63564
  }
63560
- });
63565
+ }), "openColumn");
63561
63566
  function convertSchema(schema2) {
63562
63567
  let schemaToUse = schema2;
63563
63568
  if (!schemaToUse.fields && Array.isArray(schema2)) {
@@ -75990,9 +75995,7 @@ ${latestSubscriptionCallbackError.current.stack}
75990
75995
  Popover,
75991
75996
  {
75992
75997
  position: "bottom",
75993
- onClose: () => {
75994
- setColumnFilterMenuOpen(false);
75995
- },
75998
+ onClose: () => setColumnFilterMenuOpen(false),
75996
75999
  isOpen: columnFilterMenuOpen,
75997
76000
  modifiers: {
75998
76001
  preventOverflow: { enabled: true },
@@ -76659,61 +76662,60 @@ ${latestSubscriptionCallbackError.current.stack}
76659
76662
  }
76660
76663
  ));
76661
76664
  }, "RenderCell");
76662
- const RenderColumns = /* @__PURE__ */ __name((props) => {
76663
- const {
76664
- addFilters,
76665
- cellRenderer,
76666
- change: change2,
76667
- columns,
76668
- currentParams,
76669
- compact: compact2,
76670
- editableCellValue,
76671
- editingCell,
76672
- editingCellSelectAll,
76673
- entities,
76674
- expandedEntityIdMap,
76675
- extraCompact,
76676
- filters,
76677
- getCellHoverText,
76678
- isCellEditable,
76679
- isEntityDisabled,
76680
- isLocalCall,
76681
- isSimple,
76682
- isSingleSelect,
76683
- isSelectionARectangle,
76684
- noDeselectAll,
76685
- noSelect,
76686
- noUserSelect,
76687
- onDeselect,
76688
- onMultiRowSelect,
76689
- onRowClick,
76690
- onRowSelect,
76691
- onSingleRowSelect,
76692
- order: order2,
76693
- primarySelectedCellId,
76694
- reduxFormCellValidation,
76695
- reduxFormSelectedEntityIdMap,
76696
- refocusTable,
76697
- removeSingleFilter = noop$6,
76698
- schema: schema2,
76699
- selectedCells,
76700
- setEditableCellValue,
76701
- setEditingCell,
76702
- setExpandedEntityIdMap,
76703
- setNewParams,
76704
- setOrder = noop$6,
76705
- setSelectedCells,
76706
- shouldShowSubComponent,
76707
- startCellEdit,
76708
- SubComponent,
76709
- tableRef,
76710
- updateEntitiesHelper,
76711
- updateValidation,
76712
- withCheckboxes,
76713
- withExpandAndCollapseAllButton,
76714
- withFilter: _withFilter,
76715
- withSort = true
76716
- } = props;
76665
+ const RenderColumns = /* @__PURE__ */ __name(({
76666
+ addFilters,
76667
+ cellRenderer,
76668
+ change: change2,
76669
+ columns,
76670
+ currentParams,
76671
+ compact: compact2,
76672
+ editableCellValue,
76673
+ editingCell,
76674
+ editingCellSelectAll,
76675
+ entities,
76676
+ expandedEntityIdMap,
76677
+ extraCompact,
76678
+ filters,
76679
+ getCellHoverText,
76680
+ isCellEditable,
76681
+ isEntityDisabled,
76682
+ isLocalCall,
76683
+ isSimple,
76684
+ isSingleSelect,
76685
+ isSelectionARectangle,
76686
+ noDeselectAll,
76687
+ noSelect,
76688
+ noUserSelect,
76689
+ onDeselect,
76690
+ onMultiRowSelect,
76691
+ onRowClick,
76692
+ onRowSelect,
76693
+ onSingleRowSelect,
76694
+ order: order2,
76695
+ primarySelectedCellId,
76696
+ reduxFormCellValidation,
76697
+ reduxFormSelectedEntityIdMap,
76698
+ refocusTable,
76699
+ removeSingleFilter = noop$6,
76700
+ schema: schema2,
76701
+ selectedCells,
76702
+ setEditableCellValue,
76703
+ setEditingCell,
76704
+ setExpandedEntityIdMap,
76705
+ setNewParams,
76706
+ setOrder = noop$6,
76707
+ setSelectedCells,
76708
+ shouldShowSubComponent,
76709
+ startCellEdit,
76710
+ SubComponent,
76711
+ tableRef,
76712
+ updateEntitiesHelper,
76713
+ updateValidation,
76714
+ withCheckboxes,
76715
+ withExpandAndCollapseAllButton,
76716
+ withFilter: _withFilter,
76717
+ withSort = true
76718
+ }) => {
76717
76719
  const withFilter = _withFilter === void 0 ? !isSimple : _withFilter;
76718
76720
  const onDragEnd2 = /* @__PURE__ */ __name((cellsToSelect) => {
76719
76721
  const [primaryRowId, primaryCellPath] = primarySelectedCellId.split(":");
@@ -76885,13 +76887,19 @@ ${latestSubscriptionCallbackError.current.stack}
76885
76887
  let text2 = typeof val2 !== "string" ? row.value : val2;
76886
76888
  const record = row.original;
76887
76889
  if (column.getClipboardData) {
76888
- text2 = column.getClipboardData(row.value, record, row, props);
76890
+ text2 = column.getClipboardData(row.value, record, row);
76889
76891
  } else if (column.getValueToFilterOn) {
76890
- text2 = column.getValueToFilterOn(record, props);
76892
+ text2 = column.getValueToFilterOn(record);
76891
76893
  } else if (column.render) {
76892
- text2 = column.render(row.value, record, row, props);
76894
+ text2 = column.render(row.value, record, row, {
76895
+ currentParams,
76896
+ setNewParams
76897
+ });
76893
76898
  } else if (cellRenderer && cellRenderer[column.path]) {
76894
- text2 = cellRenderer[column.path](row.value, row.original, row, props);
76899
+ text2 = cellRenderer[column.path](row.value, row.original, row, {
76900
+ currentParams,
76901
+ setNewParams
76902
+ });
76895
76903
  } else if (text2) {
76896
76904
  text2 = reactExports.isValidElement(text2) ? text2 : String(text2);
76897
76905
  }
@@ -77109,17 +77117,18 @@ ${latestSubscriptionCallbackError.current.stack}
77109
77117
  }
77110
77118
  if (cellRenderer && cellRenderer[column.path]) {
77111
77119
  tableColumn.Cell = (row) => {
77112
- const val2 = cellRenderer[column.path](
77113
- row.value,
77114
- row.original,
77115
- row,
77116
- props
77117
- );
77120
+ const val2 = cellRenderer[column.path](row.value, row.original, row, {
77121
+ currentParams,
77122
+ setNewParams
77123
+ });
77118
77124
  return val2;
77119
77125
  };
77120
77126
  } else if (column.render) {
77121
77127
  tableColumn.Cell = (row) => {
77122
- const val2 = column.render(row.value, row.original, row, props);
77128
+ const val2 = column.render(row.value, row.original, row, {
77129
+ currentParams,
77130
+ setNewParams
77131
+ });
77123
77132
  return val2;
77124
77133
  };
77125
77134
  } else if (column.type === "timestamp") {
@@ -77307,12 +77316,13 @@ ${latestSubscriptionCallbackError.current.stack}
77307
77316
  // }
77308
77317
  ]
77309
77318
  }, props.defaults || {}));
77310
- let _schema;
77311
- if (isFunction$1(__schema))
77312
- _schema = __schema(props);
77313
- else
77314
- _schema = __schema;
77315
- const convertedSchema = convertSchema(_schema);
77319
+ const _schema = reactExports.useMemo(() => {
77320
+ if (isFunction$1(__schema))
77321
+ return __schema(props);
77322
+ else
77323
+ return __schema;
77324
+ }, [__schema, props]);
77325
+ const convertedSchema = reactExports.useMemo(() => convertSchema(_schema), [_schema]);
77316
77326
  if (isLocalCall) {
77317
77327
  if (!noForm && (!formName || formName === "tgDataTable")) {
77318
77328
  throw new Error(
@@ -77349,20 +77359,11 @@ ${latestSubscriptionCallbackError.current.stack}
77349
77359
  props = __spreadValues(__spreadValues({}, props), withSelectedEntities2 && typeof withSelectedEntities2 === "string" && {
77350
77360
  [withSelectedEntities2]: selectedEntities
77351
77361
  });
77352
- console.log("history.location", history);
77353
77362
  const currentParams = reactExports.useMemo(() => {
77354
- const tmp = (urlConnected ? getCurrentParamsFromUrl(
77355
- history ? history.location : ownProps.location
77356
- ) : reduxFormQueryParams) || {};
77363
+ const tmp = (urlConnected ? getCurrentParamsFromUrl(history.location) : reduxFormQueryParams) || {};
77357
77364
  tmp.searchTerm = reduxFormSearchInput;
77358
77365
  return tmp;
77359
- }, [
77360
- history,
77361
- ownProps.location,
77362
- reduxFormQueryParams,
77363
- reduxFormSearchInput,
77364
- urlConnected
77365
- ]);
77366
+ }, [history, reduxFormQueryParams, reduxFormSearchInput, urlConnected]);
77366
77367
  const tableParams = reactExports.useMemo(() => {
77367
77368
  if (!isTableParamsConnected) {
77368
77369
  const updateSearch = /* @__PURE__ */ __name((val2) => {
@@ -77399,7 +77400,7 @@ ${latestSubscriptionCallbackError.current.stack}
77399
77400
  _tableParams,
77400
77401
  change2,
77401
77402
  currentParams,
77402
- history.replace,
77403
+ history,
77403
77404
  isTableParamsConnected,
77404
77405
  props,
77405
77406
  selectedEntities,
@@ -77429,6 +77430,9 @@ ${latestSubscriptionCallbackError.current.stack}
77429
77430
  }
77430
77431
  return {};
77431
77432
  }, [
77433
+ props.entities,
77434
+ props.noOrderError,
77435
+ props.isCodeModel,
77432
77436
  convertedSchema,
77433
77437
  currentParams,
77434
77438
  doNotCoercePageSize,
@@ -77463,7 +77467,7 @@ ${latestSubscriptionCallbackError.current.stack}
77463
77467
  doNotShowEmptyRows,
77464
77468
  doNotValidateUntouchedRows,
77465
77469
  editingCellSelectAll,
77466
- entities: __origEntities = [],
77470
+ entities: _origEntities = [],
77467
77471
  entitiesAcrossPages: _entitiesAcrossPages,
77468
77472
  entityCount,
77469
77473
  errorParsingUrlString,
@@ -77544,10 +77548,11 @@ ${latestSubscriptionCallbackError.current.stack}
77544
77548
  withSort,
77545
77549
  withTitle = !isSimple
77546
77550
  } = props;
77547
- const _origEntities = useDeepEqualMemo(__origEntities);
77548
- const entities = useDeepEqualMemo(
77549
- ((reduxFormEntities == null ? void 0 : reduxFormEntities.length) ? reduxFormEntities : _origEntities) || []
77551
+ const _entities = reactExports.useMemo(
77552
+ () => ((reduxFormEntities == null ? void 0 : reduxFormEntities.length) ? reduxFormEntities : _origEntities) || [],
77553
+ [_origEntities, reduxFormEntities]
77550
77554
  );
77555
+ const entities = useDeepEqualMemo(_entities);
77551
77556
  const entitiesAcrossPages = useDeepEqualMemo(_entitiesAcrossPages);
77552
77557
  reactExports.useEffect(() => {
77553
77558
  if (change2) {
@@ -77584,12 +77589,15 @@ ${latestSubscriptionCallbackError.current.stack}
77584
77589
  withDisplayOptions
77585
77590
  ]);
77586
77591
  const schema2 = reactExports.useMemo(() => {
77587
- const schema22 = convertSchema(_schema);
77592
+ const schema22 = convertedSchema;
77588
77593
  if (isViewable) {
77589
77594
  schema22.fields = [viewColumn, ...schema22.fields];
77590
77595
  }
77591
77596
  if (isOpenable) {
77592
- schema22.fields = [openColumn, ...schema22.fields];
77597
+ schema22.fields = [
77598
+ openColumn({ onDoubleClick, history }),
77599
+ ...schema22.fields
77600
+ ];
77593
77601
  }
77594
77602
  schema22.fields = schema22.fields.map((field) => {
77595
77603
  if (field.placementPath) {
@@ -77651,13 +77659,15 @@ ${latestSubscriptionCallbackError.current.stack}
77651
77659
  }
77652
77660
  return schema22;
77653
77661
  }, [
77654
- _schema,
77655
77662
  cellRenderer,
77663
+ convertedSchema,
77656
77664
  entities,
77665
+ history,
77657
77666
  isInfinite,
77658
77667
  isOpenable,
77659
77668
  isSimple,
77660
77669
  isViewable,
77670
+ onDoubleClick,
77661
77671
  showForcedHiddenColumns,
77662
77672
  tableConfig.columnOrderings,
77663
77673
  tableConfig.fieldOptions,
@@ -79482,7 +79492,7 @@ ${latestSubscriptionCallbackError.current.stack}
79482
79492
  return entities;
79483
79493
  }, [entities, onlyShowRowsWErrors, reduxFormCellValidation]);
79484
79494
  const renderColumns = reactExports.useMemo(
79485
- () => RenderColumns(__spreadProps(__spreadValues({}, props), {
79495
+ () => RenderColumns({
79486
79496
  addFilters,
79487
79497
  cellRenderer,
79488
79498
  change: change2,
@@ -79535,7 +79545,7 @@ ${latestSubscriptionCallbackError.current.stack}
79535
79545
  withExpandAndCollapseAllButton,
79536
79546
  withFilter,
79537
79547
  withSort
79538
- })),
79548
+ }),
79539
79549
  // eslint-disable-next-line react-hooks/exhaustive-deps
79540
79550
  [
79541
79551
  SubComponent,
@@ -146285,7 +146295,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
146285
146295
  }
146286
146296
  __name(showFileDialog, "showFileDialog");
146287
146297
  const name = "@teselagen/ove";
146288
- const version = "0.5.30";
146298
+ const version = "0.5.31-beta.2";
146289
146299
  const main = "./src/index.js";
146290
146300
  const type = "module";
146291
146301
  const exports$1 = {
@@ -156815,42 +156825,19 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
156815
156825
  };
156816
156826
  __name(_ComponentToPrint, "ComponentToPrint");
156817
156827
  let ComponentToPrint = _ComponentToPrint;
156818
- const sizeSchema = {
156828
+ const sizeSchema = /* @__PURE__ */ __name((isProtein2) => ({
156819
156829
  path: "size",
156820
156830
  type: "number",
156821
- render: (val2, _record, i2, props) => {
156822
- const record = props.isProtein ? convertDnaCaretPositionOrRangeToAA(_record) : _record;
156831
+ render: (val2, _record) => {
156832
+ const record = isProtein2 ? convertDnaCaretPositionOrRangeToAA(_record) : _record;
156823
156833
  const base1Range = convertRangeTo1Based(record);
156824
156834
  const hasJoinedLocations = record.locations && record.locations.length > 1;
156825
- return /* @__PURE__ */ React$2.createElement("span", null, props.isProtein ? Math.floor(val2 / 3) : val2, " ", /* @__PURE__ */ React$2.createElement("span", { style: { fontSize: 10 } }, hasJoinedLocations ? record.locations.map((loc, i22) => {
156835
+ return /* @__PURE__ */ React$2.createElement("span", null, isProtein2 ? Math.floor(val2 / 3) : val2, " ", /* @__PURE__ */ React$2.createElement("span", { style: { fontSize: 10 } }, hasJoinedLocations ? record.locations.map((loc, i2) => {
156826
156836
  const base1Range2 = convertRangeTo1Based(loc);
156827
- return /* @__PURE__ */ React$2.createElement("span", { key: i22 }, "(", base1Range2.start, "-", base1Range2.end, ")");
156837
+ return /* @__PURE__ */ React$2.createElement("span", { key: i2 }, "(", base1Range2.start, "-", base1Range2.end, ")");
156828
156838
  }) : /* @__PURE__ */ React$2.createElement("span", null, "(", base1Range.start, "-", base1Range.end, ")")));
156829
156839
  }
156830
- };
156831
- const schema$2 = {
156832
- fields: [
156833
- // ...(noColor
156834
- // ? []
156835
- // : [
156836
- // {
156837
- // path: "color",
156838
- // type: "string",
156839
- // render: color => {
156840
- // return (
156841
- // <ColorPickerPopover>
156842
- // <div style={{ height: 20, width: 20, background: color }} />
156843
- // </ColorPickerPopover>
156844
- // );
156845
- // }
156846
- // }
156847
- // ]),
156848
- { path: "name", type: "string" },
156849
- // ...(noType ? [] : [{ path: "type", type: "string" }]),
156850
- sizeSchema,
156851
- { path: "strand", type: "string" }
156852
- ]
156853
- };
156840
+ }), "sizeSchema");
156854
156841
  const _RemoveDuplicatesDialog = class _RemoveDuplicatesDialog extends React$2.Component {
156855
156842
  constructor() {
156856
156843
  super(...arguments);
@@ -156896,6 +156883,29 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
156896
156883
  render() {
156897
156884
  const { duplicatesToRemoveSelectedEntities, hideModal, type: type2 } = this.props;
156898
156885
  const selectedIds = this.state.dups.map((d2) => d2.id);
156886
+ const schema2 = {
156887
+ fields: [
156888
+ // ...(noColor
156889
+ // ? []
156890
+ // : [
156891
+ // {
156892
+ // path: "color",
156893
+ // type: "string",
156894
+ // render: color => {
156895
+ // return (
156896
+ // <ColorPickerPopover>
156897
+ // <div style={{ height: 20, width: 20, background: color }} />
156898
+ // </ColorPickerPopover>
156899
+ // );
156900
+ // }
156901
+ // }
156902
+ // ]),
156903
+ { path: "name", type: "string" },
156904
+ // ...(noType ? [] : [{ path: "type", type: "string" }]),
156905
+ sizeSchema(this.props.isProtein),
156906
+ { path: "strand", type: "string" }
156907
+ ]
156908
+ };
156899
156909
  return /* @__PURE__ */ React$2.createElement("div", { className: classNames$1(DIALOG_BODY, "tg-min-width-dialog") }, /* @__PURE__ */ React$2.createElement(
156900
156910
  WrappedDT,
156901
156911
  {
@@ -156913,7 +156923,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
156913
156923
  withSearch: false,
156914
156924
  hideSelectedCount: true,
156915
156925
  isInfinite: true,
156916
- schema: schema$2,
156926
+ schema: schema2,
156917
156927
  entities: this.state.dups
156918
156928
  }
156919
156929
  ), /* @__PURE__ */ React$2.createElement(
@@ -160537,7 +160547,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
160537
160547
  RenderBases2,
160538
160548
  __spreadValues({}, {
160539
160549
  // ...this.props,
160540
- // bases,
160550
+ bases,
160541
160551
  defaultLinkedOligoMessage,
160542
160552
  getLinkedOligoLink,
160543
160553
  readOnly: this.props.readOnly,
@@ -161126,9 +161136,9 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
161126
161136
  start: start2,
161127
161137
  end: end2,
161128
161138
  primerBindsOn,
161129
- bases,
161130
161139
  forward
161131
161140
  }) {
161141
+ const bases = input.value;
161132
161142
  const [hasTempError, setTempError] = reactExports.useState(false);
161133
161143
  const inputRef = reactExports.useRef(null);
161134
161144
  const [caretPosition2, setCaretPosition] = reactExports.useState({ start: 0, end: 0 });
@@ -161257,7 +161267,6 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
161257
161267
  normalizedSelection,
161258
161268
  sequenceData2.sequence
161259
161269
  );
161260
- console.log("bps", bps);
161261
161270
  if (!forward) {
161262
161271
  bps = getReverseComplementSequenceString(bps);
161263
161272
  }
@@ -166132,13 +166141,38 @@ ${seqDataToCopy}\r
166132
166141
  });
166133
166142
  }, "onRowSelect"));
166134
166143
  this.commands = getCommands(this);
166144
+ }
166145
+ render() {
166146
+ var _a2;
166147
+ const {
166148
+ readOnly: readOnly2,
166149
+ annotations = {},
166150
+ annotationVisibility: annotationVisibility2,
166151
+ sequenceLength,
166152
+ selectionLayer: selectionLayer2,
166153
+ sequence: sequence2,
166154
+ isProtein: isProtein2,
166155
+ allPartTags,
166156
+ annotationPropertiesSelectedEntities: _annotationPropertiesSelectedEntities,
166157
+ selectedAnnotationId
166158
+ } = this.props;
166159
+ const annotationPropertiesSelectedEntities = _annotationPropertiesSelectedEntities.filter((a2) => annotations[a2.id]);
166160
+ const deleteAnnotation = this.props[`delete${annotationTypeUpper}`];
166161
+ const annotationsToUse = map$3(annotations, (annotation) => {
166162
+ return __spreadProps(__spreadValues(__spreadValues({}, annotation), annotation.strand === void 0 && {
166163
+ strand: annotation.forward ? 1 : -1
166164
+ }), {
166165
+ size: getRangeLength(annotation, sequenceLength)
166166
+ });
166167
+ });
166168
+ const keyedPartTags = (_a2 = getKeyedTagsAndTagOptions(allPartTags)) != null ? _a2 : {};
166135
166169
  this.schema = {
166136
166170
  fields: [
166137
166171
  {
166138
166172
  path: "name",
166139
166173
  type: "string",
166140
- render: (name2, ann, row, props2) => {
166141
- const checked = !props2.annotationVisibility[`${annotationType}IndividualToHide`][ann.id];
166174
+ render: (name2, ann) => {
166175
+ const checked = !this.props.annotationVisibility[`${annotationType}IndividualToHide`][ann.id];
166142
166176
  return /* @__PURE__ */ React$2.createElement(React$2.Fragment, null, /* @__PURE__ */ React$2.createElement(
166143
166177
  Icon,
166144
166178
  {
@@ -166147,9 +166181,9 @@ ${seqDataToCopy}\r
166147
166181
  e2.stopPropagation();
166148
166182
  const upperType = startCase(annotationType);
166149
166183
  if (checked) {
166150
- props2[`hide${upperType}Individual`]([ann.id]);
166184
+ this.props[`hide${upperType}Individual`]([ann.id]);
166151
166185
  } else {
166152
- props2[`show${upperType}Individual`]([ann.id]);
166186
+ this.props[`show${upperType}Individual`]([ann.id]);
166153
166187
  }
166154
166188
  },
166155
166189
  style: {
@@ -166167,10 +166201,10 @@ ${seqDataToCopy}\r
166167
166201
  {
166168
166202
  path: "bases",
166169
166203
  type: "string",
166170
- render: (bases, primer, row, props2) => {
166204
+ render: (bases, primer) => {
166171
166205
  let bps = bases;
166172
166206
  if (!bases) {
166173
- bps = getSequenceWithinRange(primer, props2.sequence);
166207
+ bps = getSequenceWithinRange(primer, this.props.sequence);
166174
166208
  if (!primer.forward) {
166175
166209
  bps = getReverseComplementSequenceString(bps);
166176
166210
  }
@@ -166195,12 +166229,12 @@ ${seqDataToCopy}\r
166195
166229
  }
166196
166230
  }
166197
166231
  ],
166198
- sizeSchema,
166232
+ sizeSchema(this.props.isProtein),
166199
166233
  ...withTags && this.props.allPartTags ? [
166200
166234
  {
166201
166235
  path: "tags",
166202
166236
  type: "string",
166203
- getValueToFilterOn: (o2, { keyedPartTags }) => {
166237
+ getValueToFilterOn: (o2) => {
166204
166238
  const toRet = (o2.tags || []).map((tagId) => {
166205
166239
  const tag = keyedPartTags[tagId];
166206
166240
  if (!tag)
@@ -166209,7 +166243,7 @@ ${seqDataToCopy}\r
166209
166243
  }).join(" ");
166210
166244
  return toRet;
166211
166245
  },
166212
- render: (tags, b3, c2, { keyedPartTags = {} }) => {
166246
+ render: (tags) => {
166213
166247
  return /* @__PURE__ */ React$2.createElement("div", { style: { display: "flex" } }, (tags || []).map((tagId, i2) => {
166214
166248
  const tag = keyedPartTags[tagId];
166215
166249
  if (!tag)
@@ -166222,29 +166256,6 @@ ${seqDataToCopy}\r
166222
166256
  { path: "strand", type: "number" }
166223
166257
  ]
166224
166258
  };
166225
- }
166226
- render() {
166227
- const {
166228
- readOnly: readOnly2,
166229
- annotations = {},
166230
- annotationVisibility: annotationVisibility2,
166231
- sequenceLength,
166232
- selectionLayer: selectionLayer2,
166233
- sequence: sequence2,
166234
- isProtein: isProtein2,
166235
- allPartTags,
166236
- annotationPropertiesSelectedEntities: _annotationPropertiesSelectedEntities,
166237
- selectedAnnotationId
166238
- } = this.props;
166239
- const annotationPropertiesSelectedEntities = _annotationPropertiesSelectedEntities.filter((a2) => annotations[a2.id]);
166240
- const deleteAnnotation = this.props[`delete${annotationTypeUpper}`];
166241
- const annotationsToUse = map$3(annotations, (annotation) => {
166242
- return __spreadProps(__spreadValues(__spreadValues({}, annotation), annotation.strand === void 0 && {
166243
- strand: annotation.forward ? 1 : -1
166244
- }), {
166245
- size: getRangeLength(annotation, sequenceLength)
166246
- });
166247
- });
166248
166259
  return /* @__PURE__ */ React$2.createElement(
166249
166260
  WrappedDT,
166250
166261
  {
@@ -166365,7 +166376,6 @@ ${seqDataToCopy}\r
166365
166376
  formName: "annotationProperties",
166366
166377
  noRouter: true,
166367
166378
  isProtein: isProtein2,
166368
- keyedPartTags: getKeyedTagsAndTagOptions(allPartTags),
166369
166379
  compact: true,
166370
166380
  isInfinite: true,
166371
166381
  schema: this.schema,
@@ -166728,7 +166738,7 @@ ${seqDataToCopy}\r
166728
166738
  displayName: "Size (aa)",
166729
166739
  type: "number"
166730
166740
  },
166731
- sizeSchema,
166741
+ sizeSchema(this.props.isProtein),
166732
166742
  { path: "frame", type: "number" },
166733
166743
  { path: "strand", type: "number" }
166734
166744
  ]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@teselagen/ove",
3
- "version": "0.5.31-beta.1",
3
+ "version": "0.5.31-beta.3",
4
4
  "main": "./src/index.js",
5
5
  "exports": {
6
6
  ".": {
@@ -12,7 +12,7 @@
12
12
  "dependencies": {
13
13
  "@teselagen/sequence-utils": "0.3.27",
14
14
  "@teselagen/range-utils": "0.3.7",
15
- "@teselagen/ui": "0.5.23-beta.6",
15
+ "@teselagen/ui": "0.5.23-beta.12",
16
16
  "@teselagen/file-utils": "0.3.16",
17
17
  "@teselagen/bounce-loader": "0.3.11",
18
18
  "@teselagen/bio-parsers": "0.4.22",