diff --git a/client/.env b/client/.env index 601e08c..c86ae30 100644 --- a/client/.env +++ b/client/.env @@ -1 +1 @@ -REACT_APP_VERSION=1.4.3 \ No newline at end of file +REACT_APP_VERSION=1.4.4 \ No newline at end of file diff --git a/client/src/components/Apps/AppForm/AppForm.tsx b/client/src/components/Apps/AppForm/AppForm.tsx index 61d2023..a8881c2 100644 --- a/client/src/components/Apps/AppForm/AppForm.tsx +++ b/client/src/components/Apps/AppForm/AppForm.tsx @@ -18,7 +18,7 @@ interface ComponentProps { } const AppForm = (props: ComponentProps): JSX.Element => { - const [useCustomIcon, toggleUseCustomIcon] = useState(true); + const [useCustomIcon, toggleUseCustomIcon] = useState(false); const [customIcon, setCustomIcon] = useState(null); const [formData, setFormData] = useState({ name: '', diff --git a/client/src/components/Home/Home.tsx b/client/src/components/Home/Home.tsx index 078c3a3..3742234 100644 --- a/client/src/components/Home/Home.tsx +++ b/client/src/components/Home/Home.tsx @@ -1,4 +1,4 @@ -import { useState, useEffect } from 'react'; +import { useState, useEffect, Fragment } from 'react'; import { Link } from 'react-router-dom'; // Redux @@ -101,24 +101,33 @@ const Home = (props: ComponentProps): JSX.Element => { :
} - - {appsLoading - ? - : app.isPinned)} - totalApps={apps.length} - /> + {searchConfig('hideApps', 0) !== 1 + ? ( + + {appsLoading + ? + : app.isPinned)} + totalApps={apps.length} + /> + } +
+
) + :
} -
- - - {categoriesLoading - ? - : category.isPinned)} - totalCategories={categories.length} - /> + {searchConfig('hideCategories', 0) !== 1 + ? ( + + {categoriesLoading + ? + : category.isPinned)} + totalCategories={categories.length} + /> + } + ) + :
} diff --git a/client/src/components/Settings/OtherSettings/OtherSettings.module.css b/client/src/components/Settings/OtherSettings/OtherSettings.module.css new file mode 100644 index 0000000..36e4deb --- /dev/null +++ b/client/src/components/Settings/OtherSettings/OtherSettings.module.css @@ -0,0 +1,9 @@ +.SettingsSection { + color: var(--color-primary); + padding-bottom: 3px; + margin-bottom: 10px; + font-size: 20px; + font-weight: 500; + border-bottom: 2px solid var(--color-accent); + display: inline-block; +} \ No newline at end of file diff --git a/client/src/components/Settings/OtherSettings/OtherSettings.tsx b/client/src/components/Settings/OtherSettings/OtherSettings.tsx index 3c63d83..b3e4c3e 100644 --- a/client/src/components/Settings/OtherSettings/OtherSettings.tsx +++ b/client/src/components/Settings/OtherSettings/OtherSettings.tsx @@ -11,6 +11,9 @@ import { GlobalState, NewNotification, SettingsForm } from '../../../interfaces' import InputGroup from '../../UI/Forms/InputGroup/InputGroup'; import Button from '../../UI/Buttons/Button/Button'; +// CSS +import classes from './OtherSettings.module.css'; + // Utils import { searchConfig } from '../../../utility'; @@ -29,6 +32,8 @@ const OtherSettings = (props: ComponentProps): JSX.Element => { pinAppsByDefault: 1, pinCategoriesByDefault: 1, hideHeader: 0, + hideApps: 0, + hideCategories: 0, useOrdering: 'createdAt', openSameTab: 0 }) @@ -40,6 +45,8 @@ const OtherSettings = (props: ComponentProps): JSX.Element => { pinAppsByDefault: searchConfig('pinAppsByDefault', 1), pinCategoriesByDefault: searchConfig('pinCategoriesByDefault', 1), hideHeader: searchConfig('hideHeader', 0), + hideApps: searchConfig('hideApps', 0), + hideCategories: searchConfig('hideCategories', 0), useOrdering: searchConfig('useOrdering', 'createdAt'), openSameTab: searchConfig('openSameTab', 0) }) @@ -76,6 +83,8 @@ const OtherSettings = (props: ComponentProps): JSX.Element => { return (
formSubmitHandler(e)}> + {/* OTHER OPTIONS */} +

Miscellaneous

{ onChange={(e) => inputChangeHandler(e)} /> + + {/* BEAHVIOR OPTIONS */} +

App Behavior

- - - - + + {/* MODULES OPTIONS */} +

Modules

+ + + + + + + + + + + +
) diff --git a/client/src/interfaces/Forms.ts b/client/src/interfaces/Forms.ts index 948fb42..e63fad7 100644 --- a/client/src/interfaces/Forms.ts +++ b/client/src/interfaces/Forms.ts @@ -10,6 +10,8 @@ export interface SettingsForm { pinAppsByDefault: number; pinCategoriesByDefault: number; hideHeader: number; + hideApps: number; + hideCategories: number; useOrdering: string; openSameTab: number; } \ No newline at end of file diff --git a/utils/initialConfig.json b/utils/initialConfig.json index ab0a861..a954456 100644 --- a/utils/initialConfig.json +++ b/utils/initialConfig.json @@ -39,6 +39,14 @@ { "key": "openSameTab", "value": false + }, + { + "key": "hideApps", + "value": false + }, + { + "key": "hideCategories", + "value": false } ] } \ No newline at end of file