@weng-lab/genomebrowser-ui 0.2.3 → 0.2.5
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/dist/TrackSelect/Folders/biosamples/data/human.json.d.ts +3 -3
- package/dist/genomebrowser-ui.es.js +6 -5
- package/dist/genomebrowser-ui.es.js.map +1 -1
- package/package.json +1 -1
- package/src/TrackSelect/Folders/biosamples/data/human.json +3 -3
- package/src/TrackSelect/TreeView/CustomTreeItem.tsx +4 -5
- package/src/TrackSelect/TreeView/TreeViewWrapper.tsx +3 -7
package/package.json
CHANGED
|
@@ -31223,11 +31223,11 @@
|
|
|
31223
31223
|
"fileAccession": "ENCFF814BZJ"
|
|
31224
31224
|
},
|
|
31225
31225
|
{
|
|
31226
|
-
"id": "ccre-
|
|
31226
|
+
"id": "ccre-ENCFF592CNZ_ENCFF346DEM_ENCFF192FOK",
|
|
31227
31227
|
"assay": "ccre",
|
|
31228
|
-
"url": "https://downloads.wenglab.org/Registry-V4/
|
|
31228
|
+
"url": "https://downloads.wenglab.org/Registry-V4/ENCFF592CNZ_ENCFF346DEM_ENCFF192FOK.bigBed",
|
|
31229
31229
|
"experimentAccession": "",
|
|
31230
|
-
"fileAccession": "
|
|
31230
|
+
"fileAccession": "ENCFF592CNZ_ENCFF346DEM_ENCFF192FOK"
|
|
31231
31231
|
}
|
|
31232
31232
|
]
|
|
31233
31233
|
},
|
|
@@ -19,7 +19,6 @@ import {
|
|
|
19
19
|
ExtendedTreeItemProps,
|
|
20
20
|
} from "../types";
|
|
21
21
|
|
|
22
|
-
// Everything below is styling for the custom directory look of the tree view
|
|
23
22
|
const TreeItemRoot = styled("li")(({ theme }) => ({
|
|
24
23
|
listStyle: "none",
|
|
25
24
|
margin: 0,
|
|
@@ -27,7 +26,7 @@ const TreeItemRoot = styled("li")(({ theme }) => ({
|
|
|
27
26
|
outline: 4,
|
|
28
27
|
color: theme.palette.grey[400],
|
|
29
28
|
...theme.applyStyles("light", {
|
|
30
|
-
color: theme.palette.grey[600],
|
|
29
|
+
color: theme.palette.grey[600],
|
|
31
30
|
}),
|
|
32
31
|
}));
|
|
33
32
|
|
|
@@ -95,9 +94,9 @@ function CustomLabel({
|
|
|
95
94
|
const TreeItemContent = styled("div")(({ theme }) => ({
|
|
96
95
|
padding: theme.spacing(0.5),
|
|
97
96
|
paddingRight: theme.spacing(2),
|
|
98
|
-
paddingLeft: `calc(${theme.spacing(1)} +
|
|
97
|
+
paddingLeft: `calc(${theme.spacing(1)} + 6px * var(--TreeView-itemDepth))`,
|
|
99
98
|
width: "100%",
|
|
100
|
-
boxSizing: "border-box",
|
|
99
|
+
boxSizing: "border-box",
|
|
101
100
|
position: "relative",
|
|
102
101
|
display: "flex",
|
|
103
102
|
alignItems: "center",
|
|
@@ -162,7 +161,7 @@ export const CustomTreeItem = React.forwardRef(function CustomTreeItem(
|
|
|
162
161
|
const icon = getIconFromTreeItemType(item.icon, renderIcon);
|
|
163
162
|
|
|
164
163
|
const handleRemoveIconClick = (e: React.MouseEvent) => {
|
|
165
|
-
e.stopPropagation();
|
|
164
|
+
e.stopPropagation();
|
|
166
165
|
onRemove?.(item);
|
|
167
166
|
};
|
|
168
167
|
|
|
@@ -9,9 +9,6 @@ import {
|
|
|
9
9
|
} from "../types";
|
|
10
10
|
import { CustomTreeItem } from "./CustomTreeItem";
|
|
11
11
|
|
|
12
|
-
/**
|
|
13
|
-
* Recursively collects all item IDs that have children (expandable items)
|
|
14
|
-
*/
|
|
15
12
|
function getAllExpandableItemIds(
|
|
16
13
|
items: TreeViewBaseItem<ExtendedTreeItemProps>[],
|
|
17
14
|
): string[] {
|
|
@@ -25,9 +22,6 @@ function getAllExpandableItemIds(
|
|
|
25
22
|
return ids;
|
|
26
23
|
}
|
|
27
24
|
|
|
28
|
-
/**
|
|
29
|
-
* Internal component that renders a single folder's tree with its own expanded state.
|
|
30
|
-
*/
|
|
31
25
|
function FolderTree({
|
|
32
26
|
items,
|
|
33
27
|
TreeItemComponent,
|
|
@@ -44,7 +38,6 @@ function FolderTree({
|
|
|
44
38
|
const [expandedItems, setExpandedItems] =
|
|
45
39
|
useState<string[]>(allExpandableIds);
|
|
46
40
|
|
|
47
|
-
// Auto-expand new items when they're added
|
|
48
41
|
useEffect(() => {
|
|
49
42
|
setExpandedItems((prev) => {
|
|
50
43
|
const newIds = allExpandableIds.filter((id) => !prev.includes(id));
|
|
@@ -77,6 +70,9 @@ function FolderTree({
|
|
|
77
70
|
sx={{
|
|
78
71
|
ml: 1,
|
|
79
72
|
mr: 1,
|
|
73
|
+
"& ul": {
|
|
74
|
+
paddingInlineStart: "12px",
|
|
75
|
+
},
|
|
80
76
|
}}
|
|
81
77
|
itemChildrenIndentation={0}
|
|
82
78
|
/>
|