diff --git a/package.json b/package.json
index b8db4372..ada64ab9 100644
--- a/package.json
+++ b/package.json
@@ -41,6 +41,7 @@
"start:test": "env-cmd -f ./.env.test react-scripts start",
"start:ci": "react-scripts -r @cypress/instrument-cra start",
"build": "react-scripts build",
+ "dist": "env-cmd -f ./.env.production react-scripts build",
"eject": "react-scripts eject",
"lint": "eslint .",
"prettier:check": "prettier --check src/**/*.js",
diff --git a/src/components/common/Item.js b/src/components/common/Item.js
index e570a94d..55da0f35 100644
--- a/src/components/common/Item.js
+++ b/src/components/common/Item.js
@@ -21,9 +21,15 @@ import {
buildFolderButtonId,
FOLDER_NAME_TITLE_CLASS,
} from '../../config/selectors';
-import { SCREEN_MAX_HEIGHT } from '../../config/constants';
+import { API_HOST, SCREEN_MAX_HEIGHT } from '../../config/constants';
-const { useItem, useChildren, useFileContent, useS3FileContent } = hooks;
+const {
+ useItem,
+ useChildren,
+ useFileContent,
+ useS3FileContent,
+ useCurrentMember,
+} = hooks;
const useStyles = makeStyles((theme) => ({
container: {
@@ -36,6 +42,7 @@ const Item = ({ id, isChildren }) => {
const { t } = useTranslation();
const classes = useStyles();
const { data: item, isLoading, isError } = useItem(id);
+ const { data: user, isLoading: isMemberLoading } = useCurrentMember();
// fetch children if item is folder
const isFolder = Boolean(item?.get('type') === ITEM_TYPES.FOLDER);
@@ -110,7 +117,18 @@ const Item = ({ id, isChildren }) => {
return ;
}
case ITEM_TYPES.APP: {
- return ;
+ if (isMemberLoading) {
+ return ;
+ }
+
+ return (
+
+ );
}
default:
console.error(`The type ${item?.get('type')} is not defined`);