Working on adding a workspace/ sidebar view

This commit is contained in:
Alicia Sykes
2021-06-15 14:22:22 +01:00
parent f3bee653a0
commit 491c07ed67
12 changed files with 203 additions and 14 deletions

View File

@@ -8,13 +8,17 @@ import Defaults, { localStorageKeys } from '@/utils/defaults';
import conf from '../../public/conf.yml';
export const appConfig = (() => {
let usersAppConfig = Defaults.appConfig;
if (localStorage[localStorageKeys.APP_CONFIG]) {
return JSON.parse(localStorage[localStorageKeys.APP_CONFIG]);
usersAppConfig = JSON.parse(localStorage[localStorageKeys.APP_CONFIG]);
} else if (conf.appConfig) {
return conf.appConfig;
} else {
return Defaults.appConfig;
usersAppConfig = conf.appConfig;
}
usersAppConfig.layout = localStorage[localStorageKeys.LAYOUT_ORIENTATION]
|| conf.appConfig.layout || Defaults.layout;
usersAppConfig.iconSize = localStorage[localStorageKeys.ICON_SIZE]
|| conf.appConfig.iconSize || Defaults.iconSize;
return usersAppConfig;
})();
export const pageInfo = (() => {

View File

@@ -69,6 +69,25 @@
"pattern": "^[a-z0-9]{10}$",
"description": "API key for font-awesome"
},
"layout": {
"enum": [
"horizontal",
"vertical",
"auto",
"sidebar"
],
"default": "auto",
"description": "Specifies sections layout orientation on the home screen"
},
"iconSize": {
"enum": [
"small",
"medium",
"large"
],
"default": "medium",
"description": "The size of each link item / icon"
},
"cssThemes": {
"type": "array",
"description": "Theme names to be added to the dropdown",
@@ -195,7 +214,7 @@
"default": 1,
"description": "The amount of space that the section spans horizontally"
},
"layout": {
"sectionLayout": {
"enum": [
"grid",
"auto"

View File

@@ -77,4 +77,7 @@ module.exports = {
},
backupEndpoint: 'https://dashy-sync-service.as93.net',
splashScreenTime: 1900,
metaTagData: [
{ name: 'description', content: 'A simple static homepage for you\'re server' },
],
};