@jbrowse/plugin-data-management 2.10.1 → 2.10.3
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/HierarchicalTrackSelectorWidget/components/dialogs/ManageConnectionsDialog.js +6 -3
- package/dist/HierarchicalTrackSelectorWidget/components/tree/HamburgerMenu.js +11 -11
- package/dist/PluginStoreWidget/components/InstalledPlugin.js +1 -1
- package/dist/PluginStoreWidget/components/PluginStoreWidget.js +1 -1
- package/esm/HierarchicalTrackSelectorWidget/components/dialogs/ManageConnectionsDialog.js +6 -3
- package/esm/HierarchicalTrackSelectorWidget/components/tree/HamburgerMenu.js +11 -11
- package/esm/PluginStoreWidget/components/InstalledPlugin.js +1 -1
- package/esm/PluginStoreWidget/components/PluginStoreWidget.js +1 -1
- package/package.json +2 -2
|
@@ -17,6 +17,11 @@ const useStyles = (0, mui_1.makeStyles)()(theme => ({
|
|
|
17
17
|
width: 500,
|
|
18
18
|
},
|
|
19
19
|
}));
|
|
20
|
+
function DisabledButton() {
|
|
21
|
+
return (react_1.default.createElement(material_1.Tooltip, { title: "Unable to delete connection in config file as non-admin user" },
|
|
22
|
+
react_1.default.createElement(material_1.IconButton, null,
|
|
23
|
+
react_1.default.createElement(Close_1.default, { color: "disabled" }))));
|
|
24
|
+
}
|
|
20
25
|
const ManageConnectionsDialog = (0, mobx_react_1.observer)(function ({ session, handleClose, breakConnection, }) {
|
|
21
26
|
const { classes } = useStyles();
|
|
22
27
|
const { adminMode, connections, sessionConnections } = session;
|
|
@@ -28,9 +33,7 @@ const ManageConnectionsDialog = (0, mobx_react_1.observer)(function ({ session,
|
|
|
28
33
|
const name = (0, configuration_1.readConfObject)(conf, 'name');
|
|
29
34
|
return (react_1.default.createElement(material_1.Typography, { key: `conn-${name}` },
|
|
30
35
|
adminMode || (sessionConnections === null || sessionConnections === void 0 ? void 0 : sessionConnections.includes(conf)) ? (react_1.default.createElement(material_1.IconButton, { onClick: () => breakConnection(conf, true) },
|
|
31
|
-
react_1.default.createElement(Close_1.default, { color: "error" }))) : (react_1.default.createElement(
|
|
32
|
-
react_1.default.createElement(material_1.IconButton, null,
|
|
33
|
-
react_1.default.createElement(Close_1.default, { color: "disabled" })))),
|
|
36
|
+
react_1.default.createElement(Close_1.default, { color: "error" }))) : (react_1.default.createElement(DisabledButton, null)),
|
|
34
37
|
name));
|
|
35
38
|
}),
|
|
36
39
|
!connections.length ? (react_1.default.createElement(material_1.Typography, null, "No connections found")) : null)),
|
|
@@ -36,14 +36,14 @@ const Menu_1 = __importDefault(require("@mui/icons-material/Menu"));
|
|
|
36
36
|
// lazies
|
|
37
37
|
const FacetedDialog = (0, react_1.lazy)(() => Promise.resolve().then(() => __importStar(require('../faceted/FacetedDialog'))));
|
|
38
38
|
// lazy components
|
|
39
|
-
const
|
|
40
|
-
const
|
|
41
|
-
const
|
|
42
|
-
const
|
|
39
|
+
const CloseConnectionDialog = (0, react_1.lazy)(() => Promise.resolve().then(() => __importStar(require('../dialogs/CloseConnectionDialog'))));
|
|
40
|
+
const DeleteConnectionDialog = (0, react_1.lazy)(() => Promise.resolve().then(() => __importStar(require('../dialogs/DeleteConnectionDialog'))));
|
|
41
|
+
const ManageConnectionsDialog = (0, react_1.lazy)(() => Promise.resolve().then(() => __importStar(require('../dialogs/ManageConnectionsDialog'))));
|
|
42
|
+
const ToggleConnectionsDialog = (0, react_1.lazy)(() => Promise.resolve().then(() => __importStar(require('../dialogs/ToggleConnectionsDialog'))));
|
|
43
43
|
const HamburgerMenu = (0, mobx_react_1.observer)(function ({ model, }) {
|
|
44
44
|
const session = (0, util_1.getSession)(model);
|
|
45
45
|
const [modalInfo, setModalInfo] = (0, react_1.useState)();
|
|
46
|
-
const [
|
|
46
|
+
const [deleteDialogDetails, setDeleteDialogDetails] = (0, react_1.useState)();
|
|
47
47
|
const [connectionToggleOpen, setConnectionToggleOpen] = (0, react_1.useState)(false);
|
|
48
48
|
const [connectionManagerOpen, setConnectionManagerOpen] = (0, react_1.useState)(false);
|
|
49
49
|
const [facetedOpen, setFacetedOpen] = (0, react_1.useState)(false);
|
|
@@ -66,7 +66,7 @@ const HamburgerMenu = (0, mobx_react_1.observer)(function ({ model, }) {
|
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
68
|
if (deletingConnection) {
|
|
69
|
-
|
|
69
|
+
setDeleteDialogDetails({ name, connectionConf });
|
|
70
70
|
}
|
|
71
71
|
}
|
|
72
72
|
return (react_1.default.createElement(react_1.default.Fragment, null,
|
|
@@ -162,11 +162,11 @@ const HamburgerMenu = (0, mobx_react_1.observer)(function ({ model, }) {
|
|
|
162
162
|
},
|
|
163
163
|
] },
|
|
164
164
|
react_1.default.createElement(Menu_1.default, null)),
|
|
165
|
-
react_1.default.createElement(react_1.Suspense, { fallback:
|
|
166
|
-
modalInfo ? (react_1.default.createElement(
|
|
167
|
-
|
|
168
|
-
connectionManagerOpen ? (react_1.default.createElement(
|
|
169
|
-
connectionToggleOpen ? (react_1.default.createElement(
|
|
165
|
+
react_1.default.createElement(react_1.Suspense, { fallback: null },
|
|
166
|
+
modalInfo ? (react_1.default.createElement(CloseConnectionDialog, { modalInfo: modalInfo, onClose: () => setModalInfo(undefined) })) : null,
|
|
167
|
+
deleteDialogDetails ? (react_1.default.createElement(DeleteConnectionDialog, { handleClose: () => setDeleteDialogDetails(undefined), deleteDialogDetails: deleteDialogDetails, session: session })) : null,
|
|
168
|
+
connectionManagerOpen ? (react_1.default.createElement(ManageConnectionsDialog, { handleClose: () => setConnectionManagerOpen(false), breakConnection: breakConnection, session: session })) : null,
|
|
169
|
+
connectionToggleOpen ? (react_1.default.createElement(ToggleConnectionsDialog, { handleClose: () => setConnectionToggleOpen(false), session: session, breakConnection: breakConnection })) : null,
|
|
170
170
|
facetedOpen ? (react_1.default.createElement(FacetedDialog, { handleClose: () => setFacetedOpen(false), model: model })) : null)));
|
|
171
171
|
});
|
|
172
172
|
exports.default = HamburgerMenu;
|
|
@@ -56,7 +56,7 @@ const InstalledPlugin = (0, mobx_react_1.observer)(function ({ plugin, model, })
|
|
|
56
56
|
? (_a = session.sessionPlugins) === null || _a === void 0 ? void 0 : _a.some(p => pluginManager.pluginMetadata[plugin.name].url === p.url)
|
|
57
57
|
: false;
|
|
58
58
|
return (react_1.default.createElement(react_1.default.Fragment, null,
|
|
59
|
-
dialogPlugin ? (react_1.default.createElement(react_1.Suspense, { fallback:
|
|
59
|
+
dialogPlugin ? (react_1.default.createElement(react_1.Suspense, { fallback: null },
|
|
60
60
|
react_1.default.createElement(DeletePluginDialog, { plugin: dialogPlugin, onClose: name => {
|
|
61
61
|
if (name) {
|
|
62
62
|
const pluginMetadata = pluginManager.pluginMetadata[plugin.name];
|
|
@@ -74,7 +74,7 @@ const PluginStoreWidget = (0, mobx_react_1.observer)(function ({ model, }) {
|
|
|
74
74
|
react_1.default.createElement("code", null, "admin-server"),
|
|
75
75
|
". Any changes you make will be saved to your configuration file. You also have the ability to add custom plugins that are not in the store."))),
|
|
76
76
|
react_1.default.createElement(material_1.Button, { className: classes.customPluginButton, variant: "contained", onClick: () => setOpen(true) }, "Add custom plugin"),
|
|
77
|
-
open ? (react_1.default.createElement(react_1.Suspense, { fallback:
|
|
77
|
+
open ? (react_1.default.createElement(react_1.Suspense, { fallback: null },
|
|
78
78
|
react_1.default.createElement(AddCustomPluginDialog, { onClose: () => setOpen(false), model: model }))) : null)),
|
|
79
79
|
react_1.default.createElement(material_1.TextField, { label: "Filter plugins", value: model.filterText, onChange: event => model.setFilterText(event.target.value), fullWidth: true, InputProps: {
|
|
80
80
|
endAdornment: (react_1.default.createElement(material_1.InputAdornment, { position: "end" },
|
|
@@ -12,6 +12,11 @@ const useStyles = makeStyles()(theme => ({
|
|
|
12
12
|
width: 500,
|
|
13
13
|
},
|
|
14
14
|
}));
|
|
15
|
+
function DisabledButton() {
|
|
16
|
+
return (React.createElement(Tooltip, { title: "Unable to delete connection in config file as non-admin user" },
|
|
17
|
+
React.createElement(IconButton, null,
|
|
18
|
+
React.createElement(CloseIcon, { color: "disabled" }))));
|
|
19
|
+
}
|
|
15
20
|
const ManageConnectionsDialog = observer(function ({ session, handleClose, breakConnection, }) {
|
|
16
21
|
const { classes } = useStyles();
|
|
17
22
|
const { adminMode, connections, sessionConnections } = session;
|
|
@@ -23,9 +28,7 @@ const ManageConnectionsDialog = observer(function ({ session, handleClose, break
|
|
|
23
28
|
const name = readConfObject(conf, 'name');
|
|
24
29
|
return (React.createElement(Typography, { key: `conn-${name}` },
|
|
25
30
|
adminMode || (sessionConnections === null || sessionConnections === void 0 ? void 0 : sessionConnections.includes(conf)) ? (React.createElement(IconButton, { onClick: () => breakConnection(conf, true) },
|
|
26
|
-
React.createElement(CloseIcon, { color: "error" }))) : (React.createElement(
|
|
27
|
-
React.createElement(IconButton, null,
|
|
28
|
-
React.createElement(CloseIcon, { color: "disabled" })))),
|
|
31
|
+
React.createElement(CloseIcon, { color: "error" }))) : (React.createElement(DisabledButton, null)),
|
|
29
32
|
name));
|
|
30
33
|
}),
|
|
31
34
|
!connections.length ? (React.createElement(Typography, null, "No connections found")) : null)),
|
|
@@ -8,14 +8,14 @@ import MenuIcon from '@mui/icons-material/Menu';
|
|
|
8
8
|
// lazies
|
|
9
9
|
const FacetedDialog = lazy(() => import('../faceted/FacetedDialog'));
|
|
10
10
|
// lazy components
|
|
11
|
-
const
|
|
12
|
-
const
|
|
13
|
-
const
|
|
14
|
-
const
|
|
11
|
+
const CloseConnectionDialog = lazy(() => import('../dialogs/CloseConnectionDialog'));
|
|
12
|
+
const DeleteConnectionDialog = lazy(() => import('../dialogs/DeleteConnectionDialog'));
|
|
13
|
+
const ManageConnectionsDialog = lazy(() => import('../dialogs/ManageConnectionsDialog'));
|
|
14
|
+
const ToggleConnectionsDialog = lazy(() => import('../dialogs/ToggleConnectionsDialog'));
|
|
15
15
|
const HamburgerMenu = observer(function ({ model, }) {
|
|
16
16
|
const session = getSession(model);
|
|
17
17
|
const [modalInfo, setModalInfo] = useState();
|
|
18
|
-
const [
|
|
18
|
+
const [deleteDialogDetails, setDeleteDialogDetails] = useState();
|
|
19
19
|
const [connectionToggleOpen, setConnectionToggleOpen] = useState(false);
|
|
20
20
|
const [connectionManagerOpen, setConnectionManagerOpen] = useState(false);
|
|
21
21
|
const [facetedOpen, setFacetedOpen] = useState(false);
|
|
@@ -38,7 +38,7 @@ const HamburgerMenu = observer(function ({ model, }) {
|
|
|
38
38
|
}
|
|
39
39
|
}
|
|
40
40
|
if (deletingConnection) {
|
|
41
|
-
|
|
41
|
+
setDeleteDialogDetails({ name, connectionConf });
|
|
42
42
|
}
|
|
43
43
|
}
|
|
44
44
|
return (React.createElement(React.Fragment, null,
|
|
@@ -134,11 +134,11 @@ const HamburgerMenu = observer(function ({ model, }) {
|
|
|
134
134
|
},
|
|
135
135
|
] },
|
|
136
136
|
React.createElement(MenuIcon, null)),
|
|
137
|
-
React.createElement(Suspense, { fallback:
|
|
138
|
-
modalInfo ? (React.createElement(
|
|
139
|
-
|
|
140
|
-
connectionManagerOpen ? (React.createElement(
|
|
141
|
-
connectionToggleOpen ? (React.createElement(
|
|
137
|
+
React.createElement(Suspense, { fallback: null },
|
|
138
|
+
modalInfo ? (React.createElement(CloseConnectionDialog, { modalInfo: modalInfo, onClose: () => setModalInfo(undefined) })) : null,
|
|
139
|
+
deleteDialogDetails ? (React.createElement(DeleteConnectionDialog, { handleClose: () => setDeleteDialogDetails(undefined), deleteDialogDetails: deleteDialogDetails, session: session })) : null,
|
|
140
|
+
connectionManagerOpen ? (React.createElement(ManageConnectionsDialog, { handleClose: () => setConnectionManagerOpen(false), breakConnection: breakConnection, session: session })) : null,
|
|
141
|
+
connectionToggleOpen ? (React.createElement(ToggleConnectionsDialog, { handleClose: () => setConnectionToggleOpen(false), session: session, breakConnection: breakConnection })) : null,
|
|
142
142
|
facetedOpen ? (React.createElement(FacetedDialog, { handleClose: () => setFacetedOpen(false), model: model })) : null)));
|
|
143
143
|
});
|
|
144
144
|
export default HamburgerMenu;
|
|
@@ -28,7 +28,7 @@ const InstalledPlugin = observer(function ({ plugin, model, }) {
|
|
|
28
28
|
? (_a = session.sessionPlugins) === null || _a === void 0 ? void 0 : _a.some(p => pluginManager.pluginMetadata[plugin.name].url === p.url)
|
|
29
29
|
: false;
|
|
30
30
|
return (React.createElement(React.Fragment, null,
|
|
31
|
-
dialogPlugin ? (React.createElement(Suspense, { fallback:
|
|
31
|
+
dialogPlugin ? (React.createElement(Suspense, { fallback: null },
|
|
32
32
|
React.createElement(DeletePluginDialog, { plugin: dialogPlugin, onClose: name => {
|
|
33
33
|
if (name) {
|
|
34
34
|
const pluginMetadata = pluginManager.pluginMetadata[plugin.name];
|
|
@@ -46,7 +46,7 @@ const PluginStoreWidget = observer(function ({ model, }) {
|
|
|
46
46
|
React.createElement("code", null, "admin-server"),
|
|
47
47
|
". Any changes you make will be saved to your configuration file. You also have the ability to add custom plugins that are not in the store."))),
|
|
48
48
|
React.createElement(Button, { className: classes.customPluginButton, variant: "contained", onClick: () => setOpen(true) }, "Add custom plugin"),
|
|
49
|
-
open ? (React.createElement(Suspense, { fallback:
|
|
49
|
+
open ? (React.createElement(Suspense, { fallback: null },
|
|
50
50
|
React.createElement(AddCustomPluginDialog, { onClose: () => setOpen(false), model: model }))) : null)),
|
|
51
51
|
React.createElement(TextField, { label: "Filter plugins", value: model.filterText, onChange: event => model.setFilterText(event.target.value), fullWidth: true, InputProps: {
|
|
52
52
|
endAdornment: (React.createElement(InputAdornment, { position: "end" },
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jbrowse/plugin-data-management",
|
|
3
|
-
"version": "2.10.
|
|
3
|
+
"version": "2.10.3",
|
|
4
4
|
"description": "JBrowse 2 linear genome view",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"jbrowse",
|
|
@@ -60,5 +60,5 @@
|
|
|
60
60
|
"distModule": "esm/index.js",
|
|
61
61
|
"srcModule": "src/index.ts",
|
|
62
62
|
"module": "esm/index.js",
|
|
63
|
-
"gitHead": "
|
|
63
|
+
"gitHead": "c8fc800cd17decd72b2e971c7a6add3b95214e72"
|
|
64
64
|
}
|