mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-31 04:23:40 +00:00
fix ui address bug and streamline install flow
This commit is contained in:
committed by
Aiden McClelland
parent
45d945db2e
commit
c5585f7f35
@@ -11,50 +11,6 @@ export class WizardBaker {
|
||||
private readonly embassyApi: ApiService,
|
||||
) { }
|
||||
|
||||
install (values: {
|
||||
id: string
|
||||
title: string
|
||||
version: string
|
||||
installAlert?: string
|
||||
}): InstallWizardComponent['params'] {
|
||||
const { id, title, version, installAlert } = values
|
||||
|
||||
const action = 'install'
|
||||
const toolbar: TopbarParams = { action, title, version }
|
||||
|
||||
const slideDefinitions: SlideDefinition[] = [
|
||||
installAlert ? {
|
||||
slide: {
|
||||
selector: 'alert',
|
||||
params: {
|
||||
title: 'Warning',
|
||||
message: installAlert,
|
||||
titleColor: 'warning',
|
||||
},
|
||||
},
|
||||
bottomBar: {
|
||||
cancel: { afterLoading: { text: 'Cancel' } }, next: 'Next',
|
||||
},
|
||||
} : undefined,
|
||||
{
|
||||
slide: {
|
||||
selector: 'complete',
|
||||
params: {
|
||||
action,
|
||||
verb: 'beginning installation for',
|
||||
title,
|
||||
executeAction: () => this.embassyApi.installPackage({ id, version }),
|
||||
},
|
||||
},
|
||||
bottomBar: {
|
||||
cancel: { whileLoading: { } },
|
||||
finish: 'Dismiss',
|
||||
},
|
||||
},
|
||||
]
|
||||
return { toolbar, slideDefinitions: slideDefinitions.filter(exists) }
|
||||
}
|
||||
|
||||
update (values: {
|
||||
id: string
|
||||
title: string
|
||||
|
||||
Reference in New Issue
Block a user