- create default values for starter fields

- add starter api urls
- try and add TS types for initial components and objects
- cleanup status indicator on layout header
- create custom textfield for config form editing
This commit is contained in:
gingervitis
2020-12-28 01:11:26 -08:00
committed by Gabe Kangas
parent f63fe9ea7b
commit f0e5bbae1f
9 changed files with 202 additions and 50 deletions

View File

@@ -4,4 +4,30 @@ export const DEFAULT_NAME = 'Owncast User';
export const DEFAULT_TITLE = 'Owncast Server';
export const DEFAULT_SUMMARY = '';
export const TEXT_MAXLENGTH = 255;
export const TEXT_MAXLENGTH = 255;
// Creating this so that it'll be easier to change values in one place, rather than looking for places to change it in a sea of JSX.
// key is the input's `fieldName`
//serversummary
export const TEXTFIELD_DEFAULTS = {
name: {
apiPath: '/name',
defaultValue: DEFAULT_NAME,
maxLength: TEXT_MAXLENGTH,
placeholder: DEFAULT_NAME,
configPath: 'instanceDetails',
label: 'Your name',
tip: 'This is your name that shows up on things and stuff.',
},
summary: {
apiPath: '/summary',
defaultValue: DEFAULT_NAME,
maxLength: TEXT_MAXLENGTH,
placeholder: DEFAULT_NAME,
configPath: 'instanceDetails',
label: 'Summary',
tip: 'A brief blurb about what your stream is about.',
}
}