Skip to content

Commit

Permalink
Unable to change global system if tree is open
Browse files Browse the repository at this point in the history
  • Loading branch information
Kasmadei committed Jun 12, 2024
1 parent 5487fd9 commit 07623a4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/components/appBar/AppBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,9 @@ const AppBar = ({ title, showBackButton = false, topPanelHeight }: Props) => {
const { classes } = useStyles();
const history = useNavigate();
const { i18n, t } = useTranslation();
const location = useLocation();
const { appBarTitle, systemsList } = useAppBar();
const location = useLocation();
const path = location.pathname;

const [anchorEl, setAnchorEl] = React.useState<null | HTMLElement>(null);
const [selectedSystem, setSelectedSystem] = useSelectedSystem();
Expand Down Expand Up @@ -143,6 +144,7 @@ const AppBar = ({ title, showBackButton = false, topPanelHeight }: Props) => {
className={classes.textfieldSelect}
value={selectedSystem ? selectedSystem.iri : ""}
onChange={handleSystemChange}
disabled={path.includes("instance")}
>
{systemsList.map((s, i) => {
return (
Expand Down

0 comments on commit 07623a4

Please sign in to comment.