@@ -114,18 +109,16 @@ export default class CollectionTree extends React.Component {
let { remoteRoots, sharedWithCollectionVisible } = this.state
remoteRoots = this.removeOrphanRoots(remoteRoots)
- let labelledRoots = remoteRoots.map(e => {
- return update(e, {
- label: {
- $set:
-
- }
- })
- })
+ let labelledRoots = remoteRoots.map(e => ({
+ ...e,
+ label: (
+
@@ -149,18 +142,16 @@ export default class CollectionTree extends React.Component {
let { syncInRoots, syncCollectionVisible } = this.state
syncInRoots = this.removeOrphanRoots(syncInRoots)
- let labelledRoots = syncInRoots.map(e => {
- return update(e, {
- label: {
- $set:
-
- {this.labelRoot('shared_by', e)}
- {' '}
- {this.labelRoot('shared_to', e)}
-
- }
- })
- })
+ let labelledRoots = syncInRoots.map(e => ({
+ ...e,
+ label: (
+
+ {this.labelRoot('shared_by', e)}
+ {' '}
+ {this.labelRoot('shared_to', e)}
+
+ )
+ }));
let subTreeLabels = (
diff --git a/app/packs/src/apps/mydb/elements/Elements.js b/app/packs/src/apps/mydb/elements/Elements.js
index aca4f64c4b..9f9550d53d 100644
--- a/app/packs/src/apps/mydb/elements/Elements.js
+++ b/app/packs/src/apps/mydb/elements/Elements.js
@@ -32,7 +32,6 @@ export default class Elements extends Component {
const { currentElement } = this.state;
const hasCurrentElement = currentElement !== null;
- const showReport = currentElement?.type === 'report';
const listWidth = hasCurrentElement ? 5 : 12;
return (
@@ -40,7 +39,6 @@ export default class Elements extends Component {
{hasCurrentElement && (
diff --git a/app/packs/src/apps/mydb/elements/list/ElementsList.js b/app/packs/src/apps/mydb/elements/list/ElementsList.js
index 7a5bcce8f5..c0c60cf81c 100644
--- a/app/packs/src/apps/mydb/elements/list/ElementsList.js
+++ b/app/packs/src/apps/mydb/elements/list/ElementsList.js
@@ -188,7 +188,7 @@ export default class ElementsList extends React.Component {
const {
visible, hidden, totalCheckedElements, totalElements
} = this.state;
- const { overview, showReport } = this.props;
+ const { overview } = this.props;
const constEls = Immutable.Set([
'sample',
@@ -241,7 +241,6 @@ export default class ElementsList extends React.Component {
>
@@ -282,5 +281,4 @@ export default class ElementsList extends React.Component {
ElementsList.propTypes = {
overview: PropTypes.bool.isRequired,
- showReport: PropTypes.bool.isRequired,
};
diff --git a/app/packs/src/apps/mydb/elements/list/ElementsTable.js b/app/packs/src/apps/mydb/elements/list/ElementsTable.js
index 58c7cb9aa1..2a0d636645 100644
--- a/app/packs/src/apps/mydb/elements/list/ElementsTable.js
+++ b/app/packs/src/apps/mydb/elements/list/ElementsTable.js
@@ -546,7 +546,7 @@ export default class ElementsTable extends React.Component {
renderHeader = () => {
const { filterCreatedAt, ui } = this.state;
- const { type, showReport, genericEl } = this.props;
+ const { type, genericEl } = this.props;
const { fromDate, toDate, userLabel } = ui;
let searchLabel = ;
@@ -576,7 +576,6 @@ export default class ElementsTable extends React.Component {
-
- {title}
-
-
-
-
-
- );
- }
-
- renderPreview() {
- const { element, classNames } = this.props;
-
- return (
-
-
-
- );
- }
-
- render() {
- return (
-
- {this.renderPreview()}
- {this.renderModal()}
-
- );
- }
-}
-
-SvgWithModal.propTypes = {
- element: PropTypes.object.isRequired,
- classNames: PropTypes.string.isRequired,
-};
diff --git a/app/packs/src/components/sampleTaskInbox/SampleTaskInbox.js b/app/packs/src/components/sampleTaskInbox/SampleTaskInbox.js
index 12b5d74fab..dea7068db2 100644
--- a/app/packs/src/components/sampleTaskInbox/SampleTaskInbox.js
+++ b/app/packs/src/components/sampleTaskInbox/SampleTaskInbox.js
@@ -41,6 +41,9 @@ const SampleTaskInbox = ({}) => {
};
const [_colProps1, singleScanDropRef] = useDrop(dropConfig(1));
const [_colProps2, doubleScanDropRef] = useDrop(dropConfig(2));
+
+ if (!sampleTasksStore.inboxVisible) return null;
+
const sendErrorNotification = (message) => {
const notification = {
title: message,
@@ -101,7 +104,7 @@ const SampleTaskInbox = ({}) => {
{
const searchStore = useContext(StoreContext).search;
const [deltaPosition, setDeltaPosition] = useState({ x: 0, y: 0 });
+ if (!searchStore.searchModalVisible) return null;
+
let FormData = [
{
value: 'advanced',
@@ -73,7 +75,7 @@ const SearchModal = () => {
searchStore.handleCancel()}
backdrop={false}
keyboard={false}
@@ -85,7 +87,7 @@ const SearchModal = () => {
transform: `translate(${deltaPosition.x}px, ${deltaPosition.y}px)`,
}}
>
-
+
@@ -125,7 +127,7 @@ const SearchModal = () => {
-
+
}>
diff --git a/package.json b/package.json
index ed06a825ae..9d3daa312c 100644
--- a/package.json
+++ b/package.json
@@ -40,7 +40,6 @@
"factory-bot": "^6.3.1",
"html2pdf.js": "^0.10.1",
"humps": "^2.0.1",
- "immutability-helper": "^2.8.1",
"immutable": "^4.0.0-rc.12",
"jcampconverter": "^2.11.0",
"js-yaml": "^3.13.1",
@@ -91,7 +90,6 @@
"react-select": "^5.8.1",
"react-svg-file-zoom-pan": "0.1.5",
"react-svg-file-zoom-pan-latest": "npm:@complat/react-svg-file-zoom-pan@1.1.3",
- "react-svg-inline": "^1.2.0",
"react-ui-tree": "3.1.0",
"react-vis": "1.12.1",
"reactflow": "^11.7.2",
diff --git a/yarn.lock b/yarn.lock
index 0cee4a90ad..db7a419dee 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -9142,13 +9142,6 @@ ignore@^5.2.0:
resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.2.0.tgz#6d3bac8fa7fe0d45d9f9be7bac2fc279577e345a"
integrity sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ==
-immutability-helper@^2.8.1:
- version "2.9.1"
- resolved "https://registry.npmjs.org/immutability-helper/-/immutability-helper-2.9.1.tgz"
- integrity sha512-r/RmRG8xO06s/k+PIaif2r5rGc3j4Yhc01jSBfwPCXDLYZwp/yxralI37Df1mwmuzcCsen/E/ITKcTEvc1PQmQ==
- dependencies:
- invariant "^2.2.0"
-
immutable@^3.7.4:
version "3.8.2"
resolved "https://registry.npmjs.org/immutable/-/immutable-3.8.2.tgz"
@@ -9265,7 +9258,7 @@ interpret@^3.1.1:
resolved "https://registry.yarnpkg.com/interpret/-/interpret-3.1.1.tgz#5be0ceed67ca79c6c4bc5cf0d7ee843dcea110c4"
integrity sha512-6xwYfHbajpoF0xLW+iwLkhwgvLoZDfjYfoFNu8ftMoXINzwuymNLd9u/KmwtdT2GbR+/Cz66otEGEVVUHX9QLQ==
-invariant@^2.2.0, invariant@^2.2.4:
+invariant@^2.2.4:
version "2.2.4"
resolved "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz"
integrity sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==
@@ -13191,13 +13184,6 @@ react-svg-file-zoom-pan@0.1.5:
d3 "^3.5.15"
prop-types "^15.6.2"
-react-svg-inline@^1.2.0:
- version "1.2.0"
- resolved "https://registry.npmjs.org/react-svg-inline/-/react-svg-inline-1.2.0.tgz"
- integrity sha1-oCv4Gg7XYV4xlKAUtY2YrqVSH9U=
- dependencies:
- classnames "^2.2.1"
-
react-test-renderer@^17.0.0:
version "17.0.2"
resolved "https://registry.npmjs.org/react-test-renderer/-/react-test-renderer-17.0.2.tgz"