diff --git a/src/renderer/src/components/shared/DatasetContentSelector/index.jsx b/src/renderer/src/components/shared/DatasetContentSelector/index.jsx
index 21e5f9719..628c489bb 100644
--- a/src/renderer/src/components/shared/DatasetContentSelector/index.jsx
+++ b/src/renderer/src/components/shared/DatasetContentSelector/index.jsx
@@ -1,9 +1,10 @@
-import { useState } from "react";
-import { Table, Checkbox, Text } from "@mantine/core";
+import { Card, Stack, Text, Group } from "@mantine/core";
import FullWidthContainer from "../../containers/FullWidthContainer";
+import useGlobalStore from "../../../stores/globalStore";
+import { toggleComponent } from "../../../stores/slices/datasetContentSelectorSlice";
const DatasetContentSelector = () => {
- const [selectedComponents, setSelectedComponents] = useState([]);
+ const selectedComponents = useGlobalStore((state) => state.selectedComponents);
const options = [
{
@@ -23,62 +24,67 @@ const DatasetContentSelector = () => {
value: "sites",
label: "Sites",
description:
- "Specific locations in the body, environment, or experimental setup where data or samples were collected.",
+ "Specific locations in the body, environment, or experimental setup where data or samples were collected. Conditionally required if data were gathered from multiple distinct locations or experimental setups for the same subject or sample.",
dependsOn: "subjects",
},
{
value: "performances",
label: "Performances",
- description: "Repeated experimental runs or iterations conducted as part of the study.",
+ description:
+ "Multiple distinct performances of one type of experimental protocol on the same subject or same sample (i.e. multiple visits, runs, sessions, or execution).",
dependsOn: "subjects",
},
{
value: "code",
label: "Code",
description:
- "Scripts, computational models, or analysis pipelines used in or generated by the study.",
+ "Scripts, computational models, analysis pipelines, or other code/tools used in the study.",
},
];
+
const toggleSelection = (value) => {
- setSelectedComponents((prev) =>
- prev.includes(value) ? prev.filter((item) => item !== value) : [...prev, value]
- );
+ toggleComponent(value);
};
return (
-
+ return (
+
- Several resources are required to curate and share a SPARC dataset. They are listed - below so you can make sure you can have access to them before getting started. + Select all dataset entities relevant to your study based on the data you collected.
What are subjects/samples?
- -- Subjects are experimental units that are being studied. A subject can be a - living human, animal, or a biological specimen. -
-- Samples are a portion of a subject's tissue, fluid, or other biological - materal that data is collected from. -
-- For example: If a study is being done on liver tissue, a subject could be a - human donor, and a sample could be a piece of liver tissue that was collected for - analysis. -
-- Subjects have already been added to your dataset. If you would like to - add/edit/delete subjects, you may do so in the "Subject addition" tab. -
-- Learn more about experimental versus computational datasets -
- -- Experimental datasets are datasets that have a primary purpose of - collecting and sharing data obtained from physical experiments. -
-- Computational datasets consist of computational models, visualization - scripts, or other code that is used to analyze or visualize experimental data. -
-- The dataset type was not able to be determined as the dataset does not contain data - collected from subjects or any code for computational modeling, visualization - scripts etc. If your code does not contain either of the above, please contact the - SPARC team at - curation@sparc.science. -
-