feat: add option to save custom username suggestions (#415)

* 💄 add option to save custom username suggestions that shall be used instead of the docker style usernames.

* 🚸 add minimum of 10 usernames / update wording

* Prettified Code!

* 🚸 add message for the default name generator / indicate that no further action is required

Co-authored-by: jeyemwey <jeyemwey@users.noreply.github.com>
This commit is contained in:
Jannik
2022-01-12 19:17:14 +01:00
committed by GitHub
parent 0f3051960f
commit 030b936f05
6 changed files with 106 additions and 15 deletions

View File

@@ -31,6 +31,7 @@ export const API_WEB_PORT = '/webserverport';
export const API_YP_SWITCH = '/directoryenabled';
export const API_CHAT_DISABLE = '/chat/disable';
export const API_CHAT_FORBIDDEN_USERNAMES = '/chat/forbiddenusernames';
export const API_CHAT_SUGGESTED_USERNAMES = '/chat/suggestedusernames';
export const API_EXTERNAL_ACTIONS = '/externalactions';
export const API_VIDEO_CODEC = '/video/codec';
@@ -190,6 +191,15 @@ export const TEXTFIELD_PROPS_CHAT_FORBIDDEN_USERNAMES = {
tip: 'A list of words in chat usernames you disallow.',
};
export const TEXTFIELD_PROPS_CHAT_SUGGESTED_USERNAMES = {
apiPath: API_CHAT_SUGGESTED_USERNAMES,
placeholder: 'username',
label: 'Default usernames',
tip: 'An optional list of chat usernames that new users get assigned. If the list holds less then 10 items, random names will be generated. Users can change their usernames afterwards and the same username may be given out multple times.',
min_not_reached: 'At least 10 items are required for this feature.',
no_entries: 'The default name generator is used.',
};
export const VIDEO_VARIANT_SETTING_DEFAULTS = {
// this one is currently unused
audioBitrate: {