@weng-lab/genomebrowser-ui 0.4.0-beta.0 → 0.4.0-beta.1

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@weng-lab/genomebrowser-ui",
3
3
  "private": false,
4
- "version": "0.4.0-beta.0",
4
+ "version": "0.4.0-beta.1",
5
5
  "license": "MIT",
6
6
  "type": "module",
7
7
  "publishConfig": {
@@ -26,8 +26,8 @@ export function ClearDialog({
26
26
  <Dialog open={open} onClose={onClose}>
27
27
  <DialogTitle
28
28
  sx={{
29
- bgcolor: "#0c184a",
30
- color: "white",
29
+ bgcolor: "primary.main",
30
+ color: "primary.contrastText",
31
31
  fontWeight: "bold",
32
32
  }}
33
33
  >
@@ -46,12 +46,7 @@ export function ClearDialog({
46
46
  </DialogContentText>
47
47
  </DialogContent>
48
48
  <DialogActions sx={{ justifyContent: "center", gap: 2, pb: 2 }}>
49
- <Button
50
- variant="contained"
51
- color="primary"
52
- onClick={onClose}
53
- autoFocus
54
- >
49
+ <Button variant="contained" color="primary" onClick={onClose} autoFocus>
55
50
  Cancel
56
51
  </Button>
57
52
  <Button variant="outlined" color="secondary" onClick={onConfirm}>
@@ -18,8 +18,8 @@ export function ResetDialog({ open, onClose, onConfirm }: ResetDialogProps) {
18
18
  <Dialog open={open} onClose={onClose}>
19
19
  <DialogTitle
20
20
  sx={{
21
- bgcolor: "#0c184a",
22
- color: "white",
21
+ bgcolor: "primary.main",
22
+ color: "primary.contrastText",
23
23
  fontWeight: "bold",
24
24
  }}
25
25
  >
@@ -37,6 +37,6 @@ export const defaultColumns: GridColDef<GeneRowInfo>[] = [
37
37
  export const defaultGroupingModel: string[] = [];
38
38
 
39
39
  /**
40
- * Leaf field - the unique identifier
40
+ * Leaf field - the raw track ID (without folder prefix) used as the tree view leaf label
41
41
  */
42
- export const defaultLeafField = "id";
42
+ export const defaultLeafField = "trackId";
@@ -11,6 +11,7 @@ import { createGeneTrack } from "./toTrack";
11
11
  function trackToRow(folderId: string, track: GeneTrackInfo): GeneRowInfo {
12
12
  return {
13
13
  id: `${folderId}/${track.id}`,
14
+ trackId: track.id,
14
15
  displayName: track.displayName,
15
16
  versions: track.versions,
16
17
  };
@@ -19,6 +19,8 @@ export type GeneTrackInfo = {
19
19
  */
20
20
  export type GeneRowInfo = {
21
21
  id: string;
22
+ /** The raw track ID without the folder prefix, used as the tree view leaf label */
23
+ trackId: string;
22
24
  displayName: string;
23
25
  versions: number[];
24
26
  };
@@ -376,8 +376,8 @@ export default function TrackSelect({
376
376
  <Dialog open={open} onClose={handleCancel} maxWidth="lg" fullWidth>
377
377
  <DialogTitle
378
378
  sx={{
379
- bgcolor: "#0c184a",
380
- color: "white",
379
+ bgcolor: "primary.main",
380
+ color: "primary.contrastText",
381
381
  display: "flex",
382
382
  justifyContent: "space-between",
383
383
  alignItems: "center",
@@ -388,7 +388,7 @@ export default function TrackSelect({
388
388
  <IconButton
389
389
  size="large"
390
390
  onClick={handleCancel}
391
- sx={{ color: "white", p: 0 }}
391
+ sx={{ color: "primary.contrastText", p: 0 }}
392
392
  >
393
393
  <CloseIcon fontSize="large" />
394
394
  </IconButton>
@@ -30,13 +30,13 @@ const TreeItemRoot = styled("li")(({ theme }) => ({
30
30
  }),
31
31
  }));
32
32
 
33
- const TreeItemLabelText = styled(Typography)({
34
- color: "black",
33
+ const TreeItemLabelText = styled(Typography)(({ theme }) => ({
34
+ color: theme.palette.text.primary,
35
35
  fontFamily: "inherit",
36
36
  overflow: "hidden",
37
37
  textOverflow: "ellipsis",
38
38
  whiteSpace: "nowrap",
39
- });
39
+ }));
40
40
 
41
41
  function CustomLabel({
42
42
  icon: Icon,