🗃️ Adds new config attributes for granular auth access

This commit is contained in:
Alicia Sykes 2021-08-20 22:20:40 +01:00
parent eca0c44320
commit 95bc5d2c49
2 changed files with 24 additions and 0 deletions

View File

@ -149,6 +149,9 @@ To disallow any changes from being written to disk via the UI config editor, set
**`sectionLayout`** | `string` | _Optional_ | Specify which CSS layout will be used to responsivley place items. Can be either `auto` (which uses flex layout), or `grid`. If `grid` is selected, then `itemCountX` and `itemCountY` may also be set. Defaults to `auto`
**`itemCountX`** | `number` | _Optional_ | The number of items to display per row / horizontally. If not set, it will be calculated automatically based on available space. Can only be set if `sectionLayout` is set to `grid`. Must be a whole number between `1` and `12`
**`itemCountY`** | `number` | _Optional_ | The number of items to display per column / vertically. If not set, it will be calculated automatically based on available space. If `itemCountX` is set, then `itemCountY` can be calculated automatically. Can only be set if `sectionLayout` is set to `grid`. Must be a whole number between `1` and `12`
**`hideForUsers`** | `string[]` | _Optional_ | Current section will be visible to all users, except for those specified in this list
**`showForUsers`** | `string[]` | _Optional_ | Current section will be hidden from all users, except for those specified in this list
**`hideForGuests`** | `boolean` | _Optional_ | Current section will be visible for logged in users, but not for guests (see `appConfig.enableGuestAccess`). Defaults to `false`
**[⬆️ Back to Top](#configuring)**

View File

@ -369,6 +369,27 @@
"minimum": 1,
"maximum": 12,
"description": "Number of items per row"
},
"hideForUsers": {
"type": "array",
"description": "Section will be visible to all users, except for those specified in this list",
"items": {
"type": "string",
"description": "Username for the user that will not be able to view this section"
}
},
"showForUsers": {
"type": "array",
"description": "Section will be hidden from all users, except for those specified in this list",
"items": {
"type": "string",
"description": "Username for the user that will have access to this section"
}
},
"hideForGuests": {
"type": "boolean",
"default": false,
"description": "If set to true, section will be visible for logged in users, but not for guests"
}
}
},