added save settings to qdn

This commit is contained in:
2024-10-21 01:20:06 +03:00
parent affcd33dff
commit 082c9c11cf
10 changed files with 233 additions and 25 deletions

View File

@@ -42,7 +42,7 @@ const AppViewerContainer = ({app, isSelected, hide}) => {
</style>
</>
} style={{
height: `calc(${rootHeight} - 60px - 45px)`,
height: `calc(${rootHeight} - 60px - 45px - 20px)`,
border: 'none',
width: '100%',
display: (!isSelected || hide) && 'none'

View File

@@ -236,6 +236,7 @@ export const Apps = ({ mode, setMode, show , myName}) => {
const setNewTabWindowFunc = (e) => {
setIsNewTabWindow(true);
setSelectedTab(null)
};
useEffect(() => {
@@ -252,18 +253,19 @@ export const Apps = ({ mode, setMode, show , myName}) => {
display: !show && "none",
}}
>
{mode !== "viewer" && <Spacer height="30px" />}
{mode !== "viewer" && !selectedTab && <Spacer height="30px" />}
{mode === "home" && (
<AppsHome availableQapps={availableQapps} setMode={setMode} myApp={myApp} myWebsite={myWebsite} />
)}
{mode === "library" && (
<AppsLibrary
isShow={mode === "library" && !selectedTab}
availableQapps={availableQapps}
setMode={setMode}
myName={myName}
hasPublishApp={!!(myApp || myWebsite)}
/>
)}
{mode === "appInfo" && <AppInfo app={selectedAppInfo} myName={myName} />}
{mode === "publish" && <AppPublish names={myName ? [myName] : []} categories={categories} />}
@@ -283,7 +285,7 @@ export const Apps = ({ mode, setMode, show , myName}) => {
<AppsHome availableQapps={availableQapps} setMode={setMode} myApp={myApp} myWebsite={myWebsite} />
</>
)}
{mode !== "viewer" && <Spacer height="180px" />}
{mode !== "viewer" && !selectedTab && <Spacer height="180px" />}
</AppsParent>
);
};

View File

@@ -74,7 +74,7 @@ const ScrollerStyled = styled('div')({
"-ms-overflow-style": "none",
});
export const AppsLibrary = ({ availableQapps, setMode, myName, hasPublishApp }) => {
export const AppsLibrary = ({ availableQapps, setMode, myName, hasPublishApp, isShow }) => {
const [searchValue, setSearchValue] = useState("");
const virtuosoRef = useRef();
const { rootHeight } = useContext(MyContext);
@@ -133,7 +133,9 @@ export const AppsLibrary = ({ availableQapps, setMode, myName, hasPublishApp })
return (
<AppsLibraryContainer>
<AppsLibraryContainer sx={{
display: !isShow && 'none'
}}>
<AppsWidthLimiter>
<Box
sx={{

View File

@@ -124,6 +124,7 @@ export const AppsNavBar = () => {
}} src={NavAdd} />
</ButtonBase>
<ButtonBase onClick={(e)=> {
if(!selectedTab) return
handleClick(e)
}}>
<img style={{