@teselagen/ove 0.7.14 → 0.7.16

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
@@ -59,7 +59,7 @@ var __async = (__this, __arguments, generator) => {
59
59
  });
60
60
  };
61
61
 
62
- var _E, _F, _G, _H, _I, _J, _M, _P, _W;
62
+ var _C, _D, _E, _F, _G, _H, _K, _N, _U;
63
63
  function _mergeNamespaces(n2, m2) {
64
64
  for (var i2 = 0; i2 < m2.length; i2++) {
65
65
  const e2 = m2[i2];
@@ -61046,37 +61046,7 @@ ${latestSubscriptionCallbackError.current.stack}
61046
61046
  * See the License for the specific language governing permissions and
61047
61047
  * limitations under the License.
61048
61048
  */
61049
- const sortKeys = /* @__PURE__ */ __name((o2) => {
61050
- if (Array.isArray(o2)) {
61051
- return o2.map(sortKeys);
61052
- } else if (o2 instanceof Object) {
61053
- let numeric = [];
61054
- let nonNumeric = [];
61055
- Object.keys(o2).forEach((key2) => {
61056
- if (/^(0|[1-9][0-9]*)$/.test(key2)) {
61057
- numeric.push(+key2);
61058
- } else {
61059
- nonNumeric.push(key2);
61060
- }
61061
- });
61062
- return numeric.sort(function(a2, b3) {
61063
- return a2 - b3;
61064
- }).concat(nonNumeric.sort()).reduce((result, key2) => {
61065
- result[key2] = sortKeys(o2[key2]);
61066
- return result;
61067
- }, {});
61068
- }
61069
- return o2;
61070
- }, "sortKeys");
61071
- const jsonStringify = JSON.stringify.bind(JSON);
61072
- const sortify = /* @__PURE__ */ __name((value, replacer, space2) => {
61073
- let nativeJson = jsonStringify(value, replacer, 0);
61074
- if (!nativeJson || nativeJson[0] !== "{" && nativeJson[0] !== "[") {
61075
- return nativeJson;
61076
- }
61077
- let cleanObj = JSON.parse(nativeJson);
61078
- return jsonStringify(sortKeys(cleanObj), null, space2);
61079
- }, "sortify");
61049
+ JSON.stringify.bind(JSON);
61080
61050
  const REQUIRED_ERROR = "This field is required.";
61081
61051
  const fieldRequired = /* @__PURE__ */ __name((value) => !value || Array.isArray(value) && !value.length ? REQUIRED_ERROR : void 0, "fieldRequired");
61082
61052
  const useStableReference = /* @__PURE__ */ __name((value) => {
@@ -61683,98 +61653,15 @@ ${latestSubscriptionCallbackError.current.stack}
61683
61653
  });
61684
61654
  return /* @__PURE__ */ React$2.createElement(TgSelect$1, __spreadValues({}, propsToUse));
61685
61655
  }, "renderReactSelect");
61686
- const BPSelect = /* @__PURE__ */ __name((_q) => {
61687
- var _r = _q, { value, onChange } = _r, rest = __objRest(_r, ["value", "onChange"]);
61688
- return renderSelect(__spreadProps(__spreadValues({}, rest), { input: { onChange, value } }));
61689
- }, "BPSelect");
61690
- const renderSelect = /* @__PURE__ */ __name((_s) => {
61691
- var _t = _s, {
61692
- input: { value, onChange },
61693
- hideValue,
61694
- className,
61695
- placeholder,
61696
- onFieldSubmit,
61697
- options,
61698
- hidePlaceHolder,
61699
- minimal,
61700
- disabled
61701
- } = _t, rest = __objRest(_t, [
61702
- "input",
61703
- "hideValue",
61704
- "className",
61705
- "placeholder",
61706
- "onFieldSubmit",
61707
- "options",
61708
- "hidePlaceHolder",
61709
- "minimal",
61710
- "disabled"
61711
- ]);
61712
- return /* @__PURE__ */ React$2.createElement(
61713
- "div",
61714
- {
61715
- className: `${minimal && MINIMAL} ` + classNames$1(SELECT$1, FILL, className)
61716
- },
61717
- /* @__PURE__ */ React$2.createElement(
61718
- "select",
61719
- __spreadProps(__spreadValues(__spreadProps(__spreadValues({}, removeUnwantedProps(rest)), {
61720
- className: `${disabled && DISABLED} `,
61721
- value: placeholder && value === "" ? "__placeholder__" : typeof value !== "string" ? sortify(value) : value,
61722
- disabled
61723
- }), hideValue ? { value: "" } : {}), {
61724
- onChange: function(e2) {
61725
- let val2 = e2.target.value;
61726
- try {
61727
- const maybeNewValue = JSON.parse(e2.target.value);
61728
- const hasMatchInOriginalOptions = options.find(
61729
- (opt) => opt === maybeNewValue || opt.value === maybeNewValue
61730
- );
61731
- if (hasMatchInOriginalOptions || isPlainObject$4(maybeNewValue)) {
61732
- val2 = maybeNewValue;
61733
- }
61734
- } catch (e22) {
61735
- }
61736
- onChange(val2);
61737
- onFieldSubmit && onFieldSubmit(val2);
61738
- }
61739
- }),
61740
- placeholder && /* @__PURE__ */ React$2.createElement("option", { value: "__placeholder__", disabled: true, hidden: hidePlaceHolder }, placeholder),
61741
- options.map(function(opt, index2) {
61742
- let label, value2;
61743
- if (typeof opt === "string") {
61744
- label = opt;
61745
- value2 = opt;
61746
- } else if (isNumber$6(opt)) {
61747
- label = opt.toString();
61748
- value2 = opt;
61749
- } else if (Array.isArray(opt)) {
61750
- throw new Error(
61751
- "the option coming in should be an object, not an array!"
61752
- );
61753
- } else {
61754
- label = opt.label;
61755
- value2 = opt.value;
61756
- }
61757
- return /* @__PURE__ */ React$2.createElement(
61758
- "option",
61759
- {
61760
- key: index2,
61761
- value: typeof value2 !== "string" ? sortify(value2) : value2
61762
- },
61763
- label
61764
- );
61765
- })
61766
- )
61767
- );
61768
- }, "renderSelect");
61769
- const renderBlueprintNumericInput = /* @__PURE__ */ __name((_u) => {
61770
- var _v = _u, {
61656
+ const renderBlueprintNumericInput = /* @__PURE__ */ __name((_q) => {
61657
+ var _r = _q, {
61771
61658
  input,
61772
61659
  hideValue,
61773
61660
  intent,
61774
61661
  inputClassName,
61775
61662
  onFieldSubmit,
61776
61663
  onAnyNumberChange
61777
- } = _v, rest = __objRest(_v, [
61664
+ } = _r, rest = __objRest(_r, [
61778
61665
  "input",
61779
61666
  "hideValue",
61780
61667
  "intent",
@@ -61819,12 +61706,12 @@ ${latestSubscriptionCallbackError.current.stack}
61819
61706
  })
61820
61707
  );
61821
61708
  }, "renderBlueprintNumericInput");
61822
- const renderBlueprintRadioGroup = /* @__PURE__ */ __name((_w) => {
61823
- var _x = _w, {
61709
+ const renderBlueprintRadioGroup = /* @__PURE__ */ __name((_s) => {
61710
+ var _t = _s, {
61824
61711
  input,
61825
61712
  options,
61826
61713
  onFieldSubmit
61827
- } = _x, rest = __objRest(_x, [
61714
+ } = _t, rest = __objRest(_t, [
61828
61715
  "input",
61829
61716
  "options",
61830
61717
  "onFieldSubmit"
@@ -82697,8 +82584,8 @@ ${latestSubscriptionCallbackError.current.stack}
82697
82584
  normal: () => 33.34,
82698
82585
  comfortable: () => 41.34
82699
82586
  };
82700
- const DataTable = /* @__PURE__ */ __name((_y) => {
82701
- var _z = _y, {
82587
+ const DataTable = /* @__PURE__ */ __name((_u) => {
82588
+ var _v = _u, {
82702
82589
  controlled_pageSize,
82703
82590
  formName = "tgDataTable",
82704
82591
  history,
@@ -82712,7 +82599,7 @@ ${latestSubscriptionCallbackError.current.stack}
82712
82599
  tableParams: _tableParams,
82713
82600
  anyTouched,
82714
82601
  blur: blur2
82715
- } = _z, ownProps = __objRest(_z, [
82602
+ } = _v, ownProps = __objRest(_v, [
82716
82603
  "controlled_pageSize",
82717
82604
  "formName",
82718
82605
  "history",
@@ -98687,14 +98574,22 @@ ${latestSubscriptionCallbackError.current.stack}
98687
98574
  ), isOpen2 && /* @__PURE__ */ React$2.createElement("div", { style: { marginTop: 10 } }, content2 || children));
98688
98575
  }
98689
98576
  __name(AdvancedOptions, "AdvancedOptions");
98690
- function DropdownButton(_A) {
98691
- var _B = _A, {
98577
+ const TgHTMLSelect = /* @__PURE__ */ __name((_w) => {
98578
+ var _x = _w, { disabled } = _x, rest = __objRest(_x, ["disabled"]);
98579
+ if (disabled) {
98580
+ const opt = rest.options.find((o2) => o2.value === rest.value);
98581
+ return /* @__PURE__ */ React$2.createElement("div", __spreadProps(__spreadValues({}, rest), { className: classNames$1("bp3-html-select", rest.className) }), opt.label);
98582
+ }
98583
+ return /* @__PURE__ */ React$2.createElement(HTMLSelect, __spreadValues({}, rest));
98584
+ }, "TgHTMLSelect");
98585
+ function DropdownButton(_y) {
98586
+ var _z = _y, {
98692
98587
  disabled,
98693
98588
  menu,
98694
98589
  noRightIcon,
98695
98590
  popoverProps,
98696
98591
  className
98697
- } = _B, rest = __objRest(_B, [
98592
+ } = _z, rest = __objRest(_z, [
98698
98593
  "disabled",
98699
98594
  "menu",
98700
98595
  "noRightIcon",
@@ -102066,14 +101961,14 @@ ${latestSubscriptionCallbackError.current.stack}
102066
101961
  }
102067
101962
  }),
102068
101963
  branch(({ navTo }) => navTo, withRouter)
102069
- )(function(_C) {
102070
- var _D = _C, {
101964
+ )(function(_A) {
101965
+ var _B = _A, {
102071
101966
  navTo,
102072
101967
  context,
102073
101968
  staticContext,
102074
101969
  didMount,
102075
101970
  willUnmount
102076
- } = _D, props = __objRest(_D, [
101971
+ } = _B, props = __objRest(_B, [
102077
101972
  "navTo",
102078
101973
  "context",
102079
101974
  "staticContext",
@@ -102348,7 +102243,7 @@ ${latestSubscriptionCallbackError.current.stack}
102348
102243
  down: "↓"
102349
102244
  };
102350
102245
  symbols.mod = symbols[isMac ? "meta" : "ctrl"];
102351
- let MenuBar$1 = (_E = class extends React$2.Component {
102246
+ let MenuBar$1 = (_C = class extends React$2.Component {
102352
102247
  constructor(props) {
102353
102248
  super(props);
102354
102249
  __publicField(this, "state", {
@@ -102593,10 +102488,10 @@ ${latestSubscriptionCallbackError.current.stack}
102593
102488
  );
102594
102489
  }), extraContent);
102595
102490
  }
102596
- }, __name(_E, "MenuBar"), __publicField(_E, "defaultProps", {
102491
+ }, __name(_C, "MenuBar"), __publicField(_C, "defaultProps", {
102597
102492
  className: "",
102598
102493
  style: {}
102599
- }), _E);
102494
+ }), _C);
102600
102495
  const isDivider = /* @__PURE__ */ __name((item) => item.divider !== void 0, "isDivider");
102601
102496
  function getAllMenuTextsAndHandlers(menu, enhancers, context, path2 = []) {
102602
102497
  if (!menu)
@@ -102744,7 +102639,7 @@ ${latestSubscriptionCallbackError.current.stack}
102744
102639
  );
102745
102640
  }
102746
102641
  __name(HotkeysDialog, "HotkeysDialog");
102747
- let FillWindow$1 = (_F = class extends React$2.Component {
102642
+ let FillWindow$1 = (_D = class extends React$2.Component {
102748
102643
  constructor(props) {
102749
102644
  super(props);
102750
102645
  rerenderOnWindowResize(this);
@@ -102792,7 +102687,7 @@ ${latestSubscriptionCallbackError.current.stack}
102792
102687
  return reactDomExports.createPortal(inner2, window.document.body);
102793
102688
  return inner2;
102794
102689
  }
102795
- }, __name(_F, "FillWindow"), _F);
102690
+ }, __name(_D, "FillWindow"), _D);
102796
102691
  var relativeTime$1 = { exports: {} };
102797
102692
  (function(module2, exports3) {
102798
102693
  !function(r2, e2) {
@@ -121777,7 +121672,7 @@ ${latestSubscriptionCallbackError.current.stack}
121777
121672
  const xmlNode = xmlNode$1;
121778
121673
  const readDocType = DocTypeReader;
121779
121674
  const toNumber = strnum;
121780
- let OrderedObjParser$1 = (_G = class {
121675
+ let OrderedObjParser$1 = (_E = class {
121781
121676
  constructor(options) {
121782
121677
  this.options = options;
121783
121678
  this.currentNode = null;
@@ -121816,7 +121711,7 @@ ${latestSubscriptionCallbackError.current.stack}
121816
121711
  this.saveTextToParentTag = saveTextToParentTag;
121817
121712
  this.addChild = addChild;
121818
121713
  }
121819
- }, __name(_G, "OrderedObjParser"), _G);
121714
+ }, __name(_E, "OrderedObjParser"), _E);
121820
121715
  function addExternalEntities(externalEntities) {
121821
121716
  const entKeys = Object.keys(externalEntities);
121822
121717
  for (let i2 = 0; i2 < entKeys.length; i2++) {
@@ -122372,7 +122267,7 @@ ${latestSubscriptionCallbackError.current.stack}
122372
122267
  const OrderedObjParser = OrderedObjParser_1;
122373
122268
  const { prettify } = node2json;
122374
122269
  const validator$1 = validator$2;
122375
- let XMLParser$1 = (_H = class {
122270
+ let XMLParser$1 = (_F = class {
122376
122271
  constructor(options) {
122377
122272
  this.externalEntities = {};
122378
122273
  this.options = buildOptions(options);
@@ -122422,7 +122317,7 @@ ${latestSubscriptionCallbackError.current.stack}
122422
122317
  this.externalEntities[key2] = value;
122423
122318
  }
122424
122319
  }
122425
- }, __name(_H, "XMLParser"), _H);
122320
+ }, __name(_F, "XMLParser"), _F);
122426
122321
  var XMLParser_1 = XMLParser$1;
122427
122322
  const EOL = "\n";
122428
122323
  function toXml(jArray, options) {
@@ -130239,7 +130134,7 @@ ${seq.sequence}
130239
130134
  };
130240
130135
  __name(_FASTAParser, "FASTAParser");
130241
130136
  let FASTAParser = _FASTAParser;
130242
- let Parser$1 = (_I = class {
130137
+ let Parser$1 = (_G = class {
130243
130138
  constructor(args) {
130244
130139
  this.fastaParser = void 0;
130245
130140
  this.eof = false;
@@ -130463,7 +130358,7 @@ ${seq.sequence}
130463
130358
  }
130464
130359
  });
130465
130360
  }
130466
- }, __name(_I, "Parser"), _I);
130361
+ }, __name(_G, "Parser"), _G);
130467
130362
  function _callback(callback2) {
130468
130363
  if (process && process.nextTick)
130469
130364
  process.nextTick(callback2);
@@ -148993,7 +148888,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
148993
148888
  "editorName"
148994
148889
  ])(Labels$1);
148995
148890
  const DrawLabel = withHover(
148996
- (_J = class extends React$2.Component {
148891
+ (_H = class extends React$2.Component {
148997
148892
  render() {
148998
148893
  const {
148999
148894
  hovered,
@@ -149097,7 +148992,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
149097
148992
  }
149098
148993
  ));
149099
148994
  }
149100
- }, __name(_J, "DrawLabelInner"), _J)
148995
+ }, __name(_H, "DrawLabelInner"), _H)
149101
148996
  );
149102
148997
  const labelClassNames = {
149103
148998
  cutsites: "veCutsiteLabel",
@@ -150973,7 +150868,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
150973
150868
  }
150974
150869
  __name(showFileDialog, "showFileDialog");
150975
150870
  const name = "@teselagen/ove";
150976
- const version = "0.7.13";
150871
+ const version = "0.7.15";
150977
150872
  const main = "./src/index.js";
150978
150873
  const type = "module";
150979
150874
  const exports$1 = {
@@ -151053,8 +150948,8 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
151053
150948
  cutsites: 100
151054
150949
  }
151055
150950
  }), "useAnnotationLimits");
151056
- function LimitAnnotations(_K) {
151057
- var _L = _K, { type: type2 } = _L, rest = __objRest(_L, ["type"]);
150951
+ function LimitAnnotations(_I) {
150952
+ var _J = _I, { type: type2 } = _J, rest = __objRest(_J, ["type"]);
151058
150953
  const [limits = {}, setLimits] = useAnnotationLimits();
151059
150954
  return /* @__PURE__ */ React$2.createElement(MenuItem, __spreadValues({ icon: "blank", shouldDismissPopover: false }, rest), [50, 100, 200, 400].map((n2) => /* @__PURE__ */ React$2.createElement(
151060
150955
  MenuItem,
@@ -157357,7 +157252,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
157357
157252
  __name(_Minimap, "Minimap");
157358
157253
  let Minimap = _Minimap;
157359
157254
  const YellowScrollHandle = view(
157360
- (_M = class extends React$2.Component {
157255
+ (_K = class extends React$2.Component {
157361
157256
  render() {
157362
157257
  const {
157363
157258
  scrollHandleWidth,
@@ -157512,7 +157407,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
157512
157407
  )
157513
157408
  );
157514
157409
  }
157515
- }, __name(_M, "YellowScrollHandleInner"), _M)
157410
+ }, __name(_K, "YellowScrollHandleInner"), _K)
157516
157411
  );
157517
157412
  function getTrimmedRangesToDisplay({ trimmedRange, seqLen }) {
157518
157413
  if (!trimmedRange)
@@ -157885,14 +157780,14 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
157885
157780
  }, rest);
157886
157781
  }
157887
157782
  __name(getRangeAnglesSpecial, "getRangeAnglesSpecial");
157888
- function PositionAnnotationOnCircle(_N) {
157889
- var _O = _N, {
157783
+ function PositionAnnotationOnCircle(_L) {
157784
+ var _M = _L, {
157890
157785
  children,
157891
157786
  height: height2 = 0,
157892
157787
  sAngle = 0,
157893
157788
  eAngle = 0,
157894
157789
  forward = true
157895
- } = _O, rest = __objRest(_O, [
157790
+ } = _M, rest = __objRest(_M, [
157896
157791
  "children",
157897
157792
  "height",
157898
157793
  "sAngle",
@@ -160197,13 +160092,14 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
160197
160092
  smallSlider,
160198
160093
  editorName
160199
160094
  }) {
160095
+ const mainSelector = editorName ? `.veEditor.${editorName}` : ".veEditor";
160200
160096
  const target = React$2.useRef();
160201
160097
  const svgEleRef = React$2.useRef();
160202
160098
  reactExports.useEffect(() => {
160203
160099
  var _a2;
160204
- const svgEle = (_a2 = document.querySelector(`.veEditor.${editorName}`)) == null ? void 0 : _a2.querySelector(".veCircularView .circularViewSvg");
160100
+ const svgEle = (_a2 = document.querySelector(mainSelector)) == null ? void 0 : _a2.querySelector(".veCircularView .circularViewSvg");
160205
160101
  svgEleRef.current = svgEle;
160206
- }, [editorName]);
160102
+ }, [editorName, mainSelector]);
160207
160103
  const showLabelsDebounced = c(
160208
160104
  (el2) => {
160209
160105
  try {
@@ -160240,9 +160136,11 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
160240
160136
  var _a2;
160241
160137
  const val2 = 360 - _val;
160242
160138
  if (!svgEleRef.current) {
160243
- svgEleRef.current = (_a2 = document.querySelector(`.veEditor.${editorName}`)) == null ? void 0 : _a2.querySelector(".veCircularView .circularViewSvg");
160139
+ svgEleRef.current = (_a2 = document.querySelector(mainSelector)) == null ? void 0 : _a2.querySelector(".veCircularView .circularViewSvg");
160244
160140
  }
160245
160141
  const el2 = svgEleRef.current;
160142
+ if (!el2)
160143
+ return;
160246
160144
  const innerEl = el2 == null ? void 0 : el2.querySelector("g");
160247
160145
  innerEl.style.transform = `rotate(${val2}deg)`;
160248
160146
  setRotationRadians(val2 * Math.PI / 180);
@@ -168101,7 +167999,8 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
168101
167999
  withFullscreen,
168102
168000
  selectionLayer: selectionLayer2,
168103
168001
  selectionLayerUpdate: selectionLayerUpdate2,
168104
- caretPositionUpdate: caretPositionUpdate2
168002
+ caretPositionUpdate: caretPositionUpdate2,
168003
+ editorName = "tg-simple-dna-view"
168105
168004
  } = props;
168106
168005
  const [previewType, setPreviewType] = reactExports.useState(
168107
168006
  _sequenceData.circular ? "circular" : "linear"
@@ -168234,7 +168133,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
168234
168133
  Component,
168235
168134
  __spreadValues({}, __spreadProps(__spreadValues(__spreadProps(__spreadValues(__spreadValues({
168236
168135
  showCicularViewInternalLabels: true,
168237
- className: "tg-simple-dna-view veEditor",
168136
+ className: `${editorName} veEditor tg-simple-dna-view`,
168238
168137
  width: 300,
168239
168138
  height: 300,
168240
168139
  noWarnings,
@@ -168473,7 +168372,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
168473
168372
  }),
168474
168373
  tgFormValues("from", "to")
168475
168374
  )(
168476
- (_P = class extends React$2.Component {
168375
+ (_N = class extends React$2.Component {
168477
168376
  constructor() {
168478
168377
  super(...arguments);
168479
168378
  __publicField(this, "updateTempHighlight", /* @__PURE__ */ __name(({ isStart, isEnd } = {}) => (val2) => {
@@ -168584,7 +168483,7 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
168584
168483
  ))
168585
168484
  );
168586
168485
  }
168587
- }, __name(_P, "SelectDialog"), _P)
168486
+ }, __name(_N, "SelectDialog"), _N)
168588
168487
  );
168589
168488
  const normalizeToInt = /* @__PURE__ */ __name((val2) => {
168590
168489
  const int2 = Math.round(val2);
@@ -172059,8 +171958,8 @@ Part of ${annotation.translationType} Translation from BPs ${annotation.start +
172059
171958
  return track;
172060
171959
  }
172061
171960
  __name(getTrackFromEvent, "getTrackFromEvent");
172062
- const PerformantSelectionLayer = view((_Q) => {
172063
- var _R = _Q, { easyStore: easyStore2 } = _R, rest = __objRest(_R, ["easyStore"]);
171961
+ const PerformantSelectionLayer = view((_O) => {
171962
+ var _P = _O, { easyStore: easyStore2 } = _P, rest = __objRest(_P, ["easyStore"]);
172064
171963
  const seqLen = rest.sequenceLength - 1;
172065
171964
  return /* @__PURE__ */ React$2.createElement(
172066
171965
  SelectionLayer$3,
@@ -173886,8 +173785,8 @@ ${seqDataToCopy}\r
173886
173785
  })
173887
173786
  )
173888
173787
  )(AlignmentView);
173889
- const PerformantCaret = view((_S) => {
173890
- var _T = _S, { easyStore: easyStore2 } = _T, rest = __objRest(_T, ["easyStore"]);
173788
+ const PerformantCaret = view((_Q) => {
173789
+ var _R = _Q, { easyStore: easyStore2 } = _R, rest = __objRest(_R, ["easyStore"]);
173891
173790
  return /* @__PURE__ */ React$2.createElement(Caret$2, __spreadValues({ caretPosition: easyStore2.caretPosition }, rest));
173892
173791
  });
173893
173792
  function cleanTracks(alignmentTracks) {
@@ -176150,14 +176049,14 @@ ${seqDataToCopy}\r
176150
176049
  }, toolbarItemProps))
176151
176050
  );
176152
176051
  });
176153
- function CutsiteToolDropDown(_U) {
176154
- var _V = _U, {
176052
+ function CutsiteToolDropDown(_S) {
176053
+ var _T = _S, {
176155
176054
  editorName,
176156
176055
  toggleDropdown,
176157
176056
  annotationVisibilityShow: annotationVisibilityShow2,
176158
176057
  withDigestTool,
176159
176058
  createNewDigest: createNewDigest2
176160
- } = _V, rest = __objRest(_V, [
176059
+ } = _T, rest = __objRest(_T, [
176161
176060
  "editorName",
176162
176061
  "toggleDropdown",
176163
176062
  "annotationVisibilityShow",
@@ -176285,7 +176184,7 @@ ${seqDataToCopy}\r
176285
176184
  );
176286
176185
  });
176287
176186
  const OrfToolDropdown = withEditorProps(
176288
- (_W = class extends React$2.Component {
176187
+ (_U = class extends React$2.Component {
176289
176188
  constructor(props) {
176290
176189
  super(props);
176291
176190
  this.commands = getCommands(this);
@@ -176311,7 +176210,7 @@ ${seqDataToCopy}\r
176311
176210
  }
176312
176211
  ));
176313
176212
  }
176314
- }, __name(_W, "OrfDropdown"), _W)
176213
+ }, __name(_U, "OrfDropdown"), _U)
176315
176214
  );
176316
176215
  const opts = [
176317
176216
  { label: "DNA", value: "DNA" },
@@ -176371,7 +176270,7 @@ ${seqDataToCopy}\r
176371
176270
  }, "updateMatchNumber");
176372
176271
  const findOptionsEls = [
176373
176272
  /* @__PURE__ */ React$2.createElement(
176374
- HTMLSelect,
176273
+ TgHTMLSelect,
176375
176274
  {
176376
176275
  key: "dnaoraa",
176377
176276
  options: opts,
@@ -176383,7 +176282,7 @@ ${seqDataToCopy}\r
176383
176282
  }
176384
176283
  ),
176385
176284
  /* @__PURE__ */ React$2.createElement("div", { style: { display: "flex" }, key: "ambiguousorliteral" }, /* @__PURE__ */ React$2.createElement(
176386
- HTMLSelect,
176285
+ TgHTMLSelect,
176387
176286
  {
176388
176287
  name: "ambiguousOrLiteral",
176389
176288
  options: [
@@ -176926,10 +176825,11 @@ ${seqDataToCopy}\r
176926
176825
  disableSetReadOnly,
176927
176826
  disableBpEditing
176928
176827
  } = props;
176828
+ const disabled = disableSetReadOnly || !onSave;
176929
176829
  return showReadOnly ? /* @__PURE__ */ React$2.createElement(StatusBarItem, { dataTest: "veStatusBar-readOnly" }, onSave ? /* @__PURE__ */ React$2.createElement(
176930
- HTMLSelect,
176830
+ TgHTMLSelect,
176931
176831
  {
176932
- "data-tip": !readOnly2 && disableBpEditing ? disableBpEditing : void 0,
176832
+ "data-tip": !readOnly2 && typeof disableBpEditing === "string" ? disableBpEditing : void 0,
176933
176833
  options: [
176934
176834
  {
176935
176835
  label: "Read Only",
@@ -176940,8 +176840,8 @@ ${seqDataToCopy}\r
176940
176840
  value: "editable"
176941
176841
  }
176942
176842
  ],
176943
- disabled: disableSetReadOnly || !onSave,
176944
- className: MINIMAL,
176843
+ disabled,
176844
+ className: MINIMAL + " veReadOnlySelect",
176945
176845
  value: readOnly2 ? "readOnly" : "editable",
176946
176846
  onChange: ({ target: { value } }) => handleReadOnlyChange(value === "readOnly", props)
176947
176847
  }
@@ -177045,7 +176945,7 @@ ${seqDataToCopy}\r
177045
176945
  withHandlers({ updateCircular })
177046
176946
  )(({ readOnly: readOnly2, showCircularity, circular: circular2, updateCircular: updateCircular2 }) => {
177047
176947
  return showCircularity ? /* @__PURE__ */ React$2.createElement(StatusBarItem, { dataTest: "veStatusBar-circularity" }, readOnly2 ? circular2 ? "Circular" : "Linear" : /* @__PURE__ */ React$2.createElement(
177048
- HTMLSelect,
176948
+ TgHTMLSelect,
177049
176949
  {
177050
176950
  onChange: ({ target: { value } }) => {
177051
176951
  updateCircular2(value === "circular");
@@ -177066,7 +176966,7 @@ ${seqDataToCopy}\r
177066
176966
  })
177067
176967
  )(({ readOnly: readOnly2, showAvailability, materiallyAvailable: materiallyAvailable2, updateAvailability: updateAvailability2 }) => {
177068
176968
  return showAvailability ? /* @__PURE__ */ React$2.createElement(StatusBarItem, null, readOnly2 ? materiallyAvailable2 ? "Available" : "Unavailable" : /* @__PURE__ */ React$2.createElement(
177069
- HTMLSelect,
176969
+ TgHTMLSelect,
177070
176970
  {
177071
176971
  onChange: ({ target: { value } }) => {
177072
176972
  updateAvailability2(value === "available");
@@ -177536,13 +177436,14 @@ ${seqDataToCopy}\r
177536
177436
  const {
177537
177437
  readOnly: readOnly2,
177538
177438
  showReadOnly = true,
177539
- updateCircular: updateCircular2,
177540
177439
  isProtein: isProtein2,
177541
177440
  disableSetReadOnly,
177542
- updateAvailability: updateAvailability2,
177543
177441
  sequenceData: sequenceData2,
177544
177442
  onSave,
177545
177443
  showAvailability,
177444
+ beforeReadOnlyChange,
177445
+ editorName,
177446
+ disableBpEditing,
177546
177447
  sequenceNameUpdate: sequenceNameUpdate2
177547
177448
  } = this.props;
177548
177449
  const {
@@ -177551,9 +177452,7 @@ ${seqDataToCopy}\r
177551
177452
  isOligo: isOligo2,
177552
177453
  isRna: isRna2,
177553
177454
  sequence: sequence2 = "",
177554
- proteinSequence = "",
177555
- circular: circular2,
177556
- materiallyAvailable: materiallyAvailable2
177455
+ proteinSequence = ""
177557
177456
  } = sequenceData2 || {};
177558
177457
  return /* @__PURE__ */ React$2.createElement(React$2.Fragment, null, /* @__PURE__ */ React$2.createElement("div", { className: "ve-flex-row" }, /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-left bp3-label" }, "Name"), " ", /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-right" }, /* @__PURE__ */ React$2.createElement(
177559
177458
  InputField,
@@ -177566,43 +177465,15 @@ ${seqDataToCopy}\r
177566
177465
  enableReinitialize: true,
177567
177466
  defaultValue: name2
177568
177467
  }
177569
- ), " ")), !isProtein2 && !isOligo2 && !isRna2 && /* @__PURE__ */ React$2.createElement("div", { className: "ve-flex-row circularLinearSelect" }, /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-left bp3-label" }, "Circular/Linear"), " ", /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-right" }, " ", /* @__PURE__ */ React$2.createElement(
177570
- BPSelect,
177571
- {
177572
- disabled: readOnly2,
177573
- onChange: (val2) => {
177574
- updateCircular2(val2 === "circular");
177575
- },
177576
- value: circular2 ? "circular" : "linear",
177577
- options: [
177578
- { label: "Circular", value: "circular" },
177579
- { label: "Linear", value: "linear" }
177580
- ]
177581
- }
177582
- ))), showAvailability && /* @__PURE__ */ React$2.createElement("div", { className: "ve-flex-row" }, /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-left bp3-label" }, "Material Availability"), " ", /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-right" }, " ", /* @__PURE__ */ React$2.createElement(
177583
- BPSelect,
177468
+ ), " ")), !isProtein2 && !isOligo2 && !isRna2 && /* @__PURE__ */ React$2.createElement("div", { className: "ve-flex-row circularLinearSelect" }, /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-left bp3-label" }, "Circular/Linear"), " ", /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-right" }, " ", /* @__PURE__ */ React$2.createElement(EditCircularityItem, { editorName, showCircularity: true }))), showAvailability && /* @__PURE__ */ React$2.createElement("div", { className: "ve-flex-row" }, /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-left bp3-label" }, "Material Availability"), " ", /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-right" }, " ", /* @__PURE__ */ React$2.createElement(EditAvailabilityItem, { editorName, showAvailability: true }))), /* @__PURE__ */ React$2.createElement("div", { className: "ve-flex-row" }, /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-left bp3-label" }, "Length"), " ", /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-right" }, " ", isProtein2 ? proteinSequence.length : sequence2.length)), showReadOnly && /* @__PURE__ */ React$2.createElement("div", { className: "ve-flex-row" }, /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-left bp3-label" }, "Is Editable"), " ", /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-right" }, " ", /* @__PURE__ */ React$2.createElement(
177469
+ EditReadOnlyItem,
177584
177470
  {
177585
- disabled: readOnly2,
177586
- onChange: (val2) => {
177587
- updateAvailability2(val2 === "available");
177588
- },
177589
- value: materiallyAvailable2 ? "available" : "unavailable",
177590
- options: [
177591
- { label: "Available", value: "available" },
177592
- { label: "Unavailable", value: "unavailable" }
177593
- ]
177594
- }
177595
- ))), /* @__PURE__ */ React$2.createElement("div", { className: "ve-flex-row" }, /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-left bp3-label" }, "Length"), " ", /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-right" }, " ", isProtein2 ? proteinSequence.length : sequence2.length)), showReadOnly && /* @__PURE__ */ React$2.createElement("div", { className: "ve-flex-row" }, /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-left bp3-label" }, "Is Editable"), " ", /* @__PURE__ */ React$2.createElement("div", { className: "ve-column-right" }, " ", /* @__PURE__ */ React$2.createElement(
177596
- BPSelect,
177597
- {
177598
- className: "veReadOnlySelect",
177599
- disabled: !onSave || disableSetReadOnly,
177600
- onChange: (val2) => handleReadOnlyChange(val2 === "readOnly", this.props),
177601
- value: readOnly2 ? "readOnly" : "editable",
177602
- options: [
177603
- { label: "Read Only", value: "readOnly" },
177604
- { label: "Editable", value: "editable" }
177605
- ]
177471
+ beforeReadOnlyChange,
177472
+ editorName,
177473
+ onSave,
177474
+ disableBpEditing,
177475
+ disableSetReadOnly,
177476
+ showReadOnly
177606
177477
  }
177607
177478
  ))), /* @__PURE__ */ React$2.createElement("div", null, "Description"), /* @__PURE__ */ React$2.createElement(
177608
177479
  TextareaField,
@@ -181728,8 +181599,8 @@ ${seqDataToCopy}\r
181728
181599
  return /* @__PURE__ */ React$2.createElement(Provider, { store }, /* @__PURE__ */ React$2.createElement(VersionHistoryView$1, __spreadValues({}, __spreadValues({}, props))));
181729
181600
  }
181730
181601
  __name(StandaloneVersionHistoryView, "StandaloneVersionHistoryView");
181731
- function createVectorEditor(_node, _X = {}) {
181732
- var _Y = _X, { editorName = "StandaloneEditor" } = _Y, rest = __objRest(_Y, ["editorName"]);
181602
+ function createVectorEditor(_node, _V = {}) {
181603
+ var _W = _V, { editorName = "StandaloneEditor" } = _W, rest = __objRest(_W, ["editorName"]);
181733
181604
  if (!store) {
181734
181605
  store = makeStore();
181735
181606
  }
@@ -181762,8 +181633,8 @@ ${seqDataToCopy}\r
181762
181633
  return editor;
181763
181634
  }
181764
181635
  __name(createVectorEditor, "createVectorEditor");
181765
- function createVersionHistoryView(node2, _Z = {}) {
181766
- var __ = _Z, { editorName = "StandaloneVersionHistoryView" } = __, rest = __objRest(__, ["editorName"]);
181636
+ function createVersionHistoryView(node2, _X = {}) {
181637
+ var _Y = _X, { editorName = "StandaloneVersionHistoryView" } = _Y, rest = __objRest(_Y, ["editorName"]);
181767
181638
  if (!store) {
181768
181639
  store = makeStore();
181769
181640
  }