@teselagen/ove 0.7.36 → 0.8.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/ove.css CHANGED
@@ -9356,6 +9356,43 @@ button:not(:disabled):active {
9356
9356
  margin-left: 16px;
9357
9357
  }
9358
9358
  }
9359
+ .tg-blueprint-divider {
9360
+ position: relative;
9361
+ }
9362
+
9363
+ /* Override Blueprint's default divider when we use text */
9364
+ .tg-blueprint-divider-with-text.bp3-divider {
9365
+ /* Remove Blueprint's default border styling to avoid duplication */
9366
+ border: none;
9367
+ display: flex;
9368
+ align-items: center;
9369
+ margin: 16px 0;
9370
+ height: auto;
9371
+ }
9372
+
9373
+ .tg-blueprint-divider-with-text::before,
9374
+ .tg-blueprint-divider-with-text::after {
9375
+ content: "";
9376
+ flex: 1;
9377
+ border-bottom: 1px solid rgba(16, 22, 26, 0.15);
9378
+ }
9379
+
9380
+ .tg-blueprint-divider-text {
9381
+ padding: 0 10px;
9382
+ font-size: 14px;
9383
+ color: rgba(92, 112, 128, 0.6);
9384
+ white-space: nowrap;
9385
+ }
9386
+
9387
+ /* Dark theme support */
9388
+ .bp3-dark .tg-blueprint-divider-with-text::before,
9389
+ .bp3-dark .tg-blueprint-divider-with-text::after {
9390
+ border-bottom-color: rgba(255, 255, 255, 0.15);
9391
+ }
9392
+
9393
+ .bp3-dark .tg-blueprint-divider-text {
9394
+ color: rgba(167, 182, 194, 0.6);
9395
+ }
9359
9396
  .rg-celleditor-input,
9360
9397
  .rg-celleditor input {
9361
9398
  border: none;
@@ -9423,6 +9460,7 @@ button:not(:disabled):active {
9423
9460
  }
9424
9461
  .bp3-popover.tg-info-helper-popover .bp3-popover-content {
9425
9462
  max-width: 340px;
9463
+ white-space: pre-line;
9426
9464
  }
9427
9465
 
9428
9466
  .info-helper-clickable .bp3-popover-target {
@@ -11520,22 +11558,30 @@ path.partWithSelectedTag {
11520
11558
  overflow: auto;
11521
11559
  max-height: 50vh;
11522
11560
  }
11523
- /* .veFindBar {
11524
- z-index: 20000;
11561
+ .veFindBar {
11562
+ background: #ffffff;
11525
11563
  border-bottom: 1px solid lightgrey;
11526
11564
  border-left: 1px solid lightgrey;
11527
11565
  border-right: 1px solid lightgrey;
11528
11566
  border-bottom-left-radius: 5px;
11529
11567
  border-bottom-right-radius: 5px;
11530
- } */
11568
+ }
11569
+
11531
11570
  .veFindBar > .bp3-control {
11532
11571
  margin-bottom: 0px;
11533
11572
  }
11534
11573
  .veFindBar > * {
11535
- margin-right: 10px;
11536
11574
  width: fit-content;
11537
11575
  }
11538
11576
 
11577
+ .bp3-dark .veFindBar {
11578
+ border-radius: 5px;
11579
+ background: #30404d !important;
11580
+ border-bottom: 1px solid #202b33 !important;
11581
+ border-left: 1px solid #202b33 !important;
11582
+ border-right: 1px solid #202b33 !important;
11583
+ }
11584
+
11539
11585
  .ve-find-options-popover > * {
11540
11586
  margin: 10px 5px;
11541
11587
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@teselagen/ove",
3
- "version": "0.7.36",
3
+ "version": "0.8.2",
4
4
  "main": "./src/index.js",
5
5
  "type": "module",
6
6
  "exports": {
@@ -19,7 +19,7 @@
19
19
  "@teselagen/range-utils": "0.3.13",
20
20
  "@teselagen/react-list": "0.8.18",
21
21
  "@teselagen/sequence-utils": "0.3.32",
22
- "@teselagen/ui": "0.9.6",
22
+ "@teselagen/ui": "0.10.3",
23
23
  "@use-gesture/react": "10.3.0",
24
24
  "biomsa": "^0.2.4",
25
25
  "classnames": "^2.3.2",
@@ -9,8 +9,7 @@ import {
9
9
  } from "@blueprintjs/core";
10
10
  import React from "react";
11
11
  import { map, startCase } from "lodash-es";
12
- import pureNoFunc from "../utils/pureNoFunc";
13
- // import { fullSequenceTranslationMenu } from "../MenuBar/viewSubmenu";
12
+ import { pureNoFunc } from "@teselagen/ui";
14
13
 
15
14
  export default pureNoFunc(function AlignmentVisibilityTool(props) {
16
15
  return (
@@ -3,7 +3,7 @@ import { getRangeAngles } from "@teselagen/range-utils";
3
3
  import PositionAnnotationOnCircle from "./PositionAnnotationOnCircle";
4
4
  import React from "react";
5
5
  import draggableClassnames from "../constants/draggableClassnames";
6
- import pureNoFunc from "../utils/pureNoFunc";
6
+ import { pureNoFunc } from "@teselagen/ui";
7
7
  import { getSelectionMessage } from "../utils/editorUtils";
8
8
 
9
9
  function Caret({
@@ -4,7 +4,7 @@ import PositionAnnotationOnCircle from "./PositionAnnotationOnCircle";
4
4
  import React from "react";
5
5
  import each from "lodash/each";
6
6
  import withHover from "../helperComponents/withHover";
7
- import pureNoFunc from "../utils/pureNoFunc";
7
+ import { pureNoFunc } from "@teselagen/ui";
8
8
 
9
9
  function Cutsites({
10
10
  radius,
@@ -5,7 +5,7 @@ import getRangeAngles from "./getRangeAnglesSpecial";
5
5
  import PositionAnnotationOnCircle from "./PositionAnnotationOnCircle";
6
6
  import React from "react";
7
7
  import draggableClassnames from "../constants/draggableClassnames";
8
- import pureNoFunc from "../utils/pureNoFunc";
8
+ import { pureNoFunc } from "@teselagen/ui";
9
9
  import {
10
10
  getSelectionMessage,
11
11
  preventDefaultStopPropagation
@@ -270,19 +270,13 @@ export class FindBar extends React.Component {
270
270
  }
271
271
  : {
272
272
  position: "fixed",
273
- top: 0,
273
+ top: 120,
274
274
  right: 25,
275
275
  padding: 10,
276
276
  display: "flex",
277
- alignItems: "center",
277
+ alignItems: "start",
278
278
  paddingBottom: 5,
279
- background: "white",
280
- zIndex: "20000",
281
- borderBottom: "1px solid lightgrey",
282
- borderLeft: "1px solid lightgrey",
283
- borderRight: "1px solid lightgrey",
284
- borderBottomLeftRadius: "5px",
285
- borderBottomRightRadius: "5px"
279
+ zIndex: 20000
286
280
  }
287
281
  }
288
282
  className="veFindBar"
@@ -295,7 +289,10 @@ export class FindBar extends React.Component {
295
289
  autoFocus
296
290
  style={{
297
291
  resize: "vertical",
298
- ...(!isInline && { width: 350, minHeight: 70 })
292
+ ...(!isInline && {
293
+ width: 350,
294
+ height: 190
295
+ })
299
296
  }}
300
297
  className="tg-find-tool-input"
301
298
  inputRef={n => {
@@ -347,12 +344,10 @@ export class FindBar extends React.Component {
347
344
  {!isInline && (
348
345
  <div
349
346
  style={{
347
+ marginLeft: 10,
350
348
  display: "flex",
351
- maxWidth: "400px",
352
- flexWrap: "wrap",
353
- justifyContent: "space-around",
354
- alignItems: "stretch",
355
- height: "76px"
349
+ flexDirection: "column",
350
+ gap: 5
356
351
  }}
357
352
  >
358
353
  {rightEl}
@@ -362,7 +357,7 @@ export class FindBar extends React.Component {
362
357
  {!isInline && (
363
358
  <Button
364
359
  minimal
365
- style={{ position: "absolute", bottom: 0, right: -10 }}
360
+ style={{ position: "absolute", bottom: 0, right: 0 }}
366
361
  onClick={toggleFindTool}
367
362
  icon="cross"
368
363
  />
@@ -1,19 +1,27 @@
1
- /* .veFindBar {
2
- z-index: 20000;
1
+ .veFindBar {
2
+ background: #ffffff;
3
3
  border-bottom: 1px solid lightgrey;
4
4
  border-left: 1px solid lightgrey;
5
5
  border-right: 1px solid lightgrey;
6
6
  border-bottom-left-radius: 5px;
7
7
  border-bottom-right-radius: 5px;
8
- } */
8
+ }
9
+
9
10
  .veFindBar > .bp3-control {
10
11
  margin-bottom: 0px;
11
12
  }
12
13
  .veFindBar > * {
13
- margin-right: 10px;
14
14
  width: fit-content;
15
15
  }
16
16
 
17
+ .bp3-dark .veFindBar {
18
+ border-radius: 5px;
19
+ background: #30404d !important;
20
+ border-bottom: 1px solid #202b33 !important;
21
+ border-left: 1px solid #202b33 !important;
22
+ border-right: 1px solid #202b33 !important;
23
+ }
24
+
17
25
  .ve-find-options-popover > * {
18
26
  margin: 10px 5px;
19
27
  }
@@ -148,4 +148,3 @@ const Axis = function (props) {
148
148
 
149
149
  // export default Axis
150
150
  export default view(Axis);
151
- // export default pureNoFunc(Axis);
@@ -1,6 +1,5 @@
1
1
  import React from "react";
2
2
  import classnames from "classnames";
3
- // import pure from "../../utils/pureNoFunc";
4
3
  import "./style.css";
5
4
  import { getSelectionMessage } from "../../utils/editorUtils";
6
5
  // import draggableClassnames from "../../constants/draggableClassnames";
@@ -4,7 +4,7 @@ import React from "react";
4
4
  import areNonNegativeIntegers from "validate.io-nonnegative-integer-array";
5
5
  import { getOverlapsOfPotentiallyCircularRanges } from "@teselagen/range-utils";
6
6
  import getXStartAndWidthOfRangeWrtRow from "./getXStartAndWidthOfRangeWrtRow";
7
- import pureNoFunc from "../utils/pureNoFunc";
7
+ import { pureNoFunc } from "@teselagen/ui";
8
8
  import { connectToEditor } from "../withEditorProps";
9
9
 
10
10
  let snipStyle = {
@@ -1,8 +1,7 @@
1
1
  import AnnotationPositioner from "../AnnotationPositioner";
2
2
  import AnnotationContainerHolder from "../AnnotationContainerHolder";
3
3
  import React from "react";
4
- import pureNoFunc from "../../utils/pureNoFunc";
5
-
4
+ import { pureNoFunc } from "@teselagen/ui";
6
5
  import "./style.css";
7
6
 
8
7
  import getXStartAndWidthOfRangeWrtRow from "../getXStartAndWidthOfRangeWrtRow";
@@ -2,8 +2,7 @@
2
2
  import draggableClassnames from "../../constants/draggableClassnames";
3
3
  import React from "react";
4
4
  import Caret from "../Caret";
5
- import pureNoFunc from "../../utils/pureNoFunc";
6
-
5
+ import { pureNoFunc } from "@teselagen/ui";
7
6
  import "./style.css";
8
7
 
9
8
  import getXStartAndWidthOfRangeWrtRow from "../getXStartAndWidthOfRangeWrtRow";
@@ -1,6 +1,6 @@
1
1
  // import PropTypes from "prop-types";
2
2
  import React from "react";
3
- import pureNoFunc from "../../utils/pureNoFunc";
3
+ import { pureNoFunc } from "@teselagen/ui";
4
4
 
5
5
  function AASliver(props) {
6
6
  const {
@@ -4,7 +4,7 @@ import {
4
4
  zeroSubrangeByContainerRange
5
5
  } from "@teselagen/range-utils";
6
6
  import AASliver from "./AASliver";
7
- import pureNoFunc from "../../utils/pureNoFunc";
7
+ import { pureNoFunc } from "@teselagen/ui";
8
8
  import { proteinAlphabet } from "@teselagen/sequence-utils";
9
9
 
10
10
  class Translation extends React.Component {
@@ -3,5 +3,6 @@ import { useSelector } from "react-redux";
3
3
  import { get } from "lodash";
4
4
 
5
5
  export const useFormValue = (formName, field) => {
6
- return useSelector(state => get(state.form?.[formName]?.values, field));
6
+ const formValSelector = state => get(state.form?.[formName]?.values, field);
7
+ return useSelector(formValSelector);
7
8
  };